@ckeditor/ckeditor5-revision-history 48.2.0-alpha.5 → 48.2.0-alpha.7
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/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 +10 -10
package/dist/index.js
CHANGED
|
@@ -20,11 +20,11 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
import{ObservableMixin as
|
|
24
|
-
_0x4cbe68(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x21f77e){super(),this['id']=_0x21f77e['id']||_0x55087c(),this['creator']=_0x21f77e['creator']||null,this['authors']=_0x21f77e['authors']||[],this['diffData']=_0x21f77e['diffData']||null,this['toVersion']=_0x21f77e['toVersion']||0x0,this['fromVersion']=_0x21f77e['fromVersion']||0x0,this['set']('name',_0x21f77e['name']||''),this['set']('createdAt',_0x21f77e['createdAt']||new Date()),this['set']('attributes',_0x21f77e['attributes']||{});}['setName'](_0x5c8e38){this['_update']({'name':_0x5c8e38});}['setAttribute'](_0x1d7f11,_0x40ae8d){const _0x55fa19=_0x527a66(this['attributes']);_0x19e1e7(_0x55fa19,_0x1d7f11,_0x40ae8d),this['_update']({'attributes':_0x55fa19});}['removeAttribute'](_0x430546){const _0x31cc29=_0x527a66(this['attributes']);_0x1fc4f8(_0x31cc29,_0x430546),this['_update']({'attributes':_0x31cc29});}['_update'](_0xa00809,_0x2906e5=!0x1){let _0x130b4b=!0x1;const _0x41efd5={'id':this['id']},_0x506259=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x4bb097 of _0x506259){const _0x401272=_0xa00809[_0x4bb097];void 0x0!==_0x401272&&_0x401272!==this[_0x4bb097]&&(this[_0x4bb097]=_0x401272,_0x41efd5[_0x4bb097]=_0x401272,_0x130b4b=!0x0);}_0x130b4b&&(_0x41efd5['authors']&&(_0x41efd5['authorsIds']=_0x41efd5['authors']['map'](_0xcc67df=>_0xcc67df['id']),delete _0x41efd5['authors']),this['fire']('_update',_0x41efd5,_0x2906e5));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x4b1968=>_0x4b1968['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class RevisionsRepository extends _0x18ed42{['_revisions'];static get['requires'](){return[_0x4c4887];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x20b87b){super(_0x20b87b),this['_revisions']=new _0x12a0e4();}['afterInit'](){!async function(_0x5165bc){const _0x498677=_0x5d1c7d([0x76,0x73,0x6d,0x4c,0x34,0x54,0x50,0x70,0x75,0x52,0x35,0x33,0x4d,0x6c,0x71,0x53,0x6a,0x32,0x56,0x58,0x77,0x48,0x39,0x6f,0x45,0x41,0x4e,0x38,0x46,0x78,0x4a,0x74,0x47,0x55,0x4f,0x64,0x62,0x44,0x43,0x5a,0x30,0x31,0x69,0x68,0x79,0x66,0x6b,0x42,0x51,0x59,0x36,0x61,0x63,0x67,0x7a,0x37,0x72,0x49,0x65,0x57,0x4b,0x6e]),_0xaca41c=0xeb829,_0x440da4=0x359e09b0,_0x481ac3=0x35998208^_0x440da4,_0x8bb4ad=window[_0x5d1c7d([0x44,0x61,0x74,0x65])][_0x5d1c7d([0x6e,0x6f,0x77])](),_0x43c3f7=_0x5165bc[_0x5d1c7d([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x2b70d4=new window[(_0x5d1c7d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x61a5da=>{_0x43c3f7[_0x5d1c7d([0x6f,0x6e,0x63,0x65])](_0x5d1c7d([0x72,0x65,0x61,0x64,0x79]),_0x61a5da);}),_0x497bae={[_0x5d1c7d([0x6b,0x74,0x79])]:_0x5d1c7d([0x45,0x43]),[_0x5d1c7d([0x75,0x73,0x65])]:_0x5d1c7d([0x73,0x69,0x67]),[_0x5d1c7d([0x63,0x72,0x76])]:_0x5d1c7d([0x50,0x2d,0x32,0x35,0x36]),[_0x5d1c7d([0x78])]:_0x5d1c7d([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]),[_0x5d1c7d([0x79])]:_0x5d1c7d([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]),[_0x5d1c7d([0x61,0x6c,0x67])]:_0x5d1c7d([0x45,0x53,0x32,0x35,0x36])},_0x2b73ae=_0x43c3f7[_0x5d1c7d([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x5d1c7d([0x67,0x65,0x74])](_0x5d1c7d([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x11bf19(){let _0x548977,_0x2f5160=null,_0x2e1c4a=null;try{if(_0x2b73ae==_0x5d1c7d([0x47,0x50,0x4c]))return _0x5d1c7d([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x548977=_0x272516(),!_0x548977)return _0x5d1c7d([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x548977[_0x5d1c7d([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x2e1c4a=_0x2c4678(_0x548977[_0x5d1c7d([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x548977[_0x5d1c7d([0x6a,0x74,0x69])])),await _0x1da2ea()?_0x3cb106()?_0xe45512()?_0x5d1c7d([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x5781a4()?(_0x548977[_0x5d1c7d([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x5d1c7d([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x2f5160=_0x852988(_0x5d1c7d([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),await _0x420fca()):_0x5d1c7d([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x5d1c7d([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x5d1c7d([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x5d1c7d([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0xe45512(){const _0x5783f9=[_0x5d1c7d([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x5d1c7d([0x74,0x72,0x69,0x61,0x6c])][_0x5d1c7d([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x548977[_0x5d1c7d([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x8bb4ad/0x3e8:0xe10*_0x481ac3;return _0x548977[_0x5d1c7d([0x65,0x78,0x70])]<_0x5783f9;}function _0x3cb106(){const _0x1aec8f=_0x548977[_0x5d1c7d([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x1aec8f)return!0x1;if(_0x1aec8f[_0x5d1c7d([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x5d1c7d([0x2a])))return!0x0;if(_0x1aec8f[_0x5d1c7d([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x5d1c7d([0x52,0x48])))return!0x0;if(_0x1aec8f[_0x5d1c7d([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x5d1c7d([0x52,0x52,0x48]))){if(_0x132679())return!0x0;if(_0x4cfeb2()||_0x3a4c3a())return!0x0;}return!0x1;}function _0x5781a4(){const _0x17740e=_0x548977[_0x5d1c7d([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x17740e||0x0==_0x17740e[_0x5d1c7d([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x21fb9b}=new URL(window[_0x5d1c7d([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x17740e[_0x5d1c7d([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x21fb9b))return!0x0;const _0x27ff75=_0x21fb9b[_0x5d1c7d([0x73,0x70,0x6c,0x69,0x74])](_0x5d1c7d([0x2e]));return _0x17740e[_0x5d1c7d([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x12d628=>_0x12d628[_0x5d1c7d([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x5d1c7d([0x2a])))[_0x5d1c7d([0x6d,0x61,0x70])](_0x5b3ca2=>_0x5b3ca2[_0x5d1c7d([0x73,0x70,0x6c,0x69,0x74])](_0x5d1c7d([0x2e])))[_0x5d1c7d([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x1fa4a9=>_0x1fa4a9[_0x5d1c7d([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x27ff75[_0x5d1c7d([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x5d1c7d([0x6d,0x61,0x70])](_0xb70fe=>Array(_0x27ff75[_0x5d1c7d([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0xb70fe[_0x5d1c7d([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x5d1c7d([0x66,0x69,0x6c,0x6c])](_0xb70fe[0x0]===_0x5d1c7d([0x2a])?_0x5d1c7d([0x2a]):'')[_0x5d1c7d([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0xb70fe))[_0x5d1c7d([0x73,0x6f,0x6d,0x65])](_0x7694e9=>_0x27ff75[_0x5d1c7d([0x65,0x76,0x65,0x72,0x79])]((_0x3b0aa3,_0x1787b4)=>_0x7694e9[_0x1787b4]===_0x3b0aa3||_0x7694e9[_0x1787b4]===_0x5d1c7d([0x2a])));}function _0x420fca(){return _0x2f5160&&_0x2e1c4a?new window[(_0x5d1c7d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x45c921,_0x30aae9)=>{_0x2f5160[_0x5d1c7d([0x74,0x68,0x65,0x6e])](_0x45c921,_0x30aae9),_0x2e1c4a[_0x5d1c7d([0x74,0x68,0x65,0x6e])](_0x5ebf6e=>{_0x5ebf6e!=_0x5d1c7d([0x56,0x61,0x6c,0x69,0x64])&&_0x45c921(_0x5ebf6e);},_0x30aae9);}):_0x2f5160||_0x2e1c4a||_0x5d1c7d([0x56,0x61,0x6c,0x69,0x64]);}}function _0x2c4678(_0x8d0dfb,_0x4a76b7){return new window[(_0x5d1c7d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x5bf62a=>{if(_0x2d485c())return _0x5bf62a(_0x5d1c7d([0x56,0x61,0x6c,0x69,0x64]));_0x396914(),_0x43c3f7[_0x5d1c7d([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x5d1c7d([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x244890=!0x1;const _0x363ddd=_0x55087c();function _0x4a789d(_0xfa7733){return!!_0xfa7733&&(typeof _0xfa7733===_0x5d1c7d([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0xfa7733===_0x5d1c7d([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0xfa7733[_0x5d1c7d([0x74,0x68,0x65,0x6e])]===_0x5d1c7d([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0xfa7733[_0x5d1c7d([0x63,0x61,0x74,0x63,0x68])]===_0x5d1c7d([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x439f3a(_0xdc9052){_0x2ae6ab(_0xdc9052)[_0x5d1c7d([0x74,0x68,0x65,0x6e])](_0x4aa718=>{if(!_0x4aa718||_0x4aa718[_0x5d1c7d([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x5d1c7d([0x6f,0x6b]))return _0x5d1c7d([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x36dd10(_0x542649(_0x363ddd+_0x4a76b7))!=_0x4aa718[_0x5d1c7d([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x5d1c7d([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x5d1c7d([0x56,0x61,0x6c,0x69,0x64]);})[_0x5d1c7d([0x74,0x68,0x65,0x6e])](_0x442d2b=>(_0x3ea0d4(),_0x442d2b),()=>{const _0x3407f4=_0x57af19();return null==_0x3407f4?(_0x3ea0d4(),_0x5d1c7d([0x56,0x61,0x6c,0x69,0x64])):_0x5d1c7d(_0x8bb4ad-_0x3407f4>(0x11928db0^_0x440da4)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x5d1c7d([0x74,0x68,0x65,0x6e])](_0x5bf62a)[_0x5d1c7d([0x63,0x61,0x74,0x63,0x68])](()=>{_0x5bf62a(_0x5d1c7d([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x4f8f6e=0x35a8e730^_0x440da4;function _0x3ea0d4(){const _0x34c8cb=_0x5d1c7d([0x6c,0x6c,0x63,0x74,0x2d])+_0x36dd10(_0x542649(_0x8d0dfb)),_0x59ab01=_0x420fcb(_0x36dd10(window[_0x5d1c7d([0x4d,0x61,0x74,0x68])][_0x5d1c7d([0x63,0x65,0x69,0x6c])](_0x8bb4ad/_0x4f8f6e)));window[_0x5d1c7d([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x5d1c7d([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x34c8cb,_0x59ab01);}function _0x57af19(){const _0x2bd889=_0x5d1c7d([0x6c,0x6c,0x63,0x74,0x2d])+_0x36dd10(_0x542649(_0x8d0dfb)),_0x227ba6=window[_0x5d1c7d([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x5d1c7d([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x2bd889);return _0x227ba6?window[_0x5d1c7d([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x420fcb(_0x227ba6),0x10)*_0x4f8f6e:null;}function _0x2ae6ab(_0x5e17f9){return new window[(_0x5d1c7d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x438199,_0x4d839e)=>{_0x5e17f9[_0x5d1c7d([0x74,0x68,0x65,0x6e])](_0x438199,_0x4d839e),window[_0x5d1c7d([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x4d839e,0x359fdd70^_0x440da4);});}}_0x43c3f7[_0x5d1c7d([0x6f,0x6e])](_0x5d1c7d([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x3f87db,_0x4f5780)=>{if(_0x4f5780[0x0]!=_0x8d0dfb)return _0x5bf62a(_0x5d1c7d([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x4f5780[0x1]={..._0x4f5780[0x1],[_0x5d1c7d([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x363ddd};},{[_0x5d1c7d([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x5d1c7d([0x68,0x69,0x67,0x68])}),_0x43c3f7[_0x5d1c7d([0x6f,0x6e])](_0x5d1c7d([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x58738e=>{_0x4a789d(_0x58738e[_0x5d1c7d([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x244890=!0x0,_0x439f3a(_0x58738e[_0x5d1c7d([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x5d1c7d([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x5d1c7d([0x6c,0x6f,0x77])}),_0x2b70d4[_0x5d1c7d([0x74,0x68,0x65,0x6e])](()=>{_0x244890||_0x5bf62a(_0x5d1c7d([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x2d485c(){return _0x43c3f7[_0x5d1c7d([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x5d1c7d([0x76,0x69,0x65,0x77])][_0x5d1c7d([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x5d1c7d([0x61,0x75,0x74,0x6f]);}function _0x396914(){_0x43c3f7[_0x5d1c7d([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x5d1c7d([0x76,0x69,0x65,0x77])][_0x5d1c7d([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x5d1c7d([0x61,0x75,0x74,0x6f]);}}function _0x852988(_0x3eab18){const _0x24d2a2=[new window[(_0x5d1c7d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2f7714=>setTimeout(_0x2f7714,0x3597377c^_0x440da4)),_0x2b70d4[_0x5d1c7d([0x74,0x68,0x65,0x6e])](()=>new window[(_0x5d1c7d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x12af0d=>{const _0x765392=0x359e09b7^_0x440da4,_0x1aeb1a=_0x5165bc[_0x5d1c7d([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x20683c(){_0x1aeb1a[_0x5d1c7d([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x765392&&_0x12af0d();}_0x20683c(),_0x1aeb1a[_0x5d1c7d([0x6f,0x6e])](_0x5d1c7d([0x61,0x64,0x64]),_0x20683c);})),new window[(_0x5d1c7d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x412aaf=>{function _0x49054a(){for(const _0x58f675 in window)if(window[_0x5d1c7d([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x5d1c7d([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x58f675))&&window[_0x58f675]==_0xaca41c)return _0x412aaf();_0x43c3f7[_0x5d1c7d([0x73,0x74,0x61,0x74,0x65])]!=_0x5d1c7d([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x5d1c7d([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x49054a,0x359e1a38^_0x440da4);}_0x1e2a84(_0x5d1c7d([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x49054a();})];return window[_0x5d1c7d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x5d1c7d([0x72,0x61,0x63,0x65])](_0x24d2a2)[_0x5d1c7d([0x74,0x68,0x65,0x6e])](()=>_0x3eab18);}async function _0x281f07(){if(await _0x2b70d4,_0x1e2a84(_0x5d1c7d([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x897501=_0x5165bc[_0x5d1c7d([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x453e79=_0x5165bc[_0x5d1c7d([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])](_0x897501[_0x5d1c7d([0x69,0x64])]),_0x5d1438=_0x15c307(_0x5d1c7d([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x5d1438[_0x5d1c7d([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x897501['id'],_0x453e79?_0x453e79['id']:null,!0x0),_0x5d1438[_0x5d1c7d([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x5d1c7d([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x5d1438[_0x5d1c7d([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x5d1438[_0x5d1c7d([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x3f4413,void(_0x5d1438[_0x5d1c7d([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x3f4413);}if(_0x1e2a84(_0x5d1c7d([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x51125f=_0x15c307(_0x5d1c7d([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x51125f[_0x5d1c7d([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x5d1c7d([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x51125f[_0x5d1c7d([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x51125f[_0x5d1c7d([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x3f4413,_0x51125f[_0x5d1c7d([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x3f4413;}_0x43c3f7[_0x5d1c7d([0x6d,0x6f,0x64,0x65,0x6c])][_0x5d1c7d([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x3f4413,_0x43c3f7[_0x5d1c7d([0x6d,0x6f,0x64,0x65,0x6c])][_0x5d1c7d([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x3f4413,_0x43c3f7[_0x5d1c7d([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x5d1c7d([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x132679(){return _0x1e2a84(_0x5d1c7d([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x15c307(_0x5d1c7d([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x5d1c7d([0x73,0x74,0x61,0x74,0x65])]==_0x5d1c7d([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x4cfeb2(){return _0x1e2a84(_0x5d1c7d([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 _0x3a4c3a(){return _0x1e2a84(_0x5d1c7d([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x217e6b(_0x4e7d0d){const _0x4fe9f1=_0x1f1b2f();_0x43c3f7[_0x4fe9f1]=_0x5d1c7d([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])+_0x4e7d0d,_0x4e7d0d[_0x5d1c7d([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x5d1c7d([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x1f1b2f()]=_0xaca41c),_0x4e7d0d!=_0x5d1c7d([0x56,0x61,0x6c,0x69,0x64])&&_0x281f07();}function _0x1f1b2f(){const _0x40e340=window[_0x5d1c7d([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x5d1c7d([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x5d1c7d([0x6e,0x6f,0x77])]())[_0x5d1c7d([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x5d1c7d([0x2e]),'');let _0x596b77=_0x5d1c7d([0x76]);for(let _0x3d1f13=0x0;_0x3d1f13<_0x40e340[_0x5d1c7d([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x3d1f13+=0x2){let _0x5cd666=window[_0x5d1c7d([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x40e340[_0x5d1c7d([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x3d1f13,_0x3d1f13+0x2));_0x5cd666>=_0x498677[_0x5d1c7d([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x5cd666-=_0x498677[_0x5d1c7d([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x596b77+=_0x498677[_0x5cd666];}return _0x596b77;}function _0x272516(){const _0x576d4c=_0x2b73ae[_0x5d1c7d([0x73,0x70,0x6c,0x69,0x74])](_0x5d1c7d([0x2e]));if(0x3!=_0x576d4c[_0x5d1c7d([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x23cd7a(_0x576d4c[0x1]);function _0x23cd7a(_0x178ea4){const _0xc3e90d=_0x4beae0(_0x178ea4);return _0xc3e90d&&_0x662e2e()?_0xc3e90d:null;function _0x662e2e(){const _0x1b4fca=_0xc3e90d[_0x5d1c7d([0x6a,0x74,0x69])],_0x10bf40=window[_0x5d1c7d([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x1b4fca[_0x5d1c7d([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x1b4fca[_0x5d1c7d([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x3c984c={..._0xc3e90d,[_0x5d1c7d([0x6a,0x74,0x69])]:_0x1b4fca[_0x5d1c7d([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x1b4fca[_0x5d1c7d([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x3c984c[_0x5d1c7d([0x76,0x63])],_0x542649(_0x3c984c)==_0x10bf40;}}}async function _0x1da2ea(){let _0x2479ff=!0x0;try{const _0x2e074e=_0x2b73ae[_0x5d1c7d([0x73,0x70,0x6c,0x69,0x74])](_0x5d1c7d([0x2e])),[_0x55bbbd,_0x4654d5,_0x79e3d5]=_0x2e074e;return _0x266f3d(_0x55bbbd),await _0x22a50d(_0x55bbbd,_0x4654d5,_0x79e3d5),_0x2479ff;}catch{return!0x1;}function _0x266f3d(_0x1c04fc){const _0x31bcbd=_0x4beae0(_0x1c04fc);_0x31bcbd&&_0x31bcbd[_0x5d1c7d([0x61,0x6c,0x67])]==_0x5d1c7d([0x45,0x53,0x32,0x35,0x36])||(_0x2479ff=!0x1);}async function _0x22a50d(_0x4aa730,_0x13777a,_0x152673){const _0x8a2474=window[_0x5d1c7d([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x5d1c7d([0x66,0x72,0x6f,0x6d])](_0x2776cb(_0x152673),_0x2a8947=>_0x2a8947[_0x5d1c7d([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x3c228a=new window[(_0x5d1c7d([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x5d1c7d([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x4aa730+_0x5d1c7d([0x2e])+_0x13777a),_0x40bbe0=window[_0x5d1c7d([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x5d1c7d([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x40bbe0)return;const _0x57a183=await _0x40bbe0[_0x5d1c7d([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x5d1c7d([0x6a,0x77,0x6b]),_0x497bae,{[_0x5d1c7d([0x6e,0x61,0x6d,0x65])]:_0x5d1c7d([0x45,0x43,0x44,0x53,0x41]),[_0x5d1c7d([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x5d1c7d([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x5d1c7d([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x40bbe0[_0x5d1c7d([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x5d1c7d([0x6e,0x61,0x6d,0x65])]:_0x5d1c7d([0x45,0x43,0x44,0x53,0x41]),[_0x5d1c7d([0x68,0x61,0x73,0x68])]:{[_0x5d1c7d([0x6e,0x61,0x6d,0x65])]:_0x5d1c7d([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x57a183,_0x8a2474,_0x3c228a)||(_0x2479ff=!0x1);}}function _0x4beae0(_0x3e2b01){return _0x3e2b01[_0x5d1c7d([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x5d1c7d([0x65,0x79]))?JSON[_0x5d1c7d([0x70,0x61,0x72,0x73,0x65])](_0x2776cb(_0x3e2b01)):null;}function _0x2776cb(_0x2aefb4){return window[_0x5d1c7d([0x61,0x74,0x6f,0x62])](_0x2aefb4[_0x5d1c7d([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x5d1c7d([0x2b]))[_0x5d1c7d([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x5d1c7d([0x2f])));}function _0x542649(_0x430b14){let _0x16832e=0x1505;function _0x2dcae5(_0x5bbe47){for(let _0x358c5f=0x0;_0x358c5f<_0x5bbe47[_0x5d1c7d([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x358c5f++){const _0x48a210=_0x5bbe47[_0x5d1c7d([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x358c5f);_0x16832e=(_0x16832e<<0x5)+_0x16832e+_0x48a210,_0x16832e&=_0x16832e;}}function _0x2b2396(_0xeab79f){Array[_0x5d1c7d([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0xeab79f)?_0xeab79f[_0x5d1c7d([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x2b2396):_0xeab79f&&typeof _0xeab79f==_0x5d1c7d([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x5d1c7d([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0xeab79f)[_0x5d1c7d([0x73,0x6f,0x72,0x74])]()[_0x5d1c7d([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x241c7d,_0x2a2681])=>{_0x2dcae5(_0x241c7d),_0x2b2396(_0x2a2681);}):_0x2dcae5(window[_0x5d1c7d([0x53,0x74,0x72,0x69,0x6e,0x67])](_0xeab79f));}return _0x2b2396(_0x430b14),_0x16832e>>>0x0;}function _0x36dd10(_0x10ebab){return _0x10ebab[_0x5d1c7d([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x5d1c7d([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x5d1c7d([0x30]));}function _0x420fcb(_0x19307d){return _0x19307d[_0x5d1c7d([0x73,0x70,0x6c,0x69,0x74])]('')[_0x5d1c7d([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x5d1c7d([0x6a,0x6f,0x69,0x6e])]('');}function _0x1e2a84(_0x1b01c4){return _0x43c3f7[_0x5d1c7d([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x5d1c7d([0x68,0x61,0x73])](_0x1b01c4);}function _0x15c307(_0x33213d){return _0x43c3f7[_0x5d1c7d([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x5d1c7d([0x67,0x65,0x74])](_0x33213d);}function _0x3f4413(){}function _0x5d1c7d(_0x52031b){return _0x52031b['map'](_0x145d4a=>String['fromCharCode'](_0x145d4a))['join']('');}_0x217e6b(await _0x11bf19());}(this);}['createRevision'](_0x3c99c6){const _0x4d6c25=this['editor']['plugins']['get']('Users');return new Revision({'id':_0x3c99c6['id'],'name':_0x3c99c6['name'],'creator':_0x3c99c6['creatorId']?_0x4d6c25['getUser'](_0x3c99c6['creatorId']):null,'diffData':_0x3c99c6['diffData']||_0x3c99c6['data'],'authors':_0x3c99c6['authorsIds']['map'](_0x3e7402=>_0x4d6c25['getUser'](_0x3e7402)),'createdAt':new Date(_0x3c99c6['createdAt']),'attributes':_0x3c99c6['attributes'],'fromVersion':_0x3c99c6['fromVersion'],'toVersion':_0x3c99c6['toVersion']});}['addRevision'](_0x308681,_0x170a01=0x0){this['_revisions']['add'](_0x308681,_0x170a01);}['getRevision'](_0x2a816c){return this['_revisions']['get'](_0x2a816c);}['getRevisions'](_0x5f5881={'toJSON':!0x1}){const _0x35252b=Array['from'](this['_revisions']);return _0x35252b['reverse'](),_0x5f5881['toJSON']?_0x35252b['map'](_0x5a1a57=>_0x5a1a57['toJSON']()):_0x35252b;}['getIndex'](_0x12b781){return this['_revisions']['getIndex'](_0x12b781);}['getEarlierVisibleRevision'](_0x3398ed){const [,_0x1e2a81]=this['getRevisionsIterator'](_0x3398ed,{'direction':'earlier'});return _0x1e2a81;}['getLaterVisibleRevision'](_0x37e42f){const [,_0x3e8bfe]=this['getRevisionsIterator'](_0x37e42f,{'direction':'later'});return _0x3e8bfe;}['getRevisionsInDiff'](_0x289cc4){const _0x1ec40d=[];for(const _0x2fe842 of this['getRevisionsIterator'](_0x289cc4['newRevisionId']))if(_0x1ec40d['push'](_0x2fe842),_0x2fe842['id']===_0x289cc4['oldRevisionId'])break;return _0x1ec40d;}*['getRevisionsIterator'](_0x39e6da,{direction:_0x5aa69d='earlier',filter:_0xfc6bb4=()=>!0x0}={}){const _0x11765c='earlier'===_0x5aa69d?0x1:-0x1;let _0x358374=this['_revisions']['get'](_0x39e6da),_0x46a8b8=this['getIndex'](_0x358374);for(yield _0x358374;_0x358374;){if(_0x46a8b8+=_0x11765c,_0x358374=this['getRevision'](_0x46a8b8),!_0x358374)return;_0xfc6bb4(_0x358374)&&(yield _0x358374);}}}class RevisionHistoryUtils extends _0x18ed42{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x27685d,'c'],[_0x572198,'a'],[_0x8b642d,'e'],[_0x1845d7,'r'],[_0x474da6,'u']]);['_typeCharToViewClass']=new Map([['c',_0x27685d],['a',_0x572198],['e',_0x8b642d],['r',_0x1845d7],['u',_0x474da6]]);async['loadRevisionData'](_0x157b09,_0x460831){if(_0x157b09['diffData']||!_0x460831)return;const _0x5e84a7=this['editor']['config']['get']('collaboration.channelId'),_0x395c5e=await _0x460831['getRevision']({'channelId':_0x5e84a7,'revisionId':_0x157b09['id']});_0x157b09['diffData']=_0x395c5e['diffData'];}['getRevisionDocumentData'](_0x41234e){const _0x45abd1={};for(const _0x3e2c13 in _0x41234e['diffData']){if(_0x41234e['diffData'][_0x3e2c13]['attachChange']&&!_0x41234e['diffData'][_0x3e2c13]['attachChange']['isAttached'])continue;const _0x13ccbb=this['_removeRevisionMarkers'](JSON['parse'](_0x41234e['diffData'][_0x3e2c13]['insertions'])),_0x3cee7c=this['editor']['editing']['view']['document'],_0x4600c2=new _0x3e2908(_0x3cee7c,_0x13ccbb['map'](_0x254663=>this['_getViewFromDiffObj'](_0x254663,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x45abd1[_0x3e2c13]=this['editor']['data']['processor']['toData'](_0x4600c2),this['editor']['data']['processor']['useFillerType']('default');}return _0x45abd1;}['getRevisionRootsAttributes'](_0x5a2bbb){const _0x3b6a3e={};for(const _0x4f6d43 in _0x5a2bbb['diffData'])_0x5a2bbb['diffData'][_0x4f6d43]['attachChange']&&!_0x5a2bbb['diffData'][_0x4f6d43]['attachChange']['isAttached']||(_0x3b6a3e[_0x4f6d43]=_0x5a2bbb['diffData'][_0x4f6d43]['attributesAfter']||{});return _0x3b6a3e;}['getRevisionRootsModelElements'](_0xd332a5){const _0x26959a={};for(const _0x148b92 in _0xd332a5['diffData']){if(_0xd332a5['diffData'][_0x148b92]['attachChange']&&!_0xd332a5['diffData'][_0x148b92]['attachChange']['isAttached'])continue;const _0x32056e=_0xd332a5['diffData'][_0x148b92]['rootElementName'];_0x32056e&&(_0x26959a[_0x148b92]=_0x32056e);}return _0x26959a;}['_getTypeCharForViewElement'](_0xd3b23d){return this['_viewClassToTypeChar']['get'](_0xd3b23d['constructor']);}['_getViewFromDiffObj'](_0x3de900,_0x257172){const _0x16d25b=this['editor']['editing']['view']['document'];if('string'==typeof _0x3de900)return new _0x1712b5(_0x16d25b,_0x3de900);{let _0x3374bf,_0x22df00;_0x22df00='u'==_0x3de900['type']||'r'==_0x3de900['type']?[]:_0x3de900['children']['map'](_0x3fd60a=>this['_getViewFromDiffObj'](_0x3fd60a,_0x257172));const _0x3876fc=this['_typeCharToViewClass']['get'](_0x3de900['type'])||_0x19d66d,_0x26773b=this['editor']['data']['htmlProcessor']['domConverter'];if(_0x3374bf=new _0x3876fc(_0x16d25b,_0x3de900['name'],_0x3de900['attributes'],_0x22df00),'u'==_0x3de900['type']&&_0x3de900['children'][0x0]){const _0x185519=_0x3de900['children'][0x0];if(_0x3374bf['render']=function(_0x3f9418){const _0x20c5e7=_0x3f9418['createElement']('div');return _0x20c5e7['innerHTML']=_0x185519,_0x20c5e7['childNodes'][0x0];},_0x257172){const _0x2ecb0a=new _0x3e2908(_0x16d25b);_0x2ecb0a['_appendChild'](_0x3374bf);const _0x4a9942=Array['from'](_0x26773b['viewChildrenToDom'](_0x2ecb0a,{'bind':!0x1})),_0x2c6b16=_0x26773b['domDocument']['createElement']('div');_0x2c6b16['append'](..._0x4a9942),_0x3374bf=Array['from'](_0x26773b['domChildrenToView'](_0x2c6b16))[0x0];}}else{if('r'==_0x3de900['type']&&_0x3de900['children'][0x0]){const _0x3d86df=_0x3de900['children'][0x0];if(_0x3374bf['render']=function(_0x363998){_0x363998['innerHTML']=_0x3d86df;},_0x257172){const _0x20e7a8=new _0x3e2908(_0x16d25b);_0x20e7a8['_appendChild'](_0x3374bf);const _0x1bdd0d=Array['from'](_0x26773b['viewChildrenToDom'](_0x20e7a8,{'bind':!0x1})),_0x42e570=_0x26773b['domDocument']['createElement']('div');_0x42e570['append'](..._0x1bdd0d);const _0x2186d2=Array['from'](_0x26773b['domChildrenToView'](_0x42e570));_0x2186d2['length']>0x1?_0x3374bf['_appendChild'](_0x2186d2):_0x3374bf=_0x2186d2[0x0];}}}if(_0x3de900['customProperties']){for(const [_0x2d36fa,_0x3188ad]of _0x3de900['customProperties'])_0x3374bf['_setCustomProperty'](_0x2d36fa,_0x3188ad);}const _0x570b94=void 0x0===_0x3de900['fillerOffset']?null:_0x3de900['fillerOffset'];return null!==_0x570b94&&(_0x3374bf['getFillerOffset']=()=>_0x570b94),_0x3374bf;}}['_makeModelFromViewString'](_0x5cff82,_0x30d1fa){const _0x44bbd3=JSON['parse'](_0x5cff82),_0x39a170=this['editor']['editing']['view']['document'],_0x370ccb=new _0x3e2908(_0x39a170,_0x44bbd3['map'](_0x219a6f=>this['_getViewFromDiffObj'](_0x219a6f,!0x0))),_0x311715=this['editor']['data']['toModel'](_0x370ccb,_0x30d1fa);return _0x311715['name']=_0x30d1fa,_0x311715;}['_removeRevisionMarkers'](_0x53712b){return(_0x53712b=_0x53712b['filter'](_0x888bdd=>!_0x888bdd['name']||'revision-start'!==_0x888bdd['name']&&'revision-end'!==_0x888bdd['name']))['forEach'](_0x179fe6=>{'string'!=typeof _0x179fe6&&(_0x179fe6['children']=this['_removeRevisionMarkers'](_0x179fe6['children']),_0x179fe6['attributes']=_0x179fe6['attributes']['filter'](_0x2fe1a6=>!_0x2fe1a6[0x0]['startsWith']('data-revision-')));}),_0x53712b;}}function ft(_0x709d34,_0x2cc4f7,_0x3efdfa){const t=_0x709d34['t'];switch(_0x2cc4f7){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'},_0x3efdfa);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x3efdfa);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 RevisionTracker extends _0x18ed42{['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[_0x4c4887,RevisionsRepository,RevisionHistoryUtils,_0x579023];}constructor(_0x3a32dc){super(_0x3a32dc),this['repository']=this['editor']['plugins']['get']('RevisionsRepository'),this['_utils']=this['editor']['plugins']['get']('RevisionHistoryUtils'),this['_revisionDataBuilder']=new RevisionDataBuilder(this['editor']),this['_initialRevisionId']=this['editor']['config']['get']('collaboration.channelId')||'initial',this['_bufferedUpdates']=new Map(),this['_loadedStateData']=null;const _0x15fb1f=_0x55087c();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x15fb1f},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 _0x30c29a=this['repository']['getRevision'](0x0),_0x2ef144=_0x30c29a&&null===_0x30c29a['creator']?_0x30c29a:null;if(this['_continueCurrentRevision']=!!_0x2ef144&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x39f55c=this['_source']['getCurrentRevisionId'](),_0x2e9970=this['repository']['getRevision'](_0x39f55c);if(_0x2e9970)this['_startingVersion']=_0x2e9970['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x10d104=this['_source']['history']['_operations']['find'](_0x4cffb9=>!_0x4cffb9['_isInit']),_0x150c5b=_0x10d104?_0x10d104['baseVersion']:this['_source']['history']['version'];_0x30c29a?(_0x30c29a['toVersion']<_0x150c5b&&_0x30c29a['_update']({'toVersion':_0x150c5b}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x2ef144['id'],this['_startingVersion']=_0x2ef144['fromVersion']):(this['_startingVersion']=_0x30c29a['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x150c5b,this['_continueCurrentRevision']=!0x1);}}else _0x2ef144&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x2ef144['toVersion'],this['editor']['model']['document']['history']['version']),_0x2ef144['fromVersion']===_0x2ef144['toVersion']?(0x0!==_0x2ef144['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x2ef144['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x2ef144['id'],this['_startingVersion']=_0x2ef144['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',_0x51a819=>!_0x51a819),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x2d91b9=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0xdfbfcc;for(const _0x1f5950 in _0x2d91b9){const _0x40d39c=_0x1f5950,_0x4500c8=_0x2d91b9[_0x40d39c];if('revisionHistoryLicenseKeyValid'==_0x4500c8||'revisionHistoryLicenseKeyInvalid'==_0x4500c8||'revisionHistoryLicenseKeyExpired'==_0x4500c8||'revisionHistoryLicenseKeyDomainLimit'==_0x4500c8||'revisionHistoryLicenseKeyNotAllowed'==_0x4500c8||'revisionHistoryLicenseKeyEvaluationLimit'==_0x4500c8||'revisionHistoryLicenseKeyUsageLimit'==_0x4500c8){delete _0x2d91b9[_0x40d39c],_0xdfbfcc=_0x4500c8,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0xdfbfcc&&_0x2d91b9['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0xdfbfcc&&_0x2d91b9['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0xdfbfcc&&_0x2d91b9['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0xdfbfcc&&_0x2d91b9['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0xdfbfcc&&_0x2d91b9['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0xdfbfcc&&_0x2d91b9['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x152db5=this['repository']['getRevision'](0x0),_0xc1236c=await this['getRevisionDocumentData'](_0x152db5),_0x35654e=await this['getRevisionRootsAttributes'](_0x152db5),_0x28e4f7=this['_utils']['getRevisionRootsModelElements'](_0x152db5);this['_replaceEditorDataWithRevisionData'](_0xc1236c,_0x35654e,_0x28e4f7);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x2cbc94){this['_source']=_0x2cbc94;}async['update'](){const _0x4a9d85=await this['_source']['getLatestVersion']();if(_0x4a9d85>this['currentRevision']['toVersion']){await this['_loadState']();const _0x1f5138=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x4a9d85});_0x1f5138['authors']=_0x1f5138['authorsIds']['map'](_0x5e423=>this['editor']['plugins']['get']('Users')['getUser'](_0x5e423)),this['currentRevision']['_update'](_0x1f5138);}}async['saveRevision'](_0x552fc4={},_0x533394=null){const _0x5c0595=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x533394>this['currentRevision']['toVersion']&&(_0x533394=null),null===_0x533394&&(_0x533394=await this['_source']['getLatestVersion']());const _0x96e1b8=this['_getFromVersion'](_0x533394),_0xf0041d=this['buildRevisionData']({'from':_0x96e1b8,'to':_0x533394});if(this['currentRevision']['toVersion']<_0x533394){const _0x3216aa=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x533394,'to':_0x533394});_0x3216aa['authors']=[],_0x3216aa['authorsIds']=[],_0x3216aa['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x3216aa,!0x0),delete _0x3216aa['authors'],_0x5c0595['push'](_0x3216aa);}_0x552fc4['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x552fc4['name']=_0x552fc4['name']||null,_0x552fc4['id']=_0x552fc4['id']||_0x55087c(),_0x552fc4={..._0x552fc4,..._0xf0041d};const _0x25d40c=this['addRevisionData'](_0x552fc4);_0x5c0595['push'](_0x552fc4);const _0x5a5678=this['repository']['getIndex'](_0x25d40c);if(0x0!==_0x5a5678){const _0x617128=this['repository']['getRevision'](_0x5a5678-0x1);if(_0x617128['fromVersion']!==_0x533394){const _0x15b1be=this['_revisionDataBuilder']['getData'](_0x533394,_0x617128['toVersion']),_0x2087a5={'id':_0x617128['id'],'diffData':_0x15b1be['diffData'],'authorsIds':_0x15b1be['authorsIds'],'authors':_0x15b1be['authorsIds']['map'](_0x1205ab=>this['editor']['plugins']['get']('Users')['getUser'](_0x1205ab)),'fromVersion':_0x533394};_0x617128===this['currentRevision']&&(_0x2087a5['createdAt']=new Date(_0x552fc4['createdAt']['getTime']()+0xa)),_0x617128['_update'](_0x2087a5,!0x0),delete _0x2087a5['authors'],_0x5c0595['push'](_0x2087a5);}}if(this['adapter']){for(const _0x4d6fb1 of _0x5c0595)this['_bufferUpdate'](_0x4d6fb1['id'],_0x4d6fb1,!0x0);this['sendBufferedUpdates']();}return _0x25d40c;}['addRevisionData'](_0x48737e){const _0x339849=this['repository']['createRevision'](_0x48737e);return this['adapter']&&_0x339849['on']('_update',(_0x1e0d86,_0x39f58e,_0x13c4b5)=>{_0x13c4b5||(this['_bufferUpdate'](_0x39f58e['id'],_0x39f58e,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x339849,this['_findInsertionIndex'](_0x339849)),_0x339849;}async['getRevisionDocumentData'](_0x532ee1){return await this['_utils']['loadRevisionData'](_0x532ee1,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x532ee1);}async['getRevisionRootsAttributes'](_0x309e4b){return await this['_utils']['loadRevisionData'](_0x309e4b,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x309e4b);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x15b574=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x3895d8=0x0;_0x3895d8<_0x15b574['length'];_0x3895d8++){const _0x4db0b1=_0x15b574[_0x3895d8];let _0x17d22b=!0x1;for(const _0x4ce1da of Object['keys'](_0x4db0b1))void 0x0===_0x4db0b1[_0x4ce1da]?delete _0x4db0b1[_0x4ce1da]:'id'!==_0x4ce1da&&(_0x17d22b=!0x0);_0x17d22b||(_0x15b574[_0x3895d8]=null);}if(_0x15b574=_0x15b574['filter'](_0x54374a=>null!==_0x54374a),!_0x15b574['length'])return;for(let _0x1ab2ef=0x0;_0x1ab2ef<_0x15b574['length'];_0x1ab2ef++){const _0x13126f=_0x15b574[_0x1ab2ef];void 0x0!==_0x13126f['fromVersion']&&void 0x0===_0x13126f['toVersion']&&(_0x13126f['toVersion']=this['repository']['getRevision'](_0x13126f['id'])['toVersion']),void 0x0!==_0x13126f['toVersion']&&void 0x0===_0x13126f['fromVersion']&&(_0x13126f['fromVersion']=this['repository']['getRevision'](_0x13126f['id'])['fromVersion']);}const _0x465b00=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x15b574,_0x465b00)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x538f56=>{if(_0x538f56){for(const _0x3a64ee of _0x538f56)this['setRevisionData']({'id':_0x3a64ee['id'],'createdAt':_0x3a64ee['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0x135d2a=null,from:_0x107130=null,to:_0x2220b8=null}){_0x107130=null!==_0x107130?_0x107130:_0x135d2a['fromVersion'],_0x2220b8=null!==_0x2220b8?_0x2220b8:_0x135d2a['toVersion'];const _0x3efb14=this['_revisionDataBuilder']['getData'](_0x107130,_0x2220b8),_0x250431={'diffData':_0x3efb14['diffData'],'authorsIds':_0x3efb14['authorsIds'],'fromVersion':_0x107130,'toVersion':_0x2220b8};if(!_0x135d2a||_0x2220b8!==_0x135d2a['toVersion']){const _0x118919=_0x2220b8-0x1,_0x386725=this['_source']['history']['getOperation'](_0x118919);_0x250431['createdAt']=_0x386725&&_0x386725['createdAt']||new Date();}if(this['_loadedStateData']&&_0x107130===this['_loadedStateData']['fromVersion']){for(const _0x27a731 of this['_loadedStateData']['authors'])_0x250431['authorsIds']['includes'](_0x27a731['id'])||_0x250431['authorsIds']['push'](_0x27a731['id']);}return _0x250431;}['_bufferUpdate'](_0x1a16b4,_0x20df9b,_0x50d1e3){if(this['_bufferedUpdates']['has'](_0x1a16b4)){const _0x10e6a1=this['_bufferedUpdates']['get'](_0x1a16b4);_0x20df9b=_0x50d1e3?{..._0x10e6a1,..._0x20df9b}:{..._0x20df9b,..._0x10e6a1};}this['_bufferedUpdates']['set'](_0x1a16b4,_0x20df9b);}['setRevisionData'](_0x3b70cc){const _0x52398b=this['repository']['getRevision'](_0x3b70cc['id']);if(_0x3b70cc['createdAt']&&(_0x3b70cc['createdAt']=new Date(_0x3b70cc['createdAt'])),_0x3b70cc['authorsIds']){const _0x1b557b=this['editor']['plugins']['get']('Users');_0x3b70cc['authors']=_0x3b70cc['authorsIds']['map'](_0x112338=>_0x1b557b['getUser'](_0x112338));}_0x52398b['_update'](_0x3b70cc,!0x0);}['_createInitialRevision'](_0x34218e){const _0x25603b=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x25603b)this['_initialRevisionId']=_0x25603b['id'];else{const _0x18431d=!this['editor']['model']['document']['roots']['find'](_0x54c31f=>this['editor']['model']['hasContent'](_0x54c31f)),_0x2b1c20=this['editor']['plugins']['get']('Users')['me']['id'],_0x42c5cf=ft(this['editor']['locale'],_0x18431d?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x34218e,'to':_0x34218e,'id':this['_initialRevisionId'],'name':_0x42c5cf,'creatorId':_0x2b1c20});}}['_createCurrentRevision'](_0x11efc5){const _0x378d70=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x378d70),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x11efc5,'to':_0x11efc5,'id':_0x378d70,'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'](_0x10689b,_0x7ebf26,_0x1b569d){const _0x318fae={},_0x478e24={},_0x2ecb8c={},_0x2dc060=this['editor']['config']['get']('roots')||{};for(const [_0x4a460a,_0xb27904]of Object['entries'](_0x2dc060))_0xb27904['lazyLoad']||(_0x318fae[_0x4a460a]=_0xb27904['initialData']??'',_0x478e24[_0x4a460a]=_0xb27904['modelAttributes']||{},_0xb27904['modelElement']&&(_0x2ecb8c[_0x4a460a]=_0xb27904['modelElement']));for(const _0x14aa31 of this['editor']['model']['document']['getRootNames']())_0x318fae[_0x14aa31]??='',_0x478e24[_0x14aa31]??={};let _0x12b2da=!0x1;const _0x3f5c4e=Object['keys'](_0x318fae),_0x39b958=Object['keys'](_0x10689b);for(const _0x98a1cc of _0x3f5c4e){if(_0x318fae[_0x98a1cc]!==_0x10689b[_0x98a1cc]&&''!==_0x318fae[_0x98a1cc]['trim']()){_0x12b2da=!0x0;break;}if(!_0x3a917e(_0x478e24[_0x98a1cc],_0x7ebf26[_0x98a1cc])&&Object['keys'](_0x478e24[_0x98a1cc])['length']>0x0){_0x12b2da=!0x0;break;}const _0x583978=_0x2ecb8c[_0x98a1cc],_0x13fa25=_0x1b569d[_0x98a1cc];if(_0x583978&&_0x13fa25&&_0x583978!==_0x13fa25){_0x12b2da=!0x0;break;}}_0x12b2da||(_0x12b2da=_0x39b958['some'](_0xfaf16a=>!this['editor']['model']['document']['getRoot'](_0xfaf16a))),_0x12b2da&&_0x3748bd('editor-initial-data-replaced-with-revision-data',{'editorData':_0x318fae,'editorRootsAttributes':_0x478e24,'editorRootsModelElements':_0x2ecb8c,'revisionData':_0x10689b,'revisionRootsAttributes':_0x7ebf26,'revisionRootsModelElements':_0x1b569d});for(const [_0x57c6f4,_0xd9b48b]of Object['entries'](_0x10689b))this['editor']['config']['set']('roots.'+_0x57c6f4+'.initialData',_0xd9b48b);for(const [_0xf454db,_0x16d05e]of Object['entries'](_0x7ebf26))this['editor']['config']['set']('roots.'+_0xf454db+'.modelAttributes',_0x16d05e);const _0x35d009=this['editor']['model']['document'];for(const [_0x267a65,_0x2ecc01]of Object['entries'](_0x1b569d)){this['editor']['config']['set']('roots.'+_0x267a65+'.modelElement',_0x2ecc01);const _0x553ef4=_0x35d009['getRoot'](_0x267a65);_0x553ef4&&_0x553ef4['name']!==_0x2ecc01&&(_0x35d009['roots']['remove'](_0x267a65),_0x35d009['createRoot'](_0x2ecc01,_0x267a65));}}['_addPendingAction'](){if(!this['_pendingAction']){const _0x1685e8=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x1685e8['add'](ft(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x30243a){const _0x2d2dc0=this['repository']['getRevisions']();_0x2d2dc0['reverse']();let _0x839a8c=0x0;for(;_0x839a8c<_0x2d2dc0['length'];){const _0x2f2ce3=_0x2d2dc0[_0x839a8c];if(_0x2f2ce3===this['currentRevision']){_0x839a8c++;continue;}if(_0x2f2ce3['id']===this['_initialRevisionId'])break;const _0xe1b7d9=_0x30243a['toVersion']-_0x2f2ce3['toVersion']||_0x30243a['fromVersion']-_0x2f2ce3['fromVersion'];if(_0xe1b7d9>0x0)break;if(_0xe1b7d9<0x0)_0x839a8c++;else{if(!_0x30243a['creator']&&_0x2f2ce3['creator'])break;if(_0x2f2ce3['creator']||!_0x30243a['creator']){if(_0x30243a['createdAt']>_0x2f2ce3['createdAt'])break;_0x839a8c++;}else _0x839a8c++;}}return _0x839a8c;}['_getFromVersion'](_0x2446af){const _0x32fdad=this['repository']['getRevisions']();_0x32fdad['reverse'](),_0x32fdad['shift']();const _0x2e32e6=_0x32fdad['find'](_0x2a0719=>_0x2a0719['toVersion']<=_0x2446af)['toVersion'];return _0x2e32e6<this['_startingVersion']?this['_startingVersion']:_0x2e32e6;}['_makeRevision']({name:_0x59410c,from:_0x5a6f52,to:_0x4a5605,creatorId:_0x32799a,id:_0x3beaeb}){const _0x540c35=this['buildRevisionData']({'from':_0x5a6f52,'to':_0x4a5605});_0x540c35['name']=_0x59410c,_0x540c35['creatorId']=_0x32799a,_0x540c35['id']=_0x3beaeb;const _0x3dde7f=this['addRevisionData'](_0x540c35);return this['adapter']&&this['_bufferUpdate'](_0x540c35['id'],_0x540c35,!0x0),_0x3dde7f;}['_setConversion'](){this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'});}}class RevisionDataBuilder{['editor'];['source'];['_savedMetaData'];['_lastFrom'];['_lastTo'];['_markers'];['_diffRoots'];['_diffRootsAttributes'];['_baseRoots'];['_baseRootsAttributes'];['_idsRoots'];['_baseIdsRoots'];['_touched'];['_touchedMarkers'];['_touchedRoots'];['_revisionId'];['_startingRevisionId'];constructor(_0x1380ab){this['editor']=_0x1380ab,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'](_0x38f8ef){this['source']=_0x38f8ef;const _0xaf0038=new Map(),_0x33fc49=new Map(),_0x34c179=this['editor']['model']['document']['roots']['map'](_0x3d2345=>_0x3d2345['rootName']);for(const _0x3e10f0 of _0x34c179){const _0x196210=this['editor']['model']['document']['getRoot'](_0x3e10f0),_0x321bda=gt(_0x196210);_0xaf0038['set'](_0x3e10f0,_0x321bda),_0x33fc49['set'](_0x3e10f0,Object['fromEntries'](_0x196210['getAttributes']()));}const _0x5b467e=Array['from'](this['editor']['model']['markers'])['map'](_0x542721=>[_0x542721['name'],_0x542721['getRange']()]),_0x5499d5=this['source']['version'];this['_saveMetaData'](_0x5499d5,_0xaf0038,_0x5b467e,_0x33fc49),this['_startingRevisionId']=this['_revisionId'];const _0x4e38f1=new Map(),_0x546646=new Map();for(const _0x1cf9ee of _0x34c179){const _0x404320=wt(_0x1cf9ee,this['editor']['model']['document']['getRoot'](_0x1cf9ee)['name']);_0x4e38f1['set'](_0x1cf9ee,_0x404320),_0x546646['set'](_0x1cf9ee,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x4e38f1,[],_0x546646);}['getData'](_0x129d90,_0x3cdd4){if(this['_lastFrom']===_0x129d90&&this['_lastTo']<=_0x3cdd4)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x3cdd4,!0x0);else{if(!this['_savedMetaData']['has'](_0x129d90)){const _0x372ccd=this['_getPreviousFrom'](_0x129d90);this['_calculateMetaData'](_0x372ccd,_0x129d90,!0x1);}this['_calculateMetaData'](_0x129d90,_0x3cdd4,!0x0);}return this['_lastFrom']=_0x129d90,this['_lastTo']=_0x3cdd4,this['_getState']();}['loadState'](_0x938534){if(!this['_savedMetaData']['has'](_0x938534['fromVersion'])){const _0x5b9950=this['_getPreviousFrom'](_0x938534['fromVersion']);this['_calculateMetaData'](_0x5b9950,_0x938534['fromVersion'],!0x1);}this['_calculateMetaData'](_0x938534['fromVersion'],_0x938534['toVersion'],!0x1);const _0x252bab=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x938534['fromVersion'],this['_lastTo']=_0x938534['toVersion'];for(const _0x120965 in _0x938534['diffData']){const _0x4c68eb=_0x938534['diffData'][_0x120965]['attachChange'],_0x21a77a=_0x527a66(_0x938534['diffData'][_0x120965]['attributesBefore'])||{},_0x53fe3f=_0x938534['diffData'][_0x120965],_0x5a8490=_0x252bab['_makeModelFromViewString'](_0x53fe3f['deletions'],_0x53fe3f['rootElementName']||'$root');_0x5a8490['rootName']=_0x120965,_0x5a8490['_isAttached']=!_0x4c68eb||!_0x4c68eb['isAttached'],_0x5a8490['isAttached']=()=>_0x5a8490['_isAttached'],this['_baseRoots']['set'](_0x120965,_0x5a8490),this['_baseRootsAttributes']['set'](_0x120965,_0x21a77a),_0x4c68eb&&this['_touchedRoots']['set'](_0x120965,_0x4c68eb);const _0x3ebcde=this['_makeIdsRoot'](_0x5a8490);this['_baseIdsRoots']['set'](_0x120965,_0x3ebcde);for(const [_0x3e7577,_0x1dde51]of _0x5a8490['markers']){if(!_0x3e7577['startsWith']('revision:'))continue;const _0x2c3dbc=_0x3e7577['split'](':')[0x2];for(const _0x564a19 of _0x1dde51['getWalker']({'singleCharacters':!0x0})){const _0x3c5a4e=this['_getVidAttributeName'](_0x564a19),_0x3439d8='elementEnd'==_0x564a19['type']?_0x564a19['previousPosition']['path']['slice'](0x0,-0x1):_0x564a19['previousPosition']['path'],_0x34d62a=_0x3ebcde['getNodeByPath'](_0x3439d8)['getAttribute'](_0x3c5a4e);this['_touched']['set'](_0x34d62a,{'userId':_0x2c3dbc});}_0x5a8490['markers']['delete'](_0x3e7577);}}this['_startingRevisionId']=this['_revisionId'];const _0x798e06=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x30650b=>!this['_touched']['has'](_0x30650b));let _0x17890f=0x0;const _0x409067=new Map();for(const _0x2c8265 in _0x938534['diffData']){const _0x4c683d=_0x938534['diffData'][_0x2c8265]['attachChange'],_0x46743b=_0x527a66(_0x938534['diffData'][_0x2c8265]['attributesAfter'])||{},_0x165430=_0x938534['diffData'][_0x2c8265],_0x215b84=_0x252bab['_makeModelFromViewString'](_0x165430['insertions'],_0x165430['rootElementName']||'$root');_0x215b84['rootName']=_0x2c8265,_0x215b84['_isAttached']=!_0x4c683d||_0x4c683d['isAttached'],_0x215b84['isAttached']=()=>_0x215b84['_isAttached'],this['_diffRoots']['set'](_0x2c8265,_0x215b84),this['_diffRootsAttributes']['set'](_0x2c8265,_0x46743b);const _0x5bfd6e=this['_makeIdsRoot'](_0x215b84,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x2c8265,_0x5bfd6e),_0x409067['set'](_0x2c8265,_0x215b84['isAttached']()?_0x46743b:{});for(const [_0x5bebd2,_0x2c6c00]of _0x215b84['markers']){if(!_0x5bebd2['startsWith']('revision:'))continue;const _0x3f8ed2=_0x5bebd2['split'](':')[0x2];for(const _0x920456 of _0x2c6c00['getWalker']({'singleCharacters':!0x0})){const _0x1c402a=this['_getVidAttributeName'](_0x920456),_0x41d4fe=this['_revisionId']++,_0x48743f='elementEnd'==_0x920456['type']?_0x920456['previousPosition']['path']['slice'](0x0,-0x1):_0x920456['previousPosition']['path'];_0x5bfd6e['getNodeByPath'](_0x48743f)['_setAttribute'](_0x1c402a,_0x41d4fe),this['_touched']['set'](_0x41d4fe,{'userId':_0x3f8ed2});}_0x215b84['markers']['delete'](_0x5bebd2);}for(const _0x323c20 of this['editor']['model']['createRangeIn'](_0x215b84)['getWalker']({'singleCharacters':!0x0})){const _0x3199e7=this['_getVidAttributeName'](_0x323c20),_0xc8a834='elementEnd'==_0x323c20['type']?_0x323c20['previousPosition']['path']['slice'](0x0,-0x1):_0x323c20['previousPosition']['path'],_0x6d4311=_0x5bfd6e['getNodeByPath'](_0xc8a834);_0x6d4311['getAttribute'](_0x3199e7)>0x0||_0x6d4311['_setAttribute'](_0x3199e7,_0x798e06[_0x17890f++]);}for(const [_0x456871,_0x46d48e]of _0x215b84['markers'])_0x456871['startsWith']('revision:')||this['_markers']['set'](_0x456871,_0x46d48e);}const {roots:_0x2e255f}=this['_savedMetaData']['get'](_0x938534['fromVersion']),{roots:_0x4ac911}=this['_savedMetaData']['get'](_0x938534['toVersion']),_0x5c90f1=gt(_0x2e255f['get']('$graveyard'));this['_baseRoots']['set']('$graveyard',_0x5c90f1),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x5c90f1,Number['NEGATIVE_INFINITY']));const _0x33cc98=gt(_0x4ac911['get']('$graveyard'));this['_diffRoots']['set']('$graveyard',_0x33cc98),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x33cc98));const _0x352d3b=Array['from'](this['_diffRoots'])['map'](([_0x48f8dc,_0x596696])=>[_0x48f8dc,gt(_0x596696)]);this['_saveMetaData'](this['_lastTo'],_0x352d3b,this['_markers'],_0x409067);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0xb01b6a,_0x1f6d13,_0x3c4918,_0x4cacde){const _0x4d5a8c=new Map(_0x1f6d13),_0x54c9c2=new Map(_0x527a66(_0x4cacde)),_0x48bd4b=new Map();for(const [_0x1eb782,_0x89db60]of _0x3c4918)_0x48bd4b['set'](_0x1eb782,{'start':_0x89db60['start']['clone'](),'end':_0x89db60['end']['clone'](),'rootName':_0x89db60['root']['rootName']});this['_savedMetaData']['set'](_0xb01b6a,{'roots':_0x4d5a8c,'markers':_0x48bd4b,'rootsAttributes':_0x54c9c2});}['_removeMetaData'](_0x1a07e7){this['_savedMetaData']['delete'](_0x1a07e7);}['_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'](_0x4930fd,_0x4304b0=null){let _0x1cdd8e=null;_0x4930fd['is']('documentFragment')||(_0x1cdd8e=new _0x45e0a6(_0x4930fd['name'],{'vid_start':null===_0x4304b0?this['_revisionId']++:_0x4304b0++}));const _0x51ba4d=[];for(const _0x137e93 of _0x4930fd['getChildren']())if(_0x137e93['is']('element')){_0x51ba4d['push'](this['_makeIdsRoot'](_0x137e93,_0x4304b0));const _0x5511c8=_0x51ba4d[_0x51ba4d['length']-0x1];null!==_0x4304b0&&(_0x4304b0=_0x5511c8['is']('element','$text')?_0x5511c8['getAttribute']('vid')+0x1:_0x5511c8['getAttribute']('vid_end')+0x1);}else{for(let _0x389795=0x0;_0x389795<_0x137e93['offsetSize'];_0x389795++)_0x51ba4d['push'](new _0x45e0a6('$text',{'vid':null===_0x4304b0?this['_revisionId']++:_0x4304b0++}));}if(_0x4930fd['is']('documentFragment')){const _0x505297=wt(_0x4930fd['rootName'],_0x4930fd['name']);return _0x505297['_insertChild'](0x0,_0x51ba4d),_0x505297;}return _0x1cdd8e['_setAttribute']('vid_end',null===_0x4304b0?this['_revisionId']++:_0x4304b0++),_0x1cdd8e['_insertChild'](0x0,_0x51ba4d),_0x1cdd8e;}['_calculateMetaData'](_0x2c4dc9,_0xd529ae,_0x11b997){this['_reset']();const {roots:_0x2f18e3,markers:_0x383916,rootsAttributes:_0x285881}=this['_savedMetaData']['get'](_0x2c4dc9);this['_baseRoots']=new Map(_0x2f18e3),this['_baseRootsAttributes']=new Map(_0x527a66(_0x285881));for(const [_0x360653,_0x2b85c3]of this['_baseRoots'])if('$graveyard'!==_0x360653&&(this['_diffRoots']['set'](_0x360653,gt(_0x2b85c3)),this['_diffRootsAttributes']=new Map(_0x527a66(_0x285881)),_0x11b997)){const _0x172a04=this['_revisionId'];this['_idsRoots']['set'](_0x360653,this['_makeIdsRoot'](_0x2b85c3)),this['_baseIdsRoots']['set'](_0x360653,this['_makeIdsRoot'](_0x2b85c3,_0x172a04));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',gt(this['_baseRoots']['get']('$graveyard'))),_0x11b997&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x110e59,_0x58ae7b]of _0x383916){const _0x227f46=this['_baseRoots']['get'](_0x58ae7b['rootName']),_0x1c32be=this['_diffRoots']['get'](_0x58ae7b['rootName']),_0x192ce7=new _0x8a4273(this['_fixPosition'](_0x58ae7b['start'],_0x227f46),this['_fixPosition'](_0x58ae7b['end'],_0x227f46)),_0x15f9d9=this['_fixRange'](_0x192ce7,_0x1c32be);_0x227f46['markers']['set'](_0x110e59,_0x192ce7),this['_markers']['set'](_0x110e59,_0x15f9d9);}this['_applyOperations'](_0x2c4dc9,_0xd529ae,_0x11b997);}['_applyOperations'](_0x7cf3c4,_0x402681,_0x36dd35){for(const _0x1d01dd of this['source']['getOperations'](_0x7cf3c4,_0x402681))this['_handleOperation'](_0x1d01dd,_0x36dd35);for(const _0xd14497 of this['_diffRoots']['values']())_0xd14497['markers']['clear']();for(const [_0x270a09,_0x1eaaec]of this['_markers']){this['_diffRoots']['get'](_0x1eaaec['root']['rootName'])['markers']['set'](_0x270a09,_0x1eaaec['clone']());}const _0x5b8bcb=new Map(),_0x93288f=new Map();for(const [_0x8eb0ff,_0x110e5e]of this['_diffRoots'])_0x5b8bcb['set'](_0x8eb0ff,gt(_0x110e5e)),_0x93288f['set'](_0x8eb0ff,this['_diffRootsAttributes']['get'](_0x8eb0ff));this['_saveMetaData'](_0x402681,_0x5b8bcb,this['_markers'],_0x93288f);}['_getPreviousFrom'](_0xd344a7){const _0x361168=Array['from'](this['_savedMetaData']['keys']());_0x361168['sort']((_0x2e9e0e,_0x566927)=>_0x2e9e0e-_0x566927),_0x361168['reverse']();for(const _0x54505b of _0x361168)if(_0x54505b<_0xd344a7)return _0x54505b;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x2bf574,_0x3d760f){const _0x53b93c=Array['from'](_0x3d760f['markers'])['map'](([_0x287eb4,_0x4bf17d])=>[_0x287eb4,this['_fixRange'](_0x4bf17d,_0x2bf574)]);_0x2bf574['markers']=new Map(_0x53b93c);}['_transformMarkers'](_0x4351b7){for(const _0x5395a6 of this['_markers']['values']()){const _0x180135=_0x5395a6['getTransformedByOperation'](_0x4351b7),_0x554f19=_0x8a4273['_createFromRanges'](_0x180135);_0x5395a6['start']=_0x554f19['start'],_0x5395a6['end']=_0x554f19['end'];}}['_handleOperation'](_0x243d16,_0x2fd70e){if('addRoot'!=_0x243d16['type']&&'detachRoot'!=_0x243d16['type']){if('insert'==_0x243d16['type']){const _0x364773=_0x243d16['position']['root'],_0x3bb257=_0x364773['rootName'],_0x367422=_0x364773['name'];this['_diffRoots']['has'](_0x3bb257)||(this['_diffRoots']['set'](_0x3bb257,wt(_0x3bb257,_0x367422,!0x0)),this['_diffRootsAttributes']['set'](_0x3bb257,{}),_0x2fd70e&&this['_idsRoots']['set'](_0x3bb257,wt(_0x3bb257,_0x367422,!0x0)));}else{if('addRootAttribute'==_0x243d16['type']||'removeRootAttribute'==_0x243d16['type']||'changeRootAttribute'==_0x243d16['type'])return void this['_handleRootAttributeOperation'](_0x243d16);'marker'==_0x243d16['type']&&this['_handleMarkerOperation'](_0x243d16);}if('marker'!==_0x243d16['type']){const _0x5094fe=this['_cloneOperation'](_0x243d16,this['_diffRoots']);_0x5094fe['_execute'](),this['_transformMarkers'](_0x5094fe);}if(_0x2fd70e)switch(_0x243d16['type']){case'insert':this['_handleInsertOperation'](_0x243d16);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x243d16);break;case'merge':this['_handleMergeOperation'](_0x243d16);break;case'split':this['_handleSplitOperation'](_0x243d16);}}else this['_handleRootOperation'](_0x243d16,_0x2fd70e);}['_cloneOperation'](_0x4339ab,_0x15d241){const _0x1f60c3=_0x4339ab['clone']();return _0x1f60c3['_authorId']=_0x4339ab['_authorId'],this['_fixOperation'](_0x1f60c3,_0x15d241),_0x1f60c3;}['_getBaseVids'](_0x302022){return _0x302022['map'](_0x3c82b5=>{const _0x4252e5=this['_getVidAttributeName'](_0x3c82b5);return Number(_0x3c82b5['item']['getAttribute'](_0x4252e5));});}['_generateTape'](_0x467bbd,_0x4e7ec1){if(_0x467bbd['is']('element','$text'))_0x4e7ec1['push']({'item':_0x467bbd,'type':'text'});else{_0x467bbd['is']('element')&&_0x4e7ec1['push']({'item':_0x467bbd,'type':'elementStart'});for(const _0x1988cf of _0x467bbd['getChildren']())this['_generateTape'](_0x1988cf,_0x4e7ec1);_0x467bbd['is']('element')&&_0x4e7ec1['push']({'item':_0x467bbd,'type':'elementEnd'});}return _0x4e7ec1;}['_getState'](){const _0x582e9f=new Map(this['_touched']),_0x18d2a5=new Map(_0x582e9f),_0x4d0019=new Map(),_0x4c4877={'insertions':{},'deletions':{}},_0x2c761f={'insertions':{},'deletions':{}},_0x78b328=new Map(),_0x4a70ad=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]),_0x3fce47=new Map();_0x4a70ad['delete']('$graveyard');for(const _0x47beab of _0x4a70ad){const _0x4b7fe1=(this['_diffRoots']['get'](_0x47beab)??this['_baseRoots']['get'](_0x47beab))['name'],_0x47f8bf=this['_diffRoots']['get'](_0x47beab)||wt(_0x47beab,_0x4b7fe1,!0x1),_0x26929f=this['_baseRoots']['get'](_0x47beab)||wt(_0x47beab,_0x4b7fe1,!0x1);_0x47f8bf['isAttached']()||_0x26929f['isAttached']()?(_0x3fce47['set'](_0x47beab,_0x4b7fe1),_0x4c4877['insertions'][_0x47beab]=gt(_0x47f8bf),_0x4c4877['deletions'][_0x47beab]=gt(_0x26929f),this['_copyMarkers'](_0x4c4877['deletions'][_0x47beab],_0x26929f),this['_copyMarkers'](_0x4c4877['insertions'][_0x47beab],_0x47f8bf),_0x2c761f['insertions'][_0x47beab]=this['_generateTape'](this['_idsRoots']['get'](_0x47beab),[]),_0x2c761f['deletions'][_0x47beab]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x47beab)||wt(_0x47beab,_0x4b7fe1,!0x1),[])):_0x4a70ad['delete'](_0x47beab);}for(const _0x29760d of _0x4a70ad){const _0x539f87=_0x2c761f['insertions'][_0x29760d];for(const _0x5d5605 of _0x539f87){const _0x4089e0=this['_getVidAttributeName'](_0x5d5605),_0x51c4cb=_0x5d5605['item']['getAttribute'](_0x4089e0);_0x18d2a5['delete'](_0x51c4cb),_0x51c4cb>=this['_startingRevisionId']&&_0x4d0019['set'](_0x51c4cb,_0x582e9f['get'](_0x51c4cb));}}for(const _0x5093bd of _0x4a70ad){const _0x557344=_0x2c761f['insertions'][_0x5093bd],_0x5c5a3c=this['_getBaseVids'](_0x2c761f['deletions'][_0x5093bd]);let _0x184f6d=0x0;for(const _0x147128 of _0x557344){const _0x47c5fe=this['_getVidAttributeName'](_0x147128),_0x5c69c9=_0x147128['item']['getAttribute'](_0x47c5fe);if(!_0x4d0019['has'](_0x5c69c9)&&!_0x78b328['has'](_0x5c69c9)){if(_0x18d2a5['has'](_0x5c69c9))_0x184f6d++;else{if(_0x5c69c9!=_0x5c5a3c[_0x184f6d]){const _0x2b4b4b=_0x582e9f['get'](_0x5c69c9)||_0x582e9f['get'](_0x5c5a3c[_0x184f6d]);for(;_0x5c69c9!=_0x5c5a3c[_0x184f6d];)_0x18d2a5['has'](_0x5c5a3c[_0x184f6d])||(_0x78b328['set'](_0x5c5a3c[_0x184f6d],_0x2b4b4b),_0x582e9f['set'](_0x5c5a3c[_0x184f6d],_0x2b4b4b)),_0x184f6d++;}_0x184f6d++;}}}}for(const _0x48b27a of _0x4a70ad){const _0x5d7d3f=_0x2c761f['insertions'][_0x48b27a];for(const _0x36c69 of _0x5d7d3f){const _0x308b2d=this['_getVidAttributeName'](_0x36c69),_0xcc80c4=_0x36c69['item']['getAttribute'](_0x308b2d);if(_0x78b328['has'](_0xcc80c4)){const _0x305a37=_0x78b328['get'](_0xcc80c4);_0x18d2a5['has'](_0xcc80c4)||_0x18d2a5['set'](_0xcc80c4,{..._0x305a37}),_0x4d0019['set'](_0xcc80c4,{..._0x305a37});}}}for(const _0x3876b6 of _0x18d2a5['keys']())_0x3876b6>=this['_startingRevisionId']&&_0x18d2a5['delete'](_0x3876b6);const _0x212b13=new Map();for(const _0x566a1c of _0x4a70ad){let _0x577883=_0x2c761f['insertions'][_0x566a1c];for(const _0x5d3b0b of _0x577883)if(_0x5d3b0b['item']['is']('element','tableCell')){const _0x48f2b=this['_getVidAttributeName'](_0x5d3b0b),_0x1a32e5=_0x5d3b0b['item']['getAttribute'](_0x48f2b);if(_0x4d0019['has'](_0x1a32e5)){const _0x5c039c=_0x5d3b0b['item']['parent']['parent']['getAttribute']('vid_start'),_0x2ffbb3=_0x212b13['get'](_0x5c039c)||new Set();_0x2ffbb3['add'](_0x4d0019['get'](_0x1a32e5)['userId']),_0x212b13['set'](_0x5c039c,_0x2ffbb3);}}_0x577883=_0x2c761f['deletions'][_0x566a1c];for(const _0x625a43 of _0x577883)if(_0x625a43['item']['is']('element','tableCell')){const _0x340269=this['_getVidAttributeName'](_0x625a43),_0x494970=_0x625a43['item']['getAttribute'](_0x340269);if(_0x18d2a5['has'](_0x494970)){const _0xd4dd0=_0x625a43['item']['parent']['parent']['getAttribute']('vid_start'),_0x4f1022=_0x212b13['get'](_0xd4dd0)||new Set();_0x4f1022['add'](_0x18d2a5['get'](_0x494970)['userId']),_0x212b13['set'](_0xd4dd0,_0x4f1022);}}for(const _0x5829c7 of _0x212b13['keys']())(_0x4d0019['has'](_0x5829c7)||_0x18d2a5['has'](_0x5829c7))&&_0x212b13['delete'](_0x5829c7);}for(const _0x372ef5 of _0x4a70ad){const _0x539b83=_0x2c761f['insertions'][_0x372ef5];let _0x44534f=null,_0x3c387b=null;for(const _0x43800b of _0x539b83){const _0x22987b=this['_getVidAttributeName'](_0x43800b),_0x525bdc=_0x43800b['item']['getAttribute'](_0x22987b),_0x4e22fa=_0x212b13['get'](_0x525bdc);_0x4e22fa&&'elementStart'==_0x43800b['type']&&(_0x44534f=Array['from'](_0x4e22fa)[0x0],_0x3c387b=_0x43800b['item']['getAttribute']('vid_end')),_0x44534f&&(_0x18d2a5['set'](_0x525bdc,{'userId':_0x44534f}),_0x4d0019['set'](_0x525bdc,{'userId':_0x44534f})),_0x525bdc==_0x3c387b&&(_0x44534f=null,_0x3c387b=null);}}const _0x53aab7={},_0x1da416=new Set();for(const _0x116de1 of _0x4a70ad){const _0x38f953=_0x4c4877['deletions'][_0x116de1],_0x156f70=_0x4c4877['insertions'][_0x116de1];for(const {userId:_0x1b48cc}of this['_touchedMarkers']['values']())null!==_0x1b48cc&&_0x1da416['add'](_0x1b48cc);for(const {userId:_0x21f0fb}of this['_touchedRoots']['values']())null!==_0x21f0fb&&_0x1da416['add'](_0x21f0fb);this['_markChanges'](_0x156f70,_0x2c761f['insertions'][_0x116de1],_0x4d0019,'insertion',_0x1da416),this['_markChanges'](_0x38f953,_0x2c761f['deletions'][_0x116de1],_0x18d2a5,'deletion',_0x1da416),_0x53aab7[_0x116de1]={'insertions':this['_prepareViewToSave'](_0x156f70),'deletions':this['_prepareViewToSave'](_0x38f953),'attachChange':this['_touchedRoots']['get'](_0x116de1)||null,'attributesBefore':_0x527a66(this['_baseRootsAttributes']['get'](_0x116de1))||{},'attributesAfter':_0x527a66(this['_diffRootsAttributes']['get'](_0x116de1)),'rootElementName':_0x3fce47['get'](_0x116de1)};}return{'diffData':_0x53aab7,'authorsIds':Array['from'](_0x1da416)};}['_processRootBeforeSave'](_0x2a642a){for(const [,_0x728619]of _0x2a642a['markers']){const _0x385465=_0x728619['start']['getAncestors']()['filter'](_0x2e7b94=>'tableCell'==_0x2e7b94['name']);for(const _0x21a974 of _0x385465)0x1==_0x21a974['childCount']&&_0x21a974['getChild'](0x0)['is']('element','paragraph')&&_0x21a974['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x4801ec){this['_processRootBeforeSave'](_0x4801ec);const _0x2a7698=this['editor']['data']['toView'](_0x4801ec,{}),_0x1385da=Array['from'](_0x2a7698['getChildren']())['map'](_0x150b41=>this['_getViewJson'](_0x150b41));return JSON['stringify'](_0x1385da);}['_getViewJson'](_0x412e35){if(_0x412e35['is']('$text'))return _0x412e35['data'];{const _0x44e188=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0x29948c=_0x412e35,_0x2bf472=this['editor']['data']['htmlProcessor']['domConverter'],_0x4d05d9={'type':_0x44e188['_getTypeCharForViewElement'](_0x29948c),'name':_0x29948c['name'],'attributes':Array['from'](_0x29948c['getAttributes']()),'children':Array['from'](_0x29948c['getChildren']())['map'](_0x2a01ce=>this['_getViewJson'](_0x2a01ce))};if(_0x412e35['is']('uiElement')&&'$comment'!=_0x412e35['name']){const _0x283328=_0x412e35['render'](_0x2bf472['domDocument'],_0x2bf472);_0x4d05d9['children']['push'](_0x283328['outerHTML']);}else{if(_0x412e35['is']('rawElement')){const _0x3fce58=_0x2bf472['domDocument']['createElement'](_0x29948c['name']);_0x412e35['render'](_0x3fce58,_0x2bf472),_0x4d05d9['children']['push'](_0x3fce58['innerHTML']);}}const _0x3add92=Array['from'](_0x29948c['getCustomProperties']());_0x3add92['length']>0x0&&(_0x4d05d9['customProperties']=_0x3add92);const _0x2104a9=_0x29948c['getFillerOffset']();return null!==_0x2104a9&&(_0x4d05d9['fillerOffset']=_0x2104a9),_0x4d05d9;}}['_markChanges'](_0x2a9d9f,_0x2ee381,_0x487c8c,_0x4d5b7f,_0x15c798){let _0x5bae4a=null,_0xdcff70=null,_0x29f301=0x0;const _0x1aef4c=this['editor']['model'];for(let _0x31bb21=0x0;_0x31bb21<_0x2ee381['length'];_0x31bb21++){const _0x43505f=this['_getVidAttributeName'](_0x2ee381[_0x31bb21]),_0x26da79=_0x2ee381[_0x31bb21]['item']['getAttribute'](_0x43505f),_0x1fa828=_0x487c8c['get'](_0x26da79),_0x477a67=_0x31bb21==_0x2ee381['length']-0x1;(!_0x5bae4a&&_0x1fa828&&(_0x5bae4a=_0x1fa828,_0xdcff70=_0x2ee381[_0x31bb21]),_0x5bae4a&&(!_0x1fa828||_0x1fa828['userId']!=_0x5bae4a['userId']))&&(_0x53b7e6(_0x1fa828,mt(_0xdcff70,_0x2a9d9f,_0x1aef4c),mt(_0x2ee381[_0x31bb21],_0x2a9d9f,_0x1aef4c)),_0x5bae4a=_0x1fa828||null,_0xdcff70=_0x1fa828?_0x2ee381[_0x31bb21]:null),_0x5bae4a&&_0x477a67&&_0x53b7e6(_0x1fa828,mt(_0xdcff70,_0x2a9d9f,_0x1aef4c),pt(_0x2ee381[_0x31bb21],_0x2a9d9f,_0x1aef4c));}function _0x53b7e6(_0x47cb45,_0xe41271,_0x4add29){const _0x530d5d=_0x5bae4a['userId'],_0x1cd03b='revision:'+_0x4d5b7f+':'+_0x530d5d+':'+_0x29f301++,_0x3a7f50=_0x1aef4c['createRange'](_0xe41271,_0x4add29);_0x2a9d9f['markers']['set'](_0x1cd03b,_0x3a7f50),null!==_0x530d5d&&_0x15c798['add'](_0x530d5d);}}['_getVidAttributeName'](_0x250870){switch(_0x250870['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x1204cb,_0xa1057){_0x1204cb['baseVersion']=null;for(const _0xcb2a10 in _0x1204cb){const _0x5b328c=_0x1204cb[_0xcb2a10];if(_0x5b328c instanceof _0x4e4050){const _0x19e648=_0xa1057['get'](_0x5b328c['root']['rootName']);_0x1204cb[_0xcb2a10]=this['_fixPosition'](_0x5b328c,_0x19e648);}if(_0x5b328c instanceof _0x8a4273){const _0x2882b2=_0xa1057['get'](_0x5b328c['root']['rootName']);_0x1204cb[_0xcb2a10]=this['_fixRange'](_0x5b328c,_0x2882b2);}'root'===_0xcb2a10&&(_0x1204cb['root']=_0xa1057['get'](_0x1204cb['root']['rootName']));}}['_fixRange'](_0x2aa2a9,_0x347f19){return this['editor']['model']['createRange'](this['_fixPosition'](_0x2aa2a9['start'],_0x347f19),this['_fixPosition'](_0x2aa2a9['end'],_0x347f19));}['_fixPosition'](_0x1fd7d6,_0x389750){return this['editor']['model']['createPositionFromPath'](_0x389750,_0x1fd7d6['path'],_0x1fd7d6['stickiness']);}['_handleInsertOperation'](_0x31f0f8){const _0x49eed7=this['_idsRoots']['get'](_0x31f0f8['position']['root']['rootName']),_0x60c8=this['_fixPosition'](_0x31f0f8['position'],_0x49eed7),_0x534837=null===_0x31f0f8['_authorId']?null:_0x31f0f8['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x5bcd4b=_0x60c8['parent'],_0xc81e35=this['_revisionId'],_0x256e5d=[];for(const _0x3e060f of _0x31f0f8['nodes'])if(_0x3e060f['is']('element'))_0x256e5d['push'](this['_makeIdsRoot'](_0x3e060f));else{for(let _0x43d16f=0x0;_0x43d16f<_0x3e060f['offsetSize'];_0x43d16f++)_0x256e5d['push'](new _0x45e0a6('$text',{'vid':this['_revisionId']++}));}const _0x3f71bc=this['_revisionId'];for(let _0x15e88f=_0xc81e35;_0x15e88f<_0x3f71bc;_0x15e88f++)this['_touched']['set'](_0x15e88f,{'userId':_0x534837});_0x5bcd4b['_insertChild'](_0x60c8['offset'],_0x256e5d);}['_handleMoveOperation'](_0x242bb9){(_0x242bb9=this['_cloneOperation'](_0x242bb9,this['_idsRoots']))['_execute']();const _0x15b857=null===_0x242bb9['_authorId']?null:_0x242bb9['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x3615d4=_0x242bb9['getMovedRangeStart'](),_0x4c2c80=_0x3615d4['parent'],_0x1bf0be=_0x3615d4['offset'];!function _0xedab9b(_0x3414dc,_0x563f86,_0xacb70c,_0x591466){for(let _0x2b9e3d=_0xacb70c;_0x2b9e3d<_0x591466;_0x2b9e3d++){const _0x135519=_0x563f86['getChild'](_0x2b9e3d);_0x135519['is']('element','$text')?_0x3414dc['set'](_0x135519['getAttribute']('vid'),{'userId':_0x15b857}):(_0x3414dc['set'](_0x135519['getAttribute']('vid_start'),{'userId':_0x15b857}),_0xedab9b(_0x3414dc,_0x135519,0x0,_0x135519['childCount']),_0x3414dc['set'](_0x135519['getAttribute']('vid_end'),{'userId':_0x15b857}));}}(this['_touched'],_0x4c2c80,_0x1bf0be,_0x1bf0be+_0x242bb9['howMany']);}['_handleMergeOperation'](_0x36c6b8){const _0x38b1d0=null===(_0x36c6b8=this['_cloneOperation'](_0x36c6b8,this['_idsRoots']))['_authorId']?null:_0x36c6b8['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x31e67b=_0x36c6b8['targetPosition']['parent'],_0x5b3055=_0x36c6b8['sourcePosition']['parent'],_0x48341a=_0x31e67b['getAttribute']('vid_end'),_0x119b9e=_0x5b3055['getAttribute']('vid_start');_0x31e67b['_setAttribute']('vid_end',_0x5b3055['getAttribute']('vid_end')),_0x5b3055['_setAttribute']('vid_end',_0x48341a),this['_touched']['set'](_0x119b9e,{'userId':_0x38b1d0}),this['_touched']['set'](_0x48341a,{'userId':_0x38b1d0}),_0x36c6b8['_execute']();}['_handleSplitOperation'](_0x15c3cf){const _0x2a604b=null===(_0x15c3cf=this['_cloneOperation'](_0x15c3cf,this['_idsRoots']))['_authorId']?null:_0x15c3cf['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x4c14c3=_0x15c3cf['graveyardPosition'],_0x1aae14=_0x15c3cf['splitPosition']['parent'];_0x15c3cf['_execute']();const _0x5c6e8c=_0x1aae14['getAttribute']('vid_end'),_0x3c7e9d=_0x15c3cf['insertionPosition']['nodeAfter'];if(_0x4c14c3){const _0x4da43c=_0x3c7e9d['getAttribute']('vid_end'),_0x123f0a=_0x1aae14['getAttribute']('vid_end');_0x1aae14['_setAttribute']('vid_end',_0x4da43c),_0x3c7e9d['_setAttribute']('vid_end',_0x123f0a),this['_touched']['set'](_0x1aae14['getAttribute']('vid_end'),{'userId':_0x2a604b}),this['_touched']['set'](_0x3c7e9d['getAttribute']('vid_start'),{'userId':_0x2a604b});}else{const _0x1423da=this['_revisionId']++,_0x297578=this['_revisionId']++;_0x1aae14['_setAttribute']('vid_end',_0x1423da),_0x3c7e9d['_setAttribute']('vid_start',_0x297578),_0x3c7e9d['_setAttribute']('vid_end',_0x5c6e8c),this['_touched']['set'](_0x1423da,{'userId':_0x2a604b}),this['_touched']['set'](_0x297578,{'userId':_0x2a604b});}}['_handleMarkerOperation'](_0x8c03ff){if(!_0x8c03ff['affectsData'])return;const _0x4ac037=(_0x8c03ff=this['_cloneOperation'](_0x8c03ff,this['_diffRoots']))['oldRange']?_0x8c03ff['oldRange']['root']:null,_0x6e7abc=_0x8c03ff['newRange']?_0x8c03ff['newRange']['root']:null;_0x4ac037&&this['_markers']['delete'](_0x8c03ff['name']),_0x6e7abc&&this['_markers']['set'](_0x8c03ff['name'],_0x8c03ff['newRange']['clone']());const _0x18c6f3=null===_0x8c03ff['_authorId']?null:_0x8c03ff['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x1a43e7=_0x8c03ff['name'];if(!this['_touchedMarkers']['has'](_0x1a43e7))return void this['_touchedMarkers']['set'](_0x1a43e7,{'range':_0x8c03ff['oldRange'],'userId':_0x18c6f3});const _0x43c91d=this['_touchedMarkers']['get'](_0x1a43e7),_0xd59a3=_0x43c91d['range'],_0x5af699=_0x8c03ff['newRange'];null==_0xd59a3&&null==_0x5af699||_0xd59a3&&_0x5af699&&_0xd59a3['isEqual'](_0x5af699)?this['_touchedMarkers']['delete'](_0x8c03ff['name']):_0x43c91d['userId']=_0x18c6f3;}['_handleRootOperation'](_0x29cdee,_0x18b559){this['_diffRoots']['has'](_0x29cdee['rootName'])?this['_diffRoots']['get'](_0x29cdee['rootName'])['_isAttached']=_0x29cdee['isAdd']:(this['_diffRoots']['set'](_0x29cdee['rootName'],wt(_0x29cdee['rootName'],_0x29cdee['elementName'],!0x0)),this['_diffRootsAttributes']['set'](_0x29cdee['rootName'],{}),_0x18b559&&this['_idsRoots']['set'](_0x29cdee['rootName'],wt(_0x29cdee['rootName'],_0x29cdee['elementName'],!0x0)));const _0x1d36aa=null===_0x29cdee['_authorId']?null:_0x29cdee['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x1a3e3d=this['_touchedRoots']['get'](_0x29cdee['rootName']);_0x1a3e3d&&_0x1a3e3d['userId']===_0x1d36aa?this['_touchedRoots']['delete'](_0x29cdee['rootName']):this['_touchedRoots']['set'](_0x29cdee['rootName'],{'userId':_0x1d36aa,'isAttached':_0x29cdee['isAdd']});}['_handleRootAttributeOperation'](_0x5f1d03){const _0xc542cf=this['_diffRootsAttributes']['get'](_0x5f1d03['root']['rootName']);null===_0x5f1d03['newValue']?delete _0xc542cf[_0x5f1d03['key']]:_0xc542cf[_0x5f1d03['key']]=_0x5f1d03['newValue'];}}function gt(_0x13bf35){const _0xf71434=wt(_0x13bf35['rootName'],_0x13bf35['name'],_0x13bf35['isAttached']());for(const _0x5a8f89 of _0x13bf35['getChildren']()){const _0x5c7310=_0x5a8f89['_clone'](!0x0);_0xf71434['_appendChild'](_0x5c7310);}return _0xf71434;}function wt(_0x5d15f2,_0x14bca7,_0x24b769=!0x0){const _0x50e9de=new _0x34f38e();return _0x50e9de['rootName']=_0x5d15f2,_0x50e9de['name']=_0x14bca7,_0x50e9de['_isAttached']=_0x24b769,_0x50e9de['isAttached']=()=>_0x50e9de['_isAttached'],_0x50e9de;}function mt(_0x541755,_0x54747f,_0x3c1589){const _0x395271='elementEnd'==_0x541755['type']?_0x3c1589['createPositionAt'](_0x541755['item'],'end'):_0x3c1589['createPositionBefore'](_0x541755['item']);return _0x3c1589['createPositionFromPath'](_0x54747f,_0x395271['path'],_0x395271['stickiness']);}function pt(_0x48c8dd,_0x2e1a7a,_0x12de6a){const _0x57e8b0='elementStart'==_0x48c8dd['type']?_0x12de6a['createPositionAt'](_0x48c8dd['item'],0x0):_0x12de6a['createPositionAfter'](_0x48c8dd['item']);return _0x12de6a['createPositionFromPath'](_0x2e1a7a,_0x57e8b0['path'],_0x57e8b0['stickiness']);}class RevisionHistorySaveRevisionFormView extends/* #__PURE__ -- @preserve */
|
|
25
|
-
|
|
26
|
-
_0x4cbe68(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x27517c){super(),this['id']=_0x27517c['id']||_0x55087c(),this['author']=_0x27517c['author'],this['type']=_0x27517c['type'],this['data']=_0x27517c['data']||{},this['rootName']=_0x27517c['rootName'],this['set']('createdAt',_0x27517c['createdAt']);}['toJSON'](){return{'id':this['id'],'authorId':this['author']['id'],'type':this['type'],'data':this['data'],'createdAt':this['createdAt']};}}class RevisionDiff{['newRevisionId'];['oldRevisionId'];['changes'];constructor(_0x485069,_0x18ebbf){this['newRevisionId']=_0x485069,this['oldRevisionId']=_0x18ebbf,this['changes']=new _0x12a0e4();}['_setChanges'](_0x48334f){for(const _0x2b3df1 of _0x48334f)this['changes']['add'](_0x2b3df1);}}class RevisionViewer extends _0x18ed42{['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[_0x4c4887,et,RevisionsRepository,RevisionHistoryUtils];}constructor(_0x494fe6){super(_0x494fe6),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',(_0x3af280,_0x9a3c50,_0x5e6ced)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x5215b1=>{for(const _0x443183 of this['editor']['editing']['view']['document']['roots'])_0x5e6ced?_0x5215b1['removeClass']('ck-editor__editable__overlay',_0x443183):_0x5215b1['addClass']('ck-editor__editable__overlay',_0x443183);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x2a2360=>null!==_0x2a2360),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x3febfd,_0x2daccb,_0x382524)=>_0x3febfd&&_0x382524?_0x2daccb['changes']['getIndex'](_0x382524):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x364e72,_0x2b9c2d)=>_0x364e72?_0x2b9c2d['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](et);}['init'](){const _0x1657ed=this['editor'],_0x2936c7=new ShowChangeCommand(_0x1657ed,{'direction':'backward'}),_0x135f67=new ShowChangeCommand(_0x1657ed,{'direction':'forward'});(_0x1657ed['commands']['add']('showPreviousChange',_0x2936c7),_0x1657ed['commands']['add']('showNextChange',_0x135f67),_0x1657ed['commands']['add']('restoreRevision',new RestoreRevisionCommand(_0x1657ed)),this['on']('change:numberOfChanges',()=>{_0x2936c7['refresh'](),_0x135f67['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x1657ed['enableReadOnlyMode']('revision-viewer'),_0x1657ed['plugins']['has']('WidgetToolbarRepository'))&&_0x1657ed['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x155073){return await this['_utils']['loadRevisionData'](_0x155073,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x155073);}async['getRevisionRootsAttributes'](_0x1ef00d){return await this['_utils']['loadRevisionData'](_0x1ef00d,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x1ef00d);}async['compare'](_0x1540ae,_0x3627aa,_0x18e22b=!0x1){if(!this['isEnabled'])return;const _0x5e7bf8=this['diff'],_0x106a1a=this['repository'],_0xa5d484='string'==typeof _0x1540ae?_0x106a1a['getRevision'](_0x1540ae):_0x1540ae,_0x252dc0='string'==typeof _0x3627aa?_0x106a1a['getRevision'](_0x3627aa):_0x3627aa,_0xd75a43=_0xa5d484['id'],_0x1bb20d=_0x252dc0?_0x252dc0['id']:null;if(!_0x18e22b&&this['diff']&&this['diff']['newRevisionId']===_0xd75a43&&this['diff']['oldRevisionId']===_0x1bb20d)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new RevisionDiff(_0xd75a43,_0x1bb20d);const _0x1da27a=this['_getRevisionsRange'](_0xa5d484,_0x252dc0,!0x0)['map'](_0x87c518=>this['_utils']['loadRevisionData'](_0x87c518,this['adapter']));return _0x1da27a['push'](new Promise(_0x116068=>{setTimeout(_0x116068,0x14);})),Promise['all'](_0x1da27a)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x39ec9d=this['_getDiff'](_0xd75a43,_0x1bb20d);for(const _0x232ed8 of _0x39ec9d['changes'])this['_changeIdToChange']['set'](_0x232ed8['id'],_0x232ed8);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x5364f9=>{for(const _0x4ba985 of this['editor']['model']['document']['getRootNames']())_0x5364f9['detachRoot'](_0x4ba985);for(const _0x17da1a of Object['keys'](_0x39ec9d['model'])){const _0x1aa0f=_0x39ec9d['model'][_0x17da1a]['name'],_0x40ae6f=_0x5364f9['addRoot'](_0x17da1a,_0x1aa0f);for(const _0x563cae of Object['keys'](_0x39ec9d['attributes'][_0x17da1a]))_0x5364f9['setAttribute'](_0x563cae,_0x39ec9d['attributes'][_0x17da1a][_0x563cae],_0x40ae6f);_0x5364f9['insert'](_0x39ec9d['model'][_0x17da1a],_0x40ae6f,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x39ec9d['changes'])),this['isReady']=!0x0;})['catch'](_0x257782=>{console['error'](_0x257782),this['_cleanUp'](),_0x5e7bf8&&(this['diff']=_0x5e7bf8),this['isReady']=!0x0;});}['addRevisionData'](_0xa0c232,_0x96f41e){const _0x168c9a=this['repository']['createRevision'](_0xa0c232);return _0x168c9a['on']('_update',(_0x32cf49,_0x3a9a12,_0xa9dcbf)=>_0x96f41e(_0x3a9a12,_0xa9dcbf,_0x168c9a)),this['repository']['addRevision'](_0x168c9a),_0x168c9a;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x1da53b=>{for(const _0x3286bb of this['editor']['model']['document']['getRootNames']())_0x1da53b['detachRoot'](_0x3286bb);});}['_sortAndFilterDiffChanges'](_0x1a7083){const _0x145f33=[],_0x40d99f=new Map();for(const _0xeb6333 of this['editor']['model']['document']['getRootNames']()){const _0x50d858=this['editor']['editing']['view']['getDomRoot'](_0xeb6333);if(!_0x50d858)continue;const _0x5905cf=_0x50d858['getClientRects']()['item'](0x0);_0x5905cf&&(_0x145f33['push'](_0xeb6333),_0x40d99f['set'](_0xeb6333,_0x5905cf));}return _0x145f33['sort']((_0x5b6681,_0x83971)=>{const _0x2145e8=_0x40d99f['get'](_0x5b6681),_0x473752=_0x40d99f['get'](_0x83971);return _0x2145e8['y']-_0x473752['y']||_0x2145e8['x']-_0x473752['x'];}),(_0x1a7083=_0x1a7083['filter'](_0x11b208=>_0x145f33['includes'](_0x11b208['rootName'])))['sort']((_0x537813,_0x43d062)=>_0x145f33['indexOf'](_0x537813['rootName'])-_0x145f33['indexOf'](_0x43d062['rootName'])),_0x1a7083;}['_makeTape'](_0x2baae6){const _0x4083d5=Array['from'](_0x2baae6['markers'])['filter'](([_0x4a030f,_0xd05172])=>_0x4a030f['startsWith']('revision:')&&!_0xd05172['isCollapsed']),_0x2119a8=Array['from'](this['editor']['model']['createRangeIn'](_0x2baae6)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x4083d5['length'])for(const _0x55e963 of _0x2119a8){const [_0x1a5621,_0x31d26b]=_0x4083d5[0x0],[,_0x399490,_0x2c8c20]=_0x1a5621['split'](':');if(_0x31d26b['end']['isEqual'](_0x55e963['nextPosition'])&&_0x4083d5['shift'](),(_0x55e963['previousPosition']['isEqual'](_0x31d26b['start'])||_0x55e963['previousPosition']['isAfter'](_0x31d26b['start']))&&('insertion'==_0x399490?_0x55e963['isAdded']={'userId':_0x2c8c20}:'deletion'==_0x399490&&(_0x55e963['isRemoved']={'userId':_0x2c8c20})),0x0==_0x4083d5['length'])break;}return _0x2119a8;}['_refreshStartEndIndex'](_0x44facd){const _0xf342e6=new Map();for(let _0x5f0cd3=0x0;_0x5f0cd3<_0x44facd['length'];_0x5f0cd3++)'text'===_0x44facd[_0x5f0cd3]['type']?(_0x44facd[_0x5f0cd3]['item']['startIndex']=_0x5f0cd3,_0x44facd[_0x5f0cd3]['item']['endIndex']=_0x5f0cd3):('elementStart'===_0x44facd[_0x5f0cd3]['type']?_0x44facd[_0x5f0cd3]['item']['startIndex']=_0x5f0cd3:'elementEnd'===_0x44facd[_0x5f0cd3]['type']&&(_0x44facd[_0x5f0cd3]['item']['endIndex']=_0x5f0cd3),_0xf342e6['set'](_0x44facd[_0x5f0cd3]['id'],_0x5f0cd3));for(const _0x41513d of _0xf342e6['values']())'elementStart'===_0x44facd[_0x41513d]['type']?_0x44facd[_0x41513d]['item']['endIndex']=_0xf342e6['get'](_0x44facd[_0x41513d]['pairId']):'elementEnd'===_0x44facd[_0x41513d]['type']&&(_0x44facd[_0x41513d]['item']['startIndex']=_0xf342e6['get'](_0x44facd[_0x41513d]['pairId']));}['_processTape'](_0x774158){for(let _0x1a2458=0x0;_0x1a2458<_0x774158['length'];_0x1a2458++){if('elementStart'===_0x774158[_0x1a2458]['type'])_0x774158[_0x1a2458]['item']['startIndex']=_0x1a2458;else{if('elementEnd'===_0x774158[_0x1a2458]['type']){_0x774158[_0x1a2458]['item']['endIndex']=_0x1a2458;const _0x308e72=_0x774158[_0x1a2458]['item']['startIndex'];_0x774158[_0x308e72]['pairId']=_0x774158[_0x1a2458]['id'],_0x774158[_0x1a2458]['pairId']=_0x774158[_0x308e72]['id'];}else _0x774158[_0x1a2458]['item']['startIndex']=_0x1a2458,_0x774158[_0x1a2458]['item']['endIndex']=_0x1a2458,_0x774158[_0x1a2458]['pairId']=null;}_0x774158[_0x1a2458]['markersStart']||(_0x774158[_0x1a2458]['markersStart']=[],_0x774158[_0x1a2458]['markersEnd']=[]);}}['_markInsertions'](_0x58db94,_0x2af9a1){const _0x2b95c4=_0x58db94['filter'](_0x2b3f3c=>!_0x2b3f3c['isAdded']);for(let _0x5160d9=0x0;_0x5160d9<_0x2af9a1['length'];_0x5160d9++)_0x2af9a1[_0x5160d9]['isAdded']&&(_0x2b95c4[_0x5160d9]['isAdded']=_0x2af9a1[_0x5160d9]['isAdded']);}['_getDiff'](_0x4f50dc,_0x318459=null){const _0x900e4f=this['repository']['getRevision'](_0x4f50dc),_0x341385=_0x318459?this['repository']['getRevision'](_0x318459):null,_0x1fcf16=this['_getRevisionsRange'](_0x900e4f,_0x341385),_0x132144=_0x1fcf16[_0x1fcf16['length']-0x1],_0xe017b9=new Map(),_0x3f8873={'model':{},'attributes':{},'changes':[]},_0x4c122b=new Set(),_0x483f79=new Map();for(let _0x64ee4=_0x1fcf16['length']-0x1;_0x64ee4>=0x0;_0x64ee4--){const _0x3118b4=_0x1fcf16[_0x64ee4];for(const _0xe702ec of Object['keys'](_0x3118b4['diffData']))if(_0x3118b4['diffData'][_0xe702ec]['attachChange']){const _0x21ece3=_0x3118b4['diffData'][_0xe702ec]['attachChange'];_0x21ece3['isAttached']?(_0x4c122b['add'](_0xe702ec),_0x483f79['has'](_0xe702ec)&&_0x483f79['get'](_0xe702ec)['userId']==_0x21ece3['userId']?_0x483f79['delete'](_0xe702ec):_0x483f79['set'](_0xe702ec,_0x21ece3)):_0x483f79['has'](_0xe702ec)?(_0x4c122b['delete'](_0xe702ec),_0x483f79['delete'](_0xe702ec)):(_0x4c122b['add'](_0xe702ec),_0x483f79['set'](_0xe702ec,_0x21ece3));}else _0x4c122b['add'](_0xe702ec);}for(const _0xb78017 of _0x4c122b){const _0x3e067d=_0x483f79['has'](_0xb78017)&&!_0x483f79['get'](_0xb78017)['isAttached'];let _0x14d78a=_0x3e067d?_0x1fcf16['length']-0x1:0x0;const _0x54b575=_0x3e067d?-0x1:0x1;for(;_0x1fcf16[_0x14d78a];){const _0x31a01e=_0x1fcf16[_0x14d78a];if(_0x31a01e['diffData'][_0xb78017]){const _0xf72002=_0x3e067d?_0x31a01e['diffData'][_0xb78017]['attributesBefore']:_0x31a01e['diffData'][_0xb78017]['attributesAfter'];_0x3f8873['attributes'][_0xb78017]=_0xf72002?_0x527a66(_0xf72002):{};break;}_0x14d78a+=_0x54b575;}}for(const _0xb173d of _0x1fcf16){_0xb173d['model']={};for(const _0x3d878c of _0xb173d['authors'])_0xe017b9['set'](_0x3d878c['id'],_0x3d878c);for(const _0x33ec15 of _0x4c122b){const _0x4bbd86=_0xb173d['diffData'][_0x33ec15]?_0xb173d['diffData'][_0x33ec15]['insertions']:'[]',_0x2199c9=_0xb173d['diffData'][_0x33ec15]?_0xb173d['diffData'][_0x33ec15]['deletions']:'[]',_0x599d92=_0xb173d['diffData'][_0x33ec15]?.['rootElementName']||'$root';_0xb173d['model'][_0x33ec15]={'insertions':this['_utils']['_makeModelFromViewString'](_0x4bbd86,_0x599d92),'deletions':this['_utils']['_makeModelFromViewString'](_0x2199c9,_0x599d92)};}}for(const _0x365a3d of _0x4c122b){let _0x4c41b3=null,_0x52df91=0x0;const _0x4d6ec5=_0x1fcf16['map'](_0x4dbd55=>_0x4dbd55['diffData'][_0x365a3d]?.['rootElementName'])['find'](_0x252e6e=>void 0x0!==_0x252e6e)||'$root',_0x22a3c1=new Map(Array['from'](_0x900e4f['model'][_0x365a3d]['insertions']['markers'])['filter'](([_0xaac474])=>!_0xaac474['startsWith']('revision:')));let _0x419500=0x0;for(const _0x21470f of _0x1fcf16){const _0x4a261d=this['_makeTape'](_0x21470f['model'][_0x365a3d]['insertions']);_0x21470f==_0x900e4f?(_0x4c41b3=_0x4a261d,_0x52df91=_0x4c41b3['length'],_0x4c41b3['forEach'](_0x4d92c0=>{_0x4d92c0['id']=_0x419500++;}),this['_processTape'](_0x4c41b3)):this['_markInsertions'](_0x4c41b3,_0x4a261d);const _0x11d726=_0x4c41b3['filter'](_0x51806a=>!_0x51806a['isAdded'])['map'](_0x315351=>_0x315351['id']);let _0x4412ac=0x0;const _0x53ea00=this['_makeTape'](_0x21470f['model'][_0x365a3d]['deletions']);_0x53ea00['forEach'](_0x281801=>{_0x281801['isRemoved']?_0x281801['id']=_0x52df91++:_0x281801['id']=_0x11d726[_0x4412ac++];}),this['_processTape'](_0x53ea00),this['_setDistance'](_0x4c41b3,'isAdded'),this['_setDistance'](_0x53ea00,'isRemoved'),_0x21470f==_0x900e4f&&this['_markMarkers'](_0x4c41b3,_0x22a3c1),_0x4c41b3=this['_joinTapes'](_0x4c41b3,_0x53ea00),this['_refreshStartEndIndex'](_0x4c41b3),this['_setDistance'](_0x4c41b3,'isRemoved');}_0x4c41b3=_0x4c41b3['filter'](_0x2527b8=>!(_0x2527b8['isAdded']&&_0x2527b8['isRemoved']));const _0x63a536=new Map(_0x132144['model'][_0x365a3d]['deletions']['markers']),_0x47308f=new Set(_0x22a3c1['keys']());for(const _0x1e0fb6 of _0x63a536['keys']())_0x47308f['delete'](_0x1e0fb6);this['_markSuggestions'](_0x4c41b3,_0x47308f),this['_fixObsoleteTags'](_0x4c41b3),_0x4c41b3=this['_removeMissingPairs'](_0x4c41b3),_0x4c41b3=this['_markMismatchedRemovedTags'](_0x4c41b3),_0x4c41b3=this['_removeUnsupportedChanges'](_0x4c41b3);const {root:_0x5bb5d4,changes:_0x231308}=this['_makeModelFromTape'](_0x4c41b3,_0xe017b9,_0x365a3d,_0x4d6ec5);_0x3f8873['model'][_0x365a3d]=_0x5bb5d4;const _0xcac542=_0x483f79['get'](_0x365a3d);if(_0xcac542){const _0x74e8a6=_0xe017b9['get'](_0xcac542['userId']),_0x153469=new ChangeItem({'author':_0x74e8a6,'type':_0xcac542['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x365a3d});_0x231308['unshift'](_0x153469),_0x3f8873['attributes'][_0x365a3d]['revisionHistoryAttachChange']=_0x153469['id'];}_0x3f8873['changes']=_0x3f8873['changes']['concat'](_0x231308);}return _0x3f8873;}['_markMarkers'](_0x2479ed,_0x12ee00){for(let _0x579a7e=0x0;_0x579a7e<_0x2479ed['length'];_0x579a7e++)for(const [_0x54b306,_0x123917]of _0x12ee00)!_0x123917['isCollapsed']&&_0x123917['start']['isEqual'](_0x2479ed[_0x579a7e]['previousPosition'])&&_0x2479ed[_0x579a7e]['markersStart']['push'](_0x54b306),_0x123917['end']['isEqual'](_0x2479ed[_0x579a7e]['nextPosition'])&&_0x2479ed[_0x579a7e]['markersEnd']['push'](_0x54b306);}['_joinTapes'](_0x5c26d7,_0x3b4ff9){let _0x1f8959=[],_0x4d0f9f=0x0,_0x7b261a=0x0;for(;_0x4d0f9f<_0x5c26d7['length']||_0x7b261a<_0x3b4ff9['length'];){const _0x39efc1=_0x5c26d7[_0x4d0f9f]||{},_0x28ca59=_0x3b4ff9[_0x7b261a]||{};if(_0x39efc1['id']==_0x28ca59['id'])_0x4d0f9f++,_0x7b261a++,_0x1f8959['push'](_0x39efc1);else{if(_0x28ca59['isRemoved']&&_0x39efc1['isAdded']){const {commonTape:_0x13bbf5,iEnd:_0x45ca9c,jEnd:_0x1357c4}=this['_threeWayMerge'](_0x5c26d7,_0x4d0f9f,_0x3b4ff9,_0x7b261a);_0x1f8959=_0x1f8959['concat'](_0x13bbf5),_0x4d0f9f=_0x45ca9c,_0x7b261a=_0x1357c4;}else _0x28ca59['isRemoved']?(_0x7b261a++,_0x1f8959['push'](_0x28ca59)):(_0x4d0f9f++,_0x1f8959['push'](_0x39efc1));}}return _0x1f8959;}['_markSuggestions'](_0x1b5a15,_0x584bf1){const _0x4bc3a2=[];for(let _0x3740f7=0x0;_0x3740f7<_0x1b5a15['length'];_0x3740f7++){for(let _0x10588c=0x0;_0x10588c<_0x1b5a15[_0x3740f7]['markersStart']['length'];_0x10588c++){const _0x22c367=_0x1b5a15[_0x3740f7]['markersStart'][_0x10588c];if(!_0x584bf1['has'](_0x22c367))continue;const {group:_0x4e55fe,type:_0x3ebcce,authorId:_0x4db3a2}=_0x20c608(_0x22c367);'revision-suggestion'!=_0x4e55fe||'insertion'!=_0x3ebcce&&'deletion'!=_0x3ebcce||(_0x4bc3a2['unshift']({'type':_0x3ebcce,'name':_0x22c367,'userId':_0x4db3a2}),_0x1b5a15[_0x3740f7]['markersStart']['splice'](_0x10588c,0x1),_0x10588c--);}_0x1a717b(_0x1b5a15[_0x3740f7]);for(let _0x3fe000=0x0;_0x3fe000<_0x1b5a15[_0x3740f7]['markersEnd']['length'];_0x3fe000++){const _0x577538=_0x1b5a15[_0x3740f7]['markersEnd'][_0x3fe000];if(!_0x584bf1['has'](_0x577538))continue;const {group:_0x493a34,type:_0x503c07}=_0x20c608(_0x577538);if('revision-suggestion'!=_0x493a34||'insertion'!=_0x503c07&&'deletion'!=_0x503c07)continue;_0x1b5a15[_0x3740f7]['markersEnd']['splice'](_0x3fe000,0x1),_0x3fe000--;const _0x54bd8a=_0x4bc3a2['findIndex'](_0x4afdfb=>_0x4afdfb['name']==_0x577538);_0x54bd8a>-0x1&&_0x4bc3a2['splice'](_0x54bd8a,0x1);}}function _0x20c608(_0x364175){const _0x5865e9=_0x364175['split'](':');return{'group':_0x5865e9[0x0],'type':_0x5865e9[0x1],'subType':_0x5865e9['length']>=0x5?_0x5865e9[0x2]:null,'id':_0x5865e9['length']<0x5?_0x5865e9[0x2]:_0x5865e9[0x3],'authorId':_0x5865e9['length']<0x5?_0x5865e9[0x3]:_0x5865e9[0x4],'markerCount':0x6==_0x5865e9['length']?_0x5865e9[0x5]:null};}function _0x1a717b(_0xb3bd3d){for(let _0x1702f1=0x0;_0x1702f1<_0x4bc3a2['length'];_0x1702f1++){if(_0xb3bd3d['isAdded']&&'insertion'==_0x4bc3a2[_0x1702f1]['type']&&_0xb3bd3d['isAdded']['userId']==_0x4bc3a2[_0x1702f1]['userId'])return _0xb3bd3d['isAddSuggestion']=_0x4bc3a2[_0x1702f1],void delete _0xb3bd3d['isAdded'];if(!_0xb3bd3d['isAdded']&&!_0xb3bd3d['isRemoved']&&'deletion'==_0x4bc3a2[_0x1702f1]['type'])return void(_0xb3bd3d['isRemoveSuggestion']=_0x4bc3a2[_0x1702f1]);}}}['_setDistance'](_0x13144c,_0x52eeb3){let _0x329984=0x0,_0x220d63=!0x1;const _0x7c9bc3=new Map();for(const _0x5099ed of _0x13144c)_0x5099ed[_0x52eeb3]?_0x220d63&&(_0x329984++,_0x220d63=!0x1):(_0x329984++,_0x220d63=!0x0),_0x7c9bc3['set'](_0x5099ed['id'],_0x329984);for(let _0x594227=0x0;_0x594227<_0x13144c['length'];_0x594227++){if('isRemoved'==_0x52eeb3&&_0x13144c[_0x594227]['isAdded']||'isAdded'==_0x52eeb3&&_0x13144c[_0x594227]['isRemoved'])continue;if('text'==_0x13144c[_0x594227]['type']){_0x13144c[_0x594227]['distance']=0x0;continue;}const _0x4146f5=_0x7c9bc3['get'](_0x13144c[_0x594227]['pairId']),_0x197f33=_0x7c9bc3['get'](_0x13144c[_0x594227]['id']);_0x13144c[_0x594227]['distance']=_0x4146f5-_0x197f33;}}['_getRevisionsRange'](_0x3c9808,_0x3daf23,_0x2fef34=!0x1){const _0x1bbf4a=[];let _0x2662be=this['repository']['getIndex'](_0x3c9808),_0x533ce0=this['repository']['getIndex'](_0x3daf23);for(-0x1==_0x533ce0&&(_0x533ce0=this['repository']['_revisions']['length'],_0x2fef34=!0x1);_0x2662be<_0x533ce0;)_0x1bbf4a['push'](this['repository']['getRevision'](_0x2662be)),_0x2662be++;return _0x2fef34&&_0x1bbf4a['push'](this['repository']['getRevision'](_0x2662be)),_0x1bbf4a;}['_threeWayMerge'](_0x57cedd,_0x19fc15,_0x1fcfaa,_0xdd63e9){const _0x438a21=this['editor']['model']['schema'];let _0x28021a=_0x19fc15;for(;_0x57cedd[_0x28021a]&&_0x57cedd[_0x28021a]['isAdded'];)_0x28021a++;let _0x123b78=_0xdd63e9;for(;_0x1fcfaa[_0x123b78]&&_0x1fcfaa[_0x123b78]['isRemoved'];)_0x123b78++;_0x2b1282(_0x57cedd,_0x19fc15,_0x28021a),_0x2b1282(_0x1fcfaa,_0xdd63e9,_0x123b78);const _0x5c2ddd=_0x1fcfaa['slice'](_0xdd63e9,_0x123b78)['concat'](_0x57cedd['slice'](_0x19fc15,_0x28021a));return _0x5c2ddd['sort']((_0x4d2dd5,_0x24e3ae)=>_0x4d2dd5['side']!=_0x24e3ae['side']?_0x4d2dd5['side']-_0x24e3ae['side']:_0x4d2dd5['level']!=_0x24e3ae['level']?_0x4d2dd5['level']-_0x24e3ae['level']:_0x4d2dd5['distance']!=_0x24e3ae['distance']?_0x24e3ae['distance']-_0x4d2dd5['distance']:!!_0x4d2dd5['isAdded']!=!!_0x24e3ae['isAdded']?-0x1==_0x4d2dd5['side']||0x0==_0x4d2dd5['side']?_0x4d2dd5['isAdded']?-0x1:0x1:_0x4d2dd5['isAdded']?0x1:-0x1:_0x4d2dd5['index']-_0x24e3ae['index']),{'commonTape':_0x5c2ddd,'iEnd':_0x28021a,'jEnd':_0x123b78};function _0x2b1282(_0x658418,_0x1d71ce,_0x3dfc91){let _0x360aaa=-0x1,_0x3d7938=Number['POSITIVE_INFINITY'],_0x3ef597=!0x0;for(let _0x3591b5=_0x1d71ce;_0x3591b5<_0x3dfc91;_0x3591b5++)if(_0x438a21['isInline'](_0x658418[_0x3591b5]['item'])||(_0x3ef597=!0x1),_0x658418[_0x3591b5]['item']['startIndex']<_0x1d71ce&&(_0x360aaa=_0x3591b5),_0x658418[_0x3591b5]['item']['endIndex']>=_0x3dfc91){_0x3d7938=_0x3591b5;break;}_0x3ef597&&(_0x360aaa=_0x3dfc91-0x1);for(let _0x1929c3=_0x1d71ce;_0x1929c3<_0x3dfc91;_0x1929c3++)_0x658418[_0x1929c3]['side']=_0x1929c3<=_0x360aaa?-0x1:_0x1929c3<_0x3d7938?0x0:0x1,_0x658418[_0x1929c3]['index']=_0x1929c3;let _0x37463a=0x0;for(let _0x1a3d49=_0x1d71ce;_0x1a3d49<=_0x360aaa;_0x1a3d49++)0x0==_0x658418[_0x1a3d49]['distance']?_0x658418[_0x1a3d49]['level']=_0x37463a:(_0x37463a++,_0x658418[_0x1a3d49]['level']=_0x37463a,_0x37463a++);for(let _0x40d79b=_0x1d71ce;_0x40d79b<_0x3dfc91;_0x40d79b++)0x0==_0x658418[_0x40d79b]['side']&&(_0x658418[_0x40d79b]['level']=_0x37463a);_0x37463a=0x0;for(let _0x37b204=_0x3dfc91-0x1;_0x37b204>=_0x3d7938;_0x37b204--)0x0==_0x658418[_0x37b204]['distance']?_0x658418[_0x37b204]['level']=_0x37463a:(_0x37463a--,_0x658418[_0x37b204]['level']=_0x37463a,_0x37463a--);}}['_fixObsoleteTags'](_0x4c0d5f){const _0x29af8e=new Map(),_0x2a2921=this['editor']['model']['schema'];for(let _0x5eb623=0x1;_0x5eb623<_0x4c0d5f['length'];_0x5eb623++){let _0x11b39f,_0x3e1334,_0x2de003;const _0x370038=_0x4c0d5f[_0x5eb623],_0x32865f=_0x4c0d5f[_0x5eb623-0x1];if('text'==_0x370038['type'])continue;if(_0x370038['type']!=_0x32865f['type'])continue;if(!_0x2a2921['isBlock'](_0x32865f['item'])||_0x2a2921['isLimit'](_0x32865f['item']))continue;if(!_0x2a2921['isBlock'](_0x370038['item'])||_0x2a2921['isLimit'](_0x370038['item']))continue;if((_0x4c0d5f[_0x5eb623]['isAdded']||_0x4c0d5f[_0x5eb623]['isAddSuggestion'])&&_0x4c0d5f[_0x5eb623-0x1]['isRemoved'])_0x11b39f=_0x4c0d5f[_0x5eb623],_0x3e1334=_0x4c0d5f[_0x5eb623-0x1],_0x2de003=_0x5eb623-0x1;else{if(!_0x4c0d5f[_0x5eb623]['isRemoved']||!_0x4c0d5f[_0x5eb623-0x1]['isAdded']&&!_0x4c0d5f[_0x5eb623-0x1]['isAddSuggestion'])continue;_0x11b39f=_0x4c0d5f[_0x5eb623-0x1],_0x3e1334=_0x4c0d5f[_0x5eb623],_0x2de003=_0x5eb623;}const _0x4d3298=_0x11b39f['level']==_0x3e1334['level'],_0x249368=Math['abs'](_0x11b39f['level'])<Math['abs'](_0x3e1334['level'])&&0x0==_0x3e1334['distance'];(_0x4d3298||_0x249368)&&(_0x29af8e['set'](_0x3e1334['id'],_0x11b39f['id']),_0x4c0d5f['splice'](_0x2de003,0x1),_0x5eb623--,_0x11b39f['isAdded']=!0x1);}for(let _0x2da6f0=0x0;_0x2da6f0<_0x4c0d5f['length'];_0x2da6f0++)_0x29af8e['has'](_0x4c0d5f[_0x2da6f0]['pairId'])&&(_0x4c0d5f[_0x2da6f0]['pairId']=_0x29af8e['get'](_0x4c0d5f[_0x2da6f0]['pairId']));}['_removeMissingPairs'](_0x32493b){const _0x63ebd0=new Set(_0x32493b['map'](_0x3b6601=>_0x3b6601['id']));for(let _0x15523e=0x0;_0x15523e<_0x32493b['length'];_0x15523e++)_0x63ebd0['has'](_0x32493b[_0x15523e]['pairId'])||0x0==_0x32493b[_0x15523e]['distance']||(_0x32493b[_0x15523e]['isIncorrect']=!0x0);return _0x32493b['filter'](_0x49f429=>!_0x49f429['isIncorrect']);}['_markMismatchedRemovedTags'](_0x54b50e){const _0x263e55=new Set();for(let _0x51532a=0x0;_0x51532a<_0x54b50e['length'];_0x51532a++){if(_0x263e55['has'](_0x54b50e[_0x51532a]['id'])&&_0x54b50e[_0x51532a]['isRemoved']&&(_0x54b50e[_0x51532a]['isIncorrect']=!0x0),_0x54b50e[_0x51532a]['isIncorrect'])continue;if(0x0==_0x54b50e[_0x51532a]['distance'])continue;if('elementStart'!=_0x54b50e[_0x51532a]['type'])continue;if(null==_0x54b50e[_0x51532a]['pairId'])continue;let _0x89fe9b=_0x51532a+0x1,_0x5dab21=0x0;for(;_0x54b50e[_0x89fe9b]['id']!=_0x54b50e[_0x51532a]['pairId'];)'elementStart'==_0x54b50e[_0x89fe9b]['type']?_0x5dab21++:'elementEnd'==_0x54b50e[_0x89fe9b]['type']&&_0x5dab21--,_0x89fe9b++;if(0x0!=_0x5dab21){if(_0x54b50e[_0x51532a]['isRemoved'])_0x54b50e[_0x51532a]['isIncorrect']=!0x0;else{for(;_0x89fe9b!=_0x51532a;)_0x54b50e[_0x89fe9b]['isRemoved']&&0x0!=_0x54b50e[_0x89fe9b]['distance']&&(_0x54b50e[_0x89fe9b]['isIncorrect']=!0x0,_0x263e55['add'](_0x54b50e[_0x89fe9b]['pairId'])),_0x89fe9b--;}}}return _0x54b50e['filter'](_0x1acaac=>!_0x1acaac['isIncorrect']);}['_removeUnsupportedChanges'](_0x1054c4){const _0x56e100=this['editor']['model']['schema'];for(let _0x4fdd1b=0x0;_0x4fdd1b<_0x1054c4['length'];_0x4fdd1b++){if(!(_0x1054c4[_0x4fdd1b]['isAdded']||_0x1054c4[_0x4fdd1b]['isAddSuggestion']||_0x1054c4[_0x4fdd1b]['isRemoved']||_0x1054c4[_0x4fdd1b]['isRemoveSuggestion']))continue;if(0x0==_0x1054c4[_0x4fdd1b]['distance'])continue;const _0x2e23b4=_0x1054c4[_0x4fdd1b]['item'];_0x56e100['isBlock'](_0x2e23b4)||_0x56e100['isLimit'](_0x2e23b4)||(_0x1054c4[_0x4fdd1b]['isAdded']&&delete _0x1054c4[_0x4fdd1b]['isAdded'],_0x1054c4[_0x4fdd1b]['isAddSuggestion']&&delete _0x1054c4[_0x4fdd1b]['isAddSuggestion'],_0x1054c4[_0x4fdd1b]['isRemoveSuggestion']&&delete _0x1054c4[_0x4fdd1b]['isRemoveSuggestion'],_0x1054c4[_0x4fdd1b]['isRemoved']&&(_0x1054c4[_0x4fdd1b]['isIncorrect']=!0x0));}return _0x1054c4['filter'](_0x26a9cf=>!_0x26a9cf['isIncorrect']);}['_makeModelFromTape'](_0x5cf989,_0x10dbc6,_0xb82977,_0x7bf851){const _0x3a642f=new _0x34f38e(),_0x22dbc1=[],_0x55db90=new Map(),_0x2fe856=this['editor']['model'],_0x5bc52a=_0x2fe856['schema'],_0x35e7ee=[_0x3a642f],_0x42c861={},_0x51f6ca={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};_0x3a642f['name']=_0x7bf851;let _0x41afa0=null;const _0x18202b=[0x0];for(let _0x613e8e=0x0;_0x613e8e<_0x5cf989['length'];_0x613e8e++)if('elementStart'===_0x5cf989[_0x613e8e]['type']){_0x5cf989[_0x613e8e]['previousPosition']=_0x2fe856['createPositionFromPath'](_0x3a642f,_0x18202b);const _0x3f68b7=new _0x45e0a6(_0x5cf989[_0x613e8e]['item']['name'],_0x5cf989[_0x613e8e]['item']['getAttributes']());_0x35e7ee[0x0]['_appendChild'](_0x3f68b7),_0x18202b['push'](0x0),_0x35e7ee['unshift'](_0x3f68b7),_0x5cf989[_0x613e8e]['nextPosition']=_0x2fe856['createPositionFromPath'](_0x3a642f,_0x18202b);}else'elementEnd'===_0x5cf989[_0x613e8e]['type']?(_0x35e7ee['shift'](),_0x5cf989[_0x613e8e]['previousPosition']=_0x2fe856['createPositionFromPath'](_0x3a642f,_0x18202b),_0x18202b['pop'](),_0x18202b[_0x18202b['length']-0x1]++,_0x5cf989[_0x613e8e]['nextPosition']=_0x2fe856['createPositionFromPath'](_0x3a642f,_0x18202b)):(_0x5cf989[_0x613e8e]['previousPosition']=_0x2fe856['createPositionFromPath'](_0x3a642f,_0x18202b),_0x41afa0?_0x41afa0['_data']+=_0x5cf989[_0x613e8e]['item']['data']:_0x41afa0=new _0x541a0c(_0x5cf989[_0x613e8e]['item']['data'],_0x5cf989[_0x613e8e]['item']['getAttributes']()),_0x5cf989[_0x613e8e+0x1]&&'text'===_0x5cf989[_0x613e8e+0x1]['type']&&_0xa4322f(_0x41afa0,_0x5cf989[_0x613e8e+0x1]['item'])||(_0x35e7ee[0x0]['_appendChild'](_0x41afa0),_0x41afa0=null),_0x18202b[_0x18202b['length']-0x1]+=_0x5cf989[_0x613e8e]['item']['offsetSize'],_0x5cf989[_0x613e8e]['nextPosition']=_0x2fe856['createPositionFromPath'](_0x3a642f,_0x18202b));for(let _0x1d83a7=0x0;_0x1d83a7<_0x5cf989['length'];_0x1d83a7++){const _0x5b1720=_0x5cf989[_0x1d83a7]['previousPosition'],_0x14e620=_0x5cf989[_0x1d83a7]['nextPosition'];for(const _0x3a91a5 of _0x5cf989[_0x1d83a7]['markersStart'])_0x55db90['set'](_0x3a91a5,{'start':_0x5b1720,'end':null});_0x428baf('isRemoveSuggestion',_0x1d83a7,_0x5b1720,_0x14e620),_0x428baf('isAddSuggestion',_0x1d83a7,_0x5b1720,_0x14e620),_0x428baf('isRemoved',_0x1d83a7,_0x5b1720,_0x14e620),_0x428baf('isAdded',_0x1d83a7,_0x5b1720,_0x14e620);for(const _0x5ae9bd of _0x5cf989[_0x1d83a7]['markersEnd']){const _0x1518d6=_0x55db90['get'](_0x5ae9bd);_0x1518d6?_0x1518d6['end']=_0x14e620:_0x55db90['set'](_0x5ae9bd,{'start':_0x14e620,'end':_0x14e620});}}for(const [_0x1e06e0,_0x3007a2]of _0x55db90){const _0x368f59=this['editor']['model']['createRange'](_0x3007a2['start'],_0x3007a2['end']);_0x3a642f['markers']['set'](_0x1e06e0,_0x368f59);}return _0x22dbc1['sort']((_0x22fc17,_0x11fbdf)=>{const _0x5c0529=_0x3a642f['markers']['get']('revision:'+_0x22fc17['id']),_0x56ca2d=_0x3a642f['markers']['get']('revision:'+_0x11fbdf['id']);return _0x5c0529['start']['isBefore'](_0x56ca2d['start'])?-0x1:_0x5c0529['start']['isAfter'](_0x56ca2d['start'])?0x1:_0x5c0529['end']['isBefore'](_0x56ca2d['end'])?-0x1:_0x5c0529['end']['isAfter'](_0x56ca2d['end'])?0x1:'add'===_0x22fc17['type']?-0x1:0x1;}),{'root':_0x3a642f,'changes':_0x22dbc1};function _0x428baf(_0x394085,_0x289711,_0x89fd71,_0x15f296){const _0x1e9d2b=!!_0x5cf989[_0x289711][_0x394085],_0x305eb0=_0x1e9d2b?_0x5cf989[_0x289711][_0x394085]['userId']:null,_0x9e678a=_0x289711===_0x5cf989['length']-0x1,_0x771ef3=_0x51f6ca[_0x394085][0x0],_0x563f2a=_0x5bc52a['isObject'](_0x5cf989[_0x289711]['item']);!_0x42c861[_0x394085]&&_0x1e9d2b?_0x42c861[_0x394085]={'start':_0x89fd71,'tapeItem':_0x5cf989[_0x289711],'userId':_0x305eb0,'type':_0x394085}:_0x42c861[_0x394085]&&!_0x1e9d2b?(_0x42c861[_0x394085]['end']=_0x89fd71,_0x11004e(_0x42c861[_0x394085]),_0x42c861[_0x394085]=null):_0x42c861[_0x394085]&&_0x1e9d2b&&_0x42c861[_0x394085]['userId']!==_0x305eb0&&(_0x42c861[_0x394085]['end']=_0x89fd71,_0x771ef3&&_0x771ef3['userId']===_0x42c861[_0x394085]['userId']||_0x11004e(_0x42c861[_0x394085]),_0x42c861[_0x394085]={'start':_0x89fd71,'tapeItem':_0x5cf989[_0x289711],'userId':_0x305eb0,'type':_0x394085}),_0x42c861[_0x394085]&&_0x563f2a&&('elementStart'!==_0x5cf989[_0x289711]['type']||_0x771ef3&&_0x771ef3['userId']===_0x305eb0||_0x51f6ca[_0x394085]['unshift']({'userId':_0x305eb0,'object':_0x5cf989[_0x289711]['item'],'change':_0x42c861[_0x394085]}),'elementEnd'===_0x5cf989[_0x289711]['type']&&_0x771ef3&&_0x771ef3['object']===_0x5cf989[_0x289711]['item']&&(_0x51f6ca[_0x394085]['shift'](),_0x42c861[_0x394085]=_0x771ef3['change'])),_0x42c861[_0x394085]&&_0x9e678a&&(_0x42c861[_0x394085]['end']=_0x15f296,_0x11004e(_0x42c861[_0x394085]),_0x42c861[_0x394085]=null);}function _0x11004e({start:_0x291db8,end:_0x3d1855,tapeItem:_0x4738bf,userId:_0xbd3e81,type:_0x2462f4}){const _0x22a9e6=_0x4738bf['item'],_0x152e0a=_0x2fe856['schema']['isBlock'](_0x22a9e6)&&!_0x2fe856['schema']['isLimit'](_0x22a9e6),_0x5eaff3=_0x291db8['nodeAfter']==_0x3d1855['parent']&&_0x3d1855['isAtStart'];if(_0x152e0a&&_0x5eaff3)return;const _0x4665cc=_0x2fe856['createRange'](_0x291db8,_0x3d1855),_0x3eafdf=_0x10dbc6['get'](_0xbd3e81),_0x21eb71=new ChangeItem({'author':_0x3eafdf,'type':'isAdded'==_0x2462f4||'isAddSuggestion'==_0x2462f4?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x2462f4||'isRemoveSuggestion'==_0x2462f4},'createdAt':new Date(),'rootName':_0xb82977});_0x22dbc1['push'](_0x21eb71),_0x3a642f['markers']['set']('revision:'+_0x21eb71['id'],_0x4665cc);}function _0xa4322f(_0x34ae19,_0x5c8fbc){const _0x49cab5=_0x34ae19['getAttributes'](),_0x5bf926=_0x5c8fbc['getAttributes']();for(const _0x4ea65b of _0x49cab5){if(_0x4ea65b[0x1]!==_0x5c8fbc['getAttribute'](_0x4ea65b[0x0]))return!0x1;_0x5bf926['next']();}return _0x5bf926['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x1df0c2=>{const _0x2da276=_0x1df0c2['markerName']['split'](':')[0x1],_0x500234=this['_getChangeFromId'](_0x2da276);if(!_0x500234)return null;const _0x2c12dd='add'==_0x500234['type']?'insertion':'deletion',_0x1c031b=['ck-suggestion-marker','ck-suggestion-marker-'+_0x2c12dd];return _0x500234['data']['isSuggestion']&&_0x1c031b['push']('ck-suggestion-marker-'+_0x2c12dd+'-new'),this['activeChange']==_0x500234&&_0x1c031b['push']('ck-suggestion-marker--active'),{'classes':_0x1c031b,'attributes':{'data-change-id':_0x2da276}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x5db322=>{_0x5db322['on']('element:pre',(_0x293a01,_0x512aff,_0x2795c4)=>{const _0x56964c=_0x512aff['viewItem']['getChild'](0x0);if(!_0x56964c||!_0x56964c['is']('element','code'))return;if(!_0x2795c4['consumable']['consume'](_0x56964c,{'attributes':['vid_start','vid_end']}))return;const _0x2dba06=_0x512aff['modelRange']['start']['nodeAfter'];_0x2795c4['writer']['setAttribute']('vid_start',_0x56964c['getAttribute']('vid_start'),_0x2dba06),_0x2795c4['writer']['setAttribute']('vid_end',_0x56964c['getAttribute']('vid_end'),_0x2dba06);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x56fab3=>{_0x56fab3['on']('element',(_0x4d6bbd,_0x36d41b,_0xe7c806)=>{if(!_0xe7c806['consumable']['consume'](_0x36d41b['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x36d41b['modelRange']['isCollapsed'])return;const _0x53b46f=_0x36d41b['modelRange']['start']['nodeAfter'];_0x53b46f['hasAttribute']('vid_start')||_0x53b46f['hasAttribute']('vid')||(_0xe7c806['writer']['setAttribute']('vid_start',_0x36d41b['viewItem']['getAttribute']('vid_start'),_0x53b46f),_0xe7c806['writer']['setAttribute']('vid_end',_0x36d41b['viewItem']['getAttribute']('vid_end'),_0x53b46f));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x450c69=>_0x450c69['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x33d2db,[,_0x468f3f])=>{['vid_start','vid_end','vid']['includes'](_0x468f3f)&&(_0x33d2db['return']=!0x0,_0x33d2db['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x46aa7b=>{_0x46aa7b['on']('attribute:vid',(_0x17ab2f,_0x1cf3a,_0x1c6542)=>{if('\x20'!=_0x1cf3a['item']['data']||_0x1cf3a['item']['parent']['maxOffset']>0x1)return;if(!_0x1c6542['consumable']['consume'](_0x1cf3a['item'],_0x17ab2f['name']))return;const _0x49c293=_0x1c6542['writer'],_0x18728a=_0x1c6542['mapper']['toViewRange'](_0x1cf3a['range']);_0x49c293['wrap'](_0x18728a,_0x49c293['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x350473){const _0x355d02=_0x350473['plugins']['get']('RevisionViewer');return(_0x47fb47,_0x49d8c2,_0x5e026d)=>{const _0x312bee=_0x49d8c2['markerName']['split'](':')[0x1],_0x459b29=_0x355d02['_getChangeFromId'](_0x312bee);if(!_0x459b29)return null;const _0x4044e9='add'==_0x459b29['type']?'split':'merge';if(!_0x5e026d['consumable']['test'](_0x49d8c2['markerRange'],_0x47fb47['name']))return;const _0x2a373f=_0x49d8c2['markerRange']['getWalker'](),_0x384a4f=_0x49d8c2['markerRange']['start'],_0x29144a=_0x350473['model']['schema'];let _0x2fabdb=null,_0x532d26=null,_0x39aac5=!0x1,_0x29f8a0=!0x1;for(const _0x5c8334 of _0x2a373f){const _0x3de85b=_0x5c8334['item'];_0x39aac5=_0x39aac5||_0x29144a['isContent'](_0x3de85b);const _0x25ea8c=_0x5e026d['mapper']['toViewElement'](_0x3de85b);if(_0x25ea8c&&_0x25ea8c['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x5c8334['type']&&(_0x29144a['isBlock'](_0x3de85b)&&!_0x29144a['isLimit'](_0x3de85b)&&(_0x3de85b['nextSibling']||_0x384a4f['isAtEnd']?_0x2fabdb&&_0x2fabdb['parent']==_0x3de85b||(_0x2fabdb=_0x3de85b,_0x296dbf(_0x5c8334['previousPosition']),_0x29f8a0=!0x0):_0x532d26=_0x532d26||_0x5c8334['previousPosition']));}function _0x296dbf(_0x176ca7){const _0x30f73d=_0x5e026d['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x4044e9}),_0x37f051=_0x5e026d['mapper']['toViewPosition'](_0x176ca7);_0x459b29['data']['isSuggestion']&&_0x5e026d['writer']['addClass']('ck-suggestion-marker-'+_0x4044e9+'-new',_0x30f73d),_0x355d02['activeChange']==_0x459b29&&_0x5e026d['writer']['addClass']('ck-suggestion-marker--active',_0x30f73d),_0x5e026d['writer']['insert'](_0x37f051,_0x30f73d),_0x5e026d['mapper']['bindElementToMarker'](_0x30f73d,_0x49d8c2['markerName']);}_0x39aac5||_0x29f8a0||!_0x532d26||_0x296dbf(_0x532d26);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x195c72,_0xbec0cd,_0xa37980)=>{const _0x2ef848=_0xa37980['mapper']['markerNameToElements'](_0xbec0cd['markerName']);if(_0x2ef848){for(const _0x583791 of _0x2ef848)(_0x583791['hasClass']('ck-suggestion-marker-split')||_0x583791['hasClass']('ck-suggestion-marker-merge'))&&(_0xa37980['mapper']['unbindElementFromMarkerName'](_0x583791,_0xbec0cd['markerName']),_0xa37980['writer']['remove'](_0x583791));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x4c3bdd,_0x209e19,_0x28452b)=>{const _0x1f8c51=_0x209e19['markerName']['split'](':')[0x1],_0x10f390=this['_getChangeFromId'](_0x1f8c51);if(!_0x10f390)return null;const _0x38f89f='add'==_0x10f390['type']?'split':'merge';if(_0x28452b['consumable']['test'](_0x209e19['markerRange'],_0x4c3bdd['name']))for(const _0x84ef9d of _0x209e19['markerRange']['getItems']()){if(!_0x84ef9d['is']('element','softBreak'))continue;const _0x4e8f98=_0x28452b['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x38f89f}),_0x1f068a=_0x28452b['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x84ef9d));_0x10f390['data']['isSuggestion']&&_0x28452b['writer']['addClass']('ck-suggestion-marker-'+_0x38f89f+'-new',_0x4e8f98),this['activeChange']==_0x10f390&&_0x28452b['writer']['addClass']('ck-suggestion-marker--active',_0x4e8f98),_0x28452b['writer']['insert'](_0x1f068a,_0x4e8f98),_0x28452b['mapper']['bindElementToMarker'](_0x4e8f98,_0x209e19['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x3daa09=>{for(const _0x26fc04 of this['editor']['model']['document']['getRootNames']()){const _0x49c852=this['editor']['model']['document']['getRoot'](_0x26fc04),_0x427526=this['editor']['editing']['view']['document']['getRoot'](_0x26fc04);if(_0x427526){const _0x1cce40=_0x49c852['getAttribute']('revisionHistoryAttachChange');if(_0x3daa09['removeAttribute']('data-change-id',_0x427526),_0x3daa09['removeClass']('ck-revision-history-root-add',_0x427526),_0x3daa09['removeClass']('ck-revision-history-root-remove',_0x427526),_0x3daa09['removeClass']('ck-revision-history-root--active',_0x427526),_0x1cce40){const _0x194987=this['_getChangeFromId'](_0x1cce40);if(!_0x194987)return null;_0x3daa09['setAttribute']('data-change-id',_0x1cce40,_0x427526),_0x3daa09['addClass']('ck-revision-history-root-'+_0x194987['type'],_0x427526),this['activeChange']==_0x194987&&_0x3daa09['addClass']('ck-revision-history-root--active',_0x427526);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x44f1d0=>'revision-comment:'+_0x44f1d0,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x1e6cee=>'revision-suggestion:'+_0x1e6cee,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x5de848=>({'name':'suggestion:'+_0x5de848,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x3f4b5e=>{const _0x24fe3c=_0x3f4b5e['markerName']['split'](':')[0x1];return'insertion'!=_0x24fe3c&&'deletion'!=_0x24fe3c?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x24fe3c]};}}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:deletion',_t(this['editor'],'merge'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:insertion',_t(this['editor'],'split'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision-suggestion',(_0x539f5f,_0xeee255,_0x2f1ab3)=>{const _0x22e44=_0x2f1ab3['mapper']['markerNameToElements'](_0xeee255['markerName']);if(_0x22e44){for(const _0x4826a4 of _0x22e44)_0x4826a4['is']('uiElement')&&(_0x2f1ab3['mapper']['unbindElementFromMarkerName'](_0x4826a4,_0xeee255['markerName']),_0x2f1ab3['writer']['remove'](_0x4826a4));}},{'priority':'high'});}['_getChangeFromId'](_0x49337d){return this['_changeIdToChange']['get'](_0x49337d);}['_getViewForChange'](_0x2e3748){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new ChangeDetailsView(this['editor']['locale'],_0x2e3748),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x25c0e7,_0x2c294c,_0x2d1153,_0x3fed35)=>{_0x3fed35&&this['_balloon']['remove'](_0x3fed35),_0x2d1153&&(this['_balloon']['add']({'view':_0x2d1153,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x517c89=this['editor']['editing'],_0x2bc9bf=this['_getChangeFromId'](_0x2d1153['changeId']);let _0x1bbcc5;if(_0x2bc9bf['data']['isOnRoot']){const _0x1b9559=_0x517c89['view']['getDomRoot'](_0x2bc9bf['rootName']);_0x1bbcc5=Array['from'](_0x1b9559['getClientRects']());}else{const _0x8320a=this['editor']['model']['markers']['get']('revision:'+_0x2d1153['changeId']);_0x1bbcc5=Array['from'](_0x517c89['mapper']['markerNameToElements'](_0x8320a['name']))['map'](_0x5f1005=>_0x517c89['view']['domConverter']['mapViewToDom'](_0x5f1005))['map'](_0x2361aa=>Array['from'](_0x2361aa['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x1bbcc5[0x0];return _0x1bbcc5['find'](_0x1b17be=>_0x1b17be['top']-0x3<=this['_activeViewTarget']['y']&&_0x1b17be['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x1b17be['left']-0x3<=this['_activeViewTarget']['x']&&_0x1b17be['right']+0x3>=this['_activeViewTarget']['x'])||_0x1bbcc5[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x49ca26,_0x9b92ee,_0x1c0f55,_0x4f5920)=>{this['activeView']=_0x1c0f55?this['_getViewForChange'](_0x1c0f55):null,this['editor']['model']['change'](()=>{const _0x27ec47=this['editor']['editing'];_0x4f5920&&(_0x4f5920['data']['isOnRoot']?_0x27ec47['view']['change'](_0x219414=>{_0x219414['removeClass']('ck-revision-history-root--active',_0x27ec47['view']['document']['getRoot'](_0x4f5920['rootName']));}):_0x27ec47['reconvertMarker']('revision:'+_0x4f5920['id'])),_0x1c0f55&&(_0x1c0f55['data']['isOnRoot']?_0x27ec47['view']['change'](_0x3b0d27=>{_0x3b0d27['addClass']('ck-revision-history-root--active',_0x27ec47['view']['document']['getRoot'](_0x1c0f55['rootName']));}):_0x27ec47['reconvertMarker']('revision:'+_0x1c0f55['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x13e2b1,_0x594ecd)=>{if(this['activeChange'])return;const _0x3a9d1c=this['_findChangeIdFromDomTarget'](_0x594ecd['target']),_0x533a79=this['_changeIdToChange']['get'](_0x3a9d1c);_0x533a79?(this['_activeViewTarget']={'x':_0x594ecd['domEvent']['x'],'y':_0x594ecd['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x533a79)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x34ae5a,_0x24159b)=>{const _0x90d49c=this['_findChangeIdFromDomTarget'](_0x24159b['target']),_0x309ce0=this['_changeIdToChange']['get'](_0x90d49c);_0x309ce0?(this['_activeViewTarget']={'x':_0x24159b['domEvent']['x'],'y':_0x24159b['domEvent']['y']},_0x309ce0===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x309ce0):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x44f9e1){do{const _0x3232fb=_0x44f9e1['getAttribute']('data-change-id');if(_0x3232fb)return _0x3232fb;_0x44f9e1=_0x44f9e1['parent'];}while(_0x44f9e1);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x5d46ea=>{for(const _0x266c2e of this['editor']['model']['markers'])_0x5d46ea['removeMarker'](_0x266c2e);});}}function _t(_0x20f379,_0x49fb84){return(_0x2a0cc8,_0x45e825,_0x147be9)=>{if(!_0x147be9['consumable']['test'](_0x45e825['markerRange'],_0x2a0cc8['name']))return;const _0xb1e4c0=_0x45e825['markerRange']['getWalker'](),_0x4af739=_0x45e825['markerRange']['start'],_0x202cee=_0x20f379['model']['schema'];let _0x31c0a0=null,_0x4331f9=null,_0x3f36d5=!0x1,_0x5a695f=!0x1;for(const _0x6ad58c of _0xb1e4c0){const _0x37dafa=_0x6ad58c['item'];_0x3f36d5=_0x3f36d5||_0x202cee['isContent'](_0x37dafa);const _0x4b993e=_0x147be9['mapper']['toViewElement'](_0x37dafa);if(_0x4b993e&&_0x4b993e['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x6ad58c['type']&&(_0x202cee['isBlock'](_0x37dafa)&&!_0x202cee['isLimit'](_0x37dafa)&&(_0x37dafa['nextSibling']||_0x4af739['isAtEnd']?_0x31c0a0&&_0x31c0a0['parent']==_0x37dafa||(_0x31c0a0=_0x37dafa,_0x94cf98(_0x6ad58c['previousPosition']),_0x5a695f=!0x0):_0x4331f9=_0x4331f9||_0x6ad58c['previousPosition']));}function _0x94cf98(_0xf7ea09){const _0x16ccf7=_0x147be9['mapper']['toViewPosition'](_0xf7ea09),_0xe74a0e=_0x147be9['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x49fb84});_0x147be9['writer']['insert'](_0x16ccf7,_0xe74a0e),_0x147be9['mapper']['bindElementToMarker'](_0xe74a0e,_0x45e825['markerName']);}_0x3f36d5||_0x5a695f||!_0x4331f9||_0x94cf98(_0x4331f9);};}class RestoreRevisionCommand extends _0x25b174{constructor(_0x2ceef1){super(_0x2ceef1);const _0x5042f3=_0x2ceef1['plugins']['get'](RevisionViewer);this['affectsData']=!0x1,this['listenTo'](_0x5042f3,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x5042f3,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x3c14eb=this['editor'],_0x3042ca=_0x3c14eb['plugins']['get'](RevisionViewer),_0x3c0f47=_0x3042ca['isReady']?_0x3042ca['diff']['newRevisionId']:null;_0x3c14eb['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x3c0f47);}['refresh'](){const {isReady:_0x54f185,isEnabled:_0x335832,repository:_0x169616,diff:_0x349c49}=this['editor']['plugins']['get'](RevisionViewer),_0x3714d6=_0x349c49&&_0x169616['getLaterVisibleRevision'](_0x349c49['newRevisionId']);this['isEnabled']=_0x54f185&&_0x335832&&Boolean(_0x3714d6);}}class ShowChangeCommand extends _0x25b174{['_step'];constructor(_0x3af8c5,{direction:_0x33af63}){super(_0x3af8c5);const _0x32e421=_0x3af8c5['plugins']['get'](RevisionViewer);this['affectsData']=!0x1,this['_step']='forward'===_0x33af63?0x1:-0x1,this['listenTo'](_0x32e421,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x32e421,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x32e421,'change:activeChange',()=>this['refresh']());}['execute'](){const _0xd0f723=this['editor'],_0xfd4d1d=_0xd0f723['plugins']['get'](RevisionViewer),{isNavigationMode:_0x52a1e2,currentChangeNumber:_0x2bebaf}=_0xfd4d1d;let _0x4d58f5;if(_0xfd4d1d['activeChange']=_0x52a1e2?_0xfd4d1d['diff']['changes']['get'](_0x2bebaf+this['_step']):_0xfd4d1d['diff']['changes']['first'],_0xfd4d1d['activeChange']['data']['isOnRoot'])_0x4d58f5=_0xd0f723['editing']['view']['getDomRoot'](_0xfd4d1d['activeChange']['rootName']);else{const _0x4901d4=_0xd0f723['model']['markers']['get']('revision:'+_0xfd4d1d['activeChange']['id']);_0x4d58f5=_0x1d3e7d(_0xd0f723['editing'],_0x4901d4);}_0x17cc9f({'target':_0x4d58f5,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x2a5277,currentChangeNumber:_0xaacaba,numberOfChanges:_0x5ed73a,isReady:_0xeee4da,isEnabled:_0x589d54}=this['editor']['plugins']['get'](RevisionViewer);this['isEnabled']=!!(_0x589d54&&_0xeee4da&&_0x5ed73a)&&(!_0x2a5277||(0x1===this['_step']?_0xaacaba<_0x5ed73a-0x1:_0xaacaba>0x0));}}class ChangesNavigationView extends _0x39c569{constructor(_0x41985a){super(_0x41985a);const _0x10493d=this['bindTemplate'],_0x676904=new _0x3296a8(_0x41985a),_0x4628ea=new _0x3296a8(_0x41985a);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',(_0x1178b8,_0x33f0f7)=>_0x1178b8&&_0x33f0f7>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x23aedf,_0x2190f9,_0x4ce21,_0x1282e6)=>{if(!_0x23aedf)return ft(_0x41985a,'Loading...');if(!_0x4ce21)return ft(_0x41985a,'No\x20changes');const _0x485767=ft(_0x41985a,'NUMBER_OF_CHANGES',_0x4ce21);return _0x1282e6?ft(_0x41985a,'X_OF_Y_CHANGES',[_0x2190f9+0x1,_0x4ce21]):_0x485767;}),_0x676904['set']({'label':ft(_0x41985a,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x396732}),_0x4628ea['set']({'label':ft(_0x41985a,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x3e48c0}),_0x676904['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x4628ea['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x676904['on']('execute',()=>this['fire']('execute','backward')),_0x4628ea['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',_0x10493d['if']('_isStatusLabelVisible','ck-hidden',_0x11a2f4=>!_0x11a2f4)]},'children':[{'text':_0x10493d['to']('isNavigationMode',_0x59125b=>_0x59125b?ft(_0x41985a,'EDIT_X_OF_Y_REVISIONS')+':\x20':ft(_0x41985a,'Total')+':\x20')}]},{'text':_0x10493d['to']('_statusText')}]},new st(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x676904,_0x4628ea]}]});}}const yt='ck-editor__editable__loading-overlay';class RevisionViewerLoadingOverlay extends _0x18ed42{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x7b27b2=this['editor']['editing']['view'];_0x7b27b2['change'](_0x2a22c3=>{for(const _0x335436 of _0x7b27b2['document']['roots'])_0x2a22c3['addClass'](yt,_0x335436);});}['hide'](){const _0x2c73be=this['editor']['editing']['view'];_0x2c73be['change'](_0x34fe94=>{for(const _0x909e70 of _0x2c73be['document']['roots'])_0x34fe94['removeClass'](yt,_0x909e70);});}}class RevisionViewerUI extends _0x18ed42{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[RevisionViewer,RevisionViewerLoadingOverlay];}['init'](){const _0x5359e4=this['editor'],_0xbcbed4=_0x5359e4['plugins']['get'](RevisionViewer),_0x4ab7f7=_0x5359e4['plugins']['get'](RevisionViewerLoadingOverlay);_0x5359e4['ui']['componentFactory']['add']('exitToEditing',_0x5be2cc=>{const _0x3c5469=new _0x3296a8(_0x5be2cc);return _0x3c5469['set']({'label':ft(_0x5be2cc,'Back\x20to\x20editing'),'icon':_0x54f965,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x3c5469,'execute',()=>{_0x5359e4['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x3c5469;}),_0x5359e4['ui']['componentFactory']['add']('restoreRevision',_0x8168d8=>{const _0x200fc5=new _0x3296a8(_0x8168d8);return _0x200fc5['set']({'label':ft(_0x8168d8,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x200fc5['bind']('isEnabled')['to'](_0x5359e4['commands']['get']('restoreRevision')),this['listenTo'](_0x200fc5,'execute',()=>_0x5359e4['execute']('restoreRevision')),_0x200fc5;}),_0x5359e4['ui']['componentFactory']['add']('changesNavigation',_0x3af795=>{const _0x397e0e=new ChangesNavigationView(_0x3af795),_0x29cdc8=_0x5359e4['commands']['get']('showPreviousChange'),_0x469fd8=_0x5359e4['commands']['get']('showNextChange');return _0x397e0e['bind']('isBackwardNavigationEnabled')['to'](_0x29cdc8,'isEnabled'),_0x397e0e['bind']('isForwardNavigationEnabled')['to'](_0x469fd8,'isEnabled'),_0x397e0e['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0xbcbed4),this['listenTo'](_0x397e0e,'execute',(_0xb39fff,_0x436b09)=>{_0x5359e4['execute']('forward'===_0x436b09?'showNextChange':'showPreviousChange');}),_0x397e0e;}),_0x4ab7f7['show'](),_0xbcbed4['on']('change:isReady',(_0x405a94,_0x42b432,_0xa1548f)=>{_0xa1548f?_0x4ab7f7['hide']():_0x4ab7f7['show']();});}}class RevisionNameView extends _0x321730{['_resizeObserver']=null;constructor(_0x3fb0b6,_0x183fd3){super(_0x3fb0b6,_0x183fd3);const _0x11a72b=this['bindTemplate'];this['set']({'label':ft(_0x3fb0b6,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=ft(_0x3fb0b6,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x11a72b['to']('_tooltipString'),'data-cke-tooltip-position':'s','data-cke-tooltip-class':'ck-tooltip_multi-line'}});}['render'](){super['render'](),this['_resizeObserver']=new _0x122c77(this['fieldView']['element'],()=>this['_updateTooltipText']()),this['listenTo'](this['fieldView'],'input',()=>this['_updateTooltipText']());}['destroy'](){super['destroy'](),this['_resizeObserver']&&this['_resizeObserver']['destroy']();}['_updateTooltipText'](){const _0x4aa743=this['fieldView']['element'];this['_tooltipString']=_0x4aa743['scrollWidth']>_0x4aa743['clientWidth']&&_0x4aa743['value']||'';}}class RevisionAuthorView extends _0x39c569{constructor(_0x2adec2,_0x1f92d0,_0x16f381){super(_0x2adec2);const _0x504b35=new nt();_0x504b35['set']({'content':_0x580980,'viewBox':'0\x200\x2011\x2010'});const _0x67855b=['ck','ck-revision-history-sidebar__revision-author'];_0x16f381&&_0x67855b['push']('ck-revision-history-sidebar__revision-author_creator');const _0x37e601=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':ft(_0x2adec2,_0x16f381?'Revision\x20creator':'Revision\x20author')},'children':[_0x504b35,_0x1f92d0['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x67855b},'children':_0x37e601});}}function Rt(_0x3d0644,_0x504ce0){const _0x1575ee=_0x3d0644['bindTemplate'],_0x579887=_0x3d0644['locale'],_0x5c70de=_0x38d1cc(_0x579887);_0x5c70de['panelPosition']='sw';const _0x1c7dbf=function(_0x4f8f7f,_0x327cb2){const _0x1614c5=function(_0x25e52a,_0x4eab0f){const _0x37432e=_0x25e52a['locale'],_0x3a5851={'Compare\x20against\x20selected':ft(_0x37432e,'Compare\x20against\x20selected'),'Name\x20this\x20revision':ft(_0x37432e,'Name\x20this\x20revision'),'Restore\x20this\x20revision':ft(_0x37432e,'Restore\x20this\x20revision')};return _0x4eab0f['map'](_0x5a5cb0=>{const _0x327f06=_0x3a5851[_0x5a5cb0['name']];return _0x327f06&&_0x327f06!==_0x5a5cb0['name']&&(_0x5a5cb0['name']=_0x327f06),_0x5a5cb0;});}(_0x4f8f7f,_0x327cb2),_0x395fdd=new _0x12a0e4();for(const _0x2c4ca4 of _0x1614c5){const _0x444e09={'type':'button','model':new rt({'label':_0x2c4ca4['name'],'class':_0x2c4ca4['class'],'withText':!0x0,'role':'menuitem','_action':_0x2c4ca4['action']})};_0x444e09['model']['bind']('isEnabled')['to'](_0x4f8f7f,'isActionsDropdownOpen',_0x1011cc=>'function'!=typeof _0x2c4ca4['isEnabled']||(!_0x1011cc||_0x2c4ca4['isEnabled'](_0x4f8f7f))),_0x395fdd['add'](_0x444e09);}return _0x395fdd;}(_0x3d0644,_0x504ce0);return _0x3d0644['bind']('isActionsDropdownOpen')['to'](_0x5c70de,'isOpen'),_0x5c70de['buttonView']['set']({'label':ft(_0x579887,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x131dec}),_0x5c70de['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x1575ee['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x1575ee['to'](_0x3486c1=>_0x3486c1['stopPropagation']())}}),_0x5c70de['on']('execute',_0x54b071=>{_0x3d0644['isReady']&&'function'==typeof _0x54b071['source']['_action']&&_0x54b071['source']['_action'](_0x3d0644);}),ot(_0x5c70de,_0x1c7dbf,{'role':'menu'}),_0x5c70de['listenTo'](_0x3d0644,'change:isActionsDropdownOpen',(_0x256db9,_0x295fbd,_0x41ab84)=>{if(_0x41ab84)for(const _0x4f15e5 of _0x5c70de['listView']['items']){const _0x40f0c3=_0x4f15e5['children']['first'],_0x573e8c=_0x504ce0['find'](_0x35d6ac=>_0x35d6ac['action']===_0x40f0c3['_action'])['isVisible'];_0x4f15e5['isVisible']=void 0x0===_0x573e8c||_0x573e8c(_0x3d0644);}}),_0x5c70de;}class RevisionView extends/* #__PURE__ -- @preserve */
|
|
27
|
-
|
|
23
|
+
import{ObservableMixin as _0xf684e0,uid as _0x51ceb2,Collection as _0x3625c9,logWarning as _0x1b67c3,FocusTracker as _0x28ca2c,KeystrokeHandler as _0x2f638f,scrollViewportToShowTarget as _0x4fee1d,ResizeObserver as _0x39f055,ElementReplacer as _0x4acda2,CKEditorError as _0x423177}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x8c5550,set as _0x49f456,unset as _0x1ca3fa,isEqual as _0x5af7ec}from'es-toolkit/compat';import{Plugin as _0x538071,PendingActions as _0x3985ee,Command as _0x3dad1f,ElementApiMixin as _0x26f772,Editor as _0x278490}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x2baa1d,getMarkerDomElement as _0x205b94,ConfirmMixin as _0x1f967d,sanitizeEditorConfig as _0x21c68e}from'@ckeditor/ckeditor5-collaboration-core/dist/index.js';import{ViewContainerElement as _0x20af03,ViewAttributeElement as _0x4babb5,ViewEmptyElement as _0x4ed8f7,ViewRawElement as _0x4e0b8b,ViewUIElement as _0x103961,ViewDocumentFragment as _0x862c9,ViewText as _0x460563,ViewElement as _0x2c71cb,ModelElement as _0x46d26f,ModelRange as _0xa8802c,ModelPosition as _0x10f6fa,ModelDocumentFragment as _0x59fcbe,ModelText as _0x3b5bf9}from'@ckeditor/ckeditor5-engine/dist/index.js';import{IconHistory as _0x5ea9e8,IconChevronUp as _0x37d115,IconChevronDown as _0x27b0d7,IconUndo as _0x2c0af7,IconUser as _0x185391,IconThreeVerticalDots as _0x5379e9}from'@ckeditor/ckeditor5-icons/dist/index.js';import{CssTransitionDisablerMixin as _0x151f05,View as _0xafec90,submitHandler as _0x33eb0a,LabeledFieldView as _0x17e56b,createLabeledInputText as _0x238b41,createDropdown as _0x182132,ListView as _0x44c12a,ListItemView as _0x4582a8,ButtonView as _0x135801,MenuBarMenuView as _0x48deab,MenuBarMenuListView as _0x41b7d1,MenuBarMenuListItemView as tt,MenuBarMenuListItemButtonView as it,ContextualBalloon as et,ToolbarSeparatorView as st,IconView as nt,addListToDropdown as ot,UIModel as rt,EditorUI as at,normalizeToolbarConfig as ht,BoxedEditorUIView as ct,StickyPanelView as lt,ToolbarView as ut,InlineEditableUIView as dt}from'@ckeditor/ckeditor5-ui/dist/index.js';import{DateTime as vt}from'luxon';class Revision extends/* #__PURE__ -- @preserve */
|
|
24
|
+
_0xf684e0(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0xbcc8a2){super(),this['id']=_0xbcc8a2['id']||_0x51ceb2(),this['creator']=_0xbcc8a2['creator']||null,this['authors']=_0xbcc8a2['authors']||[],this['diffData']=_0xbcc8a2['diffData']||null,this['toVersion']=_0xbcc8a2['toVersion']||0x0,this['fromVersion']=_0xbcc8a2['fromVersion']||0x0,this['set']('name',_0xbcc8a2['name']||''),this['set']('createdAt',_0xbcc8a2['createdAt']||new Date()),this['set']('attributes',_0xbcc8a2['attributes']||{});}['setName'](_0x150791){this['_update']({'name':_0x150791});}['setAttribute'](_0x56add3,_0x2547a0){const _0xc5668c=_0x8c5550(this['attributes']);_0x49f456(_0xc5668c,_0x56add3,_0x2547a0),this['_update']({'attributes':_0xc5668c});}['removeAttribute'](_0xe43243){const _0x4e080b=_0x8c5550(this['attributes']);_0x1ca3fa(_0x4e080b,_0xe43243),this['_update']({'attributes':_0x4e080b});}['_update'](_0x32e4e1,_0x2f35a3=!0x1){let _0x3aa059=!0x1;const _0x1da0e1={'id':this['id']},_0x196ba5=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x3e1c76 of _0x196ba5){const _0x39fd51=_0x32e4e1[_0x3e1c76];void 0x0!==_0x39fd51&&_0x39fd51!==this[_0x3e1c76]&&(this[_0x3e1c76]=_0x39fd51,_0x1da0e1[_0x3e1c76]=_0x39fd51,_0x3aa059=!0x0);}_0x3aa059&&(_0x1da0e1['authors']&&(_0x1da0e1['authorsIds']=_0x1da0e1['authors']['map'](_0x583edd=>_0x583edd['id']),delete _0x1da0e1['authors']),this['fire']('_update',_0x1da0e1,_0x2f35a3));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x141b53=>_0x141b53['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class RevisionsRepository extends _0x538071{['_revisions'];static get['requires'](){return[_0x2baa1d];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x2699be){super(_0x2699be),this['_revisions']=new _0x3625c9();}['afterInit'](){!async function(_0x3bb343){const _0x24b7ef=_0x498e7a([0x76,0x73,0x6d,0x4c,0x34,0x54,0x50,0x70,0x75,0x52,0x35,0x33,0x4d,0x6c,0x71,0x53,0x6a,0x32,0x56,0x58,0x77,0x48,0x39,0x6f,0x45,0x41,0x4e,0x38,0x46,0x78,0x4a,0x74,0x47,0x55,0x4f,0x64,0x62,0x44,0x43,0x5a,0x30,0x31,0x69,0x68,0x79,0x66,0x6b,0x42,0x51,0x59,0x36,0x61,0x63,0x67,0x7a,0x37,0x72,0x49,0x65,0x57,0x4b,0x6e]),_0x386ccc=0xeb829,_0x271916=0x359e09b0,_0x56ab77=0x35998260^_0x271916,_0x469276=window[_0x498e7a([0x44,0x61,0x74,0x65])][_0x498e7a([0x6e,0x6f,0x77])](),_0x22c383=_0x3bb343[_0x498e7a([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x1dc45d=new window[(_0x498e7a([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x5ca87b=>{_0x22c383[_0x498e7a([0x6f,0x6e,0x63,0x65])](_0x498e7a([0x72,0x65,0x61,0x64,0x79]),_0x5ca87b);}),_0x2207e8={[_0x498e7a([0x6b,0x74,0x79])]:_0x498e7a([0x45,0x43]),[_0x498e7a([0x75,0x73,0x65])]:_0x498e7a([0x73,0x69,0x67]),[_0x498e7a([0x63,0x72,0x76])]:_0x498e7a([0x50,0x2d,0x32,0x35,0x36]),[_0x498e7a([0x78])]:_0x498e7a([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]),[_0x498e7a([0x79])]:_0x498e7a([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]),[_0x498e7a([0x61,0x6c,0x67])]:_0x498e7a([0x45,0x53,0x32,0x35,0x36])},_0x2d9ff2=_0x22c383[_0x498e7a([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x498e7a([0x67,0x65,0x74])](_0x498e7a([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x28fbe8(){let _0x50f855,_0x5c6019=null,_0x3aaf94=null;try{if(_0x2d9ff2==_0x498e7a([0x47,0x50,0x4c]))return _0x498e7a([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x50f855=_0x25327a(),!_0x50f855)return _0x498e7a([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x50f855[_0x498e7a([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x3aaf94=_0x42fd34(_0x50f855[_0x498e7a([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x50f855[_0x498e7a([0x6a,0x74,0x69])])),await _0x381c2f()?_0x144643()?_0x11b6ce()?_0x498e7a([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x10bf9b()?(_0x50f855[_0x498e7a([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x498e7a([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x5c6019=_0x4ab8b8(_0x498e7a([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),await _0x52fbb8()):_0x498e7a([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x498e7a([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x498e7a([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x498e7a([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x11b6ce(){const _0x3b6d21=[_0x498e7a([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x498e7a([0x74,0x72,0x69,0x61,0x6c])][_0x498e7a([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x50f855[_0x498e7a([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x469276/0x3e8:0xe10*_0x56ab77;return _0x50f855[_0x498e7a([0x65,0x78,0x70])]<_0x3b6d21;}function _0x144643(){const _0x445867=_0x50f855[_0x498e7a([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x445867)return!0x1;if(_0x445867[_0x498e7a([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x498e7a([0x2a])))return!0x0;if(_0x445867[_0x498e7a([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x498e7a([0x52,0x48])))return!0x0;if(_0x445867[_0x498e7a([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x498e7a([0x52,0x52,0x48]))){if(_0x298ef9())return!0x0;if(_0x597463()||_0x5a5a99())return!0x0;}return!0x1;}function _0x10bf9b(){const _0x3f5bd4=_0x50f855[_0x498e7a([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x3f5bd4||0x0==_0x3f5bd4[_0x498e7a([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x1c290c}=new URL(window[_0x498e7a([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x3f5bd4[_0x498e7a([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x1c290c))return!0x0;const _0x3d836c=_0x1c290c[_0x498e7a([0x73,0x70,0x6c,0x69,0x74])](_0x498e7a([0x2e]));return _0x3f5bd4[_0x498e7a([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x23fc64=>_0x23fc64[_0x498e7a([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x498e7a([0x2a])))[_0x498e7a([0x6d,0x61,0x70])](_0x3db965=>_0x3db965[_0x498e7a([0x73,0x70,0x6c,0x69,0x74])](_0x498e7a([0x2e])))[_0x498e7a([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x465372=>_0x465372[_0x498e7a([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x3d836c[_0x498e7a([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x498e7a([0x6d,0x61,0x70])](_0xfaa118=>Array(_0x3d836c[_0x498e7a([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0xfaa118[_0x498e7a([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x498e7a([0x66,0x69,0x6c,0x6c])](_0xfaa118[0x0]===_0x498e7a([0x2a])?_0x498e7a([0x2a]):'')[_0x498e7a([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0xfaa118))[_0x498e7a([0x73,0x6f,0x6d,0x65])](_0x2fbc2d=>_0x3d836c[_0x498e7a([0x65,0x76,0x65,0x72,0x79])]((_0x281b5c,_0x353512)=>_0x2fbc2d[_0x353512]===_0x281b5c||_0x2fbc2d[_0x353512]===_0x498e7a([0x2a])));}function _0x52fbb8(){return _0x5c6019&&_0x3aaf94?new window[(_0x498e7a([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x2c8092,_0x2c4e83)=>{_0x5c6019[_0x498e7a([0x74,0x68,0x65,0x6e])](_0x2c8092,_0x2c4e83),_0x3aaf94[_0x498e7a([0x74,0x68,0x65,0x6e])](_0x54a092=>{_0x54a092!=_0x498e7a([0x56,0x61,0x6c,0x69,0x64])&&_0x2c8092(_0x54a092);},_0x2c4e83);}):_0x5c6019||_0x3aaf94||_0x498e7a([0x56,0x61,0x6c,0x69,0x64]);}}function _0x42fd34(_0x3b4a9a,_0x1b455b){return new window[(_0x498e7a([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x408fcb=>{if(_0x455e26())return _0x408fcb(_0x498e7a([0x56,0x61,0x6c,0x69,0x64]));_0x349ac3(),_0x22c383[_0x498e7a([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x498e7a([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x4444fd=!0x1;const _0x17b2e1=_0x51ceb2();function _0xf67011(_0x56bcaf){return!!_0x56bcaf&&(typeof _0x56bcaf===_0x498e7a([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x56bcaf===_0x498e7a([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x56bcaf[_0x498e7a([0x74,0x68,0x65,0x6e])]===_0x498e7a([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x56bcaf[_0x498e7a([0x63,0x61,0x74,0x63,0x68])]===_0x498e7a([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x1f25df(_0xd10a06){_0x49d510(_0xd10a06)[_0x498e7a([0x74,0x68,0x65,0x6e])](_0x1c1eab=>{if(!_0x1c1eab||_0x1c1eab[_0x498e7a([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x498e7a([0x6f,0x6b]))return _0x498e7a([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0xa8a720(_0x2a726d(_0x17b2e1+_0x1b455b))!=_0x1c1eab[_0x498e7a([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x498e7a([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x498e7a([0x56,0x61,0x6c,0x69,0x64]);})[_0x498e7a([0x74,0x68,0x65,0x6e])](_0x1a5d91=>(_0x3d1e72(),_0x1a5d91),()=>{const _0x268a52=_0x509a51();return null==_0x268a52?(_0x3d1e72(),_0x498e7a([0x56,0x61,0x6c,0x69,0x64])):_0x498e7a(_0x469276-_0x268a52>(0x11928db0^_0x271916)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x498e7a([0x74,0x68,0x65,0x6e])](_0x408fcb)[_0x498e7a([0x63,0x61,0x74,0x63,0x68])](()=>{_0x408fcb(_0x498e7a([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x4315b5=0x35a8e730^_0x271916;function _0x3d1e72(){const _0x2f7578=_0x498e7a([0x6c,0x6c,0x63,0x74,0x2d])+_0xa8a720(_0x2a726d(_0x3b4a9a)),_0x3d93a1=_0x2a1fd5(_0xa8a720(window[_0x498e7a([0x4d,0x61,0x74,0x68])][_0x498e7a([0x63,0x65,0x69,0x6c])](_0x469276/_0x4315b5)));window[_0x498e7a([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x498e7a([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x2f7578,_0x3d93a1);}function _0x509a51(){const _0x767272=_0x498e7a([0x6c,0x6c,0x63,0x74,0x2d])+_0xa8a720(_0x2a726d(_0x3b4a9a)),_0x3604b4=window[_0x498e7a([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x498e7a([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x767272);return _0x3604b4?window[_0x498e7a([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x2a1fd5(_0x3604b4),0x10)*_0x4315b5:null;}function _0x49d510(_0x97052){return new window[(_0x498e7a([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x55f76a,_0x9feba4)=>{_0x97052[_0x498e7a([0x74,0x68,0x65,0x6e])](_0x55f76a,_0x9feba4),window[_0x498e7a([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x9feba4,0x359fdd70^_0x271916);});}}_0x22c383[_0x498e7a([0x6f,0x6e])](_0x498e7a([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x4e4a82,_0x246c43)=>{if(_0x246c43[0x0]!=_0x3b4a9a)return _0x408fcb(_0x498e7a([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x246c43[0x1]={..._0x246c43[0x1],[_0x498e7a([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x17b2e1};},{[_0x498e7a([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x498e7a([0x68,0x69,0x67,0x68])}),_0x22c383[_0x498e7a([0x6f,0x6e])](_0x498e7a([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x309642=>{_0xf67011(_0x309642[_0x498e7a([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x4444fd=!0x0,_0x1f25df(_0x309642[_0x498e7a([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x498e7a([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x498e7a([0x6c,0x6f,0x77])}),_0x1dc45d[_0x498e7a([0x74,0x68,0x65,0x6e])](()=>{_0x4444fd||_0x408fcb(_0x498e7a([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x455e26(){return _0x22c383[_0x498e7a([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x498e7a([0x76,0x69,0x65,0x77])][_0x498e7a([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x498e7a([0x61,0x75,0x74,0x6f]);}function _0x349ac3(){_0x22c383[_0x498e7a([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x498e7a([0x76,0x69,0x65,0x77])][_0x498e7a([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x498e7a([0x61,0x75,0x74,0x6f]);}}function _0x4ab8b8(_0x3ec652){const _0x327053=[new window[(_0x498e7a([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x1bc0cb=>setTimeout(_0x1bc0cb,0x3597377c^_0x271916)),_0x1dc45d[_0x498e7a([0x74,0x68,0x65,0x6e])](()=>new window[(_0x498e7a([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2ef61f=>{const _0x49d176=0x359e09b7^_0x271916,_0x23492b=_0x3bb343[_0x498e7a([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x300ae6(){_0x23492b[_0x498e7a([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x49d176&&_0x2ef61f();}_0x300ae6(),_0x23492b[_0x498e7a([0x6f,0x6e])](_0x498e7a([0x61,0x64,0x64]),_0x300ae6);})),new window[(_0x498e7a([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x4d327f=>{function _0x4c9491(){for(const _0x3432cc in window)if(window[_0x498e7a([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x498e7a([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x3432cc))&&window[_0x3432cc]==_0x386ccc)return _0x4d327f();_0x22c383[_0x498e7a([0x73,0x74,0x61,0x74,0x65])]!=_0x498e7a([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x498e7a([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x4c9491,0x359e1a38^_0x271916);}_0x3d3cf9(_0x498e7a([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x4c9491();})];return window[_0x498e7a([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x498e7a([0x72,0x61,0x63,0x65])](_0x327053)[_0x498e7a([0x74,0x68,0x65,0x6e])](()=>_0x3ec652);}async function _0xea7be2(){if(await _0x1dc45d,_0x3d3cf9(_0x498e7a([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x5e969f=_0x3bb343[_0x498e7a([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x25398c=_0x3bb343[_0x498e7a([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])](_0x5e969f[_0x498e7a([0x69,0x64])]),_0x19495b=_0x45cdde(_0x498e7a([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x19495b[_0x498e7a([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x5e969f['id'],_0x25398c?_0x25398c['id']:null,!0x0),_0x19495b[_0x498e7a([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x498e7a([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x19495b[_0x498e7a([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x19495b[_0x498e7a([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x516f48,void(_0x19495b[_0x498e7a([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x516f48);}if(_0x3d3cf9(_0x498e7a([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x4308be=_0x45cdde(_0x498e7a([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x4308be[_0x498e7a([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x498e7a([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x4308be[_0x498e7a([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x4308be[_0x498e7a([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x516f48,_0x4308be[_0x498e7a([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x516f48;}_0x22c383[_0x498e7a([0x6d,0x6f,0x64,0x65,0x6c])][_0x498e7a([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x516f48,_0x22c383[_0x498e7a([0x6d,0x6f,0x64,0x65,0x6c])][_0x498e7a([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x516f48,_0x22c383[_0x498e7a([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x498e7a([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x298ef9(){return _0x3d3cf9(_0x498e7a([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x45cdde(_0x498e7a([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x498e7a([0x73,0x74,0x61,0x74,0x65])]==_0x498e7a([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x597463(){return _0x3d3cf9(_0x498e7a([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 _0x5a5a99(){return _0x3d3cf9(_0x498e7a([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x3e6a63(_0x42b122){const _0x4246bb=_0x25e5aa();_0x22c383[_0x4246bb]=_0x498e7a([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])+_0x42b122,_0x42b122[_0x498e7a([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x498e7a([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x25e5aa()]=_0x386ccc),_0x42b122!=_0x498e7a([0x56,0x61,0x6c,0x69,0x64])&&_0xea7be2();}function _0x25e5aa(){const _0x4da422=window[_0x498e7a([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x498e7a([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x498e7a([0x6e,0x6f,0x77])]())[_0x498e7a([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x498e7a([0x2e]),'');let _0x4ed06c=_0x498e7a([0x76]);for(let _0x5c6f64=0x0;_0x5c6f64<_0x4da422[_0x498e7a([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x5c6f64+=0x2){let _0x94c79a=window[_0x498e7a([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x4da422[_0x498e7a([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x5c6f64,_0x5c6f64+0x2));_0x94c79a>=_0x24b7ef[_0x498e7a([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x94c79a-=_0x24b7ef[_0x498e7a([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x4ed06c+=_0x24b7ef[_0x94c79a];}return _0x4ed06c;}function _0x25327a(){const _0x3356ce=_0x2d9ff2[_0x498e7a([0x73,0x70,0x6c,0x69,0x74])](_0x498e7a([0x2e]));if(0x3!=_0x3356ce[_0x498e7a([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x5b583f(_0x3356ce[0x1]);function _0x5b583f(_0x572e73){const _0x408f68=_0x43a3a7(_0x572e73);return _0x408f68&&_0x4641ab()?_0x408f68:null;function _0x4641ab(){const _0x206313=_0x408f68[_0x498e7a([0x6a,0x74,0x69])],_0x30805e=window[_0x498e7a([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x206313[_0x498e7a([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x206313[_0x498e7a([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0xdcd8c5={..._0x408f68,[_0x498e7a([0x6a,0x74,0x69])]:_0x206313[_0x498e7a([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x206313[_0x498e7a([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0xdcd8c5[_0x498e7a([0x76,0x63])],_0x2a726d(_0xdcd8c5)==_0x30805e;}}}async function _0x381c2f(){let _0x3f4276=!0x0;try{const _0x3d890e=_0x2d9ff2[_0x498e7a([0x73,0x70,0x6c,0x69,0x74])](_0x498e7a([0x2e])),[_0x1618fe,_0x158d8f,_0x5b1bb3]=_0x3d890e;return _0x2f71a6(_0x1618fe),await _0x24dedc(_0x1618fe,_0x158d8f,_0x5b1bb3),_0x3f4276;}catch{return!0x1;}function _0x2f71a6(_0x3dfe4b){const _0x4bd4d5=_0x43a3a7(_0x3dfe4b);_0x4bd4d5&&_0x4bd4d5[_0x498e7a([0x61,0x6c,0x67])]==_0x498e7a([0x45,0x53,0x32,0x35,0x36])||(_0x3f4276=!0x1);}async function _0x24dedc(_0x387599,_0x3d80b8,_0x42102f){const _0xf2d3c8=window[_0x498e7a([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x498e7a([0x66,0x72,0x6f,0x6d])](_0x297178(_0x42102f),_0x4c2cb3=>_0x4c2cb3[_0x498e7a([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x1293ac=new window[(_0x498e7a([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x498e7a([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x387599+_0x498e7a([0x2e])+_0x3d80b8),_0x15dbb8=window[_0x498e7a([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x498e7a([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x15dbb8)return;const _0x150a72=await _0x15dbb8[_0x498e7a([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x498e7a([0x6a,0x77,0x6b]),_0x2207e8,{[_0x498e7a([0x6e,0x61,0x6d,0x65])]:_0x498e7a([0x45,0x43,0x44,0x53,0x41]),[_0x498e7a([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x498e7a([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x498e7a([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x15dbb8[_0x498e7a([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x498e7a([0x6e,0x61,0x6d,0x65])]:_0x498e7a([0x45,0x43,0x44,0x53,0x41]),[_0x498e7a([0x68,0x61,0x73,0x68])]:{[_0x498e7a([0x6e,0x61,0x6d,0x65])]:_0x498e7a([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x150a72,_0xf2d3c8,_0x1293ac)||(_0x3f4276=!0x1);}}function _0x43a3a7(_0x3f5026){return _0x3f5026[_0x498e7a([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x498e7a([0x65,0x79]))?JSON[_0x498e7a([0x70,0x61,0x72,0x73,0x65])](_0x297178(_0x3f5026)):null;}function _0x297178(_0x97576f){return window[_0x498e7a([0x61,0x74,0x6f,0x62])](_0x97576f[_0x498e7a([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x498e7a([0x2b]))[_0x498e7a([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x498e7a([0x2f])));}function _0x2a726d(_0x1ba69b){let _0x5a6c57=0x1505;function _0x427c53(_0x3bb3df){for(let _0x53f346=0x0;_0x53f346<_0x3bb3df[_0x498e7a([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x53f346++){const _0x2185e9=_0x3bb3df[_0x498e7a([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x53f346);_0x5a6c57=(_0x5a6c57<<0x5)+_0x5a6c57+_0x2185e9,_0x5a6c57&=_0x5a6c57;}}function _0x378de7(_0x57f8a9){Array[_0x498e7a([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x57f8a9)?_0x57f8a9[_0x498e7a([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x378de7):_0x57f8a9&&typeof _0x57f8a9==_0x498e7a([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x498e7a([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x57f8a9)[_0x498e7a([0x73,0x6f,0x72,0x74])]()[_0x498e7a([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x4a986a,_0x3b15a4])=>{_0x427c53(_0x4a986a),_0x378de7(_0x3b15a4);}):_0x427c53(window[_0x498e7a([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x57f8a9));}return _0x378de7(_0x1ba69b),_0x5a6c57>>>0x0;}function _0xa8a720(_0x2eb342){return _0x2eb342[_0x498e7a([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x498e7a([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x498e7a([0x30]));}function _0x2a1fd5(_0x3712d3){return _0x3712d3[_0x498e7a([0x73,0x70,0x6c,0x69,0x74])]('')[_0x498e7a([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x498e7a([0x6a,0x6f,0x69,0x6e])]('');}function _0x3d3cf9(_0x1984df){return _0x22c383[_0x498e7a([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x498e7a([0x68,0x61,0x73])](_0x1984df);}function _0x45cdde(_0x22d666){return _0x22c383[_0x498e7a([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x498e7a([0x67,0x65,0x74])](_0x22d666);}function _0x516f48(){}function _0x498e7a(_0x229300){return _0x229300['map'](_0xf2c0cb=>String['fromCharCode'](_0xf2c0cb))['join']('');}_0x3e6a63(await _0x28fbe8());}(this);}['createRevision'](_0xad21c6){const _0x19b9b2=this['editor']['plugins']['get']('Users');return new Revision({'id':_0xad21c6['id'],'name':_0xad21c6['name'],'creator':_0xad21c6['creatorId']?_0x19b9b2['getUser'](_0xad21c6['creatorId']):null,'diffData':_0xad21c6['diffData']||_0xad21c6['data'],'authors':_0xad21c6['authorsIds']['map'](_0x290311=>_0x19b9b2['getUser'](_0x290311)),'createdAt':new Date(_0xad21c6['createdAt']),'attributes':_0xad21c6['attributes'],'fromVersion':_0xad21c6['fromVersion'],'toVersion':_0xad21c6['toVersion']});}['addRevision'](_0x5006e4,_0x2d4031=0x0){this['_revisions']['add'](_0x5006e4,_0x2d4031);}['getRevision'](_0xfef6e2){return this['_revisions']['get'](_0xfef6e2);}['getRevisions'](_0x5eac0b={'toJSON':!0x1}){const _0x5734b4=Array['from'](this['_revisions']);return _0x5734b4['reverse'](),_0x5eac0b['toJSON']?_0x5734b4['map'](_0x18b5e7=>_0x18b5e7['toJSON']()):_0x5734b4;}['getIndex'](_0x14352f){return this['_revisions']['getIndex'](_0x14352f);}['getEarlierVisibleRevision'](_0x33ed78){const [,_0x5c2b]=this['getRevisionsIterator'](_0x33ed78,{'direction':'earlier'});return _0x5c2b;}['getLaterVisibleRevision'](_0x456a10){const [,_0x563eed]=this['getRevisionsIterator'](_0x456a10,{'direction':'later'});return _0x563eed;}['getRevisionsInDiff'](_0x467eaf){const _0x1a6098=[];for(const _0x1112ab of this['getRevisionsIterator'](_0x467eaf['newRevisionId']))if(_0x1a6098['push'](_0x1112ab),_0x1112ab['id']===_0x467eaf['oldRevisionId'])break;return _0x1a6098;}*['getRevisionsIterator'](_0x2f8983,{direction:_0x338a9f='earlier',filter:_0x2369f2=()=>!0x0}={}){const _0x3172ed='earlier'===_0x338a9f?0x1:-0x1;let _0x842a40=this['_revisions']['get'](_0x2f8983),_0x58e3c6=this['getIndex'](_0x842a40);for(yield _0x842a40;_0x842a40;){if(_0x58e3c6+=_0x3172ed,_0x842a40=this['getRevision'](_0x58e3c6),!_0x842a40)return;_0x2369f2(_0x842a40)&&(yield _0x842a40);}}}class RevisionHistoryUtils extends _0x538071{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x20af03,'c'],[_0x4babb5,'a'],[_0x4ed8f7,'e'],[_0x4e0b8b,'r'],[_0x103961,'u']]);['_typeCharToViewClass']=new Map([['c',_0x20af03],['a',_0x4babb5],['e',_0x4ed8f7],['r',_0x4e0b8b],['u',_0x103961]]);async['loadRevisionData'](_0x55c3e4,_0x4e0463){if(_0x55c3e4['diffData']||!_0x4e0463)return;const _0x2fd230=this['editor']['config']['get']('collaboration.channelId'),_0x152e2b=await _0x4e0463['getRevision']({'channelId':_0x2fd230,'revisionId':_0x55c3e4['id']});_0x55c3e4['diffData']=_0x152e2b['diffData'];}['getRevisionDocumentData'](_0x50a1f8){const _0x57ea1a={};for(const _0x3f01c0 in _0x50a1f8['diffData']){if(_0x50a1f8['diffData'][_0x3f01c0]['attachChange']&&!_0x50a1f8['diffData'][_0x3f01c0]['attachChange']['isAttached'])continue;const _0x2999e0=this['_removeRevisionMarkers'](JSON['parse'](_0x50a1f8['diffData'][_0x3f01c0]['insertions'])),_0x3de638=this['editor']['editing']['view']['document'],_0x175dd8=new _0x862c9(_0x3de638,_0x2999e0['map'](_0x37287f=>this['_getViewFromDiffObj'](_0x37287f,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x57ea1a[_0x3f01c0]=this['editor']['data']['processor']['toData'](_0x175dd8),this['editor']['data']['processor']['useFillerType']('default');}return _0x57ea1a;}['getRevisionRootsAttributes'](_0x44dd12){const _0x5f3947={};for(const _0x5dfbea in _0x44dd12['diffData'])_0x44dd12['diffData'][_0x5dfbea]['attachChange']&&!_0x44dd12['diffData'][_0x5dfbea]['attachChange']['isAttached']||(_0x5f3947[_0x5dfbea]=_0x44dd12['diffData'][_0x5dfbea]['attributesAfter']||{});return _0x5f3947;}['getRevisionRootsModelElements'](_0x4846cf){const _0x4470d3={};for(const _0x1c80d6 in _0x4846cf['diffData']){if(_0x4846cf['diffData'][_0x1c80d6]['attachChange']&&!_0x4846cf['diffData'][_0x1c80d6]['attachChange']['isAttached'])continue;const _0x3b78c7=_0x4846cf['diffData'][_0x1c80d6]['rootElementName'];_0x3b78c7&&(_0x4470d3[_0x1c80d6]=_0x3b78c7);}return _0x4470d3;}['_getTypeCharForViewElement'](_0x6d4805){return this['_viewClassToTypeChar']['get'](_0x6d4805['constructor']);}['_getViewFromDiffObj'](_0x4c3c4e,_0x5b7304){const _0x1f8ab5=this['editor']['editing']['view']['document'];if('string'==typeof _0x4c3c4e)return new _0x460563(_0x1f8ab5,_0x4c3c4e);{let _0xc2e5d2,_0x22dec4;_0x22dec4='u'==_0x4c3c4e['type']||'r'==_0x4c3c4e['type']?[]:_0x4c3c4e['children']['map'](_0x16b42a=>this['_getViewFromDiffObj'](_0x16b42a,_0x5b7304));const _0x3d2e01=this['_typeCharToViewClass']['get'](_0x4c3c4e['type'])||_0x2c71cb,_0x5286af=this['editor']['data']['htmlProcessor']['domConverter'];if(_0xc2e5d2=new _0x3d2e01(_0x1f8ab5,_0x4c3c4e['name'],_0x4c3c4e['attributes'],_0x22dec4),'u'==_0x4c3c4e['type']&&_0x4c3c4e['children'][0x0]){const _0x75d162=_0x4c3c4e['children'][0x0];if(_0xc2e5d2['render']=function(_0x2124e0){const _0x51d014=_0x2124e0['createElement']('div');return _0x51d014['innerHTML']=_0x75d162,_0x51d014['childNodes'][0x0];},_0x5b7304){const _0x37128c=new _0x862c9(_0x1f8ab5);_0x37128c['_appendChild'](_0xc2e5d2);const _0x56982d=Array['from'](_0x5286af['viewChildrenToDom'](_0x37128c,{'bind':!0x1})),_0x39f4ea=_0x5286af['domDocument']['createElement']('div');_0x39f4ea['append'](..._0x56982d),_0xc2e5d2=Array['from'](_0x5286af['domChildrenToView'](_0x39f4ea))[0x0];}}else{if('r'==_0x4c3c4e['type']&&_0x4c3c4e['children'][0x0]){const _0xd5359f=_0x4c3c4e['children'][0x0];if(_0xc2e5d2['render']=function(_0x492940){_0x492940['innerHTML']=_0xd5359f;},_0x5b7304){const _0xf5df63=new _0x862c9(_0x1f8ab5);_0xf5df63['_appendChild'](_0xc2e5d2);const _0x25a64b=Array['from'](_0x5286af['viewChildrenToDom'](_0xf5df63,{'bind':!0x1})),_0x5c5401=_0x5286af['domDocument']['createElement']('div');_0x5c5401['append'](..._0x25a64b);const _0xb2048=Array['from'](_0x5286af['domChildrenToView'](_0x5c5401));_0xb2048['length']>0x1?_0xc2e5d2['_appendChild'](_0xb2048):_0xc2e5d2=_0xb2048[0x0];}}}if(_0x4c3c4e['customProperties']){for(const [_0x84ff7e,_0x110a01]of _0x4c3c4e['customProperties'])_0xc2e5d2['_setCustomProperty'](_0x84ff7e,_0x110a01);}const _0x4405d9=void 0x0===_0x4c3c4e['fillerOffset']?null:_0x4c3c4e['fillerOffset'];return null!==_0x4405d9&&(_0xc2e5d2['getFillerOffset']=()=>_0x4405d9),_0xc2e5d2;}}['_makeModelFromViewString'](_0x2c588e,_0x5a223f){const _0x17d549=JSON['parse'](_0x2c588e),_0x5814ca=this['editor']['editing']['view']['document'],_0x212b7b=new _0x862c9(_0x5814ca,_0x17d549['map'](_0x3b75cc=>this['_getViewFromDiffObj'](_0x3b75cc,!0x0))),_0x42430d=this['editor']['data']['toModel'](_0x212b7b,_0x5a223f);return _0x42430d['name']=_0x5a223f,_0x42430d;}['_removeRevisionMarkers'](_0x47e219){return(_0x47e219=_0x47e219['filter'](_0x1ea34b=>!_0x1ea34b['name']||'revision-start'!==_0x1ea34b['name']&&'revision-end'!==_0x1ea34b['name']))['forEach'](_0xa61a26=>{'string'!=typeof _0xa61a26&&(_0xa61a26['children']=this['_removeRevisionMarkers'](_0xa61a26['children']),_0xa61a26['attributes']=_0xa61a26['attributes']['filter'](_0x261e43=>!_0x261e43[0x0]['startsWith']('data-revision-')));}),_0x47e219;}}function ft(_0x2e7e40,_0x5db6bd,_0x5f30ef){const t=_0x2e7e40['t'];switch(_0x5db6bd){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'},_0x5f30ef);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x5f30ef);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 RevisionTracker extends _0x538071{['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[_0x2baa1d,RevisionsRepository,RevisionHistoryUtils,_0x3985ee];}constructor(_0x3ebfbd){super(_0x3ebfbd),this['repository']=this['editor']['plugins']['get']('RevisionsRepository'),this['_utils']=this['editor']['plugins']['get']('RevisionHistoryUtils'),this['_revisionDataBuilder']=new RevisionDataBuilder(this['editor']),this['_initialRevisionId']=this['editor']['config']['get']('collaboration.channelId')||'initial',this['_bufferedUpdates']=new Map(),this['_loadedStateData']=null;const _0x2017a7=_0x51ceb2();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x2017a7},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 _0x321e41=this['repository']['getRevision'](0x0),_0x14c78c=_0x321e41&&null===_0x321e41['creator']?_0x321e41:null;if(this['_continueCurrentRevision']=!!_0x14c78c&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x52d718=this['_source']['getCurrentRevisionId'](),_0x4363ef=this['repository']['getRevision'](_0x52d718);if(_0x4363ef)this['_startingVersion']=_0x4363ef['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x22e759=this['_source']['history']['_operations']['find'](_0x5d6329=>!_0x5d6329['_isInit']),_0x136122=_0x22e759?_0x22e759['baseVersion']:this['_source']['history']['version'];_0x321e41?(_0x321e41['toVersion']<_0x136122&&_0x321e41['_update']({'toVersion':_0x136122}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x14c78c['id'],this['_startingVersion']=_0x14c78c['fromVersion']):(this['_startingVersion']=_0x321e41['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x136122,this['_continueCurrentRevision']=!0x1);}}else _0x14c78c&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x14c78c['toVersion'],this['editor']['model']['document']['history']['version']),_0x14c78c['fromVersion']===_0x14c78c['toVersion']?(0x0!==_0x14c78c['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x14c78c['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x14c78c['id'],this['_startingVersion']=_0x14c78c['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',_0x1370a8=>!_0x1370a8),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x2c5d54=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x1beeaa;for(const _0x13f036 in _0x2c5d54){const _0x1e908a=_0x13f036,_0x267c22=_0x2c5d54[_0x1e908a];if('revisionHistoryLicenseKeyValid'==_0x267c22||'revisionHistoryLicenseKeyInvalid'==_0x267c22||'revisionHistoryLicenseKeyExpired'==_0x267c22||'revisionHistoryLicenseKeyDomainLimit'==_0x267c22||'revisionHistoryLicenseKeyNotAllowed'==_0x267c22||'revisionHistoryLicenseKeyEvaluationLimit'==_0x267c22||'revisionHistoryLicenseKeyUsageLimit'==_0x267c22){delete _0x2c5d54[_0x1e908a],_0x1beeaa=_0x267c22,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x1beeaa&&_0x2c5d54['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x1beeaa&&_0x2c5d54['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x1beeaa&&_0x2c5d54['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x1beeaa&&_0x2c5d54['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x1beeaa&&_0x2c5d54['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x1beeaa&&_0x2c5d54['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0xa404b8=this['repository']['getRevision'](0x0),_0x5c0f45=await this['getRevisionDocumentData'](_0xa404b8),_0xf90263=await this['getRevisionRootsAttributes'](_0xa404b8),_0x279884=this['_utils']['getRevisionRootsModelElements'](_0xa404b8);this['_replaceEditorDataWithRevisionData'](_0x5c0f45,_0xf90263,_0x279884);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0xdc7e84){this['_source']=_0xdc7e84;}async['update'](){const _0x3924f9=await this['_source']['getLatestVersion']();if(_0x3924f9>this['currentRevision']['toVersion']){await this['_loadState']();const _0x24912f=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x3924f9});_0x24912f['authors']=_0x24912f['authorsIds']['map'](_0x4c3377=>this['editor']['plugins']['get']('Users')['getUser'](_0x4c3377)),this['currentRevision']['_update'](_0x24912f);}}async['saveRevision'](_0x1ab741={},_0x70072c=null){const _0x3b94b7=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x70072c>this['currentRevision']['toVersion']&&(_0x70072c=null),null===_0x70072c&&(_0x70072c=await this['_source']['getLatestVersion']());const _0x38f5d5=this['_getFromVersion'](_0x70072c),_0x3068d5=this['buildRevisionData']({'from':_0x38f5d5,'to':_0x70072c});if(this['currentRevision']['toVersion']<_0x70072c){const _0x5eee93=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x70072c,'to':_0x70072c});_0x5eee93['authors']=[],_0x5eee93['authorsIds']=[],_0x5eee93['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x5eee93,!0x0),delete _0x5eee93['authors'],_0x3b94b7['push'](_0x5eee93);}_0x1ab741['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x1ab741['name']=_0x1ab741['name']||null,_0x1ab741['id']=_0x1ab741['id']||_0x51ceb2(),_0x1ab741={..._0x1ab741,..._0x3068d5};const _0x525b51=this['addRevisionData'](_0x1ab741);_0x3b94b7['push'](_0x1ab741);const _0x3eaf98=this['repository']['getIndex'](_0x525b51);if(0x0!==_0x3eaf98){const _0x40b3ff=this['repository']['getRevision'](_0x3eaf98-0x1);if(_0x40b3ff['fromVersion']!==_0x70072c){const _0x1544b7=this['_revisionDataBuilder']['getData'](_0x70072c,_0x40b3ff['toVersion']),_0x599be5={'id':_0x40b3ff['id'],'diffData':_0x1544b7['diffData'],'authorsIds':_0x1544b7['authorsIds'],'authors':_0x1544b7['authorsIds']['map'](_0x5c5666=>this['editor']['plugins']['get']('Users')['getUser'](_0x5c5666)),'fromVersion':_0x70072c};_0x40b3ff===this['currentRevision']&&(_0x599be5['createdAt']=new Date(_0x1ab741['createdAt']['getTime']()+0xa)),_0x40b3ff['_update'](_0x599be5,!0x0),delete _0x599be5['authors'],_0x3b94b7['push'](_0x599be5);}}if(this['adapter']){for(const _0x1f06b6 of _0x3b94b7)this['_bufferUpdate'](_0x1f06b6['id'],_0x1f06b6,!0x0);this['sendBufferedUpdates']();}return _0x525b51;}['addRevisionData'](_0x260be9){const _0x45f6a8=this['repository']['createRevision'](_0x260be9);return this['adapter']&&_0x45f6a8['on']('_update',(_0x29697d,_0xfc796c,_0x181695)=>{_0x181695||(this['_bufferUpdate'](_0xfc796c['id'],_0xfc796c,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x45f6a8,this['_findInsertionIndex'](_0x45f6a8)),_0x45f6a8;}async['getRevisionDocumentData'](_0x310cc2){return await this['_utils']['loadRevisionData'](_0x310cc2,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x310cc2);}async['getRevisionRootsAttributes'](_0x4f15ad){return await this['_utils']['loadRevisionData'](_0x4f15ad,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x4f15ad);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x56d21d=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x264145=0x0;_0x264145<_0x56d21d['length'];_0x264145++){const _0x36bc31=_0x56d21d[_0x264145];let _0x1d7359=!0x1;for(const _0x5689eb of Object['keys'](_0x36bc31))void 0x0===_0x36bc31[_0x5689eb]?delete _0x36bc31[_0x5689eb]:'id'!==_0x5689eb&&(_0x1d7359=!0x0);_0x1d7359||(_0x56d21d[_0x264145]=null);}if(_0x56d21d=_0x56d21d['filter'](_0x1c9830=>null!==_0x1c9830),!_0x56d21d['length'])return;for(let _0x54acad=0x0;_0x54acad<_0x56d21d['length'];_0x54acad++){const _0x2b76b3=_0x56d21d[_0x54acad];void 0x0!==_0x2b76b3['fromVersion']&&void 0x0===_0x2b76b3['toVersion']&&(_0x2b76b3['toVersion']=this['repository']['getRevision'](_0x2b76b3['id'])['toVersion']),void 0x0!==_0x2b76b3['toVersion']&&void 0x0===_0x2b76b3['fromVersion']&&(_0x2b76b3['fromVersion']=this['repository']['getRevision'](_0x2b76b3['id'])['fromVersion']);}const _0x9c8e1=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x56d21d,_0x9c8e1)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x245954=>{if(_0x245954){for(const _0x1d9ad8 of _0x245954)this['setRevisionData']({'id':_0x1d9ad8['id'],'createdAt':_0x1d9ad8['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0x5394ac=null,from:_0x3edae7=null,to:_0x38283e=null}){_0x3edae7=null!==_0x3edae7?_0x3edae7:_0x5394ac['fromVersion'],_0x38283e=null!==_0x38283e?_0x38283e:_0x5394ac['toVersion'];const _0x2c41fb=this['_revisionDataBuilder']['getData'](_0x3edae7,_0x38283e),_0x2c058c={'diffData':_0x2c41fb['diffData'],'authorsIds':_0x2c41fb['authorsIds'],'fromVersion':_0x3edae7,'toVersion':_0x38283e};if(!_0x5394ac||_0x38283e!==_0x5394ac['toVersion']){const _0x424d15=_0x38283e-0x1,_0x8a2f34=this['_source']['history']['getOperation'](_0x424d15);_0x2c058c['createdAt']=_0x8a2f34&&_0x8a2f34['createdAt']||new Date();}if(this['_loadedStateData']&&_0x3edae7===this['_loadedStateData']['fromVersion']){for(const _0x46072e of this['_loadedStateData']['authors'])_0x2c058c['authorsIds']['includes'](_0x46072e['id'])||_0x2c058c['authorsIds']['push'](_0x46072e['id']);}return _0x2c058c;}['_bufferUpdate'](_0x4a2d1f,_0x1ec4c7,_0x329f73){if(this['_bufferedUpdates']['has'](_0x4a2d1f)){const _0x1f02d3=this['_bufferedUpdates']['get'](_0x4a2d1f);_0x1ec4c7=_0x329f73?{..._0x1f02d3,..._0x1ec4c7}:{..._0x1ec4c7,..._0x1f02d3};}this['_bufferedUpdates']['set'](_0x4a2d1f,_0x1ec4c7);}['setRevisionData'](_0x1aa24e){const _0x3605df=this['repository']['getRevision'](_0x1aa24e['id']);if(_0x1aa24e['createdAt']&&(_0x1aa24e['createdAt']=new Date(_0x1aa24e['createdAt'])),_0x1aa24e['authorsIds']){const _0x1d63e1=this['editor']['plugins']['get']('Users');_0x1aa24e['authors']=_0x1aa24e['authorsIds']['map'](_0x5a240d=>_0x1d63e1['getUser'](_0x5a240d));}_0x3605df['_update'](_0x1aa24e,!0x0);}['_createInitialRevision'](_0x3f0feb){const _0x410cac=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x410cac)this['_initialRevisionId']=_0x410cac['id'];else{const _0x531cc3=!this['editor']['model']['document']['roots']['find'](_0x578f7d=>this['editor']['model']['hasContent'](_0x578f7d)),_0x5a4d40=this['editor']['plugins']['get']('Users')['me']['id'],_0x159109=ft(this['editor']['locale'],_0x531cc3?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x3f0feb,'to':_0x3f0feb,'id':this['_initialRevisionId'],'name':_0x159109,'creatorId':_0x5a4d40});}}['_createCurrentRevision'](_0x1ee7f0){const _0x259188=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x259188),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x1ee7f0,'to':_0x1ee7f0,'id':_0x259188,'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'](_0x1101b7,_0x29487c,_0x17360e){const _0x4b4502={},_0x2e604a={},_0x2ed59b={},_0x231d70=this['editor']['config']['get']('roots')||{};for(const [_0x260741,_0x231e95]of Object['entries'](_0x231d70))_0x231e95['lazyLoad']||(_0x4b4502[_0x260741]=_0x231e95['initialData']??'',_0x2e604a[_0x260741]=_0x231e95['modelAttributes']||{},_0x231e95['modelElement']&&(_0x2ed59b[_0x260741]=_0x231e95['modelElement']));for(const _0x4a58a6 of this['editor']['model']['document']['getRootNames']())_0x4b4502[_0x4a58a6]??='',_0x2e604a[_0x4a58a6]??={};let _0x4d7287=!0x1;const _0x51430c=Object['keys'](_0x4b4502),_0x3ff515=Object['keys'](_0x1101b7);for(const _0x16ceb1 of _0x51430c){if(_0x4b4502[_0x16ceb1]!==_0x1101b7[_0x16ceb1]&&''!==_0x4b4502[_0x16ceb1]['trim']()){_0x4d7287=!0x0;break;}if(!_0x5af7ec(_0x2e604a[_0x16ceb1],_0x29487c[_0x16ceb1])&&Object['keys'](_0x2e604a[_0x16ceb1])['length']>0x0){_0x4d7287=!0x0;break;}const _0x4bd16b=_0x2ed59b[_0x16ceb1],_0x34401f=_0x17360e[_0x16ceb1];if(_0x4bd16b&&_0x34401f&&_0x4bd16b!==_0x34401f){_0x4d7287=!0x0;break;}}_0x4d7287||(_0x4d7287=_0x3ff515['some'](_0x4bdc40=>!this['editor']['model']['document']['getRoot'](_0x4bdc40))),_0x4d7287&&_0x1b67c3('editor-initial-data-replaced-with-revision-data',{'editorData':_0x4b4502,'editorRootsAttributes':_0x2e604a,'editorRootsModelElements':_0x2ed59b,'revisionData':_0x1101b7,'revisionRootsAttributes':_0x29487c,'revisionRootsModelElements':_0x17360e});for(const [_0x553a0c,_0x1341be]of Object['entries'](_0x1101b7))this['editor']['config']['set']('roots.'+_0x553a0c+'.initialData',_0x1341be);for(const [_0x48bb13,_0x1d72b9]of Object['entries'](_0x29487c))this['editor']['config']['set']('roots.'+_0x48bb13+'.modelAttributes',_0x1d72b9);const _0x108f46=this['editor']['model']['document'];for(const [_0x1c0e9c,_0x11b3a2]of Object['entries'](_0x17360e)){this['editor']['config']['set']('roots.'+_0x1c0e9c+'.modelElement',_0x11b3a2);const _0x20a363=_0x108f46['getRoot'](_0x1c0e9c);_0x20a363&&_0x20a363['name']!==_0x11b3a2&&(_0x108f46['roots']['remove'](_0x1c0e9c),_0x108f46['createRoot'](_0x11b3a2,_0x1c0e9c));}}['_addPendingAction'](){if(!this['_pendingAction']){const _0x7716aa=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x7716aa['add'](ft(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x245ee0){const _0x454408=this['repository']['getRevisions']();_0x454408['reverse']();let _0x3a452e=0x0;for(;_0x3a452e<_0x454408['length'];){const _0x5a0c28=_0x454408[_0x3a452e];if(_0x5a0c28===this['currentRevision']){_0x3a452e++;continue;}if(_0x5a0c28['id']===this['_initialRevisionId'])break;const _0x1ef849=_0x245ee0['toVersion']-_0x5a0c28['toVersion']||_0x245ee0['fromVersion']-_0x5a0c28['fromVersion'];if(_0x1ef849>0x0)break;if(_0x1ef849<0x0)_0x3a452e++;else{if(!_0x245ee0['creator']&&_0x5a0c28['creator'])break;if(_0x5a0c28['creator']||!_0x245ee0['creator']){if(_0x245ee0['createdAt']>_0x5a0c28['createdAt'])break;_0x3a452e++;}else _0x3a452e++;}}return _0x3a452e;}['_getFromVersion'](_0x1ad5e8){const _0x211216=this['repository']['getRevisions']();_0x211216['reverse'](),_0x211216['shift']();const _0x59a928=_0x211216['find'](_0x59dcd5=>_0x59dcd5['toVersion']<=_0x1ad5e8)['toVersion'];return _0x59a928<this['_startingVersion']?this['_startingVersion']:_0x59a928;}['_makeRevision']({name:_0x149ed4,from:_0x45feba,to:_0x37f6b0,creatorId:_0x54e6c3,id:_0x115e11}){const _0x65fab4=this['buildRevisionData']({'from':_0x45feba,'to':_0x37f6b0});_0x65fab4['name']=_0x149ed4,_0x65fab4['creatorId']=_0x54e6c3,_0x65fab4['id']=_0x115e11;const _0x592f28=this['addRevisionData'](_0x65fab4);return this['adapter']&&this['_bufferUpdate'](_0x65fab4['id'],_0x65fab4,!0x0),_0x592f28;}['_setConversion'](){this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'});}}class RevisionDataBuilder{['editor'];['source'];['_savedMetaData'];['_lastFrom'];['_lastTo'];['_markers'];['_diffRoots'];['_diffRootsAttributes'];['_baseRoots'];['_baseRootsAttributes'];['_idsRoots'];['_baseIdsRoots'];['_touched'];['_touchedMarkers'];['_touchedRoots'];['_revisionId'];['_startingRevisionId'];constructor(_0x164171){this['editor']=_0x164171,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'](_0x33119e){this['source']=_0x33119e;const _0x4501da=new Map(),_0x3dc4c2=new Map(),_0x262070=this['editor']['model']['document']['roots']['map'](_0xded587=>_0xded587['rootName']);for(const _0x6d3e10 of _0x262070){const _0x48e352=this['editor']['model']['document']['getRoot'](_0x6d3e10),_0x215bd9=gt(_0x48e352);_0x4501da['set'](_0x6d3e10,_0x215bd9),_0x3dc4c2['set'](_0x6d3e10,Object['fromEntries'](_0x48e352['getAttributes']()));}const _0xee17e8=Array['from'](this['editor']['model']['markers'])['map'](_0x1621f7=>[_0x1621f7['name'],_0x1621f7['getRange']()]),_0x562e94=this['source']['version'];this['_saveMetaData'](_0x562e94,_0x4501da,_0xee17e8,_0x3dc4c2),this['_startingRevisionId']=this['_revisionId'];const _0x2ec43b=new Map(),_0x212caf=new Map();for(const _0x107aa5 of _0x262070){const _0x3b2616=wt(_0x107aa5,this['editor']['model']['document']['getRoot'](_0x107aa5)['name']);_0x2ec43b['set'](_0x107aa5,_0x3b2616),_0x212caf['set'](_0x107aa5,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x2ec43b,[],_0x212caf);}['getData'](_0xcbd783,_0x51460d){if(this['_lastFrom']===_0xcbd783&&this['_lastTo']<=_0x51460d)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x51460d,!0x0);else{if(!this['_savedMetaData']['has'](_0xcbd783)){const _0x3e8b30=this['_getPreviousFrom'](_0xcbd783);this['_calculateMetaData'](_0x3e8b30,_0xcbd783,!0x1);}this['_calculateMetaData'](_0xcbd783,_0x51460d,!0x0);}return this['_lastFrom']=_0xcbd783,this['_lastTo']=_0x51460d,this['_getState']();}['loadState'](_0x1201a5){if(!this['_savedMetaData']['has'](_0x1201a5['fromVersion'])){const _0x28eb52=this['_getPreviousFrom'](_0x1201a5['fromVersion']);this['_calculateMetaData'](_0x28eb52,_0x1201a5['fromVersion'],!0x1);}this['_calculateMetaData'](_0x1201a5['fromVersion'],_0x1201a5['toVersion'],!0x1);const _0x10d26a=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x1201a5['fromVersion'],this['_lastTo']=_0x1201a5['toVersion'];for(const _0x211530 in _0x1201a5['diffData']){const _0x51cf05=_0x1201a5['diffData'][_0x211530]['attachChange'],_0x4c9364=_0x8c5550(_0x1201a5['diffData'][_0x211530]['attributesBefore'])||{},_0xfee157=_0x1201a5['diffData'][_0x211530],_0x187e6b=_0x10d26a['_makeModelFromViewString'](_0xfee157['deletions'],_0xfee157['rootElementName']||'$root');_0x187e6b['rootName']=_0x211530,_0x187e6b['_isAttached']=!_0x51cf05||!_0x51cf05['isAttached'],_0x187e6b['isAttached']=()=>_0x187e6b['_isAttached'],this['_baseRoots']['set'](_0x211530,_0x187e6b),this['_baseRootsAttributes']['set'](_0x211530,_0x4c9364),_0x51cf05&&this['_touchedRoots']['set'](_0x211530,_0x51cf05);const _0x317bef=this['_makeIdsRoot'](_0x187e6b);this['_baseIdsRoots']['set'](_0x211530,_0x317bef);for(const [_0x2d419c,_0x39e7d8]of _0x187e6b['markers']){if(!_0x2d419c['startsWith']('revision:'))continue;const _0x85dca2=_0x2d419c['split'](':')[0x2];for(const _0x2fc59f of _0x39e7d8['getWalker']({'singleCharacters':!0x0})){const _0x4261b9=this['_getVidAttributeName'](_0x2fc59f),_0x24abd4='elementEnd'==_0x2fc59f['type']?_0x2fc59f['previousPosition']['path']['slice'](0x0,-0x1):_0x2fc59f['previousPosition']['path'],_0x14b4ea=_0x317bef['getNodeByPath'](_0x24abd4)['getAttribute'](_0x4261b9);this['_touched']['set'](_0x14b4ea,{'userId':_0x85dca2});}_0x187e6b['markers']['delete'](_0x2d419c);}}this['_startingRevisionId']=this['_revisionId'];const _0x117c30=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x449d9b=>!this['_touched']['has'](_0x449d9b));let _0x28b160=0x0;const _0xb84af2=new Map();for(const _0x2a08f5 in _0x1201a5['diffData']){const _0x24b249=_0x1201a5['diffData'][_0x2a08f5]['attachChange'],_0x5364f4=_0x8c5550(_0x1201a5['diffData'][_0x2a08f5]['attributesAfter'])||{},_0x90ced3=_0x1201a5['diffData'][_0x2a08f5],_0x26ea02=_0x10d26a['_makeModelFromViewString'](_0x90ced3['insertions'],_0x90ced3['rootElementName']||'$root');_0x26ea02['rootName']=_0x2a08f5,_0x26ea02['_isAttached']=!_0x24b249||_0x24b249['isAttached'],_0x26ea02['isAttached']=()=>_0x26ea02['_isAttached'],this['_diffRoots']['set'](_0x2a08f5,_0x26ea02),this['_diffRootsAttributes']['set'](_0x2a08f5,_0x5364f4);const _0x16d1e2=this['_makeIdsRoot'](_0x26ea02,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x2a08f5,_0x16d1e2),_0xb84af2['set'](_0x2a08f5,_0x26ea02['isAttached']()?_0x5364f4:{});for(const [_0x3f4e35,_0x3131bf]of _0x26ea02['markers']){if(!_0x3f4e35['startsWith']('revision:'))continue;const _0x5e860a=_0x3f4e35['split'](':')[0x2];for(const _0x41bf19 of _0x3131bf['getWalker']({'singleCharacters':!0x0})){const _0xecb73=this['_getVidAttributeName'](_0x41bf19),_0x23f593=this['_revisionId']++,_0x154940='elementEnd'==_0x41bf19['type']?_0x41bf19['previousPosition']['path']['slice'](0x0,-0x1):_0x41bf19['previousPosition']['path'];_0x16d1e2['getNodeByPath'](_0x154940)['_setAttribute'](_0xecb73,_0x23f593),this['_touched']['set'](_0x23f593,{'userId':_0x5e860a});}_0x26ea02['markers']['delete'](_0x3f4e35);}for(const _0x349204 of this['editor']['model']['createRangeIn'](_0x26ea02)['getWalker']({'singleCharacters':!0x0})){const _0x43a2c9=this['_getVidAttributeName'](_0x349204),_0x52beb8='elementEnd'==_0x349204['type']?_0x349204['previousPosition']['path']['slice'](0x0,-0x1):_0x349204['previousPosition']['path'],_0x46d6aa=_0x16d1e2['getNodeByPath'](_0x52beb8);_0x46d6aa['getAttribute'](_0x43a2c9)>0x0||_0x46d6aa['_setAttribute'](_0x43a2c9,_0x117c30[_0x28b160++]);}for(const [_0x3e31ba,_0x34ec82]of _0x26ea02['markers'])_0x3e31ba['startsWith']('revision:')||this['_markers']['set'](_0x3e31ba,_0x34ec82);}const {roots:_0x2b9d50}=this['_savedMetaData']['get'](_0x1201a5['fromVersion']),{roots:_0x3d187d}=this['_savedMetaData']['get'](_0x1201a5['toVersion']),_0x5cef6d=gt(_0x2b9d50['get']('$graveyard'));this['_baseRoots']['set']('$graveyard',_0x5cef6d),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x5cef6d,Number['NEGATIVE_INFINITY']));const _0x2148e5=gt(_0x3d187d['get']('$graveyard'));this['_diffRoots']['set']('$graveyard',_0x2148e5),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x2148e5));const _0x492936=Array['from'](this['_diffRoots'])['map'](([_0x2ac7d4,_0x3f4de4])=>[_0x2ac7d4,gt(_0x3f4de4)]);this['_saveMetaData'](this['_lastTo'],_0x492936,this['_markers'],_0xb84af2);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0x4f890f,_0x353e3a,_0x54f1f1,_0xa875f2){const _0x212390=new Map(_0x353e3a),_0x3a9824=new Map(_0x8c5550(_0xa875f2)),_0x295916=new Map();for(const [_0xfc152a,_0x5c8b30]of _0x54f1f1)_0x295916['set'](_0xfc152a,{'start':_0x5c8b30['start']['clone'](),'end':_0x5c8b30['end']['clone'](),'rootName':_0x5c8b30['root']['rootName']});this['_savedMetaData']['set'](_0x4f890f,{'roots':_0x212390,'markers':_0x295916,'rootsAttributes':_0x3a9824});}['_removeMetaData'](_0x242cb1){this['_savedMetaData']['delete'](_0x242cb1);}['_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'](_0x51cfdc,_0x4fd686=null){let _0xb18c96=null;_0x51cfdc['is']('documentFragment')||(_0xb18c96=new _0x46d26f(_0x51cfdc['name'],{'vid_start':null===_0x4fd686?this['_revisionId']++:_0x4fd686++}));const _0x5b25c5=[];for(const _0x5189ec of _0x51cfdc['getChildren']())if(_0x5189ec['is']('element')){_0x5b25c5['push'](this['_makeIdsRoot'](_0x5189ec,_0x4fd686));const _0x14341a=_0x5b25c5[_0x5b25c5['length']-0x1];null!==_0x4fd686&&(_0x4fd686=_0x14341a['is']('element','$text')?_0x14341a['getAttribute']('vid')+0x1:_0x14341a['getAttribute']('vid_end')+0x1);}else{for(let _0x518f86=0x0;_0x518f86<_0x5189ec['offsetSize'];_0x518f86++)_0x5b25c5['push'](new _0x46d26f('$text',{'vid':null===_0x4fd686?this['_revisionId']++:_0x4fd686++}));}if(_0x51cfdc['is']('documentFragment')){const _0x57e8b1=wt(_0x51cfdc['rootName'],_0x51cfdc['name']);return _0x57e8b1['_insertChild'](0x0,_0x5b25c5),_0x57e8b1;}return _0xb18c96['_setAttribute']('vid_end',null===_0x4fd686?this['_revisionId']++:_0x4fd686++),_0xb18c96['_insertChild'](0x0,_0x5b25c5),_0xb18c96;}['_calculateMetaData'](_0x71d2b6,_0x359751,_0xf3f40f){this['_reset']();const {roots:_0x497925,markers:_0x276976,rootsAttributes:_0x43d613}=this['_savedMetaData']['get'](_0x71d2b6);this['_baseRoots']=new Map(_0x497925),this['_baseRootsAttributes']=new Map(_0x8c5550(_0x43d613));for(const [_0x2f9351,_0x3f6294]of this['_baseRoots'])if('$graveyard'!==_0x2f9351&&(this['_diffRoots']['set'](_0x2f9351,gt(_0x3f6294)),this['_diffRootsAttributes']=new Map(_0x8c5550(_0x43d613)),_0xf3f40f)){const _0x251ed0=this['_revisionId'];this['_idsRoots']['set'](_0x2f9351,this['_makeIdsRoot'](_0x3f6294)),this['_baseIdsRoots']['set'](_0x2f9351,this['_makeIdsRoot'](_0x3f6294,_0x251ed0));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',gt(this['_baseRoots']['get']('$graveyard'))),_0xf3f40f&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x1ff339,_0x58f781]of _0x276976){const _0x4c87bb=this['_baseRoots']['get'](_0x58f781['rootName']),_0x400a2b=this['_diffRoots']['get'](_0x58f781['rootName']),_0x493579=new _0xa8802c(this['_fixPosition'](_0x58f781['start'],_0x4c87bb),this['_fixPosition'](_0x58f781['end'],_0x4c87bb)),_0x4d3a48=this['_fixRange'](_0x493579,_0x400a2b);_0x4c87bb['markers']['set'](_0x1ff339,_0x493579),this['_markers']['set'](_0x1ff339,_0x4d3a48);}this['_applyOperations'](_0x71d2b6,_0x359751,_0xf3f40f);}['_applyOperations'](_0xe16e56,_0x12d519,_0x401274){for(const _0x5bc536 of this['source']['getOperations'](_0xe16e56,_0x12d519))this['_handleOperation'](_0x5bc536,_0x401274);for(const _0x268993 of this['_diffRoots']['values']())_0x268993['markers']['clear']();for(const [_0x57ab43,_0x32c083]of this['_markers']){this['_diffRoots']['get'](_0x32c083['root']['rootName'])['markers']['set'](_0x57ab43,_0x32c083['clone']());}const _0x29ae54=new Map(),_0x16acdd=new Map();for(const [_0x2cd0ed,_0x486b34]of this['_diffRoots'])_0x29ae54['set'](_0x2cd0ed,gt(_0x486b34)),_0x16acdd['set'](_0x2cd0ed,this['_diffRootsAttributes']['get'](_0x2cd0ed));this['_saveMetaData'](_0x12d519,_0x29ae54,this['_markers'],_0x16acdd);}['_getPreviousFrom'](_0x42ccd6){const _0x3d8500=Array['from'](this['_savedMetaData']['keys']());_0x3d8500['sort']((_0x3f7b1e,_0x110bc1)=>_0x3f7b1e-_0x110bc1),_0x3d8500['reverse']();for(const _0x451b8c of _0x3d8500)if(_0x451b8c<_0x42ccd6)return _0x451b8c;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0xf6b1ae,_0x31ebde){const _0x344456=Array['from'](_0x31ebde['markers'])['map'](([_0x26eb8a,_0x16ec26])=>[_0x26eb8a,this['_fixRange'](_0x16ec26,_0xf6b1ae)]);_0xf6b1ae['markers']=new Map(_0x344456);}['_transformMarkers'](_0x502668){for(const _0x3a8607 of this['_markers']['values']()){const _0x199645=_0x3a8607['getTransformedByOperation'](_0x502668),_0xd35267=_0xa8802c['_createFromRanges'](_0x199645);_0x3a8607['start']=_0xd35267['start'],_0x3a8607['end']=_0xd35267['end'];}}['_handleOperation'](_0x5f203e,_0x3d8baf){if('addRoot'!=_0x5f203e['type']&&'detachRoot'!=_0x5f203e['type']){if('insert'==_0x5f203e['type']){const _0x516341=_0x5f203e['position']['root'],_0xded08d=_0x516341['rootName'],_0x22033e=_0x516341['name'];this['_diffRoots']['has'](_0xded08d)||(this['_diffRoots']['set'](_0xded08d,wt(_0xded08d,_0x22033e,!0x0)),this['_diffRootsAttributes']['set'](_0xded08d,{}),_0x3d8baf&&this['_idsRoots']['set'](_0xded08d,wt(_0xded08d,_0x22033e,!0x0)));}else{if('addRootAttribute'==_0x5f203e['type']||'removeRootAttribute'==_0x5f203e['type']||'changeRootAttribute'==_0x5f203e['type'])return void this['_handleRootAttributeOperation'](_0x5f203e);'marker'==_0x5f203e['type']&&this['_handleMarkerOperation'](_0x5f203e);}if('marker'!==_0x5f203e['type']){const _0x4d0984=this['_cloneOperation'](_0x5f203e,this['_diffRoots']);_0x4d0984['_execute'](),this['_transformMarkers'](_0x4d0984);}if(_0x3d8baf)switch(_0x5f203e['type']){case'insert':this['_handleInsertOperation'](_0x5f203e);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x5f203e);break;case'merge':this['_handleMergeOperation'](_0x5f203e);break;case'split':this['_handleSplitOperation'](_0x5f203e);}}else this['_handleRootOperation'](_0x5f203e,_0x3d8baf);}['_cloneOperation'](_0x572ade,_0x39a48a){const _0x3c9641=_0x572ade['clone']();return _0x3c9641['_authorId']=_0x572ade['_authorId'],this['_fixOperation'](_0x3c9641,_0x39a48a),_0x3c9641;}['_getBaseVids'](_0x469ce3){return _0x469ce3['map'](_0xb10902=>{const _0x193f78=this['_getVidAttributeName'](_0xb10902);return Number(_0xb10902['item']['getAttribute'](_0x193f78));});}['_generateTape'](_0x16873e,_0x5b3e11){if(_0x16873e['is']('element','$text'))_0x5b3e11['push']({'item':_0x16873e,'type':'text'});else{_0x16873e['is']('element')&&_0x5b3e11['push']({'item':_0x16873e,'type':'elementStart'});for(const _0x26501a of _0x16873e['getChildren']())this['_generateTape'](_0x26501a,_0x5b3e11);_0x16873e['is']('element')&&_0x5b3e11['push']({'item':_0x16873e,'type':'elementEnd'});}return _0x5b3e11;}['_getState'](){const _0x32e8f1=new Map(this['_touched']),_0x517942=new Map(_0x32e8f1),_0xe11ea5=new Map(),_0x1e4185={'insertions':{},'deletions':{}},_0x39c24a={'insertions':{},'deletions':{}},_0x10cb30=new Map(),_0x3ee65b=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]),_0x21a4e7=new Map();_0x3ee65b['delete']('$graveyard');for(const _0x561e4b of _0x3ee65b){const _0x5d6d67=(this['_diffRoots']['get'](_0x561e4b)??this['_baseRoots']['get'](_0x561e4b))['name'],_0x2a2107=this['_diffRoots']['get'](_0x561e4b)||wt(_0x561e4b,_0x5d6d67,!0x1),_0x56cf55=this['_baseRoots']['get'](_0x561e4b)||wt(_0x561e4b,_0x5d6d67,!0x1);_0x2a2107['isAttached']()||_0x56cf55['isAttached']()?(_0x21a4e7['set'](_0x561e4b,_0x5d6d67),_0x1e4185['insertions'][_0x561e4b]=gt(_0x2a2107),_0x1e4185['deletions'][_0x561e4b]=gt(_0x56cf55),this['_copyMarkers'](_0x1e4185['deletions'][_0x561e4b],_0x56cf55),this['_copyMarkers'](_0x1e4185['insertions'][_0x561e4b],_0x2a2107),_0x39c24a['insertions'][_0x561e4b]=this['_generateTape'](this['_idsRoots']['get'](_0x561e4b),[]),_0x39c24a['deletions'][_0x561e4b]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x561e4b)||wt(_0x561e4b,_0x5d6d67,!0x1),[])):_0x3ee65b['delete'](_0x561e4b);}for(const _0x1c4dd4 of _0x3ee65b){const _0x5e54e9=_0x39c24a['insertions'][_0x1c4dd4];for(const _0x3cba97 of _0x5e54e9){const _0x197fd0=this['_getVidAttributeName'](_0x3cba97),_0x25f53a=_0x3cba97['item']['getAttribute'](_0x197fd0);_0x517942['delete'](_0x25f53a),_0x25f53a>=this['_startingRevisionId']&&_0xe11ea5['set'](_0x25f53a,_0x32e8f1['get'](_0x25f53a));}}for(const _0x36ca0d of _0x3ee65b){const _0x3f2d56=_0x39c24a['insertions'][_0x36ca0d],_0x5add97=this['_getBaseVids'](_0x39c24a['deletions'][_0x36ca0d]);let _0x31d4a8=0x0;for(const _0x4b3695 of _0x3f2d56){const _0x2dd340=this['_getVidAttributeName'](_0x4b3695),_0x3f2f70=_0x4b3695['item']['getAttribute'](_0x2dd340);if(!_0xe11ea5['has'](_0x3f2f70)&&!_0x10cb30['has'](_0x3f2f70)){if(_0x517942['has'](_0x3f2f70))_0x31d4a8++;else{if(_0x3f2f70!=_0x5add97[_0x31d4a8]){const _0x16ab01=_0x32e8f1['get'](_0x3f2f70)||_0x32e8f1['get'](_0x5add97[_0x31d4a8]);for(;_0x3f2f70!=_0x5add97[_0x31d4a8];)_0x517942['has'](_0x5add97[_0x31d4a8])||(_0x10cb30['set'](_0x5add97[_0x31d4a8],_0x16ab01),_0x32e8f1['set'](_0x5add97[_0x31d4a8],_0x16ab01)),_0x31d4a8++;}_0x31d4a8++;}}}}for(const _0x481365 of _0x3ee65b){const _0x1053d0=_0x39c24a['insertions'][_0x481365];for(const _0x1a6049 of _0x1053d0){const _0x3c6d17=this['_getVidAttributeName'](_0x1a6049),_0x22a8b2=_0x1a6049['item']['getAttribute'](_0x3c6d17);if(_0x10cb30['has'](_0x22a8b2)){const _0x3a0224=_0x10cb30['get'](_0x22a8b2);_0x517942['has'](_0x22a8b2)||_0x517942['set'](_0x22a8b2,{..._0x3a0224}),_0xe11ea5['set'](_0x22a8b2,{..._0x3a0224});}}}for(const _0x16e062 of _0x517942['keys']())_0x16e062>=this['_startingRevisionId']&&_0x517942['delete'](_0x16e062);const _0x215c00=new Map();for(const _0x37fd1a of _0x3ee65b){let _0x59ab1f=_0x39c24a['insertions'][_0x37fd1a];for(const _0x4b2cf4 of _0x59ab1f)if(_0x4b2cf4['item']['is']('element','tableCell')){const _0xf1ec7e=this['_getVidAttributeName'](_0x4b2cf4),_0x5a41d8=_0x4b2cf4['item']['getAttribute'](_0xf1ec7e);if(_0xe11ea5['has'](_0x5a41d8)){const _0x43d712=_0x4b2cf4['item']['parent']['parent']['getAttribute']('vid_start'),_0x58facd=_0x215c00['get'](_0x43d712)||new Set();_0x58facd['add'](_0xe11ea5['get'](_0x5a41d8)['userId']),_0x215c00['set'](_0x43d712,_0x58facd);}}_0x59ab1f=_0x39c24a['deletions'][_0x37fd1a];for(const _0x182e11 of _0x59ab1f)if(_0x182e11['item']['is']('element','tableCell')){const _0x44bc24=this['_getVidAttributeName'](_0x182e11),_0x1c43d7=_0x182e11['item']['getAttribute'](_0x44bc24);if(_0x517942['has'](_0x1c43d7)){const _0x174d00=_0x182e11['item']['parent']['parent']['getAttribute']('vid_start'),_0x1c7ec9=_0x215c00['get'](_0x174d00)||new Set();_0x1c7ec9['add'](_0x517942['get'](_0x1c43d7)['userId']),_0x215c00['set'](_0x174d00,_0x1c7ec9);}}for(const _0x991cbe of _0x215c00['keys']())(_0xe11ea5['has'](_0x991cbe)||_0x517942['has'](_0x991cbe))&&_0x215c00['delete'](_0x991cbe);}for(const _0x2963ba of _0x3ee65b){const _0x361207=_0x39c24a['insertions'][_0x2963ba];let _0x1dc649=null,_0x5eefa8=null;for(const _0xad7e45 of _0x361207){const _0x48b5a7=this['_getVidAttributeName'](_0xad7e45),_0xc31246=_0xad7e45['item']['getAttribute'](_0x48b5a7),_0x3b1b3f=_0x215c00['get'](_0xc31246);_0x3b1b3f&&'elementStart'==_0xad7e45['type']&&(_0x1dc649=Array['from'](_0x3b1b3f)[0x0],_0x5eefa8=_0xad7e45['item']['getAttribute']('vid_end')),_0x1dc649&&(_0x517942['set'](_0xc31246,{'userId':_0x1dc649}),_0xe11ea5['set'](_0xc31246,{'userId':_0x1dc649})),_0xc31246==_0x5eefa8&&(_0x1dc649=null,_0x5eefa8=null);}}const _0x22e1a1={},_0xcaa8f7=new Set();for(const _0xd6eff of _0x3ee65b){const _0x31bc05=_0x1e4185['deletions'][_0xd6eff],_0x4a3c69=_0x1e4185['insertions'][_0xd6eff];for(const {userId:_0x27730a}of this['_touchedMarkers']['values']())null!==_0x27730a&&_0xcaa8f7['add'](_0x27730a);for(const {userId:_0x4e3642}of this['_touchedRoots']['values']())null!==_0x4e3642&&_0xcaa8f7['add'](_0x4e3642);this['_markChanges'](_0x4a3c69,_0x39c24a['insertions'][_0xd6eff],_0xe11ea5,'insertion',_0xcaa8f7),this['_markChanges'](_0x31bc05,_0x39c24a['deletions'][_0xd6eff],_0x517942,'deletion',_0xcaa8f7),_0x22e1a1[_0xd6eff]={'insertions':this['_prepareViewToSave'](_0x4a3c69),'deletions':this['_prepareViewToSave'](_0x31bc05),'attachChange':this['_touchedRoots']['get'](_0xd6eff)||null,'attributesBefore':_0x8c5550(this['_baseRootsAttributes']['get'](_0xd6eff))||{},'attributesAfter':_0x8c5550(this['_diffRootsAttributes']['get'](_0xd6eff)),'rootElementName':_0x21a4e7['get'](_0xd6eff)};}return{'diffData':_0x22e1a1,'authorsIds':Array['from'](_0xcaa8f7)};}['_processRootBeforeSave'](_0x4d42fe){for(const [,_0x4472c6]of _0x4d42fe['markers']){const _0x2a1b6d=_0x4472c6['start']['getAncestors']()['filter'](_0x32e81b=>'tableCell'==_0x32e81b['name']);for(const _0x35a162 of _0x2a1b6d)0x1==_0x35a162['childCount']&&_0x35a162['getChild'](0x0)['is']('element','paragraph')&&_0x35a162['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x5c6af6){this['_processRootBeforeSave'](_0x5c6af6);const _0x2ba76a=this['editor']['data']['toView'](_0x5c6af6,{}),_0x81cd09=Array['from'](_0x2ba76a['getChildren']())['map'](_0x24127b=>this['_getViewJson'](_0x24127b));return JSON['stringify'](_0x81cd09);}['_getViewJson'](_0x4723a9){if(_0x4723a9['is']('$text'))return _0x4723a9['data'];{const _0x3970a2=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0x517df2=_0x4723a9,_0x4123fe=this['editor']['data']['htmlProcessor']['domConverter'],_0x17b8ec={'type':_0x3970a2['_getTypeCharForViewElement'](_0x517df2),'name':_0x517df2['name'],'attributes':Array['from'](_0x517df2['getAttributes']()),'children':Array['from'](_0x517df2['getChildren']())['map'](_0x469e84=>this['_getViewJson'](_0x469e84))};if(_0x4723a9['is']('uiElement')&&'$comment'!=_0x4723a9['name']){const _0x52c1b8=_0x4723a9['render'](_0x4123fe['domDocument'],_0x4123fe);_0x17b8ec['children']['push'](_0x52c1b8['outerHTML']);}else{if(_0x4723a9['is']('rawElement')){const _0x3cb671=_0x4123fe['domDocument']['createElement'](_0x517df2['name']);_0x4723a9['render'](_0x3cb671,_0x4123fe),_0x17b8ec['children']['push'](_0x3cb671['innerHTML']);}}const _0x415623=Array['from'](_0x517df2['getCustomProperties']());_0x415623['length']>0x0&&(_0x17b8ec['customProperties']=_0x415623);const _0x1bc014=_0x517df2['getFillerOffset']();return null!==_0x1bc014&&(_0x17b8ec['fillerOffset']=_0x1bc014),_0x17b8ec;}}['_markChanges'](_0x5850af,_0x3eae41,_0x35197e,_0x2c421c,_0x30f1b4){let _0x4e52a7=null,_0x54b41d=null,_0x2b4d0a=0x0;const _0x28f694=this['editor']['model'];for(let _0x374f70=0x0;_0x374f70<_0x3eae41['length'];_0x374f70++){const _0x5dfde2=this['_getVidAttributeName'](_0x3eae41[_0x374f70]),_0xe52493=_0x3eae41[_0x374f70]['item']['getAttribute'](_0x5dfde2),_0x4069e5=_0x35197e['get'](_0xe52493),_0x47d802=_0x374f70==_0x3eae41['length']-0x1;(!_0x4e52a7&&_0x4069e5&&(_0x4e52a7=_0x4069e5,_0x54b41d=_0x3eae41[_0x374f70]),_0x4e52a7&&(!_0x4069e5||_0x4069e5['userId']!=_0x4e52a7['userId']))&&(_0x36f0a7(_0x4069e5,mt(_0x54b41d,_0x5850af,_0x28f694),mt(_0x3eae41[_0x374f70],_0x5850af,_0x28f694)),_0x4e52a7=_0x4069e5||null,_0x54b41d=_0x4069e5?_0x3eae41[_0x374f70]:null),_0x4e52a7&&_0x47d802&&_0x36f0a7(_0x4069e5,mt(_0x54b41d,_0x5850af,_0x28f694),pt(_0x3eae41[_0x374f70],_0x5850af,_0x28f694));}function _0x36f0a7(_0x50243e,_0x4345de,_0x3e580c){const _0x55b49=_0x4e52a7['userId'],_0x1344ae='revision:'+_0x2c421c+':'+_0x55b49+':'+_0x2b4d0a++,_0x42d8df=_0x28f694['createRange'](_0x4345de,_0x3e580c);_0x5850af['markers']['set'](_0x1344ae,_0x42d8df),null!==_0x55b49&&_0x30f1b4['add'](_0x55b49);}}['_getVidAttributeName'](_0x46068d){switch(_0x46068d['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x12cf26,_0x38bb9e){_0x12cf26['baseVersion']=null;for(const _0x16d468 in _0x12cf26){const _0x34a8ae=_0x12cf26[_0x16d468];if(_0x34a8ae instanceof _0x10f6fa){const _0x1678ed=_0x38bb9e['get'](_0x34a8ae['root']['rootName']);_0x12cf26[_0x16d468]=this['_fixPosition'](_0x34a8ae,_0x1678ed);}if(_0x34a8ae instanceof _0xa8802c){const _0x4065d7=_0x38bb9e['get'](_0x34a8ae['root']['rootName']);_0x12cf26[_0x16d468]=this['_fixRange'](_0x34a8ae,_0x4065d7);}'root'===_0x16d468&&(_0x12cf26['root']=_0x38bb9e['get'](_0x12cf26['root']['rootName']));}}['_fixRange'](_0x22c10a,_0x28db87){return this['editor']['model']['createRange'](this['_fixPosition'](_0x22c10a['start'],_0x28db87),this['_fixPosition'](_0x22c10a['end'],_0x28db87));}['_fixPosition'](_0x1dab09,_0x3d987a){return this['editor']['model']['createPositionFromPath'](_0x3d987a,_0x1dab09['path'],_0x1dab09['stickiness']);}['_handleInsertOperation'](_0x15e7c2){const _0x5511fb=this['_idsRoots']['get'](_0x15e7c2['position']['root']['rootName']),_0x21d529=this['_fixPosition'](_0x15e7c2['position'],_0x5511fb),_0x9e9774=null===_0x15e7c2['_authorId']?null:_0x15e7c2['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x3ab51c=_0x21d529['parent'],_0xd16ecc=this['_revisionId'],_0x4521d7=[];for(const _0xd4730f of _0x15e7c2['nodes'])if(_0xd4730f['is']('element'))_0x4521d7['push'](this['_makeIdsRoot'](_0xd4730f));else{for(let _0x3cea2e=0x0;_0x3cea2e<_0xd4730f['offsetSize'];_0x3cea2e++)_0x4521d7['push'](new _0x46d26f('$text',{'vid':this['_revisionId']++}));}const _0xa5968c=this['_revisionId'];for(let _0x3010f3=_0xd16ecc;_0x3010f3<_0xa5968c;_0x3010f3++)this['_touched']['set'](_0x3010f3,{'userId':_0x9e9774});_0x3ab51c['_insertChild'](_0x21d529['offset'],_0x4521d7);}['_handleMoveOperation'](_0x41fd63){(_0x41fd63=this['_cloneOperation'](_0x41fd63,this['_idsRoots']))['_execute']();const _0xb4d941=null===_0x41fd63['_authorId']?null:_0x41fd63['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x4bb2c9=_0x41fd63['getMovedRangeStart'](),_0x40c354=_0x4bb2c9['parent'],_0x4fc2dd=_0x4bb2c9['offset'];!function _0xd00e9c(_0x26143d,_0x3128cc,_0x2384b0,_0x4778db){for(let _0xaf4fca=_0x2384b0;_0xaf4fca<_0x4778db;_0xaf4fca++){const _0x3b2859=_0x3128cc['getChild'](_0xaf4fca);_0x3b2859['is']('element','$text')?_0x26143d['set'](_0x3b2859['getAttribute']('vid'),{'userId':_0xb4d941}):(_0x26143d['set'](_0x3b2859['getAttribute']('vid_start'),{'userId':_0xb4d941}),_0xd00e9c(_0x26143d,_0x3b2859,0x0,_0x3b2859['childCount']),_0x26143d['set'](_0x3b2859['getAttribute']('vid_end'),{'userId':_0xb4d941}));}}(this['_touched'],_0x40c354,_0x4fc2dd,_0x4fc2dd+_0x41fd63['howMany']);}['_handleMergeOperation'](_0x3ba458){const _0x5e020f=null===(_0x3ba458=this['_cloneOperation'](_0x3ba458,this['_idsRoots']))['_authorId']?null:_0x3ba458['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x3c7e0a=_0x3ba458['targetPosition']['parent'],_0x3f042f=_0x3ba458['sourcePosition']['parent'],_0x441931=_0x3c7e0a['getAttribute']('vid_end'),_0x584552=_0x3f042f['getAttribute']('vid_start');_0x3c7e0a['_setAttribute']('vid_end',_0x3f042f['getAttribute']('vid_end')),_0x3f042f['_setAttribute']('vid_end',_0x441931),this['_touched']['set'](_0x584552,{'userId':_0x5e020f}),this['_touched']['set'](_0x441931,{'userId':_0x5e020f}),_0x3ba458['_execute']();}['_handleSplitOperation'](_0x180775){const _0x46bd48=null===(_0x180775=this['_cloneOperation'](_0x180775,this['_idsRoots']))['_authorId']?null:_0x180775['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x414665=_0x180775['graveyardPosition'],_0x5f3f48=_0x180775['splitPosition']['parent'];_0x180775['_execute']();const _0x566450=_0x5f3f48['getAttribute']('vid_end'),_0x5020eb=_0x180775['insertionPosition']['nodeAfter'];if(_0x414665){const _0x4fdc97=_0x5020eb['getAttribute']('vid_end'),_0x22afc5=_0x5f3f48['getAttribute']('vid_end');_0x5f3f48['_setAttribute']('vid_end',_0x4fdc97),_0x5020eb['_setAttribute']('vid_end',_0x22afc5),this['_touched']['set'](_0x5f3f48['getAttribute']('vid_end'),{'userId':_0x46bd48}),this['_touched']['set'](_0x5020eb['getAttribute']('vid_start'),{'userId':_0x46bd48});}else{const _0x28ca35=this['_revisionId']++,_0x10808f=this['_revisionId']++;_0x5f3f48['_setAttribute']('vid_end',_0x28ca35),_0x5020eb['_setAttribute']('vid_start',_0x10808f),_0x5020eb['_setAttribute']('vid_end',_0x566450),this['_touched']['set'](_0x28ca35,{'userId':_0x46bd48}),this['_touched']['set'](_0x10808f,{'userId':_0x46bd48});}}['_handleMarkerOperation'](_0x4d5f2c){if(!_0x4d5f2c['affectsData'])return;const _0x25fe3c=(_0x4d5f2c=this['_cloneOperation'](_0x4d5f2c,this['_diffRoots']))['oldRange']?_0x4d5f2c['oldRange']['root']:null,_0x4ea0f1=_0x4d5f2c['newRange']?_0x4d5f2c['newRange']['root']:null;_0x25fe3c&&this['_markers']['delete'](_0x4d5f2c['name']),_0x4ea0f1&&this['_markers']['set'](_0x4d5f2c['name'],_0x4d5f2c['newRange']['clone']());const _0x5e25b0=null===_0x4d5f2c['_authorId']?null:_0x4d5f2c['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x36a9c4=_0x4d5f2c['name'];if(!this['_touchedMarkers']['has'](_0x36a9c4))return void this['_touchedMarkers']['set'](_0x36a9c4,{'range':_0x4d5f2c['oldRange'],'userId':_0x5e25b0});const _0x5ee2df=this['_touchedMarkers']['get'](_0x36a9c4),_0x5b806f=_0x5ee2df['range'],_0x3e57db=_0x4d5f2c['newRange'];null==_0x5b806f&&null==_0x3e57db||_0x5b806f&&_0x3e57db&&_0x5b806f['isEqual'](_0x3e57db)?this['_touchedMarkers']['delete'](_0x4d5f2c['name']):_0x5ee2df['userId']=_0x5e25b0;}['_handleRootOperation'](_0x29a9e2,_0x37652){this['_diffRoots']['has'](_0x29a9e2['rootName'])?this['_diffRoots']['get'](_0x29a9e2['rootName'])['_isAttached']=_0x29a9e2['isAdd']:(this['_diffRoots']['set'](_0x29a9e2['rootName'],wt(_0x29a9e2['rootName'],_0x29a9e2['elementName'],!0x0)),this['_diffRootsAttributes']['set'](_0x29a9e2['rootName'],{}),_0x37652&&this['_idsRoots']['set'](_0x29a9e2['rootName'],wt(_0x29a9e2['rootName'],_0x29a9e2['elementName'],!0x0)));const _0x1bde0f=null===_0x29a9e2['_authorId']?null:_0x29a9e2['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x31661c=this['_touchedRoots']['get'](_0x29a9e2['rootName']);_0x31661c&&_0x31661c['userId']===_0x1bde0f?this['_touchedRoots']['delete'](_0x29a9e2['rootName']):this['_touchedRoots']['set'](_0x29a9e2['rootName'],{'userId':_0x1bde0f,'isAttached':_0x29a9e2['isAdd']});}['_handleRootAttributeOperation'](_0x482cd0){const _0x53a3c7=this['_diffRootsAttributes']['get'](_0x482cd0['root']['rootName']);null===_0x482cd0['newValue']?delete _0x53a3c7[_0x482cd0['key']]:_0x53a3c7[_0x482cd0['key']]=_0x482cd0['newValue'];}}function gt(_0x5b7250){const _0x6e69ca=wt(_0x5b7250['rootName'],_0x5b7250['name'],_0x5b7250['isAttached']());for(const _0xe954d5 of _0x5b7250['getChildren']()){const _0x279586=_0xe954d5['_clone'](!0x0);_0x6e69ca['_appendChild'](_0x279586);}return _0x6e69ca;}function wt(_0x5cfaa0,_0x3ffb37,_0x4de986=!0x0){const _0x5301ff=new _0x59fcbe();return _0x5301ff['rootName']=_0x5cfaa0,_0x5301ff['name']=_0x3ffb37,_0x5301ff['_isAttached']=_0x4de986,_0x5301ff['isAttached']=()=>_0x5301ff['_isAttached'],_0x5301ff;}function mt(_0x5a0253,_0x58073d,_0x478435){const _0x5bea26='elementEnd'==_0x5a0253['type']?_0x478435['createPositionAt'](_0x5a0253['item'],'end'):_0x478435['createPositionBefore'](_0x5a0253['item']);return _0x478435['createPositionFromPath'](_0x58073d,_0x5bea26['path'],_0x5bea26['stickiness']);}function pt(_0xd0b542,_0x413ef8,_0x51d605){const _0xc66955='elementStart'==_0xd0b542['type']?_0x51d605['createPositionAt'](_0xd0b542['item'],0x0):_0x51d605['createPositionAfter'](_0xd0b542['item']);return _0x51d605['createPositionFromPath'](_0x413ef8,_0xc66955['path'],_0xc66955['stickiness']);}class RevisionHistorySaveRevisionFormView extends/* #__PURE__ -- @preserve */
|
|
25
|
+
_0x151f05(_0xafec90){['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0xfe7fa8,_0x339212){super(_0xfe7fa8),this['focusTracker']=new _0x28ca2c(),this['keystrokes']=new _0x2f638f(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x339212),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'](),_0x33eb0a({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x26f1e1=_0x3ec8c0=>_0x3ec8c0['stopPropagation']();this['keystrokes']['set']('arrowright',_0x26f1e1),this['keystrokes']['set']('arrowleft',_0x26f1e1),this['keystrokes']['set']('arrowup',_0x26f1e1),this['keystrokes']['set']('arrowdown',_0x26f1e1);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x4d3635){this['revisionNameInputView']['fieldView']['element']['value']=_0x4d3635['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x5890ab){const _0x161b39=new _0x17e56b(this['locale'],_0x238b41),_0x1eb624=_0x161b39['fieldView'];_0x1eb624['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x590dff=ft(this['locale'],'Name\x20of\x20the\x20revision');return!_0x5890ab&&(_0x590dff+='\x20('+ft(this['locale'],'optional')+')'),(_0x161b39['label']=_0x590dff,_0x1eb624['on']('input',()=>{this['revisionNameInputValue']=_0x1eb624['element']['value']['trim']();}),_0x161b39);}}class RevisionHistoryUI extends _0x538071{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[RevisionTracker];}['_saveRevisionFormView'];['init'](){const _0x38749d=this['editor'],_0x28c204=_0x38749d['plugins']['get']('RevisionTracker');_0x38749d['ui']['componentFactory']['add']('revisionHistory',_0x3cbb7c=>{const _0x3378a2=_0x182132(_0x3cbb7c),_0x46b311=_0x3378a2['panelView']['children'],_0x5cfb71=new _0x44c12a(_0x3cbb7c),_0x57f7bb=new _0x4582a8(_0x3cbb7c),_0x17e2b8=this['_createSaveRevisionButton'](_0x135801),_0x168889=new _0x4582a8(_0x3cbb7c),_0x1aec2b=this['_createOpenRevisionButton'](_0x135801);return _0x3378a2['bind']('isEnabled')['to'](_0x28c204,'isReady',_0x28c204,'isEnabled',_0x38749d,'isReadOnly',(_0x3a8b78,_0x280dc1,_0x2c94fa)=>_0x3a8b78&&_0x280dc1&&!_0x2c94fa),_0x3378a2['buttonView']['set']({'icon':_0x5ea9e8,'label':ft(_0x3cbb7c,'Revision\x20history'),'tooltip':!0x0}),_0x17e2b8['set']({'withText':!0x0,'role':'menuitem'}),_0x1aec2b['set']({'withText':!0x0,'role':'menuitem'}),this['listenTo'](_0x1aec2b,'execute',()=>{_0x3378a2['isOpen']=!0x1,_0x38749d['editing']['view']['focus']();},{'priority':'low'}),_0x57f7bb['children']['add'](_0x17e2b8),_0x168889['children']['add'](_0x1aec2b),_0x5cfb71['role']='menu',_0x5cfb71['items']['addMany']([_0x57f7bb,_0x168889]),_0x46b311['add'](_0x5cfb71),_0x3378a2;}),_0x38749d['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x4f0c61=this['editor'],_0x453a89=_0x4f0c61['locale'],_0x453312=_0x4f0c61['plugins']['get']('RevisionTracker'),_0x896a83=new _0x48deab(_0x453a89),_0x593d62=new _0x41b7d1(_0x453a89);_0x896a83['bind']('isEnabled')['to'](_0x453312,'isReady',_0x453312,'isEnabled',_0x4f0c61,'isReadOnly',(_0x471ca6,_0x3f96a0,_0x4d4944)=>_0x471ca6&&_0x3f96a0&&!_0x4d4944),_0x896a83['buttonView']['set']({'icon':_0x5ea9e8,'label':ft(_0x453a89,'Revision\x20history')});const _0x2608c4=new tt(_0x453a89,_0x896a83),_0x495459=this['_createSaveRevisionButton'](it);_0x495459['delegate']('execute')['to'](_0x896a83),_0x2608c4['children']['add'](_0x495459),_0x593d62['items']['add'](_0x2608c4);const _0x1eb7eb=new tt(_0x453a89,_0x896a83),_0x271a18=this['_createOpenRevisionButton'](it);return _0x271a18['delegate']('execute')['to'](_0x896a83),_0x1eb7eb['children']['add'](_0x271a18),_0x593d62['items']['add'](_0x1eb7eb),_0x896a83['panelView']['children']['add'](_0x593d62),_0x896a83;}['_createSaveRevisionButton'](_0x5398a5){const _0x4a5261=this['editor'],_0x3534d4=_0x4a5261['plugins']['get']('RevisionTracker'),_0x2315b6=new _0x5398a5(_0x4a5261['locale']);return _0x2315b6['set']({'label':ft(_0x4a5261['locale'],'Save\x20current\x20revision')}),_0x2315b6['bind']('isEnabled')['to'](_0x3534d4,'isReady',_0x3534d4,'isEnabled',_0x4a5261,'isReadOnly',(_0x95cec3,_0x2c45f1,_0x2e4e40)=>_0x95cec3&&_0x2c45f1&&!_0x2e4e40),this['listenTo'](_0x2315b6,'execute',()=>{this['_showDialog']();}),_0x2315b6;}['_createOpenRevisionButton'](_0x10ddf7){const _0xbdf08=this['editor'],_0x1baffd=_0xbdf08['plugins']['get']('RevisionTracker'),_0x552029=new _0x10ddf7(_0xbdf08['locale']);return _0x552029['set']({'label':ft(_0xbdf08['locale'],'Open\x20revision\x20history')}),_0x552029['bind']('isEnabled')['to'](_0x1baffd,'isReady',_0xbdf08,'isReadOnly',(_0x284df5,_0x76b3bf)=>_0x284df5&&!_0x76b3bf),this['listenTo'](_0x552029,'execute',()=>{_0xbdf08['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x552029;}['_showDialog'](){const _0x3f0b7b=this['editor'],_0x31111e=_0x3f0b7b['locale'],_0x39f321=_0x3f0b7b['plugins']['get']('Dialog'),_0x1583e2=_0x3f0b7b['plugins']['get']('RevisionTracker');function _0x182f40(_0x248563){_0x3f0b7b['config']['get']('revisionHistory.requireRevisionName')&&''===_0x248563['revisionName']?_0x248563['revisionNameInputView']['errorText']=ft(_0x31111e,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x3f0b7b['plugins']['get'](RevisionTracker)['saveRevision']({'name':_0x248563['revisionName']}),_0x39f321['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x182f40(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x39f321['show']({'id':'revisionSave','title':ft(_0x31111e,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':ft(_0x3f0b7b['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x39f321['hide']()},{'label':ft(_0x3f0b7b['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x287ee1){_0x287ee1['bind']('isEnabled')['to'](_0x1583e2,'isReady',_0x1583e2,'isEnabled',_0x3f0b7b,'isReadOnly',(_0x3874b8,_0x925459,_0x5e95f3)=>_0x3874b8&&_0x925459&&!_0x5e95f3);},'onExecute':()=>_0x182f40(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0xfd874e=this['editor'],_0x3870b5=_0xfd874e['locale'];this['_saveRevisionFormView']=new RevisionHistorySaveRevisionFormView(_0x3870b5,_0xfd874e['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class ChangeDetailsView extends _0xafec90{['changeId'];['_model'];constructor(_0x443e51,_0x59f26b){super(_0x443e51),this['_model']=_0x59f26b,this['changeId']=_0x59f26b['id'];const _0x7e2ecb=this['bindTemplate'],_0x1757e6=ft(_0x443e51,_0x59f26b['data']['isSuggestion']?'Suggested\x20by':'add'==_0x59f26b['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x59f26b['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x7e2ecb['to']('type',_0x18732f=>'ck-revision-change__'+_0x18732f)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x1757e6}]},{'text':'\x20'+_0x59f26b['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class ChangeItem extends/* #__PURE__ -- @preserve */
|
|
26
|
+
_0xf684e0(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x37dd15){super(),this['id']=_0x37dd15['id']||_0x51ceb2(),this['author']=_0x37dd15['author'],this['type']=_0x37dd15['type'],this['data']=_0x37dd15['data']||{},this['rootName']=_0x37dd15['rootName'],this['set']('createdAt',_0x37dd15['createdAt']);}['toJSON'](){return{'id':this['id'],'authorId':this['author']['id'],'type':this['type'],'data':this['data'],'createdAt':this['createdAt']};}}class RevisionDiff{['newRevisionId'];['oldRevisionId'];['changes'];constructor(_0x3029fd,_0x28b2cc){this['newRevisionId']=_0x3029fd,this['oldRevisionId']=_0x28b2cc,this['changes']=new _0x3625c9();}['_setChanges'](_0x134fe2){for(const _0x405e3d of _0x134fe2)this['changes']['add'](_0x405e3d);}}class RevisionViewer extends _0x538071{['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[_0x2baa1d,et,RevisionsRepository,RevisionHistoryUtils];}constructor(_0x1f6b81){super(_0x1f6b81),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',(_0x2e70a3,_0x44c010,_0x48f2ea)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x8940e5=>{for(const _0x19b166 of this['editor']['editing']['view']['document']['roots'])_0x48f2ea?_0x8940e5['removeClass']('ck-editor__editable__overlay',_0x19b166):_0x8940e5['addClass']('ck-editor__editable__overlay',_0x19b166);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x1b2c12=>null!==_0x1b2c12),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x5cb3da,_0xa89e5c,_0x3022cf)=>_0x5cb3da&&_0x3022cf?_0xa89e5c['changes']['getIndex'](_0x3022cf):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x44925d,_0xe3fdb3)=>_0x44925d?_0xe3fdb3['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](et);}['init'](){const _0x13e5eb=this['editor'],_0x25d4a2=new ShowChangeCommand(_0x13e5eb,{'direction':'backward'}),_0x310e10=new ShowChangeCommand(_0x13e5eb,{'direction':'forward'});(_0x13e5eb['commands']['add']('showPreviousChange',_0x25d4a2),_0x13e5eb['commands']['add']('showNextChange',_0x310e10),_0x13e5eb['commands']['add']('restoreRevision',new RestoreRevisionCommand(_0x13e5eb)),this['on']('change:numberOfChanges',()=>{_0x25d4a2['refresh'](),_0x310e10['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x13e5eb['enableReadOnlyMode']('revision-viewer'),_0x13e5eb['plugins']['has']('WidgetToolbarRepository'))&&_0x13e5eb['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x4815ad){return await this['_utils']['loadRevisionData'](_0x4815ad,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x4815ad);}async['getRevisionRootsAttributes'](_0x250cc2){return await this['_utils']['loadRevisionData'](_0x250cc2,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x250cc2);}async['compare'](_0x4af679,_0x2df7c2,_0x5747a4=!0x1){if(!this['isEnabled'])return;const _0x14688f=this['diff'],_0x1138f5=this['repository'],_0x35aa88='string'==typeof _0x4af679?_0x1138f5['getRevision'](_0x4af679):_0x4af679,_0x588858='string'==typeof _0x2df7c2?_0x1138f5['getRevision'](_0x2df7c2):_0x2df7c2,_0x4e156b=_0x35aa88['id'],_0x342c79=_0x588858?_0x588858['id']:null;if(!_0x5747a4&&this['diff']&&this['diff']['newRevisionId']===_0x4e156b&&this['diff']['oldRevisionId']===_0x342c79)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new RevisionDiff(_0x4e156b,_0x342c79);const _0x474d5d=this['_getRevisionsRange'](_0x35aa88,_0x588858,!0x0)['map'](_0x22c3bc=>this['_utils']['loadRevisionData'](_0x22c3bc,this['adapter']));return _0x474d5d['push'](new Promise(_0xa5bdad=>{setTimeout(_0xa5bdad,0x14);})),Promise['all'](_0x474d5d)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x17d443=this['_getDiff'](_0x4e156b,_0x342c79);for(const _0x360094 of _0x17d443['changes'])this['_changeIdToChange']['set'](_0x360094['id'],_0x360094);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x5835cd=>{for(const _0xb8cba5 of this['editor']['model']['document']['getRootNames']())_0x5835cd['detachRoot'](_0xb8cba5);for(const _0x568b63 of Object['keys'](_0x17d443['model'])){const _0x158d70=_0x17d443['model'][_0x568b63]['name'],_0x578e8d=_0x5835cd['addRoot'](_0x568b63,_0x158d70);for(const _0x102a85 of Object['keys'](_0x17d443['attributes'][_0x568b63]))_0x5835cd['setAttribute'](_0x102a85,_0x17d443['attributes'][_0x568b63][_0x102a85],_0x578e8d);_0x5835cd['insert'](_0x17d443['model'][_0x568b63],_0x578e8d,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x17d443['changes'])),this['isReady']=!0x0;})['catch'](_0x7b6451=>{console['error'](_0x7b6451),this['_cleanUp'](),_0x14688f&&(this['diff']=_0x14688f),this['isReady']=!0x0;});}['addRevisionData'](_0x46b69d,_0x507b66){const _0x5b1fe7=this['repository']['createRevision'](_0x46b69d);return _0x5b1fe7['on']('_update',(_0x2384ef,_0x2f9ced,_0x24b795)=>_0x507b66(_0x2f9ced,_0x24b795,_0x5b1fe7)),this['repository']['addRevision'](_0x5b1fe7),_0x5b1fe7;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x439218=>{for(const _0x451e15 of this['editor']['model']['document']['getRootNames']())_0x439218['detachRoot'](_0x451e15);});}['_sortAndFilterDiffChanges'](_0x228591){const _0x2ae375=[],_0xcd331c=new Map();for(const _0x26baf4 of this['editor']['model']['document']['getRootNames']()){const _0x4fb61e=this['editor']['editing']['view']['getDomRoot'](_0x26baf4);if(!_0x4fb61e)continue;const _0x1f20a0=_0x4fb61e['getClientRects']()['item'](0x0);_0x1f20a0&&(_0x2ae375['push'](_0x26baf4),_0xcd331c['set'](_0x26baf4,_0x1f20a0));}return _0x2ae375['sort']((_0x5c7636,_0x37b74a)=>{const _0x41b7b4=_0xcd331c['get'](_0x5c7636),_0x13697c=_0xcd331c['get'](_0x37b74a);return _0x41b7b4['y']-_0x13697c['y']||_0x41b7b4['x']-_0x13697c['x'];}),(_0x228591=_0x228591['filter'](_0x5ed611=>_0x2ae375['includes'](_0x5ed611['rootName'])))['sort']((_0x2392cb,_0x2d3ed0)=>_0x2ae375['indexOf'](_0x2392cb['rootName'])-_0x2ae375['indexOf'](_0x2d3ed0['rootName'])),_0x228591;}['_makeTape'](_0x585f2f){const _0x1cf1ec=Array['from'](_0x585f2f['markers'])['filter'](([_0x2c51ed,_0x5f0504])=>_0x2c51ed['startsWith']('revision:')&&!_0x5f0504['isCollapsed']),_0x506e7=Array['from'](this['editor']['model']['createRangeIn'](_0x585f2f)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x1cf1ec['length'])for(const _0x12eafa of _0x506e7){const [_0x349f54,_0x5860b1]=_0x1cf1ec[0x0],[,_0x3da456,_0x56982a]=_0x349f54['split'](':');if(_0x5860b1['end']['isEqual'](_0x12eafa['nextPosition'])&&_0x1cf1ec['shift'](),(_0x12eafa['previousPosition']['isEqual'](_0x5860b1['start'])||_0x12eafa['previousPosition']['isAfter'](_0x5860b1['start']))&&('insertion'==_0x3da456?_0x12eafa['isAdded']={'userId':_0x56982a}:'deletion'==_0x3da456&&(_0x12eafa['isRemoved']={'userId':_0x56982a})),0x0==_0x1cf1ec['length'])break;}return _0x506e7;}['_refreshStartEndIndex'](_0x4884d4){const _0x217dc0=new Map();for(let _0x57d5de=0x0;_0x57d5de<_0x4884d4['length'];_0x57d5de++)'text'===_0x4884d4[_0x57d5de]['type']?(_0x4884d4[_0x57d5de]['item']['startIndex']=_0x57d5de,_0x4884d4[_0x57d5de]['item']['endIndex']=_0x57d5de):('elementStart'===_0x4884d4[_0x57d5de]['type']?_0x4884d4[_0x57d5de]['item']['startIndex']=_0x57d5de:'elementEnd'===_0x4884d4[_0x57d5de]['type']&&(_0x4884d4[_0x57d5de]['item']['endIndex']=_0x57d5de),_0x217dc0['set'](_0x4884d4[_0x57d5de]['id'],_0x57d5de));for(const _0x298dce of _0x217dc0['values']())'elementStart'===_0x4884d4[_0x298dce]['type']?_0x4884d4[_0x298dce]['item']['endIndex']=_0x217dc0['get'](_0x4884d4[_0x298dce]['pairId']):'elementEnd'===_0x4884d4[_0x298dce]['type']&&(_0x4884d4[_0x298dce]['item']['startIndex']=_0x217dc0['get'](_0x4884d4[_0x298dce]['pairId']));}['_processTape'](_0x193b02){for(let _0x562603=0x0;_0x562603<_0x193b02['length'];_0x562603++){if('elementStart'===_0x193b02[_0x562603]['type'])_0x193b02[_0x562603]['item']['startIndex']=_0x562603;else{if('elementEnd'===_0x193b02[_0x562603]['type']){_0x193b02[_0x562603]['item']['endIndex']=_0x562603;const _0x5af6f2=_0x193b02[_0x562603]['item']['startIndex'];_0x193b02[_0x5af6f2]['pairId']=_0x193b02[_0x562603]['id'],_0x193b02[_0x562603]['pairId']=_0x193b02[_0x5af6f2]['id'];}else _0x193b02[_0x562603]['item']['startIndex']=_0x562603,_0x193b02[_0x562603]['item']['endIndex']=_0x562603,_0x193b02[_0x562603]['pairId']=null;}_0x193b02[_0x562603]['markersStart']||(_0x193b02[_0x562603]['markersStart']=[],_0x193b02[_0x562603]['markersEnd']=[]);}}['_markInsertions'](_0x2c16d4,_0x21d65c){const _0x5adc1d=_0x2c16d4['filter'](_0x57b230=>!_0x57b230['isAdded']);for(let _0x17b966=0x0;_0x17b966<_0x21d65c['length'];_0x17b966++)_0x21d65c[_0x17b966]['isAdded']&&(_0x5adc1d[_0x17b966]['isAdded']=_0x21d65c[_0x17b966]['isAdded']);}['_getDiff'](_0x24654d,_0x2513c7=null){const _0x132981=this['repository']['getRevision'](_0x24654d),_0x29e9e3=_0x2513c7?this['repository']['getRevision'](_0x2513c7):null,_0x479c93=this['_getRevisionsRange'](_0x132981,_0x29e9e3),_0x451e3f=_0x479c93[_0x479c93['length']-0x1],_0x498bb6=new Map(),_0x4602b={'model':{},'attributes':{},'changes':[]},_0x484ac1=new Set(),_0x11d5c0=new Map();for(let _0x75bee4=_0x479c93['length']-0x1;_0x75bee4>=0x0;_0x75bee4--){const _0x44d253=_0x479c93[_0x75bee4];for(const _0x226559 of Object['keys'](_0x44d253['diffData']))if(_0x44d253['diffData'][_0x226559]['attachChange']){const _0x2daa82=_0x44d253['diffData'][_0x226559]['attachChange'];_0x2daa82['isAttached']?(_0x484ac1['add'](_0x226559),_0x11d5c0['has'](_0x226559)&&_0x11d5c0['get'](_0x226559)['userId']==_0x2daa82['userId']?_0x11d5c0['delete'](_0x226559):_0x11d5c0['set'](_0x226559,_0x2daa82)):_0x11d5c0['has'](_0x226559)?(_0x484ac1['delete'](_0x226559),_0x11d5c0['delete'](_0x226559)):(_0x484ac1['add'](_0x226559),_0x11d5c0['set'](_0x226559,_0x2daa82));}else _0x484ac1['add'](_0x226559);}for(const _0x6b1811 of _0x484ac1){const _0x1c2c98=_0x11d5c0['has'](_0x6b1811)&&!_0x11d5c0['get'](_0x6b1811)['isAttached'];let _0x56b2c3=_0x1c2c98?_0x479c93['length']-0x1:0x0;const _0x2e0135=_0x1c2c98?-0x1:0x1;for(;_0x479c93[_0x56b2c3];){const _0x19fe49=_0x479c93[_0x56b2c3];if(_0x19fe49['diffData'][_0x6b1811]){const _0xbe2521=_0x1c2c98?_0x19fe49['diffData'][_0x6b1811]['attributesBefore']:_0x19fe49['diffData'][_0x6b1811]['attributesAfter'];_0x4602b['attributes'][_0x6b1811]=_0xbe2521?_0x8c5550(_0xbe2521):{};break;}_0x56b2c3+=_0x2e0135;}}for(const _0x44761b of _0x479c93){_0x44761b['model']={};for(const _0x11c5d4 of _0x44761b['authors'])_0x498bb6['set'](_0x11c5d4['id'],_0x11c5d4);for(const _0x19ed31 of _0x484ac1){const _0x4c14b7=_0x44761b['diffData'][_0x19ed31]?_0x44761b['diffData'][_0x19ed31]['insertions']:'[]',_0x345575=_0x44761b['diffData'][_0x19ed31]?_0x44761b['diffData'][_0x19ed31]['deletions']:'[]',_0x34c947=_0x44761b['diffData'][_0x19ed31]?.['rootElementName']||'$root';_0x44761b['model'][_0x19ed31]={'insertions':this['_utils']['_makeModelFromViewString'](_0x4c14b7,_0x34c947),'deletions':this['_utils']['_makeModelFromViewString'](_0x345575,_0x34c947)};}}for(const _0x4e0e14 of _0x484ac1){let _0x4c5c6e=null,_0x101c51=0x0;const _0x12fd16=_0x479c93['map'](_0x81b411=>_0x81b411['diffData'][_0x4e0e14]?.['rootElementName'])['find'](_0x5ae716=>void 0x0!==_0x5ae716)||'$root',_0x11e7cc=new Map(Array['from'](_0x132981['model'][_0x4e0e14]['insertions']['markers'])['filter'](([_0x3ea4c2])=>!_0x3ea4c2['startsWith']('revision:')));let _0x1ee92f=0x0;for(const _0x38f7b9 of _0x479c93){const _0xb67f69=this['_makeTape'](_0x38f7b9['model'][_0x4e0e14]['insertions']);_0x38f7b9==_0x132981?(_0x4c5c6e=_0xb67f69,_0x101c51=_0x4c5c6e['length'],_0x4c5c6e['forEach'](_0x12298a=>{_0x12298a['id']=_0x1ee92f++;}),this['_processTape'](_0x4c5c6e)):this['_markInsertions'](_0x4c5c6e,_0xb67f69);const _0xd2c30c=_0x4c5c6e['filter'](_0x352f6d=>!_0x352f6d['isAdded'])['map'](_0x45d26f=>_0x45d26f['id']);let _0x43dba3=0x0;const _0x572f28=this['_makeTape'](_0x38f7b9['model'][_0x4e0e14]['deletions']);_0x572f28['forEach'](_0x18a67f=>{_0x18a67f['isRemoved']?_0x18a67f['id']=_0x101c51++:_0x18a67f['id']=_0xd2c30c[_0x43dba3++];}),this['_processTape'](_0x572f28),this['_setDistance'](_0x4c5c6e,'isAdded'),this['_setDistance'](_0x572f28,'isRemoved'),_0x38f7b9==_0x132981&&this['_markMarkers'](_0x4c5c6e,_0x11e7cc),_0x4c5c6e=this['_joinTapes'](_0x4c5c6e,_0x572f28),this['_refreshStartEndIndex'](_0x4c5c6e),this['_setDistance'](_0x4c5c6e,'isRemoved');}_0x4c5c6e=_0x4c5c6e['filter'](_0x252808=>!(_0x252808['isAdded']&&_0x252808['isRemoved']));const _0x4232eb=new Map(_0x451e3f['model'][_0x4e0e14]['deletions']['markers']),_0x8d1a1c=new Set(_0x11e7cc['keys']());for(const _0x27c90b of _0x4232eb['keys']())_0x8d1a1c['delete'](_0x27c90b);this['_markSuggestions'](_0x4c5c6e,_0x8d1a1c),this['_fixObsoleteTags'](_0x4c5c6e),_0x4c5c6e=this['_removeMissingPairs'](_0x4c5c6e),_0x4c5c6e=this['_markMismatchedRemovedTags'](_0x4c5c6e),_0x4c5c6e=this['_removeUnsupportedChanges'](_0x4c5c6e);const {root:_0x4ca19a,changes:_0x1fea3e}=this['_makeModelFromTape'](_0x4c5c6e,_0x498bb6,_0x4e0e14,_0x12fd16);_0x4602b['model'][_0x4e0e14]=_0x4ca19a;const _0x103ef3=_0x11d5c0['get'](_0x4e0e14);if(_0x103ef3){const _0x271619=_0x498bb6['get'](_0x103ef3['userId']),_0x1c7939=new ChangeItem({'author':_0x271619,'type':_0x103ef3['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x4e0e14});_0x1fea3e['unshift'](_0x1c7939),_0x4602b['attributes'][_0x4e0e14]['revisionHistoryAttachChange']=_0x1c7939['id'];}_0x4602b['changes']=_0x4602b['changes']['concat'](_0x1fea3e);}return _0x4602b;}['_markMarkers'](_0x1f23fd,_0x49ed24){for(let _0xa0bf4c=0x0;_0xa0bf4c<_0x1f23fd['length'];_0xa0bf4c++)for(const [_0xf257f,_0x4ba272]of _0x49ed24)!_0x4ba272['isCollapsed']&&_0x4ba272['start']['isEqual'](_0x1f23fd[_0xa0bf4c]['previousPosition'])&&_0x1f23fd[_0xa0bf4c]['markersStart']['push'](_0xf257f),_0x4ba272['end']['isEqual'](_0x1f23fd[_0xa0bf4c]['nextPosition'])&&_0x1f23fd[_0xa0bf4c]['markersEnd']['push'](_0xf257f);}['_joinTapes'](_0x55c82b,_0x38ba99){let _0x3caae1=[],_0x14217f=0x0,_0x1160ee=0x0;for(;_0x14217f<_0x55c82b['length']||_0x1160ee<_0x38ba99['length'];){const _0x387726=_0x55c82b[_0x14217f]||{},_0x56df7f=_0x38ba99[_0x1160ee]||{};if(_0x387726['id']==_0x56df7f['id'])_0x14217f++,_0x1160ee++,_0x3caae1['push'](_0x387726);else{if(_0x56df7f['isRemoved']&&_0x387726['isAdded']){const {commonTape:_0x24aed7,iEnd:_0x534b36,jEnd:_0xc21037}=this['_threeWayMerge'](_0x55c82b,_0x14217f,_0x38ba99,_0x1160ee);_0x3caae1=_0x3caae1['concat'](_0x24aed7),_0x14217f=_0x534b36,_0x1160ee=_0xc21037;}else _0x56df7f['isRemoved']?(_0x1160ee++,_0x3caae1['push'](_0x56df7f)):(_0x14217f++,_0x3caae1['push'](_0x387726));}}return _0x3caae1;}['_markSuggestions'](_0x4c116a,_0x31e591){const _0x26dc55=[];for(let _0x451106=0x0;_0x451106<_0x4c116a['length'];_0x451106++){for(let _0x4cd69b=0x0;_0x4cd69b<_0x4c116a[_0x451106]['markersStart']['length'];_0x4cd69b++){const _0x463e98=_0x4c116a[_0x451106]['markersStart'][_0x4cd69b];if(!_0x31e591['has'](_0x463e98))continue;const {group:_0xed4190,type:_0x2611a1,authorId:_0xc19edd}=_0x36a5b8(_0x463e98);'revision-suggestion'!=_0xed4190||'insertion'!=_0x2611a1&&'deletion'!=_0x2611a1||(_0x26dc55['unshift']({'type':_0x2611a1,'name':_0x463e98,'userId':_0xc19edd}),_0x4c116a[_0x451106]['markersStart']['splice'](_0x4cd69b,0x1),_0x4cd69b--);}_0x49f12d(_0x4c116a[_0x451106]);for(let _0x16a0be=0x0;_0x16a0be<_0x4c116a[_0x451106]['markersEnd']['length'];_0x16a0be++){const _0x311343=_0x4c116a[_0x451106]['markersEnd'][_0x16a0be];if(!_0x31e591['has'](_0x311343))continue;const {group:_0xe621f6,type:_0x556335}=_0x36a5b8(_0x311343);if('revision-suggestion'!=_0xe621f6||'insertion'!=_0x556335&&'deletion'!=_0x556335)continue;_0x4c116a[_0x451106]['markersEnd']['splice'](_0x16a0be,0x1),_0x16a0be--;const _0x48cec3=_0x26dc55['findIndex'](_0x8d9591=>_0x8d9591['name']==_0x311343);_0x48cec3>-0x1&&_0x26dc55['splice'](_0x48cec3,0x1);}}function _0x36a5b8(_0x3d9a1a){const _0x2dfc41=_0x3d9a1a['split'](':');return{'group':_0x2dfc41[0x0],'type':_0x2dfc41[0x1],'subType':_0x2dfc41['length']>=0x5?_0x2dfc41[0x2]:null,'id':_0x2dfc41['length']<0x5?_0x2dfc41[0x2]:_0x2dfc41[0x3],'authorId':_0x2dfc41['length']<0x5?_0x2dfc41[0x3]:_0x2dfc41[0x4],'markerCount':0x6==_0x2dfc41['length']?_0x2dfc41[0x5]:null};}function _0x49f12d(_0x20cb22){for(let _0x552b0e=0x0;_0x552b0e<_0x26dc55['length'];_0x552b0e++){if(_0x20cb22['isAdded']&&'insertion'==_0x26dc55[_0x552b0e]['type']&&_0x20cb22['isAdded']['userId']==_0x26dc55[_0x552b0e]['userId'])return _0x20cb22['isAddSuggestion']=_0x26dc55[_0x552b0e],void delete _0x20cb22['isAdded'];if(!_0x20cb22['isAdded']&&!_0x20cb22['isRemoved']&&'deletion'==_0x26dc55[_0x552b0e]['type'])return void(_0x20cb22['isRemoveSuggestion']=_0x26dc55[_0x552b0e]);}}}['_setDistance'](_0x227e23,_0x1f81b2){let _0x19f6fc=0x0,_0x21efea=!0x1;const _0x4cd35c=new Map();for(const _0x1698c5 of _0x227e23)_0x1698c5[_0x1f81b2]?_0x21efea&&(_0x19f6fc++,_0x21efea=!0x1):(_0x19f6fc++,_0x21efea=!0x0),_0x4cd35c['set'](_0x1698c5['id'],_0x19f6fc);for(let _0x354ae6=0x0;_0x354ae6<_0x227e23['length'];_0x354ae6++){if('isRemoved'==_0x1f81b2&&_0x227e23[_0x354ae6]['isAdded']||'isAdded'==_0x1f81b2&&_0x227e23[_0x354ae6]['isRemoved'])continue;if('text'==_0x227e23[_0x354ae6]['type']){_0x227e23[_0x354ae6]['distance']=0x0;continue;}const _0x1732b8=_0x4cd35c['get'](_0x227e23[_0x354ae6]['pairId']),_0x16557d=_0x4cd35c['get'](_0x227e23[_0x354ae6]['id']);_0x227e23[_0x354ae6]['distance']=_0x1732b8-_0x16557d;}}['_getRevisionsRange'](_0x4d4d1d,_0x51a2f9,_0x2f2b1c=!0x1){const _0x1366ba=[];let _0x3b9789=this['repository']['getIndex'](_0x4d4d1d),_0x5a736f=this['repository']['getIndex'](_0x51a2f9);for(-0x1==_0x5a736f&&(_0x5a736f=this['repository']['_revisions']['length'],_0x2f2b1c=!0x1);_0x3b9789<_0x5a736f;)_0x1366ba['push'](this['repository']['getRevision'](_0x3b9789)),_0x3b9789++;return _0x2f2b1c&&_0x1366ba['push'](this['repository']['getRevision'](_0x3b9789)),_0x1366ba;}['_threeWayMerge'](_0x508ece,_0xef125e,_0x5d45da,_0x2029a0){const _0x6371a1=this['editor']['model']['schema'];let _0x5d745d=_0xef125e;for(;_0x508ece[_0x5d745d]&&_0x508ece[_0x5d745d]['isAdded'];)_0x5d745d++;let _0x240043=_0x2029a0;for(;_0x5d45da[_0x240043]&&_0x5d45da[_0x240043]['isRemoved'];)_0x240043++;_0x2f9b74(_0x508ece,_0xef125e,_0x5d745d),_0x2f9b74(_0x5d45da,_0x2029a0,_0x240043);const _0x1c5872=_0x5d45da['slice'](_0x2029a0,_0x240043)['concat'](_0x508ece['slice'](_0xef125e,_0x5d745d));return _0x1c5872['sort']((_0x92e18b,_0x4d72b1)=>_0x92e18b['side']!=_0x4d72b1['side']?_0x92e18b['side']-_0x4d72b1['side']:_0x92e18b['level']!=_0x4d72b1['level']?_0x92e18b['level']-_0x4d72b1['level']:_0x92e18b['distance']!=_0x4d72b1['distance']?_0x4d72b1['distance']-_0x92e18b['distance']:!!_0x92e18b['isAdded']!=!!_0x4d72b1['isAdded']?-0x1==_0x92e18b['side']||0x0==_0x92e18b['side']?_0x92e18b['isAdded']?-0x1:0x1:_0x92e18b['isAdded']?0x1:-0x1:_0x92e18b['index']-_0x4d72b1['index']),{'commonTape':_0x1c5872,'iEnd':_0x5d745d,'jEnd':_0x240043};function _0x2f9b74(_0x188a7c,_0x578f86,_0x480cb6){let _0x42a372=-0x1,_0x366020=Number['POSITIVE_INFINITY'],_0x51c75f=!0x0;for(let _0x3dfac7=_0x578f86;_0x3dfac7<_0x480cb6;_0x3dfac7++)if(_0x6371a1['isInline'](_0x188a7c[_0x3dfac7]['item'])||(_0x51c75f=!0x1),_0x188a7c[_0x3dfac7]['item']['startIndex']<_0x578f86&&(_0x42a372=_0x3dfac7),_0x188a7c[_0x3dfac7]['item']['endIndex']>=_0x480cb6){_0x366020=_0x3dfac7;break;}_0x51c75f&&(_0x42a372=_0x480cb6-0x1);for(let _0x375afa=_0x578f86;_0x375afa<_0x480cb6;_0x375afa++)_0x188a7c[_0x375afa]['side']=_0x375afa<=_0x42a372?-0x1:_0x375afa<_0x366020?0x0:0x1,_0x188a7c[_0x375afa]['index']=_0x375afa;let _0x46001b=0x0;for(let _0x31db8a=_0x578f86;_0x31db8a<=_0x42a372;_0x31db8a++)0x0==_0x188a7c[_0x31db8a]['distance']?_0x188a7c[_0x31db8a]['level']=_0x46001b:(_0x46001b++,_0x188a7c[_0x31db8a]['level']=_0x46001b,_0x46001b++);for(let _0x115e75=_0x578f86;_0x115e75<_0x480cb6;_0x115e75++)0x0==_0x188a7c[_0x115e75]['side']&&(_0x188a7c[_0x115e75]['level']=_0x46001b);_0x46001b=0x0;for(let _0x544949=_0x480cb6-0x1;_0x544949>=_0x366020;_0x544949--)0x0==_0x188a7c[_0x544949]['distance']?_0x188a7c[_0x544949]['level']=_0x46001b:(_0x46001b--,_0x188a7c[_0x544949]['level']=_0x46001b,_0x46001b--);}}['_fixObsoleteTags'](_0x271139){const _0x1a738c=new Map(),_0x302d73=this['editor']['model']['schema'];for(let _0x257544=0x1;_0x257544<_0x271139['length'];_0x257544++){let _0x420f3c,_0x2a80b3,_0x1f98fb;const _0x49a10e=_0x271139[_0x257544],_0x655fe2=_0x271139[_0x257544-0x1];if('text'==_0x49a10e['type'])continue;if(_0x49a10e['type']!=_0x655fe2['type'])continue;if(!_0x302d73['isBlock'](_0x655fe2['item'])||_0x302d73['isLimit'](_0x655fe2['item']))continue;if(!_0x302d73['isBlock'](_0x49a10e['item'])||_0x302d73['isLimit'](_0x49a10e['item']))continue;if((_0x271139[_0x257544]['isAdded']||_0x271139[_0x257544]['isAddSuggestion'])&&_0x271139[_0x257544-0x1]['isRemoved'])_0x420f3c=_0x271139[_0x257544],_0x2a80b3=_0x271139[_0x257544-0x1],_0x1f98fb=_0x257544-0x1;else{if(!_0x271139[_0x257544]['isRemoved']||!_0x271139[_0x257544-0x1]['isAdded']&&!_0x271139[_0x257544-0x1]['isAddSuggestion'])continue;_0x420f3c=_0x271139[_0x257544-0x1],_0x2a80b3=_0x271139[_0x257544],_0x1f98fb=_0x257544;}const _0x2d211d=_0x420f3c['level']==_0x2a80b3['level'],_0x4b2c86=Math['abs'](_0x420f3c['level'])<Math['abs'](_0x2a80b3['level'])&&0x0==_0x2a80b3['distance'];(_0x2d211d||_0x4b2c86)&&(_0x1a738c['set'](_0x2a80b3['id'],_0x420f3c['id']),_0x271139['splice'](_0x1f98fb,0x1),_0x257544--,_0x420f3c['isAdded']=!0x1);}for(let _0x2f3649=0x0;_0x2f3649<_0x271139['length'];_0x2f3649++)_0x1a738c['has'](_0x271139[_0x2f3649]['pairId'])&&(_0x271139[_0x2f3649]['pairId']=_0x1a738c['get'](_0x271139[_0x2f3649]['pairId']));}['_removeMissingPairs'](_0x30d36d){const _0x3b0fee=new Set(_0x30d36d['map'](_0x5912b5=>_0x5912b5['id']));for(let _0x203a9e=0x0;_0x203a9e<_0x30d36d['length'];_0x203a9e++)_0x3b0fee['has'](_0x30d36d[_0x203a9e]['pairId'])||0x0==_0x30d36d[_0x203a9e]['distance']||(_0x30d36d[_0x203a9e]['isIncorrect']=!0x0);return _0x30d36d['filter'](_0x41171=>!_0x41171['isIncorrect']);}['_markMismatchedRemovedTags'](_0x5b39b8){const _0x3a5a86=new Set();for(let _0x309895=0x0;_0x309895<_0x5b39b8['length'];_0x309895++){if(_0x3a5a86['has'](_0x5b39b8[_0x309895]['id'])&&_0x5b39b8[_0x309895]['isRemoved']&&(_0x5b39b8[_0x309895]['isIncorrect']=!0x0),_0x5b39b8[_0x309895]['isIncorrect'])continue;if(0x0==_0x5b39b8[_0x309895]['distance'])continue;if('elementStart'!=_0x5b39b8[_0x309895]['type'])continue;if(null==_0x5b39b8[_0x309895]['pairId'])continue;let _0x42955a=_0x309895+0x1,_0x26a4c4=0x0;for(;_0x5b39b8[_0x42955a]['id']!=_0x5b39b8[_0x309895]['pairId'];)'elementStart'==_0x5b39b8[_0x42955a]['type']?_0x26a4c4++:'elementEnd'==_0x5b39b8[_0x42955a]['type']&&_0x26a4c4--,_0x42955a++;if(0x0!=_0x26a4c4){if(_0x5b39b8[_0x309895]['isRemoved'])_0x5b39b8[_0x309895]['isIncorrect']=!0x0;else{for(;_0x42955a!=_0x309895;)_0x5b39b8[_0x42955a]['isRemoved']&&0x0!=_0x5b39b8[_0x42955a]['distance']&&(_0x5b39b8[_0x42955a]['isIncorrect']=!0x0,_0x3a5a86['add'](_0x5b39b8[_0x42955a]['pairId'])),_0x42955a--;}}}return _0x5b39b8['filter'](_0x5e157f=>!_0x5e157f['isIncorrect']);}['_removeUnsupportedChanges'](_0x5c76d2){const _0x2dabd4=this['editor']['model']['schema'];for(let _0x16b180=0x0;_0x16b180<_0x5c76d2['length'];_0x16b180++){if(!(_0x5c76d2[_0x16b180]['isAdded']||_0x5c76d2[_0x16b180]['isAddSuggestion']||_0x5c76d2[_0x16b180]['isRemoved']||_0x5c76d2[_0x16b180]['isRemoveSuggestion']))continue;if(0x0==_0x5c76d2[_0x16b180]['distance'])continue;const _0x2e40b2=_0x5c76d2[_0x16b180]['item'];_0x2dabd4['isBlock'](_0x2e40b2)||_0x2dabd4['isLimit'](_0x2e40b2)||(_0x5c76d2[_0x16b180]['isAdded']&&delete _0x5c76d2[_0x16b180]['isAdded'],_0x5c76d2[_0x16b180]['isAddSuggestion']&&delete _0x5c76d2[_0x16b180]['isAddSuggestion'],_0x5c76d2[_0x16b180]['isRemoveSuggestion']&&delete _0x5c76d2[_0x16b180]['isRemoveSuggestion'],_0x5c76d2[_0x16b180]['isRemoved']&&(_0x5c76d2[_0x16b180]['isIncorrect']=!0x0));}return _0x5c76d2['filter'](_0x12986d=>!_0x12986d['isIncorrect']);}['_makeModelFromTape'](_0x1af85a,_0xa2c4a0,_0xca466f,_0x303001){const _0x277e01=new _0x59fcbe(),_0x19066b=[],_0x3feab7=new Map(),_0x1d2bba=this['editor']['model'],_0x2168ad=_0x1d2bba['schema'],_0x35b34d=[_0x277e01],_0xa6b095={},_0x5387f0={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};_0x277e01['name']=_0x303001;let _0x251f82=null;const _0x5c1d67=[0x0];for(let _0x553d53=0x0;_0x553d53<_0x1af85a['length'];_0x553d53++)if('elementStart'===_0x1af85a[_0x553d53]['type']){_0x1af85a[_0x553d53]['previousPosition']=_0x1d2bba['createPositionFromPath'](_0x277e01,_0x5c1d67);const _0x5b2b27=new _0x46d26f(_0x1af85a[_0x553d53]['item']['name'],_0x1af85a[_0x553d53]['item']['getAttributes']());_0x35b34d[0x0]['_appendChild'](_0x5b2b27),_0x5c1d67['push'](0x0),_0x35b34d['unshift'](_0x5b2b27),_0x1af85a[_0x553d53]['nextPosition']=_0x1d2bba['createPositionFromPath'](_0x277e01,_0x5c1d67);}else'elementEnd'===_0x1af85a[_0x553d53]['type']?(_0x35b34d['shift'](),_0x1af85a[_0x553d53]['previousPosition']=_0x1d2bba['createPositionFromPath'](_0x277e01,_0x5c1d67),_0x5c1d67['pop'](),_0x5c1d67[_0x5c1d67['length']-0x1]++,_0x1af85a[_0x553d53]['nextPosition']=_0x1d2bba['createPositionFromPath'](_0x277e01,_0x5c1d67)):(_0x1af85a[_0x553d53]['previousPosition']=_0x1d2bba['createPositionFromPath'](_0x277e01,_0x5c1d67),_0x251f82?_0x251f82['_data']+=_0x1af85a[_0x553d53]['item']['data']:_0x251f82=new _0x3b5bf9(_0x1af85a[_0x553d53]['item']['data'],_0x1af85a[_0x553d53]['item']['getAttributes']()),_0x1af85a[_0x553d53+0x1]&&'text'===_0x1af85a[_0x553d53+0x1]['type']&&_0x5722d1(_0x251f82,_0x1af85a[_0x553d53+0x1]['item'])||(_0x35b34d[0x0]['_appendChild'](_0x251f82),_0x251f82=null),_0x5c1d67[_0x5c1d67['length']-0x1]+=_0x1af85a[_0x553d53]['item']['offsetSize'],_0x1af85a[_0x553d53]['nextPosition']=_0x1d2bba['createPositionFromPath'](_0x277e01,_0x5c1d67));for(let _0x40cf51=0x0;_0x40cf51<_0x1af85a['length'];_0x40cf51++){const _0x3dbcfd=_0x1af85a[_0x40cf51]['previousPosition'],_0x22899a=_0x1af85a[_0x40cf51]['nextPosition'];for(const _0x3249bb of _0x1af85a[_0x40cf51]['markersStart'])_0x3feab7['set'](_0x3249bb,{'start':_0x3dbcfd,'end':null});_0xedf4cf('isRemoveSuggestion',_0x40cf51,_0x3dbcfd,_0x22899a),_0xedf4cf('isAddSuggestion',_0x40cf51,_0x3dbcfd,_0x22899a),_0xedf4cf('isRemoved',_0x40cf51,_0x3dbcfd,_0x22899a),_0xedf4cf('isAdded',_0x40cf51,_0x3dbcfd,_0x22899a);for(const _0x1d0044 of _0x1af85a[_0x40cf51]['markersEnd']){const _0x4e99a4=_0x3feab7['get'](_0x1d0044);_0x4e99a4?_0x4e99a4['end']=_0x22899a:_0x3feab7['set'](_0x1d0044,{'start':_0x22899a,'end':_0x22899a});}}for(const [_0x36cf7b,_0x560e15]of _0x3feab7){const _0x527f42=this['editor']['model']['createRange'](_0x560e15['start'],_0x560e15['end']);_0x277e01['markers']['set'](_0x36cf7b,_0x527f42);}return _0x19066b['sort']((_0x17bd8f,_0x18e3e5)=>{const _0x2e6b7d=_0x277e01['markers']['get']('revision:'+_0x17bd8f['id']),_0x1158db=_0x277e01['markers']['get']('revision:'+_0x18e3e5['id']);return _0x2e6b7d['start']['isBefore'](_0x1158db['start'])?-0x1:_0x2e6b7d['start']['isAfter'](_0x1158db['start'])?0x1:_0x2e6b7d['end']['isBefore'](_0x1158db['end'])?-0x1:_0x2e6b7d['end']['isAfter'](_0x1158db['end'])?0x1:'add'===_0x17bd8f['type']?-0x1:0x1;}),{'root':_0x277e01,'changes':_0x19066b};function _0xedf4cf(_0x4dfa2c,_0x4ba9d6,_0x2ccd39,_0x4aef7b){const _0xf388d0=!!_0x1af85a[_0x4ba9d6][_0x4dfa2c],_0xbff0aa=_0xf388d0?_0x1af85a[_0x4ba9d6][_0x4dfa2c]['userId']:null,_0xe0aca2=_0x4ba9d6===_0x1af85a['length']-0x1,_0x477d7f=_0x5387f0[_0x4dfa2c][0x0],_0x3e7036=_0x2168ad['isObject'](_0x1af85a[_0x4ba9d6]['item']);!_0xa6b095[_0x4dfa2c]&&_0xf388d0?_0xa6b095[_0x4dfa2c]={'start':_0x2ccd39,'tapeItem':_0x1af85a[_0x4ba9d6],'userId':_0xbff0aa,'type':_0x4dfa2c}:_0xa6b095[_0x4dfa2c]&&!_0xf388d0?(_0xa6b095[_0x4dfa2c]['end']=_0x2ccd39,_0x5471a9(_0xa6b095[_0x4dfa2c]),_0xa6b095[_0x4dfa2c]=null):_0xa6b095[_0x4dfa2c]&&_0xf388d0&&_0xa6b095[_0x4dfa2c]['userId']!==_0xbff0aa&&(_0xa6b095[_0x4dfa2c]['end']=_0x2ccd39,_0x477d7f&&_0x477d7f['userId']===_0xa6b095[_0x4dfa2c]['userId']||_0x5471a9(_0xa6b095[_0x4dfa2c]),_0xa6b095[_0x4dfa2c]={'start':_0x2ccd39,'tapeItem':_0x1af85a[_0x4ba9d6],'userId':_0xbff0aa,'type':_0x4dfa2c}),_0xa6b095[_0x4dfa2c]&&_0x3e7036&&('elementStart'!==_0x1af85a[_0x4ba9d6]['type']||_0x477d7f&&_0x477d7f['userId']===_0xbff0aa||_0x5387f0[_0x4dfa2c]['unshift']({'userId':_0xbff0aa,'object':_0x1af85a[_0x4ba9d6]['item'],'change':_0xa6b095[_0x4dfa2c]}),'elementEnd'===_0x1af85a[_0x4ba9d6]['type']&&_0x477d7f&&_0x477d7f['object']===_0x1af85a[_0x4ba9d6]['item']&&(_0x5387f0[_0x4dfa2c]['shift'](),_0xa6b095[_0x4dfa2c]=_0x477d7f['change'])),_0xa6b095[_0x4dfa2c]&&_0xe0aca2&&(_0xa6b095[_0x4dfa2c]['end']=_0x4aef7b,_0x5471a9(_0xa6b095[_0x4dfa2c]),_0xa6b095[_0x4dfa2c]=null);}function _0x5471a9({start:_0x4d1824,end:_0x27eba2,tapeItem:_0x5274ef,userId:_0x55336a,type:_0x22c3f3}){const _0x5c513e=_0x5274ef['item'],_0x2fc9e4=_0x1d2bba['schema']['isBlock'](_0x5c513e)&&!_0x1d2bba['schema']['isLimit'](_0x5c513e),_0x2e3e1f=_0x4d1824['nodeAfter']==_0x27eba2['parent']&&_0x27eba2['isAtStart'];if(_0x2fc9e4&&_0x2e3e1f)return;const _0x52fbce=_0x1d2bba['createRange'](_0x4d1824,_0x27eba2),_0xd74f6c=_0xa2c4a0['get'](_0x55336a),_0x3627ef=new ChangeItem({'author':_0xd74f6c,'type':'isAdded'==_0x22c3f3||'isAddSuggestion'==_0x22c3f3?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x22c3f3||'isRemoveSuggestion'==_0x22c3f3},'createdAt':new Date(),'rootName':_0xca466f});_0x19066b['push'](_0x3627ef),_0x277e01['markers']['set']('revision:'+_0x3627ef['id'],_0x52fbce);}function _0x5722d1(_0x324ba3,_0x28711d){const _0x528e18=_0x324ba3['getAttributes'](),_0x3d5eed=_0x28711d['getAttributes']();for(const _0x10d9ab of _0x528e18){if(_0x10d9ab[0x1]!==_0x28711d['getAttribute'](_0x10d9ab[0x0]))return!0x1;_0x3d5eed['next']();}return _0x3d5eed['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0xc032db=>{const _0x58c13a=_0xc032db['markerName']['split'](':')[0x1],_0xcde035=this['_getChangeFromId'](_0x58c13a);if(!_0xcde035)return null;const _0x3c62cc='add'==_0xcde035['type']?'insertion':'deletion',_0x2c02eb=['ck-suggestion-marker','ck-suggestion-marker-'+_0x3c62cc];return _0xcde035['data']['isSuggestion']&&_0x2c02eb['push']('ck-suggestion-marker-'+_0x3c62cc+'-new'),this['activeChange']==_0xcde035&&_0x2c02eb['push']('ck-suggestion-marker--active'),{'classes':_0x2c02eb,'attributes':{'data-change-id':_0x58c13a}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x32467e=>{_0x32467e['on']('element:pre',(_0x34f7e7,_0x32a629,_0x5ea890)=>{const _0x3edb61=_0x32a629['viewItem']['getChild'](0x0);if(!_0x3edb61||!_0x3edb61['is']('element','code'))return;if(!_0x5ea890['consumable']['consume'](_0x3edb61,{'attributes':['vid_start','vid_end']}))return;const _0x1b5092=_0x32a629['modelRange']['start']['nodeAfter'];_0x5ea890['writer']['setAttribute']('vid_start',_0x3edb61['getAttribute']('vid_start'),_0x1b5092),_0x5ea890['writer']['setAttribute']('vid_end',_0x3edb61['getAttribute']('vid_end'),_0x1b5092);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x56f587=>{_0x56f587['on']('element',(_0x3ba932,_0x4523de,_0x5e6125)=>{if(!_0x5e6125['consumable']['consume'](_0x4523de['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x4523de['modelRange']['isCollapsed'])return;const _0x43766a=_0x4523de['modelRange']['start']['nodeAfter'];_0x43766a['hasAttribute']('vid_start')||_0x43766a['hasAttribute']('vid')||(_0x5e6125['writer']['setAttribute']('vid_start',_0x4523de['viewItem']['getAttribute']('vid_start'),_0x43766a),_0x5e6125['writer']['setAttribute']('vid_end',_0x4523de['viewItem']['getAttribute']('vid_end'),_0x43766a));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x6a95f=>_0x6a95f['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x13b1ca,[,_0x2d359e])=>{['vid_start','vid_end','vid']['includes'](_0x2d359e)&&(_0x13b1ca['return']=!0x0,_0x13b1ca['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x5be889=>{_0x5be889['on']('attribute:vid',(_0xdb58a0,_0x478600,_0x2c574c)=>{if('\x20'!=_0x478600['item']['data']||_0x478600['item']['parent']['maxOffset']>0x1)return;if(!_0x2c574c['consumable']['consume'](_0x478600['item'],_0xdb58a0['name']))return;const _0x2f1495=_0x2c574c['writer'],_0x599cb8=_0x2c574c['mapper']['toViewRange'](_0x478600['range']);_0x2f1495['wrap'](_0x599cb8,_0x2f1495['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x8bbcf4){const _0x298c55=_0x8bbcf4['plugins']['get']('RevisionViewer');return(_0x382cfc,_0xc973e8,_0x2a30f8)=>{const _0x1fc9f1=_0xc973e8['markerName']['split'](':')[0x1],_0x157221=_0x298c55['_getChangeFromId'](_0x1fc9f1);if(!_0x157221)return null;const _0x3a0390='add'==_0x157221['type']?'split':'merge';if(!_0x2a30f8['consumable']['test'](_0xc973e8['markerRange'],_0x382cfc['name']))return;const _0xf95050=_0xc973e8['markerRange']['getWalker'](),_0x57cfb7=_0xc973e8['markerRange']['start'],_0x244cce=_0x8bbcf4['model']['schema'];let _0x16a133=null,_0x47cd11=null,_0x23c538=!0x1,_0x2de000=!0x1;for(const _0x342bb1 of _0xf95050){const _0xa1281f=_0x342bb1['item'];_0x23c538=_0x23c538||_0x244cce['isContent'](_0xa1281f);const _0x36453e=_0x2a30f8['mapper']['toViewElement'](_0xa1281f);if(_0x36453e&&_0x36453e['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x342bb1['type']&&(_0x244cce['isBlock'](_0xa1281f)&&!_0x244cce['isLimit'](_0xa1281f)&&(_0xa1281f['nextSibling']||_0x57cfb7['isAtEnd']?_0x16a133&&_0x16a133['parent']==_0xa1281f||(_0x16a133=_0xa1281f,_0xcc5857(_0x342bb1['previousPosition']),_0x2de000=!0x0):_0x47cd11=_0x47cd11||_0x342bb1['previousPosition']));}function _0xcc5857(_0x522352){const _0x2bf8f2=_0x2a30f8['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x3a0390}),_0xa7d1ca=_0x2a30f8['mapper']['toViewPosition'](_0x522352);_0x157221['data']['isSuggestion']&&_0x2a30f8['writer']['addClass']('ck-suggestion-marker-'+_0x3a0390+'-new',_0x2bf8f2),_0x298c55['activeChange']==_0x157221&&_0x2a30f8['writer']['addClass']('ck-suggestion-marker--active',_0x2bf8f2),_0x2a30f8['writer']['insert'](_0xa7d1ca,_0x2bf8f2),_0x2a30f8['mapper']['bindElementToMarker'](_0x2bf8f2,_0xc973e8['markerName']);}_0x23c538||_0x2de000||!_0x47cd11||_0xcc5857(_0x47cd11);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x1dd817,_0x2c8b2c,_0x284efe)=>{const _0xc40ba3=_0x284efe['mapper']['markerNameToElements'](_0x2c8b2c['markerName']);if(_0xc40ba3){for(const _0x2ebb78 of _0xc40ba3)(_0x2ebb78['hasClass']('ck-suggestion-marker-split')||_0x2ebb78['hasClass']('ck-suggestion-marker-merge'))&&(_0x284efe['mapper']['unbindElementFromMarkerName'](_0x2ebb78,_0x2c8b2c['markerName']),_0x284efe['writer']['remove'](_0x2ebb78));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x1010e8,_0x23a913,_0x1ca828)=>{const _0x35bd91=_0x23a913['markerName']['split'](':')[0x1],_0x239cf4=this['_getChangeFromId'](_0x35bd91);if(!_0x239cf4)return null;const _0x216d1a='add'==_0x239cf4['type']?'split':'merge';if(_0x1ca828['consumable']['test'](_0x23a913['markerRange'],_0x1010e8['name']))for(const _0x5b541e of _0x23a913['markerRange']['getItems']()){if(!_0x5b541e['is']('element','softBreak'))continue;const _0x546af9=_0x1ca828['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x216d1a}),_0x3f57be=_0x1ca828['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x5b541e));_0x239cf4['data']['isSuggestion']&&_0x1ca828['writer']['addClass']('ck-suggestion-marker-'+_0x216d1a+'-new',_0x546af9),this['activeChange']==_0x239cf4&&_0x1ca828['writer']['addClass']('ck-suggestion-marker--active',_0x546af9),_0x1ca828['writer']['insert'](_0x3f57be,_0x546af9),_0x1ca828['mapper']['bindElementToMarker'](_0x546af9,_0x23a913['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x1d86d9=>{for(const _0x5b0800 of this['editor']['model']['document']['getRootNames']()){const _0x55cad1=this['editor']['model']['document']['getRoot'](_0x5b0800),_0xde906d=this['editor']['editing']['view']['document']['getRoot'](_0x5b0800);if(_0xde906d){const _0x2e0126=_0x55cad1['getAttribute']('revisionHistoryAttachChange');if(_0x1d86d9['removeAttribute']('data-change-id',_0xde906d),_0x1d86d9['removeClass']('ck-revision-history-root-add',_0xde906d),_0x1d86d9['removeClass']('ck-revision-history-root-remove',_0xde906d),_0x1d86d9['removeClass']('ck-revision-history-root--active',_0xde906d),_0x2e0126){const _0x43f2f7=this['_getChangeFromId'](_0x2e0126);if(!_0x43f2f7)return null;_0x1d86d9['setAttribute']('data-change-id',_0x2e0126,_0xde906d),_0x1d86d9['addClass']('ck-revision-history-root-'+_0x43f2f7['type'],_0xde906d),this['activeChange']==_0x43f2f7&&_0x1d86d9['addClass']('ck-revision-history-root--active',_0xde906d);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x22157d=>'revision-comment:'+_0x22157d,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x2b0152=>'revision-suggestion:'+_0x2b0152,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x5bf65c=>({'name':'suggestion:'+_0x5bf65c,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x33315d=>{const _0x19aba7=_0x33315d['markerName']['split'](':')[0x1];return'insertion'!=_0x19aba7&&'deletion'!=_0x19aba7?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x19aba7]};}}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:deletion',_t(this['editor'],'merge'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:insertion',_t(this['editor'],'split'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision-suggestion',(_0x56ee8e,_0x1ebf2a,_0x2585c5)=>{const _0x2fee29=_0x2585c5['mapper']['markerNameToElements'](_0x1ebf2a['markerName']);if(_0x2fee29){for(const _0x3b3a8f of _0x2fee29)_0x3b3a8f['is']('uiElement')&&(_0x2585c5['mapper']['unbindElementFromMarkerName'](_0x3b3a8f,_0x1ebf2a['markerName']),_0x2585c5['writer']['remove'](_0x3b3a8f));}},{'priority':'high'});}['_getChangeFromId'](_0xd84258){return this['_changeIdToChange']['get'](_0xd84258);}['_getViewForChange'](_0x3dab98){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new ChangeDetailsView(this['editor']['locale'],_0x3dab98),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x3bc98c,_0xf3c307,_0x4c0e1c,_0x29f304)=>{_0x29f304&&this['_balloon']['remove'](_0x29f304),_0x4c0e1c&&(this['_balloon']['add']({'view':_0x4c0e1c,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x7af140=this['editor']['editing'],_0x25325a=this['_getChangeFromId'](_0x4c0e1c['changeId']);let _0x31c69f;if(_0x25325a['data']['isOnRoot']){const _0x46e62b=_0x7af140['view']['getDomRoot'](_0x25325a['rootName']);_0x31c69f=Array['from'](_0x46e62b['getClientRects']());}else{const _0xaaa48f=this['editor']['model']['markers']['get']('revision:'+_0x4c0e1c['changeId']);_0x31c69f=Array['from'](_0x7af140['mapper']['markerNameToElements'](_0xaaa48f['name']))['map'](_0x12f8d5=>_0x7af140['view']['domConverter']['mapViewToDom'](_0x12f8d5))['map'](_0x3ac84e=>Array['from'](_0x3ac84e['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x31c69f[0x0];return _0x31c69f['find'](_0x15cca5=>_0x15cca5['top']-0x3<=this['_activeViewTarget']['y']&&_0x15cca5['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x15cca5['left']-0x3<=this['_activeViewTarget']['x']&&_0x15cca5['right']+0x3>=this['_activeViewTarget']['x'])||_0x31c69f[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x4eb8fc,_0x27be5c,_0x35f561,_0x8177d2)=>{this['activeView']=_0x35f561?this['_getViewForChange'](_0x35f561):null,this['editor']['model']['change'](()=>{const _0x43104a=this['editor']['editing'];_0x8177d2&&(_0x8177d2['data']['isOnRoot']?_0x43104a['view']['change'](_0x1c635c=>{_0x1c635c['removeClass']('ck-revision-history-root--active',_0x43104a['view']['document']['getRoot'](_0x8177d2['rootName']));}):_0x43104a['reconvertMarker']('revision:'+_0x8177d2['id'])),_0x35f561&&(_0x35f561['data']['isOnRoot']?_0x43104a['view']['change'](_0x51e934=>{_0x51e934['addClass']('ck-revision-history-root--active',_0x43104a['view']['document']['getRoot'](_0x35f561['rootName']));}):_0x43104a['reconvertMarker']('revision:'+_0x35f561['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x1088d0,_0x5d50f1)=>{if(this['activeChange'])return;const _0x3317de=this['_findChangeIdFromDomTarget'](_0x5d50f1['target']),_0x3df386=this['_changeIdToChange']['get'](_0x3317de);_0x3df386?(this['_activeViewTarget']={'x':_0x5d50f1['domEvent']['x'],'y':_0x5d50f1['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x3df386)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x11ef1c,_0x34530f)=>{const _0xa80260=this['_findChangeIdFromDomTarget'](_0x34530f['target']),_0x124857=this['_changeIdToChange']['get'](_0xa80260);_0x124857?(this['_activeViewTarget']={'x':_0x34530f['domEvent']['x'],'y':_0x34530f['domEvent']['y']},_0x124857===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x124857):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x3072e6){do{const _0x5584f8=_0x3072e6['getAttribute']('data-change-id');if(_0x5584f8)return _0x5584f8;_0x3072e6=_0x3072e6['parent'];}while(_0x3072e6);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x3478d8=>{for(const _0x2b7999 of this['editor']['model']['markers'])_0x3478d8['removeMarker'](_0x2b7999);});}}function _t(_0x174649,_0x161c99){return(_0x4dbc24,_0x278d4e,_0x52ebdb)=>{if(!_0x52ebdb['consumable']['test'](_0x278d4e['markerRange'],_0x4dbc24['name']))return;const _0x598280=_0x278d4e['markerRange']['getWalker'](),_0xd90dd=_0x278d4e['markerRange']['start'],_0x582593=_0x174649['model']['schema'];let _0x1e471c=null,_0x2f7fb9=null,_0x251231=!0x1,_0x1eaf8e=!0x1;for(const _0xd417be of _0x598280){const _0x3566e4=_0xd417be['item'];_0x251231=_0x251231||_0x582593['isContent'](_0x3566e4);const _0x29c569=_0x52ebdb['mapper']['toViewElement'](_0x3566e4);if(_0x29c569&&_0x29c569['getCustomProperty']('addHighlight'))return;'elementEnd'==_0xd417be['type']&&(_0x582593['isBlock'](_0x3566e4)&&!_0x582593['isLimit'](_0x3566e4)&&(_0x3566e4['nextSibling']||_0xd90dd['isAtEnd']?_0x1e471c&&_0x1e471c['parent']==_0x3566e4||(_0x1e471c=_0x3566e4,_0x2fbd48(_0xd417be['previousPosition']),_0x1eaf8e=!0x0):_0x2f7fb9=_0x2f7fb9||_0xd417be['previousPosition']));}function _0x2fbd48(_0x572b3a){const _0x59d550=_0x52ebdb['mapper']['toViewPosition'](_0x572b3a),_0x7930a7=_0x52ebdb['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x161c99});_0x52ebdb['writer']['insert'](_0x59d550,_0x7930a7),_0x52ebdb['mapper']['bindElementToMarker'](_0x7930a7,_0x278d4e['markerName']);}_0x251231||_0x1eaf8e||!_0x2f7fb9||_0x2fbd48(_0x2f7fb9);};}class RestoreRevisionCommand extends _0x3dad1f{constructor(_0x1a3418){super(_0x1a3418);const _0x3888cc=_0x1a3418['plugins']['get'](RevisionViewer);this['affectsData']=!0x1,this['listenTo'](_0x3888cc,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x3888cc,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x3298d8=this['editor'],_0x27692c=_0x3298d8['plugins']['get'](RevisionViewer),_0x5774f0=_0x27692c['isReady']?_0x27692c['diff']['newRevisionId']:null;_0x3298d8['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x5774f0);}['refresh'](){const {isReady:_0x3cee8f,isEnabled:_0x147887,repository:_0x29288a,diff:_0x5ac106}=this['editor']['plugins']['get'](RevisionViewer),_0x4ab354=_0x5ac106&&_0x29288a['getLaterVisibleRevision'](_0x5ac106['newRevisionId']);this['isEnabled']=_0x3cee8f&&_0x147887&&Boolean(_0x4ab354);}}class ShowChangeCommand extends _0x3dad1f{['_step'];constructor(_0x8a95a5,{direction:_0x5ba60e}){super(_0x8a95a5);const _0xc6402=_0x8a95a5['plugins']['get'](RevisionViewer);this['affectsData']=!0x1,this['_step']='forward'===_0x5ba60e?0x1:-0x1,this['listenTo'](_0xc6402,'change:isReady',()=>this['refresh']()),this['listenTo'](_0xc6402,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0xc6402,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x9d0bc=this['editor'],_0x5b16a7=_0x9d0bc['plugins']['get'](RevisionViewer),{isNavigationMode:_0x57ae37,currentChangeNumber:_0x47a554}=_0x5b16a7;let _0x5590b7;if(_0x5b16a7['activeChange']=_0x57ae37?_0x5b16a7['diff']['changes']['get'](_0x47a554+this['_step']):_0x5b16a7['diff']['changes']['first'],_0x5b16a7['activeChange']['data']['isOnRoot'])_0x5590b7=_0x9d0bc['editing']['view']['getDomRoot'](_0x5b16a7['activeChange']['rootName']);else{const _0x21d5ce=_0x9d0bc['model']['markers']['get']('revision:'+_0x5b16a7['activeChange']['id']);_0x5590b7=_0x205b94(_0x9d0bc['editing'],_0x21d5ce);}_0x4fee1d({'target':_0x5590b7,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x3e0e39,currentChangeNumber:_0x4eea59,numberOfChanges:_0x271a1b,isReady:_0x328e1e,isEnabled:_0x54e47c}=this['editor']['plugins']['get'](RevisionViewer);this['isEnabled']=!!(_0x54e47c&&_0x328e1e&&_0x271a1b)&&(!_0x3e0e39||(0x1===this['_step']?_0x4eea59<_0x271a1b-0x1:_0x4eea59>0x0));}}class ChangesNavigationView extends _0xafec90{constructor(_0x27335b){super(_0x27335b);const _0x266b2e=this['bindTemplate'],_0x33036a=new _0x135801(_0x27335b),_0x257ec0=new _0x135801(_0x27335b);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',(_0x26f1d5,_0x3e8ae6)=>_0x26f1d5&&_0x3e8ae6>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x56d9d7,_0x339ef8,_0x2f420a,_0x3cc2e8)=>{if(!_0x56d9d7)return ft(_0x27335b,'Loading...');if(!_0x2f420a)return ft(_0x27335b,'No\x20changes');const _0x3bd669=ft(_0x27335b,'NUMBER_OF_CHANGES',_0x2f420a);return _0x3cc2e8?ft(_0x27335b,'X_OF_Y_CHANGES',[_0x339ef8+0x1,_0x2f420a]):_0x3bd669;}),_0x33036a['set']({'label':ft(_0x27335b,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x37d115}),_0x257ec0['set']({'label':ft(_0x27335b,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x27b0d7}),_0x33036a['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x257ec0['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x33036a['on']('execute',()=>this['fire']('execute','backward')),_0x257ec0['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',_0x266b2e['if']('_isStatusLabelVisible','ck-hidden',_0x55912d=>!_0x55912d)]},'children':[{'text':_0x266b2e['to']('isNavigationMode',_0xbf806c=>_0xbf806c?ft(_0x27335b,'EDIT_X_OF_Y_REVISIONS')+':\x20':ft(_0x27335b,'Total')+':\x20')}]},{'text':_0x266b2e['to']('_statusText')}]},new st(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x33036a,_0x257ec0]}]});}}const yt='ck-editor__editable__loading-overlay';class RevisionViewerLoadingOverlay extends _0x538071{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x4a4826=this['editor']['editing']['view'];_0x4a4826['change'](_0x1a8a86=>{for(const _0x4770c0 of _0x4a4826['document']['roots'])_0x1a8a86['addClass'](yt,_0x4770c0);});}['hide'](){const _0x528adb=this['editor']['editing']['view'];_0x528adb['change'](_0x4860f0=>{for(const _0x473b2b of _0x528adb['document']['roots'])_0x4860f0['removeClass'](yt,_0x473b2b);});}}class RevisionViewerUI extends _0x538071{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[RevisionViewer,RevisionViewerLoadingOverlay];}['init'](){const _0x4729c4=this['editor'],_0x1bbf48=_0x4729c4['plugins']['get'](RevisionViewer),_0x46f328=_0x4729c4['plugins']['get'](RevisionViewerLoadingOverlay);_0x4729c4['ui']['componentFactory']['add']('exitToEditing',_0x5e3d11=>{const _0xc0794=new _0x135801(_0x5e3d11);return _0xc0794['set']({'label':ft(_0x5e3d11,'Back\x20to\x20editing'),'icon':_0x2c0af7,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0xc0794,'execute',()=>{_0x4729c4['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0xc0794;}),_0x4729c4['ui']['componentFactory']['add']('restoreRevision',_0x326f75=>{const _0x47b0cf=new _0x135801(_0x326f75);return _0x47b0cf['set']({'label':ft(_0x326f75,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x47b0cf['bind']('isEnabled')['to'](_0x4729c4['commands']['get']('restoreRevision')),this['listenTo'](_0x47b0cf,'execute',()=>_0x4729c4['execute']('restoreRevision')),_0x47b0cf;}),_0x4729c4['ui']['componentFactory']['add']('changesNavigation',_0x3f2fc3=>{const _0x4868a1=new ChangesNavigationView(_0x3f2fc3),_0x20cf63=_0x4729c4['commands']['get']('showPreviousChange'),_0x3c1bf1=_0x4729c4['commands']['get']('showNextChange');return _0x4868a1['bind']('isBackwardNavigationEnabled')['to'](_0x20cf63,'isEnabled'),_0x4868a1['bind']('isForwardNavigationEnabled')['to'](_0x3c1bf1,'isEnabled'),_0x4868a1['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x1bbf48),this['listenTo'](_0x4868a1,'execute',(_0x52c49a,_0x1a7d83)=>{_0x4729c4['execute']('forward'===_0x1a7d83?'showNextChange':'showPreviousChange');}),_0x4868a1;}),_0x46f328['show'](),_0x1bbf48['on']('change:isReady',(_0x4598fb,_0x4bb2a0,_0x2f00ff)=>{_0x2f00ff?_0x46f328['hide']():_0x46f328['show']();});}}class RevisionNameView extends _0x17e56b{['_resizeObserver']=null;constructor(_0xc08aca,_0x5e463b){super(_0xc08aca,_0x5e463b);const _0x26ce64=this['bindTemplate'];this['set']({'label':ft(_0xc08aca,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=ft(_0xc08aca,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x26ce64['to']('_tooltipString'),'data-cke-tooltip-position':'s','data-cke-tooltip-class':'ck-tooltip_multi-line'}});}['render'](){super['render'](),this['_resizeObserver']=new _0x39f055(this['fieldView']['element'],()=>this['_updateTooltipText']()),this['listenTo'](this['fieldView'],'input',()=>this['_updateTooltipText']());}['destroy'](){super['destroy'](),this['_resizeObserver']&&this['_resizeObserver']['destroy']();}['_updateTooltipText'](){const _0x2705ae=this['fieldView']['element'];this['_tooltipString']=_0x2705ae['scrollWidth']>_0x2705ae['clientWidth']&&_0x2705ae['value']||'';}}class RevisionAuthorView extends _0xafec90{constructor(_0x5dfb96,_0x169a71,_0xa5cc3a){super(_0x5dfb96);const _0x41afe7=new nt();_0x41afe7['set']({'content':_0x185391,'viewBox':'0\x200\x2011\x2010'});const _0x9539ff=['ck','ck-revision-history-sidebar__revision-author'];_0xa5cc3a&&_0x9539ff['push']('ck-revision-history-sidebar__revision-author_creator');const _0x557798=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':ft(_0x5dfb96,_0xa5cc3a?'Revision\x20creator':'Revision\x20author')},'children':[_0x41afe7,_0x169a71['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x9539ff},'children':_0x557798});}}function Rt(_0x7d78c5,_0x5b62a9){const _0x40a8ce=_0x7d78c5['bindTemplate'],_0xe9a06e=_0x7d78c5['locale'],_0x3ed543=_0x182132(_0xe9a06e);_0x3ed543['panelPosition']='sw';const _0x40ee4b=function(_0x2b9254,_0x440ca6){const _0x58d883=function(_0x59e4c2,_0x5edcd2){const _0x53f9cd=_0x59e4c2['locale'],_0x211183={'Compare\x20against\x20selected':ft(_0x53f9cd,'Compare\x20against\x20selected'),'Name\x20this\x20revision':ft(_0x53f9cd,'Name\x20this\x20revision'),'Restore\x20this\x20revision':ft(_0x53f9cd,'Restore\x20this\x20revision')};return _0x5edcd2['map'](_0x338a09=>{const _0x51b170=_0x211183[_0x338a09['name']];return _0x51b170&&_0x51b170!==_0x338a09['name']&&(_0x338a09['name']=_0x51b170),_0x338a09;});}(_0x2b9254,_0x440ca6),_0x286a7c=new _0x3625c9();for(const _0x868898 of _0x58d883){const _0x470cd8={'type':'button','model':new rt({'label':_0x868898['name'],'class':_0x868898['class'],'withText':!0x0,'role':'menuitem','_action':_0x868898['action']})};_0x470cd8['model']['bind']('isEnabled')['to'](_0x2b9254,'isActionsDropdownOpen',_0x24eaae=>'function'!=typeof _0x868898['isEnabled']||(!_0x24eaae||_0x868898['isEnabled'](_0x2b9254))),_0x286a7c['add'](_0x470cd8);}return _0x286a7c;}(_0x7d78c5,_0x5b62a9);return _0x7d78c5['bind']('isActionsDropdownOpen')['to'](_0x3ed543,'isOpen'),_0x3ed543['buttonView']['set']({'label':ft(_0xe9a06e,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x5379e9}),_0x3ed543['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x40a8ce['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x40a8ce['to'](_0x42f41a=>_0x42f41a['stopPropagation']())}}),_0x3ed543['on']('execute',_0x5b827f=>{_0x7d78c5['isReady']&&'function'==typeof _0x5b827f['source']['_action']&&_0x5b827f['source']['_action'](_0x7d78c5);}),ot(_0x3ed543,_0x40ee4b,{'role':'menu'}),_0x3ed543['listenTo'](_0x7d78c5,'change:isActionsDropdownOpen',(_0x41ee18,_0x4368fa,_0x2ab2b2)=>{if(_0x2ab2b2)for(const _0x41606b of _0x3ed543['listView']['items']){const _0x16da51=_0x41606b['children']['first'],_0x2e0e83=_0x5b62a9['find'](_0x1ad6f1=>_0x1ad6f1['action']===_0x16da51['_action'])['isVisible'];_0x41606b['isVisible']=void 0x0===_0x2e0e83||_0x2e0e83(_0x7d78c5);}}),_0x3ed543;}class RevisionView extends/* #__PURE__ -- @preserve */
|
|
27
|
+
_0x1f967d(_0xafec90){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x524caf,_0xd38c8e,_0x892ae0,_0x23c543){super(_0x524caf);const _0x4ca3e6=this['bindTemplate'],_0x59c01d=function(_0x384b27,_0x4f43ac){const _0x52e3ba=Array['from'](_0x4f43ac['authors'])['filter'](_0x20d6b7=>_0x20d6b7!=_0x4f43ac['creator']);return _0x4f43ac['creator']&&_0x52e3ba['unshift'](_0x4f43ac['creator']),_0x52e3ba['map'](_0x14cde7=>new RevisionAuthorView(_0x384b27,_0x14cde7,_0x14cde7==_0x4f43ac['creator']));}(_0x524caf,_0xd38c8e);this['id']=_0xd38c8e['id'],this['_revision']=_0xd38c8e,this['_requireRevisionName']=_0x23c543,this['bind']('name','createdAt')['to'](_0xd38c8e),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x12bc82=>{return _0x21c992=_0x524caf['uiLanguage'],(_0x44af9c=_0x12bc82)['toLocaleDateString'](_0x21c992,{'month':'long','day':'numeric'})+',\x20'+_0x44af9c['toLocaleTimeString'](_0x21c992,{'hour':'numeric','minute':'numeric'});var _0x21c992,_0x44af9c;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new RevisionNameView(_0x524caf,_0x238b41),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x1e3443=>_0x1e3443||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x2033c4,_0x10916f)=>_0x2033c4&&_0x10916f),this['revisionActionsView']=_0x892ae0&&_0x892ae0['length']?Rt(this,_0x892ae0):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x4ca3e6['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x4ca3e6['if']('isEnabled','ck-disabled',_0x42dddc=>!_0x42dddc),_0x4ca3e6['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x4ca3e6['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x4ca3e6['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':_0x4ca3e6['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':_0x59c01d}]},this['revisionActionsView']],'on':{'click':_0x4ca3e6['to'](_0x5835f7=>{_0x5835f7['srcElement']['closest']('.ck-confirm-view')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x2cc92a=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x2cc92a,'change',()=>{this['_requireRevisionName']&&!_0x2cc92a['value']||this['fire']('setName',{'id':this['id'],'name':_0x2cc92a['value']}),_0x2cc92a['value']||(_0x2cc92a['value']=this['name']?this['name']:this['_createdAtFormatted']);});}['select'](){this['isSelected']=!0x0;}['deselect'](){this['isSelected']=!0x1;}['highlight'](){this['isHighlighted']=!0x0;}['unhighlight'](){this['isHighlighted']=!0x1;}}function bt(_0xe1aff4,_0x22f11f){const _0x142ad6=vt['fromJSDate'](_0xe1aff4)['setLocale'](_0x22f11f),_0x46df4f=vt['local'](),_0x1876d2=_0x46df4f['minus']({'days':0x1})['startOf']('day');let _0x12bbdf,_0x30bae6;return _0x142ad6['hasSame'](_0x46df4f,'day')?(_0x12bbdf=_0x142ad6['startOf']('day')['toJSDate'](),_0x30bae6=_0x142ad6['toRelativeCalendar']()):_0x142ad6['hasSame'](_0x1876d2,'day')?(_0x12bbdf=_0x1876d2['toJSDate'](),_0x30bae6=_0x142ad6['toRelativeCalendar']()):_0x142ad6['hasSame'](_0x46df4f,'week')?(_0x12bbdf=_0x142ad6['startOf']('week')['toJSDate'](),_0x30bae6=_0x142ad6['weekdayLong']||''):_0x142ad6['hasSame'](_0x46df4f,'year')?(_0x12bbdf=_0x142ad6['startOf']('month')['toJSDate'](),_0x30bae6=_0x142ad6['monthLong']||''):(_0x12bbdf=_0x142ad6['startOf']('year')['toJSDate'](),_0x30bae6=String(_0x142ad6['year'])),{'startDate':_0x12bbdf,'localizedPeriodName':_0x30bae6};}class RevisionsSidebarTimePeriodView extends _0xafec90{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x25a448,_0x169b2a,_0x1118a2,_0x51acd8){super(_0x25a448);const _0x1d4d64=bt(_0x169b2a,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x169b2a,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x1118a2,this['_requireRevisionName']=_0x51acd8,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':_0x1d4d64}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x59fca8){const _0x1fadce=new RevisionView(this['locale'],_0x59fca8,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x1fadce);}['removeRevision'](_0x446c37){const _0x6b7bba=this['revisionViews']['find'](_0x410590=>_0x410590['id']===_0x446c37['id']);this['revisionViews']['remove'](_0x6b7bba);}}class RevisionsSidebarHeaderView extends _0xafec90{constructor(_0x1cc838){super(_0x1cc838);const _0xf5d2b4=new nt();_0xf5d2b4['content']=_0x5ea9e8,this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0xf5d2b4,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[ft(_0x1cc838,'Revision\x20history')]}]});}}class RevisionsSidebarView extends _0xafec90{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x44a43e,_0x46cbea,_0x42c5f7,_0x3baee3){super(_0x44a43e);const _0x55e156=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x46cbea,this['_revisionActions']=_0x42c5f7,this['_requireRevisionName']=_0x3baee3,this['on']('select',(_0x13bca6,_0x1b73eb)=>{this['fire']('revisionSelected',_0x1b73eb);}),this['on']('setName',(_0x187e10,_0x37f373)=>{this['fire']('revisionSetName',_0x37f373);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new RevisionsSidebarHeaderView(_0x44a43e),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x55e156['if']('isEnabled','ck-disabled',_0x3724b5=>!_0x3724b5)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x38a787 of this['_revisions'])this['_addRevision'](_0x38a787);this['_revisions']['on']('add',(_0x2d8765,_0x2f0ea8)=>{this['_addRevision'](_0x2f0ea8);}),this['_revisions']['on']('remove',(_0x14937c,_0x513568)=>{this['_removeRevision'](_0x513568);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0xc09a4=>_0xc09a4['revisionViews']['map'](_0x1f176b=>_0x1f176b))['flat']();}['selectRevision'](_0x514d18){for(const _0x23d5cc of this['revisionViews'])_0x514d18&&_0x514d18['id']===_0x23d5cc['id']?_0x23d5cc['select']():_0x23d5cc['deselect']();}['highlightRevisions'](_0x53b33d){for(const _0x3ba440 of this['revisionViews'])_0x53b33d['some'](({id:_0x12db71})=>_0x12db71===_0x3ba440['id'])?_0x3ba440['highlight']():_0x3ba440['unhighlight']();}['_addRevision'](_0x76edce){const _0x100b74=bt(_0x76edce['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x22ccd9=this['_getTimePeriodViewByStartDate'](_0x100b74);_0x22ccd9||(_0x22ccd9=new RevisionsSidebarTimePeriodView(this['locale'],_0x100b74,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x22ccd9)),_0x22ccd9['addRevision'](_0x76edce);}['_removeRevision'](_0x34e946){const _0xd124a9=bt(_0x34e946['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0xd124a9)['removeRevision'](_0x34e946);}['_getTimePeriodViewByStartDate'](_0x7e638f){return this['timePeriodViews']['find'](_0x2a79be=>_0x2a79be['startDate']['getTime']()===_0x7e638f['getTime']());}}class RevisionsSidebar extends _0x538071{['_revisionViewer'];['_revisionsRepository'];['_sidebarView'];static ['defaultRevisionActions']=/* #__PURE__ -- @preserve */
|
|
28
28
|
((()=>['compareAgainstSelected','restoreRevision','nameRevision'])());static ['availableRevisionActions']=/* #__PURE__ -- @preserve */
|
|
29
|
-
kt();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[RevisionViewer];}constructor(
|
|
30
|
-
_0x443cf2(_0x2c191d){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x3c75d0,_0x3b04c4){super(_0x3b04c4),this['sourceElement']=_0x3c75d0,this['model']['document']['createRoot']();const _0x2c1442=new RevisionViewerEditorUIView(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new RevisionViewerEditorUI(this,_0x2c1442);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x2707a3,_0x2926c4){const _0x1cf995=new this(_0x2707a3,_0x2926c4);return await _0x1cf995['initPlugins'](),await _0x1cf995['ui']['init'](_0x2707a3),await _0x1cf995['data']['init'](_0x1cf995['config']['get']('initialData')||''),_0x1cf995['fire']('ready'),_0x1cf995;}}const It=['RevisionHistoryUI','RestrictedEditingMode','AIChat','AIReviewMode','AIBalloon','AIQuickActions','AIActions','AIChatShortcuts','AITranslate'];class RevisionViewerIntegration extends _0x18ed42{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x45366e){function _0x33097e(_0x55c7ed){return _0x55c7ed['map'](_0x5dcbdb=>String['fromCharCode'](_0x5dcbdb))['join']('');}super(_0x45366e),this['result']='end',_0x45366e[_0x33097e([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x33097e([0x76,0x69,0x65,0x77])][_0x33097e([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x33097e([0x61,0x75,0x74,0x6f]),_0x45366e[_0x33097e([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x33097e([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x33097e([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x33097e([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x33097e([0x6f,0x6b])});}}class RevisionHistory extends _0x18ed42{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[RevisionTracker,RevisionHistoryUI];}constructor(_0x118676){if(super(_0x118676),!this['editor']['config']['get']('revisionHistory'))throw new _0x1f5a5b('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0xc3c8a5=>this['_showRevisionViewer']({..._0xc3c8a5,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x15aabe=>this['_closeRevisionViewer'](_0x15aabe)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x53aaef=>this['_restoreRevision'](_0x53aaef)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x423d8d){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x423d8d;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x56b804){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x56b804);}['getRevision'](_0x661238){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x661238);}['getRevisions'](_0x416205){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x416205||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x42a0c5=this['editor'],_0x1ff72f=_0x554e49(_0x42a0c5,It),_0x4402ff=_0x42a0c5['plugins']['get']('RevisionTracker'),_0x3c2bd3=_0x42a0c5['plugins']['get'](_0x4c4887)['users'];return _0x1ff72f['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x1ff72f['lazyRoots'],(_0x1ff72f['plugins']['push'](RevisionViewerIntegration,RevisionViewer,RevisionViewerUI,class RevisionViewerInit extends _0x18ed42{static get['requires'](){return[RevisionViewer,_0x4c4887];}['init'](){const _0x44f1ff=this['editor']['plugins']['get'](_0x4c4887);for(const _0x2bc809 of _0x3c2bd3)_0x2bc809['isAnonymous']||_0x44f1ff['getUser'](_0x2bc809['id'])||_0x44f1ff['addUser'](_0x2bc809);const _0x33be09=_0x4402ff['repository']['getRevisions']();let _0x1daa02=null;const _0x165344=this['editor']['plugins']['get']('RevisionViewer');_0x165344['adapter']=_0x4402ff['adapter'],_0x165344['bind']('isEnabled')['to'](_0x4402ff),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x42a0c5,'isReadOnly',_0x3ff5d7=>!_0x3ff5d7);for(const _0x26d11f of _0x33be09){const _0x273944=null===_0x26d11f['creator'];if(_0x273944&&_0x26d11f['toVersion']===_0x26d11f['fromVersion'])continue;const _0x49a8d1=_0x26d11f['toJSON']();_0x165344['addRevisionData'](_0x49a8d1,(_0x3886c6,_0x46fad3,_0x31d52c)=>{if(_0x273944){if(_0x1daa02)_0x1daa02['_update'](_0x3886c6,_0x46fad3);else{if(!_0x46fad3){const _0x3f500d=_0x31d52c['toJSON']();_0x3f500d['id']=_0x55087c(),_0x4402ff['saveRevision'](_0x3f500d,_0x31d52c['toVersion'])['then'](_0x41115c=>{_0x1daa02=_0x41115c;});}}}else _0x26d11f['_update'](_0x3886c6,_0x46fad3);});}}},RevisionsSidebar),_0x1ff72f);}['_enhanceShowRevisionViewerCallback'](){const _0xf28c12=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x3fd3c1=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x447f07=this['editor']['plugins']['get']('Autosave');await _0x447f07['save']();}else await _0x3fd3c1['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x5d268d=this['editor']['plugins']['get']('Dialog');_0x5d268d['isOpen']&&_0x5d268d['hide']();}if(this['editor']['plugins']['has']('AITabs')){const _0x3587aa=this['editor']['plugins']['get']('AITabs')['view']['panelViews'];for(const _0x4b4676 of _0x3587aa)_0x4b4676['class']=_0x4b4676['class']?_0x4b4676['class']+'\x20ck-tab-panel_disabled':'ck-tab-panel_disabled';if(this['editor']['plugins']['has']('AIChat')){const _0x11b976=document['querySelector']('.ck-ai-chat__prompt-input\x20.ck-textarea');_0x11b976&&_0x11b976['setAttribute']('tabindex','-1');}if(this['editor']['plugins']['has']('AIChatHistory')){const _0xcd86ab=document['querySelector']('.ck-ai-chat-history\x20.ck-input');_0xcd86ab&&_0xcd86ab['setAttribute']('tabindex','-1');}}const _0x38aa35=this['_getRevisionViewerEditorConfig']();return _0xf28c12(_0x38aa35)['then'](_0x281268=>{return(this['_viewerEditor']=_0x281268,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'),_0x281268);})['catch'](_0x320d6c=>(console['error'](_0x320d6c),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x3be552=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 _0x21ec5e=this['editor']['plugins']['get']('AITabs')['view']['panelViews'];for(const _0x197d52 of _0x21ec5e)_0x197d52['class']='ck-tab-panel_disabled'===_0x197d52['class']?'':_0x197d52['class']['replace']('\x20ck-tab-panel_disabled','');if(this['editor']['plugins']['has']('AIChat')){const _0x1ae869=document['querySelector']('.ck-ai-chat__prompt-input\x20.ck-textarea');_0x1ae869&&_0x1ae869['removeAttribute']('tabindex');}if(this['editor']['plugins']['has']('AIChatHistory')){const _0x425dd1=document['querySelector']('.ck-ai-chat-history\x20.ck-input');_0x425dd1&&_0x425dd1['removeAttribute']('tabindex');}}return this['_viewerEditor']['plugins']['get']('RevisionViewer')['_cleanUp'](),_0x3be552(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x177062=this['editor']['plugins']['get']('Annotations');_0x177062['refreshVisibility'](),_0x177062['refreshPositioning']();}});});}['_showRevisionViewer'](_0x7ebf95){const _0x595a90=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x581840=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x455657=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return RevisionViewerEditor['create'](_0x455657,_0x7ebf95)['then'](_0x1e793f=>(_0x581840['style']['display']='block',_0x595a90['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x1e793f));}['_closeRevisionViewer'](_0x497eae){const _0x40ec84=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x40ec84['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x497eae['destroy']();}async['_restoreRevision'](_0x11dd94){const _0x48ad1e=this['editor'],_0x2eba80=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0xf1e945=_0x48ad1e['plugins']['get']('RevisionTracker'),_0xabc710=_0x48ad1e['plugins']['get']('RevisionHistoryUtils'),_0x8ded6b=_0x2eba80['repository']['getRevision'](_0x11dd94);let _0x1d598c,_0x180891,_0x550707;try{await _0xabc710['loadRevisionData'](_0x8ded6b,this['adapter']),_0x1d598c=_0xabc710['getRevisionDocumentData'](_0x8ded6b),_0x180891=_0xabc710['getRevisionRootsAttributes'](_0x8ded6b);}catch(_0x25def1){return void console['error'](_0x25def1);}_0x48ad1e['model']['change'](_0x5aed60=>{for(const _0x4ae39d of Array['from'](_0x48ad1e['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x5aed60['removeMarker'](_0x4ae39d);}),_0x2eba80['isReady']=!0x1,_0x48ad1e['model']['enqueueChange'](_0x147cc1=>{_0x147cc1['setSelection'](null),_0x147cc1['removeSelectionAttribute'](_0x48ad1e['model']['document']['selection']['getAttributeKeys']());const _0x578b00=Object['keys'](_0x1d598c);for(const _0x67aa00 of _0x48ad1e['model']['document']['roots'])'$graveyard'!=_0x67aa00['rootName']&&_0x67aa00['isAttached']()&&!_0x578b00['includes'](_0x67aa00['rootName'])&&_0x147cc1['detachRoot'](_0x67aa00);for(const _0xad344e of _0x578b00){let _0x4f4afb=_0x48ad1e['model']['document']['getRoot'](_0xad344e);if(!_0x4f4afb||!_0x4f4afb['isAttached']()){const _0x3ca181=_0x8ded6b['diffData']?.[_0xad344e]?.['rootElementName']||'$root';_0x4f4afb=_0x147cc1['addRoot'](_0xad344e,_0x3ca181);}const _0x3fe02f=_0x180891[_0xad344e],_0x43cf0a=Object['keys'](_0x3fe02f),_0x21351d=_0x1d598c[_0xad344e];for(const _0xa1e2c3 of _0x4f4afb['getAttributeKeys']())_0x43cf0a['includes'](_0xa1e2c3)||_0x147cc1['removeAttribute'](_0xa1e2c3,_0x4f4afb);for(const _0x475ba0 of _0x43cf0a)_0x147cc1['setAttribute'](_0x475ba0,_0x180891[_0xad344e][_0x475ba0],_0x4f4afb);_0x147cc1['remove'](_0x147cc1['createRangeIn'](_0x4f4afb)),_0x147cc1['insert'](_0x48ad1e['data']['parse'](_0x21351d,_0x4f4afb),_0x4f4afb,0x0);}});const _0x4e0e41=ft(_0x48ad1e['locale'],'Restored');if(_0x8ded6b['name'])_0x550707=-0x1==_0x8ded6b['name']['indexOf'](_0x4e0e41)?_0x4e0e41+':\x20'+_0x8ded6b['name']:_0x8ded6b['name'];else _0x550707=_0x4e0e41+':\x20'+(_0x8ded6b['createdAt']['toLocaleDateString'](_0x48ad1e['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x8ded6b['createdAt']['toLocaleTimeString'](_0x48ad1e['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0xf1e945['saveRevision']({'name':_0x550707}),_0x2eba80['isReady']=!0x0,_0x48ad1e['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{RestoreRevisionCommand,Revision,RevisionHistory,RevisionHistoryUI,RevisionHistoryUtils,RevisionTracker,RevisionViewer,RevisionViewerEditor,RevisionViewerIntegration,RevisionViewerLoadingOverlay,RevisionViewerUI,RevisionsRepository,RevisionsSidebar,ShowChangeCommand};
|
|
29
|
+
kt();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[RevisionViewer];}constructor(_0x227219){super(_0x227219),this['_revisionViewer']=_0x227219['plugins']['get'](RevisionViewer),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x21125c=this['_revisionsRepository']['_revisions'],_0x5c9c41=this['_createRevisionActions'](),_0x3843e3=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new RevisionsSidebarView(this['editor']['locale'],_0x21125c,_0x5c9c41,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',(_0x29155c,_0x335fbe)=>{_0x335fbe['revisionViews']['on']('add',(_0x35fd6a,_0x449fc7)=>{_0x449fc7['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)),_0x3843e3['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x4f1985=this['_revisionsRepository']['getRevision'](0x0);if(_0x4f1985){const _0x482c07=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x4f1985['id']);this['_revisionViewer']['compare'](_0x4f1985,_0x482c07);}}['_handleRevisionSelected'](_0x1b7f6d,_0x487502){const _0x3b5523=this['_revisionsRepository']['getRevision'](_0x487502['id']),_0x41a1c2=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x3b5523['id']);this['_revisionViewer']['compare'](_0x3b5523,_0x41a1c2);}['_handleRevisionSetName'](_0x1bd895,_0x408a49){this['_revisionsRepository']['getRevision'](_0x408a49['id'])['setName'](_0x408a49['name']);}['_handleDiffChange'](_0x25d356,_0x149c79,_0x5a3051){const _0x29cea5=this['_revisionsRepository']['getRevisionsInDiff'](_0x5a3051);_0x29cea5['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x29cea5),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x29cea5[0x0]));}['_createRevisionActions'](){const _0x2a654d=this['editor'],_0x2c15ea=RevisionsSidebar['availableRevisionActions'],_0x594257=_0x2a654d['config']['get']('revisionHistory.revisionActions')||RevisionsSidebar['defaultRevisionActions'];if(_0x594257['length'])return _0x594257['map'](_0x51b8e3=>{const _0x2f6007='string'==typeof _0x51b8e3?Object['assign']({},_0x2c15ea[_0x51b8e3]):_0x51b8e3;return _0x2f6007['action']=_0x2f6007['action']['bind'](this,_0x2a654d),_0x2f6007['isVisible']&&(_0x2f6007['isVisible']=_0x2f6007['isVisible']['bind'](this,_0x2a654d)),_0x2f6007;});}}function kt(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x485f5b},_0x1762e9)=>{const _0x2e936f=_0x485f5b['get'](RevisionViewer),_0xebfede=_0x2e936f['repository'];let _0x4aa954=_0x2e936f['diff']['newRevisionId'],_0x5bfdf3=_0x1762e9['id'];_0xebfede['getIndex'](_0x4aa954)>_0xebfede['getIndex'](_0x5bfdf3)&&([_0x4aa954,_0x5bfdf3]=[_0x5bfdf3,_0x4aa954]),_0x2e936f['compare'](_0x4aa954,_0x5bfdf3);},'isVisible':({plugins:_0x4c4ca2},_0x295afe)=>{const _0x11d9c8=_0x4c4ca2['get'](RevisionViewer);return!(_0x11d9c8['repository']['getRevisionsInDiff'](_0x11d9c8['diff'])['length']>0x2)&&!_0x295afe['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x5c9556,{id:_0x5e0520})=>{_0x5c9556['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x5e0520);},'isVisible':({plugins:_0x5f14b2},_0x48bcef)=>!!_0x5f14b2['get'](RevisionViewer)['repository']['getLaterVisibleRevision'](_0x48bcef['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x43d540},{id:_0x1e3b7f,revisionNameView:_0x2e4300})=>{const _0x76c0e=_0x43d540['get'](RevisionViewer),_0x3e757a=_0x76c0e['repository']['getEarlierVisibleRevision'](_0x1e3b7f);_0x76c0e['compare'](_0x1e3b7f,_0x3e757a),_0x2e4300['focus'](),_0x2e4300['fieldView']['select']();}}};}class RevisionViewerEditorUI extends at{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x167372,_0x17f6f4){super(_0x167372),this['_view']=_0x17f6f4,this['_toolbarConfig']=ht(_0x167372['config']['get']('toolbar')),this['_elementReplacer']=new _0x4acda2();}get['element'](){return this['view']['element'];}['init'](_0x1c0db9){const _0x115b80=this['editor'],_0x40e973=this['view'],_0x3d1770=_0x115b80['editing']['view'],_0x4a87c4=_0x40e973['editable'],_0x3bed59=_0x3d1770['document']['getRoot']();_0x4a87c4['name']=_0x3bed59['rootName'],_0x40e973['render']();const _0x3858bf=_0x4a87c4['element'];this['setEditableElement'](_0x4a87c4['name'],_0x3858bf),_0x40e973['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x3d1770['attachDomRoot'](_0x3858bf),this['_elementReplacer']['replace'](_0x1c0db9,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x2b3488=this['view'],_0x3d62f7=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x3d62f7['detachDomRoot'](_0x2b3488['editable']['name']),_0x2b3488['destroy']();}['_initToolbar'](){const _0x21c161=this['view'];_0x21c161['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x21c161['stickyPanel']['limiterElement']=_0x21c161['element'],_0x21c161['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x163c20})=>_0x163c20),_0x21c161['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x21c161['toolbar']);}}class RevisionViewerEditorUIView extends ct{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x4e866c,_0x92f590,_0xe508e={}){super(_0x4e866c),this['stickyPanel']=new lt(_0x4e866c),this['toolbar']=new ut(_0x4e866c,{'shouldGroupWhenFull':_0xe508e['shouldToolbarGroupWhenFull']}),this['_editable']=new dt(_0x4e866c,_0x92f590);}['render'](){super['render'](),this['stickyPanel']['content']['add'](this['toolbar']),this['top']['add'](this['stickyPanel']),this['main']['add'](this['editable']);}}class RevisionViewerEditor extends/* #__PURE__ -- @preserve */
|
|
30
|
+
_0x26f772(_0x278490){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x30d062,_0x324efb){super(_0x324efb),this['sourceElement']=_0x30d062,this['model']['document']['createRoot']();const _0x178446=new RevisionViewerEditorUIView(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new RevisionViewerEditorUI(this,_0x178446);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x22d809,_0x594e46){const _0x3c4bdd=new this(_0x22d809,_0x594e46);return await _0x3c4bdd['initPlugins'](),await _0x3c4bdd['ui']['init'](_0x22d809),await _0x3c4bdd['data']['init'](_0x3c4bdd['config']['get']('initialData')||''),_0x3c4bdd['fire']('ready'),_0x3c4bdd;}}const It=['RevisionHistoryUI','RestrictedEditingMode','AIChat','AIReviewMode','AIBalloon','AIQuickActions','AIActions','AIChatShortcuts','AITranslate'];class RevisionViewerIntegration extends _0x538071{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x49cfe4){function _0x5e6a65(_0x540a43){return _0x540a43['map'](_0x101a32=>String['fromCharCode'](_0x101a32))['join']('');}super(_0x49cfe4),this['result']='end',_0x49cfe4[_0x5e6a65([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x5e6a65([0x76,0x69,0x65,0x77])][_0x5e6a65([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x5e6a65([0x61,0x75,0x74,0x6f]),_0x49cfe4[_0x5e6a65([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x5e6a65([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x5e6a65([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x5e6a65([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x5e6a65([0x6f,0x6b])});}}class RevisionHistory extends _0x538071{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[RevisionTracker,RevisionHistoryUI];}constructor(_0x264422){if(super(_0x264422),!this['editor']['config']['get']('revisionHistory'))throw new _0x423177('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x4a757f=>this['_showRevisionViewer']({..._0x4a757f,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x22069a=>this['_closeRevisionViewer'](_0x22069a)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x56da53=>this['_restoreRevision'](_0x56da53)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x3e5258){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x3e5258;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x584264){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x584264);}['getRevision'](_0x55530f){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x55530f);}['getRevisions'](_0x582463){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x582463||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x38d81a=this['editor'],_0x5454fa=_0x21c68e(_0x38d81a,It),_0x5eb4c5=_0x38d81a['plugins']['get']('RevisionTracker'),_0x123db3=_0x38d81a['plugins']['get'](_0x2baa1d)['users'];return _0x5454fa['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x5454fa['lazyRoots'],(_0x5454fa['plugins']['push'](RevisionViewerIntegration,RevisionViewer,RevisionViewerUI,class RevisionViewerInit extends _0x538071{static get['requires'](){return[RevisionViewer,_0x2baa1d];}['init'](){const _0x130a3b=this['editor']['plugins']['get'](_0x2baa1d);for(const _0x534a86 of _0x123db3)_0x534a86['isAnonymous']||_0x130a3b['getUser'](_0x534a86['id'])||_0x130a3b['addUser'](_0x534a86);const _0x41eac1=_0x5eb4c5['repository']['getRevisions']();let _0x5944d2=null;const _0x814115=this['editor']['plugins']['get']('RevisionViewer');_0x814115['adapter']=_0x5eb4c5['adapter'],_0x814115['bind']('isEnabled')['to'](_0x5eb4c5),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x38d81a,'isReadOnly',_0x462ebb=>!_0x462ebb);for(const _0x3efddb of _0x41eac1){const _0x19b5e6=null===_0x3efddb['creator'];if(_0x19b5e6&&_0x3efddb['toVersion']===_0x3efddb['fromVersion'])continue;const _0x4c82cc=_0x3efddb['toJSON']();_0x814115['addRevisionData'](_0x4c82cc,(_0x2493d6,_0x3f6772,_0x4ed8cb)=>{if(_0x19b5e6){if(_0x5944d2)_0x5944d2['_update'](_0x2493d6,_0x3f6772);else{if(!_0x3f6772){const _0x13f9bf=_0x4ed8cb['toJSON']();_0x13f9bf['id']=_0x51ceb2(),_0x5eb4c5['saveRevision'](_0x13f9bf,_0x4ed8cb['toVersion'])['then'](_0x39cb61=>{_0x5944d2=_0x39cb61;});}}}else _0x3efddb['_update'](_0x2493d6,_0x3f6772);});}}},RevisionsSidebar),_0x5454fa);}['_enhanceShowRevisionViewerCallback'](){const _0x2c64ae=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0xd083d4=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x90b6a7=this['editor']['plugins']['get']('Autosave');await _0x90b6a7['save']();}else await _0xd083d4['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x30581e=this['editor']['plugins']['get']('Dialog');_0x30581e['isOpen']&&_0x30581e['hide']();}if(this['editor']['plugins']['has']('AITabs')){const _0x11d570=this['editor']['plugins']['get']('AITabs')['view']['panelViews'];for(const _0x4fc634 of _0x11d570)_0x4fc634['class']=_0x4fc634['class']?_0x4fc634['class']+'\x20ck-tab-panel_disabled':'ck-tab-panel_disabled';if(this['editor']['plugins']['has']('AIChat')){const _0x4e2bf4=document['querySelector']('.ck-ai-chat__prompt-input\x20.ck-textarea');_0x4e2bf4&&_0x4e2bf4['setAttribute']('tabindex','-1');}if(this['editor']['plugins']['has']('AIChatHistory')){const _0x2d1bb6=document['querySelector']('.ck-ai-chat-history\x20.ck-input');_0x2d1bb6&&_0x2d1bb6['setAttribute']('tabindex','-1');}}const _0x235bdd=this['_getRevisionViewerEditorConfig']();return _0x2c64ae(_0x235bdd)['then'](_0x593705=>{return(this['_viewerEditor']=_0x593705,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'),_0x593705);})['catch'](_0x523aa0=>(console['error'](_0x523aa0),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x2be4c7=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 _0x5bf701=this['editor']['plugins']['get']('AITabs')['view']['panelViews'];for(const _0x1f2318 of _0x5bf701)_0x1f2318['class']='ck-tab-panel_disabled'===_0x1f2318['class']?'':_0x1f2318['class']['replace']('\x20ck-tab-panel_disabled','');if(this['editor']['plugins']['has']('AIChat')){const _0x21c3a7=document['querySelector']('.ck-ai-chat__prompt-input\x20.ck-textarea');_0x21c3a7&&_0x21c3a7['removeAttribute']('tabindex');}if(this['editor']['plugins']['has']('AIChatHistory')){const _0x594fb3=document['querySelector']('.ck-ai-chat-history\x20.ck-input');_0x594fb3&&_0x594fb3['removeAttribute']('tabindex');}}return this['_viewerEditor']['plugins']['get']('RevisionViewer')['_cleanUp'](),_0x2be4c7(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x40bc5d=this['editor']['plugins']['get']('Annotations');_0x40bc5d['refreshVisibility'](),_0x40bc5d['refreshPositioning']();}});});}['_showRevisionViewer'](_0x2fb4a4){const _0xa5650b=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x326c1c=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x43e08b=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return RevisionViewerEditor['create'](_0x43e08b,_0x2fb4a4)['then'](_0x452fe6=>(_0x326c1c['style']['display']='block',_0xa5650b['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x452fe6));}['_closeRevisionViewer'](_0x20e5fe){const _0x2ac452=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x2ac452['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x20e5fe['destroy']();}async['_restoreRevision'](_0x431c98){const _0x107210=this['editor'],_0x404013=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x1ceed1=_0x107210['plugins']['get']('RevisionTracker'),_0x3610db=_0x107210['plugins']['get']('RevisionHistoryUtils'),_0x3e8d5f=_0x404013['repository']['getRevision'](_0x431c98);let _0x3e2678,_0x28f619,_0xf51379;try{await _0x3610db['loadRevisionData'](_0x3e8d5f,this['adapter']),_0x3e2678=_0x3610db['getRevisionDocumentData'](_0x3e8d5f),_0x28f619=_0x3610db['getRevisionRootsAttributes'](_0x3e8d5f);}catch(_0x3aaa59){return void console['error'](_0x3aaa59);}_0x107210['model']['change'](_0x327e00=>{for(const _0x5447aa of Array['from'](_0x107210['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x327e00['removeMarker'](_0x5447aa);}),_0x404013['isReady']=!0x1,_0x107210['model']['enqueueChange'](_0x267580=>{_0x267580['setSelection'](null),_0x267580['removeSelectionAttribute'](_0x107210['model']['document']['selection']['getAttributeKeys']());const _0x40f7ff=Object['keys'](_0x3e2678);for(const _0x399431 of _0x107210['model']['document']['roots'])'$graveyard'!=_0x399431['rootName']&&_0x399431['isAttached']()&&!_0x40f7ff['includes'](_0x399431['rootName'])&&_0x267580['detachRoot'](_0x399431);for(const _0x82696e of _0x40f7ff){let _0x3f62a2=_0x107210['model']['document']['getRoot'](_0x82696e);if(!_0x3f62a2||!_0x3f62a2['isAttached']()){const _0x51b12d=_0x3e8d5f['diffData']?.[_0x82696e]?.['rootElementName']||'$root';_0x3f62a2=_0x267580['addRoot'](_0x82696e,_0x51b12d);}const _0x26fb4b=_0x28f619[_0x82696e],_0x14d467=Object['keys'](_0x26fb4b),_0x41eb21=_0x3e2678[_0x82696e];for(const _0x2a6693 of _0x3f62a2['getAttributeKeys']())_0x14d467['includes'](_0x2a6693)||_0x267580['removeAttribute'](_0x2a6693,_0x3f62a2);for(const _0x25c5aa of _0x14d467)_0x267580['setAttribute'](_0x25c5aa,_0x28f619[_0x82696e][_0x25c5aa],_0x3f62a2);_0x267580['remove'](_0x267580['createRangeIn'](_0x3f62a2)),_0x267580['insert'](_0x107210['data']['parse'](_0x41eb21,_0x3f62a2),_0x3f62a2,0x0);}});const _0x36ca26=ft(_0x107210['locale'],'Restored');if(_0x3e8d5f['name'])_0xf51379=-0x1==_0x3e8d5f['name']['indexOf'](_0x36ca26)?_0x36ca26+':\x20'+_0x3e8d5f['name']:_0x3e8d5f['name'];else _0xf51379=_0x36ca26+':\x20'+(_0x3e8d5f['createdAt']['toLocaleDateString'](_0x107210['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x3e8d5f['createdAt']['toLocaleTimeString'](_0x107210['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x1ceed1['saveRevision']({'name':_0xf51379}),_0x404013['isReady']=!0x0,_0x107210['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{RestoreRevisionCommand,Revision,RevisionHistory,RevisionHistoryUI,RevisionHistoryUtils,RevisionTracker,RevisionViewer,RevisionViewerEditor,RevisionViewerIntegration,RevisionViewerLoadingOverlay,RevisionViewerUI,RevisionsRepository,RevisionsSidebar,ShowChangeCommand};
|