@ckeditor/ckeditor5-revision-history 46.0.0-alpha.3 → 46.0.0-alpha.5
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.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
|
-
_0x235c38(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x21ff7b){super(),this['id']=_0x21ff7b['id']||_0x1a737e(),this['creator']=_0x21ff7b['creator']||null,this['authors']=_0x21ff7b['authors']||[],this['diffData']=_0x21ff7b['diffData']||null,this['toVersion']=_0x21ff7b['toVersion']||0x0,this['fromVersion']=_0x21ff7b['fromVersion']||0x0,this['set']('name',_0x21ff7b['name']||''),this['set']('createdAt',_0x21ff7b['createdAt']||new Date()),this['set']('attributes',_0x21ff7b['attributes']||{});}['setName'](_0x29cb35){this['_update']({'name':_0x29cb35});}['setAttribute'](_0xe778ee,_0xff89a1){const _0x157afc=_0x2b75d6(this['attributes']);_0x535535(_0x157afc,_0xe778ee,_0xff89a1),this['_update']({'attributes':_0x157afc});}['removeAttribute'](_0x66099d){const _0x56c204=_0x2b75d6(this['attributes']);_0x5acadb(_0x56c204,_0x66099d),this['_update']({'attributes':_0x56c204});}['_update'](_0x3d46f9,_0x595d97=!0x1){let _0x733e9f=!0x1;const _0x3a293a={'id':this['id']},_0x4e3c2c=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x7209f9 of _0x4e3c2c){const _0x102289=_0x3d46f9[_0x7209f9];void 0x0!==_0x102289&&_0x102289!==this[_0x7209f9]&&(this[_0x7209f9]=_0x102289,_0x3a293a[_0x7209f9]=_0x102289,_0x733e9f=!0x0);}_0x733e9f&&(_0x3a293a['authors']&&(_0x3a293a['authorsIds']=_0x3a293a['authors']['map'](_0x58ff4d=>_0x58ff4d['id']),delete _0x3a293a['authors']),this['fire']('_update',_0x3a293a,_0x595d97));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x53e04b=>_0x53e04b['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class S extends _0x858dc7{['_revisions'];static get['requires'](){return[_0x267b04];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x1c924c){super(_0x1c924c),this['_revisions']=new _0x1d5790();}['afterInit'](){!async function(_0x59eb22){const _0xeae7e1=_0x341d79([0x77,0x59,0x49,0x31,0x4f,0x76,0x30,0x64,0x44,0x63,0x79,0x7a,0x35,0x75,0x78,0x47,0x67,0x72,0x6f,0x38,0x54,0x32,0x6e,0x56,0x69,0x62,0x53,0x6b,0x39,0x61,0x73,0x66,0x46,0x33,0x58,0x74,0x50,0x4e,0x70,0x41,0x4b,0x45,0x4a,0x57,0x55,0x34,0x65,0x48,0x4d,0x52,0x6c,0x4c,0x43,0x68,0x51,0x6d,0x42,0x5a,0x6a,0x36,0x37,0x71]),_0x541196=0xeb829,_0x29f5ef=0x17ac1d91,_0x1ad27c=0x17ab7109^_0x29f5ef,_0x2bc370=window[_0x341d79([0x44,0x61,0x74,0x65])][_0x341d79([0x6e,0x6f,0x77])](),_0x46dad6=_0x59eb22[_0x341d79([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x5bc737=new window[(_0x341d79([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x1d9ecf=>{_0x46dad6[_0x341d79([0x6f,0x6e,0x63,0x65])](_0x341d79([0x72,0x65,0x61,0x64,0x79]),_0x1d9ecf);}),_0x5357a7={[_0x341d79([0x6b,0x74,0x79])]:_0x341d79([0x45,0x43]),[_0x341d79([0x75,0x73,0x65])]:_0x341d79([0x73,0x69,0x67]),[_0x341d79([0x63,0x72,0x76])]:_0x341d79([0x50,0x2d,0x32,0x35,0x36]),[_0x341d79([0x78])]:_0x341d79([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]),[_0x341d79([0x79])]:_0x341d79([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]),[_0x341d79([0x61,0x6c,0x67])]:_0x341d79([0x45,0x53,0x32,0x35,0x36])},_0x5d41b8=_0x46dad6[_0x341d79([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x341d79([0x67,0x65,0x74])](_0x341d79([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x4a38e2(){let _0x5a9896,_0x511a64=null,_0x3fd4e5=null;try{if(_0x5d41b8==_0x341d79([0x47,0x50,0x4c]))return _0x341d79([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x5a9896=_0x44f768(),!_0x5a9896)return _0x341d79([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x5a9896[_0x341d79([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x3fd4e5=_0x2ef1f7(_0x5a9896[_0x341d79([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x5a9896[_0x341d79([0x6a,0x74,0x69])])),await _0x3920c5()?_0x4ece00()?_0x3b82a8()?_0x341d79([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x260b97()?(_0x5a9896[_0x341d79([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x341d79([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x511a64=_0x5c5596(_0x341d79([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x5a9896[_0x341d79([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x341d79([0x74,0x72,0x69,0x61,0x6c])&&(_0x511a64=_0x5c5596(_0x341d79([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x52ca06()):_0x341d79([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x341d79([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x341d79([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x341d79([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x3b82a8(){const _0x1f49bf=[_0x341d79([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x341d79([0x74,0x72,0x69,0x61,0x6c])][_0x341d79([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x5a9896[_0x341d79([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x2bc370/0x3e8:0xe10*_0x1ad27c;return _0x5a9896[_0x341d79([0x65,0x78,0x70])]<_0x1f49bf;}function _0x4ece00(){const _0x13d2ce=_0x5a9896[_0x341d79([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x13d2ce)return!0x1;if(_0x13d2ce[_0x341d79([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x341d79([0x2a])))return!0x0;if(_0x13d2ce[_0x341d79([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x341d79([0x52,0x48])))return!0x0;if(_0x13d2ce[_0x341d79([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x341d79([0x52,0x52,0x48]))){if(_0x33d63e())return!0x0;if(_0x5acd5c()||_0x3a35eb())return!0x0;}return!0x1;}function _0x260b97(){const _0x135c2a=_0x5a9896[_0x341d79([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x135c2a||0x0==_0x135c2a[_0x341d79([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x1e327c}=new URL(window[_0x341d79([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x135c2a[_0x341d79([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x1e327c))return!0x0;const _0x3fa9b2=_0x1e327c[_0x341d79([0x73,0x70,0x6c,0x69,0x74])](_0x341d79([0x2e]));return _0x135c2a[_0x341d79([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x53fc1b=>_0x53fc1b[_0x341d79([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x341d79([0x2a])))[_0x341d79([0x6d,0x61,0x70])](_0x227ffc=>_0x227ffc[_0x341d79([0x73,0x70,0x6c,0x69,0x74])](_0x341d79([0x2e])))[_0x341d79([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x30fd69=>_0x30fd69[_0x341d79([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x3fa9b2[_0x341d79([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x341d79([0x6d,0x61,0x70])](_0x58cdec=>Array(_0x3fa9b2[_0x341d79([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0x58cdec[_0x341d79([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x341d79([0x66,0x69,0x6c,0x6c])](_0x58cdec[0x0]===_0x341d79([0x2a])?_0x341d79([0x2a]):'')[_0x341d79([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0x58cdec))[_0x341d79([0x73,0x6f,0x6d,0x65])](_0xeeac24=>_0x3fa9b2[_0x341d79([0x65,0x76,0x65,0x72,0x79])]((_0x494849,_0x594704)=>_0xeeac24[_0x594704]===_0x494849||_0xeeac24[_0x594704]===_0x341d79([0x2a])));}function _0x52ca06(){return _0x511a64&&_0x3fd4e5?new window[(_0x341d79([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x282400,_0x5ba1d9)=>{_0x511a64[_0x341d79([0x74,0x68,0x65,0x6e])](_0x282400,_0x5ba1d9),_0x3fd4e5[_0x341d79([0x74,0x68,0x65,0x6e])](_0x10722b=>{_0x10722b!=_0x341d79([0x56,0x61,0x6c,0x69,0x64])&&_0x282400(_0x10722b);},_0x5ba1d9);}):_0x511a64||_0x3fd4e5||_0x341d79([0x56,0x61,0x6c,0x69,0x64]);}}function _0x2ef1f7(_0x50eb84,_0x3749bb){return new window[(_0x341d79([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x4befbe=>{if(_0x584089())return _0x4befbe(_0x341d79([0x56,0x61,0x6c,0x69,0x64]));_0x36a1ee(),_0x46dad6[_0x341d79([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x341d79([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x4499a2=!0x1;const _0x402950=_0x1a737e();function _0xd06e12(_0x82d928){return!!_0x82d928&&(typeof _0x82d928===_0x341d79([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x82d928===_0x341d79([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x82d928[_0x341d79([0x74,0x68,0x65,0x6e])]===_0x341d79([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x82d928[_0x341d79([0x63,0x61,0x74,0x63,0x68])]===_0x341d79([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x4e48e2(_0x18ed7c){_0x73fc8a(_0x18ed7c)[_0x341d79([0x74,0x68,0x65,0x6e])](_0x17db14=>{if(!_0x17db14||_0x17db14[_0x341d79([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x341d79([0x6f,0x6b]))return _0x341d79([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x244a66(_0x3808a3(_0x402950+_0x3749bb))!=_0x17db14[_0x341d79([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x341d79([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x341d79([0x56,0x61,0x6c,0x69,0x64]);})[_0x341d79([0x74,0x68,0x65,0x6e])](_0xa9ff00=>(_0x48f461(),_0xa9ff00),()=>{const _0x5b833e=_0xed9653();return null==_0x5b833e?(_0x48f461(),_0x341d79([0x56,0x61,0x6c,0x69,0x64])):_0x341d79(_0x2bc370-_0x5b833e>(0x33a09991^_0x29f5ef)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x341d79([0x74,0x68,0x65,0x6e])](_0x4befbe)[_0x341d79([0x63,0x61,0x74,0x63,0x68])](()=>{_0x4befbe(_0x341d79([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x39f30e=0x179af311^_0x29f5ef;function _0x48f461(){const _0x2fa6bb=_0x341d79([0x6c,0x6c,0x63,0x74,0x2d])+_0x244a66(_0x3808a3(_0x50eb84)),_0xfa6c9=_0x122909(_0x244a66(window[_0x341d79([0x4d,0x61,0x74,0x68])][_0x341d79([0x63,0x65,0x69,0x6c])](_0x2bc370/_0x39f30e)));window[_0x341d79([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x341d79([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x2fa6bb,_0xfa6c9);}function _0xed9653(){const _0x4e7c74=_0x341d79([0x6c,0x6c,0x63,0x74,0x2d])+_0x244a66(_0x3808a3(_0x50eb84)),_0x5ef687=window[_0x341d79([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x341d79([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x4e7c74);return _0x5ef687?window[_0x341d79([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x122909(_0x5ef687),0x10)*_0x39f30e:null;}function _0x73fc8a(_0x3d9958){return new window[(_0x341d79([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x2aedb2,_0x2efe7d)=>{_0x3d9958[_0x341d79([0x74,0x68,0x65,0x6e])](_0x2aedb2,_0x2efe7d),window[_0x341d79([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x2efe7d,0x17adc951^_0x29f5ef);});}}_0x46dad6[_0x341d79([0x6f,0x6e])](_0x341d79([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x20a323,_0x321677)=>{if(_0x321677[0x0]!=_0x50eb84)return _0x4befbe(_0x341d79([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x321677[0x1]={..._0x321677[0x1],[_0x341d79([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x402950};},{[_0x341d79([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x341d79([0x68,0x69,0x67,0x68])}),_0x46dad6[_0x341d79([0x6f,0x6e])](_0x341d79([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x13667e=>{_0xd06e12(_0x13667e[_0x341d79([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x4499a2=!0x0,_0x4e48e2(_0x13667e[_0x341d79([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x341d79([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x341d79([0x6c,0x6f,0x77])}),_0x5bc737[_0x341d79([0x74,0x68,0x65,0x6e])](()=>{_0x4499a2||_0x4befbe(_0x341d79([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x584089(){return _0x46dad6[_0x341d79([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x341d79([0x76,0x69,0x65,0x77])][_0x341d79([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x341d79([0x61,0x75,0x74,0x6f]);}function _0x36a1ee(){_0x46dad6[_0x341d79([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x341d79([0x76,0x69,0x65,0x77])][_0x341d79([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x341d79([0x61,0x75,0x74,0x6f]);}}function _0x5c5596(_0x5aa3f5){const _0x3754c4=[new window[(_0x341d79([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x322235=>setTimeout(_0x322235,0x17a5235d^_0x29f5ef)),_0x5bc737[_0x341d79([0x74,0x68,0x65,0x6e])](()=>new window[(_0x341d79([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2792ed=>{const _0x16c3b1=0x17ac1d96^_0x29f5ef,_0x788e3b=_0x59eb22[_0x341d79([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x13d8fd(){_0x788e3b[_0x341d79([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x16c3b1&&_0x2792ed();}_0x13d8fd(),_0x788e3b[_0x341d79([0x6f,0x6e])](_0x341d79([0x61,0x64,0x64]),_0x13d8fd);})),new window[(_0x341d79([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x58eac9=>{function _0x151549(){for(const _0x969732 in window)if(window[_0x341d79([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x341d79([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x969732))&&window[_0x969732]==_0x541196)return _0x58eac9();_0x46dad6[_0x341d79([0x73,0x74,0x61,0x74,0x65])]!=_0x341d79([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x341d79([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x151549,0x17ac0e19^_0x29f5ef);}_0x5b3c99(_0x341d79([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x151549();})];return window[_0x341d79([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x341d79([0x72,0x61,0x63,0x65])](_0x3754c4)[_0x341d79([0x74,0x68,0x65,0x6e])](()=>_0x5aa3f5);}async function _0x344b77(){if(await _0x5bc737,_0x5b3c99(_0x341d79([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x1597c2=_0x59eb22[_0x341d79([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x3ba3cf=_0x59eb22[_0x341d79([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])](_0x1597c2[_0x341d79([0x69,0x64])]),_0x4432fc=_0x5198b4(_0x341d79([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x4432fc[_0x341d79([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x1597c2['id'],_0x3ba3cf?_0x3ba3cf['id']:null,!0x0),_0x4432fc[_0x341d79([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x341d79([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x4432fc[_0x341d79([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x4432fc[_0x341d79([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x3c694d,void(_0x4432fc[_0x341d79([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x3c694d);}if(_0x5b3c99(_0x341d79([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x16c8c8=_0x5198b4(_0x341d79([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x16c8c8[_0x341d79([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x341d79([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x16c8c8[_0x341d79([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x16c8c8[_0x341d79([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x3c694d,_0x16c8c8[_0x341d79([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x3c694d;}_0x46dad6[_0x341d79([0x6d,0x6f,0x64,0x65,0x6c])][_0x341d79([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x3c694d,_0x46dad6[_0x341d79([0x6d,0x6f,0x64,0x65,0x6c])][_0x341d79([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x3c694d,_0x46dad6[_0x341d79([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x341d79([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x33d63e(){return _0x5b3c99(_0x341d79([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x5198b4(_0x341d79([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x341d79([0x73,0x74,0x61,0x74,0x65])]==_0x341d79([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x5acd5c(){return _0x5b3c99(_0x341d79([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 _0x3a35eb(){return _0x5b3c99(_0x341d79([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0xfc57d8(_0x32a115){const _0x52599b=_0x4db93b();_0x46dad6[_0x52599b]=_0x341d79([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])+_0x32a115,_0x32a115[_0x341d79([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x341d79([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x4db93b()]=_0x541196),_0x32a115!=_0x341d79([0x56,0x61,0x6c,0x69,0x64])&&_0x344b77();}function _0x4db93b(){const _0x1d9e2c=window[_0x341d79([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x341d79([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x341d79([0x6e,0x6f,0x77])]())[_0x341d79([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x341d79([0x2e]),'');let _0x3162f5=_0x341d79([0x77]);for(let _0x3386cd=0x0;_0x3386cd<_0x1d9e2c[_0x341d79([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x3386cd+=0x2){let _0x583231=window[_0x341d79([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x1d9e2c[_0x341d79([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x3386cd,_0x3386cd+0x2));_0x583231>=_0xeae7e1[_0x341d79([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x583231-=_0xeae7e1[_0x341d79([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x3162f5+=_0xeae7e1[_0x583231];}return _0x3162f5;}function _0x44f768(){const _0x466a2d=_0x5d41b8[_0x341d79([0x73,0x70,0x6c,0x69,0x74])](_0x341d79([0x2e]));if(0x3!=_0x466a2d[_0x341d79([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x49dc02(_0x466a2d[0x1]);function _0x49dc02(_0x3827bb){const _0x1c8492=_0x4ecacc(_0x3827bb);return _0x1c8492&&_0x33bca5()?_0x1c8492:null;function _0x33bca5(){const _0x171430=_0x1c8492[_0x341d79([0x6a,0x74,0x69])],_0x1ae583=window[_0x341d79([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x171430[_0x341d79([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x171430[_0x341d79([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x2ab758={..._0x1c8492,[_0x341d79([0x6a,0x74,0x69])]:_0x171430[_0x341d79([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x171430[_0x341d79([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x2ab758[_0x341d79([0x76,0x63])],_0x3808a3(_0x2ab758)==_0x1ae583;}}}async function _0x3920c5(){let _0xc818e8=!0x0;try{const _0x49c236=_0x5d41b8[_0x341d79([0x73,0x70,0x6c,0x69,0x74])](_0x341d79([0x2e])),[_0x891145,_0x139611,_0x191483]=_0x49c236;return _0x345d2d(_0x891145),await _0x5a6ec0(_0x891145,_0x139611,_0x191483),_0xc818e8;}catch{return!0x1;}function _0x345d2d(_0x5e4e0c){const _0x2761c9=_0x4ecacc(_0x5e4e0c);_0x2761c9&&_0x2761c9[_0x341d79([0x61,0x6c,0x67])]==_0x341d79([0x45,0x53,0x32,0x35,0x36])||(_0xc818e8=!0x1);}async function _0x5a6ec0(_0x32b597,_0x5a836d,_0x67561c){const _0x411877=window[_0x341d79([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x341d79([0x66,0x72,0x6f,0x6d])](_0x19d21d(_0x67561c),_0x3e2cdb=>_0x3e2cdb[_0x341d79([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x4eed8a=new window[(_0x341d79([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x341d79([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x32b597+_0x341d79([0x2e])+_0x5a836d),_0x32544d=window[_0x341d79([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x341d79([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x32544d)return;const _0x54e373=await _0x32544d[_0x341d79([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x341d79([0x6a,0x77,0x6b]),_0x5357a7,{[_0x341d79([0x6e,0x61,0x6d,0x65])]:_0x341d79([0x45,0x43,0x44,0x53,0x41]),[_0x341d79([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x341d79([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x341d79([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x32544d[_0x341d79([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x341d79([0x6e,0x61,0x6d,0x65])]:_0x341d79([0x45,0x43,0x44,0x53,0x41]),[_0x341d79([0x68,0x61,0x73,0x68])]:{[_0x341d79([0x6e,0x61,0x6d,0x65])]:_0x341d79([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x54e373,_0x411877,_0x4eed8a)||(_0xc818e8=!0x1);}}function _0x4ecacc(_0x5798c8){return _0x5798c8[_0x341d79([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x341d79([0x65,0x79]))?JSON[_0x341d79([0x70,0x61,0x72,0x73,0x65])](_0x19d21d(_0x5798c8)):null;}function _0x19d21d(_0x59670b){return window[_0x341d79([0x61,0x74,0x6f,0x62])](_0x59670b[_0x341d79([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x341d79([0x2b]))[_0x341d79([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x341d79([0x2f])));}function _0x3808a3(_0x22bc46){let _0x16796f=0x1505;function _0x429385(_0x32b86c){for(let _0x511848=0x0;_0x511848<_0x32b86c[_0x341d79([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x511848++){const _0x25a1e1=_0x32b86c[_0x341d79([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x511848);_0x16796f=(_0x16796f<<0x5)+_0x16796f+_0x25a1e1,_0x16796f&=_0x16796f;}}function _0x50a746(_0x197ec2){Array[_0x341d79([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x197ec2)?_0x197ec2[_0x341d79([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x50a746):_0x197ec2&&typeof _0x197ec2==_0x341d79([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x341d79([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x197ec2)[_0x341d79([0x73,0x6f,0x72,0x74])]()[_0x341d79([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x275c40,_0x53808c])=>{_0x429385(_0x275c40),_0x50a746(_0x53808c);}):_0x429385(window[_0x341d79([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x197ec2));}return _0x50a746(_0x22bc46),_0x16796f>>>0x0;}function _0x244a66(_0x51087c){return _0x51087c[_0x341d79([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x341d79([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x341d79([0x30]));}function _0x122909(_0x296dcd){return _0x296dcd[_0x341d79([0x73,0x70,0x6c,0x69,0x74])]('')[_0x341d79([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x341d79([0x6a,0x6f,0x69,0x6e])]('');}function _0x5b3c99(_0x489f0c){return _0x46dad6[_0x341d79([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x341d79([0x68,0x61,0x73])](_0x489f0c);}function _0x5198b4(_0x13ab0d){return _0x46dad6[_0x341d79([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x341d79([0x67,0x65,0x74])](_0x13ab0d);}function _0x3c694d(){}function _0x341d79(_0x277028){return _0x277028['map'](_0xc9b955=>String['fromCharCode'](_0xc9b955))['join']('');}_0xfc57d8(await _0x4a38e2());}(this);}['createRevision'](_0x1b8659){const _0x1d1b95=this['editor']['plugins']['get']('Users');return new I({'id':_0x1b8659['id'],'name':_0x1b8659['name'],'creator':_0x1b8659['creatorId']?_0x1d1b95['getUser'](_0x1b8659['creatorId']):null,'diffData':_0x1b8659['diffData']||_0x1b8659['data'],'authors':_0x1b8659['authorsIds']['map'](_0x1af0e1=>_0x1d1b95['getUser'](_0x1af0e1)),'createdAt':new Date(_0x1b8659['createdAt']),'attributes':_0x1b8659['attributes'],'fromVersion':_0x1b8659['fromVersion'],'toVersion':_0x1b8659['toVersion']});}['addRevision'](_0x1ab0c5,_0x32bff0=0x0){this['_revisions']['add'](_0x1ab0c5,_0x32bff0);}['getRevision'](_0x32abf5){return this['_revisions']['get'](_0x32abf5);}['getRevisions'](_0x3625d0={'toJSON':!0x1}){const _0x31d2c9=Array['from'](this['_revisions']);return _0x31d2c9['reverse'](),_0x3625d0['toJSON']?_0x31d2c9['map'](_0x5f4c13=>_0x5f4c13['toJSON']()):_0x31d2c9;}['getIndex'](_0x5ca825){return this['_revisions']['getIndex'](_0x5ca825);}['getEarlierVisibleRevision'](_0x11d82a){const [,_0x4aabeb]=this['getRevisionsIterator'](_0x11d82a,{'direction':'earlier'});return _0x4aabeb;}['getLaterVisibleRevision'](_0x106c81){const [,_0x592771]=this['getRevisionsIterator'](_0x106c81,{'direction':'later'});return _0x592771;}['getRevisionsInDiff'](_0x3b2c81){const _0x43b1d4=[];for(const _0x448bc7 of this['getRevisionsIterator'](_0x3b2c81['newRevisionId']))if(_0x43b1d4['push'](_0x448bc7),_0x448bc7['id']===_0x3b2c81['oldRevisionId'])break;return _0x43b1d4;}*['getRevisionsIterator'](_0xbf369e,{direction:_0x4ee8d7='earlier',filter:_0x22a6ea=()=>!0x0}={}){const _0x3e4991='earlier'===_0x4ee8d7?0x1:-0x1;let _0xb53081=this['_revisions']['get'](_0xbf369e),_0x25d33f=this['getIndex'](_0xb53081);for(yield _0xb53081;_0xb53081;){if(_0x25d33f+=_0x3e4991,_0xb53081=this['getRevision'](_0x25d33f),!_0xb53081)return;_0x22a6ea(_0xb53081)&&(yield _0xb53081);}}}class $ extends _0x858dc7{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x414402,'c'],[_0x3473b1,'a'],[_0x13c3fa,'e'],[_0x5f3d85,'r'],[_0x2b5473,'u']]);['_typeCharToViewClass']=new Map([['c',_0x414402],['a',_0x3473b1],['e',_0x13c3fa],['r',_0x5f3d85],['u',_0x2b5473]]);async['loadRevisionData'](_0x186f9f,_0x5da053){if(_0x186f9f['diffData']||!_0x5da053)return;const _0x2f9dfc=this['editor']['config']['get']('collaboration.channelId'),_0x3cb54d=await _0x5da053['getRevision']({'channelId':_0x2f9dfc,'revisionId':_0x186f9f['id']});_0x186f9f['diffData']=_0x3cb54d['diffData'];}['getRevisionDocumentData'](_0x2fa1d9){const _0x1c82a9={};for(const _0x454e2f in _0x2fa1d9['diffData']){if(_0x2fa1d9['diffData'][_0x454e2f]['attachChange']&&!_0x2fa1d9['diffData'][_0x454e2f]['attachChange']['isAttached'])continue;const _0x331ea7=this['_removeRevisionMarkers'](JSON['parse'](_0x2fa1d9['diffData'][_0x454e2f]['insertions'])),_0x14a071=this['editor']['editing']['view']['document'],_0x4229af=new _0x26445f(_0x14a071,_0x331ea7['map'](_0x3a4299=>this['_getViewFromDiffObj'](_0x3a4299,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x1c82a9[_0x454e2f]=this['editor']['data']['processor']['toData'](_0x4229af),this['editor']['data']['processor']['useFillerType']('default');}return _0x1c82a9;}['getRevisionRootsAttributes'](_0x89d54c){const _0x2de059={};for(const _0x3cfd75 in _0x89d54c['diffData'])_0x89d54c['diffData'][_0x3cfd75]['attachChange']&&!_0x89d54c['diffData'][_0x3cfd75]['attachChange']['isAttached']||(_0x2de059[_0x3cfd75]=_0x89d54c['diffData'][_0x3cfd75]['attributesAfter']||{});return _0x2de059;}['_getTypeCharForViewElement'](_0x61bfb6){return this['_viewClassToTypeChar']['get'](_0x61bfb6['constructor']);}['_getViewFromDiffObj'](_0x2bbcc4,_0x42e88b){const _0x7d4353=this['editor']['editing']['view']['document'];if('string'==typeof _0x2bbcc4)return new _0x140a00(_0x7d4353,_0x2bbcc4);{let _0x45a6a,_0x20c2fd;_0x20c2fd='u'==_0x2bbcc4['type']||'r'==_0x2bbcc4['type']?[]:_0x2bbcc4['children']['map'](_0x4df111=>this['_getViewFromDiffObj'](_0x4df111,_0x42e88b));const _0x4c68c0=this['_typeCharToViewClass']['get'](_0x2bbcc4['type'])||_0x5be4ed,_0xe86d9e=this['editor']['data']['htmlProcessor']['domConverter'];if(_0x45a6a=new _0x4c68c0(_0x7d4353,_0x2bbcc4['name'],_0x2bbcc4['attributes'],_0x20c2fd),'u'==_0x2bbcc4['type']&&_0x2bbcc4['children'][0x0]){const _0x3846df=_0x2bbcc4['children'][0x0];if(_0x45a6a['render']=function(_0x287ba0){const _0x2014aa=_0x287ba0['createElement']('div');return _0x2014aa['innerHTML']=_0x3846df,_0x2014aa['childNodes'][0x0];},_0x42e88b){const _0x55dae7=new _0x26445f(_0x7d4353);_0x55dae7['_appendChild'](_0x45a6a);const _0x509047=Array['from'](_0xe86d9e['viewChildrenToDom'](_0x55dae7,{'bind':!0x1})),_0xaddbf7=_0xe86d9e['domDocument']['createElement']('div');_0xaddbf7['append'](..._0x509047),_0x45a6a=Array['from'](_0xe86d9e['domChildrenToView'](_0xaddbf7))[0x0];}}else{if('r'==_0x2bbcc4['type']&&_0x2bbcc4['children'][0x0]){const _0x24e8f1=_0x2bbcc4['children'][0x0];if(_0x45a6a['render']=function(_0xa1af72){_0xa1af72['innerHTML']=_0x24e8f1;},_0x42e88b){const _0x5b0679=new _0x26445f(_0x7d4353);_0x5b0679['_appendChild'](_0x45a6a);const _0x5b11e0=Array['from'](_0xe86d9e['viewChildrenToDom'](_0x5b0679,{'bind':!0x1})),_0x11a742=_0xe86d9e['domDocument']['createElement']('div');_0x11a742['append'](..._0x5b11e0);const _0x658ac7=Array['from'](_0xe86d9e['domChildrenToView'](_0x11a742));_0x658ac7['length']>0x1?_0x45a6a['_appendChild'](_0x658ac7):_0x45a6a=_0x658ac7[0x0];}}}if(_0x2bbcc4['customProperties']){for(const [_0xe7d4d3,_0x2a349e]of _0x2bbcc4['customProperties'])_0x45a6a['_setCustomProperty'](_0xe7d4d3,_0x2a349e);}const _0xaf797d=void 0x0===_0x2bbcc4['fillerOffset']?null:_0x2bbcc4['fillerOffset'];return null!==_0xaf797d&&(_0x45a6a['getFillerOffset']=()=>_0xaf797d),_0x45a6a;}}['_makeModelFromViewString'](_0x477b09){const _0x37bdd9=JSON['parse'](_0x477b09),_0x2fcc91=this['editor']['editing']['view']['document'],_0x3e220b=new _0x26445f(_0x2fcc91,_0x37bdd9['map'](_0x469f19=>this['_getViewFromDiffObj'](_0x469f19,!0x0)));return this['editor']['data']['toModel'](_0x3e220b);}['_removeRevisionMarkers'](_0x2bad7c){return(_0x2bad7c=_0x2bad7c['filter'](_0x358fd4=>!_0x358fd4['name']||'revision-start'!==_0x358fd4['name']&&'revision-end'!==_0x358fd4['name']))['forEach'](_0x2ba0e0=>{'string'!=typeof _0x2ba0e0&&(_0x2ba0e0['children']=this['_removeRevisionMarkers'](_0x2ba0e0['children']),_0x2ba0e0['attributes']=_0x2ba0e0['attributes']['filter'](_0x5b977a=>!_0x5b977a[0x0]['startsWith']('data-revision-')));}),_0x2bad7c;}}function R(_0xda7e40,_0x56744d,_0x457c82){const t=_0xda7e40['t'];switch(_0x56744d){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'},_0x457c82);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x457c82);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 _0x858dc7{['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[_0x267b04,S,$,_0x3530c7];}constructor(_0x55c47d){super(_0x55c47d),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 _0x5e3190=_0x1a737e();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x5e3190},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 _0x32d646=this['repository']['getRevision'](0x0),_0x6ce38a=_0x32d646&&null===_0x32d646['creator']?_0x32d646:null;if(this['_continueCurrentRevision']=!!_0x6ce38a&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x29e77a=this['_source']['getCurrentRevisionId'](),_0x7db48d=this['repository']['getRevision'](_0x29e77a);if(_0x7db48d)this['_startingVersion']=_0x7db48d['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x2db9ea=this['_source']['history']['_operations']['find'](_0x4e7283=>!_0x4e7283['_isInit']),_0x28fc93=_0x2db9ea?_0x2db9ea['baseVersion']:this['_source']['history']['version'];_0x32d646?(_0x32d646['toVersion']<_0x28fc93&&_0x32d646['_update']({'toVersion':_0x28fc93}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x6ce38a['id'],this['_startingVersion']=_0x6ce38a['fromVersion']):(this['_startingVersion']=_0x32d646['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x28fc93,this['_continueCurrentRevision']=!0x1);}}else _0x6ce38a&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x6ce38a['toVersion'],this['editor']['model']['document']['history']['version']),_0x6ce38a['fromVersion']===_0x6ce38a['toVersion']?(0x0!==_0x6ce38a['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x6ce38a['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x6ce38a['id'],this['_startingVersion']=_0x6ce38a['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',_0xaf7c5=>!_0xaf7c5),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0xd73325=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x235baa;for(const _0x15a48f in _0xd73325){const _0x54bbd1=_0x15a48f,_0x38b4df=_0xd73325[_0x54bbd1];if('revisionHistoryLicenseKeyValid'==_0x38b4df||'revisionHistoryLicenseKeyInvalid'==_0x38b4df||'revisionHistoryLicenseKeyExpired'==_0x38b4df||'revisionHistoryLicenseKeyDomainLimit'==_0x38b4df||'revisionHistoryLicenseKeyNotAllowed'==_0x38b4df||'revisionHistoryLicenseKeyEvaluationLimit'==_0x38b4df||'revisionHistoryLicenseKeyTrialLimit'==_0x38b4df||'revisionHistoryLicenseKeyUsageLimit'==_0x38b4df){delete _0xd73325[_0x54bbd1],_0x235baa=_0x38b4df,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x235baa&&_0xd73325['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x235baa&&_0xd73325['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x235baa&&_0xd73325['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x235baa&&_0xd73325['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x235baa&&_0xd73325['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x235baa&&_0xd73325['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x235baa&&_0xd73325['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x3eb2d=this['repository']['getRevision'](0x0),_0x418249=await this['getRevisionDocumentData'](_0x3eb2d),_0x4fc0c1=await this['getRevisionRootsAttributes'](_0x3eb2d);this['_replaceEditorDataWithRevisionData'](_0x418249,_0x4fc0c1);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x5a4783){this['_source']=_0x5a4783;}async['update'](){const _0x1c905d=await this['_source']['getLatestVersion']();if(_0x1c905d>this['currentRevision']['toVersion']){await this['_loadState']();const _0x53448b=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x1c905d});_0x53448b['authors']=_0x53448b['authorsIds']['map'](_0x4f8c2b=>this['editor']['plugins']['get']('Users')['getUser'](_0x4f8c2b)),this['currentRevision']['_update'](_0x53448b);}}async['saveRevision'](_0x2144c0={},_0x3b8e58=null){const _0x1fab14=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x3b8e58>this['currentRevision']['toVersion']&&(_0x3b8e58=null),null===_0x3b8e58&&(_0x3b8e58=await this['_source']['getLatestVersion']());const _0xdea15c=this['_getFromVersion'](_0x3b8e58),_0x5497dd=this['buildRevisionData']({'from':_0xdea15c,'to':_0x3b8e58});if(this['currentRevision']['toVersion']<_0x3b8e58){const _0x2303ae=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x3b8e58,'to':_0x3b8e58});_0x2303ae['authors']=[],_0x2303ae['authorsIds']=[],_0x2303ae['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x2303ae,!0x0),delete _0x2303ae['authors'],_0x1fab14['push'](_0x2303ae);}_0x2144c0['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x2144c0['name']=_0x2144c0['name']||null,_0x2144c0['id']=_0x2144c0['id']||_0x1a737e(),_0x2144c0={..._0x2144c0,..._0x5497dd};const _0x5b80a8=this['addRevisionData'](_0x2144c0);_0x1fab14['push'](_0x2144c0);const _0x24476=this['repository']['getIndex'](_0x5b80a8);if(0x0!==_0x24476){const _0x4927b0=this['repository']['getRevision'](_0x24476-0x1);if(_0x4927b0['fromVersion']!==_0x3b8e58){const _0x415b3f=this['_revisionDataBuilder']['getData'](_0x3b8e58,_0x4927b0['toVersion']),_0x58fb2b={'id':_0x4927b0['id'],'diffData':_0x415b3f['diffData'],'authorsIds':_0x415b3f['authorsIds'],'authors':_0x415b3f['authorsIds']['map'](_0x7bdf6a=>this['editor']['plugins']['get']('Users')['getUser'](_0x7bdf6a)),'fromVersion':_0x3b8e58};_0x4927b0===this['currentRevision']&&(_0x58fb2b['createdAt']=new Date(_0x2144c0['createdAt']['getTime']()+0xa)),_0x4927b0['_update'](_0x58fb2b,!0x0),delete _0x58fb2b['authors'],_0x1fab14['push'](_0x58fb2b);}}if(this['adapter']){for(const _0x70596d of _0x1fab14)this['_bufferUpdate'](_0x70596d['id'],_0x70596d,!0x0);this['sendBufferedUpdates']();}return _0x5b80a8;}['addRevisionData'](_0x378bb9){const _0x5c278d=this['repository']['createRevision'](_0x378bb9);return this['adapter']&&_0x5c278d['on']('_update',(_0x54d60f,_0x3e6e9b,_0x4ef37f)=>{_0x4ef37f||(this['_bufferUpdate'](_0x3e6e9b['id'],_0x3e6e9b,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x5c278d,this['_findInsertionIndex'](_0x5c278d)),_0x5c278d;}async['getRevisionDocumentData'](_0x53553c){return await this['_utils']['loadRevisionData'](_0x53553c,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x53553c);}async['getRevisionRootsAttributes'](_0x1198e5){return await this['_utils']['loadRevisionData'](_0x1198e5,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x1198e5);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x24c166=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x2a8c3b=0x0;_0x2a8c3b<_0x24c166['length'];_0x2a8c3b++){const _0x2ba1e4=_0x24c166[_0x2a8c3b];let _0x4eea05=!0x1;for(const _0x312278 of Object['keys'](_0x2ba1e4))void 0x0===_0x2ba1e4[_0x312278]?delete _0x2ba1e4[_0x312278]:'id'!==_0x312278&&(_0x4eea05=!0x0);_0x4eea05||(_0x24c166[_0x2a8c3b]=null);}if(_0x24c166=_0x24c166['filter'](_0x2ace73=>null!==_0x2ace73),!_0x24c166['length'])return;for(let _0xa3f0c6=0x0;_0xa3f0c6<_0x24c166['length'];_0xa3f0c6++){const _0x7eb603=_0x24c166[_0xa3f0c6];void 0x0!==_0x7eb603['fromVersion']&&void 0x0===_0x7eb603['toVersion']&&(_0x7eb603['toVersion']=this['repository']['getRevision'](_0x7eb603['id'])['toVersion']),void 0x0!==_0x7eb603['toVersion']&&void 0x0===_0x7eb603['fromVersion']&&(_0x7eb603['fromVersion']=this['repository']['getRevision'](_0x7eb603['id'])['fromVersion']);}const _0x18c383=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x24c166,_0x18c383)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x5d8e31=>{if(_0x5d8e31){for(const _0x56f427 of _0x5d8e31)this['setRevisionData']({'id':_0x56f427['id'],'createdAt':_0x56f427['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0x29aafd=null,from:_0x47ead8=null,to:_0x3ffca5=null}){_0x47ead8=null!==_0x47ead8?_0x47ead8:_0x29aafd['fromVersion'],_0x3ffca5=null!==_0x3ffca5?_0x3ffca5:_0x29aafd['toVersion'];const _0x2f7778=this['_revisionDataBuilder']['getData'](_0x47ead8,_0x3ffca5),_0x32b912={'diffData':_0x2f7778['diffData'],'authorsIds':_0x2f7778['authorsIds'],'fromVersion':_0x47ead8,'toVersion':_0x3ffca5};if(!_0x29aafd||_0x3ffca5!==_0x29aafd['toVersion']){const _0x21c25c=_0x3ffca5-0x1,_0x5b916e=this['_source']['history']['getOperation'](_0x21c25c);_0x32b912['createdAt']=_0x5b916e&&_0x5b916e['createdAt']||new Date();}if(this['_loadedStateData']&&_0x47ead8===this['_loadedStateData']['fromVersion']){for(const _0x32c1e1 of this['_loadedStateData']['authors'])_0x32b912['authorsIds']['includes'](_0x32c1e1['id'])||_0x32b912['authorsIds']['push'](_0x32c1e1['id']);}return _0x32b912;}['_bufferUpdate'](_0x3e2286,_0x238a24,_0x27b09b){if(this['_bufferedUpdates']['has'](_0x3e2286)){const _0x5a72f4=this['_bufferedUpdates']['get'](_0x3e2286);_0x238a24=_0x27b09b?{..._0x5a72f4,..._0x238a24}:{..._0x238a24,..._0x5a72f4};}this['_bufferedUpdates']['set'](_0x3e2286,_0x238a24);}['setRevisionData'](_0x1c1e14){const _0x4fe628=this['repository']['getRevision'](_0x1c1e14['id']);if(_0x1c1e14['createdAt']&&(_0x1c1e14['createdAt']=new Date(_0x1c1e14['createdAt'])),_0x1c1e14['authorsIds']){const _0x43d8f9=this['editor']['plugins']['get']('Users');_0x1c1e14['authors']=_0x1c1e14['authorsIds']['map'](_0x3d8c9f=>_0x43d8f9['getUser'](_0x3d8c9f));}_0x4fe628['_update'](_0x1c1e14,!0x0);}['_createInitialRevision'](_0x3d1ee7){const _0x547045=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x547045)this['_initialRevisionId']=_0x547045['id'];else{const _0x5bee62=!this['editor']['model']['document']['roots']['find'](_0x34fed5=>this['editor']['model']['hasContent'](_0x34fed5)),_0x51cd27=this['editor']['plugins']['get']('Users')['me']['id'],_0x40c313=R(this['editor']['locale'],_0x5bee62?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x3d1ee7,'to':_0x3d1ee7,'id':this['_initialRevisionId'],'name':_0x40c313,'creatorId':_0x51cd27});}}['_createCurrentRevision'](_0x312984){const _0x5ad1a2=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x5ad1a2),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x312984,'to':_0x312984,'id':_0x5ad1a2,'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'](_0x473e98,_0x266476){let _0x4928c2=this['editor']['config']['get']('initialData'),_0x32f036=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x4928c2){_0x4928c2={};for(const _0x3653b8 of this['editor']['model']['document']['getRootNames']())_0x4928c2[_0x3653b8]='';}if('string'==typeof _0x4928c2&&(_0x4928c2={'main':_0x4928c2}),void 0x0===_0x32f036){_0x32f036={};for(const _0x356425 of this['editor']['model']['document']['getRootNames']())_0x32f036[_0x356425]={};}let _0x59ac4b=!0x1;const _0x524013=Object['keys'](_0x4928c2),_0x3ab86a=Object['keys'](_0x473e98);for(const _0x2b46de of _0x524013){if(_0x4928c2[_0x2b46de]!==_0x473e98[_0x2b46de]&&''!==_0x4928c2[_0x2b46de]['trim']()){_0x59ac4b=!0x0;break;}if(!_0x28128b(_0x32f036[_0x2b46de],_0x266476[_0x2b46de])&&Object['keys'](_0x32f036[_0x2b46de])['length']>0x0){_0x59ac4b=!0x0;break;}}_0x59ac4b||(_0x59ac4b=_0x3ab86a['some'](_0x1e1715=>!this['editor']['model']['document']['getRoot'](_0x1e1715))),_0x59ac4b&&_0x198b8e('editor-initial-data-replaced-with-revision-data',{'editorData':_0x4928c2,'editorRootsAttributes':_0x32f036,'revisionData':_0x473e98,'revisionRootsAttributes':_0x266476}),this['editor']['config']['set']('initialData',_0x473e98),this['editor']['config']['set']('rootsAttributes',_0x266476);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x14f113=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x14f113['add'](R(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x43728f){const _0x13aa02=this['repository']['getRevisions']();_0x13aa02['reverse']();let _0x22200c=0x0;for(;_0x22200c<_0x13aa02['length'];){const _0x26a107=_0x13aa02[_0x22200c];if(_0x26a107===this['currentRevision']){_0x22200c++;continue;}if(_0x26a107['id']===this['_initialRevisionId'])break;const _0x7894bb=_0x43728f['toVersion']-_0x26a107['toVersion']||_0x43728f['fromVersion']-_0x26a107['fromVersion'];if(_0x7894bb>0x0)break;if(_0x7894bb<0x0)_0x22200c++;else{if(!_0x43728f['creator']&&_0x26a107['creator'])break;if(_0x26a107['creator']||!_0x43728f['creator']){if(_0x43728f['createdAt']>_0x26a107['createdAt'])break;_0x22200c++;}else _0x22200c++;}}return _0x22200c;}['_getFromVersion'](_0x5474fa){const _0x56a401=this['repository']['getRevisions']();_0x56a401['reverse'](),_0x56a401['shift']();const _0x62a08f=_0x56a401['find'](_0x354912=>_0x354912['toVersion']<=_0x5474fa)['toVersion'];return _0x62a08f<this['_startingVersion']?this['_startingVersion']:_0x62a08f;}['_makeRevision']({name:_0x3f8b69,from:_0x659b00,to:_0x31d668,creatorId:_0x428768,id:_0x3db11d}){const _0x1da1cf=this['buildRevisionData']({'from':_0x659b00,'to':_0x31d668});_0x1da1cf['name']=_0x3f8b69,_0x1da1cf['creatorId']=_0x428768,_0x1da1cf['id']=_0x3db11d;const _0x89c603=this['addRevisionData'](_0x1da1cf);return this['adapter']&&this['_bufferUpdate'](_0x1da1cf['id'],_0x1da1cf,!0x0),_0x89c603;}['_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(_0x7d0903){this['editor']=_0x7d0903,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'](_0x5efb1d){this['source']=_0x5efb1d;const _0x4dea30=new Map(),_0x1d8101=new Map(),_0x2af5de=this['editor']['model']['document']['roots']['map'](_0x2fd2af=>_0x2fd2af['rootName']);for(const _0x3564a0 of _0x2af5de){const _0x2d8b53=this['editor']['model']['document']['getRoot'](_0x3564a0),_0x148f9a=x(_0x2d8b53);_0x4dea30['set'](_0x3564a0,_0x148f9a),_0x1d8101['set'](_0x3564a0,Object['fromEntries'](_0x2d8b53['getAttributes']()));}const _0x873b52=Array['from'](this['editor']['model']['markers'])['map'](_0x583087=>[_0x583087['name'],_0x583087['getRange']()]),_0x97e314=this['source']['version'];this['_saveMetaData'](_0x97e314,_0x4dea30,_0x873b52,_0x1d8101),this['_startingRevisionId']=this['_revisionId'];const _0x3e1485=new Map(),_0x274de0=new Map();for(const _0x12bf8f of _0x2af5de){const _0x4648df=N(_0x12bf8f);_0x3e1485['set'](_0x12bf8f,_0x4648df),_0x274de0['set'](_0x12bf8f,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x3e1485,[],_0x274de0);}['getData'](_0x2e0e64,_0x9a57){if(this['_lastFrom']===_0x2e0e64&&this['_lastTo']<=_0x9a57)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x9a57,!0x0);else{if(!this['_savedMetaData']['has'](_0x2e0e64)){const _0x3440c1=this['_getPreviousFrom'](_0x2e0e64);this['_calculateMetaData'](_0x3440c1,_0x2e0e64,!0x1);}this['_calculateMetaData'](_0x2e0e64,_0x9a57,!0x0);}return this['_lastFrom']=_0x2e0e64,this['_lastTo']=_0x9a57,this['_getState']();}['loadState'](_0x55f485){const _0x1536f1=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x55f485['fromVersion'],this['_lastTo']=_0x55f485['toVersion'];for(const _0x2aad41 in _0x55f485['diffData']){const _0x5deacd=_0x55f485['diffData'][_0x2aad41]['attachChange'],_0x2ecc52=_0x2b75d6(_0x55f485['diffData'][_0x2aad41]['attributesBefore'])||{},_0x610a8e=_0x1536f1['_makeModelFromViewString'](_0x55f485['diffData'][_0x2aad41]['deletions']);_0x610a8e['rootName']=_0x2aad41,_0x610a8e['_isAttached']=!_0x5deacd||!_0x5deacd['isAttached'],_0x610a8e['isAttached']=()=>_0x610a8e['_isAttached'],this['_baseRoots']['set'](_0x2aad41,_0x610a8e),this['_baseRootsAttributes']['set'](_0x2aad41,_0x2ecc52),_0x5deacd&&this['_touchedRoots']['set'](_0x2aad41,_0x5deacd);const _0x3e0c54=this['_makeIdsRoot'](_0x610a8e);this['_baseIdsRoots']['set'](_0x2aad41,_0x3e0c54);for(const [_0x1206d7,_0x1d431a]of _0x610a8e['markers']){if(!_0x1206d7['startsWith']('revision:'))continue;const _0x2f7748=_0x1206d7['split'](':')[0x2];for(const _0x449291 of _0x1d431a['getWalker']({'singleCharacters':!0x0})){const _0x503a98=this['_getVidAttributeName'](_0x449291),_0x166435='elementEnd'==_0x449291['type']?_0x449291['previousPosition']['path']['slice'](0x0,-0x1):_0x449291['previousPosition']['path'],_0x467d87=_0x3e0c54['getNodeByPath'](_0x166435)['getAttribute'](_0x503a98);this['_touched']['set'](_0x467d87,{'userId':_0x2f7748});}}}this['_startingRevisionId']=this['_revisionId'];const _0x21772d=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0xfce44d=>!this['_touched']['has'](_0xfce44d));let _0x53d1a8=0x0;const _0x4f3263=new Map();for(const _0x2b3c7c in _0x55f485['diffData']){const _0x17f906=_0x55f485['diffData'][_0x2b3c7c]['attachChange'],_0x3fbd21=_0x2b75d6(_0x55f485['diffData'][_0x2b3c7c]['attributesAfter'])||{},_0x563024=_0x1536f1['_makeModelFromViewString'](_0x55f485['diffData'][_0x2b3c7c]['insertions']);_0x563024['rootName']=_0x2b3c7c,_0x563024['_isAttached']=!_0x17f906||_0x17f906['isAttached'],_0x563024['isAttached']=()=>_0x563024['_isAttached'],this['_diffRoots']['set'](_0x2b3c7c,_0x563024),this['_diffRootsAttributes']['set'](_0x2b3c7c,_0x3fbd21);const _0x497e38=this['_makeIdsRoot'](_0x563024,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x2b3c7c,_0x497e38),_0x4f3263['set'](_0x2b3c7c,_0x563024['isAttached']()?_0x3fbd21:{});for(const [_0x40b254,_0x21f8cf]of _0x563024['markers']){if(!_0x40b254['startsWith']('revision:'))continue;const _0x1ee4cb=_0x40b254['split'](':')[0x2];for(const _0x5d7f75 of _0x21f8cf['getWalker']({'singleCharacters':!0x0})){const _0x2c4e18=this['_getVidAttributeName'](_0x5d7f75),_0x38eaf2=this['_revisionId']++,_0x303dc7='elementEnd'==_0x5d7f75['type']?_0x5d7f75['previousPosition']['path']['slice'](0x0,-0x1):_0x5d7f75['previousPosition']['path'];_0x497e38['getNodeByPath'](_0x303dc7)['_setAttribute'](_0x2c4e18,_0x38eaf2),this['_touched']['set'](_0x38eaf2,{'userId':_0x1ee4cb});}}for(const _0x5eec24 of this['editor']['model']['createRangeIn'](_0x563024)['getWalker']({'singleCharacters':!0x0})){const _0x2caa10=this['_getVidAttributeName'](_0x5eec24),_0x35e917='elementEnd'==_0x5eec24['type']?_0x5eec24['previousPosition']['path']['slice'](0x0,-0x1):_0x5eec24['previousPosition']['path'],_0x3a2436=_0x497e38['getNodeByPath'](_0x35e917);_0x3a2436['getAttribute'](_0x2caa10)>0x0||_0x3a2436['_setAttribute'](_0x2caa10,_0x21772d[_0x53d1a8++]);}for(const [_0x1910e1,_0x26d422]of _0x563024['markers'])_0x1910e1['startsWith']('revision:')||this['_markers']['set'](_0x1910e1,_0x26d422);}const _0x43f6ac=N('$graveyard');this['_baseRoots']['set']('$graveyard',_0x43f6ac),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x43f6ac,0x1));const _0x29eb8d=N('$graveyard');this['_diffRoots']['set']('$graveyard',_0x29eb8d),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x29eb8d,0x1));const _0x1b0f68=Array['from'](this['_diffRoots'])['map'](([_0xe4e6bc,_0x2db8b6])=>[_0xe4e6bc,x(_0x2db8b6)]);this['_saveMetaData'](this['_lastTo'],_0x1b0f68,this['_markers'],_0x4f3263);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0xe6c013,_0x127cee,_0x2e6a69,_0x51a322){const _0x4bbf64=new Map(_0x127cee),_0x3a7a07=new Map(_0x2b75d6(_0x51a322)),_0x126ada=new Map();for(const [_0x2da66a,_0x3c628b]of _0x2e6a69)_0x126ada['set'](_0x2da66a,{'start':_0x3c628b['start']['clone'](),'end':_0x3c628b['end']['clone'](),'rootName':_0x3c628b['root']['rootName']});this['_savedMetaData']['set'](_0xe6c013,{'roots':_0x4bbf64,'markers':_0x126ada,'rootsAttributes':_0x3a7a07});}['_removeMetaData'](_0x1ba9c9){this['_savedMetaData']['delete'](_0x1ba9c9);}['_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'](_0x1a2737,_0x259353=null){let _0x19b8b6=null;_0x1a2737['is']('documentFragment')||(_0x19b8b6=new _0x3061f3(_0x1a2737['name'],{'vid_start':null===_0x259353?this['_revisionId']++:_0x259353++}));const _0x2005cd=[];for(const _0x50775f of _0x1a2737['getChildren']())if(_0x50775f['is']('element')){_0x2005cd['push'](this['_makeIdsRoot'](_0x50775f,_0x259353));const _0x3b9265=_0x2005cd[_0x2005cd['length']-0x1];null!==_0x259353&&(_0x259353=_0x3b9265['is']('element','$text')?_0x3b9265['getAttribute']('vid')+0x1:_0x3b9265['getAttribute']('vid_end')+0x1);}else{for(let _0x2cb980=0x0;_0x2cb980<_0x50775f['offsetSize'];_0x2cb980++)_0x2005cd['push'](new _0x3061f3('$text',{'vid':null===_0x259353?this['_revisionId']++:_0x259353++}));}if(_0x1a2737['is']('documentFragment')){const _0x58d1bc=N(_0x1a2737['rootName']);return _0x58d1bc['_insertChild'](0x0,_0x2005cd),_0x58d1bc;}return _0x19b8b6['_setAttribute']('vid_end',null===_0x259353?this['_revisionId']++:_0x259353++),_0x19b8b6['_insertChild'](0x0,_0x2005cd),_0x19b8b6;}['_calculateMetaData'](_0xb5cdf8,_0x5c4393,_0x5d9105){this['_reset']();const {roots:_0x530aa4,markers:_0x42289e,rootsAttributes:_0x1adff0}=this['_savedMetaData']['get'](_0xb5cdf8);this['_baseRoots']=new Map(_0x530aa4),this['_baseRootsAttributes']=new Map(_0x2b75d6(_0x1adff0));for(const [_0x4c662e,_0x3ecfd5]of this['_baseRoots'])if('$graveyard'!==_0x4c662e&&(this['_diffRoots']['set'](_0x4c662e,x(_0x3ecfd5)),this['_diffRootsAttributes']=new Map(_0x2b75d6(_0x1adff0)),_0x5d9105)){const _0x511497=this['_revisionId'];this['_idsRoots']['set'](_0x4c662e,this['_makeIdsRoot'](_0x3ecfd5)),this['_baseIdsRoots']['set'](_0x4c662e,this['_makeIdsRoot'](_0x3ecfd5,_0x511497));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',x(this['_baseRoots']['get']('$graveyard'))),_0x5d9105&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x4fb7fc,_0x4b0696]of _0x42289e){const _0x4835a2=this['_baseRoots']['get'](_0x4b0696['rootName']),_0x3b1c91=this['_diffRoots']['get'](_0x4b0696['rootName']),_0x5fb50c=new _0x1c348a(this['_fixPosition'](_0x4b0696['start'],_0x4835a2),this['_fixPosition'](_0x4b0696['end'],_0x4835a2)),_0x4a23a5=this['_fixRange'](_0x5fb50c,_0x3b1c91);_0x4835a2['markers']['set'](_0x4fb7fc,_0x5fb50c),this['_markers']['set'](_0x4fb7fc,_0x4a23a5);}this['_applyOperations'](_0xb5cdf8,_0x5c4393,_0x5d9105);}['_applyOperations'](_0x5cb0eb,_0x1f76e7,_0x50a97f){for(const _0x2414d0 of this['source']['getOperations'](_0x5cb0eb,_0x1f76e7))this['_handleOperation'](_0x2414d0,_0x50a97f);for(const _0x5c2507 of this['_diffRoots']['values']())_0x5c2507['markers']['clear']();for(const [_0x22595b,_0x9207b8]of this['_markers']){this['_diffRoots']['get'](_0x9207b8['root']['rootName'])['markers']['set'](_0x22595b,_0x9207b8['clone']());}const _0x7c49fb=new Map(),_0xe9334c=new Map();for(const [_0x5becab,_0x3084f4]of this['_diffRoots'])_0x7c49fb['set'](_0x5becab,x(_0x3084f4)),_0xe9334c['set'](_0x5becab,this['_diffRootsAttributes']['get'](_0x5becab));this['_saveMetaData'](_0x1f76e7,_0x7c49fb,this['_markers'],_0xe9334c);}['_getPreviousFrom'](_0xfd1511){const _0x32cb06=Array['from'](this['_savedMetaData']['keys']());_0x32cb06['sort']((_0x2cb7be,_0x11e26a)=>_0x2cb7be-_0x11e26a),_0x32cb06['reverse']();for(const _0x5804bb of _0x32cb06)if(_0x5804bb<_0xfd1511)return _0x5804bb;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x30b5b8,_0x4d47dd){const _0x45f8d4=Array['from'](_0x4d47dd['markers'])['map'](([_0x3aaaa1,_0x1881cd])=>[_0x3aaaa1,this['_fixRange'](_0x1881cd,_0x30b5b8)]);_0x30b5b8['markers']=new Map(_0x45f8d4);}['_transformMarkers'](_0x1d4d21){for(const _0x3077dd of this['_markers']['values']()){const _0x2739e9=_0x3077dd['getTransformedByOperation'](_0x1d4d21),_0xd394dd=_0x1c348a['_createFromRanges'](_0x2739e9);_0x3077dd['start']=_0xd394dd['start'],_0x3077dd['end']=_0xd394dd['end'];}}['_handleOperation'](_0x40ec10,_0xa485ff){if('addRoot'!=_0x40ec10['type']&&'detachRoot'!=_0x40ec10['type']){if('insert'==_0x40ec10['type']){const _0x32ad3c=_0x40ec10['position']['root']['rootName'];this['_diffRoots']['has'](_0x32ad3c)||(this['_diffRoots']['set'](_0x32ad3c,N(_0x32ad3c,!0x0)),this['_diffRootsAttributes']['set'](_0x32ad3c,{}),_0xa485ff&&this['_idsRoots']['set'](_0x32ad3c,N(_0x32ad3c,!0x0)));}else{if('addRootAttribute'==_0x40ec10['type']||'removeRootAttribute'==_0x40ec10['type']||'changeRootAttribute'==_0x40ec10['type'])return void this['_handleRootAttributeOperation'](_0x40ec10);'marker'==_0x40ec10['type']&&this['_handleMarkerOperation'](_0x40ec10);}if('marker'!==_0x40ec10['type']){const _0x23e987=this['_cloneOperation'](_0x40ec10,this['_diffRoots']);_0x23e987['_execute'](),this['_transformMarkers'](_0x23e987);}if(_0xa485ff)switch(_0x40ec10['type']){case'insert':this['_handleInsertOperation'](_0x40ec10);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x40ec10);break;case'merge':this['_handleMergeOperation'](_0x40ec10);break;case'split':this['_handleSplitOperation'](_0x40ec10);}}else this['_handleRootOperation'](_0x40ec10,_0xa485ff);}['_cloneOperation'](_0x56df39,_0x2568fb){const _0x3aadfa=_0x56df39['clone']();return _0x3aadfa['_authorId']=_0x56df39['_authorId'],this['_fixOperation'](_0x3aadfa,_0x2568fb),_0x3aadfa;}['_getBaseVids'](_0x5b8517){return _0x5b8517['map'](_0x528b69=>{const _0x5477ba=this['_getVidAttributeName'](_0x528b69);return Number(_0x528b69['item']['getAttribute'](_0x5477ba));});}['_generateTape'](_0x518af7,_0x381ef8){if(_0x518af7['is']('element','$text'))_0x381ef8['push']({'item':_0x518af7,'type':'text'});else{_0x518af7['is']('element')&&_0x381ef8['push']({'item':_0x518af7,'type':'elementStart'});for(const _0x3a6963 of _0x518af7['getChildren']())this['_generateTape'](_0x3a6963,_0x381ef8);_0x518af7['is']('element')&&_0x381ef8['push']({'item':_0x518af7,'type':'elementEnd'});}return _0x381ef8;}['_getState'](){const _0x4a5521=new Map(this['_touched']),_0x46245d=new Map(_0x4a5521),_0x1d8fb5=new Map(),_0x29fb7d={'insertions':{},'deletions':{}},_0x3ff078={'insertions':{},'deletions':{}},_0x462bbb=new Map(),_0x3a7bfe=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x3a7bfe['delete']('$graveyard');for(const _0x115823 of _0x3a7bfe){const _0x479bdb=this['_diffRoots']['get'](_0x115823)||N(_0x115823,!0x1),_0x1aab13=this['_baseRoots']['get'](_0x115823)||N(_0x115823,!0x1);_0x479bdb['isAttached']()||_0x1aab13['isAttached']()?(_0x29fb7d['insertions'][_0x115823]=x(_0x479bdb),_0x29fb7d['deletions'][_0x115823]=x(_0x1aab13),this['_copyMarkers'](_0x29fb7d['deletions'][_0x115823],_0x1aab13),this['_copyMarkers'](_0x29fb7d['insertions'][_0x115823],_0x479bdb),_0x3ff078['insertions'][_0x115823]=this['_generateTape'](this['_idsRoots']['get'](_0x115823),[]),_0x3ff078['deletions'][_0x115823]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x115823)||N(_0x115823,!0x1),[])):_0x3a7bfe['delete'](_0x115823);}for(const _0x5c3845 of _0x3a7bfe){const _0xc41bd5=_0x3ff078['insertions'][_0x5c3845];for(const _0x11ff6d of _0xc41bd5){const _0x59de21=this['_getVidAttributeName'](_0x11ff6d),_0x47c1af=_0x11ff6d['item']['getAttribute'](_0x59de21);_0x46245d['delete'](_0x47c1af),_0x47c1af>=this['_startingRevisionId']&&_0x1d8fb5['set'](_0x47c1af,_0x4a5521['get'](_0x47c1af));}}for(const _0x36ea02 of _0x3a7bfe){const _0x2eeb60=_0x3ff078['insertions'][_0x36ea02],_0x3dbb0b=this['_getBaseVids'](_0x3ff078['deletions'][_0x36ea02]);let _0x5ed64b=0x0;for(const _0x19e600 of _0x2eeb60){const _0x359212=this['_getVidAttributeName'](_0x19e600),_0x345ccb=_0x19e600['item']['getAttribute'](_0x359212);if(!_0x1d8fb5['has'](_0x345ccb)&&!_0x462bbb['has'](_0x345ccb)){if(_0x46245d['has'](_0x345ccb))_0x5ed64b++;else{if(_0x345ccb!=_0x3dbb0b[_0x5ed64b]){const _0xd86416=_0x4a5521['get'](_0x345ccb)||_0x4a5521['get'](_0x3dbb0b[_0x5ed64b]);for(;_0x345ccb!=_0x3dbb0b[_0x5ed64b];)_0x46245d['has'](_0x3dbb0b[_0x5ed64b])||(_0x462bbb['set'](_0x3dbb0b[_0x5ed64b],_0xd86416),_0x4a5521['set'](_0x3dbb0b[_0x5ed64b],_0xd86416)),_0x5ed64b++;}_0x5ed64b++;}}}}for(const _0x5df5ee of _0x3a7bfe){const _0x2c3615=_0x3ff078['insertions'][_0x5df5ee];for(const _0x3c6853 of _0x2c3615){const _0x4659f9=this['_getVidAttributeName'](_0x3c6853),_0x5423a8=_0x3c6853['item']['getAttribute'](_0x4659f9);if(_0x462bbb['has'](_0x5423a8)){const _0x594aa1=_0x462bbb['get'](_0x5423a8);_0x46245d['has'](_0x5423a8)||_0x46245d['set'](_0x5423a8,{..._0x594aa1}),_0x1d8fb5['set'](_0x5423a8,{..._0x594aa1});}}}for(const _0x53bd1c of _0x46245d['keys']())_0x53bd1c>=this['_startingRevisionId']&&_0x46245d['delete'](_0x53bd1c);const _0x4724bb=new Map();for(const _0x526029 of _0x3a7bfe){let _0x49f043=_0x3ff078['insertions'][_0x526029];for(const _0x16850e of _0x49f043)if(_0x16850e['item']['is']('element','tableCell')){const _0x16577d=this['_getVidAttributeName'](_0x16850e),_0x12463b=_0x16850e['item']['getAttribute'](_0x16577d);if(_0x1d8fb5['has'](_0x12463b)){const _0x19d92f=_0x16850e['item']['parent']['parent']['getAttribute']('vid_start'),_0xe02567=_0x4724bb['get'](_0x19d92f)||new Set();_0xe02567['add'](_0x1d8fb5['get'](_0x12463b)['userId']),_0x4724bb['set'](_0x19d92f,_0xe02567);}}_0x49f043=_0x3ff078['deletions'][_0x526029];for(const _0xf580db of _0x49f043)if(_0xf580db['item']['is']('element','tableCell')){const _0x319037=this['_getVidAttributeName'](_0xf580db),_0x6107e4=_0xf580db['item']['getAttribute'](_0x319037);if(_0x46245d['has'](_0x6107e4)){const _0x980698=_0xf580db['item']['parent']['parent']['getAttribute']('vid_start'),_0x557a8c=_0x4724bb['get'](_0x980698)||new Set();_0x557a8c['add'](_0x46245d['get'](_0x6107e4)['userId']),_0x4724bb['set'](_0x980698,_0x557a8c);}}for(const _0x5bf2a3 of _0x4724bb['keys']())(_0x1d8fb5['has'](_0x5bf2a3)||_0x46245d['has'](_0x5bf2a3))&&_0x4724bb['delete'](_0x5bf2a3);}for(const _0x510f95 of _0x3a7bfe){const _0x43f3b7=_0x3ff078['insertions'][_0x510f95];let _0x58982b=null,_0x3f6b05=null;for(const _0x15533d of _0x43f3b7){const _0x217c79=this['_getVidAttributeName'](_0x15533d),_0x277cba=_0x15533d['item']['getAttribute'](_0x217c79),_0x336023=_0x4724bb['get'](_0x277cba);_0x336023&&'elementStart'==_0x15533d['type']&&(_0x58982b=Array['from'](_0x336023)[0x0],_0x3f6b05=_0x15533d['item']['getAttribute']('vid_end')),_0x58982b&&(_0x46245d['set'](_0x277cba,{'userId':_0x58982b}),_0x1d8fb5['set'](_0x277cba,{'userId':_0x58982b})),_0x277cba==_0x3f6b05&&(_0x58982b=null,_0x3f6b05=null);}}const _0x3d47c4={},_0x53aec7=new Set();for(const _0x142b67 of _0x3a7bfe){const _0xda93dc=_0x29fb7d['deletions'][_0x142b67],_0x28dbe3=_0x29fb7d['insertions'][_0x142b67];for(const {userId:_0x24aa1f}of this['_touchedMarkers']['values']())null!==_0x24aa1f&&_0x53aec7['add'](_0x24aa1f);for(const {userId:_0x4b9ee1}of this['_touchedRoots']['values']())null!==_0x4b9ee1&&_0x53aec7['add'](_0x4b9ee1);this['_markChanges'](_0x28dbe3,_0x3ff078['insertions'][_0x142b67],_0x1d8fb5,'insertion',_0x53aec7),this['_markChanges'](_0xda93dc,_0x3ff078['deletions'][_0x142b67],_0x46245d,'deletion',_0x53aec7),_0x3d47c4[_0x142b67]={'insertions':this['_prepareViewToSave'](_0x28dbe3),'deletions':this['_prepareViewToSave'](_0xda93dc),'attachChange':this['_touchedRoots']['get'](_0x142b67)||null,'attributesBefore':_0x2b75d6(this['_baseRootsAttributes']['get'](_0x142b67))||{},'attributesAfter':_0x2b75d6(this['_diffRootsAttributes']['get'](_0x142b67))};}return{'diffData':_0x3d47c4,'authorsIds':Array['from'](_0x53aec7)};}['_processRootBeforeSave'](_0x5451e8){for(const [,_0x379cbd]of _0x5451e8['markers']){const _0x1cde60=_0x379cbd['start']['getAncestors']()['filter'](_0x11bc2a=>'tableCell'==_0x11bc2a['name']);for(const _0x86199d of _0x1cde60)0x1==_0x86199d['childCount']&&_0x86199d['getChild'](0x0)['is']('element','paragraph')&&_0x86199d['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x42526e){this['_processRootBeforeSave'](_0x42526e);const _0x434b8e=this['editor']['data']['toView'](_0x42526e,{}),_0x3e83d4=Array['from'](_0x434b8e['getChildren']())['map'](_0x53b0f7=>this['_getViewJson'](_0x53b0f7));return JSON['stringify'](_0x3e83d4);}['_getViewJson'](_0x5b64a5){if(_0x5b64a5['is']('$text'))return _0x5b64a5['data'];{const _0x225ae2=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0x337431=_0x5b64a5,_0x29115c=this['editor']['data']['htmlProcessor']['domConverter'],_0x3540d8={'type':_0x225ae2['_getTypeCharForViewElement'](_0x337431),'name':_0x337431['name'],'attributes':Array['from'](_0x337431['getAttributes']()),'children':Array['from'](_0x337431['getChildren']())['map'](_0x35364c=>this['_getViewJson'](_0x35364c))};if(_0x5b64a5['is']('uiElement')&&'$comment'!=_0x5b64a5['name']){const _0x221aa6=_0x5b64a5['render'](_0x29115c['domDocument'],_0x29115c);_0x3540d8['children']['push'](_0x221aa6['outerHTML']);}else{if(_0x5b64a5['is']('rawElement')){const _0x2d5c50=_0x29115c['domDocument']['createElement'](_0x337431['name']);_0x5b64a5['render'](_0x2d5c50,_0x29115c),_0x3540d8['children']['push'](_0x2d5c50['innerHTML']);}}const _0x2a32d7=Array['from'](_0x337431['getCustomProperties']());_0x2a32d7['length']>0x0&&(_0x3540d8['customProperties']=_0x2a32d7);const _0x3871d9=_0x337431['getFillerOffset']();return null!==_0x3871d9&&(_0x3540d8['fillerOffset']=_0x3871d9),_0x3540d8;}}['_markChanges'](_0x1c1acd,_0xec07f1,_0x568edf,_0x21a174,_0x2130aa){let _0x1c2689=null,_0x317165=null,_0x315dfa=0x0;const _0x1a9ea1=this['editor']['model'];for(let _0x355020=0x0;_0x355020<_0xec07f1['length'];_0x355020++){const _0x5cd4d6=this['_getVidAttributeName'](_0xec07f1[_0x355020]),_0x206f8=_0xec07f1[_0x355020]['item']['getAttribute'](_0x5cd4d6),_0x11e67a=_0x568edf['get'](_0x206f8),_0x28033a=_0x355020==_0xec07f1['length']-0x1;(!_0x1c2689&&_0x11e67a&&(_0x1c2689=_0x11e67a,_0x317165=_0xec07f1[_0x355020]),_0x1c2689&&(!_0x11e67a||_0x11e67a['userId']!=_0x1c2689['userId']))&&(_0x135e64(_0x11e67a,P(_0x317165,_0x1c1acd,_0x1a9ea1),P(_0xec07f1[_0x355020],_0x1c1acd,_0x1a9ea1)),_0x1c2689=_0x11e67a||null,_0x317165=_0x11e67a?_0xec07f1[_0x355020]:null),_0x1c2689&&_0x28033a&&_0x135e64(_0x11e67a,P(_0x317165,_0x1c1acd,_0x1a9ea1),V(_0xec07f1[_0x355020],_0x1c1acd,_0x1a9ea1));}function _0x135e64(_0x7e1224,_0x47732f,_0x36b4ff){const _0x1cb3b0=_0x1c2689['userId'],_0x3680f0='revision:'+_0x21a174+':'+_0x1cb3b0+':'+_0x315dfa++,_0x372d15=_0x1a9ea1['createRange'](_0x47732f,_0x36b4ff);_0x1c1acd['markers']['set'](_0x3680f0,_0x372d15),null!==_0x1cb3b0&&_0x2130aa['add'](_0x1cb3b0);}}['_getVidAttributeName'](_0x499a4a){switch(_0x499a4a['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x4fcad4,_0x3fdaaf){_0x4fcad4['baseVersion']=null;for(const _0x3b3d61 in _0x4fcad4){const _0x41f711=_0x4fcad4[_0x3b3d61];if(_0x41f711 instanceof _0x3da34e){const _0x111ff6=_0x3fdaaf['get'](_0x41f711['root']['rootName']);_0x4fcad4[_0x3b3d61]=this['_fixPosition'](_0x41f711,_0x111ff6);}if(_0x41f711 instanceof _0x1c348a){const _0x1283cb=_0x3fdaaf['get'](_0x41f711['root']['rootName']);_0x4fcad4[_0x3b3d61]=this['_fixRange'](_0x41f711,_0x1283cb);}'root'===_0x3b3d61&&(_0x4fcad4['root']=_0x3fdaaf['get'](_0x4fcad4['root']['rootName']));}}['_fixRange'](_0x53e285,_0xb51089){return this['editor']['model']['createRange'](this['_fixPosition'](_0x53e285['start'],_0xb51089),this['_fixPosition'](_0x53e285['end'],_0xb51089));}['_fixPosition'](_0x1d91ea,_0x56d1b3){return this['editor']['model']['createPositionFromPath'](_0x56d1b3,_0x1d91ea['path'],_0x1d91ea['stickiness']);}['_handleInsertOperation'](_0x5c2315){const _0x959fe8=this['_idsRoots']['get'](_0x5c2315['position']['root']['rootName']),_0xb67b15=this['_fixPosition'](_0x5c2315['position'],_0x959fe8),_0x545173=null===_0x5c2315['_authorId']?null:_0x5c2315['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x26a1c4=_0xb67b15['parent'],_0x5c4597=this['_revisionId'],_0x2f800c=[];for(const _0x2cc9d6 of _0x5c2315['nodes'])if(_0x2cc9d6['is']('element'))_0x2f800c['push'](this['_makeIdsRoot'](_0x2cc9d6));else{for(let _0x40e4cc=0x0;_0x40e4cc<_0x2cc9d6['offsetSize'];_0x40e4cc++)_0x2f800c['push'](new _0x3061f3('$text',{'vid':this['_revisionId']++}));}const _0x58d72c=this['_revisionId'];for(let _0x5f5373=_0x5c4597;_0x5f5373<_0x58d72c;_0x5f5373++)this['_touched']['set'](_0x5f5373,{'userId':_0x545173});_0x26a1c4['_insertChild'](_0xb67b15['offset'],_0x2f800c);}['_handleMoveOperation'](_0x39c223){(_0x39c223=this['_cloneOperation'](_0x39c223,this['_idsRoots']))['_execute']();const _0x23dc54=null===_0x39c223['_authorId']?null:_0x39c223['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x44fdab=_0x39c223['getMovedRangeStart'](),_0x425fcf=_0x44fdab['parent'],_0x5f1391=_0x44fdab['offset'];!function _0x43110f(_0x23e0ce,_0x5a0e1c,_0x3252b2,_0x179ccb){for(let _0x3f1c8d=_0x3252b2;_0x3f1c8d<_0x179ccb;_0x3f1c8d++){const _0x4abf5e=_0x5a0e1c['getChild'](_0x3f1c8d);_0x4abf5e['is']('element','$text')?_0x23e0ce['set'](_0x4abf5e['getAttribute']('vid'),{'userId':_0x23dc54}):(_0x23e0ce['set'](_0x4abf5e['getAttribute']('vid_start'),{'userId':_0x23dc54}),_0x43110f(_0x23e0ce,_0x4abf5e,0x0,_0x4abf5e['childCount']),_0x23e0ce['set'](_0x4abf5e['getAttribute']('vid_end'),{'userId':_0x23dc54}));}}(this['_touched'],_0x425fcf,_0x5f1391,_0x5f1391+_0x39c223['howMany']);}['_handleMergeOperation'](_0x3070c9){const _0x3ef3e1=null===(_0x3070c9=this['_cloneOperation'](_0x3070c9,this['_idsRoots']))['_authorId']?null:_0x3070c9['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x2a3fd8=_0x3070c9['targetPosition']['parent'],_0x160cc6=_0x3070c9['sourcePosition']['parent'],_0x431aaf=_0x2a3fd8['getAttribute']('vid_end'),_0x536f4e=_0x160cc6['getAttribute']('vid_start');_0x2a3fd8['_setAttribute']('vid_end',_0x160cc6['getAttribute']('vid_end')),_0x160cc6['_setAttribute']('vid_end',_0x431aaf),this['_touched']['set'](_0x536f4e,{'userId':_0x3ef3e1}),this['_touched']['set'](_0x431aaf,{'userId':_0x3ef3e1}),_0x3070c9['_execute']();}['_handleSplitOperation'](_0x2c0710){const _0x57b2ae=null===(_0x2c0710=this['_cloneOperation'](_0x2c0710,this['_idsRoots']))['_authorId']?null:_0x2c0710['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x2558e4=_0x2c0710['graveyardPosition'],_0x1b2310=_0x2c0710['splitPosition']['parent'];_0x2c0710['_execute']();const _0x1c867b=_0x1b2310['getAttribute']('vid_end'),_0x45da46=_0x2c0710['insertionPosition']['nodeAfter'];if(_0x2558e4){const _0x1d333e=_0x45da46['getAttribute']('vid_end'),_0x1a7e0e=_0x1b2310['getAttribute']('vid_end');_0x1b2310['_setAttribute']('vid_end',_0x1d333e),_0x45da46['_setAttribute']('vid_end',_0x1a7e0e),this['_touched']['set'](_0x1b2310['getAttribute']('vid_end'),{'userId':_0x57b2ae}),this['_touched']['set'](_0x45da46['getAttribute']('vid_start'),{'userId':_0x57b2ae});}else{const _0x15dcfb=this['_revisionId']++,_0x3a1b1c=this['_revisionId']++;_0x1b2310['_setAttribute']('vid_end',_0x15dcfb),_0x45da46['_setAttribute']('vid_start',_0x3a1b1c),_0x45da46['_setAttribute']('vid_end',_0x1c867b),this['_touched']['set'](_0x15dcfb,{'userId':_0x57b2ae}),this['_touched']['set'](_0x3a1b1c,{'userId':_0x57b2ae});}}['_handleMarkerOperation'](_0x3e2cf0){if(!_0x3e2cf0['affectsData'])return;const _0x23fe06=(_0x3e2cf0=this['_cloneOperation'](_0x3e2cf0,this['_diffRoots']))['oldRange']?_0x3e2cf0['oldRange']['root']:null,_0x1b3908=_0x3e2cf0['newRange']?_0x3e2cf0['newRange']['root']:null;_0x23fe06&&this['_markers']['delete'](_0x3e2cf0['name']),_0x1b3908&&this['_markers']['set'](_0x3e2cf0['name'],_0x3e2cf0['newRange']['clone']());const _0x53fcf2=null===_0x3e2cf0['_authorId']?null:_0x3e2cf0['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x49520e=_0x3e2cf0['name'];if(!this['_touchedMarkers']['has'](_0x49520e))return void this['_touchedMarkers']['set'](_0x49520e,{'range':_0x3e2cf0['oldRange'],'userId':_0x53fcf2});const _0x246449=this['_touchedMarkers']['get'](_0x49520e),_0x30c294=_0x246449['range'],_0x16b775=_0x3e2cf0['newRange'];null==_0x30c294&&null==_0x16b775||_0x30c294&&_0x16b775&&_0x30c294['isEqual'](_0x16b775)?this['_touchedMarkers']['delete'](_0x3e2cf0['name']):_0x246449['userId']=_0x53fcf2;}['_handleRootOperation'](_0x20b88b,_0x4b625d){this['_diffRoots']['has'](_0x20b88b['rootName'])?this['_diffRoots']['get'](_0x20b88b['rootName'])['_isAttached']=_0x20b88b['isAdd']:(this['_diffRoots']['set'](_0x20b88b['rootName'],N(_0x20b88b['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x20b88b['rootName'],{}),_0x4b625d&&this['_idsRoots']['set'](_0x20b88b['rootName'],N(_0x20b88b['rootName'],!0x0)));const _0x217c36=null===_0x20b88b['_authorId']?null:_0x20b88b['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x2d6404=this['_touchedRoots']['get'](_0x20b88b['rootName']);_0x2d6404&&_0x2d6404['userId']===_0x217c36?this['_touchedRoots']['delete'](_0x20b88b['rootName']):this['_touchedRoots']['set'](_0x20b88b['rootName'],{'userId':_0x217c36,'isAttached':_0x20b88b['isAdd']});}['_handleRootAttributeOperation'](_0x592631){const _0x250987=this['_diffRootsAttributes']['get'](_0x592631['root']['rootName']);null===_0x592631['newValue']?delete _0x250987[_0x592631['key']]:_0x250987[_0x592631['key']]=_0x592631['newValue'];}}function x(_0x5d8326){const _0x57bc18=N(_0x5d8326['rootName'],_0x5d8326['isAttached']());for(const _0x56e19e of _0x5d8326['getChildren']()){const _0x49b29f=_0x56e19e['_clone'](!0x0);_0x57bc18['_appendChild'](_0x49b29f);}return _0x57bc18;}function N(_0x21ec95,_0x429dcb=!0x0){const _0x48b4f9=new _0x3a58c7();return _0x48b4f9['rootName']=_0x21ec95,_0x48b4f9['_isAttached']=_0x429dcb,_0x48b4f9['isAttached']=()=>_0x48b4f9['_isAttached'],_0x48b4f9;}function P(_0x1cb70e,_0x15347,_0x475c37){const _0x5f4fa1='elementEnd'==_0x1cb70e['type']?_0x475c37['createPositionAt'](_0x1cb70e['item'],'end'):_0x475c37['createPositionBefore'](_0x1cb70e['item']);return _0x475c37['createPositionFromPath'](_0x15347,_0x5f4fa1['path'],_0x5f4fa1['stickiness']);}function V(_0x1321c3,_0x159223,_0x51d15b){const _0x32b62c='elementStart'==_0x1321c3['type']?_0x51d15b['createPositionAt'](_0x1321c3['item'],0x0):_0x51d15b['createPositionAfter'](_0x1321c3['item']);return _0x51d15b['createPositionFromPath'](_0x159223,_0x32b62c['path'],_0x32b62c['stickiness']);}class he extends/* #__PURE__ -- @preserve */
|
|
25
|
-
|
|
26
|
-
_0x235c38(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x1eb48c){super(),this['id']=_0x1eb48c['id']||_0x1a737e(),this['author']=_0x1eb48c['author'],this['type']=_0x1eb48c['type'],this['data']=_0x1eb48c['data']||{},this['rootName']=_0x1eb48c['rootName'],this['set']('createdAt',_0x1eb48c['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(_0x4d14e3,_0x40ed3e){this['newRevisionId']=_0x4d14e3,this['oldRevisionId']=_0x40ed3e,this['changes']=new _0x1d5790();}['_setChanges'](_0xf036dc){for(const _0x51ff94 of _0xf036dc)this['changes']['add'](_0x51ff94);}}class l extends _0x858dc7{['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[_0x267b04,_0x55b3a5,S,$];}constructor(_0x8c1f2){super(_0x8c1f2),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',(_0x1603c8,_0x162d28,_0x2426b6)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0xd55567=>{for(const _0x4aac89 of this['editor']['editing']['view']['document']['roots'])_0x2426b6?_0xd55567['removeClass']('ck-editor__editable__overlay',_0x4aac89):_0xd55567['addClass']('ck-editor__editable__overlay',_0x4aac89);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x209c30=>null!==_0x209c30),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x587d4e,_0xedb61,_0x5758f9)=>_0x587d4e&&_0x5758f9?_0xedb61['changes']['getIndex'](_0x5758f9):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x1f3a34,_0x133c2d)=>_0x1f3a34?_0x133c2d['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0x55b3a5);}['init'](){const _0x3bf345=this['editor'],_0x3586d8=new ot(_0x3bf345,{'direction':'backward'}),_0x258f16=new ot(_0x3bf345,{'direction':'forward'});(_0x3bf345['commands']['add']('showPreviousChange',_0x3586d8),_0x3bf345['commands']['add']('showNextChange',_0x258f16),_0x3bf345['commands']['add']('restoreRevision',new nt(_0x3bf345)),this['on']('change:numberOfChanges',()=>{_0x3586d8['refresh'](),_0x258f16['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x3bf345['enableReadOnlyMode']('revision-viewer'),_0x3bf345['plugins']['has']('WidgetToolbarRepository'))&&_0x3bf345['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x5be6d2){return await this['_utils']['loadRevisionData'](_0x5be6d2,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x5be6d2);}async['getRevisionRootsAttributes'](_0x5ddc7d){return await this['_utils']['loadRevisionData'](_0x5ddc7d,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x5ddc7d);}async['compare'](_0x1c272d,_0x4729af,_0x429414=!0x1){if(!this['isEnabled'])return;const _0x35c324=this['diff'],_0x579aad=this['repository'],_0x28e9ef='string'==typeof _0x1c272d?_0x579aad['getRevision'](_0x1c272d):_0x1c272d,_0x55af43='string'==typeof _0x4729af?_0x579aad['getRevision'](_0x4729af):_0x4729af,_0x43d4e7=_0x28e9ef['id'],_0x3bb687=_0x55af43?_0x55af43['id']:null;if(!_0x429414&&this['diff']&&this['diff']['newRevisionId']===_0x43d4e7&&this['diff']['oldRevisionId']===_0x3bb687)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new J(_0x43d4e7,_0x3bb687);const _0x48ea86=this['_getRevisionsRange'](_0x28e9ef,_0x55af43,!0x0)['map'](_0x2c5c5f=>this['_utils']['loadRevisionData'](_0x2c5c5f,this['adapter']));return _0x48ea86['push'](new Promise(_0x11316b=>{setTimeout(_0x11316b,0x14);})),Promise['all'](_0x48ea86)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x47da56=this['_getDiff'](_0x43d4e7,_0x3bb687);for(const _0x3cd108 of _0x47da56['changes'])this['_changeIdToChange']['set'](_0x3cd108['id'],_0x3cd108);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x29e249=>{for(const _0x49d530 of this['editor']['model']['document']['getRootNames']())_0x29e249['detachRoot'](_0x49d530);for(const _0x2eaec8 of Object['keys'](_0x47da56['model'])){const _0x48b3a7=_0x29e249['addRoot'](_0x2eaec8);for(const _0x2a9330 of Object['keys'](_0x47da56['attributes'][_0x2eaec8]))_0x29e249['setAttribute'](_0x2a9330,_0x47da56['attributes'][_0x2eaec8][_0x2a9330],_0x48b3a7);_0x29e249['insert'](_0x47da56['model'][_0x2eaec8],_0x48b3a7,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x47da56['changes'])),this['isReady']=!0x0;})['catch'](_0x3a92c6=>{console['error'](_0x3a92c6),this['_cleanUp'](),_0x35c324&&(this['diff']=_0x35c324),this['isReady']=!0x0;});}['addRevisionData'](_0x3bf8e1,_0x321cf8){const _0x28d7f7=this['repository']['createRevision'](_0x3bf8e1);return _0x28d7f7['on']('_update',(_0x40ac30,_0x16b463,_0x49c991)=>_0x321cf8(_0x16b463,_0x49c991,_0x28d7f7)),this['repository']['addRevision'](_0x28d7f7),_0x28d7f7;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x2a95f2=>{for(const _0x2c943f of this['editor']['model']['document']['getRootNames']())_0x2a95f2['detachRoot'](_0x2c943f);});}['_sortAndFilterDiffChanges'](_0x290a33){const _0x25d78d=[],_0xb255f1=new Map();for(const _0x28f7a7 of this['editor']['model']['document']['getRootNames']()){const _0x12781b=this['editor']['editing']['view']['getDomRoot'](_0x28f7a7);if(!_0x12781b)continue;const _0xc705b6=_0x12781b['getClientRects']()['item'](0x0);_0xc705b6&&(_0x25d78d['push'](_0x28f7a7),_0xb255f1['set'](_0x28f7a7,_0xc705b6));}return _0x25d78d['sort']((_0x4d2c17,_0x2015a3)=>{const _0x105936=_0xb255f1['get'](_0x4d2c17),_0x18e0d7=_0xb255f1['get'](_0x2015a3);return _0x105936['y']-_0x18e0d7['y']||_0x105936['x']-_0x18e0d7['x'];}),(_0x290a33=_0x290a33['filter'](_0x410430=>_0x25d78d['includes'](_0x410430['rootName'])))['sort']((_0x5a3e8e,_0x55c59a)=>_0x25d78d['indexOf'](_0x5a3e8e['rootName'])-_0x25d78d['indexOf'](_0x55c59a['rootName'])),_0x290a33;}['_makeTape'](_0x5d88e8){const _0x39bf33=Array['from'](_0x5d88e8['markers'])['filter'](([_0xd1274b,_0x44e8f1])=>_0xd1274b['startsWith']('revision:')&&!_0x44e8f1['isCollapsed']),_0x66fce=Array['from'](this['editor']['model']['createRangeIn'](_0x5d88e8)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x39bf33['length'])for(const _0x295d00 of _0x66fce){const [_0x22ced1,_0x440385]=_0x39bf33[0x0],[,_0x59989a,_0x288df5]=_0x22ced1['split'](':');if(_0x440385['end']['isEqual'](_0x295d00['nextPosition'])&&_0x39bf33['shift'](),(_0x295d00['previousPosition']['isEqual'](_0x440385['start'])||_0x295d00['previousPosition']['isAfter'](_0x440385['start']))&&('insertion'==_0x59989a?_0x295d00['isAdded']={'userId':_0x288df5}:'deletion'==_0x59989a&&(_0x295d00['isRemoved']={'userId':_0x288df5})),0x0==_0x39bf33['length'])break;}return _0x66fce;}['_refreshStartEndIndex'](_0x5c5426){const _0x479fdc=new Map();for(let _0x20736c=0x0;_0x20736c<_0x5c5426['length'];_0x20736c++)'text'===_0x5c5426[_0x20736c]['type']?(_0x5c5426[_0x20736c]['item']['startIndex']=_0x20736c,_0x5c5426[_0x20736c]['item']['endIndex']=_0x20736c):('elementStart'===_0x5c5426[_0x20736c]['type']?_0x5c5426[_0x20736c]['item']['startIndex']=_0x20736c:'elementEnd'===_0x5c5426[_0x20736c]['type']&&(_0x5c5426[_0x20736c]['item']['endIndex']=_0x20736c),_0x479fdc['set'](_0x5c5426[_0x20736c]['id'],_0x20736c));for(const _0x2e9f73 of _0x479fdc['values']())'elementStart'===_0x5c5426[_0x2e9f73]['type']?_0x5c5426[_0x2e9f73]['item']['endIndex']=_0x479fdc['get'](_0x5c5426[_0x2e9f73]['pairId']):'elementEnd'===_0x5c5426[_0x2e9f73]['type']&&(_0x5c5426[_0x2e9f73]['item']['startIndex']=_0x479fdc['get'](_0x5c5426[_0x2e9f73]['pairId']));}['_processTape'](_0x2160a0){for(let _0xa51c4f=0x0;_0xa51c4f<_0x2160a0['length'];_0xa51c4f++){if('elementStart'===_0x2160a0[_0xa51c4f]['type'])_0x2160a0[_0xa51c4f]['item']['startIndex']=_0xa51c4f;else{if('elementEnd'===_0x2160a0[_0xa51c4f]['type']){_0x2160a0[_0xa51c4f]['item']['endIndex']=_0xa51c4f;const _0xe948cc=_0x2160a0[_0xa51c4f]['item']['startIndex'];_0x2160a0[_0xe948cc]['pairId']=_0x2160a0[_0xa51c4f]['id'],_0x2160a0[_0xa51c4f]['pairId']=_0x2160a0[_0xe948cc]['id'];}else _0x2160a0[_0xa51c4f]['item']['startIndex']=_0xa51c4f,_0x2160a0[_0xa51c4f]['item']['endIndex']=_0xa51c4f,_0x2160a0[_0xa51c4f]['pairId']=null;}_0x2160a0[_0xa51c4f]['markersStart']||(_0x2160a0[_0xa51c4f]['markersStart']=[],_0x2160a0[_0xa51c4f]['markersEnd']=[]);}}['_markInsertions'](_0xe184de,_0x31fdce){const _0x3de0fd=_0xe184de['filter'](_0x4f1880=>!_0x4f1880['isAdded']);for(let _0x2ad7ac=0x0;_0x2ad7ac<_0x31fdce['length'];_0x2ad7ac++)_0x31fdce[_0x2ad7ac]['isAdded']&&(_0x3de0fd[_0x2ad7ac]['isAdded']=_0x31fdce[_0x2ad7ac]['isAdded']);}['_getDiff'](_0x27cebd,_0x3b7068=null){const _0x19c3fe=this['repository']['getRevision'](_0x27cebd),_0x1ed555=_0x3b7068?this['repository']['getRevision'](_0x3b7068):null,_0xf9aaa0=this['_getRevisionsRange'](_0x19c3fe,_0x1ed555),_0x18f517=_0xf9aaa0[_0xf9aaa0['length']-0x1],_0x40533c=new Map(),_0x5d7339={'model':{},'attributes':{},'changes':[]},_0x55a3dc=new Set(),_0x12ba6e=new Map();for(let _0x528a43=_0xf9aaa0['length']-0x1;_0x528a43>=0x0;_0x528a43--){const _0x3c266a=_0xf9aaa0[_0x528a43];for(const _0x5c6f60 of Object['keys'](_0x3c266a['diffData']))if(_0x3c266a['diffData'][_0x5c6f60]['attachChange']){const _0x4f3020=_0x3c266a['diffData'][_0x5c6f60]['attachChange'];_0x4f3020['isAttached']?(_0x55a3dc['add'](_0x5c6f60),_0x12ba6e['has'](_0x5c6f60)&&_0x12ba6e['get'](_0x5c6f60)['userId']==_0x4f3020['userId']?_0x12ba6e['delete'](_0x5c6f60):_0x12ba6e['set'](_0x5c6f60,_0x4f3020)):_0x12ba6e['has'](_0x5c6f60)?(_0x55a3dc['delete'](_0x5c6f60),_0x12ba6e['delete'](_0x5c6f60)):(_0x55a3dc['add'](_0x5c6f60),_0x12ba6e['set'](_0x5c6f60,_0x4f3020));}else _0x55a3dc['add'](_0x5c6f60);}for(const _0x1c3319 of _0x55a3dc){const _0x4ab1a8=_0x12ba6e['has'](_0x1c3319)&&!_0x12ba6e['get'](_0x1c3319)['isAttached'];let _0x4e2353=_0x4ab1a8?_0xf9aaa0['length']-0x1:0x0;const _0x1576f2=_0x4ab1a8?-0x1:0x1;for(;_0xf9aaa0[_0x4e2353];){const _0x44a593=_0xf9aaa0[_0x4e2353];if(_0x44a593['diffData'][_0x1c3319]){const _0x567057=_0x4ab1a8?_0x44a593['diffData'][_0x1c3319]['attributesBefore']:_0x44a593['diffData'][_0x1c3319]['attributesAfter'];_0x5d7339['attributes'][_0x1c3319]=_0x567057?_0x2b75d6(_0x567057):{};break;}_0x4e2353+=_0x1576f2;}}for(const _0x23d38b of _0xf9aaa0){_0x23d38b['model']={};for(const _0x2e8b17 of _0x23d38b['authors'])_0x40533c['set'](_0x2e8b17['id'],_0x2e8b17);for(const _0x3dbc81 of _0x55a3dc){const _0x3142ba=_0x23d38b['diffData'][_0x3dbc81]?_0x23d38b['diffData'][_0x3dbc81]['insertions']:'[]',_0x13a0b2=_0x23d38b['diffData'][_0x3dbc81]?_0x23d38b['diffData'][_0x3dbc81]['deletions']:'[]';_0x23d38b['model'][_0x3dbc81]={'insertions':this['_utils']['_makeModelFromViewString'](_0x3142ba),'deletions':this['_utils']['_makeModelFromViewString'](_0x13a0b2)};}}for(const _0x477545 of _0x55a3dc){let _0x3ac2ad=null,_0x275251=0x0;const _0x4ad93b=new Map(Array['from'](_0x19c3fe['model'][_0x477545]['insertions']['markers'])['filter'](([_0x43969d])=>!_0x43969d['startsWith']('revision:')));let _0x1eb0d8=0x0;for(const _0x3aa24b of _0xf9aaa0){const _0x2994f2=this['_makeTape'](_0x3aa24b['model'][_0x477545]['insertions']);_0x3aa24b==_0x19c3fe?(_0x3ac2ad=_0x2994f2,_0x275251=_0x3ac2ad['length'],_0x3ac2ad['forEach'](_0x2c8e56=>{_0x2c8e56['id']=_0x1eb0d8++;}),this['_processTape'](_0x3ac2ad)):this['_markInsertions'](_0x3ac2ad,_0x2994f2);const _0x19041=_0x3ac2ad['filter'](_0x1c9602=>!_0x1c9602['isAdded'])['map'](_0x174c63=>_0x174c63['id']);let _0x221b21=0x0;const _0x5d549c=this['_makeTape'](_0x3aa24b['model'][_0x477545]['deletions']);_0x5d549c['forEach'](_0x3b66f2=>{_0x3b66f2['isRemoved']?_0x3b66f2['id']=_0x275251++:_0x3b66f2['id']=_0x19041[_0x221b21++];}),this['_processTape'](_0x5d549c),this['_setDistance'](_0x3ac2ad,'isAdded'),this['_setDistance'](_0x5d549c,'isRemoved'),_0x3aa24b==_0x19c3fe&&this['_markMarkers'](_0x3ac2ad,_0x4ad93b),_0x3ac2ad=this['_joinTapes'](_0x3ac2ad,_0x5d549c),this['_refreshStartEndIndex'](_0x3ac2ad),this['_setDistance'](_0x3ac2ad,'isRemoved');}_0x3ac2ad=_0x3ac2ad['filter'](_0x2d9f59=>!(_0x2d9f59['isAdded']&&_0x2d9f59['isRemoved']));const _0x1b1d3e=new Map(_0x18f517['model'][_0x477545]['deletions']['markers']),_0x28d626=new Set(_0x4ad93b['keys']());for(const _0x5b90a6 of _0x1b1d3e['keys']())_0x28d626['delete'](_0x5b90a6);this['_markSuggestions'](_0x3ac2ad,_0x28d626),this['_fixObsoleteTags'](_0x3ac2ad),_0x3ac2ad=this['_removeMissingPairs'](_0x3ac2ad),_0x3ac2ad=this['_markMismatchedRemovedTags'](_0x3ac2ad),_0x3ac2ad=this['_removeUnsupportedChanges'](_0x3ac2ad);const {root:_0x5ee7fe,changes:_0x5e65cd}=this['_makeModelFromTape'](_0x3ac2ad,_0x40533c,_0x477545);_0x5d7339['model'][_0x477545]=_0x5ee7fe;const _0x3f929f=_0x12ba6e['get'](_0x477545);if(_0x3f929f){const _0x8ab5c4=_0x40533c['get'](_0x3f929f['userId']),_0x24f5a9=new G({'author':_0x8ab5c4,'type':_0x3f929f['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x477545});_0x5e65cd['unshift'](_0x24f5a9),_0x5d7339['attributes'][_0x477545]['revisionHistoryAttachChange']=_0x24f5a9['id'];}_0x5d7339['changes']=_0x5d7339['changes']['concat'](_0x5e65cd);}return _0x5d7339;}['_markMarkers'](_0x537776,_0x2b9a05){for(let _0x599bf8=0x0;_0x599bf8<_0x537776['length'];_0x599bf8++)for(const [_0xaa003a,_0x32b568]of _0x2b9a05)!_0x32b568['isCollapsed']&&_0x32b568['start']['isEqual'](_0x537776[_0x599bf8]['previousPosition'])&&_0x537776[_0x599bf8]['markersStart']['push'](_0xaa003a),_0x32b568['end']['isEqual'](_0x537776[_0x599bf8]['nextPosition'])&&_0x537776[_0x599bf8]['markersEnd']['push'](_0xaa003a);}['_joinTapes'](_0x38e666,_0x2fa61e){let _0x4cbdff=[],_0x37ac86=0x0,_0x16c52f=0x0;for(;_0x37ac86<_0x38e666['length']||_0x16c52f<_0x2fa61e['length'];){const _0x36d78c=_0x38e666[_0x37ac86]||{},_0x5981fb=_0x2fa61e[_0x16c52f]||{};if(_0x36d78c['id']==_0x5981fb['id'])_0x37ac86++,_0x16c52f++,_0x4cbdff['push'](_0x36d78c);else{if(_0x5981fb['isRemoved']&&_0x36d78c['isAdded']){const {commonTape:_0x4c7527,iEnd:_0x185e18,jEnd:_0x3f1526}=this['_threeWayMerge'](_0x38e666,_0x37ac86,_0x2fa61e,_0x16c52f);_0x4cbdff=_0x4cbdff['concat'](_0x4c7527),_0x37ac86=_0x185e18,_0x16c52f=_0x3f1526;}else _0x5981fb['isRemoved']?(_0x16c52f++,_0x4cbdff['push'](_0x5981fb)):(_0x37ac86++,_0x4cbdff['push'](_0x36d78c));}}return _0x4cbdff;}['_markSuggestions'](_0x39b513,_0x5c6615){const _0x1b4ed5=[];for(let _0xc75f28=0x0;_0xc75f28<_0x39b513['length'];_0xc75f28++){for(let _0x5c4762=0x0;_0x5c4762<_0x39b513[_0xc75f28]['markersStart']['length'];_0x5c4762++){const _0x278409=_0x39b513[_0xc75f28]['markersStart'][_0x5c4762];if(!_0x5c6615['has'](_0x278409))continue;const {group:_0x11eea8,type:_0x2706da,authorId:_0x1c35ef}=_0x55df35(_0x278409);'revision-suggestion'!=_0x11eea8||'insertion'!=_0x2706da&&'deletion'!=_0x2706da||(_0x1b4ed5['unshift']({'type':_0x2706da,'name':_0x278409,'userId':_0x1c35ef}),_0x39b513[_0xc75f28]['markersStart']['splice'](_0x5c4762,0x1),_0x5c4762--);}_0x77c0b7(_0x39b513[_0xc75f28]);for(let _0x310c65=0x0;_0x310c65<_0x39b513[_0xc75f28]['markersEnd']['length'];_0x310c65++){const _0x3e72af=_0x39b513[_0xc75f28]['markersEnd'][_0x310c65];if(!_0x5c6615['has'](_0x3e72af))continue;const {group:_0x155cb5,type:_0x13d6cc}=_0x55df35(_0x3e72af);if('revision-suggestion'!=_0x155cb5||'insertion'!=_0x13d6cc&&'deletion'!=_0x13d6cc)continue;_0x39b513[_0xc75f28]['markersEnd']['splice'](_0x310c65,0x1),_0x310c65--;const _0x87f172=_0x1b4ed5['findIndex'](_0x4cbdbb=>_0x4cbdbb['name']==_0x3e72af);_0x87f172>-0x1&&_0x1b4ed5['splice'](_0x87f172,0x1);}}function _0x55df35(_0x460f1e){const _0x59a35d=_0x460f1e['split'](':');return{'group':_0x59a35d[0x0],'type':_0x59a35d[0x1],'subType':_0x59a35d['length']>=0x5?_0x59a35d[0x2]:null,'id':_0x59a35d['length']<0x5?_0x59a35d[0x2]:_0x59a35d[0x3],'authorId':_0x59a35d['length']<0x5?_0x59a35d[0x3]:_0x59a35d[0x4],'markerCount':0x6==_0x59a35d['length']?_0x59a35d[0x5]:null};}function _0x77c0b7(_0x4eb7fe){for(let _0x2c9fc1=0x0;_0x2c9fc1<_0x1b4ed5['length'];_0x2c9fc1++){if(_0x4eb7fe['isAdded']&&'insertion'==_0x1b4ed5[_0x2c9fc1]['type']&&_0x4eb7fe['isAdded']['userId']==_0x1b4ed5[_0x2c9fc1]['userId'])return _0x4eb7fe['isAddSuggestion']=_0x1b4ed5[_0x2c9fc1],void delete _0x4eb7fe['isAdded'];if(!_0x4eb7fe['isAdded']&&!_0x4eb7fe['isRemoved']&&'deletion'==_0x1b4ed5[_0x2c9fc1]['type'])return void(_0x4eb7fe['isRemoveSuggestion']=_0x1b4ed5[_0x2c9fc1]);}}}['_setDistance'](_0x524c28,_0xcbe678){let _0x31f9fb=0x0,_0x3bdd4b=!0x1;const _0x40018a=new Map();for(const _0x4a0af2 of _0x524c28)_0x4a0af2[_0xcbe678]?_0x3bdd4b&&(_0x31f9fb++,_0x3bdd4b=!0x1):(_0x31f9fb++,_0x3bdd4b=!0x0),_0x40018a['set'](_0x4a0af2['id'],_0x31f9fb);for(let _0x29449a=0x0;_0x29449a<_0x524c28['length'];_0x29449a++){if('isRemoved'==_0xcbe678&&_0x524c28[_0x29449a]['isAdded']||'isAdded'==_0xcbe678&&_0x524c28[_0x29449a]['isRemoved'])continue;if('text'==_0x524c28[_0x29449a]['type']){_0x524c28[_0x29449a]['distance']=0x0;continue;}const _0x2945bc=_0x40018a['get'](_0x524c28[_0x29449a]['pairId']),_0xe9628b=_0x40018a['get'](_0x524c28[_0x29449a]['id']);_0x524c28[_0x29449a]['distance']=_0x2945bc-_0xe9628b;}}['_getRevisionsRange'](_0x49888d,_0x8705b,_0xe4de7f=!0x1){const _0x47010a=[];let _0x38c3d7=this['repository']['getIndex'](_0x49888d),_0x3aecd9=this['repository']['getIndex'](_0x8705b);for(-0x1==_0x3aecd9&&(_0x3aecd9=this['repository']['_revisions']['length'],_0xe4de7f=!0x1);_0x38c3d7<_0x3aecd9;)_0x47010a['push'](this['repository']['getRevision'](_0x38c3d7)),_0x38c3d7++;return _0xe4de7f&&_0x47010a['push'](this['repository']['getRevision'](_0x38c3d7)),_0x47010a;}['_threeWayMerge'](_0x4776e4,_0x24e38d,_0x24df9e,_0x55eb98){const _0x42d8f2=this['editor']['model']['schema'];let _0x13ad62=_0x24e38d;for(;_0x4776e4[_0x13ad62]&&_0x4776e4[_0x13ad62]['isAdded'];)_0x13ad62++;let _0x29bfd6=_0x55eb98;for(;_0x24df9e[_0x29bfd6]&&_0x24df9e[_0x29bfd6]['isRemoved'];)_0x29bfd6++;_0x1b528b(_0x4776e4,_0x24e38d,_0x13ad62),_0x1b528b(_0x24df9e,_0x55eb98,_0x29bfd6);const _0x5090ce=_0x24df9e['slice'](_0x55eb98,_0x29bfd6)['concat'](_0x4776e4['slice'](_0x24e38d,_0x13ad62));return _0x5090ce['sort']((_0x288205,_0x5c2551)=>_0x288205['side']!=_0x5c2551['side']?_0x288205['side']-_0x5c2551['side']:_0x288205['level']!=_0x5c2551['level']?_0x288205['level']-_0x5c2551['level']:_0x288205['distance']!=_0x5c2551['distance']?_0x5c2551['distance']-_0x288205['distance']:!!_0x288205['isAdded']!=!!_0x5c2551['isAdded']?-0x1==_0x288205['side']||0x0==_0x288205['side']?_0x288205['isAdded']?-0x1:0x1:_0x288205['isAdded']?0x1:-0x1:_0x288205['index']-_0x5c2551['index']),{'commonTape':_0x5090ce,'iEnd':_0x13ad62,'jEnd':_0x29bfd6};function _0x1b528b(_0x1e7a9c,_0x169b34,_0x17c683){let _0x442aef=-0x1,_0xf6d0a9=Number['POSITIVE_INFINITY'],_0x2400ce=!0x0;for(let _0xcba6bf=_0x169b34;_0xcba6bf<_0x17c683;_0xcba6bf++)if(_0x42d8f2['isInline'](_0x1e7a9c[_0xcba6bf]['item'])||(_0x2400ce=!0x1),_0x1e7a9c[_0xcba6bf]['item']['startIndex']<_0x169b34&&(_0x442aef=_0xcba6bf),_0x1e7a9c[_0xcba6bf]['item']['endIndex']>=_0x17c683){_0xf6d0a9=_0xcba6bf;break;}_0x2400ce&&(_0x442aef=_0x17c683-0x1);for(let _0x33f6c0=_0x169b34;_0x33f6c0<_0x17c683;_0x33f6c0++)_0x1e7a9c[_0x33f6c0]['side']=_0x33f6c0<=_0x442aef?-0x1:_0x33f6c0<_0xf6d0a9?0x0:0x1,_0x1e7a9c[_0x33f6c0]['index']=_0x33f6c0;let _0x2ac190=0x0;for(let _0x440f2f=_0x169b34;_0x440f2f<=_0x442aef;_0x440f2f++)0x0==_0x1e7a9c[_0x440f2f]['distance']?_0x1e7a9c[_0x440f2f]['level']=_0x2ac190:(_0x2ac190++,_0x1e7a9c[_0x440f2f]['level']=_0x2ac190,_0x2ac190++);for(let _0x52123c=_0x169b34;_0x52123c<_0x17c683;_0x52123c++)0x0==_0x1e7a9c[_0x52123c]['side']&&(_0x1e7a9c[_0x52123c]['level']=_0x2ac190);_0x2ac190=0x0;for(let _0x40b297=_0x17c683-0x1;_0x40b297>=_0xf6d0a9;_0x40b297--)0x0==_0x1e7a9c[_0x40b297]['distance']?_0x1e7a9c[_0x40b297]['level']=_0x2ac190:(_0x2ac190--,_0x1e7a9c[_0x40b297]['level']=_0x2ac190,_0x2ac190--);}}['_fixObsoleteTags'](_0x35b594){const _0x91db2f=new Map(),_0x5aa413=this['editor']['model']['schema'];for(let _0x2f2c65=0x1;_0x2f2c65<_0x35b594['length'];_0x2f2c65++){let _0x48453d,_0x369398,_0x30549f;const _0x1dc2ab=_0x35b594[_0x2f2c65],_0x54a386=_0x35b594[_0x2f2c65-0x1];if('text'==_0x1dc2ab['type'])continue;if(_0x1dc2ab['type']!=_0x54a386['type'])continue;if(!_0x5aa413['isBlock'](_0x54a386['item'])||_0x5aa413['isLimit'](_0x54a386['item']))continue;if(!_0x5aa413['isBlock'](_0x1dc2ab['item'])||_0x5aa413['isLimit'](_0x1dc2ab['item']))continue;if((_0x35b594[_0x2f2c65]['isAdded']||_0x35b594[_0x2f2c65]['isAddSuggestion'])&&_0x35b594[_0x2f2c65-0x1]['isRemoved'])_0x48453d=_0x35b594[_0x2f2c65],_0x369398=_0x35b594[_0x2f2c65-0x1],_0x30549f=_0x2f2c65-0x1;else{if(!_0x35b594[_0x2f2c65]['isRemoved']||!_0x35b594[_0x2f2c65-0x1]['isAdded']&&!_0x35b594[_0x2f2c65-0x1]['isAddSuggestion'])continue;_0x48453d=_0x35b594[_0x2f2c65-0x1],_0x369398=_0x35b594[_0x2f2c65],_0x30549f=_0x2f2c65;}const _0x545519=_0x48453d['level']==_0x369398['level'],_0x5dfd86=Math['abs'](_0x48453d['level'])<Math['abs'](_0x369398['level'])&&0x0==_0x369398['distance'];(_0x545519||_0x5dfd86)&&(_0x91db2f['set'](_0x369398['id'],_0x48453d['id']),_0x35b594['splice'](_0x30549f,0x1),_0x2f2c65--,_0x48453d['isAdded']=!0x1);}for(let _0x2bc37a=0x0;_0x2bc37a<_0x35b594['length'];_0x2bc37a++)_0x91db2f['has'](_0x35b594[_0x2bc37a]['pairId'])&&(_0x35b594[_0x2bc37a]['pairId']=_0x91db2f['get'](_0x35b594[_0x2bc37a]['pairId']));}['_removeMissingPairs'](_0x469b3d){const _0xc09700=new Set(_0x469b3d['map'](_0x30873f=>_0x30873f['id']));for(let _0x192c6a=0x0;_0x192c6a<_0x469b3d['length'];_0x192c6a++)_0xc09700['has'](_0x469b3d[_0x192c6a]['pairId'])||0x0==_0x469b3d[_0x192c6a]['distance']||(_0x469b3d[_0x192c6a]['isIncorrect']=!0x0);return _0x469b3d['filter'](_0x20c8ad=>!_0x20c8ad['isIncorrect']);}['_markMismatchedRemovedTags'](_0x546f48){const _0xa6422=new Set();for(let _0x226129=0x0;_0x226129<_0x546f48['length'];_0x226129++){if(_0xa6422['has'](_0x546f48[_0x226129]['id'])&&_0x546f48[_0x226129]['isRemoved']&&(_0x546f48[_0x226129]['isIncorrect']=!0x0),_0x546f48[_0x226129]['isIncorrect'])continue;if(0x0==_0x546f48[_0x226129]['distance'])continue;if('elementStart'!=_0x546f48[_0x226129]['type'])continue;if(null==_0x546f48[_0x226129]['pairId'])continue;let _0x8fab52=_0x226129+0x1,_0x3a11b9=0x0;for(;_0x546f48[_0x8fab52]['id']!=_0x546f48[_0x226129]['pairId'];)'elementStart'==_0x546f48[_0x8fab52]['type']?_0x3a11b9++:'elementEnd'==_0x546f48[_0x8fab52]['type']&&_0x3a11b9--,_0x8fab52++;if(0x0!=_0x3a11b9){if(_0x546f48[_0x226129]['isRemoved'])_0x546f48[_0x226129]['isIncorrect']=!0x0;else{for(;_0x8fab52!=_0x226129;)_0x546f48[_0x8fab52]['isRemoved']&&0x0!=_0x546f48[_0x8fab52]['distance']&&(_0x546f48[_0x8fab52]['isIncorrect']=!0x0,_0xa6422['add'](_0x546f48[_0x8fab52]['pairId'])),_0x8fab52--;}}}return _0x546f48['filter'](_0xcde37a=>!_0xcde37a['isIncorrect']);}['_removeUnsupportedChanges'](_0x23fefa){const _0x402db6=this['editor']['model']['schema'];for(let _0x157d1d=0x0;_0x157d1d<_0x23fefa['length'];_0x157d1d++){if(!(_0x23fefa[_0x157d1d]['isAdded']||_0x23fefa[_0x157d1d]['isAddSuggestion']||_0x23fefa[_0x157d1d]['isRemoved']||_0x23fefa[_0x157d1d]['isRemoveSuggestion']))continue;if(0x0==_0x23fefa[_0x157d1d]['distance'])continue;const _0x922c24=_0x23fefa[_0x157d1d]['item'];_0x402db6['isBlock'](_0x922c24)||_0x402db6['isLimit'](_0x922c24)||(_0x23fefa[_0x157d1d]['isAdded']&&delete _0x23fefa[_0x157d1d]['isAdded'],_0x23fefa[_0x157d1d]['isAddSuggestion']&&delete _0x23fefa[_0x157d1d]['isAddSuggestion'],_0x23fefa[_0x157d1d]['isRemoveSuggestion']&&delete _0x23fefa[_0x157d1d]['isRemoveSuggestion'],_0x23fefa[_0x157d1d]['isRemoved']&&(_0x23fefa[_0x157d1d]['isIncorrect']=!0x0));}return _0x23fefa['filter'](_0x47651e=>!_0x47651e['isIncorrect']);}['_makeModelFromTape'](_0x2bdb2a,_0x6a452e,_0xe58510){const _0x4028d9=new _0x3a58c7(),_0x2ac552=[],_0xd119cd=new Map(),_0x585720=this['editor']['model'],_0x129807=_0x585720['schema'],_0x57da44=[_0x4028d9],_0x491330={},_0x3e6d71={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x21917c=null;const _0x25bcc9=[0x0];for(let _0x3089a6=0x0;_0x3089a6<_0x2bdb2a['length'];_0x3089a6++)if('elementStart'===_0x2bdb2a[_0x3089a6]['type']){_0x2bdb2a[_0x3089a6]['previousPosition']=_0x585720['createPositionFromPath'](_0x4028d9,_0x25bcc9);const _0x1bbb8d=new _0x3061f3(_0x2bdb2a[_0x3089a6]['item']['name'],_0x2bdb2a[_0x3089a6]['item']['getAttributes']());_0x57da44[0x0]['_appendChild'](_0x1bbb8d),_0x25bcc9['push'](0x0),_0x57da44['unshift'](_0x1bbb8d),_0x2bdb2a[_0x3089a6]['nextPosition']=_0x585720['createPositionFromPath'](_0x4028d9,_0x25bcc9);}else'elementEnd'===_0x2bdb2a[_0x3089a6]['type']?(_0x57da44['shift'](),_0x2bdb2a[_0x3089a6]['previousPosition']=_0x585720['createPositionFromPath'](_0x4028d9,_0x25bcc9),_0x25bcc9['pop'](),_0x25bcc9[_0x25bcc9['length']-0x1]++,_0x2bdb2a[_0x3089a6]['nextPosition']=_0x585720['createPositionFromPath'](_0x4028d9,_0x25bcc9)):(_0x2bdb2a[_0x3089a6]['previousPosition']=_0x585720['createPositionFromPath'](_0x4028d9,_0x25bcc9),_0x21917c?_0x21917c['_data']+=_0x2bdb2a[_0x3089a6]['item']['data']:_0x21917c=new _0x54876f(_0x2bdb2a[_0x3089a6]['item']['data'],_0x2bdb2a[_0x3089a6]['item']['getAttributes']()),_0x2bdb2a[_0x3089a6+0x1]&&'text'===_0x2bdb2a[_0x3089a6+0x1]['type']&&_0x3e673b(_0x21917c,_0x2bdb2a[_0x3089a6+0x1]['item'])||(_0x57da44[0x0]['_appendChild'](_0x21917c),_0x21917c=null),_0x25bcc9[_0x25bcc9['length']-0x1]+=_0x2bdb2a[_0x3089a6]['item']['offsetSize'],_0x2bdb2a[_0x3089a6]['nextPosition']=_0x585720['createPositionFromPath'](_0x4028d9,_0x25bcc9));for(let _0x348324=0x0;_0x348324<_0x2bdb2a['length'];_0x348324++){const _0x38c591=_0x2bdb2a[_0x348324]['previousPosition'],_0xe31d98=_0x2bdb2a[_0x348324]['nextPosition'];for(const _0x236a1a of _0x2bdb2a[_0x348324]['markersStart'])_0xd119cd['set'](_0x236a1a,{'start':_0x38c591,'end':null});_0x10dbf3('isRemoveSuggestion',_0x348324,_0x38c591,_0xe31d98),_0x10dbf3('isAddSuggestion',_0x348324,_0x38c591,_0xe31d98),_0x10dbf3('isRemoved',_0x348324,_0x38c591,_0xe31d98),_0x10dbf3('isAdded',_0x348324,_0x38c591,_0xe31d98);for(const _0x461892 of _0x2bdb2a[_0x348324]['markersEnd']){const _0x402705=_0xd119cd['get'](_0x461892);_0x402705?_0x402705['end']=_0xe31d98:_0xd119cd['set'](_0x461892,{'start':_0xe31d98,'end':_0xe31d98});}}for(const [_0x4d8f30,_0x5d94b2]of _0xd119cd){const _0x36ce85=this['editor']['model']['createRange'](_0x5d94b2['start'],_0x5d94b2['end']);_0x4028d9['markers']['set'](_0x4d8f30,_0x36ce85);}return _0x2ac552['sort']((_0x19a4e0,_0x3bfa6f)=>{const _0x3def93=_0x4028d9['markers']['get']('revision:'+_0x19a4e0['id']),_0x26d11d=_0x4028d9['markers']['get']('revision:'+_0x3bfa6f['id']);return _0x3def93['start']['isBefore'](_0x26d11d['start'])?-0x1:_0x3def93['start']['isAfter'](_0x26d11d['start'])?0x1:_0x3def93['end']['isBefore'](_0x26d11d['end'])?-0x1:_0x3def93['end']['isAfter'](_0x26d11d['end'])?0x1:'add'===_0x19a4e0['type']?-0x1:0x1;}),{'root':_0x4028d9,'changes':_0x2ac552};function _0x10dbf3(_0x4f6619,_0x21147c,_0x2ea131,_0x52b1c6){const _0x21b686=!!_0x2bdb2a[_0x21147c][_0x4f6619],_0xb36863=_0x21b686?_0x2bdb2a[_0x21147c][_0x4f6619]['userId']:null,_0x411583=_0x21147c===_0x2bdb2a['length']-0x1,_0x18f901=_0x3e6d71[_0x4f6619][0x0],_0x15ff5a=_0x129807['isObject'](_0x2bdb2a[_0x21147c]['item']);!_0x491330[_0x4f6619]&&_0x21b686?_0x491330[_0x4f6619]={'start':_0x2ea131,'tapeItem':_0x2bdb2a[_0x21147c],'userId':_0xb36863,'type':_0x4f6619}:_0x491330[_0x4f6619]&&!_0x21b686?(_0x491330[_0x4f6619]['end']=_0x2ea131,_0x252f93(_0x491330[_0x4f6619]),_0x491330[_0x4f6619]=null):_0x491330[_0x4f6619]&&_0x21b686&&_0x491330[_0x4f6619]['userId']!==_0xb36863&&(_0x491330[_0x4f6619]['end']=_0x2ea131,_0x18f901&&_0x18f901['userId']===_0x491330[_0x4f6619]['userId']||_0x252f93(_0x491330[_0x4f6619]),_0x491330[_0x4f6619]={'start':_0x2ea131,'tapeItem':_0x2bdb2a[_0x21147c],'userId':_0xb36863,'type':_0x4f6619}),_0x491330[_0x4f6619]&&_0x15ff5a&&('elementStart'!==_0x2bdb2a[_0x21147c]['type']||_0x18f901&&_0x18f901['userId']===_0xb36863||_0x3e6d71[_0x4f6619]['unshift']({'userId':_0xb36863,'object':_0x2bdb2a[_0x21147c]['item'],'change':_0x491330[_0x4f6619]}),'elementEnd'===_0x2bdb2a[_0x21147c]['type']&&_0x18f901&&_0x18f901['object']===_0x2bdb2a[_0x21147c]['item']&&(_0x3e6d71[_0x4f6619]['shift'](),_0x491330[_0x4f6619]=_0x18f901['change'])),_0x491330[_0x4f6619]&&_0x411583&&(_0x491330[_0x4f6619]['end']=_0x52b1c6,_0x252f93(_0x491330[_0x4f6619]),_0x491330[_0x4f6619]=null);}function _0x252f93({start:_0x189f4f,end:_0x3764d2,tapeItem:_0x56e6f9,userId:_0x18e689,type:_0x431c57}){const _0x5632cd=_0x56e6f9['item'],_0x35b3ac=_0x585720['schema']['isBlock'](_0x5632cd)&&!_0x585720['schema']['isLimit'](_0x5632cd),_0x12cf18=_0x189f4f['nodeAfter']==_0x3764d2['parent']&&_0x3764d2['isAtStart'];if(_0x35b3ac&&_0x12cf18)return;const _0x2cf88d=_0x585720['createRange'](_0x189f4f,_0x3764d2),_0x9706e=_0x6a452e['get'](_0x18e689),_0x724dd4=new G({'author':_0x9706e,'type':'isAdded'==_0x431c57||'isAddSuggestion'==_0x431c57?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x431c57||'isRemoveSuggestion'==_0x431c57},'createdAt':new Date(),'rootName':_0xe58510});_0x2ac552['push'](_0x724dd4),_0x4028d9['markers']['set']('revision:'+_0x724dd4['id'],_0x2cf88d);}function _0x3e673b(_0x1fbcae,_0x10a17d){const _0x4f462f=_0x1fbcae['getAttributes'](),_0x4fe22e=_0x10a17d['getAttributes']();for(const _0x547d3f of _0x4f462f){if(_0x547d3f[0x1]!==_0x10a17d['getAttribute'](_0x547d3f[0x0]))return!0x1;_0x4fe22e['next']();}return _0x4fe22e['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x26b7c0=>{const _0x1b5d6d=_0x26b7c0['markerName']['split'](':')[0x1],_0x4170cb=this['_getChangeFromId'](_0x1b5d6d);if(!_0x4170cb)return null;const _0x3c5657='add'==_0x4170cb['type']?'insertion':'deletion',_0x4df617=['ck-suggestion-marker','ck-suggestion-marker-'+_0x3c5657];return _0x4170cb['data']['isSuggestion']&&_0x4df617['push']('ck-suggestion-marker-'+_0x3c5657+'-new'),this['activeChange']==_0x4170cb&&_0x4df617['push']('ck-suggestion-marker--active'),{'classes':_0x4df617,'attributes':{'data-change-id':_0x1b5d6d}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x447ec3=>{_0x447ec3['on']('element:pre',(_0x228f6d,_0x24240c,_0x192b10)=>{const _0x19828a=_0x24240c['viewItem']['getChild'](0x0);if(!_0x19828a||!_0x19828a['is']('element','code'))return;if(!_0x192b10['consumable']['consume'](_0x19828a,{'attributes':['vid_start','vid_end']}))return;const _0x536502=_0x24240c['modelRange']['start']['nodeAfter'];_0x192b10['writer']['setAttribute']('vid_start',_0x19828a['getAttribute']('vid_start'),_0x536502),_0x192b10['writer']['setAttribute']('vid_end',_0x19828a['getAttribute']('vid_end'),_0x536502);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x3ff276=>{_0x3ff276['on']('element',(_0x2acf8e,_0x4aca0e,_0x3a1c1b)=>{if(!_0x3a1c1b['consumable']['consume'](_0x4aca0e['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x4aca0e['modelRange']['isCollapsed'])return;const _0x347779=_0x4aca0e['modelRange']['start']['nodeAfter'];_0x347779['hasAttribute']('vid_start')||_0x347779['hasAttribute']('vid')||(_0x3a1c1b['writer']['setAttribute']('vid_start',_0x4aca0e['viewItem']['getAttribute']('vid_start'),_0x347779),_0x3a1c1b['writer']['setAttribute']('vid_end',_0x4aca0e['viewItem']['getAttribute']('vid_end'),_0x347779));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x39901a=>_0x39901a['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x1ba4ef,[,_0x281165])=>{['vid_start','vid_end','vid']['includes'](_0x281165)&&(_0x1ba4ef['return']=!0x0,_0x1ba4ef['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x1c493a=>{_0x1c493a['on']('attribute:vid',(_0x482aa8,_0x19fcf6,_0x2cc074)=>{if('\x20'!=_0x19fcf6['item']['data']||_0x19fcf6['item']['parent']['maxOffset']>0x1)return;if(!_0x2cc074['consumable']['consume'](_0x19fcf6['item'],_0x482aa8['name']))return;const _0x2bd83a=_0x2cc074['writer'],_0x2c3a56=_0x2cc074['mapper']['toViewRange'](_0x19fcf6['range']);_0x2bd83a['wrap'](_0x2c3a56,_0x2bd83a['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x4e592d){const _0x381b9e=_0x4e592d['plugins']['get']('RevisionViewer');return(_0x4c9e01,_0x4ee834,_0x1a1678)=>{const _0x2f9869=_0x4ee834['markerName']['split'](':')[0x1],_0x45743e=_0x381b9e['_getChangeFromId'](_0x2f9869);if(!_0x45743e)return null;const _0x14756a='add'==_0x45743e['type']?'split':'merge';if(!_0x1a1678['consumable']['test'](_0x4ee834['markerRange'],_0x4c9e01['name']))return;const _0x1965ad=_0x4ee834['markerRange']['getWalker'](),_0x493347=_0x4ee834['markerRange']['start'],_0x1da131=_0x4e592d['model']['schema'];let _0x373a6f=null,_0x516709=null,_0xb456ef=!0x1,_0x151b7e=!0x1;for(const _0xd943dc of _0x1965ad){const _0x50c7c5=_0xd943dc['item'];_0xb456ef=_0xb456ef||_0x1da131['isContent'](_0x50c7c5);const _0xdaefdd=_0x1a1678['mapper']['toViewElement'](_0x50c7c5);if(_0xdaefdd&&_0xdaefdd['getCustomProperty']('addHighlight'))return;'elementEnd'==_0xd943dc['type']&&(_0x1da131['isBlock'](_0x50c7c5)&&!_0x1da131['isLimit'](_0x50c7c5)&&(_0x50c7c5['nextSibling']||_0x493347['isAtEnd']?_0x373a6f&&_0x373a6f['parent']==_0x50c7c5||(_0x373a6f=_0x50c7c5,_0x3f6883(_0xd943dc['previousPosition']),_0x151b7e=!0x0):_0x516709=_0x516709||_0xd943dc['previousPosition']));}function _0x3f6883(_0x17d1fa){const _0x5f2866=_0x1a1678['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x14756a}),_0x501e89=_0x1a1678['mapper']['toViewPosition'](_0x17d1fa);_0x45743e['data']['isSuggestion']&&_0x1a1678['writer']['addClass']('ck-suggestion-marker-'+_0x14756a+'-new',_0x5f2866),_0x381b9e['activeChange']==_0x45743e&&_0x1a1678['writer']['addClass']('ck-suggestion-marker--active',_0x5f2866),_0x1a1678['writer']['insert'](_0x501e89,_0x5f2866),_0x1a1678['mapper']['bindElementToMarker'](_0x5f2866,_0x4ee834['markerName']);}_0xb456ef||_0x151b7e||!_0x516709||_0x3f6883(_0x516709);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x447b0b,_0x5f1406,_0x1dab7d)=>{const _0x15faa7=_0x1dab7d['mapper']['markerNameToElements'](_0x5f1406['markerName']);if(_0x15faa7){for(const _0x48dab1 of _0x15faa7)(_0x48dab1['hasClass']('ck-suggestion-marker-split')||_0x48dab1['hasClass']('ck-suggestion-marker-merge'))&&(_0x1dab7d['mapper']['unbindElementFromMarkerName'](_0x48dab1,_0x5f1406['markerName']),_0x1dab7d['writer']['remove'](_0x48dab1));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x1a16eb,_0x13d0ba,_0x5b3291)=>{const _0x46789a=_0x13d0ba['markerName']['split'](':')[0x1],_0x797306=this['_getChangeFromId'](_0x46789a);if(!_0x797306)return null;const _0x54e0e0='add'==_0x797306['type']?'split':'merge';if(_0x5b3291['consumable']['test'](_0x13d0ba['markerRange'],_0x1a16eb['name']))for(const _0x1fe8cf of _0x13d0ba['markerRange']['getItems']()){if(!_0x1fe8cf['is']('element','softBreak'))continue;const _0x20356b=_0x5b3291['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x54e0e0}),_0x5b5551=_0x5b3291['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x1fe8cf));_0x797306['data']['isSuggestion']&&_0x5b3291['writer']['addClass']('ck-suggestion-marker-'+_0x54e0e0+'-new',_0x20356b),this['activeChange']==_0x797306&&_0x5b3291['writer']['addClass']('ck-suggestion-marker--active',_0x20356b),_0x5b3291['writer']['insert'](_0x5b5551,_0x20356b),_0x5b3291['mapper']['bindElementToMarker'](_0x20356b,_0x13d0ba['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x4c8fc1=>{for(const _0x3e8626 of this['editor']['model']['document']['getRootNames']()){const _0xc1b30=this['editor']['model']['document']['getRoot'](_0x3e8626),_0x51a44a=this['editor']['editing']['view']['document']['getRoot'](_0x3e8626);if(_0x51a44a){const _0x508343=_0xc1b30['getAttribute']('revisionHistoryAttachChange');if(_0x4c8fc1['removeAttribute']('data-change-id',_0x51a44a),_0x4c8fc1['removeClass']('ck-revision-history-root-add',_0x51a44a),_0x4c8fc1['removeClass']('ck-revision-history-root-remove',_0x51a44a),_0x4c8fc1['removeClass']('ck-revision-history-root--active',_0x51a44a),_0x508343){const _0x387a58=this['_getChangeFromId'](_0x508343);if(!_0x387a58)return null;_0x4c8fc1['setAttribute']('data-change-id',_0x508343,_0x51a44a),_0x4c8fc1['addClass']('ck-revision-history-root-'+_0x387a58['type'],_0x51a44a),this['activeChange']==_0x387a58&&_0x4c8fc1['addClass']('ck-revision-history-root--active',_0x51a44a);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x1004c1=>'revision-comment:'+_0x1004c1,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x17153a=>'revision-suggestion:'+_0x17153a,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x127be0=>({'name':'suggestion:'+_0x127be0,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x3b7489=>{const _0x48c88f=_0x3b7489['markerName']['split'](':')[0x1];return'insertion'!=_0x48c88f&&'deletion'!=_0x48c88f?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x48c88f]};}}),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',(_0x519e66,_0x4b8975,_0x56a366)=>{const _0x59207f=_0x56a366['mapper']['markerNameToElements'](_0x4b8975['markerName']);if(_0x59207f){for(const _0x53fca3 of _0x59207f)_0x53fca3['is']('uiElement')&&(_0x56a366['mapper']['unbindElementFromMarkerName'](_0x53fca3,_0x4b8975['markerName']),_0x56a366['writer']['remove'](_0x53fca3));}},{'priority':'high'});}['_getChangeFromId'](_0x421e74){return this['_changeIdToChange']['get'](_0x421e74);}['_getViewForChange'](_0x12a39d){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new z(this['editor']['locale'],_0x12a39d),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x13ee28,_0x46891a,_0x497792,_0xdcc80e)=>{_0xdcc80e&&this['_balloon']['remove'](_0xdcc80e),_0x497792&&(this['_balloon']['add']({'view':_0x497792,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x5de825=this['editor']['editing'],_0x39ceba=this['_getChangeFromId'](_0x497792['changeId']);let _0x24760f;if(_0x39ceba['data']['isOnRoot']){const _0x2b851c=_0x5de825['view']['getDomRoot'](_0x39ceba['rootName']);_0x24760f=Array['from'](_0x2b851c['getClientRects']());}else{const _0x5af7f8=this['editor']['model']['markers']['get']('revision:'+_0x497792['changeId']);_0x24760f=Array['from'](_0x5de825['mapper']['markerNameToElements'](_0x5af7f8['name']))['map'](_0x3ab224=>_0x5de825['view']['domConverter']['mapViewToDom'](_0x3ab224))['map'](_0x124e18=>Array['from'](_0x124e18['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x24760f[0x0];return _0x24760f['find'](_0x30d64f=>_0x30d64f['top']-0x3<=this['_activeViewTarget']['y']&&_0x30d64f['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x30d64f['left']-0x3<=this['_activeViewTarget']['x']&&_0x30d64f['right']+0x3>=this['_activeViewTarget']['x'])||_0x24760f[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x57f1d1,_0x1566c1,_0x3f8ec0,_0x39a2eb)=>{this['activeView']=_0x3f8ec0?this['_getViewForChange'](_0x3f8ec0):null,this['editor']['model']['change'](()=>{const _0x8abf=this['editor']['editing'];_0x39a2eb&&(_0x39a2eb['data']['isOnRoot']?_0x8abf['view']['change'](_0xbf014d=>{_0xbf014d['removeClass']('ck-revision-history-root--active',_0x8abf['view']['document']['getRoot'](_0x39a2eb['rootName']));}):_0x8abf['reconvertMarker']('revision:'+_0x39a2eb['id'])),_0x3f8ec0&&(_0x3f8ec0['data']['isOnRoot']?_0x8abf['view']['change'](_0x2e83db=>{_0x2e83db['addClass']('ck-revision-history-root--active',_0x8abf['view']['document']['getRoot'](_0x3f8ec0['rootName']));}):_0x8abf['reconvertMarker']('revision:'+_0x3f8ec0['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x5c2660,_0x195108)=>{if(this['activeChange'])return;const _0x5ae04d=this['_findChangeIdFromDomTarget'](_0x195108['target']),_0x491f06=this['_changeIdToChange']['get'](_0x5ae04d);_0x491f06?(this['_activeViewTarget']={'x':_0x195108['domEvent']['x'],'y':_0x195108['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x491f06)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x539f30,_0x7fde43)=>{const _0x1f4946=this['_findChangeIdFromDomTarget'](_0x7fde43['target']),_0x3dd60f=this['_changeIdToChange']['get'](_0x1f4946);_0x3dd60f?(this['_activeViewTarget']={'x':_0x7fde43['domEvent']['x'],'y':_0x7fde43['domEvent']['y']},_0x3dd60f===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x3dd60f):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x2e4096){do{const _0x3512e3=_0x2e4096['getAttribute']('data-change-id');if(_0x3512e3)return _0x3512e3;_0x2e4096=_0x2e4096['parent'];}while(_0x2e4096);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x3a592a=>{for(const _0x3a6a9c of this['editor']['model']['markers'])_0x3a592a['removeMarker'](_0x3a6a9c);});}}function Q(_0xac6705,_0x11e51d){return(_0x38dce,_0x37da2e,_0x2c7172)=>{if(!_0x2c7172['consumable']['test'](_0x37da2e['markerRange'],_0x38dce['name']))return;const _0x49c04e=_0x37da2e['markerRange']['getWalker'](),_0x120023=_0x37da2e['markerRange']['start'],_0x23c9d8=_0xac6705['model']['schema'];let _0x379c1b=null,_0x1261bd=null,_0x43c8fd=!0x1,_0x5b5743=!0x1;for(const _0x47e6a6 of _0x49c04e){const _0x227729=_0x47e6a6['item'];_0x43c8fd=_0x43c8fd||_0x23c9d8['isContent'](_0x227729);const _0x1ac3ad=_0x2c7172['mapper']['toViewElement'](_0x227729);if(_0x1ac3ad&&_0x1ac3ad['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x47e6a6['type']&&(_0x23c9d8['isBlock'](_0x227729)&&!_0x23c9d8['isLimit'](_0x227729)&&(_0x227729['nextSibling']||_0x120023['isAtEnd']?_0x379c1b&&_0x379c1b['parent']==_0x227729||(_0x379c1b=_0x227729,_0x4231c0(_0x47e6a6['previousPosition']),_0x5b5743=!0x0):_0x1261bd=_0x1261bd||_0x47e6a6['previousPosition']));}function _0x4231c0(_0x483310){const _0x2683a5=_0x2c7172['mapper']['toViewPosition'](_0x483310),_0x537637=_0x2c7172['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x11e51d});_0x2c7172['writer']['insert'](_0x2683a5,_0x537637),_0x2c7172['mapper']['bindElementToMarker'](_0x537637,_0x37da2e['markerName']);}_0x43c8fd||_0x5b5743||!_0x1261bd||_0x4231c0(_0x1261bd);};}class nt extends _0x53e976{constructor(_0x42614d){super(_0x42614d);const _0x1fd5d9=_0x42614d['plugins']['get'](l);this['affectsData']=!0x1,this['listenTo'](_0x1fd5d9,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x1fd5d9,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x47ff66=this['editor'],_0x3d151d=_0x47ff66['plugins']['get'](l),_0x486e79=_0x3d151d['isReady']?_0x3d151d['diff']['newRevisionId']:null;_0x47ff66['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x486e79);}['refresh'](){const {isReady:_0x3344a3,isEnabled:_0x119cdb,repository:_0x53a63f,diff:_0x45d131}=this['editor']['plugins']['get'](l),_0x30caf7=_0x45d131&&_0x53a63f['getLaterVisibleRevision'](_0x45d131['newRevisionId']);this['isEnabled']=_0x3344a3&&_0x119cdb&&Boolean(_0x30caf7);}}class ot extends _0x53e976{['_step'];constructor(_0x22e7cb,{direction:_0x41a144}){super(_0x22e7cb);const _0x272025=_0x22e7cb['plugins']['get'](l);this['affectsData']=!0x1,this['_step']='forward'===_0x41a144?0x1:-0x1,this['listenTo'](_0x272025,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x272025,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x272025,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x5ceb01=this['editor'],_0x3bd1fc=_0x5ceb01['plugins']['get'](l),{isNavigationMode:_0x32d3e2,currentChangeNumber:_0xda8453}=_0x3bd1fc;let _0x3c2cd2;if(_0x3bd1fc['activeChange']=_0x32d3e2?_0x3bd1fc['diff']['changes']['get'](_0xda8453+this['_step']):_0x3bd1fc['diff']['changes']['first'],_0x3bd1fc['activeChange']['data']['isOnRoot'])_0x3c2cd2=_0x5ceb01['editing']['view']['getDomRoot'](_0x3bd1fc['activeChange']['rootName']);else{const _0xc168ae=_0x5ceb01['model']['markers']['get']('revision:'+_0x3bd1fc['activeChange']['id']);_0x3c2cd2=_0x5d23d5(_0x5ceb01['editing'],_0xc168ae);}_0x2be881({'target':_0x3c2cd2,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x600804,currentChangeNumber:_0x6ee66e,numberOfChanges:_0x20f917,isReady:_0x254629,isEnabled:_0x5daccf}=this['editor']['plugins']['get'](l);this['isEnabled']=!!(_0x5daccf&&_0x254629&&_0x20f917)&&(!_0x600804||(0x1===this['_step']?_0x6ee66e<_0x20f917-0x1:_0x6ee66e>0x0));}}class Ri extends _0x4d7898{constructor(_0x5be6a8){super(_0x5be6a8);const _0x52d54b=this['bindTemplate'],_0x41e7a7=new _0x1b0a61(_0x5be6a8),_0x573251=new _0x1b0a61(_0x5be6a8);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',(_0x3253d9,_0x1399c1)=>_0x3253d9&&_0x1399c1>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x3fcdbd,_0x2001a9,_0x1934de,_0x458567)=>{if(!_0x3fcdbd)return R(_0x5be6a8,'Loading...');if(!_0x1934de)return R(_0x5be6a8,'No\x20changes');const _0x528861=R(_0x5be6a8,'NUMBER_OF_CHANGES',_0x1934de);return _0x458567?R(_0x5be6a8,'X_OF_Y_CHANGES',[_0x2001a9+0x1,_0x1934de]):_0x528861;}),_0x41e7a7['set']({'label':R(_0x5be6a8,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x124557}),_0x573251['set']({'label':R(_0x5be6a8,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x2f8724}),_0x41e7a7['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x573251['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x41e7a7['on']('execute',()=>this['fire']('execute','backward')),_0x573251['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',_0x52d54b['if']('_isStatusLabelVisible','ck-hidden',_0xe55c8c=>!_0xe55c8c)]},'children':[{'text':_0x52d54b['to']('isNavigationMode',_0x507445=>_0x507445?R(_0x5be6a8,'EDIT_X_OF_Y_REVISIONS')+':\x20':R(_0x5be6a8,'Total')+':\x20')}]},{'text':_0x52d54b['to']('_statusText')}]},new _0x5bb667(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x41e7a7,_0x573251]}]});}}const ge='ck-editor__editable__loading-overlay';class ji extends _0x858dc7{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x39da7c=this['editor']['editing']['view'];_0x39da7c['change'](_0x47f4bb=>{for(const _0x281e62 of _0x39da7c['document']['roots'])_0x47f4bb['addClass'](ge,_0x281e62);});}['hide'](){const _0x2e5175=this['editor']['editing']['view'];_0x2e5175['change'](_0x445bdf=>{for(const _0xc5327b of _0x2e5175['document']['roots'])_0x445bdf['removeClass'](ge,_0xc5327b);});}}class u extends _0x858dc7{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l,ji];}['init'](){const _0x4d45c6=this['editor'],_0x392b32=_0x4d45c6['plugins']['get'](l),_0x1f907d=_0x4d45c6['plugins']['get'](ji);_0x4d45c6['ui']['componentFactory']['add']('exitToEditing',_0x370662=>{const _0x1d2979=new _0x1b0a61(_0x370662);return _0x1d2979['set']({'label':R(_0x370662,'Back\x20to\x20editing'),'icon':_0x49b94e,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x1d2979,'execute',()=>{_0x4d45c6['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x1d2979;}),_0x4d45c6['ui']['componentFactory']['add']('restoreRevision',_0x1cdfb3=>{const _0x3be4e8=new _0x1b0a61(_0x1cdfb3);return _0x3be4e8['set']({'label':R(_0x1cdfb3,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x3be4e8['bind']('isEnabled')['to'](_0x4d45c6['commands']['get']('restoreRevision')),this['listenTo'](_0x3be4e8,'execute',()=>_0x4d45c6['execute']('restoreRevision')),_0x3be4e8;}),_0x4d45c6['ui']['componentFactory']['add']('changesNavigation',_0x5cd1f6=>{const _0x597cf5=new Ri(_0x5cd1f6),_0x3a212b=_0x4d45c6['commands']['get']('showPreviousChange'),_0x17709b=_0x4d45c6['commands']['get']('showNextChange');return _0x597cf5['bind']('isBackwardNavigationEnabled')['to'](_0x3a212b,'isEnabled'),_0x597cf5['bind']('isForwardNavigationEnabled')['to'](_0x17709b,'isEnabled'),_0x597cf5['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x392b32),this['listenTo'](_0x597cf5,'execute',(_0x23df18,_0x4e1f4d)=>{_0x4d45c6['execute']('forward'===_0x4e1f4d?'showNextChange':'showPreviousChange');}),_0x597cf5;}),_0x1f907d['show'](),_0x392b32['on']('change:isReady',(_0x17d849,_0x167643,_0x5ee0ba)=>{_0x5ee0ba?_0x1f907d['hide']():_0x1f907d['show']();});}}class li extends ti{['_resizeObserver']=null;constructor(_0x45b328,_0x1633c1){super(_0x45b328,_0x1633c1);const _0xee9bd1=this['bindTemplate'];this['set']({'label':R(_0x45b328,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=R(_0x45b328,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0xee9bd1['to']('_tooltipString'),'data-cke-tooltip-position':'s','data-cke-tooltip-class':'ck-tooltip_multi-line'}});}['render'](){super['render'](),this['_resizeObserver']=new et(this['fieldView']['element'],()=>this['_updateTooltipText']()),this['listenTo'](this['fieldView'],'input',()=>this['_updateTooltipText']());}['destroy'](){super['destroy'](),this['_resizeObserver']&&this['_resizeObserver']['destroy']();}['_updateTooltipText'](){const _0x50001a=this['fieldView']['element'];this['_tooltipString']=_0x50001a['scrollWidth']>_0x50001a['clientWidth']&&_0x50001a['value']||'';}}class vi extends _0x4d7898{constructor(_0x13cf95,_0xe63be9,_0x383acd){super(_0x13cf95);const _0x5f23b1=new _0x13fce5();_0x5f23b1['set']({'content':_0x45ead2,'viewBox':'0\x200\x2011\x2010'});const _0x41071b=['ck','ck-revision-history-sidebar__revision-author'];_0x383acd&&_0x41071b['push']('ck-revision-history-sidebar__revision-author_creator');const _0xf93cc3=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':R(_0x13cf95,_0x383acd?'Revision\x20creator':'Revision\x20author')},'children':[_0x5f23b1,_0xe63be9['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x41071b},'children':_0xf93cc3});}}function mi(_0x5d33cf,_0x90a406){const _0x1477b9=_0x5d33cf['bindTemplate'],_0xab86ea=_0x5d33cf['locale'],_0x23eef7=_0x2842e0(_0xab86ea);_0x23eef7['panelPosition']='sw';const _0x100e29=function(_0x233f41,_0x5c7f87){const _0x1137a2=function(_0x33a02c,_0x31e2d6){const _0x4e98bb=_0x33a02c['locale'],_0x3e005b={'Compare\x20against\x20selected':R(_0x4e98bb,'Compare\x20against\x20selected'),'Name\x20this\x20revision':R(_0x4e98bb,'Name\x20this\x20revision'),'Restore\x20this\x20revision':R(_0x4e98bb,'Restore\x20this\x20revision')};return _0x31e2d6['map'](_0x3f075e=>{const _0x363bec=_0x3e005b[_0x3f075e['name']];return _0x363bec&&_0x363bec!==_0x3f075e['name']&&(_0x3f075e['name']=_0x363bec),_0x3f075e;});}(_0x233f41,_0x5c7f87),_0x2ea7d9=new _0x1d5790();for(const _0x459f90 of _0x1137a2){const _0x2bd2d6={'type':'button','model':new to({'label':_0x459f90['name'],'class':_0x459f90['class'],'withText':!0x0,'role':'menuitem','_action':_0x459f90['action']})};_0x2bd2d6['model']['bind']('isEnabled')['to'](_0x233f41,'isActionsDropdownOpen',_0x1fc848=>'function'!=typeof _0x459f90['isEnabled']||(!_0x1fc848||_0x459f90['isEnabled'](_0x233f41))),_0x2ea7d9['add'](_0x2bd2d6);}return _0x2ea7d9;}(_0x5d33cf,_0x90a406);return _0x5d33cf['bind']('isActionsDropdownOpen')['to'](_0x23eef7,'isOpen'),_0x23eef7['buttonView']['set']({'label':R(_0xab86ea,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x36531b}),_0x23eef7['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x1477b9['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x1477b9['to'](_0x1fd402=>_0x1fd402['stopPropagation']())}}),_0x23eef7['on']('execute',_0x1248d8=>{_0x5d33cf['isReady']&&'function'==typeof _0x1248d8['source']['_action']&&_0x1248d8['source']['_action'](_0x5d33cf);}),_0x2b214d(_0x23eef7,_0x100e29,{'role':'menu'}),_0x23eef7['listenTo'](_0x5d33cf,'change:isActionsDropdownOpen',(_0x59c1a7,_0xd5d800,_0x4866fd)=>{if(_0x4866fd)for(const _0x500585 of _0x23eef7['listView']['items']){const _0x2df8e0=_0x500585['children']['first'],_0x1288a9=_0x90a406['find'](_0x2549ec=>_0x2549ec['action']===_0x2df8e0['_action'])['isVisible'];_0x500585['isVisible']=void 0x0===_0x1288a9||_0x1288a9(_0x5d33cf);}}),_0x23eef7;}class pi extends/* #__PURE__ -- @preserve */
|
|
27
|
-
|
|
23
|
+
import{ObservableMixin as _0x255515,uid as _0xc2c09a,Collection as _0x577801,logWarning as _0x18fd47,FocusTracker as _0x33a359,KeystrokeHandler as _0x15232b,scrollViewportToShowTarget as _0x1f6038,ResizeObserver as et,ElementReplacer as it,CKEditorError as _0x55e8c6}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x4300e7,set as _0x2f1917,unset as _0x52d03c,isEqual as _0x343c2b}from'es-toolkit/compat';import{Plugin as _0x5b0dba,PendingActions as _0x5d1036,Command as _0x14ef0e,ElementApiMixin as _0x1caf97,Editor as _0x4e4a7e}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x156c7a,getMarkerDomElement as _0x13d047,ConfirmMixin as _0x525a0c,sanitizeEditorConfig as _0x23274b}from'ckeditor5-collaboration/dist/index.js';import{ViewContainerElement as _0x209b17,ViewAttributeElement as _0x3f49f5,ViewEmptyElement as _0x6acfa8,ViewRawElement as _0x1038e6,ViewUIElement as _0x2b5cfb,ViewDocumentFragment as _0x1049ad,ViewText as _0xd730f6,ViewElement as _0x4a1962,ModelElement as _0x560940,ModelRange as _0x3fb84c,ModelPosition as _0x5346a5,ModelDocumentFragment as _0x8e7ca7,ModelText as _0x34a305}from'@ckeditor/ckeditor5-engine/dist/index.js';import{IconHistory as _0x2efa8c,IconChevronUp as _0x4605ea,IconChevronDown as _0x129e8c,IconUndo as _0x805c16,IconUser as _0x434f3a,IconThreeVerticalDots as _0x3f8486}from'@ckeditor/ckeditor5-icons/dist/index.js';import{CssTransitionDisablerMixin as _0x105b56,View as _0x13ae3e,submitHandler as _0x10e463,LabeledFieldView as ti,createLabeledInputText as _0x14027c,createDropdown as _0x2ef58a,ListView as _0x34e818,ListItemView as _0x5b3d8d,ButtonView as _0xbf084f,MenuBarMenuView as _0x3a0adb,MenuBarMenuListView as _0x221b21,MenuBarMenuListItemView as _0x2a567a,MenuBarMenuListItemButtonView as _0x5eafa3,ContextualBalloon as _0x56c3c6,ToolbarSeparatorView as _0x311722,IconView as _0x24f111,addListToDropdown as _0x121886,UIModel as to,EditorUI as tt,normalizeToolbarConfig as st,BoxedEditorUIView as _0xbb4a8a,StickyPanelView as _0x345106,ToolbarView as _0x9f2c9,InlineEditableUIView as te}from'@ckeditor/ckeditor5-ui/dist/index.js';import{DateTime as _0x489a69}from'luxon';class I extends/* #__PURE__ -- @preserve */
|
|
24
|
+
_0x255515(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x141cf1){super(),this['id']=_0x141cf1['id']||_0xc2c09a(),this['creator']=_0x141cf1['creator']||null,this['authors']=_0x141cf1['authors']||[],this['diffData']=_0x141cf1['diffData']||null,this['toVersion']=_0x141cf1['toVersion']||0x0,this['fromVersion']=_0x141cf1['fromVersion']||0x0,this['set']('name',_0x141cf1['name']||''),this['set']('createdAt',_0x141cf1['createdAt']||new Date()),this['set']('attributes',_0x141cf1['attributes']||{});}['setName'](_0x3e0c6e){this['_update']({'name':_0x3e0c6e});}['setAttribute'](_0x458284,_0x233ba6){const _0xa2a84b=_0x4300e7(this['attributes']);_0x2f1917(_0xa2a84b,_0x458284,_0x233ba6),this['_update']({'attributes':_0xa2a84b});}['removeAttribute'](_0x36a323){const _0x81e9dc=_0x4300e7(this['attributes']);_0x52d03c(_0x81e9dc,_0x36a323),this['_update']({'attributes':_0x81e9dc});}['_update'](_0x49570d,_0x513c50=!0x1){let _0x4e2694=!0x1;const _0x3c5fcb={'id':this['id']},_0x2ebe7d=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x2e5280 of _0x2ebe7d){const _0x21fad3=_0x49570d[_0x2e5280];void 0x0!==_0x21fad3&&_0x21fad3!==this[_0x2e5280]&&(this[_0x2e5280]=_0x21fad3,_0x3c5fcb[_0x2e5280]=_0x21fad3,_0x4e2694=!0x0);}_0x4e2694&&(_0x3c5fcb['authors']&&(_0x3c5fcb['authorsIds']=_0x3c5fcb['authors']['map'](_0x1c5a08=>_0x1c5a08['id']),delete _0x3c5fcb['authors']),this['fire']('_update',_0x3c5fcb,_0x513c50));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x19886a=>_0x19886a['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class S extends _0x5b0dba{['_revisions'];static get['requires'](){return[_0x156c7a];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x5850b9){super(_0x5850b9),this['_revisions']=new _0x577801();}['afterInit'](){!async function(_0x545727){const _0x2329af=_0x147845([0x64,0x78,0x75,0x4d,0x51,0x73,0x37,0x35,0x52,0x67,0x39,0x5a,0x46,0x71,0x48,0x74,0x38,0x47,0x55,0x6e,0x65,0x49,0x6a,0x62,0x6b,0x30,0x32,0x33,0x61,0x63,0x4c,0x76,0x58,0x34,0x4a,0x43,0x56,0x57,0x50,0x6f,0x54,0x31,0x72,0x68,0x70,0x4e,0x59,0x77,0x36,0x4f,0x45,0x42,0x53,0x41,0x44,0x4b,0x6d,0x66,0x7a,0x79,0x6c,0x69]),_0x1e0179=0xeb829,_0x41b2c9=0x3dd46f5f,_0x197b36=0x3dd30397^_0x41b2c9,_0x49f951=window[_0x147845([0x44,0x61,0x74,0x65])][_0x147845([0x6e,0x6f,0x77])](),_0x56aba4=_0x545727[_0x147845([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x575ce9=new window[(_0x147845([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x518da7=>{_0x56aba4[_0x147845([0x6f,0x6e,0x63,0x65])](_0x147845([0x72,0x65,0x61,0x64,0x79]),_0x518da7);}),_0x2f8cc2={[_0x147845([0x6b,0x74,0x79])]:_0x147845([0x45,0x43]),[_0x147845([0x75,0x73,0x65])]:_0x147845([0x73,0x69,0x67]),[_0x147845([0x63,0x72,0x76])]:_0x147845([0x50,0x2d,0x32,0x35,0x36]),[_0x147845([0x78])]:_0x147845([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]),[_0x147845([0x79])]:_0x147845([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]),[_0x147845([0x61,0x6c,0x67])]:_0x147845([0x45,0x53,0x32,0x35,0x36])},_0x2f2978=_0x56aba4[_0x147845([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x147845([0x67,0x65,0x74])](_0x147845([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x4d0edf(){let _0x308b56,_0x5a1ee9=null,_0x961851=null;try{if(_0x2f2978==_0x147845([0x47,0x50,0x4c]))return _0x147845([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x308b56=_0xe99239(),!_0x308b56)return _0x147845([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x308b56[_0x147845([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x961851=_0x1feff2(_0x308b56[_0x147845([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x308b56[_0x147845([0x6a,0x74,0x69])])),await _0x15fe23()?_0xa8d3b5()?_0x2bc5fb()?_0x147845([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x3b315c()?(_0x308b56[_0x147845([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x147845([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x5a1ee9=_0x15c098(_0x147845([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x308b56[_0x147845([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x147845([0x74,0x72,0x69,0x61,0x6c])&&(_0x5a1ee9=_0x15c098(_0x147845([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x3b5edb()):_0x147845([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x147845([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x147845([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x147845([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x2bc5fb(){const _0x5e4729=[_0x147845([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x147845([0x74,0x72,0x69,0x61,0x6c])][_0x147845([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x308b56[_0x147845([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x49f951/0x3e8:0xe10*_0x197b36;return _0x308b56[_0x147845([0x65,0x78,0x70])]<_0x5e4729;}function _0xa8d3b5(){const _0x1e4d79=_0x308b56[_0x147845([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x1e4d79)return!0x1;if(_0x1e4d79[_0x147845([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x147845([0x2a])))return!0x0;if(_0x1e4d79[_0x147845([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x147845([0x52,0x48])))return!0x0;if(_0x1e4d79[_0x147845([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x147845([0x52,0x52,0x48]))){if(_0x34d30f())return!0x0;if(_0x22cf0c()||_0x2437f8())return!0x0;}return!0x1;}function _0x3b315c(){const _0x5586a3=_0x308b56[_0x147845([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x5586a3||0x0==_0x5586a3[_0x147845([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x125325}=new URL(window[_0x147845([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x5586a3[_0x147845([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x125325))return!0x0;const _0x30c1b9=_0x125325[_0x147845([0x73,0x70,0x6c,0x69,0x74])](_0x147845([0x2e]));return _0x5586a3[_0x147845([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x4e33bb=>_0x4e33bb[_0x147845([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x147845([0x2a])))[_0x147845([0x6d,0x61,0x70])](_0x413389=>_0x413389[_0x147845([0x73,0x70,0x6c,0x69,0x74])](_0x147845([0x2e])))[_0x147845([0x66,0x69,0x6c,0x74,0x65,0x72])](_0xd918c6=>_0xd918c6[_0x147845([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x30c1b9[_0x147845([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x147845([0x6d,0x61,0x70])](_0x2a5ce2=>Array(_0x30c1b9[_0x147845([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0x2a5ce2[_0x147845([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x147845([0x66,0x69,0x6c,0x6c])](_0x2a5ce2[0x0]===_0x147845([0x2a])?_0x147845([0x2a]):'')[_0x147845([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0x2a5ce2))[_0x147845([0x73,0x6f,0x6d,0x65])](_0x2fac0e=>_0x30c1b9[_0x147845([0x65,0x76,0x65,0x72,0x79])]((_0x10282e,_0x242cfb)=>_0x2fac0e[_0x242cfb]===_0x10282e||_0x2fac0e[_0x242cfb]===_0x147845([0x2a])));}function _0x3b5edb(){return _0x5a1ee9&&_0x961851?new window[(_0x147845([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x83787c,_0x38fb44)=>{_0x5a1ee9[_0x147845([0x74,0x68,0x65,0x6e])](_0x83787c,_0x38fb44),_0x961851[_0x147845([0x74,0x68,0x65,0x6e])](_0x61c6e=>{_0x61c6e!=_0x147845([0x56,0x61,0x6c,0x69,0x64])&&_0x83787c(_0x61c6e);},_0x38fb44);}):_0x5a1ee9||_0x961851||_0x147845([0x56,0x61,0x6c,0x69,0x64]);}}function _0x1feff2(_0x526143,_0x46f2c2){return new window[(_0x147845([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x22a4e1=>{if(_0x45163f())return _0x22a4e1(_0x147845([0x56,0x61,0x6c,0x69,0x64]));_0x155471(),_0x56aba4[_0x147845([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x147845([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x34aa2c=!0x1;const _0x182231=_0xc2c09a();function _0x4d2bf2(_0x46b2c0){return!!_0x46b2c0&&(typeof _0x46b2c0===_0x147845([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x46b2c0===_0x147845([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x46b2c0[_0x147845([0x74,0x68,0x65,0x6e])]===_0x147845([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x46b2c0[_0x147845([0x63,0x61,0x74,0x63,0x68])]===_0x147845([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x477f64(_0x2ea05f){_0x367e3c(_0x2ea05f)[_0x147845([0x74,0x68,0x65,0x6e])](_0x2d7a57=>{if(!_0x2d7a57||_0x2d7a57[_0x147845([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x147845([0x6f,0x6b]))return _0x147845([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0xb22b53(_0x59a253(_0x182231+_0x46f2c2))!=_0x2d7a57[_0x147845([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x147845([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x147845([0x56,0x61,0x6c,0x69,0x64]);})[_0x147845([0x74,0x68,0x65,0x6e])](_0x32de58=>(_0x5e41a0(),_0x32de58),()=>{const _0x8b6afe=_0x56faa5();return null==_0x8b6afe?(_0x5e41a0(),_0x147845([0x56,0x61,0x6c,0x69,0x64])):_0x147845(_0x49f951-_0x8b6afe>(0x19d8eb5f^_0x41b2c9)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x147845([0x74,0x68,0x65,0x6e])](_0x22a4e1)[_0x147845([0x63,0x61,0x74,0x63,0x68])](()=>{_0x22a4e1(_0x147845([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x1c6dc8=0x3de281df^_0x41b2c9;function _0x5e41a0(){const _0x14e9eb=_0x147845([0x6c,0x6c,0x63,0x74,0x2d])+_0xb22b53(_0x59a253(_0x526143)),_0x35a01a=_0x14e6fe(_0xb22b53(window[_0x147845([0x4d,0x61,0x74,0x68])][_0x147845([0x63,0x65,0x69,0x6c])](_0x49f951/_0x1c6dc8)));window[_0x147845([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x147845([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x14e9eb,_0x35a01a);}function _0x56faa5(){const _0x11fff5=_0x147845([0x6c,0x6c,0x63,0x74,0x2d])+_0xb22b53(_0x59a253(_0x526143)),_0x55a0fa=window[_0x147845([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x147845([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x11fff5);return _0x55a0fa?window[_0x147845([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x14e6fe(_0x55a0fa),0x10)*_0x1c6dc8:null;}function _0x367e3c(_0x24167a){return new window[(_0x147845([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x2480ec,_0x385192)=>{_0x24167a[_0x147845([0x74,0x68,0x65,0x6e])](_0x2480ec,_0x385192),window[_0x147845([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x385192,0x3dd5bb9f^_0x41b2c9);});}}_0x56aba4[_0x147845([0x6f,0x6e])](_0x147845([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x114b87,_0x49cf7d)=>{if(_0x49cf7d[0x0]!=_0x526143)return _0x22a4e1(_0x147845([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x49cf7d[0x1]={..._0x49cf7d[0x1],[_0x147845([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x182231};},{[_0x147845([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x147845([0x68,0x69,0x67,0x68])}),_0x56aba4[_0x147845([0x6f,0x6e])](_0x147845([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x5919de=>{_0x4d2bf2(_0x5919de[_0x147845([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x34aa2c=!0x0,_0x477f64(_0x5919de[_0x147845([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x147845([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x147845([0x6c,0x6f,0x77])}),_0x575ce9[_0x147845([0x74,0x68,0x65,0x6e])](()=>{_0x34aa2c||_0x22a4e1(_0x147845([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x45163f(){return _0x56aba4[_0x147845([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x147845([0x76,0x69,0x65,0x77])][_0x147845([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x147845([0x61,0x75,0x74,0x6f]);}function _0x155471(){_0x56aba4[_0x147845([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x147845([0x76,0x69,0x65,0x77])][_0x147845([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x147845([0x61,0x75,0x74,0x6f]);}}function _0x15c098(_0x4ad954){const _0x110f69=[new window[(_0x147845([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2d79fa=>setTimeout(_0x2d79fa,0x3ddd5193^_0x41b2c9)),_0x575ce9[_0x147845([0x74,0x68,0x65,0x6e])](()=>new window[(_0x147845([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x3f3c66=>{const _0x1c5f9b=0x3dd46f58^_0x41b2c9,_0x5a02f7=_0x545727[_0x147845([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x27e937(){_0x5a02f7[_0x147845([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x1c5f9b&&_0x3f3c66();}_0x27e937(),_0x5a02f7[_0x147845([0x6f,0x6e])](_0x147845([0x61,0x64,0x64]),_0x27e937);})),new window[(_0x147845([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x766ad4=>{function _0x34a058(){for(const _0x3b4d03 in window)if(window[_0x147845([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x147845([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x3b4d03))&&window[_0x3b4d03]==_0x1e0179)return _0x766ad4();_0x56aba4[_0x147845([0x73,0x74,0x61,0x74,0x65])]!=_0x147845([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x147845([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x34a058,0x3dd47cd7^_0x41b2c9);}_0x535171(_0x147845([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x34a058();})];return window[_0x147845([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x147845([0x72,0x61,0x63,0x65])](_0x110f69)[_0x147845([0x74,0x68,0x65,0x6e])](()=>_0x4ad954);}async function _0x18c3e7(){if(await _0x575ce9,_0x535171(_0x147845([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x2a7e2a=_0x545727[_0x147845([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x476211=_0x545727[_0x147845([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])](_0x2a7e2a[_0x147845([0x69,0x64])]),_0x3d15ee=_0x10a11c(_0x147845([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x3d15ee[_0x147845([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x2a7e2a['id'],_0x476211?_0x476211['id']:null,!0x0),_0x3d15ee[_0x147845([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x147845([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x3d15ee[_0x147845([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x3d15ee[_0x147845([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x472357,void(_0x3d15ee[_0x147845([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x472357);}if(_0x535171(_0x147845([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x24e361=_0x10a11c(_0x147845([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x24e361[_0x147845([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x147845([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x24e361[_0x147845([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x24e361[_0x147845([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x472357,_0x24e361[_0x147845([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x472357;}_0x56aba4[_0x147845([0x6d,0x6f,0x64,0x65,0x6c])][_0x147845([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x472357,_0x56aba4[_0x147845([0x6d,0x6f,0x64,0x65,0x6c])][_0x147845([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x472357,_0x56aba4[_0x147845([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x147845([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x34d30f(){return _0x535171(_0x147845([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x10a11c(_0x147845([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x147845([0x73,0x74,0x61,0x74,0x65])]==_0x147845([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x22cf0c(){return _0x535171(_0x147845([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 _0x2437f8(){return _0x535171(_0x147845([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x551f72(_0x4ebe3c){const _0x1995d9=_0xe08945();_0x56aba4[_0x1995d9]=_0x147845([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])+_0x4ebe3c,_0x4ebe3c[_0x147845([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x147845([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0xe08945()]=_0x1e0179),_0x4ebe3c!=_0x147845([0x56,0x61,0x6c,0x69,0x64])&&_0x18c3e7();}function _0xe08945(){const _0x1cb289=window[_0x147845([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x147845([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x147845([0x6e,0x6f,0x77])]())[_0x147845([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x147845([0x2e]),'');let _0x21fd09=_0x147845([0x64]);for(let _0x4b0e48=0x0;_0x4b0e48<_0x1cb289[_0x147845([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x4b0e48+=0x2){let _0x5562fc=window[_0x147845([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x1cb289[_0x147845([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x4b0e48,_0x4b0e48+0x2));_0x5562fc>=_0x2329af[_0x147845([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x5562fc-=_0x2329af[_0x147845([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x21fd09+=_0x2329af[_0x5562fc];}return _0x21fd09;}function _0xe99239(){const _0x313cdf=_0x2f2978[_0x147845([0x73,0x70,0x6c,0x69,0x74])](_0x147845([0x2e]));if(0x3!=_0x313cdf[_0x147845([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x3a7e14(_0x313cdf[0x1]);function _0x3a7e14(_0xda51b){const _0x2e1fd0=_0x398d64(_0xda51b);return _0x2e1fd0&&_0x4d3ca8()?_0x2e1fd0:null;function _0x4d3ca8(){const _0x323938=_0x2e1fd0[_0x147845([0x6a,0x74,0x69])],_0x19440e=window[_0x147845([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x323938[_0x147845([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x323938[_0x147845([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x1b0c47={..._0x2e1fd0,[_0x147845([0x6a,0x74,0x69])]:_0x323938[_0x147845([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x323938[_0x147845([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x1b0c47[_0x147845([0x76,0x63])],_0x59a253(_0x1b0c47)==_0x19440e;}}}async function _0x15fe23(){let _0x35699b=!0x0;try{const _0x51e68b=_0x2f2978[_0x147845([0x73,0x70,0x6c,0x69,0x74])](_0x147845([0x2e])),[_0x2da1ab,_0x22e112,_0x476a75]=_0x51e68b;return _0x266b95(_0x2da1ab),await _0x1fc5ea(_0x2da1ab,_0x22e112,_0x476a75),_0x35699b;}catch{return!0x1;}function _0x266b95(_0x19d632){const _0x44e791=_0x398d64(_0x19d632);_0x44e791&&_0x44e791[_0x147845([0x61,0x6c,0x67])]==_0x147845([0x45,0x53,0x32,0x35,0x36])||(_0x35699b=!0x1);}async function _0x1fc5ea(_0x3be364,_0x3d6690,_0xb02f9d){const _0x581c01=window[_0x147845([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x147845([0x66,0x72,0x6f,0x6d])](_0x2344b6(_0xb02f9d),_0xb4631d=>_0xb4631d[_0x147845([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x15cb47=new window[(_0x147845([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x147845([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x3be364+_0x147845([0x2e])+_0x3d6690),_0x149dcb=window[_0x147845([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x147845([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x149dcb)return;const _0x378841=await _0x149dcb[_0x147845([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x147845([0x6a,0x77,0x6b]),_0x2f8cc2,{[_0x147845([0x6e,0x61,0x6d,0x65])]:_0x147845([0x45,0x43,0x44,0x53,0x41]),[_0x147845([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x147845([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x147845([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x149dcb[_0x147845([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x147845([0x6e,0x61,0x6d,0x65])]:_0x147845([0x45,0x43,0x44,0x53,0x41]),[_0x147845([0x68,0x61,0x73,0x68])]:{[_0x147845([0x6e,0x61,0x6d,0x65])]:_0x147845([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x378841,_0x581c01,_0x15cb47)||(_0x35699b=!0x1);}}function _0x398d64(_0x4189c3){return _0x4189c3[_0x147845([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x147845([0x65,0x79]))?JSON[_0x147845([0x70,0x61,0x72,0x73,0x65])](_0x2344b6(_0x4189c3)):null;}function _0x2344b6(_0x1fbe9e){return window[_0x147845([0x61,0x74,0x6f,0x62])](_0x1fbe9e[_0x147845([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x147845([0x2b]))[_0x147845([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x147845([0x2f])));}function _0x59a253(_0x1febdd){let _0x358162=0x1505;function _0x409682(_0x1dd265){for(let _0x522edf=0x0;_0x522edf<_0x1dd265[_0x147845([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x522edf++){const _0x454234=_0x1dd265[_0x147845([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x522edf);_0x358162=(_0x358162<<0x5)+_0x358162+_0x454234,_0x358162&=_0x358162;}}function _0x385d69(_0x25a440){Array[_0x147845([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x25a440)?_0x25a440[_0x147845([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x385d69):_0x25a440&&typeof _0x25a440==_0x147845([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x147845([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x25a440)[_0x147845([0x73,0x6f,0x72,0x74])]()[_0x147845([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x594fdb,_0x4a5245])=>{_0x409682(_0x594fdb),_0x385d69(_0x4a5245);}):_0x409682(window[_0x147845([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x25a440));}return _0x385d69(_0x1febdd),_0x358162>>>0x0;}function _0xb22b53(_0x3fc895){return _0x3fc895[_0x147845([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x147845([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x147845([0x30]));}function _0x14e6fe(_0x60c15d){return _0x60c15d[_0x147845([0x73,0x70,0x6c,0x69,0x74])]('')[_0x147845([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x147845([0x6a,0x6f,0x69,0x6e])]('');}function _0x535171(_0x51e6cf){return _0x56aba4[_0x147845([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x147845([0x68,0x61,0x73])](_0x51e6cf);}function _0x10a11c(_0x54fd63){return _0x56aba4[_0x147845([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x147845([0x67,0x65,0x74])](_0x54fd63);}function _0x472357(){}function _0x147845(_0x568665){return _0x568665['map'](_0x301927=>String['fromCharCode'](_0x301927))['join']('');}_0x551f72(await _0x4d0edf());}(this);}['createRevision'](_0x477746){const _0x4d367f=this['editor']['plugins']['get']('Users');return new I({'id':_0x477746['id'],'name':_0x477746['name'],'creator':_0x477746['creatorId']?_0x4d367f['getUser'](_0x477746['creatorId']):null,'diffData':_0x477746['diffData']||_0x477746['data'],'authors':_0x477746['authorsIds']['map'](_0x42af41=>_0x4d367f['getUser'](_0x42af41)),'createdAt':new Date(_0x477746['createdAt']),'attributes':_0x477746['attributes'],'fromVersion':_0x477746['fromVersion'],'toVersion':_0x477746['toVersion']});}['addRevision'](_0x52a7eb,_0x103dd1=0x0){this['_revisions']['add'](_0x52a7eb,_0x103dd1);}['getRevision'](_0x21f9d5){return this['_revisions']['get'](_0x21f9d5);}['getRevisions'](_0x508a7f={'toJSON':!0x1}){const _0xb231b3=Array['from'](this['_revisions']);return _0xb231b3['reverse'](),_0x508a7f['toJSON']?_0xb231b3['map'](_0x7cc4b0=>_0x7cc4b0['toJSON']()):_0xb231b3;}['getIndex'](_0x38d9dd){return this['_revisions']['getIndex'](_0x38d9dd);}['getEarlierVisibleRevision'](_0x2a195d){const [,_0x3b1ac6]=this['getRevisionsIterator'](_0x2a195d,{'direction':'earlier'});return _0x3b1ac6;}['getLaterVisibleRevision'](_0x4316cb){const [,_0x405e89]=this['getRevisionsIterator'](_0x4316cb,{'direction':'later'});return _0x405e89;}['getRevisionsInDiff'](_0x333e2f){const _0x1d43cf=[];for(const _0x5d1e2e of this['getRevisionsIterator'](_0x333e2f['newRevisionId']))if(_0x1d43cf['push'](_0x5d1e2e),_0x5d1e2e['id']===_0x333e2f['oldRevisionId'])break;return _0x1d43cf;}*['getRevisionsIterator'](_0x18f74e,{direction:_0xd2b69f='earlier',filter:_0x51753e=()=>!0x0}={}){const _0x1a87e7='earlier'===_0xd2b69f?0x1:-0x1;let _0x18bb18=this['_revisions']['get'](_0x18f74e),_0x34424f=this['getIndex'](_0x18bb18);for(yield _0x18bb18;_0x18bb18;){if(_0x34424f+=_0x1a87e7,_0x18bb18=this['getRevision'](_0x34424f),!_0x18bb18)return;_0x51753e(_0x18bb18)&&(yield _0x18bb18);}}}class $ extends _0x5b0dba{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x209b17,'c'],[_0x3f49f5,'a'],[_0x6acfa8,'e'],[_0x1038e6,'r'],[_0x2b5cfb,'u']]);['_typeCharToViewClass']=new Map([['c',_0x209b17],['a',_0x3f49f5],['e',_0x6acfa8],['r',_0x1038e6],['u',_0x2b5cfb]]);async['loadRevisionData'](_0x3fe56e,_0x348038){if(_0x3fe56e['diffData']||!_0x348038)return;const _0xcb9a57=this['editor']['config']['get']('collaboration.channelId'),_0x147643=await _0x348038['getRevision']({'channelId':_0xcb9a57,'revisionId':_0x3fe56e['id']});_0x3fe56e['diffData']=_0x147643['diffData'];}['getRevisionDocumentData'](_0x27ea59){const _0xeb5def={};for(const _0x260177 in _0x27ea59['diffData']){if(_0x27ea59['diffData'][_0x260177]['attachChange']&&!_0x27ea59['diffData'][_0x260177]['attachChange']['isAttached'])continue;const _0x3bcbc7=this['_removeRevisionMarkers'](JSON['parse'](_0x27ea59['diffData'][_0x260177]['insertions'])),_0x1e67fa=this['editor']['editing']['view']['document'],_0x1ff079=new _0x1049ad(_0x1e67fa,_0x3bcbc7['map'](_0x18d932=>this['_getViewFromDiffObj'](_0x18d932,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0xeb5def[_0x260177]=this['editor']['data']['processor']['toData'](_0x1ff079),this['editor']['data']['processor']['useFillerType']('default');}return _0xeb5def;}['getRevisionRootsAttributes'](_0x8bf4e3){const _0x182290={};for(const _0x20eb72 in _0x8bf4e3['diffData'])_0x8bf4e3['diffData'][_0x20eb72]['attachChange']&&!_0x8bf4e3['diffData'][_0x20eb72]['attachChange']['isAttached']||(_0x182290[_0x20eb72]=_0x8bf4e3['diffData'][_0x20eb72]['attributesAfter']||{});return _0x182290;}['_getTypeCharForViewElement'](_0x4bfcef){return this['_viewClassToTypeChar']['get'](_0x4bfcef['constructor']);}['_getViewFromDiffObj'](_0x3a7942,_0x3a6909){const _0x20679b=this['editor']['editing']['view']['document'];if('string'==typeof _0x3a7942)return new _0xd730f6(_0x20679b,_0x3a7942);{let _0x3c390c,_0x57b71c;_0x57b71c='u'==_0x3a7942['type']||'r'==_0x3a7942['type']?[]:_0x3a7942['children']['map'](_0x4e4320=>this['_getViewFromDiffObj'](_0x4e4320,_0x3a6909));const _0x5dc2a0=this['_typeCharToViewClass']['get'](_0x3a7942['type'])||_0x4a1962,_0x1fb084=this['editor']['data']['htmlProcessor']['domConverter'];if(_0x3c390c=new _0x5dc2a0(_0x20679b,_0x3a7942['name'],_0x3a7942['attributes'],_0x57b71c),'u'==_0x3a7942['type']&&_0x3a7942['children'][0x0]){const _0x448143=_0x3a7942['children'][0x0];if(_0x3c390c['render']=function(_0xd43ae8){const _0x14ec49=_0xd43ae8['createElement']('div');return _0x14ec49['innerHTML']=_0x448143,_0x14ec49['childNodes'][0x0];},_0x3a6909){const _0x3d889c=new _0x1049ad(_0x20679b);_0x3d889c['_appendChild'](_0x3c390c);const _0x353bec=Array['from'](_0x1fb084['viewChildrenToDom'](_0x3d889c,{'bind':!0x1})),_0x2ce34f=_0x1fb084['domDocument']['createElement']('div');_0x2ce34f['append'](..._0x353bec),_0x3c390c=Array['from'](_0x1fb084['domChildrenToView'](_0x2ce34f))[0x0];}}else{if('r'==_0x3a7942['type']&&_0x3a7942['children'][0x0]){const _0x54c60b=_0x3a7942['children'][0x0];if(_0x3c390c['render']=function(_0x25024d){_0x25024d['innerHTML']=_0x54c60b;},_0x3a6909){const _0x284869=new _0x1049ad(_0x20679b);_0x284869['_appendChild'](_0x3c390c);const _0x387f9e=Array['from'](_0x1fb084['viewChildrenToDom'](_0x284869,{'bind':!0x1})),_0x15a9c4=_0x1fb084['domDocument']['createElement']('div');_0x15a9c4['append'](..._0x387f9e);const _0x3f6488=Array['from'](_0x1fb084['domChildrenToView'](_0x15a9c4));_0x3f6488['length']>0x1?_0x3c390c['_appendChild'](_0x3f6488):_0x3c390c=_0x3f6488[0x0];}}}if(_0x3a7942['customProperties']){for(const [_0x1cf70b,_0x3fb32b]of _0x3a7942['customProperties'])_0x3c390c['_setCustomProperty'](_0x1cf70b,_0x3fb32b);}const _0x569fc2=void 0x0===_0x3a7942['fillerOffset']?null:_0x3a7942['fillerOffset'];return null!==_0x569fc2&&(_0x3c390c['getFillerOffset']=()=>_0x569fc2),_0x3c390c;}}['_makeModelFromViewString'](_0x452597){const _0x5c86f9=JSON['parse'](_0x452597),_0xa58dc9=this['editor']['editing']['view']['document'],_0x3b4ca8=new _0x1049ad(_0xa58dc9,_0x5c86f9['map'](_0x37b5ce=>this['_getViewFromDiffObj'](_0x37b5ce,!0x0)));return this['editor']['data']['toModel'](_0x3b4ca8);}['_removeRevisionMarkers'](_0x250f66){return(_0x250f66=_0x250f66['filter'](_0x2c8ab1=>!_0x2c8ab1['name']||'revision-start'!==_0x2c8ab1['name']&&'revision-end'!==_0x2c8ab1['name']))['forEach'](_0x49c225=>{'string'!=typeof _0x49c225&&(_0x49c225['children']=this['_removeRevisionMarkers'](_0x49c225['children']),_0x49c225['attributes']=_0x49c225['attributes']['filter'](_0x4df6b5=>!_0x4df6b5[0x0]['startsWith']('data-revision-')));}),_0x250f66;}}function R(_0x4608d0,_0x1a5f71,_0x1dc5b7){const t=_0x4608d0['t'];switch(_0x1a5f71){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'},_0x1dc5b7);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x1dc5b7);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 _0x5b0dba{['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[_0x156c7a,S,$,_0x5d1036];}constructor(_0x550aed){super(_0x550aed),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 _0x12537b=_0xc2c09a();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x12537b},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 _0x19e2e1=this['repository']['getRevision'](0x0),_0x452bd3=_0x19e2e1&&null===_0x19e2e1['creator']?_0x19e2e1:null;if(this['_continueCurrentRevision']=!!_0x452bd3&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x5aae10=this['_source']['getCurrentRevisionId'](),_0x5afea0=this['repository']['getRevision'](_0x5aae10);if(_0x5afea0)this['_startingVersion']=_0x5afea0['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x499842=this['_source']['history']['_operations']['find'](_0x55e316=>!_0x55e316['_isInit']),_0x5b3398=_0x499842?_0x499842['baseVersion']:this['_source']['history']['version'];_0x19e2e1?(_0x19e2e1['toVersion']<_0x5b3398&&_0x19e2e1['_update']({'toVersion':_0x5b3398}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x452bd3['id'],this['_startingVersion']=_0x452bd3['fromVersion']):(this['_startingVersion']=_0x19e2e1['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x5b3398,this['_continueCurrentRevision']=!0x1);}}else _0x452bd3&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x452bd3['toVersion'],this['editor']['model']['document']['history']['version']),_0x452bd3['fromVersion']===_0x452bd3['toVersion']?(0x0!==_0x452bd3['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x452bd3['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x452bd3['id'],this['_startingVersion']=_0x452bd3['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',_0x173213=>!_0x173213),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0xd631cb=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x77eb74;for(const _0x10e893 in _0xd631cb){const _0x18a1c4=_0x10e893,_0x538d08=_0xd631cb[_0x18a1c4];if('revisionHistoryLicenseKeyValid'==_0x538d08||'revisionHistoryLicenseKeyInvalid'==_0x538d08||'revisionHistoryLicenseKeyExpired'==_0x538d08||'revisionHistoryLicenseKeyDomainLimit'==_0x538d08||'revisionHistoryLicenseKeyNotAllowed'==_0x538d08||'revisionHistoryLicenseKeyEvaluationLimit'==_0x538d08||'revisionHistoryLicenseKeyTrialLimit'==_0x538d08||'revisionHistoryLicenseKeyUsageLimit'==_0x538d08){delete _0xd631cb[_0x18a1c4],_0x77eb74=_0x538d08,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x77eb74&&_0xd631cb['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x77eb74&&_0xd631cb['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x77eb74&&_0xd631cb['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x77eb74&&_0xd631cb['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x77eb74&&_0xd631cb['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x77eb74&&_0xd631cb['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x77eb74&&_0xd631cb['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x3c4464=this['repository']['getRevision'](0x0),_0x3a4f13=await this['getRevisionDocumentData'](_0x3c4464),_0x1ea096=await this['getRevisionRootsAttributes'](_0x3c4464);this['_replaceEditorDataWithRevisionData'](_0x3a4f13,_0x1ea096);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x2ff32b){this['_source']=_0x2ff32b;}async['update'](){const _0xaf43c2=await this['_source']['getLatestVersion']();if(_0xaf43c2>this['currentRevision']['toVersion']){await this['_loadState']();const _0x1bc706=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0xaf43c2});_0x1bc706['authors']=_0x1bc706['authorsIds']['map'](_0x2e0ab0=>this['editor']['plugins']['get']('Users')['getUser'](_0x2e0ab0)),this['currentRevision']['_update'](_0x1bc706);}}async['saveRevision'](_0x387c0d={},_0x226830=null){const _0x554688=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x226830>this['currentRevision']['toVersion']&&(_0x226830=null),null===_0x226830&&(_0x226830=await this['_source']['getLatestVersion']());const _0x922c68=this['_getFromVersion'](_0x226830),_0x6ec374=this['buildRevisionData']({'from':_0x922c68,'to':_0x226830});if(this['currentRevision']['toVersion']<_0x226830){const _0xe35cc6=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x226830,'to':_0x226830});_0xe35cc6['authors']=[],_0xe35cc6['authorsIds']=[],_0xe35cc6['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0xe35cc6,!0x0),delete _0xe35cc6['authors'],_0x554688['push'](_0xe35cc6);}_0x387c0d['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x387c0d['name']=_0x387c0d['name']||null,_0x387c0d['id']=_0x387c0d['id']||_0xc2c09a(),_0x387c0d={..._0x387c0d,..._0x6ec374};const _0x4cfc68=this['addRevisionData'](_0x387c0d);_0x554688['push'](_0x387c0d);const _0x18bc0f=this['repository']['getIndex'](_0x4cfc68);if(0x0!==_0x18bc0f){const _0x2c1bdf=this['repository']['getRevision'](_0x18bc0f-0x1);if(_0x2c1bdf['fromVersion']!==_0x226830){const _0x53deaa=this['_revisionDataBuilder']['getData'](_0x226830,_0x2c1bdf['toVersion']),_0x3f46d1={'id':_0x2c1bdf['id'],'diffData':_0x53deaa['diffData'],'authorsIds':_0x53deaa['authorsIds'],'authors':_0x53deaa['authorsIds']['map'](_0x4217e7=>this['editor']['plugins']['get']('Users')['getUser'](_0x4217e7)),'fromVersion':_0x226830};_0x2c1bdf===this['currentRevision']&&(_0x3f46d1['createdAt']=new Date(_0x387c0d['createdAt']['getTime']()+0xa)),_0x2c1bdf['_update'](_0x3f46d1,!0x0),delete _0x3f46d1['authors'],_0x554688['push'](_0x3f46d1);}}if(this['adapter']){for(const _0x2194e3 of _0x554688)this['_bufferUpdate'](_0x2194e3['id'],_0x2194e3,!0x0);this['sendBufferedUpdates']();}return _0x4cfc68;}['addRevisionData'](_0x2949e2){const _0x560dd7=this['repository']['createRevision'](_0x2949e2);return this['adapter']&&_0x560dd7['on']('_update',(_0x189c7a,_0x47bb9b,_0x3cc768)=>{_0x3cc768||(this['_bufferUpdate'](_0x47bb9b['id'],_0x47bb9b,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x560dd7,this['_findInsertionIndex'](_0x560dd7)),_0x560dd7;}async['getRevisionDocumentData'](_0x1c980c){return await this['_utils']['loadRevisionData'](_0x1c980c,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x1c980c);}async['getRevisionRootsAttributes'](_0x455019){return await this['_utils']['loadRevisionData'](_0x455019,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x455019);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x397ecb=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x4e99b9=0x0;_0x4e99b9<_0x397ecb['length'];_0x4e99b9++){const _0x4d1183=_0x397ecb[_0x4e99b9];let _0x437e6a=!0x1;for(const _0x116e59 of Object['keys'](_0x4d1183))void 0x0===_0x4d1183[_0x116e59]?delete _0x4d1183[_0x116e59]:'id'!==_0x116e59&&(_0x437e6a=!0x0);_0x437e6a||(_0x397ecb[_0x4e99b9]=null);}if(_0x397ecb=_0x397ecb['filter'](_0x47b34a=>null!==_0x47b34a),!_0x397ecb['length'])return;for(let _0x1f9ca2=0x0;_0x1f9ca2<_0x397ecb['length'];_0x1f9ca2++){const _0x2c53db=_0x397ecb[_0x1f9ca2];void 0x0!==_0x2c53db['fromVersion']&&void 0x0===_0x2c53db['toVersion']&&(_0x2c53db['toVersion']=this['repository']['getRevision'](_0x2c53db['id'])['toVersion']),void 0x0!==_0x2c53db['toVersion']&&void 0x0===_0x2c53db['fromVersion']&&(_0x2c53db['fromVersion']=this['repository']['getRevision'](_0x2c53db['id'])['fromVersion']);}const _0x523d7f=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x397ecb,_0x523d7f)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x49cb33=>{if(_0x49cb33){for(const _0x4f9641 of _0x49cb33)this['setRevisionData']({'id':_0x4f9641['id'],'createdAt':_0x4f9641['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0x34f25b=null,from:_0x5e86fd=null,to:_0x5f3c0f=null}){_0x5e86fd=null!==_0x5e86fd?_0x5e86fd:_0x34f25b['fromVersion'],_0x5f3c0f=null!==_0x5f3c0f?_0x5f3c0f:_0x34f25b['toVersion'];const _0xad62c4=this['_revisionDataBuilder']['getData'](_0x5e86fd,_0x5f3c0f),_0x1846f6={'diffData':_0xad62c4['diffData'],'authorsIds':_0xad62c4['authorsIds'],'fromVersion':_0x5e86fd,'toVersion':_0x5f3c0f};if(!_0x34f25b||_0x5f3c0f!==_0x34f25b['toVersion']){const _0x5db42=_0x5f3c0f-0x1,_0x48f147=this['_source']['history']['getOperation'](_0x5db42);_0x1846f6['createdAt']=_0x48f147&&_0x48f147['createdAt']||new Date();}if(this['_loadedStateData']&&_0x5e86fd===this['_loadedStateData']['fromVersion']){for(const _0x265422 of this['_loadedStateData']['authors'])_0x1846f6['authorsIds']['includes'](_0x265422['id'])||_0x1846f6['authorsIds']['push'](_0x265422['id']);}return _0x1846f6;}['_bufferUpdate'](_0x3c7099,_0x32afd0,_0x47751f){if(this['_bufferedUpdates']['has'](_0x3c7099)){const _0x108aaa=this['_bufferedUpdates']['get'](_0x3c7099);_0x32afd0=_0x47751f?{..._0x108aaa,..._0x32afd0}:{..._0x32afd0,..._0x108aaa};}this['_bufferedUpdates']['set'](_0x3c7099,_0x32afd0);}['setRevisionData'](_0x381fb3){const _0x577dc7=this['repository']['getRevision'](_0x381fb3['id']);if(_0x381fb3['createdAt']&&(_0x381fb3['createdAt']=new Date(_0x381fb3['createdAt'])),_0x381fb3['authorsIds']){const _0x2ea60e=this['editor']['plugins']['get']('Users');_0x381fb3['authors']=_0x381fb3['authorsIds']['map'](_0x23c739=>_0x2ea60e['getUser'](_0x23c739));}_0x577dc7['_update'](_0x381fb3,!0x0);}['_createInitialRevision'](_0x412f7d){const _0x240634=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x240634)this['_initialRevisionId']=_0x240634['id'];else{const _0x12042a=!this['editor']['model']['document']['roots']['find'](_0x4c77c5=>this['editor']['model']['hasContent'](_0x4c77c5)),_0x43c0e9=this['editor']['plugins']['get']('Users')['me']['id'],_0x4a70c1=R(this['editor']['locale'],_0x12042a?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x412f7d,'to':_0x412f7d,'id':this['_initialRevisionId'],'name':_0x4a70c1,'creatorId':_0x43c0e9});}}['_createCurrentRevision'](_0x177b1e){const _0x518941=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x518941),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x177b1e,'to':_0x177b1e,'id':_0x518941,'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'](_0x4b31de,_0x353c74){let _0x4cc71a=this['editor']['config']['get']('initialData'),_0x296cc6=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x4cc71a){_0x4cc71a={};for(const _0x108e6f of this['editor']['model']['document']['getRootNames']())_0x4cc71a[_0x108e6f]='';}if('string'==typeof _0x4cc71a&&(_0x4cc71a={'main':_0x4cc71a}),void 0x0===_0x296cc6){_0x296cc6={};for(const _0x32f339 of this['editor']['model']['document']['getRootNames']())_0x296cc6[_0x32f339]={};}let _0x8fe607=!0x1;const _0x180729=Object['keys'](_0x4cc71a),_0x5d4f2f=Object['keys'](_0x4b31de);for(const _0x1a122b of _0x180729){if(_0x4cc71a[_0x1a122b]!==_0x4b31de[_0x1a122b]&&''!==_0x4cc71a[_0x1a122b]['trim']()){_0x8fe607=!0x0;break;}if(!_0x343c2b(_0x296cc6[_0x1a122b],_0x353c74[_0x1a122b])&&Object['keys'](_0x296cc6[_0x1a122b])['length']>0x0){_0x8fe607=!0x0;break;}}_0x8fe607||(_0x8fe607=_0x5d4f2f['some'](_0x1eb472=>!this['editor']['model']['document']['getRoot'](_0x1eb472))),_0x8fe607&&_0x18fd47('editor-initial-data-replaced-with-revision-data',{'editorData':_0x4cc71a,'editorRootsAttributes':_0x296cc6,'revisionData':_0x4b31de,'revisionRootsAttributes':_0x353c74}),this['editor']['config']['set']('initialData',_0x4b31de),this['editor']['config']['set']('rootsAttributes',_0x353c74);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x169e7e=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x169e7e['add'](R(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0xe2986c){const _0x4fe206=this['repository']['getRevisions']();_0x4fe206['reverse']();let _0x10728b=0x0;for(;_0x10728b<_0x4fe206['length'];){const _0x14a90a=_0x4fe206[_0x10728b];if(_0x14a90a===this['currentRevision']){_0x10728b++;continue;}if(_0x14a90a['id']===this['_initialRevisionId'])break;const _0xcaf58=_0xe2986c['toVersion']-_0x14a90a['toVersion']||_0xe2986c['fromVersion']-_0x14a90a['fromVersion'];if(_0xcaf58>0x0)break;if(_0xcaf58<0x0)_0x10728b++;else{if(!_0xe2986c['creator']&&_0x14a90a['creator'])break;if(_0x14a90a['creator']||!_0xe2986c['creator']){if(_0xe2986c['createdAt']>_0x14a90a['createdAt'])break;_0x10728b++;}else _0x10728b++;}}return _0x10728b;}['_getFromVersion'](_0x202609){const _0x23ae78=this['repository']['getRevisions']();_0x23ae78['reverse'](),_0x23ae78['shift']();const _0x3419d2=_0x23ae78['find'](_0x48aeb1=>_0x48aeb1['toVersion']<=_0x202609)['toVersion'];return _0x3419d2<this['_startingVersion']?this['_startingVersion']:_0x3419d2;}['_makeRevision']({name:_0x3f4f8b,from:_0x3f9978,to:_0x90e88e,creatorId:_0x87f901,id:_0xf0b281}){const _0x41b19b=this['buildRevisionData']({'from':_0x3f9978,'to':_0x90e88e});_0x41b19b['name']=_0x3f4f8b,_0x41b19b['creatorId']=_0x87f901,_0x41b19b['id']=_0xf0b281;const _0x5da397=this['addRevisionData'](_0x41b19b);return this['adapter']&&this['_bufferUpdate'](_0x41b19b['id'],_0x41b19b,!0x0),_0x5da397;}['_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(_0x337fe5){this['editor']=_0x337fe5,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'](_0x48468d){this['source']=_0x48468d;const _0x4b3f4e=new Map(),_0x11982e=new Map(),_0xc01491=this['editor']['model']['document']['roots']['map'](_0x4360e1=>_0x4360e1['rootName']);for(const _0x522e03 of _0xc01491){const _0x438895=this['editor']['model']['document']['getRoot'](_0x522e03),_0x486538=x(_0x438895);_0x4b3f4e['set'](_0x522e03,_0x486538),_0x11982e['set'](_0x522e03,Object['fromEntries'](_0x438895['getAttributes']()));}const _0x1a118b=Array['from'](this['editor']['model']['markers'])['map'](_0x4ae5ef=>[_0x4ae5ef['name'],_0x4ae5ef['getRange']()]),_0x14dcbe=this['source']['version'];this['_saveMetaData'](_0x14dcbe,_0x4b3f4e,_0x1a118b,_0x11982e),this['_startingRevisionId']=this['_revisionId'];const _0x59cad1=new Map(),_0x1df771=new Map();for(const _0x4e7084 of _0xc01491){const _0x5d20a5=N(_0x4e7084);_0x59cad1['set'](_0x4e7084,_0x5d20a5),_0x1df771['set'](_0x4e7084,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x59cad1,[],_0x1df771);}['getData'](_0xef483b,_0x54846f){if(this['_lastFrom']===_0xef483b&&this['_lastTo']<=_0x54846f)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x54846f,!0x0);else{if(!this['_savedMetaData']['has'](_0xef483b)){const _0x377c44=this['_getPreviousFrom'](_0xef483b);this['_calculateMetaData'](_0x377c44,_0xef483b,!0x1);}this['_calculateMetaData'](_0xef483b,_0x54846f,!0x0);}return this['_lastFrom']=_0xef483b,this['_lastTo']=_0x54846f,this['_getState']();}['loadState'](_0x47b89a){const _0x95289f=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x47b89a['fromVersion'],this['_lastTo']=_0x47b89a['toVersion'];for(const _0x19c965 in _0x47b89a['diffData']){const _0x352445=_0x47b89a['diffData'][_0x19c965]['attachChange'],_0x403235=_0x4300e7(_0x47b89a['diffData'][_0x19c965]['attributesBefore'])||{},_0x222db6=_0x95289f['_makeModelFromViewString'](_0x47b89a['diffData'][_0x19c965]['deletions']);_0x222db6['rootName']=_0x19c965,_0x222db6['_isAttached']=!_0x352445||!_0x352445['isAttached'],_0x222db6['isAttached']=()=>_0x222db6['_isAttached'],this['_baseRoots']['set'](_0x19c965,_0x222db6),this['_baseRootsAttributes']['set'](_0x19c965,_0x403235),_0x352445&&this['_touchedRoots']['set'](_0x19c965,_0x352445);const _0x417aa7=this['_makeIdsRoot'](_0x222db6);this['_baseIdsRoots']['set'](_0x19c965,_0x417aa7);for(const [_0x3a5024,_0xa8a8e9]of _0x222db6['markers']){if(!_0x3a5024['startsWith']('revision:'))continue;const _0x2fe038=_0x3a5024['split'](':')[0x2];for(const _0x1914f8 of _0xa8a8e9['getWalker']({'singleCharacters':!0x0})){const _0x24e088=this['_getVidAttributeName'](_0x1914f8),_0x331733='elementEnd'==_0x1914f8['type']?_0x1914f8['previousPosition']['path']['slice'](0x0,-0x1):_0x1914f8['previousPosition']['path'],_0x2fee15=_0x417aa7['getNodeByPath'](_0x331733)['getAttribute'](_0x24e088);this['_touched']['set'](_0x2fee15,{'userId':_0x2fe038});}}}this['_startingRevisionId']=this['_revisionId'];const _0x45cbfa=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x224984=>!this['_touched']['has'](_0x224984));let _0x540f34=0x0;const _0x253414=new Map();for(const _0x57a8a0 in _0x47b89a['diffData']){const _0x4f2293=_0x47b89a['diffData'][_0x57a8a0]['attachChange'],_0x36427e=_0x4300e7(_0x47b89a['diffData'][_0x57a8a0]['attributesAfter'])||{},_0xd618b0=_0x95289f['_makeModelFromViewString'](_0x47b89a['diffData'][_0x57a8a0]['insertions']);_0xd618b0['rootName']=_0x57a8a0,_0xd618b0['_isAttached']=!_0x4f2293||_0x4f2293['isAttached'],_0xd618b0['isAttached']=()=>_0xd618b0['_isAttached'],this['_diffRoots']['set'](_0x57a8a0,_0xd618b0),this['_diffRootsAttributes']['set'](_0x57a8a0,_0x36427e);const _0x2e5cb0=this['_makeIdsRoot'](_0xd618b0,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x57a8a0,_0x2e5cb0),_0x253414['set'](_0x57a8a0,_0xd618b0['isAttached']()?_0x36427e:{});for(const [_0x21976b,_0x4c237d]of _0xd618b0['markers']){if(!_0x21976b['startsWith']('revision:'))continue;const _0x382065=_0x21976b['split'](':')[0x2];for(const _0x585668 of _0x4c237d['getWalker']({'singleCharacters':!0x0})){const _0x397034=this['_getVidAttributeName'](_0x585668),_0x5a48e2=this['_revisionId']++,_0x10860d='elementEnd'==_0x585668['type']?_0x585668['previousPosition']['path']['slice'](0x0,-0x1):_0x585668['previousPosition']['path'];_0x2e5cb0['getNodeByPath'](_0x10860d)['_setAttribute'](_0x397034,_0x5a48e2),this['_touched']['set'](_0x5a48e2,{'userId':_0x382065});}}for(const _0x4c448f of this['editor']['model']['createRangeIn'](_0xd618b0)['getWalker']({'singleCharacters':!0x0})){const _0x155d92=this['_getVidAttributeName'](_0x4c448f),_0xa1af08='elementEnd'==_0x4c448f['type']?_0x4c448f['previousPosition']['path']['slice'](0x0,-0x1):_0x4c448f['previousPosition']['path'],_0x500756=_0x2e5cb0['getNodeByPath'](_0xa1af08);_0x500756['getAttribute'](_0x155d92)>0x0||_0x500756['_setAttribute'](_0x155d92,_0x45cbfa[_0x540f34++]);}for(const [_0x54ba83,_0x565746]of _0xd618b0['markers'])_0x54ba83['startsWith']('revision:')||this['_markers']['set'](_0x54ba83,_0x565746);}const _0x502162=N('$graveyard');this['_baseRoots']['set']('$graveyard',_0x502162),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x502162,0x1));const _0x466ef7=N('$graveyard');this['_diffRoots']['set']('$graveyard',_0x466ef7),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x466ef7,0x1));const _0x743c56=Array['from'](this['_diffRoots'])['map'](([_0xf96d99,_0x3cee22])=>[_0xf96d99,x(_0x3cee22)]);this['_saveMetaData'](this['_lastTo'],_0x743c56,this['_markers'],_0x253414);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0x307114,_0x240a99,_0x1c2bc1,_0x3da24b){const _0x57f182=new Map(_0x240a99),_0xf1e4f0=new Map(_0x4300e7(_0x3da24b)),_0x2bde0e=new Map();for(const [_0xe7dc0,_0xd630ec]of _0x1c2bc1)_0x2bde0e['set'](_0xe7dc0,{'start':_0xd630ec['start']['clone'](),'end':_0xd630ec['end']['clone'](),'rootName':_0xd630ec['root']['rootName']});this['_savedMetaData']['set'](_0x307114,{'roots':_0x57f182,'markers':_0x2bde0e,'rootsAttributes':_0xf1e4f0});}['_removeMetaData'](_0x39306d){this['_savedMetaData']['delete'](_0x39306d);}['_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'](_0x313e74,_0x5220dc=null){let _0x1f1779=null;_0x313e74['is']('documentFragment')||(_0x1f1779=new _0x560940(_0x313e74['name'],{'vid_start':null===_0x5220dc?this['_revisionId']++:_0x5220dc++}));const _0x39e839=[];for(const _0x5d51e0 of _0x313e74['getChildren']())if(_0x5d51e0['is']('element')){_0x39e839['push'](this['_makeIdsRoot'](_0x5d51e0,_0x5220dc));const _0x4fbbf6=_0x39e839[_0x39e839['length']-0x1];null!==_0x5220dc&&(_0x5220dc=_0x4fbbf6['is']('element','$text')?_0x4fbbf6['getAttribute']('vid')+0x1:_0x4fbbf6['getAttribute']('vid_end')+0x1);}else{for(let _0x4cee1e=0x0;_0x4cee1e<_0x5d51e0['offsetSize'];_0x4cee1e++)_0x39e839['push'](new _0x560940('$text',{'vid':null===_0x5220dc?this['_revisionId']++:_0x5220dc++}));}if(_0x313e74['is']('documentFragment')){const _0x3e644b=N(_0x313e74['rootName']);return _0x3e644b['_insertChild'](0x0,_0x39e839),_0x3e644b;}return _0x1f1779['_setAttribute']('vid_end',null===_0x5220dc?this['_revisionId']++:_0x5220dc++),_0x1f1779['_insertChild'](0x0,_0x39e839),_0x1f1779;}['_calculateMetaData'](_0x562b09,_0x37ad88,_0x4df013){this['_reset']();const {roots:_0x22aa0a,markers:_0x3bb100,rootsAttributes:_0x5712c5}=this['_savedMetaData']['get'](_0x562b09);this['_baseRoots']=new Map(_0x22aa0a),this['_baseRootsAttributes']=new Map(_0x4300e7(_0x5712c5));for(const [_0x10c4fe,_0x281a3f]of this['_baseRoots'])if('$graveyard'!==_0x10c4fe&&(this['_diffRoots']['set'](_0x10c4fe,x(_0x281a3f)),this['_diffRootsAttributes']=new Map(_0x4300e7(_0x5712c5)),_0x4df013)){const _0x367e95=this['_revisionId'];this['_idsRoots']['set'](_0x10c4fe,this['_makeIdsRoot'](_0x281a3f)),this['_baseIdsRoots']['set'](_0x10c4fe,this['_makeIdsRoot'](_0x281a3f,_0x367e95));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',x(this['_baseRoots']['get']('$graveyard'))),_0x4df013&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x42ca61,_0xe0bb0c]of _0x3bb100){const _0x2dc4d7=this['_baseRoots']['get'](_0xe0bb0c['rootName']),_0x574756=this['_diffRoots']['get'](_0xe0bb0c['rootName']),_0x1311bf=new _0x3fb84c(this['_fixPosition'](_0xe0bb0c['start'],_0x2dc4d7),this['_fixPosition'](_0xe0bb0c['end'],_0x2dc4d7)),_0x41d58c=this['_fixRange'](_0x1311bf,_0x574756);_0x2dc4d7['markers']['set'](_0x42ca61,_0x1311bf),this['_markers']['set'](_0x42ca61,_0x41d58c);}this['_applyOperations'](_0x562b09,_0x37ad88,_0x4df013);}['_applyOperations'](_0x48f94f,_0xe265e2,_0x22bc27){for(const _0x297509 of this['source']['getOperations'](_0x48f94f,_0xe265e2))this['_handleOperation'](_0x297509,_0x22bc27);for(const _0x57ba4f of this['_diffRoots']['values']())_0x57ba4f['markers']['clear']();for(const [_0x28596b,_0x138dae]of this['_markers']){this['_diffRoots']['get'](_0x138dae['root']['rootName'])['markers']['set'](_0x28596b,_0x138dae['clone']());}const _0x2116b2=new Map(),_0x2f4c0f=new Map();for(const [_0x738aca,_0x36c21c]of this['_diffRoots'])_0x2116b2['set'](_0x738aca,x(_0x36c21c)),_0x2f4c0f['set'](_0x738aca,this['_diffRootsAttributes']['get'](_0x738aca));this['_saveMetaData'](_0xe265e2,_0x2116b2,this['_markers'],_0x2f4c0f);}['_getPreviousFrom'](_0x4368de){const _0x2271fd=Array['from'](this['_savedMetaData']['keys']());_0x2271fd['sort']((_0x1f5d28,_0x3ce12c)=>_0x1f5d28-_0x3ce12c),_0x2271fd['reverse']();for(const _0x4a2744 of _0x2271fd)if(_0x4a2744<_0x4368de)return _0x4a2744;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x392c08,_0x28455d){const _0x2581cc=Array['from'](_0x28455d['markers'])['map'](([_0x567b53,_0x37cfd0])=>[_0x567b53,this['_fixRange'](_0x37cfd0,_0x392c08)]);_0x392c08['markers']=new Map(_0x2581cc);}['_transformMarkers'](_0x3f1aee){for(const _0x37f34d of this['_markers']['values']()){const _0x34190e=_0x37f34d['getTransformedByOperation'](_0x3f1aee),_0x35b193=_0x3fb84c['_createFromRanges'](_0x34190e);_0x37f34d['start']=_0x35b193['start'],_0x37f34d['end']=_0x35b193['end'];}}['_handleOperation'](_0x34e319,_0x179a7c){if('addRoot'!=_0x34e319['type']&&'detachRoot'!=_0x34e319['type']){if('insert'==_0x34e319['type']){const _0x4a194b=_0x34e319['position']['root']['rootName'];this['_diffRoots']['has'](_0x4a194b)||(this['_diffRoots']['set'](_0x4a194b,N(_0x4a194b,!0x0)),this['_diffRootsAttributes']['set'](_0x4a194b,{}),_0x179a7c&&this['_idsRoots']['set'](_0x4a194b,N(_0x4a194b,!0x0)));}else{if('addRootAttribute'==_0x34e319['type']||'removeRootAttribute'==_0x34e319['type']||'changeRootAttribute'==_0x34e319['type'])return void this['_handleRootAttributeOperation'](_0x34e319);'marker'==_0x34e319['type']&&this['_handleMarkerOperation'](_0x34e319);}if('marker'!==_0x34e319['type']){const _0x5c69ea=this['_cloneOperation'](_0x34e319,this['_diffRoots']);_0x5c69ea['_execute'](),this['_transformMarkers'](_0x5c69ea);}if(_0x179a7c)switch(_0x34e319['type']){case'insert':this['_handleInsertOperation'](_0x34e319);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x34e319);break;case'merge':this['_handleMergeOperation'](_0x34e319);break;case'split':this['_handleSplitOperation'](_0x34e319);}}else this['_handleRootOperation'](_0x34e319,_0x179a7c);}['_cloneOperation'](_0x22a9d5,_0x3e79ab){const _0x25a695=_0x22a9d5['clone']();return _0x25a695['_authorId']=_0x22a9d5['_authorId'],this['_fixOperation'](_0x25a695,_0x3e79ab),_0x25a695;}['_getBaseVids'](_0x547bc8){return _0x547bc8['map'](_0x130f39=>{const _0x47d997=this['_getVidAttributeName'](_0x130f39);return Number(_0x130f39['item']['getAttribute'](_0x47d997));});}['_generateTape'](_0x4d8c78,_0x15ef56){if(_0x4d8c78['is']('element','$text'))_0x15ef56['push']({'item':_0x4d8c78,'type':'text'});else{_0x4d8c78['is']('element')&&_0x15ef56['push']({'item':_0x4d8c78,'type':'elementStart'});for(const _0x2e8c4e of _0x4d8c78['getChildren']())this['_generateTape'](_0x2e8c4e,_0x15ef56);_0x4d8c78['is']('element')&&_0x15ef56['push']({'item':_0x4d8c78,'type':'elementEnd'});}return _0x15ef56;}['_getState'](){const _0x5949d9=new Map(this['_touched']),_0x22b1b8=new Map(_0x5949d9),_0x3ba2e7=new Map(),_0x38e4d2={'insertions':{},'deletions':{}},_0x469d52={'insertions':{},'deletions':{}},_0x519665=new Map(),_0x4a8dae=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x4a8dae['delete']('$graveyard');for(const _0x1961d2 of _0x4a8dae){const _0x2d65f3=this['_diffRoots']['get'](_0x1961d2)||N(_0x1961d2,!0x1),_0xe03b17=this['_baseRoots']['get'](_0x1961d2)||N(_0x1961d2,!0x1);_0x2d65f3['isAttached']()||_0xe03b17['isAttached']()?(_0x38e4d2['insertions'][_0x1961d2]=x(_0x2d65f3),_0x38e4d2['deletions'][_0x1961d2]=x(_0xe03b17),this['_copyMarkers'](_0x38e4d2['deletions'][_0x1961d2],_0xe03b17),this['_copyMarkers'](_0x38e4d2['insertions'][_0x1961d2],_0x2d65f3),_0x469d52['insertions'][_0x1961d2]=this['_generateTape'](this['_idsRoots']['get'](_0x1961d2),[]),_0x469d52['deletions'][_0x1961d2]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x1961d2)||N(_0x1961d2,!0x1),[])):_0x4a8dae['delete'](_0x1961d2);}for(const _0x22ea23 of _0x4a8dae){const _0x9c5fc9=_0x469d52['insertions'][_0x22ea23];for(const _0x3d58eb of _0x9c5fc9){const _0x2fd3cf=this['_getVidAttributeName'](_0x3d58eb),_0x249789=_0x3d58eb['item']['getAttribute'](_0x2fd3cf);_0x22b1b8['delete'](_0x249789),_0x249789>=this['_startingRevisionId']&&_0x3ba2e7['set'](_0x249789,_0x5949d9['get'](_0x249789));}}for(const _0x180616 of _0x4a8dae){const _0x406a89=_0x469d52['insertions'][_0x180616],_0xd6df32=this['_getBaseVids'](_0x469d52['deletions'][_0x180616]);let _0x42c00e=0x0;for(const _0x20ddf8 of _0x406a89){const _0x5a6c7a=this['_getVidAttributeName'](_0x20ddf8),_0x58c036=_0x20ddf8['item']['getAttribute'](_0x5a6c7a);if(!_0x3ba2e7['has'](_0x58c036)&&!_0x519665['has'](_0x58c036)){if(_0x22b1b8['has'](_0x58c036))_0x42c00e++;else{if(_0x58c036!=_0xd6df32[_0x42c00e]){const _0x248adc=_0x5949d9['get'](_0x58c036)||_0x5949d9['get'](_0xd6df32[_0x42c00e]);for(;_0x58c036!=_0xd6df32[_0x42c00e];)_0x22b1b8['has'](_0xd6df32[_0x42c00e])||(_0x519665['set'](_0xd6df32[_0x42c00e],_0x248adc),_0x5949d9['set'](_0xd6df32[_0x42c00e],_0x248adc)),_0x42c00e++;}_0x42c00e++;}}}}for(const _0x42dc8c of _0x4a8dae){const _0x523979=_0x469d52['insertions'][_0x42dc8c];for(const _0x4f4c44 of _0x523979){const _0x129645=this['_getVidAttributeName'](_0x4f4c44),_0x1a1265=_0x4f4c44['item']['getAttribute'](_0x129645);if(_0x519665['has'](_0x1a1265)){const _0x5e4389=_0x519665['get'](_0x1a1265);_0x22b1b8['has'](_0x1a1265)||_0x22b1b8['set'](_0x1a1265,{..._0x5e4389}),_0x3ba2e7['set'](_0x1a1265,{..._0x5e4389});}}}for(const _0x3fc49e of _0x22b1b8['keys']())_0x3fc49e>=this['_startingRevisionId']&&_0x22b1b8['delete'](_0x3fc49e);const _0x5199e7=new Map();for(const _0x161fea of _0x4a8dae){let _0x258b69=_0x469d52['insertions'][_0x161fea];for(const _0x4375e8 of _0x258b69)if(_0x4375e8['item']['is']('element','tableCell')){const _0x1c6f5b=this['_getVidAttributeName'](_0x4375e8),_0x2f97da=_0x4375e8['item']['getAttribute'](_0x1c6f5b);if(_0x3ba2e7['has'](_0x2f97da)){const _0x41df1f=_0x4375e8['item']['parent']['parent']['getAttribute']('vid_start'),_0x147f65=_0x5199e7['get'](_0x41df1f)||new Set();_0x147f65['add'](_0x3ba2e7['get'](_0x2f97da)['userId']),_0x5199e7['set'](_0x41df1f,_0x147f65);}}_0x258b69=_0x469d52['deletions'][_0x161fea];for(const _0x315e8f of _0x258b69)if(_0x315e8f['item']['is']('element','tableCell')){const _0x8cbdad=this['_getVidAttributeName'](_0x315e8f),_0x1571a6=_0x315e8f['item']['getAttribute'](_0x8cbdad);if(_0x22b1b8['has'](_0x1571a6)){const _0x5c4cc3=_0x315e8f['item']['parent']['parent']['getAttribute']('vid_start'),_0x1c3acc=_0x5199e7['get'](_0x5c4cc3)||new Set();_0x1c3acc['add'](_0x22b1b8['get'](_0x1571a6)['userId']),_0x5199e7['set'](_0x5c4cc3,_0x1c3acc);}}for(const _0x276355 of _0x5199e7['keys']())(_0x3ba2e7['has'](_0x276355)||_0x22b1b8['has'](_0x276355))&&_0x5199e7['delete'](_0x276355);}for(const _0x25c0d3 of _0x4a8dae){const _0x42de56=_0x469d52['insertions'][_0x25c0d3];let _0x136887=null,_0x3399ef=null;for(const _0x49cab6 of _0x42de56){const _0xf98204=this['_getVidAttributeName'](_0x49cab6),_0x3501e9=_0x49cab6['item']['getAttribute'](_0xf98204),_0x2b1a44=_0x5199e7['get'](_0x3501e9);_0x2b1a44&&'elementStart'==_0x49cab6['type']&&(_0x136887=Array['from'](_0x2b1a44)[0x0],_0x3399ef=_0x49cab6['item']['getAttribute']('vid_end')),_0x136887&&(_0x22b1b8['set'](_0x3501e9,{'userId':_0x136887}),_0x3ba2e7['set'](_0x3501e9,{'userId':_0x136887})),_0x3501e9==_0x3399ef&&(_0x136887=null,_0x3399ef=null);}}const _0x46ae6c={},_0x21a8f5=new Set();for(const _0x40b100 of _0x4a8dae){const _0x172beb=_0x38e4d2['deletions'][_0x40b100],_0x82723d=_0x38e4d2['insertions'][_0x40b100];for(const {userId:_0x25b2d7}of this['_touchedMarkers']['values']())null!==_0x25b2d7&&_0x21a8f5['add'](_0x25b2d7);for(const {userId:_0x287604}of this['_touchedRoots']['values']())null!==_0x287604&&_0x21a8f5['add'](_0x287604);this['_markChanges'](_0x82723d,_0x469d52['insertions'][_0x40b100],_0x3ba2e7,'insertion',_0x21a8f5),this['_markChanges'](_0x172beb,_0x469d52['deletions'][_0x40b100],_0x22b1b8,'deletion',_0x21a8f5),_0x46ae6c[_0x40b100]={'insertions':this['_prepareViewToSave'](_0x82723d),'deletions':this['_prepareViewToSave'](_0x172beb),'attachChange':this['_touchedRoots']['get'](_0x40b100)||null,'attributesBefore':_0x4300e7(this['_baseRootsAttributes']['get'](_0x40b100))||{},'attributesAfter':_0x4300e7(this['_diffRootsAttributes']['get'](_0x40b100))};}return{'diffData':_0x46ae6c,'authorsIds':Array['from'](_0x21a8f5)};}['_processRootBeforeSave'](_0x472a77){for(const [,_0x401bec]of _0x472a77['markers']){const _0x32ba29=_0x401bec['start']['getAncestors']()['filter'](_0x55dfa1=>'tableCell'==_0x55dfa1['name']);for(const _0x1aa993 of _0x32ba29)0x1==_0x1aa993['childCount']&&_0x1aa993['getChild'](0x0)['is']('element','paragraph')&&_0x1aa993['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x9cc4dc){this['_processRootBeforeSave'](_0x9cc4dc);const _0x9cedcf=this['editor']['data']['toView'](_0x9cc4dc,{}),_0x1556f1=Array['from'](_0x9cedcf['getChildren']())['map'](_0x48f06c=>this['_getViewJson'](_0x48f06c));return JSON['stringify'](_0x1556f1);}['_getViewJson'](_0x2edff8){if(_0x2edff8['is']('$text'))return _0x2edff8['data'];{const _0x3df64c=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0x4ac12e=_0x2edff8,_0x5ed18e=this['editor']['data']['htmlProcessor']['domConverter'],_0x30b757={'type':_0x3df64c['_getTypeCharForViewElement'](_0x4ac12e),'name':_0x4ac12e['name'],'attributes':Array['from'](_0x4ac12e['getAttributes']()),'children':Array['from'](_0x4ac12e['getChildren']())['map'](_0x4e57a3=>this['_getViewJson'](_0x4e57a3))};if(_0x2edff8['is']('uiElement')&&'$comment'!=_0x2edff8['name']){const _0x5284b3=_0x2edff8['render'](_0x5ed18e['domDocument'],_0x5ed18e);_0x30b757['children']['push'](_0x5284b3['outerHTML']);}else{if(_0x2edff8['is']('rawElement')){const _0x422c07=_0x5ed18e['domDocument']['createElement'](_0x4ac12e['name']);_0x2edff8['render'](_0x422c07,_0x5ed18e),_0x30b757['children']['push'](_0x422c07['innerHTML']);}}const _0x3b9cd4=Array['from'](_0x4ac12e['getCustomProperties']());_0x3b9cd4['length']>0x0&&(_0x30b757['customProperties']=_0x3b9cd4);const _0x5d631e=_0x4ac12e['getFillerOffset']();return null!==_0x5d631e&&(_0x30b757['fillerOffset']=_0x5d631e),_0x30b757;}}['_markChanges'](_0x31533e,_0x3ccf27,_0x309e5d,_0x4d54de,_0x54bb4a){let _0x8faa5a=null,_0x1de26e=null,_0x790ce=0x0;const _0x145127=this['editor']['model'];for(let _0x5a120a=0x0;_0x5a120a<_0x3ccf27['length'];_0x5a120a++){const _0x1502e0=this['_getVidAttributeName'](_0x3ccf27[_0x5a120a]),_0x362ccc=_0x3ccf27[_0x5a120a]['item']['getAttribute'](_0x1502e0),_0x11e05d=_0x309e5d['get'](_0x362ccc),_0x2e9556=_0x5a120a==_0x3ccf27['length']-0x1;(!_0x8faa5a&&_0x11e05d&&(_0x8faa5a=_0x11e05d,_0x1de26e=_0x3ccf27[_0x5a120a]),_0x8faa5a&&(!_0x11e05d||_0x11e05d['userId']!=_0x8faa5a['userId']))&&(_0x50ab9d(_0x11e05d,P(_0x1de26e,_0x31533e,_0x145127),P(_0x3ccf27[_0x5a120a],_0x31533e,_0x145127)),_0x8faa5a=_0x11e05d||null,_0x1de26e=_0x11e05d?_0x3ccf27[_0x5a120a]:null),_0x8faa5a&&_0x2e9556&&_0x50ab9d(_0x11e05d,P(_0x1de26e,_0x31533e,_0x145127),V(_0x3ccf27[_0x5a120a],_0x31533e,_0x145127));}function _0x50ab9d(_0x434d97,_0x41418f,_0x4f8330){const _0x107f83=_0x8faa5a['userId'],_0xc45aa9='revision:'+_0x4d54de+':'+_0x107f83+':'+_0x790ce++,_0x984b24=_0x145127['createRange'](_0x41418f,_0x4f8330);_0x31533e['markers']['set'](_0xc45aa9,_0x984b24),null!==_0x107f83&&_0x54bb4a['add'](_0x107f83);}}['_getVidAttributeName'](_0x571572){switch(_0x571572['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x4ad214,_0x5a1f61){_0x4ad214['baseVersion']=null;for(const _0x25af6a in _0x4ad214){const _0x143e5e=_0x4ad214[_0x25af6a];if(_0x143e5e instanceof _0x5346a5){const _0x393a74=_0x5a1f61['get'](_0x143e5e['root']['rootName']);_0x4ad214[_0x25af6a]=this['_fixPosition'](_0x143e5e,_0x393a74);}if(_0x143e5e instanceof _0x3fb84c){const _0x137c27=_0x5a1f61['get'](_0x143e5e['root']['rootName']);_0x4ad214[_0x25af6a]=this['_fixRange'](_0x143e5e,_0x137c27);}'root'===_0x25af6a&&(_0x4ad214['root']=_0x5a1f61['get'](_0x4ad214['root']['rootName']));}}['_fixRange'](_0x469bbc,_0x4f5001){return this['editor']['model']['createRange'](this['_fixPosition'](_0x469bbc['start'],_0x4f5001),this['_fixPosition'](_0x469bbc['end'],_0x4f5001));}['_fixPosition'](_0x3e96a3,_0x5d2121){return this['editor']['model']['createPositionFromPath'](_0x5d2121,_0x3e96a3['path'],_0x3e96a3['stickiness']);}['_handleInsertOperation'](_0x5ecd1a){const _0x436475=this['_idsRoots']['get'](_0x5ecd1a['position']['root']['rootName']),_0x3d80f5=this['_fixPosition'](_0x5ecd1a['position'],_0x436475),_0x2d1e8e=null===_0x5ecd1a['_authorId']?null:_0x5ecd1a['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x1eadf9=_0x3d80f5['parent'],_0x38b516=this['_revisionId'],_0x44ec6f=[];for(const _0x569eb4 of _0x5ecd1a['nodes'])if(_0x569eb4['is']('element'))_0x44ec6f['push'](this['_makeIdsRoot'](_0x569eb4));else{for(let _0x32d196=0x0;_0x32d196<_0x569eb4['offsetSize'];_0x32d196++)_0x44ec6f['push'](new _0x560940('$text',{'vid':this['_revisionId']++}));}const _0x33108b=this['_revisionId'];for(let _0x46ff03=_0x38b516;_0x46ff03<_0x33108b;_0x46ff03++)this['_touched']['set'](_0x46ff03,{'userId':_0x2d1e8e});_0x1eadf9['_insertChild'](_0x3d80f5['offset'],_0x44ec6f);}['_handleMoveOperation'](_0x560be3){(_0x560be3=this['_cloneOperation'](_0x560be3,this['_idsRoots']))['_execute']();const _0x34f122=null===_0x560be3['_authorId']?null:_0x560be3['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x2ef9f0=_0x560be3['getMovedRangeStart'](),_0x1ee489=_0x2ef9f0['parent'],_0x2679b5=_0x2ef9f0['offset'];!function _0x47fb58(_0x29e6e7,_0x3228fb,_0x48d953,_0x1d598b){for(let _0xa221fe=_0x48d953;_0xa221fe<_0x1d598b;_0xa221fe++){const _0x534b81=_0x3228fb['getChild'](_0xa221fe);_0x534b81['is']('element','$text')?_0x29e6e7['set'](_0x534b81['getAttribute']('vid'),{'userId':_0x34f122}):(_0x29e6e7['set'](_0x534b81['getAttribute']('vid_start'),{'userId':_0x34f122}),_0x47fb58(_0x29e6e7,_0x534b81,0x0,_0x534b81['childCount']),_0x29e6e7['set'](_0x534b81['getAttribute']('vid_end'),{'userId':_0x34f122}));}}(this['_touched'],_0x1ee489,_0x2679b5,_0x2679b5+_0x560be3['howMany']);}['_handleMergeOperation'](_0x4d78bc){const _0x5c160d=null===(_0x4d78bc=this['_cloneOperation'](_0x4d78bc,this['_idsRoots']))['_authorId']?null:_0x4d78bc['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x126a02=_0x4d78bc['targetPosition']['parent'],_0x136827=_0x4d78bc['sourcePosition']['parent'],_0x39cf8b=_0x126a02['getAttribute']('vid_end'),_0x451638=_0x136827['getAttribute']('vid_start');_0x126a02['_setAttribute']('vid_end',_0x136827['getAttribute']('vid_end')),_0x136827['_setAttribute']('vid_end',_0x39cf8b),this['_touched']['set'](_0x451638,{'userId':_0x5c160d}),this['_touched']['set'](_0x39cf8b,{'userId':_0x5c160d}),_0x4d78bc['_execute']();}['_handleSplitOperation'](_0x399c35){const _0x51c115=null===(_0x399c35=this['_cloneOperation'](_0x399c35,this['_idsRoots']))['_authorId']?null:_0x399c35['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x107f34=_0x399c35['graveyardPosition'],_0x221385=_0x399c35['splitPosition']['parent'];_0x399c35['_execute']();const _0x1f2fd3=_0x221385['getAttribute']('vid_end'),_0x25627e=_0x399c35['insertionPosition']['nodeAfter'];if(_0x107f34){const _0x402b65=_0x25627e['getAttribute']('vid_end'),_0x204060=_0x221385['getAttribute']('vid_end');_0x221385['_setAttribute']('vid_end',_0x402b65),_0x25627e['_setAttribute']('vid_end',_0x204060),this['_touched']['set'](_0x221385['getAttribute']('vid_end'),{'userId':_0x51c115}),this['_touched']['set'](_0x25627e['getAttribute']('vid_start'),{'userId':_0x51c115});}else{const _0x39620b=this['_revisionId']++,_0x1a2149=this['_revisionId']++;_0x221385['_setAttribute']('vid_end',_0x39620b),_0x25627e['_setAttribute']('vid_start',_0x1a2149),_0x25627e['_setAttribute']('vid_end',_0x1f2fd3),this['_touched']['set'](_0x39620b,{'userId':_0x51c115}),this['_touched']['set'](_0x1a2149,{'userId':_0x51c115});}}['_handleMarkerOperation'](_0x3c3f39){if(!_0x3c3f39['affectsData'])return;const _0x552195=(_0x3c3f39=this['_cloneOperation'](_0x3c3f39,this['_diffRoots']))['oldRange']?_0x3c3f39['oldRange']['root']:null,_0xb94ac3=_0x3c3f39['newRange']?_0x3c3f39['newRange']['root']:null;_0x552195&&this['_markers']['delete'](_0x3c3f39['name']),_0xb94ac3&&this['_markers']['set'](_0x3c3f39['name'],_0x3c3f39['newRange']['clone']());const _0x3b0e2c=null===_0x3c3f39['_authorId']?null:_0x3c3f39['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x246852=_0x3c3f39['name'];if(!this['_touchedMarkers']['has'](_0x246852))return void this['_touchedMarkers']['set'](_0x246852,{'range':_0x3c3f39['oldRange'],'userId':_0x3b0e2c});const _0x3cb8fe=this['_touchedMarkers']['get'](_0x246852),_0x16ead2=_0x3cb8fe['range'],_0x5a7aa2=_0x3c3f39['newRange'];null==_0x16ead2&&null==_0x5a7aa2||_0x16ead2&&_0x5a7aa2&&_0x16ead2['isEqual'](_0x5a7aa2)?this['_touchedMarkers']['delete'](_0x3c3f39['name']):_0x3cb8fe['userId']=_0x3b0e2c;}['_handleRootOperation'](_0x37c908,_0x35923f){this['_diffRoots']['has'](_0x37c908['rootName'])?this['_diffRoots']['get'](_0x37c908['rootName'])['_isAttached']=_0x37c908['isAdd']:(this['_diffRoots']['set'](_0x37c908['rootName'],N(_0x37c908['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x37c908['rootName'],{}),_0x35923f&&this['_idsRoots']['set'](_0x37c908['rootName'],N(_0x37c908['rootName'],!0x0)));const _0x190ef8=null===_0x37c908['_authorId']?null:_0x37c908['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0xd41f9e=this['_touchedRoots']['get'](_0x37c908['rootName']);_0xd41f9e&&_0xd41f9e['userId']===_0x190ef8?this['_touchedRoots']['delete'](_0x37c908['rootName']):this['_touchedRoots']['set'](_0x37c908['rootName'],{'userId':_0x190ef8,'isAttached':_0x37c908['isAdd']});}['_handleRootAttributeOperation'](_0x22a6ba){const _0x572604=this['_diffRootsAttributes']['get'](_0x22a6ba['root']['rootName']);null===_0x22a6ba['newValue']?delete _0x572604[_0x22a6ba['key']]:_0x572604[_0x22a6ba['key']]=_0x22a6ba['newValue'];}}function x(_0x55ced3){const _0x2d8d30=N(_0x55ced3['rootName'],_0x55ced3['isAttached']());for(const _0x3b7f39 of _0x55ced3['getChildren']()){const _0x421f1b=_0x3b7f39['_clone'](!0x0);_0x2d8d30['_appendChild'](_0x421f1b);}return _0x2d8d30;}function N(_0x825346,_0x3cc685=!0x0){const _0x35ac35=new _0x8e7ca7();return _0x35ac35['rootName']=_0x825346,_0x35ac35['_isAttached']=_0x3cc685,_0x35ac35['isAttached']=()=>_0x35ac35['_isAttached'],_0x35ac35;}function P(_0x1769f5,_0x345fd5,_0x59eb1b){const _0x147897='elementEnd'==_0x1769f5['type']?_0x59eb1b['createPositionAt'](_0x1769f5['item'],'end'):_0x59eb1b['createPositionBefore'](_0x1769f5['item']);return _0x59eb1b['createPositionFromPath'](_0x345fd5,_0x147897['path'],_0x147897['stickiness']);}function V(_0x35ca9a,_0x3f5c7a,_0x2cc2c6){const _0x2c5cd0='elementStart'==_0x35ca9a['type']?_0x2cc2c6['createPositionAt'](_0x35ca9a['item'],0x0):_0x2cc2c6['createPositionAfter'](_0x35ca9a['item']);return _0x2cc2c6['createPositionFromPath'](_0x3f5c7a,_0x2c5cd0['path'],_0x2c5cd0['stickiness']);}class he extends/* #__PURE__ -- @preserve */
|
|
25
|
+
_0x105b56(_0x13ae3e){['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x467b34,_0x8a5ecb){super(_0x467b34),this['focusTracker']=new _0x33a359(),this['keystrokes']=new _0x15232b(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x8a5ecb),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'](),_0x10e463({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x180457=_0x504ecd=>_0x504ecd['stopPropagation']();this['keystrokes']['set']('arrowright',_0x180457),this['keystrokes']['set']('arrowleft',_0x180457),this['keystrokes']['set']('arrowup',_0x180457),this['keystrokes']['set']('arrowdown',_0x180457);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x11e709){this['revisionNameInputView']['fieldView']['element']['value']=_0x11e709['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x6c55ea){const _0x3dad4f=new ti(this['locale'],_0x14027c),_0x148f5f=_0x3dad4f['fieldView'];_0x148f5f['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x5e11cf=R(this['locale'],'Name\x20of\x20the\x20revision');return!_0x6c55ea&&(_0x5e11cf+='\x20('+R(this['locale'],'optional')+')'),(_0x3dad4f['label']=_0x5e11cf,_0x148f5f['on']('input',()=>{this['revisionNameInputValue']=_0x148f5f['element']['value']['trim']();}),_0x3dad4f);}}class v extends _0x5b0dba{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h];}['_saveRevisionFormView'];['init'](){const _0x1017b2=this['editor'],_0x24fee9=_0x1017b2['plugins']['get']('RevisionTracker');_0x1017b2['ui']['componentFactory']['add']('revisionHistory',_0x118c42=>{const _0x4f3402=_0x2ef58a(_0x118c42),_0x5139ab=_0x4f3402['panelView']['children'],_0x33707b=new _0x34e818(_0x118c42),_0x5c52d3=new _0x5b3d8d(_0x118c42),_0x499a23=new _0xbf084f(_0x118c42),_0x11cd2f=new _0x5b3d8d(_0x118c42),_0x47c790=new _0xbf084f(_0x118c42);return _0x4f3402['bind']('isEnabled')['to'](_0x24fee9,'isReady',_0x24fee9,'isEnabled',_0x1017b2,'isReadOnly',(_0x3b9bdd,_0x574fa1,_0x41d7a2)=>_0x3b9bdd&&_0x574fa1&&!_0x41d7a2),_0x4f3402['buttonView']['set']({'icon':_0x2efa8c,'label':R(_0x118c42,'Revision\x20history'),'tooltip':!0x0}),_0x499a23['set']({'label':R(_0x118c42,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x499a23['bind']('isEnabled')['to'](_0x24fee9,'isReady',_0x24fee9,'isEnabled',_0x1017b2,'isReadOnly',(_0x4b633c,_0x2d6744,_0x5abafb)=>_0x4b633c&&_0x2d6744&&!_0x5abafb),_0x499a23['on']('execute',()=>this['_showDialog']()),_0x47c790['set']({'label':R(_0x118c42,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x47c790['bind']('isEnabled')['to'](_0x24fee9,'isReady',_0x1017b2,'isReadOnly',(_0x2ef31b,_0x281294)=>_0x2ef31b&&!_0x281294),_0x47c790['on']('execute',()=>{_0x1017b2['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x4f3402['isOpen']=!0x1,_0x1017b2['editing']['view']['focus']();}),_0x5c52d3['children']['add'](_0x499a23),_0x11cd2f['children']['add'](_0x47c790),_0x33707b['role']='menu',_0x33707b['items']['addMany']([_0x5c52d3,_0x11cd2f]),_0x5139ab['add'](_0x33707b),_0x4f3402;}),_0x1017b2['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x278472=this['editor'],_0x446442=_0x278472['locale'],_0x20424e=new _0x3a0adb(_0x446442),_0x1e0c9c=new _0x221b21(_0x446442);_0x20424e['buttonView']['set']({'icon':_0x2efa8c,'label':R(_0x446442,'Revision\x20history')});const _0x535415=new _0x2a567a(_0x446442,_0x20424e),_0x457a8c=new _0x5eafa3(_0x446442);_0x457a8c['set']({'label':R(_0x446442,'Save\x20current\x20revision')}),_0x457a8c['delegate']('execute')['to'](_0x20424e),_0x457a8c['on']('execute',()=>{this['_showDialog']();}),_0x535415['children']['add'](_0x457a8c),_0x1e0c9c['items']['add'](_0x535415);const _0x133b89=new _0x2a567a(_0x446442,_0x20424e),_0x2d37cd=new _0x5eafa3(_0x446442);return _0x2d37cd['set']({'label':R(_0x446442,'Open\x20revision\x20history')}),_0x2d37cd['delegate']('execute')['to'](_0x20424e),_0x2d37cd['on']('execute',()=>{_0x278472['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x133b89['children']['add'](_0x2d37cd),_0x1e0c9c['items']['add'](_0x133b89),_0x20424e['panelView']['children']['add'](_0x1e0c9c),_0x20424e;}['_showDialog'](){const _0x76d4a0=this['editor'],_0x2025ec=_0x76d4a0['locale'],_0x3195cb=_0x76d4a0['plugins']['get']('Dialog'),_0x413fac=_0x76d4a0['plugins']['get']('RevisionTracker');function _0x41a5c6(_0x57926d){_0x76d4a0['config']['get']('revisionHistory.requireRevisionName')&&''===_0x57926d['revisionName']?_0x57926d['revisionNameInputView']['errorText']=R(_0x2025ec,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x76d4a0['plugins']['get'](h)['saveRevision']({'name':_0x57926d['revisionName']}),_0x3195cb['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x41a5c6(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x3195cb['show']({'id':'revisionSave','title':R(_0x2025ec,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':R(_0x76d4a0['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x3195cb['hide']()},{'label':R(_0x76d4a0['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x5e2aae){_0x5e2aae['bind']('isEnabled')['to'](_0x413fac,'isReady',_0x413fac,'isEnabled',_0x76d4a0,'isReadOnly',(_0x575470,_0x49bef4,_0x208d02)=>_0x575470&&_0x49bef4&&!_0x208d02);},'onExecute':()=>_0x41a5c6(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x1738ca=this['editor'],_0x294e9b=_0x1738ca['locale'];this['_saveRevisionFormView']=new he(_0x294e9b,_0x1738ca['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class z extends _0x13ae3e{['changeId'];['_model'];constructor(_0x9f8d1,_0x4be0c7){super(_0x9f8d1),this['_model']=_0x4be0c7,this['changeId']=_0x4be0c7['id'];const _0x51dca2=this['bindTemplate'],_0x23812a=R(_0x9f8d1,_0x4be0c7['data']['isSuggestion']?'Suggested\x20by':'add'==_0x4be0c7['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x4be0c7['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x51dca2['to']('type',_0x33e168=>'ck-revision-change__'+_0x33e168)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x23812a}]},{'text':'\x20'+_0x4be0c7['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class G extends/* #__PURE__ -- @preserve */
|
|
26
|
+
_0x255515(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x4f0a03){super(),this['id']=_0x4f0a03['id']||_0xc2c09a(),this['author']=_0x4f0a03['author'],this['type']=_0x4f0a03['type'],this['data']=_0x4f0a03['data']||{},this['rootName']=_0x4f0a03['rootName'],this['set']('createdAt',_0x4f0a03['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(_0x58d2af,_0x56607c){this['newRevisionId']=_0x58d2af,this['oldRevisionId']=_0x56607c,this['changes']=new _0x577801();}['_setChanges'](_0x5f563c){for(const _0x5a7f64 of _0x5f563c)this['changes']['add'](_0x5a7f64);}}class l extends _0x5b0dba{['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[_0x156c7a,_0x56c3c6,S,$];}constructor(_0x297baf){super(_0x297baf),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',(_0x425f76,_0x10188e,_0x2942fa)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x612070=>{for(const _0x319972 of this['editor']['editing']['view']['document']['roots'])_0x2942fa?_0x612070['removeClass']('ck-editor__editable__overlay',_0x319972):_0x612070['addClass']('ck-editor__editable__overlay',_0x319972);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x27c8ad=>null!==_0x27c8ad),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x370b24,_0x167add,_0x423ff9)=>_0x370b24&&_0x423ff9?_0x167add['changes']['getIndex'](_0x423ff9):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x3a78fc,_0x35d7fd)=>_0x3a78fc?_0x35d7fd['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0x56c3c6);}['init'](){const _0x2b65fa=this['editor'],_0x262ff5=new ot(_0x2b65fa,{'direction':'backward'}),_0x190587=new ot(_0x2b65fa,{'direction':'forward'});(_0x2b65fa['commands']['add']('showPreviousChange',_0x262ff5),_0x2b65fa['commands']['add']('showNextChange',_0x190587),_0x2b65fa['commands']['add']('restoreRevision',new nt(_0x2b65fa)),this['on']('change:numberOfChanges',()=>{_0x262ff5['refresh'](),_0x190587['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x2b65fa['enableReadOnlyMode']('revision-viewer'),_0x2b65fa['plugins']['has']('WidgetToolbarRepository'))&&_0x2b65fa['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x4be3a6){return await this['_utils']['loadRevisionData'](_0x4be3a6,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x4be3a6);}async['getRevisionRootsAttributes'](_0x397d07){return await this['_utils']['loadRevisionData'](_0x397d07,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x397d07);}async['compare'](_0x3a582e,_0xdc65a3,_0x4f9eaf=!0x1){if(!this['isEnabled'])return;const _0x40cd41=this['diff'],_0x4f3a0d=this['repository'],_0x3af9bc='string'==typeof _0x3a582e?_0x4f3a0d['getRevision'](_0x3a582e):_0x3a582e,_0x25537a='string'==typeof _0xdc65a3?_0x4f3a0d['getRevision'](_0xdc65a3):_0xdc65a3,_0x2610d8=_0x3af9bc['id'],_0x4c2b8a=_0x25537a?_0x25537a['id']:null;if(!_0x4f9eaf&&this['diff']&&this['diff']['newRevisionId']===_0x2610d8&&this['diff']['oldRevisionId']===_0x4c2b8a)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new J(_0x2610d8,_0x4c2b8a);const _0x3cb890=this['_getRevisionsRange'](_0x3af9bc,_0x25537a,!0x0)['map'](_0x4b5a9d=>this['_utils']['loadRevisionData'](_0x4b5a9d,this['adapter']));return _0x3cb890['push'](new Promise(_0x5337d9=>{setTimeout(_0x5337d9,0x14);})),Promise['all'](_0x3cb890)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x19d1fd=this['_getDiff'](_0x2610d8,_0x4c2b8a);for(const _0x3900b4 of _0x19d1fd['changes'])this['_changeIdToChange']['set'](_0x3900b4['id'],_0x3900b4);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x129010=>{for(const _0x17679a of this['editor']['model']['document']['getRootNames']())_0x129010['detachRoot'](_0x17679a);for(const _0x29e5ba of Object['keys'](_0x19d1fd['model'])){const _0x92e3c5=_0x129010['addRoot'](_0x29e5ba);for(const _0x1e1f8c of Object['keys'](_0x19d1fd['attributes'][_0x29e5ba]))_0x129010['setAttribute'](_0x1e1f8c,_0x19d1fd['attributes'][_0x29e5ba][_0x1e1f8c],_0x92e3c5);_0x129010['insert'](_0x19d1fd['model'][_0x29e5ba],_0x92e3c5,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x19d1fd['changes'])),this['isReady']=!0x0;})['catch'](_0x1803f1=>{console['error'](_0x1803f1),this['_cleanUp'](),_0x40cd41&&(this['diff']=_0x40cd41),this['isReady']=!0x0;});}['addRevisionData'](_0x530f3d,_0x2d27fe){const _0x1a37ed=this['repository']['createRevision'](_0x530f3d);return _0x1a37ed['on']('_update',(_0xadf10f,_0x30eb16,_0x2acbf1)=>_0x2d27fe(_0x30eb16,_0x2acbf1,_0x1a37ed)),this['repository']['addRevision'](_0x1a37ed),_0x1a37ed;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x404ef7=>{for(const _0x214a6c of this['editor']['model']['document']['getRootNames']())_0x404ef7['detachRoot'](_0x214a6c);});}['_sortAndFilterDiffChanges'](_0x4a96d4){const _0x2d7883=[],_0x452998=new Map();for(const _0x1069a0 of this['editor']['model']['document']['getRootNames']()){const _0x36bb31=this['editor']['editing']['view']['getDomRoot'](_0x1069a0);if(!_0x36bb31)continue;const _0x2030a4=_0x36bb31['getClientRects']()['item'](0x0);_0x2030a4&&(_0x2d7883['push'](_0x1069a0),_0x452998['set'](_0x1069a0,_0x2030a4));}return _0x2d7883['sort']((_0x1761af,_0x2eef16)=>{const _0x499a48=_0x452998['get'](_0x1761af),_0x1c6298=_0x452998['get'](_0x2eef16);return _0x499a48['y']-_0x1c6298['y']||_0x499a48['x']-_0x1c6298['x'];}),(_0x4a96d4=_0x4a96d4['filter'](_0x3cf37a=>_0x2d7883['includes'](_0x3cf37a['rootName'])))['sort']((_0x39b7cd,_0x29a31e)=>_0x2d7883['indexOf'](_0x39b7cd['rootName'])-_0x2d7883['indexOf'](_0x29a31e['rootName'])),_0x4a96d4;}['_makeTape'](_0x5c4b4d){const _0x5cb5e4=Array['from'](_0x5c4b4d['markers'])['filter'](([_0x591547,_0x3b9954])=>_0x591547['startsWith']('revision:')&&!_0x3b9954['isCollapsed']),_0x38d588=Array['from'](this['editor']['model']['createRangeIn'](_0x5c4b4d)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x5cb5e4['length'])for(const _0xae0731 of _0x38d588){const [_0x3d5d6a,_0x4e0d06]=_0x5cb5e4[0x0],[,_0x408823,_0x1c277a]=_0x3d5d6a['split'](':');if(_0x4e0d06['end']['isEqual'](_0xae0731['nextPosition'])&&_0x5cb5e4['shift'](),(_0xae0731['previousPosition']['isEqual'](_0x4e0d06['start'])||_0xae0731['previousPosition']['isAfter'](_0x4e0d06['start']))&&('insertion'==_0x408823?_0xae0731['isAdded']={'userId':_0x1c277a}:'deletion'==_0x408823&&(_0xae0731['isRemoved']={'userId':_0x1c277a})),0x0==_0x5cb5e4['length'])break;}return _0x38d588;}['_refreshStartEndIndex'](_0x4d8656){const _0x1f36e6=new Map();for(let _0x1e8161=0x0;_0x1e8161<_0x4d8656['length'];_0x1e8161++)'text'===_0x4d8656[_0x1e8161]['type']?(_0x4d8656[_0x1e8161]['item']['startIndex']=_0x1e8161,_0x4d8656[_0x1e8161]['item']['endIndex']=_0x1e8161):('elementStart'===_0x4d8656[_0x1e8161]['type']?_0x4d8656[_0x1e8161]['item']['startIndex']=_0x1e8161:'elementEnd'===_0x4d8656[_0x1e8161]['type']&&(_0x4d8656[_0x1e8161]['item']['endIndex']=_0x1e8161),_0x1f36e6['set'](_0x4d8656[_0x1e8161]['id'],_0x1e8161));for(const _0x28549f of _0x1f36e6['values']())'elementStart'===_0x4d8656[_0x28549f]['type']?_0x4d8656[_0x28549f]['item']['endIndex']=_0x1f36e6['get'](_0x4d8656[_0x28549f]['pairId']):'elementEnd'===_0x4d8656[_0x28549f]['type']&&(_0x4d8656[_0x28549f]['item']['startIndex']=_0x1f36e6['get'](_0x4d8656[_0x28549f]['pairId']));}['_processTape'](_0x4cf8ba){for(let _0x74ab28=0x0;_0x74ab28<_0x4cf8ba['length'];_0x74ab28++){if('elementStart'===_0x4cf8ba[_0x74ab28]['type'])_0x4cf8ba[_0x74ab28]['item']['startIndex']=_0x74ab28;else{if('elementEnd'===_0x4cf8ba[_0x74ab28]['type']){_0x4cf8ba[_0x74ab28]['item']['endIndex']=_0x74ab28;const _0x215a87=_0x4cf8ba[_0x74ab28]['item']['startIndex'];_0x4cf8ba[_0x215a87]['pairId']=_0x4cf8ba[_0x74ab28]['id'],_0x4cf8ba[_0x74ab28]['pairId']=_0x4cf8ba[_0x215a87]['id'];}else _0x4cf8ba[_0x74ab28]['item']['startIndex']=_0x74ab28,_0x4cf8ba[_0x74ab28]['item']['endIndex']=_0x74ab28,_0x4cf8ba[_0x74ab28]['pairId']=null;}_0x4cf8ba[_0x74ab28]['markersStart']||(_0x4cf8ba[_0x74ab28]['markersStart']=[],_0x4cf8ba[_0x74ab28]['markersEnd']=[]);}}['_markInsertions'](_0x1fc1c7,_0x156411){const _0x2d1c64=_0x1fc1c7['filter'](_0x5d6fc2=>!_0x5d6fc2['isAdded']);for(let _0x3a8643=0x0;_0x3a8643<_0x156411['length'];_0x3a8643++)_0x156411[_0x3a8643]['isAdded']&&(_0x2d1c64[_0x3a8643]['isAdded']=_0x156411[_0x3a8643]['isAdded']);}['_getDiff'](_0x302ce9,_0x39b7fd=null){const _0x3f5055=this['repository']['getRevision'](_0x302ce9),_0xffe23d=_0x39b7fd?this['repository']['getRevision'](_0x39b7fd):null,_0x247282=this['_getRevisionsRange'](_0x3f5055,_0xffe23d),_0x5ce5c1=_0x247282[_0x247282['length']-0x1],_0x12ccf0=new Map(),_0x26f965={'model':{},'attributes':{},'changes':[]},_0x4846a2=new Set(),_0x51ea7e=new Map();for(let _0xd8c270=_0x247282['length']-0x1;_0xd8c270>=0x0;_0xd8c270--){const _0x50e2e5=_0x247282[_0xd8c270];for(const _0x306713 of Object['keys'](_0x50e2e5['diffData']))if(_0x50e2e5['diffData'][_0x306713]['attachChange']){const _0x174c93=_0x50e2e5['diffData'][_0x306713]['attachChange'];_0x174c93['isAttached']?(_0x4846a2['add'](_0x306713),_0x51ea7e['has'](_0x306713)&&_0x51ea7e['get'](_0x306713)['userId']==_0x174c93['userId']?_0x51ea7e['delete'](_0x306713):_0x51ea7e['set'](_0x306713,_0x174c93)):_0x51ea7e['has'](_0x306713)?(_0x4846a2['delete'](_0x306713),_0x51ea7e['delete'](_0x306713)):(_0x4846a2['add'](_0x306713),_0x51ea7e['set'](_0x306713,_0x174c93));}else _0x4846a2['add'](_0x306713);}for(const _0x1fadac of _0x4846a2){const _0x5e7ecc=_0x51ea7e['has'](_0x1fadac)&&!_0x51ea7e['get'](_0x1fadac)['isAttached'];let _0x3d5b24=_0x5e7ecc?_0x247282['length']-0x1:0x0;const _0x4c555b=_0x5e7ecc?-0x1:0x1;for(;_0x247282[_0x3d5b24];){const _0x42eee9=_0x247282[_0x3d5b24];if(_0x42eee9['diffData'][_0x1fadac]){const _0x1e29ee=_0x5e7ecc?_0x42eee9['diffData'][_0x1fadac]['attributesBefore']:_0x42eee9['diffData'][_0x1fadac]['attributesAfter'];_0x26f965['attributes'][_0x1fadac]=_0x1e29ee?_0x4300e7(_0x1e29ee):{};break;}_0x3d5b24+=_0x4c555b;}}for(const _0x5655c8 of _0x247282){_0x5655c8['model']={};for(const _0x280cff of _0x5655c8['authors'])_0x12ccf0['set'](_0x280cff['id'],_0x280cff);for(const _0x2dcdcf of _0x4846a2){const _0x244da0=_0x5655c8['diffData'][_0x2dcdcf]?_0x5655c8['diffData'][_0x2dcdcf]['insertions']:'[]',_0x3818b8=_0x5655c8['diffData'][_0x2dcdcf]?_0x5655c8['diffData'][_0x2dcdcf]['deletions']:'[]';_0x5655c8['model'][_0x2dcdcf]={'insertions':this['_utils']['_makeModelFromViewString'](_0x244da0),'deletions':this['_utils']['_makeModelFromViewString'](_0x3818b8)};}}for(const _0x3a8c9c of _0x4846a2){let _0x1ded08=null,_0x1769ad=0x0;const _0x549ceb=new Map(Array['from'](_0x3f5055['model'][_0x3a8c9c]['insertions']['markers'])['filter'](([_0x394566])=>!_0x394566['startsWith']('revision:')));let _0x36fa29=0x0;for(const _0x3c0484 of _0x247282){const _0x4ae524=this['_makeTape'](_0x3c0484['model'][_0x3a8c9c]['insertions']);_0x3c0484==_0x3f5055?(_0x1ded08=_0x4ae524,_0x1769ad=_0x1ded08['length'],_0x1ded08['forEach'](_0x337856=>{_0x337856['id']=_0x36fa29++;}),this['_processTape'](_0x1ded08)):this['_markInsertions'](_0x1ded08,_0x4ae524);const _0x19c9ef=_0x1ded08['filter'](_0x4e3ab3=>!_0x4e3ab3['isAdded'])['map'](_0x3e8dda=>_0x3e8dda['id']);let _0x1976d7=0x0;const _0x41b795=this['_makeTape'](_0x3c0484['model'][_0x3a8c9c]['deletions']);_0x41b795['forEach'](_0x50caac=>{_0x50caac['isRemoved']?_0x50caac['id']=_0x1769ad++:_0x50caac['id']=_0x19c9ef[_0x1976d7++];}),this['_processTape'](_0x41b795),this['_setDistance'](_0x1ded08,'isAdded'),this['_setDistance'](_0x41b795,'isRemoved'),_0x3c0484==_0x3f5055&&this['_markMarkers'](_0x1ded08,_0x549ceb),_0x1ded08=this['_joinTapes'](_0x1ded08,_0x41b795),this['_refreshStartEndIndex'](_0x1ded08),this['_setDistance'](_0x1ded08,'isRemoved');}_0x1ded08=_0x1ded08['filter'](_0x43391a=>!(_0x43391a['isAdded']&&_0x43391a['isRemoved']));const _0x2e4272=new Map(_0x5ce5c1['model'][_0x3a8c9c]['deletions']['markers']),_0x51bfc8=new Set(_0x549ceb['keys']());for(const _0x289817 of _0x2e4272['keys']())_0x51bfc8['delete'](_0x289817);this['_markSuggestions'](_0x1ded08,_0x51bfc8),this['_fixObsoleteTags'](_0x1ded08),_0x1ded08=this['_removeMissingPairs'](_0x1ded08),_0x1ded08=this['_markMismatchedRemovedTags'](_0x1ded08),_0x1ded08=this['_removeUnsupportedChanges'](_0x1ded08);const {root:_0x518e8a,changes:_0x10b956}=this['_makeModelFromTape'](_0x1ded08,_0x12ccf0,_0x3a8c9c);_0x26f965['model'][_0x3a8c9c]=_0x518e8a;const _0x1e97b5=_0x51ea7e['get'](_0x3a8c9c);if(_0x1e97b5){const _0x16ba3a=_0x12ccf0['get'](_0x1e97b5['userId']),_0x39f3e7=new G({'author':_0x16ba3a,'type':_0x1e97b5['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x3a8c9c});_0x10b956['unshift'](_0x39f3e7),_0x26f965['attributes'][_0x3a8c9c]['revisionHistoryAttachChange']=_0x39f3e7['id'];}_0x26f965['changes']=_0x26f965['changes']['concat'](_0x10b956);}return _0x26f965;}['_markMarkers'](_0x2b11ee,_0x1d6b79){for(let _0x5067fa=0x0;_0x5067fa<_0x2b11ee['length'];_0x5067fa++)for(const [_0x482c4b,_0x44eb6d]of _0x1d6b79)!_0x44eb6d['isCollapsed']&&_0x44eb6d['start']['isEqual'](_0x2b11ee[_0x5067fa]['previousPosition'])&&_0x2b11ee[_0x5067fa]['markersStart']['push'](_0x482c4b),_0x44eb6d['end']['isEqual'](_0x2b11ee[_0x5067fa]['nextPosition'])&&_0x2b11ee[_0x5067fa]['markersEnd']['push'](_0x482c4b);}['_joinTapes'](_0x4784e7,_0x541c2c){let _0x4b418d=[],_0x16e3c4=0x0,_0x1afb5a=0x0;for(;_0x16e3c4<_0x4784e7['length']||_0x1afb5a<_0x541c2c['length'];){const _0x33625b=_0x4784e7[_0x16e3c4]||{},_0x5f2c2b=_0x541c2c[_0x1afb5a]||{};if(_0x33625b['id']==_0x5f2c2b['id'])_0x16e3c4++,_0x1afb5a++,_0x4b418d['push'](_0x33625b);else{if(_0x5f2c2b['isRemoved']&&_0x33625b['isAdded']){const {commonTape:_0x569a46,iEnd:_0x45d8c8,jEnd:_0x4d69f9}=this['_threeWayMerge'](_0x4784e7,_0x16e3c4,_0x541c2c,_0x1afb5a);_0x4b418d=_0x4b418d['concat'](_0x569a46),_0x16e3c4=_0x45d8c8,_0x1afb5a=_0x4d69f9;}else _0x5f2c2b['isRemoved']?(_0x1afb5a++,_0x4b418d['push'](_0x5f2c2b)):(_0x16e3c4++,_0x4b418d['push'](_0x33625b));}}return _0x4b418d;}['_markSuggestions'](_0x44a5ef,_0x5c8df2){const _0x4a152d=[];for(let _0x14b7f8=0x0;_0x14b7f8<_0x44a5ef['length'];_0x14b7f8++){for(let _0x5b8b11=0x0;_0x5b8b11<_0x44a5ef[_0x14b7f8]['markersStart']['length'];_0x5b8b11++){const _0x2a3362=_0x44a5ef[_0x14b7f8]['markersStart'][_0x5b8b11];if(!_0x5c8df2['has'](_0x2a3362))continue;const {group:_0x1765b1,type:_0x441951,authorId:_0x33cb01}=_0x539a84(_0x2a3362);'revision-suggestion'!=_0x1765b1||'insertion'!=_0x441951&&'deletion'!=_0x441951||(_0x4a152d['unshift']({'type':_0x441951,'name':_0x2a3362,'userId':_0x33cb01}),_0x44a5ef[_0x14b7f8]['markersStart']['splice'](_0x5b8b11,0x1),_0x5b8b11--);}_0x408189(_0x44a5ef[_0x14b7f8]);for(let _0x2167ee=0x0;_0x2167ee<_0x44a5ef[_0x14b7f8]['markersEnd']['length'];_0x2167ee++){const _0x3aa5bf=_0x44a5ef[_0x14b7f8]['markersEnd'][_0x2167ee];if(!_0x5c8df2['has'](_0x3aa5bf))continue;const {group:_0x2b5b6c,type:_0x2db02e}=_0x539a84(_0x3aa5bf);if('revision-suggestion'!=_0x2b5b6c||'insertion'!=_0x2db02e&&'deletion'!=_0x2db02e)continue;_0x44a5ef[_0x14b7f8]['markersEnd']['splice'](_0x2167ee,0x1),_0x2167ee--;const _0x33c942=_0x4a152d['findIndex'](_0x314967=>_0x314967['name']==_0x3aa5bf);_0x33c942>-0x1&&_0x4a152d['splice'](_0x33c942,0x1);}}function _0x539a84(_0x5a1b33){const _0xc3002=_0x5a1b33['split'](':');return{'group':_0xc3002[0x0],'type':_0xc3002[0x1],'subType':_0xc3002['length']>=0x5?_0xc3002[0x2]:null,'id':_0xc3002['length']<0x5?_0xc3002[0x2]:_0xc3002[0x3],'authorId':_0xc3002['length']<0x5?_0xc3002[0x3]:_0xc3002[0x4],'markerCount':0x6==_0xc3002['length']?_0xc3002[0x5]:null};}function _0x408189(_0x387cdc){for(let _0x42001c=0x0;_0x42001c<_0x4a152d['length'];_0x42001c++){if(_0x387cdc['isAdded']&&'insertion'==_0x4a152d[_0x42001c]['type']&&_0x387cdc['isAdded']['userId']==_0x4a152d[_0x42001c]['userId'])return _0x387cdc['isAddSuggestion']=_0x4a152d[_0x42001c],void delete _0x387cdc['isAdded'];if(!_0x387cdc['isAdded']&&!_0x387cdc['isRemoved']&&'deletion'==_0x4a152d[_0x42001c]['type'])return void(_0x387cdc['isRemoveSuggestion']=_0x4a152d[_0x42001c]);}}}['_setDistance'](_0x90504a,_0x272473){let _0x19b057=0x0,_0x5030d8=!0x1;const _0x29817a=new Map();for(const _0x868812 of _0x90504a)_0x868812[_0x272473]?_0x5030d8&&(_0x19b057++,_0x5030d8=!0x1):(_0x19b057++,_0x5030d8=!0x0),_0x29817a['set'](_0x868812['id'],_0x19b057);for(let _0x176ea0=0x0;_0x176ea0<_0x90504a['length'];_0x176ea0++){if('isRemoved'==_0x272473&&_0x90504a[_0x176ea0]['isAdded']||'isAdded'==_0x272473&&_0x90504a[_0x176ea0]['isRemoved'])continue;if('text'==_0x90504a[_0x176ea0]['type']){_0x90504a[_0x176ea0]['distance']=0x0;continue;}const _0x143744=_0x29817a['get'](_0x90504a[_0x176ea0]['pairId']),_0x3598ea=_0x29817a['get'](_0x90504a[_0x176ea0]['id']);_0x90504a[_0x176ea0]['distance']=_0x143744-_0x3598ea;}}['_getRevisionsRange'](_0x342fbc,_0x5bd9e4,_0x53f335=!0x1){const _0x380da2=[];let _0x252431=this['repository']['getIndex'](_0x342fbc),_0x6930ff=this['repository']['getIndex'](_0x5bd9e4);for(-0x1==_0x6930ff&&(_0x6930ff=this['repository']['_revisions']['length'],_0x53f335=!0x1);_0x252431<_0x6930ff;)_0x380da2['push'](this['repository']['getRevision'](_0x252431)),_0x252431++;return _0x53f335&&_0x380da2['push'](this['repository']['getRevision'](_0x252431)),_0x380da2;}['_threeWayMerge'](_0x7ce1bb,_0x569735,_0x4200db,_0x215115){const _0x1f7457=this['editor']['model']['schema'];let _0x1046ef=_0x569735;for(;_0x7ce1bb[_0x1046ef]&&_0x7ce1bb[_0x1046ef]['isAdded'];)_0x1046ef++;let _0x21447a=_0x215115;for(;_0x4200db[_0x21447a]&&_0x4200db[_0x21447a]['isRemoved'];)_0x21447a++;_0x4dc9a0(_0x7ce1bb,_0x569735,_0x1046ef),_0x4dc9a0(_0x4200db,_0x215115,_0x21447a);const _0x20aa7b=_0x4200db['slice'](_0x215115,_0x21447a)['concat'](_0x7ce1bb['slice'](_0x569735,_0x1046ef));return _0x20aa7b['sort']((_0x2685bb,_0xd76e44)=>_0x2685bb['side']!=_0xd76e44['side']?_0x2685bb['side']-_0xd76e44['side']:_0x2685bb['level']!=_0xd76e44['level']?_0x2685bb['level']-_0xd76e44['level']:_0x2685bb['distance']!=_0xd76e44['distance']?_0xd76e44['distance']-_0x2685bb['distance']:!!_0x2685bb['isAdded']!=!!_0xd76e44['isAdded']?-0x1==_0x2685bb['side']||0x0==_0x2685bb['side']?_0x2685bb['isAdded']?-0x1:0x1:_0x2685bb['isAdded']?0x1:-0x1:_0x2685bb['index']-_0xd76e44['index']),{'commonTape':_0x20aa7b,'iEnd':_0x1046ef,'jEnd':_0x21447a};function _0x4dc9a0(_0x8a6176,_0x32af50,_0x1610a2){let _0x2cb465=-0x1,_0xf69fd5=Number['POSITIVE_INFINITY'],_0xd625a9=!0x0;for(let _0x4457fe=_0x32af50;_0x4457fe<_0x1610a2;_0x4457fe++)if(_0x1f7457['isInline'](_0x8a6176[_0x4457fe]['item'])||(_0xd625a9=!0x1),_0x8a6176[_0x4457fe]['item']['startIndex']<_0x32af50&&(_0x2cb465=_0x4457fe),_0x8a6176[_0x4457fe]['item']['endIndex']>=_0x1610a2){_0xf69fd5=_0x4457fe;break;}_0xd625a9&&(_0x2cb465=_0x1610a2-0x1);for(let _0x286359=_0x32af50;_0x286359<_0x1610a2;_0x286359++)_0x8a6176[_0x286359]['side']=_0x286359<=_0x2cb465?-0x1:_0x286359<_0xf69fd5?0x0:0x1,_0x8a6176[_0x286359]['index']=_0x286359;let _0x293147=0x0;for(let _0x460d27=_0x32af50;_0x460d27<=_0x2cb465;_0x460d27++)0x0==_0x8a6176[_0x460d27]['distance']?_0x8a6176[_0x460d27]['level']=_0x293147:(_0x293147++,_0x8a6176[_0x460d27]['level']=_0x293147,_0x293147++);for(let _0x584a3a=_0x32af50;_0x584a3a<_0x1610a2;_0x584a3a++)0x0==_0x8a6176[_0x584a3a]['side']&&(_0x8a6176[_0x584a3a]['level']=_0x293147);_0x293147=0x0;for(let _0x45027b=_0x1610a2-0x1;_0x45027b>=_0xf69fd5;_0x45027b--)0x0==_0x8a6176[_0x45027b]['distance']?_0x8a6176[_0x45027b]['level']=_0x293147:(_0x293147--,_0x8a6176[_0x45027b]['level']=_0x293147,_0x293147--);}}['_fixObsoleteTags'](_0x225a81){const _0x5120c8=new Map(),_0x2226c4=this['editor']['model']['schema'];for(let _0x22b1ca=0x1;_0x22b1ca<_0x225a81['length'];_0x22b1ca++){let _0x23c4a3,_0x2c914b,_0x9b966a;const _0x24c64d=_0x225a81[_0x22b1ca],_0x792fd1=_0x225a81[_0x22b1ca-0x1];if('text'==_0x24c64d['type'])continue;if(_0x24c64d['type']!=_0x792fd1['type'])continue;if(!_0x2226c4['isBlock'](_0x792fd1['item'])||_0x2226c4['isLimit'](_0x792fd1['item']))continue;if(!_0x2226c4['isBlock'](_0x24c64d['item'])||_0x2226c4['isLimit'](_0x24c64d['item']))continue;if((_0x225a81[_0x22b1ca]['isAdded']||_0x225a81[_0x22b1ca]['isAddSuggestion'])&&_0x225a81[_0x22b1ca-0x1]['isRemoved'])_0x23c4a3=_0x225a81[_0x22b1ca],_0x2c914b=_0x225a81[_0x22b1ca-0x1],_0x9b966a=_0x22b1ca-0x1;else{if(!_0x225a81[_0x22b1ca]['isRemoved']||!_0x225a81[_0x22b1ca-0x1]['isAdded']&&!_0x225a81[_0x22b1ca-0x1]['isAddSuggestion'])continue;_0x23c4a3=_0x225a81[_0x22b1ca-0x1],_0x2c914b=_0x225a81[_0x22b1ca],_0x9b966a=_0x22b1ca;}const _0x2d2bfe=_0x23c4a3['level']==_0x2c914b['level'],_0x405ccd=Math['abs'](_0x23c4a3['level'])<Math['abs'](_0x2c914b['level'])&&0x0==_0x2c914b['distance'];(_0x2d2bfe||_0x405ccd)&&(_0x5120c8['set'](_0x2c914b['id'],_0x23c4a3['id']),_0x225a81['splice'](_0x9b966a,0x1),_0x22b1ca--,_0x23c4a3['isAdded']=!0x1);}for(let _0x59f866=0x0;_0x59f866<_0x225a81['length'];_0x59f866++)_0x5120c8['has'](_0x225a81[_0x59f866]['pairId'])&&(_0x225a81[_0x59f866]['pairId']=_0x5120c8['get'](_0x225a81[_0x59f866]['pairId']));}['_removeMissingPairs'](_0x142aa9){const _0x4abb5f=new Set(_0x142aa9['map'](_0x1798c4=>_0x1798c4['id']));for(let _0x492282=0x0;_0x492282<_0x142aa9['length'];_0x492282++)_0x4abb5f['has'](_0x142aa9[_0x492282]['pairId'])||0x0==_0x142aa9[_0x492282]['distance']||(_0x142aa9[_0x492282]['isIncorrect']=!0x0);return _0x142aa9['filter'](_0x141f79=>!_0x141f79['isIncorrect']);}['_markMismatchedRemovedTags'](_0x27400d){const _0x5d7b7a=new Set();for(let _0x1ee3b2=0x0;_0x1ee3b2<_0x27400d['length'];_0x1ee3b2++){if(_0x5d7b7a['has'](_0x27400d[_0x1ee3b2]['id'])&&_0x27400d[_0x1ee3b2]['isRemoved']&&(_0x27400d[_0x1ee3b2]['isIncorrect']=!0x0),_0x27400d[_0x1ee3b2]['isIncorrect'])continue;if(0x0==_0x27400d[_0x1ee3b2]['distance'])continue;if('elementStart'!=_0x27400d[_0x1ee3b2]['type'])continue;if(null==_0x27400d[_0x1ee3b2]['pairId'])continue;let _0x50e6da=_0x1ee3b2+0x1,_0x3400b8=0x0;for(;_0x27400d[_0x50e6da]['id']!=_0x27400d[_0x1ee3b2]['pairId'];)'elementStart'==_0x27400d[_0x50e6da]['type']?_0x3400b8++:'elementEnd'==_0x27400d[_0x50e6da]['type']&&_0x3400b8--,_0x50e6da++;if(0x0!=_0x3400b8){if(_0x27400d[_0x1ee3b2]['isRemoved'])_0x27400d[_0x1ee3b2]['isIncorrect']=!0x0;else{for(;_0x50e6da!=_0x1ee3b2;)_0x27400d[_0x50e6da]['isRemoved']&&0x0!=_0x27400d[_0x50e6da]['distance']&&(_0x27400d[_0x50e6da]['isIncorrect']=!0x0,_0x5d7b7a['add'](_0x27400d[_0x50e6da]['pairId'])),_0x50e6da--;}}}return _0x27400d['filter'](_0x2bfde5=>!_0x2bfde5['isIncorrect']);}['_removeUnsupportedChanges'](_0x588093){const _0x4236f4=this['editor']['model']['schema'];for(let _0x4415f2=0x0;_0x4415f2<_0x588093['length'];_0x4415f2++){if(!(_0x588093[_0x4415f2]['isAdded']||_0x588093[_0x4415f2]['isAddSuggestion']||_0x588093[_0x4415f2]['isRemoved']||_0x588093[_0x4415f2]['isRemoveSuggestion']))continue;if(0x0==_0x588093[_0x4415f2]['distance'])continue;const _0x3989b8=_0x588093[_0x4415f2]['item'];_0x4236f4['isBlock'](_0x3989b8)||_0x4236f4['isLimit'](_0x3989b8)||(_0x588093[_0x4415f2]['isAdded']&&delete _0x588093[_0x4415f2]['isAdded'],_0x588093[_0x4415f2]['isAddSuggestion']&&delete _0x588093[_0x4415f2]['isAddSuggestion'],_0x588093[_0x4415f2]['isRemoveSuggestion']&&delete _0x588093[_0x4415f2]['isRemoveSuggestion'],_0x588093[_0x4415f2]['isRemoved']&&(_0x588093[_0x4415f2]['isIncorrect']=!0x0));}return _0x588093['filter'](_0x5adfe7=>!_0x5adfe7['isIncorrect']);}['_makeModelFromTape'](_0x1fb90a,_0x250ed1,_0x14db79){const _0x2298c0=new _0x8e7ca7(),_0xb71346=[],_0x4c8ba4=new Map(),_0x4da26b=this['editor']['model'],_0x4fa173=_0x4da26b['schema'],_0xd37c05=[_0x2298c0],_0x3f0e79={},_0x1fa179={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x1d7f0c=null;const _0x51c3d6=[0x0];for(let _0x215526=0x0;_0x215526<_0x1fb90a['length'];_0x215526++)if('elementStart'===_0x1fb90a[_0x215526]['type']){_0x1fb90a[_0x215526]['previousPosition']=_0x4da26b['createPositionFromPath'](_0x2298c0,_0x51c3d6);const _0x4e41a2=new _0x560940(_0x1fb90a[_0x215526]['item']['name'],_0x1fb90a[_0x215526]['item']['getAttributes']());_0xd37c05[0x0]['_appendChild'](_0x4e41a2),_0x51c3d6['push'](0x0),_0xd37c05['unshift'](_0x4e41a2),_0x1fb90a[_0x215526]['nextPosition']=_0x4da26b['createPositionFromPath'](_0x2298c0,_0x51c3d6);}else'elementEnd'===_0x1fb90a[_0x215526]['type']?(_0xd37c05['shift'](),_0x1fb90a[_0x215526]['previousPosition']=_0x4da26b['createPositionFromPath'](_0x2298c0,_0x51c3d6),_0x51c3d6['pop'](),_0x51c3d6[_0x51c3d6['length']-0x1]++,_0x1fb90a[_0x215526]['nextPosition']=_0x4da26b['createPositionFromPath'](_0x2298c0,_0x51c3d6)):(_0x1fb90a[_0x215526]['previousPosition']=_0x4da26b['createPositionFromPath'](_0x2298c0,_0x51c3d6),_0x1d7f0c?_0x1d7f0c['_data']+=_0x1fb90a[_0x215526]['item']['data']:_0x1d7f0c=new _0x34a305(_0x1fb90a[_0x215526]['item']['data'],_0x1fb90a[_0x215526]['item']['getAttributes']()),_0x1fb90a[_0x215526+0x1]&&'text'===_0x1fb90a[_0x215526+0x1]['type']&&_0x2660e7(_0x1d7f0c,_0x1fb90a[_0x215526+0x1]['item'])||(_0xd37c05[0x0]['_appendChild'](_0x1d7f0c),_0x1d7f0c=null),_0x51c3d6[_0x51c3d6['length']-0x1]+=_0x1fb90a[_0x215526]['item']['offsetSize'],_0x1fb90a[_0x215526]['nextPosition']=_0x4da26b['createPositionFromPath'](_0x2298c0,_0x51c3d6));for(let _0xc7eadf=0x0;_0xc7eadf<_0x1fb90a['length'];_0xc7eadf++){const _0xb8bd72=_0x1fb90a[_0xc7eadf]['previousPosition'],_0x56e196=_0x1fb90a[_0xc7eadf]['nextPosition'];for(const _0x129e56 of _0x1fb90a[_0xc7eadf]['markersStart'])_0x4c8ba4['set'](_0x129e56,{'start':_0xb8bd72,'end':null});_0x1fadbc('isRemoveSuggestion',_0xc7eadf,_0xb8bd72,_0x56e196),_0x1fadbc('isAddSuggestion',_0xc7eadf,_0xb8bd72,_0x56e196),_0x1fadbc('isRemoved',_0xc7eadf,_0xb8bd72,_0x56e196),_0x1fadbc('isAdded',_0xc7eadf,_0xb8bd72,_0x56e196);for(const _0x278c64 of _0x1fb90a[_0xc7eadf]['markersEnd']){const _0x28425a=_0x4c8ba4['get'](_0x278c64);_0x28425a?_0x28425a['end']=_0x56e196:_0x4c8ba4['set'](_0x278c64,{'start':_0x56e196,'end':_0x56e196});}}for(const [_0x241488,_0x405115]of _0x4c8ba4){const _0x33ab63=this['editor']['model']['createRange'](_0x405115['start'],_0x405115['end']);_0x2298c0['markers']['set'](_0x241488,_0x33ab63);}return _0xb71346['sort']((_0xecf2d5,_0x540821)=>{const _0x3b97b2=_0x2298c0['markers']['get']('revision:'+_0xecf2d5['id']),_0x8291cb=_0x2298c0['markers']['get']('revision:'+_0x540821['id']);return _0x3b97b2['start']['isBefore'](_0x8291cb['start'])?-0x1:_0x3b97b2['start']['isAfter'](_0x8291cb['start'])?0x1:_0x3b97b2['end']['isBefore'](_0x8291cb['end'])?-0x1:_0x3b97b2['end']['isAfter'](_0x8291cb['end'])?0x1:'add'===_0xecf2d5['type']?-0x1:0x1;}),{'root':_0x2298c0,'changes':_0xb71346};function _0x1fadbc(_0xb3f7d8,_0x3deced,_0x170963,_0x26e3cb){const _0x5312df=!!_0x1fb90a[_0x3deced][_0xb3f7d8],_0xa14728=_0x5312df?_0x1fb90a[_0x3deced][_0xb3f7d8]['userId']:null,_0x3a2933=_0x3deced===_0x1fb90a['length']-0x1,_0x5b721d=_0x1fa179[_0xb3f7d8][0x0],_0x1e0272=_0x4fa173['isObject'](_0x1fb90a[_0x3deced]['item']);!_0x3f0e79[_0xb3f7d8]&&_0x5312df?_0x3f0e79[_0xb3f7d8]={'start':_0x170963,'tapeItem':_0x1fb90a[_0x3deced],'userId':_0xa14728,'type':_0xb3f7d8}:_0x3f0e79[_0xb3f7d8]&&!_0x5312df?(_0x3f0e79[_0xb3f7d8]['end']=_0x170963,_0x382da1(_0x3f0e79[_0xb3f7d8]),_0x3f0e79[_0xb3f7d8]=null):_0x3f0e79[_0xb3f7d8]&&_0x5312df&&_0x3f0e79[_0xb3f7d8]['userId']!==_0xa14728&&(_0x3f0e79[_0xb3f7d8]['end']=_0x170963,_0x5b721d&&_0x5b721d['userId']===_0x3f0e79[_0xb3f7d8]['userId']||_0x382da1(_0x3f0e79[_0xb3f7d8]),_0x3f0e79[_0xb3f7d8]={'start':_0x170963,'tapeItem':_0x1fb90a[_0x3deced],'userId':_0xa14728,'type':_0xb3f7d8}),_0x3f0e79[_0xb3f7d8]&&_0x1e0272&&('elementStart'!==_0x1fb90a[_0x3deced]['type']||_0x5b721d&&_0x5b721d['userId']===_0xa14728||_0x1fa179[_0xb3f7d8]['unshift']({'userId':_0xa14728,'object':_0x1fb90a[_0x3deced]['item'],'change':_0x3f0e79[_0xb3f7d8]}),'elementEnd'===_0x1fb90a[_0x3deced]['type']&&_0x5b721d&&_0x5b721d['object']===_0x1fb90a[_0x3deced]['item']&&(_0x1fa179[_0xb3f7d8]['shift'](),_0x3f0e79[_0xb3f7d8]=_0x5b721d['change'])),_0x3f0e79[_0xb3f7d8]&&_0x3a2933&&(_0x3f0e79[_0xb3f7d8]['end']=_0x26e3cb,_0x382da1(_0x3f0e79[_0xb3f7d8]),_0x3f0e79[_0xb3f7d8]=null);}function _0x382da1({start:_0x178d7d,end:_0x4f44c2,tapeItem:_0x3d5ff0,userId:_0x343ac5,type:_0x4faa26}){const _0x36fb98=_0x3d5ff0['item'],_0xcf2ad2=_0x4da26b['schema']['isBlock'](_0x36fb98)&&!_0x4da26b['schema']['isLimit'](_0x36fb98),_0x2836b8=_0x178d7d['nodeAfter']==_0x4f44c2['parent']&&_0x4f44c2['isAtStart'];if(_0xcf2ad2&&_0x2836b8)return;const _0x5b0e66=_0x4da26b['createRange'](_0x178d7d,_0x4f44c2),_0x3eb47a=_0x250ed1['get'](_0x343ac5),_0x4e650c=new G({'author':_0x3eb47a,'type':'isAdded'==_0x4faa26||'isAddSuggestion'==_0x4faa26?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x4faa26||'isRemoveSuggestion'==_0x4faa26},'createdAt':new Date(),'rootName':_0x14db79});_0xb71346['push'](_0x4e650c),_0x2298c0['markers']['set']('revision:'+_0x4e650c['id'],_0x5b0e66);}function _0x2660e7(_0x5ab67c,_0x5885eb){const _0x446d64=_0x5ab67c['getAttributes'](),_0x356015=_0x5885eb['getAttributes']();for(const _0x3b7b50 of _0x446d64){if(_0x3b7b50[0x1]!==_0x5885eb['getAttribute'](_0x3b7b50[0x0]))return!0x1;_0x356015['next']();}return _0x356015['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x84883a=>{const _0x137bfe=_0x84883a['markerName']['split'](':')[0x1],_0x294776=this['_getChangeFromId'](_0x137bfe);if(!_0x294776)return null;const _0x3b7b86='add'==_0x294776['type']?'insertion':'deletion',_0x45f2b8=['ck-suggestion-marker','ck-suggestion-marker-'+_0x3b7b86];return _0x294776['data']['isSuggestion']&&_0x45f2b8['push']('ck-suggestion-marker-'+_0x3b7b86+'-new'),this['activeChange']==_0x294776&&_0x45f2b8['push']('ck-suggestion-marker--active'),{'classes':_0x45f2b8,'attributes':{'data-change-id':_0x137bfe}};}}),this['editor']['conversion']['for']('upcast')['add'](_0xf0d3ef=>{_0xf0d3ef['on']('element:pre',(_0x4a0dae,_0x567c0f,_0x510c8d)=>{const _0x7e9121=_0x567c0f['viewItem']['getChild'](0x0);if(!_0x7e9121||!_0x7e9121['is']('element','code'))return;if(!_0x510c8d['consumable']['consume'](_0x7e9121,{'attributes':['vid_start','vid_end']}))return;const _0xb2da4c=_0x567c0f['modelRange']['start']['nodeAfter'];_0x510c8d['writer']['setAttribute']('vid_start',_0x7e9121['getAttribute']('vid_start'),_0xb2da4c),_0x510c8d['writer']['setAttribute']('vid_end',_0x7e9121['getAttribute']('vid_end'),_0xb2da4c);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x48cf03=>{_0x48cf03['on']('element',(_0x1af025,_0xe157f4,_0x59dd89)=>{if(!_0x59dd89['consumable']['consume'](_0xe157f4['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0xe157f4['modelRange']['isCollapsed'])return;const _0x4ec13b=_0xe157f4['modelRange']['start']['nodeAfter'];_0x4ec13b['hasAttribute']('vid_start')||_0x4ec13b['hasAttribute']('vid')||(_0x59dd89['writer']['setAttribute']('vid_start',_0xe157f4['viewItem']['getAttribute']('vid_start'),_0x4ec13b),_0x59dd89['writer']['setAttribute']('vid_end',_0xe157f4['viewItem']['getAttribute']('vid_end'),_0x4ec13b));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x83c6bd=>_0x83c6bd['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x3245eb,[,_0x31765a])=>{['vid_start','vid_end','vid']['includes'](_0x31765a)&&(_0x3245eb['return']=!0x0,_0x3245eb['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x2ec84b=>{_0x2ec84b['on']('attribute:vid',(_0x20df91,_0x47be1a,_0x308369)=>{if('\x20'!=_0x47be1a['item']['data']||_0x47be1a['item']['parent']['maxOffset']>0x1)return;if(!_0x308369['consumable']['consume'](_0x47be1a['item'],_0x20df91['name']))return;const _0x2440ed=_0x308369['writer'],_0x4cfd89=_0x308369['mapper']['toViewRange'](_0x47be1a['range']);_0x2440ed['wrap'](_0x4cfd89,_0x2440ed['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x25446b){const _0x258dd9=_0x25446b['plugins']['get']('RevisionViewer');return(_0x1effba,_0x28b6e2,_0x174cd3)=>{const _0x4253d7=_0x28b6e2['markerName']['split'](':')[0x1],_0x3e32=_0x258dd9['_getChangeFromId'](_0x4253d7);if(!_0x3e32)return null;const _0x5578ec='add'==_0x3e32['type']?'split':'merge';if(!_0x174cd3['consumable']['test'](_0x28b6e2['markerRange'],_0x1effba['name']))return;const _0x48c14e=_0x28b6e2['markerRange']['getWalker'](),_0x30588b=_0x28b6e2['markerRange']['start'],_0x166087=_0x25446b['model']['schema'];let _0x383438=null,_0x4a3635=null,_0x2e7041=!0x1,_0x156032=!0x1;for(const _0x51b341 of _0x48c14e){const _0x24f7e8=_0x51b341['item'];_0x2e7041=_0x2e7041||_0x166087['isContent'](_0x24f7e8);const _0x34198f=_0x174cd3['mapper']['toViewElement'](_0x24f7e8);if(_0x34198f&&_0x34198f['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x51b341['type']&&(_0x166087['isBlock'](_0x24f7e8)&&!_0x166087['isLimit'](_0x24f7e8)&&(_0x24f7e8['nextSibling']||_0x30588b['isAtEnd']?_0x383438&&_0x383438['parent']==_0x24f7e8||(_0x383438=_0x24f7e8,_0x14ecac(_0x51b341['previousPosition']),_0x156032=!0x0):_0x4a3635=_0x4a3635||_0x51b341['previousPosition']));}function _0x14ecac(_0x161e96){const _0x545650=_0x174cd3['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x5578ec}),_0x47c606=_0x174cd3['mapper']['toViewPosition'](_0x161e96);_0x3e32['data']['isSuggestion']&&_0x174cd3['writer']['addClass']('ck-suggestion-marker-'+_0x5578ec+'-new',_0x545650),_0x258dd9['activeChange']==_0x3e32&&_0x174cd3['writer']['addClass']('ck-suggestion-marker--active',_0x545650),_0x174cd3['writer']['insert'](_0x47c606,_0x545650),_0x174cd3['mapper']['bindElementToMarker'](_0x545650,_0x28b6e2['markerName']);}_0x2e7041||_0x156032||!_0x4a3635||_0x14ecac(_0x4a3635);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x4d284a,_0x154ad4,_0xe91360)=>{const _0x3333c2=_0xe91360['mapper']['markerNameToElements'](_0x154ad4['markerName']);if(_0x3333c2){for(const _0x2db06e of _0x3333c2)(_0x2db06e['hasClass']('ck-suggestion-marker-split')||_0x2db06e['hasClass']('ck-suggestion-marker-merge'))&&(_0xe91360['mapper']['unbindElementFromMarkerName'](_0x2db06e,_0x154ad4['markerName']),_0xe91360['writer']['remove'](_0x2db06e));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x2d078c,_0x1e3713,_0x52429b)=>{const _0x4269a8=_0x1e3713['markerName']['split'](':')[0x1],_0x4f4e48=this['_getChangeFromId'](_0x4269a8);if(!_0x4f4e48)return null;const _0x295c35='add'==_0x4f4e48['type']?'split':'merge';if(_0x52429b['consumable']['test'](_0x1e3713['markerRange'],_0x2d078c['name']))for(const _0x53e742 of _0x1e3713['markerRange']['getItems']()){if(!_0x53e742['is']('element','softBreak'))continue;const _0x40f86f=_0x52429b['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x295c35}),_0x2e76ea=_0x52429b['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x53e742));_0x4f4e48['data']['isSuggestion']&&_0x52429b['writer']['addClass']('ck-suggestion-marker-'+_0x295c35+'-new',_0x40f86f),this['activeChange']==_0x4f4e48&&_0x52429b['writer']['addClass']('ck-suggestion-marker--active',_0x40f86f),_0x52429b['writer']['insert'](_0x2e76ea,_0x40f86f),_0x52429b['mapper']['bindElementToMarker'](_0x40f86f,_0x1e3713['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x1a3600=>{for(const _0x31654e of this['editor']['model']['document']['getRootNames']()){const _0x427b05=this['editor']['model']['document']['getRoot'](_0x31654e),_0x51d6df=this['editor']['editing']['view']['document']['getRoot'](_0x31654e);if(_0x51d6df){const _0x3fb75a=_0x427b05['getAttribute']('revisionHistoryAttachChange');if(_0x1a3600['removeAttribute']('data-change-id',_0x51d6df),_0x1a3600['removeClass']('ck-revision-history-root-add',_0x51d6df),_0x1a3600['removeClass']('ck-revision-history-root-remove',_0x51d6df),_0x1a3600['removeClass']('ck-revision-history-root--active',_0x51d6df),_0x3fb75a){const _0x294804=this['_getChangeFromId'](_0x3fb75a);if(!_0x294804)return null;_0x1a3600['setAttribute']('data-change-id',_0x3fb75a,_0x51d6df),_0x1a3600['addClass']('ck-revision-history-root-'+_0x294804['type'],_0x51d6df),this['activeChange']==_0x294804&&_0x1a3600['addClass']('ck-revision-history-root--active',_0x51d6df);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x12832e=>'revision-comment:'+_0x12832e,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x3531ae=>'revision-suggestion:'+_0x3531ae,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x395ba5=>({'name':'suggestion:'+_0x395ba5,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x474190=>{const _0x2d60f7=_0x474190['markerName']['split'](':')[0x1];return'insertion'!=_0x2d60f7&&'deletion'!=_0x2d60f7?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x2d60f7]};}}),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',(_0x1292e7,_0x4c0762,_0x2ee6c3)=>{const _0xc98ce8=_0x2ee6c3['mapper']['markerNameToElements'](_0x4c0762['markerName']);if(_0xc98ce8){for(const _0x106338 of _0xc98ce8)_0x106338['is']('uiElement')&&(_0x2ee6c3['mapper']['unbindElementFromMarkerName'](_0x106338,_0x4c0762['markerName']),_0x2ee6c3['writer']['remove'](_0x106338));}},{'priority':'high'});}['_getChangeFromId'](_0x5343bc){return this['_changeIdToChange']['get'](_0x5343bc);}['_getViewForChange'](_0x18ca30){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new z(this['editor']['locale'],_0x18ca30),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x2e0c6e,_0x323d32,_0x23c5f6,_0x59c5c6)=>{_0x59c5c6&&this['_balloon']['remove'](_0x59c5c6),_0x23c5f6&&(this['_balloon']['add']({'view':_0x23c5f6,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x38f710=this['editor']['editing'],_0x570027=this['_getChangeFromId'](_0x23c5f6['changeId']);let _0x46c3f1;if(_0x570027['data']['isOnRoot']){const _0xc79fda=_0x38f710['view']['getDomRoot'](_0x570027['rootName']);_0x46c3f1=Array['from'](_0xc79fda['getClientRects']());}else{const _0x4557b6=this['editor']['model']['markers']['get']('revision:'+_0x23c5f6['changeId']);_0x46c3f1=Array['from'](_0x38f710['mapper']['markerNameToElements'](_0x4557b6['name']))['map'](_0x1cf29f=>_0x38f710['view']['domConverter']['mapViewToDom'](_0x1cf29f))['map'](_0x45e9b7=>Array['from'](_0x45e9b7['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x46c3f1[0x0];return _0x46c3f1['find'](_0x5a16c3=>_0x5a16c3['top']-0x3<=this['_activeViewTarget']['y']&&_0x5a16c3['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x5a16c3['left']-0x3<=this['_activeViewTarget']['x']&&_0x5a16c3['right']+0x3>=this['_activeViewTarget']['x'])||_0x46c3f1[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x2f56b6,_0x235222,_0x5028fb,_0x12e997)=>{this['activeView']=_0x5028fb?this['_getViewForChange'](_0x5028fb):null,this['editor']['model']['change'](()=>{const _0x7d4a28=this['editor']['editing'];_0x12e997&&(_0x12e997['data']['isOnRoot']?_0x7d4a28['view']['change'](_0x2ef119=>{_0x2ef119['removeClass']('ck-revision-history-root--active',_0x7d4a28['view']['document']['getRoot'](_0x12e997['rootName']));}):_0x7d4a28['reconvertMarker']('revision:'+_0x12e997['id'])),_0x5028fb&&(_0x5028fb['data']['isOnRoot']?_0x7d4a28['view']['change'](_0x5b5581=>{_0x5b5581['addClass']('ck-revision-history-root--active',_0x7d4a28['view']['document']['getRoot'](_0x5028fb['rootName']));}):_0x7d4a28['reconvertMarker']('revision:'+_0x5028fb['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x2fa98b,_0x5da51f)=>{if(this['activeChange'])return;const _0x18228e=this['_findChangeIdFromDomTarget'](_0x5da51f['target']),_0x1adee5=this['_changeIdToChange']['get'](_0x18228e);_0x1adee5?(this['_activeViewTarget']={'x':_0x5da51f['domEvent']['x'],'y':_0x5da51f['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x1adee5)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x386712,_0x4c96c7)=>{const _0x31718c=this['_findChangeIdFromDomTarget'](_0x4c96c7['target']),_0x18f256=this['_changeIdToChange']['get'](_0x31718c);_0x18f256?(this['_activeViewTarget']={'x':_0x4c96c7['domEvent']['x'],'y':_0x4c96c7['domEvent']['y']},_0x18f256===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x18f256):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x1d53eb){do{const _0x5dafc1=_0x1d53eb['getAttribute']('data-change-id');if(_0x5dafc1)return _0x5dafc1;_0x1d53eb=_0x1d53eb['parent'];}while(_0x1d53eb);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x45ee54=>{for(const _0x2bbe68 of this['editor']['model']['markers'])_0x45ee54['removeMarker'](_0x2bbe68);});}}function Q(_0x26b4da,_0x13ab24){return(_0x7bb212,_0x54a5f8,_0x4acd5d)=>{if(!_0x4acd5d['consumable']['test'](_0x54a5f8['markerRange'],_0x7bb212['name']))return;const _0x1d79c2=_0x54a5f8['markerRange']['getWalker'](),_0x34a21a=_0x54a5f8['markerRange']['start'],_0x43f7ec=_0x26b4da['model']['schema'];let _0xaf40e3=null,_0x2e1807=null,_0x459f7d=!0x1,_0x4244cb=!0x1;for(const _0x262460 of _0x1d79c2){const _0x8b53cd=_0x262460['item'];_0x459f7d=_0x459f7d||_0x43f7ec['isContent'](_0x8b53cd);const _0x3c769b=_0x4acd5d['mapper']['toViewElement'](_0x8b53cd);if(_0x3c769b&&_0x3c769b['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x262460['type']&&(_0x43f7ec['isBlock'](_0x8b53cd)&&!_0x43f7ec['isLimit'](_0x8b53cd)&&(_0x8b53cd['nextSibling']||_0x34a21a['isAtEnd']?_0xaf40e3&&_0xaf40e3['parent']==_0x8b53cd||(_0xaf40e3=_0x8b53cd,_0x12f63d(_0x262460['previousPosition']),_0x4244cb=!0x0):_0x2e1807=_0x2e1807||_0x262460['previousPosition']));}function _0x12f63d(_0x10a6b1){const _0x2af31e=_0x4acd5d['mapper']['toViewPosition'](_0x10a6b1),_0x4ec918=_0x4acd5d['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x13ab24});_0x4acd5d['writer']['insert'](_0x2af31e,_0x4ec918),_0x4acd5d['mapper']['bindElementToMarker'](_0x4ec918,_0x54a5f8['markerName']);}_0x459f7d||_0x4244cb||!_0x2e1807||_0x12f63d(_0x2e1807);};}class nt extends _0x14ef0e{constructor(_0xfd98f){super(_0xfd98f);const _0x259acd=_0xfd98f['plugins']['get'](l);this['affectsData']=!0x1,this['listenTo'](_0x259acd,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x259acd,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0xb28957=this['editor'],_0x117175=_0xb28957['plugins']['get'](l),_0xa16ab1=_0x117175['isReady']?_0x117175['diff']['newRevisionId']:null;_0xb28957['config']['get']('revisionHistory')['restoreRevisionCallback'](_0xa16ab1);}['refresh'](){const {isReady:_0x3b1563,isEnabled:_0x126623,repository:_0x2fe7e0,diff:_0x3f6d94}=this['editor']['plugins']['get'](l),_0x35a24a=_0x3f6d94&&_0x2fe7e0['getLaterVisibleRevision'](_0x3f6d94['newRevisionId']);this['isEnabled']=_0x3b1563&&_0x126623&&Boolean(_0x35a24a);}}class ot extends _0x14ef0e{['_step'];constructor(_0x14992b,{direction:_0x45d108}){super(_0x14992b);const _0x231026=_0x14992b['plugins']['get'](l);this['affectsData']=!0x1,this['_step']='forward'===_0x45d108?0x1:-0x1,this['listenTo'](_0x231026,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x231026,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x231026,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x37553e=this['editor'],_0x5f184f=_0x37553e['plugins']['get'](l),{isNavigationMode:_0x124b12,currentChangeNumber:_0x5ee982}=_0x5f184f;let _0x119338;if(_0x5f184f['activeChange']=_0x124b12?_0x5f184f['diff']['changes']['get'](_0x5ee982+this['_step']):_0x5f184f['diff']['changes']['first'],_0x5f184f['activeChange']['data']['isOnRoot'])_0x119338=_0x37553e['editing']['view']['getDomRoot'](_0x5f184f['activeChange']['rootName']);else{const _0x5a3e0e=_0x37553e['model']['markers']['get']('revision:'+_0x5f184f['activeChange']['id']);_0x119338=_0x13d047(_0x37553e['editing'],_0x5a3e0e);}_0x1f6038({'target':_0x119338,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x4c956b,currentChangeNumber:_0x3bf480,numberOfChanges:_0x439870,isReady:_0x3b2bc3,isEnabled:_0x4b316d}=this['editor']['plugins']['get'](l);this['isEnabled']=!!(_0x4b316d&&_0x3b2bc3&&_0x439870)&&(!_0x4c956b||(0x1===this['_step']?_0x3bf480<_0x439870-0x1:_0x3bf480>0x0));}}class Ri extends _0x13ae3e{constructor(_0x2c35b2){super(_0x2c35b2);const _0x7d8f92=this['bindTemplate'],_0x41171e=new _0xbf084f(_0x2c35b2),_0x1917cd=new _0xbf084f(_0x2c35b2);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',(_0x416518,_0x2ec341)=>_0x416518&&_0x2ec341>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x22ca66,_0x1a0562,_0x1f4b37,_0x136f01)=>{if(!_0x22ca66)return R(_0x2c35b2,'Loading...');if(!_0x1f4b37)return R(_0x2c35b2,'No\x20changes');const _0x213f54=R(_0x2c35b2,'NUMBER_OF_CHANGES',_0x1f4b37);return _0x136f01?R(_0x2c35b2,'X_OF_Y_CHANGES',[_0x1a0562+0x1,_0x1f4b37]):_0x213f54;}),_0x41171e['set']({'label':R(_0x2c35b2,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x4605ea}),_0x1917cd['set']({'label':R(_0x2c35b2,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x129e8c}),_0x41171e['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x1917cd['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x41171e['on']('execute',()=>this['fire']('execute','backward')),_0x1917cd['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',_0x7d8f92['if']('_isStatusLabelVisible','ck-hidden',_0xe73f15=>!_0xe73f15)]},'children':[{'text':_0x7d8f92['to']('isNavigationMode',_0x37187b=>_0x37187b?R(_0x2c35b2,'EDIT_X_OF_Y_REVISIONS')+':\x20':R(_0x2c35b2,'Total')+':\x20')}]},{'text':_0x7d8f92['to']('_statusText')}]},new _0x311722(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x41171e,_0x1917cd]}]});}}const ge='ck-editor__editable__loading-overlay';class ji extends _0x5b0dba{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x5df7a6=this['editor']['editing']['view'];_0x5df7a6['change'](_0x88994=>{for(const _0x5b4189 of _0x5df7a6['document']['roots'])_0x88994['addClass'](ge,_0x5b4189);});}['hide'](){const _0x599612=this['editor']['editing']['view'];_0x599612['change'](_0x4c8372=>{for(const _0xf328e5 of _0x599612['document']['roots'])_0x4c8372['removeClass'](ge,_0xf328e5);});}}class u extends _0x5b0dba{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l,ji];}['init'](){const _0xd200d=this['editor'],_0x403b1c=_0xd200d['plugins']['get'](l),_0x3e50cc=_0xd200d['plugins']['get'](ji);_0xd200d['ui']['componentFactory']['add']('exitToEditing',_0x38f925=>{const _0x4b5843=new _0xbf084f(_0x38f925);return _0x4b5843['set']({'label':R(_0x38f925,'Back\x20to\x20editing'),'icon':_0x805c16,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x4b5843,'execute',()=>{_0xd200d['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x4b5843;}),_0xd200d['ui']['componentFactory']['add']('restoreRevision',_0x28ddc9=>{const _0x1ee672=new _0xbf084f(_0x28ddc9);return _0x1ee672['set']({'label':R(_0x28ddc9,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x1ee672['bind']('isEnabled')['to'](_0xd200d['commands']['get']('restoreRevision')),this['listenTo'](_0x1ee672,'execute',()=>_0xd200d['execute']('restoreRevision')),_0x1ee672;}),_0xd200d['ui']['componentFactory']['add']('changesNavigation',_0x12a7d6=>{const _0x2b7f33=new Ri(_0x12a7d6),_0x3af3f9=_0xd200d['commands']['get']('showPreviousChange'),_0x42b152=_0xd200d['commands']['get']('showNextChange');return _0x2b7f33['bind']('isBackwardNavigationEnabled')['to'](_0x3af3f9,'isEnabled'),_0x2b7f33['bind']('isForwardNavigationEnabled')['to'](_0x42b152,'isEnabled'),_0x2b7f33['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x403b1c),this['listenTo'](_0x2b7f33,'execute',(_0x1a154d,_0x428af5)=>{_0xd200d['execute']('forward'===_0x428af5?'showNextChange':'showPreviousChange');}),_0x2b7f33;}),_0x3e50cc['show'](),_0x403b1c['on']('change:isReady',(_0x2b2e36,_0x1803c2,_0x36f672)=>{_0x36f672?_0x3e50cc['hide']():_0x3e50cc['show']();});}}class li extends ti{['_resizeObserver']=null;constructor(_0x1deabf,_0x2712ba){super(_0x1deabf,_0x2712ba);const _0x1abd23=this['bindTemplate'];this['set']({'label':R(_0x1deabf,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=R(_0x1deabf,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x1abd23['to']('_tooltipString'),'data-cke-tooltip-position':'s','data-cke-tooltip-class':'ck-tooltip_multi-line'}});}['render'](){super['render'](),this['_resizeObserver']=new et(this['fieldView']['element'],()=>this['_updateTooltipText']()),this['listenTo'](this['fieldView'],'input',()=>this['_updateTooltipText']());}['destroy'](){super['destroy'](),this['_resizeObserver']&&this['_resizeObserver']['destroy']();}['_updateTooltipText'](){const _0x6a4a2a=this['fieldView']['element'];this['_tooltipString']=_0x6a4a2a['scrollWidth']>_0x6a4a2a['clientWidth']&&_0x6a4a2a['value']||'';}}class vi extends _0x13ae3e{constructor(_0x115f5f,_0x185c29,_0x79c1fe){super(_0x115f5f);const _0x5c9e97=new _0x24f111();_0x5c9e97['set']({'content':_0x434f3a,'viewBox':'0\x200\x2011\x2010'});const _0x35aed9=['ck','ck-revision-history-sidebar__revision-author'];_0x79c1fe&&_0x35aed9['push']('ck-revision-history-sidebar__revision-author_creator');const _0x509f48=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':R(_0x115f5f,_0x79c1fe?'Revision\x20creator':'Revision\x20author')},'children':[_0x5c9e97,_0x185c29['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x35aed9},'children':_0x509f48});}}function mi(_0x4a0ea8,_0x422e8b){const _0x4c0488=_0x4a0ea8['bindTemplate'],_0x484e0f=_0x4a0ea8['locale'],_0x5b0cfb=_0x2ef58a(_0x484e0f);_0x5b0cfb['panelPosition']='sw';const _0x1e47f4=function(_0x5e2e90,_0x3d2732){const _0x4fa642=function(_0x3988c4,_0x135ef3){const _0x8582d1=_0x3988c4['locale'],_0x8cc003={'Compare\x20against\x20selected':R(_0x8582d1,'Compare\x20against\x20selected'),'Name\x20this\x20revision':R(_0x8582d1,'Name\x20this\x20revision'),'Restore\x20this\x20revision':R(_0x8582d1,'Restore\x20this\x20revision')};return _0x135ef3['map'](_0x18afbb=>{const _0x2ff64f=_0x8cc003[_0x18afbb['name']];return _0x2ff64f&&_0x2ff64f!==_0x18afbb['name']&&(_0x18afbb['name']=_0x2ff64f),_0x18afbb;});}(_0x5e2e90,_0x3d2732),_0x29b979=new _0x577801();for(const _0x383b87 of _0x4fa642){const _0x3b84ea={'type':'button','model':new to({'label':_0x383b87['name'],'class':_0x383b87['class'],'withText':!0x0,'role':'menuitem','_action':_0x383b87['action']})};_0x3b84ea['model']['bind']('isEnabled')['to'](_0x5e2e90,'isActionsDropdownOpen',_0x2a9f07=>'function'!=typeof _0x383b87['isEnabled']||(!_0x2a9f07||_0x383b87['isEnabled'](_0x5e2e90))),_0x29b979['add'](_0x3b84ea);}return _0x29b979;}(_0x4a0ea8,_0x422e8b);return _0x4a0ea8['bind']('isActionsDropdownOpen')['to'](_0x5b0cfb,'isOpen'),_0x5b0cfb['buttonView']['set']({'label':R(_0x484e0f,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x3f8486}),_0x5b0cfb['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x4c0488['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x4c0488['to'](_0x449633=>_0x449633['stopPropagation']())}}),_0x5b0cfb['on']('execute',_0x45a0c2=>{_0x4a0ea8['isReady']&&'function'==typeof _0x45a0c2['source']['_action']&&_0x45a0c2['source']['_action'](_0x4a0ea8);}),_0x121886(_0x5b0cfb,_0x1e47f4,{'role':'menu'}),_0x5b0cfb['listenTo'](_0x4a0ea8,'change:isActionsDropdownOpen',(_0x3ebe8f,_0x3ffa19,_0x39c7b5)=>{if(_0x39c7b5)for(const _0x55ac7d of _0x5b0cfb['listView']['items']){const _0x23c063=_0x55ac7d['children']['first'],_0x18f0a4=_0x422e8b['find'](_0x3cc179=>_0x3cc179['action']===_0x23c063['_action'])['isVisible'];_0x55ac7d['isVisible']=void 0x0===_0x18f0a4||_0x18f0a4(_0x4a0ea8);}}),_0x5b0cfb;}class pi extends/* #__PURE__ -- @preserve */
|
|
27
|
+
_0x525a0c(_0x13ae3e){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x4633e9,_0x37a366,_0x531e8a,_0xef027){super(_0x4633e9);const _0x479651=this['bindTemplate'],_0x41ec0e=function(_0x6b533d,_0x298fb3){const _0x548a64=Array['from'](_0x298fb3['authors'])['filter'](_0x3a8fb1=>_0x3a8fb1!=_0x298fb3['creator']);return _0x298fb3['creator']&&_0x548a64['unshift'](_0x298fb3['creator']),_0x548a64['map'](_0xa35a7a=>new vi(_0x6b533d,_0xa35a7a,_0xa35a7a==_0x298fb3['creator']));}(_0x4633e9,_0x37a366);this['id']=_0x37a366['id'],this['_revision']=_0x37a366,this['_requireRevisionName']=_0xef027,this['bind']('name','createdAt')['to'](_0x37a366),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x39df16=>{return _0x56a02f=_0x4633e9['uiLanguage'],(_0x905aa9=_0x39df16)['toLocaleDateString'](_0x56a02f,{'month':'long','day':'numeric'})+',\x20'+_0x905aa9['toLocaleTimeString'](_0x56a02f,{'hour':'numeric','minute':'numeric'});var _0x56a02f,_0x905aa9;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new li(_0x4633e9,_0x14027c),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x3eb07c=>_0x3eb07c||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x4b79eb,_0xea7d77)=>_0x4b79eb&&_0xea7d77),this['revisionActionsView']=_0x531e8a&&_0x531e8a['length']?mi(this,_0x531e8a):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x479651['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x479651['if']('isEnabled','ck-disabled',_0x19bcf1=>!_0x19bcf1),_0x479651['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x479651['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x479651['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':_0x479651['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':_0x41ec0e}]},this['revisionActionsView']],'on':{'click':_0x479651['to'](_0xaba1a8=>{_0xaba1a8['srcElement']['closest']('.ck-thread__remove-confirm')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x2be937=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x2be937,'change',()=>{this['_requireRevisionName']&&!_0x2be937['value']||this['fire']('setName',{'id':this['id'],'name':_0x2be937['value']}),_0x2be937['value']||(_0x2be937['value']=this['name']?this['name']:this['_createdAtFormatted']);});}['select'](){this['isSelected']=!0x0;}['deselect'](){this['isSelected']=!0x1;}['highlight'](){this['isHighlighted']=!0x0;}['unhighlight'](){this['isHighlighted']=!0x1;}}function bi(_0x128ed8,_0x3fdfa9){const _0x32143b=_0x489a69['fromJSDate'](_0x128ed8)['setLocale'](_0x3fdfa9),_0xae7f9b=_0x489a69['local'](),_0x16bd08=_0xae7f9b['minus']({'days':0x1})['startOf']('day');let _0x5d9c9a,_0x214d80;return _0x32143b['hasSame'](_0xae7f9b,'day')?(_0x5d9c9a=_0x32143b['startOf']('day')['toJSDate'](),_0x214d80=_0x32143b['toRelativeCalendar']()):_0x32143b['hasSame'](_0x16bd08,'day')?(_0x5d9c9a=_0x16bd08['toJSDate'](),_0x214d80=_0x32143b['toRelativeCalendar']()):_0x32143b['hasSame'](_0xae7f9b,'week')?(_0x5d9c9a=_0x32143b['startOf']('week')['toJSDate'](),_0x214d80=_0x32143b['weekdayLong']||''):_0x32143b['hasSame'](_0xae7f9b,'year')?(_0x5d9c9a=_0x32143b['startOf']('month')['toJSDate'](),_0x214d80=_0x32143b['monthLong']||''):(_0x5d9c9a=_0x32143b['startOf']('year')['toJSDate'](),_0x214d80=String(_0x32143b['year'])),{'startDate':_0x5d9c9a,'localizedPeriodName':_0x214d80};}class fi extends _0x13ae3e{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x3d0c7b,_0x13bc08,_0x570191,_0x45be54){super(_0x3d0c7b);const _0x56fc95=bi(_0x13bc08,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x13bc08,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x570191,this['_requireRevisionName']=_0x45be54,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':_0x56fc95}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x9c8dc3){const _0x267162=new pi(this['locale'],_0x9c8dc3,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x267162);}['removeRevision'](_0x582b11){const _0x40a306=this['revisionViews']['find'](_0xf62cac=>_0xf62cac['id']===_0x582b11['id']);this['revisionViews']['remove'](_0x40a306);}}class ki extends _0x13ae3e{constructor(_0x402c57){super(_0x402c57);const _0x5a8722=new _0x24f111();_0x5a8722['content']=_0x2efa8c,this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x5a8722,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[R(_0x402c57,'Revision\x20history')]}]});}}class ui extends _0x13ae3e{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x55ced9,_0x1dcc2d,_0x2be319,_0x5d44cb){super(_0x55ced9);const _0x160f4e=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x1dcc2d,this['_revisionActions']=_0x2be319,this['_requireRevisionName']=_0x5d44cb,this['on']('select',(_0x3ff391,_0x3bcecd)=>{this['fire']('revisionSelected',_0x3bcecd);}),this['on']('setName',(_0x4750e0,_0x280d90)=>{this['fire']('revisionSetName',_0x280d90);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new ki(_0x55ced9),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x160f4e['if']('isEnabled','ck-disabled',_0x3c6efc=>!_0x3c6efc)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x158c5d of this['_revisions'])this['_addRevision'](_0x158c5d);this['_revisions']['on']('add',(_0x30bd3a,_0x3041b1)=>{this['_addRevision'](_0x3041b1);}),this['_revisions']['on']('remove',(_0x562f4d,_0x5879dc)=>{this['_removeRevision'](_0x5879dc);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0xc61b9e=>_0xc61b9e['revisionViews']['map'](_0x45d140=>_0x45d140))['flat']();}['selectRevision'](_0x373fde){for(const _0x16259c of this['revisionViews'])_0x373fde&&_0x373fde['id']===_0x16259c['id']?_0x16259c['select']():_0x16259c['deselect']();}['highlightRevisions'](_0x290882){for(const _0x4c6caa of this['revisionViews'])_0x290882['some'](({id:_0x360044})=>_0x360044===_0x4c6caa['id'])?_0x4c6caa['highlight']():_0x4c6caa['unhighlight']();}['_addRevision'](_0x1788e6){const _0x27f4de=bi(_0x1788e6['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x4df8ee=this['timePeriodViews']['get'](0x0);_0x4df8ee&&_0x4df8ee['startDate']['getTime']()===_0x27f4de['getTime']()||(_0x4df8ee=new fi(this['locale'],_0x27f4de,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x4df8ee)),_0x4df8ee['addRevision'](_0x1788e6);}['_removeRevision'](_0x24bd1d){const _0x187bc2=bi(_0x24bd1d['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x187bc2)['removeRevision'](_0x24bd1d);}['_getTimePeriodViewByStartDate'](_0x2070f3){return this['timePeriodViews']['find'](_0x813315=>_0x813315['startDate']['getTime']()===_0x2070f3['getTime']());}}class f extends _0x5b0dba{['_revisionViewer'];['_revisionsRepository'];['_sidebarView'];static ['defaultRevisionActions']=/* #__PURE__ -- @preserve */
|
|
28
28
|
((()=>['compareAgainstSelected','restoreRevision','nameRevision'])());static ['availableRevisionActions']=/* #__PURE__ -- @preserve */
|
|
29
|
-
rt();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l];}constructor(
|
|
30
|
-
_0x3d53cc(_0x130cd1){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x49e000,_0x20f0ea){super(_0x20f0ea),this['sourceElement']=_0x49e000,this['model']['document']['createRoot']();const _0x4f1dd5=new ii(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new Z(this,_0x4f1dd5);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x5555ef,_0x302182){const _0x1d6887=new this(_0x5555ef,_0x302182);return await _0x1d6887['initPlugins'](),await _0x1d6887['ui']['init'](_0x5555ef),await _0x1d6887['data']['init'](_0x1d6887['config']['get']('initialData')||''),_0x1d6887['fire']('ready'),_0x1d6887;}}const d=['RevisionHistoryUI','RestrictedEditingMode'];class at extends _0x858dc7{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x12cbd0){function _0x26663c(_0x41bbd5){return _0x41bbd5['map'](_0x3ff85c=>String['fromCharCode'](_0x3ff85c))['join']('');}super(_0x12cbd0),this['result']='end',_0x12cbd0[_0x26663c([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x26663c([0x76,0x69,0x65,0x77])][_0x26663c([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x26663c([0x61,0x75,0x74,0x6f]),_0x12cbd0[_0x26663c([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x26663c([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x26663c([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x26663c([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x26663c([0x6f,0x6b])});}}class ht extends _0x858dc7{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h,v];}constructor(_0x452965){if(super(_0x452965),!this['editor']['config']['get']('revisionHistory'))throw new _0x5ea239('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x4b66bf=>this['_showRevisionViewer']({..._0x4b66bf,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x3391cb=>this['_closeRevisionViewer'](_0x3391cb)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x142228=>this['_restoreRevision'](_0x142228)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x21ed07){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x21ed07;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x3137cb){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x3137cb);}['getRevision'](_0x227823){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x227823);}['getRevisions'](_0x5e2fd1){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x5e2fd1||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x5c60a8=this['editor'],_0x350d7d=_0x74082c(_0x5c60a8,d),_0x230518=_0x5c60a8['plugins']['get']('RevisionTracker'),_0x3bd461=_0x5c60a8['plugins']['get']('Users')['users'];return _0x350d7d['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x350d7d['lazyRoots'],(_0x350d7d['plugins']['push'](at,l,u,class extends _0x858dc7{static get['requires'](){return[l,'Users'];}['init'](){const _0x448dd=this['editor']['plugins']['get']('Users');for(const _0x4aca47 of _0x3bd461)_0x4aca47['isAnonymous']||_0x448dd['getUser'](_0x4aca47['id'])||_0x448dd['addUser'](_0x4aca47);const _0x52ce10=_0x230518['repository']['getRevisions']();let _0x5c8c9a=null;const _0x144c5c=this['editor']['plugins']['get']('RevisionViewer');_0x144c5c['adapter']=_0x230518['adapter'],_0x144c5c['bind']('isEnabled')['to'](_0x230518),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x5c60a8,'isReadOnly',_0x116b78=>!_0x116b78);for(const _0x561975 of _0x52ce10){const _0x4b6415=null===_0x561975['creator'];if(_0x4b6415&&_0x561975['toVersion']===_0x561975['fromVersion'])continue;const _0x203b93=_0x561975['toJSON']();_0x144c5c['addRevisionData'](_0x203b93,(_0x53d3ed,_0x572368,_0x3bb22b)=>{if(_0x4b6415){if(_0x5c8c9a)_0x5c8c9a['_update'](_0x53d3ed,_0x572368);else{if(!_0x572368){const _0x4503ac=_0x3bb22b['toJSON']();_0x4503ac['id']=_0x1a737e(),_0x230518['saveRevision'](_0x4503ac,_0x3bb22b['toVersion'])['then'](_0x38a870=>{_0x5c8c9a=_0x38a870;});}}}else _0x561975['_update'](_0x53d3ed,_0x572368);});}}},f),_0x350d7d);}['_enhanceShowRevisionViewerCallback'](){const _0x3fa965=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x16448a=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x44a740=this['editor']['plugins']['get']('Autosave');await _0x44a740['save']();}else await _0x16448a['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x3766a2=this['editor']['plugins']['get']('Dialog');_0x3766a2['isOpen']&&_0x3766a2['hide']();}const _0x5d4c04=this['_getRevisionViewerEditorConfig']();return _0x3fa965(_0x5d4c04)['then'](_0x4a41f3=>{return(this['_viewerEditor']=_0x4a41f3,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'),_0x4a41f3);})['catch'](_0x416899=>(console['error'](_0x416899),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x57a95d=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'](),_0x57a95d(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x4f762=this['editor']['plugins']['get']('Annotations');_0x4f762['refreshVisibility'](),_0x4f762['refreshPositioning']();}})));}['_showRevisionViewer'](_0x74784b){const _0x40c22f=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x4a734e=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x38ec65=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return m['create'](_0x38ec65,_0x74784b)['then'](_0x4e34c7=>(_0x4a734e['style']['display']='block',_0x40c22f['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x4e34c7));}['_closeRevisionViewer'](_0x547d20){const _0x27090f=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x27090f['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x547d20['destroy']();}async['_restoreRevision'](_0x58b5d2){const _0x1cec46=this['editor'],_0x380de2=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x292a6d=_0x1cec46['plugins']['get']('RevisionTracker'),_0x3ced14=_0x1cec46['plugins']['get']('RevisionHistoryUtils'),_0x30d5a6=_0x380de2['repository']['getRevision'](_0x58b5d2);let _0x251f30,_0x49d59f,_0x49fa19;try{await _0x3ced14['loadRevisionData'](_0x30d5a6,this['adapter']),_0x251f30=_0x3ced14['getRevisionDocumentData'](_0x30d5a6),_0x49d59f=_0x3ced14['getRevisionRootsAttributes'](_0x30d5a6);}catch(_0xb85e5e){return void console['error'](_0xb85e5e);}_0x1cec46['model']['change'](_0x268684=>{for(const _0x2a45f7 of Array['from'](_0x1cec46['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x268684['removeMarker'](_0x2a45f7);}),_0x380de2['isReady']=!0x1,_0x1cec46['model']['enqueueChange'](_0x369d03=>{_0x369d03['setSelection'](null),_0x369d03['removeSelectionAttribute'](_0x1cec46['model']['document']['selection']['getAttributeKeys']());const _0x2acc1e=Object['keys'](_0x251f30);for(const _0x347d0d of _0x1cec46['model']['document']['roots'])'$graveyard'!=_0x347d0d['rootName']&&_0x347d0d['isAttached']()&&!_0x2acc1e['includes'](_0x347d0d['rootName'])&&_0x369d03['detachRoot'](_0x347d0d);for(const _0x21c069 of _0x2acc1e){let _0x122650=_0x1cec46['model']['document']['getRoot'](_0x21c069);_0x122650&&_0x122650['isAttached']()||(_0x122650=_0x369d03['addRoot'](_0x21c069));const _0x40213f=_0x49d59f[_0x21c069],_0x22b895=Object['keys'](_0x40213f),_0x162c01=_0x251f30[_0x21c069];for(const _0x5760d9 of _0x122650['getAttributeKeys']())_0x22b895['includes'](_0x5760d9)||_0x369d03['removeAttribute'](_0x5760d9,_0x122650);for(const _0x1c3a80 of _0x22b895)_0x369d03['setAttribute'](_0x1c3a80,_0x49d59f[_0x21c069][_0x1c3a80],_0x122650);_0x369d03['remove'](_0x369d03['createRangeIn'](_0x122650)),_0x369d03['insert'](_0x1cec46['data']['parse'](_0x162c01,_0x122650),_0x122650,0x0);}});const _0x1bbc7e=R(_0x1cec46['locale'],'Restored');if(_0x30d5a6['name'])_0x49fa19=-0x1==_0x30d5a6['name']['indexOf'](_0x1bbc7e)?_0x1bbc7e+':\x20'+_0x30d5a6['name']:_0x30d5a6['name'];else _0x49fa19=_0x1bbc7e+':\x20'+(_0x30d5a6['createdAt']['toLocaleDateString'](_0x1cec46['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x30d5a6['createdAt']['toLocaleTimeString'](_0x1cec46['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x292a6d['saveRevision']({'name':_0x49fa19}),_0x380de2['isReady']=!0x0,_0x1cec46['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{nt as RestoreRevisionCommand,I as Revision,ht as RevisionHistory,v as RevisionHistoryUI,$ as RevisionHistoryUtils,h as RevisionTracker,l as RevisionViewer,m as RevisionViewerEditor,ji as RevisionViewerLoadingOverlay,u as RevisionViewerUI,S as RevisionsRepository,f as RevisionsSidebar,ot as ShowChangeCommand};
|
|
29
|
+
rt();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l];}constructor(_0x2765f0){super(_0x2765f0),this['_revisionViewer']=_0x2765f0['plugins']['get'](l),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x399dff=this['_revisionsRepository']['_revisions'],_0x12170f=this['_createRevisionActions'](),_0x2758a8=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new ui(this['editor']['locale'],_0x399dff,_0x12170f,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',(_0x344077,_0x584975)=>{_0x584975['revisionViews']['on']('add',(_0x1f3b58,_0x5b7719)=>{_0x5b7719['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)),_0x2758a8['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x3f3a17=this['_revisionsRepository']['getRevision'](0x0);if(_0x3f3a17){const _0x21d14f=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x3f3a17['id']);this['_revisionViewer']['compare'](_0x3f3a17,_0x21d14f);}}['_handleRevisionSelected'](_0x477e47,_0x538679){const _0x346957=this['_revisionsRepository']['getRevision'](_0x538679['id']),_0x1933c6=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x346957['id']);this['_revisionViewer']['compare'](_0x346957,_0x1933c6);}['_handleRevisionSetName'](_0x415d55,_0x286fd7){this['_revisionsRepository']['getRevision'](_0x286fd7['id'])['setName'](_0x286fd7['name']);}['_handleDiffChange'](_0x519795,_0x38121f,_0x229d1b){const _0x4ae3ff=this['_revisionsRepository']['getRevisionsInDiff'](_0x229d1b);_0x4ae3ff['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x4ae3ff),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x4ae3ff[0x0]));}['_createRevisionActions'](){const _0x1f5a56=this['editor'],_0x3074cf=f['availableRevisionActions'],_0x18d8c6=_0x1f5a56['config']['get']('revisionHistory.revisionActions')||f['defaultRevisionActions'];if(_0x18d8c6['length'])return _0x18d8c6['map'](_0x274d40=>{const _0x2b0eeb='string'==typeof _0x274d40?Object['assign']({},_0x3074cf[_0x274d40]):_0x274d40;return _0x2b0eeb['action']=_0x2b0eeb['action']['bind'](this,_0x1f5a56),_0x2b0eeb['isVisible']&&(_0x2b0eeb['isVisible']=_0x2b0eeb['isVisible']['bind'](this,_0x1f5a56)),_0x2b0eeb;});}}function rt(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x1bf9b0},_0x584a6a)=>{const _0x1fe6e1=_0x1bf9b0['get'](l),_0x39563b=_0x1fe6e1['repository'];let _0x52cfbf=_0x1fe6e1['diff']['newRevisionId'],_0x32f792=_0x584a6a['id'];_0x39563b['getIndex'](_0x52cfbf)>_0x39563b['getIndex'](_0x32f792)&&([_0x52cfbf,_0x32f792]=[_0x32f792,_0x52cfbf]),_0x1fe6e1['compare'](_0x52cfbf,_0x32f792);},'isVisible':({plugins:_0x172280},_0x24302c)=>{const _0x1fa7a3=_0x172280['get'](l);return!(_0x1fa7a3['repository']['getRevisionsInDiff'](_0x1fa7a3['diff'])['length']>0x2)&&!_0x24302c['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x533ece,{id:_0xbd491d})=>{_0x533ece['config']['get']('revisionHistory')['restoreRevisionCallback'](_0xbd491d);},'isVisible':({plugins:_0x17ad1b},_0x305a63)=>!!_0x17ad1b['get'](l)['repository']['getLaterVisibleRevision'](_0x305a63['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x1dbb17},{id:_0x17a412,revisionNameView:_0xe9a7a})=>{const _0x57eb18=_0x1dbb17['get'](l),_0x2c9fa4=_0x57eb18['repository']['getEarlierVisibleRevision'](_0x17a412);_0x57eb18['compare'](_0x17a412,_0x2c9fa4),_0xe9a7a['focus'](),_0xe9a7a['fieldView']['select']();}}};}class Z extends tt{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x4857fc,_0x471126){super(_0x4857fc),this['_view']=_0x471126,this['_toolbarConfig']=st(_0x4857fc['config']['get']('toolbar')),this['_elementReplacer']=new it();}get['element'](){return this['view']['element'];}['init'](_0x29adbc){const _0x205813=this['editor'],_0x5d87d0=this['view'],_0x51eaa9=_0x205813['editing']['view'],_0x365317=_0x5d87d0['editable'],_0x291cd9=_0x51eaa9['document']['getRoot']();_0x365317['name']=_0x291cd9['rootName'],_0x5d87d0['render']();const _0x53a278=_0x365317['element'];this['setEditableElement'](_0x365317['name'],_0x53a278),_0x5d87d0['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x51eaa9['attachDomRoot'](_0x53a278),this['_elementReplacer']['replace'](_0x29adbc,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x1a22bf=this['view'],_0x3dea13=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x3dea13['detachDomRoot'](_0x1a22bf['editable']['name']),_0x1a22bf['destroy']();}['_initToolbar'](){const _0x156319=this['view'];_0x156319['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x156319['stickyPanel']['limiterElement']=_0x156319['element'],_0x156319['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x43d3a9})=>_0x43d3a9),_0x156319['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x156319['toolbar']);}}class ii extends _0xbb4a8a{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x21a57b,_0x5b8390,_0x35312c={}){super(_0x21a57b),this['stickyPanel']=new _0x345106(_0x21a57b),this['toolbar']=new _0x9f2c9(_0x21a57b,{'shouldGroupWhenFull':_0x35312c['shouldToolbarGroupWhenFull']}),this['_editable']=new te(_0x21a57b,_0x5b8390);}['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
|
+
_0x1caf97(_0x4e4a7e){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x50ae3b,_0x3f2309){super(_0x3f2309),this['sourceElement']=_0x50ae3b,this['model']['document']['createRoot']();const _0x3ddffa=new ii(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new Z(this,_0x3ddffa);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x5b52db,_0x264abd){const _0x12148e=new this(_0x5b52db,_0x264abd);return await _0x12148e['initPlugins'](),await _0x12148e['ui']['init'](_0x5b52db),await _0x12148e['data']['init'](_0x12148e['config']['get']('initialData')||''),_0x12148e['fire']('ready'),_0x12148e;}}const d=['RevisionHistoryUI','RestrictedEditingMode'];class at extends _0x5b0dba{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x4734a8){function _0x1145af(_0x78d27f){return _0x78d27f['map'](_0x2855a4=>String['fromCharCode'](_0x2855a4))['join']('');}super(_0x4734a8),this['result']='end',_0x4734a8[_0x1145af([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x1145af([0x76,0x69,0x65,0x77])][_0x1145af([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x1145af([0x61,0x75,0x74,0x6f]),_0x4734a8[_0x1145af([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x1145af([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x1145af([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x1145af([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x1145af([0x6f,0x6b])});}}class ht extends _0x5b0dba{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h,v];}constructor(_0x53394a){if(super(_0x53394a),!this['editor']['config']['get']('revisionHistory'))throw new _0x55e8c6('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x50e07f=>this['_showRevisionViewer']({..._0x50e07f,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x5c9b8b=>this['_closeRevisionViewer'](_0x5c9b8b)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x4c82d5=>this['_restoreRevision'](_0x4c82d5)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0xea1107){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0xea1107;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x1d6aa1){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x1d6aa1);}['getRevision'](_0x5d9629){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x5d9629);}['getRevisions'](_0x2f07fe){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x2f07fe||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x13cbec=this['editor'],_0x531f42=_0x23274b(_0x13cbec,d),_0x3afb62=_0x13cbec['plugins']['get']('RevisionTracker'),_0x19ce0f=_0x13cbec['plugins']['get']('Users')['users'];return _0x531f42['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x531f42['lazyRoots'],(_0x531f42['plugins']['push'](at,l,u,class extends _0x5b0dba{static get['requires'](){return[l,'Users'];}['init'](){const _0x2cc9c5=this['editor']['plugins']['get']('Users');for(const _0x1879a6 of _0x19ce0f)_0x1879a6['isAnonymous']||_0x2cc9c5['getUser'](_0x1879a6['id'])||_0x2cc9c5['addUser'](_0x1879a6);const _0x5193e6=_0x3afb62['repository']['getRevisions']();let _0x10f7c1=null;const _0x26e32b=this['editor']['plugins']['get']('RevisionViewer');_0x26e32b['adapter']=_0x3afb62['adapter'],_0x26e32b['bind']('isEnabled')['to'](_0x3afb62),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x13cbec,'isReadOnly',_0x533bf8=>!_0x533bf8);for(const _0x3ba657 of _0x5193e6){const _0x486556=null===_0x3ba657['creator'];if(_0x486556&&_0x3ba657['toVersion']===_0x3ba657['fromVersion'])continue;const _0x28bc53=_0x3ba657['toJSON']();_0x26e32b['addRevisionData'](_0x28bc53,(_0x3121d4,_0x5e4c74,_0x1e5ee7)=>{if(_0x486556){if(_0x10f7c1)_0x10f7c1['_update'](_0x3121d4,_0x5e4c74);else{if(!_0x5e4c74){const _0x2c4b05=_0x1e5ee7['toJSON']();_0x2c4b05['id']=_0xc2c09a(),_0x3afb62['saveRevision'](_0x2c4b05,_0x1e5ee7['toVersion'])['then'](_0x179dc5=>{_0x10f7c1=_0x179dc5;});}}}else _0x3ba657['_update'](_0x3121d4,_0x5e4c74);});}}},f),_0x531f42);}['_enhanceShowRevisionViewerCallback'](){const _0x4fc439=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x345fc=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x5e9d03=this['editor']['plugins']['get']('Autosave');await _0x5e9d03['save']();}else await _0x345fc['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x138dc4=this['editor']['plugins']['get']('Dialog');_0x138dc4['isOpen']&&_0x138dc4['hide']();}const _0x30ac8a=this['_getRevisionViewerEditorConfig']();return _0x4fc439(_0x30ac8a)['then'](_0xedffd9=>{return(this['_viewerEditor']=_0xedffd9,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'),_0xedffd9);})['catch'](_0x237b72=>(console['error'](_0x237b72),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x20ac05=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'](),_0x20ac05(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x24280b=this['editor']['plugins']['get']('Annotations');_0x24280b['refreshVisibility'](),_0x24280b['refreshPositioning']();}})));}['_showRevisionViewer'](_0x5335c7){const _0x1330f0=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x1af0b5=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x5b0fb2=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return m['create'](_0x5b0fb2,_0x5335c7)['then'](_0x203224=>(_0x1af0b5['style']['display']='block',_0x1330f0['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x203224));}['_closeRevisionViewer'](_0x3b4500){const _0x38feaa=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x38feaa['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x3b4500['destroy']();}async['_restoreRevision'](_0x175244){const _0x5a3768=this['editor'],_0x1dcfbd=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x346dc6=_0x5a3768['plugins']['get']('RevisionTracker'),_0x11a6e7=_0x5a3768['plugins']['get']('RevisionHistoryUtils'),_0x377b8b=_0x1dcfbd['repository']['getRevision'](_0x175244);let _0x10e5af,_0xaaf005,_0x393328;try{await _0x11a6e7['loadRevisionData'](_0x377b8b,this['adapter']),_0x10e5af=_0x11a6e7['getRevisionDocumentData'](_0x377b8b),_0xaaf005=_0x11a6e7['getRevisionRootsAttributes'](_0x377b8b);}catch(_0xbe0354){return void console['error'](_0xbe0354);}_0x5a3768['model']['change'](_0x2e49e0=>{for(const _0x555c7e of Array['from'](_0x5a3768['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x2e49e0['removeMarker'](_0x555c7e);}),_0x1dcfbd['isReady']=!0x1,_0x5a3768['model']['enqueueChange'](_0x532688=>{_0x532688['setSelection'](null),_0x532688['removeSelectionAttribute'](_0x5a3768['model']['document']['selection']['getAttributeKeys']());const _0x58d716=Object['keys'](_0x10e5af);for(const _0x1a132b of _0x5a3768['model']['document']['roots'])'$graveyard'!=_0x1a132b['rootName']&&_0x1a132b['isAttached']()&&!_0x58d716['includes'](_0x1a132b['rootName'])&&_0x532688['detachRoot'](_0x1a132b);for(const _0x2446bf of _0x58d716){let _0x270adf=_0x5a3768['model']['document']['getRoot'](_0x2446bf);_0x270adf&&_0x270adf['isAttached']()||(_0x270adf=_0x532688['addRoot'](_0x2446bf));const _0x1cd9c3=_0xaaf005[_0x2446bf],_0x1e4d48=Object['keys'](_0x1cd9c3),_0x5ed784=_0x10e5af[_0x2446bf];for(const _0x1dc424 of _0x270adf['getAttributeKeys']())_0x1e4d48['includes'](_0x1dc424)||_0x532688['removeAttribute'](_0x1dc424,_0x270adf);for(const _0x364ae4 of _0x1e4d48)_0x532688['setAttribute'](_0x364ae4,_0xaaf005[_0x2446bf][_0x364ae4],_0x270adf);_0x532688['remove'](_0x532688['createRangeIn'](_0x270adf)),_0x532688['insert'](_0x5a3768['data']['parse'](_0x5ed784,_0x270adf),_0x270adf,0x0);}});const _0x71b074=R(_0x5a3768['locale'],'Restored');if(_0x377b8b['name'])_0x393328=-0x1==_0x377b8b['name']['indexOf'](_0x71b074)?_0x71b074+':\x20'+_0x377b8b['name']:_0x377b8b['name'];else _0x393328=_0x71b074+':\x20'+(_0x377b8b['createdAt']['toLocaleDateString'](_0x5a3768['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x377b8b['createdAt']['toLocaleTimeString'](_0x5a3768['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x346dc6['saveRevision']({'name':_0x393328}),_0x1dcfbd['isReady']=!0x0,_0x5a3768['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{nt as RestoreRevisionCommand,I as Revision,ht as RevisionHistory,v as RevisionHistoryUI,$ as RevisionHistoryUtils,h as RevisionTracker,l as RevisionViewer,m as RevisionViewerEditor,ji as RevisionViewerLoadingOverlay,u as RevisionViewerUI,S as RevisionsRepository,f as RevisionsSidebar,ot as ShowChangeCommand};
|