@ckeditor/ckeditor5-revision-history 46.0.0 → 46.0.1-alpha.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/revision-history.js +1 -1
- package/dist/index.js +7 -7
- package/dist/translations/af.js +1 -1
- package/dist/translations/af.umd.js +1 -1
- package/dist/translations/ar.js +1 -1
- package/dist/translations/ar.umd.js +1 -1
- package/dist/translations/ast.js +1 -1
- package/dist/translations/ast.umd.js +1 -1
- package/dist/translations/az.js +1 -1
- package/dist/translations/az.umd.js +1 -1
- package/dist/translations/be.js +1 -1
- package/dist/translations/be.umd.js +1 -1
- package/dist/translations/bg.js +1 -1
- package/dist/translations/bg.umd.js +1 -1
- package/dist/translations/bn.js +1 -1
- package/dist/translations/bn.umd.js +1 -1
- package/dist/translations/bs.js +1 -1
- package/dist/translations/bs.umd.js +1 -1
- package/dist/translations/ca.js +1 -1
- package/dist/translations/ca.umd.js +1 -1
- package/dist/translations/cs.js +1 -1
- package/dist/translations/cs.umd.js +1 -1
- package/dist/translations/da.js +1 -1
- package/dist/translations/da.umd.js +1 -1
- package/dist/translations/de-ch.js +1 -1
- package/dist/translations/de-ch.umd.js +1 -1
- package/dist/translations/de.js +1 -1
- package/dist/translations/de.umd.js +1 -1
- package/dist/translations/el.js +1 -1
- package/dist/translations/el.umd.js +1 -1
- package/dist/translations/en-au.js +1 -1
- package/dist/translations/en-au.umd.js +1 -1
- package/dist/translations/en-gb.js +1 -1
- package/dist/translations/en-gb.umd.js +1 -1
- package/dist/translations/en.js +1 -1
- package/dist/translations/en.umd.js +1 -1
- package/dist/translations/eo.js +1 -1
- package/dist/translations/eo.umd.js +1 -1
- package/dist/translations/es-co.js +1 -1
- package/dist/translations/es-co.umd.js +1 -1
- package/dist/translations/es.js +1 -1
- package/dist/translations/es.umd.js +1 -1
- package/dist/translations/et.js +1 -1
- package/dist/translations/et.umd.js +1 -1
- package/dist/translations/eu.js +1 -1
- package/dist/translations/eu.umd.js +1 -1
- package/dist/translations/fa.js +1 -1
- package/dist/translations/fa.umd.js +1 -1
- package/dist/translations/fi.js +1 -1
- package/dist/translations/fi.umd.js +1 -1
- package/dist/translations/fr.js +1 -1
- package/dist/translations/fr.umd.js +1 -1
- package/dist/translations/gl.js +1 -1
- package/dist/translations/gl.umd.js +1 -1
- package/dist/translations/gu.js +1 -1
- package/dist/translations/gu.umd.js +1 -1
- package/dist/translations/he.js +1 -1
- package/dist/translations/he.umd.js +1 -1
- package/dist/translations/hi.js +1 -1
- package/dist/translations/hi.umd.js +1 -1
- package/dist/translations/hr.js +1 -1
- package/dist/translations/hr.umd.js +1 -1
- package/dist/translations/hu.js +1 -1
- package/dist/translations/hu.umd.js +1 -1
- package/dist/translations/hy.js +1 -1
- package/dist/translations/hy.umd.js +1 -1
- package/dist/translations/id.js +1 -1
- package/dist/translations/id.umd.js +1 -1
- package/dist/translations/it.js +1 -1
- package/dist/translations/it.umd.js +1 -1
- package/dist/translations/ja.js +1 -1
- package/dist/translations/ja.umd.js +1 -1
- package/dist/translations/jv.js +1 -1
- package/dist/translations/jv.umd.js +1 -1
- package/dist/translations/kk.js +1 -1
- package/dist/translations/kk.umd.js +1 -1
- package/dist/translations/km.js +1 -1
- package/dist/translations/km.umd.js +1 -1
- package/dist/translations/kn.js +1 -1
- package/dist/translations/kn.umd.js +1 -1
- package/dist/translations/ko.js +1 -1
- package/dist/translations/ko.umd.js +1 -1
- package/dist/translations/ku.js +1 -1
- package/dist/translations/ku.umd.js +1 -1
- package/dist/translations/lt.js +1 -1
- package/dist/translations/lt.umd.js +1 -1
- package/dist/translations/lv.js +1 -1
- package/dist/translations/lv.umd.js +1 -1
- package/dist/translations/ms.js +1 -1
- package/dist/translations/ms.umd.js +1 -1
- package/dist/translations/nb.js +1 -1
- package/dist/translations/nb.umd.js +1 -1
- package/dist/translations/ne.js +1 -1
- package/dist/translations/ne.umd.js +1 -1
- package/dist/translations/nl.js +1 -1
- package/dist/translations/nl.umd.js +1 -1
- package/dist/translations/no.js +1 -1
- package/dist/translations/no.umd.js +1 -1
- package/dist/translations/oc.js +1 -1
- package/dist/translations/oc.umd.js +1 -1
- package/dist/translations/pl.js +1 -1
- package/dist/translations/pl.umd.js +1 -1
- package/dist/translations/pt-br.js +1 -1
- package/dist/translations/pt-br.umd.js +1 -1
- package/dist/translations/pt.js +1 -1
- package/dist/translations/pt.umd.js +1 -1
- package/dist/translations/ro.js +1 -1
- package/dist/translations/ro.umd.js +1 -1
- package/dist/translations/ru.js +1 -1
- package/dist/translations/ru.umd.js +1 -1
- package/dist/translations/si.js +1 -1
- package/dist/translations/si.umd.js +1 -1
- package/dist/translations/sk.js +1 -1
- package/dist/translations/sk.umd.js +1 -1
- package/dist/translations/sl.js +1 -1
- package/dist/translations/sl.umd.js +1 -1
- package/dist/translations/sq.js +1 -1
- package/dist/translations/sq.umd.js +1 -1
- package/dist/translations/sr-latn.js +1 -1
- package/dist/translations/sr-latn.umd.js +1 -1
- package/dist/translations/sr.js +1 -1
- package/dist/translations/sr.umd.js +1 -1
- package/dist/translations/sv.js +1 -1
- package/dist/translations/sv.umd.js +1 -1
- package/dist/translations/th.js +1 -1
- package/dist/translations/th.umd.js +1 -1
- package/dist/translations/ti.js +1 -1
- package/dist/translations/ti.umd.js +1 -1
- package/dist/translations/tk.js +1 -1
- package/dist/translations/tk.umd.js +1 -1
- package/dist/translations/tr.js +1 -1
- package/dist/translations/tr.umd.js +1 -1
- package/dist/translations/tt.js +1 -1
- package/dist/translations/tt.umd.js +1 -1
- package/dist/translations/ug.js +1 -1
- package/dist/translations/ug.umd.js +1 -1
- package/dist/translations/uk.js +1 -1
- package/dist/translations/uk.umd.js +1 -1
- package/dist/translations/ur.js +1 -1
- package/dist/translations/ur.umd.js +1 -1
- package/dist/translations/uz.js +1 -1
- package/dist/translations/uz.umd.js +1 -1
- package/dist/translations/vi.js +1 -1
- package/dist/translations/vi.umd.js +1 -1
- package/dist/translations/zh-cn.js +1 -1
- package/dist/translations/zh-cn.umd.js +1 -1
- package/dist/translations/zh.js +1 -1
- package/dist/translations/zh.umd.js +1 -1
- package/package.json +11 -11
- package/src/changeitem.js +2 -2
- package/src/editor/revisionviewereditor.js +2 -2
- package/src/editor/revisionviewereditorui.js +1 -1
- package/src/editor/revisionviewereditoruiview.js +1 -1
- package/src/index.d.ts +1 -3
- 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
|
-
_0x53b020(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x1a7ee9){super(),this['id']=_0x1a7ee9['id']||_0x1b5d50(),this['creator']=_0x1a7ee9['creator']||null,this['authors']=_0x1a7ee9['authors']||[],this['diffData']=_0x1a7ee9['diffData']||null,this['toVersion']=_0x1a7ee9['toVersion']||0x0,this['fromVersion']=_0x1a7ee9['fromVersion']||0x0,this['set']('name',_0x1a7ee9['name']||''),this['set']('createdAt',_0x1a7ee9['createdAt']||new Date()),this['set']('attributes',_0x1a7ee9['attributes']||{});}['setName'](_0x16d4fa){this['_update']({'name':_0x16d4fa});}['setAttribute'](_0x38407b,_0x4722b4){const _0x4e03f5=_0x186599(this['attributes']);_0x2a78eb(_0x4e03f5,_0x38407b,_0x4722b4),this['_update']({'attributes':_0x4e03f5});}['removeAttribute'](_0x34c508){const _0x50706c=_0x186599(this['attributes']);_0x148056(_0x50706c,_0x34c508),this['_update']({'attributes':_0x50706c});}['_update'](_0x465bec,_0x5a5789=!0x1){let _0x154a05=!0x1;const _0x25268d={'id':this['id']},_0x3c4c9b=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x2e4fa6 of _0x3c4c9b){const _0x3d2607=_0x465bec[_0x2e4fa6];void 0x0!==_0x3d2607&&_0x3d2607!==this[_0x2e4fa6]&&(this[_0x2e4fa6]=_0x3d2607,_0x25268d[_0x2e4fa6]=_0x3d2607,_0x154a05=!0x0);}_0x154a05&&(_0x25268d['authors']&&(_0x25268d['authorsIds']=_0x25268d['authors']['map'](_0x571072=>_0x571072['id']),delete _0x25268d['authors']),this['fire']('_update',_0x25268d,_0x5a5789));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x11495d=>_0x11495d['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class S extends _0x235b76{['_revisions'];static get['requires'](){return[_0x34eefc];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x3a9508){super(_0x3a9508),this['_revisions']=new _0x3ac57f();}['afterInit'](){!async function(_0x1abc88){const _0x1e415a=_0x3705bf([0x41,0x77,0x44,0x69,0x58,0x34,0x74,0x52,0x53,0x36,0x67,0x6b,0x50,0x43,0x4d,0x48,0x6d,0x62,0x6e,0x57,0x65,0x75,0x32,0x61,0x70,0x56,0x73,0x63,0x68,0x30,0x6a,0x42,0x47,0x35,0x54,0x4e,0x78,0x51,0x4c,0x66,0x5a,0x31,0x45,0x55,0x76,0x71,0x37,0x49,0x33,0x59,0x38,0x4b,0x6f,0x46,0x64,0x7a,0x4a,0x79,0x72,0x6c,0x4f,0x39]),_0x34014f=0xeb829,_0xdde753=0x109c0e60,_0xd7c1d8=0x109b6370^_0xdde753,_0x1a7318=window[_0x3705bf([0x44,0x61,0x74,0x65])][_0x3705bf([0x6e,0x6f,0x77])](),_0x20ec79=_0x1abc88[_0x3705bf([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x126b28=new window[(_0x3705bf([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0xc72592=>{_0x20ec79[_0x3705bf([0x6f,0x6e,0x63,0x65])](_0x3705bf([0x72,0x65,0x61,0x64,0x79]),_0xc72592);}),_0x164d60={[_0x3705bf([0x6b,0x74,0x79])]:_0x3705bf([0x45,0x43]),[_0x3705bf([0x75,0x73,0x65])]:_0x3705bf([0x73,0x69,0x67]),[_0x3705bf([0x63,0x72,0x76])]:_0x3705bf([0x50,0x2d,0x32,0x35,0x36]),[_0x3705bf([0x78])]:_0x3705bf([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]),[_0x3705bf([0x79])]:_0x3705bf([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]),[_0x3705bf([0x61,0x6c,0x67])]:_0x3705bf([0x45,0x53,0x32,0x35,0x36])},_0x4321e3=_0x20ec79[_0x3705bf([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x3705bf([0x67,0x65,0x74])](_0x3705bf([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x9f0ae9(){let _0x46265d,_0x1665d9=null,_0x112f2a=null;try{if(_0x4321e3==_0x3705bf([0x47,0x50,0x4c]))return _0x3705bf([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x46265d=_0x1c0aa6(),!_0x46265d)return _0x3705bf([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x46265d[_0x3705bf([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x112f2a=_0x2ec1b9(_0x46265d[_0x3705bf([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x46265d[_0x3705bf([0x6a,0x74,0x69])])),await _0x3cf3ee()?_0x129f5c()?_0x4a5479()?_0x3705bf([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x35fc51()?(_0x46265d[_0x3705bf([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x3705bf([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x1665d9=_0x3ba307(_0x3705bf([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x46265d[_0x3705bf([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x3705bf([0x74,0x72,0x69,0x61,0x6c])&&(_0x1665d9=_0x3ba307(_0x3705bf([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x4c8c73()):_0x3705bf([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x3705bf([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x3705bf([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x3705bf([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x4a5479(){const _0x10e76d=[_0x3705bf([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x3705bf([0x74,0x72,0x69,0x61,0x6c])][_0x3705bf([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x46265d[_0x3705bf([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x1a7318/0x3e8:0xe10*_0xd7c1d8;return _0x46265d[_0x3705bf([0x65,0x78,0x70])]<_0x10e76d;}function _0x129f5c(){const _0x357c58=_0x46265d[_0x3705bf([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x357c58)return!0x1;if(_0x357c58[_0x3705bf([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x3705bf([0x2a])))return!0x0;if(_0x357c58[_0x3705bf([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x3705bf([0x52,0x48])))return!0x0;if(_0x357c58[_0x3705bf([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x3705bf([0x52,0x52,0x48]))){if(_0x5e246d())return!0x0;if(_0x6a194c()||_0xa5d0fa())return!0x0;}return!0x1;}function _0x35fc51(){const _0x5c9259=_0x46265d[_0x3705bf([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x5c9259||0x0==_0x5c9259[_0x3705bf([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x20f09a}=new URL(window[_0x3705bf([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x5c9259[_0x3705bf([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x20f09a))return!0x0;const _0x29d655=_0x20f09a[_0x3705bf([0x73,0x70,0x6c,0x69,0x74])](_0x3705bf([0x2e]));return _0x5c9259[_0x3705bf([0x66,0x69,0x6c,0x74,0x65,0x72])](_0xb68f9c=>_0xb68f9c[_0x3705bf([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x3705bf([0x2a])))[_0x3705bf([0x6d,0x61,0x70])](_0xa3dffa=>_0xa3dffa[_0x3705bf([0x73,0x70,0x6c,0x69,0x74])](_0x3705bf([0x2e])))[_0x3705bf([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x22224a=>_0x22224a[_0x3705bf([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x29d655[_0x3705bf([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x3705bf([0x6d,0x61,0x70])](_0x3e4b0f=>Array(_0x29d655[_0x3705bf([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0x3e4b0f[_0x3705bf([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x3705bf([0x66,0x69,0x6c,0x6c])](_0x3e4b0f[0x0]===_0x3705bf([0x2a])?_0x3705bf([0x2a]):'')[_0x3705bf([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0x3e4b0f))[_0x3705bf([0x73,0x6f,0x6d,0x65])](_0x70d44=>_0x29d655[_0x3705bf([0x65,0x76,0x65,0x72,0x79])]((_0x4867f2,_0xff9795)=>_0x70d44[_0xff9795]===_0x4867f2||_0x70d44[_0xff9795]===_0x3705bf([0x2a])));}function _0x4c8c73(){return _0x1665d9&&_0x112f2a?new window[(_0x3705bf([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x2706e3,_0x2aab69)=>{_0x1665d9[_0x3705bf([0x74,0x68,0x65,0x6e])](_0x2706e3,_0x2aab69),_0x112f2a[_0x3705bf([0x74,0x68,0x65,0x6e])](_0x2761ed=>{_0x2761ed!=_0x3705bf([0x56,0x61,0x6c,0x69,0x64])&&_0x2706e3(_0x2761ed);},_0x2aab69);}):_0x1665d9||_0x112f2a||_0x3705bf([0x56,0x61,0x6c,0x69,0x64]);}}function _0x2ec1b9(_0x5790d9,_0x14c9e2){return new window[(_0x3705bf([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0xa015a5=>{if(_0x3be99d())return _0xa015a5(_0x3705bf([0x56,0x61,0x6c,0x69,0x64]));_0x34eb30(),_0x20ec79[_0x3705bf([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x3705bf([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x3d5f12=!0x1;const _0xf4a1c9=_0x1b5d50();function _0x47e73f(_0x10fa8a){return!!_0x10fa8a&&(typeof _0x10fa8a===_0x3705bf([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x10fa8a===_0x3705bf([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x10fa8a[_0x3705bf([0x74,0x68,0x65,0x6e])]===_0x3705bf([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x10fa8a[_0x3705bf([0x63,0x61,0x74,0x63,0x68])]===_0x3705bf([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x4da3a0(_0x4db079){_0x404a64(_0x4db079)[_0x3705bf([0x74,0x68,0x65,0x6e])](_0x46634d=>{if(!_0x46634d||_0x46634d[_0x3705bf([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x3705bf([0x6f,0x6b]))return _0x3705bf([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x5f3a5f(_0x2dff84(_0xf4a1c9+_0x14c9e2))!=_0x46634d[_0x3705bf([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x3705bf([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x3705bf([0x56,0x61,0x6c,0x69,0x64]);})[_0x3705bf([0x74,0x68,0x65,0x6e])](_0x161a6b=>(_0xc4aaba(),_0x161a6b),()=>{const _0x13e925=_0x2923fa();return null==_0x13e925?(_0xc4aaba(),_0x3705bf([0x56,0x61,0x6c,0x69,0x64])):_0x3705bf(_0x1a7318-_0x13e925>(0x34908a60^_0xdde753)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x3705bf([0x74,0x68,0x65,0x6e])](_0xa015a5)[_0x3705bf([0x63,0x61,0x74,0x63,0x68])](()=>{_0xa015a5(_0x3705bf([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x11ade1=0x10aae0e0^_0xdde753;function _0xc4aaba(){const _0x506dce=_0x3705bf([0x6c,0x6c,0x63,0x74,0x2d])+_0x5f3a5f(_0x2dff84(_0x5790d9)),_0x3e50a4=_0x3c4a09(_0x5f3a5f(window[_0x3705bf([0x4d,0x61,0x74,0x68])][_0x3705bf([0x63,0x65,0x69,0x6c])](_0x1a7318/_0x11ade1)));window[_0x3705bf([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x3705bf([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x506dce,_0x3e50a4);}function _0x2923fa(){const _0xfda2f8=_0x3705bf([0x6c,0x6c,0x63,0x74,0x2d])+_0x5f3a5f(_0x2dff84(_0x5790d9)),_0x32bb48=window[_0x3705bf([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x3705bf([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0xfda2f8);return _0x32bb48?window[_0x3705bf([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x3c4a09(_0x32bb48),0x10)*_0x11ade1:null;}function _0x404a64(_0x59b1a3){return new window[(_0x3705bf([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x3aba50,_0x2f077c)=>{_0x59b1a3[_0x3705bf([0x74,0x68,0x65,0x6e])](_0x3aba50,_0x2f077c),window[_0x3705bf([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x2f077c,0x109ddaa0^_0xdde753);});}}_0x20ec79[_0x3705bf([0x6f,0x6e])](_0x3705bf([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x2dd8c0,_0x584a65)=>{if(_0x584a65[0x0]!=_0x5790d9)return _0xa015a5(_0x3705bf([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x584a65[0x1]={..._0x584a65[0x1],[_0x3705bf([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0xf4a1c9};},{[_0x3705bf([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x3705bf([0x68,0x69,0x67,0x68])}),_0x20ec79[_0x3705bf([0x6f,0x6e])](_0x3705bf([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x2ac4eb=>{_0x47e73f(_0x2ac4eb[_0x3705bf([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x3d5f12=!0x0,_0x4da3a0(_0x2ac4eb[_0x3705bf([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x3705bf([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x3705bf([0x6c,0x6f,0x77])}),_0x126b28[_0x3705bf([0x74,0x68,0x65,0x6e])](()=>{_0x3d5f12||_0xa015a5(_0x3705bf([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x3be99d(){return _0x20ec79[_0x3705bf([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x3705bf([0x76,0x69,0x65,0x77])][_0x3705bf([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x3705bf([0x61,0x75,0x74,0x6f]);}function _0x34eb30(){_0x20ec79[_0x3705bf([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x3705bf([0x76,0x69,0x65,0x77])][_0x3705bf([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x3705bf([0x61,0x75,0x74,0x6f]);}}function _0x3ba307(_0x270f05){const _0x3050d9=[new window[(_0x3705bf([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2f206b=>setTimeout(_0x2f206b,0x109530ac^_0xdde753)),_0x126b28[_0x3705bf([0x74,0x68,0x65,0x6e])](()=>new window[(_0x3705bf([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x1dad35=>{const _0x375aac=0x109c0e67^_0xdde753,_0xf4b3c6=_0x1abc88[_0x3705bf([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x297668(){_0xf4b3c6[_0x3705bf([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x375aac&&_0x1dad35();}_0x297668(),_0xf4b3c6[_0x3705bf([0x6f,0x6e])](_0x3705bf([0x61,0x64,0x64]),_0x297668);})),new window[(_0x3705bf([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2d29c0=>{function _0x2bd366(){for(const _0xa5dd0f in window)if(window[_0x3705bf([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x3705bf([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0xa5dd0f))&&window[_0xa5dd0f]==_0x34014f)return _0x2d29c0();_0x20ec79[_0x3705bf([0x73,0x74,0x61,0x74,0x65])]!=_0x3705bf([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x3705bf([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x2bd366,0x109c1de8^_0xdde753);}_0x4fb361(_0x3705bf([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x2bd366();})];return window[_0x3705bf([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x3705bf([0x72,0x61,0x63,0x65])](_0x3050d9)[_0x3705bf([0x74,0x68,0x65,0x6e])](()=>_0x270f05);}async function _0x21f391(){if(await _0x126b28,_0x4fb361(_0x3705bf([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x5c4ba8=_0x1abc88[_0x3705bf([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x16c105=_0x1abc88[_0x3705bf([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])](_0x5c4ba8[_0x3705bf([0x69,0x64])]),_0x575b18=_0x548125(_0x3705bf([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x575b18[_0x3705bf([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x5c4ba8['id'],_0x16c105?_0x16c105['id']:null,!0x0),_0x575b18[_0x3705bf([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x3705bf([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x575b18[_0x3705bf([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x575b18[_0x3705bf([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x13eb62,void(_0x575b18[_0x3705bf([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x13eb62);}if(_0x4fb361(_0x3705bf([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x135d83=_0x548125(_0x3705bf([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x135d83[_0x3705bf([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x3705bf([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x135d83[_0x3705bf([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x135d83[_0x3705bf([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x13eb62,_0x135d83[_0x3705bf([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x13eb62;}_0x20ec79[_0x3705bf([0x6d,0x6f,0x64,0x65,0x6c])][_0x3705bf([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x13eb62,_0x20ec79[_0x3705bf([0x6d,0x6f,0x64,0x65,0x6c])][_0x3705bf([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x13eb62,_0x20ec79[_0x3705bf([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x3705bf([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x5e246d(){return _0x4fb361(_0x3705bf([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x548125(_0x3705bf([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x3705bf([0x73,0x74,0x61,0x74,0x65])]==_0x3705bf([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x6a194c(){return _0x4fb361(_0x3705bf([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 _0xa5d0fa(){return _0x4fb361(_0x3705bf([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x286523(_0x12d844){const _0x301037=_0x512467();_0x20ec79[_0x301037]=_0x3705bf([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])+_0x12d844,_0x12d844[_0x3705bf([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x3705bf([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x512467()]=_0x34014f),_0x12d844!=_0x3705bf([0x56,0x61,0x6c,0x69,0x64])&&_0x21f391();}function _0x512467(){const _0x31e5a6=window[_0x3705bf([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x3705bf([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x3705bf([0x6e,0x6f,0x77])]())[_0x3705bf([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x3705bf([0x2e]),'');let _0x28cc0d=_0x3705bf([0x41]);for(let _0x5716a6=0x0;_0x5716a6<_0x31e5a6[_0x3705bf([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x5716a6+=0x2){let _0x25b0dc=window[_0x3705bf([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x31e5a6[_0x3705bf([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x5716a6,_0x5716a6+0x2));_0x25b0dc>=_0x1e415a[_0x3705bf([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x25b0dc-=_0x1e415a[_0x3705bf([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x28cc0d+=_0x1e415a[_0x25b0dc];}return _0x28cc0d;}function _0x1c0aa6(){const _0xa5d2a2=_0x4321e3[_0x3705bf([0x73,0x70,0x6c,0x69,0x74])](_0x3705bf([0x2e]));if(0x3!=_0xa5d2a2[_0x3705bf([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x4815af(_0xa5d2a2[0x1]);function _0x4815af(_0x5d8553){const _0x161c2e=_0x1925ae(_0x5d8553);return _0x161c2e&&_0x4c4c0e()?_0x161c2e:null;function _0x4c4c0e(){const _0x323381=_0x161c2e[_0x3705bf([0x6a,0x74,0x69])],_0x354b70=window[_0x3705bf([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x323381[_0x3705bf([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x323381[_0x3705bf([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x415ae4={..._0x161c2e,[_0x3705bf([0x6a,0x74,0x69])]:_0x323381[_0x3705bf([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x323381[_0x3705bf([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x415ae4[_0x3705bf([0x76,0x63])],_0x2dff84(_0x415ae4)==_0x354b70;}}}async function _0x3cf3ee(){let _0x330e14=!0x0;try{const _0x28e2d1=_0x4321e3[_0x3705bf([0x73,0x70,0x6c,0x69,0x74])](_0x3705bf([0x2e])),[_0x32e281,_0x42153c,_0x6791b8]=_0x28e2d1;return _0x7e14bc(_0x32e281),await _0x145af4(_0x32e281,_0x42153c,_0x6791b8),_0x330e14;}catch{return!0x1;}function _0x7e14bc(_0x304a2b){const _0x3a472a=_0x1925ae(_0x304a2b);_0x3a472a&&_0x3a472a[_0x3705bf([0x61,0x6c,0x67])]==_0x3705bf([0x45,0x53,0x32,0x35,0x36])||(_0x330e14=!0x1);}async function _0x145af4(_0x2830f5,_0x28b5f3,_0xb03c1b){const _0x26ce8d=window[_0x3705bf([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x3705bf([0x66,0x72,0x6f,0x6d])](_0x2acf5d(_0xb03c1b),_0x45e72d=>_0x45e72d[_0x3705bf([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x2be97c=new window[(_0x3705bf([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x3705bf([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x2830f5+_0x3705bf([0x2e])+_0x28b5f3),_0x4bbaba=window[_0x3705bf([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x3705bf([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x4bbaba)return;const _0x5d0ced=await _0x4bbaba[_0x3705bf([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x3705bf([0x6a,0x77,0x6b]),_0x164d60,{[_0x3705bf([0x6e,0x61,0x6d,0x65])]:_0x3705bf([0x45,0x43,0x44,0x53,0x41]),[_0x3705bf([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x3705bf([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x3705bf([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x4bbaba[_0x3705bf([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x3705bf([0x6e,0x61,0x6d,0x65])]:_0x3705bf([0x45,0x43,0x44,0x53,0x41]),[_0x3705bf([0x68,0x61,0x73,0x68])]:{[_0x3705bf([0x6e,0x61,0x6d,0x65])]:_0x3705bf([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x5d0ced,_0x26ce8d,_0x2be97c)||(_0x330e14=!0x1);}}function _0x1925ae(_0x34d312){return _0x34d312[_0x3705bf([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x3705bf([0x65,0x79]))?JSON[_0x3705bf([0x70,0x61,0x72,0x73,0x65])](_0x2acf5d(_0x34d312)):null;}function _0x2acf5d(_0x565c92){return window[_0x3705bf([0x61,0x74,0x6f,0x62])](_0x565c92[_0x3705bf([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x3705bf([0x2b]))[_0x3705bf([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x3705bf([0x2f])));}function _0x2dff84(_0x3f95f4){let _0x5510d1=0x1505;function _0x1a03eb(_0x50c7f4){for(let _0xf8ef5=0x0;_0xf8ef5<_0x50c7f4[_0x3705bf([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0xf8ef5++){const _0x4b1ea4=_0x50c7f4[_0x3705bf([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0xf8ef5);_0x5510d1=(_0x5510d1<<0x5)+_0x5510d1+_0x4b1ea4,_0x5510d1&=_0x5510d1;}}function _0x49997a(_0x2e2530){Array[_0x3705bf([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x2e2530)?_0x2e2530[_0x3705bf([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x49997a):_0x2e2530&&typeof _0x2e2530==_0x3705bf([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x3705bf([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x2e2530)[_0x3705bf([0x73,0x6f,0x72,0x74])]()[_0x3705bf([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x2f0297,_0x2e368b])=>{_0x1a03eb(_0x2f0297),_0x49997a(_0x2e368b);}):_0x1a03eb(window[_0x3705bf([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x2e2530));}return _0x49997a(_0x3f95f4),_0x5510d1>>>0x0;}function _0x5f3a5f(_0x3d9c89){return _0x3d9c89[_0x3705bf([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x3705bf([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x3705bf([0x30]));}function _0x3c4a09(_0x537a70){return _0x537a70[_0x3705bf([0x73,0x70,0x6c,0x69,0x74])]('')[_0x3705bf([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x3705bf([0x6a,0x6f,0x69,0x6e])]('');}function _0x4fb361(_0x469864){return _0x20ec79[_0x3705bf([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x3705bf([0x68,0x61,0x73])](_0x469864);}function _0x548125(_0x2b0161){return _0x20ec79[_0x3705bf([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x3705bf([0x67,0x65,0x74])](_0x2b0161);}function _0x13eb62(){}function _0x3705bf(_0x2e3e03){return _0x2e3e03['map'](_0x56bd39=>String['fromCharCode'](_0x56bd39))['join']('');}_0x286523(await _0x9f0ae9());}(this);}['createRevision'](_0x10db59){const _0x13b9d8=this['editor']['plugins']['get']('Users');return new I({'id':_0x10db59['id'],'name':_0x10db59['name'],'creator':_0x10db59['creatorId']?_0x13b9d8['getUser'](_0x10db59['creatorId']):null,'diffData':_0x10db59['diffData']||_0x10db59['data'],'authors':_0x10db59['authorsIds']['map'](_0x13b1d3=>_0x13b9d8['getUser'](_0x13b1d3)),'createdAt':new Date(_0x10db59['createdAt']),'attributes':_0x10db59['attributes'],'fromVersion':_0x10db59['fromVersion'],'toVersion':_0x10db59['toVersion']});}['addRevision'](_0x16c112,_0x31497e=0x0){this['_revisions']['add'](_0x16c112,_0x31497e);}['getRevision'](_0x1ee84d){return this['_revisions']['get'](_0x1ee84d);}['getRevisions'](_0x564d92={'toJSON':!0x1}){const _0x43bb29=Array['from'](this['_revisions']);return _0x43bb29['reverse'](),_0x564d92['toJSON']?_0x43bb29['map'](_0x352a0d=>_0x352a0d['toJSON']()):_0x43bb29;}['getIndex'](_0x10eb0c){return this['_revisions']['getIndex'](_0x10eb0c);}['getEarlierVisibleRevision'](_0x12d8b3){const [,_0x2e4f5c]=this['getRevisionsIterator'](_0x12d8b3,{'direction':'earlier'});return _0x2e4f5c;}['getLaterVisibleRevision'](_0x4dc05d){const [,_0x10c2cd]=this['getRevisionsIterator'](_0x4dc05d,{'direction':'later'});return _0x10c2cd;}['getRevisionsInDiff'](_0x3c5568){const _0x293f83=[];for(const _0x48f256 of this['getRevisionsIterator'](_0x3c5568['newRevisionId']))if(_0x293f83['push'](_0x48f256),_0x48f256['id']===_0x3c5568['oldRevisionId'])break;return _0x293f83;}*['getRevisionsIterator'](_0x1a8274,{direction:_0x14cde7='earlier',filter:_0x52d594=()=>!0x0}={}){const _0x3e4cfd='earlier'===_0x14cde7?0x1:-0x1;let _0x2c8ee8=this['_revisions']['get'](_0x1a8274),_0x5433eb=this['getIndex'](_0x2c8ee8);for(yield _0x2c8ee8;_0x2c8ee8;){if(_0x5433eb+=_0x3e4cfd,_0x2c8ee8=this['getRevision'](_0x5433eb),!_0x2c8ee8)return;_0x52d594(_0x2c8ee8)&&(yield _0x2c8ee8);}}}class $ extends _0x235b76{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x3f3e5a,'c'],[_0x56ffeb,'a'],[_0x5585ef,'e'],[_0x478f62,'r'],[_0x1e5a5c,'u']]);['_typeCharToViewClass']=new Map([['c',_0x3f3e5a],['a',_0x56ffeb],['e',_0x5585ef],['r',_0x478f62],['u',_0x1e5a5c]]);async['loadRevisionData'](_0x5b32b6,_0x31e798){if(_0x5b32b6['diffData']||!_0x31e798)return;const _0x4ad86e=this['editor']['config']['get']('collaboration.channelId'),_0x388d09=await _0x31e798['getRevision']({'channelId':_0x4ad86e,'revisionId':_0x5b32b6['id']});_0x5b32b6['diffData']=_0x388d09['diffData'];}['getRevisionDocumentData'](_0x3b0e0c){const _0x3867b1={};for(const _0x129422 in _0x3b0e0c['diffData']){if(_0x3b0e0c['diffData'][_0x129422]['attachChange']&&!_0x3b0e0c['diffData'][_0x129422]['attachChange']['isAttached'])continue;const _0x49ca61=this['_removeRevisionMarkers'](JSON['parse'](_0x3b0e0c['diffData'][_0x129422]['insertions'])),_0x55d215=this['editor']['editing']['view']['document'],_0x14d7b8=new _0x1daad2(_0x55d215,_0x49ca61['map'](_0xb3dafa=>this['_getViewFromDiffObj'](_0xb3dafa,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x3867b1[_0x129422]=this['editor']['data']['processor']['toData'](_0x14d7b8),this['editor']['data']['processor']['useFillerType']('default');}return _0x3867b1;}['getRevisionRootsAttributes'](_0x7b3bf3){const _0x4cb573={};for(const _0x6e4748 in _0x7b3bf3['diffData'])_0x7b3bf3['diffData'][_0x6e4748]['attachChange']&&!_0x7b3bf3['diffData'][_0x6e4748]['attachChange']['isAttached']||(_0x4cb573[_0x6e4748]=_0x7b3bf3['diffData'][_0x6e4748]['attributesAfter']||{});return _0x4cb573;}['_getTypeCharForViewElement'](_0x1528d7){return this['_viewClassToTypeChar']['get'](_0x1528d7['constructor']);}['_getViewFromDiffObj'](_0x50317d,_0x1033ac){const _0x4a20bd=this['editor']['editing']['view']['document'];if('string'==typeof _0x50317d)return new _0x2ab4f3(_0x4a20bd,_0x50317d);{let _0x254102,_0x1eec78;_0x1eec78='u'==_0x50317d['type']||'r'==_0x50317d['type']?[]:_0x50317d['children']['map'](_0x4e35ee=>this['_getViewFromDiffObj'](_0x4e35ee,_0x1033ac));const _0x749dea=this['_typeCharToViewClass']['get'](_0x50317d['type'])||_0x505201,_0x317b37=this['editor']['data']['htmlProcessor']['domConverter'];if(_0x254102=new _0x749dea(_0x4a20bd,_0x50317d['name'],_0x50317d['attributes'],_0x1eec78),'u'==_0x50317d['type']&&_0x50317d['children'][0x0]){const _0x5f1334=_0x50317d['children'][0x0];if(_0x254102['render']=function(_0x427b95){const _0x5063ae=_0x427b95['createElement']('div');return _0x5063ae['innerHTML']=_0x5f1334,_0x5063ae['childNodes'][0x0];},_0x1033ac){const _0x287292=new _0x1daad2(_0x4a20bd);_0x287292['_appendChild'](_0x254102);const _0x1ee05a=Array['from'](_0x317b37['viewChildrenToDom'](_0x287292,{'bind':!0x1})),_0x7a01e8=_0x317b37['domDocument']['createElement']('div');_0x7a01e8['append'](..._0x1ee05a),_0x254102=Array['from'](_0x317b37['domChildrenToView'](_0x7a01e8))[0x0];}}else{if('r'==_0x50317d['type']&&_0x50317d['children'][0x0]){const _0x233711=_0x50317d['children'][0x0];if(_0x254102['render']=function(_0x4a4ce5){_0x4a4ce5['innerHTML']=_0x233711;},_0x1033ac){const _0xcd3c8c=new _0x1daad2(_0x4a20bd);_0xcd3c8c['_appendChild'](_0x254102);const _0x2a7e02=Array['from'](_0x317b37['viewChildrenToDom'](_0xcd3c8c,{'bind':!0x1})),_0xdfcaf4=_0x317b37['domDocument']['createElement']('div');_0xdfcaf4['append'](..._0x2a7e02);const _0x47f924=Array['from'](_0x317b37['domChildrenToView'](_0xdfcaf4));_0x47f924['length']>0x1?_0x254102['_appendChild'](_0x47f924):_0x254102=_0x47f924[0x0];}}}if(_0x50317d['customProperties']){for(const [_0x2fecb8,_0x537cf8]of _0x50317d['customProperties'])_0x254102['_setCustomProperty'](_0x2fecb8,_0x537cf8);}const _0x5aec2d=void 0x0===_0x50317d['fillerOffset']?null:_0x50317d['fillerOffset'];return null!==_0x5aec2d&&(_0x254102['getFillerOffset']=()=>_0x5aec2d),_0x254102;}}['_makeModelFromViewString'](_0x3a4176){const _0x5c5ccc=JSON['parse'](_0x3a4176),_0x4f4cee=this['editor']['editing']['view']['document'],_0x2edadf=new _0x1daad2(_0x4f4cee,_0x5c5ccc['map'](_0x24a131=>this['_getViewFromDiffObj'](_0x24a131,!0x0)));return this['editor']['data']['toModel'](_0x2edadf);}['_removeRevisionMarkers'](_0x193480){return(_0x193480=_0x193480['filter'](_0x438c0f=>!_0x438c0f['name']||'revision-start'!==_0x438c0f['name']&&'revision-end'!==_0x438c0f['name']))['forEach'](_0x20e9f8=>{'string'!=typeof _0x20e9f8&&(_0x20e9f8['children']=this['_removeRevisionMarkers'](_0x20e9f8['children']),_0x20e9f8['attributes']=_0x20e9f8['attributes']['filter'](_0x19ed18=>!_0x19ed18[0x0]['startsWith']('data-revision-')));}),_0x193480;}}function R(_0x5d3310,_0x198597,_0x398005){const t=_0x5d3310['t'];switch(_0x198597){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'},_0x398005);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x398005);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 _0x235b76{['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[_0x34eefc,S,$,_0x360008];}constructor(_0x396b32){super(_0x396b32),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 _0x4f5d09=_0x1b5d50();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x4f5d09},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 _0x335906=this['repository']['getRevision'](0x0),_0x3b2f38=_0x335906&&null===_0x335906['creator']?_0x335906:null;if(this['_continueCurrentRevision']=!!_0x3b2f38&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x5f57bc=this['_source']['getCurrentRevisionId'](),_0x2e8c11=this['repository']['getRevision'](_0x5f57bc);if(_0x2e8c11)this['_startingVersion']=_0x2e8c11['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x59e9d0=this['_source']['history']['_operations']['find'](_0x450209=>!_0x450209['_isInit']),_0x58215b=_0x59e9d0?_0x59e9d0['baseVersion']:this['_source']['history']['version'];_0x335906?(_0x335906['toVersion']<_0x58215b&&_0x335906['_update']({'toVersion':_0x58215b}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x3b2f38['id'],this['_startingVersion']=_0x3b2f38['fromVersion']):(this['_startingVersion']=_0x335906['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x58215b,this['_continueCurrentRevision']=!0x1);}}else _0x3b2f38&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x3b2f38['toVersion'],this['editor']['model']['document']['history']['version']),_0x3b2f38['fromVersion']===_0x3b2f38['toVersion']?(0x0!==_0x3b2f38['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x3b2f38['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x3b2f38['id'],this['_startingVersion']=_0x3b2f38['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',_0x59ff31=>!_0x59ff31),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x5747f2=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x30b631;for(const _0x154b10 in _0x5747f2){const _0x50f5cf=_0x154b10,_0x589680=_0x5747f2[_0x50f5cf];if('revisionHistoryLicenseKeyValid'==_0x589680||'revisionHistoryLicenseKeyInvalid'==_0x589680||'revisionHistoryLicenseKeyExpired'==_0x589680||'revisionHistoryLicenseKeyDomainLimit'==_0x589680||'revisionHistoryLicenseKeyNotAllowed'==_0x589680||'revisionHistoryLicenseKeyEvaluationLimit'==_0x589680||'revisionHistoryLicenseKeyTrialLimit'==_0x589680||'revisionHistoryLicenseKeyUsageLimit'==_0x589680){delete _0x5747f2[_0x50f5cf],_0x30b631=_0x589680,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x30b631&&_0x5747f2['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x30b631&&_0x5747f2['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x30b631&&_0x5747f2['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x30b631&&_0x5747f2['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x30b631&&_0x5747f2['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x30b631&&_0x5747f2['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x30b631&&_0x5747f2['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x273e72=this['repository']['getRevision'](0x0),_0x33b406=await this['getRevisionDocumentData'](_0x273e72),_0x5b62e2=await this['getRevisionRootsAttributes'](_0x273e72);this['_replaceEditorDataWithRevisionData'](_0x33b406,_0x5b62e2);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x31d379){this['_source']=_0x31d379;}async['update'](){const _0x50d140=await this['_source']['getLatestVersion']();if(_0x50d140>this['currentRevision']['toVersion']){await this['_loadState']();const _0x29935d=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x50d140});_0x29935d['authors']=_0x29935d['authorsIds']['map'](_0x3c676d=>this['editor']['plugins']['get']('Users')['getUser'](_0x3c676d)),this['currentRevision']['_update'](_0x29935d);}}async['saveRevision'](_0x2e3adf={},_0x4b0f3d=null){const _0x460823=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x4b0f3d>this['currentRevision']['toVersion']&&(_0x4b0f3d=null),null===_0x4b0f3d&&(_0x4b0f3d=await this['_source']['getLatestVersion']());const _0x155729=this['_getFromVersion'](_0x4b0f3d),_0x3449cf=this['buildRevisionData']({'from':_0x155729,'to':_0x4b0f3d});if(this['currentRevision']['toVersion']<_0x4b0f3d){const _0x22cb45=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x4b0f3d,'to':_0x4b0f3d});_0x22cb45['authors']=[],_0x22cb45['authorsIds']=[],_0x22cb45['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x22cb45,!0x0),delete _0x22cb45['authors'],_0x460823['push'](_0x22cb45);}_0x2e3adf['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x2e3adf['name']=_0x2e3adf['name']||null,_0x2e3adf['id']=_0x2e3adf['id']||_0x1b5d50(),_0x2e3adf={..._0x2e3adf,..._0x3449cf};const _0x436191=this['addRevisionData'](_0x2e3adf);_0x460823['push'](_0x2e3adf);const _0x23f3c8=this['repository']['getIndex'](_0x436191);if(0x0!==_0x23f3c8){const _0x43c8a1=this['repository']['getRevision'](_0x23f3c8-0x1);if(_0x43c8a1['fromVersion']!==_0x4b0f3d){const _0x24f5a7=this['_revisionDataBuilder']['getData'](_0x4b0f3d,_0x43c8a1['toVersion']),_0x5e89b1={'id':_0x43c8a1['id'],'diffData':_0x24f5a7['diffData'],'authorsIds':_0x24f5a7['authorsIds'],'authors':_0x24f5a7['authorsIds']['map'](_0x5f5ac3=>this['editor']['plugins']['get']('Users')['getUser'](_0x5f5ac3)),'fromVersion':_0x4b0f3d};_0x43c8a1===this['currentRevision']&&(_0x5e89b1['createdAt']=new Date(_0x2e3adf['createdAt']['getTime']()+0xa)),_0x43c8a1['_update'](_0x5e89b1,!0x0),delete _0x5e89b1['authors'],_0x460823['push'](_0x5e89b1);}}if(this['adapter']){for(const _0x8bac61 of _0x460823)this['_bufferUpdate'](_0x8bac61['id'],_0x8bac61,!0x0);this['sendBufferedUpdates']();}return _0x436191;}['addRevisionData'](_0x2952eb){const _0xd28568=this['repository']['createRevision'](_0x2952eb);return this['adapter']&&_0xd28568['on']('_update',(_0x3c1343,_0x217e92,_0x4adc70)=>{_0x4adc70||(this['_bufferUpdate'](_0x217e92['id'],_0x217e92,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0xd28568,this['_findInsertionIndex'](_0xd28568)),_0xd28568;}async['getRevisionDocumentData'](_0x227409){return await this['_utils']['loadRevisionData'](_0x227409,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x227409);}async['getRevisionRootsAttributes'](_0x2c0018){return await this['_utils']['loadRevisionData'](_0x2c0018,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x2c0018);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x397f0b=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x5bf81d=0x0;_0x5bf81d<_0x397f0b['length'];_0x5bf81d++){const _0x15b132=_0x397f0b[_0x5bf81d];let _0x3e3bef=!0x1;for(const _0x451f1b of Object['keys'](_0x15b132))void 0x0===_0x15b132[_0x451f1b]?delete _0x15b132[_0x451f1b]:'id'!==_0x451f1b&&(_0x3e3bef=!0x0);_0x3e3bef||(_0x397f0b[_0x5bf81d]=null);}if(_0x397f0b=_0x397f0b['filter'](_0x465a9f=>null!==_0x465a9f),!_0x397f0b['length'])return;for(let _0x4e5f5d=0x0;_0x4e5f5d<_0x397f0b['length'];_0x4e5f5d++){const _0x23c5ea=_0x397f0b[_0x4e5f5d];void 0x0!==_0x23c5ea['fromVersion']&&void 0x0===_0x23c5ea['toVersion']&&(_0x23c5ea['toVersion']=this['repository']['getRevision'](_0x23c5ea['id'])['toVersion']),void 0x0!==_0x23c5ea['toVersion']&&void 0x0===_0x23c5ea['fromVersion']&&(_0x23c5ea['fromVersion']=this['repository']['getRevision'](_0x23c5ea['id'])['fromVersion']);}const _0x2eee95=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x397f0b,_0x2eee95)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0xed57c1=>{if(_0xed57c1){for(const _0x39f5ad of _0xed57c1)this['setRevisionData']({'id':_0x39f5ad['id'],'createdAt':_0x39f5ad['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0x58713b=null,from:_0x4090c1=null,to:_0x3719f7=null}){_0x4090c1=null!==_0x4090c1?_0x4090c1:_0x58713b['fromVersion'],_0x3719f7=null!==_0x3719f7?_0x3719f7:_0x58713b['toVersion'];const _0x1af56c=this['_revisionDataBuilder']['getData'](_0x4090c1,_0x3719f7),_0x5df2f2={'diffData':_0x1af56c['diffData'],'authorsIds':_0x1af56c['authorsIds'],'fromVersion':_0x4090c1,'toVersion':_0x3719f7};if(!_0x58713b||_0x3719f7!==_0x58713b['toVersion']){const _0x5e15fa=_0x3719f7-0x1,_0x3703cb=this['_source']['history']['getOperation'](_0x5e15fa);_0x5df2f2['createdAt']=_0x3703cb&&_0x3703cb['createdAt']||new Date();}if(this['_loadedStateData']&&_0x4090c1===this['_loadedStateData']['fromVersion']){for(const _0x15cbdb of this['_loadedStateData']['authors'])_0x5df2f2['authorsIds']['includes'](_0x15cbdb['id'])||_0x5df2f2['authorsIds']['push'](_0x15cbdb['id']);}return _0x5df2f2;}['_bufferUpdate'](_0x1ef3b5,_0x122b7f,_0x5dca05){if(this['_bufferedUpdates']['has'](_0x1ef3b5)){const _0xee399=this['_bufferedUpdates']['get'](_0x1ef3b5);_0x122b7f=_0x5dca05?{..._0xee399,..._0x122b7f}:{..._0x122b7f,..._0xee399};}this['_bufferedUpdates']['set'](_0x1ef3b5,_0x122b7f);}['setRevisionData'](_0x2b543a){const _0x184480=this['repository']['getRevision'](_0x2b543a['id']);if(_0x2b543a['createdAt']&&(_0x2b543a['createdAt']=new Date(_0x2b543a['createdAt'])),_0x2b543a['authorsIds']){const _0x6f73b8=this['editor']['plugins']['get']('Users');_0x2b543a['authors']=_0x2b543a['authorsIds']['map'](_0x1e358c=>_0x6f73b8['getUser'](_0x1e358c));}_0x184480['_update'](_0x2b543a,!0x0);}['_createInitialRevision'](_0x9cde95){const _0x22abea=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x22abea)this['_initialRevisionId']=_0x22abea['id'];else{const _0x11d022=!this['editor']['model']['document']['roots']['find'](_0x450251=>this['editor']['model']['hasContent'](_0x450251)),_0x598bd4=this['editor']['plugins']['get']('Users')['me']['id'],_0x24e4d6=R(this['editor']['locale'],_0x11d022?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x9cde95,'to':_0x9cde95,'id':this['_initialRevisionId'],'name':_0x24e4d6,'creatorId':_0x598bd4});}}['_createCurrentRevision'](_0x4fd42d){const _0x591cc1=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x591cc1),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x4fd42d,'to':_0x4fd42d,'id':_0x591cc1,'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'](_0x567af5,_0x5b5dc9){let _0xc70c1f=this['editor']['config']['get']('initialData'),_0x557257=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0xc70c1f){_0xc70c1f={};for(const _0x1540b4 of this['editor']['model']['document']['getRootNames']())_0xc70c1f[_0x1540b4]='';}if('string'==typeof _0xc70c1f&&(_0xc70c1f={'main':_0xc70c1f}),void 0x0===_0x557257){_0x557257={};for(const _0x31362c of this['editor']['model']['document']['getRootNames']())_0x557257[_0x31362c]={};}let _0x35e04c=!0x1;const _0x343698=Object['keys'](_0xc70c1f),_0x5c76af=Object['keys'](_0x567af5);for(const _0x297049 of _0x343698){if(_0xc70c1f[_0x297049]!==_0x567af5[_0x297049]&&''!==_0xc70c1f[_0x297049]['trim']()){_0x35e04c=!0x0;break;}if(!_0x2b6e41(_0x557257[_0x297049],_0x5b5dc9[_0x297049])&&Object['keys'](_0x557257[_0x297049])['length']>0x0){_0x35e04c=!0x0;break;}}_0x35e04c||(_0x35e04c=_0x5c76af['some'](_0x1acc80=>!this['editor']['model']['document']['getRoot'](_0x1acc80))),_0x35e04c&&_0x7ece4e('editor-initial-data-replaced-with-revision-data',{'editorData':_0xc70c1f,'editorRootsAttributes':_0x557257,'revisionData':_0x567af5,'revisionRootsAttributes':_0x5b5dc9}),this['editor']['config']['set']('initialData',_0x567af5),this['editor']['config']['set']('rootsAttributes',_0x5b5dc9);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x534519=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x534519['add'](R(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x253cc5){const _0x4fc80d=this['repository']['getRevisions']();_0x4fc80d['reverse']();let _0x106538=0x0;for(;_0x106538<_0x4fc80d['length'];){const _0x3d69bb=_0x4fc80d[_0x106538];if(_0x3d69bb===this['currentRevision']){_0x106538++;continue;}if(_0x3d69bb['id']===this['_initialRevisionId'])break;const _0x6db859=_0x253cc5['toVersion']-_0x3d69bb['toVersion']||_0x253cc5['fromVersion']-_0x3d69bb['fromVersion'];if(_0x6db859>0x0)break;if(_0x6db859<0x0)_0x106538++;else{if(!_0x253cc5['creator']&&_0x3d69bb['creator'])break;if(_0x3d69bb['creator']||!_0x253cc5['creator']){if(_0x253cc5['createdAt']>_0x3d69bb['createdAt'])break;_0x106538++;}else _0x106538++;}}return _0x106538;}['_getFromVersion'](_0x567910){const _0x4e8c0f=this['repository']['getRevisions']();_0x4e8c0f['reverse'](),_0x4e8c0f['shift']();const _0x20c624=_0x4e8c0f['find'](_0xe52e68=>_0xe52e68['toVersion']<=_0x567910)['toVersion'];return _0x20c624<this['_startingVersion']?this['_startingVersion']:_0x20c624;}['_makeRevision']({name:_0x215644,from:_0x30bea5,to:_0x62f686,creatorId:_0x1d6e61,id:_0x2f7b19}){const _0x5c0ba2=this['buildRevisionData']({'from':_0x30bea5,'to':_0x62f686});_0x5c0ba2['name']=_0x215644,_0x5c0ba2['creatorId']=_0x1d6e61,_0x5c0ba2['id']=_0x2f7b19;const _0x183d0f=this['addRevisionData'](_0x5c0ba2);return this['adapter']&&this['_bufferUpdate'](_0x5c0ba2['id'],_0x5c0ba2,!0x0),_0x183d0f;}['_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(_0x1fcb8f){this['editor']=_0x1fcb8f,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'](_0x44009b){this['source']=_0x44009b;const _0x534280=new Map(),_0x5f2999=new Map(),_0x155792=this['editor']['model']['document']['roots']['map'](_0x16c8bb=>_0x16c8bb['rootName']);for(const _0x369a5d of _0x155792){const _0x529727=this['editor']['model']['document']['getRoot'](_0x369a5d),_0x8de451=x(_0x529727);_0x534280['set'](_0x369a5d,_0x8de451),_0x5f2999['set'](_0x369a5d,Object['fromEntries'](_0x529727['getAttributes']()));}const _0x185622=Array['from'](this['editor']['model']['markers'])['map'](_0x58b3fa=>[_0x58b3fa['name'],_0x58b3fa['getRange']()]),_0x4eb084=this['source']['version'];this['_saveMetaData'](_0x4eb084,_0x534280,_0x185622,_0x5f2999),this['_startingRevisionId']=this['_revisionId'];const _0x4e0461=new Map(),_0x206600=new Map();for(const _0x52d032 of _0x155792){const _0x29d856=N(_0x52d032);_0x4e0461['set'](_0x52d032,_0x29d856),_0x206600['set'](_0x52d032,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x4e0461,[],_0x206600);}['getData'](_0x5f2ecc,_0x3332cb){if(this['_lastFrom']===_0x5f2ecc&&this['_lastTo']<=_0x3332cb)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x3332cb,!0x0);else{if(!this['_savedMetaData']['has'](_0x5f2ecc)){const _0x4e48b6=this['_getPreviousFrom'](_0x5f2ecc);this['_calculateMetaData'](_0x4e48b6,_0x5f2ecc,!0x1);}this['_calculateMetaData'](_0x5f2ecc,_0x3332cb,!0x0);}return this['_lastFrom']=_0x5f2ecc,this['_lastTo']=_0x3332cb,this['_getState']();}['loadState'](_0x4d064b){const _0x252485=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x4d064b['fromVersion'],this['_lastTo']=_0x4d064b['toVersion'];for(const _0x11054e in _0x4d064b['diffData']){const _0x21a847=_0x4d064b['diffData'][_0x11054e]['attachChange'],_0x493d35=_0x186599(_0x4d064b['diffData'][_0x11054e]['attributesBefore'])||{},_0x28652d=_0x252485['_makeModelFromViewString'](_0x4d064b['diffData'][_0x11054e]['deletions']);_0x28652d['rootName']=_0x11054e,_0x28652d['_isAttached']=!_0x21a847||!_0x21a847['isAttached'],_0x28652d['isAttached']=()=>_0x28652d['_isAttached'],this['_baseRoots']['set'](_0x11054e,_0x28652d),this['_baseRootsAttributes']['set'](_0x11054e,_0x493d35),_0x21a847&&this['_touchedRoots']['set'](_0x11054e,_0x21a847);const _0x39028d=this['_makeIdsRoot'](_0x28652d);this['_baseIdsRoots']['set'](_0x11054e,_0x39028d);for(const [_0x251c1f,_0x2360ca]of _0x28652d['markers']){if(!_0x251c1f['startsWith']('revision:'))continue;const _0x4d8cd7=_0x251c1f['split'](':')[0x2];for(const _0x1144b8 of _0x2360ca['getWalker']({'singleCharacters':!0x0})){const _0x56c361=this['_getVidAttributeName'](_0x1144b8),_0x1d160a='elementEnd'==_0x1144b8['type']?_0x1144b8['previousPosition']['path']['slice'](0x0,-0x1):_0x1144b8['previousPosition']['path'],_0x2cc688=_0x39028d['getNodeByPath'](_0x1d160a)['getAttribute'](_0x56c361);this['_touched']['set'](_0x2cc688,{'userId':_0x4d8cd7});}}}this['_startingRevisionId']=this['_revisionId'];const _0x47e4d5=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x2d9f80=>!this['_touched']['has'](_0x2d9f80));let _0x154b43=0x0;const _0x285084=new Map();for(const _0x1ec005 in _0x4d064b['diffData']){const _0x100dc7=_0x4d064b['diffData'][_0x1ec005]['attachChange'],_0x3753f9=_0x186599(_0x4d064b['diffData'][_0x1ec005]['attributesAfter'])||{},_0x58236d=_0x252485['_makeModelFromViewString'](_0x4d064b['diffData'][_0x1ec005]['insertions']);_0x58236d['rootName']=_0x1ec005,_0x58236d['_isAttached']=!_0x100dc7||_0x100dc7['isAttached'],_0x58236d['isAttached']=()=>_0x58236d['_isAttached'],this['_diffRoots']['set'](_0x1ec005,_0x58236d),this['_diffRootsAttributes']['set'](_0x1ec005,_0x3753f9);const _0x4de132=this['_makeIdsRoot'](_0x58236d,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x1ec005,_0x4de132),_0x285084['set'](_0x1ec005,_0x58236d['isAttached']()?_0x3753f9:{});for(const [_0xe13652,_0x21a89b]of _0x58236d['markers']){if(!_0xe13652['startsWith']('revision:'))continue;const _0x5c069f=_0xe13652['split'](':')[0x2];for(const _0x3e1a7a of _0x21a89b['getWalker']({'singleCharacters':!0x0})){const _0x5b7ec1=this['_getVidAttributeName'](_0x3e1a7a),_0x4b1e07=this['_revisionId']++,_0x5ea0df='elementEnd'==_0x3e1a7a['type']?_0x3e1a7a['previousPosition']['path']['slice'](0x0,-0x1):_0x3e1a7a['previousPosition']['path'];_0x4de132['getNodeByPath'](_0x5ea0df)['_setAttribute'](_0x5b7ec1,_0x4b1e07),this['_touched']['set'](_0x4b1e07,{'userId':_0x5c069f});}}for(const _0x382af2 of this['editor']['model']['createRangeIn'](_0x58236d)['getWalker']({'singleCharacters':!0x0})){const _0x2c7a9c=this['_getVidAttributeName'](_0x382af2),_0x39e61f='elementEnd'==_0x382af2['type']?_0x382af2['previousPosition']['path']['slice'](0x0,-0x1):_0x382af2['previousPosition']['path'],_0xdb1dd5=_0x4de132['getNodeByPath'](_0x39e61f);_0xdb1dd5['getAttribute'](_0x2c7a9c)>0x0||_0xdb1dd5['_setAttribute'](_0x2c7a9c,_0x47e4d5[_0x154b43++]);}for(const [_0x28e1ba,_0x51981a]of _0x58236d['markers'])_0x28e1ba['startsWith']('revision:')||this['_markers']['set'](_0x28e1ba,_0x51981a);}const _0x5da046=N('$graveyard');this['_baseRoots']['set']('$graveyard',_0x5da046),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x5da046,0x1));const _0xe02e9=N('$graveyard');this['_diffRoots']['set']('$graveyard',_0xe02e9),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0xe02e9,0x1));const _0x372455=Array['from'](this['_diffRoots'])['map'](([_0x328657,_0x422101])=>[_0x328657,x(_0x422101)]);this['_saveMetaData'](this['_lastTo'],_0x372455,this['_markers'],_0x285084);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0x627f27,_0x17cfd1,_0x1c47b7,_0x50f069){const _0xa62f7a=new Map(_0x17cfd1),_0xfcdaa0=new Map(_0x186599(_0x50f069)),_0x55a269=new Map();for(const [_0x594abb,_0x2cf8e0]of _0x1c47b7)_0x55a269['set'](_0x594abb,{'start':_0x2cf8e0['start']['clone'](),'end':_0x2cf8e0['end']['clone'](),'rootName':_0x2cf8e0['root']['rootName']});this['_savedMetaData']['set'](_0x627f27,{'roots':_0xa62f7a,'markers':_0x55a269,'rootsAttributes':_0xfcdaa0});}['_removeMetaData'](_0x55207f){this['_savedMetaData']['delete'](_0x55207f);}['_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'](_0x40b11f,_0x2b5d07=null){let _0x5e1aa1=null;_0x40b11f['is']('documentFragment')||(_0x5e1aa1=new _0x11a5c7(_0x40b11f['name'],{'vid_start':null===_0x2b5d07?this['_revisionId']++:_0x2b5d07++}));const _0x3d7111=[];for(const _0x10f175 of _0x40b11f['getChildren']())if(_0x10f175['is']('element')){_0x3d7111['push'](this['_makeIdsRoot'](_0x10f175,_0x2b5d07));const _0x2a6c27=_0x3d7111[_0x3d7111['length']-0x1];null!==_0x2b5d07&&(_0x2b5d07=_0x2a6c27['is']('element','$text')?_0x2a6c27['getAttribute']('vid')+0x1:_0x2a6c27['getAttribute']('vid_end')+0x1);}else{for(let _0x1226f6=0x0;_0x1226f6<_0x10f175['offsetSize'];_0x1226f6++)_0x3d7111['push'](new _0x11a5c7('$text',{'vid':null===_0x2b5d07?this['_revisionId']++:_0x2b5d07++}));}if(_0x40b11f['is']('documentFragment')){const _0x220b95=N(_0x40b11f['rootName']);return _0x220b95['_insertChild'](0x0,_0x3d7111),_0x220b95;}return _0x5e1aa1['_setAttribute']('vid_end',null===_0x2b5d07?this['_revisionId']++:_0x2b5d07++),_0x5e1aa1['_insertChild'](0x0,_0x3d7111),_0x5e1aa1;}['_calculateMetaData'](_0x425895,_0x3fa86e,_0x5ac94d){this['_reset']();const {roots:_0x5c7b69,markers:_0x2795ef,rootsAttributes:_0x391188}=this['_savedMetaData']['get'](_0x425895);this['_baseRoots']=new Map(_0x5c7b69),this['_baseRootsAttributes']=new Map(_0x186599(_0x391188));for(const [_0x35d4b5,_0x32ce35]of this['_baseRoots'])if('$graveyard'!==_0x35d4b5&&(this['_diffRoots']['set'](_0x35d4b5,x(_0x32ce35)),this['_diffRootsAttributes']=new Map(_0x186599(_0x391188)),_0x5ac94d)){const _0x4d6427=this['_revisionId'];this['_idsRoots']['set'](_0x35d4b5,this['_makeIdsRoot'](_0x32ce35)),this['_baseIdsRoots']['set'](_0x35d4b5,this['_makeIdsRoot'](_0x32ce35,_0x4d6427));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',x(this['_baseRoots']['get']('$graveyard'))),_0x5ac94d&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x45a44f,_0x265e89]of _0x2795ef){const _0x56392e=this['_baseRoots']['get'](_0x265e89['rootName']),_0x47772a=this['_diffRoots']['get'](_0x265e89['rootName']),_0x515499=new _0x150733(this['_fixPosition'](_0x265e89['start'],_0x56392e),this['_fixPosition'](_0x265e89['end'],_0x56392e)),_0x244df3=this['_fixRange'](_0x515499,_0x47772a);_0x56392e['markers']['set'](_0x45a44f,_0x515499),this['_markers']['set'](_0x45a44f,_0x244df3);}this['_applyOperations'](_0x425895,_0x3fa86e,_0x5ac94d);}['_applyOperations'](_0x26f574,_0x3ef0ed,_0x16aaf9){for(const _0x3b4480 of this['source']['getOperations'](_0x26f574,_0x3ef0ed))this['_handleOperation'](_0x3b4480,_0x16aaf9);for(const _0x4378a0 of this['_diffRoots']['values']())_0x4378a0['markers']['clear']();for(const [_0x52ceaa,_0x2edb91]of this['_markers']){this['_diffRoots']['get'](_0x2edb91['root']['rootName'])['markers']['set'](_0x52ceaa,_0x2edb91['clone']());}const _0x1a1f5e=new Map(),_0x53807e=new Map();for(const [_0x5b5ccd,_0xee22e4]of this['_diffRoots'])_0x1a1f5e['set'](_0x5b5ccd,x(_0xee22e4)),_0x53807e['set'](_0x5b5ccd,this['_diffRootsAttributes']['get'](_0x5b5ccd));this['_saveMetaData'](_0x3ef0ed,_0x1a1f5e,this['_markers'],_0x53807e);}['_getPreviousFrom'](_0x3594fb){const _0x11a724=Array['from'](this['_savedMetaData']['keys']());_0x11a724['sort']((_0x3300b2,_0x506b0b)=>_0x3300b2-_0x506b0b),_0x11a724['reverse']();for(const _0x1e1a22 of _0x11a724)if(_0x1e1a22<_0x3594fb)return _0x1e1a22;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0xfc9c3e,_0x50ed73){const _0x1cd832=Array['from'](_0x50ed73['markers'])['map'](([_0x57a84d,_0x286a6c])=>[_0x57a84d,this['_fixRange'](_0x286a6c,_0xfc9c3e)]);_0xfc9c3e['markers']=new Map(_0x1cd832);}['_transformMarkers'](_0x533328){for(const _0x2bd361 of this['_markers']['values']()){const _0xc23c57=_0x2bd361['getTransformedByOperation'](_0x533328),_0x10c7b6=_0x150733['_createFromRanges'](_0xc23c57);_0x2bd361['start']=_0x10c7b6['start'],_0x2bd361['end']=_0x10c7b6['end'];}}['_handleOperation'](_0x548814,_0x2393ae){if('addRoot'!=_0x548814['type']&&'detachRoot'!=_0x548814['type']){if('insert'==_0x548814['type']){const _0x1fc8e9=_0x548814['position']['root']['rootName'];this['_diffRoots']['has'](_0x1fc8e9)||(this['_diffRoots']['set'](_0x1fc8e9,N(_0x1fc8e9,!0x0)),this['_diffRootsAttributes']['set'](_0x1fc8e9,{}),_0x2393ae&&this['_idsRoots']['set'](_0x1fc8e9,N(_0x1fc8e9,!0x0)));}else{if('addRootAttribute'==_0x548814['type']||'removeRootAttribute'==_0x548814['type']||'changeRootAttribute'==_0x548814['type'])return void this['_handleRootAttributeOperation'](_0x548814);'marker'==_0x548814['type']&&this['_handleMarkerOperation'](_0x548814);}if('marker'!==_0x548814['type']){const _0x196341=this['_cloneOperation'](_0x548814,this['_diffRoots']);_0x196341['_execute'](),this['_transformMarkers'](_0x196341);}if(_0x2393ae)switch(_0x548814['type']){case'insert':this['_handleInsertOperation'](_0x548814);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x548814);break;case'merge':this['_handleMergeOperation'](_0x548814);break;case'split':this['_handleSplitOperation'](_0x548814);}}else this['_handleRootOperation'](_0x548814,_0x2393ae);}['_cloneOperation'](_0x507f32,_0x35b2e1){const _0x7180d1=_0x507f32['clone']();return _0x7180d1['_authorId']=_0x507f32['_authorId'],this['_fixOperation'](_0x7180d1,_0x35b2e1),_0x7180d1;}['_getBaseVids'](_0x15084f){return _0x15084f['map'](_0x5364cf=>{const _0x5a179a=this['_getVidAttributeName'](_0x5364cf);return Number(_0x5364cf['item']['getAttribute'](_0x5a179a));});}['_generateTape'](_0x42c07b,_0x55b6f7){if(_0x42c07b['is']('element','$text'))_0x55b6f7['push']({'item':_0x42c07b,'type':'text'});else{_0x42c07b['is']('element')&&_0x55b6f7['push']({'item':_0x42c07b,'type':'elementStart'});for(const _0x41fd13 of _0x42c07b['getChildren']())this['_generateTape'](_0x41fd13,_0x55b6f7);_0x42c07b['is']('element')&&_0x55b6f7['push']({'item':_0x42c07b,'type':'elementEnd'});}return _0x55b6f7;}['_getState'](){const _0x2f16ff=new Map(this['_touched']),_0x60bae3=new Map(_0x2f16ff),_0x4b6965=new Map(),_0x57c483={'insertions':{},'deletions':{}},_0xc1b704={'insertions':{},'deletions':{}},_0xb4b1f8=new Map(),_0x465c35=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x465c35['delete']('$graveyard');for(const _0x4ce582 of _0x465c35){const _0x483c82=this['_diffRoots']['get'](_0x4ce582)||N(_0x4ce582,!0x1),_0x1b3e52=this['_baseRoots']['get'](_0x4ce582)||N(_0x4ce582,!0x1);_0x483c82['isAttached']()||_0x1b3e52['isAttached']()?(_0x57c483['insertions'][_0x4ce582]=x(_0x483c82),_0x57c483['deletions'][_0x4ce582]=x(_0x1b3e52),this['_copyMarkers'](_0x57c483['deletions'][_0x4ce582],_0x1b3e52),this['_copyMarkers'](_0x57c483['insertions'][_0x4ce582],_0x483c82),_0xc1b704['insertions'][_0x4ce582]=this['_generateTape'](this['_idsRoots']['get'](_0x4ce582),[]),_0xc1b704['deletions'][_0x4ce582]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x4ce582)||N(_0x4ce582,!0x1),[])):_0x465c35['delete'](_0x4ce582);}for(const _0x2a0389 of _0x465c35){const _0x32d868=_0xc1b704['insertions'][_0x2a0389];for(const _0x197ab0 of _0x32d868){const _0x29ef42=this['_getVidAttributeName'](_0x197ab0),_0x100b4a=_0x197ab0['item']['getAttribute'](_0x29ef42);_0x60bae3['delete'](_0x100b4a),_0x100b4a>=this['_startingRevisionId']&&_0x4b6965['set'](_0x100b4a,_0x2f16ff['get'](_0x100b4a));}}for(const _0x33b8f of _0x465c35){const _0x967add=_0xc1b704['insertions'][_0x33b8f],_0x465d87=this['_getBaseVids'](_0xc1b704['deletions'][_0x33b8f]);let _0x418c05=0x0;for(const _0x41fa90 of _0x967add){const _0x13c964=this['_getVidAttributeName'](_0x41fa90),_0x3d2de1=_0x41fa90['item']['getAttribute'](_0x13c964);if(!_0x4b6965['has'](_0x3d2de1)&&!_0xb4b1f8['has'](_0x3d2de1)){if(_0x60bae3['has'](_0x3d2de1))_0x418c05++;else{if(_0x3d2de1!=_0x465d87[_0x418c05]){const _0x2c4cbf=_0x2f16ff['get'](_0x3d2de1)||_0x2f16ff['get'](_0x465d87[_0x418c05]);for(;_0x3d2de1!=_0x465d87[_0x418c05];)_0x60bae3['has'](_0x465d87[_0x418c05])||(_0xb4b1f8['set'](_0x465d87[_0x418c05],_0x2c4cbf),_0x2f16ff['set'](_0x465d87[_0x418c05],_0x2c4cbf)),_0x418c05++;}_0x418c05++;}}}}for(const _0x39fb2c of _0x465c35){const _0x2f95de=_0xc1b704['insertions'][_0x39fb2c];for(const _0x4dbaf7 of _0x2f95de){const _0x1ddd40=this['_getVidAttributeName'](_0x4dbaf7),_0x593791=_0x4dbaf7['item']['getAttribute'](_0x1ddd40);if(_0xb4b1f8['has'](_0x593791)){const _0x54d56f=_0xb4b1f8['get'](_0x593791);_0x60bae3['has'](_0x593791)||_0x60bae3['set'](_0x593791,{..._0x54d56f}),_0x4b6965['set'](_0x593791,{..._0x54d56f});}}}for(const _0x132ed0 of _0x60bae3['keys']())_0x132ed0>=this['_startingRevisionId']&&_0x60bae3['delete'](_0x132ed0);const _0x136bf0=new Map();for(const _0x32052f of _0x465c35){let _0x96e3ad=_0xc1b704['insertions'][_0x32052f];for(const _0x3dc28a of _0x96e3ad)if(_0x3dc28a['item']['is']('element','tableCell')){const _0x562b49=this['_getVidAttributeName'](_0x3dc28a),_0x54266f=_0x3dc28a['item']['getAttribute'](_0x562b49);if(_0x4b6965['has'](_0x54266f)){const _0x455ab2=_0x3dc28a['item']['parent']['parent']['getAttribute']('vid_start'),_0x261065=_0x136bf0['get'](_0x455ab2)||new Set();_0x261065['add'](_0x4b6965['get'](_0x54266f)['userId']),_0x136bf0['set'](_0x455ab2,_0x261065);}}_0x96e3ad=_0xc1b704['deletions'][_0x32052f];for(const _0x6eaa6d of _0x96e3ad)if(_0x6eaa6d['item']['is']('element','tableCell')){const _0x4f1a33=this['_getVidAttributeName'](_0x6eaa6d),_0x1396c7=_0x6eaa6d['item']['getAttribute'](_0x4f1a33);if(_0x60bae3['has'](_0x1396c7)){const _0x25b272=_0x6eaa6d['item']['parent']['parent']['getAttribute']('vid_start'),_0x4b9793=_0x136bf0['get'](_0x25b272)||new Set();_0x4b9793['add'](_0x60bae3['get'](_0x1396c7)['userId']),_0x136bf0['set'](_0x25b272,_0x4b9793);}}for(const _0x1e02db of _0x136bf0['keys']())(_0x4b6965['has'](_0x1e02db)||_0x60bae3['has'](_0x1e02db))&&_0x136bf0['delete'](_0x1e02db);}for(const _0x370b2b of _0x465c35){const _0x199aa5=_0xc1b704['insertions'][_0x370b2b];let _0x48d8ab=null,_0x160490=null;for(const _0x266206 of _0x199aa5){const _0x26018b=this['_getVidAttributeName'](_0x266206),_0x370040=_0x266206['item']['getAttribute'](_0x26018b),_0x3f2166=_0x136bf0['get'](_0x370040);_0x3f2166&&'elementStart'==_0x266206['type']&&(_0x48d8ab=Array['from'](_0x3f2166)[0x0],_0x160490=_0x266206['item']['getAttribute']('vid_end')),_0x48d8ab&&(_0x60bae3['set'](_0x370040,{'userId':_0x48d8ab}),_0x4b6965['set'](_0x370040,{'userId':_0x48d8ab})),_0x370040==_0x160490&&(_0x48d8ab=null,_0x160490=null);}}const _0x943589={},_0x48355a=new Set();for(const _0x48d9af of _0x465c35){const _0xcc29df=_0x57c483['deletions'][_0x48d9af],_0x43f90d=_0x57c483['insertions'][_0x48d9af];for(const {userId:_0xf013f1}of this['_touchedMarkers']['values']())null!==_0xf013f1&&_0x48355a['add'](_0xf013f1);for(const {userId:_0x1882a1}of this['_touchedRoots']['values']())null!==_0x1882a1&&_0x48355a['add'](_0x1882a1);this['_markChanges'](_0x43f90d,_0xc1b704['insertions'][_0x48d9af],_0x4b6965,'insertion',_0x48355a),this['_markChanges'](_0xcc29df,_0xc1b704['deletions'][_0x48d9af],_0x60bae3,'deletion',_0x48355a),_0x943589[_0x48d9af]={'insertions':this['_prepareViewToSave'](_0x43f90d),'deletions':this['_prepareViewToSave'](_0xcc29df),'attachChange':this['_touchedRoots']['get'](_0x48d9af)||null,'attributesBefore':_0x186599(this['_baseRootsAttributes']['get'](_0x48d9af))||{},'attributesAfter':_0x186599(this['_diffRootsAttributes']['get'](_0x48d9af))};}return{'diffData':_0x943589,'authorsIds':Array['from'](_0x48355a)};}['_processRootBeforeSave'](_0x37fda0){for(const [,_0x293335]of _0x37fda0['markers']){const _0x16b3b1=_0x293335['start']['getAncestors']()['filter'](_0x4e3bd5=>'tableCell'==_0x4e3bd5['name']);for(const _0x1351c4 of _0x16b3b1)0x1==_0x1351c4['childCount']&&_0x1351c4['getChild'](0x0)['is']('element','paragraph')&&_0x1351c4['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x1316b5){this['_processRootBeforeSave'](_0x1316b5);const _0x77b893=this['editor']['data']['toView'](_0x1316b5,{}),_0x1ee484=Array['from'](_0x77b893['getChildren']())['map'](_0x21097e=>this['_getViewJson'](_0x21097e));return JSON['stringify'](_0x1ee484);}['_getViewJson'](_0x998443){if(_0x998443['is']('$text'))return _0x998443['data'];{const _0x5955fe=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0x4e6d82=_0x998443,_0x638797=this['editor']['data']['htmlProcessor']['domConverter'],_0x23b65d={'type':_0x5955fe['_getTypeCharForViewElement'](_0x4e6d82),'name':_0x4e6d82['name'],'attributes':Array['from'](_0x4e6d82['getAttributes']()),'children':Array['from'](_0x4e6d82['getChildren']())['map'](_0x81569=>this['_getViewJson'](_0x81569))};if(_0x998443['is']('uiElement')&&'$comment'!=_0x998443['name']){const _0x31285d=_0x998443['render'](_0x638797['domDocument'],_0x638797);_0x23b65d['children']['push'](_0x31285d['outerHTML']);}else{if(_0x998443['is']('rawElement')){const _0x2da7d8=_0x638797['domDocument']['createElement'](_0x4e6d82['name']);_0x998443['render'](_0x2da7d8,_0x638797),_0x23b65d['children']['push'](_0x2da7d8['innerHTML']);}}const _0x48e62a=Array['from'](_0x4e6d82['getCustomProperties']());_0x48e62a['length']>0x0&&(_0x23b65d['customProperties']=_0x48e62a);const _0x11cd7a=_0x4e6d82['getFillerOffset']();return null!==_0x11cd7a&&(_0x23b65d['fillerOffset']=_0x11cd7a),_0x23b65d;}}['_markChanges'](_0x455465,_0x5d6689,_0xd9fa0e,_0x1503c9,_0x207a0c){let _0x286e7b=null,_0x37cd9e=null,_0x114404=0x0;const _0x4eae50=this['editor']['model'];for(let _0x349a83=0x0;_0x349a83<_0x5d6689['length'];_0x349a83++){const _0x4577cd=this['_getVidAttributeName'](_0x5d6689[_0x349a83]),_0x102b95=_0x5d6689[_0x349a83]['item']['getAttribute'](_0x4577cd),_0x3fc7e1=_0xd9fa0e['get'](_0x102b95),_0x176a64=_0x349a83==_0x5d6689['length']-0x1;(!_0x286e7b&&_0x3fc7e1&&(_0x286e7b=_0x3fc7e1,_0x37cd9e=_0x5d6689[_0x349a83]),_0x286e7b&&(!_0x3fc7e1||_0x3fc7e1['userId']!=_0x286e7b['userId']))&&(_0x7e6e6d(_0x3fc7e1,P(_0x37cd9e,_0x455465,_0x4eae50),P(_0x5d6689[_0x349a83],_0x455465,_0x4eae50)),_0x286e7b=_0x3fc7e1||null,_0x37cd9e=_0x3fc7e1?_0x5d6689[_0x349a83]:null),_0x286e7b&&_0x176a64&&_0x7e6e6d(_0x3fc7e1,P(_0x37cd9e,_0x455465,_0x4eae50),V(_0x5d6689[_0x349a83],_0x455465,_0x4eae50));}function _0x7e6e6d(_0x4afd75,_0x1856a6,_0x45eb73){const _0xa995a7=_0x286e7b['userId'],_0x35257f='revision:'+_0x1503c9+':'+_0xa995a7+':'+_0x114404++,_0x5b0fbe=_0x4eae50['createRange'](_0x1856a6,_0x45eb73);_0x455465['markers']['set'](_0x35257f,_0x5b0fbe),null!==_0xa995a7&&_0x207a0c['add'](_0xa995a7);}}['_getVidAttributeName'](_0xe8bed0){switch(_0xe8bed0['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x5f1b86,_0x220b9b){_0x5f1b86['baseVersion']=null;for(const _0x1edd77 in _0x5f1b86){const _0x31bdc7=_0x5f1b86[_0x1edd77];if(_0x31bdc7 instanceof _0x1112ca){const _0x4d306d=_0x220b9b['get'](_0x31bdc7['root']['rootName']);_0x5f1b86[_0x1edd77]=this['_fixPosition'](_0x31bdc7,_0x4d306d);}if(_0x31bdc7 instanceof _0x150733){const _0x21baca=_0x220b9b['get'](_0x31bdc7['root']['rootName']);_0x5f1b86[_0x1edd77]=this['_fixRange'](_0x31bdc7,_0x21baca);}'root'===_0x1edd77&&(_0x5f1b86['root']=_0x220b9b['get'](_0x5f1b86['root']['rootName']));}}['_fixRange'](_0x1a7df8,_0x51fae1){return this['editor']['model']['createRange'](this['_fixPosition'](_0x1a7df8['start'],_0x51fae1),this['_fixPosition'](_0x1a7df8['end'],_0x51fae1));}['_fixPosition'](_0x1a0985,_0x455768){return this['editor']['model']['createPositionFromPath'](_0x455768,_0x1a0985['path'],_0x1a0985['stickiness']);}['_handleInsertOperation'](_0x1e2e32){const _0x165c07=this['_idsRoots']['get'](_0x1e2e32['position']['root']['rootName']),_0x4893fa=this['_fixPosition'](_0x1e2e32['position'],_0x165c07),_0x9aef2e=null===_0x1e2e32['_authorId']?null:_0x1e2e32['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x5b403e=_0x4893fa['parent'],_0x26eafa=this['_revisionId'],_0x353f35=[];for(const _0x2db56d of _0x1e2e32['nodes'])if(_0x2db56d['is']('element'))_0x353f35['push'](this['_makeIdsRoot'](_0x2db56d));else{for(let _0x447a48=0x0;_0x447a48<_0x2db56d['offsetSize'];_0x447a48++)_0x353f35['push'](new _0x11a5c7('$text',{'vid':this['_revisionId']++}));}const _0x3b9f67=this['_revisionId'];for(let _0x54cd5d=_0x26eafa;_0x54cd5d<_0x3b9f67;_0x54cd5d++)this['_touched']['set'](_0x54cd5d,{'userId':_0x9aef2e});_0x5b403e['_insertChild'](_0x4893fa['offset'],_0x353f35);}['_handleMoveOperation'](_0x39d367){(_0x39d367=this['_cloneOperation'](_0x39d367,this['_idsRoots']))['_execute']();const _0x4ff321=null===_0x39d367['_authorId']?null:_0x39d367['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x3c93fa=_0x39d367['getMovedRangeStart'](),_0xb174f5=_0x3c93fa['parent'],_0x479ded=_0x3c93fa['offset'];!function _0x11f82b(_0x5525bb,_0x628ab9,_0xc1b8de,_0x2d5333){for(let _0x296b08=_0xc1b8de;_0x296b08<_0x2d5333;_0x296b08++){const _0x5bcd6f=_0x628ab9['getChild'](_0x296b08);_0x5bcd6f['is']('element','$text')?_0x5525bb['set'](_0x5bcd6f['getAttribute']('vid'),{'userId':_0x4ff321}):(_0x5525bb['set'](_0x5bcd6f['getAttribute']('vid_start'),{'userId':_0x4ff321}),_0x11f82b(_0x5525bb,_0x5bcd6f,0x0,_0x5bcd6f['childCount']),_0x5525bb['set'](_0x5bcd6f['getAttribute']('vid_end'),{'userId':_0x4ff321}));}}(this['_touched'],_0xb174f5,_0x479ded,_0x479ded+_0x39d367['howMany']);}['_handleMergeOperation'](_0x22689b){const _0x1810ca=null===(_0x22689b=this['_cloneOperation'](_0x22689b,this['_idsRoots']))['_authorId']?null:_0x22689b['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x927df6=_0x22689b['targetPosition']['parent'],_0x3e9856=_0x22689b['sourcePosition']['parent'],_0x851f31=_0x927df6['getAttribute']('vid_end'),_0x3d8e7a=_0x3e9856['getAttribute']('vid_start');_0x927df6['_setAttribute']('vid_end',_0x3e9856['getAttribute']('vid_end')),_0x3e9856['_setAttribute']('vid_end',_0x851f31),this['_touched']['set'](_0x3d8e7a,{'userId':_0x1810ca}),this['_touched']['set'](_0x851f31,{'userId':_0x1810ca}),_0x22689b['_execute']();}['_handleSplitOperation'](_0x2570e6){const _0xbe8841=null===(_0x2570e6=this['_cloneOperation'](_0x2570e6,this['_idsRoots']))['_authorId']?null:_0x2570e6['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x2d4b68=_0x2570e6['graveyardPosition'],_0x407ef1=_0x2570e6['splitPosition']['parent'];_0x2570e6['_execute']();const _0x329726=_0x407ef1['getAttribute']('vid_end'),_0x4a58f7=_0x2570e6['insertionPosition']['nodeAfter'];if(_0x2d4b68){const _0x2d5637=_0x4a58f7['getAttribute']('vid_end'),_0x13b1d9=_0x407ef1['getAttribute']('vid_end');_0x407ef1['_setAttribute']('vid_end',_0x2d5637),_0x4a58f7['_setAttribute']('vid_end',_0x13b1d9),this['_touched']['set'](_0x407ef1['getAttribute']('vid_end'),{'userId':_0xbe8841}),this['_touched']['set'](_0x4a58f7['getAttribute']('vid_start'),{'userId':_0xbe8841});}else{const _0x540897=this['_revisionId']++,_0x29f8a1=this['_revisionId']++;_0x407ef1['_setAttribute']('vid_end',_0x540897),_0x4a58f7['_setAttribute']('vid_start',_0x29f8a1),_0x4a58f7['_setAttribute']('vid_end',_0x329726),this['_touched']['set'](_0x540897,{'userId':_0xbe8841}),this['_touched']['set'](_0x29f8a1,{'userId':_0xbe8841});}}['_handleMarkerOperation'](_0x372406){if(!_0x372406['affectsData'])return;const _0x255b29=(_0x372406=this['_cloneOperation'](_0x372406,this['_diffRoots']))['oldRange']?_0x372406['oldRange']['root']:null,_0x212697=_0x372406['newRange']?_0x372406['newRange']['root']:null;_0x255b29&&this['_markers']['delete'](_0x372406['name']),_0x212697&&this['_markers']['set'](_0x372406['name'],_0x372406['newRange']['clone']());const _0x375af4=null===_0x372406['_authorId']?null:_0x372406['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0xc5d180=_0x372406['name'];if(!this['_touchedMarkers']['has'](_0xc5d180))return void this['_touchedMarkers']['set'](_0xc5d180,{'range':_0x372406['oldRange'],'userId':_0x375af4});const _0x49d9f2=this['_touchedMarkers']['get'](_0xc5d180),_0x220124=_0x49d9f2['range'],_0x2ace5d=_0x372406['newRange'];null==_0x220124&&null==_0x2ace5d||_0x220124&&_0x2ace5d&&_0x220124['isEqual'](_0x2ace5d)?this['_touchedMarkers']['delete'](_0x372406['name']):_0x49d9f2['userId']=_0x375af4;}['_handleRootOperation'](_0x1363be,_0x5cb921){this['_diffRoots']['has'](_0x1363be['rootName'])?this['_diffRoots']['get'](_0x1363be['rootName'])['_isAttached']=_0x1363be['isAdd']:(this['_diffRoots']['set'](_0x1363be['rootName'],N(_0x1363be['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x1363be['rootName'],{}),_0x5cb921&&this['_idsRoots']['set'](_0x1363be['rootName'],N(_0x1363be['rootName'],!0x0)));const _0x3e6344=null===_0x1363be['_authorId']?null:_0x1363be['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x374b50=this['_touchedRoots']['get'](_0x1363be['rootName']);_0x374b50&&_0x374b50['userId']===_0x3e6344?this['_touchedRoots']['delete'](_0x1363be['rootName']):this['_touchedRoots']['set'](_0x1363be['rootName'],{'userId':_0x3e6344,'isAttached':_0x1363be['isAdd']});}['_handleRootAttributeOperation'](_0x2ee145){const _0x4ee9a6=this['_diffRootsAttributes']['get'](_0x2ee145['root']['rootName']);null===_0x2ee145['newValue']?delete _0x4ee9a6[_0x2ee145['key']]:_0x4ee9a6[_0x2ee145['key']]=_0x2ee145['newValue'];}}function x(_0x2e539e){const _0x3af1bf=N(_0x2e539e['rootName'],_0x2e539e['isAttached']());for(const _0x22a695 of _0x2e539e['getChildren']()){const _0x5021a2=_0x22a695['_clone'](!0x0);_0x3af1bf['_appendChild'](_0x5021a2);}return _0x3af1bf;}function N(_0xae9702,_0x3c25e6=!0x0){const _0x13e8fb=new _0x3ae66b();return _0x13e8fb['rootName']=_0xae9702,_0x13e8fb['_isAttached']=_0x3c25e6,_0x13e8fb['isAttached']=()=>_0x13e8fb['_isAttached'],_0x13e8fb;}function P(_0x2ed57f,_0x1879b5,_0x2113a6){const _0xff75a6='elementEnd'==_0x2ed57f['type']?_0x2113a6['createPositionAt'](_0x2ed57f['item'],'end'):_0x2113a6['createPositionBefore'](_0x2ed57f['item']);return _0x2113a6['createPositionFromPath'](_0x1879b5,_0xff75a6['path'],_0xff75a6['stickiness']);}function V(_0xc31812,_0x54a8fd,_0x49f54){const _0x1b1b03='elementStart'==_0xc31812['type']?_0x49f54['createPositionAt'](_0xc31812['item'],0x0):_0x49f54['createPositionAfter'](_0xc31812['item']);return _0x49f54['createPositionFromPath'](_0x54a8fd,_0x1b1b03['path'],_0x1b1b03['stickiness']);}class me extends/* #__PURE__ -- @preserve */
|
|
25
|
-
|
|
26
|
-
_0x53b020(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x233834){super(),this['id']=_0x233834['id']||_0x1b5d50(),this['author']=_0x233834['author'],this['type']=_0x233834['type'],this['data']=_0x233834['data']||{},this['rootName']=_0x233834['rootName'],this['set']('createdAt',_0x233834['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(_0xacd82d,_0x448f0b){this['newRevisionId']=_0xacd82d,this['oldRevisionId']=_0x448f0b,this['changes']=new _0x3ac57f();}['_setChanges'](_0x10ac32){for(const _0x3226e8 of _0x10ac32)this['changes']['add'](_0x3226e8);}}class l extends _0x235b76{['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[_0x34eefc,_0xe4aace,S,$];}constructor(_0xe5d2ce){super(_0xe5d2ce),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',(_0x29dcf5,_0x5f4c64,_0x11a68a)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x5e2d44=>{for(const _0xc79686 of this['editor']['editing']['view']['document']['roots'])_0x11a68a?_0x5e2d44['removeClass']('ck-editor__editable__overlay',_0xc79686):_0x5e2d44['addClass']('ck-editor__editable__overlay',_0xc79686);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x355b04=>null!==_0x355b04),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x1e1fa1,_0x3a883c,_0x62b958)=>_0x1e1fa1&&_0x62b958?_0x3a883c['changes']['getIndex'](_0x62b958):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x1ff49a,_0x51077e)=>_0x1ff49a?_0x51077e['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0xe4aace);}['init'](){const _0x24aa97=this['editor'],_0x2ff7e6=new rt(_0x24aa97,{'direction':'backward'}),_0x3747d1=new rt(_0x24aa97,{'direction':'forward'});(_0x24aa97['commands']['add']('showPreviousChange',_0x2ff7e6),_0x24aa97['commands']['add']('showNextChange',_0x3747d1),_0x24aa97['commands']['add']('restoreRevision',new nt(_0x24aa97)),this['on']('change:numberOfChanges',()=>{_0x2ff7e6['refresh'](),_0x3747d1['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x24aa97['enableReadOnlyMode']('revision-viewer'),_0x24aa97['plugins']['has']('WidgetToolbarRepository'))&&_0x24aa97['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x567da5){return await this['_utils']['loadRevisionData'](_0x567da5,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x567da5);}async['getRevisionRootsAttributes'](_0x52ff83){return await this['_utils']['loadRevisionData'](_0x52ff83,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x52ff83);}async['compare'](_0x2e90e3,_0x5ef62e,_0x4616b7=!0x1){if(!this['isEnabled'])return;const _0x58ae31=this['diff'],_0x42b3e6=this['repository'],_0x5deb39='string'==typeof _0x2e90e3?_0x42b3e6['getRevision'](_0x2e90e3):_0x2e90e3,_0x3c80bd='string'==typeof _0x5ef62e?_0x42b3e6['getRevision'](_0x5ef62e):_0x5ef62e,_0x1fa7f6=_0x5deb39['id'],_0x48545a=_0x3c80bd?_0x3c80bd['id']:null;if(!_0x4616b7&&this['diff']&&this['diff']['newRevisionId']===_0x1fa7f6&&this['diff']['oldRevisionId']===_0x48545a)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new J(_0x1fa7f6,_0x48545a);const _0xf35d31=this['_getRevisionsRange'](_0x5deb39,_0x3c80bd,!0x0)['map'](_0x485bad=>this['_utils']['loadRevisionData'](_0x485bad,this['adapter']));return _0xf35d31['push'](new Promise(_0x3a7b7c=>{setTimeout(_0x3a7b7c,0x14);})),Promise['all'](_0xf35d31)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x52a30e=this['_getDiff'](_0x1fa7f6,_0x48545a);for(const _0x371f29 of _0x52a30e['changes'])this['_changeIdToChange']['set'](_0x371f29['id'],_0x371f29);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x3de90a=>{for(const _0x56b5af of this['editor']['model']['document']['getRootNames']())_0x3de90a['detachRoot'](_0x56b5af);for(const _0x34dda8 of Object['keys'](_0x52a30e['model'])){const _0x1037b8=_0x3de90a['addRoot'](_0x34dda8);for(const _0x9926cf of Object['keys'](_0x52a30e['attributes'][_0x34dda8]))_0x3de90a['setAttribute'](_0x9926cf,_0x52a30e['attributes'][_0x34dda8][_0x9926cf],_0x1037b8);_0x3de90a['insert'](_0x52a30e['model'][_0x34dda8],_0x1037b8,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x52a30e['changes'])),this['isReady']=!0x0;})['catch'](_0x36047b=>{console['error'](_0x36047b),this['_cleanUp'](),_0x58ae31&&(this['diff']=_0x58ae31),this['isReady']=!0x0;});}['addRevisionData'](_0x22ab09,_0x690d58){const _0x54917e=this['repository']['createRevision'](_0x22ab09);return _0x54917e['on']('_update',(_0x1d7679,_0x3915c1,_0xd40679)=>_0x690d58(_0x3915c1,_0xd40679,_0x54917e)),this['repository']['addRevision'](_0x54917e),_0x54917e;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x29c4f3=>{for(const _0x485a22 of this['editor']['model']['document']['getRootNames']())_0x29c4f3['detachRoot'](_0x485a22);});}['_sortAndFilterDiffChanges'](_0x18f015){const _0x220316=[],_0xdbdbc1=new Map();for(const _0x3571be of this['editor']['model']['document']['getRootNames']()){const _0x1c1582=this['editor']['editing']['view']['getDomRoot'](_0x3571be);if(!_0x1c1582)continue;const _0x410b02=_0x1c1582['getClientRects']()['item'](0x0);_0x410b02&&(_0x220316['push'](_0x3571be),_0xdbdbc1['set'](_0x3571be,_0x410b02));}return _0x220316['sort']((_0x1bcc5e,_0x48b57e)=>{const _0x37012a=_0xdbdbc1['get'](_0x1bcc5e),_0x4e143e=_0xdbdbc1['get'](_0x48b57e);return _0x37012a['y']-_0x4e143e['y']||_0x37012a['x']-_0x4e143e['x'];}),(_0x18f015=_0x18f015['filter'](_0x146473=>_0x220316['includes'](_0x146473['rootName'])))['sort']((_0x574a78,_0x331626)=>_0x220316['indexOf'](_0x574a78['rootName'])-_0x220316['indexOf'](_0x331626['rootName'])),_0x18f015;}['_makeTape'](_0x22733b){const _0x3c94b4=Array['from'](_0x22733b['markers'])['filter'](([_0xa9a4d5,_0xe89d18])=>_0xa9a4d5['startsWith']('revision:')&&!_0xe89d18['isCollapsed']),_0x3f63ba=Array['from'](this['editor']['model']['createRangeIn'](_0x22733b)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x3c94b4['length'])for(const _0x1f0cc2 of _0x3f63ba){const [_0x3a2de6,_0x23d369]=_0x3c94b4[0x0],[,_0x31a9a8,_0x1b667a]=_0x3a2de6['split'](':');if(_0x23d369['end']['isEqual'](_0x1f0cc2['nextPosition'])&&_0x3c94b4['shift'](),(_0x1f0cc2['previousPosition']['isEqual'](_0x23d369['start'])||_0x1f0cc2['previousPosition']['isAfter'](_0x23d369['start']))&&('insertion'==_0x31a9a8?_0x1f0cc2['isAdded']={'userId':_0x1b667a}:'deletion'==_0x31a9a8&&(_0x1f0cc2['isRemoved']={'userId':_0x1b667a})),0x0==_0x3c94b4['length'])break;}return _0x3f63ba;}['_refreshStartEndIndex'](_0x3da219){const _0x2f272d=new Map();for(let _0x5cc39e=0x0;_0x5cc39e<_0x3da219['length'];_0x5cc39e++)'text'===_0x3da219[_0x5cc39e]['type']?(_0x3da219[_0x5cc39e]['item']['startIndex']=_0x5cc39e,_0x3da219[_0x5cc39e]['item']['endIndex']=_0x5cc39e):('elementStart'===_0x3da219[_0x5cc39e]['type']?_0x3da219[_0x5cc39e]['item']['startIndex']=_0x5cc39e:'elementEnd'===_0x3da219[_0x5cc39e]['type']&&(_0x3da219[_0x5cc39e]['item']['endIndex']=_0x5cc39e),_0x2f272d['set'](_0x3da219[_0x5cc39e]['id'],_0x5cc39e));for(const _0x381075 of _0x2f272d['values']())'elementStart'===_0x3da219[_0x381075]['type']?_0x3da219[_0x381075]['item']['endIndex']=_0x2f272d['get'](_0x3da219[_0x381075]['pairId']):'elementEnd'===_0x3da219[_0x381075]['type']&&(_0x3da219[_0x381075]['item']['startIndex']=_0x2f272d['get'](_0x3da219[_0x381075]['pairId']));}['_processTape'](_0x4ec5d0){for(let _0x3236bd=0x0;_0x3236bd<_0x4ec5d0['length'];_0x3236bd++){if('elementStart'===_0x4ec5d0[_0x3236bd]['type'])_0x4ec5d0[_0x3236bd]['item']['startIndex']=_0x3236bd;else{if('elementEnd'===_0x4ec5d0[_0x3236bd]['type']){_0x4ec5d0[_0x3236bd]['item']['endIndex']=_0x3236bd;const _0x414458=_0x4ec5d0[_0x3236bd]['item']['startIndex'];_0x4ec5d0[_0x414458]['pairId']=_0x4ec5d0[_0x3236bd]['id'],_0x4ec5d0[_0x3236bd]['pairId']=_0x4ec5d0[_0x414458]['id'];}else _0x4ec5d0[_0x3236bd]['item']['startIndex']=_0x3236bd,_0x4ec5d0[_0x3236bd]['item']['endIndex']=_0x3236bd,_0x4ec5d0[_0x3236bd]['pairId']=null;}_0x4ec5d0[_0x3236bd]['markersStart']||(_0x4ec5d0[_0x3236bd]['markersStart']=[],_0x4ec5d0[_0x3236bd]['markersEnd']=[]);}}['_markInsertions'](_0x1de2d6,_0x355ad0){const _0xc55fae=_0x1de2d6['filter'](_0x511f33=>!_0x511f33['isAdded']);for(let _0xbcaac7=0x0;_0xbcaac7<_0x355ad0['length'];_0xbcaac7++)_0x355ad0[_0xbcaac7]['isAdded']&&(_0xc55fae[_0xbcaac7]['isAdded']=_0x355ad0[_0xbcaac7]['isAdded']);}['_getDiff'](_0x4107bb,_0x38f92b=null){const _0x4e455f=this['repository']['getRevision'](_0x4107bb),_0x209c8f=_0x38f92b?this['repository']['getRevision'](_0x38f92b):null,_0x4532a7=this['_getRevisionsRange'](_0x4e455f,_0x209c8f),_0x428325=_0x4532a7[_0x4532a7['length']-0x1],_0x4dc7fb=new Map(),_0x11ecef={'model':{},'attributes':{},'changes':[]},_0x18e20d=new Set(),_0x464b73=new Map();for(let _0x1ebab=_0x4532a7['length']-0x1;_0x1ebab>=0x0;_0x1ebab--){const _0x306366=_0x4532a7[_0x1ebab];for(const _0x34567a of Object['keys'](_0x306366['diffData']))if(_0x306366['diffData'][_0x34567a]['attachChange']){const _0x57653e=_0x306366['diffData'][_0x34567a]['attachChange'];_0x57653e['isAttached']?(_0x18e20d['add'](_0x34567a),_0x464b73['has'](_0x34567a)&&_0x464b73['get'](_0x34567a)['userId']==_0x57653e['userId']?_0x464b73['delete'](_0x34567a):_0x464b73['set'](_0x34567a,_0x57653e)):_0x464b73['has'](_0x34567a)?(_0x18e20d['delete'](_0x34567a),_0x464b73['delete'](_0x34567a)):(_0x18e20d['add'](_0x34567a),_0x464b73['set'](_0x34567a,_0x57653e));}else _0x18e20d['add'](_0x34567a);}for(const _0x5117af of _0x18e20d){const _0x443768=_0x464b73['has'](_0x5117af)&&!_0x464b73['get'](_0x5117af)['isAttached'];let _0x448ea4=_0x443768?_0x4532a7['length']-0x1:0x0;const _0x1fb86b=_0x443768?-0x1:0x1;for(;_0x4532a7[_0x448ea4];){const _0x11a616=_0x4532a7[_0x448ea4];if(_0x11a616['diffData'][_0x5117af]){const _0xc5ec78=_0x443768?_0x11a616['diffData'][_0x5117af]['attributesBefore']:_0x11a616['diffData'][_0x5117af]['attributesAfter'];_0x11ecef['attributes'][_0x5117af]=_0xc5ec78?_0x186599(_0xc5ec78):{};break;}_0x448ea4+=_0x1fb86b;}}for(const _0x3122ac of _0x4532a7){_0x3122ac['model']={};for(const _0x4c3fec of _0x3122ac['authors'])_0x4dc7fb['set'](_0x4c3fec['id'],_0x4c3fec);for(const _0x213c0c of _0x18e20d){const _0x274b4b=_0x3122ac['diffData'][_0x213c0c]?_0x3122ac['diffData'][_0x213c0c]['insertions']:'[]',_0x1316ba=_0x3122ac['diffData'][_0x213c0c]?_0x3122ac['diffData'][_0x213c0c]['deletions']:'[]';_0x3122ac['model'][_0x213c0c]={'insertions':this['_utils']['_makeModelFromViewString'](_0x274b4b),'deletions':this['_utils']['_makeModelFromViewString'](_0x1316ba)};}}for(const _0x45b166 of _0x18e20d){let _0x521739=null,_0x10acc6=0x0;const _0xabdaa2=new Map(Array['from'](_0x4e455f['model'][_0x45b166]['insertions']['markers'])['filter'](([_0x1845b2])=>!_0x1845b2['startsWith']('revision:')));let _0x5177e5=0x0;for(const _0x81e5d of _0x4532a7){const _0xa1c547=this['_makeTape'](_0x81e5d['model'][_0x45b166]['insertions']);_0x81e5d==_0x4e455f?(_0x521739=_0xa1c547,_0x10acc6=_0x521739['length'],_0x521739['forEach'](_0x269d57=>{_0x269d57['id']=_0x5177e5++;}),this['_processTape'](_0x521739)):this['_markInsertions'](_0x521739,_0xa1c547);const _0x19eee2=_0x521739['filter'](_0xaff2d2=>!_0xaff2d2['isAdded'])['map'](_0x4a1568=>_0x4a1568['id']);let _0x30b015=0x0;const _0x458de2=this['_makeTape'](_0x81e5d['model'][_0x45b166]['deletions']);_0x458de2['forEach'](_0x200a07=>{_0x200a07['isRemoved']?_0x200a07['id']=_0x10acc6++:_0x200a07['id']=_0x19eee2[_0x30b015++];}),this['_processTape'](_0x458de2),this['_setDistance'](_0x521739,'isAdded'),this['_setDistance'](_0x458de2,'isRemoved'),_0x81e5d==_0x4e455f&&this['_markMarkers'](_0x521739,_0xabdaa2),_0x521739=this['_joinTapes'](_0x521739,_0x458de2),this['_refreshStartEndIndex'](_0x521739),this['_setDistance'](_0x521739,'isRemoved');}_0x521739=_0x521739['filter'](_0x3dbb50=>!(_0x3dbb50['isAdded']&&_0x3dbb50['isRemoved']));const _0x48d2ae=new Map(_0x428325['model'][_0x45b166]['deletions']['markers']),_0x127654=new Set(_0xabdaa2['keys']());for(const _0x3004e6 of _0x48d2ae['keys']())_0x127654['delete'](_0x3004e6);this['_markSuggestions'](_0x521739,_0x127654),this['_fixObsoleteTags'](_0x521739),_0x521739=this['_removeMissingPairs'](_0x521739),_0x521739=this['_markMismatchedRemovedTags'](_0x521739),_0x521739=this['_removeUnsupportedChanges'](_0x521739);const {root:_0x3ec712,changes:_0x3dee08}=this['_makeModelFromTape'](_0x521739,_0x4dc7fb,_0x45b166);_0x11ecef['model'][_0x45b166]=_0x3ec712;const _0x4e4b39=_0x464b73['get'](_0x45b166);if(_0x4e4b39){const _0x19707d=_0x4dc7fb['get'](_0x4e4b39['userId']),_0x3449f8=new G({'author':_0x19707d,'type':_0x4e4b39['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x45b166});_0x3dee08['unshift'](_0x3449f8),_0x11ecef['attributes'][_0x45b166]['revisionHistoryAttachChange']=_0x3449f8['id'];}_0x11ecef['changes']=_0x11ecef['changes']['concat'](_0x3dee08);}return _0x11ecef;}['_markMarkers'](_0x4e7381,_0x59bfce){for(let _0x539480=0x0;_0x539480<_0x4e7381['length'];_0x539480++)for(const [_0x2f985d,_0x3b4a84]of _0x59bfce)!_0x3b4a84['isCollapsed']&&_0x3b4a84['start']['isEqual'](_0x4e7381[_0x539480]['previousPosition'])&&_0x4e7381[_0x539480]['markersStart']['push'](_0x2f985d),_0x3b4a84['end']['isEqual'](_0x4e7381[_0x539480]['nextPosition'])&&_0x4e7381[_0x539480]['markersEnd']['push'](_0x2f985d);}['_joinTapes'](_0x570573,_0x2f7d0f){let _0x1294d2=[],_0x55644b=0x0,_0x47a6f0=0x0;for(;_0x55644b<_0x570573['length']||_0x47a6f0<_0x2f7d0f['length'];){const _0x511cb4=_0x570573[_0x55644b]||{},_0x43322a=_0x2f7d0f[_0x47a6f0]||{};if(_0x511cb4['id']==_0x43322a['id'])_0x55644b++,_0x47a6f0++,_0x1294d2['push'](_0x511cb4);else{if(_0x43322a['isRemoved']&&_0x511cb4['isAdded']){const {commonTape:_0x2b0127,iEnd:_0x297d2e,jEnd:_0x5ec40b}=this['_threeWayMerge'](_0x570573,_0x55644b,_0x2f7d0f,_0x47a6f0);_0x1294d2=_0x1294d2['concat'](_0x2b0127),_0x55644b=_0x297d2e,_0x47a6f0=_0x5ec40b;}else _0x43322a['isRemoved']?(_0x47a6f0++,_0x1294d2['push'](_0x43322a)):(_0x55644b++,_0x1294d2['push'](_0x511cb4));}}return _0x1294d2;}['_markSuggestions'](_0x34f76b,_0x55dd06){const _0x428d7c=[];for(let _0x3537c1=0x0;_0x3537c1<_0x34f76b['length'];_0x3537c1++){for(let _0x2c8001=0x0;_0x2c8001<_0x34f76b[_0x3537c1]['markersStart']['length'];_0x2c8001++){const _0x253b12=_0x34f76b[_0x3537c1]['markersStart'][_0x2c8001];if(!_0x55dd06['has'](_0x253b12))continue;const {group:_0x2a16dc,type:_0x3f67cd,authorId:_0x1543da}=_0x130d81(_0x253b12);'revision-suggestion'!=_0x2a16dc||'insertion'!=_0x3f67cd&&'deletion'!=_0x3f67cd||(_0x428d7c['unshift']({'type':_0x3f67cd,'name':_0x253b12,'userId':_0x1543da}),_0x34f76b[_0x3537c1]['markersStart']['splice'](_0x2c8001,0x1),_0x2c8001--);}_0x5e8e41(_0x34f76b[_0x3537c1]);for(let _0x3ca94c=0x0;_0x3ca94c<_0x34f76b[_0x3537c1]['markersEnd']['length'];_0x3ca94c++){const _0x3c7d55=_0x34f76b[_0x3537c1]['markersEnd'][_0x3ca94c];if(!_0x55dd06['has'](_0x3c7d55))continue;const {group:_0x2656a4,type:_0x3ba243}=_0x130d81(_0x3c7d55);if('revision-suggestion'!=_0x2656a4||'insertion'!=_0x3ba243&&'deletion'!=_0x3ba243)continue;_0x34f76b[_0x3537c1]['markersEnd']['splice'](_0x3ca94c,0x1),_0x3ca94c--;const _0x358055=_0x428d7c['findIndex'](_0x3f0b2b=>_0x3f0b2b['name']==_0x3c7d55);_0x358055>-0x1&&_0x428d7c['splice'](_0x358055,0x1);}}function _0x130d81(_0x1271ac){const _0x3a7f1d=_0x1271ac['split'](':');return{'group':_0x3a7f1d[0x0],'type':_0x3a7f1d[0x1],'subType':_0x3a7f1d['length']>=0x5?_0x3a7f1d[0x2]:null,'id':_0x3a7f1d['length']<0x5?_0x3a7f1d[0x2]:_0x3a7f1d[0x3],'authorId':_0x3a7f1d['length']<0x5?_0x3a7f1d[0x3]:_0x3a7f1d[0x4],'markerCount':0x6==_0x3a7f1d['length']?_0x3a7f1d[0x5]:null};}function _0x5e8e41(_0x67505b){for(let _0x58e9c2=0x0;_0x58e9c2<_0x428d7c['length'];_0x58e9c2++){if(_0x67505b['isAdded']&&'insertion'==_0x428d7c[_0x58e9c2]['type']&&_0x67505b['isAdded']['userId']==_0x428d7c[_0x58e9c2]['userId'])return _0x67505b['isAddSuggestion']=_0x428d7c[_0x58e9c2],void delete _0x67505b['isAdded'];if(!_0x67505b['isAdded']&&!_0x67505b['isRemoved']&&'deletion'==_0x428d7c[_0x58e9c2]['type'])return void(_0x67505b['isRemoveSuggestion']=_0x428d7c[_0x58e9c2]);}}}['_setDistance'](_0x44b15d,_0x473643){let _0x429725=0x0,_0x468c1b=!0x1;const _0x2e2af5=new Map();for(const _0x2641e3 of _0x44b15d)_0x2641e3[_0x473643]?_0x468c1b&&(_0x429725++,_0x468c1b=!0x1):(_0x429725++,_0x468c1b=!0x0),_0x2e2af5['set'](_0x2641e3['id'],_0x429725);for(let _0x4ca90f=0x0;_0x4ca90f<_0x44b15d['length'];_0x4ca90f++){if('isRemoved'==_0x473643&&_0x44b15d[_0x4ca90f]['isAdded']||'isAdded'==_0x473643&&_0x44b15d[_0x4ca90f]['isRemoved'])continue;if('text'==_0x44b15d[_0x4ca90f]['type']){_0x44b15d[_0x4ca90f]['distance']=0x0;continue;}const _0x526bb2=_0x2e2af5['get'](_0x44b15d[_0x4ca90f]['pairId']),_0x25fc93=_0x2e2af5['get'](_0x44b15d[_0x4ca90f]['id']);_0x44b15d[_0x4ca90f]['distance']=_0x526bb2-_0x25fc93;}}['_getRevisionsRange'](_0x2d3c5,_0x3956e5,_0x29e725=!0x1){const _0x1d1313=[];let _0x5da1ab=this['repository']['getIndex'](_0x2d3c5),_0x527dad=this['repository']['getIndex'](_0x3956e5);for(-0x1==_0x527dad&&(_0x527dad=this['repository']['_revisions']['length'],_0x29e725=!0x1);_0x5da1ab<_0x527dad;)_0x1d1313['push'](this['repository']['getRevision'](_0x5da1ab)),_0x5da1ab++;return _0x29e725&&_0x1d1313['push'](this['repository']['getRevision'](_0x5da1ab)),_0x1d1313;}['_threeWayMerge'](_0x548479,_0x2abd2d,_0x1fd745,_0xaf3006){const _0x2a07af=this['editor']['model']['schema'];let _0x30c983=_0x2abd2d;for(;_0x548479[_0x30c983]&&_0x548479[_0x30c983]['isAdded'];)_0x30c983++;let _0x7c3fcb=_0xaf3006;for(;_0x1fd745[_0x7c3fcb]&&_0x1fd745[_0x7c3fcb]['isRemoved'];)_0x7c3fcb++;_0x468d1e(_0x548479,_0x2abd2d,_0x30c983),_0x468d1e(_0x1fd745,_0xaf3006,_0x7c3fcb);const _0x1620b0=_0x1fd745['slice'](_0xaf3006,_0x7c3fcb)['concat'](_0x548479['slice'](_0x2abd2d,_0x30c983));return _0x1620b0['sort']((_0xa539f6,_0x3274a6)=>_0xa539f6['side']!=_0x3274a6['side']?_0xa539f6['side']-_0x3274a6['side']:_0xa539f6['level']!=_0x3274a6['level']?_0xa539f6['level']-_0x3274a6['level']:_0xa539f6['distance']!=_0x3274a6['distance']?_0x3274a6['distance']-_0xa539f6['distance']:!!_0xa539f6['isAdded']!=!!_0x3274a6['isAdded']?-0x1==_0xa539f6['side']||0x0==_0xa539f6['side']?_0xa539f6['isAdded']?-0x1:0x1:_0xa539f6['isAdded']?0x1:-0x1:_0xa539f6['index']-_0x3274a6['index']),{'commonTape':_0x1620b0,'iEnd':_0x30c983,'jEnd':_0x7c3fcb};function _0x468d1e(_0x1f3572,_0x497b6e,_0x1659e3){let _0x5a3509=-0x1,_0x307fa5=Number['POSITIVE_INFINITY'],_0xcea5e3=!0x0;for(let _0x322f0b=_0x497b6e;_0x322f0b<_0x1659e3;_0x322f0b++)if(_0x2a07af['isInline'](_0x1f3572[_0x322f0b]['item'])||(_0xcea5e3=!0x1),_0x1f3572[_0x322f0b]['item']['startIndex']<_0x497b6e&&(_0x5a3509=_0x322f0b),_0x1f3572[_0x322f0b]['item']['endIndex']>=_0x1659e3){_0x307fa5=_0x322f0b;break;}_0xcea5e3&&(_0x5a3509=_0x1659e3-0x1);for(let _0xdd82fc=_0x497b6e;_0xdd82fc<_0x1659e3;_0xdd82fc++)_0x1f3572[_0xdd82fc]['side']=_0xdd82fc<=_0x5a3509?-0x1:_0xdd82fc<_0x307fa5?0x0:0x1,_0x1f3572[_0xdd82fc]['index']=_0xdd82fc;let _0x105cd7=0x0;for(let _0x308c46=_0x497b6e;_0x308c46<=_0x5a3509;_0x308c46++)0x0==_0x1f3572[_0x308c46]['distance']?_0x1f3572[_0x308c46]['level']=_0x105cd7:(_0x105cd7++,_0x1f3572[_0x308c46]['level']=_0x105cd7,_0x105cd7++);for(let _0x51a6a2=_0x497b6e;_0x51a6a2<_0x1659e3;_0x51a6a2++)0x0==_0x1f3572[_0x51a6a2]['side']&&(_0x1f3572[_0x51a6a2]['level']=_0x105cd7);_0x105cd7=0x0;for(let _0x4d2eca=_0x1659e3-0x1;_0x4d2eca>=_0x307fa5;_0x4d2eca--)0x0==_0x1f3572[_0x4d2eca]['distance']?_0x1f3572[_0x4d2eca]['level']=_0x105cd7:(_0x105cd7--,_0x1f3572[_0x4d2eca]['level']=_0x105cd7,_0x105cd7--);}}['_fixObsoleteTags'](_0x2f37dc){const _0x122c1e=new Map(),_0x528dbe=this['editor']['model']['schema'];for(let _0x1c3ea9=0x1;_0x1c3ea9<_0x2f37dc['length'];_0x1c3ea9++){let _0x506f8f,_0x56e763,_0x2ddf80;const _0xcc261f=_0x2f37dc[_0x1c3ea9],_0x199001=_0x2f37dc[_0x1c3ea9-0x1];if('text'==_0xcc261f['type'])continue;if(_0xcc261f['type']!=_0x199001['type'])continue;if(!_0x528dbe['isBlock'](_0x199001['item'])||_0x528dbe['isLimit'](_0x199001['item']))continue;if(!_0x528dbe['isBlock'](_0xcc261f['item'])||_0x528dbe['isLimit'](_0xcc261f['item']))continue;if((_0x2f37dc[_0x1c3ea9]['isAdded']||_0x2f37dc[_0x1c3ea9]['isAddSuggestion'])&&_0x2f37dc[_0x1c3ea9-0x1]['isRemoved'])_0x506f8f=_0x2f37dc[_0x1c3ea9],_0x56e763=_0x2f37dc[_0x1c3ea9-0x1],_0x2ddf80=_0x1c3ea9-0x1;else{if(!_0x2f37dc[_0x1c3ea9]['isRemoved']||!_0x2f37dc[_0x1c3ea9-0x1]['isAdded']&&!_0x2f37dc[_0x1c3ea9-0x1]['isAddSuggestion'])continue;_0x506f8f=_0x2f37dc[_0x1c3ea9-0x1],_0x56e763=_0x2f37dc[_0x1c3ea9],_0x2ddf80=_0x1c3ea9;}const _0x55bb8e=_0x506f8f['level']==_0x56e763['level'],_0x5bff7c=Math['abs'](_0x506f8f['level'])<Math['abs'](_0x56e763['level'])&&0x0==_0x56e763['distance'];(_0x55bb8e||_0x5bff7c)&&(_0x122c1e['set'](_0x56e763['id'],_0x506f8f['id']),_0x2f37dc['splice'](_0x2ddf80,0x1),_0x1c3ea9--,_0x506f8f['isAdded']=!0x1);}for(let _0x47beb1=0x0;_0x47beb1<_0x2f37dc['length'];_0x47beb1++)_0x122c1e['has'](_0x2f37dc[_0x47beb1]['pairId'])&&(_0x2f37dc[_0x47beb1]['pairId']=_0x122c1e['get'](_0x2f37dc[_0x47beb1]['pairId']));}['_removeMissingPairs'](_0x3e10d8){const _0x4c0f90=new Set(_0x3e10d8['map'](_0x5aefb6=>_0x5aefb6['id']));for(let _0x53679b=0x0;_0x53679b<_0x3e10d8['length'];_0x53679b++)_0x4c0f90['has'](_0x3e10d8[_0x53679b]['pairId'])||0x0==_0x3e10d8[_0x53679b]['distance']||(_0x3e10d8[_0x53679b]['isIncorrect']=!0x0);return _0x3e10d8['filter'](_0x364c6c=>!_0x364c6c['isIncorrect']);}['_markMismatchedRemovedTags'](_0x37b891){const _0x5593cf=new Set();for(let _0x2b7aee=0x0;_0x2b7aee<_0x37b891['length'];_0x2b7aee++){if(_0x5593cf['has'](_0x37b891[_0x2b7aee]['id'])&&_0x37b891[_0x2b7aee]['isRemoved']&&(_0x37b891[_0x2b7aee]['isIncorrect']=!0x0),_0x37b891[_0x2b7aee]['isIncorrect'])continue;if(0x0==_0x37b891[_0x2b7aee]['distance'])continue;if('elementStart'!=_0x37b891[_0x2b7aee]['type'])continue;if(null==_0x37b891[_0x2b7aee]['pairId'])continue;let _0x250988=_0x2b7aee+0x1,_0x38e8b5=0x0;for(;_0x37b891[_0x250988]['id']!=_0x37b891[_0x2b7aee]['pairId'];)'elementStart'==_0x37b891[_0x250988]['type']?_0x38e8b5++:'elementEnd'==_0x37b891[_0x250988]['type']&&_0x38e8b5--,_0x250988++;if(0x0!=_0x38e8b5){if(_0x37b891[_0x2b7aee]['isRemoved'])_0x37b891[_0x2b7aee]['isIncorrect']=!0x0;else{for(;_0x250988!=_0x2b7aee;)_0x37b891[_0x250988]['isRemoved']&&0x0!=_0x37b891[_0x250988]['distance']&&(_0x37b891[_0x250988]['isIncorrect']=!0x0,_0x5593cf['add'](_0x37b891[_0x250988]['pairId'])),_0x250988--;}}}return _0x37b891['filter'](_0x48de34=>!_0x48de34['isIncorrect']);}['_removeUnsupportedChanges'](_0x53fc83){const _0xcf327e=this['editor']['model']['schema'];for(let _0x593559=0x0;_0x593559<_0x53fc83['length'];_0x593559++){if(!(_0x53fc83[_0x593559]['isAdded']||_0x53fc83[_0x593559]['isAddSuggestion']||_0x53fc83[_0x593559]['isRemoved']||_0x53fc83[_0x593559]['isRemoveSuggestion']))continue;if(0x0==_0x53fc83[_0x593559]['distance'])continue;const _0x26731c=_0x53fc83[_0x593559]['item'];_0xcf327e['isBlock'](_0x26731c)||_0xcf327e['isLimit'](_0x26731c)||(_0x53fc83[_0x593559]['isAdded']&&delete _0x53fc83[_0x593559]['isAdded'],_0x53fc83[_0x593559]['isAddSuggestion']&&delete _0x53fc83[_0x593559]['isAddSuggestion'],_0x53fc83[_0x593559]['isRemoveSuggestion']&&delete _0x53fc83[_0x593559]['isRemoveSuggestion'],_0x53fc83[_0x593559]['isRemoved']&&(_0x53fc83[_0x593559]['isIncorrect']=!0x0));}return _0x53fc83['filter'](_0xe1b7c8=>!_0xe1b7c8['isIncorrect']);}['_makeModelFromTape'](_0x3ba30b,_0x1ba147,_0x5d7523){const _0x3e0351=new _0x3ae66b(),_0x552596=[],_0x53b1cc=new Map(),_0x34adf2=this['editor']['model'],_0x11a968=_0x34adf2['schema'],_0x20344b=[_0x3e0351],_0xb43f81={},_0x357458={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x4172c1=null;const _0x468225=[0x0];for(let _0x583067=0x0;_0x583067<_0x3ba30b['length'];_0x583067++)if('elementStart'===_0x3ba30b[_0x583067]['type']){_0x3ba30b[_0x583067]['previousPosition']=_0x34adf2['createPositionFromPath'](_0x3e0351,_0x468225);const _0x1fdaff=new _0x11a5c7(_0x3ba30b[_0x583067]['item']['name'],_0x3ba30b[_0x583067]['item']['getAttributes']());_0x20344b[0x0]['_appendChild'](_0x1fdaff),_0x468225['push'](0x0),_0x20344b['unshift'](_0x1fdaff),_0x3ba30b[_0x583067]['nextPosition']=_0x34adf2['createPositionFromPath'](_0x3e0351,_0x468225);}else'elementEnd'===_0x3ba30b[_0x583067]['type']?(_0x20344b['shift'](),_0x3ba30b[_0x583067]['previousPosition']=_0x34adf2['createPositionFromPath'](_0x3e0351,_0x468225),_0x468225['pop'](),_0x468225[_0x468225['length']-0x1]++,_0x3ba30b[_0x583067]['nextPosition']=_0x34adf2['createPositionFromPath'](_0x3e0351,_0x468225)):(_0x3ba30b[_0x583067]['previousPosition']=_0x34adf2['createPositionFromPath'](_0x3e0351,_0x468225),_0x4172c1?_0x4172c1['_data']+=_0x3ba30b[_0x583067]['item']['data']:_0x4172c1=new _0x2a1bb8(_0x3ba30b[_0x583067]['item']['data'],_0x3ba30b[_0x583067]['item']['getAttributes']()),_0x3ba30b[_0x583067+0x1]&&'text'===_0x3ba30b[_0x583067+0x1]['type']&&_0x5841b7(_0x4172c1,_0x3ba30b[_0x583067+0x1]['item'])||(_0x20344b[0x0]['_appendChild'](_0x4172c1),_0x4172c1=null),_0x468225[_0x468225['length']-0x1]+=_0x3ba30b[_0x583067]['item']['offsetSize'],_0x3ba30b[_0x583067]['nextPosition']=_0x34adf2['createPositionFromPath'](_0x3e0351,_0x468225));for(let _0xad3190=0x0;_0xad3190<_0x3ba30b['length'];_0xad3190++){const _0xb52381=_0x3ba30b[_0xad3190]['previousPosition'],_0x280571=_0x3ba30b[_0xad3190]['nextPosition'];for(const _0x1fd10c of _0x3ba30b[_0xad3190]['markersStart'])_0x53b1cc['set'](_0x1fd10c,{'start':_0xb52381,'end':null});_0x23066f('isRemoveSuggestion',_0xad3190,_0xb52381,_0x280571),_0x23066f('isAddSuggestion',_0xad3190,_0xb52381,_0x280571),_0x23066f('isRemoved',_0xad3190,_0xb52381,_0x280571),_0x23066f('isAdded',_0xad3190,_0xb52381,_0x280571);for(const _0x529d2a of _0x3ba30b[_0xad3190]['markersEnd']){const _0x26c2d4=_0x53b1cc['get'](_0x529d2a);_0x26c2d4?_0x26c2d4['end']=_0x280571:_0x53b1cc['set'](_0x529d2a,{'start':_0x280571,'end':_0x280571});}}for(const [_0x5a9e59,_0x13c6ef]of _0x53b1cc){const _0x1168eb=this['editor']['model']['createRange'](_0x13c6ef['start'],_0x13c6ef['end']);_0x3e0351['markers']['set'](_0x5a9e59,_0x1168eb);}return _0x552596['sort']((_0x5bb793,_0x315707)=>{const _0xbe7e8d=_0x3e0351['markers']['get']('revision:'+_0x5bb793['id']),_0x3a9b55=_0x3e0351['markers']['get']('revision:'+_0x315707['id']);return _0xbe7e8d['start']['isBefore'](_0x3a9b55['start'])?-0x1:_0xbe7e8d['start']['isAfter'](_0x3a9b55['start'])?0x1:_0xbe7e8d['end']['isBefore'](_0x3a9b55['end'])?-0x1:_0xbe7e8d['end']['isAfter'](_0x3a9b55['end'])?0x1:'add'===_0x5bb793['type']?-0x1:0x1;}),{'root':_0x3e0351,'changes':_0x552596};function _0x23066f(_0x2faf41,_0x5b70d6,_0x2001d3,_0x39ae83){const _0x2f248c=!!_0x3ba30b[_0x5b70d6][_0x2faf41],_0x237b7d=_0x2f248c?_0x3ba30b[_0x5b70d6][_0x2faf41]['userId']:null,_0x14dd0e=_0x5b70d6===_0x3ba30b['length']-0x1,_0x21dceb=_0x357458[_0x2faf41][0x0],_0x10ee82=_0x11a968['isObject'](_0x3ba30b[_0x5b70d6]['item']);!_0xb43f81[_0x2faf41]&&_0x2f248c?_0xb43f81[_0x2faf41]={'start':_0x2001d3,'tapeItem':_0x3ba30b[_0x5b70d6],'userId':_0x237b7d,'type':_0x2faf41}:_0xb43f81[_0x2faf41]&&!_0x2f248c?(_0xb43f81[_0x2faf41]['end']=_0x2001d3,_0x256a1e(_0xb43f81[_0x2faf41]),_0xb43f81[_0x2faf41]=null):_0xb43f81[_0x2faf41]&&_0x2f248c&&_0xb43f81[_0x2faf41]['userId']!==_0x237b7d&&(_0xb43f81[_0x2faf41]['end']=_0x2001d3,_0x21dceb&&_0x21dceb['userId']===_0xb43f81[_0x2faf41]['userId']||_0x256a1e(_0xb43f81[_0x2faf41]),_0xb43f81[_0x2faf41]={'start':_0x2001d3,'tapeItem':_0x3ba30b[_0x5b70d6],'userId':_0x237b7d,'type':_0x2faf41}),_0xb43f81[_0x2faf41]&&_0x10ee82&&('elementStart'!==_0x3ba30b[_0x5b70d6]['type']||_0x21dceb&&_0x21dceb['userId']===_0x237b7d||_0x357458[_0x2faf41]['unshift']({'userId':_0x237b7d,'object':_0x3ba30b[_0x5b70d6]['item'],'change':_0xb43f81[_0x2faf41]}),'elementEnd'===_0x3ba30b[_0x5b70d6]['type']&&_0x21dceb&&_0x21dceb['object']===_0x3ba30b[_0x5b70d6]['item']&&(_0x357458[_0x2faf41]['shift'](),_0xb43f81[_0x2faf41]=_0x21dceb['change'])),_0xb43f81[_0x2faf41]&&_0x14dd0e&&(_0xb43f81[_0x2faf41]['end']=_0x39ae83,_0x256a1e(_0xb43f81[_0x2faf41]),_0xb43f81[_0x2faf41]=null);}function _0x256a1e({start:_0x39843b,end:_0xe85af,tapeItem:_0x53fb33,userId:_0xec5f80,type:_0x3e2f48}){const _0x3f6388=_0x53fb33['item'],_0x593104=_0x34adf2['schema']['isBlock'](_0x3f6388)&&!_0x34adf2['schema']['isLimit'](_0x3f6388),_0x5e6774=_0x39843b['nodeAfter']==_0xe85af['parent']&&_0xe85af['isAtStart'];if(_0x593104&&_0x5e6774)return;const _0x40a6ac=_0x34adf2['createRange'](_0x39843b,_0xe85af),_0x5b5555=_0x1ba147['get'](_0xec5f80),_0x325a1a=new G({'author':_0x5b5555,'type':'isAdded'==_0x3e2f48||'isAddSuggestion'==_0x3e2f48?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x3e2f48||'isRemoveSuggestion'==_0x3e2f48},'createdAt':new Date(),'rootName':_0x5d7523});_0x552596['push'](_0x325a1a),_0x3e0351['markers']['set']('revision:'+_0x325a1a['id'],_0x40a6ac);}function _0x5841b7(_0xb848ce,_0x3c7a14){const _0x48f654=_0xb848ce['getAttributes'](),_0x37991c=_0x3c7a14['getAttributes']();for(const _0x115c6a of _0x48f654){if(_0x115c6a[0x1]!==_0x3c7a14['getAttribute'](_0x115c6a[0x0]))return!0x1;_0x37991c['next']();}return _0x37991c['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x2cc327=>{const _0x6f7a2e=_0x2cc327['markerName']['split'](':')[0x1],_0x17202d=this['_getChangeFromId'](_0x6f7a2e);if(!_0x17202d)return null;const _0x2bc202='add'==_0x17202d['type']?'insertion':'deletion',_0x53670d=['ck-suggestion-marker','ck-suggestion-marker-'+_0x2bc202];return _0x17202d['data']['isSuggestion']&&_0x53670d['push']('ck-suggestion-marker-'+_0x2bc202+'-new'),this['activeChange']==_0x17202d&&_0x53670d['push']('ck-suggestion-marker--active'),{'classes':_0x53670d,'attributes':{'data-change-id':_0x6f7a2e}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x51ec03=>{_0x51ec03['on']('element:pre',(_0x3cefa4,_0x5de8df,_0x41cfec)=>{const _0x146a4c=_0x5de8df['viewItem']['getChild'](0x0);if(!_0x146a4c||!_0x146a4c['is']('element','code'))return;if(!_0x41cfec['consumable']['consume'](_0x146a4c,{'attributes':['vid_start','vid_end']}))return;const _0x37b540=_0x5de8df['modelRange']['start']['nodeAfter'];_0x41cfec['writer']['setAttribute']('vid_start',_0x146a4c['getAttribute']('vid_start'),_0x37b540),_0x41cfec['writer']['setAttribute']('vid_end',_0x146a4c['getAttribute']('vid_end'),_0x37b540);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x54f55f=>{_0x54f55f['on']('element',(_0x4c177d,_0xc0645a,_0x209b71)=>{if(!_0x209b71['consumable']['consume'](_0xc0645a['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0xc0645a['modelRange']['isCollapsed'])return;const _0x598795=_0xc0645a['modelRange']['start']['nodeAfter'];_0x598795['hasAttribute']('vid_start')||_0x598795['hasAttribute']('vid')||(_0x209b71['writer']['setAttribute']('vid_start',_0xc0645a['viewItem']['getAttribute']('vid_start'),_0x598795),_0x209b71['writer']['setAttribute']('vid_end',_0xc0645a['viewItem']['getAttribute']('vid_end'),_0x598795));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x5318ae=>_0x5318ae['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x35d981,[,_0x43363a])=>{['vid_start','vid_end','vid']['includes'](_0x43363a)&&(_0x35d981['return']=!0x0,_0x35d981['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x430cb2=>{_0x430cb2['on']('attribute:vid',(_0x134eb0,_0x3e161f,_0x1d973b)=>{if('\x20'!=_0x3e161f['item']['data']||_0x3e161f['item']['parent']['maxOffset']>0x1)return;if(!_0x1d973b['consumable']['consume'](_0x3e161f['item'],_0x134eb0['name']))return;const _0x57e2f2=_0x1d973b['writer'],_0x5849b2=_0x1d973b['mapper']['toViewRange'](_0x3e161f['range']);_0x57e2f2['wrap'](_0x5849b2,_0x57e2f2['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x39c0eb){const _0x4da209=_0x39c0eb['plugins']['get']('RevisionViewer');return(_0x164050,_0x39216b,_0x332ccd)=>{const _0x1a6385=_0x39216b['markerName']['split'](':')[0x1],_0x189566=_0x4da209['_getChangeFromId'](_0x1a6385);if(!_0x189566)return null;const _0x3a7d1f='add'==_0x189566['type']?'split':'merge';if(!_0x332ccd['consumable']['test'](_0x39216b['markerRange'],_0x164050['name']))return;const _0x101ce0=_0x39216b['markerRange']['getWalker'](),_0x564296=_0x39216b['markerRange']['start'],_0x2a2bac=_0x39c0eb['model']['schema'];let _0x18f149=null,_0x3e6c6e=null,_0x3ad57b=!0x1,_0x300296=!0x1;for(const _0x50b9ba of _0x101ce0){const _0x5ac297=_0x50b9ba['item'];_0x3ad57b=_0x3ad57b||_0x2a2bac['isContent'](_0x5ac297);const _0x7c1ace=_0x332ccd['mapper']['toViewElement'](_0x5ac297);if(_0x7c1ace&&_0x7c1ace['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x50b9ba['type']&&(_0x2a2bac['isBlock'](_0x5ac297)&&!_0x2a2bac['isLimit'](_0x5ac297)&&(_0x5ac297['nextSibling']||_0x564296['isAtEnd']?_0x18f149&&_0x18f149['parent']==_0x5ac297||(_0x18f149=_0x5ac297,_0x43f9e7(_0x50b9ba['previousPosition']),_0x300296=!0x0):_0x3e6c6e=_0x3e6c6e||_0x50b9ba['previousPosition']));}function _0x43f9e7(_0x19fb58){const _0x19c934=_0x332ccd['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x3a7d1f}),_0x160ef5=_0x332ccd['mapper']['toViewPosition'](_0x19fb58);_0x189566['data']['isSuggestion']&&_0x332ccd['writer']['addClass']('ck-suggestion-marker-'+_0x3a7d1f+'-new',_0x19c934),_0x4da209['activeChange']==_0x189566&&_0x332ccd['writer']['addClass']('ck-suggestion-marker--active',_0x19c934),_0x332ccd['writer']['insert'](_0x160ef5,_0x19c934),_0x332ccd['mapper']['bindElementToMarker'](_0x19c934,_0x39216b['markerName']);}_0x3ad57b||_0x300296||!_0x3e6c6e||_0x43f9e7(_0x3e6c6e);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x1b2511,_0x5336a9,_0x29f1ee)=>{const _0x82f2a8=_0x29f1ee['mapper']['markerNameToElements'](_0x5336a9['markerName']);if(_0x82f2a8){for(const _0x5dc106 of _0x82f2a8)(_0x5dc106['hasClass']('ck-suggestion-marker-split')||_0x5dc106['hasClass']('ck-suggestion-marker-merge'))&&(_0x29f1ee['mapper']['unbindElementFromMarkerName'](_0x5dc106,_0x5336a9['markerName']),_0x29f1ee['writer']['remove'](_0x5dc106));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x188bd9,_0x3eb86b,_0x14c3f0)=>{const _0x27dcd7=_0x3eb86b['markerName']['split'](':')[0x1],_0x348fc2=this['_getChangeFromId'](_0x27dcd7);if(!_0x348fc2)return null;const _0x489fa3='add'==_0x348fc2['type']?'split':'merge';if(_0x14c3f0['consumable']['test'](_0x3eb86b['markerRange'],_0x188bd9['name']))for(const _0x58b21d of _0x3eb86b['markerRange']['getItems']()){if(!_0x58b21d['is']('element','softBreak'))continue;const _0x209205=_0x14c3f0['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x489fa3}),_0x5a0ce1=_0x14c3f0['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x58b21d));_0x348fc2['data']['isSuggestion']&&_0x14c3f0['writer']['addClass']('ck-suggestion-marker-'+_0x489fa3+'-new',_0x209205),this['activeChange']==_0x348fc2&&_0x14c3f0['writer']['addClass']('ck-suggestion-marker--active',_0x209205),_0x14c3f0['writer']['insert'](_0x5a0ce1,_0x209205),_0x14c3f0['mapper']['bindElementToMarker'](_0x209205,_0x3eb86b['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x79aed0=>{for(const _0x368b6e of this['editor']['model']['document']['getRootNames']()){const _0x3212aa=this['editor']['model']['document']['getRoot'](_0x368b6e),_0x3aece2=this['editor']['editing']['view']['document']['getRoot'](_0x368b6e);if(_0x3aece2){const _0x4ca9b4=_0x3212aa['getAttribute']('revisionHistoryAttachChange');if(_0x79aed0['removeAttribute']('data-change-id',_0x3aece2),_0x79aed0['removeClass']('ck-revision-history-root-add',_0x3aece2),_0x79aed0['removeClass']('ck-revision-history-root-remove',_0x3aece2),_0x79aed0['removeClass']('ck-revision-history-root--active',_0x3aece2),_0x4ca9b4){const _0x233668=this['_getChangeFromId'](_0x4ca9b4);if(!_0x233668)return null;_0x79aed0['setAttribute']('data-change-id',_0x4ca9b4,_0x3aece2),_0x79aed0['addClass']('ck-revision-history-root-'+_0x233668['type'],_0x3aece2),this['activeChange']==_0x233668&&_0x79aed0['addClass']('ck-revision-history-root--active',_0x3aece2);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x14710c=>'revision-comment:'+_0x14710c,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x3ae038=>'revision-suggestion:'+_0x3ae038,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x57af57=>({'name':'suggestion:'+_0x57af57,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x41cabe=>{const _0x5b6f09=_0x41cabe['markerName']['split'](':')[0x1];return'insertion'!=_0x5b6f09&&'deletion'!=_0x5b6f09?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x5b6f09]};}}),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',(_0x5b8c69,_0x2ba958,_0x824150)=>{const _0x2a75fc=_0x824150['mapper']['markerNameToElements'](_0x2ba958['markerName']);if(_0x2a75fc){for(const _0x5d8fc7 of _0x2a75fc)_0x5d8fc7['is']('uiElement')&&(_0x824150['mapper']['unbindElementFromMarkerName'](_0x5d8fc7,_0x2ba958['markerName']),_0x824150['writer']['remove'](_0x5d8fc7));}},{'priority':'high'});}['_getChangeFromId'](_0x319688){return this['_changeIdToChange']['get'](_0x319688);}['_getViewForChange'](_0x5e3829){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new z(this['editor']['locale'],_0x5e3829),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x2fe93a,_0x6990d3,_0x677814,_0x59505c)=>{_0x59505c&&this['_balloon']['remove'](_0x59505c),_0x677814&&(this['_balloon']['add']({'view':_0x677814,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x5c7516=this['editor']['editing'],_0x32ba4d=this['_getChangeFromId'](_0x677814['changeId']);let _0x2b4407;if(_0x32ba4d['data']['isOnRoot']){const _0x20c9d2=_0x5c7516['view']['getDomRoot'](_0x32ba4d['rootName']);_0x2b4407=Array['from'](_0x20c9d2['getClientRects']());}else{const _0x5dc6ad=this['editor']['model']['markers']['get']('revision:'+_0x677814['changeId']);_0x2b4407=Array['from'](_0x5c7516['mapper']['markerNameToElements'](_0x5dc6ad['name']))['map'](_0xd37109=>_0x5c7516['view']['domConverter']['mapViewToDom'](_0xd37109))['map'](_0x1f4f1a=>Array['from'](_0x1f4f1a['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x2b4407[0x0];return _0x2b4407['find'](_0x2861d8=>_0x2861d8['top']-0x3<=this['_activeViewTarget']['y']&&_0x2861d8['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x2861d8['left']-0x3<=this['_activeViewTarget']['x']&&_0x2861d8['right']+0x3>=this['_activeViewTarget']['x'])||_0x2b4407[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0xcc21b4,_0xd7f720,_0x224b8e,_0x1bf0db)=>{this['activeView']=_0x224b8e?this['_getViewForChange'](_0x224b8e):null,this['editor']['model']['change'](()=>{const _0x3abea5=this['editor']['editing'];_0x1bf0db&&(_0x1bf0db['data']['isOnRoot']?_0x3abea5['view']['change'](_0x26a42d=>{_0x26a42d['removeClass']('ck-revision-history-root--active',_0x3abea5['view']['document']['getRoot'](_0x1bf0db['rootName']));}):_0x3abea5['reconvertMarker']('revision:'+_0x1bf0db['id'])),_0x224b8e&&(_0x224b8e['data']['isOnRoot']?_0x3abea5['view']['change'](_0x25e0e9=>{_0x25e0e9['addClass']('ck-revision-history-root--active',_0x3abea5['view']['document']['getRoot'](_0x224b8e['rootName']));}):_0x3abea5['reconvertMarker']('revision:'+_0x224b8e['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x4cb38a,_0x470b3d)=>{if(this['activeChange'])return;const _0x4bb349=this['_findChangeIdFromDomTarget'](_0x470b3d['target']),_0x54f333=this['_changeIdToChange']['get'](_0x4bb349);_0x54f333?(this['_activeViewTarget']={'x':_0x470b3d['domEvent']['x'],'y':_0x470b3d['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x54f333)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x4710c5,_0x5838d4)=>{const _0x41853e=this['_findChangeIdFromDomTarget'](_0x5838d4['target']),_0x5b60b3=this['_changeIdToChange']['get'](_0x41853e);_0x5b60b3?(this['_activeViewTarget']={'x':_0x5838d4['domEvent']['x'],'y':_0x5838d4['domEvent']['y']},_0x5b60b3===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x5b60b3):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x560079){do{const _0xd1906c=_0x560079['getAttribute']('data-change-id');if(_0xd1906c)return _0xd1906c;_0x560079=_0x560079['parent'];}while(_0x560079);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x1dfc24=>{for(const _0x8adeba of this['editor']['model']['markers'])_0x1dfc24['removeMarker'](_0x8adeba);});}}function Q(_0x3f311a,_0x189eaf){return(_0x1e4a11,_0x2691c3,_0x2f1fb5)=>{if(!_0x2f1fb5['consumable']['test'](_0x2691c3['markerRange'],_0x1e4a11['name']))return;const _0x3d99a4=_0x2691c3['markerRange']['getWalker'](),_0x30c1d3=_0x2691c3['markerRange']['start'],_0x24c810=_0x3f311a['model']['schema'];let _0x5bcade=null,_0x36bbca=null,_0x413cb3=!0x1,_0x1817bc=!0x1;for(const _0x29f05a of _0x3d99a4){const _0x1467dd=_0x29f05a['item'];_0x413cb3=_0x413cb3||_0x24c810['isContent'](_0x1467dd);const _0x256e60=_0x2f1fb5['mapper']['toViewElement'](_0x1467dd);if(_0x256e60&&_0x256e60['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x29f05a['type']&&(_0x24c810['isBlock'](_0x1467dd)&&!_0x24c810['isLimit'](_0x1467dd)&&(_0x1467dd['nextSibling']||_0x30c1d3['isAtEnd']?_0x5bcade&&_0x5bcade['parent']==_0x1467dd||(_0x5bcade=_0x1467dd,_0x4d2d62(_0x29f05a['previousPosition']),_0x1817bc=!0x0):_0x36bbca=_0x36bbca||_0x29f05a['previousPosition']));}function _0x4d2d62(_0x3f57d5){const _0x5a102d=_0x2f1fb5['mapper']['toViewPosition'](_0x3f57d5),_0x47a7c0=_0x2f1fb5['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x189eaf});_0x2f1fb5['writer']['insert'](_0x5a102d,_0x47a7c0),_0x2f1fb5['mapper']['bindElementToMarker'](_0x47a7c0,_0x2691c3['markerName']);}_0x413cb3||_0x1817bc||!_0x36bbca||_0x4d2d62(_0x36bbca);};}class nt extends _0x3dab4f{constructor(_0x3954bf){super(_0x3954bf);const _0x305225=_0x3954bf['plugins']['get'](l);this['affectsData']=!0x1,this['listenTo'](_0x305225,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x305225,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0xd078c0=this['editor'],_0x1a1cd1=_0xd078c0['plugins']['get'](l),_0x59e475=_0x1a1cd1['isReady']?_0x1a1cd1['diff']['newRevisionId']:null;_0xd078c0['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x59e475);}['refresh'](){const {isReady:_0x247d86,isEnabled:_0x25236d,repository:_0x4e91a2,diff:_0x1bb5be}=this['editor']['plugins']['get'](l),_0x4d9e93=_0x1bb5be&&_0x4e91a2['getLaterVisibleRevision'](_0x1bb5be['newRevisionId']);this['isEnabled']=_0x247d86&&_0x25236d&&Boolean(_0x4d9e93);}}class rt extends _0x3dab4f{['_step'];constructor(_0xe79849,{direction:_0x403173}){super(_0xe79849);const _0x1ee214=_0xe79849['plugins']['get'](l);this['affectsData']=!0x1,this['_step']='forward'===_0x403173?0x1:-0x1,this['listenTo'](_0x1ee214,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x1ee214,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x1ee214,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x188b82=this['editor'],_0x33d4c1=_0x188b82['plugins']['get'](l),{isNavigationMode:_0x4ebce4,currentChangeNumber:_0x156a68}=_0x33d4c1;let _0x4630b4;if(_0x33d4c1['activeChange']=_0x4ebce4?_0x33d4c1['diff']['changes']['get'](_0x156a68+this['_step']):_0x33d4c1['diff']['changes']['first'],_0x33d4c1['activeChange']['data']['isOnRoot'])_0x4630b4=_0x188b82['editing']['view']['getDomRoot'](_0x33d4c1['activeChange']['rootName']);else{const _0x2fab1a=_0x188b82['model']['markers']['get']('revision:'+_0x33d4c1['activeChange']['id']);_0x4630b4=_0x3d22cf(_0x188b82['editing'],_0x2fab1a);}_0x5d40e9({'target':_0x4630b4,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x247219,currentChangeNumber:_0x452305,numberOfChanges:_0x5c139c,isReady:_0x52a516,isEnabled:_0x104ff9}=this['editor']['plugins']['get'](l);this['isEnabled']=!!(_0x104ff9&&_0x52a516&&_0x5c139c)&&(!_0x247219||(0x1===this['_step']?_0x452305<_0x5c139c-0x1:_0x452305>0x0));}}class Ri extends _0x2978dc{constructor(_0x2674a5){super(_0x2674a5);const _0x3cfad3=this['bindTemplate'],_0x4dc636=new _0x3ced20(_0x2674a5),_0x292358=new _0x3ced20(_0x2674a5);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',(_0x2dc935,_0xd7ed4e)=>_0x2dc935&&_0xd7ed4e>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x5c16fe,_0x2fd229,_0x4947fa,_0x27c498)=>{if(!_0x5c16fe)return R(_0x2674a5,'Loading...');if(!_0x4947fa)return R(_0x2674a5,'No\x20changes');const _0x1f7198=R(_0x2674a5,'NUMBER_OF_CHANGES',_0x4947fa);return _0x27c498?R(_0x2674a5,'X_OF_Y_CHANGES',[_0x2fd229+0x1,_0x4947fa]):_0x1f7198;}),_0x4dc636['set']({'label':R(_0x2674a5,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x54f190}),_0x292358['set']({'label':R(_0x2674a5,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x4bb357}),_0x4dc636['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x292358['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x4dc636['on']('execute',()=>this['fire']('execute','backward')),_0x292358['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',_0x3cfad3['if']('_isStatusLabelVisible','ck-hidden',_0xc84bdc=>!_0xc84bdc)]},'children':[{'text':_0x3cfad3['to']('isNavigationMode',_0x14598c=>_0x14598c?R(_0x2674a5,'EDIT_X_OF_Y_REVISIONS')+':\x20':R(_0x2674a5,'Total')+':\x20')}]},{'text':_0x3cfad3['to']('_statusText')}]},new _0x2b1b00(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x4dc636,_0x292358]}]});}}const ge='ck-editor__editable__loading-overlay';class ji extends _0x235b76{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x290124=this['editor']['editing']['view'];_0x290124['change'](_0x290155=>{for(const _0x593de2 of _0x290124['document']['roots'])_0x290155['addClass'](ge,_0x593de2);});}['hide'](){const _0x3f5b7f=this['editor']['editing']['view'];_0x3f5b7f['change'](_0x1a6dff=>{for(const _0x1a1cb0 of _0x3f5b7f['document']['roots'])_0x1a6dff['removeClass'](ge,_0x1a1cb0);});}}class u extends _0x235b76{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l,ji];}['init'](){const _0x1057dd=this['editor'],_0x459bda=_0x1057dd['plugins']['get'](l),_0x53ec80=_0x1057dd['plugins']['get'](ji);_0x1057dd['ui']['componentFactory']['add']('exitToEditing',_0x2e613c=>{const _0x457d64=new _0x3ced20(_0x2e613c);return _0x457d64['set']({'label':R(_0x2e613c,'Back\x20to\x20editing'),'icon':_0x3ff679,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x457d64,'execute',()=>{_0x1057dd['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x457d64;}),_0x1057dd['ui']['componentFactory']['add']('restoreRevision',_0x1f0bd7=>{const _0x323793=new _0x3ced20(_0x1f0bd7);return _0x323793['set']({'label':R(_0x1f0bd7,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x323793['bind']('isEnabled')['to'](_0x1057dd['commands']['get']('restoreRevision')),this['listenTo'](_0x323793,'execute',()=>_0x1057dd['execute']('restoreRevision')),_0x323793;}),_0x1057dd['ui']['componentFactory']['add']('changesNavigation',_0xcbeb92=>{const _0x44efb7=new Ri(_0xcbeb92),_0x3b5603=_0x1057dd['commands']['get']('showPreviousChange'),_0x5e4712=_0x1057dd['commands']['get']('showNextChange');return _0x44efb7['bind']('isBackwardNavigationEnabled')['to'](_0x3b5603,'isEnabled'),_0x44efb7['bind']('isForwardNavigationEnabled')['to'](_0x5e4712,'isEnabled'),_0x44efb7['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x459bda),this['listenTo'](_0x44efb7,'execute',(_0x450e18,_0xbd8d4a)=>{_0x1057dd['execute']('forward'===_0xbd8d4a?'showNextChange':'showPreviousChange');}),_0x44efb7;}),_0x53ec80['show'](),_0x459bda['on']('change:isReady',(_0x590b29,_0xbfdddc,_0x40f591)=>{_0x40f591?_0x53ec80['hide']():_0x53ec80['show']();});}}class hi extends et{['_resizeObserver']=null;constructor(_0x58838a,_0x3bd571){super(_0x58838a,_0x3bd571);const _0x2bd636=this['bindTemplate'];this['set']({'label':R(_0x58838a,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=R(_0x58838a,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x2bd636['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 _0x2b52bf=this['fieldView']['element'];this['_tooltipString']=_0x2b52bf['scrollWidth']>_0x2b52bf['clientWidth']&&_0x2b52bf['value']||'';}}class ni extends _0x2978dc{constructor(_0x5d542c,_0x5cf6b7,_0x4194ed){super(_0x5d542c);const _0x356ed1=new _0x34c740();_0x356ed1['set']({'content':_0x5b6cfe,'viewBox':'0\x200\x2011\x2010'});const _0x317839=['ck','ck-revision-history-sidebar__revision-author'];_0x4194ed&&_0x317839['push']('ck-revision-history-sidebar__revision-author_creator');const _0x516697=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':R(_0x5d542c,_0x4194ed?'Revision\x20creator':'Revision\x20author')},'children':[_0x356ed1,_0x5cf6b7['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x317839},'children':_0x516697});}}function ci(_0x1dd151,_0x12e84e){const _0x3f978d=_0x1dd151['bindTemplate'],_0x14af37=_0x1dd151['locale'],_0x686821=_0x5e74ef(_0x14af37);_0x686821['panelPosition']='sw';const _0x52277f=function(_0xf12f69,_0x3118ba){const _0x2899c0=function(_0x158338,_0x4dc0eb){const _0x47098b=_0x158338['locale'],_0x20d7be={'Compare\x20against\x20selected':R(_0x47098b,'Compare\x20against\x20selected'),'Name\x20this\x20revision':R(_0x47098b,'Name\x20this\x20revision'),'Restore\x20this\x20revision':R(_0x47098b,'Restore\x20this\x20revision')};return _0x4dc0eb['map'](_0x1b2489=>{const _0x54aa1a=_0x20d7be[_0x1b2489['name']];return _0x54aa1a&&_0x54aa1a!==_0x1b2489['name']&&(_0x1b2489['name']=_0x54aa1a),_0x1b2489;});}(_0xf12f69,_0x3118ba),_0x32ed25=new _0x3ac57f();for(const _0x13a953 of _0x2899c0){const _0x3a0bd3={'type':'button','model':new to({'label':_0x13a953['name'],'class':_0x13a953['class'],'withText':!0x0,'role':'menuitem','_action':_0x13a953['action']})};_0x3a0bd3['model']['bind']('isEnabled')['to'](_0xf12f69,'isActionsDropdownOpen',_0x4a1656=>'function'!=typeof _0x13a953['isEnabled']||(!_0x4a1656||_0x13a953['isEnabled'](_0xf12f69))),_0x32ed25['add'](_0x3a0bd3);}return _0x32ed25;}(_0x1dd151,_0x12e84e);return _0x1dd151['bind']('isActionsDropdownOpen')['to'](_0x686821,'isOpen'),_0x686821['buttonView']['set']({'label':R(_0x14af37,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x5c4da2}),_0x686821['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x3f978d['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x3f978d['to'](_0x1df0f8=>_0x1df0f8['stopPropagation']())}}),_0x686821['on']('execute',_0x4ebbd7=>{_0x1dd151['isReady']&&'function'==typeof _0x4ebbd7['source']['_action']&&_0x4ebbd7['source']['_action'](_0x1dd151);}),_0x2000a3(_0x686821,_0x52277f,{'role':'menu'}),_0x686821['listenTo'](_0x1dd151,'change:isActionsDropdownOpen',(_0x113f61,_0x3c5b44,_0x1d333b)=>{if(_0x1d333b)for(const _0x22eb2a of _0x686821['listView']['items']){const _0x577c0c=_0x22eb2a['children']['first'],_0x50c147=_0x12e84e['find'](_0x590a3d=>_0x590a3d['action']===_0x577c0c['_action'])['isVisible'];_0x22eb2a['isVisible']=void 0x0===_0x50c147||_0x50c147(_0x1dd151);}}),_0x686821;}class vi extends/* #__PURE__ -- @preserve */
|
|
27
|
-
|
|
23
|
+
import{ObservableMixin as _0x1b5e58,uid as _0xe8fa3b,Collection as _0xb0d30e,logWarning as _0x262eb6,FocusTracker as _0x1b8ed5,KeystrokeHandler as _0x586743,scrollViewportToShowTarget as _0x557404,ResizeObserver as ot,ElementReplacer as it,CKEditorError as _0x1959ba}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x1184a6,set as _0xce2506,unset as _0x115195,isEqual as _0x297bd1}from'es-toolkit/compat';import{Plugin as _0x1eb7a5,PendingActions as _0x230593,Command as _0x63058a,ElementApiMixin as _0x27d20d,Editor as _0x546a66}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x1bea53,getMarkerDomElement as _0x43fbbc,ConfirmMixin as _0x257fd9,sanitizeEditorConfig as _0x30bb80}from'ckeditor5-collaboration/dist/index.js';import{ViewContainerElement as _0x285fc8,ViewAttributeElement as _0x227db8,ViewEmptyElement as _0x434982,ViewRawElement as _0x35d8c8,ViewUIElement as _0x415344,ViewDocumentFragment as _0x225620,ViewText as _0x3fd389,ViewElement as _0x309f6f,ModelElement as _0x1feb76,ModelRange as _0x1f4939,ModelPosition as _0x4ad552,ModelDocumentFragment as _0x235d32,ModelText as _0x5ce995}from'@ckeditor/ckeditor5-engine/dist/index.js';import{IconHistory as _0x368a30,IconChevronUp as _0x360e11,IconChevronDown as _0x28d147,IconUndo as _0x11cea3,IconUser as _0x1269d6,IconThreeVerticalDots as _0xff9fef}from'@ckeditor/ckeditor5-icons/dist/index.js';import{CssTransitionDisablerMixin as _0x4ba853,View as _0x3f2314,submitHandler as _0x40656b,LabeledFieldView as et,createLabeledInputText as ti,createDropdown as _0x5be730,ListView as _0x1b93b8,ListItemView as _0x516099,ButtonView as _0x21b928,MenuBarMenuView as _0x4500c0,MenuBarMenuListView as _0x5b6fb8,MenuBarMenuListItemView as _0x44eb32,MenuBarMenuListItemButtonView as _0x4a7f4d,ContextualBalloon as _0x2864ff,ToolbarSeparatorView as _0x3bddfb,IconView as _0x21a133,addListToDropdown as _0x525fe6,UIModel as to,EditorUI as tt,normalizeToolbarConfig as st,BoxedEditorUIView as _0x4aec7b,StickyPanelView as _0x440a34,ToolbarView as _0x994f94,InlineEditableUIView as te}from'@ckeditor/ckeditor5-ui/dist/index.js';import{DateTime as _0x2abda7}from'luxon';class I extends/* #__PURE__ -- @preserve */
|
|
24
|
+
_0x1b5e58(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x551f79){super(),this['id']=_0x551f79['id']||_0xe8fa3b(),this['creator']=_0x551f79['creator']||null,this['authors']=_0x551f79['authors']||[],this['diffData']=_0x551f79['diffData']||null,this['toVersion']=_0x551f79['toVersion']||0x0,this['fromVersion']=_0x551f79['fromVersion']||0x0,this['set']('name',_0x551f79['name']||''),this['set']('createdAt',_0x551f79['createdAt']||new Date()),this['set']('attributes',_0x551f79['attributes']||{});}['setName'](_0x1ee29b){this['_update']({'name':_0x1ee29b});}['setAttribute'](_0x4eb203,_0x2f5d3b){const _0x438757=_0x1184a6(this['attributes']);_0xce2506(_0x438757,_0x4eb203,_0x2f5d3b),this['_update']({'attributes':_0x438757});}['removeAttribute'](_0x5055e6){const _0x2e05f5=_0x1184a6(this['attributes']);_0x115195(_0x2e05f5,_0x5055e6),this['_update']({'attributes':_0x2e05f5});}['_update'](_0x5daf06,_0x1fca19=!0x1){let _0x11b56c=!0x1;const _0x3837e9={'id':this['id']},_0x34a2a2=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x36137d of _0x34a2a2){const _0x166c3a=_0x5daf06[_0x36137d];void 0x0!==_0x166c3a&&_0x166c3a!==this[_0x36137d]&&(this[_0x36137d]=_0x166c3a,_0x3837e9[_0x36137d]=_0x166c3a,_0x11b56c=!0x0);}_0x11b56c&&(_0x3837e9['authors']&&(_0x3837e9['authorsIds']=_0x3837e9['authors']['map'](_0x354446=>_0x354446['id']),delete _0x3837e9['authors']),this['fire']('_update',_0x3837e9,_0x1fca19));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x551dca=>_0x551dca['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class S extends _0x1eb7a5{['_revisions'];static get['requires'](){return[_0x1bea53];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x4f04d7){super(_0x4f04d7),this['_revisions']=new _0xb0d30e();}['afterInit'](){!async function(_0x15291b){const _0x1a27d1=_0x3ec778([0x79,0x72,0x44,0x68,0x74,0x4b,0x58,0x76,0x46,0x61,0x7a,0x39,0x6d,0x56,0x42,0x37,0x53,0x33,0x45,0x6e,0x4c,0x36,0x49,0x41,0x6c,0x52,0x71,0x51,0x34,0x6f,0x4d,0x54,0x67,0x62,0x66,0x63,0x47,0x38,0x77,0x64,0x30,0x4e,0x6a,0x48,0x5a,0x65,0x78,0x50,0x59,0x57,0x4f,0x35,0x6b,0x32,0x31,0x55,0x70,0x75,0x4a,0x73,0x43,0x69]),_0x53df66=0xeb829,_0x403035=0x1abff38d,_0x5a2548=0x1ab89c85^_0x403035,_0x3c9461=window[_0x3ec778([0x44,0x61,0x74,0x65])][_0x3ec778([0x6e,0x6f,0x77])](),_0x52d1da=_0x15291b[_0x3ec778([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x5a915d=new window[(_0x3ec778([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x1ab115=>{_0x52d1da[_0x3ec778([0x6f,0x6e,0x63,0x65])](_0x3ec778([0x72,0x65,0x61,0x64,0x79]),_0x1ab115);}),_0x483d00={[_0x3ec778([0x6b,0x74,0x79])]:_0x3ec778([0x45,0x43]),[_0x3ec778([0x75,0x73,0x65])]:_0x3ec778([0x73,0x69,0x67]),[_0x3ec778([0x63,0x72,0x76])]:_0x3ec778([0x50,0x2d,0x32,0x35,0x36]),[_0x3ec778([0x78])]:_0x3ec778([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]),[_0x3ec778([0x79])]:_0x3ec778([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]),[_0x3ec778([0x61,0x6c,0x67])]:_0x3ec778([0x45,0x53,0x32,0x35,0x36])},_0xd0a0f5=_0x52d1da[_0x3ec778([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x3ec778([0x67,0x65,0x74])](_0x3ec778([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x9b555f(){let _0x297aa6,_0x4de518=null,_0x1fa877=null;try{if(_0xd0a0f5==_0x3ec778([0x47,0x50,0x4c]))return _0x3ec778([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x297aa6=_0x4e9646(),!_0x297aa6)return _0x3ec778([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x297aa6[_0x3ec778([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x1fa877=_0xb4bf44(_0x297aa6[_0x3ec778([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x297aa6[_0x3ec778([0x6a,0x74,0x69])])),await _0x3986c6()?_0x34853a()?_0x27c2e4()?_0x3ec778([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x5d30e4()?(_0x297aa6[_0x3ec778([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x3ec778([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x4de518=_0x3a00f9(_0x3ec778([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x297aa6[_0x3ec778([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x3ec778([0x74,0x72,0x69,0x61,0x6c])&&(_0x4de518=_0x3a00f9(_0x3ec778([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x1f901d()):_0x3ec778([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x3ec778([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x3ec778([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x3ec778([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x27c2e4(){const _0x3c82c9=[_0x3ec778([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x3ec778([0x74,0x72,0x69,0x61,0x6c])][_0x3ec778([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x297aa6[_0x3ec778([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x3c9461/0x3e8:0xe10*_0x5a2548;return _0x297aa6[_0x3ec778([0x65,0x78,0x70])]<_0x3c82c9;}function _0x34853a(){const _0x1a404d=_0x297aa6[_0x3ec778([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x1a404d)return!0x1;if(_0x1a404d[_0x3ec778([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x3ec778([0x2a])))return!0x0;if(_0x1a404d[_0x3ec778([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x3ec778([0x52,0x48])))return!0x0;if(_0x1a404d[_0x3ec778([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x3ec778([0x52,0x52,0x48]))){if(_0x54aa0a())return!0x0;if(_0x2fcc40()||_0x2de8d7())return!0x0;}return!0x1;}function _0x5d30e4(){const _0x275fad=_0x297aa6[_0x3ec778([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x275fad||0x0==_0x275fad[_0x3ec778([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x46d144}=new URL(window[_0x3ec778([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x275fad[_0x3ec778([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x46d144))return!0x0;const _0x4df841=_0x46d144[_0x3ec778([0x73,0x70,0x6c,0x69,0x74])](_0x3ec778([0x2e]));return _0x275fad[_0x3ec778([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x1f2ff4=>_0x1f2ff4[_0x3ec778([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x3ec778([0x2a])))[_0x3ec778([0x6d,0x61,0x70])](_0x557308=>_0x557308[_0x3ec778([0x73,0x70,0x6c,0x69,0x74])](_0x3ec778([0x2e])))[_0x3ec778([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x3743da=>_0x3743da[_0x3ec778([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x4df841[_0x3ec778([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x3ec778([0x6d,0x61,0x70])](_0x3efd5b=>Array(_0x4df841[_0x3ec778([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0x3efd5b[_0x3ec778([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x3ec778([0x66,0x69,0x6c,0x6c])](_0x3efd5b[0x0]===_0x3ec778([0x2a])?_0x3ec778([0x2a]):'')[_0x3ec778([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0x3efd5b))[_0x3ec778([0x73,0x6f,0x6d,0x65])](_0x4dc629=>_0x4df841[_0x3ec778([0x65,0x76,0x65,0x72,0x79])]((_0x370b1e,_0x384830)=>_0x4dc629[_0x384830]===_0x370b1e||_0x4dc629[_0x384830]===_0x3ec778([0x2a])));}function _0x1f901d(){return _0x4de518&&_0x1fa877?new window[(_0x3ec778([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x2666ed,_0xea10bb)=>{_0x4de518[_0x3ec778([0x74,0x68,0x65,0x6e])](_0x2666ed,_0xea10bb),_0x1fa877[_0x3ec778([0x74,0x68,0x65,0x6e])](_0x2ab33d=>{_0x2ab33d!=_0x3ec778([0x56,0x61,0x6c,0x69,0x64])&&_0x2666ed(_0x2ab33d);},_0xea10bb);}):_0x4de518||_0x1fa877||_0x3ec778([0x56,0x61,0x6c,0x69,0x64]);}}function _0xb4bf44(_0x5f4ff3,_0x411443){return new window[(_0x3ec778([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x734c64=>{if(_0x28d67b())return _0x734c64(_0x3ec778([0x56,0x61,0x6c,0x69,0x64]));_0x43c8ff(),_0x52d1da[_0x3ec778([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x3ec778([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x511ca9=!0x1;const _0x55a367=_0xe8fa3b();function _0x2e7933(_0x5bf5d1){return!!_0x5bf5d1&&(typeof _0x5bf5d1===_0x3ec778([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x5bf5d1===_0x3ec778([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x5bf5d1[_0x3ec778([0x74,0x68,0x65,0x6e])]===_0x3ec778([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x5bf5d1[_0x3ec778([0x63,0x61,0x74,0x63,0x68])]===_0x3ec778([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x2a6997(_0x4a768d){_0x54e90f(_0x4a768d)[_0x3ec778([0x74,0x68,0x65,0x6e])](_0x596ab7=>{if(!_0x596ab7||_0x596ab7[_0x3ec778([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x3ec778([0x6f,0x6b]))return _0x3ec778([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x500e58(_0x2c8cc0(_0x55a367+_0x411443))!=_0x596ab7[_0x3ec778([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x3ec778([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x3ec778([0x56,0x61,0x6c,0x69,0x64]);})[_0x3ec778([0x74,0x68,0x65,0x6e])](_0x560256=>(_0x3bb75b(),_0x560256),()=>{const _0x1d514c=_0x560324();return null==_0x1d514c?(_0x3bb75b(),_0x3ec778([0x56,0x61,0x6c,0x69,0x64])):_0x3ec778(_0x3c9461-_0x1d514c>(0x3eb3778d^_0x403035)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x3ec778([0x74,0x68,0x65,0x6e])](_0x734c64)[_0x3ec778([0x63,0x61,0x74,0x63,0x68])](()=>{_0x734c64(_0x3ec778([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x58649c=0x1a891d0d^_0x403035;function _0x3bb75b(){const _0x475123=_0x3ec778([0x6c,0x6c,0x63,0x74,0x2d])+_0x500e58(_0x2c8cc0(_0x5f4ff3)),_0x5629d8=_0x703255(_0x500e58(window[_0x3ec778([0x4d,0x61,0x74,0x68])][_0x3ec778([0x63,0x65,0x69,0x6c])](_0x3c9461/_0x58649c)));window[_0x3ec778([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x3ec778([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x475123,_0x5629d8);}function _0x560324(){const _0x5920a6=_0x3ec778([0x6c,0x6c,0x63,0x74,0x2d])+_0x500e58(_0x2c8cc0(_0x5f4ff3)),_0x552094=window[_0x3ec778([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x3ec778([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x5920a6);return _0x552094?window[_0x3ec778([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x703255(_0x552094),0x10)*_0x58649c:null;}function _0x54e90f(_0x42268f){return new window[(_0x3ec778([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x4ebd20,_0x139a25)=>{_0x42268f[_0x3ec778([0x74,0x68,0x65,0x6e])](_0x4ebd20,_0x139a25),window[_0x3ec778([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x139a25,0x1abe274d^_0x403035);});}}_0x52d1da[_0x3ec778([0x6f,0x6e])](_0x3ec778([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x5ba3d7,_0x258582)=>{if(_0x258582[0x0]!=_0x5f4ff3)return _0x734c64(_0x3ec778([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x258582[0x1]={..._0x258582[0x1],[_0x3ec778([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x55a367};},{[_0x3ec778([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x3ec778([0x68,0x69,0x67,0x68])}),_0x52d1da[_0x3ec778([0x6f,0x6e])](_0x3ec778([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0xe0eb4e=>{_0x2e7933(_0xe0eb4e[_0x3ec778([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x511ca9=!0x0,_0x2a6997(_0xe0eb4e[_0x3ec778([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x3ec778([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x3ec778([0x6c,0x6f,0x77])}),_0x5a915d[_0x3ec778([0x74,0x68,0x65,0x6e])](()=>{_0x511ca9||_0x734c64(_0x3ec778([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x28d67b(){return _0x52d1da[_0x3ec778([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x3ec778([0x76,0x69,0x65,0x77])][_0x3ec778([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x3ec778([0x61,0x75,0x74,0x6f]);}function _0x43c8ff(){_0x52d1da[_0x3ec778([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x3ec778([0x76,0x69,0x65,0x77])][_0x3ec778([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x3ec778([0x61,0x75,0x74,0x6f]);}}function _0x3a00f9(_0x5af752){const _0x2e38ea=[new window[(_0x3ec778([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2bf65f=>setTimeout(_0x2bf65f,0x1ab6cd41^_0x403035)),_0x5a915d[_0x3ec778([0x74,0x68,0x65,0x6e])](()=>new window[(_0x3ec778([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x522092=>{const _0x48d3c5=0x1abff38a^_0x403035,_0x1a4ed0=_0x15291b[_0x3ec778([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x548a87(){_0x1a4ed0[_0x3ec778([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x48d3c5&&_0x522092();}_0x548a87(),_0x1a4ed0[_0x3ec778([0x6f,0x6e])](_0x3ec778([0x61,0x64,0x64]),_0x548a87);})),new window[(_0x3ec778([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x534a7f=>{function _0xca8d51(){for(const _0x28e14b in window)if(window[_0x3ec778([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x3ec778([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x28e14b))&&window[_0x28e14b]==_0x53df66)return _0x534a7f();_0x52d1da[_0x3ec778([0x73,0x74,0x61,0x74,0x65])]!=_0x3ec778([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x3ec778([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0xca8d51,0x1abfe005^_0x403035);}_0x14f04a(_0x3ec778([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0xca8d51();})];return window[_0x3ec778([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x3ec778([0x72,0x61,0x63,0x65])](_0x2e38ea)[_0x3ec778([0x74,0x68,0x65,0x6e])](()=>_0x5af752);}async function _0x5118b8(){if(await _0x5a915d,_0x14f04a(_0x3ec778([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x52d444=_0x15291b[_0x3ec778([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x9dd518=_0x15291b[_0x3ec778([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])](_0x52d444[_0x3ec778([0x69,0x64])]),_0x24da9e=_0x5d666e(_0x3ec778([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x24da9e[_0x3ec778([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x52d444['id'],_0x9dd518?_0x9dd518['id']:null,!0x0),_0x24da9e[_0x3ec778([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x3ec778([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x24da9e[_0x3ec778([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x24da9e[_0x3ec778([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x2956b4,void(_0x24da9e[_0x3ec778([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x2956b4);}if(_0x14f04a(_0x3ec778([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x423da7=_0x5d666e(_0x3ec778([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x423da7[_0x3ec778([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x3ec778([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x423da7[_0x3ec778([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x423da7[_0x3ec778([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x2956b4,_0x423da7[_0x3ec778([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x2956b4;}_0x52d1da[_0x3ec778([0x6d,0x6f,0x64,0x65,0x6c])][_0x3ec778([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x2956b4,_0x52d1da[_0x3ec778([0x6d,0x6f,0x64,0x65,0x6c])][_0x3ec778([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x2956b4,_0x52d1da[_0x3ec778([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x3ec778([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x54aa0a(){return _0x14f04a(_0x3ec778([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x5d666e(_0x3ec778([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x3ec778([0x73,0x74,0x61,0x74,0x65])]==_0x3ec778([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x2fcc40(){return _0x14f04a(_0x3ec778([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 _0x2de8d7(){return _0x14f04a(_0x3ec778([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x1769f5(_0x4c3691){const _0x2bfb35=_0x2f41e4();_0x52d1da[_0x2bfb35]=_0x3ec778([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])+_0x4c3691,_0x4c3691[_0x3ec778([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x3ec778([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x2f41e4()]=_0x53df66),_0x4c3691!=_0x3ec778([0x56,0x61,0x6c,0x69,0x64])&&_0x5118b8();}function _0x2f41e4(){const _0x58f37b=window[_0x3ec778([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x3ec778([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x3ec778([0x6e,0x6f,0x77])]())[_0x3ec778([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x3ec778([0x2e]),'');let _0x4deae7=_0x3ec778([0x79]);for(let _0x26af55=0x0;_0x26af55<_0x58f37b[_0x3ec778([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x26af55+=0x2){let _0x187bba=window[_0x3ec778([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x58f37b[_0x3ec778([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x26af55,_0x26af55+0x2));_0x187bba>=_0x1a27d1[_0x3ec778([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x187bba-=_0x1a27d1[_0x3ec778([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x4deae7+=_0x1a27d1[_0x187bba];}return _0x4deae7;}function _0x4e9646(){const _0x1ed482=_0xd0a0f5[_0x3ec778([0x73,0x70,0x6c,0x69,0x74])](_0x3ec778([0x2e]));if(0x3!=_0x1ed482[_0x3ec778([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x476845(_0x1ed482[0x1]);function _0x476845(_0x5214cf){const _0x32b171=_0x3ef890(_0x5214cf);return _0x32b171&&_0x1abc88()?_0x32b171:null;function _0x1abc88(){const _0x47a8b7=_0x32b171[_0x3ec778([0x6a,0x74,0x69])],_0x22c41f=window[_0x3ec778([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x47a8b7[_0x3ec778([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x47a8b7[_0x3ec778([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x38da17={..._0x32b171,[_0x3ec778([0x6a,0x74,0x69])]:_0x47a8b7[_0x3ec778([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x47a8b7[_0x3ec778([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x38da17[_0x3ec778([0x76,0x63])],_0x2c8cc0(_0x38da17)==_0x22c41f;}}}async function _0x3986c6(){let _0x534089=!0x0;try{const _0x51560e=_0xd0a0f5[_0x3ec778([0x73,0x70,0x6c,0x69,0x74])](_0x3ec778([0x2e])),[_0x2a8e00,_0x4d7430,_0x1e293c]=_0x51560e;return _0x5b0c6b(_0x2a8e00),await _0x1135d3(_0x2a8e00,_0x4d7430,_0x1e293c),_0x534089;}catch{return!0x1;}function _0x5b0c6b(_0x45c96e){const _0x12e28e=_0x3ef890(_0x45c96e);_0x12e28e&&_0x12e28e[_0x3ec778([0x61,0x6c,0x67])]==_0x3ec778([0x45,0x53,0x32,0x35,0x36])||(_0x534089=!0x1);}async function _0x1135d3(_0x42265c,_0x4b6365,_0x585b95){const _0x9924d3=window[_0x3ec778([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x3ec778([0x66,0x72,0x6f,0x6d])](_0x2e2195(_0x585b95),_0x30f2fb=>_0x30f2fb[_0x3ec778([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x4cf250=new window[(_0x3ec778([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x3ec778([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x42265c+_0x3ec778([0x2e])+_0x4b6365),_0x1909b6=window[_0x3ec778([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x3ec778([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x1909b6)return;const _0x38e468=await _0x1909b6[_0x3ec778([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x3ec778([0x6a,0x77,0x6b]),_0x483d00,{[_0x3ec778([0x6e,0x61,0x6d,0x65])]:_0x3ec778([0x45,0x43,0x44,0x53,0x41]),[_0x3ec778([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x3ec778([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x3ec778([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x1909b6[_0x3ec778([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x3ec778([0x6e,0x61,0x6d,0x65])]:_0x3ec778([0x45,0x43,0x44,0x53,0x41]),[_0x3ec778([0x68,0x61,0x73,0x68])]:{[_0x3ec778([0x6e,0x61,0x6d,0x65])]:_0x3ec778([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x38e468,_0x9924d3,_0x4cf250)||(_0x534089=!0x1);}}function _0x3ef890(_0x3a984d){return _0x3a984d[_0x3ec778([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x3ec778([0x65,0x79]))?JSON[_0x3ec778([0x70,0x61,0x72,0x73,0x65])](_0x2e2195(_0x3a984d)):null;}function _0x2e2195(_0x2e4875){return window[_0x3ec778([0x61,0x74,0x6f,0x62])](_0x2e4875[_0x3ec778([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x3ec778([0x2b]))[_0x3ec778([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x3ec778([0x2f])));}function _0x2c8cc0(_0x252281){let _0x26c169=0x1505;function _0x378338(_0x3eb4bd){for(let _0x21d8df=0x0;_0x21d8df<_0x3eb4bd[_0x3ec778([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x21d8df++){const _0x5d701a=_0x3eb4bd[_0x3ec778([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x21d8df);_0x26c169=(_0x26c169<<0x5)+_0x26c169+_0x5d701a,_0x26c169&=_0x26c169;}}function _0x5ef411(_0x52da10){Array[_0x3ec778([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x52da10)?_0x52da10[_0x3ec778([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x5ef411):_0x52da10&&typeof _0x52da10==_0x3ec778([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x3ec778([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x52da10)[_0x3ec778([0x73,0x6f,0x72,0x74])]()[_0x3ec778([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x247d4b,_0x32e518])=>{_0x378338(_0x247d4b),_0x5ef411(_0x32e518);}):_0x378338(window[_0x3ec778([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x52da10));}return _0x5ef411(_0x252281),_0x26c169>>>0x0;}function _0x500e58(_0xcf7fdb){return _0xcf7fdb[_0x3ec778([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x3ec778([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x3ec778([0x30]));}function _0x703255(_0x1ad5a8){return _0x1ad5a8[_0x3ec778([0x73,0x70,0x6c,0x69,0x74])]('')[_0x3ec778([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x3ec778([0x6a,0x6f,0x69,0x6e])]('');}function _0x14f04a(_0x1f9f8b){return _0x52d1da[_0x3ec778([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x3ec778([0x68,0x61,0x73])](_0x1f9f8b);}function _0x5d666e(_0x40053d){return _0x52d1da[_0x3ec778([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x3ec778([0x67,0x65,0x74])](_0x40053d);}function _0x2956b4(){}function _0x3ec778(_0x21b0ba){return _0x21b0ba['map'](_0x176a6b=>String['fromCharCode'](_0x176a6b))['join']('');}_0x1769f5(await _0x9b555f());}(this);}['createRevision'](_0x2d7d6b){const _0x54eb95=this['editor']['plugins']['get']('Users');return new I({'id':_0x2d7d6b['id'],'name':_0x2d7d6b['name'],'creator':_0x2d7d6b['creatorId']?_0x54eb95['getUser'](_0x2d7d6b['creatorId']):null,'diffData':_0x2d7d6b['diffData']||_0x2d7d6b['data'],'authors':_0x2d7d6b['authorsIds']['map'](_0x42bcb3=>_0x54eb95['getUser'](_0x42bcb3)),'createdAt':new Date(_0x2d7d6b['createdAt']),'attributes':_0x2d7d6b['attributes'],'fromVersion':_0x2d7d6b['fromVersion'],'toVersion':_0x2d7d6b['toVersion']});}['addRevision'](_0x45f5e0,_0x44269c=0x0){this['_revisions']['add'](_0x45f5e0,_0x44269c);}['getRevision'](_0x16af8e){return this['_revisions']['get'](_0x16af8e);}['getRevisions'](_0x5c8344={'toJSON':!0x1}){const _0x12f9f3=Array['from'](this['_revisions']);return _0x12f9f3['reverse'](),_0x5c8344['toJSON']?_0x12f9f3['map'](_0xbeefd7=>_0xbeefd7['toJSON']()):_0x12f9f3;}['getIndex'](_0x20535a){return this['_revisions']['getIndex'](_0x20535a);}['getEarlierVisibleRevision'](_0x30f866){const [,_0x7ee392]=this['getRevisionsIterator'](_0x30f866,{'direction':'earlier'});return _0x7ee392;}['getLaterVisibleRevision'](_0x7d669e){const [,_0x435939]=this['getRevisionsIterator'](_0x7d669e,{'direction':'later'});return _0x435939;}['getRevisionsInDiff'](_0xc66bb3){const _0x576883=[];for(const _0xcf29a9 of this['getRevisionsIterator'](_0xc66bb3['newRevisionId']))if(_0x576883['push'](_0xcf29a9),_0xcf29a9['id']===_0xc66bb3['oldRevisionId'])break;return _0x576883;}*['getRevisionsIterator'](_0x5d3fce,{direction:_0x124ded='earlier',filter:_0x4f5bb9=()=>!0x0}={}){const _0x4b0cba='earlier'===_0x124ded?0x1:-0x1;let _0x31822f=this['_revisions']['get'](_0x5d3fce),_0x2660ff=this['getIndex'](_0x31822f);for(yield _0x31822f;_0x31822f;){if(_0x2660ff+=_0x4b0cba,_0x31822f=this['getRevision'](_0x2660ff),!_0x31822f)return;_0x4f5bb9(_0x31822f)&&(yield _0x31822f);}}}class $ extends _0x1eb7a5{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x285fc8,'c'],[_0x227db8,'a'],[_0x434982,'e'],[_0x35d8c8,'r'],[_0x415344,'u']]);['_typeCharToViewClass']=new Map([['c',_0x285fc8],['a',_0x227db8],['e',_0x434982],['r',_0x35d8c8],['u',_0x415344]]);async['loadRevisionData'](_0x5b123e,_0x1f7d4f){if(_0x5b123e['diffData']||!_0x1f7d4f)return;const _0x2d5216=this['editor']['config']['get']('collaboration.channelId'),_0x158196=await _0x1f7d4f['getRevision']({'channelId':_0x2d5216,'revisionId':_0x5b123e['id']});_0x5b123e['diffData']=_0x158196['diffData'];}['getRevisionDocumentData'](_0x24c8c6){const _0x1990a0={};for(const _0x576568 in _0x24c8c6['diffData']){if(_0x24c8c6['diffData'][_0x576568]['attachChange']&&!_0x24c8c6['diffData'][_0x576568]['attachChange']['isAttached'])continue;const _0xae900=this['_removeRevisionMarkers'](JSON['parse'](_0x24c8c6['diffData'][_0x576568]['insertions'])),_0x25cb61=this['editor']['editing']['view']['document'],_0x390f04=new _0x225620(_0x25cb61,_0xae900['map'](_0x4f0c51=>this['_getViewFromDiffObj'](_0x4f0c51,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x1990a0[_0x576568]=this['editor']['data']['processor']['toData'](_0x390f04),this['editor']['data']['processor']['useFillerType']('default');}return _0x1990a0;}['getRevisionRootsAttributes'](_0x3acdae){const _0x4f731e={};for(const _0xe310c0 in _0x3acdae['diffData'])_0x3acdae['diffData'][_0xe310c0]['attachChange']&&!_0x3acdae['diffData'][_0xe310c0]['attachChange']['isAttached']||(_0x4f731e[_0xe310c0]=_0x3acdae['diffData'][_0xe310c0]['attributesAfter']||{});return _0x4f731e;}['_getTypeCharForViewElement'](_0xbdf8d0){return this['_viewClassToTypeChar']['get'](_0xbdf8d0['constructor']);}['_getViewFromDiffObj'](_0x22ab8e,_0x4d976a){const _0x3d9fab=this['editor']['editing']['view']['document'];if('string'==typeof _0x22ab8e)return new _0x3fd389(_0x3d9fab,_0x22ab8e);{let _0xfdd2f,_0x19f252;_0x19f252='u'==_0x22ab8e['type']||'r'==_0x22ab8e['type']?[]:_0x22ab8e['children']['map'](_0x238560=>this['_getViewFromDiffObj'](_0x238560,_0x4d976a));const _0x4c5b6e=this['_typeCharToViewClass']['get'](_0x22ab8e['type'])||_0x309f6f,_0x563de5=this['editor']['data']['htmlProcessor']['domConverter'];if(_0xfdd2f=new _0x4c5b6e(_0x3d9fab,_0x22ab8e['name'],_0x22ab8e['attributes'],_0x19f252),'u'==_0x22ab8e['type']&&_0x22ab8e['children'][0x0]){const _0x208a25=_0x22ab8e['children'][0x0];if(_0xfdd2f['render']=function(_0x35b86e){const _0x2b3338=_0x35b86e['createElement']('div');return _0x2b3338['innerHTML']=_0x208a25,_0x2b3338['childNodes'][0x0];},_0x4d976a){const _0x2650bb=new _0x225620(_0x3d9fab);_0x2650bb['_appendChild'](_0xfdd2f);const _0x3eaceb=Array['from'](_0x563de5['viewChildrenToDom'](_0x2650bb,{'bind':!0x1})),_0x225682=_0x563de5['domDocument']['createElement']('div');_0x225682['append'](..._0x3eaceb),_0xfdd2f=Array['from'](_0x563de5['domChildrenToView'](_0x225682))[0x0];}}else{if('r'==_0x22ab8e['type']&&_0x22ab8e['children'][0x0]){const _0x3f3a4f=_0x22ab8e['children'][0x0];if(_0xfdd2f['render']=function(_0x52c326){_0x52c326['innerHTML']=_0x3f3a4f;},_0x4d976a){const _0xeb72ee=new _0x225620(_0x3d9fab);_0xeb72ee['_appendChild'](_0xfdd2f);const _0x14c24b=Array['from'](_0x563de5['viewChildrenToDom'](_0xeb72ee,{'bind':!0x1})),_0x13da11=_0x563de5['domDocument']['createElement']('div');_0x13da11['append'](..._0x14c24b);const _0x5e368c=Array['from'](_0x563de5['domChildrenToView'](_0x13da11));_0x5e368c['length']>0x1?_0xfdd2f['_appendChild'](_0x5e368c):_0xfdd2f=_0x5e368c[0x0];}}}if(_0x22ab8e['customProperties']){for(const [_0x385d80,_0x20e0e5]of _0x22ab8e['customProperties'])_0xfdd2f['_setCustomProperty'](_0x385d80,_0x20e0e5);}const _0x4327d0=void 0x0===_0x22ab8e['fillerOffset']?null:_0x22ab8e['fillerOffset'];return null!==_0x4327d0&&(_0xfdd2f['getFillerOffset']=()=>_0x4327d0),_0xfdd2f;}}['_makeModelFromViewString'](_0x46e684){const _0x3952be=JSON['parse'](_0x46e684),_0x2e3613=this['editor']['editing']['view']['document'],_0x191dc1=new _0x225620(_0x2e3613,_0x3952be['map'](_0x238748=>this['_getViewFromDiffObj'](_0x238748,!0x0)));return this['editor']['data']['toModel'](_0x191dc1);}['_removeRevisionMarkers'](_0x241a25){return(_0x241a25=_0x241a25['filter'](_0x52eaa8=>!_0x52eaa8['name']||'revision-start'!==_0x52eaa8['name']&&'revision-end'!==_0x52eaa8['name']))['forEach'](_0x45e2b6=>{'string'!=typeof _0x45e2b6&&(_0x45e2b6['children']=this['_removeRevisionMarkers'](_0x45e2b6['children']),_0x45e2b6['attributes']=_0x45e2b6['attributes']['filter'](_0x554c54=>!_0x554c54[0x0]['startsWith']('data-revision-')));}),_0x241a25;}}function R(_0x4ce975,_0x19f690,_0x439b52){const t=_0x4ce975['t'];switch(_0x19f690){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'},_0x439b52);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x439b52);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 _0x1eb7a5{['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[_0x1bea53,S,$,_0x230593];}constructor(_0x555a96){super(_0x555a96),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 _0x391ce4=_0xe8fa3b();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x391ce4},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 _0x4db80c=this['repository']['getRevision'](0x0),_0x441940=_0x4db80c&&null===_0x4db80c['creator']?_0x4db80c:null;if(this['_continueCurrentRevision']=!!_0x441940&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x4b00f0=this['_source']['getCurrentRevisionId'](),_0x358742=this['repository']['getRevision'](_0x4b00f0);if(_0x358742)this['_startingVersion']=_0x358742['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x47326d=this['_source']['history']['_operations']['find'](_0x4e4d00=>!_0x4e4d00['_isInit']),_0x48c1a2=_0x47326d?_0x47326d['baseVersion']:this['_source']['history']['version'];_0x4db80c?(_0x4db80c['toVersion']<_0x48c1a2&&_0x4db80c['_update']({'toVersion':_0x48c1a2}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x441940['id'],this['_startingVersion']=_0x441940['fromVersion']):(this['_startingVersion']=_0x4db80c['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x48c1a2,this['_continueCurrentRevision']=!0x1);}}else _0x441940&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x441940['toVersion'],this['editor']['model']['document']['history']['version']),_0x441940['fromVersion']===_0x441940['toVersion']?(0x0!==_0x441940['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x441940['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x441940['id'],this['_startingVersion']=_0x441940['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',_0x47b76e=>!_0x47b76e),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x2d767d=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x3903ce;for(const _0x113791 in _0x2d767d){const _0x251d8c=_0x113791,_0x5d8b42=_0x2d767d[_0x251d8c];if('revisionHistoryLicenseKeyValid'==_0x5d8b42||'revisionHistoryLicenseKeyInvalid'==_0x5d8b42||'revisionHistoryLicenseKeyExpired'==_0x5d8b42||'revisionHistoryLicenseKeyDomainLimit'==_0x5d8b42||'revisionHistoryLicenseKeyNotAllowed'==_0x5d8b42||'revisionHistoryLicenseKeyEvaluationLimit'==_0x5d8b42||'revisionHistoryLicenseKeyTrialLimit'==_0x5d8b42||'revisionHistoryLicenseKeyUsageLimit'==_0x5d8b42){delete _0x2d767d[_0x251d8c],_0x3903ce=_0x5d8b42,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x3903ce&&_0x2d767d['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x3903ce&&_0x2d767d['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x3903ce&&_0x2d767d['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x3903ce&&_0x2d767d['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x3903ce&&_0x2d767d['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x3903ce&&_0x2d767d['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x3903ce&&_0x2d767d['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x5134a2=this['repository']['getRevision'](0x0),_0x303890=await this['getRevisionDocumentData'](_0x5134a2),_0x5dd446=await this['getRevisionRootsAttributes'](_0x5134a2);this['_replaceEditorDataWithRevisionData'](_0x303890,_0x5dd446);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x3be9ac){this['_source']=_0x3be9ac;}async['update'](){const _0x48528c=await this['_source']['getLatestVersion']();if(_0x48528c>this['currentRevision']['toVersion']){await this['_loadState']();const _0x2d6aea=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x48528c});_0x2d6aea['authors']=_0x2d6aea['authorsIds']['map'](_0x54371f=>this['editor']['plugins']['get']('Users')['getUser'](_0x54371f)),this['currentRevision']['_update'](_0x2d6aea);}}async['saveRevision'](_0x25f3aa={},_0x411de2=null){const _0x39e718=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x411de2>this['currentRevision']['toVersion']&&(_0x411de2=null),null===_0x411de2&&(_0x411de2=await this['_source']['getLatestVersion']());const _0x12b987=this['_getFromVersion'](_0x411de2),_0x2764c9=this['buildRevisionData']({'from':_0x12b987,'to':_0x411de2});if(this['currentRevision']['toVersion']<_0x411de2){const _0x19dd0e=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x411de2,'to':_0x411de2});_0x19dd0e['authors']=[],_0x19dd0e['authorsIds']=[],_0x19dd0e['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x19dd0e,!0x0),delete _0x19dd0e['authors'],_0x39e718['push'](_0x19dd0e);}_0x25f3aa['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x25f3aa['name']=_0x25f3aa['name']||null,_0x25f3aa['id']=_0x25f3aa['id']||_0xe8fa3b(),_0x25f3aa={..._0x25f3aa,..._0x2764c9};const _0x109e64=this['addRevisionData'](_0x25f3aa);_0x39e718['push'](_0x25f3aa);const _0x4ca61b=this['repository']['getIndex'](_0x109e64);if(0x0!==_0x4ca61b){const _0x301ced=this['repository']['getRevision'](_0x4ca61b-0x1);if(_0x301ced['fromVersion']!==_0x411de2){const _0x5c7ecf=this['_revisionDataBuilder']['getData'](_0x411de2,_0x301ced['toVersion']),_0xf3ae2e={'id':_0x301ced['id'],'diffData':_0x5c7ecf['diffData'],'authorsIds':_0x5c7ecf['authorsIds'],'authors':_0x5c7ecf['authorsIds']['map'](_0x394225=>this['editor']['plugins']['get']('Users')['getUser'](_0x394225)),'fromVersion':_0x411de2};_0x301ced===this['currentRevision']&&(_0xf3ae2e['createdAt']=new Date(_0x25f3aa['createdAt']['getTime']()+0xa)),_0x301ced['_update'](_0xf3ae2e,!0x0),delete _0xf3ae2e['authors'],_0x39e718['push'](_0xf3ae2e);}}if(this['adapter']){for(const _0x1dd804 of _0x39e718)this['_bufferUpdate'](_0x1dd804['id'],_0x1dd804,!0x0);this['sendBufferedUpdates']();}return _0x109e64;}['addRevisionData'](_0x12ec55){const _0x2d0e27=this['repository']['createRevision'](_0x12ec55);return this['adapter']&&_0x2d0e27['on']('_update',(_0x2067b2,_0x2f1633,_0x4378c8)=>{_0x4378c8||(this['_bufferUpdate'](_0x2f1633['id'],_0x2f1633,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x2d0e27,this['_findInsertionIndex'](_0x2d0e27)),_0x2d0e27;}async['getRevisionDocumentData'](_0x276f3f){return await this['_utils']['loadRevisionData'](_0x276f3f,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x276f3f);}async['getRevisionRootsAttributes'](_0x1471fe){return await this['_utils']['loadRevisionData'](_0x1471fe,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x1471fe);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x51b1dc=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x5be770=0x0;_0x5be770<_0x51b1dc['length'];_0x5be770++){const _0x5c6ab0=_0x51b1dc[_0x5be770];let _0x29e521=!0x1;for(const _0x1dc843 of Object['keys'](_0x5c6ab0))void 0x0===_0x5c6ab0[_0x1dc843]?delete _0x5c6ab0[_0x1dc843]:'id'!==_0x1dc843&&(_0x29e521=!0x0);_0x29e521||(_0x51b1dc[_0x5be770]=null);}if(_0x51b1dc=_0x51b1dc['filter'](_0x2d9bd3=>null!==_0x2d9bd3),!_0x51b1dc['length'])return;for(let _0x2ce165=0x0;_0x2ce165<_0x51b1dc['length'];_0x2ce165++){const _0x5e58bb=_0x51b1dc[_0x2ce165];void 0x0!==_0x5e58bb['fromVersion']&&void 0x0===_0x5e58bb['toVersion']&&(_0x5e58bb['toVersion']=this['repository']['getRevision'](_0x5e58bb['id'])['toVersion']),void 0x0!==_0x5e58bb['toVersion']&&void 0x0===_0x5e58bb['fromVersion']&&(_0x5e58bb['fromVersion']=this['repository']['getRevision'](_0x5e58bb['id'])['fromVersion']);}const _0x1e67f4=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x51b1dc,_0x1e67f4)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x3c0eff=>{if(_0x3c0eff){for(const _0x3fe004 of _0x3c0eff)this['setRevisionData']({'id':_0x3fe004['id'],'createdAt':_0x3fe004['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0x523c04=null,from:_0x2a1833=null,to:_0x1d1d1e=null}){_0x2a1833=null!==_0x2a1833?_0x2a1833:_0x523c04['fromVersion'],_0x1d1d1e=null!==_0x1d1d1e?_0x1d1d1e:_0x523c04['toVersion'];const _0x36f130=this['_revisionDataBuilder']['getData'](_0x2a1833,_0x1d1d1e),_0x2c64fa={'diffData':_0x36f130['diffData'],'authorsIds':_0x36f130['authorsIds'],'fromVersion':_0x2a1833,'toVersion':_0x1d1d1e};if(!_0x523c04||_0x1d1d1e!==_0x523c04['toVersion']){const _0x2881cb=_0x1d1d1e-0x1,_0x2cfd17=this['_source']['history']['getOperation'](_0x2881cb);_0x2c64fa['createdAt']=_0x2cfd17&&_0x2cfd17['createdAt']||new Date();}if(this['_loadedStateData']&&_0x2a1833===this['_loadedStateData']['fromVersion']){for(const _0x469ecf of this['_loadedStateData']['authors'])_0x2c64fa['authorsIds']['includes'](_0x469ecf['id'])||_0x2c64fa['authorsIds']['push'](_0x469ecf['id']);}return _0x2c64fa;}['_bufferUpdate'](_0xec0a19,_0x1b881b,_0x5f4ba4){if(this['_bufferedUpdates']['has'](_0xec0a19)){const _0x4e32ac=this['_bufferedUpdates']['get'](_0xec0a19);_0x1b881b=_0x5f4ba4?{..._0x4e32ac,..._0x1b881b}:{..._0x1b881b,..._0x4e32ac};}this['_bufferedUpdates']['set'](_0xec0a19,_0x1b881b);}['setRevisionData'](_0xee1fb1){const _0x4b81ad=this['repository']['getRevision'](_0xee1fb1['id']);if(_0xee1fb1['createdAt']&&(_0xee1fb1['createdAt']=new Date(_0xee1fb1['createdAt'])),_0xee1fb1['authorsIds']){const _0x3b3fb3=this['editor']['plugins']['get']('Users');_0xee1fb1['authors']=_0xee1fb1['authorsIds']['map'](_0x435b6a=>_0x3b3fb3['getUser'](_0x435b6a));}_0x4b81ad['_update'](_0xee1fb1,!0x0);}['_createInitialRevision'](_0x100676){const _0x21d64e=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x21d64e)this['_initialRevisionId']=_0x21d64e['id'];else{const _0xcd3c3b=!this['editor']['model']['document']['roots']['find'](_0x11edf3=>this['editor']['model']['hasContent'](_0x11edf3)),_0x2a79a4=this['editor']['plugins']['get']('Users')['me']['id'],_0x4682a3=R(this['editor']['locale'],_0xcd3c3b?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x100676,'to':_0x100676,'id':this['_initialRevisionId'],'name':_0x4682a3,'creatorId':_0x2a79a4});}}['_createCurrentRevision'](_0x4432b2){const _0x2dcf66=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x2dcf66),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x4432b2,'to':_0x4432b2,'id':_0x2dcf66,'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'](_0x19b734,_0x5020f1){let _0x5f440a=this['editor']['config']['get']('initialData'),_0x54e689=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x5f440a){_0x5f440a={};for(const _0x10d541 of this['editor']['model']['document']['getRootNames']())_0x5f440a[_0x10d541]='';}if('string'==typeof _0x5f440a&&(_0x5f440a={'main':_0x5f440a}),void 0x0===_0x54e689){_0x54e689={};for(const _0x595070 of this['editor']['model']['document']['getRootNames']())_0x54e689[_0x595070]={};}let _0x49360d=!0x1;const _0x538afe=Object['keys'](_0x5f440a),_0x5413fa=Object['keys'](_0x19b734);for(const _0x3641d2 of _0x538afe){if(_0x5f440a[_0x3641d2]!==_0x19b734[_0x3641d2]&&''!==_0x5f440a[_0x3641d2]['trim']()){_0x49360d=!0x0;break;}if(!_0x297bd1(_0x54e689[_0x3641d2],_0x5020f1[_0x3641d2])&&Object['keys'](_0x54e689[_0x3641d2])['length']>0x0){_0x49360d=!0x0;break;}}_0x49360d||(_0x49360d=_0x5413fa['some'](_0x49c8b7=>!this['editor']['model']['document']['getRoot'](_0x49c8b7))),_0x49360d&&_0x262eb6('editor-initial-data-replaced-with-revision-data',{'editorData':_0x5f440a,'editorRootsAttributes':_0x54e689,'revisionData':_0x19b734,'revisionRootsAttributes':_0x5020f1}),this['editor']['config']['set']('initialData',_0x19b734),this['editor']['config']['set']('rootsAttributes',_0x5020f1);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x2deb46=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x2deb46['add'](R(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x455db9){const _0x4afcea=this['repository']['getRevisions']();_0x4afcea['reverse']();let _0x51eb5e=0x0;for(;_0x51eb5e<_0x4afcea['length'];){const _0xb36f6b=_0x4afcea[_0x51eb5e];if(_0xb36f6b===this['currentRevision']){_0x51eb5e++;continue;}if(_0xb36f6b['id']===this['_initialRevisionId'])break;const _0x5cf1c2=_0x455db9['toVersion']-_0xb36f6b['toVersion']||_0x455db9['fromVersion']-_0xb36f6b['fromVersion'];if(_0x5cf1c2>0x0)break;if(_0x5cf1c2<0x0)_0x51eb5e++;else{if(!_0x455db9['creator']&&_0xb36f6b['creator'])break;if(_0xb36f6b['creator']||!_0x455db9['creator']){if(_0x455db9['createdAt']>_0xb36f6b['createdAt'])break;_0x51eb5e++;}else _0x51eb5e++;}}return _0x51eb5e;}['_getFromVersion'](_0x1349f4){const _0x495d03=this['repository']['getRevisions']();_0x495d03['reverse'](),_0x495d03['shift']();const _0x411b79=_0x495d03['find'](_0x455a42=>_0x455a42['toVersion']<=_0x1349f4)['toVersion'];return _0x411b79<this['_startingVersion']?this['_startingVersion']:_0x411b79;}['_makeRevision']({name:_0x3bfb6b,from:_0x345931,to:_0x19bfb9,creatorId:_0x51fd87,id:_0x34ba3d}){const _0x1f4ab0=this['buildRevisionData']({'from':_0x345931,'to':_0x19bfb9});_0x1f4ab0['name']=_0x3bfb6b,_0x1f4ab0['creatorId']=_0x51fd87,_0x1f4ab0['id']=_0x34ba3d;const _0x3888ef=this['addRevisionData'](_0x1f4ab0);return this['adapter']&&this['_bufferUpdate'](_0x1f4ab0['id'],_0x1f4ab0,!0x0),_0x3888ef;}['_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(_0x4dc704){this['editor']=_0x4dc704,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'](_0x2733e0){this['source']=_0x2733e0;const _0x530020=new Map(),_0x59e6bd=new Map(),_0x61f411=this['editor']['model']['document']['roots']['map'](_0x41a239=>_0x41a239['rootName']);for(const _0x49d7b3 of _0x61f411){const _0x44e95a=this['editor']['model']['document']['getRoot'](_0x49d7b3),_0x276a8e=x(_0x44e95a);_0x530020['set'](_0x49d7b3,_0x276a8e),_0x59e6bd['set'](_0x49d7b3,Object['fromEntries'](_0x44e95a['getAttributes']()));}const _0x4245d3=Array['from'](this['editor']['model']['markers'])['map'](_0xdcdd80=>[_0xdcdd80['name'],_0xdcdd80['getRange']()]),_0xc2178=this['source']['version'];this['_saveMetaData'](_0xc2178,_0x530020,_0x4245d3,_0x59e6bd),this['_startingRevisionId']=this['_revisionId'];const _0x225e13=new Map(),_0x3514e0=new Map();for(const _0x394623 of _0x61f411){const _0x1d682c=N(_0x394623);_0x225e13['set'](_0x394623,_0x1d682c),_0x3514e0['set'](_0x394623,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x225e13,[],_0x3514e0);}['getData'](_0x2586b1,_0x4ac65b){if(this['_lastFrom']===_0x2586b1&&this['_lastTo']<=_0x4ac65b)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x4ac65b,!0x0);else{if(!this['_savedMetaData']['has'](_0x2586b1)){const _0xc7abc1=this['_getPreviousFrom'](_0x2586b1);this['_calculateMetaData'](_0xc7abc1,_0x2586b1,!0x1);}this['_calculateMetaData'](_0x2586b1,_0x4ac65b,!0x0);}return this['_lastFrom']=_0x2586b1,this['_lastTo']=_0x4ac65b,this['_getState']();}['loadState'](_0x34bcd5){const _0x26af0e=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x34bcd5['fromVersion'],this['_lastTo']=_0x34bcd5['toVersion'];for(const _0x3fa6bf in _0x34bcd5['diffData']){const _0x59767f=_0x34bcd5['diffData'][_0x3fa6bf]['attachChange'],_0x34f46a=_0x1184a6(_0x34bcd5['diffData'][_0x3fa6bf]['attributesBefore'])||{},_0x21a348=_0x26af0e['_makeModelFromViewString'](_0x34bcd5['diffData'][_0x3fa6bf]['deletions']);_0x21a348['rootName']=_0x3fa6bf,_0x21a348['_isAttached']=!_0x59767f||!_0x59767f['isAttached'],_0x21a348['isAttached']=()=>_0x21a348['_isAttached'],this['_baseRoots']['set'](_0x3fa6bf,_0x21a348),this['_baseRootsAttributes']['set'](_0x3fa6bf,_0x34f46a),_0x59767f&&this['_touchedRoots']['set'](_0x3fa6bf,_0x59767f);const _0x557825=this['_makeIdsRoot'](_0x21a348);this['_baseIdsRoots']['set'](_0x3fa6bf,_0x557825);for(const [_0x38cdd1,_0x1eeb52]of _0x21a348['markers']){if(!_0x38cdd1['startsWith']('revision:'))continue;const _0x55f467=_0x38cdd1['split'](':')[0x2];for(const _0x374c7d of _0x1eeb52['getWalker']({'singleCharacters':!0x0})){const _0x256e24=this['_getVidAttributeName'](_0x374c7d),_0x4ff4ba='elementEnd'==_0x374c7d['type']?_0x374c7d['previousPosition']['path']['slice'](0x0,-0x1):_0x374c7d['previousPosition']['path'],_0x4633e8=_0x557825['getNodeByPath'](_0x4ff4ba)['getAttribute'](_0x256e24);this['_touched']['set'](_0x4633e8,{'userId':_0x55f467});}}}this['_startingRevisionId']=this['_revisionId'];const _0x3a56de=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x37b9ea=>!this['_touched']['has'](_0x37b9ea));let _0x244d14=0x0;const _0x334553=new Map();for(const _0x4ce654 in _0x34bcd5['diffData']){const _0x5346ab=_0x34bcd5['diffData'][_0x4ce654]['attachChange'],_0x51c970=_0x1184a6(_0x34bcd5['diffData'][_0x4ce654]['attributesAfter'])||{},_0xd282a5=_0x26af0e['_makeModelFromViewString'](_0x34bcd5['diffData'][_0x4ce654]['insertions']);_0xd282a5['rootName']=_0x4ce654,_0xd282a5['_isAttached']=!_0x5346ab||_0x5346ab['isAttached'],_0xd282a5['isAttached']=()=>_0xd282a5['_isAttached'],this['_diffRoots']['set'](_0x4ce654,_0xd282a5),this['_diffRootsAttributes']['set'](_0x4ce654,_0x51c970);const _0x3dc417=this['_makeIdsRoot'](_0xd282a5,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x4ce654,_0x3dc417),_0x334553['set'](_0x4ce654,_0xd282a5['isAttached']()?_0x51c970:{});for(const [_0x3aad18,_0x2c54e1]of _0xd282a5['markers']){if(!_0x3aad18['startsWith']('revision:'))continue;const _0x2948c2=_0x3aad18['split'](':')[0x2];for(const _0x2b07ab of _0x2c54e1['getWalker']({'singleCharacters':!0x0})){const _0xcbc1ab=this['_getVidAttributeName'](_0x2b07ab),_0x5b969e=this['_revisionId']++,_0x2dc032='elementEnd'==_0x2b07ab['type']?_0x2b07ab['previousPosition']['path']['slice'](0x0,-0x1):_0x2b07ab['previousPosition']['path'];_0x3dc417['getNodeByPath'](_0x2dc032)['_setAttribute'](_0xcbc1ab,_0x5b969e),this['_touched']['set'](_0x5b969e,{'userId':_0x2948c2});}}for(const _0x19da96 of this['editor']['model']['createRangeIn'](_0xd282a5)['getWalker']({'singleCharacters':!0x0})){const _0x33782b=this['_getVidAttributeName'](_0x19da96),_0x59a4e0='elementEnd'==_0x19da96['type']?_0x19da96['previousPosition']['path']['slice'](0x0,-0x1):_0x19da96['previousPosition']['path'],_0x89586b=_0x3dc417['getNodeByPath'](_0x59a4e0);_0x89586b['getAttribute'](_0x33782b)>0x0||_0x89586b['_setAttribute'](_0x33782b,_0x3a56de[_0x244d14++]);}for(const [_0x456cfb,_0x39f34f]of _0xd282a5['markers'])_0x456cfb['startsWith']('revision:')||this['_markers']['set'](_0x456cfb,_0x39f34f);}const _0x5b611c=N('$graveyard');this['_baseRoots']['set']('$graveyard',_0x5b611c),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x5b611c,0x1));const _0x3d0b4a=N('$graveyard');this['_diffRoots']['set']('$graveyard',_0x3d0b4a),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x3d0b4a,0x1));const _0x2db9d4=Array['from'](this['_diffRoots'])['map'](([_0x281538,_0x361a6d])=>[_0x281538,x(_0x361a6d)]);this['_saveMetaData'](this['_lastTo'],_0x2db9d4,this['_markers'],_0x334553);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0x122f09,_0x35e374,_0x1b9f7f,_0x35141b){const _0x3d68af=new Map(_0x35e374),_0x521928=new Map(_0x1184a6(_0x35141b)),_0x5b1abe=new Map();for(const [_0x3d9c18,_0x48bfd8]of _0x1b9f7f)_0x5b1abe['set'](_0x3d9c18,{'start':_0x48bfd8['start']['clone'](),'end':_0x48bfd8['end']['clone'](),'rootName':_0x48bfd8['root']['rootName']});this['_savedMetaData']['set'](_0x122f09,{'roots':_0x3d68af,'markers':_0x5b1abe,'rootsAttributes':_0x521928});}['_removeMetaData'](_0x2f605c){this['_savedMetaData']['delete'](_0x2f605c);}['_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'](_0xb2645,_0x3c636b=null){let _0x45f5e4=null;_0xb2645['is']('documentFragment')||(_0x45f5e4=new _0x1feb76(_0xb2645['name'],{'vid_start':null===_0x3c636b?this['_revisionId']++:_0x3c636b++}));const _0x34d46e=[];for(const _0x5c7c2 of _0xb2645['getChildren']())if(_0x5c7c2['is']('element')){_0x34d46e['push'](this['_makeIdsRoot'](_0x5c7c2,_0x3c636b));const _0x3883f2=_0x34d46e[_0x34d46e['length']-0x1];null!==_0x3c636b&&(_0x3c636b=_0x3883f2['is']('element','$text')?_0x3883f2['getAttribute']('vid')+0x1:_0x3883f2['getAttribute']('vid_end')+0x1);}else{for(let _0x536cb9=0x0;_0x536cb9<_0x5c7c2['offsetSize'];_0x536cb9++)_0x34d46e['push'](new _0x1feb76('$text',{'vid':null===_0x3c636b?this['_revisionId']++:_0x3c636b++}));}if(_0xb2645['is']('documentFragment')){const _0x39e63d=N(_0xb2645['rootName']);return _0x39e63d['_insertChild'](0x0,_0x34d46e),_0x39e63d;}return _0x45f5e4['_setAttribute']('vid_end',null===_0x3c636b?this['_revisionId']++:_0x3c636b++),_0x45f5e4['_insertChild'](0x0,_0x34d46e),_0x45f5e4;}['_calculateMetaData'](_0x48c2c6,_0x15051c,_0x227b90){this['_reset']();const {roots:_0x3da0d5,markers:_0x183736,rootsAttributes:_0x12cb82}=this['_savedMetaData']['get'](_0x48c2c6);this['_baseRoots']=new Map(_0x3da0d5),this['_baseRootsAttributes']=new Map(_0x1184a6(_0x12cb82));for(const [_0x41cb00,_0x3888bd]of this['_baseRoots'])if('$graveyard'!==_0x41cb00&&(this['_diffRoots']['set'](_0x41cb00,x(_0x3888bd)),this['_diffRootsAttributes']=new Map(_0x1184a6(_0x12cb82)),_0x227b90)){const _0x584255=this['_revisionId'];this['_idsRoots']['set'](_0x41cb00,this['_makeIdsRoot'](_0x3888bd)),this['_baseIdsRoots']['set'](_0x41cb00,this['_makeIdsRoot'](_0x3888bd,_0x584255));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',x(this['_baseRoots']['get']('$graveyard'))),_0x227b90&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x8d22e3,_0x57ad4c]of _0x183736){const _0x1b7bb6=this['_baseRoots']['get'](_0x57ad4c['rootName']),_0x327133=this['_diffRoots']['get'](_0x57ad4c['rootName']),_0x200830=new _0x1f4939(this['_fixPosition'](_0x57ad4c['start'],_0x1b7bb6),this['_fixPosition'](_0x57ad4c['end'],_0x1b7bb6)),_0x28177c=this['_fixRange'](_0x200830,_0x327133);_0x1b7bb6['markers']['set'](_0x8d22e3,_0x200830),this['_markers']['set'](_0x8d22e3,_0x28177c);}this['_applyOperations'](_0x48c2c6,_0x15051c,_0x227b90);}['_applyOperations'](_0x26b306,_0x92b58a,_0x209617){for(const _0xea22e7 of this['source']['getOperations'](_0x26b306,_0x92b58a))this['_handleOperation'](_0xea22e7,_0x209617);for(const _0x18cd45 of this['_diffRoots']['values']())_0x18cd45['markers']['clear']();for(const [_0x2cf836,_0xfd4662]of this['_markers']){this['_diffRoots']['get'](_0xfd4662['root']['rootName'])['markers']['set'](_0x2cf836,_0xfd4662['clone']());}const _0x45b497=new Map(),_0x4a594a=new Map();for(const [_0x2d2d16,_0x1c4b88]of this['_diffRoots'])_0x45b497['set'](_0x2d2d16,x(_0x1c4b88)),_0x4a594a['set'](_0x2d2d16,this['_diffRootsAttributes']['get'](_0x2d2d16));this['_saveMetaData'](_0x92b58a,_0x45b497,this['_markers'],_0x4a594a);}['_getPreviousFrom'](_0x1a01da){const _0xc6fa2e=Array['from'](this['_savedMetaData']['keys']());_0xc6fa2e['sort']((_0x59a635,_0x2a4973)=>_0x59a635-_0x2a4973),_0xc6fa2e['reverse']();for(const _0x90aa30 of _0xc6fa2e)if(_0x90aa30<_0x1a01da)return _0x90aa30;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x4b5888,_0x4cfd00){const _0x5365a9=Array['from'](_0x4cfd00['markers'])['map'](([_0x1a27a0,_0x18143c])=>[_0x1a27a0,this['_fixRange'](_0x18143c,_0x4b5888)]);_0x4b5888['markers']=new Map(_0x5365a9);}['_transformMarkers'](_0x4f3e8e){for(const _0x3fe2e7 of this['_markers']['values']()){const _0x4b6471=_0x3fe2e7['getTransformedByOperation'](_0x4f3e8e),_0x2c76bb=_0x1f4939['_createFromRanges'](_0x4b6471);_0x3fe2e7['start']=_0x2c76bb['start'],_0x3fe2e7['end']=_0x2c76bb['end'];}}['_handleOperation'](_0x5d9c55,_0xbc0bcf){if('addRoot'!=_0x5d9c55['type']&&'detachRoot'!=_0x5d9c55['type']){if('insert'==_0x5d9c55['type']){const _0x463b7a=_0x5d9c55['position']['root']['rootName'];this['_diffRoots']['has'](_0x463b7a)||(this['_diffRoots']['set'](_0x463b7a,N(_0x463b7a,!0x0)),this['_diffRootsAttributes']['set'](_0x463b7a,{}),_0xbc0bcf&&this['_idsRoots']['set'](_0x463b7a,N(_0x463b7a,!0x0)));}else{if('addRootAttribute'==_0x5d9c55['type']||'removeRootAttribute'==_0x5d9c55['type']||'changeRootAttribute'==_0x5d9c55['type'])return void this['_handleRootAttributeOperation'](_0x5d9c55);'marker'==_0x5d9c55['type']&&this['_handleMarkerOperation'](_0x5d9c55);}if('marker'!==_0x5d9c55['type']){const _0x58d67c=this['_cloneOperation'](_0x5d9c55,this['_diffRoots']);_0x58d67c['_execute'](),this['_transformMarkers'](_0x58d67c);}if(_0xbc0bcf)switch(_0x5d9c55['type']){case'insert':this['_handleInsertOperation'](_0x5d9c55);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x5d9c55);break;case'merge':this['_handleMergeOperation'](_0x5d9c55);break;case'split':this['_handleSplitOperation'](_0x5d9c55);}}else this['_handleRootOperation'](_0x5d9c55,_0xbc0bcf);}['_cloneOperation'](_0x2f079d,_0x34a6d0){const _0x3d316b=_0x2f079d['clone']();return _0x3d316b['_authorId']=_0x2f079d['_authorId'],this['_fixOperation'](_0x3d316b,_0x34a6d0),_0x3d316b;}['_getBaseVids'](_0x45399a){return _0x45399a['map'](_0x3a7a35=>{const _0x2c64d8=this['_getVidAttributeName'](_0x3a7a35);return Number(_0x3a7a35['item']['getAttribute'](_0x2c64d8));});}['_generateTape'](_0x2ba724,_0x5b59ca){if(_0x2ba724['is']('element','$text'))_0x5b59ca['push']({'item':_0x2ba724,'type':'text'});else{_0x2ba724['is']('element')&&_0x5b59ca['push']({'item':_0x2ba724,'type':'elementStart'});for(const _0x251379 of _0x2ba724['getChildren']())this['_generateTape'](_0x251379,_0x5b59ca);_0x2ba724['is']('element')&&_0x5b59ca['push']({'item':_0x2ba724,'type':'elementEnd'});}return _0x5b59ca;}['_getState'](){const _0x183932=new Map(this['_touched']),_0x45cdfa=new Map(_0x183932),_0x25415e=new Map(),_0x5c069d={'insertions':{},'deletions':{}},_0x1c80e0={'insertions':{},'deletions':{}},_0x53fc8f=new Map(),_0x435ab4=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x435ab4['delete']('$graveyard');for(const _0x276532 of _0x435ab4){const _0x2184e6=this['_diffRoots']['get'](_0x276532)||N(_0x276532,!0x1),_0x5c7f61=this['_baseRoots']['get'](_0x276532)||N(_0x276532,!0x1);_0x2184e6['isAttached']()||_0x5c7f61['isAttached']()?(_0x5c069d['insertions'][_0x276532]=x(_0x2184e6),_0x5c069d['deletions'][_0x276532]=x(_0x5c7f61),this['_copyMarkers'](_0x5c069d['deletions'][_0x276532],_0x5c7f61),this['_copyMarkers'](_0x5c069d['insertions'][_0x276532],_0x2184e6),_0x1c80e0['insertions'][_0x276532]=this['_generateTape'](this['_idsRoots']['get'](_0x276532),[]),_0x1c80e0['deletions'][_0x276532]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x276532)||N(_0x276532,!0x1),[])):_0x435ab4['delete'](_0x276532);}for(const _0x51d9e7 of _0x435ab4){const _0x3741e2=_0x1c80e0['insertions'][_0x51d9e7];for(const _0x5bf447 of _0x3741e2){const _0x29dd16=this['_getVidAttributeName'](_0x5bf447),_0x490724=_0x5bf447['item']['getAttribute'](_0x29dd16);_0x45cdfa['delete'](_0x490724),_0x490724>=this['_startingRevisionId']&&_0x25415e['set'](_0x490724,_0x183932['get'](_0x490724));}}for(const _0x162267 of _0x435ab4){const _0x481cf3=_0x1c80e0['insertions'][_0x162267],_0x5dcc06=this['_getBaseVids'](_0x1c80e0['deletions'][_0x162267]);let _0x3a1273=0x0;for(const _0x566edc of _0x481cf3){const _0xed2619=this['_getVidAttributeName'](_0x566edc),_0x1ad233=_0x566edc['item']['getAttribute'](_0xed2619);if(!_0x25415e['has'](_0x1ad233)&&!_0x53fc8f['has'](_0x1ad233)){if(_0x45cdfa['has'](_0x1ad233))_0x3a1273++;else{if(_0x1ad233!=_0x5dcc06[_0x3a1273]){const _0x19afa9=_0x183932['get'](_0x1ad233)||_0x183932['get'](_0x5dcc06[_0x3a1273]);for(;_0x1ad233!=_0x5dcc06[_0x3a1273];)_0x45cdfa['has'](_0x5dcc06[_0x3a1273])||(_0x53fc8f['set'](_0x5dcc06[_0x3a1273],_0x19afa9),_0x183932['set'](_0x5dcc06[_0x3a1273],_0x19afa9)),_0x3a1273++;}_0x3a1273++;}}}}for(const _0x4e31c4 of _0x435ab4){const _0x3ad607=_0x1c80e0['insertions'][_0x4e31c4];for(const _0x3ffea1 of _0x3ad607){const _0x331a8f=this['_getVidAttributeName'](_0x3ffea1),_0xdca8e9=_0x3ffea1['item']['getAttribute'](_0x331a8f);if(_0x53fc8f['has'](_0xdca8e9)){const _0x2d1c69=_0x53fc8f['get'](_0xdca8e9);_0x45cdfa['has'](_0xdca8e9)||_0x45cdfa['set'](_0xdca8e9,{..._0x2d1c69}),_0x25415e['set'](_0xdca8e9,{..._0x2d1c69});}}}for(const _0xeb9db5 of _0x45cdfa['keys']())_0xeb9db5>=this['_startingRevisionId']&&_0x45cdfa['delete'](_0xeb9db5);const _0x2de2de=new Map();for(const _0x3f2f6a of _0x435ab4){let _0x2a77cc=_0x1c80e0['insertions'][_0x3f2f6a];for(const _0x2b6ff3 of _0x2a77cc)if(_0x2b6ff3['item']['is']('element','tableCell')){const _0x51bbdc=this['_getVidAttributeName'](_0x2b6ff3),_0xbd6a12=_0x2b6ff3['item']['getAttribute'](_0x51bbdc);if(_0x25415e['has'](_0xbd6a12)){const _0x2fd2aa=_0x2b6ff3['item']['parent']['parent']['getAttribute']('vid_start'),_0x35dd96=_0x2de2de['get'](_0x2fd2aa)||new Set();_0x35dd96['add'](_0x25415e['get'](_0xbd6a12)['userId']),_0x2de2de['set'](_0x2fd2aa,_0x35dd96);}}_0x2a77cc=_0x1c80e0['deletions'][_0x3f2f6a];for(const _0x255fd7 of _0x2a77cc)if(_0x255fd7['item']['is']('element','tableCell')){const _0x13e54e=this['_getVidAttributeName'](_0x255fd7),_0x52c4a2=_0x255fd7['item']['getAttribute'](_0x13e54e);if(_0x45cdfa['has'](_0x52c4a2)){const _0x437c2e=_0x255fd7['item']['parent']['parent']['getAttribute']('vid_start'),_0x177f23=_0x2de2de['get'](_0x437c2e)||new Set();_0x177f23['add'](_0x45cdfa['get'](_0x52c4a2)['userId']),_0x2de2de['set'](_0x437c2e,_0x177f23);}}for(const _0x40d96e of _0x2de2de['keys']())(_0x25415e['has'](_0x40d96e)||_0x45cdfa['has'](_0x40d96e))&&_0x2de2de['delete'](_0x40d96e);}for(const _0x24678d of _0x435ab4){const _0x57b06e=_0x1c80e0['insertions'][_0x24678d];let _0x4d78f8=null,_0x3fe386=null;for(const _0x4112dc of _0x57b06e){const _0x5ee5bf=this['_getVidAttributeName'](_0x4112dc),_0x2b5605=_0x4112dc['item']['getAttribute'](_0x5ee5bf),_0x1d16d2=_0x2de2de['get'](_0x2b5605);_0x1d16d2&&'elementStart'==_0x4112dc['type']&&(_0x4d78f8=Array['from'](_0x1d16d2)[0x0],_0x3fe386=_0x4112dc['item']['getAttribute']('vid_end')),_0x4d78f8&&(_0x45cdfa['set'](_0x2b5605,{'userId':_0x4d78f8}),_0x25415e['set'](_0x2b5605,{'userId':_0x4d78f8})),_0x2b5605==_0x3fe386&&(_0x4d78f8=null,_0x3fe386=null);}}const _0x35ab25={},_0x146da5=new Set();for(const _0x47d74b of _0x435ab4){const _0xac7d43=_0x5c069d['deletions'][_0x47d74b],_0x477fc1=_0x5c069d['insertions'][_0x47d74b];for(const {userId:_0x219111}of this['_touchedMarkers']['values']())null!==_0x219111&&_0x146da5['add'](_0x219111);for(const {userId:_0x463bf7}of this['_touchedRoots']['values']())null!==_0x463bf7&&_0x146da5['add'](_0x463bf7);this['_markChanges'](_0x477fc1,_0x1c80e0['insertions'][_0x47d74b],_0x25415e,'insertion',_0x146da5),this['_markChanges'](_0xac7d43,_0x1c80e0['deletions'][_0x47d74b],_0x45cdfa,'deletion',_0x146da5),_0x35ab25[_0x47d74b]={'insertions':this['_prepareViewToSave'](_0x477fc1),'deletions':this['_prepareViewToSave'](_0xac7d43),'attachChange':this['_touchedRoots']['get'](_0x47d74b)||null,'attributesBefore':_0x1184a6(this['_baseRootsAttributes']['get'](_0x47d74b))||{},'attributesAfter':_0x1184a6(this['_diffRootsAttributes']['get'](_0x47d74b))};}return{'diffData':_0x35ab25,'authorsIds':Array['from'](_0x146da5)};}['_processRootBeforeSave'](_0x450a23){for(const [,_0x3fec10]of _0x450a23['markers']){const _0x219f1c=_0x3fec10['start']['getAncestors']()['filter'](_0x28061a=>'tableCell'==_0x28061a['name']);for(const _0x41ff42 of _0x219f1c)0x1==_0x41ff42['childCount']&&_0x41ff42['getChild'](0x0)['is']('element','paragraph')&&_0x41ff42['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x410926){this['_processRootBeforeSave'](_0x410926);const _0x1ed9a1=this['editor']['data']['toView'](_0x410926,{}),_0x2aa49d=Array['from'](_0x1ed9a1['getChildren']())['map'](_0x4e1a00=>this['_getViewJson'](_0x4e1a00));return JSON['stringify'](_0x2aa49d);}['_getViewJson'](_0x54d4e5){if(_0x54d4e5['is']('$text'))return _0x54d4e5['data'];{const _0xbcb0dc=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0x3ba74d=_0x54d4e5,_0x24632b=this['editor']['data']['htmlProcessor']['domConverter'],_0x58a243={'type':_0xbcb0dc['_getTypeCharForViewElement'](_0x3ba74d),'name':_0x3ba74d['name'],'attributes':Array['from'](_0x3ba74d['getAttributes']()),'children':Array['from'](_0x3ba74d['getChildren']())['map'](_0x78305=>this['_getViewJson'](_0x78305))};if(_0x54d4e5['is']('uiElement')&&'$comment'!=_0x54d4e5['name']){const _0x2769a8=_0x54d4e5['render'](_0x24632b['domDocument'],_0x24632b);_0x58a243['children']['push'](_0x2769a8['outerHTML']);}else{if(_0x54d4e5['is']('rawElement')){const _0x26bf3b=_0x24632b['domDocument']['createElement'](_0x3ba74d['name']);_0x54d4e5['render'](_0x26bf3b,_0x24632b),_0x58a243['children']['push'](_0x26bf3b['innerHTML']);}}const _0x5df638=Array['from'](_0x3ba74d['getCustomProperties']());_0x5df638['length']>0x0&&(_0x58a243['customProperties']=_0x5df638);const _0x51eba6=_0x3ba74d['getFillerOffset']();return null!==_0x51eba6&&(_0x58a243['fillerOffset']=_0x51eba6),_0x58a243;}}['_markChanges'](_0x2fc703,_0x50f3ae,_0x5f48e1,_0x49f04a,_0x33e9b9){let _0x1662d0=null,_0x12c0fe=null,_0x7fb7d4=0x0;const _0x5ddf25=this['editor']['model'];for(let _0x3bbc48=0x0;_0x3bbc48<_0x50f3ae['length'];_0x3bbc48++){const _0x999ff0=this['_getVidAttributeName'](_0x50f3ae[_0x3bbc48]),_0xc6356f=_0x50f3ae[_0x3bbc48]['item']['getAttribute'](_0x999ff0),_0x2b7ec8=_0x5f48e1['get'](_0xc6356f),_0x21d53d=_0x3bbc48==_0x50f3ae['length']-0x1;(!_0x1662d0&&_0x2b7ec8&&(_0x1662d0=_0x2b7ec8,_0x12c0fe=_0x50f3ae[_0x3bbc48]),_0x1662d0&&(!_0x2b7ec8||_0x2b7ec8['userId']!=_0x1662d0['userId']))&&(_0x7d4c5c(_0x2b7ec8,P(_0x12c0fe,_0x2fc703,_0x5ddf25),P(_0x50f3ae[_0x3bbc48],_0x2fc703,_0x5ddf25)),_0x1662d0=_0x2b7ec8||null,_0x12c0fe=_0x2b7ec8?_0x50f3ae[_0x3bbc48]:null),_0x1662d0&&_0x21d53d&&_0x7d4c5c(_0x2b7ec8,P(_0x12c0fe,_0x2fc703,_0x5ddf25),V(_0x50f3ae[_0x3bbc48],_0x2fc703,_0x5ddf25));}function _0x7d4c5c(_0x311fe2,_0x3ef7a1,_0x48e025){const _0xb92054=_0x1662d0['userId'],_0x2b7979='revision:'+_0x49f04a+':'+_0xb92054+':'+_0x7fb7d4++,_0x10ee9c=_0x5ddf25['createRange'](_0x3ef7a1,_0x48e025);_0x2fc703['markers']['set'](_0x2b7979,_0x10ee9c),null!==_0xb92054&&_0x33e9b9['add'](_0xb92054);}}['_getVidAttributeName'](_0x404082){switch(_0x404082['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x4f489d,_0x41c4f){_0x4f489d['baseVersion']=null;for(const _0x34a2ef in _0x4f489d){const _0x311009=_0x4f489d[_0x34a2ef];if(_0x311009 instanceof _0x4ad552){const _0x20c4ff=_0x41c4f['get'](_0x311009['root']['rootName']);_0x4f489d[_0x34a2ef]=this['_fixPosition'](_0x311009,_0x20c4ff);}if(_0x311009 instanceof _0x1f4939){const _0x2b225b=_0x41c4f['get'](_0x311009['root']['rootName']);_0x4f489d[_0x34a2ef]=this['_fixRange'](_0x311009,_0x2b225b);}'root'===_0x34a2ef&&(_0x4f489d['root']=_0x41c4f['get'](_0x4f489d['root']['rootName']));}}['_fixRange'](_0x37f885,_0x347d43){return this['editor']['model']['createRange'](this['_fixPosition'](_0x37f885['start'],_0x347d43),this['_fixPosition'](_0x37f885['end'],_0x347d43));}['_fixPosition'](_0x336349,_0x3a5722){return this['editor']['model']['createPositionFromPath'](_0x3a5722,_0x336349['path'],_0x336349['stickiness']);}['_handleInsertOperation'](_0x33122d){const _0x19d212=this['_idsRoots']['get'](_0x33122d['position']['root']['rootName']),_0x549a81=this['_fixPosition'](_0x33122d['position'],_0x19d212),_0x1d0e02=null===_0x33122d['_authorId']?null:_0x33122d['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x4e8ec3=_0x549a81['parent'],_0x6459c6=this['_revisionId'],_0x42f855=[];for(const _0x6e3d8a of _0x33122d['nodes'])if(_0x6e3d8a['is']('element'))_0x42f855['push'](this['_makeIdsRoot'](_0x6e3d8a));else{for(let _0x14f7e6=0x0;_0x14f7e6<_0x6e3d8a['offsetSize'];_0x14f7e6++)_0x42f855['push'](new _0x1feb76('$text',{'vid':this['_revisionId']++}));}const _0x49850d=this['_revisionId'];for(let _0x29093d=_0x6459c6;_0x29093d<_0x49850d;_0x29093d++)this['_touched']['set'](_0x29093d,{'userId':_0x1d0e02});_0x4e8ec3['_insertChild'](_0x549a81['offset'],_0x42f855);}['_handleMoveOperation'](_0x34a275){(_0x34a275=this['_cloneOperation'](_0x34a275,this['_idsRoots']))['_execute']();const _0x36d318=null===_0x34a275['_authorId']?null:_0x34a275['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x1c1152=_0x34a275['getMovedRangeStart'](),_0x1dac7e=_0x1c1152['parent'],_0x4a5a87=_0x1c1152['offset'];!function _0x2f68eb(_0x389a84,_0xf100fe,_0x3e189b,_0x5c722){for(let _0x1675ae=_0x3e189b;_0x1675ae<_0x5c722;_0x1675ae++){const _0x31e7cc=_0xf100fe['getChild'](_0x1675ae);_0x31e7cc['is']('element','$text')?_0x389a84['set'](_0x31e7cc['getAttribute']('vid'),{'userId':_0x36d318}):(_0x389a84['set'](_0x31e7cc['getAttribute']('vid_start'),{'userId':_0x36d318}),_0x2f68eb(_0x389a84,_0x31e7cc,0x0,_0x31e7cc['childCount']),_0x389a84['set'](_0x31e7cc['getAttribute']('vid_end'),{'userId':_0x36d318}));}}(this['_touched'],_0x1dac7e,_0x4a5a87,_0x4a5a87+_0x34a275['howMany']);}['_handleMergeOperation'](_0x52b0cf){const _0x20b4eb=null===(_0x52b0cf=this['_cloneOperation'](_0x52b0cf,this['_idsRoots']))['_authorId']?null:_0x52b0cf['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x37b460=_0x52b0cf['targetPosition']['parent'],_0x590b65=_0x52b0cf['sourcePosition']['parent'],_0x138801=_0x37b460['getAttribute']('vid_end'),_0x2cb7e4=_0x590b65['getAttribute']('vid_start');_0x37b460['_setAttribute']('vid_end',_0x590b65['getAttribute']('vid_end')),_0x590b65['_setAttribute']('vid_end',_0x138801),this['_touched']['set'](_0x2cb7e4,{'userId':_0x20b4eb}),this['_touched']['set'](_0x138801,{'userId':_0x20b4eb}),_0x52b0cf['_execute']();}['_handleSplitOperation'](_0x2c6995){const _0x4cc468=null===(_0x2c6995=this['_cloneOperation'](_0x2c6995,this['_idsRoots']))['_authorId']?null:_0x2c6995['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x349dc6=_0x2c6995['graveyardPosition'],_0x1da313=_0x2c6995['splitPosition']['parent'];_0x2c6995['_execute']();const _0x14bf4a=_0x1da313['getAttribute']('vid_end'),_0x32c98e=_0x2c6995['insertionPosition']['nodeAfter'];if(_0x349dc6){const _0x1b6a59=_0x32c98e['getAttribute']('vid_end'),_0x165b30=_0x1da313['getAttribute']('vid_end');_0x1da313['_setAttribute']('vid_end',_0x1b6a59),_0x32c98e['_setAttribute']('vid_end',_0x165b30),this['_touched']['set'](_0x1da313['getAttribute']('vid_end'),{'userId':_0x4cc468}),this['_touched']['set'](_0x32c98e['getAttribute']('vid_start'),{'userId':_0x4cc468});}else{const _0x5d0a6d=this['_revisionId']++,_0x4b2074=this['_revisionId']++;_0x1da313['_setAttribute']('vid_end',_0x5d0a6d),_0x32c98e['_setAttribute']('vid_start',_0x4b2074),_0x32c98e['_setAttribute']('vid_end',_0x14bf4a),this['_touched']['set'](_0x5d0a6d,{'userId':_0x4cc468}),this['_touched']['set'](_0x4b2074,{'userId':_0x4cc468});}}['_handleMarkerOperation'](_0x44b36f){if(!_0x44b36f['affectsData'])return;const _0x7f657a=(_0x44b36f=this['_cloneOperation'](_0x44b36f,this['_diffRoots']))['oldRange']?_0x44b36f['oldRange']['root']:null,_0x57afa4=_0x44b36f['newRange']?_0x44b36f['newRange']['root']:null;_0x7f657a&&this['_markers']['delete'](_0x44b36f['name']),_0x57afa4&&this['_markers']['set'](_0x44b36f['name'],_0x44b36f['newRange']['clone']());const _0x41fdde=null===_0x44b36f['_authorId']?null:_0x44b36f['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x3b3cd4=_0x44b36f['name'];if(!this['_touchedMarkers']['has'](_0x3b3cd4))return void this['_touchedMarkers']['set'](_0x3b3cd4,{'range':_0x44b36f['oldRange'],'userId':_0x41fdde});const _0x1a4c24=this['_touchedMarkers']['get'](_0x3b3cd4),_0x286a20=_0x1a4c24['range'],_0x221803=_0x44b36f['newRange'];null==_0x286a20&&null==_0x221803||_0x286a20&&_0x221803&&_0x286a20['isEqual'](_0x221803)?this['_touchedMarkers']['delete'](_0x44b36f['name']):_0x1a4c24['userId']=_0x41fdde;}['_handleRootOperation'](_0x5e3b20,_0x238fd0){this['_diffRoots']['has'](_0x5e3b20['rootName'])?this['_diffRoots']['get'](_0x5e3b20['rootName'])['_isAttached']=_0x5e3b20['isAdd']:(this['_diffRoots']['set'](_0x5e3b20['rootName'],N(_0x5e3b20['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x5e3b20['rootName'],{}),_0x238fd0&&this['_idsRoots']['set'](_0x5e3b20['rootName'],N(_0x5e3b20['rootName'],!0x0)));const _0x17b839=null===_0x5e3b20['_authorId']?null:_0x5e3b20['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x5831f3=this['_touchedRoots']['get'](_0x5e3b20['rootName']);_0x5831f3&&_0x5831f3['userId']===_0x17b839?this['_touchedRoots']['delete'](_0x5e3b20['rootName']):this['_touchedRoots']['set'](_0x5e3b20['rootName'],{'userId':_0x17b839,'isAttached':_0x5e3b20['isAdd']});}['_handleRootAttributeOperation'](_0x47f7a1){const _0x14e494=this['_diffRootsAttributes']['get'](_0x47f7a1['root']['rootName']);null===_0x47f7a1['newValue']?delete _0x14e494[_0x47f7a1['key']]:_0x14e494[_0x47f7a1['key']]=_0x47f7a1['newValue'];}}function x(_0x3d816f){const _0x56c69d=N(_0x3d816f['rootName'],_0x3d816f['isAttached']());for(const _0x11abc0 of _0x3d816f['getChildren']()){const _0x5b03e4=_0x11abc0['_clone'](!0x0);_0x56c69d['_appendChild'](_0x5b03e4);}return _0x56c69d;}function N(_0x1f8c01,_0x5cf31a=!0x0){const _0x2fee49=new _0x235d32();return _0x2fee49['rootName']=_0x1f8c01,_0x2fee49['_isAttached']=_0x5cf31a,_0x2fee49['isAttached']=()=>_0x2fee49['_isAttached'],_0x2fee49;}function P(_0x51c7fa,_0x322069,_0x255067){const _0x40f0fa='elementEnd'==_0x51c7fa['type']?_0x255067['createPositionAt'](_0x51c7fa['item'],'end'):_0x255067['createPositionBefore'](_0x51c7fa['item']);return _0x255067['createPositionFromPath'](_0x322069,_0x40f0fa['path'],_0x40f0fa['stickiness']);}function V(_0xb58360,_0xfb3b45,_0x3da56c){const _0x6488e6='elementStart'==_0xb58360['type']?_0x3da56c['createPositionAt'](_0xb58360['item'],0x0):_0x3da56c['createPositionAfter'](_0xb58360['item']);return _0x3da56c['createPositionFromPath'](_0xfb3b45,_0x6488e6['path'],_0x6488e6['stickiness']);}class me extends/* #__PURE__ -- @preserve */
|
|
25
|
+
_0x4ba853(_0x3f2314){['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0xead813,_0x225764){super(_0xead813),this['focusTracker']=new _0x1b8ed5(),this['keystrokes']=new _0x586743(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x225764),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'](),_0x40656b({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x357098=_0x320cf8=>_0x320cf8['stopPropagation']();this['keystrokes']['set']('arrowright',_0x357098),this['keystrokes']['set']('arrowleft',_0x357098),this['keystrokes']['set']('arrowup',_0x357098),this['keystrokes']['set']('arrowdown',_0x357098);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x206479){this['revisionNameInputView']['fieldView']['element']['value']=_0x206479['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x4bb8f5){const _0xb1e4ae=new et(this['locale'],ti),_0xc44f8d=_0xb1e4ae['fieldView'];_0xc44f8d['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x584574=R(this['locale'],'Name\x20of\x20the\x20revision');return!_0x4bb8f5&&(_0x584574+='\x20('+R(this['locale'],'optional')+')'),(_0xb1e4ae['label']=_0x584574,_0xc44f8d['on']('input',()=>{this['revisionNameInputValue']=_0xc44f8d['element']['value']['trim']();}),_0xb1e4ae);}}class v extends _0x1eb7a5{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h];}['_saveRevisionFormView'];['init'](){const _0x5a5825=this['editor'],_0x593155=_0x5a5825['plugins']['get']('RevisionTracker');_0x5a5825['ui']['componentFactory']['add']('revisionHistory',_0x5a345b=>{const _0x3e49ef=_0x5be730(_0x5a345b),_0x53f1a9=_0x3e49ef['panelView']['children'],_0x2ae61f=new _0x1b93b8(_0x5a345b),_0x22f115=new _0x516099(_0x5a345b),_0x507eee=new _0x21b928(_0x5a345b),_0x3b2e62=new _0x516099(_0x5a345b),_0x2f70c6=new _0x21b928(_0x5a345b);return _0x3e49ef['bind']('isEnabled')['to'](_0x593155,'isReady',_0x593155,'isEnabled',_0x5a5825,'isReadOnly',(_0x36417d,_0x5d13fa,_0xd03cf)=>_0x36417d&&_0x5d13fa&&!_0xd03cf),_0x3e49ef['buttonView']['set']({'icon':_0x368a30,'label':R(_0x5a345b,'Revision\x20history'),'tooltip':!0x0}),_0x507eee['set']({'label':R(_0x5a345b,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x507eee['bind']('isEnabled')['to'](_0x593155,'isReady',_0x593155,'isEnabled',_0x5a5825,'isReadOnly',(_0x2f4e00,_0x493bcd,_0xe56708)=>_0x2f4e00&&_0x493bcd&&!_0xe56708),_0x507eee['on']('execute',()=>this['_showDialog']()),_0x2f70c6['set']({'label':R(_0x5a345b,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x2f70c6['bind']('isEnabled')['to'](_0x593155,'isReady',_0x5a5825,'isReadOnly',(_0x4660b6,_0x13b221)=>_0x4660b6&&!_0x13b221),_0x2f70c6['on']('execute',()=>{_0x5a5825['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x3e49ef['isOpen']=!0x1,_0x5a5825['editing']['view']['focus']();}),_0x22f115['children']['add'](_0x507eee),_0x3b2e62['children']['add'](_0x2f70c6),_0x2ae61f['role']='menu',_0x2ae61f['items']['addMany']([_0x22f115,_0x3b2e62]),_0x53f1a9['add'](_0x2ae61f),_0x3e49ef;}),_0x5a5825['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x31f9ab=this['editor'],_0x6131b2=_0x31f9ab['locale'],_0x2dd6f5=new _0x4500c0(_0x6131b2),_0x235b0a=new _0x5b6fb8(_0x6131b2);_0x2dd6f5['buttonView']['set']({'icon':_0x368a30,'label':R(_0x6131b2,'Revision\x20history')});const _0x2623c2=new _0x44eb32(_0x6131b2,_0x2dd6f5),_0x571305=new _0x4a7f4d(_0x6131b2);_0x571305['set']({'label':R(_0x6131b2,'Save\x20current\x20revision')}),_0x571305['delegate']('execute')['to'](_0x2dd6f5),_0x571305['on']('execute',()=>{this['_showDialog']();}),_0x2623c2['children']['add'](_0x571305),_0x235b0a['items']['add'](_0x2623c2);const _0x41a807=new _0x44eb32(_0x6131b2,_0x2dd6f5),_0x88caaf=new _0x4a7f4d(_0x6131b2);return _0x88caaf['set']({'label':R(_0x6131b2,'Open\x20revision\x20history')}),_0x88caaf['delegate']('execute')['to'](_0x2dd6f5),_0x88caaf['on']('execute',()=>{_0x31f9ab['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x41a807['children']['add'](_0x88caaf),_0x235b0a['items']['add'](_0x41a807),_0x2dd6f5['panelView']['children']['add'](_0x235b0a),_0x2dd6f5;}['_showDialog'](){const _0x26a043=this['editor'],_0x4ad44c=_0x26a043['locale'],_0x36aba3=_0x26a043['plugins']['get']('Dialog'),_0x2804c2=_0x26a043['plugins']['get']('RevisionTracker');function _0x1f2549(_0x5495f7){_0x26a043['config']['get']('revisionHistory.requireRevisionName')&&''===_0x5495f7['revisionName']?_0x5495f7['revisionNameInputView']['errorText']=R(_0x4ad44c,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x26a043['plugins']['get'](h)['saveRevision']({'name':_0x5495f7['revisionName']}),_0x36aba3['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x1f2549(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x36aba3['show']({'id':'revisionSave','title':R(_0x4ad44c,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':R(_0x26a043['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x36aba3['hide']()},{'label':R(_0x26a043['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x367929){_0x367929['bind']('isEnabled')['to'](_0x2804c2,'isReady',_0x2804c2,'isEnabled',_0x26a043,'isReadOnly',(_0x51c876,_0x3d769f,_0x3e2f3c)=>_0x51c876&&_0x3d769f&&!_0x3e2f3c);},'onExecute':()=>_0x1f2549(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x302465=this['editor'],_0x14eb97=_0x302465['locale'];this['_saveRevisionFormView']=new me(_0x14eb97,_0x302465['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class z extends _0x3f2314{['changeId'];['_model'];constructor(_0x26f26e,_0x40b51a){super(_0x26f26e),this['_model']=_0x40b51a,this['changeId']=_0x40b51a['id'];const _0x758ef4=this['bindTemplate'],_0x25689b=R(_0x26f26e,_0x40b51a['data']['isSuggestion']?'Suggested\x20by':'add'==_0x40b51a['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x40b51a['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x758ef4['to']('type',_0x1e6d4d=>'ck-revision-change__'+_0x1e6d4d)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x25689b}]},{'text':'\x20'+_0x40b51a['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class G extends/* #__PURE__ -- @preserve */
|
|
26
|
+
_0x1b5e58(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x3b08fe){super(),this['id']=_0x3b08fe['id']||_0xe8fa3b(),this['author']=_0x3b08fe['author'],this['type']=_0x3b08fe['type'],this['data']=_0x3b08fe['data']||{},this['rootName']=_0x3b08fe['rootName'],this['set']('createdAt',_0x3b08fe['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(_0x67ae6d,_0x6edd22){this['newRevisionId']=_0x67ae6d,this['oldRevisionId']=_0x6edd22,this['changes']=new _0xb0d30e();}['_setChanges'](_0x391ab4){for(const _0x34ce8c of _0x391ab4)this['changes']['add'](_0x34ce8c);}}class l extends _0x1eb7a5{['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[_0x1bea53,_0x2864ff,S,$];}constructor(_0x593382){super(_0x593382),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',(_0x3d51a7,_0x20068c,_0x2729ce)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x2ed07c=>{for(const _0x48549f of this['editor']['editing']['view']['document']['roots'])_0x2729ce?_0x2ed07c['removeClass']('ck-editor__editable__overlay',_0x48549f):_0x2ed07c['addClass']('ck-editor__editable__overlay',_0x48549f);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x42be5a=>null!==_0x42be5a),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x842ab6,_0xd250d,_0x44973c)=>_0x842ab6&&_0x44973c?_0xd250d['changes']['getIndex'](_0x44973c):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x3781f8,_0x283c44)=>_0x3781f8?_0x283c44['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0x2864ff);}['init'](){const _0x5111b8=this['editor'],_0x532c09=new rt(_0x5111b8,{'direction':'backward'}),_0xc49fd8=new rt(_0x5111b8,{'direction':'forward'});(_0x5111b8['commands']['add']('showPreviousChange',_0x532c09),_0x5111b8['commands']['add']('showNextChange',_0xc49fd8),_0x5111b8['commands']['add']('restoreRevision',new nt(_0x5111b8)),this['on']('change:numberOfChanges',()=>{_0x532c09['refresh'](),_0xc49fd8['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x5111b8['enableReadOnlyMode']('revision-viewer'),_0x5111b8['plugins']['has']('WidgetToolbarRepository'))&&_0x5111b8['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x546c08){return await this['_utils']['loadRevisionData'](_0x546c08,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x546c08);}async['getRevisionRootsAttributes'](_0x58b1d7){return await this['_utils']['loadRevisionData'](_0x58b1d7,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x58b1d7);}async['compare'](_0xcca723,_0x4a2cac,_0x4a7b76=!0x1){if(!this['isEnabled'])return;const _0x52c800=this['diff'],_0x43cabd=this['repository'],_0x30a181='string'==typeof _0xcca723?_0x43cabd['getRevision'](_0xcca723):_0xcca723,_0x463e64='string'==typeof _0x4a2cac?_0x43cabd['getRevision'](_0x4a2cac):_0x4a2cac,_0x3216c5=_0x30a181['id'],_0x3c0717=_0x463e64?_0x463e64['id']:null;if(!_0x4a7b76&&this['diff']&&this['diff']['newRevisionId']===_0x3216c5&&this['diff']['oldRevisionId']===_0x3c0717)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new J(_0x3216c5,_0x3c0717);const _0x11c965=this['_getRevisionsRange'](_0x30a181,_0x463e64,!0x0)['map'](_0x47727e=>this['_utils']['loadRevisionData'](_0x47727e,this['adapter']));return _0x11c965['push'](new Promise(_0x5a494d=>{setTimeout(_0x5a494d,0x14);})),Promise['all'](_0x11c965)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x4f6a79=this['_getDiff'](_0x3216c5,_0x3c0717);for(const _0x13056d of _0x4f6a79['changes'])this['_changeIdToChange']['set'](_0x13056d['id'],_0x13056d);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x3fe328=>{for(const _0x17e650 of this['editor']['model']['document']['getRootNames']())_0x3fe328['detachRoot'](_0x17e650);for(const _0x5efa5f of Object['keys'](_0x4f6a79['model'])){const _0xa3ad53=_0x3fe328['addRoot'](_0x5efa5f);for(const _0x1edead of Object['keys'](_0x4f6a79['attributes'][_0x5efa5f]))_0x3fe328['setAttribute'](_0x1edead,_0x4f6a79['attributes'][_0x5efa5f][_0x1edead],_0xa3ad53);_0x3fe328['insert'](_0x4f6a79['model'][_0x5efa5f],_0xa3ad53,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x4f6a79['changes'])),this['isReady']=!0x0;})['catch'](_0x33b9bf=>{console['error'](_0x33b9bf),this['_cleanUp'](),_0x52c800&&(this['diff']=_0x52c800),this['isReady']=!0x0;});}['addRevisionData'](_0x4d6089,_0xb00160){const _0x4aa5c7=this['repository']['createRevision'](_0x4d6089);return _0x4aa5c7['on']('_update',(_0x5e8c5d,_0x85dcf1,_0x2d6250)=>_0xb00160(_0x85dcf1,_0x2d6250,_0x4aa5c7)),this['repository']['addRevision'](_0x4aa5c7),_0x4aa5c7;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x2bce4e=>{for(const _0x39c7c5 of this['editor']['model']['document']['getRootNames']())_0x2bce4e['detachRoot'](_0x39c7c5);});}['_sortAndFilterDiffChanges'](_0x2d04fb){const _0x19c8c3=[],_0x2fa79a=new Map();for(const _0x15cb3f of this['editor']['model']['document']['getRootNames']()){const _0x5d3d9a=this['editor']['editing']['view']['getDomRoot'](_0x15cb3f);if(!_0x5d3d9a)continue;const _0x101c47=_0x5d3d9a['getClientRects']()['item'](0x0);_0x101c47&&(_0x19c8c3['push'](_0x15cb3f),_0x2fa79a['set'](_0x15cb3f,_0x101c47));}return _0x19c8c3['sort']((_0x76a4f8,_0x34efaf)=>{const _0x5d7f2c=_0x2fa79a['get'](_0x76a4f8),_0x278efe=_0x2fa79a['get'](_0x34efaf);return _0x5d7f2c['y']-_0x278efe['y']||_0x5d7f2c['x']-_0x278efe['x'];}),(_0x2d04fb=_0x2d04fb['filter'](_0x145044=>_0x19c8c3['includes'](_0x145044['rootName'])))['sort']((_0x13acf5,_0x2f8f6f)=>_0x19c8c3['indexOf'](_0x13acf5['rootName'])-_0x19c8c3['indexOf'](_0x2f8f6f['rootName'])),_0x2d04fb;}['_makeTape'](_0x5d0814){const _0x546be8=Array['from'](_0x5d0814['markers'])['filter'](([_0x586248,_0x32a70e])=>_0x586248['startsWith']('revision:')&&!_0x32a70e['isCollapsed']),_0x2efa5b=Array['from'](this['editor']['model']['createRangeIn'](_0x5d0814)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x546be8['length'])for(const _0x2d70d2 of _0x2efa5b){const [_0x191996,_0x2c00b6]=_0x546be8[0x0],[,_0x44fc53,_0x4d715a]=_0x191996['split'](':');if(_0x2c00b6['end']['isEqual'](_0x2d70d2['nextPosition'])&&_0x546be8['shift'](),(_0x2d70d2['previousPosition']['isEqual'](_0x2c00b6['start'])||_0x2d70d2['previousPosition']['isAfter'](_0x2c00b6['start']))&&('insertion'==_0x44fc53?_0x2d70d2['isAdded']={'userId':_0x4d715a}:'deletion'==_0x44fc53&&(_0x2d70d2['isRemoved']={'userId':_0x4d715a})),0x0==_0x546be8['length'])break;}return _0x2efa5b;}['_refreshStartEndIndex'](_0x443955){const _0x381f3d=new Map();for(let _0x3b3b68=0x0;_0x3b3b68<_0x443955['length'];_0x3b3b68++)'text'===_0x443955[_0x3b3b68]['type']?(_0x443955[_0x3b3b68]['item']['startIndex']=_0x3b3b68,_0x443955[_0x3b3b68]['item']['endIndex']=_0x3b3b68):('elementStart'===_0x443955[_0x3b3b68]['type']?_0x443955[_0x3b3b68]['item']['startIndex']=_0x3b3b68:'elementEnd'===_0x443955[_0x3b3b68]['type']&&(_0x443955[_0x3b3b68]['item']['endIndex']=_0x3b3b68),_0x381f3d['set'](_0x443955[_0x3b3b68]['id'],_0x3b3b68));for(const _0x1c419e of _0x381f3d['values']())'elementStart'===_0x443955[_0x1c419e]['type']?_0x443955[_0x1c419e]['item']['endIndex']=_0x381f3d['get'](_0x443955[_0x1c419e]['pairId']):'elementEnd'===_0x443955[_0x1c419e]['type']&&(_0x443955[_0x1c419e]['item']['startIndex']=_0x381f3d['get'](_0x443955[_0x1c419e]['pairId']));}['_processTape'](_0xb9dad3){for(let _0x393a96=0x0;_0x393a96<_0xb9dad3['length'];_0x393a96++){if('elementStart'===_0xb9dad3[_0x393a96]['type'])_0xb9dad3[_0x393a96]['item']['startIndex']=_0x393a96;else{if('elementEnd'===_0xb9dad3[_0x393a96]['type']){_0xb9dad3[_0x393a96]['item']['endIndex']=_0x393a96;const _0x149f66=_0xb9dad3[_0x393a96]['item']['startIndex'];_0xb9dad3[_0x149f66]['pairId']=_0xb9dad3[_0x393a96]['id'],_0xb9dad3[_0x393a96]['pairId']=_0xb9dad3[_0x149f66]['id'];}else _0xb9dad3[_0x393a96]['item']['startIndex']=_0x393a96,_0xb9dad3[_0x393a96]['item']['endIndex']=_0x393a96,_0xb9dad3[_0x393a96]['pairId']=null;}_0xb9dad3[_0x393a96]['markersStart']||(_0xb9dad3[_0x393a96]['markersStart']=[],_0xb9dad3[_0x393a96]['markersEnd']=[]);}}['_markInsertions'](_0x3ebb8e,_0x57e38e){const _0x116475=_0x3ebb8e['filter'](_0x5eaaea=>!_0x5eaaea['isAdded']);for(let _0x504e7d=0x0;_0x504e7d<_0x57e38e['length'];_0x504e7d++)_0x57e38e[_0x504e7d]['isAdded']&&(_0x116475[_0x504e7d]['isAdded']=_0x57e38e[_0x504e7d]['isAdded']);}['_getDiff'](_0x3675c4,_0xf64318=null){const _0x49d730=this['repository']['getRevision'](_0x3675c4),_0x2943b6=_0xf64318?this['repository']['getRevision'](_0xf64318):null,_0x582b29=this['_getRevisionsRange'](_0x49d730,_0x2943b6),_0x5b89c9=_0x582b29[_0x582b29['length']-0x1],_0x2a2091=new Map(),_0xbd18c0={'model':{},'attributes':{},'changes':[]},_0x205e25=new Set(),_0x5b364a=new Map();for(let _0x458a1c=_0x582b29['length']-0x1;_0x458a1c>=0x0;_0x458a1c--){const _0x5a8e1d=_0x582b29[_0x458a1c];for(const _0x3c94ed of Object['keys'](_0x5a8e1d['diffData']))if(_0x5a8e1d['diffData'][_0x3c94ed]['attachChange']){const _0x41983d=_0x5a8e1d['diffData'][_0x3c94ed]['attachChange'];_0x41983d['isAttached']?(_0x205e25['add'](_0x3c94ed),_0x5b364a['has'](_0x3c94ed)&&_0x5b364a['get'](_0x3c94ed)['userId']==_0x41983d['userId']?_0x5b364a['delete'](_0x3c94ed):_0x5b364a['set'](_0x3c94ed,_0x41983d)):_0x5b364a['has'](_0x3c94ed)?(_0x205e25['delete'](_0x3c94ed),_0x5b364a['delete'](_0x3c94ed)):(_0x205e25['add'](_0x3c94ed),_0x5b364a['set'](_0x3c94ed,_0x41983d));}else _0x205e25['add'](_0x3c94ed);}for(const _0x49d953 of _0x205e25){const _0xc1d926=_0x5b364a['has'](_0x49d953)&&!_0x5b364a['get'](_0x49d953)['isAttached'];let _0x41e582=_0xc1d926?_0x582b29['length']-0x1:0x0;const _0x43e887=_0xc1d926?-0x1:0x1;for(;_0x582b29[_0x41e582];){const _0x19d154=_0x582b29[_0x41e582];if(_0x19d154['diffData'][_0x49d953]){const _0x46d93a=_0xc1d926?_0x19d154['diffData'][_0x49d953]['attributesBefore']:_0x19d154['diffData'][_0x49d953]['attributesAfter'];_0xbd18c0['attributes'][_0x49d953]=_0x46d93a?_0x1184a6(_0x46d93a):{};break;}_0x41e582+=_0x43e887;}}for(const _0x28498f of _0x582b29){_0x28498f['model']={};for(const _0x50655e of _0x28498f['authors'])_0x2a2091['set'](_0x50655e['id'],_0x50655e);for(const _0x3b1788 of _0x205e25){const _0xe161cc=_0x28498f['diffData'][_0x3b1788]?_0x28498f['diffData'][_0x3b1788]['insertions']:'[]',_0x59a589=_0x28498f['diffData'][_0x3b1788]?_0x28498f['diffData'][_0x3b1788]['deletions']:'[]';_0x28498f['model'][_0x3b1788]={'insertions':this['_utils']['_makeModelFromViewString'](_0xe161cc),'deletions':this['_utils']['_makeModelFromViewString'](_0x59a589)};}}for(const _0x541369 of _0x205e25){let _0x1bbaeb=null,_0x105cd2=0x0;const _0x533385=new Map(Array['from'](_0x49d730['model'][_0x541369]['insertions']['markers'])['filter'](([_0x58e90f])=>!_0x58e90f['startsWith']('revision:')));let _0x1d7240=0x0;for(const _0x1a6fb1 of _0x582b29){const _0x3fab0=this['_makeTape'](_0x1a6fb1['model'][_0x541369]['insertions']);_0x1a6fb1==_0x49d730?(_0x1bbaeb=_0x3fab0,_0x105cd2=_0x1bbaeb['length'],_0x1bbaeb['forEach'](_0x4d6edd=>{_0x4d6edd['id']=_0x1d7240++;}),this['_processTape'](_0x1bbaeb)):this['_markInsertions'](_0x1bbaeb,_0x3fab0);const _0x59b476=_0x1bbaeb['filter'](_0x2f5b9c=>!_0x2f5b9c['isAdded'])['map'](_0x1777f7=>_0x1777f7['id']);let _0x405d84=0x0;const _0x59637c=this['_makeTape'](_0x1a6fb1['model'][_0x541369]['deletions']);_0x59637c['forEach'](_0x35bbf2=>{_0x35bbf2['isRemoved']?_0x35bbf2['id']=_0x105cd2++:_0x35bbf2['id']=_0x59b476[_0x405d84++];}),this['_processTape'](_0x59637c),this['_setDistance'](_0x1bbaeb,'isAdded'),this['_setDistance'](_0x59637c,'isRemoved'),_0x1a6fb1==_0x49d730&&this['_markMarkers'](_0x1bbaeb,_0x533385),_0x1bbaeb=this['_joinTapes'](_0x1bbaeb,_0x59637c),this['_refreshStartEndIndex'](_0x1bbaeb),this['_setDistance'](_0x1bbaeb,'isRemoved');}_0x1bbaeb=_0x1bbaeb['filter'](_0x1c65c6=>!(_0x1c65c6['isAdded']&&_0x1c65c6['isRemoved']));const _0x3a8d0c=new Map(_0x5b89c9['model'][_0x541369]['deletions']['markers']),_0x1559af=new Set(_0x533385['keys']());for(const _0x30dc01 of _0x3a8d0c['keys']())_0x1559af['delete'](_0x30dc01);this['_markSuggestions'](_0x1bbaeb,_0x1559af),this['_fixObsoleteTags'](_0x1bbaeb),_0x1bbaeb=this['_removeMissingPairs'](_0x1bbaeb),_0x1bbaeb=this['_markMismatchedRemovedTags'](_0x1bbaeb),_0x1bbaeb=this['_removeUnsupportedChanges'](_0x1bbaeb);const {root:_0x43f64d,changes:_0x473d96}=this['_makeModelFromTape'](_0x1bbaeb,_0x2a2091,_0x541369);_0xbd18c0['model'][_0x541369]=_0x43f64d;const _0x176368=_0x5b364a['get'](_0x541369);if(_0x176368){const _0x3272ac=_0x2a2091['get'](_0x176368['userId']),_0x1de55b=new G({'author':_0x3272ac,'type':_0x176368['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x541369});_0x473d96['unshift'](_0x1de55b),_0xbd18c0['attributes'][_0x541369]['revisionHistoryAttachChange']=_0x1de55b['id'];}_0xbd18c0['changes']=_0xbd18c0['changes']['concat'](_0x473d96);}return _0xbd18c0;}['_markMarkers'](_0x609c31,_0x4e8397){for(let _0x569e9f=0x0;_0x569e9f<_0x609c31['length'];_0x569e9f++)for(const [_0x4e8a67,_0x5d7bdf]of _0x4e8397)!_0x5d7bdf['isCollapsed']&&_0x5d7bdf['start']['isEqual'](_0x609c31[_0x569e9f]['previousPosition'])&&_0x609c31[_0x569e9f]['markersStart']['push'](_0x4e8a67),_0x5d7bdf['end']['isEqual'](_0x609c31[_0x569e9f]['nextPosition'])&&_0x609c31[_0x569e9f]['markersEnd']['push'](_0x4e8a67);}['_joinTapes'](_0x254d87,_0x1d90e8){let _0x4afd1d=[],_0x20f6b3=0x0,_0x323674=0x0;for(;_0x20f6b3<_0x254d87['length']||_0x323674<_0x1d90e8['length'];){const _0x57ba65=_0x254d87[_0x20f6b3]||{},_0x399544=_0x1d90e8[_0x323674]||{};if(_0x57ba65['id']==_0x399544['id'])_0x20f6b3++,_0x323674++,_0x4afd1d['push'](_0x57ba65);else{if(_0x399544['isRemoved']&&_0x57ba65['isAdded']){const {commonTape:_0x1ccb7a,iEnd:_0x294f00,jEnd:_0xba823f}=this['_threeWayMerge'](_0x254d87,_0x20f6b3,_0x1d90e8,_0x323674);_0x4afd1d=_0x4afd1d['concat'](_0x1ccb7a),_0x20f6b3=_0x294f00,_0x323674=_0xba823f;}else _0x399544['isRemoved']?(_0x323674++,_0x4afd1d['push'](_0x399544)):(_0x20f6b3++,_0x4afd1d['push'](_0x57ba65));}}return _0x4afd1d;}['_markSuggestions'](_0x222039,_0x29590e){const _0x7ad6cf=[];for(let _0x2ad098=0x0;_0x2ad098<_0x222039['length'];_0x2ad098++){for(let _0xe3a1d5=0x0;_0xe3a1d5<_0x222039[_0x2ad098]['markersStart']['length'];_0xe3a1d5++){const _0x3c93cf=_0x222039[_0x2ad098]['markersStart'][_0xe3a1d5];if(!_0x29590e['has'](_0x3c93cf))continue;const {group:_0x1cc591,type:_0x80fd27,authorId:_0x18958e}=_0x3adb01(_0x3c93cf);'revision-suggestion'!=_0x1cc591||'insertion'!=_0x80fd27&&'deletion'!=_0x80fd27||(_0x7ad6cf['unshift']({'type':_0x80fd27,'name':_0x3c93cf,'userId':_0x18958e}),_0x222039[_0x2ad098]['markersStart']['splice'](_0xe3a1d5,0x1),_0xe3a1d5--);}_0x2a28d4(_0x222039[_0x2ad098]);for(let _0x2b184f=0x0;_0x2b184f<_0x222039[_0x2ad098]['markersEnd']['length'];_0x2b184f++){const _0x3b8921=_0x222039[_0x2ad098]['markersEnd'][_0x2b184f];if(!_0x29590e['has'](_0x3b8921))continue;const {group:_0x352a48,type:_0x17e76e}=_0x3adb01(_0x3b8921);if('revision-suggestion'!=_0x352a48||'insertion'!=_0x17e76e&&'deletion'!=_0x17e76e)continue;_0x222039[_0x2ad098]['markersEnd']['splice'](_0x2b184f,0x1),_0x2b184f--;const _0x38ae46=_0x7ad6cf['findIndex'](_0x1f413d=>_0x1f413d['name']==_0x3b8921);_0x38ae46>-0x1&&_0x7ad6cf['splice'](_0x38ae46,0x1);}}function _0x3adb01(_0x29776b){const _0x192574=_0x29776b['split'](':');return{'group':_0x192574[0x0],'type':_0x192574[0x1],'subType':_0x192574['length']>=0x5?_0x192574[0x2]:null,'id':_0x192574['length']<0x5?_0x192574[0x2]:_0x192574[0x3],'authorId':_0x192574['length']<0x5?_0x192574[0x3]:_0x192574[0x4],'markerCount':0x6==_0x192574['length']?_0x192574[0x5]:null};}function _0x2a28d4(_0x1860ac){for(let _0x3682d0=0x0;_0x3682d0<_0x7ad6cf['length'];_0x3682d0++){if(_0x1860ac['isAdded']&&'insertion'==_0x7ad6cf[_0x3682d0]['type']&&_0x1860ac['isAdded']['userId']==_0x7ad6cf[_0x3682d0]['userId'])return _0x1860ac['isAddSuggestion']=_0x7ad6cf[_0x3682d0],void delete _0x1860ac['isAdded'];if(!_0x1860ac['isAdded']&&!_0x1860ac['isRemoved']&&'deletion'==_0x7ad6cf[_0x3682d0]['type'])return void(_0x1860ac['isRemoveSuggestion']=_0x7ad6cf[_0x3682d0]);}}}['_setDistance'](_0x465f40,_0x3fc587){let _0x52846f=0x0,_0x547241=!0x1;const _0x32e051=new Map();for(const _0x124cc3 of _0x465f40)_0x124cc3[_0x3fc587]?_0x547241&&(_0x52846f++,_0x547241=!0x1):(_0x52846f++,_0x547241=!0x0),_0x32e051['set'](_0x124cc3['id'],_0x52846f);for(let _0x179b68=0x0;_0x179b68<_0x465f40['length'];_0x179b68++){if('isRemoved'==_0x3fc587&&_0x465f40[_0x179b68]['isAdded']||'isAdded'==_0x3fc587&&_0x465f40[_0x179b68]['isRemoved'])continue;if('text'==_0x465f40[_0x179b68]['type']){_0x465f40[_0x179b68]['distance']=0x0;continue;}const _0x1a6467=_0x32e051['get'](_0x465f40[_0x179b68]['pairId']),_0x1dd284=_0x32e051['get'](_0x465f40[_0x179b68]['id']);_0x465f40[_0x179b68]['distance']=_0x1a6467-_0x1dd284;}}['_getRevisionsRange'](_0x4b3cca,_0x5ea140,_0x40589d=!0x1){const _0x2e99f3=[];let _0x289ae9=this['repository']['getIndex'](_0x4b3cca),_0x1f9718=this['repository']['getIndex'](_0x5ea140);for(-0x1==_0x1f9718&&(_0x1f9718=this['repository']['_revisions']['length'],_0x40589d=!0x1);_0x289ae9<_0x1f9718;)_0x2e99f3['push'](this['repository']['getRevision'](_0x289ae9)),_0x289ae9++;return _0x40589d&&_0x2e99f3['push'](this['repository']['getRevision'](_0x289ae9)),_0x2e99f3;}['_threeWayMerge'](_0x31aa6b,_0xf3fe6e,_0x3261b5,_0x41b421){const _0x555346=this['editor']['model']['schema'];let _0x1b20ba=_0xf3fe6e;for(;_0x31aa6b[_0x1b20ba]&&_0x31aa6b[_0x1b20ba]['isAdded'];)_0x1b20ba++;let _0x3d4599=_0x41b421;for(;_0x3261b5[_0x3d4599]&&_0x3261b5[_0x3d4599]['isRemoved'];)_0x3d4599++;_0x592563(_0x31aa6b,_0xf3fe6e,_0x1b20ba),_0x592563(_0x3261b5,_0x41b421,_0x3d4599);const _0x3021ca=_0x3261b5['slice'](_0x41b421,_0x3d4599)['concat'](_0x31aa6b['slice'](_0xf3fe6e,_0x1b20ba));return _0x3021ca['sort']((_0x45f862,_0x5e96f0)=>_0x45f862['side']!=_0x5e96f0['side']?_0x45f862['side']-_0x5e96f0['side']:_0x45f862['level']!=_0x5e96f0['level']?_0x45f862['level']-_0x5e96f0['level']:_0x45f862['distance']!=_0x5e96f0['distance']?_0x5e96f0['distance']-_0x45f862['distance']:!!_0x45f862['isAdded']!=!!_0x5e96f0['isAdded']?-0x1==_0x45f862['side']||0x0==_0x45f862['side']?_0x45f862['isAdded']?-0x1:0x1:_0x45f862['isAdded']?0x1:-0x1:_0x45f862['index']-_0x5e96f0['index']),{'commonTape':_0x3021ca,'iEnd':_0x1b20ba,'jEnd':_0x3d4599};function _0x592563(_0x20f579,_0x403a7b,_0x3fdd7b){let _0x3a2d70=-0x1,_0x2aaa08=Number['POSITIVE_INFINITY'],_0x1cd669=!0x0;for(let _0x2e0763=_0x403a7b;_0x2e0763<_0x3fdd7b;_0x2e0763++)if(_0x555346['isInline'](_0x20f579[_0x2e0763]['item'])||(_0x1cd669=!0x1),_0x20f579[_0x2e0763]['item']['startIndex']<_0x403a7b&&(_0x3a2d70=_0x2e0763),_0x20f579[_0x2e0763]['item']['endIndex']>=_0x3fdd7b){_0x2aaa08=_0x2e0763;break;}_0x1cd669&&(_0x3a2d70=_0x3fdd7b-0x1);for(let _0x468406=_0x403a7b;_0x468406<_0x3fdd7b;_0x468406++)_0x20f579[_0x468406]['side']=_0x468406<=_0x3a2d70?-0x1:_0x468406<_0x2aaa08?0x0:0x1,_0x20f579[_0x468406]['index']=_0x468406;let _0x10e210=0x0;for(let _0x415b02=_0x403a7b;_0x415b02<=_0x3a2d70;_0x415b02++)0x0==_0x20f579[_0x415b02]['distance']?_0x20f579[_0x415b02]['level']=_0x10e210:(_0x10e210++,_0x20f579[_0x415b02]['level']=_0x10e210,_0x10e210++);for(let _0x4cc240=_0x403a7b;_0x4cc240<_0x3fdd7b;_0x4cc240++)0x0==_0x20f579[_0x4cc240]['side']&&(_0x20f579[_0x4cc240]['level']=_0x10e210);_0x10e210=0x0;for(let _0xd65c3a=_0x3fdd7b-0x1;_0xd65c3a>=_0x2aaa08;_0xd65c3a--)0x0==_0x20f579[_0xd65c3a]['distance']?_0x20f579[_0xd65c3a]['level']=_0x10e210:(_0x10e210--,_0x20f579[_0xd65c3a]['level']=_0x10e210,_0x10e210--);}}['_fixObsoleteTags'](_0x30f967){const _0x2c01f4=new Map(),_0x5ca367=this['editor']['model']['schema'];for(let _0x67fc7f=0x1;_0x67fc7f<_0x30f967['length'];_0x67fc7f++){let _0x571da4,_0x1e40eb,_0x4c0a9b;const _0x150ff3=_0x30f967[_0x67fc7f],_0x348675=_0x30f967[_0x67fc7f-0x1];if('text'==_0x150ff3['type'])continue;if(_0x150ff3['type']!=_0x348675['type'])continue;if(!_0x5ca367['isBlock'](_0x348675['item'])||_0x5ca367['isLimit'](_0x348675['item']))continue;if(!_0x5ca367['isBlock'](_0x150ff3['item'])||_0x5ca367['isLimit'](_0x150ff3['item']))continue;if((_0x30f967[_0x67fc7f]['isAdded']||_0x30f967[_0x67fc7f]['isAddSuggestion'])&&_0x30f967[_0x67fc7f-0x1]['isRemoved'])_0x571da4=_0x30f967[_0x67fc7f],_0x1e40eb=_0x30f967[_0x67fc7f-0x1],_0x4c0a9b=_0x67fc7f-0x1;else{if(!_0x30f967[_0x67fc7f]['isRemoved']||!_0x30f967[_0x67fc7f-0x1]['isAdded']&&!_0x30f967[_0x67fc7f-0x1]['isAddSuggestion'])continue;_0x571da4=_0x30f967[_0x67fc7f-0x1],_0x1e40eb=_0x30f967[_0x67fc7f],_0x4c0a9b=_0x67fc7f;}const _0x5767cf=_0x571da4['level']==_0x1e40eb['level'],_0x5f435f=Math['abs'](_0x571da4['level'])<Math['abs'](_0x1e40eb['level'])&&0x0==_0x1e40eb['distance'];(_0x5767cf||_0x5f435f)&&(_0x2c01f4['set'](_0x1e40eb['id'],_0x571da4['id']),_0x30f967['splice'](_0x4c0a9b,0x1),_0x67fc7f--,_0x571da4['isAdded']=!0x1);}for(let _0x350a10=0x0;_0x350a10<_0x30f967['length'];_0x350a10++)_0x2c01f4['has'](_0x30f967[_0x350a10]['pairId'])&&(_0x30f967[_0x350a10]['pairId']=_0x2c01f4['get'](_0x30f967[_0x350a10]['pairId']));}['_removeMissingPairs'](_0x5d008b){const _0x23fa95=new Set(_0x5d008b['map'](_0x8fa0f6=>_0x8fa0f6['id']));for(let _0x4d30ca=0x0;_0x4d30ca<_0x5d008b['length'];_0x4d30ca++)_0x23fa95['has'](_0x5d008b[_0x4d30ca]['pairId'])||0x0==_0x5d008b[_0x4d30ca]['distance']||(_0x5d008b[_0x4d30ca]['isIncorrect']=!0x0);return _0x5d008b['filter'](_0x2ea878=>!_0x2ea878['isIncorrect']);}['_markMismatchedRemovedTags'](_0x1869f3){const _0x406565=new Set();for(let _0x44b900=0x0;_0x44b900<_0x1869f3['length'];_0x44b900++){if(_0x406565['has'](_0x1869f3[_0x44b900]['id'])&&_0x1869f3[_0x44b900]['isRemoved']&&(_0x1869f3[_0x44b900]['isIncorrect']=!0x0),_0x1869f3[_0x44b900]['isIncorrect'])continue;if(0x0==_0x1869f3[_0x44b900]['distance'])continue;if('elementStart'!=_0x1869f3[_0x44b900]['type'])continue;if(null==_0x1869f3[_0x44b900]['pairId'])continue;let _0x59f592=_0x44b900+0x1,_0x5a8fa6=0x0;for(;_0x1869f3[_0x59f592]['id']!=_0x1869f3[_0x44b900]['pairId'];)'elementStart'==_0x1869f3[_0x59f592]['type']?_0x5a8fa6++:'elementEnd'==_0x1869f3[_0x59f592]['type']&&_0x5a8fa6--,_0x59f592++;if(0x0!=_0x5a8fa6){if(_0x1869f3[_0x44b900]['isRemoved'])_0x1869f3[_0x44b900]['isIncorrect']=!0x0;else{for(;_0x59f592!=_0x44b900;)_0x1869f3[_0x59f592]['isRemoved']&&0x0!=_0x1869f3[_0x59f592]['distance']&&(_0x1869f3[_0x59f592]['isIncorrect']=!0x0,_0x406565['add'](_0x1869f3[_0x59f592]['pairId'])),_0x59f592--;}}}return _0x1869f3['filter'](_0x326aa6=>!_0x326aa6['isIncorrect']);}['_removeUnsupportedChanges'](_0xe7a021){const _0x5c8262=this['editor']['model']['schema'];for(let _0x13f449=0x0;_0x13f449<_0xe7a021['length'];_0x13f449++){if(!(_0xe7a021[_0x13f449]['isAdded']||_0xe7a021[_0x13f449]['isAddSuggestion']||_0xe7a021[_0x13f449]['isRemoved']||_0xe7a021[_0x13f449]['isRemoveSuggestion']))continue;if(0x0==_0xe7a021[_0x13f449]['distance'])continue;const _0x19cd89=_0xe7a021[_0x13f449]['item'];_0x5c8262['isBlock'](_0x19cd89)||_0x5c8262['isLimit'](_0x19cd89)||(_0xe7a021[_0x13f449]['isAdded']&&delete _0xe7a021[_0x13f449]['isAdded'],_0xe7a021[_0x13f449]['isAddSuggestion']&&delete _0xe7a021[_0x13f449]['isAddSuggestion'],_0xe7a021[_0x13f449]['isRemoveSuggestion']&&delete _0xe7a021[_0x13f449]['isRemoveSuggestion'],_0xe7a021[_0x13f449]['isRemoved']&&(_0xe7a021[_0x13f449]['isIncorrect']=!0x0));}return _0xe7a021['filter'](_0x35eefd=>!_0x35eefd['isIncorrect']);}['_makeModelFromTape'](_0x126993,_0x2535f6,_0x1a5594){const _0x55b7bd=new _0x235d32(),_0x26e78e=[],_0x4d12f8=new Map(),_0x23fa36=this['editor']['model'],_0x104148=_0x23fa36['schema'],_0x373afe=[_0x55b7bd],_0x6c5d30={},_0x3f3522={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x1178fa=null;const _0x6429f0=[0x0];for(let _0x3ee336=0x0;_0x3ee336<_0x126993['length'];_0x3ee336++)if('elementStart'===_0x126993[_0x3ee336]['type']){_0x126993[_0x3ee336]['previousPosition']=_0x23fa36['createPositionFromPath'](_0x55b7bd,_0x6429f0);const _0x111df4=new _0x1feb76(_0x126993[_0x3ee336]['item']['name'],_0x126993[_0x3ee336]['item']['getAttributes']());_0x373afe[0x0]['_appendChild'](_0x111df4),_0x6429f0['push'](0x0),_0x373afe['unshift'](_0x111df4),_0x126993[_0x3ee336]['nextPosition']=_0x23fa36['createPositionFromPath'](_0x55b7bd,_0x6429f0);}else'elementEnd'===_0x126993[_0x3ee336]['type']?(_0x373afe['shift'](),_0x126993[_0x3ee336]['previousPosition']=_0x23fa36['createPositionFromPath'](_0x55b7bd,_0x6429f0),_0x6429f0['pop'](),_0x6429f0[_0x6429f0['length']-0x1]++,_0x126993[_0x3ee336]['nextPosition']=_0x23fa36['createPositionFromPath'](_0x55b7bd,_0x6429f0)):(_0x126993[_0x3ee336]['previousPosition']=_0x23fa36['createPositionFromPath'](_0x55b7bd,_0x6429f0),_0x1178fa?_0x1178fa['_data']+=_0x126993[_0x3ee336]['item']['data']:_0x1178fa=new _0x5ce995(_0x126993[_0x3ee336]['item']['data'],_0x126993[_0x3ee336]['item']['getAttributes']()),_0x126993[_0x3ee336+0x1]&&'text'===_0x126993[_0x3ee336+0x1]['type']&&_0x17a348(_0x1178fa,_0x126993[_0x3ee336+0x1]['item'])||(_0x373afe[0x0]['_appendChild'](_0x1178fa),_0x1178fa=null),_0x6429f0[_0x6429f0['length']-0x1]+=_0x126993[_0x3ee336]['item']['offsetSize'],_0x126993[_0x3ee336]['nextPosition']=_0x23fa36['createPositionFromPath'](_0x55b7bd,_0x6429f0));for(let _0x275d7f=0x0;_0x275d7f<_0x126993['length'];_0x275d7f++){const _0x485399=_0x126993[_0x275d7f]['previousPosition'],_0x2c4f90=_0x126993[_0x275d7f]['nextPosition'];for(const _0x7bc91c of _0x126993[_0x275d7f]['markersStart'])_0x4d12f8['set'](_0x7bc91c,{'start':_0x485399,'end':null});_0x29af43('isRemoveSuggestion',_0x275d7f,_0x485399,_0x2c4f90),_0x29af43('isAddSuggestion',_0x275d7f,_0x485399,_0x2c4f90),_0x29af43('isRemoved',_0x275d7f,_0x485399,_0x2c4f90),_0x29af43('isAdded',_0x275d7f,_0x485399,_0x2c4f90);for(const _0x172eac of _0x126993[_0x275d7f]['markersEnd']){const _0x2d627c=_0x4d12f8['get'](_0x172eac);_0x2d627c?_0x2d627c['end']=_0x2c4f90:_0x4d12f8['set'](_0x172eac,{'start':_0x2c4f90,'end':_0x2c4f90});}}for(const [_0x36e78e,_0x552eff]of _0x4d12f8){const _0x4385da=this['editor']['model']['createRange'](_0x552eff['start'],_0x552eff['end']);_0x55b7bd['markers']['set'](_0x36e78e,_0x4385da);}return _0x26e78e['sort']((_0x55adfa,_0x2e1c8a)=>{const _0x2d1084=_0x55b7bd['markers']['get']('revision:'+_0x55adfa['id']),_0x158d09=_0x55b7bd['markers']['get']('revision:'+_0x2e1c8a['id']);return _0x2d1084['start']['isBefore'](_0x158d09['start'])?-0x1:_0x2d1084['start']['isAfter'](_0x158d09['start'])?0x1:_0x2d1084['end']['isBefore'](_0x158d09['end'])?-0x1:_0x2d1084['end']['isAfter'](_0x158d09['end'])?0x1:'add'===_0x55adfa['type']?-0x1:0x1;}),{'root':_0x55b7bd,'changes':_0x26e78e};function _0x29af43(_0x1cbe18,_0x2932f7,_0x1a12d7,_0x1fd62f){const _0x342bc2=!!_0x126993[_0x2932f7][_0x1cbe18],_0x333ef2=_0x342bc2?_0x126993[_0x2932f7][_0x1cbe18]['userId']:null,_0xea677c=_0x2932f7===_0x126993['length']-0x1,_0x162a29=_0x3f3522[_0x1cbe18][0x0],_0x552569=_0x104148['isObject'](_0x126993[_0x2932f7]['item']);!_0x6c5d30[_0x1cbe18]&&_0x342bc2?_0x6c5d30[_0x1cbe18]={'start':_0x1a12d7,'tapeItem':_0x126993[_0x2932f7],'userId':_0x333ef2,'type':_0x1cbe18}:_0x6c5d30[_0x1cbe18]&&!_0x342bc2?(_0x6c5d30[_0x1cbe18]['end']=_0x1a12d7,_0x8e1fe0(_0x6c5d30[_0x1cbe18]),_0x6c5d30[_0x1cbe18]=null):_0x6c5d30[_0x1cbe18]&&_0x342bc2&&_0x6c5d30[_0x1cbe18]['userId']!==_0x333ef2&&(_0x6c5d30[_0x1cbe18]['end']=_0x1a12d7,_0x162a29&&_0x162a29['userId']===_0x6c5d30[_0x1cbe18]['userId']||_0x8e1fe0(_0x6c5d30[_0x1cbe18]),_0x6c5d30[_0x1cbe18]={'start':_0x1a12d7,'tapeItem':_0x126993[_0x2932f7],'userId':_0x333ef2,'type':_0x1cbe18}),_0x6c5d30[_0x1cbe18]&&_0x552569&&('elementStart'!==_0x126993[_0x2932f7]['type']||_0x162a29&&_0x162a29['userId']===_0x333ef2||_0x3f3522[_0x1cbe18]['unshift']({'userId':_0x333ef2,'object':_0x126993[_0x2932f7]['item'],'change':_0x6c5d30[_0x1cbe18]}),'elementEnd'===_0x126993[_0x2932f7]['type']&&_0x162a29&&_0x162a29['object']===_0x126993[_0x2932f7]['item']&&(_0x3f3522[_0x1cbe18]['shift'](),_0x6c5d30[_0x1cbe18]=_0x162a29['change'])),_0x6c5d30[_0x1cbe18]&&_0xea677c&&(_0x6c5d30[_0x1cbe18]['end']=_0x1fd62f,_0x8e1fe0(_0x6c5d30[_0x1cbe18]),_0x6c5d30[_0x1cbe18]=null);}function _0x8e1fe0({start:_0x449629,end:_0x3a2044,tapeItem:_0x599f31,userId:_0x48ee99,type:_0xcc1549}){const _0x141f04=_0x599f31['item'],_0xa8fc86=_0x23fa36['schema']['isBlock'](_0x141f04)&&!_0x23fa36['schema']['isLimit'](_0x141f04),_0x1d74b5=_0x449629['nodeAfter']==_0x3a2044['parent']&&_0x3a2044['isAtStart'];if(_0xa8fc86&&_0x1d74b5)return;const _0x495c86=_0x23fa36['createRange'](_0x449629,_0x3a2044),_0x4a8c65=_0x2535f6['get'](_0x48ee99),_0x4bdd63=new G({'author':_0x4a8c65,'type':'isAdded'==_0xcc1549||'isAddSuggestion'==_0xcc1549?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0xcc1549||'isRemoveSuggestion'==_0xcc1549},'createdAt':new Date(),'rootName':_0x1a5594});_0x26e78e['push'](_0x4bdd63),_0x55b7bd['markers']['set']('revision:'+_0x4bdd63['id'],_0x495c86);}function _0x17a348(_0x11eb10,_0x46dff8){const _0x57e02b=_0x11eb10['getAttributes'](),_0x892975=_0x46dff8['getAttributes']();for(const _0x1d3c28 of _0x57e02b){if(_0x1d3c28[0x1]!==_0x46dff8['getAttribute'](_0x1d3c28[0x0]))return!0x1;_0x892975['next']();}return _0x892975['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x313d2b=>{const _0x367ef3=_0x313d2b['markerName']['split'](':')[0x1],_0x350d3f=this['_getChangeFromId'](_0x367ef3);if(!_0x350d3f)return null;const _0x5b7a2e='add'==_0x350d3f['type']?'insertion':'deletion',_0x1d0cd1=['ck-suggestion-marker','ck-suggestion-marker-'+_0x5b7a2e];return _0x350d3f['data']['isSuggestion']&&_0x1d0cd1['push']('ck-suggestion-marker-'+_0x5b7a2e+'-new'),this['activeChange']==_0x350d3f&&_0x1d0cd1['push']('ck-suggestion-marker--active'),{'classes':_0x1d0cd1,'attributes':{'data-change-id':_0x367ef3}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x282ca5=>{_0x282ca5['on']('element:pre',(_0x21418c,_0x489934,_0x438849)=>{const _0x3df5cf=_0x489934['viewItem']['getChild'](0x0);if(!_0x3df5cf||!_0x3df5cf['is']('element','code'))return;if(!_0x438849['consumable']['consume'](_0x3df5cf,{'attributes':['vid_start','vid_end']}))return;const _0x1a17a9=_0x489934['modelRange']['start']['nodeAfter'];_0x438849['writer']['setAttribute']('vid_start',_0x3df5cf['getAttribute']('vid_start'),_0x1a17a9),_0x438849['writer']['setAttribute']('vid_end',_0x3df5cf['getAttribute']('vid_end'),_0x1a17a9);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x5c58c1=>{_0x5c58c1['on']('element',(_0x5e179b,_0x3fb2e2,_0x9da90d)=>{if(!_0x9da90d['consumable']['consume'](_0x3fb2e2['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x3fb2e2['modelRange']['isCollapsed'])return;const _0x2ec381=_0x3fb2e2['modelRange']['start']['nodeAfter'];_0x2ec381['hasAttribute']('vid_start')||_0x2ec381['hasAttribute']('vid')||(_0x9da90d['writer']['setAttribute']('vid_start',_0x3fb2e2['viewItem']['getAttribute']('vid_start'),_0x2ec381),_0x9da90d['writer']['setAttribute']('vid_end',_0x3fb2e2['viewItem']['getAttribute']('vid_end'),_0x2ec381));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x430d11=>_0x430d11['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x5419e7,[,_0x19e903])=>{['vid_start','vid_end','vid']['includes'](_0x19e903)&&(_0x5419e7['return']=!0x0,_0x5419e7['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x2a3ed7=>{_0x2a3ed7['on']('attribute:vid',(_0x57bf03,_0x68393a,_0x36936e)=>{if('\x20'!=_0x68393a['item']['data']||_0x68393a['item']['parent']['maxOffset']>0x1)return;if(!_0x36936e['consumable']['consume'](_0x68393a['item'],_0x57bf03['name']))return;const _0x2e3c22=_0x36936e['writer'],_0xb916c7=_0x36936e['mapper']['toViewRange'](_0x68393a['range']);_0x2e3c22['wrap'](_0xb916c7,_0x2e3c22['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x1f850d){const _0x14a1b4=_0x1f850d['plugins']['get']('RevisionViewer');return(_0x17e996,_0x1c15e0,_0x35a4be)=>{const _0x3f1970=_0x1c15e0['markerName']['split'](':')[0x1],_0xc9bac9=_0x14a1b4['_getChangeFromId'](_0x3f1970);if(!_0xc9bac9)return null;const _0x3673e0='add'==_0xc9bac9['type']?'split':'merge';if(!_0x35a4be['consumable']['test'](_0x1c15e0['markerRange'],_0x17e996['name']))return;const _0x127351=_0x1c15e0['markerRange']['getWalker'](),_0x5403ea=_0x1c15e0['markerRange']['start'],_0x3ef018=_0x1f850d['model']['schema'];let _0x4b091b=null,_0x296938=null,_0x16894c=!0x1,_0x253030=!0x1;for(const _0x4c0d42 of _0x127351){const _0x42c7f8=_0x4c0d42['item'];_0x16894c=_0x16894c||_0x3ef018['isContent'](_0x42c7f8);const _0x52f529=_0x35a4be['mapper']['toViewElement'](_0x42c7f8);if(_0x52f529&&_0x52f529['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x4c0d42['type']&&(_0x3ef018['isBlock'](_0x42c7f8)&&!_0x3ef018['isLimit'](_0x42c7f8)&&(_0x42c7f8['nextSibling']||_0x5403ea['isAtEnd']?_0x4b091b&&_0x4b091b['parent']==_0x42c7f8||(_0x4b091b=_0x42c7f8,_0x77d509(_0x4c0d42['previousPosition']),_0x253030=!0x0):_0x296938=_0x296938||_0x4c0d42['previousPosition']));}function _0x77d509(_0x50b2e8){const _0x3b5df8=_0x35a4be['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x3673e0}),_0x59259d=_0x35a4be['mapper']['toViewPosition'](_0x50b2e8);_0xc9bac9['data']['isSuggestion']&&_0x35a4be['writer']['addClass']('ck-suggestion-marker-'+_0x3673e0+'-new',_0x3b5df8),_0x14a1b4['activeChange']==_0xc9bac9&&_0x35a4be['writer']['addClass']('ck-suggestion-marker--active',_0x3b5df8),_0x35a4be['writer']['insert'](_0x59259d,_0x3b5df8),_0x35a4be['mapper']['bindElementToMarker'](_0x3b5df8,_0x1c15e0['markerName']);}_0x16894c||_0x253030||!_0x296938||_0x77d509(_0x296938);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x3b0d03,_0x20970a,_0x1be30c)=>{const _0x6dec03=_0x1be30c['mapper']['markerNameToElements'](_0x20970a['markerName']);if(_0x6dec03){for(const _0x392b0b of _0x6dec03)(_0x392b0b['hasClass']('ck-suggestion-marker-split')||_0x392b0b['hasClass']('ck-suggestion-marker-merge'))&&(_0x1be30c['mapper']['unbindElementFromMarkerName'](_0x392b0b,_0x20970a['markerName']),_0x1be30c['writer']['remove'](_0x392b0b));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x33b54f,_0x5941a3,_0x4baec5)=>{const _0x8b3594=_0x5941a3['markerName']['split'](':')[0x1],_0x5895f6=this['_getChangeFromId'](_0x8b3594);if(!_0x5895f6)return null;const _0x2ebd27='add'==_0x5895f6['type']?'split':'merge';if(_0x4baec5['consumable']['test'](_0x5941a3['markerRange'],_0x33b54f['name']))for(const _0x13f639 of _0x5941a3['markerRange']['getItems']()){if(!_0x13f639['is']('element','softBreak'))continue;const _0x5ea1df=_0x4baec5['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x2ebd27}),_0x289c1c=_0x4baec5['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x13f639));_0x5895f6['data']['isSuggestion']&&_0x4baec5['writer']['addClass']('ck-suggestion-marker-'+_0x2ebd27+'-new',_0x5ea1df),this['activeChange']==_0x5895f6&&_0x4baec5['writer']['addClass']('ck-suggestion-marker--active',_0x5ea1df),_0x4baec5['writer']['insert'](_0x289c1c,_0x5ea1df),_0x4baec5['mapper']['bindElementToMarker'](_0x5ea1df,_0x5941a3['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x387c57=>{for(const _0x5cc1d0 of this['editor']['model']['document']['getRootNames']()){const _0x50a5f1=this['editor']['model']['document']['getRoot'](_0x5cc1d0),_0x519627=this['editor']['editing']['view']['document']['getRoot'](_0x5cc1d0);if(_0x519627){const _0x45cf8b=_0x50a5f1['getAttribute']('revisionHistoryAttachChange');if(_0x387c57['removeAttribute']('data-change-id',_0x519627),_0x387c57['removeClass']('ck-revision-history-root-add',_0x519627),_0x387c57['removeClass']('ck-revision-history-root-remove',_0x519627),_0x387c57['removeClass']('ck-revision-history-root--active',_0x519627),_0x45cf8b){const _0x1cfc1f=this['_getChangeFromId'](_0x45cf8b);if(!_0x1cfc1f)return null;_0x387c57['setAttribute']('data-change-id',_0x45cf8b,_0x519627),_0x387c57['addClass']('ck-revision-history-root-'+_0x1cfc1f['type'],_0x519627),this['activeChange']==_0x1cfc1f&&_0x387c57['addClass']('ck-revision-history-root--active',_0x519627);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x514b16=>'revision-comment:'+_0x514b16,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x36f0fd=>'revision-suggestion:'+_0x36f0fd,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x2870af=>({'name':'suggestion:'+_0x2870af,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x16a092=>{const _0x30f59b=_0x16a092['markerName']['split'](':')[0x1];return'insertion'!=_0x30f59b&&'deletion'!=_0x30f59b?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x30f59b]};}}),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',(_0x511a82,_0x3bb196,_0x7f42c7)=>{const _0x41d8bd=_0x7f42c7['mapper']['markerNameToElements'](_0x3bb196['markerName']);if(_0x41d8bd){for(const _0xcbcd of _0x41d8bd)_0xcbcd['is']('uiElement')&&(_0x7f42c7['mapper']['unbindElementFromMarkerName'](_0xcbcd,_0x3bb196['markerName']),_0x7f42c7['writer']['remove'](_0xcbcd));}},{'priority':'high'});}['_getChangeFromId'](_0x100e09){return this['_changeIdToChange']['get'](_0x100e09);}['_getViewForChange'](_0x1f9330){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new z(this['editor']['locale'],_0x1f9330),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x4ac463,_0x505abb,_0x3d286c,_0x6a9efe)=>{_0x6a9efe&&this['_balloon']['remove'](_0x6a9efe),_0x3d286c&&(this['_balloon']['add']({'view':_0x3d286c,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0xfca8f0=this['editor']['editing'],_0x4c80cd=this['_getChangeFromId'](_0x3d286c['changeId']);let _0xbb36cf;if(_0x4c80cd['data']['isOnRoot']){const _0x319d8f=_0xfca8f0['view']['getDomRoot'](_0x4c80cd['rootName']);_0xbb36cf=Array['from'](_0x319d8f['getClientRects']());}else{const _0x3d98d0=this['editor']['model']['markers']['get']('revision:'+_0x3d286c['changeId']);_0xbb36cf=Array['from'](_0xfca8f0['mapper']['markerNameToElements'](_0x3d98d0['name']))['map'](_0x14fb65=>_0xfca8f0['view']['domConverter']['mapViewToDom'](_0x14fb65))['map'](_0x281592=>Array['from'](_0x281592['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0xbb36cf[0x0];return _0xbb36cf['find'](_0x1429c5=>_0x1429c5['top']-0x3<=this['_activeViewTarget']['y']&&_0x1429c5['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x1429c5['left']-0x3<=this['_activeViewTarget']['x']&&_0x1429c5['right']+0x3>=this['_activeViewTarget']['x'])||_0xbb36cf[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x654968,_0x2e1e34,_0x35050b,_0x22c68d)=>{this['activeView']=_0x35050b?this['_getViewForChange'](_0x35050b):null,this['editor']['model']['change'](()=>{const _0xf476a8=this['editor']['editing'];_0x22c68d&&(_0x22c68d['data']['isOnRoot']?_0xf476a8['view']['change'](_0x574ac9=>{_0x574ac9['removeClass']('ck-revision-history-root--active',_0xf476a8['view']['document']['getRoot'](_0x22c68d['rootName']));}):_0xf476a8['reconvertMarker']('revision:'+_0x22c68d['id'])),_0x35050b&&(_0x35050b['data']['isOnRoot']?_0xf476a8['view']['change'](_0x365e22=>{_0x365e22['addClass']('ck-revision-history-root--active',_0xf476a8['view']['document']['getRoot'](_0x35050b['rootName']));}):_0xf476a8['reconvertMarker']('revision:'+_0x35050b['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0xf90dc1,_0x113f2f)=>{if(this['activeChange'])return;const _0x30e5e1=this['_findChangeIdFromDomTarget'](_0x113f2f['target']),_0x362fef=this['_changeIdToChange']['get'](_0x30e5e1);_0x362fef?(this['_activeViewTarget']={'x':_0x113f2f['domEvent']['x'],'y':_0x113f2f['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x362fef)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x259586,_0x556809)=>{const _0x251e68=this['_findChangeIdFromDomTarget'](_0x556809['target']),_0x373129=this['_changeIdToChange']['get'](_0x251e68);_0x373129?(this['_activeViewTarget']={'x':_0x556809['domEvent']['x'],'y':_0x556809['domEvent']['y']},_0x373129===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x373129):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x55149f){do{const _0x3f4dc4=_0x55149f['getAttribute']('data-change-id');if(_0x3f4dc4)return _0x3f4dc4;_0x55149f=_0x55149f['parent'];}while(_0x55149f);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x18e496=>{for(const _0x228bf2 of this['editor']['model']['markers'])_0x18e496['removeMarker'](_0x228bf2);});}}function Q(_0x2c8008,_0x191305){return(_0x112c09,_0xb6345a,_0x488cbe)=>{if(!_0x488cbe['consumable']['test'](_0xb6345a['markerRange'],_0x112c09['name']))return;const _0x38e5cb=_0xb6345a['markerRange']['getWalker'](),_0x57221b=_0xb6345a['markerRange']['start'],_0x418e94=_0x2c8008['model']['schema'];let _0x7bc11f=null,_0x284b93=null,_0x4f8dd7=!0x1,_0x5e7175=!0x1;for(const _0x1271f8 of _0x38e5cb){const _0x48d97e=_0x1271f8['item'];_0x4f8dd7=_0x4f8dd7||_0x418e94['isContent'](_0x48d97e);const _0x4adc01=_0x488cbe['mapper']['toViewElement'](_0x48d97e);if(_0x4adc01&&_0x4adc01['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x1271f8['type']&&(_0x418e94['isBlock'](_0x48d97e)&&!_0x418e94['isLimit'](_0x48d97e)&&(_0x48d97e['nextSibling']||_0x57221b['isAtEnd']?_0x7bc11f&&_0x7bc11f['parent']==_0x48d97e||(_0x7bc11f=_0x48d97e,_0x2c0eee(_0x1271f8['previousPosition']),_0x5e7175=!0x0):_0x284b93=_0x284b93||_0x1271f8['previousPosition']));}function _0x2c0eee(_0x39ffbb){const _0x139cba=_0x488cbe['mapper']['toViewPosition'](_0x39ffbb),_0x44c7cf=_0x488cbe['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x191305});_0x488cbe['writer']['insert'](_0x139cba,_0x44c7cf),_0x488cbe['mapper']['bindElementToMarker'](_0x44c7cf,_0xb6345a['markerName']);}_0x4f8dd7||_0x5e7175||!_0x284b93||_0x2c0eee(_0x284b93);};}class nt extends _0x63058a{constructor(_0x433dfc){super(_0x433dfc);const _0x3002d1=_0x433dfc['plugins']['get'](l);this['affectsData']=!0x1,this['listenTo'](_0x3002d1,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x3002d1,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x1116e2=this['editor'],_0x44b94c=_0x1116e2['plugins']['get'](l),_0xabf8bd=_0x44b94c['isReady']?_0x44b94c['diff']['newRevisionId']:null;_0x1116e2['config']['get']('revisionHistory')['restoreRevisionCallback'](_0xabf8bd);}['refresh'](){const {isReady:_0x4394ee,isEnabled:_0x1317f3,repository:_0x5bec1f,diff:_0x56cfbc}=this['editor']['plugins']['get'](l),_0x16cac8=_0x56cfbc&&_0x5bec1f['getLaterVisibleRevision'](_0x56cfbc['newRevisionId']);this['isEnabled']=_0x4394ee&&_0x1317f3&&Boolean(_0x16cac8);}}class rt extends _0x63058a{['_step'];constructor(_0x1ab0aa,{direction:_0x511bab}){super(_0x1ab0aa);const _0x56a0ae=_0x1ab0aa['plugins']['get'](l);this['affectsData']=!0x1,this['_step']='forward'===_0x511bab?0x1:-0x1,this['listenTo'](_0x56a0ae,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x56a0ae,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x56a0ae,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x360dac=this['editor'],_0x2fafa3=_0x360dac['plugins']['get'](l),{isNavigationMode:_0x518601,currentChangeNumber:_0x30df5e}=_0x2fafa3;let _0x20df02;if(_0x2fafa3['activeChange']=_0x518601?_0x2fafa3['diff']['changes']['get'](_0x30df5e+this['_step']):_0x2fafa3['diff']['changes']['first'],_0x2fafa3['activeChange']['data']['isOnRoot'])_0x20df02=_0x360dac['editing']['view']['getDomRoot'](_0x2fafa3['activeChange']['rootName']);else{const _0xab2096=_0x360dac['model']['markers']['get']('revision:'+_0x2fafa3['activeChange']['id']);_0x20df02=_0x43fbbc(_0x360dac['editing'],_0xab2096);}_0x557404({'target':_0x20df02,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x56db04,currentChangeNumber:_0x419ad0,numberOfChanges:_0x3b8a7c,isReady:_0x196a0b,isEnabled:_0x19a1d8}=this['editor']['plugins']['get'](l);this['isEnabled']=!!(_0x19a1d8&&_0x196a0b&&_0x3b8a7c)&&(!_0x56db04||(0x1===this['_step']?_0x419ad0<_0x3b8a7c-0x1:_0x419ad0>0x0));}}class fi extends _0x3f2314{constructor(_0x8b3865){super(_0x8b3865);const _0x23ff6c=this['bindTemplate'],_0x1bd733=new _0x21b928(_0x8b3865),_0x21805d=new _0x21b928(_0x8b3865);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',(_0x1a3ae4,_0x32ba77)=>_0x1a3ae4&&_0x32ba77>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x5b1fc6,_0x4c97f0,_0x64935,_0x2a5868)=>{if(!_0x5b1fc6)return R(_0x8b3865,'Loading...');if(!_0x64935)return R(_0x8b3865,'No\x20changes');const _0x563e4e=R(_0x8b3865,'NUMBER_OF_CHANGES',_0x64935);return _0x2a5868?R(_0x8b3865,'X_OF_Y_CHANGES',[_0x4c97f0+0x1,_0x64935]):_0x563e4e;}),_0x1bd733['set']({'label':R(_0x8b3865,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x360e11}),_0x21805d['set']({'label':R(_0x8b3865,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x28d147}),_0x1bd733['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x21805d['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x1bd733['on']('execute',()=>this['fire']('execute','backward')),_0x21805d['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',_0x23ff6c['if']('_isStatusLabelVisible','ck-hidden',_0x55f3b4=>!_0x55f3b4)]},'children':[{'text':_0x23ff6c['to']('isNavigationMode',_0x469dd4=>_0x469dd4?R(_0x8b3865,'EDIT_X_OF_Y_REVISIONS')+':\x20':R(_0x8b3865,'Total')+':\x20')}]},{'text':_0x23ff6c['to']('_statusText')}]},new _0x3bddfb(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x1bd733,_0x21805d]}]});}}const ge='ck-editor__editable__loading-overlay';class bi extends _0x1eb7a5{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x4e467e=this['editor']['editing']['view'];_0x4e467e['change'](_0x361115=>{for(const _0x4f9995 of _0x4e467e['document']['roots'])_0x361115['addClass'](ge,_0x4f9995);});}['hide'](){const _0x13cd6e=this['editor']['editing']['view'];_0x13cd6e['change'](_0x5219d5=>{for(const _0xb7de9f of _0x13cd6e['document']['roots'])_0x5219d5['removeClass'](ge,_0xb7de9f);});}}class u extends _0x1eb7a5{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l,bi];}['init'](){const _0xe38db1=this['editor'],_0x33566b=_0xe38db1['plugins']['get'](l),_0x12faa9=_0xe38db1['plugins']['get'](bi);_0xe38db1['ui']['componentFactory']['add']('exitToEditing',_0x1467f0=>{const _0x4ab519=new _0x21b928(_0x1467f0);return _0x4ab519['set']({'label':R(_0x1467f0,'Back\x20to\x20editing'),'icon':_0x11cea3,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x4ab519,'execute',()=>{_0xe38db1['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x4ab519;}),_0xe38db1['ui']['componentFactory']['add']('restoreRevision',_0x2cf8cd=>{const _0x42e4b3=new _0x21b928(_0x2cf8cd);return _0x42e4b3['set']({'label':R(_0x2cf8cd,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x42e4b3['bind']('isEnabled')['to'](_0xe38db1['commands']['get']('restoreRevision')),this['listenTo'](_0x42e4b3,'execute',()=>_0xe38db1['execute']('restoreRevision')),_0x42e4b3;}),_0xe38db1['ui']['componentFactory']['add']('changesNavigation',_0x4c595a=>{const _0x2b637a=new fi(_0x4c595a),_0x2a6d97=_0xe38db1['commands']['get']('showPreviousChange'),_0x980574=_0xe38db1['commands']['get']('showNextChange');return _0x2b637a['bind']('isBackwardNavigationEnabled')['to'](_0x2a6d97,'isEnabled'),_0x2b637a['bind']('isForwardNavigationEnabled')['to'](_0x980574,'isEnabled'),_0x2b637a['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x33566b),this['listenTo'](_0x2b637a,'execute',(_0x1ddcfa,_0x171782)=>{_0xe38db1['execute']('forward'===_0x171782?'showNextChange':'showPreviousChange');}),_0x2b637a;}),_0x12faa9['show'](),_0x33566b['on']('change:isReady',(_0x3cd0f2,_0x255911,_0x20d516)=>{_0x20d516?_0x12faa9['hide']():_0x12faa9['show']();});}}class hi extends et{['_resizeObserver']=null;constructor(_0x144786,_0x58dfda){super(_0x144786,_0x58dfda);const _0x15ea8a=this['bindTemplate'];this['set']({'label':R(_0x144786,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=R(_0x144786,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x15ea8a['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 _0x309488=this['fieldView']['element'];this['_tooltipString']=_0x309488['scrollWidth']>_0x309488['clientWidth']&&_0x309488['value']||'';}}class ni extends _0x3f2314{constructor(_0x557e85,_0x337f27,_0x1273f0){super(_0x557e85);const _0x1a72c7=new _0x21a133();_0x1a72c7['set']({'content':_0x1269d6,'viewBox':'0\x200\x2011\x2010'});const _0x53b8ca=['ck','ck-revision-history-sidebar__revision-author'];_0x1273f0&&_0x53b8ca['push']('ck-revision-history-sidebar__revision-author_creator');const _0x5cf079=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':R(_0x557e85,_0x1273f0?'Revision\x20creator':'Revision\x20author')},'children':[_0x1a72c7,_0x337f27['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x53b8ca},'children':_0x5cf079});}}function ci(_0x99c6b9,_0x442652){const _0x11c077=_0x99c6b9['bindTemplate'],_0x575ea9=_0x99c6b9['locale'],_0x4f25ca=_0x5be730(_0x575ea9);_0x4f25ca['panelPosition']='sw';const _0x101761=function(_0x13fb91,_0x2c3565){const _0xdef052=function(_0x5a3842,_0x4d4991){const _0x25f758=_0x5a3842['locale'],_0x46c224={'Compare\x20against\x20selected':R(_0x25f758,'Compare\x20against\x20selected'),'Name\x20this\x20revision':R(_0x25f758,'Name\x20this\x20revision'),'Restore\x20this\x20revision':R(_0x25f758,'Restore\x20this\x20revision')};return _0x4d4991['map'](_0x2ddc07=>{const _0x368d9e=_0x46c224[_0x2ddc07['name']];return _0x368d9e&&_0x368d9e!==_0x2ddc07['name']&&(_0x2ddc07['name']=_0x368d9e),_0x2ddc07;});}(_0x13fb91,_0x2c3565),_0x575f7e=new _0xb0d30e();for(const _0xed5339 of _0xdef052){const _0x46141e={'type':'button','model':new to({'label':_0xed5339['name'],'class':_0xed5339['class'],'withText':!0x0,'role':'menuitem','_action':_0xed5339['action']})};_0x46141e['model']['bind']('isEnabled')['to'](_0x13fb91,'isActionsDropdownOpen',_0x3430db=>'function'!=typeof _0xed5339['isEnabled']||(!_0x3430db||_0xed5339['isEnabled'](_0x13fb91))),_0x575f7e['add'](_0x46141e);}return _0x575f7e;}(_0x99c6b9,_0x442652);return _0x99c6b9['bind']('isActionsDropdownOpen')['to'](_0x4f25ca,'isOpen'),_0x4f25ca['buttonView']['set']({'label':R(_0x575ea9,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0xff9fef}),_0x4f25ca['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x11c077['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x11c077['to'](_0x82bff5=>_0x82bff5['stopPropagation']())}}),_0x4f25ca['on']('execute',_0x1a2c37=>{_0x99c6b9['isReady']&&'function'==typeof _0x1a2c37['source']['_action']&&_0x1a2c37['source']['_action'](_0x99c6b9);}),_0x525fe6(_0x4f25ca,_0x101761,{'role':'menu'}),_0x4f25ca['listenTo'](_0x99c6b9,'change:isActionsDropdownOpen',(_0x1deafc,_0x5cbabe,_0x1ee8ac)=>{if(_0x1ee8ac)for(const _0x2ea3d0 of _0x4f25ca['listView']['items']){const _0x278488=_0x2ea3d0['children']['first'],_0x4b1509=_0x442652['find'](_0x291112=>_0x291112['action']===_0x278488['_action'])['isVisible'];_0x2ea3d0['isVisible']=void 0x0===_0x4b1509||_0x4b1509(_0x99c6b9);}}),_0x4f25ca;}class _i extends/* #__PURE__ -- @preserve */
|
|
27
|
+
_0x257fd9(_0x3f2314){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x281ac9,_0x3c17e5,_0x419676,_0x7df079){super(_0x281ac9);const _0x6341b1=this['bindTemplate'],_0x5f201a=function(_0x5da0ba,_0x48037e){const _0x6c9bad=Array['from'](_0x48037e['authors'])['filter'](_0x398a0f=>_0x398a0f!=_0x48037e['creator']);return _0x48037e['creator']&&_0x6c9bad['unshift'](_0x48037e['creator']),_0x6c9bad['map'](_0x103736=>new ni(_0x5da0ba,_0x103736,_0x103736==_0x48037e['creator']));}(_0x281ac9,_0x3c17e5);this['id']=_0x3c17e5['id'],this['_revision']=_0x3c17e5,this['_requireRevisionName']=_0x7df079,this['bind']('name','createdAt')['to'](_0x3c17e5),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x1493f3=>{return _0x5a45fc=_0x281ac9['uiLanguage'],(_0xf286a8=_0x1493f3)['toLocaleDateString'](_0x5a45fc,{'month':'long','day':'numeric'})+',\x20'+_0xf286a8['toLocaleTimeString'](_0x5a45fc,{'hour':'numeric','minute':'numeric'});var _0x5a45fc,_0xf286a8;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new hi(_0x281ac9,ti),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x412126=>_0x412126||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x80068b,_0x4c2ebb)=>_0x80068b&&_0x4c2ebb),this['revisionActionsView']=_0x419676&&_0x419676['length']?ci(this,_0x419676):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x6341b1['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x6341b1['if']('isEnabled','ck-disabled',_0xd6290e=>!_0xd6290e),_0x6341b1['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x6341b1['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x6341b1['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':_0x6341b1['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':_0x5f201a}]},this['revisionActionsView']],'on':{'click':_0x6341b1['to'](_0x4ae952=>{_0x4ae952['srcElement']['closest']('.ck-thread__remove-confirm')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x5bcd4e=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x5bcd4e,'change',()=>{this['_requireRevisionName']&&!_0x5bcd4e['value']||this['fire']('setName',{'id':this['id'],'name':_0x5bcd4e['value']}),_0x5bcd4e['value']||(_0x5bcd4e['value']=this['name']?this['name']:this['_createdAtFormatted']);});}['select'](){this['isSelected']=!0x0;}['deselect'](){this['isSelected']=!0x1;}['highlight'](){this['isHighlighted']=!0x0;}['unhighlight'](){this['isHighlighted']=!0x1;}}function ki(_0x3db440,_0x390f10){const _0x4c1cdc=_0x2abda7['fromJSDate'](_0x3db440)['setLocale'](_0x390f10),_0x123354=_0x2abda7['local'](),_0xf41196=_0x123354['minus']({'days':0x1})['startOf']('day');let _0x3573f5,_0x46ed8d;return _0x4c1cdc['hasSame'](_0x123354,'day')?(_0x3573f5=_0x4c1cdc['startOf']('day')['toJSDate'](),_0x46ed8d=_0x4c1cdc['toRelativeCalendar']()):_0x4c1cdc['hasSame'](_0xf41196,'day')?(_0x3573f5=_0xf41196['toJSDate'](),_0x46ed8d=_0x4c1cdc['toRelativeCalendar']()):_0x4c1cdc['hasSame'](_0x123354,'week')?(_0x3573f5=_0x4c1cdc['startOf']('week')['toJSDate'](),_0x46ed8d=_0x4c1cdc['weekdayLong']||''):_0x4c1cdc['hasSame'](_0x123354,'year')?(_0x3573f5=_0x4c1cdc['startOf']('month')['toJSDate'](),_0x46ed8d=_0x4c1cdc['monthLong']||''):(_0x3573f5=_0x4c1cdc['startOf']('year')['toJSDate'](),_0x46ed8d=String(_0x4c1cdc['year'])),{'startDate':_0x3573f5,'localizedPeriodName':_0x46ed8d};}class ji extends _0x3f2314{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x37921a,_0x1bb7b4,_0x3c1a73,_0x2a5f84){super(_0x37921a);const _0x24d5fc=ki(_0x1bb7b4,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x1bb7b4,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x3c1a73,this['_requireRevisionName']=_0x2a5f84,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':_0x24d5fc}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x357d26){const _0x512b33=new _i(this['locale'],_0x357d26,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x512b33);}['removeRevision'](_0x71a8fe){const _0x222324=this['revisionViews']['find'](_0x2ad7aa=>_0x2ad7aa['id']===_0x71a8fe['id']);this['revisionViews']['remove'](_0x222324);}}class Ni extends _0x3f2314{constructor(_0x2499d5){super(_0x2499d5);const _0x2853e6=new _0x21a133();_0x2853e6['content']=_0x368a30,this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x2853e6,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[R(_0x2499d5,'Revision\x20history')]}]});}}class Ri extends _0x3f2314{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x1adb2d,_0x3992e6,_0x116755,_0x26eb6f){super(_0x1adb2d);const _0x5e1f54=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x3992e6,this['_revisionActions']=_0x116755,this['_requireRevisionName']=_0x26eb6f,this['on']('select',(_0x424959,_0x50912d)=>{this['fire']('revisionSelected',_0x50912d);}),this['on']('setName',(_0x3512e4,_0x39fa5c)=>{this['fire']('revisionSetName',_0x39fa5c);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new Ni(_0x1adb2d),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x5e1f54['if']('isEnabled','ck-disabled',_0x5b4227=>!_0x5b4227)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x2db25a of this['_revisions'])this['_addRevision'](_0x2db25a);this['_revisions']['on']('add',(_0x267afd,_0x3fc133)=>{this['_addRevision'](_0x3fc133);}),this['_revisions']['on']('remove',(_0x3f7fd2,_0xf97827)=>{this['_removeRevision'](_0xf97827);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x50fb0e=>_0x50fb0e['revisionViews']['map'](_0xfd5495=>_0xfd5495))['flat']();}['selectRevision'](_0x3729bf){for(const _0x141bbb of this['revisionViews'])_0x3729bf&&_0x3729bf['id']===_0x141bbb['id']?_0x141bbb['select']():_0x141bbb['deselect']();}['highlightRevisions'](_0xf4b7){for(const _0x4fbf59 of this['revisionViews'])_0xf4b7['some'](({id:_0x2e1d74})=>_0x2e1d74===_0x4fbf59['id'])?_0x4fbf59['highlight']():_0x4fbf59['unhighlight']();}['_addRevision'](_0x4ee9fc){const _0x27d1fa=ki(_0x4ee9fc['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x1e8102=this['timePeriodViews']['get'](0x0);_0x1e8102&&_0x1e8102['startDate']['getTime']()===_0x27d1fa['getTime']()||(_0x1e8102=new ji(this['locale'],_0x27d1fa,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x1e8102)),_0x1e8102['addRevision'](_0x4ee9fc);}['_removeRevision'](_0x46b4be){const _0x3d4553=ki(_0x46b4be['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x3d4553)['removeRevision'](_0x46b4be);}['_getTimePeriodViewByStartDate'](_0x5aad65){return this['timePeriodViews']['find'](_0xb637ce=>_0xb637ce['startDate']['getTime']()===_0x5aad65['getTime']());}}class f extends _0x1eb7a5{['_revisionViewer'];['_revisionsRepository'];['_sidebarView'];static ['defaultRevisionActions']=/* #__PURE__ -- @preserve */
|
|
28
28
|
((()=>['compareAgainstSelected','restoreRevision','nameRevision'])());static ['availableRevisionActions']=/* #__PURE__ -- @preserve */
|
|
29
|
-
at();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l];}constructor(
|
|
30
|
-
_0x367870(_0x6012b0){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x5f48f7,_0x483230){super(_0x483230),this['sourceElement']=_0x5f48f7,this['model']['document']['createRoot']();const _0x35f7e1=new ii(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new Z(this,_0x35f7e1);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x2f349f,_0x2201ad){const _0x185c4b=new this(_0x2f349f,_0x2201ad);return await _0x185c4b['initPlugins'](),await _0x185c4b['ui']['init'](_0x2f349f),await _0x185c4b['data']['init'](_0x185c4b['config']['get']('initialData')||''),_0x185c4b['fire']('ready'),_0x185c4b;}}const d=['RevisionHistoryUI','RestrictedEditingMode'];class ht extends _0x235b76{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x2ca2a3){function _0x1b6f48(_0x539893){return _0x539893['map'](_0x2c4516=>String['fromCharCode'](_0x2c4516))['join']('');}super(_0x2ca2a3),this['result']='end',_0x2ca2a3[_0x1b6f48([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x1b6f48([0x76,0x69,0x65,0x77])][_0x1b6f48([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x1b6f48([0x61,0x75,0x74,0x6f]),_0x2ca2a3[_0x1b6f48([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x1b6f48([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x1b6f48([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x1b6f48([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x1b6f48([0x6f,0x6b])});}}class ct extends _0x235b76{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h,v];}constructor(_0x23b9ba){if(super(_0x23b9ba),!this['editor']['config']['get']('revisionHistory'))throw new _0x9a71df('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x2c6e75=>this['_showRevisionViewer']({..._0x2c6e75,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0xe6966=>this['_closeRevisionViewer'](_0xe6966)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x5231cd=>this['_restoreRevision'](_0x5231cd)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x2a3f68){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x2a3f68;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x3441fb){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x3441fb);}['getRevision'](_0x2a57bc){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x2a57bc);}['getRevisions'](_0x181d83){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x181d83||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x331b28=this['editor'],_0x23c4a9=_0x55b787(_0x331b28,d),_0x2db52b=_0x331b28['plugins']['get']('RevisionTracker'),_0x37125a=_0x331b28['plugins']['get']('Users')['users'];return _0x23c4a9['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x23c4a9['lazyRoots'],(_0x23c4a9['plugins']['push'](ht,l,u,class extends _0x235b76{static get['requires'](){return[l,'Users'];}['init'](){const _0x46db6b=this['editor']['plugins']['get']('Users');for(const _0x24161d of _0x37125a)_0x24161d['isAnonymous']||_0x46db6b['getUser'](_0x24161d['id'])||_0x46db6b['addUser'](_0x24161d);const _0x242ce1=_0x2db52b['repository']['getRevisions']();let _0x556510=null;const _0x19768b=this['editor']['plugins']['get']('RevisionViewer');_0x19768b['adapter']=_0x2db52b['adapter'],_0x19768b['bind']('isEnabled')['to'](_0x2db52b),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x331b28,'isReadOnly',_0x85755b=>!_0x85755b);for(const _0x5e62f7 of _0x242ce1){const _0x2dea68=null===_0x5e62f7['creator'];if(_0x2dea68&&_0x5e62f7['toVersion']===_0x5e62f7['fromVersion'])continue;const _0x3b67ec=_0x5e62f7['toJSON']();_0x19768b['addRevisionData'](_0x3b67ec,(_0xd3aee7,_0x138799,_0x5c956b)=>{if(_0x2dea68){if(_0x556510)_0x556510['_update'](_0xd3aee7,_0x138799);else{if(!_0x138799){const _0x350168=_0x5c956b['toJSON']();_0x350168['id']=_0x1b5d50(),_0x2db52b['saveRevision'](_0x350168,_0x5c956b['toVersion'])['then'](_0x3f06cc=>{_0x556510=_0x3f06cc;});}}}else _0x5e62f7['_update'](_0xd3aee7,_0x138799);});}}},f),_0x23c4a9);}['_enhanceShowRevisionViewerCallback'](){const _0xcbdf4d=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x48939d=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x4092c3=this['editor']['plugins']['get']('Autosave');await _0x4092c3['save']();}else await _0x48939d['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x1341ef=this['editor']['plugins']['get']('Dialog');_0x1341ef['isOpen']&&_0x1341ef['hide']();}const _0x1540f2=this['_getRevisionViewerEditorConfig']();return _0xcbdf4d(_0x1540f2)['then'](_0x5c15e4=>{return(this['_viewerEditor']=_0x5c15e4,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'),_0x5c15e4);})['catch'](_0x376878=>(console['error'](_0x376878),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x543528=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'](),_0x543528(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x5be6bf=this['editor']['plugins']['get']('Annotations');_0x5be6bf['refreshVisibility'](),_0x5be6bf['refreshPositioning']();}})));}['_showRevisionViewer'](_0xd01c8d){const _0x422cf8=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x3f5725=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x1412ac=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return m['create'](_0x1412ac,_0xd01c8d)['then'](_0x288e9c=>(_0x3f5725['style']['display']='block',_0x422cf8['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x288e9c));}['_closeRevisionViewer'](_0x2ce119){const _0x38bcf8=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x38bcf8['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x2ce119['destroy']();}async['_restoreRevision'](_0x443f49){const _0x57a3a5=this['editor'],_0x5c3ed0=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x5fee0d=_0x57a3a5['plugins']['get']('RevisionTracker'),_0x108ae0=_0x57a3a5['plugins']['get']('RevisionHistoryUtils'),_0xd30fbf=_0x5c3ed0['repository']['getRevision'](_0x443f49);let _0x5b0b1e,_0x487fe,_0x35998a;try{await _0x108ae0['loadRevisionData'](_0xd30fbf,this['adapter']),_0x5b0b1e=_0x108ae0['getRevisionDocumentData'](_0xd30fbf),_0x487fe=_0x108ae0['getRevisionRootsAttributes'](_0xd30fbf);}catch(_0x5a6e7f){return void console['error'](_0x5a6e7f);}_0x57a3a5['model']['change'](_0x224574=>{for(const _0x9a9fb6 of Array['from'](_0x57a3a5['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x224574['removeMarker'](_0x9a9fb6);}),_0x5c3ed0['isReady']=!0x1,_0x57a3a5['model']['enqueueChange'](_0x161240=>{_0x161240['setSelection'](null),_0x161240['removeSelectionAttribute'](_0x57a3a5['model']['document']['selection']['getAttributeKeys']());const _0x4e0e23=Object['keys'](_0x5b0b1e);for(const _0x5b94ee of _0x57a3a5['model']['document']['roots'])'$graveyard'!=_0x5b94ee['rootName']&&_0x5b94ee['isAttached']()&&!_0x4e0e23['includes'](_0x5b94ee['rootName'])&&_0x161240['detachRoot'](_0x5b94ee);for(const _0x58086c of _0x4e0e23){let _0x451453=_0x57a3a5['model']['document']['getRoot'](_0x58086c);_0x451453&&_0x451453['isAttached']()||(_0x451453=_0x161240['addRoot'](_0x58086c));const _0x1f3b94=_0x487fe[_0x58086c],_0x4df1dd=Object['keys'](_0x1f3b94),_0x489976=_0x5b0b1e[_0x58086c];for(const _0x37392e of _0x451453['getAttributeKeys']())_0x4df1dd['includes'](_0x37392e)||_0x161240['removeAttribute'](_0x37392e,_0x451453);for(const _0x5ef570 of _0x4df1dd)_0x161240['setAttribute'](_0x5ef570,_0x487fe[_0x58086c][_0x5ef570],_0x451453);_0x161240['remove'](_0x161240['createRangeIn'](_0x451453)),_0x161240['insert'](_0x57a3a5['data']['parse'](_0x489976,_0x451453),_0x451453,0x0);}});const _0x4888a5=R(_0x57a3a5['locale'],'Restored');if(_0xd30fbf['name'])_0x35998a=-0x1==_0xd30fbf['name']['indexOf'](_0x4888a5)?_0x4888a5+':\x20'+_0xd30fbf['name']:_0xd30fbf['name'];else _0x35998a=_0x4888a5+':\x20'+(_0xd30fbf['createdAt']['toLocaleDateString'](_0x57a3a5['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0xd30fbf['createdAt']['toLocaleTimeString'](_0x57a3a5['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x5fee0d['saveRevision']({'name':_0x35998a}),_0x5c3ed0['isReady']=!0x0,_0x57a3a5['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,ji as RevisionViewerLoadingOverlay,u as RevisionViewerUI,S as RevisionsRepository,f as RevisionsSidebar,rt as ShowChangeCommand};
|
|
29
|
+
at();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l];}constructor(_0x5f5465){super(_0x5f5465),this['_revisionViewer']=_0x5f5465['plugins']['get'](l),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x38190d=this['_revisionsRepository']['_revisions'],_0x37cb02=this['_createRevisionActions'](),_0x6e5a8c=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new Ri(this['editor']['locale'],_0x38190d,_0x37cb02,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',(_0x462ae9,_0xa1c169)=>{_0xa1c169['revisionViews']['on']('add',(_0x5ec658,_0xc562c2)=>{_0xc562c2['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)),_0x6e5a8c['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x3f8792=this['_revisionsRepository']['getRevision'](0x0);if(_0x3f8792){const _0x22f382=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x3f8792['id']);this['_revisionViewer']['compare'](_0x3f8792,_0x22f382);}}['_handleRevisionSelected'](_0x4adeba,_0x45c82a){const _0x55c979=this['_revisionsRepository']['getRevision'](_0x45c82a['id']),_0x4eb071=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x55c979['id']);this['_revisionViewer']['compare'](_0x55c979,_0x4eb071);}['_handleRevisionSetName'](_0x512173,_0x1472d7){this['_revisionsRepository']['getRevision'](_0x1472d7['id'])['setName'](_0x1472d7['name']);}['_handleDiffChange'](_0x1b955a,_0x926878,_0xa231f8){const _0x27091b=this['_revisionsRepository']['getRevisionsInDiff'](_0xa231f8);_0x27091b['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x27091b),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x27091b[0x0]));}['_createRevisionActions'](){const _0xef3b1c=this['editor'],_0x20e4aa=f['availableRevisionActions'],_0x4733ae=_0xef3b1c['config']['get']('revisionHistory.revisionActions')||f['defaultRevisionActions'];if(_0x4733ae['length'])return _0x4733ae['map'](_0x124e48=>{const _0x54d32a='string'==typeof _0x124e48?Object['assign']({},_0x20e4aa[_0x124e48]):_0x124e48;return _0x54d32a['action']=_0x54d32a['action']['bind'](this,_0xef3b1c),_0x54d32a['isVisible']&&(_0x54d32a['isVisible']=_0x54d32a['isVisible']['bind'](this,_0xef3b1c)),_0x54d32a;});}}function at(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x7d672b},_0x1795a7)=>{const _0x48d861=_0x7d672b['get'](l),_0x27de95=_0x48d861['repository'];let _0x3ace1c=_0x48d861['diff']['newRevisionId'],_0x24d50a=_0x1795a7['id'];_0x27de95['getIndex'](_0x3ace1c)>_0x27de95['getIndex'](_0x24d50a)&&([_0x3ace1c,_0x24d50a]=[_0x24d50a,_0x3ace1c]),_0x48d861['compare'](_0x3ace1c,_0x24d50a);},'isVisible':({plugins:_0x4c2840},_0x2e0c92)=>{const _0x3047ca=_0x4c2840['get'](l);return!(_0x3047ca['repository']['getRevisionsInDiff'](_0x3047ca['diff'])['length']>0x2)&&!_0x2e0c92['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x3113b6,{id:_0x58d9f5})=>{_0x3113b6['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x58d9f5);},'isVisible':({plugins:_0x2451db},_0x57d9fe)=>!!_0x2451db['get'](l)['repository']['getLaterVisibleRevision'](_0x57d9fe['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x2cebe6},{id:_0x1f05e1,revisionNameView:_0x407f35})=>{const _0x40fb4c=_0x2cebe6['get'](l),_0x10c120=_0x40fb4c['repository']['getEarlierVisibleRevision'](_0x1f05e1);_0x40fb4c['compare'](_0x1f05e1,_0x10c120),_0x407f35['focus'](),_0x407f35['fieldView']['select']();}}};}class Z extends tt{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x4732cb,_0x3e8990){super(_0x4732cb),this['_view']=_0x3e8990,this['_toolbarConfig']=st(_0x4732cb['config']['get']('toolbar')),this['_elementReplacer']=new it();}get['element'](){return this['view']['element'];}['init'](_0x30806e){const _0x4db355=this['editor'],_0x5f11f6=this['view'],_0x418f70=_0x4db355['editing']['view'],_0x34815f=_0x5f11f6['editable'],_0x2803df=_0x418f70['document']['getRoot']();_0x34815f['name']=_0x2803df['rootName'],_0x5f11f6['render']();const _0x1da3b0=_0x34815f['element'];this['setEditableElement'](_0x34815f['name'],_0x1da3b0),_0x5f11f6['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x418f70['attachDomRoot'](_0x1da3b0),this['_elementReplacer']['replace'](_0x30806e,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x159fd1=this['view'],_0x6275ea=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x6275ea['detachDomRoot'](_0x159fd1['editable']['name']),_0x159fd1['destroy']();}['_initToolbar'](){const _0x1547c9=this['view'];_0x1547c9['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x1547c9['stickyPanel']['limiterElement']=_0x1547c9['element'],_0x1547c9['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0xe1eaf5})=>_0xe1eaf5),_0x1547c9['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x1547c9['toolbar']);}}class ii extends _0x4aec7b{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x4ce14b,_0x22ffbc,_0x4d5cf7={}){super(_0x4ce14b),this['stickyPanel']=new _0x440a34(_0x4ce14b),this['toolbar']=new _0x994f94(_0x4ce14b,{'shouldGroupWhenFull':_0x4d5cf7['shouldToolbarGroupWhenFull']}),this['_editable']=new te(_0x4ce14b,_0x22ffbc);}['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
|
+
_0x27d20d(_0x546a66){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x52de37,_0x508044){super(_0x508044),this['sourceElement']=_0x52de37,this['model']['document']['createRoot']();const _0x402592=new ii(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new Z(this,_0x402592);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x3df4ee,_0x131808){const _0x10ebce=new this(_0x3df4ee,_0x131808);return await _0x10ebce['initPlugins'](),await _0x10ebce['ui']['init'](_0x3df4ee),await _0x10ebce['data']['init'](_0x10ebce['config']['get']('initialData')||''),_0x10ebce['fire']('ready'),_0x10ebce;}}const d=['RevisionHistoryUI','RestrictedEditingMode'];class ht extends _0x1eb7a5{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x26f31f){function _0x2a31df(_0x436354){return _0x436354['map'](_0x53988f=>String['fromCharCode'](_0x53988f))['join']('');}super(_0x26f31f),this['result']='end',_0x26f31f[_0x2a31df([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x2a31df([0x76,0x69,0x65,0x77])][_0x2a31df([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x2a31df([0x61,0x75,0x74,0x6f]),_0x26f31f[_0x2a31df([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x2a31df([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x2a31df([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x2a31df([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x2a31df([0x6f,0x6b])});}}class ct extends _0x1eb7a5{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h,v];}constructor(_0x5c225e){if(super(_0x5c225e),!this['editor']['config']['get']('revisionHistory'))throw new _0x1959ba('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x3fbc03=>this['_showRevisionViewer']({..._0x3fbc03,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x3da21f=>this['_closeRevisionViewer'](_0x3da21f)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x4dfb95=>this['_restoreRevision'](_0x4dfb95)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x2a018a){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x2a018a;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x3cb0d6){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x3cb0d6);}['getRevision'](_0x1af981){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x1af981);}['getRevisions'](_0x4b2626){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x4b2626||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x27f9f3=this['editor'],_0x34b0f8=_0x30bb80(_0x27f9f3,d),_0x14d221=_0x27f9f3['plugins']['get']('RevisionTracker'),_0x40ae3b=_0x27f9f3['plugins']['get']('Users')['users'];return _0x34b0f8['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x34b0f8['lazyRoots'],(_0x34b0f8['plugins']['push'](ht,l,u,class extends _0x1eb7a5{static get['requires'](){return[l,'Users'];}['init'](){const _0x3918d7=this['editor']['plugins']['get']('Users');for(const _0x11eb00 of _0x40ae3b)_0x11eb00['isAnonymous']||_0x3918d7['getUser'](_0x11eb00['id'])||_0x3918d7['addUser'](_0x11eb00);const _0x59f0a8=_0x14d221['repository']['getRevisions']();let _0x5db5ad=null;const _0x3daaae=this['editor']['plugins']['get']('RevisionViewer');_0x3daaae['adapter']=_0x14d221['adapter'],_0x3daaae['bind']('isEnabled')['to'](_0x14d221),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x27f9f3,'isReadOnly',_0x546619=>!_0x546619);for(const _0x27a721 of _0x59f0a8){const _0x59b3c3=null===_0x27a721['creator'];if(_0x59b3c3&&_0x27a721['toVersion']===_0x27a721['fromVersion'])continue;const _0x2a82c2=_0x27a721['toJSON']();_0x3daaae['addRevisionData'](_0x2a82c2,(_0x57a8b5,_0x39b25a,_0x44eba3)=>{if(_0x59b3c3){if(_0x5db5ad)_0x5db5ad['_update'](_0x57a8b5,_0x39b25a);else{if(!_0x39b25a){const _0x1a0473=_0x44eba3['toJSON']();_0x1a0473['id']=_0xe8fa3b(),_0x14d221['saveRevision'](_0x1a0473,_0x44eba3['toVersion'])['then'](_0x2c0c3c=>{_0x5db5ad=_0x2c0c3c;});}}}else _0x27a721['_update'](_0x57a8b5,_0x39b25a);});}}},f),_0x34b0f8);}['_enhanceShowRevisionViewerCallback'](){const _0xc9aba=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x360213=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x402d6d=this['editor']['plugins']['get']('Autosave');await _0x402d6d['save']();}else await _0x360213['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x5dcb15=this['editor']['plugins']['get']('Dialog');_0x5dcb15['isOpen']&&_0x5dcb15['hide']();}const _0x182e9d=this['_getRevisionViewerEditorConfig']();return _0xc9aba(_0x182e9d)['then'](_0xb968c2=>{return(this['_viewerEditor']=_0xb968c2,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'),_0xb968c2);})['catch'](_0x480b00=>(console['error'](_0x480b00),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x159727=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'](),_0x159727(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x1a784c=this['editor']['plugins']['get']('Annotations');_0x1a784c['refreshVisibility'](),_0x1a784c['refreshPositioning']();}})));}['_showRevisionViewer'](_0x477d28){const _0x469f48=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x15676c=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x5f3c5b=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return m['create'](_0x5f3c5b,_0x477d28)['then'](_0x2ebf79=>(_0x15676c['style']['display']='block',_0x469f48['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x2ebf79));}['_closeRevisionViewer'](_0x1ddcd6){const _0x4f8b1e=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x4f8b1e['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x1ddcd6['destroy']();}async['_restoreRevision'](_0xdd1de8){const _0x71e947=this['editor'],_0x45c4fd=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x25b42a=_0x71e947['plugins']['get']('RevisionTracker'),_0x240c77=_0x71e947['plugins']['get']('RevisionHistoryUtils'),_0x2c02b1=_0x45c4fd['repository']['getRevision'](_0xdd1de8);let _0x471293,_0x2d28d0,_0x59bbf9;try{await _0x240c77['loadRevisionData'](_0x2c02b1,this['adapter']),_0x471293=_0x240c77['getRevisionDocumentData'](_0x2c02b1),_0x2d28d0=_0x240c77['getRevisionRootsAttributes'](_0x2c02b1);}catch(_0x204eab){return void console['error'](_0x204eab);}_0x71e947['model']['change'](_0x2386d3=>{for(const _0x1375cf of Array['from'](_0x71e947['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x2386d3['removeMarker'](_0x1375cf);}),_0x45c4fd['isReady']=!0x1,_0x71e947['model']['enqueueChange'](_0x514396=>{_0x514396['setSelection'](null),_0x514396['removeSelectionAttribute'](_0x71e947['model']['document']['selection']['getAttributeKeys']());const _0x1fd1dd=Object['keys'](_0x471293);for(const _0x3da42e of _0x71e947['model']['document']['roots'])'$graveyard'!=_0x3da42e['rootName']&&_0x3da42e['isAttached']()&&!_0x1fd1dd['includes'](_0x3da42e['rootName'])&&_0x514396['detachRoot'](_0x3da42e);for(const _0x5cdd31 of _0x1fd1dd){let _0x173021=_0x71e947['model']['document']['getRoot'](_0x5cdd31);_0x173021&&_0x173021['isAttached']()||(_0x173021=_0x514396['addRoot'](_0x5cdd31));const _0x5c31ba=_0x2d28d0[_0x5cdd31],_0x1f286b=Object['keys'](_0x5c31ba),_0x26a5a9=_0x471293[_0x5cdd31];for(const _0x2b36b2 of _0x173021['getAttributeKeys']())_0x1f286b['includes'](_0x2b36b2)||_0x514396['removeAttribute'](_0x2b36b2,_0x173021);for(const _0x131d7a of _0x1f286b)_0x514396['setAttribute'](_0x131d7a,_0x2d28d0[_0x5cdd31][_0x131d7a],_0x173021);_0x514396['remove'](_0x514396['createRangeIn'](_0x173021)),_0x514396['insert'](_0x71e947['data']['parse'](_0x26a5a9,_0x173021),_0x173021,0x0);}});const _0xe5e845=R(_0x71e947['locale'],'Restored');if(_0x2c02b1['name'])_0x59bbf9=-0x1==_0x2c02b1['name']['indexOf'](_0xe5e845)?_0xe5e845+':\x20'+_0x2c02b1['name']:_0x2c02b1['name'];else _0x59bbf9=_0xe5e845+':\x20'+(_0x2c02b1['createdAt']['toLocaleDateString'](_0x71e947['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x2c02b1['createdAt']['toLocaleTimeString'](_0x71e947['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x25b42a['saveRevision']({'name':_0x59bbf9}),_0x45c4fd['isReady']=!0x0,_0x71e947['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{nt as RestoreRevisionCommand,I as Revision,ct as RevisionHistory,v as RevisionHistoryUI,$ as RevisionHistoryUtils,h as RevisionTracker,l as RevisionViewer,m as RevisionViewerEditor,ht as RevisionViewerIntegration,bi as RevisionViewerLoadingOverlay,u as RevisionViewerUI,S as RevisionsRepository,f as RevisionsSidebar,rt as ShowChangeCommand};
|