@ckeditor/ckeditor5-revision-history 0.0.0-nightly-20250611.0 → 0.0.0-nightly-20250614.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/revision-history.js +1 -1
- package/dist/index.js +7 -7
- package/dist/translations/af.js +1 -1
- package/dist/translations/af.umd.js +1 -1
- package/dist/translations/ar.js +1 -1
- package/dist/translations/ar.umd.js +1 -1
- package/dist/translations/ast.js +1 -1
- package/dist/translations/ast.umd.js +1 -1
- package/dist/translations/az.js +1 -1
- package/dist/translations/az.umd.js +1 -1
- package/dist/translations/be.js +1 -1
- package/dist/translations/be.umd.js +1 -1
- package/dist/translations/bg.js +1 -1
- package/dist/translations/bg.umd.js +1 -1
- package/dist/translations/bn.js +1 -1
- package/dist/translations/bn.umd.js +1 -1
- package/dist/translations/bs.js +1 -1
- package/dist/translations/bs.umd.js +1 -1
- package/dist/translations/ca.js +1 -1
- package/dist/translations/ca.umd.js +1 -1
- package/dist/translations/cs.js +1 -1
- package/dist/translations/cs.umd.js +1 -1
- package/dist/translations/da.js +1 -1
- package/dist/translations/da.umd.js +1 -1
- package/dist/translations/de-ch.js +1 -1
- package/dist/translations/de-ch.umd.js +1 -1
- package/dist/translations/de.js +1 -1
- package/dist/translations/de.umd.js +1 -1
- package/dist/translations/el.js +1 -1
- package/dist/translations/el.umd.js +1 -1
- package/dist/translations/en-au.js +1 -1
- package/dist/translations/en-au.umd.js +1 -1
- package/dist/translations/en-gb.js +1 -1
- package/dist/translations/en-gb.umd.js +1 -1
- package/dist/translations/en.js +1 -1
- package/dist/translations/en.umd.js +1 -1
- package/dist/translations/eo.js +1 -1
- package/dist/translations/eo.umd.js +1 -1
- package/dist/translations/es-co.js +1 -1
- package/dist/translations/es-co.umd.js +1 -1
- package/dist/translations/es.js +1 -1
- package/dist/translations/es.umd.js +1 -1
- package/dist/translations/et.js +1 -1
- package/dist/translations/et.umd.js +1 -1
- package/dist/translations/eu.js +1 -1
- package/dist/translations/eu.umd.js +1 -1
- package/dist/translations/fa.js +1 -1
- package/dist/translations/fa.umd.js +1 -1
- package/dist/translations/fi.js +1 -1
- package/dist/translations/fi.umd.js +1 -1
- package/dist/translations/fr.js +1 -1
- package/dist/translations/fr.umd.js +1 -1
- package/dist/translations/gl.js +1 -1
- package/dist/translations/gl.umd.js +1 -1
- package/dist/translations/gu.js +1 -1
- package/dist/translations/gu.umd.js +1 -1
- package/dist/translations/he.js +1 -1
- package/dist/translations/he.umd.js +1 -1
- package/dist/translations/hi.js +1 -1
- package/dist/translations/hi.umd.js +1 -1
- package/dist/translations/hr.js +1 -1
- package/dist/translations/hr.umd.js +1 -1
- package/dist/translations/hu.js +1 -1
- package/dist/translations/hu.umd.js +1 -1
- package/dist/translations/hy.js +1 -1
- package/dist/translations/hy.umd.js +1 -1
- package/dist/translations/id.js +1 -1
- package/dist/translations/id.umd.js +1 -1
- package/dist/translations/it.js +1 -1
- package/dist/translations/it.umd.js +1 -1
- package/dist/translations/ja.js +1 -1
- package/dist/translations/ja.umd.js +1 -1
- package/dist/translations/jv.js +1 -1
- package/dist/translations/jv.umd.js +1 -1
- package/dist/translations/kk.js +1 -1
- package/dist/translations/kk.umd.js +1 -1
- package/dist/translations/km.js +1 -1
- package/dist/translations/km.umd.js +1 -1
- package/dist/translations/kn.js +1 -1
- package/dist/translations/kn.umd.js +1 -1
- package/dist/translations/ko.js +1 -1
- package/dist/translations/ko.umd.js +1 -1
- package/dist/translations/ku.js +1 -1
- package/dist/translations/ku.umd.js +1 -1
- package/dist/translations/lt.js +1 -1
- package/dist/translations/lt.umd.js +1 -1
- package/dist/translations/lv.js +1 -1
- package/dist/translations/lv.umd.js +1 -1
- package/dist/translations/ms.js +1 -1
- package/dist/translations/ms.umd.js +1 -1
- package/dist/translations/nb.js +1 -1
- package/dist/translations/nb.umd.js +1 -1
- package/dist/translations/ne.js +1 -1
- package/dist/translations/ne.umd.js +1 -1
- package/dist/translations/nl.js +1 -1
- package/dist/translations/nl.umd.js +1 -1
- package/dist/translations/no.js +1 -1
- package/dist/translations/no.umd.js +1 -1
- package/dist/translations/oc.js +1 -1
- package/dist/translations/oc.umd.js +1 -1
- package/dist/translations/pl.js +1 -1
- package/dist/translations/pl.umd.js +1 -1
- package/dist/translations/pt-br.js +1 -1
- package/dist/translations/pt-br.umd.js +1 -1
- package/dist/translations/pt.js +1 -1
- package/dist/translations/pt.umd.js +1 -1
- package/dist/translations/ro.js +1 -1
- package/dist/translations/ro.umd.js +1 -1
- package/dist/translations/ru.js +1 -1
- package/dist/translations/ru.umd.js +1 -1
- package/dist/translations/si.js +1 -1
- package/dist/translations/si.umd.js +1 -1
- package/dist/translations/sk.js +1 -1
- package/dist/translations/sk.umd.js +1 -1
- package/dist/translations/sl.js +1 -1
- package/dist/translations/sl.umd.js +1 -1
- package/dist/translations/sq.js +1 -1
- package/dist/translations/sq.umd.js +1 -1
- package/dist/translations/sr-latn.js +1 -1
- package/dist/translations/sr-latn.umd.js +1 -1
- package/dist/translations/sr.js +1 -1
- package/dist/translations/sr.umd.js +1 -1
- package/dist/translations/sv.js +1 -1
- package/dist/translations/sv.umd.js +1 -1
- package/dist/translations/th.js +1 -1
- package/dist/translations/th.umd.js +1 -1
- package/dist/translations/ti.js +1 -1
- package/dist/translations/ti.umd.js +1 -1
- package/dist/translations/tk.js +1 -1
- package/dist/translations/tk.umd.js +1 -1
- package/dist/translations/tr.js +1 -1
- package/dist/translations/tr.umd.js +1 -1
- package/dist/translations/tt.js +1 -1
- package/dist/translations/tt.umd.js +1 -1
- package/dist/translations/ug.js +1 -1
- package/dist/translations/ug.umd.js +1 -1
- package/dist/translations/uk.js +1 -1
- package/dist/translations/uk.umd.js +1 -1
- package/dist/translations/ur.js +1 -1
- package/dist/translations/ur.umd.js +1 -1
- package/dist/translations/uz.js +1 -1
- package/dist/translations/uz.umd.js +1 -1
- package/dist/translations/vi.js +1 -1
- package/dist/translations/vi.umd.js +1 -1
- package/dist/translations/zh-cn.js +1 -1
- package/dist/translations/zh-cn.umd.js +1 -1
- package/dist/translations/zh.js +1 -1
- package/dist/translations/zh.umd.js +1 -1
- package/package.json +11 -11
- package/src/changeitem.js +2 -2
- package/src/editor/revisionviewereditor.js +2 -2
- package/src/editor/revisionviewereditorui.js +1 -1
- package/src/editor/revisionviewereditoruiview.js +1 -1
- package/src/index.d.ts +3 -2
- package/src/index.js +1 -1
- package/src/revision.js +2 -2
- package/src/revisiondiff.js +1 -1
- package/src/revisionhistory.js +1 -1
- package/src/revisionhistoryutils.js +1 -1
- package/src/revisionsrepository.js +1 -1
- package/src/revisiontracker.js +1 -1
- package/src/revisionviewer.js +1 -1
- package/src/ui/revision/createrevisionactionsdropdown.js +1 -1
- package/src/ui/revision/revisionauthorview.js +1 -1
- package/src/ui/revision/revisionnameview.js +1 -1
- package/src/ui/revision/revisionview.js +2 -2
- package/src/ui/revision/subrevisioncollapserview.js +1 -1
- package/src/ui/revision/subrevisionview.js +1 -1
- package/src/ui/revision/utils.js +1 -1
- package/src/ui/revisionhistory/revisionhistorysaverevisionformview.js +2 -2
- package/src/ui/revisionhistory/revisionhistoryui.js +1 -1
- package/src/ui/revisionssidebar/revisionssidebar.js +1 -1
- package/src/ui/revisionssidebar/revisionssidebarheaderview.js +1 -1
- package/src/ui/revisionssidebar/revisionssidebartimeperiodview.js +1 -1
- package/src/ui/revisionssidebar/revisionssidebarview.js +1 -1
- package/src/ui/revisionssidebar/utils.js +1 -1
- package/src/ui/revisionviewer/changedetailsview.js +1 -1
- package/src/ui/revisionviewer/changesnavigationview.js +1 -1
- package/src/ui/revisionviewer/revisionviewerloadingoverlay.js +1 -1
- package/src/ui/revisionviewer/revisionviewerui.js +1 -1
- package/src/utils/common-translations.js +1 -1
package/dist/index.js
CHANGED
|
@@ -20,11 +20,11 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
import{ObservableMixin as
|
|
24
|
-
_0x2e4104(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x1443b4){super(),this['id']=_0x1443b4['id']||_0x5545a3(),this['creator']=_0x1443b4['creator']||null,this['authors']=_0x1443b4['authors']||[],this['diffData']=_0x1443b4['diffData']||null,this['toVersion']=_0x1443b4['toVersion']||0x0,this['fromVersion']=_0x1443b4['fromVersion']||0x0,this['set']('name',_0x1443b4['name']||''),this['set']('createdAt',_0x1443b4['createdAt']||new Date()),this['set']('attributes',_0x1443b4['attributes']||{});}['setName'](_0x4c7229){this['_update']({'name':_0x4c7229});}['setAttribute'](_0x39108e,_0x36c9fb){const _0x1d6b72=_0x45be4a(this['attributes']);_0x3151fa(_0x1d6b72,_0x39108e,_0x36c9fb),this['_update']({'attributes':_0x1d6b72});}['removeAttribute'](_0x2bf836){const _0x5ad2a5=_0x45be4a(this['attributes']);_0x505729(_0x5ad2a5,_0x2bf836),this['_update']({'attributes':_0x5ad2a5});}['_update'](_0x4fa345,_0x3bc47b=!0x1){let _0x4a247a=!0x1;const _0x5410b9={'id':this['id']},_0x3da525=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x230dfa of _0x3da525){const _0x151c65=_0x4fa345[_0x230dfa];void 0x0!==_0x151c65&&_0x151c65!==this[_0x230dfa]&&(this[_0x230dfa]=_0x151c65,_0x5410b9[_0x230dfa]=_0x151c65,_0x4a247a=!0x0);}_0x4a247a&&(_0x5410b9['authors']&&(_0x5410b9['authorsIds']=_0x5410b9['authors']['map'](_0x397da8=>_0x397da8['id']),delete _0x5410b9['authors']),this['fire']('_update',_0x5410b9,_0x3bc47b));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x534d16=>_0x534d16['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class S extends _0x25ad5f{['_revisions'];static get['requires'](){return[_0x55a47e];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x5446ab){super(_0x5446ab),this['_revisions']=new _0x2da206();}['afterInit'](){!async function(_0xad4504){const _0x5c9a74=_0x4e4885([0x49,0x47,0x54,0x70,0x36,0x5a,0x4c,0x32,0x6b,0x66,0x53,0x55,0x58,0x51,0x56,0x6a,0x46,0x6f,0x4a,0x45,0x35,0x63,0x72,0x68,0x69,0x59,0x76,0x61,0x79,0x30,0x6c,0x75,0x50,0x64,0x65,0x71,0x39,0x73,0x74,0x52,0x48,0x41,0x33,0x7a,0x4e,0x38,0x37,0x4f,0x44,0x6e,0x62,0x57,0x42,0x77,0x31,0x43,0x34,0x4d,0x78,0x6d,0x67,0x4b]),_0xbf2ea=0xeb829,_0x1642c9=0x59a9891a,_0x1942cd=0x59aee36a^_0x1642c9,_0x499419=window[_0x4e4885([0x44,0x61,0x74,0x65])][_0x4e4885([0x6e,0x6f,0x77])](),_0x1df360=_0xad4504[_0x4e4885([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x1a5715=new window[(_0x4e4885([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0xdf3f02=>{_0x1df360[_0x4e4885([0x6f,0x6e,0x63,0x65])](_0x4e4885([0x72,0x65,0x61,0x64,0x79]),_0xdf3f02);}),_0x35d599={[_0x4e4885([0x6b,0x74,0x79])]:_0x4e4885([0x45,0x43]),[_0x4e4885([0x75,0x73,0x65])]:_0x4e4885([0x73,0x69,0x67]),[_0x4e4885([0x63,0x72,0x76])]:_0x4e4885([0x50,0x2d,0x32,0x35,0x36]),[_0x4e4885([0x78])]:_0x4e4885([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]),[_0x4e4885([0x79])]:_0x4e4885([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]),[_0x4e4885([0x61,0x6c,0x67])]:_0x4e4885([0x45,0x53,0x32,0x35,0x36])},_0x216c95=_0x1df360[_0x4e4885([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x4e4885([0x67,0x65,0x74])](_0x4e4885([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x36218f(){let _0x3bcb49,_0x2e55c8=null,_0x115fc3=null;try{if(_0x216c95==_0x4e4885([0x47,0x50,0x4c]))return _0x4e4885([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x3bcb49=_0x648488(),!_0x3bcb49)return _0x4e4885([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x3bcb49[_0x4e4885([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x115fc3=_0x340b80(_0x3bcb49[_0x4e4885([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x3bcb49[_0x4e4885([0x6a,0x74,0x69])])),await _0x2f07df()?_0x57b7d7()?_0xd51d50()?_0x4e4885([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0xaa4279()?(_0x3bcb49[_0x4e4885([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x4e4885([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x2e55c8=_0x145749(_0x4e4885([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x3bcb49[_0x4e4885([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x4e4885([0x74,0x72,0x69,0x61,0x6c])&&(_0x2e55c8=_0x145749(_0x4e4885([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x55667f()):_0x4e4885([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x4e4885([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x4e4885([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x4e4885([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0xd51d50(){const _0x91091=[_0x4e4885([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x4e4885([0x74,0x72,0x69,0x61,0x6c])][_0x4e4885([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x3bcb49[_0x4e4885([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x499419/0x3e8:0xe10*_0x1942cd;return _0x3bcb49[_0x4e4885([0x65,0x78,0x70])]<_0x91091;}function _0x57b7d7(){const _0x45fdf9=_0x3bcb49[_0x4e4885([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x45fdf9)return!0x1;if(_0x45fdf9[_0x4e4885([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4e4885([0x2a])))return!0x0;if(_0x45fdf9[_0x4e4885([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4e4885([0x52,0x48])))return!0x0;if(_0x45fdf9[_0x4e4885([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4e4885([0x52,0x52,0x48]))){if(_0x5d5a94())return!0x0;if(_0x1dd5b1()||_0x4af772())return!0x0;}return!0x1;}function _0xaa4279(){const _0x31903e=_0x3bcb49[_0x4e4885([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x31903e||0x0==_0x31903e[_0x4e4885([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0xa1ed8e}=new URL(window[_0x4e4885([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x31903e[_0x4e4885([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0xa1ed8e))return!0x0;const _0x4aceeb=_0xa1ed8e[_0x4e4885([0x73,0x70,0x6c,0x69,0x74])](_0x4e4885([0x2e]));return _0x31903e[_0x4e4885([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x296d5f=>_0x296d5f[_0x4e4885([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4e4885([0x2a])))[_0x4e4885([0x6d,0x61,0x70])](_0x250a5e=>_0x250a5e[_0x4e4885([0x73,0x70,0x6c,0x69,0x74])](_0x4e4885([0x2e])))[_0x4e4885([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x542ce4=>_0x542ce4[_0x4e4885([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x4aceeb[_0x4e4885([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x4e4885([0x6d,0x61,0x70])](_0x35f3b1=>Array(_0x4aceeb[_0x4e4885([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0x35f3b1[_0x4e4885([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x4e4885([0x66,0x69,0x6c,0x6c])](_0x35f3b1[0x0]===_0x4e4885([0x2a])?_0x4e4885([0x2a]):'')[_0x4e4885([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0x35f3b1))[_0x4e4885([0x73,0x6f,0x6d,0x65])](_0x3ea0f5=>_0x4aceeb[_0x4e4885([0x65,0x76,0x65,0x72,0x79])]((_0x4d672e,_0x430e21)=>_0x3ea0f5[_0x430e21]===_0x4d672e||_0x3ea0f5[_0x430e21]===_0x4e4885([0x2a])));}function _0x55667f(){return _0x2e55c8&&_0x115fc3?new window[(_0x4e4885([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x362acd,_0x118340)=>{_0x2e55c8[_0x4e4885([0x74,0x68,0x65,0x6e])](_0x362acd,_0x118340),_0x115fc3[_0x4e4885([0x74,0x68,0x65,0x6e])](_0x129193=>{_0x129193!=_0x4e4885([0x56,0x61,0x6c,0x69,0x64])&&_0x362acd(_0x129193);},_0x118340);}):_0x2e55c8||_0x115fc3||_0x4e4885([0x56,0x61,0x6c,0x69,0x64]);}}function _0x340b80(_0x191503,_0x58e7e2){return new window[(_0x4e4885([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x173409=>{if(_0x48964b())return _0x173409(_0x4e4885([0x56,0x61,0x6c,0x69,0x64]));_0x501e4a(),_0x1df360[_0x4e4885([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x4e4885([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x233788=!0x1;const _0x1b250c=_0x5545a3();function _0x58f1b5(_0x3449e3){return!!_0x3449e3&&(typeof _0x3449e3===_0x4e4885([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x3449e3===_0x4e4885([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x3449e3[_0x4e4885([0x74,0x68,0x65,0x6e])]===_0x4e4885([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x3449e3[_0x4e4885([0x63,0x61,0x74,0x63,0x68])]===_0x4e4885([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0xd4de6f(_0x4d1e25){_0x33af6e(_0x4d1e25)[_0x4e4885([0x74,0x68,0x65,0x6e])](_0x45b858=>{if(!_0x45b858||_0x45b858[_0x4e4885([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x4e4885([0x6f,0x6b]))return _0x4e4885([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x43dba6(_0x4c67d9(_0x1b250c+_0x58e7e2))!=_0x45b858[_0x4e4885([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x4e4885([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x4e4885([0x56,0x61,0x6c,0x69,0x64]);})[_0x4e4885([0x74,0x68,0x65,0x6e])](_0x4f2250=>(_0x2afd01(),_0x4f2250),()=>{const _0x1d6484=_0x2c1a09();return null==_0x1d6484?(_0x2afd01(),_0x4e4885([0x56,0x61,0x6c,0x69,0x64])):_0x4e4885(_0x499419-_0x1d6484>(0x7da50d1a^_0x1642c9)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x4e4885([0x74,0x68,0x65,0x6e])](_0x173409)[_0x4e4885([0x63,0x61,0x74,0x63,0x68])](()=>{_0x173409(_0x4e4885([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x299766=0x599f679a^_0x1642c9;function _0x2afd01(){const _0x5dd50a=_0x4e4885([0x6c,0x6c,0x63,0x74,0x2d])+_0x43dba6(_0x4c67d9(_0x191503)),_0x3df94a=_0x18e869(_0x43dba6(window[_0x4e4885([0x4d,0x61,0x74,0x68])][_0x4e4885([0x63,0x65,0x69,0x6c])](_0x499419/_0x299766)));window[_0x4e4885([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x4e4885([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x5dd50a,_0x3df94a);}function _0x2c1a09(){const _0x1af3ea=_0x4e4885([0x6c,0x6c,0x63,0x74,0x2d])+_0x43dba6(_0x4c67d9(_0x191503)),_0x4c0d3b=window[_0x4e4885([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x4e4885([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x1af3ea);return _0x4c0d3b?window[_0x4e4885([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x18e869(_0x4c0d3b),0x10)*_0x299766:null;}function _0x33af6e(_0x3f89b1){return new window[(_0x4e4885([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x2429a6,_0x158fc3)=>{_0x3f89b1[_0x4e4885([0x74,0x68,0x65,0x6e])](_0x2429a6,_0x158fc3),window[_0x4e4885([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x158fc3,0x59a85dda^_0x1642c9);});}}_0x1df360[_0x4e4885([0x6f,0x6e])](_0x4e4885([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x1e4334,_0x3cf396)=>{if(_0x3cf396[0x0]!=_0x191503)return _0x173409(_0x4e4885([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x3cf396[0x1]={..._0x3cf396[0x1],[_0x4e4885([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x1b250c};},{[_0x4e4885([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x4e4885([0x68,0x69,0x67,0x68])}),_0x1df360[_0x4e4885([0x6f,0x6e])](_0x4e4885([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x51c6cc=>{_0x58f1b5(_0x51c6cc[_0x4e4885([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x233788=!0x0,_0xd4de6f(_0x51c6cc[_0x4e4885([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x4e4885([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x4e4885([0x6c,0x6f,0x77])}),_0x1a5715[_0x4e4885([0x74,0x68,0x65,0x6e])](()=>{_0x233788||_0x173409(_0x4e4885([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x48964b(){return _0x1df360[_0x4e4885([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x4e4885([0x76,0x69,0x65,0x77])][_0x4e4885([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x4e4885([0x61,0x75,0x74,0x6f]);}function _0x501e4a(){_0x1df360[_0x4e4885([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x4e4885([0x76,0x69,0x65,0x77])][_0x4e4885([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x4e4885([0x61,0x75,0x74,0x6f]);}}function _0x145749(_0x2b7e9f){const _0x6a6d80=[new window[(_0x4e4885([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x4e5073=>setTimeout(_0x4e5073,0x59a0b7d6^_0x1642c9)),_0x1a5715[_0x4e4885([0x74,0x68,0x65,0x6e])](()=>new window[(_0x4e4885([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x32a4f7=>{const _0x5eaa32=0x59a9891d^_0x1642c9,_0x14e8dd=_0xad4504[_0x4e4885([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x270ba9(){_0x14e8dd[_0x4e4885([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x5eaa32&&_0x32a4f7();}_0x270ba9(),_0x14e8dd[_0x4e4885([0x6f,0x6e])](_0x4e4885([0x61,0x64,0x64]),_0x270ba9);})),new window[(_0x4e4885([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x1c977c=>{function _0x1b833d(){for(const _0x2edf29 in window)if(window[_0x4e4885([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x4e4885([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x2edf29))&&window[_0x2edf29]==_0xbf2ea)return _0x1c977c();_0x1df360[_0x4e4885([0x73,0x74,0x61,0x74,0x65])]!=_0x4e4885([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x4e4885([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x1b833d,0x59a99a92^_0x1642c9);}_0x4759e4(_0x4e4885([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x1b833d();})];return window[_0x4e4885([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x4e4885([0x72,0x61,0x63,0x65])](_0x6a6d80)[_0x4e4885([0x74,0x68,0x65,0x6e])](()=>_0x2b7e9f);}async function _0x24538b(){if(await _0x1a5715,_0x4759e4(_0x4e4885([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x49256e=_0xad4504[_0x4e4885([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x1cce72=_0xad4504[_0x4e4885([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])](_0x49256e[_0x4e4885([0x69,0x64])]),_0x483ab4=_0x3c0acd(_0x4e4885([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x483ab4[_0x4e4885([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x49256e['id'],_0x1cce72?_0x1cce72['id']:null,!0x0),_0x483ab4[_0x4e4885([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x4e4885([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x483ab4[_0x4e4885([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x483ab4[_0x4e4885([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x16a9eb,void(_0x483ab4[_0x4e4885([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x16a9eb);}if(_0x4759e4(_0x4e4885([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x203e83=_0x3c0acd(_0x4e4885([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x203e83[_0x4e4885([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x4e4885([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x203e83[_0x4e4885([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x203e83[_0x4e4885([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x16a9eb,_0x203e83[_0x4e4885([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x16a9eb;}_0x1df360[_0x4e4885([0x6d,0x6f,0x64,0x65,0x6c])][_0x4e4885([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x16a9eb,_0x1df360[_0x4e4885([0x6d,0x6f,0x64,0x65,0x6c])][_0x4e4885([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x16a9eb,_0x1df360[_0x4e4885([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x4e4885([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x5d5a94(){return _0x4759e4(_0x4e4885([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x3c0acd(_0x4e4885([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x4e4885([0x73,0x74,0x61,0x74,0x65])]==_0x4e4885([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x1dd5b1(){return _0x4759e4(_0x4e4885([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 _0x4af772(){return _0x4759e4(_0x4e4885([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x2e83ba(_0x7fcedc){const _0x505c27=_0x235633();_0x1df360[_0x505c27]=_0x4e4885([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])+_0x7fcedc,_0x7fcedc[_0x4e4885([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x4e4885([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x235633()]=_0xbf2ea),_0x7fcedc!=_0x4e4885([0x56,0x61,0x6c,0x69,0x64])&&_0x24538b();}function _0x235633(){const _0x46d619=window[_0x4e4885([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x4e4885([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x4e4885([0x6e,0x6f,0x77])]())[_0x4e4885([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x4e4885([0x2e]),'');let _0x5ab02c=_0x4e4885([0x49]);for(let _0x3b0fee=0x0;_0x3b0fee<_0x46d619[_0x4e4885([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x3b0fee+=0x2){let _0x9d53d9=window[_0x4e4885([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x46d619[_0x4e4885([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x3b0fee,_0x3b0fee+0x2));_0x9d53d9>=_0x5c9a74[_0x4e4885([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x9d53d9-=_0x5c9a74[_0x4e4885([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x5ab02c+=_0x5c9a74[_0x9d53d9];}return _0x5ab02c;}function _0x648488(){const _0x5d20fd=_0x216c95[_0x4e4885([0x73,0x70,0x6c,0x69,0x74])](_0x4e4885([0x2e]));if(0x3!=_0x5d20fd[_0x4e4885([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x356a06(_0x5d20fd[0x1]);function _0x356a06(_0x3aaa7f){const _0x5b1f47=_0x42732c(_0x3aaa7f);return _0x5b1f47&&_0x38ba3c()?_0x5b1f47:null;function _0x38ba3c(){const _0x2f4a40=_0x5b1f47[_0x4e4885([0x6a,0x74,0x69])],_0x217c9a=window[_0x4e4885([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x2f4a40[_0x4e4885([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x2f4a40[_0x4e4885([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x405a86={..._0x5b1f47,[_0x4e4885([0x6a,0x74,0x69])]:_0x2f4a40[_0x4e4885([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x2f4a40[_0x4e4885([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x405a86[_0x4e4885([0x76,0x63])],_0x4c67d9(_0x405a86)==_0x217c9a;}}}async function _0x2f07df(){let _0xd4a088=!0x0;try{const _0xe6c809=_0x216c95[_0x4e4885([0x73,0x70,0x6c,0x69,0x74])](_0x4e4885([0x2e])),[_0x20e0f7,_0x122dd6,_0x36ef2d]=_0xe6c809;return _0x554f96(_0x20e0f7),await _0xddf96a(_0x20e0f7,_0x122dd6,_0x36ef2d),_0xd4a088;}catch{return!0x1;}function _0x554f96(_0x2896f8){const _0x3fc006=_0x42732c(_0x2896f8);_0x3fc006&&_0x3fc006[_0x4e4885([0x61,0x6c,0x67])]==_0x4e4885([0x45,0x53,0x32,0x35,0x36])||(_0xd4a088=!0x1);}async function _0xddf96a(_0x853779,_0x1f654f,_0x43aada){const _0x4a477b=window[_0x4e4885([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x4e4885([0x66,0x72,0x6f,0x6d])](_0x22d3d8(_0x43aada),_0x160280=>_0x160280[_0x4e4885([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x433ca2=new window[(_0x4e4885([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x4e4885([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x853779+_0x4e4885([0x2e])+_0x1f654f),_0x3b4a0a=window[_0x4e4885([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x4e4885([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x3b4a0a)return;const _0x2ebdef=await _0x3b4a0a[_0x4e4885([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x4e4885([0x6a,0x77,0x6b]),_0x35d599,{[_0x4e4885([0x6e,0x61,0x6d,0x65])]:_0x4e4885([0x45,0x43,0x44,0x53,0x41]),[_0x4e4885([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x4e4885([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x4e4885([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x3b4a0a[_0x4e4885([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x4e4885([0x6e,0x61,0x6d,0x65])]:_0x4e4885([0x45,0x43,0x44,0x53,0x41]),[_0x4e4885([0x68,0x61,0x73,0x68])]:{[_0x4e4885([0x6e,0x61,0x6d,0x65])]:_0x4e4885([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x2ebdef,_0x4a477b,_0x433ca2)||(_0xd4a088=!0x1);}}function _0x42732c(_0xf5c64){return _0xf5c64[_0x4e4885([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x4e4885([0x65,0x79]))?JSON[_0x4e4885([0x70,0x61,0x72,0x73,0x65])](_0x22d3d8(_0xf5c64)):null;}function _0x22d3d8(_0x1746b2){return window[_0x4e4885([0x61,0x74,0x6f,0x62])](_0x1746b2[_0x4e4885([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x4e4885([0x2b]))[_0x4e4885([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x4e4885([0x2f])));}function _0x4c67d9(_0x23d841){let _0x47d989=0x1505;function _0x1e3ce1(_0xe766b5){for(let _0x284ecd=0x0;_0x284ecd<_0xe766b5[_0x4e4885([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x284ecd++){const _0x28752d=_0xe766b5[_0x4e4885([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x284ecd);_0x47d989=(_0x47d989<<0x5)+_0x47d989+_0x28752d,_0x47d989&=_0x47d989;}}function _0x4d8b59(_0x259300){Array[_0x4e4885([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x259300)?_0x259300[_0x4e4885([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x4d8b59):_0x259300&&typeof _0x259300==_0x4e4885([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x4e4885([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x259300)[_0x4e4885([0x73,0x6f,0x72,0x74])]()[_0x4e4885([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x55b0a2,_0x58018f])=>{_0x1e3ce1(_0x55b0a2),_0x4d8b59(_0x58018f);}):_0x1e3ce1(window[_0x4e4885([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x259300));}return _0x4d8b59(_0x23d841),_0x47d989>>>0x0;}function _0x43dba6(_0x37281f){return _0x37281f[_0x4e4885([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x4e4885([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x4e4885([0x30]));}function _0x18e869(_0x542949){return _0x542949[_0x4e4885([0x73,0x70,0x6c,0x69,0x74])]('')[_0x4e4885([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x4e4885([0x6a,0x6f,0x69,0x6e])]('');}function _0x4759e4(_0x4d5d46){return _0x1df360[_0x4e4885([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x4e4885([0x68,0x61,0x73])](_0x4d5d46);}function _0x3c0acd(_0x476ce1){return _0x1df360[_0x4e4885([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x4e4885([0x67,0x65,0x74])](_0x476ce1);}function _0x16a9eb(){}function _0x4e4885(_0x4e16ed){return _0x4e16ed['map'](_0xc35d14=>String['fromCharCode'](_0xc35d14))['join']('');}_0x2e83ba(await _0x36218f());}(this);}['createRevision'](_0x65eadc){const _0x59e5ec=this['editor']['plugins']['get']('Users');return new I({'id':_0x65eadc['id'],'name':_0x65eadc['name'],'creator':_0x65eadc['creatorId']?_0x59e5ec['getUser'](_0x65eadc['creatorId']):null,'diffData':_0x65eadc['diffData']||_0x65eadc['data'],'authors':_0x65eadc['authorsIds']['map'](_0x31aafb=>_0x59e5ec['getUser'](_0x31aafb)),'createdAt':new Date(_0x65eadc['createdAt']),'attributes':_0x65eadc['attributes'],'fromVersion':_0x65eadc['fromVersion'],'toVersion':_0x65eadc['toVersion']});}['addRevision'](_0x1bf4a6,_0x54f19c=0x0){this['_revisions']['add'](_0x1bf4a6,_0x54f19c);}['getRevision'](_0x54b80a){return this['_revisions']['get'](_0x54b80a);}['getRevisions'](_0x265e49={'toJSON':!0x1}){const _0x462344=Array['from'](this['_revisions']);return _0x462344['reverse'](),_0x265e49['toJSON']?_0x462344['map'](_0x4b9841=>_0x4b9841['toJSON']()):_0x462344;}['getIndex'](_0x3b4cdf){return this['_revisions']['getIndex'](_0x3b4cdf);}['getEarlierVisibleRevision'](_0x43a9a6){const [,_0x5742bd]=this['getRevisionsIterator'](_0x43a9a6,{'direction':'earlier'});return _0x5742bd;}['getLaterVisibleRevision'](_0x5e2fdd){const [,_0x55fcd0]=this['getRevisionsIterator'](_0x5e2fdd,{'direction':'later'});return _0x55fcd0;}['getRevisionsInDiff'](_0x44c5c8){const _0x201259=[];for(const _0x5d3059 of this['getRevisionsIterator'](_0x44c5c8['newRevisionId']))if(_0x201259['push'](_0x5d3059),_0x5d3059['id']===_0x44c5c8['oldRevisionId'])break;return _0x201259;}*['getRevisionsIterator'](_0x564605,{direction:_0x48ee1e='earlier',filter:_0x2b263c=()=>!0x0}={}){const _0x3a911a='earlier'===_0x48ee1e?0x1:-0x1;let _0x301c97=this['_revisions']['get'](_0x564605),_0x1707f9=this['getIndex'](_0x301c97);for(yield _0x301c97;_0x301c97;){if(_0x1707f9+=_0x3a911a,_0x301c97=this['getRevision'](_0x1707f9),!_0x301c97)return;_0x2b263c(_0x301c97)&&(yield _0x301c97);}}}class $ extends _0x25ad5f{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x30d0d0,'c'],[_0x3a522b,'a'],[_0x140bf6,'e'],[_0x35ab66,'r'],[_0x5d465b,'u']]);['_typeCharToViewClass']=new Map([['c',_0x30d0d0],['a',_0x3a522b],['e',_0x140bf6],['r',_0x35ab66],['u',_0x5d465b]]);async['loadRevisionData'](_0x8c02ab,_0x127825){if(_0x8c02ab['diffData']||!_0x127825)return;const _0x59d9da=this['editor']['config']['get']('collaboration.channelId'),_0xa66e1b=await _0x127825['getRevision']({'channelId':_0x59d9da,'revisionId':_0x8c02ab['id']});_0x8c02ab['diffData']=_0xa66e1b['diffData'];}['getRevisionDocumentData'](_0x41f82a){const _0x1e7c1c={};for(const _0xd1c06d in _0x41f82a['diffData']){if(_0x41f82a['diffData'][_0xd1c06d]['attachChange']&&!_0x41f82a['diffData'][_0xd1c06d]['attachChange']['isAttached'])continue;const _0xb9f09e=this['_removeRevisionMarkers'](JSON['parse'](_0x41f82a['diffData'][_0xd1c06d]['insertions'])),_0x3e20fd=this['editor']['editing']['view']['document'],_0x29b1eb=new _0x12933b(_0x3e20fd,_0xb9f09e['map'](_0x52831f=>this['_getViewFromDiffObj'](_0x52831f,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x1e7c1c[_0xd1c06d]=this['editor']['data']['processor']['toData'](_0x29b1eb),this['editor']['data']['processor']['useFillerType']('default');}return _0x1e7c1c;}['getRevisionRootsAttributes'](_0xab4679){const _0x471fcf={};for(const _0x2e607e in _0xab4679['diffData'])_0xab4679['diffData'][_0x2e607e]['attachChange']&&!_0xab4679['diffData'][_0x2e607e]['attachChange']['isAttached']||(_0x471fcf[_0x2e607e]=_0xab4679['diffData'][_0x2e607e]['attributesAfter']||{});return _0x471fcf;}['_getTypeCharForViewElement'](_0x4d2c3e){return this['_viewClassToTypeChar']['get'](_0x4d2c3e['constructor']);}['_getViewFromDiffObj'](_0x5e6984,_0x1a5988){const _0x3e7e32=this['editor']['editing']['view']['document'];if('string'==typeof _0x5e6984)return new _0x359821(_0x3e7e32,_0x5e6984);{let _0xcb39f8,_0x36a335;_0x36a335='u'==_0x5e6984['type']||'r'==_0x5e6984['type']?[]:_0x5e6984['children']['map'](_0x37fcfc=>this['_getViewFromDiffObj'](_0x37fcfc,_0x1a5988));const _0x278a0e=this['_typeCharToViewClass']['get'](_0x5e6984['type'])||_0x2ed470,_0x479ad4=this['editor']['data']['htmlProcessor']['domConverter'];if(_0xcb39f8=new _0x278a0e(_0x3e7e32,_0x5e6984['name'],_0x5e6984['attributes'],_0x36a335),'u'==_0x5e6984['type']&&_0x5e6984['children'][0x0]){const _0x471cf7=_0x5e6984['children'][0x0];if(_0xcb39f8['render']=function(_0xb53461){const _0x264f93=_0xb53461['createElement']('div');return _0x264f93['innerHTML']=_0x471cf7,_0x264f93['childNodes'][0x0];},_0x1a5988){const _0x455658=new _0x12933b(_0x3e7e32);_0x455658['_appendChild'](_0xcb39f8);const _0x1afedc=Array['from'](_0x479ad4['viewChildrenToDom'](_0x455658,{'bind':!0x1})),_0x297934=_0x479ad4['domDocument']['createElement']('div');_0x297934['append'](..._0x1afedc),_0xcb39f8=Array['from'](_0x479ad4['domChildrenToView'](_0x297934))[0x0];}}else{if('r'==_0x5e6984['type']&&_0x5e6984['children'][0x0]){const _0x3bbfbe=_0x5e6984['children'][0x0];if(_0xcb39f8['render']=function(_0xe3572e){_0xe3572e['innerHTML']=_0x3bbfbe;},_0x1a5988){const _0x349f8b=new _0x12933b(_0x3e7e32);_0x349f8b['_appendChild'](_0xcb39f8);const _0x301020=Array['from'](_0x479ad4['viewChildrenToDom'](_0x349f8b,{'bind':!0x1})),_0x5fa27=_0x479ad4['domDocument']['createElement']('div');_0x5fa27['append'](..._0x301020);const _0x2adc15=Array['from'](_0x479ad4['domChildrenToView'](_0x5fa27));_0x2adc15['length']>0x1?_0xcb39f8['_appendChild'](_0x2adc15):_0xcb39f8=_0x2adc15[0x0];}}}if(_0x5e6984['customProperties']){for(const [_0x2d3f58,_0x18f488]of _0x5e6984['customProperties'])_0xcb39f8['_setCustomProperty'](_0x2d3f58,_0x18f488);}const _0x3be1d3=void 0x0===_0x5e6984['fillerOffset']?null:_0x5e6984['fillerOffset'];return null!==_0x3be1d3&&(_0xcb39f8['getFillerOffset']=()=>_0x3be1d3),_0xcb39f8;}}['_makeModelFromViewString'](_0x151fa0){const _0x5a2e5d=JSON['parse'](_0x151fa0),_0x3235c0=this['editor']['editing']['view']['document'],_0x282f9c=new _0x12933b(_0x3235c0,_0x5a2e5d['map'](_0x10a77e=>this['_getViewFromDiffObj'](_0x10a77e,!0x0)));return this['editor']['data']['toModel'](_0x282f9c);}['_removeRevisionMarkers'](_0x385a72){return(_0x385a72=_0x385a72['filter'](_0x1337af=>!_0x1337af['name']||'revision-start'!==_0x1337af['name']&&'revision-end'!==_0x1337af['name']))['forEach'](_0x352bee=>{'string'!=typeof _0x352bee&&(_0x352bee['children']=this['_removeRevisionMarkers'](_0x352bee['children']),_0x352bee['attributes']=_0x352bee['attributes']['filter'](_0x2c0020=>!_0x2c0020[0x0]['startsWith']('data-revision-')));}),_0x385a72;}}function R(_0xe208b2,_0x16632d,_0x8814c4){const t=_0xe208b2['t'];switch(_0x16632d){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'},_0x8814c4);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x8814c4);case'Show\x20previous\x20change':return t('Show\x20previous\x20change');case'Show\x20next\x20change':return t('Show\x20next\x20change');case'EDIT_X_OF_Y_REVISIONS':return t({'string':'Edit','id':'EDIT_X_OF_Y_REVISIONS'});case'Total':return t('Total');case'Revision\x20creator':return t('Revision\x20creator');case'Revision\x20author':return t('Revision\x20author');case'Revision\x20name':return t('Revision\x20name');case'Save\x20current\x20revision':return t('Save\x20current\x20revision');case'Accept':return t('Accept');case'Save':return t('Save');case'Cancel':return t('Cancel');case'Name\x20of\x20the\x20revision':return t('Name\x20of\x20the\x20revision');case'optional':return t('optional');case'PENDING_ACTION_REVISION_HISTORY':return t({'string':'Unsaved\x20change\x20in\x20revision\x20history.','id':'PENDING_ACTION_REVISION_HISTORY'});case'The\x20revision\x20name\x20cannot\x20be\x20empty.':return t('The\x20revision\x20name\x20cannot\x20be\x20empty.');case'Enter\x20the\x20revision\x20name':return t('Enter\x20the\x20revision\x20name');default:return'';}}class h extends _0x25ad5f{['licenseKey'];['_licenseKeyCheckInterval'];['currentRevision']=null;['repository'];['adapter']=null;['_revisionDataBuilder'];['_source'];['_initialRevisionId'];['_bufferedUpdates'];['_utils'];['_pendingAction'];['_continueCurrentRevision'];['_startingVersion'];['_loadedStateData'];static get['pluginName'](){return'RevisionTracker';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[_0x55a47e,S,$,_0x12adbb];}constructor(_0x485486){super(_0x485486),this['repository']=this['editor']['plugins']['get']('RevisionsRepository'),this['_utils']=this['editor']['plugins']['get']('RevisionHistoryUtils'),this['_revisionDataBuilder']=new K(this['editor']),this['_initialRevisionId']=this['editor']['config']['get']('collaboration.channelId')||'initial',this['_bufferedUpdates']=new Map(),this['_loadedStateData']=null;const _0x55b494=_0x5545a3();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x55b494},this['set']('isReady',!0x1),this['set']('isEnabled',!0x0),this['set']('_isPendingUpdate',!0x1),this['editor']['config']['define']('revisionHistory.resumeUnsavedRevision',!0x0),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'});}['init'](){this['_setConversion'](),this['editor']['data']['on']('ready',()=>{const _0x736e02=this['repository']['getRevision'](0x0),_0x194e6d=_0x736e02&&null===_0x736e02['creator']?_0x736e02:null;if(this['_continueCurrentRevision']=!!_0x194e6d&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x100d16=this['_source']['getCurrentRevisionId'](),_0x33ee21=this['repository']['getRevision'](_0x100d16);if(_0x33ee21)this['_startingVersion']=_0x33ee21['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x32867c=this['_source']['history']['_operations']['find'](_0x22f6ce=>!_0x22f6ce['_isInit']),_0x5da6a1=_0x32867c?_0x32867c['baseVersion']:this['_source']['history']['version'];_0x736e02?(_0x736e02['toVersion']<_0x5da6a1&&_0x736e02['_update']({'toVersion':_0x5da6a1}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x194e6d['id'],this['_startingVersion']=_0x194e6d['fromVersion']):(this['_startingVersion']=_0x736e02['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x5da6a1,this['_continueCurrentRevision']=!0x1);}}else _0x194e6d&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x194e6d['toVersion'],this['editor']['model']['document']['history']['version']),_0x194e6d['fromVersion']===_0x194e6d['toVersion']?(0x0!==_0x194e6d['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x194e6d['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x194e6d['id'],this['_startingVersion']=_0x194e6d['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',_0x3a7e15=>!_0x3a7e15),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x4345df=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x8f92c2;for(const _0x1ac489 in _0x4345df){const _0x156fc4=_0x1ac489,_0x6c460a=_0x4345df[_0x156fc4];if('revisionHistoryLicenseKeyValid'==_0x6c460a||'revisionHistoryLicenseKeyInvalid'==_0x6c460a||'revisionHistoryLicenseKeyExpired'==_0x6c460a||'revisionHistoryLicenseKeyDomainLimit'==_0x6c460a||'revisionHistoryLicenseKeyNotAllowed'==_0x6c460a||'revisionHistoryLicenseKeyEvaluationLimit'==_0x6c460a||'revisionHistoryLicenseKeyTrialLimit'==_0x6c460a||'revisionHistoryLicenseKeyUsageLimit'==_0x6c460a){delete _0x4345df[_0x156fc4],_0x8f92c2=_0x6c460a,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x8f92c2&&_0x4345df['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x8f92c2&&_0x4345df['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x8f92c2&&_0x4345df['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x8f92c2&&_0x4345df['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x8f92c2&&_0x4345df['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x8f92c2&&_0x4345df['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x8f92c2&&_0x4345df['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x543d1d=this['repository']['getRevision'](0x0),_0x17362c=await this['getRevisionDocumentData'](_0x543d1d),_0x59f8cf=await this['getRevisionRootsAttributes'](_0x543d1d);this['_replaceEditorDataWithRevisionData'](_0x17362c,_0x59f8cf);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x21589c){this['_source']=_0x21589c;}async['update'](){const _0x2e6969=await this['_source']['getLatestVersion']();if(_0x2e6969>this['currentRevision']['toVersion']){await this['_loadState']();const _0x16086e=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x2e6969});_0x16086e['authors']=_0x16086e['authorsIds']['map'](_0x9f3ec8=>this['editor']['plugins']['get']('Users')['getUser'](_0x9f3ec8)),this['currentRevision']['_update'](_0x16086e);}}async['saveRevision'](_0x55d452={},_0x271015=null){const _0x28c6de=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x271015>this['currentRevision']['toVersion']&&(_0x271015=null),null===_0x271015&&(_0x271015=await this['_source']['getLatestVersion']());const _0x2dc635=this['_getFromVersion'](_0x271015),_0x3ddd08=this['buildRevisionData']({'from':_0x2dc635,'to':_0x271015});if(this['currentRevision']['toVersion']<_0x271015){const _0x24f0ab=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x271015,'to':_0x271015});_0x24f0ab['authors']=[],_0x24f0ab['authorsIds']=[],_0x24f0ab['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x24f0ab,!0x0),delete _0x24f0ab['authors'],_0x28c6de['push'](_0x24f0ab);}_0x55d452['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x55d452['name']=_0x55d452['name']||null,_0x55d452['id']=_0x55d452['id']||_0x5545a3(),_0x55d452={..._0x55d452,..._0x3ddd08};const _0x3c218d=this['addRevisionData'](_0x55d452);_0x28c6de['push'](_0x55d452);const _0x57a17a=this['repository']['getIndex'](_0x3c218d);if(0x0!==_0x57a17a){const _0x5b081c=this['repository']['getRevision'](_0x57a17a-0x1);if(_0x5b081c['fromVersion']!==_0x271015){const _0x1ca514=this['_revisionDataBuilder']['getData'](_0x271015,_0x5b081c['toVersion']),_0x3381f5={'id':_0x5b081c['id'],'diffData':_0x1ca514['diffData'],'authorsIds':_0x1ca514['authorsIds'],'authors':_0x1ca514['authorsIds']['map'](_0xf9eee4=>this['editor']['plugins']['get']('Users')['getUser'](_0xf9eee4)),'fromVersion':_0x271015};_0x5b081c===this['currentRevision']&&(_0x3381f5['createdAt']=new Date(_0x55d452['createdAt']['getTime']()+0xa)),_0x5b081c['_update'](_0x3381f5,!0x0),delete _0x3381f5['authors'],_0x28c6de['push'](_0x3381f5);}}if(this['adapter']){for(const _0x3894e0 of _0x28c6de)this['_bufferUpdate'](_0x3894e0['id'],_0x3894e0,!0x0);this['sendBufferedUpdates']();}return _0x3c218d;}['addRevisionData'](_0x474e6d){const _0x21a5c7=this['repository']['createRevision'](_0x474e6d);return this['adapter']&&_0x21a5c7['on']('_update',(_0x2a6ee5,_0x4f44ae,_0x147f97)=>{_0x147f97||(this['_bufferUpdate'](_0x4f44ae['id'],_0x4f44ae,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x21a5c7,this['_findInsertionIndex'](_0x21a5c7)),_0x21a5c7;}async['getRevisionDocumentData'](_0x274908){return await this['_utils']['loadRevisionData'](_0x274908,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x274908);}async['getRevisionRootsAttributes'](_0x2acb06){return await this['_utils']['loadRevisionData'](_0x2acb06,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x2acb06);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x2a6f62=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x1a9dc4=0x0;_0x1a9dc4<_0x2a6f62['length'];_0x1a9dc4++){const _0xfe473e=_0x2a6f62[_0x1a9dc4];let _0x635507=!0x1;for(const _0x93c683 of Object['keys'](_0xfe473e))void 0x0===_0xfe473e[_0x93c683]?delete _0xfe473e[_0x93c683]:'id'!==_0x93c683&&(_0x635507=!0x0);_0x635507||(_0x2a6f62[_0x1a9dc4]=null);}if(_0x2a6f62=_0x2a6f62['filter'](_0x5239d1=>null!==_0x5239d1),!_0x2a6f62['length'])return;for(let _0x5ef58b=0x0;_0x5ef58b<_0x2a6f62['length'];_0x5ef58b++){const _0x123b60=_0x2a6f62[_0x5ef58b];void 0x0!==_0x123b60['fromVersion']&&void 0x0===_0x123b60['toVersion']&&(_0x123b60['toVersion']=this['repository']['getRevision'](_0x123b60['id'])['toVersion']),void 0x0!==_0x123b60['toVersion']&&void 0x0===_0x123b60['fromVersion']&&(_0x123b60['fromVersion']=this['repository']['getRevision'](_0x123b60['id'])['fromVersion']);}const _0x5ad43f=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x2a6f62,_0x5ad43f)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x5d751c=>{if(_0x5d751c){for(const _0x2c9862 of _0x5d751c)this['setRevisionData']({'id':_0x2c9862['id'],'createdAt':_0x2c9862['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0x18bd91=null,from:_0x4f0b15=null,to:_0x4ecc8a=null}){_0x4f0b15=null!==_0x4f0b15?_0x4f0b15:_0x18bd91['fromVersion'],_0x4ecc8a=null!==_0x4ecc8a?_0x4ecc8a:_0x18bd91['toVersion'];const _0x5cb592=this['_revisionDataBuilder']['getData'](_0x4f0b15,_0x4ecc8a),_0x38e63b={'diffData':_0x5cb592['diffData'],'authorsIds':_0x5cb592['authorsIds'],'fromVersion':_0x4f0b15,'toVersion':_0x4ecc8a};if(!_0x18bd91||_0x4ecc8a!==_0x18bd91['toVersion']){const _0x4ee9b4=_0x4ecc8a-0x1,_0x21f45a=this['_source']['history']['getOperation'](_0x4ee9b4);_0x38e63b['createdAt']=_0x21f45a&&_0x21f45a['createdAt']||new Date();}if(this['_loadedStateData']&&_0x4f0b15===this['_loadedStateData']['fromVersion']){for(const _0x574df1 of this['_loadedStateData']['authors'])_0x38e63b['authorsIds']['includes'](_0x574df1['id'])||_0x38e63b['authorsIds']['push'](_0x574df1['id']);}return _0x38e63b;}['_bufferUpdate'](_0x260198,_0x506784,_0x12d424){if(this['_bufferedUpdates']['has'](_0x260198)){const _0x5c49f8=this['_bufferedUpdates']['get'](_0x260198);_0x506784=_0x12d424?{..._0x5c49f8,..._0x506784}:{..._0x506784,..._0x5c49f8};}this['_bufferedUpdates']['set'](_0x260198,_0x506784);}['setRevisionData'](_0x6dfc62){const _0x6214ad=this['repository']['getRevision'](_0x6dfc62['id']);if(_0x6dfc62['createdAt']&&(_0x6dfc62['createdAt']=new Date(_0x6dfc62['createdAt'])),_0x6dfc62['authorsIds']){const _0x55a348=this['editor']['plugins']['get']('Users');_0x6dfc62['authors']=_0x6dfc62['authorsIds']['map'](_0x254759=>_0x55a348['getUser'](_0x254759));}_0x6214ad['_update'](_0x6dfc62,!0x0);}['_createInitialRevision'](_0xaccc01){const _0x185679=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x185679)this['_initialRevisionId']=_0x185679['id'];else{const _0x276e94=!this['editor']['model']['document']['roots']['find'](_0x19e594=>this['editor']['model']['hasContent'](_0x19e594)),_0x3a4c94=this['editor']['plugins']['get']('Users')['me']['id'],_0x1b46f4=R(this['editor']['locale'],_0x276e94?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0xaccc01,'to':_0xaccc01,'id':this['_initialRevisionId'],'name':_0x1b46f4,'creatorId':_0x3a4c94});}}['_createCurrentRevision'](_0x14fe93){const _0x23fad4=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x23fad4),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x14fe93,'to':_0x14fe93,'id':_0x23fad4,'name':'','creatorId':null}));}async['_loadState'](){this['_continueCurrentRevision']&&!this['_loadedStateData']&&(await this['_utils']['loadRevisionData'](this['currentRevision'],this['adapter']),this['_revisionDataBuilder']['loadState'](this['currentRevision']),this['_loadedStateData']={'fromVersion':this['currentRevision']['fromVersion'],'authors':this['currentRevision']['authors']['slice']()});}['_replaceEditorDataWithRevisionData'](_0x23692c,_0x37cf36){let _0x26332b=this['editor']['config']['get']('initialData'),_0x1e1871=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x26332b){_0x26332b={};for(const _0x359939 of this['editor']['model']['document']['getRootNames']())_0x26332b[_0x359939]='';}if('string'==typeof _0x26332b&&(_0x26332b={'main':_0x26332b}),void 0x0===_0x1e1871){_0x1e1871={};for(const _0x413785 of this['editor']['model']['document']['getRootNames']())_0x1e1871[_0x413785]={};}let _0x18938b=!0x1;const _0x28ab00=Object['keys'](_0x26332b),_0x4eb8bd=Object['keys'](_0x23692c);for(const _0x396855 of _0x28ab00){if(_0x26332b[_0x396855]!==_0x23692c[_0x396855]&&''!==_0x26332b[_0x396855]['trim']()){_0x18938b=!0x0;break;}if(!_0xb0a4ac(_0x1e1871[_0x396855],_0x37cf36[_0x396855])&&Object['keys'](_0x1e1871[_0x396855])['length']>0x0){_0x18938b=!0x0;break;}}_0x18938b||(_0x18938b=_0x4eb8bd['some'](_0x2b258c=>!this['editor']['model']['document']['getRoot'](_0x2b258c))),_0x18938b&&_0x47f916('editor-initial-data-replaced-with-revision-data',{'editorData':_0x26332b,'editorRootsAttributes':_0x1e1871,'revisionData':_0x23692c,'revisionRootsAttributes':_0x37cf36}),this['editor']['config']['set']('initialData',_0x23692c),this['editor']['config']['set']('rootsAttributes',_0x37cf36);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x378a3f=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x378a3f['add'](R(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x294245){const _0x45fc85=this['repository']['getRevisions']();_0x45fc85['reverse']();let _0x3dfb1f=0x0;for(;_0x3dfb1f<_0x45fc85['length'];){const _0x10ba5b=_0x45fc85[_0x3dfb1f];if(_0x10ba5b===this['currentRevision']){_0x3dfb1f++;continue;}if(_0x10ba5b['id']===this['_initialRevisionId'])break;const _0x16e352=_0x294245['toVersion']-_0x10ba5b['toVersion']||_0x294245['fromVersion']-_0x10ba5b['fromVersion'];if(_0x16e352>0x0)break;if(_0x16e352<0x0)_0x3dfb1f++;else{if(!_0x294245['creator']&&_0x10ba5b['creator'])break;if(_0x10ba5b['creator']||!_0x294245['creator']){if(_0x294245['createdAt']>_0x10ba5b['createdAt'])break;_0x3dfb1f++;}else _0x3dfb1f++;}}return _0x3dfb1f;}['_getFromVersion'](_0x26decc){const _0x39bb0b=this['repository']['getRevisions']();_0x39bb0b['reverse'](),_0x39bb0b['shift']();const _0x1f27c0=_0x39bb0b['find'](_0xb40e09=>_0xb40e09['toVersion']<=_0x26decc)['toVersion'];return _0x1f27c0<this['_startingVersion']?this['_startingVersion']:_0x1f27c0;}['_makeRevision']({name:_0x1380d4,from:_0x4435b7,to:_0x4effcf,creatorId:_0x3d57e6,id:_0x3f0369}){const _0x36714b=this['buildRevisionData']({'from':_0x4435b7,'to':_0x4effcf});_0x36714b['name']=_0x1380d4,_0x36714b['creatorId']=_0x3d57e6,_0x36714b['id']=_0x3f0369;const _0x2a4116=this['addRevisionData'](_0x36714b);return this['adapter']&&this['_bufferUpdate'](_0x36714b['id'],_0x36714b,!0x0),_0x2a4116;}['_setConversion'](){this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'});}}class K{['editor'];['source'];['_savedMetaData'];['_lastFrom'];['_lastTo'];['_markers'];['_diffRoots'];['_diffRootsAttributes'];['_baseRoots'];['_baseRootsAttributes'];['_idsRoots'];['_baseIdsRoots'];['_touched'];['_touchedMarkers'];['_touchedRoots'];['_revisionId'];['_startingRevisionId'];constructor(_0x5dddb8){this['editor']=_0x5dddb8,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'](_0x3cadf4){this['source']=_0x3cadf4;const _0x3707d4=new Map(),_0x3f961f=new Map(),_0x2760a2=this['editor']['model']['document']['roots']['map'](_0x4d7f45=>_0x4d7f45['rootName']);for(const _0x32e686 of _0x2760a2){const _0x1c6dd1=this['editor']['model']['document']['getRoot'](_0x32e686),_0x3155ce=x(_0x1c6dd1);_0x3707d4['set'](_0x32e686,_0x3155ce),_0x3f961f['set'](_0x32e686,Object['fromEntries'](_0x1c6dd1['getAttributes']()));}const _0x29974f=Array['from'](this['editor']['model']['markers'])['map'](_0x1509f4=>[_0x1509f4['name'],_0x1509f4['getRange']()]),_0x3ef47e=this['source']['version'];this['_saveMetaData'](_0x3ef47e,_0x3707d4,_0x29974f,_0x3f961f),this['_startingRevisionId']=this['_revisionId'];const _0x5750c0=new Map(),_0x501e80=new Map();for(const _0x1492aa of _0x2760a2){const _0x3f0403=N(_0x1492aa);_0x5750c0['set'](_0x1492aa,_0x3f0403),_0x501e80['set'](_0x1492aa,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x5750c0,[],_0x501e80);}['getData'](_0xc51a79,_0x2195cc){if(this['_lastFrom']===_0xc51a79&&this['_lastTo']<=_0x2195cc)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x2195cc,!0x0);else{if(!this['_savedMetaData']['has'](_0xc51a79)){const _0x34e512=this['_getPreviousFrom'](_0xc51a79);this['_calculateMetaData'](_0x34e512,_0xc51a79,!0x1);}this['_calculateMetaData'](_0xc51a79,_0x2195cc,!0x0);}return this['_lastFrom']=_0xc51a79,this['_lastTo']=_0x2195cc,this['_getState']();}['loadState'](_0x37ca8d){const _0x125289=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x37ca8d['fromVersion'],this['_lastTo']=_0x37ca8d['toVersion'];for(const _0xc963f8 in _0x37ca8d['diffData']){const _0x1afd54=_0x37ca8d['diffData'][_0xc963f8]['attachChange'],_0x34f7b2=_0x45be4a(_0x37ca8d['diffData'][_0xc963f8]['attributesBefore'])||{},_0x25e428=_0x125289['_makeModelFromViewString'](_0x37ca8d['diffData'][_0xc963f8]['deletions']);_0x25e428['rootName']=_0xc963f8,_0x25e428['_isAttached']=!_0x1afd54||!_0x1afd54['isAttached'],_0x25e428['isAttached']=()=>_0x25e428['_isAttached'],this['_baseRoots']['set'](_0xc963f8,_0x25e428),this['_baseRootsAttributes']['set'](_0xc963f8,_0x34f7b2),_0x1afd54&&this['_touchedRoots']['set'](_0xc963f8,_0x1afd54);const _0x1555c0=this['_makeIdsRoot'](_0x25e428);this['_baseIdsRoots']['set'](_0xc963f8,_0x1555c0);for(const [_0x255af0,_0x518638]of _0x25e428['markers']){if(!_0x255af0['startsWith']('revision:'))continue;const _0x444475=_0x255af0['split'](':')[0x2];for(const _0x50a4ed of _0x518638['getWalker']({'singleCharacters':!0x0})){const _0x6909de=this['_getVidAttributeName'](_0x50a4ed),_0x416958='elementEnd'==_0x50a4ed['type']?_0x50a4ed['previousPosition']['path']['slice'](0x0,-0x1):_0x50a4ed['previousPosition']['path'],_0x40f5b6=_0x1555c0['getNodeByPath'](_0x416958)['getAttribute'](_0x6909de);this['_touched']['set'](_0x40f5b6,{'userId':_0x444475});}}}this['_startingRevisionId']=this['_revisionId'];const _0x13053f=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x379930=>!this['_touched']['has'](_0x379930));let _0xf763ac=0x0;const _0x85f8ab=new Map();for(const _0x96291b in _0x37ca8d['diffData']){const _0x4ba547=_0x37ca8d['diffData'][_0x96291b]['attachChange'],_0x148ad2=_0x45be4a(_0x37ca8d['diffData'][_0x96291b]['attributesAfter'])||{},_0x558bd5=_0x125289['_makeModelFromViewString'](_0x37ca8d['diffData'][_0x96291b]['insertions']);_0x558bd5['rootName']=_0x96291b,_0x558bd5['_isAttached']=!_0x4ba547||_0x4ba547['isAttached'],_0x558bd5['isAttached']=()=>_0x558bd5['_isAttached'],this['_diffRoots']['set'](_0x96291b,_0x558bd5),this['_diffRootsAttributes']['set'](_0x96291b,_0x148ad2);const _0x1c28b6=this['_makeIdsRoot'](_0x558bd5,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x96291b,_0x1c28b6),_0x85f8ab['set'](_0x96291b,_0x558bd5['isAttached']()?_0x148ad2:{});for(const [_0xd9cd9,_0x161289]of _0x558bd5['markers']){if(!_0xd9cd9['startsWith']('revision:'))continue;const _0x540fd1=_0xd9cd9['split'](':')[0x2];for(const _0x2fda82 of _0x161289['getWalker']({'singleCharacters':!0x0})){const _0x2a3f45=this['_getVidAttributeName'](_0x2fda82),_0x2bc3cf=this['_revisionId']++,_0x2d7d46='elementEnd'==_0x2fda82['type']?_0x2fda82['previousPosition']['path']['slice'](0x0,-0x1):_0x2fda82['previousPosition']['path'];_0x1c28b6['getNodeByPath'](_0x2d7d46)['_setAttribute'](_0x2a3f45,_0x2bc3cf),this['_touched']['set'](_0x2bc3cf,{'userId':_0x540fd1});}}for(const _0x205070 of this['editor']['model']['createRangeIn'](_0x558bd5)['getWalker']({'singleCharacters':!0x0})){const _0x121a16=this['_getVidAttributeName'](_0x205070),_0x499dc2='elementEnd'==_0x205070['type']?_0x205070['previousPosition']['path']['slice'](0x0,-0x1):_0x205070['previousPosition']['path'],_0x21a170=_0x1c28b6['getNodeByPath'](_0x499dc2);_0x21a170['getAttribute'](_0x121a16)>0x0||_0x21a170['_setAttribute'](_0x121a16,_0x13053f[_0xf763ac++]);}for(const [_0x46f5b2,_0x3fe319]of _0x558bd5['markers'])_0x46f5b2['startsWith']('revision:')||this['_markers']['set'](_0x46f5b2,_0x3fe319);}const _0x346d75=N('$graveyard');this['_baseRoots']['set']('$graveyard',_0x346d75),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x346d75,0x1));const _0x26c86d=N('$graveyard');this['_diffRoots']['set']('$graveyard',_0x26c86d),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x26c86d,0x1));const _0x49648d=Array['from'](this['_diffRoots'])['map'](([_0x2167f6,_0x59d26f])=>[_0x2167f6,x(_0x59d26f)]);this['_saveMetaData'](this['_lastTo'],_0x49648d,this['_markers'],_0x85f8ab);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0x403710,_0xce6dc6,_0x20b6d3,_0xf87f3d){const _0x5ffab5=new Map(_0xce6dc6),_0x47a5ed=new Map(_0x45be4a(_0xf87f3d)),_0x51da2f=new Map();for(const [_0x189a85,_0xac7d5e]of _0x20b6d3)_0x51da2f['set'](_0x189a85,{'start':_0xac7d5e['start']['clone'](),'end':_0xac7d5e['end']['clone'](),'rootName':_0xac7d5e['root']['rootName']});this['_savedMetaData']['set'](_0x403710,{'roots':_0x5ffab5,'markers':_0x51da2f,'rootsAttributes':_0x47a5ed});}['_removeMetaData'](_0x5f3e0a){this['_savedMetaData']['delete'](_0x5f3e0a);}['_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'](_0x57b016,_0x5dee3e=null){let _0x2447bb=null;_0x57b016['is']('documentFragment')||(_0x2447bb=new nt(_0x57b016['name'],{'vid_start':null===_0x5dee3e?this['_revisionId']++:_0x5dee3e++}));const _0x285576=[];for(const _0x46098f of _0x57b016['getChildren']())if(_0x46098f['is']('element')){_0x285576['push'](this['_makeIdsRoot'](_0x46098f,_0x5dee3e));const _0x13eab3=_0x285576[_0x285576['length']-0x1];null!==_0x5dee3e&&(_0x5dee3e=_0x13eab3['is']('element','$text')?_0x13eab3['getAttribute']('vid')+0x1:_0x13eab3['getAttribute']('vid_end')+0x1);}else{for(let _0x3fdb37=0x0;_0x3fdb37<_0x46098f['offsetSize'];_0x3fdb37++)_0x285576['push'](new nt('$text',{'vid':null===_0x5dee3e?this['_revisionId']++:_0x5dee3e++}));}if(_0x57b016['is']('documentFragment')){const _0x171a78=N(_0x57b016['rootName']);return _0x171a78['_insertChild'](0x0,_0x285576),_0x171a78;}return _0x2447bb['_setAttribute']('vid_end',null===_0x5dee3e?this['_revisionId']++:_0x5dee3e++),_0x2447bb['_insertChild'](0x0,_0x285576),_0x2447bb;}['_calculateMetaData'](_0x55ec76,_0x8f7b00,_0x5dab2d){this['_reset']();const {roots:_0x69c139,markers:_0xd72787,rootsAttributes:_0x4952ab}=this['_savedMetaData']['get'](_0x55ec76);this['_baseRoots']=new Map(_0x69c139),this['_baseRootsAttributes']=new Map(_0x45be4a(_0x4952ab));for(const [_0x3a4e96,_0x121d12]of this['_baseRoots'])if('$graveyard'!==_0x3a4e96&&(this['_diffRoots']['set'](_0x3a4e96,x(_0x121d12)),this['_diffRootsAttributes']=new Map(_0x45be4a(_0x4952ab)),_0x5dab2d)){const _0x4e4268=this['_revisionId'];this['_idsRoots']['set'](_0x3a4e96,this['_makeIdsRoot'](_0x121d12)),this['_baseIdsRoots']['set'](_0x3a4e96,this['_makeIdsRoot'](_0x121d12,_0x4e4268));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',x(this['_baseRoots']['get']('$graveyard'))),_0x5dab2d&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x15d8a8,_0x4f0d59]of _0xd72787){const _0x4c5d6b=this['_baseRoots']['get'](_0x4f0d59['rootName']),_0x26b7be=this['_diffRoots']['get'](_0x4f0d59['rootName']),_0x1e7112=new ot(this['_fixPosition'](_0x4f0d59['start'],_0x4c5d6b),this['_fixPosition'](_0x4f0d59['end'],_0x4c5d6b)),_0x1b6a54=this['_fixRange'](_0x1e7112,_0x26b7be);_0x4c5d6b['markers']['set'](_0x15d8a8,_0x1e7112),this['_markers']['set'](_0x15d8a8,_0x1b6a54);}this['_applyOperations'](_0x55ec76,_0x8f7b00,_0x5dab2d);}['_applyOperations'](_0x87d54e,_0x3bd893,_0x1d76e5){for(const _0x373b8c of this['source']['getOperations'](_0x87d54e,_0x3bd893))this['_handleOperation'](_0x373b8c,_0x1d76e5);for(const _0x1f3757 of this['_diffRoots']['values']())_0x1f3757['markers']['clear']();for(const [_0x2c3c34,_0x3df48c]of this['_markers']){this['_diffRoots']['get'](_0x3df48c['root']['rootName'])['markers']['set'](_0x2c3c34,_0x3df48c['clone']());}const _0x1e9b33=new Map(),_0x5260fb=new Map();for(const [_0x1c5361,_0x2edc64]of this['_diffRoots'])_0x1e9b33['set'](_0x1c5361,x(_0x2edc64)),_0x5260fb['set'](_0x1c5361,this['_diffRootsAttributes']['get'](_0x1c5361));this['_saveMetaData'](_0x3bd893,_0x1e9b33,this['_markers'],_0x5260fb);}['_getPreviousFrom'](_0x2b7fe8){const _0x4eae9c=Array['from'](this['_savedMetaData']['keys']());_0x4eae9c['sort']((_0x43f498,_0x2db721)=>_0x43f498-_0x2db721),_0x4eae9c['reverse']();for(const _0x45dde4 of _0x4eae9c)if(_0x45dde4<_0x2b7fe8)return _0x45dde4;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x533c98,_0x3c0a7d){const _0x5bf777=Array['from'](_0x3c0a7d['markers'])['map'](([_0x463558,_0x395522])=>[_0x463558,this['_fixRange'](_0x395522,_0x533c98)]);_0x533c98['markers']=new Map(_0x5bf777);}['_transformMarkers'](_0x9ec08b){for(const _0xbc5132 of this['_markers']['values']()){const _0x70de28=_0xbc5132['getTransformedByOperation'](_0x9ec08b),_0x58ccb4=ot['_createFromRanges'](_0x70de28);_0xbc5132['start']=_0x58ccb4['start'],_0xbc5132['end']=_0x58ccb4['end'];}}['_handleOperation'](_0x3e1ff1,_0x1efb98){if('addRoot'!=_0x3e1ff1['type']&&'detachRoot'!=_0x3e1ff1['type']){if('insert'==_0x3e1ff1['type']){const _0x2ba4cf=_0x3e1ff1['position']['root']['rootName'];this['_diffRoots']['has'](_0x2ba4cf)||(this['_diffRoots']['set'](_0x2ba4cf,N(_0x2ba4cf,!0x0)),this['_diffRootsAttributes']['set'](_0x2ba4cf,{}),_0x1efb98&&this['_idsRoots']['set'](_0x2ba4cf,N(_0x2ba4cf,!0x0)));}else{if('addRootAttribute'==_0x3e1ff1['type']||'removeRootAttribute'==_0x3e1ff1['type']||'changeRootAttribute'==_0x3e1ff1['type'])return void this['_handleRootAttributeOperation'](_0x3e1ff1);'marker'==_0x3e1ff1['type']&&this['_handleMarkerOperation'](_0x3e1ff1);}if('marker'!==_0x3e1ff1['type']){const _0x4afcf8=this['_cloneOperation'](_0x3e1ff1,this['_diffRoots']);_0x4afcf8['_execute'](),this['_transformMarkers'](_0x4afcf8);}if(_0x1efb98)switch(_0x3e1ff1['type']){case'insert':this['_handleInsertOperation'](_0x3e1ff1);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x3e1ff1);break;case'merge':this['_handleMergeOperation'](_0x3e1ff1);break;case'split':this['_handleSplitOperation'](_0x3e1ff1);}}else this['_handleRootOperation'](_0x3e1ff1,_0x1efb98);}['_cloneOperation'](_0x193071,_0x157628){const _0x3f508d=_0x193071['clone']();return _0x3f508d['_authorId']=_0x193071['_authorId'],this['_fixOperation'](_0x3f508d,_0x157628),_0x3f508d;}['_getBaseVids'](_0x5e84f3){return _0x5e84f3['map'](_0xb959a5=>{const _0x5ccd41=this['_getVidAttributeName'](_0xb959a5);return Number(_0xb959a5['item']['getAttribute'](_0x5ccd41));});}['_generateTape'](_0x582646,_0x1030a6){if(_0x582646['is']('element','$text'))_0x1030a6['push']({'item':_0x582646,'type':'text'});else{_0x582646['is']('element')&&_0x1030a6['push']({'item':_0x582646,'type':'elementStart'});for(const _0x5eda5a of _0x582646['getChildren']())this['_generateTape'](_0x5eda5a,_0x1030a6);_0x582646['is']('element')&&_0x1030a6['push']({'item':_0x582646,'type':'elementEnd'});}return _0x1030a6;}['_getState'](){const _0x4d3d2c=new Map(this['_touched']),_0x445c82=new Map(_0x4d3d2c),_0x24e26c=new Map(),_0x334053={'insertions':{},'deletions':{}},_0x27428d={'insertions':{},'deletions':{}},_0x44d10c=new Map(),_0x4534ba=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x4534ba['delete']('$graveyard');for(const _0x5294dd of _0x4534ba){const _0x4559ba=this['_diffRoots']['get'](_0x5294dd)||N(_0x5294dd,!0x1),_0x1ec29b=this['_baseRoots']['get'](_0x5294dd)||N(_0x5294dd,!0x1);_0x4559ba['isAttached']()||_0x1ec29b['isAttached']()?(_0x334053['insertions'][_0x5294dd]=x(_0x4559ba),_0x334053['deletions'][_0x5294dd]=x(_0x1ec29b),this['_copyMarkers'](_0x334053['deletions'][_0x5294dd],_0x1ec29b),this['_copyMarkers'](_0x334053['insertions'][_0x5294dd],_0x4559ba),_0x27428d['insertions'][_0x5294dd]=this['_generateTape'](this['_idsRoots']['get'](_0x5294dd),[]),_0x27428d['deletions'][_0x5294dd]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x5294dd)||N(_0x5294dd,!0x1),[])):_0x4534ba['delete'](_0x5294dd);}for(const _0x32e5b1 of _0x4534ba){const _0x3854c2=_0x27428d['insertions'][_0x32e5b1];for(const _0x535377 of _0x3854c2){const _0x51bbcd=this['_getVidAttributeName'](_0x535377),_0x9a0a66=_0x535377['item']['getAttribute'](_0x51bbcd);_0x445c82['delete'](_0x9a0a66),_0x9a0a66>=this['_startingRevisionId']&&_0x24e26c['set'](_0x9a0a66,_0x4d3d2c['get'](_0x9a0a66));}}for(const _0x5de822 of _0x4534ba){const _0x3fc965=_0x27428d['insertions'][_0x5de822],_0x3c091a=this['_getBaseVids'](_0x27428d['deletions'][_0x5de822]);let _0x5ac511=0x0;for(const _0x4ac856 of _0x3fc965){const _0x2c14dd=this['_getVidAttributeName'](_0x4ac856),_0x5a6390=_0x4ac856['item']['getAttribute'](_0x2c14dd);if(!_0x24e26c['has'](_0x5a6390)&&!_0x44d10c['has'](_0x5a6390)){if(_0x445c82['has'](_0x5a6390))_0x5ac511++;else{if(_0x5a6390!=_0x3c091a[_0x5ac511]){const _0x4ecc3c=_0x4d3d2c['get'](_0x5a6390)||_0x4d3d2c['get'](_0x3c091a[_0x5ac511]);for(;_0x5a6390!=_0x3c091a[_0x5ac511];)_0x445c82['has'](_0x3c091a[_0x5ac511])||(_0x44d10c['set'](_0x3c091a[_0x5ac511],_0x4ecc3c),_0x4d3d2c['set'](_0x3c091a[_0x5ac511],_0x4ecc3c)),_0x5ac511++;}_0x5ac511++;}}}}for(const _0x2efc33 of _0x4534ba){const _0x4f72b7=_0x27428d['insertions'][_0x2efc33];for(const _0x5850de of _0x4f72b7){const _0xa15835=this['_getVidAttributeName'](_0x5850de),_0x105624=_0x5850de['item']['getAttribute'](_0xa15835);if(_0x44d10c['has'](_0x105624)){const _0x2ff4b0=_0x44d10c['get'](_0x105624);_0x445c82['has'](_0x105624)||_0x445c82['set'](_0x105624,{..._0x2ff4b0}),_0x24e26c['set'](_0x105624,{..._0x2ff4b0});}}}for(const _0x4b28f9 of _0x445c82['keys']())_0x4b28f9>=this['_startingRevisionId']&&_0x445c82['delete'](_0x4b28f9);const _0x1a9bbb=new Map();for(const _0x336240 of _0x4534ba){let _0x768280=_0x27428d['insertions'][_0x336240];for(const _0x2e3a91 of _0x768280)if(_0x2e3a91['item']['is']('element','tableCell')){const _0x21f930=this['_getVidAttributeName'](_0x2e3a91),_0x1edbeb=_0x2e3a91['item']['getAttribute'](_0x21f930);if(_0x24e26c['has'](_0x1edbeb)){const _0x132a03=_0x2e3a91['item']['parent']['parent']['getAttribute']('vid_start'),_0x136cce=_0x1a9bbb['get'](_0x132a03)||new Set();_0x136cce['add'](_0x24e26c['get'](_0x1edbeb)['userId']),_0x1a9bbb['set'](_0x132a03,_0x136cce);}}_0x768280=_0x27428d['deletions'][_0x336240];for(const _0x1751d6 of _0x768280)if(_0x1751d6['item']['is']('element','tableCell')){const _0x500064=this['_getVidAttributeName'](_0x1751d6),_0x581606=_0x1751d6['item']['getAttribute'](_0x500064);if(_0x445c82['has'](_0x581606)){const _0x43c7e8=_0x1751d6['item']['parent']['parent']['getAttribute']('vid_start'),_0x4c5ed5=_0x1a9bbb['get'](_0x43c7e8)||new Set();_0x4c5ed5['add'](_0x445c82['get'](_0x581606)['userId']),_0x1a9bbb['set'](_0x43c7e8,_0x4c5ed5);}}for(const _0x1fd9cf of _0x1a9bbb['keys']())(_0x24e26c['has'](_0x1fd9cf)||_0x445c82['has'](_0x1fd9cf))&&_0x1a9bbb['delete'](_0x1fd9cf);}for(const _0x3b5966 of _0x4534ba){const _0x2203f2=_0x27428d['insertions'][_0x3b5966];let _0x4cf640=null,_0x12ed8f=null;for(const _0x56a7de of _0x2203f2){const _0xd00c5a=this['_getVidAttributeName'](_0x56a7de),_0x23d2e3=_0x56a7de['item']['getAttribute'](_0xd00c5a),_0x46a170=_0x1a9bbb['get'](_0x23d2e3);_0x46a170&&'elementStart'==_0x56a7de['type']&&(_0x4cf640=Array['from'](_0x46a170)[0x0],_0x12ed8f=_0x56a7de['item']['getAttribute']('vid_end')),_0x4cf640&&(_0x445c82['set'](_0x23d2e3,{'userId':_0x4cf640}),_0x24e26c['set'](_0x23d2e3,{'userId':_0x4cf640})),_0x23d2e3==_0x12ed8f&&(_0x4cf640=null,_0x12ed8f=null);}}const _0x367235={},_0x4ff472=new Set();for(const _0x4f61bb of _0x4534ba){const _0x2ef791=_0x334053['deletions'][_0x4f61bb],_0x23c57d=_0x334053['insertions'][_0x4f61bb];for(const {userId:_0x848243}of this['_touchedMarkers']['values']())null!==_0x848243&&_0x4ff472['add'](_0x848243);for(const {userId:_0x4c9685}of this['_touchedRoots']['values']())null!==_0x4c9685&&_0x4ff472['add'](_0x4c9685);this['_markChanges'](_0x23c57d,_0x27428d['insertions'][_0x4f61bb],_0x24e26c,'insertion',_0x4ff472),this['_markChanges'](_0x2ef791,_0x27428d['deletions'][_0x4f61bb],_0x445c82,'deletion',_0x4ff472),_0x367235[_0x4f61bb]={'insertions':this['_prepareViewToSave'](_0x23c57d),'deletions':this['_prepareViewToSave'](_0x2ef791),'attachChange':this['_touchedRoots']['get'](_0x4f61bb)||null,'attributesBefore':_0x45be4a(this['_baseRootsAttributes']['get'](_0x4f61bb))||{},'attributesAfter':_0x45be4a(this['_diffRootsAttributes']['get'](_0x4f61bb))};}return{'diffData':_0x367235,'authorsIds':Array['from'](_0x4ff472)};}['_processRootBeforeSave'](_0x53cd86){for(const [,_0x3a2f2b]of _0x53cd86['markers']){const _0x574154=_0x3a2f2b['start']['getAncestors']()['filter'](_0x28d7d0=>'tableCell'==_0x28d7d0['name']);for(const _0x385444 of _0x574154)0x1==_0x385444['childCount']&&_0x385444['getChild'](0x0)['is']('element','paragraph')&&_0x385444['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x4ac01a){this['_processRootBeforeSave'](_0x4ac01a);const _0x18214e=this['editor']['data']['toView'](_0x4ac01a,{}),_0x1dbfba=Array['from'](_0x18214e['getChildren']())['map'](_0x11eb10=>this['_getViewJson'](_0x11eb10));return JSON['stringify'](_0x1dbfba);}['_getViewJson'](_0x60230){if(_0x60230['is']('$text'))return _0x60230['data'];{const _0x4938ce=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0x1527d0=_0x60230,_0x4fde43=this['editor']['data']['htmlProcessor']['domConverter'],_0x577dfd={'type':_0x4938ce['_getTypeCharForViewElement'](_0x1527d0),'name':_0x1527d0['name'],'attributes':Array['from'](_0x1527d0['getAttributes']()),'children':Array['from'](_0x1527d0['getChildren']())['map'](_0x27d2cc=>this['_getViewJson'](_0x27d2cc))};if(_0x60230['is']('uiElement')&&'$comment'!=_0x60230['name']){const _0x332bf7=_0x60230['render'](_0x4fde43['domDocument'],_0x4fde43);_0x577dfd['children']['push'](_0x332bf7['outerHTML']);}else{if(_0x60230['is']('rawElement')){const _0x1858d5=_0x4fde43['domDocument']['createElement'](_0x1527d0['name']);_0x60230['render'](_0x1858d5,_0x4fde43),_0x577dfd['children']['push'](_0x1858d5['innerHTML']);}}const _0x2248ec=Array['from'](_0x1527d0['getCustomProperties']());_0x2248ec['length']>0x0&&(_0x577dfd['customProperties']=_0x2248ec);const _0x22fd26=_0x1527d0['getFillerOffset']();return null!==_0x22fd26&&(_0x577dfd['fillerOffset']=_0x22fd26),_0x577dfd;}}['_markChanges'](_0x5ad602,_0x553238,_0x1a10de,_0x2e9026,_0x1bb5d9){let _0x578d57=null,_0x3869de=null,_0x3b47ee=0x0;const _0x5d549a=this['editor']['model'];for(let _0x2b1ecd=0x0;_0x2b1ecd<_0x553238['length'];_0x2b1ecd++){const _0x382790=this['_getVidAttributeName'](_0x553238[_0x2b1ecd]),_0x3647b3=_0x553238[_0x2b1ecd]['item']['getAttribute'](_0x382790),_0x16d2d9=_0x1a10de['get'](_0x3647b3),_0x202184=_0x2b1ecd==_0x553238['length']-0x1;(!_0x578d57&&_0x16d2d9&&(_0x578d57=_0x16d2d9,_0x3869de=_0x553238[_0x2b1ecd]),_0x578d57&&(!_0x16d2d9||_0x16d2d9['userId']!=_0x578d57['userId']))&&(_0x4447ff(_0x16d2d9,P(_0x3869de,_0x5ad602,_0x5d549a),P(_0x553238[_0x2b1ecd],_0x5ad602,_0x5d549a)),_0x578d57=_0x16d2d9||null,_0x3869de=_0x16d2d9?_0x553238[_0x2b1ecd]:null),_0x578d57&&_0x202184&&_0x4447ff(_0x16d2d9,P(_0x3869de,_0x5ad602,_0x5d549a),V(_0x553238[_0x2b1ecd],_0x5ad602,_0x5d549a));}function _0x4447ff(_0x2ca39e,_0x4cc615,_0xae0495){const _0x5d5893=_0x578d57['userId'],_0x30fe9a='revision:'+_0x2e9026+':'+_0x5d5893+':'+_0x3b47ee++,_0x1592f3=_0x5d549a['createRange'](_0x4cc615,_0xae0495);_0x5ad602['markers']['set'](_0x30fe9a,_0x1592f3),null!==_0x5d5893&&_0x1bb5d9['add'](_0x5d5893);}}['_getVidAttributeName'](_0x11bf03){switch(_0x11bf03['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x11edfb,_0x3f6b8a){_0x11edfb['baseVersion']=null;for(const _0x4703f1 in _0x11edfb){const _0x27a043=_0x11edfb[_0x4703f1];if(_0x27a043 instanceof rt){const _0x4f8596=_0x3f6b8a['get'](_0x27a043['root']['rootName']);_0x11edfb[_0x4703f1]=this['_fixPosition'](_0x27a043,_0x4f8596);}if(_0x27a043 instanceof ot){const _0x55bd4a=_0x3f6b8a['get'](_0x27a043['root']['rootName']);_0x11edfb[_0x4703f1]=this['_fixRange'](_0x27a043,_0x55bd4a);}'root'===_0x4703f1&&(_0x11edfb['root']=_0x3f6b8a['get'](_0x11edfb['root']['rootName']));}}['_fixRange'](_0xafeb8a,_0x2e7508){return this['editor']['model']['createRange'](this['_fixPosition'](_0xafeb8a['start'],_0x2e7508),this['_fixPosition'](_0xafeb8a['end'],_0x2e7508));}['_fixPosition'](_0x1da592,_0x4bb746){return this['editor']['model']['createPositionFromPath'](_0x4bb746,_0x1da592['path'],_0x1da592['stickiness']);}['_handleInsertOperation'](_0x8b9243){const _0xdeb2a5=this['_idsRoots']['get'](_0x8b9243['position']['root']['rootName']),_0x1d502b=this['_fixPosition'](_0x8b9243['position'],_0xdeb2a5),_0x30fb06=null===_0x8b9243['_authorId']?null:_0x8b9243['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x3a5396=_0x1d502b['parent'],_0xd1a02a=this['_revisionId'],_0x4dbc4f=[];for(const _0x2b4968 of _0x8b9243['nodes'])if(_0x2b4968['is']('element'))_0x4dbc4f['push'](this['_makeIdsRoot'](_0x2b4968));else{for(let _0x2dad40=0x0;_0x2dad40<_0x2b4968['offsetSize'];_0x2dad40++)_0x4dbc4f['push'](new nt('$text',{'vid':this['_revisionId']++}));}const _0x40593a=this['_revisionId'];for(let _0x12d7bf=_0xd1a02a;_0x12d7bf<_0x40593a;_0x12d7bf++)this['_touched']['set'](_0x12d7bf,{'userId':_0x30fb06});_0x3a5396['_insertChild'](_0x1d502b['offset'],_0x4dbc4f);}['_handleMoveOperation'](_0x3b3f85){(_0x3b3f85=this['_cloneOperation'](_0x3b3f85,this['_idsRoots']))['_execute']();const _0x5dad5c=null===_0x3b3f85['_authorId']?null:_0x3b3f85['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x1bd008=_0x3b3f85['getMovedRangeStart'](),_0x1241f2=_0x1bd008['parent'],_0x5211f9=_0x1bd008['offset'];!function _0x4327cb(_0x48be7a,_0x576d56,_0x436c08,_0x5b0508){for(let _0x2c341e=_0x436c08;_0x2c341e<_0x5b0508;_0x2c341e++){const _0x408763=_0x576d56['getChild'](_0x2c341e);_0x408763['is']('element','$text')?_0x48be7a['set'](_0x408763['getAttribute']('vid'),{'userId':_0x5dad5c}):(_0x48be7a['set'](_0x408763['getAttribute']('vid_start'),{'userId':_0x5dad5c}),_0x4327cb(_0x48be7a,_0x408763,0x0,_0x408763['childCount']),_0x48be7a['set'](_0x408763['getAttribute']('vid_end'),{'userId':_0x5dad5c}));}}(this['_touched'],_0x1241f2,_0x5211f9,_0x5211f9+_0x3b3f85['howMany']);}['_handleMergeOperation'](_0x33b8fe){const _0x49d90a=null===(_0x33b8fe=this['_cloneOperation'](_0x33b8fe,this['_idsRoots']))['_authorId']?null:_0x33b8fe['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x2c920a=_0x33b8fe['targetPosition']['parent'],_0x8c21f5=_0x33b8fe['sourcePosition']['parent'],_0x184dc0=_0x2c920a['getAttribute']('vid_end'),_0x4d2ba8=_0x8c21f5['getAttribute']('vid_start');_0x2c920a['_setAttribute']('vid_end',_0x8c21f5['getAttribute']('vid_end')),_0x8c21f5['_setAttribute']('vid_end',_0x184dc0),this['_touched']['set'](_0x4d2ba8,{'userId':_0x49d90a}),this['_touched']['set'](_0x184dc0,{'userId':_0x49d90a}),_0x33b8fe['_execute']();}['_handleSplitOperation'](_0x361d03){const _0x351fed=null===(_0x361d03=this['_cloneOperation'](_0x361d03,this['_idsRoots']))['_authorId']?null:_0x361d03['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x4b12dd=_0x361d03['graveyardPosition'],_0x47958f=_0x361d03['splitPosition']['parent'];_0x361d03['_execute']();const _0x1d5e5a=_0x47958f['getAttribute']('vid_end'),_0x1b9082=_0x361d03['insertionPosition']['nodeAfter'];if(_0x4b12dd){const _0x3627de=_0x1b9082['getAttribute']('vid_end'),_0x5d0087=_0x47958f['getAttribute']('vid_end');_0x47958f['_setAttribute']('vid_end',_0x3627de),_0x1b9082['_setAttribute']('vid_end',_0x5d0087),this['_touched']['set'](_0x47958f['getAttribute']('vid_end'),{'userId':_0x351fed}),this['_touched']['set'](_0x1b9082['getAttribute']('vid_start'),{'userId':_0x351fed});}else{const _0x34021c=this['_revisionId']++,_0x22a5e7=this['_revisionId']++;_0x47958f['_setAttribute']('vid_end',_0x34021c),_0x1b9082['_setAttribute']('vid_start',_0x22a5e7),_0x1b9082['_setAttribute']('vid_end',_0x1d5e5a),this['_touched']['set'](_0x34021c,{'userId':_0x351fed}),this['_touched']['set'](_0x22a5e7,{'userId':_0x351fed});}}['_handleMarkerOperation'](_0x413a2b){if(!_0x413a2b['affectsData'])return;const _0x1ff3c6=(_0x413a2b=this['_cloneOperation'](_0x413a2b,this['_diffRoots']))['oldRange']?_0x413a2b['oldRange']['root']:null,_0x323666=_0x413a2b['newRange']?_0x413a2b['newRange']['root']:null;_0x1ff3c6&&this['_markers']['delete'](_0x413a2b['name']),_0x323666&&this['_markers']['set'](_0x413a2b['name'],_0x413a2b['newRange']['clone']());const _0x172d0f=null===_0x413a2b['_authorId']?null:_0x413a2b['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x56f0db=_0x413a2b['name'];if(!this['_touchedMarkers']['has'](_0x56f0db))return void this['_touchedMarkers']['set'](_0x56f0db,{'range':_0x413a2b['oldRange'],'userId':_0x172d0f});const _0x55f6ed=this['_touchedMarkers']['get'](_0x56f0db),_0x2f4530=_0x55f6ed['range'],_0x24c71d=_0x413a2b['newRange'];null==_0x2f4530&&null==_0x24c71d||_0x2f4530&&_0x24c71d&&_0x2f4530['isEqual'](_0x24c71d)?this['_touchedMarkers']['delete'](_0x413a2b['name']):_0x55f6ed['userId']=_0x172d0f;}['_handleRootOperation'](_0x400833,_0x1b6c82){this['_diffRoots']['has'](_0x400833['rootName'])?this['_diffRoots']['get'](_0x400833['rootName'])['_isAttached']=_0x400833['isAdd']:(this['_diffRoots']['set'](_0x400833['rootName'],N(_0x400833['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x400833['rootName'],{}),_0x1b6c82&&this['_idsRoots']['set'](_0x400833['rootName'],N(_0x400833['rootName'],!0x0)));const _0x26e9db=null===_0x400833['_authorId']?null:_0x400833['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x3ba821=this['_touchedRoots']['get'](_0x400833['rootName']);_0x3ba821&&_0x3ba821['userId']===_0x26e9db?this['_touchedRoots']['delete'](_0x400833['rootName']):this['_touchedRoots']['set'](_0x400833['rootName'],{'userId':_0x26e9db,'isAttached':_0x400833['isAdd']});}['_handleRootAttributeOperation'](_0x2a27d7){const _0x1e973d=this['_diffRootsAttributes']['get'](_0x2a27d7['root']['rootName']);null===_0x2a27d7['newValue']?delete _0x1e973d[_0x2a27d7['key']]:_0x1e973d[_0x2a27d7['key']]=_0x2a27d7['newValue'];}}function x(_0x3e8482){const _0x18f373=N(_0x3e8482['rootName'],_0x3e8482['isAttached']());for(const _0x1b6561 of _0x3e8482['getChildren']()){const _0x1f44cd=_0x1b6561['_clone'](!0x0);_0x18f373['_appendChild'](_0x1f44cd);}return _0x18f373;}function N(_0x31d1fe,_0x1a3d6c=!0x0){const _0x3933b8=new at();return _0x3933b8['rootName']=_0x31d1fe,_0x3933b8['_isAttached']=_0x1a3d6c,_0x3933b8['isAttached']=()=>_0x3933b8['_isAttached'],_0x3933b8;}function P(_0xcc9d9b,_0x5b20b8,_0x57f0d8){const _0x22c30c='elementEnd'==_0xcc9d9b['type']?_0x57f0d8['createPositionAt'](_0xcc9d9b['item'],'end'):_0x57f0d8['createPositionBefore'](_0xcc9d9b['item']);return _0x57f0d8['createPositionFromPath'](_0x5b20b8,_0x22c30c['path'],_0x22c30c['stickiness']);}function V(_0x3c54f7,_0x57586b,_0x5cc746){const _0x42b3ca='elementStart'==_0x3c54f7['type']?_0x5cc746['createPositionAt'](_0x3c54f7['item'],0x0):_0x5cc746['createPositionAfter'](_0x3c54f7['item']);return _0x5cc746['createPositionFromPath'](_0x57586b,_0x42b3ca['path'],_0x42b3ca['stickiness']);}class he extends/* #__PURE__ -- @preserve */
|
|
25
|
-
|
|
26
|
-
_0x2e4104(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x1bb7aa){super(),this['id']=_0x1bb7aa['id']||_0x5545a3(),this['author']=_0x1bb7aa['author'],this['type']=_0x1bb7aa['type'],this['data']=_0x1bb7aa['data']||{},this['rootName']=_0x1bb7aa['rootName'],this['set']('createdAt',_0x1bb7aa['createdAt']);}['toJSON'](){return{'id':this['id'],'authorId':this['author']['id'],'type':this['type'],'data':this['data'],'createdAt':this['createdAt']};}}class J{['newRevisionId'];['oldRevisionId'];['changes'];constructor(_0x4ec751,_0x3209a6){this['newRevisionId']=_0x4ec751,this['oldRevisionId']=_0x3209a6,this['changes']=new _0x2da206();}['_setChanges'](_0x297e74){for(const _0x843c3a of _0x297e74)this['changes']['add'](_0x843c3a);}}class l extends _0x25ad5f{['repository'];['adapter']=null;['_utils'];['_activeViewTarget'];['_changeView'];['_changeIdToChange'];['_balloon'];static get['pluginName'](){return'RevisionViewer';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[_0x55a47e,_0x214e82,S,$];}constructor(_0x4f36a1){super(_0x4f36a1),this['repository']=this['editor']['plugins']['get']('RevisionsRepository'),this['_utils']=this['editor']['plugins']['get']('RevisionHistoryUtils'),this['set']('activeChange',null),this['set']('activeView',null),this['_activeViewTarget']=null,this['set']('diff',null),this['set']('isReady',!0x1),this['set']('isEnabled',!0x0),this['on']('change:isEnabled',(_0xf53473,_0x59baab,_0x2cd0ea)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0xa6115d=>{for(const _0x258a5f of this['editor']['editing']['view']['document']['roots'])_0x2cd0ea?_0xa6115d['removeClass']('ck-editor__editable__overlay',_0x258a5f):_0xa6115d['addClass']('ck-editor__editable__overlay',_0x258a5f);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x3ff543=>null!==_0x3ff543),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x1ec9f1,_0x13f193,_0x58e0ae)=>_0x1ec9f1&&_0x58e0ae?_0x13f193['changes']['getIndex'](_0x58e0ae):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x9a84a3,_0x2fa2e4)=>_0x9a84a3?_0x2fa2e4['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0x214e82);}['init'](){const _0x3489dc=this['editor'],_0xb4a7b2=new ut(_0x3489dc,{'direction':'backward'}),_0x25e6f7=new ut(_0x3489dc,{'direction':'forward'});(_0x3489dc['commands']['add']('showPreviousChange',_0xb4a7b2),_0x3489dc['commands']['add']('showNextChange',_0x25e6f7),_0x3489dc['commands']['add']('restoreRevision',new ct(_0x3489dc)),this['on']('change:numberOfChanges',()=>{_0xb4a7b2['refresh'](),_0x25e6f7['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x3489dc['enableReadOnlyMode']('revision-viewer'),_0x3489dc['plugins']['has']('WidgetToolbarRepository'))&&_0x3489dc['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x258575){return await this['_utils']['loadRevisionData'](_0x258575,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x258575);}async['getRevisionRootsAttributes'](_0x2d37d1){return await this['_utils']['loadRevisionData'](_0x2d37d1,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x2d37d1);}async['compare'](_0x5adc12,_0x132966,_0x1dab53=!0x1){if(!this['isEnabled'])return;const _0x1150f4=this['diff'],_0x20b049=this['repository'],_0x45ce7f='string'==typeof _0x5adc12?_0x20b049['getRevision'](_0x5adc12):_0x5adc12,_0x246016='string'==typeof _0x132966?_0x20b049['getRevision'](_0x132966):_0x132966,_0x2c9f32=_0x45ce7f['id'],_0x57ad6=_0x246016?_0x246016['id']:null;if(!_0x1dab53&&this['diff']&&this['diff']['newRevisionId']===_0x2c9f32&&this['diff']['oldRevisionId']===_0x57ad6)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new J(_0x2c9f32,_0x57ad6);const _0x520959=this['_getRevisionsRange'](_0x45ce7f,_0x246016,!0x0)['map'](_0xcbae7=>this['_utils']['loadRevisionData'](_0xcbae7,this['adapter']));return _0x520959['push'](new Promise(_0x4cd85f=>{setTimeout(_0x4cd85f,0x14);})),Promise['all'](_0x520959)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x395b43=this['_getDiff'](_0x2c9f32,_0x57ad6);for(const _0x32b885 of _0x395b43['changes'])this['_changeIdToChange']['set'](_0x32b885['id'],_0x32b885);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x5f340d=>{for(const _0x3b671e of this['editor']['model']['document']['getRootNames']())_0x5f340d['detachRoot'](_0x3b671e);for(const _0x5ca7c7 of Object['keys'](_0x395b43['model'])){const _0x403c1b=_0x5f340d['addRoot'](_0x5ca7c7);for(const _0x258cb3 of Object['keys'](_0x395b43['attributes'][_0x5ca7c7]))_0x5f340d['setAttribute'](_0x258cb3,_0x395b43['attributes'][_0x5ca7c7][_0x258cb3],_0x403c1b);_0x5f340d['insert'](_0x395b43['model'][_0x5ca7c7],_0x403c1b,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x395b43['changes'])),this['isReady']=!0x0;})['catch'](_0x21a90f=>{console['error'](_0x21a90f),this['_cleanUp'](),_0x1150f4&&(this['diff']=_0x1150f4),this['isReady']=!0x0;});}['addRevisionData'](_0x8c2e4d,_0x1b618c){const _0xe866e0=this['repository']['createRevision'](_0x8c2e4d);return _0xe866e0['on']('_update',(_0x3d6aa2,_0x36ebde,_0x194efa)=>_0x1b618c(_0x36ebde,_0x194efa,_0xe866e0)),this['repository']['addRevision'](_0xe866e0),_0xe866e0;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x45829b=>{for(const _0x309b42 of this['editor']['model']['document']['getRootNames']())_0x45829b['detachRoot'](_0x309b42);});}['_sortAndFilterDiffChanges'](_0x2860fe){const _0x1bdf80=[],_0x199873=new Map();for(const _0x3d8061 of this['editor']['model']['document']['getRootNames']()){const _0x29ee9c=this['editor']['editing']['view']['getDomRoot'](_0x3d8061);if(!_0x29ee9c)continue;const _0x36aa7f=_0x29ee9c['getClientRects']()['item'](0x0);_0x36aa7f&&(_0x1bdf80['push'](_0x3d8061),_0x199873['set'](_0x3d8061,_0x36aa7f));}return _0x1bdf80['sort']((_0x178728,_0x2a4cdd)=>{const _0x4540a4=_0x199873['get'](_0x178728),_0x294bdd=_0x199873['get'](_0x2a4cdd);return _0x4540a4['y']-_0x294bdd['y']||_0x4540a4['x']-_0x294bdd['x'];}),(_0x2860fe=_0x2860fe['filter'](_0xe84cd=>_0x1bdf80['includes'](_0xe84cd['rootName'])))['sort']((_0x24229b,_0x55774e)=>_0x1bdf80['indexOf'](_0x24229b['rootName'])-_0x1bdf80['indexOf'](_0x55774e['rootName'])),_0x2860fe;}['_makeTape'](_0x2846c5){const _0x4c32db=Array['from'](_0x2846c5['markers'])['filter'](([_0x2dfec4,_0x371ddb])=>_0x2dfec4['startsWith']('revision:')&&!_0x371ddb['isCollapsed']),_0x37e072=Array['from'](this['editor']['model']['createRangeIn'](_0x2846c5)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x4c32db['length'])for(const _0x2fe881 of _0x37e072){const [_0x40d467,_0xaee0c3]=_0x4c32db[0x0],[,_0x2ce2e2,_0xd5cd10]=_0x40d467['split'](':');if(_0xaee0c3['end']['isEqual'](_0x2fe881['nextPosition'])&&_0x4c32db['shift'](),(_0x2fe881['previousPosition']['isEqual'](_0xaee0c3['start'])||_0x2fe881['previousPosition']['isAfter'](_0xaee0c3['start']))&&('insertion'==_0x2ce2e2?_0x2fe881['isAdded']={'userId':_0xd5cd10}:'deletion'==_0x2ce2e2&&(_0x2fe881['isRemoved']={'userId':_0xd5cd10})),0x0==_0x4c32db['length'])break;}return _0x37e072;}['_refreshStartEndIndex'](_0xed62d5){const _0x12584b=new Map();for(let _0x837c89=0x0;_0x837c89<_0xed62d5['length'];_0x837c89++)'text'===_0xed62d5[_0x837c89]['type']?(_0xed62d5[_0x837c89]['item']['startIndex']=_0x837c89,_0xed62d5[_0x837c89]['item']['endIndex']=_0x837c89):('elementStart'===_0xed62d5[_0x837c89]['type']?_0xed62d5[_0x837c89]['item']['startIndex']=_0x837c89:'elementEnd'===_0xed62d5[_0x837c89]['type']&&(_0xed62d5[_0x837c89]['item']['endIndex']=_0x837c89),_0x12584b['set'](_0xed62d5[_0x837c89]['id'],_0x837c89));for(const _0x305deb of _0x12584b['values']())'elementStart'===_0xed62d5[_0x305deb]['type']?_0xed62d5[_0x305deb]['item']['endIndex']=_0x12584b['get'](_0xed62d5[_0x305deb]['pairId']):'elementEnd'===_0xed62d5[_0x305deb]['type']&&(_0xed62d5[_0x305deb]['item']['startIndex']=_0x12584b['get'](_0xed62d5[_0x305deb]['pairId']));}['_processTape'](_0x5456b1){for(let _0x75f240=0x0;_0x75f240<_0x5456b1['length'];_0x75f240++){if('elementStart'===_0x5456b1[_0x75f240]['type'])_0x5456b1[_0x75f240]['item']['startIndex']=_0x75f240;else{if('elementEnd'===_0x5456b1[_0x75f240]['type']){_0x5456b1[_0x75f240]['item']['endIndex']=_0x75f240;const _0x17b6f3=_0x5456b1[_0x75f240]['item']['startIndex'];_0x5456b1[_0x17b6f3]['pairId']=_0x5456b1[_0x75f240]['id'],_0x5456b1[_0x75f240]['pairId']=_0x5456b1[_0x17b6f3]['id'];}else _0x5456b1[_0x75f240]['item']['startIndex']=_0x75f240,_0x5456b1[_0x75f240]['item']['endIndex']=_0x75f240,_0x5456b1[_0x75f240]['pairId']=null;}_0x5456b1[_0x75f240]['markersStart']||(_0x5456b1[_0x75f240]['markersStart']=[],_0x5456b1[_0x75f240]['markersEnd']=[]);}}['_markInsertions'](_0x2c69d5,_0x42ac6c){const _0x4c391e=_0x2c69d5['filter'](_0x1cbe8a=>!_0x1cbe8a['isAdded']);for(let _0x46231a=0x0;_0x46231a<_0x42ac6c['length'];_0x46231a++)_0x42ac6c[_0x46231a]['isAdded']&&(_0x4c391e[_0x46231a]['isAdded']=_0x42ac6c[_0x46231a]['isAdded']);}['_getDiff'](_0x2b3030,_0x7d2b12=null){const _0x3e1c12=this['repository']['getRevision'](_0x2b3030),_0x3fe164=_0x7d2b12?this['repository']['getRevision'](_0x7d2b12):null,_0xb8df73=this['_getRevisionsRange'](_0x3e1c12,_0x3fe164),_0x24af7c=_0xb8df73[_0xb8df73['length']-0x1],_0x51ff3c=new Map(),_0x5a924e={'model':{},'attributes':{},'changes':[]},_0x3f9443=new Set(),_0x4609fc=new Map();for(let _0x1dda16=_0xb8df73['length']-0x1;_0x1dda16>=0x0;_0x1dda16--){const _0x27cc7f=_0xb8df73[_0x1dda16];for(const _0x49faae of Object['keys'](_0x27cc7f['diffData']))if(_0x27cc7f['diffData'][_0x49faae]['attachChange']){const _0x2d28f4=_0x27cc7f['diffData'][_0x49faae]['attachChange'];_0x2d28f4['isAttached']?(_0x3f9443['add'](_0x49faae),_0x4609fc['has'](_0x49faae)&&_0x4609fc['get'](_0x49faae)['userId']==_0x2d28f4['userId']?_0x4609fc['delete'](_0x49faae):_0x4609fc['set'](_0x49faae,_0x2d28f4)):_0x4609fc['has'](_0x49faae)?(_0x3f9443['delete'](_0x49faae),_0x4609fc['delete'](_0x49faae)):(_0x3f9443['add'](_0x49faae),_0x4609fc['set'](_0x49faae,_0x2d28f4));}else _0x3f9443['add'](_0x49faae);}for(const _0x2b1a7f of _0x3f9443){const _0x56b6c7=_0x4609fc['has'](_0x2b1a7f)&&!_0x4609fc['get'](_0x2b1a7f)['isAttached'];let _0x298bb7=_0x56b6c7?_0xb8df73['length']-0x1:0x0;const _0x3770ae=_0x56b6c7?-0x1:0x1;for(;_0xb8df73[_0x298bb7];){const _0x5dec52=_0xb8df73[_0x298bb7];if(_0x5dec52['diffData'][_0x2b1a7f]){const _0x1bbe09=_0x56b6c7?_0x5dec52['diffData'][_0x2b1a7f]['attributesBefore']:_0x5dec52['diffData'][_0x2b1a7f]['attributesAfter'];_0x5a924e['attributes'][_0x2b1a7f]=_0x1bbe09?_0x45be4a(_0x1bbe09):{};break;}_0x298bb7+=_0x3770ae;}}for(const _0x1e82e9 of _0xb8df73){_0x1e82e9['model']={};for(const _0x9b8a23 of _0x1e82e9['authors'])_0x51ff3c['set'](_0x9b8a23['id'],_0x9b8a23);for(const _0x338161 of _0x3f9443){const _0x3b52b8=_0x1e82e9['diffData'][_0x338161]?_0x1e82e9['diffData'][_0x338161]['insertions']:'[]',_0x1aebcf=_0x1e82e9['diffData'][_0x338161]?_0x1e82e9['diffData'][_0x338161]['deletions']:'[]';_0x1e82e9['model'][_0x338161]={'insertions':this['_utils']['_makeModelFromViewString'](_0x3b52b8),'deletions':this['_utils']['_makeModelFromViewString'](_0x1aebcf)};}}for(const _0x28425a of _0x3f9443){let _0x2ed933=null,_0x76ca10=0x0;const _0x1caf7f=new Map(Array['from'](_0x3e1c12['model'][_0x28425a]['insertions']['markers'])['filter'](([_0x57d608])=>!_0x57d608['startsWith']('revision:')));let _0x310abd=0x0;for(const _0x15ad9a of _0xb8df73){const _0xc3b7d6=this['_makeTape'](_0x15ad9a['model'][_0x28425a]['insertions']);_0x15ad9a==_0x3e1c12?(_0x2ed933=_0xc3b7d6,_0x76ca10=_0x2ed933['length'],_0x2ed933['forEach'](_0x1ec48c=>{_0x1ec48c['id']=_0x310abd++;}),this['_processTape'](_0x2ed933)):this['_markInsertions'](_0x2ed933,_0xc3b7d6);const _0x383ebe=_0x2ed933['filter'](_0x420230=>!_0x420230['isAdded'])['map'](_0x56f110=>_0x56f110['id']);let _0xaf4e7f=0x0;const _0x15a9b6=this['_makeTape'](_0x15ad9a['model'][_0x28425a]['deletions']);_0x15a9b6['forEach'](_0x5411de=>{_0x5411de['isRemoved']?_0x5411de['id']=_0x76ca10++:_0x5411de['id']=_0x383ebe[_0xaf4e7f++];}),this['_processTape'](_0x15a9b6),this['_setDistance'](_0x2ed933,'isAdded'),this['_setDistance'](_0x15a9b6,'isRemoved'),_0x15ad9a==_0x3e1c12&&this['_markMarkers'](_0x2ed933,_0x1caf7f),_0x2ed933=this['_joinTapes'](_0x2ed933,_0x15a9b6),this['_refreshStartEndIndex'](_0x2ed933),this['_setDistance'](_0x2ed933,'isRemoved');}_0x2ed933=_0x2ed933['filter'](_0x94eebf=>!(_0x94eebf['isAdded']&&_0x94eebf['isRemoved']));const _0x41700b=new Map(_0x24af7c['model'][_0x28425a]['deletions']['markers']),_0x28a69e=new Set(_0x1caf7f['keys']());for(const _0x40a8bb of _0x41700b['keys']())_0x28a69e['delete'](_0x40a8bb);this['_markSuggestions'](_0x2ed933,_0x28a69e),this['_fixObsoleteTags'](_0x2ed933),_0x2ed933=this['_removeMissingPairs'](_0x2ed933),_0x2ed933=this['_markMismatchedRemovedTags'](_0x2ed933),_0x2ed933=this['_removeUnsupportedChanges'](_0x2ed933);const {root:_0x5a7e99,changes:_0x54d94b}=this['_makeModelFromTape'](_0x2ed933,_0x51ff3c,_0x28425a);_0x5a924e['model'][_0x28425a]=_0x5a7e99;const _0x4316e3=_0x4609fc['get'](_0x28425a);if(_0x4316e3){const _0xe1cc07=_0x51ff3c['get'](_0x4316e3['userId']),_0x530fdf=new G({'author':_0xe1cc07,'type':_0x4316e3['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x28425a});_0x54d94b['unshift'](_0x530fdf),_0x5a924e['attributes'][_0x28425a]['revisionHistoryAttachChange']=_0x530fdf['id'];}_0x5a924e['changes']=_0x5a924e['changes']['concat'](_0x54d94b);}return _0x5a924e;}['_markMarkers'](_0x29b18e,_0x511825){for(let _0x251db1=0x0;_0x251db1<_0x29b18e['length'];_0x251db1++)for(const [_0x363266,_0x4de91c]of _0x511825)!_0x4de91c['isCollapsed']&&_0x4de91c['start']['isEqual'](_0x29b18e[_0x251db1]['previousPosition'])&&_0x29b18e[_0x251db1]['markersStart']['push'](_0x363266),_0x4de91c['end']['isEqual'](_0x29b18e[_0x251db1]['nextPosition'])&&_0x29b18e[_0x251db1]['markersEnd']['push'](_0x363266);}['_joinTapes'](_0x1d1369,_0x2fe3c5){let _0xe018d8=[],_0x4e465a=0x0,_0x1bb3d8=0x0;for(;_0x4e465a<_0x1d1369['length']||_0x1bb3d8<_0x2fe3c5['length'];){const _0x2c4305=_0x1d1369[_0x4e465a]||{},_0x9a6a05=_0x2fe3c5[_0x1bb3d8]||{};if(_0x2c4305['id']==_0x9a6a05['id'])_0x4e465a++,_0x1bb3d8++,_0xe018d8['push'](_0x2c4305);else{if(_0x9a6a05['isRemoved']&&_0x2c4305['isAdded']){const {commonTape:_0x378678,iEnd:_0x10e44b,jEnd:_0x317462}=this['_threeWayMerge'](_0x1d1369,_0x4e465a,_0x2fe3c5,_0x1bb3d8);_0xe018d8=_0xe018d8['concat'](_0x378678),_0x4e465a=_0x10e44b,_0x1bb3d8=_0x317462;}else _0x9a6a05['isRemoved']?(_0x1bb3d8++,_0xe018d8['push'](_0x9a6a05)):(_0x4e465a++,_0xe018d8['push'](_0x2c4305));}}return _0xe018d8;}['_markSuggestions'](_0x3e0950,_0x1174d5){const _0x163b28=[];for(let _0x5c300f=0x0;_0x5c300f<_0x3e0950['length'];_0x5c300f++){for(let _0x361636=0x0;_0x361636<_0x3e0950[_0x5c300f]['markersStart']['length'];_0x361636++){const _0x2d6e8d=_0x3e0950[_0x5c300f]['markersStart'][_0x361636];if(!_0x1174d5['has'](_0x2d6e8d))continue;const {group:_0x28048c,type:_0x327d7a,authorId:_0x21d9b2}=_0x53d1a4(_0x2d6e8d);'revision-suggestion'!=_0x28048c||'insertion'!=_0x327d7a&&'deletion'!=_0x327d7a||(_0x163b28['unshift']({'type':_0x327d7a,'name':_0x2d6e8d,'userId':_0x21d9b2}),_0x3e0950[_0x5c300f]['markersStart']['splice'](_0x361636,0x1),_0x361636--);}_0x4d649e(_0x3e0950[_0x5c300f]);for(let _0x36e811=0x0;_0x36e811<_0x3e0950[_0x5c300f]['markersEnd']['length'];_0x36e811++){const _0x41bfd2=_0x3e0950[_0x5c300f]['markersEnd'][_0x36e811];if(!_0x1174d5['has'](_0x41bfd2))continue;const {group:_0x2a6116,type:_0x5c0122}=_0x53d1a4(_0x41bfd2);if('revision-suggestion'!=_0x2a6116||'insertion'!=_0x5c0122&&'deletion'!=_0x5c0122)continue;_0x3e0950[_0x5c300f]['markersEnd']['splice'](_0x36e811,0x1),_0x36e811--;const _0x120c6f=_0x163b28['findIndex'](_0x5f38d7=>_0x5f38d7['name']==_0x41bfd2);_0x120c6f>-0x1&&_0x163b28['splice'](_0x120c6f,0x1);}}function _0x53d1a4(_0x11a2ad){const _0x2e1157=_0x11a2ad['split'](':');return{'group':_0x2e1157[0x0],'type':_0x2e1157[0x1],'subType':_0x2e1157['length']>=0x5?_0x2e1157[0x2]:null,'id':_0x2e1157['length']<0x5?_0x2e1157[0x2]:_0x2e1157[0x3],'authorId':_0x2e1157['length']<0x5?_0x2e1157[0x3]:_0x2e1157[0x4],'markerCount':0x6==_0x2e1157['length']?_0x2e1157[0x5]:null};}function _0x4d649e(_0x18c61c){for(let _0x1cebee=0x0;_0x1cebee<_0x163b28['length'];_0x1cebee++){if(_0x18c61c['isAdded']&&'insertion'==_0x163b28[_0x1cebee]['type']&&_0x18c61c['isAdded']['userId']==_0x163b28[_0x1cebee]['userId'])return _0x18c61c['isAddSuggestion']=_0x163b28[_0x1cebee],void delete _0x18c61c['isAdded'];if(!_0x18c61c['isAdded']&&!_0x18c61c['isRemoved']&&'deletion'==_0x163b28[_0x1cebee]['type'])return void(_0x18c61c['isRemoveSuggestion']=_0x163b28[_0x1cebee]);}}}['_setDistance'](_0x50c276,_0x41a7b3){let _0x2833de=0x0,_0x297c32=!0x1;const _0x1dfb24=new Map();for(const _0x4707d5 of _0x50c276)_0x4707d5[_0x41a7b3]?_0x297c32&&(_0x2833de++,_0x297c32=!0x1):(_0x2833de++,_0x297c32=!0x0),_0x1dfb24['set'](_0x4707d5['id'],_0x2833de);for(let _0x55a8bb=0x0;_0x55a8bb<_0x50c276['length'];_0x55a8bb++){if('isRemoved'==_0x41a7b3&&_0x50c276[_0x55a8bb]['isAdded']||'isAdded'==_0x41a7b3&&_0x50c276[_0x55a8bb]['isRemoved'])continue;if('text'==_0x50c276[_0x55a8bb]['type']){_0x50c276[_0x55a8bb]['distance']=0x0;continue;}const _0x50d83a=_0x1dfb24['get'](_0x50c276[_0x55a8bb]['pairId']),_0x3e0b37=_0x1dfb24['get'](_0x50c276[_0x55a8bb]['id']);_0x50c276[_0x55a8bb]['distance']=_0x50d83a-_0x3e0b37;}}['_getRevisionsRange'](_0x4763dc,_0x713a6c,_0x3da5fb=!0x1){const _0x52c02f=[];let _0x3ded22=this['repository']['getIndex'](_0x4763dc),_0x4cde35=this['repository']['getIndex'](_0x713a6c);for(-0x1==_0x4cde35&&(_0x4cde35=this['repository']['_revisions']['length'],_0x3da5fb=!0x1);_0x3ded22<_0x4cde35;)_0x52c02f['push'](this['repository']['getRevision'](_0x3ded22)),_0x3ded22++;return _0x3da5fb&&_0x52c02f['push'](this['repository']['getRevision'](_0x3ded22)),_0x52c02f;}['_threeWayMerge'](_0x54553b,_0x2c49db,_0x551640,_0x629bfd){const _0x3c07df=this['editor']['model']['schema'];let _0x5f3066=_0x2c49db;for(;_0x54553b[_0x5f3066]&&_0x54553b[_0x5f3066]['isAdded'];)_0x5f3066++;let _0x6a539=_0x629bfd;for(;_0x551640[_0x6a539]&&_0x551640[_0x6a539]['isRemoved'];)_0x6a539++;_0x3b2de2(_0x54553b,_0x2c49db,_0x5f3066),_0x3b2de2(_0x551640,_0x629bfd,_0x6a539);const _0x341f2b=_0x551640['slice'](_0x629bfd,_0x6a539)['concat'](_0x54553b['slice'](_0x2c49db,_0x5f3066));return _0x341f2b['sort']((_0x52f052,_0x43bebf)=>_0x52f052['side']!=_0x43bebf['side']?_0x52f052['side']-_0x43bebf['side']:_0x52f052['level']!=_0x43bebf['level']?_0x52f052['level']-_0x43bebf['level']:_0x52f052['distance']!=_0x43bebf['distance']?_0x43bebf['distance']-_0x52f052['distance']:!!_0x52f052['isAdded']!=!!_0x43bebf['isAdded']?-0x1==_0x52f052['side']||0x0==_0x52f052['side']?_0x52f052['isAdded']?-0x1:0x1:_0x52f052['isAdded']?0x1:-0x1:_0x52f052['index']-_0x43bebf['index']),{'commonTape':_0x341f2b,'iEnd':_0x5f3066,'jEnd':_0x6a539};function _0x3b2de2(_0x6b3270,_0x9d483,_0xa45a82){let _0x275cbd=-0x1,_0x4aac8b=Number['POSITIVE_INFINITY'],_0xebd61f=!0x0;for(let _0x2659ac=_0x9d483;_0x2659ac<_0xa45a82;_0x2659ac++)if(_0x3c07df['isInline'](_0x6b3270[_0x2659ac]['item'])||(_0xebd61f=!0x1),_0x6b3270[_0x2659ac]['item']['startIndex']<_0x9d483&&(_0x275cbd=_0x2659ac),_0x6b3270[_0x2659ac]['item']['endIndex']>=_0xa45a82){_0x4aac8b=_0x2659ac;break;}_0xebd61f&&(_0x275cbd=_0xa45a82-0x1);for(let _0x4b8932=_0x9d483;_0x4b8932<_0xa45a82;_0x4b8932++)_0x6b3270[_0x4b8932]['side']=_0x4b8932<=_0x275cbd?-0x1:_0x4b8932<_0x4aac8b?0x0:0x1,_0x6b3270[_0x4b8932]['index']=_0x4b8932;let _0x4f24a9=0x0;for(let _0x384c0a=_0x9d483;_0x384c0a<=_0x275cbd;_0x384c0a++)0x0==_0x6b3270[_0x384c0a]['distance']?_0x6b3270[_0x384c0a]['level']=_0x4f24a9:(_0x4f24a9++,_0x6b3270[_0x384c0a]['level']=_0x4f24a9,_0x4f24a9++);for(let _0x5d20af=_0x9d483;_0x5d20af<_0xa45a82;_0x5d20af++)0x0==_0x6b3270[_0x5d20af]['side']&&(_0x6b3270[_0x5d20af]['level']=_0x4f24a9);_0x4f24a9=0x0;for(let _0x1a9919=_0xa45a82-0x1;_0x1a9919>=_0x4aac8b;_0x1a9919--)0x0==_0x6b3270[_0x1a9919]['distance']?_0x6b3270[_0x1a9919]['level']=_0x4f24a9:(_0x4f24a9--,_0x6b3270[_0x1a9919]['level']=_0x4f24a9,_0x4f24a9--);}}['_fixObsoleteTags'](_0x441f0c){const _0x122c5d=new Map(),_0x29fbc3=this['editor']['model']['schema'];for(let _0x574eaf=0x1;_0x574eaf<_0x441f0c['length'];_0x574eaf++){let _0x2d7e8b,_0x477317,_0x50c858;const _0x368c4e=_0x441f0c[_0x574eaf],_0x44bfcd=_0x441f0c[_0x574eaf-0x1];if('text'==_0x368c4e['type'])continue;if(_0x368c4e['type']!=_0x44bfcd['type'])continue;if(!_0x29fbc3['isBlock'](_0x44bfcd['item'])||_0x29fbc3['isLimit'](_0x44bfcd['item']))continue;if(!_0x29fbc3['isBlock'](_0x368c4e['item'])||_0x29fbc3['isLimit'](_0x368c4e['item']))continue;if((_0x441f0c[_0x574eaf]['isAdded']||_0x441f0c[_0x574eaf]['isAddSuggestion'])&&_0x441f0c[_0x574eaf-0x1]['isRemoved'])_0x2d7e8b=_0x441f0c[_0x574eaf],_0x477317=_0x441f0c[_0x574eaf-0x1],_0x50c858=_0x574eaf-0x1;else{if(!_0x441f0c[_0x574eaf]['isRemoved']||!_0x441f0c[_0x574eaf-0x1]['isAdded']&&!_0x441f0c[_0x574eaf-0x1]['isAddSuggestion'])continue;_0x2d7e8b=_0x441f0c[_0x574eaf-0x1],_0x477317=_0x441f0c[_0x574eaf],_0x50c858=_0x574eaf;}const _0x567ac2=_0x2d7e8b['level']==_0x477317['level'],_0x22aa6c=Math['abs'](_0x2d7e8b['level'])<Math['abs'](_0x477317['level'])&&0x0==_0x477317['distance'];(_0x567ac2||_0x22aa6c)&&(_0x122c5d['set'](_0x477317['id'],_0x2d7e8b['id']),_0x441f0c['splice'](_0x50c858,0x1),_0x574eaf--,_0x2d7e8b['isAdded']=!0x1);}for(let _0xf8850b=0x0;_0xf8850b<_0x441f0c['length'];_0xf8850b++)_0x122c5d['has'](_0x441f0c[_0xf8850b]['pairId'])&&(_0x441f0c[_0xf8850b]['pairId']=_0x122c5d['get'](_0x441f0c[_0xf8850b]['pairId']));}['_removeMissingPairs'](_0x5e89b1){const _0x194db5=new Set(_0x5e89b1['map'](_0x6f1e2e=>_0x6f1e2e['id']));for(let _0x277832=0x0;_0x277832<_0x5e89b1['length'];_0x277832++)_0x194db5['has'](_0x5e89b1[_0x277832]['pairId'])||0x0==_0x5e89b1[_0x277832]['distance']||(_0x5e89b1[_0x277832]['isIncorrect']=!0x0);return _0x5e89b1['filter'](_0x509ab0=>!_0x509ab0['isIncorrect']);}['_markMismatchedRemovedTags'](_0x3ef830){const _0x32bf13=new Set();for(let _0x41d7c1=0x0;_0x41d7c1<_0x3ef830['length'];_0x41d7c1++){if(_0x32bf13['has'](_0x3ef830[_0x41d7c1]['id'])&&_0x3ef830[_0x41d7c1]['isRemoved']&&(_0x3ef830[_0x41d7c1]['isIncorrect']=!0x0),_0x3ef830[_0x41d7c1]['isIncorrect'])continue;if(0x0==_0x3ef830[_0x41d7c1]['distance'])continue;if('elementStart'!=_0x3ef830[_0x41d7c1]['type'])continue;if(null==_0x3ef830[_0x41d7c1]['pairId'])continue;let _0x29fd91=_0x41d7c1+0x1,_0x52fb21=0x0;for(;_0x3ef830[_0x29fd91]['id']!=_0x3ef830[_0x41d7c1]['pairId'];)'elementStart'==_0x3ef830[_0x29fd91]['type']?_0x52fb21++:'elementEnd'==_0x3ef830[_0x29fd91]['type']&&_0x52fb21--,_0x29fd91++;if(0x0!=_0x52fb21){if(_0x3ef830[_0x41d7c1]['isRemoved'])_0x3ef830[_0x41d7c1]['isIncorrect']=!0x0;else{for(;_0x29fd91!=_0x41d7c1;)_0x3ef830[_0x29fd91]['isRemoved']&&0x0!=_0x3ef830[_0x29fd91]['distance']&&(_0x3ef830[_0x29fd91]['isIncorrect']=!0x0,_0x32bf13['add'](_0x3ef830[_0x29fd91]['pairId'])),_0x29fd91--;}}}return _0x3ef830['filter'](_0x2a774d=>!_0x2a774d['isIncorrect']);}['_removeUnsupportedChanges'](_0x53a7fc){const _0x4b6cfd=this['editor']['model']['schema'];for(let _0x49ef0f=0x0;_0x49ef0f<_0x53a7fc['length'];_0x49ef0f++){if(!(_0x53a7fc[_0x49ef0f]['isAdded']||_0x53a7fc[_0x49ef0f]['isAddSuggestion']||_0x53a7fc[_0x49ef0f]['isRemoved']||_0x53a7fc[_0x49ef0f]['isRemoveSuggestion']))continue;if(0x0==_0x53a7fc[_0x49ef0f]['distance'])continue;const _0x223a02=_0x53a7fc[_0x49ef0f]['item'];_0x4b6cfd['isBlock'](_0x223a02)||_0x4b6cfd['isLimit'](_0x223a02)||(_0x53a7fc[_0x49ef0f]['isAdded']&&delete _0x53a7fc[_0x49ef0f]['isAdded'],_0x53a7fc[_0x49ef0f]['isAddSuggestion']&&delete _0x53a7fc[_0x49ef0f]['isAddSuggestion'],_0x53a7fc[_0x49ef0f]['isRemoveSuggestion']&&delete _0x53a7fc[_0x49ef0f]['isRemoveSuggestion'],_0x53a7fc[_0x49ef0f]['isRemoved']&&(_0x53a7fc[_0x49ef0f]['isIncorrect']=!0x0));}return _0x53a7fc['filter'](_0x27e04b=>!_0x27e04b['isIncorrect']);}['_makeModelFromTape'](_0x227689,_0x1d5e21,_0x12f109){const _0x38786f=new at(),_0x25f536=[],_0x10e0b9=new Map(),_0x2935cb=this['editor']['model'],_0x132624=_0x2935cb['schema'],_0x4c0281=[_0x38786f],_0x429cee={},_0x47f7c1={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x3a1423=null;const _0x554a34=[0x0];for(let _0x4e6e62=0x0;_0x4e6e62<_0x227689['length'];_0x4e6e62++)if('elementStart'===_0x227689[_0x4e6e62]['type']){_0x227689[_0x4e6e62]['previousPosition']=_0x2935cb['createPositionFromPath'](_0x38786f,_0x554a34);const _0x28ccec=new nt(_0x227689[_0x4e6e62]['item']['name'],_0x227689[_0x4e6e62]['item']['getAttributes']());_0x4c0281[0x0]['_appendChild'](_0x28ccec),_0x554a34['push'](0x0),_0x4c0281['unshift'](_0x28ccec),_0x227689[_0x4e6e62]['nextPosition']=_0x2935cb['createPositionFromPath'](_0x38786f,_0x554a34);}else'elementEnd'===_0x227689[_0x4e6e62]['type']?(_0x4c0281['shift'](),_0x227689[_0x4e6e62]['previousPosition']=_0x2935cb['createPositionFromPath'](_0x38786f,_0x554a34),_0x554a34['pop'](),_0x554a34[_0x554a34['length']-0x1]++,_0x227689[_0x4e6e62]['nextPosition']=_0x2935cb['createPositionFromPath'](_0x38786f,_0x554a34)):(_0x227689[_0x4e6e62]['previousPosition']=_0x2935cb['createPositionFromPath'](_0x38786f,_0x554a34),_0x3a1423?_0x3a1423['_data']+=_0x227689[_0x4e6e62]['item']['data']:_0x3a1423=new ht(_0x227689[_0x4e6e62]['item']['data'],_0x227689[_0x4e6e62]['item']['getAttributes']()),_0x227689[_0x4e6e62+0x1]&&'text'===_0x227689[_0x4e6e62+0x1]['type']&&_0x3ea39a(_0x3a1423,_0x227689[_0x4e6e62+0x1]['item'])||(_0x4c0281[0x0]['_appendChild'](_0x3a1423),_0x3a1423=null),_0x554a34[_0x554a34['length']-0x1]+=_0x227689[_0x4e6e62]['item']['offsetSize'],_0x227689[_0x4e6e62]['nextPosition']=_0x2935cb['createPositionFromPath'](_0x38786f,_0x554a34));for(let _0x488ce0=0x0;_0x488ce0<_0x227689['length'];_0x488ce0++){const _0xfb1e37=_0x227689[_0x488ce0]['previousPosition'],_0x5651cd=_0x227689[_0x488ce0]['nextPosition'];for(const _0x1b46e5 of _0x227689[_0x488ce0]['markersStart'])_0x10e0b9['set'](_0x1b46e5,{'start':_0xfb1e37,'end':null});_0x5ed8b3('isRemoveSuggestion',_0x488ce0,_0xfb1e37,_0x5651cd),_0x5ed8b3('isAddSuggestion',_0x488ce0,_0xfb1e37,_0x5651cd),_0x5ed8b3('isRemoved',_0x488ce0,_0xfb1e37,_0x5651cd),_0x5ed8b3('isAdded',_0x488ce0,_0xfb1e37,_0x5651cd);for(const _0x8e456f of _0x227689[_0x488ce0]['markersEnd']){const _0x5b1fe7=_0x10e0b9['get'](_0x8e456f);_0x5b1fe7?_0x5b1fe7['end']=_0x5651cd:_0x10e0b9['set'](_0x8e456f,{'start':_0x5651cd,'end':_0x5651cd});}}for(const [_0x56895f,_0x1f3aa4]of _0x10e0b9){const _0x1796c3=this['editor']['model']['createRange'](_0x1f3aa4['start'],_0x1f3aa4['end']);_0x38786f['markers']['set'](_0x56895f,_0x1796c3);}return _0x25f536['sort']((_0x866076,_0x7b8adb)=>{const _0x497953=_0x38786f['markers']['get']('revision:'+_0x866076['id']),_0x2346c9=_0x38786f['markers']['get']('revision:'+_0x7b8adb['id']);return _0x497953['start']['isBefore'](_0x2346c9['start'])?-0x1:_0x497953['start']['isAfter'](_0x2346c9['start'])?0x1:_0x497953['end']['isBefore'](_0x2346c9['end'])?-0x1:_0x497953['end']['isAfter'](_0x2346c9['end'])?0x1:'add'===_0x866076['type']?-0x1:0x1;}),{'root':_0x38786f,'changes':_0x25f536};function _0x5ed8b3(_0x369ced,_0x1a7a18,_0x7ae18b,_0xcfd994){const _0x1b307e=!!_0x227689[_0x1a7a18][_0x369ced],_0x5ca57a=_0x1b307e?_0x227689[_0x1a7a18][_0x369ced]['userId']:null,_0x1fbe0c=_0x1a7a18===_0x227689['length']-0x1,_0x1c55ba=_0x47f7c1[_0x369ced][0x0],_0x289391=_0x132624['isObject'](_0x227689[_0x1a7a18]['item']);!_0x429cee[_0x369ced]&&_0x1b307e?_0x429cee[_0x369ced]={'start':_0x7ae18b,'tapeItem':_0x227689[_0x1a7a18],'userId':_0x5ca57a,'type':_0x369ced}:_0x429cee[_0x369ced]&&!_0x1b307e?(_0x429cee[_0x369ced]['end']=_0x7ae18b,_0x20a317(_0x429cee[_0x369ced]),_0x429cee[_0x369ced]=null):_0x429cee[_0x369ced]&&_0x1b307e&&_0x429cee[_0x369ced]['userId']!==_0x5ca57a&&(_0x429cee[_0x369ced]['end']=_0x7ae18b,_0x1c55ba&&_0x1c55ba['userId']===_0x429cee[_0x369ced]['userId']||_0x20a317(_0x429cee[_0x369ced]),_0x429cee[_0x369ced]={'start':_0x7ae18b,'tapeItem':_0x227689[_0x1a7a18],'userId':_0x5ca57a,'type':_0x369ced}),_0x429cee[_0x369ced]&&_0x289391&&('elementStart'!==_0x227689[_0x1a7a18]['type']||_0x1c55ba&&_0x1c55ba['userId']===_0x5ca57a||_0x47f7c1[_0x369ced]['unshift']({'userId':_0x5ca57a,'object':_0x227689[_0x1a7a18]['item'],'change':_0x429cee[_0x369ced]}),'elementEnd'===_0x227689[_0x1a7a18]['type']&&_0x1c55ba&&_0x1c55ba['object']===_0x227689[_0x1a7a18]['item']&&(_0x47f7c1[_0x369ced]['shift'](),_0x429cee[_0x369ced]=_0x1c55ba['change'])),_0x429cee[_0x369ced]&&_0x1fbe0c&&(_0x429cee[_0x369ced]['end']=_0xcfd994,_0x20a317(_0x429cee[_0x369ced]),_0x429cee[_0x369ced]=null);}function _0x20a317({start:_0x12d477,end:_0x4293d6,tapeItem:_0x2fc9e5,userId:_0x65b99,type:_0x94174d}){const _0x112250=_0x2fc9e5['item'],_0x1eeed6=_0x2935cb['schema']['isBlock'](_0x112250)&&!_0x2935cb['schema']['isLimit'](_0x112250),_0x389a80=_0x12d477['nodeAfter']==_0x4293d6['parent']&&_0x4293d6['isAtStart'];if(_0x1eeed6&&_0x389a80)return;const _0x41d608=_0x2935cb['createRange'](_0x12d477,_0x4293d6),_0x40e5ee=_0x1d5e21['get'](_0x65b99),_0x8eae42=new G({'author':_0x40e5ee,'type':'isAdded'==_0x94174d||'isAddSuggestion'==_0x94174d?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x94174d||'isRemoveSuggestion'==_0x94174d},'createdAt':new Date(),'rootName':_0x12f109});_0x25f536['push'](_0x8eae42),_0x38786f['markers']['set']('revision:'+_0x8eae42['id'],_0x41d608);}function _0x3ea39a(_0x537e51,_0x5735b0){const _0x470076=_0x537e51['getAttributes'](),_0xe0c203=_0x5735b0['getAttributes']();for(const _0x410690 of _0x470076){if(_0x410690[0x1]!==_0x5735b0['getAttribute'](_0x410690[0x0]))return!0x1;_0xe0c203['next']();}return _0xe0c203['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x1eae7b=>{const _0x149dbd=_0x1eae7b['markerName']['split'](':')[0x1],_0x49c8ae=this['_getChangeFromId'](_0x149dbd);if(!_0x49c8ae)return null;const _0x5bc5a2='add'==_0x49c8ae['type']?'insertion':'deletion',_0x5326a0=['ck-suggestion-marker','ck-suggestion-marker-'+_0x5bc5a2];return _0x49c8ae['data']['isSuggestion']&&_0x5326a0['push']('ck-suggestion-marker-'+_0x5bc5a2+'-new'),this['activeChange']==_0x49c8ae&&_0x5326a0['push']('ck-suggestion-marker--active'),{'classes':_0x5326a0,'attributes':{'data-change-id':_0x149dbd}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x2be7dd=>{_0x2be7dd['on']('element:pre',(_0x1d8ab4,_0x3b736d,_0x3c5a5e)=>{const _0x1159e1=_0x3b736d['viewItem']['getChild'](0x0);if(!_0x1159e1||!_0x1159e1['is']('element','code'))return;if(!_0x3c5a5e['consumable']['consume'](_0x1159e1,{'attributes':['vid_start','vid_end']}))return;const _0x2ec2a3=_0x3b736d['modelRange']['start']['nodeAfter'];_0x3c5a5e['writer']['setAttribute']('vid_start',_0x1159e1['getAttribute']('vid_start'),_0x2ec2a3),_0x3c5a5e['writer']['setAttribute']('vid_end',_0x1159e1['getAttribute']('vid_end'),_0x2ec2a3);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x49af6a=>{_0x49af6a['on']('element',(_0x27ee7c,_0x5ce24a,_0x5f0705)=>{if(!_0x5f0705['consumable']['consume'](_0x5ce24a['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x5ce24a['modelRange']['isCollapsed'])return;const _0x47b314=_0x5ce24a['modelRange']['start']['nodeAfter'];_0x47b314['hasAttribute']('vid_start')||_0x47b314['hasAttribute']('vid')||(_0x5f0705['writer']['setAttribute']('vid_start',_0x5ce24a['viewItem']['getAttribute']('vid_start'),_0x47b314),_0x5f0705['writer']['setAttribute']('vid_end',_0x5ce24a['viewItem']['getAttribute']('vid_end'),_0x47b314));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x4f4b44=>_0x4f4b44['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0xf2c623,[,_0xa47a4d])=>{['vid_start','vid_end','vid']['includes'](_0xa47a4d)&&(_0xf2c623['return']=!0x0,_0xf2c623['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x41dfd0=>{_0x41dfd0['on']('attribute:vid',(_0x468569,_0x317d56,_0x3cc1ae)=>{if('\x20'!=_0x317d56['item']['data']||_0x317d56['item']['parent']['maxOffset']>0x1)return;if(!_0x3cc1ae['consumable']['consume'](_0x317d56['item'],_0x468569['name']))return;const _0x2fad46=_0x3cc1ae['writer'],_0x47fb75=_0x3cc1ae['mapper']['toViewRange'](_0x317d56['range']);_0x2fad46['wrap'](_0x47fb75,_0x2fad46['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x3bb061){const _0x41b8d5=_0x3bb061['plugins']['get']('RevisionViewer');return(_0x28b8d3,_0x2ad17c,_0x1bc7c3)=>{const _0x5ae02a=_0x2ad17c['markerName']['split'](':')[0x1],_0x41fc6c=_0x41b8d5['_getChangeFromId'](_0x5ae02a);if(!_0x41fc6c)return null;const _0x595818='add'==_0x41fc6c['type']?'split':'merge';if(!_0x1bc7c3['consumable']['test'](_0x2ad17c['markerRange'],_0x28b8d3['name']))return;const _0x540ed0=_0x2ad17c['markerRange']['getWalker'](),_0x2e5297=_0x2ad17c['markerRange']['start'],_0x2e717f=_0x3bb061['model']['schema'];let _0x4a6e55=null,_0x313485=null,_0x4b4a28=!0x1,_0x3d9d13=!0x1;for(const _0x38437a of _0x540ed0){const _0x2cb411=_0x38437a['item'];_0x4b4a28=_0x4b4a28||_0x2e717f['isContent'](_0x2cb411);const _0x227346=_0x1bc7c3['mapper']['toViewElement'](_0x2cb411);if(_0x227346&&_0x227346['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x38437a['type']&&(_0x2e717f['isBlock'](_0x2cb411)&&!_0x2e717f['isLimit'](_0x2cb411)&&(_0x2cb411['nextSibling']||_0x2e5297['isAtEnd']?_0x4a6e55&&_0x4a6e55['parent']==_0x2cb411||(_0x4a6e55=_0x2cb411,_0x53eb74(_0x38437a['previousPosition']),_0x3d9d13=!0x0):_0x313485=_0x313485||_0x38437a['previousPosition']));}function _0x53eb74(_0x1ce8e4){const _0x218111=_0x1bc7c3['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x595818}),_0x152325=_0x1bc7c3['mapper']['toViewPosition'](_0x1ce8e4);_0x41fc6c['data']['isSuggestion']&&_0x1bc7c3['writer']['addClass']('ck-suggestion-marker-'+_0x595818+'-new',_0x218111),_0x41b8d5['activeChange']==_0x41fc6c&&_0x1bc7c3['writer']['addClass']('ck-suggestion-marker--active',_0x218111),_0x1bc7c3['writer']['insert'](_0x152325,_0x218111),_0x1bc7c3['mapper']['bindElementToMarker'](_0x218111,_0x2ad17c['markerName']);}_0x4b4a28||_0x3d9d13||!_0x313485||_0x53eb74(_0x313485);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x2130f8,_0x3cff25,_0xf3eb7)=>{const _0x2f11a7=_0xf3eb7['mapper']['markerNameToElements'](_0x3cff25['markerName']);if(_0x2f11a7){for(const _0x2dcdac of _0x2f11a7)(_0x2dcdac['hasClass']('ck-suggestion-marker-split')||_0x2dcdac['hasClass']('ck-suggestion-marker-merge'))&&(_0xf3eb7['mapper']['unbindElementFromMarkerName'](_0x2dcdac,_0x3cff25['markerName']),_0xf3eb7['writer']['remove'](_0x2dcdac));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x956d5b,_0x4d21d1,_0xc0f389)=>{const _0x4f5b0e=_0x4d21d1['markerName']['split'](':')[0x1],_0x2aa8dd=this['_getChangeFromId'](_0x4f5b0e);if(!_0x2aa8dd)return null;const _0x4cc6b4='add'==_0x2aa8dd['type']?'split':'merge';if(_0xc0f389['consumable']['test'](_0x4d21d1['markerRange'],_0x956d5b['name']))for(const _0x2956eb of _0x4d21d1['markerRange']['getItems']()){if(!_0x2956eb['is']('element','softBreak'))continue;const _0x55a278=_0xc0f389['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x4cc6b4}),_0x17dd0d=_0xc0f389['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x2956eb));_0x2aa8dd['data']['isSuggestion']&&_0xc0f389['writer']['addClass']('ck-suggestion-marker-'+_0x4cc6b4+'-new',_0x55a278),this['activeChange']==_0x2aa8dd&&_0xc0f389['writer']['addClass']('ck-suggestion-marker--active',_0x55a278),_0xc0f389['writer']['insert'](_0x17dd0d,_0x55a278),_0xc0f389['mapper']['bindElementToMarker'](_0x55a278,_0x4d21d1['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x1a775c=>{for(const _0x1214d9 of this['editor']['model']['document']['getRootNames']()){const _0x4bf0c7=this['editor']['model']['document']['getRoot'](_0x1214d9),_0x204729=this['editor']['editing']['view']['document']['getRoot'](_0x1214d9);if(_0x204729){const _0x174c95=_0x4bf0c7['getAttribute']('revisionHistoryAttachChange');if(_0x1a775c['removeAttribute']('data-change-id',_0x204729),_0x1a775c['removeClass']('ck-revision-history-root-add',_0x204729),_0x1a775c['removeClass']('ck-revision-history-root-remove',_0x204729),_0x1a775c['removeClass']('ck-revision-history-root--active',_0x204729),_0x174c95){const _0x135ca1=this['_getChangeFromId'](_0x174c95);if(!_0x135ca1)return null;_0x1a775c['setAttribute']('data-change-id',_0x174c95,_0x204729),_0x1a775c['addClass']('ck-revision-history-root-'+_0x135ca1['type'],_0x204729),this['activeChange']==_0x135ca1&&_0x1a775c['addClass']('ck-revision-history-root--active',_0x204729);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x55e174=>'revision-comment:'+_0x55e174,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x4d5fd9=>'revision-suggestion:'+_0x4d5fd9,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0xdc4ae=>({'name':'suggestion:'+_0xdc4ae,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x4a7da2=>{const _0x1b33d6=_0x4a7da2['markerName']['split'](':')[0x1];return'insertion'!=_0x1b33d6&&'deletion'!=_0x1b33d6?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x1b33d6]};}}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:deletion',Q(this['editor'],'merge'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:insertion',Q(this['editor'],'split'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision-suggestion',(_0xef8464,_0x1a4133,_0x3dee74)=>{const _0x2ba4be=_0x3dee74['mapper']['markerNameToElements'](_0x1a4133['markerName']);if(_0x2ba4be){for(const _0x424cd4 of _0x2ba4be)_0x424cd4['is']('uiElement')&&(_0x3dee74['mapper']['unbindElementFromMarkerName'](_0x424cd4,_0x1a4133['markerName']),_0x3dee74['writer']['remove'](_0x424cd4));}},{'priority':'high'});}['_getChangeFromId'](_0x1a8467){return this['_changeIdToChange']['get'](_0x1a8467);}['_getViewForChange'](_0xe03c13){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new z(this['editor']['locale'],_0xe03c13),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0xd03b6d,_0x3d7ca1,_0x639440,_0x39a6b3)=>{_0x39a6b3&&this['_balloon']['remove'](_0x39a6b3),_0x639440&&(this['_balloon']['add']({'view':_0x639440,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x4f9ab8=this['editor']['editing'],_0x2fc8ea=this['_getChangeFromId'](_0x639440['changeId']);let _0x2042a3;if(_0x2fc8ea['data']['isOnRoot']){const _0x3eec28=_0x4f9ab8['view']['getDomRoot'](_0x2fc8ea['rootName']);_0x2042a3=Array['from'](_0x3eec28['getClientRects']());}else{const _0xc04c1=this['editor']['model']['markers']['get']('revision:'+_0x639440['changeId']);_0x2042a3=Array['from'](_0x4f9ab8['mapper']['markerNameToElements'](_0xc04c1['name']))['map'](_0x5607ef=>_0x4f9ab8['view']['domConverter']['mapViewToDom'](_0x5607ef))['map'](_0x527ae1=>Array['from'](_0x527ae1['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x2042a3[0x0];return _0x2042a3['find'](_0x1ea4b7=>_0x1ea4b7['top']-0x3<=this['_activeViewTarget']['y']&&_0x1ea4b7['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x1ea4b7['left']-0x3<=this['_activeViewTarget']['x']&&_0x1ea4b7['right']+0x3>=this['_activeViewTarget']['x'])||_0x2042a3[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x151c28,_0x5f23be,_0x31e923,_0x22ce7c)=>{this['activeView']=_0x31e923?this['_getViewForChange'](_0x31e923):null,this['editor']['model']['change'](()=>{const _0x47c6fa=this['editor']['editing'];_0x22ce7c&&(_0x22ce7c['data']['isOnRoot']?_0x47c6fa['view']['change'](_0x5f4c59=>{_0x5f4c59['removeClass']('ck-revision-history-root--active',_0x47c6fa['view']['document']['getRoot'](_0x22ce7c['rootName']));}):_0x47c6fa['reconvertMarker']('revision:'+_0x22ce7c['id'])),_0x31e923&&(_0x31e923['data']['isOnRoot']?_0x47c6fa['view']['change'](_0x1c4cb8=>{_0x1c4cb8['addClass']('ck-revision-history-root--active',_0x47c6fa['view']['document']['getRoot'](_0x31e923['rootName']));}):_0x47c6fa['reconvertMarker']('revision:'+_0x31e923['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x1adc0e,_0x34b049)=>{if(this['activeChange'])return;const _0x24f188=this['_findChangeIdFromDomTarget'](_0x34b049['target']),_0x3ce00d=this['_changeIdToChange']['get'](_0x24f188);_0x3ce00d?(this['_activeViewTarget']={'x':_0x34b049['domEvent']['x'],'y':_0x34b049['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x3ce00d)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x21c8f7,_0x1d7dec)=>{const _0x4f55e7=this['_findChangeIdFromDomTarget'](_0x1d7dec['target']),_0x1751c6=this['_changeIdToChange']['get'](_0x4f55e7);_0x1751c6?(this['_activeViewTarget']={'x':_0x1d7dec['domEvent']['x'],'y':_0x1d7dec['domEvent']['y']},_0x1751c6===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x1751c6):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x3f3cb3){do{const _0x39d56d=_0x3f3cb3['getAttribute']('data-change-id');if(_0x39d56d)return _0x39d56d;_0x3f3cb3=_0x3f3cb3['parent'];}while(_0x3f3cb3);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x588924=>{for(const _0x171fe2 of this['editor']['model']['markers'])_0x588924['removeMarker'](_0x171fe2);});}}function Q(_0xad07ec,_0x46433d){return(_0x2a2938,_0xad5498,_0x5b7c17)=>{if(!_0x5b7c17['consumable']['test'](_0xad5498['markerRange'],_0x2a2938['name']))return;const _0x407cb9=_0xad5498['markerRange']['getWalker'](),_0x38ac99=_0xad5498['markerRange']['start'],_0x59ade7=_0xad07ec['model']['schema'];let _0x1c4081=null,_0x244a8a=null,_0x40a3d7=!0x1,_0x483ab3=!0x1;for(const _0x4e7a25 of _0x407cb9){const _0x205d45=_0x4e7a25['item'];_0x40a3d7=_0x40a3d7||_0x59ade7['isContent'](_0x205d45);const _0x8e41c=_0x5b7c17['mapper']['toViewElement'](_0x205d45);if(_0x8e41c&&_0x8e41c['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x4e7a25['type']&&(_0x59ade7['isBlock'](_0x205d45)&&!_0x59ade7['isLimit'](_0x205d45)&&(_0x205d45['nextSibling']||_0x38ac99['isAtEnd']?_0x1c4081&&_0x1c4081['parent']==_0x205d45||(_0x1c4081=_0x205d45,_0xb494e2(_0x4e7a25['previousPosition']),_0x483ab3=!0x0):_0x244a8a=_0x244a8a||_0x4e7a25['previousPosition']));}function _0xb494e2(_0x2c4896){const _0x2acc7e=_0x5b7c17['mapper']['toViewPosition'](_0x2c4896),_0x473d11=_0x5b7c17['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x46433d});_0x5b7c17['writer']['insert'](_0x2acc7e,_0x473d11),_0x5b7c17['mapper']['bindElementToMarker'](_0x473d11,_0xad5498['markerName']);}_0x40a3d7||_0x483ab3||!_0x244a8a||_0xb494e2(_0x244a8a);};}class ct extends _0x7a99d7{constructor(_0x4f7565){super(_0x4f7565);const _0x138a21=_0x4f7565['plugins']['get'](l);this['affectsData']=!0x1,this['listenTo'](_0x138a21,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x138a21,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x387bc3=this['editor'],_0x46c727=_0x387bc3['plugins']['get'](l),_0x1bbe47=_0x46c727['isReady']?_0x46c727['diff']['newRevisionId']:null;_0x387bc3['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x1bbe47);}['refresh'](){const {isReady:_0x829ec1,isEnabled:_0x1ce1ed,repository:_0xa1c42e,diff:_0x56739e}=this['editor']['plugins']['get'](l),_0x26d908=_0x56739e&&_0xa1c42e['getLaterVisibleRevision'](_0x56739e['newRevisionId']);this['isEnabled']=_0x829ec1&&_0x1ce1ed&&Boolean(_0x26d908);}}class ut extends _0x7a99d7{['_step'];constructor(_0x1dea19,{direction:_0x26a7cf}){super(_0x1dea19);const _0x2cf3a0=_0x1dea19['plugins']['get'](l);this['affectsData']=!0x1,this['_step']='forward'===_0x26a7cf?0x1:-0x1,this['listenTo'](_0x2cf3a0,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x2cf3a0,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x2cf3a0,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x2b3f7e=this['editor'],_0x201d9d=_0x2b3f7e['plugins']['get'](l),{isNavigationMode:_0x1fd027,currentChangeNumber:_0x540de5}=_0x201d9d;let _0x2386f9;if(_0x201d9d['activeChange']=_0x1fd027?_0x201d9d['diff']['changes']['get'](_0x540de5+this['_step']):_0x201d9d['diff']['changes']['first'],_0x201d9d['activeChange']['data']['isOnRoot'])_0x2386f9=_0x2b3f7e['editing']['view']['getDomRoot'](_0x201d9d['activeChange']['rootName']);else{const _0x226c45=_0x2b3f7e['model']['markers']['get']('revision:'+_0x201d9d['activeChange']['id']);_0x2386f9=_0x4445dc(_0x2b3f7e['editing'],_0x226c45);}_0x107d65({'target':_0x2386f9,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x17fc07,currentChangeNumber:_0x2ac9f9,numberOfChanges:_0x5c47c5,isReady:_0x3b54cc,isEnabled:_0x36eacd}=this['editor']['plugins']['get'](l);this['isEnabled']=!!(_0x36eacd&&_0x3b54cc&&_0x5c47c5)&&(!_0x17fc07||(0x1===this['_step']?_0x2ac9f9<_0x5c47c5-0x1:_0x2ac9f9>0x0));}}class Ri extends _0x3dfb19{constructor(_0x1b77a4){super(_0x1b77a4);const _0x49e2a4=this['bindTemplate'],_0x384fa6=new _0x1c6060(_0x1b77a4),_0x23f135=new _0x1c6060(_0x1b77a4);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',(_0x51f727,_0x21f8d8)=>_0x51f727&&_0x21f8d8>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x33bb88,_0x461505,_0x162076,_0x645234)=>{if(!_0x33bb88)return R(_0x1b77a4,'Loading...');if(!_0x162076)return R(_0x1b77a4,'No\x20changes');const _0x50f4d1=R(_0x1b77a4,'NUMBER_OF_CHANGES',_0x162076);return _0x645234?R(_0x1b77a4,'X_OF_Y_CHANGES',[_0x461505+0x1,_0x162076]):_0x50f4d1;}),_0x384fa6['set']({'label':R(_0x1b77a4,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x26dbf8}),_0x23f135['set']({'label':R(_0x1b77a4,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x422d7a}),_0x384fa6['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x23f135['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x384fa6['on']('execute',()=>this['fire']('execute','backward')),_0x23f135['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',_0x49e2a4['if']('_isStatusLabelVisible','ck-hidden',_0x1dabb2=>!_0x1dabb2)]},'children':[{'text':_0x49e2a4['to']('isNavigationMode',_0xf3acdf=>_0xf3acdf?R(_0x1b77a4,'EDIT_X_OF_Y_REVISIONS')+':\x20':R(_0x1b77a4,'Total')+':\x20')}]},{'text':_0x49e2a4['to']('_statusText')}]},new _0x20c73d(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x384fa6,_0x23f135]}]});}}const ge='ck-editor__editable__loading-overlay';class ji extends _0x25ad5f{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x598683=this['editor']['editing']['view'];_0x598683['change'](_0x5d83c2=>{for(const _0xdce198 of _0x598683['document']['roots'])_0x5d83c2['addClass'](ge,_0xdce198);});}['hide'](){const _0x3ac5af=this['editor']['editing']['view'];_0x3ac5af['change'](_0x4ecd5b=>{for(const _0x5541ab of _0x3ac5af['document']['roots'])_0x4ecd5b['removeClass'](ge,_0x5541ab);});}}class u extends _0x25ad5f{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l,ji];}['init'](){const _0x19b69e=this['editor'],_0x5c5953=_0x19b69e['plugins']['get'](l),_0x2a4a82=_0x19b69e['plugins']['get'](ji);_0x19b69e['ui']['componentFactory']['add']('exitToEditing',_0x942438=>{const _0x3b8c6b=new _0x1c6060(_0x942438);return _0x3b8c6b['set']({'label':R(_0x942438,'Back\x20to\x20editing'),'icon':_0x1f842f,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x3b8c6b,'execute',()=>{_0x19b69e['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x3b8c6b;}),_0x19b69e['ui']['componentFactory']['add']('restoreRevision',_0xbdb8c0=>{const _0x245443=new _0x1c6060(_0xbdb8c0);return _0x245443['set']({'label':R(_0xbdb8c0,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x245443['bind']('isEnabled')['to'](_0x19b69e['commands']['get']('restoreRevision')),this['listenTo'](_0x245443,'execute',()=>_0x19b69e['execute']('restoreRevision')),_0x245443;}),_0x19b69e['ui']['componentFactory']['add']('changesNavigation',_0x506d95=>{const _0x53f2c9=new Ri(_0x506d95),_0x2a62f5=_0x19b69e['commands']['get']('showPreviousChange'),_0x1ca658=_0x19b69e['commands']['get']('showNextChange');return _0x53f2c9['bind']('isBackwardNavigationEnabled')['to'](_0x2a62f5,'isEnabled'),_0x53f2c9['bind']('isForwardNavigationEnabled')['to'](_0x1ca658,'isEnabled'),_0x53f2c9['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x5c5953),this['listenTo'](_0x53f2c9,'execute',(_0x3640a2,_0x455b0e)=>{_0x19b69e['execute']('forward'===_0x455b0e?'showNextChange':'showPreviousChange');}),_0x53f2c9;}),_0x2a4a82['show'](),_0x5c5953['on']('change:isReady',(_0x4ae85c,_0x2af7ac,_0x720f06)=>{_0x720f06?_0x2a4a82['hide']():_0x2a4a82['show']();});}}class li extends ti{['_resizeObserver']=null;constructor(_0x3c5c0c,_0x24d527){super(_0x3c5c0c,_0x24d527);const _0x2175ea=this['bindTemplate'];this['set']({'label':R(_0x3c5c0c,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=R(_0x3c5c0c,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x2175ea['to']('_tooltipString'),'data-cke-tooltip-position':'s','data-cke-tooltip-class':'ck-tooltip_multi-line'}});}['render'](){super['render'](),this['_resizeObserver']=new et(this['fieldView']['element'],()=>this['_updateTooltipText']()),this['listenTo'](this['fieldView'],'input',()=>this['_updateTooltipText']());}['destroy'](){super['destroy'](),this['_resizeObserver']&&this['_resizeObserver']['destroy']();}['_updateTooltipText'](){const _0x44ff16=this['fieldView']['element'];this['_tooltipString']=_0x44ff16['scrollWidth']>_0x44ff16['clientWidth']&&_0x44ff16['value']||'';}}class vi extends _0x3dfb19{constructor(_0x9ad3f6,_0x4c7005,_0x2b7f65){super(_0x9ad3f6);const _0x446c12=new _0x64902d();_0x446c12['set']({'content':_0x3d0b51,'viewBox':'0\x200\x2011\x2010'});const _0x11332d=['ck','ck-revision-history-sidebar__revision-author'];_0x2b7f65&&_0x11332d['push']('ck-revision-history-sidebar__revision-author_creator');const _0x175773=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':R(_0x9ad3f6,_0x2b7f65?'Revision\x20creator':'Revision\x20author')},'children':[_0x446c12,_0x4c7005['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x11332d},'children':_0x175773});}}function mi(_0x3188fd,_0x579cae){const _0x2a6bbf=_0x3188fd['bindTemplate'],_0x14bc6a=_0x3188fd['locale'],_0x3d1e25=_0x16a93f(_0x14bc6a);_0x3d1e25['panelPosition']='sw';const _0x2b5573=function(_0x5d4d0a,_0x9016fd){const _0x2e46fa=function(_0x551497,_0x433611){const _0x12ebd1=_0x551497['locale'],_0x478bda={'Compare\x20against\x20selected':R(_0x12ebd1,'Compare\x20against\x20selected'),'Name\x20this\x20revision':R(_0x12ebd1,'Name\x20this\x20revision'),'Restore\x20this\x20revision':R(_0x12ebd1,'Restore\x20this\x20revision')};return _0x433611['map'](_0x3aa8c3=>{const _0x241f77=_0x478bda[_0x3aa8c3['name']];return _0x241f77&&_0x241f77!==_0x3aa8c3['name']&&(_0x3aa8c3['name']=_0x241f77),_0x3aa8c3;});}(_0x5d4d0a,_0x9016fd),_0x15b27f=new _0x2da206();for(const _0x3aca31 of _0x2e46fa){const _0x2f73a4={'type':'button','model':new to({'label':_0x3aca31['name'],'class':_0x3aca31['class'],'withText':!0x0,'role':'menuitem','_action':_0x3aca31['action']})};_0x2f73a4['model']['bind']('isEnabled')['to'](_0x5d4d0a,'isActionsDropdownOpen',_0x5b2d0f=>'function'!=typeof _0x3aca31['isEnabled']||(!_0x5b2d0f||_0x3aca31['isEnabled'](_0x5d4d0a))),_0x15b27f['add'](_0x2f73a4);}return _0x15b27f;}(_0x3188fd,_0x579cae);return _0x3188fd['bind']('isActionsDropdownOpen')['to'](_0x3d1e25,'isOpen'),_0x3d1e25['buttonView']['set']({'label':R(_0x14bc6a,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x39a297}),_0x3d1e25['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x2a6bbf['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x2a6bbf['to'](_0x2694b5=>_0x2694b5['stopPropagation']())}}),_0x3d1e25['on']('execute',_0x44510c=>{_0x3188fd['isReady']&&'function'==typeof _0x44510c['source']['_action']&&_0x44510c['source']['_action'](_0x3188fd);}),_0xedab6f(_0x3d1e25,_0x2b5573,{'role':'menu'}),_0x3d1e25['listenTo'](_0x3188fd,'change:isActionsDropdownOpen',(_0x63d070,_0xad3ed5,_0x1fd276)=>{if(_0x1fd276)for(const _0x42daec of _0x3d1e25['listView']['items']){const _0x4cc21e=_0x42daec['children']['first'],_0x375e62=_0x579cae['find'](_0x4a9251=>_0x4a9251['action']===_0x4cc21e['_action'])['isVisible'];_0x42daec['isVisible']=void 0x0===_0x375e62||_0x375e62(_0x3188fd);}}),_0x3d1e25;}class pi extends/* #__PURE__ -- @preserve */
|
|
27
|
-
|
|
23
|
+
import{ObservableMixin as _0x26b56e,uid as _0x173cdc,Collection as _0x28f4f5,logWarning as _0xafa18d,FocusTracker as _0x78af34,KeystrokeHandler as _0x39d239,scrollViewportToShowTarget as _0x13bd49,ResizeObserver as ot,ElementReplacer as it,CKEditorError as _0x22ea28}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x1fabc1,set as _0x58d335,unset as _0x1c871a,isEqual as _0xadfd67}from'es-toolkit/compat';import{Plugin as _0x1973ac,PendingActions as _0x17d460,Command as _0x3c48a2,ElementApiMixin as _0x31b8b8,Editor as _0x4dfa8c}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x4a7029,getMarkerDomElement as _0x41a099,ConfirmMixin as _0x4b52b0,sanitizeEditorConfig as _0x2a2211}from'ckeditor5-collaboration/dist/index.js';import{ViewContainerElement as _0x277f6b,ViewAttributeElement as _0x28a35c,ViewEmptyElement as _0x1aec30,ViewRawElement as _0x31e3cf,ViewUIElement as _0x3d0231,ViewDocumentFragment as _0x5506b2,ViewText as _0x18930f,ViewElement as _0x43bb9f,Element as nt,Range as rt,Position as at,DocumentFragment as ht,Text as ct}from'@ckeditor/ckeditor5-engine/dist/index.js';import{IconHistory as _0x2d57fb,IconChevronUp as _0x3cd2e9,IconChevronDown as _0x570090,IconUndo as _0x2b3260,IconUser as _0x2a0aaa,IconThreeVerticalDots as _0xeddefb}from'@ckeditor/ckeditor5-icons/dist/index.js';import{CssTransitionDisablerMixin as _0x1c562a,View as _0x3269ad,submitHandler as _0x1c2a08,LabeledFieldView as et,createLabeledInputText as ti,createDropdown as _0x35ed0a,ListView as _0x1b48dd,ListItemView as _0x15e797,ButtonView as _0x4bd511,MenuBarMenuView as _0x4882bd,MenuBarMenuListView as _0x32b68d,MenuBarMenuListItemView as _0x59b3f1,MenuBarMenuListItemButtonView as _0x20703f,ContextualBalloon as _0x5f3da8,ToolbarSeparatorView as _0x5e45f2,IconView as _0x5f034c,addListToDropdown as _0x3e203f,UIModel as to,EditorUI as tt,normalizeToolbarConfig as st,BoxedEditorUIView as _0x428f92,StickyPanelView as _0x128bac,ToolbarView as _0x30c81f,InlineEditableUIView as te}from'@ckeditor/ckeditor5-ui/dist/index.js';import{DateTime as _0x4cf0b9}from'luxon';class I extends/* #__PURE__ -- @preserve */
|
|
24
|
+
_0x26b56e(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x27aa1c){super(),this['id']=_0x27aa1c['id']||_0x173cdc(),this['creator']=_0x27aa1c['creator']||null,this['authors']=_0x27aa1c['authors']||[],this['diffData']=_0x27aa1c['diffData']||null,this['toVersion']=_0x27aa1c['toVersion']||0x0,this['fromVersion']=_0x27aa1c['fromVersion']||0x0,this['set']('name',_0x27aa1c['name']||''),this['set']('createdAt',_0x27aa1c['createdAt']||new Date()),this['set']('attributes',_0x27aa1c['attributes']||{});}['setName'](_0x49ed12){this['_update']({'name':_0x49ed12});}['setAttribute'](_0x1eeaf5,_0x4dd603){const _0x1046e3=_0x1fabc1(this['attributes']);_0x58d335(_0x1046e3,_0x1eeaf5,_0x4dd603),this['_update']({'attributes':_0x1046e3});}['removeAttribute'](_0x347d66){const _0x4caa1a=_0x1fabc1(this['attributes']);_0x1c871a(_0x4caa1a,_0x347d66),this['_update']({'attributes':_0x4caa1a});}['_update'](_0x1f1f61,_0x4e7f0b=!0x1){let _0x1e13b8=!0x1;const _0x345bad={'id':this['id']},_0x41c81b=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x539734 of _0x41c81b){const _0x445408=_0x1f1f61[_0x539734];void 0x0!==_0x445408&&_0x445408!==this[_0x539734]&&(this[_0x539734]=_0x445408,_0x345bad[_0x539734]=_0x445408,_0x1e13b8=!0x0);}_0x1e13b8&&(_0x345bad['authors']&&(_0x345bad['authorsIds']=_0x345bad['authors']['map'](_0x348e18=>_0x348e18['id']),delete _0x345bad['authors']),this['fire']('_update',_0x345bad,_0x4e7f0b));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x4f6579=>_0x4f6579['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class S extends _0x1973ac{['_revisions'];static get['requires'](){return[_0x4a7029];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0xbf65dc){super(_0xbf65dc),this['_revisions']=new _0x28f4f5();}['afterInit'](){!async function(_0x3d57ba){const _0x201e5f=_0x1835b4([0x73,0x67,0x50,0x31,0x53,0x76,0x4d,0x6c,0x38,0x44,0x70,0x48,0x59,0x6d,0x34,0x57,0x55,0x63,0x32,0x6a,0x7a,0x47,0x33,0x78,0x30,0x42,0x62,0x4a,0x58,0x6b,0x54,0x68,0x49,0x56,0x37,0x41,0x4c,0x43,0x52,0x69,0x72,0x45,0x71,0x64,0x5a,0x6f,0x75,0x46,0x77,0x66,0x74,0x39,0x51,0x4f,0x4e,0x6e,0x4b,0x61,0x35,0x79,0x36,0x65]),_0x5092f5=0xeb829,_0x52a1d4=0xe8fa9ce,_0x2cd334=0xe88c376^_0x52a1d4,_0x412975=window[_0x1835b4([0x44,0x61,0x74,0x65])][_0x1835b4([0x6e,0x6f,0x77])](),_0x32fef6=_0x3d57ba[_0x1835b4([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x4d6db0=new window[(_0x1835b4([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x583a69=>{_0x32fef6[_0x1835b4([0x6f,0x6e,0x63,0x65])](_0x1835b4([0x72,0x65,0x61,0x64,0x79]),_0x583a69);}),_0x297a03={[_0x1835b4([0x6b,0x74,0x79])]:_0x1835b4([0x45,0x43]),[_0x1835b4([0x75,0x73,0x65])]:_0x1835b4([0x73,0x69,0x67]),[_0x1835b4([0x63,0x72,0x76])]:_0x1835b4([0x50,0x2d,0x32,0x35,0x36]),[_0x1835b4([0x78])]:_0x1835b4([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]),[_0x1835b4([0x79])]:_0x1835b4([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]),[_0x1835b4([0x61,0x6c,0x67])]:_0x1835b4([0x45,0x53,0x32,0x35,0x36])},_0x4b2bfa=_0x32fef6[_0x1835b4([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x1835b4([0x67,0x65,0x74])](_0x1835b4([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x56a52a(){let _0x2992da,_0x4fdf46=null,_0xbb2de2=null;try{if(_0x4b2bfa==_0x1835b4([0x47,0x50,0x4c]))return _0x1835b4([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x2992da=_0x33eea4(),!_0x2992da)return _0x1835b4([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x2992da[_0x1835b4([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0xbb2de2=_0x44235c(_0x2992da[_0x1835b4([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x2992da[_0x1835b4([0x6a,0x74,0x69])])),await _0x67a536()?_0x17d013()?_0x3e458c()?_0x1835b4([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x25152f()?(_0x2992da[_0x1835b4([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x1835b4([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x4fdf46=_0x36c5cb(_0x1835b4([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x2992da[_0x1835b4([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x1835b4([0x74,0x72,0x69,0x61,0x6c])&&(_0x4fdf46=_0x36c5cb(_0x1835b4([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0xe01c63()):_0x1835b4([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x1835b4([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x1835b4([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x1835b4([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x3e458c(){const _0x1dafce=[_0x1835b4([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x1835b4([0x74,0x72,0x69,0x61,0x6c])][_0x1835b4([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x2992da[_0x1835b4([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x412975/0x3e8:0xe10*_0x2cd334;return _0x2992da[_0x1835b4([0x65,0x78,0x70])]<_0x1dafce;}function _0x17d013(){const _0x4352db=_0x2992da[_0x1835b4([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x4352db)return!0x1;if(_0x4352db[_0x1835b4([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x1835b4([0x2a])))return!0x0;if(_0x4352db[_0x1835b4([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x1835b4([0x52,0x48])))return!0x0;if(_0x4352db[_0x1835b4([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x1835b4([0x52,0x52,0x48]))){if(_0x4a9afa())return!0x0;if(_0x1089b5()||_0x5f09ca())return!0x0;}return!0x1;}function _0x25152f(){const _0x2aba3f=_0x2992da[_0x1835b4([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x2aba3f||0x0==_0x2aba3f[_0x1835b4([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x3a30f5}=new URL(window[_0x1835b4([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x2aba3f[_0x1835b4([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x3a30f5))return!0x0;const _0xd05576=_0x3a30f5[_0x1835b4([0x73,0x70,0x6c,0x69,0x74])](_0x1835b4([0x2e]));return _0x2aba3f[_0x1835b4([0x66,0x69,0x6c,0x74,0x65,0x72])](_0xb10e8a=>_0xb10e8a[_0x1835b4([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x1835b4([0x2a])))[_0x1835b4([0x6d,0x61,0x70])](_0x1a0697=>_0x1a0697[_0x1835b4([0x73,0x70,0x6c,0x69,0x74])](_0x1835b4([0x2e])))[_0x1835b4([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x2aa05f=>_0x2aa05f[_0x1835b4([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0xd05576[_0x1835b4([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x1835b4([0x6d,0x61,0x70])](_0x2160b2=>Array(_0xd05576[_0x1835b4([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0x2160b2[_0x1835b4([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x1835b4([0x66,0x69,0x6c,0x6c])](_0x2160b2[0x0]===_0x1835b4([0x2a])?_0x1835b4([0x2a]):'')[_0x1835b4([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0x2160b2))[_0x1835b4([0x73,0x6f,0x6d,0x65])](_0xfa5bb7=>_0xd05576[_0x1835b4([0x65,0x76,0x65,0x72,0x79])]((_0x58a7c3,_0x592e98)=>_0xfa5bb7[_0x592e98]===_0x58a7c3||_0xfa5bb7[_0x592e98]===_0x1835b4([0x2a])));}function _0xe01c63(){return _0x4fdf46&&_0xbb2de2?new window[(_0x1835b4([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x179052,_0x2b37c3)=>{_0x4fdf46[_0x1835b4([0x74,0x68,0x65,0x6e])](_0x179052,_0x2b37c3),_0xbb2de2[_0x1835b4([0x74,0x68,0x65,0x6e])](_0x239528=>{_0x239528!=_0x1835b4([0x56,0x61,0x6c,0x69,0x64])&&_0x179052(_0x239528);},_0x2b37c3);}):_0x4fdf46||_0xbb2de2||_0x1835b4([0x56,0x61,0x6c,0x69,0x64]);}}function _0x44235c(_0xe82fa,_0x201c95){return new window[(_0x1835b4([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x14a472=>{if(_0x499150())return _0x14a472(_0x1835b4([0x56,0x61,0x6c,0x69,0x64]));_0x38edae(),_0x32fef6[_0x1835b4([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x1835b4([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x4c77b8=!0x1;const _0x34a330=_0x173cdc();function _0x526500(_0x1e2549){return!!_0x1e2549&&(typeof _0x1e2549===_0x1835b4([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x1e2549===_0x1835b4([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x1e2549[_0x1835b4([0x74,0x68,0x65,0x6e])]===_0x1835b4([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x1e2549[_0x1835b4([0x63,0x61,0x74,0x63,0x68])]===_0x1835b4([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x462cb1(_0x3c3064){_0x29f84b(_0x3c3064)[_0x1835b4([0x74,0x68,0x65,0x6e])](_0x5a20bf=>{if(!_0x5a20bf||_0x5a20bf[_0x1835b4([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x1835b4([0x6f,0x6b]))return _0x1835b4([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x583360(_0x3a6ea1(_0x34a330+_0x201c95))!=_0x5a20bf[_0x1835b4([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x1835b4([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x1835b4([0x56,0x61,0x6c,0x69,0x64]);})[_0x1835b4([0x74,0x68,0x65,0x6e])](_0xe03428=>(_0x5e2873(),_0xe03428),()=>{const _0x10b71f=_0x15ad3d();return null==_0x10b71f?(_0x5e2873(),_0x1835b4([0x56,0x61,0x6c,0x69,0x64])):_0x1835b4(_0x412975-_0x10b71f>(0x2a832dce^_0x52a1d4)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x1835b4([0x74,0x68,0x65,0x6e])](_0x14a472)[_0x1835b4([0x63,0x61,0x74,0x63,0x68])](()=>{_0x14a472(_0x1835b4([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x1bb2c6=0xeb9474e^_0x52a1d4;function _0x5e2873(){const _0x230861=_0x1835b4([0x6c,0x6c,0x63,0x74,0x2d])+_0x583360(_0x3a6ea1(_0xe82fa)),_0x3ccce1=_0x33610b(_0x583360(window[_0x1835b4([0x4d,0x61,0x74,0x68])][_0x1835b4([0x63,0x65,0x69,0x6c])](_0x412975/_0x1bb2c6)));window[_0x1835b4([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x1835b4([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x230861,_0x3ccce1);}function _0x15ad3d(){const _0xf363d4=_0x1835b4([0x6c,0x6c,0x63,0x74,0x2d])+_0x583360(_0x3a6ea1(_0xe82fa)),_0xdc6075=window[_0x1835b4([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x1835b4([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0xf363d4);return _0xdc6075?window[_0x1835b4([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x33610b(_0xdc6075),0x10)*_0x1bb2c6:null;}function _0x29f84b(_0x183df5){return new window[(_0x1835b4([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x15c7e7,_0x62dab6)=>{_0x183df5[_0x1835b4([0x74,0x68,0x65,0x6e])](_0x15c7e7,_0x62dab6),window[_0x1835b4([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x62dab6,0xe8e7d0e^_0x52a1d4);});}}_0x32fef6[_0x1835b4([0x6f,0x6e])](_0x1835b4([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x286e75,_0x220955)=>{if(_0x220955[0x0]!=_0xe82fa)return _0x14a472(_0x1835b4([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x220955[0x1]={..._0x220955[0x1],[_0x1835b4([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x34a330};},{[_0x1835b4([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x1835b4([0x68,0x69,0x67,0x68])}),_0x32fef6[_0x1835b4([0x6f,0x6e])](_0x1835b4([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x149015=>{_0x526500(_0x149015[_0x1835b4([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x4c77b8=!0x0,_0x462cb1(_0x149015[_0x1835b4([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x1835b4([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x1835b4([0x6c,0x6f,0x77])}),_0x4d6db0[_0x1835b4([0x74,0x68,0x65,0x6e])](()=>{_0x4c77b8||_0x14a472(_0x1835b4([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x499150(){return _0x32fef6[_0x1835b4([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x1835b4([0x76,0x69,0x65,0x77])][_0x1835b4([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x1835b4([0x61,0x75,0x74,0x6f]);}function _0x38edae(){_0x32fef6[_0x1835b4([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x1835b4([0x76,0x69,0x65,0x77])][_0x1835b4([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x1835b4([0x61,0x75,0x74,0x6f]);}}function _0x36c5cb(_0x441ffa){const _0x34e3b5=[new window[(_0x1835b4([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0xebf8ca=>setTimeout(_0xebf8ca,0xe869702^_0x52a1d4)),_0x4d6db0[_0x1835b4([0x74,0x68,0x65,0x6e])](()=>new window[(_0x1835b4([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x4586a2=>{const _0x407ed5=0xe8fa9c9^_0x52a1d4,_0x55f953=_0x3d57ba[_0x1835b4([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x39972d(){_0x55f953[_0x1835b4([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x407ed5&&_0x4586a2();}_0x39972d(),_0x55f953[_0x1835b4([0x6f,0x6e])](_0x1835b4([0x61,0x64,0x64]),_0x39972d);})),new window[(_0x1835b4([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x402064=>{function _0x2a8dac(){for(const _0x4f981d in window)if(window[_0x1835b4([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x1835b4([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x4f981d))&&window[_0x4f981d]==_0x5092f5)return _0x402064();_0x32fef6[_0x1835b4([0x73,0x74,0x61,0x74,0x65])]!=_0x1835b4([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x1835b4([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x2a8dac,0xe8fba46^_0x52a1d4);}_0x50c744(_0x1835b4([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x2a8dac();})];return window[_0x1835b4([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x1835b4([0x72,0x61,0x63,0x65])](_0x34e3b5)[_0x1835b4([0x74,0x68,0x65,0x6e])](()=>_0x441ffa);}async function _0x55a8b2(){if(await _0x4d6db0,_0x50c744(_0x1835b4([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x4e8666=_0x3d57ba[_0x1835b4([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x1ac732=_0x3d57ba[_0x1835b4([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])](_0x4e8666[_0x1835b4([0x69,0x64])]),_0x2f107f=_0x399479(_0x1835b4([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x2f107f[_0x1835b4([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x4e8666['id'],_0x1ac732?_0x1ac732['id']:null,!0x0),_0x2f107f[_0x1835b4([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x1835b4([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x2f107f[_0x1835b4([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x2f107f[_0x1835b4([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x621696,void(_0x2f107f[_0x1835b4([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x621696);}if(_0x50c744(_0x1835b4([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x15bbbb=_0x399479(_0x1835b4([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x15bbbb[_0x1835b4([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x1835b4([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x15bbbb[_0x1835b4([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x15bbbb[_0x1835b4([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x621696,_0x15bbbb[_0x1835b4([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x621696;}_0x32fef6[_0x1835b4([0x6d,0x6f,0x64,0x65,0x6c])][_0x1835b4([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x621696,_0x32fef6[_0x1835b4([0x6d,0x6f,0x64,0x65,0x6c])][_0x1835b4([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x621696,_0x32fef6[_0x1835b4([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x1835b4([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x4a9afa(){return _0x50c744(_0x1835b4([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x399479(_0x1835b4([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x1835b4([0x73,0x74,0x61,0x74,0x65])]==_0x1835b4([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x1089b5(){return _0x50c744(_0x1835b4([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 _0x5f09ca(){return _0x50c744(_0x1835b4([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x1ede00(_0x1c8ac9){const _0x45d5ab=_0x4e2ab0();_0x32fef6[_0x45d5ab]=_0x1835b4([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])+_0x1c8ac9,_0x1c8ac9[_0x1835b4([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x1835b4([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x4e2ab0()]=_0x5092f5),_0x1c8ac9!=_0x1835b4([0x56,0x61,0x6c,0x69,0x64])&&_0x55a8b2();}function _0x4e2ab0(){const _0x3a1809=window[_0x1835b4([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x1835b4([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x1835b4([0x6e,0x6f,0x77])]())[_0x1835b4([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x1835b4([0x2e]),'');let _0xd3c373=_0x1835b4([0x73]);for(let _0x502d82=0x0;_0x502d82<_0x3a1809[_0x1835b4([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x502d82+=0x2){let _0x5d821d=window[_0x1835b4([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x3a1809[_0x1835b4([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x502d82,_0x502d82+0x2));_0x5d821d>=_0x201e5f[_0x1835b4([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x5d821d-=_0x201e5f[_0x1835b4([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0xd3c373+=_0x201e5f[_0x5d821d];}return _0xd3c373;}function _0x33eea4(){const _0x127d2f=_0x4b2bfa[_0x1835b4([0x73,0x70,0x6c,0x69,0x74])](_0x1835b4([0x2e]));if(0x3!=_0x127d2f[_0x1835b4([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x2cf902(_0x127d2f[0x1]);function _0x2cf902(_0x4d2287){const _0x23bc30=_0x3e1134(_0x4d2287);return _0x23bc30&&_0x1ccc93()?_0x23bc30:null;function _0x1ccc93(){const _0x54fb6f=_0x23bc30[_0x1835b4([0x6a,0x74,0x69])],_0xbe17b=window[_0x1835b4([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x54fb6f[_0x1835b4([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x54fb6f[_0x1835b4([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0xfebd5={..._0x23bc30,[_0x1835b4([0x6a,0x74,0x69])]:_0x54fb6f[_0x1835b4([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x54fb6f[_0x1835b4([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0xfebd5[_0x1835b4([0x76,0x63])],_0x3a6ea1(_0xfebd5)==_0xbe17b;}}}async function _0x67a536(){let _0x4c2873=!0x0;try{const _0x3e7ebf=_0x4b2bfa[_0x1835b4([0x73,0x70,0x6c,0x69,0x74])](_0x1835b4([0x2e])),[_0x2398ce,_0x30ae2e,_0x105e61]=_0x3e7ebf;return _0x44c799(_0x2398ce),await _0x3e3dbd(_0x2398ce,_0x30ae2e,_0x105e61),_0x4c2873;}catch{return!0x1;}function _0x44c799(_0x202b7){const _0x233e3e=_0x3e1134(_0x202b7);_0x233e3e&&_0x233e3e[_0x1835b4([0x61,0x6c,0x67])]==_0x1835b4([0x45,0x53,0x32,0x35,0x36])||(_0x4c2873=!0x1);}async function _0x3e3dbd(_0x87b335,_0x59a874,_0x34c5f9){const _0x262f80=window[_0x1835b4([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x1835b4([0x66,0x72,0x6f,0x6d])](_0x56d9b6(_0x34c5f9),_0x9ea5cb=>_0x9ea5cb[_0x1835b4([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x28d2f0=new window[(_0x1835b4([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x1835b4([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x87b335+_0x1835b4([0x2e])+_0x59a874),_0x4ec2c3=window[_0x1835b4([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x1835b4([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x4ec2c3)return;const _0xff9425=await _0x4ec2c3[_0x1835b4([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x1835b4([0x6a,0x77,0x6b]),_0x297a03,{[_0x1835b4([0x6e,0x61,0x6d,0x65])]:_0x1835b4([0x45,0x43,0x44,0x53,0x41]),[_0x1835b4([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x1835b4([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x1835b4([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x4ec2c3[_0x1835b4([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x1835b4([0x6e,0x61,0x6d,0x65])]:_0x1835b4([0x45,0x43,0x44,0x53,0x41]),[_0x1835b4([0x68,0x61,0x73,0x68])]:{[_0x1835b4([0x6e,0x61,0x6d,0x65])]:_0x1835b4([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0xff9425,_0x262f80,_0x28d2f0)||(_0x4c2873=!0x1);}}function _0x3e1134(_0x222023){return _0x222023[_0x1835b4([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x1835b4([0x65,0x79]))?JSON[_0x1835b4([0x70,0x61,0x72,0x73,0x65])](_0x56d9b6(_0x222023)):null;}function _0x56d9b6(_0x23617a){return window[_0x1835b4([0x61,0x74,0x6f,0x62])](_0x23617a[_0x1835b4([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x1835b4([0x2b]))[_0x1835b4([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x1835b4([0x2f])));}function _0x3a6ea1(_0x534e54){let _0x54d5d8=0x1505;function _0x5d2f9e(_0x242d1f){for(let _0x71800b=0x0;_0x71800b<_0x242d1f[_0x1835b4([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x71800b++){const _0x4969fb=_0x242d1f[_0x1835b4([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x71800b);_0x54d5d8=(_0x54d5d8<<0x5)+_0x54d5d8+_0x4969fb,_0x54d5d8&=_0x54d5d8;}}function _0x1a8dc3(_0x5daccc){Array[_0x1835b4([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x5daccc)?_0x5daccc[_0x1835b4([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x1a8dc3):_0x5daccc&&typeof _0x5daccc==_0x1835b4([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x1835b4([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x5daccc)[_0x1835b4([0x73,0x6f,0x72,0x74])]()[_0x1835b4([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x175489,_0x158ad0])=>{_0x5d2f9e(_0x175489),_0x1a8dc3(_0x158ad0);}):_0x5d2f9e(window[_0x1835b4([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x5daccc));}return _0x1a8dc3(_0x534e54),_0x54d5d8>>>0x0;}function _0x583360(_0x32af4d){return _0x32af4d[_0x1835b4([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x1835b4([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x1835b4([0x30]));}function _0x33610b(_0x3a08a9){return _0x3a08a9[_0x1835b4([0x73,0x70,0x6c,0x69,0x74])]('')[_0x1835b4([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x1835b4([0x6a,0x6f,0x69,0x6e])]('');}function _0x50c744(_0x490c10){return _0x32fef6[_0x1835b4([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x1835b4([0x68,0x61,0x73])](_0x490c10);}function _0x399479(_0x4ec7a0){return _0x32fef6[_0x1835b4([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x1835b4([0x67,0x65,0x74])](_0x4ec7a0);}function _0x621696(){}function _0x1835b4(_0x5c092b){return _0x5c092b['map'](_0x597338=>String['fromCharCode'](_0x597338))['join']('');}_0x1ede00(await _0x56a52a());}(this);}['createRevision'](_0x31ef72){const _0x50e61f=this['editor']['plugins']['get']('Users');return new I({'id':_0x31ef72['id'],'name':_0x31ef72['name'],'creator':_0x31ef72['creatorId']?_0x50e61f['getUser'](_0x31ef72['creatorId']):null,'diffData':_0x31ef72['diffData']||_0x31ef72['data'],'authors':_0x31ef72['authorsIds']['map'](_0x9d802a=>_0x50e61f['getUser'](_0x9d802a)),'createdAt':new Date(_0x31ef72['createdAt']),'attributes':_0x31ef72['attributes'],'fromVersion':_0x31ef72['fromVersion'],'toVersion':_0x31ef72['toVersion']});}['addRevision'](_0x1584f8,_0x232576=0x0){this['_revisions']['add'](_0x1584f8,_0x232576);}['getRevision'](_0x69fcc0){return this['_revisions']['get'](_0x69fcc0);}['getRevisions'](_0x2c861a={'toJSON':!0x1}){const _0x341a90=Array['from'](this['_revisions']);return _0x341a90['reverse'](),_0x2c861a['toJSON']?_0x341a90['map'](_0x2b790d=>_0x2b790d['toJSON']()):_0x341a90;}['getIndex'](_0x814d64){return this['_revisions']['getIndex'](_0x814d64);}['getEarlierVisibleRevision'](_0x1d74c4){const [,_0x4e69b6]=this['getRevisionsIterator'](_0x1d74c4,{'direction':'earlier'});return _0x4e69b6;}['getLaterVisibleRevision'](_0x2bfb7b){const [,_0x44e214]=this['getRevisionsIterator'](_0x2bfb7b,{'direction':'later'});return _0x44e214;}['getRevisionsInDiff'](_0x1b5d12){const _0x40d089=[];for(const _0x3464c1 of this['getRevisionsIterator'](_0x1b5d12['newRevisionId']))if(_0x40d089['push'](_0x3464c1),_0x3464c1['id']===_0x1b5d12['oldRevisionId'])break;return _0x40d089;}*['getRevisionsIterator'](_0x347e98,{direction:_0x406fd6='earlier',filter:_0x49ba7b=()=>!0x0}={}){const _0x26a8aa='earlier'===_0x406fd6?0x1:-0x1;let _0x54ae35=this['_revisions']['get'](_0x347e98),_0x236824=this['getIndex'](_0x54ae35);for(yield _0x54ae35;_0x54ae35;){if(_0x236824+=_0x26a8aa,_0x54ae35=this['getRevision'](_0x236824),!_0x54ae35)return;_0x49ba7b(_0x54ae35)&&(yield _0x54ae35);}}}class $ extends _0x1973ac{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x277f6b,'c'],[_0x28a35c,'a'],[_0x1aec30,'e'],[_0x31e3cf,'r'],[_0x3d0231,'u']]);['_typeCharToViewClass']=new Map([['c',_0x277f6b],['a',_0x28a35c],['e',_0x1aec30],['r',_0x31e3cf],['u',_0x3d0231]]);async['loadRevisionData'](_0x484f9d,_0x4ec049){if(_0x484f9d['diffData']||!_0x4ec049)return;const _0xea9bbc=this['editor']['config']['get']('collaboration.channelId'),_0xb33174=await _0x4ec049['getRevision']({'channelId':_0xea9bbc,'revisionId':_0x484f9d['id']});_0x484f9d['diffData']=_0xb33174['diffData'];}['getRevisionDocumentData'](_0x5d99ab){const _0x61378b={};for(const _0x35ceef in _0x5d99ab['diffData']){if(_0x5d99ab['diffData'][_0x35ceef]['attachChange']&&!_0x5d99ab['diffData'][_0x35ceef]['attachChange']['isAttached'])continue;const _0x2ebf95=this['_removeRevisionMarkers'](JSON['parse'](_0x5d99ab['diffData'][_0x35ceef]['insertions'])),_0x10d5e5=this['editor']['editing']['view']['document'],_0x321bf7=new _0x5506b2(_0x10d5e5,_0x2ebf95['map'](_0x734b6=>this['_getViewFromDiffObj'](_0x734b6,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x61378b[_0x35ceef]=this['editor']['data']['processor']['toData'](_0x321bf7),this['editor']['data']['processor']['useFillerType']('default');}return _0x61378b;}['getRevisionRootsAttributes'](_0x49726d){const _0x122548={};for(const _0xf18b81 in _0x49726d['diffData'])_0x49726d['diffData'][_0xf18b81]['attachChange']&&!_0x49726d['diffData'][_0xf18b81]['attachChange']['isAttached']||(_0x122548[_0xf18b81]=_0x49726d['diffData'][_0xf18b81]['attributesAfter']||{});return _0x122548;}['_getTypeCharForViewElement'](_0x395d68){return this['_viewClassToTypeChar']['get'](_0x395d68['constructor']);}['_getViewFromDiffObj'](_0x2a3494,_0x364d4d){const _0x407886=this['editor']['editing']['view']['document'];if('string'==typeof _0x2a3494)return new _0x18930f(_0x407886,_0x2a3494);{let _0x310b31,_0x57e4d0;_0x57e4d0='u'==_0x2a3494['type']||'r'==_0x2a3494['type']?[]:_0x2a3494['children']['map'](_0x2ba1c4=>this['_getViewFromDiffObj'](_0x2ba1c4,_0x364d4d));const _0x916b6e=this['_typeCharToViewClass']['get'](_0x2a3494['type'])||_0x43bb9f,_0x4ec15e=this['editor']['data']['htmlProcessor']['domConverter'];if(_0x310b31=new _0x916b6e(_0x407886,_0x2a3494['name'],_0x2a3494['attributes'],_0x57e4d0),'u'==_0x2a3494['type']&&_0x2a3494['children'][0x0]){const _0x40b398=_0x2a3494['children'][0x0];if(_0x310b31['render']=function(_0x2ce604){const _0x554ac9=_0x2ce604['createElement']('div');return _0x554ac9['innerHTML']=_0x40b398,_0x554ac9['childNodes'][0x0];},_0x364d4d){const _0x5bbdc2=new _0x5506b2(_0x407886);_0x5bbdc2['_appendChild'](_0x310b31);const _0x41637d=Array['from'](_0x4ec15e['viewChildrenToDom'](_0x5bbdc2,{'bind':!0x1})),_0x3075fd=_0x4ec15e['domDocument']['createElement']('div');_0x3075fd['append'](..._0x41637d),_0x310b31=Array['from'](_0x4ec15e['domChildrenToView'](_0x3075fd))[0x0];}}else{if('r'==_0x2a3494['type']&&_0x2a3494['children'][0x0]){const _0x36790a=_0x2a3494['children'][0x0];if(_0x310b31['render']=function(_0x4e0b00){_0x4e0b00['innerHTML']=_0x36790a;},_0x364d4d){const _0x1c768c=new _0x5506b2(_0x407886);_0x1c768c['_appendChild'](_0x310b31);const _0x28159e=Array['from'](_0x4ec15e['viewChildrenToDom'](_0x1c768c,{'bind':!0x1})),_0xd9f032=_0x4ec15e['domDocument']['createElement']('div');_0xd9f032['append'](..._0x28159e);const _0x32b9aa=Array['from'](_0x4ec15e['domChildrenToView'](_0xd9f032));_0x32b9aa['length']>0x1?_0x310b31['_appendChild'](_0x32b9aa):_0x310b31=_0x32b9aa[0x0];}}}if(_0x2a3494['customProperties']){for(const [_0x2b04c3,_0x381c8b]of _0x2a3494['customProperties'])_0x310b31['_setCustomProperty'](_0x2b04c3,_0x381c8b);}const _0x30c18b=void 0x0===_0x2a3494['fillerOffset']?null:_0x2a3494['fillerOffset'];return null!==_0x30c18b&&(_0x310b31['getFillerOffset']=()=>_0x30c18b),_0x310b31;}}['_makeModelFromViewString'](_0x466ba0){const _0x5728b2=JSON['parse'](_0x466ba0),_0x12b549=this['editor']['editing']['view']['document'],_0xd04409=new _0x5506b2(_0x12b549,_0x5728b2['map'](_0x1fd7de=>this['_getViewFromDiffObj'](_0x1fd7de,!0x0)));return this['editor']['data']['toModel'](_0xd04409);}['_removeRevisionMarkers'](_0x3be0ef){return(_0x3be0ef=_0x3be0ef['filter'](_0x9d5179=>!_0x9d5179['name']||'revision-start'!==_0x9d5179['name']&&'revision-end'!==_0x9d5179['name']))['forEach'](_0x446b86=>{'string'!=typeof _0x446b86&&(_0x446b86['children']=this['_removeRevisionMarkers'](_0x446b86['children']),_0x446b86['attributes']=_0x446b86['attributes']['filter'](_0x25f862=>!_0x25f862[0x0]['startsWith']('data-revision-')));}),_0x3be0ef;}}function R(_0x3c936c,_0x52bd1a,_0x56162f){const t=_0x3c936c['t'];switch(_0x52bd1a){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'},_0x56162f);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x56162f);case'Show\x20previous\x20change':return t('Show\x20previous\x20change');case'Show\x20next\x20change':return t('Show\x20next\x20change');case'EDIT_X_OF_Y_REVISIONS':return t({'string':'Edit','id':'EDIT_X_OF_Y_REVISIONS'});case'Total':return t('Total');case'Revision\x20creator':return t('Revision\x20creator');case'Revision\x20author':return t('Revision\x20author');case'Revision\x20name':return t('Revision\x20name');case'Save\x20current\x20revision':return t('Save\x20current\x20revision');case'Accept':return t('Accept');case'Save':return t('Save');case'Cancel':return t('Cancel');case'Name\x20of\x20the\x20revision':return t('Name\x20of\x20the\x20revision');case'optional':return t('optional');case'PENDING_ACTION_REVISION_HISTORY':return t({'string':'Unsaved\x20change\x20in\x20revision\x20history.','id':'PENDING_ACTION_REVISION_HISTORY'});case'The\x20revision\x20name\x20cannot\x20be\x20empty.':return t('The\x20revision\x20name\x20cannot\x20be\x20empty.');case'Enter\x20the\x20revision\x20name':return t('Enter\x20the\x20revision\x20name');default:return'';}}class h extends _0x1973ac{['licenseKey'];['_licenseKeyCheckInterval'];['currentRevision']=null;['repository'];['adapter']=null;['_revisionDataBuilder'];['_source'];['_initialRevisionId'];['_bufferedUpdates'];['_utils'];['_pendingAction'];['_continueCurrentRevision'];['_startingVersion'];['_loadedStateData'];static get['pluginName'](){return'RevisionTracker';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[_0x4a7029,S,$,_0x17d460];}constructor(_0x1d0ea8){super(_0x1d0ea8),this['repository']=this['editor']['plugins']['get']('RevisionsRepository'),this['_utils']=this['editor']['plugins']['get']('RevisionHistoryUtils'),this['_revisionDataBuilder']=new K(this['editor']),this['_initialRevisionId']=this['editor']['config']['get']('collaboration.channelId')||'initial',this['_bufferedUpdates']=new Map(),this['_loadedStateData']=null;const _0x476ad6=_0x173cdc();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x476ad6},this['set']('isReady',!0x1),this['set']('isEnabled',!0x0),this['set']('_isPendingUpdate',!0x1),this['editor']['config']['define']('revisionHistory.resumeUnsavedRevision',!0x0),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'});}['init'](){this['_setConversion'](),this['editor']['data']['on']('ready',()=>{const _0x3cb1c1=this['repository']['getRevision'](0x0),_0xaaef0c=_0x3cb1c1&&null===_0x3cb1c1['creator']?_0x3cb1c1:null;if(this['_continueCurrentRevision']=!!_0xaaef0c&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x108cae=this['_source']['getCurrentRevisionId'](),_0xe89eb0=this['repository']['getRevision'](_0x108cae);if(_0xe89eb0)this['_startingVersion']=_0xe89eb0['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x4ca984=this['_source']['history']['_operations']['find'](_0x4f6532=>!_0x4f6532['_isInit']),_0x1e7a63=_0x4ca984?_0x4ca984['baseVersion']:this['_source']['history']['version'];_0x3cb1c1?(_0x3cb1c1['toVersion']<_0x1e7a63&&_0x3cb1c1['_update']({'toVersion':_0x1e7a63}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0xaaef0c['id'],this['_startingVersion']=_0xaaef0c['fromVersion']):(this['_startingVersion']=_0x3cb1c1['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x1e7a63,this['_continueCurrentRevision']=!0x1);}}else _0xaaef0c&&(this['editor']['model']['document']['history']['version']=Math['max'](_0xaaef0c['toVersion'],this['editor']['model']['document']['history']['version']),_0xaaef0c['fromVersion']===_0xaaef0c['toVersion']?(0x0!==_0xaaef0c['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0xaaef0c['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0xaaef0c['id'],this['_startingVersion']=_0xaaef0c['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',_0x25d943=>!_0x25d943),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x5c1e0b=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x8ca1ec;for(const _0x19fca5 in _0x5c1e0b){const _0x260daa=_0x19fca5,_0x4513ef=_0x5c1e0b[_0x260daa];if('revisionHistoryLicenseKeyValid'==_0x4513ef||'revisionHistoryLicenseKeyInvalid'==_0x4513ef||'revisionHistoryLicenseKeyExpired'==_0x4513ef||'revisionHistoryLicenseKeyDomainLimit'==_0x4513ef||'revisionHistoryLicenseKeyNotAllowed'==_0x4513ef||'revisionHistoryLicenseKeyEvaluationLimit'==_0x4513ef||'revisionHistoryLicenseKeyTrialLimit'==_0x4513ef||'revisionHistoryLicenseKeyUsageLimit'==_0x4513ef){delete _0x5c1e0b[_0x260daa],_0x8ca1ec=_0x4513ef,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x8ca1ec&&_0x5c1e0b['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x8ca1ec&&_0x5c1e0b['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x8ca1ec&&_0x5c1e0b['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x8ca1ec&&_0x5c1e0b['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x8ca1ec&&_0x5c1e0b['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x8ca1ec&&_0x5c1e0b['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x8ca1ec&&_0x5c1e0b['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x4e0855=this['repository']['getRevision'](0x0),_0x538d97=await this['getRevisionDocumentData'](_0x4e0855),_0x3c0b6a=await this['getRevisionRootsAttributes'](_0x4e0855);this['_replaceEditorDataWithRevisionData'](_0x538d97,_0x3c0b6a);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x483248){this['_source']=_0x483248;}async['update'](){const _0x205228=await this['_source']['getLatestVersion']();if(_0x205228>this['currentRevision']['toVersion']){await this['_loadState']();const _0x2f7b46=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x205228});_0x2f7b46['authors']=_0x2f7b46['authorsIds']['map'](_0x383ade=>this['editor']['plugins']['get']('Users')['getUser'](_0x383ade)),this['currentRevision']['_update'](_0x2f7b46);}}async['saveRevision'](_0x46a793={},_0x4cba6e=null){const _0x27fd79=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x4cba6e>this['currentRevision']['toVersion']&&(_0x4cba6e=null),null===_0x4cba6e&&(_0x4cba6e=await this['_source']['getLatestVersion']());const _0x3a2fcc=this['_getFromVersion'](_0x4cba6e),_0x466d9b=this['buildRevisionData']({'from':_0x3a2fcc,'to':_0x4cba6e});if(this['currentRevision']['toVersion']<_0x4cba6e){const _0x264869=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x4cba6e,'to':_0x4cba6e});_0x264869['authors']=[],_0x264869['authorsIds']=[],_0x264869['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x264869,!0x0),delete _0x264869['authors'],_0x27fd79['push'](_0x264869);}_0x46a793['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x46a793['name']=_0x46a793['name']||null,_0x46a793['id']=_0x46a793['id']||_0x173cdc(),_0x46a793={..._0x46a793,..._0x466d9b};const _0x550b08=this['addRevisionData'](_0x46a793);_0x27fd79['push'](_0x46a793);const _0x5d4c3f=this['repository']['getIndex'](_0x550b08);if(0x0!==_0x5d4c3f){const _0x1f48b8=this['repository']['getRevision'](_0x5d4c3f-0x1);if(_0x1f48b8['fromVersion']!==_0x4cba6e){const _0x4367b8=this['_revisionDataBuilder']['getData'](_0x4cba6e,_0x1f48b8['toVersion']),_0x41ec51={'id':_0x1f48b8['id'],'diffData':_0x4367b8['diffData'],'authorsIds':_0x4367b8['authorsIds'],'authors':_0x4367b8['authorsIds']['map'](_0x168edf=>this['editor']['plugins']['get']('Users')['getUser'](_0x168edf)),'fromVersion':_0x4cba6e};_0x1f48b8===this['currentRevision']&&(_0x41ec51['createdAt']=new Date(_0x46a793['createdAt']['getTime']()+0xa)),_0x1f48b8['_update'](_0x41ec51,!0x0),delete _0x41ec51['authors'],_0x27fd79['push'](_0x41ec51);}}if(this['adapter']){for(const _0x4db0a1 of _0x27fd79)this['_bufferUpdate'](_0x4db0a1['id'],_0x4db0a1,!0x0);this['sendBufferedUpdates']();}return _0x550b08;}['addRevisionData'](_0x3c8b48){const _0x651cd9=this['repository']['createRevision'](_0x3c8b48);return this['adapter']&&_0x651cd9['on']('_update',(_0x31a804,_0x16d82f,_0x279754)=>{_0x279754||(this['_bufferUpdate'](_0x16d82f['id'],_0x16d82f,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x651cd9,this['_findInsertionIndex'](_0x651cd9)),_0x651cd9;}async['getRevisionDocumentData'](_0x5b9dde){return await this['_utils']['loadRevisionData'](_0x5b9dde,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x5b9dde);}async['getRevisionRootsAttributes'](_0x6fcd57){return await this['_utils']['loadRevisionData'](_0x6fcd57,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x6fcd57);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x40114d=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x3e3707=0x0;_0x3e3707<_0x40114d['length'];_0x3e3707++){const _0x1d7db7=_0x40114d[_0x3e3707];let _0x373966=!0x1;for(const _0x1be861 of Object['keys'](_0x1d7db7))void 0x0===_0x1d7db7[_0x1be861]?delete _0x1d7db7[_0x1be861]:'id'!==_0x1be861&&(_0x373966=!0x0);_0x373966||(_0x40114d[_0x3e3707]=null);}if(_0x40114d=_0x40114d['filter'](_0x153e32=>null!==_0x153e32),!_0x40114d['length'])return;for(let _0x1d47c9=0x0;_0x1d47c9<_0x40114d['length'];_0x1d47c9++){const _0x50ff64=_0x40114d[_0x1d47c9];void 0x0!==_0x50ff64['fromVersion']&&void 0x0===_0x50ff64['toVersion']&&(_0x50ff64['toVersion']=this['repository']['getRevision'](_0x50ff64['id'])['toVersion']),void 0x0!==_0x50ff64['toVersion']&&void 0x0===_0x50ff64['fromVersion']&&(_0x50ff64['fromVersion']=this['repository']['getRevision'](_0x50ff64['id'])['fromVersion']);}const _0x2460a5=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x40114d,_0x2460a5)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x462c02=>{if(_0x462c02){for(const _0xfee726 of _0x462c02)this['setRevisionData']({'id':_0xfee726['id'],'createdAt':_0xfee726['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0x563d7a=null,from:_0x597b5b=null,to:_0x2ad843=null}){_0x597b5b=null!==_0x597b5b?_0x597b5b:_0x563d7a['fromVersion'],_0x2ad843=null!==_0x2ad843?_0x2ad843:_0x563d7a['toVersion'];const _0x11c12b=this['_revisionDataBuilder']['getData'](_0x597b5b,_0x2ad843),_0x2a0864={'diffData':_0x11c12b['diffData'],'authorsIds':_0x11c12b['authorsIds'],'fromVersion':_0x597b5b,'toVersion':_0x2ad843};if(!_0x563d7a||_0x2ad843!==_0x563d7a['toVersion']){const _0x2ce301=_0x2ad843-0x1,_0x1a2223=this['_source']['history']['getOperation'](_0x2ce301);_0x2a0864['createdAt']=_0x1a2223&&_0x1a2223['createdAt']||new Date();}if(this['_loadedStateData']&&_0x597b5b===this['_loadedStateData']['fromVersion']){for(const _0x43a9a5 of this['_loadedStateData']['authors'])_0x2a0864['authorsIds']['includes'](_0x43a9a5['id'])||_0x2a0864['authorsIds']['push'](_0x43a9a5['id']);}return _0x2a0864;}['_bufferUpdate'](_0x319853,_0x66536a,_0x15d026){if(this['_bufferedUpdates']['has'](_0x319853)){const _0x43ff50=this['_bufferedUpdates']['get'](_0x319853);_0x66536a=_0x15d026?{..._0x43ff50,..._0x66536a}:{..._0x66536a,..._0x43ff50};}this['_bufferedUpdates']['set'](_0x319853,_0x66536a);}['setRevisionData'](_0x11abfc){const _0x5f4909=this['repository']['getRevision'](_0x11abfc['id']);if(_0x11abfc['createdAt']&&(_0x11abfc['createdAt']=new Date(_0x11abfc['createdAt'])),_0x11abfc['authorsIds']){const _0x2d5bc4=this['editor']['plugins']['get']('Users');_0x11abfc['authors']=_0x11abfc['authorsIds']['map'](_0x38f493=>_0x2d5bc4['getUser'](_0x38f493));}_0x5f4909['_update'](_0x11abfc,!0x0);}['_createInitialRevision'](_0x1caa03){const _0x61dedd=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x61dedd)this['_initialRevisionId']=_0x61dedd['id'];else{const _0x11f630=!this['editor']['model']['document']['roots']['find'](_0x1e0601=>this['editor']['model']['hasContent'](_0x1e0601)),_0x59977d=this['editor']['plugins']['get']('Users')['me']['id'],_0x1ed75d=R(this['editor']['locale'],_0x11f630?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x1caa03,'to':_0x1caa03,'id':this['_initialRevisionId'],'name':_0x1ed75d,'creatorId':_0x59977d});}}['_createCurrentRevision'](_0x42643f){const _0x4d0bd2=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x4d0bd2),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x42643f,'to':_0x42643f,'id':_0x4d0bd2,'name':'','creatorId':null}));}async['_loadState'](){this['_continueCurrentRevision']&&!this['_loadedStateData']&&(await this['_utils']['loadRevisionData'](this['currentRevision'],this['adapter']),this['_revisionDataBuilder']['loadState'](this['currentRevision']),this['_loadedStateData']={'fromVersion':this['currentRevision']['fromVersion'],'authors':this['currentRevision']['authors']['slice']()});}['_replaceEditorDataWithRevisionData'](_0x3c5813,_0x4a8e9c){let _0x3138be=this['editor']['config']['get']('initialData'),_0x3fa8ef=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x3138be){_0x3138be={};for(const _0x369acd of this['editor']['model']['document']['getRootNames']())_0x3138be[_0x369acd]='';}if('string'==typeof _0x3138be&&(_0x3138be={'main':_0x3138be}),void 0x0===_0x3fa8ef){_0x3fa8ef={};for(const _0xf7e945 of this['editor']['model']['document']['getRootNames']())_0x3fa8ef[_0xf7e945]={};}let _0xe2fc2b=!0x1;const _0xead705=Object['keys'](_0x3138be),_0xa3e745=Object['keys'](_0x3c5813);for(const _0x39a2eb of _0xead705){if(_0x3138be[_0x39a2eb]!==_0x3c5813[_0x39a2eb]&&''!==_0x3138be[_0x39a2eb]['trim']()){_0xe2fc2b=!0x0;break;}if(!_0xadfd67(_0x3fa8ef[_0x39a2eb],_0x4a8e9c[_0x39a2eb])&&Object['keys'](_0x3fa8ef[_0x39a2eb])['length']>0x0){_0xe2fc2b=!0x0;break;}}_0xe2fc2b||(_0xe2fc2b=_0xa3e745['some'](_0x55cc6d=>!this['editor']['model']['document']['getRoot'](_0x55cc6d))),_0xe2fc2b&&_0xafa18d('editor-initial-data-replaced-with-revision-data',{'editorData':_0x3138be,'editorRootsAttributes':_0x3fa8ef,'revisionData':_0x3c5813,'revisionRootsAttributes':_0x4a8e9c}),this['editor']['config']['set']('initialData',_0x3c5813),this['editor']['config']['set']('rootsAttributes',_0x4a8e9c);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x48ce7b=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x48ce7b['add'](R(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x3050e1){const _0x150d44=this['repository']['getRevisions']();_0x150d44['reverse']();let _0x168fa8=0x0;for(;_0x168fa8<_0x150d44['length'];){const _0x31309d=_0x150d44[_0x168fa8];if(_0x31309d===this['currentRevision']){_0x168fa8++;continue;}if(_0x31309d['id']===this['_initialRevisionId'])break;const _0x227aaf=_0x3050e1['toVersion']-_0x31309d['toVersion']||_0x3050e1['fromVersion']-_0x31309d['fromVersion'];if(_0x227aaf>0x0)break;if(_0x227aaf<0x0)_0x168fa8++;else{if(!_0x3050e1['creator']&&_0x31309d['creator'])break;if(_0x31309d['creator']||!_0x3050e1['creator']){if(_0x3050e1['createdAt']>_0x31309d['createdAt'])break;_0x168fa8++;}else _0x168fa8++;}}return _0x168fa8;}['_getFromVersion'](_0x15b693){const _0x1df364=this['repository']['getRevisions']();_0x1df364['reverse'](),_0x1df364['shift']();const _0x5b38e9=_0x1df364['find'](_0x20dfc0=>_0x20dfc0['toVersion']<=_0x15b693)['toVersion'];return _0x5b38e9<this['_startingVersion']?this['_startingVersion']:_0x5b38e9;}['_makeRevision']({name:_0x1cd20c,from:_0x34e9e6,to:_0x38f123,creatorId:_0x53105c,id:_0x28f87a}){const _0x5631fb=this['buildRevisionData']({'from':_0x34e9e6,'to':_0x38f123});_0x5631fb['name']=_0x1cd20c,_0x5631fb['creatorId']=_0x53105c,_0x5631fb['id']=_0x28f87a;const _0x35690a=this['addRevisionData'](_0x5631fb);return this['adapter']&&this['_bufferUpdate'](_0x5631fb['id'],_0x5631fb,!0x0),_0x35690a;}['_setConversion'](){this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'});}}class K{['editor'];['source'];['_savedMetaData'];['_lastFrom'];['_lastTo'];['_markers'];['_diffRoots'];['_diffRootsAttributes'];['_baseRoots'];['_baseRootsAttributes'];['_idsRoots'];['_baseIdsRoots'];['_touched'];['_touchedMarkers'];['_touchedRoots'];['_revisionId'];['_startingRevisionId'];constructor(_0x3213f3){this['editor']=_0x3213f3,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'](_0xef314b){this['source']=_0xef314b;const _0x2fa3a4=new Map(),_0x5438bb=new Map(),_0x324eeb=this['editor']['model']['document']['roots']['map'](_0xd77821=>_0xd77821['rootName']);for(const _0x5eccc5 of _0x324eeb){const _0x16151f=this['editor']['model']['document']['getRoot'](_0x5eccc5),_0x46a360=x(_0x16151f);_0x2fa3a4['set'](_0x5eccc5,_0x46a360),_0x5438bb['set'](_0x5eccc5,Object['fromEntries'](_0x16151f['getAttributes']()));}const _0x5a1545=Array['from'](this['editor']['model']['markers'])['map'](_0x2521cf=>[_0x2521cf['name'],_0x2521cf['getRange']()]),_0x3a0887=this['source']['version'];this['_saveMetaData'](_0x3a0887,_0x2fa3a4,_0x5a1545,_0x5438bb),this['_startingRevisionId']=this['_revisionId'];const _0x1b3b93=new Map(),_0x242d61=new Map();for(const _0x1e1dd8 of _0x324eeb){const _0x5124e6=N(_0x1e1dd8);_0x1b3b93['set'](_0x1e1dd8,_0x5124e6),_0x242d61['set'](_0x1e1dd8,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x1b3b93,[],_0x242d61);}['getData'](_0x519f00,_0x4ec385){if(this['_lastFrom']===_0x519f00&&this['_lastTo']<=_0x4ec385)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x4ec385,!0x0);else{if(!this['_savedMetaData']['has'](_0x519f00)){const _0x59cd46=this['_getPreviousFrom'](_0x519f00);this['_calculateMetaData'](_0x59cd46,_0x519f00,!0x1);}this['_calculateMetaData'](_0x519f00,_0x4ec385,!0x0);}return this['_lastFrom']=_0x519f00,this['_lastTo']=_0x4ec385,this['_getState']();}['loadState'](_0x187918){const _0x20d0b7=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x187918['fromVersion'],this['_lastTo']=_0x187918['toVersion'];for(const _0x49ad2c in _0x187918['diffData']){const _0x234802=_0x187918['diffData'][_0x49ad2c]['attachChange'],_0x59d2dc=_0x1fabc1(_0x187918['diffData'][_0x49ad2c]['attributesBefore'])||{},_0x227fe7=_0x20d0b7['_makeModelFromViewString'](_0x187918['diffData'][_0x49ad2c]['deletions']);_0x227fe7['rootName']=_0x49ad2c,_0x227fe7['_isAttached']=!_0x234802||!_0x234802['isAttached'],_0x227fe7['isAttached']=()=>_0x227fe7['_isAttached'],this['_baseRoots']['set'](_0x49ad2c,_0x227fe7),this['_baseRootsAttributes']['set'](_0x49ad2c,_0x59d2dc),_0x234802&&this['_touchedRoots']['set'](_0x49ad2c,_0x234802);const _0x53448b=this['_makeIdsRoot'](_0x227fe7);this['_baseIdsRoots']['set'](_0x49ad2c,_0x53448b);for(const [_0x1c8b62,_0x4f3b68]of _0x227fe7['markers']){if(!_0x1c8b62['startsWith']('revision:'))continue;const _0x215a94=_0x1c8b62['split'](':')[0x2];for(const _0x8e35cb of _0x4f3b68['getWalker']({'singleCharacters':!0x0})){const _0x3180d3=this['_getVidAttributeName'](_0x8e35cb),_0x3e1aed='elementEnd'==_0x8e35cb['type']?_0x8e35cb['previousPosition']['path']['slice'](0x0,-0x1):_0x8e35cb['previousPosition']['path'],_0x4a8453=_0x53448b['getNodeByPath'](_0x3e1aed)['getAttribute'](_0x3180d3);this['_touched']['set'](_0x4a8453,{'userId':_0x215a94});}}}this['_startingRevisionId']=this['_revisionId'];const _0x528579=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x33383=>!this['_touched']['has'](_0x33383));let _0x2441d4=0x0;const _0x57ccc6=new Map();for(const _0x962d5b in _0x187918['diffData']){const _0x3c92fb=_0x187918['diffData'][_0x962d5b]['attachChange'],_0x5a2d05=_0x1fabc1(_0x187918['diffData'][_0x962d5b]['attributesAfter'])||{},_0x1e3550=_0x20d0b7['_makeModelFromViewString'](_0x187918['diffData'][_0x962d5b]['insertions']);_0x1e3550['rootName']=_0x962d5b,_0x1e3550['_isAttached']=!_0x3c92fb||_0x3c92fb['isAttached'],_0x1e3550['isAttached']=()=>_0x1e3550['_isAttached'],this['_diffRoots']['set'](_0x962d5b,_0x1e3550),this['_diffRootsAttributes']['set'](_0x962d5b,_0x5a2d05);const _0x10b8d5=this['_makeIdsRoot'](_0x1e3550,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x962d5b,_0x10b8d5),_0x57ccc6['set'](_0x962d5b,_0x1e3550['isAttached']()?_0x5a2d05:{});for(const [_0x258288,_0x4f0730]of _0x1e3550['markers']){if(!_0x258288['startsWith']('revision:'))continue;const _0xdd6e4f=_0x258288['split'](':')[0x2];for(const _0x56725e of _0x4f0730['getWalker']({'singleCharacters':!0x0})){const _0x319c70=this['_getVidAttributeName'](_0x56725e),_0x3092a1=this['_revisionId']++,_0x48d7e6='elementEnd'==_0x56725e['type']?_0x56725e['previousPosition']['path']['slice'](0x0,-0x1):_0x56725e['previousPosition']['path'];_0x10b8d5['getNodeByPath'](_0x48d7e6)['_setAttribute'](_0x319c70,_0x3092a1),this['_touched']['set'](_0x3092a1,{'userId':_0xdd6e4f});}}for(const _0x427602 of this['editor']['model']['createRangeIn'](_0x1e3550)['getWalker']({'singleCharacters':!0x0})){const _0x502adf=this['_getVidAttributeName'](_0x427602),_0x3b6137='elementEnd'==_0x427602['type']?_0x427602['previousPosition']['path']['slice'](0x0,-0x1):_0x427602['previousPosition']['path'],_0x3f0936=_0x10b8d5['getNodeByPath'](_0x3b6137);_0x3f0936['getAttribute'](_0x502adf)>0x0||_0x3f0936['_setAttribute'](_0x502adf,_0x528579[_0x2441d4++]);}for(const [_0x3affef,_0x483996]of _0x1e3550['markers'])_0x3affef['startsWith']('revision:')||this['_markers']['set'](_0x3affef,_0x483996);}const _0x3c973d=N('$graveyard');this['_baseRoots']['set']('$graveyard',_0x3c973d),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x3c973d,0x1));const _0x46b0ec=N('$graveyard');this['_diffRoots']['set']('$graveyard',_0x46b0ec),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x46b0ec,0x1));const _0x52735a=Array['from'](this['_diffRoots'])['map'](([_0x392ada,_0x380291])=>[_0x392ada,x(_0x380291)]);this['_saveMetaData'](this['_lastTo'],_0x52735a,this['_markers'],_0x57ccc6);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0x34dd2d,_0x16c9da,_0x492d2a,_0x276980){const _0x5c843a=new Map(_0x16c9da),_0x323029=new Map(_0x1fabc1(_0x276980)),_0x58c44f=new Map();for(const [_0x15f3e5,_0x16cd66]of _0x492d2a)_0x58c44f['set'](_0x15f3e5,{'start':_0x16cd66['start']['clone'](),'end':_0x16cd66['end']['clone'](),'rootName':_0x16cd66['root']['rootName']});this['_savedMetaData']['set'](_0x34dd2d,{'roots':_0x5c843a,'markers':_0x58c44f,'rootsAttributes':_0x323029});}['_removeMetaData'](_0x3228fe){this['_savedMetaData']['delete'](_0x3228fe);}['_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'](_0x2f1f7b,_0x323f3c=null){let _0x492f80=null;_0x2f1f7b['is']('documentFragment')||(_0x492f80=new nt(_0x2f1f7b['name'],{'vid_start':null===_0x323f3c?this['_revisionId']++:_0x323f3c++}));const _0x16b763=[];for(const _0x20be4c of _0x2f1f7b['getChildren']())if(_0x20be4c['is']('element')){_0x16b763['push'](this['_makeIdsRoot'](_0x20be4c,_0x323f3c));const _0x196d66=_0x16b763[_0x16b763['length']-0x1];null!==_0x323f3c&&(_0x323f3c=_0x196d66['is']('element','$text')?_0x196d66['getAttribute']('vid')+0x1:_0x196d66['getAttribute']('vid_end')+0x1);}else{for(let _0x2b01ae=0x0;_0x2b01ae<_0x20be4c['offsetSize'];_0x2b01ae++)_0x16b763['push'](new nt('$text',{'vid':null===_0x323f3c?this['_revisionId']++:_0x323f3c++}));}if(_0x2f1f7b['is']('documentFragment')){const _0x3e5b54=N(_0x2f1f7b['rootName']);return _0x3e5b54['_insertChild'](0x0,_0x16b763),_0x3e5b54;}return _0x492f80['_setAttribute']('vid_end',null===_0x323f3c?this['_revisionId']++:_0x323f3c++),_0x492f80['_insertChild'](0x0,_0x16b763),_0x492f80;}['_calculateMetaData'](_0x5c173a,_0x5d29db,_0x56664c){this['_reset']();const {roots:_0x5cadf5,markers:_0x2c0460,rootsAttributes:_0x3aa349}=this['_savedMetaData']['get'](_0x5c173a);this['_baseRoots']=new Map(_0x5cadf5),this['_baseRootsAttributes']=new Map(_0x1fabc1(_0x3aa349));for(const [_0x1202ec,_0x3cc833]of this['_baseRoots'])if('$graveyard'!==_0x1202ec&&(this['_diffRoots']['set'](_0x1202ec,x(_0x3cc833)),this['_diffRootsAttributes']=new Map(_0x1fabc1(_0x3aa349)),_0x56664c)){const _0x57bb22=this['_revisionId'];this['_idsRoots']['set'](_0x1202ec,this['_makeIdsRoot'](_0x3cc833)),this['_baseIdsRoots']['set'](_0x1202ec,this['_makeIdsRoot'](_0x3cc833,_0x57bb22));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',x(this['_baseRoots']['get']('$graveyard'))),_0x56664c&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x48e75a,_0x3adbce]of _0x2c0460){const _0x495a54=this['_baseRoots']['get'](_0x3adbce['rootName']),_0x38f5d3=this['_diffRoots']['get'](_0x3adbce['rootName']),_0x5f2b67=new rt(this['_fixPosition'](_0x3adbce['start'],_0x495a54),this['_fixPosition'](_0x3adbce['end'],_0x495a54)),_0x40a29f=this['_fixRange'](_0x5f2b67,_0x38f5d3);_0x495a54['markers']['set'](_0x48e75a,_0x5f2b67),this['_markers']['set'](_0x48e75a,_0x40a29f);}this['_applyOperations'](_0x5c173a,_0x5d29db,_0x56664c);}['_applyOperations'](_0x4d5610,_0xd5237b,_0x24782a){for(const _0x2a2ff6 of this['source']['getOperations'](_0x4d5610,_0xd5237b))this['_handleOperation'](_0x2a2ff6,_0x24782a);for(const _0x5ef9ee of this['_diffRoots']['values']())_0x5ef9ee['markers']['clear']();for(const [_0x39c443,_0x3b4041]of this['_markers']){this['_diffRoots']['get'](_0x3b4041['root']['rootName'])['markers']['set'](_0x39c443,_0x3b4041['clone']());}const _0x2de557=new Map(),_0x173c40=new Map();for(const [_0x1d1d21,_0x3d3f8d]of this['_diffRoots'])_0x2de557['set'](_0x1d1d21,x(_0x3d3f8d)),_0x173c40['set'](_0x1d1d21,this['_diffRootsAttributes']['get'](_0x1d1d21));this['_saveMetaData'](_0xd5237b,_0x2de557,this['_markers'],_0x173c40);}['_getPreviousFrom'](_0x27b056){const _0x5607ed=Array['from'](this['_savedMetaData']['keys']());_0x5607ed['sort']((_0x1a2641,_0xc371fb)=>_0x1a2641-_0xc371fb),_0x5607ed['reverse']();for(const _0x5b0833 of _0x5607ed)if(_0x5b0833<_0x27b056)return _0x5b0833;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x925a60,_0x29520c){const _0x2de7c4=Array['from'](_0x29520c['markers'])['map'](([_0x4709e1,_0x8b6de7])=>[_0x4709e1,this['_fixRange'](_0x8b6de7,_0x925a60)]);_0x925a60['markers']=new Map(_0x2de7c4);}['_transformMarkers'](_0x109edc){for(const _0x4ad265 of this['_markers']['values']()){const _0x5eb295=_0x4ad265['getTransformedByOperation'](_0x109edc),_0x295c35=rt['_createFromRanges'](_0x5eb295);_0x4ad265['start']=_0x295c35['start'],_0x4ad265['end']=_0x295c35['end'];}}['_handleOperation'](_0x1fcdaf,_0x3ebec9){if('addRoot'!=_0x1fcdaf['type']&&'detachRoot'!=_0x1fcdaf['type']){if('insert'==_0x1fcdaf['type']){const _0x43d7ec=_0x1fcdaf['position']['root']['rootName'];this['_diffRoots']['has'](_0x43d7ec)||(this['_diffRoots']['set'](_0x43d7ec,N(_0x43d7ec,!0x0)),this['_diffRootsAttributes']['set'](_0x43d7ec,{}),_0x3ebec9&&this['_idsRoots']['set'](_0x43d7ec,N(_0x43d7ec,!0x0)));}else{if('addRootAttribute'==_0x1fcdaf['type']||'removeRootAttribute'==_0x1fcdaf['type']||'changeRootAttribute'==_0x1fcdaf['type'])return void this['_handleRootAttributeOperation'](_0x1fcdaf);'marker'==_0x1fcdaf['type']&&this['_handleMarkerOperation'](_0x1fcdaf);}if('marker'!==_0x1fcdaf['type']){const _0x30e59d=this['_cloneOperation'](_0x1fcdaf,this['_diffRoots']);_0x30e59d['_execute'](),this['_transformMarkers'](_0x30e59d);}if(_0x3ebec9)switch(_0x1fcdaf['type']){case'insert':this['_handleInsertOperation'](_0x1fcdaf);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x1fcdaf);break;case'merge':this['_handleMergeOperation'](_0x1fcdaf);break;case'split':this['_handleSplitOperation'](_0x1fcdaf);}}else this['_handleRootOperation'](_0x1fcdaf,_0x3ebec9);}['_cloneOperation'](_0x3aceb8,_0x31a1ef){const _0x16b450=_0x3aceb8['clone']();return _0x16b450['_authorId']=_0x3aceb8['_authorId'],this['_fixOperation'](_0x16b450,_0x31a1ef),_0x16b450;}['_getBaseVids'](_0x2b0e95){return _0x2b0e95['map'](_0x1b300c=>{const _0x492aca=this['_getVidAttributeName'](_0x1b300c);return Number(_0x1b300c['item']['getAttribute'](_0x492aca));});}['_generateTape'](_0x32b1e3,_0x34a18f){if(_0x32b1e3['is']('element','$text'))_0x34a18f['push']({'item':_0x32b1e3,'type':'text'});else{_0x32b1e3['is']('element')&&_0x34a18f['push']({'item':_0x32b1e3,'type':'elementStart'});for(const _0xc0cad of _0x32b1e3['getChildren']())this['_generateTape'](_0xc0cad,_0x34a18f);_0x32b1e3['is']('element')&&_0x34a18f['push']({'item':_0x32b1e3,'type':'elementEnd'});}return _0x34a18f;}['_getState'](){const _0x4381dd=new Map(this['_touched']),_0x428991=new Map(_0x4381dd),_0x16d2e5=new Map(),_0x4e0ac3={'insertions':{},'deletions':{}},_0x520472={'insertions':{},'deletions':{}},_0x3cb560=new Map(),_0x5a2762=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x5a2762['delete']('$graveyard');for(const _0x1883eb of _0x5a2762){const _0x1a1eb0=this['_diffRoots']['get'](_0x1883eb)||N(_0x1883eb,!0x1),_0x388c2e=this['_baseRoots']['get'](_0x1883eb)||N(_0x1883eb,!0x1);_0x1a1eb0['isAttached']()||_0x388c2e['isAttached']()?(_0x4e0ac3['insertions'][_0x1883eb]=x(_0x1a1eb0),_0x4e0ac3['deletions'][_0x1883eb]=x(_0x388c2e),this['_copyMarkers'](_0x4e0ac3['deletions'][_0x1883eb],_0x388c2e),this['_copyMarkers'](_0x4e0ac3['insertions'][_0x1883eb],_0x1a1eb0),_0x520472['insertions'][_0x1883eb]=this['_generateTape'](this['_idsRoots']['get'](_0x1883eb),[]),_0x520472['deletions'][_0x1883eb]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x1883eb)||N(_0x1883eb,!0x1),[])):_0x5a2762['delete'](_0x1883eb);}for(const _0x1c3a95 of _0x5a2762){const _0x3924fc=_0x520472['insertions'][_0x1c3a95];for(const _0x11a2fb of _0x3924fc){const _0x4a6543=this['_getVidAttributeName'](_0x11a2fb),_0x5a5946=_0x11a2fb['item']['getAttribute'](_0x4a6543);_0x428991['delete'](_0x5a5946),_0x5a5946>=this['_startingRevisionId']&&_0x16d2e5['set'](_0x5a5946,_0x4381dd['get'](_0x5a5946));}}for(const _0xe629ff of _0x5a2762){const _0x505c3c=_0x520472['insertions'][_0xe629ff],_0x1664cd=this['_getBaseVids'](_0x520472['deletions'][_0xe629ff]);let _0x1f4298=0x0;for(const _0x7d596a of _0x505c3c){const _0x4a1662=this['_getVidAttributeName'](_0x7d596a),_0x528b61=_0x7d596a['item']['getAttribute'](_0x4a1662);if(!_0x16d2e5['has'](_0x528b61)&&!_0x3cb560['has'](_0x528b61)){if(_0x428991['has'](_0x528b61))_0x1f4298++;else{if(_0x528b61!=_0x1664cd[_0x1f4298]){const _0x4e8427=_0x4381dd['get'](_0x528b61)||_0x4381dd['get'](_0x1664cd[_0x1f4298]);for(;_0x528b61!=_0x1664cd[_0x1f4298];)_0x428991['has'](_0x1664cd[_0x1f4298])||(_0x3cb560['set'](_0x1664cd[_0x1f4298],_0x4e8427),_0x4381dd['set'](_0x1664cd[_0x1f4298],_0x4e8427)),_0x1f4298++;}_0x1f4298++;}}}}for(const _0x13251c of _0x5a2762){const _0x224792=_0x520472['insertions'][_0x13251c];for(const _0x464adc of _0x224792){const _0x4822fc=this['_getVidAttributeName'](_0x464adc),_0x3d0a1e=_0x464adc['item']['getAttribute'](_0x4822fc);if(_0x3cb560['has'](_0x3d0a1e)){const _0xbdbcae=_0x3cb560['get'](_0x3d0a1e);_0x428991['has'](_0x3d0a1e)||_0x428991['set'](_0x3d0a1e,{..._0xbdbcae}),_0x16d2e5['set'](_0x3d0a1e,{..._0xbdbcae});}}}for(const _0x4177ba of _0x428991['keys']())_0x4177ba>=this['_startingRevisionId']&&_0x428991['delete'](_0x4177ba);const _0x1af14e=new Map();for(const _0x385104 of _0x5a2762){let _0x4e017f=_0x520472['insertions'][_0x385104];for(const _0x252106 of _0x4e017f)if(_0x252106['item']['is']('element','tableCell')){const _0x2022e2=this['_getVidAttributeName'](_0x252106),_0x44e8ad=_0x252106['item']['getAttribute'](_0x2022e2);if(_0x16d2e5['has'](_0x44e8ad)){const _0x469639=_0x252106['item']['parent']['parent']['getAttribute']('vid_start'),_0x58e846=_0x1af14e['get'](_0x469639)||new Set();_0x58e846['add'](_0x16d2e5['get'](_0x44e8ad)['userId']),_0x1af14e['set'](_0x469639,_0x58e846);}}_0x4e017f=_0x520472['deletions'][_0x385104];for(const _0x350308 of _0x4e017f)if(_0x350308['item']['is']('element','tableCell')){const _0x27c61a=this['_getVidAttributeName'](_0x350308),_0x123598=_0x350308['item']['getAttribute'](_0x27c61a);if(_0x428991['has'](_0x123598)){const _0x488ccc=_0x350308['item']['parent']['parent']['getAttribute']('vid_start'),_0x1bf512=_0x1af14e['get'](_0x488ccc)||new Set();_0x1bf512['add'](_0x428991['get'](_0x123598)['userId']),_0x1af14e['set'](_0x488ccc,_0x1bf512);}}for(const _0x20697c of _0x1af14e['keys']())(_0x16d2e5['has'](_0x20697c)||_0x428991['has'](_0x20697c))&&_0x1af14e['delete'](_0x20697c);}for(const _0x13e563 of _0x5a2762){const _0x3997db=_0x520472['insertions'][_0x13e563];let _0x300466=null,_0xf30e80=null;for(const _0x33afd4 of _0x3997db){const _0x19a698=this['_getVidAttributeName'](_0x33afd4),_0x1c6ee3=_0x33afd4['item']['getAttribute'](_0x19a698),_0x421860=_0x1af14e['get'](_0x1c6ee3);_0x421860&&'elementStart'==_0x33afd4['type']&&(_0x300466=Array['from'](_0x421860)[0x0],_0xf30e80=_0x33afd4['item']['getAttribute']('vid_end')),_0x300466&&(_0x428991['set'](_0x1c6ee3,{'userId':_0x300466}),_0x16d2e5['set'](_0x1c6ee3,{'userId':_0x300466})),_0x1c6ee3==_0xf30e80&&(_0x300466=null,_0xf30e80=null);}}const _0x2a8c72={},_0x4100fc=new Set();for(const _0x4ca575 of _0x5a2762){const _0x55d3b5=_0x4e0ac3['deletions'][_0x4ca575],_0x281f5c=_0x4e0ac3['insertions'][_0x4ca575];for(const {userId:_0x2f768b}of this['_touchedMarkers']['values']())null!==_0x2f768b&&_0x4100fc['add'](_0x2f768b);for(const {userId:_0x122914}of this['_touchedRoots']['values']())null!==_0x122914&&_0x4100fc['add'](_0x122914);this['_markChanges'](_0x281f5c,_0x520472['insertions'][_0x4ca575],_0x16d2e5,'insertion',_0x4100fc),this['_markChanges'](_0x55d3b5,_0x520472['deletions'][_0x4ca575],_0x428991,'deletion',_0x4100fc),_0x2a8c72[_0x4ca575]={'insertions':this['_prepareViewToSave'](_0x281f5c),'deletions':this['_prepareViewToSave'](_0x55d3b5),'attachChange':this['_touchedRoots']['get'](_0x4ca575)||null,'attributesBefore':_0x1fabc1(this['_baseRootsAttributes']['get'](_0x4ca575))||{},'attributesAfter':_0x1fabc1(this['_diffRootsAttributes']['get'](_0x4ca575))};}return{'diffData':_0x2a8c72,'authorsIds':Array['from'](_0x4100fc)};}['_processRootBeforeSave'](_0x574d63){for(const [,_0x2e02bf]of _0x574d63['markers']){const _0x56353b=_0x2e02bf['start']['getAncestors']()['filter'](_0x269ed4=>'tableCell'==_0x269ed4['name']);for(const _0x565d46 of _0x56353b)0x1==_0x565d46['childCount']&&_0x565d46['getChild'](0x0)['is']('element','paragraph')&&_0x565d46['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x6580fd){this['_processRootBeforeSave'](_0x6580fd);const _0x555c8f=this['editor']['data']['toView'](_0x6580fd,{}),_0x41b92a=Array['from'](_0x555c8f['getChildren']())['map'](_0x3a62f2=>this['_getViewJson'](_0x3a62f2));return JSON['stringify'](_0x41b92a);}['_getViewJson'](_0xb15827){if(_0xb15827['is']('$text'))return _0xb15827['data'];{const _0x476967=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0x54c626=_0xb15827,_0x1e1319=this['editor']['data']['htmlProcessor']['domConverter'],_0x9d125e={'type':_0x476967['_getTypeCharForViewElement'](_0x54c626),'name':_0x54c626['name'],'attributes':Array['from'](_0x54c626['getAttributes']()),'children':Array['from'](_0x54c626['getChildren']())['map'](_0x31d848=>this['_getViewJson'](_0x31d848))};if(_0xb15827['is']('uiElement')&&'$comment'!=_0xb15827['name']){const _0x100ed1=_0xb15827['render'](_0x1e1319['domDocument'],_0x1e1319);_0x9d125e['children']['push'](_0x100ed1['outerHTML']);}else{if(_0xb15827['is']('rawElement')){const _0x4f30ca=_0x1e1319['domDocument']['createElement'](_0x54c626['name']);_0xb15827['render'](_0x4f30ca,_0x1e1319),_0x9d125e['children']['push'](_0x4f30ca['innerHTML']);}}const _0x261abf=Array['from'](_0x54c626['getCustomProperties']());_0x261abf['length']>0x0&&(_0x9d125e['customProperties']=_0x261abf);const _0x5e41ad=_0x54c626['getFillerOffset']();return null!==_0x5e41ad&&(_0x9d125e['fillerOffset']=_0x5e41ad),_0x9d125e;}}['_markChanges'](_0x246c04,_0x2bbc22,_0x2ffaac,_0x567137,_0x1f3a81){let _0x20defa=null,_0x477ed1=null,_0x16b910=0x0;const _0x1370ac=this['editor']['model'];for(let _0x2361c5=0x0;_0x2361c5<_0x2bbc22['length'];_0x2361c5++){const _0x5cb0b2=this['_getVidAttributeName'](_0x2bbc22[_0x2361c5]),_0x112243=_0x2bbc22[_0x2361c5]['item']['getAttribute'](_0x5cb0b2),_0x3bd699=_0x2ffaac['get'](_0x112243),_0x170cd2=_0x2361c5==_0x2bbc22['length']-0x1;(!_0x20defa&&_0x3bd699&&(_0x20defa=_0x3bd699,_0x477ed1=_0x2bbc22[_0x2361c5]),_0x20defa&&(!_0x3bd699||_0x3bd699['userId']!=_0x20defa['userId']))&&(_0x62978a(_0x3bd699,P(_0x477ed1,_0x246c04,_0x1370ac),P(_0x2bbc22[_0x2361c5],_0x246c04,_0x1370ac)),_0x20defa=_0x3bd699||null,_0x477ed1=_0x3bd699?_0x2bbc22[_0x2361c5]:null),_0x20defa&&_0x170cd2&&_0x62978a(_0x3bd699,P(_0x477ed1,_0x246c04,_0x1370ac),V(_0x2bbc22[_0x2361c5],_0x246c04,_0x1370ac));}function _0x62978a(_0x1f7776,_0x169d1b,_0x2377b0){const _0x528ba4=_0x20defa['userId'],_0x35b8f4='revision:'+_0x567137+':'+_0x528ba4+':'+_0x16b910++,_0x2b91fa=_0x1370ac['createRange'](_0x169d1b,_0x2377b0);_0x246c04['markers']['set'](_0x35b8f4,_0x2b91fa),null!==_0x528ba4&&_0x1f3a81['add'](_0x528ba4);}}['_getVidAttributeName'](_0x31435f){switch(_0x31435f['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x4d2863,_0x58a57c){_0x4d2863['baseVersion']=null;for(const _0x13b3eb in _0x4d2863){const _0x5e4f5b=_0x4d2863[_0x13b3eb];if(_0x5e4f5b instanceof at){const _0x4e1112=_0x58a57c['get'](_0x5e4f5b['root']['rootName']);_0x4d2863[_0x13b3eb]=this['_fixPosition'](_0x5e4f5b,_0x4e1112);}if(_0x5e4f5b instanceof rt){const _0x356088=_0x58a57c['get'](_0x5e4f5b['root']['rootName']);_0x4d2863[_0x13b3eb]=this['_fixRange'](_0x5e4f5b,_0x356088);}'root'===_0x13b3eb&&(_0x4d2863['root']=_0x58a57c['get'](_0x4d2863['root']['rootName']));}}['_fixRange'](_0x54834e,_0x4b8c0e){return this['editor']['model']['createRange'](this['_fixPosition'](_0x54834e['start'],_0x4b8c0e),this['_fixPosition'](_0x54834e['end'],_0x4b8c0e));}['_fixPosition'](_0x228421,_0x27731d){return this['editor']['model']['createPositionFromPath'](_0x27731d,_0x228421['path'],_0x228421['stickiness']);}['_handleInsertOperation'](_0x2ca303){const _0x4fbdc7=this['_idsRoots']['get'](_0x2ca303['position']['root']['rootName']),_0x373e39=this['_fixPosition'](_0x2ca303['position'],_0x4fbdc7),_0x34921b=null===_0x2ca303['_authorId']?null:_0x2ca303['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x380554=_0x373e39['parent'],_0x412fcd=this['_revisionId'],_0x2b07ba=[];for(const _0x60f868 of _0x2ca303['nodes'])if(_0x60f868['is']('element'))_0x2b07ba['push'](this['_makeIdsRoot'](_0x60f868));else{for(let _0x5e1a04=0x0;_0x5e1a04<_0x60f868['offsetSize'];_0x5e1a04++)_0x2b07ba['push'](new nt('$text',{'vid':this['_revisionId']++}));}const _0x2aac0b=this['_revisionId'];for(let _0x13d324=_0x412fcd;_0x13d324<_0x2aac0b;_0x13d324++)this['_touched']['set'](_0x13d324,{'userId':_0x34921b});_0x380554['_insertChild'](_0x373e39['offset'],_0x2b07ba);}['_handleMoveOperation'](_0xf870cc){(_0xf870cc=this['_cloneOperation'](_0xf870cc,this['_idsRoots']))['_execute']();const _0x590ff3=null===_0xf870cc['_authorId']?null:_0xf870cc['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x40945d=_0xf870cc['getMovedRangeStart'](),_0x142860=_0x40945d['parent'],_0x452108=_0x40945d['offset'];!function _0x472dd8(_0x390049,_0x406fde,_0x39649d,_0x2a9451){for(let _0x3eeab4=_0x39649d;_0x3eeab4<_0x2a9451;_0x3eeab4++){const _0x9d21b1=_0x406fde['getChild'](_0x3eeab4);_0x9d21b1['is']('element','$text')?_0x390049['set'](_0x9d21b1['getAttribute']('vid'),{'userId':_0x590ff3}):(_0x390049['set'](_0x9d21b1['getAttribute']('vid_start'),{'userId':_0x590ff3}),_0x472dd8(_0x390049,_0x9d21b1,0x0,_0x9d21b1['childCount']),_0x390049['set'](_0x9d21b1['getAttribute']('vid_end'),{'userId':_0x590ff3}));}}(this['_touched'],_0x142860,_0x452108,_0x452108+_0xf870cc['howMany']);}['_handleMergeOperation'](_0x1ef35c){const _0x295040=null===(_0x1ef35c=this['_cloneOperation'](_0x1ef35c,this['_idsRoots']))['_authorId']?null:_0x1ef35c['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x42541a=_0x1ef35c['targetPosition']['parent'],_0x3061c8=_0x1ef35c['sourcePosition']['parent'],_0x18a151=_0x42541a['getAttribute']('vid_end'),_0x3a6d1c=_0x3061c8['getAttribute']('vid_start');_0x42541a['_setAttribute']('vid_end',_0x3061c8['getAttribute']('vid_end')),_0x3061c8['_setAttribute']('vid_end',_0x18a151),this['_touched']['set'](_0x3a6d1c,{'userId':_0x295040}),this['_touched']['set'](_0x18a151,{'userId':_0x295040}),_0x1ef35c['_execute']();}['_handleSplitOperation'](_0x26ddf4){const _0x3624ba=null===(_0x26ddf4=this['_cloneOperation'](_0x26ddf4,this['_idsRoots']))['_authorId']?null:_0x26ddf4['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x54d291=_0x26ddf4['graveyardPosition'],_0x231637=_0x26ddf4['splitPosition']['parent'];_0x26ddf4['_execute']();const _0x1c81e9=_0x231637['getAttribute']('vid_end'),_0x4a4582=_0x26ddf4['insertionPosition']['nodeAfter'];if(_0x54d291){const _0x1e237a=_0x4a4582['getAttribute']('vid_end'),_0x24a0fa=_0x231637['getAttribute']('vid_end');_0x231637['_setAttribute']('vid_end',_0x1e237a),_0x4a4582['_setAttribute']('vid_end',_0x24a0fa),this['_touched']['set'](_0x231637['getAttribute']('vid_end'),{'userId':_0x3624ba}),this['_touched']['set'](_0x4a4582['getAttribute']('vid_start'),{'userId':_0x3624ba});}else{const _0x26c2b5=this['_revisionId']++,_0x403a04=this['_revisionId']++;_0x231637['_setAttribute']('vid_end',_0x26c2b5),_0x4a4582['_setAttribute']('vid_start',_0x403a04),_0x4a4582['_setAttribute']('vid_end',_0x1c81e9),this['_touched']['set'](_0x26c2b5,{'userId':_0x3624ba}),this['_touched']['set'](_0x403a04,{'userId':_0x3624ba});}}['_handleMarkerOperation'](_0x3e5f9f){if(!_0x3e5f9f['affectsData'])return;const _0x383b15=(_0x3e5f9f=this['_cloneOperation'](_0x3e5f9f,this['_diffRoots']))['oldRange']?_0x3e5f9f['oldRange']['root']:null,_0x4ef6a3=_0x3e5f9f['newRange']?_0x3e5f9f['newRange']['root']:null;_0x383b15&&this['_markers']['delete'](_0x3e5f9f['name']),_0x4ef6a3&&this['_markers']['set'](_0x3e5f9f['name'],_0x3e5f9f['newRange']['clone']());const _0x47971f=null===_0x3e5f9f['_authorId']?null:_0x3e5f9f['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x149ffd=_0x3e5f9f['name'];if(!this['_touchedMarkers']['has'](_0x149ffd))return void this['_touchedMarkers']['set'](_0x149ffd,{'range':_0x3e5f9f['oldRange'],'userId':_0x47971f});const _0x164b95=this['_touchedMarkers']['get'](_0x149ffd),_0x55b143=_0x164b95['range'],_0x31c406=_0x3e5f9f['newRange'];null==_0x55b143&&null==_0x31c406||_0x55b143&&_0x31c406&&_0x55b143['isEqual'](_0x31c406)?this['_touchedMarkers']['delete'](_0x3e5f9f['name']):_0x164b95['userId']=_0x47971f;}['_handleRootOperation'](_0x4f184d,_0x345c1a){this['_diffRoots']['has'](_0x4f184d['rootName'])?this['_diffRoots']['get'](_0x4f184d['rootName'])['_isAttached']=_0x4f184d['isAdd']:(this['_diffRoots']['set'](_0x4f184d['rootName'],N(_0x4f184d['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x4f184d['rootName'],{}),_0x345c1a&&this['_idsRoots']['set'](_0x4f184d['rootName'],N(_0x4f184d['rootName'],!0x0)));const _0x2b5aa8=null===_0x4f184d['_authorId']?null:_0x4f184d['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x29c289=this['_touchedRoots']['get'](_0x4f184d['rootName']);_0x29c289&&_0x29c289['userId']===_0x2b5aa8?this['_touchedRoots']['delete'](_0x4f184d['rootName']):this['_touchedRoots']['set'](_0x4f184d['rootName'],{'userId':_0x2b5aa8,'isAttached':_0x4f184d['isAdd']});}['_handleRootAttributeOperation'](_0x2a47fd){const _0x220665=this['_diffRootsAttributes']['get'](_0x2a47fd['root']['rootName']);null===_0x2a47fd['newValue']?delete _0x220665[_0x2a47fd['key']]:_0x220665[_0x2a47fd['key']]=_0x2a47fd['newValue'];}}function x(_0x1de38d){const _0x18b416=N(_0x1de38d['rootName'],_0x1de38d['isAttached']());for(const _0x4f6886 of _0x1de38d['getChildren']()){const _0x59104b=_0x4f6886['_clone'](!0x0);_0x18b416['_appendChild'](_0x59104b);}return _0x18b416;}function N(_0x6130d6,_0x5db180=!0x0){const _0x354589=new ht();return _0x354589['rootName']=_0x6130d6,_0x354589['_isAttached']=_0x5db180,_0x354589['isAttached']=()=>_0x354589['_isAttached'],_0x354589;}function P(_0x2d6273,_0x5f3cf0,_0x5dc9eb){const _0x363e94='elementEnd'==_0x2d6273['type']?_0x5dc9eb['createPositionAt'](_0x2d6273['item'],'end'):_0x5dc9eb['createPositionBefore'](_0x2d6273['item']);return _0x5dc9eb['createPositionFromPath'](_0x5f3cf0,_0x363e94['path'],_0x363e94['stickiness']);}function V(_0x1fc6b6,_0x99c709,_0x277c89){const _0x28d904='elementStart'==_0x1fc6b6['type']?_0x277c89['createPositionAt'](_0x1fc6b6['item'],0x0):_0x277c89['createPositionAfter'](_0x1fc6b6['item']);return _0x277c89['createPositionFromPath'](_0x99c709,_0x28d904['path'],_0x28d904['stickiness']);}class me extends/* #__PURE__ -- @preserve */
|
|
25
|
+
_0x1c562a(_0x3269ad){['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x81b649,_0x5c7330){super(_0x81b649),this['focusTracker']=new _0x78af34(),this['keystrokes']=new _0x39d239(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x5c7330),this['setTemplate']({'tag':'form','attributes':{'class':['ck','ck-revision-history-save-revision-form','ck-responsive-form'],'tabindex':'-1'},'children':[this['revisionNameInputView']]}),this['initializeCssTransitionDisablerMixin']();}['render'](){super['render'](),_0x1c2a08({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x465f7c=_0x4b5f61=>_0x4b5f61['stopPropagation']();this['keystrokes']['set']('arrowright',_0x465f7c),this['keystrokes']['set']('arrowleft',_0x465f7c),this['keystrokes']['set']('arrowup',_0x465f7c),this['keystrokes']['set']('arrowdown',_0x465f7c);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x44d693){this['revisionNameInputView']['fieldView']['element']['value']=_0x44d693['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x1f9c3d){const _0x439eb5=new et(this['locale'],ti),_0x5ae972=_0x439eb5['fieldView'];_0x5ae972['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x280ead=R(this['locale'],'Name\x20of\x20the\x20revision');return!_0x1f9c3d&&(_0x280ead+='\x20('+R(this['locale'],'optional')+')'),(_0x439eb5['label']=_0x280ead,_0x5ae972['on']('input',()=>{this['revisionNameInputValue']=_0x5ae972['element']['value']['trim']();}),_0x439eb5);}}class v extends _0x1973ac{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h];}['_saveRevisionFormView'];['init'](){const _0x204650=this['editor'],_0x315092=_0x204650['plugins']['get']('RevisionTracker');_0x204650['ui']['componentFactory']['add']('revisionHistory',_0x3645d3=>{const _0x459848=_0x35ed0a(_0x3645d3),_0x2b7e24=_0x459848['panelView']['children'],_0x5c510e=new _0x1b48dd(_0x3645d3),_0x8b1fe6=new _0x15e797(_0x3645d3),_0x5ba1a9=new _0x4bd511(_0x3645d3),_0x19a6c9=new _0x15e797(_0x3645d3),_0x7a4bea=new _0x4bd511(_0x3645d3);return _0x459848['bind']('isEnabled')['to'](_0x315092,'isReady',_0x315092,'isEnabled',_0x204650,'isReadOnly',(_0x5281f7,_0x1fb270,_0x46de71)=>_0x5281f7&&_0x1fb270&&!_0x46de71),_0x459848['buttonView']['set']({'icon':_0x2d57fb,'label':R(_0x3645d3,'Revision\x20history'),'tooltip':!0x0}),_0x5ba1a9['set']({'label':R(_0x3645d3,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x5ba1a9['bind']('isEnabled')['to'](_0x315092,'isReady',_0x315092,'isEnabled',_0x204650,'isReadOnly',(_0x3fca08,_0x1b621f,_0x3828d6)=>_0x3fca08&&_0x1b621f&&!_0x3828d6),_0x5ba1a9['on']('execute',()=>this['_showDialog']()),_0x7a4bea['set']({'label':R(_0x3645d3,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x7a4bea['bind']('isEnabled')['to'](_0x315092,'isReady',_0x204650,'isReadOnly',(_0xf74317,_0x49f933)=>_0xf74317&&!_0x49f933),_0x7a4bea['on']('execute',()=>{_0x204650['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x459848['isOpen']=!0x1,_0x204650['editing']['view']['focus']();}),_0x8b1fe6['children']['add'](_0x5ba1a9),_0x19a6c9['children']['add'](_0x7a4bea),_0x5c510e['role']='menu',_0x5c510e['items']['addMany']([_0x8b1fe6,_0x19a6c9]),_0x2b7e24['add'](_0x5c510e),_0x459848;}),_0x204650['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x1bdc09=this['editor'],_0x5de8cb=_0x1bdc09['locale'],_0x3d4304=new _0x4882bd(_0x5de8cb),_0x1cac3e=new _0x32b68d(_0x5de8cb);_0x3d4304['buttonView']['set']({'icon':_0x2d57fb,'label':R(_0x5de8cb,'Revision\x20history')});const _0xdcf14c=new _0x59b3f1(_0x5de8cb,_0x3d4304),_0x1f7b31=new _0x20703f(_0x5de8cb);_0x1f7b31['set']({'label':R(_0x5de8cb,'Save\x20current\x20revision')}),_0x1f7b31['delegate']('execute')['to'](_0x3d4304),_0x1f7b31['on']('execute',()=>{this['_showDialog']();}),_0xdcf14c['children']['add'](_0x1f7b31),_0x1cac3e['items']['add'](_0xdcf14c);const _0x85eb9e=new _0x59b3f1(_0x5de8cb,_0x3d4304),_0x560392=new _0x20703f(_0x5de8cb);return _0x560392['set']({'label':R(_0x5de8cb,'Open\x20revision\x20history')}),_0x560392['delegate']('execute')['to'](_0x3d4304),_0x560392['on']('execute',()=>{_0x1bdc09['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x85eb9e['children']['add'](_0x560392),_0x1cac3e['items']['add'](_0x85eb9e),_0x3d4304['panelView']['children']['add'](_0x1cac3e),_0x3d4304;}['_showDialog'](){const _0xb30458=this['editor'],_0xf91eb0=_0xb30458['locale'],_0xb04a38=_0xb30458['plugins']['get']('Dialog'),_0x7cb808=_0xb30458['plugins']['get']('RevisionTracker');function _0x205127(_0x22a07f){_0xb30458['config']['get']('revisionHistory.requireRevisionName')&&''===_0x22a07f['revisionName']?_0x22a07f['revisionNameInputView']['errorText']=R(_0xf91eb0,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0xb30458['plugins']['get'](h)['saveRevision']({'name':_0x22a07f['revisionName']}),_0xb04a38['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x205127(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0xb04a38['show']({'id':'revisionSave','title':R(_0xf91eb0,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':R(_0xb30458['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0xb04a38['hide']()},{'label':R(_0xb30458['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x5d2247){_0x5d2247['bind']('isEnabled')['to'](_0x7cb808,'isReady',_0x7cb808,'isEnabled',_0xb30458,'isReadOnly',(_0x4791f4,_0x2f3b59,_0x3cc64c)=>_0x4791f4&&_0x2f3b59&&!_0x3cc64c);},'onExecute':()=>_0x205127(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x1b6b33=this['editor'],_0x3a4b98=_0x1b6b33['locale'];this['_saveRevisionFormView']=new me(_0x3a4b98,_0x1b6b33['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class z extends _0x3269ad{['changeId'];['_model'];constructor(_0x1c8526,_0x1105e9){super(_0x1c8526),this['_model']=_0x1105e9,this['changeId']=_0x1105e9['id'];const _0x2ae8b1=this['bindTemplate'],_0x5329e4=R(_0x1c8526,_0x1105e9['data']['isSuggestion']?'Suggested\x20by':'add'==_0x1105e9['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x1105e9['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x2ae8b1['to']('type',_0x3b4678=>'ck-revision-change__'+_0x3b4678)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x5329e4}]},{'text':'\x20'+_0x1105e9['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class G extends/* #__PURE__ -- @preserve */
|
|
26
|
+
_0x26b56e(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x54db2e){super(),this['id']=_0x54db2e['id']||_0x173cdc(),this['author']=_0x54db2e['author'],this['type']=_0x54db2e['type'],this['data']=_0x54db2e['data']||{},this['rootName']=_0x54db2e['rootName'],this['set']('createdAt',_0x54db2e['createdAt']);}['toJSON'](){return{'id':this['id'],'authorId':this['author']['id'],'type':this['type'],'data':this['data'],'createdAt':this['createdAt']};}}class J{['newRevisionId'];['oldRevisionId'];['changes'];constructor(_0x486a77,_0x3f92a7){this['newRevisionId']=_0x486a77,this['oldRevisionId']=_0x3f92a7,this['changes']=new _0x28f4f5();}['_setChanges'](_0x2d80e3){for(const _0x39e5b8 of _0x2d80e3)this['changes']['add'](_0x39e5b8);}}class l extends _0x1973ac{['repository'];['adapter']=null;['_utils'];['_activeViewTarget'];['_changeView'];['_changeIdToChange'];['_balloon'];static get['pluginName'](){return'RevisionViewer';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[_0x4a7029,_0x5f3da8,S,$];}constructor(_0x27eb68){super(_0x27eb68),this['repository']=this['editor']['plugins']['get']('RevisionsRepository'),this['_utils']=this['editor']['plugins']['get']('RevisionHistoryUtils'),this['set']('activeChange',null),this['set']('activeView',null),this['_activeViewTarget']=null,this['set']('diff',null),this['set']('isReady',!0x1),this['set']('isEnabled',!0x0),this['on']('change:isEnabled',(_0x1d8393,_0x19789f,_0x1f2a2d)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x336746=>{for(const _0x31583b of this['editor']['editing']['view']['document']['roots'])_0x1f2a2d?_0x336746['removeClass']('ck-editor__editable__overlay',_0x31583b):_0x336746['addClass']('ck-editor__editable__overlay',_0x31583b);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0xb7211e=>null!==_0xb7211e),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x39d34c,_0x714008,_0x424ca7)=>_0x39d34c&&_0x424ca7?_0x714008['changes']['getIndex'](_0x424ca7):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x1a2670,_0x385262)=>_0x1a2670?_0x385262['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0x5f3da8);}['init'](){const _0x48f338=this['editor'],_0x103c7c=new lt(_0x48f338,{'direction':'backward'}),_0x992a28=new lt(_0x48f338,{'direction':'forward'});(_0x48f338['commands']['add']('showPreviousChange',_0x103c7c),_0x48f338['commands']['add']('showNextChange',_0x992a28),_0x48f338['commands']['add']('restoreRevision',new ut(_0x48f338)),this['on']('change:numberOfChanges',()=>{_0x103c7c['refresh'](),_0x992a28['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x48f338['enableReadOnlyMode']('revision-viewer'),_0x48f338['plugins']['has']('WidgetToolbarRepository'))&&_0x48f338['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x5d5910){return await this['_utils']['loadRevisionData'](_0x5d5910,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x5d5910);}async['getRevisionRootsAttributes'](_0x40e639){return await this['_utils']['loadRevisionData'](_0x40e639,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x40e639);}async['compare'](_0x154908,_0x264261,_0x41a342=!0x1){if(!this['isEnabled'])return;const _0x27c020=this['diff'],_0x459308=this['repository'],_0x299b48='string'==typeof _0x154908?_0x459308['getRevision'](_0x154908):_0x154908,_0x123458='string'==typeof _0x264261?_0x459308['getRevision'](_0x264261):_0x264261,_0x1d6dd2=_0x299b48['id'],_0xc65a48=_0x123458?_0x123458['id']:null;if(!_0x41a342&&this['diff']&&this['diff']['newRevisionId']===_0x1d6dd2&&this['diff']['oldRevisionId']===_0xc65a48)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new J(_0x1d6dd2,_0xc65a48);const _0x3019bc=this['_getRevisionsRange'](_0x299b48,_0x123458,!0x0)['map'](_0x590d9b=>this['_utils']['loadRevisionData'](_0x590d9b,this['adapter']));return _0x3019bc['push'](new Promise(_0x2c41fd=>{setTimeout(_0x2c41fd,0x14);})),Promise['all'](_0x3019bc)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x1b2a14=this['_getDiff'](_0x1d6dd2,_0xc65a48);for(const _0xc7986f of _0x1b2a14['changes'])this['_changeIdToChange']['set'](_0xc7986f['id'],_0xc7986f);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x18399f=>{for(const _0x423370 of this['editor']['model']['document']['getRootNames']())_0x18399f['detachRoot'](_0x423370);for(const _0x5e9127 of Object['keys'](_0x1b2a14['model'])){const _0x474657=_0x18399f['addRoot'](_0x5e9127);for(const _0x12ba22 of Object['keys'](_0x1b2a14['attributes'][_0x5e9127]))_0x18399f['setAttribute'](_0x12ba22,_0x1b2a14['attributes'][_0x5e9127][_0x12ba22],_0x474657);_0x18399f['insert'](_0x1b2a14['model'][_0x5e9127],_0x474657,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x1b2a14['changes'])),this['isReady']=!0x0;})['catch'](_0x6f7d98=>{console['error'](_0x6f7d98),this['_cleanUp'](),_0x27c020&&(this['diff']=_0x27c020),this['isReady']=!0x0;});}['addRevisionData'](_0x2752bd,_0xde2f43){const _0x4b7577=this['repository']['createRevision'](_0x2752bd);return _0x4b7577['on']('_update',(_0xa872b6,_0x19b298,_0x2d5e3f)=>_0xde2f43(_0x19b298,_0x2d5e3f,_0x4b7577)),this['repository']['addRevision'](_0x4b7577),_0x4b7577;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x4dabf6=>{for(const _0x5578d1 of this['editor']['model']['document']['getRootNames']())_0x4dabf6['detachRoot'](_0x5578d1);});}['_sortAndFilterDiffChanges'](_0x528e2c){const _0x184f8b=[],_0x25b82a=new Map();for(const _0x3d0393 of this['editor']['model']['document']['getRootNames']()){const _0x1c2d98=this['editor']['editing']['view']['getDomRoot'](_0x3d0393);if(!_0x1c2d98)continue;const _0x4e72e1=_0x1c2d98['getClientRects']()['item'](0x0);_0x4e72e1&&(_0x184f8b['push'](_0x3d0393),_0x25b82a['set'](_0x3d0393,_0x4e72e1));}return _0x184f8b['sort']((_0x131f39,_0x585a03)=>{const _0x6c13ad=_0x25b82a['get'](_0x131f39),_0x1d9515=_0x25b82a['get'](_0x585a03);return _0x6c13ad['y']-_0x1d9515['y']||_0x6c13ad['x']-_0x1d9515['x'];}),(_0x528e2c=_0x528e2c['filter'](_0x4a8218=>_0x184f8b['includes'](_0x4a8218['rootName'])))['sort']((_0x2ccb12,_0x5c7e09)=>_0x184f8b['indexOf'](_0x2ccb12['rootName'])-_0x184f8b['indexOf'](_0x5c7e09['rootName'])),_0x528e2c;}['_makeTape'](_0x556193){const _0x2642a2=Array['from'](_0x556193['markers'])['filter'](([_0x4ed5fb,_0x2604a9])=>_0x4ed5fb['startsWith']('revision:')&&!_0x2604a9['isCollapsed']),_0xf537ad=Array['from'](this['editor']['model']['createRangeIn'](_0x556193)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x2642a2['length'])for(const _0xc2d839 of _0xf537ad){const [_0x385023,_0x5717a7]=_0x2642a2[0x0],[,_0x36be9a,_0x2327dd]=_0x385023['split'](':');if(_0x5717a7['end']['isEqual'](_0xc2d839['nextPosition'])&&_0x2642a2['shift'](),(_0xc2d839['previousPosition']['isEqual'](_0x5717a7['start'])||_0xc2d839['previousPosition']['isAfter'](_0x5717a7['start']))&&('insertion'==_0x36be9a?_0xc2d839['isAdded']={'userId':_0x2327dd}:'deletion'==_0x36be9a&&(_0xc2d839['isRemoved']={'userId':_0x2327dd})),0x0==_0x2642a2['length'])break;}return _0xf537ad;}['_refreshStartEndIndex'](_0x52dbb0){const _0x1bc1f6=new Map();for(let _0x359905=0x0;_0x359905<_0x52dbb0['length'];_0x359905++)'text'===_0x52dbb0[_0x359905]['type']?(_0x52dbb0[_0x359905]['item']['startIndex']=_0x359905,_0x52dbb0[_0x359905]['item']['endIndex']=_0x359905):('elementStart'===_0x52dbb0[_0x359905]['type']?_0x52dbb0[_0x359905]['item']['startIndex']=_0x359905:'elementEnd'===_0x52dbb0[_0x359905]['type']&&(_0x52dbb0[_0x359905]['item']['endIndex']=_0x359905),_0x1bc1f6['set'](_0x52dbb0[_0x359905]['id'],_0x359905));for(const _0x24ccfd of _0x1bc1f6['values']())'elementStart'===_0x52dbb0[_0x24ccfd]['type']?_0x52dbb0[_0x24ccfd]['item']['endIndex']=_0x1bc1f6['get'](_0x52dbb0[_0x24ccfd]['pairId']):'elementEnd'===_0x52dbb0[_0x24ccfd]['type']&&(_0x52dbb0[_0x24ccfd]['item']['startIndex']=_0x1bc1f6['get'](_0x52dbb0[_0x24ccfd]['pairId']));}['_processTape'](_0x15fe28){for(let _0x2912f7=0x0;_0x2912f7<_0x15fe28['length'];_0x2912f7++){if('elementStart'===_0x15fe28[_0x2912f7]['type'])_0x15fe28[_0x2912f7]['item']['startIndex']=_0x2912f7;else{if('elementEnd'===_0x15fe28[_0x2912f7]['type']){_0x15fe28[_0x2912f7]['item']['endIndex']=_0x2912f7;const _0x179a6b=_0x15fe28[_0x2912f7]['item']['startIndex'];_0x15fe28[_0x179a6b]['pairId']=_0x15fe28[_0x2912f7]['id'],_0x15fe28[_0x2912f7]['pairId']=_0x15fe28[_0x179a6b]['id'];}else _0x15fe28[_0x2912f7]['item']['startIndex']=_0x2912f7,_0x15fe28[_0x2912f7]['item']['endIndex']=_0x2912f7,_0x15fe28[_0x2912f7]['pairId']=null;}_0x15fe28[_0x2912f7]['markersStart']||(_0x15fe28[_0x2912f7]['markersStart']=[],_0x15fe28[_0x2912f7]['markersEnd']=[]);}}['_markInsertions'](_0x27ac57,_0x110d71){const _0x559705=_0x27ac57['filter'](_0x558137=>!_0x558137['isAdded']);for(let _0x421ca5=0x0;_0x421ca5<_0x110d71['length'];_0x421ca5++)_0x110d71[_0x421ca5]['isAdded']&&(_0x559705[_0x421ca5]['isAdded']=_0x110d71[_0x421ca5]['isAdded']);}['_getDiff'](_0x505078,_0xc8a4b1=null){const _0x4193b7=this['repository']['getRevision'](_0x505078),_0x562238=_0xc8a4b1?this['repository']['getRevision'](_0xc8a4b1):null,_0x449bb3=this['_getRevisionsRange'](_0x4193b7,_0x562238),_0x5e2f93=_0x449bb3[_0x449bb3['length']-0x1],_0x52881a=new Map(),_0x233678={'model':{},'attributes':{},'changes':[]},_0x3c2b32=new Set(),_0xbc4467=new Map();for(let _0xe6ed2d=_0x449bb3['length']-0x1;_0xe6ed2d>=0x0;_0xe6ed2d--){const _0x15ae25=_0x449bb3[_0xe6ed2d];for(const _0x532d2f of Object['keys'](_0x15ae25['diffData']))if(_0x15ae25['diffData'][_0x532d2f]['attachChange']){const _0x343a2a=_0x15ae25['diffData'][_0x532d2f]['attachChange'];_0x343a2a['isAttached']?(_0x3c2b32['add'](_0x532d2f),_0xbc4467['has'](_0x532d2f)&&_0xbc4467['get'](_0x532d2f)['userId']==_0x343a2a['userId']?_0xbc4467['delete'](_0x532d2f):_0xbc4467['set'](_0x532d2f,_0x343a2a)):_0xbc4467['has'](_0x532d2f)?(_0x3c2b32['delete'](_0x532d2f),_0xbc4467['delete'](_0x532d2f)):(_0x3c2b32['add'](_0x532d2f),_0xbc4467['set'](_0x532d2f,_0x343a2a));}else _0x3c2b32['add'](_0x532d2f);}for(const _0x212c1e of _0x3c2b32){const _0x5c4818=_0xbc4467['has'](_0x212c1e)&&!_0xbc4467['get'](_0x212c1e)['isAttached'];let _0x151a5b=_0x5c4818?_0x449bb3['length']-0x1:0x0;const _0x517321=_0x5c4818?-0x1:0x1;for(;_0x449bb3[_0x151a5b];){const _0x323024=_0x449bb3[_0x151a5b];if(_0x323024['diffData'][_0x212c1e]){const _0x268df0=_0x5c4818?_0x323024['diffData'][_0x212c1e]['attributesBefore']:_0x323024['diffData'][_0x212c1e]['attributesAfter'];_0x233678['attributes'][_0x212c1e]=_0x268df0?_0x1fabc1(_0x268df0):{};break;}_0x151a5b+=_0x517321;}}for(const _0x46eb1f of _0x449bb3){_0x46eb1f['model']={};for(const _0x38a722 of _0x46eb1f['authors'])_0x52881a['set'](_0x38a722['id'],_0x38a722);for(const _0x6c06d2 of _0x3c2b32){const _0x401481=_0x46eb1f['diffData'][_0x6c06d2]?_0x46eb1f['diffData'][_0x6c06d2]['insertions']:'[]',_0x2f6198=_0x46eb1f['diffData'][_0x6c06d2]?_0x46eb1f['diffData'][_0x6c06d2]['deletions']:'[]';_0x46eb1f['model'][_0x6c06d2]={'insertions':this['_utils']['_makeModelFromViewString'](_0x401481),'deletions':this['_utils']['_makeModelFromViewString'](_0x2f6198)};}}for(const _0x112e35 of _0x3c2b32){let _0x5c1acf=null,_0x16b046=0x0;const _0x599c0d=new Map(Array['from'](_0x4193b7['model'][_0x112e35]['insertions']['markers'])['filter'](([_0x55db09])=>!_0x55db09['startsWith']('revision:')));let _0x342e63=0x0;for(const _0x2752ac of _0x449bb3){const _0x178e41=this['_makeTape'](_0x2752ac['model'][_0x112e35]['insertions']);_0x2752ac==_0x4193b7?(_0x5c1acf=_0x178e41,_0x16b046=_0x5c1acf['length'],_0x5c1acf['forEach'](_0x33db7c=>{_0x33db7c['id']=_0x342e63++;}),this['_processTape'](_0x5c1acf)):this['_markInsertions'](_0x5c1acf,_0x178e41);const _0x922093=_0x5c1acf['filter'](_0x19c18e=>!_0x19c18e['isAdded'])['map'](_0x47f1fe=>_0x47f1fe['id']);let _0x49115f=0x0;const _0x48120f=this['_makeTape'](_0x2752ac['model'][_0x112e35]['deletions']);_0x48120f['forEach'](_0x4152a4=>{_0x4152a4['isRemoved']?_0x4152a4['id']=_0x16b046++:_0x4152a4['id']=_0x922093[_0x49115f++];}),this['_processTape'](_0x48120f),this['_setDistance'](_0x5c1acf,'isAdded'),this['_setDistance'](_0x48120f,'isRemoved'),_0x2752ac==_0x4193b7&&this['_markMarkers'](_0x5c1acf,_0x599c0d),_0x5c1acf=this['_joinTapes'](_0x5c1acf,_0x48120f),this['_refreshStartEndIndex'](_0x5c1acf),this['_setDistance'](_0x5c1acf,'isRemoved');}_0x5c1acf=_0x5c1acf['filter'](_0x294ebd=>!(_0x294ebd['isAdded']&&_0x294ebd['isRemoved']));const _0x59e287=new Map(_0x5e2f93['model'][_0x112e35]['deletions']['markers']),_0x3c9e4f=new Set(_0x599c0d['keys']());for(const _0x17c064 of _0x59e287['keys']())_0x3c9e4f['delete'](_0x17c064);this['_markSuggestions'](_0x5c1acf,_0x3c9e4f),this['_fixObsoleteTags'](_0x5c1acf),_0x5c1acf=this['_removeMissingPairs'](_0x5c1acf),_0x5c1acf=this['_markMismatchedRemovedTags'](_0x5c1acf),_0x5c1acf=this['_removeUnsupportedChanges'](_0x5c1acf);const {root:_0x51bfa6,changes:_0x278005}=this['_makeModelFromTape'](_0x5c1acf,_0x52881a,_0x112e35);_0x233678['model'][_0x112e35]=_0x51bfa6;const _0x5c09e8=_0xbc4467['get'](_0x112e35);if(_0x5c09e8){const _0x3c5a7b=_0x52881a['get'](_0x5c09e8['userId']),_0x5b0fff=new G({'author':_0x3c5a7b,'type':_0x5c09e8['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x112e35});_0x278005['unshift'](_0x5b0fff),_0x233678['attributes'][_0x112e35]['revisionHistoryAttachChange']=_0x5b0fff['id'];}_0x233678['changes']=_0x233678['changes']['concat'](_0x278005);}return _0x233678;}['_markMarkers'](_0x1ffb51,_0x54a2cf){for(let _0x2a80ef=0x0;_0x2a80ef<_0x1ffb51['length'];_0x2a80ef++)for(const [_0xfb8853,_0x533be7]of _0x54a2cf)!_0x533be7['isCollapsed']&&_0x533be7['start']['isEqual'](_0x1ffb51[_0x2a80ef]['previousPosition'])&&_0x1ffb51[_0x2a80ef]['markersStart']['push'](_0xfb8853),_0x533be7['end']['isEqual'](_0x1ffb51[_0x2a80ef]['nextPosition'])&&_0x1ffb51[_0x2a80ef]['markersEnd']['push'](_0xfb8853);}['_joinTapes'](_0x3f2a01,_0x427f2a){let _0x594d60=[],_0x39abd0=0x0,_0x52e50e=0x0;for(;_0x39abd0<_0x3f2a01['length']||_0x52e50e<_0x427f2a['length'];){const _0x522c84=_0x3f2a01[_0x39abd0]||{},_0x419e97=_0x427f2a[_0x52e50e]||{};if(_0x522c84['id']==_0x419e97['id'])_0x39abd0++,_0x52e50e++,_0x594d60['push'](_0x522c84);else{if(_0x419e97['isRemoved']&&_0x522c84['isAdded']){const {commonTape:_0x4975e1,iEnd:_0x3e8890,jEnd:_0x25a41b}=this['_threeWayMerge'](_0x3f2a01,_0x39abd0,_0x427f2a,_0x52e50e);_0x594d60=_0x594d60['concat'](_0x4975e1),_0x39abd0=_0x3e8890,_0x52e50e=_0x25a41b;}else _0x419e97['isRemoved']?(_0x52e50e++,_0x594d60['push'](_0x419e97)):(_0x39abd0++,_0x594d60['push'](_0x522c84));}}return _0x594d60;}['_markSuggestions'](_0x3e5eae,_0x8aa3f2){const _0xe77d0b=[];for(let _0x4266ff=0x0;_0x4266ff<_0x3e5eae['length'];_0x4266ff++){for(let _0x2b6e0b=0x0;_0x2b6e0b<_0x3e5eae[_0x4266ff]['markersStart']['length'];_0x2b6e0b++){const _0x2059c9=_0x3e5eae[_0x4266ff]['markersStart'][_0x2b6e0b];if(!_0x8aa3f2['has'](_0x2059c9))continue;const {group:_0x16ef60,type:_0x4d8070,authorId:_0x2fc62e}=_0xec841d(_0x2059c9);'revision-suggestion'!=_0x16ef60||'insertion'!=_0x4d8070&&'deletion'!=_0x4d8070||(_0xe77d0b['unshift']({'type':_0x4d8070,'name':_0x2059c9,'userId':_0x2fc62e}),_0x3e5eae[_0x4266ff]['markersStart']['splice'](_0x2b6e0b,0x1),_0x2b6e0b--);}_0x29ca3d(_0x3e5eae[_0x4266ff]);for(let _0x49da84=0x0;_0x49da84<_0x3e5eae[_0x4266ff]['markersEnd']['length'];_0x49da84++){const _0x2f26a4=_0x3e5eae[_0x4266ff]['markersEnd'][_0x49da84];if(!_0x8aa3f2['has'](_0x2f26a4))continue;const {group:_0x36b906,type:_0x40b20a}=_0xec841d(_0x2f26a4);if('revision-suggestion'!=_0x36b906||'insertion'!=_0x40b20a&&'deletion'!=_0x40b20a)continue;_0x3e5eae[_0x4266ff]['markersEnd']['splice'](_0x49da84,0x1),_0x49da84--;const _0x3f0ab8=_0xe77d0b['findIndex'](_0x3ba6a9=>_0x3ba6a9['name']==_0x2f26a4);_0x3f0ab8>-0x1&&_0xe77d0b['splice'](_0x3f0ab8,0x1);}}function _0xec841d(_0x1a01fb){const _0x5e0842=_0x1a01fb['split'](':');return{'group':_0x5e0842[0x0],'type':_0x5e0842[0x1],'subType':_0x5e0842['length']>=0x5?_0x5e0842[0x2]:null,'id':_0x5e0842['length']<0x5?_0x5e0842[0x2]:_0x5e0842[0x3],'authorId':_0x5e0842['length']<0x5?_0x5e0842[0x3]:_0x5e0842[0x4],'markerCount':0x6==_0x5e0842['length']?_0x5e0842[0x5]:null};}function _0x29ca3d(_0x1344c3){for(let _0x54fa66=0x0;_0x54fa66<_0xe77d0b['length'];_0x54fa66++){if(_0x1344c3['isAdded']&&'insertion'==_0xe77d0b[_0x54fa66]['type']&&_0x1344c3['isAdded']['userId']==_0xe77d0b[_0x54fa66]['userId'])return _0x1344c3['isAddSuggestion']=_0xe77d0b[_0x54fa66],void delete _0x1344c3['isAdded'];if(!_0x1344c3['isAdded']&&!_0x1344c3['isRemoved']&&'deletion'==_0xe77d0b[_0x54fa66]['type'])return void(_0x1344c3['isRemoveSuggestion']=_0xe77d0b[_0x54fa66]);}}}['_setDistance'](_0x1960d2,_0x40421c){let _0x4c72f0=0x0,_0x2154bf=!0x1;const _0x218a5b=new Map();for(const _0x178fa9 of _0x1960d2)_0x178fa9[_0x40421c]?_0x2154bf&&(_0x4c72f0++,_0x2154bf=!0x1):(_0x4c72f0++,_0x2154bf=!0x0),_0x218a5b['set'](_0x178fa9['id'],_0x4c72f0);for(let _0x1bd0c0=0x0;_0x1bd0c0<_0x1960d2['length'];_0x1bd0c0++){if('isRemoved'==_0x40421c&&_0x1960d2[_0x1bd0c0]['isAdded']||'isAdded'==_0x40421c&&_0x1960d2[_0x1bd0c0]['isRemoved'])continue;if('text'==_0x1960d2[_0x1bd0c0]['type']){_0x1960d2[_0x1bd0c0]['distance']=0x0;continue;}const _0x47d63b=_0x218a5b['get'](_0x1960d2[_0x1bd0c0]['pairId']),_0x4ff757=_0x218a5b['get'](_0x1960d2[_0x1bd0c0]['id']);_0x1960d2[_0x1bd0c0]['distance']=_0x47d63b-_0x4ff757;}}['_getRevisionsRange'](_0x251af8,_0x5af19c,_0x12b242=!0x1){const _0x3f95db=[];let _0x43916b=this['repository']['getIndex'](_0x251af8),_0x368c4c=this['repository']['getIndex'](_0x5af19c);for(-0x1==_0x368c4c&&(_0x368c4c=this['repository']['_revisions']['length'],_0x12b242=!0x1);_0x43916b<_0x368c4c;)_0x3f95db['push'](this['repository']['getRevision'](_0x43916b)),_0x43916b++;return _0x12b242&&_0x3f95db['push'](this['repository']['getRevision'](_0x43916b)),_0x3f95db;}['_threeWayMerge'](_0x330040,_0x5ae9cf,_0x41f4ee,_0xc0defa){const _0x29d1e1=this['editor']['model']['schema'];let _0x18907b=_0x5ae9cf;for(;_0x330040[_0x18907b]&&_0x330040[_0x18907b]['isAdded'];)_0x18907b++;let _0x3d842e=_0xc0defa;for(;_0x41f4ee[_0x3d842e]&&_0x41f4ee[_0x3d842e]['isRemoved'];)_0x3d842e++;_0xb75b57(_0x330040,_0x5ae9cf,_0x18907b),_0xb75b57(_0x41f4ee,_0xc0defa,_0x3d842e);const _0x5385ac=_0x41f4ee['slice'](_0xc0defa,_0x3d842e)['concat'](_0x330040['slice'](_0x5ae9cf,_0x18907b));return _0x5385ac['sort']((_0x232e71,_0x48277f)=>_0x232e71['side']!=_0x48277f['side']?_0x232e71['side']-_0x48277f['side']:_0x232e71['level']!=_0x48277f['level']?_0x232e71['level']-_0x48277f['level']:_0x232e71['distance']!=_0x48277f['distance']?_0x48277f['distance']-_0x232e71['distance']:!!_0x232e71['isAdded']!=!!_0x48277f['isAdded']?-0x1==_0x232e71['side']||0x0==_0x232e71['side']?_0x232e71['isAdded']?-0x1:0x1:_0x232e71['isAdded']?0x1:-0x1:_0x232e71['index']-_0x48277f['index']),{'commonTape':_0x5385ac,'iEnd':_0x18907b,'jEnd':_0x3d842e};function _0xb75b57(_0x13f6da,_0x2a5433,_0x2de2a4){let _0x279241=-0x1,_0x527102=Number['POSITIVE_INFINITY'],_0x2b8cee=!0x0;for(let _0x2a8d47=_0x2a5433;_0x2a8d47<_0x2de2a4;_0x2a8d47++)if(_0x29d1e1['isInline'](_0x13f6da[_0x2a8d47]['item'])||(_0x2b8cee=!0x1),_0x13f6da[_0x2a8d47]['item']['startIndex']<_0x2a5433&&(_0x279241=_0x2a8d47),_0x13f6da[_0x2a8d47]['item']['endIndex']>=_0x2de2a4){_0x527102=_0x2a8d47;break;}_0x2b8cee&&(_0x279241=_0x2de2a4-0x1);for(let _0x2e466c=_0x2a5433;_0x2e466c<_0x2de2a4;_0x2e466c++)_0x13f6da[_0x2e466c]['side']=_0x2e466c<=_0x279241?-0x1:_0x2e466c<_0x527102?0x0:0x1,_0x13f6da[_0x2e466c]['index']=_0x2e466c;let _0x1e97c9=0x0;for(let _0x7a153c=_0x2a5433;_0x7a153c<=_0x279241;_0x7a153c++)0x0==_0x13f6da[_0x7a153c]['distance']?_0x13f6da[_0x7a153c]['level']=_0x1e97c9:(_0x1e97c9++,_0x13f6da[_0x7a153c]['level']=_0x1e97c9,_0x1e97c9++);for(let _0x530289=_0x2a5433;_0x530289<_0x2de2a4;_0x530289++)0x0==_0x13f6da[_0x530289]['side']&&(_0x13f6da[_0x530289]['level']=_0x1e97c9);_0x1e97c9=0x0;for(let _0x11e4b7=_0x2de2a4-0x1;_0x11e4b7>=_0x527102;_0x11e4b7--)0x0==_0x13f6da[_0x11e4b7]['distance']?_0x13f6da[_0x11e4b7]['level']=_0x1e97c9:(_0x1e97c9--,_0x13f6da[_0x11e4b7]['level']=_0x1e97c9,_0x1e97c9--);}}['_fixObsoleteTags'](_0xe730e9){const _0x26b091=new Map(),_0x1586ce=this['editor']['model']['schema'];for(let _0x1557d8=0x1;_0x1557d8<_0xe730e9['length'];_0x1557d8++){let _0x8416b2,_0x49d1cd,_0x483cb7;const _0x1e6267=_0xe730e9[_0x1557d8],_0x284da6=_0xe730e9[_0x1557d8-0x1];if('text'==_0x1e6267['type'])continue;if(_0x1e6267['type']!=_0x284da6['type'])continue;if(!_0x1586ce['isBlock'](_0x284da6['item'])||_0x1586ce['isLimit'](_0x284da6['item']))continue;if(!_0x1586ce['isBlock'](_0x1e6267['item'])||_0x1586ce['isLimit'](_0x1e6267['item']))continue;if((_0xe730e9[_0x1557d8]['isAdded']||_0xe730e9[_0x1557d8]['isAddSuggestion'])&&_0xe730e9[_0x1557d8-0x1]['isRemoved'])_0x8416b2=_0xe730e9[_0x1557d8],_0x49d1cd=_0xe730e9[_0x1557d8-0x1],_0x483cb7=_0x1557d8-0x1;else{if(!_0xe730e9[_0x1557d8]['isRemoved']||!_0xe730e9[_0x1557d8-0x1]['isAdded']&&!_0xe730e9[_0x1557d8-0x1]['isAddSuggestion'])continue;_0x8416b2=_0xe730e9[_0x1557d8-0x1],_0x49d1cd=_0xe730e9[_0x1557d8],_0x483cb7=_0x1557d8;}const _0x208030=_0x8416b2['level']==_0x49d1cd['level'],_0x27eeb2=Math['abs'](_0x8416b2['level'])<Math['abs'](_0x49d1cd['level'])&&0x0==_0x49d1cd['distance'];(_0x208030||_0x27eeb2)&&(_0x26b091['set'](_0x49d1cd['id'],_0x8416b2['id']),_0xe730e9['splice'](_0x483cb7,0x1),_0x1557d8--,_0x8416b2['isAdded']=!0x1);}for(let _0x2af459=0x0;_0x2af459<_0xe730e9['length'];_0x2af459++)_0x26b091['has'](_0xe730e9[_0x2af459]['pairId'])&&(_0xe730e9[_0x2af459]['pairId']=_0x26b091['get'](_0xe730e9[_0x2af459]['pairId']));}['_removeMissingPairs'](_0x2b896b){const _0x134f01=new Set(_0x2b896b['map'](_0x382539=>_0x382539['id']));for(let _0x6a7aca=0x0;_0x6a7aca<_0x2b896b['length'];_0x6a7aca++)_0x134f01['has'](_0x2b896b[_0x6a7aca]['pairId'])||0x0==_0x2b896b[_0x6a7aca]['distance']||(_0x2b896b[_0x6a7aca]['isIncorrect']=!0x0);return _0x2b896b['filter'](_0x1e208e=>!_0x1e208e['isIncorrect']);}['_markMismatchedRemovedTags'](_0x2e84f4){const _0x5799f7=new Set();for(let _0x26bffb=0x0;_0x26bffb<_0x2e84f4['length'];_0x26bffb++){if(_0x5799f7['has'](_0x2e84f4[_0x26bffb]['id'])&&_0x2e84f4[_0x26bffb]['isRemoved']&&(_0x2e84f4[_0x26bffb]['isIncorrect']=!0x0),_0x2e84f4[_0x26bffb]['isIncorrect'])continue;if(0x0==_0x2e84f4[_0x26bffb]['distance'])continue;if('elementStart'!=_0x2e84f4[_0x26bffb]['type'])continue;if(null==_0x2e84f4[_0x26bffb]['pairId'])continue;let _0x58894d=_0x26bffb+0x1,_0x53ab36=0x0;for(;_0x2e84f4[_0x58894d]['id']!=_0x2e84f4[_0x26bffb]['pairId'];)'elementStart'==_0x2e84f4[_0x58894d]['type']?_0x53ab36++:'elementEnd'==_0x2e84f4[_0x58894d]['type']&&_0x53ab36--,_0x58894d++;if(0x0!=_0x53ab36){if(_0x2e84f4[_0x26bffb]['isRemoved'])_0x2e84f4[_0x26bffb]['isIncorrect']=!0x0;else{for(;_0x58894d!=_0x26bffb;)_0x2e84f4[_0x58894d]['isRemoved']&&0x0!=_0x2e84f4[_0x58894d]['distance']&&(_0x2e84f4[_0x58894d]['isIncorrect']=!0x0,_0x5799f7['add'](_0x2e84f4[_0x58894d]['pairId'])),_0x58894d--;}}}return _0x2e84f4['filter'](_0x339540=>!_0x339540['isIncorrect']);}['_removeUnsupportedChanges'](_0x3a2aae){const _0x53dc87=this['editor']['model']['schema'];for(let _0x16838c=0x0;_0x16838c<_0x3a2aae['length'];_0x16838c++){if(!(_0x3a2aae[_0x16838c]['isAdded']||_0x3a2aae[_0x16838c]['isAddSuggestion']||_0x3a2aae[_0x16838c]['isRemoved']||_0x3a2aae[_0x16838c]['isRemoveSuggestion']))continue;if(0x0==_0x3a2aae[_0x16838c]['distance'])continue;const _0x90dbd7=_0x3a2aae[_0x16838c]['item'];_0x53dc87['isBlock'](_0x90dbd7)||_0x53dc87['isLimit'](_0x90dbd7)||(_0x3a2aae[_0x16838c]['isAdded']&&delete _0x3a2aae[_0x16838c]['isAdded'],_0x3a2aae[_0x16838c]['isAddSuggestion']&&delete _0x3a2aae[_0x16838c]['isAddSuggestion'],_0x3a2aae[_0x16838c]['isRemoveSuggestion']&&delete _0x3a2aae[_0x16838c]['isRemoveSuggestion'],_0x3a2aae[_0x16838c]['isRemoved']&&(_0x3a2aae[_0x16838c]['isIncorrect']=!0x0));}return _0x3a2aae['filter'](_0x5e9ccd=>!_0x5e9ccd['isIncorrect']);}['_makeModelFromTape'](_0x525f77,_0x2bf039,_0x5f22ee){const _0x5342b7=new ht(),_0x4b8d56=[],_0x4c0328=new Map(),_0x5c763f=this['editor']['model'],_0x4c7e8e=_0x5c763f['schema'],_0xc47a9c=[_0x5342b7],_0x318ff6={},_0x1cd8a0={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x271b9b=null;const _0xe59c44=[0x0];for(let _0x343ffc=0x0;_0x343ffc<_0x525f77['length'];_0x343ffc++)if('elementStart'===_0x525f77[_0x343ffc]['type']){_0x525f77[_0x343ffc]['previousPosition']=_0x5c763f['createPositionFromPath'](_0x5342b7,_0xe59c44);const _0x3fa9cf=new nt(_0x525f77[_0x343ffc]['item']['name'],_0x525f77[_0x343ffc]['item']['getAttributes']());_0xc47a9c[0x0]['_appendChild'](_0x3fa9cf),_0xe59c44['push'](0x0),_0xc47a9c['unshift'](_0x3fa9cf),_0x525f77[_0x343ffc]['nextPosition']=_0x5c763f['createPositionFromPath'](_0x5342b7,_0xe59c44);}else'elementEnd'===_0x525f77[_0x343ffc]['type']?(_0xc47a9c['shift'](),_0x525f77[_0x343ffc]['previousPosition']=_0x5c763f['createPositionFromPath'](_0x5342b7,_0xe59c44),_0xe59c44['pop'](),_0xe59c44[_0xe59c44['length']-0x1]++,_0x525f77[_0x343ffc]['nextPosition']=_0x5c763f['createPositionFromPath'](_0x5342b7,_0xe59c44)):(_0x525f77[_0x343ffc]['previousPosition']=_0x5c763f['createPositionFromPath'](_0x5342b7,_0xe59c44),_0x271b9b?_0x271b9b['_data']+=_0x525f77[_0x343ffc]['item']['data']:_0x271b9b=new ct(_0x525f77[_0x343ffc]['item']['data'],_0x525f77[_0x343ffc]['item']['getAttributes']()),_0x525f77[_0x343ffc+0x1]&&'text'===_0x525f77[_0x343ffc+0x1]['type']&&_0x1d5adb(_0x271b9b,_0x525f77[_0x343ffc+0x1]['item'])||(_0xc47a9c[0x0]['_appendChild'](_0x271b9b),_0x271b9b=null),_0xe59c44[_0xe59c44['length']-0x1]+=_0x525f77[_0x343ffc]['item']['offsetSize'],_0x525f77[_0x343ffc]['nextPosition']=_0x5c763f['createPositionFromPath'](_0x5342b7,_0xe59c44));for(let _0x5e2f1e=0x0;_0x5e2f1e<_0x525f77['length'];_0x5e2f1e++){const _0x36fd3a=_0x525f77[_0x5e2f1e]['previousPosition'],_0x165a48=_0x525f77[_0x5e2f1e]['nextPosition'];for(const _0x355010 of _0x525f77[_0x5e2f1e]['markersStart'])_0x4c0328['set'](_0x355010,{'start':_0x36fd3a,'end':null});_0x43bcd0('isRemoveSuggestion',_0x5e2f1e,_0x36fd3a,_0x165a48),_0x43bcd0('isAddSuggestion',_0x5e2f1e,_0x36fd3a,_0x165a48),_0x43bcd0('isRemoved',_0x5e2f1e,_0x36fd3a,_0x165a48),_0x43bcd0('isAdded',_0x5e2f1e,_0x36fd3a,_0x165a48);for(const _0x4cc2cd of _0x525f77[_0x5e2f1e]['markersEnd']){const _0xb34c11=_0x4c0328['get'](_0x4cc2cd);_0xb34c11?_0xb34c11['end']=_0x165a48:_0x4c0328['set'](_0x4cc2cd,{'start':_0x165a48,'end':_0x165a48});}}for(const [_0x3216dd,_0x2409d7]of _0x4c0328){const _0x4f8b76=this['editor']['model']['createRange'](_0x2409d7['start'],_0x2409d7['end']);_0x5342b7['markers']['set'](_0x3216dd,_0x4f8b76);}return _0x4b8d56['sort']((_0x2e307f,_0x440614)=>{const _0x5b7f8e=_0x5342b7['markers']['get']('revision:'+_0x2e307f['id']),_0x30ad51=_0x5342b7['markers']['get']('revision:'+_0x440614['id']);return _0x5b7f8e['start']['isBefore'](_0x30ad51['start'])?-0x1:_0x5b7f8e['start']['isAfter'](_0x30ad51['start'])?0x1:_0x5b7f8e['end']['isBefore'](_0x30ad51['end'])?-0x1:_0x5b7f8e['end']['isAfter'](_0x30ad51['end'])?0x1:'add'===_0x2e307f['type']?-0x1:0x1;}),{'root':_0x5342b7,'changes':_0x4b8d56};function _0x43bcd0(_0x4409d1,_0x1da8d8,_0x3b1035,_0x4e04d5){const _0xba9e75=!!_0x525f77[_0x1da8d8][_0x4409d1],_0x2a5d2b=_0xba9e75?_0x525f77[_0x1da8d8][_0x4409d1]['userId']:null,_0x12d646=_0x1da8d8===_0x525f77['length']-0x1,_0x288e35=_0x1cd8a0[_0x4409d1][0x0],_0x358557=_0x4c7e8e['isObject'](_0x525f77[_0x1da8d8]['item']);!_0x318ff6[_0x4409d1]&&_0xba9e75?_0x318ff6[_0x4409d1]={'start':_0x3b1035,'tapeItem':_0x525f77[_0x1da8d8],'userId':_0x2a5d2b,'type':_0x4409d1}:_0x318ff6[_0x4409d1]&&!_0xba9e75?(_0x318ff6[_0x4409d1]['end']=_0x3b1035,_0xc9541(_0x318ff6[_0x4409d1]),_0x318ff6[_0x4409d1]=null):_0x318ff6[_0x4409d1]&&_0xba9e75&&_0x318ff6[_0x4409d1]['userId']!==_0x2a5d2b&&(_0x318ff6[_0x4409d1]['end']=_0x3b1035,_0x288e35&&_0x288e35['userId']===_0x318ff6[_0x4409d1]['userId']||_0xc9541(_0x318ff6[_0x4409d1]),_0x318ff6[_0x4409d1]={'start':_0x3b1035,'tapeItem':_0x525f77[_0x1da8d8],'userId':_0x2a5d2b,'type':_0x4409d1}),_0x318ff6[_0x4409d1]&&_0x358557&&('elementStart'!==_0x525f77[_0x1da8d8]['type']||_0x288e35&&_0x288e35['userId']===_0x2a5d2b||_0x1cd8a0[_0x4409d1]['unshift']({'userId':_0x2a5d2b,'object':_0x525f77[_0x1da8d8]['item'],'change':_0x318ff6[_0x4409d1]}),'elementEnd'===_0x525f77[_0x1da8d8]['type']&&_0x288e35&&_0x288e35['object']===_0x525f77[_0x1da8d8]['item']&&(_0x1cd8a0[_0x4409d1]['shift'](),_0x318ff6[_0x4409d1]=_0x288e35['change'])),_0x318ff6[_0x4409d1]&&_0x12d646&&(_0x318ff6[_0x4409d1]['end']=_0x4e04d5,_0xc9541(_0x318ff6[_0x4409d1]),_0x318ff6[_0x4409d1]=null);}function _0xc9541({start:_0x4e43d7,end:_0x3c6b76,tapeItem:_0x59d371,userId:_0x554cb2,type:_0x46fe86}){const _0x1585a4=_0x59d371['item'],_0x1a067e=_0x5c763f['schema']['isBlock'](_0x1585a4)&&!_0x5c763f['schema']['isLimit'](_0x1585a4),_0x42c434=_0x4e43d7['nodeAfter']==_0x3c6b76['parent']&&_0x3c6b76['isAtStart'];if(_0x1a067e&&_0x42c434)return;const _0x119b4d=_0x5c763f['createRange'](_0x4e43d7,_0x3c6b76),_0x8bc4b5=_0x2bf039['get'](_0x554cb2),_0x16abd1=new G({'author':_0x8bc4b5,'type':'isAdded'==_0x46fe86||'isAddSuggestion'==_0x46fe86?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x46fe86||'isRemoveSuggestion'==_0x46fe86},'createdAt':new Date(),'rootName':_0x5f22ee});_0x4b8d56['push'](_0x16abd1),_0x5342b7['markers']['set']('revision:'+_0x16abd1['id'],_0x119b4d);}function _0x1d5adb(_0x5c2a6b,_0x36c403){const _0x2d7d4c=_0x5c2a6b['getAttributes'](),_0x3d395e=_0x36c403['getAttributes']();for(const _0x14c726 of _0x2d7d4c){if(_0x14c726[0x1]!==_0x36c403['getAttribute'](_0x14c726[0x0]))return!0x1;_0x3d395e['next']();}return _0x3d395e['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0xdef617=>{const _0x46b689=_0xdef617['markerName']['split'](':')[0x1],_0x25e932=this['_getChangeFromId'](_0x46b689);if(!_0x25e932)return null;const _0x20eeb7='add'==_0x25e932['type']?'insertion':'deletion',_0x3a6b69=['ck-suggestion-marker','ck-suggestion-marker-'+_0x20eeb7];return _0x25e932['data']['isSuggestion']&&_0x3a6b69['push']('ck-suggestion-marker-'+_0x20eeb7+'-new'),this['activeChange']==_0x25e932&&_0x3a6b69['push']('ck-suggestion-marker--active'),{'classes':_0x3a6b69,'attributes':{'data-change-id':_0x46b689}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x54b05c=>{_0x54b05c['on']('element:pre',(_0x3a944a,_0x40f318,_0x252c97)=>{const _0x152867=_0x40f318['viewItem']['getChild'](0x0);if(!_0x152867||!_0x152867['is']('element','code'))return;if(!_0x252c97['consumable']['consume'](_0x152867,{'attributes':['vid_start','vid_end']}))return;const _0x51bc44=_0x40f318['modelRange']['start']['nodeAfter'];_0x252c97['writer']['setAttribute']('vid_start',_0x152867['getAttribute']('vid_start'),_0x51bc44),_0x252c97['writer']['setAttribute']('vid_end',_0x152867['getAttribute']('vid_end'),_0x51bc44);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x453fd7=>{_0x453fd7['on']('element',(_0x1fbf08,_0x52a77f,_0x7fedd8)=>{if(!_0x7fedd8['consumable']['consume'](_0x52a77f['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x52a77f['modelRange']['isCollapsed'])return;const _0x22664b=_0x52a77f['modelRange']['start']['nodeAfter'];_0x22664b['hasAttribute']('vid_start')||_0x22664b['hasAttribute']('vid')||(_0x7fedd8['writer']['setAttribute']('vid_start',_0x52a77f['viewItem']['getAttribute']('vid_start'),_0x22664b),_0x7fedd8['writer']['setAttribute']('vid_end',_0x52a77f['viewItem']['getAttribute']('vid_end'),_0x22664b));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x35725e=>_0x35725e['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x2a5855,[,_0x271993])=>{['vid_start','vid_end','vid']['includes'](_0x271993)&&(_0x2a5855['return']=!0x0,_0x2a5855['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x92930f=>{_0x92930f['on']('attribute:vid',(_0x3a3d92,_0x4e5600,_0x32e59d)=>{if('\x20'!=_0x4e5600['item']['data']||_0x4e5600['item']['parent']['maxOffset']>0x1)return;if(!_0x32e59d['consumable']['consume'](_0x4e5600['item'],_0x3a3d92['name']))return;const _0x46e991=_0x32e59d['writer'],_0x95f299=_0x32e59d['mapper']['toViewRange'](_0x4e5600['range']);_0x46e991['wrap'](_0x95f299,_0x46e991['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x2fab1e){const _0x2fcd50=_0x2fab1e['plugins']['get']('RevisionViewer');return(_0x50c7e2,_0x489959,_0x5f3d56)=>{const _0x25f1db=_0x489959['markerName']['split'](':')[0x1],_0x50cd72=_0x2fcd50['_getChangeFromId'](_0x25f1db);if(!_0x50cd72)return null;const _0x253acd='add'==_0x50cd72['type']?'split':'merge';if(!_0x5f3d56['consumable']['test'](_0x489959['markerRange'],_0x50c7e2['name']))return;const _0x27a31a=_0x489959['markerRange']['getWalker'](),_0x3686c9=_0x489959['markerRange']['start'],_0x288a80=_0x2fab1e['model']['schema'];let _0x4e8793=null,_0x7ecd79=null,_0x1087e9=!0x1,_0x552951=!0x1;for(const _0x444ca1 of _0x27a31a){const _0x33ecec=_0x444ca1['item'];_0x1087e9=_0x1087e9||_0x288a80['isContent'](_0x33ecec);const _0x4b9c8b=_0x5f3d56['mapper']['toViewElement'](_0x33ecec);if(_0x4b9c8b&&_0x4b9c8b['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x444ca1['type']&&(_0x288a80['isBlock'](_0x33ecec)&&!_0x288a80['isLimit'](_0x33ecec)&&(_0x33ecec['nextSibling']||_0x3686c9['isAtEnd']?_0x4e8793&&_0x4e8793['parent']==_0x33ecec||(_0x4e8793=_0x33ecec,_0x2a055b(_0x444ca1['previousPosition']),_0x552951=!0x0):_0x7ecd79=_0x7ecd79||_0x444ca1['previousPosition']));}function _0x2a055b(_0x419b98){const _0x54b8e8=_0x5f3d56['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x253acd}),_0x4a7684=_0x5f3d56['mapper']['toViewPosition'](_0x419b98);_0x50cd72['data']['isSuggestion']&&_0x5f3d56['writer']['addClass']('ck-suggestion-marker-'+_0x253acd+'-new',_0x54b8e8),_0x2fcd50['activeChange']==_0x50cd72&&_0x5f3d56['writer']['addClass']('ck-suggestion-marker--active',_0x54b8e8),_0x5f3d56['writer']['insert'](_0x4a7684,_0x54b8e8),_0x5f3d56['mapper']['bindElementToMarker'](_0x54b8e8,_0x489959['markerName']);}_0x1087e9||_0x552951||!_0x7ecd79||_0x2a055b(_0x7ecd79);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x2c4b22,_0x23e632,_0x21f64b)=>{const _0x928655=_0x21f64b['mapper']['markerNameToElements'](_0x23e632['markerName']);if(_0x928655){for(const _0x21d634 of _0x928655)(_0x21d634['hasClass']('ck-suggestion-marker-split')||_0x21d634['hasClass']('ck-suggestion-marker-merge'))&&(_0x21f64b['mapper']['unbindElementFromMarkerName'](_0x21d634,_0x23e632['markerName']),_0x21f64b['writer']['remove'](_0x21d634));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x380255,_0x21822a,_0xd84035)=>{const _0xe176d0=_0x21822a['markerName']['split'](':')[0x1],_0x3859e4=this['_getChangeFromId'](_0xe176d0);if(!_0x3859e4)return null;const _0x2091b6='add'==_0x3859e4['type']?'split':'merge';if(_0xd84035['consumable']['test'](_0x21822a['markerRange'],_0x380255['name']))for(const _0x2b5417 of _0x21822a['markerRange']['getItems']()){if(!_0x2b5417['is']('element','softBreak'))continue;const _0x92170c=_0xd84035['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x2091b6}),_0x1d47f4=_0xd84035['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x2b5417));_0x3859e4['data']['isSuggestion']&&_0xd84035['writer']['addClass']('ck-suggestion-marker-'+_0x2091b6+'-new',_0x92170c),this['activeChange']==_0x3859e4&&_0xd84035['writer']['addClass']('ck-suggestion-marker--active',_0x92170c),_0xd84035['writer']['insert'](_0x1d47f4,_0x92170c),_0xd84035['mapper']['bindElementToMarker'](_0x92170c,_0x21822a['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x3da15d=>{for(const _0x277c11 of this['editor']['model']['document']['getRootNames']()){const _0x297b44=this['editor']['model']['document']['getRoot'](_0x277c11),_0x526ee4=this['editor']['editing']['view']['document']['getRoot'](_0x277c11);if(_0x526ee4){const _0x6329ca=_0x297b44['getAttribute']('revisionHistoryAttachChange');if(_0x3da15d['removeAttribute']('data-change-id',_0x526ee4),_0x3da15d['removeClass']('ck-revision-history-root-add',_0x526ee4),_0x3da15d['removeClass']('ck-revision-history-root-remove',_0x526ee4),_0x3da15d['removeClass']('ck-revision-history-root--active',_0x526ee4),_0x6329ca){const _0x1e436c=this['_getChangeFromId'](_0x6329ca);if(!_0x1e436c)return null;_0x3da15d['setAttribute']('data-change-id',_0x6329ca,_0x526ee4),_0x3da15d['addClass']('ck-revision-history-root-'+_0x1e436c['type'],_0x526ee4),this['activeChange']==_0x1e436c&&_0x3da15d['addClass']('ck-revision-history-root--active',_0x526ee4);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x2511a3=>'revision-comment:'+_0x2511a3,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x45cf84=>'revision-suggestion:'+_0x45cf84,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x429ac1=>({'name':'suggestion:'+_0x429ac1,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x3f145b=>{const _0xbe0fb3=_0x3f145b['markerName']['split'](':')[0x1];return'insertion'!=_0xbe0fb3&&'deletion'!=_0xbe0fb3?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0xbe0fb3]};}}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:deletion',Q(this['editor'],'merge'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:insertion',Q(this['editor'],'split'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision-suggestion',(_0x2d5bbc,_0x5a4113,_0x47083a)=>{const _0x30a5ef=_0x47083a['mapper']['markerNameToElements'](_0x5a4113['markerName']);if(_0x30a5ef){for(const _0x4b37bb of _0x30a5ef)_0x4b37bb['is']('uiElement')&&(_0x47083a['mapper']['unbindElementFromMarkerName'](_0x4b37bb,_0x5a4113['markerName']),_0x47083a['writer']['remove'](_0x4b37bb));}},{'priority':'high'});}['_getChangeFromId'](_0x217caf){return this['_changeIdToChange']['get'](_0x217caf);}['_getViewForChange'](_0x344b52){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new z(this['editor']['locale'],_0x344b52),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x287f13,_0xc5fa36,_0x1c7ec3,_0x20919b)=>{_0x20919b&&this['_balloon']['remove'](_0x20919b),_0x1c7ec3&&(this['_balloon']['add']({'view':_0x1c7ec3,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x470ba9=this['editor']['editing'],_0x547484=this['_getChangeFromId'](_0x1c7ec3['changeId']);let _0x1c7c01;if(_0x547484['data']['isOnRoot']){const _0x1adfd7=_0x470ba9['view']['getDomRoot'](_0x547484['rootName']);_0x1c7c01=Array['from'](_0x1adfd7['getClientRects']());}else{const _0x56fa51=this['editor']['model']['markers']['get']('revision:'+_0x1c7ec3['changeId']);_0x1c7c01=Array['from'](_0x470ba9['mapper']['markerNameToElements'](_0x56fa51['name']))['map'](_0x490c90=>_0x470ba9['view']['domConverter']['mapViewToDom'](_0x490c90))['map'](_0x1681eb=>Array['from'](_0x1681eb['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x1c7c01[0x0];return _0x1c7c01['find'](_0x261fd4=>_0x261fd4['top']-0x3<=this['_activeViewTarget']['y']&&_0x261fd4['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x261fd4['left']-0x3<=this['_activeViewTarget']['x']&&_0x261fd4['right']+0x3>=this['_activeViewTarget']['x'])||_0x1c7c01[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x341443,_0x231d46,_0x5d4f88,_0x165f07)=>{this['activeView']=_0x5d4f88?this['_getViewForChange'](_0x5d4f88):null,this['editor']['model']['change'](()=>{const _0x2a5938=this['editor']['editing'];_0x165f07&&(_0x165f07['data']['isOnRoot']?_0x2a5938['view']['change'](_0xee3425=>{_0xee3425['removeClass']('ck-revision-history-root--active',_0x2a5938['view']['document']['getRoot'](_0x165f07['rootName']));}):_0x2a5938['reconvertMarker']('revision:'+_0x165f07['id'])),_0x5d4f88&&(_0x5d4f88['data']['isOnRoot']?_0x2a5938['view']['change'](_0x1fedc6=>{_0x1fedc6['addClass']('ck-revision-history-root--active',_0x2a5938['view']['document']['getRoot'](_0x5d4f88['rootName']));}):_0x2a5938['reconvertMarker']('revision:'+_0x5d4f88['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x1bb0d2,_0x4f095a)=>{if(this['activeChange'])return;const _0xcab9b7=this['_findChangeIdFromDomTarget'](_0x4f095a['target']),_0x40f79e=this['_changeIdToChange']['get'](_0xcab9b7);_0x40f79e?(this['_activeViewTarget']={'x':_0x4f095a['domEvent']['x'],'y':_0x4f095a['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x40f79e)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x372ec6,_0x1f9281)=>{const _0x38c985=this['_findChangeIdFromDomTarget'](_0x1f9281['target']),_0x5d0e3e=this['_changeIdToChange']['get'](_0x38c985);_0x5d0e3e?(this['_activeViewTarget']={'x':_0x1f9281['domEvent']['x'],'y':_0x1f9281['domEvent']['y']},_0x5d0e3e===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x5d0e3e):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x45835c){do{const _0x528d0e=_0x45835c['getAttribute']('data-change-id');if(_0x528d0e)return _0x528d0e;_0x45835c=_0x45835c['parent'];}while(_0x45835c);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x4a3b69=>{for(const _0x2a05f3 of this['editor']['model']['markers'])_0x4a3b69['removeMarker'](_0x2a05f3);});}}function Q(_0x35e895,_0xf7fdd5){return(_0x4f8eb7,_0x3cb5b8,_0x5505c6)=>{if(!_0x5505c6['consumable']['test'](_0x3cb5b8['markerRange'],_0x4f8eb7['name']))return;const _0x1afae9=_0x3cb5b8['markerRange']['getWalker'](),_0x409651=_0x3cb5b8['markerRange']['start'],_0x17b206=_0x35e895['model']['schema'];let _0x5aded3=null,_0x100a47=null,_0x1e41ea=!0x1,_0x47d93e=!0x1;for(const _0x12dc65 of _0x1afae9){const _0x3ae4b5=_0x12dc65['item'];_0x1e41ea=_0x1e41ea||_0x17b206['isContent'](_0x3ae4b5);const _0x2f7d74=_0x5505c6['mapper']['toViewElement'](_0x3ae4b5);if(_0x2f7d74&&_0x2f7d74['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x12dc65['type']&&(_0x17b206['isBlock'](_0x3ae4b5)&&!_0x17b206['isLimit'](_0x3ae4b5)&&(_0x3ae4b5['nextSibling']||_0x409651['isAtEnd']?_0x5aded3&&_0x5aded3['parent']==_0x3ae4b5||(_0x5aded3=_0x3ae4b5,_0x21e720(_0x12dc65['previousPosition']),_0x47d93e=!0x0):_0x100a47=_0x100a47||_0x12dc65['previousPosition']));}function _0x21e720(_0x582838){const _0xbf9a0d=_0x5505c6['mapper']['toViewPosition'](_0x582838),_0x52ecbc=_0x5505c6['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0xf7fdd5});_0x5505c6['writer']['insert'](_0xbf9a0d,_0x52ecbc),_0x5505c6['mapper']['bindElementToMarker'](_0x52ecbc,_0x3cb5b8['markerName']);}_0x1e41ea||_0x47d93e||!_0x100a47||_0x21e720(_0x100a47);};}class ut extends _0x3c48a2{constructor(_0x45346b){super(_0x45346b);const _0x3dca9a=_0x45346b['plugins']['get'](l);this['affectsData']=!0x1,this['listenTo'](_0x3dca9a,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x3dca9a,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x2705a8=this['editor'],_0x45a537=_0x2705a8['plugins']['get'](l),_0x557f70=_0x45a537['isReady']?_0x45a537['diff']['newRevisionId']:null;_0x2705a8['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x557f70);}['refresh'](){const {isReady:_0x3d2898,isEnabled:_0x5263b1,repository:_0x1673a4,diff:_0x28c7e1}=this['editor']['plugins']['get'](l),_0x428db6=_0x28c7e1&&_0x1673a4['getLaterVisibleRevision'](_0x28c7e1['newRevisionId']);this['isEnabled']=_0x3d2898&&_0x5263b1&&Boolean(_0x428db6);}}class lt extends _0x3c48a2{['_step'];constructor(_0x59935d,{direction:_0x50f5b2}){super(_0x59935d);const _0x2b87ee=_0x59935d['plugins']['get'](l);this['affectsData']=!0x1,this['_step']='forward'===_0x50f5b2?0x1:-0x1,this['listenTo'](_0x2b87ee,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x2b87ee,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x2b87ee,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x2a170c=this['editor'],_0xe47bbf=_0x2a170c['plugins']['get'](l),{isNavigationMode:_0x21c786,currentChangeNumber:_0x37c0b8}=_0xe47bbf;let _0x1b4243;if(_0xe47bbf['activeChange']=_0x21c786?_0xe47bbf['diff']['changes']['get'](_0x37c0b8+this['_step']):_0xe47bbf['diff']['changes']['first'],_0xe47bbf['activeChange']['data']['isOnRoot'])_0x1b4243=_0x2a170c['editing']['view']['getDomRoot'](_0xe47bbf['activeChange']['rootName']);else{const _0x1fdfb3=_0x2a170c['model']['markers']['get']('revision:'+_0xe47bbf['activeChange']['id']);_0x1b4243=_0x41a099(_0x2a170c['editing'],_0x1fdfb3);}_0x13bd49({'target':_0x1b4243,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x1390bc,currentChangeNumber:_0x5a623f,numberOfChanges:_0x1c5796,isReady:_0x343026,isEnabled:_0x3bb034}=this['editor']['plugins']['get'](l);this['isEnabled']=!!(_0x3bb034&&_0x343026&&_0x1c5796)&&(!_0x1390bc||(0x1===this['_step']?_0x5a623f<_0x1c5796-0x1:_0x5a623f>0x0));}}class Ri extends _0x3269ad{constructor(_0x3c282e){super(_0x3c282e);const _0x4ce3e0=this['bindTemplate'],_0x2d48ab=new _0x4bd511(_0x3c282e),_0x4d3bbf=new _0x4bd511(_0x3c282e);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',(_0x5eba39,_0xc8dbad)=>_0x5eba39&&_0xc8dbad>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0xa79642,_0x36c21f,_0x5b8e38,_0x594cd7)=>{if(!_0xa79642)return R(_0x3c282e,'Loading...');if(!_0x5b8e38)return R(_0x3c282e,'No\x20changes');const _0x22aa35=R(_0x3c282e,'NUMBER_OF_CHANGES',_0x5b8e38);return _0x594cd7?R(_0x3c282e,'X_OF_Y_CHANGES',[_0x36c21f+0x1,_0x5b8e38]):_0x22aa35;}),_0x2d48ab['set']({'label':R(_0x3c282e,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x3cd2e9}),_0x4d3bbf['set']({'label':R(_0x3c282e,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x570090}),_0x2d48ab['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x4d3bbf['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x2d48ab['on']('execute',()=>this['fire']('execute','backward')),_0x4d3bbf['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',_0x4ce3e0['if']('_isStatusLabelVisible','ck-hidden',_0x51d368=>!_0x51d368)]},'children':[{'text':_0x4ce3e0['to']('isNavigationMode',_0x14e10d=>_0x14e10d?R(_0x3c282e,'EDIT_X_OF_Y_REVISIONS')+':\x20':R(_0x3c282e,'Total')+':\x20')}]},{'text':_0x4ce3e0['to']('_statusText')}]},new _0x5e45f2(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x2d48ab,_0x4d3bbf]}]});}}const ge='ck-editor__editable__loading-overlay';class ji extends _0x1973ac{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x21772b=this['editor']['editing']['view'];_0x21772b['change'](_0x39e238=>{for(const _0x1a9a38 of _0x21772b['document']['roots'])_0x39e238['addClass'](ge,_0x1a9a38);});}['hide'](){const _0xd1f21d=this['editor']['editing']['view'];_0xd1f21d['change'](_0x404bbf=>{for(const _0x397e64 of _0xd1f21d['document']['roots'])_0x404bbf['removeClass'](ge,_0x397e64);});}}class u extends _0x1973ac{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l,ji];}['init'](){const _0x3d6769=this['editor'],_0x16dc89=_0x3d6769['plugins']['get'](l),_0x15e952=_0x3d6769['plugins']['get'](ji);_0x3d6769['ui']['componentFactory']['add']('exitToEditing',_0x302b71=>{const _0x26eb90=new _0x4bd511(_0x302b71);return _0x26eb90['set']({'label':R(_0x302b71,'Back\x20to\x20editing'),'icon':_0x2b3260,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x26eb90,'execute',()=>{_0x3d6769['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x26eb90;}),_0x3d6769['ui']['componentFactory']['add']('restoreRevision',_0x5d1cf1=>{const _0x1bfe7c=new _0x4bd511(_0x5d1cf1);return _0x1bfe7c['set']({'label':R(_0x5d1cf1,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x1bfe7c['bind']('isEnabled')['to'](_0x3d6769['commands']['get']('restoreRevision')),this['listenTo'](_0x1bfe7c,'execute',()=>_0x3d6769['execute']('restoreRevision')),_0x1bfe7c;}),_0x3d6769['ui']['componentFactory']['add']('changesNavigation',_0x37f49a=>{const _0x5141eb=new Ri(_0x37f49a),_0x11c9dc=_0x3d6769['commands']['get']('showPreviousChange'),_0x627cca=_0x3d6769['commands']['get']('showNextChange');return _0x5141eb['bind']('isBackwardNavigationEnabled')['to'](_0x11c9dc,'isEnabled'),_0x5141eb['bind']('isForwardNavigationEnabled')['to'](_0x627cca,'isEnabled'),_0x5141eb['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x16dc89),this['listenTo'](_0x5141eb,'execute',(_0x1f718f,_0x1b33fc)=>{_0x3d6769['execute']('forward'===_0x1b33fc?'showNextChange':'showPreviousChange');}),_0x5141eb;}),_0x15e952['show'](),_0x16dc89['on']('change:isReady',(_0x309a08,_0x425b7f,_0x457fb7)=>{_0x457fb7?_0x15e952['hide']():_0x15e952['show']();});}}class hi extends et{['_resizeObserver']=null;constructor(_0x3d4b65,_0x123f58){super(_0x3d4b65,_0x123f58);const _0xf7c6ed=this['bindTemplate'];this['set']({'label':R(_0x3d4b65,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=R(_0x3d4b65,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0xf7c6ed['to']('_tooltipString'),'data-cke-tooltip-position':'s','data-cke-tooltip-class':'ck-tooltip_multi-line'}});}['render'](){super['render'](),this['_resizeObserver']=new ot(this['fieldView']['element'],()=>this['_updateTooltipText']()),this['listenTo'](this['fieldView'],'input',()=>this['_updateTooltipText']());}['destroy'](){super['destroy'](),this['_resizeObserver']&&this['_resizeObserver']['destroy']();}['_updateTooltipText'](){const _0x2166d3=this['fieldView']['element'];this['_tooltipString']=_0x2166d3['scrollWidth']>_0x2166d3['clientWidth']&&_0x2166d3['value']||'';}}class ni extends _0x3269ad{constructor(_0x1b3359,_0x5d022a,_0x123e51){super(_0x1b3359);const _0x575665=new _0x5f034c();_0x575665['set']({'content':_0x2a0aaa,'viewBox':'0\x200\x2011\x2010'});const _0x23f4cf=['ck','ck-revision-history-sidebar__revision-author'];_0x123e51&&_0x23f4cf['push']('ck-revision-history-sidebar__revision-author_creator');const _0x43a0ab=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':R(_0x1b3359,_0x123e51?'Revision\x20creator':'Revision\x20author')},'children':[_0x575665,_0x5d022a['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x23f4cf},'children':_0x43a0ab});}}function ci(_0x30398c,_0x3187ec){const _0x2a1774=_0x30398c['bindTemplate'],_0x410a02=_0x30398c['locale'],_0x13a0c9=_0x35ed0a(_0x410a02);_0x13a0c9['panelPosition']='sw';const _0xca68b6=function(_0x31074a,_0x9117c3){const _0x177811=function(_0x538847,_0x102522){const _0x1d1354=_0x538847['locale'],_0x5011f6={'Compare\x20against\x20selected':R(_0x1d1354,'Compare\x20against\x20selected'),'Name\x20this\x20revision':R(_0x1d1354,'Name\x20this\x20revision'),'Restore\x20this\x20revision':R(_0x1d1354,'Restore\x20this\x20revision')};return _0x102522['map'](_0x33a451=>{const _0x55548c=_0x5011f6[_0x33a451['name']];return _0x55548c&&_0x55548c!==_0x33a451['name']&&(_0x33a451['name']=_0x55548c),_0x33a451;});}(_0x31074a,_0x9117c3),_0x5d5cb7=new _0x28f4f5();for(const _0x2cc007 of _0x177811){const _0x23c732={'type':'button','model':new to({'label':_0x2cc007['name'],'class':_0x2cc007['class'],'withText':!0x0,'role':'menuitem','_action':_0x2cc007['action']})};_0x23c732['model']['bind']('isEnabled')['to'](_0x31074a,'isActionsDropdownOpen',_0x12dec0=>'function'!=typeof _0x2cc007['isEnabled']||(!_0x12dec0||_0x2cc007['isEnabled'](_0x31074a))),_0x5d5cb7['add'](_0x23c732);}return _0x5d5cb7;}(_0x30398c,_0x3187ec);return _0x30398c['bind']('isActionsDropdownOpen')['to'](_0x13a0c9,'isOpen'),_0x13a0c9['buttonView']['set']({'label':R(_0x410a02,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0xeddefb}),_0x13a0c9['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x2a1774['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x2a1774['to'](_0x3ebdd6=>_0x3ebdd6['stopPropagation']())}}),_0x13a0c9['on']('execute',_0x12b78a=>{_0x30398c['isReady']&&'function'==typeof _0x12b78a['source']['_action']&&_0x12b78a['source']['_action'](_0x30398c);}),_0x3e203f(_0x13a0c9,_0xca68b6,{'role':'menu'}),_0x13a0c9['listenTo'](_0x30398c,'change:isActionsDropdownOpen',(_0x1c1813,_0x325148,_0x5cfd9d)=>{if(_0x5cfd9d)for(const _0x11de66 of _0x13a0c9['listView']['items']){const _0x4cd321=_0x11de66['children']['first'],_0x17abd9=_0x3187ec['find'](_0x5f4f2f=>_0x5f4f2f['action']===_0x4cd321['_action'])['isVisible'];_0x11de66['isVisible']=void 0x0===_0x17abd9||_0x17abd9(_0x30398c);}}),_0x13a0c9;}class vi extends/* #__PURE__ -- @preserve */
|
|
27
|
+
_0x4b52b0(_0x3269ad){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x31304a,_0x24f254,_0x2cd505,_0x2aeda4){super(_0x31304a);const _0x27b0da=this['bindTemplate'],_0x11a020=function(_0x4556e5,_0x8add4a){const _0x47b829=Array['from'](_0x8add4a['authors'])['filter'](_0x439960=>_0x439960!=_0x8add4a['creator']);return _0x8add4a['creator']&&_0x47b829['unshift'](_0x8add4a['creator']),_0x47b829['map'](_0x4a52af=>new ni(_0x4556e5,_0x4a52af,_0x4a52af==_0x8add4a['creator']));}(_0x31304a,_0x24f254);this['id']=_0x24f254['id'],this['_revision']=_0x24f254,this['_requireRevisionName']=_0x2aeda4,this['bind']('name','createdAt')['to'](_0x24f254),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x41dba2=>{return _0x8fe2b8=_0x31304a['uiLanguage'],(_0x4cff41=_0x41dba2)['toLocaleDateString'](_0x8fe2b8,{'month':'long','day':'numeric'})+',\x20'+_0x4cff41['toLocaleTimeString'](_0x8fe2b8,{'hour':'numeric','minute':'numeric'});var _0x8fe2b8,_0x4cff41;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new hi(_0x31304a,ti),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x108254=>_0x108254||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0xf462e9,_0x59e570)=>_0xf462e9&&_0x59e570),this['revisionActionsView']=_0x2cd505&&_0x2cd505['length']?ci(this,_0x2cd505):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x27b0da['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x27b0da['if']('isEnabled','ck-disabled',_0x230982=>!_0x230982),_0x27b0da['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x27b0da['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x27b0da['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':_0x27b0da['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':_0x11a020}]},this['revisionActionsView']],'on':{'click':_0x27b0da['to'](_0x5df02d=>{_0x5df02d['srcElement']['closest']('.ck-thread__remove-confirm')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x400ef3=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x400ef3,'change',()=>{this['_requireRevisionName']&&!_0x400ef3['value']||this['fire']('setName',{'id':this['id'],'name':_0x400ef3['value']}),_0x400ef3['value']||(_0x400ef3['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(_0x8213f2,_0x5d6065){const _0x533b60=_0x4cf0b9['fromJSDate'](_0x8213f2)['setLocale'](_0x5d6065),_0x22fb24=_0x4cf0b9['local'](),_0x31e17d=_0x22fb24['minus']({'days':0x1})['startOf']('day');let _0x44798b,_0x228a6d;return _0x533b60['hasSame'](_0x22fb24,'day')?(_0x44798b=_0x533b60['startOf']('day')['toJSDate'](),_0x228a6d=_0x533b60['toRelativeCalendar']()):_0x533b60['hasSame'](_0x31e17d,'day')?(_0x44798b=_0x31e17d['toJSDate'](),_0x228a6d=_0x533b60['toRelativeCalendar']()):_0x533b60['hasSame'](_0x22fb24,'week')?(_0x44798b=_0x533b60['startOf']('week')['toJSDate'](),_0x228a6d=_0x533b60['weekdayLong']||''):_0x533b60['hasSame'](_0x22fb24,'year')?(_0x44798b=_0x533b60['startOf']('month')['toJSDate'](),_0x228a6d=_0x533b60['monthLong']||''):(_0x44798b=_0x533b60['startOf']('year')['toJSDate'](),_0x228a6d=String(_0x533b60['year'])),{'startDate':_0x44798b,'localizedPeriodName':_0x228a6d};}class li extends _0x3269ad{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x5a2492,_0x503ec1,_0x689ab7,_0x5a4d7e){super(_0x5a2492);const _0x39aa75=mi(_0x503ec1,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x503ec1,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x689ab7,this['_requireRevisionName']=_0x5a4d7e,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':_0x39aa75}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x15d3b5){const _0x1e226d=new vi(this['locale'],_0x15d3b5,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x1e226d);}['removeRevision'](_0x33c735){const _0x56cb99=this['revisionViews']['find'](_0x9c1f62=>_0x9c1f62['id']===_0x33c735['id']);this['revisionViews']['remove'](_0x56cb99);}}class bi extends _0x3269ad{constructor(_0x3d215f){super(_0x3d215f);const _0xb1995e=new _0x5f034c();_0xb1995e['content']=_0x2d57fb,this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0xb1995e,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[R(_0x3d215f,'Revision\x20history')]}]});}}class di extends _0x3269ad{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0xab2087,_0x77b03a,_0x6ed4e3,_0x46ebdb){super(_0xab2087);const _0x2dcb6d=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x77b03a,this['_revisionActions']=_0x6ed4e3,this['_requireRevisionName']=_0x46ebdb,this['on']('select',(_0x5eb686,_0x482644)=>{this['fire']('revisionSelected',_0x482644);}),this['on']('setName',(_0x2ebbf8,_0x34aec9)=>{this['fire']('revisionSetName',_0x34aec9);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new bi(_0xab2087),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x2dcb6d['if']('isEnabled','ck-disabled',_0x257089=>!_0x257089)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x23681e of this['_revisions'])this['_addRevision'](_0x23681e);this['_revisions']['on']('add',(_0x1bb186,_0x24b8bd)=>{this['_addRevision'](_0x24b8bd);}),this['_revisions']['on']('remove',(_0x45b7f9,_0x1d68eb)=>{this['_removeRevision'](_0x1d68eb);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x232362=>_0x232362['revisionViews']['map'](_0x2a29d2=>_0x2a29d2))['flat']();}['selectRevision'](_0x36ba2e){for(const _0x44b063 of this['revisionViews'])_0x36ba2e&&_0x36ba2e['id']===_0x44b063['id']?_0x44b063['select']():_0x44b063['deselect']();}['highlightRevisions'](_0x581c21){for(const _0x128aea of this['revisionViews'])_0x581c21['some'](({id:_0x5a245e})=>_0x5a245e===_0x128aea['id'])?_0x128aea['highlight']():_0x128aea['unhighlight']();}['_addRevision'](_0x912c6c){const _0x17ea4b=mi(_0x912c6c['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x1496bb=this['timePeriodViews']['get'](0x0);_0x1496bb&&_0x1496bb['startDate']['getTime']()===_0x17ea4b['getTime']()||(_0x1496bb=new li(this['locale'],_0x17ea4b,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x1496bb)),_0x1496bb['addRevision'](_0x912c6c);}['_removeRevision'](_0x1556d0){const _0x37e737=mi(_0x1556d0['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x37e737)['removeRevision'](_0x1556d0);}['_getTimePeriodViewByStartDate'](_0x44640d){return this['timePeriodViews']['find'](_0x12921c=>_0x12921c['startDate']['getTime']()===_0x44640d['getTime']());}}class f extends _0x1973ac{['_revisionViewer'];['_revisionsRepository'];['_sidebarView'];static ['defaultRevisionActions']=/* #__PURE__ -- @preserve */
|
|
28
28
|
((()=>['compareAgainstSelected','restoreRevision','nameRevision'])());static ['availableRevisionActions']=/* #__PURE__ -- @preserve */
|
|
29
|
-
|
|
30
|
-
_0x558728(_0x5d8de5){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x5497ef,_0x380d67){super(_0x380d67),this['sourceElement']=_0x5497ef,this['model']['document']['createRoot']();const _0x4c50b3=new ii(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new Z(this,_0x4c50b3);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x535446,_0xf46ac5){const _0x4ed814=new this(_0x535446,_0xf46ac5);return await _0x4ed814['initPlugins'](),await _0x4ed814['ui']['init'](_0x535446),await _0x4ed814['data']['init'](_0x4ed814['config']['get']('initialData')||''),_0x4ed814['fire']('ready'),_0x4ed814;}}const d=['RevisionHistoryUI','RestrictedEditingMode'];class dt extends _0x25ad5f{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x4c5b88){function _0x5a7561(_0x5647e6){return _0x5647e6['map'](_0x1cb756=>String['fromCharCode'](_0x1cb756))['join']('');}super(_0x4c5b88),this['result']='end',_0x4c5b88[_0x5a7561([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x5a7561([0x76,0x69,0x65,0x77])][_0x5a7561([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x5a7561([0x61,0x75,0x74,0x6f]),_0x4c5b88[_0x5a7561([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x5a7561([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x5a7561([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x5a7561([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x5a7561([0x6f,0x6b])});}}class ft extends _0x25ad5f{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h,v];}constructor(_0x1a168f){if(super(_0x1a168f),!this['editor']['config']['get']('revisionHistory'))throw new _0x401f9c('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x10a21b=>this['_showRevisionViewer']({..._0x10a21b,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x324fd0=>this['_closeRevisionViewer'](_0x324fd0)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x480911=>this['_restoreRevision'](_0x480911)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x1a421a){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x1a421a;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x23d8e7){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x23d8e7);}['getRevision'](_0x1b28ff){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x1b28ff);}['getRevisions'](_0xe562d5){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0xe562d5||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x36712b=this['editor'],_0x257b6e=_0x1405c7(_0x36712b,d),_0x43c41c=_0x36712b['plugins']['get']('RevisionTracker'),_0x450a73=_0x36712b['plugins']['get']('Users')['users'];return _0x257b6e['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x257b6e['lazyRoots'],(_0x257b6e['plugins']['push'](dt,l,u,class extends _0x25ad5f{static get['requires'](){return[l,'Users'];}['init'](){const _0xf32819=this['editor']['plugins']['get']('Users');for(const _0x3cf945 of _0x450a73)_0x3cf945['isAnonymous']||_0xf32819['getUser'](_0x3cf945['id'])||_0xf32819['addUser'](_0x3cf945);const _0x4770ab=_0x43c41c['repository']['getRevisions']();let _0x410505=null;const _0x83e1fb=this['editor']['plugins']['get']('RevisionViewer');_0x83e1fb['adapter']=_0x43c41c['adapter'],_0x83e1fb['bind']('isEnabled')['to'](_0x43c41c),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x36712b,'isReadOnly',_0x5a88a1=>!_0x5a88a1);for(const _0x4f8dbe of _0x4770ab){const _0x3f2fca=null===_0x4f8dbe['creator'];if(_0x3f2fca&&_0x4f8dbe['toVersion']===_0x4f8dbe['fromVersion'])continue;const _0x3986b5=_0x4f8dbe['toJSON']();_0x83e1fb['addRevisionData'](_0x3986b5,(_0xb9c126,_0x44191b,_0x1c0596)=>{if(_0x3f2fca){if(_0x410505)_0x410505['_update'](_0xb9c126,_0x44191b);else{if(!_0x44191b){const _0x17d6e5=_0x1c0596['toJSON']();_0x17d6e5['id']=_0x5545a3(),_0x43c41c['saveRevision'](_0x17d6e5,_0x1c0596['toVersion'])['then'](_0x121c59=>{_0x410505=_0x121c59;});}}}else _0x4f8dbe['_update'](_0xb9c126,_0x44191b);});}}},f),_0x257b6e);}['_enhanceShowRevisionViewerCallback'](){const _0x58ab78=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x16d5c0=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x54bb6d=this['editor']['plugins']['get']('Autosave');await _0x54bb6d['save']();}else await _0x16d5c0['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x293907=this['editor']['plugins']['get']('Dialog');_0x293907['isOpen']&&_0x293907['hide']();}const _0x5db5b8=this['_getRevisionViewerEditorConfig']();return _0x58ab78(_0x5db5b8)['then'](_0x2f4293=>{return(this['_viewerEditor']=_0x2f4293,this['editor']['plugins']['has']('Annotations'))&&this['editor']['plugins']['get']('Annotations')['refreshVisibility'](),(this['editor']['plugins']['has']('DocumentOutline')&&(this['editor']['plugins']['get']('DocumentOutlineUI')['view']['element']['style']['display']='none'),_0x2f4293);})['catch'](_0x277e05=>(console['error'](_0x277e05),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x10721d=this['editor']['config']['get']('revisionHistory')['closeRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.closeRevisionViewerCallback',()=>(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('DocumentOutline')&&(this['editor']['plugins']['get']('DocumentOutlineUI')['view']['element']['style']['display']=''),this['_viewerEditor']['plugins']['get']('RevisionViewer')['_cleanUp'](),_0x10721d(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x1072f9=this['editor']['plugins']['get']('Annotations');_0x1072f9['refreshVisibility'](),_0x1072f9['refreshPositioning']();}})));}['_showRevisionViewer'](_0x522910){const _0x3ad288=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x13fbeb=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x435584=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return m['create'](_0x435584,_0x522910)['then'](_0x49bae6=>(_0x13fbeb['style']['display']='block',_0x3ad288['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x49bae6));}['_closeRevisionViewer'](_0x47f04b){const _0x2b33ce=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x2b33ce['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x47f04b['destroy']();}async['_restoreRevision'](_0x57c3d8){const _0x5b51b3=this['editor'],_0x3cfd13=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x1be844=_0x5b51b3['plugins']['get']('RevisionTracker'),_0x25dcba=_0x5b51b3['plugins']['get']('RevisionHistoryUtils'),_0x54f36e=_0x3cfd13['repository']['getRevision'](_0x57c3d8);let _0x2be81a,_0xa562e2,_0x10f5fd;try{await _0x25dcba['loadRevisionData'](_0x54f36e,this['adapter']),_0x2be81a=_0x25dcba['getRevisionDocumentData'](_0x54f36e),_0xa562e2=_0x25dcba['getRevisionRootsAttributes'](_0x54f36e);}catch(_0x3390f9){return void console['error'](_0x3390f9);}_0x5b51b3['model']['change'](_0x193643=>{for(const _0x5492c4 of Array['from'](_0x5b51b3['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x193643['removeMarker'](_0x5492c4);}),_0x3cfd13['isReady']=!0x1,_0x5b51b3['model']['enqueueChange'](_0x29d1ff=>{_0x29d1ff['setSelection'](null),_0x29d1ff['removeSelectionAttribute'](_0x5b51b3['model']['document']['selection']['getAttributeKeys']());const _0x532b65=Object['keys'](_0x2be81a);for(const _0x155e3b of _0x5b51b3['model']['document']['roots'])'$graveyard'!=_0x155e3b['rootName']&&_0x155e3b['isAttached']()&&!_0x532b65['includes'](_0x155e3b['rootName'])&&_0x29d1ff['detachRoot'](_0x155e3b);for(const _0x2bdb7f of _0x532b65){let _0x5cb125=_0x5b51b3['model']['document']['getRoot'](_0x2bdb7f);_0x5cb125&&_0x5cb125['isAttached']()||(_0x5cb125=_0x29d1ff['addRoot'](_0x2bdb7f));const _0x3f915d=_0xa562e2[_0x2bdb7f],_0x532f9e=Object['keys'](_0x3f915d),_0x4cfda3=_0x2be81a[_0x2bdb7f];for(const _0x5adab4 of _0x5cb125['getAttributeKeys']())_0x532f9e['includes'](_0x5adab4)||_0x29d1ff['removeAttribute'](_0x5adab4,_0x5cb125);for(const _0xe08b2e of _0x532f9e)_0x29d1ff['setAttribute'](_0xe08b2e,_0xa562e2[_0x2bdb7f][_0xe08b2e],_0x5cb125);_0x29d1ff['remove'](_0x29d1ff['createRangeIn'](_0x5cb125)),_0x29d1ff['insert'](_0x5b51b3['data']['parse'](_0x4cfda3,_0x5cb125),_0x5cb125,0x0);}});const _0x3abe5f=R(_0x5b51b3['locale'],'Restored');if(_0x54f36e['name'])_0x10f5fd=-0x1==_0x54f36e['name']['indexOf'](_0x3abe5f)?_0x3abe5f+':\x20'+_0x54f36e['name']:_0x54f36e['name'];else _0x10f5fd=_0x3abe5f+':\x20'+(_0x54f36e['createdAt']['toLocaleDateString'](_0x5b51b3['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x54f36e['createdAt']['toLocaleTimeString'](_0x5b51b3['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x1be844['saveRevision']({'name':_0x10f5fd}),_0x3cfd13['isReady']=!0x0,_0x5b51b3['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{ct as RestoreRevisionCommand,I as Revision,ft as RevisionHistory,v as RevisionHistoryUI,$ as RevisionHistoryUtils,h as RevisionTracker,l as RevisionViewer,m as RevisionViewerEditor,ji as RevisionViewerLoadingOverlay,u as RevisionViewerUI,S as RevisionsRepository,f as RevisionsSidebar,ut as ShowChangeCommand};
|
|
29
|
+
dt();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l];}constructor(_0x103607){super(_0x103607),this['_revisionViewer']=_0x103607['plugins']['get'](l),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x3f0ae4=this['_revisionsRepository']['_revisions'],_0x2a3b2a=this['_createRevisionActions'](),_0x496cf1=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new di(this['editor']['locale'],_0x3f0ae4,_0x2a3b2a,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',(_0x39547e,_0x1e8b2d)=>{_0x1e8b2d['revisionViews']['on']('add',(_0x1a1792,_0x2afd5f)=>{_0x2afd5f['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)),_0x496cf1['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0xa3d42f=this['_revisionsRepository']['getRevision'](0x0);if(_0xa3d42f){const _0x429c4b=this['_revisionsRepository']['getEarlierVisibleRevision'](_0xa3d42f['id']);this['_revisionViewer']['compare'](_0xa3d42f,_0x429c4b);}}['_handleRevisionSelected'](_0x4eaed5,_0xf15973){const _0x15701d=this['_revisionsRepository']['getRevision'](_0xf15973['id']),_0x1d292e=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x15701d['id']);this['_revisionViewer']['compare'](_0x15701d,_0x1d292e);}['_handleRevisionSetName'](_0x327461,_0x13a37c){this['_revisionsRepository']['getRevision'](_0x13a37c['id'])['setName'](_0x13a37c['name']);}['_handleDiffChange'](_0xb1931f,_0x3b3f77,_0x19cac1){const _0x19dda2=this['_revisionsRepository']['getRevisionsInDiff'](_0x19cac1);_0x19dda2['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x19dda2),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x19dda2[0x0]));}['_createRevisionActions'](){const _0x3aa8bd=this['editor'],_0x465110=f['availableRevisionActions'],_0x142167=_0x3aa8bd['config']['get']('revisionHistory.revisionActions')||f['defaultRevisionActions'];if(_0x142167['length'])return _0x142167['map'](_0xb9d8f1=>{const _0x1825f7='string'==typeof _0xb9d8f1?Object['assign']({},_0x465110[_0xb9d8f1]):_0xb9d8f1;return _0x1825f7['action']=_0x1825f7['action']['bind'](this,_0x3aa8bd),_0x1825f7['isVisible']&&(_0x1825f7['isVisible']=_0x1825f7['isVisible']['bind'](this,_0x3aa8bd)),_0x1825f7;});}}function dt(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x427821},_0x57d4e6)=>{const _0x1a0204=_0x427821['get'](l),_0x264da9=_0x1a0204['repository'];let _0x38e039=_0x1a0204['diff']['newRevisionId'],_0x10dc10=_0x57d4e6['id'];_0x264da9['getIndex'](_0x38e039)>_0x264da9['getIndex'](_0x10dc10)&&([_0x38e039,_0x10dc10]=[_0x10dc10,_0x38e039]),_0x1a0204['compare'](_0x38e039,_0x10dc10);},'isVisible':({plugins:_0x5b21d9},_0x4e611c)=>{const _0x1f3f67=_0x5b21d9['get'](l);return!(_0x1f3f67['repository']['getRevisionsInDiff'](_0x1f3f67['diff'])['length']>0x2)&&!_0x4e611c['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x1a2f63,{id:_0x5cf7c2})=>{_0x1a2f63['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x5cf7c2);},'isVisible':({plugins:_0x5e38f6},_0x52e933)=>!!_0x5e38f6['get'](l)['repository']['getLaterVisibleRevision'](_0x52e933['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x3f6c28},{id:_0x489b2e,revisionNameView:_0x153736})=>{const _0x3b3867=_0x3f6c28['get'](l),_0x2648d3=_0x3b3867['repository']['getEarlierVisibleRevision'](_0x489b2e);_0x3b3867['compare'](_0x489b2e,_0x2648d3),_0x153736['focus'](),_0x153736['fieldView']['select']();}}};}class Z extends tt{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x59c322,_0xd84249){super(_0x59c322),this['_view']=_0xd84249,this['_toolbarConfig']=st(_0x59c322['config']['get']('toolbar')),this['_elementReplacer']=new it();}get['element'](){return this['view']['element'];}['init'](_0xa3d9c4){const _0x25574a=this['editor'],_0x325137=this['view'],_0x5ae106=_0x25574a['editing']['view'],_0x5dd4cc=_0x325137['editable'],_0x49e456=_0x5ae106['document']['getRoot']();_0x5dd4cc['name']=_0x49e456['rootName'],_0x325137['render']();const _0x1de79f=_0x5dd4cc['element'];this['setEditableElement'](_0x5dd4cc['name'],_0x1de79f),_0x325137['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x5ae106['attachDomRoot'](_0x1de79f),this['_elementReplacer']['replace'](_0xa3d9c4,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x2f9522=this['view'],_0x3a30aa=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x3a30aa['detachDomRoot'](_0x2f9522['editable']['name']),_0x2f9522['destroy']();}['_initToolbar'](){const _0x58007e=this['view'];_0x58007e['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x58007e['stickyPanel']['limiterElement']=_0x58007e['element'],_0x58007e['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x83216d})=>_0x83216d),_0x58007e['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x58007e['toolbar']);}}class ii extends _0x428f92{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x568844,_0x5149d0,_0x4e721e={}){super(_0x568844),this['stickyPanel']=new _0x128bac(_0x568844),this['toolbar']=new _0x30c81f(_0x568844,{'shouldGroupWhenFull':_0x4e721e['shouldToolbarGroupWhenFull']}),this['_editable']=new te(_0x568844,_0x5149d0);}['render'](){super['render'](),this['stickyPanel']['content']['add'](this['toolbar']),this['top']['add'](this['stickyPanel']),this['main']['add'](this['editable']);}}class m extends/* #__PURE__ -- @preserve */
|
|
30
|
+
_0x31b8b8(_0x4dfa8c){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x11a0e3,_0x4483cb){super(_0x4483cb),this['sourceElement']=_0x11a0e3,this['model']['document']['createRoot']();const _0x5e6417=new ii(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new Z(this,_0x5e6417);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x13d0c5,_0x4cb8bb){const _0x20bcb4=new this(_0x13d0c5,_0x4cb8bb);return await _0x20bcb4['initPlugins'](),await _0x20bcb4['ui']['init'](_0x13d0c5),await _0x20bcb4['data']['init'](_0x20bcb4['config']['get']('initialData')||''),_0x20bcb4['fire']('ready'),_0x20bcb4;}}const d=['RevisionHistoryUI','RestrictedEditingMode'];class ft extends _0x1973ac{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x11d240){function _0x1f1368(_0x2832b8){return _0x2832b8['map'](_0x2a6371=>String['fromCharCode'](_0x2a6371))['join']('');}super(_0x11d240),this['result']='end',_0x11d240[_0x1f1368([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x1f1368([0x76,0x69,0x65,0x77])][_0x1f1368([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x1f1368([0x61,0x75,0x74,0x6f]),_0x11d240[_0x1f1368([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x1f1368([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x1f1368([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x1f1368([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x1f1368([0x6f,0x6b])});}}class vt extends _0x1973ac{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h,v];}constructor(_0x41cd5b){if(super(_0x41cd5b),!this['editor']['config']['get']('revisionHistory'))throw new _0x22ea28('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x4665b9=>this['_showRevisionViewer']({..._0x4665b9,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x4ed6c9=>this['_closeRevisionViewer'](_0x4ed6c9)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x2c6e95=>this['_restoreRevision'](_0x2c6e95)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x2fb473){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x2fb473;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x3a064e){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x3a064e);}['getRevision'](_0x218e0f){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x218e0f);}['getRevisions'](_0x4f2bdc){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x4f2bdc||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x571eba=this['editor'],_0x3398e7=_0x2a2211(_0x571eba,d),_0x15d7ea=_0x571eba['plugins']['get']('RevisionTracker'),_0x4d4908=_0x571eba['plugins']['get']('Users')['users'];return _0x3398e7['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x3398e7['lazyRoots'],(_0x3398e7['plugins']['push'](ft,l,u,class extends _0x1973ac{static get['requires'](){return[l,'Users'];}['init'](){const _0x153825=this['editor']['plugins']['get']('Users');for(const _0x2f5da9 of _0x4d4908)_0x2f5da9['isAnonymous']||_0x153825['getUser'](_0x2f5da9['id'])||_0x153825['addUser'](_0x2f5da9);const _0x34f11d=_0x15d7ea['repository']['getRevisions']();let _0x554562=null;const _0x45c679=this['editor']['plugins']['get']('RevisionViewer');_0x45c679['adapter']=_0x15d7ea['adapter'],_0x45c679['bind']('isEnabled')['to'](_0x15d7ea),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x571eba,'isReadOnly',_0x17a289=>!_0x17a289);for(const _0x6e2e36 of _0x34f11d){const _0x293a10=null===_0x6e2e36['creator'];if(_0x293a10&&_0x6e2e36['toVersion']===_0x6e2e36['fromVersion'])continue;const _0x5f5784=_0x6e2e36['toJSON']();_0x45c679['addRevisionData'](_0x5f5784,(_0x480828,_0x4f26b2,_0x2d00d0)=>{if(_0x293a10){if(_0x554562)_0x554562['_update'](_0x480828,_0x4f26b2);else{if(!_0x4f26b2){const _0xfd6ff2=_0x2d00d0['toJSON']();_0xfd6ff2['id']=_0x173cdc(),_0x15d7ea['saveRevision'](_0xfd6ff2,_0x2d00d0['toVersion'])['then'](_0x1cf001=>{_0x554562=_0x1cf001;});}}}else _0x6e2e36['_update'](_0x480828,_0x4f26b2);});}}},f),_0x3398e7);}['_enhanceShowRevisionViewerCallback'](){const _0x1c8155=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x3fa701=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x52f035=this['editor']['plugins']['get']('Autosave');await _0x52f035['save']();}else await _0x3fa701['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x133dbf=this['editor']['plugins']['get']('Dialog');_0x133dbf['isOpen']&&_0x133dbf['hide']();}const _0x2a0996=this['_getRevisionViewerEditorConfig']();return _0x1c8155(_0x2a0996)['then'](_0x247456=>{return(this['_viewerEditor']=_0x247456,this['editor']['plugins']['has']('Annotations'))&&this['editor']['plugins']['get']('Annotations')['refreshVisibility'](),(this['editor']['plugins']['has']('DocumentOutline')&&(this['editor']['plugins']['get']('DocumentOutlineUI')['view']['element']['style']['display']='none'),_0x247456);})['catch'](_0x3aa011=>(console['error'](_0x3aa011),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x40848b=this['editor']['config']['get']('revisionHistory')['closeRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.closeRevisionViewerCallback',()=>(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('DocumentOutline')&&(this['editor']['plugins']['get']('DocumentOutlineUI')['view']['element']['style']['display']=''),this['_viewerEditor']['plugins']['get']('RevisionViewer')['_cleanUp'](),_0x40848b(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x12d7ee=this['editor']['plugins']['get']('Annotations');_0x12d7ee['refreshVisibility'](),_0x12d7ee['refreshPositioning']();}})));}['_showRevisionViewer'](_0x32880c){const _0xf1f134=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x314a3a=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x31f67a=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return m['create'](_0x31f67a,_0x32880c)['then'](_0x339c09=>(_0x314a3a['style']['display']='block',_0xf1f134['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x339c09));}['_closeRevisionViewer'](_0x325cf0){const _0x5c33e4=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x5c33e4['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x325cf0['destroy']();}async['_restoreRevision'](_0x2ed7be){const _0x1e8715=this['editor'],_0x1d5b1c=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x1e269c=_0x1e8715['plugins']['get']('RevisionTracker'),_0x4418d2=_0x1e8715['plugins']['get']('RevisionHistoryUtils'),_0x3c839f=_0x1d5b1c['repository']['getRevision'](_0x2ed7be);let _0x5e57e6,_0x4330be,_0x58f079;try{await _0x4418d2['loadRevisionData'](_0x3c839f,this['adapter']),_0x5e57e6=_0x4418d2['getRevisionDocumentData'](_0x3c839f),_0x4330be=_0x4418d2['getRevisionRootsAttributes'](_0x3c839f);}catch(_0x5c96dd){return void console['error'](_0x5c96dd);}_0x1e8715['model']['change'](_0xdc14bf=>{for(const _0x119d4a of Array['from'](_0x1e8715['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0xdc14bf['removeMarker'](_0x119d4a);}),_0x1d5b1c['isReady']=!0x1,_0x1e8715['model']['enqueueChange'](_0x4a5e15=>{_0x4a5e15['setSelection'](null),_0x4a5e15['removeSelectionAttribute'](_0x1e8715['model']['document']['selection']['getAttributeKeys']());const _0x4c5a14=Object['keys'](_0x5e57e6);for(const _0x151b4b of _0x1e8715['model']['document']['roots'])'$graveyard'!=_0x151b4b['rootName']&&_0x151b4b['isAttached']()&&!_0x4c5a14['includes'](_0x151b4b['rootName'])&&_0x4a5e15['detachRoot'](_0x151b4b);for(const _0xaa219 of _0x4c5a14){let _0x4d12a3=_0x1e8715['model']['document']['getRoot'](_0xaa219);_0x4d12a3&&_0x4d12a3['isAttached']()||(_0x4d12a3=_0x4a5e15['addRoot'](_0xaa219));const _0x34533a=_0x4330be[_0xaa219],_0x5b6ed7=Object['keys'](_0x34533a),_0x443e14=_0x5e57e6[_0xaa219];for(const _0x3cdd14 of _0x4d12a3['getAttributeKeys']())_0x5b6ed7['includes'](_0x3cdd14)||_0x4a5e15['removeAttribute'](_0x3cdd14,_0x4d12a3);for(const _0x117368 of _0x5b6ed7)_0x4a5e15['setAttribute'](_0x117368,_0x4330be[_0xaa219][_0x117368],_0x4d12a3);_0x4a5e15['remove'](_0x4a5e15['createRangeIn'](_0x4d12a3)),_0x4a5e15['insert'](_0x1e8715['data']['parse'](_0x443e14,_0x4d12a3),_0x4d12a3,0x0);}});const _0x458c2f=R(_0x1e8715['locale'],'Restored');if(_0x3c839f['name'])_0x58f079=-0x1==_0x3c839f['name']['indexOf'](_0x458c2f)?_0x458c2f+':\x20'+_0x3c839f['name']:_0x3c839f['name'];else _0x58f079=_0x458c2f+':\x20'+(_0x3c839f['createdAt']['toLocaleDateString'](_0x1e8715['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x3c839f['createdAt']['toLocaleTimeString'](_0x1e8715['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x1e269c['saveRevision']({'name':_0x58f079}),_0x1d5b1c['isReady']=!0x0,_0x1e8715['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{ut as RestoreRevisionCommand,I as Revision,vt as RevisionHistory,v as RevisionHistoryUI,$ as RevisionHistoryUtils,h as RevisionTracker,l as RevisionViewer,m as RevisionViewerEditor,ji as RevisionViewerLoadingOverlay,u as RevisionViewerUI,S as RevisionsRepository,f as RevisionsSidebar,lt as ShowChangeCommand};
|