@ckeditor/ckeditor5-revision-history 0.0.0-nightly-next-20250213.0 → 0.0.0-nightly-20250214.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/LICENSE.md +1 -1
- package/build/revision-history.js +1 -1
- package/ckeditor5-metadata.json +1 -1
- package/dist/index.js +6 -6
- package/dist/translations/af.js +1 -1
- package/dist/translations/af.umd.js +1 -1
- package/dist/translations/ar.js +1 -1
- package/dist/translations/ar.umd.js +1 -1
- package/dist/translations/ast.js +1 -1
- package/dist/translations/ast.umd.js +1 -1
- package/dist/translations/az.js +1 -1
- package/dist/translations/az.umd.js +1 -1
- package/dist/translations/bg.js +1 -1
- package/dist/translations/bg.umd.js +1 -1
- package/dist/translations/bn.js +1 -1
- package/dist/translations/bn.umd.js +1 -1
- package/dist/translations/bs.js +1 -1
- package/dist/translations/bs.umd.js +1 -1
- package/dist/translations/ca.js +1 -1
- package/dist/translations/ca.umd.js +1 -1
- package/dist/translations/cs.js +1 -1
- package/dist/translations/cs.umd.js +1 -1
- package/dist/translations/da.js +1 -1
- package/dist/translations/da.umd.js +1 -1
- package/dist/translations/de-ch.js +1 -1
- package/dist/translations/de-ch.umd.js +1 -1
- package/dist/translations/de.js +1 -1
- package/dist/translations/de.umd.js +1 -1
- package/dist/translations/el.js +1 -1
- package/dist/translations/el.umd.js +1 -1
- package/dist/translations/en-au.js +1 -1
- package/dist/translations/en-au.umd.js +1 -1
- package/dist/translations/en-gb.js +1 -1
- package/dist/translations/en-gb.umd.js +1 -1
- package/dist/translations/en.js +1 -1
- package/dist/translations/en.umd.js +1 -1
- package/dist/translations/eo.js +1 -1
- package/dist/translations/eo.umd.js +1 -1
- package/dist/translations/es-co.js +1 -1
- package/dist/translations/es-co.umd.js +1 -1
- package/dist/translations/es.js +1 -1
- package/dist/translations/es.umd.js +1 -1
- package/dist/translations/et.js +1 -1
- package/dist/translations/et.umd.js +1 -1
- package/dist/translations/eu.js +1 -1
- package/dist/translations/eu.umd.js +1 -1
- package/dist/translations/fa.js +1 -1
- package/dist/translations/fa.umd.js +1 -1
- package/dist/translations/fi.js +1 -1
- package/dist/translations/fi.umd.js +1 -1
- package/dist/translations/fr.js +1 -1
- package/dist/translations/fr.umd.js +1 -1
- package/dist/translations/gl.js +1 -1
- package/dist/translations/gl.umd.js +1 -1
- package/dist/translations/gu.js +1 -1
- package/dist/translations/gu.umd.js +1 -1
- package/dist/translations/he.js +1 -1
- package/dist/translations/he.umd.js +1 -1
- package/dist/translations/hi.js +1 -1
- package/dist/translations/hi.umd.js +1 -1
- package/dist/translations/hr.js +1 -1
- package/dist/translations/hr.umd.js +1 -1
- package/dist/translations/hu.js +1 -1
- package/dist/translations/hu.umd.js +1 -1
- package/dist/translations/hy.js +1 -1
- package/dist/translations/hy.umd.js +1 -1
- package/dist/translations/id.js +1 -1
- package/dist/translations/id.umd.js +1 -1
- package/dist/translations/it.js +1 -1
- package/dist/translations/it.umd.js +1 -1
- package/dist/translations/ja.js +1 -1
- package/dist/translations/ja.umd.js +1 -1
- package/dist/translations/jv.js +1 -1
- package/dist/translations/jv.umd.js +1 -1
- package/dist/translations/kk.js +1 -1
- package/dist/translations/kk.umd.js +1 -1
- package/dist/translations/km.js +1 -1
- package/dist/translations/km.umd.js +1 -1
- package/dist/translations/kn.js +1 -1
- package/dist/translations/kn.umd.js +1 -1
- package/dist/translations/ko.js +1 -1
- package/dist/translations/ko.umd.js +1 -1
- package/dist/translations/ku.js +1 -1
- package/dist/translations/ku.umd.js +1 -1
- package/dist/translations/lt.js +1 -1
- package/dist/translations/lt.umd.js +1 -1
- package/dist/translations/lv.js +1 -1
- package/dist/translations/lv.umd.js +1 -1
- package/dist/translations/ms.js +1 -1
- package/dist/translations/ms.umd.js +1 -1
- package/dist/translations/nb.js +1 -1
- package/dist/translations/nb.umd.js +1 -1
- package/dist/translations/ne.js +1 -1
- package/dist/translations/ne.umd.js +1 -1
- package/dist/translations/nl.js +1 -1
- package/dist/translations/nl.umd.js +1 -1
- package/dist/translations/no.js +1 -1
- package/dist/translations/no.umd.js +1 -1
- package/dist/translations/oc.js +1 -1
- package/dist/translations/oc.umd.js +1 -1
- package/dist/translations/pl.js +1 -1
- package/dist/translations/pl.umd.js +1 -1
- package/dist/translations/pt-br.js +1 -1
- package/dist/translations/pt-br.umd.js +1 -1
- package/dist/translations/pt.js +1 -1
- package/dist/translations/pt.umd.js +1 -1
- package/dist/translations/ro.js +1 -1
- package/dist/translations/ro.umd.js +1 -1
- package/dist/translations/ru.js +1 -1
- package/dist/translations/ru.umd.js +1 -1
- package/dist/translations/si.js +1 -1
- package/dist/translations/si.umd.js +1 -1
- package/dist/translations/sk.js +1 -1
- package/dist/translations/sk.umd.js +1 -1
- package/dist/translations/sl.js +1 -1
- package/dist/translations/sl.umd.js +1 -1
- package/dist/translations/sq.js +1 -1
- package/dist/translations/sq.umd.js +1 -1
- package/dist/translations/sr-latn.js +1 -1
- package/dist/translations/sr-latn.umd.js +1 -1
- package/dist/translations/sr.js +1 -1
- package/dist/translations/sr.umd.js +1 -1
- package/dist/translations/sv.js +1 -1
- package/dist/translations/sv.umd.js +1 -1
- package/dist/translations/th.js +1 -1
- package/dist/translations/th.umd.js +1 -1
- package/dist/translations/ti.js +1 -1
- package/dist/translations/ti.umd.js +1 -1
- package/dist/translations/tk.js +1 -1
- package/dist/translations/tk.umd.js +1 -1
- package/dist/translations/tr.js +1 -1
- package/dist/translations/tr.umd.js +1 -1
- package/dist/translations/tt.js +1 -1
- package/dist/translations/tt.umd.js +1 -1
- package/dist/translations/ug.js +1 -1
- package/dist/translations/ug.umd.js +1 -1
- package/dist/translations/uk.js +1 -1
- package/dist/translations/uk.umd.js +1 -1
- package/dist/translations/ur.js +1 -1
- package/dist/translations/ur.umd.js +1 -1
- package/dist/translations/uz.js +1 -1
- package/dist/translations/uz.umd.js +1 -1
- package/dist/translations/vi.js +1 -1
- package/dist/translations/vi.umd.js +1 -1
- package/dist/translations/zh-cn.js +1 -1
- package/dist/translations/zh-cn.umd.js +1 -1
- package/dist/translations/zh.js +1 -1
- package/dist/translations/zh.umd.js +1 -1
- package/package.json +11 -12
- package/src/changeitem.js +2 -2
- package/src/editor/revisionviewereditor.js +2 -2
- package/src/editor/revisionviewereditorui.js +1 -1
- package/src/editor/revisionviewereditoruiview.js +1 -1
- package/src/index.js +1 -1
- package/src/revision.js +2 -2
- package/src/revisiondiff.js +1 -1
- package/src/revisionhistory.js +1 -1
- package/src/revisionsrepository.js +1 -1
- package/src/revisiontracker.js +1 -1
- package/src/revisionviewer.js +1 -1
- package/src/ui/revision/createrevisionactionsdropdown.js +1 -1
- package/src/ui/revision/revisionauthorview.js +1 -1
- package/src/ui/revision/revisionnameview.js +1 -1
- package/src/ui/revision/revisionview.js +2 -2
- package/src/ui/revision/subrevisioncollapserview.js +1 -1
- package/src/ui/revision/subrevisionview.js +1 -1
- package/src/ui/revision/utils.js +1 -1
- package/src/ui/revisionhistory/revisionhistorysaverevisionformview.js +1 -1
- package/src/ui/revisionhistory/revisionhistoryui.js +1 -1
- package/src/ui/revisionssidebar/revisionssidebar.js +1 -1
- package/src/ui/revisionssidebar/revisionssidebarheaderview.js +1 -1
- package/src/ui/revisionssidebar/revisionssidebartimeperiodview.js +1 -1
- package/src/ui/revisionssidebar/revisionssidebarview.js +1 -1
- package/src/ui/revisionssidebar/utils.js +1 -1
- package/src/ui/revisionviewer/changedetailsview.js +1 -1
- package/src/ui/revisionviewer/changesnavigationview.js +1 -1
- package/src/ui/revisionviewer/revisionviewerloadingoverlay.js +1 -1
- package/src/ui/revisionviewer/revisionviewerui.js +1 -1
- package/src/utils/common-translations.js +1 -1
- package/theme/icons/arrow-down.svg +1 -0
- package/theme/icons/arrow-up.svg +1 -0
- package/theme/icons/revision-history.svg +1 -0
- package/theme/icons/user.svg +1 -0
package/dist/index.js
CHANGED
|
@@ -20,10 +20,10 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
import{ObservableMixin as
|
|
24
|
-
_0x4f7caf(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x5d32ca){super(),this['id']=_0x5d32ca['id']||_0x3aad70(),this['creator']=_0x5d32ca['creator']||null,this['authors']=_0x5d32ca['authors']||[],this['diffData']=_0x5d32ca['diffData']||null,this['toVersion']=_0x5d32ca['toVersion']||0x0,this['fromVersion']=_0x5d32ca['fromVersion']||0x0,this['set']('name',_0x5d32ca['name']||''),this['set']('createdAt',_0x5d32ca['createdAt']||new Date()),this['set']('attributes',_0x5d32ca['attributes']||{});}['setName'](_0xde0be7){this['_update']({'name':_0xde0be7});}['setAttribute'](_0x4bd1a6,_0x4025f2){const _0x19ecc6=_0x4abf57(this['attributes']);_0x5bca57(_0x19ecc6,_0x4bd1a6,_0x4025f2),this['_update']({'attributes':_0x19ecc6});}['removeAttribute'](_0x249eaa){const _0x12a5ef=_0x4abf57(this['attributes']);_0x45c231(_0x12a5ef,_0x249eaa),this['_update']({'attributes':_0x12a5ef});}['_update'](_0x544e8f,_0x5d200a=!0x1){let _0x14ccf5=!0x1;const _0x585ac2={'id':this['id']},_0x4580ad=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x3bc169 of _0x4580ad){const _0x851b3a=_0x544e8f[_0x3bc169];void 0x0!==_0x851b3a&&_0x851b3a!==this[_0x3bc169]&&(this[_0x3bc169]=_0x851b3a,_0x585ac2[_0x3bc169]=_0x851b3a,_0x14ccf5=!0x0);}_0x14ccf5&&(_0x585ac2['authors']&&(_0x585ac2['authorsIds']=_0x585ac2['authors']['map'](_0x4048b1=>_0x4048b1['id']),delete _0x585ac2['authors']),this['fire']('_update',_0x585ac2,_0x5d200a));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x123650=>_0x123650['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class j extends _0x5517c8{['_revisions'];static get['requires'](){return[_0x49ffcb];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x578642){super(_0x578642),this['_revisions']=new _0x1b37a4();}['afterInit'](){!async function(_0x62b0b5){const _0xcb8d75=_0x1376d4([0x39,0x47,0x50,0x59,0x70,0x54,0x76,0x53,0x55,0x52,0x6b,0x48,0x58,0x6d,0x69,0x36,0x34,0x6e,0x6c,0x74,0x4c,0x38,0x62,0x43,0x68,0x7a,0x31,0x66,0x4e,0x71,0x75,0x45,0x44,0x46,0x51,0x42,0x64,0x4d,0x41,0x57,0x65,0x4f,0x5a,0x63,0x6f,0x33,0x77,0x73,0x30,0x37,0x4a,0x72,0x79,0x67,0x32,0x49,0x6a,0x35,0x4b,0x78,0x61,0x56]),_0x4af0cf=0xeb829,_0x458931=0x10c4eff3,_0x5ab10c=0x10c3b093^_0x458931,_0x3c6780=window[_0x1376d4([0x44,0x61,0x74,0x65])][_0x1376d4([0x6e,0x6f,0x77])](),_0x3cea63=_0x62b0b5[_0x1376d4([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x232680=new window[(_0x1376d4([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2a9289=>{_0x3cea63[_0x1376d4([0x6f,0x6e,0x63,0x65])](_0x1376d4([0x72,0x65,0x61,0x64,0x79]),_0x2a9289);}),_0x43cc56={[_0x1376d4([0x6b,0x74,0x79])]:_0x1376d4([0x45,0x43]),[_0x1376d4([0x75,0x73,0x65])]:_0x1376d4([0x73,0x69,0x67]),[_0x1376d4([0x63,0x72,0x76])]:_0x1376d4([0x50,0x2d,0x32,0x35,0x36]),[_0x1376d4([0x78])]:_0x1376d4([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]),[_0x1376d4([0x79])]:_0x1376d4([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]),[_0x1376d4([0x61,0x6c,0x67])]:_0x1376d4([0x45,0x53,0x32,0x35,0x36])},_0xbe4ea5=_0x3cea63[_0x1376d4([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x1376d4([0x67,0x65,0x74])](_0x1376d4([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x860173(){let _0xfc2898,_0x4bc9a4=null,_0x2e1004=null;try{if(_0xbe4ea5==_0x1376d4([0x47,0x50,0x4c]))return _0x1376d4([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0xfc2898=_0x450281(),!_0xfc2898)return _0x1376d4([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0xfc2898[_0x1376d4([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x2e1004=_0x19cbc9(_0xfc2898[_0x1376d4([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0xfc2898[_0x1376d4([0x6a,0x74,0x69])])),await _0x3c88f2()?_0x34b9ca()?_0x2da6d3()?_0x1376d4([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x55ad76()?(_0xfc2898[_0x1376d4([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x1376d4([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x4bc9a4=_0x58b534(_0x1376d4([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0xfc2898[_0x1376d4([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x1376d4([0x74,0x72,0x69,0x61,0x6c])&&(_0x4bc9a4=_0x58b534(_0x1376d4([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x58c0bf()):_0x1376d4([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x1376d4([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x1376d4([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch(_0x73ca1b){return _0x1376d4([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x2da6d3(){const _0xdabcff=[_0x1376d4([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x1376d4([0x74,0x72,0x69,0x61,0x6c])][_0x1376d4([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0xfc2898[_0x1376d4([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x3c6780/0x3e8:0xe10*_0x5ab10c;return _0xfc2898[_0x1376d4([0x65,0x78,0x70])]<_0xdabcff;}function _0x34b9ca(){const _0x5d2d86=_0xfc2898[_0x1376d4([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x5d2d86)return!0x1;if(_0x5d2d86[_0x1376d4([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x1376d4([0x2a])))return!0x0;if(_0x5d2d86[_0x1376d4([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x1376d4([0x52,0x48])))return!0x0;if(_0x5d2d86[_0x1376d4([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x1376d4([0x52,0x52,0x48]))){if(_0x18c3d1())return!0x0;if(_0x13d21c()||_0x2d1858())return!0x0;}return!0x1;}function _0x55ad76(){const _0xb37636=_0xfc2898[_0x1376d4([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0xb37636||0x0==_0xb37636[_0x1376d4([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x1397e0}=new URL(window[_0x1376d4([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0xb37636[_0x1376d4([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x1397e0))return!0x0;const _0x457d91=_0x1397e0[_0x1376d4([0x73,0x70,0x6c,0x69,0x74])](_0x1376d4([0x2e]));return _0xb37636[_0x1376d4([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x3da9d4=>_0x3da9d4[_0x1376d4([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x1376d4([0x2a])))[_0x1376d4([0x6d,0x61,0x70])](_0x5e1a43=>_0x5e1a43[_0x1376d4([0x73,0x70,0x6c,0x69,0x74])](_0x1376d4([0x2e])))[_0x1376d4([0x73,0x6f,0x6d,0x65])](_0x35a8cb=>_0x457d91[_0x1376d4([0x65,0x76,0x65,0x72,0x79])]((_0x2a76aa,_0x29449a)=>_0x35a8cb[_0x29449a]===_0x2a76aa||_0x35a8cb[_0x29449a]===_0x1376d4([0x2a])));}function _0x58c0bf(){return _0x4bc9a4&&_0x2e1004?new window[(_0x1376d4([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x10fa49,_0x4d816c)=>{_0x4bc9a4[_0x1376d4([0x74,0x68,0x65,0x6e])](_0x10fa49,_0x4d816c),_0x2e1004[_0x1376d4([0x74,0x68,0x65,0x6e])](_0x176740=>{_0x176740!=_0x1376d4([0x56,0x61,0x6c,0x69,0x64])&&_0x10fa49(_0x176740);},_0x4d816c);}):_0x4bc9a4||_0x2e1004||_0x1376d4([0x56,0x61,0x6c,0x69,0x64]);}}function _0x19cbc9(_0x206abf,_0x3a2c16){return new window[(_0x1376d4([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x5a0445=>{if(_0x12bc16())return _0x5a0445(_0x1376d4([0x56,0x61,0x6c,0x69,0x64]));_0x3f67a8(),_0x3cea63[_0x1376d4([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x1376d4([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x276b16=!0x1;const _0x3421d8=_0x3aad70();function _0x2fb7f0(_0x1874cc){return!!_0x1874cc&&(typeof _0x1874cc===_0x1376d4([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x1874cc===_0x1376d4([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x1874cc[_0x1376d4([0x74,0x68,0x65,0x6e])]===_0x1376d4([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x1874cc[_0x1376d4([0x63,0x61,0x74,0x63,0x68])]===_0x1376d4([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x5124c0(_0xb6ab90){_0x3fb94c(_0xb6ab90)[_0x1376d4([0x74,0x68,0x65,0x6e])](_0x5e02be=>{if(!_0x5e02be||_0x5e02be[_0x1376d4([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x1376d4([0x6f,0x6b]))return _0x1376d4([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x2fdbd3(_0x338816(_0x3421d8+_0x3a2c16))!=_0x5e02be[_0x1376d4([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x1376d4([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x1376d4([0x56,0x61,0x6c,0x69,0x64]);})[_0x1376d4([0x74,0x68,0x65,0x6e])](_0x135098=>(_0x48b2a4(),_0x135098),()=>{const _0x3af90b=_0x25a1ac();return null==_0x3af90b?(_0x48b2a4(),_0x1376d4([0x56,0x61,0x6c,0x69,0x64])):_0x1376d4(_0x3c6780-_0x3af90b>(0x34c86bf3^_0x458931)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x1376d4([0x74,0x68,0x65,0x6e])](_0x5a0445)[_0x1376d4([0x63,0x61,0x74,0x63,0x68])](()=>{_0x5a0445(_0x1376d4([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x48f1cb=0x10f20173^_0x458931;function _0x48b2a4(){const _0x30d318=_0x1376d4([0x6c,0x6c,0x63,0x74,0x2d])+_0x2fdbd3(_0x338816(_0x206abf)),_0x5c28c1=_0x3d729b(_0x2fdbd3(window[_0x1376d4([0x4d,0x61,0x74,0x68])][_0x1376d4([0x63,0x65,0x69,0x6c])](_0x3c6780/_0x48f1cb)));window[_0x1376d4([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x1376d4([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x30d318,_0x5c28c1);}function _0x25a1ac(){const _0x23005d=_0x1376d4([0x6c,0x6c,0x63,0x74,0x2d])+_0x2fdbd3(_0x338816(_0x206abf)),_0x1a0b9e=window[_0x1376d4([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x1376d4([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x23005d);return _0x1a0b9e?window[_0x1376d4([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x3d729b(_0x1a0b9e),0x10)*_0x48f1cb:null;}function _0x3fb94c(_0x197daa){return new window[(_0x1376d4([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x581af3,_0xdad63b)=>{_0x197daa[_0x1376d4([0x74,0x68,0x65,0x6e])](_0x581af3,_0xdad63b),window[_0x1376d4([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0xdad63b,0x10c53b33^_0x458931);});}}_0x3cea63[_0x1376d4([0x6f,0x6e])](_0x1376d4([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x3c6f5e,_0x154c19)=>{if(_0x154c19[0x0]!=_0x206abf)return _0x5a0445(_0x1376d4([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x154c19[0x1]={..._0x154c19[0x1],[_0x1376d4([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x3421d8};},{[_0x1376d4([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x1376d4([0x68,0x69,0x67,0x68])}),_0x3cea63[_0x1376d4([0x6f,0x6e])](_0x1376d4([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x34b7a3=>{_0x2fb7f0(_0x34b7a3[_0x1376d4([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x276b16=!0x0,_0x5124c0(_0x34b7a3[_0x1376d4([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x1376d4([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x1376d4([0x6c,0x6f,0x77])}),_0x232680[_0x1376d4([0x74,0x68,0x65,0x6e])](()=>{_0x276b16||_0x5a0445(_0x1376d4([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x12bc16(){return _0x3cea63[_0x1376d4([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x1376d4([0x76,0x69,0x65,0x77])][_0x1376d4([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x1376d4([0x61,0x75,0x74,0x6f]);}function _0x3f67a8(){_0x3cea63[_0x1376d4([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x1376d4([0x76,0x69,0x65,0x77])][_0x1376d4([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x1376d4([0x61,0x75,0x74,0x6f]);}}function _0x58b534(_0x300106){const _0x2c37d9=[new window[(_0x1376d4([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2c898c=>setTimeout(_0x2c898c,0x10cdd13f^_0x458931)),_0x232680[_0x1376d4([0x74,0x68,0x65,0x6e])](()=>new window[(_0x1376d4([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x1ab5c0=>{const _0xcf4673=0x10c4eff4^_0x458931,_0x4c9558=_0x62b0b5[_0x1376d4([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x47415a(){_0x4c9558[_0x1376d4([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0xcf4673&&_0x1ab5c0();}_0x47415a(),_0x4c9558[_0x1376d4([0x6f,0x6e])](_0x1376d4([0x61,0x64,0x64]),_0x47415a);})),new window[(_0x1376d4([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x164f4e=>{function _0x35573b(){for(const _0x4d0099 in window)if(window[_0x1376d4([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x1376d4([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x4d0099))&&window[_0x4d0099]==_0x4af0cf)return _0x164f4e();_0x3cea63[_0x1376d4([0x73,0x74,0x61,0x74,0x65])]!=_0x1376d4([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x1376d4([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x35573b,0x10c4fc7b^_0x458931);}_0x267410(_0x1376d4([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x35573b();})];return window[_0x1376d4([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x1376d4([0x72,0x61,0x63,0x65])](_0x2c37d9)[_0x1376d4([0x74,0x68,0x65,0x6e])](()=>_0x300106);}async function _0x2fd7f3(){if(await _0x232680,_0x267410(_0x1376d4([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x40eb5f=_0x62b0b5[_0x1376d4([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x308835=_0x62b0b5[_0x1376d4([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])](_0x40eb5f[_0x1376d4([0x69,0x64])]),_0x56a503=_0x2da2ee(_0x1376d4([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x56a503[_0x1376d4([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x40eb5f['id'],_0x308835?_0x308835['id']:null,!0x0),_0x56a503[_0x1376d4([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x1376d4([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x56a503[_0x1376d4([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x56a503[_0x1376d4([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x1e8351,void(_0x56a503[_0x1376d4([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x1e8351);}if(_0x267410(_0x1376d4([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x219c9c=_0x2da2ee(_0x1376d4([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x219c9c[_0x1376d4([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x1376d4([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x219c9c[_0x1376d4([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x219c9c[_0x1376d4([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x1e8351,_0x219c9c[_0x1376d4([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x1e8351;}_0x3cea63[_0x1376d4([0x6d,0x6f,0x64,0x65,0x6c])][_0x1376d4([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x1e8351,_0x3cea63[_0x1376d4([0x6d,0x6f,0x64,0x65,0x6c])][_0x1376d4([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x1e8351,_0x3cea63[_0x1376d4([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x1376d4([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x18c3d1(){return _0x267410(_0x1376d4([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x2da2ee(_0x1376d4([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x1376d4([0x73,0x74,0x61,0x74,0x65])]==_0x1376d4([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x13d21c(){return _0x267410(_0x1376d4([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 _0x2d1858(){return _0x267410(_0x1376d4([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x2f4530(_0x68b75c){const _0x904377=_0x31585();_0x3cea63[_0x904377]=_0x1376d4([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])+_0x68b75c,_0x68b75c[_0x1376d4([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x1376d4([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x31585()]=_0x4af0cf),_0x68b75c!=_0x1376d4([0x56,0x61,0x6c,0x69,0x64])&&_0x2fd7f3();}function _0x31585(){const _0x2591f3=window[_0x1376d4([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x1376d4([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x1376d4([0x6e,0x6f,0x77])]())[_0x1376d4([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x1376d4([0x2e]),'');let _0x1f3d5a=_0x1376d4([0x47]);for(let _0xdf2068=0x0;_0xdf2068<_0x2591f3[_0x1376d4([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0xdf2068+=0x2){let _0x56cbda=window[_0x1376d4([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x2591f3[_0x1376d4([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0xdf2068,_0xdf2068+0x2));_0x56cbda>=_0xcb8d75[_0x1376d4([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x56cbda-=_0xcb8d75[_0x1376d4([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x1f3d5a+=_0xcb8d75[_0x56cbda];}return _0x1f3d5a;}function _0x450281(){const _0x580b55=_0xbe4ea5[_0x1376d4([0x73,0x70,0x6c,0x69,0x74])](_0x1376d4([0x2e]));if(0x3!=_0x580b55[_0x1376d4([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x35bfab(_0x580b55[0x1]);function _0x35bfab(_0x572a1d){const _0xc34e10=_0x24c926(_0x572a1d);return _0xc34e10&&_0x12be36()?_0xc34e10:null;function _0x12be36(){const _0x185bfa=_0xc34e10[_0x1376d4([0x6a,0x74,0x69])],_0x47fcbb=window[_0x1376d4([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x185bfa[_0x1376d4([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x185bfa[_0x1376d4([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x59ad92={..._0xc34e10,[_0x1376d4([0x6a,0x74,0x69])]:_0x185bfa[_0x1376d4([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x185bfa[_0x1376d4([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x59ad92[_0x1376d4([0x76,0x63])],_0x338816(_0x59ad92)==_0x47fcbb;}}}async function _0x3c88f2(){let _0x4ed640=!0x0;try{const _0x4bbff8=_0xbe4ea5[_0x1376d4([0x73,0x70,0x6c,0x69,0x74])](_0x1376d4([0x2e])),[_0x3c3d28,_0xc4d0ff,_0x33ee58]=_0x4bbff8;return _0x3fd918(_0x3c3d28),await _0x26a03c(_0x3c3d28,_0xc4d0ff,_0x33ee58),_0x4ed640;}catch(_0x1ba4ca){return!0x1;}function _0x3fd918(_0x5c7175){const _0x3dfcb4=_0x24c926(_0x5c7175);_0x3dfcb4&&_0x3dfcb4[_0x1376d4([0x61,0x6c,0x67])]==_0x1376d4([0x45,0x53,0x32,0x35,0x36])||(_0x4ed640=!0x1);}async function _0x26a03c(_0x3a9a57,_0xa5f46,_0x2d46bc){const _0x47a0ba=window[_0x1376d4([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x1376d4([0x66,0x72,0x6f,0x6d])](_0x35ed25(_0x2d46bc),_0x289a37=>_0x289a37[_0x1376d4([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x2e3c65=new window[(_0x1376d4([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x1376d4([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x3a9a57+_0x1376d4([0x2e])+_0xa5f46),_0x1aa03d=window[_0x1376d4([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x1376d4([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x1aa03d)return;const _0x4f49d4=await _0x1aa03d[_0x1376d4([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x1376d4([0x6a,0x77,0x6b]),_0x43cc56,{[_0x1376d4([0x6e,0x61,0x6d,0x65])]:_0x1376d4([0x45,0x43,0x44,0x53,0x41]),[_0x1376d4([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x1376d4([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x1376d4([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x1aa03d[_0x1376d4([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x1376d4([0x6e,0x61,0x6d,0x65])]:_0x1376d4([0x45,0x43,0x44,0x53,0x41]),[_0x1376d4([0x68,0x61,0x73,0x68])]:{[_0x1376d4([0x6e,0x61,0x6d,0x65])]:_0x1376d4([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x4f49d4,_0x47a0ba,_0x2e3c65)||(_0x4ed640=!0x1);}}function _0x24c926(_0x11ea0e){return _0x11ea0e[_0x1376d4([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x1376d4([0x65,0x79]))?JSON[_0x1376d4([0x70,0x61,0x72,0x73,0x65])](_0x35ed25(_0x11ea0e)):null;}function _0x35ed25(_0x20153a){return window[_0x1376d4([0x61,0x74,0x6f,0x62])](_0x20153a[_0x1376d4([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x1376d4([0x2b]))[_0x1376d4([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x1376d4([0x2f])));}function _0x338816(_0x6a9e50){let _0x13efe5=0x1505;function _0x51f700(_0x1b8817){for(let _0x334053=0x0;_0x334053<_0x1b8817[_0x1376d4([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x334053++){const _0x4ce5b4=_0x1b8817[_0x1376d4([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x334053);_0x13efe5=(_0x13efe5<<0x5)+_0x13efe5+_0x4ce5b4,_0x13efe5&=_0x13efe5;}}function _0x36a9a6(_0x4d21fb){Array[_0x1376d4([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x4d21fb)?_0x4d21fb[_0x1376d4([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x36a9a6):_0x4d21fb&&typeof _0x4d21fb==_0x1376d4([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x1376d4([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x4d21fb)[_0x1376d4([0x73,0x6f,0x72,0x74])]()[_0x1376d4([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x45afc4,_0x2b20d3])=>{_0x51f700(_0x45afc4),_0x36a9a6(_0x2b20d3);}):_0x51f700(window[_0x1376d4([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x4d21fb));}return _0x36a9a6(_0x6a9e50),_0x13efe5>>>0x0;}function _0x2fdbd3(_0x2002f6){return _0x2002f6[_0x1376d4([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x1376d4([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x1376d4([0x30]));}function _0x3d729b(_0x517ee8){return _0x517ee8[_0x1376d4([0x73,0x70,0x6c,0x69,0x74])]('')[_0x1376d4([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x1376d4([0x6a,0x6f,0x69,0x6e])]('');}function _0x267410(_0x3a8238){return _0x3cea63[_0x1376d4([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x1376d4([0x68,0x61,0x73])](_0x3a8238);}function _0x2da2ee(_0x31bad3){return _0x3cea63[_0x1376d4([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x1376d4([0x67,0x65,0x74])](_0x31bad3);}function _0x1e8351(){}function _0x1376d4(_0x12352e){return _0x12352e['map'](_0x42126d=>String['fromCharCode'](_0x42126d))['join']('');}_0x2f4530(await _0x860173());}(this);}['createRevision'](_0x1019ac){const _0x55f2d5=this['editor']['plugins']['get']('Users');return new h({'id':_0x1019ac['id'],'name':_0x1019ac['name'],'creator':_0x1019ac['creatorId']?_0x55f2d5['getUser'](_0x1019ac['creatorId']):null,'diffData':_0x1019ac['diffData']||_0x1019ac['data'],'authors':_0x1019ac['authorsIds']['map'](_0x1e0d48=>_0x55f2d5['getUser'](_0x1e0d48)),'createdAt':new Date(_0x1019ac['createdAt']),'attributes':_0x1019ac['attributes'],'fromVersion':_0x1019ac['fromVersion'],'toVersion':_0x1019ac['toVersion']});}['addRevision'](_0x54b3f2,_0x531408=0x0){this['_revisions']['add'](_0x54b3f2,_0x531408);}['getRevision'](_0x3d83cd){return this['_revisions']['get'](_0x3d83cd);}['getRevisions'](_0x5f576b={'toJSON':!0x1}){const _0x9dc5cd=Array['from'](this['_revisions']);return _0x9dc5cd['reverse'](),_0x5f576b['toJSON']?_0x9dc5cd['map'](_0x36d8d9=>_0x36d8d9['toJSON']()):_0x9dc5cd;}['getIndex'](_0x21bab7){return this['_revisions']['getIndex'](_0x21bab7);}['getEarlierVisibleRevision'](_0x298b2e){const [,_0x16b7b1]=this['getRevisionsIterator'](_0x298b2e,{'direction':'earlier'});return _0x16b7b1;}['getLaterVisibleRevision'](_0x567f41){const [,_0x2e650b]=this['getRevisionsIterator'](_0x567f41,{'direction':'later'});return _0x2e650b;}['getRevisionsInDiff'](_0x2a50b1){const _0x5a80fd=[];for(const _0x591343 of this['getRevisionsIterator'](_0x2a50b1['newRevisionId']))if(_0x5a80fd['push'](_0x591343),_0x591343['id']===_0x2a50b1['oldRevisionId'])break;return _0x5a80fd;}*['getRevisionsIterator'](_0x505059,{direction:_0x30928e='earlier',filter:_0x5b7aaa=()=>!0x0}={}){const _0xedb9bf='earlier'===_0x30928e?0x1:-0x1;let _0xd1a8bc=this['_revisions']['get'](_0x505059),_0x1e52c0=this['getIndex'](_0xd1a8bc);for(yield _0xd1a8bc;_0xd1a8bc;){if(_0x1e52c0+=_0xedb9bf,_0xd1a8bc=this['getRevision'](_0x1e52c0),!_0xd1a8bc)return;_0x5b7aaa(_0xd1a8bc)&&(yield _0xd1a8bc);}}}function m(_0x15e01c,_0x1030ab,_0x1e07de){const t=_0x15e01c['t'];switch(_0x1030ab){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'},_0x1e07de);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x1e07de);case'Show\x20previous\x20change':return t('Show\x20previous\x20change');case'Show\x20next\x20change':return t('Show\x20next\x20change');case'EDIT_X_OF_Y_REVISIONS':return t({'string':'Edit','id':'EDIT_X_OF_Y_REVISIONS'});case'Total':return t('Total');case'Revision\x20creator':return t('Revision\x20creator');case'Revision\x20author':return t('Revision\x20author');case'Revision\x20name':return t('Revision\x20name');case'Save\x20current\x20revision':return t('Save\x20current\x20revision');case'Accept':return t('Accept');case'Save':return t('Save');case'Cancel':return t('Cancel');case'Name\x20of\x20the\x20revision':return t('Name\x20of\x20the\x20revision');case'optional':return t('optional');case'PENDING_ACTION_REVISION_HISTORY':return t({'string':'Unsaved\x20change\x20in\x20revision\x20history.','id':'PENDING_ACTION_REVISION_HISTORY'});case'The\x20revision\x20name\x20cannot\x20be\x20empty.':return t('The\x20revision\x20name\x20cannot\x20be\x20empty.');case'Enter\x20the\x20revision\x20name':return t('Enter\x20the\x20revision\x20name');default:return'';}}const E={'c':_0x135f7f,'a':_0xf10c63,'e':_0xd2038a,'r':_0x35328c,'u':_0x5db413};class u extends _0x5517c8{['licenseKey'];['_licenseKeyCheckInterval'];['adapter'];['currentRevision'];['repository'];['_revisionDataBuilder'];['_source'];['_initialRevisionId'];['_bufferedUpdates'];['_pendingAction'];['_continueCurrentRevision'];['_startingVersion'];['_loadedStateData'];static get['pluginName'](){return'RevisionTracker';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[_0x49ffcb,j,_0x38413b];}constructor(_0x94c9e5){super(_0x94c9e5),this['adapter']=null,this['currentRevision']=null,this['_revisionDataBuilder']=new V(this['editor']),this['_initialRevisionId']=this['editor']['config']['get']('collaboration.channelId')||'initial',this['_bufferedUpdates']=new Map(),this['_loadedStateData']=null;const _0x1191cf=_0x3aad70();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x1191cf},this['set']('isReady',!0x1),this['set']('isEnabled',!0x0),this['set']('_isPendingUpdate',!0x1),this['editor']['config']['define']('revisionHistory.resumeUnsavedRevision',!0x0),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'});}['init'](){this['repository']=this['editor']['plugins']['get']('RevisionsRepository'),this['_setConversion'](),this['editor']['data']['on']('ready',()=>{const _0x535fda=this['repository']['getRevision'](0x0),_0x4eb023=_0x535fda&&null===_0x535fda['creator']?_0x535fda:null;if(this['_continueCurrentRevision']=!!_0x4eb023&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x5a3741=this['_source']['getCurrentRevisionId'](),_0x1c12c2=this['repository']['getRevision'](_0x5a3741);if(_0x1c12c2)this['_startingVersion']=_0x1c12c2['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0xcc831e=this['_source']['history']['_operations']['find'](_0x3894a9=>!_0x3894a9['_isInit']),_0xf8dd97=_0xcc831e?_0xcc831e['baseVersion']:this['_source']['history']['version'];_0x535fda?(_0x535fda['toVersion']<_0xf8dd97&&_0x535fda['_update']({'toVersion':_0xf8dd97}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x4eb023['id'],this['_startingVersion']=_0x4eb023['fromVersion']):(this['_startingVersion']=_0x535fda['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0xf8dd97,this['_continueCurrentRevision']=!0x1);}}else _0x4eb023&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x4eb023['toVersion'],this['editor']['model']['document']['history']['version']),_0x4eb023['fromVersion']===_0x4eb023['toVersion']?(0x0!==_0x4eb023['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x4eb023['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x4eb023['id'],this['_startingVersion']=_0x4eb023['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',_0x34128a=>!_0x34128a),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x2c4e92=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x48ebf5;for(const _0x29061b in _0x2c4e92){const _0x162583=_0x29061b,_0x3167ec=_0x2c4e92[_0x162583];if('revisionHistoryLicenseKeyValid'==_0x3167ec||'revisionHistoryLicenseKeyInvalid'==_0x3167ec||'revisionHistoryLicenseKeyExpired'==_0x3167ec||'revisionHistoryLicenseKeyDomainLimit'==_0x3167ec||'revisionHistoryLicenseKeyNotAllowed'==_0x3167ec||'revisionHistoryLicenseKeyEvaluationLimit'==_0x3167ec||'revisionHistoryLicenseKeyTrialLimit'==_0x3167ec||'revisionHistoryLicenseKeyUsageLimit'==_0x3167ec){delete _0x2c4e92[_0x162583],_0x48ebf5=_0x3167ec,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x48ebf5&&_0x2c4e92['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x48ebf5&&_0x2c4e92['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x48ebf5&&_0x2c4e92['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x48ebf5&&_0x2c4e92['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x48ebf5&&_0x2c4e92['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x48ebf5&&_0x2c4e92['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x48ebf5&&_0x2c4e92['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x27e073=this['repository']['getRevision'](0x0),_0xbb530e=await this['getRevisionDocumentData'](_0x27e073),_0x4ad82e=await this['getRevisionRootsAttributes'](_0x27e073);this['_replaceEditorDataWithRevisionData'](_0xbb530e,_0x4ad82e);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x18c299){this['_source']=_0x18c299;}async['update'](){const _0x5cc709=await this['_source']['getLatestVersion']();if(_0x5cc709>this['currentRevision']['toVersion']){await this['_loadState']();const _0x2e4cb9=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x5cc709});_0x2e4cb9['authors']=_0x2e4cb9['authorsIds']['map'](_0xd53751=>this['editor']['plugins']['get']('Users')['getUser'](_0xd53751)),this['currentRevision']['_update'](_0x2e4cb9);}}async['_loadState'](){this['_continueCurrentRevision']&&!this['_loadedStateData']&&(await this['_loadRevisionData'](this['currentRevision']),this['_revisionDataBuilder']['loadState'](this['currentRevision']),this['_loadedStateData']={'fromVersion':this['currentRevision']['fromVersion'],'authors':this['currentRevision']['authors']['slice']()});}async['saveRevision'](_0x595423={},_0x70aa97=null){const _0x284700=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x70aa97>this['currentRevision']['toVersion']&&(_0x70aa97=null),null===_0x70aa97&&(_0x70aa97=await this['_source']['getLatestVersion']());const _0x53a7ec=this['_getFromVersion'](_0x70aa97),_0x554e0e=this['buildRevisionData']({'from':_0x53a7ec,'to':_0x70aa97});if(this['currentRevision']['toVersion']<_0x70aa97){const _0x306ef3=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x70aa97,'to':_0x70aa97});_0x306ef3['authors']=[],_0x306ef3['authorsIds']=[],_0x306ef3['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x306ef3,!0x0),delete _0x306ef3['authors'],_0x284700['push'](_0x306ef3);}_0x595423['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x595423['name']=_0x595423['name']||null,_0x595423['id']=_0x595423['id']||_0x3aad70(),_0x595423={..._0x595423,..._0x554e0e};const _0x1c109f=this['addRevisionData'](_0x595423);_0x284700['push'](_0x595423);const _0xb65b3a=this['repository']['getIndex'](_0x1c109f);if(0x0!==_0xb65b3a){const _0x386b4b=this['repository']['getRevision'](_0xb65b3a-0x1);if(_0x386b4b['fromVersion']!==_0x70aa97){const _0x14a258=this['_revisionDataBuilder']['getData'](_0x70aa97,_0x386b4b['toVersion']),_0x52bd09={'id':_0x386b4b['id'],'diffData':_0x14a258['diffData'],'authorsIds':_0x14a258['authorsIds'],'authors':_0x14a258['authorsIds']['map'](_0x554fcd=>this['editor']['plugins']['get']('Users')['getUser'](_0x554fcd)),'fromVersion':_0x70aa97};_0x386b4b===this['currentRevision']&&(_0x52bd09['createdAt']=new Date(_0x595423['createdAt']['getTime']()+0xa)),_0x386b4b['_update'](_0x52bd09,!0x0),delete _0x52bd09['authors'],_0x284700['push'](_0x52bd09);}}if(this['adapter']){for(const _0xf35a58 of _0x284700)this['_bufferUpdate'](_0xf35a58['id'],_0xf35a58,!0x0);this['sendBufferedUpdates']();}return _0x1c109f;}['addRevisionData'](_0x5048e7){const _0x5da9a6=this['repository']['createRevision'](_0x5048e7);return this['adapter']&&_0x5da9a6['on']('_update',(_0x4fd718,_0x5affdb,_0x2b3213)=>{_0x2b3213||(this['_bufferUpdate'](_0x5affdb['id'],_0x5affdb,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x5da9a6,this['_findInsertionIndex'](_0x5da9a6)),_0x5da9a6;}async['getRevisionDocumentData'](_0x518d5f){await this['_loadRevisionData'](_0x518d5f);const _0x1c58ce={};for(const _0x5d5174 in _0x518d5f['diffData']){if(_0x518d5f['diffData'][_0x5d5174]['attachChange']&&!_0x518d5f['diffData'][_0x5d5174]['attachChange']['isAttached'])continue;const _0x5edf61=this['_removeRevisionMarkers'](JSON['parse'](_0x518d5f['diffData'][_0x5d5174]['insertions'])),_0xdeb872=this['editor']['editing']['view']['document'],_0x4a4840=new _0x1c9f86(_0xdeb872,_0x5edf61['map'](_0xd48eb=>P(_0xd48eb,this['editor'])));this['editor']['data']['processor']['useFillerType']('marked'),_0x1c58ce[_0x5d5174]=this['editor']['data']['processor']['toData'](_0x4a4840),this['editor']['data']['processor']['useFillerType']('default');}return _0x1c58ce;}async['getRevisionRootsAttributes'](_0x1e5d4b){await this['_loadRevisionData'](_0x1e5d4b);const _0x5a14e7={};for(const _0x5c344b in _0x1e5d4b['diffData'])_0x1e5d4b['diffData'][_0x5c344b]['attachChange']&&!_0x1e5d4b['diffData'][_0x5c344b]['attachChange']['isAttached']||(_0x5a14e7[_0x5c344b]=_0x1e5d4b['diffData'][_0x5c344b]['attributesAfter']||{});return _0x5a14e7;}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x54bc22=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x80632f=0x0;_0x80632f<_0x54bc22['length'];_0x80632f++){const _0x5bf80a=_0x54bc22[_0x80632f];let _0x5421ee=!0x1;for(const _0x4d28ee of Object['keys'](_0x5bf80a))void 0x0===_0x5bf80a[_0x4d28ee]?delete _0x5bf80a[_0x4d28ee]:'id'!==_0x4d28ee&&(_0x5421ee=!0x0);_0x5421ee||(_0x54bc22[_0x80632f]=null);}if(_0x54bc22=_0x54bc22['filter'](_0xcefe09=>null!==_0xcefe09),!_0x54bc22['length'])return;for(let _0x181499=0x0;_0x181499<_0x54bc22['length'];_0x181499++){const _0x353f02=_0x54bc22[_0x181499];void 0x0!==_0x353f02['fromVersion']&&void 0x0===_0x353f02['toVersion']&&(_0x353f02['toVersion']=this['repository']['getRevision'](_0x353f02['id'])['toVersion']),void 0x0!==_0x353f02['toVersion']&&void 0x0===_0x353f02['fromVersion']&&(_0x353f02['fromVersion']=this['repository']['getRevision'](_0x353f02['id'])['fromVersion']);}const _0x5633f5=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x54bc22,_0x5633f5)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x552ab4=>{if(_0x552ab4){for(const _0x52c09d of _0x552ab4)this['setRevisionData']({'id':_0x52c09d['id'],'createdAt':_0x52c09d['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['_replaceEditorDataWithRevisionData'](_0x3ccc4f,_0xc533a5){let _0x32589d=this['editor']['config']['get']('initialData'),_0x2c1e3b=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x32589d){_0x32589d={};for(const _0x35088e of this['editor']['model']['document']['getRootNames']())_0x32589d[_0x35088e]='';}if('string'==typeof _0x32589d&&(_0x32589d={'main':_0x32589d}),void 0x0===_0x2c1e3b){_0x2c1e3b={};for(const _0x1fb87b of this['editor']['model']['document']['getRootNames']())_0x2c1e3b[_0x1fb87b]={};}let _0x57631b=!0x1;const _0x480255=Object['keys'](_0x32589d),_0x5bf505=Object['keys'](_0x3ccc4f);for(const _0x38ad99 of _0x480255){if(_0x32589d[_0x38ad99]!==_0x3ccc4f[_0x38ad99]&&''!==_0x32589d[_0x38ad99]['trim']()){_0x57631b=!0x0;break;}if(!_0x93096c(_0x2c1e3b[_0x38ad99],_0xc533a5[_0x38ad99])&&Object['keys'](_0x2c1e3b[_0x38ad99])['length']>0x0){_0x57631b=!0x0;break;}}_0x57631b||(_0x57631b=_0x5bf505['some'](_0x58ef69=>!this['editor']['model']['document']['getRoot'](_0x58ef69))),_0x57631b&&_0x4d1e6d('editor-initial-data-replaced-with-revision-data',{'editorData':_0x32589d,'editorRootsAttributes':_0x2c1e3b,'revisionData':_0x3ccc4f,'revisionRootsAttributes':_0xc533a5}),this['editor']['config']['set']('initialData',_0x3ccc4f),this['editor']['config']['set']('rootsAttributes',_0xc533a5);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x53d17f=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x53d17f['add'](m(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x320b1c){const _0x2894d0=this['repository']['getRevisions']();_0x2894d0['reverse']();let _0x3ec7a9=0x0;for(;_0x3ec7a9<_0x2894d0['length'];){const _0x529e09=_0x2894d0[_0x3ec7a9];if(_0x529e09===this['currentRevision']){_0x3ec7a9++;continue;}if(_0x529e09['id']===this['_initialRevisionId'])break;const _0x5bce25=_0x320b1c['toVersion']-_0x529e09['toVersion']||_0x320b1c['fromVersion']-_0x529e09['fromVersion'];if(_0x5bce25>0x0)break;if(_0x5bce25<0x0)_0x3ec7a9++;else{if(!_0x320b1c['creator']&&_0x529e09['creator'])break;if(_0x529e09['creator']||!_0x320b1c['creator']){if(_0x320b1c['createdAt']>_0x529e09['createdAt'])break;_0x3ec7a9++;}else _0x3ec7a9++;}}return _0x3ec7a9;}['setRevisionData'](_0x499a43){const _0xc16ead=this['repository']['getRevision'](_0x499a43['id']);if(_0x499a43['createdAt']&&(_0x499a43['createdAt']=new Date(_0x499a43['createdAt'])),_0x499a43['authorsIds']){const _0x14ecd2=this['editor']['plugins']['get']('Users');_0x499a43['authors']=_0x499a43['authorsIds']['map'](_0x435854=>_0x14ecd2['getUser'](_0x435854));}_0xc16ead['_update'](_0x499a43,!0x0);}['buildRevisionData']({revision:_0x3942b7=null,from:_0x3f8dae=null,to:_0xcf052c=null}){_0x3f8dae=null!==_0x3f8dae?_0x3f8dae:_0x3942b7['fromVersion'],_0xcf052c=null!==_0xcf052c?_0xcf052c:_0x3942b7['toVersion'];const _0x3419e8=this['_revisionDataBuilder']['getData'](_0x3f8dae,_0xcf052c),_0x135250={'diffData':_0x3419e8['diffData'],'authorsIds':_0x3419e8['authorsIds'],'fromVersion':_0x3f8dae,'toVersion':_0xcf052c};if(!_0x3942b7||_0xcf052c!==_0x3942b7['toVersion']){const _0x58e2aa=_0xcf052c-0x1,_0x426204=this['_source']['history']['getOperation'](_0x58e2aa);_0x135250['createdAt']=_0x426204&&_0x426204['createdAt']||new Date();}if(this['_loadedStateData']&&_0x3f8dae===this['_loadedStateData']['fromVersion']){for(const _0x4ade84 of this['_loadedStateData']['authors'])_0x135250['authorsIds']['includes'](_0x4ade84['id'])||_0x135250['authorsIds']['push'](_0x4ade84['id']);}return _0x135250;}['_loadRevisionData'](_0x3f2781){if(!_0x3f2781||_0x3f2781['diffData'])return Promise['resolve']();{const _0xa60a4=this['editor']['config']['get']('collaboration.channelId');return this['adapter']['getRevision']({'channelId':_0xa60a4,'revisionId':_0x3f2781['id']})['then'](_0xb3816c=>{_0x3f2781['diffData']=_0xb3816c['diffData'];});}}['_bufferUpdate'](_0x3989e6,_0x4522c4,_0x544936){if(this['_bufferedUpdates']['has'](_0x3989e6)){const _0x574f8d=this['_bufferedUpdates']['get'](_0x3989e6);_0x4522c4=_0x544936?{..._0x574f8d,..._0x4522c4}:{..._0x4522c4,..._0x574f8d};}this['_bufferedUpdates']['set'](_0x3989e6,_0x4522c4);}['_getFromVersion'](_0x49a840){const _0x32322c=this['repository']['getRevisions']();_0x32322c['reverse'](),_0x32322c['shift']();const _0x403ab9=_0x32322c['find'](_0x1a46d5=>_0x1a46d5['toVersion']<=_0x49a840)['toVersion'];return _0x403ab9<this['_startingVersion']?this['_startingVersion']:_0x403ab9;}['_createInitialRevision'](_0x329b68){const _0x24725e=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x24725e)this['_initialRevisionId']=_0x24725e['id'];else{const _0x5189e7=!this['editor']['model']['document']['roots']['find'](_0x2c6a2c=>this['editor']['model']['hasContent'](_0x2c6a2c)),_0x190cf9=this['editor']['plugins']['get']('Users')['me']['id'],_0x7f0a21=m(this['editor']['locale'],_0x5189e7?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x329b68,'to':_0x329b68,'id':this['_initialRevisionId'],'name':_0x7f0a21,'creatorId':_0x190cf9});}}['_createCurrentRevision'](_0x5bf29b){const _0x455fc9=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x455fc9),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x5bf29b,'to':_0x5bf29b,'id':_0x455fc9,'name':'','creatorId':null}));}['_makeRevision']({name:_0x575ae6,from:_0x3264bd,to:_0x3934c8,creatorId:_0x505018,id:_0x51f6e5}){const _0x4fba11=this['buildRevisionData']({'from':_0x3264bd,'to':_0x3934c8});_0x4fba11['name']=_0x575ae6,_0x4fba11['creatorId']=_0x505018,_0x4fba11['id']=_0x51f6e5;const _0x3bc564=this['addRevisionData'](_0x4fba11);return this['adapter']&&this['_bufferUpdate'](_0x4fba11['id'],_0x4fba11,!0x0),_0x3bc564;}['_setConversion'](){this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'});}['_removeRevisionMarkers'](_0x16df9b){return(_0x16df9b=_0x16df9b['filter'](_0xe0865=>!_0xe0865['name']||'revision-start'!==_0xe0865['name']&&'revision-end'!==_0xe0865['name']))['forEach'](_0x2d395b=>{'string'!=typeof _0x2d395b&&(_0x2d395b['children']=this['_removeRevisionMarkers'](_0x2d395b['children']),_0x2d395b['attributes']=_0x2d395b['attributes']['filter'](_0x59f73d=>!_0x59f73d[0x0]['startsWith']('data-revision-')));}),_0x16df9b;}}function P(_0xfecd9d,_0x331ebb){const _0x515bdd=_0x331ebb['editing']['view']['document'];if('string'==typeof _0xfecd9d)return new _0x5b5f30(_0x515bdd,_0xfecd9d);{const _0x518d44=_0xfecd9d['children']['map'](_0x33c9d5=>P(_0x33c9d5,_0x331ebb));return new(E[_0xfecd9d['type']]||_0x5aa52f)(_0x515bdd,_0xfecd9d['name'],_0xfecd9d['attributes'],_0x518d44);}}class V{['editor'];['source'];['_savedMetaData'];['_lastFrom'];['_lastTo'];['_markers'];['_diffRoots'];['_diffRootsAttributes'];['_baseRoots'];['_baseRootsAttributes'];['_idsRoots'];['_baseIdsRoots'];['_touched'];['_touchedMarkers'];['_touchedRoots'];['_revisionId'];['_startingRevisionId'];constructor(_0x253b96){this['editor']=_0x253b96,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'](_0x3dbe5e){this['source']=_0x3dbe5e;const _0x44a915=new Map(),_0x42b341=new Map(),_0x361338=this['editor']['model']['document']['roots']['map'](_0x156523=>_0x156523['rootName']);for(const _0xab164d of _0x361338){const _0x1f6f10=this['editor']['model']['document']['getRoot'](_0xab164d),_0x408791=T(_0x1f6f10);_0x44a915['set'](_0xab164d,_0x408791),_0x42b341['set'](_0xab164d,Object['fromEntries'](_0x1f6f10['getAttributes']()));}const _0x4e6a4e=Array['from'](this['editor']['model']['markers'])['map'](_0x62d997=>[_0x62d997['name'],_0x62d997['getRange']()]),_0x470f3e=this['source']['version'];this['_saveMetaData'](_0x470f3e,_0x44a915,_0x4e6a4e,_0x42b341),this['_startingRevisionId']=this['_revisionId'];const _0x305015=new Map(),_0x3b4197=new Map();for(const _0x6eafbd of _0x361338){const _0x468f88=F(_0x6eafbd);_0x305015['set'](_0x6eafbd,_0x468f88),_0x3b4197['set'](_0x6eafbd,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x305015,[],_0x3b4197);}['getData'](_0x1ff16d,_0x358144){if(this['_lastFrom']===_0x1ff16d&&this['_lastTo']<=_0x358144)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x358144,!0x0);else{if(!this['_savedMetaData']['has'](_0x1ff16d)){const _0x2de812=this['_getPreviousFrom'](_0x1ff16d);this['_calculateMetaData'](_0x2de812,_0x1ff16d,!0x1);}this['_calculateMetaData'](_0x1ff16d,_0x358144,!0x0);}return this['_lastFrom']=_0x1ff16d,this['_lastTo']=_0x358144,this['_getState']();}['loadState'](_0x3d6085){this['_reset'](),this['_lastFrom']=_0x3d6085['fromVersion'],this['_lastTo']=_0x3d6085['toVersion'];for(const _0x35a34a in _0x3d6085['diffData']){const _0xf85110=_0x3d6085['diffData'][_0x35a34a]['attachChange'],_0x4c8da1=_0x4abf57(_0x3d6085['diffData'][_0x35a34a]['attributesBefore'])||{},_0x17d85b=this['_makeModelFromViewString'](_0x3d6085['diffData'][_0x35a34a]['deletions']);_0x17d85b['rootName']=_0x35a34a,_0x17d85b['_isAttached']=!_0xf85110||!_0xf85110['isAttached'],_0x17d85b['isAttached']=()=>_0x17d85b['_isAttached'],this['_baseRoots']['set'](_0x35a34a,_0x17d85b),this['_baseRootsAttributes']['set'](_0x35a34a,_0x4c8da1),_0xf85110&&this['_touchedRoots']['set'](_0x35a34a,_0xf85110);const _0x251d38=this['_makeIdsRoot'](_0x17d85b);this['_baseIdsRoots']['set'](_0x35a34a,_0x251d38);for(const [_0x53c437,_0x9dd1cd]of _0x17d85b['markers']){if(!_0x53c437['startsWith']('revision:'))continue;const _0x2ec562=_0x53c437['split'](':')[0x2];for(const _0x2e83f7 of _0x9dd1cd['getWalker']({'singleCharacters':!0x0})){const _0x1885bb=this['_getVidAttributeName'](_0x2e83f7),_0x55b3f6='elementEnd'==_0x2e83f7['type']?_0x2e83f7['previousPosition']['path']['slice'](0x0,-0x1):_0x2e83f7['previousPosition']['path'],_0x492274=_0x251d38['getNodeByPath'](_0x55b3f6)['getAttribute'](_0x1885bb);this['_touched']['set'](_0x492274,{'userId':_0x2ec562});}}}this['_startingRevisionId']=this['_revisionId'];const _0x55a177=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x37e8dc=>!this['_touched']['has'](_0x37e8dc));let _0x11a3ee=0x0;const _0x26b573=new Map();for(const _0x5ad722 in _0x3d6085['diffData']){const _0x2dca36=_0x3d6085['diffData'][_0x5ad722]['attachChange'],_0x44353e=_0x4abf57(_0x3d6085['diffData'][_0x5ad722]['attributesAfter'])||{},_0x2c502c=this['_makeModelFromViewString'](_0x3d6085['diffData'][_0x5ad722]['insertions']);_0x2c502c['rootName']=_0x5ad722,_0x2c502c['_isAttached']=!_0x2dca36||_0x2dca36['isAttached'],_0x2c502c['isAttached']=()=>_0x2c502c['_isAttached'],this['_diffRoots']['set'](_0x5ad722,_0x2c502c),this['_diffRootsAttributes']['set'](_0x5ad722,_0x44353e);const _0xe8b2f6=this['_makeIdsRoot'](_0x2c502c,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x5ad722,_0xe8b2f6),_0x26b573['set'](_0x5ad722,_0x2c502c['isAttached']()?_0x44353e:{});for(const [_0x1ac178,_0x467eba]of _0x2c502c['markers']){if(!_0x1ac178['startsWith']('revision:'))continue;const _0x3695d9=_0x1ac178['split'](':')[0x2];for(const _0x11da4a of _0x467eba['getWalker']({'singleCharacters':!0x0})){const _0x559e6b=this['_getVidAttributeName'](_0x11da4a),_0x8d0b40=this['_revisionId']++,_0x1eb9d2='elementEnd'==_0x11da4a['type']?_0x11da4a['previousPosition']['path']['slice'](0x0,-0x1):_0x11da4a['previousPosition']['path'];_0xe8b2f6['getNodeByPath'](_0x1eb9d2)['_setAttribute'](_0x559e6b,_0x8d0b40),this['_touched']['set'](_0x8d0b40,{'userId':_0x3695d9});}}for(const _0x47344c of this['editor']['model']['createRangeIn'](_0x2c502c)['getWalker']({'singleCharacters':!0x0})){const _0x12659d=this['_getVidAttributeName'](_0x47344c),_0x205823='elementEnd'==_0x47344c['type']?_0x47344c['previousPosition']['path']['slice'](0x0,-0x1):_0x47344c['previousPosition']['path'],_0x4bf3fd=_0xe8b2f6['getNodeByPath'](_0x205823);_0x4bf3fd['getAttribute'](_0x12659d)>0x0||_0x4bf3fd['_setAttribute'](_0x12659d,_0x55a177[_0x11a3ee++]);}for(const [_0xefc02a,_0x31e536]of _0x2c502c['markers'])_0xefc02a['startsWith']('revision:')||this['_markers']['set'](_0xefc02a,_0x31e536);}const _0x2d025a=F('$graveyard');this['_baseRoots']['set']('$graveyard',_0x2d025a),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x2d025a,0x1));const _0x2a6a48=F('$graveyard');this['_diffRoots']['set']('$graveyard',_0x2a6a48),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x2a6a48,0x1));const _0xb14a59=Array['from'](this['_diffRoots'])['map'](([_0x464587,_0x10076d])=>[_0x464587,T(_0x10076d)]);this['_saveMetaData'](this['_lastTo'],_0xb14a59,this['_markers'],_0x26b573);}['_makeModelFromViewString'](_0x3a8972){const _0x207fde=JSON['parse'](_0x3a8972),_0x256d9f=this['editor']['editing']['view']['document'],_0x1f47aa=new _0x1c9f86(_0x256d9f,_0x207fde['map'](_0x42d3d7=>P(_0x42d3d7,this['editor'])));return this['editor']['data']['toModel'](_0x1f47aa);}['_saveMetaData'](_0x2ceb21,_0x50d1d9,_0x2edca,_0xaa2367){const _0x57f17d=new Map(_0x50d1d9),_0x3ca228=new Map(_0x4abf57(_0xaa2367)),_0x40b863=new Map();for(const [_0x5a0884,_0x175d43]of _0x2edca)_0x40b863['set'](_0x5a0884,{'start':_0x175d43['start']['clone'](),'end':_0x175d43['end']['clone'](),'rootName':_0x175d43['root']['rootName']});this['_savedMetaData']['set'](_0x2ceb21,{'roots':_0x57f17d,'markers':_0x40b863,'rootsAttributes':_0x3ca228});}['_removeMetaData'](_0x313b8d){this['_savedMetaData']['delete'](_0x313b8d);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_reset'](){this['_touched']['clear'](),this['_touchedMarkers']['clear'](),this['_touchedRoots']['clear'](),this['_diffRoots']['clear'](),this['_diffRootsAttributes']['clear'](),this['_baseRoots']['clear'](),this['_baseRootsAttributes']['clear'](),this['_idsRoots']['clear'](),this['_baseIdsRoots']['clear'](),this['_markers']['clear'](),this['_revisionId']=0x1,this['_startingRevisionId']=this['_revisionId'];}['_makeIdsRoot'](_0xd88c23,_0x314c10=null){let _0x377a81=null;_0xd88c23['is']('documentFragment')||(_0x377a81=new ut(_0xd88c23['name'],{'vid_start':null===_0x314c10?this['_revisionId']++:_0x314c10++}));const _0x31dc0a=[];for(const _0x50a1c9 of _0xd88c23['getChildren']())if(_0x50a1c9['is']('element')){_0x31dc0a['push'](this['_makeIdsRoot'](_0x50a1c9,_0x314c10));const _0x507479=_0x31dc0a[_0x31dc0a['length']-0x1];null!==_0x314c10&&(_0x314c10=_0x507479['is']('element','$text')?_0x507479['getAttribute']('vid')+0x1:_0x507479['getAttribute']('vid_end')+0x1);}else{for(let _0x1bd5e4=0x0;_0x1bd5e4<_0x50a1c9['offsetSize'];_0x1bd5e4++)_0x31dc0a['push'](new ut('$text',{'vid':null===_0x314c10?this['_revisionId']++:_0x314c10++}));}if(_0xd88c23['is']('documentFragment')){const _0x57038e=F(_0xd88c23['rootName']);return _0x57038e['_insertChild'](0x0,_0x31dc0a),_0x57038e;}return _0x377a81['_setAttribute']('vid_end',null===_0x314c10?this['_revisionId']++:_0x314c10++),_0x377a81['_insertChild'](0x0,_0x31dc0a),_0x377a81;}['_calculateMetaData'](_0x5ea4b0,_0x1cdf66,_0x2b65a2){this['_reset']();const {roots:_0x49f556,markers:_0x5b236f,rootsAttributes:_0x270d79}=this['_savedMetaData']['get'](_0x5ea4b0);this['_baseRoots']=new Map(_0x49f556),this['_baseRootsAttributes']=new Map(_0x4abf57(_0x270d79));for(const [_0x48a684,_0x4e1045]of this['_baseRoots'])if('$graveyard'!==_0x48a684&&(this['_diffRoots']['set'](_0x48a684,T(_0x4e1045)),this['_diffRootsAttributes']=new Map(_0x4abf57(_0x270d79)),_0x2b65a2)){const _0x59c5d7=this['_revisionId'];this['_idsRoots']['set'](_0x48a684,this['_makeIdsRoot'](_0x4e1045)),this['_baseIdsRoots']['set'](_0x48a684,this['_makeIdsRoot'](_0x4e1045,_0x59c5d7));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',T(this['_baseRoots']['get']('$graveyard'))),_0x2b65a2&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0xb0e037,_0x4603c2]of _0x5b236f){const _0x165635=this['_baseRoots']['get'](_0x4603c2['rootName']),_0x3c6322=this['_diffRoots']['get'](_0x4603c2['rootName']),_0x22303=new ft(this['_fixPosition'](_0x4603c2['start'],_0x165635),this['_fixPosition'](_0x4603c2['end'],_0x165635)),_0x16b171=this['_fixRange'](_0x22303,_0x3c6322);_0x165635['markers']['set'](_0xb0e037,_0x22303),this['_markers']['set'](_0xb0e037,_0x16b171);}this['_applyOperations'](_0x5ea4b0,_0x1cdf66,_0x2b65a2);}['_applyOperations'](_0x43812f,_0x16230f,_0xaab519){for(const _0x252517 of this['source']['getOperations'](_0x43812f,_0x16230f))this['_handleOperation'](_0x252517,_0xaab519);for(const _0x5587cc of this['_diffRoots']['values']())_0x5587cc['markers']['clear']();for(const [_0x108883,_0x13a072]of this['_markers']){this['_diffRoots']['get'](_0x13a072['root']['rootName'])['markers']['set'](_0x108883,_0x13a072['clone']());}const _0x4f5ed7=new Map(),_0xb2d693=new Map();for(const [_0x8a6955,_0x2ccab1]of this['_diffRoots'])_0x4f5ed7['set'](_0x8a6955,T(_0x2ccab1)),_0xb2d693['set'](_0x8a6955,this['_diffRootsAttributes']['get'](_0x8a6955));this['_saveMetaData'](_0x16230f,_0x4f5ed7,this['_markers'],_0xb2d693);}['_getPreviousFrom'](_0x5dae33){const _0x5ab94e=Array['from'](this['_savedMetaData']['keys']());_0x5ab94e['sort']((_0x3e18b4,_0x4c670c)=>_0x3e18b4-_0x4c670c),_0x5ab94e['reverse']();for(const _0x5756a3 of _0x5ab94e)if(_0x5756a3<_0x5dae33)return _0x5756a3;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0xc3a817,_0x158991){const _0x54899f=Array['from'](_0x158991['markers'])['map'](([_0x551ae0,_0x1aa909])=>[_0x551ae0,this['_fixRange'](_0x1aa909,_0xc3a817)]);_0xc3a817['markers']=new Map(_0x54899f);}['_transformMarkers'](_0x279e91){for(const _0x63097 of this['_markers']['values']()){const _0x418e89=_0x63097['getTransformedByOperation'](_0x279e91),_0x3d7022=ft['_createFromRanges'](_0x418e89);_0x63097['start']=_0x3d7022['start'],_0x63097['end']=_0x3d7022['end'];}}['_handleOperation'](_0x1f4b29,_0x178b2a){if('addRoot'!=_0x1f4b29['type']&&'detachRoot'!=_0x1f4b29['type']){if('insert'==_0x1f4b29['type']){const _0x218b31=_0x1f4b29['position']['root']['rootName'];this['_diffRoots']['has'](_0x218b31)||(this['_diffRoots']['set'](_0x218b31,F(_0x218b31,!0x0)),this['_diffRootsAttributes']['set'](_0x218b31,{}),_0x178b2a&&this['_idsRoots']['set'](_0x218b31,F(_0x218b31,!0x0)));}else{if('addRootAttribute'==_0x1f4b29['type']||'removeRootAttribute'==_0x1f4b29['type']||'changeRootAttribute'==_0x1f4b29['type'])return void this['_handleRootAttributeOperation'](_0x1f4b29);'marker'==_0x1f4b29['type']&&this['_handleMarkerOperation'](_0x1f4b29);}if('marker'!==_0x1f4b29['type']){const _0x3c44e1=this['_cloneOperation'](_0x1f4b29,this['_diffRoots']);_0x3c44e1['_execute'](),this['_transformMarkers'](_0x3c44e1);}if(_0x178b2a)switch(_0x1f4b29['type']){case'insert':this['_handleInsertOperation'](_0x1f4b29);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x1f4b29);break;case'merge':this['_handleMergeOperation'](_0x1f4b29);break;case'split':this['_handleSplitOperation'](_0x1f4b29);}}else this['_handleRootOperation'](_0x1f4b29,_0x178b2a);}['_cloneOperation'](_0x4b8d79,_0x5b3ea1){const _0x2e36e2=_0x4b8d79['clone']();return _0x2e36e2['_authorId']=_0x4b8d79['_authorId'],this['_fixOperation'](_0x2e36e2,_0x5b3ea1),_0x2e36e2;}['_getBaseVids'](_0x5ba3db){return _0x5ba3db['map'](_0x48559d=>{const _0x833f12=this['_getVidAttributeName'](_0x48559d);return Number(_0x48559d['item']['getAttribute'](_0x833f12));});}['_generateTape'](_0x2d8350,_0x1de3ac){if(_0x2d8350['is']('element','$text'))_0x1de3ac['push']({'item':_0x2d8350,'type':'text'});else{_0x2d8350['is']('element')&&_0x1de3ac['push']({'item':_0x2d8350,'type':'elementStart'});for(const _0x2805bb of _0x2d8350['getChildren']())this['_generateTape'](_0x2805bb,_0x1de3ac);_0x2d8350['is']('element')&&_0x1de3ac['push']({'item':_0x2d8350,'type':'elementEnd'});}return _0x1de3ac;}['_getState'](){const _0x396923=new Map(this['_touched']),_0x745e2=new Map(_0x396923),_0x17c815=new Map(),_0x365bf9={'insertions':{},'deletions':{}},_0x39c1aa={'insertions':{},'deletions':{}},_0x2edca5=new Map(),_0x37e919=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x37e919['delete']('$graveyard');for(const _0x402cf2 of _0x37e919){const _0x1c1282=this['_diffRoots']['get'](_0x402cf2)||F(_0x402cf2,!0x1),_0x534f52=this['_baseRoots']['get'](_0x402cf2)||F(_0x402cf2,!0x1);_0x1c1282['isAttached']()||_0x534f52['isAttached']()?(_0x365bf9['insertions'][_0x402cf2]=T(_0x1c1282),_0x365bf9['deletions'][_0x402cf2]=T(_0x534f52),this['_copyMarkers'](_0x365bf9['deletions'][_0x402cf2],_0x534f52),this['_copyMarkers'](_0x365bf9['insertions'][_0x402cf2],_0x1c1282),_0x39c1aa['insertions'][_0x402cf2]=this['_generateTape'](this['_idsRoots']['get'](_0x402cf2),[]),_0x39c1aa['deletions'][_0x402cf2]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x402cf2)||F(_0x402cf2,!0x1),[])):_0x37e919['delete'](_0x402cf2);}for(const _0x2aa38f of _0x37e919){const _0x51d097=_0x39c1aa['insertions'][_0x2aa38f];for(const _0x355db5 of _0x51d097){const _0x92e6e8=this['_getVidAttributeName'](_0x355db5),_0x363207=_0x355db5['item']['getAttribute'](_0x92e6e8);_0x745e2['delete'](_0x363207),_0x363207>=this['_startingRevisionId']&&_0x17c815['set'](_0x363207,_0x396923['get'](_0x363207));}}for(const _0x294908 of _0x37e919){const _0x315902=_0x39c1aa['insertions'][_0x294908],_0x12c544=this['_getBaseVids'](_0x39c1aa['deletions'][_0x294908]);let _0x15b108=0x0;for(const _0x588ba2 of _0x315902){const _0x7db122=this['_getVidAttributeName'](_0x588ba2),_0x50e62a=_0x588ba2['item']['getAttribute'](_0x7db122);if(!_0x17c815['has'](_0x50e62a)&&!_0x2edca5['has'](_0x50e62a)){if(_0x745e2['has'](_0x50e62a))_0x15b108++;else{if(_0x50e62a!=_0x12c544[_0x15b108]){const _0x2ee8eb=_0x396923['get'](_0x50e62a)||_0x396923['get'](_0x12c544[_0x15b108]);for(;_0x50e62a!=_0x12c544[_0x15b108];)_0x745e2['has'](_0x12c544[_0x15b108])||(_0x2edca5['set'](_0x12c544[_0x15b108],_0x2ee8eb),_0x396923['set'](_0x12c544[_0x15b108],_0x2ee8eb)),_0x15b108++;}_0x15b108++;}}}}for(const _0x5d549e of _0x37e919){const _0x17bcee=_0x39c1aa['insertions'][_0x5d549e];for(const _0x2c31a4 of _0x17bcee){const _0x2ac822=this['_getVidAttributeName'](_0x2c31a4),_0x5dbf40=_0x2c31a4['item']['getAttribute'](_0x2ac822);if(_0x2edca5['has'](_0x5dbf40)){const _0x29fced=_0x2edca5['get'](_0x5dbf40);_0x745e2['has'](_0x5dbf40)||_0x745e2['set'](_0x5dbf40,{..._0x29fced}),_0x17c815['set'](_0x5dbf40,{..._0x29fced});}}}for(const _0x10545e of _0x745e2['keys']())_0x10545e>=this['_startingRevisionId']&&_0x745e2['delete'](_0x10545e);const _0x30eb10=new Map();for(const _0xf12888 of _0x37e919){let _0x2ef5e0=_0x39c1aa['insertions'][_0xf12888];for(const _0x40035e of _0x2ef5e0)if(_0x40035e['item']['is']('element','tableCell')){const _0x2ea1bd=this['_getVidAttributeName'](_0x40035e),_0x25b019=_0x40035e['item']['getAttribute'](_0x2ea1bd);if(_0x17c815['has'](_0x25b019)){const _0x14871e=_0x40035e['item']['parent']['parent']['getAttribute']('vid_start'),_0x2411a4=_0x30eb10['get'](_0x14871e)||new Set();_0x2411a4['add'](_0x17c815['get'](_0x25b019)['userId']),_0x30eb10['set'](_0x14871e,_0x2411a4);}}_0x2ef5e0=_0x39c1aa['deletions'][_0xf12888];for(const _0x25a868 of _0x2ef5e0)if(_0x25a868['item']['is']('element','tableCell')){const _0x5ad9d1=this['_getVidAttributeName'](_0x25a868),_0x525967=_0x25a868['item']['getAttribute'](_0x5ad9d1);if(_0x745e2['has'](_0x525967)){const _0x130085=_0x25a868['item']['parent']['parent']['getAttribute']('vid_start'),_0x3c4d7e=_0x30eb10['get'](_0x130085)||new Set();_0x3c4d7e['add'](_0x745e2['get'](_0x525967)['userId']),_0x30eb10['set'](_0x130085,_0x3c4d7e);}}for(const _0x13fbed of _0x30eb10['keys']())(_0x17c815['has'](_0x13fbed)||_0x745e2['has'](_0x13fbed))&&_0x30eb10['delete'](_0x13fbed);}for(const _0x195871 of _0x37e919){const _0x16cfcd=_0x39c1aa['insertions'][_0x195871];let _0x235346=null,_0x370170=null;for(const _0x33f834 of _0x16cfcd){const _0x2414c3=this['_getVidAttributeName'](_0x33f834),_0x5743fe=_0x33f834['item']['getAttribute'](_0x2414c3),_0x418c43=_0x30eb10['get'](_0x5743fe);_0x418c43&&'elementStart'==_0x33f834['type']&&(_0x235346=Array['from'](_0x418c43)[0x0],_0x370170=_0x33f834['item']['getAttribute']('vid_end')),_0x235346&&(_0x745e2['set'](_0x5743fe,{'userId':_0x235346}),_0x17c815['set'](_0x5743fe,{'userId':_0x235346})),_0x5743fe==_0x370170&&(_0x235346=null,_0x370170=null);}}const _0x336a01={},_0x4d7a51=new Set();for(const _0x7a9af5 of _0x37e919){const _0x58dded=_0x365bf9['deletions'][_0x7a9af5],_0x30753f=_0x365bf9['insertions'][_0x7a9af5];for(const {userId:_0x130bb0}of this['_touchedMarkers']['values']())null!==_0x130bb0&&_0x4d7a51['add'](_0x130bb0);for(const {userId:_0x1c92e0}of this['_touchedRoots']['values']())null!==_0x1c92e0&&_0x4d7a51['add'](_0x1c92e0);this['_markChanges'](_0x30753f,_0x39c1aa['insertions'][_0x7a9af5],_0x17c815,'insertion',_0x4d7a51),this['_markChanges'](_0x58dded,_0x39c1aa['deletions'][_0x7a9af5],_0x745e2,'deletion',_0x4d7a51),_0x336a01[_0x7a9af5]={'insertions':this['_prepareViewToSave'](_0x30753f),'deletions':this['_prepareViewToSave'](_0x58dded),'attachChange':this['_touchedRoots']['get'](_0x7a9af5)||null,'attributesBefore':_0x4abf57(this['_baseRootsAttributes']['get'](_0x7a9af5))||{},'attributesAfter':_0x4abf57(this['_diffRootsAttributes']['get'](_0x7a9af5))};}return{'diffData':_0x336a01,'authorsIds':Array['from'](_0x4d7a51)};}['_processRootBeforeSave'](_0x5b292a){for(const [,_0x47226f]of _0x5b292a['markers']){const _0x16baa7=_0x47226f['start']['getAncestors']()['filter'](_0x19a7fb=>'tableCell'==_0x19a7fb['name']);for(const _0x516075 of _0x16baa7)0x1==_0x516075['childCount']&&_0x516075['getChild'](0x0)['is']('element','paragraph')&&_0x516075['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x5bc040){this['_processRootBeforeSave'](_0x5bc040);const _0x4fb1cd=this['editor']['data']['toView'](_0x5bc040,{}),_0x5e7854=Array['from'](_0x4fb1cd['getChildren']())['map'](_0x2fd3c3=>this['_getViewJson'](_0x2fd3c3));return JSON['stringify'](_0x5e7854);}['_getViewJson'](_0x49ef5b){if(_0x49ef5b['is']('$text'))return _0x49ef5b['data'];{const _0x10762b=_0x49ef5b;return{'type':Object['keys'](E)['find'](_0x528d6=>_0x49ef5b instanceof E[_0x528d6]),'name':_0x10762b['name'],'attributes':Array['from'](_0x10762b['getAttributes']()),'children':Array['from'](_0x10762b['getChildren']())['map'](_0x57d192=>this['_getViewJson'](_0x57d192))};}}['_markChanges'](_0x21946e,_0x4525f8,_0x5ecc02,_0x5f0ad9,_0x421437){let _0x27e7ae=null,_0x596abf=null,_0x1f8a0d=0x0;const _0x4368d0=this['editor']['model'];for(let _0x6dfbee=0x0;_0x6dfbee<_0x4525f8['length'];_0x6dfbee++){const _0x3be68f=this['_getVidAttributeName'](_0x4525f8[_0x6dfbee]),_0x55367c=_0x4525f8[_0x6dfbee]['item']['getAttribute'](_0x3be68f),_0x415135=_0x5ecc02['get'](_0x55367c),_0x4f5d63=_0x6dfbee==_0x4525f8['length']-0x1;(!_0x27e7ae&&_0x415135&&(_0x27e7ae=_0x415135,_0x596abf=_0x4525f8[_0x6dfbee]),_0x27e7ae&&(!_0x415135||_0x415135['userId']!=_0x27e7ae['userId']))&&(_0x1079d6(_0x415135,B(_0x596abf,_0x21946e,_0x4368d0),B(_0x4525f8[_0x6dfbee],_0x21946e,_0x4368d0)),_0x27e7ae=_0x415135||null,_0x596abf=_0x415135?_0x4525f8[_0x6dfbee]:null),_0x27e7ae&&_0x4f5d63&&_0x1079d6(_0x415135,B(_0x596abf,_0x21946e,_0x4368d0),J(_0x4525f8[_0x6dfbee],_0x21946e,_0x4368d0));}function _0x1079d6(_0x23bffb,_0x4a3f76,_0x40cfcf){const _0x48b659=_0x27e7ae['userId'],_0x5ea22f='revision:'+_0x5f0ad9+':'+_0x48b659+':'+_0x1f8a0d++,_0x1c8d82=_0x4368d0['createRange'](_0x4a3f76,_0x40cfcf);_0x21946e['markers']['set'](_0x5ea22f,_0x1c8d82),null!==_0x48b659&&_0x421437['add'](_0x48b659);}}['_getVidAttributeName'](_0x530a4a){switch(_0x530a4a['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x57b44b,_0x488caa){_0x57b44b['baseVersion']=null;for(const _0x5d7b83 in _0x57b44b){const _0x201869=_0x57b44b[_0x5d7b83];if(_0x201869 instanceof vt){const _0x47c8d4=_0x488caa['get'](_0x201869['root']['rootName']);_0x57b44b[_0x5d7b83]=this['_fixPosition'](_0x201869,_0x47c8d4);}if(_0x201869 instanceof ft){const _0x5d9648=_0x488caa['get'](_0x201869['root']['rootName']);_0x57b44b[_0x5d7b83]=this['_fixRange'](_0x201869,_0x5d9648);}'root'===_0x5d7b83&&(_0x57b44b['root']=_0x488caa['get'](_0x57b44b['root']['rootName']));}}['_fixRange'](_0x2b3d14,_0x28fd6d){return this['editor']['model']['createRange'](this['_fixPosition'](_0x2b3d14['start'],_0x28fd6d),this['_fixPosition'](_0x2b3d14['end'],_0x28fd6d));}['_fixPosition'](_0x5aee37,_0x86393b){return this['editor']['model']['createPositionFromPath'](_0x86393b,_0x5aee37['path'],_0x5aee37['stickiness']);}['_handleInsertOperation'](_0x52cf1e){const _0x98f835=this['_idsRoots']['get'](_0x52cf1e['position']['root']['rootName']),_0x24d23f=this['_fixPosition'](_0x52cf1e['position'],_0x98f835),_0x535574=null===_0x52cf1e['_authorId']?null:_0x52cf1e['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x245d04=_0x24d23f['parent'],_0x28b128=this['_revisionId'],_0x244362=[];for(const _0x205f49 of _0x52cf1e['nodes'])if(_0x205f49['is']('element'))_0x244362['push'](this['_makeIdsRoot'](_0x205f49));else{for(let _0x331a78=0x0;_0x331a78<_0x205f49['offsetSize'];_0x331a78++)_0x244362['push'](new ut('$text',{'vid':this['_revisionId']++}));}const _0x398279=this['_revisionId'];for(let _0x1937ea=_0x28b128;_0x1937ea<_0x398279;_0x1937ea++)this['_touched']['set'](_0x1937ea,{'userId':_0x535574});_0x245d04['_insertChild'](_0x24d23f['offset'],_0x244362);}['_handleMoveOperation'](_0x315c69){(_0x315c69=this['_cloneOperation'](_0x315c69,this['_idsRoots']))['_execute']();const _0x4e2dae=null===_0x315c69['_authorId']?null:_0x315c69['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x2735f6=_0x315c69['getMovedRangeStart'](),_0x1779cd=_0x2735f6['parent'],_0x61d9bd=_0x2735f6['offset'];!function _0x1db5f7(_0x141abd,_0x1c0274,_0x27e38c,_0x1596a8){for(let _0x5d7dbc=_0x27e38c;_0x5d7dbc<_0x1596a8;_0x5d7dbc++){const _0x205500=_0x1c0274['getChild'](_0x5d7dbc);_0x205500['is']('element','$text')?_0x141abd['set'](_0x205500['getAttribute']('vid'),{'userId':_0x4e2dae}):(_0x141abd['set'](_0x205500['getAttribute']('vid_start'),{'userId':_0x4e2dae}),_0x1db5f7(_0x141abd,_0x205500,0x0,_0x205500['childCount']),_0x141abd['set'](_0x205500['getAttribute']('vid_end'),{'userId':_0x4e2dae}));}}(this['_touched'],_0x1779cd,_0x61d9bd,_0x61d9bd+_0x315c69['howMany']);}['_handleMergeOperation'](_0x58cf02){const _0x3ccd24=null===(_0x58cf02=this['_cloneOperation'](_0x58cf02,this['_idsRoots']))['_authorId']?null:_0x58cf02['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x2dff03=_0x58cf02['targetPosition']['parent'],_0x5ef496=_0x58cf02['sourcePosition']['parent'],_0x10b4b9=_0x2dff03['getAttribute']('vid_end'),_0x220519=_0x5ef496['getAttribute']('vid_start');_0x2dff03['_setAttribute']('vid_end',_0x5ef496['getAttribute']('vid_end')),_0x5ef496['_setAttribute']('vid_end',_0x10b4b9),this['_touched']['set'](_0x220519,{'userId':_0x3ccd24}),this['_touched']['set'](_0x10b4b9,{'userId':_0x3ccd24}),_0x58cf02['_execute']();}['_handleSplitOperation'](_0x4a1960){const _0x38221e=null===(_0x4a1960=this['_cloneOperation'](_0x4a1960,this['_idsRoots']))['_authorId']?null:_0x4a1960['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x3f543f=_0x4a1960['graveyardPosition'],_0x4ae57b=_0x4a1960['splitPosition']['parent'];_0x4a1960['_execute']();const _0x4127b2=_0x4ae57b['getAttribute']('vid_end'),_0x2dda20=_0x4a1960['insertionPosition']['nodeAfter'];if(_0x3f543f){const _0x3a1f39=_0x2dda20['getAttribute']('vid_end'),_0xb5f910=_0x4ae57b['getAttribute']('vid_end');_0x4ae57b['_setAttribute']('vid_end',_0x3a1f39),_0x2dda20['_setAttribute']('vid_end',_0xb5f910),this['_touched']['set'](_0x4ae57b['getAttribute']('vid_end'),{'userId':_0x38221e}),this['_touched']['set'](_0x2dda20['getAttribute']('vid_start'),{'userId':_0x38221e});}else{const _0xf9875b=this['_revisionId']++,_0x9ef7bd=this['_revisionId']++;_0x4ae57b['_setAttribute']('vid_end',_0xf9875b),_0x2dda20['_setAttribute']('vid_start',_0x9ef7bd),_0x2dda20['_setAttribute']('vid_end',_0x4127b2),this['_touched']['set'](_0xf9875b,{'userId':_0x38221e}),this['_touched']['set'](_0x9ef7bd,{'userId':_0x38221e});}}['_handleMarkerOperation'](_0x46f007){if(!_0x46f007['affectsData'])return;const _0x127e21=(_0x46f007=this['_cloneOperation'](_0x46f007,this['_diffRoots']))['oldRange']?_0x46f007['oldRange']['root']:null,_0x5dacd1=_0x46f007['newRange']?_0x46f007['newRange']['root']:null;_0x127e21&&this['_markers']['delete'](_0x46f007['name']),_0x5dacd1&&this['_markers']['set'](_0x46f007['name'],_0x46f007['newRange']['clone']());const _0x3edccd=null===_0x46f007['_authorId']?null:_0x46f007['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x4be6cd=_0x46f007['name'];if(!this['_touchedMarkers']['has'](_0x4be6cd))return void this['_touchedMarkers']['set'](_0x4be6cd,{'range':_0x46f007['oldRange'],'userId':_0x3edccd});const _0x4cf259=this['_touchedMarkers']['get'](_0x4be6cd),_0x1f8dfb=_0x4cf259['range'],_0x491961=_0x46f007['newRange'];null==_0x1f8dfb&&null==_0x491961||_0x1f8dfb&&_0x491961&&_0x1f8dfb['isEqual'](_0x491961)?this['_touchedMarkers']['delete'](_0x46f007['name']):_0x4cf259['userId']=_0x3edccd;}['_handleRootOperation'](_0x54b357,_0x233cae){this['_diffRoots']['has'](_0x54b357['rootName'])?this['_diffRoots']['get'](_0x54b357['rootName'])['_isAttached']=_0x54b357['isAdd']:(this['_diffRoots']['set'](_0x54b357['rootName'],F(_0x54b357['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x54b357['rootName'],{}),_0x233cae&&this['_idsRoots']['set'](_0x54b357['rootName'],F(_0x54b357['rootName'],!0x0)));const _0x42b129=null===_0x54b357['_authorId']?null:_0x54b357['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x4fa242=this['_touchedRoots']['get'](_0x54b357['rootName']);_0x4fa242&&_0x4fa242['userId']===_0x42b129?this['_touchedRoots']['delete'](_0x54b357['rootName']):this['_touchedRoots']['set'](_0x54b357['rootName'],{'userId':_0x42b129,'isAttached':_0x54b357['isAdd']});}['_handleRootAttributeOperation'](_0x1cb202){const _0x2833b7=this['_diffRootsAttributes']['get'](_0x1cb202['root']['rootName']);null===_0x1cb202['newValue']?delete _0x2833b7[_0x1cb202['key']]:_0x2833b7[_0x1cb202['key']]=_0x1cb202['newValue'];}}function T(_0x51be5e){const _0x3b8d3b=F(_0x51be5e['rootName'],_0x51be5e['isAttached']());for(const _0x2ad4cd of _0x51be5e['getChildren']()){const _0x27543e=_0x2ad4cd['_clone'](!0x0);_0x3b8d3b['_appendChild'](_0x27543e);}return _0x3b8d3b;}function F(_0x5b7834,_0x321536=!0x0){const _0x921d9b=new gt();return _0x921d9b['rootName']=_0x5b7834,_0x921d9b['_isAttached']=_0x321536,_0x921d9b['isAttached']=()=>_0x921d9b['_isAttached'],_0x921d9b;}function B(_0x3f2419,_0x31e0c4,_0x3d9ce3){const _0x59ead3='elementEnd'==_0x3f2419['type']?_0x3d9ce3['createPositionAt'](_0x3f2419['item'],'end'):_0x3d9ce3['createPositionBefore'](_0x3f2419['item']);return _0x3d9ce3['createPositionFromPath'](_0x31e0c4,_0x59ead3['path'],_0x59ead3['stickiness']);}function J(_0x5e36cc,_0x497444,_0x3fdef9){const _0x1539ea='elementStart'==_0x5e36cc['type']?_0x3fdef9['createPositionAt'](_0x5e36cc['item'],0x0):_0x3fdef9['createPositionAfter'](_0x5e36cc['item']);return _0x3fdef9['createPositionFromPath'](_0x497444,_0x1539ea['path'],_0x1539ea['stickiness']);}class hs extends ts{['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x1acbf8,_0x5e183a){super(_0x1acbf8),this['focusTracker']=new _0x42db06(),this['keystrokes']=new _0x271894(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x5e183a),this['setTemplate']({'tag':'form','attributes':{'class':['ck','ck-revision-history-save-revision-form','ck-responsive-form'],'tabindex':'-1'},'children':[this['revisionNameInputView']]}),_0x482dd0(this);}['render'](){super['render'](),_0x25a94a({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x49ca71=_0x3e8692=>_0x3e8692['stopPropagation']();this['keystrokes']['set']('arrowright',_0x49ca71),this['keystrokes']['set']('arrowleft',_0x49ca71),this['keystrokes']['set']('arrowup',_0x49ca71),this['keystrokes']['set']('arrowdown',_0x49ca71);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x35461c){this['revisionNameInputView']['fieldView']['element']['value']=_0x35461c['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x23cb29){const _0x50b2d0=new _0x231adc(this['locale'],_0x433401),_0x523ce2=_0x50b2d0['fieldView'];_0x523ce2['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x571fc3=m(this['locale'],'Name\x20of\x20the\x20revision');return!_0x23cb29&&(_0x571fc3+='\x20('+m(this['locale'],'optional')+')'),(_0x50b2d0['label']=_0x571fc3,_0x523ce2['on']('input',()=>{this['revisionNameInputValue']=_0x523ce2['element']['value']['trim']();}),_0x50b2d0);}}class f extends _0x5517c8{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u];}['_saveRevisionFormView'];['init'](){const _0x2cf0e=this['editor'],_0x3bd2bf=_0x2cf0e['plugins']['get']('RevisionTracker');_0x2cf0e['ui']['componentFactory']['add']('revisionHistory',_0x9d8c00=>{const _0xd2d48f=_0x461af0(_0x9d8c00),_0x34b126=_0xd2d48f['panelView']['children'],_0x6bde38=new _0x396fe8(_0x9d8c00),_0x4e1c88=new _0x3b1ae9(_0x9d8c00),_0x1fd34b=new te(_0x9d8c00),_0x35964e=new _0x3b1ae9(_0x9d8c00),_0x11f38c=new te(_0x9d8c00);return _0xd2d48f['bind']('isEnabled')['to'](_0x3bd2bf,'isReady',_0x3bd2bf,'isEnabled',_0x2cf0e,'isReadOnly',(_0x2e8f62,_0x2bee29,_0x2213d3)=>_0x2e8f62&&_0x2bee29&&!_0x2213d3),_0xd2d48f['buttonView']['set']({'icon':_0x35cf4f,'label':m(_0x9d8c00,'Revision\x20history'),'tooltip':!0x0}),_0x1fd34b['set']({'label':m(_0x9d8c00,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x1fd34b['bind']('isEnabled')['to'](_0x3bd2bf,'isReady',_0x3bd2bf,'isEnabled',_0x2cf0e,'isReadOnly',(_0x1cd9c8,_0x4d080c,_0x7087a5)=>_0x1cd9c8&&_0x4d080c&&!_0x7087a5),_0x1fd34b['on']('execute',()=>this['_showDialog']()),_0x11f38c['set']({'label':m(_0x9d8c00,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x11f38c['bind']('isEnabled')['to'](_0x3bd2bf,'isReady',_0x2cf0e,'isReadOnly',(_0x3d05e9,_0x1b4d3b)=>_0x3d05e9&&!_0x1b4d3b),_0x11f38c['on']('execute',()=>{_0x2cf0e['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0xd2d48f['isOpen']=!0x1,_0x2cf0e['editing']['view']['focus']();}),_0x4e1c88['children']['add'](_0x1fd34b),_0x35964e['children']['add'](_0x11f38c),_0x6bde38['role']='menu',_0x6bde38['items']['addMany']([_0x4e1c88,_0x35964e]),_0x34b126['add'](_0x6bde38),_0xd2d48f;}),_0x2cf0e['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x41c393=this['editor'],_0x211e21=_0x41c393['locale'],_0x1b9957=new _0x428ca0(_0x211e21),_0x2e851c=new _0x183e56(_0x211e21);_0x1b9957['buttonView']['set']({'icon':_0x35cf4f,'label':m(_0x211e21,'Revision\x20history')});const _0x4d47f2=new _0x502dbc(_0x211e21,_0x1b9957),_0x76d935=new _0x53f0b7(_0x211e21);_0x76d935['set']({'label':m(_0x211e21,'Save\x20current\x20revision')}),_0x76d935['delegate']('execute')['to'](_0x1b9957),_0x76d935['on']('execute',()=>{this['_showDialog']();}),_0x4d47f2['children']['add'](_0x76d935),_0x2e851c['items']['add'](_0x4d47f2);const _0x55e0c3=new _0x502dbc(_0x211e21,_0x1b9957),_0x3970ca=new _0x53f0b7(_0x211e21);return _0x3970ca['set']({'label':m(_0x211e21,'Open\x20revision\x20history')}),_0x3970ca['delegate']('execute')['to'](_0x1b9957),_0x3970ca['on']('execute',()=>{_0x41c393['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x55e0c3['children']['add'](_0x3970ca),_0x2e851c['items']['add'](_0x55e0c3),_0x1b9957['panelView']['children']['add'](_0x2e851c),_0x1b9957;}['_showDialog'](){const _0x1a654f=this['editor'],_0x4c9950=_0x1a654f['locale'],_0x2f5efb=_0x1a654f['plugins']['get']('Dialog'),_0x21b94b=_0x1a654f['plugins']['get']('RevisionTracker');function _0xf65e04(_0x40ac66){_0x1a654f['config']['get']('revisionHistory.requireRevisionName')&&''===_0x40ac66['revisionName']?_0x40ac66['revisionNameInputView']['errorText']=m(_0x4c9950,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x1a654f['plugins']['get'](u)['saveRevision']({'name':_0x40ac66['revisionName']}),_0x2f5efb['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0xf65e04(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x2f5efb['show']({'id':'revisionSave','title':m(_0x4c9950,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':m(_0x1a654f['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x2f5efb['hide']()},{'label':m(_0x1a654f['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x5f2120){_0x5f2120['bind']('isEnabled')['to'](_0x21b94b,'isReady',_0x21b94b,'isEnabled',_0x1a654f,'isReadOnly',(_0x4c30fb,_0x3977ec,_0x5d8158)=>_0x4c30fb&&_0x3977ec&&!_0x5d8158);},'onExecute':()=>_0xf65e04(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x583aa2=this['editor'],_0x25ad75=_0x583aa2['locale'];this['_saveRevisionFormView']=new hs(_0x25ad75,_0x583aa2['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class X extends ts{['changeId'];['_model'];constructor(_0x339569,_0x50975b){super(_0x339569),this['_model']=_0x50975b,this['changeId']=_0x50975b['id'];const _0x5d846c=this['bindTemplate'],_0x36fcc9=m(_0x339569,_0x50975b['data']['isSuggestion']?'Suggested\x20by':'add'==_0x50975b['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x50975b['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x5d846c['to']('type',_0x20b0ea=>'ck-revision-change__'+_0x20b0ea)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x36fcc9}]},{'text':'\x20'+_0x50975b['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class r extends/* #__PURE__ -- @preserve */
|
|
25
|
-
_0x4f7caf(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x3a6ca3){super(),this['id']=_0x3a6ca3['id']||_0x3aad70(),this['author']=_0x3a6ca3['author'],this['type']=_0x3a6ca3['type'],this['data']=_0x3a6ca3['data']||{},this['rootName']=_0x3a6ca3['rootName'],this['set']('createdAt',_0x3a6ca3['createdAt']);}['toJSON'](){return{'id':this['id'],'authorId':this['author']['id'],'type':this['type'],'data':this['data'],'createdAt':this['createdAt']};}}class c{['newRevisionId'];['oldRevisionId'];['changes'];constructor(_0x2a5707,_0x775ff5){this['newRevisionId']=_0x2a5707,this['oldRevisionId']=_0x775ff5,this['changes']=new _0x1b37a4();}['_setChanges'](_0x308d80){for(const _0x4fef1b of _0x308d80)this['changes']['add'](_0x4fef1b);}}const Y={'c':_0x135f7f,'a':_0xf10c63,'e':_0xd2038a,'r':_0x35328c,'u':_0x5db413};class d extends _0x5517c8{['repository'];['adapter'];['_activeViewTarget'];['_changeView'];['_changeIdToChange'];['_balloon'];static get['pluginName'](){return'RevisionViewer';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[_0x49ffcb,_0x4abf6b,j];}constructor(_0x32cf89){super(_0x32cf89),this['repository']=this['editor']['plugins']['get']('RevisionsRepository'),this['set']('activeChange',null),this['set']('activeView',null),this['_activeViewTarget']=null,this['set']('diff',null),this['set']('isReady',!0x1),this['set']('isEnabled',!0x0),this['on']('change:isEnabled',(_0x3e5cbb,_0x589471,_0x38c186)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x4cedc3=>{for(const _0x432acd of this['editor']['editing']['view']['document']['roots'])_0x38c186?_0x4cedc3['removeClass']('ck-editor__editable__overlay',_0x432acd):_0x4cedc3['addClass']('ck-editor__editable__overlay',_0x432acd);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x9d6c78=>null!==_0x9d6c78),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x132079,_0x5cb937,_0x3047bd)=>_0x132079&&_0x3047bd?_0x5cb937['changes']['getIndex'](_0x3047bd):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x5c0390,_0x24edf2)=>_0x5c0390?_0x24edf2['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['adapter']=null,this['_balloon']=this['editor']['plugins']['get'](_0x4abf6b);}['init'](){const _0x322308=this['editor'],_0x1c55ed=new _t(_0x322308,{'direction':'backward'}),_0x3e96dc=new _t(_0x322308,{'direction':'forward'});(_0x322308['commands']['add']('showPreviousChange',_0x1c55ed),_0x322308['commands']['add']('showNextChange',_0x3e96dc),_0x322308['commands']['add']('restoreRevision',new wt(_0x322308)),this['on']('change:numberOfChanges',()=>{_0x1c55ed['refresh'](),_0x3e96dc['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x322308['enableReadOnlyMode']('revision-viewer'),_0x322308['plugins']['has']('WidgetToolbarRepository'))&&_0x322308['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionData'](_0x4d5e1e){await this['loadRevisionData'](_0x4d5e1e);const _0x16f5cd={};for(const _0x1b456a in _0x4d5e1e['diffData']){if(_0x4d5e1e['diffData'][_0x1b456a]['attachChange']&&!_0x4d5e1e['diffData'][_0x1b456a]['attachChange']['isAttached'])continue;const _0x44c5f2=this['_removeRevisionMarkers'](JSON['parse'](_0x4d5e1e['diffData'][_0x1b456a]['insertions'])),_0x463170=this['editor']['editing']['view']['document'],_0x3a2fab=new _0x1c9f86(_0x463170,_0x44c5f2['map'](_0x31c2b3=>this['_getViewObj'](_0x31c2b3)));this['editor']['data']['processor']['useFillerType']('marked'),_0x16f5cd[_0x1b456a]=this['editor']['data']['processor']['toData'](_0x3a2fab),this['editor']['data']['processor']['useFillerType']('default');}return _0x16f5cd;}async['getRevisionRootsAttributes'](_0x4193c5){await this['loadRevisionData'](_0x4193c5);const _0x35ca3c={};for(const _0x3ff159 in _0x4193c5['diffData'])_0x4193c5['diffData'][_0x3ff159]['attachChange']&&!_0x4193c5['diffData'][_0x3ff159]['attachChange']['isAttached']||(_0x35ca3c[_0x3ff159]=_0x4193c5['diffData'][_0x3ff159]['attributesAfter']||{});return _0x35ca3c;}['_removeRevisionMarkers'](_0x4b0a1c){return(_0x4b0a1c=_0x4b0a1c['filter'](_0x31ffba=>!_0x31ffba['name']||'revision-start'!==_0x31ffba['name']&&'revision-end'!==_0x31ffba['name']))['forEach'](_0x5a76ae=>{'string'!=typeof _0x5a76ae&&(_0x5a76ae['children']=this['_removeRevisionMarkers'](_0x5a76ae['children']),_0x5a76ae['attributes']=_0x5a76ae['attributes']['filter'](_0xe47dd0=>!_0xe47dd0[0x0]['startsWith']('data-revision-')));}),_0x4b0a1c;}async['compare'](_0x11d379,_0x99fbb5,_0x278931=!0x1){if(!this['isEnabled'])return;const _0x4f9339=this['diff'],_0xb50f28=this['repository'],_0x561ad1='string'==typeof _0x11d379?_0xb50f28['getRevision'](_0x11d379):_0x11d379,_0x1763df='string'==typeof _0x99fbb5?_0xb50f28['getRevision'](_0x99fbb5):_0x99fbb5,_0x59e809=_0x561ad1['id'],_0x18cffc=_0x1763df?_0x1763df['id']:null;if(!_0x278931&&this['diff']&&this['diff']['newRevisionId']===_0x59e809&&this['diff']['oldRevisionId']===_0x18cffc)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new c(_0x59e809,_0x18cffc);const _0x3d28da=this['_getRevisionsRange'](_0x561ad1,_0x1763df,!0x0)['map'](_0x29bf79=>this['loadRevisionData'](_0x29bf79));return _0x3d28da['push'](new Promise(_0x1ea74e=>{setTimeout(_0x1ea74e,0x14);})),Promise['all'](_0x3d28da)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x1566f6=this['_getDiff'](_0x59e809,_0x18cffc);for(const _0x2908ca of _0x1566f6['changes'])this['_changeIdToChange']['set'](_0x2908ca['id'],_0x2908ca);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x2f5adf=>{for(const _0x3198a5 of this['editor']['model']['document']['getRootNames']())_0x2f5adf['detachRoot'](_0x3198a5);for(const _0x1d906e of Object['keys'](_0x1566f6['model'])){const _0x45e2b4=_0x2f5adf['addRoot'](_0x1d906e);for(const _0x11d091 of Object['keys'](_0x1566f6['attributes'][_0x1d906e]))_0x2f5adf['setAttribute'](_0x11d091,_0x1566f6['attributes'][_0x1d906e][_0x11d091],_0x45e2b4);_0x2f5adf['insert'](_0x1566f6['model'][_0x1d906e],_0x45e2b4,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x1566f6['changes'])),this['isReady']=!0x0;})['catch'](_0x2c9239=>{console['error'](_0x2c9239),this['_cleanUp'](),_0x4f9339&&(this['diff']=_0x4f9339),this['isReady']=!0x0;});}['addRevisionData'](_0x4382e0,_0x47a045){const _0x50bc10=this['repository']['createRevision'](_0x4382e0);return _0x50bc10['on']('_update',(_0x2938ee,_0x3516be,_0x4be495)=>_0x47a045(_0x3516be,_0x4be495,_0x50bc10)),this['repository']['addRevision'](_0x50bc10),_0x50bc10;}['loadRevisionData'](_0x1f786c){if(!_0x1f786c||_0x1f786c['diffData'])return Promise['resolve']();{const _0x205f61=this['editor']['config']['get']('collaboration.channelId');return this['adapter']['getRevision']({'channelId':_0x205f61,'revisionId':_0x1f786c['id']})['then'](_0x33bfee=>{_0x1f786c['_update']({'diffData':_0x33bfee['diffData']},!0x0);});}}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x4ce12c=>{for(const _0xdc33a2 of this['editor']['model']['document']['getRootNames']())_0x4ce12c['detachRoot'](_0xdc33a2);});}['_sortAndFilterDiffChanges'](_0x117302){const _0x48804b=[],_0x26dc54=new Map();for(const _0x3297e4 of this['editor']['model']['document']['getRootNames']()){const _0x474e63=this['editor']['editing']['view']['getDomRoot'](_0x3297e4);if(!_0x474e63)continue;const _0x272337=_0x474e63['getClientRects']()['item'](0x0);_0x272337&&(_0x48804b['push'](_0x3297e4),_0x26dc54['set'](_0x3297e4,_0x272337));}return _0x48804b['sort']((_0x5657d7,_0x590ade)=>{const _0x3154e8=_0x26dc54['get'](_0x5657d7),_0x448585=_0x26dc54['get'](_0x590ade);return _0x3154e8['y']-_0x448585['y']||_0x3154e8['x']-_0x448585['x'];}),(_0x117302=_0x117302['filter'](_0x3f9486=>_0x48804b['includes'](_0x3f9486['rootName'])))['sort']((_0x323264,_0x5f1630)=>_0x48804b['indexOf'](_0x323264['rootName'])-_0x48804b['indexOf'](_0x5f1630['rootName'])),_0x117302;}['_makeTape'](_0x5bf50c){const _0xd9a1b9=Array['from'](_0x5bf50c['markers'])['filter'](([_0x1b9b8e,_0x342607])=>_0x1b9b8e['startsWith']('revision:')&&!_0x342607['isCollapsed']),_0x2e00b0=Array['from'](this['editor']['model']['createRangeIn'](_0x5bf50c)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0xd9a1b9['length'])for(const _0x55e7bc of _0x2e00b0){const [_0x157463,_0x5e5eb5]=_0xd9a1b9[0x0],[,_0x5baaad,_0x13253f]=_0x157463['split'](':');if(_0x5e5eb5['end']['isEqual'](_0x55e7bc['nextPosition'])&&_0xd9a1b9['shift'](),(_0x55e7bc['previousPosition']['isEqual'](_0x5e5eb5['start'])||_0x55e7bc['previousPosition']['isAfter'](_0x5e5eb5['start']))&&('insertion'==_0x5baaad?_0x55e7bc['isAdded']={'userId':_0x13253f}:'deletion'==_0x5baaad&&(_0x55e7bc['isRemoved']={'userId':_0x13253f})),0x0==_0xd9a1b9['length'])break;}return _0x2e00b0;}['_refreshStartEndIndex'](_0x38760e){const _0x29a439=new Map();for(let _0x106a34=0x0;_0x106a34<_0x38760e['length'];_0x106a34++)'text'===_0x38760e[_0x106a34]['type']?(_0x38760e[_0x106a34]['item']['startIndex']=_0x106a34,_0x38760e[_0x106a34]['item']['endIndex']=_0x106a34):('elementStart'===_0x38760e[_0x106a34]['type']?_0x38760e[_0x106a34]['item']['startIndex']=_0x106a34:'elementEnd'===_0x38760e[_0x106a34]['type']&&(_0x38760e[_0x106a34]['item']['endIndex']=_0x106a34),_0x29a439['set'](_0x38760e[_0x106a34]['id'],_0x106a34));for(const _0x1751cf of _0x29a439['values']())'elementStart'===_0x38760e[_0x1751cf]['type']?_0x38760e[_0x1751cf]['item']['endIndex']=_0x29a439['get'](_0x38760e[_0x1751cf]['pairId']):'elementEnd'===_0x38760e[_0x1751cf]['type']&&(_0x38760e[_0x1751cf]['item']['startIndex']=_0x29a439['get'](_0x38760e[_0x1751cf]['pairId']));}['_processTape'](_0x44b800){for(let _0xf840b0=0x0;_0xf840b0<_0x44b800['length'];_0xf840b0++){if('elementStart'===_0x44b800[_0xf840b0]['type'])_0x44b800[_0xf840b0]['item']['startIndex']=_0xf840b0;else{if('elementEnd'===_0x44b800[_0xf840b0]['type']){_0x44b800[_0xf840b0]['item']['endIndex']=_0xf840b0;const _0x1df218=_0x44b800[_0xf840b0]['item']['startIndex'];_0x44b800[_0x1df218]['pairId']=_0x44b800[_0xf840b0]['id'],_0x44b800[_0xf840b0]['pairId']=_0x44b800[_0x1df218]['id'];}else _0x44b800[_0xf840b0]['item']['startIndex']=_0xf840b0,_0x44b800[_0xf840b0]['item']['endIndex']=_0xf840b0,_0x44b800[_0xf840b0]['pairId']=null;}_0x44b800[_0xf840b0]['markersStart']||(_0x44b800[_0xf840b0]['markersStart']=[],_0x44b800[_0xf840b0]['markersEnd']=[]);}}['_markInsertions'](_0x3cba7f,_0x2a27e4){const _0x3dddfd=_0x3cba7f['filter'](_0x515c83=>!_0x515c83['isAdded']);for(let _0x1227fb=0x0;_0x1227fb<_0x2a27e4['length'];_0x1227fb++)_0x2a27e4[_0x1227fb]['isAdded']&&(_0x3dddfd[_0x1227fb]['isAdded']=_0x2a27e4[_0x1227fb]['isAdded']);}['_makeModelFromViewString'](_0x49e525){const _0x458175=JSON['parse'](_0x49e525),_0x102a79=this['editor']['editing']['view']['document'],_0x2b5cca=new _0x1c9f86(_0x102a79,_0x458175['map'](_0x28f9b5=>this['_getViewObj'](_0x28f9b5)));return this['editor']['data']['toModel'](_0x2b5cca);}['_getViewObj'](_0x5a8026){const _0x106c03=this['editor']['editing']['view']['document'];if('string'==typeof _0x5a8026)return new _0x5b5f30(_0x106c03,_0x5a8026);{const _0x1e68d1=_0x5a8026['children']['map'](_0x5aa677=>this['_getViewObj'](_0x5aa677));return new(Y[_0x5a8026['type']]||_0x5aa52f)(_0x106c03,_0x5a8026['name'],_0x5a8026['attributes'],_0x1e68d1);}}['_getDiff'](_0x1ad956,_0x2df5c3=null){const _0x59a5ef=this['repository']['getRevision'](_0x1ad956),_0x28f7f9=_0x2df5c3?this['repository']['getRevision'](_0x2df5c3):null,_0x4ff40f=this['_getRevisionsRange'](_0x59a5ef,_0x28f7f9),_0x361dee=_0x4ff40f[_0x4ff40f['length']-0x1],_0xba452f=new Map(),_0x36a901={'model':{},'attributes':{},'changes':[]},_0x3e1eac=new Set(),_0x42b048=new Map();for(let _0x207346=_0x4ff40f['length']-0x1;_0x207346>=0x0;_0x207346--){const _0x430bee=_0x4ff40f[_0x207346];for(const _0x18120d of Object['keys'](_0x430bee['diffData']))if(_0x430bee['diffData'][_0x18120d]['attachChange']){const _0x400884=_0x430bee['diffData'][_0x18120d]['attachChange'];_0x400884['isAttached']?(_0x3e1eac['add'](_0x18120d),_0x42b048['has'](_0x18120d)&&_0x42b048['get'](_0x18120d)['userId']==_0x400884['userId']?_0x42b048['delete'](_0x18120d):_0x42b048['set'](_0x18120d,_0x400884)):_0x42b048['has'](_0x18120d)?(_0x3e1eac['delete'](_0x18120d),_0x42b048['delete'](_0x18120d)):(_0x3e1eac['add'](_0x18120d),_0x42b048['set'](_0x18120d,_0x400884));}else _0x3e1eac['add'](_0x18120d);}for(const _0x5009e2 of _0x3e1eac){const _0x4f9270=_0x42b048['has'](_0x5009e2)&&!_0x42b048['get'](_0x5009e2)['isAttached'];let _0xe353ba=_0x4f9270?_0x4ff40f['length']-0x1:0x0;const _0x4afdc9=_0x4f9270?-0x1:0x1;for(;_0x4ff40f[_0xe353ba];){const _0x80ae72=_0x4ff40f[_0xe353ba];if(_0x80ae72['diffData'][_0x5009e2]){const _0x37dc3f=_0x4f9270?_0x80ae72['diffData'][_0x5009e2]['attributesBefore']:_0x80ae72['diffData'][_0x5009e2]['attributesAfter'];_0x36a901['attributes'][_0x5009e2]=_0x37dc3f?_0x4abf57(_0x37dc3f):{};break;}_0xe353ba+=_0x4afdc9;}}for(const _0x1c92a5 of _0x4ff40f){_0x1c92a5['model']={};for(const _0x2c17dd of _0x1c92a5['authors'])_0xba452f['set'](_0x2c17dd['id'],_0x2c17dd);for(const _0x277040 of _0x3e1eac){const _0x5340b8=_0x1c92a5['diffData'][_0x277040]?_0x1c92a5['diffData'][_0x277040]['insertions']:'[]',_0x5d9b83=_0x1c92a5['diffData'][_0x277040]?_0x1c92a5['diffData'][_0x277040]['deletions']:'[]';_0x1c92a5['model'][_0x277040]={'insertions':this['_makeModelFromViewString'](_0x5340b8),'deletions':this['_makeModelFromViewString'](_0x5d9b83)};}}for(const _0x340e7e of _0x3e1eac){let _0x180a68=null,_0x12e3c8=0x0;const _0x41f0bc=new Map(Array['from'](_0x59a5ef['model'][_0x340e7e]['insertions']['markers'])['filter'](([_0x5066e8])=>!_0x5066e8['startsWith']('revision:')));let _0x493c82=0x0;for(const _0x430980 of _0x4ff40f){const _0x253d7d=this['_makeTape'](_0x430980['model'][_0x340e7e]['insertions']);_0x430980==_0x59a5ef?(_0x180a68=_0x253d7d,_0x12e3c8=_0x180a68['length'],_0x180a68['forEach'](_0x39a62b=>{_0x39a62b['id']=_0x493c82++;}),this['_processTape'](_0x180a68)):this['_markInsertions'](_0x180a68,_0x253d7d);const _0x3c1100=_0x180a68['filter'](_0x40375c=>!_0x40375c['isAdded'])['map'](_0x5952b5=>_0x5952b5['id']);let _0x581f0d=0x0;const _0x33fb1e=this['_makeTape'](_0x430980['model'][_0x340e7e]['deletions']);_0x33fb1e['forEach'](_0x2215cb=>{_0x2215cb['isRemoved']?_0x2215cb['id']=_0x12e3c8++:_0x2215cb['id']=_0x3c1100[_0x581f0d++];}),this['_processTape'](_0x33fb1e),this['_setDistance'](_0x180a68,'isAdded'),this['_setDistance'](_0x33fb1e,'isRemoved'),_0x430980==_0x59a5ef&&this['_markMarkers'](_0x180a68,_0x41f0bc),_0x180a68=this['_joinTapes'](_0x180a68,_0x33fb1e),this['_refreshStartEndIndex'](_0x180a68),this['_setDistance'](_0x180a68,'isRemoved');}_0x180a68=_0x180a68['filter'](_0x16ecf5=>!(_0x16ecf5['isAdded']&&_0x16ecf5['isRemoved']));const _0xd9ea0d=new Map(_0x361dee['model'][_0x340e7e]['deletions']['markers']),_0x492ab2=new Set(_0x41f0bc['keys']());for(const _0x4009a7 of _0xd9ea0d['keys']())_0x492ab2['delete'](_0x4009a7);this['_markSuggestions'](_0x180a68,_0x492ab2),this['_fixObsoleteTags'](_0x180a68),_0x180a68=this['_removeMissingPairs'](_0x180a68),_0x180a68=this['_markMismatchedRemovedTags'](_0x180a68),_0x180a68=this['_removeUnsupportedChanges'](_0x180a68);const {root:_0x5056fa,changes:_0x1583fe}=this['_makeModelFromTape'](_0x180a68,_0xba452f,_0x340e7e);_0x36a901['model'][_0x340e7e]=_0x5056fa;const _0x2c0a79=_0x42b048['get'](_0x340e7e);if(_0x2c0a79){const _0x4625b6=_0xba452f['get'](_0x2c0a79['userId']),_0x19044c=new r({'author':_0x4625b6,'type':_0x2c0a79['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x340e7e});_0x1583fe['unshift'](_0x19044c),_0x36a901['attributes'][_0x340e7e]['revisionHistoryAttachChange']=_0x19044c['id'];}_0x36a901['changes']=_0x36a901['changes']['concat'](_0x1583fe);}return _0x36a901;}['_markMarkers'](_0x138f4b,_0x330786){for(let _0x1c1bac=0x0;_0x1c1bac<_0x138f4b['length'];_0x1c1bac++)for(const [_0x49e13a,_0x94f666]of _0x330786)_0x94f666['start']['isEqual'](_0x138f4b[_0x1c1bac]['previousPosition'])&&_0x138f4b[_0x1c1bac]['markersStart']['push'](_0x49e13a),_0x94f666['end']['isEqual'](_0x138f4b[_0x1c1bac]['nextPosition'])&&_0x138f4b[_0x1c1bac]['markersEnd']['push'](_0x49e13a);}['_joinTapes'](_0x475c7c,_0x3e1f29){let _0x63927b=[],_0x577298=0x0,_0x29d278=0x0;for(;_0x577298<_0x475c7c['length']||_0x29d278<_0x3e1f29['length'];){const _0x2c8010=_0x475c7c[_0x577298]||{},_0x4bf39c=_0x3e1f29[_0x29d278]||{};if(_0x2c8010['id']==_0x4bf39c['id'])_0x577298++,_0x29d278++,_0x63927b['push'](_0x2c8010);else{if(_0x4bf39c['isRemoved']&&_0x2c8010['isAdded']){const {commonTape:_0x2180d2,iEnd:_0xa86578,jEnd:_0x275522}=this['_threeWayMerge'](_0x475c7c,_0x577298,_0x3e1f29,_0x29d278);_0x63927b=_0x63927b['concat'](_0x2180d2),_0x577298=_0xa86578,_0x29d278=_0x275522;}else _0x4bf39c['isRemoved']?(_0x29d278++,_0x63927b['push'](_0x4bf39c)):(_0x577298++,_0x63927b['push'](_0x2c8010));}}return _0x63927b;}['_markSuggestions'](_0x3e420e,_0x500dbb){const _0x2e724b=[];for(let _0x3d854c=0x0;_0x3d854c<_0x3e420e['length'];_0x3d854c++){for(let _0x4beb7e=0x0;_0x4beb7e<_0x3e420e[_0x3d854c]['markersStart']['length'];_0x4beb7e++){const _0x211e5a=_0x3e420e[_0x3d854c]['markersStart'][_0x4beb7e];if(!_0x500dbb['has'](_0x211e5a))continue;const {group:_0x1860a5,type:_0x3c178d,authorId:_0x589530}=_0x290554(_0x211e5a);'revision-suggestion'!=_0x1860a5||'insertion'!=_0x3c178d&&'deletion'!=_0x3c178d||(_0x2e724b['unshift']({'type':_0x3c178d,'name':_0x211e5a,'userId':_0x589530}),_0x3e420e[_0x3d854c]['markersStart']['splice'](_0x4beb7e,0x1),_0x4beb7e--);}_0x59fa62(_0x3e420e[_0x3d854c]);for(let _0x47e14f=0x0;_0x47e14f<_0x3e420e[_0x3d854c]['markersEnd']['length'];_0x47e14f++){const _0xfb4458=_0x3e420e[_0x3d854c]['markersEnd'][_0x47e14f];if(!_0x500dbb['has'](_0xfb4458))continue;const {group:_0x483a11,type:_0x5ad32d}=_0x290554(_0xfb4458);if('revision-suggestion'!=_0x483a11||'insertion'!=_0x5ad32d&&'deletion'!=_0x5ad32d)continue;_0x3e420e[_0x3d854c]['markersEnd']['splice'](_0x47e14f,0x1),_0x47e14f--;const _0x2f261a=_0x2e724b['findIndex'](_0x471c7c=>_0x471c7c['name']==_0xfb4458);_0x2f261a>-0x1&&_0x2e724b['splice'](_0x2f261a,0x1);}}function _0x290554(_0x40ebd9){const _0x3154ea=_0x40ebd9['split'](':');return{'group':_0x3154ea[0x0],'type':_0x3154ea[0x1],'subType':_0x3154ea['length']>=0x5?_0x3154ea[0x2]:null,'id':_0x3154ea['length']<0x5?_0x3154ea[0x2]:_0x3154ea[0x3],'authorId':_0x3154ea['length']<0x5?_0x3154ea[0x3]:_0x3154ea[0x4],'markerCount':0x6==_0x3154ea['length']?_0x3154ea[0x5]:null};}function _0x59fa62(_0x368468){for(let _0x40f24f=0x0;_0x40f24f<_0x2e724b['length'];_0x40f24f++){if(_0x368468['isAdded']&&'insertion'==_0x2e724b[_0x40f24f]['type'])return _0x368468['isAddSuggestion']=_0x2e724b[_0x40f24f],void delete _0x368468['isAdded'];if(!_0x368468['isAdded']&&!_0x368468['isRemoved']&&'deletion'==_0x2e724b[_0x40f24f]['type'])return void(_0x368468['isRemoveSuggestion']=_0x2e724b[_0x40f24f]);}}}['_setDistance'](_0x1c908e,_0x367703){let _0x53fbf6=0x0,_0x327524=!0x1;const _0x323c01=new Map();for(const _0x43abe7 of _0x1c908e)_0x43abe7[_0x367703]?_0x327524&&(_0x53fbf6++,_0x327524=!0x1):(_0x53fbf6++,_0x327524=!0x0),_0x323c01['set'](_0x43abe7['id'],_0x53fbf6);for(let _0x69db36=0x0;_0x69db36<_0x1c908e['length'];_0x69db36++){if('isRemoved'==_0x367703&&_0x1c908e[_0x69db36]['isAdded']||'isAdded'==_0x367703&&_0x1c908e[_0x69db36]['isRemoved'])continue;if('text'==_0x1c908e[_0x69db36]['type']){_0x1c908e[_0x69db36]['distance']=0x0;continue;}const _0x5b76e4=_0x323c01['get'](_0x1c908e[_0x69db36]['pairId']),_0x3ae779=_0x323c01['get'](_0x1c908e[_0x69db36]['id']);_0x1c908e[_0x69db36]['distance']=_0x5b76e4-_0x3ae779;}}['_getRevisionsRange'](_0x5a0d2b,_0x327608,_0x4bf003=!0x1){const _0x4a65b8=[];let _0x7a227=this['repository']['getIndex'](_0x5a0d2b),_0x233899=this['repository']['getIndex'](_0x327608);for(-0x1==_0x233899&&(_0x233899=this['repository']['_revisions']['length'],_0x4bf003=!0x1);_0x7a227<_0x233899;)_0x4a65b8['push'](this['repository']['getRevision'](_0x7a227)),_0x7a227++;return _0x4bf003&&_0x4a65b8['push'](this['repository']['getRevision'](_0x7a227)),_0x4a65b8;}['_threeWayMerge'](_0x396218,_0x51c81a,_0x377114,_0x3df210){const _0xc8684f=this['editor']['model']['schema'];let _0x1b7c76=_0x51c81a;for(;_0x396218[_0x1b7c76]&&_0x396218[_0x1b7c76]['isAdded'];)_0x1b7c76++;let _0x2afc4e=_0x3df210;for(;_0x377114[_0x2afc4e]&&_0x377114[_0x2afc4e]['isRemoved'];)_0x2afc4e++;_0x967c60(_0x396218,_0x51c81a,_0x1b7c76),_0x967c60(_0x377114,_0x3df210,_0x2afc4e);const _0x53a7d7=_0x377114['slice'](_0x3df210,_0x2afc4e)['concat'](_0x396218['slice'](_0x51c81a,_0x1b7c76));return _0x53a7d7['sort']((_0x593f11,_0xea4c96)=>_0x593f11['side']!=_0xea4c96['side']?_0x593f11['side']-_0xea4c96['side']:_0x593f11['level']!=_0xea4c96['level']?_0x593f11['level']-_0xea4c96['level']:_0x593f11['distance']!=_0xea4c96['distance']?_0xea4c96['distance']-_0x593f11['distance']:!!_0x593f11['isAdded']!=!!_0xea4c96['isAdded']?-0x1==_0x593f11['side']||0x0==_0x593f11['side']?_0x593f11['isAdded']?-0x1:0x1:_0x593f11['isAdded']?0x1:-0x1:_0x593f11['index']-_0xea4c96['index']),{'commonTape':_0x53a7d7,'iEnd':_0x1b7c76,'jEnd':_0x2afc4e};function _0x967c60(_0x1cf2c6,_0x4e54e4,_0x3b5e2c){let _0x48441d=-0x1,_0x1382cd=Number['POSITIVE_INFINITY'],_0x376670=!0x0;for(let _0x36fef4=_0x4e54e4;_0x36fef4<_0x3b5e2c;_0x36fef4++)if(_0xc8684f['isInline'](_0x1cf2c6[_0x36fef4]['item'])||(_0x376670=!0x1),_0x1cf2c6[_0x36fef4]['item']['startIndex']<_0x4e54e4&&(_0x48441d=_0x36fef4),_0x1cf2c6[_0x36fef4]['item']['endIndex']>=_0x3b5e2c){_0x1382cd=_0x36fef4;break;}_0x376670&&(_0x48441d=_0x3b5e2c-0x1);for(let _0x28a7ef=_0x4e54e4;_0x28a7ef<_0x3b5e2c;_0x28a7ef++)_0x1cf2c6[_0x28a7ef]['side']=_0x28a7ef<=_0x48441d?-0x1:_0x28a7ef<_0x1382cd?0x0:0x1,_0x1cf2c6[_0x28a7ef]['index']=_0x28a7ef;let _0x1aedb9=0x0;for(let _0x1678bf=_0x4e54e4;_0x1678bf<=_0x48441d;_0x1678bf++)0x0==_0x1cf2c6[_0x1678bf]['distance']?_0x1cf2c6[_0x1678bf]['level']=_0x1aedb9:(_0x1aedb9++,_0x1cf2c6[_0x1678bf]['level']=_0x1aedb9,_0x1aedb9++);for(let _0x62b2f3=_0x4e54e4;_0x62b2f3<_0x3b5e2c;_0x62b2f3++)0x0==_0x1cf2c6[_0x62b2f3]['side']&&(_0x1cf2c6[_0x62b2f3]['level']=_0x1aedb9);_0x1aedb9=0x0;for(let _0x33bca9=_0x3b5e2c-0x1;_0x33bca9>=_0x1382cd;_0x33bca9--)0x0==_0x1cf2c6[_0x33bca9]['distance']?_0x1cf2c6[_0x33bca9]['level']=_0x1aedb9:(_0x1aedb9--,_0x1cf2c6[_0x33bca9]['level']=_0x1aedb9,_0x1aedb9--);}}['_fixObsoleteTags'](_0x209580){const _0x2aae20=new Map(),_0x9249d4=this['editor']['model']['schema'];for(let _0x2dc8fc=0x1;_0x2dc8fc<_0x209580['length'];_0x2dc8fc++){let _0x5bf0d5,_0x8f98f3,_0x46c547;const _0x68802b=_0x209580[_0x2dc8fc],_0x221c20=_0x209580[_0x2dc8fc-0x1];if('text'==_0x68802b['type'])continue;if(_0x68802b['type']!=_0x221c20['type'])continue;if(!_0x9249d4['isBlock'](_0x221c20['item'])||_0x9249d4['isLimit'](_0x221c20['item']))continue;if(!_0x9249d4['isBlock'](_0x68802b['item'])||_0x9249d4['isLimit'](_0x68802b['item']))continue;if((_0x209580[_0x2dc8fc]['isAdded']||_0x209580[_0x2dc8fc]['isAddSuggestion'])&&_0x209580[_0x2dc8fc-0x1]['isRemoved'])_0x5bf0d5=_0x209580[_0x2dc8fc],_0x8f98f3=_0x209580[_0x2dc8fc-0x1],_0x46c547=_0x2dc8fc-0x1;else{if(!_0x209580[_0x2dc8fc]['isRemoved']||!_0x209580[_0x2dc8fc-0x1]['isAdded']&&!_0x209580[_0x2dc8fc-0x1]['isAddSuggestion'])continue;_0x5bf0d5=_0x209580[_0x2dc8fc-0x1],_0x8f98f3=_0x209580[_0x2dc8fc],_0x46c547=_0x2dc8fc;}const _0x65916a=_0x5bf0d5['level']==_0x8f98f3['level'],_0x219071=Math['abs'](_0x5bf0d5['level'])<Math['abs'](_0x8f98f3['level'])&&0x0==_0x8f98f3['distance'];(_0x65916a||_0x219071)&&(_0x2aae20['set'](_0x8f98f3['id'],_0x5bf0d5['id']),_0x209580['splice'](_0x46c547,0x1),_0x2dc8fc--,_0x5bf0d5['isAdded']=!0x1);}for(let _0x2dcbb0=0x0;_0x2dcbb0<_0x209580['length'];_0x2dcbb0++)_0x2aae20['has'](_0x209580[_0x2dcbb0]['pairId'])&&(_0x209580[_0x2dcbb0]['pairId']=_0x2aae20['get'](_0x209580[_0x2dcbb0]['pairId']));}['_removeMissingPairs'](_0x4477c2){const _0x506ef3=new Set(_0x4477c2['map'](_0x1f61c7=>_0x1f61c7['id']));for(let _0x51039a=0x0;_0x51039a<_0x4477c2['length'];_0x51039a++)_0x506ef3['has'](_0x4477c2[_0x51039a]['pairId'])||0x0==_0x4477c2[_0x51039a]['distance']||(_0x4477c2[_0x51039a]['isIncorrect']=!0x0);return _0x4477c2['filter'](_0x2bfed7=>!_0x2bfed7['isIncorrect']);}['_markMismatchedRemovedTags'](_0x430c74){const _0x7568f4=new Set();for(let _0x4ca4a6=0x0;_0x4ca4a6<_0x430c74['length'];_0x4ca4a6++){if(_0x7568f4['has'](_0x430c74[_0x4ca4a6]['id'])&&_0x430c74[_0x4ca4a6]['isRemoved']&&(_0x430c74[_0x4ca4a6]['isIncorrect']=!0x0),_0x430c74[_0x4ca4a6]['isIncorrect'])continue;if(0x0==_0x430c74[_0x4ca4a6]['distance'])continue;if('elementStart'!=_0x430c74[_0x4ca4a6]['type'])continue;if(null==_0x430c74[_0x4ca4a6]['pairId'])continue;let _0x511c18=_0x4ca4a6+0x1,_0x5e55bb=0x0;for(;_0x430c74[_0x511c18]['id']!=_0x430c74[_0x4ca4a6]['pairId'];)'elementStart'==_0x430c74[_0x511c18]['type']?_0x5e55bb++:'elementEnd'==_0x430c74[_0x511c18]['type']&&_0x5e55bb--,_0x511c18++;if(0x0!=_0x5e55bb){if(_0x430c74[_0x4ca4a6]['isRemoved'])_0x430c74[_0x4ca4a6]['isIncorrect']=!0x0;else{for(;_0x511c18!=_0x4ca4a6;)_0x430c74[_0x511c18]['isRemoved']&&0x0!=_0x430c74[_0x511c18]['distance']&&(_0x430c74[_0x511c18]['isIncorrect']=!0x0,_0x7568f4['add'](_0x430c74[_0x511c18]['pairId'])),_0x511c18--;}}}return _0x430c74['filter'](_0x219155=>!_0x219155['isIncorrect']);}['_removeUnsupportedChanges'](_0x4cb6cc){const _0x3d7f58=this['editor']['model']['schema'];for(let _0x5b9d38=0x0;_0x5b9d38<_0x4cb6cc['length'];_0x5b9d38++){if(!(_0x4cb6cc[_0x5b9d38]['isAdded']||_0x4cb6cc[_0x5b9d38]['isAddSuggestion']||_0x4cb6cc[_0x5b9d38]['isRemoved']||_0x4cb6cc[_0x5b9d38]['isRemoveSuggestion']))continue;if(0x0==_0x4cb6cc[_0x5b9d38]['distance'])continue;const _0x3704d0=_0x4cb6cc[_0x5b9d38]['item'];_0x3d7f58['isBlock'](_0x3704d0)||_0x3d7f58['isLimit'](_0x3704d0)||(_0x4cb6cc[_0x5b9d38]['isAdded']&&delete _0x4cb6cc[_0x5b9d38]['isAdded'],_0x4cb6cc[_0x5b9d38]['isAddSuggestion']&&delete _0x4cb6cc[_0x5b9d38]['isAddSuggestion'],_0x4cb6cc[_0x5b9d38]['isRemoveSuggestion']&&delete _0x4cb6cc[_0x5b9d38]['isRemoveSuggestion'],_0x4cb6cc[_0x5b9d38]['isRemoved']&&(_0x4cb6cc[_0x5b9d38]['isIncorrect']=!0x0));}return _0x4cb6cc['filter'](_0x321da7=>!_0x321da7['isIncorrect']);}['_makeModelFromTape'](_0x69c5c5,_0x1ff54e,_0xc4ab1b){const _0x59911b=new gt(),_0x166723=[],_0x67fe3d=new Map(),_0x396330=this['editor']['model'],_0x48bc1c=_0x396330['schema'],_0x2c5ef1=[_0x59911b],_0x209f73={},_0x595438={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x26438c=null;const _0x5d1799=[0x0];for(let _0x226bdf=0x0;_0x226bdf<_0x69c5c5['length'];_0x226bdf++)if('elementStart'===_0x69c5c5[_0x226bdf]['type']){_0x69c5c5[_0x226bdf]['previousPosition']=_0x396330['createPositionFromPath'](_0x59911b,_0x5d1799);const _0xca3bd4=new ut(_0x69c5c5[_0x226bdf]['item']['name'],_0x69c5c5[_0x226bdf]['item']['getAttributes']());_0x2c5ef1[0x0]['_appendChild'](_0xca3bd4),_0x5d1799['push'](0x0),_0x2c5ef1['unshift'](_0xca3bd4),_0x69c5c5[_0x226bdf]['nextPosition']=_0x396330['createPositionFromPath'](_0x59911b,_0x5d1799);}else'elementEnd'===_0x69c5c5[_0x226bdf]['type']?(_0x2c5ef1['shift'](),_0x69c5c5[_0x226bdf]['previousPosition']=_0x396330['createPositionFromPath'](_0x59911b,_0x5d1799),_0x5d1799['pop'](),_0x5d1799[_0x5d1799['length']-0x1]++,_0x69c5c5[_0x226bdf]['nextPosition']=_0x396330['createPositionFromPath'](_0x59911b,_0x5d1799)):(_0x69c5c5[_0x226bdf]['previousPosition']=_0x396330['createPositionFromPath'](_0x59911b,_0x5d1799),_0x26438c?_0x26438c['_data']+=_0x69c5c5[_0x226bdf]['item']['data']:_0x26438c=new mt(_0x69c5c5[_0x226bdf]['item']['data'],_0x69c5c5[_0x226bdf]['item']['getAttributes']()),_0x69c5c5[_0x226bdf+0x1]&&'text'===_0x69c5c5[_0x226bdf+0x1]['type']&&_0x44135b(_0x26438c,_0x69c5c5[_0x226bdf+0x1]['item'])||(_0x2c5ef1[0x0]['_appendChild'](_0x26438c),_0x26438c=null),_0x5d1799[_0x5d1799['length']-0x1]+=_0x69c5c5[_0x226bdf]['item']['offsetSize'],_0x69c5c5[_0x226bdf]['nextPosition']=_0x396330['createPositionFromPath'](_0x59911b,_0x5d1799));for(let _0x9999a9=0x0;_0x9999a9<_0x69c5c5['length'];_0x9999a9++){const _0x46ffd4=_0x69c5c5[_0x9999a9]['previousPosition'],_0x26f297=_0x69c5c5[_0x9999a9]['nextPosition'];for(const _0x16e040 of _0x69c5c5[_0x9999a9]['markersStart'])_0x67fe3d['set'](_0x16e040,{'start':_0x46ffd4,'end':null});_0x5c49cf('isRemoveSuggestion',_0x9999a9,_0x46ffd4,_0x26f297),_0x5c49cf('isAddSuggestion',_0x9999a9,_0x46ffd4,_0x26f297),_0x5c49cf('isRemoved',_0x9999a9,_0x46ffd4,_0x26f297),_0x5c49cf('isAdded',_0x9999a9,_0x46ffd4,_0x26f297);for(const _0x54f89a of _0x69c5c5[_0x9999a9]['markersEnd']){_0x67fe3d['get'](_0x54f89a)['end']=_0x26f297;}}for(const [_0x320ca3,_0x336f3b]of _0x67fe3d){const _0x5d64d5=this['editor']['model']['createRange'](_0x336f3b['start'],_0x336f3b['end']);_0x59911b['markers']['set'](_0x320ca3,_0x5d64d5);}return _0x166723['sort']((_0x1d960f,_0x21c5a9)=>{const _0x4f8067=_0x59911b['markers']['get']('revision:'+_0x1d960f['id']),_0x46016e=_0x59911b['markers']['get']('revision:'+_0x21c5a9['id']);return _0x4f8067['start']['isBefore'](_0x46016e['start'])?-0x1:_0x4f8067['start']['isAfter'](_0x46016e['start'])?0x1:_0x4f8067['end']['isBefore'](_0x46016e['end'])?-0x1:_0x4f8067['end']['isAfter'](_0x46016e['end'])?0x1:'add'===_0x1d960f['type']?-0x1:0x1;}),{'root':_0x59911b,'changes':_0x166723};function _0x5c49cf(_0x5c6c51,_0x316c6f,_0xc28a40,_0x5eee2c){const _0x28140d=!!_0x69c5c5[_0x316c6f][_0x5c6c51],_0x2a58a5=_0x28140d?_0x69c5c5[_0x316c6f][_0x5c6c51]['userId']:null,_0x55e4c8=_0x316c6f===_0x69c5c5['length']-0x1,_0xf6e877=_0x595438[_0x5c6c51][0x0],_0x402ce4=_0x48bc1c['isObject'](_0x69c5c5[_0x316c6f]['item']);!_0x209f73[_0x5c6c51]&&_0x28140d?_0x209f73[_0x5c6c51]={'start':_0xc28a40,'tapeItem':_0x69c5c5[_0x316c6f],'userId':_0x2a58a5,'type':_0x5c6c51}:_0x209f73[_0x5c6c51]&&!_0x28140d?(_0x209f73[_0x5c6c51]['end']=_0xc28a40,_0x12e31f(_0x209f73[_0x5c6c51]),_0x209f73[_0x5c6c51]=null):_0x209f73[_0x5c6c51]&&_0x28140d&&_0x209f73[_0x5c6c51]['userId']!==_0x2a58a5&&(_0x209f73[_0x5c6c51]['end']=_0xc28a40,_0xf6e877&&_0xf6e877['userId']===_0x209f73[_0x5c6c51]['userId']||_0x12e31f(_0x209f73[_0x5c6c51]),_0x209f73[_0x5c6c51]={'start':_0xc28a40,'tapeItem':_0x69c5c5[_0x316c6f],'userId':_0x2a58a5,'type':_0x5c6c51}),_0x209f73[_0x5c6c51]&&_0x402ce4&&('elementStart'!==_0x69c5c5[_0x316c6f]['type']||_0xf6e877&&_0xf6e877['userId']===_0x2a58a5||_0x595438[_0x5c6c51]['unshift']({'userId':_0x2a58a5,'object':_0x69c5c5[_0x316c6f]['item'],'change':_0x209f73[_0x5c6c51]}),'elementEnd'===_0x69c5c5[_0x316c6f]['type']&&_0xf6e877&&_0xf6e877['object']===_0x69c5c5[_0x316c6f]['item']&&(_0x595438[_0x5c6c51]['shift'](),_0x209f73[_0x5c6c51]=_0xf6e877['change'])),_0x209f73[_0x5c6c51]&&_0x55e4c8&&(_0x209f73[_0x5c6c51]['end']=_0x5eee2c,_0x12e31f(_0x209f73[_0x5c6c51]),_0x209f73[_0x5c6c51]=null);}function _0x12e31f({start:_0x580aa6,end:_0x43beb2,tapeItem:_0x5a9fce,userId:_0x1c278e,type:_0x14de66}){const _0x47c308=_0x5a9fce['item'],_0x2f5ea5=_0x396330['schema']['isBlock'](_0x47c308)&&!_0x396330['schema']['isLimit'](_0x47c308),_0x5642e2=_0x580aa6['nodeAfter']==_0x43beb2['parent']&&_0x43beb2['isAtStart'];if(_0x2f5ea5&&_0x5642e2)return;const _0x7257a8=_0x396330['createRange'](_0x580aa6,_0x43beb2),_0x359ab4=_0x1ff54e['get'](_0x1c278e),_0x1c3a32=new r({'author':_0x359ab4,'type':'isAdded'==_0x14de66||'isAddSuggestion'==_0x14de66?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x14de66||'isRemoveSuggestion'==_0x14de66},'createdAt':new Date(),'rootName':_0xc4ab1b});_0x166723['push'](_0x1c3a32),_0x59911b['markers']['set']('revision:'+_0x1c3a32['id'],_0x7257a8);}function _0x44135b(_0x181714,_0x329a87){const _0x487044=_0x181714['getAttributes'](),_0x4e222a=_0x329a87['getAttributes']();for(const _0x8a4d11 of _0x487044){if(_0x8a4d11[0x1]!==_0x329a87['getAttribute'](_0x8a4d11[0x0]))return!0x1;_0x4e222a['next']();}return _0x4e222a['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x4211d5=>{const _0x5c3dcc=_0x4211d5['markerName']['split'](':')[0x1],_0x560d52=this['_getChangeFromId'](_0x5c3dcc);if(!_0x560d52)return null;const _0x19fe0b='add'==_0x560d52['type']?'insertion':'deletion',_0x3ad45a=['ck-suggestion-marker','ck-suggestion-marker-'+_0x19fe0b];return _0x560d52['data']['isSuggestion']&&_0x3ad45a['push']('ck-suggestion-marker-'+_0x19fe0b+'-new'),this['activeChange']==_0x560d52&&_0x3ad45a['push']('ck-suggestion-marker--active'),{'classes':_0x3ad45a,'attributes':{'data-change-id':_0x5c3dcc}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x3d1ba2=>{_0x3d1ba2['on']('element:pre',(_0x45e80f,_0x37854a,_0x188b9a)=>{const _0x571b41=_0x37854a['viewItem']['getChild'](0x0);if(!_0x571b41||!_0x571b41['is']('element','code'))return;if(!_0x188b9a['consumable']['consume'](_0x571b41,{'attributes':['vid_start','vid_end']}))return;const _0x12da73=_0x37854a['modelRange']['start']['nodeAfter'];_0x188b9a['writer']['setAttribute']('vid_start',_0x571b41['getAttribute']('vid_start'),_0x12da73),_0x188b9a['writer']['setAttribute']('vid_end',_0x571b41['getAttribute']('vid_end'),_0x12da73);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x247463=>{_0x247463['on']('element',(_0x251adb,_0xa40af7,_0x375c72)=>{if(!_0x375c72['consumable']['consume'](_0xa40af7['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0xa40af7['modelRange']['isCollapsed'])return;const _0x3b6a65=_0xa40af7['modelRange']['start']['nodeAfter'];_0x3b6a65['hasAttribute']('vid_start')||_0x3b6a65['hasAttribute']('vid')||(_0x375c72['writer']['setAttribute']('vid_start',_0xa40af7['viewItem']['getAttribute']('vid_start'),_0x3b6a65),_0x375c72['writer']['setAttribute']('vid_end',_0xa40af7['viewItem']['getAttribute']('vid_end'),_0x3b6a65));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x6ced35=>_0x6ced35['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x5a2a10,[,_0x4cbfe0])=>{['vid_start','vid_end','vid']['includes'](_0x4cbfe0)&&(_0x5a2a10['return']=!0x0,_0x5a2a10['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x2746a6=>{_0x2746a6['on']('attribute:vid',(_0x2ab417,_0x54b30f,_0x23279a)=>{if('\x20'!=_0x54b30f['item']['data']||_0x54b30f['item']['parent']['maxOffset']>0x1)return;if(!_0x23279a['consumable']['consume'](_0x54b30f['item'],_0x2ab417['name']))return;const _0x3ec8a6=_0x23279a['writer'],_0x159ea9=_0x23279a['mapper']['toViewRange'](_0x54b30f['range']);_0x3ec8a6['wrap'](_0x159ea9,_0x3ec8a6['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x8feff5){const _0x5e184a=_0x8feff5['plugins']['get']('RevisionViewer');return(_0x4d287e,_0x18c761,_0xd830a8)=>{const _0x3c62b4=_0x18c761['markerName']['split'](':')[0x1],_0x51ba98=_0x5e184a['_getChangeFromId'](_0x3c62b4);if(!_0x51ba98)return null;const _0x30a572='add'==_0x51ba98['type']?'split':'merge';if(!_0xd830a8['consumable']['test'](_0x18c761['markerRange'],_0x4d287e['name']))return;const _0x599411=_0x18c761['markerRange']['getWalker'](),_0x5b8de0=_0x18c761['markerRange']['start'],_0x221a2b=_0x8feff5['model']['schema'];let _0xd9d4f8=null,_0x44e1c4=null,_0x3d0a46=!0x1,_0xe2ae3e=!0x1;for(const _0x5779c1 of _0x599411){const _0x1686a9=_0x5779c1['item'];_0x3d0a46=_0x3d0a46||_0x221a2b['isContent'](_0x1686a9);const _0x15eb1d=_0xd830a8['mapper']['toViewElement'](_0x1686a9);if(_0x15eb1d&&_0x15eb1d['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x5779c1['type']&&(_0x221a2b['isBlock'](_0x1686a9)&&!_0x221a2b['isLimit'](_0x1686a9)&&(_0x1686a9['nextSibling']||_0x5b8de0['isAtEnd']?_0xd9d4f8&&_0xd9d4f8['parent']==_0x1686a9||(_0xd9d4f8=_0x1686a9,_0x11ee9d(_0x5779c1['previousPosition']),_0xe2ae3e=!0x0):_0x44e1c4=_0x44e1c4||_0x5779c1['previousPosition']));}function _0x11ee9d(_0x1f7a93){const _0x1f7406=_0xd830a8['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x30a572}),_0x570823=_0xd830a8['mapper']['toViewPosition'](_0x1f7a93);_0x51ba98['data']['isSuggestion']&&_0xd830a8['writer']['addClass']('ck-suggestion-marker-'+_0x30a572+'-new',_0x1f7406),_0x5e184a['activeChange']==_0x51ba98&&_0xd830a8['writer']['addClass']('ck-suggestion-marker--active',_0x1f7406),_0xd830a8['writer']['insert'](_0x570823,_0x1f7406),_0xd830a8['mapper']['bindElementToMarker'](_0x1f7406,_0x18c761['markerName']);}_0x3d0a46||_0xe2ae3e||!_0x44e1c4||_0x11ee9d(_0x44e1c4);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x551fad,_0xcc7de2,_0x44211b)=>{const _0x1b13b8=_0x44211b['mapper']['markerNameToElements'](_0xcc7de2['markerName']);if(_0x1b13b8){for(const _0x535828 of _0x1b13b8)(_0x535828['hasClass']('ck-suggestion-marker-split')||_0x535828['hasClass']('ck-suggestion-marker-merge'))&&(_0x44211b['mapper']['unbindElementFromMarkerName'](_0x535828,_0xcc7de2['markerName']),_0x44211b['writer']['remove'](_0x535828));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x2ad563,_0x590a72,_0xdfa2b9)=>{const _0x5414f2=_0x590a72['markerName']['split'](':')[0x1],_0x466824=this['_getChangeFromId'](_0x5414f2);if(!_0x466824)return null;const _0x2fa1f3='add'==_0x466824['type']?'split':'merge';if(_0xdfa2b9['consumable']['test'](_0x590a72['markerRange'],_0x2ad563['name']))for(const _0x38bd32 of _0x590a72['markerRange']['getItems']()){if(!_0x38bd32['is']('element','softBreak'))continue;const _0x4059ed=_0xdfa2b9['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x2fa1f3}),_0x5e8401=_0xdfa2b9['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x38bd32));_0x466824['data']['isSuggestion']&&_0xdfa2b9['writer']['addClass']('ck-suggestion-marker-'+_0x2fa1f3+'-new',_0x4059ed),this['activeChange']==_0x466824&&_0xdfa2b9['writer']['addClass']('ck-suggestion-marker--active',_0x4059ed),_0xdfa2b9['writer']['insert'](_0x5e8401,_0x4059ed),_0xdfa2b9['mapper']['bindElementToMarker'](_0x4059ed,_0x590a72['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x306352=>{for(const _0xc13c04 of this['editor']['model']['document']['getRootNames']()){const _0xa5f377=this['editor']['model']['document']['getRoot'](_0xc13c04),_0x3df468=this['editor']['editing']['view']['document']['getRoot'](_0xc13c04);if(_0x3df468){const _0x3b9ea9=_0xa5f377['getAttribute']('revisionHistoryAttachChange');if(_0x306352['removeAttribute']('data-change-id',_0x3df468),_0x306352['removeClass']('ck-revision-history-root-add',_0x3df468),_0x306352['removeClass']('ck-revision-history-root-remove',_0x3df468),_0x306352['removeClass']('ck-revision-history-root--active',_0x3df468),_0x3b9ea9){const _0x13de3d=this['_getChangeFromId'](_0x3b9ea9);if(!_0x13de3d)return null;_0x306352['setAttribute']('data-change-id',_0x3b9ea9,_0x3df468),_0x306352['addClass']('ck-revision-history-root-'+_0x13de3d['type'],_0x3df468),this['activeChange']==_0x13de3d&&_0x306352['addClass']('ck-revision-history-root--active',_0x3df468);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x1792b1=>'revision-comment:'+_0x1792b1,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x346d9e=>'revision-suggestion:'+_0x346d9e,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x379c2a=>({'name':'suggestion:'+_0x379c2a,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x52eec2=>{const _0x4b995f=_0x52eec2['markerName']['split'](':')[0x1];return'insertion'!=_0x4b995f&&'deletion'!=_0x4b995f?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x4b995f]};}}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:deletion',Z(this['editor'],'merge'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:insertion',Z(this['editor'],'split'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision-suggestion',(_0x2ea725,_0x586f26,_0x154f0d)=>{const _0x4687a7=_0x154f0d['mapper']['markerNameToElements'](_0x586f26['markerName']);if(_0x4687a7){for(const _0x9d4170 of _0x4687a7)_0x9d4170['is']('uiElement')&&(_0x154f0d['mapper']['unbindElementFromMarkerName'](_0x9d4170,_0x586f26['markerName']),_0x154f0d['writer']['remove'](_0x9d4170));}},{'priority':'high'});}['_getChangeFromId'](_0x3f2659){return this['_changeIdToChange']['get'](_0x3f2659);}['_getViewForChange'](_0x479107){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new X(this['editor']['locale'],_0x479107),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x2af1c0,_0x27e572,_0xaac59a,_0x2f37d9)=>{_0x2f37d9&&this['_balloon']['remove'](_0x2f37d9),_0xaac59a&&(this['_balloon']['add']({'view':_0xaac59a,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x178f43=this['editor']['editing'],_0x1a3248=this['_getChangeFromId'](_0xaac59a['changeId']);let _0x443074;if(_0x1a3248['data']['isOnRoot']){const _0x32315f=_0x178f43['view']['getDomRoot'](_0x1a3248['rootName']);_0x443074=Array['from'](_0x32315f['getClientRects']());}else{const _0x581627=this['editor']['model']['markers']['get']('revision:'+_0xaac59a['changeId']);_0x443074=Array['from'](_0x178f43['mapper']['markerNameToElements'](_0x581627['name']))['map'](_0x205c41=>_0x178f43['view']['domConverter']['mapViewToDom'](_0x205c41))['map'](_0x426b6a=>Array['from'](_0x426b6a['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x443074[0x0];return _0x443074['find'](_0x1eed74=>_0x1eed74['top']-0x3<=this['_activeViewTarget']['y']&&_0x1eed74['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x1eed74['left']-0x3<=this['_activeViewTarget']['x']&&_0x1eed74['right']+0x3>=this['_activeViewTarget']['x'])||_0x443074[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x574bad,_0x47e1f0,_0x31e6b8,_0x28f4c3)=>{this['activeView']=_0x31e6b8?this['_getViewForChange'](_0x31e6b8):null,this['editor']['model']['change'](()=>{const _0x3d604c=this['editor']['editing'];_0x28f4c3&&(_0x28f4c3['data']['isOnRoot']?_0x3d604c['view']['change'](_0x49c1ef=>{_0x49c1ef['removeClass']('ck-revision-history-root--active',_0x3d604c['view']['document']['getRoot'](_0x28f4c3['rootName']));}):_0x3d604c['reconvertMarker']('revision:'+_0x28f4c3['id'])),_0x31e6b8&&(_0x31e6b8['data']['isOnRoot']?_0x3d604c['view']['change'](_0x370494=>{_0x370494['addClass']('ck-revision-history-root--active',_0x3d604c['view']['document']['getRoot'](_0x31e6b8['rootName']));}):_0x3d604c['reconvertMarker']('revision:'+_0x31e6b8['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x3cdf42,_0x5cc138)=>{if(this['activeChange'])return;const _0x62a32d=this['_findChangeIdFromDomTarget'](_0x5cc138['target']),_0xeafbe8=this['_changeIdToChange']['get'](_0x62a32d);_0xeafbe8?(this['_activeViewTarget']={'x':_0x5cc138['domEvent']['x'],'y':_0x5cc138['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0xeafbe8)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x4352d7,_0x490ec2)=>{const _0x2405fc=this['_findChangeIdFromDomTarget'](_0x490ec2['target']),_0xa29bdb=this['_changeIdToChange']['get'](_0x2405fc);_0xa29bdb?(this['_activeViewTarget']={'x':_0x490ec2['domEvent']['x'],'y':_0x490ec2['domEvent']['y']},_0xa29bdb===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0xa29bdb):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x3d3142){do{const _0x3ab58f=_0x3d3142['getAttribute']('data-change-id');if(_0x3ab58f)return _0x3ab58f;_0x3d3142=_0x3d3142['parent'];}while(_0x3d3142);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x4f3867=>{for(const _0x1c8009 of this['editor']['model']['markers'])_0x4f3867['removeMarker'](_0x1c8009);});}}function Z(_0xa5834,_0x43aab7){return(_0x3bf3eb,_0xea1529,_0x5b5ee6)=>{if(!_0x5b5ee6['consumable']['test'](_0xea1529['markerRange'],_0x3bf3eb['name']))return;const _0x47893b=_0xea1529['markerRange']['getWalker'](),_0x567ede=_0xea1529['markerRange']['start'],_0x5029fc=_0xa5834['model']['schema'];let _0x47bbb5=null,_0x2e9fce=null,_0x528f98=!0x1,_0x526950=!0x1;for(const _0x4b190a of _0x47893b){const _0x49631e=_0x4b190a['item'];_0x528f98=_0x528f98||_0x5029fc['isContent'](_0x49631e);const _0x512868=_0x5b5ee6['mapper']['toViewElement'](_0x49631e);if(_0x512868&&_0x512868['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x4b190a['type']&&(_0x5029fc['isBlock'](_0x49631e)&&!_0x5029fc['isLimit'](_0x49631e)&&(_0x49631e['nextSibling']||_0x567ede['isAtEnd']?_0x47bbb5&&_0x47bbb5['parent']==_0x49631e||(_0x47bbb5=_0x49631e,_0x595291(_0x4b190a['previousPosition']),_0x526950=!0x0):_0x2e9fce=_0x2e9fce||_0x4b190a['previousPosition']));}function _0x595291(_0x3fab96){const _0x4d38b5=_0x5b5ee6['mapper']['toViewPosition'](_0x3fab96),_0x1b964e=_0x5b5ee6['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x43aab7});_0x5b5ee6['writer']['insert'](_0x4d38b5,_0x1b964e),_0x5b5ee6['mapper']['bindElementToMarker'](_0x1b964e,_0xea1529['markerName']);}_0x528f98||_0x526950||!_0x2e9fce||_0x595291(_0x2e9fce);};}class wt extends _0x1db4eb{constructor(_0x2dd1b1){super(_0x2dd1b1);const _0x4ee634=_0x2dd1b1['plugins']['get'](d);this['affectsData']=!0x1,this['listenTo'](_0x4ee634,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x4ee634,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x34d8a9=this['editor'],_0x3dcbc2=_0x34d8a9['plugins']['get'](d),_0x3529d4=_0x3dcbc2['isReady']?_0x3dcbc2['diff']['newRevisionId']:null;_0x34d8a9['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x3529d4);}['refresh'](){const {isReady:_0x291e41,isEnabled:_0x55db2f,repository:_0x3b5b3c,diff:_0x316ca0}=this['editor']['plugins']['get'](d),_0x220859=_0x316ca0&&_0x3b5b3c['getLaterVisibleRevision'](_0x316ca0['newRevisionId']);this['isEnabled']=_0x291e41&&_0x55db2f&&Boolean(_0x220859);}}class _t extends _0x1db4eb{['_step'];constructor(_0x4e489d,{direction:_0x3e9d27}){super(_0x4e489d);const _0x233a85=_0x4e489d['plugins']['get'](d);this['affectsData']=!0x1,this['_step']='forward'===_0x3e9d27?0x1:-0x1,this['listenTo'](_0x233a85,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x233a85,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x233a85,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x5bfe97=this['editor'],_0x1a6b4e=_0x5bfe97['plugins']['get'](d),{isNavigationMode:_0x26c9ed,currentChangeNumber:_0x2c582d}=_0x1a6b4e;let _0x519569;if(_0x1a6b4e['activeChange']=_0x26c9ed?_0x1a6b4e['diff']['changes']['get'](_0x2c582d+this['_step']):_0x1a6b4e['diff']['changes']['first'],_0x1a6b4e['activeChange']['data']['isOnRoot'])_0x519569=_0x5bfe97['editing']['view']['getDomRoot'](_0x1a6b4e['activeChange']['rootName']);else{const _0x553244=_0x5bfe97['model']['markers']['get']('revision:'+_0x1a6b4e['activeChange']['id']);_0x519569=_0x126672(_0x5bfe97['editing'],_0x553244);}_0x44f96b({'target':_0x519569,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x4673d0,currentChangeNumber:_0x333f41,numberOfChanges:_0x5a0d19,isReady:_0x4dabd4,isEnabled:_0x4d7b14}=this['editor']['plugins']['get'](d);this['isEnabled']=!!(_0x4d7b14&&_0x4dabd4&&_0x5a0d19)&&(!_0x4673d0||(0x1===this['_step']?_0x333f41<_0x5a0d19-0x1:_0x333f41>0x0));}}class _i extends ts{constructor(_0x309d83){super(_0x309d83);const _0x24dab7=this['bindTemplate'],_0xdcb1d4=new te(_0x309d83),_0x1f8625=new te(_0x309d83);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',(_0x441c83,_0x594fb2)=>_0x441c83&&_0x594fb2>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x51d5ab,_0x5f1bbb,_0x48cdde,_0x12592c)=>{if(!_0x51d5ab)return m(_0x309d83,'Loading...');if(!_0x48cdde)return m(_0x309d83,'No\x20changes');const _0x3f3d02=m(_0x309d83,'NUMBER_OF_CHANGES',_0x48cdde);return _0x12592c?m(_0x309d83,'X_OF_Y_CHANGES',[_0x5f1bbb+0x1,_0x48cdde]):_0x3f3d02;}),_0xdcb1d4['set']({'label':m(_0x309d83,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x140ee6}),_0x1f8625['set']({'label':m(_0x309d83,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x710b16}),_0xdcb1d4['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x1f8625['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0xdcb1d4['on']('execute',()=>this['fire']('execute','backward')),_0x1f8625['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',_0x24dab7['if']('_isStatusLabelVisible','ck-hidden',_0x5c44a2=>!_0x5c44a2)]},'children':[{'text':_0x24dab7['to']('isNavigationMode',_0x3c42d7=>_0x3c42d7?m(_0x309d83,'EDIT_X_OF_Y_REVISIONS')+':\x20':m(_0x309d83,'Total')+':\x20')}]},{'text':_0x24dab7['to']('_statusText')}]},new _0x1e098a(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0xdcb1d4,_0x1f8625]}]});}}const le='ck-editor__editable__loading-overlay';class ge extends _0x5517c8{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x496341=this['editor']['editing']['view'];_0x496341['change'](_0x51f1f3=>{for(const _0x2572be of _0x496341['document']['roots'])_0x51f1f3['addClass'](le,_0x2572be);});}['hide'](){const _0x5f3b2d=this['editor']['editing']['view'];_0x5f3b2d['change'](_0xf3fc66=>{for(const _0x5112fc of _0x5f3b2d['document']['roots'])_0xf3fc66['removeClass'](le,_0x5112fc);});}}class w extends _0x5517c8{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[d,ge];}['init'](){const _0x1aab6b=this['editor'],_0x302a4c=_0x1aab6b['plugins']['get'](d),_0x53351b=_0x1aab6b['plugins']['get'](ge);_0x1aab6b['ui']['componentFactory']['add']('exitToEditing',_0x333e1f=>{const _0x441de1=new te(_0x333e1f);return _0x441de1['set']({'label':m(_0x333e1f,'Back\x20to\x20editing'),'icon':_0x5332e8,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x441de1,'execute',()=>{_0x1aab6b['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x441de1;}),_0x1aab6b['ui']['componentFactory']['add']('restoreRevision',_0x12e7d2=>{const _0x5f2680=new te(_0x12e7d2);return _0x5f2680['set']({'label':m(_0x12e7d2,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x5f2680['bind']('isEnabled')['to'](_0x1aab6b['commands']['get']('restoreRevision')),this['listenTo'](_0x5f2680,'execute',()=>_0x1aab6b['execute']('restoreRevision')),_0x5f2680;}),_0x1aab6b['ui']['componentFactory']['add']('changesNavigation',_0x16ab08=>{const _0x464e65=new _i(_0x16ab08),_0x1e5c4e=_0x1aab6b['commands']['get']('showPreviousChange'),_0xfae7d8=_0x1aab6b['commands']['get']('showNextChange');return _0x464e65['bind']('isBackwardNavigationEnabled')['to'](_0x1e5c4e,'isEnabled'),_0x464e65['bind']('isForwardNavigationEnabled')['to'](_0xfae7d8,'isEnabled'),_0x464e65['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x302a4c),this['listenTo'](_0x464e65,'execute',(_0x594383,_0x2c2830)=>{_0x1aab6b['execute']('forward'===_0x2c2830?'showNextChange':'showPreviousChange');}),_0x464e65;}),_0x53351b['show'](),_0x302a4c['on']('change:isReady',(_0x304822,_0x1c32c3,_0x5863fa)=>{_0x5863fa?_0x53351b['hide']():_0x53351b['show']();});}}class pt extends _0x231adc{['_resizeObserver']=null;constructor(_0x50b08c,_0x4bea28){super(_0x50b08c,_0x4bea28);const _0x1ec564=this['bindTemplate'];this['set']({'label':m(_0x50b08c,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=m(_0x50b08c,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x1ec564['to']('_tooltipString'),'data-cke-tooltip-position':'s','data-cke-tooltip-class':'ck-tooltip_multi-line'}});}['render'](){super['render'](),this['_resizeObserver']=new at(this['fieldView']['element'],()=>this['_updateTooltipText']()),this['listenTo'](this['fieldView'],'input',()=>this['_updateTooltipText']());}['destroy'](){super['destroy'](),this['_resizeObserver']&&this['_resizeObserver']['destroy']();}['_updateTooltipText'](){const _0x3f0e20=this['fieldView']['element'];this['_tooltipString']=_0x3f0e20['scrollWidth']>_0x3f0e20['clientWidth']&&_0x3f0e20['value']||'';}}class si extends ts{constructor(_0x1ea28e,_0x2c9f27,_0x4e61a8){super(_0x1ea28e);const _0x2b5392=new _0x5762d1();_0x2b5392['set']({'content':_0x1792fe,'viewBox':'0\x200\x2011\x2010'});const _0x1c100d=['ck','ck-revision-history-sidebar__revision-author'];_0x4e61a8&&_0x1c100d['push']('ck-revision-history-sidebar__revision-author_creator');const _0x2e91c4=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':m(_0x1ea28e,_0x4e61a8?'Revision\x20creator':'Revision\x20author')},'children':[_0x2b5392,_0x2c9f27['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x1c100d},'children':_0x2e91c4});}}function oi(_0x5e7623,_0x34839b){const _0x1a0417=_0x5e7623['bindTemplate'],_0x33d524=_0x5e7623['locale'],_0x20fa47=_0x461af0(_0x33d524);_0x20fa47['panelPosition']='sw';const _0x3903cf=function(_0x56817d,_0x47ea50){const _0x53af62=function(_0x28b2a9,_0x2b8b18){const _0x135cd0=_0x28b2a9['locale'],_0x3d7040={'Compare\x20against\x20selected':m(_0x135cd0,'Compare\x20against\x20selected'),'Name\x20this\x20revision':m(_0x135cd0,'Name\x20this\x20revision'),'Restore\x20this\x20revision':m(_0x135cd0,'Restore\x20this\x20revision')};return _0x2b8b18['map'](_0x5e84de=>{const _0x1b47a5=_0x3d7040[_0x5e84de['name']];return _0x1b47a5&&_0x1b47a5!==_0x5e84de['name']&&(_0x5e84de['name']=_0x1b47a5),_0x5e84de;});}(_0x56817d,_0x47ea50),_0x225f94=new _0x1b37a4();for(const _0x20ef66 of _0x53af62){const _0x17936d={'type':'button','model':new to({'label':_0x20ef66['name'],'class':_0x20ef66['class'],'withText':!0x0,'role':'menuitem','_action':_0x20ef66['action']})};_0x17936d['model']['bind']('isEnabled')['to'](_0x56817d,'isActionsDropdownOpen',_0xa5fa97=>'function'!=typeof _0x20ef66['isEnabled']||(!_0xa5fa97||_0x20ef66['isEnabled'](_0x56817d))),_0x225f94['add'](_0x17936d);}return _0x225f94;}(_0x5e7623,_0x34839b);return _0x5e7623['bind']('isActionsDropdownOpen')['to'](_0x20fa47,'isOpen'),_0x20fa47['buttonView']['set']({'label':m(_0x33d524,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0xf69623}),_0x20fa47['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x1a0417['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x1a0417['to'](_0x505668=>_0x505668['stopPropagation']())}}),_0x20fa47['on']('execute',_0x1ed6f1=>{_0x5e7623['isReady']&&'function'==typeof _0x1ed6f1['source']['_action']&&_0x1ed6f1['source']['_action'](_0x5e7623);}),_0x570a7f(_0x20fa47,_0x3903cf,{'role':'menu'}),_0x20fa47['listenTo'](_0x5e7623,'change:isActionsDropdownOpen',(_0x49e04c,_0x1fe025,_0x13ee96)=>{if(_0x13ee96)for(const _0xc8989a of _0x20fa47['listView']['items']){const _0x248f9a=_0xc8989a['children']['first'],_0x569fad=_0x34839b['find'](_0x505cbb=>_0x505cbb['action']===_0x248f9a['_action'])['isVisible'];_0xc8989a['isVisible']=void 0x0===_0x569fad||_0x569fad(_0x5e7623);}}),_0x20fa47;}class hi extends/* #__PURE__ -- @preserve */
|
|
26
|
-
|
|
23
|
+
import{ObservableMixin as _0x2d9680,uid as _0x358749,Collection as _0x42ce0a,logWarning as _0x13b4f9,FocusTracker as _0x14a05e,KeystrokeHandler as _0x593668,scrollViewportToShowTarget as _0x182fa2,ResizeObserver as at,ElementReplacer as ht,CKEditorError as _0x5f4f1d}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x49c00c,set as _0x3ee33f,unset as _0x1b0d3c,isEqual as _0x31d3ce}from'lodash-es';import{Plugin as _0x38c4e4,PendingActions as _0x26d8a9,icons as _0x226c5d,Command as _0x56d2a8,ElementApiMixin as it,Editor as tt}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x25c78c,getMarkerDomElement as _0x3ac489,ConfirmMixin as _0x43bb9d,sanitizeEditorConfig as _0x1e169a}from'ckeditor5-collaboration/dist/index.js';import{ViewDocumentFragment as _0xe0cd86,Element as ft,Range as vt,ViewUIElement as _0x2dca08,ViewRawElement as _0x11a6f7,ViewEmptyElement as _0x48c1f7,ViewAttributeElement as _0x2053cd,ViewContainerElement as _0x73e509,Position as gt,ViewText as _0x293831,ViewElement as _0x1faa4b,DocumentFragment as mt,Text as wt}from'@ckeditor/ckeditor5-engine/dist/index.js';import{View as _0x3f0f05,injectCssTransitionDisabler as ts,submitHandler as _0x6652f9,LabeledFieldView as nt,createLabeledInputText as _0x1d572c,createDropdown as _0x2a9d1c,ListView as te,ListItemView as _0x451921,ButtonView as _0x13b3b7,MenuBarMenuView as _0x1b77ca,MenuBarMenuListView as _0x3b79b8,MenuBarMenuListItemView as _0x50d7f2,MenuBarMenuListItemButtonView as _0x37066d,ContextualBalloon as _0x377694,ToolbarSeparatorView as _0x492e02,IconView as _0x5787b7,addListToDropdown as _0x546d70,ViewModel as to,EditorUI as st,normalizeToolbarConfig as ot,BoxedEditorUIView as ct,StickyPanelView as ut,ToolbarView as lt,InlineEditableUIView as dt}from'@ckeditor/ckeditor5-ui/dist/index.js';import{DateTime as _0x446d2f}from'luxon';class a extends/* #__PURE__ -- @preserve */
|
|
24
|
+
_0x2d9680(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x1ae52d){super(),this['id']=_0x1ae52d['id']||_0x358749(),this['creator']=_0x1ae52d['creator']||null,this['authors']=_0x1ae52d['authors']||[],this['diffData']=_0x1ae52d['diffData']||null,this['toVersion']=_0x1ae52d['toVersion']||0x0,this['fromVersion']=_0x1ae52d['fromVersion']||0x0,this['set']('name',_0x1ae52d['name']||''),this['set']('createdAt',_0x1ae52d['createdAt']||new Date()),this['set']('attributes',_0x1ae52d['attributes']||{});}['setName'](_0x54295b){this['_update']({'name':_0x54295b});}['setAttribute'](_0x41d357,_0x2c1f26){const _0x43e069=_0x49c00c(this['attributes']);_0x3ee33f(_0x43e069,_0x41d357,_0x2c1f26),this['_update']({'attributes':_0x43e069});}['removeAttribute'](_0x213254){const _0x296243=_0x49c00c(this['attributes']);_0x1b0d3c(_0x296243,_0x213254),this['_update']({'attributes':_0x296243});}['_update'](_0xcfb2ca,_0x41d94f=!0x1){let _0xf0de75=!0x1;const _0x7081e1={'id':this['id']},_0x138886=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x7f2046 of _0x138886){const _0x46295a=_0xcfb2ca[_0x7f2046];void 0x0!==_0x46295a&&_0x46295a!==this[_0x7f2046]&&(this[_0x7f2046]=_0x46295a,_0x7081e1[_0x7f2046]=_0x46295a,_0xf0de75=!0x0);}_0xf0de75&&(_0x7081e1['authors']&&(_0x7081e1['authorsIds']=_0x7081e1['authors']['map'](_0x246c92=>_0x246c92['id']),delete _0x7081e1['authors']),this['fire']('_update',_0x7081e1,_0x41d94f));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x5c06bf=>_0x5c06bf['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class j extends _0x38c4e4{['_revisions'];static get['requires'](){return[_0x25c78c];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x4695aa){super(_0x4695aa),this['_revisions']=new _0x42ce0a();}['afterInit'](){!async function(_0x2cef2e){const _0x1f242c=_0x57046b([0x65,0x6e,0x75,0x37,0x34,0x30,0x73,0x4a,0x74,0x6d,0x6a,0x69,0x39,0x68,0x76,0x63,0x4b,0x52,0x70,0x48,0x55,0x59,0x71,0x42,0x4d,0x38,0x58,0x43,0x6c,0x4c,0x33,0x64,0x53,0x79,0x31,0x36,0x45,0x78,0x4e,0x47,0x77,0x41,0x61,0x49,0x72,0x32,0x62,0x35,0x6b,0x54,0x51,0x50,0x56,0x5a,0x6f,0x44,0x7a,0x46,0x57,0x4f,0x67,0x66]),_0x9286e6=0xeb829,_0x28cc5e=0x485a3396,_0x2edb87=0x485d6cee^_0x28cc5e,_0x533119=window[_0x57046b([0x44,0x61,0x74,0x65])][_0x57046b([0x6e,0x6f,0x77])](),_0xf3340a=_0x2cef2e[_0x57046b([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x40c578=new window[(_0x57046b([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x175cc0=>{_0xf3340a[_0x57046b([0x6f,0x6e,0x63,0x65])](_0x57046b([0x72,0x65,0x61,0x64,0x79]),_0x175cc0);}),_0x43775d={[_0x57046b([0x6b,0x74,0x79])]:_0x57046b([0x45,0x43]),[_0x57046b([0x75,0x73,0x65])]:_0x57046b([0x73,0x69,0x67]),[_0x57046b([0x63,0x72,0x76])]:_0x57046b([0x50,0x2d,0x32,0x35,0x36]),[_0x57046b([0x78])]:_0x57046b([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]),[_0x57046b([0x79])]:_0x57046b([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]),[_0x57046b([0x61,0x6c,0x67])]:_0x57046b([0x45,0x53,0x32,0x35,0x36])},_0x1aeeaa=_0xf3340a[_0x57046b([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x57046b([0x67,0x65,0x74])](_0x57046b([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x1513c6(){let _0x333444,_0x473774=null,_0x5353c6=null;try{if(_0x1aeeaa==_0x57046b([0x47,0x50,0x4c]))return _0x57046b([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x333444=_0x33b3bc(),!_0x333444)return _0x57046b([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x333444[_0x57046b([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x5353c6=_0x11c754(_0x333444[_0x57046b([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x333444[_0x57046b([0x6a,0x74,0x69])])),await _0x1406ed()?_0x4418e4()?_0x5f5928()?_0x57046b([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x168d87()?(_0x333444[_0x57046b([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x57046b([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x473774=_0x339e81(_0x57046b([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x333444[_0x57046b([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x57046b([0x74,0x72,0x69,0x61,0x6c])&&(_0x473774=_0x339e81(_0x57046b([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x1495dd()):_0x57046b([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x57046b([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x57046b([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch(_0x2f0034){return _0x57046b([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x5f5928(){const _0x47f9b3=[_0x57046b([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x57046b([0x74,0x72,0x69,0x61,0x6c])][_0x57046b([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x333444[_0x57046b([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x533119/0x3e8:0xe10*_0x2edb87;return _0x333444[_0x57046b([0x65,0x78,0x70])]<_0x47f9b3;}function _0x4418e4(){const _0x39cb00=_0x333444[_0x57046b([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x39cb00)return!0x1;if(_0x39cb00[_0x57046b([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x57046b([0x2a])))return!0x0;if(_0x39cb00[_0x57046b([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x57046b([0x52,0x48])))return!0x0;if(_0x39cb00[_0x57046b([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x57046b([0x52,0x52,0x48]))){if(_0x4888bf())return!0x0;if(_0x179126()||_0x4b20e3())return!0x0;}return!0x1;}function _0x168d87(){const _0x56a7b3=_0x333444[_0x57046b([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x56a7b3||0x0==_0x56a7b3[_0x57046b([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x4264e8}=new URL(window[_0x57046b([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x56a7b3[_0x57046b([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4264e8))return!0x0;const _0x5f0b76=_0x4264e8[_0x57046b([0x73,0x70,0x6c,0x69,0x74])](_0x57046b([0x2e]));return _0x56a7b3[_0x57046b([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x456d31=>_0x456d31[_0x57046b([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x57046b([0x2a])))[_0x57046b([0x6d,0x61,0x70])](_0x3f560c=>_0x3f560c[_0x57046b([0x73,0x70,0x6c,0x69,0x74])](_0x57046b([0x2e])))[_0x57046b([0x73,0x6f,0x6d,0x65])](_0x5a9ed5=>_0x5f0b76[_0x57046b([0x65,0x76,0x65,0x72,0x79])]((_0x50c6b8,_0x3d3896)=>_0x5a9ed5[_0x3d3896]===_0x50c6b8||_0x5a9ed5[_0x3d3896]===_0x57046b([0x2a])));}function _0x1495dd(){return _0x473774&&_0x5353c6?new window[(_0x57046b([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x3a4135,_0x2c83de)=>{_0x473774[_0x57046b([0x74,0x68,0x65,0x6e])](_0x3a4135,_0x2c83de),_0x5353c6[_0x57046b([0x74,0x68,0x65,0x6e])](_0x3854c3=>{_0x3854c3!=_0x57046b([0x56,0x61,0x6c,0x69,0x64])&&_0x3a4135(_0x3854c3);},_0x2c83de);}):_0x473774||_0x5353c6||_0x57046b([0x56,0x61,0x6c,0x69,0x64]);}}function _0x11c754(_0x2d12fc,_0x393152){return new window[(_0x57046b([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x4f8537=>{if(_0x538a29())return _0x4f8537(_0x57046b([0x56,0x61,0x6c,0x69,0x64]));_0x75e90b(),_0xf3340a[_0x57046b([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x57046b([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x14ede4=!0x1;const _0x9b8b5d=_0x358749();function _0x1113e6(_0x2c9426){return!!_0x2c9426&&(typeof _0x2c9426===_0x57046b([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x2c9426===_0x57046b([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x2c9426[_0x57046b([0x74,0x68,0x65,0x6e])]===_0x57046b([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x2c9426[_0x57046b([0x63,0x61,0x74,0x63,0x68])]===_0x57046b([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x10a85b(_0x4adfb2){_0x1271c1(_0x4adfb2)[_0x57046b([0x74,0x68,0x65,0x6e])](_0x3ec7b5=>{if(!_0x3ec7b5||_0x3ec7b5[_0x57046b([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x57046b([0x6f,0x6b]))return _0x57046b([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x127619(_0x339c27(_0x9b8b5d+_0x393152))!=_0x3ec7b5[_0x57046b([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x57046b([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x57046b([0x56,0x61,0x6c,0x69,0x64]);})[_0x57046b([0x74,0x68,0x65,0x6e])](_0x443e9b=>(_0x567192(),_0x443e9b),()=>{const _0x5a1c9e=_0x2d18f1();return null==_0x5a1c9e?(_0x567192(),_0x57046b([0x56,0x61,0x6c,0x69,0x64])):_0x57046b(_0x533119-_0x5a1c9e>(0x6c56b796^_0x28cc5e)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x57046b([0x74,0x68,0x65,0x6e])](_0x4f8537)[_0x57046b([0x63,0x61,0x74,0x63,0x68])](()=>{_0x4f8537(_0x57046b([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x361f65=0x486cdd16^_0x28cc5e;function _0x567192(){const _0x577797=_0x57046b([0x6c,0x6c,0x63,0x74,0x2d])+_0x127619(_0x339c27(_0x2d12fc)),_0x140f4c=_0x5e91fb(_0x127619(window[_0x57046b([0x4d,0x61,0x74,0x68])][_0x57046b([0x63,0x65,0x69,0x6c])](_0x533119/_0x361f65)));window[_0x57046b([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x57046b([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x577797,_0x140f4c);}function _0x2d18f1(){const _0x6a1194=_0x57046b([0x6c,0x6c,0x63,0x74,0x2d])+_0x127619(_0x339c27(_0x2d12fc)),_0x3ee4c6=window[_0x57046b([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x57046b([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x6a1194);return _0x3ee4c6?window[_0x57046b([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x5e91fb(_0x3ee4c6),0x10)*_0x361f65:null;}function _0x1271c1(_0x53777c){return new window[(_0x57046b([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x1d7e0d,_0x39684d)=>{_0x53777c[_0x57046b([0x74,0x68,0x65,0x6e])](_0x1d7e0d,_0x39684d),window[_0x57046b([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x39684d,0x485be756^_0x28cc5e);});}}_0xf3340a[_0x57046b([0x6f,0x6e])](_0x57046b([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x57fb63,_0x17ffd0)=>{if(_0x17ffd0[0x0]!=_0x2d12fc)return _0x4f8537(_0x57046b([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x17ffd0[0x1]={..._0x17ffd0[0x1],[_0x57046b([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x9b8b5d};},{[_0x57046b([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x57046b([0x68,0x69,0x67,0x68])}),_0xf3340a[_0x57046b([0x6f,0x6e])](_0x57046b([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x44ec76=>{_0x1113e6(_0x44ec76[_0x57046b([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x14ede4=!0x0,_0x10a85b(_0x44ec76[_0x57046b([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x57046b([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x57046b([0x6c,0x6f,0x77])}),_0x40c578[_0x57046b([0x74,0x68,0x65,0x6e])](()=>{_0x14ede4||_0x4f8537(_0x57046b([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x538a29(){return _0xf3340a[_0x57046b([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x57046b([0x76,0x69,0x65,0x77])][_0x57046b([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x57046b([0x61,0x75,0x74,0x6f]);}function _0x75e90b(){_0xf3340a[_0x57046b([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x57046b([0x76,0x69,0x65,0x77])][_0x57046b([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x57046b([0x61,0x75,0x74,0x6f]);}}function _0x339e81(_0x35707c){const _0x1b01da=[new window[(_0x57046b([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x21e991=>setTimeout(_0x21e991,0x48530d5a^_0x28cc5e)),_0x40c578[_0x57046b([0x74,0x68,0x65,0x6e])](()=>new window[(_0x57046b([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x3a37ba=>{const _0x56013e=0x485a3391^_0x28cc5e,_0x4b1c82=_0x2cef2e[_0x57046b([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x1a4820(){_0x4b1c82[_0x57046b([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x56013e&&_0x3a37ba();}_0x1a4820(),_0x4b1c82[_0x57046b([0x6f,0x6e])](_0x57046b([0x61,0x64,0x64]),_0x1a4820);})),new window[(_0x57046b([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x36a1d7=>{function _0x471e59(){for(const _0x1813e6 in window)if(window[_0x57046b([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x57046b([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x1813e6))&&window[_0x1813e6]==_0x9286e6)return _0x36a1d7();_0xf3340a[_0x57046b([0x73,0x74,0x61,0x74,0x65])]!=_0x57046b([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x57046b([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x471e59,0x485a201e^_0x28cc5e);}_0x9a30ab(_0x57046b([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x471e59();})];return window[_0x57046b([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x57046b([0x72,0x61,0x63,0x65])](_0x1b01da)[_0x57046b([0x74,0x68,0x65,0x6e])](()=>_0x35707c);}async function _0x87122e(){if(await _0x40c578,_0x9a30ab(_0x57046b([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x11ada1=_0x2cef2e[_0x57046b([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x2f23c8=_0x2cef2e[_0x57046b([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])](_0x11ada1[_0x57046b([0x69,0x64])]),_0x5096d1=_0x4aba69(_0x57046b([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x5096d1[_0x57046b([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x11ada1['id'],_0x2f23c8?_0x2f23c8['id']:null,!0x0),_0x5096d1[_0x57046b([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x57046b([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x5096d1[_0x57046b([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x5096d1[_0x57046b([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x43a8f0,void(_0x5096d1[_0x57046b([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x43a8f0);}if(_0x9a30ab(_0x57046b([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x129b06=_0x4aba69(_0x57046b([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x129b06[_0x57046b([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x57046b([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x129b06[_0x57046b([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x129b06[_0x57046b([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x43a8f0,_0x129b06[_0x57046b([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x43a8f0;}_0xf3340a[_0x57046b([0x6d,0x6f,0x64,0x65,0x6c])][_0x57046b([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x43a8f0,_0xf3340a[_0x57046b([0x6d,0x6f,0x64,0x65,0x6c])][_0x57046b([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x43a8f0,_0xf3340a[_0x57046b([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x57046b([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x4888bf(){return _0x9a30ab(_0x57046b([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x4aba69(_0x57046b([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x57046b([0x73,0x74,0x61,0x74,0x65])]==_0x57046b([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x179126(){return _0x9a30ab(_0x57046b([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 _0x4b20e3(){return _0x9a30ab(_0x57046b([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0xa2b783(_0x339481){const _0x3cccb9=_0x153735();_0xf3340a[_0x3cccb9]=_0x57046b([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])+_0x339481,_0x339481[_0x57046b([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x57046b([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x153735()]=_0x9286e6),_0x339481!=_0x57046b([0x56,0x61,0x6c,0x69,0x64])&&_0x87122e();}function _0x153735(){const _0x2473e4=window[_0x57046b([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x57046b([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x57046b([0x6e,0x6f,0x77])]())[_0x57046b([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x57046b([0x2e]),'');let _0x283e27=_0x57046b([0x65]);for(let _0xeb6713=0x0;_0xeb6713<_0x2473e4[_0x57046b([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0xeb6713+=0x2){let _0x519b5f=window[_0x57046b([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x2473e4[_0x57046b([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0xeb6713,_0xeb6713+0x2));_0x519b5f>=_0x1f242c[_0x57046b([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x519b5f-=_0x1f242c[_0x57046b([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x283e27+=_0x1f242c[_0x519b5f];}return _0x283e27;}function _0x33b3bc(){const _0x57e801=_0x1aeeaa[_0x57046b([0x73,0x70,0x6c,0x69,0x74])](_0x57046b([0x2e]));if(0x3!=_0x57e801[_0x57046b([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x39b9b9(_0x57e801[0x1]);function _0x39b9b9(_0x2f2f97){const _0x29251f=_0x205b21(_0x2f2f97);return _0x29251f&&_0x18875b()?_0x29251f:null;function _0x18875b(){const _0x106413=_0x29251f[_0x57046b([0x6a,0x74,0x69])],_0x30a335=window[_0x57046b([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x106413[_0x57046b([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x106413[_0x57046b([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x2976a4={..._0x29251f,[_0x57046b([0x6a,0x74,0x69])]:_0x106413[_0x57046b([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x106413[_0x57046b([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x2976a4[_0x57046b([0x76,0x63])],_0x339c27(_0x2976a4)==_0x30a335;}}}async function _0x1406ed(){let _0x45c440=!0x0;try{const _0x526a5d=_0x1aeeaa[_0x57046b([0x73,0x70,0x6c,0x69,0x74])](_0x57046b([0x2e])),[_0x1aa3b7,_0x29b5ac,_0x14a3d7]=_0x526a5d;return _0x44dbb4(_0x1aa3b7),await _0x46426e(_0x1aa3b7,_0x29b5ac,_0x14a3d7),_0x45c440;}catch(_0x774b05){return!0x1;}function _0x44dbb4(_0x5c991d){const _0x1c028a=_0x205b21(_0x5c991d);_0x1c028a&&_0x1c028a[_0x57046b([0x61,0x6c,0x67])]==_0x57046b([0x45,0x53,0x32,0x35,0x36])||(_0x45c440=!0x1);}async function _0x46426e(_0x1f35fe,_0x3dedd4,_0x27561d){const _0x3747ed=window[_0x57046b([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x57046b([0x66,0x72,0x6f,0x6d])](_0x15b33a(_0x27561d),_0x4cf308=>_0x4cf308[_0x57046b([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x511b59=new window[(_0x57046b([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x57046b([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x1f35fe+_0x57046b([0x2e])+_0x3dedd4),_0x431dc0=window[_0x57046b([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x57046b([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x431dc0)return;const _0x2d67b8=await _0x431dc0[_0x57046b([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x57046b([0x6a,0x77,0x6b]),_0x43775d,{[_0x57046b([0x6e,0x61,0x6d,0x65])]:_0x57046b([0x45,0x43,0x44,0x53,0x41]),[_0x57046b([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x57046b([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x57046b([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x431dc0[_0x57046b([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x57046b([0x6e,0x61,0x6d,0x65])]:_0x57046b([0x45,0x43,0x44,0x53,0x41]),[_0x57046b([0x68,0x61,0x73,0x68])]:{[_0x57046b([0x6e,0x61,0x6d,0x65])]:_0x57046b([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x2d67b8,_0x3747ed,_0x511b59)||(_0x45c440=!0x1);}}function _0x205b21(_0x2104b4){return _0x2104b4[_0x57046b([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x57046b([0x65,0x79]))?JSON[_0x57046b([0x70,0x61,0x72,0x73,0x65])](_0x15b33a(_0x2104b4)):null;}function _0x15b33a(_0x30cbbf){return window[_0x57046b([0x61,0x74,0x6f,0x62])](_0x30cbbf[_0x57046b([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x57046b([0x2b]))[_0x57046b([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x57046b([0x2f])));}function _0x339c27(_0x225c2a){let _0x3727e8=0x1505;function _0x3870e5(_0x348fe1){for(let _0x1f8dd2=0x0;_0x1f8dd2<_0x348fe1[_0x57046b([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x1f8dd2++){const _0x5aad66=_0x348fe1[_0x57046b([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x1f8dd2);_0x3727e8=(_0x3727e8<<0x5)+_0x3727e8+_0x5aad66,_0x3727e8&=_0x3727e8;}}function _0x2bb10a(_0x31fc59){Array[_0x57046b([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x31fc59)?_0x31fc59[_0x57046b([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x2bb10a):_0x31fc59&&typeof _0x31fc59==_0x57046b([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x57046b([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x31fc59)[_0x57046b([0x73,0x6f,0x72,0x74])]()[_0x57046b([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x4f16ee,_0x377730])=>{_0x3870e5(_0x4f16ee),_0x2bb10a(_0x377730);}):_0x3870e5(window[_0x57046b([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x31fc59));}return _0x2bb10a(_0x225c2a),_0x3727e8>>>0x0;}function _0x127619(_0x113b22){return _0x113b22[_0x57046b([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x57046b([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x57046b([0x30]));}function _0x5e91fb(_0x18bb99){return _0x18bb99[_0x57046b([0x73,0x70,0x6c,0x69,0x74])]('')[_0x57046b([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x57046b([0x6a,0x6f,0x69,0x6e])]('');}function _0x9a30ab(_0x3e3294){return _0xf3340a[_0x57046b([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x57046b([0x68,0x61,0x73])](_0x3e3294);}function _0x4aba69(_0x63d2c9){return _0xf3340a[_0x57046b([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x57046b([0x67,0x65,0x74])](_0x63d2c9);}function _0x43a8f0(){}function _0x57046b(_0x5ed014){return _0x5ed014['map'](_0x79cd97=>String['fromCharCode'](_0x79cd97))['join']('');}_0xa2b783(await _0x1513c6());}(this);}['createRevision'](_0x1f665c){const _0x11b228=this['editor']['plugins']['get']('Users');return new a({'id':_0x1f665c['id'],'name':_0x1f665c['name'],'creator':_0x1f665c['creatorId']?_0x11b228['getUser'](_0x1f665c['creatorId']):null,'diffData':_0x1f665c['diffData']||_0x1f665c['data'],'authors':_0x1f665c['authorsIds']['map'](_0x32ce3c=>_0x11b228['getUser'](_0x32ce3c)),'createdAt':new Date(_0x1f665c['createdAt']),'attributes':_0x1f665c['attributes'],'fromVersion':_0x1f665c['fromVersion'],'toVersion':_0x1f665c['toVersion']});}['addRevision'](_0x17d660,_0x40393d=0x0){this['_revisions']['add'](_0x17d660,_0x40393d);}['getRevision'](_0x3a327a){return this['_revisions']['get'](_0x3a327a);}['getRevisions'](_0x582f61={'toJSON':!0x1}){const _0x3bd789=Array['from'](this['_revisions']);return _0x3bd789['reverse'](),_0x582f61['toJSON']?_0x3bd789['map'](_0x4e143f=>_0x4e143f['toJSON']()):_0x3bd789;}['getIndex'](_0x39dd01){return this['_revisions']['getIndex'](_0x39dd01);}['getEarlierVisibleRevision'](_0x5c75c2){const [,_0x2ed04e]=this['getRevisionsIterator'](_0x5c75c2,{'direction':'earlier'});return _0x2ed04e;}['getLaterVisibleRevision'](_0x5cbaca){const [,_0xf9d12]=this['getRevisionsIterator'](_0x5cbaca,{'direction':'later'});return _0xf9d12;}['getRevisionsInDiff'](_0x5c7cde){const _0x542575=[];for(const _0x3b11f1 of this['getRevisionsIterator'](_0x5c7cde['newRevisionId']))if(_0x542575['push'](_0x3b11f1),_0x3b11f1['id']===_0x5c7cde['oldRevisionId'])break;return _0x542575;}*['getRevisionsIterator'](_0x4f5362,{direction:_0x3dfb29='earlier',filter:_0x4ee31a=()=>!0x0}={}){const _0x2be090='earlier'===_0x3dfb29?0x1:-0x1;let _0x14fea7=this['_revisions']['get'](_0x4f5362),_0x40a96d=this['getIndex'](_0x14fea7);for(yield _0x14fea7;_0x14fea7;){if(_0x40a96d+=_0x2be090,_0x14fea7=this['getRevision'](_0x40a96d),!_0x14fea7)return;_0x4ee31a(_0x14fea7)&&(yield _0x14fea7);}}}function m(_0x2e6b2d,_0x5e1234,_0x41e7a9){const t=_0x2e6b2d['t'];switch(_0x5e1234){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'},_0x41e7a9);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x41e7a9);case'Show\x20previous\x20change':return t('Show\x20previous\x20change');case'Show\x20next\x20change':return t('Show\x20next\x20change');case'EDIT_X_OF_Y_REVISIONS':return t({'string':'Edit','id':'EDIT_X_OF_Y_REVISIONS'});case'Total':return t('Total');case'Revision\x20creator':return t('Revision\x20creator');case'Revision\x20author':return t('Revision\x20author');case'Revision\x20name':return t('Revision\x20name');case'Save\x20current\x20revision':return t('Save\x20current\x20revision');case'Accept':return t('Accept');case'Save':return t('Save');case'Cancel':return t('Cancel');case'Name\x20of\x20the\x20revision':return t('Name\x20of\x20the\x20revision');case'optional':return t('optional');case'PENDING_ACTION_REVISION_HISTORY':return t({'string':'Unsaved\x20change\x20in\x20revision\x20history.','id':'PENDING_ACTION_REVISION_HISTORY'});case'The\x20revision\x20name\x20cannot\x20be\x20empty.':return t('The\x20revision\x20name\x20cannot\x20be\x20empty.');case'Enter\x20the\x20revision\x20name':return t('Enter\x20the\x20revision\x20name');default:return'';}}const P={'c':_0x73e509,'a':_0x2053cd,'e':_0x48c1f7,'r':_0x11a6f7,'u':_0x2dca08};class l extends _0x38c4e4{['licenseKey'];['_licenseKeyCheckInterval'];['adapter'];['currentRevision'];['repository'];['_revisionDataBuilder'];['_source'];['_initialRevisionId'];['_bufferedUpdates'];['_pendingAction'];['_continueCurrentRevision'];['_startingVersion'];['_loadedStateData'];static get['pluginName'](){return'RevisionTracker';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[_0x25c78c,j,_0x26d8a9];}constructor(_0x1aa353){super(_0x1aa353),this['adapter']=null,this['currentRevision']=null,this['_revisionDataBuilder']=new V(this['editor']),this['_initialRevisionId']=this['editor']['config']['get']('collaboration.channelId')||'initial',this['_bufferedUpdates']=new Map(),this['_loadedStateData']=null;const _0x396517=_0x358749();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x396517},this['set']('isReady',!0x1),this['set']('isEnabled',!0x0),this['set']('_isPendingUpdate',!0x1),this['editor']['config']['define']('revisionHistory.resumeUnsavedRevision',!0x0),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'});}['init'](){this['repository']=this['editor']['plugins']['get']('RevisionsRepository'),this['_setConversion'](),this['editor']['data']['on']('ready',()=>{const _0x59e56d=this['repository']['getRevision'](0x0),_0x31e3f9=_0x59e56d&&null===_0x59e56d['creator']?_0x59e56d:null;if(this['_continueCurrentRevision']=!!_0x31e3f9&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x3c1bc3=this['_source']['getCurrentRevisionId'](),_0x5a6075=this['repository']['getRevision'](_0x3c1bc3);if(_0x5a6075)this['_startingVersion']=_0x5a6075['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0xd5650b=this['_source']['history']['_operations']['find'](_0x46c82d=>!_0x46c82d['_isInit']),_0x14a87d=_0xd5650b?_0xd5650b['baseVersion']:this['_source']['history']['version'];_0x59e56d?(_0x59e56d['toVersion']<_0x14a87d&&_0x59e56d['_update']({'toVersion':_0x14a87d}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x31e3f9['id'],this['_startingVersion']=_0x31e3f9['fromVersion']):(this['_startingVersion']=_0x59e56d['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x14a87d,this['_continueCurrentRevision']=!0x1);}}else _0x31e3f9&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x31e3f9['toVersion'],this['editor']['model']['document']['history']['version']),_0x31e3f9['fromVersion']===_0x31e3f9['toVersion']?(0x0!==_0x31e3f9['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x31e3f9['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x31e3f9['id'],this['_startingVersion']=_0x31e3f9['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',_0x2b082f=>!_0x2b082f),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x151787=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x50d284;for(const _0x183023 in _0x151787){const _0x76851f=_0x183023,_0xfdc778=_0x151787[_0x76851f];if('revisionHistoryLicenseKeyValid'==_0xfdc778||'revisionHistoryLicenseKeyInvalid'==_0xfdc778||'revisionHistoryLicenseKeyExpired'==_0xfdc778||'revisionHistoryLicenseKeyDomainLimit'==_0xfdc778||'revisionHistoryLicenseKeyNotAllowed'==_0xfdc778||'revisionHistoryLicenseKeyEvaluationLimit'==_0xfdc778||'revisionHistoryLicenseKeyTrialLimit'==_0xfdc778||'revisionHistoryLicenseKeyUsageLimit'==_0xfdc778){delete _0x151787[_0x76851f],_0x50d284=_0xfdc778,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x50d284&&_0x151787['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x50d284&&_0x151787['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x50d284&&_0x151787['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x50d284&&_0x151787['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x50d284&&_0x151787['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x50d284&&_0x151787['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x50d284&&_0x151787['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x336705=this['repository']['getRevision'](0x0),_0x2564ae=await this['getRevisionDocumentData'](_0x336705),_0x33f9a0=await this['getRevisionRootsAttributes'](_0x336705);this['_replaceEditorDataWithRevisionData'](_0x2564ae,_0x33f9a0);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x276e8d){this['_source']=_0x276e8d;}async['update'](){const _0x26980c=await this['_source']['getLatestVersion']();if(_0x26980c>this['currentRevision']['toVersion']){await this['_loadState']();const _0x586835=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x26980c});_0x586835['authors']=_0x586835['authorsIds']['map'](_0x206912=>this['editor']['plugins']['get']('Users')['getUser'](_0x206912)),this['currentRevision']['_update'](_0x586835);}}async['_loadState'](){this['_continueCurrentRevision']&&!this['_loadedStateData']&&(await this['_loadRevisionData'](this['currentRevision']),this['_revisionDataBuilder']['loadState'](this['currentRevision']),this['_loadedStateData']={'fromVersion':this['currentRevision']['fromVersion'],'authors':this['currentRevision']['authors']['slice']()});}async['saveRevision'](_0x197a6b={},_0x4335fd=null){const _0x16e7dc=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x4335fd>this['currentRevision']['toVersion']&&(_0x4335fd=null),null===_0x4335fd&&(_0x4335fd=await this['_source']['getLatestVersion']());const _0x3f8c4e=this['_getFromVersion'](_0x4335fd),_0x56b0cc=this['buildRevisionData']({'from':_0x3f8c4e,'to':_0x4335fd});if(this['currentRevision']['toVersion']<_0x4335fd){const _0x35a98a=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x4335fd,'to':_0x4335fd});_0x35a98a['authors']=[],_0x35a98a['authorsIds']=[],_0x35a98a['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x35a98a,!0x0),delete _0x35a98a['authors'],_0x16e7dc['push'](_0x35a98a);}_0x197a6b['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x197a6b['name']=_0x197a6b['name']||null,_0x197a6b['id']=_0x197a6b['id']||_0x358749(),_0x197a6b={..._0x197a6b,..._0x56b0cc};const _0x5f3f82=this['addRevisionData'](_0x197a6b);_0x16e7dc['push'](_0x197a6b);const _0x12da5e=this['repository']['getIndex'](_0x5f3f82);if(0x0!==_0x12da5e){const _0x53d9c6=this['repository']['getRevision'](_0x12da5e-0x1);if(_0x53d9c6['fromVersion']!==_0x4335fd){const _0x37cf45=this['_revisionDataBuilder']['getData'](_0x4335fd,_0x53d9c6['toVersion']),_0x3c1ef7={'id':_0x53d9c6['id'],'diffData':_0x37cf45['diffData'],'authorsIds':_0x37cf45['authorsIds'],'authors':_0x37cf45['authorsIds']['map'](_0x4401eb=>this['editor']['plugins']['get']('Users')['getUser'](_0x4401eb)),'fromVersion':_0x4335fd};_0x53d9c6===this['currentRevision']&&(_0x3c1ef7['createdAt']=new Date(_0x197a6b['createdAt']['getTime']()+0xa)),_0x53d9c6['_update'](_0x3c1ef7,!0x0),delete _0x3c1ef7['authors'],_0x16e7dc['push'](_0x3c1ef7);}}if(this['adapter']){for(const _0x55ee45 of _0x16e7dc)this['_bufferUpdate'](_0x55ee45['id'],_0x55ee45,!0x0);this['sendBufferedUpdates']();}return _0x5f3f82;}['addRevisionData'](_0x2d547d){const _0x5658e9=this['repository']['createRevision'](_0x2d547d);return this['adapter']&&_0x5658e9['on']('_update',(_0xfc598c,_0x1eb4a3,_0x2db94e)=>{_0x2db94e||(this['_bufferUpdate'](_0x1eb4a3['id'],_0x1eb4a3,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x5658e9,this['_findInsertionIndex'](_0x5658e9)),_0x5658e9;}async['getRevisionDocumentData'](_0x3ce1bf){await this['_loadRevisionData'](_0x3ce1bf);const _0x4b1bda={};for(const _0x1f2d06 in _0x3ce1bf['diffData']){if(_0x3ce1bf['diffData'][_0x1f2d06]['attachChange']&&!_0x3ce1bf['diffData'][_0x1f2d06]['attachChange']['isAttached'])continue;const _0x56ce61=this['_removeRevisionMarkers'](JSON['parse'](_0x3ce1bf['diffData'][_0x1f2d06]['insertions'])),_0x3fee00=this['editor']['editing']['view']['document'],_0x5d4d0e=new _0xe0cd86(_0x3fee00,_0x56ce61['map'](_0x17efe8=>C(_0x17efe8,this['editor'])));this['editor']['data']['processor']['useFillerType']('marked'),_0x4b1bda[_0x1f2d06]=this['editor']['data']['processor']['toData'](_0x5d4d0e),this['editor']['data']['processor']['useFillerType']('default');}return _0x4b1bda;}async['getRevisionRootsAttributes'](_0x2f4129){await this['_loadRevisionData'](_0x2f4129);const _0x86b8fd={};for(const _0x45ba8a in _0x2f4129['diffData'])_0x2f4129['diffData'][_0x45ba8a]['attachChange']&&!_0x2f4129['diffData'][_0x45ba8a]['attachChange']['isAttached']||(_0x86b8fd[_0x45ba8a]=_0x2f4129['diffData'][_0x45ba8a]['attributesAfter']||{});return _0x86b8fd;}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x421170=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x334047=0x0;_0x334047<_0x421170['length'];_0x334047++){const _0x712c5d=_0x421170[_0x334047];let _0x3d540a=!0x1;for(const _0x3478fd of Object['keys'](_0x712c5d))void 0x0===_0x712c5d[_0x3478fd]?delete _0x712c5d[_0x3478fd]:'id'!==_0x3478fd&&(_0x3d540a=!0x0);_0x3d540a||(_0x421170[_0x334047]=null);}if(_0x421170=_0x421170['filter'](_0x4c29e0=>null!==_0x4c29e0),!_0x421170['length'])return;for(let _0x334f72=0x0;_0x334f72<_0x421170['length'];_0x334f72++){const _0x54247f=_0x421170[_0x334f72];void 0x0!==_0x54247f['fromVersion']&&void 0x0===_0x54247f['toVersion']&&(_0x54247f['toVersion']=this['repository']['getRevision'](_0x54247f['id'])['toVersion']),void 0x0!==_0x54247f['toVersion']&&void 0x0===_0x54247f['fromVersion']&&(_0x54247f['fromVersion']=this['repository']['getRevision'](_0x54247f['id'])['fromVersion']);}const _0x37df33=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x421170,_0x37df33)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x193bcb=>{if(_0x193bcb){for(const _0x15d5f8 of _0x193bcb)this['setRevisionData']({'id':_0x15d5f8['id'],'createdAt':_0x15d5f8['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['_replaceEditorDataWithRevisionData'](_0x57b5e6,_0x4d5f8d){let _0x339644=this['editor']['config']['get']('initialData'),_0x4fbd49=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x339644){_0x339644={};for(const _0x57fea9 of this['editor']['model']['document']['getRootNames']())_0x339644[_0x57fea9]='';}if('string'==typeof _0x339644&&(_0x339644={'main':_0x339644}),void 0x0===_0x4fbd49){_0x4fbd49={};for(const _0x598194 of this['editor']['model']['document']['getRootNames']())_0x4fbd49[_0x598194]={};}let _0x23cc32=!0x1;const _0x35a309=Object['keys'](_0x339644),_0x3b3bf5=Object['keys'](_0x57b5e6);for(const _0x553b02 of _0x35a309){if(_0x339644[_0x553b02]!==_0x57b5e6[_0x553b02]&&''!==_0x339644[_0x553b02]['trim']()){_0x23cc32=!0x0;break;}if(!_0x31d3ce(_0x4fbd49[_0x553b02],_0x4d5f8d[_0x553b02])&&Object['keys'](_0x4fbd49[_0x553b02])['length']>0x0){_0x23cc32=!0x0;break;}}_0x23cc32||(_0x23cc32=_0x3b3bf5['some'](_0x44cad2=>!this['editor']['model']['document']['getRoot'](_0x44cad2))),_0x23cc32&&_0x13b4f9('editor-initial-data-replaced-with-revision-data',{'editorData':_0x339644,'editorRootsAttributes':_0x4fbd49,'revisionData':_0x57b5e6,'revisionRootsAttributes':_0x4d5f8d}),this['editor']['config']['set']('initialData',_0x57b5e6),this['editor']['config']['set']('rootsAttributes',_0x4d5f8d);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x33b85b=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x33b85b['add'](m(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x371d8c){const _0x2afef7=this['repository']['getRevisions']();_0x2afef7['reverse']();let _0x1510c6=0x0;for(;_0x1510c6<_0x2afef7['length'];){const _0x10b51c=_0x2afef7[_0x1510c6];if(_0x10b51c===this['currentRevision']){_0x1510c6++;continue;}if(_0x10b51c['id']===this['_initialRevisionId'])break;const _0x10a36a=_0x371d8c['toVersion']-_0x10b51c['toVersion']||_0x371d8c['fromVersion']-_0x10b51c['fromVersion'];if(_0x10a36a>0x0)break;if(_0x10a36a<0x0)_0x1510c6++;else{if(!_0x371d8c['creator']&&_0x10b51c['creator'])break;if(_0x10b51c['creator']||!_0x371d8c['creator']){if(_0x371d8c['createdAt']>_0x10b51c['createdAt'])break;_0x1510c6++;}else _0x1510c6++;}}return _0x1510c6;}['setRevisionData'](_0x500044){const _0x2f07ba=this['repository']['getRevision'](_0x500044['id']);if(_0x500044['createdAt']&&(_0x500044['createdAt']=new Date(_0x500044['createdAt'])),_0x500044['authorsIds']){const _0x13a03d=this['editor']['plugins']['get']('Users');_0x500044['authors']=_0x500044['authorsIds']['map'](_0xf4055b=>_0x13a03d['getUser'](_0xf4055b));}_0x2f07ba['_update'](_0x500044,!0x0);}['buildRevisionData']({revision:_0x42f3c9=null,from:_0x2140de=null,to:_0x2b1431=null}){_0x2140de=null!==_0x2140de?_0x2140de:_0x42f3c9['fromVersion'],_0x2b1431=null!==_0x2b1431?_0x2b1431:_0x42f3c9['toVersion'];const _0x4030d3=this['_revisionDataBuilder']['getData'](_0x2140de,_0x2b1431),_0xbe26eb={'diffData':_0x4030d3['diffData'],'authorsIds':_0x4030d3['authorsIds'],'fromVersion':_0x2140de,'toVersion':_0x2b1431};if(!_0x42f3c9||_0x2b1431!==_0x42f3c9['toVersion']){const _0x59ce7f=_0x2b1431-0x1,_0xbf998d=this['_source']['history']['getOperation'](_0x59ce7f);_0xbe26eb['createdAt']=_0xbf998d&&_0xbf998d['createdAt']||new Date();}if(this['_loadedStateData']&&_0x2140de===this['_loadedStateData']['fromVersion']){for(const _0x59929e of this['_loadedStateData']['authors'])_0xbe26eb['authorsIds']['includes'](_0x59929e['id'])||_0xbe26eb['authorsIds']['push'](_0x59929e['id']);}return _0xbe26eb;}['_loadRevisionData'](_0x423322){if(!_0x423322||_0x423322['diffData'])return Promise['resolve']();{const _0x1976be=this['editor']['config']['get']('collaboration.channelId');return this['adapter']['getRevision']({'channelId':_0x1976be,'revisionId':_0x423322['id']})['then'](_0x2acabf=>{_0x423322['diffData']=_0x2acabf['diffData'];});}}['_bufferUpdate'](_0x38d7dd,_0xb163f7,_0xd7fa7c){if(this['_bufferedUpdates']['has'](_0x38d7dd)){const _0xdfb099=this['_bufferedUpdates']['get'](_0x38d7dd);_0xb163f7=_0xd7fa7c?{..._0xdfb099,..._0xb163f7}:{..._0xb163f7,..._0xdfb099};}this['_bufferedUpdates']['set'](_0x38d7dd,_0xb163f7);}['_getFromVersion'](_0x4685c9){const _0x5b4984=this['repository']['getRevisions']();_0x5b4984['reverse'](),_0x5b4984['shift']();const _0x4e1241=_0x5b4984['find'](_0x1f1903=>_0x1f1903['toVersion']<=_0x4685c9)['toVersion'];return _0x4e1241<this['_startingVersion']?this['_startingVersion']:_0x4e1241;}['_createInitialRevision'](_0x1255b4){const _0x27dd8a=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x27dd8a)this['_initialRevisionId']=_0x27dd8a['id'];else{const _0x54fd3f=!this['editor']['model']['document']['roots']['find'](_0x26fc58=>this['editor']['model']['hasContent'](_0x26fc58)),_0x181597=this['editor']['plugins']['get']('Users')['me']['id'],_0x3cdf61=m(this['editor']['locale'],_0x54fd3f?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x1255b4,'to':_0x1255b4,'id':this['_initialRevisionId'],'name':_0x3cdf61,'creatorId':_0x181597});}}['_createCurrentRevision'](_0x18f463){const _0x9d2e07=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x9d2e07),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x18f463,'to':_0x18f463,'id':_0x9d2e07,'name':'','creatorId':null}));}['_makeRevision']({name:_0x4a064c,from:_0x2c00b6,to:_0x28c0c1,creatorId:_0x27ed7b,id:_0x52c57f}){const _0x590c5b=this['buildRevisionData']({'from':_0x2c00b6,'to':_0x28c0c1});_0x590c5b['name']=_0x4a064c,_0x590c5b['creatorId']=_0x27ed7b,_0x590c5b['id']=_0x52c57f;const _0x368a56=this['addRevisionData'](_0x590c5b);return this['adapter']&&this['_bufferUpdate'](_0x590c5b['id'],_0x590c5b,!0x0),_0x368a56;}['_setConversion'](){this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'});}['_removeRevisionMarkers'](_0x331ac1){return(_0x331ac1=_0x331ac1['filter'](_0x2ffe28=>!_0x2ffe28['name']||'revision-start'!==_0x2ffe28['name']&&'revision-end'!==_0x2ffe28['name']))['forEach'](_0x7aa3e3=>{'string'!=typeof _0x7aa3e3&&(_0x7aa3e3['children']=this['_removeRevisionMarkers'](_0x7aa3e3['children']),_0x7aa3e3['attributes']=_0x7aa3e3['attributes']['filter'](_0x1ffae2=>!_0x1ffae2[0x0]['startsWith']('data-revision-')));}),_0x331ac1;}}function C(_0x4100d0,_0xfe8188){const _0x485816=_0xfe8188['editing']['view']['document'];if('string'==typeof _0x4100d0)return new _0x293831(_0x485816,_0x4100d0);{const _0x2b527d=_0x4100d0['children']['map'](_0xc252e3=>C(_0xc252e3,_0xfe8188));return new(P[_0x4100d0['type']]||_0x1faa4b)(_0x485816,_0x4100d0['name'],_0x4100d0['attributes'],_0x2b527d);}}class V{['editor'];['source'];['_savedMetaData'];['_lastFrom'];['_lastTo'];['_markers'];['_diffRoots'];['_diffRootsAttributes'];['_baseRoots'];['_baseRootsAttributes'];['_idsRoots'];['_baseIdsRoots'];['_touched'];['_touchedMarkers'];['_touchedRoots'];['_revisionId'];['_startingRevisionId'];constructor(_0xd9957d){this['editor']=_0xd9957d,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'](_0xb6f5f8){this['source']=_0xb6f5f8;const _0x148104=new Map(),_0x1fcc6b=new Map(),_0x4a877c=this['editor']['model']['document']['roots']['map'](_0x586207=>_0x586207['rootName']);for(const _0xafe297 of _0x4a877c){const _0x4349c2=this['editor']['model']['document']['getRoot'](_0xafe297),_0x308dab=T(_0x4349c2);_0x148104['set'](_0xafe297,_0x308dab),_0x1fcc6b['set'](_0xafe297,Object['fromEntries'](_0x4349c2['getAttributes']()));}const _0x333134=Array['from'](this['editor']['model']['markers'])['map'](_0x1fc47b=>[_0x1fc47b['name'],_0x1fc47b['getRange']()]),_0x2788ff=this['source']['version'];this['_saveMetaData'](_0x2788ff,_0x148104,_0x333134,_0x1fcc6b),this['_startingRevisionId']=this['_revisionId'];const _0x7b4629=new Map(),_0x47fe83=new Map();for(const _0xe27cc2 of _0x4a877c){const _0x310593=F(_0xe27cc2);_0x7b4629['set'](_0xe27cc2,_0x310593),_0x47fe83['set'](_0xe27cc2,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x7b4629,[],_0x47fe83);}['getData'](_0xe576c7,_0x30d45b){if(this['_lastFrom']===_0xe576c7&&this['_lastTo']<=_0x30d45b)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x30d45b,!0x0);else{if(!this['_savedMetaData']['has'](_0xe576c7)){const _0x4af291=this['_getPreviousFrom'](_0xe576c7);this['_calculateMetaData'](_0x4af291,_0xe576c7,!0x1);}this['_calculateMetaData'](_0xe576c7,_0x30d45b,!0x0);}return this['_lastFrom']=_0xe576c7,this['_lastTo']=_0x30d45b,this['_getState']();}['loadState'](_0x5d8267){this['_reset'](),this['_lastFrom']=_0x5d8267['fromVersion'],this['_lastTo']=_0x5d8267['toVersion'];for(const _0x22d0db in _0x5d8267['diffData']){const _0x2fb37f=_0x5d8267['diffData'][_0x22d0db]['attachChange'],_0x1a5ba1=_0x49c00c(_0x5d8267['diffData'][_0x22d0db]['attributesBefore'])||{},_0x9ef78e=this['_makeModelFromViewString'](_0x5d8267['diffData'][_0x22d0db]['deletions']);_0x9ef78e['rootName']=_0x22d0db,_0x9ef78e['_isAttached']=!_0x2fb37f||!_0x2fb37f['isAttached'],_0x9ef78e['isAttached']=()=>_0x9ef78e['_isAttached'],this['_baseRoots']['set'](_0x22d0db,_0x9ef78e),this['_baseRootsAttributes']['set'](_0x22d0db,_0x1a5ba1),_0x2fb37f&&this['_touchedRoots']['set'](_0x22d0db,_0x2fb37f);const _0x4946bb=this['_makeIdsRoot'](_0x9ef78e);this['_baseIdsRoots']['set'](_0x22d0db,_0x4946bb);for(const [_0xe4f72e,_0x54b34c]of _0x9ef78e['markers']){if(!_0xe4f72e['startsWith']('revision:'))continue;const _0x4fcf93=_0xe4f72e['split'](':')[0x2];for(const _0x5691ff of _0x54b34c['getWalker']({'singleCharacters':!0x0})){const _0x5dbb65=this['_getVidAttributeName'](_0x5691ff),_0x3e86a7='elementEnd'==_0x5691ff['type']?_0x5691ff['previousPosition']['path']['slice'](0x0,-0x1):_0x5691ff['previousPosition']['path'],_0x4763b6=_0x4946bb['getNodeByPath'](_0x3e86a7)['getAttribute'](_0x5dbb65);this['_touched']['set'](_0x4763b6,{'userId':_0x4fcf93});}}}this['_startingRevisionId']=this['_revisionId'];const _0x43522b=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x1552a2=>!this['_touched']['has'](_0x1552a2));let _0x336120=0x0;const _0x2836e7=new Map();for(const _0x552572 in _0x5d8267['diffData']){const _0x1caefb=_0x5d8267['diffData'][_0x552572]['attachChange'],_0x17c33f=_0x49c00c(_0x5d8267['diffData'][_0x552572]['attributesAfter'])||{},_0x31e727=this['_makeModelFromViewString'](_0x5d8267['diffData'][_0x552572]['insertions']);_0x31e727['rootName']=_0x552572,_0x31e727['_isAttached']=!_0x1caefb||_0x1caefb['isAttached'],_0x31e727['isAttached']=()=>_0x31e727['_isAttached'],this['_diffRoots']['set'](_0x552572,_0x31e727),this['_diffRootsAttributes']['set'](_0x552572,_0x17c33f);const _0x245010=this['_makeIdsRoot'](_0x31e727,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x552572,_0x245010),_0x2836e7['set'](_0x552572,_0x31e727['isAttached']()?_0x17c33f:{});for(const [_0x1c2d9b,_0x5dd2d0]of _0x31e727['markers']){if(!_0x1c2d9b['startsWith']('revision:'))continue;const _0x9454c=_0x1c2d9b['split'](':')[0x2];for(const _0xf7d61d of _0x5dd2d0['getWalker']({'singleCharacters':!0x0})){const _0x56c344=this['_getVidAttributeName'](_0xf7d61d),_0x12c808=this['_revisionId']++,_0x434227='elementEnd'==_0xf7d61d['type']?_0xf7d61d['previousPosition']['path']['slice'](0x0,-0x1):_0xf7d61d['previousPosition']['path'];_0x245010['getNodeByPath'](_0x434227)['_setAttribute'](_0x56c344,_0x12c808),this['_touched']['set'](_0x12c808,{'userId':_0x9454c});}}for(const _0xd1a5f0 of this['editor']['model']['createRangeIn'](_0x31e727)['getWalker']({'singleCharacters':!0x0})){const _0x57bdc4=this['_getVidAttributeName'](_0xd1a5f0),_0x1b6108='elementEnd'==_0xd1a5f0['type']?_0xd1a5f0['previousPosition']['path']['slice'](0x0,-0x1):_0xd1a5f0['previousPosition']['path'],_0x5e5a9a=_0x245010['getNodeByPath'](_0x1b6108);_0x5e5a9a['getAttribute'](_0x57bdc4)>0x0||_0x5e5a9a['_setAttribute'](_0x57bdc4,_0x43522b[_0x336120++]);}for(const [_0x4c2d84,_0x462538]of _0x31e727['markers'])_0x4c2d84['startsWith']('revision:')||this['_markers']['set'](_0x4c2d84,_0x462538);}const _0x56ecb0=F('$graveyard');this['_baseRoots']['set']('$graveyard',_0x56ecb0),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x56ecb0,0x1));const _0x42e869=F('$graveyard');this['_diffRoots']['set']('$graveyard',_0x42e869),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x42e869,0x1));const _0x3c0013=Array['from'](this['_diffRoots'])['map'](([_0x280af8,_0x2742cd])=>[_0x280af8,T(_0x2742cd)]);this['_saveMetaData'](this['_lastTo'],_0x3c0013,this['_markers'],_0x2836e7);}['_makeModelFromViewString'](_0x3606d0){const _0x5456c5=JSON['parse'](_0x3606d0),_0x3b383=this['editor']['editing']['view']['document'],_0x44e747=new _0xe0cd86(_0x3b383,_0x5456c5['map'](_0x13d52e=>C(_0x13d52e,this['editor'])));return this['editor']['data']['toModel'](_0x44e747);}['_saveMetaData'](_0x138823,_0xf6aa99,_0x3a3aad,_0x44771d){const _0x2a3976=new Map(_0xf6aa99),_0x5c0870=new Map(_0x49c00c(_0x44771d)),_0x58a5f3=new Map();for(const [_0x4c7c0e,_0x2f3727]of _0x3a3aad)_0x58a5f3['set'](_0x4c7c0e,{'start':_0x2f3727['start']['clone'](),'end':_0x2f3727['end']['clone'](),'rootName':_0x2f3727['root']['rootName']});this['_savedMetaData']['set'](_0x138823,{'roots':_0x2a3976,'markers':_0x58a5f3,'rootsAttributes':_0x5c0870});}['_removeMetaData'](_0x5c83d2){this['_savedMetaData']['delete'](_0x5c83d2);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_reset'](){this['_touched']['clear'](),this['_touchedMarkers']['clear'](),this['_touchedRoots']['clear'](),this['_diffRoots']['clear'](),this['_diffRootsAttributes']['clear'](),this['_baseRoots']['clear'](),this['_baseRootsAttributes']['clear'](),this['_idsRoots']['clear'](),this['_baseIdsRoots']['clear'](),this['_markers']['clear'](),this['_revisionId']=0x1,this['_startingRevisionId']=this['_revisionId'];}['_makeIdsRoot'](_0x35e3c7,_0x232f13=null){let _0x65e899=null;_0x35e3c7['is']('documentFragment')||(_0x65e899=new ft(_0x35e3c7['name'],{'vid_start':null===_0x232f13?this['_revisionId']++:_0x232f13++}));const _0x103b39=[];for(const _0xea48bf of _0x35e3c7['getChildren']())if(_0xea48bf['is']('element')){_0x103b39['push'](this['_makeIdsRoot'](_0xea48bf,_0x232f13));const _0x29ed32=_0x103b39[_0x103b39['length']-0x1];null!==_0x232f13&&(_0x232f13=_0x29ed32['is']('element','$text')?_0x29ed32['getAttribute']('vid')+0x1:_0x29ed32['getAttribute']('vid_end')+0x1);}else{for(let _0x7ab58=0x0;_0x7ab58<_0xea48bf['offsetSize'];_0x7ab58++)_0x103b39['push'](new ft('$text',{'vid':null===_0x232f13?this['_revisionId']++:_0x232f13++}));}if(_0x35e3c7['is']('documentFragment')){const _0x151351=F(_0x35e3c7['rootName']);return _0x151351['_insertChild'](0x0,_0x103b39),_0x151351;}return _0x65e899['_setAttribute']('vid_end',null===_0x232f13?this['_revisionId']++:_0x232f13++),_0x65e899['_insertChild'](0x0,_0x103b39),_0x65e899;}['_calculateMetaData'](_0x1edb12,_0x370d8c,_0x389679){this['_reset']();const {roots:_0x10a308,markers:_0x237288,rootsAttributes:_0x5d28da}=this['_savedMetaData']['get'](_0x1edb12);this['_baseRoots']=new Map(_0x10a308),this['_baseRootsAttributes']=new Map(_0x49c00c(_0x5d28da));for(const [_0x3286cd,_0x346f7b]of this['_baseRoots'])if('$graveyard'!==_0x3286cd&&(this['_diffRoots']['set'](_0x3286cd,T(_0x346f7b)),this['_diffRootsAttributes']=new Map(_0x49c00c(_0x5d28da)),_0x389679)){const _0x54380f=this['_revisionId'];this['_idsRoots']['set'](_0x3286cd,this['_makeIdsRoot'](_0x346f7b)),this['_baseIdsRoots']['set'](_0x3286cd,this['_makeIdsRoot'](_0x346f7b,_0x54380f));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',T(this['_baseRoots']['get']('$graveyard'))),_0x389679&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x145698,_0x50567f]of _0x237288){const _0x3a84d2=this['_baseRoots']['get'](_0x50567f['rootName']),_0x363a02=this['_diffRoots']['get'](_0x50567f['rootName']),_0x52cee4=new vt(this['_fixPosition'](_0x50567f['start'],_0x3a84d2),this['_fixPosition'](_0x50567f['end'],_0x3a84d2)),_0x4fdacc=this['_fixRange'](_0x52cee4,_0x363a02);_0x3a84d2['markers']['set'](_0x145698,_0x52cee4),this['_markers']['set'](_0x145698,_0x4fdacc);}this['_applyOperations'](_0x1edb12,_0x370d8c,_0x389679);}['_applyOperations'](_0x3f0824,_0x54ef35,_0x1b9195){for(const _0x5196d4 of this['source']['getOperations'](_0x3f0824,_0x54ef35))this['_handleOperation'](_0x5196d4,_0x1b9195);for(const _0x4fed6b of this['_diffRoots']['values']())_0x4fed6b['markers']['clear']();for(const [_0x32095a,_0x513a41]of this['_markers']){this['_diffRoots']['get'](_0x513a41['root']['rootName'])['markers']['set'](_0x32095a,_0x513a41['clone']());}const _0x2242cb=new Map(),_0x15b7c0=new Map();for(const [_0x19555a,_0x285ec0]of this['_diffRoots'])_0x2242cb['set'](_0x19555a,T(_0x285ec0)),_0x15b7c0['set'](_0x19555a,this['_diffRootsAttributes']['get'](_0x19555a));this['_saveMetaData'](_0x54ef35,_0x2242cb,this['_markers'],_0x15b7c0);}['_getPreviousFrom'](_0x700416){const _0x287274=Array['from'](this['_savedMetaData']['keys']());_0x287274['sort']((_0x406b1f,_0x361d4d)=>_0x406b1f-_0x361d4d),_0x287274['reverse']();for(const _0x38db5b of _0x287274)if(_0x38db5b<_0x700416)return _0x38db5b;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x2e7cd8,_0x44707e){const _0x44c033=Array['from'](_0x44707e['markers'])['map'](([_0x33d8e6,_0x398973])=>[_0x33d8e6,this['_fixRange'](_0x398973,_0x2e7cd8)]);_0x2e7cd8['markers']=new Map(_0x44c033);}['_transformMarkers'](_0x58d2b9){for(const _0x36fd02 of this['_markers']['values']()){const _0x55400d=_0x36fd02['getTransformedByOperation'](_0x58d2b9),_0x51faf6=vt['_createFromRanges'](_0x55400d);_0x36fd02['start']=_0x51faf6['start'],_0x36fd02['end']=_0x51faf6['end'];}}['_handleOperation'](_0x131b21,_0x16b8b7){if('addRoot'!=_0x131b21['type']&&'detachRoot'!=_0x131b21['type']){if('insert'==_0x131b21['type']){const _0xe6625c=_0x131b21['position']['root']['rootName'];this['_diffRoots']['has'](_0xe6625c)||(this['_diffRoots']['set'](_0xe6625c,F(_0xe6625c,!0x0)),this['_diffRootsAttributes']['set'](_0xe6625c,{}),_0x16b8b7&&this['_idsRoots']['set'](_0xe6625c,F(_0xe6625c,!0x0)));}else{if('addRootAttribute'==_0x131b21['type']||'removeRootAttribute'==_0x131b21['type']||'changeRootAttribute'==_0x131b21['type'])return void this['_handleRootAttributeOperation'](_0x131b21);'marker'==_0x131b21['type']&&this['_handleMarkerOperation'](_0x131b21);}if('marker'!==_0x131b21['type']){const _0xedc831=this['_cloneOperation'](_0x131b21,this['_diffRoots']);_0xedc831['_execute'](),this['_transformMarkers'](_0xedc831);}if(_0x16b8b7)switch(_0x131b21['type']){case'insert':this['_handleInsertOperation'](_0x131b21);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x131b21);break;case'merge':this['_handleMergeOperation'](_0x131b21);break;case'split':this['_handleSplitOperation'](_0x131b21);}}else this['_handleRootOperation'](_0x131b21,_0x16b8b7);}['_cloneOperation'](_0x16f6fc,_0x3eccf7){const _0x2ae636=_0x16f6fc['clone']();return _0x2ae636['_authorId']=_0x16f6fc['_authorId'],this['_fixOperation'](_0x2ae636,_0x3eccf7),_0x2ae636;}['_getBaseVids'](_0x54291d){return _0x54291d['map'](_0x4d543f=>{const _0x5d5ab8=this['_getVidAttributeName'](_0x4d543f);return Number(_0x4d543f['item']['getAttribute'](_0x5d5ab8));});}['_generateTape'](_0x382099,_0x592828){if(_0x382099['is']('element','$text'))_0x592828['push']({'item':_0x382099,'type':'text'});else{_0x382099['is']('element')&&_0x592828['push']({'item':_0x382099,'type':'elementStart'});for(const _0x551e31 of _0x382099['getChildren']())this['_generateTape'](_0x551e31,_0x592828);_0x382099['is']('element')&&_0x592828['push']({'item':_0x382099,'type':'elementEnd'});}return _0x592828;}['_getState'](){const _0x2e606a=new Map(this['_touched']),_0x2347bc=new Map(_0x2e606a),_0x47e7d3=new Map(),_0x51febf={'insertions':{},'deletions':{}},_0x34830b={'insertions':{},'deletions':{}},_0x3e7577=new Map(),_0x450f6d=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x450f6d['delete']('$graveyard');for(const _0x198a2c of _0x450f6d){const _0x3ec0bf=this['_diffRoots']['get'](_0x198a2c)||F(_0x198a2c,!0x1),_0x274a2c=this['_baseRoots']['get'](_0x198a2c)||F(_0x198a2c,!0x1);_0x3ec0bf['isAttached']()||_0x274a2c['isAttached']()?(_0x51febf['insertions'][_0x198a2c]=T(_0x3ec0bf),_0x51febf['deletions'][_0x198a2c]=T(_0x274a2c),this['_copyMarkers'](_0x51febf['deletions'][_0x198a2c],_0x274a2c),this['_copyMarkers'](_0x51febf['insertions'][_0x198a2c],_0x3ec0bf),_0x34830b['insertions'][_0x198a2c]=this['_generateTape'](this['_idsRoots']['get'](_0x198a2c),[]),_0x34830b['deletions'][_0x198a2c]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x198a2c)||F(_0x198a2c,!0x1),[])):_0x450f6d['delete'](_0x198a2c);}for(const _0x38ecfb of _0x450f6d){const _0x16c372=_0x34830b['insertions'][_0x38ecfb];for(const _0x462f28 of _0x16c372){const _0x503e7f=this['_getVidAttributeName'](_0x462f28),_0x493dc3=_0x462f28['item']['getAttribute'](_0x503e7f);_0x2347bc['delete'](_0x493dc3),_0x493dc3>=this['_startingRevisionId']&&_0x47e7d3['set'](_0x493dc3,_0x2e606a['get'](_0x493dc3));}}for(const _0x290cb3 of _0x450f6d){const _0x593197=_0x34830b['insertions'][_0x290cb3],_0x38e3aa=this['_getBaseVids'](_0x34830b['deletions'][_0x290cb3]);let _0x2afeef=0x0;for(const _0x5f6182 of _0x593197){const _0x5dd3f3=this['_getVidAttributeName'](_0x5f6182),_0x12103b=_0x5f6182['item']['getAttribute'](_0x5dd3f3);if(!_0x47e7d3['has'](_0x12103b)&&!_0x3e7577['has'](_0x12103b)){if(_0x2347bc['has'](_0x12103b))_0x2afeef++;else{if(_0x12103b!=_0x38e3aa[_0x2afeef]){const _0x7a1f02=_0x2e606a['get'](_0x12103b)||_0x2e606a['get'](_0x38e3aa[_0x2afeef]);for(;_0x12103b!=_0x38e3aa[_0x2afeef];)_0x2347bc['has'](_0x38e3aa[_0x2afeef])||(_0x3e7577['set'](_0x38e3aa[_0x2afeef],_0x7a1f02),_0x2e606a['set'](_0x38e3aa[_0x2afeef],_0x7a1f02)),_0x2afeef++;}_0x2afeef++;}}}}for(const _0x3d8006 of _0x450f6d){const _0x43ca3b=_0x34830b['insertions'][_0x3d8006];for(const _0x2001de of _0x43ca3b){const _0x3162a4=this['_getVidAttributeName'](_0x2001de),_0x4c3ad6=_0x2001de['item']['getAttribute'](_0x3162a4);if(_0x3e7577['has'](_0x4c3ad6)){const _0x3b0ce6=_0x3e7577['get'](_0x4c3ad6);_0x2347bc['has'](_0x4c3ad6)||_0x2347bc['set'](_0x4c3ad6,{..._0x3b0ce6}),_0x47e7d3['set'](_0x4c3ad6,{..._0x3b0ce6});}}}for(const _0x4310bc of _0x2347bc['keys']())_0x4310bc>=this['_startingRevisionId']&&_0x2347bc['delete'](_0x4310bc);const _0x283fc2=new Map();for(const _0x585855 of _0x450f6d){let _0x26aea5=_0x34830b['insertions'][_0x585855];for(const _0x3979e9 of _0x26aea5)if(_0x3979e9['item']['is']('element','tableCell')){const _0x1e70eb=this['_getVidAttributeName'](_0x3979e9),_0x386de8=_0x3979e9['item']['getAttribute'](_0x1e70eb);if(_0x47e7d3['has'](_0x386de8)){const _0x49e273=_0x3979e9['item']['parent']['parent']['getAttribute']('vid_start'),_0x13e189=_0x283fc2['get'](_0x49e273)||new Set();_0x13e189['add'](_0x47e7d3['get'](_0x386de8)['userId']),_0x283fc2['set'](_0x49e273,_0x13e189);}}_0x26aea5=_0x34830b['deletions'][_0x585855];for(const _0xac8d02 of _0x26aea5)if(_0xac8d02['item']['is']('element','tableCell')){const _0x38628d=this['_getVidAttributeName'](_0xac8d02),_0x204606=_0xac8d02['item']['getAttribute'](_0x38628d);if(_0x2347bc['has'](_0x204606)){const _0x12c5bd=_0xac8d02['item']['parent']['parent']['getAttribute']('vid_start'),_0x1901c5=_0x283fc2['get'](_0x12c5bd)||new Set();_0x1901c5['add'](_0x2347bc['get'](_0x204606)['userId']),_0x283fc2['set'](_0x12c5bd,_0x1901c5);}}for(const _0x5de2ac of _0x283fc2['keys']())(_0x47e7d3['has'](_0x5de2ac)||_0x2347bc['has'](_0x5de2ac))&&_0x283fc2['delete'](_0x5de2ac);}for(const _0x4cff28 of _0x450f6d){const _0x4e8d6e=_0x34830b['insertions'][_0x4cff28];let _0x47035b=null,_0x3197df=null;for(const _0x411f38 of _0x4e8d6e){const _0x3c7b03=this['_getVidAttributeName'](_0x411f38),_0x87b92=_0x411f38['item']['getAttribute'](_0x3c7b03),_0x291d67=_0x283fc2['get'](_0x87b92);_0x291d67&&'elementStart'==_0x411f38['type']&&(_0x47035b=Array['from'](_0x291d67)[0x0],_0x3197df=_0x411f38['item']['getAttribute']('vid_end')),_0x47035b&&(_0x2347bc['set'](_0x87b92,{'userId':_0x47035b}),_0x47e7d3['set'](_0x87b92,{'userId':_0x47035b})),_0x87b92==_0x3197df&&(_0x47035b=null,_0x3197df=null);}}const _0x2e33b1={},_0x355271=new Set();for(const _0x9b9b29 of _0x450f6d){const _0x275373=_0x51febf['deletions'][_0x9b9b29],_0x2233fe=_0x51febf['insertions'][_0x9b9b29];for(const {userId:_0x2dceff}of this['_touchedMarkers']['values']())null!==_0x2dceff&&_0x355271['add'](_0x2dceff);for(const {userId:_0x3a10a4}of this['_touchedRoots']['values']())null!==_0x3a10a4&&_0x355271['add'](_0x3a10a4);this['_markChanges'](_0x2233fe,_0x34830b['insertions'][_0x9b9b29],_0x47e7d3,'insertion',_0x355271),this['_markChanges'](_0x275373,_0x34830b['deletions'][_0x9b9b29],_0x2347bc,'deletion',_0x355271),_0x2e33b1[_0x9b9b29]={'insertions':this['_prepareViewToSave'](_0x2233fe),'deletions':this['_prepareViewToSave'](_0x275373),'attachChange':this['_touchedRoots']['get'](_0x9b9b29)||null,'attributesBefore':_0x49c00c(this['_baseRootsAttributes']['get'](_0x9b9b29))||{},'attributesAfter':_0x49c00c(this['_diffRootsAttributes']['get'](_0x9b9b29))};}return{'diffData':_0x2e33b1,'authorsIds':Array['from'](_0x355271)};}['_processRootBeforeSave'](_0x57d30c){for(const [,_0x42c7c7]of _0x57d30c['markers']){const _0x5793dc=_0x42c7c7['start']['getAncestors']()['filter'](_0x32af7f=>'tableCell'==_0x32af7f['name']);for(const _0x1a33d0 of _0x5793dc)0x1==_0x1a33d0['childCount']&&_0x1a33d0['getChild'](0x0)['is']('element','paragraph')&&_0x1a33d0['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x260d1b){this['_processRootBeforeSave'](_0x260d1b);const _0x32ef48=this['editor']['data']['toView'](_0x260d1b,{}),_0x5d4ce0=Array['from'](_0x32ef48['getChildren']())['map'](_0x16e445=>this['_getViewJson'](_0x16e445));return JSON['stringify'](_0x5d4ce0);}['_getViewJson'](_0x460f01){if(_0x460f01['is']('$text'))return _0x460f01['data'];{const _0x133bac=_0x460f01;return{'type':Object['keys'](P)['find'](_0x1691cb=>_0x460f01 instanceof P[_0x1691cb]),'name':_0x133bac['name'],'attributes':Array['from'](_0x133bac['getAttributes']()),'children':Array['from'](_0x133bac['getChildren']())['map'](_0x2ee5d9=>this['_getViewJson'](_0x2ee5d9))};}}['_markChanges'](_0x55745f,_0x503b6d,_0x1960db,_0x2ca6a0,_0x3f4432){let _0x2a8a24=null,_0x3950dd=null,_0x375247=0x0;const _0x26af40=this['editor']['model'];for(let _0xfe9d0d=0x0;_0xfe9d0d<_0x503b6d['length'];_0xfe9d0d++){const _0x39b9bb=this['_getVidAttributeName'](_0x503b6d[_0xfe9d0d]),_0x5a43e2=_0x503b6d[_0xfe9d0d]['item']['getAttribute'](_0x39b9bb),_0x588575=_0x1960db['get'](_0x5a43e2),_0x5ddb41=_0xfe9d0d==_0x503b6d['length']-0x1;(!_0x2a8a24&&_0x588575&&(_0x2a8a24=_0x588575,_0x3950dd=_0x503b6d[_0xfe9d0d]),_0x2a8a24&&(!_0x588575||_0x588575['userId']!=_0x2a8a24['userId']))&&(_0x44e53d(_0x588575,B(_0x3950dd,_0x55745f,_0x26af40),B(_0x503b6d[_0xfe9d0d],_0x55745f,_0x26af40)),_0x2a8a24=_0x588575||null,_0x3950dd=_0x588575?_0x503b6d[_0xfe9d0d]:null),_0x2a8a24&&_0x5ddb41&&_0x44e53d(_0x588575,B(_0x3950dd,_0x55745f,_0x26af40),J(_0x503b6d[_0xfe9d0d],_0x55745f,_0x26af40));}function _0x44e53d(_0x5a1577,_0x3ed57c,_0x4d1f8a){const _0x2c9142=_0x2a8a24['userId'],_0x4ffb78='revision:'+_0x2ca6a0+':'+_0x2c9142+':'+_0x375247++,_0x3036cb=_0x26af40['createRange'](_0x3ed57c,_0x4d1f8a);_0x55745f['markers']['set'](_0x4ffb78,_0x3036cb),null!==_0x2c9142&&_0x3f4432['add'](_0x2c9142);}}['_getVidAttributeName'](_0x21b3e3){switch(_0x21b3e3['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x30dfc5,_0x46ba5a){_0x30dfc5['baseVersion']=null;for(const _0x3f87c7 in _0x30dfc5){const _0x137478=_0x30dfc5[_0x3f87c7];if(_0x137478 instanceof gt){const _0x538877=_0x46ba5a['get'](_0x137478['root']['rootName']);_0x30dfc5[_0x3f87c7]=this['_fixPosition'](_0x137478,_0x538877);}if(_0x137478 instanceof vt){const _0x2d9b16=_0x46ba5a['get'](_0x137478['root']['rootName']);_0x30dfc5[_0x3f87c7]=this['_fixRange'](_0x137478,_0x2d9b16);}'root'===_0x3f87c7&&(_0x30dfc5['root']=_0x46ba5a['get'](_0x30dfc5['root']['rootName']));}}['_fixRange'](_0x44bfff,_0x47c7e2){return this['editor']['model']['createRange'](this['_fixPosition'](_0x44bfff['start'],_0x47c7e2),this['_fixPosition'](_0x44bfff['end'],_0x47c7e2));}['_fixPosition'](_0x5837e5,_0x3a7945){return this['editor']['model']['createPositionFromPath'](_0x3a7945,_0x5837e5['path'],_0x5837e5['stickiness']);}['_handleInsertOperation'](_0xd1a81f){const _0x13e4cf=this['_idsRoots']['get'](_0xd1a81f['position']['root']['rootName']),_0x280980=this['_fixPosition'](_0xd1a81f['position'],_0x13e4cf),_0x43b02b=null===_0xd1a81f['_authorId']?null:_0xd1a81f['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x5c339f=_0x280980['parent'],_0x27e931=this['_revisionId'],_0x3fac47=[];for(const _0x53ec3d of _0xd1a81f['nodes'])if(_0x53ec3d['is']('element'))_0x3fac47['push'](this['_makeIdsRoot'](_0x53ec3d));else{for(let _0x4726a0=0x0;_0x4726a0<_0x53ec3d['offsetSize'];_0x4726a0++)_0x3fac47['push'](new ft('$text',{'vid':this['_revisionId']++}));}const _0x101302=this['_revisionId'];for(let _0x3cb430=_0x27e931;_0x3cb430<_0x101302;_0x3cb430++)this['_touched']['set'](_0x3cb430,{'userId':_0x43b02b});_0x5c339f['_insertChild'](_0x280980['offset'],_0x3fac47);}['_handleMoveOperation'](_0x4db02e){(_0x4db02e=this['_cloneOperation'](_0x4db02e,this['_idsRoots']))['_execute']();const _0x15c41=null===_0x4db02e['_authorId']?null:_0x4db02e['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x118080=_0x4db02e['getMovedRangeStart'](),_0x426d87=_0x118080['parent'],_0x2b94df=_0x118080['offset'];!function _0x1057e4(_0x4eec27,_0x71f8ec,_0x4421e2,_0x2b1c2c){for(let _0x377a87=_0x4421e2;_0x377a87<_0x2b1c2c;_0x377a87++){const _0x3c4616=_0x71f8ec['getChild'](_0x377a87);_0x3c4616['is']('element','$text')?_0x4eec27['set'](_0x3c4616['getAttribute']('vid'),{'userId':_0x15c41}):(_0x4eec27['set'](_0x3c4616['getAttribute']('vid_start'),{'userId':_0x15c41}),_0x1057e4(_0x4eec27,_0x3c4616,0x0,_0x3c4616['childCount']),_0x4eec27['set'](_0x3c4616['getAttribute']('vid_end'),{'userId':_0x15c41}));}}(this['_touched'],_0x426d87,_0x2b94df,_0x2b94df+_0x4db02e['howMany']);}['_handleMergeOperation'](_0x3335b5){const _0x4e3613=null===(_0x3335b5=this['_cloneOperation'](_0x3335b5,this['_idsRoots']))['_authorId']?null:_0x3335b5['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x3d89a8=_0x3335b5['targetPosition']['parent'],_0x3fb572=_0x3335b5['sourcePosition']['parent'],_0x1e9d78=_0x3d89a8['getAttribute']('vid_end'),_0x1a4b02=_0x3fb572['getAttribute']('vid_start');_0x3d89a8['_setAttribute']('vid_end',_0x3fb572['getAttribute']('vid_end')),_0x3fb572['_setAttribute']('vid_end',_0x1e9d78),this['_touched']['set'](_0x1a4b02,{'userId':_0x4e3613}),this['_touched']['set'](_0x1e9d78,{'userId':_0x4e3613}),_0x3335b5['_execute']();}['_handleSplitOperation'](_0x5397e2){const _0x2d9df7=null===(_0x5397e2=this['_cloneOperation'](_0x5397e2,this['_idsRoots']))['_authorId']?null:_0x5397e2['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x2b674a=_0x5397e2['graveyardPosition'],_0x1793bf=_0x5397e2['splitPosition']['parent'];_0x5397e2['_execute']();const _0x3fb8d5=_0x1793bf['getAttribute']('vid_end'),_0x30bbe7=_0x5397e2['insertionPosition']['nodeAfter'];if(_0x2b674a){const _0x3f419b=_0x30bbe7['getAttribute']('vid_end'),_0x384bee=_0x1793bf['getAttribute']('vid_end');_0x1793bf['_setAttribute']('vid_end',_0x3f419b),_0x30bbe7['_setAttribute']('vid_end',_0x384bee),this['_touched']['set'](_0x1793bf['getAttribute']('vid_end'),{'userId':_0x2d9df7}),this['_touched']['set'](_0x30bbe7['getAttribute']('vid_start'),{'userId':_0x2d9df7});}else{const _0xcdac79=this['_revisionId']++,_0x5a7bc2=this['_revisionId']++;_0x1793bf['_setAttribute']('vid_end',_0xcdac79),_0x30bbe7['_setAttribute']('vid_start',_0x5a7bc2),_0x30bbe7['_setAttribute']('vid_end',_0x3fb8d5),this['_touched']['set'](_0xcdac79,{'userId':_0x2d9df7}),this['_touched']['set'](_0x5a7bc2,{'userId':_0x2d9df7});}}['_handleMarkerOperation'](_0x364b2f){if(!_0x364b2f['affectsData'])return;const _0x3e58c3=(_0x364b2f=this['_cloneOperation'](_0x364b2f,this['_diffRoots']))['oldRange']?_0x364b2f['oldRange']['root']:null,_0x24b221=_0x364b2f['newRange']?_0x364b2f['newRange']['root']:null;_0x3e58c3&&this['_markers']['delete'](_0x364b2f['name']),_0x24b221&&this['_markers']['set'](_0x364b2f['name'],_0x364b2f['newRange']['clone']());const _0x3b46ea=null===_0x364b2f['_authorId']?null:_0x364b2f['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x191be4=_0x364b2f['name'];if(!this['_touchedMarkers']['has'](_0x191be4))return void this['_touchedMarkers']['set'](_0x191be4,{'range':_0x364b2f['oldRange'],'userId':_0x3b46ea});const _0x4d55fd=this['_touchedMarkers']['get'](_0x191be4),_0x5e41a7=_0x4d55fd['range'],_0x4f0cbd=_0x364b2f['newRange'];null==_0x5e41a7&&null==_0x4f0cbd||_0x5e41a7&&_0x4f0cbd&&_0x5e41a7['isEqual'](_0x4f0cbd)?this['_touchedMarkers']['delete'](_0x364b2f['name']):_0x4d55fd['userId']=_0x3b46ea;}['_handleRootOperation'](_0x36b2ca,_0x344da2){this['_diffRoots']['has'](_0x36b2ca['rootName'])?this['_diffRoots']['get'](_0x36b2ca['rootName'])['_isAttached']=_0x36b2ca['isAdd']:(this['_diffRoots']['set'](_0x36b2ca['rootName'],F(_0x36b2ca['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x36b2ca['rootName'],{}),_0x344da2&&this['_idsRoots']['set'](_0x36b2ca['rootName'],F(_0x36b2ca['rootName'],!0x0)));const _0x408cfd=null===_0x36b2ca['_authorId']?null:_0x36b2ca['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x3b14b4=this['_touchedRoots']['get'](_0x36b2ca['rootName']);_0x3b14b4&&_0x3b14b4['userId']===_0x408cfd?this['_touchedRoots']['delete'](_0x36b2ca['rootName']):this['_touchedRoots']['set'](_0x36b2ca['rootName'],{'userId':_0x408cfd,'isAttached':_0x36b2ca['isAdd']});}['_handleRootAttributeOperation'](_0x2d4490){const _0x5647ea=this['_diffRootsAttributes']['get'](_0x2d4490['root']['rootName']);null===_0x2d4490['newValue']?delete _0x5647ea[_0x2d4490['key']]:_0x5647ea[_0x2d4490['key']]=_0x2d4490['newValue'];}}function T(_0x44e413){const _0x27c7c3=F(_0x44e413['rootName'],_0x44e413['isAttached']());for(const _0x3b8e81 of _0x44e413['getChildren']()){const _0x26e11b=_0x3b8e81['_clone'](!0x0);_0x27c7c3['_appendChild'](_0x26e11b);}return _0x27c7c3;}function F(_0x4ab756,_0x50c57b=!0x0){const _0x2767dc=new mt();return _0x2767dc['rootName']=_0x4ab756,_0x2767dc['_isAttached']=_0x50c57b,_0x2767dc['isAttached']=()=>_0x2767dc['_isAttached'],_0x2767dc;}function B(_0x22acfc,_0x7c5176,_0x31d993){const _0x5a9526='elementEnd'==_0x22acfc['type']?_0x31d993['createPositionAt'](_0x22acfc['item'],'end'):_0x31d993['createPositionBefore'](_0x22acfc['item']);return _0x31d993['createPositionFromPath'](_0x7c5176,_0x5a9526['path'],_0x5a9526['stickiness']);}function J(_0x2c68c9,_0x4ef0fa,_0x181ba7){const _0x52fd62='elementStart'==_0x2c68c9['type']?_0x181ba7['createPositionAt'](_0x2c68c9['item'],0x0):_0x181ba7['createPositionAfter'](_0x2c68c9['item']);return _0x181ba7['createPositionFromPath'](_0x4ef0fa,_0x52fd62['path'],_0x52fd62['stickiness']);}class ns extends _0x3f0f05{['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x2a9518,_0x58a1e9){super(_0x2a9518),this['focusTracker']=new _0x14a05e(),this['keystrokes']=new _0x593668(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x58a1e9),this['setTemplate']({'tag':'form','attributes':{'class':['ck','ck-revision-history-save-revision-form','ck-responsive-form'],'tabindex':'-1'},'children':[this['revisionNameInputView']]}),ts(this);}['render'](){super['render'](),_0x6652f9({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x3f6750=_0x19ddc2=>_0x19ddc2['stopPropagation']();this['keystrokes']['set']('arrowright',_0x3f6750),this['keystrokes']['set']('arrowleft',_0x3f6750),this['keystrokes']['set']('arrowup',_0x3f6750),this['keystrokes']['set']('arrowdown',_0x3f6750);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x247974){this['revisionNameInputView']['fieldView']['element']['value']=_0x247974['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x4f65de){const _0x1ff2eb=new nt(this['locale'],_0x1d572c),_0x45cb5b=_0x1ff2eb['fieldView'];_0x45cb5b['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x3ed297=m(this['locale'],'Name\x20of\x20the\x20revision');return!_0x4f65de&&(_0x3ed297+='\x20('+m(this['locale'],'optional')+')'),(_0x1ff2eb['label']=_0x3ed297,_0x45cb5b['on']('input',()=>{this['revisionNameInputValue']=_0x45cb5b['element']['value']['trim']();}),_0x1ff2eb);}}class u extends _0x38c4e4{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l];}['_saveRevisionFormView'];['init'](){const _0x25369f=this['editor'],_0x595b11=_0x25369f['plugins']['get']('RevisionTracker');_0x25369f['ui']['componentFactory']['add']('revisionHistory',_0x3f1969=>{const _0x37b6e8=_0x2a9d1c(_0x3f1969),_0x3971d0=_0x37b6e8['panelView']['children'],_0x3538d0=new te(_0x3f1969),_0x227dd1=new _0x451921(_0x3f1969),_0x2381fe=new _0x13b3b7(_0x3f1969),_0x403330=new _0x451921(_0x3f1969),_0x1c641e=new _0x13b3b7(_0x3f1969);return _0x37b6e8['bind']('isEnabled')['to'](_0x595b11,'isReady',_0x595b11,'isEnabled',_0x25369f,'isReadOnly',(_0x5a87ea,_0x12f695,_0x10713d)=>_0x5a87ea&&_0x12f695&&!_0x10713d),_0x37b6e8['buttonView']['set']({'icon':_0x226c5d['history'],'label':m(_0x3f1969,'Revision\x20history'),'tooltip':!0x0}),_0x2381fe['set']({'label':m(_0x3f1969,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x2381fe['bind']('isEnabled')['to'](_0x595b11,'isReady',_0x595b11,'isEnabled',_0x25369f,'isReadOnly',(_0x45d437,_0x5b8db4,_0x5dc08e)=>_0x45d437&&_0x5b8db4&&!_0x5dc08e),_0x2381fe['on']('execute',()=>this['_showDialog']()),_0x1c641e['set']({'label':m(_0x3f1969,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x1c641e['bind']('isEnabled')['to'](_0x595b11,'isReady',_0x25369f,'isReadOnly',(_0x4be990,_0x3f2b69)=>_0x4be990&&!_0x3f2b69),_0x1c641e['on']('execute',()=>{_0x25369f['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x37b6e8['isOpen']=!0x1,_0x25369f['editing']['view']['focus']();}),_0x227dd1['children']['add'](_0x2381fe),_0x403330['children']['add'](_0x1c641e),_0x3538d0['role']='menu',_0x3538d0['items']['addMany']([_0x227dd1,_0x403330]),_0x3971d0['add'](_0x3538d0),_0x37b6e8;}),_0x25369f['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x12725c=this['editor'],_0x275877=_0x12725c['locale'],_0x183e64=new _0x1b77ca(_0x275877),_0x22c74e=new _0x3b79b8(_0x275877);_0x183e64['buttonView']['set']({'icon':_0x226c5d['history'],'label':m(_0x275877,'Revision\x20history')});const _0x41eb73=new _0x50d7f2(_0x275877,_0x183e64),_0x4cfe22=new _0x37066d(_0x275877);_0x4cfe22['set']({'label':m(_0x275877,'Save\x20current\x20revision')}),_0x4cfe22['delegate']('execute')['to'](_0x183e64),_0x4cfe22['on']('execute',()=>{this['_showDialog']();}),_0x41eb73['children']['add'](_0x4cfe22),_0x22c74e['items']['add'](_0x41eb73);const _0x32b75f=new _0x50d7f2(_0x275877,_0x183e64),_0x3a8072=new _0x37066d(_0x275877);return _0x3a8072['set']({'label':m(_0x275877,'Open\x20revision\x20history')}),_0x3a8072['delegate']('execute')['to'](_0x183e64),_0x3a8072['on']('execute',()=>{_0x12725c['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x32b75f['children']['add'](_0x3a8072),_0x22c74e['items']['add'](_0x32b75f),_0x183e64['panelView']['children']['add'](_0x22c74e),_0x183e64;}['_showDialog'](){const _0x4be217=this['editor'],_0x22e1d0=_0x4be217['locale'],_0x5b993f=_0x4be217['plugins']['get']('Dialog'),_0x4c6fad=_0x4be217['plugins']['get']('RevisionTracker');function _0x9d5cc2(_0x358e85){_0x4be217['config']['get']('revisionHistory.requireRevisionName')&&''===_0x358e85['revisionName']?_0x358e85['revisionNameInputView']['errorText']=m(_0x22e1d0,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x4be217['plugins']['get'](l)['saveRevision']({'name':_0x358e85['revisionName']}),_0x5b993f['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x9d5cc2(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x5b993f['show']({'id':'revisionSave','title':m(_0x22e1d0,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':m(_0x4be217['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x5b993f['hide']()},{'label':m(_0x4be217['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x1291c0){_0x1291c0['bind']('isEnabled')['to'](_0x4c6fad,'isReady',_0x4c6fad,'isEnabled',_0x4be217,'isReadOnly',(_0x5ea6fc,_0x7baaa7,_0x341957)=>_0x5ea6fc&&_0x7baaa7&&!_0x341957);},'onExecute':()=>_0x9d5cc2(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x2126d2=this['editor'],_0x2ca0da=_0x2126d2['locale'];this['_saveRevisionFormView']=new ns(_0x2ca0da,_0x2126d2['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class X extends _0x3f0f05{['changeId'];['_model'];constructor(_0xe7867,_0x534d07){super(_0xe7867),this['_model']=_0x534d07,this['changeId']=_0x534d07['id'];const _0x4295b1=this['bindTemplate'],_0x36e3c3=m(_0xe7867,_0x534d07['data']['isSuggestion']?'Suggested\x20by':'add'==_0x534d07['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x534d07['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x4295b1['to']('type',_0x3251ed=>'ck-revision-change__'+_0x3251ed)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x36e3c3}]},{'text':'\x20'+_0x534d07['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class r extends/* #__PURE__ -- @preserve */
|
|
25
|
+
_0x2d9680(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x3698ed){super(),this['id']=_0x3698ed['id']||_0x358749(),this['author']=_0x3698ed['author'],this['type']=_0x3698ed['type'],this['data']=_0x3698ed['data']||{},this['rootName']=_0x3698ed['rootName'],this['set']('createdAt',_0x3698ed['createdAt']);}['toJSON'](){return{'id':this['id'],'authorId':this['author']['id'],'type':this['type'],'data':this['data'],'createdAt':this['createdAt']};}}class f{['newRevisionId'];['oldRevisionId'];['changes'];constructor(_0x2f31a8,_0x482247){this['newRevisionId']=_0x2f31a8,this['oldRevisionId']=_0x482247,this['changes']=new _0x42ce0a();}['_setChanges'](_0x18c523){for(const _0x36c33e of _0x18c523)this['changes']['add'](_0x36c33e);}}const Y={'c':_0x73e509,'a':_0x2053cd,'e':_0x48c1f7,'r':_0x11a6f7,'u':_0x2dca08};class d extends _0x38c4e4{['repository'];['adapter'];['_activeViewTarget'];['_changeView'];['_changeIdToChange'];['_balloon'];static get['pluginName'](){return'RevisionViewer';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[_0x25c78c,_0x377694,j];}constructor(_0x11bd9d){super(_0x11bd9d),this['repository']=this['editor']['plugins']['get']('RevisionsRepository'),this['set']('activeChange',null),this['set']('activeView',null),this['_activeViewTarget']=null,this['set']('diff',null),this['set']('isReady',!0x1),this['set']('isEnabled',!0x0),this['on']('change:isEnabled',(_0x343923,_0x12e025,_0xbd5a1b)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x80a50d=>{for(const _0x2917e3 of this['editor']['editing']['view']['document']['roots'])_0xbd5a1b?_0x80a50d['removeClass']('ck-editor__editable__overlay',_0x2917e3):_0x80a50d['addClass']('ck-editor__editable__overlay',_0x2917e3);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x4ca113=>null!==_0x4ca113),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x45725c,_0x170024,_0x5d66df)=>_0x45725c&&_0x5d66df?_0x170024['changes']['getIndex'](_0x5d66df):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x44fe98,_0x2c23ae)=>_0x44fe98?_0x2c23ae['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['adapter']=null,this['_balloon']=this['editor']['plugins']['get'](_0x377694);}['init'](){const _0x34d14b=this['editor'],_0x2b0410=new yt(_0x34d14b,{'direction':'backward'}),_0x5b21e0=new yt(_0x34d14b,{'direction':'forward'});(_0x34d14b['commands']['add']('showPreviousChange',_0x2b0410),_0x34d14b['commands']['add']('showNextChange',_0x5b21e0),_0x34d14b['commands']['add']('restoreRevision',new _t(_0x34d14b)),this['on']('change:numberOfChanges',()=>{_0x2b0410['refresh'](),_0x5b21e0['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x34d14b['enableReadOnlyMode']('revision-viewer'),_0x34d14b['plugins']['has']('WidgetToolbarRepository'))&&_0x34d14b['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionData'](_0x4a6b51){await this['loadRevisionData'](_0x4a6b51);const _0x521c0e={};for(const _0x4bc531 in _0x4a6b51['diffData']){if(_0x4a6b51['diffData'][_0x4bc531]['attachChange']&&!_0x4a6b51['diffData'][_0x4bc531]['attachChange']['isAttached'])continue;const _0x37fc18=this['_removeRevisionMarkers'](JSON['parse'](_0x4a6b51['diffData'][_0x4bc531]['insertions'])),_0x133531=this['editor']['editing']['view']['document'],_0x5b8696=new _0xe0cd86(_0x133531,_0x37fc18['map'](_0x1f86af=>this['_getViewObj'](_0x1f86af)));this['editor']['data']['processor']['useFillerType']('marked'),_0x521c0e[_0x4bc531]=this['editor']['data']['processor']['toData'](_0x5b8696),this['editor']['data']['processor']['useFillerType']('default');}return _0x521c0e;}async['getRevisionRootsAttributes'](_0x2236eb){await this['loadRevisionData'](_0x2236eb);const _0x3127e8={};for(const _0x1c5a7c in _0x2236eb['diffData'])_0x2236eb['diffData'][_0x1c5a7c]['attachChange']&&!_0x2236eb['diffData'][_0x1c5a7c]['attachChange']['isAttached']||(_0x3127e8[_0x1c5a7c]=_0x2236eb['diffData'][_0x1c5a7c]['attributesAfter']||{});return _0x3127e8;}['_removeRevisionMarkers'](_0x54f523){return(_0x54f523=_0x54f523['filter'](_0x57e4b5=>!_0x57e4b5['name']||'revision-start'!==_0x57e4b5['name']&&'revision-end'!==_0x57e4b5['name']))['forEach'](_0x4f2162=>{'string'!=typeof _0x4f2162&&(_0x4f2162['children']=this['_removeRevisionMarkers'](_0x4f2162['children']),_0x4f2162['attributes']=_0x4f2162['attributes']['filter'](_0x2889ee=>!_0x2889ee[0x0]['startsWith']('data-revision-')));}),_0x54f523;}async['compare'](_0x1a2f8f,_0x25c03a,_0x26738f=!0x1){if(!this['isEnabled'])return;const _0x44c958=this['diff'],_0x5e6d99=this['repository'],_0x374240='string'==typeof _0x1a2f8f?_0x5e6d99['getRevision'](_0x1a2f8f):_0x1a2f8f,_0x14a162='string'==typeof _0x25c03a?_0x5e6d99['getRevision'](_0x25c03a):_0x25c03a,_0x10e2d6=_0x374240['id'],_0x4a3e5f=_0x14a162?_0x14a162['id']:null;if(!_0x26738f&&this['diff']&&this['diff']['newRevisionId']===_0x10e2d6&&this['diff']['oldRevisionId']===_0x4a3e5f)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new f(_0x10e2d6,_0x4a3e5f);const _0x4aeb8b=this['_getRevisionsRange'](_0x374240,_0x14a162,!0x0)['map'](_0x2fc848=>this['loadRevisionData'](_0x2fc848));return _0x4aeb8b['push'](new Promise(_0x155315=>{setTimeout(_0x155315,0x14);})),Promise['all'](_0x4aeb8b)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0xac6078=this['_getDiff'](_0x10e2d6,_0x4a3e5f);for(const _0x3bffe1 of _0xac6078['changes'])this['_changeIdToChange']['set'](_0x3bffe1['id'],_0x3bffe1);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0xb9d785=>{for(const _0x539433 of this['editor']['model']['document']['getRootNames']())_0xb9d785['detachRoot'](_0x539433);for(const _0x443b0d of Object['keys'](_0xac6078['model'])){const _0x4d8101=_0xb9d785['addRoot'](_0x443b0d);for(const _0x3a8938 of Object['keys'](_0xac6078['attributes'][_0x443b0d]))_0xb9d785['setAttribute'](_0x3a8938,_0xac6078['attributes'][_0x443b0d][_0x3a8938],_0x4d8101);_0xb9d785['insert'](_0xac6078['model'][_0x443b0d],_0x4d8101,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0xac6078['changes'])),this['isReady']=!0x0;})['catch'](_0x298789=>{console['error'](_0x298789),this['_cleanUp'](),_0x44c958&&(this['diff']=_0x44c958),this['isReady']=!0x0;});}['addRevisionData'](_0x6f788e,_0x219a81){const _0x49024d=this['repository']['createRevision'](_0x6f788e);return _0x49024d['on']('_update',(_0x1f8738,_0x54652c,_0x1e6a82)=>_0x219a81(_0x54652c,_0x1e6a82,_0x49024d)),this['repository']['addRevision'](_0x49024d),_0x49024d;}['loadRevisionData'](_0x4b1d47){if(!_0x4b1d47||_0x4b1d47['diffData'])return Promise['resolve']();{const _0x348c9a=this['editor']['config']['get']('collaboration.channelId');return this['adapter']['getRevision']({'channelId':_0x348c9a,'revisionId':_0x4b1d47['id']})['then'](_0x4a33b2=>{_0x4b1d47['_update']({'diffData':_0x4a33b2['diffData']},!0x0);});}}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x4b0622=>{for(const _0x49ef69 of this['editor']['model']['document']['getRootNames']())_0x4b0622['detachRoot'](_0x49ef69);});}['_sortAndFilterDiffChanges'](_0x432fda){const _0x1bd203=[],_0x33bc5b=new Map();for(const _0x4c7913 of this['editor']['model']['document']['getRootNames']()){const _0x247923=this['editor']['editing']['view']['getDomRoot'](_0x4c7913);if(!_0x247923)continue;const _0x206109=_0x247923['getClientRects']()['item'](0x0);_0x206109&&(_0x1bd203['push'](_0x4c7913),_0x33bc5b['set'](_0x4c7913,_0x206109));}return _0x1bd203['sort']((_0x5377b8,_0x380b07)=>{const _0x359a1c=_0x33bc5b['get'](_0x5377b8),_0x3280fd=_0x33bc5b['get'](_0x380b07);return _0x359a1c['y']-_0x3280fd['y']||_0x359a1c['x']-_0x3280fd['x'];}),(_0x432fda=_0x432fda['filter'](_0x20af5c=>_0x1bd203['includes'](_0x20af5c['rootName'])))['sort']((_0x44fc28,_0x464efc)=>_0x1bd203['indexOf'](_0x44fc28['rootName'])-_0x1bd203['indexOf'](_0x464efc['rootName'])),_0x432fda;}['_makeTape'](_0xda741d){const _0x3fff92=Array['from'](_0xda741d['markers'])['filter'](([_0x13586b,_0x5b0245])=>_0x13586b['startsWith']('revision:')&&!_0x5b0245['isCollapsed']),_0x3a7ec3=Array['from'](this['editor']['model']['createRangeIn'](_0xda741d)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x3fff92['length'])for(const _0x46487e of _0x3a7ec3){const [_0x2a9c53,_0x2421ec]=_0x3fff92[0x0],[,_0x4af7b2,_0x3adc13]=_0x2a9c53['split'](':');if(_0x2421ec['end']['isEqual'](_0x46487e['nextPosition'])&&_0x3fff92['shift'](),(_0x46487e['previousPosition']['isEqual'](_0x2421ec['start'])||_0x46487e['previousPosition']['isAfter'](_0x2421ec['start']))&&('insertion'==_0x4af7b2?_0x46487e['isAdded']={'userId':_0x3adc13}:'deletion'==_0x4af7b2&&(_0x46487e['isRemoved']={'userId':_0x3adc13})),0x0==_0x3fff92['length'])break;}return _0x3a7ec3;}['_refreshStartEndIndex'](_0x5400a5){const _0x8be168=new Map();for(let _0x615757=0x0;_0x615757<_0x5400a5['length'];_0x615757++)'text'===_0x5400a5[_0x615757]['type']?(_0x5400a5[_0x615757]['item']['startIndex']=_0x615757,_0x5400a5[_0x615757]['item']['endIndex']=_0x615757):('elementStart'===_0x5400a5[_0x615757]['type']?_0x5400a5[_0x615757]['item']['startIndex']=_0x615757:'elementEnd'===_0x5400a5[_0x615757]['type']&&(_0x5400a5[_0x615757]['item']['endIndex']=_0x615757),_0x8be168['set'](_0x5400a5[_0x615757]['id'],_0x615757));for(const _0x476aca of _0x8be168['values']())'elementStart'===_0x5400a5[_0x476aca]['type']?_0x5400a5[_0x476aca]['item']['endIndex']=_0x8be168['get'](_0x5400a5[_0x476aca]['pairId']):'elementEnd'===_0x5400a5[_0x476aca]['type']&&(_0x5400a5[_0x476aca]['item']['startIndex']=_0x8be168['get'](_0x5400a5[_0x476aca]['pairId']));}['_processTape'](_0x55529d){for(let _0x262a1b=0x0;_0x262a1b<_0x55529d['length'];_0x262a1b++){if('elementStart'===_0x55529d[_0x262a1b]['type'])_0x55529d[_0x262a1b]['item']['startIndex']=_0x262a1b;else{if('elementEnd'===_0x55529d[_0x262a1b]['type']){_0x55529d[_0x262a1b]['item']['endIndex']=_0x262a1b;const _0x493056=_0x55529d[_0x262a1b]['item']['startIndex'];_0x55529d[_0x493056]['pairId']=_0x55529d[_0x262a1b]['id'],_0x55529d[_0x262a1b]['pairId']=_0x55529d[_0x493056]['id'];}else _0x55529d[_0x262a1b]['item']['startIndex']=_0x262a1b,_0x55529d[_0x262a1b]['item']['endIndex']=_0x262a1b,_0x55529d[_0x262a1b]['pairId']=null;}_0x55529d[_0x262a1b]['markersStart']||(_0x55529d[_0x262a1b]['markersStart']=[],_0x55529d[_0x262a1b]['markersEnd']=[]);}}['_markInsertions'](_0x3adbf5,_0x49810f){const _0xe46394=_0x3adbf5['filter'](_0x622f90=>!_0x622f90['isAdded']);for(let _0x57a6f5=0x0;_0x57a6f5<_0x49810f['length'];_0x57a6f5++)_0x49810f[_0x57a6f5]['isAdded']&&(_0xe46394[_0x57a6f5]['isAdded']=_0x49810f[_0x57a6f5]['isAdded']);}['_makeModelFromViewString'](_0xea873d){const _0x8771d3=JSON['parse'](_0xea873d),_0x43c04a=this['editor']['editing']['view']['document'],_0xd931bd=new _0xe0cd86(_0x43c04a,_0x8771d3['map'](_0x4d994=>this['_getViewObj'](_0x4d994)));return this['editor']['data']['toModel'](_0xd931bd);}['_getViewObj'](_0x7797c5){const _0x1ac49b=this['editor']['editing']['view']['document'];if('string'==typeof _0x7797c5)return new _0x293831(_0x1ac49b,_0x7797c5);{const _0x539382=_0x7797c5['children']['map'](_0x302937=>this['_getViewObj'](_0x302937));return new(Y[_0x7797c5['type']]||_0x1faa4b)(_0x1ac49b,_0x7797c5['name'],_0x7797c5['attributes'],_0x539382);}}['_getDiff'](_0x452120,_0x25c090=null){const _0x358754=this['repository']['getRevision'](_0x452120),_0x4f4035=_0x25c090?this['repository']['getRevision'](_0x25c090):null,_0x7f7188=this['_getRevisionsRange'](_0x358754,_0x4f4035),_0x3207d3=_0x7f7188[_0x7f7188['length']-0x1],_0x4f91e3=new Map(),_0x320009={'model':{},'attributes':{},'changes':[]},_0x39a81d=new Set(),_0x4c6fcd=new Map();for(let _0x13b844=_0x7f7188['length']-0x1;_0x13b844>=0x0;_0x13b844--){const _0x5c10ed=_0x7f7188[_0x13b844];for(const _0x168d86 of Object['keys'](_0x5c10ed['diffData']))if(_0x5c10ed['diffData'][_0x168d86]['attachChange']){const _0x5c8ac3=_0x5c10ed['diffData'][_0x168d86]['attachChange'];_0x5c8ac3['isAttached']?(_0x39a81d['add'](_0x168d86),_0x4c6fcd['has'](_0x168d86)&&_0x4c6fcd['get'](_0x168d86)['userId']==_0x5c8ac3['userId']?_0x4c6fcd['delete'](_0x168d86):_0x4c6fcd['set'](_0x168d86,_0x5c8ac3)):_0x4c6fcd['has'](_0x168d86)?(_0x39a81d['delete'](_0x168d86),_0x4c6fcd['delete'](_0x168d86)):(_0x39a81d['add'](_0x168d86),_0x4c6fcd['set'](_0x168d86,_0x5c8ac3));}else _0x39a81d['add'](_0x168d86);}for(const _0x39ccfd of _0x39a81d){const _0x29854d=_0x4c6fcd['has'](_0x39ccfd)&&!_0x4c6fcd['get'](_0x39ccfd)['isAttached'];let _0x415752=_0x29854d?_0x7f7188['length']-0x1:0x0;const _0xa77c7b=_0x29854d?-0x1:0x1;for(;_0x7f7188[_0x415752];){const _0xaf9c14=_0x7f7188[_0x415752];if(_0xaf9c14['diffData'][_0x39ccfd]){const _0x26ae51=_0x29854d?_0xaf9c14['diffData'][_0x39ccfd]['attributesBefore']:_0xaf9c14['diffData'][_0x39ccfd]['attributesAfter'];_0x320009['attributes'][_0x39ccfd]=_0x26ae51?_0x49c00c(_0x26ae51):{};break;}_0x415752+=_0xa77c7b;}}for(const _0x430172 of _0x7f7188){_0x430172['model']={};for(const _0x53d2c8 of _0x430172['authors'])_0x4f91e3['set'](_0x53d2c8['id'],_0x53d2c8);for(const _0x2385f9 of _0x39a81d){const _0x337b81=_0x430172['diffData'][_0x2385f9]?_0x430172['diffData'][_0x2385f9]['insertions']:'[]',_0x2a91b6=_0x430172['diffData'][_0x2385f9]?_0x430172['diffData'][_0x2385f9]['deletions']:'[]';_0x430172['model'][_0x2385f9]={'insertions':this['_makeModelFromViewString'](_0x337b81),'deletions':this['_makeModelFromViewString'](_0x2a91b6)};}}for(const _0x3896dc of _0x39a81d){let _0x43f90d=null,_0x54c8be=0x0;const _0x555ee8=new Map(Array['from'](_0x358754['model'][_0x3896dc]['insertions']['markers'])['filter'](([_0x59a1f4])=>!_0x59a1f4['startsWith']('revision:')));let _0xeafdb7=0x0;for(const _0x12da58 of _0x7f7188){const _0xa9caf=this['_makeTape'](_0x12da58['model'][_0x3896dc]['insertions']);_0x12da58==_0x358754?(_0x43f90d=_0xa9caf,_0x54c8be=_0x43f90d['length'],_0x43f90d['forEach'](_0x4de588=>{_0x4de588['id']=_0xeafdb7++;}),this['_processTape'](_0x43f90d)):this['_markInsertions'](_0x43f90d,_0xa9caf);const _0x382783=_0x43f90d['filter'](_0x4532db=>!_0x4532db['isAdded'])['map'](_0x7b911a=>_0x7b911a['id']);let _0x298ada=0x0;const _0x25e8c3=this['_makeTape'](_0x12da58['model'][_0x3896dc]['deletions']);_0x25e8c3['forEach'](_0x3c0fbe=>{_0x3c0fbe['isRemoved']?_0x3c0fbe['id']=_0x54c8be++:_0x3c0fbe['id']=_0x382783[_0x298ada++];}),this['_processTape'](_0x25e8c3),this['_setDistance'](_0x43f90d,'isAdded'),this['_setDistance'](_0x25e8c3,'isRemoved'),_0x12da58==_0x358754&&this['_markMarkers'](_0x43f90d,_0x555ee8),_0x43f90d=this['_joinTapes'](_0x43f90d,_0x25e8c3),this['_refreshStartEndIndex'](_0x43f90d),this['_setDistance'](_0x43f90d,'isRemoved');}_0x43f90d=_0x43f90d['filter'](_0x354b5a=>!(_0x354b5a['isAdded']&&_0x354b5a['isRemoved']));const _0x1919f9=new Map(_0x3207d3['model'][_0x3896dc]['deletions']['markers']),_0x2bb2bd=new Set(_0x555ee8['keys']());for(const _0x47d112 of _0x1919f9['keys']())_0x2bb2bd['delete'](_0x47d112);this['_markSuggestions'](_0x43f90d,_0x2bb2bd),this['_fixObsoleteTags'](_0x43f90d),_0x43f90d=this['_removeMissingPairs'](_0x43f90d),_0x43f90d=this['_markMismatchedRemovedTags'](_0x43f90d),_0x43f90d=this['_removeUnsupportedChanges'](_0x43f90d);const {root:_0x59117a,changes:_0x559368}=this['_makeModelFromTape'](_0x43f90d,_0x4f91e3,_0x3896dc);_0x320009['model'][_0x3896dc]=_0x59117a;const _0x2632da=_0x4c6fcd['get'](_0x3896dc);if(_0x2632da){const _0x299fd8=_0x4f91e3['get'](_0x2632da['userId']),_0x3944a4=new r({'author':_0x299fd8,'type':_0x2632da['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x3896dc});_0x559368['unshift'](_0x3944a4),_0x320009['attributes'][_0x3896dc]['revisionHistoryAttachChange']=_0x3944a4['id'];}_0x320009['changes']=_0x320009['changes']['concat'](_0x559368);}return _0x320009;}['_markMarkers'](_0x1ded16,_0x439692){for(let _0xbee46=0x0;_0xbee46<_0x1ded16['length'];_0xbee46++)for(const [_0x3b081d,_0x234c27]of _0x439692)_0x234c27['start']['isEqual'](_0x1ded16[_0xbee46]['previousPosition'])&&_0x1ded16[_0xbee46]['markersStart']['push'](_0x3b081d),_0x234c27['end']['isEqual'](_0x1ded16[_0xbee46]['nextPosition'])&&_0x1ded16[_0xbee46]['markersEnd']['push'](_0x3b081d);}['_joinTapes'](_0x10a324,_0x5eda9e){let _0x322964=[],_0x270b7e=0x0,_0x1912b4=0x0;for(;_0x270b7e<_0x10a324['length']||_0x1912b4<_0x5eda9e['length'];){const _0x22ea0c=_0x10a324[_0x270b7e]||{},_0x59e411=_0x5eda9e[_0x1912b4]||{};if(_0x22ea0c['id']==_0x59e411['id'])_0x270b7e++,_0x1912b4++,_0x322964['push'](_0x22ea0c);else{if(_0x59e411['isRemoved']&&_0x22ea0c['isAdded']){const {commonTape:_0xfe7fa5,iEnd:_0x300294,jEnd:_0x130c3c}=this['_threeWayMerge'](_0x10a324,_0x270b7e,_0x5eda9e,_0x1912b4);_0x322964=_0x322964['concat'](_0xfe7fa5),_0x270b7e=_0x300294,_0x1912b4=_0x130c3c;}else _0x59e411['isRemoved']?(_0x1912b4++,_0x322964['push'](_0x59e411)):(_0x270b7e++,_0x322964['push'](_0x22ea0c));}}return _0x322964;}['_markSuggestions'](_0x27a8a5,_0x2990be){const _0x30ff62=[];for(let _0x4abe2b=0x0;_0x4abe2b<_0x27a8a5['length'];_0x4abe2b++){for(let _0x45e1fe=0x0;_0x45e1fe<_0x27a8a5[_0x4abe2b]['markersStart']['length'];_0x45e1fe++){const _0x440afe=_0x27a8a5[_0x4abe2b]['markersStart'][_0x45e1fe];if(!_0x2990be['has'](_0x440afe))continue;const {group:_0x5f0ea5,type:_0x192feb,authorId:_0x12dbd5}=_0x1d8062(_0x440afe);'revision-suggestion'!=_0x5f0ea5||'insertion'!=_0x192feb&&'deletion'!=_0x192feb||(_0x30ff62['unshift']({'type':_0x192feb,'name':_0x440afe,'userId':_0x12dbd5}),_0x27a8a5[_0x4abe2b]['markersStart']['splice'](_0x45e1fe,0x1),_0x45e1fe--);}_0x905d61(_0x27a8a5[_0x4abe2b]);for(let _0x39634f=0x0;_0x39634f<_0x27a8a5[_0x4abe2b]['markersEnd']['length'];_0x39634f++){const _0x16ec31=_0x27a8a5[_0x4abe2b]['markersEnd'][_0x39634f];if(!_0x2990be['has'](_0x16ec31))continue;const {group:_0x199ec0,type:_0x3cce53}=_0x1d8062(_0x16ec31);if('revision-suggestion'!=_0x199ec0||'insertion'!=_0x3cce53&&'deletion'!=_0x3cce53)continue;_0x27a8a5[_0x4abe2b]['markersEnd']['splice'](_0x39634f,0x1),_0x39634f--;const _0x1ad091=_0x30ff62['findIndex'](_0x430cc6=>_0x430cc6['name']==_0x16ec31);_0x1ad091>-0x1&&_0x30ff62['splice'](_0x1ad091,0x1);}}function _0x1d8062(_0x2554f8){const _0x5ce60b=_0x2554f8['split'](':');return{'group':_0x5ce60b[0x0],'type':_0x5ce60b[0x1],'subType':_0x5ce60b['length']>=0x5?_0x5ce60b[0x2]:null,'id':_0x5ce60b['length']<0x5?_0x5ce60b[0x2]:_0x5ce60b[0x3],'authorId':_0x5ce60b['length']<0x5?_0x5ce60b[0x3]:_0x5ce60b[0x4],'markerCount':0x6==_0x5ce60b['length']?_0x5ce60b[0x5]:null};}function _0x905d61(_0x22b960){for(let _0x57e1a2=0x0;_0x57e1a2<_0x30ff62['length'];_0x57e1a2++){if(_0x22b960['isAdded']&&'insertion'==_0x30ff62[_0x57e1a2]['type'])return _0x22b960['isAddSuggestion']=_0x30ff62[_0x57e1a2],void delete _0x22b960['isAdded'];if(!_0x22b960['isAdded']&&!_0x22b960['isRemoved']&&'deletion'==_0x30ff62[_0x57e1a2]['type'])return void(_0x22b960['isRemoveSuggestion']=_0x30ff62[_0x57e1a2]);}}}['_setDistance'](_0x576079,_0x117543){let _0x1bbe50=0x0,_0x1bfe41=!0x1;const _0x124826=new Map();for(const _0x4bb4a8 of _0x576079)_0x4bb4a8[_0x117543]?_0x1bfe41&&(_0x1bbe50++,_0x1bfe41=!0x1):(_0x1bbe50++,_0x1bfe41=!0x0),_0x124826['set'](_0x4bb4a8['id'],_0x1bbe50);for(let _0x55a945=0x0;_0x55a945<_0x576079['length'];_0x55a945++){if('isRemoved'==_0x117543&&_0x576079[_0x55a945]['isAdded']||'isAdded'==_0x117543&&_0x576079[_0x55a945]['isRemoved'])continue;if('text'==_0x576079[_0x55a945]['type']){_0x576079[_0x55a945]['distance']=0x0;continue;}const _0x1ce2c8=_0x124826['get'](_0x576079[_0x55a945]['pairId']),_0x802314=_0x124826['get'](_0x576079[_0x55a945]['id']);_0x576079[_0x55a945]['distance']=_0x1ce2c8-_0x802314;}}['_getRevisionsRange'](_0x257c15,_0x1d32c3,_0x1339a5=!0x1){const _0x5d51b9=[];let _0xa57ffd=this['repository']['getIndex'](_0x257c15),_0x4f11ef=this['repository']['getIndex'](_0x1d32c3);for(-0x1==_0x4f11ef&&(_0x4f11ef=this['repository']['_revisions']['length'],_0x1339a5=!0x1);_0xa57ffd<_0x4f11ef;)_0x5d51b9['push'](this['repository']['getRevision'](_0xa57ffd)),_0xa57ffd++;return _0x1339a5&&_0x5d51b9['push'](this['repository']['getRevision'](_0xa57ffd)),_0x5d51b9;}['_threeWayMerge'](_0x17ee53,_0x4e8e10,_0x40aa93,_0x1ca163){const _0x70525f=this['editor']['model']['schema'];let _0x344771=_0x4e8e10;for(;_0x17ee53[_0x344771]&&_0x17ee53[_0x344771]['isAdded'];)_0x344771++;let _0x1f567a=_0x1ca163;for(;_0x40aa93[_0x1f567a]&&_0x40aa93[_0x1f567a]['isRemoved'];)_0x1f567a++;_0x4f7180(_0x17ee53,_0x4e8e10,_0x344771),_0x4f7180(_0x40aa93,_0x1ca163,_0x1f567a);const _0x95f49c=_0x40aa93['slice'](_0x1ca163,_0x1f567a)['concat'](_0x17ee53['slice'](_0x4e8e10,_0x344771));return _0x95f49c['sort']((_0x54ebf5,_0x46c610)=>_0x54ebf5['side']!=_0x46c610['side']?_0x54ebf5['side']-_0x46c610['side']:_0x54ebf5['level']!=_0x46c610['level']?_0x54ebf5['level']-_0x46c610['level']:_0x54ebf5['distance']!=_0x46c610['distance']?_0x46c610['distance']-_0x54ebf5['distance']:!!_0x54ebf5['isAdded']!=!!_0x46c610['isAdded']?-0x1==_0x54ebf5['side']||0x0==_0x54ebf5['side']?_0x54ebf5['isAdded']?-0x1:0x1:_0x54ebf5['isAdded']?0x1:-0x1:_0x54ebf5['index']-_0x46c610['index']),{'commonTape':_0x95f49c,'iEnd':_0x344771,'jEnd':_0x1f567a};function _0x4f7180(_0x19854c,_0x246ea8,_0x221740){let _0x5c2108=-0x1,_0x7333f3=Number['POSITIVE_INFINITY'],_0x3aeaca=!0x0;for(let _0x21844b=_0x246ea8;_0x21844b<_0x221740;_0x21844b++)if(_0x70525f['isInline'](_0x19854c[_0x21844b]['item'])||(_0x3aeaca=!0x1),_0x19854c[_0x21844b]['item']['startIndex']<_0x246ea8&&(_0x5c2108=_0x21844b),_0x19854c[_0x21844b]['item']['endIndex']>=_0x221740){_0x7333f3=_0x21844b;break;}_0x3aeaca&&(_0x5c2108=_0x221740-0x1);for(let _0x300c16=_0x246ea8;_0x300c16<_0x221740;_0x300c16++)_0x19854c[_0x300c16]['side']=_0x300c16<=_0x5c2108?-0x1:_0x300c16<_0x7333f3?0x0:0x1,_0x19854c[_0x300c16]['index']=_0x300c16;let _0x57ffc8=0x0;for(let _0x57c141=_0x246ea8;_0x57c141<=_0x5c2108;_0x57c141++)0x0==_0x19854c[_0x57c141]['distance']?_0x19854c[_0x57c141]['level']=_0x57ffc8:(_0x57ffc8++,_0x19854c[_0x57c141]['level']=_0x57ffc8,_0x57ffc8++);for(let _0x4d910f=_0x246ea8;_0x4d910f<_0x221740;_0x4d910f++)0x0==_0x19854c[_0x4d910f]['side']&&(_0x19854c[_0x4d910f]['level']=_0x57ffc8);_0x57ffc8=0x0;for(let _0x2743ba=_0x221740-0x1;_0x2743ba>=_0x7333f3;_0x2743ba--)0x0==_0x19854c[_0x2743ba]['distance']?_0x19854c[_0x2743ba]['level']=_0x57ffc8:(_0x57ffc8--,_0x19854c[_0x2743ba]['level']=_0x57ffc8,_0x57ffc8--);}}['_fixObsoleteTags'](_0x52ad21){const _0x54efcb=new Map(),_0x322d54=this['editor']['model']['schema'];for(let _0x4ff0d5=0x1;_0x4ff0d5<_0x52ad21['length'];_0x4ff0d5++){let _0x146fff,_0x1e122d,_0x1872af;const _0x2f11b3=_0x52ad21[_0x4ff0d5],_0x477fa6=_0x52ad21[_0x4ff0d5-0x1];if('text'==_0x2f11b3['type'])continue;if(_0x2f11b3['type']!=_0x477fa6['type'])continue;if(!_0x322d54['isBlock'](_0x477fa6['item'])||_0x322d54['isLimit'](_0x477fa6['item']))continue;if(!_0x322d54['isBlock'](_0x2f11b3['item'])||_0x322d54['isLimit'](_0x2f11b3['item']))continue;if((_0x52ad21[_0x4ff0d5]['isAdded']||_0x52ad21[_0x4ff0d5]['isAddSuggestion'])&&_0x52ad21[_0x4ff0d5-0x1]['isRemoved'])_0x146fff=_0x52ad21[_0x4ff0d5],_0x1e122d=_0x52ad21[_0x4ff0d5-0x1],_0x1872af=_0x4ff0d5-0x1;else{if(!_0x52ad21[_0x4ff0d5]['isRemoved']||!_0x52ad21[_0x4ff0d5-0x1]['isAdded']&&!_0x52ad21[_0x4ff0d5-0x1]['isAddSuggestion'])continue;_0x146fff=_0x52ad21[_0x4ff0d5-0x1],_0x1e122d=_0x52ad21[_0x4ff0d5],_0x1872af=_0x4ff0d5;}const _0x4ae3dd=_0x146fff['level']==_0x1e122d['level'],_0x3ce002=Math['abs'](_0x146fff['level'])<Math['abs'](_0x1e122d['level'])&&0x0==_0x1e122d['distance'];(_0x4ae3dd||_0x3ce002)&&(_0x54efcb['set'](_0x1e122d['id'],_0x146fff['id']),_0x52ad21['splice'](_0x1872af,0x1),_0x4ff0d5--,_0x146fff['isAdded']=!0x1);}for(let _0x3a13f9=0x0;_0x3a13f9<_0x52ad21['length'];_0x3a13f9++)_0x54efcb['has'](_0x52ad21[_0x3a13f9]['pairId'])&&(_0x52ad21[_0x3a13f9]['pairId']=_0x54efcb['get'](_0x52ad21[_0x3a13f9]['pairId']));}['_removeMissingPairs'](_0x90e54c){const _0xa5ee03=new Set(_0x90e54c['map'](_0x57e4ae=>_0x57e4ae['id']));for(let _0x1810d8=0x0;_0x1810d8<_0x90e54c['length'];_0x1810d8++)_0xa5ee03['has'](_0x90e54c[_0x1810d8]['pairId'])||0x0==_0x90e54c[_0x1810d8]['distance']||(_0x90e54c[_0x1810d8]['isIncorrect']=!0x0);return _0x90e54c['filter'](_0x5c0a38=>!_0x5c0a38['isIncorrect']);}['_markMismatchedRemovedTags'](_0x1de930){const _0x1218f8=new Set();for(let _0x1dcdad=0x0;_0x1dcdad<_0x1de930['length'];_0x1dcdad++){if(_0x1218f8['has'](_0x1de930[_0x1dcdad]['id'])&&_0x1de930[_0x1dcdad]['isRemoved']&&(_0x1de930[_0x1dcdad]['isIncorrect']=!0x0),_0x1de930[_0x1dcdad]['isIncorrect'])continue;if(0x0==_0x1de930[_0x1dcdad]['distance'])continue;if('elementStart'!=_0x1de930[_0x1dcdad]['type'])continue;if(null==_0x1de930[_0x1dcdad]['pairId'])continue;let _0x4856a5=_0x1dcdad+0x1,_0x4a0203=0x0;for(;_0x1de930[_0x4856a5]['id']!=_0x1de930[_0x1dcdad]['pairId'];)'elementStart'==_0x1de930[_0x4856a5]['type']?_0x4a0203++:'elementEnd'==_0x1de930[_0x4856a5]['type']&&_0x4a0203--,_0x4856a5++;if(0x0!=_0x4a0203){if(_0x1de930[_0x1dcdad]['isRemoved'])_0x1de930[_0x1dcdad]['isIncorrect']=!0x0;else{for(;_0x4856a5!=_0x1dcdad;)_0x1de930[_0x4856a5]['isRemoved']&&0x0!=_0x1de930[_0x4856a5]['distance']&&(_0x1de930[_0x4856a5]['isIncorrect']=!0x0,_0x1218f8['add'](_0x1de930[_0x4856a5]['pairId'])),_0x4856a5--;}}}return _0x1de930['filter'](_0x37a730=>!_0x37a730['isIncorrect']);}['_removeUnsupportedChanges'](_0x107490){const _0x16cc80=this['editor']['model']['schema'];for(let _0x257992=0x0;_0x257992<_0x107490['length'];_0x257992++){if(!(_0x107490[_0x257992]['isAdded']||_0x107490[_0x257992]['isAddSuggestion']||_0x107490[_0x257992]['isRemoved']||_0x107490[_0x257992]['isRemoveSuggestion']))continue;if(0x0==_0x107490[_0x257992]['distance'])continue;const _0x294ebf=_0x107490[_0x257992]['item'];_0x16cc80['isBlock'](_0x294ebf)||_0x16cc80['isLimit'](_0x294ebf)||(_0x107490[_0x257992]['isAdded']&&delete _0x107490[_0x257992]['isAdded'],_0x107490[_0x257992]['isAddSuggestion']&&delete _0x107490[_0x257992]['isAddSuggestion'],_0x107490[_0x257992]['isRemoveSuggestion']&&delete _0x107490[_0x257992]['isRemoveSuggestion'],_0x107490[_0x257992]['isRemoved']&&(_0x107490[_0x257992]['isIncorrect']=!0x0));}return _0x107490['filter'](_0x33b259=>!_0x33b259['isIncorrect']);}['_makeModelFromTape'](_0x501b13,_0xe0a6f4,_0x441846){const _0x2509d2=new mt(),_0x54112c=[],_0x3cdfc3=new Map(),_0x67433e=this['editor']['model'],_0x427e77=_0x67433e['schema'],_0x22238b=[_0x2509d2],_0x2bc102={},_0x28f080={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x24345d=null;const _0x2f00c0=[0x0];for(let _0x11048e=0x0;_0x11048e<_0x501b13['length'];_0x11048e++)if('elementStart'===_0x501b13[_0x11048e]['type']){_0x501b13[_0x11048e]['previousPosition']=_0x67433e['createPositionFromPath'](_0x2509d2,_0x2f00c0);const _0x686158=new ft(_0x501b13[_0x11048e]['item']['name'],_0x501b13[_0x11048e]['item']['getAttributes']());_0x22238b[0x0]['_appendChild'](_0x686158),_0x2f00c0['push'](0x0),_0x22238b['unshift'](_0x686158),_0x501b13[_0x11048e]['nextPosition']=_0x67433e['createPositionFromPath'](_0x2509d2,_0x2f00c0);}else'elementEnd'===_0x501b13[_0x11048e]['type']?(_0x22238b['shift'](),_0x501b13[_0x11048e]['previousPosition']=_0x67433e['createPositionFromPath'](_0x2509d2,_0x2f00c0),_0x2f00c0['pop'](),_0x2f00c0[_0x2f00c0['length']-0x1]++,_0x501b13[_0x11048e]['nextPosition']=_0x67433e['createPositionFromPath'](_0x2509d2,_0x2f00c0)):(_0x501b13[_0x11048e]['previousPosition']=_0x67433e['createPositionFromPath'](_0x2509d2,_0x2f00c0),_0x24345d?_0x24345d['_data']+=_0x501b13[_0x11048e]['item']['data']:_0x24345d=new wt(_0x501b13[_0x11048e]['item']['data'],_0x501b13[_0x11048e]['item']['getAttributes']()),_0x501b13[_0x11048e+0x1]&&'text'===_0x501b13[_0x11048e+0x1]['type']&&_0x33ccbf(_0x24345d,_0x501b13[_0x11048e+0x1]['item'])||(_0x22238b[0x0]['_appendChild'](_0x24345d),_0x24345d=null),_0x2f00c0[_0x2f00c0['length']-0x1]+=_0x501b13[_0x11048e]['item']['offsetSize'],_0x501b13[_0x11048e]['nextPosition']=_0x67433e['createPositionFromPath'](_0x2509d2,_0x2f00c0));for(let _0x51796d=0x0;_0x51796d<_0x501b13['length'];_0x51796d++){const _0x2c1296=_0x501b13[_0x51796d]['previousPosition'],_0x19566c=_0x501b13[_0x51796d]['nextPosition'];for(const _0x38b05b of _0x501b13[_0x51796d]['markersStart'])_0x3cdfc3['set'](_0x38b05b,{'start':_0x2c1296,'end':null});_0x24c477('isRemoveSuggestion',_0x51796d,_0x2c1296,_0x19566c),_0x24c477('isAddSuggestion',_0x51796d,_0x2c1296,_0x19566c),_0x24c477('isRemoved',_0x51796d,_0x2c1296,_0x19566c),_0x24c477('isAdded',_0x51796d,_0x2c1296,_0x19566c);for(const _0x54ee5b of _0x501b13[_0x51796d]['markersEnd']){_0x3cdfc3['get'](_0x54ee5b)['end']=_0x19566c;}}for(const [_0x479300,_0x37cf39]of _0x3cdfc3){const _0x3cc6ea=this['editor']['model']['createRange'](_0x37cf39['start'],_0x37cf39['end']);_0x2509d2['markers']['set'](_0x479300,_0x3cc6ea);}return _0x54112c['sort']((_0x4ddd6b,_0xfc42bf)=>{const _0x2d8309=_0x2509d2['markers']['get']('revision:'+_0x4ddd6b['id']),_0x58af1e=_0x2509d2['markers']['get']('revision:'+_0xfc42bf['id']);return _0x2d8309['start']['isBefore'](_0x58af1e['start'])?-0x1:_0x2d8309['start']['isAfter'](_0x58af1e['start'])?0x1:_0x2d8309['end']['isBefore'](_0x58af1e['end'])?-0x1:_0x2d8309['end']['isAfter'](_0x58af1e['end'])?0x1:'add'===_0x4ddd6b['type']?-0x1:0x1;}),{'root':_0x2509d2,'changes':_0x54112c};function _0x24c477(_0x12937a,_0x2de933,_0x15137b,_0x23834c){const _0x396cd8=!!_0x501b13[_0x2de933][_0x12937a],_0x167184=_0x396cd8?_0x501b13[_0x2de933][_0x12937a]['userId']:null,_0x21759a=_0x2de933===_0x501b13['length']-0x1,_0x123dee=_0x28f080[_0x12937a][0x0],_0x598d05=_0x427e77['isObject'](_0x501b13[_0x2de933]['item']);!_0x2bc102[_0x12937a]&&_0x396cd8?_0x2bc102[_0x12937a]={'start':_0x15137b,'tapeItem':_0x501b13[_0x2de933],'userId':_0x167184,'type':_0x12937a}:_0x2bc102[_0x12937a]&&!_0x396cd8?(_0x2bc102[_0x12937a]['end']=_0x15137b,_0x319185(_0x2bc102[_0x12937a]),_0x2bc102[_0x12937a]=null):_0x2bc102[_0x12937a]&&_0x396cd8&&_0x2bc102[_0x12937a]['userId']!==_0x167184&&(_0x2bc102[_0x12937a]['end']=_0x15137b,_0x123dee&&_0x123dee['userId']===_0x2bc102[_0x12937a]['userId']||_0x319185(_0x2bc102[_0x12937a]),_0x2bc102[_0x12937a]={'start':_0x15137b,'tapeItem':_0x501b13[_0x2de933],'userId':_0x167184,'type':_0x12937a}),_0x2bc102[_0x12937a]&&_0x598d05&&('elementStart'!==_0x501b13[_0x2de933]['type']||_0x123dee&&_0x123dee['userId']===_0x167184||_0x28f080[_0x12937a]['unshift']({'userId':_0x167184,'object':_0x501b13[_0x2de933]['item'],'change':_0x2bc102[_0x12937a]}),'elementEnd'===_0x501b13[_0x2de933]['type']&&_0x123dee&&_0x123dee['object']===_0x501b13[_0x2de933]['item']&&(_0x28f080[_0x12937a]['shift'](),_0x2bc102[_0x12937a]=_0x123dee['change'])),_0x2bc102[_0x12937a]&&_0x21759a&&(_0x2bc102[_0x12937a]['end']=_0x23834c,_0x319185(_0x2bc102[_0x12937a]),_0x2bc102[_0x12937a]=null);}function _0x319185({start:_0x1ca794,end:_0x42f4f4,tapeItem:_0x22726c,userId:_0x166da7,type:_0x537c57}){const _0x43b228=_0x22726c['item'],_0x5196f=_0x67433e['schema']['isBlock'](_0x43b228)&&!_0x67433e['schema']['isLimit'](_0x43b228),_0x770d6c=_0x1ca794['nodeAfter']==_0x42f4f4['parent']&&_0x42f4f4['isAtStart'];if(_0x5196f&&_0x770d6c)return;const _0x2fc55e=_0x67433e['createRange'](_0x1ca794,_0x42f4f4),_0x114343=_0xe0a6f4['get'](_0x166da7),_0x4ec205=new r({'author':_0x114343,'type':'isAdded'==_0x537c57||'isAddSuggestion'==_0x537c57?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x537c57||'isRemoveSuggestion'==_0x537c57},'createdAt':new Date(),'rootName':_0x441846});_0x54112c['push'](_0x4ec205),_0x2509d2['markers']['set']('revision:'+_0x4ec205['id'],_0x2fc55e);}function _0x33ccbf(_0x11df9f,_0x267d93){const _0x2bdc22=_0x11df9f['getAttributes'](),_0x3607fa=_0x267d93['getAttributes']();for(const _0x1f06d8 of _0x2bdc22){if(_0x1f06d8[0x1]!==_0x267d93['getAttribute'](_0x1f06d8[0x0]))return!0x1;_0x3607fa['next']();}return _0x3607fa['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x471c23=>{const _0x396935=_0x471c23['markerName']['split'](':')[0x1],_0x2e8ed7=this['_getChangeFromId'](_0x396935);if(!_0x2e8ed7)return null;const _0x20abdc='add'==_0x2e8ed7['type']?'insertion':'deletion',_0x534e46=['ck-suggestion-marker','ck-suggestion-marker-'+_0x20abdc];return _0x2e8ed7['data']['isSuggestion']&&_0x534e46['push']('ck-suggestion-marker-'+_0x20abdc+'-new'),this['activeChange']==_0x2e8ed7&&_0x534e46['push']('ck-suggestion-marker--active'),{'classes':_0x534e46,'attributes':{'data-change-id':_0x396935}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x201a23=>{_0x201a23['on']('element:pre',(_0x2094b3,_0x18838e,_0x36166e)=>{const _0xbb41ae=_0x18838e['viewItem']['getChild'](0x0);if(!_0xbb41ae||!_0xbb41ae['is']('element','code'))return;if(!_0x36166e['consumable']['consume'](_0xbb41ae,{'attributes':['vid_start','vid_end']}))return;const _0x17850e=_0x18838e['modelRange']['start']['nodeAfter'];_0x36166e['writer']['setAttribute']('vid_start',_0xbb41ae['getAttribute']('vid_start'),_0x17850e),_0x36166e['writer']['setAttribute']('vid_end',_0xbb41ae['getAttribute']('vid_end'),_0x17850e);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x5f4b73=>{_0x5f4b73['on']('element',(_0xbfac30,_0x3e34b3,_0x385d9a)=>{if(!_0x385d9a['consumable']['consume'](_0x3e34b3['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x3e34b3['modelRange']['isCollapsed'])return;const _0x24197f=_0x3e34b3['modelRange']['start']['nodeAfter'];_0x24197f['hasAttribute']('vid_start')||_0x24197f['hasAttribute']('vid')||(_0x385d9a['writer']['setAttribute']('vid_start',_0x3e34b3['viewItem']['getAttribute']('vid_start'),_0x24197f),_0x385d9a['writer']['setAttribute']('vid_end',_0x3e34b3['viewItem']['getAttribute']('vid_end'),_0x24197f));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x1a560c=>_0x1a560c['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x4230e4,[,_0x4e122a])=>{['vid_start','vid_end','vid']['includes'](_0x4e122a)&&(_0x4230e4['return']=!0x0,_0x4230e4['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x1d951b=>{_0x1d951b['on']('attribute:vid',(_0x161b71,_0x452695,_0x56a884)=>{if('\x20'!=_0x452695['item']['data']||_0x452695['item']['parent']['maxOffset']>0x1)return;if(!_0x56a884['consumable']['consume'](_0x452695['item'],_0x161b71['name']))return;const _0x499dc4=_0x56a884['writer'],_0x4ada06=_0x56a884['mapper']['toViewRange'](_0x452695['range']);_0x499dc4['wrap'](_0x4ada06,_0x499dc4['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x21a308){const _0x564f6c=_0x21a308['plugins']['get']('RevisionViewer');return(_0xa203ec,_0x496c21,_0x397707)=>{const _0x1b10d6=_0x496c21['markerName']['split'](':')[0x1],_0x3c21b6=_0x564f6c['_getChangeFromId'](_0x1b10d6);if(!_0x3c21b6)return null;const _0x11c48d='add'==_0x3c21b6['type']?'split':'merge';if(!_0x397707['consumable']['test'](_0x496c21['markerRange'],_0xa203ec['name']))return;const _0x4b9247=_0x496c21['markerRange']['getWalker'](),_0x15bbca=_0x496c21['markerRange']['start'],_0x2a8d29=_0x21a308['model']['schema'];let _0x4cf777=null,_0x2c877e=null,_0x1cd4cc=!0x1,_0x2c28dc=!0x1;for(const _0x21a9d1 of _0x4b9247){const _0x48f21a=_0x21a9d1['item'];_0x1cd4cc=_0x1cd4cc||_0x2a8d29['isContent'](_0x48f21a);const _0x4b31cd=_0x397707['mapper']['toViewElement'](_0x48f21a);if(_0x4b31cd&&_0x4b31cd['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x21a9d1['type']&&(_0x2a8d29['isBlock'](_0x48f21a)&&!_0x2a8d29['isLimit'](_0x48f21a)&&(_0x48f21a['nextSibling']||_0x15bbca['isAtEnd']?_0x4cf777&&_0x4cf777['parent']==_0x48f21a||(_0x4cf777=_0x48f21a,_0x145ee5(_0x21a9d1['previousPosition']),_0x2c28dc=!0x0):_0x2c877e=_0x2c877e||_0x21a9d1['previousPosition']));}function _0x145ee5(_0x5eb4b5){const _0x1fb2ba=_0x397707['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x11c48d}),_0x4ef7a2=_0x397707['mapper']['toViewPosition'](_0x5eb4b5);_0x3c21b6['data']['isSuggestion']&&_0x397707['writer']['addClass']('ck-suggestion-marker-'+_0x11c48d+'-new',_0x1fb2ba),_0x564f6c['activeChange']==_0x3c21b6&&_0x397707['writer']['addClass']('ck-suggestion-marker--active',_0x1fb2ba),_0x397707['writer']['insert'](_0x4ef7a2,_0x1fb2ba),_0x397707['mapper']['bindElementToMarker'](_0x1fb2ba,_0x496c21['markerName']);}_0x1cd4cc||_0x2c28dc||!_0x2c877e||_0x145ee5(_0x2c877e);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x5b7dbf,_0x5b22a2,_0xd093d6)=>{const _0x5629c0=_0xd093d6['mapper']['markerNameToElements'](_0x5b22a2['markerName']);if(_0x5629c0){for(const _0x1bb422 of _0x5629c0)(_0x1bb422['hasClass']('ck-suggestion-marker-split')||_0x1bb422['hasClass']('ck-suggestion-marker-merge'))&&(_0xd093d6['mapper']['unbindElementFromMarkerName'](_0x1bb422,_0x5b22a2['markerName']),_0xd093d6['writer']['remove'](_0x1bb422));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x6fe920,_0xd04bc3,_0x4662da)=>{const _0x3015db=_0xd04bc3['markerName']['split'](':')[0x1],_0x372d5d=this['_getChangeFromId'](_0x3015db);if(!_0x372d5d)return null;const _0x1fef7a='add'==_0x372d5d['type']?'split':'merge';if(_0x4662da['consumable']['test'](_0xd04bc3['markerRange'],_0x6fe920['name']))for(const _0x1d4d20 of _0xd04bc3['markerRange']['getItems']()){if(!_0x1d4d20['is']('element','softBreak'))continue;const _0x76860b=_0x4662da['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x1fef7a}),_0x5718ac=_0x4662da['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x1d4d20));_0x372d5d['data']['isSuggestion']&&_0x4662da['writer']['addClass']('ck-suggestion-marker-'+_0x1fef7a+'-new',_0x76860b),this['activeChange']==_0x372d5d&&_0x4662da['writer']['addClass']('ck-suggestion-marker--active',_0x76860b),_0x4662da['writer']['insert'](_0x5718ac,_0x76860b),_0x4662da['mapper']['bindElementToMarker'](_0x76860b,_0xd04bc3['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x390ca3=>{for(const _0x95fe6b of this['editor']['model']['document']['getRootNames']()){const _0x2d8817=this['editor']['model']['document']['getRoot'](_0x95fe6b),_0x138933=this['editor']['editing']['view']['document']['getRoot'](_0x95fe6b);if(_0x138933){const _0x332190=_0x2d8817['getAttribute']('revisionHistoryAttachChange');if(_0x390ca3['removeAttribute']('data-change-id',_0x138933),_0x390ca3['removeClass']('ck-revision-history-root-add',_0x138933),_0x390ca3['removeClass']('ck-revision-history-root-remove',_0x138933),_0x390ca3['removeClass']('ck-revision-history-root--active',_0x138933),_0x332190){const _0x46ca3c=this['_getChangeFromId'](_0x332190);if(!_0x46ca3c)return null;_0x390ca3['setAttribute']('data-change-id',_0x332190,_0x138933),_0x390ca3['addClass']('ck-revision-history-root-'+_0x46ca3c['type'],_0x138933),this['activeChange']==_0x46ca3c&&_0x390ca3['addClass']('ck-revision-history-root--active',_0x138933);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x555764=>'revision-comment:'+_0x555764,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x448fa4=>'revision-suggestion:'+_0x448fa4,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x1ee9e2=>({'name':'suggestion:'+_0x1ee9e2,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x11bf36=>{const _0x5a89be=_0x11bf36['markerName']['split'](':')[0x1];return'insertion'!=_0x5a89be&&'deletion'!=_0x5a89be?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x5a89be]};}}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:deletion',Z(this['editor'],'merge'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:insertion',Z(this['editor'],'split'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision-suggestion',(_0x456671,_0x558cce,_0x2158b1)=>{const _0x355520=_0x2158b1['mapper']['markerNameToElements'](_0x558cce['markerName']);if(_0x355520){for(const _0x442017 of _0x355520)_0x442017['is']('uiElement')&&(_0x2158b1['mapper']['unbindElementFromMarkerName'](_0x442017,_0x558cce['markerName']),_0x2158b1['writer']['remove'](_0x442017));}},{'priority':'high'});}['_getChangeFromId'](_0x5f45f7){return this['_changeIdToChange']['get'](_0x5f45f7);}['_getViewForChange'](_0xb704ac){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new X(this['editor']['locale'],_0xb704ac),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x37917a,_0x875523,_0x5d822a,_0x1f1161)=>{_0x1f1161&&this['_balloon']['remove'](_0x1f1161),_0x5d822a&&(this['_balloon']['add']({'view':_0x5d822a,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x4a702e=this['editor']['editing'],_0xb9ee36=this['_getChangeFromId'](_0x5d822a['changeId']);let _0x6cdb30;if(_0xb9ee36['data']['isOnRoot']){const _0x2a4ee1=_0x4a702e['view']['getDomRoot'](_0xb9ee36['rootName']);_0x6cdb30=Array['from'](_0x2a4ee1['getClientRects']());}else{const _0x2f40aa=this['editor']['model']['markers']['get']('revision:'+_0x5d822a['changeId']);_0x6cdb30=Array['from'](_0x4a702e['mapper']['markerNameToElements'](_0x2f40aa['name']))['map'](_0x5dabd8=>_0x4a702e['view']['domConverter']['mapViewToDom'](_0x5dabd8))['map'](_0xaef0a4=>Array['from'](_0xaef0a4['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x6cdb30[0x0];return _0x6cdb30['find'](_0x5acf52=>_0x5acf52['top']-0x3<=this['_activeViewTarget']['y']&&_0x5acf52['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x5acf52['left']-0x3<=this['_activeViewTarget']['x']&&_0x5acf52['right']+0x3>=this['_activeViewTarget']['x'])||_0x6cdb30[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x2fee32,_0x2b61ee,_0x45eda4,_0x351375)=>{this['activeView']=_0x45eda4?this['_getViewForChange'](_0x45eda4):null,this['editor']['model']['change'](()=>{const _0x2c5483=this['editor']['editing'];_0x351375&&(_0x351375['data']['isOnRoot']?_0x2c5483['view']['change'](_0x455f6d=>{_0x455f6d['removeClass']('ck-revision-history-root--active',_0x2c5483['view']['document']['getRoot'](_0x351375['rootName']));}):_0x2c5483['reconvertMarker']('revision:'+_0x351375['id'])),_0x45eda4&&(_0x45eda4['data']['isOnRoot']?_0x2c5483['view']['change'](_0x132444=>{_0x132444['addClass']('ck-revision-history-root--active',_0x2c5483['view']['document']['getRoot'](_0x45eda4['rootName']));}):_0x2c5483['reconvertMarker']('revision:'+_0x45eda4['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x321ee4,_0x2f6bbf)=>{if(this['activeChange'])return;const _0x519243=this['_findChangeIdFromDomTarget'](_0x2f6bbf['target']),_0x465ad1=this['_changeIdToChange']['get'](_0x519243);_0x465ad1?(this['_activeViewTarget']={'x':_0x2f6bbf['domEvent']['x'],'y':_0x2f6bbf['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x465ad1)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x5193c1,_0x3fdd50)=>{const _0xc915f7=this['_findChangeIdFromDomTarget'](_0x3fdd50['target']),_0x165903=this['_changeIdToChange']['get'](_0xc915f7);_0x165903?(this['_activeViewTarget']={'x':_0x3fdd50['domEvent']['x'],'y':_0x3fdd50['domEvent']['y']},_0x165903===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x165903):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x23b91c){do{const _0x366a73=_0x23b91c['getAttribute']('data-change-id');if(_0x366a73)return _0x366a73;_0x23b91c=_0x23b91c['parent'];}while(_0x23b91c);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x1e7332=>{for(const _0xa9e47d of this['editor']['model']['markers'])_0x1e7332['removeMarker'](_0xa9e47d);});}}function Z(_0x20aa8a,_0x7e1d33){return(_0x51c81e,_0x265ba0,_0x377477)=>{if(!_0x377477['consumable']['test'](_0x265ba0['markerRange'],_0x51c81e['name']))return;const _0x4754b1=_0x265ba0['markerRange']['getWalker'](),_0xea112d=_0x265ba0['markerRange']['start'],_0x41377e=_0x20aa8a['model']['schema'];let _0x3dd317=null,_0x1f902d=null,_0x282d9e=!0x1,_0x532854=!0x1;for(const _0x51b1cd of _0x4754b1){const _0x47fab7=_0x51b1cd['item'];_0x282d9e=_0x282d9e||_0x41377e['isContent'](_0x47fab7);const _0x1054f5=_0x377477['mapper']['toViewElement'](_0x47fab7);if(_0x1054f5&&_0x1054f5['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x51b1cd['type']&&(_0x41377e['isBlock'](_0x47fab7)&&!_0x41377e['isLimit'](_0x47fab7)&&(_0x47fab7['nextSibling']||_0xea112d['isAtEnd']?_0x3dd317&&_0x3dd317['parent']==_0x47fab7||(_0x3dd317=_0x47fab7,_0x2e0122(_0x51b1cd['previousPosition']),_0x532854=!0x0):_0x1f902d=_0x1f902d||_0x51b1cd['previousPosition']));}function _0x2e0122(_0x1ffcaa){const _0x3afa66=_0x377477['mapper']['toViewPosition'](_0x1ffcaa),_0x1b94dc=_0x377477['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x7e1d33});_0x377477['writer']['insert'](_0x3afa66,_0x1b94dc),_0x377477['mapper']['bindElementToMarker'](_0x1b94dc,_0x265ba0['markerName']);}_0x282d9e||_0x532854||!_0x1f902d||_0x2e0122(_0x1f902d);};}class _t extends _0x56d2a8{constructor(_0x47110c){super(_0x47110c);const _0xb63246=_0x47110c['plugins']['get'](d);this['affectsData']=!0x1,this['listenTo'](_0xb63246,'change:isReady',()=>this['refresh']()),this['listenTo'](_0xb63246,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x541ad0=this['editor'],_0x3cf3b3=_0x541ad0['plugins']['get'](d),_0x12b3b4=_0x3cf3b3['isReady']?_0x3cf3b3['diff']['newRevisionId']:null;_0x541ad0['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x12b3b4);}['refresh'](){const {isReady:_0x4d59db,isEnabled:_0x1a6e08,repository:_0x36d455,diff:_0x54348c}=this['editor']['plugins']['get'](d),_0x5c0f05=_0x54348c&&_0x36d455['getLaterVisibleRevision'](_0x54348c['newRevisionId']);this['isEnabled']=_0x4d59db&&_0x1a6e08&&Boolean(_0x5c0f05);}}class yt extends _0x56d2a8{['_step'];constructor(_0x535745,{direction:_0x2ba5cc}){super(_0x535745);const _0x547013=_0x535745['plugins']['get'](d);this['affectsData']=!0x1,this['_step']='forward'===_0x2ba5cc?0x1:-0x1,this['listenTo'](_0x547013,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x547013,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x547013,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x552220=this['editor'],_0x42fd8b=_0x552220['plugins']['get'](d),{isNavigationMode:_0x130c22,currentChangeNumber:_0x319359}=_0x42fd8b;let _0x3c8837;if(_0x42fd8b['activeChange']=_0x130c22?_0x42fd8b['diff']['changes']['get'](_0x319359+this['_step']):_0x42fd8b['diff']['changes']['first'],_0x42fd8b['activeChange']['data']['isOnRoot'])_0x3c8837=_0x552220['editing']['view']['getDomRoot'](_0x42fd8b['activeChange']['rootName']);else{const _0x4009a3=_0x552220['model']['markers']['get']('revision:'+_0x42fd8b['activeChange']['id']);_0x3c8837=_0x3ac489(_0x552220['editing'],_0x4009a3);}_0x182fa2({'target':_0x3c8837,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x3996c4,currentChangeNumber:_0x243d13,numberOfChanges:_0x1e5846,isReady:_0x5204c4,isEnabled:_0x36c91b}=this['editor']['plugins']['get'](d);this['isEnabled']=!!(_0x36c91b&&_0x5204c4&&_0x1e5846)&&(!_0x3996c4||(0x1===this['_step']?_0x243d13<_0x1e5846-0x1:_0x243d13>0x0));}}class _i extends _0x3f0f05{constructor(_0x86132c){super(_0x86132c);const _0x394588=this['bindTemplate'],_0x1ab82e=new _0x13b3b7(_0x86132c),_0x136402=new _0x13b3b7(_0x86132c);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',(_0x1b749f,_0xa31168)=>_0x1b749f&&_0xa31168>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x3a6e0a,_0x32ab4a,_0x5577d2,_0x54e6b6)=>{if(!_0x3a6e0a)return m(_0x86132c,'Loading...');if(!_0x5577d2)return m(_0x86132c,'No\x20changes');const _0x33c990=m(_0x86132c,'NUMBER_OF_CHANGES',_0x5577d2);return _0x54e6b6?m(_0x86132c,'X_OF_Y_CHANGES',[_0x32ab4a+0x1,_0x5577d2]):_0x33c990;}),_0x1ab82e['set']({'label':m(_0x86132c,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':'<svg\x20viewBox=\x220\x200\x2020\x2020\x22\x20xmlns=\x22http://www.w3.org/2000/svg\x22><path\x20d=\x22M16.435\x2014.494a.75.75\x200\x200\x200\x201.197-.899l-.067-.089-6.992-8a.75.75\x200\x200\x200-1.05-.078l-.079.078-7.008\x208a.75.75\x200\x200\x200\x201.049\x201.066l.08-.078\x206.442-7.354\x206.428\x207.354z\x22/></svg>\x0a'}),_0x136402['set']({'label':m(_0x86132c,'Show\x20next\x20change'),'tooltip':!0x0,'icon':'<svg\x20viewBox=\x220\x200\x2020\x2020\x22\x20xmlns=\x22http://www.w3.org/2000/svg\x22><path\x20d=\x22M16.435\x205.506a.75.75\x200\x200\x201\x201.197.899l-.067.089-6.992\x208a.75.75\x200\x200\x201-1.05.078l-.079-.078-7.008-8a.75.75\x200\x200\x201\x201.049-1.066l.08.078\x206.442\x207.354\x206.428-7.354z\x22/></svg>\x0a'}),_0x1ab82e['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x136402['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x1ab82e['on']('execute',()=>this['fire']('execute','backward')),_0x136402['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',_0x394588['if']('_isStatusLabelVisible','ck-hidden',_0x1791be=>!_0x1791be)]},'children':[{'text':_0x394588['to']('isNavigationMode',_0x41314b=>_0x41314b?m(_0x86132c,'EDIT_X_OF_Y_REVISIONS')+':\x20':m(_0x86132c,'Total')+':\x20')}]},{'text':_0x394588['to']('_statusText')}]},new _0x492e02(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x1ab82e,_0x136402]}]});}}const ce='ck-editor__editable__loading-overlay';class le extends _0x38c4e4{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x42da06=this['editor']['editing']['view'];_0x42da06['change'](_0x4465e4=>{for(const _0x266c21 of _0x42da06['document']['roots'])_0x4465e4['addClass'](ce,_0x266c21);});}['hide'](){const _0x4cfb2a=this['editor']['editing']['view'];_0x4cfb2a['change'](_0x20799f=>{for(const _0x2203c6 of _0x4cfb2a['document']['roots'])_0x20799f['removeClass'](ce,_0x2203c6);});}}class g extends _0x38c4e4{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[d,le];}['init'](){const _0x7615e3=this['editor'],_0x1016e0=_0x7615e3['plugins']['get'](d),_0x400541=_0x7615e3['plugins']['get'](le);_0x7615e3['ui']['componentFactory']['add']('exitToEditing',_0x21d007=>{const _0xf0c93b=new _0x13b3b7(_0x21d007);return _0xf0c93b['set']({'label':m(_0x21d007,'Back\x20to\x20editing'),'icon':_0x226c5d['undo'],'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0xf0c93b,'execute',()=>{_0x7615e3['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0xf0c93b;}),_0x7615e3['ui']['componentFactory']['add']('restoreRevision',_0x3d7817=>{const _0xcd2edf=new _0x13b3b7(_0x3d7817);return _0xcd2edf['set']({'label':m(_0x3d7817,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0xcd2edf['bind']('isEnabled')['to'](_0x7615e3['commands']['get']('restoreRevision')),this['listenTo'](_0xcd2edf,'execute',()=>_0x7615e3['execute']('restoreRevision')),_0xcd2edf;}),_0x7615e3['ui']['componentFactory']['add']('changesNavigation',_0x67437e=>{const _0x4f5c4b=new _i(_0x67437e),_0x53bc1d=_0x7615e3['commands']['get']('showPreviousChange'),_0x15e105=_0x7615e3['commands']['get']('showNextChange');return _0x4f5c4b['bind']('isBackwardNavigationEnabled')['to'](_0x53bc1d,'isEnabled'),_0x4f5c4b['bind']('isForwardNavigationEnabled')['to'](_0x15e105,'isEnabled'),_0x4f5c4b['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x1016e0),this['listenTo'](_0x4f5c4b,'execute',(_0x3caeab,_0x533e3c)=>{_0x7615e3['execute']('forward'===_0x533e3c?'showNextChange':'showPreviousChange');}),_0x4f5c4b;}),_0x400541['show'](),_0x1016e0['on']('change:isReady',(_0x50effd,_0x1ce11a,_0x2228e2)=>{_0x2228e2?_0x400541['hide']():_0x400541['show']();});}}class pt extends nt{['_resizeObserver']=null;constructor(_0x2bdb58,_0x2761b7){super(_0x2bdb58,_0x2761b7);const _0x4fc9d5=this['bindTemplate'];this['set']({'label':m(_0x2bdb58,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=m(_0x2bdb58,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x4fc9d5['to']('_tooltipString'),'data-cke-tooltip-position':'s','data-cke-tooltip-class':'ck-tooltip_multi-line'}});}['render'](){super['render'](),this['_resizeObserver']=new at(this['fieldView']['element'],()=>this['_updateTooltipText']()),this['listenTo'](this['fieldView'],'input',()=>this['_updateTooltipText']());}['destroy'](){super['destroy'](),this['_resizeObserver']&&this['_resizeObserver']['destroy']();}['_updateTooltipText'](){const _0x476eac=this['fieldView']['element'];this['_tooltipString']=_0x476eac['scrollWidth']>_0x476eac['clientWidth']&&_0x476eac['value']||'';}}class ti extends _0x3f0f05{constructor(_0x21a6c4,_0x5d23c4,_0x29f12b){super(_0x21a6c4);const _0x2073c8=new _0x5787b7();_0x2073c8['set']({'content':'<svg\x20viewBox=\x220\x200\x2011\x2010\x22\x20xmlns=\x22http://www.w3.org/2000/svg\x22\x20xmlns:xlink=\x22http://www.w3.org/1999/xlink\x22><path\x20d=\x22M5.5\x205C8.538\x205\x2011\x207.015\x2011\x209.5c0\x20.17-.011.336-.034.5H.034A3.732\x203.732\x200\x200\x201\x200\x209.5C0\x207.015\x202.462\x205\x205.5\x205zm0-5a2.5\x202.5\x200\x201\x201\x200\x205\x202.5\x202.5\x200\x200\x201\x200-5z\x22\x20/></svg>\x0a','viewBox':'0\x200\x2011\x2010'});const _0x375331=['ck','ck-revision-history-sidebar__revision-author'];_0x29f12b&&_0x375331['push']('ck-revision-history-sidebar__revision-author_creator');const _0x457697=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':m(_0x21a6c4,_0x29f12b?'Revision\x20creator':'Revision\x20author')},'children':[_0x2073c8,_0x5d23c4['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x375331},'children':_0x457697});}}function ni(_0x306b2d,_0x59aed1){const _0x4a6ac0=_0x306b2d['bindTemplate'],_0x36239a=_0x306b2d['locale'],_0x1f1572=_0x2a9d1c(_0x36239a);_0x1f1572['panelPosition']='sw';const _0x544f56=function(_0x485da1,_0x5e759d){const _0x364696=function(_0x52b801,_0x58d1eb){const _0x12fa27=_0x52b801['locale'],_0x4c304a={'Compare\x20against\x20selected':m(_0x12fa27,'Compare\x20against\x20selected'),'Name\x20this\x20revision':m(_0x12fa27,'Name\x20this\x20revision'),'Restore\x20this\x20revision':m(_0x12fa27,'Restore\x20this\x20revision')};return _0x58d1eb['map'](_0x51834a=>{const _0x5339e4=_0x4c304a[_0x51834a['name']];return _0x5339e4&&_0x5339e4!==_0x51834a['name']&&(_0x51834a['name']=_0x5339e4),_0x51834a;});}(_0x485da1,_0x5e759d),_0x4cadae=new _0x42ce0a();for(const _0x59c912 of _0x364696){const _0x565eb8={'type':'button','model':new to({'label':_0x59c912['name'],'class':_0x59c912['class'],'withText':!0x0,'role':'menuitem','_action':_0x59c912['action']})};_0x565eb8['model']['bind']('isEnabled')['to'](_0x485da1,'isActionsDropdownOpen',_0x76b8eb=>'function'!=typeof _0x59c912['isEnabled']||(!_0x76b8eb||_0x59c912['isEnabled'](_0x485da1))),_0x4cadae['add'](_0x565eb8);}return _0x4cadae;}(_0x306b2d,_0x59aed1);return _0x306b2d['bind']('isActionsDropdownOpen')['to'](_0x1f1572,'isOpen'),_0x1f1572['buttonView']['set']({'label':m(_0x36239a,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x226c5d['threeVerticalDots']}),_0x1f1572['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x4a6ac0['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x4a6ac0['to'](_0x32b930=>_0x32b930['stopPropagation']())}}),_0x1f1572['on']('execute',_0x1d47f5=>{_0x306b2d['isReady']&&'function'==typeof _0x1d47f5['source']['_action']&&_0x1d47f5['source']['_action'](_0x306b2d);}),_0x546d70(_0x1f1572,_0x544f56,{'role':'menu'}),_0x1f1572['listenTo'](_0x306b2d,'change:isActionsDropdownOpen',(_0x30b700,_0x13b305,_0x515cec)=>{if(_0x515cec)for(const _0x5df475 of _0x1f1572['listView']['items']){const _0x4fb66a=_0x5df475['children']['first'],_0x2c63cf=_0x59aed1['find'](_0x556c9c=>_0x556c9c['action']===_0x4fb66a['_action'])['isVisible'];_0x5df475['isVisible']=void 0x0===_0x2c63cf||_0x2c63cf(_0x306b2d);}}),_0x1f1572;}class ai extends/* #__PURE__ -- @preserve */
|
|
26
|
+
_0x43bb9d(_0x3f0f05){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x427e53,_0x1258f4,_0xe6d299,_0x3db52b){super(_0x427e53);const _0x5b62f4=this['bindTemplate'],_0x4abbed=function(_0x410755,_0x36badc){const _0x4a7980=Array['from'](_0x36badc['authors'])['filter'](_0x3fe7f6=>_0x3fe7f6!=_0x36badc['creator']);return _0x36badc['creator']&&_0x4a7980['unshift'](_0x36badc['creator']),_0x4a7980['map'](_0x3e74c8=>new ti(_0x410755,_0x3e74c8,_0x3e74c8==_0x36badc['creator']));}(_0x427e53,_0x1258f4);this['id']=_0x1258f4['id'],this['_revision']=_0x1258f4,this['_requireRevisionName']=_0x3db52b,this['bind']('name','createdAt')['to'](_0x1258f4),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0xcdfebb=>{return _0xc5a685=_0x427e53['uiLanguage'],(_0x324317=_0xcdfebb)['toLocaleDateString'](_0xc5a685,{'month':'long','day':'numeric'})+',\x20'+_0x324317['toLocaleTimeString'](_0xc5a685,{'hour':'numeric','minute':'numeric'});var _0xc5a685,_0x324317;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new pt(_0x427e53,_0x1d572c),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x3c0f3d=>_0x3c0f3d||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x1187bd,_0x933d9)=>_0x1187bd&&_0x933d9),this['revisionActionsView']=_0xe6d299&&_0xe6d299['length']?ni(this,_0xe6d299):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x5b62f4['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x5b62f4['if']('isEnabled','ck-disabled',_0x541858=>!_0x541858),_0x5b62f4['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x5b62f4['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x5b62f4['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':_0x5b62f4['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':_0x4abbed}]},this['revisionActionsView']],'on':{'click':_0x5b62f4['to'](_0x1e57e0=>{_0x1e57e0['srcElement']['closest']('.ck-thread__remove-confirm')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x4cb107=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x4cb107,'change',()=>{this['_requireRevisionName']&&!_0x4cb107['value']||this['fire']('setName',{'id':this['id'],'name':_0x4cb107['value']}),_0x4cb107['value']||(_0x4cb107['value']=this['name']?this['name']:this['_createdAtFormatted']);});}['select'](){this['isSelected']=!0x0;}['deselect'](){this['isSelected']=!0x1;}['highlight'](){this['isHighlighted']=!0x0;}['unhighlight'](){this['isHighlighted']=!0x1;}}function di(_0x4384a6,_0x3d2657){const _0x1fcd20=_0x446d2f['fromJSDate'](_0x4384a6)['setLocale'](_0x3d2657),_0x5bb0fc=_0x446d2f['local'](),_0x454769=_0x5bb0fc['minus']({'days':0x1})['startOf']('day');let _0x3fcc2f,_0x1b0563;return _0x1fcd20['hasSame'](_0x5bb0fc,'day')?(_0x3fcc2f=_0x1fcd20['startOf']('day')['toJSDate'](),_0x1b0563=_0x1fcd20['toRelativeCalendar']()):_0x1fcd20['hasSame'](_0x454769,'day')?(_0x3fcc2f=_0x454769['toJSDate'](),_0x1b0563=_0x1fcd20['toRelativeCalendar']()):_0x1fcd20['hasSame'](_0x5bb0fc,'week')?(_0x3fcc2f=_0x1fcd20['startOf']('week')['toJSDate'](),_0x1b0563=_0x1fcd20['weekdayLong']||''):_0x1fcd20['hasSame'](_0x5bb0fc,'year')?(_0x3fcc2f=_0x1fcd20['startOf']('month')['toJSDate'](),_0x1b0563=_0x1fcd20['monthLong']||''):(_0x3fcc2f=_0x1fcd20['startOf']('year')['toJSDate'](),_0x1b0563=String(_0x1fcd20['year'])),{'startDate':_0x3fcc2f,'localizedPeriodName':_0x1b0563};}class mi extends _0x3f0f05{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x41fd02,_0x7f8174,_0x1dbb30,_0x5ec5a2){super(_0x41fd02);const _0x5eda58=di(_0x7f8174,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x7f8174,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x1dbb30,this['_requireRevisionName']=_0x5ec5a2,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':_0x5eda58}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x3ad299){const _0x2e3645=new ai(this['locale'],_0x3ad299,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x2e3645);}['removeRevision'](_0x1b42c0){const _0x16da14=this['revisionViews']['find'](_0x3eb6c1=>_0x3eb6c1['id']===_0x1b42c0['id']);this['revisionViews']['remove'](_0x16da14);}}class as extends _0x3f0f05{constructor(_0x1a03de){super(_0x1a03de);const _0x1fb0e8=new _0x5787b7();_0x1fb0e8['content']=_0x226c5d['history'],this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x1fb0e8,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[m(_0x1a03de,'Revision\x20history')]}]});}}class ci extends _0x3f0f05{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x10df9f,_0x184ee8,_0x519318,_0x5ee44b){super(_0x10df9f);const _0x364cca=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x184ee8,this['_revisionActions']=_0x519318,this['_requireRevisionName']=_0x5ee44b,this['on']('select',(_0x3cfb1a,_0x4194fd)=>{this['fire']('revisionSelected',_0x4194fd);}),this['on']('setName',(_0x42b36a,_0x1bcf87)=>{this['fire']('revisionSetName',_0x1bcf87);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new as(_0x10df9f),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x364cca['if']('isEnabled','ck-disabled',_0x51869e=>!_0x51869e)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x3d3d50 of this['_revisions'])this['_addRevision'](_0x3d3d50);this['_revisions']['on']('add',(_0x553555,_0x29c8a1)=>{this['_addRevision'](_0x29c8a1);}),this['_revisions']['on']('remove',(_0x4135cc,_0x250af2)=>{this['_removeRevision'](_0x250af2);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x5b5cad=>_0x5b5cad['revisionViews']['map'](_0x328963=>_0x328963))['flat']();}['selectRevision'](_0x2bc996){for(const _0x37cc57 of this['revisionViews'])_0x2bc996&&_0x2bc996['id']===_0x37cc57['id']?_0x37cc57['select']():_0x37cc57['deselect']();}['highlightRevisions'](_0x3bf857){for(const _0x1a8c20 of this['revisionViews'])_0x3bf857['some'](({id:_0x2ae1ca})=>_0x2ae1ca===_0x1a8c20['id'])?_0x1a8c20['highlight']():_0x1a8c20['unhighlight']();}['_addRevision'](_0x2c4afa){const _0x1b1a1e=di(_0x2c4afa['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x4def4d=this['timePeriodViews']['get'](0x0);_0x4def4d&&_0x4def4d['startDate']['getTime']()===_0x1b1a1e['getTime']()||(_0x4def4d=new mi(this['locale'],_0x1b1a1e,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x4def4d)),_0x4def4d['addRevision'](_0x2c4afa);}['_removeRevision'](_0x410c09){const _0x4c1092=di(_0x410c09['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x4c1092)['removeRevision'](_0x410c09);}['_getTimePeriodViewByStartDate'](_0x33c4d3){return this['timePeriodViews']['find'](_0x49da4c=>_0x49da4c['startDate']['getTime']()===_0x33c4d3['getTime']());}}class w extends _0x38c4e4{['_revisionViewer'];['_revisionsRepository'];['_sidebarView'];static ['defaultRevisionActions']=/* #__PURE__ -- @preserve */
|
|
27
27
|
((()=>['compareAgainstSelected','restoreRevision','nameRevision'])());static ['availableRevisionActions']=/* #__PURE__ -- @preserve */
|
|
28
|
-
|
|
29
|
-
it(tt){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x3ece45,_0x87d10d){super(_0x87d10d),this['sourceElement']=_0x3ece45,this['model']['document']['createRoot']();const _0x407948=new et(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new rt(this,_0x407948);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x59f837,_0xc41b1e){const _0x4e37fc=new this(_0x59f837,_0xc41b1e);return await _0x4e37fc['initPlugins'](),await _0x4e37fc['ui']['init'](_0x59f837),await _0x4e37fc['data']['init'](_0x4e37fc['config']['get']('initialData')||''),_0x4e37fc['fire']('ready'),_0x4e37fc;}}const p=['RevisionHistoryUI','RestrictedEditingMode'];class bt extends _0x5517c8{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x3d9bc7){function _0x231b3d(_0x12e2bd){return _0x12e2bd['map'](_0x42abc7=>String['fromCharCode'](_0x42abc7))['join']('');}super(_0x3d9bc7),this['result']='end',_0x3d9bc7[_0x231b3d([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x231b3d([0x76,0x69,0x65,0x77])][_0x231b3d([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x231b3d([0x61,0x75,0x74,0x6f]),_0x3d9bc7[_0x231b3d([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x231b3d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x231b3d([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x231b3d([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x231b3d([0x6f,0x6b])});}}class k extends _0x5517c8{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u,f];}constructor(_0x375f67){if(super(_0x375f67),!this['editor']['config']['get']('revisionHistory'))throw new _0x1d0ae3('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x38b628=>this['_showRevisionViewer']({..._0x38b628,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x5e3751=>this['_closeRevisionViewer'](_0x5e3751)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x398708=>this['_restoreRevision'](_0x398708)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x119f15){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x119f15;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x56d0d0){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x56d0d0);}['getRevision'](_0x1b41f7){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x1b41f7);}['getRevisions'](_0x55bb4a){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x55bb4a||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x1d70a2=this['editor'],_0x9d5776=_0x8852d7(_0x1d70a2,p),_0x3e5fc8=_0x1d70a2['plugins']['get']('RevisionTracker'),_0x1d7442=_0x1d70a2['plugins']['get']('Users')['users'];return _0x9d5776['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x9d5776['lazyRoots'],(_0x9d5776['plugins']['push'](bt,d,w,class extends _0x5517c8{static get['requires'](){return[d,'Users'];}['init'](){const _0x28dbf3=this['editor']['plugins']['get']('Users');for(const _0x33ae05 of _0x1d7442)_0x33ae05['isAnonymous']||_0x28dbf3['getUser'](_0x33ae05['id'])||_0x28dbf3['addUser'](_0x33ae05);const _0x4c6c17=_0x3e5fc8['repository']['getRevisions']();let _0x5cc366=null;const _0x27ef54=this['editor']['plugins']['get']('RevisionViewer');_0x27ef54['adapter']=_0x3e5fc8['adapter'],_0x27ef54['bind']('isEnabled')['to'](_0x3e5fc8),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x1d70a2,'isReadOnly',_0x11aa89=>!_0x11aa89);for(const _0x5de5e5 of _0x4c6c17){const _0x399275=null===_0x5de5e5['creator'];if(_0x399275&&_0x5de5e5['toVersion']===_0x5de5e5['fromVersion'])continue;const _0x51d9c5=_0x5de5e5['toJSON']();_0x27ef54['addRevisionData'](_0x51d9c5,(_0x52aea4,_0x3e6104,_0x2e9289)=>{if(_0x399275){if(_0x5cc366)_0x5cc366['_update'](_0x52aea4,_0x3e6104);else{if(!_0x3e6104){const _0x101920=_0x2e9289['toJSON']();_0x101920['id']=_0x3aad70(),_0x3e5fc8['saveRevision'](_0x101920,_0x2e9289['toVersion'])['then'](_0x1843fc=>{_0x5cc366=_0x1843fc;});}}}else _0x5de5e5['_update'](_0x52aea4,_0x3e6104);});}}},g),_0x9d5776);}['_enhanceShowRevisionViewerCallback'](){const _0x56ff3f=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x5d03b2=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x41493d=this['editor']['plugins']['get']('Autosave');await _0x41493d['save']();}else await _0x5d03b2['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x385178=this['editor']['plugins']['get']('Dialog');_0x385178['isOpen']&&_0x385178['hide']();}const _0x149e8f=this['_getRevisionViewerEditorConfig']();return _0x56ff3f(_0x149e8f)['then'](_0x1a3ed6=>{return(this['_viewerEditor']=_0x1a3ed6,this['editor']['plugins']['has']('Annotations'))&&this['editor']['plugins']['get']('Annotations')['refreshVisibility'](),_0x1a3ed6;})['catch'](_0x5714b0=>(console['error'](_0x5714b0),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x3d571e=this['editor']['config']['get']('revisionHistory')['closeRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.closeRevisionViewerCallback',()=>(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['_viewerEditor']['plugins']['get']('RevisionViewer')['_cleanUp'](),_0x3d571e(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x7b86ec=this['editor']['plugins']['get']('Annotations');_0x7b86ec['refreshVisibility'](),_0x7b86ec['refreshPositioning']();}})));}['_showRevisionViewer'](_0x6d2af4){const _0xde370d=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x5ce90f=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0xefa72b=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return R['create'](_0xefa72b,_0x6d2af4)['then'](_0x12dc16=>(_0x5ce90f['style']['display']='block',_0xde370d['style']['display']='none',_0x12dc16));}['_closeRevisionViewer'](_0xb76ee1){const _0xe1f80b=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0xe1f80b['style']['display']='',_0xb76ee1['destroy']();}async['_restoreRevision'](_0x4db5e1){const _0x468aaf=this['editor'],_0x2643ac=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x4fd3ac=_0x468aaf['plugins']['get']('RevisionTracker'),_0xecde14=_0x2643ac['repository']['getRevision'](_0x4db5e1);let _0x1308ee,_0xafff6c,_0x3e4a70;try{_0x1308ee=await _0x2643ac['getRevisionData'](_0xecde14),_0xafff6c=await _0x2643ac['getRevisionRootsAttributes'](_0xecde14);}catch(_0x458d4b){return void console['error'](_0x458d4b);}_0x468aaf['model']['change'](_0x33e125=>{for(const _0x415598 of Array['from'](_0x468aaf['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x33e125['removeMarker'](_0x415598);}),_0x2643ac['isReady']=!0x1,_0x468aaf['model']['enqueueChange'](_0x8ba8be=>{_0x8ba8be['setSelection'](null),_0x8ba8be['removeSelectionAttribute'](_0x468aaf['model']['document']['selection']['getAttributeKeys']());const _0x16a51c=Object['keys'](_0x1308ee);for(const _0x35808a of _0x468aaf['model']['document']['roots'])'$graveyard'!=_0x35808a['rootName']&&_0x35808a['isAttached']()&&!_0x16a51c['includes'](_0x35808a['rootName'])&&_0x8ba8be['detachRoot'](_0x35808a);for(const _0x419ab9 of _0x16a51c){let _0x5a0529=_0x468aaf['model']['document']['getRoot'](_0x419ab9);_0x5a0529&&_0x5a0529['isAttached']()||(_0x5a0529=_0x8ba8be['addRoot'](_0x419ab9));const _0x431008=_0xafff6c[_0x419ab9],_0x38fe7b=Object['keys'](_0x431008),_0x263987=_0x1308ee[_0x419ab9];for(const _0xe8961d of _0x5a0529['getAttributeKeys']())_0x38fe7b['includes'](_0xe8961d)||_0x8ba8be['removeAttribute'](_0xe8961d,_0x5a0529);for(const _0x5a8706 of _0x38fe7b)_0x8ba8be['setAttribute'](_0x5a8706,_0xafff6c[_0x419ab9][_0x5a8706],_0x5a0529);_0x8ba8be['remove'](_0x8ba8be['createRangeIn'](_0x5a0529)),_0x8ba8be['insert'](_0x468aaf['data']['parse'](_0x263987,_0x5a0529),_0x5a0529,0x0);}});const _0xc8ffbf=m(_0x468aaf['locale'],'Restored');if(_0xecde14['name'])_0x3e4a70=-0x1==_0xecde14['name']['indexOf'](_0xc8ffbf)?_0xc8ffbf+':\x20'+_0xecde14['name']:_0xecde14['name'];else _0x3e4a70=_0xc8ffbf+':\x20'+(_0xecde14['createdAt']['toLocaleDateString'](_0x468aaf['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0xecde14['createdAt']['toLocaleTimeString'](_0x468aaf['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x4fd3ac['saveRevision']({'name':_0x3e4a70}),_0x2643ac['isReady']=!0x0,_0x468aaf['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{h as Revision,k as RevisionHistory,f as RevisionHistoryUI,u as RevisionTracker,d as RevisionViewer,ge as RevisionViewerLoadingOverlay,w as RevisionViewerUI,j as RevisionsRepository,g as RevisionsSidebar};
|
|
28
|
+
bt();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[d];}constructor(_0x433838){super(_0x433838),this['_revisionViewer']=_0x433838['plugins']['get'](d),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0xce4d35=this['_revisionsRepository']['_revisions'],_0x138638=this['_createRevisionActions'](),_0x163f8c=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new ci(this['editor']['locale'],_0xce4d35,_0x138638,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',(_0x4bdb92,_0xf42c8e)=>{_0xf42c8e['revisionViews']['on']('add',(_0x498622,_0x2b57d5)=>{_0x2b57d5['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)),_0x163f8c['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x53ef9f=this['_revisionsRepository']['getRevision'](0x0);if(_0x53ef9f){const _0xfe237f=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x53ef9f['id']);this['_revisionViewer']['compare'](_0x53ef9f,_0xfe237f);}}['_handleRevisionSelected'](_0x42447c,_0x23e179){const _0x2d027=this['_revisionsRepository']['getRevision'](_0x23e179['id']),_0x20cfd0=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x2d027['id']);this['_revisionViewer']['compare'](_0x2d027,_0x20cfd0);}['_handleRevisionSetName'](_0x28ef15,_0x24f3d1){this['_revisionsRepository']['getRevision'](_0x24f3d1['id'])['setName'](_0x24f3d1['name']);}['_handleDiffChange'](_0xcffee6,_0x488388,_0x2d4616){const _0x1d526d=this['_revisionsRepository']['getRevisionsInDiff'](_0x2d4616);_0x1d526d['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x1d526d),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x1d526d[0x0]));}['_createRevisionActions'](){const _0x35e80f=this['editor'],_0x4832a7=w['availableRevisionActions'],_0x6b7d78=_0x35e80f['config']['get']('revisionHistory.revisionActions')||w['defaultRevisionActions'];if(_0x6b7d78['length'])return _0x6b7d78['map'](_0x59a390=>{const _0x54ca8c='string'==typeof _0x59a390?Object['assign']({},_0x4832a7[_0x59a390]):_0x59a390;return _0x54ca8c['action']=_0x54ca8c['action']['bind'](this,_0x35e80f),_0x54ca8c['isVisible']&&(_0x54ca8c['isVisible']=_0x54ca8c['isVisible']['bind'](this,_0x35e80f)),_0x54ca8c;});}}function bt(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0xe599c3},_0x76ae16)=>{const _0x258a54=_0xe599c3['get'](d),_0x2ceb68=_0x258a54['repository'];let _0x2d7e05=_0x258a54['diff']['newRevisionId'],_0x47cd46=_0x76ae16['id'];_0x2ceb68['getIndex'](_0x2d7e05)>_0x2ceb68['getIndex'](_0x47cd46)&&([_0x2d7e05,_0x47cd46]=[_0x47cd46,_0x2d7e05]),_0x258a54['compare'](_0x2d7e05,_0x47cd46);},'isVisible':({plugins:_0x4f4d3b},_0x39f0f6)=>{const _0xf3c317=_0x4f4d3b['get'](d);return!(_0xf3c317['repository']['getRevisionsInDiff'](_0xf3c317['diff'])['length']>0x2)&&!_0x39f0f6['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x4bebd2,{id:_0x1155c3})=>{_0x4bebd2['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x1155c3);},'isVisible':({plugins:_0x322942},_0x5f3d5e)=>!!_0x322942['get'](d)['repository']['getLaterVisibleRevision'](_0x5f3d5e['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x546997},{id:_0x4351ae,revisionNameView:_0x1c2352})=>{const _0x379cba=_0x546997['get'](d),_0x528ceb=_0x379cba['repository']['getEarlierVisibleRevision'](_0x4351ae);_0x379cba['compare'](_0x4351ae,_0x528ceb),_0x1c2352['focus'](),_0x1c2352['fieldView']['select']();}}};}class rt extends st{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0xc1b732,_0x3569b7){super(_0xc1b732),this['_view']=_0x3569b7,this['_toolbarConfig']=ot(_0xc1b732['config']['get']('toolbar')),this['_elementReplacer']=new ht();}get['element'](){return this['view']['element'];}['init'](_0xdd5de1){const _0x509da1=this['editor'],_0x1b3d1a=this['view'],_0x2fb247=_0x509da1['editing']['view'],_0x4c27de=_0x1b3d1a['editable'],_0x54f4f1=_0x2fb247['document']['getRoot']();_0x4c27de['name']=_0x54f4f1['rootName'],_0x1b3d1a['render']();const _0x3d55f6=_0x4c27de['element'];this['setEditableElement'](_0x4c27de['name'],_0x3d55f6),_0x1b3d1a['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x2fb247['attachDomRoot'](_0x3d55f6),this['_elementReplacer']['replace'](_0xdd5de1,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x321698=this['view'],_0x1595a9=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x1595a9['detachDomRoot'](_0x321698['editable']['name']),_0x321698['destroy']();}['_initToolbar'](){const _0x258a7d=this['view'];_0x258a7d['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x258a7d['stickyPanel']['limiterElement']=_0x258a7d['element'],_0x258a7d['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x24822d})=>_0x24822d),_0x258a7d['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x258a7d['toolbar']);}}class et extends ct{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x5cd3bc,_0xe49e81,_0x416e69={}){super(_0x5cd3bc),this['stickyPanel']=new ut(_0x5cd3bc),this['toolbar']=new lt(_0x5cd3bc,{'shouldGroupWhenFull':_0x416e69['shouldToolbarGroupWhenFull']}),this['_editable']=new dt(_0x5cd3bc,_0xe49e81);}['render'](){super['render'](),this['stickyPanel']['content']['add'](this['toolbar']),this['top']['add'](this['stickyPanel']),this['main']['add'](this['editable']);}}class R extends/* #__PURE__ -- @preserve */
|
|
29
|
+
it(tt){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x4d3c96,_0x2aaa54){super(_0x2aaa54),this['sourceElement']=_0x4d3c96,this['model']['document']['createRoot']();const _0x4ec558=new et(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new rt(this,_0x4ec558);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x449537,_0x3d8445){const _0x3ad8c7=new this(_0x449537,_0x3d8445);return await _0x3ad8c7['initPlugins'](),await _0x3ad8c7['ui']['init'](_0x449537),await _0x3ad8c7['data']['init'](_0x3ad8c7['config']['get']('initialData')||''),_0x3ad8c7['fire']('ready'),_0x3ad8c7;}}const p=['RevisionHistoryUI','RestrictedEditingMode'];class Rt extends _0x38c4e4{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x8c1934){function _0x3a70f3(_0x5cdf98){return _0x5cdf98['map'](_0x57fe89=>String['fromCharCode'](_0x57fe89))['join']('');}super(_0x8c1934),this['result']='end',_0x8c1934[_0x3a70f3([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x3a70f3([0x76,0x69,0x65,0x77])][_0x3a70f3([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x3a70f3([0x61,0x75,0x74,0x6f]),_0x8c1934[_0x3a70f3([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x3a70f3([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x3a70f3([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x3a70f3([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x3a70f3([0x6f,0x6b])});}}class k extends _0x38c4e4{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l,u];}constructor(_0x5757b0){if(super(_0x5757b0),!this['editor']['config']['get']('revisionHistory'))throw new _0x5f4f1d('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x211ea8=>this['_showRevisionViewer']({..._0x211ea8,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x227a1b=>this['_closeRevisionViewer'](_0x227a1b)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x56f289=>this['_restoreRevision'](_0x56f289)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x522f66){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x522f66;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0xc7736d){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0xc7736d);}['getRevision'](_0x2a767a){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x2a767a);}['getRevisions'](_0x15b278){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x15b278||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x35f659=this['editor'],_0x33149a=_0x1e169a(_0x35f659,p),_0x3b99f7=_0x35f659['plugins']['get']('RevisionTracker'),_0x40670e=_0x35f659['plugins']['get']('Users')['users'];return _0x33149a['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x33149a['lazyRoots'],(_0x33149a['plugins']['push'](Rt,d,g,class extends _0x38c4e4{static get['requires'](){return[d,'Users'];}['init'](){const _0x5d1f2e=this['editor']['plugins']['get']('Users');for(const _0x1ae7ff of _0x40670e)_0x1ae7ff['isAnonymous']||_0x5d1f2e['getUser'](_0x1ae7ff['id'])||_0x5d1f2e['addUser'](_0x1ae7ff);const _0x1485c2=_0x3b99f7['repository']['getRevisions']();let _0x30d3ba=null;const _0x3e5587=this['editor']['plugins']['get']('RevisionViewer');_0x3e5587['adapter']=_0x3b99f7['adapter'],_0x3e5587['bind']('isEnabled')['to'](_0x3b99f7),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x35f659,'isReadOnly',_0x2e6b38=>!_0x2e6b38);for(const _0x40b71e of _0x1485c2){const _0xa28a40=null===_0x40b71e['creator'];if(_0xa28a40&&_0x40b71e['toVersion']===_0x40b71e['fromVersion'])continue;const _0x14882b=_0x40b71e['toJSON']();_0x3e5587['addRevisionData'](_0x14882b,(_0x750814,_0x310efa,_0x232083)=>{if(_0xa28a40){if(_0x30d3ba)_0x30d3ba['_update'](_0x750814,_0x310efa);else{if(!_0x310efa){const _0x483a73=_0x232083['toJSON']();_0x483a73['id']=_0x358749(),_0x3b99f7['saveRevision'](_0x483a73,_0x232083['toVersion'])['then'](_0x11bd28=>{_0x30d3ba=_0x11bd28;});}}}else _0x40b71e['_update'](_0x750814,_0x310efa);});}}},w),_0x33149a);}['_enhanceShowRevisionViewerCallback'](){const _0xd02b09=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0xf053cd=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x17a3eb=this['editor']['plugins']['get']('Autosave');await _0x17a3eb['save']();}else await _0xf053cd['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x4d7282=this['editor']['plugins']['get']('Dialog');_0x4d7282['isOpen']&&_0x4d7282['hide']();}const _0x187b21=this['_getRevisionViewerEditorConfig']();return _0xd02b09(_0x187b21)['then'](_0x16cc68=>{return(this['_viewerEditor']=_0x16cc68,this['editor']['plugins']['has']('Annotations'))&&this['editor']['plugins']['get']('Annotations')['refreshVisibility'](),_0x16cc68;})['catch'](_0x10832b=>(console['error'](_0x10832b),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x55d3cf=this['editor']['config']['get']('revisionHistory')['closeRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.closeRevisionViewerCallback',()=>(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['_viewerEditor']['plugins']['get']('RevisionViewer')['_cleanUp'](),_0x55d3cf(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x27b26f=this['editor']['plugins']['get']('Annotations');_0x27b26f['refreshVisibility'](),_0x27b26f['refreshPositioning']();}})));}['_showRevisionViewer'](_0x3bc640){const _0x2576c5=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x202005=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x2dcc0d=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return R['create'](_0x2dcc0d,_0x3bc640)['then'](_0x3c5d40=>(_0x202005['style']['display']='block',_0x2576c5['style']['display']='none',_0x3c5d40));}['_closeRevisionViewer'](_0x988651){const _0x57b6b=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x57b6b['style']['display']='',_0x988651['destroy']();}async['_restoreRevision'](_0x2f6659){const _0x234e85=this['editor'],_0x5a508d=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x1651d5=_0x234e85['plugins']['get']('RevisionTracker'),_0x321a2a=_0x5a508d['repository']['getRevision'](_0x2f6659);let _0x522d6a,_0x24fcef,_0x185d4d;try{_0x522d6a=await _0x5a508d['getRevisionData'](_0x321a2a),_0x24fcef=await _0x5a508d['getRevisionRootsAttributes'](_0x321a2a);}catch(_0x278d79){return void console['error'](_0x278d79);}_0x234e85['model']['change'](_0x240c9d=>{for(const _0x499b04 of Array['from'](_0x234e85['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x240c9d['removeMarker'](_0x499b04);}),_0x5a508d['isReady']=!0x1,_0x234e85['model']['enqueueChange'](_0x4d5b29=>{_0x4d5b29['setSelection'](null),_0x4d5b29['removeSelectionAttribute'](_0x234e85['model']['document']['selection']['getAttributeKeys']());const _0x3e5093=Object['keys'](_0x522d6a);for(const _0x1ce743 of _0x234e85['model']['document']['roots'])'$graveyard'!=_0x1ce743['rootName']&&_0x1ce743['isAttached']()&&!_0x3e5093['includes'](_0x1ce743['rootName'])&&_0x4d5b29['detachRoot'](_0x1ce743);for(const _0x366226 of _0x3e5093){let _0x353172=_0x234e85['model']['document']['getRoot'](_0x366226);_0x353172&&_0x353172['isAttached']()||(_0x353172=_0x4d5b29['addRoot'](_0x366226));const _0x31429c=_0x24fcef[_0x366226],_0x3008ac=Object['keys'](_0x31429c),_0x2a7934=_0x522d6a[_0x366226];for(const _0x1bc5a3 of _0x353172['getAttributeKeys']())_0x3008ac['includes'](_0x1bc5a3)||_0x4d5b29['removeAttribute'](_0x1bc5a3,_0x353172);for(const _0x48973e of _0x3008ac)_0x4d5b29['setAttribute'](_0x48973e,_0x24fcef[_0x366226][_0x48973e],_0x353172);_0x4d5b29['remove'](_0x4d5b29['createRangeIn'](_0x353172)),_0x4d5b29['insert'](_0x234e85['data']['parse'](_0x2a7934,_0x353172),_0x353172,0x0);}});const _0x546452=m(_0x234e85['locale'],'Restored');if(_0x321a2a['name'])_0x185d4d=-0x1==_0x321a2a['name']['indexOf'](_0x546452)?_0x546452+':\x20'+_0x321a2a['name']:_0x321a2a['name'];else _0x185d4d=_0x546452+':\x20'+(_0x321a2a['createdAt']['toLocaleDateString'](_0x234e85['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x321a2a['createdAt']['toLocaleTimeString'](_0x234e85['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x1651d5['saveRevision']({'name':_0x185d4d}),_0x5a508d['isReady']=!0x0,_0x234e85['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{a as Revision,k as RevisionHistory,u as RevisionHistoryUI,l as RevisionTracker,d as RevisionViewer,le as RevisionViewerLoadingOverlay,g as RevisionViewerUI,j as RevisionsRepository,w as RevisionsSidebar};
|