@ckeditor/ckeditor5-revision-history 47.0.0-alpha.8 → 47.0.0-alpha.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/revision-history.js +1 -1
- package/dist/index.js +7 -7
- package/dist/translations/af.js +1 -1
- package/dist/translations/af.umd.js +1 -1
- package/dist/translations/ar.js +1 -1
- package/dist/translations/ar.umd.js +1 -1
- package/dist/translations/ast.js +1 -1
- package/dist/translations/ast.umd.js +1 -1
- package/dist/translations/az.js +1 -1
- package/dist/translations/az.umd.js +1 -1
- package/dist/translations/be.js +1 -1
- package/dist/translations/be.umd.js +1 -1
- package/dist/translations/bg.js +1 -1
- package/dist/translations/bg.umd.js +1 -1
- package/dist/translations/bn.js +1 -1
- package/dist/translations/bn.umd.js +1 -1
- package/dist/translations/bs.js +1 -1
- package/dist/translations/bs.umd.js +1 -1
- package/dist/translations/ca.js +1 -1
- package/dist/translations/ca.umd.js +1 -1
- package/dist/translations/cs.js +1 -1
- package/dist/translations/cs.umd.js +1 -1
- package/dist/translations/da.js +1 -1
- package/dist/translations/da.umd.js +1 -1
- package/dist/translations/de-ch.js +1 -1
- package/dist/translations/de-ch.umd.js +1 -1
- package/dist/translations/de.js +1 -1
- package/dist/translations/de.umd.js +1 -1
- package/dist/translations/el.js +1 -1
- package/dist/translations/el.umd.js +1 -1
- package/dist/translations/en-au.js +1 -1
- package/dist/translations/en-au.umd.js +1 -1
- package/dist/translations/en-gb.js +1 -1
- package/dist/translations/en-gb.umd.js +1 -1
- package/dist/translations/en.js +1 -1
- package/dist/translations/en.umd.js +1 -1
- package/dist/translations/eo.js +1 -1
- package/dist/translations/eo.umd.js +1 -1
- package/dist/translations/es-co.js +1 -1
- package/dist/translations/es-co.umd.js +1 -1
- package/dist/translations/es.js +1 -1
- package/dist/translations/es.umd.js +1 -1
- package/dist/translations/et.js +1 -1
- package/dist/translations/et.umd.js +1 -1
- package/dist/translations/eu.js +1 -1
- package/dist/translations/eu.umd.js +1 -1
- package/dist/translations/fa.js +1 -1
- package/dist/translations/fa.umd.js +1 -1
- package/dist/translations/fi.js +1 -1
- package/dist/translations/fi.umd.js +1 -1
- package/dist/translations/fr.js +1 -1
- package/dist/translations/fr.umd.js +1 -1
- package/dist/translations/gl.js +1 -1
- package/dist/translations/gl.umd.js +1 -1
- package/dist/translations/gu.js +1 -1
- package/dist/translations/gu.umd.js +1 -1
- package/dist/translations/he.js +1 -1
- package/dist/translations/he.umd.js +1 -1
- package/dist/translations/hi.js +1 -1
- package/dist/translations/hi.umd.js +1 -1
- package/dist/translations/hr.js +1 -1
- package/dist/translations/hr.umd.js +1 -1
- package/dist/translations/hu.js +1 -1
- package/dist/translations/hu.umd.js +1 -1
- package/dist/translations/hy.js +1 -1
- package/dist/translations/hy.umd.js +1 -1
- package/dist/translations/id.js +1 -1
- package/dist/translations/id.umd.js +1 -1
- package/dist/translations/it.js +1 -1
- package/dist/translations/it.umd.js +1 -1
- package/dist/translations/ja.js +1 -1
- package/dist/translations/ja.umd.js +1 -1
- package/dist/translations/jv.js +1 -1
- package/dist/translations/jv.umd.js +1 -1
- package/dist/translations/kk.js +1 -1
- package/dist/translations/kk.umd.js +1 -1
- package/dist/translations/km.js +1 -1
- package/dist/translations/km.umd.js +1 -1
- package/dist/translations/kn.js +1 -1
- package/dist/translations/kn.umd.js +1 -1
- package/dist/translations/ko.js +1 -1
- package/dist/translations/ko.umd.js +1 -1
- package/dist/translations/ku.js +1 -1
- package/dist/translations/ku.umd.js +1 -1
- package/dist/translations/lt.js +1 -1
- package/dist/translations/lt.umd.js +1 -1
- package/dist/translations/lv.js +1 -1
- package/dist/translations/lv.umd.js +1 -1
- package/dist/translations/ms.js +1 -1
- package/dist/translations/ms.umd.js +1 -1
- package/dist/translations/nb.js +1 -1
- package/dist/translations/nb.umd.js +1 -1
- package/dist/translations/ne.js +1 -1
- package/dist/translations/ne.umd.js +1 -1
- package/dist/translations/nl.js +1 -1
- package/dist/translations/nl.umd.js +1 -1
- package/dist/translations/no.js +1 -1
- package/dist/translations/no.umd.js +1 -1
- package/dist/translations/oc.js +1 -1
- package/dist/translations/oc.umd.js +1 -1
- package/dist/translations/pl.js +1 -1
- package/dist/translations/pl.umd.js +1 -1
- package/dist/translations/pt-br.js +1 -1
- package/dist/translations/pt-br.umd.js +1 -1
- package/dist/translations/pt.js +1 -1
- package/dist/translations/pt.umd.js +1 -1
- package/dist/translations/ro.js +1 -1
- package/dist/translations/ro.umd.js +1 -1
- package/dist/translations/ru.js +1 -1
- package/dist/translations/ru.umd.js +1 -1
- package/dist/translations/si.js +1 -1
- package/dist/translations/si.umd.js +1 -1
- package/dist/translations/sk.js +1 -1
- package/dist/translations/sk.umd.js +1 -1
- package/dist/translations/sl.js +1 -1
- package/dist/translations/sl.umd.js +1 -1
- package/dist/translations/sq.js +1 -1
- package/dist/translations/sq.umd.js +1 -1
- package/dist/translations/sr-latn.js +1 -1
- package/dist/translations/sr-latn.umd.js +1 -1
- package/dist/translations/sr.js +1 -1
- package/dist/translations/sr.umd.js +1 -1
- package/dist/translations/sv.js +1 -1
- package/dist/translations/sv.umd.js +1 -1
- package/dist/translations/th.js +1 -1
- package/dist/translations/th.umd.js +1 -1
- package/dist/translations/ti.js +1 -1
- package/dist/translations/ti.umd.js +1 -1
- package/dist/translations/tk.js +1 -1
- package/dist/translations/tk.umd.js +1 -1
- package/dist/translations/tr.js +1 -1
- package/dist/translations/tr.umd.js +1 -1
- package/dist/translations/tt.js +1 -1
- package/dist/translations/tt.umd.js +1 -1
- package/dist/translations/ug.js +1 -1
- package/dist/translations/ug.umd.js +1 -1
- package/dist/translations/uk.js +1 -1
- package/dist/translations/uk.umd.js +1 -1
- package/dist/translations/ur.js +1 -1
- package/dist/translations/ur.umd.js +1 -1
- package/dist/translations/uz.js +1 -1
- package/dist/translations/uz.umd.js +1 -1
- package/dist/translations/vi.js +1 -1
- package/dist/translations/vi.umd.js +1 -1
- package/dist/translations/zh-cn.js +1 -1
- package/dist/translations/zh-cn.umd.js +1 -1
- package/dist/translations/zh.js +1 -1
- package/dist/translations/zh.umd.js +1 -1
- package/package.json +12 -12
- package/src/changeitem.js +2 -2
- package/src/editor/revisionviewereditor.js +2 -2
- package/src/editor/revisionviewereditorui.js +1 -1
- package/src/editor/revisionviewereditoruiview.js +1 -1
- package/src/index.js +1 -1
- package/src/revision.js +2 -2
- package/src/revisiondiff.js +1 -1
- package/src/revisionhistory.js +1 -1
- package/src/revisionhistoryutils.js +1 -1
- package/src/revisionsrepository.js +1 -1
- package/src/revisiontracker.js +1 -1
- package/src/revisionviewer.js +1 -1
- package/src/ui/revision/createrevisionactionsdropdown.js +1 -1
- package/src/ui/revision/revisionauthorview.js +1 -1
- package/src/ui/revision/revisionnameview.js +1 -1
- package/src/ui/revision/revisionview.js +2 -2
- package/src/ui/revision/subrevisioncollapserview.js +1 -1
- package/src/ui/revision/subrevisionview.js +1 -1
- package/src/ui/revision/utils.js +1 -1
- package/src/ui/revisionhistory/revisionhistorysaverevisionformview.js +2 -2
- package/src/ui/revisionhistory/revisionhistoryui.js +1 -1
- package/src/ui/revisionssidebar/revisionssidebar.js +1 -1
- package/src/ui/revisionssidebar/revisionssidebarheaderview.js +1 -1
- package/src/ui/revisionssidebar/revisionssidebartimeperiodview.js +1 -1
- package/src/ui/revisionssidebar/revisionssidebarview.js +1 -1
- package/src/ui/revisionssidebar/utils.js +1 -1
- package/src/ui/revisionviewer/changedetailsview.js +1 -1
- package/src/ui/revisionviewer/changesnavigationview.js +1 -1
- package/src/ui/revisionviewer/revisionviewerloadingoverlay.js +1 -1
- package/src/ui/revisionviewer/revisionviewerui.js +1 -1
- package/src/utils/common-translations.js +1 -1
package/dist/index.js
CHANGED
|
@@ -20,11 +20,11 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
import{ObservableMixin as
|
|
24
|
-
_0x37be83(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x475f5e){super(),this['id']=_0x475f5e['id']||_0x40f93b(),this['creator']=_0x475f5e['creator']||null,this['authors']=_0x475f5e['authors']||[],this['diffData']=_0x475f5e['diffData']||null,this['toVersion']=_0x475f5e['toVersion']||0x0,this['fromVersion']=_0x475f5e['fromVersion']||0x0,this['set']('name',_0x475f5e['name']||''),this['set']('createdAt',_0x475f5e['createdAt']||new Date()),this['set']('attributes',_0x475f5e['attributes']||{});}['setName'](_0x505c2b){this['_update']({'name':_0x505c2b});}['setAttribute'](_0x4ae9ab,_0x3ddca5){const _0xb40e3f=_0x378b0e(this['attributes']);_0x12de3c(_0xb40e3f,_0x4ae9ab,_0x3ddca5),this['_update']({'attributes':_0xb40e3f});}['removeAttribute'](_0x5c38c5){const _0x3d4bfd=_0x378b0e(this['attributes']);_0x19e1c2(_0x3d4bfd,_0x5c38c5),this['_update']({'attributes':_0x3d4bfd});}['_update'](_0x2af827,_0x4a7fca=!0x1){let _0x47d317=!0x1;const _0x16bdfa={'id':this['id']},_0x5ca32f=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x17df78 of _0x5ca32f){const _0x593fc9=_0x2af827[_0x17df78];void 0x0!==_0x593fc9&&_0x593fc9!==this[_0x17df78]&&(this[_0x17df78]=_0x593fc9,_0x16bdfa[_0x17df78]=_0x593fc9,_0x47d317=!0x0);}_0x47d317&&(_0x16bdfa['authors']&&(_0x16bdfa['authorsIds']=_0x16bdfa['authors']['map'](_0x596868=>_0x596868['id']),delete _0x16bdfa['authors']),this['fire']('_update',_0x16bdfa,_0x4a7fca));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0xbdfcdd=>_0xbdfcdd['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class S extends _0xb302f2{['_revisions'];static get['requires'](){return[_0x5232bd];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x4cda02){super(_0x4cda02),this['_revisions']=new _0x150ee0();}['afterInit'](){!async function(_0x3a4db4){const _0x2ee23a=_0x539569([0x73,0x47,0x36,0x35,0x43,0x72,0x6b,0x31,0x63,0x64,0x32,0x69,0x67,0x4c,0x4e,0x37,0x7a,0x49,0x45,0x41,0x59,0x6a,0x75,0x39,0x4a,0x33,0x68,0x62,0x50,0x42,0x74,0x6e,0x46,0x4d,0x78,0x51,0x66,0x34,0x48,0x77,0x5a,0x61,0x6c,0x30,0x71,0x54,0x53,0x56,0x4b,0x79,0x44,0x6d,0x6f,0x52,0x76,0x55,0x58,0x65,0x70,0x57,0x4f,0x38]),_0x54447b=0xeb829,_0x42ae38=0x7374585f,_0x91043=0x73732caf^_0x42ae38,_0x5ef47a=window[_0x539569([0x44,0x61,0x74,0x65])][_0x539569([0x6e,0x6f,0x77])](),_0x5de29f=_0x3a4db4[_0x539569([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x3f830a=new window[(_0x539569([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x50921e=>{_0x5de29f[_0x539569([0x6f,0x6e,0x63,0x65])](_0x539569([0x72,0x65,0x61,0x64,0x79]),_0x50921e);}),_0x4dcd5c={[_0x539569([0x6b,0x74,0x79])]:_0x539569([0x45,0x43]),[_0x539569([0x75,0x73,0x65])]:_0x539569([0x73,0x69,0x67]),[_0x539569([0x63,0x72,0x76])]:_0x539569([0x50,0x2d,0x32,0x35,0x36]),[_0x539569([0x78])]:_0x539569([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]),[_0x539569([0x79])]:_0x539569([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]),[_0x539569([0x61,0x6c,0x67])]:_0x539569([0x45,0x53,0x32,0x35,0x36])},_0x3edcaf=_0x5de29f[_0x539569([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x539569([0x67,0x65,0x74])](_0x539569([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x5a4628(){let _0x250851,_0xdbfa9=null,_0x2ff764=null;try{if(_0x3edcaf==_0x539569([0x47,0x50,0x4c]))return _0x539569([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x250851=_0x485e93(),!_0x250851)return _0x539569([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x250851[_0x539569([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x2ff764=_0x1f0726(_0x250851[_0x539569([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x250851[_0x539569([0x6a,0x74,0x69])])),await _0x38b2d0()?_0x43901d()?_0x5be38f()?_0x539569([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0xa96fb()?(_0x250851[_0x539569([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x539569([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0xdbfa9=_0x46dd2d(_0x539569([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x250851[_0x539569([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x539569([0x74,0x72,0x69,0x61,0x6c])&&(_0xdbfa9=_0x46dd2d(_0x539569([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x4ce0df()):_0x539569([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x539569([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x539569([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x539569([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x5be38f(){const _0x124389=[_0x539569([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x539569([0x74,0x72,0x69,0x61,0x6c])][_0x539569([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x250851[_0x539569([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x5ef47a/0x3e8:0xe10*_0x91043;return _0x250851[_0x539569([0x65,0x78,0x70])]<_0x124389;}function _0x43901d(){const _0xe2632d=_0x250851[_0x539569([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0xe2632d)return!0x1;if(_0xe2632d[_0x539569([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x539569([0x2a])))return!0x0;if(_0xe2632d[_0x539569([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x539569([0x52,0x48])))return!0x0;if(_0xe2632d[_0x539569([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x539569([0x52,0x52,0x48]))){if(_0x50a6ba())return!0x0;if(_0x2c3f2e()||_0x42f944())return!0x0;}return!0x1;}function _0xa96fb(){const _0x2b271f=_0x250851[_0x539569([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x2b271f||0x0==_0x2b271f[_0x539569([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x37fdb0}=new URL(window[_0x539569([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x2b271f[_0x539569([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x37fdb0))return!0x0;const _0x39b187=_0x37fdb0[_0x539569([0x73,0x70,0x6c,0x69,0x74])](_0x539569([0x2e]));return _0x2b271f[_0x539569([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x4ecc47=>_0x4ecc47[_0x539569([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x539569([0x2a])))[_0x539569([0x6d,0x61,0x70])](_0x27679d=>_0x27679d[_0x539569([0x73,0x70,0x6c,0x69,0x74])](_0x539569([0x2e])))[_0x539569([0x66,0x69,0x6c,0x74,0x65,0x72])](_0xc2440d=>_0xc2440d[_0x539569([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x39b187[_0x539569([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x539569([0x6d,0x61,0x70])](_0x252da9=>Array(_0x39b187[_0x539569([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0x252da9[_0x539569([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x539569([0x66,0x69,0x6c,0x6c])](_0x252da9[0x0]===_0x539569([0x2a])?_0x539569([0x2a]):'')[_0x539569([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0x252da9))[_0x539569([0x73,0x6f,0x6d,0x65])](_0x35aa24=>_0x39b187[_0x539569([0x65,0x76,0x65,0x72,0x79])]((_0x1218c9,_0xc77c65)=>_0x35aa24[_0xc77c65]===_0x1218c9||_0x35aa24[_0xc77c65]===_0x539569([0x2a])));}function _0x4ce0df(){return _0xdbfa9&&_0x2ff764?new window[(_0x539569([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x514e72,_0x26f55b)=>{_0xdbfa9[_0x539569([0x74,0x68,0x65,0x6e])](_0x514e72,_0x26f55b),_0x2ff764[_0x539569([0x74,0x68,0x65,0x6e])](_0x3535dc=>{_0x3535dc!=_0x539569([0x56,0x61,0x6c,0x69,0x64])&&_0x514e72(_0x3535dc);},_0x26f55b);}):_0xdbfa9||_0x2ff764||_0x539569([0x56,0x61,0x6c,0x69,0x64]);}}function _0x1f0726(_0x33bd05,_0x117d9e){return new window[(_0x539569([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x108062=>{if(_0x2c968c())return _0x108062(_0x539569([0x56,0x61,0x6c,0x69,0x64]));_0x469cf3(),_0x5de29f[_0x539569([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x539569([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x1582a1=!0x1;const _0x314787=_0x40f93b();function _0x299129(_0x3166f1){return!!_0x3166f1&&(typeof _0x3166f1===_0x539569([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x3166f1===_0x539569([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x3166f1[_0x539569([0x74,0x68,0x65,0x6e])]===_0x539569([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x3166f1[_0x539569([0x63,0x61,0x74,0x63,0x68])]===_0x539569([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x2bbc9f(_0x118ea1){_0x299b0d(_0x118ea1)[_0x539569([0x74,0x68,0x65,0x6e])](_0x43cfa9=>{if(!_0x43cfa9||_0x43cfa9[_0x539569([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x539569([0x6f,0x6b]))return _0x539569([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x1bd447(_0x541781(_0x314787+_0x117d9e))!=_0x43cfa9[_0x539569([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x539569([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x539569([0x56,0x61,0x6c,0x69,0x64]);})[_0x539569([0x74,0x68,0x65,0x6e])](_0x10ec3b=>(_0x31c102(),_0x10ec3b),()=>{const _0x3e66b2=_0x55e735();return null==_0x3e66b2?(_0x31c102(),_0x539569([0x56,0x61,0x6c,0x69,0x64])):_0x539569(_0x5ef47a-_0x3e66b2>(0x5778dc5f^_0x42ae38)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x539569([0x74,0x68,0x65,0x6e])](_0x108062)[_0x539569([0x63,0x61,0x74,0x63,0x68])](()=>{_0x108062(_0x539569([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0xb9d3fe=0x7342b6df^_0x42ae38;function _0x31c102(){const _0x4eae64=_0x539569([0x6c,0x6c,0x63,0x74,0x2d])+_0x1bd447(_0x541781(_0x33bd05)),_0x3c72fa=_0x4fa537(_0x1bd447(window[_0x539569([0x4d,0x61,0x74,0x68])][_0x539569([0x63,0x65,0x69,0x6c])](_0x5ef47a/_0xb9d3fe)));window[_0x539569([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x539569([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x4eae64,_0x3c72fa);}function _0x55e735(){const _0x59d31c=_0x539569([0x6c,0x6c,0x63,0x74,0x2d])+_0x1bd447(_0x541781(_0x33bd05)),_0x55ec06=window[_0x539569([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x539569([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x59d31c);return _0x55ec06?window[_0x539569([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x4fa537(_0x55ec06),0x10)*_0xb9d3fe:null;}function _0x299b0d(_0x5e23de){return new window[(_0x539569([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x290510,_0x5ba178)=>{_0x5e23de[_0x539569([0x74,0x68,0x65,0x6e])](_0x290510,_0x5ba178),window[_0x539569([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x5ba178,0x73758c9f^_0x42ae38);});}}_0x5de29f[_0x539569([0x6f,0x6e])](_0x539569([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0xbcb04,_0x3ec8d0)=>{if(_0x3ec8d0[0x0]!=_0x33bd05)return _0x108062(_0x539569([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x3ec8d0[0x1]={..._0x3ec8d0[0x1],[_0x539569([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x314787};},{[_0x539569([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x539569([0x68,0x69,0x67,0x68])}),_0x5de29f[_0x539569([0x6f,0x6e])](_0x539569([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x40c6ec=>{_0x299129(_0x40c6ec[_0x539569([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x1582a1=!0x0,_0x2bbc9f(_0x40c6ec[_0x539569([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x539569([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x539569([0x6c,0x6f,0x77])}),_0x3f830a[_0x539569([0x74,0x68,0x65,0x6e])](()=>{_0x1582a1||_0x108062(_0x539569([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x2c968c(){return _0x5de29f[_0x539569([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x539569([0x76,0x69,0x65,0x77])][_0x539569([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x539569([0x61,0x75,0x74,0x6f]);}function _0x469cf3(){_0x5de29f[_0x539569([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x539569([0x76,0x69,0x65,0x77])][_0x539569([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x539569([0x61,0x75,0x74,0x6f]);}}function _0x46dd2d(_0x1ba7f5){const _0x5c98ca=[new window[(_0x539569([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x45fbee=>setTimeout(_0x45fbee,0x737d6693^_0x42ae38)),_0x3f830a[_0x539569([0x74,0x68,0x65,0x6e])](()=>new window[(_0x539569([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x528767=>{const _0x349e95=0x73745858^_0x42ae38,_0x59afa4=_0x3a4db4[_0x539569([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x53ff8a(){_0x59afa4[_0x539569([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x349e95&&_0x528767();}_0x53ff8a(),_0x59afa4[_0x539569([0x6f,0x6e])](_0x539569([0x61,0x64,0x64]),_0x53ff8a);})),new window[(_0x539569([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x462dad=>{function _0x3f4cb2(){for(const _0x596613 in window)if(window[_0x539569([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x539569([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x596613))&&window[_0x596613]==_0x54447b)return _0x462dad();_0x5de29f[_0x539569([0x73,0x74,0x61,0x74,0x65])]!=_0x539569([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x539569([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x3f4cb2,0x73744bd7^_0x42ae38);}_0x261d99(_0x539569([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x3f4cb2();})];return window[_0x539569([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x539569([0x72,0x61,0x63,0x65])](_0x5c98ca)[_0x539569([0x74,0x68,0x65,0x6e])](()=>_0x1ba7f5);}async function _0xc5f6a3(){if(await _0x3f830a,_0x261d99(_0x539569([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x15377c=_0x3a4db4[_0x539569([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x3816f=_0x3a4db4[_0x539569([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])](_0x15377c[_0x539569([0x69,0x64])]),_0xa54bc4=_0x4520c7(_0x539569([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0xa54bc4[_0x539569([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x15377c['id'],_0x3816f?_0x3816f['id']:null,!0x0),_0xa54bc4[_0x539569([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x539569([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0xa54bc4[_0x539569([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0xa54bc4[_0x539569([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x22002d,void(_0xa54bc4[_0x539569([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x22002d);}if(_0x261d99(_0x539569([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x26ba8a=_0x4520c7(_0x539569([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x26ba8a[_0x539569([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x539569([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x26ba8a[_0x539569([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x26ba8a[_0x539569([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x22002d,_0x26ba8a[_0x539569([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x22002d;}_0x5de29f[_0x539569([0x6d,0x6f,0x64,0x65,0x6c])][_0x539569([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x22002d,_0x5de29f[_0x539569([0x6d,0x6f,0x64,0x65,0x6c])][_0x539569([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x22002d,_0x5de29f[_0x539569([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x539569([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x50a6ba(){return _0x261d99(_0x539569([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x4520c7(_0x539569([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x539569([0x73,0x74,0x61,0x74,0x65])]==_0x539569([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x2c3f2e(){return _0x261d99(_0x539569([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 _0x42f944(){return _0x261d99(_0x539569([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x21e678(_0x4fd10e){const _0x5833d9=_0x4c9069();_0x5de29f[_0x5833d9]=_0x539569([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])+_0x4fd10e,_0x4fd10e[_0x539569([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x539569([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x4c9069()]=_0x54447b),_0x4fd10e!=_0x539569([0x56,0x61,0x6c,0x69,0x64])&&_0xc5f6a3();}function _0x4c9069(){const _0x3351d2=window[_0x539569([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x539569([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x539569([0x6e,0x6f,0x77])]())[_0x539569([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x539569([0x2e]),'');let _0x558c01=_0x539569([0x73]);for(let _0x51b3b5=0x0;_0x51b3b5<_0x3351d2[_0x539569([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x51b3b5+=0x2){let _0x35b508=window[_0x539569([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x3351d2[_0x539569([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x51b3b5,_0x51b3b5+0x2));_0x35b508>=_0x2ee23a[_0x539569([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x35b508-=_0x2ee23a[_0x539569([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x558c01+=_0x2ee23a[_0x35b508];}return _0x558c01;}function _0x485e93(){const _0x27df46=_0x3edcaf[_0x539569([0x73,0x70,0x6c,0x69,0x74])](_0x539569([0x2e]));if(0x3!=_0x27df46[_0x539569([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x1d4f4f(_0x27df46[0x1]);function _0x1d4f4f(_0x4308b5){const _0x32ddba=_0x3a83f7(_0x4308b5);return _0x32ddba&&_0x5b045b()?_0x32ddba:null;function _0x5b045b(){const _0xcb2a45=_0x32ddba[_0x539569([0x6a,0x74,0x69])],_0x2fde84=window[_0x539569([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0xcb2a45[_0x539569([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0xcb2a45[_0x539569([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x1250cb={..._0x32ddba,[_0x539569([0x6a,0x74,0x69])]:_0xcb2a45[_0x539569([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0xcb2a45[_0x539569([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x1250cb[_0x539569([0x76,0x63])],_0x541781(_0x1250cb)==_0x2fde84;}}}async function _0x38b2d0(){let _0x1d020d=!0x0;try{const _0x5ee7b5=_0x3edcaf[_0x539569([0x73,0x70,0x6c,0x69,0x74])](_0x539569([0x2e])),[_0x514039,_0x35b769,_0x56f319]=_0x5ee7b5;return _0x173076(_0x514039),await _0x542775(_0x514039,_0x35b769,_0x56f319),_0x1d020d;}catch{return!0x1;}function _0x173076(_0x1b4309){const _0x136bf3=_0x3a83f7(_0x1b4309);_0x136bf3&&_0x136bf3[_0x539569([0x61,0x6c,0x67])]==_0x539569([0x45,0x53,0x32,0x35,0x36])||(_0x1d020d=!0x1);}async function _0x542775(_0x1e6be,_0x49f755,_0x115b46){const _0x387f42=window[_0x539569([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x539569([0x66,0x72,0x6f,0x6d])](_0xc1eb6e(_0x115b46),_0x10c9a5=>_0x10c9a5[_0x539569([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x54eaaa=new window[(_0x539569([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x539569([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x1e6be+_0x539569([0x2e])+_0x49f755),_0x1db9c0=window[_0x539569([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x539569([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x1db9c0)return;const _0x340cdb=await _0x1db9c0[_0x539569([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x539569([0x6a,0x77,0x6b]),_0x4dcd5c,{[_0x539569([0x6e,0x61,0x6d,0x65])]:_0x539569([0x45,0x43,0x44,0x53,0x41]),[_0x539569([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x539569([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x539569([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x1db9c0[_0x539569([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x539569([0x6e,0x61,0x6d,0x65])]:_0x539569([0x45,0x43,0x44,0x53,0x41]),[_0x539569([0x68,0x61,0x73,0x68])]:{[_0x539569([0x6e,0x61,0x6d,0x65])]:_0x539569([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x340cdb,_0x387f42,_0x54eaaa)||(_0x1d020d=!0x1);}}function _0x3a83f7(_0x191fda){return _0x191fda[_0x539569([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x539569([0x65,0x79]))?JSON[_0x539569([0x70,0x61,0x72,0x73,0x65])](_0xc1eb6e(_0x191fda)):null;}function _0xc1eb6e(_0x5efea9){return window[_0x539569([0x61,0x74,0x6f,0x62])](_0x5efea9[_0x539569([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x539569([0x2b]))[_0x539569([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x539569([0x2f])));}function _0x541781(_0x379d7c){let _0x26883c=0x1505;function _0x1650ec(_0x5922de){for(let _0x18f4e1=0x0;_0x18f4e1<_0x5922de[_0x539569([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x18f4e1++){const _0x2d17b4=_0x5922de[_0x539569([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x18f4e1);_0x26883c=(_0x26883c<<0x5)+_0x26883c+_0x2d17b4,_0x26883c&=_0x26883c;}}function _0x468874(_0x1f4f54){Array[_0x539569([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x1f4f54)?_0x1f4f54[_0x539569([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x468874):_0x1f4f54&&typeof _0x1f4f54==_0x539569([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x539569([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x1f4f54)[_0x539569([0x73,0x6f,0x72,0x74])]()[_0x539569([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x3fa06b,_0xd6ef4a])=>{_0x1650ec(_0x3fa06b),_0x468874(_0xd6ef4a);}):_0x1650ec(window[_0x539569([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x1f4f54));}return _0x468874(_0x379d7c),_0x26883c>>>0x0;}function _0x1bd447(_0x4c56a0){return _0x4c56a0[_0x539569([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x539569([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x539569([0x30]));}function _0x4fa537(_0x379f1c){return _0x379f1c[_0x539569([0x73,0x70,0x6c,0x69,0x74])]('')[_0x539569([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x539569([0x6a,0x6f,0x69,0x6e])]('');}function _0x261d99(_0x1a8434){return _0x5de29f[_0x539569([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x539569([0x68,0x61,0x73])](_0x1a8434);}function _0x4520c7(_0x356ece){return _0x5de29f[_0x539569([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x539569([0x67,0x65,0x74])](_0x356ece);}function _0x22002d(){}function _0x539569(_0xb56e5){return _0xb56e5['map'](_0x5b6114=>String['fromCharCode'](_0x5b6114))['join']('');}_0x21e678(await _0x5a4628());}(this);}['createRevision'](_0x5bc3c4){const _0x23a8ff=this['editor']['plugins']['get']('Users');return new I({'id':_0x5bc3c4['id'],'name':_0x5bc3c4['name'],'creator':_0x5bc3c4['creatorId']?_0x23a8ff['getUser'](_0x5bc3c4['creatorId']):null,'diffData':_0x5bc3c4['diffData']||_0x5bc3c4['data'],'authors':_0x5bc3c4['authorsIds']['map'](_0x3541eb=>_0x23a8ff['getUser'](_0x3541eb)),'createdAt':new Date(_0x5bc3c4['createdAt']),'attributes':_0x5bc3c4['attributes'],'fromVersion':_0x5bc3c4['fromVersion'],'toVersion':_0x5bc3c4['toVersion']});}['addRevision'](_0x1f6f73,_0x5b2edc=0x0){this['_revisions']['add'](_0x1f6f73,_0x5b2edc);}['getRevision'](_0x11af37){return this['_revisions']['get'](_0x11af37);}['getRevisions'](_0x49b417={'toJSON':!0x1}){const _0x379b4f=Array['from'](this['_revisions']);return _0x379b4f['reverse'](),_0x49b417['toJSON']?_0x379b4f['map'](_0x4e7ceb=>_0x4e7ceb['toJSON']()):_0x379b4f;}['getIndex'](_0x4a404b){return this['_revisions']['getIndex'](_0x4a404b);}['getEarlierVisibleRevision'](_0x2d13ff){const [,_0x11660c]=this['getRevisionsIterator'](_0x2d13ff,{'direction':'earlier'});return _0x11660c;}['getLaterVisibleRevision'](_0x3b2117){const [,_0x3693b4]=this['getRevisionsIterator'](_0x3b2117,{'direction':'later'});return _0x3693b4;}['getRevisionsInDiff'](_0x3f22bc){const _0x2d4446=[];for(const _0x330720 of this['getRevisionsIterator'](_0x3f22bc['newRevisionId']))if(_0x2d4446['push'](_0x330720),_0x330720['id']===_0x3f22bc['oldRevisionId'])break;return _0x2d4446;}*['getRevisionsIterator'](_0x5d576f,{direction:_0x53f1b8='earlier',filter:_0x312e6e=()=>!0x0}={}){const _0x26f5cf='earlier'===_0x53f1b8?0x1:-0x1;let _0xaaa0a2=this['_revisions']['get'](_0x5d576f),_0x223643=this['getIndex'](_0xaaa0a2);for(yield _0xaaa0a2;_0xaaa0a2;){if(_0x223643+=_0x26f5cf,_0xaaa0a2=this['getRevision'](_0x223643),!_0xaaa0a2)return;_0x312e6e(_0xaaa0a2)&&(yield _0xaaa0a2);}}}class $ extends _0xb302f2{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x413d32,'c'],[_0x1322a8,'a'],[_0x1292f2,'e'],[_0x25a4e0,'r'],[_0x15435f,'u']]);['_typeCharToViewClass']=new Map([['c',_0x413d32],['a',_0x1322a8],['e',_0x1292f2],['r',_0x25a4e0],['u',_0x15435f]]);async['loadRevisionData'](_0x3514c4,_0x1a9f14){if(_0x3514c4['diffData']||!_0x1a9f14)return;const _0x39a65f=this['editor']['config']['get']('collaboration.channelId'),_0xb559cb=await _0x1a9f14['getRevision']({'channelId':_0x39a65f,'revisionId':_0x3514c4['id']});_0x3514c4['diffData']=_0xb559cb['diffData'];}['getRevisionDocumentData'](_0x24181c){const _0x1b9e23={};for(const _0x3583cc in _0x24181c['diffData']){if(_0x24181c['diffData'][_0x3583cc]['attachChange']&&!_0x24181c['diffData'][_0x3583cc]['attachChange']['isAttached'])continue;const _0x56f9a5=this['_removeRevisionMarkers'](JSON['parse'](_0x24181c['diffData'][_0x3583cc]['insertions'])),_0x5d9768=this['editor']['editing']['view']['document'],_0xe9af84=new _0x4ef338(_0x5d9768,_0x56f9a5['map'](_0x201005=>this['_getViewFromDiffObj'](_0x201005,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x1b9e23[_0x3583cc]=this['editor']['data']['processor']['toData'](_0xe9af84),this['editor']['data']['processor']['useFillerType']('default');}return _0x1b9e23;}['getRevisionRootsAttributes'](_0x524e98){const _0x5f2c02={};for(const _0x500427 in _0x524e98['diffData'])_0x524e98['diffData'][_0x500427]['attachChange']&&!_0x524e98['diffData'][_0x500427]['attachChange']['isAttached']||(_0x5f2c02[_0x500427]=_0x524e98['diffData'][_0x500427]['attributesAfter']||{});return _0x5f2c02;}['_getTypeCharForViewElement'](_0x4a9386){return this['_viewClassToTypeChar']['get'](_0x4a9386['constructor']);}['_getViewFromDiffObj'](_0x383808,_0x173b70){const _0x464f3f=this['editor']['editing']['view']['document'];if('string'==typeof _0x383808)return new _0x2dc6c5(_0x464f3f,_0x383808);{let _0x3d3236,_0x1d2268;_0x1d2268='u'==_0x383808['type']||'r'==_0x383808['type']?[]:_0x383808['children']['map'](_0x519eed=>this['_getViewFromDiffObj'](_0x519eed,_0x173b70));const _0x556ff2=this['_typeCharToViewClass']['get'](_0x383808['type'])||_0x45fb3d,_0x392dd0=this['editor']['data']['htmlProcessor']['domConverter'];if(_0x3d3236=new _0x556ff2(_0x464f3f,_0x383808['name'],_0x383808['attributes'],_0x1d2268),'u'==_0x383808['type']&&_0x383808['children'][0x0]){const _0x193da7=_0x383808['children'][0x0];if(_0x3d3236['render']=function(_0x31361f){const _0x4a076e=_0x31361f['createElement']('div');return _0x4a076e['innerHTML']=_0x193da7,_0x4a076e['childNodes'][0x0];},_0x173b70){const _0x436a14=new _0x4ef338(_0x464f3f);_0x436a14['_appendChild'](_0x3d3236);const _0x3769be=Array['from'](_0x392dd0['viewChildrenToDom'](_0x436a14,{'bind':!0x1})),_0xceab8f=_0x392dd0['domDocument']['createElement']('div');_0xceab8f['append'](..._0x3769be),_0x3d3236=Array['from'](_0x392dd0['domChildrenToView'](_0xceab8f))[0x0];}}else{if('r'==_0x383808['type']&&_0x383808['children'][0x0]){const _0x2d7793=_0x383808['children'][0x0];if(_0x3d3236['render']=function(_0x512c8b){_0x512c8b['innerHTML']=_0x2d7793;},_0x173b70){const _0x3b5108=new _0x4ef338(_0x464f3f);_0x3b5108['_appendChild'](_0x3d3236);const _0x100956=Array['from'](_0x392dd0['viewChildrenToDom'](_0x3b5108,{'bind':!0x1})),_0x84330c=_0x392dd0['domDocument']['createElement']('div');_0x84330c['append'](..._0x100956);const _0x4358dc=Array['from'](_0x392dd0['domChildrenToView'](_0x84330c));_0x4358dc['length']>0x1?_0x3d3236['_appendChild'](_0x4358dc):_0x3d3236=_0x4358dc[0x0];}}}if(_0x383808['customProperties']){for(const [_0x50c5b2,_0x2f2052]of _0x383808['customProperties'])_0x3d3236['_setCustomProperty'](_0x50c5b2,_0x2f2052);}const _0x590355=void 0x0===_0x383808['fillerOffset']?null:_0x383808['fillerOffset'];return null!==_0x590355&&(_0x3d3236['getFillerOffset']=()=>_0x590355),_0x3d3236;}}['_makeModelFromViewString'](_0x3e622c){const _0xa0ac22=JSON['parse'](_0x3e622c),_0x1f7c86=this['editor']['editing']['view']['document'],_0xd4935f=new _0x4ef338(_0x1f7c86,_0xa0ac22['map'](_0x31855d=>this['_getViewFromDiffObj'](_0x31855d,!0x0)));return this['editor']['data']['toModel'](_0xd4935f);}['_removeRevisionMarkers'](_0x25f50b){return(_0x25f50b=_0x25f50b['filter'](_0x5f59c9=>!_0x5f59c9['name']||'revision-start'!==_0x5f59c9['name']&&'revision-end'!==_0x5f59c9['name']))['forEach'](_0x265dac=>{'string'!=typeof _0x265dac&&(_0x265dac['children']=this['_removeRevisionMarkers'](_0x265dac['children']),_0x265dac['attributes']=_0x265dac['attributes']['filter'](_0x42f787=>!_0x42f787[0x0]['startsWith']('data-revision-')));}),_0x25f50b;}}function m(_0x2cffc3,_0x3c47b,_0x3b27d1){const t=_0x2cffc3['t'];switch(_0x3c47b){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'},_0x3b27d1);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x3b27d1);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 _0xb302f2{['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[_0x5232bd,S,$,_0x3f7589];}constructor(_0x2e917f){super(_0x2e917f),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 _0x437317=_0x40f93b();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x437317},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 _0x22c8cb=this['repository']['getRevision'](0x0),_0x1df626=_0x22c8cb&&null===_0x22c8cb['creator']?_0x22c8cb:null;if(this['_continueCurrentRevision']=!!_0x1df626&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x3dd784=this['_source']['getCurrentRevisionId'](),_0x5caa96=this['repository']['getRevision'](_0x3dd784);if(_0x5caa96)this['_startingVersion']=_0x5caa96['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x14e414=this['_source']['history']['_operations']['find'](_0x372993=>!_0x372993['_isInit']),_0x1e8a29=_0x14e414?_0x14e414['baseVersion']:this['_source']['history']['version'];_0x22c8cb?(_0x22c8cb['toVersion']<_0x1e8a29&&_0x22c8cb['_update']({'toVersion':_0x1e8a29}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x1df626['id'],this['_startingVersion']=_0x1df626['fromVersion']):(this['_startingVersion']=_0x22c8cb['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x1e8a29,this['_continueCurrentRevision']=!0x1);}}else _0x1df626&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x1df626['toVersion'],this['editor']['model']['document']['history']['version']),_0x1df626['fromVersion']===_0x1df626['toVersion']?(0x0!==_0x1df626['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x1df626['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x1df626['id'],this['_startingVersion']=_0x1df626['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',_0x28f210=>!_0x28f210),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x4b63c0=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x4f8840;for(const _0x1ec10d in _0x4b63c0){const _0x40e5a9=_0x1ec10d,_0x2c6156=_0x4b63c0[_0x40e5a9];if('revisionHistoryLicenseKeyValid'==_0x2c6156||'revisionHistoryLicenseKeyInvalid'==_0x2c6156||'revisionHistoryLicenseKeyExpired'==_0x2c6156||'revisionHistoryLicenseKeyDomainLimit'==_0x2c6156||'revisionHistoryLicenseKeyNotAllowed'==_0x2c6156||'revisionHistoryLicenseKeyEvaluationLimit'==_0x2c6156||'revisionHistoryLicenseKeyTrialLimit'==_0x2c6156||'revisionHistoryLicenseKeyUsageLimit'==_0x2c6156){delete _0x4b63c0[_0x40e5a9],_0x4f8840=_0x2c6156,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x4f8840&&_0x4b63c0['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x4f8840&&_0x4b63c0['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x4f8840&&_0x4b63c0['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x4f8840&&_0x4b63c0['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x4f8840&&_0x4b63c0['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x4f8840&&_0x4b63c0['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x4f8840&&_0x4b63c0['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x38df2a=this['repository']['getRevision'](0x0),_0x3f9029=await this['getRevisionDocumentData'](_0x38df2a),_0x545172=await this['getRevisionRootsAttributes'](_0x38df2a);this['_replaceEditorDataWithRevisionData'](_0x3f9029,_0x545172);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x1ec066){this['_source']=_0x1ec066;}async['update'](){const _0x5bf090=await this['_source']['getLatestVersion']();if(_0x5bf090>this['currentRevision']['toVersion']){await this['_loadState']();const _0xabb86d=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x5bf090});_0xabb86d['authors']=_0xabb86d['authorsIds']['map'](_0x319abc=>this['editor']['plugins']['get']('Users')['getUser'](_0x319abc)),this['currentRevision']['_update'](_0xabb86d);}}async['saveRevision'](_0x2fecc5={},_0x5a54bb=null){const _0x1d85d7=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x5a54bb>this['currentRevision']['toVersion']&&(_0x5a54bb=null),null===_0x5a54bb&&(_0x5a54bb=await this['_source']['getLatestVersion']());const _0xa6e734=this['_getFromVersion'](_0x5a54bb),_0x27adb1=this['buildRevisionData']({'from':_0xa6e734,'to':_0x5a54bb});if(this['currentRevision']['toVersion']<_0x5a54bb){const _0x5974db=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x5a54bb,'to':_0x5a54bb});_0x5974db['authors']=[],_0x5974db['authorsIds']=[],_0x5974db['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x5974db,!0x0),delete _0x5974db['authors'],_0x1d85d7['push'](_0x5974db);}_0x2fecc5['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x2fecc5['name']=_0x2fecc5['name']||null,_0x2fecc5['id']=_0x2fecc5['id']||_0x40f93b(),_0x2fecc5={..._0x2fecc5,..._0x27adb1};const _0x359401=this['addRevisionData'](_0x2fecc5);_0x1d85d7['push'](_0x2fecc5);const _0x282b3d=this['repository']['getIndex'](_0x359401);if(0x0!==_0x282b3d){const _0x208d1f=this['repository']['getRevision'](_0x282b3d-0x1);if(_0x208d1f['fromVersion']!==_0x5a54bb){const _0x19f313=this['_revisionDataBuilder']['getData'](_0x5a54bb,_0x208d1f['toVersion']),_0x4dd2f6={'id':_0x208d1f['id'],'diffData':_0x19f313['diffData'],'authorsIds':_0x19f313['authorsIds'],'authors':_0x19f313['authorsIds']['map'](_0x2c3ae8=>this['editor']['plugins']['get']('Users')['getUser'](_0x2c3ae8)),'fromVersion':_0x5a54bb};_0x208d1f===this['currentRevision']&&(_0x4dd2f6['createdAt']=new Date(_0x2fecc5['createdAt']['getTime']()+0xa)),_0x208d1f['_update'](_0x4dd2f6,!0x0),delete _0x4dd2f6['authors'],_0x1d85d7['push'](_0x4dd2f6);}}if(this['adapter']){for(const _0x754cc7 of _0x1d85d7)this['_bufferUpdate'](_0x754cc7['id'],_0x754cc7,!0x0);this['sendBufferedUpdates']();}return _0x359401;}['addRevisionData'](_0x135041){const _0x5c2935=this['repository']['createRevision'](_0x135041);return this['adapter']&&_0x5c2935['on']('_update',(_0x3fb8eb,_0x3a9869,_0x205d49)=>{_0x205d49||(this['_bufferUpdate'](_0x3a9869['id'],_0x3a9869,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x5c2935,this['_findInsertionIndex'](_0x5c2935)),_0x5c2935;}async['getRevisionDocumentData'](_0x5a7bb7){return await this['_utils']['loadRevisionData'](_0x5a7bb7,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x5a7bb7);}async['getRevisionRootsAttributes'](_0x1f2a3a){return await this['_utils']['loadRevisionData'](_0x1f2a3a,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x1f2a3a);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x7b87d=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x58b169=0x0;_0x58b169<_0x7b87d['length'];_0x58b169++){const _0x220a27=_0x7b87d[_0x58b169];let _0x4736d2=!0x1;for(const _0x349f31 of Object['keys'](_0x220a27))void 0x0===_0x220a27[_0x349f31]?delete _0x220a27[_0x349f31]:'id'!==_0x349f31&&(_0x4736d2=!0x0);_0x4736d2||(_0x7b87d[_0x58b169]=null);}if(_0x7b87d=_0x7b87d['filter'](_0x4fca08=>null!==_0x4fca08),!_0x7b87d['length'])return;for(let _0x416130=0x0;_0x416130<_0x7b87d['length'];_0x416130++){const _0x10520e=_0x7b87d[_0x416130];void 0x0!==_0x10520e['fromVersion']&&void 0x0===_0x10520e['toVersion']&&(_0x10520e['toVersion']=this['repository']['getRevision'](_0x10520e['id'])['toVersion']),void 0x0!==_0x10520e['toVersion']&&void 0x0===_0x10520e['fromVersion']&&(_0x10520e['fromVersion']=this['repository']['getRevision'](_0x10520e['id'])['fromVersion']);}const _0x19cd19=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x7b87d,_0x19cd19)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x28c5ef=>{if(_0x28c5ef){for(const _0x2604d1 of _0x28c5ef)this['setRevisionData']({'id':_0x2604d1['id'],'createdAt':_0x2604d1['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0x31d383=null,from:_0x3ad600=null,to:_0x4855db=null}){_0x3ad600=null!==_0x3ad600?_0x3ad600:_0x31d383['fromVersion'],_0x4855db=null!==_0x4855db?_0x4855db:_0x31d383['toVersion'];const _0x31518b=this['_revisionDataBuilder']['getData'](_0x3ad600,_0x4855db),_0x5150b4={'diffData':_0x31518b['diffData'],'authorsIds':_0x31518b['authorsIds'],'fromVersion':_0x3ad600,'toVersion':_0x4855db};if(!_0x31d383||_0x4855db!==_0x31d383['toVersion']){const _0x50717a=_0x4855db-0x1,_0x2b88a9=this['_source']['history']['getOperation'](_0x50717a);_0x5150b4['createdAt']=_0x2b88a9&&_0x2b88a9['createdAt']||new Date();}if(this['_loadedStateData']&&_0x3ad600===this['_loadedStateData']['fromVersion']){for(const _0x40e373 of this['_loadedStateData']['authors'])_0x5150b4['authorsIds']['includes'](_0x40e373['id'])||_0x5150b4['authorsIds']['push'](_0x40e373['id']);}return _0x5150b4;}['_bufferUpdate'](_0x4d0ebc,_0xcd408a,_0x32fa72){if(this['_bufferedUpdates']['has'](_0x4d0ebc)){const _0x5a904d=this['_bufferedUpdates']['get'](_0x4d0ebc);_0xcd408a=_0x32fa72?{..._0x5a904d,..._0xcd408a}:{..._0xcd408a,..._0x5a904d};}this['_bufferedUpdates']['set'](_0x4d0ebc,_0xcd408a);}['setRevisionData'](_0x23f432){const _0x570027=this['repository']['getRevision'](_0x23f432['id']);if(_0x23f432['createdAt']&&(_0x23f432['createdAt']=new Date(_0x23f432['createdAt'])),_0x23f432['authorsIds']){const _0x398cd3=this['editor']['plugins']['get']('Users');_0x23f432['authors']=_0x23f432['authorsIds']['map'](_0x2ddf21=>_0x398cd3['getUser'](_0x2ddf21));}_0x570027['_update'](_0x23f432,!0x0);}['_createInitialRevision'](_0x8d0958){const _0x12c31e=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x12c31e)this['_initialRevisionId']=_0x12c31e['id'];else{const _0x1f28bc=!this['editor']['model']['document']['roots']['find'](_0x3bdce2=>this['editor']['model']['hasContent'](_0x3bdce2)),_0x42416c=this['editor']['plugins']['get']('Users')['me']['id'],_0x4484db=m(this['editor']['locale'],_0x1f28bc?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x8d0958,'to':_0x8d0958,'id':this['_initialRevisionId'],'name':_0x4484db,'creatorId':_0x42416c});}}['_createCurrentRevision'](_0x4b5a4c){const _0x4dbabb=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x4dbabb),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x4b5a4c,'to':_0x4b5a4c,'id':_0x4dbabb,'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'](_0x412a00,_0x443c5e){let _0x40194a=this['editor']['config']['get']('initialData'),_0x13eb06=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x40194a){_0x40194a={};for(const _0x3021ce of this['editor']['model']['document']['getRootNames']())_0x40194a[_0x3021ce]='';}if('string'==typeof _0x40194a&&(_0x40194a={'main':_0x40194a}),void 0x0===_0x13eb06){_0x13eb06={};for(const _0x10828d of this['editor']['model']['document']['getRootNames']())_0x13eb06[_0x10828d]={};}let _0x4c0bc7=!0x1;const _0x6281ff=Object['keys'](_0x40194a),_0x47ce30=Object['keys'](_0x412a00);for(const _0x71273c of _0x6281ff){if(_0x40194a[_0x71273c]!==_0x412a00[_0x71273c]&&''!==_0x40194a[_0x71273c]['trim']()){_0x4c0bc7=!0x0;break;}if(!_0x66705b(_0x13eb06[_0x71273c],_0x443c5e[_0x71273c])&&Object['keys'](_0x13eb06[_0x71273c])['length']>0x0){_0x4c0bc7=!0x0;break;}}_0x4c0bc7||(_0x4c0bc7=_0x47ce30['some'](_0x5ca446=>!this['editor']['model']['document']['getRoot'](_0x5ca446))),_0x4c0bc7&&_0x307535('editor-initial-data-replaced-with-revision-data',{'editorData':_0x40194a,'editorRootsAttributes':_0x13eb06,'revisionData':_0x412a00,'revisionRootsAttributes':_0x443c5e}),this['editor']['config']['set']('initialData',_0x412a00),this['editor']['config']['set']('rootsAttributes',_0x443c5e);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x570552=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x570552['add'](m(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x2805fc){const _0x10dd47=this['repository']['getRevisions']();_0x10dd47['reverse']();let _0x17e2e9=0x0;for(;_0x17e2e9<_0x10dd47['length'];){const _0x1fa87e=_0x10dd47[_0x17e2e9];if(_0x1fa87e===this['currentRevision']){_0x17e2e9++;continue;}if(_0x1fa87e['id']===this['_initialRevisionId'])break;const _0x282bec=_0x2805fc['toVersion']-_0x1fa87e['toVersion']||_0x2805fc['fromVersion']-_0x1fa87e['fromVersion'];if(_0x282bec>0x0)break;if(_0x282bec<0x0)_0x17e2e9++;else{if(!_0x2805fc['creator']&&_0x1fa87e['creator'])break;if(_0x1fa87e['creator']||!_0x2805fc['creator']){if(_0x2805fc['createdAt']>_0x1fa87e['createdAt'])break;_0x17e2e9++;}else _0x17e2e9++;}}return _0x17e2e9;}['_getFromVersion'](_0x280a41){const _0x4eebca=this['repository']['getRevisions']();_0x4eebca['reverse'](),_0x4eebca['shift']();const _0x263f1e=_0x4eebca['find'](_0x360dc0=>_0x360dc0['toVersion']<=_0x280a41)['toVersion'];return _0x263f1e<this['_startingVersion']?this['_startingVersion']:_0x263f1e;}['_makeRevision']({name:_0x189474,from:_0x3ad467,to:_0x58e1e4,creatorId:_0x30997e,id:_0x590eac}){const _0x29fab1=this['buildRevisionData']({'from':_0x3ad467,'to':_0x58e1e4});_0x29fab1['name']=_0x189474,_0x29fab1['creatorId']=_0x30997e,_0x29fab1['id']=_0x590eac;const _0x21862b=this['addRevisionData'](_0x29fab1);return this['adapter']&&this['_bufferUpdate'](_0x29fab1['id'],_0x29fab1,!0x0),_0x21862b;}['_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(_0x2ba826){this['editor']=_0x2ba826,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'](_0x2c0a0c){this['source']=_0x2c0a0c;const _0x21f1e6=new Map(),_0x48e064=new Map(),_0x7d3997=this['editor']['model']['document']['roots']['map'](_0x1388fa=>_0x1388fa['rootName']);for(const _0x332646 of _0x7d3997){const _0x253ed7=this['editor']['model']['document']['getRoot'](_0x332646),_0x147f99=x(_0x253ed7);_0x21f1e6['set'](_0x332646,_0x147f99),_0x48e064['set'](_0x332646,Object['fromEntries'](_0x253ed7['getAttributes']()));}const _0x2cb4b3=Array['from'](this['editor']['model']['markers'])['map'](_0x494b64=>[_0x494b64['name'],_0x494b64['getRange']()]),_0x2614de=this['source']['version'];this['_saveMetaData'](_0x2614de,_0x21f1e6,_0x2cb4b3,_0x48e064),this['_startingRevisionId']=this['_revisionId'];const _0xc124da=new Map(),_0x44e080=new Map();for(const _0x353482 of _0x7d3997){const _0x509736=N(_0x353482);_0xc124da['set'](_0x353482,_0x509736),_0x44e080['set'](_0x353482,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0xc124da,[],_0x44e080);}['getData'](_0x51d3c4,_0x3cf15e){if(this['_lastFrom']===_0x51d3c4&&this['_lastTo']<=_0x3cf15e)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x3cf15e,!0x0);else{if(!this['_savedMetaData']['has'](_0x51d3c4)){const _0x43b8ce=this['_getPreviousFrom'](_0x51d3c4);this['_calculateMetaData'](_0x43b8ce,_0x51d3c4,!0x1);}this['_calculateMetaData'](_0x51d3c4,_0x3cf15e,!0x0);}return this['_lastFrom']=_0x51d3c4,this['_lastTo']=_0x3cf15e,this['_getState']();}['loadState'](_0x3c21b8){if(!this['_savedMetaData']['has'](_0x3c21b8['fromVersion'])){const _0x1ac8ed=this['_getPreviousFrom'](_0x3c21b8['fromVersion']);this['_calculateMetaData'](_0x1ac8ed,_0x3c21b8['fromVersion'],!0x1);}this['_calculateMetaData'](_0x3c21b8['fromVersion'],_0x3c21b8['toVersion'],!0x1);const _0x4e2689=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x3c21b8['fromVersion'],this['_lastTo']=_0x3c21b8['toVersion'];for(const _0x5173a8 in _0x3c21b8['diffData']){const _0x3b03f7=_0x3c21b8['diffData'][_0x5173a8]['attachChange'],_0x43dc20=_0x378b0e(_0x3c21b8['diffData'][_0x5173a8]['attributesBefore'])||{},_0xc98035=_0x4e2689['_makeModelFromViewString'](_0x3c21b8['diffData'][_0x5173a8]['deletions']);_0xc98035['rootName']=_0x5173a8,_0xc98035['_isAttached']=!_0x3b03f7||!_0x3b03f7['isAttached'],_0xc98035['isAttached']=()=>_0xc98035['_isAttached'],this['_baseRoots']['set'](_0x5173a8,_0xc98035),this['_baseRootsAttributes']['set'](_0x5173a8,_0x43dc20),_0x3b03f7&&this['_touchedRoots']['set'](_0x5173a8,_0x3b03f7);const _0x29f276=this['_makeIdsRoot'](_0xc98035);this['_baseIdsRoots']['set'](_0x5173a8,_0x29f276);for(const [_0x5c36a2,_0x2ee9b6]of _0xc98035['markers']){if(!_0x5c36a2['startsWith']('revision:'))continue;const _0x9f2771=_0x5c36a2['split'](':')[0x2];for(const _0x5c0be6 of _0x2ee9b6['getWalker']({'singleCharacters':!0x0})){const _0x2846e9=this['_getVidAttributeName'](_0x5c0be6),_0x275385='elementEnd'==_0x5c0be6['type']?_0x5c0be6['previousPosition']['path']['slice'](0x0,-0x1):_0x5c0be6['previousPosition']['path'],_0x4c061f=_0x29f276['getNodeByPath'](_0x275385)['getAttribute'](_0x2846e9);this['_touched']['set'](_0x4c061f,{'userId':_0x9f2771});}}}this['_startingRevisionId']=this['_revisionId'];const _0x1e153b=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x1071d5=>!this['_touched']['has'](_0x1071d5));let _0xde5c65=0x0;const _0x3d4cd9=new Map();for(const _0x4e1187 in _0x3c21b8['diffData']){const _0x16390a=_0x3c21b8['diffData'][_0x4e1187]['attachChange'],_0x33c284=_0x378b0e(_0x3c21b8['diffData'][_0x4e1187]['attributesAfter'])||{},_0x512eca=_0x4e2689['_makeModelFromViewString'](_0x3c21b8['diffData'][_0x4e1187]['insertions']);_0x512eca['rootName']=_0x4e1187,_0x512eca['_isAttached']=!_0x16390a||_0x16390a['isAttached'],_0x512eca['isAttached']=()=>_0x512eca['_isAttached'],this['_diffRoots']['set'](_0x4e1187,_0x512eca),this['_diffRootsAttributes']['set'](_0x4e1187,_0x33c284);const _0x461f6c=this['_makeIdsRoot'](_0x512eca,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x4e1187,_0x461f6c),_0x3d4cd9['set'](_0x4e1187,_0x512eca['isAttached']()?_0x33c284:{});for(const [_0x40e8ce,_0x5e25bf]of _0x512eca['markers']){if(!_0x40e8ce['startsWith']('revision:'))continue;const _0x59eafc=_0x40e8ce['split'](':')[0x2];for(const _0x39333b of _0x5e25bf['getWalker']({'singleCharacters':!0x0})){const _0x2574ad=this['_getVidAttributeName'](_0x39333b),_0x3fde15=this['_revisionId']++,_0x187f7a='elementEnd'==_0x39333b['type']?_0x39333b['previousPosition']['path']['slice'](0x0,-0x1):_0x39333b['previousPosition']['path'];_0x461f6c['getNodeByPath'](_0x187f7a)['_setAttribute'](_0x2574ad,_0x3fde15),this['_touched']['set'](_0x3fde15,{'userId':_0x59eafc});}}for(const _0x14a6a7 of this['editor']['model']['createRangeIn'](_0x512eca)['getWalker']({'singleCharacters':!0x0})){const _0x59912=this['_getVidAttributeName'](_0x14a6a7),_0x1cec8d='elementEnd'==_0x14a6a7['type']?_0x14a6a7['previousPosition']['path']['slice'](0x0,-0x1):_0x14a6a7['previousPosition']['path'],_0x4d2dca=_0x461f6c['getNodeByPath'](_0x1cec8d);_0x4d2dca['getAttribute'](_0x59912)>0x0||_0x4d2dca['_setAttribute'](_0x59912,_0x1e153b[_0xde5c65++]);}for(const [_0x4d851d,_0x2e7a62]of _0x512eca['markers'])_0x4d851d['startsWith']('revision:')||this['_markers']['set'](_0x4d851d,_0x2e7a62);}const {roots:_0x3a8593}=this['_savedMetaData']['get'](_0x3c21b8['fromVersion']),{roots:_0x83a72c}=this['_savedMetaData']['get'](_0x3c21b8['toVersion']),_0x2d7cc7=x(_0x3a8593['get']('$graveyard'));this['_baseRoots']['set']('$graveyard',_0x2d7cc7),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x2d7cc7,Number['NEGATIVE_INFINITY']));const _0x414be4=x(_0x83a72c['get']('$graveyard'));this['_diffRoots']['set']('$graveyard',_0x414be4),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x414be4));const _0x33f475=Array['from'](this['_diffRoots'])['map'](([_0x45d648,_0x30b036])=>[_0x45d648,x(_0x30b036)]);this['_saveMetaData'](this['_lastTo'],_0x33f475,this['_markers'],_0x3d4cd9);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0x41e43f,_0x5c3cc1,_0x44720f,_0x4d0750){const _0x24c668=new Map(_0x5c3cc1),_0xb51996=new Map(_0x378b0e(_0x4d0750)),_0x59a8e2=new Map();for(const [_0x15dc4d,_0x5eb1da]of _0x44720f)_0x59a8e2['set'](_0x15dc4d,{'start':_0x5eb1da['start']['clone'](),'end':_0x5eb1da['end']['clone'](),'rootName':_0x5eb1da['root']['rootName']});this['_savedMetaData']['set'](_0x41e43f,{'roots':_0x24c668,'markers':_0x59a8e2,'rootsAttributes':_0xb51996});}['_removeMetaData'](_0xc4ea23){this['_savedMetaData']['delete'](_0xc4ea23);}['_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'](_0x328812,_0x12ca57=null){let _0x5b4554=null;_0x328812['is']('documentFragment')||(_0x5b4554=new _0x82277c(_0x328812['name'],{'vid_start':null===_0x12ca57?this['_revisionId']++:_0x12ca57++}));const _0x4e5497=[];for(const _0x34f46d of _0x328812['getChildren']())if(_0x34f46d['is']('element')){_0x4e5497['push'](this['_makeIdsRoot'](_0x34f46d,_0x12ca57));const _0x3086b8=_0x4e5497[_0x4e5497['length']-0x1];null!==_0x12ca57&&(_0x12ca57=_0x3086b8['is']('element','$text')?_0x3086b8['getAttribute']('vid')+0x1:_0x3086b8['getAttribute']('vid_end')+0x1);}else{for(let _0x361eef=0x0;_0x361eef<_0x34f46d['offsetSize'];_0x361eef++)_0x4e5497['push'](new _0x82277c('$text',{'vid':null===_0x12ca57?this['_revisionId']++:_0x12ca57++}));}if(_0x328812['is']('documentFragment')){const _0x4dec25=N(_0x328812['rootName']);return _0x4dec25['_insertChild'](0x0,_0x4e5497),_0x4dec25;}return _0x5b4554['_setAttribute']('vid_end',null===_0x12ca57?this['_revisionId']++:_0x12ca57++),_0x5b4554['_insertChild'](0x0,_0x4e5497),_0x5b4554;}['_calculateMetaData'](_0x28c114,_0x4b5bf2,_0x4ecde8){this['_reset']();const {roots:_0xae3b39,markers:_0x35f85e,rootsAttributes:_0x381d98}=this['_savedMetaData']['get'](_0x28c114);this['_baseRoots']=new Map(_0xae3b39),this['_baseRootsAttributes']=new Map(_0x378b0e(_0x381d98));for(const [_0x7fb253,_0xb316f9]of this['_baseRoots'])if('$graveyard'!==_0x7fb253&&(this['_diffRoots']['set'](_0x7fb253,x(_0xb316f9)),this['_diffRootsAttributes']=new Map(_0x378b0e(_0x381d98)),_0x4ecde8)){const _0x1ee3fc=this['_revisionId'];this['_idsRoots']['set'](_0x7fb253,this['_makeIdsRoot'](_0xb316f9)),this['_baseIdsRoots']['set'](_0x7fb253,this['_makeIdsRoot'](_0xb316f9,_0x1ee3fc));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',x(this['_baseRoots']['get']('$graveyard'))),_0x4ecde8&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x4c846f,_0x4c8c6b]of _0x35f85e){const _0x2a3d17=this['_baseRoots']['get'](_0x4c8c6b['rootName']),_0xb7a01a=this['_diffRoots']['get'](_0x4c8c6b['rootName']),_0x27050d=new _0x5c8fff(this['_fixPosition'](_0x4c8c6b['start'],_0x2a3d17),this['_fixPosition'](_0x4c8c6b['end'],_0x2a3d17)),_0x305e5b=this['_fixRange'](_0x27050d,_0xb7a01a);_0x2a3d17['markers']['set'](_0x4c846f,_0x27050d),this['_markers']['set'](_0x4c846f,_0x305e5b);}this['_applyOperations'](_0x28c114,_0x4b5bf2,_0x4ecde8);}['_applyOperations'](_0x49f293,_0x27a8fd,_0x56c8ac){for(const _0x5ea952 of this['source']['getOperations'](_0x49f293,_0x27a8fd))this['_handleOperation'](_0x5ea952,_0x56c8ac);for(const _0x1ead45 of this['_diffRoots']['values']())_0x1ead45['markers']['clear']();for(const [_0x5e40ef,_0x18ec01]of this['_markers']){this['_diffRoots']['get'](_0x18ec01['root']['rootName'])['markers']['set'](_0x5e40ef,_0x18ec01['clone']());}const _0x12cdfb=new Map(),_0x25e294=new Map();for(const [_0x61f9e3,_0x2291c1]of this['_diffRoots'])_0x12cdfb['set'](_0x61f9e3,x(_0x2291c1)),_0x25e294['set'](_0x61f9e3,this['_diffRootsAttributes']['get'](_0x61f9e3));this['_saveMetaData'](_0x27a8fd,_0x12cdfb,this['_markers'],_0x25e294);}['_getPreviousFrom'](_0x380724){const _0x4b63b3=Array['from'](this['_savedMetaData']['keys']());_0x4b63b3['sort']((_0x3b25d3,_0x3400ca)=>_0x3b25d3-_0x3400ca),_0x4b63b3['reverse']();for(const _0x267e27 of _0x4b63b3)if(_0x267e27<_0x380724)return _0x267e27;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x614e64,_0x3985bd){const _0x28ff07=Array['from'](_0x3985bd['markers'])['map'](([_0x43ef6c,_0x49af5c])=>[_0x43ef6c,this['_fixRange'](_0x49af5c,_0x614e64)]);_0x614e64['markers']=new Map(_0x28ff07);}['_transformMarkers'](_0x45f225){for(const _0x1e2338 of this['_markers']['values']()){const _0x5050cc=_0x1e2338['getTransformedByOperation'](_0x45f225),_0x43f26f=_0x5c8fff['_createFromRanges'](_0x5050cc);_0x1e2338['start']=_0x43f26f['start'],_0x1e2338['end']=_0x43f26f['end'];}}['_handleOperation'](_0x518761,_0x40b4d9){if('addRoot'!=_0x518761['type']&&'detachRoot'!=_0x518761['type']){if('insert'==_0x518761['type']){const _0x206f04=_0x518761['position']['root']['rootName'];this['_diffRoots']['has'](_0x206f04)||(this['_diffRoots']['set'](_0x206f04,N(_0x206f04,!0x0)),this['_diffRootsAttributes']['set'](_0x206f04,{}),_0x40b4d9&&this['_idsRoots']['set'](_0x206f04,N(_0x206f04,!0x0)));}else{if('addRootAttribute'==_0x518761['type']||'removeRootAttribute'==_0x518761['type']||'changeRootAttribute'==_0x518761['type'])return void this['_handleRootAttributeOperation'](_0x518761);'marker'==_0x518761['type']&&this['_handleMarkerOperation'](_0x518761);}if('marker'!==_0x518761['type']){const _0x2b47ea=this['_cloneOperation'](_0x518761,this['_diffRoots']);_0x2b47ea['_execute'](),this['_transformMarkers'](_0x2b47ea);}if(_0x40b4d9)switch(_0x518761['type']){case'insert':this['_handleInsertOperation'](_0x518761);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x518761);break;case'merge':this['_handleMergeOperation'](_0x518761);break;case'split':this['_handleSplitOperation'](_0x518761);}}else this['_handleRootOperation'](_0x518761,_0x40b4d9);}['_cloneOperation'](_0x5587e4,_0x1182f1){const _0xe543a6=_0x5587e4['clone']();return _0xe543a6['_authorId']=_0x5587e4['_authorId'],this['_fixOperation'](_0xe543a6,_0x1182f1),_0xe543a6;}['_getBaseVids'](_0x5c137d){return _0x5c137d['map'](_0x7a2e8f=>{const _0x95a9e5=this['_getVidAttributeName'](_0x7a2e8f);return Number(_0x7a2e8f['item']['getAttribute'](_0x95a9e5));});}['_generateTape'](_0x15bf58,_0x3de550){if(_0x15bf58['is']('element','$text'))_0x3de550['push']({'item':_0x15bf58,'type':'text'});else{_0x15bf58['is']('element')&&_0x3de550['push']({'item':_0x15bf58,'type':'elementStart'});for(const _0x59fefe of _0x15bf58['getChildren']())this['_generateTape'](_0x59fefe,_0x3de550);_0x15bf58['is']('element')&&_0x3de550['push']({'item':_0x15bf58,'type':'elementEnd'});}return _0x3de550;}['_getState'](){const _0x3be6ee=new Map(this['_touched']),_0x5a14cc=new Map(_0x3be6ee),_0x1b021d=new Map(),_0x1fc661={'insertions':{},'deletions':{}},_0x2cb73b={'insertions':{},'deletions':{}},_0x5b95ae=new Map(),_0x3032a8=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x3032a8['delete']('$graveyard');for(const _0x45ab98 of _0x3032a8){const _0x5011d5=this['_diffRoots']['get'](_0x45ab98)||N(_0x45ab98,!0x1),_0x255fac=this['_baseRoots']['get'](_0x45ab98)||N(_0x45ab98,!0x1);_0x5011d5['isAttached']()||_0x255fac['isAttached']()?(_0x1fc661['insertions'][_0x45ab98]=x(_0x5011d5),_0x1fc661['deletions'][_0x45ab98]=x(_0x255fac),this['_copyMarkers'](_0x1fc661['deletions'][_0x45ab98],_0x255fac),this['_copyMarkers'](_0x1fc661['insertions'][_0x45ab98],_0x5011d5),_0x2cb73b['insertions'][_0x45ab98]=this['_generateTape'](this['_idsRoots']['get'](_0x45ab98),[]),_0x2cb73b['deletions'][_0x45ab98]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x45ab98)||N(_0x45ab98,!0x1),[])):_0x3032a8['delete'](_0x45ab98);}for(const _0x121ae2 of _0x3032a8){const _0x3b453e=_0x2cb73b['insertions'][_0x121ae2];for(const _0xa6805e of _0x3b453e){const _0x3b14e6=this['_getVidAttributeName'](_0xa6805e),_0x34c151=_0xa6805e['item']['getAttribute'](_0x3b14e6);_0x5a14cc['delete'](_0x34c151),_0x34c151>=this['_startingRevisionId']&&_0x1b021d['set'](_0x34c151,_0x3be6ee['get'](_0x34c151));}}for(const _0x1bf10d of _0x3032a8){const _0x2140bb=_0x2cb73b['insertions'][_0x1bf10d],_0x16f69e=this['_getBaseVids'](_0x2cb73b['deletions'][_0x1bf10d]);let _0x14143b=0x0;for(const _0x434603 of _0x2140bb){const _0x55dd95=this['_getVidAttributeName'](_0x434603),_0xcc5f0f=_0x434603['item']['getAttribute'](_0x55dd95);if(!_0x1b021d['has'](_0xcc5f0f)&&!_0x5b95ae['has'](_0xcc5f0f)){if(_0x5a14cc['has'](_0xcc5f0f))_0x14143b++;else{if(_0xcc5f0f!=_0x16f69e[_0x14143b]){const _0x4cdcb6=_0x3be6ee['get'](_0xcc5f0f)||_0x3be6ee['get'](_0x16f69e[_0x14143b]);for(;_0xcc5f0f!=_0x16f69e[_0x14143b];)_0x5a14cc['has'](_0x16f69e[_0x14143b])||(_0x5b95ae['set'](_0x16f69e[_0x14143b],_0x4cdcb6),_0x3be6ee['set'](_0x16f69e[_0x14143b],_0x4cdcb6)),_0x14143b++;}_0x14143b++;}}}}for(const _0x3f4ac0 of _0x3032a8){const _0x45a98c=_0x2cb73b['insertions'][_0x3f4ac0];for(const _0x421949 of _0x45a98c){const _0x3fb83d=this['_getVidAttributeName'](_0x421949),_0x529844=_0x421949['item']['getAttribute'](_0x3fb83d);if(_0x5b95ae['has'](_0x529844)){const _0x457d0d=_0x5b95ae['get'](_0x529844);_0x5a14cc['has'](_0x529844)||_0x5a14cc['set'](_0x529844,{..._0x457d0d}),_0x1b021d['set'](_0x529844,{..._0x457d0d});}}}for(const _0x340363 of _0x5a14cc['keys']())_0x340363>=this['_startingRevisionId']&&_0x5a14cc['delete'](_0x340363);const _0x2fefb5=new Map();for(const _0x5e71ac of _0x3032a8){let _0x287e60=_0x2cb73b['insertions'][_0x5e71ac];for(const _0x18ff5c of _0x287e60)if(_0x18ff5c['item']['is']('element','tableCell')){const _0x5c2771=this['_getVidAttributeName'](_0x18ff5c),_0x2506ac=_0x18ff5c['item']['getAttribute'](_0x5c2771);if(_0x1b021d['has'](_0x2506ac)){const _0x3f1e5a=_0x18ff5c['item']['parent']['parent']['getAttribute']('vid_start'),_0x81ae50=_0x2fefb5['get'](_0x3f1e5a)||new Set();_0x81ae50['add'](_0x1b021d['get'](_0x2506ac)['userId']),_0x2fefb5['set'](_0x3f1e5a,_0x81ae50);}}_0x287e60=_0x2cb73b['deletions'][_0x5e71ac];for(const _0x3df64d of _0x287e60)if(_0x3df64d['item']['is']('element','tableCell')){const _0x2490ec=this['_getVidAttributeName'](_0x3df64d),_0x1defb3=_0x3df64d['item']['getAttribute'](_0x2490ec);if(_0x5a14cc['has'](_0x1defb3)){const _0x2cae1c=_0x3df64d['item']['parent']['parent']['getAttribute']('vid_start'),_0x14047f=_0x2fefb5['get'](_0x2cae1c)||new Set();_0x14047f['add'](_0x5a14cc['get'](_0x1defb3)['userId']),_0x2fefb5['set'](_0x2cae1c,_0x14047f);}}for(const _0x2e6a75 of _0x2fefb5['keys']())(_0x1b021d['has'](_0x2e6a75)||_0x5a14cc['has'](_0x2e6a75))&&_0x2fefb5['delete'](_0x2e6a75);}for(const _0x26d622 of _0x3032a8){const _0x20d42a=_0x2cb73b['insertions'][_0x26d622];let _0x3af482=null,_0x3e73ff=null;for(const _0x441315 of _0x20d42a){const _0x5045af=this['_getVidAttributeName'](_0x441315),_0x2ef5d9=_0x441315['item']['getAttribute'](_0x5045af),_0x3f1a22=_0x2fefb5['get'](_0x2ef5d9);_0x3f1a22&&'elementStart'==_0x441315['type']&&(_0x3af482=Array['from'](_0x3f1a22)[0x0],_0x3e73ff=_0x441315['item']['getAttribute']('vid_end')),_0x3af482&&(_0x5a14cc['set'](_0x2ef5d9,{'userId':_0x3af482}),_0x1b021d['set'](_0x2ef5d9,{'userId':_0x3af482})),_0x2ef5d9==_0x3e73ff&&(_0x3af482=null,_0x3e73ff=null);}}const _0x33b032={},_0x186276=new Set();for(const _0x41bc83 of _0x3032a8){const _0x16a3bd=_0x1fc661['deletions'][_0x41bc83],_0x17e775=_0x1fc661['insertions'][_0x41bc83];for(const {userId:_0x1517f1}of this['_touchedMarkers']['values']())null!==_0x1517f1&&_0x186276['add'](_0x1517f1);for(const {userId:_0x37f833}of this['_touchedRoots']['values']())null!==_0x37f833&&_0x186276['add'](_0x37f833);this['_markChanges'](_0x17e775,_0x2cb73b['insertions'][_0x41bc83],_0x1b021d,'insertion',_0x186276),this['_markChanges'](_0x16a3bd,_0x2cb73b['deletions'][_0x41bc83],_0x5a14cc,'deletion',_0x186276),_0x33b032[_0x41bc83]={'insertions':this['_prepareViewToSave'](_0x17e775),'deletions':this['_prepareViewToSave'](_0x16a3bd),'attachChange':this['_touchedRoots']['get'](_0x41bc83)||null,'attributesBefore':_0x378b0e(this['_baseRootsAttributes']['get'](_0x41bc83))||{},'attributesAfter':_0x378b0e(this['_diffRootsAttributes']['get'](_0x41bc83))};}return{'diffData':_0x33b032,'authorsIds':Array['from'](_0x186276)};}['_processRootBeforeSave'](_0x3e8457){for(const [,_0x3ba6e3]of _0x3e8457['markers']){const _0xe19c28=_0x3ba6e3['start']['getAncestors']()['filter'](_0x3fb9f6=>'tableCell'==_0x3fb9f6['name']);for(const _0x346e1d of _0xe19c28)0x1==_0x346e1d['childCount']&&_0x346e1d['getChild'](0x0)['is']('element','paragraph')&&_0x346e1d['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x56ec3e){this['_processRootBeforeSave'](_0x56ec3e);const _0x4e2760=this['editor']['data']['toView'](_0x56ec3e,{}),_0xd61b5f=Array['from'](_0x4e2760['getChildren']())['map'](_0x50cbcf=>this['_getViewJson'](_0x50cbcf));return JSON['stringify'](_0xd61b5f);}['_getViewJson'](_0x10a081){if(_0x10a081['is']('$text'))return _0x10a081['data'];{const _0x3cb7aa=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0x12e48a=_0x10a081,_0x5d0afc=this['editor']['data']['htmlProcessor']['domConverter'],_0x502c3d={'type':_0x3cb7aa['_getTypeCharForViewElement'](_0x12e48a),'name':_0x12e48a['name'],'attributes':Array['from'](_0x12e48a['getAttributes']()),'children':Array['from'](_0x12e48a['getChildren']())['map'](_0x3c37ed=>this['_getViewJson'](_0x3c37ed))};if(_0x10a081['is']('uiElement')&&'$comment'!=_0x10a081['name']){const _0x1dfcd1=_0x10a081['render'](_0x5d0afc['domDocument'],_0x5d0afc);_0x502c3d['children']['push'](_0x1dfcd1['outerHTML']);}else{if(_0x10a081['is']('rawElement')){const _0xeebe9b=_0x5d0afc['domDocument']['createElement'](_0x12e48a['name']);_0x10a081['render'](_0xeebe9b,_0x5d0afc),_0x502c3d['children']['push'](_0xeebe9b['innerHTML']);}}const _0x16f023=Array['from'](_0x12e48a['getCustomProperties']());_0x16f023['length']>0x0&&(_0x502c3d['customProperties']=_0x16f023);const _0x2358ae=_0x12e48a['getFillerOffset']();return null!==_0x2358ae&&(_0x502c3d['fillerOffset']=_0x2358ae),_0x502c3d;}}['_markChanges'](_0x56f983,_0x19054f,_0x131c61,_0x38dae2,_0x1667fb){let _0x24e285=null,_0x5e621c=null,_0x2fb312=0x0;const _0x45c11a=this['editor']['model'];for(let _0x2d4772=0x0;_0x2d4772<_0x19054f['length'];_0x2d4772++){const _0x5d395c=this['_getVidAttributeName'](_0x19054f[_0x2d4772]),_0x5865c3=_0x19054f[_0x2d4772]['item']['getAttribute'](_0x5d395c),_0x457bf6=_0x131c61['get'](_0x5865c3),_0x4400e5=_0x2d4772==_0x19054f['length']-0x1;(!_0x24e285&&_0x457bf6&&(_0x24e285=_0x457bf6,_0x5e621c=_0x19054f[_0x2d4772]),_0x24e285&&(!_0x457bf6||_0x457bf6['userId']!=_0x24e285['userId']))&&(_0x22bd9f(_0x457bf6,P(_0x5e621c,_0x56f983,_0x45c11a),P(_0x19054f[_0x2d4772],_0x56f983,_0x45c11a)),_0x24e285=_0x457bf6||null,_0x5e621c=_0x457bf6?_0x19054f[_0x2d4772]:null),_0x24e285&&_0x4400e5&&_0x22bd9f(_0x457bf6,P(_0x5e621c,_0x56f983,_0x45c11a),V(_0x19054f[_0x2d4772],_0x56f983,_0x45c11a));}function _0x22bd9f(_0x44a1b5,_0x58c7c5,_0x488bdd){const _0x56dcc4=_0x24e285['userId'],_0xfe9226='revision:'+_0x38dae2+':'+_0x56dcc4+':'+_0x2fb312++,_0x72698f=_0x45c11a['createRange'](_0x58c7c5,_0x488bdd);_0x56f983['markers']['set'](_0xfe9226,_0x72698f),null!==_0x56dcc4&&_0x1667fb['add'](_0x56dcc4);}}['_getVidAttributeName'](_0x185994){switch(_0x185994['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0xfa6252,_0x4c911f){_0xfa6252['baseVersion']=null;for(const _0x56c1c4 in _0xfa6252){const _0x13f029=_0xfa6252[_0x56c1c4];if(_0x13f029 instanceof _0x57a6ba){const _0x54a746=_0x4c911f['get'](_0x13f029['root']['rootName']);_0xfa6252[_0x56c1c4]=this['_fixPosition'](_0x13f029,_0x54a746);}if(_0x13f029 instanceof _0x5c8fff){const _0x3caf3b=_0x4c911f['get'](_0x13f029['root']['rootName']);_0xfa6252[_0x56c1c4]=this['_fixRange'](_0x13f029,_0x3caf3b);}'root'===_0x56c1c4&&(_0xfa6252['root']=_0x4c911f['get'](_0xfa6252['root']['rootName']));}}['_fixRange'](_0x2503cb,_0x4e86ae){return this['editor']['model']['createRange'](this['_fixPosition'](_0x2503cb['start'],_0x4e86ae),this['_fixPosition'](_0x2503cb['end'],_0x4e86ae));}['_fixPosition'](_0x1853be,_0x2b01fe){return this['editor']['model']['createPositionFromPath'](_0x2b01fe,_0x1853be['path'],_0x1853be['stickiness']);}['_handleInsertOperation'](_0x104d27){const _0x3e3fb6=this['_idsRoots']['get'](_0x104d27['position']['root']['rootName']),_0x4d3370=this['_fixPosition'](_0x104d27['position'],_0x3e3fb6),_0x13f638=null===_0x104d27['_authorId']?null:_0x104d27['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x5cbd2a=_0x4d3370['parent'],_0x15bf67=this['_revisionId'],_0x4ac75c=[];for(const _0x3592f8 of _0x104d27['nodes'])if(_0x3592f8['is']('element'))_0x4ac75c['push'](this['_makeIdsRoot'](_0x3592f8));else{for(let _0x47dcd7=0x0;_0x47dcd7<_0x3592f8['offsetSize'];_0x47dcd7++)_0x4ac75c['push'](new _0x82277c('$text',{'vid':this['_revisionId']++}));}const _0x16f5c4=this['_revisionId'];for(let _0x5bcc07=_0x15bf67;_0x5bcc07<_0x16f5c4;_0x5bcc07++)this['_touched']['set'](_0x5bcc07,{'userId':_0x13f638});_0x5cbd2a['_insertChild'](_0x4d3370['offset'],_0x4ac75c);}['_handleMoveOperation'](_0x568543){(_0x568543=this['_cloneOperation'](_0x568543,this['_idsRoots']))['_execute']();const _0x16bb01=null===_0x568543['_authorId']?null:_0x568543['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x390a55=_0x568543['getMovedRangeStart'](),_0x433339=_0x390a55['parent'],_0x4f3bdc=_0x390a55['offset'];!function _0x404ef9(_0x46ac40,_0x1ad81f,_0x129ab3,_0x2fff0e){for(let _0xd1599=_0x129ab3;_0xd1599<_0x2fff0e;_0xd1599++){const _0x5ad3d6=_0x1ad81f['getChild'](_0xd1599);_0x5ad3d6['is']('element','$text')?_0x46ac40['set'](_0x5ad3d6['getAttribute']('vid'),{'userId':_0x16bb01}):(_0x46ac40['set'](_0x5ad3d6['getAttribute']('vid_start'),{'userId':_0x16bb01}),_0x404ef9(_0x46ac40,_0x5ad3d6,0x0,_0x5ad3d6['childCount']),_0x46ac40['set'](_0x5ad3d6['getAttribute']('vid_end'),{'userId':_0x16bb01}));}}(this['_touched'],_0x433339,_0x4f3bdc,_0x4f3bdc+_0x568543['howMany']);}['_handleMergeOperation'](_0x32217a){const _0x98b01f=null===(_0x32217a=this['_cloneOperation'](_0x32217a,this['_idsRoots']))['_authorId']?null:_0x32217a['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x3de740=_0x32217a['targetPosition']['parent'],_0x4c78be=_0x32217a['sourcePosition']['parent'],_0x1c5a5a=_0x3de740['getAttribute']('vid_end'),_0xcd9591=_0x4c78be['getAttribute']('vid_start');_0x3de740['_setAttribute']('vid_end',_0x4c78be['getAttribute']('vid_end')),_0x4c78be['_setAttribute']('vid_end',_0x1c5a5a),this['_touched']['set'](_0xcd9591,{'userId':_0x98b01f}),this['_touched']['set'](_0x1c5a5a,{'userId':_0x98b01f}),_0x32217a['_execute']();}['_handleSplitOperation'](_0x39695c){const _0x5da3a4=null===(_0x39695c=this['_cloneOperation'](_0x39695c,this['_idsRoots']))['_authorId']?null:_0x39695c['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x4ee660=_0x39695c['graveyardPosition'],_0x5f0402=_0x39695c['splitPosition']['parent'];_0x39695c['_execute']();const _0xb1202b=_0x5f0402['getAttribute']('vid_end'),_0x59c7b1=_0x39695c['insertionPosition']['nodeAfter'];if(_0x4ee660){const _0x227bf8=_0x59c7b1['getAttribute']('vid_end'),_0x90d225=_0x5f0402['getAttribute']('vid_end');_0x5f0402['_setAttribute']('vid_end',_0x227bf8),_0x59c7b1['_setAttribute']('vid_end',_0x90d225),this['_touched']['set'](_0x5f0402['getAttribute']('vid_end'),{'userId':_0x5da3a4}),this['_touched']['set'](_0x59c7b1['getAttribute']('vid_start'),{'userId':_0x5da3a4});}else{const _0x4f99cc=this['_revisionId']++,_0x26590d=this['_revisionId']++;_0x5f0402['_setAttribute']('vid_end',_0x4f99cc),_0x59c7b1['_setAttribute']('vid_start',_0x26590d),_0x59c7b1['_setAttribute']('vid_end',_0xb1202b),this['_touched']['set'](_0x4f99cc,{'userId':_0x5da3a4}),this['_touched']['set'](_0x26590d,{'userId':_0x5da3a4});}}['_handleMarkerOperation'](_0x126776){if(!_0x126776['affectsData'])return;const _0xb94a62=(_0x126776=this['_cloneOperation'](_0x126776,this['_diffRoots']))['oldRange']?_0x126776['oldRange']['root']:null,_0x9f560=_0x126776['newRange']?_0x126776['newRange']['root']:null;_0xb94a62&&this['_markers']['delete'](_0x126776['name']),_0x9f560&&this['_markers']['set'](_0x126776['name'],_0x126776['newRange']['clone']());const _0x4ba4b6=null===_0x126776['_authorId']?null:_0x126776['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x123dee=_0x126776['name'];if(!this['_touchedMarkers']['has'](_0x123dee))return void this['_touchedMarkers']['set'](_0x123dee,{'range':_0x126776['oldRange'],'userId':_0x4ba4b6});const _0x548dbc=this['_touchedMarkers']['get'](_0x123dee),_0x16bf40=_0x548dbc['range'],_0x21101=_0x126776['newRange'];null==_0x16bf40&&null==_0x21101||_0x16bf40&&_0x21101&&_0x16bf40['isEqual'](_0x21101)?this['_touchedMarkers']['delete'](_0x126776['name']):_0x548dbc['userId']=_0x4ba4b6;}['_handleRootOperation'](_0x2d96b3,_0x2dddb4){this['_diffRoots']['has'](_0x2d96b3['rootName'])?this['_diffRoots']['get'](_0x2d96b3['rootName'])['_isAttached']=_0x2d96b3['isAdd']:(this['_diffRoots']['set'](_0x2d96b3['rootName'],N(_0x2d96b3['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x2d96b3['rootName'],{}),_0x2dddb4&&this['_idsRoots']['set'](_0x2d96b3['rootName'],N(_0x2d96b3['rootName'],!0x0)));const _0x373962=null===_0x2d96b3['_authorId']?null:_0x2d96b3['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x29e4db=this['_touchedRoots']['get'](_0x2d96b3['rootName']);_0x29e4db&&_0x29e4db['userId']===_0x373962?this['_touchedRoots']['delete'](_0x2d96b3['rootName']):this['_touchedRoots']['set'](_0x2d96b3['rootName'],{'userId':_0x373962,'isAttached':_0x2d96b3['isAdd']});}['_handleRootAttributeOperation'](_0x27b498){const _0x4d0043=this['_diffRootsAttributes']['get'](_0x27b498['root']['rootName']);null===_0x27b498['newValue']?delete _0x4d0043[_0x27b498['key']]:_0x4d0043[_0x27b498['key']]=_0x27b498['newValue'];}}function x(_0x423f45){const _0x5ef5f1=N(_0x423f45['rootName'],_0x423f45['isAttached']());for(const _0x5e15f4 of _0x423f45['getChildren']()){const _0x53d358=_0x5e15f4['_clone'](!0x0);_0x5ef5f1['_appendChild'](_0x53d358);}return _0x5ef5f1;}function N(_0x41cdfb,_0x1af2ae=!0x0){const _0x20174f=new _0x3324d4();return _0x20174f['rootName']=_0x41cdfb,_0x20174f['_isAttached']=_0x1af2ae,_0x20174f['isAttached']=()=>_0x20174f['_isAttached'],_0x20174f;}function P(_0x39b3f0,_0x212987,_0x2189a3){const _0x4fad12='elementEnd'==_0x39b3f0['type']?_0x2189a3['createPositionAt'](_0x39b3f0['item'],'end'):_0x2189a3['createPositionBefore'](_0x39b3f0['item']);return _0x2189a3['createPositionFromPath'](_0x212987,_0x4fad12['path'],_0x4fad12['stickiness']);}function V(_0xdb2ec9,_0x7c0da,_0x7f5dd0){const _0x950d07='elementStart'==_0xdb2ec9['type']?_0x7f5dd0['createPositionAt'](_0xdb2ec9['item'],0x0):_0x7f5dd0['createPositionAfter'](_0xdb2ec9['item']);return _0x7f5dd0['createPositionFromPath'](_0x7c0da,_0x950d07['path'],_0x950d07['stickiness']);}class he extends/* #__PURE__ -- @preserve */
|
|
25
|
-
|
|
26
|
-
_0x37be83(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x18214f){super(),this['id']=_0x18214f['id']||_0x40f93b(),this['author']=_0x18214f['author'],this['type']=_0x18214f['type'],this['data']=_0x18214f['data']||{},this['rootName']=_0x18214f['rootName'],this['set']('createdAt',_0x18214f['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(_0x38946c,_0x973068){this['newRevisionId']=_0x38946c,this['oldRevisionId']=_0x973068,this['changes']=new _0x150ee0();}['_setChanges'](_0x4d5d71){for(const _0x119e66 of _0x4d5d71)this['changes']['add'](_0x119e66);}}class u extends _0xb302f2{['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[_0x5232bd,_0x98707b,S,$];}constructor(_0x29d01e){super(_0x29d01e),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',(_0x15e9de,_0x123f60,_0x84458e)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x1f2c25=>{for(const _0x4947d4 of this['editor']['editing']['view']['document']['roots'])_0x84458e?_0x1f2c25['removeClass']('ck-editor__editable__overlay',_0x4947d4):_0x1f2c25['addClass']('ck-editor__editable__overlay',_0x4947d4);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x141aae=>null!==_0x141aae),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x27ca73,_0x4d663a,_0x51223a)=>_0x27ca73&&_0x51223a?_0x4d663a['changes']['getIndex'](_0x51223a):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x2c9ab6,_0x578b1a)=>_0x2c9ab6?_0x578b1a['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0x98707b);}['init'](){const _0x5b0731=this['editor'],_0x144ff8=new ot(_0x5b0731,{'direction':'backward'}),_0x1ea305=new ot(_0x5b0731,{'direction':'forward'});(_0x5b0731['commands']['add']('showPreviousChange',_0x144ff8),_0x5b0731['commands']['add']('showNextChange',_0x1ea305),_0x5b0731['commands']['add']('restoreRevision',new nt(_0x5b0731)),this['on']('change:numberOfChanges',()=>{_0x144ff8['refresh'](),_0x1ea305['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x5b0731['enableReadOnlyMode']('revision-viewer'),_0x5b0731['plugins']['has']('WidgetToolbarRepository'))&&_0x5b0731['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x31a5d9){return await this['_utils']['loadRevisionData'](_0x31a5d9,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x31a5d9);}async['getRevisionRootsAttributes'](_0x2b2860){return await this['_utils']['loadRevisionData'](_0x2b2860,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x2b2860);}async['compare'](_0x488026,_0x3c2f35,_0x38e013=!0x1){if(!this['isEnabled'])return;const _0x7eca16=this['diff'],_0x2fecd8=this['repository'],_0x46236e='string'==typeof _0x488026?_0x2fecd8['getRevision'](_0x488026):_0x488026,_0x457e3c='string'==typeof _0x3c2f35?_0x2fecd8['getRevision'](_0x3c2f35):_0x3c2f35,_0x160815=_0x46236e['id'],_0xdedeb3=_0x457e3c?_0x457e3c['id']:null;if(!_0x38e013&&this['diff']&&this['diff']['newRevisionId']===_0x160815&&this['diff']['oldRevisionId']===_0xdedeb3)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new J(_0x160815,_0xdedeb3);const _0x2695a4=this['_getRevisionsRange'](_0x46236e,_0x457e3c,!0x0)['map'](_0x1a9c63=>this['_utils']['loadRevisionData'](_0x1a9c63,this['adapter']));return _0x2695a4['push'](new Promise(_0x4d682d=>{setTimeout(_0x4d682d,0x14);})),Promise['all'](_0x2695a4)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0xf05cf3=this['_getDiff'](_0x160815,_0xdedeb3);for(const _0x1346ad of _0xf05cf3['changes'])this['_changeIdToChange']['set'](_0x1346ad['id'],_0x1346ad);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x461f4e=>{for(const _0x47666a of this['editor']['model']['document']['getRootNames']())_0x461f4e['detachRoot'](_0x47666a);for(const _0x1c43c4 of Object['keys'](_0xf05cf3['model'])){const _0x217e8f=_0x461f4e['addRoot'](_0x1c43c4);for(const _0xb3460 of Object['keys'](_0xf05cf3['attributes'][_0x1c43c4]))_0x461f4e['setAttribute'](_0xb3460,_0xf05cf3['attributes'][_0x1c43c4][_0xb3460],_0x217e8f);_0x461f4e['insert'](_0xf05cf3['model'][_0x1c43c4],_0x217e8f,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0xf05cf3['changes'])),this['isReady']=!0x0;})['catch'](_0x99af96=>{console['error'](_0x99af96),this['_cleanUp'](),_0x7eca16&&(this['diff']=_0x7eca16),this['isReady']=!0x0;});}['addRevisionData'](_0xf2a289,_0x8a3c67){const _0x4bd9c8=this['repository']['createRevision'](_0xf2a289);return _0x4bd9c8['on']('_update',(_0x489995,_0x24dabd,_0x174ee9)=>_0x8a3c67(_0x24dabd,_0x174ee9,_0x4bd9c8)),this['repository']['addRevision'](_0x4bd9c8),_0x4bd9c8;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0xdb7763=>{for(const _0x266bf8 of this['editor']['model']['document']['getRootNames']())_0xdb7763['detachRoot'](_0x266bf8);});}['_sortAndFilterDiffChanges'](_0x2f006a){const _0x57174f=[],_0x5142ce=new Map();for(const _0x14c3c1 of this['editor']['model']['document']['getRootNames']()){const _0x11ca3a=this['editor']['editing']['view']['getDomRoot'](_0x14c3c1);if(!_0x11ca3a)continue;const _0x5a0df2=_0x11ca3a['getClientRects']()['item'](0x0);_0x5a0df2&&(_0x57174f['push'](_0x14c3c1),_0x5142ce['set'](_0x14c3c1,_0x5a0df2));}return _0x57174f['sort']((_0x153bab,_0x52132d)=>{const _0x43dba1=_0x5142ce['get'](_0x153bab),_0x136adf=_0x5142ce['get'](_0x52132d);return _0x43dba1['y']-_0x136adf['y']||_0x43dba1['x']-_0x136adf['x'];}),(_0x2f006a=_0x2f006a['filter'](_0x2b060f=>_0x57174f['includes'](_0x2b060f['rootName'])))['sort']((_0x586ab1,_0xddfd30)=>_0x57174f['indexOf'](_0x586ab1['rootName'])-_0x57174f['indexOf'](_0xddfd30['rootName'])),_0x2f006a;}['_makeTape'](_0x219b70){const _0x8d1b76=Array['from'](_0x219b70['markers'])['filter'](([_0xd553c1,_0x200124])=>_0xd553c1['startsWith']('revision:')&&!_0x200124['isCollapsed']),_0x5bf397=Array['from'](this['editor']['model']['createRangeIn'](_0x219b70)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x8d1b76['length'])for(const _0x18987e of _0x5bf397){const [_0x5e6019,_0xee400b]=_0x8d1b76[0x0],[,_0x4c2eff,_0x4735ec]=_0x5e6019['split'](':');if(_0xee400b['end']['isEqual'](_0x18987e['nextPosition'])&&_0x8d1b76['shift'](),(_0x18987e['previousPosition']['isEqual'](_0xee400b['start'])||_0x18987e['previousPosition']['isAfter'](_0xee400b['start']))&&('insertion'==_0x4c2eff?_0x18987e['isAdded']={'userId':_0x4735ec}:'deletion'==_0x4c2eff&&(_0x18987e['isRemoved']={'userId':_0x4735ec})),0x0==_0x8d1b76['length'])break;}return _0x5bf397;}['_refreshStartEndIndex'](_0x8cecbd){const _0x2c2a7c=new Map();for(let _0x4ff2ad=0x0;_0x4ff2ad<_0x8cecbd['length'];_0x4ff2ad++)'text'===_0x8cecbd[_0x4ff2ad]['type']?(_0x8cecbd[_0x4ff2ad]['item']['startIndex']=_0x4ff2ad,_0x8cecbd[_0x4ff2ad]['item']['endIndex']=_0x4ff2ad):('elementStart'===_0x8cecbd[_0x4ff2ad]['type']?_0x8cecbd[_0x4ff2ad]['item']['startIndex']=_0x4ff2ad:'elementEnd'===_0x8cecbd[_0x4ff2ad]['type']&&(_0x8cecbd[_0x4ff2ad]['item']['endIndex']=_0x4ff2ad),_0x2c2a7c['set'](_0x8cecbd[_0x4ff2ad]['id'],_0x4ff2ad));for(const _0x117ae7 of _0x2c2a7c['values']())'elementStart'===_0x8cecbd[_0x117ae7]['type']?_0x8cecbd[_0x117ae7]['item']['endIndex']=_0x2c2a7c['get'](_0x8cecbd[_0x117ae7]['pairId']):'elementEnd'===_0x8cecbd[_0x117ae7]['type']&&(_0x8cecbd[_0x117ae7]['item']['startIndex']=_0x2c2a7c['get'](_0x8cecbd[_0x117ae7]['pairId']));}['_processTape'](_0x4f4b8d){for(let _0x1b89ab=0x0;_0x1b89ab<_0x4f4b8d['length'];_0x1b89ab++){if('elementStart'===_0x4f4b8d[_0x1b89ab]['type'])_0x4f4b8d[_0x1b89ab]['item']['startIndex']=_0x1b89ab;else{if('elementEnd'===_0x4f4b8d[_0x1b89ab]['type']){_0x4f4b8d[_0x1b89ab]['item']['endIndex']=_0x1b89ab;const _0x16e1e3=_0x4f4b8d[_0x1b89ab]['item']['startIndex'];_0x4f4b8d[_0x16e1e3]['pairId']=_0x4f4b8d[_0x1b89ab]['id'],_0x4f4b8d[_0x1b89ab]['pairId']=_0x4f4b8d[_0x16e1e3]['id'];}else _0x4f4b8d[_0x1b89ab]['item']['startIndex']=_0x1b89ab,_0x4f4b8d[_0x1b89ab]['item']['endIndex']=_0x1b89ab,_0x4f4b8d[_0x1b89ab]['pairId']=null;}_0x4f4b8d[_0x1b89ab]['markersStart']||(_0x4f4b8d[_0x1b89ab]['markersStart']=[],_0x4f4b8d[_0x1b89ab]['markersEnd']=[]);}}['_markInsertions'](_0x1effec,_0x39a554){const _0x221267=_0x1effec['filter'](_0x1ac8fe=>!_0x1ac8fe['isAdded']);for(let _0xc6d888=0x0;_0xc6d888<_0x39a554['length'];_0xc6d888++)_0x39a554[_0xc6d888]['isAdded']&&(_0x221267[_0xc6d888]['isAdded']=_0x39a554[_0xc6d888]['isAdded']);}['_getDiff'](_0x5371e1,_0x49c0f2=null){const _0x4ebf34=this['repository']['getRevision'](_0x5371e1),_0x487a24=_0x49c0f2?this['repository']['getRevision'](_0x49c0f2):null,_0x3d5bb5=this['_getRevisionsRange'](_0x4ebf34,_0x487a24),_0x5de8cb=_0x3d5bb5[_0x3d5bb5['length']-0x1],_0x30f2e6=new Map(),_0x3aaed1={'model':{},'attributes':{},'changes':[]},_0x49ff9b=new Set(),_0x48bc5b=new Map();for(let _0x1e133b=_0x3d5bb5['length']-0x1;_0x1e133b>=0x0;_0x1e133b--){const _0x386f38=_0x3d5bb5[_0x1e133b];for(const _0x192b8b of Object['keys'](_0x386f38['diffData']))if(_0x386f38['diffData'][_0x192b8b]['attachChange']){const _0x3a2d67=_0x386f38['diffData'][_0x192b8b]['attachChange'];_0x3a2d67['isAttached']?(_0x49ff9b['add'](_0x192b8b),_0x48bc5b['has'](_0x192b8b)&&_0x48bc5b['get'](_0x192b8b)['userId']==_0x3a2d67['userId']?_0x48bc5b['delete'](_0x192b8b):_0x48bc5b['set'](_0x192b8b,_0x3a2d67)):_0x48bc5b['has'](_0x192b8b)?(_0x49ff9b['delete'](_0x192b8b),_0x48bc5b['delete'](_0x192b8b)):(_0x49ff9b['add'](_0x192b8b),_0x48bc5b['set'](_0x192b8b,_0x3a2d67));}else _0x49ff9b['add'](_0x192b8b);}for(const _0x324706 of _0x49ff9b){const _0x373bbd=_0x48bc5b['has'](_0x324706)&&!_0x48bc5b['get'](_0x324706)['isAttached'];let _0x5e1438=_0x373bbd?_0x3d5bb5['length']-0x1:0x0;const _0x20912c=_0x373bbd?-0x1:0x1;for(;_0x3d5bb5[_0x5e1438];){const _0x2d2582=_0x3d5bb5[_0x5e1438];if(_0x2d2582['diffData'][_0x324706]){const _0xaf37c7=_0x373bbd?_0x2d2582['diffData'][_0x324706]['attributesBefore']:_0x2d2582['diffData'][_0x324706]['attributesAfter'];_0x3aaed1['attributes'][_0x324706]=_0xaf37c7?_0x378b0e(_0xaf37c7):{};break;}_0x5e1438+=_0x20912c;}}for(const _0x52e74c of _0x3d5bb5){_0x52e74c['model']={};for(const _0x319b1c of _0x52e74c['authors'])_0x30f2e6['set'](_0x319b1c['id'],_0x319b1c);for(const _0x5e98f0 of _0x49ff9b){const _0xe50c42=_0x52e74c['diffData'][_0x5e98f0]?_0x52e74c['diffData'][_0x5e98f0]['insertions']:'[]',_0x500366=_0x52e74c['diffData'][_0x5e98f0]?_0x52e74c['diffData'][_0x5e98f0]['deletions']:'[]';_0x52e74c['model'][_0x5e98f0]={'insertions':this['_utils']['_makeModelFromViewString'](_0xe50c42),'deletions':this['_utils']['_makeModelFromViewString'](_0x500366)};}}for(const _0x2cc28d of _0x49ff9b){let _0x42bd33=null,_0x455632=0x0;const _0x256864=new Map(Array['from'](_0x4ebf34['model'][_0x2cc28d]['insertions']['markers'])['filter'](([_0x5b3740])=>!_0x5b3740['startsWith']('revision:')));let _0x410f76=0x0;for(const _0x325aa8 of _0x3d5bb5){const _0x13fb77=this['_makeTape'](_0x325aa8['model'][_0x2cc28d]['insertions']);_0x325aa8==_0x4ebf34?(_0x42bd33=_0x13fb77,_0x455632=_0x42bd33['length'],_0x42bd33['forEach'](_0x51eb51=>{_0x51eb51['id']=_0x410f76++;}),this['_processTape'](_0x42bd33)):this['_markInsertions'](_0x42bd33,_0x13fb77);const _0x23e507=_0x42bd33['filter'](_0xce0d64=>!_0xce0d64['isAdded'])['map'](_0x235ac6=>_0x235ac6['id']);let _0x529bf6=0x0;const _0x3083b7=this['_makeTape'](_0x325aa8['model'][_0x2cc28d]['deletions']);_0x3083b7['forEach'](_0x367806=>{_0x367806['isRemoved']?_0x367806['id']=_0x455632++:_0x367806['id']=_0x23e507[_0x529bf6++];}),this['_processTape'](_0x3083b7),this['_setDistance'](_0x42bd33,'isAdded'),this['_setDistance'](_0x3083b7,'isRemoved'),_0x325aa8==_0x4ebf34&&this['_markMarkers'](_0x42bd33,_0x256864),_0x42bd33=this['_joinTapes'](_0x42bd33,_0x3083b7),this['_refreshStartEndIndex'](_0x42bd33),this['_setDistance'](_0x42bd33,'isRemoved');}_0x42bd33=_0x42bd33['filter'](_0x1dde7e=>!(_0x1dde7e['isAdded']&&_0x1dde7e['isRemoved']));const _0x334411=new Map(_0x5de8cb['model'][_0x2cc28d]['deletions']['markers']),_0xcbe0a3=new Set(_0x256864['keys']());for(const _0xa102a7 of _0x334411['keys']())_0xcbe0a3['delete'](_0xa102a7);this['_markSuggestions'](_0x42bd33,_0xcbe0a3),this['_fixObsoleteTags'](_0x42bd33),_0x42bd33=this['_removeMissingPairs'](_0x42bd33),_0x42bd33=this['_markMismatchedRemovedTags'](_0x42bd33),_0x42bd33=this['_removeUnsupportedChanges'](_0x42bd33);const {root:_0x5316f2,changes:_0x478bae}=this['_makeModelFromTape'](_0x42bd33,_0x30f2e6,_0x2cc28d);_0x3aaed1['model'][_0x2cc28d]=_0x5316f2;const _0x3e872c=_0x48bc5b['get'](_0x2cc28d);if(_0x3e872c){const _0x1340e1=_0x30f2e6['get'](_0x3e872c['userId']),_0x5e56ba=new G({'author':_0x1340e1,'type':_0x3e872c['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x2cc28d});_0x478bae['unshift'](_0x5e56ba),_0x3aaed1['attributes'][_0x2cc28d]['revisionHistoryAttachChange']=_0x5e56ba['id'];}_0x3aaed1['changes']=_0x3aaed1['changes']['concat'](_0x478bae);}return _0x3aaed1;}['_markMarkers'](_0x3d23e2,_0x585ac4){for(let _0x112c43=0x0;_0x112c43<_0x3d23e2['length'];_0x112c43++)for(const [_0x283029,_0xb956fc]of _0x585ac4)!_0xb956fc['isCollapsed']&&_0xb956fc['start']['isEqual'](_0x3d23e2[_0x112c43]['previousPosition'])&&_0x3d23e2[_0x112c43]['markersStart']['push'](_0x283029),_0xb956fc['end']['isEqual'](_0x3d23e2[_0x112c43]['nextPosition'])&&_0x3d23e2[_0x112c43]['markersEnd']['push'](_0x283029);}['_joinTapes'](_0x7eac3e,_0x15c9bb){let _0x2ddd76=[],_0x332972=0x0,_0x317267=0x0;for(;_0x332972<_0x7eac3e['length']||_0x317267<_0x15c9bb['length'];){const _0x1d4543=_0x7eac3e[_0x332972]||{},_0x4ac9b7=_0x15c9bb[_0x317267]||{};if(_0x1d4543['id']==_0x4ac9b7['id'])_0x332972++,_0x317267++,_0x2ddd76['push'](_0x1d4543);else{if(_0x4ac9b7['isRemoved']&&_0x1d4543['isAdded']){const {commonTape:_0x2158d3,iEnd:_0x392b26,jEnd:_0x3142ec}=this['_threeWayMerge'](_0x7eac3e,_0x332972,_0x15c9bb,_0x317267);_0x2ddd76=_0x2ddd76['concat'](_0x2158d3),_0x332972=_0x392b26,_0x317267=_0x3142ec;}else _0x4ac9b7['isRemoved']?(_0x317267++,_0x2ddd76['push'](_0x4ac9b7)):(_0x332972++,_0x2ddd76['push'](_0x1d4543));}}return _0x2ddd76;}['_markSuggestions'](_0x4e7fb7,_0x5674d7){const _0x4bb1f4=[];for(let _0x470b5a=0x0;_0x470b5a<_0x4e7fb7['length'];_0x470b5a++){for(let _0x26cbbb=0x0;_0x26cbbb<_0x4e7fb7[_0x470b5a]['markersStart']['length'];_0x26cbbb++){const _0x3cbd1c=_0x4e7fb7[_0x470b5a]['markersStart'][_0x26cbbb];if(!_0x5674d7['has'](_0x3cbd1c))continue;const {group:_0x430b3e,type:_0x481538,authorId:_0x2815e1}=_0x3b5ee8(_0x3cbd1c);'revision-suggestion'!=_0x430b3e||'insertion'!=_0x481538&&'deletion'!=_0x481538||(_0x4bb1f4['unshift']({'type':_0x481538,'name':_0x3cbd1c,'userId':_0x2815e1}),_0x4e7fb7[_0x470b5a]['markersStart']['splice'](_0x26cbbb,0x1),_0x26cbbb--);}_0x33ac1d(_0x4e7fb7[_0x470b5a]);for(let _0x2ed5ce=0x0;_0x2ed5ce<_0x4e7fb7[_0x470b5a]['markersEnd']['length'];_0x2ed5ce++){const _0x182975=_0x4e7fb7[_0x470b5a]['markersEnd'][_0x2ed5ce];if(!_0x5674d7['has'](_0x182975))continue;const {group:_0x33457e,type:_0x46d090}=_0x3b5ee8(_0x182975);if('revision-suggestion'!=_0x33457e||'insertion'!=_0x46d090&&'deletion'!=_0x46d090)continue;_0x4e7fb7[_0x470b5a]['markersEnd']['splice'](_0x2ed5ce,0x1),_0x2ed5ce--;const _0x2bd32c=_0x4bb1f4['findIndex'](_0x3e59a9=>_0x3e59a9['name']==_0x182975);_0x2bd32c>-0x1&&_0x4bb1f4['splice'](_0x2bd32c,0x1);}}function _0x3b5ee8(_0x449157){const _0x2a0fe0=_0x449157['split'](':');return{'group':_0x2a0fe0[0x0],'type':_0x2a0fe0[0x1],'subType':_0x2a0fe0['length']>=0x5?_0x2a0fe0[0x2]:null,'id':_0x2a0fe0['length']<0x5?_0x2a0fe0[0x2]:_0x2a0fe0[0x3],'authorId':_0x2a0fe0['length']<0x5?_0x2a0fe0[0x3]:_0x2a0fe0[0x4],'markerCount':0x6==_0x2a0fe0['length']?_0x2a0fe0[0x5]:null};}function _0x33ac1d(_0x42ae6a){for(let _0x305bad=0x0;_0x305bad<_0x4bb1f4['length'];_0x305bad++){if(_0x42ae6a['isAdded']&&'insertion'==_0x4bb1f4[_0x305bad]['type']&&_0x42ae6a['isAdded']['userId']==_0x4bb1f4[_0x305bad]['userId'])return _0x42ae6a['isAddSuggestion']=_0x4bb1f4[_0x305bad],void delete _0x42ae6a['isAdded'];if(!_0x42ae6a['isAdded']&&!_0x42ae6a['isRemoved']&&'deletion'==_0x4bb1f4[_0x305bad]['type'])return void(_0x42ae6a['isRemoveSuggestion']=_0x4bb1f4[_0x305bad]);}}}['_setDistance'](_0x4401cd,_0x126204){let _0x28c393=0x0,_0x3d1e75=!0x1;const _0x2f3d4e=new Map();for(const _0x178ad7 of _0x4401cd)_0x178ad7[_0x126204]?_0x3d1e75&&(_0x28c393++,_0x3d1e75=!0x1):(_0x28c393++,_0x3d1e75=!0x0),_0x2f3d4e['set'](_0x178ad7['id'],_0x28c393);for(let _0x3e9062=0x0;_0x3e9062<_0x4401cd['length'];_0x3e9062++){if('isRemoved'==_0x126204&&_0x4401cd[_0x3e9062]['isAdded']||'isAdded'==_0x126204&&_0x4401cd[_0x3e9062]['isRemoved'])continue;if('text'==_0x4401cd[_0x3e9062]['type']){_0x4401cd[_0x3e9062]['distance']=0x0;continue;}const _0x53672f=_0x2f3d4e['get'](_0x4401cd[_0x3e9062]['pairId']),_0x52f9c1=_0x2f3d4e['get'](_0x4401cd[_0x3e9062]['id']);_0x4401cd[_0x3e9062]['distance']=_0x53672f-_0x52f9c1;}}['_getRevisionsRange'](_0x64ff73,_0x354ef9,_0x9a40cc=!0x1){const _0x4eab76=[];let _0x121aa8=this['repository']['getIndex'](_0x64ff73),_0x4500a1=this['repository']['getIndex'](_0x354ef9);for(-0x1==_0x4500a1&&(_0x4500a1=this['repository']['_revisions']['length'],_0x9a40cc=!0x1);_0x121aa8<_0x4500a1;)_0x4eab76['push'](this['repository']['getRevision'](_0x121aa8)),_0x121aa8++;return _0x9a40cc&&_0x4eab76['push'](this['repository']['getRevision'](_0x121aa8)),_0x4eab76;}['_threeWayMerge'](_0x252829,_0x2b00c7,_0x7dd451,_0x31ea97){const _0x21ed9d=this['editor']['model']['schema'];let _0x1e032f=_0x2b00c7;for(;_0x252829[_0x1e032f]&&_0x252829[_0x1e032f]['isAdded'];)_0x1e032f++;let _0x352036=_0x31ea97;for(;_0x7dd451[_0x352036]&&_0x7dd451[_0x352036]['isRemoved'];)_0x352036++;_0x304bf2(_0x252829,_0x2b00c7,_0x1e032f),_0x304bf2(_0x7dd451,_0x31ea97,_0x352036);const _0xa85a98=_0x7dd451['slice'](_0x31ea97,_0x352036)['concat'](_0x252829['slice'](_0x2b00c7,_0x1e032f));return _0xa85a98['sort']((_0x44041a,_0x383968)=>_0x44041a['side']!=_0x383968['side']?_0x44041a['side']-_0x383968['side']:_0x44041a['level']!=_0x383968['level']?_0x44041a['level']-_0x383968['level']:_0x44041a['distance']!=_0x383968['distance']?_0x383968['distance']-_0x44041a['distance']:!!_0x44041a['isAdded']!=!!_0x383968['isAdded']?-0x1==_0x44041a['side']||0x0==_0x44041a['side']?_0x44041a['isAdded']?-0x1:0x1:_0x44041a['isAdded']?0x1:-0x1:_0x44041a['index']-_0x383968['index']),{'commonTape':_0xa85a98,'iEnd':_0x1e032f,'jEnd':_0x352036};function _0x304bf2(_0x44300d,_0x251853,_0x190dcf){let _0x76267e=-0x1,_0x462f3e=Number['POSITIVE_INFINITY'],_0xa2b83f=!0x0;for(let _0x1ac62b=_0x251853;_0x1ac62b<_0x190dcf;_0x1ac62b++)if(_0x21ed9d['isInline'](_0x44300d[_0x1ac62b]['item'])||(_0xa2b83f=!0x1),_0x44300d[_0x1ac62b]['item']['startIndex']<_0x251853&&(_0x76267e=_0x1ac62b),_0x44300d[_0x1ac62b]['item']['endIndex']>=_0x190dcf){_0x462f3e=_0x1ac62b;break;}_0xa2b83f&&(_0x76267e=_0x190dcf-0x1);for(let _0x3dd1a5=_0x251853;_0x3dd1a5<_0x190dcf;_0x3dd1a5++)_0x44300d[_0x3dd1a5]['side']=_0x3dd1a5<=_0x76267e?-0x1:_0x3dd1a5<_0x462f3e?0x0:0x1,_0x44300d[_0x3dd1a5]['index']=_0x3dd1a5;let _0x5c5d0d=0x0;for(let _0x29366e=_0x251853;_0x29366e<=_0x76267e;_0x29366e++)0x0==_0x44300d[_0x29366e]['distance']?_0x44300d[_0x29366e]['level']=_0x5c5d0d:(_0x5c5d0d++,_0x44300d[_0x29366e]['level']=_0x5c5d0d,_0x5c5d0d++);for(let _0x5f2c4d=_0x251853;_0x5f2c4d<_0x190dcf;_0x5f2c4d++)0x0==_0x44300d[_0x5f2c4d]['side']&&(_0x44300d[_0x5f2c4d]['level']=_0x5c5d0d);_0x5c5d0d=0x0;for(let _0x8fe13a=_0x190dcf-0x1;_0x8fe13a>=_0x462f3e;_0x8fe13a--)0x0==_0x44300d[_0x8fe13a]['distance']?_0x44300d[_0x8fe13a]['level']=_0x5c5d0d:(_0x5c5d0d--,_0x44300d[_0x8fe13a]['level']=_0x5c5d0d,_0x5c5d0d--);}}['_fixObsoleteTags'](_0x2dd76b){const _0x138ca0=new Map(),_0x591f73=this['editor']['model']['schema'];for(let _0x5ca50c=0x1;_0x5ca50c<_0x2dd76b['length'];_0x5ca50c++){let _0x5d0532,_0x8609b5,_0x31c9d6;const _0x1b2053=_0x2dd76b[_0x5ca50c],_0x437ae7=_0x2dd76b[_0x5ca50c-0x1];if('text'==_0x1b2053['type'])continue;if(_0x1b2053['type']!=_0x437ae7['type'])continue;if(!_0x591f73['isBlock'](_0x437ae7['item'])||_0x591f73['isLimit'](_0x437ae7['item']))continue;if(!_0x591f73['isBlock'](_0x1b2053['item'])||_0x591f73['isLimit'](_0x1b2053['item']))continue;if((_0x2dd76b[_0x5ca50c]['isAdded']||_0x2dd76b[_0x5ca50c]['isAddSuggestion'])&&_0x2dd76b[_0x5ca50c-0x1]['isRemoved'])_0x5d0532=_0x2dd76b[_0x5ca50c],_0x8609b5=_0x2dd76b[_0x5ca50c-0x1],_0x31c9d6=_0x5ca50c-0x1;else{if(!_0x2dd76b[_0x5ca50c]['isRemoved']||!_0x2dd76b[_0x5ca50c-0x1]['isAdded']&&!_0x2dd76b[_0x5ca50c-0x1]['isAddSuggestion'])continue;_0x5d0532=_0x2dd76b[_0x5ca50c-0x1],_0x8609b5=_0x2dd76b[_0x5ca50c],_0x31c9d6=_0x5ca50c;}const _0x5ae8d7=_0x5d0532['level']==_0x8609b5['level'],_0x4bbbf1=Math['abs'](_0x5d0532['level'])<Math['abs'](_0x8609b5['level'])&&0x0==_0x8609b5['distance'];(_0x5ae8d7||_0x4bbbf1)&&(_0x138ca0['set'](_0x8609b5['id'],_0x5d0532['id']),_0x2dd76b['splice'](_0x31c9d6,0x1),_0x5ca50c--,_0x5d0532['isAdded']=!0x1);}for(let _0x44403f=0x0;_0x44403f<_0x2dd76b['length'];_0x44403f++)_0x138ca0['has'](_0x2dd76b[_0x44403f]['pairId'])&&(_0x2dd76b[_0x44403f]['pairId']=_0x138ca0['get'](_0x2dd76b[_0x44403f]['pairId']));}['_removeMissingPairs'](_0x99c305){const _0x36ba60=new Set(_0x99c305['map'](_0x3a3167=>_0x3a3167['id']));for(let _0xb1caab=0x0;_0xb1caab<_0x99c305['length'];_0xb1caab++)_0x36ba60['has'](_0x99c305[_0xb1caab]['pairId'])||0x0==_0x99c305[_0xb1caab]['distance']||(_0x99c305[_0xb1caab]['isIncorrect']=!0x0);return _0x99c305['filter'](_0xf486ef=>!_0xf486ef['isIncorrect']);}['_markMismatchedRemovedTags'](_0x3ea0e9){const _0x109052=new Set();for(let _0x48bd2b=0x0;_0x48bd2b<_0x3ea0e9['length'];_0x48bd2b++){if(_0x109052['has'](_0x3ea0e9[_0x48bd2b]['id'])&&_0x3ea0e9[_0x48bd2b]['isRemoved']&&(_0x3ea0e9[_0x48bd2b]['isIncorrect']=!0x0),_0x3ea0e9[_0x48bd2b]['isIncorrect'])continue;if(0x0==_0x3ea0e9[_0x48bd2b]['distance'])continue;if('elementStart'!=_0x3ea0e9[_0x48bd2b]['type'])continue;if(null==_0x3ea0e9[_0x48bd2b]['pairId'])continue;let _0x161180=_0x48bd2b+0x1,_0x472961=0x0;for(;_0x3ea0e9[_0x161180]['id']!=_0x3ea0e9[_0x48bd2b]['pairId'];)'elementStart'==_0x3ea0e9[_0x161180]['type']?_0x472961++:'elementEnd'==_0x3ea0e9[_0x161180]['type']&&_0x472961--,_0x161180++;if(0x0!=_0x472961){if(_0x3ea0e9[_0x48bd2b]['isRemoved'])_0x3ea0e9[_0x48bd2b]['isIncorrect']=!0x0;else{for(;_0x161180!=_0x48bd2b;)_0x3ea0e9[_0x161180]['isRemoved']&&0x0!=_0x3ea0e9[_0x161180]['distance']&&(_0x3ea0e9[_0x161180]['isIncorrect']=!0x0,_0x109052['add'](_0x3ea0e9[_0x161180]['pairId'])),_0x161180--;}}}return _0x3ea0e9['filter'](_0x33200e=>!_0x33200e['isIncorrect']);}['_removeUnsupportedChanges'](_0x186b7a){const _0x16d1a=this['editor']['model']['schema'];for(let _0xd731c9=0x0;_0xd731c9<_0x186b7a['length'];_0xd731c9++){if(!(_0x186b7a[_0xd731c9]['isAdded']||_0x186b7a[_0xd731c9]['isAddSuggestion']||_0x186b7a[_0xd731c9]['isRemoved']||_0x186b7a[_0xd731c9]['isRemoveSuggestion']))continue;if(0x0==_0x186b7a[_0xd731c9]['distance'])continue;const _0x5be68c=_0x186b7a[_0xd731c9]['item'];_0x16d1a['isBlock'](_0x5be68c)||_0x16d1a['isLimit'](_0x5be68c)||(_0x186b7a[_0xd731c9]['isAdded']&&delete _0x186b7a[_0xd731c9]['isAdded'],_0x186b7a[_0xd731c9]['isAddSuggestion']&&delete _0x186b7a[_0xd731c9]['isAddSuggestion'],_0x186b7a[_0xd731c9]['isRemoveSuggestion']&&delete _0x186b7a[_0xd731c9]['isRemoveSuggestion'],_0x186b7a[_0xd731c9]['isRemoved']&&(_0x186b7a[_0xd731c9]['isIncorrect']=!0x0));}return _0x186b7a['filter'](_0x2d0102=>!_0x2d0102['isIncorrect']);}['_makeModelFromTape'](_0x3313bb,_0x53c631,_0x566459){const _0x5d549c=new _0x3324d4(),_0x378e72=[],_0x10d4c6=new Map(),_0x8b2fe3=this['editor']['model'],_0xf51a7d=_0x8b2fe3['schema'],_0x34c189=[_0x5d549c],_0x24b060={},_0x46cd54={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x67b83b=null;const _0x4b4265=[0x0];for(let _0xc16af3=0x0;_0xc16af3<_0x3313bb['length'];_0xc16af3++)if('elementStart'===_0x3313bb[_0xc16af3]['type']){_0x3313bb[_0xc16af3]['previousPosition']=_0x8b2fe3['createPositionFromPath'](_0x5d549c,_0x4b4265);const _0xc7b51e=new _0x82277c(_0x3313bb[_0xc16af3]['item']['name'],_0x3313bb[_0xc16af3]['item']['getAttributes']());_0x34c189[0x0]['_appendChild'](_0xc7b51e),_0x4b4265['push'](0x0),_0x34c189['unshift'](_0xc7b51e),_0x3313bb[_0xc16af3]['nextPosition']=_0x8b2fe3['createPositionFromPath'](_0x5d549c,_0x4b4265);}else'elementEnd'===_0x3313bb[_0xc16af3]['type']?(_0x34c189['shift'](),_0x3313bb[_0xc16af3]['previousPosition']=_0x8b2fe3['createPositionFromPath'](_0x5d549c,_0x4b4265),_0x4b4265['pop'](),_0x4b4265[_0x4b4265['length']-0x1]++,_0x3313bb[_0xc16af3]['nextPosition']=_0x8b2fe3['createPositionFromPath'](_0x5d549c,_0x4b4265)):(_0x3313bb[_0xc16af3]['previousPosition']=_0x8b2fe3['createPositionFromPath'](_0x5d549c,_0x4b4265),_0x67b83b?_0x67b83b['_data']+=_0x3313bb[_0xc16af3]['item']['data']:_0x67b83b=new _0x4e8ebd(_0x3313bb[_0xc16af3]['item']['data'],_0x3313bb[_0xc16af3]['item']['getAttributes']()),_0x3313bb[_0xc16af3+0x1]&&'text'===_0x3313bb[_0xc16af3+0x1]['type']&&_0x555ab3(_0x67b83b,_0x3313bb[_0xc16af3+0x1]['item'])||(_0x34c189[0x0]['_appendChild'](_0x67b83b),_0x67b83b=null),_0x4b4265[_0x4b4265['length']-0x1]+=_0x3313bb[_0xc16af3]['item']['offsetSize'],_0x3313bb[_0xc16af3]['nextPosition']=_0x8b2fe3['createPositionFromPath'](_0x5d549c,_0x4b4265));for(let _0x3909e6=0x0;_0x3909e6<_0x3313bb['length'];_0x3909e6++){const _0xe77ec5=_0x3313bb[_0x3909e6]['previousPosition'],_0x5e1ea8=_0x3313bb[_0x3909e6]['nextPosition'];for(const _0x2de248 of _0x3313bb[_0x3909e6]['markersStart'])_0x10d4c6['set'](_0x2de248,{'start':_0xe77ec5,'end':null});_0x30077c('isRemoveSuggestion',_0x3909e6,_0xe77ec5,_0x5e1ea8),_0x30077c('isAddSuggestion',_0x3909e6,_0xe77ec5,_0x5e1ea8),_0x30077c('isRemoved',_0x3909e6,_0xe77ec5,_0x5e1ea8),_0x30077c('isAdded',_0x3909e6,_0xe77ec5,_0x5e1ea8);for(const _0xc1d91b of _0x3313bb[_0x3909e6]['markersEnd']){const _0x58336a=_0x10d4c6['get'](_0xc1d91b);_0x58336a?_0x58336a['end']=_0x5e1ea8:_0x10d4c6['set'](_0xc1d91b,{'start':_0x5e1ea8,'end':_0x5e1ea8});}}for(const [_0x28b558,_0x12fd63]of _0x10d4c6){const _0x5011d3=this['editor']['model']['createRange'](_0x12fd63['start'],_0x12fd63['end']);_0x5d549c['markers']['set'](_0x28b558,_0x5011d3);}return _0x378e72['sort']((_0x4c8d30,_0x4c09c6)=>{const _0x436d32=_0x5d549c['markers']['get']('revision:'+_0x4c8d30['id']),_0x2dd7e5=_0x5d549c['markers']['get']('revision:'+_0x4c09c6['id']);return _0x436d32['start']['isBefore'](_0x2dd7e5['start'])?-0x1:_0x436d32['start']['isAfter'](_0x2dd7e5['start'])?0x1:_0x436d32['end']['isBefore'](_0x2dd7e5['end'])?-0x1:_0x436d32['end']['isAfter'](_0x2dd7e5['end'])?0x1:'add'===_0x4c8d30['type']?-0x1:0x1;}),{'root':_0x5d549c,'changes':_0x378e72};function _0x30077c(_0x5dc23c,_0x42ddc6,_0x4475ac,_0x307d33){const _0x465a15=!!_0x3313bb[_0x42ddc6][_0x5dc23c],_0x54bd46=_0x465a15?_0x3313bb[_0x42ddc6][_0x5dc23c]['userId']:null,_0x589e89=_0x42ddc6===_0x3313bb['length']-0x1,_0x5e3d0b=_0x46cd54[_0x5dc23c][0x0],_0x1a7f34=_0xf51a7d['isObject'](_0x3313bb[_0x42ddc6]['item']);!_0x24b060[_0x5dc23c]&&_0x465a15?_0x24b060[_0x5dc23c]={'start':_0x4475ac,'tapeItem':_0x3313bb[_0x42ddc6],'userId':_0x54bd46,'type':_0x5dc23c}:_0x24b060[_0x5dc23c]&&!_0x465a15?(_0x24b060[_0x5dc23c]['end']=_0x4475ac,_0x269d5c(_0x24b060[_0x5dc23c]),_0x24b060[_0x5dc23c]=null):_0x24b060[_0x5dc23c]&&_0x465a15&&_0x24b060[_0x5dc23c]['userId']!==_0x54bd46&&(_0x24b060[_0x5dc23c]['end']=_0x4475ac,_0x5e3d0b&&_0x5e3d0b['userId']===_0x24b060[_0x5dc23c]['userId']||_0x269d5c(_0x24b060[_0x5dc23c]),_0x24b060[_0x5dc23c]={'start':_0x4475ac,'tapeItem':_0x3313bb[_0x42ddc6],'userId':_0x54bd46,'type':_0x5dc23c}),_0x24b060[_0x5dc23c]&&_0x1a7f34&&('elementStart'!==_0x3313bb[_0x42ddc6]['type']||_0x5e3d0b&&_0x5e3d0b['userId']===_0x54bd46||_0x46cd54[_0x5dc23c]['unshift']({'userId':_0x54bd46,'object':_0x3313bb[_0x42ddc6]['item'],'change':_0x24b060[_0x5dc23c]}),'elementEnd'===_0x3313bb[_0x42ddc6]['type']&&_0x5e3d0b&&_0x5e3d0b['object']===_0x3313bb[_0x42ddc6]['item']&&(_0x46cd54[_0x5dc23c]['shift'](),_0x24b060[_0x5dc23c]=_0x5e3d0b['change'])),_0x24b060[_0x5dc23c]&&_0x589e89&&(_0x24b060[_0x5dc23c]['end']=_0x307d33,_0x269d5c(_0x24b060[_0x5dc23c]),_0x24b060[_0x5dc23c]=null);}function _0x269d5c({start:_0x3d37c8,end:_0x3acc1c,tapeItem:_0xbe1787,userId:_0x46a7aa,type:_0x4cc221}){const _0xf79b33=_0xbe1787['item'],_0x28d52e=_0x8b2fe3['schema']['isBlock'](_0xf79b33)&&!_0x8b2fe3['schema']['isLimit'](_0xf79b33),_0x42a92e=_0x3d37c8['nodeAfter']==_0x3acc1c['parent']&&_0x3acc1c['isAtStart'];if(_0x28d52e&&_0x42a92e)return;const _0x21b118=_0x8b2fe3['createRange'](_0x3d37c8,_0x3acc1c),_0x3ecd74=_0x53c631['get'](_0x46a7aa),_0x535bba=new G({'author':_0x3ecd74,'type':'isAdded'==_0x4cc221||'isAddSuggestion'==_0x4cc221?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x4cc221||'isRemoveSuggestion'==_0x4cc221},'createdAt':new Date(),'rootName':_0x566459});_0x378e72['push'](_0x535bba),_0x5d549c['markers']['set']('revision:'+_0x535bba['id'],_0x21b118);}function _0x555ab3(_0x5bf8b9,_0x5bbeb4){const _0x154b74=_0x5bf8b9['getAttributes'](),_0x377ffb=_0x5bbeb4['getAttributes']();for(const _0x3981e9 of _0x154b74){if(_0x3981e9[0x1]!==_0x5bbeb4['getAttribute'](_0x3981e9[0x0]))return!0x1;_0x377ffb['next']();}return _0x377ffb['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x51f2e1=>{const _0x345b4b=_0x51f2e1['markerName']['split'](':')[0x1],_0x133d1a=this['_getChangeFromId'](_0x345b4b);if(!_0x133d1a)return null;const _0x1fb3c5='add'==_0x133d1a['type']?'insertion':'deletion',_0x2c6bfd=['ck-suggestion-marker','ck-suggestion-marker-'+_0x1fb3c5];return _0x133d1a['data']['isSuggestion']&&_0x2c6bfd['push']('ck-suggestion-marker-'+_0x1fb3c5+'-new'),this['activeChange']==_0x133d1a&&_0x2c6bfd['push']('ck-suggestion-marker--active'),{'classes':_0x2c6bfd,'attributes':{'data-change-id':_0x345b4b}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x28272e=>{_0x28272e['on']('element:pre',(_0x118629,_0x18fb36,_0x494805)=>{const _0x16603c=_0x18fb36['viewItem']['getChild'](0x0);if(!_0x16603c||!_0x16603c['is']('element','code'))return;if(!_0x494805['consumable']['consume'](_0x16603c,{'attributes':['vid_start','vid_end']}))return;const _0x7e4798=_0x18fb36['modelRange']['start']['nodeAfter'];_0x494805['writer']['setAttribute']('vid_start',_0x16603c['getAttribute']('vid_start'),_0x7e4798),_0x494805['writer']['setAttribute']('vid_end',_0x16603c['getAttribute']('vid_end'),_0x7e4798);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x41c939=>{_0x41c939['on']('element',(_0x5765d7,_0x2ef7e8,_0x24df94)=>{if(!_0x24df94['consumable']['consume'](_0x2ef7e8['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x2ef7e8['modelRange']['isCollapsed'])return;const _0xd85dff=_0x2ef7e8['modelRange']['start']['nodeAfter'];_0xd85dff['hasAttribute']('vid_start')||_0xd85dff['hasAttribute']('vid')||(_0x24df94['writer']['setAttribute']('vid_start',_0x2ef7e8['viewItem']['getAttribute']('vid_start'),_0xd85dff),_0x24df94['writer']['setAttribute']('vid_end',_0x2ef7e8['viewItem']['getAttribute']('vid_end'),_0xd85dff));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x442555=>_0x442555['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0xfccf92,[,_0x52cc34])=>{['vid_start','vid_end','vid']['includes'](_0x52cc34)&&(_0xfccf92['return']=!0x0,_0xfccf92['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x41ad4a=>{_0x41ad4a['on']('attribute:vid',(_0xce7c0,_0x569fb5,_0x9b23c9)=>{if('\x20'!=_0x569fb5['item']['data']||_0x569fb5['item']['parent']['maxOffset']>0x1)return;if(!_0x9b23c9['consumable']['consume'](_0x569fb5['item'],_0xce7c0['name']))return;const _0x182b91=_0x9b23c9['writer'],_0x2b8167=_0x9b23c9['mapper']['toViewRange'](_0x569fb5['range']);_0x182b91['wrap'](_0x2b8167,_0x182b91['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x4ca396){const _0x5d5d2e=_0x4ca396['plugins']['get']('RevisionViewer');return(_0x460555,_0x2ec341,_0x1939f2)=>{const _0x261e35=_0x2ec341['markerName']['split'](':')[0x1],_0xa385df=_0x5d5d2e['_getChangeFromId'](_0x261e35);if(!_0xa385df)return null;const _0x25ab7f='add'==_0xa385df['type']?'split':'merge';if(!_0x1939f2['consumable']['test'](_0x2ec341['markerRange'],_0x460555['name']))return;const _0x9b8653=_0x2ec341['markerRange']['getWalker'](),_0x1c08eb=_0x2ec341['markerRange']['start'],_0xef03e6=_0x4ca396['model']['schema'];let _0x2e10fa=null,_0x3a3ab3=null,_0x4f8717=!0x1,_0x2d17be=!0x1;for(const _0x597473 of _0x9b8653){const _0x17f706=_0x597473['item'];_0x4f8717=_0x4f8717||_0xef03e6['isContent'](_0x17f706);const _0x504449=_0x1939f2['mapper']['toViewElement'](_0x17f706);if(_0x504449&&_0x504449['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x597473['type']&&(_0xef03e6['isBlock'](_0x17f706)&&!_0xef03e6['isLimit'](_0x17f706)&&(_0x17f706['nextSibling']||_0x1c08eb['isAtEnd']?_0x2e10fa&&_0x2e10fa['parent']==_0x17f706||(_0x2e10fa=_0x17f706,_0x5a815c(_0x597473['previousPosition']),_0x2d17be=!0x0):_0x3a3ab3=_0x3a3ab3||_0x597473['previousPosition']));}function _0x5a815c(_0x247c5b){const _0x5d1161=_0x1939f2['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x25ab7f}),_0x4dc68b=_0x1939f2['mapper']['toViewPosition'](_0x247c5b);_0xa385df['data']['isSuggestion']&&_0x1939f2['writer']['addClass']('ck-suggestion-marker-'+_0x25ab7f+'-new',_0x5d1161),_0x5d5d2e['activeChange']==_0xa385df&&_0x1939f2['writer']['addClass']('ck-suggestion-marker--active',_0x5d1161),_0x1939f2['writer']['insert'](_0x4dc68b,_0x5d1161),_0x1939f2['mapper']['bindElementToMarker'](_0x5d1161,_0x2ec341['markerName']);}_0x4f8717||_0x2d17be||!_0x3a3ab3||_0x5a815c(_0x3a3ab3);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x5e4d0a,_0x59cc3f,_0x578e4f)=>{const _0x2ab1aa=_0x578e4f['mapper']['markerNameToElements'](_0x59cc3f['markerName']);if(_0x2ab1aa){for(const _0x39c6ef of _0x2ab1aa)(_0x39c6ef['hasClass']('ck-suggestion-marker-split')||_0x39c6ef['hasClass']('ck-suggestion-marker-merge'))&&(_0x578e4f['mapper']['unbindElementFromMarkerName'](_0x39c6ef,_0x59cc3f['markerName']),_0x578e4f['writer']['remove'](_0x39c6ef));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x3d8f9f,_0x43ee3e,_0x44c6b2)=>{const _0x4a543b=_0x43ee3e['markerName']['split'](':')[0x1],_0x19e67d=this['_getChangeFromId'](_0x4a543b);if(!_0x19e67d)return null;const _0x22c910='add'==_0x19e67d['type']?'split':'merge';if(_0x44c6b2['consumable']['test'](_0x43ee3e['markerRange'],_0x3d8f9f['name']))for(const _0x171cdb of _0x43ee3e['markerRange']['getItems']()){if(!_0x171cdb['is']('element','softBreak'))continue;const _0x4b6c80=_0x44c6b2['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x22c910}),_0xb70e91=_0x44c6b2['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x171cdb));_0x19e67d['data']['isSuggestion']&&_0x44c6b2['writer']['addClass']('ck-suggestion-marker-'+_0x22c910+'-new',_0x4b6c80),this['activeChange']==_0x19e67d&&_0x44c6b2['writer']['addClass']('ck-suggestion-marker--active',_0x4b6c80),_0x44c6b2['writer']['insert'](_0xb70e91,_0x4b6c80),_0x44c6b2['mapper']['bindElementToMarker'](_0x4b6c80,_0x43ee3e['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x340785=>{for(const _0x3eddf6 of this['editor']['model']['document']['getRootNames']()){const _0x14c6e0=this['editor']['model']['document']['getRoot'](_0x3eddf6),_0x357602=this['editor']['editing']['view']['document']['getRoot'](_0x3eddf6);if(_0x357602){const _0x36be08=_0x14c6e0['getAttribute']('revisionHistoryAttachChange');if(_0x340785['removeAttribute']('data-change-id',_0x357602),_0x340785['removeClass']('ck-revision-history-root-add',_0x357602),_0x340785['removeClass']('ck-revision-history-root-remove',_0x357602),_0x340785['removeClass']('ck-revision-history-root--active',_0x357602),_0x36be08){const _0x3a4b15=this['_getChangeFromId'](_0x36be08);if(!_0x3a4b15)return null;_0x340785['setAttribute']('data-change-id',_0x36be08,_0x357602),_0x340785['addClass']('ck-revision-history-root-'+_0x3a4b15['type'],_0x357602),this['activeChange']==_0x3a4b15&&_0x340785['addClass']('ck-revision-history-root--active',_0x357602);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x592e53=>'revision-comment:'+_0x592e53,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x43dc56=>'revision-suggestion:'+_0x43dc56,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x5a2889=>({'name':'suggestion:'+_0x5a2889,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x27c873=>{const _0x9af84=_0x27c873['markerName']['split'](':')[0x1];return'insertion'!=_0x9af84&&'deletion'!=_0x9af84?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x9af84]};}}),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',(_0x5ae29b,_0x4c253e,_0x589f01)=>{const _0x30cf35=_0x589f01['mapper']['markerNameToElements'](_0x4c253e['markerName']);if(_0x30cf35){for(const _0x79776e of _0x30cf35)_0x79776e['is']('uiElement')&&(_0x589f01['mapper']['unbindElementFromMarkerName'](_0x79776e,_0x4c253e['markerName']),_0x589f01['writer']['remove'](_0x79776e));}},{'priority':'high'});}['_getChangeFromId'](_0x348c0e){return this['_changeIdToChange']['get'](_0x348c0e);}['_getViewForChange'](_0x3dd294){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new z(this['editor']['locale'],_0x3dd294),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0xb74560,_0x5717a9,_0x2aedfc,_0x1b6955)=>{_0x1b6955&&this['_balloon']['remove'](_0x1b6955),_0x2aedfc&&(this['_balloon']['add']({'view':_0x2aedfc,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x527e5e=this['editor']['editing'],_0x3110b3=this['_getChangeFromId'](_0x2aedfc['changeId']);let _0x1f3957;if(_0x3110b3['data']['isOnRoot']){const _0x43367e=_0x527e5e['view']['getDomRoot'](_0x3110b3['rootName']);_0x1f3957=Array['from'](_0x43367e['getClientRects']());}else{const _0x4cf945=this['editor']['model']['markers']['get']('revision:'+_0x2aedfc['changeId']);_0x1f3957=Array['from'](_0x527e5e['mapper']['markerNameToElements'](_0x4cf945['name']))['map'](_0x3bdfaf=>_0x527e5e['view']['domConverter']['mapViewToDom'](_0x3bdfaf))['map'](_0x50493c=>Array['from'](_0x50493c['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x1f3957[0x0];return _0x1f3957['find'](_0x2cda6a=>_0x2cda6a['top']-0x3<=this['_activeViewTarget']['y']&&_0x2cda6a['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x2cda6a['left']-0x3<=this['_activeViewTarget']['x']&&_0x2cda6a['right']+0x3>=this['_activeViewTarget']['x'])||_0x1f3957[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x44c488,_0x2fc60f,_0x46b5fb,_0x5528b5)=>{this['activeView']=_0x46b5fb?this['_getViewForChange'](_0x46b5fb):null,this['editor']['model']['change'](()=>{const _0x139c44=this['editor']['editing'];_0x5528b5&&(_0x5528b5['data']['isOnRoot']?_0x139c44['view']['change'](_0x320bdc=>{_0x320bdc['removeClass']('ck-revision-history-root--active',_0x139c44['view']['document']['getRoot'](_0x5528b5['rootName']));}):_0x139c44['reconvertMarker']('revision:'+_0x5528b5['id'])),_0x46b5fb&&(_0x46b5fb['data']['isOnRoot']?_0x139c44['view']['change'](_0x4d4ff3=>{_0x4d4ff3['addClass']('ck-revision-history-root--active',_0x139c44['view']['document']['getRoot'](_0x46b5fb['rootName']));}):_0x139c44['reconvertMarker']('revision:'+_0x46b5fb['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x2137c9,_0x81e42e)=>{if(this['activeChange'])return;const _0x4ac322=this['_findChangeIdFromDomTarget'](_0x81e42e['target']),_0x453de6=this['_changeIdToChange']['get'](_0x4ac322);_0x453de6?(this['_activeViewTarget']={'x':_0x81e42e['domEvent']['x'],'y':_0x81e42e['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x453de6)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x26d85b,_0x5826ab)=>{const _0x1d010f=this['_findChangeIdFromDomTarget'](_0x5826ab['target']),_0x37d957=this['_changeIdToChange']['get'](_0x1d010f);_0x37d957?(this['_activeViewTarget']={'x':_0x5826ab['domEvent']['x'],'y':_0x5826ab['domEvent']['y']},_0x37d957===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x37d957):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x20561c){do{const _0x42738d=_0x20561c['getAttribute']('data-change-id');if(_0x42738d)return _0x42738d;_0x20561c=_0x20561c['parent'];}while(_0x20561c);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x21d62e=>{for(const _0x279f5c of this['editor']['model']['markers'])_0x21d62e['removeMarker'](_0x279f5c);});}}function Q(_0x3168ee,_0x2667da){return(_0x3916f1,_0x1e8771,_0x235ecf)=>{if(!_0x235ecf['consumable']['test'](_0x1e8771['markerRange'],_0x3916f1['name']))return;const _0xc65cde=_0x1e8771['markerRange']['getWalker'](),_0x353b1f=_0x1e8771['markerRange']['start'],_0x5ec111=_0x3168ee['model']['schema'];let _0x31f25f=null,_0x2e74b7=null,_0x59c93a=!0x1,_0xb62167=!0x1;for(const _0x391b45 of _0xc65cde){const _0x46acbf=_0x391b45['item'];_0x59c93a=_0x59c93a||_0x5ec111['isContent'](_0x46acbf);const _0x4efdd3=_0x235ecf['mapper']['toViewElement'](_0x46acbf);if(_0x4efdd3&&_0x4efdd3['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x391b45['type']&&(_0x5ec111['isBlock'](_0x46acbf)&&!_0x5ec111['isLimit'](_0x46acbf)&&(_0x46acbf['nextSibling']||_0x353b1f['isAtEnd']?_0x31f25f&&_0x31f25f['parent']==_0x46acbf||(_0x31f25f=_0x46acbf,_0x3d8d6a(_0x391b45['previousPosition']),_0xb62167=!0x0):_0x2e74b7=_0x2e74b7||_0x391b45['previousPosition']));}function _0x3d8d6a(_0xb7a712){const _0x17a3d0=_0x235ecf['mapper']['toViewPosition'](_0xb7a712),_0x2ef0e5=_0x235ecf['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x2667da});_0x235ecf['writer']['insert'](_0x17a3d0,_0x2ef0e5),_0x235ecf['mapper']['bindElementToMarker'](_0x2ef0e5,_0x1e8771['markerName']);}_0x59c93a||_0xb62167||!_0x2e74b7||_0x3d8d6a(_0x2e74b7);};}class nt extends _0x1bb13c{constructor(_0x401561){super(_0x401561);const _0x348c34=_0x401561['plugins']['get'](u);this['affectsData']=!0x1,this['listenTo'](_0x348c34,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x348c34,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x4f093e=this['editor'],_0x242123=_0x4f093e['plugins']['get'](u),_0x5df279=_0x242123['isReady']?_0x242123['diff']['newRevisionId']:null;_0x4f093e['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x5df279);}['refresh'](){const {isReady:_0x26d0c0,isEnabled:_0x456cd8,repository:_0x18c621,diff:_0x25d726}=this['editor']['plugins']['get'](u),_0x33dbd4=_0x25d726&&_0x18c621['getLaterVisibleRevision'](_0x25d726['newRevisionId']);this['isEnabled']=_0x26d0c0&&_0x456cd8&&Boolean(_0x33dbd4);}}class ot extends _0x1bb13c{['_step'];constructor(_0x4dd1bc,{direction:_0x10fe5d}){super(_0x4dd1bc);const _0x37ca69=_0x4dd1bc['plugins']['get'](u);this['affectsData']=!0x1,this['_step']='forward'===_0x10fe5d?0x1:-0x1,this['listenTo'](_0x37ca69,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x37ca69,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x37ca69,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x18ce15=this['editor'],_0x4978ba=_0x18ce15['plugins']['get'](u),{isNavigationMode:_0x33584f,currentChangeNumber:_0xdba9}=_0x4978ba;let _0x101d89;if(_0x4978ba['activeChange']=_0x33584f?_0x4978ba['diff']['changes']['get'](_0xdba9+this['_step']):_0x4978ba['diff']['changes']['first'],_0x4978ba['activeChange']['data']['isOnRoot'])_0x101d89=_0x18ce15['editing']['view']['getDomRoot'](_0x4978ba['activeChange']['rootName']);else{const _0x1b6448=_0x18ce15['model']['markers']['get']('revision:'+_0x4978ba['activeChange']['id']);_0x101d89=_0x1eaada(_0x18ce15['editing'],_0x1b6448);}_0xffbfb2({'target':_0x101d89,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x58da56,currentChangeNumber:_0x46e69c,numberOfChanges:_0x51b9c1,isReady:_0x43d85d,isEnabled:_0x5ce4dd}=this['editor']['plugins']['get'](u);this['isEnabled']=!!(_0x5ce4dd&&_0x43d85d&&_0x51b9c1)&&(!_0x58da56||(0x1===this['_step']?_0x46e69c<_0x51b9c1-0x1:_0x46e69c>0x0));}}class ui extends _0x28ff5a{constructor(_0x581a6e){super(_0x581a6e);const _0x38c712=this['bindTemplate'],_0x35fb00=new _0x22df11(_0x581a6e),_0x72ab80=new _0x22df11(_0x581a6e);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',(_0x7fef84,_0x1c3cbc)=>_0x7fef84&&_0x1c3cbc>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x4514f9,_0x2ed46c,_0x3da09a,_0x34f387)=>{if(!_0x4514f9)return m(_0x581a6e,'Loading...');if(!_0x3da09a)return m(_0x581a6e,'No\x20changes');const _0x580684=m(_0x581a6e,'NUMBER_OF_CHANGES',_0x3da09a);return _0x34f387?m(_0x581a6e,'X_OF_Y_CHANGES',[_0x2ed46c+0x1,_0x3da09a]):_0x580684;}),_0x35fb00['set']({'label':m(_0x581a6e,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x5453e5}),_0x72ab80['set']({'label':m(_0x581a6e,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x5c4b72}),_0x35fb00['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x72ab80['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x35fb00['on']('execute',()=>this['fire']('execute','backward')),_0x72ab80['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',_0x38c712['if']('_isStatusLabelVisible','ck-hidden',_0x57d3af=>!_0x57d3af)]},'children':[{'text':_0x38c712['to']('isNavigationMode',_0x3e9202=>_0x3e9202?m(_0x581a6e,'EDIT_X_OF_Y_REVISIONS')+':\x20':m(_0x581a6e,'Total')+':\x20')}]},{'text':_0x38c712['to']('_statusText')}]},new _0x2d4abe(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x35fb00,_0x72ab80]}]});}}const ge='ck-editor__editable__loading-overlay';class vi extends _0xb302f2{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x3144b1=this['editor']['editing']['view'];_0x3144b1['change'](_0x8a3f2d=>{for(const _0x98faee of _0x3144b1['document']['roots'])_0x8a3f2d['addClass'](ge,_0x98faee);});}['hide'](){const _0x41f516=this['editor']['editing']['view'];_0x41f516['change'](_0x3ee099=>{for(const _0x318eef of _0x41f516['document']['roots'])_0x3ee099['removeClass'](ge,_0x318eef);});}}class v extends _0xb302f2{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u,vi];}['init'](){const _0x4249f7=this['editor'],_0x291c01=_0x4249f7['plugins']['get'](u),_0x32a9a1=_0x4249f7['plugins']['get'](vi);_0x4249f7['ui']['componentFactory']['add']('exitToEditing',_0x3ab4ef=>{const _0x3fe0b1=new _0x22df11(_0x3ab4ef);return _0x3fe0b1['set']({'label':m(_0x3ab4ef,'Back\x20to\x20editing'),'icon':_0x77d497,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x3fe0b1,'execute',()=>{_0x4249f7['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x3fe0b1;}),_0x4249f7['ui']['componentFactory']['add']('restoreRevision',_0x490cad=>{const _0x5a131=new _0x22df11(_0x490cad);return _0x5a131['set']({'label':m(_0x490cad,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x5a131['bind']('isEnabled')['to'](_0x4249f7['commands']['get']('restoreRevision')),this['listenTo'](_0x5a131,'execute',()=>_0x4249f7['execute']('restoreRevision')),_0x5a131;}),_0x4249f7['ui']['componentFactory']['add']('changesNavigation',_0x34ef5b=>{const _0xc37825=new ui(_0x34ef5b),_0x35bf8c=_0x4249f7['commands']['get']('showPreviousChange'),_0x525b94=_0x4249f7['commands']['get']('showNextChange');return _0xc37825['bind']('isBackwardNavigationEnabled')['to'](_0x35bf8c,'isEnabled'),_0xc37825['bind']('isForwardNavigationEnabled')['to'](_0x525b94,'isEnabled'),_0xc37825['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x291c01),this['listenTo'](_0xc37825,'execute',(_0x5b9452,_0x10a5e7)=>{_0x4249f7['execute']('forward'===_0x10a5e7?'showNextChange':'showPreviousChange');}),_0xc37825;}),_0x32a9a1['show'](),_0x291c01['on']('change:isReady',(_0x3c04ab,_0x2ce03e,_0x2050fd)=>{_0x2050fd?_0x32a9a1['hide']():_0x32a9a1['show']();});}}class wi extends ti{['_resizeObserver']=null;constructor(_0xc11f74,_0x444df7){super(_0xc11f74,_0x444df7);const _0x5aa14d=this['bindTemplate'];this['set']({'label':m(_0xc11f74,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=m(_0xc11f74,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x5aa14d['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 _0x47828a=this['fieldView']['element'];this['_tooltipString']=_0x47828a['scrollWidth']>_0x47828a['clientWidth']&&_0x47828a['value']||'';}}class yi extends _0x28ff5a{constructor(_0x28b1ff,_0x56528e,_0x266056){super(_0x28b1ff);const _0x2a5e25=new _0xb2dc1d();_0x2a5e25['set']({'content':_0x34dedb,'viewBox':'0\x200\x2011\x2010'});const _0x1b9a98=['ck','ck-revision-history-sidebar__revision-author'];_0x266056&&_0x1b9a98['push']('ck-revision-history-sidebar__revision-author_creator');const _0x2c0328=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':m(_0x28b1ff,_0x266056?'Revision\x20creator':'Revision\x20author')},'children':[_0x2a5e25,_0x56528e['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x1b9a98},'children':_0x2c0328});}}function ji(_0x323ee5,_0x39314c){const _0x2a83c2=_0x323ee5['bindTemplate'],_0x1a1446=_0x323ee5['locale'],_0x46510e=_0x1f74c9(_0x1a1446);_0x46510e['panelPosition']='sw';const _0x20cdec=function(_0x3ab732,_0x269d2a){const _0x875c0b=function(_0x58869a,_0x3f649a){const _0x32df7c=_0x58869a['locale'],_0x549978={'Compare\x20against\x20selected':m(_0x32df7c,'Compare\x20against\x20selected'),'Name\x20this\x20revision':m(_0x32df7c,'Name\x20this\x20revision'),'Restore\x20this\x20revision':m(_0x32df7c,'Restore\x20this\x20revision')};return _0x3f649a['map'](_0x1c40c9=>{const _0x5d5a23=_0x549978[_0x1c40c9['name']];return _0x5d5a23&&_0x5d5a23!==_0x1c40c9['name']&&(_0x1c40c9['name']=_0x5d5a23),_0x1c40c9;});}(_0x3ab732,_0x269d2a),_0x52dced=new _0x150ee0();for(const _0x42bf28 of _0x875c0b){const _0x38b5c3={'type':'button','model':new to({'label':_0x42bf28['name'],'class':_0x42bf28['class'],'withText':!0x0,'role':'menuitem','_action':_0x42bf28['action']})};_0x38b5c3['model']['bind']('isEnabled')['to'](_0x3ab732,'isActionsDropdownOpen',_0x18accc=>'function'!=typeof _0x42bf28['isEnabled']||(!_0x18accc||_0x42bf28['isEnabled'](_0x3ab732))),_0x52dced['add'](_0x38b5c3);}return _0x52dced;}(_0x323ee5,_0x39314c);return _0x323ee5['bind']('isActionsDropdownOpen')['to'](_0x46510e,'isOpen'),_0x46510e['buttonView']['set']({'label':m(_0x1a1446,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x20126f}),_0x46510e['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x2a83c2['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x2a83c2['to'](_0x2b8723=>_0x2b8723['stopPropagation']())}}),_0x46510e['on']('execute',_0x52a8e3=>{_0x323ee5['isReady']&&'function'==typeof _0x52a8e3['source']['_action']&&_0x52a8e3['source']['_action'](_0x323ee5);}),_0x32b313(_0x46510e,_0x20cdec,{'role':'menu'}),_0x46510e['listenTo'](_0x323ee5,'change:isActionsDropdownOpen',(_0x3bd609,_0x2d2705,_0x2b5e89)=>{if(_0x2b5e89)for(const _0x2fd7ae of _0x46510e['listView']['items']){const _0x571390=_0x2fd7ae['children']['first'],_0x2ec7b1=_0x39314c['find'](_0xfbc6e=>_0xfbc6e['action']===_0x571390['_action'])['isVisible'];_0x2fd7ae['isVisible']=void 0x0===_0x2ec7b1||_0x2ec7b1(_0x323ee5);}}),_0x46510e;}class _i extends/* #__PURE__ -- @preserve */
|
|
27
|
-
|
|
23
|
+
import{ObservableMixin as _0x1a438a,uid as _0x3bb1d9,Collection as _0x40f1c6,logWarning as _0x823218,FocusTracker as _0x57d9ce,KeystrokeHandler as _0x5f3a69,scrollViewportToShowTarget as _0x41b90b,ResizeObserver as ot,ElementReplacer as it,CKEditorError as _0x5a9728}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x1f8919,set as _0x2c972b,unset as _0x45b178,isEqual as _0x588fc7}from'es-toolkit/compat';import{Plugin as _0x2bce4d,PendingActions as _0x5a0857,Command as _0x1e3043,ElementApiMixin as _0x335ce4,Editor as _0x43bc7b}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x729304,getMarkerDomElement as _0x47c945,ConfirmMixin as _0x4e9a07,sanitizeEditorConfig as _0x4af87c}from'ckeditor5-collaboration/dist/index.js';import{ViewContainerElement as _0x6e2313,ViewAttributeElement as _0x4ce6b3,ViewEmptyElement as _0x5d6ad4,ViewRawElement as _0x242d82,ViewUIElement as _0x49d851,ViewDocumentFragment as _0x11f4b2,ViewText as _0x286ad4,ViewElement as _0x23f5aa,ModelElement as _0x41b3fc,ModelRange as _0x1340e0,ModelPosition as _0x4d7936,ModelDocumentFragment as _0x1753c2,ModelText as _0x3e2046}from'@ckeditor/ckeditor5-engine/dist/index.js';import{IconHistory as _0x3f5198,IconChevronUp as _0x338ac3,IconChevronDown as _0x13d84f,IconUndo as _0x57a137,IconUser as _0x4ad26c,IconThreeVerticalDots as _0x575b19}from'@ckeditor/ckeditor5-icons/dist/index.js';import{CssTransitionDisablerMixin as _0x5e9ce1,View as _0x4c679a,submitHandler as _0x3ae8e9,LabeledFieldView as et,createLabeledInputText as ti,createDropdown as _0x46d208,ListView as _0x33e630,ListItemView as _0x2b7b7d,ButtonView as _0x1a6925,MenuBarMenuView as _0x412e4b,MenuBarMenuListView as _0x289751,MenuBarMenuListItemView as _0x50e527,MenuBarMenuListItemButtonView as _0x1326a4,ContextualBalloon as _0x27a1d9,ToolbarSeparatorView as _0x33adfd,IconView as _0x26c7e2,addListToDropdown as _0x39fd9f,UIModel as to,EditorUI as tt,normalizeToolbarConfig as st,BoxedEditorUIView as _0x21096b,StickyPanelView as _0x267fea,ToolbarView as _0x2a39c7,InlineEditableUIView as te}from'@ckeditor/ckeditor5-ui/dist/index.js';import{DateTime as _0x11c9f8}from'luxon';class I extends/* #__PURE__ -- @preserve */
|
|
24
|
+
_0x1a438a(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x182d7d){super(),this['id']=_0x182d7d['id']||_0x3bb1d9(),this['creator']=_0x182d7d['creator']||null,this['authors']=_0x182d7d['authors']||[],this['diffData']=_0x182d7d['diffData']||null,this['toVersion']=_0x182d7d['toVersion']||0x0,this['fromVersion']=_0x182d7d['fromVersion']||0x0,this['set']('name',_0x182d7d['name']||''),this['set']('createdAt',_0x182d7d['createdAt']||new Date()),this['set']('attributes',_0x182d7d['attributes']||{});}['setName'](_0x5a74c3){this['_update']({'name':_0x5a74c3});}['setAttribute'](_0x34d2a9,_0x5aeca2){const _0x42b2e6=_0x1f8919(this['attributes']);_0x2c972b(_0x42b2e6,_0x34d2a9,_0x5aeca2),this['_update']({'attributes':_0x42b2e6});}['removeAttribute'](_0x28b96b){const _0x1b0177=_0x1f8919(this['attributes']);_0x45b178(_0x1b0177,_0x28b96b),this['_update']({'attributes':_0x1b0177});}['_update'](_0x131400,_0x3a759f=!0x1){let _0x285a9a=!0x1;const _0xd88e12={'id':this['id']},_0x1af273=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x4f9567 of _0x1af273){const _0x460a68=_0x131400[_0x4f9567];void 0x0!==_0x460a68&&_0x460a68!==this[_0x4f9567]&&(this[_0x4f9567]=_0x460a68,_0xd88e12[_0x4f9567]=_0x460a68,_0x285a9a=!0x0);}_0x285a9a&&(_0xd88e12['authors']&&(_0xd88e12['authorsIds']=_0xd88e12['authors']['map'](_0x51a996=>_0x51a996['id']),delete _0xd88e12['authors']),this['fire']('_update',_0xd88e12,_0x3a759f));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x2c941c=>_0x2c941c['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class S extends _0x2bce4d{['_revisions'];static get['requires'](){return[_0x729304];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x4f3a8c){super(_0x4f3a8c),this['_revisions']=new _0x40f1c6();}['afterInit'](){!async function(_0x1fe2df){const _0x3b0496=_0x38a251([0x73,0x47,0x36,0x35,0x43,0x72,0x6b,0x31,0x63,0x64,0x32,0x69,0x67,0x4c,0x4e,0x37,0x7a,0x49,0x45,0x41,0x59,0x6a,0x75,0x39,0x4a,0x33,0x68,0x62,0x50,0x42,0x74,0x6e,0x46,0x4d,0x78,0x51,0x66,0x34,0x48,0x77,0x5a,0x61,0x6c,0x30,0x71,0x54,0x53,0x56,0x4b,0x79,0x44,0x6d,0x6f,0x52,0x76,0x55,0x58,0x65,0x70,0x57,0x4f,0x38]),_0x58edfb=0xeb829,_0x26ab8f=0x7374585f,_0x5e85ec=0x73732caf^_0x26ab8f,_0x2e78e1=window[_0x38a251([0x44,0x61,0x74,0x65])][_0x38a251([0x6e,0x6f,0x77])](),_0x59fc46=_0x1fe2df[_0x38a251([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x435776=new window[(_0x38a251([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x3fa6ab=>{_0x59fc46[_0x38a251([0x6f,0x6e,0x63,0x65])](_0x38a251([0x72,0x65,0x61,0x64,0x79]),_0x3fa6ab);}),_0x14fbf8={[_0x38a251([0x6b,0x74,0x79])]:_0x38a251([0x45,0x43]),[_0x38a251([0x75,0x73,0x65])]:_0x38a251([0x73,0x69,0x67]),[_0x38a251([0x63,0x72,0x76])]:_0x38a251([0x50,0x2d,0x32,0x35,0x36]),[_0x38a251([0x78])]:_0x38a251([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]),[_0x38a251([0x79])]:_0x38a251([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]),[_0x38a251([0x61,0x6c,0x67])]:_0x38a251([0x45,0x53,0x32,0x35,0x36])},_0x24f6d4=_0x59fc46[_0x38a251([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x38a251([0x67,0x65,0x74])](_0x38a251([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x22a989(){let _0x541463,_0x47ebff=null,_0x6be07e=null;try{if(_0x24f6d4==_0x38a251([0x47,0x50,0x4c]))return _0x38a251([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x541463=_0x5c96d3(),!_0x541463)return _0x38a251([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x541463[_0x38a251([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x6be07e=_0x59b605(_0x541463[_0x38a251([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x541463[_0x38a251([0x6a,0x74,0x69])])),await _0x199d93()?_0x53312d()?_0x482598()?_0x38a251([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x110180()?(_0x541463[_0x38a251([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x38a251([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x47ebff=_0x1401dc(_0x38a251([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x541463[_0x38a251([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x38a251([0x74,0x72,0x69,0x61,0x6c])&&(_0x47ebff=_0x1401dc(_0x38a251([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x3c5826()):_0x38a251([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x38a251([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x38a251([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x38a251([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x482598(){const _0x20c50e=[_0x38a251([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x38a251([0x74,0x72,0x69,0x61,0x6c])][_0x38a251([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x541463[_0x38a251([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x2e78e1/0x3e8:0xe10*_0x5e85ec;return _0x541463[_0x38a251([0x65,0x78,0x70])]<_0x20c50e;}function _0x53312d(){const _0x386499=_0x541463[_0x38a251([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x386499)return!0x1;if(_0x386499[_0x38a251([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x38a251([0x2a])))return!0x0;if(_0x386499[_0x38a251([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x38a251([0x52,0x48])))return!0x0;if(_0x386499[_0x38a251([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x38a251([0x52,0x52,0x48]))){if(_0x15c2b8())return!0x0;if(_0x230ff9()||_0x304331())return!0x0;}return!0x1;}function _0x110180(){const _0x5f4ff9=_0x541463[_0x38a251([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x5f4ff9||0x0==_0x5f4ff9[_0x38a251([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x3d8b5e}=new URL(window[_0x38a251([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x5f4ff9[_0x38a251([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x3d8b5e))return!0x0;const _0x28e968=_0x3d8b5e[_0x38a251([0x73,0x70,0x6c,0x69,0x74])](_0x38a251([0x2e]));return _0x5f4ff9[_0x38a251([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x4bd94c=>_0x4bd94c[_0x38a251([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x38a251([0x2a])))[_0x38a251([0x6d,0x61,0x70])](_0x189495=>_0x189495[_0x38a251([0x73,0x70,0x6c,0x69,0x74])](_0x38a251([0x2e])))[_0x38a251([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x172404=>_0x172404[_0x38a251([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x28e968[_0x38a251([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x38a251([0x6d,0x61,0x70])](_0x116135=>Array(_0x28e968[_0x38a251([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0x116135[_0x38a251([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x38a251([0x66,0x69,0x6c,0x6c])](_0x116135[0x0]===_0x38a251([0x2a])?_0x38a251([0x2a]):'')[_0x38a251([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0x116135))[_0x38a251([0x73,0x6f,0x6d,0x65])](_0x2baa33=>_0x28e968[_0x38a251([0x65,0x76,0x65,0x72,0x79])]((_0x451786,_0x575a90)=>_0x2baa33[_0x575a90]===_0x451786||_0x2baa33[_0x575a90]===_0x38a251([0x2a])));}function _0x3c5826(){return _0x47ebff&&_0x6be07e?new window[(_0x38a251([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x537b7b,_0x3bbb6f)=>{_0x47ebff[_0x38a251([0x74,0x68,0x65,0x6e])](_0x537b7b,_0x3bbb6f),_0x6be07e[_0x38a251([0x74,0x68,0x65,0x6e])](_0x4d9f1c=>{_0x4d9f1c!=_0x38a251([0x56,0x61,0x6c,0x69,0x64])&&_0x537b7b(_0x4d9f1c);},_0x3bbb6f);}):_0x47ebff||_0x6be07e||_0x38a251([0x56,0x61,0x6c,0x69,0x64]);}}function _0x59b605(_0x34f5fd,_0x3eeea6){return new window[(_0x38a251([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x21d546=>{if(_0x5e1901())return _0x21d546(_0x38a251([0x56,0x61,0x6c,0x69,0x64]));_0x2f39ac(),_0x59fc46[_0x38a251([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x38a251([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x85878d=!0x1;const _0x3004c3=_0x3bb1d9();function _0x27db1f(_0x5a872a){return!!_0x5a872a&&(typeof _0x5a872a===_0x38a251([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x5a872a===_0x38a251([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x5a872a[_0x38a251([0x74,0x68,0x65,0x6e])]===_0x38a251([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x5a872a[_0x38a251([0x63,0x61,0x74,0x63,0x68])]===_0x38a251([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x1617a0(_0x7dd2b){_0x398a59(_0x7dd2b)[_0x38a251([0x74,0x68,0x65,0x6e])](_0xe045f1=>{if(!_0xe045f1||_0xe045f1[_0x38a251([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x38a251([0x6f,0x6b]))return _0x38a251([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x5aad07(_0x3e5fa8(_0x3004c3+_0x3eeea6))!=_0xe045f1[_0x38a251([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x38a251([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x38a251([0x56,0x61,0x6c,0x69,0x64]);})[_0x38a251([0x74,0x68,0x65,0x6e])](_0x28b1ca=>(_0x2b9e20(),_0x28b1ca),()=>{const _0x3bed84=_0x5668e8();return null==_0x3bed84?(_0x2b9e20(),_0x38a251([0x56,0x61,0x6c,0x69,0x64])):_0x38a251(_0x2e78e1-_0x3bed84>(0x5778dc5f^_0x26ab8f)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x38a251([0x74,0x68,0x65,0x6e])](_0x21d546)[_0x38a251([0x63,0x61,0x74,0x63,0x68])](()=>{_0x21d546(_0x38a251([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x3d80f9=0x7342b6df^_0x26ab8f;function _0x2b9e20(){const _0x2e030f=_0x38a251([0x6c,0x6c,0x63,0x74,0x2d])+_0x5aad07(_0x3e5fa8(_0x34f5fd)),_0xa11525=_0x58d8a3(_0x5aad07(window[_0x38a251([0x4d,0x61,0x74,0x68])][_0x38a251([0x63,0x65,0x69,0x6c])](_0x2e78e1/_0x3d80f9)));window[_0x38a251([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x38a251([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x2e030f,_0xa11525);}function _0x5668e8(){const _0x54f5fc=_0x38a251([0x6c,0x6c,0x63,0x74,0x2d])+_0x5aad07(_0x3e5fa8(_0x34f5fd)),_0xd86eb3=window[_0x38a251([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x38a251([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x54f5fc);return _0xd86eb3?window[_0x38a251([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x58d8a3(_0xd86eb3),0x10)*_0x3d80f9:null;}function _0x398a59(_0x8af3f6){return new window[(_0x38a251([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x4b2e5b,_0x1419a0)=>{_0x8af3f6[_0x38a251([0x74,0x68,0x65,0x6e])](_0x4b2e5b,_0x1419a0),window[_0x38a251([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x1419a0,0x73758c9f^_0x26ab8f);});}}_0x59fc46[_0x38a251([0x6f,0x6e])](_0x38a251([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x212168,_0x15068f)=>{if(_0x15068f[0x0]!=_0x34f5fd)return _0x21d546(_0x38a251([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x15068f[0x1]={..._0x15068f[0x1],[_0x38a251([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x3004c3};},{[_0x38a251([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x38a251([0x68,0x69,0x67,0x68])}),_0x59fc46[_0x38a251([0x6f,0x6e])](_0x38a251([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x243743=>{_0x27db1f(_0x243743[_0x38a251([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x85878d=!0x0,_0x1617a0(_0x243743[_0x38a251([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x38a251([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x38a251([0x6c,0x6f,0x77])}),_0x435776[_0x38a251([0x74,0x68,0x65,0x6e])](()=>{_0x85878d||_0x21d546(_0x38a251([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x5e1901(){return _0x59fc46[_0x38a251([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x38a251([0x76,0x69,0x65,0x77])][_0x38a251([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x38a251([0x61,0x75,0x74,0x6f]);}function _0x2f39ac(){_0x59fc46[_0x38a251([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x38a251([0x76,0x69,0x65,0x77])][_0x38a251([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x38a251([0x61,0x75,0x74,0x6f]);}}function _0x1401dc(_0x25cc00){const _0x516ea8=[new window[(_0x38a251([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x288530=>setTimeout(_0x288530,0x737d6693^_0x26ab8f)),_0x435776[_0x38a251([0x74,0x68,0x65,0x6e])](()=>new window[(_0x38a251([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x226086=>{const _0x5a0963=0x73745858^_0x26ab8f,_0x41e1b4=_0x1fe2df[_0x38a251([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x5f8747(){_0x41e1b4[_0x38a251([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x5a0963&&_0x226086();}_0x5f8747(),_0x41e1b4[_0x38a251([0x6f,0x6e])](_0x38a251([0x61,0x64,0x64]),_0x5f8747);})),new window[(_0x38a251([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x4fbabe=>{function _0x4c55a3(){for(const _0x2c64ad in window)if(window[_0x38a251([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x38a251([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x2c64ad))&&window[_0x2c64ad]==_0x58edfb)return _0x4fbabe();_0x59fc46[_0x38a251([0x73,0x74,0x61,0x74,0x65])]!=_0x38a251([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x38a251([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x4c55a3,0x73744bd7^_0x26ab8f);}_0x432bd9(_0x38a251([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x4c55a3();})];return window[_0x38a251([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x38a251([0x72,0x61,0x63,0x65])](_0x516ea8)[_0x38a251([0x74,0x68,0x65,0x6e])](()=>_0x25cc00);}async function _0x24aacb(){if(await _0x435776,_0x432bd9(_0x38a251([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x565b88=_0x1fe2df[_0x38a251([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x4819c8=_0x1fe2df[_0x38a251([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])](_0x565b88[_0x38a251([0x69,0x64])]),_0x138e20=_0x1bbb0e(_0x38a251([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x138e20[_0x38a251([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x565b88['id'],_0x4819c8?_0x4819c8['id']:null,!0x0),_0x138e20[_0x38a251([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x38a251([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x138e20[_0x38a251([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x138e20[_0x38a251([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x121d89,void(_0x138e20[_0x38a251([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x121d89);}if(_0x432bd9(_0x38a251([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x3f0faa=_0x1bbb0e(_0x38a251([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x3f0faa[_0x38a251([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x38a251([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x3f0faa[_0x38a251([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x3f0faa[_0x38a251([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x121d89,_0x3f0faa[_0x38a251([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x121d89;}_0x59fc46[_0x38a251([0x6d,0x6f,0x64,0x65,0x6c])][_0x38a251([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x121d89,_0x59fc46[_0x38a251([0x6d,0x6f,0x64,0x65,0x6c])][_0x38a251([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x121d89,_0x59fc46[_0x38a251([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x38a251([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x15c2b8(){return _0x432bd9(_0x38a251([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x1bbb0e(_0x38a251([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x38a251([0x73,0x74,0x61,0x74,0x65])]==_0x38a251([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x230ff9(){return _0x432bd9(_0x38a251([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 _0x304331(){return _0x432bd9(_0x38a251([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x19c34b(_0x79f6e4){const _0x4a76c8=_0x287e2b();_0x59fc46[_0x4a76c8]=_0x38a251([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])+_0x79f6e4,_0x79f6e4[_0x38a251([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x38a251([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x287e2b()]=_0x58edfb),_0x79f6e4!=_0x38a251([0x56,0x61,0x6c,0x69,0x64])&&_0x24aacb();}function _0x287e2b(){const _0x1026af=window[_0x38a251([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x38a251([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x38a251([0x6e,0x6f,0x77])]())[_0x38a251([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x38a251([0x2e]),'');let _0x7a097=_0x38a251([0x73]);for(let _0x5df506=0x0;_0x5df506<_0x1026af[_0x38a251([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x5df506+=0x2){let _0x5cfc74=window[_0x38a251([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x1026af[_0x38a251([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x5df506,_0x5df506+0x2));_0x5cfc74>=_0x3b0496[_0x38a251([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x5cfc74-=_0x3b0496[_0x38a251([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x7a097+=_0x3b0496[_0x5cfc74];}return _0x7a097;}function _0x5c96d3(){const _0x5e6170=_0x24f6d4[_0x38a251([0x73,0x70,0x6c,0x69,0x74])](_0x38a251([0x2e]));if(0x3!=_0x5e6170[_0x38a251([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x322a7f(_0x5e6170[0x1]);function _0x322a7f(_0x354ab9){const _0x4e3a90=_0x4deb64(_0x354ab9);return _0x4e3a90&&_0x38c792()?_0x4e3a90:null;function _0x38c792(){const _0x4261d1=_0x4e3a90[_0x38a251([0x6a,0x74,0x69])],_0x56b158=window[_0x38a251([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x4261d1[_0x38a251([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x4261d1[_0x38a251([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x5f5248={..._0x4e3a90,[_0x38a251([0x6a,0x74,0x69])]:_0x4261d1[_0x38a251([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x4261d1[_0x38a251([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x5f5248[_0x38a251([0x76,0x63])],_0x3e5fa8(_0x5f5248)==_0x56b158;}}}async function _0x199d93(){let _0x45f44a=!0x0;try{const _0x3d88f1=_0x24f6d4[_0x38a251([0x73,0x70,0x6c,0x69,0x74])](_0x38a251([0x2e])),[_0x42bcca,_0x209f4a,_0x5f02fa]=_0x3d88f1;return _0x1ef106(_0x42bcca),await _0x27c9ba(_0x42bcca,_0x209f4a,_0x5f02fa),_0x45f44a;}catch{return!0x1;}function _0x1ef106(_0x40bec5){const _0x2b3ba0=_0x4deb64(_0x40bec5);_0x2b3ba0&&_0x2b3ba0[_0x38a251([0x61,0x6c,0x67])]==_0x38a251([0x45,0x53,0x32,0x35,0x36])||(_0x45f44a=!0x1);}async function _0x27c9ba(_0x2b8e5f,_0x15fa17,_0x479a03){const _0x3416d7=window[_0x38a251([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x38a251([0x66,0x72,0x6f,0x6d])](_0xd3d097(_0x479a03),_0x2f8d6d=>_0x2f8d6d[_0x38a251([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x4c1e3b=new window[(_0x38a251([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x38a251([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x2b8e5f+_0x38a251([0x2e])+_0x15fa17),_0x237042=window[_0x38a251([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x38a251([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x237042)return;const _0x3cdda0=await _0x237042[_0x38a251([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x38a251([0x6a,0x77,0x6b]),_0x14fbf8,{[_0x38a251([0x6e,0x61,0x6d,0x65])]:_0x38a251([0x45,0x43,0x44,0x53,0x41]),[_0x38a251([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x38a251([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x38a251([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x237042[_0x38a251([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x38a251([0x6e,0x61,0x6d,0x65])]:_0x38a251([0x45,0x43,0x44,0x53,0x41]),[_0x38a251([0x68,0x61,0x73,0x68])]:{[_0x38a251([0x6e,0x61,0x6d,0x65])]:_0x38a251([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x3cdda0,_0x3416d7,_0x4c1e3b)||(_0x45f44a=!0x1);}}function _0x4deb64(_0x428423){return _0x428423[_0x38a251([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x38a251([0x65,0x79]))?JSON[_0x38a251([0x70,0x61,0x72,0x73,0x65])](_0xd3d097(_0x428423)):null;}function _0xd3d097(_0xaad63){return window[_0x38a251([0x61,0x74,0x6f,0x62])](_0xaad63[_0x38a251([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x38a251([0x2b]))[_0x38a251([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x38a251([0x2f])));}function _0x3e5fa8(_0x345c98){let _0xefede6=0x1505;function _0x1669d5(_0x483df0){for(let _0x176876=0x0;_0x176876<_0x483df0[_0x38a251([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x176876++){const _0x4d72b2=_0x483df0[_0x38a251([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x176876);_0xefede6=(_0xefede6<<0x5)+_0xefede6+_0x4d72b2,_0xefede6&=_0xefede6;}}function _0x2d94b8(_0x2fa231){Array[_0x38a251([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x2fa231)?_0x2fa231[_0x38a251([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x2d94b8):_0x2fa231&&typeof _0x2fa231==_0x38a251([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x38a251([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x2fa231)[_0x38a251([0x73,0x6f,0x72,0x74])]()[_0x38a251([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x5e975b,_0xde48ba])=>{_0x1669d5(_0x5e975b),_0x2d94b8(_0xde48ba);}):_0x1669d5(window[_0x38a251([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x2fa231));}return _0x2d94b8(_0x345c98),_0xefede6>>>0x0;}function _0x5aad07(_0xa0309d){return _0xa0309d[_0x38a251([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x38a251([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x38a251([0x30]));}function _0x58d8a3(_0x2fa8d4){return _0x2fa8d4[_0x38a251([0x73,0x70,0x6c,0x69,0x74])]('')[_0x38a251([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x38a251([0x6a,0x6f,0x69,0x6e])]('');}function _0x432bd9(_0xfd37ea){return _0x59fc46[_0x38a251([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x38a251([0x68,0x61,0x73])](_0xfd37ea);}function _0x1bbb0e(_0x1ace37){return _0x59fc46[_0x38a251([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x38a251([0x67,0x65,0x74])](_0x1ace37);}function _0x121d89(){}function _0x38a251(_0x32e56a){return _0x32e56a['map'](_0x5be2=>String['fromCharCode'](_0x5be2))['join']('');}_0x19c34b(await _0x22a989());}(this);}['createRevision'](_0x423363){const _0x3bd5e9=this['editor']['plugins']['get']('Users');return new I({'id':_0x423363['id'],'name':_0x423363['name'],'creator':_0x423363['creatorId']?_0x3bd5e9['getUser'](_0x423363['creatorId']):null,'diffData':_0x423363['diffData']||_0x423363['data'],'authors':_0x423363['authorsIds']['map'](_0x3481ed=>_0x3bd5e9['getUser'](_0x3481ed)),'createdAt':new Date(_0x423363['createdAt']),'attributes':_0x423363['attributes'],'fromVersion':_0x423363['fromVersion'],'toVersion':_0x423363['toVersion']});}['addRevision'](_0xadaad0,_0x4a3c21=0x0){this['_revisions']['add'](_0xadaad0,_0x4a3c21);}['getRevision'](_0x6e7d72){return this['_revisions']['get'](_0x6e7d72);}['getRevisions'](_0x139397={'toJSON':!0x1}){const _0x3e73d5=Array['from'](this['_revisions']);return _0x3e73d5['reverse'](),_0x139397['toJSON']?_0x3e73d5['map'](_0x48ce39=>_0x48ce39['toJSON']()):_0x3e73d5;}['getIndex'](_0x28b6fc){return this['_revisions']['getIndex'](_0x28b6fc);}['getEarlierVisibleRevision'](_0xfbbafb){const [,_0x50b224]=this['getRevisionsIterator'](_0xfbbafb,{'direction':'earlier'});return _0x50b224;}['getLaterVisibleRevision'](_0x59ee06){const [,_0x3d50ad]=this['getRevisionsIterator'](_0x59ee06,{'direction':'later'});return _0x3d50ad;}['getRevisionsInDiff'](_0x559bea){const _0x551053=[];for(const _0x2f360a of this['getRevisionsIterator'](_0x559bea['newRevisionId']))if(_0x551053['push'](_0x2f360a),_0x2f360a['id']===_0x559bea['oldRevisionId'])break;return _0x551053;}*['getRevisionsIterator'](_0x3fa82c,{direction:_0x20035b='earlier',filter:_0x1a93f5=()=>!0x0}={}){const _0x1775dd='earlier'===_0x20035b?0x1:-0x1;let _0x41bb57=this['_revisions']['get'](_0x3fa82c),_0x3aa626=this['getIndex'](_0x41bb57);for(yield _0x41bb57;_0x41bb57;){if(_0x3aa626+=_0x1775dd,_0x41bb57=this['getRevision'](_0x3aa626),!_0x41bb57)return;_0x1a93f5(_0x41bb57)&&(yield _0x41bb57);}}}class $ extends _0x2bce4d{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x6e2313,'c'],[_0x4ce6b3,'a'],[_0x5d6ad4,'e'],[_0x242d82,'r'],[_0x49d851,'u']]);['_typeCharToViewClass']=new Map([['c',_0x6e2313],['a',_0x4ce6b3],['e',_0x5d6ad4],['r',_0x242d82],['u',_0x49d851]]);async['loadRevisionData'](_0x5317ca,_0x55ed40){if(_0x5317ca['diffData']||!_0x55ed40)return;const _0x16e754=this['editor']['config']['get']('collaboration.channelId'),_0x262771=await _0x55ed40['getRevision']({'channelId':_0x16e754,'revisionId':_0x5317ca['id']});_0x5317ca['diffData']=_0x262771['diffData'];}['getRevisionDocumentData'](_0x379676){const _0x42284b={};for(const _0x33ebdd in _0x379676['diffData']){if(_0x379676['diffData'][_0x33ebdd]['attachChange']&&!_0x379676['diffData'][_0x33ebdd]['attachChange']['isAttached'])continue;const _0x3b0388=this['_removeRevisionMarkers'](JSON['parse'](_0x379676['diffData'][_0x33ebdd]['insertions'])),_0x202b1d=this['editor']['editing']['view']['document'],_0x206c69=new _0x11f4b2(_0x202b1d,_0x3b0388['map'](_0x28684d=>this['_getViewFromDiffObj'](_0x28684d,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x42284b[_0x33ebdd]=this['editor']['data']['processor']['toData'](_0x206c69),this['editor']['data']['processor']['useFillerType']('default');}return _0x42284b;}['getRevisionRootsAttributes'](_0x5e96dc){const _0x3becfc={};for(const _0x2e525f in _0x5e96dc['diffData'])_0x5e96dc['diffData'][_0x2e525f]['attachChange']&&!_0x5e96dc['diffData'][_0x2e525f]['attachChange']['isAttached']||(_0x3becfc[_0x2e525f]=_0x5e96dc['diffData'][_0x2e525f]['attributesAfter']||{});return _0x3becfc;}['_getTypeCharForViewElement'](_0x108c83){return this['_viewClassToTypeChar']['get'](_0x108c83['constructor']);}['_getViewFromDiffObj'](_0x4be165,_0x2a40aa){const _0x36f481=this['editor']['editing']['view']['document'];if('string'==typeof _0x4be165)return new _0x286ad4(_0x36f481,_0x4be165);{let _0x69c0a8,_0x1d2c81;_0x1d2c81='u'==_0x4be165['type']||'r'==_0x4be165['type']?[]:_0x4be165['children']['map'](_0x1dda4e=>this['_getViewFromDiffObj'](_0x1dda4e,_0x2a40aa));const _0x51f2c0=this['_typeCharToViewClass']['get'](_0x4be165['type'])||_0x23f5aa,_0x1828db=this['editor']['data']['htmlProcessor']['domConverter'];if(_0x69c0a8=new _0x51f2c0(_0x36f481,_0x4be165['name'],_0x4be165['attributes'],_0x1d2c81),'u'==_0x4be165['type']&&_0x4be165['children'][0x0]){const _0x4195eb=_0x4be165['children'][0x0];if(_0x69c0a8['render']=function(_0x37575e){const _0x3f7bd0=_0x37575e['createElement']('div');return _0x3f7bd0['innerHTML']=_0x4195eb,_0x3f7bd0['childNodes'][0x0];},_0x2a40aa){const _0x5883a2=new _0x11f4b2(_0x36f481);_0x5883a2['_appendChild'](_0x69c0a8);const _0x186845=Array['from'](_0x1828db['viewChildrenToDom'](_0x5883a2,{'bind':!0x1})),_0xa8377e=_0x1828db['domDocument']['createElement']('div');_0xa8377e['append'](..._0x186845),_0x69c0a8=Array['from'](_0x1828db['domChildrenToView'](_0xa8377e))[0x0];}}else{if('r'==_0x4be165['type']&&_0x4be165['children'][0x0]){const _0x17c023=_0x4be165['children'][0x0];if(_0x69c0a8['render']=function(_0x3f9d4a){_0x3f9d4a['innerHTML']=_0x17c023;},_0x2a40aa){const _0x2371e5=new _0x11f4b2(_0x36f481);_0x2371e5['_appendChild'](_0x69c0a8);const _0x4c58fa=Array['from'](_0x1828db['viewChildrenToDom'](_0x2371e5,{'bind':!0x1})),_0x37941d=_0x1828db['domDocument']['createElement']('div');_0x37941d['append'](..._0x4c58fa);const _0x30639e=Array['from'](_0x1828db['domChildrenToView'](_0x37941d));_0x30639e['length']>0x1?_0x69c0a8['_appendChild'](_0x30639e):_0x69c0a8=_0x30639e[0x0];}}}if(_0x4be165['customProperties']){for(const [_0x15a433,_0x393111]of _0x4be165['customProperties'])_0x69c0a8['_setCustomProperty'](_0x15a433,_0x393111);}const _0x43d7ed=void 0x0===_0x4be165['fillerOffset']?null:_0x4be165['fillerOffset'];return null!==_0x43d7ed&&(_0x69c0a8['getFillerOffset']=()=>_0x43d7ed),_0x69c0a8;}}['_makeModelFromViewString'](_0x343972){const _0x2590d8=JSON['parse'](_0x343972),_0x56dfb4=this['editor']['editing']['view']['document'],_0x344acb=new _0x11f4b2(_0x56dfb4,_0x2590d8['map'](_0x3d5989=>this['_getViewFromDiffObj'](_0x3d5989,!0x0)));return this['editor']['data']['toModel'](_0x344acb);}['_removeRevisionMarkers'](_0x26edc4){return(_0x26edc4=_0x26edc4['filter'](_0x3ee896=>!_0x3ee896['name']||'revision-start'!==_0x3ee896['name']&&'revision-end'!==_0x3ee896['name']))['forEach'](_0x3df0f4=>{'string'!=typeof _0x3df0f4&&(_0x3df0f4['children']=this['_removeRevisionMarkers'](_0x3df0f4['children']),_0x3df0f4['attributes']=_0x3df0f4['attributes']['filter'](_0x4e36d1=>!_0x4e36d1[0x0]['startsWith']('data-revision-')));}),_0x26edc4;}}function m(_0x41152e,_0x3092df,_0xbe60d6){const t=_0x41152e['t'];switch(_0x3092df){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'},_0xbe60d6);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0xbe60d6);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 _0x2bce4d{['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[_0x729304,S,$,_0x5a0857];}constructor(_0x6da23e){super(_0x6da23e),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 _0x473ce8=_0x3bb1d9();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x473ce8},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 _0x3684c5=this['repository']['getRevision'](0x0),_0xb8a2d9=_0x3684c5&&null===_0x3684c5['creator']?_0x3684c5:null;if(this['_continueCurrentRevision']=!!_0xb8a2d9&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x22e506=this['_source']['getCurrentRevisionId'](),_0x2f3339=this['repository']['getRevision'](_0x22e506);if(_0x2f3339)this['_startingVersion']=_0x2f3339['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x5c6614=this['_source']['history']['_operations']['find'](_0x1939d3=>!_0x1939d3['_isInit']),_0x304420=_0x5c6614?_0x5c6614['baseVersion']:this['_source']['history']['version'];_0x3684c5?(_0x3684c5['toVersion']<_0x304420&&_0x3684c5['_update']({'toVersion':_0x304420}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0xb8a2d9['id'],this['_startingVersion']=_0xb8a2d9['fromVersion']):(this['_startingVersion']=_0x3684c5['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x304420,this['_continueCurrentRevision']=!0x1);}}else _0xb8a2d9&&(this['editor']['model']['document']['history']['version']=Math['max'](_0xb8a2d9['toVersion'],this['editor']['model']['document']['history']['version']),_0xb8a2d9['fromVersion']===_0xb8a2d9['toVersion']?(0x0!==_0xb8a2d9['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0xb8a2d9['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0xb8a2d9['id'],this['_startingVersion']=_0xb8a2d9['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',_0xff3c51=>!_0xff3c51),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x1f0c09=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x25211d;for(const _0x4a37d6 in _0x1f0c09){const _0xf5f11a=_0x4a37d6,_0x449183=_0x1f0c09[_0xf5f11a];if('revisionHistoryLicenseKeyValid'==_0x449183||'revisionHistoryLicenseKeyInvalid'==_0x449183||'revisionHistoryLicenseKeyExpired'==_0x449183||'revisionHistoryLicenseKeyDomainLimit'==_0x449183||'revisionHistoryLicenseKeyNotAllowed'==_0x449183||'revisionHistoryLicenseKeyEvaluationLimit'==_0x449183||'revisionHistoryLicenseKeyTrialLimit'==_0x449183||'revisionHistoryLicenseKeyUsageLimit'==_0x449183){delete _0x1f0c09[_0xf5f11a],_0x25211d=_0x449183,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x25211d&&_0x1f0c09['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x25211d&&_0x1f0c09['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x25211d&&_0x1f0c09['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x25211d&&_0x1f0c09['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x25211d&&_0x1f0c09['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x25211d&&_0x1f0c09['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x25211d&&_0x1f0c09['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x40f73c=this['repository']['getRevision'](0x0),_0x4c0f19=await this['getRevisionDocumentData'](_0x40f73c),_0x232bcd=await this['getRevisionRootsAttributes'](_0x40f73c);this['_replaceEditorDataWithRevisionData'](_0x4c0f19,_0x232bcd);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x1e5860){this['_source']=_0x1e5860;}async['update'](){const _0x556b72=await this['_source']['getLatestVersion']();if(_0x556b72>this['currentRevision']['toVersion']){await this['_loadState']();const _0x519fbc=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x556b72});_0x519fbc['authors']=_0x519fbc['authorsIds']['map'](_0x1f21f0=>this['editor']['plugins']['get']('Users')['getUser'](_0x1f21f0)),this['currentRevision']['_update'](_0x519fbc);}}async['saveRevision'](_0xd17027={},_0x50350e=null){const _0x143ed3=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x50350e>this['currentRevision']['toVersion']&&(_0x50350e=null),null===_0x50350e&&(_0x50350e=await this['_source']['getLatestVersion']());const _0x89dfd0=this['_getFromVersion'](_0x50350e),_0x8646c2=this['buildRevisionData']({'from':_0x89dfd0,'to':_0x50350e});if(this['currentRevision']['toVersion']<_0x50350e){const _0x44d08c=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x50350e,'to':_0x50350e});_0x44d08c['authors']=[],_0x44d08c['authorsIds']=[],_0x44d08c['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x44d08c,!0x0),delete _0x44d08c['authors'],_0x143ed3['push'](_0x44d08c);}_0xd17027['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0xd17027['name']=_0xd17027['name']||null,_0xd17027['id']=_0xd17027['id']||_0x3bb1d9(),_0xd17027={..._0xd17027,..._0x8646c2};const _0x24c5c1=this['addRevisionData'](_0xd17027);_0x143ed3['push'](_0xd17027);const _0x2e77a3=this['repository']['getIndex'](_0x24c5c1);if(0x0!==_0x2e77a3){const _0x4610e4=this['repository']['getRevision'](_0x2e77a3-0x1);if(_0x4610e4['fromVersion']!==_0x50350e){const _0x16114e=this['_revisionDataBuilder']['getData'](_0x50350e,_0x4610e4['toVersion']),_0x4f28e7={'id':_0x4610e4['id'],'diffData':_0x16114e['diffData'],'authorsIds':_0x16114e['authorsIds'],'authors':_0x16114e['authorsIds']['map'](_0x19e5b3=>this['editor']['plugins']['get']('Users')['getUser'](_0x19e5b3)),'fromVersion':_0x50350e};_0x4610e4===this['currentRevision']&&(_0x4f28e7['createdAt']=new Date(_0xd17027['createdAt']['getTime']()+0xa)),_0x4610e4['_update'](_0x4f28e7,!0x0),delete _0x4f28e7['authors'],_0x143ed3['push'](_0x4f28e7);}}if(this['adapter']){for(const _0x4caeec of _0x143ed3)this['_bufferUpdate'](_0x4caeec['id'],_0x4caeec,!0x0);this['sendBufferedUpdates']();}return _0x24c5c1;}['addRevisionData'](_0x3c307a){const _0x6b0b46=this['repository']['createRevision'](_0x3c307a);return this['adapter']&&_0x6b0b46['on']('_update',(_0x4414a6,_0x55d277,_0x4b3295)=>{_0x4b3295||(this['_bufferUpdate'](_0x55d277['id'],_0x55d277,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x6b0b46,this['_findInsertionIndex'](_0x6b0b46)),_0x6b0b46;}async['getRevisionDocumentData'](_0x4e0d3a){return await this['_utils']['loadRevisionData'](_0x4e0d3a,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x4e0d3a);}async['getRevisionRootsAttributes'](_0x48af5e){return await this['_utils']['loadRevisionData'](_0x48af5e,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x48af5e);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x2aa735=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x1ec8ec=0x0;_0x1ec8ec<_0x2aa735['length'];_0x1ec8ec++){const _0x51e3c5=_0x2aa735[_0x1ec8ec];let _0x1a94fa=!0x1;for(const _0x5c8037 of Object['keys'](_0x51e3c5))void 0x0===_0x51e3c5[_0x5c8037]?delete _0x51e3c5[_0x5c8037]:'id'!==_0x5c8037&&(_0x1a94fa=!0x0);_0x1a94fa||(_0x2aa735[_0x1ec8ec]=null);}if(_0x2aa735=_0x2aa735['filter'](_0x2435c6=>null!==_0x2435c6),!_0x2aa735['length'])return;for(let _0x1c391f=0x0;_0x1c391f<_0x2aa735['length'];_0x1c391f++){const _0x140c1f=_0x2aa735[_0x1c391f];void 0x0!==_0x140c1f['fromVersion']&&void 0x0===_0x140c1f['toVersion']&&(_0x140c1f['toVersion']=this['repository']['getRevision'](_0x140c1f['id'])['toVersion']),void 0x0!==_0x140c1f['toVersion']&&void 0x0===_0x140c1f['fromVersion']&&(_0x140c1f['fromVersion']=this['repository']['getRevision'](_0x140c1f['id'])['fromVersion']);}const _0x550e3c=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x2aa735,_0x550e3c)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x1554f0=>{if(_0x1554f0){for(const _0x5743e7 of _0x1554f0)this['setRevisionData']({'id':_0x5743e7['id'],'createdAt':_0x5743e7['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0x54ddad=null,from:_0xd68000=null,to:_0x5fc6b3=null}){_0xd68000=null!==_0xd68000?_0xd68000:_0x54ddad['fromVersion'],_0x5fc6b3=null!==_0x5fc6b3?_0x5fc6b3:_0x54ddad['toVersion'];const _0x45fad0=this['_revisionDataBuilder']['getData'](_0xd68000,_0x5fc6b3),_0x5b07f1={'diffData':_0x45fad0['diffData'],'authorsIds':_0x45fad0['authorsIds'],'fromVersion':_0xd68000,'toVersion':_0x5fc6b3};if(!_0x54ddad||_0x5fc6b3!==_0x54ddad['toVersion']){const _0x3d9657=_0x5fc6b3-0x1,_0xf3e37e=this['_source']['history']['getOperation'](_0x3d9657);_0x5b07f1['createdAt']=_0xf3e37e&&_0xf3e37e['createdAt']||new Date();}if(this['_loadedStateData']&&_0xd68000===this['_loadedStateData']['fromVersion']){for(const _0x5eb783 of this['_loadedStateData']['authors'])_0x5b07f1['authorsIds']['includes'](_0x5eb783['id'])||_0x5b07f1['authorsIds']['push'](_0x5eb783['id']);}return _0x5b07f1;}['_bufferUpdate'](_0xe15bd1,_0x4d8512,_0x3be38e){if(this['_bufferedUpdates']['has'](_0xe15bd1)){const _0x3b8e85=this['_bufferedUpdates']['get'](_0xe15bd1);_0x4d8512=_0x3be38e?{..._0x3b8e85,..._0x4d8512}:{..._0x4d8512,..._0x3b8e85};}this['_bufferedUpdates']['set'](_0xe15bd1,_0x4d8512);}['setRevisionData'](_0x500f40){const _0x10098c=this['repository']['getRevision'](_0x500f40['id']);if(_0x500f40['createdAt']&&(_0x500f40['createdAt']=new Date(_0x500f40['createdAt'])),_0x500f40['authorsIds']){const _0x172cc1=this['editor']['plugins']['get']('Users');_0x500f40['authors']=_0x500f40['authorsIds']['map'](_0x2cad89=>_0x172cc1['getUser'](_0x2cad89));}_0x10098c['_update'](_0x500f40,!0x0);}['_createInitialRevision'](_0x317b83){const _0x142d05=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x142d05)this['_initialRevisionId']=_0x142d05['id'];else{const _0x46ad60=!this['editor']['model']['document']['roots']['find'](_0x1c79fe=>this['editor']['model']['hasContent'](_0x1c79fe)),_0x238f9e=this['editor']['plugins']['get']('Users')['me']['id'],_0x51bf21=m(this['editor']['locale'],_0x46ad60?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x317b83,'to':_0x317b83,'id':this['_initialRevisionId'],'name':_0x51bf21,'creatorId':_0x238f9e});}}['_createCurrentRevision'](_0xd304e3){const _0x3e7acd=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x3e7acd),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0xd304e3,'to':_0xd304e3,'id':_0x3e7acd,'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'](_0x16a9a6,_0x481ead){let _0x550780=this['editor']['config']['get']('initialData'),_0x432599=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x550780){_0x550780={};for(const _0x417f3c of this['editor']['model']['document']['getRootNames']())_0x550780[_0x417f3c]='';}if('string'==typeof _0x550780&&(_0x550780={'main':_0x550780}),void 0x0===_0x432599){_0x432599={};for(const _0x19db68 of this['editor']['model']['document']['getRootNames']())_0x432599[_0x19db68]={};}let _0x21c4bc=!0x1;const _0x87d774=Object['keys'](_0x550780),_0x1ab652=Object['keys'](_0x16a9a6);for(const _0x4a9ff0 of _0x87d774){if(_0x550780[_0x4a9ff0]!==_0x16a9a6[_0x4a9ff0]&&''!==_0x550780[_0x4a9ff0]['trim']()){_0x21c4bc=!0x0;break;}if(!_0x588fc7(_0x432599[_0x4a9ff0],_0x481ead[_0x4a9ff0])&&Object['keys'](_0x432599[_0x4a9ff0])['length']>0x0){_0x21c4bc=!0x0;break;}}_0x21c4bc||(_0x21c4bc=_0x1ab652['some'](_0x264df6=>!this['editor']['model']['document']['getRoot'](_0x264df6))),_0x21c4bc&&_0x823218('editor-initial-data-replaced-with-revision-data',{'editorData':_0x550780,'editorRootsAttributes':_0x432599,'revisionData':_0x16a9a6,'revisionRootsAttributes':_0x481ead}),this['editor']['config']['set']('initialData',_0x16a9a6),this['editor']['config']['set']('rootsAttributes',_0x481ead);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x42219f=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x42219f['add'](m(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x986f3b){const _0x44562e=this['repository']['getRevisions']();_0x44562e['reverse']();let _0x26d9e0=0x0;for(;_0x26d9e0<_0x44562e['length'];){const _0x4464c9=_0x44562e[_0x26d9e0];if(_0x4464c9===this['currentRevision']){_0x26d9e0++;continue;}if(_0x4464c9['id']===this['_initialRevisionId'])break;const _0x3a9780=_0x986f3b['toVersion']-_0x4464c9['toVersion']||_0x986f3b['fromVersion']-_0x4464c9['fromVersion'];if(_0x3a9780>0x0)break;if(_0x3a9780<0x0)_0x26d9e0++;else{if(!_0x986f3b['creator']&&_0x4464c9['creator'])break;if(_0x4464c9['creator']||!_0x986f3b['creator']){if(_0x986f3b['createdAt']>_0x4464c9['createdAt'])break;_0x26d9e0++;}else _0x26d9e0++;}}return _0x26d9e0;}['_getFromVersion'](_0x159157){const _0x2f4ed3=this['repository']['getRevisions']();_0x2f4ed3['reverse'](),_0x2f4ed3['shift']();const _0x379ea9=_0x2f4ed3['find'](_0x25e80a=>_0x25e80a['toVersion']<=_0x159157)['toVersion'];return _0x379ea9<this['_startingVersion']?this['_startingVersion']:_0x379ea9;}['_makeRevision']({name:_0x49b1e5,from:_0x408d34,to:_0x3f3d1a,creatorId:_0x3eed52,id:_0x16a980}){const _0x175c1b=this['buildRevisionData']({'from':_0x408d34,'to':_0x3f3d1a});_0x175c1b['name']=_0x49b1e5,_0x175c1b['creatorId']=_0x3eed52,_0x175c1b['id']=_0x16a980;const _0x40a1cd=this['addRevisionData'](_0x175c1b);return this['adapter']&&this['_bufferUpdate'](_0x175c1b['id'],_0x175c1b,!0x0),_0x40a1cd;}['_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(_0x578109){this['editor']=_0x578109,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'](_0x3337fb){this['source']=_0x3337fb;const _0x2fb9e7=new Map(),_0x2c9dbf=new Map(),_0x20b6d7=this['editor']['model']['document']['roots']['map'](_0x356908=>_0x356908['rootName']);for(const _0x539f8a of _0x20b6d7){const _0x329024=this['editor']['model']['document']['getRoot'](_0x539f8a),_0x106db2=x(_0x329024);_0x2fb9e7['set'](_0x539f8a,_0x106db2),_0x2c9dbf['set'](_0x539f8a,Object['fromEntries'](_0x329024['getAttributes']()));}const _0x586a76=Array['from'](this['editor']['model']['markers'])['map'](_0x3235eb=>[_0x3235eb['name'],_0x3235eb['getRange']()]),_0x319720=this['source']['version'];this['_saveMetaData'](_0x319720,_0x2fb9e7,_0x586a76,_0x2c9dbf),this['_startingRevisionId']=this['_revisionId'];const _0x3bce85=new Map(),_0x56addb=new Map();for(const _0x1117a1 of _0x20b6d7){const _0x1f1729=N(_0x1117a1);_0x3bce85['set'](_0x1117a1,_0x1f1729),_0x56addb['set'](_0x1117a1,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x3bce85,[],_0x56addb);}['getData'](_0x50e13c,_0x27b8eb){if(this['_lastFrom']===_0x50e13c&&this['_lastTo']<=_0x27b8eb)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x27b8eb,!0x0);else{if(!this['_savedMetaData']['has'](_0x50e13c)){const _0x1335b3=this['_getPreviousFrom'](_0x50e13c);this['_calculateMetaData'](_0x1335b3,_0x50e13c,!0x1);}this['_calculateMetaData'](_0x50e13c,_0x27b8eb,!0x0);}return this['_lastFrom']=_0x50e13c,this['_lastTo']=_0x27b8eb,this['_getState']();}['loadState'](_0x2cd645){if(!this['_savedMetaData']['has'](_0x2cd645['fromVersion'])){const _0xb41f4f=this['_getPreviousFrom'](_0x2cd645['fromVersion']);this['_calculateMetaData'](_0xb41f4f,_0x2cd645['fromVersion'],!0x1);}this['_calculateMetaData'](_0x2cd645['fromVersion'],_0x2cd645['toVersion'],!0x1);const _0x29c417=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x2cd645['fromVersion'],this['_lastTo']=_0x2cd645['toVersion'];for(const _0x2f7bb0 in _0x2cd645['diffData']){const _0x5c8841=_0x2cd645['diffData'][_0x2f7bb0]['attachChange'],_0x2cfb82=_0x1f8919(_0x2cd645['diffData'][_0x2f7bb0]['attributesBefore'])||{},_0x4b6666=_0x29c417['_makeModelFromViewString'](_0x2cd645['diffData'][_0x2f7bb0]['deletions']);_0x4b6666['rootName']=_0x2f7bb0,_0x4b6666['_isAttached']=!_0x5c8841||!_0x5c8841['isAttached'],_0x4b6666['isAttached']=()=>_0x4b6666['_isAttached'],this['_baseRoots']['set'](_0x2f7bb0,_0x4b6666),this['_baseRootsAttributes']['set'](_0x2f7bb0,_0x2cfb82),_0x5c8841&&this['_touchedRoots']['set'](_0x2f7bb0,_0x5c8841);const _0xc2379=this['_makeIdsRoot'](_0x4b6666);this['_baseIdsRoots']['set'](_0x2f7bb0,_0xc2379);for(const [_0x3b7a93,_0x46b8a4]of _0x4b6666['markers']){if(!_0x3b7a93['startsWith']('revision:'))continue;const _0x44eea4=_0x3b7a93['split'](':')[0x2];for(const _0x3ed489 of _0x46b8a4['getWalker']({'singleCharacters':!0x0})){const _0x1af86d=this['_getVidAttributeName'](_0x3ed489),_0x10df4e='elementEnd'==_0x3ed489['type']?_0x3ed489['previousPosition']['path']['slice'](0x0,-0x1):_0x3ed489['previousPosition']['path'],_0x5bc0f9=_0xc2379['getNodeByPath'](_0x10df4e)['getAttribute'](_0x1af86d);this['_touched']['set'](_0x5bc0f9,{'userId':_0x44eea4});}}}this['_startingRevisionId']=this['_revisionId'];const _0x1b777e=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x228280=>!this['_touched']['has'](_0x228280));let _0x14065b=0x0;const _0x23a84f=new Map();for(const _0x4815f in _0x2cd645['diffData']){const _0x4c771a=_0x2cd645['diffData'][_0x4815f]['attachChange'],_0x5981e7=_0x1f8919(_0x2cd645['diffData'][_0x4815f]['attributesAfter'])||{},_0x228f1b=_0x29c417['_makeModelFromViewString'](_0x2cd645['diffData'][_0x4815f]['insertions']);_0x228f1b['rootName']=_0x4815f,_0x228f1b['_isAttached']=!_0x4c771a||_0x4c771a['isAttached'],_0x228f1b['isAttached']=()=>_0x228f1b['_isAttached'],this['_diffRoots']['set'](_0x4815f,_0x228f1b),this['_diffRootsAttributes']['set'](_0x4815f,_0x5981e7);const _0x174086=this['_makeIdsRoot'](_0x228f1b,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x4815f,_0x174086),_0x23a84f['set'](_0x4815f,_0x228f1b['isAttached']()?_0x5981e7:{});for(const [_0x39119a,_0x15c344]of _0x228f1b['markers']){if(!_0x39119a['startsWith']('revision:'))continue;const _0x5d57f5=_0x39119a['split'](':')[0x2];for(const _0x51e9b4 of _0x15c344['getWalker']({'singleCharacters':!0x0})){const _0x3f5fa3=this['_getVidAttributeName'](_0x51e9b4),_0x75089=this['_revisionId']++,_0x1c4818='elementEnd'==_0x51e9b4['type']?_0x51e9b4['previousPosition']['path']['slice'](0x0,-0x1):_0x51e9b4['previousPosition']['path'];_0x174086['getNodeByPath'](_0x1c4818)['_setAttribute'](_0x3f5fa3,_0x75089),this['_touched']['set'](_0x75089,{'userId':_0x5d57f5});}}for(const _0x48ec55 of this['editor']['model']['createRangeIn'](_0x228f1b)['getWalker']({'singleCharacters':!0x0})){const _0x11ab83=this['_getVidAttributeName'](_0x48ec55),_0x192101='elementEnd'==_0x48ec55['type']?_0x48ec55['previousPosition']['path']['slice'](0x0,-0x1):_0x48ec55['previousPosition']['path'],_0x22058f=_0x174086['getNodeByPath'](_0x192101);_0x22058f['getAttribute'](_0x11ab83)>0x0||_0x22058f['_setAttribute'](_0x11ab83,_0x1b777e[_0x14065b++]);}for(const [_0xc98ab6,_0x430e26]of _0x228f1b['markers'])_0xc98ab6['startsWith']('revision:')||this['_markers']['set'](_0xc98ab6,_0x430e26);}const {roots:_0x5af7ec}=this['_savedMetaData']['get'](_0x2cd645['fromVersion']),{roots:_0xdf1962}=this['_savedMetaData']['get'](_0x2cd645['toVersion']),_0x47c24a=x(_0x5af7ec['get']('$graveyard'));this['_baseRoots']['set']('$graveyard',_0x47c24a),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x47c24a,Number['NEGATIVE_INFINITY']));const _0x2fc013=x(_0xdf1962['get']('$graveyard'));this['_diffRoots']['set']('$graveyard',_0x2fc013),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x2fc013));const _0x4e786f=Array['from'](this['_diffRoots'])['map'](([_0x2cbd4b,_0xcf90d9])=>[_0x2cbd4b,x(_0xcf90d9)]);this['_saveMetaData'](this['_lastTo'],_0x4e786f,this['_markers'],_0x23a84f);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0xc42ffc,_0x219b8c,_0x8529d0,_0x330f9e){const _0x398a38=new Map(_0x219b8c),_0x3e5e51=new Map(_0x1f8919(_0x330f9e)),_0x7d65a4=new Map();for(const [_0x4fd83b,_0x23fa09]of _0x8529d0)_0x7d65a4['set'](_0x4fd83b,{'start':_0x23fa09['start']['clone'](),'end':_0x23fa09['end']['clone'](),'rootName':_0x23fa09['root']['rootName']});this['_savedMetaData']['set'](_0xc42ffc,{'roots':_0x398a38,'markers':_0x7d65a4,'rootsAttributes':_0x3e5e51});}['_removeMetaData'](_0x319eeb){this['_savedMetaData']['delete'](_0x319eeb);}['_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'](_0x15a9fb,_0x35305a=null){let _0xcd2dfd=null;_0x15a9fb['is']('documentFragment')||(_0xcd2dfd=new _0x41b3fc(_0x15a9fb['name'],{'vid_start':null===_0x35305a?this['_revisionId']++:_0x35305a++}));const _0x54ad2e=[];for(const _0x1debb of _0x15a9fb['getChildren']())if(_0x1debb['is']('element')){_0x54ad2e['push'](this['_makeIdsRoot'](_0x1debb,_0x35305a));const _0x181b0f=_0x54ad2e[_0x54ad2e['length']-0x1];null!==_0x35305a&&(_0x35305a=_0x181b0f['is']('element','$text')?_0x181b0f['getAttribute']('vid')+0x1:_0x181b0f['getAttribute']('vid_end')+0x1);}else{for(let _0x103b0e=0x0;_0x103b0e<_0x1debb['offsetSize'];_0x103b0e++)_0x54ad2e['push'](new _0x41b3fc('$text',{'vid':null===_0x35305a?this['_revisionId']++:_0x35305a++}));}if(_0x15a9fb['is']('documentFragment')){const _0x35931b=N(_0x15a9fb['rootName']);return _0x35931b['_insertChild'](0x0,_0x54ad2e),_0x35931b;}return _0xcd2dfd['_setAttribute']('vid_end',null===_0x35305a?this['_revisionId']++:_0x35305a++),_0xcd2dfd['_insertChild'](0x0,_0x54ad2e),_0xcd2dfd;}['_calculateMetaData'](_0x10783e,_0x1119c8,_0xc506aa){this['_reset']();const {roots:_0x35aaab,markers:_0x4bd2b7,rootsAttributes:_0x5b9d8a}=this['_savedMetaData']['get'](_0x10783e);this['_baseRoots']=new Map(_0x35aaab),this['_baseRootsAttributes']=new Map(_0x1f8919(_0x5b9d8a));for(const [_0x40baad,_0x15bd73]of this['_baseRoots'])if('$graveyard'!==_0x40baad&&(this['_diffRoots']['set'](_0x40baad,x(_0x15bd73)),this['_diffRootsAttributes']=new Map(_0x1f8919(_0x5b9d8a)),_0xc506aa)){const _0x2e38d8=this['_revisionId'];this['_idsRoots']['set'](_0x40baad,this['_makeIdsRoot'](_0x15bd73)),this['_baseIdsRoots']['set'](_0x40baad,this['_makeIdsRoot'](_0x15bd73,_0x2e38d8));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',x(this['_baseRoots']['get']('$graveyard'))),_0xc506aa&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x2b4bfe,_0x4e3ba0]of _0x4bd2b7){const _0x126ea8=this['_baseRoots']['get'](_0x4e3ba0['rootName']),_0x4044e4=this['_diffRoots']['get'](_0x4e3ba0['rootName']),_0x41f315=new _0x1340e0(this['_fixPosition'](_0x4e3ba0['start'],_0x126ea8),this['_fixPosition'](_0x4e3ba0['end'],_0x126ea8)),_0x5604a0=this['_fixRange'](_0x41f315,_0x4044e4);_0x126ea8['markers']['set'](_0x2b4bfe,_0x41f315),this['_markers']['set'](_0x2b4bfe,_0x5604a0);}this['_applyOperations'](_0x10783e,_0x1119c8,_0xc506aa);}['_applyOperations'](_0x9a88de,_0x426643,_0x5774b3){for(const _0x2eaf97 of this['source']['getOperations'](_0x9a88de,_0x426643))this['_handleOperation'](_0x2eaf97,_0x5774b3);for(const _0x3eaaa7 of this['_diffRoots']['values']())_0x3eaaa7['markers']['clear']();for(const [_0x10c58c,_0x416278]of this['_markers']){this['_diffRoots']['get'](_0x416278['root']['rootName'])['markers']['set'](_0x10c58c,_0x416278['clone']());}const _0x712e84=new Map(),_0x5ac358=new Map();for(const [_0x23a541,_0x26715b]of this['_diffRoots'])_0x712e84['set'](_0x23a541,x(_0x26715b)),_0x5ac358['set'](_0x23a541,this['_diffRootsAttributes']['get'](_0x23a541));this['_saveMetaData'](_0x426643,_0x712e84,this['_markers'],_0x5ac358);}['_getPreviousFrom'](_0x545838){const _0x20d274=Array['from'](this['_savedMetaData']['keys']());_0x20d274['sort']((_0x51af08,_0x40ae93)=>_0x51af08-_0x40ae93),_0x20d274['reverse']();for(const _0x22fa2b of _0x20d274)if(_0x22fa2b<_0x545838)return _0x22fa2b;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x4dfd43,_0xc1f0f4){const _0xad64ba=Array['from'](_0xc1f0f4['markers'])['map'](([_0x2f2439,_0x253b0a])=>[_0x2f2439,this['_fixRange'](_0x253b0a,_0x4dfd43)]);_0x4dfd43['markers']=new Map(_0xad64ba);}['_transformMarkers'](_0x7db8a3){for(const _0x5378fe of this['_markers']['values']()){const _0x22da49=_0x5378fe['getTransformedByOperation'](_0x7db8a3),_0x13526b=_0x1340e0['_createFromRanges'](_0x22da49);_0x5378fe['start']=_0x13526b['start'],_0x5378fe['end']=_0x13526b['end'];}}['_handleOperation'](_0x2770f6,_0x4c9bf1){if('addRoot'!=_0x2770f6['type']&&'detachRoot'!=_0x2770f6['type']){if('insert'==_0x2770f6['type']){const _0x4441ae=_0x2770f6['position']['root']['rootName'];this['_diffRoots']['has'](_0x4441ae)||(this['_diffRoots']['set'](_0x4441ae,N(_0x4441ae,!0x0)),this['_diffRootsAttributes']['set'](_0x4441ae,{}),_0x4c9bf1&&this['_idsRoots']['set'](_0x4441ae,N(_0x4441ae,!0x0)));}else{if('addRootAttribute'==_0x2770f6['type']||'removeRootAttribute'==_0x2770f6['type']||'changeRootAttribute'==_0x2770f6['type'])return void this['_handleRootAttributeOperation'](_0x2770f6);'marker'==_0x2770f6['type']&&this['_handleMarkerOperation'](_0x2770f6);}if('marker'!==_0x2770f6['type']){const _0x45b7f5=this['_cloneOperation'](_0x2770f6,this['_diffRoots']);_0x45b7f5['_execute'](),this['_transformMarkers'](_0x45b7f5);}if(_0x4c9bf1)switch(_0x2770f6['type']){case'insert':this['_handleInsertOperation'](_0x2770f6);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x2770f6);break;case'merge':this['_handleMergeOperation'](_0x2770f6);break;case'split':this['_handleSplitOperation'](_0x2770f6);}}else this['_handleRootOperation'](_0x2770f6,_0x4c9bf1);}['_cloneOperation'](_0x420a71,_0x2e502b){const _0x582490=_0x420a71['clone']();return _0x582490['_authorId']=_0x420a71['_authorId'],this['_fixOperation'](_0x582490,_0x2e502b),_0x582490;}['_getBaseVids'](_0x5eb001){return _0x5eb001['map'](_0x1c2b2b=>{const _0x21ad5e=this['_getVidAttributeName'](_0x1c2b2b);return Number(_0x1c2b2b['item']['getAttribute'](_0x21ad5e));});}['_generateTape'](_0x5792b7,_0x37b2c8){if(_0x5792b7['is']('element','$text'))_0x37b2c8['push']({'item':_0x5792b7,'type':'text'});else{_0x5792b7['is']('element')&&_0x37b2c8['push']({'item':_0x5792b7,'type':'elementStart'});for(const _0xe51e2e of _0x5792b7['getChildren']())this['_generateTape'](_0xe51e2e,_0x37b2c8);_0x5792b7['is']('element')&&_0x37b2c8['push']({'item':_0x5792b7,'type':'elementEnd'});}return _0x37b2c8;}['_getState'](){const _0x27f4f3=new Map(this['_touched']),_0x34d86f=new Map(_0x27f4f3),_0x2429fc=new Map(),_0x4fdbdc={'insertions':{},'deletions':{}},_0x1215ea={'insertions':{},'deletions':{}},_0x413eae=new Map(),_0x3b4734=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x3b4734['delete']('$graveyard');for(const _0x1cc3b5 of _0x3b4734){const _0x302691=this['_diffRoots']['get'](_0x1cc3b5)||N(_0x1cc3b5,!0x1),_0x1b6ff5=this['_baseRoots']['get'](_0x1cc3b5)||N(_0x1cc3b5,!0x1);_0x302691['isAttached']()||_0x1b6ff5['isAttached']()?(_0x4fdbdc['insertions'][_0x1cc3b5]=x(_0x302691),_0x4fdbdc['deletions'][_0x1cc3b5]=x(_0x1b6ff5),this['_copyMarkers'](_0x4fdbdc['deletions'][_0x1cc3b5],_0x1b6ff5),this['_copyMarkers'](_0x4fdbdc['insertions'][_0x1cc3b5],_0x302691),_0x1215ea['insertions'][_0x1cc3b5]=this['_generateTape'](this['_idsRoots']['get'](_0x1cc3b5),[]),_0x1215ea['deletions'][_0x1cc3b5]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x1cc3b5)||N(_0x1cc3b5,!0x1),[])):_0x3b4734['delete'](_0x1cc3b5);}for(const _0x333a05 of _0x3b4734){const _0x5eb207=_0x1215ea['insertions'][_0x333a05];for(const _0x15f605 of _0x5eb207){const _0x4f5d1e=this['_getVidAttributeName'](_0x15f605),_0x47926d=_0x15f605['item']['getAttribute'](_0x4f5d1e);_0x34d86f['delete'](_0x47926d),_0x47926d>=this['_startingRevisionId']&&_0x2429fc['set'](_0x47926d,_0x27f4f3['get'](_0x47926d));}}for(const _0x47bc7f of _0x3b4734){const _0x18d397=_0x1215ea['insertions'][_0x47bc7f],_0x3b2479=this['_getBaseVids'](_0x1215ea['deletions'][_0x47bc7f]);let _0x2b654c=0x0;for(const _0x5177dd of _0x18d397){const _0x45f88f=this['_getVidAttributeName'](_0x5177dd),_0x416b6f=_0x5177dd['item']['getAttribute'](_0x45f88f);if(!_0x2429fc['has'](_0x416b6f)&&!_0x413eae['has'](_0x416b6f)){if(_0x34d86f['has'](_0x416b6f))_0x2b654c++;else{if(_0x416b6f!=_0x3b2479[_0x2b654c]){const _0x1d19e1=_0x27f4f3['get'](_0x416b6f)||_0x27f4f3['get'](_0x3b2479[_0x2b654c]);for(;_0x416b6f!=_0x3b2479[_0x2b654c];)_0x34d86f['has'](_0x3b2479[_0x2b654c])||(_0x413eae['set'](_0x3b2479[_0x2b654c],_0x1d19e1),_0x27f4f3['set'](_0x3b2479[_0x2b654c],_0x1d19e1)),_0x2b654c++;}_0x2b654c++;}}}}for(const _0x270e43 of _0x3b4734){const _0xa2161a=_0x1215ea['insertions'][_0x270e43];for(const _0x38c43e of _0xa2161a){const _0x3e8895=this['_getVidAttributeName'](_0x38c43e),_0x5be0d7=_0x38c43e['item']['getAttribute'](_0x3e8895);if(_0x413eae['has'](_0x5be0d7)){const _0x27d85f=_0x413eae['get'](_0x5be0d7);_0x34d86f['has'](_0x5be0d7)||_0x34d86f['set'](_0x5be0d7,{..._0x27d85f}),_0x2429fc['set'](_0x5be0d7,{..._0x27d85f});}}}for(const _0x2f0011 of _0x34d86f['keys']())_0x2f0011>=this['_startingRevisionId']&&_0x34d86f['delete'](_0x2f0011);const _0x35491f=new Map();for(const _0x5eb735 of _0x3b4734){let _0x54a4e0=_0x1215ea['insertions'][_0x5eb735];for(const _0x4c9882 of _0x54a4e0)if(_0x4c9882['item']['is']('element','tableCell')){const _0xa5b556=this['_getVidAttributeName'](_0x4c9882),_0x417b34=_0x4c9882['item']['getAttribute'](_0xa5b556);if(_0x2429fc['has'](_0x417b34)){const _0x7678b5=_0x4c9882['item']['parent']['parent']['getAttribute']('vid_start'),_0x2ab833=_0x35491f['get'](_0x7678b5)||new Set();_0x2ab833['add'](_0x2429fc['get'](_0x417b34)['userId']),_0x35491f['set'](_0x7678b5,_0x2ab833);}}_0x54a4e0=_0x1215ea['deletions'][_0x5eb735];for(const _0x5911ea of _0x54a4e0)if(_0x5911ea['item']['is']('element','tableCell')){const _0x1c6819=this['_getVidAttributeName'](_0x5911ea),_0x2f6f36=_0x5911ea['item']['getAttribute'](_0x1c6819);if(_0x34d86f['has'](_0x2f6f36)){const _0x56f34a=_0x5911ea['item']['parent']['parent']['getAttribute']('vid_start'),_0x2ccfb6=_0x35491f['get'](_0x56f34a)||new Set();_0x2ccfb6['add'](_0x34d86f['get'](_0x2f6f36)['userId']),_0x35491f['set'](_0x56f34a,_0x2ccfb6);}}for(const _0x52e39f of _0x35491f['keys']())(_0x2429fc['has'](_0x52e39f)||_0x34d86f['has'](_0x52e39f))&&_0x35491f['delete'](_0x52e39f);}for(const _0x40a6cf of _0x3b4734){const _0x5a464a=_0x1215ea['insertions'][_0x40a6cf];let _0x22c56f=null,_0x1a9d48=null;for(const _0x2922b2 of _0x5a464a){const _0x16a77e=this['_getVidAttributeName'](_0x2922b2),_0x38fc20=_0x2922b2['item']['getAttribute'](_0x16a77e),_0x238ad7=_0x35491f['get'](_0x38fc20);_0x238ad7&&'elementStart'==_0x2922b2['type']&&(_0x22c56f=Array['from'](_0x238ad7)[0x0],_0x1a9d48=_0x2922b2['item']['getAttribute']('vid_end')),_0x22c56f&&(_0x34d86f['set'](_0x38fc20,{'userId':_0x22c56f}),_0x2429fc['set'](_0x38fc20,{'userId':_0x22c56f})),_0x38fc20==_0x1a9d48&&(_0x22c56f=null,_0x1a9d48=null);}}const _0x2f5711={},_0x59467e=new Set();for(const _0x34d2b5 of _0x3b4734){const _0x50ebb9=_0x4fdbdc['deletions'][_0x34d2b5],_0x5535bd=_0x4fdbdc['insertions'][_0x34d2b5];for(const {userId:_0x255a50}of this['_touchedMarkers']['values']())null!==_0x255a50&&_0x59467e['add'](_0x255a50);for(const {userId:_0x3f9672}of this['_touchedRoots']['values']())null!==_0x3f9672&&_0x59467e['add'](_0x3f9672);this['_markChanges'](_0x5535bd,_0x1215ea['insertions'][_0x34d2b5],_0x2429fc,'insertion',_0x59467e),this['_markChanges'](_0x50ebb9,_0x1215ea['deletions'][_0x34d2b5],_0x34d86f,'deletion',_0x59467e),_0x2f5711[_0x34d2b5]={'insertions':this['_prepareViewToSave'](_0x5535bd),'deletions':this['_prepareViewToSave'](_0x50ebb9),'attachChange':this['_touchedRoots']['get'](_0x34d2b5)||null,'attributesBefore':_0x1f8919(this['_baseRootsAttributes']['get'](_0x34d2b5))||{},'attributesAfter':_0x1f8919(this['_diffRootsAttributes']['get'](_0x34d2b5))};}return{'diffData':_0x2f5711,'authorsIds':Array['from'](_0x59467e)};}['_processRootBeforeSave'](_0x2c7b02){for(const [,_0x13e4a5]of _0x2c7b02['markers']){const _0xca49b5=_0x13e4a5['start']['getAncestors']()['filter'](_0xfdcd8c=>'tableCell'==_0xfdcd8c['name']);for(const _0x46a9a1 of _0xca49b5)0x1==_0x46a9a1['childCount']&&_0x46a9a1['getChild'](0x0)['is']('element','paragraph')&&_0x46a9a1['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x13eb7a){this['_processRootBeforeSave'](_0x13eb7a);const _0x237f6e=this['editor']['data']['toView'](_0x13eb7a,{}),_0x1e949f=Array['from'](_0x237f6e['getChildren']())['map'](_0x4c151f=>this['_getViewJson'](_0x4c151f));return JSON['stringify'](_0x1e949f);}['_getViewJson'](_0x1d027){if(_0x1d027['is']('$text'))return _0x1d027['data'];{const _0x2d7ed3=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0xe685e4=_0x1d027,_0x14ded4=this['editor']['data']['htmlProcessor']['domConverter'],_0x1f4bc5={'type':_0x2d7ed3['_getTypeCharForViewElement'](_0xe685e4),'name':_0xe685e4['name'],'attributes':Array['from'](_0xe685e4['getAttributes']()),'children':Array['from'](_0xe685e4['getChildren']())['map'](_0xa6f18b=>this['_getViewJson'](_0xa6f18b))};if(_0x1d027['is']('uiElement')&&'$comment'!=_0x1d027['name']){const _0x59560e=_0x1d027['render'](_0x14ded4['domDocument'],_0x14ded4);_0x1f4bc5['children']['push'](_0x59560e['outerHTML']);}else{if(_0x1d027['is']('rawElement')){const _0x353e65=_0x14ded4['domDocument']['createElement'](_0xe685e4['name']);_0x1d027['render'](_0x353e65,_0x14ded4),_0x1f4bc5['children']['push'](_0x353e65['innerHTML']);}}const _0x4bd659=Array['from'](_0xe685e4['getCustomProperties']());_0x4bd659['length']>0x0&&(_0x1f4bc5['customProperties']=_0x4bd659);const _0x52dbe5=_0xe685e4['getFillerOffset']();return null!==_0x52dbe5&&(_0x1f4bc5['fillerOffset']=_0x52dbe5),_0x1f4bc5;}}['_markChanges'](_0x24e41e,_0x5917e0,_0x1a0e1c,_0x196d27,_0x4e6243){let _0x221041=null,_0x228932=null,_0x1e94fe=0x0;const _0x32c6d9=this['editor']['model'];for(let _0x5a817b=0x0;_0x5a817b<_0x5917e0['length'];_0x5a817b++){const _0x404e77=this['_getVidAttributeName'](_0x5917e0[_0x5a817b]),_0xc9db45=_0x5917e0[_0x5a817b]['item']['getAttribute'](_0x404e77),_0x3a442d=_0x1a0e1c['get'](_0xc9db45),_0x1feecb=_0x5a817b==_0x5917e0['length']-0x1;(!_0x221041&&_0x3a442d&&(_0x221041=_0x3a442d,_0x228932=_0x5917e0[_0x5a817b]),_0x221041&&(!_0x3a442d||_0x3a442d['userId']!=_0x221041['userId']))&&(_0x44e94a(_0x3a442d,P(_0x228932,_0x24e41e,_0x32c6d9),P(_0x5917e0[_0x5a817b],_0x24e41e,_0x32c6d9)),_0x221041=_0x3a442d||null,_0x228932=_0x3a442d?_0x5917e0[_0x5a817b]:null),_0x221041&&_0x1feecb&&_0x44e94a(_0x3a442d,P(_0x228932,_0x24e41e,_0x32c6d9),V(_0x5917e0[_0x5a817b],_0x24e41e,_0x32c6d9));}function _0x44e94a(_0x5862e7,_0x1cc6cf,_0x33d8b0){const _0x2cf9af=_0x221041['userId'],_0x514910='revision:'+_0x196d27+':'+_0x2cf9af+':'+_0x1e94fe++,_0x5f377a=_0x32c6d9['createRange'](_0x1cc6cf,_0x33d8b0);_0x24e41e['markers']['set'](_0x514910,_0x5f377a),null!==_0x2cf9af&&_0x4e6243['add'](_0x2cf9af);}}['_getVidAttributeName'](_0x291573){switch(_0x291573['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x536d73,_0x248119){_0x536d73['baseVersion']=null;for(const _0x1e2eee in _0x536d73){const _0x5dbfd2=_0x536d73[_0x1e2eee];if(_0x5dbfd2 instanceof _0x4d7936){const _0x123d72=_0x248119['get'](_0x5dbfd2['root']['rootName']);_0x536d73[_0x1e2eee]=this['_fixPosition'](_0x5dbfd2,_0x123d72);}if(_0x5dbfd2 instanceof _0x1340e0){const _0x327092=_0x248119['get'](_0x5dbfd2['root']['rootName']);_0x536d73[_0x1e2eee]=this['_fixRange'](_0x5dbfd2,_0x327092);}'root'===_0x1e2eee&&(_0x536d73['root']=_0x248119['get'](_0x536d73['root']['rootName']));}}['_fixRange'](_0x4b7f36,_0x3d7e09){return this['editor']['model']['createRange'](this['_fixPosition'](_0x4b7f36['start'],_0x3d7e09),this['_fixPosition'](_0x4b7f36['end'],_0x3d7e09));}['_fixPosition'](_0x3fadf3,_0x7191c0){return this['editor']['model']['createPositionFromPath'](_0x7191c0,_0x3fadf3['path'],_0x3fadf3['stickiness']);}['_handleInsertOperation'](_0x16ede6){const _0x1267fa=this['_idsRoots']['get'](_0x16ede6['position']['root']['rootName']),_0x2eea21=this['_fixPosition'](_0x16ede6['position'],_0x1267fa),_0x195032=null===_0x16ede6['_authorId']?null:_0x16ede6['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0xfc99bd=_0x2eea21['parent'],_0x15626e=this['_revisionId'],_0x196494=[];for(const _0xac6d45 of _0x16ede6['nodes'])if(_0xac6d45['is']('element'))_0x196494['push'](this['_makeIdsRoot'](_0xac6d45));else{for(let _0x5196a3=0x0;_0x5196a3<_0xac6d45['offsetSize'];_0x5196a3++)_0x196494['push'](new _0x41b3fc('$text',{'vid':this['_revisionId']++}));}const _0x251a27=this['_revisionId'];for(let _0x18a33f=_0x15626e;_0x18a33f<_0x251a27;_0x18a33f++)this['_touched']['set'](_0x18a33f,{'userId':_0x195032});_0xfc99bd['_insertChild'](_0x2eea21['offset'],_0x196494);}['_handleMoveOperation'](_0x4eaec4){(_0x4eaec4=this['_cloneOperation'](_0x4eaec4,this['_idsRoots']))['_execute']();const _0x53c951=null===_0x4eaec4['_authorId']?null:_0x4eaec4['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x51ea72=_0x4eaec4['getMovedRangeStart'](),_0x596809=_0x51ea72['parent'],_0x418d3f=_0x51ea72['offset'];!function _0x337176(_0x1ef299,_0x593023,_0x301b1a,_0x2e5aa4){for(let _0x57f2cd=_0x301b1a;_0x57f2cd<_0x2e5aa4;_0x57f2cd++){const _0x91ec69=_0x593023['getChild'](_0x57f2cd);_0x91ec69['is']('element','$text')?_0x1ef299['set'](_0x91ec69['getAttribute']('vid'),{'userId':_0x53c951}):(_0x1ef299['set'](_0x91ec69['getAttribute']('vid_start'),{'userId':_0x53c951}),_0x337176(_0x1ef299,_0x91ec69,0x0,_0x91ec69['childCount']),_0x1ef299['set'](_0x91ec69['getAttribute']('vid_end'),{'userId':_0x53c951}));}}(this['_touched'],_0x596809,_0x418d3f,_0x418d3f+_0x4eaec4['howMany']);}['_handleMergeOperation'](_0x55b435){const _0x3d0619=null===(_0x55b435=this['_cloneOperation'](_0x55b435,this['_idsRoots']))['_authorId']?null:_0x55b435['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x541e9b=_0x55b435['targetPosition']['parent'],_0x19c578=_0x55b435['sourcePosition']['parent'],_0x318c22=_0x541e9b['getAttribute']('vid_end'),_0x362471=_0x19c578['getAttribute']('vid_start');_0x541e9b['_setAttribute']('vid_end',_0x19c578['getAttribute']('vid_end')),_0x19c578['_setAttribute']('vid_end',_0x318c22),this['_touched']['set'](_0x362471,{'userId':_0x3d0619}),this['_touched']['set'](_0x318c22,{'userId':_0x3d0619}),_0x55b435['_execute']();}['_handleSplitOperation'](_0x2e6ca3){const _0x3dee61=null===(_0x2e6ca3=this['_cloneOperation'](_0x2e6ca3,this['_idsRoots']))['_authorId']?null:_0x2e6ca3['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x233f44=_0x2e6ca3['graveyardPosition'],_0x4b2d42=_0x2e6ca3['splitPosition']['parent'];_0x2e6ca3['_execute']();const _0x973548=_0x4b2d42['getAttribute']('vid_end'),_0x2536ad=_0x2e6ca3['insertionPosition']['nodeAfter'];if(_0x233f44){const _0x4ef924=_0x2536ad['getAttribute']('vid_end'),_0x5ec808=_0x4b2d42['getAttribute']('vid_end');_0x4b2d42['_setAttribute']('vid_end',_0x4ef924),_0x2536ad['_setAttribute']('vid_end',_0x5ec808),this['_touched']['set'](_0x4b2d42['getAttribute']('vid_end'),{'userId':_0x3dee61}),this['_touched']['set'](_0x2536ad['getAttribute']('vid_start'),{'userId':_0x3dee61});}else{const _0x67aa64=this['_revisionId']++,_0x117cf2=this['_revisionId']++;_0x4b2d42['_setAttribute']('vid_end',_0x67aa64),_0x2536ad['_setAttribute']('vid_start',_0x117cf2),_0x2536ad['_setAttribute']('vid_end',_0x973548),this['_touched']['set'](_0x67aa64,{'userId':_0x3dee61}),this['_touched']['set'](_0x117cf2,{'userId':_0x3dee61});}}['_handleMarkerOperation'](_0x415e82){if(!_0x415e82['affectsData'])return;const _0x2ffd47=(_0x415e82=this['_cloneOperation'](_0x415e82,this['_diffRoots']))['oldRange']?_0x415e82['oldRange']['root']:null,_0x147c69=_0x415e82['newRange']?_0x415e82['newRange']['root']:null;_0x2ffd47&&this['_markers']['delete'](_0x415e82['name']),_0x147c69&&this['_markers']['set'](_0x415e82['name'],_0x415e82['newRange']['clone']());const _0x44bdc5=null===_0x415e82['_authorId']?null:_0x415e82['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x257c9b=_0x415e82['name'];if(!this['_touchedMarkers']['has'](_0x257c9b))return void this['_touchedMarkers']['set'](_0x257c9b,{'range':_0x415e82['oldRange'],'userId':_0x44bdc5});const _0xfd2de5=this['_touchedMarkers']['get'](_0x257c9b),_0x49af89=_0xfd2de5['range'],_0x5a1855=_0x415e82['newRange'];null==_0x49af89&&null==_0x5a1855||_0x49af89&&_0x5a1855&&_0x49af89['isEqual'](_0x5a1855)?this['_touchedMarkers']['delete'](_0x415e82['name']):_0xfd2de5['userId']=_0x44bdc5;}['_handleRootOperation'](_0xf7f694,_0x1b5616){this['_diffRoots']['has'](_0xf7f694['rootName'])?this['_diffRoots']['get'](_0xf7f694['rootName'])['_isAttached']=_0xf7f694['isAdd']:(this['_diffRoots']['set'](_0xf7f694['rootName'],N(_0xf7f694['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0xf7f694['rootName'],{}),_0x1b5616&&this['_idsRoots']['set'](_0xf7f694['rootName'],N(_0xf7f694['rootName'],!0x0)));const _0x15b85a=null===_0xf7f694['_authorId']?null:_0xf7f694['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x7378f9=this['_touchedRoots']['get'](_0xf7f694['rootName']);_0x7378f9&&_0x7378f9['userId']===_0x15b85a?this['_touchedRoots']['delete'](_0xf7f694['rootName']):this['_touchedRoots']['set'](_0xf7f694['rootName'],{'userId':_0x15b85a,'isAttached':_0xf7f694['isAdd']});}['_handleRootAttributeOperation'](_0x4bdadc){const _0x25a935=this['_diffRootsAttributes']['get'](_0x4bdadc['root']['rootName']);null===_0x4bdadc['newValue']?delete _0x25a935[_0x4bdadc['key']]:_0x25a935[_0x4bdadc['key']]=_0x4bdadc['newValue'];}}function x(_0x60d302){const _0x5de043=N(_0x60d302['rootName'],_0x60d302['isAttached']());for(const _0x224ae7 of _0x60d302['getChildren']()){const _0x253db7=_0x224ae7['_clone'](!0x0);_0x5de043['_appendChild'](_0x253db7);}return _0x5de043;}function N(_0x22a97b,_0x56fc97=!0x0){const _0x5af5dc=new _0x1753c2();return _0x5af5dc['rootName']=_0x22a97b,_0x5af5dc['_isAttached']=_0x56fc97,_0x5af5dc['isAttached']=()=>_0x5af5dc['_isAttached'],_0x5af5dc;}function P(_0x1158f1,_0x4bf6fa,_0xe5eb15){const _0x29715e='elementEnd'==_0x1158f1['type']?_0xe5eb15['createPositionAt'](_0x1158f1['item'],'end'):_0xe5eb15['createPositionBefore'](_0x1158f1['item']);return _0xe5eb15['createPositionFromPath'](_0x4bf6fa,_0x29715e['path'],_0x29715e['stickiness']);}function V(_0x4a1d91,_0x2d0985,_0x45fbe3){const _0x4087a3='elementStart'==_0x4a1d91['type']?_0x45fbe3['createPositionAt'](_0x4a1d91['item'],0x0):_0x45fbe3['createPositionAfter'](_0x4a1d91['item']);return _0x45fbe3['createPositionFromPath'](_0x2d0985,_0x4087a3['path'],_0x4087a3['stickiness']);}class me extends/* #__PURE__ -- @preserve */
|
|
25
|
+
_0x5e9ce1(_0x4c679a){['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x5582ae,_0x2ceba7){super(_0x5582ae),this['focusTracker']=new _0x57d9ce(),this['keystrokes']=new _0x5f3a69(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x2ceba7),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'](),_0x3ae8e9({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x14886d=_0x1190ce=>_0x1190ce['stopPropagation']();this['keystrokes']['set']('arrowright',_0x14886d),this['keystrokes']['set']('arrowleft',_0x14886d),this['keystrokes']['set']('arrowup',_0x14886d),this['keystrokes']['set']('arrowdown',_0x14886d);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x794bf7){this['revisionNameInputView']['fieldView']['element']['value']=_0x794bf7['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0xbc0fdf){const _0x914c71=new et(this['locale'],ti),_0x3bef7a=_0x914c71['fieldView'];_0x3bef7a['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x334bb4=m(this['locale'],'Name\x20of\x20the\x20revision');return!_0xbc0fdf&&(_0x334bb4+='\x20('+m(this['locale'],'optional')+')'),(_0x914c71['label']=_0x334bb4,_0x3bef7a['on']('input',()=>{this['revisionNameInputValue']=_0x3bef7a['element']['value']['trim']();}),_0x914c71);}}class l extends _0x2bce4d{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h];}['_saveRevisionFormView'];['init'](){const _0x16f09f=this['editor'],_0x4fd146=_0x16f09f['plugins']['get']('RevisionTracker');_0x16f09f['ui']['componentFactory']['add']('revisionHistory',_0x519809=>{const _0x5ba753=_0x46d208(_0x519809),_0x37a10a=_0x5ba753['panelView']['children'],_0x132914=new _0x33e630(_0x519809),_0x26f8d6=new _0x2b7b7d(_0x519809),_0x43930f=new _0x1a6925(_0x519809),_0x4c3a21=new _0x2b7b7d(_0x519809),_0x5a3824=new _0x1a6925(_0x519809);return _0x5ba753['bind']('isEnabled')['to'](_0x4fd146,'isReady',_0x4fd146,'isEnabled',_0x16f09f,'isReadOnly',(_0x31205d,_0x3cc307,_0x41f8d7)=>_0x31205d&&_0x3cc307&&!_0x41f8d7),_0x5ba753['buttonView']['set']({'icon':_0x3f5198,'label':m(_0x519809,'Revision\x20history'),'tooltip':!0x0}),_0x43930f['set']({'label':m(_0x519809,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x43930f['bind']('isEnabled')['to'](_0x4fd146,'isReady',_0x4fd146,'isEnabled',_0x16f09f,'isReadOnly',(_0x240c6e,_0x385972,_0xff4a3)=>_0x240c6e&&_0x385972&&!_0xff4a3),_0x43930f['on']('execute',()=>this['_showDialog']()),_0x5a3824['set']({'label':m(_0x519809,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x5a3824['bind']('isEnabled')['to'](_0x4fd146,'isReady',_0x16f09f,'isReadOnly',(_0x38e69f,_0x4c911a)=>_0x38e69f&&!_0x4c911a),_0x5a3824['on']('execute',()=>{_0x16f09f['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x5ba753['isOpen']=!0x1,_0x16f09f['editing']['view']['focus']();}),_0x26f8d6['children']['add'](_0x43930f),_0x4c3a21['children']['add'](_0x5a3824),_0x132914['role']='menu',_0x132914['items']['addMany']([_0x26f8d6,_0x4c3a21]),_0x37a10a['add'](_0x132914),_0x5ba753;}),_0x16f09f['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x1763fe=this['editor'],_0x7b232=_0x1763fe['locale'],_0x3d5fb6=new _0x412e4b(_0x7b232),_0x426563=new _0x289751(_0x7b232);_0x3d5fb6['buttonView']['set']({'icon':_0x3f5198,'label':m(_0x7b232,'Revision\x20history')});const _0x144195=new _0x50e527(_0x7b232,_0x3d5fb6),_0x553a5e=new _0x1326a4(_0x7b232);_0x553a5e['set']({'label':m(_0x7b232,'Save\x20current\x20revision')}),_0x553a5e['delegate']('execute')['to'](_0x3d5fb6),_0x553a5e['on']('execute',()=>{this['_showDialog']();}),_0x144195['children']['add'](_0x553a5e),_0x426563['items']['add'](_0x144195);const _0x508629=new _0x50e527(_0x7b232,_0x3d5fb6),_0xe1796c=new _0x1326a4(_0x7b232);return _0xe1796c['set']({'label':m(_0x7b232,'Open\x20revision\x20history')}),_0xe1796c['delegate']('execute')['to'](_0x3d5fb6),_0xe1796c['on']('execute',()=>{_0x1763fe['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x508629['children']['add'](_0xe1796c),_0x426563['items']['add'](_0x508629),_0x3d5fb6['panelView']['children']['add'](_0x426563),_0x3d5fb6;}['_showDialog'](){const _0x2b1c54=this['editor'],_0x1af60f=_0x2b1c54['locale'],_0x3180ac=_0x2b1c54['plugins']['get']('Dialog'),_0x1be9ea=_0x2b1c54['plugins']['get']('RevisionTracker');function _0x46295d(_0x19389f){_0x2b1c54['config']['get']('revisionHistory.requireRevisionName')&&''===_0x19389f['revisionName']?_0x19389f['revisionNameInputView']['errorText']=m(_0x1af60f,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x2b1c54['plugins']['get'](h)['saveRevision']({'name':_0x19389f['revisionName']}),_0x3180ac['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x46295d(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x3180ac['show']({'id':'revisionSave','title':m(_0x1af60f,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':m(_0x2b1c54['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x3180ac['hide']()},{'label':m(_0x2b1c54['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0xcdb8b3){_0xcdb8b3['bind']('isEnabled')['to'](_0x1be9ea,'isReady',_0x1be9ea,'isEnabled',_0x2b1c54,'isReadOnly',(_0xb9f416,_0x342412,_0xb2c4b2)=>_0xb9f416&&_0x342412&&!_0xb2c4b2);},'onExecute':()=>_0x46295d(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x1ce303=this['editor'],_0x7aa48a=_0x1ce303['locale'];this['_saveRevisionFormView']=new me(_0x7aa48a,_0x1ce303['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class z extends _0x4c679a{['changeId'];['_model'];constructor(_0x4e50fc,_0x20d5a2){super(_0x4e50fc),this['_model']=_0x20d5a2,this['changeId']=_0x20d5a2['id'];const _0x48f9c1=this['bindTemplate'],_0x4fc419=m(_0x4e50fc,_0x20d5a2['data']['isSuggestion']?'Suggested\x20by':'add'==_0x20d5a2['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x20d5a2['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x48f9c1['to']('type',_0x2ba129=>'ck-revision-change__'+_0x2ba129)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x4fc419}]},{'text':'\x20'+_0x20d5a2['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class G extends/* #__PURE__ -- @preserve */
|
|
26
|
+
_0x1a438a(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x15f47f){super(),this['id']=_0x15f47f['id']||_0x3bb1d9(),this['author']=_0x15f47f['author'],this['type']=_0x15f47f['type'],this['data']=_0x15f47f['data']||{},this['rootName']=_0x15f47f['rootName'],this['set']('createdAt',_0x15f47f['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(_0x11a237,_0x1ca45c){this['newRevisionId']=_0x11a237,this['oldRevisionId']=_0x1ca45c,this['changes']=new _0x40f1c6();}['_setChanges'](_0x2af9cf){for(const _0x134d72 of _0x2af9cf)this['changes']['add'](_0x134d72);}}class u extends _0x2bce4d{['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[_0x729304,_0x27a1d9,S,$];}constructor(_0x246c8e){super(_0x246c8e),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',(_0x51861e,_0x49cc40,_0x46313a)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x28d356=>{for(const _0x520c92 of this['editor']['editing']['view']['document']['roots'])_0x46313a?_0x28d356['removeClass']('ck-editor__editable__overlay',_0x520c92):_0x28d356['addClass']('ck-editor__editable__overlay',_0x520c92);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x16b803=>null!==_0x16b803),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x18f0ff,_0x336276,_0x3f60fa)=>_0x18f0ff&&_0x3f60fa?_0x336276['changes']['getIndex'](_0x3f60fa):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x6a06b7,_0xada702)=>_0x6a06b7?_0xada702['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0x27a1d9);}['init'](){const _0x41ff91=this['editor'],_0x52e51e=new rt(_0x41ff91,{'direction':'backward'}),_0x584175=new rt(_0x41ff91,{'direction':'forward'});(_0x41ff91['commands']['add']('showPreviousChange',_0x52e51e),_0x41ff91['commands']['add']('showNextChange',_0x584175),_0x41ff91['commands']['add']('restoreRevision',new nt(_0x41ff91)),this['on']('change:numberOfChanges',()=>{_0x52e51e['refresh'](),_0x584175['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x41ff91['enableReadOnlyMode']('revision-viewer'),_0x41ff91['plugins']['has']('WidgetToolbarRepository'))&&_0x41ff91['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x115452){return await this['_utils']['loadRevisionData'](_0x115452,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x115452);}async['getRevisionRootsAttributes'](_0x147cc5){return await this['_utils']['loadRevisionData'](_0x147cc5,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x147cc5);}async['compare'](_0x2e6093,_0x2042e1,_0x1f132f=!0x1){if(!this['isEnabled'])return;const _0x1ce66e=this['diff'],_0x517d6d=this['repository'],_0xaac944='string'==typeof _0x2e6093?_0x517d6d['getRevision'](_0x2e6093):_0x2e6093,_0xf4a10a='string'==typeof _0x2042e1?_0x517d6d['getRevision'](_0x2042e1):_0x2042e1,_0x267f20=_0xaac944['id'],_0x3b7b3c=_0xf4a10a?_0xf4a10a['id']:null;if(!_0x1f132f&&this['diff']&&this['diff']['newRevisionId']===_0x267f20&&this['diff']['oldRevisionId']===_0x3b7b3c)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new J(_0x267f20,_0x3b7b3c);const _0x1c378c=this['_getRevisionsRange'](_0xaac944,_0xf4a10a,!0x0)['map'](_0x23fc5c=>this['_utils']['loadRevisionData'](_0x23fc5c,this['adapter']));return _0x1c378c['push'](new Promise(_0x48bdc1=>{setTimeout(_0x48bdc1,0x14);})),Promise['all'](_0x1c378c)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x15b60f=this['_getDiff'](_0x267f20,_0x3b7b3c);for(const _0x5021dd of _0x15b60f['changes'])this['_changeIdToChange']['set'](_0x5021dd['id'],_0x5021dd);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x785625=>{for(const _0xf3ae99 of this['editor']['model']['document']['getRootNames']())_0x785625['detachRoot'](_0xf3ae99);for(const _0x5834ae of Object['keys'](_0x15b60f['model'])){const _0x4f3601=_0x785625['addRoot'](_0x5834ae);for(const _0x4ae0a9 of Object['keys'](_0x15b60f['attributes'][_0x5834ae]))_0x785625['setAttribute'](_0x4ae0a9,_0x15b60f['attributes'][_0x5834ae][_0x4ae0a9],_0x4f3601);_0x785625['insert'](_0x15b60f['model'][_0x5834ae],_0x4f3601,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x15b60f['changes'])),this['isReady']=!0x0;})['catch'](_0x29bf3d=>{console['error'](_0x29bf3d),this['_cleanUp'](),_0x1ce66e&&(this['diff']=_0x1ce66e),this['isReady']=!0x0;});}['addRevisionData'](_0x514de6,_0x3de9c0){const _0x405913=this['repository']['createRevision'](_0x514de6);return _0x405913['on']('_update',(_0x445e45,_0x1bab58,_0x414aeb)=>_0x3de9c0(_0x1bab58,_0x414aeb,_0x405913)),this['repository']['addRevision'](_0x405913),_0x405913;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x4986c9=>{for(const _0x4fd223 of this['editor']['model']['document']['getRootNames']())_0x4986c9['detachRoot'](_0x4fd223);});}['_sortAndFilterDiffChanges'](_0x187740){const _0x454531=[],_0xbc2a58=new Map();for(const _0x57007e of this['editor']['model']['document']['getRootNames']()){const _0x35b892=this['editor']['editing']['view']['getDomRoot'](_0x57007e);if(!_0x35b892)continue;const _0x14ef1a=_0x35b892['getClientRects']()['item'](0x0);_0x14ef1a&&(_0x454531['push'](_0x57007e),_0xbc2a58['set'](_0x57007e,_0x14ef1a));}return _0x454531['sort']((_0x341fff,_0x5804e3)=>{const _0x29b491=_0xbc2a58['get'](_0x341fff),_0x361c8e=_0xbc2a58['get'](_0x5804e3);return _0x29b491['y']-_0x361c8e['y']||_0x29b491['x']-_0x361c8e['x'];}),(_0x187740=_0x187740['filter'](_0x4f5b95=>_0x454531['includes'](_0x4f5b95['rootName'])))['sort']((_0x271baf,_0x363f19)=>_0x454531['indexOf'](_0x271baf['rootName'])-_0x454531['indexOf'](_0x363f19['rootName'])),_0x187740;}['_makeTape'](_0x4ada08){const _0x7d74e1=Array['from'](_0x4ada08['markers'])['filter'](([_0xeeb07,_0x58d402])=>_0xeeb07['startsWith']('revision:')&&!_0x58d402['isCollapsed']),_0xfcfb65=Array['from'](this['editor']['model']['createRangeIn'](_0x4ada08)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x7d74e1['length'])for(const _0x14ca88 of _0xfcfb65){const [_0x3bd716,_0x616f2a]=_0x7d74e1[0x0],[,_0x37ace3,_0x2992bf]=_0x3bd716['split'](':');if(_0x616f2a['end']['isEqual'](_0x14ca88['nextPosition'])&&_0x7d74e1['shift'](),(_0x14ca88['previousPosition']['isEqual'](_0x616f2a['start'])||_0x14ca88['previousPosition']['isAfter'](_0x616f2a['start']))&&('insertion'==_0x37ace3?_0x14ca88['isAdded']={'userId':_0x2992bf}:'deletion'==_0x37ace3&&(_0x14ca88['isRemoved']={'userId':_0x2992bf})),0x0==_0x7d74e1['length'])break;}return _0xfcfb65;}['_refreshStartEndIndex'](_0x3d0ea0){const _0x103876=new Map();for(let _0x13d46d=0x0;_0x13d46d<_0x3d0ea0['length'];_0x13d46d++)'text'===_0x3d0ea0[_0x13d46d]['type']?(_0x3d0ea0[_0x13d46d]['item']['startIndex']=_0x13d46d,_0x3d0ea0[_0x13d46d]['item']['endIndex']=_0x13d46d):('elementStart'===_0x3d0ea0[_0x13d46d]['type']?_0x3d0ea0[_0x13d46d]['item']['startIndex']=_0x13d46d:'elementEnd'===_0x3d0ea0[_0x13d46d]['type']&&(_0x3d0ea0[_0x13d46d]['item']['endIndex']=_0x13d46d),_0x103876['set'](_0x3d0ea0[_0x13d46d]['id'],_0x13d46d));for(const _0x1450f4 of _0x103876['values']())'elementStart'===_0x3d0ea0[_0x1450f4]['type']?_0x3d0ea0[_0x1450f4]['item']['endIndex']=_0x103876['get'](_0x3d0ea0[_0x1450f4]['pairId']):'elementEnd'===_0x3d0ea0[_0x1450f4]['type']&&(_0x3d0ea0[_0x1450f4]['item']['startIndex']=_0x103876['get'](_0x3d0ea0[_0x1450f4]['pairId']));}['_processTape'](_0x35f23a){for(let _0x3f5ded=0x0;_0x3f5ded<_0x35f23a['length'];_0x3f5ded++){if('elementStart'===_0x35f23a[_0x3f5ded]['type'])_0x35f23a[_0x3f5ded]['item']['startIndex']=_0x3f5ded;else{if('elementEnd'===_0x35f23a[_0x3f5ded]['type']){_0x35f23a[_0x3f5ded]['item']['endIndex']=_0x3f5ded;const _0x24e397=_0x35f23a[_0x3f5ded]['item']['startIndex'];_0x35f23a[_0x24e397]['pairId']=_0x35f23a[_0x3f5ded]['id'],_0x35f23a[_0x3f5ded]['pairId']=_0x35f23a[_0x24e397]['id'];}else _0x35f23a[_0x3f5ded]['item']['startIndex']=_0x3f5ded,_0x35f23a[_0x3f5ded]['item']['endIndex']=_0x3f5ded,_0x35f23a[_0x3f5ded]['pairId']=null;}_0x35f23a[_0x3f5ded]['markersStart']||(_0x35f23a[_0x3f5ded]['markersStart']=[],_0x35f23a[_0x3f5ded]['markersEnd']=[]);}}['_markInsertions'](_0x47ace1,_0x1464ab){const _0xd49585=_0x47ace1['filter'](_0x2c9530=>!_0x2c9530['isAdded']);for(let _0x1ce892=0x0;_0x1ce892<_0x1464ab['length'];_0x1ce892++)_0x1464ab[_0x1ce892]['isAdded']&&(_0xd49585[_0x1ce892]['isAdded']=_0x1464ab[_0x1ce892]['isAdded']);}['_getDiff'](_0x114099,_0x31f4c7=null){const _0x1e7941=this['repository']['getRevision'](_0x114099),_0x51016d=_0x31f4c7?this['repository']['getRevision'](_0x31f4c7):null,_0x1d12ee=this['_getRevisionsRange'](_0x1e7941,_0x51016d),_0x2d1f6a=_0x1d12ee[_0x1d12ee['length']-0x1],_0x1d4250=new Map(),_0x1f3c7e={'model':{},'attributes':{},'changes':[]},_0x281ff8=new Set(),_0x3d24cb=new Map();for(let _0x3d883f=_0x1d12ee['length']-0x1;_0x3d883f>=0x0;_0x3d883f--){const _0x515e37=_0x1d12ee[_0x3d883f];for(const _0x455db9 of Object['keys'](_0x515e37['diffData']))if(_0x515e37['diffData'][_0x455db9]['attachChange']){const _0x4bb927=_0x515e37['diffData'][_0x455db9]['attachChange'];_0x4bb927['isAttached']?(_0x281ff8['add'](_0x455db9),_0x3d24cb['has'](_0x455db9)&&_0x3d24cb['get'](_0x455db9)['userId']==_0x4bb927['userId']?_0x3d24cb['delete'](_0x455db9):_0x3d24cb['set'](_0x455db9,_0x4bb927)):_0x3d24cb['has'](_0x455db9)?(_0x281ff8['delete'](_0x455db9),_0x3d24cb['delete'](_0x455db9)):(_0x281ff8['add'](_0x455db9),_0x3d24cb['set'](_0x455db9,_0x4bb927));}else _0x281ff8['add'](_0x455db9);}for(const _0x153135 of _0x281ff8){const _0x4b0187=_0x3d24cb['has'](_0x153135)&&!_0x3d24cb['get'](_0x153135)['isAttached'];let _0x2b16f4=_0x4b0187?_0x1d12ee['length']-0x1:0x0;const _0x56ac01=_0x4b0187?-0x1:0x1;for(;_0x1d12ee[_0x2b16f4];){const _0x24f622=_0x1d12ee[_0x2b16f4];if(_0x24f622['diffData'][_0x153135]){const _0x47e162=_0x4b0187?_0x24f622['diffData'][_0x153135]['attributesBefore']:_0x24f622['diffData'][_0x153135]['attributesAfter'];_0x1f3c7e['attributes'][_0x153135]=_0x47e162?_0x1f8919(_0x47e162):{};break;}_0x2b16f4+=_0x56ac01;}}for(const _0x5cd02b of _0x1d12ee){_0x5cd02b['model']={};for(const _0x427cbb of _0x5cd02b['authors'])_0x1d4250['set'](_0x427cbb['id'],_0x427cbb);for(const _0x1cd772 of _0x281ff8){const _0x3c4281=_0x5cd02b['diffData'][_0x1cd772]?_0x5cd02b['diffData'][_0x1cd772]['insertions']:'[]',_0x5a5e99=_0x5cd02b['diffData'][_0x1cd772]?_0x5cd02b['diffData'][_0x1cd772]['deletions']:'[]';_0x5cd02b['model'][_0x1cd772]={'insertions':this['_utils']['_makeModelFromViewString'](_0x3c4281),'deletions':this['_utils']['_makeModelFromViewString'](_0x5a5e99)};}}for(const _0x45f6c9 of _0x281ff8){let _0x356a8d=null,_0x2430a3=0x0;const _0x14e6d4=new Map(Array['from'](_0x1e7941['model'][_0x45f6c9]['insertions']['markers'])['filter'](([_0x376447])=>!_0x376447['startsWith']('revision:')));let _0xffa9db=0x0;for(const _0x3ddf23 of _0x1d12ee){const _0x15c10e=this['_makeTape'](_0x3ddf23['model'][_0x45f6c9]['insertions']);_0x3ddf23==_0x1e7941?(_0x356a8d=_0x15c10e,_0x2430a3=_0x356a8d['length'],_0x356a8d['forEach'](_0x1f2f58=>{_0x1f2f58['id']=_0xffa9db++;}),this['_processTape'](_0x356a8d)):this['_markInsertions'](_0x356a8d,_0x15c10e);const _0x254cc6=_0x356a8d['filter'](_0x36469b=>!_0x36469b['isAdded'])['map'](_0x3af20f=>_0x3af20f['id']);let _0x26623a=0x0;const _0xb2af29=this['_makeTape'](_0x3ddf23['model'][_0x45f6c9]['deletions']);_0xb2af29['forEach'](_0x3476c4=>{_0x3476c4['isRemoved']?_0x3476c4['id']=_0x2430a3++:_0x3476c4['id']=_0x254cc6[_0x26623a++];}),this['_processTape'](_0xb2af29),this['_setDistance'](_0x356a8d,'isAdded'),this['_setDistance'](_0xb2af29,'isRemoved'),_0x3ddf23==_0x1e7941&&this['_markMarkers'](_0x356a8d,_0x14e6d4),_0x356a8d=this['_joinTapes'](_0x356a8d,_0xb2af29),this['_refreshStartEndIndex'](_0x356a8d),this['_setDistance'](_0x356a8d,'isRemoved');}_0x356a8d=_0x356a8d['filter'](_0x2532b1=>!(_0x2532b1['isAdded']&&_0x2532b1['isRemoved']));const _0x5adafd=new Map(_0x2d1f6a['model'][_0x45f6c9]['deletions']['markers']),_0x3c679a=new Set(_0x14e6d4['keys']());for(const _0x7e46ed of _0x5adafd['keys']())_0x3c679a['delete'](_0x7e46ed);this['_markSuggestions'](_0x356a8d,_0x3c679a),this['_fixObsoleteTags'](_0x356a8d),_0x356a8d=this['_removeMissingPairs'](_0x356a8d),_0x356a8d=this['_markMismatchedRemovedTags'](_0x356a8d),_0x356a8d=this['_removeUnsupportedChanges'](_0x356a8d);const {root:_0x55f2cc,changes:_0x395b3a}=this['_makeModelFromTape'](_0x356a8d,_0x1d4250,_0x45f6c9);_0x1f3c7e['model'][_0x45f6c9]=_0x55f2cc;const _0x50418c=_0x3d24cb['get'](_0x45f6c9);if(_0x50418c){const _0x53a7fc=_0x1d4250['get'](_0x50418c['userId']),_0x375299=new G({'author':_0x53a7fc,'type':_0x50418c['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x45f6c9});_0x395b3a['unshift'](_0x375299),_0x1f3c7e['attributes'][_0x45f6c9]['revisionHistoryAttachChange']=_0x375299['id'];}_0x1f3c7e['changes']=_0x1f3c7e['changes']['concat'](_0x395b3a);}return _0x1f3c7e;}['_markMarkers'](_0x1708e4,_0x38fe7e){for(let _0x4236ff=0x0;_0x4236ff<_0x1708e4['length'];_0x4236ff++)for(const [_0x27f656,_0x4cc38a]of _0x38fe7e)!_0x4cc38a['isCollapsed']&&_0x4cc38a['start']['isEqual'](_0x1708e4[_0x4236ff]['previousPosition'])&&_0x1708e4[_0x4236ff]['markersStart']['push'](_0x27f656),_0x4cc38a['end']['isEqual'](_0x1708e4[_0x4236ff]['nextPosition'])&&_0x1708e4[_0x4236ff]['markersEnd']['push'](_0x27f656);}['_joinTapes'](_0x3598bc,_0x2ed7d7){let _0x5d7b6a=[],_0x4682f3=0x0,_0x248df7=0x0;for(;_0x4682f3<_0x3598bc['length']||_0x248df7<_0x2ed7d7['length'];){const _0xca7af7=_0x3598bc[_0x4682f3]||{},_0x529ab6=_0x2ed7d7[_0x248df7]||{};if(_0xca7af7['id']==_0x529ab6['id'])_0x4682f3++,_0x248df7++,_0x5d7b6a['push'](_0xca7af7);else{if(_0x529ab6['isRemoved']&&_0xca7af7['isAdded']){const {commonTape:_0x57a2c5,iEnd:_0x4e0e7a,jEnd:_0x5061b2}=this['_threeWayMerge'](_0x3598bc,_0x4682f3,_0x2ed7d7,_0x248df7);_0x5d7b6a=_0x5d7b6a['concat'](_0x57a2c5),_0x4682f3=_0x4e0e7a,_0x248df7=_0x5061b2;}else _0x529ab6['isRemoved']?(_0x248df7++,_0x5d7b6a['push'](_0x529ab6)):(_0x4682f3++,_0x5d7b6a['push'](_0xca7af7));}}return _0x5d7b6a;}['_markSuggestions'](_0x39ec55,_0x26ca47){const _0x1f720a=[];for(let _0x1a1602=0x0;_0x1a1602<_0x39ec55['length'];_0x1a1602++){for(let _0x5436e1=0x0;_0x5436e1<_0x39ec55[_0x1a1602]['markersStart']['length'];_0x5436e1++){const _0x590843=_0x39ec55[_0x1a1602]['markersStart'][_0x5436e1];if(!_0x26ca47['has'](_0x590843))continue;const {group:_0x143327,type:_0x44089a,authorId:_0x334d71}=_0x4de535(_0x590843);'revision-suggestion'!=_0x143327||'insertion'!=_0x44089a&&'deletion'!=_0x44089a||(_0x1f720a['unshift']({'type':_0x44089a,'name':_0x590843,'userId':_0x334d71}),_0x39ec55[_0x1a1602]['markersStart']['splice'](_0x5436e1,0x1),_0x5436e1--);}_0x23c715(_0x39ec55[_0x1a1602]);for(let _0x274aa5=0x0;_0x274aa5<_0x39ec55[_0x1a1602]['markersEnd']['length'];_0x274aa5++){const _0x18ba08=_0x39ec55[_0x1a1602]['markersEnd'][_0x274aa5];if(!_0x26ca47['has'](_0x18ba08))continue;const {group:_0x3dccfc,type:_0xa8a512}=_0x4de535(_0x18ba08);if('revision-suggestion'!=_0x3dccfc||'insertion'!=_0xa8a512&&'deletion'!=_0xa8a512)continue;_0x39ec55[_0x1a1602]['markersEnd']['splice'](_0x274aa5,0x1),_0x274aa5--;const _0x299f0e=_0x1f720a['findIndex'](_0x51051a=>_0x51051a['name']==_0x18ba08);_0x299f0e>-0x1&&_0x1f720a['splice'](_0x299f0e,0x1);}}function _0x4de535(_0x19f0d4){const _0x38ab3b=_0x19f0d4['split'](':');return{'group':_0x38ab3b[0x0],'type':_0x38ab3b[0x1],'subType':_0x38ab3b['length']>=0x5?_0x38ab3b[0x2]:null,'id':_0x38ab3b['length']<0x5?_0x38ab3b[0x2]:_0x38ab3b[0x3],'authorId':_0x38ab3b['length']<0x5?_0x38ab3b[0x3]:_0x38ab3b[0x4],'markerCount':0x6==_0x38ab3b['length']?_0x38ab3b[0x5]:null};}function _0x23c715(_0x1b2d12){for(let _0x132d4c=0x0;_0x132d4c<_0x1f720a['length'];_0x132d4c++){if(_0x1b2d12['isAdded']&&'insertion'==_0x1f720a[_0x132d4c]['type']&&_0x1b2d12['isAdded']['userId']==_0x1f720a[_0x132d4c]['userId'])return _0x1b2d12['isAddSuggestion']=_0x1f720a[_0x132d4c],void delete _0x1b2d12['isAdded'];if(!_0x1b2d12['isAdded']&&!_0x1b2d12['isRemoved']&&'deletion'==_0x1f720a[_0x132d4c]['type'])return void(_0x1b2d12['isRemoveSuggestion']=_0x1f720a[_0x132d4c]);}}}['_setDistance'](_0x5bd6b6,_0x1ed951){let _0x56a095=0x0,_0x29a47b=!0x1;const _0x58201b=new Map();for(const _0x181ed3 of _0x5bd6b6)_0x181ed3[_0x1ed951]?_0x29a47b&&(_0x56a095++,_0x29a47b=!0x1):(_0x56a095++,_0x29a47b=!0x0),_0x58201b['set'](_0x181ed3['id'],_0x56a095);for(let _0x49f168=0x0;_0x49f168<_0x5bd6b6['length'];_0x49f168++){if('isRemoved'==_0x1ed951&&_0x5bd6b6[_0x49f168]['isAdded']||'isAdded'==_0x1ed951&&_0x5bd6b6[_0x49f168]['isRemoved'])continue;if('text'==_0x5bd6b6[_0x49f168]['type']){_0x5bd6b6[_0x49f168]['distance']=0x0;continue;}const _0x3ed375=_0x58201b['get'](_0x5bd6b6[_0x49f168]['pairId']),_0xa1af8=_0x58201b['get'](_0x5bd6b6[_0x49f168]['id']);_0x5bd6b6[_0x49f168]['distance']=_0x3ed375-_0xa1af8;}}['_getRevisionsRange'](_0x4d5833,_0x53ffde,_0x2dec5b=!0x1){const _0x17fae4=[];let _0x45f26b=this['repository']['getIndex'](_0x4d5833),_0x1e0cb8=this['repository']['getIndex'](_0x53ffde);for(-0x1==_0x1e0cb8&&(_0x1e0cb8=this['repository']['_revisions']['length'],_0x2dec5b=!0x1);_0x45f26b<_0x1e0cb8;)_0x17fae4['push'](this['repository']['getRevision'](_0x45f26b)),_0x45f26b++;return _0x2dec5b&&_0x17fae4['push'](this['repository']['getRevision'](_0x45f26b)),_0x17fae4;}['_threeWayMerge'](_0x184787,_0x3d6eb4,_0x1ba95a,_0x5ce38a){const _0x3331c3=this['editor']['model']['schema'];let _0x1539a5=_0x3d6eb4;for(;_0x184787[_0x1539a5]&&_0x184787[_0x1539a5]['isAdded'];)_0x1539a5++;let _0x1efa74=_0x5ce38a;for(;_0x1ba95a[_0x1efa74]&&_0x1ba95a[_0x1efa74]['isRemoved'];)_0x1efa74++;_0x1e31d4(_0x184787,_0x3d6eb4,_0x1539a5),_0x1e31d4(_0x1ba95a,_0x5ce38a,_0x1efa74);const _0x4bc80d=_0x1ba95a['slice'](_0x5ce38a,_0x1efa74)['concat'](_0x184787['slice'](_0x3d6eb4,_0x1539a5));return _0x4bc80d['sort']((_0x2533e8,_0x3e11a4)=>_0x2533e8['side']!=_0x3e11a4['side']?_0x2533e8['side']-_0x3e11a4['side']:_0x2533e8['level']!=_0x3e11a4['level']?_0x2533e8['level']-_0x3e11a4['level']:_0x2533e8['distance']!=_0x3e11a4['distance']?_0x3e11a4['distance']-_0x2533e8['distance']:!!_0x2533e8['isAdded']!=!!_0x3e11a4['isAdded']?-0x1==_0x2533e8['side']||0x0==_0x2533e8['side']?_0x2533e8['isAdded']?-0x1:0x1:_0x2533e8['isAdded']?0x1:-0x1:_0x2533e8['index']-_0x3e11a4['index']),{'commonTape':_0x4bc80d,'iEnd':_0x1539a5,'jEnd':_0x1efa74};function _0x1e31d4(_0x676597,_0x36b73f,_0x11940a){let _0x1830bb=-0x1,_0x4b9a1f=Number['POSITIVE_INFINITY'],_0x212f08=!0x0;for(let _0x427cca=_0x36b73f;_0x427cca<_0x11940a;_0x427cca++)if(_0x3331c3['isInline'](_0x676597[_0x427cca]['item'])||(_0x212f08=!0x1),_0x676597[_0x427cca]['item']['startIndex']<_0x36b73f&&(_0x1830bb=_0x427cca),_0x676597[_0x427cca]['item']['endIndex']>=_0x11940a){_0x4b9a1f=_0x427cca;break;}_0x212f08&&(_0x1830bb=_0x11940a-0x1);for(let _0x50823b=_0x36b73f;_0x50823b<_0x11940a;_0x50823b++)_0x676597[_0x50823b]['side']=_0x50823b<=_0x1830bb?-0x1:_0x50823b<_0x4b9a1f?0x0:0x1,_0x676597[_0x50823b]['index']=_0x50823b;let _0x463021=0x0;for(let _0x26f22e=_0x36b73f;_0x26f22e<=_0x1830bb;_0x26f22e++)0x0==_0x676597[_0x26f22e]['distance']?_0x676597[_0x26f22e]['level']=_0x463021:(_0x463021++,_0x676597[_0x26f22e]['level']=_0x463021,_0x463021++);for(let _0x5600d3=_0x36b73f;_0x5600d3<_0x11940a;_0x5600d3++)0x0==_0x676597[_0x5600d3]['side']&&(_0x676597[_0x5600d3]['level']=_0x463021);_0x463021=0x0;for(let _0x4e4dd0=_0x11940a-0x1;_0x4e4dd0>=_0x4b9a1f;_0x4e4dd0--)0x0==_0x676597[_0x4e4dd0]['distance']?_0x676597[_0x4e4dd0]['level']=_0x463021:(_0x463021--,_0x676597[_0x4e4dd0]['level']=_0x463021,_0x463021--);}}['_fixObsoleteTags'](_0x3074c3){const _0xa03a3a=new Map(),_0x2b25ff=this['editor']['model']['schema'];for(let _0x3a93c8=0x1;_0x3a93c8<_0x3074c3['length'];_0x3a93c8++){let _0x398e45,_0x262f9a,_0x38f03d;const _0x27b1e9=_0x3074c3[_0x3a93c8],_0x44b328=_0x3074c3[_0x3a93c8-0x1];if('text'==_0x27b1e9['type'])continue;if(_0x27b1e9['type']!=_0x44b328['type'])continue;if(!_0x2b25ff['isBlock'](_0x44b328['item'])||_0x2b25ff['isLimit'](_0x44b328['item']))continue;if(!_0x2b25ff['isBlock'](_0x27b1e9['item'])||_0x2b25ff['isLimit'](_0x27b1e9['item']))continue;if((_0x3074c3[_0x3a93c8]['isAdded']||_0x3074c3[_0x3a93c8]['isAddSuggestion'])&&_0x3074c3[_0x3a93c8-0x1]['isRemoved'])_0x398e45=_0x3074c3[_0x3a93c8],_0x262f9a=_0x3074c3[_0x3a93c8-0x1],_0x38f03d=_0x3a93c8-0x1;else{if(!_0x3074c3[_0x3a93c8]['isRemoved']||!_0x3074c3[_0x3a93c8-0x1]['isAdded']&&!_0x3074c3[_0x3a93c8-0x1]['isAddSuggestion'])continue;_0x398e45=_0x3074c3[_0x3a93c8-0x1],_0x262f9a=_0x3074c3[_0x3a93c8],_0x38f03d=_0x3a93c8;}const _0x59268d=_0x398e45['level']==_0x262f9a['level'],_0x5920ff=Math['abs'](_0x398e45['level'])<Math['abs'](_0x262f9a['level'])&&0x0==_0x262f9a['distance'];(_0x59268d||_0x5920ff)&&(_0xa03a3a['set'](_0x262f9a['id'],_0x398e45['id']),_0x3074c3['splice'](_0x38f03d,0x1),_0x3a93c8--,_0x398e45['isAdded']=!0x1);}for(let _0x26aa4d=0x0;_0x26aa4d<_0x3074c3['length'];_0x26aa4d++)_0xa03a3a['has'](_0x3074c3[_0x26aa4d]['pairId'])&&(_0x3074c3[_0x26aa4d]['pairId']=_0xa03a3a['get'](_0x3074c3[_0x26aa4d]['pairId']));}['_removeMissingPairs'](_0x28c61a){const _0x545c6c=new Set(_0x28c61a['map'](_0x3640c7=>_0x3640c7['id']));for(let _0x2485a8=0x0;_0x2485a8<_0x28c61a['length'];_0x2485a8++)_0x545c6c['has'](_0x28c61a[_0x2485a8]['pairId'])||0x0==_0x28c61a[_0x2485a8]['distance']||(_0x28c61a[_0x2485a8]['isIncorrect']=!0x0);return _0x28c61a['filter'](_0x61e738=>!_0x61e738['isIncorrect']);}['_markMismatchedRemovedTags'](_0x3793d5){const _0x3cc74c=new Set();for(let _0x35bad8=0x0;_0x35bad8<_0x3793d5['length'];_0x35bad8++){if(_0x3cc74c['has'](_0x3793d5[_0x35bad8]['id'])&&_0x3793d5[_0x35bad8]['isRemoved']&&(_0x3793d5[_0x35bad8]['isIncorrect']=!0x0),_0x3793d5[_0x35bad8]['isIncorrect'])continue;if(0x0==_0x3793d5[_0x35bad8]['distance'])continue;if('elementStart'!=_0x3793d5[_0x35bad8]['type'])continue;if(null==_0x3793d5[_0x35bad8]['pairId'])continue;let _0x1aaac6=_0x35bad8+0x1,_0x582701=0x0;for(;_0x3793d5[_0x1aaac6]['id']!=_0x3793d5[_0x35bad8]['pairId'];)'elementStart'==_0x3793d5[_0x1aaac6]['type']?_0x582701++:'elementEnd'==_0x3793d5[_0x1aaac6]['type']&&_0x582701--,_0x1aaac6++;if(0x0!=_0x582701){if(_0x3793d5[_0x35bad8]['isRemoved'])_0x3793d5[_0x35bad8]['isIncorrect']=!0x0;else{for(;_0x1aaac6!=_0x35bad8;)_0x3793d5[_0x1aaac6]['isRemoved']&&0x0!=_0x3793d5[_0x1aaac6]['distance']&&(_0x3793d5[_0x1aaac6]['isIncorrect']=!0x0,_0x3cc74c['add'](_0x3793d5[_0x1aaac6]['pairId'])),_0x1aaac6--;}}}return _0x3793d5['filter'](_0x202cd6=>!_0x202cd6['isIncorrect']);}['_removeUnsupportedChanges'](_0x272793){const _0xf92308=this['editor']['model']['schema'];for(let _0xb93b15=0x0;_0xb93b15<_0x272793['length'];_0xb93b15++){if(!(_0x272793[_0xb93b15]['isAdded']||_0x272793[_0xb93b15]['isAddSuggestion']||_0x272793[_0xb93b15]['isRemoved']||_0x272793[_0xb93b15]['isRemoveSuggestion']))continue;if(0x0==_0x272793[_0xb93b15]['distance'])continue;const _0x2aaa6d=_0x272793[_0xb93b15]['item'];_0xf92308['isBlock'](_0x2aaa6d)||_0xf92308['isLimit'](_0x2aaa6d)||(_0x272793[_0xb93b15]['isAdded']&&delete _0x272793[_0xb93b15]['isAdded'],_0x272793[_0xb93b15]['isAddSuggestion']&&delete _0x272793[_0xb93b15]['isAddSuggestion'],_0x272793[_0xb93b15]['isRemoveSuggestion']&&delete _0x272793[_0xb93b15]['isRemoveSuggestion'],_0x272793[_0xb93b15]['isRemoved']&&(_0x272793[_0xb93b15]['isIncorrect']=!0x0));}return _0x272793['filter'](_0x43105d=>!_0x43105d['isIncorrect']);}['_makeModelFromTape'](_0x37c963,_0x481418,_0x1aecee){const _0x4bb0e2=new _0x1753c2(),_0x53dce7=[],_0x3861c3=new Map(),_0x3084a3=this['editor']['model'],_0x3d30ca=_0x3084a3['schema'],_0x11cc7a=[_0x4bb0e2],_0x178af0={},_0x4ad5e6={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x3881a8=null;const _0x825dd7=[0x0];for(let _0x3368d3=0x0;_0x3368d3<_0x37c963['length'];_0x3368d3++)if('elementStart'===_0x37c963[_0x3368d3]['type']){_0x37c963[_0x3368d3]['previousPosition']=_0x3084a3['createPositionFromPath'](_0x4bb0e2,_0x825dd7);const _0x3f7543=new _0x41b3fc(_0x37c963[_0x3368d3]['item']['name'],_0x37c963[_0x3368d3]['item']['getAttributes']());_0x11cc7a[0x0]['_appendChild'](_0x3f7543),_0x825dd7['push'](0x0),_0x11cc7a['unshift'](_0x3f7543),_0x37c963[_0x3368d3]['nextPosition']=_0x3084a3['createPositionFromPath'](_0x4bb0e2,_0x825dd7);}else'elementEnd'===_0x37c963[_0x3368d3]['type']?(_0x11cc7a['shift'](),_0x37c963[_0x3368d3]['previousPosition']=_0x3084a3['createPositionFromPath'](_0x4bb0e2,_0x825dd7),_0x825dd7['pop'](),_0x825dd7[_0x825dd7['length']-0x1]++,_0x37c963[_0x3368d3]['nextPosition']=_0x3084a3['createPositionFromPath'](_0x4bb0e2,_0x825dd7)):(_0x37c963[_0x3368d3]['previousPosition']=_0x3084a3['createPositionFromPath'](_0x4bb0e2,_0x825dd7),_0x3881a8?_0x3881a8['_data']+=_0x37c963[_0x3368d3]['item']['data']:_0x3881a8=new _0x3e2046(_0x37c963[_0x3368d3]['item']['data'],_0x37c963[_0x3368d3]['item']['getAttributes']()),_0x37c963[_0x3368d3+0x1]&&'text'===_0x37c963[_0x3368d3+0x1]['type']&&_0x4b1e0e(_0x3881a8,_0x37c963[_0x3368d3+0x1]['item'])||(_0x11cc7a[0x0]['_appendChild'](_0x3881a8),_0x3881a8=null),_0x825dd7[_0x825dd7['length']-0x1]+=_0x37c963[_0x3368d3]['item']['offsetSize'],_0x37c963[_0x3368d3]['nextPosition']=_0x3084a3['createPositionFromPath'](_0x4bb0e2,_0x825dd7));for(let _0x5201b0=0x0;_0x5201b0<_0x37c963['length'];_0x5201b0++){const _0x203eeb=_0x37c963[_0x5201b0]['previousPosition'],_0x297d0b=_0x37c963[_0x5201b0]['nextPosition'];for(const _0x3e2ebe of _0x37c963[_0x5201b0]['markersStart'])_0x3861c3['set'](_0x3e2ebe,{'start':_0x203eeb,'end':null});_0x564fb4('isRemoveSuggestion',_0x5201b0,_0x203eeb,_0x297d0b),_0x564fb4('isAddSuggestion',_0x5201b0,_0x203eeb,_0x297d0b),_0x564fb4('isRemoved',_0x5201b0,_0x203eeb,_0x297d0b),_0x564fb4('isAdded',_0x5201b0,_0x203eeb,_0x297d0b);for(const _0xdcf3dc of _0x37c963[_0x5201b0]['markersEnd']){const _0x32977f=_0x3861c3['get'](_0xdcf3dc);_0x32977f?_0x32977f['end']=_0x297d0b:_0x3861c3['set'](_0xdcf3dc,{'start':_0x297d0b,'end':_0x297d0b});}}for(const [_0x4597b9,_0x1748e1]of _0x3861c3){const _0x4271e1=this['editor']['model']['createRange'](_0x1748e1['start'],_0x1748e1['end']);_0x4bb0e2['markers']['set'](_0x4597b9,_0x4271e1);}return _0x53dce7['sort']((_0x533967,_0x3aff2e)=>{const _0x1b0f28=_0x4bb0e2['markers']['get']('revision:'+_0x533967['id']),_0x4b5bcb=_0x4bb0e2['markers']['get']('revision:'+_0x3aff2e['id']);return _0x1b0f28['start']['isBefore'](_0x4b5bcb['start'])?-0x1:_0x1b0f28['start']['isAfter'](_0x4b5bcb['start'])?0x1:_0x1b0f28['end']['isBefore'](_0x4b5bcb['end'])?-0x1:_0x1b0f28['end']['isAfter'](_0x4b5bcb['end'])?0x1:'add'===_0x533967['type']?-0x1:0x1;}),{'root':_0x4bb0e2,'changes':_0x53dce7};function _0x564fb4(_0x426285,_0x4d510d,_0x4231e3,_0x4ba862){const _0xfdbfc7=!!_0x37c963[_0x4d510d][_0x426285],_0x38f34e=_0xfdbfc7?_0x37c963[_0x4d510d][_0x426285]['userId']:null,_0x417e02=_0x4d510d===_0x37c963['length']-0x1,_0x2d46a6=_0x4ad5e6[_0x426285][0x0],_0x358c6a=_0x3d30ca['isObject'](_0x37c963[_0x4d510d]['item']);!_0x178af0[_0x426285]&&_0xfdbfc7?_0x178af0[_0x426285]={'start':_0x4231e3,'tapeItem':_0x37c963[_0x4d510d],'userId':_0x38f34e,'type':_0x426285}:_0x178af0[_0x426285]&&!_0xfdbfc7?(_0x178af0[_0x426285]['end']=_0x4231e3,_0xb9a0(_0x178af0[_0x426285]),_0x178af0[_0x426285]=null):_0x178af0[_0x426285]&&_0xfdbfc7&&_0x178af0[_0x426285]['userId']!==_0x38f34e&&(_0x178af0[_0x426285]['end']=_0x4231e3,_0x2d46a6&&_0x2d46a6['userId']===_0x178af0[_0x426285]['userId']||_0xb9a0(_0x178af0[_0x426285]),_0x178af0[_0x426285]={'start':_0x4231e3,'tapeItem':_0x37c963[_0x4d510d],'userId':_0x38f34e,'type':_0x426285}),_0x178af0[_0x426285]&&_0x358c6a&&('elementStart'!==_0x37c963[_0x4d510d]['type']||_0x2d46a6&&_0x2d46a6['userId']===_0x38f34e||_0x4ad5e6[_0x426285]['unshift']({'userId':_0x38f34e,'object':_0x37c963[_0x4d510d]['item'],'change':_0x178af0[_0x426285]}),'elementEnd'===_0x37c963[_0x4d510d]['type']&&_0x2d46a6&&_0x2d46a6['object']===_0x37c963[_0x4d510d]['item']&&(_0x4ad5e6[_0x426285]['shift'](),_0x178af0[_0x426285]=_0x2d46a6['change'])),_0x178af0[_0x426285]&&_0x417e02&&(_0x178af0[_0x426285]['end']=_0x4ba862,_0xb9a0(_0x178af0[_0x426285]),_0x178af0[_0x426285]=null);}function _0xb9a0({start:_0x580fbe,end:_0x358ce7,tapeItem:_0x596f2a,userId:_0x5b2cd7,type:_0x65f6b7}){const _0x2a19e7=_0x596f2a['item'],_0x22d241=_0x3084a3['schema']['isBlock'](_0x2a19e7)&&!_0x3084a3['schema']['isLimit'](_0x2a19e7),_0x56f35f=_0x580fbe['nodeAfter']==_0x358ce7['parent']&&_0x358ce7['isAtStart'];if(_0x22d241&&_0x56f35f)return;const _0x3bef6f=_0x3084a3['createRange'](_0x580fbe,_0x358ce7),_0x542a77=_0x481418['get'](_0x5b2cd7),_0xd15705=new G({'author':_0x542a77,'type':'isAdded'==_0x65f6b7||'isAddSuggestion'==_0x65f6b7?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x65f6b7||'isRemoveSuggestion'==_0x65f6b7},'createdAt':new Date(),'rootName':_0x1aecee});_0x53dce7['push'](_0xd15705),_0x4bb0e2['markers']['set']('revision:'+_0xd15705['id'],_0x3bef6f);}function _0x4b1e0e(_0x34c03b,_0x48710c){const _0xa8b47e=_0x34c03b['getAttributes'](),_0x3e94ad=_0x48710c['getAttributes']();for(const _0x5aeeb0 of _0xa8b47e){if(_0x5aeeb0[0x1]!==_0x48710c['getAttribute'](_0x5aeeb0[0x0]))return!0x1;_0x3e94ad['next']();}return _0x3e94ad['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0xa7d011=>{const _0x574afa=_0xa7d011['markerName']['split'](':')[0x1],_0x52eb83=this['_getChangeFromId'](_0x574afa);if(!_0x52eb83)return null;const _0x29000c='add'==_0x52eb83['type']?'insertion':'deletion',_0x3762a8=['ck-suggestion-marker','ck-suggestion-marker-'+_0x29000c];return _0x52eb83['data']['isSuggestion']&&_0x3762a8['push']('ck-suggestion-marker-'+_0x29000c+'-new'),this['activeChange']==_0x52eb83&&_0x3762a8['push']('ck-suggestion-marker--active'),{'classes':_0x3762a8,'attributes':{'data-change-id':_0x574afa}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x561eeb=>{_0x561eeb['on']('element:pre',(_0x1d0e06,_0x2b1c93,_0x384ab2)=>{const _0x4be362=_0x2b1c93['viewItem']['getChild'](0x0);if(!_0x4be362||!_0x4be362['is']('element','code'))return;if(!_0x384ab2['consumable']['consume'](_0x4be362,{'attributes':['vid_start','vid_end']}))return;const _0x10184d=_0x2b1c93['modelRange']['start']['nodeAfter'];_0x384ab2['writer']['setAttribute']('vid_start',_0x4be362['getAttribute']('vid_start'),_0x10184d),_0x384ab2['writer']['setAttribute']('vid_end',_0x4be362['getAttribute']('vid_end'),_0x10184d);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x57b38c=>{_0x57b38c['on']('element',(_0x39fb2f,_0x11c88a,_0x229eb0)=>{if(!_0x229eb0['consumable']['consume'](_0x11c88a['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x11c88a['modelRange']['isCollapsed'])return;const _0x2e1690=_0x11c88a['modelRange']['start']['nodeAfter'];_0x2e1690['hasAttribute']('vid_start')||_0x2e1690['hasAttribute']('vid')||(_0x229eb0['writer']['setAttribute']('vid_start',_0x11c88a['viewItem']['getAttribute']('vid_start'),_0x2e1690),_0x229eb0['writer']['setAttribute']('vid_end',_0x11c88a['viewItem']['getAttribute']('vid_end'),_0x2e1690));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x1a788e=>_0x1a788e['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0xcb89c9,[,_0xe01617])=>{['vid_start','vid_end','vid']['includes'](_0xe01617)&&(_0xcb89c9['return']=!0x0,_0xcb89c9['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x363555=>{_0x363555['on']('attribute:vid',(_0x105497,_0x1122dd,_0x3feba4)=>{if('\x20'!=_0x1122dd['item']['data']||_0x1122dd['item']['parent']['maxOffset']>0x1)return;if(!_0x3feba4['consumable']['consume'](_0x1122dd['item'],_0x105497['name']))return;const _0x314360=_0x3feba4['writer'],_0x5e94e7=_0x3feba4['mapper']['toViewRange'](_0x1122dd['range']);_0x314360['wrap'](_0x5e94e7,_0x314360['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x3d05c7){const _0x2d86b3=_0x3d05c7['plugins']['get']('RevisionViewer');return(_0x37ed08,_0x23064e,_0x12d609)=>{const _0x46026d=_0x23064e['markerName']['split'](':')[0x1],_0x16749e=_0x2d86b3['_getChangeFromId'](_0x46026d);if(!_0x16749e)return null;const _0x30db0b='add'==_0x16749e['type']?'split':'merge';if(!_0x12d609['consumable']['test'](_0x23064e['markerRange'],_0x37ed08['name']))return;const _0x146887=_0x23064e['markerRange']['getWalker'](),_0xc8ab05=_0x23064e['markerRange']['start'],_0x315330=_0x3d05c7['model']['schema'];let _0x178cd2=null,_0x29e7f7=null,_0xa2e407=!0x1,_0x344dd8=!0x1;for(const _0x204d64 of _0x146887){const _0x3c1521=_0x204d64['item'];_0xa2e407=_0xa2e407||_0x315330['isContent'](_0x3c1521);const _0x32ed8c=_0x12d609['mapper']['toViewElement'](_0x3c1521);if(_0x32ed8c&&_0x32ed8c['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x204d64['type']&&(_0x315330['isBlock'](_0x3c1521)&&!_0x315330['isLimit'](_0x3c1521)&&(_0x3c1521['nextSibling']||_0xc8ab05['isAtEnd']?_0x178cd2&&_0x178cd2['parent']==_0x3c1521||(_0x178cd2=_0x3c1521,_0xb3b76c(_0x204d64['previousPosition']),_0x344dd8=!0x0):_0x29e7f7=_0x29e7f7||_0x204d64['previousPosition']));}function _0xb3b76c(_0x32b79d){const _0x34a74a=_0x12d609['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x30db0b}),_0x420a1f=_0x12d609['mapper']['toViewPosition'](_0x32b79d);_0x16749e['data']['isSuggestion']&&_0x12d609['writer']['addClass']('ck-suggestion-marker-'+_0x30db0b+'-new',_0x34a74a),_0x2d86b3['activeChange']==_0x16749e&&_0x12d609['writer']['addClass']('ck-suggestion-marker--active',_0x34a74a),_0x12d609['writer']['insert'](_0x420a1f,_0x34a74a),_0x12d609['mapper']['bindElementToMarker'](_0x34a74a,_0x23064e['markerName']);}_0xa2e407||_0x344dd8||!_0x29e7f7||_0xb3b76c(_0x29e7f7);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x456785,_0x24c4fe,_0x59fc71)=>{const _0x227339=_0x59fc71['mapper']['markerNameToElements'](_0x24c4fe['markerName']);if(_0x227339){for(const _0x177317 of _0x227339)(_0x177317['hasClass']('ck-suggestion-marker-split')||_0x177317['hasClass']('ck-suggestion-marker-merge'))&&(_0x59fc71['mapper']['unbindElementFromMarkerName'](_0x177317,_0x24c4fe['markerName']),_0x59fc71['writer']['remove'](_0x177317));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x2024f5,_0x1c3a1e,_0x4aedd1)=>{const _0x12555f=_0x1c3a1e['markerName']['split'](':')[0x1],_0x12a8a5=this['_getChangeFromId'](_0x12555f);if(!_0x12a8a5)return null;const _0x4fe1ce='add'==_0x12a8a5['type']?'split':'merge';if(_0x4aedd1['consumable']['test'](_0x1c3a1e['markerRange'],_0x2024f5['name']))for(const _0x56570f of _0x1c3a1e['markerRange']['getItems']()){if(!_0x56570f['is']('element','softBreak'))continue;const _0x3272aa=_0x4aedd1['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x4fe1ce}),_0x235967=_0x4aedd1['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x56570f));_0x12a8a5['data']['isSuggestion']&&_0x4aedd1['writer']['addClass']('ck-suggestion-marker-'+_0x4fe1ce+'-new',_0x3272aa),this['activeChange']==_0x12a8a5&&_0x4aedd1['writer']['addClass']('ck-suggestion-marker--active',_0x3272aa),_0x4aedd1['writer']['insert'](_0x235967,_0x3272aa),_0x4aedd1['mapper']['bindElementToMarker'](_0x3272aa,_0x1c3a1e['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x115b7a=>{for(const _0x2ea9c9 of this['editor']['model']['document']['getRootNames']()){const _0x3f43eb=this['editor']['model']['document']['getRoot'](_0x2ea9c9),_0x979dce=this['editor']['editing']['view']['document']['getRoot'](_0x2ea9c9);if(_0x979dce){const _0x1775d6=_0x3f43eb['getAttribute']('revisionHistoryAttachChange');if(_0x115b7a['removeAttribute']('data-change-id',_0x979dce),_0x115b7a['removeClass']('ck-revision-history-root-add',_0x979dce),_0x115b7a['removeClass']('ck-revision-history-root-remove',_0x979dce),_0x115b7a['removeClass']('ck-revision-history-root--active',_0x979dce),_0x1775d6){const _0x269bd8=this['_getChangeFromId'](_0x1775d6);if(!_0x269bd8)return null;_0x115b7a['setAttribute']('data-change-id',_0x1775d6,_0x979dce),_0x115b7a['addClass']('ck-revision-history-root-'+_0x269bd8['type'],_0x979dce),this['activeChange']==_0x269bd8&&_0x115b7a['addClass']('ck-revision-history-root--active',_0x979dce);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0xca577=>'revision-comment:'+_0xca577,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x1ff1d3=>'revision-suggestion:'+_0x1ff1d3,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x3501c3=>({'name':'suggestion:'+_0x3501c3,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x453f9d=>{const _0x3ffcb7=_0x453f9d['markerName']['split'](':')[0x1];return'insertion'!=_0x3ffcb7&&'deletion'!=_0x3ffcb7?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x3ffcb7]};}}),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',(_0x364ea4,_0x574ae4,_0x41e2dc)=>{const _0x141114=_0x41e2dc['mapper']['markerNameToElements'](_0x574ae4['markerName']);if(_0x141114){for(const _0x10e101 of _0x141114)_0x10e101['is']('uiElement')&&(_0x41e2dc['mapper']['unbindElementFromMarkerName'](_0x10e101,_0x574ae4['markerName']),_0x41e2dc['writer']['remove'](_0x10e101));}},{'priority':'high'});}['_getChangeFromId'](_0x370bb2){return this['_changeIdToChange']['get'](_0x370bb2);}['_getViewForChange'](_0x552c0f){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new z(this['editor']['locale'],_0x552c0f),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x3e760a,_0x3d3d7e,_0x554c51,_0x42723b)=>{_0x42723b&&this['_balloon']['remove'](_0x42723b),_0x554c51&&(this['_balloon']['add']({'view':_0x554c51,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x30c891=this['editor']['editing'],_0x223bac=this['_getChangeFromId'](_0x554c51['changeId']);let _0x2240ae;if(_0x223bac['data']['isOnRoot']){const _0x41b4f9=_0x30c891['view']['getDomRoot'](_0x223bac['rootName']);_0x2240ae=Array['from'](_0x41b4f9['getClientRects']());}else{const _0x4e062c=this['editor']['model']['markers']['get']('revision:'+_0x554c51['changeId']);_0x2240ae=Array['from'](_0x30c891['mapper']['markerNameToElements'](_0x4e062c['name']))['map'](_0x19e86f=>_0x30c891['view']['domConverter']['mapViewToDom'](_0x19e86f))['map'](_0x520155=>Array['from'](_0x520155['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x2240ae[0x0];return _0x2240ae['find'](_0x15432d=>_0x15432d['top']-0x3<=this['_activeViewTarget']['y']&&_0x15432d['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x15432d['left']-0x3<=this['_activeViewTarget']['x']&&_0x15432d['right']+0x3>=this['_activeViewTarget']['x'])||_0x2240ae[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x48c72c,_0x4338cb,_0x207928,_0x9fc9bb)=>{this['activeView']=_0x207928?this['_getViewForChange'](_0x207928):null,this['editor']['model']['change'](()=>{const _0x410cdf=this['editor']['editing'];_0x9fc9bb&&(_0x9fc9bb['data']['isOnRoot']?_0x410cdf['view']['change'](_0x3af38a=>{_0x3af38a['removeClass']('ck-revision-history-root--active',_0x410cdf['view']['document']['getRoot'](_0x9fc9bb['rootName']));}):_0x410cdf['reconvertMarker']('revision:'+_0x9fc9bb['id'])),_0x207928&&(_0x207928['data']['isOnRoot']?_0x410cdf['view']['change'](_0x3ea736=>{_0x3ea736['addClass']('ck-revision-history-root--active',_0x410cdf['view']['document']['getRoot'](_0x207928['rootName']));}):_0x410cdf['reconvertMarker']('revision:'+_0x207928['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x29cde1,_0x30541e)=>{if(this['activeChange'])return;const _0x2ccc77=this['_findChangeIdFromDomTarget'](_0x30541e['target']),_0x6c36dd=this['_changeIdToChange']['get'](_0x2ccc77);_0x6c36dd?(this['_activeViewTarget']={'x':_0x30541e['domEvent']['x'],'y':_0x30541e['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x6c36dd)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x161592,_0x4dbed8)=>{const _0x1fdf41=this['_findChangeIdFromDomTarget'](_0x4dbed8['target']),_0x2d2c9b=this['_changeIdToChange']['get'](_0x1fdf41);_0x2d2c9b?(this['_activeViewTarget']={'x':_0x4dbed8['domEvent']['x'],'y':_0x4dbed8['domEvent']['y']},_0x2d2c9b===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x2d2c9b):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x332fe7){do{const _0x179041=_0x332fe7['getAttribute']('data-change-id');if(_0x179041)return _0x179041;_0x332fe7=_0x332fe7['parent'];}while(_0x332fe7);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x39f503=>{for(const _0x1dec98 of this['editor']['model']['markers'])_0x39f503['removeMarker'](_0x1dec98);});}}function Q(_0xf43e58,_0x133ef2){return(_0x2c6ca7,_0x8992ce,_0x3e6007)=>{if(!_0x3e6007['consumable']['test'](_0x8992ce['markerRange'],_0x2c6ca7['name']))return;const _0x740a83=_0x8992ce['markerRange']['getWalker'](),_0x1723c9=_0x8992ce['markerRange']['start'],_0x582868=_0xf43e58['model']['schema'];let _0x4cf2d2=null,_0x3863ca=null,_0x1af59d=!0x1,_0xc070de=!0x1;for(const _0x140285 of _0x740a83){const _0x2a5d49=_0x140285['item'];_0x1af59d=_0x1af59d||_0x582868['isContent'](_0x2a5d49);const _0x4e7458=_0x3e6007['mapper']['toViewElement'](_0x2a5d49);if(_0x4e7458&&_0x4e7458['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x140285['type']&&(_0x582868['isBlock'](_0x2a5d49)&&!_0x582868['isLimit'](_0x2a5d49)&&(_0x2a5d49['nextSibling']||_0x1723c9['isAtEnd']?_0x4cf2d2&&_0x4cf2d2['parent']==_0x2a5d49||(_0x4cf2d2=_0x2a5d49,_0x5c1c38(_0x140285['previousPosition']),_0xc070de=!0x0):_0x3863ca=_0x3863ca||_0x140285['previousPosition']));}function _0x5c1c38(_0x491de5){const _0x4539a6=_0x3e6007['mapper']['toViewPosition'](_0x491de5),_0x10de46=_0x3e6007['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x133ef2});_0x3e6007['writer']['insert'](_0x4539a6,_0x10de46),_0x3e6007['mapper']['bindElementToMarker'](_0x10de46,_0x8992ce['markerName']);}_0x1af59d||_0xc070de||!_0x3863ca||_0x5c1c38(_0x3863ca);};}class nt extends _0x1e3043{constructor(_0x2cac55){super(_0x2cac55);const _0x130316=_0x2cac55['plugins']['get'](u);this['affectsData']=!0x1,this['listenTo'](_0x130316,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x130316,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x4cf5a0=this['editor'],_0x4e66eb=_0x4cf5a0['plugins']['get'](u),_0x290050=_0x4e66eb['isReady']?_0x4e66eb['diff']['newRevisionId']:null;_0x4cf5a0['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x290050);}['refresh'](){const {isReady:_0x2948cb,isEnabled:_0x21fbe3,repository:_0x4dea4f,diff:_0x556654}=this['editor']['plugins']['get'](u),_0x1263b7=_0x556654&&_0x4dea4f['getLaterVisibleRevision'](_0x556654['newRevisionId']);this['isEnabled']=_0x2948cb&&_0x21fbe3&&Boolean(_0x1263b7);}}class rt extends _0x1e3043{['_step'];constructor(_0x1b2eac,{direction:_0x430005}){super(_0x1b2eac);const _0xa1e763=_0x1b2eac['plugins']['get'](u);this['affectsData']=!0x1,this['_step']='forward'===_0x430005?0x1:-0x1,this['listenTo'](_0xa1e763,'change:isReady',()=>this['refresh']()),this['listenTo'](_0xa1e763,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0xa1e763,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x4a4a0d=this['editor'],_0x560445=_0x4a4a0d['plugins']['get'](u),{isNavigationMode:_0x34b9f8,currentChangeNumber:_0x2f7811}=_0x560445;let _0x5151c2;if(_0x560445['activeChange']=_0x34b9f8?_0x560445['diff']['changes']['get'](_0x2f7811+this['_step']):_0x560445['diff']['changes']['first'],_0x560445['activeChange']['data']['isOnRoot'])_0x5151c2=_0x4a4a0d['editing']['view']['getDomRoot'](_0x560445['activeChange']['rootName']);else{const _0x207dbf=_0x4a4a0d['model']['markers']['get']('revision:'+_0x560445['activeChange']['id']);_0x5151c2=_0x47c945(_0x4a4a0d['editing'],_0x207dbf);}_0x41b90b({'target':_0x5151c2,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x4d3bdb,currentChangeNumber:_0x509d71,numberOfChanges:_0x31e38c,isReady:_0x4339e,isEnabled:_0x1143a3}=this['editor']['plugins']['get'](u);this['isEnabled']=!!(_0x1143a3&&_0x4339e&&_0x31e38c)&&(!_0x4d3bdb||(0x1===this['_step']?_0x509d71<_0x31e38c-0x1:_0x509d71>0x0));}}class vi extends _0x4c679a{constructor(_0x1beada){super(_0x1beada);const _0x3fde58=this['bindTemplate'],_0x1ddffa=new _0x1a6925(_0x1beada),_0x4a19ec=new _0x1a6925(_0x1beada);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',(_0x5c9327,_0x67c0e9)=>_0x5c9327&&_0x67c0e9>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x36d86a,_0x3586e7,_0x308f75,_0x175008)=>{if(!_0x36d86a)return m(_0x1beada,'Loading...');if(!_0x308f75)return m(_0x1beada,'No\x20changes');const _0xeece8e=m(_0x1beada,'NUMBER_OF_CHANGES',_0x308f75);return _0x175008?m(_0x1beada,'X_OF_Y_CHANGES',[_0x3586e7+0x1,_0x308f75]):_0xeece8e;}),_0x1ddffa['set']({'label':m(_0x1beada,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x338ac3}),_0x4a19ec['set']({'label':m(_0x1beada,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x13d84f}),_0x1ddffa['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x4a19ec['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x1ddffa['on']('execute',()=>this['fire']('execute','backward')),_0x4a19ec['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',_0x3fde58['if']('_isStatusLabelVisible','ck-hidden',_0x1418d9=>!_0x1418d9)]},'children':[{'text':_0x3fde58['to']('isNavigationMode',_0x141e5d=>_0x141e5d?m(_0x1beada,'EDIT_X_OF_Y_REVISIONS')+':\x20':m(_0x1beada,'Total')+':\x20')}]},{'text':_0x3fde58['to']('_statusText')}]},new _0x33adfd(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x1ddffa,_0x4a19ec]}]});}}const oe='ck-editor__editable__loading-overlay';class wi extends _0x2bce4d{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x2a9cee=this['editor']['editing']['view'];_0x2a9cee['change'](_0x48b4d6=>{for(const _0x36d065 of _0x2a9cee['document']['roots'])_0x48b4d6['addClass'](oe,_0x36d065);});}['hide'](){const _0x3e302d=this['editor']['editing']['view'];_0x3e302d['change'](_0x187557=>{for(const _0x1620d6 of _0x3e302d['document']['roots'])_0x187557['removeClass'](oe,_0x1620d6);});}}class v extends _0x2bce4d{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u,wi];}['init'](){const _0x127361=this['editor'],_0x42230a=_0x127361['plugins']['get'](u),_0x3f0619=_0x127361['plugins']['get'](wi);_0x127361['ui']['componentFactory']['add']('exitToEditing',_0x1eb5c2=>{const _0x3e0845=new _0x1a6925(_0x1eb5c2);return _0x3e0845['set']({'label':m(_0x1eb5c2,'Back\x20to\x20editing'),'icon':_0x57a137,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x3e0845,'execute',()=>{_0x127361['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x3e0845;}),_0x127361['ui']['componentFactory']['add']('restoreRevision',_0x116c68=>{const _0x19316b=new _0x1a6925(_0x116c68);return _0x19316b['set']({'label':m(_0x116c68,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x19316b['bind']('isEnabled')['to'](_0x127361['commands']['get']('restoreRevision')),this['listenTo'](_0x19316b,'execute',()=>_0x127361['execute']('restoreRevision')),_0x19316b;}),_0x127361['ui']['componentFactory']['add']('changesNavigation',_0x46c053=>{const _0x296847=new vi(_0x46c053),_0x35af0f=_0x127361['commands']['get']('showPreviousChange'),_0x64bc1e=_0x127361['commands']['get']('showNextChange');return _0x296847['bind']('isBackwardNavigationEnabled')['to'](_0x35af0f,'isEnabled'),_0x296847['bind']('isForwardNavigationEnabled')['to'](_0x64bc1e,'isEnabled'),_0x296847['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x42230a),this['listenTo'](_0x296847,'execute',(_0x5f1d34,_0x8165f4)=>{_0x127361['execute']('forward'===_0x8165f4?'showNextChange':'showPreviousChange');}),_0x296847;}),_0x3f0619['show'](),_0x42230a['on']('change:isReady',(_0x5e634c,_0x14cc98,_0x3c3f1d)=>{_0x3c3f1d?_0x3f0619['hide']():_0x3f0619['show']();});}}class hi extends et{['_resizeObserver']=null;constructor(_0xdb2ba5,_0x317175){super(_0xdb2ba5,_0x317175);const _0x1a614c=this['bindTemplate'];this['set']({'label':m(_0xdb2ba5,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=m(_0xdb2ba5,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x1a614c['to']('_tooltipString'),'data-cke-tooltip-position':'s','data-cke-tooltip-class':'ck-tooltip_multi-line'}});}['render'](){super['render'](),this['_resizeObserver']=new ot(this['fieldView']['element'],()=>this['_updateTooltipText']()),this['listenTo'](this['fieldView'],'input',()=>this['_updateTooltipText']());}['destroy'](){super['destroy'](),this['_resizeObserver']&&this['_resizeObserver']['destroy']();}['_updateTooltipText'](){const _0xb234c=this['fieldView']['element'];this['_tooltipString']=_0xb234c['scrollWidth']>_0xb234c['clientWidth']&&_0xb234c['value']||'';}}class ni extends _0x4c679a{constructor(_0x295b0d,_0x3de9ec,_0x17dae7){super(_0x295b0d);const _0x34d4dc=new _0x26c7e2();_0x34d4dc['set']({'content':_0x4ad26c,'viewBox':'0\x200\x2011\x2010'});const _0x5cf13d=['ck','ck-revision-history-sidebar__revision-author'];_0x17dae7&&_0x5cf13d['push']('ck-revision-history-sidebar__revision-author_creator');const _0x27192c=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':m(_0x295b0d,_0x17dae7?'Revision\x20creator':'Revision\x20author')},'children':[_0x34d4dc,_0x3de9ec['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x5cf13d},'children':_0x27192c});}}function ai(_0x57bf18,_0x13cf75){const _0x3e3acb=_0x57bf18['bindTemplate'],_0x3b3ed0=_0x57bf18['locale'],_0x5f16b7=_0x46d208(_0x3b3ed0);_0x5f16b7['panelPosition']='sw';const _0x360762=function(_0x5da675,_0x1ce667){const _0x34fd68=function(_0x1cf0a8,_0x336fa9){const _0x135fd7=_0x1cf0a8['locale'],_0x2703ab={'Compare\x20against\x20selected':m(_0x135fd7,'Compare\x20against\x20selected'),'Name\x20this\x20revision':m(_0x135fd7,'Name\x20this\x20revision'),'Restore\x20this\x20revision':m(_0x135fd7,'Restore\x20this\x20revision')};return _0x336fa9['map'](_0x5f65d1=>{const _0x2efbda=_0x2703ab[_0x5f65d1['name']];return _0x2efbda&&_0x2efbda!==_0x5f65d1['name']&&(_0x5f65d1['name']=_0x2efbda),_0x5f65d1;});}(_0x5da675,_0x1ce667),_0x31897a=new _0x40f1c6();for(const _0x4439b0 of _0x34fd68){const _0x2d405d={'type':'button','model':new to({'label':_0x4439b0['name'],'class':_0x4439b0['class'],'withText':!0x0,'role':'menuitem','_action':_0x4439b0['action']})};_0x2d405d['model']['bind']('isEnabled')['to'](_0x5da675,'isActionsDropdownOpen',_0x56c1e7=>'function'!=typeof _0x4439b0['isEnabled']||(!_0x56c1e7||_0x4439b0['isEnabled'](_0x5da675))),_0x31897a['add'](_0x2d405d);}return _0x31897a;}(_0x57bf18,_0x13cf75);return _0x57bf18['bind']('isActionsDropdownOpen')['to'](_0x5f16b7,'isOpen'),_0x5f16b7['buttonView']['set']({'label':m(_0x3b3ed0,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x575b19}),_0x5f16b7['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x3e3acb['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x3e3acb['to'](_0x44ba97=>_0x44ba97['stopPropagation']())}}),_0x5f16b7['on']('execute',_0x4c1e5c=>{_0x57bf18['isReady']&&'function'==typeof _0x4c1e5c['source']['_action']&&_0x4c1e5c['source']['_action'](_0x57bf18);}),_0x39fd9f(_0x5f16b7,_0x360762,{'role':'menu'}),_0x5f16b7['listenTo'](_0x57bf18,'change:isActionsDropdownOpen',(_0x27ca45,_0x182e86,_0x3e30c0)=>{if(_0x3e30c0)for(const _0x5dbb76 of _0x5f16b7['listView']['items']){const _0x554bbb=_0x5dbb76['children']['first'],_0x3c8be8=_0x13cf75['find'](_0x435936=>_0x435936['action']===_0x554bbb['_action'])['isVisible'];_0x5dbb76['isVisible']=void 0x0===_0x3c8be8||_0x3c8be8(_0x57bf18);}}),_0x5f16b7;}class _i extends/* #__PURE__ -- @preserve */
|
|
27
|
+
_0x4e9a07(_0x4c679a){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0xfd13ca,_0x2c34f9,_0x3314bf,_0x5a1257){super(_0xfd13ca);const _0x1b88cb=this['bindTemplate'],_0x24743f=function(_0x3ab045,_0x4b8ae1){const _0x531ff8=Array['from'](_0x4b8ae1['authors'])['filter'](_0x24920e=>_0x24920e!=_0x4b8ae1['creator']);return _0x4b8ae1['creator']&&_0x531ff8['unshift'](_0x4b8ae1['creator']),_0x531ff8['map'](_0x570e64=>new ni(_0x3ab045,_0x570e64,_0x570e64==_0x4b8ae1['creator']));}(_0xfd13ca,_0x2c34f9);this['id']=_0x2c34f9['id'],this['_revision']=_0x2c34f9,this['_requireRevisionName']=_0x5a1257,this['bind']('name','createdAt')['to'](_0x2c34f9),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x1160e5=>{return _0x1d152b=_0xfd13ca['uiLanguage'],(_0x8852b2=_0x1160e5)['toLocaleDateString'](_0x1d152b,{'month':'long','day':'numeric'})+',\x20'+_0x8852b2['toLocaleTimeString'](_0x1d152b,{'hour':'numeric','minute':'numeric'});var _0x1d152b,_0x8852b2;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new hi(_0xfd13ca,ti),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x3ace98=>_0x3ace98||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x22044b,_0x7ad16f)=>_0x22044b&&_0x7ad16f),this['revisionActionsView']=_0x3314bf&&_0x3314bf['length']?ai(this,_0x3314bf):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x1b88cb['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x1b88cb['if']('isEnabled','ck-disabled',_0x17eb5c=>!_0x17eb5c),_0x1b88cb['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x1b88cb['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x1b88cb['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':_0x1b88cb['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':_0x24743f}]},this['revisionActionsView']],'on':{'click':_0x1b88cb['to'](_0x2f0c07=>{_0x2f0c07['srcElement']['closest']('.ck-confirm-view')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x4e3e16=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x4e3e16,'change',()=>{this['_requireRevisionName']&&!_0x4e3e16['value']||this['fire']('setName',{'id':this['id'],'name':_0x4e3e16['value']}),_0x4e3e16['value']||(_0x4e3e16['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(_0x1ed4b8,_0x3b5e6e){const _0x18e10e=_0x11c9f8['fromJSDate'](_0x1ed4b8)['setLocale'](_0x3b5e6e),_0xa898f6=_0x11c9f8['local'](),_0x303400=_0xa898f6['minus']({'days':0x1})['startOf']('day');let _0x38f053,_0x11ae48;return _0x18e10e['hasSame'](_0xa898f6,'day')?(_0x38f053=_0x18e10e['startOf']('day')['toJSDate'](),_0x11ae48=_0x18e10e['toRelativeCalendar']()):_0x18e10e['hasSame'](_0x303400,'day')?(_0x38f053=_0x303400['toJSDate'](),_0x11ae48=_0x18e10e['toRelativeCalendar']()):_0x18e10e['hasSame'](_0xa898f6,'week')?(_0x38f053=_0x18e10e['startOf']('week')['toJSDate'](),_0x11ae48=_0x18e10e['weekdayLong']||''):_0x18e10e['hasSame'](_0xa898f6,'year')?(_0x38f053=_0x18e10e['startOf']('month')['toJSDate'](),_0x11ae48=_0x18e10e['monthLong']||''):(_0x38f053=_0x18e10e['startOf']('year')['toJSDate'](),_0x11ae48=String(_0x18e10e['year'])),{'startDate':_0x38f053,'localizedPeriodName':_0x11ae48};}class ji extends _0x4c679a{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x3ac48c,_0x23643e,_0x128738,_0x26433b){super(_0x3ac48c);const _0x1b89f3=bi(_0x23643e,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x23643e,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x128738,this['_requireRevisionName']=_0x26433b,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':_0x1b89f3}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x23719a){const _0xa05f51=new _i(this['locale'],_0x23719a,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0xa05f51);}['removeRevision'](_0x5eaed6){const _0xc2c0b1=this['revisionViews']['find'](_0x216436=>_0x216436['id']===_0x5eaed6['id']);this['revisionViews']['remove'](_0xc2c0b1);}}class Si extends _0x4c679a{constructor(_0x4d41cd){super(_0x4d41cd);const _0x5e52e8=new _0x26c7e2();_0x5e52e8['content']=_0x3f5198,this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x5e52e8,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[m(_0x4d41cd,'Revision\x20history')]}]});}}class Ri extends _0x4c679a{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x16ac60,_0x4a8498,_0x1013e5,_0x50accb){super(_0x16ac60);const _0x4ee4ad=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x4a8498,this['_revisionActions']=_0x1013e5,this['_requireRevisionName']=_0x50accb,this['on']('select',(_0x599ed5,_0x2903e7)=>{this['fire']('revisionSelected',_0x2903e7);}),this['on']('setName',(_0x3ba7cb,_0x57fe24)=>{this['fire']('revisionSetName',_0x57fe24);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new Si(_0x16ac60),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x4ee4ad['if']('isEnabled','ck-disabled',_0x4d9f9f=>!_0x4d9f9f)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x2c8eb5 of this['_revisions'])this['_addRevision'](_0x2c8eb5);this['_revisions']['on']('add',(_0x3745aa,_0x28d339)=>{this['_addRevision'](_0x28d339);}),this['_revisions']['on']('remove',(_0x594330,_0x5b6b9d)=>{this['_removeRevision'](_0x5b6b9d);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0xb27db7=>_0xb27db7['revisionViews']['map'](_0x198171=>_0x198171))['flat']();}['selectRevision'](_0x1176fe){for(const _0x8fac95 of this['revisionViews'])_0x1176fe&&_0x1176fe['id']===_0x8fac95['id']?_0x8fac95['select']():_0x8fac95['deselect']();}['highlightRevisions'](_0x7d3f76){for(const _0x4d4b48 of this['revisionViews'])_0x7d3f76['some'](({id:_0x211624})=>_0x211624===_0x4d4b48['id'])?_0x4d4b48['highlight']():_0x4d4b48['unhighlight']();}['_addRevision'](_0x4c66d1){const _0x1b0716=bi(_0x4c66d1['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x27132c=this['timePeriodViews']['get'](0x0);_0x27132c&&_0x27132c['startDate']['getTime']()===_0x1b0716['getTime']()||(_0x27132c=new ji(this['locale'],_0x1b0716,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x27132c)),_0x27132c['addRevision'](_0x4c66d1);}['_removeRevision'](_0x1589f5){const _0x4ebb46=bi(_0x1589f5['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x4ebb46)['removeRevision'](_0x1589f5);}['_getTimePeriodViewByStartDate'](_0x3240a7){return this['timePeriodViews']['find'](_0x5b139a=>_0x5b139a['startDate']['getTime']()===_0x3240a7['getTime']());}}class d extends _0x2bce4d{['_revisionViewer'];['_revisionsRepository'];['_sidebarView'];static ['defaultRevisionActions']=/* #__PURE__ -- @preserve */
|
|
28
28
|
((()=>['compareAgainstSelected','restoreRevision','nameRevision'])());static ['availableRevisionActions']=/* #__PURE__ -- @preserve */
|
|
29
|
-
|
|
30
|
-
_0x4e63f0(_0x168dde){['_ui'];get['ui'](){return this['_ui'];}constructor(_0xa11d04,_0x31b86a){super(_0x31b86a),this['sourceElement']=_0xa11d04,this['model']['document']['createRoot']();const _0x1423a8=new ii(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new Z(this,_0x1423a8);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x41215c,_0x1c3d8f){const _0x595e58=new this(_0x41215c,_0x1c3d8f);return await _0x595e58['initPlugins'](),await _0x595e58['ui']['init'](_0x41215c),await _0x595e58['data']['init'](_0x595e58['config']['get']('initialData')||''),_0x595e58['fire']('ready'),_0x595e58;}}const p=['RevisionHistoryUI','RestrictedEditingMode','AIChat','AIReviewMode','AIBalloon','AIQuickActions','AIActions'];class at extends _0xb302f2{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x1bff40){function _0x1a0183(_0x4f69df){return _0x4f69df['map'](_0x505a6b=>String['fromCharCode'](_0x505a6b))['join']('');}super(_0x1bff40),this['result']='end',_0x1bff40[_0x1a0183([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x1a0183([0x76,0x69,0x65,0x77])][_0x1a0183([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x1a0183([0x61,0x75,0x74,0x6f]),_0x1bff40[_0x1a0183([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x1a0183([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x1a0183([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x1a0183([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x1a0183([0x6f,0x6b])});}}class ht extends _0xb302f2{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h,l];}constructor(_0x3026a6){if(super(_0x3026a6),!this['editor']['config']['get']('revisionHistory'))throw new _0xd34d2c('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x30ee4c=>this['_showRevisionViewer']({..._0x30ee4c,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x4f99b1=>this['_closeRevisionViewer'](_0x4f99b1)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x3b2c60=>this['_restoreRevision'](_0x3b2c60)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x40598b){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x40598b;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x1f5376){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x1f5376);}['getRevision'](_0x126d22){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x126d22);}['getRevisions'](_0x3f5cdd){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x3f5cdd||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x6ebfed=this['editor'],_0x5c7ade=_0x3acf91(_0x6ebfed,p),_0x3a3a8b=_0x6ebfed['plugins']['get']('RevisionTracker'),_0x45baad=_0x6ebfed['plugins']['get']('Users')['users'];return _0x5c7ade['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x5c7ade['lazyRoots'],(_0x5c7ade['plugins']['push'](at,u,v,class extends _0xb302f2{static get['requires'](){return[u,'Users'];}['init'](){const _0x47d8e7=this['editor']['plugins']['get']('Users');for(const _0x3b5de1 of _0x45baad)_0x3b5de1['isAnonymous']||_0x47d8e7['getUser'](_0x3b5de1['id'])||_0x47d8e7['addUser'](_0x3b5de1);const _0x4d14ff=_0x3a3a8b['repository']['getRevisions']();let _0x5e1ddc=null;const _0x4c9465=this['editor']['plugins']['get']('RevisionViewer');_0x4c9465['adapter']=_0x3a3a8b['adapter'],_0x4c9465['bind']('isEnabled')['to'](_0x3a3a8b),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x6ebfed,'isReadOnly',_0x4a2bd4=>!_0x4a2bd4);for(const _0x37135d of _0x4d14ff){const _0x56c497=null===_0x37135d['creator'];if(_0x56c497&&_0x37135d['toVersion']===_0x37135d['fromVersion'])continue;const _0x3694bd=_0x37135d['toJSON']();_0x4c9465['addRevisionData'](_0x3694bd,(_0x2deb37,_0xed72c6,_0x2d71fc)=>{if(_0x56c497){if(_0x5e1ddc)_0x5e1ddc['_update'](_0x2deb37,_0xed72c6);else{if(!_0xed72c6){const _0x52408e=_0x2d71fc['toJSON']();_0x52408e['id']=_0x40f93b(),_0x3a3a8b['saveRevision'](_0x52408e,_0x2d71fc['toVersion'])['then'](_0x226946=>{_0x5e1ddc=_0x226946;});}}}else _0x37135d['_update'](_0x2deb37,_0xed72c6);});}}},d),_0x5c7ade);}['_enhanceShowRevisionViewerCallback'](){const _0x4e5b39=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x457afb=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x153dfa=this['editor']['plugins']['get']('Autosave');await _0x153dfa['save']();}else await _0x457afb['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x5840d2=this['editor']['plugins']['get']('Dialog');_0x5840d2['isOpen']&&_0x5840d2['hide']();}if(this['editor']['plugins']['has']('AITabs')){const _0x11e19e=this['editor']['plugins']['get']('AITabs')['view']['panelViews'];for(const _0x1e51a1 of _0x11e19e)_0x1e51a1['class']=_0x1e51a1['class']?_0x1e51a1['class']+'\x20ck-tab-panel_disabled':'ck-tab-panel_disabled';if(this['editor']['plugins']['has']('AIChat')){const _0x121741=document['querySelector']('.ck-ai-chat__prompt-input\x20.ck-textarea');_0x121741&&_0x121741['setAttribute']('tabindex','-1');}if(this['editor']['plugins']['has']('AIChatHistory')){const _0x546956=document['querySelector']('.ck-ai-chat-history\x20.ck-input');_0x546956&&_0x546956['setAttribute']('tabindex','-1');}}const _0x4319eb=this['_getRevisionViewerEditorConfig']();return _0x4e5b39(_0x4319eb)['then'](_0x1cd04c=>{return(this['_viewerEditor']=_0x1cd04c,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'),_0x1cd04c);})['catch'](_0xcfec51=>(console['error'](_0xcfec51),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x187b6=this['editor']['config']['get']('revisionHistory')['closeRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.closeRevisionViewerCallback',()=>{if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('DocumentOutline')&&(this['editor']['plugins']['get']('DocumentOutlineUI')['view']['element']['style']['display']=''),this['editor']['plugins']['has']('AITabs')){const _0x17ca7a=this['editor']['plugins']['get']('AITabs')['view']['panelViews'];for(const _0x1fef3b of _0x17ca7a)_0x1fef3b['class']='ck-tab-panel_disabled'===_0x1fef3b['class']?'':_0x1fef3b['class']['replace']('\x20ck-tab-panel_disabled','');if(this['editor']['plugins']['has']('AIChat')){const _0x1f06d3=document['querySelector']('.ck-ai-chat__prompt-input\x20.ck-textarea');_0x1f06d3&&_0x1f06d3['removeAttribute']('tabindex');}if(this['editor']['plugins']['has']('AIChatHistory')){const _0x335f68=document['querySelector']('.ck-ai-chat-history\x20.ck-input');_0x335f68&&_0x335f68['removeAttribute']('tabindex');}}return this['_viewerEditor']['plugins']['get']('RevisionViewer')['_cleanUp'](),_0x187b6(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x3215d3=this['editor']['plugins']['get']('Annotations');_0x3215d3['refreshVisibility'](),_0x3215d3['refreshPositioning']();}});});}['_showRevisionViewer'](_0x155a78){const _0x59dd5e=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x5dea0a=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x1316e8=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return f['create'](_0x1316e8,_0x155a78)['then'](_0x12a8e6=>(_0x5dea0a['style']['display']='block',_0x59dd5e['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x12a8e6));}['_closeRevisionViewer'](_0x2ab375){const _0x8eeeb3=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x8eeeb3['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x2ab375['destroy']();}async['_restoreRevision'](_0x255dfc){const _0x56472c=this['editor'],_0x46a9fd=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x4fa0ce=_0x56472c['plugins']['get']('RevisionTracker'),_0x3722e3=_0x56472c['plugins']['get']('RevisionHistoryUtils'),_0x5cd14c=_0x46a9fd['repository']['getRevision'](_0x255dfc);let _0x40a804,_0x24ee1f,_0x2b543b;try{await _0x3722e3['loadRevisionData'](_0x5cd14c,this['adapter']),_0x40a804=_0x3722e3['getRevisionDocumentData'](_0x5cd14c),_0x24ee1f=_0x3722e3['getRevisionRootsAttributes'](_0x5cd14c);}catch(_0x37922b){return void console['error'](_0x37922b);}_0x56472c['model']['change'](_0x51b3e8=>{for(const _0x3bd2e9 of Array['from'](_0x56472c['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x51b3e8['removeMarker'](_0x3bd2e9);}),_0x46a9fd['isReady']=!0x1,_0x56472c['model']['enqueueChange'](_0x331d89=>{_0x331d89['setSelection'](null),_0x331d89['removeSelectionAttribute'](_0x56472c['model']['document']['selection']['getAttributeKeys']());const _0x3bdf25=Object['keys'](_0x40a804);for(const _0x37ce3b of _0x56472c['model']['document']['roots'])'$graveyard'!=_0x37ce3b['rootName']&&_0x37ce3b['isAttached']()&&!_0x3bdf25['includes'](_0x37ce3b['rootName'])&&_0x331d89['detachRoot'](_0x37ce3b);for(const _0xed5811 of _0x3bdf25){let _0x5ca8f6=_0x56472c['model']['document']['getRoot'](_0xed5811);_0x5ca8f6&&_0x5ca8f6['isAttached']()||(_0x5ca8f6=_0x331d89['addRoot'](_0xed5811));const _0x370865=_0x24ee1f[_0xed5811],_0x3a11fc=Object['keys'](_0x370865),_0xb54894=_0x40a804[_0xed5811];for(const _0x12cfba of _0x5ca8f6['getAttributeKeys']())_0x3a11fc['includes'](_0x12cfba)||_0x331d89['removeAttribute'](_0x12cfba,_0x5ca8f6);for(const _0x502585 of _0x3a11fc)_0x331d89['setAttribute'](_0x502585,_0x24ee1f[_0xed5811][_0x502585],_0x5ca8f6);_0x331d89['remove'](_0x331d89['createRangeIn'](_0x5ca8f6)),_0x331d89['insert'](_0x56472c['data']['parse'](_0xb54894,_0x5ca8f6),_0x5ca8f6,0x0);}});const _0x130586=m(_0x56472c['locale'],'Restored');if(_0x5cd14c['name'])_0x2b543b=-0x1==_0x5cd14c['name']['indexOf'](_0x130586)?_0x130586+':\x20'+_0x5cd14c['name']:_0x5cd14c['name'];else _0x2b543b=_0x130586+':\x20'+(_0x5cd14c['createdAt']['toLocaleDateString'](_0x56472c['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x5cd14c['createdAt']['toLocaleTimeString'](_0x56472c['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x4fa0ce['saveRevision']({'name':_0x2b543b}),_0x46a9fd['isReady']=!0x0,_0x56472c['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{nt as RestoreRevisionCommand,I as Revision,ht as RevisionHistory,l as RevisionHistoryUI,$ as RevisionHistoryUtils,h as RevisionTracker,u as RevisionViewer,f as RevisionViewerEditor,at as RevisionViewerIntegration,vi as RevisionViewerLoadingOverlay,v as RevisionViewerUI,S as RevisionsRepository,d as RevisionsSidebar,ot as ShowChangeCommand};
|
|
29
|
+
at();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u];}constructor(_0x47a0aa){super(_0x47a0aa),this['_revisionViewer']=_0x47a0aa['plugins']['get'](u),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x5eb69b=this['_revisionsRepository']['_revisions'],_0x839629=this['_createRevisionActions'](),_0x2c476f=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new Ri(this['editor']['locale'],_0x5eb69b,_0x839629,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',(_0x1522ae,_0x39e520)=>{_0x39e520['revisionViews']['on']('add',(_0xd8d80f,_0x296439)=>{_0x296439['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)),_0x2c476f['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x107134=this['_revisionsRepository']['getRevision'](0x0);if(_0x107134){const _0x150081=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x107134['id']);this['_revisionViewer']['compare'](_0x107134,_0x150081);}}['_handleRevisionSelected'](_0x4f4431,_0x522a44){const _0x26deda=this['_revisionsRepository']['getRevision'](_0x522a44['id']),_0x48692=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x26deda['id']);this['_revisionViewer']['compare'](_0x26deda,_0x48692);}['_handleRevisionSetName'](_0x1dad47,_0x307695){this['_revisionsRepository']['getRevision'](_0x307695['id'])['setName'](_0x307695['name']);}['_handleDiffChange'](_0x2f44a2,_0x46e003,_0x48b8a9){const _0x4aa809=this['_revisionsRepository']['getRevisionsInDiff'](_0x48b8a9);_0x4aa809['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x4aa809),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x4aa809[0x0]));}['_createRevisionActions'](){const _0x37a967=this['editor'],_0x2152ab=d['availableRevisionActions'],_0x57bf61=_0x37a967['config']['get']('revisionHistory.revisionActions')||d['defaultRevisionActions'];if(_0x57bf61['length'])return _0x57bf61['map'](_0x23e47b=>{const _0x4b6f6d='string'==typeof _0x23e47b?Object['assign']({},_0x2152ab[_0x23e47b]):_0x23e47b;return _0x4b6f6d['action']=_0x4b6f6d['action']['bind'](this,_0x37a967),_0x4b6f6d['isVisible']&&(_0x4b6f6d['isVisible']=_0x4b6f6d['isVisible']['bind'](this,_0x37a967)),_0x4b6f6d;});}}function at(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x4e2c85},_0x2ff2f4)=>{const _0x52342c=_0x4e2c85['get'](u),_0x5baafa=_0x52342c['repository'];let _0x3fb8e8=_0x52342c['diff']['newRevisionId'],_0x1db14f=_0x2ff2f4['id'];_0x5baafa['getIndex'](_0x3fb8e8)>_0x5baafa['getIndex'](_0x1db14f)&&([_0x3fb8e8,_0x1db14f]=[_0x1db14f,_0x3fb8e8]),_0x52342c['compare'](_0x3fb8e8,_0x1db14f);},'isVisible':({plugins:_0x464839},_0x3e60df)=>{const _0x300e99=_0x464839['get'](u);return!(_0x300e99['repository']['getRevisionsInDiff'](_0x300e99['diff'])['length']>0x2)&&!_0x3e60df['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x4f41db,{id:_0x15e6fc})=>{_0x4f41db['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x15e6fc);},'isVisible':({plugins:_0x466091},_0x587613)=>!!_0x466091['get'](u)['repository']['getLaterVisibleRevision'](_0x587613['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x1d72ab},{id:_0x1a13b9,revisionNameView:_0x359f63})=>{const _0x2d42bd=_0x1d72ab['get'](u),_0x2d0dca=_0x2d42bd['repository']['getEarlierVisibleRevision'](_0x1a13b9);_0x2d42bd['compare'](_0x1a13b9,_0x2d0dca),_0x359f63['focus'](),_0x359f63['fieldView']['select']();}}};}class Z extends tt{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x61e7f1,_0x197b92){super(_0x61e7f1),this['_view']=_0x197b92,this['_toolbarConfig']=st(_0x61e7f1['config']['get']('toolbar')),this['_elementReplacer']=new it();}get['element'](){return this['view']['element'];}['init'](_0x3df6d0){const _0x2014fa=this['editor'],_0x1a5a65=this['view'],_0x1864f6=_0x2014fa['editing']['view'],_0x3762a1=_0x1a5a65['editable'],_0x8fd9a1=_0x1864f6['document']['getRoot']();_0x3762a1['name']=_0x8fd9a1['rootName'],_0x1a5a65['render']();const _0x173ea3=_0x3762a1['element'];this['setEditableElement'](_0x3762a1['name'],_0x173ea3),_0x1a5a65['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x1864f6['attachDomRoot'](_0x173ea3),this['_elementReplacer']['replace'](_0x3df6d0,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x5e4f81=this['view'],_0x5c17a5=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x5c17a5['detachDomRoot'](_0x5e4f81['editable']['name']),_0x5e4f81['destroy']();}['_initToolbar'](){const _0x18dafc=this['view'];_0x18dafc['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x18dafc['stickyPanel']['limiterElement']=_0x18dafc['element'],_0x18dafc['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x28eda})=>_0x28eda),_0x18dafc['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x18dafc['toolbar']);}}class ii extends _0x21096b{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0xef71c8,_0x17a320,_0x490ea8={}){super(_0xef71c8),this['stickyPanel']=new _0x267fea(_0xef71c8),this['toolbar']=new _0x2a39c7(_0xef71c8,{'shouldGroupWhenFull':_0x490ea8['shouldToolbarGroupWhenFull']}),this['_editable']=new te(_0xef71c8,_0x17a320);}['render'](){super['render'](),this['stickyPanel']['content']['add'](this['toolbar']),this['top']['add'](this['stickyPanel']),this['main']['add'](this['editable']);}}class f extends/* #__PURE__ -- @preserve */
|
|
30
|
+
_0x335ce4(_0x43bc7b){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x451214,_0x360431){super(_0x360431),this['sourceElement']=_0x451214,this['model']['document']['createRoot']();const _0x398a24=new ii(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new Z(this,_0x398a24);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x422699,_0x2363f7){const _0x5db86f=new this(_0x422699,_0x2363f7);return await _0x5db86f['initPlugins'](),await _0x5db86f['ui']['init'](_0x422699),await _0x5db86f['data']['init'](_0x5db86f['config']['get']('initialData')||''),_0x5db86f['fire']('ready'),_0x5db86f;}}const p=['RevisionHistoryUI','RestrictedEditingMode','AIChat','AIReviewMode','AIBalloon','AIQuickActions','AIActions'];class ht extends _0x2bce4d{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x3115ca){function _0x16361f(_0x5324aa){return _0x5324aa['map'](_0x3d8d12=>String['fromCharCode'](_0x3d8d12))['join']('');}super(_0x3115ca),this['result']='end',_0x3115ca[_0x16361f([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x16361f([0x76,0x69,0x65,0x77])][_0x16361f([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x16361f([0x61,0x75,0x74,0x6f]),_0x3115ca[_0x16361f([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x16361f([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x16361f([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x16361f([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x16361f([0x6f,0x6b])});}}class ct extends _0x2bce4d{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h,l];}constructor(_0x33b1f7){if(super(_0x33b1f7),!this['editor']['config']['get']('revisionHistory'))throw new _0x5a9728('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x156b82=>this['_showRevisionViewer']({..._0x156b82,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x520197=>this['_closeRevisionViewer'](_0x520197)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x5d4864=>this['_restoreRevision'](_0x5d4864)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x482581){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x482581;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x2942b2){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x2942b2);}['getRevision'](_0x259590){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x259590);}['getRevisions'](_0x19baac){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x19baac||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x1e63e6=this['editor'],_0xcc5486=_0x4af87c(_0x1e63e6,p),_0x2c68d7=_0x1e63e6['plugins']['get']('RevisionTracker'),_0x5d5f40=_0x1e63e6['plugins']['get']('Users')['users'];return _0xcc5486['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0xcc5486['lazyRoots'],(_0xcc5486['plugins']['push'](ht,u,v,class extends _0x2bce4d{static get['requires'](){return[u,'Users'];}['init'](){const _0x498041=this['editor']['plugins']['get']('Users');for(const _0x348631 of _0x5d5f40)_0x348631['isAnonymous']||_0x498041['getUser'](_0x348631['id'])||_0x498041['addUser'](_0x348631);const _0x2fe356=_0x2c68d7['repository']['getRevisions']();let _0x39c906=null;const _0xb7b4d=this['editor']['plugins']['get']('RevisionViewer');_0xb7b4d['adapter']=_0x2c68d7['adapter'],_0xb7b4d['bind']('isEnabled')['to'](_0x2c68d7),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x1e63e6,'isReadOnly',_0x48854e=>!_0x48854e);for(const _0x4d4b65 of _0x2fe356){const _0x31c0f9=null===_0x4d4b65['creator'];if(_0x31c0f9&&_0x4d4b65['toVersion']===_0x4d4b65['fromVersion'])continue;const _0x3b7285=_0x4d4b65['toJSON']();_0xb7b4d['addRevisionData'](_0x3b7285,(_0x33286a,_0x4d3d85,_0x5863dc)=>{if(_0x31c0f9){if(_0x39c906)_0x39c906['_update'](_0x33286a,_0x4d3d85);else{if(!_0x4d3d85){const _0x2f9616=_0x5863dc['toJSON']();_0x2f9616['id']=_0x3bb1d9(),_0x2c68d7['saveRevision'](_0x2f9616,_0x5863dc['toVersion'])['then'](_0x249204=>{_0x39c906=_0x249204;});}}}else _0x4d4b65['_update'](_0x33286a,_0x4d3d85);});}}},d),_0xcc5486);}['_enhanceShowRevisionViewerCallback'](){const _0x5f507d=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x990f25=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x1721a2=this['editor']['plugins']['get']('Autosave');await _0x1721a2['save']();}else await _0x990f25['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x1ef6d5=this['editor']['plugins']['get']('Dialog');_0x1ef6d5['isOpen']&&_0x1ef6d5['hide']();}if(this['editor']['plugins']['has']('AITabs')){const _0x4cfaf6=this['editor']['plugins']['get']('AITabs')['view']['panelViews'];for(const _0x40498d of _0x4cfaf6)_0x40498d['class']=_0x40498d['class']?_0x40498d['class']+'\x20ck-tab-panel_disabled':'ck-tab-panel_disabled';if(this['editor']['plugins']['has']('AIChat')){const _0x5037a6=document['querySelector']('.ck-ai-chat__prompt-input\x20.ck-textarea');_0x5037a6&&_0x5037a6['setAttribute']('tabindex','-1');}if(this['editor']['plugins']['has']('AIChatHistory')){const _0x263764=document['querySelector']('.ck-ai-chat-history\x20.ck-input');_0x263764&&_0x263764['setAttribute']('tabindex','-1');}}const _0x55c968=this['_getRevisionViewerEditorConfig']();return _0x5f507d(_0x55c968)['then'](_0x2f3754=>{return(this['_viewerEditor']=_0x2f3754,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'),_0x2f3754);})['catch'](_0xe6e805=>(console['error'](_0xe6e805),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x3d34ce=this['editor']['config']['get']('revisionHistory')['closeRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.closeRevisionViewerCallback',()=>{if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('DocumentOutline')&&(this['editor']['plugins']['get']('DocumentOutlineUI')['view']['element']['style']['display']=''),this['editor']['plugins']['has']('AITabs')){const _0x196c52=this['editor']['plugins']['get']('AITabs')['view']['panelViews'];for(const _0x3119da of _0x196c52)_0x3119da['class']='ck-tab-panel_disabled'===_0x3119da['class']?'':_0x3119da['class']['replace']('\x20ck-tab-panel_disabled','');if(this['editor']['plugins']['has']('AIChat')){const _0x28c93b=document['querySelector']('.ck-ai-chat__prompt-input\x20.ck-textarea');_0x28c93b&&_0x28c93b['removeAttribute']('tabindex');}if(this['editor']['plugins']['has']('AIChatHistory')){const _0x5ba995=document['querySelector']('.ck-ai-chat-history\x20.ck-input');_0x5ba995&&_0x5ba995['removeAttribute']('tabindex');}}return this['_viewerEditor']['plugins']['get']('RevisionViewer')['_cleanUp'](),_0x3d34ce(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x252646=this['editor']['plugins']['get']('Annotations');_0x252646['refreshVisibility'](),_0x252646['refreshPositioning']();}});});}['_showRevisionViewer'](_0x1c59b1){const _0x271291=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x3e97cb=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x228b4d=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return f['create'](_0x228b4d,_0x1c59b1)['then'](_0x57b53b=>(_0x3e97cb['style']['display']='block',_0x271291['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x57b53b));}['_closeRevisionViewer'](_0x22223e){const _0x3550a6=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x3550a6['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x22223e['destroy']();}async['_restoreRevision'](_0x5511c5){const _0x2a720f=this['editor'],_0x2e3952=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x3c0493=_0x2a720f['plugins']['get']('RevisionTracker'),_0x22e2c5=_0x2a720f['plugins']['get']('RevisionHistoryUtils'),_0x25c05d=_0x2e3952['repository']['getRevision'](_0x5511c5);let _0xcad0b8,_0x1f261e,_0x5d3df3;try{await _0x22e2c5['loadRevisionData'](_0x25c05d,this['adapter']),_0xcad0b8=_0x22e2c5['getRevisionDocumentData'](_0x25c05d),_0x1f261e=_0x22e2c5['getRevisionRootsAttributes'](_0x25c05d);}catch(_0x333fbd){return void console['error'](_0x333fbd);}_0x2a720f['model']['change'](_0x4416b2=>{for(const _0x277943 of Array['from'](_0x2a720f['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x4416b2['removeMarker'](_0x277943);}),_0x2e3952['isReady']=!0x1,_0x2a720f['model']['enqueueChange'](_0x51bc9f=>{_0x51bc9f['setSelection'](null),_0x51bc9f['removeSelectionAttribute'](_0x2a720f['model']['document']['selection']['getAttributeKeys']());const _0x412d77=Object['keys'](_0xcad0b8);for(const _0x3a0cb5 of _0x2a720f['model']['document']['roots'])'$graveyard'!=_0x3a0cb5['rootName']&&_0x3a0cb5['isAttached']()&&!_0x412d77['includes'](_0x3a0cb5['rootName'])&&_0x51bc9f['detachRoot'](_0x3a0cb5);for(const _0x12f2d2 of _0x412d77){let _0x119284=_0x2a720f['model']['document']['getRoot'](_0x12f2d2);_0x119284&&_0x119284['isAttached']()||(_0x119284=_0x51bc9f['addRoot'](_0x12f2d2));const _0x16b491=_0x1f261e[_0x12f2d2],_0x18ceac=Object['keys'](_0x16b491),_0x17b808=_0xcad0b8[_0x12f2d2];for(const _0x5a2f63 of _0x119284['getAttributeKeys']())_0x18ceac['includes'](_0x5a2f63)||_0x51bc9f['removeAttribute'](_0x5a2f63,_0x119284);for(const _0x1d00bb of _0x18ceac)_0x51bc9f['setAttribute'](_0x1d00bb,_0x1f261e[_0x12f2d2][_0x1d00bb],_0x119284);_0x51bc9f['remove'](_0x51bc9f['createRangeIn'](_0x119284)),_0x51bc9f['insert'](_0x2a720f['data']['parse'](_0x17b808,_0x119284),_0x119284,0x0);}});const _0x35f392=m(_0x2a720f['locale'],'Restored');if(_0x25c05d['name'])_0x5d3df3=-0x1==_0x25c05d['name']['indexOf'](_0x35f392)?_0x35f392+':\x20'+_0x25c05d['name']:_0x25c05d['name'];else _0x5d3df3=_0x35f392+':\x20'+(_0x25c05d['createdAt']['toLocaleDateString'](_0x2a720f['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x25c05d['createdAt']['toLocaleTimeString'](_0x2a720f['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x3c0493['saveRevision']({'name':_0x5d3df3}),_0x2e3952['isReady']=!0x0,_0x2a720f['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{nt as RestoreRevisionCommand,I as Revision,ct as RevisionHistory,l as RevisionHistoryUI,$ as RevisionHistoryUtils,h as RevisionTracker,u as RevisionViewer,f as RevisionViewerEditor,ht as RevisionViewerIntegration,wi as RevisionViewerLoadingOverlay,v as RevisionViewerUI,S as RevisionsRepository,d as RevisionsSidebar,rt as ShowChangeCommand};
|