@ckeditor/ckeditor5-revision-history 44.3.0-alpha.3 → 44.3.0-alpha.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/revision-history.js +1 -1
- package/dist/index.js +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 +10 -10
- 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
|
-
_0x217fff(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x279f9a){super(),this['id']=_0x279f9a['id']||_0x5d66aa(),this['creator']=_0x279f9a['creator']||null,this['authors']=_0x279f9a['authors']||[],this['diffData']=_0x279f9a['diffData']||null,this['toVersion']=_0x279f9a['toVersion']||0x0,this['fromVersion']=_0x279f9a['fromVersion']||0x0,this['set']('name',_0x279f9a['name']||''),this['set']('createdAt',_0x279f9a['createdAt']||new Date()),this['set']('attributes',_0x279f9a['attributes']||{});}['setName'](_0x59dd10){this['_update']({'name':_0x59dd10});}['setAttribute'](_0x44fb92,_0x3a07fa){const _0x5cadbc=_0x77b43c(this['attributes']);_0x532155(_0x5cadbc,_0x44fb92,_0x3a07fa),this['_update']({'attributes':_0x5cadbc});}['removeAttribute'](_0x75fa07){const _0x149c26=_0x77b43c(this['attributes']);_0xf42061(_0x149c26,_0x75fa07),this['_update']({'attributes':_0x149c26});}['_update'](_0x251944,_0x42a129=!0x1){let _0x24562d=!0x1;const _0xb5f985={'id':this['id']},_0x5d1648=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0xe876ad of _0x5d1648){const _0x56cdb4=_0x251944[_0xe876ad];void 0x0!==_0x56cdb4&&_0x56cdb4!==this[_0xe876ad]&&(this[_0xe876ad]=_0x56cdb4,_0xb5f985[_0xe876ad]=_0x56cdb4,_0x24562d=!0x0);}_0x24562d&&(_0xb5f985['authors']&&(_0xb5f985['authorsIds']=_0xb5f985['authors']['map'](_0x331f5e=>_0x331f5e['id']),delete _0xb5f985['authors']),this['fire']('_update',_0xb5f985,_0x42a129));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x3e57ac=>_0x3e57ac['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class j extends _0x1420a4{['_revisions'];static get['requires'](){return[_0x4f378f];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x4d1414){super(_0x4d1414),this['_revisions']=new _0xcf6e93();}['afterInit'](){!async function(_0x4dd962){const _0x4a3e05=_0x183b43([0x57,0x43,0x47,0x32,0x79,0x34,0x4e,0x72,0x49,0x61,0x31,0x6f,0x66,0x62,0x77,0x56,0x36,0x74,0x37,0x39,0x6e,0x4c,0x4f,0x33,0x38,0x67,0x6c,0x50,0x30,0x44,0x73,0x4a,0x69,0x59,0x76,0x5a,0x52,0x42,0x78,0x75,0x51,0x41,0x53,0x71,0x55,0x6d,0x70,0x46,0x6b,0x68,0x35,0x58,0x4b,0x7a,0x4d,0x48,0x45,0x64,0x54,0x65,0x6a,0x63]),_0x1d3969=0xeb829,_0x2a051e=0x23bf4070,_0x2b2b3a=0x23b82090^_0x2a051e,_0x2c0a5d=window[_0x183b43([0x44,0x61,0x74,0x65])][_0x183b43([0x6e,0x6f,0x77])](),_0x214631=_0x4dd962[_0x183b43([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x520299=new window[(_0x183b43([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x3ac214=>{_0x214631[_0x183b43([0x6f,0x6e,0x63,0x65])](_0x183b43([0x72,0x65,0x61,0x64,0x79]),_0x3ac214);}),_0x2d4663={[_0x183b43([0x6b,0x74,0x79])]:_0x183b43([0x45,0x43]),[_0x183b43([0x75,0x73,0x65])]:_0x183b43([0x73,0x69,0x67]),[_0x183b43([0x63,0x72,0x76])]:_0x183b43([0x50,0x2d,0x32,0x35,0x36]),[_0x183b43([0x78])]:_0x183b43([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]),[_0x183b43([0x79])]:_0x183b43([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]),[_0x183b43([0x61,0x6c,0x67])]:_0x183b43([0x45,0x53,0x32,0x35,0x36])},_0x2f40dd=_0x214631[_0x183b43([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x183b43([0x67,0x65,0x74])](_0x183b43([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x1c2c94(){let _0x375cb2,_0x4eab7e=null,_0x5c1953=null;try{if(_0x2f40dd==_0x183b43([0x47,0x50,0x4c]))return _0x183b43([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x375cb2=_0x47f9fe(),!_0x375cb2)return _0x183b43([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x375cb2[_0x183b43([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x5c1953=_0x950af8(_0x375cb2[_0x183b43([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x375cb2[_0x183b43([0x6a,0x74,0x69])])),await _0x47ba7d()?_0x555a86()?_0x3e9760()?_0x183b43([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x235fa1()?(_0x375cb2[_0x183b43([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x183b43([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x4eab7e=_0x1c89b7(_0x183b43([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x375cb2[_0x183b43([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x183b43([0x74,0x72,0x69,0x61,0x6c])&&(_0x4eab7e=_0x1c89b7(_0x183b43([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x4270d6()):_0x183b43([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x183b43([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x183b43([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch(_0x34a87e){return _0x183b43([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x3e9760(){const _0x334f3f=[_0x183b43([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x183b43([0x74,0x72,0x69,0x61,0x6c])][_0x183b43([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x375cb2[_0x183b43([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x2c0a5d/0x3e8:0xe10*_0x2b2b3a;return _0x375cb2[_0x183b43([0x65,0x78,0x70])]<_0x334f3f;}function _0x555a86(){const _0x5aa3a4=_0x375cb2[_0x183b43([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x5aa3a4)return!0x1;if(_0x5aa3a4[_0x183b43([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x183b43([0x2a])))return!0x0;if(_0x5aa3a4[_0x183b43([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x183b43([0x52,0x48])))return!0x0;if(_0x5aa3a4[_0x183b43([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x183b43([0x52,0x52,0x48]))){if(_0x4d0bdd())return!0x0;if(_0x4d9606()||_0x667b67())return!0x0;}return!0x1;}function _0x235fa1(){const _0x322e92=_0x375cb2[_0x183b43([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x322e92||0x0==_0x322e92[_0x183b43([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x14a8b3}=new URL(window[_0x183b43([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x322e92[_0x183b43([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x14a8b3))return!0x0;const _0x1fceab=_0x14a8b3[_0x183b43([0x73,0x70,0x6c,0x69,0x74])](_0x183b43([0x2e]));return _0x322e92[_0x183b43([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x1b5d37=>_0x1b5d37[_0x183b43([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x183b43([0x2a])))[_0x183b43([0x6d,0x61,0x70])](_0x491e6a=>_0x491e6a[_0x183b43([0x73,0x70,0x6c,0x69,0x74])](_0x183b43([0x2e])))[_0x183b43([0x73,0x6f,0x6d,0x65])](_0x33c6cb=>_0x1fceab[_0x183b43([0x65,0x76,0x65,0x72,0x79])]((_0x386900,_0x48b710)=>_0x33c6cb[_0x48b710]===_0x386900||_0x33c6cb[_0x48b710]===_0x183b43([0x2a])));}function _0x4270d6(){return _0x4eab7e&&_0x5c1953?new window[(_0x183b43([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x40da9e,_0xa7ea43)=>{_0x4eab7e[_0x183b43([0x74,0x68,0x65,0x6e])](_0x40da9e,_0xa7ea43),_0x5c1953[_0x183b43([0x74,0x68,0x65,0x6e])](_0x9c0b5=>{_0x9c0b5!=_0x183b43([0x56,0x61,0x6c,0x69,0x64])&&_0x40da9e(_0x9c0b5);},_0xa7ea43);}):_0x4eab7e||_0x5c1953||_0x183b43([0x56,0x61,0x6c,0x69,0x64]);}}function _0x950af8(_0x3e0ed7,_0x5b9cab){return new window[(_0x183b43([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2bfd4d=>{if(_0x3c5145())return _0x2bfd4d(_0x183b43([0x56,0x61,0x6c,0x69,0x64]));_0x121e18(),_0x214631[_0x183b43([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x183b43([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x11d527=!0x1;const _0x3fa7ac=_0x5d66aa();function _0x5f28fd(_0x23ea99){return!!_0x23ea99&&(typeof _0x23ea99===_0x183b43([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x23ea99===_0x183b43([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x23ea99[_0x183b43([0x74,0x68,0x65,0x6e])]===_0x183b43([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x23ea99[_0x183b43([0x63,0x61,0x74,0x63,0x68])]===_0x183b43([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x59372e(_0x2603ae){_0xfd6f2e(_0x2603ae)[_0x183b43([0x74,0x68,0x65,0x6e])](_0x62728c=>{if(!_0x62728c||_0x62728c[_0x183b43([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x183b43([0x6f,0x6b]))return _0x183b43([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0xb34bb0(_0x580d5e(_0x3fa7ac+_0x5b9cab))!=_0x62728c[_0x183b43([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x183b43([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x183b43([0x56,0x61,0x6c,0x69,0x64]);})[_0x183b43([0x74,0x68,0x65,0x6e])](_0x44237b=>(_0x4e4419(),_0x44237b),()=>{const _0x23f357=_0x1d14d7();return null==_0x23f357?(_0x4e4419(),_0x183b43([0x56,0x61,0x6c,0x69,0x64])):_0x183b43(_0x2c0a5d-_0x23f357>(0x7b3c470^_0x2a051e)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x183b43([0x74,0x68,0x65,0x6e])](_0x2bfd4d)[_0x183b43([0x63,0x61,0x74,0x63,0x68])](()=>{_0x2bfd4d(_0x183b43([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0xf5a3da=0x2389aef0^_0x2a051e;function _0x4e4419(){const _0x2e5143=_0x183b43([0x6c,0x6c,0x63,0x74,0x2d])+_0xb34bb0(_0x580d5e(_0x3e0ed7)),_0x581d51=_0x1d6793(_0xb34bb0(window[_0x183b43([0x4d,0x61,0x74,0x68])][_0x183b43([0x63,0x65,0x69,0x6c])](_0x2c0a5d/_0xf5a3da)));window[_0x183b43([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x183b43([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x2e5143,_0x581d51);}function _0x1d14d7(){const _0x318907=_0x183b43([0x6c,0x6c,0x63,0x74,0x2d])+_0xb34bb0(_0x580d5e(_0x3e0ed7)),_0x556dbc=window[_0x183b43([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x183b43([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x318907);return _0x556dbc?window[_0x183b43([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x1d6793(_0x556dbc),0x10)*_0xf5a3da:null;}function _0xfd6f2e(_0x22f3ca){return new window[(_0x183b43([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x484598,_0x8c5ca7)=>{_0x22f3ca[_0x183b43([0x74,0x68,0x65,0x6e])](_0x484598,_0x8c5ca7),window[_0x183b43([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x8c5ca7,0x23be94b0^_0x2a051e);});}}_0x214631[_0x183b43([0x6f,0x6e])](_0x183b43([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x1370d3,_0x3460ee)=>{if(_0x3460ee[0x0]!=_0x3e0ed7)return _0x2bfd4d(_0x183b43([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x3460ee[0x1]={..._0x3460ee[0x1],[_0x183b43([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x3fa7ac};},{[_0x183b43([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x183b43([0x68,0x69,0x67,0x68])}),_0x214631[_0x183b43([0x6f,0x6e])](_0x183b43([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x295dc6=>{_0x5f28fd(_0x295dc6[_0x183b43([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x11d527=!0x0,_0x59372e(_0x295dc6[_0x183b43([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x183b43([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x183b43([0x6c,0x6f,0x77])}),_0x520299[_0x183b43([0x74,0x68,0x65,0x6e])](()=>{_0x11d527||_0x2bfd4d(_0x183b43([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x3c5145(){return _0x214631[_0x183b43([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x183b43([0x76,0x69,0x65,0x77])][_0x183b43([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x183b43([0x61,0x75,0x74,0x6f]);}function _0x121e18(){_0x214631[_0x183b43([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x183b43([0x76,0x69,0x65,0x77])][_0x183b43([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x183b43([0x61,0x75,0x74,0x6f]);}}function _0x1c89b7(_0x16f011){const _0x249993=[new window[(_0x183b43([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x4e6f03=>setTimeout(_0x4e6f03,0x23b67ebc^_0x2a051e)),_0x520299[_0x183b43([0x74,0x68,0x65,0x6e])](()=>new window[(_0x183b43([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x189242=>{const _0x35c99c=0x23bf4077^_0x2a051e,_0x45c2e1=_0x4dd962[_0x183b43([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x3cbd41(){_0x45c2e1[_0x183b43([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x35c99c&&_0x189242();}_0x3cbd41(),_0x45c2e1[_0x183b43([0x6f,0x6e])](_0x183b43([0x61,0x64,0x64]),_0x3cbd41);})),new window[(_0x183b43([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x4140e9=>{function _0x206e86(){for(const _0x57c4ae in window)if(window[_0x183b43([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x183b43([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x57c4ae))&&window[_0x57c4ae]==_0x1d3969)return _0x4140e9();_0x214631[_0x183b43([0x73,0x74,0x61,0x74,0x65])]!=_0x183b43([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x183b43([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x206e86,0x23bf53f8^_0x2a051e);}_0x439c06(_0x183b43([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x206e86();})];return window[_0x183b43([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x183b43([0x72,0x61,0x63,0x65])](_0x249993)[_0x183b43([0x74,0x68,0x65,0x6e])](()=>_0x16f011);}async function _0x132f62(){if(await _0x520299,_0x439c06(_0x183b43([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x57277b=_0x4dd962[_0x183b43([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x3f51eb=_0x4dd962[_0x183b43([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])](_0x57277b[_0x183b43([0x69,0x64])]),_0x457e88=_0x4baec3(_0x183b43([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x457e88[_0x183b43([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x57277b['id'],_0x3f51eb?_0x3f51eb['id']:null,!0x0),_0x457e88[_0x183b43([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x183b43([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x457e88[_0x183b43([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x457e88[_0x183b43([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x232662,void(_0x457e88[_0x183b43([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x232662);}if(_0x439c06(_0x183b43([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x5230e7=_0x4baec3(_0x183b43([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x5230e7[_0x183b43([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x183b43([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x5230e7[_0x183b43([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x5230e7[_0x183b43([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x232662,_0x5230e7[_0x183b43([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x232662;}_0x214631[_0x183b43([0x6d,0x6f,0x64,0x65,0x6c])][_0x183b43([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x232662,_0x214631[_0x183b43([0x6d,0x6f,0x64,0x65,0x6c])][_0x183b43([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x232662,_0x214631[_0x183b43([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x183b43([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x4d0bdd(){return _0x439c06(_0x183b43([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x4baec3(_0x183b43([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x183b43([0x73,0x74,0x61,0x74,0x65])]==_0x183b43([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x4d9606(){return _0x439c06(_0x183b43([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 _0x667b67(){return _0x439c06(_0x183b43([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x3e8c09(_0x424f69){const _0x3016ca=_0xe1f1b4();_0x214631[_0x3016ca]=_0x183b43([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])+_0x424f69,_0x424f69[_0x183b43([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x183b43([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0xe1f1b4()]=_0x1d3969),_0x424f69!=_0x183b43([0x56,0x61,0x6c,0x69,0x64])&&_0x132f62();}function _0xe1f1b4(){const _0x1296bd=window[_0x183b43([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x183b43([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x183b43([0x6e,0x6f,0x77])]())[_0x183b43([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x183b43([0x2e]),'');let _0x1d7d69=_0x183b43([0x57]);for(let _0x309b1e=0x0;_0x309b1e<_0x1296bd[_0x183b43([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x309b1e+=0x2){let _0x395912=window[_0x183b43([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x1296bd[_0x183b43([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x309b1e,_0x309b1e+0x2));_0x395912>=_0x4a3e05[_0x183b43([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x395912-=_0x4a3e05[_0x183b43([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x1d7d69+=_0x4a3e05[_0x395912];}return _0x1d7d69;}function _0x47f9fe(){const _0x5bec8d=_0x2f40dd[_0x183b43([0x73,0x70,0x6c,0x69,0x74])](_0x183b43([0x2e]));if(0x3!=_0x5bec8d[_0x183b43([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x7bb2b(_0x5bec8d[0x1]);function _0x7bb2b(_0x565276){const _0xff69b7=_0x2163cb(_0x565276);return _0xff69b7&&_0x2b7324()?_0xff69b7:null;function _0x2b7324(){const _0x34dbd7=_0xff69b7[_0x183b43([0x6a,0x74,0x69])],_0x590af7=window[_0x183b43([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x34dbd7[_0x183b43([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x34dbd7[_0x183b43([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x589f2d={..._0xff69b7,[_0x183b43([0x6a,0x74,0x69])]:_0x34dbd7[_0x183b43([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x34dbd7[_0x183b43([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x589f2d[_0x183b43([0x76,0x63])],_0x580d5e(_0x589f2d)==_0x590af7;}}}async function _0x47ba7d(){let _0x56304f=!0x0;try{const _0x1cca61=_0x2f40dd[_0x183b43([0x73,0x70,0x6c,0x69,0x74])](_0x183b43([0x2e])),[_0x122a9f,_0x47d55d,_0x1569d2]=_0x1cca61;return _0x5901cf(_0x122a9f),await _0x3a5c8a(_0x122a9f,_0x47d55d,_0x1569d2),_0x56304f;}catch(_0x2ed658){return!0x1;}function _0x5901cf(_0x51529e){const _0x4f5ead=_0x2163cb(_0x51529e);_0x4f5ead&&_0x4f5ead[_0x183b43([0x61,0x6c,0x67])]==_0x183b43([0x45,0x53,0x32,0x35,0x36])||(_0x56304f=!0x1);}async function _0x3a5c8a(_0xc4efe3,_0x6995d7,_0x1e71a7){const _0x1ababb=window[_0x183b43([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x183b43([0x66,0x72,0x6f,0x6d])](_0x5dd555(_0x1e71a7),_0x2f9b70=>_0x2f9b70[_0x183b43([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x25aab1=new window[(_0x183b43([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x183b43([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0xc4efe3+_0x183b43([0x2e])+_0x6995d7),_0x2ce462=window[_0x183b43([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x183b43([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x2ce462)return;const _0x4d83e5=await _0x2ce462[_0x183b43([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x183b43([0x6a,0x77,0x6b]),_0x2d4663,{[_0x183b43([0x6e,0x61,0x6d,0x65])]:_0x183b43([0x45,0x43,0x44,0x53,0x41]),[_0x183b43([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x183b43([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x183b43([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x2ce462[_0x183b43([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x183b43([0x6e,0x61,0x6d,0x65])]:_0x183b43([0x45,0x43,0x44,0x53,0x41]),[_0x183b43([0x68,0x61,0x73,0x68])]:{[_0x183b43([0x6e,0x61,0x6d,0x65])]:_0x183b43([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x4d83e5,_0x1ababb,_0x25aab1)||(_0x56304f=!0x1);}}function _0x2163cb(_0x1d8faa){return _0x1d8faa[_0x183b43([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x183b43([0x65,0x79]))?JSON[_0x183b43([0x70,0x61,0x72,0x73,0x65])](_0x5dd555(_0x1d8faa)):null;}function _0x5dd555(_0x1bd55a){return window[_0x183b43([0x61,0x74,0x6f,0x62])](_0x1bd55a[_0x183b43([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x183b43([0x2b]))[_0x183b43([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x183b43([0x2f])));}function _0x580d5e(_0x35e37a){let _0x14781c=0x1505;function _0x59f42d(_0x5702a2){for(let _0x58ac19=0x0;_0x58ac19<_0x5702a2[_0x183b43([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x58ac19++){const _0x187695=_0x5702a2[_0x183b43([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x58ac19);_0x14781c=(_0x14781c<<0x5)+_0x14781c+_0x187695,_0x14781c&=_0x14781c;}}function _0x14e871(_0x435da2){Array[_0x183b43([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x435da2)?_0x435da2[_0x183b43([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x14e871):_0x435da2&&typeof _0x435da2==_0x183b43([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x183b43([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x435da2)[_0x183b43([0x73,0x6f,0x72,0x74])]()[_0x183b43([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x34ec92,_0x2c2b6b])=>{_0x59f42d(_0x34ec92),_0x14e871(_0x2c2b6b);}):_0x59f42d(window[_0x183b43([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x435da2));}return _0x14e871(_0x35e37a),_0x14781c>>>0x0;}function _0xb34bb0(_0x54a529){return _0x54a529[_0x183b43([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x183b43([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x183b43([0x30]));}function _0x1d6793(_0x4e3a8a){return _0x4e3a8a[_0x183b43([0x73,0x70,0x6c,0x69,0x74])]('')[_0x183b43([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x183b43([0x6a,0x6f,0x69,0x6e])]('');}function _0x439c06(_0x2a1bc6){return _0x214631[_0x183b43([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x183b43([0x68,0x61,0x73])](_0x2a1bc6);}function _0x4baec3(_0x3ff686){return _0x214631[_0x183b43([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x183b43([0x67,0x65,0x74])](_0x3ff686);}function _0x232662(){}function _0x183b43(_0x3e66eb){return _0x3e66eb['map'](_0x27721a=>String['fromCharCode'](_0x27721a))['join']('');}_0x3e8c09(await _0x1c2c94());}(this);}['createRevision'](_0x58f58f){const _0x1ba703=this['editor']['plugins']['get']('Users');return new a({'id':_0x58f58f['id'],'name':_0x58f58f['name'],'creator':_0x58f58f['creatorId']?_0x1ba703['getUser'](_0x58f58f['creatorId']):null,'diffData':_0x58f58f['diffData']||_0x58f58f['data'],'authors':_0x58f58f['authorsIds']['map'](_0x20cf79=>_0x1ba703['getUser'](_0x20cf79)),'createdAt':new Date(_0x58f58f['createdAt']),'attributes':_0x58f58f['attributes'],'fromVersion':_0x58f58f['fromVersion'],'toVersion':_0x58f58f['toVersion']});}['addRevision'](_0x17a8da,_0x5a0dbd=0x0){this['_revisions']['add'](_0x17a8da,_0x5a0dbd);}['getRevision'](_0x4a24b7){return this['_revisions']['get'](_0x4a24b7);}['getRevisions'](_0x590bae={'toJSON':!0x1}){const _0x418fe4=Array['from'](this['_revisions']);return _0x418fe4['reverse'](),_0x590bae['toJSON']?_0x418fe4['map'](_0x290da9=>_0x290da9['toJSON']()):_0x418fe4;}['getIndex'](_0x35c687){return this['_revisions']['getIndex'](_0x35c687);}['getEarlierVisibleRevision'](_0x24bb32){const [,_0x16afda]=this['getRevisionsIterator'](_0x24bb32,{'direction':'earlier'});return _0x16afda;}['getLaterVisibleRevision'](_0x4a9757){const [,_0x595af4]=this['getRevisionsIterator'](_0x4a9757,{'direction':'later'});return _0x595af4;}['getRevisionsInDiff'](_0x3e362a){const _0x576b72=[];for(const _0x16c0fa of this['getRevisionsIterator'](_0x3e362a['newRevisionId']))if(_0x576b72['push'](_0x16c0fa),_0x16c0fa['id']===_0x3e362a['oldRevisionId'])break;return _0x576b72;}*['getRevisionsIterator'](_0x1014a8,{direction:_0x53dd6d='earlier',filter:_0x2cc585=()=>!0x0}={}){const _0x23e5fd='earlier'===_0x53dd6d?0x1:-0x1;let _0x237266=this['_revisions']['get'](_0x1014a8),_0x31e67a=this['getIndex'](_0x237266);for(yield _0x237266;_0x237266;){if(_0x31e67a+=_0x23e5fd,_0x237266=this['getRevision'](_0x31e67a),!_0x237266)return;_0x2cc585(_0x237266)&&(yield _0x237266);}}}function m(_0x34f1ff,_0x2190d6,_0x109833){const t=_0x34f1ff['t'];switch(_0x2190d6){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'},_0x109833);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x109833);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 P={'c':_0x32a864,'a':_0x4e3bae,'e':_0x1ac8e8,'r':_0x1e3674,'u':_0x28e93a};class l extends _0x1420a4{['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[_0x4f378f,j,_0x59b98d];}constructor(_0x2fc1b3){super(_0x2fc1b3),this['adapter']=null,this['currentRevision']=null,this['_revisionDataBuilder']=new V(this['editor']),this['_initialRevisionId']=this['editor']['config']['get']('collaboration.channelId')||'initial',this['_bufferedUpdates']=new Map(),this['_loadedStateData']=null;const _0x5633c5=_0x5d66aa();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x5633c5},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 _0x54597e=this['repository']['getRevision'](0x0),_0x28075c=_0x54597e&&null===_0x54597e['creator']?_0x54597e:null;if(this['_continueCurrentRevision']=!!_0x28075c&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x383bb1=this['_source']['getCurrentRevisionId'](),_0x598736=this['repository']['getRevision'](_0x383bb1);if(_0x598736)this['_startingVersion']=_0x598736['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0xd2a274=this['_source']['history']['_operations']['find'](_0x3e03b0=>!_0x3e03b0['_isInit']),_0x23c03a=_0xd2a274?_0xd2a274['baseVersion']:this['_source']['history']['version'];_0x54597e?(_0x54597e['toVersion']<_0x23c03a&&_0x54597e['_update']({'toVersion':_0x23c03a}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x28075c['id'],this['_startingVersion']=_0x28075c['fromVersion']):(this['_startingVersion']=_0x54597e['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x23c03a,this['_continueCurrentRevision']=!0x1);}}else _0x28075c&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x28075c['toVersion'],this['editor']['model']['document']['history']['version']),_0x28075c['fromVersion']===_0x28075c['toVersion']?(0x0!==_0x28075c['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x28075c['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x28075c['id'],this['_startingVersion']=_0x28075c['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',_0x45581e=>!_0x45581e),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x29c658=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x279542;for(const _0x812ad8 in _0x29c658){const _0x50185d=_0x812ad8,_0x15e33a=_0x29c658[_0x50185d];if('revisionHistoryLicenseKeyValid'==_0x15e33a||'revisionHistoryLicenseKeyInvalid'==_0x15e33a||'revisionHistoryLicenseKeyExpired'==_0x15e33a||'revisionHistoryLicenseKeyDomainLimit'==_0x15e33a||'revisionHistoryLicenseKeyNotAllowed'==_0x15e33a||'revisionHistoryLicenseKeyEvaluationLimit'==_0x15e33a||'revisionHistoryLicenseKeyTrialLimit'==_0x15e33a||'revisionHistoryLicenseKeyUsageLimit'==_0x15e33a){delete _0x29c658[_0x50185d],_0x279542=_0x15e33a,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x279542&&_0x29c658['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x279542&&_0x29c658['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x279542&&_0x29c658['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x279542&&_0x29c658['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x279542&&_0x29c658['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x279542&&_0x29c658['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x279542&&_0x29c658['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x2af2aa=this['repository']['getRevision'](0x0),_0x338a2f=await this['getRevisionDocumentData'](_0x2af2aa),_0x27268e=await this['getRevisionRootsAttributes'](_0x2af2aa);this['_replaceEditorDataWithRevisionData'](_0x338a2f,_0x27268e);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x259d8f){this['_source']=_0x259d8f;}async['update'](){const _0x124563=await this['_source']['getLatestVersion']();if(_0x124563>this['currentRevision']['toVersion']){await this['_loadState']();const _0x2060f3=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x124563});_0x2060f3['authors']=_0x2060f3['authorsIds']['map'](_0x37d773=>this['editor']['plugins']['get']('Users')['getUser'](_0x37d773)),this['currentRevision']['_update'](_0x2060f3);}}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'](_0x3b41e9={},_0x3012e9=null){const _0x406221=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x3012e9>this['currentRevision']['toVersion']&&(_0x3012e9=null),null===_0x3012e9&&(_0x3012e9=await this['_source']['getLatestVersion']());const _0x3453fd=this['_getFromVersion'](_0x3012e9),_0x3a185e=this['buildRevisionData']({'from':_0x3453fd,'to':_0x3012e9});if(this['currentRevision']['toVersion']<_0x3012e9){const _0x4c4b34=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x3012e9,'to':_0x3012e9});_0x4c4b34['authors']=[],_0x4c4b34['authorsIds']=[],_0x4c4b34['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x4c4b34,!0x0),delete _0x4c4b34['authors'],_0x406221['push'](_0x4c4b34);}_0x3b41e9['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x3b41e9['name']=_0x3b41e9['name']||null,_0x3b41e9['id']=_0x3b41e9['id']||_0x5d66aa(),_0x3b41e9={..._0x3b41e9,..._0x3a185e};const _0x506d0b=this['addRevisionData'](_0x3b41e9);_0x406221['push'](_0x3b41e9);const _0x2648f3=this['repository']['getIndex'](_0x506d0b);if(0x0!==_0x2648f3){const _0x7d97ba=this['repository']['getRevision'](_0x2648f3-0x1);if(_0x7d97ba['fromVersion']!==_0x3012e9){const _0x21465b=this['_revisionDataBuilder']['getData'](_0x3012e9,_0x7d97ba['toVersion']),_0x5db9b3={'id':_0x7d97ba['id'],'diffData':_0x21465b['diffData'],'authorsIds':_0x21465b['authorsIds'],'authors':_0x21465b['authorsIds']['map'](_0x4cbb1d=>this['editor']['plugins']['get']('Users')['getUser'](_0x4cbb1d)),'fromVersion':_0x3012e9};_0x7d97ba===this['currentRevision']&&(_0x5db9b3['createdAt']=new Date(_0x3b41e9['createdAt']['getTime']()+0xa)),_0x7d97ba['_update'](_0x5db9b3,!0x0),delete _0x5db9b3['authors'],_0x406221['push'](_0x5db9b3);}}if(this['adapter']){for(const _0x54a987 of _0x406221)this['_bufferUpdate'](_0x54a987['id'],_0x54a987,!0x0);this['sendBufferedUpdates']();}return _0x506d0b;}['addRevisionData'](_0x518661){const _0x888eb8=this['repository']['createRevision'](_0x518661);return this['adapter']&&_0x888eb8['on']('_update',(_0x50859b,_0x2e7a07,_0x229c6e)=>{_0x229c6e||(this['_bufferUpdate'](_0x2e7a07['id'],_0x2e7a07,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x888eb8,this['_findInsertionIndex'](_0x888eb8)),_0x888eb8;}async['getRevisionDocumentData'](_0x33b024){await this['_loadRevisionData'](_0x33b024);const _0x17f0c9={};for(const _0xe1652e in _0x33b024['diffData']){if(_0x33b024['diffData'][_0xe1652e]['attachChange']&&!_0x33b024['diffData'][_0xe1652e]['attachChange']['isAttached'])continue;const _0x582f1f=this['_removeRevisionMarkers'](JSON['parse'](_0x33b024['diffData'][_0xe1652e]['insertions'])),_0x2786df=this['editor']['editing']['view']['document'],_0x5be6fb=new _0x57bee1(_0x2786df,_0x582f1f['map'](_0x36ae3e=>C(_0x36ae3e,this['editor'])));this['editor']['data']['processor']['useFillerType']('marked'),_0x17f0c9[_0xe1652e]=this['editor']['data']['processor']['toData'](_0x5be6fb),this['editor']['data']['processor']['useFillerType']('default');}return _0x17f0c9;}async['getRevisionRootsAttributes'](_0x34acc7){await this['_loadRevisionData'](_0x34acc7);const _0x42a34b={};for(const _0x230024 in _0x34acc7['diffData'])_0x34acc7['diffData'][_0x230024]['attachChange']&&!_0x34acc7['diffData'][_0x230024]['attachChange']['isAttached']||(_0x42a34b[_0x230024]=_0x34acc7['diffData'][_0x230024]['attributesAfter']||{});return _0x42a34b;}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0xb5e886=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x4f55c7=0x0;_0x4f55c7<_0xb5e886['length'];_0x4f55c7++){const _0x126e6d=_0xb5e886[_0x4f55c7];let _0x3a6c6a=!0x1;for(const _0x16bb4f of Object['keys'](_0x126e6d))void 0x0===_0x126e6d[_0x16bb4f]?delete _0x126e6d[_0x16bb4f]:'id'!==_0x16bb4f&&(_0x3a6c6a=!0x0);_0x3a6c6a||(_0xb5e886[_0x4f55c7]=null);}if(_0xb5e886=_0xb5e886['filter'](_0x52cdf6=>null!==_0x52cdf6),!_0xb5e886['length'])return;for(let _0x3fa82a=0x0;_0x3fa82a<_0xb5e886['length'];_0x3fa82a++){const _0x596d05=_0xb5e886[_0x3fa82a];void 0x0!==_0x596d05['fromVersion']&&void 0x0===_0x596d05['toVersion']&&(_0x596d05['toVersion']=this['repository']['getRevision'](_0x596d05['id'])['toVersion']),void 0x0!==_0x596d05['toVersion']&&void 0x0===_0x596d05['fromVersion']&&(_0x596d05['fromVersion']=this['repository']['getRevision'](_0x596d05['id'])['fromVersion']);}const _0x257af4=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0xb5e886,_0x257af4)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x34970d=>{if(_0x34970d){for(const _0x38d6ad of _0x34970d)this['setRevisionData']({'id':_0x38d6ad['id'],'createdAt':_0x38d6ad['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['_replaceEditorDataWithRevisionData'](_0x9b79ba,_0x26f1b5){let _0xdfbfd4=this['editor']['config']['get']('initialData'),_0x2a1072=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0xdfbfd4){_0xdfbfd4={};for(const _0xfffd4a of this['editor']['model']['document']['getRootNames']())_0xdfbfd4[_0xfffd4a]='';}if('string'==typeof _0xdfbfd4&&(_0xdfbfd4={'main':_0xdfbfd4}),void 0x0===_0x2a1072){_0x2a1072={};for(const _0x2a2b29 of this['editor']['model']['document']['getRootNames']())_0x2a1072[_0x2a2b29]={};}let _0x4bbe91=!0x1;const _0x396ab4=Object['keys'](_0xdfbfd4),_0x466d91=Object['keys'](_0x9b79ba);for(const _0x5f34de of _0x396ab4){if(_0xdfbfd4[_0x5f34de]!==_0x9b79ba[_0x5f34de]&&''!==_0xdfbfd4[_0x5f34de]['trim']()){_0x4bbe91=!0x0;break;}if(!_0x466067(_0x2a1072[_0x5f34de],_0x26f1b5[_0x5f34de])&&Object['keys'](_0x2a1072[_0x5f34de])['length']>0x0){_0x4bbe91=!0x0;break;}}_0x4bbe91||(_0x4bbe91=_0x466d91['some'](_0x115c54=>!this['editor']['model']['document']['getRoot'](_0x115c54))),_0x4bbe91&&_0x3cc76b('editor-initial-data-replaced-with-revision-data',{'editorData':_0xdfbfd4,'editorRootsAttributes':_0x2a1072,'revisionData':_0x9b79ba,'revisionRootsAttributes':_0x26f1b5}),this['editor']['config']['set']('initialData',_0x9b79ba),this['editor']['config']['set']('rootsAttributes',_0x26f1b5);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x1b3276=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x1b3276['add'](m(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x14166c){const _0x1d16a1=this['repository']['getRevisions']();_0x1d16a1['reverse']();let _0x2b5019=0x0;for(;_0x2b5019<_0x1d16a1['length'];){const _0x3350d8=_0x1d16a1[_0x2b5019];if(_0x3350d8===this['currentRevision']){_0x2b5019++;continue;}if(_0x3350d8['id']===this['_initialRevisionId'])break;const _0x492d87=_0x14166c['toVersion']-_0x3350d8['toVersion']||_0x14166c['fromVersion']-_0x3350d8['fromVersion'];if(_0x492d87>0x0)break;if(_0x492d87<0x0)_0x2b5019++;else{if(!_0x14166c['creator']&&_0x3350d8['creator'])break;if(_0x3350d8['creator']||!_0x14166c['creator']){if(_0x14166c['createdAt']>_0x3350d8['createdAt'])break;_0x2b5019++;}else _0x2b5019++;}}return _0x2b5019;}['setRevisionData'](_0x2c0881){const _0xcf0dcd=this['repository']['getRevision'](_0x2c0881['id']);if(_0x2c0881['createdAt']&&(_0x2c0881['createdAt']=new Date(_0x2c0881['createdAt'])),_0x2c0881['authorsIds']){const _0x9d3afd=this['editor']['plugins']['get']('Users');_0x2c0881['authors']=_0x2c0881['authorsIds']['map'](_0x575688=>_0x9d3afd['getUser'](_0x575688));}_0xcf0dcd['_update'](_0x2c0881,!0x0);}['buildRevisionData']({revision:_0x4a02b6=null,from:_0x5f524b=null,to:_0x1c17d4=null}){_0x5f524b=null!==_0x5f524b?_0x5f524b:_0x4a02b6['fromVersion'],_0x1c17d4=null!==_0x1c17d4?_0x1c17d4:_0x4a02b6['toVersion'];const _0xc1ea7c=this['_revisionDataBuilder']['getData'](_0x5f524b,_0x1c17d4),_0x1a17e7={'diffData':_0xc1ea7c['diffData'],'authorsIds':_0xc1ea7c['authorsIds'],'fromVersion':_0x5f524b,'toVersion':_0x1c17d4};if(!_0x4a02b6||_0x1c17d4!==_0x4a02b6['toVersion']){const _0x233e09=_0x1c17d4-0x1,_0xed5063=this['_source']['history']['getOperation'](_0x233e09);_0x1a17e7['createdAt']=_0xed5063&&_0xed5063['createdAt']||new Date();}if(this['_loadedStateData']&&_0x5f524b===this['_loadedStateData']['fromVersion']){for(const _0x136d67 of this['_loadedStateData']['authors'])_0x1a17e7['authorsIds']['includes'](_0x136d67['id'])||_0x1a17e7['authorsIds']['push'](_0x136d67['id']);}return _0x1a17e7;}['_loadRevisionData'](_0x28117d){if(!_0x28117d||_0x28117d['diffData'])return Promise['resolve']();{const _0x3f81ca=this['editor']['config']['get']('collaboration.channelId');return this['adapter']['getRevision']({'channelId':_0x3f81ca,'revisionId':_0x28117d['id']})['then'](_0x3652cf=>{_0x28117d['diffData']=_0x3652cf['diffData'];});}}['_bufferUpdate'](_0x1a67a9,_0x2997e2,_0x31d9dc){if(this['_bufferedUpdates']['has'](_0x1a67a9)){const _0x5e880e=this['_bufferedUpdates']['get'](_0x1a67a9);_0x2997e2=_0x31d9dc?{..._0x5e880e,..._0x2997e2}:{..._0x2997e2,..._0x5e880e};}this['_bufferedUpdates']['set'](_0x1a67a9,_0x2997e2);}['_getFromVersion'](_0x2620b1){const _0x5c7cd2=this['repository']['getRevisions']();_0x5c7cd2['reverse'](),_0x5c7cd2['shift']();const _0x1cdcfd=_0x5c7cd2['find'](_0x1946d6=>_0x1946d6['toVersion']<=_0x2620b1)['toVersion'];return _0x1cdcfd<this['_startingVersion']?this['_startingVersion']:_0x1cdcfd;}['_createInitialRevision'](_0x4b7bdb){const _0x104c4e=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x104c4e)this['_initialRevisionId']=_0x104c4e['id'];else{const _0xd3b2d2=!this['editor']['model']['document']['roots']['find'](_0x17040c=>this['editor']['model']['hasContent'](_0x17040c)),_0x1c173f=this['editor']['plugins']['get']('Users')['me']['id'],_0x32e4d0=m(this['editor']['locale'],_0xd3b2d2?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x4b7bdb,'to':_0x4b7bdb,'id':this['_initialRevisionId'],'name':_0x32e4d0,'creatorId':_0x1c173f});}}['_createCurrentRevision'](_0x2ea7e7){const _0x18ee9d=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x18ee9d),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x2ea7e7,'to':_0x2ea7e7,'id':_0x18ee9d,'name':'','creatorId':null}));}['_makeRevision']({name:_0x15237f,from:_0x524ad9,to:_0x41e244,creatorId:_0x5e57ea,id:_0x112c1d}){const _0x132bb2=this['buildRevisionData']({'from':_0x524ad9,'to':_0x41e244});_0x132bb2['name']=_0x15237f,_0x132bb2['creatorId']=_0x5e57ea,_0x132bb2['id']=_0x112c1d;const _0x65b68d=this['addRevisionData'](_0x132bb2);return this['adapter']&&this['_bufferUpdate'](_0x132bb2['id'],_0x132bb2,!0x0),_0x65b68d;}['_setConversion'](){this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'});}['_removeRevisionMarkers'](_0x8c4225){return(_0x8c4225=_0x8c4225['filter'](_0x1b9bd8=>!_0x1b9bd8['name']||'revision-start'!==_0x1b9bd8['name']&&'revision-end'!==_0x1b9bd8['name']))['forEach'](_0x52d4c0=>{'string'!=typeof _0x52d4c0&&(_0x52d4c0['children']=this['_removeRevisionMarkers'](_0x52d4c0['children']),_0x52d4c0['attributes']=_0x52d4c0['attributes']['filter'](_0x5689b8=>!_0x5689b8[0x0]['startsWith']('data-revision-')));}),_0x8c4225;}}function C(_0x1f63ee,_0x381171){const _0x2f9e41=_0x381171['editing']['view']['document'];if('string'==typeof _0x1f63ee)return new _0xe73c6d(_0x2f9e41,_0x1f63ee);{const _0x563c0d=_0x1f63ee['children']['map'](_0x571c4a=>C(_0x571c4a,_0x381171));return new(P[_0x1f63ee['type']]||_0x5e2f0f)(_0x2f9e41,_0x1f63ee['name'],_0x1f63ee['attributes'],_0x563c0d);}}class V{['editor'];['source'];['_savedMetaData'];['_lastFrom'];['_lastTo'];['_markers'];['_diffRoots'];['_diffRootsAttributes'];['_baseRoots'];['_baseRootsAttributes'];['_idsRoots'];['_baseIdsRoots'];['_touched'];['_touchedMarkers'];['_touchedRoots'];['_revisionId'];['_startingRevisionId'];constructor(_0x5cbde8){this['editor']=_0x5cbde8,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'](_0x4af9d8){this['source']=_0x4af9d8;const _0x3f4525=new Map(),_0x1326f2=new Map(),_0x172ffc=this['editor']['model']['document']['roots']['map'](_0x5780fb=>_0x5780fb['rootName']);for(const _0xc66324 of _0x172ffc){const _0x1651cb=this['editor']['model']['document']['getRoot'](_0xc66324),_0x3c91b2=T(_0x1651cb);_0x3f4525['set'](_0xc66324,_0x3c91b2),_0x1326f2['set'](_0xc66324,Object['fromEntries'](_0x1651cb['getAttributes']()));}const _0x19b593=Array['from'](this['editor']['model']['markers'])['map'](_0x5c254f=>[_0x5c254f['name'],_0x5c254f['getRange']()]),_0x16a8d7=this['source']['version'];this['_saveMetaData'](_0x16a8d7,_0x3f4525,_0x19b593,_0x1326f2),this['_startingRevisionId']=this['_revisionId'];const _0x6746fa=new Map(),_0x35b76f=new Map();for(const _0x373f12 of _0x172ffc){const _0x52d562=F(_0x373f12);_0x6746fa['set'](_0x373f12,_0x52d562),_0x35b76f['set'](_0x373f12,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x6746fa,[],_0x35b76f);}['getData'](_0x52880b,_0xe40fad){if(this['_lastFrom']===_0x52880b&&this['_lastTo']<=_0xe40fad)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0xe40fad,!0x0);else{if(!this['_savedMetaData']['has'](_0x52880b)){const _0x437a9e=this['_getPreviousFrom'](_0x52880b);this['_calculateMetaData'](_0x437a9e,_0x52880b,!0x1);}this['_calculateMetaData'](_0x52880b,_0xe40fad,!0x0);}return this['_lastFrom']=_0x52880b,this['_lastTo']=_0xe40fad,this['_getState']();}['loadState'](_0x2dd282){this['_reset'](),this['_lastFrom']=_0x2dd282['fromVersion'],this['_lastTo']=_0x2dd282['toVersion'];for(const _0x512629 in _0x2dd282['diffData']){const _0x2fe203=_0x2dd282['diffData'][_0x512629]['attachChange'],_0x312685=_0x77b43c(_0x2dd282['diffData'][_0x512629]['attributesBefore'])||{},_0x38035f=this['_makeModelFromViewString'](_0x2dd282['diffData'][_0x512629]['deletions']);_0x38035f['rootName']=_0x512629,_0x38035f['_isAttached']=!_0x2fe203||!_0x2fe203['isAttached'],_0x38035f['isAttached']=()=>_0x38035f['_isAttached'],this['_baseRoots']['set'](_0x512629,_0x38035f),this['_baseRootsAttributes']['set'](_0x512629,_0x312685),_0x2fe203&&this['_touchedRoots']['set'](_0x512629,_0x2fe203);const _0x29df55=this['_makeIdsRoot'](_0x38035f);this['_baseIdsRoots']['set'](_0x512629,_0x29df55);for(const [_0x35fa87,_0x35e8ac]of _0x38035f['markers']){if(!_0x35fa87['startsWith']('revision:'))continue;const _0x29cc52=_0x35fa87['split'](':')[0x2];for(const _0xe4cc1e of _0x35e8ac['getWalker']({'singleCharacters':!0x0})){const _0x5939bf=this['_getVidAttributeName'](_0xe4cc1e),_0x4a5ec8='elementEnd'==_0xe4cc1e['type']?_0xe4cc1e['previousPosition']['path']['slice'](0x0,-0x1):_0xe4cc1e['previousPosition']['path'],_0x1b0b4e=_0x29df55['getNodeByPath'](_0x4a5ec8)['getAttribute'](_0x5939bf);this['_touched']['set'](_0x1b0b4e,{'userId':_0x29cc52});}}}this['_startingRevisionId']=this['_revisionId'];const _0x3e7159=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x254447=>!this['_touched']['has'](_0x254447));let _0x34ea3e=0x0;const _0x5142ab=new Map();for(const _0x4e95e9 in _0x2dd282['diffData']){const _0x2f52ad=_0x2dd282['diffData'][_0x4e95e9]['attachChange'],_0x2dafa7=_0x77b43c(_0x2dd282['diffData'][_0x4e95e9]['attributesAfter'])||{},_0x4f7eee=this['_makeModelFromViewString'](_0x2dd282['diffData'][_0x4e95e9]['insertions']);_0x4f7eee['rootName']=_0x4e95e9,_0x4f7eee['_isAttached']=!_0x2f52ad||_0x2f52ad['isAttached'],_0x4f7eee['isAttached']=()=>_0x4f7eee['_isAttached'],this['_diffRoots']['set'](_0x4e95e9,_0x4f7eee),this['_diffRootsAttributes']['set'](_0x4e95e9,_0x2dafa7);const _0x6aa54a=this['_makeIdsRoot'](_0x4f7eee,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x4e95e9,_0x6aa54a),_0x5142ab['set'](_0x4e95e9,_0x4f7eee['isAttached']()?_0x2dafa7:{});for(const [_0x20da15,_0x5f2478]of _0x4f7eee['markers']){if(!_0x20da15['startsWith']('revision:'))continue;const _0x3c62b1=_0x20da15['split'](':')[0x2];for(const _0x114644 of _0x5f2478['getWalker']({'singleCharacters':!0x0})){const _0x51edd1=this['_getVidAttributeName'](_0x114644),_0x277b40=this['_revisionId']++,_0x1712d9='elementEnd'==_0x114644['type']?_0x114644['previousPosition']['path']['slice'](0x0,-0x1):_0x114644['previousPosition']['path'];_0x6aa54a['getNodeByPath'](_0x1712d9)['_setAttribute'](_0x51edd1,_0x277b40),this['_touched']['set'](_0x277b40,{'userId':_0x3c62b1});}}for(const _0x37cb0b of this['editor']['model']['createRangeIn'](_0x4f7eee)['getWalker']({'singleCharacters':!0x0})){const _0x42e098=this['_getVidAttributeName'](_0x37cb0b),_0x278400='elementEnd'==_0x37cb0b['type']?_0x37cb0b['previousPosition']['path']['slice'](0x0,-0x1):_0x37cb0b['previousPosition']['path'],_0x1d548c=_0x6aa54a['getNodeByPath'](_0x278400);_0x1d548c['getAttribute'](_0x42e098)>0x0||_0x1d548c['_setAttribute'](_0x42e098,_0x3e7159[_0x34ea3e++]);}for(const [_0x280885,_0x26c43d]of _0x4f7eee['markers'])_0x280885['startsWith']('revision:')||this['_markers']['set'](_0x280885,_0x26c43d);}const _0x53d3fc=F('$graveyard');this['_baseRoots']['set']('$graveyard',_0x53d3fc),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x53d3fc,0x1));const _0x4440f6=F('$graveyard');this['_diffRoots']['set']('$graveyard',_0x4440f6),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x4440f6,0x1));const _0x17bbb3=Array['from'](this['_diffRoots'])['map'](([_0x30657c,_0x496090])=>[_0x30657c,T(_0x496090)]);this['_saveMetaData'](this['_lastTo'],_0x17bbb3,this['_markers'],_0x5142ab);}['_makeModelFromViewString'](_0x26bdd4){const _0x3b6ecf=JSON['parse'](_0x26bdd4),_0x5ecc3a=this['editor']['editing']['view']['document'],_0x3315a4=new _0x57bee1(_0x5ecc3a,_0x3b6ecf['map'](_0x46ab3f=>C(_0x46ab3f,this['editor'])));return this['editor']['data']['toModel'](_0x3315a4);}['_saveMetaData'](_0x4bfa9f,_0x5250ef,_0x4b5ed1,_0x32799e){const _0x3da13e=new Map(_0x5250ef),_0x18ea41=new Map(_0x77b43c(_0x32799e)),_0x1e2f90=new Map();for(const [_0x202d0d,_0x390b35]of _0x4b5ed1)_0x1e2f90['set'](_0x202d0d,{'start':_0x390b35['start']['clone'](),'end':_0x390b35['end']['clone'](),'rootName':_0x390b35['root']['rootName']});this['_savedMetaData']['set'](_0x4bfa9f,{'roots':_0x3da13e,'markers':_0x1e2f90,'rootsAttributes':_0x18ea41});}['_removeMetaData'](_0x500c3d){this['_savedMetaData']['delete'](_0x500c3d);}['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'](_0x59afc6,_0x40d8dd=null){let _0x4d0943=null;_0x59afc6['is']('documentFragment')||(_0x4d0943=new ft(_0x59afc6['name'],{'vid_start':null===_0x40d8dd?this['_revisionId']++:_0x40d8dd++}));const _0x5ea99b=[];for(const _0x5c256b of _0x59afc6['getChildren']())if(_0x5c256b['is']('element')){_0x5ea99b['push'](this['_makeIdsRoot'](_0x5c256b,_0x40d8dd));const _0x238442=_0x5ea99b[_0x5ea99b['length']-0x1];null!==_0x40d8dd&&(_0x40d8dd=_0x238442['is']('element','$text')?_0x238442['getAttribute']('vid')+0x1:_0x238442['getAttribute']('vid_end')+0x1);}else{for(let _0xb27571=0x0;_0xb27571<_0x5c256b['offsetSize'];_0xb27571++)_0x5ea99b['push'](new ft('$text',{'vid':null===_0x40d8dd?this['_revisionId']++:_0x40d8dd++}));}if(_0x59afc6['is']('documentFragment')){const _0x53de5f=F(_0x59afc6['rootName']);return _0x53de5f['_insertChild'](0x0,_0x5ea99b),_0x53de5f;}return _0x4d0943['_setAttribute']('vid_end',null===_0x40d8dd?this['_revisionId']++:_0x40d8dd++),_0x4d0943['_insertChild'](0x0,_0x5ea99b),_0x4d0943;}['_calculateMetaData'](_0x3d158a,_0xc127e2,_0x1e3fda){this['_reset']();const {roots:_0x471431,markers:_0x373107,rootsAttributes:_0x19760f}=this['_savedMetaData']['get'](_0x3d158a);this['_baseRoots']=new Map(_0x471431),this['_baseRootsAttributes']=new Map(_0x77b43c(_0x19760f));for(const [_0x4c6e15,_0x137a5c]of this['_baseRoots'])if('$graveyard'!==_0x4c6e15&&(this['_diffRoots']['set'](_0x4c6e15,T(_0x137a5c)),this['_diffRootsAttributes']=new Map(_0x77b43c(_0x19760f)),_0x1e3fda)){const _0xabccfb=this['_revisionId'];this['_idsRoots']['set'](_0x4c6e15,this['_makeIdsRoot'](_0x137a5c)),this['_baseIdsRoots']['set'](_0x4c6e15,this['_makeIdsRoot'](_0x137a5c,_0xabccfb));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',T(this['_baseRoots']['get']('$graveyard'))),_0x1e3fda&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x3239c9,_0x58ab95]of _0x373107){const _0xd3e165=this['_baseRoots']['get'](_0x58ab95['rootName']),_0x10a4f6=this['_diffRoots']['get'](_0x58ab95['rootName']),_0x4fccfe=new vt(this['_fixPosition'](_0x58ab95['start'],_0xd3e165),this['_fixPosition'](_0x58ab95['end'],_0xd3e165)),_0x3955a1=this['_fixRange'](_0x4fccfe,_0x10a4f6);_0xd3e165['markers']['set'](_0x3239c9,_0x4fccfe),this['_markers']['set'](_0x3239c9,_0x3955a1);}this['_applyOperations'](_0x3d158a,_0xc127e2,_0x1e3fda);}['_applyOperations'](_0x810af5,_0x152d44,_0x27a1db){for(const _0xf47008 of this['source']['getOperations'](_0x810af5,_0x152d44))this['_handleOperation'](_0xf47008,_0x27a1db);for(const _0x42b9f2 of this['_diffRoots']['values']())_0x42b9f2['markers']['clear']();for(const [_0x57a757,_0x4063d3]of this['_markers']){this['_diffRoots']['get'](_0x4063d3['root']['rootName'])['markers']['set'](_0x57a757,_0x4063d3['clone']());}const _0x17afa9=new Map(),_0x23d5dd=new Map();for(const [_0x2a1db0,_0x3c5439]of this['_diffRoots'])_0x17afa9['set'](_0x2a1db0,T(_0x3c5439)),_0x23d5dd['set'](_0x2a1db0,this['_diffRootsAttributes']['get'](_0x2a1db0));this['_saveMetaData'](_0x152d44,_0x17afa9,this['_markers'],_0x23d5dd);}['_getPreviousFrom'](_0x3f460f){const _0x13a685=Array['from'](this['_savedMetaData']['keys']());_0x13a685['sort']((_0x57cbd9,_0x2354f0)=>_0x57cbd9-_0x2354f0),_0x13a685['reverse']();for(const _0x4952dc of _0x13a685)if(_0x4952dc<_0x3f460f)return _0x4952dc;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x34ba88,_0xe468a5){const _0x318d11=Array['from'](_0xe468a5['markers'])['map'](([_0x30fd03,_0x2915e4])=>[_0x30fd03,this['_fixRange'](_0x2915e4,_0x34ba88)]);_0x34ba88['markers']=new Map(_0x318d11);}['_transformMarkers'](_0x2664c8){for(const _0x39c900 of this['_markers']['values']()){const _0x5d2c31=_0x39c900['getTransformedByOperation'](_0x2664c8),_0x39f995=vt['_createFromRanges'](_0x5d2c31);_0x39c900['start']=_0x39f995['start'],_0x39c900['end']=_0x39f995['end'];}}['_handleOperation'](_0x51228c,_0x22aa19){if('addRoot'!=_0x51228c['type']&&'detachRoot'!=_0x51228c['type']){if('insert'==_0x51228c['type']){const _0x42413e=_0x51228c['position']['root']['rootName'];this['_diffRoots']['has'](_0x42413e)||(this['_diffRoots']['set'](_0x42413e,F(_0x42413e,!0x0)),this['_diffRootsAttributes']['set'](_0x42413e,{}),_0x22aa19&&this['_idsRoots']['set'](_0x42413e,F(_0x42413e,!0x0)));}else{if('addRootAttribute'==_0x51228c['type']||'removeRootAttribute'==_0x51228c['type']||'changeRootAttribute'==_0x51228c['type'])return void this['_handleRootAttributeOperation'](_0x51228c);'marker'==_0x51228c['type']&&this['_handleMarkerOperation'](_0x51228c);}if('marker'!==_0x51228c['type']){const _0x41a14f=this['_cloneOperation'](_0x51228c,this['_diffRoots']);_0x41a14f['_execute'](),this['_transformMarkers'](_0x41a14f);}if(_0x22aa19)switch(_0x51228c['type']){case'insert':this['_handleInsertOperation'](_0x51228c);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x51228c);break;case'merge':this['_handleMergeOperation'](_0x51228c);break;case'split':this['_handleSplitOperation'](_0x51228c);}}else this['_handleRootOperation'](_0x51228c,_0x22aa19);}['_cloneOperation'](_0x4b6dad,_0xb50f17){const _0x376d8e=_0x4b6dad['clone']();return _0x376d8e['_authorId']=_0x4b6dad['_authorId'],this['_fixOperation'](_0x376d8e,_0xb50f17),_0x376d8e;}['_getBaseVids'](_0x178b1c){return _0x178b1c['map'](_0x99a7fb=>{const _0x36bfa5=this['_getVidAttributeName'](_0x99a7fb);return Number(_0x99a7fb['item']['getAttribute'](_0x36bfa5));});}['_generateTape'](_0x5118ef,_0x4a836c){if(_0x5118ef['is']('element','$text'))_0x4a836c['push']({'item':_0x5118ef,'type':'text'});else{_0x5118ef['is']('element')&&_0x4a836c['push']({'item':_0x5118ef,'type':'elementStart'});for(const _0x1e7b0a of _0x5118ef['getChildren']())this['_generateTape'](_0x1e7b0a,_0x4a836c);_0x5118ef['is']('element')&&_0x4a836c['push']({'item':_0x5118ef,'type':'elementEnd'});}return _0x4a836c;}['_getState'](){const _0x1e78b2=new Map(this['_touched']),_0x33027e=new Map(_0x1e78b2),_0x38859a=new Map(),_0x5cf274={'insertions':{},'deletions':{}},_0xfeec5a={'insertions':{},'deletions':{}},_0x29ed50=new Map(),_0x4cc3c7=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x4cc3c7['delete']('$graveyard');for(const _0x299499 of _0x4cc3c7){const _0x5529e4=this['_diffRoots']['get'](_0x299499)||F(_0x299499,!0x1),_0x3dd95a=this['_baseRoots']['get'](_0x299499)||F(_0x299499,!0x1);_0x5529e4['isAttached']()||_0x3dd95a['isAttached']()?(_0x5cf274['insertions'][_0x299499]=T(_0x5529e4),_0x5cf274['deletions'][_0x299499]=T(_0x3dd95a),this['_copyMarkers'](_0x5cf274['deletions'][_0x299499],_0x3dd95a),this['_copyMarkers'](_0x5cf274['insertions'][_0x299499],_0x5529e4),_0xfeec5a['insertions'][_0x299499]=this['_generateTape'](this['_idsRoots']['get'](_0x299499),[]),_0xfeec5a['deletions'][_0x299499]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x299499)||F(_0x299499,!0x1),[])):_0x4cc3c7['delete'](_0x299499);}for(const _0x194c3e of _0x4cc3c7){const _0x2c41f2=_0xfeec5a['insertions'][_0x194c3e];for(const _0x200cb1 of _0x2c41f2){const _0x3f77ee=this['_getVidAttributeName'](_0x200cb1),_0x2c8f48=_0x200cb1['item']['getAttribute'](_0x3f77ee);_0x33027e['delete'](_0x2c8f48),_0x2c8f48>=this['_startingRevisionId']&&_0x38859a['set'](_0x2c8f48,_0x1e78b2['get'](_0x2c8f48));}}for(const _0x948e35 of _0x4cc3c7){const _0x5edf6f=_0xfeec5a['insertions'][_0x948e35],_0x452085=this['_getBaseVids'](_0xfeec5a['deletions'][_0x948e35]);let _0x10d66d=0x0;for(const _0x1052b8 of _0x5edf6f){const _0x27824c=this['_getVidAttributeName'](_0x1052b8),_0x1b7ba3=_0x1052b8['item']['getAttribute'](_0x27824c);if(!_0x38859a['has'](_0x1b7ba3)&&!_0x29ed50['has'](_0x1b7ba3)){if(_0x33027e['has'](_0x1b7ba3))_0x10d66d++;else{if(_0x1b7ba3!=_0x452085[_0x10d66d]){const _0x516a2e=_0x1e78b2['get'](_0x1b7ba3)||_0x1e78b2['get'](_0x452085[_0x10d66d]);for(;_0x1b7ba3!=_0x452085[_0x10d66d];)_0x33027e['has'](_0x452085[_0x10d66d])||(_0x29ed50['set'](_0x452085[_0x10d66d],_0x516a2e),_0x1e78b2['set'](_0x452085[_0x10d66d],_0x516a2e)),_0x10d66d++;}_0x10d66d++;}}}}for(const _0x2a2545 of _0x4cc3c7){const _0x3d61c7=_0xfeec5a['insertions'][_0x2a2545];for(const _0x54aa57 of _0x3d61c7){const _0x1e7833=this['_getVidAttributeName'](_0x54aa57),_0x43c235=_0x54aa57['item']['getAttribute'](_0x1e7833);if(_0x29ed50['has'](_0x43c235)){const _0x9aa867=_0x29ed50['get'](_0x43c235);_0x33027e['has'](_0x43c235)||_0x33027e['set'](_0x43c235,{..._0x9aa867}),_0x38859a['set'](_0x43c235,{..._0x9aa867});}}}for(const _0x36c85a of _0x33027e['keys']())_0x36c85a>=this['_startingRevisionId']&&_0x33027e['delete'](_0x36c85a);const _0xaf599f=new Map();for(const _0x2a92ff of _0x4cc3c7){let _0x1aa4ce=_0xfeec5a['insertions'][_0x2a92ff];for(const _0xe621e0 of _0x1aa4ce)if(_0xe621e0['item']['is']('element','tableCell')){const _0x3628d9=this['_getVidAttributeName'](_0xe621e0),_0x52f691=_0xe621e0['item']['getAttribute'](_0x3628d9);if(_0x38859a['has'](_0x52f691)){const _0x2ad0cb=_0xe621e0['item']['parent']['parent']['getAttribute']('vid_start'),_0x4982c4=_0xaf599f['get'](_0x2ad0cb)||new Set();_0x4982c4['add'](_0x38859a['get'](_0x52f691)['userId']),_0xaf599f['set'](_0x2ad0cb,_0x4982c4);}}_0x1aa4ce=_0xfeec5a['deletions'][_0x2a92ff];for(const _0x4fd7a3 of _0x1aa4ce)if(_0x4fd7a3['item']['is']('element','tableCell')){const _0x2e3de4=this['_getVidAttributeName'](_0x4fd7a3),_0xfbc29b=_0x4fd7a3['item']['getAttribute'](_0x2e3de4);if(_0x33027e['has'](_0xfbc29b)){const _0x38a1c4=_0x4fd7a3['item']['parent']['parent']['getAttribute']('vid_start'),_0x24afcb=_0xaf599f['get'](_0x38a1c4)||new Set();_0x24afcb['add'](_0x33027e['get'](_0xfbc29b)['userId']),_0xaf599f['set'](_0x38a1c4,_0x24afcb);}}for(const _0x364359 of _0xaf599f['keys']())(_0x38859a['has'](_0x364359)||_0x33027e['has'](_0x364359))&&_0xaf599f['delete'](_0x364359);}for(const _0x538e2a of _0x4cc3c7){const _0x155197=_0xfeec5a['insertions'][_0x538e2a];let _0x5a7bb9=null,_0x2c5604=null;for(const _0x193df3 of _0x155197){const _0x47dbc3=this['_getVidAttributeName'](_0x193df3),_0x36dc05=_0x193df3['item']['getAttribute'](_0x47dbc3),_0x7ad6f1=_0xaf599f['get'](_0x36dc05);_0x7ad6f1&&'elementStart'==_0x193df3['type']&&(_0x5a7bb9=Array['from'](_0x7ad6f1)[0x0],_0x2c5604=_0x193df3['item']['getAttribute']('vid_end')),_0x5a7bb9&&(_0x33027e['set'](_0x36dc05,{'userId':_0x5a7bb9}),_0x38859a['set'](_0x36dc05,{'userId':_0x5a7bb9})),_0x36dc05==_0x2c5604&&(_0x5a7bb9=null,_0x2c5604=null);}}const _0x3746f={},_0x4baf55=new Set();for(const _0xa858cb of _0x4cc3c7){const _0x130631=_0x5cf274['deletions'][_0xa858cb],_0x2ffbbf=_0x5cf274['insertions'][_0xa858cb];for(const {userId:_0x11ec8e}of this['_touchedMarkers']['values']())null!==_0x11ec8e&&_0x4baf55['add'](_0x11ec8e);for(const {userId:_0x1776e4}of this['_touchedRoots']['values']())null!==_0x1776e4&&_0x4baf55['add'](_0x1776e4);this['_markChanges'](_0x2ffbbf,_0xfeec5a['insertions'][_0xa858cb],_0x38859a,'insertion',_0x4baf55),this['_markChanges'](_0x130631,_0xfeec5a['deletions'][_0xa858cb],_0x33027e,'deletion',_0x4baf55),_0x3746f[_0xa858cb]={'insertions':this['_prepareViewToSave'](_0x2ffbbf),'deletions':this['_prepareViewToSave'](_0x130631),'attachChange':this['_touchedRoots']['get'](_0xa858cb)||null,'attributesBefore':_0x77b43c(this['_baseRootsAttributes']['get'](_0xa858cb))||{},'attributesAfter':_0x77b43c(this['_diffRootsAttributes']['get'](_0xa858cb))};}return{'diffData':_0x3746f,'authorsIds':Array['from'](_0x4baf55)};}['_processRootBeforeSave'](_0x40f18b){for(const [,_0x174a1e]of _0x40f18b['markers']){const _0x3fcd15=_0x174a1e['start']['getAncestors']()['filter'](_0x1535dd=>'tableCell'==_0x1535dd['name']);for(const _0x1cf220 of _0x3fcd15)0x1==_0x1cf220['childCount']&&_0x1cf220['getChild'](0x0)['is']('element','paragraph')&&_0x1cf220['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x59f6a1){this['_processRootBeforeSave'](_0x59f6a1);const _0x509f59=this['editor']['data']['toView'](_0x59f6a1,{}),_0x9bcfdb=Array['from'](_0x509f59['getChildren']())['map'](_0x384c7e=>this['_getViewJson'](_0x384c7e));return JSON['stringify'](_0x9bcfdb);}['_getViewJson'](_0x3bcbf5){if(_0x3bcbf5['is']('$text'))return _0x3bcbf5['data'];{const _0x58df57=_0x3bcbf5;return{'type':Object['keys'](P)['find'](_0x167350=>_0x3bcbf5 instanceof P[_0x167350]),'name':_0x58df57['name'],'attributes':Array['from'](_0x58df57['getAttributes']()),'children':Array['from'](_0x58df57['getChildren']())['map'](_0x22f734=>this['_getViewJson'](_0x22f734))};}}['_markChanges'](_0x4dda38,_0xe1489e,_0x1b4f4a,_0x185ace,_0xe0eba4){let _0x1f7de7=null,_0x4348c6=null,_0x4540a4=0x0;const _0x5307cd=this['editor']['model'];for(let _0x142a80=0x0;_0x142a80<_0xe1489e['length'];_0x142a80++){const _0x37de12=this['_getVidAttributeName'](_0xe1489e[_0x142a80]),_0x268817=_0xe1489e[_0x142a80]['item']['getAttribute'](_0x37de12),_0x3a88b6=_0x1b4f4a['get'](_0x268817),_0x396769=_0x142a80==_0xe1489e['length']-0x1;(!_0x1f7de7&&_0x3a88b6&&(_0x1f7de7=_0x3a88b6,_0x4348c6=_0xe1489e[_0x142a80]),_0x1f7de7&&(!_0x3a88b6||_0x3a88b6['userId']!=_0x1f7de7['userId']))&&(_0x25b618(_0x3a88b6,B(_0x4348c6,_0x4dda38,_0x5307cd),B(_0xe1489e[_0x142a80],_0x4dda38,_0x5307cd)),_0x1f7de7=_0x3a88b6||null,_0x4348c6=_0x3a88b6?_0xe1489e[_0x142a80]:null),_0x1f7de7&&_0x396769&&_0x25b618(_0x3a88b6,B(_0x4348c6,_0x4dda38,_0x5307cd),J(_0xe1489e[_0x142a80],_0x4dda38,_0x5307cd));}function _0x25b618(_0x2a039f,_0x214fb3,_0x37648a){const _0x326158=_0x1f7de7['userId'],_0x371d34='revision:'+_0x185ace+':'+_0x326158+':'+_0x4540a4++,_0x11e68e=_0x5307cd['createRange'](_0x214fb3,_0x37648a);_0x4dda38['markers']['set'](_0x371d34,_0x11e68e),null!==_0x326158&&_0xe0eba4['add'](_0x326158);}}['_getVidAttributeName'](_0x2495c8){switch(_0x2495c8['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x43874f,_0x3012f5){_0x43874f['baseVersion']=null;for(const _0x308e47 in _0x43874f){const _0x275a7f=_0x43874f[_0x308e47];if(_0x275a7f instanceof gt){const _0x29a04f=_0x3012f5['get'](_0x275a7f['root']['rootName']);_0x43874f[_0x308e47]=this['_fixPosition'](_0x275a7f,_0x29a04f);}if(_0x275a7f instanceof vt){const _0x415feb=_0x3012f5['get'](_0x275a7f['root']['rootName']);_0x43874f[_0x308e47]=this['_fixRange'](_0x275a7f,_0x415feb);}'root'===_0x308e47&&(_0x43874f['root']=_0x3012f5['get'](_0x43874f['root']['rootName']));}}['_fixRange'](_0x4946e8,_0x498619){return this['editor']['model']['createRange'](this['_fixPosition'](_0x4946e8['start'],_0x498619),this['_fixPosition'](_0x4946e8['end'],_0x498619));}['_fixPosition'](_0x26ca51,_0xa5b6ec){return this['editor']['model']['createPositionFromPath'](_0xa5b6ec,_0x26ca51['path'],_0x26ca51['stickiness']);}['_handleInsertOperation'](_0x4abab9){const _0x14b066=this['_idsRoots']['get'](_0x4abab9['position']['root']['rootName']),_0x4bfec2=this['_fixPosition'](_0x4abab9['position'],_0x14b066),_0x9c6af2=null===_0x4abab9['_authorId']?null:_0x4abab9['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x1b11dc=_0x4bfec2['parent'],_0x46f23c=this['_revisionId'],_0x205f3a=[];for(const _0xec8cb3 of _0x4abab9['nodes'])if(_0xec8cb3['is']('element'))_0x205f3a['push'](this['_makeIdsRoot'](_0xec8cb3));else{for(let _0x55cb33=0x0;_0x55cb33<_0xec8cb3['offsetSize'];_0x55cb33++)_0x205f3a['push'](new ft('$text',{'vid':this['_revisionId']++}));}const _0x1e027e=this['_revisionId'];for(let _0x38912e=_0x46f23c;_0x38912e<_0x1e027e;_0x38912e++)this['_touched']['set'](_0x38912e,{'userId':_0x9c6af2});_0x1b11dc['_insertChild'](_0x4bfec2['offset'],_0x205f3a);}['_handleMoveOperation'](_0x14fbce){(_0x14fbce=this['_cloneOperation'](_0x14fbce,this['_idsRoots']))['_execute']();const _0x986bbc=null===_0x14fbce['_authorId']?null:_0x14fbce['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x191216=_0x14fbce['getMovedRangeStart'](),_0x2bcfc1=_0x191216['parent'],_0x276043=_0x191216['offset'];!function _0x45a16a(_0x2854b1,_0x26413b,_0x18d6df,_0x578afd){for(let _0x337384=_0x18d6df;_0x337384<_0x578afd;_0x337384++){const _0x192e19=_0x26413b['getChild'](_0x337384);_0x192e19['is']('element','$text')?_0x2854b1['set'](_0x192e19['getAttribute']('vid'),{'userId':_0x986bbc}):(_0x2854b1['set'](_0x192e19['getAttribute']('vid_start'),{'userId':_0x986bbc}),_0x45a16a(_0x2854b1,_0x192e19,0x0,_0x192e19['childCount']),_0x2854b1['set'](_0x192e19['getAttribute']('vid_end'),{'userId':_0x986bbc}));}}(this['_touched'],_0x2bcfc1,_0x276043,_0x276043+_0x14fbce['howMany']);}['_handleMergeOperation'](_0x59fe33){const _0x4ead31=null===(_0x59fe33=this['_cloneOperation'](_0x59fe33,this['_idsRoots']))['_authorId']?null:_0x59fe33['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x3c76f1=_0x59fe33['targetPosition']['parent'],_0xc2ac05=_0x59fe33['sourcePosition']['parent'],_0x4235b8=_0x3c76f1['getAttribute']('vid_end'),_0x12fe8b=_0xc2ac05['getAttribute']('vid_start');_0x3c76f1['_setAttribute']('vid_end',_0xc2ac05['getAttribute']('vid_end')),_0xc2ac05['_setAttribute']('vid_end',_0x4235b8),this['_touched']['set'](_0x12fe8b,{'userId':_0x4ead31}),this['_touched']['set'](_0x4235b8,{'userId':_0x4ead31}),_0x59fe33['_execute']();}['_handleSplitOperation'](_0x49ad5f){const _0x117916=null===(_0x49ad5f=this['_cloneOperation'](_0x49ad5f,this['_idsRoots']))['_authorId']?null:_0x49ad5f['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x1eadc2=_0x49ad5f['graveyardPosition'],_0x52ae04=_0x49ad5f['splitPosition']['parent'];_0x49ad5f['_execute']();const _0x19e3a4=_0x52ae04['getAttribute']('vid_end'),_0xabf750=_0x49ad5f['insertionPosition']['nodeAfter'];if(_0x1eadc2){const _0x2c392d=_0xabf750['getAttribute']('vid_end'),_0xe737bc=_0x52ae04['getAttribute']('vid_end');_0x52ae04['_setAttribute']('vid_end',_0x2c392d),_0xabf750['_setAttribute']('vid_end',_0xe737bc),this['_touched']['set'](_0x52ae04['getAttribute']('vid_end'),{'userId':_0x117916}),this['_touched']['set'](_0xabf750['getAttribute']('vid_start'),{'userId':_0x117916});}else{const _0x2fe9e5=this['_revisionId']++,_0x3eb5b8=this['_revisionId']++;_0x52ae04['_setAttribute']('vid_end',_0x2fe9e5),_0xabf750['_setAttribute']('vid_start',_0x3eb5b8),_0xabf750['_setAttribute']('vid_end',_0x19e3a4),this['_touched']['set'](_0x2fe9e5,{'userId':_0x117916}),this['_touched']['set'](_0x3eb5b8,{'userId':_0x117916});}}['_handleMarkerOperation'](_0x507253){if(!_0x507253['affectsData'])return;const _0x3bb3e0=(_0x507253=this['_cloneOperation'](_0x507253,this['_diffRoots']))['oldRange']?_0x507253['oldRange']['root']:null,_0xe094bc=_0x507253['newRange']?_0x507253['newRange']['root']:null;_0x3bb3e0&&this['_markers']['delete'](_0x507253['name']),_0xe094bc&&this['_markers']['set'](_0x507253['name'],_0x507253['newRange']['clone']());const _0x31a8b6=null===_0x507253['_authorId']?null:_0x507253['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x189af3=_0x507253['name'];if(!this['_touchedMarkers']['has'](_0x189af3))return void this['_touchedMarkers']['set'](_0x189af3,{'range':_0x507253['oldRange'],'userId':_0x31a8b6});const _0x250e70=this['_touchedMarkers']['get'](_0x189af3),_0x4d835f=_0x250e70['range'],_0x18006c=_0x507253['newRange'];null==_0x4d835f&&null==_0x18006c||_0x4d835f&&_0x18006c&&_0x4d835f['isEqual'](_0x18006c)?this['_touchedMarkers']['delete'](_0x507253['name']):_0x250e70['userId']=_0x31a8b6;}['_handleRootOperation'](_0x1bc513,_0x4d7af2){this['_diffRoots']['has'](_0x1bc513['rootName'])?this['_diffRoots']['get'](_0x1bc513['rootName'])['_isAttached']=_0x1bc513['isAdd']:(this['_diffRoots']['set'](_0x1bc513['rootName'],F(_0x1bc513['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x1bc513['rootName'],{}),_0x4d7af2&&this['_idsRoots']['set'](_0x1bc513['rootName'],F(_0x1bc513['rootName'],!0x0)));const _0x5539a8=null===_0x1bc513['_authorId']?null:_0x1bc513['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x54e5a2=this['_touchedRoots']['get'](_0x1bc513['rootName']);_0x54e5a2&&_0x54e5a2['userId']===_0x5539a8?this['_touchedRoots']['delete'](_0x1bc513['rootName']):this['_touchedRoots']['set'](_0x1bc513['rootName'],{'userId':_0x5539a8,'isAttached':_0x1bc513['isAdd']});}['_handleRootAttributeOperation'](_0x3e6a15){const _0x187d07=this['_diffRootsAttributes']['get'](_0x3e6a15['root']['rootName']);null===_0x3e6a15['newValue']?delete _0x187d07[_0x3e6a15['key']]:_0x187d07[_0x3e6a15['key']]=_0x3e6a15['newValue'];}}function T(_0x1ae50e){const _0x673dae=F(_0x1ae50e['rootName'],_0x1ae50e['isAttached']());for(const _0x20860b of _0x1ae50e['getChildren']()){const _0x3daad4=_0x20860b['_clone'](!0x0);_0x673dae['_appendChild'](_0x3daad4);}return _0x673dae;}function F(_0x28619d,_0x74df6a=!0x0){const _0x93e1b1=new mt();return _0x93e1b1['rootName']=_0x28619d,_0x93e1b1['_isAttached']=_0x74df6a,_0x93e1b1['isAttached']=()=>_0x93e1b1['_isAttached'],_0x93e1b1;}function B(_0x13d13f,_0xc8e738,_0x275517){const _0x545b7d='elementEnd'==_0x13d13f['type']?_0x275517['createPositionAt'](_0x13d13f['item'],'end'):_0x275517['createPositionBefore'](_0x13d13f['item']);return _0x275517['createPositionFromPath'](_0xc8e738,_0x545b7d['path'],_0x545b7d['stickiness']);}function J(_0x37c1b0,_0x5c57a4,_0xb66ab3){const _0x38a856='elementStart'==_0x37c1b0['type']?_0xb66ab3['createPositionAt'](_0x37c1b0['item'],0x0):_0xb66ab3['createPositionAfter'](_0x37c1b0['item']);return _0xb66ab3['createPositionFromPath'](_0x5c57a4,_0x38a856['path'],_0x38a856['stickiness']);}class hs extends ts{['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x25f995,_0x49423c){super(_0x25f995),this['focusTracker']=new _0x2cdc04(),this['keystrokes']=new _0x430444(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x49423c),this['setTemplate']({'tag':'form','attributes':{'class':['ck','ck-revision-history-save-revision-form','ck-responsive-form'],'tabindex':'-1'},'children':[this['revisionNameInputView']]}),_0x338fd2(this);}['render'](){super['render'](),_0x53558e({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x511943=_0x31485d=>_0x31485d['stopPropagation']();this['keystrokes']['set']('arrowright',_0x511943),this['keystrokes']['set']('arrowleft',_0x511943),this['keystrokes']['set']('arrowup',_0x511943),this['keystrokes']['set']('arrowdown',_0x511943);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x5c5cc9){this['revisionNameInputView']['fieldView']['element']['value']=_0x5c5cc9['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x56f378){const _0x13dfec=new _0xe538c1(this['locale'],_0x368611),_0x50b88b=_0x13dfec['fieldView'];_0x50b88b['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x1f408c=m(this['locale'],'Name\x20of\x20the\x20revision');return!_0x56f378&&(_0x1f408c+='\x20('+m(this['locale'],'optional')+')'),(_0x13dfec['label']=_0x1f408c,_0x50b88b['on']('input',()=>{this['revisionNameInputValue']=_0x50b88b['element']['value']['trim']();}),_0x13dfec);}}class u extends _0x1420a4{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l];}['_saveRevisionFormView'];['init'](){const _0x20443d=this['editor'],_0x229214=_0x20443d['plugins']['get']('RevisionTracker');_0x20443d['ui']['componentFactory']['add']('revisionHistory',_0x127d5d=>{const _0x1eb6a4=_0x1e0a60(_0x127d5d),_0x1c9f5b=_0x1eb6a4['panelView']['children'],_0x1e9e70=new _0x4646f5(_0x127d5d),_0x2dc59e=new _0x503a4e(_0x127d5d),_0x55318b=new te(_0x127d5d),_0xe9c586=new _0x503a4e(_0x127d5d),_0xd39516=new te(_0x127d5d);return _0x1eb6a4['bind']('isEnabled')['to'](_0x229214,'isReady',_0x229214,'isEnabled',_0x20443d,'isReadOnly',(_0x4dfc90,_0x4347b8,_0xa64501)=>_0x4dfc90&&_0x4347b8&&!_0xa64501),_0x1eb6a4['buttonView']['set']({'icon':_0x247700['history'],'label':m(_0x127d5d,'Revision\x20history'),'tooltip':!0x0}),_0x55318b['set']({'label':m(_0x127d5d,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x55318b['bind']('isEnabled')['to'](_0x229214,'isReady',_0x229214,'isEnabled',_0x20443d,'isReadOnly',(_0x464390,_0x44041c,_0x260a35)=>_0x464390&&_0x44041c&&!_0x260a35),_0x55318b['on']('execute',()=>this['_showDialog']()),_0xd39516['set']({'label':m(_0x127d5d,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0xd39516['bind']('isEnabled')['to'](_0x229214,'isReady',_0x20443d,'isReadOnly',(_0x2dd954,_0x584ed1)=>_0x2dd954&&!_0x584ed1),_0xd39516['on']('execute',()=>{_0x20443d['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x1eb6a4['isOpen']=!0x1,_0x20443d['editing']['view']['focus']();}),_0x2dc59e['children']['add'](_0x55318b),_0xe9c586['children']['add'](_0xd39516),_0x1e9e70['role']='menu',_0x1e9e70['items']['addMany']([_0x2dc59e,_0xe9c586]),_0x1c9f5b['add'](_0x1e9e70),_0x1eb6a4;}),_0x20443d['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x41aa49=this['editor'],_0x5a67aa=_0x41aa49['locale'],_0x5a619f=new _0x827bd6(_0x5a67aa),_0x49cf56=new _0x170de9(_0x5a67aa);_0x5a619f['buttonView']['set']({'icon':_0x247700['history'],'label':m(_0x5a67aa,'Revision\x20history')});const _0xfa7961=new _0x4b4311(_0x5a67aa,_0x5a619f),_0x27aa4d=new _0x2b7259(_0x5a67aa);_0x27aa4d['set']({'label':m(_0x5a67aa,'Save\x20current\x20revision')}),_0x27aa4d['delegate']('execute')['to'](_0x5a619f),_0x27aa4d['on']('execute',()=>{this['_showDialog']();}),_0xfa7961['children']['add'](_0x27aa4d),_0x49cf56['items']['add'](_0xfa7961);const _0x454874=new _0x4b4311(_0x5a67aa,_0x5a619f),_0x568a7a=new _0x2b7259(_0x5a67aa);return _0x568a7a['set']({'label':m(_0x5a67aa,'Open\x20revision\x20history')}),_0x568a7a['delegate']('execute')['to'](_0x5a619f),_0x568a7a['on']('execute',()=>{_0x41aa49['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x454874['children']['add'](_0x568a7a),_0x49cf56['items']['add'](_0x454874),_0x5a619f['panelView']['children']['add'](_0x49cf56),_0x5a619f;}['_showDialog'](){const _0x58d500=this['editor'],_0x365ba3=_0x58d500['locale'],_0x4e1cd5=_0x58d500['plugins']['get']('Dialog'),_0x293ba0=_0x58d500['plugins']['get']('RevisionTracker');function _0x3dfb9e(_0x1a6158){_0x58d500['config']['get']('revisionHistory.requireRevisionName')&&''===_0x1a6158['revisionName']?_0x1a6158['revisionNameInputView']['errorText']=m(_0x365ba3,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x58d500['plugins']['get'](l)['saveRevision']({'name':_0x1a6158['revisionName']}),_0x4e1cd5['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x3dfb9e(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x4e1cd5['show']({'id':'revisionSave','title':m(_0x365ba3,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':m(_0x58d500['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x4e1cd5['hide']()},{'label':m(_0x58d500['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x1d6df0){_0x1d6df0['bind']('isEnabled')['to'](_0x293ba0,'isReady',_0x293ba0,'isEnabled',_0x58d500,'isReadOnly',(_0x57ff1a,_0x45bc04,_0x1e81b3)=>_0x57ff1a&&_0x45bc04&&!_0x1e81b3);},'onExecute':()=>_0x3dfb9e(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x1dd8c4=this['editor'],_0x532904=_0x1dd8c4['locale'];this['_saveRevisionFormView']=new hs(_0x532904,_0x1dd8c4['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class X extends ts{['changeId'];['_model'];constructor(_0x59071d,_0x1cda80){super(_0x59071d),this['_model']=_0x1cda80,this['changeId']=_0x1cda80['id'];const _0x401279=this['bindTemplate'],_0x12afac=m(_0x59071d,_0x1cda80['data']['isSuggestion']?'Suggested\x20by':'add'==_0x1cda80['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x1cda80['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x401279['to']('type',_0x1fa879=>'ck-revision-change__'+_0x1fa879)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x12afac}]},{'text':'\x20'+_0x1cda80['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class r extends/* #__PURE__ -- @preserve */
|
|
25
|
-
_0x217fff(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x3e6f84){super(),this['id']=_0x3e6f84['id']||_0x5d66aa(),this['author']=_0x3e6f84['author'],this['type']=_0x3e6f84['type'],this['data']=_0x3e6f84['data']||{},this['rootName']=_0x3e6f84['rootName'],this['set']('createdAt',_0x3e6f84['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(_0x308a92,_0x34c1e9){this['newRevisionId']=_0x308a92,this['oldRevisionId']=_0x34c1e9,this['changes']=new _0xcf6e93();}['_setChanges'](_0x3aca52){for(const _0x1d6db8 of _0x3aca52)this['changes']['add'](_0x1d6db8);}}const Y={'c':_0x32a864,'a':_0x4e3bae,'e':_0x1ac8e8,'r':_0x1e3674,'u':_0x28e93a};class d extends _0x1420a4{['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[_0x4f378f,_0x1e2672,j];}constructor(_0x21adb8){super(_0x21adb8),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',(_0xfc6e13,_0x1ecb7f,_0x1c14a7)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x102040=>{for(const _0x4cd044 of this['editor']['editing']['view']['document']['roots'])_0x1c14a7?_0x102040['removeClass']('ck-editor__editable__overlay',_0x4cd044):_0x102040['addClass']('ck-editor__editable__overlay',_0x4cd044);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x1ea5d8=>null!==_0x1ea5d8),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x4f7510,_0x454908,_0x2ebd0a)=>_0x4f7510&&_0x2ebd0a?_0x454908['changes']['getIndex'](_0x2ebd0a):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x5e5a06,_0x322dda)=>_0x5e5a06?_0x322dda['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['adapter']=null,this['_balloon']=this['editor']['plugins']['get'](_0x1e2672);}['init'](){const _0x5ff3eb=this['editor'],_0x25e3ca=new _t(_0x5ff3eb,{'direction':'backward'}),_0x1e6fca=new _t(_0x5ff3eb,{'direction':'forward'});(_0x5ff3eb['commands']['add']('showPreviousChange',_0x25e3ca),_0x5ff3eb['commands']['add']('showNextChange',_0x1e6fca),_0x5ff3eb['commands']['add']('restoreRevision',new pt(_0x5ff3eb)),this['on']('change:numberOfChanges',()=>{_0x25e3ca['refresh'](),_0x1e6fca['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x5ff3eb['enableReadOnlyMode']('revision-viewer'),_0x5ff3eb['plugins']['has']('WidgetToolbarRepository'))&&_0x5ff3eb['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionData'](_0x9e0492){await this['loadRevisionData'](_0x9e0492);const _0x3069c4={};for(const _0x299faf in _0x9e0492['diffData']){if(_0x9e0492['diffData'][_0x299faf]['attachChange']&&!_0x9e0492['diffData'][_0x299faf]['attachChange']['isAttached'])continue;const _0x15497f=this['_removeRevisionMarkers'](JSON['parse'](_0x9e0492['diffData'][_0x299faf]['insertions'])),_0x1436f1=this['editor']['editing']['view']['document'],_0x449ebe=new _0x57bee1(_0x1436f1,_0x15497f['map'](_0x562dab=>this['_getViewObj'](_0x562dab)));this['editor']['data']['processor']['useFillerType']('marked'),_0x3069c4[_0x299faf]=this['editor']['data']['processor']['toData'](_0x449ebe),this['editor']['data']['processor']['useFillerType']('default');}return _0x3069c4;}async['getRevisionRootsAttributes'](_0x27c2c1){await this['loadRevisionData'](_0x27c2c1);const _0x349ec0={};for(const _0x54e2f0 in _0x27c2c1['diffData'])_0x27c2c1['diffData'][_0x54e2f0]['attachChange']&&!_0x27c2c1['diffData'][_0x54e2f0]['attachChange']['isAttached']||(_0x349ec0[_0x54e2f0]=_0x27c2c1['diffData'][_0x54e2f0]['attributesAfter']||{});return _0x349ec0;}['_removeRevisionMarkers'](_0x42115a){return(_0x42115a=_0x42115a['filter'](_0x3734e7=>!_0x3734e7['name']||'revision-start'!==_0x3734e7['name']&&'revision-end'!==_0x3734e7['name']))['forEach'](_0x9af19a=>{'string'!=typeof _0x9af19a&&(_0x9af19a['children']=this['_removeRevisionMarkers'](_0x9af19a['children']),_0x9af19a['attributes']=_0x9af19a['attributes']['filter'](_0x266a15=>!_0x266a15[0x0]['startsWith']('data-revision-')));}),_0x42115a;}async['compare'](_0xe7b205,_0xf03f08,_0x3f10f5=!0x1){if(!this['isEnabled'])return;const _0xc69680=this['diff'],_0x173106=this['repository'],_0x3f9cd5='string'==typeof _0xe7b205?_0x173106['getRevision'](_0xe7b205):_0xe7b205,_0x3e31f2='string'==typeof _0xf03f08?_0x173106['getRevision'](_0xf03f08):_0xf03f08,_0x49198c=_0x3f9cd5['id'],_0x10170f=_0x3e31f2?_0x3e31f2['id']:null;if(!_0x3f10f5&&this['diff']&&this['diff']['newRevisionId']===_0x49198c&&this['diff']['oldRevisionId']===_0x10170f)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new f(_0x49198c,_0x10170f);const _0x325e0e=this['_getRevisionsRange'](_0x3f9cd5,_0x3e31f2,!0x0)['map'](_0x2b20c8=>this['loadRevisionData'](_0x2b20c8));return _0x325e0e['push'](new Promise(_0x2258bd=>{setTimeout(_0x2258bd,0x14);})),Promise['all'](_0x325e0e)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x30096a=this['_getDiff'](_0x49198c,_0x10170f);for(const _0x5c01b5 of _0x30096a['changes'])this['_changeIdToChange']['set'](_0x5c01b5['id'],_0x5c01b5);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0xc5a026=>{for(const _0x4dd314 of this['editor']['model']['document']['getRootNames']())_0xc5a026['detachRoot'](_0x4dd314);for(const _0xfffadf of Object['keys'](_0x30096a['model'])){const _0x2f17fd=_0xc5a026['addRoot'](_0xfffadf);for(const _0x1a50e7 of Object['keys'](_0x30096a['attributes'][_0xfffadf]))_0xc5a026['setAttribute'](_0x1a50e7,_0x30096a['attributes'][_0xfffadf][_0x1a50e7],_0x2f17fd);_0xc5a026['insert'](_0x30096a['model'][_0xfffadf],_0x2f17fd,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x30096a['changes'])),this['isReady']=!0x0;})['catch'](_0x34ca99=>{console['error'](_0x34ca99),this['_cleanUp'](),_0xc69680&&(this['diff']=_0xc69680),this['isReady']=!0x0;});}['addRevisionData'](_0x34db75,_0x4948b9){const _0x5b6288=this['repository']['createRevision'](_0x34db75);return _0x5b6288['on']('_update',(_0x1b4200,_0x2401cc,_0x3d300f)=>_0x4948b9(_0x2401cc,_0x3d300f,_0x5b6288)),this['repository']['addRevision'](_0x5b6288),_0x5b6288;}['loadRevisionData'](_0x489a33){if(!_0x489a33||_0x489a33['diffData'])return Promise['resolve']();{const _0x354487=this['editor']['config']['get']('collaboration.channelId');return this['adapter']['getRevision']({'channelId':_0x354487,'revisionId':_0x489a33['id']})['then'](_0x8f2136=>{_0x489a33['_update']({'diffData':_0x8f2136['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},_0x1650a5=>{for(const _0x5d4666 of this['editor']['model']['document']['getRootNames']())_0x1650a5['detachRoot'](_0x5d4666);});}['_sortAndFilterDiffChanges'](_0x416b2c){const _0x398f87=[],_0x56d6d4=new Map();for(const _0x46cd16 of this['editor']['model']['document']['getRootNames']()){const _0x487403=this['editor']['editing']['view']['getDomRoot'](_0x46cd16);if(!_0x487403)continue;const _0x565aeb=_0x487403['getClientRects']()['item'](0x0);_0x565aeb&&(_0x398f87['push'](_0x46cd16),_0x56d6d4['set'](_0x46cd16,_0x565aeb));}return _0x398f87['sort']((_0x460ee3,_0x956682)=>{const _0x4f94c3=_0x56d6d4['get'](_0x460ee3),_0x4a2765=_0x56d6d4['get'](_0x956682);return _0x4f94c3['y']-_0x4a2765['y']||_0x4f94c3['x']-_0x4a2765['x'];}),(_0x416b2c=_0x416b2c['filter'](_0x432479=>_0x398f87['includes'](_0x432479['rootName'])))['sort']((_0x22546b,_0x4f5b19)=>_0x398f87['indexOf'](_0x22546b['rootName'])-_0x398f87['indexOf'](_0x4f5b19['rootName'])),_0x416b2c;}['_makeTape'](_0x3d0ac7){const _0x5efa76=Array['from'](_0x3d0ac7['markers'])['filter'](([_0x95878,_0x1c3b9d])=>_0x95878['startsWith']('revision:')&&!_0x1c3b9d['isCollapsed']),_0x13e22b=Array['from'](this['editor']['model']['createRangeIn'](_0x3d0ac7)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x5efa76['length'])for(const _0x248c47 of _0x13e22b){const [_0x439ad5,_0xa07233]=_0x5efa76[0x0],[,_0x911314,_0x3c36ec]=_0x439ad5['split'](':');if(_0xa07233['end']['isEqual'](_0x248c47['nextPosition'])&&_0x5efa76['shift'](),(_0x248c47['previousPosition']['isEqual'](_0xa07233['start'])||_0x248c47['previousPosition']['isAfter'](_0xa07233['start']))&&('insertion'==_0x911314?_0x248c47['isAdded']={'userId':_0x3c36ec}:'deletion'==_0x911314&&(_0x248c47['isRemoved']={'userId':_0x3c36ec})),0x0==_0x5efa76['length'])break;}return _0x13e22b;}['_refreshStartEndIndex'](_0x572ae9){const _0x31661c=new Map();for(let _0x2a9308=0x0;_0x2a9308<_0x572ae9['length'];_0x2a9308++)'text'===_0x572ae9[_0x2a9308]['type']?(_0x572ae9[_0x2a9308]['item']['startIndex']=_0x2a9308,_0x572ae9[_0x2a9308]['item']['endIndex']=_0x2a9308):('elementStart'===_0x572ae9[_0x2a9308]['type']?_0x572ae9[_0x2a9308]['item']['startIndex']=_0x2a9308:'elementEnd'===_0x572ae9[_0x2a9308]['type']&&(_0x572ae9[_0x2a9308]['item']['endIndex']=_0x2a9308),_0x31661c['set'](_0x572ae9[_0x2a9308]['id'],_0x2a9308));for(const _0x2ffc68 of _0x31661c['values']())'elementStart'===_0x572ae9[_0x2ffc68]['type']?_0x572ae9[_0x2ffc68]['item']['endIndex']=_0x31661c['get'](_0x572ae9[_0x2ffc68]['pairId']):'elementEnd'===_0x572ae9[_0x2ffc68]['type']&&(_0x572ae9[_0x2ffc68]['item']['startIndex']=_0x31661c['get'](_0x572ae9[_0x2ffc68]['pairId']));}['_processTape'](_0xdf3323){for(let _0x358406=0x0;_0x358406<_0xdf3323['length'];_0x358406++){if('elementStart'===_0xdf3323[_0x358406]['type'])_0xdf3323[_0x358406]['item']['startIndex']=_0x358406;else{if('elementEnd'===_0xdf3323[_0x358406]['type']){_0xdf3323[_0x358406]['item']['endIndex']=_0x358406;const _0x25adb0=_0xdf3323[_0x358406]['item']['startIndex'];_0xdf3323[_0x25adb0]['pairId']=_0xdf3323[_0x358406]['id'],_0xdf3323[_0x358406]['pairId']=_0xdf3323[_0x25adb0]['id'];}else _0xdf3323[_0x358406]['item']['startIndex']=_0x358406,_0xdf3323[_0x358406]['item']['endIndex']=_0x358406,_0xdf3323[_0x358406]['pairId']=null;}_0xdf3323[_0x358406]['markersStart']||(_0xdf3323[_0x358406]['markersStart']=[],_0xdf3323[_0x358406]['markersEnd']=[]);}}['_markInsertions'](_0x4f7fed,_0x47be4c){const _0x319e6d=_0x4f7fed['filter'](_0x2e2a72=>!_0x2e2a72['isAdded']);for(let _0x537395=0x0;_0x537395<_0x47be4c['length'];_0x537395++)_0x47be4c[_0x537395]['isAdded']&&(_0x319e6d[_0x537395]['isAdded']=_0x47be4c[_0x537395]['isAdded']);}['_makeModelFromViewString'](_0x35d0ab){const _0x29dcb5=JSON['parse'](_0x35d0ab),_0x25265e=this['editor']['editing']['view']['document'],_0x38ca25=new _0x57bee1(_0x25265e,_0x29dcb5['map'](_0x1cc680=>this['_getViewObj'](_0x1cc680)));return this['editor']['data']['toModel'](_0x38ca25);}['_getViewObj'](_0x30659a){const _0x642aac=this['editor']['editing']['view']['document'];if('string'==typeof _0x30659a)return new _0xe73c6d(_0x642aac,_0x30659a);{const _0x338cba=_0x30659a['children']['map'](_0x47cf31=>this['_getViewObj'](_0x47cf31));return new(Y[_0x30659a['type']]||_0x5e2f0f)(_0x642aac,_0x30659a['name'],_0x30659a['attributes'],_0x338cba);}}['_getDiff'](_0x3d1e90,_0x255f23=null){const _0x44b714=this['repository']['getRevision'](_0x3d1e90),_0x4c5a38=_0x255f23?this['repository']['getRevision'](_0x255f23):null,_0x155924=this['_getRevisionsRange'](_0x44b714,_0x4c5a38),_0x478d81=_0x155924[_0x155924['length']-0x1],_0x17d0a0=new Map(),_0x666382={'model':{},'attributes':{},'changes':[]},_0x3e8c40=new Set(),_0xd3bb19=new Map();for(let _0x44d855=_0x155924['length']-0x1;_0x44d855>=0x0;_0x44d855--){const _0x3909ae=_0x155924[_0x44d855];for(const _0x50aff9 of Object['keys'](_0x3909ae['diffData']))if(_0x3909ae['diffData'][_0x50aff9]['attachChange']){const _0x469ce9=_0x3909ae['diffData'][_0x50aff9]['attachChange'];_0x469ce9['isAttached']?(_0x3e8c40['add'](_0x50aff9),_0xd3bb19['has'](_0x50aff9)&&_0xd3bb19['get'](_0x50aff9)['userId']==_0x469ce9['userId']?_0xd3bb19['delete'](_0x50aff9):_0xd3bb19['set'](_0x50aff9,_0x469ce9)):_0xd3bb19['has'](_0x50aff9)?(_0x3e8c40['delete'](_0x50aff9),_0xd3bb19['delete'](_0x50aff9)):(_0x3e8c40['add'](_0x50aff9),_0xd3bb19['set'](_0x50aff9,_0x469ce9));}else _0x3e8c40['add'](_0x50aff9);}for(const _0x4a751b of _0x3e8c40){const _0x4fd243=_0xd3bb19['has'](_0x4a751b)&&!_0xd3bb19['get'](_0x4a751b)['isAttached'];let _0x36f777=_0x4fd243?_0x155924['length']-0x1:0x0;const _0x26b66c=_0x4fd243?-0x1:0x1;for(;_0x155924[_0x36f777];){const _0x2188f2=_0x155924[_0x36f777];if(_0x2188f2['diffData'][_0x4a751b]){const _0x345967=_0x4fd243?_0x2188f2['diffData'][_0x4a751b]['attributesBefore']:_0x2188f2['diffData'][_0x4a751b]['attributesAfter'];_0x666382['attributes'][_0x4a751b]=_0x345967?_0x77b43c(_0x345967):{};break;}_0x36f777+=_0x26b66c;}}for(const _0x452f2f of _0x155924){_0x452f2f['model']={};for(const _0x3ae91f of _0x452f2f['authors'])_0x17d0a0['set'](_0x3ae91f['id'],_0x3ae91f);for(const _0x21f020 of _0x3e8c40){const _0x18cca1=_0x452f2f['diffData'][_0x21f020]?_0x452f2f['diffData'][_0x21f020]['insertions']:'[]',_0x1f4c74=_0x452f2f['diffData'][_0x21f020]?_0x452f2f['diffData'][_0x21f020]['deletions']:'[]';_0x452f2f['model'][_0x21f020]={'insertions':this['_makeModelFromViewString'](_0x18cca1),'deletions':this['_makeModelFromViewString'](_0x1f4c74)};}}for(const _0x82accc of _0x3e8c40){let _0x2e40ce=null,_0x56fb37=0x0;const _0x43780d=new Map(Array['from'](_0x44b714['model'][_0x82accc]['insertions']['markers'])['filter'](([_0x1bd17f])=>!_0x1bd17f['startsWith']('revision:')));let _0x1531c2=0x0;for(const _0x1858f0 of _0x155924){const _0x53e116=this['_makeTape'](_0x1858f0['model'][_0x82accc]['insertions']);_0x1858f0==_0x44b714?(_0x2e40ce=_0x53e116,_0x56fb37=_0x2e40ce['length'],_0x2e40ce['forEach'](_0x18bece=>{_0x18bece['id']=_0x1531c2++;}),this['_processTape'](_0x2e40ce)):this['_markInsertions'](_0x2e40ce,_0x53e116);const _0x3ee358=_0x2e40ce['filter'](_0x546252=>!_0x546252['isAdded'])['map'](_0x3aab3d=>_0x3aab3d['id']);let _0x340917=0x0;const _0x113f0a=this['_makeTape'](_0x1858f0['model'][_0x82accc]['deletions']);_0x113f0a['forEach'](_0x57d7ae=>{_0x57d7ae['isRemoved']?_0x57d7ae['id']=_0x56fb37++:_0x57d7ae['id']=_0x3ee358[_0x340917++];}),this['_processTape'](_0x113f0a),this['_setDistance'](_0x2e40ce,'isAdded'),this['_setDistance'](_0x113f0a,'isRemoved'),_0x1858f0==_0x44b714&&this['_markMarkers'](_0x2e40ce,_0x43780d),_0x2e40ce=this['_joinTapes'](_0x2e40ce,_0x113f0a),this['_refreshStartEndIndex'](_0x2e40ce),this['_setDistance'](_0x2e40ce,'isRemoved');}_0x2e40ce=_0x2e40ce['filter'](_0x21ffef=>!(_0x21ffef['isAdded']&&_0x21ffef['isRemoved']));const _0xb9c6e7=new Map(_0x478d81['model'][_0x82accc]['deletions']['markers']),_0x5ebf6a=new Set(_0x43780d['keys']());for(const _0x2a1c6c of _0xb9c6e7['keys']())_0x5ebf6a['delete'](_0x2a1c6c);this['_markSuggestions'](_0x2e40ce,_0x5ebf6a),this['_fixObsoleteTags'](_0x2e40ce),_0x2e40ce=this['_removeMissingPairs'](_0x2e40ce),_0x2e40ce=this['_markMismatchedRemovedTags'](_0x2e40ce),_0x2e40ce=this['_removeUnsupportedChanges'](_0x2e40ce);const {root:_0x521579,changes:_0x1e1622}=this['_makeModelFromTape'](_0x2e40ce,_0x17d0a0,_0x82accc);_0x666382['model'][_0x82accc]=_0x521579;const _0x11a877=_0xd3bb19['get'](_0x82accc);if(_0x11a877){const _0x5be509=_0x17d0a0['get'](_0x11a877['userId']),_0x1c67a9=new r({'author':_0x5be509,'type':_0x11a877['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x82accc});_0x1e1622['unshift'](_0x1c67a9),_0x666382['attributes'][_0x82accc]['revisionHistoryAttachChange']=_0x1c67a9['id'];}_0x666382['changes']=_0x666382['changes']['concat'](_0x1e1622);}return _0x666382;}['_markMarkers'](_0x61a971,_0x4c93b4){for(let _0xaa1b42=0x0;_0xaa1b42<_0x61a971['length'];_0xaa1b42++)for(const [_0x20eba4,_0x3c3af5]of _0x4c93b4)_0x3c3af5['start']['isEqual'](_0x61a971[_0xaa1b42]['previousPosition'])&&_0x61a971[_0xaa1b42]['markersStart']['push'](_0x20eba4),_0x3c3af5['end']['isEqual'](_0x61a971[_0xaa1b42]['nextPosition'])&&_0x61a971[_0xaa1b42]['markersEnd']['push'](_0x20eba4);}['_joinTapes'](_0x4f92e5,_0x39ce36){let _0x29c550=[],_0x5ebff4=0x0,_0x1a56b2=0x0;for(;_0x5ebff4<_0x4f92e5['length']||_0x1a56b2<_0x39ce36['length'];){const _0x2b6ff5=_0x4f92e5[_0x5ebff4]||{},_0x31c622=_0x39ce36[_0x1a56b2]||{};if(_0x2b6ff5['id']==_0x31c622['id'])_0x5ebff4++,_0x1a56b2++,_0x29c550['push'](_0x2b6ff5);else{if(_0x31c622['isRemoved']&&_0x2b6ff5['isAdded']){const {commonTape:_0x4d2d96,iEnd:_0x2b9d8f,jEnd:_0x20bf94}=this['_threeWayMerge'](_0x4f92e5,_0x5ebff4,_0x39ce36,_0x1a56b2);_0x29c550=_0x29c550['concat'](_0x4d2d96),_0x5ebff4=_0x2b9d8f,_0x1a56b2=_0x20bf94;}else _0x31c622['isRemoved']?(_0x1a56b2++,_0x29c550['push'](_0x31c622)):(_0x5ebff4++,_0x29c550['push'](_0x2b6ff5));}}return _0x29c550;}['_markSuggestions'](_0x2d06d4,_0x28ca36){const _0x1cb48e=[];for(let _0x555e1f=0x0;_0x555e1f<_0x2d06d4['length'];_0x555e1f++){for(let _0xdff107=0x0;_0xdff107<_0x2d06d4[_0x555e1f]['markersStart']['length'];_0xdff107++){const _0x4f10c4=_0x2d06d4[_0x555e1f]['markersStart'][_0xdff107];if(!_0x28ca36['has'](_0x4f10c4))continue;const {group:_0x47f239,type:_0x44239d,authorId:_0x1c0fd9}=_0x418e6c(_0x4f10c4);'revision-suggestion'!=_0x47f239||'insertion'!=_0x44239d&&'deletion'!=_0x44239d||(_0x1cb48e['unshift']({'type':_0x44239d,'name':_0x4f10c4,'userId':_0x1c0fd9}),_0x2d06d4[_0x555e1f]['markersStart']['splice'](_0xdff107,0x1),_0xdff107--);}_0x5058d1(_0x2d06d4[_0x555e1f]);for(let _0x65ff9a=0x0;_0x65ff9a<_0x2d06d4[_0x555e1f]['markersEnd']['length'];_0x65ff9a++){const _0x2457b0=_0x2d06d4[_0x555e1f]['markersEnd'][_0x65ff9a];if(!_0x28ca36['has'](_0x2457b0))continue;const {group:_0x560c1c,type:_0x3d81b7}=_0x418e6c(_0x2457b0);if('revision-suggestion'!=_0x560c1c||'insertion'!=_0x3d81b7&&'deletion'!=_0x3d81b7)continue;_0x2d06d4[_0x555e1f]['markersEnd']['splice'](_0x65ff9a,0x1),_0x65ff9a--;const _0x9fadee=_0x1cb48e['findIndex'](_0x101613=>_0x101613['name']==_0x2457b0);_0x9fadee>-0x1&&_0x1cb48e['splice'](_0x9fadee,0x1);}}function _0x418e6c(_0xac3111){const _0x20ac6a=_0xac3111['split'](':');return{'group':_0x20ac6a[0x0],'type':_0x20ac6a[0x1],'subType':_0x20ac6a['length']>=0x5?_0x20ac6a[0x2]:null,'id':_0x20ac6a['length']<0x5?_0x20ac6a[0x2]:_0x20ac6a[0x3],'authorId':_0x20ac6a['length']<0x5?_0x20ac6a[0x3]:_0x20ac6a[0x4],'markerCount':0x6==_0x20ac6a['length']?_0x20ac6a[0x5]:null};}function _0x5058d1(_0x2194b8){for(let _0x521df5=0x0;_0x521df5<_0x1cb48e['length'];_0x521df5++){if(_0x2194b8['isAdded']&&'insertion'==_0x1cb48e[_0x521df5]['type'])return _0x2194b8['isAddSuggestion']=_0x1cb48e[_0x521df5],void delete _0x2194b8['isAdded'];if(!_0x2194b8['isAdded']&&!_0x2194b8['isRemoved']&&'deletion'==_0x1cb48e[_0x521df5]['type'])return void(_0x2194b8['isRemoveSuggestion']=_0x1cb48e[_0x521df5]);}}}['_setDistance'](_0x416d86,_0x16261b){let _0x552664=0x0,_0x45d1ce=!0x1;const _0x46da5d=new Map();for(const _0x323596 of _0x416d86)_0x323596[_0x16261b]?_0x45d1ce&&(_0x552664++,_0x45d1ce=!0x1):(_0x552664++,_0x45d1ce=!0x0),_0x46da5d['set'](_0x323596['id'],_0x552664);for(let _0x397e0f=0x0;_0x397e0f<_0x416d86['length'];_0x397e0f++){if('isRemoved'==_0x16261b&&_0x416d86[_0x397e0f]['isAdded']||'isAdded'==_0x16261b&&_0x416d86[_0x397e0f]['isRemoved'])continue;if('text'==_0x416d86[_0x397e0f]['type']){_0x416d86[_0x397e0f]['distance']=0x0;continue;}const _0x503967=_0x46da5d['get'](_0x416d86[_0x397e0f]['pairId']),_0xd12b75=_0x46da5d['get'](_0x416d86[_0x397e0f]['id']);_0x416d86[_0x397e0f]['distance']=_0x503967-_0xd12b75;}}['_getRevisionsRange'](_0x42793e,_0x52b263,_0x5ea001=!0x1){const _0xd043d9=[];let _0x73ee47=this['repository']['getIndex'](_0x42793e),_0x4e3e0e=this['repository']['getIndex'](_0x52b263);for(-0x1==_0x4e3e0e&&(_0x4e3e0e=this['repository']['_revisions']['length'],_0x5ea001=!0x1);_0x73ee47<_0x4e3e0e;)_0xd043d9['push'](this['repository']['getRevision'](_0x73ee47)),_0x73ee47++;return _0x5ea001&&_0xd043d9['push'](this['repository']['getRevision'](_0x73ee47)),_0xd043d9;}['_threeWayMerge'](_0x68e67b,_0x380b38,_0x5b0314,_0x5ab4eb){const _0x1acf6b=this['editor']['model']['schema'];let _0xaf597d=_0x380b38;for(;_0x68e67b[_0xaf597d]&&_0x68e67b[_0xaf597d]['isAdded'];)_0xaf597d++;let _0x3996d7=_0x5ab4eb;for(;_0x5b0314[_0x3996d7]&&_0x5b0314[_0x3996d7]['isRemoved'];)_0x3996d7++;_0x3e0739(_0x68e67b,_0x380b38,_0xaf597d),_0x3e0739(_0x5b0314,_0x5ab4eb,_0x3996d7);const _0x45e3eb=_0x5b0314['slice'](_0x5ab4eb,_0x3996d7)['concat'](_0x68e67b['slice'](_0x380b38,_0xaf597d));return _0x45e3eb['sort']((_0x1d56fd,_0x222c0b)=>_0x1d56fd['side']!=_0x222c0b['side']?_0x1d56fd['side']-_0x222c0b['side']:_0x1d56fd['level']!=_0x222c0b['level']?_0x1d56fd['level']-_0x222c0b['level']:_0x1d56fd['distance']!=_0x222c0b['distance']?_0x222c0b['distance']-_0x1d56fd['distance']:!!_0x1d56fd['isAdded']!=!!_0x222c0b['isAdded']?-0x1==_0x1d56fd['side']||0x0==_0x1d56fd['side']?_0x1d56fd['isAdded']?-0x1:0x1:_0x1d56fd['isAdded']?0x1:-0x1:_0x1d56fd['index']-_0x222c0b['index']),{'commonTape':_0x45e3eb,'iEnd':_0xaf597d,'jEnd':_0x3996d7};function _0x3e0739(_0x5cbea0,_0x5f5d0a,_0x492af6){let _0x316f06=-0x1,_0x3dd429=Number['POSITIVE_INFINITY'],_0x55179a=!0x0;for(let _0x40db4f=_0x5f5d0a;_0x40db4f<_0x492af6;_0x40db4f++)if(_0x1acf6b['isInline'](_0x5cbea0[_0x40db4f]['item'])||(_0x55179a=!0x1),_0x5cbea0[_0x40db4f]['item']['startIndex']<_0x5f5d0a&&(_0x316f06=_0x40db4f),_0x5cbea0[_0x40db4f]['item']['endIndex']>=_0x492af6){_0x3dd429=_0x40db4f;break;}_0x55179a&&(_0x316f06=_0x492af6-0x1);for(let _0x19e3d9=_0x5f5d0a;_0x19e3d9<_0x492af6;_0x19e3d9++)_0x5cbea0[_0x19e3d9]['side']=_0x19e3d9<=_0x316f06?-0x1:_0x19e3d9<_0x3dd429?0x0:0x1,_0x5cbea0[_0x19e3d9]['index']=_0x19e3d9;let _0x11e064=0x0;for(let _0x4a7c51=_0x5f5d0a;_0x4a7c51<=_0x316f06;_0x4a7c51++)0x0==_0x5cbea0[_0x4a7c51]['distance']?_0x5cbea0[_0x4a7c51]['level']=_0x11e064:(_0x11e064++,_0x5cbea0[_0x4a7c51]['level']=_0x11e064,_0x11e064++);for(let _0x1e2aaa=_0x5f5d0a;_0x1e2aaa<_0x492af6;_0x1e2aaa++)0x0==_0x5cbea0[_0x1e2aaa]['side']&&(_0x5cbea0[_0x1e2aaa]['level']=_0x11e064);_0x11e064=0x0;for(let _0x4135a1=_0x492af6-0x1;_0x4135a1>=_0x3dd429;_0x4135a1--)0x0==_0x5cbea0[_0x4135a1]['distance']?_0x5cbea0[_0x4135a1]['level']=_0x11e064:(_0x11e064--,_0x5cbea0[_0x4135a1]['level']=_0x11e064,_0x11e064--);}}['_fixObsoleteTags'](_0x482175){const _0x3f4958=new Map(),_0x24a8ec=this['editor']['model']['schema'];for(let _0x3d2d62=0x1;_0x3d2d62<_0x482175['length'];_0x3d2d62++){let _0x297170,_0x112d73,_0xb2a217;const _0x427e8d=_0x482175[_0x3d2d62],_0x2f12e5=_0x482175[_0x3d2d62-0x1];if('text'==_0x427e8d['type'])continue;if(_0x427e8d['type']!=_0x2f12e5['type'])continue;if(!_0x24a8ec['isBlock'](_0x2f12e5['item'])||_0x24a8ec['isLimit'](_0x2f12e5['item']))continue;if(!_0x24a8ec['isBlock'](_0x427e8d['item'])||_0x24a8ec['isLimit'](_0x427e8d['item']))continue;if((_0x482175[_0x3d2d62]['isAdded']||_0x482175[_0x3d2d62]['isAddSuggestion'])&&_0x482175[_0x3d2d62-0x1]['isRemoved'])_0x297170=_0x482175[_0x3d2d62],_0x112d73=_0x482175[_0x3d2d62-0x1],_0xb2a217=_0x3d2d62-0x1;else{if(!_0x482175[_0x3d2d62]['isRemoved']||!_0x482175[_0x3d2d62-0x1]['isAdded']&&!_0x482175[_0x3d2d62-0x1]['isAddSuggestion'])continue;_0x297170=_0x482175[_0x3d2d62-0x1],_0x112d73=_0x482175[_0x3d2d62],_0xb2a217=_0x3d2d62;}const _0x3640d3=_0x297170['level']==_0x112d73['level'],_0x5f17de=Math['abs'](_0x297170['level'])<Math['abs'](_0x112d73['level'])&&0x0==_0x112d73['distance'];(_0x3640d3||_0x5f17de)&&(_0x3f4958['set'](_0x112d73['id'],_0x297170['id']),_0x482175['splice'](_0xb2a217,0x1),_0x3d2d62--,_0x297170['isAdded']=!0x1);}for(let _0x44da32=0x0;_0x44da32<_0x482175['length'];_0x44da32++)_0x3f4958['has'](_0x482175[_0x44da32]['pairId'])&&(_0x482175[_0x44da32]['pairId']=_0x3f4958['get'](_0x482175[_0x44da32]['pairId']));}['_removeMissingPairs'](_0x259891){const _0x5f260a=new Set(_0x259891['map'](_0x5c60b4=>_0x5c60b4['id']));for(let _0x49d92e=0x0;_0x49d92e<_0x259891['length'];_0x49d92e++)_0x5f260a['has'](_0x259891[_0x49d92e]['pairId'])||0x0==_0x259891[_0x49d92e]['distance']||(_0x259891[_0x49d92e]['isIncorrect']=!0x0);return _0x259891['filter'](_0x50e555=>!_0x50e555['isIncorrect']);}['_markMismatchedRemovedTags'](_0x127b52){const _0xa5fc78=new Set();for(let _0x511fcf=0x0;_0x511fcf<_0x127b52['length'];_0x511fcf++){if(_0xa5fc78['has'](_0x127b52[_0x511fcf]['id'])&&_0x127b52[_0x511fcf]['isRemoved']&&(_0x127b52[_0x511fcf]['isIncorrect']=!0x0),_0x127b52[_0x511fcf]['isIncorrect'])continue;if(0x0==_0x127b52[_0x511fcf]['distance'])continue;if('elementStart'!=_0x127b52[_0x511fcf]['type'])continue;if(null==_0x127b52[_0x511fcf]['pairId'])continue;let _0x3ebcc2=_0x511fcf+0x1,_0x4ec936=0x0;for(;_0x127b52[_0x3ebcc2]['id']!=_0x127b52[_0x511fcf]['pairId'];)'elementStart'==_0x127b52[_0x3ebcc2]['type']?_0x4ec936++:'elementEnd'==_0x127b52[_0x3ebcc2]['type']&&_0x4ec936--,_0x3ebcc2++;if(0x0!=_0x4ec936){if(_0x127b52[_0x511fcf]['isRemoved'])_0x127b52[_0x511fcf]['isIncorrect']=!0x0;else{for(;_0x3ebcc2!=_0x511fcf;)_0x127b52[_0x3ebcc2]['isRemoved']&&0x0!=_0x127b52[_0x3ebcc2]['distance']&&(_0x127b52[_0x3ebcc2]['isIncorrect']=!0x0,_0xa5fc78['add'](_0x127b52[_0x3ebcc2]['pairId'])),_0x3ebcc2--;}}}return _0x127b52['filter'](_0x57b902=>!_0x57b902['isIncorrect']);}['_removeUnsupportedChanges'](_0x41cd9f){const _0x3dd921=this['editor']['model']['schema'];for(let _0x49ec61=0x0;_0x49ec61<_0x41cd9f['length'];_0x49ec61++){if(!(_0x41cd9f[_0x49ec61]['isAdded']||_0x41cd9f[_0x49ec61]['isAddSuggestion']||_0x41cd9f[_0x49ec61]['isRemoved']||_0x41cd9f[_0x49ec61]['isRemoveSuggestion']))continue;if(0x0==_0x41cd9f[_0x49ec61]['distance'])continue;const _0x2380f3=_0x41cd9f[_0x49ec61]['item'];_0x3dd921['isBlock'](_0x2380f3)||_0x3dd921['isLimit'](_0x2380f3)||(_0x41cd9f[_0x49ec61]['isAdded']&&delete _0x41cd9f[_0x49ec61]['isAdded'],_0x41cd9f[_0x49ec61]['isAddSuggestion']&&delete _0x41cd9f[_0x49ec61]['isAddSuggestion'],_0x41cd9f[_0x49ec61]['isRemoveSuggestion']&&delete _0x41cd9f[_0x49ec61]['isRemoveSuggestion'],_0x41cd9f[_0x49ec61]['isRemoved']&&(_0x41cd9f[_0x49ec61]['isIncorrect']=!0x0));}return _0x41cd9f['filter'](_0x4f3370=>!_0x4f3370['isIncorrect']);}['_makeModelFromTape'](_0x4a76d3,_0x4812ce,_0x42bdb6){const _0x402507=new mt(),_0x1871d3=[],_0x188f7b=new Map(),_0x56afb3=this['editor']['model'],_0x463ab2=_0x56afb3['schema'],_0x4c2644=[_0x402507],_0x307cd1={},_0x3ef066={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0xdaf75=null;const _0x41afad=[0x0];for(let _0x52f542=0x0;_0x52f542<_0x4a76d3['length'];_0x52f542++)if('elementStart'===_0x4a76d3[_0x52f542]['type']){_0x4a76d3[_0x52f542]['previousPosition']=_0x56afb3['createPositionFromPath'](_0x402507,_0x41afad);const _0x197021=new ft(_0x4a76d3[_0x52f542]['item']['name'],_0x4a76d3[_0x52f542]['item']['getAttributes']());_0x4c2644[0x0]['_appendChild'](_0x197021),_0x41afad['push'](0x0),_0x4c2644['unshift'](_0x197021),_0x4a76d3[_0x52f542]['nextPosition']=_0x56afb3['createPositionFromPath'](_0x402507,_0x41afad);}else'elementEnd'===_0x4a76d3[_0x52f542]['type']?(_0x4c2644['shift'](),_0x4a76d3[_0x52f542]['previousPosition']=_0x56afb3['createPositionFromPath'](_0x402507,_0x41afad),_0x41afad['pop'](),_0x41afad[_0x41afad['length']-0x1]++,_0x4a76d3[_0x52f542]['nextPosition']=_0x56afb3['createPositionFromPath'](_0x402507,_0x41afad)):(_0x4a76d3[_0x52f542]['previousPosition']=_0x56afb3['createPositionFromPath'](_0x402507,_0x41afad),_0xdaf75?_0xdaf75['_data']+=_0x4a76d3[_0x52f542]['item']['data']:_0xdaf75=new wt(_0x4a76d3[_0x52f542]['item']['data'],_0x4a76d3[_0x52f542]['item']['getAttributes']()),_0x4a76d3[_0x52f542+0x1]&&'text'===_0x4a76d3[_0x52f542+0x1]['type']&&_0x47bc24(_0xdaf75,_0x4a76d3[_0x52f542+0x1]['item'])||(_0x4c2644[0x0]['_appendChild'](_0xdaf75),_0xdaf75=null),_0x41afad[_0x41afad['length']-0x1]+=_0x4a76d3[_0x52f542]['item']['offsetSize'],_0x4a76d3[_0x52f542]['nextPosition']=_0x56afb3['createPositionFromPath'](_0x402507,_0x41afad));for(let _0x3fd02b=0x0;_0x3fd02b<_0x4a76d3['length'];_0x3fd02b++){const _0x3cde4e=_0x4a76d3[_0x3fd02b]['previousPosition'],_0x2d0c92=_0x4a76d3[_0x3fd02b]['nextPosition'];for(const _0x17c234 of _0x4a76d3[_0x3fd02b]['markersStart'])_0x188f7b['set'](_0x17c234,{'start':_0x3cde4e,'end':null});_0xa53845('isRemoveSuggestion',_0x3fd02b,_0x3cde4e,_0x2d0c92),_0xa53845('isAddSuggestion',_0x3fd02b,_0x3cde4e,_0x2d0c92),_0xa53845('isRemoved',_0x3fd02b,_0x3cde4e,_0x2d0c92),_0xa53845('isAdded',_0x3fd02b,_0x3cde4e,_0x2d0c92);for(const _0x4743d2 of _0x4a76d3[_0x3fd02b]['markersEnd']){_0x188f7b['get'](_0x4743d2)['end']=_0x2d0c92;}}for(const [_0x4e800e,_0x4c8bea]of _0x188f7b){const _0x4cb81a=this['editor']['model']['createRange'](_0x4c8bea['start'],_0x4c8bea['end']);_0x402507['markers']['set'](_0x4e800e,_0x4cb81a);}return _0x1871d3['sort']((_0x13c876,_0x5ee4ce)=>{const _0x4ac0fb=_0x402507['markers']['get']('revision:'+_0x13c876['id']),_0x1a7b4b=_0x402507['markers']['get']('revision:'+_0x5ee4ce['id']);return _0x4ac0fb['start']['isBefore'](_0x1a7b4b['start'])?-0x1:_0x4ac0fb['start']['isAfter'](_0x1a7b4b['start'])?0x1:_0x4ac0fb['end']['isBefore'](_0x1a7b4b['end'])?-0x1:_0x4ac0fb['end']['isAfter'](_0x1a7b4b['end'])?0x1:'add'===_0x13c876['type']?-0x1:0x1;}),{'root':_0x402507,'changes':_0x1871d3};function _0xa53845(_0x901214,_0x35b3eb,_0x30898c,_0x308072){const _0x248be3=!!_0x4a76d3[_0x35b3eb][_0x901214],_0xe29d1e=_0x248be3?_0x4a76d3[_0x35b3eb][_0x901214]['userId']:null,_0x3a5769=_0x35b3eb===_0x4a76d3['length']-0x1,_0x26fa3a=_0x3ef066[_0x901214][0x0],_0x543171=_0x463ab2['isObject'](_0x4a76d3[_0x35b3eb]['item']);!_0x307cd1[_0x901214]&&_0x248be3?_0x307cd1[_0x901214]={'start':_0x30898c,'tapeItem':_0x4a76d3[_0x35b3eb],'userId':_0xe29d1e,'type':_0x901214}:_0x307cd1[_0x901214]&&!_0x248be3?(_0x307cd1[_0x901214]['end']=_0x30898c,_0x2c0392(_0x307cd1[_0x901214]),_0x307cd1[_0x901214]=null):_0x307cd1[_0x901214]&&_0x248be3&&_0x307cd1[_0x901214]['userId']!==_0xe29d1e&&(_0x307cd1[_0x901214]['end']=_0x30898c,_0x26fa3a&&_0x26fa3a['userId']===_0x307cd1[_0x901214]['userId']||_0x2c0392(_0x307cd1[_0x901214]),_0x307cd1[_0x901214]={'start':_0x30898c,'tapeItem':_0x4a76d3[_0x35b3eb],'userId':_0xe29d1e,'type':_0x901214}),_0x307cd1[_0x901214]&&_0x543171&&('elementStart'!==_0x4a76d3[_0x35b3eb]['type']||_0x26fa3a&&_0x26fa3a['userId']===_0xe29d1e||_0x3ef066[_0x901214]['unshift']({'userId':_0xe29d1e,'object':_0x4a76d3[_0x35b3eb]['item'],'change':_0x307cd1[_0x901214]}),'elementEnd'===_0x4a76d3[_0x35b3eb]['type']&&_0x26fa3a&&_0x26fa3a['object']===_0x4a76d3[_0x35b3eb]['item']&&(_0x3ef066[_0x901214]['shift'](),_0x307cd1[_0x901214]=_0x26fa3a['change'])),_0x307cd1[_0x901214]&&_0x3a5769&&(_0x307cd1[_0x901214]['end']=_0x308072,_0x2c0392(_0x307cd1[_0x901214]),_0x307cd1[_0x901214]=null);}function _0x2c0392({start:_0x526ad1,end:_0x27fcb9,tapeItem:_0x5254b9,userId:_0x2d5fae,type:_0xb7dde4}){const _0x293622=_0x5254b9['item'],_0x29a622=_0x56afb3['schema']['isBlock'](_0x293622)&&!_0x56afb3['schema']['isLimit'](_0x293622),_0x441e25=_0x526ad1['nodeAfter']==_0x27fcb9['parent']&&_0x27fcb9['isAtStart'];if(_0x29a622&&_0x441e25)return;const _0x2052e1=_0x56afb3['createRange'](_0x526ad1,_0x27fcb9),_0x2ba0ca=_0x4812ce['get'](_0x2d5fae),_0x32c47a=new r({'author':_0x2ba0ca,'type':'isAdded'==_0xb7dde4||'isAddSuggestion'==_0xb7dde4?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0xb7dde4||'isRemoveSuggestion'==_0xb7dde4},'createdAt':new Date(),'rootName':_0x42bdb6});_0x1871d3['push'](_0x32c47a),_0x402507['markers']['set']('revision:'+_0x32c47a['id'],_0x2052e1);}function _0x47bc24(_0x23373b,_0x234019){const _0xbe187c=_0x23373b['getAttributes'](),_0x2eb3b4=_0x234019['getAttributes']();for(const _0xa2cfda of _0xbe187c){if(_0xa2cfda[0x1]!==_0x234019['getAttribute'](_0xa2cfda[0x0]))return!0x1;_0x2eb3b4['next']();}return _0x2eb3b4['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x57370c=>{const _0x2b0ddc=_0x57370c['markerName']['split'](':')[0x1],_0x16c7de=this['_getChangeFromId'](_0x2b0ddc);if(!_0x16c7de)return null;const _0x3c7622='add'==_0x16c7de['type']?'insertion':'deletion',_0x39d5e7=['ck-suggestion-marker','ck-suggestion-marker-'+_0x3c7622];return _0x16c7de['data']['isSuggestion']&&_0x39d5e7['push']('ck-suggestion-marker-'+_0x3c7622+'-new'),this['activeChange']==_0x16c7de&&_0x39d5e7['push']('ck-suggestion-marker--active'),{'classes':_0x39d5e7,'attributes':{'data-change-id':_0x2b0ddc}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x534b5f=>{_0x534b5f['on']('element:pre',(_0x221f0f,_0x1a480a,_0x107fe6)=>{const _0xe2353f=_0x1a480a['viewItem']['getChild'](0x0);if(!_0xe2353f||!_0xe2353f['is']('element','code'))return;if(!_0x107fe6['consumable']['consume'](_0xe2353f,{'attributes':['vid_start','vid_end']}))return;const _0x2e792b=_0x1a480a['modelRange']['start']['nodeAfter'];_0x107fe6['writer']['setAttribute']('vid_start',_0xe2353f['getAttribute']('vid_start'),_0x2e792b),_0x107fe6['writer']['setAttribute']('vid_end',_0xe2353f['getAttribute']('vid_end'),_0x2e792b);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x229bf9=>{_0x229bf9['on']('element',(_0x547f3f,_0x46009c,_0x4fca2d)=>{if(!_0x4fca2d['consumable']['consume'](_0x46009c['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x46009c['modelRange']['isCollapsed'])return;const _0x5d60f5=_0x46009c['modelRange']['start']['nodeAfter'];_0x5d60f5['hasAttribute']('vid_start')||_0x5d60f5['hasAttribute']('vid')||(_0x4fca2d['writer']['setAttribute']('vid_start',_0x46009c['viewItem']['getAttribute']('vid_start'),_0x5d60f5),_0x4fca2d['writer']['setAttribute']('vid_end',_0x46009c['viewItem']['getAttribute']('vid_end'),_0x5d60f5));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x143db0=>_0x143db0['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x3b3410,[,_0x456863])=>{['vid_start','vid_end','vid']['includes'](_0x456863)&&(_0x3b3410['return']=!0x0,_0x3b3410['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x407600=>{_0x407600['on']('attribute:vid',(_0x5b52fe,_0x90c0a8,_0xc6435)=>{if('\x20'!=_0x90c0a8['item']['data']||_0x90c0a8['item']['parent']['maxOffset']>0x1)return;if(!_0xc6435['consumable']['consume'](_0x90c0a8['item'],_0x5b52fe['name']))return;const _0x1950d6=_0xc6435['writer'],_0x1d5181=_0xc6435['mapper']['toViewRange'](_0x90c0a8['range']);_0x1950d6['wrap'](_0x1d5181,_0x1950d6['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x394b16){const _0xbb1949=_0x394b16['plugins']['get']('RevisionViewer');return(_0x5bb37e,_0x1e301b,_0x2704a6)=>{const _0x1dacd2=_0x1e301b['markerName']['split'](':')[0x1],_0x11fe52=_0xbb1949['_getChangeFromId'](_0x1dacd2);if(!_0x11fe52)return null;const _0x1f7982='add'==_0x11fe52['type']?'split':'merge';if(!_0x2704a6['consumable']['test'](_0x1e301b['markerRange'],_0x5bb37e['name']))return;const _0x97ed77=_0x1e301b['markerRange']['getWalker'](),_0x41ce85=_0x1e301b['markerRange']['start'],_0x5cd118=_0x394b16['model']['schema'];let _0x413925=null,_0x916c8e=null,_0x2ac79c=!0x1,_0x5cfea7=!0x1;for(const _0x1dd5e1 of _0x97ed77){const _0x199756=_0x1dd5e1['item'];_0x2ac79c=_0x2ac79c||_0x5cd118['isContent'](_0x199756);const _0x5a6928=_0x2704a6['mapper']['toViewElement'](_0x199756);if(_0x5a6928&&_0x5a6928['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x1dd5e1['type']&&(_0x5cd118['isBlock'](_0x199756)&&!_0x5cd118['isLimit'](_0x199756)&&(_0x199756['nextSibling']||_0x41ce85['isAtEnd']?_0x413925&&_0x413925['parent']==_0x199756||(_0x413925=_0x199756,_0x248415(_0x1dd5e1['previousPosition']),_0x5cfea7=!0x0):_0x916c8e=_0x916c8e||_0x1dd5e1['previousPosition']));}function _0x248415(_0x461c17){const _0x2a5e9e=_0x2704a6['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x1f7982}),_0x30494d=_0x2704a6['mapper']['toViewPosition'](_0x461c17);_0x11fe52['data']['isSuggestion']&&_0x2704a6['writer']['addClass']('ck-suggestion-marker-'+_0x1f7982+'-new',_0x2a5e9e),_0xbb1949['activeChange']==_0x11fe52&&_0x2704a6['writer']['addClass']('ck-suggestion-marker--active',_0x2a5e9e),_0x2704a6['writer']['insert'](_0x30494d,_0x2a5e9e),_0x2704a6['mapper']['bindElementToMarker'](_0x2a5e9e,_0x1e301b['markerName']);}_0x2ac79c||_0x5cfea7||!_0x916c8e||_0x248415(_0x916c8e);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x41eaa4,_0x3e6945,_0x534976)=>{const _0x268634=_0x534976['mapper']['markerNameToElements'](_0x3e6945['markerName']);if(_0x268634){for(const _0x172435 of _0x268634)(_0x172435['hasClass']('ck-suggestion-marker-split')||_0x172435['hasClass']('ck-suggestion-marker-merge'))&&(_0x534976['mapper']['unbindElementFromMarkerName'](_0x172435,_0x3e6945['markerName']),_0x534976['writer']['remove'](_0x172435));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x137a9e,_0x52b955,_0x422a30)=>{const _0x2997d2=_0x52b955['markerName']['split'](':')[0x1],_0x1999f8=this['_getChangeFromId'](_0x2997d2);if(!_0x1999f8)return null;const _0x6f4801='add'==_0x1999f8['type']?'split':'merge';if(_0x422a30['consumable']['test'](_0x52b955['markerRange'],_0x137a9e['name']))for(const _0x31f1bd of _0x52b955['markerRange']['getItems']()){if(!_0x31f1bd['is']('element','softBreak'))continue;const _0xc067ac=_0x422a30['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x6f4801}),_0x1ad713=_0x422a30['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x31f1bd));_0x1999f8['data']['isSuggestion']&&_0x422a30['writer']['addClass']('ck-suggestion-marker-'+_0x6f4801+'-new',_0xc067ac),this['activeChange']==_0x1999f8&&_0x422a30['writer']['addClass']('ck-suggestion-marker--active',_0xc067ac),_0x422a30['writer']['insert'](_0x1ad713,_0xc067ac),_0x422a30['mapper']['bindElementToMarker'](_0xc067ac,_0x52b955['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x17187d=>{for(const _0x2aea47 of this['editor']['model']['document']['getRootNames']()){const _0x50cc26=this['editor']['model']['document']['getRoot'](_0x2aea47),_0x214c44=this['editor']['editing']['view']['document']['getRoot'](_0x2aea47);if(_0x214c44){const _0x36aabc=_0x50cc26['getAttribute']('revisionHistoryAttachChange');if(_0x17187d['removeAttribute']('data-change-id',_0x214c44),_0x17187d['removeClass']('ck-revision-history-root-add',_0x214c44),_0x17187d['removeClass']('ck-revision-history-root-remove',_0x214c44),_0x17187d['removeClass']('ck-revision-history-root--active',_0x214c44),_0x36aabc){const _0x16b0e6=this['_getChangeFromId'](_0x36aabc);if(!_0x16b0e6)return null;_0x17187d['setAttribute']('data-change-id',_0x36aabc,_0x214c44),_0x17187d['addClass']('ck-revision-history-root-'+_0x16b0e6['type'],_0x214c44),this['activeChange']==_0x16b0e6&&_0x17187d['addClass']('ck-revision-history-root--active',_0x214c44);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x207523=>'revision-comment:'+_0x207523,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x49d307=>'revision-suggestion:'+_0x49d307,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x3b8e30=>({'name':'suggestion:'+_0x3b8e30,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x341c71=>{const _0x33d46e=_0x341c71['markerName']['split'](':')[0x1];return'insertion'!=_0x33d46e&&'deletion'!=_0x33d46e?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x33d46e]};}}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:deletion',Z(this['editor'],'merge'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:insertion',Z(this['editor'],'split'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision-suggestion',(_0x54244c,_0x2a5a65,_0x1d413d)=>{const _0x20715a=_0x1d413d['mapper']['markerNameToElements'](_0x2a5a65['markerName']);if(_0x20715a){for(const _0x403735 of _0x20715a)_0x403735['is']('uiElement')&&(_0x1d413d['mapper']['unbindElementFromMarkerName'](_0x403735,_0x2a5a65['markerName']),_0x1d413d['writer']['remove'](_0x403735));}},{'priority':'high'});}['_getChangeFromId'](_0x381035){return this['_changeIdToChange']['get'](_0x381035);}['_getViewForChange'](_0x589ebb){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new X(this['editor']['locale'],_0x589ebb),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x320b3b,_0x322c2d,_0x21637f,_0x51e74a)=>{_0x51e74a&&this['_balloon']['remove'](_0x51e74a),_0x21637f&&(this['_balloon']['add']({'view':_0x21637f,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x2c1595=this['editor']['editing'],_0x2ca1e2=this['_getChangeFromId'](_0x21637f['changeId']);let _0x271c2f;if(_0x2ca1e2['data']['isOnRoot']){const _0x202961=_0x2c1595['view']['getDomRoot'](_0x2ca1e2['rootName']);_0x271c2f=Array['from'](_0x202961['getClientRects']());}else{const _0x3371d1=this['editor']['model']['markers']['get']('revision:'+_0x21637f['changeId']);_0x271c2f=Array['from'](_0x2c1595['mapper']['markerNameToElements'](_0x3371d1['name']))['map'](_0xdbeb2d=>_0x2c1595['view']['domConverter']['mapViewToDom'](_0xdbeb2d))['map'](_0xf2333d=>Array['from'](_0xf2333d['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x271c2f[0x0];return _0x271c2f['find'](_0xeea292=>_0xeea292['top']-0x3<=this['_activeViewTarget']['y']&&_0xeea292['bottom']+0x3>=this['_activeViewTarget']['y']&&_0xeea292['left']-0x3<=this['_activeViewTarget']['x']&&_0xeea292['right']+0x3>=this['_activeViewTarget']['x'])||_0x271c2f[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0xa659aa,_0x5e7b06,_0x1bc497,_0x29b467)=>{this['activeView']=_0x1bc497?this['_getViewForChange'](_0x1bc497):null,this['editor']['model']['change'](()=>{const _0x36bf6f=this['editor']['editing'];_0x29b467&&(_0x29b467['data']['isOnRoot']?_0x36bf6f['view']['change'](_0x4d8d2d=>{_0x4d8d2d['removeClass']('ck-revision-history-root--active',_0x36bf6f['view']['document']['getRoot'](_0x29b467['rootName']));}):_0x36bf6f['reconvertMarker']('revision:'+_0x29b467['id'])),_0x1bc497&&(_0x1bc497['data']['isOnRoot']?_0x36bf6f['view']['change'](_0x3c7910=>{_0x3c7910['addClass']('ck-revision-history-root--active',_0x36bf6f['view']['document']['getRoot'](_0x1bc497['rootName']));}):_0x36bf6f['reconvertMarker']('revision:'+_0x1bc497['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x23f074,_0x567bf0)=>{if(this['activeChange'])return;const _0x563303=this['_findChangeIdFromDomTarget'](_0x567bf0['target']),_0x52e247=this['_changeIdToChange']['get'](_0x563303);_0x52e247?(this['_activeViewTarget']={'x':_0x567bf0['domEvent']['x'],'y':_0x567bf0['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x52e247)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x43619e,_0x2b2476)=>{const _0x4227e5=this['_findChangeIdFromDomTarget'](_0x2b2476['target']),_0x2c8462=this['_changeIdToChange']['get'](_0x4227e5);_0x2c8462?(this['_activeViewTarget']={'x':_0x2b2476['domEvent']['x'],'y':_0x2b2476['domEvent']['y']},_0x2c8462===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x2c8462):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x52b8ec){do{const _0x129e80=_0x52b8ec['getAttribute']('data-change-id');if(_0x129e80)return _0x129e80;_0x52b8ec=_0x52b8ec['parent'];}while(_0x52b8ec);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x20cdd4=>{for(const _0x559b4c of this['editor']['model']['markers'])_0x20cdd4['removeMarker'](_0x559b4c);});}}function Z(_0x2ac33b,_0x518be2){return(_0x59c9ff,_0x35211d,_0x25652a)=>{if(!_0x25652a['consumable']['test'](_0x35211d['markerRange'],_0x59c9ff['name']))return;const _0x4a7e6d=_0x35211d['markerRange']['getWalker'](),_0x3f0e5f=_0x35211d['markerRange']['start'],_0x58e7bb=_0x2ac33b['model']['schema'];let _0x434593=null,_0x575d00=null,_0xd4bfc8=!0x1,_0x28ce9d=!0x1;for(const _0x4ba0cd of _0x4a7e6d){const _0xa76e87=_0x4ba0cd['item'];_0xd4bfc8=_0xd4bfc8||_0x58e7bb['isContent'](_0xa76e87);const _0x35a513=_0x25652a['mapper']['toViewElement'](_0xa76e87);if(_0x35a513&&_0x35a513['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x4ba0cd['type']&&(_0x58e7bb['isBlock'](_0xa76e87)&&!_0x58e7bb['isLimit'](_0xa76e87)&&(_0xa76e87['nextSibling']||_0x3f0e5f['isAtEnd']?_0x434593&&_0x434593['parent']==_0xa76e87||(_0x434593=_0xa76e87,_0x4652b9(_0x4ba0cd['previousPosition']),_0x28ce9d=!0x0):_0x575d00=_0x575d00||_0x4ba0cd['previousPosition']));}function _0x4652b9(_0x1345d7){const _0x1db31a=_0x25652a['mapper']['toViewPosition'](_0x1345d7),_0x2f28ca=_0x25652a['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x518be2});_0x25652a['writer']['insert'](_0x1db31a,_0x2f28ca),_0x25652a['mapper']['bindElementToMarker'](_0x2f28ca,_0x35211d['markerName']);}_0xd4bfc8||_0x28ce9d||!_0x575d00||_0x4652b9(_0x575d00);};}class pt extends _0x1d782e{constructor(_0xd3d341){super(_0xd3d341);const _0x4d8545=_0xd3d341['plugins']['get'](d);this['affectsData']=!0x1,this['listenTo'](_0x4d8545,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x4d8545,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x352074=this['editor'],_0x2f20b9=_0x352074['plugins']['get'](d),_0xca07d8=_0x2f20b9['isReady']?_0x2f20b9['diff']['newRevisionId']:null;_0x352074['config']['get']('revisionHistory')['restoreRevisionCallback'](_0xca07d8);}['refresh'](){const {isReady:_0x5c612b,isEnabled:_0x4e8870,repository:_0x5c35f7,diff:_0x26be50}=this['editor']['plugins']['get'](d),_0x347a9b=_0x26be50&&_0x5c35f7['getLaterVisibleRevision'](_0x26be50['newRevisionId']);this['isEnabled']=_0x5c612b&&_0x4e8870&&Boolean(_0x347a9b);}}class _t extends _0x1d782e{['_step'];constructor(_0x376db5,{direction:_0x1aafb3}){super(_0x376db5);const _0x427924=_0x376db5['plugins']['get'](d);this['affectsData']=!0x1,this['_step']='forward'===_0x1aafb3?0x1:-0x1,this['listenTo'](_0x427924,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x427924,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x427924,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x382d9d=this['editor'],_0x23cf60=_0x382d9d['plugins']['get'](d),{isNavigationMode:_0x599db7,currentChangeNumber:_0x1b4f47}=_0x23cf60;let _0x2319bc;if(_0x23cf60['activeChange']=_0x599db7?_0x23cf60['diff']['changes']['get'](_0x1b4f47+this['_step']):_0x23cf60['diff']['changes']['first'],_0x23cf60['activeChange']['data']['isOnRoot'])_0x2319bc=_0x382d9d['editing']['view']['getDomRoot'](_0x23cf60['activeChange']['rootName']);else{const _0x3e6fc6=_0x382d9d['model']['markers']['get']('revision:'+_0x23cf60['activeChange']['id']);_0x2319bc=_0x40ad99(_0x382d9d['editing'],_0x3e6fc6);}_0x170d53({'target':_0x2319bc,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x1e1839,currentChangeNumber:_0x25a4f1,numberOfChanges:_0x4c3fd6,isReady:_0x3992ac,isEnabled:_0x1a3f9c}=this['editor']['plugins']['get'](d);this['isEnabled']=!!(_0x1a3f9c&&_0x3992ac&&_0x4c3fd6)&&(!_0x1e1839||(0x1===this['_step']?_0x25a4f1<_0x4c3fd6-0x1:_0x25a4f1>0x0));}}class li extends ts{constructor(_0x10d957){super(_0x10d957);const _0x25118c=this['bindTemplate'],_0x4e45bf=new te(_0x10d957),_0x39e6fd=new te(_0x10d957);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',(_0x477902,_0x312e00)=>_0x477902&&_0x312e00>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x332bb3,_0x401d5e,_0x44dba7,_0x1c6004)=>{if(!_0x332bb3)return m(_0x10d957,'Loading...');if(!_0x44dba7)return m(_0x10d957,'No\x20changes');const _0x56671a=m(_0x10d957,'NUMBER_OF_CHANGES',_0x44dba7);return _0x1c6004?m(_0x10d957,'X_OF_Y_CHANGES',[_0x401d5e+0x1,_0x44dba7]):_0x56671a;}),_0x4e45bf['set']({'label':m(_0x10d957,'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'}),_0x39e6fd['set']({'label':m(_0x10d957,'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'}),_0x4e45bf['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x39e6fd['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x4e45bf['on']('execute',()=>this['fire']('execute','backward')),_0x39e6fd['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',_0x25118c['if']('_isStatusLabelVisible','ck-hidden',_0x59dd6d=>!_0x59dd6d)]},'children':[{'text':_0x25118c['to']('isNavigationMode',_0x54d895=>_0x54d895?m(_0x10d957,'EDIT_X_OF_Y_REVISIONS')+':\x20':m(_0x10d957,'Total')+':\x20')}]},{'text':_0x25118c['to']('_statusText')}]},new _0x4101c0(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x4e45bf,_0x39e6fd]}]});}}const le='ck-editor__editable__loading-overlay';class ge extends _0x1420a4{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x3714c7=this['editor']['editing']['view'];_0x3714c7['change'](_0x964742=>{for(const _0xe05202 of _0x3714c7['document']['roots'])_0x964742['addClass'](le,_0xe05202);});}['hide'](){const _0x2d360c=this['editor']['editing']['view'];_0x2d360c['change'](_0x53f9ea=>{for(const _0x52569d of _0x2d360c['document']['roots'])_0x53f9ea['removeClass'](le,_0x52569d);});}}class g extends _0x1420a4{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[d,ge];}['init'](){const _0x56b112=this['editor'],_0x39f179=_0x56b112['plugins']['get'](d),_0x25d734=_0x56b112['plugins']['get'](ge);_0x56b112['ui']['componentFactory']['add']('exitToEditing',_0x538dd1=>{const _0x39be8f=new te(_0x538dd1);return _0x39be8f['set']({'label':m(_0x538dd1,'Back\x20to\x20editing'),'icon':_0x247700['undo'],'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x39be8f,'execute',()=>{_0x56b112['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x39be8f;}),_0x56b112['ui']['componentFactory']['add']('restoreRevision',_0x2618bb=>{const _0x1612d4=new te(_0x2618bb);return _0x1612d4['set']({'label':m(_0x2618bb,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x1612d4['bind']('isEnabled')['to'](_0x56b112['commands']['get']('restoreRevision')),this['listenTo'](_0x1612d4,'execute',()=>_0x56b112['execute']('restoreRevision')),_0x1612d4;}),_0x56b112['ui']['componentFactory']['add']('changesNavigation',_0x201032=>{const _0x29709b=new li(_0x201032),_0x4a0c5a=_0x56b112['commands']['get']('showPreviousChange'),_0x5777d8=_0x56b112['commands']['get']('showNextChange');return _0x29709b['bind']('isBackwardNavigationEnabled')['to'](_0x4a0c5a,'isEnabled'),_0x29709b['bind']('isForwardNavigationEnabled')['to'](_0x5777d8,'isEnabled'),_0x29709b['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x39f179),this['listenTo'](_0x29709b,'execute',(_0x1667ad,_0x5dabb8)=>{_0x56b112['execute']('forward'===_0x5dabb8?'showNextChange':'showPreviousChange');}),_0x29709b;}),_0x25d734['show'](),_0x39f179['on']('change:isReady',(_0x45b833,_0x2c424c,_0x566408)=>{_0x566408?_0x25d734['hide']():_0x25d734['show']();});}}class at extends _0xe538c1{['_resizeObserver']=null;constructor(_0x4b9198,_0x3662db){super(_0x4b9198,_0x3662db);const _0x23147c=this['bindTemplate'];this['set']({'label':m(_0x4b9198,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=m(_0x4b9198,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x23147c['to']('_tooltipString'),'data-cke-tooltip-position':'s','data-cke-tooltip-class':'ck-tooltip_multi-line'}});}['render'](){super['render'](),this['_resizeObserver']=new nt(this['fieldView']['element'],()=>this['_updateTooltipText']()),this['listenTo'](this['fieldView'],'input',()=>this['_updateTooltipText']());}['destroy'](){super['destroy'](),this['_resizeObserver']&&this['_resizeObserver']['destroy']();}['_updateTooltipText'](){const _0x5e25ca=this['fieldView']['element'];this['_tooltipString']=_0x5e25ca['scrollWidth']>_0x5e25ca['clientWidth']&&_0x5e25ca['value']||'';}}class ri extends ts{constructor(_0x482a4e,_0x521360,_0x67e42a){super(_0x482a4e);const _0x27e2df=new _0x151b45();_0x27e2df['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 _0x1a131f=['ck','ck-revision-history-sidebar__revision-author'];_0x67e42a&&_0x1a131f['push']('ck-revision-history-sidebar__revision-author_creator');const _0x2419ee=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':m(_0x482a4e,_0x67e42a?'Revision\x20creator':'Revision\x20author')},'children':[_0x27e2df,_0x521360['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x1a131f},'children':_0x2419ee});}}function oi(_0x58a4f0,_0x1f81b4){const _0xc8a8ee=_0x58a4f0['bindTemplate'],_0x1a22e0=_0x58a4f0['locale'],_0x626e70=_0x1e0a60(_0x1a22e0);_0x626e70['panelPosition']='sw';const _0x1a9d37=function(_0x3cc103,_0x4884de){const _0x596780=function(_0x26d074,_0x283996){const _0x12e8b1=_0x26d074['locale'],_0x219ca1={'Compare\x20against\x20selected':m(_0x12e8b1,'Compare\x20against\x20selected'),'Name\x20this\x20revision':m(_0x12e8b1,'Name\x20this\x20revision'),'Restore\x20this\x20revision':m(_0x12e8b1,'Restore\x20this\x20revision')};return _0x283996['map'](_0x3a629e=>{const _0x24ac03=_0x219ca1[_0x3a629e['name']];return _0x24ac03&&_0x24ac03!==_0x3a629e['name']&&(_0x3a629e['name']=_0x24ac03),_0x3a629e;});}(_0x3cc103,_0x4884de),_0x9adb05=new _0xcf6e93();for(const _0x3f69a1 of _0x596780){const _0x1ccbbb={'type':'button','model':new _0x58fc48({'label':_0x3f69a1['name'],'class':_0x3f69a1['class'],'withText':!0x0,'role':'menuitem','_action':_0x3f69a1['action']})};_0x1ccbbb['model']['bind']('isEnabled')['to'](_0x3cc103,'isActionsDropdownOpen',_0x271e33=>'function'!=typeof _0x3f69a1['isEnabled']||(!_0x271e33||_0x3f69a1['isEnabled'](_0x3cc103))),_0x9adb05['add'](_0x1ccbbb);}return _0x9adb05;}(_0x58a4f0,_0x1f81b4);return _0x58a4f0['bind']('isActionsDropdownOpen')['to'](_0x626e70,'isOpen'),_0x626e70['buttonView']['set']({'label':m(_0x1a22e0,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x247700['threeVerticalDots']}),_0x626e70['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0xc8a8ee['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0xc8a8ee['to'](_0x40523e=>_0x40523e['stopPropagation']())}}),_0x626e70['on']('execute',_0x218b5c=>{_0x58a4f0['isReady']&&'function'==typeof _0x218b5c['source']['_action']&&_0x218b5c['source']['_action'](_0x58a4f0);}),to(_0x626e70,_0x1a9d37,{'role':'menu'}),_0x626e70['listenTo'](_0x58a4f0,'change:isActionsDropdownOpen',(_0x2b09aa,_0x3fb6c3,_0x14f488)=>{if(_0x14f488)for(const _0x20f60c of _0x626e70['listView']['items']){const _0x22bc47=_0x20f60c['children']['first'],_0xc7d649=_0x1f81b4['find'](_0x13f3f6=>_0x13f3f6['action']===_0x22bc47['_action'])['isVisible'];_0x20f60c['isVisible']=void 0x0===_0xc7d649||_0xc7d649(_0x58a4f0);}}),_0x626e70;}class hi extends/* #__PURE__ -- @preserve */
|
|
26
|
-
|
|
23
|
+
import{ObservableMixin as _0xe5b2fd,uid as _0x4ff600,Collection as _0x4e4c8a,logWarning as _0x19ff0e,FocusTracker as _0x4dac43,KeystrokeHandler as _0x533f48,scrollViewportToShowTarget as _0x30ca02,ResizeObserver as at,ElementReplacer as ht,CKEditorError as _0x4dc96e}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x2b10be,set as _0x31a6b3,unset as _0x19a254,isEqual as _0x3ee13a}from'lodash-es';import{Plugin as _0x32454b,PendingActions as _0x4bc6b8,icons as _0x15f173,Command as _0x5a0586,ElementApiMixin as it,Editor as tt}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0xa55a60,getMarkerDomElement as _0x51bacb,ConfirmMixin as _0x2a2fd6,sanitizeEditorConfig as _0x162ae5}from'ckeditor5-collaboration/dist/index.js';import{ViewDocumentFragment as _0x363fce,Element as ft,Range as vt,ViewUIElement as _0x429f21,ViewRawElement as _0x496ec4,ViewEmptyElement as _0x23f14e,ViewAttributeElement as _0x5b9586,ViewContainerElement as _0x741c8a,Position as gt,ViewText as _0x363037,ViewElement as _0x50af6c,DocumentFragment as mt,Text as wt}from'@ckeditor/ckeditor5-engine/dist/index.js';import{View as _0x4a3822,injectCssTransitionDisabler as ts,submitHandler as _0x993ef8,LabeledFieldView as nt,createLabeledInputText as _0x5e5100,createDropdown as _0x2e60bd,ListView as te,ListItemView as _0x37f162,ButtonView as _0x20da59,MenuBarMenuView as _0x2d4176,MenuBarMenuListView as _0x1c4cb5,MenuBarMenuListItemView as _0x4ef73b,MenuBarMenuListItemButtonView as _0x445b04,ContextualBalloon as _0x51b82d,ToolbarSeparatorView as _0x5cb790,IconView as _0x5d4041,addListToDropdown as _0x1d265f,ViewModel as to,EditorUI as st,normalizeToolbarConfig as ot,BoxedEditorUIView as ct,StickyPanelView as ut,ToolbarView as lt,InlineEditableUIView as dt}from'@ckeditor/ckeditor5-ui/dist/index.js';import{DateTime as _0x2b215c}from'luxon';class a extends/* #__PURE__ -- @preserve */
|
|
24
|
+
_0xe5b2fd(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x155441){super(),this['id']=_0x155441['id']||_0x4ff600(),this['creator']=_0x155441['creator']||null,this['authors']=_0x155441['authors']||[],this['diffData']=_0x155441['diffData']||null,this['toVersion']=_0x155441['toVersion']||0x0,this['fromVersion']=_0x155441['fromVersion']||0x0,this['set']('name',_0x155441['name']||''),this['set']('createdAt',_0x155441['createdAt']||new Date()),this['set']('attributes',_0x155441['attributes']||{});}['setName'](_0x4c7c1f){this['_update']({'name':_0x4c7c1f});}['setAttribute'](_0x1d13c6,_0x15afea){const _0x15fa82=_0x2b10be(this['attributes']);_0x31a6b3(_0x15fa82,_0x1d13c6,_0x15afea),this['_update']({'attributes':_0x15fa82});}['removeAttribute'](_0x456d9e){const _0x9e5d5c=_0x2b10be(this['attributes']);_0x19a254(_0x9e5d5c,_0x456d9e),this['_update']({'attributes':_0x9e5d5c});}['_update'](_0x516e58,_0x224dd3=!0x1){let _0x5200ab=!0x1;const _0x2b3eca={'id':this['id']},_0x5e035a=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0xf14ea8 of _0x5e035a){const _0x4e422f=_0x516e58[_0xf14ea8];void 0x0!==_0x4e422f&&_0x4e422f!==this[_0xf14ea8]&&(this[_0xf14ea8]=_0x4e422f,_0x2b3eca[_0xf14ea8]=_0x4e422f,_0x5200ab=!0x0);}_0x5200ab&&(_0x2b3eca['authors']&&(_0x2b3eca['authorsIds']=_0x2b3eca['authors']['map'](_0x4f7832=>_0x4f7832['id']),delete _0x2b3eca['authors']),this['fire']('_update',_0x2b3eca,_0x224dd3));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x2ac1b7=>_0x2ac1b7['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class j extends _0x32454b{['_revisions'];static get['requires'](){return[_0xa55a60];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x27e58c){super(_0x27e58c),this['_revisions']=new _0x4e4c8a();}['afterInit'](){!async function(_0x3d0bf7){const _0x1bce40=_0x4a272b([0x55,0x6f,0x52,0x59,0x43,0x39,0x4b,0x6a,0x38,0x70,0x48,0x63,0x69,0x5a,0x73,0x33,0x37,0x67,0x42,0x30,0x44,0x62,0x35,0x72,0x46,0x36,0x54,0x68,0x31,0x7a,0x4e,0x6e,0x53,0x50,0x66,0x45,0x58,0x78,0x4d,0x4c,0x56,0x77,0x79,0x6d,0x4f,0x6b,0x71,0x75,0x76,0x34,0x74,0x41,0x4a,0x47,0x61,0x49,0x32,0x57,0x65,0x51,0x6c,0x64]),_0xbeaa66=0xeb829,_0x5bc1a9=0x73bcf348,_0x52b864=0x73bb9258^_0x5bc1a9,_0x4b2f41=window[_0x4a272b([0x44,0x61,0x74,0x65])][_0x4a272b([0x6e,0x6f,0x77])](),_0x5b44ef=_0x3d0bf7[_0x4a272b([0x65,0x64,0x69,0x74,0x6f,0x72])],_0xccd8a9=new window[(_0x4a272b([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x3cc157=>{_0x5b44ef[_0x4a272b([0x6f,0x6e,0x63,0x65])](_0x4a272b([0x72,0x65,0x61,0x64,0x79]),_0x3cc157);}),_0x2ad806={[_0x4a272b([0x6b,0x74,0x79])]:_0x4a272b([0x45,0x43]),[_0x4a272b([0x75,0x73,0x65])]:_0x4a272b([0x73,0x69,0x67]),[_0x4a272b([0x63,0x72,0x76])]:_0x4a272b([0x50,0x2d,0x32,0x35,0x36]),[_0x4a272b([0x78])]:_0x4a272b([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]),[_0x4a272b([0x79])]:_0x4a272b([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]),[_0x4a272b([0x61,0x6c,0x67])]:_0x4a272b([0x45,0x53,0x32,0x35,0x36])},_0x32c074=_0x5b44ef[_0x4a272b([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x4a272b([0x67,0x65,0x74])](_0x4a272b([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x43782e(){let _0x81c8b6,_0x485d5c=null,_0x195de9=null;try{if(_0x32c074==_0x4a272b([0x47,0x50,0x4c]))return _0x4a272b([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x81c8b6=_0x56db62(),!_0x81c8b6)return _0x4a272b([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x81c8b6[_0x4a272b([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x195de9=_0x5bb6f1(_0x81c8b6[_0x4a272b([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x81c8b6[_0x4a272b([0x6a,0x74,0x69])])),await _0x54ea17()?_0x3bf601()?_0x1e90cc()?_0x4a272b([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x1015a7()?(_0x81c8b6[_0x4a272b([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x4a272b([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x485d5c=_0x19e910(_0x4a272b([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x81c8b6[_0x4a272b([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x4a272b([0x74,0x72,0x69,0x61,0x6c])&&(_0x485d5c=_0x19e910(_0x4a272b([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x4ad52d()):_0x4a272b([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x4a272b([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x4a272b([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch(_0x5cc242){return _0x4a272b([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x1e90cc(){const _0x1ddb78=[_0x4a272b([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x4a272b([0x74,0x72,0x69,0x61,0x6c])][_0x4a272b([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x81c8b6[_0x4a272b([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x4b2f41/0x3e8:0xe10*_0x52b864;return _0x81c8b6[_0x4a272b([0x65,0x78,0x70])]<_0x1ddb78;}function _0x3bf601(){const _0x3eb1a3=_0x81c8b6[_0x4a272b([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x3eb1a3)return!0x1;if(_0x3eb1a3[_0x4a272b([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4a272b([0x2a])))return!0x0;if(_0x3eb1a3[_0x4a272b([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4a272b([0x52,0x48])))return!0x0;if(_0x3eb1a3[_0x4a272b([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4a272b([0x52,0x52,0x48]))){if(_0x2f93e2())return!0x0;if(_0x5908c1()||_0x4610af())return!0x0;}return!0x1;}function _0x1015a7(){const _0xa30984=_0x81c8b6[_0x4a272b([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0xa30984||0x0==_0xa30984[_0x4a272b([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x482824}=new URL(window[_0x4a272b([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0xa30984[_0x4a272b([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x482824))return!0x0;const _0x26c1e5=_0x482824[_0x4a272b([0x73,0x70,0x6c,0x69,0x74])](_0x4a272b([0x2e]));return _0xa30984[_0x4a272b([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x29762f=>_0x29762f[_0x4a272b([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4a272b([0x2a])))[_0x4a272b([0x6d,0x61,0x70])](_0x379b81=>_0x379b81[_0x4a272b([0x73,0x70,0x6c,0x69,0x74])](_0x4a272b([0x2e])))[_0x4a272b([0x73,0x6f,0x6d,0x65])](_0x4d7bf3=>_0x26c1e5[_0x4a272b([0x65,0x76,0x65,0x72,0x79])]((_0x35aed4,_0x476193)=>_0x4d7bf3[_0x476193]===_0x35aed4||_0x4d7bf3[_0x476193]===_0x4a272b([0x2a])));}function _0x4ad52d(){return _0x485d5c&&_0x195de9?new window[(_0x4a272b([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x4ce70e,_0x4deca7)=>{_0x485d5c[_0x4a272b([0x74,0x68,0x65,0x6e])](_0x4ce70e,_0x4deca7),_0x195de9[_0x4a272b([0x74,0x68,0x65,0x6e])](_0x30573b=>{_0x30573b!=_0x4a272b([0x56,0x61,0x6c,0x69,0x64])&&_0x4ce70e(_0x30573b);},_0x4deca7);}):_0x485d5c||_0x195de9||_0x4a272b([0x56,0x61,0x6c,0x69,0x64]);}}function _0x5bb6f1(_0xad2191,_0x51613b){return new window[(_0x4a272b([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x16c378=>{if(_0x516333())return _0x16c378(_0x4a272b([0x56,0x61,0x6c,0x69,0x64]));_0x16ca3f(),_0x5b44ef[_0x4a272b([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x4a272b([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x5bf328=!0x1;const _0x2cdd78=_0x4ff600();function _0xc3105(_0x1f3af4){return!!_0x1f3af4&&(typeof _0x1f3af4===_0x4a272b([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x1f3af4===_0x4a272b([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x1f3af4[_0x4a272b([0x74,0x68,0x65,0x6e])]===_0x4a272b([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x1f3af4[_0x4a272b([0x63,0x61,0x74,0x63,0x68])]===_0x4a272b([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x1fdae2(_0x3697a5){_0x5b7c0d(_0x3697a5)[_0x4a272b([0x74,0x68,0x65,0x6e])](_0x344643=>{if(!_0x344643||_0x344643[_0x4a272b([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x4a272b([0x6f,0x6b]))return _0x4a272b([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x116a23(_0x23a88f(_0x2cdd78+_0x51613b))!=_0x344643[_0x4a272b([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x4a272b([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x4a272b([0x56,0x61,0x6c,0x69,0x64]);})[_0x4a272b([0x74,0x68,0x65,0x6e])](_0x128c1b=>(_0x787193(),_0x128c1b),()=>{const _0x51497e=_0xa39961();return null==_0x51497e?(_0x787193(),_0x4a272b([0x56,0x61,0x6c,0x69,0x64])):_0x4a272b(_0x4b2f41-_0x51497e>(0x57b07748^_0x5bc1a9)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x4a272b([0x74,0x68,0x65,0x6e])](_0x16c378)[_0x4a272b([0x63,0x61,0x74,0x63,0x68])](()=>{_0x16c378(_0x4a272b([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x5b7bdb=0x738a1dc8^_0x5bc1a9;function _0x787193(){const _0x1c1c1c=_0x4a272b([0x6c,0x6c,0x63,0x74,0x2d])+_0x116a23(_0x23a88f(_0xad2191)),_0x1b55bb=_0x18508a(_0x116a23(window[_0x4a272b([0x4d,0x61,0x74,0x68])][_0x4a272b([0x63,0x65,0x69,0x6c])](_0x4b2f41/_0x5b7bdb)));window[_0x4a272b([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x4a272b([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x1c1c1c,_0x1b55bb);}function _0xa39961(){const _0x525667=_0x4a272b([0x6c,0x6c,0x63,0x74,0x2d])+_0x116a23(_0x23a88f(_0xad2191)),_0x3d62cc=window[_0x4a272b([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x4a272b([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x525667);return _0x3d62cc?window[_0x4a272b([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x18508a(_0x3d62cc),0x10)*_0x5b7bdb:null;}function _0x5b7c0d(_0x2093b7){return new window[(_0x4a272b([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x10edfd,_0x3a804d)=>{_0x2093b7[_0x4a272b([0x74,0x68,0x65,0x6e])](_0x10edfd,_0x3a804d),window[_0x4a272b([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x3a804d,0x73bd2788^_0x5bc1a9);});}}_0x5b44ef[_0x4a272b([0x6f,0x6e])](_0x4a272b([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x2dd34b,_0x5eafc8)=>{if(_0x5eafc8[0x0]!=_0xad2191)return _0x16c378(_0x4a272b([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x5eafc8[0x1]={..._0x5eafc8[0x1],[_0x4a272b([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x2cdd78};},{[_0x4a272b([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x4a272b([0x68,0x69,0x67,0x68])}),_0x5b44ef[_0x4a272b([0x6f,0x6e])](_0x4a272b([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x2304c5=>{_0xc3105(_0x2304c5[_0x4a272b([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x5bf328=!0x0,_0x1fdae2(_0x2304c5[_0x4a272b([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x4a272b([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x4a272b([0x6c,0x6f,0x77])}),_0xccd8a9[_0x4a272b([0x74,0x68,0x65,0x6e])](()=>{_0x5bf328||_0x16c378(_0x4a272b([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x516333(){return _0x5b44ef[_0x4a272b([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x4a272b([0x76,0x69,0x65,0x77])][_0x4a272b([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x4a272b([0x61,0x75,0x74,0x6f]);}function _0x16ca3f(){_0x5b44ef[_0x4a272b([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x4a272b([0x76,0x69,0x65,0x77])][_0x4a272b([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x4a272b([0x61,0x75,0x74,0x6f]);}}function _0x19e910(_0x3e2ac9){const _0x45b4a9=[new window[(_0x4a272b([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x35443f=>setTimeout(_0x35443f,0x73b5cd84^_0x5bc1a9)),_0xccd8a9[_0x4a272b([0x74,0x68,0x65,0x6e])](()=>new window[(_0x4a272b([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x22121b=>{const _0x4f2b3f=0x73bcf34f^_0x5bc1a9,_0x532a57=_0x3d0bf7[_0x4a272b([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x3722ca(){_0x532a57[_0x4a272b([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x4f2b3f&&_0x22121b();}_0x3722ca(),_0x532a57[_0x4a272b([0x6f,0x6e])](_0x4a272b([0x61,0x64,0x64]),_0x3722ca);})),new window[(_0x4a272b([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x12c829=>{function _0x25f56d(){for(const _0x217c4d in window)if(window[_0x4a272b([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x4a272b([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x217c4d))&&window[_0x217c4d]==_0xbeaa66)return _0x12c829();_0x5b44ef[_0x4a272b([0x73,0x74,0x61,0x74,0x65])]!=_0x4a272b([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x4a272b([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x25f56d,0x73bce0c0^_0x5bc1a9);}_0x42e621(_0x4a272b([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x25f56d();})];return window[_0x4a272b([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x4a272b([0x72,0x61,0x63,0x65])](_0x45b4a9)[_0x4a272b([0x74,0x68,0x65,0x6e])](()=>_0x3e2ac9);}async function _0x146a20(){if(await _0xccd8a9,_0x42e621(_0x4a272b([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x223459=_0x3d0bf7[_0x4a272b([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x16edfa=_0x3d0bf7[_0x4a272b([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])](_0x223459[_0x4a272b([0x69,0x64])]),_0x57deb2=_0x37fc0a(_0x4a272b([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x57deb2[_0x4a272b([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x223459['id'],_0x16edfa?_0x16edfa['id']:null,!0x0),_0x57deb2[_0x4a272b([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x4a272b([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x57deb2[_0x4a272b([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x57deb2[_0x4a272b([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x25af9e,void(_0x57deb2[_0x4a272b([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x25af9e);}if(_0x42e621(_0x4a272b([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x36f512=_0x37fc0a(_0x4a272b([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x36f512[_0x4a272b([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x4a272b([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x36f512[_0x4a272b([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x36f512[_0x4a272b([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x25af9e,_0x36f512[_0x4a272b([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x25af9e;}_0x5b44ef[_0x4a272b([0x6d,0x6f,0x64,0x65,0x6c])][_0x4a272b([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x25af9e,_0x5b44ef[_0x4a272b([0x6d,0x6f,0x64,0x65,0x6c])][_0x4a272b([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x25af9e,_0x5b44ef[_0x4a272b([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x4a272b([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x2f93e2(){return _0x42e621(_0x4a272b([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x37fc0a(_0x4a272b([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x4a272b([0x73,0x74,0x61,0x74,0x65])]==_0x4a272b([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x5908c1(){return _0x42e621(_0x4a272b([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 _0x4610af(){return _0x42e621(_0x4a272b([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x132bba(_0x4b466b){const _0x3f5ace=_0x3b72a9();_0x5b44ef[_0x3f5ace]=_0x4a272b([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])+_0x4b466b,_0x4b466b[_0x4a272b([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x4a272b([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x3b72a9()]=_0xbeaa66),_0x4b466b!=_0x4a272b([0x56,0x61,0x6c,0x69,0x64])&&_0x146a20();}function _0x3b72a9(){const _0x90672e=window[_0x4a272b([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x4a272b([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x4a272b([0x6e,0x6f,0x77])]())[_0x4a272b([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x4a272b([0x2e]),'');let _0x46454b=_0x4a272b([0x55]);for(let _0xd7d5ba=0x0;_0xd7d5ba<_0x90672e[_0x4a272b([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0xd7d5ba+=0x2){let _0x11460e=window[_0x4a272b([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x90672e[_0x4a272b([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0xd7d5ba,_0xd7d5ba+0x2));_0x11460e>=_0x1bce40[_0x4a272b([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x11460e-=_0x1bce40[_0x4a272b([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x46454b+=_0x1bce40[_0x11460e];}return _0x46454b;}function _0x56db62(){const _0x256f40=_0x32c074[_0x4a272b([0x73,0x70,0x6c,0x69,0x74])](_0x4a272b([0x2e]));if(0x3!=_0x256f40[_0x4a272b([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x206ff3(_0x256f40[0x1]);function _0x206ff3(_0x45b825){const _0x3899ee=_0x28c197(_0x45b825);return _0x3899ee&&_0x31da0d()?_0x3899ee:null;function _0x31da0d(){const _0x11c218=_0x3899ee[_0x4a272b([0x6a,0x74,0x69])],_0x401056=window[_0x4a272b([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x11c218[_0x4a272b([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x11c218[_0x4a272b([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x38eca7={..._0x3899ee,[_0x4a272b([0x6a,0x74,0x69])]:_0x11c218[_0x4a272b([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x11c218[_0x4a272b([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x38eca7[_0x4a272b([0x76,0x63])],_0x23a88f(_0x38eca7)==_0x401056;}}}async function _0x54ea17(){let _0x2d55d5=!0x0;try{const _0x380115=_0x32c074[_0x4a272b([0x73,0x70,0x6c,0x69,0x74])](_0x4a272b([0x2e])),[_0x3dc1e2,_0x2cd772,_0x3e8668]=_0x380115;return _0x663552(_0x3dc1e2),await _0x8b4826(_0x3dc1e2,_0x2cd772,_0x3e8668),_0x2d55d5;}catch(_0x2e593a){return!0x1;}function _0x663552(_0x1f6135){const _0x17a026=_0x28c197(_0x1f6135);_0x17a026&&_0x17a026[_0x4a272b([0x61,0x6c,0x67])]==_0x4a272b([0x45,0x53,0x32,0x35,0x36])||(_0x2d55d5=!0x1);}async function _0x8b4826(_0x125f82,_0x512655,_0x3c8fdf){const _0x5b425e=window[_0x4a272b([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x4a272b([0x66,0x72,0x6f,0x6d])](_0x10c772(_0x3c8fdf),_0x2b6e47=>_0x2b6e47[_0x4a272b([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x3f01dd=new window[(_0x4a272b([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x4a272b([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x125f82+_0x4a272b([0x2e])+_0x512655),_0x49fbc6=window[_0x4a272b([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x4a272b([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x49fbc6)return;const _0x4641a6=await _0x49fbc6[_0x4a272b([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x4a272b([0x6a,0x77,0x6b]),_0x2ad806,{[_0x4a272b([0x6e,0x61,0x6d,0x65])]:_0x4a272b([0x45,0x43,0x44,0x53,0x41]),[_0x4a272b([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x4a272b([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x4a272b([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x49fbc6[_0x4a272b([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x4a272b([0x6e,0x61,0x6d,0x65])]:_0x4a272b([0x45,0x43,0x44,0x53,0x41]),[_0x4a272b([0x68,0x61,0x73,0x68])]:{[_0x4a272b([0x6e,0x61,0x6d,0x65])]:_0x4a272b([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x4641a6,_0x5b425e,_0x3f01dd)||(_0x2d55d5=!0x1);}}function _0x28c197(_0x3999ab){return _0x3999ab[_0x4a272b([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x4a272b([0x65,0x79]))?JSON[_0x4a272b([0x70,0x61,0x72,0x73,0x65])](_0x10c772(_0x3999ab)):null;}function _0x10c772(_0xeaaad5){return window[_0x4a272b([0x61,0x74,0x6f,0x62])](_0xeaaad5[_0x4a272b([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x4a272b([0x2b]))[_0x4a272b([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x4a272b([0x2f])));}function _0x23a88f(_0x438332){let _0x3da3e4=0x1505;function _0x363ff2(_0x1e73ee){for(let _0x4eb61a=0x0;_0x4eb61a<_0x1e73ee[_0x4a272b([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x4eb61a++){const _0x4ae669=_0x1e73ee[_0x4a272b([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x4eb61a);_0x3da3e4=(_0x3da3e4<<0x5)+_0x3da3e4+_0x4ae669,_0x3da3e4&=_0x3da3e4;}}function _0x30e51f(_0x41d921){Array[_0x4a272b([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x41d921)?_0x41d921[_0x4a272b([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x30e51f):_0x41d921&&typeof _0x41d921==_0x4a272b([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x4a272b([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x41d921)[_0x4a272b([0x73,0x6f,0x72,0x74])]()[_0x4a272b([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x2edeff,_0x1c3530])=>{_0x363ff2(_0x2edeff),_0x30e51f(_0x1c3530);}):_0x363ff2(window[_0x4a272b([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x41d921));}return _0x30e51f(_0x438332),_0x3da3e4>>>0x0;}function _0x116a23(_0x59b7c9){return _0x59b7c9[_0x4a272b([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x4a272b([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x4a272b([0x30]));}function _0x18508a(_0x3d670d){return _0x3d670d[_0x4a272b([0x73,0x70,0x6c,0x69,0x74])]('')[_0x4a272b([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x4a272b([0x6a,0x6f,0x69,0x6e])]('');}function _0x42e621(_0x1098f8){return _0x5b44ef[_0x4a272b([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x4a272b([0x68,0x61,0x73])](_0x1098f8);}function _0x37fc0a(_0x327662){return _0x5b44ef[_0x4a272b([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x4a272b([0x67,0x65,0x74])](_0x327662);}function _0x25af9e(){}function _0x4a272b(_0xb763e3){return _0xb763e3['map'](_0x45c354=>String['fromCharCode'](_0x45c354))['join']('');}_0x132bba(await _0x43782e());}(this);}['createRevision'](_0x925905){const _0x22fa31=this['editor']['plugins']['get']('Users');return new a({'id':_0x925905['id'],'name':_0x925905['name'],'creator':_0x925905['creatorId']?_0x22fa31['getUser'](_0x925905['creatorId']):null,'diffData':_0x925905['diffData']||_0x925905['data'],'authors':_0x925905['authorsIds']['map'](_0x466b55=>_0x22fa31['getUser'](_0x466b55)),'createdAt':new Date(_0x925905['createdAt']),'attributes':_0x925905['attributes'],'fromVersion':_0x925905['fromVersion'],'toVersion':_0x925905['toVersion']});}['addRevision'](_0x4dc6c7,_0x424640=0x0){this['_revisions']['add'](_0x4dc6c7,_0x424640);}['getRevision'](_0xfef1f7){return this['_revisions']['get'](_0xfef1f7);}['getRevisions'](_0x3b3352={'toJSON':!0x1}){const _0x51f7b0=Array['from'](this['_revisions']);return _0x51f7b0['reverse'](),_0x3b3352['toJSON']?_0x51f7b0['map'](_0x3231cc=>_0x3231cc['toJSON']()):_0x51f7b0;}['getIndex'](_0xb0e1b8){return this['_revisions']['getIndex'](_0xb0e1b8);}['getEarlierVisibleRevision'](_0x3c8e02){const [,_0x5e72e4]=this['getRevisionsIterator'](_0x3c8e02,{'direction':'earlier'});return _0x5e72e4;}['getLaterVisibleRevision'](_0x36e6bd){const [,_0x40c6ee]=this['getRevisionsIterator'](_0x36e6bd,{'direction':'later'});return _0x40c6ee;}['getRevisionsInDiff'](_0x449859){const _0x2012fc=[];for(const _0x2d8d7e of this['getRevisionsIterator'](_0x449859['newRevisionId']))if(_0x2012fc['push'](_0x2d8d7e),_0x2d8d7e['id']===_0x449859['oldRevisionId'])break;return _0x2012fc;}*['getRevisionsIterator'](_0x393de2,{direction:_0x4d6878='earlier',filter:_0x440353=()=>!0x0}={}){const _0x5f265e='earlier'===_0x4d6878?0x1:-0x1;let _0x358a02=this['_revisions']['get'](_0x393de2),_0x2c8f81=this['getIndex'](_0x358a02);for(yield _0x358a02;_0x358a02;){if(_0x2c8f81+=_0x5f265e,_0x358a02=this['getRevision'](_0x2c8f81),!_0x358a02)return;_0x440353(_0x358a02)&&(yield _0x358a02);}}}function m(_0x14f3e4,_0x4f6643,_0xe45054){const t=_0x14f3e4['t'];switch(_0x4f6643){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'},_0xe45054);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0xe45054);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 P={'c':_0x741c8a,'a':_0x5b9586,'e':_0x23f14e,'r':_0x496ec4,'u':_0x429f21};class l extends _0x32454b{['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[_0xa55a60,j,_0x4bc6b8];}constructor(_0x46b08a){super(_0x46b08a),this['adapter']=null,this['currentRevision']=null,this['_revisionDataBuilder']=new V(this['editor']),this['_initialRevisionId']=this['editor']['config']['get']('collaboration.channelId')||'initial',this['_bufferedUpdates']=new Map(),this['_loadedStateData']=null;const _0x16d1cc=_0x4ff600();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x16d1cc},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 _0x9ed889=this['repository']['getRevision'](0x0),_0x3b914c=_0x9ed889&&null===_0x9ed889['creator']?_0x9ed889:null;if(this['_continueCurrentRevision']=!!_0x3b914c&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x254ff6=this['_source']['getCurrentRevisionId'](),_0x42af3c=this['repository']['getRevision'](_0x254ff6);if(_0x42af3c)this['_startingVersion']=_0x42af3c['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x2c8590=this['_source']['history']['_operations']['find'](_0x42222b=>!_0x42222b['_isInit']),_0x571864=_0x2c8590?_0x2c8590['baseVersion']:this['_source']['history']['version'];_0x9ed889?(_0x9ed889['toVersion']<_0x571864&&_0x9ed889['_update']({'toVersion':_0x571864}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x3b914c['id'],this['_startingVersion']=_0x3b914c['fromVersion']):(this['_startingVersion']=_0x9ed889['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x571864,this['_continueCurrentRevision']=!0x1);}}else _0x3b914c&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x3b914c['toVersion'],this['editor']['model']['document']['history']['version']),_0x3b914c['fromVersion']===_0x3b914c['toVersion']?(0x0!==_0x3b914c['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x3b914c['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x3b914c['id'],this['_startingVersion']=_0x3b914c['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',_0x4b7d9e=>!_0x4b7d9e),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x893d9a=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x1edd47;for(const _0x3c0686 in _0x893d9a){const _0x4a3b86=_0x3c0686,_0x555149=_0x893d9a[_0x4a3b86];if('revisionHistoryLicenseKeyValid'==_0x555149||'revisionHistoryLicenseKeyInvalid'==_0x555149||'revisionHistoryLicenseKeyExpired'==_0x555149||'revisionHistoryLicenseKeyDomainLimit'==_0x555149||'revisionHistoryLicenseKeyNotAllowed'==_0x555149||'revisionHistoryLicenseKeyEvaluationLimit'==_0x555149||'revisionHistoryLicenseKeyTrialLimit'==_0x555149||'revisionHistoryLicenseKeyUsageLimit'==_0x555149){delete _0x893d9a[_0x4a3b86],_0x1edd47=_0x555149,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x1edd47&&_0x893d9a['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x1edd47&&_0x893d9a['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x1edd47&&_0x893d9a['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x1edd47&&_0x893d9a['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x1edd47&&_0x893d9a['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x1edd47&&_0x893d9a['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x1edd47&&_0x893d9a['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x1141e3=this['repository']['getRevision'](0x0),_0x2740e5=await this['getRevisionDocumentData'](_0x1141e3),_0x852a4d=await this['getRevisionRootsAttributes'](_0x1141e3);this['_replaceEditorDataWithRevisionData'](_0x2740e5,_0x852a4d);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x3ff3e8){this['_source']=_0x3ff3e8;}async['update'](){const _0x407de6=await this['_source']['getLatestVersion']();if(_0x407de6>this['currentRevision']['toVersion']){await this['_loadState']();const _0x4505a9=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x407de6});_0x4505a9['authors']=_0x4505a9['authorsIds']['map'](_0x5be829=>this['editor']['plugins']['get']('Users')['getUser'](_0x5be829)),this['currentRevision']['_update'](_0x4505a9);}}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'](_0x599cbd={},_0x2e9cfb=null){const _0x196868=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x2e9cfb>this['currentRevision']['toVersion']&&(_0x2e9cfb=null),null===_0x2e9cfb&&(_0x2e9cfb=await this['_source']['getLatestVersion']());const _0x4f2985=this['_getFromVersion'](_0x2e9cfb),_0x38b137=this['buildRevisionData']({'from':_0x4f2985,'to':_0x2e9cfb});if(this['currentRevision']['toVersion']<_0x2e9cfb){const _0x590d11=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x2e9cfb,'to':_0x2e9cfb});_0x590d11['authors']=[],_0x590d11['authorsIds']=[],_0x590d11['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x590d11,!0x0),delete _0x590d11['authors'],_0x196868['push'](_0x590d11);}_0x599cbd['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x599cbd['name']=_0x599cbd['name']||null,_0x599cbd['id']=_0x599cbd['id']||_0x4ff600(),_0x599cbd={..._0x599cbd,..._0x38b137};const _0x47e4e4=this['addRevisionData'](_0x599cbd);_0x196868['push'](_0x599cbd);const _0x4c1b28=this['repository']['getIndex'](_0x47e4e4);if(0x0!==_0x4c1b28){const _0x419c92=this['repository']['getRevision'](_0x4c1b28-0x1);if(_0x419c92['fromVersion']!==_0x2e9cfb){const _0xfeef4e=this['_revisionDataBuilder']['getData'](_0x2e9cfb,_0x419c92['toVersion']),_0x314fa9={'id':_0x419c92['id'],'diffData':_0xfeef4e['diffData'],'authorsIds':_0xfeef4e['authorsIds'],'authors':_0xfeef4e['authorsIds']['map'](_0x2887ab=>this['editor']['plugins']['get']('Users')['getUser'](_0x2887ab)),'fromVersion':_0x2e9cfb};_0x419c92===this['currentRevision']&&(_0x314fa9['createdAt']=new Date(_0x599cbd['createdAt']['getTime']()+0xa)),_0x419c92['_update'](_0x314fa9,!0x0),delete _0x314fa9['authors'],_0x196868['push'](_0x314fa9);}}if(this['adapter']){for(const _0x25c01d of _0x196868)this['_bufferUpdate'](_0x25c01d['id'],_0x25c01d,!0x0);this['sendBufferedUpdates']();}return _0x47e4e4;}['addRevisionData'](_0x15b42e){const _0x2f37a1=this['repository']['createRevision'](_0x15b42e);return this['adapter']&&_0x2f37a1['on']('_update',(_0x342eb0,_0x3d01ec,_0x287bde)=>{_0x287bde||(this['_bufferUpdate'](_0x3d01ec['id'],_0x3d01ec,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x2f37a1,this['_findInsertionIndex'](_0x2f37a1)),_0x2f37a1;}async['getRevisionDocumentData'](_0xe927ec){await this['_loadRevisionData'](_0xe927ec);const _0x59206e={};for(const _0x203ce3 in _0xe927ec['diffData']){if(_0xe927ec['diffData'][_0x203ce3]['attachChange']&&!_0xe927ec['diffData'][_0x203ce3]['attachChange']['isAttached'])continue;const _0x3ee229=this['_removeRevisionMarkers'](JSON['parse'](_0xe927ec['diffData'][_0x203ce3]['insertions'])),_0x4117d8=this['editor']['editing']['view']['document'],_0x5001c2=new _0x363fce(_0x4117d8,_0x3ee229['map'](_0x2a8c4=>C(_0x2a8c4,this['editor'])));this['editor']['data']['processor']['useFillerType']('marked'),_0x59206e[_0x203ce3]=this['editor']['data']['processor']['toData'](_0x5001c2),this['editor']['data']['processor']['useFillerType']('default');}return _0x59206e;}async['getRevisionRootsAttributes'](_0x22ba12){await this['_loadRevisionData'](_0x22ba12);const _0x4e45e0={};for(const _0x29970d in _0x22ba12['diffData'])_0x22ba12['diffData'][_0x29970d]['attachChange']&&!_0x22ba12['diffData'][_0x29970d]['attachChange']['isAttached']||(_0x4e45e0[_0x29970d]=_0x22ba12['diffData'][_0x29970d]['attributesAfter']||{});return _0x4e45e0;}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x3c1f90=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x1a95da=0x0;_0x1a95da<_0x3c1f90['length'];_0x1a95da++){const _0x4493ed=_0x3c1f90[_0x1a95da];let _0x40e791=!0x1;for(const _0x5141bc of Object['keys'](_0x4493ed))void 0x0===_0x4493ed[_0x5141bc]?delete _0x4493ed[_0x5141bc]:'id'!==_0x5141bc&&(_0x40e791=!0x0);_0x40e791||(_0x3c1f90[_0x1a95da]=null);}if(_0x3c1f90=_0x3c1f90['filter'](_0x57c3b7=>null!==_0x57c3b7),!_0x3c1f90['length'])return;for(let _0x262eeb=0x0;_0x262eeb<_0x3c1f90['length'];_0x262eeb++){const _0x55e4d9=_0x3c1f90[_0x262eeb];void 0x0!==_0x55e4d9['fromVersion']&&void 0x0===_0x55e4d9['toVersion']&&(_0x55e4d9['toVersion']=this['repository']['getRevision'](_0x55e4d9['id'])['toVersion']),void 0x0!==_0x55e4d9['toVersion']&&void 0x0===_0x55e4d9['fromVersion']&&(_0x55e4d9['fromVersion']=this['repository']['getRevision'](_0x55e4d9['id'])['fromVersion']);}const _0x1f8843=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x3c1f90,_0x1f8843)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x224b70=>{if(_0x224b70){for(const _0x3d7f13 of _0x224b70)this['setRevisionData']({'id':_0x3d7f13['id'],'createdAt':_0x3d7f13['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['_replaceEditorDataWithRevisionData'](_0x3ffbfa,_0x4a59f6){let _0x46386c=this['editor']['config']['get']('initialData'),_0x5df353=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x46386c){_0x46386c={};for(const _0x3f7e9d of this['editor']['model']['document']['getRootNames']())_0x46386c[_0x3f7e9d]='';}if('string'==typeof _0x46386c&&(_0x46386c={'main':_0x46386c}),void 0x0===_0x5df353){_0x5df353={};for(const _0x1134ce of this['editor']['model']['document']['getRootNames']())_0x5df353[_0x1134ce]={};}let _0x416fe8=!0x1;const _0x33b4d1=Object['keys'](_0x46386c),_0x38d11e=Object['keys'](_0x3ffbfa);for(const _0xc044e1 of _0x33b4d1){if(_0x46386c[_0xc044e1]!==_0x3ffbfa[_0xc044e1]&&''!==_0x46386c[_0xc044e1]['trim']()){_0x416fe8=!0x0;break;}if(!_0x3ee13a(_0x5df353[_0xc044e1],_0x4a59f6[_0xc044e1])&&Object['keys'](_0x5df353[_0xc044e1])['length']>0x0){_0x416fe8=!0x0;break;}}_0x416fe8||(_0x416fe8=_0x38d11e['some'](_0x15e7ed=>!this['editor']['model']['document']['getRoot'](_0x15e7ed))),_0x416fe8&&_0x19ff0e('editor-initial-data-replaced-with-revision-data',{'editorData':_0x46386c,'editorRootsAttributes':_0x5df353,'revisionData':_0x3ffbfa,'revisionRootsAttributes':_0x4a59f6}),this['editor']['config']['set']('initialData',_0x3ffbfa),this['editor']['config']['set']('rootsAttributes',_0x4a59f6);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x47f58e=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x47f58e['add'](m(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x15a4d7){const _0x239fc8=this['repository']['getRevisions']();_0x239fc8['reverse']();let _0x331e27=0x0;for(;_0x331e27<_0x239fc8['length'];){const _0x1d5971=_0x239fc8[_0x331e27];if(_0x1d5971===this['currentRevision']){_0x331e27++;continue;}if(_0x1d5971['id']===this['_initialRevisionId'])break;const _0x506d52=_0x15a4d7['toVersion']-_0x1d5971['toVersion']||_0x15a4d7['fromVersion']-_0x1d5971['fromVersion'];if(_0x506d52>0x0)break;if(_0x506d52<0x0)_0x331e27++;else{if(!_0x15a4d7['creator']&&_0x1d5971['creator'])break;if(_0x1d5971['creator']||!_0x15a4d7['creator']){if(_0x15a4d7['createdAt']>_0x1d5971['createdAt'])break;_0x331e27++;}else _0x331e27++;}}return _0x331e27;}['setRevisionData'](_0x2bce2c){const _0x87bb8c=this['repository']['getRevision'](_0x2bce2c['id']);if(_0x2bce2c['createdAt']&&(_0x2bce2c['createdAt']=new Date(_0x2bce2c['createdAt'])),_0x2bce2c['authorsIds']){const _0x100781=this['editor']['plugins']['get']('Users');_0x2bce2c['authors']=_0x2bce2c['authorsIds']['map'](_0x39e831=>_0x100781['getUser'](_0x39e831));}_0x87bb8c['_update'](_0x2bce2c,!0x0);}['buildRevisionData']({revision:_0x2f514d=null,from:_0x2cd414=null,to:_0x3c6719=null}){_0x2cd414=null!==_0x2cd414?_0x2cd414:_0x2f514d['fromVersion'],_0x3c6719=null!==_0x3c6719?_0x3c6719:_0x2f514d['toVersion'];const _0x35351e=this['_revisionDataBuilder']['getData'](_0x2cd414,_0x3c6719),_0x4c4f5e={'diffData':_0x35351e['diffData'],'authorsIds':_0x35351e['authorsIds'],'fromVersion':_0x2cd414,'toVersion':_0x3c6719};if(!_0x2f514d||_0x3c6719!==_0x2f514d['toVersion']){const _0x42164d=_0x3c6719-0x1,_0x15e02e=this['_source']['history']['getOperation'](_0x42164d);_0x4c4f5e['createdAt']=_0x15e02e&&_0x15e02e['createdAt']||new Date();}if(this['_loadedStateData']&&_0x2cd414===this['_loadedStateData']['fromVersion']){for(const _0x42fbd5 of this['_loadedStateData']['authors'])_0x4c4f5e['authorsIds']['includes'](_0x42fbd5['id'])||_0x4c4f5e['authorsIds']['push'](_0x42fbd5['id']);}return _0x4c4f5e;}['_loadRevisionData'](_0x1cbd3e){if(!_0x1cbd3e||_0x1cbd3e['diffData'])return Promise['resolve']();{const _0x538819=this['editor']['config']['get']('collaboration.channelId');return this['adapter']['getRevision']({'channelId':_0x538819,'revisionId':_0x1cbd3e['id']})['then'](_0x5f29d5=>{_0x1cbd3e['diffData']=_0x5f29d5['diffData'];});}}['_bufferUpdate'](_0x378e3f,_0x502642,_0x475ab3){if(this['_bufferedUpdates']['has'](_0x378e3f)){const _0x1c30f6=this['_bufferedUpdates']['get'](_0x378e3f);_0x502642=_0x475ab3?{..._0x1c30f6,..._0x502642}:{..._0x502642,..._0x1c30f6};}this['_bufferedUpdates']['set'](_0x378e3f,_0x502642);}['_getFromVersion'](_0x2c15b7){const _0x37652a=this['repository']['getRevisions']();_0x37652a['reverse'](),_0x37652a['shift']();const _0x2f2edc=_0x37652a['find'](_0x2aa3bf=>_0x2aa3bf['toVersion']<=_0x2c15b7)['toVersion'];return _0x2f2edc<this['_startingVersion']?this['_startingVersion']:_0x2f2edc;}['_createInitialRevision'](_0x5dc162){const _0x23884e=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x23884e)this['_initialRevisionId']=_0x23884e['id'];else{const _0x2d346f=!this['editor']['model']['document']['roots']['find'](_0x12eb2d=>this['editor']['model']['hasContent'](_0x12eb2d)),_0x4b32c5=this['editor']['plugins']['get']('Users')['me']['id'],_0x81014=m(this['editor']['locale'],_0x2d346f?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x5dc162,'to':_0x5dc162,'id':this['_initialRevisionId'],'name':_0x81014,'creatorId':_0x4b32c5});}}['_createCurrentRevision'](_0x526fc0){const _0x5a0430=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x5a0430),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x526fc0,'to':_0x526fc0,'id':_0x5a0430,'name':'','creatorId':null}));}['_makeRevision']({name:_0x52e5be,from:_0x461eb6,to:_0x5a7362,creatorId:_0x518dd2,id:_0x2d0ecd}){const _0xb2ea3d=this['buildRevisionData']({'from':_0x461eb6,'to':_0x5a7362});_0xb2ea3d['name']=_0x52e5be,_0xb2ea3d['creatorId']=_0x518dd2,_0xb2ea3d['id']=_0x2d0ecd;const _0x226b43=this['addRevisionData'](_0xb2ea3d);return this['adapter']&&this['_bufferUpdate'](_0xb2ea3d['id'],_0xb2ea3d,!0x0),_0x226b43;}['_setConversion'](){this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'});}['_removeRevisionMarkers'](_0x22a8a3){return(_0x22a8a3=_0x22a8a3['filter'](_0x26191d=>!_0x26191d['name']||'revision-start'!==_0x26191d['name']&&'revision-end'!==_0x26191d['name']))['forEach'](_0x29d843=>{'string'!=typeof _0x29d843&&(_0x29d843['children']=this['_removeRevisionMarkers'](_0x29d843['children']),_0x29d843['attributes']=_0x29d843['attributes']['filter'](_0x4ecc63=>!_0x4ecc63[0x0]['startsWith']('data-revision-')));}),_0x22a8a3;}}function C(_0x50febf,_0x4432f6){const _0x6dbd81=_0x4432f6['editing']['view']['document'];if('string'==typeof _0x50febf)return new _0x363037(_0x6dbd81,_0x50febf);{const _0x5e5b23=_0x50febf['children']['map'](_0x360333=>C(_0x360333,_0x4432f6));return new(P[_0x50febf['type']]||_0x50af6c)(_0x6dbd81,_0x50febf['name'],_0x50febf['attributes'],_0x5e5b23);}}class V{['editor'];['source'];['_savedMetaData'];['_lastFrom'];['_lastTo'];['_markers'];['_diffRoots'];['_diffRootsAttributes'];['_baseRoots'];['_baseRootsAttributes'];['_idsRoots'];['_baseIdsRoots'];['_touched'];['_touchedMarkers'];['_touchedRoots'];['_revisionId'];['_startingRevisionId'];constructor(_0x4b0842){this['editor']=_0x4b0842,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'](_0x162290){this['source']=_0x162290;const _0x374951=new Map(),_0x3e0a8f=new Map(),_0x258608=this['editor']['model']['document']['roots']['map'](_0x6fef03=>_0x6fef03['rootName']);for(const _0x101827 of _0x258608){const _0x1f2430=this['editor']['model']['document']['getRoot'](_0x101827),_0x2ed96c=T(_0x1f2430);_0x374951['set'](_0x101827,_0x2ed96c),_0x3e0a8f['set'](_0x101827,Object['fromEntries'](_0x1f2430['getAttributes']()));}const _0x2d0dc6=Array['from'](this['editor']['model']['markers'])['map'](_0x23f112=>[_0x23f112['name'],_0x23f112['getRange']()]),_0xebd4f3=this['source']['version'];this['_saveMetaData'](_0xebd4f3,_0x374951,_0x2d0dc6,_0x3e0a8f),this['_startingRevisionId']=this['_revisionId'];const _0x3e14ed=new Map(),_0x64d790=new Map();for(const _0x7ff99a of _0x258608){const _0x5935a5=F(_0x7ff99a);_0x3e14ed['set'](_0x7ff99a,_0x5935a5),_0x64d790['set'](_0x7ff99a,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x3e14ed,[],_0x64d790);}['getData'](_0x5a28cb,_0x13da80){if(this['_lastFrom']===_0x5a28cb&&this['_lastTo']<=_0x13da80)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x13da80,!0x0);else{if(!this['_savedMetaData']['has'](_0x5a28cb)){const _0x1de251=this['_getPreviousFrom'](_0x5a28cb);this['_calculateMetaData'](_0x1de251,_0x5a28cb,!0x1);}this['_calculateMetaData'](_0x5a28cb,_0x13da80,!0x0);}return this['_lastFrom']=_0x5a28cb,this['_lastTo']=_0x13da80,this['_getState']();}['loadState'](_0xf2098c){this['_reset'](),this['_lastFrom']=_0xf2098c['fromVersion'],this['_lastTo']=_0xf2098c['toVersion'];for(const _0x4dd516 in _0xf2098c['diffData']){const _0x4b2a6d=_0xf2098c['diffData'][_0x4dd516]['attachChange'],_0x515a86=_0x2b10be(_0xf2098c['diffData'][_0x4dd516]['attributesBefore'])||{},_0x3c42a6=this['_makeModelFromViewString'](_0xf2098c['diffData'][_0x4dd516]['deletions']);_0x3c42a6['rootName']=_0x4dd516,_0x3c42a6['_isAttached']=!_0x4b2a6d||!_0x4b2a6d['isAttached'],_0x3c42a6['isAttached']=()=>_0x3c42a6['_isAttached'],this['_baseRoots']['set'](_0x4dd516,_0x3c42a6),this['_baseRootsAttributes']['set'](_0x4dd516,_0x515a86),_0x4b2a6d&&this['_touchedRoots']['set'](_0x4dd516,_0x4b2a6d);const _0x410acb=this['_makeIdsRoot'](_0x3c42a6);this['_baseIdsRoots']['set'](_0x4dd516,_0x410acb);for(const [_0x27f56a,_0x193e48]of _0x3c42a6['markers']){if(!_0x27f56a['startsWith']('revision:'))continue;const _0x4e8813=_0x27f56a['split'](':')[0x2];for(const _0x26875c of _0x193e48['getWalker']({'singleCharacters':!0x0})){const _0x2d8f2c=this['_getVidAttributeName'](_0x26875c),_0x41edec='elementEnd'==_0x26875c['type']?_0x26875c['previousPosition']['path']['slice'](0x0,-0x1):_0x26875c['previousPosition']['path'],_0x28c289=_0x410acb['getNodeByPath'](_0x41edec)['getAttribute'](_0x2d8f2c);this['_touched']['set'](_0x28c289,{'userId':_0x4e8813});}}}this['_startingRevisionId']=this['_revisionId'];const _0x42b105=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x2037f9=>!this['_touched']['has'](_0x2037f9));let _0xeb014f=0x0;const _0x580c7a=new Map();for(const _0x5a8407 in _0xf2098c['diffData']){const _0x1fb3ed=_0xf2098c['diffData'][_0x5a8407]['attachChange'],_0x584ab2=_0x2b10be(_0xf2098c['diffData'][_0x5a8407]['attributesAfter'])||{},_0x38ee42=this['_makeModelFromViewString'](_0xf2098c['diffData'][_0x5a8407]['insertions']);_0x38ee42['rootName']=_0x5a8407,_0x38ee42['_isAttached']=!_0x1fb3ed||_0x1fb3ed['isAttached'],_0x38ee42['isAttached']=()=>_0x38ee42['_isAttached'],this['_diffRoots']['set'](_0x5a8407,_0x38ee42),this['_diffRootsAttributes']['set'](_0x5a8407,_0x584ab2);const _0x34b6d7=this['_makeIdsRoot'](_0x38ee42,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x5a8407,_0x34b6d7),_0x580c7a['set'](_0x5a8407,_0x38ee42['isAttached']()?_0x584ab2:{});for(const [_0x2ab142,_0x4722d9]of _0x38ee42['markers']){if(!_0x2ab142['startsWith']('revision:'))continue;const _0x3e2528=_0x2ab142['split'](':')[0x2];for(const _0x18c506 of _0x4722d9['getWalker']({'singleCharacters':!0x0})){const _0x229f56=this['_getVidAttributeName'](_0x18c506),_0x5d0a6b=this['_revisionId']++,_0x1e42a7='elementEnd'==_0x18c506['type']?_0x18c506['previousPosition']['path']['slice'](0x0,-0x1):_0x18c506['previousPosition']['path'];_0x34b6d7['getNodeByPath'](_0x1e42a7)['_setAttribute'](_0x229f56,_0x5d0a6b),this['_touched']['set'](_0x5d0a6b,{'userId':_0x3e2528});}}for(const _0x7899de of this['editor']['model']['createRangeIn'](_0x38ee42)['getWalker']({'singleCharacters':!0x0})){const _0x24cc0a=this['_getVidAttributeName'](_0x7899de),_0x2f0d9c='elementEnd'==_0x7899de['type']?_0x7899de['previousPosition']['path']['slice'](0x0,-0x1):_0x7899de['previousPosition']['path'],_0x10c594=_0x34b6d7['getNodeByPath'](_0x2f0d9c);_0x10c594['getAttribute'](_0x24cc0a)>0x0||_0x10c594['_setAttribute'](_0x24cc0a,_0x42b105[_0xeb014f++]);}for(const [_0x19e4e7,_0x1c6b16]of _0x38ee42['markers'])_0x19e4e7['startsWith']('revision:')||this['_markers']['set'](_0x19e4e7,_0x1c6b16);}const _0x35f58d=F('$graveyard');this['_baseRoots']['set']('$graveyard',_0x35f58d),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x35f58d,0x1));const _0x2b5311=F('$graveyard');this['_diffRoots']['set']('$graveyard',_0x2b5311),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x2b5311,0x1));const _0x1181e9=Array['from'](this['_diffRoots'])['map'](([_0x335042,_0x5aea66])=>[_0x335042,T(_0x5aea66)]);this['_saveMetaData'](this['_lastTo'],_0x1181e9,this['_markers'],_0x580c7a);}['_makeModelFromViewString'](_0x5e34f2){const _0x23ab90=JSON['parse'](_0x5e34f2),_0x4325e9=this['editor']['editing']['view']['document'],_0x4b9072=new _0x363fce(_0x4325e9,_0x23ab90['map'](_0x2513fe=>C(_0x2513fe,this['editor'])));return this['editor']['data']['toModel'](_0x4b9072);}['_saveMetaData'](_0x2356f2,_0x5ee690,_0xe442a9,_0x118867){const _0x3dc672=new Map(_0x5ee690),_0x4f08ec=new Map(_0x2b10be(_0x118867)),_0x1a6e81=new Map();for(const [_0x2eb928,_0x5937d9]of _0xe442a9)_0x1a6e81['set'](_0x2eb928,{'start':_0x5937d9['start']['clone'](),'end':_0x5937d9['end']['clone'](),'rootName':_0x5937d9['root']['rootName']});this['_savedMetaData']['set'](_0x2356f2,{'roots':_0x3dc672,'markers':_0x1a6e81,'rootsAttributes':_0x4f08ec});}['_removeMetaData'](_0x3f01e6){this['_savedMetaData']['delete'](_0x3f01e6);}['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'](_0x13c4c3,_0x28e691=null){let _0x2f5683=null;_0x13c4c3['is']('documentFragment')||(_0x2f5683=new ft(_0x13c4c3['name'],{'vid_start':null===_0x28e691?this['_revisionId']++:_0x28e691++}));const _0x1a861f=[];for(const _0x552e98 of _0x13c4c3['getChildren']())if(_0x552e98['is']('element')){_0x1a861f['push'](this['_makeIdsRoot'](_0x552e98,_0x28e691));const _0x2f85b8=_0x1a861f[_0x1a861f['length']-0x1];null!==_0x28e691&&(_0x28e691=_0x2f85b8['is']('element','$text')?_0x2f85b8['getAttribute']('vid')+0x1:_0x2f85b8['getAttribute']('vid_end')+0x1);}else{for(let _0x26cdce=0x0;_0x26cdce<_0x552e98['offsetSize'];_0x26cdce++)_0x1a861f['push'](new ft('$text',{'vid':null===_0x28e691?this['_revisionId']++:_0x28e691++}));}if(_0x13c4c3['is']('documentFragment')){const _0x31e328=F(_0x13c4c3['rootName']);return _0x31e328['_insertChild'](0x0,_0x1a861f),_0x31e328;}return _0x2f5683['_setAttribute']('vid_end',null===_0x28e691?this['_revisionId']++:_0x28e691++),_0x2f5683['_insertChild'](0x0,_0x1a861f),_0x2f5683;}['_calculateMetaData'](_0x2d2c4c,_0x794553,_0x38a246){this['_reset']();const {roots:_0x39d327,markers:_0x58665d,rootsAttributes:_0x4d06ac}=this['_savedMetaData']['get'](_0x2d2c4c);this['_baseRoots']=new Map(_0x39d327),this['_baseRootsAttributes']=new Map(_0x2b10be(_0x4d06ac));for(const [_0x2812a0,_0x4bc5a7]of this['_baseRoots'])if('$graveyard'!==_0x2812a0&&(this['_diffRoots']['set'](_0x2812a0,T(_0x4bc5a7)),this['_diffRootsAttributes']=new Map(_0x2b10be(_0x4d06ac)),_0x38a246)){const _0x421860=this['_revisionId'];this['_idsRoots']['set'](_0x2812a0,this['_makeIdsRoot'](_0x4bc5a7)),this['_baseIdsRoots']['set'](_0x2812a0,this['_makeIdsRoot'](_0x4bc5a7,_0x421860));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',T(this['_baseRoots']['get']('$graveyard'))),_0x38a246&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x1b97a2,_0x35eee1]of _0x58665d){const _0x1084fd=this['_baseRoots']['get'](_0x35eee1['rootName']),_0x22914f=this['_diffRoots']['get'](_0x35eee1['rootName']),_0x55deb5=new vt(this['_fixPosition'](_0x35eee1['start'],_0x1084fd),this['_fixPosition'](_0x35eee1['end'],_0x1084fd)),_0x3c2061=this['_fixRange'](_0x55deb5,_0x22914f);_0x1084fd['markers']['set'](_0x1b97a2,_0x55deb5),this['_markers']['set'](_0x1b97a2,_0x3c2061);}this['_applyOperations'](_0x2d2c4c,_0x794553,_0x38a246);}['_applyOperations'](_0xd2299d,_0x36062a,_0x8e8160){for(const _0x347953 of this['source']['getOperations'](_0xd2299d,_0x36062a))this['_handleOperation'](_0x347953,_0x8e8160);for(const _0xce5a1b of this['_diffRoots']['values']())_0xce5a1b['markers']['clear']();for(const [_0x1b693b,_0x2970d8]of this['_markers']){this['_diffRoots']['get'](_0x2970d8['root']['rootName'])['markers']['set'](_0x1b693b,_0x2970d8['clone']());}const _0x279c89=new Map(),_0x594987=new Map();for(const [_0x5e65a9,_0x1e0fba]of this['_diffRoots'])_0x279c89['set'](_0x5e65a9,T(_0x1e0fba)),_0x594987['set'](_0x5e65a9,this['_diffRootsAttributes']['get'](_0x5e65a9));this['_saveMetaData'](_0x36062a,_0x279c89,this['_markers'],_0x594987);}['_getPreviousFrom'](_0xe5caf){const _0x1384f0=Array['from'](this['_savedMetaData']['keys']());_0x1384f0['sort']((_0x3bc1b1,_0x1bf01f)=>_0x3bc1b1-_0x1bf01f),_0x1384f0['reverse']();for(const _0x4bb922 of _0x1384f0)if(_0x4bb922<_0xe5caf)return _0x4bb922;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x3641a3,_0x41918d){const _0x4f907b=Array['from'](_0x41918d['markers'])['map'](([_0xa09240,_0x51bd2b])=>[_0xa09240,this['_fixRange'](_0x51bd2b,_0x3641a3)]);_0x3641a3['markers']=new Map(_0x4f907b);}['_transformMarkers'](_0x3b550d){for(const _0x254326 of this['_markers']['values']()){const _0xfbef51=_0x254326['getTransformedByOperation'](_0x3b550d),_0x3cbc5b=vt['_createFromRanges'](_0xfbef51);_0x254326['start']=_0x3cbc5b['start'],_0x254326['end']=_0x3cbc5b['end'];}}['_handleOperation'](_0x5e8f65,_0x247854){if('addRoot'!=_0x5e8f65['type']&&'detachRoot'!=_0x5e8f65['type']){if('insert'==_0x5e8f65['type']){const _0x4b76f2=_0x5e8f65['position']['root']['rootName'];this['_diffRoots']['has'](_0x4b76f2)||(this['_diffRoots']['set'](_0x4b76f2,F(_0x4b76f2,!0x0)),this['_diffRootsAttributes']['set'](_0x4b76f2,{}),_0x247854&&this['_idsRoots']['set'](_0x4b76f2,F(_0x4b76f2,!0x0)));}else{if('addRootAttribute'==_0x5e8f65['type']||'removeRootAttribute'==_0x5e8f65['type']||'changeRootAttribute'==_0x5e8f65['type'])return void this['_handleRootAttributeOperation'](_0x5e8f65);'marker'==_0x5e8f65['type']&&this['_handleMarkerOperation'](_0x5e8f65);}if('marker'!==_0x5e8f65['type']){const _0x187040=this['_cloneOperation'](_0x5e8f65,this['_diffRoots']);_0x187040['_execute'](),this['_transformMarkers'](_0x187040);}if(_0x247854)switch(_0x5e8f65['type']){case'insert':this['_handleInsertOperation'](_0x5e8f65);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x5e8f65);break;case'merge':this['_handleMergeOperation'](_0x5e8f65);break;case'split':this['_handleSplitOperation'](_0x5e8f65);}}else this['_handleRootOperation'](_0x5e8f65,_0x247854);}['_cloneOperation'](_0xce6e7e,_0x538c79){const _0x14bf8b=_0xce6e7e['clone']();return _0x14bf8b['_authorId']=_0xce6e7e['_authorId'],this['_fixOperation'](_0x14bf8b,_0x538c79),_0x14bf8b;}['_getBaseVids'](_0x563a9e){return _0x563a9e['map'](_0x28d866=>{const _0x498506=this['_getVidAttributeName'](_0x28d866);return Number(_0x28d866['item']['getAttribute'](_0x498506));});}['_generateTape'](_0x442281,_0x1f61d1){if(_0x442281['is']('element','$text'))_0x1f61d1['push']({'item':_0x442281,'type':'text'});else{_0x442281['is']('element')&&_0x1f61d1['push']({'item':_0x442281,'type':'elementStart'});for(const _0xf897b4 of _0x442281['getChildren']())this['_generateTape'](_0xf897b4,_0x1f61d1);_0x442281['is']('element')&&_0x1f61d1['push']({'item':_0x442281,'type':'elementEnd'});}return _0x1f61d1;}['_getState'](){const _0x1ba706=new Map(this['_touched']),_0x1cebf4=new Map(_0x1ba706),_0x4fed4d=new Map(),_0x3a4b20={'insertions':{},'deletions':{}},_0x16bc81={'insertions':{},'deletions':{}},_0x313ddd=new Map(),_0x2a27f6=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x2a27f6['delete']('$graveyard');for(const _0x3f5154 of _0x2a27f6){const _0x50b9a6=this['_diffRoots']['get'](_0x3f5154)||F(_0x3f5154,!0x1),_0x164d69=this['_baseRoots']['get'](_0x3f5154)||F(_0x3f5154,!0x1);_0x50b9a6['isAttached']()||_0x164d69['isAttached']()?(_0x3a4b20['insertions'][_0x3f5154]=T(_0x50b9a6),_0x3a4b20['deletions'][_0x3f5154]=T(_0x164d69),this['_copyMarkers'](_0x3a4b20['deletions'][_0x3f5154],_0x164d69),this['_copyMarkers'](_0x3a4b20['insertions'][_0x3f5154],_0x50b9a6),_0x16bc81['insertions'][_0x3f5154]=this['_generateTape'](this['_idsRoots']['get'](_0x3f5154),[]),_0x16bc81['deletions'][_0x3f5154]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x3f5154)||F(_0x3f5154,!0x1),[])):_0x2a27f6['delete'](_0x3f5154);}for(const _0x1eefce of _0x2a27f6){const _0x184715=_0x16bc81['insertions'][_0x1eefce];for(const _0x1e2ce of _0x184715){const _0x3ba5d7=this['_getVidAttributeName'](_0x1e2ce),_0x5b24a9=_0x1e2ce['item']['getAttribute'](_0x3ba5d7);_0x1cebf4['delete'](_0x5b24a9),_0x5b24a9>=this['_startingRevisionId']&&_0x4fed4d['set'](_0x5b24a9,_0x1ba706['get'](_0x5b24a9));}}for(const _0x32a333 of _0x2a27f6){const _0x179c71=_0x16bc81['insertions'][_0x32a333],_0x5f00d9=this['_getBaseVids'](_0x16bc81['deletions'][_0x32a333]);let _0x313c9=0x0;for(const _0x94c7d5 of _0x179c71){const _0x417d3b=this['_getVidAttributeName'](_0x94c7d5),_0x2d5ef6=_0x94c7d5['item']['getAttribute'](_0x417d3b);if(!_0x4fed4d['has'](_0x2d5ef6)&&!_0x313ddd['has'](_0x2d5ef6)){if(_0x1cebf4['has'](_0x2d5ef6))_0x313c9++;else{if(_0x2d5ef6!=_0x5f00d9[_0x313c9]){const _0x551b0a=_0x1ba706['get'](_0x2d5ef6)||_0x1ba706['get'](_0x5f00d9[_0x313c9]);for(;_0x2d5ef6!=_0x5f00d9[_0x313c9];)_0x1cebf4['has'](_0x5f00d9[_0x313c9])||(_0x313ddd['set'](_0x5f00d9[_0x313c9],_0x551b0a),_0x1ba706['set'](_0x5f00d9[_0x313c9],_0x551b0a)),_0x313c9++;}_0x313c9++;}}}}for(const _0x181fd1 of _0x2a27f6){const _0x2b9223=_0x16bc81['insertions'][_0x181fd1];for(const _0x220406 of _0x2b9223){const _0x58db2a=this['_getVidAttributeName'](_0x220406),_0x2a93de=_0x220406['item']['getAttribute'](_0x58db2a);if(_0x313ddd['has'](_0x2a93de)){const _0x4efcd9=_0x313ddd['get'](_0x2a93de);_0x1cebf4['has'](_0x2a93de)||_0x1cebf4['set'](_0x2a93de,{..._0x4efcd9}),_0x4fed4d['set'](_0x2a93de,{..._0x4efcd9});}}}for(const _0x3dfbc1 of _0x1cebf4['keys']())_0x3dfbc1>=this['_startingRevisionId']&&_0x1cebf4['delete'](_0x3dfbc1);const _0x3332ab=new Map();for(const _0x2f89fc of _0x2a27f6){let _0x576d6b=_0x16bc81['insertions'][_0x2f89fc];for(const _0x4e68d5 of _0x576d6b)if(_0x4e68d5['item']['is']('element','tableCell')){const _0xe8905f=this['_getVidAttributeName'](_0x4e68d5),_0x287954=_0x4e68d5['item']['getAttribute'](_0xe8905f);if(_0x4fed4d['has'](_0x287954)){const _0x1442d9=_0x4e68d5['item']['parent']['parent']['getAttribute']('vid_start'),_0x16fbb4=_0x3332ab['get'](_0x1442d9)||new Set();_0x16fbb4['add'](_0x4fed4d['get'](_0x287954)['userId']),_0x3332ab['set'](_0x1442d9,_0x16fbb4);}}_0x576d6b=_0x16bc81['deletions'][_0x2f89fc];for(const _0xec0f87 of _0x576d6b)if(_0xec0f87['item']['is']('element','tableCell')){const _0x49c34e=this['_getVidAttributeName'](_0xec0f87),_0x5c914d=_0xec0f87['item']['getAttribute'](_0x49c34e);if(_0x1cebf4['has'](_0x5c914d)){const _0x189c57=_0xec0f87['item']['parent']['parent']['getAttribute']('vid_start'),_0x5dc59c=_0x3332ab['get'](_0x189c57)||new Set();_0x5dc59c['add'](_0x1cebf4['get'](_0x5c914d)['userId']),_0x3332ab['set'](_0x189c57,_0x5dc59c);}}for(const _0x11994b of _0x3332ab['keys']())(_0x4fed4d['has'](_0x11994b)||_0x1cebf4['has'](_0x11994b))&&_0x3332ab['delete'](_0x11994b);}for(const _0x3df4c4 of _0x2a27f6){const _0xb0a5fa=_0x16bc81['insertions'][_0x3df4c4];let _0x33fa1c=null,_0x36c6a3=null;for(const _0x4e8a86 of _0xb0a5fa){const _0x543d74=this['_getVidAttributeName'](_0x4e8a86),_0x5229f8=_0x4e8a86['item']['getAttribute'](_0x543d74),_0x4028e4=_0x3332ab['get'](_0x5229f8);_0x4028e4&&'elementStart'==_0x4e8a86['type']&&(_0x33fa1c=Array['from'](_0x4028e4)[0x0],_0x36c6a3=_0x4e8a86['item']['getAttribute']('vid_end')),_0x33fa1c&&(_0x1cebf4['set'](_0x5229f8,{'userId':_0x33fa1c}),_0x4fed4d['set'](_0x5229f8,{'userId':_0x33fa1c})),_0x5229f8==_0x36c6a3&&(_0x33fa1c=null,_0x36c6a3=null);}}const _0x1e5ed1={},_0xbdd9f1=new Set();for(const _0x54b929 of _0x2a27f6){const _0x2265b2=_0x3a4b20['deletions'][_0x54b929],_0x127a14=_0x3a4b20['insertions'][_0x54b929];for(const {userId:_0x678a3c}of this['_touchedMarkers']['values']())null!==_0x678a3c&&_0xbdd9f1['add'](_0x678a3c);for(const {userId:_0x26dfa3}of this['_touchedRoots']['values']())null!==_0x26dfa3&&_0xbdd9f1['add'](_0x26dfa3);this['_markChanges'](_0x127a14,_0x16bc81['insertions'][_0x54b929],_0x4fed4d,'insertion',_0xbdd9f1),this['_markChanges'](_0x2265b2,_0x16bc81['deletions'][_0x54b929],_0x1cebf4,'deletion',_0xbdd9f1),_0x1e5ed1[_0x54b929]={'insertions':this['_prepareViewToSave'](_0x127a14),'deletions':this['_prepareViewToSave'](_0x2265b2),'attachChange':this['_touchedRoots']['get'](_0x54b929)||null,'attributesBefore':_0x2b10be(this['_baseRootsAttributes']['get'](_0x54b929))||{},'attributesAfter':_0x2b10be(this['_diffRootsAttributes']['get'](_0x54b929))};}return{'diffData':_0x1e5ed1,'authorsIds':Array['from'](_0xbdd9f1)};}['_processRootBeforeSave'](_0x196e22){for(const [,_0x444572]of _0x196e22['markers']){const _0x430e82=_0x444572['start']['getAncestors']()['filter'](_0x4bfe50=>'tableCell'==_0x4bfe50['name']);for(const _0x2fd2f4 of _0x430e82)0x1==_0x2fd2f4['childCount']&&_0x2fd2f4['getChild'](0x0)['is']('element','paragraph')&&_0x2fd2f4['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x3509cb){this['_processRootBeforeSave'](_0x3509cb);const _0x1f8a3c=this['editor']['data']['toView'](_0x3509cb,{}),_0x6ee7fb=Array['from'](_0x1f8a3c['getChildren']())['map'](_0x284d8c=>this['_getViewJson'](_0x284d8c));return JSON['stringify'](_0x6ee7fb);}['_getViewJson'](_0x2e3852){if(_0x2e3852['is']('$text'))return _0x2e3852['data'];{const _0x3ca445=_0x2e3852;return{'type':Object['keys'](P)['find'](_0x25bfc2=>_0x2e3852 instanceof P[_0x25bfc2]),'name':_0x3ca445['name'],'attributes':Array['from'](_0x3ca445['getAttributes']()),'children':Array['from'](_0x3ca445['getChildren']())['map'](_0x2f8b16=>this['_getViewJson'](_0x2f8b16))};}}['_markChanges'](_0xf1a627,_0x498014,_0x28e12c,_0x115962,_0x2c19b2){let _0x36850e=null,_0x1e4872=null,_0x525033=0x0;const _0x4f0713=this['editor']['model'];for(let _0x502d8a=0x0;_0x502d8a<_0x498014['length'];_0x502d8a++){const _0x1db221=this['_getVidAttributeName'](_0x498014[_0x502d8a]),_0x414385=_0x498014[_0x502d8a]['item']['getAttribute'](_0x1db221),_0x4239aa=_0x28e12c['get'](_0x414385),_0x5720f5=_0x502d8a==_0x498014['length']-0x1;(!_0x36850e&&_0x4239aa&&(_0x36850e=_0x4239aa,_0x1e4872=_0x498014[_0x502d8a]),_0x36850e&&(!_0x4239aa||_0x4239aa['userId']!=_0x36850e['userId']))&&(_0x31cde3(_0x4239aa,B(_0x1e4872,_0xf1a627,_0x4f0713),B(_0x498014[_0x502d8a],_0xf1a627,_0x4f0713)),_0x36850e=_0x4239aa||null,_0x1e4872=_0x4239aa?_0x498014[_0x502d8a]:null),_0x36850e&&_0x5720f5&&_0x31cde3(_0x4239aa,B(_0x1e4872,_0xf1a627,_0x4f0713),J(_0x498014[_0x502d8a],_0xf1a627,_0x4f0713));}function _0x31cde3(_0xa1ca3c,_0x469029,_0x564394){const _0x598ce9=_0x36850e['userId'],_0x1b8ed8='revision:'+_0x115962+':'+_0x598ce9+':'+_0x525033++,_0x221979=_0x4f0713['createRange'](_0x469029,_0x564394);_0xf1a627['markers']['set'](_0x1b8ed8,_0x221979),null!==_0x598ce9&&_0x2c19b2['add'](_0x598ce9);}}['_getVidAttributeName'](_0x58cd5e){switch(_0x58cd5e['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x12079b,_0x26d59a){_0x12079b['baseVersion']=null;for(const _0x4a19aa in _0x12079b){const _0x45bdca=_0x12079b[_0x4a19aa];if(_0x45bdca instanceof gt){const _0x367a2d=_0x26d59a['get'](_0x45bdca['root']['rootName']);_0x12079b[_0x4a19aa]=this['_fixPosition'](_0x45bdca,_0x367a2d);}if(_0x45bdca instanceof vt){const _0x34c993=_0x26d59a['get'](_0x45bdca['root']['rootName']);_0x12079b[_0x4a19aa]=this['_fixRange'](_0x45bdca,_0x34c993);}'root'===_0x4a19aa&&(_0x12079b['root']=_0x26d59a['get'](_0x12079b['root']['rootName']));}}['_fixRange'](_0x5e3401,_0x403665){return this['editor']['model']['createRange'](this['_fixPosition'](_0x5e3401['start'],_0x403665),this['_fixPosition'](_0x5e3401['end'],_0x403665));}['_fixPosition'](_0x1af01a,_0x4a5a30){return this['editor']['model']['createPositionFromPath'](_0x4a5a30,_0x1af01a['path'],_0x1af01a['stickiness']);}['_handleInsertOperation'](_0x1f4fcd){const _0x1b49d4=this['_idsRoots']['get'](_0x1f4fcd['position']['root']['rootName']),_0x14fb37=this['_fixPosition'](_0x1f4fcd['position'],_0x1b49d4),_0x1a2fdb=null===_0x1f4fcd['_authorId']?null:_0x1f4fcd['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x4eb9c7=_0x14fb37['parent'],_0x416efe=this['_revisionId'],_0x606e8b=[];for(const _0x2d3105 of _0x1f4fcd['nodes'])if(_0x2d3105['is']('element'))_0x606e8b['push'](this['_makeIdsRoot'](_0x2d3105));else{for(let _0x2fcaa5=0x0;_0x2fcaa5<_0x2d3105['offsetSize'];_0x2fcaa5++)_0x606e8b['push'](new ft('$text',{'vid':this['_revisionId']++}));}const _0x215478=this['_revisionId'];for(let _0xd88a50=_0x416efe;_0xd88a50<_0x215478;_0xd88a50++)this['_touched']['set'](_0xd88a50,{'userId':_0x1a2fdb});_0x4eb9c7['_insertChild'](_0x14fb37['offset'],_0x606e8b);}['_handleMoveOperation'](_0x29bc00){(_0x29bc00=this['_cloneOperation'](_0x29bc00,this['_idsRoots']))['_execute']();const _0x5ffa94=null===_0x29bc00['_authorId']?null:_0x29bc00['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x18c3e0=_0x29bc00['getMovedRangeStart'](),_0xcf03b8=_0x18c3e0['parent'],_0x22b72f=_0x18c3e0['offset'];!function _0x270241(_0x278559,_0x41763a,_0xed30cc,_0x4eb7e6){for(let _0x50d464=_0xed30cc;_0x50d464<_0x4eb7e6;_0x50d464++){const _0x451358=_0x41763a['getChild'](_0x50d464);_0x451358['is']('element','$text')?_0x278559['set'](_0x451358['getAttribute']('vid'),{'userId':_0x5ffa94}):(_0x278559['set'](_0x451358['getAttribute']('vid_start'),{'userId':_0x5ffa94}),_0x270241(_0x278559,_0x451358,0x0,_0x451358['childCount']),_0x278559['set'](_0x451358['getAttribute']('vid_end'),{'userId':_0x5ffa94}));}}(this['_touched'],_0xcf03b8,_0x22b72f,_0x22b72f+_0x29bc00['howMany']);}['_handleMergeOperation'](_0x5e5dbd){const _0x426c2d=null===(_0x5e5dbd=this['_cloneOperation'](_0x5e5dbd,this['_idsRoots']))['_authorId']?null:_0x5e5dbd['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x35b27e=_0x5e5dbd['targetPosition']['parent'],_0x211e29=_0x5e5dbd['sourcePosition']['parent'],_0xb4dd4=_0x35b27e['getAttribute']('vid_end'),_0x281943=_0x211e29['getAttribute']('vid_start');_0x35b27e['_setAttribute']('vid_end',_0x211e29['getAttribute']('vid_end')),_0x211e29['_setAttribute']('vid_end',_0xb4dd4),this['_touched']['set'](_0x281943,{'userId':_0x426c2d}),this['_touched']['set'](_0xb4dd4,{'userId':_0x426c2d}),_0x5e5dbd['_execute']();}['_handleSplitOperation'](_0x596486){const _0x17ae01=null===(_0x596486=this['_cloneOperation'](_0x596486,this['_idsRoots']))['_authorId']?null:_0x596486['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x31e39e=_0x596486['graveyardPosition'],_0x592a4b=_0x596486['splitPosition']['parent'];_0x596486['_execute']();const _0x4be606=_0x592a4b['getAttribute']('vid_end'),_0x2ab580=_0x596486['insertionPosition']['nodeAfter'];if(_0x31e39e){const _0x572711=_0x2ab580['getAttribute']('vid_end'),_0x1c352f=_0x592a4b['getAttribute']('vid_end');_0x592a4b['_setAttribute']('vid_end',_0x572711),_0x2ab580['_setAttribute']('vid_end',_0x1c352f),this['_touched']['set'](_0x592a4b['getAttribute']('vid_end'),{'userId':_0x17ae01}),this['_touched']['set'](_0x2ab580['getAttribute']('vid_start'),{'userId':_0x17ae01});}else{const _0x5e0487=this['_revisionId']++,_0x3521ce=this['_revisionId']++;_0x592a4b['_setAttribute']('vid_end',_0x5e0487),_0x2ab580['_setAttribute']('vid_start',_0x3521ce),_0x2ab580['_setAttribute']('vid_end',_0x4be606),this['_touched']['set'](_0x5e0487,{'userId':_0x17ae01}),this['_touched']['set'](_0x3521ce,{'userId':_0x17ae01});}}['_handleMarkerOperation'](_0x51fef4){if(!_0x51fef4['affectsData'])return;const _0x3d6313=(_0x51fef4=this['_cloneOperation'](_0x51fef4,this['_diffRoots']))['oldRange']?_0x51fef4['oldRange']['root']:null,_0x3f259f=_0x51fef4['newRange']?_0x51fef4['newRange']['root']:null;_0x3d6313&&this['_markers']['delete'](_0x51fef4['name']),_0x3f259f&&this['_markers']['set'](_0x51fef4['name'],_0x51fef4['newRange']['clone']());const _0x2b52ad=null===_0x51fef4['_authorId']?null:_0x51fef4['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x134a39=_0x51fef4['name'];if(!this['_touchedMarkers']['has'](_0x134a39))return void this['_touchedMarkers']['set'](_0x134a39,{'range':_0x51fef4['oldRange'],'userId':_0x2b52ad});const _0x3dd039=this['_touchedMarkers']['get'](_0x134a39),_0x399ed7=_0x3dd039['range'],_0x229a95=_0x51fef4['newRange'];null==_0x399ed7&&null==_0x229a95||_0x399ed7&&_0x229a95&&_0x399ed7['isEqual'](_0x229a95)?this['_touchedMarkers']['delete'](_0x51fef4['name']):_0x3dd039['userId']=_0x2b52ad;}['_handleRootOperation'](_0x1161bd,_0x4f3287){this['_diffRoots']['has'](_0x1161bd['rootName'])?this['_diffRoots']['get'](_0x1161bd['rootName'])['_isAttached']=_0x1161bd['isAdd']:(this['_diffRoots']['set'](_0x1161bd['rootName'],F(_0x1161bd['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x1161bd['rootName'],{}),_0x4f3287&&this['_idsRoots']['set'](_0x1161bd['rootName'],F(_0x1161bd['rootName'],!0x0)));const _0x653bf5=null===_0x1161bd['_authorId']?null:_0x1161bd['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x13e42d=this['_touchedRoots']['get'](_0x1161bd['rootName']);_0x13e42d&&_0x13e42d['userId']===_0x653bf5?this['_touchedRoots']['delete'](_0x1161bd['rootName']):this['_touchedRoots']['set'](_0x1161bd['rootName'],{'userId':_0x653bf5,'isAttached':_0x1161bd['isAdd']});}['_handleRootAttributeOperation'](_0xddfa7){const _0x410269=this['_diffRootsAttributes']['get'](_0xddfa7['root']['rootName']);null===_0xddfa7['newValue']?delete _0x410269[_0xddfa7['key']]:_0x410269[_0xddfa7['key']]=_0xddfa7['newValue'];}}function T(_0x127522){const _0x52f6fc=F(_0x127522['rootName'],_0x127522['isAttached']());for(const _0x1a7321 of _0x127522['getChildren']()){const _0x5df650=_0x1a7321['_clone'](!0x0);_0x52f6fc['_appendChild'](_0x5df650);}return _0x52f6fc;}function F(_0x42079b,_0x53b037=!0x0){const _0x5e27ce=new mt();return _0x5e27ce['rootName']=_0x42079b,_0x5e27ce['_isAttached']=_0x53b037,_0x5e27ce['isAttached']=()=>_0x5e27ce['_isAttached'],_0x5e27ce;}function B(_0x2b0bb5,_0x125afa,_0x11ade8){const _0x202777='elementEnd'==_0x2b0bb5['type']?_0x11ade8['createPositionAt'](_0x2b0bb5['item'],'end'):_0x11ade8['createPositionBefore'](_0x2b0bb5['item']);return _0x11ade8['createPositionFromPath'](_0x125afa,_0x202777['path'],_0x202777['stickiness']);}function J(_0x5aa563,_0x512515,_0x58b500){const _0x557666='elementStart'==_0x5aa563['type']?_0x58b500['createPositionAt'](_0x5aa563['item'],0x0):_0x58b500['createPositionAfter'](_0x5aa563['item']);return _0x58b500['createPositionFromPath'](_0x512515,_0x557666['path'],_0x557666['stickiness']);}class ns extends _0x4a3822{['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x43a58e,_0x31d0c0){super(_0x43a58e),this['focusTracker']=new _0x4dac43(),this['keystrokes']=new _0x533f48(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x31d0c0),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'](),_0x993ef8({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x3b97d7=_0x16b225=>_0x16b225['stopPropagation']();this['keystrokes']['set']('arrowright',_0x3b97d7),this['keystrokes']['set']('arrowleft',_0x3b97d7),this['keystrokes']['set']('arrowup',_0x3b97d7),this['keystrokes']['set']('arrowdown',_0x3b97d7);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x30bd1f){this['revisionNameInputView']['fieldView']['element']['value']=_0x30bd1f['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0xa73f42){const _0x37722e=new nt(this['locale'],_0x5e5100),_0xec199c=_0x37722e['fieldView'];_0xec199c['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x9a05de=m(this['locale'],'Name\x20of\x20the\x20revision');return!_0xa73f42&&(_0x9a05de+='\x20('+m(this['locale'],'optional')+')'),(_0x37722e['label']=_0x9a05de,_0xec199c['on']('input',()=>{this['revisionNameInputValue']=_0xec199c['element']['value']['trim']();}),_0x37722e);}}class u extends _0x32454b{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l];}['_saveRevisionFormView'];['init'](){const _0x32a0bb=this['editor'],_0x1d999c=_0x32a0bb['plugins']['get']('RevisionTracker');_0x32a0bb['ui']['componentFactory']['add']('revisionHistory',_0x48da6a=>{const _0x2d1291=_0x2e60bd(_0x48da6a),_0x11753e=_0x2d1291['panelView']['children'],_0x2cbcbd=new te(_0x48da6a),_0x2fea7f=new _0x37f162(_0x48da6a),_0x15e5a6=new _0x20da59(_0x48da6a),_0x17a201=new _0x37f162(_0x48da6a),_0x3005ce=new _0x20da59(_0x48da6a);return _0x2d1291['bind']('isEnabled')['to'](_0x1d999c,'isReady',_0x1d999c,'isEnabled',_0x32a0bb,'isReadOnly',(_0x3f6f59,_0x19893b,_0x21e01b)=>_0x3f6f59&&_0x19893b&&!_0x21e01b),_0x2d1291['buttonView']['set']({'icon':_0x15f173['history'],'label':m(_0x48da6a,'Revision\x20history'),'tooltip':!0x0}),_0x15e5a6['set']({'label':m(_0x48da6a,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x15e5a6['bind']('isEnabled')['to'](_0x1d999c,'isReady',_0x1d999c,'isEnabled',_0x32a0bb,'isReadOnly',(_0x634641,_0x46f2fe,_0x122f6e)=>_0x634641&&_0x46f2fe&&!_0x122f6e),_0x15e5a6['on']('execute',()=>this['_showDialog']()),_0x3005ce['set']({'label':m(_0x48da6a,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x3005ce['bind']('isEnabled')['to'](_0x1d999c,'isReady',_0x32a0bb,'isReadOnly',(_0x2f52d8,_0x255b0b)=>_0x2f52d8&&!_0x255b0b),_0x3005ce['on']('execute',()=>{_0x32a0bb['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x2d1291['isOpen']=!0x1,_0x32a0bb['editing']['view']['focus']();}),_0x2fea7f['children']['add'](_0x15e5a6),_0x17a201['children']['add'](_0x3005ce),_0x2cbcbd['role']='menu',_0x2cbcbd['items']['addMany']([_0x2fea7f,_0x17a201]),_0x11753e['add'](_0x2cbcbd),_0x2d1291;}),_0x32a0bb['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x320cc4=this['editor'],_0x20ccad=_0x320cc4['locale'],_0x5845ca=new _0x2d4176(_0x20ccad),_0x36fec1=new _0x1c4cb5(_0x20ccad);_0x5845ca['buttonView']['set']({'icon':_0x15f173['history'],'label':m(_0x20ccad,'Revision\x20history')});const _0x4e4fb1=new _0x4ef73b(_0x20ccad,_0x5845ca),_0x5af8c0=new _0x445b04(_0x20ccad);_0x5af8c0['set']({'label':m(_0x20ccad,'Save\x20current\x20revision')}),_0x5af8c0['delegate']('execute')['to'](_0x5845ca),_0x5af8c0['on']('execute',()=>{this['_showDialog']();}),_0x4e4fb1['children']['add'](_0x5af8c0),_0x36fec1['items']['add'](_0x4e4fb1);const _0xb25d2=new _0x4ef73b(_0x20ccad,_0x5845ca),_0x566fc3=new _0x445b04(_0x20ccad);return _0x566fc3['set']({'label':m(_0x20ccad,'Open\x20revision\x20history')}),_0x566fc3['delegate']('execute')['to'](_0x5845ca),_0x566fc3['on']('execute',()=>{_0x320cc4['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0xb25d2['children']['add'](_0x566fc3),_0x36fec1['items']['add'](_0xb25d2),_0x5845ca['panelView']['children']['add'](_0x36fec1),_0x5845ca;}['_showDialog'](){const _0x226063=this['editor'],_0x97b870=_0x226063['locale'],_0x2c9353=_0x226063['plugins']['get']('Dialog'),_0xf3bfa0=_0x226063['plugins']['get']('RevisionTracker');function _0x3d0b9d(_0x4faa2e){_0x226063['config']['get']('revisionHistory.requireRevisionName')&&''===_0x4faa2e['revisionName']?_0x4faa2e['revisionNameInputView']['errorText']=m(_0x97b870,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x226063['plugins']['get'](l)['saveRevision']({'name':_0x4faa2e['revisionName']}),_0x2c9353['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x3d0b9d(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x2c9353['show']({'id':'revisionSave','title':m(_0x97b870,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':m(_0x226063['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x2c9353['hide']()},{'label':m(_0x226063['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0xfe99e7){_0xfe99e7['bind']('isEnabled')['to'](_0xf3bfa0,'isReady',_0xf3bfa0,'isEnabled',_0x226063,'isReadOnly',(_0x44786b,_0x489c8d,_0x3179b2)=>_0x44786b&&_0x489c8d&&!_0x3179b2);},'onExecute':()=>_0x3d0b9d(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x312802=this['editor'],_0x4098b8=_0x312802['locale'];this['_saveRevisionFormView']=new ns(_0x4098b8,_0x312802['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class X extends _0x4a3822{['changeId'];['_model'];constructor(_0x1de6f8,_0x407ce4){super(_0x1de6f8),this['_model']=_0x407ce4,this['changeId']=_0x407ce4['id'];const _0x99e512=this['bindTemplate'],_0x4ef832=m(_0x1de6f8,_0x407ce4['data']['isSuggestion']?'Suggested\x20by':'add'==_0x407ce4['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x407ce4['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x99e512['to']('type',_0x54b476=>'ck-revision-change__'+_0x54b476)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x4ef832}]},{'text':'\x20'+_0x407ce4['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class r extends/* #__PURE__ -- @preserve */
|
|
25
|
+
_0xe5b2fd(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x3cbd77){super(),this['id']=_0x3cbd77['id']||_0x4ff600(),this['author']=_0x3cbd77['author'],this['type']=_0x3cbd77['type'],this['data']=_0x3cbd77['data']||{},this['rootName']=_0x3cbd77['rootName'],this['set']('createdAt',_0x3cbd77['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(_0x710f3d,_0x114e28){this['newRevisionId']=_0x710f3d,this['oldRevisionId']=_0x114e28,this['changes']=new _0x4e4c8a();}['_setChanges'](_0x29ac78){for(const _0x2ea0b9 of _0x29ac78)this['changes']['add'](_0x2ea0b9);}}const Y={'c':_0x741c8a,'a':_0x5b9586,'e':_0x23f14e,'r':_0x496ec4,'u':_0x429f21};class d extends _0x32454b{['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[_0xa55a60,_0x51b82d,j];}constructor(_0x54aa14){super(_0x54aa14),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',(_0x31b7ec,_0x3ae374,_0x41a127)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x557962=>{for(const _0x1b672d of this['editor']['editing']['view']['document']['roots'])_0x41a127?_0x557962['removeClass']('ck-editor__editable__overlay',_0x1b672d):_0x557962['addClass']('ck-editor__editable__overlay',_0x1b672d);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x33555a=>null!==_0x33555a),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x4e323b,_0x5c03f4,_0x3fd2a0)=>_0x4e323b&&_0x3fd2a0?_0x5c03f4['changes']['getIndex'](_0x3fd2a0):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0xdc8ec2,_0x1fe528)=>_0xdc8ec2?_0x1fe528['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['adapter']=null,this['_balloon']=this['editor']['plugins']['get'](_0x51b82d);}['init'](){const _0x3749d9=this['editor'],_0x11c693=new yt(_0x3749d9,{'direction':'backward'}),_0x243486=new yt(_0x3749d9,{'direction':'forward'});(_0x3749d9['commands']['add']('showPreviousChange',_0x11c693),_0x3749d9['commands']['add']('showNextChange',_0x243486),_0x3749d9['commands']['add']('restoreRevision',new _t(_0x3749d9)),this['on']('change:numberOfChanges',()=>{_0x11c693['refresh'](),_0x243486['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x3749d9['enableReadOnlyMode']('revision-viewer'),_0x3749d9['plugins']['has']('WidgetToolbarRepository'))&&_0x3749d9['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionData'](_0x101a22){await this['loadRevisionData'](_0x101a22);const _0x1b1bac={};for(const _0x8b866e in _0x101a22['diffData']){if(_0x101a22['diffData'][_0x8b866e]['attachChange']&&!_0x101a22['diffData'][_0x8b866e]['attachChange']['isAttached'])continue;const _0x557d67=this['_removeRevisionMarkers'](JSON['parse'](_0x101a22['diffData'][_0x8b866e]['insertions'])),_0x1486c2=this['editor']['editing']['view']['document'],_0x85de55=new _0x363fce(_0x1486c2,_0x557d67['map'](_0x111e1=>this['_getViewObj'](_0x111e1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x1b1bac[_0x8b866e]=this['editor']['data']['processor']['toData'](_0x85de55),this['editor']['data']['processor']['useFillerType']('default');}return _0x1b1bac;}async['getRevisionRootsAttributes'](_0x50197e){await this['loadRevisionData'](_0x50197e);const _0x2eac9b={};for(const _0x703665 in _0x50197e['diffData'])_0x50197e['diffData'][_0x703665]['attachChange']&&!_0x50197e['diffData'][_0x703665]['attachChange']['isAttached']||(_0x2eac9b[_0x703665]=_0x50197e['diffData'][_0x703665]['attributesAfter']||{});return _0x2eac9b;}['_removeRevisionMarkers'](_0x19b082){return(_0x19b082=_0x19b082['filter'](_0x21c8a2=>!_0x21c8a2['name']||'revision-start'!==_0x21c8a2['name']&&'revision-end'!==_0x21c8a2['name']))['forEach'](_0x1f9d11=>{'string'!=typeof _0x1f9d11&&(_0x1f9d11['children']=this['_removeRevisionMarkers'](_0x1f9d11['children']),_0x1f9d11['attributes']=_0x1f9d11['attributes']['filter'](_0x10cd31=>!_0x10cd31[0x0]['startsWith']('data-revision-')));}),_0x19b082;}async['compare'](_0x4f6013,_0x596dce,_0x54c5a8=!0x1){if(!this['isEnabled'])return;const _0x44d54e=this['diff'],_0x278347=this['repository'],_0x5eed99='string'==typeof _0x4f6013?_0x278347['getRevision'](_0x4f6013):_0x4f6013,_0x39b558='string'==typeof _0x596dce?_0x278347['getRevision'](_0x596dce):_0x596dce,_0x325469=_0x5eed99['id'],_0x3311db=_0x39b558?_0x39b558['id']:null;if(!_0x54c5a8&&this['diff']&&this['diff']['newRevisionId']===_0x325469&&this['diff']['oldRevisionId']===_0x3311db)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new f(_0x325469,_0x3311db);const _0x189ba3=this['_getRevisionsRange'](_0x5eed99,_0x39b558,!0x0)['map'](_0x83fcbb=>this['loadRevisionData'](_0x83fcbb));return _0x189ba3['push'](new Promise(_0x49ddce=>{setTimeout(_0x49ddce,0x14);})),Promise['all'](_0x189ba3)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x1341fe=this['_getDiff'](_0x325469,_0x3311db);for(const _0x13af56 of _0x1341fe['changes'])this['_changeIdToChange']['set'](_0x13af56['id'],_0x13af56);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x37cd1c=>{for(const _0x3f4296 of this['editor']['model']['document']['getRootNames']())_0x37cd1c['detachRoot'](_0x3f4296);for(const _0x3933f3 of Object['keys'](_0x1341fe['model'])){const _0x9dbf6b=_0x37cd1c['addRoot'](_0x3933f3);for(const _0x13aded of Object['keys'](_0x1341fe['attributes'][_0x3933f3]))_0x37cd1c['setAttribute'](_0x13aded,_0x1341fe['attributes'][_0x3933f3][_0x13aded],_0x9dbf6b);_0x37cd1c['insert'](_0x1341fe['model'][_0x3933f3],_0x9dbf6b,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x1341fe['changes'])),this['isReady']=!0x0;})['catch'](_0x2aa790=>{console['error'](_0x2aa790),this['_cleanUp'](),_0x44d54e&&(this['diff']=_0x44d54e),this['isReady']=!0x0;});}['addRevisionData'](_0x10e8c5,_0x49d834){const _0x40a006=this['repository']['createRevision'](_0x10e8c5);return _0x40a006['on']('_update',(_0x3a02c6,_0x205fbc,_0x53aaa0)=>_0x49d834(_0x205fbc,_0x53aaa0,_0x40a006)),this['repository']['addRevision'](_0x40a006),_0x40a006;}['loadRevisionData'](_0x32594d){if(!_0x32594d||_0x32594d['diffData'])return Promise['resolve']();{const _0x2c59cd=this['editor']['config']['get']('collaboration.channelId');return this['adapter']['getRevision']({'channelId':_0x2c59cd,'revisionId':_0x32594d['id']})['then'](_0x55e019=>{_0x32594d['_update']({'diffData':_0x55e019['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},_0x2e50f6=>{for(const _0x13603b of this['editor']['model']['document']['getRootNames']())_0x2e50f6['detachRoot'](_0x13603b);});}['_sortAndFilterDiffChanges'](_0x293859){const _0x18b1e0=[],_0x2d2a4f=new Map();for(const _0x46908d of this['editor']['model']['document']['getRootNames']()){const _0x30f7f5=this['editor']['editing']['view']['getDomRoot'](_0x46908d);if(!_0x30f7f5)continue;const _0x34a1a1=_0x30f7f5['getClientRects']()['item'](0x0);_0x34a1a1&&(_0x18b1e0['push'](_0x46908d),_0x2d2a4f['set'](_0x46908d,_0x34a1a1));}return _0x18b1e0['sort']((_0x17d103,_0x2fdeaa)=>{const _0x131df5=_0x2d2a4f['get'](_0x17d103),_0x66a61d=_0x2d2a4f['get'](_0x2fdeaa);return _0x131df5['y']-_0x66a61d['y']||_0x131df5['x']-_0x66a61d['x'];}),(_0x293859=_0x293859['filter'](_0x4cf0eb=>_0x18b1e0['includes'](_0x4cf0eb['rootName'])))['sort']((_0x17a20e,_0x1b2870)=>_0x18b1e0['indexOf'](_0x17a20e['rootName'])-_0x18b1e0['indexOf'](_0x1b2870['rootName'])),_0x293859;}['_makeTape'](_0x2ca1ba){const _0x3070ca=Array['from'](_0x2ca1ba['markers'])['filter'](([_0x4893e2,_0x542dc5])=>_0x4893e2['startsWith']('revision:')&&!_0x542dc5['isCollapsed']),_0x552abd=Array['from'](this['editor']['model']['createRangeIn'](_0x2ca1ba)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x3070ca['length'])for(const _0x195c73 of _0x552abd){const [_0x533a55,_0x49c3a9]=_0x3070ca[0x0],[,_0x86152b,_0x355975]=_0x533a55['split'](':');if(_0x49c3a9['end']['isEqual'](_0x195c73['nextPosition'])&&_0x3070ca['shift'](),(_0x195c73['previousPosition']['isEqual'](_0x49c3a9['start'])||_0x195c73['previousPosition']['isAfter'](_0x49c3a9['start']))&&('insertion'==_0x86152b?_0x195c73['isAdded']={'userId':_0x355975}:'deletion'==_0x86152b&&(_0x195c73['isRemoved']={'userId':_0x355975})),0x0==_0x3070ca['length'])break;}return _0x552abd;}['_refreshStartEndIndex'](_0x278676){const _0x206615=new Map();for(let _0x2d71b0=0x0;_0x2d71b0<_0x278676['length'];_0x2d71b0++)'text'===_0x278676[_0x2d71b0]['type']?(_0x278676[_0x2d71b0]['item']['startIndex']=_0x2d71b0,_0x278676[_0x2d71b0]['item']['endIndex']=_0x2d71b0):('elementStart'===_0x278676[_0x2d71b0]['type']?_0x278676[_0x2d71b0]['item']['startIndex']=_0x2d71b0:'elementEnd'===_0x278676[_0x2d71b0]['type']&&(_0x278676[_0x2d71b0]['item']['endIndex']=_0x2d71b0),_0x206615['set'](_0x278676[_0x2d71b0]['id'],_0x2d71b0));for(const _0x451814 of _0x206615['values']())'elementStart'===_0x278676[_0x451814]['type']?_0x278676[_0x451814]['item']['endIndex']=_0x206615['get'](_0x278676[_0x451814]['pairId']):'elementEnd'===_0x278676[_0x451814]['type']&&(_0x278676[_0x451814]['item']['startIndex']=_0x206615['get'](_0x278676[_0x451814]['pairId']));}['_processTape'](_0x3ed0e2){for(let _0xf8963f=0x0;_0xf8963f<_0x3ed0e2['length'];_0xf8963f++){if('elementStart'===_0x3ed0e2[_0xf8963f]['type'])_0x3ed0e2[_0xf8963f]['item']['startIndex']=_0xf8963f;else{if('elementEnd'===_0x3ed0e2[_0xf8963f]['type']){_0x3ed0e2[_0xf8963f]['item']['endIndex']=_0xf8963f;const _0x3da551=_0x3ed0e2[_0xf8963f]['item']['startIndex'];_0x3ed0e2[_0x3da551]['pairId']=_0x3ed0e2[_0xf8963f]['id'],_0x3ed0e2[_0xf8963f]['pairId']=_0x3ed0e2[_0x3da551]['id'];}else _0x3ed0e2[_0xf8963f]['item']['startIndex']=_0xf8963f,_0x3ed0e2[_0xf8963f]['item']['endIndex']=_0xf8963f,_0x3ed0e2[_0xf8963f]['pairId']=null;}_0x3ed0e2[_0xf8963f]['markersStart']||(_0x3ed0e2[_0xf8963f]['markersStart']=[],_0x3ed0e2[_0xf8963f]['markersEnd']=[]);}}['_markInsertions'](_0x538ad2,_0x40fc67){const _0x36c0ab=_0x538ad2['filter'](_0x106ab1=>!_0x106ab1['isAdded']);for(let _0x338402=0x0;_0x338402<_0x40fc67['length'];_0x338402++)_0x40fc67[_0x338402]['isAdded']&&(_0x36c0ab[_0x338402]['isAdded']=_0x40fc67[_0x338402]['isAdded']);}['_makeModelFromViewString'](_0x2cbbb3){const _0x532d38=JSON['parse'](_0x2cbbb3),_0x10b97b=this['editor']['editing']['view']['document'],_0x456057=new _0x363fce(_0x10b97b,_0x532d38['map'](_0x157780=>this['_getViewObj'](_0x157780)));return this['editor']['data']['toModel'](_0x456057);}['_getViewObj'](_0x495748){const _0x3ab4a6=this['editor']['editing']['view']['document'];if('string'==typeof _0x495748)return new _0x363037(_0x3ab4a6,_0x495748);{const _0x5d9e80=_0x495748['children']['map'](_0x806691=>this['_getViewObj'](_0x806691));return new(Y[_0x495748['type']]||_0x50af6c)(_0x3ab4a6,_0x495748['name'],_0x495748['attributes'],_0x5d9e80);}}['_getDiff'](_0x268658,_0xd3f6a4=null){const _0x2ede03=this['repository']['getRevision'](_0x268658),_0x4e1858=_0xd3f6a4?this['repository']['getRevision'](_0xd3f6a4):null,_0xd6aa09=this['_getRevisionsRange'](_0x2ede03,_0x4e1858),_0x7d34f1=_0xd6aa09[_0xd6aa09['length']-0x1],_0x405557=new Map(),_0xde36c={'model':{},'attributes':{},'changes':[]},_0x203b28=new Set(),_0x466d7d=new Map();for(let _0x534400=_0xd6aa09['length']-0x1;_0x534400>=0x0;_0x534400--){const _0x3702db=_0xd6aa09[_0x534400];for(const _0x31b773 of Object['keys'](_0x3702db['diffData']))if(_0x3702db['diffData'][_0x31b773]['attachChange']){const _0x3198cb=_0x3702db['diffData'][_0x31b773]['attachChange'];_0x3198cb['isAttached']?(_0x203b28['add'](_0x31b773),_0x466d7d['has'](_0x31b773)&&_0x466d7d['get'](_0x31b773)['userId']==_0x3198cb['userId']?_0x466d7d['delete'](_0x31b773):_0x466d7d['set'](_0x31b773,_0x3198cb)):_0x466d7d['has'](_0x31b773)?(_0x203b28['delete'](_0x31b773),_0x466d7d['delete'](_0x31b773)):(_0x203b28['add'](_0x31b773),_0x466d7d['set'](_0x31b773,_0x3198cb));}else _0x203b28['add'](_0x31b773);}for(const _0x54864c of _0x203b28){const _0x56dcdb=_0x466d7d['has'](_0x54864c)&&!_0x466d7d['get'](_0x54864c)['isAttached'];let _0x15e392=_0x56dcdb?_0xd6aa09['length']-0x1:0x0;const _0x2ba96e=_0x56dcdb?-0x1:0x1;for(;_0xd6aa09[_0x15e392];){const _0x5151e0=_0xd6aa09[_0x15e392];if(_0x5151e0['diffData'][_0x54864c]){const _0x4e9ce7=_0x56dcdb?_0x5151e0['diffData'][_0x54864c]['attributesBefore']:_0x5151e0['diffData'][_0x54864c]['attributesAfter'];_0xde36c['attributes'][_0x54864c]=_0x4e9ce7?_0x2b10be(_0x4e9ce7):{};break;}_0x15e392+=_0x2ba96e;}}for(const _0x22c69b of _0xd6aa09){_0x22c69b['model']={};for(const _0x56b5c8 of _0x22c69b['authors'])_0x405557['set'](_0x56b5c8['id'],_0x56b5c8);for(const _0x35dcb4 of _0x203b28){const _0x5d15b9=_0x22c69b['diffData'][_0x35dcb4]?_0x22c69b['diffData'][_0x35dcb4]['insertions']:'[]',_0x5971df=_0x22c69b['diffData'][_0x35dcb4]?_0x22c69b['diffData'][_0x35dcb4]['deletions']:'[]';_0x22c69b['model'][_0x35dcb4]={'insertions':this['_makeModelFromViewString'](_0x5d15b9),'deletions':this['_makeModelFromViewString'](_0x5971df)};}}for(const _0x657d4c of _0x203b28){let _0x5531ba=null,_0x4bcb08=0x0;const _0x3d543c=new Map(Array['from'](_0x2ede03['model'][_0x657d4c]['insertions']['markers'])['filter'](([_0x405c2b])=>!_0x405c2b['startsWith']('revision:')));let _0x1083e1=0x0;for(const _0x2ea644 of _0xd6aa09){const _0x596e9d=this['_makeTape'](_0x2ea644['model'][_0x657d4c]['insertions']);_0x2ea644==_0x2ede03?(_0x5531ba=_0x596e9d,_0x4bcb08=_0x5531ba['length'],_0x5531ba['forEach'](_0x248380=>{_0x248380['id']=_0x1083e1++;}),this['_processTape'](_0x5531ba)):this['_markInsertions'](_0x5531ba,_0x596e9d);const _0x5a7106=_0x5531ba['filter'](_0x59cad6=>!_0x59cad6['isAdded'])['map'](_0x19b7c9=>_0x19b7c9['id']);let _0x221ea6=0x0;const _0x32cf7a=this['_makeTape'](_0x2ea644['model'][_0x657d4c]['deletions']);_0x32cf7a['forEach'](_0x283e81=>{_0x283e81['isRemoved']?_0x283e81['id']=_0x4bcb08++:_0x283e81['id']=_0x5a7106[_0x221ea6++];}),this['_processTape'](_0x32cf7a),this['_setDistance'](_0x5531ba,'isAdded'),this['_setDistance'](_0x32cf7a,'isRemoved'),_0x2ea644==_0x2ede03&&this['_markMarkers'](_0x5531ba,_0x3d543c),_0x5531ba=this['_joinTapes'](_0x5531ba,_0x32cf7a),this['_refreshStartEndIndex'](_0x5531ba),this['_setDistance'](_0x5531ba,'isRemoved');}_0x5531ba=_0x5531ba['filter'](_0x12dffe=>!(_0x12dffe['isAdded']&&_0x12dffe['isRemoved']));const _0x4c4831=new Map(_0x7d34f1['model'][_0x657d4c]['deletions']['markers']),_0xeb7b9=new Set(_0x3d543c['keys']());for(const _0x1096a0 of _0x4c4831['keys']())_0xeb7b9['delete'](_0x1096a0);this['_markSuggestions'](_0x5531ba,_0xeb7b9),this['_fixObsoleteTags'](_0x5531ba),_0x5531ba=this['_removeMissingPairs'](_0x5531ba),_0x5531ba=this['_markMismatchedRemovedTags'](_0x5531ba),_0x5531ba=this['_removeUnsupportedChanges'](_0x5531ba);const {root:_0x399b32,changes:_0xb6f05d}=this['_makeModelFromTape'](_0x5531ba,_0x405557,_0x657d4c);_0xde36c['model'][_0x657d4c]=_0x399b32;const _0xbd5ba2=_0x466d7d['get'](_0x657d4c);if(_0xbd5ba2){const _0x24263d=_0x405557['get'](_0xbd5ba2['userId']),_0x412679=new r({'author':_0x24263d,'type':_0xbd5ba2['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x657d4c});_0xb6f05d['unshift'](_0x412679),_0xde36c['attributes'][_0x657d4c]['revisionHistoryAttachChange']=_0x412679['id'];}_0xde36c['changes']=_0xde36c['changes']['concat'](_0xb6f05d);}return _0xde36c;}['_markMarkers'](_0x3bd57b,_0x4f64bd){for(let _0x48f9ed=0x0;_0x48f9ed<_0x3bd57b['length'];_0x48f9ed++)for(const [_0x4aee9f,_0x168d3f]of _0x4f64bd)_0x168d3f['start']['isEqual'](_0x3bd57b[_0x48f9ed]['previousPosition'])&&_0x3bd57b[_0x48f9ed]['markersStart']['push'](_0x4aee9f),_0x168d3f['end']['isEqual'](_0x3bd57b[_0x48f9ed]['nextPosition'])&&_0x3bd57b[_0x48f9ed]['markersEnd']['push'](_0x4aee9f);}['_joinTapes'](_0x1c5068,_0x142e99){let _0x23809b=[],_0x115170=0x0,_0x4afab5=0x0;for(;_0x115170<_0x1c5068['length']||_0x4afab5<_0x142e99['length'];){const _0x3f3b84=_0x1c5068[_0x115170]||{},_0x164c80=_0x142e99[_0x4afab5]||{};if(_0x3f3b84['id']==_0x164c80['id'])_0x115170++,_0x4afab5++,_0x23809b['push'](_0x3f3b84);else{if(_0x164c80['isRemoved']&&_0x3f3b84['isAdded']){const {commonTape:_0x2bfab6,iEnd:_0x3bdcbc,jEnd:_0x29ab6e}=this['_threeWayMerge'](_0x1c5068,_0x115170,_0x142e99,_0x4afab5);_0x23809b=_0x23809b['concat'](_0x2bfab6),_0x115170=_0x3bdcbc,_0x4afab5=_0x29ab6e;}else _0x164c80['isRemoved']?(_0x4afab5++,_0x23809b['push'](_0x164c80)):(_0x115170++,_0x23809b['push'](_0x3f3b84));}}return _0x23809b;}['_markSuggestions'](_0x59fa6d,_0x4ce671){const _0x36ddd3=[];for(let _0x5e80a7=0x0;_0x5e80a7<_0x59fa6d['length'];_0x5e80a7++){for(let _0x95ef6f=0x0;_0x95ef6f<_0x59fa6d[_0x5e80a7]['markersStart']['length'];_0x95ef6f++){const _0x118c20=_0x59fa6d[_0x5e80a7]['markersStart'][_0x95ef6f];if(!_0x4ce671['has'](_0x118c20))continue;const {group:_0x50b800,type:_0x2b9a25,authorId:_0x2269e5}=_0x51f33d(_0x118c20);'revision-suggestion'!=_0x50b800||'insertion'!=_0x2b9a25&&'deletion'!=_0x2b9a25||(_0x36ddd3['unshift']({'type':_0x2b9a25,'name':_0x118c20,'userId':_0x2269e5}),_0x59fa6d[_0x5e80a7]['markersStart']['splice'](_0x95ef6f,0x1),_0x95ef6f--);}_0x5b3020(_0x59fa6d[_0x5e80a7]);for(let _0x3c2e1e=0x0;_0x3c2e1e<_0x59fa6d[_0x5e80a7]['markersEnd']['length'];_0x3c2e1e++){const _0x673df4=_0x59fa6d[_0x5e80a7]['markersEnd'][_0x3c2e1e];if(!_0x4ce671['has'](_0x673df4))continue;const {group:_0x54dfad,type:_0xcc455c}=_0x51f33d(_0x673df4);if('revision-suggestion'!=_0x54dfad||'insertion'!=_0xcc455c&&'deletion'!=_0xcc455c)continue;_0x59fa6d[_0x5e80a7]['markersEnd']['splice'](_0x3c2e1e,0x1),_0x3c2e1e--;const _0x3d879c=_0x36ddd3['findIndex'](_0x4371f0=>_0x4371f0['name']==_0x673df4);_0x3d879c>-0x1&&_0x36ddd3['splice'](_0x3d879c,0x1);}}function _0x51f33d(_0x1331a9){const _0x580751=_0x1331a9['split'](':');return{'group':_0x580751[0x0],'type':_0x580751[0x1],'subType':_0x580751['length']>=0x5?_0x580751[0x2]:null,'id':_0x580751['length']<0x5?_0x580751[0x2]:_0x580751[0x3],'authorId':_0x580751['length']<0x5?_0x580751[0x3]:_0x580751[0x4],'markerCount':0x6==_0x580751['length']?_0x580751[0x5]:null};}function _0x5b3020(_0x4a9fe1){for(let _0x20f250=0x0;_0x20f250<_0x36ddd3['length'];_0x20f250++){if(_0x4a9fe1['isAdded']&&'insertion'==_0x36ddd3[_0x20f250]['type'])return _0x4a9fe1['isAddSuggestion']=_0x36ddd3[_0x20f250],void delete _0x4a9fe1['isAdded'];if(!_0x4a9fe1['isAdded']&&!_0x4a9fe1['isRemoved']&&'deletion'==_0x36ddd3[_0x20f250]['type'])return void(_0x4a9fe1['isRemoveSuggestion']=_0x36ddd3[_0x20f250]);}}}['_setDistance'](_0x46a306,_0x5e0ba7){let _0x4c7f46=0x0,_0x548e87=!0x1;const _0x454991=new Map();for(const _0x3a94cf of _0x46a306)_0x3a94cf[_0x5e0ba7]?_0x548e87&&(_0x4c7f46++,_0x548e87=!0x1):(_0x4c7f46++,_0x548e87=!0x0),_0x454991['set'](_0x3a94cf['id'],_0x4c7f46);for(let _0x359fff=0x0;_0x359fff<_0x46a306['length'];_0x359fff++){if('isRemoved'==_0x5e0ba7&&_0x46a306[_0x359fff]['isAdded']||'isAdded'==_0x5e0ba7&&_0x46a306[_0x359fff]['isRemoved'])continue;if('text'==_0x46a306[_0x359fff]['type']){_0x46a306[_0x359fff]['distance']=0x0;continue;}const _0xfb8d2f=_0x454991['get'](_0x46a306[_0x359fff]['pairId']),_0x225868=_0x454991['get'](_0x46a306[_0x359fff]['id']);_0x46a306[_0x359fff]['distance']=_0xfb8d2f-_0x225868;}}['_getRevisionsRange'](_0x32d1bf,_0x14066b,_0x42487f=!0x1){const _0xaed50a=[];let _0x56c950=this['repository']['getIndex'](_0x32d1bf),_0x31983c=this['repository']['getIndex'](_0x14066b);for(-0x1==_0x31983c&&(_0x31983c=this['repository']['_revisions']['length'],_0x42487f=!0x1);_0x56c950<_0x31983c;)_0xaed50a['push'](this['repository']['getRevision'](_0x56c950)),_0x56c950++;return _0x42487f&&_0xaed50a['push'](this['repository']['getRevision'](_0x56c950)),_0xaed50a;}['_threeWayMerge'](_0x48f6c1,_0x5cccb1,_0x5a1201,_0x588032){const _0x1f6ac0=this['editor']['model']['schema'];let _0x41bb78=_0x5cccb1;for(;_0x48f6c1[_0x41bb78]&&_0x48f6c1[_0x41bb78]['isAdded'];)_0x41bb78++;let _0x40afb6=_0x588032;for(;_0x5a1201[_0x40afb6]&&_0x5a1201[_0x40afb6]['isRemoved'];)_0x40afb6++;_0x2772f5(_0x48f6c1,_0x5cccb1,_0x41bb78),_0x2772f5(_0x5a1201,_0x588032,_0x40afb6);const _0x4c899e=_0x5a1201['slice'](_0x588032,_0x40afb6)['concat'](_0x48f6c1['slice'](_0x5cccb1,_0x41bb78));return _0x4c899e['sort']((_0x28faf3,_0x424c77)=>_0x28faf3['side']!=_0x424c77['side']?_0x28faf3['side']-_0x424c77['side']:_0x28faf3['level']!=_0x424c77['level']?_0x28faf3['level']-_0x424c77['level']:_0x28faf3['distance']!=_0x424c77['distance']?_0x424c77['distance']-_0x28faf3['distance']:!!_0x28faf3['isAdded']!=!!_0x424c77['isAdded']?-0x1==_0x28faf3['side']||0x0==_0x28faf3['side']?_0x28faf3['isAdded']?-0x1:0x1:_0x28faf3['isAdded']?0x1:-0x1:_0x28faf3['index']-_0x424c77['index']),{'commonTape':_0x4c899e,'iEnd':_0x41bb78,'jEnd':_0x40afb6};function _0x2772f5(_0xc4f410,_0x1fb695,_0x3b9455){let _0x2ca12a=-0x1,_0x35b892=Number['POSITIVE_INFINITY'],_0x1eead3=!0x0;for(let _0x325268=_0x1fb695;_0x325268<_0x3b9455;_0x325268++)if(_0x1f6ac0['isInline'](_0xc4f410[_0x325268]['item'])||(_0x1eead3=!0x1),_0xc4f410[_0x325268]['item']['startIndex']<_0x1fb695&&(_0x2ca12a=_0x325268),_0xc4f410[_0x325268]['item']['endIndex']>=_0x3b9455){_0x35b892=_0x325268;break;}_0x1eead3&&(_0x2ca12a=_0x3b9455-0x1);for(let _0x133aa3=_0x1fb695;_0x133aa3<_0x3b9455;_0x133aa3++)_0xc4f410[_0x133aa3]['side']=_0x133aa3<=_0x2ca12a?-0x1:_0x133aa3<_0x35b892?0x0:0x1,_0xc4f410[_0x133aa3]['index']=_0x133aa3;let _0x11cad6=0x0;for(let _0x36eea9=_0x1fb695;_0x36eea9<=_0x2ca12a;_0x36eea9++)0x0==_0xc4f410[_0x36eea9]['distance']?_0xc4f410[_0x36eea9]['level']=_0x11cad6:(_0x11cad6++,_0xc4f410[_0x36eea9]['level']=_0x11cad6,_0x11cad6++);for(let _0xacb9fe=_0x1fb695;_0xacb9fe<_0x3b9455;_0xacb9fe++)0x0==_0xc4f410[_0xacb9fe]['side']&&(_0xc4f410[_0xacb9fe]['level']=_0x11cad6);_0x11cad6=0x0;for(let _0x1487eb=_0x3b9455-0x1;_0x1487eb>=_0x35b892;_0x1487eb--)0x0==_0xc4f410[_0x1487eb]['distance']?_0xc4f410[_0x1487eb]['level']=_0x11cad6:(_0x11cad6--,_0xc4f410[_0x1487eb]['level']=_0x11cad6,_0x11cad6--);}}['_fixObsoleteTags'](_0x36b2c7){const _0x4f328d=new Map(),_0x322d4d=this['editor']['model']['schema'];for(let _0x21d15d=0x1;_0x21d15d<_0x36b2c7['length'];_0x21d15d++){let _0x161fe4,_0x4ff021,_0x2f8e14;const _0x114372=_0x36b2c7[_0x21d15d],_0xe3d997=_0x36b2c7[_0x21d15d-0x1];if('text'==_0x114372['type'])continue;if(_0x114372['type']!=_0xe3d997['type'])continue;if(!_0x322d4d['isBlock'](_0xe3d997['item'])||_0x322d4d['isLimit'](_0xe3d997['item']))continue;if(!_0x322d4d['isBlock'](_0x114372['item'])||_0x322d4d['isLimit'](_0x114372['item']))continue;if((_0x36b2c7[_0x21d15d]['isAdded']||_0x36b2c7[_0x21d15d]['isAddSuggestion'])&&_0x36b2c7[_0x21d15d-0x1]['isRemoved'])_0x161fe4=_0x36b2c7[_0x21d15d],_0x4ff021=_0x36b2c7[_0x21d15d-0x1],_0x2f8e14=_0x21d15d-0x1;else{if(!_0x36b2c7[_0x21d15d]['isRemoved']||!_0x36b2c7[_0x21d15d-0x1]['isAdded']&&!_0x36b2c7[_0x21d15d-0x1]['isAddSuggestion'])continue;_0x161fe4=_0x36b2c7[_0x21d15d-0x1],_0x4ff021=_0x36b2c7[_0x21d15d],_0x2f8e14=_0x21d15d;}const _0x53c82e=_0x161fe4['level']==_0x4ff021['level'],_0x5bf3d4=Math['abs'](_0x161fe4['level'])<Math['abs'](_0x4ff021['level'])&&0x0==_0x4ff021['distance'];(_0x53c82e||_0x5bf3d4)&&(_0x4f328d['set'](_0x4ff021['id'],_0x161fe4['id']),_0x36b2c7['splice'](_0x2f8e14,0x1),_0x21d15d--,_0x161fe4['isAdded']=!0x1);}for(let _0x472093=0x0;_0x472093<_0x36b2c7['length'];_0x472093++)_0x4f328d['has'](_0x36b2c7[_0x472093]['pairId'])&&(_0x36b2c7[_0x472093]['pairId']=_0x4f328d['get'](_0x36b2c7[_0x472093]['pairId']));}['_removeMissingPairs'](_0x2c9dfc){const _0x1299df=new Set(_0x2c9dfc['map'](_0x97f6a8=>_0x97f6a8['id']));for(let _0x4e945a=0x0;_0x4e945a<_0x2c9dfc['length'];_0x4e945a++)_0x1299df['has'](_0x2c9dfc[_0x4e945a]['pairId'])||0x0==_0x2c9dfc[_0x4e945a]['distance']||(_0x2c9dfc[_0x4e945a]['isIncorrect']=!0x0);return _0x2c9dfc['filter'](_0x37f39b=>!_0x37f39b['isIncorrect']);}['_markMismatchedRemovedTags'](_0x4fab4a){const _0x11a5b1=new Set();for(let _0x56bb1a=0x0;_0x56bb1a<_0x4fab4a['length'];_0x56bb1a++){if(_0x11a5b1['has'](_0x4fab4a[_0x56bb1a]['id'])&&_0x4fab4a[_0x56bb1a]['isRemoved']&&(_0x4fab4a[_0x56bb1a]['isIncorrect']=!0x0),_0x4fab4a[_0x56bb1a]['isIncorrect'])continue;if(0x0==_0x4fab4a[_0x56bb1a]['distance'])continue;if('elementStart'!=_0x4fab4a[_0x56bb1a]['type'])continue;if(null==_0x4fab4a[_0x56bb1a]['pairId'])continue;let _0x57be9a=_0x56bb1a+0x1,_0x5b5956=0x0;for(;_0x4fab4a[_0x57be9a]['id']!=_0x4fab4a[_0x56bb1a]['pairId'];)'elementStart'==_0x4fab4a[_0x57be9a]['type']?_0x5b5956++:'elementEnd'==_0x4fab4a[_0x57be9a]['type']&&_0x5b5956--,_0x57be9a++;if(0x0!=_0x5b5956){if(_0x4fab4a[_0x56bb1a]['isRemoved'])_0x4fab4a[_0x56bb1a]['isIncorrect']=!0x0;else{for(;_0x57be9a!=_0x56bb1a;)_0x4fab4a[_0x57be9a]['isRemoved']&&0x0!=_0x4fab4a[_0x57be9a]['distance']&&(_0x4fab4a[_0x57be9a]['isIncorrect']=!0x0,_0x11a5b1['add'](_0x4fab4a[_0x57be9a]['pairId'])),_0x57be9a--;}}}return _0x4fab4a['filter'](_0x15a239=>!_0x15a239['isIncorrect']);}['_removeUnsupportedChanges'](_0x1ca716){const _0x3e2681=this['editor']['model']['schema'];for(let _0x474efc=0x0;_0x474efc<_0x1ca716['length'];_0x474efc++){if(!(_0x1ca716[_0x474efc]['isAdded']||_0x1ca716[_0x474efc]['isAddSuggestion']||_0x1ca716[_0x474efc]['isRemoved']||_0x1ca716[_0x474efc]['isRemoveSuggestion']))continue;if(0x0==_0x1ca716[_0x474efc]['distance'])continue;const _0x15ffbf=_0x1ca716[_0x474efc]['item'];_0x3e2681['isBlock'](_0x15ffbf)||_0x3e2681['isLimit'](_0x15ffbf)||(_0x1ca716[_0x474efc]['isAdded']&&delete _0x1ca716[_0x474efc]['isAdded'],_0x1ca716[_0x474efc]['isAddSuggestion']&&delete _0x1ca716[_0x474efc]['isAddSuggestion'],_0x1ca716[_0x474efc]['isRemoveSuggestion']&&delete _0x1ca716[_0x474efc]['isRemoveSuggestion'],_0x1ca716[_0x474efc]['isRemoved']&&(_0x1ca716[_0x474efc]['isIncorrect']=!0x0));}return _0x1ca716['filter'](_0x436c79=>!_0x436c79['isIncorrect']);}['_makeModelFromTape'](_0x2ab272,_0x962d68,_0x20ed10){const _0x282e78=new mt(),_0x4aea5a=[],_0x586dc4=new Map(),_0x5f0d02=this['editor']['model'],_0x28643b=_0x5f0d02['schema'],_0x207e99=[_0x282e78],_0x32b23e={},_0x176c26={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x2dec69=null;const _0x160934=[0x0];for(let _0x49fd89=0x0;_0x49fd89<_0x2ab272['length'];_0x49fd89++)if('elementStart'===_0x2ab272[_0x49fd89]['type']){_0x2ab272[_0x49fd89]['previousPosition']=_0x5f0d02['createPositionFromPath'](_0x282e78,_0x160934);const _0x100683=new ft(_0x2ab272[_0x49fd89]['item']['name'],_0x2ab272[_0x49fd89]['item']['getAttributes']());_0x207e99[0x0]['_appendChild'](_0x100683),_0x160934['push'](0x0),_0x207e99['unshift'](_0x100683),_0x2ab272[_0x49fd89]['nextPosition']=_0x5f0d02['createPositionFromPath'](_0x282e78,_0x160934);}else'elementEnd'===_0x2ab272[_0x49fd89]['type']?(_0x207e99['shift'](),_0x2ab272[_0x49fd89]['previousPosition']=_0x5f0d02['createPositionFromPath'](_0x282e78,_0x160934),_0x160934['pop'](),_0x160934[_0x160934['length']-0x1]++,_0x2ab272[_0x49fd89]['nextPosition']=_0x5f0d02['createPositionFromPath'](_0x282e78,_0x160934)):(_0x2ab272[_0x49fd89]['previousPosition']=_0x5f0d02['createPositionFromPath'](_0x282e78,_0x160934),_0x2dec69?_0x2dec69['_data']+=_0x2ab272[_0x49fd89]['item']['data']:_0x2dec69=new wt(_0x2ab272[_0x49fd89]['item']['data'],_0x2ab272[_0x49fd89]['item']['getAttributes']()),_0x2ab272[_0x49fd89+0x1]&&'text'===_0x2ab272[_0x49fd89+0x1]['type']&&_0x271ec2(_0x2dec69,_0x2ab272[_0x49fd89+0x1]['item'])||(_0x207e99[0x0]['_appendChild'](_0x2dec69),_0x2dec69=null),_0x160934[_0x160934['length']-0x1]+=_0x2ab272[_0x49fd89]['item']['offsetSize'],_0x2ab272[_0x49fd89]['nextPosition']=_0x5f0d02['createPositionFromPath'](_0x282e78,_0x160934));for(let _0x28746e=0x0;_0x28746e<_0x2ab272['length'];_0x28746e++){const _0xc1d4fc=_0x2ab272[_0x28746e]['previousPosition'],_0x58313e=_0x2ab272[_0x28746e]['nextPosition'];for(const _0x47ab96 of _0x2ab272[_0x28746e]['markersStart'])_0x586dc4['set'](_0x47ab96,{'start':_0xc1d4fc,'end':null});_0x5a6f03('isRemoveSuggestion',_0x28746e,_0xc1d4fc,_0x58313e),_0x5a6f03('isAddSuggestion',_0x28746e,_0xc1d4fc,_0x58313e),_0x5a6f03('isRemoved',_0x28746e,_0xc1d4fc,_0x58313e),_0x5a6f03('isAdded',_0x28746e,_0xc1d4fc,_0x58313e);for(const _0x52b7c2 of _0x2ab272[_0x28746e]['markersEnd']){_0x586dc4['get'](_0x52b7c2)['end']=_0x58313e;}}for(const [_0x35f370,_0x2bb36d]of _0x586dc4){const _0x215f62=this['editor']['model']['createRange'](_0x2bb36d['start'],_0x2bb36d['end']);_0x282e78['markers']['set'](_0x35f370,_0x215f62);}return _0x4aea5a['sort']((_0x468b6b,_0x1143c3)=>{const _0x283e42=_0x282e78['markers']['get']('revision:'+_0x468b6b['id']),_0x535645=_0x282e78['markers']['get']('revision:'+_0x1143c3['id']);return _0x283e42['start']['isBefore'](_0x535645['start'])?-0x1:_0x283e42['start']['isAfter'](_0x535645['start'])?0x1:_0x283e42['end']['isBefore'](_0x535645['end'])?-0x1:_0x283e42['end']['isAfter'](_0x535645['end'])?0x1:'add'===_0x468b6b['type']?-0x1:0x1;}),{'root':_0x282e78,'changes':_0x4aea5a};function _0x5a6f03(_0xf7e626,_0x3150ac,_0x237711,_0x3cfd3b){const _0xbeae4d=!!_0x2ab272[_0x3150ac][_0xf7e626],_0x3ff158=_0xbeae4d?_0x2ab272[_0x3150ac][_0xf7e626]['userId']:null,_0x1c8458=_0x3150ac===_0x2ab272['length']-0x1,_0x387d9c=_0x176c26[_0xf7e626][0x0],_0x1185ce=_0x28643b['isObject'](_0x2ab272[_0x3150ac]['item']);!_0x32b23e[_0xf7e626]&&_0xbeae4d?_0x32b23e[_0xf7e626]={'start':_0x237711,'tapeItem':_0x2ab272[_0x3150ac],'userId':_0x3ff158,'type':_0xf7e626}:_0x32b23e[_0xf7e626]&&!_0xbeae4d?(_0x32b23e[_0xf7e626]['end']=_0x237711,_0x328e20(_0x32b23e[_0xf7e626]),_0x32b23e[_0xf7e626]=null):_0x32b23e[_0xf7e626]&&_0xbeae4d&&_0x32b23e[_0xf7e626]['userId']!==_0x3ff158&&(_0x32b23e[_0xf7e626]['end']=_0x237711,_0x387d9c&&_0x387d9c['userId']===_0x32b23e[_0xf7e626]['userId']||_0x328e20(_0x32b23e[_0xf7e626]),_0x32b23e[_0xf7e626]={'start':_0x237711,'tapeItem':_0x2ab272[_0x3150ac],'userId':_0x3ff158,'type':_0xf7e626}),_0x32b23e[_0xf7e626]&&_0x1185ce&&('elementStart'!==_0x2ab272[_0x3150ac]['type']||_0x387d9c&&_0x387d9c['userId']===_0x3ff158||_0x176c26[_0xf7e626]['unshift']({'userId':_0x3ff158,'object':_0x2ab272[_0x3150ac]['item'],'change':_0x32b23e[_0xf7e626]}),'elementEnd'===_0x2ab272[_0x3150ac]['type']&&_0x387d9c&&_0x387d9c['object']===_0x2ab272[_0x3150ac]['item']&&(_0x176c26[_0xf7e626]['shift'](),_0x32b23e[_0xf7e626]=_0x387d9c['change'])),_0x32b23e[_0xf7e626]&&_0x1c8458&&(_0x32b23e[_0xf7e626]['end']=_0x3cfd3b,_0x328e20(_0x32b23e[_0xf7e626]),_0x32b23e[_0xf7e626]=null);}function _0x328e20({start:_0x1a8ae2,end:_0x43aff6,tapeItem:_0xe9ee36,userId:_0x11c41a,type:_0x2b09f7}){const _0x3088e6=_0xe9ee36['item'],_0x41379a=_0x5f0d02['schema']['isBlock'](_0x3088e6)&&!_0x5f0d02['schema']['isLimit'](_0x3088e6),_0xaeb3f9=_0x1a8ae2['nodeAfter']==_0x43aff6['parent']&&_0x43aff6['isAtStart'];if(_0x41379a&&_0xaeb3f9)return;const _0x3d10d9=_0x5f0d02['createRange'](_0x1a8ae2,_0x43aff6),_0x5e6745=_0x962d68['get'](_0x11c41a),_0x18ca51=new r({'author':_0x5e6745,'type':'isAdded'==_0x2b09f7||'isAddSuggestion'==_0x2b09f7?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x2b09f7||'isRemoveSuggestion'==_0x2b09f7},'createdAt':new Date(),'rootName':_0x20ed10});_0x4aea5a['push'](_0x18ca51),_0x282e78['markers']['set']('revision:'+_0x18ca51['id'],_0x3d10d9);}function _0x271ec2(_0x575a04,_0x4c3185){const _0x1709a5=_0x575a04['getAttributes'](),_0x398d80=_0x4c3185['getAttributes']();for(const _0x2d82e5 of _0x1709a5){if(_0x2d82e5[0x1]!==_0x4c3185['getAttribute'](_0x2d82e5[0x0]))return!0x1;_0x398d80['next']();}return _0x398d80['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x40fc9a=>{const _0x11212e=_0x40fc9a['markerName']['split'](':')[0x1],_0x2c9106=this['_getChangeFromId'](_0x11212e);if(!_0x2c9106)return null;const _0x46d6e0='add'==_0x2c9106['type']?'insertion':'deletion',_0x5f9d67=['ck-suggestion-marker','ck-suggestion-marker-'+_0x46d6e0];return _0x2c9106['data']['isSuggestion']&&_0x5f9d67['push']('ck-suggestion-marker-'+_0x46d6e0+'-new'),this['activeChange']==_0x2c9106&&_0x5f9d67['push']('ck-suggestion-marker--active'),{'classes':_0x5f9d67,'attributes':{'data-change-id':_0x11212e}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x2acab9=>{_0x2acab9['on']('element:pre',(_0x1fbaa2,_0x16e75a,_0x4c5e66)=>{const _0x4952dd=_0x16e75a['viewItem']['getChild'](0x0);if(!_0x4952dd||!_0x4952dd['is']('element','code'))return;if(!_0x4c5e66['consumable']['consume'](_0x4952dd,{'attributes':['vid_start','vid_end']}))return;const _0x386287=_0x16e75a['modelRange']['start']['nodeAfter'];_0x4c5e66['writer']['setAttribute']('vid_start',_0x4952dd['getAttribute']('vid_start'),_0x386287),_0x4c5e66['writer']['setAttribute']('vid_end',_0x4952dd['getAttribute']('vid_end'),_0x386287);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x170da7=>{_0x170da7['on']('element',(_0x57127b,_0x5a69a1,_0x1b0d6a)=>{if(!_0x1b0d6a['consumable']['consume'](_0x5a69a1['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x5a69a1['modelRange']['isCollapsed'])return;const _0x5855cc=_0x5a69a1['modelRange']['start']['nodeAfter'];_0x5855cc['hasAttribute']('vid_start')||_0x5855cc['hasAttribute']('vid')||(_0x1b0d6a['writer']['setAttribute']('vid_start',_0x5a69a1['viewItem']['getAttribute']('vid_start'),_0x5855cc),_0x1b0d6a['writer']['setAttribute']('vid_end',_0x5a69a1['viewItem']['getAttribute']('vid_end'),_0x5855cc));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x3888b7=>_0x3888b7['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0xd64ce4,[,_0x12477c])=>{['vid_start','vid_end','vid']['includes'](_0x12477c)&&(_0xd64ce4['return']=!0x0,_0xd64ce4['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x38b3a9=>{_0x38b3a9['on']('attribute:vid',(_0x5d8030,_0x5798fe,_0x2ed09b)=>{if('\x20'!=_0x5798fe['item']['data']||_0x5798fe['item']['parent']['maxOffset']>0x1)return;if(!_0x2ed09b['consumable']['consume'](_0x5798fe['item'],_0x5d8030['name']))return;const _0x5cb015=_0x2ed09b['writer'],_0x6c6140=_0x2ed09b['mapper']['toViewRange'](_0x5798fe['range']);_0x5cb015['wrap'](_0x6c6140,_0x5cb015['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0xa73ddd){const _0x40f3c=_0xa73ddd['plugins']['get']('RevisionViewer');return(_0x6dfc04,_0x3302e6,_0x55a48a)=>{const _0x4df488=_0x3302e6['markerName']['split'](':')[0x1],_0x4cf73b=_0x40f3c['_getChangeFromId'](_0x4df488);if(!_0x4cf73b)return null;const _0x107b44='add'==_0x4cf73b['type']?'split':'merge';if(!_0x55a48a['consumable']['test'](_0x3302e6['markerRange'],_0x6dfc04['name']))return;const _0x33ff95=_0x3302e6['markerRange']['getWalker'](),_0x2540c2=_0x3302e6['markerRange']['start'],_0x1291dd=_0xa73ddd['model']['schema'];let _0x3d8532=null,_0x2af5c2=null,_0x268415=!0x1,_0xff92ac=!0x1;for(const _0x2e13f5 of _0x33ff95){const _0x4ba49c=_0x2e13f5['item'];_0x268415=_0x268415||_0x1291dd['isContent'](_0x4ba49c);const _0x1392fe=_0x55a48a['mapper']['toViewElement'](_0x4ba49c);if(_0x1392fe&&_0x1392fe['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x2e13f5['type']&&(_0x1291dd['isBlock'](_0x4ba49c)&&!_0x1291dd['isLimit'](_0x4ba49c)&&(_0x4ba49c['nextSibling']||_0x2540c2['isAtEnd']?_0x3d8532&&_0x3d8532['parent']==_0x4ba49c||(_0x3d8532=_0x4ba49c,_0x2e1e4d(_0x2e13f5['previousPosition']),_0xff92ac=!0x0):_0x2af5c2=_0x2af5c2||_0x2e13f5['previousPosition']));}function _0x2e1e4d(_0x21580c){const _0x7d4e2d=_0x55a48a['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x107b44}),_0x107ad1=_0x55a48a['mapper']['toViewPosition'](_0x21580c);_0x4cf73b['data']['isSuggestion']&&_0x55a48a['writer']['addClass']('ck-suggestion-marker-'+_0x107b44+'-new',_0x7d4e2d),_0x40f3c['activeChange']==_0x4cf73b&&_0x55a48a['writer']['addClass']('ck-suggestion-marker--active',_0x7d4e2d),_0x55a48a['writer']['insert'](_0x107ad1,_0x7d4e2d),_0x55a48a['mapper']['bindElementToMarker'](_0x7d4e2d,_0x3302e6['markerName']);}_0x268415||_0xff92ac||!_0x2af5c2||_0x2e1e4d(_0x2af5c2);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x22f081,_0x109b1d,_0x21fdd0)=>{const _0x1de7ed=_0x21fdd0['mapper']['markerNameToElements'](_0x109b1d['markerName']);if(_0x1de7ed){for(const _0x279138 of _0x1de7ed)(_0x279138['hasClass']('ck-suggestion-marker-split')||_0x279138['hasClass']('ck-suggestion-marker-merge'))&&(_0x21fdd0['mapper']['unbindElementFromMarkerName'](_0x279138,_0x109b1d['markerName']),_0x21fdd0['writer']['remove'](_0x279138));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x23c78b,_0x5435d7,_0xee2a84)=>{const _0x16f869=_0x5435d7['markerName']['split'](':')[0x1],_0x1354e7=this['_getChangeFromId'](_0x16f869);if(!_0x1354e7)return null;const _0x25257e='add'==_0x1354e7['type']?'split':'merge';if(_0xee2a84['consumable']['test'](_0x5435d7['markerRange'],_0x23c78b['name']))for(const _0x210ece of _0x5435d7['markerRange']['getItems']()){if(!_0x210ece['is']('element','softBreak'))continue;const _0x4c3576=_0xee2a84['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x25257e}),_0x1d0319=_0xee2a84['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x210ece));_0x1354e7['data']['isSuggestion']&&_0xee2a84['writer']['addClass']('ck-suggestion-marker-'+_0x25257e+'-new',_0x4c3576),this['activeChange']==_0x1354e7&&_0xee2a84['writer']['addClass']('ck-suggestion-marker--active',_0x4c3576),_0xee2a84['writer']['insert'](_0x1d0319,_0x4c3576),_0xee2a84['mapper']['bindElementToMarker'](_0x4c3576,_0x5435d7['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x57552c=>{for(const _0x256ede of this['editor']['model']['document']['getRootNames']()){const _0x212b8d=this['editor']['model']['document']['getRoot'](_0x256ede),_0x11f15f=this['editor']['editing']['view']['document']['getRoot'](_0x256ede);if(_0x11f15f){const _0x47edaf=_0x212b8d['getAttribute']('revisionHistoryAttachChange');if(_0x57552c['removeAttribute']('data-change-id',_0x11f15f),_0x57552c['removeClass']('ck-revision-history-root-add',_0x11f15f),_0x57552c['removeClass']('ck-revision-history-root-remove',_0x11f15f),_0x57552c['removeClass']('ck-revision-history-root--active',_0x11f15f),_0x47edaf){const _0x587af2=this['_getChangeFromId'](_0x47edaf);if(!_0x587af2)return null;_0x57552c['setAttribute']('data-change-id',_0x47edaf,_0x11f15f),_0x57552c['addClass']('ck-revision-history-root-'+_0x587af2['type'],_0x11f15f),this['activeChange']==_0x587af2&&_0x57552c['addClass']('ck-revision-history-root--active',_0x11f15f);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x419e26=>'revision-comment:'+_0x419e26,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x18cd2d=>'revision-suggestion:'+_0x18cd2d,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x56eff5=>({'name':'suggestion:'+_0x56eff5,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x27c12d=>{const _0x4d516f=_0x27c12d['markerName']['split'](':')[0x1];return'insertion'!=_0x4d516f&&'deletion'!=_0x4d516f?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x4d516f]};}}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:deletion',Z(this['editor'],'merge'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:insertion',Z(this['editor'],'split'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision-suggestion',(_0x143712,_0x5360b1,_0x59700c)=>{const _0x23e0cd=_0x59700c['mapper']['markerNameToElements'](_0x5360b1['markerName']);if(_0x23e0cd){for(const _0x435e1b of _0x23e0cd)_0x435e1b['is']('uiElement')&&(_0x59700c['mapper']['unbindElementFromMarkerName'](_0x435e1b,_0x5360b1['markerName']),_0x59700c['writer']['remove'](_0x435e1b));}},{'priority':'high'});}['_getChangeFromId'](_0x2a18bb){return this['_changeIdToChange']['get'](_0x2a18bb);}['_getViewForChange'](_0x5a0fc7){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new X(this['editor']['locale'],_0x5a0fc7),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x3fbaf3,_0x290aff,_0x455950,_0x28c870)=>{_0x28c870&&this['_balloon']['remove'](_0x28c870),_0x455950&&(this['_balloon']['add']({'view':_0x455950,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0xa96ce4=this['editor']['editing'],_0x65226d=this['_getChangeFromId'](_0x455950['changeId']);let _0x3d450c;if(_0x65226d['data']['isOnRoot']){const _0x57590=_0xa96ce4['view']['getDomRoot'](_0x65226d['rootName']);_0x3d450c=Array['from'](_0x57590['getClientRects']());}else{const _0x6475c=this['editor']['model']['markers']['get']('revision:'+_0x455950['changeId']);_0x3d450c=Array['from'](_0xa96ce4['mapper']['markerNameToElements'](_0x6475c['name']))['map'](_0x577603=>_0xa96ce4['view']['domConverter']['mapViewToDom'](_0x577603))['map'](_0x5686fa=>Array['from'](_0x5686fa['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x3d450c[0x0];return _0x3d450c['find'](_0x3c241b=>_0x3c241b['top']-0x3<=this['_activeViewTarget']['y']&&_0x3c241b['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x3c241b['left']-0x3<=this['_activeViewTarget']['x']&&_0x3c241b['right']+0x3>=this['_activeViewTarget']['x'])||_0x3d450c[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0xffd11e,_0x4edb4f,_0x270295,_0x457e74)=>{this['activeView']=_0x270295?this['_getViewForChange'](_0x270295):null,this['editor']['model']['change'](()=>{const _0x864a0b=this['editor']['editing'];_0x457e74&&(_0x457e74['data']['isOnRoot']?_0x864a0b['view']['change'](_0x1d1d59=>{_0x1d1d59['removeClass']('ck-revision-history-root--active',_0x864a0b['view']['document']['getRoot'](_0x457e74['rootName']));}):_0x864a0b['reconvertMarker']('revision:'+_0x457e74['id'])),_0x270295&&(_0x270295['data']['isOnRoot']?_0x864a0b['view']['change'](_0x53f6bd=>{_0x53f6bd['addClass']('ck-revision-history-root--active',_0x864a0b['view']['document']['getRoot'](_0x270295['rootName']));}):_0x864a0b['reconvertMarker']('revision:'+_0x270295['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x30ed27,_0x19e172)=>{if(this['activeChange'])return;const _0x47d5e9=this['_findChangeIdFromDomTarget'](_0x19e172['target']),_0x21b973=this['_changeIdToChange']['get'](_0x47d5e9);_0x21b973?(this['_activeViewTarget']={'x':_0x19e172['domEvent']['x'],'y':_0x19e172['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x21b973)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x1d5d19,_0x77a48d)=>{const _0x14100f=this['_findChangeIdFromDomTarget'](_0x77a48d['target']),_0x1f684b=this['_changeIdToChange']['get'](_0x14100f);_0x1f684b?(this['_activeViewTarget']={'x':_0x77a48d['domEvent']['x'],'y':_0x77a48d['domEvent']['y']},_0x1f684b===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x1f684b):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x221cdd){do{const _0x594519=_0x221cdd['getAttribute']('data-change-id');if(_0x594519)return _0x594519;_0x221cdd=_0x221cdd['parent'];}while(_0x221cdd);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x58381a=>{for(const _0x5353b7 of this['editor']['model']['markers'])_0x58381a['removeMarker'](_0x5353b7);});}}function Z(_0x4784d6,_0x9905d6){return(_0x175189,_0xdd18bc,_0x264dc8)=>{if(!_0x264dc8['consumable']['test'](_0xdd18bc['markerRange'],_0x175189['name']))return;const _0xf41b1e=_0xdd18bc['markerRange']['getWalker'](),_0x26778d=_0xdd18bc['markerRange']['start'],_0x1c6e9f=_0x4784d6['model']['schema'];let _0x55c5eb=null,_0x42ae8d=null,_0x53d2fa=!0x1,_0x34b48a=!0x1;for(const _0x2b6bf0 of _0xf41b1e){const _0x14d3a5=_0x2b6bf0['item'];_0x53d2fa=_0x53d2fa||_0x1c6e9f['isContent'](_0x14d3a5);const _0x421371=_0x264dc8['mapper']['toViewElement'](_0x14d3a5);if(_0x421371&&_0x421371['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x2b6bf0['type']&&(_0x1c6e9f['isBlock'](_0x14d3a5)&&!_0x1c6e9f['isLimit'](_0x14d3a5)&&(_0x14d3a5['nextSibling']||_0x26778d['isAtEnd']?_0x55c5eb&&_0x55c5eb['parent']==_0x14d3a5||(_0x55c5eb=_0x14d3a5,_0x52b7f5(_0x2b6bf0['previousPosition']),_0x34b48a=!0x0):_0x42ae8d=_0x42ae8d||_0x2b6bf0['previousPosition']));}function _0x52b7f5(_0x48c815){const _0x3007e0=_0x264dc8['mapper']['toViewPosition'](_0x48c815),_0x420e3d=_0x264dc8['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x9905d6});_0x264dc8['writer']['insert'](_0x3007e0,_0x420e3d),_0x264dc8['mapper']['bindElementToMarker'](_0x420e3d,_0xdd18bc['markerName']);}_0x53d2fa||_0x34b48a||!_0x42ae8d||_0x52b7f5(_0x42ae8d);};}class _t extends _0x5a0586{constructor(_0x46b092){super(_0x46b092);const _0x4deb59=_0x46b092['plugins']['get'](d);this['affectsData']=!0x1,this['listenTo'](_0x4deb59,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x4deb59,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x40ddbf=this['editor'],_0x1e9757=_0x40ddbf['plugins']['get'](d),_0x4c24c7=_0x1e9757['isReady']?_0x1e9757['diff']['newRevisionId']:null;_0x40ddbf['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x4c24c7);}['refresh'](){const {isReady:_0x2bc844,isEnabled:_0x19bed6,repository:_0x107585,diff:_0x29a0b8}=this['editor']['plugins']['get'](d),_0x294a01=_0x29a0b8&&_0x107585['getLaterVisibleRevision'](_0x29a0b8['newRevisionId']);this['isEnabled']=_0x2bc844&&_0x19bed6&&Boolean(_0x294a01);}}class yt extends _0x5a0586{['_step'];constructor(_0x24ce61,{direction:_0x36e1c9}){super(_0x24ce61);const _0x9508be=_0x24ce61['plugins']['get'](d);this['affectsData']=!0x1,this['_step']='forward'===_0x36e1c9?0x1:-0x1,this['listenTo'](_0x9508be,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x9508be,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x9508be,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x2c070c=this['editor'],_0x3cd4f5=_0x2c070c['plugins']['get'](d),{isNavigationMode:_0x31bd63,currentChangeNumber:_0x32bff1}=_0x3cd4f5;let _0xe7b9db;if(_0x3cd4f5['activeChange']=_0x31bd63?_0x3cd4f5['diff']['changes']['get'](_0x32bff1+this['_step']):_0x3cd4f5['diff']['changes']['first'],_0x3cd4f5['activeChange']['data']['isOnRoot'])_0xe7b9db=_0x2c070c['editing']['view']['getDomRoot'](_0x3cd4f5['activeChange']['rootName']);else{const _0x52c165=_0x2c070c['model']['markers']['get']('revision:'+_0x3cd4f5['activeChange']['id']);_0xe7b9db=_0x51bacb(_0x2c070c['editing'],_0x52c165);}_0x30ca02({'target':_0xe7b9db,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x261c08,currentChangeNumber:_0x4b4a6c,numberOfChanges:_0x491d31,isReady:_0x58bb55,isEnabled:_0x384a2c}=this['editor']['plugins']['get'](d);this['isEnabled']=!!(_0x384a2c&&_0x58bb55&&_0x491d31)&&(!_0x261c08||(0x1===this['_step']?_0x4b4a6c<_0x491d31-0x1:_0x4b4a6c>0x0));}}class di extends _0x4a3822{constructor(_0x3e65f6){super(_0x3e65f6);const _0x379aaf=this['bindTemplate'],_0x4e7bbc=new _0x20da59(_0x3e65f6),_0x596863=new _0x20da59(_0x3e65f6);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',(_0x3d5e58,_0x1fcdd2)=>_0x3d5e58&&_0x1fcdd2>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x554d5f,_0x5dca42,_0x57c40d,_0x596e1f)=>{if(!_0x554d5f)return m(_0x3e65f6,'Loading...');if(!_0x57c40d)return m(_0x3e65f6,'No\x20changes');const _0x4df0b0=m(_0x3e65f6,'NUMBER_OF_CHANGES',_0x57c40d);return _0x596e1f?m(_0x3e65f6,'X_OF_Y_CHANGES',[_0x5dca42+0x1,_0x57c40d]):_0x4df0b0;}),_0x4e7bbc['set']({'label':m(_0x3e65f6,'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'}),_0x596863['set']({'label':m(_0x3e65f6,'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'}),_0x4e7bbc['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x596863['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x4e7bbc['on']('execute',()=>this['fire']('execute','backward')),_0x596863['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',_0x379aaf['if']('_isStatusLabelVisible','ck-hidden',_0x2fc237=>!_0x2fc237)]},'children':[{'text':_0x379aaf['to']('isNavigationMode',_0x49096e=>_0x49096e?m(_0x3e65f6,'EDIT_X_OF_Y_REVISIONS')+':\x20':m(_0x3e65f6,'Total')+':\x20')}]},{'text':_0x379aaf['to']('_statusText')}]},new _0x5cb790(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x4e7bbc,_0x596863]}]});}}const ce='ck-editor__editable__loading-overlay';class ae extends _0x32454b{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x285d13=this['editor']['editing']['view'];_0x285d13['change'](_0xd445e0=>{for(const _0x48ba5e of _0x285d13['document']['roots'])_0xd445e0['addClass'](ce,_0x48ba5e);});}['hide'](){const _0x6068b7=this['editor']['editing']['view'];_0x6068b7['change'](_0x320135=>{for(const _0x3454bc of _0x6068b7['document']['roots'])_0x320135['removeClass'](ce,_0x3454bc);});}}class g extends _0x32454b{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[d,ae];}['init'](){const _0x18d8f0=this['editor'],_0x5b1891=_0x18d8f0['plugins']['get'](d),_0xba9379=_0x18d8f0['plugins']['get'](ae);_0x18d8f0['ui']['componentFactory']['add']('exitToEditing',_0x3d114e=>{const _0x39c940=new _0x20da59(_0x3d114e);return _0x39c940['set']({'label':m(_0x3d114e,'Back\x20to\x20editing'),'icon':_0x15f173['undo'],'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x39c940,'execute',()=>{_0x18d8f0['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x39c940;}),_0x18d8f0['ui']['componentFactory']['add']('restoreRevision',_0x538de6=>{const _0x4bdc0d=new _0x20da59(_0x538de6);return _0x4bdc0d['set']({'label':m(_0x538de6,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x4bdc0d['bind']('isEnabled')['to'](_0x18d8f0['commands']['get']('restoreRevision')),this['listenTo'](_0x4bdc0d,'execute',()=>_0x18d8f0['execute']('restoreRevision')),_0x4bdc0d;}),_0x18d8f0['ui']['componentFactory']['add']('changesNavigation',_0x2d1c77=>{const _0x32e438=new di(_0x2d1c77),_0x300ee2=_0x18d8f0['commands']['get']('showPreviousChange'),_0x5ba008=_0x18d8f0['commands']['get']('showNextChange');return _0x32e438['bind']('isBackwardNavigationEnabled')['to'](_0x300ee2,'isEnabled'),_0x32e438['bind']('isForwardNavigationEnabled')['to'](_0x5ba008,'isEnabled'),_0x32e438['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x5b1891),this['listenTo'](_0x32e438,'execute',(_0x3d46c2,_0x4ae84e)=>{_0x18d8f0['execute']('forward'===_0x4ae84e?'showNextChange':'showPreviousChange');}),_0x32e438;}),_0xba9379['show'](),_0x5b1891['on']('change:isReady',(_0x574afc,_0x22664a,_0x210c62)=>{_0x210c62?_0xba9379['hide']():_0xba9379['show']();});}}class pt extends nt{['_resizeObserver']=null;constructor(_0x49915b,_0x334d1f){super(_0x49915b,_0x334d1f);const _0x548e28=this['bindTemplate'];this['set']({'label':m(_0x49915b,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=m(_0x49915b,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x548e28['to']('_tooltipString'),'data-cke-tooltip-position':'s','data-cke-tooltip-class':'ck-tooltip_multi-line'}});}['render'](){super['render'](),this['_resizeObserver']=new at(this['fieldView']['element'],()=>this['_updateTooltipText']()),this['listenTo'](this['fieldView'],'input',()=>this['_updateTooltipText']());}['destroy'](){super['destroy'](),this['_resizeObserver']&&this['_resizeObserver']['destroy']();}['_updateTooltipText'](){const _0x5a155b=this['fieldView']['element'];this['_tooltipString']=_0x5a155b['scrollWidth']>_0x5a155b['clientWidth']&&_0x5a155b['value']||'';}}class ti extends _0x4a3822{constructor(_0x5e3cec,_0x6d5246,_0x21c72f){super(_0x5e3cec);const _0x3e5187=new _0x5d4041();_0x3e5187['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 _0x2917be=['ck','ck-revision-history-sidebar__revision-author'];_0x21c72f&&_0x2917be['push']('ck-revision-history-sidebar__revision-author_creator');const _0x41e8d1=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':m(_0x5e3cec,_0x21c72f?'Revision\x20creator':'Revision\x20author')},'children':[_0x3e5187,_0x6d5246['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x2917be},'children':_0x41e8d1});}}function ni(_0x4d9193,_0x19fc2b){const _0x23e538=_0x4d9193['bindTemplate'],_0x3cd529=_0x4d9193['locale'],_0x16b4be=_0x2e60bd(_0x3cd529);_0x16b4be['panelPosition']='sw';const _0xc730c8=function(_0x41c4e0,_0x1f89ec){const _0x4e0b92=function(_0x50d426,_0x57f0c1){const _0x1bece2=_0x50d426['locale'],_0x28df0e={'Compare\x20against\x20selected':m(_0x1bece2,'Compare\x20against\x20selected'),'Name\x20this\x20revision':m(_0x1bece2,'Name\x20this\x20revision'),'Restore\x20this\x20revision':m(_0x1bece2,'Restore\x20this\x20revision')};return _0x57f0c1['map'](_0x508914=>{const _0x51a8e0=_0x28df0e[_0x508914['name']];return _0x51a8e0&&_0x51a8e0!==_0x508914['name']&&(_0x508914['name']=_0x51a8e0),_0x508914;});}(_0x41c4e0,_0x1f89ec),_0x2ba058=new _0x4e4c8a();for(const _0x4d0e35 of _0x4e0b92){const _0x318bc8={'type':'button','model':new to({'label':_0x4d0e35['name'],'class':_0x4d0e35['class'],'withText':!0x0,'role':'menuitem','_action':_0x4d0e35['action']})};_0x318bc8['model']['bind']('isEnabled')['to'](_0x41c4e0,'isActionsDropdownOpen',_0x3ee4b5=>'function'!=typeof _0x4d0e35['isEnabled']||(!_0x3ee4b5||_0x4d0e35['isEnabled'](_0x41c4e0))),_0x2ba058['add'](_0x318bc8);}return _0x2ba058;}(_0x4d9193,_0x19fc2b);return _0x4d9193['bind']('isActionsDropdownOpen')['to'](_0x16b4be,'isOpen'),_0x16b4be['buttonView']['set']({'label':m(_0x3cd529,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x15f173['threeVerticalDots']}),_0x16b4be['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x23e538['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x23e538['to'](_0x4771b7=>_0x4771b7['stopPropagation']())}}),_0x16b4be['on']('execute',_0x352210=>{_0x4d9193['isReady']&&'function'==typeof _0x352210['source']['_action']&&_0x352210['source']['_action'](_0x4d9193);}),_0x1d265f(_0x16b4be,_0xc730c8,{'role':'menu'}),_0x16b4be['listenTo'](_0x4d9193,'change:isActionsDropdownOpen',(_0x77f3db,_0x419bee,_0x3a4ff7)=>{if(_0x3a4ff7)for(const _0x10c29e of _0x16b4be['listView']['items']){const _0x28c19f=_0x10c29e['children']['first'],_0x575a1f=_0x19fc2b['find'](_0x2a8a87=>_0x2a8a87['action']===_0x28c19f['_action'])['isVisible'];_0x10c29e['isVisible']=void 0x0===_0x575a1f||_0x575a1f(_0x4d9193);}}),_0x16b4be;}class ai extends/* #__PURE__ -- @preserve */
|
|
26
|
+
_0x2a2fd6(_0x4a3822){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x45628b,_0x19d01f,_0x3ee7ad,_0x362fd9){super(_0x45628b);const _0x4667c2=this['bindTemplate'],_0x18c42a=function(_0x58beea,_0x52e3dc){const _0x91da7d=Array['from'](_0x52e3dc['authors'])['filter'](_0x1ac076=>_0x1ac076!=_0x52e3dc['creator']);return _0x52e3dc['creator']&&_0x91da7d['unshift'](_0x52e3dc['creator']),_0x91da7d['map'](_0x2ea7e1=>new ti(_0x58beea,_0x2ea7e1,_0x2ea7e1==_0x52e3dc['creator']));}(_0x45628b,_0x19d01f);this['id']=_0x19d01f['id'],this['_revision']=_0x19d01f,this['_requireRevisionName']=_0x362fd9,this['bind']('name','createdAt')['to'](_0x19d01f),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x2c7565=>{return _0x324c9d=_0x45628b['uiLanguage'],(_0x192b42=_0x2c7565)['toLocaleDateString'](_0x324c9d,{'month':'long','day':'numeric'})+',\x20'+_0x192b42['toLocaleTimeString'](_0x324c9d,{'hour':'numeric','minute':'numeric'});var _0x324c9d,_0x192b42;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new pt(_0x45628b,_0x5e5100),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x3ff915=>_0x3ff915||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x22fc5f,_0x940a24)=>_0x22fc5f&&_0x940a24),this['revisionActionsView']=_0x3ee7ad&&_0x3ee7ad['length']?ni(this,_0x3ee7ad):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x4667c2['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x4667c2['if']('isEnabled','ck-disabled',_0x36de79=>!_0x36de79),_0x4667c2['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x4667c2['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x4667c2['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':_0x4667c2['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':_0x18c42a}]},this['revisionActionsView']],'on':{'click':_0x4667c2['to'](_0x2879ac=>{_0x2879ac['srcElement']['closest']('.ck-thread__remove-confirm')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x16e630=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x16e630,'change',()=>{this['_requireRevisionName']&&!_0x16e630['value']||this['fire']('setName',{'id':this['id'],'name':_0x16e630['value']}),_0x16e630['value']||(_0x16e630['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(_0x9db3dd,_0x487fa2){const _0x24b062=_0x2b215c['fromJSDate'](_0x9db3dd)['setLocale'](_0x487fa2),_0x8c3dff=_0x2b215c['local'](),_0x2b3412=_0x8c3dff['minus']({'days':0x1})['startOf']('day');let _0x408330,_0x4f0e0e;return _0x24b062['hasSame'](_0x8c3dff,'day')?(_0x408330=_0x24b062['startOf']('day')['toJSDate'](),_0x4f0e0e=_0x24b062['toRelativeCalendar']()):_0x24b062['hasSame'](_0x2b3412,'day')?(_0x408330=_0x2b3412['toJSDate'](),_0x4f0e0e=_0x24b062['toRelativeCalendar']()):_0x24b062['hasSame'](_0x8c3dff,'week')?(_0x408330=_0x24b062['startOf']('week')['toJSDate'](),_0x4f0e0e=_0x24b062['weekdayLong']||''):_0x24b062['hasSame'](_0x8c3dff,'year')?(_0x408330=_0x24b062['startOf']('month')['toJSDate'](),_0x4f0e0e=_0x24b062['monthLong']||''):(_0x408330=_0x24b062['startOf']('year')['toJSDate'](),_0x4f0e0e=String(_0x24b062['year'])),{'startDate':_0x408330,'localizedPeriodName':_0x4f0e0e};}class vi extends _0x4a3822{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x54b078,_0x274219,_0x3f8134,_0x10d764){super(_0x54b078);const _0x422463=mi(_0x274219,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x274219,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x3f8134,this['_requireRevisionName']=_0x10d764,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':_0x422463}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x69c2b0){const _0x14eed8=new ai(this['locale'],_0x69c2b0,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x14eed8);}['removeRevision'](_0x25d9b5){const _0x4fd035=this['revisionViews']['find'](_0x39aeb6=>_0x39aeb6['id']===_0x25d9b5['id']);this['revisionViews']['remove'](_0x4fd035);}}class as extends _0x4a3822{constructor(_0x501cb4){super(_0x501cb4);const _0x21c82f=new _0x5d4041();_0x21c82f['content']=_0x15f173['history'],this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x21c82f,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[m(_0x501cb4,'Revision\x20history')]}]});}}class li extends _0x4a3822{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x431e08,_0x3661ad,_0x2d4fe5,_0x5ee145){super(_0x431e08);const _0x4234d7=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x3661ad,this['_revisionActions']=_0x2d4fe5,this['_requireRevisionName']=_0x5ee145,this['on']('select',(_0x41ac1d,_0x438585)=>{this['fire']('revisionSelected',_0x438585);}),this['on']('setName',(_0x10cf70,_0x11fe09)=>{this['fire']('revisionSetName',_0x11fe09);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new as(_0x431e08),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x4234d7['if']('isEnabled','ck-disabled',_0x57dfe9=>!_0x57dfe9)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x4bbbac of this['_revisions'])this['_addRevision'](_0x4bbbac);this['_revisions']['on']('add',(_0x2404f3,_0x5b2f7f)=>{this['_addRevision'](_0x5b2f7f);}),this['_revisions']['on']('remove',(_0x246a10,_0x341dc1)=>{this['_removeRevision'](_0x341dc1);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x88c20b=>_0x88c20b['revisionViews']['map'](_0x562e28=>_0x562e28))['flat']();}['selectRevision'](_0x57d235){for(const _0x3bef3e of this['revisionViews'])_0x57d235&&_0x57d235['id']===_0x3bef3e['id']?_0x3bef3e['select']():_0x3bef3e['deselect']();}['highlightRevisions'](_0x49be04){for(const _0x18f4ca of this['revisionViews'])_0x49be04['some'](({id:_0x305b57})=>_0x305b57===_0x18f4ca['id'])?_0x18f4ca['highlight']():_0x18f4ca['unhighlight']();}['_addRevision'](_0x279bf6){const _0x50de29=mi(_0x279bf6['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x4af881=this['timePeriodViews']['get'](0x0);_0x4af881&&_0x4af881['startDate']['getTime']()===_0x50de29['getTime']()||(_0x4af881=new vi(this['locale'],_0x50de29,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x4af881)),_0x4af881['addRevision'](_0x279bf6);}['_removeRevision'](_0x3daee8){const _0x4b6656=mi(_0x3daee8['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x4b6656)['removeRevision'](_0x3daee8);}['_getTimePeriodViewByStartDate'](_0x694863){return this['timePeriodViews']['find'](_0x5bf31b=>_0x5bf31b['startDate']['getTime']()===_0x694863['getTime']());}}class w extends _0x32454b{['_revisionViewer'];['_revisionsRepository'];['_sidebarView'];static ['defaultRevisionActions']=/* #__PURE__ -- @preserve */
|
|
27
27
|
((()=>['compareAgainstSelected','restoreRevision','nameRevision'])());static ['availableRevisionActions']=/* #__PURE__ -- @preserve */
|
|
28
|
-
|
|
29
|
-
it(tt){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x21e1ad,_0xc6e691){super(_0xc6e691),this['sourceElement']=_0x21e1ad,this['model']['document']['createRoot']();const _0x17bc22=new et(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new rt(this,_0x17bc22);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x32f147,_0x3413d0){const _0x5783f1=new this(_0x32f147,_0x3413d0);return await _0x5783f1['initPlugins'](),await _0x5783f1['ui']['init'](_0x32f147),await _0x5783f1['data']['init'](_0x5783f1['config']['get']('initialData')||''),_0x5783f1['fire']('ready'),_0x5783f1;}}const p=['RevisionHistoryUI','RestrictedEditingMode'];class bt extends _0x1420a4{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x1b2f20){function _0x1782cb(_0x58a055){return _0x58a055['map'](_0xce4d16=>String['fromCharCode'](_0xce4d16))['join']('');}super(_0x1b2f20),this['result']='end',_0x1b2f20[_0x1782cb([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x1782cb([0x76,0x69,0x65,0x77])][_0x1782cb([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x1782cb([0x61,0x75,0x74,0x6f]),_0x1b2f20[_0x1782cb([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x1782cb([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x1782cb([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x1782cb([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x1782cb([0x6f,0x6b])});}}class k extends _0x1420a4{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l,u];}constructor(_0xaf1526){if(super(_0xaf1526),!this['editor']['config']['get']('revisionHistory'))throw new _0x5ea7ff('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x48ecd7=>this['_showRevisionViewer']({..._0x48ecd7,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0xef42a5=>this['_closeRevisionViewer'](_0xef42a5)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x44ecb=>this['_restoreRevision'](_0x44ecb)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x1239d0){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x1239d0;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x1bef05){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x1bef05);}['getRevision'](_0x4d0315){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x4d0315);}['getRevisions'](_0x686e17){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x686e17||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x59ef11=this['editor'],_0x7a5ab0=_0xbfc40b(_0x59ef11,p),_0x5150e2=_0x59ef11['plugins']['get']('RevisionTracker'),_0x1567e8=_0x59ef11['plugins']['get']('Users')['users'];return _0x7a5ab0['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x7a5ab0['lazyRoots'],(_0x7a5ab0['plugins']['push'](bt,d,g,class extends _0x1420a4{static get['requires'](){return[d,'Users'];}['init'](){const _0x56822e=this['editor']['plugins']['get']('Users');for(const _0xfe313e of _0x1567e8)_0xfe313e['isAnonymous']||_0x56822e['getUser'](_0xfe313e['id'])||_0x56822e['addUser'](_0xfe313e);const _0x5cb0ec=_0x5150e2['repository']['getRevisions']();let _0x274f58=null;const _0x518e87=this['editor']['plugins']['get']('RevisionViewer');_0x518e87['adapter']=_0x5150e2['adapter'],_0x518e87['bind']('isEnabled')['to'](_0x5150e2),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x59ef11,'isReadOnly',_0x2754f5=>!_0x2754f5);for(const _0x5f2e29 of _0x5cb0ec){const _0x352055=null===_0x5f2e29['creator'];if(_0x352055&&_0x5f2e29['toVersion']===_0x5f2e29['fromVersion'])continue;const _0x2217eb=_0x5f2e29['toJSON']();_0x518e87['addRevisionData'](_0x2217eb,(_0x280939,_0xa3b555,_0x180b89)=>{if(_0x352055){if(_0x274f58)_0x274f58['_update'](_0x280939,_0xa3b555);else{if(!_0xa3b555){const _0x258460=_0x180b89['toJSON']();_0x258460['id']=_0x5d66aa(),_0x5150e2['saveRevision'](_0x258460,_0x180b89['toVersion'])['then'](_0x46854a=>{_0x274f58=_0x46854a;});}}}else _0x5f2e29['_update'](_0x280939,_0xa3b555);});}}},w),_0x7a5ab0);}['_enhanceShowRevisionViewerCallback'](){const _0xce541c=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x59e97f=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x4f2da0=this['editor']['plugins']['get']('Autosave');await _0x4f2da0['save']();}else await _0x59e97f['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x203dec=this['editor']['plugins']['get']('Dialog');_0x203dec['isOpen']&&_0x203dec['hide']();}const _0x5a8984=this['_getRevisionViewerEditorConfig']();return _0xce541c(_0x5a8984)['then'](_0x15cc0c=>{return(this['_viewerEditor']=_0x15cc0c,this['editor']['plugins']['has']('Annotations'))&&this['editor']['plugins']['get']('Annotations')['refreshVisibility'](),_0x15cc0c;})['catch'](_0x704e40=>(console['error'](_0x704e40),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x35cc34=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'](),_0x35cc34(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x587ccc=this['editor']['plugins']['get']('Annotations');_0x587ccc['refreshVisibility'](),_0x587ccc['refreshPositioning']();}})));}['_showRevisionViewer'](_0x4d912b){const _0x1a075a=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x296988=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x1af494=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return R['create'](_0x1af494,_0x4d912b)['then'](_0x1aa783=>(_0x296988['style']['display']='block',_0x1a075a['style']['display']='none',_0x1aa783));}['_closeRevisionViewer'](_0x35bbc5){const _0x4c394a=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x4c394a['style']['display']='',_0x35bbc5['destroy']();}async['_restoreRevision'](_0x2f72ac){const _0x4c5d4f=this['editor'],_0x3f381e=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x432f4e=_0x4c5d4f['plugins']['get']('RevisionTracker'),_0x55c149=_0x3f381e['repository']['getRevision'](_0x2f72ac);let _0x123f66,_0x1c2659,_0x5c7290;try{_0x123f66=await _0x3f381e['getRevisionData'](_0x55c149),_0x1c2659=await _0x3f381e['getRevisionRootsAttributes'](_0x55c149);}catch(_0xe2989e){return void console['error'](_0xe2989e);}_0x4c5d4f['model']['change'](_0x3ab56a=>{for(const _0x31d132 of Array['from'](_0x4c5d4f['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x3ab56a['removeMarker'](_0x31d132);}),_0x3f381e['isReady']=!0x1,_0x4c5d4f['model']['enqueueChange'](_0x5d4018=>{_0x5d4018['setSelection'](null),_0x5d4018['removeSelectionAttribute'](_0x4c5d4f['model']['document']['selection']['getAttributeKeys']());const _0x1bb9f3=Object['keys'](_0x123f66);for(const _0x4da2c0 of _0x4c5d4f['model']['document']['roots'])'$graveyard'!=_0x4da2c0['rootName']&&_0x4da2c0['isAttached']()&&!_0x1bb9f3['includes'](_0x4da2c0['rootName'])&&_0x5d4018['detachRoot'](_0x4da2c0);for(const _0x6109c1 of _0x1bb9f3){let _0x55998e=_0x4c5d4f['model']['document']['getRoot'](_0x6109c1);_0x55998e&&_0x55998e['isAttached']()||(_0x55998e=_0x5d4018['addRoot'](_0x6109c1));const _0x47e3e2=_0x1c2659[_0x6109c1],_0xe71936=Object['keys'](_0x47e3e2),_0x5b9dd1=_0x123f66[_0x6109c1];for(const _0xcb8a40 of _0x55998e['getAttributeKeys']())_0xe71936['includes'](_0xcb8a40)||_0x5d4018['removeAttribute'](_0xcb8a40,_0x55998e);for(const _0x20f45d of _0xe71936)_0x5d4018['setAttribute'](_0x20f45d,_0x1c2659[_0x6109c1][_0x20f45d],_0x55998e);_0x5d4018['remove'](_0x5d4018['createRangeIn'](_0x55998e)),_0x5d4018['insert'](_0x4c5d4f['data']['parse'](_0x5b9dd1,_0x55998e),_0x55998e,0x0);}});const _0x1ec31c=m(_0x4c5d4f['locale'],'Restored');if(_0x55c149['name'])_0x5c7290=-0x1==_0x55c149['name']['indexOf'](_0x1ec31c)?_0x1ec31c+':\x20'+_0x55c149['name']:_0x55c149['name'];else _0x5c7290=_0x1ec31c+':\x20'+(_0x55c149['createdAt']['toLocaleDateString'](_0x4c5d4f['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x55c149['createdAt']['toLocaleTimeString'](_0x4c5d4f['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x432f4e['saveRevision']({'name':_0x5c7290}),_0x3f381e['isReady']=!0x0,_0x4c5d4f['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{a as Revision,k as RevisionHistory,u as RevisionHistoryUI,l as RevisionTracker,d as RevisionViewer,ge as RevisionViewerLoadingOverlay,g as RevisionViewerUI,j as RevisionsRepository,w as RevisionsSidebar};
|
|
28
|
+
bt();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[d];}constructor(_0x3a1732){super(_0x3a1732),this['_revisionViewer']=_0x3a1732['plugins']['get'](d),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x2bf7ae=this['_revisionsRepository']['_revisions'],_0x385e7a=this['_createRevisionActions'](),_0x42e37f=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new li(this['editor']['locale'],_0x2bf7ae,_0x385e7a,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',(_0x1521ea,_0x5bff6d)=>{_0x5bff6d['revisionViews']['on']('add',(_0x31e71a,_0x6a11da)=>{_0x6a11da['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)),_0x42e37f['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x548a3b=this['_revisionsRepository']['getRevision'](0x0);if(_0x548a3b){const _0x265bfc=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x548a3b['id']);this['_revisionViewer']['compare'](_0x548a3b,_0x265bfc);}}['_handleRevisionSelected'](_0x3dbcea,_0x3f3206){const _0x42b84c=this['_revisionsRepository']['getRevision'](_0x3f3206['id']),_0x1c3a25=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x42b84c['id']);this['_revisionViewer']['compare'](_0x42b84c,_0x1c3a25);}['_handleRevisionSetName'](_0x1a563a,_0x4168a0){this['_revisionsRepository']['getRevision'](_0x4168a0['id'])['setName'](_0x4168a0['name']);}['_handleDiffChange'](_0x4a4a86,_0x31008e,_0x378b48){const _0x45bc94=this['_revisionsRepository']['getRevisionsInDiff'](_0x378b48);_0x45bc94['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x45bc94),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x45bc94[0x0]));}['_createRevisionActions'](){const _0x10aa19=this['editor'],_0x521d23=w['availableRevisionActions'],_0x22416c=_0x10aa19['config']['get']('revisionHistory.revisionActions')||w['defaultRevisionActions'];if(_0x22416c['length'])return _0x22416c['map'](_0x385e95=>{const _0x42f3fe='string'==typeof _0x385e95?Object['assign']({},_0x521d23[_0x385e95]):_0x385e95;return _0x42f3fe['action']=_0x42f3fe['action']['bind'](this,_0x10aa19),_0x42f3fe['isVisible']&&(_0x42f3fe['isVisible']=_0x42f3fe['isVisible']['bind'](this,_0x10aa19)),_0x42f3fe;});}}function bt(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x10e7d1},_0xcb9903)=>{const _0x59aa8f=_0x10e7d1['get'](d),_0x2fa766=_0x59aa8f['repository'];let _0x2c7caa=_0x59aa8f['diff']['newRevisionId'],_0x29560a=_0xcb9903['id'];_0x2fa766['getIndex'](_0x2c7caa)>_0x2fa766['getIndex'](_0x29560a)&&([_0x2c7caa,_0x29560a]=[_0x29560a,_0x2c7caa]),_0x59aa8f['compare'](_0x2c7caa,_0x29560a);},'isVisible':({plugins:_0xa31787},_0x277ec6)=>{const _0x3df54d=_0xa31787['get'](d);return!(_0x3df54d['repository']['getRevisionsInDiff'](_0x3df54d['diff'])['length']>0x2)&&!_0x277ec6['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x51d994,{id:_0x19f7c5})=>{_0x51d994['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x19f7c5);},'isVisible':({plugins:_0x3cd8ee},_0x1d5f15)=>!!_0x3cd8ee['get'](d)['repository']['getLaterVisibleRevision'](_0x1d5f15['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x459a45},{id:_0x2219d2,revisionNameView:_0x1742d6})=>{const _0x4f9f14=_0x459a45['get'](d),_0x1fe65c=_0x4f9f14['repository']['getEarlierVisibleRevision'](_0x2219d2);_0x4f9f14['compare'](_0x2219d2,_0x1fe65c),_0x1742d6['focus'](),_0x1742d6['fieldView']['select']();}}};}class rt extends st{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x1332f8,_0xd2168c){super(_0x1332f8),this['_view']=_0xd2168c,this['_toolbarConfig']=ot(_0x1332f8['config']['get']('toolbar')),this['_elementReplacer']=new ht();}get['element'](){return this['view']['element'];}['init'](_0x3d6719){const _0x8f9e5a=this['editor'],_0x27d453=this['view'],_0x2d0af0=_0x8f9e5a['editing']['view'],_0x158cfa=_0x27d453['editable'],_0x52bd0a=_0x2d0af0['document']['getRoot']();_0x158cfa['name']=_0x52bd0a['rootName'],_0x27d453['render']();const _0x14ce58=_0x158cfa['element'];this['setEditableElement'](_0x158cfa['name'],_0x14ce58),_0x27d453['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x2d0af0['attachDomRoot'](_0x14ce58),this['_elementReplacer']['replace'](_0x3d6719,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x3bad3e=this['view'],_0x462e58=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x462e58['detachDomRoot'](_0x3bad3e['editable']['name']),_0x3bad3e['destroy']();}['_initToolbar'](){const _0x141ca5=this['view'];_0x141ca5['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x141ca5['stickyPanel']['limiterElement']=_0x141ca5['element'],_0x141ca5['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x4591ab})=>_0x4591ab),_0x141ca5['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x141ca5['toolbar']);}}class et extends ct{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x3e7e7e,_0xf09878,_0x746b4a={}){super(_0x3e7e7e),this['stickyPanel']=new ut(_0x3e7e7e),this['toolbar']=new lt(_0x3e7e7e,{'shouldGroupWhenFull':_0x746b4a['shouldToolbarGroupWhenFull']}),this['_editable']=new dt(_0x3e7e7e,_0xf09878);}['render'](){super['render'](),this['stickyPanel']['content']['add'](this['toolbar']),this['top']['add'](this['stickyPanel']),this['main']['add'](this['editable']);}}class R extends/* #__PURE__ -- @preserve */
|
|
29
|
+
it(tt){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x278d87,_0x5c782a){super(_0x5c782a),this['sourceElement']=_0x278d87,this['model']['document']['createRoot']();const _0x37c9b9=new et(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new rt(this,_0x37c9b9);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0xb9e815,_0x33e33b){const _0xa6013a=new this(_0xb9e815,_0x33e33b);return await _0xa6013a['initPlugins'](),await _0xa6013a['ui']['init'](_0xb9e815),await _0xa6013a['data']['init'](_0xa6013a['config']['get']('initialData')||''),_0xa6013a['fire']('ready'),_0xa6013a;}}const p=['RevisionHistoryUI','RestrictedEditingMode'];class Rt extends _0x32454b{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x29efbc){function _0x3dd5fd(_0x502e5c){return _0x502e5c['map'](_0x483564=>String['fromCharCode'](_0x483564))['join']('');}super(_0x29efbc),this['result']='end',_0x29efbc[_0x3dd5fd([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x3dd5fd([0x76,0x69,0x65,0x77])][_0x3dd5fd([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x3dd5fd([0x61,0x75,0x74,0x6f]),_0x29efbc[_0x3dd5fd([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x3dd5fd([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x3dd5fd([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x3dd5fd([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x3dd5fd([0x6f,0x6b])});}}class k extends _0x32454b{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l,u];}constructor(_0x171d56){if(super(_0x171d56),!this['editor']['config']['get']('revisionHistory'))throw new _0x4dc96e('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x54c3d3=>this['_showRevisionViewer']({..._0x54c3d3,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x3e044e=>this['_closeRevisionViewer'](_0x3e044e)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x5a5f15=>this['_restoreRevision'](_0x5a5f15)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x40755e){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x40755e;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x2b3c29){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x2b3c29);}['getRevision'](_0x3becef){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x3becef);}['getRevisions'](_0x17d0b1){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x17d0b1||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x38b0a3=this['editor'],_0x4430f3=_0x162ae5(_0x38b0a3,p),_0x4e3395=_0x38b0a3['plugins']['get']('RevisionTracker'),_0x4d0e0f=_0x38b0a3['plugins']['get']('Users')['users'];return _0x4430f3['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x4430f3['lazyRoots'],(_0x4430f3['plugins']['push'](Rt,d,g,class extends _0x32454b{static get['requires'](){return[d,'Users'];}['init'](){const _0x208138=this['editor']['plugins']['get']('Users');for(const _0x328c66 of _0x4d0e0f)_0x328c66['isAnonymous']||_0x208138['getUser'](_0x328c66['id'])||_0x208138['addUser'](_0x328c66);const _0x531af6=_0x4e3395['repository']['getRevisions']();let _0x1d7666=null;const _0x12ef7f=this['editor']['plugins']['get']('RevisionViewer');_0x12ef7f['adapter']=_0x4e3395['adapter'],_0x12ef7f['bind']('isEnabled')['to'](_0x4e3395),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x38b0a3,'isReadOnly',_0x428414=>!_0x428414);for(const _0x2a693f of _0x531af6){const _0x31bc=null===_0x2a693f['creator'];if(_0x31bc&&_0x2a693f['toVersion']===_0x2a693f['fromVersion'])continue;const _0x4acdc2=_0x2a693f['toJSON']();_0x12ef7f['addRevisionData'](_0x4acdc2,(_0x703cd9,_0x41cade,_0x350b19)=>{if(_0x31bc){if(_0x1d7666)_0x1d7666['_update'](_0x703cd9,_0x41cade);else{if(!_0x41cade){const _0x574e2a=_0x350b19['toJSON']();_0x574e2a['id']=_0x4ff600(),_0x4e3395['saveRevision'](_0x574e2a,_0x350b19['toVersion'])['then'](_0x116f17=>{_0x1d7666=_0x116f17;});}}}else _0x2a693f['_update'](_0x703cd9,_0x41cade);});}}},w),_0x4430f3);}['_enhanceShowRevisionViewerCallback'](){const _0x3501b7=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x23d214=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x24324a=this['editor']['plugins']['get']('Autosave');await _0x24324a['save']();}else await _0x23d214['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0xb02207=this['editor']['plugins']['get']('Dialog');_0xb02207['isOpen']&&_0xb02207['hide']();}const _0x4216db=this['_getRevisionViewerEditorConfig']();return _0x3501b7(_0x4216db)['then'](_0x752c13=>{return(this['_viewerEditor']=_0x752c13,this['editor']['plugins']['has']('Annotations'))&&this['editor']['plugins']['get']('Annotations')['refreshVisibility'](),_0x752c13;})['catch'](_0x2c2ba5=>(console['error'](_0x2c2ba5),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x6cc932=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'](),_0x6cc932(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0xb4700d=this['editor']['plugins']['get']('Annotations');_0xb4700d['refreshVisibility'](),_0xb4700d['refreshPositioning']();}})));}['_showRevisionViewer'](_0x5e8737){const _0x387700=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x2e7b1d=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x51e4b0=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return R['create'](_0x51e4b0,_0x5e8737)['then'](_0x56ff4a=>(_0x2e7b1d['style']['display']='block',_0x387700['style']['display']='none',_0x56ff4a));}['_closeRevisionViewer'](_0x5e8ec9){const _0x19f8c4=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x19f8c4['style']['display']='',_0x5e8ec9['destroy']();}async['_restoreRevision'](_0x3be59e){const _0x546dac=this['editor'],_0x1ae39d=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x175f50=_0x546dac['plugins']['get']('RevisionTracker'),_0x1a46d4=_0x1ae39d['repository']['getRevision'](_0x3be59e);let _0x356139,_0x4b3aa5,_0x23b948;try{_0x356139=await _0x1ae39d['getRevisionData'](_0x1a46d4),_0x4b3aa5=await _0x1ae39d['getRevisionRootsAttributes'](_0x1a46d4);}catch(_0x5dbb54){return void console['error'](_0x5dbb54);}_0x546dac['model']['change'](_0x36c8b8=>{for(const _0x1ae359 of Array['from'](_0x546dac['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x36c8b8['removeMarker'](_0x1ae359);}),_0x1ae39d['isReady']=!0x1,_0x546dac['model']['enqueueChange'](_0x21e0f1=>{_0x21e0f1['setSelection'](null),_0x21e0f1['removeSelectionAttribute'](_0x546dac['model']['document']['selection']['getAttributeKeys']());const _0x30a4ab=Object['keys'](_0x356139);for(const _0xfd6b05 of _0x546dac['model']['document']['roots'])'$graveyard'!=_0xfd6b05['rootName']&&_0xfd6b05['isAttached']()&&!_0x30a4ab['includes'](_0xfd6b05['rootName'])&&_0x21e0f1['detachRoot'](_0xfd6b05);for(const _0x21c6d1 of _0x30a4ab){let _0x3a3ce5=_0x546dac['model']['document']['getRoot'](_0x21c6d1);_0x3a3ce5&&_0x3a3ce5['isAttached']()||(_0x3a3ce5=_0x21e0f1['addRoot'](_0x21c6d1));const _0x29fa5e=_0x4b3aa5[_0x21c6d1],_0x957d9e=Object['keys'](_0x29fa5e),_0x1578be=_0x356139[_0x21c6d1];for(const _0x344fa1 of _0x3a3ce5['getAttributeKeys']())_0x957d9e['includes'](_0x344fa1)||_0x21e0f1['removeAttribute'](_0x344fa1,_0x3a3ce5);for(const _0x1e2c80 of _0x957d9e)_0x21e0f1['setAttribute'](_0x1e2c80,_0x4b3aa5[_0x21c6d1][_0x1e2c80],_0x3a3ce5);_0x21e0f1['remove'](_0x21e0f1['createRangeIn'](_0x3a3ce5)),_0x21e0f1['insert'](_0x546dac['data']['parse'](_0x1578be,_0x3a3ce5),_0x3a3ce5,0x0);}});const _0x380b72=m(_0x546dac['locale'],'Restored');if(_0x1a46d4['name'])_0x23b948=-0x1==_0x1a46d4['name']['indexOf'](_0x380b72)?_0x380b72+':\x20'+_0x1a46d4['name']:_0x1a46d4['name'];else _0x23b948=_0x380b72+':\x20'+(_0x1a46d4['createdAt']['toLocaleDateString'](_0x546dac['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x1a46d4['createdAt']['toLocaleTimeString'](_0x546dac['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x175f50['saveRevision']({'name':_0x23b948}),_0x1ae39d['isReady']=!0x0,_0x546dac['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{a as Revision,k as RevisionHistory,u as RevisionHistoryUI,l as RevisionTracker,d as RevisionViewer,ae as RevisionViewerLoadingOverlay,g as RevisionViewerUI,j as RevisionsRepository,w as RevisionsSidebar};
|