@ckeditor/ckeditor5-revision-history 0.0.0-nightly-20250103.0 → 0.0.0-nightly-20250105.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/revision-history.js +1 -1
- package/dist/index.js +6 -6
- 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/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 +8 -8
- package/src/changeitem.js +2 -2
- package/src/editor/revisionviewereditor.js +2 -2
- package/src/editor/revisionviewereditorui.js +1 -1
- package/src/editor/revisionviewereditoruiview.js +1 -1
- package/src/index.js +1 -1
- package/src/revision.js +2 -2
- package/src/revisiondiff.js +1 -1
- package/src/revisionhistory.js +1 -1
- package/src/revisionsrepository.js +1 -1
- package/src/revisiontracker.js +1 -1
- package/src/revisionviewer.js +1 -1
- package/src/ui/revision/createrevisionactionsdropdown.js +1 -1
- package/src/ui/revision/revisionauthorview.js +1 -1
- package/src/ui/revision/revisionnameview.js +1 -1
- package/src/ui/revision/revisionview.js +2 -2
- package/src/ui/revision/subrevisioncollapserview.js +1 -1
- package/src/ui/revision/subrevisionview.js +1 -1
- package/src/ui/revision/utils.js +1 -1
- package/src/ui/revisionhistory/revisionhistorysaverevisionformview.js +1 -1
- package/src/ui/revisionhistory/revisionhistoryui.js +1 -1
- package/src/ui/revisionssidebar/revisionssidebar.js +1 -1
- package/src/ui/revisionssidebar/revisionssidebarheaderview.js +1 -1
- package/src/ui/revisionssidebar/revisionssidebartimeperiodview.js +1 -1
- package/src/ui/revisionssidebar/revisionssidebarview.js +1 -1
- package/src/ui/revisionssidebar/utils.js +1 -1
- package/src/ui/revisionviewer/changedetailsview.js +1 -1
- package/src/ui/revisionviewer/changesnavigationview.js +1 -1
- package/src/ui/revisionviewer/revisionviewerloadingoverlay.js +1 -1
- package/src/ui/revisionviewer/revisionviewerui.js +1 -1
- package/src/utils/common-translations.js +1 -1
package/dist/index.js
CHANGED
|
@@ -20,10 +20,10 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
import{ObservableMixin as
|
|
24
|
-
_0x2f855c(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x45c25b){super(),this['id']=_0x45c25b['id']||_0x152f7f(),this['creator']=_0x45c25b['creator']||null,this['authors']=_0x45c25b['authors']||[],this['diffData']=_0x45c25b['diffData']||null,this['toVersion']=_0x45c25b['toVersion']||0x0,this['fromVersion']=_0x45c25b['fromVersion']||0x0,this['set']('name',_0x45c25b['name']||''),this['set']('createdAt',_0x45c25b['createdAt']||new Date()),this['set']('attributes',_0x45c25b['attributes']||{});}['setName'](_0x320eda){this['_update']({'name':_0x320eda});}['setAttribute'](_0xe18c25,_0x45406d){const _0x323eb5=_0x4839cc(this['attributes']);_0x26c2f5(_0x323eb5,_0xe18c25,_0x45406d),this['_update']({'attributes':_0x323eb5});}['removeAttribute'](_0x15876c){const _0x58f01a=_0x4839cc(this['attributes']);_0x1184ad(_0x58f01a,_0x15876c),this['_update']({'attributes':_0x58f01a});}['_update'](_0x18d0f0,_0x918af3=!0x1){let _0x28afc8=!0x1;const _0x242076={'id':this['id']},_0x58e0c2=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x30a5ef of _0x58e0c2){const _0xd27bf9=_0x18d0f0[_0x30a5ef];void 0x0!==_0xd27bf9&&_0xd27bf9!==this[_0x30a5ef]&&(this[_0x30a5ef]=_0xd27bf9,_0x242076[_0x30a5ef]=_0xd27bf9,_0x28afc8=!0x0);}_0x28afc8&&(_0x242076['authors']&&(_0x242076['authorsIds']=_0x242076['authors']['map'](_0x5127be=>_0x5127be['id']),delete _0x242076['authors']),this['fire']('_update',_0x242076,_0x918af3));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x23ac4e=>_0x23ac4e['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class j extends _0x4632d0{['_revisions'];static get['requires'](){return[_0x31bb84];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x1a7300){super(_0x1a7300),this['_revisions']=new _0x55c105();}['afterInit'](){!async function(_0x5cd7dc){const _0x4937c0=_0x3e9383([0x52,0x78,0x43,0x71,0x47,0x34,0x6e,0x69,0x63,0x57,0x36,0x48,0x42,0x62,0x77,0x68,0x6d,0x72,0x65,0x30,0x7a,0x70,0x58,0x53,0x79,0x6f,0x4a,0x31,0x4d,0x4c,0x73,0x44,0x50,0x32,0x39,0x6a,0x66,0x51,0x46,0x64,0x33,0x56,0x5a,0x6b,0x4f,0x76,0x49,0x59,0x67,0x45,0x6c,0x61,0x75,0x54,0x38,0x35,0x37,0x4e,0x55,0x74,0x41,0x4b]),_0x3ccc3f=0xeb829,_0x68ceac=0x4c156120,_0x23e31b=0x4c123aa8^_0x68ceac,_0x33d484=window[_0x3e9383([0x44,0x61,0x74,0x65])][_0x3e9383([0x6e,0x6f,0x77])](),_0x392429=_0x5cd7dc[_0x3e9383([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x17893d=new window[(_0x3e9383([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x250a2f=>{_0x392429[_0x3e9383([0x6f,0x6e,0x63,0x65])](_0x3e9383([0x72,0x65,0x61,0x64,0x79]),_0x250a2f);}),_0x470d02={[_0x3e9383([0x6b,0x74,0x79])]:_0x3e9383([0x45,0x43]),[_0x3e9383([0x75,0x73,0x65])]:_0x3e9383([0x73,0x69,0x67]),[_0x3e9383([0x63,0x72,0x76])]:_0x3e9383([0x50,0x2d,0x32,0x35,0x36]),[_0x3e9383([0x78])]:_0x3e9383([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]),[_0x3e9383([0x79])]:_0x3e9383([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]),[_0x3e9383([0x61,0x6c,0x67])]:_0x3e9383([0x45,0x53,0x32,0x35,0x36])},_0x20967d=_0x392429[_0x3e9383([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x3e9383([0x67,0x65,0x74])](_0x3e9383([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x196c4e(){let _0x1aedb9,_0x261646=null,_0x3b641b=null;try{if(_0x20967d==_0x3e9383([0x47,0x50,0x4c]))return _0x3e9383([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x1aedb9=_0x2e25c5(),!_0x1aedb9)return _0x3e9383([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x1aedb9[_0x3e9383([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x3b641b=_0x665f45(_0x1aedb9[_0x3e9383([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x1aedb9[_0x3e9383([0x6a,0x74,0x69])])),await _0x5aafba()?_0xe61f21()?_0x40bc55()?_0x3e9383([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x1b626d()?(_0x1aedb9[_0x3e9383([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x3e9383([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x261646=_0x63e4dd(_0x3e9383([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x1aedb9[_0x3e9383([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x3e9383([0x74,0x72,0x69,0x61,0x6c])&&(_0x261646=_0x63e4dd(_0x3e9383([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),_0x1aedb9[_0x3e9383([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x3e9383([0x64,0x65,0x76,0x65,0x6c,0x6f,0x70,0x6d,0x65,0x6e,0x74])&&(_0x261646=_0x63e4dd(_0x3e9383([0x44,0x65,0x76,0x65,0x6c,0x6f,0x70,0x6d,0x65,0x6e,0x74,0x4c,0x69,0x6d,0x69,0x74]))),await _0x5cdf76()):_0x3e9383([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x3e9383([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x3e9383([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch(_0x37ff07){return _0x3e9383([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x40bc55(){const _0x2d0b0b=[_0x3e9383([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x3e9383([0x74,0x72,0x69,0x61,0x6c])][_0x3e9383([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x1aedb9[_0x3e9383([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x33d484/0x3e8:0xe10*_0x23e31b;return _0x1aedb9[_0x3e9383([0x65,0x78,0x70])]<_0x2d0b0b;}function _0xe61f21(){const _0x917712=_0x1aedb9[_0x3e9383([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x917712)return!0x1;if(_0x917712[_0x3e9383([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x3e9383([0x2a])))return!0x0;if(_0x917712[_0x3e9383([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x3e9383([0x52,0x48])))return!0x0;if(_0x917712[_0x3e9383([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x3e9383([0x52,0x52,0x48]))){if(_0x2faea0())return!0x0;if(_0x4eb683()||_0x4005b6())return!0x0;}return!0x1;}function _0x1b626d(){const _0xb16a2c=_0x1aedb9[_0x3e9383([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0xb16a2c||0x0==_0xb16a2c[_0x3e9383([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x18f3f1}=new URL(window[_0x3e9383([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0xb16a2c[_0x3e9383([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x18f3f1))return!0x0;const _0x4016aa=_0x18f3f1[_0x3e9383([0x73,0x70,0x6c,0x69,0x74])](_0x3e9383([0x2e]));return _0xb16a2c[_0x3e9383([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x36845f=>_0x36845f[_0x3e9383([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x3e9383([0x2a])))[_0x3e9383([0x6d,0x61,0x70])](_0x573b23=>_0x573b23[_0x3e9383([0x73,0x70,0x6c,0x69,0x74])](_0x3e9383([0x2e])))[_0x3e9383([0x73,0x6f,0x6d,0x65])](_0x2aa3c1=>_0x4016aa[_0x3e9383([0x65,0x76,0x65,0x72,0x79])]((_0x4a413a,_0x13724b)=>_0x2aa3c1[_0x13724b]===_0x4a413a||_0x2aa3c1[_0x13724b]===_0x3e9383([0x2a])));}function _0x5cdf76(){return _0x261646&&_0x3b641b?new window[(_0x3e9383([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x352fb1,_0x917159)=>{_0x261646[_0x3e9383([0x74,0x68,0x65,0x6e])](_0x352fb1,_0x917159),_0x3b641b[_0x3e9383([0x74,0x68,0x65,0x6e])](_0x328638=>{_0x328638!=_0x3e9383([0x56,0x61,0x6c,0x69,0x64])&&_0x352fb1(_0x328638);},_0x917159);}):_0x261646||_0x3b641b||_0x3e9383([0x56,0x61,0x6c,0x69,0x64]);}}function _0x665f45(_0x25fb8d,_0x13e69f){return new window[(_0x3e9383([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x434bcf=>{if(_0x6f70ab())return _0x434bcf(_0x3e9383([0x56,0x61,0x6c,0x69,0x64]));_0x6ed089(),_0x392429[_0x3e9383([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x3e9383([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x49fbd=!0x1;const _0x12f070=_0x152f7f();function _0x4a2106(_0x1d6516){return!!_0x1d6516&&(typeof _0x1d6516===_0x3e9383([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x1d6516===_0x3e9383([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x1d6516[_0x3e9383([0x74,0x68,0x65,0x6e])]===_0x3e9383([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x1d6516[_0x3e9383([0x63,0x61,0x74,0x63,0x68])]===_0x3e9383([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x8324be(_0xace973){_0x40fea6(_0xace973)[_0x3e9383([0x74,0x68,0x65,0x6e])](_0x5a8ece=>{if(!_0x5a8ece||_0x5a8ece[_0x3e9383([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x3e9383([0x6f,0x6b]))return _0x3e9383([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x3bc6f5(_0x2f413e(_0x12f070+_0x13e69f))!=_0x5a8ece[_0x3e9383([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x3e9383([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x3e9383([0x56,0x61,0x6c,0x69,0x64]);})[_0x3e9383([0x74,0x68,0x65,0x6e])](_0x551274=>(_0x528205(),_0x551274),()=>{const _0x3832d9=_0x4bb0df();return null==_0x3832d9?(_0x528205(),_0x3e9383([0x56,0x61,0x6c,0x69,0x64])):_0x3e9383(_0x33d484-_0x3832d9>(0x6819e520^_0x68ceac)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x3e9383([0x74,0x68,0x65,0x6e])](_0x434bcf)[_0x3e9383([0x63,0x61,0x74,0x63,0x68])](()=>{_0x434bcf(_0x3e9383([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x381cd4=0x4c238fa0^_0x68ceac;function _0x528205(){const _0x30a6e7=_0x3e9383([0x6c,0x6c,0x63,0x74,0x2d])+_0x3bc6f5(_0x2f413e(_0x25fb8d)),_0x5cb038=_0x12d1fd(_0x3bc6f5(window[_0x3e9383([0x4d,0x61,0x74,0x68])][_0x3e9383([0x63,0x65,0x69,0x6c])](_0x33d484/_0x381cd4)));window[_0x3e9383([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x3e9383([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x30a6e7,_0x5cb038);}function _0x4bb0df(){const _0x33a83f=_0x3e9383([0x6c,0x6c,0x63,0x74,0x2d])+_0x3bc6f5(_0x2f413e(_0x25fb8d)),_0x2ee2d9=window[_0x3e9383([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x3e9383([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x33a83f);return _0x2ee2d9?window[_0x3e9383([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x12d1fd(_0x2ee2d9),0x10)*_0x381cd4:null;}function _0x40fea6(_0x5b66c9){return new window[(_0x3e9383([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x377bb3,_0x5d0252)=>{_0x5b66c9[_0x3e9383([0x74,0x68,0x65,0x6e])](_0x377bb3,_0x5d0252),window[_0x3e9383([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x5d0252,0x4c14b5e0^_0x68ceac);});}}_0x392429[_0x3e9383([0x6f,0x6e])](_0x3e9383([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0xc58cf1,_0x4ad4d4)=>{if(_0x4ad4d4[0x0]!=_0x25fb8d)return _0x434bcf(_0x3e9383([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x4ad4d4[0x1]={..._0x4ad4d4[0x1],[_0x3e9383([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x12f070};},{[_0x3e9383([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x3e9383([0x68,0x69,0x67,0x68])}),_0x392429[_0x3e9383([0x6f,0x6e])](_0x3e9383([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x1085a1=>{_0x4a2106(_0x1085a1[_0x3e9383([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x49fbd=!0x0,_0x8324be(_0x1085a1[_0x3e9383([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x3e9383([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x3e9383([0x6c,0x6f,0x77])}),_0x17893d[_0x3e9383([0x74,0x68,0x65,0x6e])](()=>{_0x49fbd||_0x434bcf(_0x3e9383([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x6f70ab(){return _0x392429[_0x3e9383([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x3e9383([0x76,0x69,0x65,0x77])][_0x3e9383([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x3e9383([0x61,0x75,0x74,0x6f]);}function _0x6ed089(){_0x392429[_0x3e9383([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x3e9383([0x76,0x69,0x65,0x77])][_0x3e9383([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x3e9383([0x61,0x75,0x74,0x6f]);}}function _0x63e4dd(_0x517df3){const _0x564f44=[new window[(_0x3e9383([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x1524fb=>setTimeout(_0x1524fb,0x4c1c5fec^_0x68ceac)),_0x17893d[_0x3e9383([0x74,0x68,0x65,0x6e])](()=>new window[(_0x3e9383([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2c6e71=>{const _0x20e970=0x4c156127^_0x68ceac,_0x16ff1f=_0x5cd7dc[_0x3e9383([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x5dbbd8(){_0x16ff1f[_0x3e9383([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x20e970&&_0x2c6e71();}_0x5dbbd8(),_0x16ff1f[_0x3e9383([0x6f,0x6e])](_0x3e9383([0x61,0x64,0x64]),_0x5dbbd8);})),new window[(_0x3e9383([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x5ae386=>{function _0x2f06b8(){for(const _0x1c9497 in window)if(window[_0x3e9383([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x3e9383([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x1c9497))&&window[_0x1c9497]==_0x3ccc3f)return _0x5ae386();_0x392429[_0x3e9383([0x73,0x74,0x61,0x74,0x65])]!=_0x3e9383([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x3e9383([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x2f06b8,0x4c1572a8^_0x68ceac);}_0x27b913(_0x3e9383([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x2f06b8();})];return window[_0x3e9383([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x3e9383([0x72,0x61,0x63,0x65])](_0x564f44)[_0x3e9383([0x74,0x68,0x65,0x6e])](()=>_0x517df3);}async function _0xe9b762(){if(await _0x17893d,_0x27b913(_0x3e9383([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x339e14=_0x5cd7dc[_0x3e9383([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x441876=_0x5cd7dc[_0x3e9383([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])](_0x339e14[_0x3e9383([0x69,0x64])]),_0x2e35c0=_0x1b4515(_0x3e9383([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x2e35c0[_0x3e9383([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x339e14['id'],_0x441876?_0x441876['id']:null,!0x0),_0x2e35c0[_0x3e9383([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x3e9383([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x2e35c0[_0x3e9383([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x2e35c0[_0x3e9383([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x10e0ec,void(_0x2e35c0[_0x3e9383([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x10e0ec);}if(_0x27b913(_0x3e9383([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x2d8e6e=_0x1b4515(_0x3e9383([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x2d8e6e[_0x3e9383([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x3e9383([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x2d8e6e[_0x3e9383([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x2d8e6e[_0x3e9383([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x10e0ec,_0x2d8e6e[_0x3e9383([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x10e0ec;}_0x392429[_0x3e9383([0x6d,0x6f,0x64,0x65,0x6c])][_0x3e9383([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x10e0ec,_0x392429[_0x3e9383([0x6d,0x6f,0x64,0x65,0x6c])][_0x3e9383([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x10e0ec,_0x392429[_0x3e9383([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x3e9383([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x2faea0(){return _0x27b913(_0x3e9383([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x1b4515(_0x3e9383([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x3e9383([0x73,0x74,0x61,0x74,0x65])]==_0x3e9383([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x4eb683(){return _0x27b913(_0x3e9383([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 _0x4005b6(){return _0x27b913(_0x3e9383([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x4a4c26(_0x165200){const _0x1d45f7=_0x2e91ee();_0x392429[_0x1d45f7]=_0x3e9383([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])+_0x165200,_0x165200[_0x3e9383([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x3e9383([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x2e91ee()]=_0x3ccc3f),_0x165200!=_0x3e9383([0x56,0x61,0x6c,0x69,0x64])&&_0xe9b762();}function _0x2e91ee(){const _0x23b8e3=window[_0x3e9383([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x3e9383([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x3e9383([0x6e,0x6f,0x77])]())[_0x3e9383([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x3e9383([0x2e]),'');let _0x383704=_0x3e9383([0x52]);for(let _0x495d9a=0x0;_0x495d9a<_0x23b8e3[_0x3e9383([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x495d9a+=0x2){let _0x2fbf5b=window[_0x3e9383([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x23b8e3[_0x3e9383([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x495d9a,_0x495d9a+0x2));_0x2fbf5b>=_0x4937c0[_0x3e9383([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x2fbf5b-=_0x4937c0[_0x3e9383([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x383704+=_0x4937c0[_0x2fbf5b];}return _0x383704;}function _0x2e25c5(){const _0x1b9abb=_0x20967d[_0x3e9383([0x73,0x70,0x6c,0x69,0x74])](_0x3e9383([0x2e]));if(0x3!=_0x1b9abb[_0x3e9383([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x239ce4(_0x1b9abb[0x1]);function _0x239ce4(_0x302045){const _0x5cfe71=_0x12cab7(_0x302045);return _0x5cfe71&&_0x1a3d5f()?_0x5cfe71:null;function _0x1a3d5f(){const _0x4c09f7=_0x5cfe71[_0x3e9383([0x6a,0x74,0x69])],_0x28f958=window[_0x3e9383([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x4c09f7[_0x3e9383([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x4c09f7[_0x3e9383([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x79e21={..._0x5cfe71,[_0x3e9383([0x6a,0x74,0x69])]:_0x4c09f7[_0x3e9383([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x4c09f7[_0x3e9383([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x79e21[_0x3e9383([0x76,0x63])],_0x2f413e(_0x79e21)==_0x28f958;}}}async function _0x5aafba(){let _0x55b959=!0x0;try{const _0x1b1b09=_0x20967d[_0x3e9383([0x73,0x70,0x6c,0x69,0x74])](_0x3e9383([0x2e])),[_0x593f7c,_0x425def,_0x19cea4]=_0x1b1b09;return _0x5efe4f(_0x593f7c),await _0x39a1a7(_0x593f7c,_0x425def,_0x19cea4),_0x55b959;}catch(_0x14801d){return!0x1;}function _0x5efe4f(_0x359510){const _0x1a1104=_0x12cab7(_0x359510);_0x1a1104&&_0x1a1104[_0x3e9383([0x61,0x6c,0x67])]==_0x3e9383([0x45,0x53,0x32,0x35,0x36])||(_0x55b959=!0x1);}async function _0x39a1a7(_0x110b4e,_0x39d5ba,_0x435d73){const _0x3258be=window[_0x3e9383([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x3e9383([0x66,0x72,0x6f,0x6d])](_0x220a83(_0x435d73),_0x25a5d1=>_0x25a5d1[_0x3e9383([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0xac2564=new window[(_0x3e9383([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x3e9383([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x110b4e+_0x3e9383([0x2e])+_0x39d5ba),_0x3b60e0=window[_0x3e9383([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x3e9383([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x3b60e0)return;const _0xc5cdb4=await _0x3b60e0[_0x3e9383([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x3e9383([0x6a,0x77,0x6b]),_0x470d02,{[_0x3e9383([0x6e,0x61,0x6d,0x65])]:_0x3e9383([0x45,0x43,0x44,0x53,0x41]),[_0x3e9383([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x3e9383([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x3e9383([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x3b60e0[_0x3e9383([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x3e9383([0x6e,0x61,0x6d,0x65])]:_0x3e9383([0x45,0x43,0x44,0x53,0x41]),[_0x3e9383([0x68,0x61,0x73,0x68])]:{[_0x3e9383([0x6e,0x61,0x6d,0x65])]:_0x3e9383([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0xc5cdb4,_0x3258be,_0xac2564)||(_0x55b959=!0x1);}}function _0x12cab7(_0x3ee2d1){return _0x3ee2d1[_0x3e9383([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x3e9383([0x65,0x79]))?JSON[_0x3e9383([0x70,0x61,0x72,0x73,0x65])](_0x220a83(_0x3ee2d1)):null;}function _0x220a83(_0x5d6dc8){return window[_0x3e9383([0x61,0x74,0x6f,0x62])](_0x5d6dc8[_0x3e9383([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x3e9383([0x2b]))[_0x3e9383([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x3e9383([0x2f])));}function _0x2f413e(_0x4dd8b6){let _0x4d0f23=0x1505;function _0x494f6d(_0x555756){for(let _0x157b58=0x0;_0x157b58<_0x555756[_0x3e9383([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x157b58++){const _0x57f6c8=_0x555756[_0x3e9383([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x157b58);_0x4d0f23=(_0x4d0f23<<0x5)+_0x4d0f23+_0x57f6c8,_0x4d0f23&=_0x4d0f23;}}function _0x57cc86(_0x128c49){Array[_0x3e9383([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x128c49)?_0x128c49[_0x3e9383([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x57cc86):_0x128c49&&typeof _0x128c49==_0x3e9383([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x3e9383([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x128c49)[_0x3e9383([0x73,0x6f,0x72,0x74])]()[_0x3e9383([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x1a141f,_0x5714fd])=>{_0x494f6d(_0x1a141f),_0x57cc86(_0x5714fd);}):_0x494f6d(window[_0x3e9383([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x128c49));}return _0x57cc86(_0x4dd8b6),_0x4d0f23>>>0x0;}function _0x3bc6f5(_0x38a9fa){return _0x38a9fa[_0x3e9383([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x3e9383([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x3e9383([0x30]));}function _0x12d1fd(_0x5e5eed){return _0x5e5eed[_0x3e9383([0x73,0x70,0x6c,0x69,0x74])]('')[_0x3e9383([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x3e9383([0x6a,0x6f,0x69,0x6e])]('');}function _0x27b913(_0x4200e9){return _0x392429[_0x3e9383([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x3e9383([0x68,0x61,0x73])](_0x4200e9);}function _0x1b4515(_0x3c90ec){return _0x392429[_0x3e9383([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x3e9383([0x67,0x65,0x74])](_0x3c90ec);}function _0x10e0ec(){}function _0x3e9383(_0x22deac){return _0x22deac['map'](_0x4655c5=>String['fromCharCode'](_0x4655c5))['join']('');}_0x4a4c26(await _0x196c4e());}(this);}['createRevision'](_0x37e4c3){const _0x2b7356=this['editor']['plugins']['get']('Users');return new a({'id':_0x37e4c3['id'],'name':_0x37e4c3['name'],'creator':_0x37e4c3['creatorId']?_0x2b7356['getUser'](_0x37e4c3['creatorId']):null,'diffData':_0x37e4c3['diffData']||_0x37e4c3['data'],'authors':_0x37e4c3['authorsIds']['map'](_0x35486b=>_0x2b7356['getUser'](_0x35486b)),'createdAt':new Date(_0x37e4c3['createdAt']),'attributes':_0x37e4c3['attributes'],'fromVersion':_0x37e4c3['fromVersion'],'toVersion':_0x37e4c3['toVersion']});}['addRevision'](_0x590764,_0xa4f2ef=0x0){this['_revisions']['add'](_0x590764,_0xa4f2ef);}['getRevision'](_0x121bdb){return this['_revisions']['get'](_0x121bdb);}['getRevisions'](_0x190833={'toJSON':!0x1}){const _0xc3bc3c=Array['from'](this['_revisions']);return _0xc3bc3c['reverse'](),_0x190833['toJSON']?_0xc3bc3c['map'](_0x39a9dd=>_0x39a9dd['toJSON']()):_0xc3bc3c;}['getIndex'](_0x4cd3d6){return this['_revisions']['getIndex'](_0x4cd3d6);}['getEarlierVisibleRevision'](_0x7c6af6){const [,_0x23ab12]=this['getRevisionsIterator'](_0x7c6af6,{'direction':'earlier'});return _0x23ab12;}['getLaterVisibleRevision'](_0x54f79b){const [,_0x5d8ee7]=this['getRevisionsIterator'](_0x54f79b,{'direction':'later'});return _0x5d8ee7;}['getRevisionsInDiff'](_0x398845){const _0x2b31c0=[];for(const _0x30993f of this['getRevisionsIterator'](_0x398845['newRevisionId']))if(_0x2b31c0['push'](_0x30993f),_0x30993f['id']===_0x398845['oldRevisionId'])break;return _0x2b31c0;}*['getRevisionsIterator'](_0x1d52a9,{direction:_0x4c3be3='earlier',filter:_0x3993f3=()=>!0x0}={}){const _0x2dd0f5='earlier'===_0x4c3be3?0x1:-0x1;let _0x555f5a=this['_revisions']['get'](_0x1d52a9),_0x743ee=this['getIndex'](_0x555f5a);for(yield _0x555f5a;_0x555f5a;){if(_0x743ee+=_0x2dd0f5,_0x555f5a=this['getRevision'](_0x743ee),!_0x555f5a)return;_0x3993f3(_0x555f5a)&&(yield _0x555f5a);}}}function R(_0x581613,_0x4cf42f,_0x5dad9c){const t=_0x581613['t'];switch(_0x4cf42f){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'},_0x5dad9c);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x5dad9c);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'';}}const C={'c':_0x471041,'a':_0xe030e4,'e':_0x473571,'r':_0x41ad37,'u':_0x478289};class l extends _0x4632d0{['licenseKey'];['_licenseKeyCheckInterval'];['adapter'];['currentRevision'];['repository'];['_revisionDataBuilder'];['_source'];['_initialRevisionId'];['_bufferedUpdates'];['_pendingAction'];['_continueCurrentRevision'];['_startingVersion'];['_loadedStateData'];static get['pluginName'](){return'RevisionTracker';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[_0x31bb84,j,_0x49b076];}constructor(_0x27ab1d){super(_0x27ab1d),this['adapter']=null,this['currentRevision']=null,this['_revisionDataBuilder']=new T(this['editor']),this['_initialRevisionId']=this['editor']['config']['get']('collaboration.channelId')||'initial',this['_bufferedUpdates']=new Map(),this['_loadedStateData']=null;const _0x51faac=_0x152f7f();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x51faac},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['repository']=this['editor']['plugins']['get']('RevisionsRepository'),this['_setConversion'](),this['editor']['data']['on']('ready',()=>{const _0x2d039f=this['repository']['getRevision'](0x0),_0x267e8b=_0x2d039f&&null===_0x2d039f['creator']?_0x2d039f:null;if(this['_continueCurrentRevision']=!!_0x267e8b&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x3233bf=this['_source']['getCurrentRevisionId'](),_0x3e3ba9=this['repository']['getRevision'](_0x3233bf);if(_0x3e3ba9)this['_startingVersion']=_0x3e3ba9['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x51f231=this['_source']['history']['_operations']['find'](_0x3d291b=>!_0x3d291b['_isInit']),_0x367dd0=_0x51f231?_0x51f231['baseVersion']:this['_source']['history']['version'];_0x2d039f?(_0x2d039f['toVersion']<_0x367dd0&&_0x2d039f['_update']({'toVersion':_0x367dd0}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x267e8b['id'],this['_startingVersion']=_0x267e8b['fromVersion']):(this['_startingVersion']=_0x2d039f['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x367dd0,this['_continueCurrentRevision']=!0x1);}}else _0x267e8b&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x267e8b['toVersion'],this['editor']['model']['document']['history']['version']),_0x267e8b['fromVersion']===_0x267e8b['toVersion']?(0x0!==_0x267e8b['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x267e8b['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x267e8b['id'],this['_startingVersion']=_0x267e8b['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',_0xadf6ec=>!_0xadf6ec),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x5a4c48=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x3c1d44;for(const _0x4900f9 in _0x5a4c48){const _0x4854eb=_0x4900f9,_0x1a508f=_0x5a4c48[_0x4854eb];if('revisionHistoryLicenseKeyValid'==_0x1a508f||'revisionHistoryLicenseKeyInvalid'==_0x1a508f||'revisionHistoryLicenseKeyExpired'==_0x1a508f||'revisionHistoryLicenseKeyDomainLimit'==_0x1a508f||'revisionHistoryLicenseKeyNotAllowed'==_0x1a508f||'revisionHistoryLicenseKeyEvaluationLimit'==_0x1a508f||'revisionHistoryLicenseKeyTrialLimit'==_0x1a508f||'revisionHistoryLicenseKeyDevelopmentLimit'==_0x1a508f||'revisionHistoryLicenseKeyUsageLimit'==_0x1a508f){delete _0x5a4c48[_0x4854eb],_0x3c1d44=_0x1a508f,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x3c1d44&&_0x5a4c48['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x3c1d44&&_0x5a4c48['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x3c1d44&&_0x5a4c48['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x3c1d44&&_0x5a4c48['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x3c1d44&&_0x5a4c48['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x3c1d44&&_0x5a4c48['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyDevelopmentLimit'==_0x3c1d44&&_0x5a4c48['_showLicenseError']('developmentLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x3c1d44&&_0x5a4c48['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x1a8c07=this['repository']['getRevision'](0x0),_0x2c2462=await this['getRevisionDocumentData'](_0x1a8c07),_0x51a02e=await this['getRevisionRootsAttributes'](_0x1a8c07);this['_replaceEditorDataWithRevisionData'](_0x2c2462,_0x51a02e);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x588e4f){this['_source']=_0x588e4f;}async['update'](){const _0x56ec0d=await this['_source']['getLatestVersion']();if(_0x56ec0d>this['currentRevision']['toVersion']){await this['_loadState']();const _0x4c3983=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x56ec0d});_0x4c3983['authors']=_0x4c3983['authorsIds']['map'](_0x5e652b=>this['editor']['plugins']['get']('Users')['getUser'](_0x5e652b)),this['currentRevision']['_update'](_0x4c3983);}}async['_loadState'](){this['_continueCurrentRevision']&&!this['_loadedStateData']&&(await this['_loadRevisionData'](this['currentRevision']),this['_revisionDataBuilder']['loadState'](this['currentRevision']),this['_loadedStateData']={'fromVersion':this['currentRevision']['fromVersion'],'authors':this['currentRevision']['authors']['slice']()});}async['saveRevision'](_0x5004d1={},_0x5baacc=null){const _0x1bd635=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x5baacc>this['currentRevision']['toVersion']&&(_0x5baacc=null),null===_0x5baacc&&(_0x5baacc=await this['_source']['getLatestVersion']());const _0xfa34f4=this['_getFromVersion'](_0x5baacc),_0x245aa8=this['buildRevisionData']({'from':_0xfa34f4,'to':_0x5baacc});if(this['currentRevision']['toVersion']<_0x5baacc){const _0x1ab2e3=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x5baacc,'to':_0x5baacc});_0x1ab2e3['authors']=[],_0x1ab2e3['authorsIds']=[],_0x1ab2e3['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x1ab2e3,!0x0),delete _0x1ab2e3['authors'],_0x1bd635['push'](_0x1ab2e3);}_0x5004d1['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x5004d1['name']=_0x5004d1['name']||null,_0x5004d1['id']=_0x5004d1['id']||_0x152f7f(),_0x5004d1={..._0x5004d1,..._0x245aa8};const _0x1d7cce=this['addRevisionData'](_0x5004d1);_0x1bd635['push'](_0x5004d1);const _0x5087af=this['repository']['getIndex'](_0x1d7cce);if(0x0!==_0x5087af){const _0x6afc53=this['repository']['getRevision'](_0x5087af-0x1);if(_0x6afc53['fromVersion']!==_0x5baacc){const _0x263b03=this['_revisionDataBuilder']['getData'](_0x5baacc,_0x6afc53['toVersion']),_0x2beb9b={'id':_0x6afc53['id'],'diffData':_0x263b03['diffData'],'authorsIds':_0x263b03['authorsIds'],'authors':_0x263b03['authorsIds']['map'](_0x16e545=>this['editor']['plugins']['get']('Users')['getUser'](_0x16e545)),'fromVersion':_0x5baacc};_0x6afc53===this['currentRevision']&&(_0x2beb9b['createdAt']=new Date(_0x5004d1['createdAt']['getTime']()+0xa)),_0x6afc53['_update'](_0x2beb9b,!0x0),delete _0x2beb9b['authors'],_0x1bd635['push'](_0x2beb9b);}}if(this['adapter']){for(const _0xabb50f of _0x1bd635)this['_bufferUpdate'](_0xabb50f['id'],_0xabb50f,!0x0);this['sendBufferedUpdates']();}return _0x1d7cce;}['addRevisionData'](_0x1b7e06){const _0x57d33c=this['repository']['createRevision'](_0x1b7e06);return this['adapter']&&_0x57d33c['on']('_update',(_0x4aed24,_0x3183b8,_0x5322b8)=>{_0x5322b8||(this['_bufferUpdate'](_0x3183b8['id'],_0x3183b8,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x57d33c,this['_findInsertionIndex'](_0x57d33c)),_0x57d33c;}async['getRevisionDocumentData'](_0x19df88){await this['_loadRevisionData'](_0x19df88);const _0x12c8a0={};for(const _0x25cd61 in _0x19df88['diffData']){if(_0x19df88['diffData'][_0x25cd61]['attachChange']&&!_0x19df88['diffData'][_0x25cd61]['attachChange']['isAttached'])continue;const _0x199848=this['_removeRevisionMarkers'](JSON['parse'](_0x19df88['diffData'][_0x25cd61]['insertions'])),_0x18df00=this['editor']['editing']['view']['document'],_0x38df17=new _0x46f024(_0x18df00,_0x199848['map'](_0x414c0d=>V(_0x414c0d,this['editor'])));this['editor']['data']['processor']['useFillerType']('marked'),_0x12c8a0[_0x25cd61]=this['editor']['data']['processor']['toData'](_0x38df17),this['editor']['data']['processor']['useFillerType']('default');}return _0x12c8a0;}async['getRevisionRootsAttributes'](_0x25b9ca){await this['_loadRevisionData'](_0x25b9ca);const _0x40e6c6={};for(const _0x153f41 in _0x25b9ca['diffData'])_0x25b9ca['diffData'][_0x153f41]['attachChange']&&!_0x25b9ca['diffData'][_0x153f41]['attachChange']['isAttached']||(_0x40e6c6[_0x153f41]=_0x25b9ca['diffData'][_0x153f41]['attributesAfter']||{});return _0x40e6c6;}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x46f7da=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x35012e=0x0;_0x35012e<_0x46f7da['length'];_0x35012e++){const _0x5cca46=_0x46f7da[_0x35012e];let _0x45203a=!0x1;for(const _0x3b3213 of Object['keys'](_0x5cca46))void 0x0===_0x5cca46[_0x3b3213]?delete _0x5cca46[_0x3b3213]:'id'!==_0x3b3213&&(_0x45203a=!0x0);_0x45203a||(_0x46f7da[_0x35012e]=null);}if(_0x46f7da=_0x46f7da['filter'](_0x2ecc5e=>null!==_0x2ecc5e),!_0x46f7da['length'])return;for(let _0xfb4cb9=0x0;_0xfb4cb9<_0x46f7da['length'];_0xfb4cb9++){const _0x8cc210=_0x46f7da[_0xfb4cb9];void 0x0!==_0x8cc210['fromVersion']&&void 0x0===_0x8cc210['toVersion']&&(_0x8cc210['toVersion']=this['repository']['getRevision'](_0x8cc210['id'])['toVersion']),void 0x0!==_0x8cc210['toVersion']&&void 0x0===_0x8cc210['fromVersion']&&(_0x8cc210['fromVersion']=this['repository']['getRevision'](_0x8cc210['id'])['fromVersion']);}const _0x152392=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x46f7da,_0x152392)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x2fd85f=>{if(_0x2fd85f){for(const _0x3788f9 of _0x2fd85f)this['setRevisionData']({'id':_0x3788f9['id'],'createdAt':_0x3788f9['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['_replaceEditorDataWithRevisionData'](_0x2c23ea,_0x4703c5){let _0x126abc=this['editor']['config']['get']('initialData'),_0x24400c=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x126abc){_0x126abc={};for(const _0x50e2a3 of this['editor']['model']['document']['getRootNames']())_0x126abc[_0x50e2a3]='';}if('string'==typeof _0x126abc&&(_0x126abc={'main':_0x126abc}),void 0x0===_0x24400c){_0x24400c={};for(const _0x593ae0 of this['editor']['model']['document']['getRootNames']())_0x24400c[_0x593ae0]={};}let _0xab202c=!0x1;const _0x1d4d05=Object['keys'](_0x126abc),_0x45b8d=Object['keys'](_0x2c23ea);for(const _0x222b5d of _0x1d4d05){if(_0x126abc[_0x222b5d]!==_0x2c23ea[_0x222b5d]&&''!==_0x126abc[_0x222b5d]['trim']()){_0xab202c=!0x0;break;}if(!_0x3cb56d(_0x24400c[_0x222b5d],_0x4703c5[_0x222b5d])&&Object['keys'](_0x24400c[_0x222b5d])['length']>0x0){_0xab202c=!0x0;break;}}_0xab202c||(_0xab202c=_0x45b8d['some'](_0x475095=>!this['editor']['model']['document']['getRoot'](_0x475095))),_0xab202c&&_0x319ed7('editor-initial-data-replaced-with-revision-data',{'editorData':_0x126abc,'editorRootsAttributes':_0x24400c,'revisionData':_0x2c23ea,'revisionRootsAttributes':_0x4703c5}),this['editor']['config']['set']('initialData',_0x2c23ea),this['editor']['config']['set']('rootsAttributes',_0x4703c5);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x528906=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x528906['add'](R(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0xb98de0){const _0x5a4724=this['repository']['getRevisions']();_0x5a4724['reverse']();let _0x569fd1=0x0;for(;_0x569fd1<_0x5a4724['length'];){const _0x2d7185=_0x5a4724[_0x569fd1];if(_0x2d7185===this['currentRevision']){_0x569fd1++;continue;}if(_0x2d7185['id']===this['_initialRevisionId'])break;const _0x12945f=_0xb98de0['toVersion']-_0x2d7185['toVersion']||_0xb98de0['fromVersion']-_0x2d7185['fromVersion'];if(_0x12945f>0x0)break;if(_0x12945f<0x0)_0x569fd1++;else{if(!_0xb98de0['creator']&&_0x2d7185['creator'])break;if(_0x2d7185['creator']||!_0xb98de0['creator']){if(_0xb98de0['createdAt']>_0x2d7185['createdAt'])break;_0x569fd1++;}else _0x569fd1++;}}return _0x569fd1;}['setRevisionData'](_0x1319f7){const _0x4566bf=this['repository']['getRevision'](_0x1319f7['id']);if(_0x1319f7['createdAt']&&(_0x1319f7['createdAt']=new Date(_0x1319f7['createdAt'])),_0x1319f7['authorsIds']){const _0x3d2485=this['editor']['plugins']['get']('Users');_0x1319f7['authors']=_0x1319f7['authorsIds']['map'](_0x448b5b=>_0x3d2485['getUser'](_0x448b5b));}_0x4566bf['_update'](_0x1319f7,!0x0);}['buildRevisionData']({revision:_0x294622=null,from:_0x4a3d30=null,to:_0x5211d2=null}){_0x4a3d30=null!==_0x4a3d30?_0x4a3d30:_0x294622['fromVersion'],_0x5211d2=null!==_0x5211d2?_0x5211d2:_0x294622['toVersion'];const _0x1c14a4=this['_revisionDataBuilder']['getData'](_0x4a3d30,_0x5211d2),_0x3f9d6c={'diffData':_0x1c14a4['diffData'],'authorsIds':_0x1c14a4['authorsIds'],'fromVersion':_0x4a3d30,'toVersion':_0x5211d2};if(!_0x294622||_0x5211d2!==_0x294622['toVersion']){const _0x278ae2=_0x5211d2-0x1,_0x41f750=this['_source']['history']['getOperation'](_0x278ae2);_0x3f9d6c['createdAt']=_0x41f750&&_0x41f750['createdAt']||new Date();}if(this['_loadedStateData']&&_0x4a3d30===this['_loadedStateData']['fromVersion']){for(const _0x5f2677 of this['_loadedStateData']['authors'])_0x3f9d6c['authorsIds']['includes'](_0x5f2677['id'])||_0x3f9d6c['authorsIds']['push'](_0x5f2677['id']);}return _0x3f9d6c;}['_loadRevisionData'](_0x425805){if(!_0x425805||_0x425805['diffData'])return Promise['resolve']();{const _0x76d784=this['editor']['config']['get']('collaboration.channelId');return this['adapter']['getRevision']({'channelId':_0x76d784,'revisionId':_0x425805['id']})['then'](_0x5a3332=>{_0x425805['diffData']=_0x5a3332['diffData'];});}}['_bufferUpdate'](_0x35d64a,_0xcab97,_0x284c74){if(this['_bufferedUpdates']['has'](_0x35d64a)){const _0x3ab639=this['_bufferedUpdates']['get'](_0x35d64a);_0xcab97=_0x284c74?{..._0x3ab639,..._0xcab97}:{..._0xcab97,..._0x3ab639};}this['_bufferedUpdates']['set'](_0x35d64a,_0xcab97);}['_getFromVersion'](_0x4d0a97){const _0x3ebd0f=this['repository']['getRevisions']();_0x3ebd0f['reverse'](),_0x3ebd0f['shift']();const _0x4bf596=_0x3ebd0f['find'](_0xbc49e7=>_0xbc49e7['toVersion']<=_0x4d0a97)['toVersion'];return _0x4bf596<this['_startingVersion']?this['_startingVersion']:_0x4bf596;}['_createInitialRevision'](_0x260ac7){const _0x27b9cc=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x27b9cc)this['_initialRevisionId']=_0x27b9cc['id'];else{const _0x3f8b24=!this['editor']['model']['document']['roots']['find'](_0x4d8e2e=>this['editor']['model']['hasContent'](_0x4d8e2e)),_0x3099fd=this['editor']['plugins']['get']('Users')['me']['id'],_0x227ec4=R(this['editor']['locale'],_0x3f8b24?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x260ac7,'to':_0x260ac7,'id':this['_initialRevisionId'],'name':_0x227ec4,'creatorId':_0x3099fd});}}['_createCurrentRevision'](_0x3089d1){const _0x3f3968=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x3f3968),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x3089d1,'to':_0x3089d1,'id':_0x3f3968,'name':'','creatorId':null}));}['_makeRevision']({name:_0x5cf1f2,from:_0x1854bb,to:_0x3f2a0e,creatorId:_0x53045a,id:_0x483f23}){const _0x287aed=this['buildRevisionData']({'from':_0x1854bb,'to':_0x3f2a0e});_0x287aed['name']=_0x5cf1f2,_0x287aed['creatorId']=_0x53045a,_0x287aed['id']=_0x483f23;const _0x14785c=this['addRevisionData'](_0x287aed);return this['adapter']&&this['_bufferUpdate'](_0x287aed['id'],_0x287aed,!0x0),_0x14785c;}['_setConversion'](){this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'});}['_removeRevisionMarkers'](_0x4f621d){return(_0x4f621d=_0x4f621d['filter'](_0x6fe6bf=>!_0x6fe6bf['name']||'revision-start'!==_0x6fe6bf['name']&&'revision-end'!==_0x6fe6bf['name']))['forEach'](_0x1c65f0=>{'string'!=typeof _0x1c65f0&&(_0x1c65f0['children']=this['_removeRevisionMarkers'](_0x1c65f0['children']),_0x1c65f0['attributes']=_0x1c65f0['attributes']['filter'](_0xbbdcd8=>!_0xbbdcd8[0x0]['startsWith']('data-revision-')));}),_0x4f621d;}}function V(_0x2fe008,_0x5eb38b){const _0x437596=_0x5eb38b['editing']['view']['document'];if('string'==typeof _0x2fe008)return new _0x441ee8(_0x437596,_0x2fe008);{const _0x2d668f=_0x2fe008['children']['map'](_0x3ba413=>V(_0x3ba413,_0x5eb38b));return new(C[_0x2fe008['type']]||_0x194c7d)(_0x437596,_0x2fe008['name'],_0x2fe008['attributes'],_0x2d668f);}}class T{['editor'];['source'];['_savedMetaData'];['_lastFrom'];['_lastTo'];['_markers'];['_diffRoots'];['_diffRootsAttributes'];['_baseRoots'];['_baseRootsAttributes'];['_idsRoots'];['_baseIdsRoots'];['_touched'];['_touchedMarkers'];['_touchedRoots'];['_revisionId'];['_startingRevisionId'];constructor(_0x8fb2ef){this['editor']=_0x8fb2ef,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'](_0x2ad3af){this['source']=_0x2ad3af;const _0xf1c4a5=new Map(),_0x519bbc=new Map(),_0x34b5ea=this['editor']['model']['document']['roots']['map'](_0xd8e3f4=>_0xd8e3f4['rootName']);for(const _0x973928 of _0x34b5ea){const _0x343d30=this['editor']['model']['document']['getRoot'](_0x973928),_0x1c65b6=F(_0x343d30);_0xf1c4a5['set'](_0x973928,_0x1c65b6),_0x519bbc['set'](_0x973928,Object['fromEntries'](_0x343d30['getAttributes']()));}const _0x6a7d8b=Array['from'](this['editor']['model']['markers'])['map'](_0x3bafc4=>[_0x3bafc4['name'],_0x3bafc4['getRange']()]),_0x5155c0=this['source']['version'];this['_saveMetaData'](_0x5155c0,_0xf1c4a5,_0x6a7d8b,_0x519bbc),this['_startingRevisionId']=this['_revisionId'];const _0x474ab9=new Map(),_0x246d0e=new Map();for(const _0x40b036 of _0x34b5ea){const _0x590af5=B(_0x40b036);_0x474ab9['set'](_0x40b036,_0x590af5),_0x246d0e['set'](_0x40b036,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x474ab9,[],_0x246d0e);}['getData'](_0x23036c,_0x359251){if(this['_lastFrom']===_0x23036c&&this['_lastTo']<=_0x359251)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x359251,!0x0);else{if(!this['_savedMetaData']['has'](_0x23036c)){const _0x1eabdf=this['_getPreviousFrom'](_0x23036c);this['_calculateMetaData'](_0x1eabdf,_0x23036c,!0x1);}this['_calculateMetaData'](_0x23036c,_0x359251,!0x0);}return this['_lastFrom']=_0x23036c,this['_lastTo']=_0x359251,this['_getState']();}['loadState'](_0x304a85){this['_reset'](),this['_lastFrom']=_0x304a85['fromVersion'],this['_lastTo']=_0x304a85['toVersion'];for(const _0x5836aa in _0x304a85['diffData']){const _0x5421e8=_0x304a85['diffData'][_0x5836aa]['attachChange'],_0x1f6e38=_0x4839cc(_0x304a85['diffData'][_0x5836aa]['attributesBefore'])||{},_0x45a5b3=this['_makeModelFromViewString'](_0x304a85['diffData'][_0x5836aa]['deletions']);_0x45a5b3['rootName']=_0x5836aa,_0x45a5b3['_isAttached']=!_0x5421e8||!_0x5421e8['isAttached'],_0x45a5b3['isAttached']=()=>_0x45a5b3['_isAttached'],this['_baseRoots']['set'](_0x5836aa,_0x45a5b3),this['_baseRootsAttributes']['set'](_0x5836aa,_0x1f6e38),_0x5421e8&&this['_touchedRoots']['set'](_0x5836aa,_0x5421e8);const _0xb926d6=this['_makeIdsRoot'](_0x45a5b3);this['_baseIdsRoots']['set'](_0x5836aa,_0xb926d6);for(const [_0x279bab,_0x1ac985]of _0x45a5b3['markers']){if(!_0x279bab['startsWith']('revision:'))continue;const _0x2bc00c=_0x279bab['split'](':')[0x2];for(const _0x25f5e5 of _0x1ac985['getWalker']({'singleCharacters':!0x0})){const _0x324aa6=this['_getVidAttributeName'](_0x25f5e5),_0x3e4a51='elementEnd'==_0x25f5e5['type']?_0x25f5e5['previousPosition']['path']['slice'](0x0,-0x1):_0x25f5e5['previousPosition']['path'],_0x1b473e=_0xb926d6['getNodeByPath'](_0x3e4a51)['getAttribute'](_0x324aa6);this['_touched']['set'](_0x1b473e,{'userId':_0x2bc00c});}}}this['_startingRevisionId']=this['_revisionId'];const _0x2a1866=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x131ccc=>!this['_touched']['has'](_0x131ccc));let _0x1c2fd0=0x0;const _0x46ffc4=new Map();for(const _0x4997d0 in _0x304a85['diffData']){const _0xbc1821=_0x304a85['diffData'][_0x4997d0]['attachChange'],_0x1fac57=_0x4839cc(_0x304a85['diffData'][_0x4997d0]['attributesAfter'])||{},_0x28a359=this['_makeModelFromViewString'](_0x304a85['diffData'][_0x4997d0]['insertions']);_0x28a359['rootName']=_0x4997d0,_0x28a359['_isAttached']=!_0xbc1821||_0xbc1821['isAttached'],_0x28a359['isAttached']=()=>_0x28a359['_isAttached'],this['_diffRoots']['set'](_0x4997d0,_0x28a359),this['_diffRootsAttributes']['set'](_0x4997d0,_0x1fac57);const _0x18f80e=this['_makeIdsRoot'](_0x28a359,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x4997d0,_0x18f80e),_0x46ffc4['set'](_0x4997d0,_0x28a359['isAttached']()?_0x1fac57:{});for(const [_0x42721e,_0x449538]of _0x28a359['markers']){if(!_0x42721e['startsWith']('revision:'))continue;const _0x429b46=_0x42721e['split'](':')[0x2];for(const _0xcbff67 of _0x449538['getWalker']({'singleCharacters':!0x0})){const _0x1ecdcb=this['_getVidAttributeName'](_0xcbff67),_0x18c463=this['_revisionId']++,_0x11484f='elementEnd'==_0xcbff67['type']?_0xcbff67['previousPosition']['path']['slice'](0x0,-0x1):_0xcbff67['previousPosition']['path'];_0x18f80e['getNodeByPath'](_0x11484f)['_setAttribute'](_0x1ecdcb,_0x18c463),this['_touched']['set'](_0x18c463,{'userId':_0x429b46});}}for(const _0xd31f1d of this['editor']['model']['createRangeIn'](_0x28a359)['getWalker']({'singleCharacters':!0x0})){const _0x368863=this['_getVidAttributeName'](_0xd31f1d),_0xb31e9a='elementEnd'==_0xd31f1d['type']?_0xd31f1d['previousPosition']['path']['slice'](0x0,-0x1):_0xd31f1d['previousPosition']['path'],_0x269f20=_0x18f80e['getNodeByPath'](_0xb31e9a);_0x269f20['getAttribute'](_0x368863)>0x0||_0x269f20['_setAttribute'](_0x368863,_0x2a1866[_0x1c2fd0++]);}for(const [_0x3fea25,_0x14111d]of _0x28a359['markers'])_0x3fea25['startsWith']('revision:')||this['_markers']['set'](_0x3fea25,_0x14111d);}const _0x58e626=B('$graveyard');this['_baseRoots']['set']('$graveyard',_0x58e626),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x58e626,0x1));const _0x2e41f0=B('$graveyard');this['_diffRoots']['set']('$graveyard',_0x2e41f0),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x2e41f0,0x1));const _0x4fc0b1=Array['from'](this['_diffRoots'])['map'](([_0x321abb,_0x176c84])=>[_0x321abb,F(_0x176c84)]);this['_saveMetaData'](this['_lastTo'],_0x4fc0b1,this['_markers'],_0x46ffc4);}['_makeModelFromViewString'](_0x2c0ecc){const _0x573ce6=JSON['parse'](_0x2c0ecc),_0x4598b6=this['editor']['editing']['view']['document'],_0x24414c=new _0x46f024(_0x4598b6,_0x573ce6['map'](_0x37d163=>V(_0x37d163,this['editor'])));return this['editor']['data']['toModel'](_0x24414c);}['_saveMetaData'](_0xd61650,_0x5776cb,_0x205317,_0x3b2de1){const _0x2592ca=new Map(_0x5776cb),_0x34ff71=new Map(_0x4839cc(_0x3b2de1)),_0x48408b=new Map();for(const [_0x58704e,_0x81b85f]of _0x205317)_0x48408b['set'](_0x58704e,{'start':_0x81b85f['start']['clone'](),'end':_0x81b85f['end']['clone'](),'rootName':_0x81b85f['root']['rootName']});this['_savedMetaData']['set'](_0xd61650,{'roots':_0x2592ca,'markers':_0x48408b,'rootsAttributes':_0x34ff71});}['_removeMetaData'](_0x22ddbb){this['_savedMetaData']['delete'](_0x22ddbb);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_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'](_0x366568,_0xb0b15a=null){let _0x1b9267=null;_0x366568['is']('documentFragment')||(_0x1b9267=new ft(_0x366568['name'],{'vid_start':null===_0xb0b15a?this['_revisionId']++:_0xb0b15a++}));const _0x332116=[];for(const _0x5053ca of _0x366568['getChildren']())if(_0x5053ca['is']('element')){_0x332116['push'](this['_makeIdsRoot'](_0x5053ca,_0xb0b15a));const _0x16adf2=_0x332116[_0x332116['length']-0x1];null!==_0xb0b15a&&(_0xb0b15a=_0x16adf2['is']('element','$text')?_0x16adf2['getAttribute']('vid')+0x1:_0x16adf2['getAttribute']('vid_end')+0x1);}else{for(let _0x46eafc=0x0;_0x46eafc<_0x5053ca['offsetSize'];_0x46eafc++)_0x332116['push'](new ft('$text',{'vid':null===_0xb0b15a?this['_revisionId']++:_0xb0b15a++}));}if(_0x366568['is']('documentFragment')){const _0xa4642c=B(_0x366568['rootName']);return _0xa4642c['_insertChild'](0x0,_0x332116),_0xa4642c;}return _0x1b9267['_setAttribute']('vid_end',null===_0xb0b15a?this['_revisionId']++:_0xb0b15a++),_0x1b9267['_insertChild'](0x0,_0x332116),_0x1b9267;}['_calculateMetaData'](_0x1cc1cd,_0x3e60be,_0x297fba){this['_reset']();const {roots:_0x32c4fe,markers:_0x78ecf8,rootsAttributes:_0x22ae1b}=this['_savedMetaData']['get'](_0x1cc1cd);this['_baseRoots']=new Map(_0x32c4fe),this['_baseRootsAttributes']=new Map(_0x4839cc(_0x22ae1b));for(const [_0x47a1cb,_0x1c5824]of this['_baseRoots'])if('$graveyard'!==_0x47a1cb&&(this['_diffRoots']['set'](_0x47a1cb,F(_0x1c5824)),this['_diffRootsAttributes']=new Map(_0x4839cc(_0x22ae1b)),_0x297fba)){const _0x329968=this['_revisionId'];this['_idsRoots']['set'](_0x47a1cb,this['_makeIdsRoot'](_0x1c5824)),this['_baseIdsRoots']['set'](_0x47a1cb,this['_makeIdsRoot'](_0x1c5824,_0x329968));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',F(this['_baseRoots']['get']('$graveyard'))),_0x297fba&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x37ff95,_0x4238ae]of _0x78ecf8){const _0x38e64a=this['_baseRoots']['get'](_0x4238ae['rootName']),_0x4fa38f=this['_diffRoots']['get'](_0x4238ae['rootName']),_0x9b7394=new vt(this['_fixPosition'](_0x4238ae['start'],_0x38e64a),this['_fixPosition'](_0x4238ae['end'],_0x38e64a)),_0x407a46=this['_fixRange'](_0x9b7394,_0x4fa38f);_0x38e64a['markers']['set'](_0x37ff95,_0x9b7394),this['_markers']['set'](_0x37ff95,_0x407a46);}this['_applyOperations'](_0x1cc1cd,_0x3e60be,_0x297fba);}['_applyOperations'](_0x2c76fa,_0x3797e5,_0xd13aed){for(const _0x4b03c4 of this['source']['getOperations'](_0x2c76fa,_0x3797e5))this['_handleOperation'](_0x4b03c4,_0xd13aed);for(const _0x576cfa of this['_diffRoots']['values']())_0x576cfa['markers']['clear']();for(const [_0x374951,_0x1ac531]of this['_markers']){this['_diffRoots']['get'](_0x1ac531['root']['rootName'])['markers']['set'](_0x374951,_0x1ac531['clone']());}const _0x5b1035=new Map(),_0x1f05b6=new Map();for(const [_0x4e526d,_0x33aeed]of this['_diffRoots'])_0x5b1035['set'](_0x4e526d,F(_0x33aeed)),_0x1f05b6['set'](_0x4e526d,this['_diffRootsAttributes']['get'](_0x4e526d));this['_saveMetaData'](_0x3797e5,_0x5b1035,this['_markers'],_0x1f05b6);}['_getPreviousFrom'](_0x4b5aa9){const _0x5022de=Array['from'](this['_savedMetaData']['keys']());_0x5022de['sort']((_0x304b33,_0x1b8808)=>_0x304b33-_0x1b8808),_0x5022de['reverse']();for(const _0x4433bc of _0x5022de)if(_0x4433bc<_0x4b5aa9)return _0x4433bc;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x1df66f,_0x54f1ba){const _0x389103=Array['from'](_0x54f1ba['markers'])['map'](([_0x37831d,_0x18987e])=>[_0x37831d,this['_fixRange'](_0x18987e,_0x1df66f)]);_0x1df66f['markers']=new Map(_0x389103);}['_transformMarkers'](_0x4cc187){for(const _0x458e1f of this['_markers']['values']()){const _0x585d84=_0x458e1f['getTransformedByOperation'](_0x4cc187),_0x2d0373=vt['_createFromRanges'](_0x585d84);_0x458e1f['start']=_0x2d0373['start'],_0x458e1f['end']=_0x2d0373['end'];}}['_handleOperation'](_0x3f8cfa,_0x102efc){if('addRoot'!=_0x3f8cfa['type']&&'detachRoot'!=_0x3f8cfa['type']){if('insert'==_0x3f8cfa['type']){const _0x58f617=_0x3f8cfa['position']['root']['rootName'];this['_diffRoots']['has'](_0x58f617)||(this['_diffRoots']['set'](_0x58f617,B(_0x58f617,!0x0)),this['_diffRootsAttributes']['set'](_0x58f617,{}),_0x102efc&&this['_idsRoots']['set'](_0x58f617,B(_0x58f617,!0x0)));}else{if('addRootAttribute'==_0x3f8cfa['type']||'removeRootAttribute'==_0x3f8cfa['type']||'changeRootAttribute'==_0x3f8cfa['type'])return void this['_handleRootAttributeOperation'](_0x3f8cfa);'marker'==_0x3f8cfa['type']&&this['_handleMarkerOperation'](_0x3f8cfa);}if('marker'!==_0x3f8cfa['type']){const _0x172f83=this['_cloneOperation'](_0x3f8cfa,this['_diffRoots']);_0x172f83['_execute'](),this['_transformMarkers'](_0x172f83);}if(_0x102efc)switch(_0x3f8cfa['type']){case'insert':this['_handleInsertOperation'](_0x3f8cfa);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x3f8cfa);break;case'merge':this['_handleMergeOperation'](_0x3f8cfa);break;case'split':this['_handleSplitOperation'](_0x3f8cfa);}}else this['_handleRootOperation'](_0x3f8cfa,_0x102efc);}['_cloneOperation'](_0xd345a6,_0x503d0f){const _0x44366d=_0xd345a6['clone']();return _0x44366d['_authorId']=_0xd345a6['_authorId'],this['_fixOperation'](_0x44366d,_0x503d0f),_0x44366d;}['_getBaseVids'](_0x36eb09){return _0x36eb09['map'](_0x1918f3=>{const _0x16047f=this['_getVidAttributeName'](_0x1918f3);return Number(_0x1918f3['item']['getAttribute'](_0x16047f));});}['_generateTape'](_0x19e2f4,_0x1dbad8){if(_0x19e2f4['is']('element','$text'))_0x1dbad8['push']({'item':_0x19e2f4,'type':'text'});else{_0x19e2f4['is']('element')&&_0x1dbad8['push']({'item':_0x19e2f4,'type':'elementStart'});for(const _0x813049 of _0x19e2f4['getChildren']())this['_generateTape'](_0x813049,_0x1dbad8);_0x19e2f4['is']('element')&&_0x1dbad8['push']({'item':_0x19e2f4,'type':'elementEnd'});}return _0x1dbad8;}['_getState'](){const _0x37b644=new Map(this['_touched']),_0x30efca=new Map(_0x37b644),_0x511405=new Map(),_0x1c9980={'insertions':{},'deletions':{}},_0x4a1524={'insertions':{},'deletions':{}},_0x4d9081=new Map(),_0x5971f9=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x5971f9['delete']('$graveyard');for(const _0x3075de of _0x5971f9){const _0x53bead=this['_diffRoots']['get'](_0x3075de)||B(_0x3075de,!0x1),_0x25a5be=this['_baseRoots']['get'](_0x3075de)||B(_0x3075de,!0x1);_0x53bead['isAttached']()||_0x25a5be['isAttached']()?(_0x1c9980['insertions'][_0x3075de]=F(_0x53bead),_0x1c9980['deletions'][_0x3075de]=F(_0x25a5be),this['_copyMarkers'](_0x1c9980['deletions'][_0x3075de],_0x25a5be),this['_copyMarkers'](_0x1c9980['insertions'][_0x3075de],_0x53bead),_0x4a1524['insertions'][_0x3075de]=this['_generateTape'](this['_idsRoots']['get'](_0x3075de),[]),_0x4a1524['deletions'][_0x3075de]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x3075de)||B(_0x3075de,!0x1),[])):_0x5971f9['delete'](_0x3075de);}for(const _0x2f71ad of _0x5971f9){const _0x2fc012=_0x4a1524['insertions'][_0x2f71ad];for(const _0x25072d of _0x2fc012){const _0x171c65=this['_getVidAttributeName'](_0x25072d),_0x146709=_0x25072d['item']['getAttribute'](_0x171c65);_0x30efca['delete'](_0x146709),_0x146709>=this['_startingRevisionId']&&_0x511405['set'](_0x146709,_0x37b644['get'](_0x146709));}}for(const _0x1b8741 of _0x5971f9){const _0x215ace=_0x4a1524['insertions'][_0x1b8741],_0x188341=this['_getBaseVids'](_0x4a1524['deletions'][_0x1b8741]);let _0x29f848=0x0;for(const _0x1730be of _0x215ace){const _0x3f2613=this['_getVidAttributeName'](_0x1730be),_0x5842ba=_0x1730be['item']['getAttribute'](_0x3f2613);if(!_0x511405['has'](_0x5842ba)&&!_0x4d9081['has'](_0x5842ba)){if(_0x30efca['has'](_0x5842ba))_0x29f848++;else{if(_0x5842ba!=_0x188341[_0x29f848]){const _0x2529e8=_0x37b644['get'](_0x5842ba)||_0x37b644['get'](_0x188341[_0x29f848]);for(;_0x5842ba!=_0x188341[_0x29f848];)_0x30efca['has'](_0x188341[_0x29f848])||(_0x4d9081['set'](_0x188341[_0x29f848],_0x2529e8),_0x37b644['set'](_0x188341[_0x29f848],_0x2529e8)),_0x29f848++;}_0x29f848++;}}}}for(const _0x2d76dc of _0x5971f9){const _0x5b1101=_0x4a1524['insertions'][_0x2d76dc];for(const _0x4ef774 of _0x5b1101){const _0x48a006=this['_getVidAttributeName'](_0x4ef774),_0x47a659=_0x4ef774['item']['getAttribute'](_0x48a006);if(_0x4d9081['has'](_0x47a659)){const _0x4a2fc2=_0x4d9081['get'](_0x47a659);_0x30efca['has'](_0x47a659)||_0x30efca['set'](_0x47a659,{..._0x4a2fc2}),_0x511405['set'](_0x47a659,{..._0x4a2fc2});}}}for(const _0x2d7996 of _0x30efca['keys']())_0x2d7996>=this['_startingRevisionId']&&_0x30efca['delete'](_0x2d7996);const _0x22648c=new Map();for(const _0x3db0a5 of _0x5971f9){let _0x7a7149=_0x4a1524['insertions'][_0x3db0a5];for(const _0x540953 of _0x7a7149)if(_0x540953['item']['is']('element','tableCell')){const _0x46e565=this['_getVidAttributeName'](_0x540953),_0x539b59=_0x540953['item']['getAttribute'](_0x46e565);if(_0x511405['has'](_0x539b59)){const _0x213ac1=_0x540953['item']['parent']['parent']['getAttribute']('vid_start'),_0x197ed3=_0x22648c['get'](_0x213ac1)||new Set();_0x197ed3['add'](_0x511405['get'](_0x539b59)['userId']),_0x22648c['set'](_0x213ac1,_0x197ed3);}}_0x7a7149=_0x4a1524['deletions'][_0x3db0a5];for(const _0x315143 of _0x7a7149)if(_0x315143['item']['is']('element','tableCell')){const _0x39a11a=this['_getVidAttributeName'](_0x315143),_0x374e51=_0x315143['item']['getAttribute'](_0x39a11a);if(_0x30efca['has'](_0x374e51)){const _0x7e6da6=_0x315143['item']['parent']['parent']['getAttribute']('vid_start'),_0x2ffd2d=_0x22648c['get'](_0x7e6da6)||new Set();_0x2ffd2d['add'](_0x30efca['get'](_0x374e51)['userId']),_0x22648c['set'](_0x7e6da6,_0x2ffd2d);}}for(const _0x3b9355 of _0x22648c['keys']())(_0x511405['has'](_0x3b9355)||_0x30efca['has'](_0x3b9355))&&_0x22648c['delete'](_0x3b9355);}for(const _0x161897 of _0x5971f9){const _0x563ddc=_0x4a1524['insertions'][_0x161897];let _0x471104=null,_0x10662c=null;for(const _0x59b67e of _0x563ddc){const _0x3c4a60=this['_getVidAttributeName'](_0x59b67e),_0x25e86d=_0x59b67e['item']['getAttribute'](_0x3c4a60),_0x10f37c=_0x22648c['get'](_0x25e86d);_0x10f37c&&'elementStart'==_0x59b67e['type']&&(_0x471104=Array['from'](_0x10f37c)[0x0],_0x10662c=_0x59b67e['item']['getAttribute']('vid_end')),_0x471104&&(_0x30efca['set'](_0x25e86d,{'userId':_0x471104}),_0x511405['set'](_0x25e86d,{'userId':_0x471104})),_0x25e86d==_0x10662c&&(_0x471104=null,_0x10662c=null);}}const _0xf25652={},_0x268694=new Set();for(const _0x4b4142 of _0x5971f9){const _0x277661=_0x1c9980['deletions'][_0x4b4142],_0x169028=_0x1c9980['insertions'][_0x4b4142];for(const {userId:_0x1124eb}of this['_touchedMarkers']['values']())null!==_0x1124eb&&_0x268694['add'](_0x1124eb);for(const {userId:_0x483d5c}of this['_touchedRoots']['values']())null!==_0x483d5c&&_0x268694['add'](_0x483d5c);this['_markChanges'](_0x169028,_0x4a1524['insertions'][_0x4b4142],_0x511405,'insertion',_0x268694),this['_markChanges'](_0x277661,_0x4a1524['deletions'][_0x4b4142],_0x30efca,'deletion',_0x268694),_0xf25652[_0x4b4142]={'insertions':this['_prepareViewToSave'](_0x169028),'deletions':this['_prepareViewToSave'](_0x277661),'attachChange':this['_touchedRoots']['get'](_0x4b4142)||null,'attributesBefore':_0x4839cc(this['_baseRootsAttributes']['get'](_0x4b4142))||{},'attributesAfter':_0x4839cc(this['_diffRootsAttributes']['get'](_0x4b4142))};}return{'diffData':_0xf25652,'authorsIds':Array['from'](_0x268694)};}['_processRootBeforeSave'](_0x5ebc63){for(const [,_0x3ac030]of _0x5ebc63['markers']){const _0x3be142=_0x3ac030['start']['getAncestors']()['filter'](_0x7f16be=>'tableCell'==_0x7f16be['name']);for(const _0x3aed1f of _0x3be142)0x1==_0x3aed1f['childCount']&&_0x3aed1f['getChild'](0x0)['is']('element','paragraph')&&_0x3aed1f['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x3472ef){this['_processRootBeforeSave'](_0x3472ef);const _0x5d092f=this['editor']['data']['toView'](_0x3472ef,{}),_0x1fd2ae=Array['from'](_0x5d092f['getChildren']())['map'](_0x45322c=>this['_getViewJson'](_0x45322c));return JSON['stringify'](_0x1fd2ae);}['_getViewJson'](_0x569eeb){if(_0x569eeb['is']('$text'))return _0x569eeb['data'];{const _0x5cf2e1=_0x569eeb;return{'type':Object['keys'](C)['find'](_0x4ed0d3=>_0x569eeb instanceof C[_0x4ed0d3]),'name':_0x5cf2e1['name'],'attributes':Array['from'](_0x5cf2e1['getAttributes']()),'children':Array['from'](_0x5cf2e1['getChildren']())['map'](_0x1de6f0=>this['_getViewJson'](_0x1de6f0))};}}['_markChanges'](_0xc7fc60,_0x4d5f24,_0xbff1f9,_0x97fa1a,_0x33f77b){let _0x4fdf10=null,_0x198c90=null,_0x141e99=0x0;const _0x4475ec=this['editor']['model'];for(let _0x3f093c=0x0;_0x3f093c<_0x4d5f24['length'];_0x3f093c++){const _0xb33128=this['_getVidAttributeName'](_0x4d5f24[_0x3f093c]),_0x28fb7b=_0x4d5f24[_0x3f093c]['item']['getAttribute'](_0xb33128),_0x26ca94=_0xbff1f9['get'](_0x28fb7b),_0x396846=_0x3f093c==_0x4d5f24['length']-0x1;(!_0x4fdf10&&_0x26ca94&&(_0x4fdf10=_0x26ca94,_0x198c90=_0x4d5f24[_0x3f093c]),_0x4fdf10&&(!_0x26ca94||_0x26ca94['userId']!=_0x4fdf10['userId']))&&(_0x5be870(_0x26ca94,J(_0x198c90,_0xc7fc60,_0x4475ec),J(_0x4d5f24[_0x3f093c],_0xc7fc60,_0x4475ec)),_0x4fdf10=_0x26ca94||null,_0x198c90=_0x26ca94?_0x4d5f24[_0x3f093c]:null),_0x4fdf10&&_0x396846&&_0x5be870(_0x26ca94,J(_0x198c90,_0xc7fc60,_0x4475ec),q(_0x4d5f24[_0x3f093c],_0xc7fc60,_0x4475ec));}function _0x5be870(_0x2d4426,_0x4036fa,_0x5b7c7b){const _0x4f85ad=_0x4fdf10['userId'],_0x3d5255='revision:'+_0x97fa1a+':'+_0x4f85ad+':'+_0x141e99++,_0x83a4ca=_0x4475ec['createRange'](_0x4036fa,_0x5b7c7b);_0xc7fc60['markers']['set'](_0x3d5255,_0x83a4ca),null!==_0x4f85ad&&_0x33f77b['add'](_0x4f85ad);}}['_getVidAttributeName'](_0x1d3a2c){switch(_0x1d3a2c['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x3152e3,_0x362df9){_0x3152e3['baseVersion']=null;for(const _0x16e6ed in _0x3152e3){const _0x5a9313=_0x3152e3[_0x16e6ed];if(_0x5a9313 instanceof gt){const _0x342a82=_0x362df9['get'](_0x5a9313['root']['rootName']);_0x3152e3[_0x16e6ed]=this['_fixPosition'](_0x5a9313,_0x342a82);}if(_0x5a9313 instanceof vt){const _0x133020=_0x362df9['get'](_0x5a9313['root']['rootName']);_0x3152e3[_0x16e6ed]=this['_fixRange'](_0x5a9313,_0x133020);}'root'===_0x16e6ed&&(_0x3152e3['root']=_0x362df9['get'](_0x3152e3['root']['rootName']));}}['_fixRange'](_0x36f23f,_0x5046e0){return this['editor']['model']['createRange'](this['_fixPosition'](_0x36f23f['start'],_0x5046e0),this['_fixPosition'](_0x36f23f['end'],_0x5046e0));}['_fixPosition'](_0x322c24,_0xd3354b){return this['editor']['model']['createPositionFromPath'](_0xd3354b,_0x322c24['path'],_0x322c24['stickiness']);}['_handleInsertOperation'](_0x2dbfee){const _0x4c7637=this['_idsRoots']['get'](_0x2dbfee['position']['root']['rootName']),_0x11b361=this['_fixPosition'](_0x2dbfee['position'],_0x4c7637),_0x3f586c=null===_0x2dbfee['_authorId']?null:_0x2dbfee['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x12bc8a=_0x11b361['parent'],_0x17b345=this['_revisionId'],_0x3a95a7=[];for(const _0x4e94e8 of _0x2dbfee['nodes'])if(_0x4e94e8['is']('element'))_0x3a95a7['push'](this['_makeIdsRoot'](_0x4e94e8));else{for(let _0x5e42a4=0x0;_0x5e42a4<_0x4e94e8['offsetSize'];_0x5e42a4++)_0x3a95a7['push'](new ft('$text',{'vid':this['_revisionId']++}));}const _0x81335f=this['_revisionId'];for(let _0x43ce34=_0x17b345;_0x43ce34<_0x81335f;_0x43ce34++)this['_touched']['set'](_0x43ce34,{'userId':_0x3f586c});_0x12bc8a['_insertChild'](_0x11b361['offset'],_0x3a95a7);}['_handleMoveOperation'](_0x211e3a){(_0x211e3a=this['_cloneOperation'](_0x211e3a,this['_idsRoots']))['_execute']();const _0x2a6d37=null===_0x211e3a['_authorId']?null:_0x211e3a['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x3cbb77=_0x211e3a['getMovedRangeStart'](),_0x28693f=_0x3cbb77['parent'],_0x1c4b84=_0x3cbb77['offset'];!function _0x47c26a(_0x98cb54,_0x4ad1fd,_0x405f25,_0x3e25fa){for(let _0x5c377e=_0x405f25;_0x5c377e<_0x3e25fa;_0x5c377e++){const _0x126b27=_0x4ad1fd['getChild'](_0x5c377e);_0x126b27['is']('element','$text')?_0x98cb54['set'](_0x126b27['getAttribute']('vid'),{'userId':_0x2a6d37}):(_0x98cb54['set'](_0x126b27['getAttribute']('vid_start'),{'userId':_0x2a6d37}),_0x47c26a(_0x98cb54,_0x126b27,0x0,_0x126b27['childCount']),_0x98cb54['set'](_0x126b27['getAttribute']('vid_end'),{'userId':_0x2a6d37}));}}(this['_touched'],_0x28693f,_0x1c4b84,_0x1c4b84+_0x211e3a['howMany']);}['_handleMergeOperation'](_0x560970){const _0xa3b36f=null===(_0x560970=this['_cloneOperation'](_0x560970,this['_idsRoots']))['_authorId']?null:_0x560970['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x332a0a=_0x560970['targetPosition']['parent'],_0x2c3965=_0x560970['sourcePosition']['parent'],_0x2e7ee7=_0x332a0a['getAttribute']('vid_end'),_0x29fee7=_0x2c3965['getAttribute']('vid_start');_0x332a0a['_setAttribute']('vid_end',_0x2c3965['getAttribute']('vid_end')),_0x2c3965['_setAttribute']('vid_end',_0x2e7ee7),this['_touched']['set'](_0x29fee7,{'userId':_0xa3b36f}),this['_touched']['set'](_0x2e7ee7,{'userId':_0xa3b36f}),_0x560970['_execute']();}['_handleSplitOperation'](_0x549ae1){const _0x2ce161=null===(_0x549ae1=this['_cloneOperation'](_0x549ae1,this['_idsRoots']))['_authorId']?null:_0x549ae1['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x4c8d7a=_0x549ae1['graveyardPosition'],_0x3d0642=_0x549ae1['splitPosition']['parent'];_0x549ae1['_execute']();const _0x2e6ceb=_0x3d0642['getAttribute']('vid_end'),_0x5d401d=_0x549ae1['insertionPosition']['nodeAfter'];if(_0x4c8d7a){const _0xe9ef9c=_0x5d401d['getAttribute']('vid_end'),_0x838c41=_0x3d0642['getAttribute']('vid_end');_0x3d0642['_setAttribute']('vid_end',_0xe9ef9c),_0x5d401d['_setAttribute']('vid_end',_0x838c41),this['_touched']['set'](_0x3d0642['getAttribute']('vid_end'),{'userId':_0x2ce161}),this['_touched']['set'](_0x5d401d['getAttribute']('vid_start'),{'userId':_0x2ce161});}else{const _0x3bdbfe=this['_revisionId']++,_0x301f60=this['_revisionId']++;_0x3d0642['_setAttribute']('vid_end',_0x3bdbfe),_0x5d401d['_setAttribute']('vid_start',_0x301f60),_0x5d401d['_setAttribute']('vid_end',_0x2e6ceb),this['_touched']['set'](_0x3bdbfe,{'userId':_0x2ce161}),this['_touched']['set'](_0x301f60,{'userId':_0x2ce161});}}['_handleMarkerOperation'](_0x4817b4){if(!_0x4817b4['affectsData'])return;const _0x46d3dd=(_0x4817b4=this['_cloneOperation'](_0x4817b4,this['_diffRoots']))['oldRange']?_0x4817b4['oldRange']['root']:null,_0x8c9ce9=_0x4817b4['newRange']?_0x4817b4['newRange']['root']:null;_0x46d3dd&&this['_markers']['delete'](_0x4817b4['name']),_0x8c9ce9&&this['_markers']['set'](_0x4817b4['name'],_0x4817b4['newRange']['clone']());const _0x5160a5=null===_0x4817b4['_authorId']?null:_0x4817b4['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x270aeb=_0x4817b4['name'];if(!this['_touchedMarkers']['has'](_0x270aeb))return void this['_touchedMarkers']['set'](_0x270aeb,{'range':_0x4817b4['oldRange'],'userId':_0x5160a5});const _0x3ccd7a=this['_touchedMarkers']['get'](_0x270aeb),_0x461d89=_0x3ccd7a['range'],_0x4e3f27=_0x4817b4['newRange'];null==_0x461d89&&null==_0x4e3f27||_0x461d89&&_0x4e3f27&&_0x461d89['isEqual'](_0x4e3f27)?this['_touchedMarkers']['delete'](_0x4817b4['name']):_0x3ccd7a['userId']=_0x5160a5;}['_handleRootOperation'](_0x8fa6d9,_0x1559ab){this['_diffRoots']['has'](_0x8fa6d9['rootName'])?this['_diffRoots']['get'](_0x8fa6d9['rootName'])['_isAttached']=_0x8fa6d9['isAdd']:(this['_diffRoots']['set'](_0x8fa6d9['rootName'],B(_0x8fa6d9['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x8fa6d9['rootName'],{}),_0x1559ab&&this['_idsRoots']['set'](_0x8fa6d9['rootName'],B(_0x8fa6d9['rootName'],!0x0)));const _0x39c03b=null===_0x8fa6d9['_authorId']?null:_0x8fa6d9['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x5081bc=this['_touchedRoots']['get'](_0x8fa6d9['rootName']);_0x5081bc&&_0x5081bc['userId']===_0x39c03b?this['_touchedRoots']['delete'](_0x8fa6d9['rootName']):this['_touchedRoots']['set'](_0x8fa6d9['rootName'],{'userId':_0x39c03b,'isAttached':_0x8fa6d9['isAdd']});}['_handleRootAttributeOperation'](_0x33a4ef){const _0x59c90b=this['_diffRootsAttributes']['get'](_0x33a4ef['root']['rootName']);null===_0x33a4ef['newValue']?delete _0x59c90b[_0x33a4ef['key']]:_0x59c90b[_0x33a4ef['key']]=_0x33a4ef['newValue'];}}function F(_0x3f1afc){const _0x19e69b=B(_0x3f1afc['rootName'],_0x3f1afc['isAttached']());for(const _0x268c4b of _0x3f1afc['getChildren']()){const _0x8b6cab=_0x268c4b['_clone'](!0x0);_0x19e69b['_appendChild'](_0x8b6cab);}return _0x19e69b;}function B(_0x880c91,_0x58beb9=!0x0){const _0x569551=new wt();return _0x569551['rootName']=_0x880c91,_0x569551['_isAttached']=_0x58beb9,_0x569551['isAttached']=()=>_0x569551['_isAttached'],_0x569551;}function J(_0x177f07,_0x54c978,_0x3050c0){const _0xf1a7c2='elementEnd'==_0x177f07['type']?_0x3050c0['createPositionAt'](_0x177f07['item'],'end'):_0x3050c0['createPositionBefore'](_0x177f07['item']);return _0x3050c0['createPositionFromPath'](_0x54c978,_0xf1a7c2['path'],_0xf1a7c2['stickiness']);}function q(_0x8691a0,_0x2a3171,_0x51af61){const _0x62b00e='elementStart'==_0x8691a0['type']?_0x51af61['createPositionAt'](_0x8691a0['item'],0x0):_0x51af61['createPositionAfter'](_0x8691a0['item']);return _0x51af61['createPositionFromPath'](_0x2a3171,_0x62b00e['path'],_0x62b00e['stickiness']);}class ns extends _0x52b1f5{['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x3ca695,_0x439875){super(_0x3ca695),this['focusTracker']=new _0x9bb3eb(),this['keystrokes']=new _0x1b5681(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x439875),this['setTemplate']({'tag':'form','attributes':{'class':['ck','ck-revision-history-save-revision-form','ck-responsive-form'],'tabindex':'-1'},'children':[this['revisionNameInputView']]}),ts(this);}['render'](){super['render'](),_0x48be9e({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x18910f=_0x4214ce=>_0x4214ce['stopPropagation']();this['keystrokes']['set']('arrowright',_0x18910f),this['keystrokes']['set']('arrowleft',_0x18910f),this['keystrokes']['set']('arrowup',_0x18910f),this['keystrokes']['set']('arrowdown',_0x18910f);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x42dd2a){this['revisionNameInputView']['fieldView']['element']['value']=_0x42dd2a['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x34c37b){const _0x1d77df=new at(this['locale'],_0x520970),_0x102c96=_0x1d77df['fieldView'];_0x102c96['extendTemplate']({'attributes':{'maxlength':'220'}});let _0xf6bb27=R(this['locale'],'Name\x20of\x20the\x20revision');return!_0x34c37b&&(_0xf6bb27+='\x20('+R(this['locale'],'optional')+')'),(_0x1d77df['label']=_0xf6bb27,_0x102c96['on']('input',()=>{this['revisionNameInputValue']=_0x102c96['element']['value']['trim']();}),_0x1d77df);}}class u extends _0x4632d0{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l];}['_saveRevisionFormView'];['init'](){const _0x5cbc8f=this['editor'],_0x55a32d=_0x5cbc8f['plugins']['get']('RevisionTracker');_0x5cbc8f['ui']['componentFactory']['add']('revisionHistory',_0x25bdae=>{const _0x2739eb=_0x119c84(_0x25bdae),_0x2ac276=_0x2739eb['panelView']['children'],_0x4a09f9=new te(_0x25bdae),_0x484ece=new _0x54fe30(_0x25bdae),_0x27c6b4=new _0x36250d(_0x25bdae),_0x2d9434=new _0x54fe30(_0x25bdae),_0x4573b2=new _0x36250d(_0x25bdae);return _0x2739eb['bind']('isEnabled')['to'](_0x55a32d,'isReady',_0x55a32d,'isEnabled',_0x5cbc8f,'isReadOnly',(_0x4fb7f4,_0x395909,_0x4c0ef4)=>_0x4fb7f4&&_0x395909&&!_0x4c0ef4),_0x2739eb['buttonView']['set']({'icon':_0x535503['history'],'label':R(_0x25bdae,'Revision\x20history'),'tooltip':!0x0}),_0x27c6b4['set']({'label':R(_0x25bdae,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x27c6b4['bind']('isEnabled')['to'](_0x55a32d,'isReady',_0x55a32d,'isEnabled',_0x5cbc8f,'isReadOnly',(_0x33e814,_0x55842c,_0x46652f)=>_0x33e814&&_0x55842c&&!_0x46652f),_0x27c6b4['on']('execute',()=>this['_showDialog']()),_0x4573b2['set']({'label':R(_0x25bdae,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x4573b2['bind']('isEnabled')['to'](_0x55a32d,'isReady',_0x5cbc8f,'isReadOnly',(_0x307ecb,_0x337bcf)=>_0x307ecb&&!_0x337bcf),_0x4573b2['on']('execute',()=>{_0x5cbc8f['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x2739eb['isOpen']=!0x1,_0x5cbc8f['editing']['view']['focus']();}),_0x484ece['children']['add'](_0x27c6b4),_0x2d9434['children']['add'](_0x4573b2),_0x4a09f9['role']='menu',_0x4a09f9['items']['addMany']([_0x484ece,_0x2d9434]),_0x2ac276['add'](_0x4a09f9),_0x2739eb;}),_0x5cbc8f['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x399de1=this['editor'],_0x23caf9=_0x399de1['locale'],_0x44a264=new _0x1f1e67(_0x23caf9),_0x3443ec=new _0x576da8(_0x23caf9);_0x44a264['buttonView']['set']({'icon':_0x535503['history'],'label':R(_0x23caf9,'Revision\x20history')});const _0x1bdc76=new _0x3845b0(_0x23caf9,_0x44a264),_0x59f6ad=new _0x51aa12(_0x23caf9);_0x59f6ad['set']({'label':R(_0x23caf9,'Save\x20current\x20revision')}),_0x59f6ad['delegate']('execute')['to'](_0x44a264),_0x59f6ad['on']('execute',()=>{this['_showDialog']();}),_0x1bdc76['children']['add'](_0x59f6ad),_0x3443ec['items']['add'](_0x1bdc76);const _0x2c526d=new _0x3845b0(_0x23caf9,_0x44a264),_0x3dc1c3=new _0x51aa12(_0x23caf9);return _0x3dc1c3['set']({'label':R(_0x23caf9,'Open\x20revision\x20history')}),_0x3dc1c3['delegate']('execute')['to'](_0x44a264),_0x3dc1c3['on']('execute',()=>{_0x399de1['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x2c526d['children']['add'](_0x3dc1c3),_0x3443ec['items']['add'](_0x2c526d),_0x44a264['panelView']['children']['add'](_0x3443ec),_0x44a264;}['_showDialog'](){const _0x491d0c=this['editor'],_0x5b7218=_0x491d0c['locale'],_0x28c399=_0x491d0c['plugins']['get']('Dialog'),_0x455c4e=_0x491d0c['plugins']['get']('RevisionTracker');function _0x117f8e(_0x557a44){_0x491d0c['config']['get']('revisionHistory.requireRevisionName')&&''===_0x557a44['revisionName']?_0x557a44['revisionNameInputView']['errorText']=R(_0x5b7218,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x491d0c['plugins']['get'](l)['saveRevision']({'name':_0x557a44['revisionName']}),_0x28c399['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x117f8e(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x28c399['show']({'id':'revisionSave','title':R(_0x5b7218,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':R(_0x491d0c['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x28c399['hide']()},{'label':R(_0x491d0c['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x4b4ea2){_0x4b4ea2['bind']('isEnabled')['to'](_0x455c4e,'isReady',_0x455c4e,'isEnabled',_0x491d0c,'isReadOnly',(_0x4935b4,_0x24f600,_0x4f6c89)=>_0x4935b4&&_0x24f600&&!_0x4f6c89);},'onExecute':()=>_0x117f8e(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x2ed912=this['editor'],_0x1aad6f=_0x2ed912['locale'];this['_saveRevisionFormView']=new ns(_0x1aad6f,_0x2ed912['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class Y extends _0x52b1f5{['changeId'];['_model'];constructor(_0x35dec2,_0x612eb3){super(_0x35dec2),this['_model']=_0x612eb3,this['changeId']=_0x612eb3['id'];const _0x30b707=this['bindTemplate'],_0xb87f96=R(_0x35dec2,_0x612eb3['data']['isSuggestion']?'Suggested\x20by':'add'==_0x612eb3['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x612eb3['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x30b707['to']('type',_0xb7f1a2=>'ck-revision-change__'+_0xb7f1a2)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0xb87f96}]},{'text':'\x20'+_0x612eb3['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class r extends/* #__PURE__ -- @preserve */
|
|
25
|
-
_0x2f855c(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0xbee6cb){super(),this['id']=_0xbee6cb['id']||_0x152f7f(),this['author']=_0xbee6cb['author'],this['type']=_0xbee6cb['type'],this['data']=_0xbee6cb['data']||{},this['rootName']=_0xbee6cb['rootName'],this['set']('createdAt',_0xbee6cb['createdAt']);}['toJSON'](){return{'id':this['id'],'authorId':this['author']['id'],'type':this['type'],'data':this['data'],'createdAt':this['createdAt']};}}class f{['newRevisionId'];['oldRevisionId'];['changes'];constructor(_0x4747b4,_0x4fd65f){this['newRevisionId']=_0x4747b4,this['oldRevisionId']=_0x4fd65f,this['changes']=new _0x55c105();}['_setChanges'](_0xcf7106){for(const _0x176553 of _0xcf7106)this['changes']['add'](_0x176553);}}const Z={'c':_0x471041,'a':_0xe030e4,'e':_0x473571,'r':_0x41ad37,'u':_0x478289};class d extends _0x4632d0{['repository'];['adapter'];['_activeViewTarget'];['_changeView'];['_changeIdToChange'];['_balloon'];static get['pluginName'](){return'RevisionViewer';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[_0x31bb84,_0x162a1c,j];}constructor(_0x3407fc){super(_0x3407fc),this['repository']=this['editor']['plugins']['get']('RevisionsRepository'),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',(_0x5b1049,_0x15d690,_0x45f062)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x5ebbb5=>{for(const _0x3bc212 of this['editor']['editing']['view']['document']['roots'])_0x45f062?_0x5ebbb5['removeClass']('ck-editor__editable__overlay',_0x3bc212):_0x5ebbb5['addClass']('ck-editor__editable__overlay',_0x3bc212);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x591305=>null!==_0x591305),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x2b99e2,_0x561848,_0x441acb)=>_0x2b99e2&&_0x441acb?_0x561848['changes']['getIndex'](_0x441acb):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0xbdf72f,_0x1e7044)=>_0xbdf72f?_0x1e7044['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['adapter']=null,this['_balloon']=this['editor']['plugins']['get'](_0x162a1c);}['init'](){const _0xbdab20=this['editor'],_0x4e348e=new bt(_0xbdab20,{'direction':'backward'}),_0x2b52af=new bt(_0xbdab20,{'direction':'forward'});(_0xbdab20['commands']['add']('showPreviousChange',_0x4e348e),_0xbdab20['commands']['add']('showNextChange',_0x2b52af),_0xbdab20['commands']['add']('restoreRevision',new yt(_0xbdab20)),this['on']('change:numberOfChanges',()=>{_0x4e348e['refresh'](),_0x2b52af['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0xbdab20['enableReadOnlyMode']('revision-viewer'),_0xbdab20['plugins']['has']('WidgetToolbarRepository'))&&_0xbdab20['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionData'](_0x1273ff){await this['loadRevisionData'](_0x1273ff);const _0x4769b7={};for(const _0x1f86da in _0x1273ff['diffData']){if(_0x1273ff['diffData'][_0x1f86da]['attachChange']&&!_0x1273ff['diffData'][_0x1f86da]['attachChange']['isAttached'])continue;const _0x52ccae=this['_removeRevisionMarkers'](JSON['parse'](_0x1273ff['diffData'][_0x1f86da]['insertions'])),_0x203ea6=this['editor']['editing']['view']['document'],_0x110fde=new _0x46f024(_0x203ea6,_0x52ccae['map'](_0x2b1a44=>this['_getViewObj'](_0x2b1a44)));this['editor']['data']['processor']['useFillerType']('marked'),_0x4769b7[_0x1f86da]=this['editor']['data']['processor']['toData'](_0x110fde),this['editor']['data']['processor']['useFillerType']('default');}return _0x4769b7;}async['getRevisionRootsAttributes'](_0x2ab17f){await this['loadRevisionData'](_0x2ab17f);const _0x29b2e5={};for(const _0x3bef5d in _0x2ab17f['diffData'])_0x2ab17f['diffData'][_0x3bef5d]['attachChange']&&!_0x2ab17f['diffData'][_0x3bef5d]['attachChange']['isAttached']||(_0x29b2e5[_0x3bef5d]=_0x2ab17f['diffData'][_0x3bef5d]['attributesAfter']||{});return _0x29b2e5;}['_removeRevisionMarkers'](_0x1688c7){return(_0x1688c7=_0x1688c7['filter'](_0x17c9ce=>!_0x17c9ce['name']||'revision-start'!==_0x17c9ce['name']&&'revision-end'!==_0x17c9ce['name']))['forEach'](_0x5752ef=>{'string'!=typeof _0x5752ef&&(_0x5752ef['children']=this['_removeRevisionMarkers'](_0x5752ef['children']),_0x5752ef['attributes']=_0x5752ef['attributes']['filter'](_0x1a5377=>!_0x1a5377[0x0]['startsWith']('data-revision-')));}),_0x1688c7;}async['compare'](_0x5666a3,_0x3b0cdb,_0xa91092=!0x1){if(!this['isEnabled'])return;const _0x505195=this['diff'],_0x238d02=this['repository'],_0x45d7e2='string'==typeof _0x5666a3?_0x238d02['getRevision'](_0x5666a3):_0x5666a3,_0x31ff9c='string'==typeof _0x3b0cdb?_0x238d02['getRevision'](_0x3b0cdb):_0x3b0cdb,_0x62fb85=_0x45d7e2['id'],_0x52ff01=_0x31ff9c?_0x31ff9c['id']:null;if(!_0xa91092&&this['diff']&&this['diff']['newRevisionId']===_0x62fb85&&this['diff']['oldRevisionId']===_0x52ff01)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new f(_0x62fb85,_0x52ff01);const _0xe6e9b3=this['_getRevisionsRange'](_0x45d7e2,_0x31ff9c,!0x0)['map'](_0x17d074=>this['loadRevisionData'](_0x17d074));return _0xe6e9b3['push'](new Promise(_0x4a34e4=>{setTimeout(_0x4a34e4,0x14);})),Promise['all'](_0xe6e9b3)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x52cbec=this['_getDiff'](_0x62fb85,_0x52ff01);for(const _0x2d792e of _0x52cbec['changes'])this['_changeIdToChange']['set'](_0x2d792e['id'],_0x2d792e);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x462392=>{for(const _0x11475a of this['editor']['model']['document']['getRootNames']())_0x462392['detachRoot'](_0x11475a);for(const _0x33a823 of Object['keys'](_0x52cbec['model'])){const _0x53db9e=_0x462392['addRoot'](_0x33a823);for(const _0x245902 of Object['keys'](_0x52cbec['attributes'][_0x33a823]))_0x462392['setAttribute'](_0x245902,_0x52cbec['attributes'][_0x33a823][_0x245902],_0x53db9e);_0x462392['insert'](_0x52cbec['model'][_0x33a823],_0x53db9e,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x52cbec['changes'])),this['isReady']=!0x0;})['catch'](_0x5f1887=>{console['error'](_0x5f1887),this['_cleanUp'](),_0x505195&&(this['diff']=_0x505195),this['isReady']=!0x0;});}['addRevisionData'](_0x4ec875,_0x55b683){const _0xe5e226=this['repository']['createRevision'](_0x4ec875);return _0xe5e226['on']('_update',(_0x1b5e29,_0x5a3b71,_0xc17ef7)=>_0x55b683(_0x5a3b71,_0xc17ef7,_0xe5e226)),this['repository']['addRevision'](_0xe5e226),_0xe5e226;}['loadRevisionData'](_0x218682){if(!_0x218682||_0x218682['diffData'])return Promise['resolve']();{const _0x50a5c3=this['editor']['config']['get']('collaboration.channelId');return this['adapter']['getRevision']({'channelId':_0x50a5c3,'revisionId':_0x218682['id']})['then'](_0x110894=>{_0x218682['_update']({'diffData':_0x110894['diffData']},!0x0);});}}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0xc6f4cb=>{for(const _0x311851 of this['editor']['model']['document']['getRootNames']())_0xc6f4cb['detachRoot'](_0x311851);});}['_sortAndFilterDiffChanges'](_0x14a75a){const _0x26b998=[],_0x279bc6=new Map();for(const _0x6837d of this['editor']['model']['document']['getRootNames']()){const _0x121e0e=this['editor']['editing']['view']['getDomRoot'](_0x6837d);if(!_0x121e0e)continue;const _0x58a643=_0x121e0e['getClientRects']()['item'](0x0);_0x58a643&&(_0x26b998['push'](_0x6837d),_0x279bc6['set'](_0x6837d,_0x58a643));}return _0x26b998['sort']((_0x5cc96f,_0xf0902b)=>{const _0x5be4cf=_0x279bc6['get'](_0x5cc96f),_0x5b8b0a=_0x279bc6['get'](_0xf0902b);return _0x5be4cf['y']-_0x5b8b0a['y']||_0x5be4cf['x']-_0x5b8b0a['x'];}),(_0x14a75a=_0x14a75a['filter'](_0x263f80=>_0x26b998['includes'](_0x263f80['rootName'])))['sort']((_0x966ff4,_0xeb04d)=>_0x26b998['indexOf'](_0x966ff4['rootName'])-_0x26b998['indexOf'](_0xeb04d['rootName'])),_0x14a75a;}['_makeTape'](_0x586905){const _0x23cfd3=Array['from'](_0x586905['markers'])['filter'](([_0x5389ad,_0x42df24])=>_0x5389ad['startsWith']('revision:')&&!_0x42df24['isCollapsed']),_0x11d34d=Array['from'](this['editor']['model']['createRangeIn'](_0x586905)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x23cfd3['length'])for(const _0x5ac96f of _0x11d34d){const [_0x46a98f,_0x40b73b]=_0x23cfd3[0x0],[,_0x48da9e,_0xded59a]=_0x46a98f['split'](':');if(_0x40b73b['end']['isEqual'](_0x5ac96f['nextPosition'])&&_0x23cfd3['shift'](),(_0x5ac96f['previousPosition']['isEqual'](_0x40b73b['start'])||_0x5ac96f['previousPosition']['isAfter'](_0x40b73b['start']))&&('insertion'==_0x48da9e?_0x5ac96f['isAdded']={'userId':_0xded59a}:'deletion'==_0x48da9e&&(_0x5ac96f['isRemoved']={'userId':_0xded59a})),0x0==_0x23cfd3['length'])break;}return _0x11d34d;}['_refreshStartEndIndex'](_0x11135b){const _0xf3a168=new Map();for(let _0x4c5ef8=0x0;_0x4c5ef8<_0x11135b['length'];_0x4c5ef8++)'text'===_0x11135b[_0x4c5ef8]['type']?(_0x11135b[_0x4c5ef8]['item']['startIndex']=_0x4c5ef8,_0x11135b[_0x4c5ef8]['item']['endIndex']=_0x4c5ef8):('elementStart'===_0x11135b[_0x4c5ef8]['type']?_0x11135b[_0x4c5ef8]['item']['startIndex']=_0x4c5ef8:'elementEnd'===_0x11135b[_0x4c5ef8]['type']&&(_0x11135b[_0x4c5ef8]['item']['endIndex']=_0x4c5ef8),_0xf3a168['set'](_0x11135b[_0x4c5ef8]['id'],_0x4c5ef8));for(const _0x57d5af of _0xf3a168['values']())'elementStart'===_0x11135b[_0x57d5af]['type']?_0x11135b[_0x57d5af]['item']['endIndex']=_0xf3a168['get'](_0x11135b[_0x57d5af]['pairId']):'elementEnd'===_0x11135b[_0x57d5af]['type']&&(_0x11135b[_0x57d5af]['item']['startIndex']=_0xf3a168['get'](_0x11135b[_0x57d5af]['pairId']));}['_processTape'](_0x31ddd8){for(let _0x51832f=0x0;_0x51832f<_0x31ddd8['length'];_0x51832f++){if('elementStart'===_0x31ddd8[_0x51832f]['type'])_0x31ddd8[_0x51832f]['item']['startIndex']=_0x51832f;else{if('elementEnd'===_0x31ddd8[_0x51832f]['type']){_0x31ddd8[_0x51832f]['item']['endIndex']=_0x51832f;const _0x9a8d95=_0x31ddd8[_0x51832f]['item']['startIndex'];_0x31ddd8[_0x9a8d95]['pairId']=_0x31ddd8[_0x51832f]['id'],_0x31ddd8[_0x51832f]['pairId']=_0x31ddd8[_0x9a8d95]['id'];}else _0x31ddd8[_0x51832f]['item']['startIndex']=_0x51832f,_0x31ddd8[_0x51832f]['item']['endIndex']=_0x51832f,_0x31ddd8[_0x51832f]['pairId']=null;}_0x31ddd8[_0x51832f]['markersStart']||(_0x31ddd8[_0x51832f]['markersStart']=[],_0x31ddd8[_0x51832f]['markersEnd']=[]);}}['_markInsertions'](_0x1c1da0,_0x5c5006){const _0x471c71=_0x1c1da0['filter'](_0x24f72e=>!_0x24f72e['isAdded']);for(let _0xa5dd48=0x0;_0xa5dd48<_0x5c5006['length'];_0xa5dd48++)_0x5c5006[_0xa5dd48]['isAdded']&&(_0x471c71[_0xa5dd48]['isAdded']=_0x5c5006[_0xa5dd48]['isAdded']);}['_makeModelFromViewString'](_0x20f479){const _0x13058a=JSON['parse'](_0x20f479),_0x213a00=this['editor']['editing']['view']['document'],_0x184446=new _0x46f024(_0x213a00,_0x13058a['map'](_0x1e594a=>this['_getViewObj'](_0x1e594a)));return this['editor']['data']['toModel'](_0x184446);}['_getViewObj'](_0x15746b){const _0xa5f139=this['editor']['editing']['view']['document'];if('string'==typeof _0x15746b)return new _0x441ee8(_0xa5f139,_0x15746b);{const _0x155aaf=_0x15746b['children']['map'](_0x445196=>this['_getViewObj'](_0x445196));return new(Z[_0x15746b['type']]||_0x194c7d)(_0xa5f139,_0x15746b['name'],_0x15746b['attributes'],_0x155aaf);}}['_getDiff'](_0x2e029d,_0xd050c=null){const _0x4b4e4d=this['repository']['getRevision'](_0x2e029d),_0xa791eb=_0xd050c?this['repository']['getRevision'](_0xd050c):null,_0x7f8e33=this['_getRevisionsRange'](_0x4b4e4d,_0xa791eb),_0x561bfc=_0x7f8e33[_0x7f8e33['length']-0x1],_0x37ad22=new Map(),_0x49bd46={'model':{},'attributes':{},'changes':[]},_0x2428f8=new Set(),_0x5a8305=new Map();for(let _0x5e4bb1=_0x7f8e33['length']-0x1;_0x5e4bb1>=0x0;_0x5e4bb1--){const _0x39dd42=_0x7f8e33[_0x5e4bb1];for(const _0x14002e of Object['keys'](_0x39dd42['diffData']))if(_0x39dd42['diffData'][_0x14002e]['attachChange']){const _0x4a6f91=_0x39dd42['diffData'][_0x14002e]['attachChange'];_0x4a6f91['isAttached']?(_0x2428f8['add'](_0x14002e),_0x5a8305['has'](_0x14002e)&&_0x5a8305['get'](_0x14002e)['userId']==_0x4a6f91['userId']?_0x5a8305['delete'](_0x14002e):_0x5a8305['set'](_0x14002e,_0x4a6f91)):_0x5a8305['has'](_0x14002e)?(_0x2428f8['delete'](_0x14002e),_0x5a8305['delete'](_0x14002e)):(_0x2428f8['add'](_0x14002e),_0x5a8305['set'](_0x14002e,_0x4a6f91));}else _0x2428f8['add'](_0x14002e);}for(const _0x942567 of _0x2428f8){const _0x11a11a=_0x5a8305['has'](_0x942567)&&!_0x5a8305['get'](_0x942567)['isAttached'];let _0x3caa69=_0x11a11a?_0x7f8e33['length']-0x1:0x0;const _0x3dbeec=_0x11a11a?-0x1:0x1;for(;_0x7f8e33[_0x3caa69];){const _0x3b47b8=_0x7f8e33[_0x3caa69];if(_0x3b47b8['diffData'][_0x942567]){const _0x531fc9=_0x11a11a?_0x3b47b8['diffData'][_0x942567]['attributesBefore']:_0x3b47b8['diffData'][_0x942567]['attributesAfter'];_0x49bd46['attributes'][_0x942567]=_0x531fc9?_0x4839cc(_0x531fc9):{};break;}_0x3caa69+=_0x3dbeec;}}for(const _0x4c970e of _0x7f8e33){_0x4c970e['model']={};for(const _0x41aa12 of _0x4c970e['authors'])_0x37ad22['set'](_0x41aa12['id'],_0x41aa12);for(const _0x5d0d6f of _0x2428f8){const _0x315341=_0x4c970e['diffData'][_0x5d0d6f]?_0x4c970e['diffData'][_0x5d0d6f]['insertions']:'[]',_0x3536dd=_0x4c970e['diffData'][_0x5d0d6f]?_0x4c970e['diffData'][_0x5d0d6f]['deletions']:'[]';_0x4c970e['model'][_0x5d0d6f]={'insertions':this['_makeModelFromViewString'](_0x315341),'deletions':this['_makeModelFromViewString'](_0x3536dd)};}}for(const _0x34d6cb of _0x2428f8){let _0x12f61b=null,_0x375c40=0x0;const _0x4d8ac6=new Map(Array['from'](_0x4b4e4d['model'][_0x34d6cb]['insertions']['markers'])['filter'](([_0x370bbe])=>!_0x370bbe['startsWith']('revision:')));let _0x4ed278=0x0;for(const _0xbb4689 of _0x7f8e33){const _0xdb7995=this['_makeTape'](_0xbb4689['model'][_0x34d6cb]['insertions']);_0xbb4689==_0x4b4e4d?(_0x12f61b=_0xdb7995,_0x375c40=_0x12f61b['length'],_0x12f61b['forEach'](_0x5788d9=>{_0x5788d9['id']=_0x4ed278++;}),this['_processTape'](_0x12f61b)):this['_markInsertions'](_0x12f61b,_0xdb7995);const _0x3742ff=_0x12f61b['filter'](_0x46a10b=>!_0x46a10b['isAdded'])['map'](_0x2a9ba7=>_0x2a9ba7['id']);let _0x26c265=0x0;const _0x22e6b8=this['_makeTape'](_0xbb4689['model'][_0x34d6cb]['deletions']);_0x22e6b8['forEach'](_0x96d994=>{_0x96d994['isRemoved']?_0x96d994['id']=_0x375c40++:_0x96d994['id']=_0x3742ff[_0x26c265++];}),this['_processTape'](_0x22e6b8),this['_setDistance'](_0x12f61b,'isAdded'),this['_setDistance'](_0x22e6b8,'isRemoved'),_0xbb4689==_0x4b4e4d&&this['_markMarkers'](_0x12f61b,_0x4d8ac6),_0x12f61b=this['_joinTapes'](_0x12f61b,_0x22e6b8),this['_refreshStartEndIndex'](_0x12f61b),this['_setDistance'](_0x12f61b,'isRemoved');}_0x12f61b=_0x12f61b['filter'](_0x3061fd=>!(_0x3061fd['isAdded']&&_0x3061fd['isRemoved']));const _0x287919=new Map(_0x561bfc['model'][_0x34d6cb]['deletions']['markers']),_0x24d06b=new Set(_0x4d8ac6['keys']());for(const _0x564d39 of _0x287919['keys']())_0x24d06b['delete'](_0x564d39);this['_markSuggestions'](_0x12f61b,_0x24d06b),this['_fixObsoleteTags'](_0x12f61b),_0x12f61b=this['_removeMissingPairs'](_0x12f61b),_0x12f61b=this['_markMismatchedRemovedTags'](_0x12f61b),_0x12f61b=this['_removeUnsupportedChanges'](_0x12f61b);const {root:_0x370b27,changes:_0x42dba2}=this['_makeModelFromTape'](_0x12f61b,_0x37ad22,_0x34d6cb);_0x49bd46['model'][_0x34d6cb]=_0x370b27;const _0x5cd033=_0x5a8305['get'](_0x34d6cb);if(_0x5cd033){const _0x5c2c7f=_0x37ad22['get'](_0x5cd033['userId']),_0x4d4e7e=new r({'author':_0x5c2c7f,'type':_0x5cd033['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x34d6cb});_0x42dba2['unshift'](_0x4d4e7e),_0x49bd46['attributes'][_0x34d6cb]['revisionHistoryAttachChange']=_0x4d4e7e['id'];}_0x49bd46['changes']=_0x49bd46['changes']['concat'](_0x42dba2);}return _0x49bd46;}['_markMarkers'](_0x298636,_0x29f0ef){for(let _0x23c702=0x0;_0x23c702<_0x298636['length'];_0x23c702++)for(const [_0x59cd23,_0x20f6c5]of _0x29f0ef)_0x20f6c5['start']['isEqual'](_0x298636[_0x23c702]['previousPosition'])&&_0x298636[_0x23c702]['markersStart']['push'](_0x59cd23),_0x20f6c5['end']['isEqual'](_0x298636[_0x23c702]['nextPosition'])&&_0x298636[_0x23c702]['markersEnd']['push'](_0x59cd23);}['_joinTapes'](_0x14ef46,_0x259898){let _0x4815b9=[],_0x10b5c3=0x0,_0x33d123=0x0;for(;_0x10b5c3<_0x14ef46['length']||_0x33d123<_0x259898['length'];){const _0xc47cee=_0x14ef46[_0x10b5c3]||{},_0xf35ccd=_0x259898[_0x33d123]||{};if(_0xc47cee['id']==_0xf35ccd['id'])_0x10b5c3++,_0x33d123++,_0x4815b9['push'](_0xc47cee);else{if(_0xf35ccd['isRemoved']&&_0xc47cee['isAdded']){const {commonTape:_0x2ade31,iEnd:_0x22f786,jEnd:_0x27423b}=this['_threeWayMerge'](_0x14ef46,_0x10b5c3,_0x259898,_0x33d123);_0x4815b9=_0x4815b9['concat'](_0x2ade31),_0x10b5c3=_0x22f786,_0x33d123=_0x27423b;}else _0xf35ccd['isRemoved']?(_0x33d123++,_0x4815b9['push'](_0xf35ccd)):(_0x10b5c3++,_0x4815b9['push'](_0xc47cee));}}return _0x4815b9;}['_markSuggestions'](_0x38f169,_0x105e9d){const _0x5c9c17=[];for(let _0x195d41=0x0;_0x195d41<_0x38f169['length'];_0x195d41++){for(let _0x36f254=0x0;_0x36f254<_0x38f169[_0x195d41]['markersStart']['length'];_0x36f254++){const _0x3e4d23=_0x38f169[_0x195d41]['markersStart'][_0x36f254];if(!_0x105e9d['has'](_0x3e4d23))continue;const {group:_0x34cf8e,type:_0xb225a3,authorId:_0x340ccc}=_0x3705fc(_0x3e4d23);'revision-suggestion'!=_0x34cf8e||'insertion'!=_0xb225a3&&'deletion'!=_0xb225a3||(_0x5c9c17['unshift']({'type':_0xb225a3,'name':_0x3e4d23,'userId':_0x340ccc}),_0x38f169[_0x195d41]['markersStart']['splice'](_0x36f254,0x1),_0x36f254--);}_0x157dcf(_0x38f169[_0x195d41]);for(let _0x4ae580=0x0;_0x4ae580<_0x38f169[_0x195d41]['markersEnd']['length'];_0x4ae580++){const _0x302dea=_0x38f169[_0x195d41]['markersEnd'][_0x4ae580];if(!_0x105e9d['has'](_0x302dea))continue;const {group:_0x3dce4e,type:_0x45ea8d}=_0x3705fc(_0x302dea);if('revision-suggestion'!=_0x3dce4e||'insertion'!=_0x45ea8d&&'deletion'!=_0x45ea8d)continue;_0x38f169[_0x195d41]['markersEnd']['splice'](_0x4ae580,0x1),_0x4ae580--;const _0x56a636=_0x5c9c17['findIndex'](_0x1e243d=>_0x1e243d['name']==_0x302dea);_0x56a636>-0x1&&_0x5c9c17['splice'](_0x56a636,0x1);}}function _0x3705fc(_0x5c2e52){const _0x3e42df=_0x5c2e52['split'](':');return{'group':_0x3e42df[0x0],'type':_0x3e42df[0x1],'subType':_0x3e42df['length']>=0x5?_0x3e42df[0x2]:null,'id':_0x3e42df['length']<0x5?_0x3e42df[0x2]:_0x3e42df[0x3],'authorId':_0x3e42df['length']<0x5?_0x3e42df[0x3]:_0x3e42df[0x4],'markerCount':0x6==_0x3e42df['length']?_0x3e42df[0x5]:null};}function _0x157dcf(_0x573328){for(let _0x253f7b=0x0;_0x253f7b<_0x5c9c17['length'];_0x253f7b++){if(_0x573328['isAdded']&&'insertion'==_0x5c9c17[_0x253f7b]['type'])return _0x573328['isAddSuggestion']=_0x5c9c17[_0x253f7b],void delete _0x573328['isAdded'];if(!_0x573328['isAdded']&&!_0x573328['isRemoved']&&'deletion'==_0x5c9c17[_0x253f7b]['type'])return void(_0x573328['isRemoveSuggestion']=_0x5c9c17[_0x253f7b]);}}}['_setDistance'](_0x3373b4,_0x2300b9){let _0x5421b3=0x0,_0x5445d=!0x1;const _0x326f8c=new Map();for(const _0x460269 of _0x3373b4)_0x460269[_0x2300b9]?_0x5445d&&(_0x5421b3++,_0x5445d=!0x1):(_0x5421b3++,_0x5445d=!0x0),_0x326f8c['set'](_0x460269['id'],_0x5421b3);for(let _0x540769=0x0;_0x540769<_0x3373b4['length'];_0x540769++){if('isRemoved'==_0x2300b9&&_0x3373b4[_0x540769]['isAdded']||'isAdded'==_0x2300b9&&_0x3373b4[_0x540769]['isRemoved'])continue;if('text'==_0x3373b4[_0x540769]['type']){_0x3373b4[_0x540769]['distance']=0x0;continue;}const _0x42e02a=_0x326f8c['get'](_0x3373b4[_0x540769]['pairId']),_0x529c78=_0x326f8c['get'](_0x3373b4[_0x540769]['id']);_0x3373b4[_0x540769]['distance']=_0x42e02a-_0x529c78;}}['_getRevisionsRange'](_0x464773,_0x1f898e,_0x2cd4e9=!0x1){const _0x46b420=[];let _0x128d00=this['repository']['getIndex'](_0x464773),_0x44eaa7=this['repository']['getIndex'](_0x1f898e);for(-0x1==_0x44eaa7&&(_0x44eaa7=this['repository']['_revisions']['length'],_0x2cd4e9=!0x1);_0x128d00<_0x44eaa7;)_0x46b420['push'](this['repository']['getRevision'](_0x128d00)),_0x128d00++;return _0x2cd4e9&&_0x46b420['push'](this['repository']['getRevision'](_0x128d00)),_0x46b420;}['_threeWayMerge'](_0x5eea43,_0x2dde9b,_0x11d36b,_0x572b3b){const _0x5974db=this['editor']['model']['schema'];let _0x354482=_0x2dde9b;for(;_0x5eea43[_0x354482]&&_0x5eea43[_0x354482]['isAdded'];)_0x354482++;let _0x313d6b=_0x572b3b;for(;_0x11d36b[_0x313d6b]&&_0x11d36b[_0x313d6b]['isRemoved'];)_0x313d6b++;_0x15448c(_0x5eea43,_0x2dde9b,_0x354482),_0x15448c(_0x11d36b,_0x572b3b,_0x313d6b);const _0x9550b9=_0x11d36b['slice'](_0x572b3b,_0x313d6b)['concat'](_0x5eea43['slice'](_0x2dde9b,_0x354482));return _0x9550b9['sort']((_0x3064f1,_0x4bedb3)=>_0x3064f1['side']!=_0x4bedb3['side']?_0x3064f1['side']-_0x4bedb3['side']:_0x3064f1['level']!=_0x4bedb3['level']?_0x3064f1['level']-_0x4bedb3['level']:_0x3064f1['distance']!=_0x4bedb3['distance']?_0x4bedb3['distance']-_0x3064f1['distance']:!!_0x3064f1['isAdded']!=!!_0x4bedb3['isAdded']?-0x1==_0x3064f1['side']||0x0==_0x3064f1['side']?_0x3064f1['isAdded']?-0x1:0x1:_0x3064f1['isAdded']?0x1:-0x1:_0x3064f1['index']-_0x4bedb3['index']),{'commonTape':_0x9550b9,'iEnd':_0x354482,'jEnd':_0x313d6b};function _0x15448c(_0x213aeb,_0x37aa10,_0x2b4462){let _0x4a5633=-0x1,_0x2f21ed=Number['POSITIVE_INFINITY'],_0xffad6a=!0x0;for(let _0x1d63bc=_0x37aa10;_0x1d63bc<_0x2b4462;_0x1d63bc++)if(_0x5974db['isInline'](_0x213aeb[_0x1d63bc]['item'])||(_0xffad6a=!0x1),_0x213aeb[_0x1d63bc]['item']['startIndex']<_0x37aa10&&(_0x4a5633=_0x1d63bc),_0x213aeb[_0x1d63bc]['item']['endIndex']>=_0x2b4462){_0x2f21ed=_0x1d63bc;break;}_0xffad6a&&(_0x4a5633=_0x2b4462-0x1);for(let _0x2eca58=_0x37aa10;_0x2eca58<_0x2b4462;_0x2eca58++)_0x213aeb[_0x2eca58]['side']=_0x2eca58<=_0x4a5633?-0x1:_0x2eca58<_0x2f21ed?0x0:0x1,_0x213aeb[_0x2eca58]['index']=_0x2eca58;let _0x5b746b=0x0;for(let _0x1061fe=_0x37aa10;_0x1061fe<=_0x4a5633;_0x1061fe++)0x0==_0x213aeb[_0x1061fe]['distance']?_0x213aeb[_0x1061fe]['level']=_0x5b746b:(_0x5b746b++,_0x213aeb[_0x1061fe]['level']=_0x5b746b,_0x5b746b++);for(let _0x314674=_0x37aa10;_0x314674<_0x2b4462;_0x314674++)0x0==_0x213aeb[_0x314674]['side']&&(_0x213aeb[_0x314674]['level']=_0x5b746b);_0x5b746b=0x0;for(let _0xf08de4=_0x2b4462-0x1;_0xf08de4>=_0x2f21ed;_0xf08de4--)0x0==_0x213aeb[_0xf08de4]['distance']?_0x213aeb[_0xf08de4]['level']=_0x5b746b:(_0x5b746b--,_0x213aeb[_0xf08de4]['level']=_0x5b746b,_0x5b746b--);}}['_fixObsoleteTags'](_0x76e55a){const _0x4c8741=new Map(),_0x204edc=this['editor']['model']['schema'];for(let _0x45b262=0x1;_0x45b262<_0x76e55a['length'];_0x45b262++){let _0x373bdb,_0x32ec4c,_0x5e90f4;const _0x11c3c4=_0x76e55a[_0x45b262],_0x879093=_0x76e55a[_0x45b262-0x1];if('text'==_0x11c3c4['type'])continue;if(_0x11c3c4['type']!=_0x879093['type'])continue;if(!_0x204edc['isBlock'](_0x879093['item'])||_0x204edc['isLimit'](_0x879093['item']))continue;if(!_0x204edc['isBlock'](_0x11c3c4['item'])||_0x204edc['isLimit'](_0x11c3c4['item']))continue;if((_0x76e55a[_0x45b262]['isAdded']||_0x76e55a[_0x45b262]['isAddSuggestion'])&&_0x76e55a[_0x45b262-0x1]['isRemoved'])_0x373bdb=_0x76e55a[_0x45b262],_0x32ec4c=_0x76e55a[_0x45b262-0x1],_0x5e90f4=_0x45b262-0x1;else{if(!_0x76e55a[_0x45b262]['isRemoved']||!_0x76e55a[_0x45b262-0x1]['isAdded']&&!_0x76e55a[_0x45b262-0x1]['isAddSuggestion'])continue;_0x373bdb=_0x76e55a[_0x45b262-0x1],_0x32ec4c=_0x76e55a[_0x45b262],_0x5e90f4=_0x45b262;}const _0x2d72c2=_0x373bdb['level']==_0x32ec4c['level'],_0x2ce484=Math['abs'](_0x373bdb['level'])<Math['abs'](_0x32ec4c['level'])&&0x0==_0x32ec4c['distance'];(_0x2d72c2||_0x2ce484)&&(_0x4c8741['set'](_0x32ec4c['id'],_0x373bdb['id']),_0x76e55a['splice'](_0x5e90f4,0x1),_0x45b262--,_0x373bdb['isAdded']=!0x1);}for(let _0x222e4b=0x0;_0x222e4b<_0x76e55a['length'];_0x222e4b++)_0x4c8741['has'](_0x76e55a[_0x222e4b]['pairId'])&&(_0x76e55a[_0x222e4b]['pairId']=_0x4c8741['get'](_0x76e55a[_0x222e4b]['pairId']));}['_removeMissingPairs'](_0x28c8e9){const _0x130a66=new Set(_0x28c8e9['map'](_0x4e38ab=>_0x4e38ab['id']));for(let _0x138e28=0x0;_0x138e28<_0x28c8e9['length'];_0x138e28++)_0x130a66['has'](_0x28c8e9[_0x138e28]['pairId'])||0x0==_0x28c8e9[_0x138e28]['distance']||(_0x28c8e9[_0x138e28]['isIncorrect']=!0x0);return _0x28c8e9['filter'](_0xd4fd8d=>!_0xd4fd8d['isIncorrect']);}['_markMismatchedRemovedTags'](_0x478eef){const _0x3aed81=new Set();for(let _0x5ecb33=0x0;_0x5ecb33<_0x478eef['length'];_0x5ecb33++){if(_0x3aed81['has'](_0x478eef[_0x5ecb33]['id'])&&_0x478eef[_0x5ecb33]['isRemoved']&&(_0x478eef[_0x5ecb33]['isIncorrect']=!0x0),_0x478eef[_0x5ecb33]['isIncorrect'])continue;if(0x0==_0x478eef[_0x5ecb33]['distance'])continue;if('elementStart'!=_0x478eef[_0x5ecb33]['type'])continue;if(null==_0x478eef[_0x5ecb33]['pairId'])continue;let _0x4fc929=_0x5ecb33+0x1,_0x28c7ac=0x0;for(;_0x478eef[_0x4fc929]['id']!=_0x478eef[_0x5ecb33]['pairId'];)'elementStart'==_0x478eef[_0x4fc929]['type']?_0x28c7ac++:'elementEnd'==_0x478eef[_0x4fc929]['type']&&_0x28c7ac--,_0x4fc929++;if(0x0!=_0x28c7ac){if(_0x478eef[_0x5ecb33]['isRemoved'])_0x478eef[_0x5ecb33]['isIncorrect']=!0x0;else{for(;_0x4fc929!=_0x5ecb33;)_0x478eef[_0x4fc929]['isRemoved']&&0x0!=_0x478eef[_0x4fc929]['distance']&&(_0x478eef[_0x4fc929]['isIncorrect']=!0x0,_0x3aed81['add'](_0x478eef[_0x4fc929]['pairId'])),_0x4fc929--;}}}return _0x478eef['filter'](_0x17c121=>!_0x17c121['isIncorrect']);}['_removeUnsupportedChanges'](_0x58746d){const _0x3b9f1f=this['editor']['model']['schema'];for(let _0x335e07=0x0;_0x335e07<_0x58746d['length'];_0x335e07++){if(!(_0x58746d[_0x335e07]['isAdded']||_0x58746d[_0x335e07]['isAddSuggestion']||_0x58746d[_0x335e07]['isRemoved']||_0x58746d[_0x335e07]['isRemoveSuggestion']))continue;if(0x0==_0x58746d[_0x335e07]['distance'])continue;const _0x10e1bf=_0x58746d[_0x335e07]['item'];_0x3b9f1f['isBlock'](_0x10e1bf)||_0x3b9f1f['isLimit'](_0x10e1bf)||(_0x58746d[_0x335e07]['isAdded']&&delete _0x58746d[_0x335e07]['isAdded'],_0x58746d[_0x335e07]['isAddSuggestion']&&delete _0x58746d[_0x335e07]['isAddSuggestion'],_0x58746d[_0x335e07]['isRemoveSuggestion']&&delete _0x58746d[_0x335e07]['isRemoveSuggestion'],_0x58746d[_0x335e07]['isRemoved']&&(_0x58746d[_0x335e07]['isIncorrect']=!0x0));}return _0x58746d['filter'](_0x213e3f=>!_0x213e3f['isIncorrect']);}['_makeModelFromTape'](_0x30ee01,_0x2d198d,_0x24c1e3){const _0x355b65=new wt(),_0x5627aa=[],_0x1f18f1=new Map(),_0x3a3678=this['editor']['model'],_0x567e64=_0x3a3678['schema'],_0x5e028b=[_0x355b65],_0x141f7b={},_0x30a1c9={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x443517=null;const _0x7f812d=[0x0];for(let _0x9ecaf2=0x0;_0x9ecaf2<_0x30ee01['length'];_0x9ecaf2++)if('elementStart'===_0x30ee01[_0x9ecaf2]['type']){_0x30ee01[_0x9ecaf2]['previousPosition']=_0x3a3678['createPositionFromPath'](_0x355b65,_0x7f812d);const _0x24cbaf=new ft(_0x30ee01[_0x9ecaf2]['item']['name'],_0x30ee01[_0x9ecaf2]['item']['getAttributes']());_0x5e028b[0x0]['_appendChild'](_0x24cbaf),_0x7f812d['push'](0x0),_0x5e028b['unshift'](_0x24cbaf),_0x30ee01[_0x9ecaf2]['nextPosition']=_0x3a3678['createPositionFromPath'](_0x355b65,_0x7f812d);}else'elementEnd'===_0x30ee01[_0x9ecaf2]['type']?(_0x5e028b['shift'](),_0x30ee01[_0x9ecaf2]['previousPosition']=_0x3a3678['createPositionFromPath'](_0x355b65,_0x7f812d),_0x7f812d['pop'](),_0x7f812d[_0x7f812d['length']-0x1]++,_0x30ee01[_0x9ecaf2]['nextPosition']=_0x3a3678['createPositionFromPath'](_0x355b65,_0x7f812d)):(_0x30ee01[_0x9ecaf2]['previousPosition']=_0x3a3678['createPositionFromPath'](_0x355b65,_0x7f812d),_0x443517?_0x443517['_data']+=_0x30ee01[_0x9ecaf2]['item']['data']:_0x443517=new _t(_0x30ee01[_0x9ecaf2]['item']['data'],_0x30ee01[_0x9ecaf2]['item']['getAttributes']()),_0x30ee01[_0x9ecaf2+0x1]&&'text'===_0x30ee01[_0x9ecaf2+0x1]['type']&&_0x1b5e1f(_0x443517,_0x30ee01[_0x9ecaf2+0x1]['item'])||(_0x5e028b[0x0]['_appendChild'](_0x443517),_0x443517=null),_0x7f812d[_0x7f812d['length']-0x1]+=_0x30ee01[_0x9ecaf2]['item']['offsetSize'],_0x30ee01[_0x9ecaf2]['nextPosition']=_0x3a3678['createPositionFromPath'](_0x355b65,_0x7f812d));for(let _0x25e080=0x0;_0x25e080<_0x30ee01['length'];_0x25e080++){const _0x433781=_0x30ee01[_0x25e080]['previousPosition'],_0xc2f2c7=_0x30ee01[_0x25e080]['nextPosition'];for(const _0x38901a of _0x30ee01[_0x25e080]['markersStart'])_0x1f18f1['set'](_0x38901a,{'start':_0x433781,'end':null});_0x50b164('isRemoveSuggestion',_0x25e080,_0x433781,_0xc2f2c7),_0x50b164('isAddSuggestion',_0x25e080,_0x433781,_0xc2f2c7),_0x50b164('isRemoved',_0x25e080,_0x433781,_0xc2f2c7),_0x50b164('isAdded',_0x25e080,_0x433781,_0xc2f2c7);for(const _0x5102e7 of _0x30ee01[_0x25e080]['markersEnd']){_0x1f18f1['get'](_0x5102e7)['end']=_0xc2f2c7;}}for(const [_0x12bb19,_0x28dcde]of _0x1f18f1){const _0x48eeaf=this['editor']['model']['createRange'](_0x28dcde['start'],_0x28dcde['end']);_0x355b65['markers']['set'](_0x12bb19,_0x48eeaf);}return _0x5627aa['sort']((_0x552089,_0x26dfda)=>{const _0x1ab738=_0x355b65['markers']['get']('revision:'+_0x552089['id']),_0x371f28=_0x355b65['markers']['get']('revision:'+_0x26dfda['id']);return _0x1ab738['start']['isBefore'](_0x371f28['start'])?-0x1:_0x1ab738['start']['isAfter'](_0x371f28['start'])?0x1:_0x1ab738['end']['isBefore'](_0x371f28['end'])?-0x1:_0x1ab738['end']['isAfter'](_0x371f28['end'])?0x1:'add'===_0x552089['type']?-0x1:0x1;}),{'root':_0x355b65,'changes':_0x5627aa};function _0x50b164(_0x4b8a12,_0x49ea83,_0x3485ee,_0x298792){const _0x5ee169=!!_0x30ee01[_0x49ea83][_0x4b8a12],_0x107a99=_0x5ee169?_0x30ee01[_0x49ea83][_0x4b8a12]['userId']:null,_0x2243c1=_0x49ea83===_0x30ee01['length']-0x1,_0x33fbc8=_0x30a1c9[_0x4b8a12][0x0],_0xd352b2=_0x567e64['isObject'](_0x30ee01[_0x49ea83]['item']);!_0x141f7b[_0x4b8a12]&&_0x5ee169?_0x141f7b[_0x4b8a12]={'start':_0x3485ee,'tapeItem':_0x30ee01[_0x49ea83],'userId':_0x107a99,'type':_0x4b8a12}:_0x141f7b[_0x4b8a12]&&!_0x5ee169?(_0x141f7b[_0x4b8a12]['end']=_0x3485ee,_0x573793(_0x141f7b[_0x4b8a12]),_0x141f7b[_0x4b8a12]=null):_0x141f7b[_0x4b8a12]&&_0x5ee169&&_0x141f7b[_0x4b8a12]['userId']!==_0x107a99&&(_0x141f7b[_0x4b8a12]['end']=_0x3485ee,_0x33fbc8&&_0x33fbc8['userId']===_0x141f7b[_0x4b8a12]['userId']||_0x573793(_0x141f7b[_0x4b8a12]),_0x141f7b[_0x4b8a12]={'start':_0x3485ee,'tapeItem':_0x30ee01[_0x49ea83],'userId':_0x107a99,'type':_0x4b8a12}),_0x141f7b[_0x4b8a12]&&_0xd352b2&&('elementStart'!==_0x30ee01[_0x49ea83]['type']||_0x33fbc8&&_0x33fbc8['userId']===_0x107a99||_0x30a1c9[_0x4b8a12]['unshift']({'userId':_0x107a99,'object':_0x30ee01[_0x49ea83]['item'],'change':_0x141f7b[_0x4b8a12]}),'elementEnd'===_0x30ee01[_0x49ea83]['type']&&_0x33fbc8&&_0x33fbc8['object']===_0x30ee01[_0x49ea83]['item']&&(_0x30a1c9[_0x4b8a12]['shift'](),_0x141f7b[_0x4b8a12]=_0x33fbc8['change'])),_0x141f7b[_0x4b8a12]&&_0x2243c1&&(_0x141f7b[_0x4b8a12]['end']=_0x298792,_0x573793(_0x141f7b[_0x4b8a12]),_0x141f7b[_0x4b8a12]=null);}function _0x573793({start:_0x559b54,end:_0x37e396,tapeItem:_0x3230b8,userId:_0x545433,type:_0x4f8e69}){const _0x2f01e7=_0x3230b8['item'],_0x120e61=_0x3a3678['schema']['isBlock'](_0x2f01e7)&&!_0x3a3678['schema']['isLimit'](_0x2f01e7),_0xbeee31=_0x559b54['nodeAfter']==_0x37e396['parent']&&_0x37e396['isAtStart'];if(_0x120e61&&_0xbeee31)return;const _0x1b6d0b=_0x3a3678['createRange'](_0x559b54,_0x37e396),_0x571b31=_0x2d198d['get'](_0x545433),_0x544fb4=new r({'author':_0x571b31,'type':'isAdded'==_0x4f8e69||'isAddSuggestion'==_0x4f8e69?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x4f8e69||'isRemoveSuggestion'==_0x4f8e69},'createdAt':new Date(),'rootName':_0x24c1e3});_0x5627aa['push'](_0x544fb4),_0x355b65['markers']['set']('revision:'+_0x544fb4['id'],_0x1b6d0b);}function _0x1b5e1f(_0x3d8bad,_0x119742){const _0x1923b3=_0x3d8bad['getAttributes'](),_0x1b7056=_0x119742['getAttributes']();for(const _0x3c76cf of _0x1923b3){if(_0x3c76cf[0x1]!==_0x119742['getAttribute'](_0x3c76cf[0x0]))return!0x1;_0x1b7056['next']();}return _0x1b7056['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x3fcb69=>{const _0x4033e9=_0x3fcb69['markerName']['split'](':')[0x1],_0x59dcfd=this['_getChangeFromId'](_0x4033e9);if(!_0x59dcfd)return null;const _0x4bfccc='add'==_0x59dcfd['type']?'insertion':'deletion',_0x5003eb=['ck-suggestion-marker','ck-suggestion-marker-'+_0x4bfccc];return _0x59dcfd['data']['isSuggestion']&&_0x5003eb['push']('ck-suggestion-marker-'+_0x4bfccc+'-new'),this['activeChange']==_0x59dcfd&&_0x5003eb['push']('ck-suggestion-marker--active'),{'classes':_0x5003eb,'attributes':{'data-change-id':_0x4033e9}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x28c85c=>{_0x28c85c['on']('element:pre',(_0x508965,_0x13b76e,_0x310867)=>{const _0x4c5758=_0x13b76e['viewItem']['getChild'](0x0);if(!_0x4c5758||!_0x4c5758['is']('element','code'))return;if(!_0x310867['consumable']['consume'](_0x4c5758,{'attributes':['vid_start','vid_end']}))return;const _0xa2b731=_0x13b76e['modelRange']['start']['nodeAfter'];_0x310867['writer']['setAttribute']('vid_start',_0x4c5758['getAttribute']('vid_start'),_0xa2b731),_0x310867['writer']['setAttribute']('vid_end',_0x4c5758['getAttribute']('vid_end'),_0xa2b731);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x50ba4c=>{_0x50ba4c['on']('element',(_0x2c7b39,_0x508898,_0x277836)=>{if(!_0x277836['consumable']['consume'](_0x508898['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x508898['modelRange']['isCollapsed'])return;const _0x57d1b7=_0x508898['modelRange']['start']['nodeAfter'];_0x57d1b7['hasAttribute']('vid_start')||_0x57d1b7['hasAttribute']('vid')||(_0x277836['writer']['setAttribute']('vid_start',_0x508898['viewItem']['getAttribute']('vid_start'),_0x57d1b7),_0x277836['writer']['setAttribute']('vid_end',_0x508898['viewItem']['getAttribute']('vid_end'),_0x57d1b7));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x296707=>_0x296707['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x629fa1,[,_0x100a1e])=>{['vid_start','vid_end','vid']['includes'](_0x100a1e)&&(_0x629fa1['return']=!0x0,_0x629fa1['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x322405=>{_0x322405['on']('attribute:vid',(_0x11edae,_0x4fad26,_0x23cd7c)=>{if('\x20'!=_0x4fad26['item']['data']||_0x4fad26['item']['parent']['maxOffset']>0x1)return;if(!_0x23cd7c['consumable']['consume'](_0x4fad26['item'],_0x11edae['name']))return;const _0x1d9949=_0x23cd7c['writer'],_0x2f51f5=_0x23cd7c['mapper']['toViewRange'](_0x4fad26['range']);_0x1d9949['wrap'](_0x2f51f5,_0x1d9949['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x202aa6){const _0x10dc9e=_0x202aa6['plugins']['get']('RevisionViewer');return(_0xec0053,_0xab5a91,_0x114408)=>{const _0xe0c6ee=_0xab5a91['markerName']['split'](':')[0x1],_0x2ce395=_0x10dc9e['_getChangeFromId'](_0xe0c6ee);if(!_0x2ce395)return null;const _0x12f755='add'==_0x2ce395['type']?'split':'merge';if(!_0x114408['consumable']['test'](_0xab5a91['markerRange'],_0xec0053['name']))return;const _0x4daa90=_0xab5a91['markerRange']['getWalker'](),_0x3f5fcc=_0xab5a91['markerRange']['start'],_0x4b8467=_0x202aa6['model']['schema'];let _0x5db029=null,_0x36df61=null,_0x1ea9c5=!0x1,_0x380477=!0x1;for(const _0x374636 of _0x4daa90){const _0x458c34=_0x374636['item'];_0x1ea9c5=_0x1ea9c5||_0x4b8467['isContent'](_0x458c34);const _0x316a72=_0x114408['mapper']['toViewElement'](_0x458c34);if(_0x316a72&&_0x316a72['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x374636['type']&&(_0x4b8467['isBlock'](_0x458c34)&&!_0x4b8467['isLimit'](_0x458c34)&&(_0x458c34['nextSibling']||_0x3f5fcc['isAtEnd']?_0x5db029&&_0x5db029['parent']==_0x458c34||(_0x5db029=_0x458c34,_0x465099(_0x374636['previousPosition']),_0x380477=!0x0):_0x36df61=_0x36df61||_0x374636['previousPosition']));}function _0x465099(_0x212155){const _0x161471=_0x114408['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x12f755}),_0x533725=_0x114408['mapper']['toViewPosition'](_0x212155);_0x2ce395['data']['isSuggestion']&&_0x114408['writer']['addClass']('ck-suggestion-marker-'+_0x12f755+'-new',_0x161471),_0x10dc9e['activeChange']==_0x2ce395&&_0x114408['writer']['addClass']('ck-suggestion-marker--active',_0x161471),_0x114408['writer']['insert'](_0x533725,_0x161471),_0x114408['mapper']['bindElementToMarker'](_0x161471,_0xab5a91['markerName']);}_0x1ea9c5||_0x380477||!_0x36df61||_0x465099(_0x36df61);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x585e3a,_0xae8552,_0x5d2976)=>{const _0x5af0e1=_0x5d2976['mapper']['markerNameToElements'](_0xae8552['markerName']);if(_0x5af0e1){for(const _0x22eee4 of _0x5af0e1)(_0x22eee4['hasClass']('ck-suggestion-marker-split')||_0x22eee4['hasClass']('ck-suggestion-marker-merge'))&&(_0x5d2976['mapper']['unbindElementFromMarkerName'](_0x22eee4,_0xae8552['markerName']),_0x5d2976['writer']['remove'](_0x22eee4));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x4a2225,_0x3dc4a9,_0x3545f8)=>{const _0xabe4d0=_0x3dc4a9['markerName']['split'](':')[0x1],_0x49f98f=this['_getChangeFromId'](_0xabe4d0);if(!_0x49f98f)return null;const _0x448651='add'==_0x49f98f['type']?'split':'merge';if(_0x3545f8['consumable']['test'](_0x3dc4a9['markerRange'],_0x4a2225['name']))for(const _0x79d67a of _0x3dc4a9['markerRange']['getItems']()){if(!_0x79d67a['is']('element','softBreak'))continue;const _0x2ed526=_0x3545f8['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x448651}),_0x2d295a=_0x3545f8['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x79d67a));_0x49f98f['data']['isSuggestion']&&_0x3545f8['writer']['addClass']('ck-suggestion-marker-'+_0x448651+'-new',_0x2ed526),this['activeChange']==_0x49f98f&&_0x3545f8['writer']['addClass']('ck-suggestion-marker--active',_0x2ed526),_0x3545f8['writer']['insert'](_0x2d295a,_0x2ed526),_0x3545f8['mapper']['bindElementToMarker'](_0x2ed526,_0x3dc4a9['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x5be1d2=>{for(const _0x27c9c9 of this['editor']['model']['document']['getRootNames']()){const _0xee6268=this['editor']['model']['document']['getRoot'](_0x27c9c9),_0xcf6915=this['editor']['editing']['view']['document']['getRoot'](_0x27c9c9);if(_0xcf6915){const _0x5844b1=_0xee6268['getAttribute']('revisionHistoryAttachChange');if(_0x5be1d2['removeAttribute']('data-change-id',_0xcf6915),_0x5be1d2['removeClass']('ck-revision-history-root-add',_0xcf6915),_0x5be1d2['removeClass']('ck-revision-history-root-remove',_0xcf6915),_0x5be1d2['removeClass']('ck-revision-history-root--active',_0xcf6915),_0x5844b1){const _0x4b29ed=this['_getChangeFromId'](_0x5844b1);if(!_0x4b29ed)return null;_0x5be1d2['setAttribute']('data-change-id',_0x5844b1,_0xcf6915),_0x5be1d2['addClass']('ck-revision-history-root-'+_0x4b29ed['type'],_0xcf6915),this['activeChange']==_0x4b29ed&&_0x5be1d2['addClass']('ck-revision-history-root--active',_0xcf6915);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x9ea911=>'revision-comment:'+_0x9ea911,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x569c78=>'revision-suggestion:'+_0x569c78,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0xf6ca2f=>({'name':'suggestion:'+_0xf6ca2f,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x5e3fcf=>{const _0x14cab6=_0x5e3fcf['markerName']['split'](':')[0x1];return'insertion'!=_0x14cab6&&'deletion'!=_0x14cab6?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x14cab6]};}}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:deletion',tt(this['editor'],'merge'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:insertion',tt(this['editor'],'split'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision-suggestion',(_0x5c8106,_0x37dbab,_0x544459)=>{const _0x587788=_0x544459['mapper']['markerNameToElements'](_0x37dbab['markerName']);if(_0x587788){for(const _0x4c2b29 of _0x587788)_0x4c2b29['is']('uiElement')&&(_0x544459['mapper']['unbindElementFromMarkerName'](_0x4c2b29,_0x37dbab['markerName']),_0x544459['writer']['remove'](_0x4c2b29));}},{'priority':'high'});}['_getChangeFromId'](_0x3d9230){return this['_changeIdToChange']['get'](_0x3d9230);}['_getViewForChange'](_0x5de327){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new Y(this['editor']['locale'],_0x5de327),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x1d2896,_0x3f2c75,_0x370a91,_0x5dfee4)=>{_0x5dfee4&&this['_balloon']['remove'](_0x5dfee4),_0x370a91&&(this['_balloon']['add']({'view':_0x370a91,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x2f92c3=this['editor']['editing'],_0xd00a3=this['_getChangeFromId'](_0x370a91['changeId']);let _0x13e890;if(_0xd00a3['data']['isOnRoot']){const _0x4dd258=_0x2f92c3['view']['getDomRoot'](_0xd00a3['rootName']);_0x13e890=Array['from'](_0x4dd258['getClientRects']());}else{const _0x4dbaea=this['editor']['model']['markers']['get']('revision:'+_0x370a91['changeId']);_0x13e890=Array['from'](_0x2f92c3['mapper']['markerNameToElements'](_0x4dbaea['name']))['map'](_0xa5084e=>_0x2f92c3['view']['domConverter']['mapViewToDom'](_0xa5084e))['map'](_0x57a4ec=>Array['from'](_0x57a4ec['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x13e890[0x0];return _0x13e890['find'](_0xcd74ec=>_0xcd74ec['top']-0x3<=this['_activeViewTarget']['y']&&_0xcd74ec['bottom']+0x3>=this['_activeViewTarget']['y']&&_0xcd74ec['left']-0x3<=this['_activeViewTarget']['x']&&_0xcd74ec['right']+0x3>=this['_activeViewTarget']['x'])||_0x13e890[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x2ecd68,_0x481af2,_0x5cf5a7,_0x133071)=>{this['activeView']=_0x5cf5a7?this['_getViewForChange'](_0x5cf5a7):null,this['editor']['model']['change'](()=>{const _0x213378=this['editor']['editing'];_0x133071&&(_0x133071['data']['isOnRoot']?_0x213378['view']['change'](_0x1b5871=>{_0x1b5871['removeClass']('ck-revision-history-root--active',_0x213378['view']['document']['getRoot'](_0x133071['rootName']));}):_0x213378['reconvertMarker']('revision:'+_0x133071['id'])),_0x5cf5a7&&(_0x5cf5a7['data']['isOnRoot']?_0x213378['view']['change'](_0x167293=>{_0x167293['addClass']('ck-revision-history-root--active',_0x213378['view']['document']['getRoot'](_0x5cf5a7['rootName']));}):_0x213378['reconvertMarker']('revision:'+_0x5cf5a7['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x4aa157,_0x5572a5)=>{if(this['activeChange'])return;const _0x390b5e=this['_findChangeIdFromDomTarget'](_0x5572a5['target']),_0xee6cf7=this['_changeIdToChange']['get'](_0x390b5e);_0xee6cf7?(this['_activeViewTarget']={'x':_0x5572a5['domEvent']['x'],'y':_0x5572a5['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0xee6cf7)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x52c14a,_0x1862fd)=>{const _0x113568=this['_findChangeIdFromDomTarget'](_0x1862fd['target']),_0x4977a3=this['_changeIdToChange']['get'](_0x113568);_0x4977a3?(this['_activeViewTarget']={'x':_0x1862fd['domEvent']['x'],'y':_0x1862fd['domEvent']['y']},_0x4977a3===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x4977a3):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x42adc8){do{const _0x46392f=_0x42adc8['getAttribute']('data-change-id');if(_0x46392f)return _0x46392f;_0x42adc8=_0x42adc8['parent'];}while(_0x42adc8);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x617c63=>{for(const _0x3d464f of this['editor']['model']['markers'])_0x617c63['removeMarker'](_0x3d464f);});}}function tt(_0x5cd41f,_0x11f970){return(_0x46898d,_0x313c09,_0x474c99)=>{if(!_0x474c99['consumable']['test'](_0x313c09['markerRange'],_0x46898d['name']))return;const _0x3958e1=_0x313c09['markerRange']['getWalker'](),_0x5e090d=_0x313c09['markerRange']['start'],_0x54bcf2=_0x5cd41f['model']['schema'];let _0xfb21b9=null,_0x5481da=null,_0x367e88=!0x1,_0x58485e=!0x1;for(const _0x5878db of _0x3958e1){const _0x760d92=_0x5878db['item'];_0x367e88=_0x367e88||_0x54bcf2['isContent'](_0x760d92);const _0x541fed=_0x474c99['mapper']['toViewElement'](_0x760d92);if(_0x541fed&&_0x541fed['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x5878db['type']&&(_0x54bcf2['isBlock'](_0x760d92)&&!_0x54bcf2['isLimit'](_0x760d92)&&(_0x760d92['nextSibling']||_0x5e090d['isAtEnd']?_0xfb21b9&&_0xfb21b9['parent']==_0x760d92||(_0xfb21b9=_0x760d92,_0x51fe04(_0x5878db['previousPosition']),_0x58485e=!0x0):_0x5481da=_0x5481da||_0x5878db['previousPosition']));}function _0x51fe04(_0x36e57d){const _0x19f4c9=_0x474c99['mapper']['toViewPosition'](_0x36e57d),_0x44e5bd=_0x474c99['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x11f970});_0x474c99['writer']['insert'](_0x19f4c9,_0x44e5bd),_0x474c99['mapper']['bindElementToMarker'](_0x44e5bd,_0x313c09['markerName']);}_0x367e88||_0x58485e||!_0x5481da||_0x51fe04(_0x5481da);};}class yt extends _0x1c762c{constructor(_0x20160d){super(_0x20160d);const _0x5f3897=_0x20160d['plugins']['get'](d);this['affectsData']=!0x1,this['listenTo'](_0x5f3897,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x5f3897,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x10358a=this['editor'],_0x2f86ac=_0x10358a['plugins']['get'](d),_0x4d41de=_0x2f86ac['isReady']?_0x2f86ac['diff']['newRevisionId']:null;_0x10358a['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x4d41de);}['refresh'](){const {isReady:_0x2c1886,isEnabled:_0x29d28a,repository:_0x3626a2,diff:_0x5eab3e}=this['editor']['plugins']['get'](d),_0x2e9032=_0x5eab3e&&_0x3626a2['getLaterVisibleRevision'](_0x5eab3e['newRevisionId']);this['isEnabled']=_0x2c1886&&_0x29d28a&&Boolean(_0x2e9032);}}class bt extends _0x1c762c{['_step'];constructor(_0x403d5a,{direction:_0x27acd6}){super(_0x403d5a);const _0x2d56ea=_0x403d5a['plugins']['get'](d);this['affectsData']=!0x1,this['_step']='forward'===_0x27acd6?0x1:-0x1,this['listenTo'](_0x2d56ea,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x2d56ea,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x2d56ea,'change:activeChange',()=>this['refresh']());}['execute'](){const _0xa60084=this['editor'],_0x33568f=_0xa60084['plugins']['get'](d),{isNavigationMode:_0xfbfa9a,currentChangeNumber:_0x103723}=_0x33568f;let _0x3aff1d;if(_0x33568f['activeChange']=_0xfbfa9a?_0x33568f['diff']['changes']['get'](_0x103723+this['_step']):_0x33568f['diff']['changes']['first'],_0x33568f['activeChange']['data']['isOnRoot'])_0x3aff1d=_0xa60084['editing']['view']['getDomRoot'](_0x33568f['activeChange']['rootName']);else{const _0x2303bf=_0xa60084['model']['markers']['get']('revision:'+_0x33568f['activeChange']['id']);_0x3aff1d=_0x45f010(_0xa60084['editing'],_0x2303bf);}_0x373097({'target':_0x3aff1d,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x59cf6a,currentChangeNumber:_0x27ce5d,numberOfChanges:_0x17d5e1,isReady:_0x2a851f,isEnabled:_0x5387b7}=this['editor']['plugins']['get'](d);this['isEnabled']=!!(_0x5387b7&&_0x2a851f&&_0x17d5e1)&&(!_0x59cf6a||(0x1===this['_step']?_0x27ce5d<_0x17d5e1-0x1:_0x27ce5d>0x0));}}class di extends _0x52b1f5{constructor(_0x342eb1){super(_0x342eb1);const _0x3362ad=this['bindTemplate'],_0x345d05=new _0x36250d(_0x342eb1),_0x3e8207=new _0x36250d(_0x342eb1);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',(_0x2528a0,_0x2b445b)=>_0x2528a0&&_0x2b445b>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x51959d,_0x39eecf,_0x44cb3e,_0x285091)=>{if(!_0x51959d)return R(_0x342eb1,'Loading...');if(!_0x44cb3e)return R(_0x342eb1,'No\x20changes');const _0x5c34ff=R(_0x342eb1,'NUMBER_OF_CHANGES',_0x44cb3e);return _0x285091?R(_0x342eb1,'X_OF_Y_CHANGES',[_0x39eecf+0x1,_0x44cb3e]):_0x5c34ff;}),_0x345d05['set']({'label':R(_0x342eb1,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':'<svg\x20viewBox=\x220\x200\x2020\x2020\x22\x20xmlns=\x22http://www.w3.org/2000/svg\x22><path\x20d=\x22M16.435\x2014.494a.75.75\x200\x200\x200\x201.197-.899l-.067-.089-6.992-8a.75.75\x200\x200\x200-1.05-.078l-.079.078-7.008\x208a.75.75\x200\x200\x200\x201.049\x201.066l.08-.078\x206.442-7.354\x206.428\x207.354z\x22/></svg>\x0a'}),_0x3e8207['set']({'label':R(_0x342eb1,'Show\x20next\x20change'),'tooltip':!0x0,'icon':'<svg\x20viewBox=\x220\x200\x2020\x2020\x22\x20xmlns=\x22http://www.w3.org/2000/svg\x22><path\x20d=\x22M16.435\x205.506a.75.75\x200\x200\x201\x201.197.899l-.067.089-6.992\x208a.75.75\x200\x200\x201-1.05.078l-.079-.078-7.008-8a.75.75\x200\x200\x201\x201.049-1.066l.08.078\x206.442\x207.354\x206.428-7.354z\x22/></svg>\x0a'}),_0x345d05['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x3e8207['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x345d05['on']('execute',()=>this['fire']('execute','backward')),_0x3e8207['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',_0x3362ad['if']('_isStatusLabelVisible','ck-hidden',_0x994c73=>!_0x994c73)]},'children':[{'text':_0x3362ad['to']('isNavigationMode',_0x7a0393=>_0x7a0393?R(_0x342eb1,'EDIT_X_OF_Y_REVISIONS')+':\x20':R(_0x342eb1,'Total')+':\x20')}]},{'text':_0x3362ad['to']('_statusText')}]},new _0x6e8557(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x345d05,_0x3e8207]}]});}}const ce='ck-editor__editable__loading-overlay';class ae extends _0x4632d0{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x2375c2=this['editor']['editing']['view'];_0x2375c2['change'](_0x59e503=>{for(const _0x5b9d36 of _0x2375c2['document']['roots'])_0x59e503['addClass'](ce,_0x5b9d36);});}['hide'](){const _0x41505d=this['editor']['editing']['view'];_0x41505d['change'](_0x3998b0=>{for(const _0x39731f of _0x41505d['document']['roots'])_0x3998b0['removeClass'](ce,_0x39731f);});}}class m extends _0x4632d0{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[d,ae];}['init'](){const _0x2bba96=this['editor'],_0x1bd402=_0x2bba96['plugins']['get'](d),_0x3e5062=_0x2bba96['plugins']['get'](ae);_0x2bba96['ui']['componentFactory']['add']('exitToEditing',_0x279a17=>{const _0x1f7a1=new _0x36250d(_0x279a17);return _0x1f7a1['set']({'label':R(_0x279a17,'Back\x20to\x20editing'),'icon':_0x535503['undo'],'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x1f7a1,'execute',()=>{_0x2bba96['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x1f7a1;}),_0x2bba96['ui']['componentFactory']['add']('restoreRevision',_0x13c21b=>{const _0x5e1966=new _0x36250d(_0x13c21b);return _0x5e1966['set']({'label':R(_0x13c21b,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x5e1966['bind']('isEnabled')['to'](_0x2bba96['commands']['get']('restoreRevision')),this['listenTo'](_0x5e1966,'execute',()=>_0x2bba96['execute']('restoreRevision')),_0x5e1966;}),_0x2bba96['ui']['componentFactory']['add']('changesNavigation',_0x3b0a6f=>{const _0x1401de=new di(_0x3b0a6f),_0x532611=_0x2bba96['commands']['get']('showPreviousChange'),_0x1f87b6=_0x2bba96['commands']['get']('showNextChange');return _0x1401de['bind']('isBackwardNavigationEnabled')['to'](_0x532611,'isEnabled'),_0x1401de['bind']('isForwardNavigationEnabled')['to'](_0x1f87b6,'isEnabled'),_0x1401de['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x1bd402),this['listenTo'](_0x1401de,'execute',(_0x5d58e6,_0x5b8021)=>{_0x2bba96['execute']('forward'===_0x5b8021?'showNextChange':'showPreviousChange');}),_0x1401de;}),_0x3e5062['show'](),_0x1bd402['on']('change:isReady',(_0x591db9,_0x30e5b9,_0x5dae62)=>{_0x5dae62?_0x3e5062['hide']():_0x3e5062['show']();});}}class mt extends at{['_resizeObserver']=null;constructor(_0x378277,_0xc5dc67){super(_0x378277,_0xc5dc67);const _0x3737e2=this['bindTemplate'];this['set']({'label':R(_0x378277,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=R(_0x378277,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x3737e2['to']('_tooltipString'),'data-cke-tooltip-position':'s','data-cke-tooltip-class':'ck-tooltip_multi-line'}});}['render'](){super['render'](),this['_resizeObserver']=new pt(this['fieldView']['element'],()=>this['_updateTooltipText']()),this['listenTo'](this['fieldView'],'input',()=>this['_updateTooltipText']());}['destroy'](){super['destroy'](),this['_resizeObserver']&&this['_resizeObserver']['destroy']();}['_updateTooltipText'](){const _0x158f49=this['fieldView']['element'];this['_tooltipString']=_0x158f49['scrollWidth']>_0x158f49['clientWidth']&&_0x158f49['value']||'';}}class ti extends _0x52b1f5{constructor(_0x41036d,_0x11786a,_0x185399){super(_0x41036d);const _0x135f48=new _0xd7ed67();_0x135f48['set']({'content':'<svg\x20viewBox=\x220\x200\x2011\x2010\x22\x20xmlns=\x22http://www.w3.org/2000/svg\x22\x20xmlns:xlink=\x22http://www.w3.org/1999/xlink\x22><path\x20d=\x22M5.5\x205C8.538\x205\x2011\x207.015\x2011\x209.5c0\x20.17-.011.336-.034.5H.034A3.732\x203.732\x200\x200\x201\x200\x209.5C0\x207.015\x202.462\x205\x205.5\x205zm0-5a2.5\x202.5\x200\x201\x201\x200\x205\x202.5\x202.5\x200\x200\x201\x200-5z\x22\x20/></svg>\x0a','viewBox':'0\x200\x2011\x2010'});const _0xf1658c=['ck','ck-revision-history-sidebar__revision-author'];_0x185399&&_0xf1658c['push']('ck-revision-history-sidebar__revision-author_creator');const _0x3f76de=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':R(_0x41036d,_0x185399?'Revision\x20creator':'Revision\x20author')},'children':[_0x135f48,_0x11786a['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0xf1658c},'children':_0x3f76de});}}function ni(_0x163aaf,_0x5c3b05){const _0x413089=_0x163aaf['bindTemplate'],_0x2738f0=_0x163aaf['locale'],_0x214e82=_0x119c84(_0x2738f0);_0x214e82['panelPosition']='sw';const _0x3b185e=function(_0x456ac1,_0x2ed563){const _0x385a45=function(_0x42a52d,_0x136173){const _0x71ed5c=_0x42a52d['locale'],_0x122f78={'Compare\x20against\x20selected':R(_0x71ed5c,'Compare\x20against\x20selected'),'Name\x20this\x20revision':R(_0x71ed5c,'Name\x20this\x20revision'),'Restore\x20this\x20revision':R(_0x71ed5c,'Restore\x20this\x20revision')};return _0x136173['map'](_0x46dcc3=>{const _0x492631=_0x122f78[_0x46dcc3['name']];return _0x492631&&_0x492631!==_0x46dcc3['name']&&(_0x46dcc3['name']=_0x492631),_0x46dcc3;});}(_0x456ac1,_0x2ed563),_0x11337e=new _0x55c105();for(const _0x420363 of _0x385a45){const _0x4f4d2e={'type':'button','model':new to({'label':_0x420363['name'],'class':_0x420363['class'],'withText':!0x0,'role':'menuitem','_action':_0x420363['action']})};_0x4f4d2e['model']['bind']('isEnabled')['to'](_0x456ac1,'isActionsDropdownOpen',_0x2cb735=>'function'!=typeof _0x420363['isEnabled']||(!_0x2cb735||_0x420363['isEnabled'](_0x456ac1))),_0x11337e['add'](_0x4f4d2e);}return _0x11337e;}(_0x163aaf,_0x5c3b05);return _0x163aaf['bind']('isActionsDropdownOpen')['to'](_0x214e82,'isOpen'),_0x214e82['buttonView']['set']({'label':R(_0x2738f0,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x535503['threeVerticalDots']}),_0x214e82['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x413089['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x413089['to'](_0x56737f=>_0x56737f['stopPropagation']())}}),_0x214e82['on']('execute',_0x599ccf=>{_0x163aaf['isReady']&&'function'==typeof _0x599ccf['source']['_action']&&_0x599ccf['source']['_action'](_0x163aaf);}),_0x1fc102(_0x214e82,_0x3b185e,{'role':'menu'}),_0x214e82['listenTo'](_0x163aaf,'change:isActionsDropdownOpen',(_0x208ddb,_0x28b73e,_0x4534bc)=>{if(_0x4534bc)for(const _0x29e8e0 of _0x214e82['listView']['items']){const _0x2bfce6=_0x29e8e0['children']['first'],_0x2d46c4=_0x5c3b05['find'](_0xd7d056=>_0xd7d056['action']===_0x2bfce6['_action'])['isVisible'];_0x29e8e0['isVisible']=void 0x0===_0x2d46c4||_0x2d46c4(_0x163aaf);}}),_0x214e82;}class ai extends/* #__PURE__ -- @preserve */
|
|
26
|
-
|
|
23
|
+
import{ObservableMixin as _0x2a484b,uid as _0x437679,Collection as _0x43ea08,logWarning as _0x5045c0,FocusTracker as _0x4c45ee,KeystrokeHandler as _0x527f19,scrollViewportToShowTarget as _0x322bc2,ResizeObserver as pt,ElementReplacer as ct,CKEditorError as _0x3fbff5}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x34b9d0,set as _0x5b3344,unset as _0x1cd9db,isEqual as _0xe8688e}from'lodash-es';import{Plugin as _0x20db2f,PendingActions as _0x1c2f0c,icons as _0x2f7a5c,Command as _0x1ca2bd,ElementApiMixin as rt,Editor as it}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x38b815,getMarkerDomElement as _0x3d8dbe,ConfirmMixin as _0x4653b3,sanitizeEditorConfig as _0x2391ab}from'ckeditor5-collaboration/dist/index.js';import{ViewDocumentFragment as _0x1e7533,ViewText as _0x2e9e1e,ViewElement as _0x132a21,Element as ft,Range as vt,Position as gt,DocumentFragment as wt,ViewContainerElement as _0x759405,ViewAttributeElement as _0xe3136e,ViewEmptyElement as _0x145ea7,ViewRawElement as _0xc1f4e3,ViewUIElement as _0x3e7f30,Text as _t}from'@ckeditor/ckeditor5-engine/dist/index.js';import{View as _0x4d3579,injectCssTransitionDisabler as ts,submitHandler as _0x58831d,LabeledFieldView as at,createLabeledInputText as _0x551952,createDropdown as _0x1c165d,ListView as te,ListItemView as _0x4dbdfb,ButtonView as _0x4f47da,MenuBarMenuView as _0x443b27,MenuBarMenuListView as _0x1470b3,MenuBarMenuListItemView as _0x7785ec,MenuBarMenuListItemButtonView as _0x3d1deb,ContextualBalloon as _0x1984f6,ToolbarSeparatorView as _0x1baf29,IconView as _0x50f711,addListToDropdown as _0x244218,ViewModel as to,EditorUI as ot,normalizeToolbarConfig as ht,BoxedEditorUIView as dt,StickyPanelView as lt,ToolbarView as nt,InlineEditableUIView as ut}from'@ckeditor/ckeditor5-ui/dist/index.js';import{DateTime as _0x7e7791}from'luxon';class a extends/* #__PURE__ -- @preserve */
|
|
24
|
+
_0x2a484b(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x57cdb4){super(),this['id']=_0x57cdb4['id']||_0x437679(),this['creator']=_0x57cdb4['creator']||null,this['authors']=_0x57cdb4['authors']||[],this['diffData']=_0x57cdb4['diffData']||null,this['toVersion']=_0x57cdb4['toVersion']||0x0,this['fromVersion']=_0x57cdb4['fromVersion']||0x0,this['set']('name',_0x57cdb4['name']||''),this['set']('createdAt',_0x57cdb4['createdAt']||new Date()),this['set']('attributes',_0x57cdb4['attributes']||{});}['setName'](_0x4e33cb){this['_update']({'name':_0x4e33cb});}['setAttribute'](_0x5f0459,_0x4cd43d){const _0x71aa66=_0x34b9d0(this['attributes']);_0x5b3344(_0x71aa66,_0x5f0459,_0x4cd43d),this['_update']({'attributes':_0x71aa66});}['removeAttribute'](_0x59d388){const _0x6bde41=_0x34b9d0(this['attributes']);_0x1cd9db(_0x6bde41,_0x59d388),this['_update']({'attributes':_0x6bde41});}['_update'](_0x34ec27,_0x5019e7=!0x1){let _0x308b42=!0x1;const _0x30352e={'id':this['id']},_0x64d58f=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0xaced62 of _0x64d58f){const _0xe1c070=_0x34ec27[_0xaced62];void 0x0!==_0xe1c070&&_0xe1c070!==this[_0xaced62]&&(this[_0xaced62]=_0xe1c070,_0x30352e[_0xaced62]=_0xe1c070,_0x308b42=!0x0);}_0x308b42&&(_0x30352e['authors']&&(_0x30352e['authorsIds']=_0x30352e['authors']['map'](_0x1d432c=>_0x1d432c['id']),delete _0x30352e['authors']),this['fire']('_update',_0x30352e,_0x5019e7));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x4ebca3=>_0x4ebca3['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class j extends _0x20db2f{['_revisions'];static get['requires'](){return[_0x38b815];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x31cfd2){super(_0x31cfd2),this['_revisions']=new _0x43ea08();}['afterInit'](){!async function(_0x12f0db){const _0x282774=_0x415f12([0x54,0x69,0x33,0x4e,0x6c,0x42,0x56,0x58,0x73,0x52,0x79,0x49,0x30,0x5a,0x67,0x32,0x45,0x75,0x70,0x35,0x72,0x6d,0x64,0x71,0x57,0x6e,0x37,0x50,0x31,0x4b,0x46,0x6b,0x4c,0x36,0x4f,0x4d,0x55,0x63,0x78,0x74,0x53,0x41,0x6a,0x6f,0x48,0x4a,0x66,0x68,0x44,0x51,0x43,0x34,0x7a,0x77,0x39,0x61,0x38,0x65,0x47,0x62,0x76,0x59]),_0x735180=0xeb829,_0xb67940=0x47951379,_0x5207f1=0x479248c1^_0xb67940,_0x22b328=window[_0x415f12([0x44,0x61,0x74,0x65])][_0x415f12([0x6e,0x6f,0x77])](),_0x4f993a=_0x12f0db[_0x415f12([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x29d4a6=new window[(_0x415f12([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x12e4d3=>{_0x4f993a[_0x415f12([0x6f,0x6e,0x63,0x65])](_0x415f12([0x72,0x65,0x61,0x64,0x79]),_0x12e4d3);}),_0x42dc9f={[_0x415f12([0x6b,0x74,0x79])]:_0x415f12([0x45,0x43]),[_0x415f12([0x75,0x73,0x65])]:_0x415f12([0x73,0x69,0x67]),[_0x415f12([0x63,0x72,0x76])]:_0x415f12([0x50,0x2d,0x32,0x35,0x36]),[_0x415f12([0x78])]:_0x415f12([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]),[_0x415f12([0x79])]:_0x415f12([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]),[_0x415f12([0x61,0x6c,0x67])]:_0x415f12([0x45,0x53,0x32,0x35,0x36])},_0x26d3db=_0x4f993a[_0x415f12([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x415f12([0x67,0x65,0x74])](_0x415f12([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x4f7bcf(){let _0x86d369,_0x578c54=null,_0x14a1d6=null;try{if(_0x26d3db==_0x415f12([0x47,0x50,0x4c]))return _0x415f12([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x86d369=_0x47f322(),!_0x86d369)return _0x415f12([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x86d369[_0x415f12([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x14a1d6=_0x70fca2(_0x86d369[_0x415f12([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x86d369[_0x415f12([0x6a,0x74,0x69])])),await _0x3dd098()?_0x211232()?_0x7eb4()?_0x415f12([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x20e42b()?(_0x86d369[_0x415f12([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x415f12([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x578c54=_0x4e1e45(_0x415f12([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x86d369[_0x415f12([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x415f12([0x74,0x72,0x69,0x61,0x6c])&&(_0x578c54=_0x4e1e45(_0x415f12([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),_0x86d369[_0x415f12([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x415f12([0x64,0x65,0x76,0x65,0x6c,0x6f,0x70,0x6d,0x65,0x6e,0x74])&&(_0x578c54=_0x4e1e45(_0x415f12([0x44,0x65,0x76,0x65,0x6c,0x6f,0x70,0x6d,0x65,0x6e,0x74,0x4c,0x69,0x6d,0x69,0x74]))),await _0xae7bc()):_0x415f12([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x415f12([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x415f12([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch(_0x2ee337){return _0x415f12([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x7eb4(){const _0x131f14=[_0x415f12([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x415f12([0x74,0x72,0x69,0x61,0x6c])][_0x415f12([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x86d369[_0x415f12([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x22b328/0x3e8:0xe10*_0x5207f1;return _0x86d369[_0x415f12([0x65,0x78,0x70])]<_0x131f14;}function _0x211232(){const _0x2da3ba=_0x86d369[_0x415f12([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x2da3ba)return!0x1;if(_0x2da3ba[_0x415f12([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x415f12([0x2a])))return!0x0;if(_0x2da3ba[_0x415f12([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x415f12([0x52,0x48])))return!0x0;if(_0x2da3ba[_0x415f12([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x415f12([0x52,0x52,0x48]))){if(_0x40e11e())return!0x0;if(_0x2e6154()||_0x17f5ab())return!0x0;}return!0x1;}function _0x20e42b(){const _0x59b2c3=_0x86d369[_0x415f12([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x59b2c3||0x0==_0x59b2c3[_0x415f12([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x2797f9}=new URL(window[_0x415f12([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x59b2c3[_0x415f12([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x2797f9))return!0x0;const _0xe9136b=_0x2797f9[_0x415f12([0x73,0x70,0x6c,0x69,0x74])](_0x415f12([0x2e]));return _0x59b2c3[_0x415f12([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x37ad65=>_0x37ad65[_0x415f12([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x415f12([0x2a])))[_0x415f12([0x6d,0x61,0x70])](_0x4e95d0=>_0x4e95d0[_0x415f12([0x73,0x70,0x6c,0x69,0x74])](_0x415f12([0x2e])))[_0x415f12([0x73,0x6f,0x6d,0x65])](_0x476581=>_0xe9136b[_0x415f12([0x65,0x76,0x65,0x72,0x79])]((_0x2bacb7,_0x149bec)=>_0x476581[_0x149bec]===_0x2bacb7||_0x476581[_0x149bec]===_0x415f12([0x2a])));}function _0xae7bc(){return _0x578c54&&_0x14a1d6?new window[(_0x415f12([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x1d10e2,_0x336131)=>{_0x578c54[_0x415f12([0x74,0x68,0x65,0x6e])](_0x1d10e2,_0x336131),_0x14a1d6[_0x415f12([0x74,0x68,0x65,0x6e])](_0x43b88e=>{_0x43b88e!=_0x415f12([0x56,0x61,0x6c,0x69,0x64])&&_0x1d10e2(_0x43b88e);},_0x336131);}):_0x578c54||_0x14a1d6||_0x415f12([0x56,0x61,0x6c,0x69,0x64]);}}function _0x70fca2(_0x354df6,_0x5ec200){return new window[(_0x415f12([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x1a3308=>{if(_0x3f4d77())return _0x1a3308(_0x415f12([0x56,0x61,0x6c,0x69,0x64]));_0x158cb6(),_0x4f993a[_0x415f12([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x415f12([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x206a1c=!0x1;const _0x36dee8=_0x437679();function _0x823d73(_0x420432){return!!_0x420432&&(typeof _0x420432===_0x415f12([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x420432===_0x415f12([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x420432[_0x415f12([0x74,0x68,0x65,0x6e])]===_0x415f12([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x420432[_0x415f12([0x63,0x61,0x74,0x63,0x68])]===_0x415f12([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x296355(_0x472339){_0x517676(_0x472339)[_0x415f12([0x74,0x68,0x65,0x6e])](_0x59f883=>{if(!_0x59f883||_0x59f883[_0x415f12([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x415f12([0x6f,0x6b]))return _0x415f12([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x1c74ad(_0x577471(_0x36dee8+_0x5ec200))!=_0x59f883[_0x415f12([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x415f12([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x415f12([0x56,0x61,0x6c,0x69,0x64]);})[_0x415f12([0x74,0x68,0x65,0x6e])](_0x2eb5b8=>(_0x5d2c02(),_0x2eb5b8),()=>{const _0x3bbce8=_0x5b5541();return null==_0x3bbce8?(_0x5d2c02(),_0x415f12([0x56,0x61,0x6c,0x69,0x64])):_0x415f12(_0x22b328-_0x3bbce8>(0x63999779^_0xb67940)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x415f12([0x74,0x68,0x65,0x6e])](_0x1a3308)[_0x415f12([0x63,0x61,0x74,0x63,0x68])](()=>{_0x1a3308(_0x415f12([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x375dc3=0x47a3fdf9^_0xb67940;function _0x5d2c02(){const _0x48c836=_0x415f12([0x6c,0x6c,0x63,0x74,0x2d])+_0x1c74ad(_0x577471(_0x354df6)),_0x27d004=_0x5c41f7(_0x1c74ad(window[_0x415f12([0x4d,0x61,0x74,0x68])][_0x415f12([0x63,0x65,0x69,0x6c])](_0x22b328/_0x375dc3)));window[_0x415f12([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x415f12([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x48c836,_0x27d004);}function _0x5b5541(){const _0x469c48=_0x415f12([0x6c,0x6c,0x63,0x74,0x2d])+_0x1c74ad(_0x577471(_0x354df6)),_0x34d35c=window[_0x415f12([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x415f12([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x469c48);return _0x34d35c?window[_0x415f12([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x5c41f7(_0x34d35c),0x10)*_0x375dc3:null;}function _0x517676(_0x1cf6ed){return new window[(_0x415f12([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0xa8e4a8,_0x9f6312)=>{_0x1cf6ed[_0x415f12([0x74,0x68,0x65,0x6e])](_0xa8e4a8,_0x9f6312),window[_0x415f12([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x9f6312,0x4794c7b9^_0xb67940);});}}_0x4f993a[_0x415f12([0x6f,0x6e])](_0x415f12([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x28d074,_0x4c14af)=>{if(_0x4c14af[0x0]!=_0x354df6)return _0x1a3308(_0x415f12([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x4c14af[0x1]={..._0x4c14af[0x1],[_0x415f12([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x36dee8};},{[_0x415f12([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x415f12([0x68,0x69,0x67,0x68])}),_0x4f993a[_0x415f12([0x6f,0x6e])](_0x415f12([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0xd25838=>{_0x823d73(_0xd25838[_0x415f12([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x206a1c=!0x0,_0x296355(_0xd25838[_0x415f12([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x415f12([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x415f12([0x6c,0x6f,0x77])}),_0x29d4a6[_0x415f12([0x74,0x68,0x65,0x6e])](()=>{_0x206a1c||_0x1a3308(_0x415f12([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x3f4d77(){return _0x4f993a[_0x415f12([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x415f12([0x76,0x69,0x65,0x77])][_0x415f12([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x415f12([0x61,0x75,0x74,0x6f]);}function _0x158cb6(){_0x4f993a[_0x415f12([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x415f12([0x76,0x69,0x65,0x77])][_0x415f12([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x415f12([0x61,0x75,0x74,0x6f]);}}function _0x4e1e45(_0x5007f0){const _0x5bd28f=[new window[(_0x415f12([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2e8578=>setTimeout(_0x2e8578,0x479c2db5^_0xb67940)),_0x29d4a6[_0x415f12([0x74,0x68,0x65,0x6e])](()=>new window[(_0x415f12([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x12368e=>{const _0xa74187=0x4795137e^_0xb67940,_0x16fa40=_0x12f0db[_0x415f12([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x42d458(){_0x16fa40[_0x415f12([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0xa74187&&_0x12368e();}_0x42d458(),_0x16fa40[_0x415f12([0x6f,0x6e])](_0x415f12([0x61,0x64,0x64]),_0x42d458);})),new window[(_0x415f12([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x38d332=>{function _0x42454e(){for(const _0x45d5ba in window)if(window[_0x415f12([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x415f12([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x45d5ba))&&window[_0x45d5ba]==_0x735180)return _0x38d332();_0x4f993a[_0x415f12([0x73,0x74,0x61,0x74,0x65])]!=_0x415f12([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x415f12([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x42454e,0x479500f1^_0xb67940);}_0x546a67(_0x415f12([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x42454e();})];return window[_0x415f12([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x415f12([0x72,0x61,0x63,0x65])](_0x5bd28f)[_0x415f12([0x74,0x68,0x65,0x6e])](()=>_0x5007f0);}async function _0x4f3ef5(){if(await _0x29d4a6,_0x546a67(_0x415f12([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x2715c0=_0x12f0db[_0x415f12([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x3f051c=_0x12f0db[_0x415f12([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])](_0x2715c0[_0x415f12([0x69,0x64])]),_0x54ead7=_0x19e7a1(_0x415f12([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x54ead7[_0x415f12([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x2715c0['id'],_0x3f051c?_0x3f051c['id']:null,!0x0),_0x54ead7[_0x415f12([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x415f12([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x54ead7[_0x415f12([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x54ead7[_0x415f12([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x4d6002,void(_0x54ead7[_0x415f12([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x4d6002);}if(_0x546a67(_0x415f12([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x57b13b=_0x19e7a1(_0x415f12([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x57b13b[_0x415f12([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x415f12([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x57b13b[_0x415f12([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x57b13b[_0x415f12([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x4d6002,_0x57b13b[_0x415f12([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x4d6002;}_0x4f993a[_0x415f12([0x6d,0x6f,0x64,0x65,0x6c])][_0x415f12([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x4d6002,_0x4f993a[_0x415f12([0x6d,0x6f,0x64,0x65,0x6c])][_0x415f12([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x4d6002,_0x4f993a[_0x415f12([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x415f12([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x40e11e(){return _0x546a67(_0x415f12([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x19e7a1(_0x415f12([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x415f12([0x73,0x74,0x61,0x74,0x65])]==_0x415f12([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x2e6154(){return _0x546a67(_0x415f12([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 _0x17f5ab(){return _0x546a67(_0x415f12([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0xfe7dd4(_0x14a952){const _0x251388=_0x98ecc7();_0x4f993a[_0x251388]=_0x415f12([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])+_0x14a952,_0x14a952[_0x415f12([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x415f12([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x98ecc7()]=_0x735180),_0x14a952!=_0x415f12([0x56,0x61,0x6c,0x69,0x64])&&_0x4f3ef5();}function _0x98ecc7(){const _0x285938=window[_0x415f12([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x415f12([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x415f12([0x6e,0x6f,0x77])]())[_0x415f12([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x415f12([0x2e]),'');let _0x1343bf=_0x415f12([0x54]);for(let _0x2bb778=0x0;_0x2bb778<_0x285938[_0x415f12([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x2bb778+=0x2){let _0x1f5fd2=window[_0x415f12([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x285938[_0x415f12([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x2bb778,_0x2bb778+0x2));_0x1f5fd2>=_0x282774[_0x415f12([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x1f5fd2-=_0x282774[_0x415f12([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x1343bf+=_0x282774[_0x1f5fd2];}return _0x1343bf;}function _0x47f322(){const _0x2a5c76=_0x26d3db[_0x415f12([0x73,0x70,0x6c,0x69,0x74])](_0x415f12([0x2e]));if(0x3!=_0x2a5c76[_0x415f12([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x4cb9b0(_0x2a5c76[0x1]);function _0x4cb9b0(_0x4891f0){const _0x1cfe91=_0x1c8c48(_0x4891f0);return _0x1cfe91&&_0x1af713()?_0x1cfe91:null;function _0x1af713(){const _0x15cd6f=_0x1cfe91[_0x415f12([0x6a,0x74,0x69])],_0x55d256=window[_0x415f12([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x15cd6f[_0x415f12([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x15cd6f[_0x415f12([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x4affe6={..._0x1cfe91,[_0x415f12([0x6a,0x74,0x69])]:_0x15cd6f[_0x415f12([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x15cd6f[_0x415f12([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x4affe6[_0x415f12([0x76,0x63])],_0x577471(_0x4affe6)==_0x55d256;}}}async function _0x3dd098(){let _0xf84ba7=!0x0;try{const _0x35e2ca=_0x26d3db[_0x415f12([0x73,0x70,0x6c,0x69,0x74])](_0x415f12([0x2e])),[_0x1a8ae9,_0x411b08,_0x5af526]=_0x35e2ca;return _0x28d2a5(_0x1a8ae9),await _0x27bfa1(_0x1a8ae9,_0x411b08,_0x5af526),_0xf84ba7;}catch(_0x27ce07){return!0x1;}function _0x28d2a5(_0x5ceb75){const _0x190041=_0x1c8c48(_0x5ceb75);_0x190041&&_0x190041[_0x415f12([0x61,0x6c,0x67])]==_0x415f12([0x45,0x53,0x32,0x35,0x36])||(_0xf84ba7=!0x1);}async function _0x27bfa1(_0x437252,_0x1307ec,_0x158936){const _0x1bdf0f=window[_0x415f12([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x415f12([0x66,0x72,0x6f,0x6d])](_0x1689bc(_0x158936),_0xe61d39=>_0xe61d39[_0x415f12([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x43582b=new window[(_0x415f12([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x415f12([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x437252+_0x415f12([0x2e])+_0x1307ec),_0x13fa3d=window[_0x415f12([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x415f12([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x13fa3d)return;const _0x37233f=await _0x13fa3d[_0x415f12([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x415f12([0x6a,0x77,0x6b]),_0x42dc9f,{[_0x415f12([0x6e,0x61,0x6d,0x65])]:_0x415f12([0x45,0x43,0x44,0x53,0x41]),[_0x415f12([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x415f12([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x415f12([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x13fa3d[_0x415f12([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x415f12([0x6e,0x61,0x6d,0x65])]:_0x415f12([0x45,0x43,0x44,0x53,0x41]),[_0x415f12([0x68,0x61,0x73,0x68])]:{[_0x415f12([0x6e,0x61,0x6d,0x65])]:_0x415f12([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x37233f,_0x1bdf0f,_0x43582b)||(_0xf84ba7=!0x1);}}function _0x1c8c48(_0x9e9fd0){return _0x9e9fd0[_0x415f12([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x415f12([0x65,0x79]))?JSON[_0x415f12([0x70,0x61,0x72,0x73,0x65])](_0x1689bc(_0x9e9fd0)):null;}function _0x1689bc(_0x5cd2ec){return window[_0x415f12([0x61,0x74,0x6f,0x62])](_0x5cd2ec[_0x415f12([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x415f12([0x2b]))[_0x415f12([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x415f12([0x2f])));}function _0x577471(_0x199200){let _0x4dfd9f=0x1505;function _0x30cda3(_0x222ab2){for(let _0x23873d=0x0;_0x23873d<_0x222ab2[_0x415f12([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x23873d++){const _0x7540e3=_0x222ab2[_0x415f12([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x23873d);_0x4dfd9f=(_0x4dfd9f<<0x5)+_0x4dfd9f+_0x7540e3,_0x4dfd9f&=_0x4dfd9f;}}function _0x57cb3c(_0x47e951){Array[_0x415f12([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x47e951)?_0x47e951[_0x415f12([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x57cb3c):_0x47e951&&typeof _0x47e951==_0x415f12([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x415f12([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x47e951)[_0x415f12([0x73,0x6f,0x72,0x74])]()[_0x415f12([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x50f3fa,_0x37fa53])=>{_0x30cda3(_0x50f3fa),_0x57cb3c(_0x37fa53);}):_0x30cda3(window[_0x415f12([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x47e951));}return _0x57cb3c(_0x199200),_0x4dfd9f>>>0x0;}function _0x1c74ad(_0x5887f6){return _0x5887f6[_0x415f12([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x415f12([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x415f12([0x30]));}function _0x5c41f7(_0x440ced){return _0x440ced[_0x415f12([0x73,0x70,0x6c,0x69,0x74])]('')[_0x415f12([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x415f12([0x6a,0x6f,0x69,0x6e])]('');}function _0x546a67(_0x104703){return _0x4f993a[_0x415f12([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x415f12([0x68,0x61,0x73])](_0x104703);}function _0x19e7a1(_0x2676e6){return _0x4f993a[_0x415f12([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x415f12([0x67,0x65,0x74])](_0x2676e6);}function _0x4d6002(){}function _0x415f12(_0xaeca4){return _0xaeca4['map'](_0x5a495e=>String['fromCharCode'](_0x5a495e))['join']('');}_0xfe7dd4(await _0x4f7bcf());}(this);}['createRevision'](_0x99173){const _0x2ce98e=this['editor']['plugins']['get']('Users');return new a({'id':_0x99173['id'],'name':_0x99173['name'],'creator':_0x99173['creatorId']?_0x2ce98e['getUser'](_0x99173['creatorId']):null,'diffData':_0x99173['diffData']||_0x99173['data'],'authors':_0x99173['authorsIds']['map'](_0x459ac5=>_0x2ce98e['getUser'](_0x459ac5)),'createdAt':new Date(_0x99173['createdAt']),'attributes':_0x99173['attributes'],'fromVersion':_0x99173['fromVersion'],'toVersion':_0x99173['toVersion']});}['addRevision'](_0x1e01e7,_0x24b66e=0x0){this['_revisions']['add'](_0x1e01e7,_0x24b66e);}['getRevision'](_0x15f794){return this['_revisions']['get'](_0x15f794);}['getRevisions'](_0x2a81e1={'toJSON':!0x1}){const _0x458dc7=Array['from'](this['_revisions']);return _0x458dc7['reverse'](),_0x2a81e1['toJSON']?_0x458dc7['map'](_0x318bda=>_0x318bda['toJSON']()):_0x458dc7;}['getIndex'](_0x249d80){return this['_revisions']['getIndex'](_0x249d80);}['getEarlierVisibleRevision'](_0x1edca6){const [,_0x534545]=this['getRevisionsIterator'](_0x1edca6,{'direction':'earlier'});return _0x534545;}['getLaterVisibleRevision'](_0x6ae9e){const [,_0x4230f6]=this['getRevisionsIterator'](_0x6ae9e,{'direction':'later'});return _0x4230f6;}['getRevisionsInDiff'](_0x5def8a){const _0x3717bd=[];for(const _0x2e60a3 of this['getRevisionsIterator'](_0x5def8a['newRevisionId']))if(_0x3717bd['push'](_0x2e60a3),_0x2e60a3['id']===_0x5def8a['oldRevisionId'])break;return _0x3717bd;}*['getRevisionsIterator'](_0x4fd967,{direction:_0x4c8dca='earlier',filter:_0x1dd10c=()=>!0x0}={}){const _0x47aabd='earlier'===_0x4c8dca?0x1:-0x1;let _0xcc7579=this['_revisions']['get'](_0x4fd967),_0x4751a8=this['getIndex'](_0xcc7579);for(yield _0xcc7579;_0xcc7579;){if(_0x4751a8+=_0x47aabd,_0xcc7579=this['getRevision'](_0x4751a8),!_0xcc7579)return;_0x1dd10c(_0xcc7579)&&(yield _0xcc7579);}}}function R(_0x46f92c,_0x3dea39,_0x14b339){const t=_0x46f92c['t'];switch(_0x3dea39){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'},_0x14b339);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x14b339);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'';}}const C={'c':_0x759405,'a':_0xe3136e,'e':_0x145ea7,'r':_0xc1f4e3,'u':_0x3e7f30};class l extends _0x20db2f{['licenseKey'];['_licenseKeyCheckInterval'];['adapter'];['currentRevision'];['repository'];['_revisionDataBuilder'];['_source'];['_initialRevisionId'];['_bufferedUpdates'];['_pendingAction'];['_continueCurrentRevision'];['_startingVersion'];['_loadedStateData'];static get['pluginName'](){return'RevisionTracker';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[_0x38b815,j,_0x1c2f0c];}constructor(_0x59c096){super(_0x59c096),this['adapter']=null,this['currentRevision']=null,this['_revisionDataBuilder']=new T(this['editor']),this['_initialRevisionId']=this['editor']['config']['get']('collaboration.channelId')||'initial',this['_bufferedUpdates']=new Map(),this['_loadedStateData']=null;const _0x2499cb=_0x437679();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x2499cb},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['repository']=this['editor']['plugins']['get']('RevisionsRepository'),this['_setConversion'](),this['editor']['data']['on']('ready',()=>{const _0x3c8d20=this['repository']['getRevision'](0x0),_0x516c4f=_0x3c8d20&&null===_0x3c8d20['creator']?_0x3c8d20:null;if(this['_continueCurrentRevision']=!!_0x516c4f&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x220145=this['_source']['getCurrentRevisionId'](),_0x27798b=this['repository']['getRevision'](_0x220145);if(_0x27798b)this['_startingVersion']=_0x27798b['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x545688=this['_source']['history']['_operations']['find'](_0x372fa6=>!_0x372fa6['_isInit']),_0x360a28=_0x545688?_0x545688['baseVersion']:this['_source']['history']['version'];_0x3c8d20?(_0x3c8d20['toVersion']<_0x360a28&&_0x3c8d20['_update']({'toVersion':_0x360a28}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x516c4f['id'],this['_startingVersion']=_0x516c4f['fromVersion']):(this['_startingVersion']=_0x3c8d20['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x360a28,this['_continueCurrentRevision']=!0x1);}}else _0x516c4f&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x516c4f['toVersion'],this['editor']['model']['document']['history']['version']),_0x516c4f['fromVersion']===_0x516c4f['toVersion']?(0x0!==_0x516c4f['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x516c4f['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x516c4f['id'],this['_startingVersion']=_0x516c4f['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',_0x24e59d=>!_0x24e59d),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x175771=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x478be4;for(const _0x1e1939 in _0x175771){const _0x441a39=_0x1e1939,_0x521f09=_0x175771[_0x441a39];if('revisionHistoryLicenseKeyValid'==_0x521f09||'revisionHistoryLicenseKeyInvalid'==_0x521f09||'revisionHistoryLicenseKeyExpired'==_0x521f09||'revisionHistoryLicenseKeyDomainLimit'==_0x521f09||'revisionHistoryLicenseKeyNotAllowed'==_0x521f09||'revisionHistoryLicenseKeyEvaluationLimit'==_0x521f09||'revisionHistoryLicenseKeyTrialLimit'==_0x521f09||'revisionHistoryLicenseKeyDevelopmentLimit'==_0x521f09||'revisionHistoryLicenseKeyUsageLimit'==_0x521f09){delete _0x175771[_0x441a39],_0x478be4=_0x521f09,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x478be4&&_0x175771['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x478be4&&_0x175771['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x478be4&&_0x175771['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x478be4&&_0x175771['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x478be4&&_0x175771['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x478be4&&_0x175771['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyDevelopmentLimit'==_0x478be4&&_0x175771['_showLicenseError']('developmentLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x478be4&&_0x175771['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x135a49=this['repository']['getRevision'](0x0),_0x65850d=await this['getRevisionDocumentData'](_0x135a49),_0x529c3d=await this['getRevisionRootsAttributes'](_0x135a49);this['_replaceEditorDataWithRevisionData'](_0x65850d,_0x529c3d);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x441cbf){this['_source']=_0x441cbf;}async['update'](){const _0x5e4aa7=await this['_source']['getLatestVersion']();if(_0x5e4aa7>this['currentRevision']['toVersion']){await this['_loadState']();const _0x544b85=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x5e4aa7});_0x544b85['authors']=_0x544b85['authorsIds']['map'](_0x2b7f0f=>this['editor']['plugins']['get']('Users')['getUser'](_0x2b7f0f)),this['currentRevision']['_update'](_0x544b85);}}async['_loadState'](){this['_continueCurrentRevision']&&!this['_loadedStateData']&&(await this['_loadRevisionData'](this['currentRevision']),this['_revisionDataBuilder']['loadState'](this['currentRevision']),this['_loadedStateData']={'fromVersion':this['currentRevision']['fromVersion'],'authors':this['currentRevision']['authors']['slice']()});}async['saveRevision'](_0x317934={},_0x7b5b62=null){const _0x152f26=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x7b5b62>this['currentRevision']['toVersion']&&(_0x7b5b62=null),null===_0x7b5b62&&(_0x7b5b62=await this['_source']['getLatestVersion']());const _0x490cf9=this['_getFromVersion'](_0x7b5b62),_0x43a4a9=this['buildRevisionData']({'from':_0x490cf9,'to':_0x7b5b62});if(this['currentRevision']['toVersion']<_0x7b5b62){const _0xbf4d5e=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x7b5b62,'to':_0x7b5b62});_0xbf4d5e['authors']=[],_0xbf4d5e['authorsIds']=[],_0xbf4d5e['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0xbf4d5e,!0x0),delete _0xbf4d5e['authors'],_0x152f26['push'](_0xbf4d5e);}_0x317934['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x317934['name']=_0x317934['name']||null,_0x317934['id']=_0x317934['id']||_0x437679(),_0x317934={..._0x317934,..._0x43a4a9};const _0x4b77b4=this['addRevisionData'](_0x317934);_0x152f26['push'](_0x317934);const _0x26925b=this['repository']['getIndex'](_0x4b77b4);if(0x0!==_0x26925b){const _0x3976a2=this['repository']['getRevision'](_0x26925b-0x1);if(_0x3976a2['fromVersion']!==_0x7b5b62){const _0x199b2d=this['_revisionDataBuilder']['getData'](_0x7b5b62,_0x3976a2['toVersion']),_0x499c45={'id':_0x3976a2['id'],'diffData':_0x199b2d['diffData'],'authorsIds':_0x199b2d['authorsIds'],'authors':_0x199b2d['authorsIds']['map'](_0x3af9e6=>this['editor']['plugins']['get']('Users')['getUser'](_0x3af9e6)),'fromVersion':_0x7b5b62};_0x3976a2===this['currentRevision']&&(_0x499c45['createdAt']=new Date(_0x317934['createdAt']['getTime']()+0xa)),_0x3976a2['_update'](_0x499c45,!0x0),delete _0x499c45['authors'],_0x152f26['push'](_0x499c45);}}if(this['adapter']){for(const _0x55fd5f of _0x152f26)this['_bufferUpdate'](_0x55fd5f['id'],_0x55fd5f,!0x0);this['sendBufferedUpdates']();}return _0x4b77b4;}['addRevisionData'](_0x43ec10){const _0x40d517=this['repository']['createRevision'](_0x43ec10);return this['adapter']&&_0x40d517['on']('_update',(_0x4d68fc,_0xc4866c,_0x578664)=>{_0x578664||(this['_bufferUpdate'](_0xc4866c['id'],_0xc4866c,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x40d517,this['_findInsertionIndex'](_0x40d517)),_0x40d517;}async['getRevisionDocumentData'](_0x444f10){await this['_loadRevisionData'](_0x444f10);const _0x5d72f8={};for(const _0x21bbb3 in _0x444f10['diffData']){if(_0x444f10['diffData'][_0x21bbb3]['attachChange']&&!_0x444f10['diffData'][_0x21bbb3]['attachChange']['isAttached'])continue;const _0x51d240=this['_removeRevisionMarkers'](JSON['parse'](_0x444f10['diffData'][_0x21bbb3]['insertions'])),_0x35d33f=this['editor']['editing']['view']['document'],_0x1bb23a=new _0x1e7533(_0x35d33f,_0x51d240['map'](_0x364bef=>V(_0x364bef,this['editor'])));this['editor']['data']['processor']['useFillerType']('marked'),_0x5d72f8[_0x21bbb3]=this['editor']['data']['processor']['toData'](_0x1bb23a),this['editor']['data']['processor']['useFillerType']('default');}return _0x5d72f8;}async['getRevisionRootsAttributes'](_0x39e3cc){await this['_loadRevisionData'](_0x39e3cc);const _0xc482c7={};for(const _0x29986b in _0x39e3cc['diffData'])_0x39e3cc['diffData'][_0x29986b]['attachChange']&&!_0x39e3cc['diffData'][_0x29986b]['attachChange']['isAttached']||(_0xc482c7[_0x29986b]=_0x39e3cc['diffData'][_0x29986b]['attributesAfter']||{});return _0xc482c7;}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x5ea7f7=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x674368=0x0;_0x674368<_0x5ea7f7['length'];_0x674368++){const _0x536c04=_0x5ea7f7[_0x674368];let _0x43a454=!0x1;for(const _0x5e4d9f of Object['keys'](_0x536c04))void 0x0===_0x536c04[_0x5e4d9f]?delete _0x536c04[_0x5e4d9f]:'id'!==_0x5e4d9f&&(_0x43a454=!0x0);_0x43a454||(_0x5ea7f7[_0x674368]=null);}if(_0x5ea7f7=_0x5ea7f7['filter'](_0x1e5cb2=>null!==_0x1e5cb2),!_0x5ea7f7['length'])return;for(let _0x371d3d=0x0;_0x371d3d<_0x5ea7f7['length'];_0x371d3d++){const _0x1ae616=_0x5ea7f7[_0x371d3d];void 0x0!==_0x1ae616['fromVersion']&&void 0x0===_0x1ae616['toVersion']&&(_0x1ae616['toVersion']=this['repository']['getRevision'](_0x1ae616['id'])['toVersion']),void 0x0!==_0x1ae616['toVersion']&&void 0x0===_0x1ae616['fromVersion']&&(_0x1ae616['fromVersion']=this['repository']['getRevision'](_0x1ae616['id'])['fromVersion']);}const _0x11646c=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x5ea7f7,_0x11646c)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0xb9fc2c=>{if(_0xb9fc2c){for(const _0x1671d4 of _0xb9fc2c)this['setRevisionData']({'id':_0x1671d4['id'],'createdAt':_0x1671d4['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['_replaceEditorDataWithRevisionData'](_0x43c353,_0x60b269){let _0x6389b9=this['editor']['config']['get']('initialData'),_0x4a81fb=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x6389b9){_0x6389b9={};for(const _0x1642eb of this['editor']['model']['document']['getRootNames']())_0x6389b9[_0x1642eb]='';}if('string'==typeof _0x6389b9&&(_0x6389b9={'main':_0x6389b9}),void 0x0===_0x4a81fb){_0x4a81fb={};for(const _0x48490d of this['editor']['model']['document']['getRootNames']())_0x4a81fb[_0x48490d]={};}let _0x5da829=!0x1;const _0xbd249d=Object['keys'](_0x6389b9),_0x5a8313=Object['keys'](_0x43c353);for(const _0x1e1723 of _0xbd249d){if(_0x6389b9[_0x1e1723]!==_0x43c353[_0x1e1723]&&''!==_0x6389b9[_0x1e1723]['trim']()){_0x5da829=!0x0;break;}if(!_0xe8688e(_0x4a81fb[_0x1e1723],_0x60b269[_0x1e1723])&&Object['keys'](_0x4a81fb[_0x1e1723])['length']>0x0){_0x5da829=!0x0;break;}}_0x5da829||(_0x5da829=_0x5a8313['some'](_0x4203b6=>!this['editor']['model']['document']['getRoot'](_0x4203b6))),_0x5da829&&_0x5045c0('editor-initial-data-replaced-with-revision-data',{'editorData':_0x6389b9,'editorRootsAttributes':_0x4a81fb,'revisionData':_0x43c353,'revisionRootsAttributes':_0x60b269}),this['editor']['config']['set']('initialData',_0x43c353),this['editor']['config']['set']('rootsAttributes',_0x60b269);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x2067ae=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x2067ae['add'](R(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x726fdd){const _0x3e49ad=this['repository']['getRevisions']();_0x3e49ad['reverse']();let _0x486027=0x0;for(;_0x486027<_0x3e49ad['length'];){const _0x48cd96=_0x3e49ad[_0x486027];if(_0x48cd96===this['currentRevision']){_0x486027++;continue;}if(_0x48cd96['id']===this['_initialRevisionId'])break;const _0x1fecab=_0x726fdd['toVersion']-_0x48cd96['toVersion']||_0x726fdd['fromVersion']-_0x48cd96['fromVersion'];if(_0x1fecab>0x0)break;if(_0x1fecab<0x0)_0x486027++;else{if(!_0x726fdd['creator']&&_0x48cd96['creator'])break;if(_0x48cd96['creator']||!_0x726fdd['creator']){if(_0x726fdd['createdAt']>_0x48cd96['createdAt'])break;_0x486027++;}else _0x486027++;}}return _0x486027;}['setRevisionData'](_0x555e1c){const _0x39a2c7=this['repository']['getRevision'](_0x555e1c['id']);if(_0x555e1c['createdAt']&&(_0x555e1c['createdAt']=new Date(_0x555e1c['createdAt'])),_0x555e1c['authorsIds']){const _0x39c39a=this['editor']['plugins']['get']('Users');_0x555e1c['authors']=_0x555e1c['authorsIds']['map'](_0x22685f=>_0x39c39a['getUser'](_0x22685f));}_0x39a2c7['_update'](_0x555e1c,!0x0);}['buildRevisionData']({revision:_0x391a5f=null,from:_0x1147b1=null,to:_0x18f8ee=null}){_0x1147b1=null!==_0x1147b1?_0x1147b1:_0x391a5f['fromVersion'],_0x18f8ee=null!==_0x18f8ee?_0x18f8ee:_0x391a5f['toVersion'];const _0x1da799=this['_revisionDataBuilder']['getData'](_0x1147b1,_0x18f8ee),_0x2312be={'diffData':_0x1da799['diffData'],'authorsIds':_0x1da799['authorsIds'],'fromVersion':_0x1147b1,'toVersion':_0x18f8ee};if(!_0x391a5f||_0x18f8ee!==_0x391a5f['toVersion']){const _0x104bae=_0x18f8ee-0x1,_0x1d004e=this['_source']['history']['getOperation'](_0x104bae);_0x2312be['createdAt']=_0x1d004e&&_0x1d004e['createdAt']||new Date();}if(this['_loadedStateData']&&_0x1147b1===this['_loadedStateData']['fromVersion']){for(const _0x27793b of this['_loadedStateData']['authors'])_0x2312be['authorsIds']['includes'](_0x27793b['id'])||_0x2312be['authorsIds']['push'](_0x27793b['id']);}return _0x2312be;}['_loadRevisionData'](_0x15c40f){if(!_0x15c40f||_0x15c40f['diffData'])return Promise['resolve']();{const _0x51049d=this['editor']['config']['get']('collaboration.channelId');return this['adapter']['getRevision']({'channelId':_0x51049d,'revisionId':_0x15c40f['id']})['then'](_0x323034=>{_0x15c40f['diffData']=_0x323034['diffData'];});}}['_bufferUpdate'](_0x9ce4f1,_0x350add,_0x59a00f){if(this['_bufferedUpdates']['has'](_0x9ce4f1)){const _0x4e6164=this['_bufferedUpdates']['get'](_0x9ce4f1);_0x350add=_0x59a00f?{..._0x4e6164,..._0x350add}:{..._0x350add,..._0x4e6164};}this['_bufferedUpdates']['set'](_0x9ce4f1,_0x350add);}['_getFromVersion'](_0x5ab04d){const _0x3b9f6e=this['repository']['getRevisions']();_0x3b9f6e['reverse'](),_0x3b9f6e['shift']();const _0x586be1=_0x3b9f6e['find'](_0x53d155=>_0x53d155['toVersion']<=_0x5ab04d)['toVersion'];return _0x586be1<this['_startingVersion']?this['_startingVersion']:_0x586be1;}['_createInitialRevision'](_0x4b3f69){const _0x2d673d=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x2d673d)this['_initialRevisionId']=_0x2d673d['id'];else{const _0x157260=!this['editor']['model']['document']['roots']['find'](_0x108964=>this['editor']['model']['hasContent'](_0x108964)),_0xdd281f=this['editor']['plugins']['get']('Users')['me']['id'],_0x46d59a=R(this['editor']['locale'],_0x157260?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x4b3f69,'to':_0x4b3f69,'id':this['_initialRevisionId'],'name':_0x46d59a,'creatorId':_0xdd281f});}}['_createCurrentRevision'](_0x56d18f){const _0x4f71da=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x4f71da),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x56d18f,'to':_0x56d18f,'id':_0x4f71da,'name':'','creatorId':null}));}['_makeRevision']({name:_0x4c9a84,from:_0x5c0feb,to:_0x30bcd4,creatorId:_0x511212,id:_0x52f272}){const _0x5dd51c=this['buildRevisionData']({'from':_0x5c0feb,'to':_0x30bcd4});_0x5dd51c['name']=_0x4c9a84,_0x5dd51c['creatorId']=_0x511212,_0x5dd51c['id']=_0x52f272;const _0x17f7a2=this['addRevisionData'](_0x5dd51c);return this['adapter']&&this['_bufferUpdate'](_0x5dd51c['id'],_0x5dd51c,!0x0),_0x17f7a2;}['_setConversion'](){this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'});}['_removeRevisionMarkers'](_0x40d9cf){return(_0x40d9cf=_0x40d9cf['filter'](_0x5c1c63=>!_0x5c1c63['name']||'revision-start'!==_0x5c1c63['name']&&'revision-end'!==_0x5c1c63['name']))['forEach'](_0xd7fc9=>{'string'!=typeof _0xd7fc9&&(_0xd7fc9['children']=this['_removeRevisionMarkers'](_0xd7fc9['children']),_0xd7fc9['attributes']=_0xd7fc9['attributes']['filter'](_0xfbe1c7=>!_0xfbe1c7[0x0]['startsWith']('data-revision-')));}),_0x40d9cf;}}function V(_0x4bd9a9,_0x1214a2){const _0x207cd2=_0x1214a2['editing']['view']['document'];if('string'==typeof _0x4bd9a9)return new _0x2e9e1e(_0x207cd2,_0x4bd9a9);{const _0x18c193=_0x4bd9a9['children']['map'](_0x1cdab2=>V(_0x1cdab2,_0x1214a2));return new(C[_0x4bd9a9['type']]||_0x132a21)(_0x207cd2,_0x4bd9a9['name'],_0x4bd9a9['attributes'],_0x18c193);}}class T{['editor'];['source'];['_savedMetaData'];['_lastFrom'];['_lastTo'];['_markers'];['_diffRoots'];['_diffRootsAttributes'];['_baseRoots'];['_baseRootsAttributes'];['_idsRoots'];['_baseIdsRoots'];['_touched'];['_touchedMarkers'];['_touchedRoots'];['_revisionId'];['_startingRevisionId'];constructor(_0x170667){this['editor']=_0x170667,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'](_0x32d834){this['source']=_0x32d834;const _0x3b1a6f=new Map(),_0x3d4368=new Map(),_0x1e7d6f=this['editor']['model']['document']['roots']['map'](_0x2d88fb=>_0x2d88fb['rootName']);for(const _0x3161ba of _0x1e7d6f){const _0x3b4a71=this['editor']['model']['document']['getRoot'](_0x3161ba),_0x1f7a8e=F(_0x3b4a71);_0x3b1a6f['set'](_0x3161ba,_0x1f7a8e),_0x3d4368['set'](_0x3161ba,Object['fromEntries'](_0x3b4a71['getAttributes']()));}const _0xd122ea=Array['from'](this['editor']['model']['markers'])['map'](_0x5252d1=>[_0x5252d1['name'],_0x5252d1['getRange']()]),_0x5b794c=this['source']['version'];this['_saveMetaData'](_0x5b794c,_0x3b1a6f,_0xd122ea,_0x3d4368),this['_startingRevisionId']=this['_revisionId'];const _0x5ef153=new Map(),_0x363caa=new Map();for(const _0x50a4d1 of _0x1e7d6f){const _0x2e1592=B(_0x50a4d1);_0x5ef153['set'](_0x50a4d1,_0x2e1592),_0x363caa['set'](_0x50a4d1,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x5ef153,[],_0x363caa);}['getData'](_0x38d320,_0x1db872){if(this['_lastFrom']===_0x38d320&&this['_lastTo']<=_0x1db872)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x1db872,!0x0);else{if(!this['_savedMetaData']['has'](_0x38d320)){const _0x58a059=this['_getPreviousFrom'](_0x38d320);this['_calculateMetaData'](_0x58a059,_0x38d320,!0x1);}this['_calculateMetaData'](_0x38d320,_0x1db872,!0x0);}return this['_lastFrom']=_0x38d320,this['_lastTo']=_0x1db872,this['_getState']();}['loadState'](_0x31f772){this['_reset'](),this['_lastFrom']=_0x31f772['fromVersion'],this['_lastTo']=_0x31f772['toVersion'];for(const _0x4072fa in _0x31f772['diffData']){const _0x5ab5c0=_0x31f772['diffData'][_0x4072fa]['attachChange'],_0x285eea=_0x34b9d0(_0x31f772['diffData'][_0x4072fa]['attributesBefore'])||{},_0x2b4aaf=this['_makeModelFromViewString'](_0x31f772['diffData'][_0x4072fa]['deletions']);_0x2b4aaf['rootName']=_0x4072fa,_0x2b4aaf['_isAttached']=!_0x5ab5c0||!_0x5ab5c0['isAttached'],_0x2b4aaf['isAttached']=()=>_0x2b4aaf['_isAttached'],this['_baseRoots']['set'](_0x4072fa,_0x2b4aaf),this['_baseRootsAttributes']['set'](_0x4072fa,_0x285eea),_0x5ab5c0&&this['_touchedRoots']['set'](_0x4072fa,_0x5ab5c0);const _0x563788=this['_makeIdsRoot'](_0x2b4aaf);this['_baseIdsRoots']['set'](_0x4072fa,_0x563788);for(const [_0x374bde,_0x2ab6a6]of _0x2b4aaf['markers']){if(!_0x374bde['startsWith']('revision:'))continue;const _0x24ec3d=_0x374bde['split'](':')[0x2];for(const _0x29162f of _0x2ab6a6['getWalker']({'singleCharacters':!0x0})){const _0xe631c6=this['_getVidAttributeName'](_0x29162f),_0x295bfb='elementEnd'==_0x29162f['type']?_0x29162f['previousPosition']['path']['slice'](0x0,-0x1):_0x29162f['previousPosition']['path'],_0x191351=_0x563788['getNodeByPath'](_0x295bfb)['getAttribute'](_0xe631c6);this['_touched']['set'](_0x191351,{'userId':_0x24ec3d});}}}this['_startingRevisionId']=this['_revisionId'];const _0x2e9169=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x4d5fd3=>!this['_touched']['has'](_0x4d5fd3));let _0x493532=0x0;const _0x4e9a8f=new Map();for(const _0xfa0990 in _0x31f772['diffData']){const _0x2c561e=_0x31f772['diffData'][_0xfa0990]['attachChange'],_0x101cb5=_0x34b9d0(_0x31f772['diffData'][_0xfa0990]['attributesAfter'])||{},_0x24f578=this['_makeModelFromViewString'](_0x31f772['diffData'][_0xfa0990]['insertions']);_0x24f578['rootName']=_0xfa0990,_0x24f578['_isAttached']=!_0x2c561e||_0x2c561e['isAttached'],_0x24f578['isAttached']=()=>_0x24f578['_isAttached'],this['_diffRoots']['set'](_0xfa0990,_0x24f578),this['_diffRootsAttributes']['set'](_0xfa0990,_0x101cb5);const _0x25000c=this['_makeIdsRoot'](_0x24f578,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0xfa0990,_0x25000c),_0x4e9a8f['set'](_0xfa0990,_0x24f578['isAttached']()?_0x101cb5:{});for(const [_0x36d8ed,_0x1f1640]of _0x24f578['markers']){if(!_0x36d8ed['startsWith']('revision:'))continue;const _0x15637d=_0x36d8ed['split'](':')[0x2];for(const _0x1bfaf2 of _0x1f1640['getWalker']({'singleCharacters':!0x0})){const _0x7eb006=this['_getVidAttributeName'](_0x1bfaf2),_0x25623c=this['_revisionId']++,_0x5852ff='elementEnd'==_0x1bfaf2['type']?_0x1bfaf2['previousPosition']['path']['slice'](0x0,-0x1):_0x1bfaf2['previousPosition']['path'];_0x25000c['getNodeByPath'](_0x5852ff)['_setAttribute'](_0x7eb006,_0x25623c),this['_touched']['set'](_0x25623c,{'userId':_0x15637d});}}for(const _0x4d9f55 of this['editor']['model']['createRangeIn'](_0x24f578)['getWalker']({'singleCharacters':!0x0})){const _0xb4d28a=this['_getVidAttributeName'](_0x4d9f55),_0x5aa676='elementEnd'==_0x4d9f55['type']?_0x4d9f55['previousPosition']['path']['slice'](0x0,-0x1):_0x4d9f55['previousPosition']['path'],_0x22bb9d=_0x25000c['getNodeByPath'](_0x5aa676);_0x22bb9d['getAttribute'](_0xb4d28a)>0x0||_0x22bb9d['_setAttribute'](_0xb4d28a,_0x2e9169[_0x493532++]);}for(const [_0x5d05e6,_0x27c28a]of _0x24f578['markers'])_0x5d05e6['startsWith']('revision:')||this['_markers']['set'](_0x5d05e6,_0x27c28a);}const _0x17d405=B('$graveyard');this['_baseRoots']['set']('$graveyard',_0x17d405),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x17d405,0x1));const _0x49994a=B('$graveyard');this['_diffRoots']['set']('$graveyard',_0x49994a),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x49994a,0x1));const _0x4e11d3=Array['from'](this['_diffRoots'])['map'](([_0x7c4314,_0x257cbf])=>[_0x7c4314,F(_0x257cbf)]);this['_saveMetaData'](this['_lastTo'],_0x4e11d3,this['_markers'],_0x4e9a8f);}['_makeModelFromViewString'](_0x7e45ea){const _0xa40bd7=JSON['parse'](_0x7e45ea),_0x1f9444=this['editor']['editing']['view']['document'],_0x2e0a47=new _0x1e7533(_0x1f9444,_0xa40bd7['map'](_0x1dcc22=>V(_0x1dcc22,this['editor'])));return this['editor']['data']['toModel'](_0x2e0a47);}['_saveMetaData'](_0x1e3f06,_0x17a850,_0x104377,_0x15cc11){const _0x10bb2e=new Map(_0x17a850),_0x265371=new Map(_0x34b9d0(_0x15cc11)),_0x5ed2b6=new Map();for(const [_0x4e22f6,_0x1e6e59]of _0x104377)_0x5ed2b6['set'](_0x4e22f6,{'start':_0x1e6e59['start']['clone'](),'end':_0x1e6e59['end']['clone'](),'rootName':_0x1e6e59['root']['rootName']});this['_savedMetaData']['set'](_0x1e3f06,{'roots':_0x10bb2e,'markers':_0x5ed2b6,'rootsAttributes':_0x265371});}['_removeMetaData'](_0x527d5e){this['_savedMetaData']['delete'](_0x527d5e);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_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'](_0x4cc729,_0x13c32c=null){let _0x457de3=null;_0x4cc729['is']('documentFragment')||(_0x457de3=new ft(_0x4cc729['name'],{'vid_start':null===_0x13c32c?this['_revisionId']++:_0x13c32c++}));const _0x767422=[];for(const _0x5db456 of _0x4cc729['getChildren']())if(_0x5db456['is']('element')){_0x767422['push'](this['_makeIdsRoot'](_0x5db456,_0x13c32c));const _0xca8559=_0x767422[_0x767422['length']-0x1];null!==_0x13c32c&&(_0x13c32c=_0xca8559['is']('element','$text')?_0xca8559['getAttribute']('vid')+0x1:_0xca8559['getAttribute']('vid_end')+0x1);}else{for(let _0x283186=0x0;_0x283186<_0x5db456['offsetSize'];_0x283186++)_0x767422['push'](new ft('$text',{'vid':null===_0x13c32c?this['_revisionId']++:_0x13c32c++}));}if(_0x4cc729['is']('documentFragment')){const _0x10c23c=B(_0x4cc729['rootName']);return _0x10c23c['_insertChild'](0x0,_0x767422),_0x10c23c;}return _0x457de3['_setAttribute']('vid_end',null===_0x13c32c?this['_revisionId']++:_0x13c32c++),_0x457de3['_insertChild'](0x0,_0x767422),_0x457de3;}['_calculateMetaData'](_0x439938,_0x210d67,_0x2eb191){this['_reset']();const {roots:_0x1eb725,markers:_0x1d4bdf,rootsAttributes:_0x5046cc}=this['_savedMetaData']['get'](_0x439938);this['_baseRoots']=new Map(_0x1eb725),this['_baseRootsAttributes']=new Map(_0x34b9d0(_0x5046cc));for(const [_0x1051df,_0x235166]of this['_baseRoots'])if('$graveyard'!==_0x1051df&&(this['_diffRoots']['set'](_0x1051df,F(_0x235166)),this['_diffRootsAttributes']=new Map(_0x34b9d0(_0x5046cc)),_0x2eb191)){const _0x43f00d=this['_revisionId'];this['_idsRoots']['set'](_0x1051df,this['_makeIdsRoot'](_0x235166)),this['_baseIdsRoots']['set'](_0x1051df,this['_makeIdsRoot'](_0x235166,_0x43f00d));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',F(this['_baseRoots']['get']('$graveyard'))),_0x2eb191&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x2976fa,_0x128c89]of _0x1d4bdf){const _0x3436ed=this['_baseRoots']['get'](_0x128c89['rootName']),_0x4d8ff4=this['_diffRoots']['get'](_0x128c89['rootName']),_0x5a57f4=new vt(this['_fixPosition'](_0x128c89['start'],_0x3436ed),this['_fixPosition'](_0x128c89['end'],_0x3436ed)),_0x5742b7=this['_fixRange'](_0x5a57f4,_0x4d8ff4);_0x3436ed['markers']['set'](_0x2976fa,_0x5a57f4),this['_markers']['set'](_0x2976fa,_0x5742b7);}this['_applyOperations'](_0x439938,_0x210d67,_0x2eb191);}['_applyOperations'](_0x1beb74,_0x45519f,_0x16ed10){for(const _0x9a410f of this['source']['getOperations'](_0x1beb74,_0x45519f))this['_handleOperation'](_0x9a410f,_0x16ed10);for(const _0x15cd83 of this['_diffRoots']['values']())_0x15cd83['markers']['clear']();for(const [_0x311a3a,_0x4be84f]of this['_markers']){this['_diffRoots']['get'](_0x4be84f['root']['rootName'])['markers']['set'](_0x311a3a,_0x4be84f['clone']());}const _0x4dd5fc=new Map(),_0x3d12cd=new Map();for(const [_0x107723,_0x26cc54]of this['_diffRoots'])_0x4dd5fc['set'](_0x107723,F(_0x26cc54)),_0x3d12cd['set'](_0x107723,this['_diffRootsAttributes']['get'](_0x107723));this['_saveMetaData'](_0x45519f,_0x4dd5fc,this['_markers'],_0x3d12cd);}['_getPreviousFrom'](_0xd20eba){const _0x281a6a=Array['from'](this['_savedMetaData']['keys']());_0x281a6a['sort']((_0x3fba87,_0x1a17ab)=>_0x3fba87-_0x1a17ab),_0x281a6a['reverse']();for(const _0x22b853 of _0x281a6a)if(_0x22b853<_0xd20eba)return _0x22b853;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0xe1687a,_0x5e1787){const _0xe6fa3d=Array['from'](_0x5e1787['markers'])['map'](([_0x49091f,_0x58b40f])=>[_0x49091f,this['_fixRange'](_0x58b40f,_0xe1687a)]);_0xe1687a['markers']=new Map(_0xe6fa3d);}['_transformMarkers'](_0xe62d1b){for(const _0x1bd14b of this['_markers']['values']()){const _0x150148=_0x1bd14b['getTransformedByOperation'](_0xe62d1b),_0x14ba4a=vt['_createFromRanges'](_0x150148);_0x1bd14b['start']=_0x14ba4a['start'],_0x1bd14b['end']=_0x14ba4a['end'];}}['_handleOperation'](_0x2b2cfe,_0x1892c4){if('addRoot'!=_0x2b2cfe['type']&&'detachRoot'!=_0x2b2cfe['type']){if('insert'==_0x2b2cfe['type']){const _0x347d90=_0x2b2cfe['position']['root']['rootName'];this['_diffRoots']['has'](_0x347d90)||(this['_diffRoots']['set'](_0x347d90,B(_0x347d90,!0x0)),this['_diffRootsAttributes']['set'](_0x347d90,{}),_0x1892c4&&this['_idsRoots']['set'](_0x347d90,B(_0x347d90,!0x0)));}else{if('addRootAttribute'==_0x2b2cfe['type']||'removeRootAttribute'==_0x2b2cfe['type']||'changeRootAttribute'==_0x2b2cfe['type'])return void this['_handleRootAttributeOperation'](_0x2b2cfe);'marker'==_0x2b2cfe['type']&&this['_handleMarkerOperation'](_0x2b2cfe);}if('marker'!==_0x2b2cfe['type']){const _0xce0ad1=this['_cloneOperation'](_0x2b2cfe,this['_diffRoots']);_0xce0ad1['_execute'](),this['_transformMarkers'](_0xce0ad1);}if(_0x1892c4)switch(_0x2b2cfe['type']){case'insert':this['_handleInsertOperation'](_0x2b2cfe);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x2b2cfe);break;case'merge':this['_handleMergeOperation'](_0x2b2cfe);break;case'split':this['_handleSplitOperation'](_0x2b2cfe);}}else this['_handleRootOperation'](_0x2b2cfe,_0x1892c4);}['_cloneOperation'](_0x3451fa,_0x45736d){const _0x56170f=_0x3451fa['clone']();return _0x56170f['_authorId']=_0x3451fa['_authorId'],this['_fixOperation'](_0x56170f,_0x45736d),_0x56170f;}['_getBaseVids'](_0x12b8e2){return _0x12b8e2['map'](_0x373b18=>{const _0x91268e=this['_getVidAttributeName'](_0x373b18);return Number(_0x373b18['item']['getAttribute'](_0x91268e));});}['_generateTape'](_0x17e93b,_0x362a22){if(_0x17e93b['is']('element','$text'))_0x362a22['push']({'item':_0x17e93b,'type':'text'});else{_0x17e93b['is']('element')&&_0x362a22['push']({'item':_0x17e93b,'type':'elementStart'});for(const _0x151e1b of _0x17e93b['getChildren']())this['_generateTape'](_0x151e1b,_0x362a22);_0x17e93b['is']('element')&&_0x362a22['push']({'item':_0x17e93b,'type':'elementEnd'});}return _0x362a22;}['_getState'](){const _0x5830fb=new Map(this['_touched']),_0x406731=new Map(_0x5830fb),_0x523a85=new Map(),_0x1db25c={'insertions':{},'deletions':{}},_0x53fc08={'insertions':{},'deletions':{}},_0x3a2669=new Map(),_0x10d2aa=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x10d2aa['delete']('$graveyard');for(const _0x1864c0 of _0x10d2aa){const _0x232f93=this['_diffRoots']['get'](_0x1864c0)||B(_0x1864c0,!0x1),_0x47ba86=this['_baseRoots']['get'](_0x1864c0)||B(_0x1864c0,!0x1);_0x232f93['isAttached']()||_0x47ba86['isAttached']()?(_0x1db25c['insertions'][_0x1864c0]=F(_0x232f93),_0x1db25c['deletions'][_0x1864c0]=F(_0x47ba86),this['_copyMarkers'](_0x1db25c['deletions'][_0x1864c0],_0x47ba86),this['_copyMarkers'](_0x1db25c['insertions'][_0x1864c0],_0x232f93),_0x53fc08['insertions'][_0x1864c0]=this['_generateTape'](this['_idsRoots']['get'](_0x1864c0),[]),_0x53fc08['deletions'][_0x1864c0]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x1864c0)||B(_0x1864c0,!0x1),[])):_0x10d2aa['delete'](_0x1864c0);}for(const _0x5a29d3 of _0x10d2aa){const _0x572518=_0x53fc08['insertions'][_0x5a29d3];for(const _0x46f280 of _0x572518){const _0x2689db=this['_getVidAttributeName'](_0x46f280),_0x3a4d11=_0x46f280['item']['getAttribute'](_0x2689db);_0x406731['delete'](_0x3a4d11),_0x3a4d11>=this['_startingRevisionId']&&_0x523a85['set'](_0x3a4d11,_0x5830fb['get'](_0x3a4d11));}}for(const _0x3ce127 of _0x10d2aa){const _0x59fb9d=_0x53fc08['insertions'][_0x3ce127],_0x1d7139=this['_getBaseVids'](_0x53fc08['deletions'][_0x3ce127]);let _0x46a237=0x0;for(const _0x437b32 of _0x59fb9d){const _0x10075f=this['_getVidAttributeName'](_0x437b32),_0x4df5c9=_0x437b32['item']['getAttribute'](_0x10075f);if(!_0x523a85['has'](_0x4df5c9)&&!_0x3a2669['has'](_0x4df5c9)){if(_0x406731['has'](_0x4df5c9))_0x46a237++;else{if(_0x4df5c9!=_0x1d7139[_0x46a237]){const _0x7a37ce=_0x5830fb['get'](_0x4df5c9)||_0x5830fb['get'](_0x1d7139[_0x46a237]);for(;_0x4df5c9!=_0x1d7139[_0x46a237];)_0x406731['has'](_0x1d7139[_0x46a237])||(_0x3a2669['set'](_0x1d7139[_0x46a237],_0x7a37ce),_0x5830fb['set'](_0x1d7139[_0x46a237],_0x7a37ce)),_0x46a237++;}_0x46a237++;}}}}for(const _0x8a1c7 of _0x10d2aa){const _0x4e4477=_0x53fc08['insertions'][_0x8a1c7];for(const _0x33ea61 of _0x4e4477){const _0x239e81=this['_getVidAttributeName'](_0x33ea61),_0x312dea=_0x33ea61['item']['getAttribute'](_0x239e81);if(_0x3a2669['has'](_0x312dea)){const _0x54ca19=_0x3a2669['get'](_0x312dea);_0x406731['has'](_0x312dea)||_0x406731['set'](_0x312dea,{..._0x54ca19}),_0x523a85['set'](_0x312dea,{..._0x54ca19});}}}for(const _0x5eeaf3 of _0x406731['keys']())_0x5eeaf3>=this['_startingRevisionId']&&_0x406731['delete'](_0x5eeaf3);const _0x427453=new Map();for(const _0x3673a1 of _0x10d2aa){let _0x1b15f7=_0x53fc08['insertions'][_0x3673a1];for(const _0x52081a of _0x1b15f7)if(_0x52081a['item']['is']('element','tableCell')){const _0x1a69b8=this['_getVidAttributeName'](_0x52081a),_0x5f4d94=_0x52081a['item']['getAttribute'](_0x1a69b8);if(_0x523a85['has'](_0x5f4d94)){const _0x49ebf2=_0x52081a['item']['parent']['parent']['getAttribute']('vid_start'),_0x492e90=_0x427453['get'](_0x49ebf2)||new Set();_0x492e90['add'](_0x523a85['get'](_0x5f4d94)['userId']),_0x427453['set'](_0x49ebf2,_0x492e90);}}_0x1b15f7=_0x53fc08['deletions'][_0x3673a1];for(const _0x5509ef of _0x1b15f7)if(_0x5509ef['item']['is']('element','tableCell')){const _0x172ca6=this['_getVidAttributeName'](_0x5509ef),_0x3522f1=_0x5509ef['item']['getAttribute'](_0x172ca6);if(_0x406731['has'](_0x3522f1)){const _0x1d9860=_0x5509ef['item']['parent']['parent']['getAttribute']('vid_start'),_0x446592=_0x427453['get'](_0x1d9860)||new Set();_0x446592['add'](_0x406731['get'](_0x3522f1)['userId']),_0x427453['set'](_0x1d9860,_0x446592);}}for(const _0xb8daf5 of _0x427453['keys']())(_0x523a85['has'](_0xb8daf5)||_0x406731['has'](_0xb8daf5))&&_0x427453['delete'](_0xb8daf5);}for(const _0x47ac4b of _0x10d2aa){const _0x414ac4=_0x53fc08['insertions'][_0x47ac4b];let _0x42c48a=null,_0x5b6c6b=null;for(const _0xc73f0b of _0x414ac4){const _0x53163b=this['_getVidAttributeName'](_0xc73f0b),_0x391807=_0xc73f0b['item']['getAttribute'](_0x53163b),_0x36e1bb=_0x427453['get'](_0x391807);_0x36e1bb&&'elementStart'==_0xc73f0b['type']&&(_0x42c48a=Array['from'](_0x36e1bb)[0x0],_0x5b6c6b=_0xc73f0b['item']['getAttribute']('vid_end')),_0x42c48a&&(_0x406731['set'](_0x391807,{'userId':_0x42c48a}),_0x523a85['set'](_0x391807,{'userId':_0x42c48a})),_0x391807==_0x5b6c6b&&(_0x42c48a=null,_0x5b6c6b=null);}}const _0x59c14e={},_0x512b9c=new Set();for(const _0x47dcc7 of _0x10d2aa){const _0x1d372a=_0x1db25c['deletions'][_0x47dcc7],_0x4bb726=_0x1db25c['insertions'][_0x47dcc7];for(const {userId:_0x550d3e}of this['_touchedMarkers']['values']())null!==_0x550d3e&&_0x512b9c['add'](_0x550d3e);for(const {userId:_0x5417a5}of this['_touchedRoots']['values']())null!==_0x5417a5&&_0x512b9c['add'](_0x5417a5);this['_markChanges'](_0x4bb726,_0x53fc08['insertions'][_0x47dcc7],_0x523a85,'insertion',_0x512b9c),this['_markChanges'](_0x1d372a,_0x53fc08['deletions'][_0x47dcc7],_0x406731,'deletion',_0x512b9c),_0x59c14e[_0x47dcc7]={'insertions':this['_prepareViewToSave'](_0x4bb726),'deletions':this['_prepareViewToSave'](_0x1d372a),'attachChange':this['_touchedRoots']['get'](_0x47dcc7)||null,'attributesBefore':_0x34b9d0(this['_baseRootsAttributes']['get'](_0x47dcc7))||{},'attributesAfter':_0x34b9d0(this['_diffRootsAttributes']['get'](_0x47dcc7))};}return{'diffData':_0x59c14e,'authorsIds':Array['from'](_0x512b9c)};}['_processRootBeforeSave'](_0x1e8ace){for(const [,_0x338658]of _0x1e8ace['markers']){const _0x4e7e04=_0x338658['start']['getAncestors']()['filter'](_0x522ed5=>'tableCell'==_0x522ed5['name']);for(const _0x2e1b21 of _0x4e7e04)0x1==_0x2e1b21['childCount']&&_0x2e1b21['getChild'](0x0)['is']('element','paragraph')&&_0x2e1b21['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x5c7c0c){this['_processRootBeforeSave'](_0x5c7c0c);const _0x23940e=this['editor']['data']['toView'](_0x5c7c0c,{}),_0x1128a7=Array['from'](_0x23940e['getChildren']())['map'](_0x6e45e3=>this['_getViewJson'](_0x6e45e3));return JSON['stringify'](_0x1128a7);}['_getViewJson'](_0x2505b5){if(_0x2505b5['is']('$text'))return _0x2505b5['data'];{const _0x1e8503=_0x2505b5;return{'type':Object['keys'](C)['find'](_0x2b0d52=>_0x2505b5 instanceof C[_0x2b0d52]),'name':_0x1e8503['name'],'attributes':Array['from'](_0x1e8503['getAttributes']()),'children':Array['from'](_0x1e8503['getChildren']())['map'](_0x4e1565=>this['_getViewJson'](_0x4e1565))};}}['_markChanges'](_0x442b5c,_0x32881d,_0x48509d,_0x4be2d9,_0x263f64){let _0x499fb0=null,_0x289aba=null,_0x30a008=0x0;const _0x3d37dc=this['editor']['model'];for(let _0x2f0608=0x0;_0x2f0608<_0x32881d['length'];_0x2f0608++){const _0x47e6a0=this['_getVidAttributeName'](_0x32881d[_0x2f0608]),_0x200006=_0x32881d[_0x2f0608]['item']['getAttribute'](_0x47e6a0),_0x3576b1=_0x48509d['get'](_0x200006),_0x341c2e=_0x2f0608==_0x32881d['length']-0x1;(!_0x499fb0&&_0x3576b1&&(_0x499fb0=_0x3576b1,_0x289aba=_0x32881d[_0x2f0608]),_0x499fb0&&(!_0x3576b1||_0x3576b1['userId']!=_0x499fb0['userId']))&&(_0x3e3d48(_0x3576b1,J(_0x289aba,_0x442b5c,_0x3d37dc),J(_0x32881d[_0x2f0608],_0x442b5c,_0x3d37dc)),_0x499fb0=_0x3576b1||null,_0x289aba=_0x3576b1?_0x32881d[_0x2f0608]:null),_0x499fb0&&_0x341c2e&&_0x3e3d48(_0x3576b1,J(_0x289aba,_0x442b5c,_0x3d37dc),q(_0x32881d[_0x2f0608],_0x442b5c,_0x3d37dc));}function _0x3e3d48(_0x1ac656,_0x4947b1,_0x3d18af){const _0x5809cf=_0x499fb0['userId'],_0x2fb3db='revision:'+_0x4be2d9+':'+_0x5809cf+':'+_0x30a008++,_0x28c396=_0x3d37dc['createRange'](_0x4947b1,_0x3d18af);_0x442b5c['markers']['set'](_0x2fb3db,_0x28c396),null!==_0x5809cf&&_0x263f64['add'](_0x5809cf);}}['_getVidAttributeName'](_0x1e205f){switch(_0x1e205f['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x104638,_0x1e1ae2){_0x104638['baseVersion']=null;for(const _0x3dffe9 in _0x104638){const _0x4b0a41=_0x104638[_0x3dffe9];if(_0x4b0a41 instanceof gt){const _0x52f64e=_0x1e1ae2['get'](_0x4b0a41['root']['rootName']);_0x104638[_0x3dffe9]=this['_fixPosition'](_0x4b0a41,_0x52f64e);}if(_0x4b0a41 instanceof vt){const _0x582fa3=_0x1e1ae2['get'](_0x4b0a41['root']['rootName']);_0x104638[_0x3dffe9]=this['_fixRange'](_0x4b0a41,_0x582fa3);}'root'===_0x3dffe9&&(_0x104638['root']=_0x1e1ae2['get'](_0x104638['root']['rootName']));}}['_fixRange'](_0x35acd6,_0x3c84ca){return this['editor']['model']['createRange'](this['_fixPosition'](_0x35acd6['start'],_0x3c84ca),this['_fixPosition'](_0x35acd6['end'],_0x3c84ca));}['_fixPosition'](_0x2184b4,_0x32b776){return this['editor']['model']['createPositionFromPath'](_0x32b776,_0x2184b4['path'],_0x2184b4['stickiness']);}['_handleInsertOperation'](_0x19dafa){const _0x38f033=this['_idsRoots']['get'](_0x19dafa['position']['root']['rootName']),_0x67bea9=this['_fixPosition'](_0x19dafa['position'],_0x38f033),_0x393bb2=null===_0x19dafa['_authorId']?null:_0x19dafa['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x27c21f=_0x67bea9['parent'],_0x3d93da=this['_revisionId'],_0x57d287=[];for(const _0x504ecb of _0x19dafa['nodes'])if(_0x504ecb['is']('element'))_0x57d287['push'](this['_makeIdsRoot'](_0x504ecb));else{for(let _0x36fa0d=0x0;_0x36fa0d<_0x504ecb['offsetSize'];_0x36fa0d++)_0x57d287['push'](new ft('$text',{'vid':this['_revisionId']++}));}const _0x196334=this['_revisionId'];for(let _0x52af4b=_0x3d93da;_0x52af4b<_0x196334;_0x52af4b++)this['_touched']['set'](_0x52af4b,{'userId':_0x393bb2});_0x27c21f['_insertChild'](_0x67bea9['offset'],_0x57d287);}['_handleMoveOperation'](_0xf75c1d){(_0xf75c1d=this['_cloneOperation'](_0xf75c1d,this['_idsRoots']))['_execute']();const _0x3e45e1=null===_0xf75c1d['_authorId']?null:_0xf75c1d['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x1aac01=_0xf75c1d['getMovedRangeStart'](),_0xdc9044=_0x1aac01['parent'],_0x23f47b=_0x1aac01['offset'];!function _0x4e860d(_0x1ce563,_0x507204,_0x411a47,_0x42f587){for(let _0x390c52=_0x411a47;_0x390c52<_0x42f587;_0x390c52++){const _0x14ea69=_0x507204['getChild'](_0x390c52);_0x14ea69['is']('element','$text')?_0x1ce563['set'](_0x14ea69['getAttribute']('vid'),{'userId':_0x3e45e1}):(_0x1ce563['set'](_0x14ea69['getAttribute']('vid_start'),{'userId':_0x3e45e1}),_0x4e860d(_0x1ce563,_0x14ea69,0x0,_0x14ea69['childCount']),_0x1ce563['set'](_0x14ea69['getAttribute']('vid_end'),{'userId':_0x3e45e1}));}}(this['_touched'],_0xdc9044,_0x23f47b,_0x23f47b+_0xf75c1d['howMany']);}['_handleMergeOperation'](_0x4c2650){const _0x51ca79=null===(_0x4c2650=this['_cloneOperation'](_0x4c2650,this['_idsRoots']))['_authorId']?null:_0x4c2650['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x5907bf=_0x4c2650['targetPosition']['parent'],_0x81f077=_0x4c2650['sourcePosition']['parent'],_0x104e25=_0x5907bf['getAttribute']('vid_end'),_0x18fb4e=_0x81f077['getAttribute']('vid_start');_0x5907bf['_setAttribute']('vid_end',_0x81f077['getAttribute']('vid_end')),_0x81f077['_setAttribute']('vid_end',_0x104e25),this['_touched']['set'](_0x18fb4e,{'userId':_0x51ca79}),this['_touched']['set'](_0x104e25,{'userId':_0x51ca79}),_0x4c2650['_execute']();}['_handleSplitOperation'](_0x2ec011){const _0x19bde8=null===(_0x2ec011=this['_cloneOperation'](_0x2ec011,this['_idsRoots']))['_authorId']?null:_0x2ec011['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x181e14=_0x2ec011['graveyardPosition'],_0x2ae38c=_0x2ec011['splitPosition']['parent'];_0x2ec011['_execute']();const _0x254bdd=_0x2ae38c['getAttribute']('vid_end'),_0x428159=_0x2ec011['insertionPosition']['nodeAfter'];if(_0x181e14){const _0x3d2f5b=_0x428159['getAttribute']('vid_end'),_0x1e1e41=_0x2ae38c['getAttribute']('vid_end');_0x2ae38c['_setAttribute']('vid_end',_0x3d2f5b),_0x428159['_setAttribute']('vid_end',_0x1e1e41),this['_touched']['set'](_0x2ae38c['getAttribute']('vid_end'),{'userId':_0x19bde8}),this['_touched']['set'](_0x428159['getAttribute']('vid_start'),{'userId':_0x19bde8});}else{const _0x4bce47=this['_revisionId']++,_0x107f31=this['_revisionId']++;_0x2ae38c['_setAttribute']('vid_end',_0x4bce47),_0x428159['_setAttribute']('vid_start',_0x107f31),_0x428159['_setAttribute']('vid_end',_0x254bdd),this['_touched']['set'](_0x4bce47,{'userId':_0x19bde8}),this['_touched']['set'](_0x107f31,{'userId':_0x19bde8});}}['_handleMarkerOperation'](_0x456005){if(!_0x456005['affectsData'])return;const _0x360a47=(_0x456005=this['_cloneOperation'](_0x456005,this['_diffRoots']))['oldRange']?_0x456005['oldRange']['root']:null,_0xace1cd=_0x456005['newRange']?_0x456005['newRange']['root']:null;_0x360a47&&this['_markers']['delete'](_0x456005['name']),_0xace1cd&&this['_markers']['set'](_0x456005['name'],_0x456005['newRange']['clone']());const _0x4e2915=null===_0x456005['_authorId']?null:_0x456005['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x5e26ba=_0x456005['name'];if(!this['_touchedMarkers']['has'](_0x5e26ba))return void this['_touchedMarkers']['set'](_0x5e26ba,{'range':_0x456005['oldRange'],'userId':_0x4e2915});const _0x404d16=this['_touchedMarkers']['get'](_0x5e26ba),_0x2c8175=_0x404d16['range'],_0x5a1f45=_0x456005['newRange'];null==_0x2c8175&&null==_0x5a1f45||_0x2c8175&&_0x5a1f45&&_0x2c8175['isEqual'](_0x5a1f45)?this['_touchedMarkers']['delete'](_0x456005['name']):_0x404d16['userId']=_0x4e2915;}['_handleRootOperation'](_0x1466ab,_0xb0d676){this['_diffRoots']['has'](_0x1466ab['rootName'])?this['_diffRoots']['get'](_0x1466ab['rootName'])['_isAttached']=_0x1466ab['isAdd']:(this['_diffRoots']['set'](_0x1466ab['rootName'],B(_0x1466ab['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x1466ab['rootName'],{}),_0xb0d676&&this['_idsRoots']['set'](_0x1466ab['rootName'],B(_0x1466ab['rootName'],!0x0)));const _0x3e5d23=null===_0x1466ab['_authorId']?null:_0x1466ab['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x1a9254=this['_touchedRoots']['get'](_0x1466ab['rootName']);_0x1a9254&&_0x1a9254['userId']===_0x3e5d23?this['_touchedRoots']['delete'](_0x1466ab['rootName']):this['_touchedRoots']['set'](_0x1466ab['rootName'],{'userId':_0x3e5d23,'isAttached':_0x1466ab['isAdd']});}['_handleRootAttributeOperation'](_0x5823c6){const _0x29188e=this['_diffRootsAttributes']['get'](_0x5823c6['root']['rootName']);null===_0x5823c6['newValue']?delete _0x29188e[_0x5823c6['key']]:_0x29188e[_0x5823c6['key']]=_0x5823c6['newValue'];}}function F(_0x4d4a3a){const _0x2e5346=B(_0x4d4a3a['rootName'],_0x4d4a3a['isAttached']());for(const _0x4c3c52 of _0x4d4a3a['getChildren']()){const _0xe0d124=_0x4c3c52['_clone'](!0x0);_0x2e5346['_appendChild'](_0xe0d124);}return _0x2e5346;}function B(_0x296c4f,_0x2182b5=!0x0){const _0x419c7c=new wt();return _0x419c7c['rootName']=_0x296c4f,_0x419c7c['_isAttached']=_0x2182b5,_0x419c7c['isAttached']=()=>_0x419c7c['_isAttached'],_0x419c7c;}function J(_0x4c607e,_0x5ae8e3,_0x3d13c2){const _0x18ac2b='elementEnd'==_0x4c607e['type']?_0x3d13c2['createPositionAt'](_0x4c607e['item'],'end'):_0x3d13c2['createPositionBefore'](_0x4c607e['item']);return _0x3d13c2['createPositionFromPath'](_0x5ae8e3,_0x18ac2b['path'],_0x18ac2b['stickiness']);}function q(_0x3ef122,_0x407496,_0x3a71bb){const _0x276e91='elementStart'==_0x3ef122['type']?_0x3a71bb['createPositionAt'](_0x3ef122['item'],0x0):_0x3a71bb['createPositionAfter'](_0x3ef122['item']);return _0x3a71bb['createPositionFromPath'](_0x407496,_0x276e91['path'],_0x276e91['stickiness']);}class ns extends _0x4d3579{['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0xc13886,_0x540333){super(_0xc13886),this['focusTracker']=new _0x4c45ee(),this['keystrokes']=new _0x527f19(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x540333),this['setTemplate']({'tag':'form','attributes':{'class':['ck','ck-revision-history-save-revision-form','ck-responsive-form'],'tabindex':'-1'},'children':[this['revisionNameInputView']]}),ts(this);}['render'](){super['render'](),_0x58831d({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x14f8c2=_0x236929=>_0x236929['stopPropagation']();this['keystrokes']['set']('arrowright',_0x14f8c2),this['keystrokes']['set']('arrowleft',_0x14f8c2),this['keystrokes']['set']('arrowup',_0x14f8c2),this['keystrokes']['set']('arrowdown',_0x14f8c2);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x445feb){this['revisionNameInputView']['fieldView']['element']['value']=_0x445feb['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x537bd4){const _0x39f49a=new at(this['locale'],_0x551952),_0x48436f=_0x39f49a['fieldView'];_0x48436f['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x485f3c=R(this['locale'],'Name\x20of\x20the\x20revision');return!_0x537bd4&&(_0x485f3c+='\x20('+R(this['locale'],'optional')+')'),(_0x39f49a['label']=_0x485f3c,_0x48436f['on']('input',()=>{this['revisionNameInputValue']=_0x48436f['element']['value']['trim']();}),_0x39f49a);}}class u extends _0x20db2f{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l];}['_saveRevisionFormView'];['init'](){const _0x3dec10=this['editor'],_0x49dee3=_0x3dec10['plugins']['get']('RevisionTracker');_0x3dec10['ui']['componentFactory']['add']('revisionHistory',_0x463be8=>{const _0x482e62=_0x1c165d(_0x463be8),_0x322c36=_0x482e62['panelView']['children'],_0x5ef97f=new te(_0x463be8),_0x5ccc1b=new _0x4dbdfb(_0x463be8),_0x49384=new _0x4f47da(_0x463be8),_0x86171f=new _0x4dbdfb(_0x463be8),_0x46f521=new _0x4f47da(_0x463be8);return _0x482e62['bind']('isEnabled')['to'](_0x49dee3,'isReady',_0x49dee3,'isEnabled',_0x3dec10,'isReadOnly',(_0x402adc,_0x5e3347,_0x25a5d5)=>_0x402adc&&_0x5e3347&&!_0x25a5d5),_0x482e62['buttonView']['set']({'icon':_0x2f7a5c['history'],'label':R(_0x463be8,'Revision\x20history'),'tooltip':!0x0}),_0x49384['set']({'label':R(_0x463be8,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x49384['bind']('isEnabled')['to'](_0x49dee3,'isReady',_0x49dee3,'isEnabled',_0x3dec10,'isReadOnly',(_0x1ccbce,_0x2255e7,_0x8990de)=>_0x1ccbce&&_0x2255e7&&!_0x8990de),_0x49384['on']('execute',()=>this['_showDialog']()),_0x46f521['set']({'label':R(_0x463be8,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x46f521['bind']('isEnabled')['to'](_0x49dee3,'isReady',_0x3dec10,'isReadOnly',(_0x3d6069,_0x30fe62)=>_0x3d6069&&!_0x30fe62),_0x46f521['on']('execute',()=>{_0x3dec10['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x482e62['isOpen']=!0x1,_0x3dec10['editing']['view']['focus']();}),_0x5ccc1b['children']['add'](_0x49384),_0x86171f['children']['add'](_0x46f521),_0x5ef97f['role']='menu',_0x5ef97f['items']['addMany']([_0x5ccc1b,_0x86171f]),_0x322c36['add'](_0x5ef97f),_0x482e62;}),_0x3dec10['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x4ff073=this['editor'],_0x47bcf2=_0x4ff073['locale'],_0x4a9f2a=new _0x443b27(_0x47bcf2),_0x26623a=new _0x1470b3(_0x47bcf2);_0x4a9f2a['buttonView']['set']({'icon':_0x2f7a5c['history'],'label':R(_0x47bcf2,'Revision\x20history')});const _0x441322=new _0x7785ec(_0x47bcf2,_0x4a9f2a),_0x2fe82c=new _0x3d1deb(_0x47bcf2);_0x2fe82c['set']({'label':R(_0x47bcf2,'Save\x20current\x20revision')}),_0x2fe82c['delegate']('execute')['to'](_0x4a9f2a),_0x2fe82c['on']('execute',()=>{this['_showDialog']();}),_0x441322['children']['add'](_0x2fe82c),_0x26623a['items']['add'](_0x441322);const _0x5642a1=new _0x7785ec(_0x47bcf2,_0x4a9f2a),_0x2fea1c=new _0x3d1deb(_0x47bcf2);return _0x2fea1c['set']({'label':R(_0x47bcf2,'Open\x20revision\x20history')}),_0x2fea1c['delegate']('execute')['to'](_0x4a9f2a),_0x2fea1c['on']('execute',()=>{_0x4ff073['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x5642a1['children']['add'](_0x2fea1c),_0x26623a['items']['add'](_0x5642a1),_0x4a9f2a['panelView']['children']['add'](_0x26623a),_0x4a9f2a;}['_showDialog'](){const _0x177d89=this['editor'],_0x2bb7db=_0x177d89['locale'],_0x510251=_0x177d89['plugins']['get']('Dialog'),_0x1bd9cf=_0x177d89['plugins']['get']('RevisionTracker');function _0x1cb6ee(_0x30546a){_0x177d89['config']['get']('revisionHistory.requireRevisionName')&&''===_0x30546a['revisionName']?_0x30546a['revisionNameInputView']['errorText']=R(_0x2bb7db,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x177d89['plugins']['get'](l)['saveRevision']({'name':_0x30546a['revisionName']}),_0x510251['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x1cb6ee(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x510251['show']({'id':'revisionSave','title':R(_0x2bb7db,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':R(_0x177d89['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x510251['hide']()},{'label':R(_0x177d89['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x2d1616){_0x2d1616['bind']('isEnabled')['to'](_0x1bd9cf,'isReady',_0x1bd9cf,'isEnabled',_0x177d89,'isReadOnly',(_0x398804,_0x1f95e0,_0x2bfc10)=>_0x398804&&_0x1f95e0&&!_0x2bfc10);},'onExecute':()=>_0x1cb6ee(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x7262ac=this['editor'],_0x3890ad=_0x7262ac['locale'];this['_saveRevisionFormView']=new ns(_0x3890ad,_0x7262ac['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class Y extends _0x4d3579{['changeId'];['_model'];constructor(_0xcd2068,_0x411b0a){super(_0xcd2068),this['_model']=_0x411b0a,this['changeId']=_0x411b0a['id'];const _0x3fe4d0=this['bindTemplate'],_0x42b3ba=R(_0xcd2068,_0x411b0a['data']['isSuggestion']?'Suggested\x20by':'add'==_0x411b0a['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x411b0a['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x3fe4d0['to']('type',_0x2c44e7=>'ck-revision-change__'+_0x2c44e7)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x42b3ba}]},{'text':'\x20'+_0x411b0a['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class r extends/* #__PURE__ -- @preserve */
|
|
25
|
+
_0x2a484b(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x5683ae){super(),this['id']=_0x5683ae['id']||_0x437679(),this['author']=_0x5683ae['author'],this['type']=_0x5683ae['type'],this['data']=_0x5683ae['data']||{},this['rootName']=_0x5683ae['rootName'],this['set']('createdAt',_0x5683ae['createdAt']);}['toJSON'](){return{'id':this['id'],'authorId':this['author']['id'],'type':this['type'],'data':this['data'],'createdAt':this['createdAt']};}}class f{['newRevisionId'];['oldRevisionId'];['changes'];constructor(_0xd9f951,_0x298fa7){this['newRevisionId']=_0xd9f951,this['oldRevisionId']=_0x298fa7,this['changes']=new _0x43ea08();}['_setChanges'](_0x143579){for(const _0xd1bca8 of _0x143579)this['changes']['add'](_0xd1bca8);}}const Z={'c':_0x759405,'a':_0xe3136e,'e':_0x145ea7,'r':_0xc1f4e3,'u':_0x3e7f30};class d extends _0x20db2f{['repository'];['adapter'];['_activeViewTarget'];['_changeView'];['_changeIdToChange'];['_balloon'];static get['pluginName'](){return'RevisionViewer';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[_0x38b815,_0x1984f6,j];}constructor(_0x384ac2){super(_0x384ac2),this['repository']=this['editor']['plugins']['get']('RevisionsRepository'),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',(_0x3097fd,_0x457455,_0x5d536e)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x27cc7e=>{for(const _0x382e1b of this['editor']['editing']['view']['document']['roots'])_0x5d536e?_0x27cc7e['removeClass']('ck-editor__editable__overlay',_0x382e1b):_0x27cc7e['addClass']('ck-editor__editable__overlay',_0x382e1b);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x399f18=>null!==_0x399f18),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x317c4e,_0x3fa910,_0x3d06af)=>_0x317c4e&&_0x3d06af?_0x3fa910['changes']['getIndex'](_0x3d06af):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x26a1ce,_0x2786aa)=>_0x26a1ce?_0x2786aa['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['adapter']=null,this['_balloon']=this['editor']['plugins']['get'](_0x1984f6);}['init'](){const _0x125d2a=this['editor'],_0x2c88a0=new bt(_0x125d2a,{'direction':'backward'}),_0x541616=new bt(_0x125d2a,{'direction':'forward'});(_0x125d2a['commands']['add']('showPreviousChange',_0x2c88a0),_0x125d2a['commands']['add']('showNextChange',_0x541616),_0x125d2a['commands']['add']('restoreRevision',new yt(_0x125d2a)),this['on']('change:numberOfChanges',()=>{_0x2c88a0['refresh'](),_0x541616['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x125d2a['enableReadOnlyMode']('revision-viewer'),_0x125d2a['plugins']['has']('WidgetToolbarRepository'))&&_0x125d2a['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionData'](_0x599223){await this['loadRevisionData'](_0x599223);const _0x420ab={};for(const _0x38a0f1 in _0x599223['diffData']){if(_0x599223['diffData'][_0x38a0f1]['attachChange']&&!_0x599223['diffData'][_0x38a0f1]['attachChange']['isAttached'])continue;const _0x288db1=this['_removeRevisionMarkers'](JSON['parse'](_0x599223['diffData'][_0x38a0f1]['insertions'])),_0x21759d=this['editor']['editing']['view']['document'],_0xe351f2=new _0x1e7533(_0x21759d,_0x288db1['map'](_0x1b9181=>this['_getViewObj'](_0x1b9181)));this['editor']['data']['processor']['useFillerType']('marked'),_0x420ab[_0x38a0f1]=this['editor']['data']['processor']['toData'](_0xe351f2),this['editor']['data']['processor']['useFillerType']('default');}return _0x420ab;}async['getRevisionRootsAttributes'](_0xa2060e){await this['loadRevisionData'](_0xa2060e);const _0x169670={};for(const _0x545e82 in _0xa2060e['diffData'])_0xa2060e['diffData'][_0x545e82]['attachChange']&&!_0xa2060e['diffData'][_0x545e82]['attachChange']['isAttached']||(_0x169670[_0x545e82]=_0xa2060e['diffData'][_0x545e82]['attributesAfter']||{});return _0x169670;}['_removeRevisionMarkers'](_0x434aa6){return(_0x434aa6=_0x434aa6['filter'](_0x1e483b=>!_0x1e483b['name']||'revision-start'!==_0x1e483b['name']&&'revision-end'!==_0x1e483b['name']))['forEach'](_0x2249f2=>{'string'!=typeof _0x2249f2&&(_0x2249f2['children']=this['_removeRevisionMarkers'](_0x2249f2['children']),_0x2249f2['attributes']=_0x2249f2['attributes']['filter'](_0x5436be=>!_0x5436be[0x0]['startsWith']('data-revision-')));}),_0x434aa6;}async['compare'](_0x4783bd,_0x500cbb,_0xb88c2c=!0x1){if(!this['isEnabled'])return;const _0x5a9b75=this['diff'],_0x26d1f7=this['repository'],_0x1ecfc1='string'==typeof _0x4783bd?_0x26d1f7['getRevision'](_0x4783bd):_0x4783bd,_0x38d240='string'==typeof _0x500cbb?_0x26d1f7['getRevision'](_0x500cbb):_0x500cbb,_0x42be93=_0x1ecfc1['id'],_0x4499ef=_0x38d240?_0x38d240['id']:null;if(!_0xb88c2c&&this['diff']&&this['diff']['newRevisionId']===_0x42be93&&this['diff']['oldRevisionId']===_0x4499ef)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new f(_0x42be93,_0x4499ef);const _0x2e8e71=this['_getRevisionsRange'](_0x1ecfc1,_0x38d240,!0x0)['map'](_0x48bef0=>this['loadRevisionData'](_0x48bef0));return _0x2e8e71['push'](new Promise(_0x1594a7=>{setTimeout(_0x1594a7,0x14);})),Promise['all'](_0x2e8e71)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x3fc25f=this['_getDiff'](_0x42be93,_0x4499ef);for(const _0x394c6b of _0x3fc25f['changes'])this['_changeIdToChange']['set'](_0x394c6b['id'],_0x394c6b);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x20f757=>{for(const _0x73c22f of this['editor']['model']['document']['getRootNames']())_0x20f757['detachRoot'](_0x73c22f);for(const _0x458fdb of Object['keys'](_0x3fc25f['model'])){const _0x2ee7f3=_0x20f757['addRoot'](_0x458fdb);for(const _0x2226b8 of Object['keys'](_0x3fc25f['attributes'][_0x458fdb]))_0x20f757['setAttribute'](_0x2226b8,_0x3fc25f['attributes'][_0x458fdb][_0x2226b8],_0x2ee7f3);_0x20f757['insert'](_0x3fc25f['model'][_0x458fdb],_0x2ee7f3,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x3fc25f['changes'])),this['isReady']=!0x0;})['catch'](_0x44d2f5=>{console['error'](_0x44d2f5),this['_cleanUp'](),_0x5a9b75&&(this['diff']=_0x5a9b75),this['isReady']=!0x0;});}['addRevisionData'](_0x36dc4c,_0x5d17fa){const _0x2a267c=this['repository']['createRevision'](_0x36dc4c);return _0x2a267c['on']('_update',(_0x487b5f,_0x323219,_0x47272f)=>_0x5d17fa(_0x323219,_0x47272f,_0x2a267c)),this['repository']['addRevision'](_0x2a267c),_0x2a267c;}['loadRevisionData'](_0x3ea24f){if(!_0x3ea24f||_0x3ea24f['diffData'])return Promise['resolve']();{const _0xbed875=this['editor']['config']['get']('collaboration.channelId');return this['adapter']['getRevision']({'channelId':_0xbed875,'revisionId':_0x3ea24f['id']})['then'](_0x470fe8=>{_0x3ea24f['_update']({'diffData':_0x470fe8['diffData']},!0x0);});}}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0xc5984f=>{for(const _0x5bf9da of this['editor']['model']['document']['getRootNames']())_0xc5984f['detachRoot'](_0x5bf9da);});}['_sortAndFilterDiffChanges'](_0x3adb1a){const _0x3aa864=[],_0x5da19a=new Map();for(const _0x4e7b1e of this['editor']['model']['document']['getRootNames']()){const _0x2d0324=this['editor']['editing']['view']['getDomRoot'](_0x4e7b1e);if(!_0x2d0324)continue;const _0x26bf05=_0x2d0324['getClientRects']()['item'](0x0);_0x26bf05&&(_0x3aa864['push'](_0x4e7b1e),_0x5da19a['set'](_0x4e7b1e,_0x26bf05));}return _0x3aa864['sort']((_0x3e8f49,_0x56e87e)=>{const _0x1afdec=_0x5da19a['get'](_0x3e8f49),_0x1b108a=_0x5da19a['get'](_0x56e87e);return _0x1afdec['y']-_0x1b108a['y']||_0x1afdec['x']-_0x1b108a['x'];}),(_0x3adb1a=_0x3adb1a['filter'](_0x2ceb50=>_0x3aa864['includes'](_0x2ceb50['rootName'])))['sort']((_0x17b910,_0x2fefa0)=>_0x3aa864['indexOf'](_0x17b910['rootName'])-_0x3aa864['indexOf'](_0x2fefa0['rootName'])),_0x3adb1a;}['_makeTape'](_0x6f5f6b){const _0x4f4d40=Array['from'](_0x6f5f6b['markers'])['filter'](([_0x2adb9c,_0xd778f6])=>_0x2adb9c['startsWith']('revision:')&&!_0xd778f6['isCollapsed']),_0x4bf945=Array['from'](this['editor']['model']['createRangeIn'](_0x6f5f6b)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x4f4d40['length'])for(const _0x2c0993 of _0x4bf945){const [_0x2aeea2,_0x1addc3]=_0x4f4d40[0x0],[,_0x1a6983,_0x440766]=_0x2aeea2['split'](':');if(_0x1addc3['end']['isEqual'](_0x2c0993['nextPosition'])&&_0x4f4d40['shift'](),(_0x2c0993['previousPosition']['isEqual'](_0x1addc3['start'])||_0x2c0993['previousPosition']['isAfter'](_0x1addc3['start']))&&('insertion'==_0x1a6983?_0x2c0993['isAdded']={'userId':_0x440766}:'deletion'==_0x1a6983&&(_0x2c0993['isRemoved']={'userId':_0x440766})),0x0==_0x4f4d40['length'])break;}return _0x4bf945;}['_refreshStartEndIndex'](_0xa350a1){const _0x459eb8=new Map();for(let _0x55cf42=0x0;_0x55cf42<_0xa350a1['length'];_0x55cf42++)'text'===_0xa350a1[_0x55cf42]['type']?(_0xa350a1[_0x55cf42]['item']['startIndex']=_0x55cf42,_0xa350a1[_0x55cf42]['item']['endIndex']=_0x55cf42):('elementStart'===_0xa350a1[_0x55cf42]['type']?_0xa350a1[_0x55cf42]['item']['startIndex']=_0x55cf42:'elementEnd'===_0xa350a1[_0x55cf42]['type']&&(_0xa350a1[_0x55cf42]['item']['endIndex']=_0x55cf42),_0x459eb8['set'](_0xa350a1[_0x55cf42]['id'],_0x55cf42));for(const _0x5037fb of _0x459eb8['values']())'elementStart'===_0xa350a1[_0x5037fb]['type']?_0xa350a1[_0x5037fb]['item']['endIndex']=_0x459eb8['get'](_0xa350a1[_0x5037fb]['pairId']):'elementEnd'===_0xa350a1[_0x5037fb]['type']&&(_0xa350a1[_0x5037fb]['item']['startIndex']=_0x459eb8['get'](_0xa350a1[_0x5037fb]['pairId']));}['_processTape'](_0x2ec7fb){for(let _0x5ee365=0x0;_0x5ee365<_0x2ec7fb['length'];_0x5ee365++){if('elementStart'===_0x2ec7fb[_0x5ee365]['type'])_0x2ec7fb[_0x5ee365]['item']['startIndex']=_0x5ee365;else{if('elementEnd'===_0x2ec7fb[_0x5ee365]['type']){_0x2ec7fb[_0x5ee365]['item']['endIndex']=_0x5ee365;const _0x4ddf63=_0x2ec7fb[_0x5ee365]['item']['startIndex'];_0x2ec7fb[_0x4ddf63]['pairId']=_0x2ec7fb[_0x5ee365]['id'],_0x2ec7fb[_0x5ee365]['pairId']=_0x2ec7fb[_0x4ddf63]['id'];}else _0x2ec7fb[_0x5ee365]['item']['startIndex']=_0x5ee365,_0x2ec7fb[_0x5ee365]['item']['endIndex']=_0x5ee365,_0x2ec7fb[_0x5ee365]['pairId']=null;}_0x2ec7fb[_0x5ee365]['markersStart']||(_0x2ec7fb[_0x5ee365]['markersStart']=[],_0x2ec7fb[_0x5ee365]['markersEnd']=[]);}}['_markInsertions'](_0x41ddf4,_0x1bce1c){const _0x399cfa=_0x41ddf4['filter'](_0x3b9d58=>!_0x3b9d58['isAdded']);for(let _0xe2dd4a=0x0;_0xe2dd4a<_0x1bce1c['length'];_0xe2dd4a++)_0x1bce1c[_0xe2dd4a]['isAdded']&&(_0x399cfa[_0xe2dd4a]['isAdded']=_0x1bce1c[_0xe2dd4a]['isAdded']);}['_makeModelFromViewString'](_0x3d1562){const _0x55bfac=JSON['parse'](_0x3d1562),_0x5192c7=this['editor']['editing']['view']['document'],_0x5af888=new _0x1e7533(_0x5192c7,_0x55bfac['map'](_0x521fd2=>this['_getViewObj'](_0x521fd2)));return this['editor']['data']['toModel'](_0x5af888);}['_getViewObj'](_0x26079a){const _0x5a53ae=this['editor']['editing']['view']['document'];if('string'==typeof _0x26079a)return new _0x2e9e1e(_0x5a53ae,_0x26079a);{const _0x21acc6=_0x26079a['children']['map'](_0x354dc7=>this['_getViewObj'](_0x354dc7));return new(Z[_0x26079a['type']]||_0x132a21)(_0x5a53ae,_0x26079a['name'],_0x26079a['attributes'],_0x21acc6);}}['_getDiff'](_0x5dbdf9,_0x2d7b02=null){const _0x3e67d9=this['repository']['getRevision'](_0x5dbdf9),_0x1be001=_0x2d7b02?this['repository']['getRevision'](_0x2d7b02):null,_0x55b84e=this['_getRevisionsRange'](_0x3e67d9,_0x1be001),_0x1e564e=_0x55b84e[_0x55b84e['length']-0x1],_0x34901b=new Map(),_0x4ccde0={'model':{},'attributes':{},'changes':[]},_0x2346c3=new Set(),_0x36f5d5=new Map();for(let _0x3acb5f=_0x55b84e['length']-0x1;_0x3acb5f>=0x0;_0x3acb5f--){const _0xf7a8bd=_0x55b84e[_0x3acb5f];for(const _0x86c6d9 of Object['keys'](_0xf7a8bd['diffData']))if(_0xf7a8bd['diffData'][_0x86c6d9]['attachChange']){const _0x48cc34=_0xf7a8bd['diffData'][_0x86c6d9]['attachChange'];_0x48cc34['isAttached']?(_0x2346c3['add'](_0x86c6d9),_0x36f5d5['has'](_0x86c6d9)&&_0x36f5d5['get'](_0x86c6d9)['userId']==_0x48cc34['userId']?_0x36f5d5['delete'](_0x86c6d9):_0x36f5d5['set'](_0x86c6d9,_0x48cc34)):_0x36f5d5['has'](_0x86c6d9)?(_0x2346c3['delete'](_0x86c6d9),_0x36f5d5['delete'](_0x86c6d9)):(_0x2346c3['add'](_0x86c6d9),_0x36f5d5['set'](_0x86c6d9,_0x48cc34));}else _0x2346c3['add'](_0x86c6d9);}for(const _0x2c0e39 of _0x2346c3){const _0x2e26c0=_0x36f5d5['has'](_0x2c0e39)&&!_0x36f5d5['get'](_0x2c0e39)['isAttached'];let _0x5e9c86=_0x2e26c0?_0x55b84e['length']-0x1:0x0;const _0x2b9a16=_0x2e26c0?-0x1:0x1;for(;_0x55b84e[_0x5e9c86];){const _0x381ce4=_0x55b84e[_0x5e9c86];if(_0x381ce4['diffData'][_0x2c0e39]){const _0x1dceac=_0x2e26c0?_0x381ce4['diffData'][_0x2c0e39]['attributesBefore']:_0x381ce4['diffData'][_0x2c0e39]['attributesAfter'];_0x4ccde0['attributes'][_0x2c0e39]=_0x1dceac?_0x34b9d0(_0x1dceac):{};break;}_0x5e9c86+=_0x2b9a16;}}for(const _0x2a0972 of _0x55b84e){_0x2a0972['model']={};for(const _0x4e5183 of _0x2a0972['authors'])_0x34901b['set'](_0x4e5183['id'],_0x4e5183);for(const _0x3716b8 of _0x2346c3){const _0x5cce07=_0x2a0972['diffData'][_0x3716b8]?_0x2a0972['diffData'][_0x3716b8]['insertions']:'[]',_0x4b0248=_0x2a0972['diffData'][_0x3716b8]?_0x2a0972['diffData'][_0x3716b8]['deletions']:'[]';_0x2a0972['model'][_0x3716b8]={'insertions':this['_makeModelFromViewString'](_0x5cce07),'deletions':this['_makeModelFromViewString'](_0x4b0248)};}}for(const _0x3f1045 of _0x2346c3){let _0x5d75ca=null,_0x18f486=0x0;const _0xab8b82=new Map(Array['from'](_0x3e67d9['model'][_0x3f1045]['insertions']['markers'])['filter'](([_0x1c1cdc])=>!_0x1c1cdc['startsWith']('revision:')));let _0x5879f2=0x0;for(const _0x52150e of _0x55b84e){const _0x4640c7=this['_makeTape'](_0x52150e['model'][_0x3f1045]['insertions']);_0x52150e==_0x3e67d9?(_0x5d75ca=_0x4640c7,_0x18f486=_0x5d75ca['length'],_0x5d75ca['forEach'](_0x149143=>{_0x149143['id']=_0x5879f2++;}),this['_processTape'](_0x5d75ca)):this['_markInsertions'](_0x5d75ca,_0x4640c7);const _0x9431de=_0x5d75ca['filter'](_0xdd607=>!_0xdd607['isAdded'])['map'](_0x4aa74e=>_0x4aa74e['id']);let _0x50ce8b=0x0;const _0x2ce303=this['_makeTape'](_0x52150e['model'][_0x3f1045]['deletions']);_0x2ce303['forEach'](_0x20bab9=>{_0x20bab9['isRemoved']?_0x20bab9['id']=_0x18f486++:_0x20bab9['id']=_0x9431de[_0x50ce8b++];}),this['_processTape'](_0x2ce303),this['_setDistance'](_0x5d75ca,'isAdded'),this['_setDistance'](_0x2ce303,'isRemoved'),_0x52150e==_0x3e67d9&&this['_markMarkers'](_0x5d75ca,_0xab8b82),_0x5d75ca=this['_joinTapes'](_0x5d75ca,_0x2ce303),this['_refreshStartEndIndex'](_0x5d75ca),this['_setDistance'](_0x5d75ca,'isRemoved');}_0x5d75ca=_0x5d75ca['filter'](_0xe77ea3=>!(_0xe77ea3['isAdded']&&_0xe77ea3['isRemoved']));const _0x21af14=new Map(_0x1e564e['model'][_0x3f1045]['deletions']['markers']),_0x52e63c=new Set(_0xab8b82['keys']());for(const _0x32627a of _0x21af14['keys']())_0x52e63c['delete'](_0x32627a);this['_markSuggestions'](_0x5d75ca,_0x52e63c),this['_fixObsoleteTags'](_0x5d75ca),_0x5d75ca=this['_removeMissingPairs'](_0x5d75ca),_0x5d75ca=this['_markMismatchedRemovedTags'](_0x5d75ca),_0x5d75ca=this['_removeUnsupportedChanges'](_0x5d75ca);const {root:_0x40ea0a,changes:_0xcc68c8}=this['_makeModelFromTape'](_0x5d75ca,_0x34901b,_0x3f1045);_0x4ccde0['model'][_0x3f1045]=_0x40ea0a;const _0x30be95=_0x36f5d5['get'](_0x3f1045);if(_0x30be95){const _0xabac5=_0x34901b['get'](_0x30be95['userId']),_0x190259=new r({'author':_0xabac5,'type':_0x30be95['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x3f1045});_0xcc68c8['unshift'](_0x190259),_0x4ccde0['attributes'][_0x3f1045]['revisionHistoryAttachChange']=_0x190259['id'];}_0x4ccde0['changes']=_0x4ccde0['changes']['concat'](_0xcc68c8);}return _0x4ccde0;}['_markMarkers'](_0x1ddb55,_0x41b518){for(let _0x1157b4=0x0;_0x1157b4<_0x1ddb55['length'];_0x1157b4++)for(const [_0x202cf6,_0x24620b]of _0x41b518)_0x24620b['start']['isEqual'](_0x1ddb55[_0x1157b4]['previousPosition'])&&_0x1ddb55[_0x1157b4]['markersStart']['push'](_0x202cf6),_0x24620b['end']['isEqual'](_0x1ddb55[_0x1157b4]['nextPosition'])&&_0x1ddb55[_0x1157b4]['markersEnd']['push'](_0x202cf6);}['_joinTapes'](_0x15ea11,_0x108af6){let _0x12edbf=[],_0x525d04=0x0,_0x22df95=0x0;for(;_0x525d04<_0x15ea11['length']||_0x22df95<_0x108af6['length'];){const _0x69f6f=_0x15ea11[_0x525d04]||{},_0x45fa43=_0x108af6[_0x22df95]||{};if(_0x69f6f['id']==_0x45fa43['id'])_0x525d04++,_0x22df95++,_0x12edbf['push'](_0x69f6f);else{if(_0x45fa43['isRemoved']&&_0x69f6f['isAdded']){const {commonTape:_0x5cf644,iEnd:_0x32b4cd,jEnd:_0x4046bc}=this['_threeWayMerge'](_0x15ea11,_0x525d04,_0x108af6,_0x22df95);_0x12edbf=_0x12edbf['concat'](_0x5cf644),_0x525d04=_0x32b4cd,_0x22df95=_0x4046bc;}else _0x45fa43['isRemoved']?(_0x22df95++,_0x12edbf['push'](_0x45fa43)):(_0x525d04++,_0x12edbf['push'](_0x69f6f));}}return _0x12edbf;}['_markSuggestions'](_0x57b585,_0x2022eb){const _0x45b91e=[];for(let _0x2ed114=0x0;_0x2ed114<_0x57b585['length'];_0x2ed114++){for(let _0x54f8dc=0x0;_0x54f8dc<_0x57b585[_0x2ed114]['markersStart']['length'];_0x54f8dc++){const _0x54100a=_0x57b585[_0x2ed114]['markersStart'][_0x54f8dc];if(!_0x2022eb['has'](_0x54100a))continue;const {group:_0xe81758,type:_0x3b086f,authorId:_0x5e7e17}=_0x3c3ca8(_0x54100a);'revision-suggestion'!=_0xe81758||'insertion'!=_0x3b086f&&'deletion'!=_0x3b086f||(_0x45b91e['unshift']({'type':_0x3b086f,'name':_0x54100a,'userId':_0x5e7e17}),_0x57b585[_0x2ed114]['markersStart']['splice'](_0x54f8dc,0x1),_0x54f8dc--);}_0x1fb1e3(_0x57b585[_0x2ed114]);for(let _0x4cd5be=0x0;_0x4cd5be<_0x57b585[_0x2ed114]['markersEnd']['length'];_0x4cd5be++){const _0x47389b=_0x57b585[_0x2ed114]['markersEnd'][_0x4cd5be];if(!_0x2022eb['has'](_0x47389b))continue;const {group:_0x12d5cf,type:_0x1f4001}=_0x3c3ca8(_0x47389b);if('revision-suggestion'!=_0x12d5cf||'insertion'!=_0x1f4001&&'deletion'!=_0x1f4001)continue;_0x57b585[_0x2ed114]['markersEnd']['splice'](_0x4cd5be,0x1),_0x4cd5be--;const _0x38e5a7=_0x45b91e['findIndex'](_0x48180e=>_0x48180e['name']==_0x47389b);_0x38e5a7>-0x1&&_0x45b91e['splice'](_0x38e5a7,0x1);}}function _0x3c3ca8(_0x41ae63){const _0x4e8fd5=_0x41ae63['split'](':');return{'group':_0x4e8fd5[0x0],'type':_0x4e8fd5[0x1],'subType':_0x4e8fd5['length']>=0x5?_0x4e8fd5[0x2]:null,'id':_0x4e8fd5['length']<0x5?_0x4e8fd5[0x2]:_0x4e8fd5[0x3],'authorId':_0x4e8fd5['length']<0x5?_0x4e8fd5[0x3]:_0x4e8fd5[0x4],'markerCount':0x6==_0x4e8fd5['length']?_0x4e8fd5[0x5]:null};}function _0x1fb1e3(_0x973474){for(let _0x47fc52=0x0;_0x47fc52<_0x45b91e['length'];_0x47fc52++){if(_0x973474['isAdded']&&'insertion'==_0x45b91e[_0x47fc52]['type'])return _0x973474['isAddSuggestion']=_0x45b91e[_0x47fc52],void delete _0x973474['isAdded'];if(!_0x973474['isAdded']&&!_0x973474['isRemoved']&&'deletion'==_0x45b91e[_0x47fc52]['type'])return void(_0x973474['isRemoveSuggestion']=_0x45b91e[_0x47fc52]);}}}['_setDistance'](_0x45b226,_0x48f457){let _0x42d20e=0x0,_0x63f1f3=!0x1;const _0xc2ccb6=new Map();for(const _0x2b3ef9 of _0x45b226)_0x2b3ef9[_0x48f457]?_0x63f1f3&&(_0x42d20e++,_0x63f1f3=!0x1):(_0x42d20e++,_0x63f1f3=!0x0),_0xc2ccb6['set'](_0x2b3ef9['id'],_0x42d20e);for(let _0x4aca86=0x0;_0x4aca86<_0x45b226['length'];_0x4aca86++){if('isRemoved'==_0x48f457&&_0x45b226[_0x4aca86]['isAdded']||'isAdded'==_0x48f457&&_0x45b226[_0x4aca86]['isRemoved'])continue;if('text'==_0x45b226[_0x4aca86]['type']){_0x45b226[_0x4aca86]['distance']=0x0;continue;}const _0x51446d=_0xc2ccb6['get'](_0x45b226[_0x4aca86]['pairId']),_0x400cdd=_0xc2ccb6['get'](_0x45b226[_0x4aca86]['id']);_0x45b226[_0x4aca86]['distance']=_0x51446d-_0x400cdd;}}['_getRevisionsRange'](_0x177ee1,_0x2da5c5,_0x4929dd=!0x1){const _0x24b066=[];let _0x5464b2=this['repository']['getIndex'](_0x177ee1),_0x52a4d3=this['repository']['getIndex'](_0x2da5c5);for(-0x1==_0x52a4d3&&(_0x52a4d3=this['repository']['_revisions']['length'],_0x4929dd=!0x1);_0x5464b2<_0x52a4d3;)_0x24b066['push'](this['repository']['getRevision'](_0x5464b2)),_0x5464b2++;return _0x4929dd&&_0x24b066['push'](this['repository']['getRevision'](_0x5464b2)),_0x24b066;}['_threeWayMerge'](_0x18383c,_0x4ba4c2,_0x2fa5b4,_0x1113c7){const _0x2e310d=this['editor']['model']['schema'];let _0x59dc5f=_0x4ba4c2;for(;_0x18383c[_0x59dc5f]&&_0x18383c[_0x59dc5f]['isAdded'];)_0x59dc5f++;let _0x2db04b=_0x1113c7;for(;_0x2fa5b4[_0x2db04b]&&_0x2fa5b4[_0x2db04b]['isRemoved'];)_0x2db04b++;_0x4aeee6(_0x18383c,_0x4ba4c2,_0x59dc5f),_0x4aeee6(_0x2fa5b4,_0x1113c7,_0x2db04b);const _0x195d1b=_0x2fa5b4['slice'](_0x1113c7,_0x2db04b)['concat'](_0x18383c['slice'](_0x4ba4c2,_0x59dc5f));return _0x195d1b['sort']((_0x5efebb,_0x1f411c)=>_0x5efebb['side']!=_0x1f411c['side']?_0x5efebb['side']-_0x1f411c['side']:_0x5efebb['level']!=_0x1f411c['level']?_0x5efebb['level']-_0x1f411c['level']:_0x5efebb['distance']!=_0x1f411c['distance']?_0x1f411c['distance']-_0x5efebb['distance']:!!_0x5efebb['isAdded']!=!!_0x1f411c['isAdded']?-0x1==_0x5efebb['side']||0x0==_0x5efebb['side']?_0x5efebb['isAdded']?-0x1:0x1:_0x5efebb['isAdded']?0x1:-0x1:_0x5efebb['index']-_0x1f411c['index']),{'commonTape':_0x195d1b,'iEnd':_0x59dc5f,'jEnd':_0x2db04b};function _0x4aeee6(_0x4b1667,_0x216db1,_0x3ae4af){let _0x3ef04d=-0x1,_0x2abb35=Number['POSITIVE_INFINITY'],_0x5dfebb=!0x0;for(let _0x17f2ce=_0x216db1;_0x17f2ce<_0x3ae4af;_0x17f2ce++)if(_0x2e310d['isInline'](_0x4b1667[_0x17f2ce]['item'])||(_0x5dfebb=!0x1),_0x4b1667[_0x17f2ce]['item']['startIndex']<_0x216db1&&(_0x3ef04d=_0x17f2ce),_0x4b1667[_0x17f2ce]['item']['endIndex']>=_0x3ae4af){_0x2abb35=_0x17f2ce;break;}_0x5dfebb&&(_0x3ef04d=_0x3ae4af-0x1);for(let _0x5494ae=_0x216db1;_0x5494ae<_0x3ae4af;_0x5494ae++)_0x4b1667[_0x5494ae]['side']=_0x5494ae<=_0x3ef04d?-0x1:_0x5494ae<_0x2abb35?0x0:0x1,_0x4b1667[_0x5494ae]['index']=_0x5494ae;let _0x49645e=0x0;for(let _0x5f5342=_0x216db1;_0x5f5342<=_0x3ef04d;_0x5f5342++)0x0==_0x4b1667[_0x5f5342]['distance']?_0x4b1667[_0x5f5342]['level']=_0x49645e:(_0x49645e++,_0x4b1667[_0x5f5342]['level']=_0x49645e,_0x49645e++);for(let _0x4d35ea=_0x216db1;_0x4d35ea<_0x3ae4af;_0x4d35ea++)0x0==_0x4b1667[_0x4d35ea]['side']&&(_0x4b1667[_0x4d35ea]['level']=_0x49645e);_0x49645e=0x0;for(let _0x174393=_0x3ae4af-0x1;_0x174393>=_0x2abb35;_0x174393--)0x0==_0x4b1667[_0x174393]['distance']?_0x4b1667[_0x174393]['level']=_0x49645e:(_0x49645e--,_0x4b1667[_0x174393]['level']=_0x49645e,_0x49645e--);}}['_fixObsoleteTags'](_0x5a4c10){const _0x4ea1d5=new Map(),_0xdc2745=this['editor']['model']['schema'];for(let _0x17614d=0x1;_0x17614d<_0x5a4c10['length'];_0x17614d++){let _0x18fd92,_0x2aafa1,_0x528039;const _0x5063f8=_0x5a4c10[_0x17614d],_0x11de19=_0x5a4c10[_0x17614d-0x1];if('text'==_0x5063f8['type'])continue;if(_0x5063f8['type']!=_0x11de19['type'])continue;if(!_0xdc2745['isBlock'](_0x11de19['item'])||_0xdc2745['isLimit'](_0x11de19['item']))continue;if(!_0xdc2745['isBlock'](_0x5063f8['item'])||_0xdc2745['isLimit'](_0x5063f8['item']))continue;if((_0x5a4c10[_0x17614d]['isAdded']||_0x5a4c10[_0x17614d]['isAddSuggestion'])&&_0x5a4c10[_0x17614d-0x1]['isRemoved'])_0x18fd92=_0x5a4c10[_0x17614d],_0x2aafa1=_0x5a4c10[_0x17614d-0x1],_0x528039=_0x17614d-0x1;else{if(!_0x5a4c10[_0x17614d]['isRemoved']||!_0x5a4c10[_0x17614d-0x1]['isAdded']&&!_0x5a4c10[_0x17614d-0x1]['isAddSuggestion'])continue;_0x18fd92=_0x5a4c10[_0x17614d-0x1],_0x2aafa1=_0x5a4c10[_0x17614d],_0x528039=_0x17614d;}const _0x127bfb=_0x18fd92['level']==_0x2aafa1['level'],_0x5348ba=Math['abs'](_0x18fd92['level'])<Math['abs'](_0x2aafa1['level'])&&0x0==_0x2aafa1['distance'];(_0x127bfb||_0x5348ba)&&(_0x4ea1d5['set'](_0x2aafa1['id'],_0x18fd92['id']),_0x5a4c10['splice'](_0x528039,0x1),_0x17614d--,_0x18fd92['isAdded']=!0x1);}for(let _0x1d7162=0x0;_0x1d7162<_0x5a4c10['length'];_0x1d7162++)_0x4ea1d5['has'](_0x5a4c10[_0x1d7162]['pairId'])&&(_0x5a4c10[_0x1d7162]['pairId']=_0x4ea1d5['get'](_0x5a4c10[_0x1d7162]['pairId']));}['_removeMissingPairs'](_0x8cce52){const _0x4d03e5=new Set(_0x8cce52['map'](_0x500e03=>_0x500e03['id']));for(let _0x3b7da3=0x0;_0x3b7da3<_0x8cce52['length'];_0x3b7da3++)_0x4d03e5['has'](_0x8cce52[_0x3b7da3]['pairId'])||0x0==_0x8cce52[_0x3b7da3]['distance']||(_0x8cce52[_0x3b7da3]['isIncorrect']=!0x0);return _0x8cce52['filter'](_0x36f2eb=>!_0x36f2eb['isIncorrect']);}['_markMismatchedRemovedTags'](_0x2d4900){const _0x44d363=new Set();for(let _0x28701c=0x0;_0x28701c<_0x2d4900['length'];_0x28701c++){if(_0x44d363['has'](_0x2d4900[_0x28701c]['id'])&&_0x2d4900[_0x28701c]['isRemoved']&&(_0x2d4900[_0x28701c]['isIncorrect']=!0x0),_0x2d4900[_0x28701c]['isIncorrect'])continue;if(0x0==_0x2d4900[_0x28701c]['distance'])continue;if('elementStart'!=_0x2d4900[_0x28701c]['type'])continue;if(null==_0x2d4900[_0x28701c]['pairId'])continue;let _0x3ade74=_0x28701c+0x1,_0x477141=0x0;for(;_0x2d4900[_0x3ade74]['id']!=_0x2d4900[_0x28701c]['pairId'];)'elementStart'==_0x2d4900[_0x3ade74]['type']?_0x477141++:'elementEnd'==_0x2d4900[_0x3ade74]['type']&&_0x477141--,_0x3ade74++;if(0x0!=_0x477141){if(_0x2d4900[_0x28701c]['isRemoved'])_0x2d4900[_0x28701c]['isIncorrect']=!0x0;else{for(;_0x3ade74!=_0x28701c;)_0x2d4900[_0x3ade74]['isRemoved']&&0x0!=_0x2d4900[_0x3ade74]['distance']&&(_0x2d4900[_0x3ade74]['isIncorrect']=!0x0,_0x44d363['add'](_0x2d4900[_0x3ade74]['pairId'])),_0x3ade74--;}}}return _0x2d4900['filter'](_0x3fcad1=>!_0x3fcad1['isIncorrect']);}['_removeUnsupportedChanges'](_0x1fbe6b){const _0x2ceb9f=this['editor']['model']['schema'];for(let _0x5bd291=0x0;_0x5bd291<_0x1fbe6b['length'];_0x5bd291++){if(!(_0x1fbe6b[_0x5bd291]['isAdded']||_0x1fbe6b[_0x5bd291]['isAddSuggestion']||_0x1fbe6b[_0x5bd291]['isRemoved']||_0x1fbe6b[_0x5bd291]['isRemoveSuggestion']))continue;if(0x0==_0x1fbe6b[_0x5bd291]['distance'])continue;const _0x337453=_0x1fbe6b[_0x5bd291]['item'];_0x2ceb9f['isBlock'](_0x337453)||_0x2ceb9f['isLimit'](_0x337453)||(_0x1fbe6b[_0x5bd291]['isAdded']&&delete _0x1fbe6b[_0x5bd291]['isAdded'],_0x1fbe6b[_0x5bd291]['isAddSuggestion']&&delete _0x1fbe6b[_0x5bd291]['isAddSuggestion'],_0x1fbe6b[_0x5bd291]['isRemoveSuggestion']&&delete _0x1fbe6b[_0x5bd291]['isRemoveSuggestion'],_0x1fbe6b[_0x5bd291]['isRemoved']&&(_0x1fbe6b[_0x5bd291]['isIncorrect']=!0x0));}return _0x1fbe6b['filter'](_0x8a6383=>!_0x8a6383['isIncorrect']);}['_makeModelFromTape'](_0x95b399,_0x4a02b2,_0x22ad8a){const _0x1a5f9b=new wt(),_0xb97b01=[],_0x5a16c0=new Map(),_0x4ebdf1=this['editor']['model'],_0x4b3adb=_0x4ebdf1['schema'],_0xeb29e9=[_0x1a5f9b],_0x25c816={},_0x135e73={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x17b9ea=null;const _0x51b401=[0x0];for(let _0x33e260=0x0;_0x33e260<_0x95b399['length'];_0x33e260++)if('elementStart'===_0x95b399[_0x33e260]['type']){_0x95b399[_0x33e260]['previousPosition']=_0x4ebdf1['createPositionFromPath'](_0x1a5f9b,_0x51b401);const _0x255014=new ft(_0x95b399[_0x33e260]['item']['name'],_0x95b399[_0x33e260]['item']['getAttributes']());_0xeb29e9[0x0]['_appendChild'](_0x255014),_0x51b401['push'](0x0),_0xeb29e9['unshift'](_0x255014),_0x95b399[_0x33e260]['nextPosition']=_0x4ebdf1['createPositionFromPath'](_0x1a5f9b,_0x51b401);}else'elementEnd'===_0x95b399[_0x33e260]['type']?(_0xeb29e9['shift'](),_0x95b399[_0x33e260]['previousPosition']=_0x4ebdf1['createPositionFromPath'](_0x1a5f9b,_0x51b401),_0x51b401['pop'](),_0x51b401[_0x51b401['length']-0x1]++,_0x95b399[_0x33e260]['nextPosition']=_0x4ebdf1['createPositionFromPath'](_0x1a5f9b,_0x51b401)):(_0x95b399[_0x33e260]['previousPosition']=_0x4ebdf1['createPositionFromPath'](_0x1a5f9b,_0x51b401),_0x17b9ea?_0x17b9ea['_data']+=_0x95b399[_0x33e260]['item']['data']:_0x17b9ea=new _t(_0x95b399[_0x33e260]['item']['data'],_0x95b399[_0x33e260]['item']['getAttributes']()),_0x95b399[_0x33e260+0x1]&&'text'===_0x95b399[_0x33e260+0x1]['type']&&_0x42719f(_0x17b9ea,_0x95b399[_0x33e260+0x1]['item'])||(_0xeb29e9[0x0]['_appendChild'](_0x17b9ea),_0x17b9ea=null),_0x51b401[_0x51b401['length']-0x1]+=_0x95b399[_0x33e260]['item']['offsetSize'],_0x95b399[_0x33e260]['nextPosition']=_0x4ebdf1['createPositionFromPath'](_0x1a5f9b,_0x51b401));for(let _0x3d4cc3=0x0;_0x3d4cc3<_0x95b399['length'];_0x3d4cc3++){const _0x334743=_0x95b399[_0x3d4cc3]['previousPosition'],_0x3674be=_0x95b399[_0x3d4cc3]['nextPosition'];for(const _0x4da0ef of _0x95b399[_0x3d4cc3]['markersStart'])_0x5a16c0['set'](_0x4da0ef,{'start':_0x334743,'end':null});_0x126ed2('isRemoveSuggestion',_0x3d4cc3,_0x334743,_0x3674be),_0x126ed2('isAddSuggestion',_0x3d4cc3,_0x334743,_0x3674be),_0x126ed2('isRemoved',_0x3d4cc3,_0x334743,_0x3674be),_0x126ed2('isAdded',_0x3d4cc3,_0x334743,_0x3674be);for(const _0x410f4d of _0x95b399[_0x3d4cc3]['markersEnd']){_0x5a16c0['get'](_0x410f4d)['end']=_0x3674be;}}for(const [_0x215e51,_0x31cddb]of _0x5a16c0){const _0x5a1761=this['editor']['model']['createRange'](_0x31cddb['start'],_0x31cddb['end']);_0x1a5f9b['markers']['set'](_0x215e51,_0x5a1761);}return _0xb97b01['sort']((_0x1610c7,_0x4d6808)=>{const _0x5ff0e0=_0x1a5f9b['markers']['get']('revision:'+_0x1610c7['id']),_0x5b663e=_0x1a5f9b['markers']['get']('revision:'+_0x4d6808['id']);return _0x5ff0e0['start']['isBefore'](_0x5b663e['start'])?-0x1:_0x5ff0e0['start']['isAfter'](_0x5b663e['start'])?0x1:_0x5ff0e0['end']['isBefore'](_0x5b663e['end'])?-0x1:_0x5ff0e0['end']['isAfter'](_0x5b663e['end'])?0x1:'add'===_0x1610c7['type']?-0x1:0x1;}),{'root':_0x1a5f9b,'changes':_0xb97b01};function _0x126ed2(_0x2feb64,_0x441e5d,_0x29c1d2,_0x17f620){const _0x21711b=!!_0x95b399[_0x441e5d][_0x2feb64],_0x12cdef=_0x21711b?_0x95b399[_0x441e5d][_0x2feb64]['userId']:null,_0x55e567=_0x441e5d===_0x95b399['length']-0x1,_0x1ebfce=_0x135e73[_0x2feb64][0x0],_0x1bf7e5=_0x4b3adb['isObject'](_0x95b399[_0x441e5d]['item']);!_0x25c816[_0x2feb64]&&_0x21711b?_0x25c816[_0x2feb64]={'start':_0x29c1d2,'tapeItem':_0x95b399[_0x441e5d],'userId':_0x12cdef,'type':_0x2feb64}:_0x25c816[_0x2feb64]&&!_0x21711b?(_0x25c816[_0x2feb64]['end']=_0x29c1d2,_0x18301f(_0x25c816[_0x2feb64]),_0x25c816[_0x2feb64]=null):_0x25c816[_0x2feb64]&&_0x21711b&&_0x25c816[_0x2feb64]['userId']!==_0x12cdef&&(_0x25c816[_0x2feb64]['end']=_0x29c1d2,_0x1ebfce&&_0x1ebfce['userId']===_0x25c816[_0x2feb64]['userId']||_0x18301f(_0x25c816[_0x2feb64]),_0x25c816[_0x2feb64]={'start':_0x29c1d2,'tapeItem':_0x95b399[_0x441e5d],'userId':_0x12cdef,'type':_0x2feb64}),_0x25c816[_0x2feb64]&&_0x1bf7e5&&('elementStart'!==_0x95b399[_0x441e5d]['type']||_0x1ebfce&&_0x1ebfce['userId']===_0x12cdef||_0x135e73[_0x2feb64]['unshift']({'userId':_0x12cdef,'object':_0x95b399[_0x441e5d]['item'],'change':_0x25c816[_0x2feb64]}),'elementEnd'===_0x95b399[_0x441e5d]['type']&&_0x1ebfce&&_0x1ebfce['object']===_0x95b399[_0x441e5d]['item']&&(_0x135e73[_0x2feb64]['shift'](),_0x25c816[_0x2feb64]=_0x1ebfce['change'])),_0x25c816[_0x2feb64]&&_0x55e567&&(_0x25c816[_0x2feb64]['end']=_0x17f620,_0x18301f(_0x25c816[_0x2feb64]),_0x25c816[_0x2feb64]=null);}function _0x18301f({start:_0x2d1cd9,end:_0x2d9c54,tapeItem:_0x2c0537,userId:_0x1fa32e,type:_0x1fbc3b}){const _0x4d1666=_0x2c0537['item'],_0x595b7b=_0x4ebdf1['schema']['isBlock'](_0x4d1666)&&!_0x4ebdf1['schema']['isLimit'](_0x4d1666),_0x31cb9c=_0x2d1cd9['nodeAfter']==_0x2d9c54['parent']&&_0x2d9c54['isAtStart'];if(_0x595b7b&&_0x31cb9c)return;const _0x4e4f39=_0x4ebdf1['createRange'](_0x2d1cd9,_0x2d9c54),_0x4452d4=_0x4a02b2['get'](_0x1fa32e),_0x4b593d=new r({'author':_0x4452d4,'type':'isAdded'==_0x1fbc3b||'isAddSuggestion'==_0x1fbc3b?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x1fbc3b||'isRemoveSuggestion'==_0x1fbc3b},'createdAt':new Date(),'rootName':_0x22ad8a});_0xb97b01['push'](_0x4b593d),_0x1a5f9b['markers']['set']('revision:'+_0x4b593d['id'],_0x4e4f39);}function _0x42719f(_0xd9cb1b,_0x1bee1d){const _0x68f4b3=_0xd9cb1b['getAttributes'](),_0x16a8d7=_0x1bee1d['getAttributes']();for(const _0x30528b of _0x68f4b3){if(_0x30528b[0x1]!==_0x1bee1d['getAttribute'](_0x30528b[0x0]))return!0x1;_0x16a8d7['next']();}return _0x16a8d7['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x42e519=>{const _0x2f644e=_0x42e519['markerName']['split'](':')[0x1],_0x1f3c8a=this['_getChangeFromId'](_0x2f644e);if(!_0x1f3c8a)return null;const _0x105df7='add'==_0x1f3c8a['type']?'insertion':'deletion',_0x5ad5b1=['ck-suggestion-marker','ck-suggestion-marker-'+_0x105df7];return _0x1f3c8a['data']['isSuggestion']&&_0x5ad5b1['push']('ck-suggestion-marker-'+_0x105df7+'-new'),this['activeChange']==_0x1f3c8a&&_0x5ad5b1['push']('ck-suggestion-marker--active'),{'classes':_0x5ad5b1,'attributes':{'data-change-id':_0x2f644e}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x3c2971=>{_0x3c2971['on']('element:pre',(_0x36333f,_0x34a529,_0x3c2719)=>{const _0x1a4f44=_0x34a529['viewItem']['getChild'](0x0);if(!_0x1a4f44||!_0x1a4f44['is']('element','code'))return;if(!_0x3c2719['consumable']['consume'](_0x1a4f44,{'attributes':['vid_start','vid_end']}))return;const _0x147d96=_0x34a529['modelRange']['start']['nodeAfter'];_0x3c2719['writer']['setAttribute']('vid_start',_0x1a4f44['getAttribute']('vid_start'),_0x147d96),_0x3c2719['writer']['setAttribute']('vid_end',_0x1a4f44['getAttribute']('vid_end'),_0x147d96);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x4d69f8=>{_0x4d69f8['on']('element',(_0x1756b0,_0x3ce1f7,_0x20d693)=>{if(!_0x20d693['consumable']['consume'](_0x3ce1f7['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x3ce1f7['modelRange']['isCollapsed'])return;const _0x36853c=_0x3ce1f7['modelRange']['start']['nodeAfter'];_0x36853c['hasAttribute']('vid_start')||_0x36853c['hasAttribute']('vid')||(_0x20d693['writer']['setAttribute']('vid_start',_0x3ce1f7['viewItem']['getAttribute']('vid_start'),_0x36853c),_0x20d693['writer']['setAttribute']('vid_end',_0x3ce1f7['viewItem']['getAttribute']('vid_end'),_0x36853c));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x152324=>_0x152324['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x22eb44,[,_0x14fa5f])=>{['vid_start','vid_end','vid']['includes'](_0x14fa5f)&&(_0x22eb44['return']=!0x0,_0x22eb44['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x518a3b=>{_0x518a3b['on']('attribute:vid',(_0x2342a3,_0x226f0c,_0x581d43)=>{if('\x20'!=_0x226f0c['item']['data']||_0x226f0c['item']['parent']['maxOffset']>0x1)return;if(!_0x581d43['consumable']['consume'](_0x226f0c['item'],_0x2342a3['name']))return;const _0x3a58b6=_0x581d43['writer'],_0x35c9ad=_0x581d43['mapper']['toViewRange'](_0x226f0c['range']);_0x3a58b6['wrap'](_0x35c9ad,_0x3a58b6['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x35f088){const _0x1e0aa8=_0x35f088['plugins']['get']('RevisionViewer');return(_0x528667,_0x1bfd0a,_0x5a1ec8)=>{const _0x1d2dd8=_0x1bfd0a['markerName']['split'](':')[0x1],_0x3c71b7=_0x1e0aa8['_getChangeFromId'](_0x1d2dd8);if(!_0x3c71b7)return null;const _0x2d5988='add'==_0x3c71b7['type']?'split':'merge';if(!_0x5a1ec8['consumable']['test'](_0x1bfd0a['markerRange'],_0x528667['name']))return;const _0x15797f=_0x1bfd0a['markerRange']['getWalker'](),_0x1b92c2=_0x1bfd0a['markerRange']['start'],_0x5add18=_0x35f088['model']['schema'];let _0x31e50d=null,_0x2f7114=null,_0x282d9b=!0x1,_0x1d681c=!0x1;for(const _0x3ea8f9 of _0x15797f){const _0x46a1af=_0x3ea8f9['item'];_0x282d9b=_0x282d9b||_0x5add18['isContent'](_0x46a1af);const _0x165de4=_0x5a1ec8['mapper']['toViewElement'](_0x46a1af);if(_0x165de4&&_0x165de4['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x3ea8f9['type']&&(_0x5add18['isBlock'](_0x46a1af)&&!_0x5add18['isLimit'](_0x46a1af)&&(_0x46a1af['nextSibling']||_0x1b92c2['isAtEnd']?_0x31e50d&&_0x31e50d['parent']==_0x46a1af||(_0x31e50d=_0x46a1af,_0x39e2ae(_0x3ea8f9['previousPosition']),_0x1d681c=!0x0):_0x2f7114=_0x2f7114||_0x3ea8f9['previousPosition']));}function _0x39e2ae(_0x42d7f2){const _0x40710b=_0x5a1ec8['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x2d5988}),_0x5d6883=_0x5a1ec8['mapper']['toViewPosition'](_0x42d7f2);_0x3c71b7['data']['isSuggestion']&&_0x5a1ec8['writer']['addClass']('ck-suggestion-marker-'+_0x2d5988+'-new',_0x40710b),_0x1e0aa8['activeChange']==_0x3c71b7&&_0x5a1ec8['writer']['addClass']('ck-suggestion-marker--active',_0x40710b),_0x5a1ec8['writer']['insert'](_0x5d6883,_0x40710b),_0x5a1ec8['mapper']['bindElementToMarker'](_0x40710b,_0x1bfd0a['markerName']);}_0x282d9b||_0x1d681c||!_0x2f7114||_0x39e2ae(_0x2f7114);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x42b063,_0x40fedd,_0x585717)=>{const _0x4d2641=_0x585717['mapper']['markerNameToElements'](_0x40fedd['markerName']);if(_0x4d2641){for(const _0x22a999 of _0x4d2641)(_0x22a999['hasClass']('ck-suggestion-marker-split')||_0x22a999['hasClass']('ck-suggestion-marker-merge'))&&(_0x585717['mapper']['unbindElementFromMarkerName'](_0x22a999,_0x40fedd['markerName']),_0x585717['writer']['remove'](_0x22a999));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x37e505,_0x1ac2ef,_0xe3dad)=>{const _0x34405c=_0x1ac2ef['markerName']['split'](':')[0x1],_0x69c1e2=this['_getChangeFromId'](_0x34405c);if(!_0x69c1e2)return null;const _0x4a1aaa='add'==_0x69c1e2['type']?'split':'merge';if(_0xe3dad['consumable']['test'](_0x1ac2ef['markerRange'],_0x37e505['name']))for(const _0x1051a8 of _0x1ac2ef['markerRange']['getItems']()){if(!_0x1051a8['is']('element','softBreak'))continue;const _0x3497b5=_0xe3dad['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x4a1aaa}),_0x3f495c=_0xe3dad['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x1051a8));_0x69c1e2['data']['isSuggestion']&&_0xe3dad['writer']['addClass']('ck-suggestion-marker-'+_0x4a1aaa+'-new',_0x3497b5),this['activeChange']==_0x69c1e2&&_0xe3dad['writer']['addClass']('ck-suggestion-marker--active',_0x3497b5),_0xe3dad['writer']['insert'](_0x3f495c,_0x3497b5),_0xe3dad['mapper']['bindElementToMarker'](_0x3497b5,_0x1ac2ef['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x324c24=>{for(const _0x4decae of this['editor']['model']['document']['getRootNames']()){const _0x11b885=this['editor']['model']['document']['getRoot'](_0x4decae),_0x5b82a5=this['editor']['editing']['view']['document']['getRoot'](_0x4decae);if(_0x5b82a5){const _0x2feea4=_0x11b885['getAttribute']('revisionHistoryAttachChange');if(_0x324c24['removeAttribute']('data-change-id',_0x5b82a5),_0x324c24['removeClass']('ck-revision-history-root-add',_0x5b82a5),_0x324c24['removeClass']('ck-revision-history-root-remove',_0x5b82a5),_0x324c24['removeClass']('ck-revision-history-root--active',_0x5b82a5),_0x2feea4){const _0x576c5e=this['_getChangeFromId'](_0x2feea4);if(!_0x576c5e)return null;_0x324c24['setAttribute']('data-change-id',_0x2feea4,_0x5b82a5),_0x324c24['addClass']('ck-revision-history-root-'+_0x576c5e['type'],_0x5b82a5),this['activeChange']==_0x576c5e&&_0x324c24['addClass']('ck-revision-history-root--active',_0x5b82a5);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x35c119=>'revision-comment:'+_0x35c119,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x39b54b=>'revision-suggestion:'+_0x39b54b,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x3b73f4=>({'name':'suggestion:'+_0x3b73f4,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x53f908=>{const _0x2e1469=_0x53f908['markerName']['split'](':')[0x1];return'insertion'!=_0x2e1469&&'deletion'!=_0x2e1469?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x2e1469]};}}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:deletion',tt(this['editor'],'merge'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:insertion',tt(this['editor'],'split'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision-suggestion',(_0x387193,_0x1091db,_0x3e7894)=>{const _0x5a90d4=_0x3e7894['mapper']['markerNameToElements'](_0x1091db['markerName']);if(_0x5a90d4){for(const _0x35c69c of _0x5a90d4)_0x35c69c['is']('uiElement')&&(_0x3e7894['mapper']['unbindElementFromMarkerName'](_0x35c69c,_0x1091db['markerName']),_0x3e7894['writer']['remove'](_0x35c69c));}},{'priority':'high'});}['_getChangeFromId'](_0x1e58a1){return this['_changeIdToChange']['get'](_0x1e58a1);}['_getViewForChange'](_0x7d20f8){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new Y(this['editor']['locale'],_0x7d20f8),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x342cc1,_0x3d1f52,_0x45718d,_0x183c9b)=>{_0x183c9b&&this['_balloon']['remove'](_0x183c9b),_0x45718d&&(this['_balloon']['add']({'view':_0x45718d,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x12f3ea=this['editor']['editing'],_0x4e64d7=this['_getChangeFromId'](_0x45718d['changeId']);let _0x1f26fb;if(_0x4e64d7['data']['isOnRoot']){const _0x5ee187=_0x12f3ea['view']['getDomRoot'](_0x4e64d7['rootName']);_0x1f26fb=Array['from'](_0x5ee187['getClientRects']());}else{const _0x16e9bd=this['editor']['model']['markers']['get']('revision:'+_0x45718d['changeId']);_0x1f26fb=Array['from'](_0x12f3ea['mapper']['markerNameToElements'](_0x16e9bd['name']))['map'](_0x1df775=>_0x12f3ea['view']['domConverter']['mapViewToDom'](_0x1df775))['map'](_0x52d4a1=>Array['from'](_0x52d4a1['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x1f26fb[0x0];return _0x1f26fb['find'](_0x15d5ee=>_0x15d5ee['top']-0x3<=this['_activeViewTarget']['y']&&_0x15d5ee['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x15d5ee['left']-0x3<=this['_activeViewTarget']['x']&&_0x15d5ee['right']+0x3>=this['_activeViewTarget']['x'])||_0x1f26fb[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x270d86,_0x1836a4,_0x27742d,_0x41c6bb)=>{this['activeView']=_0x27742d?this['_getViewForChange'](_0x27742d):null,this['editor']['model']['change'](()=>{const _0x2ff7ca=this['editor']['editing'];_0x41c6bb&&(_0x41c6bb['data']['isOnRoot']?_0x2ff7ca['view']['change'](_0x5561de=>{_0x5561de['removeClass']('ck-revision-history-root--active',_0x2ff7ca['view']['document']['getRoot'](_0x41c6bb['rootName']));}):_0x2ff7ca['reconvertMarker']('revision:'+_0x41c6bb['id'])),_0x27742d&&(_0x27742d['data']['isOnRoot']?_0x2ff7ca['view']['change'](_0x3e5002=>{_0x3e5002['addClass']('ck-revision-history-root--active',_0x2ff7ca['view']['document']['getRoot'](_0x27742d['rootName']));}):_0x2ff7ca['reconvertMarker']('revision:'+_0x27742d['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x312e9a,_0x5738d8)=>{if(this['activeChange'])return;const _0x29858c=this['_findChangeIdFromDomTarget'](_0x5738d8['target']),_0x21508d=this['_changeIdToChange']['get'](_0x29858c);_0x21508d?(this['_activeViewTarget']={'x':_0x5738d8['domEvent']['x'],'y':_0x5738d8['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x21508d)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x521078,_0x52b63c)=>{const _0x387194=this['_findChangeIdFromDomTarget'](_0x52b63c['target']),_0x1bd787=this['_changeIdToChange']['get'](_0x387194);_0x1bd787?(this['_activeViewTarget']={'x':_0x52b63c['domEvent']['x'],'y':_0x52b63c['domEvent']['y']},_0x1bd787===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x1bd787):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x25b7c9){do{const _0x4bc376=_0x25b7c9['getAttribute']('data-change-id');if(_0x4bc376)return _0x4bc376;_0x25b7c9=_0x25b7c9['parent'];}while(_0x25b7c9);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0xd7c45f=>{for(const _0x405a11 of this['editor']['model']['markers'])_0xd7c45f['removeMarker'](_0x405a11);});}}function tt(_0x50002f,_0x248340){return(_0x72586f,_0x5701af,_0x38f498)=>{if(!_0x38f498['consumable']['test'](_0x5701af['markerRange'],_0x72586f['name']))return;const _0x1960d9=_0x5701af['markerRange']['getWalker'](),_0xf01865=_0x5701af['markerRange']['start'],_0x4586e7=_0x50002f['model']['schema'];let _0x326db4=null,_0x123427=null,_0x34b0d1=!0x1,_0x5279ff=!0x1;for(const _0x3e8bac of _0x1960d9){const _0x2eee65=_0x3e8bac['item'];_0x34b0d1=_0x34b0d1||_0x4586e7['isContent'](_0x2eee65);const _0x1d84ca=_0x38f498['mapper']['toViewElement'](_0x2eee65);if(_0x1d84ca&&_0x1d84ca['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x3e8bac['type']&&(_0x4586e7['isBlock'](_0x2eee65)&&!_0x4586e7['isLimit'](_0x2eee65)&&(_0x2eee65['nextSibling']||_0xf01865['isAtEnd']?_0x326db4&&_0x326db4['parent']==_0x2eee65||(_0x326db4=_0x2eee65,_0x5d157f(_0x3e8bac['previousPosition']),_0x5279ff=!0x0):_0x123427=_0x123427||_0x3e8bac['previousPosition']));}function _0x5d157f(_0x53c6ad){const _0x465a1b=_0x38f498['mapper']['toViewPosition'](_0x53c6ad),_0x4d17e1=_0x38f498['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x248340});_0x38f498['writer']['insert'](_0x465a1b,_0x4d17e1),_0x38f498['mapper']['bindElementToMarker'](_0x4d17e1,_0x5701af['markerName']);}_0x34b0d1||_0x5279ff||!_0x123427||_0x5d157f(_0x123427);};}class yt extends _0x1ca2bd{constructor(_0x1cf110){super(_0x1cf110);const _0x7b3615=_0x1cf110['plugins']['get'](d);this['affectsData']=!0x1,this['listenTo'](_0x7b3615,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x7b3615,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x7f2b29=this['editor'],_0x491ed8=_0x7f2b29['plugins']['get'](d),_0x32b06f=_0x491ed8['isReady']?_0x491ed8['diff']['newRevisionId']:null;_0x7f2b29['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x32b06f);}['refresh'](){const {isReady:_0x4ae5a6,isEnabled:_0x28b062,repository:_0x39b694,diff:_0x118bc7}=this['editor']['plugins']['get'](d),_0x5cf623=_0x118bc7&&_0x39b694['getLaterVisibleRevision'](_0x118bc7['newRevisionId']);this['isEnabled']=_0x4ae5a6&&_0x28b062&&Boolean(_0x5cf623);}}class bt extends _0x1ca2bd{['_step'];constructor(_0x1002b6,{direction:_0x5a7efc}){super(_0x1002b6);const _0x291a9c=_0x1002b6['plugins']['get'](d);this['affectsData']=!0x1,this['_step']='forward'===_0x5a7efc?0x1:-0x1,this['listenTo'](_0x291a9c,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x291a9c,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x291a9c,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x9b846f=this['editor'],_0xa5e777=_0x9b846f['plugins']['get'](d),{isNavigationMode:_0x1b59b5,currentChangeNumber:_0x1b2940}=_0xa5e777;let _0x356ea9;if(_0xa5e777['activeChange']=_0x1b59b5?_0xa5e777['diff']['changes']['get'](_0x1b2940+this['_step']):_0xa5e777['diff']['changes']['first'],_0xa5e777['activeChange']['data']['isOnRoot'])_0x356ea9=_0x9b846f['editing']['view']['getDomRoot'](_0xa5e777['activeChange']['rootName']);else{const _0x317943=_0x9b846f['model']['markers']['get']('revision:'+_0xa5e777['activeChange']['id']);_0x356ea9=_0x3d8dbe(_0x9b846f['editing'],_0x317943);}_0x322bc2({'target':_0x356ea9,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x216bce,currentChangeNumber:_0x1ed4f9,numberOfChanges:_0x7a682a,isReady:_0x210cc0,isEnabled:_0x2475be}=this['editor']['plugins']['get'](d);this['isEnabled']=!!(_0x2475be&&_0x210cc0&&_0x7a682a)&&(!_0x216bce||(0x1===this['_step']?_0x1ed4f9<_0x7a682a-0x1:_0x1ed4f9>0x0));}}class di extends _0x4d3579{constructor(_0x3cf6cc){super(_0x3cf6cc);const _0x3abc1d=this['bindTemplate'],_0x55728d=new _0x4f47da(_0x3cf6cc),_0x5cf1e0=new _0x4f47da(_0x3cf6cc);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',(_0x2d4dea,_0x41835f)=>_0x2d4dea&&_0x41835f>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x120309,_0x2754b1,_0x5e4f48,_0x537ba3)=>{if(!_0x120309)return R(_0x3cf6cc,'Loading...');if(!_0x5e4f48)return R(_0x3cf6cc,'No\x20changes');const _0x2f91ed=R(_0x3cf6cc,'NUMBER_OF_CHANGES',_0x5e4f48);return _0x537ba3?R(_0x3cf6cc,'X_OF_Y_CHANGES',[_0x2754b1+0x1,_0x5e4f48]):_0x2f91ed;}),_0x55728d['set']({'label':R(_0x3cf6cc,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':'<svg\x20viewBox=\x220\x200\x2020\x2020\x22\x20xmlns=\x22http://www.w3.org/2000/svg\x22><path\x20d=\x22M16.435\x2014.494a.75.75\x200\x200\x200\x201.197-.899l-.067-.089-6.992-8a.75.75\x200\x200\x200-1.05-.078l-.079.078-7.008\x208a.75.75\x200\x200\x200\x201.049\x201.066l.08-.078\x206.442-7.354\x206.428\x207.354z\x22/></svg>\x0a'}),_0x5cf1e0['set']({'label':R(_0x3cf6cc,'Show\x20next\x20change'),'tooltip':!0x0,'icon':'<svg\x20viewBox=\x220\x200\x2020\x2020\x22\x20xmlns=\x22http://www.w3.org/2000/svg\x22><path\x20d=\x22M16.435\x205.506a.75.75\x200\x200\x201\x201.197.899l-.067.089-6.992\x208a.75.75\x200\x200\x201-1.05.078l-.079-.078-7.008-8a.75.75\x200\x200\x201\x201.049-1.066l.08.078\x206.442\x207.354\x206.428-7.354z\x22/></svg>\x0a'}),_0x55728d['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x5cf1e0['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x55728d['on']('execute',()=>this['fire']('execute','backward')),_0x5cf1e0['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',_0x3abc1d['if']('_isStatusLabelVisible','ck-hidden',_0x1d8c8a=>!_0x1d8c8a)]},'children':[{'text':_0x3abc1d['to']('isNavigationMode',_0x1ff2f4=>_0x1ff2f4?R(_0x3cf6cc,'EDIT_X_OF_Y_REVISIONS')+':\x20':R(_0x3cf6cc,'Total')+':\x20')}]},{'text':_0x3abc1d['to']('_statusText')}]},new _0x1baf29(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x55728d,_0x5cf1e0]}]});}}const ce='ck-editor__editable__loading-overlay';class ae extends _0x20db2f{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x4916af=this['editor']['editing']['view'];_0x4916af['change'](_0x827d9b=>{for(const _0xebd0de of _0x4916af['document']['roots'])_0x827d9b['addClass'](ce,_0xebd0de);});}['hide'](){const _0x462768=this['editor']['editing']['view'];_0x462768['change'](_0x3defbb=>{for(const _0x521f9d of _0x462768['document']['roots'])_0x3defbb['removeClass'](ce,_0x521f9d);});}}class m extends _0x20db2f{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[d,ae];}['init'](){const _0x1b063a=this['editor'],_0x58c151=_0x1b063a['plugins']['get'](d),_0x5c0be4=_0x1b063a['plugins']['get'](ae);_0x1b063a['ui']['componentFactory']['add']('exitToEditing',_0x27266e=>{const _0xaf3868=new _0x4f47da(_0x27266e);return _0xaf3868['set']({'label':R(_0x27266e,'Back\x20to\x20editing'),'icon':_0x2f7a5c['undo'],'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0xaf3868,'execute',()=>{_0x1b063a['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0xaf3868;}),_0x1b063a['ui']['componentFactory']['add']('restoreRevision',_0x5bb9e0=>{const _0x3e73f7=new _0x4f47da(_0x5bb9e0);return _0x3e73f7['set']({'label':R(_0x5bb9e0,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x3e73f7['bind']('isEnabled')['to'](_0x1b063a['commands']['get']('restoreRevision')),this['listenTo'](_0x3e73f7,'execute',()=>_0x1b063a['execute']('restoreRevision')),_0x3e73f7;}),_0x1b063a['ui']['componentFactory']['add']('changesNavigation',_0x5488a7=>{const _0xcec69b=new di(_0x5488a7),_0x1eb6e3=_0x1b063a['commands']['get']('showPreviousChange'),_0x1f5218=_0x1b063a['commands']['get']('showNextChange');return _0xcec69b['bind']('isBackwardNavigationEnabled')['to'](_0x1eb6e3,'isEnabled'),_0xcec69b['bind']('isForwardNavigationEnabled')['to'](_0x1f5218,'isEnabled'),_0xcec69b['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x58c151),this['listenTo'](_0xcec69b,'execute',(_0x1abcbc,_0x583abe)=>{_0x1b063a['execute']('forward'===_0x583abe?'showNextChange':'showPreviousChange');}),_0xcec69b;}),_0x5c0be4['show'](),_0x58c151['on']('change:isReady',(_0x541906,_0x47741f,_0xa11886)=>{_0xa11886?_0x5c0be4['hide']():_0x5c0be4['show']();});}}class mt extends at{['_resizeObserver']=null;constructor(_0x4132cf,_0x1596e9){super(_0x4132cf,_0x1596e9);const _0x17fde0=this['bindTemplate'];this['set']({'label':R(_0x4132cf,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=R(_0x4132cf,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x17fde0['to']('_tooltipString'),'data-cke-tooltip-position':'s','data-cke-tooltip-class':'ck-tooltip_multi-line'}});}['render'](){super['render'](),this['_resizeObserver']=new pt(this['fieldView']['element'],()=>this['_updateTooltipText']()),this['listenTo'](this['fieldView'],'input',()=>this['_updateTooltipText']());}['destroy'](){super['destroy'](),this['_resizeObserver']&&this['_resizeObserver']['destroy']();}['_updateTooltipText'](){const _0x52b376=this['fieldView']['element'];this['_tooltipString']=_0x52b376['scrollWidth']>_0x52b376['clientWidth']&&_0x52b376['value']||'';}}class ti extends _0x4d3579{constructor(_0x13bac5,_0x3d0993,_0x33cc09){super(_0x13bac5);const _0xee1c74=new _0x50f711();_0xee1c74['set']({'content':'<svg\x20viewBox=\x220\x200\x2011\x2010\x22\x20xmlns=\x22http://www.w3.org/2000/svg\x22\x20xmlns:xlink=\x22http://www.w3.org/1999/xlink\x22><path\x20d=\x22M5.5\x205C8.538\x205\x2011\x207.015\x2011\x209.5c0\x20.17-.011.336-.034.5H.034A3.732\x203.732\x200\x200\x201\x200\x209.5C0\x207.015\x202.462\x205\x205.5\x205zm0-5a2.5\x202.5\x200\x201\x201\x200\x205\x202.5\x202.5\x200\x200\x201\x200-5z\x22\x20/></svg>\x0a','viewBox':'0\x200\x2011\x2010'});const _0x598dd3=['ck','ck-revision-history-sidebar__revision-author'];_0x33cc09&&_0x598dd3['push']('ck-revision-history-sidebar__revision-author_creator');const _0x303c44=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':R(_0x13bac5,_0x33cc09?'Revision\x20creator':'Revision\x20author')},'children':[_0xee1c74,_0x3d0993['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x598dd3},'children':_0x303c44});}}function ni(_0x15fb2f,_0x45ae53){const _0x40fa65=_0x15fb2f['bindTemplate'],_0xaf9b22=_0x15fb2f['locale'],_0x57ee5c=_0x1c165d(_0xaf9b22);_0x57ee5c['panelPosition']='sw';const _0x139772=function(_0x1670d0,_0x348039){const _0x369bf1=function(_0x18b611,_0x18ecd6){const _0x3ee22d=_0x18b611['locale'],_0x55b3db={'Compare\x20against\x20selected':R(_0x3ee22d,'Compare\x20against\x20selected'),'Name\x20this\x20revision':R(_0x3ee22d,'Name\x20this\x20revision'),'Restore\x20this\x20revision':R(_0x3ee22d,'Restore\x20this\x20revision')};return _0x18ecd6['map'](_0x4a9675=>{const _0x4a7e39=_0x55b3db[_0x4a9675['name']];return _0x4a7e39&&_0x4a7e39!==_0x4a9675['name']&&(_0x4a9675['name']=_0x4a7e39),_0x4a9675;});}(_0x1670d0,_0x348039),_0x2e7435=new _0x43ea08();for(const _0x595b30 of _0x369bf1){const _0x30eff6={'type':'button','model':new to({'label':_0x595b30['name'],'class':_0x595b30['class'],'withText':!0x0,'role':'menuitem','_action':_0x595b30['action']})};_0x30eff6['model']['bind']('isEnabled')['to'](_0x1670d0,'isActionsDropdownOpen',_0x3f615a=>'function'!=typeof _0x595b30['isEnabled']||(!_0x3f615a||_0x595b30['isEnabled'](_0x1670d0))),_0x2e7435['add'](_0x30eff6);}return _0x2e7435;}(_0x15fb2f,_0x45ae53);return _0x15fb2f['bind']('isActionsDropdownOpen')['to'](_0x57ee5c,'isOpen'),_0x57ee5c['buttonView']['set']({'label':R(_0xaf9b22,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x2f7a5c['threeVerticalDots']}),_0x57ee5c['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x40fa65['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x40fa65['to'](_0x295e94=>_0x295e94['stopPropagation']())}}),_0x57ee5c['on']('execute',_0x148079=>{_0x15fb2f['isReady']&&'function'==typeof _0x148079['source']['_action']&&_0x148079['source']['_action'](_0x15fb2f);}),_0x244218(_0x57ee5c,_0x139772,{'role':'menu'}),_0x57ee5c['listenTo'](_0x15fb2f,'change:isActionsDropdownOpen',(_0x35c2ea,_0x55017d,_0xf73bc4)=>{if(_0xf73bc4)for(const _0x1a7414 of _0x57ee5c['listView']['items']){const _0x39a164=_0x1a7414['children']['first'],_0x2e32f6=_0x45ae53['find'](_0x5435aa=>_0x5435aa['action']===_0x39a164['_action'])['isVisible'];_0x1a7414['isVisible']=void 0x0===_0x2e32f6||_0x2e32f6(_0x15fb2f);}}),_0x57ee5c;}class ai extends/* #__PURE__ -- @preserve */
|
|
26
|
+
_0x4653b3(_0x4d3579){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x882cb9,_0x4f4c80,_0x24272d,_0x1835d0){super(_0x882cb9);const _0x32027b=this['bindTemplate'],_0x8b264f=function(_0x39df16,_0x753849){const _0x21356c=Array['from'](_0x753849['authors'])['filter'](_0x5e2ad0=>_0x5e2ad0!=_0x753849['creator']);return _0x753849['creator']&&_0x21356c['unshift'](_0x753849['creator']),_0x21356c['map'](_0x42d09a=>new ti(_0x39df16,_0x42d09a,_0x42d09a==_0x753849['creator']));}(_0x882cb9,_0x4f4c80);this['id']=_0x4f4c80['id'],this['_revision']=_0x4f4c80,this['_requireRevisionName']=_0x1835d0,this['bind']('name','createdAt')['to'](_0x4f4c80),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x1a9969=>{return _0x1a65ea=_0x882cb9['uiLanguage'],(_0x53a727=_0x1a9969)['toLocaleDateString'](_0x1a65ea,{'month':'long','day':'numeric'})+',\x20'+_0x53a727['toLocaleTimeString'](_0x1a65ea,{'hour':'numeric','minute':'numeric'});var _0x1a65ea,_0x53a727;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new mt(_0x882cb9,_0x551952),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x34f1d4=>_0x34f1d4||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x114995,_0x28eb62)=>_0x114995&&_0x28eb62),this['revisionActionsView']=_0x24272d&&_0x24272d['length']?ni(this,_0x24272d):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x32027b['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x32027b['if']('isEnabled','ck-disabled',_0x3ad60a=>!_0x3ad60a),_0x32027b['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x32027b['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x32027b['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':_0x32027b['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':_0x8b264f}]},this['revisionActionsView']],'on':{'click':_0x32027b['to'](_0x4f4544=>{_0x4f4544['srcElement']['closest']('.ck-thread__remove-confirm')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x21bce8=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x21bce8,'change',()=>{this['_requireRevisionName']&&!_0x21bce8['value']||this['fire']('setName',{'id':this['id'],'name':_0x21bce8['value']}),_0x21bce8['value']||(_0x21bce8['value']=this['name']?this['name']:this['_createdAtFormatted']);});}['select'](){this['isSelected']=!0x0;}['deselect'](){this['isSelected']=!0x1;}['highlight'](){this['isHighlighted']=!0x0;}['unhighlight'](){this['isHighlighted']=!0x1;}}function mi(_0x285dd3,_0x3901a3){const _0xeed04c=_0x7e7791['fromJSDate'](_0x285dd3)['setLocale'](_0x3901a3),_0xa0ef20=_0x7e7791['local'](),_0xa9eccb=_0xa0ef20['minus']({'days':0x1})['startOf']('day');let _0x756abe,_0x1d3275;return _0xeed04c['hasSame'](_0xa0ef20,'day')?(_0x756abe=_0xeed04c['startOf']('day')['toJSDate'](),_0x1d3275=_0xeed04c['toRelativeCalendar']()):_0xeed04c['hasSame'](_0xa9eccb,'day')?(_0x756abe=_0xa9eccb['toJSDate'](),_0x1d3275=_0xeed04c['toRelativeCalendar']()):_0xeed04c['hasSame'](_0xa0ef20,'week')?(_0x756abe=_0xeed04c['startOf']('week')['toJSDate'](),_0x1d3275=_0xeed04c['weekdayLong']||''):_0xeed04c['hasSame'](_0xa0ef20,'year')?(_0x756abe=_0xeed04c['startOf']('month')['toJSDate'](),_0x1d3275=_0xeed04c['monthLong']||''):(_0x756abe=_0xeed04c['startOf']('year')['toJSDate'](),_0x1d3275=String(_0xeed04c['year'])),{'startDate':_0x756abe,'localizedPeriodName':_0x1d3275};}class vi extends _0x4d3579{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x53ca3c,_0x542e36,_0xf0ea35,_0x124b61){super(_0x53ca3c);const _0x1f1d5d=mi(_0x542e36,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x542e36,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0xf0ea35,this['_requireRevisionName']=_0x124b61,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':_0x1f1d5d}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x15c655){const _0xbd5df=new ai(this['locale'],_0x15c655,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0xbd5df);}['removeRevision'](_0x4306a1){const _0x45605c=this['revisionViews']['find'](_0x4a6216=>_0x4a6216['id']===_0x4306a1['id']);this['revisionViews']['remove'](_0x45605c);}}class as extends _0x4d3579{constructor(_0x1752a1){super(_0x1752a1);const _0x322077=new _0x50f711();_0x322077['content']=_0x2f7a5c['history'],this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x322077,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[R(_0x1752a1,'Revision\x20history')]}]});}}class li extends _0x4d3579{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x50e5a2,_0x1cbf19,_0x913ac7,_0x4f4b33){super(_0x50e5a2);const _0x58c1fe=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x1cbf19,this['_revisionActions']=_0x913ac7,this['_requireRevisionName']=_0x4f4b33,this['on']('select',(_0x8bd87,_0xbd155c)=>{this['fire']('revisionSelected',_0xbd155c);}),this['on']('setName',(_0x1a9c96,_0x544256)=>{this['fire']('revisionSetName',_0x544256);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new as(_0x50e5a2),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x58c1fe['if']('isEnabled','ck-disabled',_0x303eb3=>!_0x303eb3)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x15bb93 of this['_revisions'])this['_addRevision'](_0x15bb93);this['_revisions']['on']('add',(_0x5c18a5,_0x3a31e9)=>{this['_addRevision'](_0x3a31e9);}),this['_revisions']['on']('remove',(_0x5e46e0,_0x2a6781)=>{this['_removeRevision'](_0x2a6781);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x554481=>_0x554481['revisionViews']['map'](_0x214bfd=>_0x214bfd))['flat']();}['selectRevision'](_0x30b34e){for(const _0x35aaa8 of this['revisionViews'])_0x30b34e&&_0x30b34e['id']===_0x35aaa8['id']?_0x35aaa8['select']():_0x35aaa8['deselect']();}['highlightRevisions'](_0x4fdbc9){for(const _0x554fc8 of this['revisionViews'])_0x4fdbc9['some'](({id:_0x5d7a90})=>_0x5d7a90===_0x554fc8['id'])?_0x554fc8['highlight']():_0x554fc8['unhighlight']();}['_addRevision'](_0x27f689){const _0x2e2424=mi(_0x27f689['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x41c9cd=this['timePeriodViews']['get'](0x0);_0x41c9cd&&_0x41c9cd['startDate']['getTime']()===_0x2e2424['getTime']()||(_0x41c9cd=new vi(this['locale'],_0x2e2424,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x41c9cd)),_0x41c9cd['addRevision'](_0x27f689);}['_removeRevision'](_0x15fa6d){const _0x28e2f3=mi(_0x15fa6d['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x28e2f3)['removeRevision'](_0x15fa6d);}['_getTimePeriodViewByStartDate'](_0x74a97c){return this['timePeriodViews']['find'](_0xba8b5b=>_0xba8b5b['startDate']['getTime']()===_0x74a97c['getTime']());}}class g extends _0x20db2f{['_revisionViewer'];['_revisionsRepository'];['_sidebarView'];static ['defaultRevisionActions']=/* #__PURE__ -- @preserve */
|
|
27
27
|
((()=>['compareAgainstSelected','restoreRevision','nameRevision'])());static ['availableRevisionActions']=/* #__PURE__ -- @preserve */
|
|
28
|
-
Rt();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[d];}constructor(
|
|
29
|
-
rt(it){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x2be806,_0x3e89b4){super(_0x3e89b4),this['sourceElement']=_0x2be806,this['model']['document']['createRoot']();const _0x229b85=new st(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new et(this,_0x229b85);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0xb0c2e0,_0x452323){const _0x5c0072=new this(_0xb0c2e0,_0x452323);return await _0x5c0072['initPlugins'](),await _0x5c0072['ui']['init'](_0xb0c2e0),await _0x5c0072['data']['init'](_0x5c0072['config']['get']('initialData')||''),_0x5c0072['fire']('ready'),_0x5c0072;}}const p=['RevisionHistoryUI','RestrictedEditingMode'];class k extends _0x4632d0{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x374947){function _0x2e7075(_0x54955f){return _0x54955f['map'](_0x42d16c=>String['fromCharCode'](_0x42d16c))['join']('');}super(_0x374947),this['result']='end',_0x374947[_0x2e7075([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x2e7075([0x76,0x69,0x65,0x77])][_0x2e7075([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x2e7075([0x61,0x75,0x74,0x6f]),_0x374947[_0x2e7075([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x2e7075([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x2e7075([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x2e7075([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x2e7075([0x6f,0x6b])});}}class H extends _0x4632d0{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l,u];}constructor(_0x11e209){if(super(_0x11e209),!this['editor']['config']['get']('revisionHistory'))throw new _0x122181('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x5dbf26=>this['_showRevisionViewer']({..._0x5dbf26,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x10cc6e=>this['_closeRevisionViewer'](_0x10cc6e)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x291de4=>this['_restoreRevision'](_0x291de4)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x28f41f){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x28f41f;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x535e56){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x535e56);}['getRevision'](_0x5d8d96){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x5d8d96);}['getRevisions'](_0x7417b7){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x7417b7||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x2a681a=this['editor'],_0x5a5698=_0x41ed26(_0x2a681a,p),_0x31a8be=_0x2a681a['plugins']['get']('RevisionTracker'),_0x492955=_0x2a681a['plugins']['get']('Users')['users'];return _0x5a5698['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x5a5698['lazyRoots'],(_0x5a5698['plugins']['push'](k,d,m,class extends _0x4632d0{static get['requires'](){return[d,'Users'];}['init'](){const _0xefc969=this['editor']['plugins']['get']('Users');for(const _0x4f0544 of _0x492955)_0x4f0544['isAnonymous']||_0xefc969['getUser'](_0x4f0544['id'])||_0xefc969['addUser'](_0x4f0544);const _0x463c33=_0x31a8be['repository']['getRevisions']();let _0x403372=null;const _0x26fdfd=this['editor']['plugins']['get']('RevisionViewer');_0x26fdfd['adapter']=_0x31a8be['adapter'],_0x26fdfd['bind']('isEnabled')['to'](_0x31a8be),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x2a681a,'isReadOnly',_0xc1b614=>!_0xc1b614);for(const _0x2a637c of _0x463c33){const _0x2cabcb=null===_0x2a637c['creator'];if(_0x2cabcb&&_0x2a637c['toVersion']===_0x2a637c['fromVersion'])continue;const _0x93587c=_0x2a637c['toJSON']();_0x26fdfd['addRevisionData'](_0x93587c,(_0x39a1b8,_0x575aed,_0x31edfe)=>{if(_0x2cabcb){if(_0x403372)_0x403372['_update'](_0x39a1b8,_0x575aed);else{if(!_0x575aed){const _0x1ffa9b=_0x31edfe['toJSON']();_0x1ffa9b['id']=_0x152f7f(),_0x31a8be['saveRevision'](_0x1ffa9b,_0x31edfe['toVersion'])['then'](_0x5859de=>{_0x403372=_0x5859de;});}}}else _0x2a637c['_update'](_0x39a1b8,_0x575aed);});}}},g),_0x5a5698);}['_enhanceShowRevisionViewerCallback'](){const _0x4b4a9c=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0xa723d5=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x762f59=this['editor']['plugins']['get']('Autosave');await _0x762f59['save']();}else await _0xa723d5['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x192a34=this['editor']['plugins']['get']('Dialog');_0x192a34['isOpen']&&_0x192a34['hide']();}const _0x1d0d37=this['_getRevisionViewerEditorConfig']();return _0x4b4a9c(_0x1d0d37)['then'](_0x37c0b3=>{return(this['_viewerEditor']=_0x37c0b3,this['editor']['plugins']['has']('Annotations'))&&this['editor']['plugins']['get']('Annotations')['refreshVisibility'](),_0x37c0b3;})['catch'](_0x15b8b3=>(console['error'](_0x15b8b3),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x37658d=this['editor']['config']['get']('revisionHistory')['closeRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.closeRevisionViewerCallback',()=>(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['_viewerEditor']['plugins']['get']('RevisionViewer')['_cleanUp'](),_0x37658d(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x31c011=this['editor']['plugins']['get']('Annotations');_0x31c011['refreshVisibility'](),_0x31c011['refreshPositioning']();}})));}['_showRevisionViewer'](_0x46a008){const _0x414a13=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x199894=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x3d7fa3=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return w['create'](_0x3d7fa3,_0x46a008)['then'](_0x20ebab=>(_0x199894['style']['display']='block',_0x414a13['style']['display']='none',_0x20ebab));}['_closeRevisionViewer'](_0x4cb45f){const _0x36ea2b=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x36ea2b['style']['display']='',_0x4cb45f['destroy']();}async['_restoreRevision'](_0x5c8bd5){const _0x1ebd1b=this['editor'],_0x5e0e39=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x513fe4=_0x1ebd1b['plugins']['get']('RevisionTracker'),_0x367c58=_0x5e0e39['repository']['getRevision'](_0x5c8bd5);let _0x135586,_0x1574ed,_0x4734b4;try{_0x135586=await _0x5e0e39['getRevisionData'](_0x367c58),_0x1574ed=await _0x5e0e39['getRevisionRootsAttributes'](_0x367c58);}catch(_0x149638){return void console['error'](_0x149638);}_0x1ebd1b['model']['change'](_0x428470=>{for(const _0x175b63 of Array['from'](_0x1ebd1b['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x428470['removeMarker'](_0x175b63);}),_0x5e0e39['isReady']=!0x1,_0x1ebd1b['model']['enqueueChange'](_0x515dfc=>{_0x515dfc['setSelection'](null),_0x515dfc['removeSelectionAttribute'](_0x1ebd1b['model']['document']['selection']['getAttributeKeys']());const _0x38f6b5=Object['keys'](_0x135586);for(const _0x28baa9 of _0x1ebd1b['model']['document']['roots'])'$graveyard'!=_0x28baa9['rootName']&&_0x28baa9['isAttached']()&&!_0x38f6b5['includes'](_0x28baa9['rootName'])&&_0x515dfc['detachRoot'](_0x28baa9);for(const _0x32f9d2 of _0x38f6b5){let _0x21d930=_0x1ebd1b['model']['document']['getRoot'](_0x32f9d2);_0x21d930&&_0x21d930['isAttached']()||(_0x21d930=_0x515dfc['addRoot'](_0x32f9d2));const _0x65b2c8=_0x1574ed[_0x32f9d2],_0x4b07e7=Object['keys'](_0x65b2c8),_0x51e2ad=_0x135586[_0x32f9d2];for(const _0x119af4 of _0x21d930['getAttributeKeys']())_0x4b07e7['includes'](_0x119af4)||_0x515dfc['removeAttribute'](_0x119af4,_0x21d930);for(const _0x141054 of _0x4b07e7)_0x515dfc['setAttribute'](_0x141054,_0x1574ed[_0x32f9d2][_0x141054],_0x21d930);_0x515dfc['remove'](_0x515dfc['createRangeIn'](_0x21d930)),_0x515dfc['insert'](_0x1ebd1b['data']['parse'](_0x51e2ad,_0x21d930),_0x21d930,0x0);}});const _0x4f39ab=R(_0x1ebd1b['locale'],'Restored');if(_0x367c58['name'])_0x4734b4=-0x1==_0x367c58['name']['indexOf'](_0x4f39ab)?_0x4f39ab+':\x20'+_0x367c58['name']:_0x367c58['name'];else _0x4734b4=_0x4f39ab+':\x20'+(_0x367c58['createdAt']['toLocaleDateString'](_0x1ebd1b['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x367c58['createdAt']['toLocaleTimeString'](_0x1ebd1b['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x513fe4['saveRevision']({'name':_0x4734b4}),_0x5e0e39['isReady']=!0x0,_0x1ebd1b['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{a as Revision,H as RevisionHistory,u as RevisionHistoryUI,l as RevisionTracker,d as RevisionViewer,ae as RevisionViewerLoadingOverlay,m as RevisionViewerUI,j as RevisionsRepository,g as RevisionsSidebar};
|
|
28
|
+
Rt();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[d];}constructor(_0xb137de){super(_0xb137de),this['_revisionViewer']=_0xb137de['plugins']['get'](d),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x5b8529=this['_revisionsRepository']['_revisions'],_0x1a5bc6=this['_createRevisionActions'](),_0x57c12d=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new li(this['editor']['locale'],_0x5b8529,_0x1a5bc6,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',(_0x202374,_0x475591)=>{_0x475591['revisionViews']['on']('add',(_0x38ee9e,_0x177d60)=>{_0x177d60['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)),_0x57c12d['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x16d923=this['_revisionsRepository']['getRevision'](0x0);if(_0x16d923){const _0x40c3ed=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x16d923['id']);this['_revisionViewer']['compare'](_0x16d923,_0x40c3ed);}}['_handleRevisionSelected'](_0x242817,_0x4bab80){const _0x577299=this['_revisionsRepository']['getRevision'](_0x4bab80['id']),_0x5676ee=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x577299['id']);this['_revisionViewer']['compare'](_0x577299,_0x5676ee);}['_handleRevisionSetName'](_0x499436,_0x5305c3){this['_revisionsRepository']['getRevision'](_0x5305c3['id'])['setName'](_0x5305c3['name']);}['_handleDiffChange'](_0x306ac7,_0x2b4050,_0x929929){const _0x1e1d7b=this['_revisionsRepository']['getRevisionsInDiff'](_0x929929);_0x1e1d7b['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x1e1d7b),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x1e1d7b[0x0]));}['_createRevisionActions'](){const _0x4309e6=this['editor'],_0x7be9ee=g['availableRevisionActions'],_0x5cccda=_0x4309e6['config']['get']('revisionHistory.revisionActions')||g['defaultRevisionActions'];if(_0x5cccda['length'])return _0x5cccda['map'](_0x514bb9=>{const _0x5e1930='string'==typeof _0x514bb9?Object['assign']({},_0x7be9ee[_0x514bb9]):_0x514bb9;return _0x5e1930['action']=_0x5e1930['action']['bind'](this,_0x4309e6),_0x5e1930['isVisible']&&(_0x5e1930['isVisible']=_0x5e1930['isVisible']['bind'](this,_0x4309e6)),_0x5e1930;});}}function Rt(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x14eb4f},_0x14ddf6)=>{const _0x51fce7=_0x14eb4f['get'](d),_0xdd8643=_0x51fce7['repository'];let _0x47a5dd=_0x51fce7['diff']['newRevisionId'],_0x71cb8=_0x14ddf6['id'];_0xdd8643['getIndex'](_0x47a5dd)>_0xdd8643['getIndex'](_0x71cb8)&&([_0x47a5dd,_0x71cb8]=[_0x71cb8,_0x47a5dd]),_0x51fce7['compare'](_0x47a5dd,_0x71cb8);},'isVisible':({plugins:_0x347e89},_0x9d9da6)=>{const _0x504a54=_0x347e89['get'](d);return!(_0x504a54['repository']['getRevisionsInDiff'](_0x504a54['diff'])['length']>0x2)&&!_0x9d9da6['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x1d7bac,{id:_0x1f44b9})=>{_0x1d7bac['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x1f44b9);},'isVisible':({plugins:_0x2dc536},_0x2529a8)=>!!_0x2dc536['get'](d)['repository']['getLaterVisibleRevision'](_0x2529a8['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x3f8d21},{id:_0x4e9a6c,revisionNameView:_0x1f902e})=>{const _0x826085=_0x3f8d21['get'](d),_0x2a98ec=_0x826085['repository']['getEarlierVisibleRevision'](_0x4e9a6c);_0x826085['compare'](_0x4e9a6c,_0x2a98ec),_0x1f902e['focus'](),_0x1f902e['fieldView']['select']();}}};}class et extends ot{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x292e00,_0x3a90fd){super(_0x292e00),this['_view']=_0x3a90fd,this['_toolbarConfig']=ht(_0x292e00['config']['get']('toolbar')),this['_elementReplacer']=new ct();}get['element'](){return this['view']['element'];}['init'](_0x3c75a5){const _0xbd9d37=this['editor'],_0x1a8dc9=this['view'],_0x21ac30=_0xbd9d37['editing']['view'],_0x313ee4=_0x1a8dc9['editable'],_0x3e9a0d=_0x21ac30['document']['getRoot']();_0x313ee4['name']=_0x3e9a0d['rootName'],_0x1a8dc9['render']();const _0x56f244=_0x313ee4['element'];this['setEditableElement'](_0x313ee4['name'],_0x56f244),_0x1a8dc9['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x21ac30['attachDomRoot'](_0x56f244),this['_elementReplacer']['replace'](_0x3c75a5,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x5937aa=this['view'],_0x43e6b7=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x43e6b7['detachDomRoot'](_0x5937aa['editable']['name']),_0x5937aa['destroy']();}['_initToolbar'](){const _0x31fada=this['view'];_0x31fada['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x31fada['stickyPanel']['limiterElement']=_0x31fada['element'],_0x31fada['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x1e0b93})=>_0x1e0b93),_0x31fada['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x31fada['toolbar']);}}class st extends dt{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0xdb2057,_0x23df26,_0x18f933={}){super(_0xdb2057),this['stickyPanel']=new lt(_0xdb2057),this['toolbar']=new nt(_0xdb2057,{'shouldGroupWhenFull':_0x18f933['shouldToolbarGroupWhenFull']}),this['_editable']=new ut(_0xdb2057,_0x23df26);}['render'](){super['render'](),this['stickyPanel']['content']['add'](this['toolbar']),this['top']['add'](this['stickyPanel']),this['main']['add'](this['editable']);}}class w extends/* #__PURE__ -- @preserve */
|
|
29
|
+
rt(it){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x3aa1df,_0x4c453c){super(_0x4c453c),this['sourceElement']=_0x3aa1df,this['model']['document']['createRoot']();const _0x59dce0=new st(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new et(this,_0x59dce0);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x170ced,_0x25b572){const _0x5c2f67=new this(_0x170ced,_0x25b572);return await _0x5c2f67['initPlugins'](),await _0x5c2f67['ui']['init'](_0x170ced),await _0x5c2f67['data']['init'](_0x5c2f67['config']['get']('initialData')||''),_0x5c2f67['fire']('ready'),_0x5c2f67;}}const p=['RevisionHistoryUI','RestrictedEditingMode'];class k extends _0x20db2f{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x322cbc){function _0x6274f6(_0x3e8e25){return _0x3e8e25['map'](_0xd08a6d=>String['fromCharCode'](_0xd08a6d))['join']('');}super(_0x322cbc),this['result']='end',_0x322cbc[_0x6274f6([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x6274f6([0x76,0x69,0x65,0x77])][_0x6274f6([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x6274f6([0x61,0x75,0x74,0x6f]),_0x322cbc[_0x6274f6([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x6274f6([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x6274f6([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x6274f6([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x6274f6([0x6f,0x6b])});}}class H extends _0x20db2f{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l,u];}constructor(_0xcc65d7){if(super(_0xcc65d7),!this['editor']['config']['get']('revisionHistory'))throw new _0x3fbff5('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x74b782=>this['_showRevisionViewer']({..._0x74b782,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x4b38f1=>this['_closeRevisionViewer'](_0x4b38f1)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x1eaf5a=>this['_restoreRevision'](_0x1eaf5a)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x5c530f){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x5c530f;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x55d748){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x55d748);}['getRevision'](_0x5178a1){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x5178a1);}['getRevisions'](_0x7a6633){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x7a6633||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x2909ec=this['editor'],_0x24c37a=_0x2391ab(_0x2909ec,p),_0x59c647=_0x2909ec['plugins']['get']('RevisionTracker'),_0xda6b7a=_0x2909ec['plugins']['get']('Users')['users'];return _0x24c37a['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x24c37a['lazyRoots'],(_0x24c37a['plugins']['push'](k,d,m,class extends _0x20db2f{static get['requires'](){return[d,'Users'];}['init'](){const _0xfa6a85=this['editor']['plugins']['get']('Users');for(const _0x2e49fd of _0xda6b7a)_0x2e49fd['isAnonymous']||_0xfa6a85['getUser'](_0x2e49fd['id'])||_0xfa6a85['addUser'](_0x2e49fd);const _0x405f28=_0x59c647['repository']['getRevisions']();let _0x66d14c=null;const _0x39c811=this['editor']['plugins']['get']('RevisionViewer');_0x39c811['adapter']=_0x59c647['adapter'],_0x39c811['bind']('isEnabled')['to'](_0x59c647),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x2909ec,'isReadOnly',_0xe83a74=>!_0xe83a74);for(const _0x293b0c of _0x405f28){const _0x98c921=null===_0x293b0c['creator'];if(_0x98c921&&_0x293b0c['toVersion']===_0x293b0c['fromVersion'])continue;const _0x5ce3bc=_0x293b0c['toJSON']();_0x39c811['addRevisionData'](_0x5ce3bc,(_0x1e904c,_0x10c6d2,_0x500273)=>{if(_0x98c921){if(_0x66d14c)_0x66d14c['_update'](_0x1e904c,_0x10c6d2);else{if(!_0x10c6d2){const _0x3babbc=_0x500273['toJSON']();_0x3babbc['id']=_0x437679(),_0x59c647['saveRevision'](_0x3babbc,_0x500273['toVersion'])['then'](_0x1131bc=>{_0x66d14c=_0x1131bc;});}}}else _0x293b0c['_update'](_0x1e904c,_0x10c6d2);});}}},g),_0x24c37a);}['_enhanceShowRevisionViewerCallback'](){const _0x486152=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x81efca=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x38a7f7=this['editor']['plugins']['get']('Autosave');await _0x38a7f7['save']();}else await _0x81efca['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x41916d=this['editor']['plugins']['get']('Dialog');_0x41916d['isOpen']&&_0x41916d['hide']();}const _0x3ae8e2=this['_getRevisionViewerEditorConfig']();return _0x486152(_0x3ae8e2)['then'](_0x151e12=>{return(this['_viewerEditor']=_0x151e12,this['editor']['plugins']['has']('Annotations'))&&this['editor']['plugins']['get']('Annotations')['refreshVisibility'](),_0x151e12;})['catch'](_0x1b1d89=>(console['error'](_0x1b1d89),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x5a7e07=this['editor']['config']['get']('revisionHistory')['closeRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.closeRevisionViewerCallback',()=>(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['_viewerEditor']['plugins']['get']('RevisionViewer')['_cleanUp'](),_0x5a7e07(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x402f5b=this['editor']['plugins']['get']('Annotations');_0x402f5b['refreshVisibility'](),_0x402f5b['refreshPositioning']();}})));}['_showRevisionViewer'](_0x179340){const _0x15ac1b=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x37ad4a=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x6a380b=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return w['create'](_0x6a380b,_0x179340)['then'](_0xbc4189=>(_0x37ad4a['style']['display']='block',_0x15ac1b['style']['display']='none',_0xbc4189));}['_closeRevisionViewer'](_0x4798c7){const _0x1aa84f=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x1aa84f['style']['display']='',_0x4798c7['destroy']();}async['_restoreRevision'](_0x226f79){const _0x267b7b=this['editor'],_0x12d2b7=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0xde963b=_0x267b7b['plugins']['get']('RevisionTracker'),_0x947500=_0x12d2b7['repository']['getRevision'](_0x226f79);let _0x367775,_0xe0a33f,_0x1a95ef;try{_0x367775=await _0x12d2b7['getRevisionData'](_0x947500),_0xe0a33f=await _0x12d2b7['getRevisionRootsAttributes'](_0x947500);}catch(_0x1c3be1){return void console['error'](_0x1c3be1);}_0x267b7b['model']['change'](_0x263fa4=>{for(const _0x9546e9 of Array['from'](_0x267b7b['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x263fa4['removeMarker'](_0x9546e9);}),_0x12d2b7['isReady']=!0x1,_0x267b7b['model']['enqueueChange'](_0x42277e=>{_0x42277e['setSelection'](null),_0x42277e['removeSelectionAttribute'](_0x267b7b['model']['document']['selection']['getAttributeKeys']());const _0x4f2811=Object['keys'](_0x367775);for(const _0x20a740 of _0x267b7b['model']['document']['roots'])'$graveyard'!=_0x20a740['rootName']&&_0x20a740['isAttached']()&&!_0x4f2811['includes'](_0x20a740['rootName'])&&_0x42277e['detachRoot'](_0x20a740);for(const _0xb3dda6 of _0x4f2811){let _0x55acda=_0x267b7b['model']['document']['getRoot'](_0xb3dda6);_0x55acda&&_0x55acda['isAttached']()||(_0x55acda=_0x42277e['addRoot'](_0xb3dda6));const _0x15d427=_0xe0a33f[_0xb3dda6],_0x44c0d5=Object['keys'](_0x15d427),_0x320c7d=_0x367775[_0xb3dda6];for(const _0x2de286 of _0x55acda['getAttributeKeys']())_0x44c0d5['includes'](_0x2de286)||_0x42277e['removeAttribute'](_0x2de286,_0x55acda);for(const _0x37e500 of _0x44c0d5)_0x42277e['setAttribute'](_0x37e500,_0xe0a33f[_0xb3dda6][_0x37e500],_0x55acda);_0x42277e['remove'](_0x42277e['createRangeIn'](_0x55acda)),_0x42277e['insert'](_0x267b7b['data']['parse'](_0x320c7d,_0x55acda),_0x55acda,0x0);}});const _0x22ca57=R(_0x267b7b['locale'],'Restored');if(_0x947500['name'])_0x1a95ef=-0x1==_0x947500['name']['indexOf'](_0x22ca57)?_0x22ca57+':\x20'+_0x947500['name']:_0x947500['name'];else _0x1a95ef=_0x22ca57+':\x20'+(_0x947500['createdAt']['toLocaleDateString'](_0x267b7b['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x947500['createdAt']['toLocaleTimeString'](_0x267b7b['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0xde963b['saveRevision']({'name':_0x1a95ef}),_0x12d2b7['isReady']=!0x0,_0x267b7b['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{a as Revision,H as RevisionHistory,u as RevisionHistoryUI,l as RevisionTracker,d as RevisionViewer,ae as RevisionViewerLoadingOverlay,m as RevisionViewerUI,j as RevisionsRepository,g as RevisionsSidebar};
|