@ckeditor/ckeditor5-revision-history 44.3.0-alpha.0 → 44.3.0-alpha.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/revision-history.js +1 -1
- package/dist/index.js +6 -6
- package/dist/translations/af.js +1 -1
- package/dist/translations/af.umd.js +1 -1
- package/dist/translations/ar.js +1 -1
- package/dist/translations/ar.umd.js +1 -1
- package/dist/translations/ast.js +1 -1
- package/dist/translations/ast.umd.js +1 -1
- package/dist/translations/az.js +1 -1
- package/dist/translations/az.umd.js +1 -1
- package/dist/translations/bg.js +1 -1
- package/dist/translations/bg.umd.js +1 -1
- package/dist/translations/bn.js +1 -1
- package/dist/translations/bn.umd.js +1 -1
- package/dist/translations/bs.js +1 -1
- package/dist/translations/bs.umd.js +1 -1
- package/dist/translations/ca.js +1 -1
- package/dist/translations/ca.umd.js +1 -1
- package/dist/translations/cs.js +1 -1
- package/dist/translations/cs.umd.js +1 -1
- package/dist/translations/da.js +1 -1
- package/dist/translations/da.umd.js +1 -1
- package/dist/translations/de-ch.js +1 -1
- package/dist/translations/de-ch.umd.js +1 -1
- package/dist/translations/de.js +1 -1
- package/dist/translations/de.umd.js +1 -1
- package/dist/translations/el.js +1 -1
- package/dist/translations/el.umd.js +1 -1
- package/dist/translations/en-au.js +1 -1
- package/dist/translations/en-au.umd.js +1 -1
- package/dist/translations/en-gb.js +1 -1
- package/dist/translations/en-gb.umd.js +1 -1
- package/dist/translations/en.js +1 -1
- package/dist/translations/en.umd.js +1 -1
- package/dist/translations/eo.js +1 -1
- package/dist/translations/eo.umd.js +1 -1
- package/dist/translations/es-co.js +1 -1
- package/dist/translations/es-co.umd.js +1 -1
- package/dist/translations/es.js +1 -1
- package/dist/translations/es.umd.js +1 -1
- package/dist/translations/et.js +1 -1
- package/dist/translations/et.umd.js +1 -1
- package/dist/translations/eu.js +1 -1
- package/dist/translations/eu.umd.js +1 -1
- package/dist/translations/fa.js +1 -1
- package/dist/translations/fa.umd.js +1 -1
- package/dist/translations/fi.js +1 -1
- package/dist/translations/fi.umd.js +1 -1
- package/dist/translations/fr.js +1 -1
- package/dist/translations/fr.umd.js +1 -1
- package/dist/translations/gl.js +1 -1
- package/dist/translations/gl.umd.js +1 -1
- package/dist/translations/gu.js +1 -1
- package/dist/translations/gu.umd.js +1 -1
- package/dist/translations/he.js +1 -1
- package/dist/translations/he.umd.js +1 -1
- package/dist/translations/hi.js +1 -1
- package/dist/translations/hi.umd.js +1 -1
- package/dist/translations/hr.js +1 -1
- package/dist/translations/hr.umd.js +1 -1
- package/dist/translations/hu.js +1 -1
- package/dist/translations/hu.umd.js +1 -1
- package/dist/translations/hy.js +1 -1
- package/dist/translations/hy.umd.js +1 -1
- package/dist/translations/id.js +1 -1
- package/dist/translations/id.umd.js +1 -1
- package/dist/translations/it.js +1 -1
- package/dist/translations/it.umd.js +1 -1
- package/dist/translations/ja.js +1 -1
- package/dist/translations/ja.umd.js +1 -1
- package/dist/translations/jv.js +1 -1
- package/dist/translations/jv.umd.js +1 -1
- package/dist/translations/kk.js +1 -1
- package/dist/translations/kk.umd.js +1 -1
- package/dist/translations/km.js +1 -1
- package/dist/translations/km.umd.js +1 -1
- package/dist/translations/kn.js +1 -1
- package/dist/translations/kn.umd.js +1 -1
- package/dist/translations/ko.js +1 -1
- package/dist/translations/ko.umd.js +1 -1
- package/dist/translations/ku.js +1 -1
- package/dist/translations/ku.umd.js +1 -1
- package/dist/translations/lt.js +1 -1
- package/dist/translations/lt.umd.js +1 -1
- package/dist/translations/lv.js +1 -1
- package/dist/translations/lv.umd.js +1 -1
- package/dist/translations/ms.js +1 -1
- package/dist/translations/ms.umd.js +1 -1
- package/dist/translations/nb.js +1 -1
- package/dist/translations/nb.umd.js +1 -1
- package/dist/translations/ne.js +1 -1
- package/dist/translations/ne.umd.js +1 -1
- package/dist/translations/nl.js +1 -1
- package/dist/translations/nl.umd.js +1 -1
- package/dist/translations/no.js +1 -1
- package/dist/translations/no.umd.js +1 -1
- package/dist/translations/oc.js +1 -1
- package/dist/translations/oc.umd.js +1 -1
- package/dist/translations/pl.js +1 -1
- package/dist/translations/pl.umd.js +1 -1
- package/dist/translations/pt-br.js +1 -1
- package/dist/translations/pt-br.umd.js +1 -1
- package/dist/translations/pt.js +1 -1
- package/dist/translations/pt.umd.js +1 -1
- package/dist/translations/ro.js +1 -1
- package/dist/translations/ro.umd.js +1 -1
- package/dist/translations/ru.js +1 -1
- package/dist/translations/ru.umd.js +1 -1
- package/dist/translations/si.js +1 -1
- package/dist/translations/si.umd.js +1 -1
- package/dist/translations/sk.js +1 -1
- package/dist/translations/sk.umd.js +1 -1
- package/dist/translations/sl.js +1 -1
- package/dist/translations/sl.umd.js +1 -1
- package/dist/translations/sq.js +1 -1
- package/dist/translations/sq.umd.js +1 -1
- package/dist/translations/sr-latn.js +1 -1
- package/dist/translations/sr-latn.umd.js +1 -1
- package/dist/translations/sr.js +1 -1
- package/dist/translations/sr.umd.js +1 -1
- package/dist/translations/sv.js +1 -1
- package/dist/translations/sv.umd.js +1 -1
- package/dist/translations/th.js +1 -1
- package/dist/translations/th.umd.js +1 -1
- package/dist/translations/ti.js +1 -1
- package/dist/translations/ti.umd.js +1 -1
- package/dist/translations/tk.js +1 -1
- package/dist/translations/tk.umd.js +1 -1
- package/dist/translations/tr.js +1 -1
- package/dist/translations/tr.umd.js +1 -1
- package/dist/translations/tt.js +1 -1
- package/dist/translations/tt.umd.js +1 -1
- package/dist/translations/ug.js +1 -1
- package/dist/translations/ug.umd.js +1 -1
- package/dist/translations/uk.js +1 -1
- package/dist/translations/uk.umd.js +1 -1
- package/dist/translations/ur.js +1 -1
- package/dist/translations/ur.umd.js +1 -1
- package/dist/translations/uz.js +1 -1
- package/dist/translations/uz.umd.js +1 -1
- package/dist/translations/vi.js +1 -1
- package/dist/translations/vi.umd.js +1 -1
- package/dist/translations/zh-cn.js +1 -1
- package/dist/translations/zh-cn.umd.js +1 -1
- package/dist/translations/zh.js +1 -1
- package/dist/translations/zh.umd.js +1 -1
- package/package.json +10 -10
- package/src/changeitem.js +2 -2
- package/src/editor/revisionviewereditor.js +2 -2
- package/src/editor/revisionviewereditorui.js +1 -1
- package/src/editor/revisionviewereditoruiview.js +1 -1
- package/src/index.js +1 -1
- package/src/revision.js +2 -2
- package/src/revisiondiff.js +1 -1
- package/src/revisionhistory.js +1 -1
- package/src/revisionsrepository.js +1 -1
- package/src/revisiontracker.js +1 -1
- package/src/revisionviewer.js +1 -1
- package/src/ui/revision/createrevisionactionsdropdown.js +1 -1
- package/src/ui/revision/revisionauthorview.js +1 -1
- package/src/ui/revision/revisionnameview.js +1 -1
- package/src/ui/revision/revisionview.js +2 -2
- package/src/ui/revision/subrevisioncollapserview.js +1 -1
- package/src/ui/revision/subrevisionview.js +1 -1
- package/src/ui/revision/utils.js +1 -1
- package/src/ui/revisionhistory/revisionhistorysaverevisionformview.js +1 -1
- package/src/ui/revisionhistory/revisionhistoryui.js +1 -1
- package/src/ui/revisionssidebar/revisionssidebar.js +1 -1
- package/src/ui/revisionssidebar/revisionssidebarheaderview.js +1 -1
- package/src/ui/revisionssidebar/revisionssidebartimeperiodview.js +1 -1
- package/src/ui/revisionssidebar/revisionssidebarview.js +1 -1
- package/src/ui/revisionssidebar/utils.js +1 -1
- package/src/ui/revisionviewer/changedetailsview.js +1 -1
- package/src/ui/revisionviewer/changesnavigationview.js +1 -1
- package/src/ui/revisionviewer/revisionviewerloadingoverlay.js +1 -1
- package/src/ui/revisionviewer/revisionviewerui.js +1 -1
- package/src/utils/common-translations.js +1 -1
package/dist/index.js
CHANGED
|
@@ -20,10 +20,10 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
import{ObservableMixin as
|
|
24
|
-
_0x45eadb(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x21aa29){super(),this['id']=_0x21aa29['id']||_0x49b9a1(),this['creator']=_0x21aa29['creator']||null,this['authors']=_0x21aa29['authors']||[],this['diffData']=_0x21aa29['diffData']||null,this['toVersion']=_0x21aa29['toVersion']||0x0,this['fromVersion']=_0x21aa29['fromVersion']||0x0,this['set']('name',_0x21aa29['name']||''),this['set']('createdAt',_0x21aa29['createdAt']||new Date()),this['set']('attributes',_0x21aa29['attributes']||{});}['setName'](_0x523faf){this['_update']({'name':_0x523faf});}['setAttribute'](_0xf3ea33,_0x13800d){const _0x2d359e=_0x57b19f(this['attributes']);_0x42b299(_0x2d359e,_0xf3ea33,_0x13800d),this['_update']({'attributes':_0x2d359e});}['removeAttribute'](_0x36a38a){const _0x28099f=_0x57b19f(this['attributes']);_0x47e7a5(_0x28099f,_0x36a38a),this['_update']({'attributes':_0x28099f});}['_update'](_0x579f20,_0x1321c0=!0x1){let _0x387b8c=!0x1;const _0x1deb80={'id':this['id']},_0x31afcd=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x4616fe of _0x31afcd){const _0x26e2c7=_0x579f20[_0x4616fe];void 0x0!==_0x26e2c7&&_0x26e2c7!==this[_0x4616fe]&&(this[_0x4616fe]=_0x26e2c7,_0x1deb80[_0x4616fe]=_0x26e2c7,_0x387b8c=!0x0);}_0x387b8c&&(_0x1deb80['authors']&&(_0x1deb80['authorsIds']=_0x1deb80['authors']['map'](_0x47fc2d=>_0x47fc2d['id']),delete _0x1deb80['authors']),this['fire']('_update',_0x1deb80,_0x1321c0));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x1b50b9=>_0x1b50b9['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class j extends _0xc00adc{['_revisions'];static get['requires'](){return[_0x926ed0];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x131a33){super(_0x131a33),this['_revisions']=new _0x43846a();}['afterInit'](){!async function(_0x3d1ba8){const _0x29726f=_0x3ec99c([0x62,0x30,0x75,0x77,0x36,0x48,0x31,0x39,0x58,0x71,0x32,0x68,0x66,0x54,0x41,0x4c,0x4e,0x46,0x35,0x4b,0x33,0x4d,0x6d,0x70,0x72,0x4f,0x74,0x76,0x56,0x61,0x44,0x49,0x51,0x6c,0x59,0x45,0x78,0x65,0x69,0x42,0x63,0x4a,0x34,0x64,0x6e,0x57,0x6f,0x53,0x5a,0x43,0x6b,0x38,0x37,0x73,0x67,0x79,0x7a,0x6a,0x55,0x47,0x50,0x52]),_0x1a7682=0xeb829,_0x14c590=0x46a7764f,_0x3d54b3=0x46a016d7^_0x14c590,_0x34a798=window[_0x3ec99c([0x44,0x61,0x74,0x65])][_0x3ec99c([0x6e,0x6f,0x77])](),_0x15d162=_0x3d1ba8[_0x3ec99c([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x523d03=new window[(_0x3ec99c([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0xe9576d=>{_0x15d162[_0x3ec99c([0x6f,0x6e,0x63,0x65])](_0x3ec99c([0x72,0x65,0x61,0x64,0x79]),_0xe9576d);}),_0x1da68a={[_0x3ec99c([0x6b,0x74,0x79])]:_0x3ec99c([0x45,0x43]),[_0x3ec99c([0x75,0x73,0x65])]:_0x3ec99c([0x73,0x69,0x67]),[_0x3ec99c([0x63,0x72,0x76])]:_0x3ec99c([0x50,0x2d,0x32,0x35,0x36]),[_0x3ec99c([0x78])]:_0x3ec99c([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]),[_0x3ec99c([0x79])]:_0x3ec99c([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]),[_0x3ec99c([0x61,0x6c,0x67])]:_0x3ec99c([0x45,0x53,0x32,0x35,0x36])},_0x3419d7=_0x15d162[_0x3ec99c([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x3ec99c([0x67,0x65,0x74])](_0x3ec99c([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x4bd4f6(){let _0xc6efb6,_0x10365e=null,_0x31b282=null;try{if(_0x3419d7==_0x3ec99c([0x47,0x50,0x4c]))return _0x3ec99c([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0xc6efb6=_0x324ca1(),!_0xc6efb6)return _0x3ec99c([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0xc6efb6[_0x3ec99c([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x31b282=_0x3579c8(_0xc6efb6[_0x3ec99c([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0xc6efb6[_0x3ec99c([0x6a,0x74,0x69])])),await _0x26ec6e()?_0x3ef570()?_0x3f3bb1()?_0x3ec99c([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x15bdfe()?(_0xc6efb6[_0x3ec99c([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x3ec99c([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x10365e=_0x1efee0(_0x3ec99c([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0xc6efb6[_0x3ec99c([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x3ec99c([0x74,0x72,0x69,0x61,0x6c])&&(_0x10365e=_0x1efee0(_0x3ec99c([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x165d46()):_0x3ec99c([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x3ec99c([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x3ec99c([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch(_0x5727d3){return _0x3ec99c([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x3f3bb1(){const _0x3c9701=[_0x3ec99c([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x3ec99c([0x74,0x72,0x69,0x61,0x6c])][_0x3ec99c([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0xc6efb6[_0x3ec99c([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x34a798/0x3e8:0xe10*_0x3d54b3;return _0xc6efb6[_0x3ec99c([0x65,0x78,0x70])]<_0x3c9701;}function _0x3ef570(){const _0x3952b4=_0xc6efb6[_0x3ec99c([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x3952b4)return!0x1;if(_0x3952b4[_0x3ec99c([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x3ec99c([0x2a])))return!0x0;if(_0x3952b4[_0x3ec99c([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x3ec99c([0x52,0x48])))return!0x0;if(_0x3952b4[_0x3ec99c([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x3ec99c([0x52,0x52,0x48]))){if(_0x844de9())return!0x0;if(_0x1d3d38()||_0x153b2f())return!0x0;}return!0x1;}function _0x15bdfe(){const _0x20c77e=_0xc6efb6[_0x3ec99c([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x20c77e||0x0==_0x20c77e[_0x3ec99c([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x1deea0}=new URL(window[_0x3ec99c([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x20c77e[_0x3ec99c([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x1deea0))return!0x0;const _0x69f32=_0x1deea0[_0x3ec99c([0x73,0x70,0x6c,0x69,0x74])](_0x3ec99c([0x2e]));return _0x20c77e[_0x3ec99c([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x1c71f1=>_0x1c71f1[_0x3ec99c([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x3ec99c([0x2a])))[_0x3ec99c([0x6d,0x61,0x70])](_0x2b0b33=>_0x2b0b33[_0x3ec99c([0x73,0x70,0x6c,0x69,0x74])](_0x3ec99c([0x2e])))[_0x3ec99c([0x73,0x6f,0x6d,0x65])](_0x420d81=>_0x69f32[_0x3ec99c([0x65,0x76,0x65,0x72,0x79])]((_0x41120b,_0x4fc1e2)=>_0x420d81[_0x4fc1e2]===_0x41120b||_0x420d81[_0x4fc1e2]===_0x3ec99c([0x2a])));}function _0x165d46(){return _0x10365e&&_0x31b282?new window[(_0x3ec99c([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x598dd1,_0x14875e)=>{_0x10365e[_0x3ec99c([0x74,0x68,0x65,0x6e])](_0x598dd1,_0x14875e),_0x31b282[_0x3ec99c([0x74,0x68,0x65,0x6e])](_0x37fd9c=>{_0x37fd9c!=_0x3ec99c([0x56,0x61,0x6c,0x69,0x64])&&_0x598dd1(_0x37fd9c);},_0x14875e);}):_0x10365e||_0x31b282||_0x3ec99c([0x56,0x61,0x6c,0x69,0x64]);}}function _0x3579c8(_0x295c01,_0x6ef70f){return new window[(_0x3ec99c([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x17d8c9=>{if(_0x5ebde8())return _0x17d8c9(_0x3ec99c([0x56,0x61,0x6c,0x69,0x64]));_0xe4309c(),_0x15d162[_0x3ec99c([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x3ec99c([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x27ca78=!0x1;const _0x4cccb6=_0x49b9a1();function _0x42ae45(_0x49123e){return!!_0x49123e&&(typeof _0x49123e===_0x3ec99c([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x49123e===_0x3ec99c([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x49123e[_0x3ec99c([0x74,0x68,0x65,0x6e])]===_0x3ec99c([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x49123e[_0x3ec99c([0x63,0x61,0x74,0x63,0x68])]===_0x3ec99c([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x4bdba1(_0x26919c){_0x2b77c7(_0x26919c)[_0x3ec99c([0x74,0x68,0x65,0x6e])](_0x96d23f=>{if(!_0x96d23f||_0x96d23f[_0x3ec99c([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x3ec99c([0x6f,0x6b]))return _0x3ec99c([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0xb4d3b1(_0x55bd84(_0x4cccb6+_0x6ef70f))!=_0x96d23f[_0x3ec99c([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x3ec99c([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x3ec99c([0x56,0x61,0x6c,0x69,0x64]);})[_0x3ec99c([0x74,0x68,0x65,0x6e])](_0x53d120=>(_0x345f2c(),_0x53d120),()=>{const _0x1eae66=_0x47144d();return null==_0x1eae66?(_0x345f2c(),_0x3ec99c([0x56,0x61,0x6c,0x69,0x64])):_0x3ec99c(_0x34a798-_0x1eae66>(0x62abf24f^_0x14c590)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x3ec99c([0x74,0x68,0x65,0x6e])](_0x17d8c9)[_0x3ec99c([0x63,0x61,0x74,0x63,0x68])](()=>{_0x17d8c9(_0x3ec99c([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x5d9cbc=0x469198cf^_0x14c590;function _0x345f2c(){const _0x2467a4=_0x3ec99c([0x6c,0x6c,0x63,0x74,0x2d])+_0xb4d3b1(_0x55bd84(_0x295c01)),_0x8f7415=_0x205ce1(_0xb4d3b1(window[_0x3ec99c([0x4d,0x61,0x74,0x68])][_0x3ec99c([0x63,0x65,0x69,0x6c])](_0x34a798/_0x5d9cbc)));window[_0x3ec99c([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x3ec99c([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x2467a4,_0x8f7415);}function _0x47144d(){const _0x580ec8=_0x3ec99c([0x6c,0x6c,0x63,0x74,0x2d])+_0xb4d3b1(_0x55bd84(_0x295c01)),_0x443f48=window[_0x3ec99c([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x3ec99c([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x580ec8);return _0x443f48?window[_0x3ec99c([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x205ce1(_0x443f48),0x10)*_0x5d9cbc:null;}function _0x2b77c7(_0x324965){return new window[(_0x3ec99c([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x586641,_0x1534ca)=>{_0x324965[_0x3ec99c([0x74,0x68,0x65,0x6e])](_0x586641,_0x1534ca),window[_0x3ec99c([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x1534ca,0x46a6a28f^_0x14c590);});}}_0x15d162[_0x3ec99c([0x6f,0x6e])](_0x3ec99c([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x119144,_0x502ae1)=>{if(_0x502ae1[0x0]!=_0x295c01)return _0x17d8c9(_0x3ec99c([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x502ae1[0x1]={..._0x502ae1[0x1],[_0x3ec99c([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x4cccb6};},{[_0x3ec99c([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x3ec99c([0x68,0x69,0x67,0x68])}),_0x15d162[_0x3ec99c([0x6f,0x6e])](_0x3ec99c([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x2a70dc=>{_0x42ae45(_0x2a70dc[_0x3ec99c([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x27ca78=!0x0,_0x4bdba1(_0x2a70dc[_0x3ec99c([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x3ec99c([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x3ec99c([0x6c,0x6f,0x77])}),_0x523d03[_0x3ec99c([0x74,0x68,0x65,0x6e])](()=>{_0x27ca78||_0x17d8c9(_0x3ec99c([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x5ebde8(){return _0x15d162[_0x3ec99c([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x3ec99c([0x76,0x69,0x65,0x77])][_0x3ec99c([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x3ec99c([0x61,0x75,0x74,0x6f]);}function _0xe4309c(){_0x15d162[_0x3ec99c([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x3ec99c([0x76,0x69,0x65,0x77])][_0x3ec99c([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x3ec99c([0x61,0x75,0x74,0x6f]);}}function _0x1efee0(_0x32784b){const _0x6a0f24=[new window[(_0x3ec99c([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x24007e=>setTimeout(_0x24007e,0x46ae4883^_0x14c590)),_0x523d03[_0x3ec99c([0x74,0x68,0x65,0x6e])](()=>new window[(_0x3ec99c([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x355b02=>{const _0x3f2116=0x46a77648^_0x14c590,_0x451b3e=_0x3d1ba8[_0x3ec99c([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x296691(){_0x451b3e[_0x3ec99c([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x3f2116&&_0x355b02();}_0x296691(),_0x451b3e[_0x3ec99c([0x6f,0x6e])](_0x3ec99c([0x61,0x64,0x64]),_0x296691);})),new window[(_0x3ec99c([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x972943=>{function _0x44aaff(){for(const _0x4ae421 in window)if(window[_0x3ec99c([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x3ec99c([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x4ae421))&&window[_0x4ae421]==_0x1a7682)return _0x972943();_0x15d162[_0x3ec99c([0x73,0x74,0x61,0x74,0x65])]!=_0x3ec99c([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x3ec99c([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x44aaff,0x46a765c7^_0x14c590);}_0xfb465(_0x3ec99c([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x44aaff();})];return window[_0x3ec99c([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x3ec99c([0x72,0x61,0x63,0x65])](_0x6a0f24)[_0x3ec99c([0x74,0x68,0x65,0x6e])](()=>_0x32784b);}async function _0x56ccea(){if(await _0x523d03,_0xfb465(_0x3ec99c([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x1597da=_0x3d1ba8[_0x3ec99c([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x1e66f5=_0x3d1ba8[_0x3ec99c([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])](_0x1597da[_0x3ec99c([0x69,0x64])]),_0x19ba06=_0x587164(_0x3ec99c([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x19ba06[_0x3ec99c([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x1597da['id'],_0x1e66f5?_0x1e66f5['id']:null,!0x0),_0x19ba06[_0x3ec99c([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x3ec99c([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x19ba06[_0x3ec99c([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x19ba06[_0x3ec99c([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x57586d,void(_0x19ba06[_0x3ec99c([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x57586d);}if(_0xfb465(_0x3ec99c([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x9a7bb4=_0x587164(_0x3ec99c([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x9a7bb4[_0x3ec99c([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x3ec99c([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x9a7bb4[_0x3ec99c([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x9a7bb4[_0x3ec99c([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x57586d,_0x9a7bb4[_0x3ec99c([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x57586d;}_0x15d162[_0x3ec99c([0x6d,0x6f,0x64,0x65,0x6c])][_0x3ec99c([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x57586d,_0x15d162[_0x3ec99c([0x6d,0x6f,0x64,0x65,0x6c])][_0x3ec99c([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x57586d,_0x15d162[_0x3ec99c([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x3ec99c([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x844de9(){return _0xfb465(_0x3ec99c([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x587164(_0x3ec99c([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x3ec99c([0x73,0x74,0x61,0x74,0x65])]==_0x3ec99c([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x1d3d38(){return _0xfb465(_0x3ec99c([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 _0x153b2f(){return _0xfb465(_0x3ec99c([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x25b5f8(_0x10a7b8){const _0x419e44=_0x592288();_0x15d162[_0x419e44]=_0x3ec99c([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])+_0x10a7b8,_0x10a7b8[_0x3ec99c([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x3ec99c([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x592288()]=_0x1a7682),_0x10a7b8!=_0x3ec99c([0x56,0x61,0x6c,0x69,0x64])&&_0x56ccea();}function _0x592288(){const _0x3ca8f0=window[_0x3ec99c([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x3ec99c([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x3ec99c([0x6e,0x6f,0x77])]())[_0x3ec99c([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x3ec99c([0x2e]),'');let _0x1261a5=_0x3ec99c([0x62]);for(let _0x5c1fab=0x0;_0x5c1fab<_0x3ca8f0[_0x3ec99c([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x5c1fab+=0x2){let _0x5152f3=window[_0x3ec99c([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x3ca8f0[_0x3ec99c([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x5c1fab,_0x5c1fab+0x2));_0x5152f3>=_0x29726f[_0x3ec99c([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x5152f3-=_0x29726f[_0x3ec99c([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x1261a5+=_0x29726f[_0x5152f3];}return _0x1261a5;}function _0x324ca1(){const _0x2aaebc=_0x3419d7[_0x3ec99c([0x73,0x70,0x6c,0x69,0x74])](_0x3ec99c([0x2e]));if(0x3!=_0x2aaebc[_0x3ec99c([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x362c69(_0x2aaebc[0x1]);function _0x362c69(_0x188736){const _0x3710de=_0x1d30c1(_0x188736);return _0x3710de&&_0x584ead()?_0x3710de:null;function _0x584ead(){const _0x251238=_0x3710de[_0x3ec99c([0x6a,0x74,0x69])],_0x260fe4=window[_0x3ec99c([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x251238[_0x3ec99c([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x251238[_0x3ec99c([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x2ca2c3={..._0x3710de,[_0x3ec99c([0x6a,0x74,0x69])]:_0x251238[_0x3ec99c([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x251238[_0x3ec99c([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x2ca2c3[_0x3ec99c([0x76,0x63])],_0x55bd84(_0x2ca2c3)==_0x260fe4;}}}async function _0x26ec6e(){let _0x5f0669=!0x0;try{const _0x32fb50=_0x3419d7[_0x3ec99c([0x73,0x70,0x6c,0x69,0x74])](_0x3ec99c([0x2e])),[_0x383251,_0xb3b1c1,_0x544a6e]=_0x32fb50;return _0x47ad44(_0x383251),await _0x2fab48(_0x383251,_0xb3b1c1,_0x544a6e),_0x5f0669;}catch(_0x3cbe14){return!0x1;}function _0x47ad44(_0x5bcae8){const _0x1eb362=_0x1d30c1(_0x5bcae8);_0x1eb362&&_0x1eb362[_0x3ec99c([0x61,0x6c,0x67])]==_0x3ec99c([0x45,0x53,0x32,0x35,0x36])||(_0x5f0669=!0x1);}async function _0x2fab48(_0x4e14cc,_0x1aabd9,_0x49ddf5){const _0x303ac3=window[_0x3ec99c([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x3ec99c([0x66,0x72,0x6f,0x6d])](_0x5a1a49(_0x49ddf5),_0x4b27f0=>_0x4b27f0[_0x3ec99c([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x4e7ca1=new window[(_0x3ec99c([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x3ec99c([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x4e14cc+_0x3ec99c([0x2e])+_0x1aabd9),_0x8bcb42=window[_0x3ec99c([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x3ec99c([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x8bcb42)return;const _0xfecf4=await _0x8bcb42[_0x3ec99c([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x3ec99c([0x6a,0x77,0x6b]),_0x1da68a,{[_0x3ec99c([0x6e,0x61,0x6d,0x65])]:_0x3ec99c([0x45,0x43,0x44,0x53,0x41]),[_0x3ec99c([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x3ec99c([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x3ec99c([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x8bcb42[_0x3ec99c([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x3ec99c([0x6e,0x61,0x6d,0x65])]:_0x3ec99c([0x45,0x43,0x44,0x53,0x41]),[_0x3ec99c([0x68,0x61,0x73,0x68])]:{[_0x3ec99c([0x6e,0x61,0x6d,0x65])]:_0x3ec99c([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0xfecf4,_0x303ac3,_0x4e7ca1)||(_0x5f0669=!0x1);}}function _0x1d30c1(_0x472ec0){return _0x472ec0[_0x3ec99c([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x3ec99c([0x65,0x79]))?JSON[_0x3ec99c([0x70,0x61,0x72,0x73,0x65])](_0x5a1a49(_0x472ec0)):null;}function _0x5a1a49(_0x4a5d9c){return window[_0x3ec99c([0x61,0x74,0x6f,0x62])](_0x4a5d9c[_0x3ec99c([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x3ec99c([0x2b]))[_0x3ec99c([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x3ec99c([0x2f])));}function _0x55bd84(_0x4598f7){let _0xa21e99=0x1505;function _0x1e2ad0(_0x3b1d78){for(let _0x252eec=0x0;_0x252eec<_0x3b1d78[_0x3ec99c([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x252eec++){const _0x105157=_0x3b1d78[_0x3ec99c([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x252eec);_0xa21e99=(_0xa21e99<<0x5)+_0xa21e99+_0x105157,_0xa21e99&=_0xa21e99;}}function _0x3333f9(_0x35b5e2){Array[_0x3ec99c([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x35b5e2)?_0x35b5e2[_0x3ec99c([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x3333f9):_0x35b5e2&&typeof _0x35b5e2==_0x3ec99c([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x3ec99c([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x35b5e2)[_0x3ec99c([0x73,0x6f,0x72,0x74])]()[_0x3ec99c([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x595a7b,_0x25cd92])=>{_0x1e2ad0(_0x595a7b),_0x3333f9(_0x25cd92);}):_0x1e2ad0(window[_0x3ec99c([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x35b5e2));}return _0x3333f9(_0x4598f7),_0xa21e99>>>0x0;}function _0xb4d3b1(_0x2ba35a){return _0x2ba35a[_0x3ec99c([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x3ec99c([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x3ec99c([0x30]));}function _0x205ce1(_0x462c05){return _0x462c05[_0x3ec99c([0x73,0x70,0x6c,0x69,0x74])]('')[_0x3ec99c([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x3ec99c([0x6a,0x6f,0x69,0x6e])]('');}function _0xfb465(_0x2ecd1b){return _0x15d162[_0x3ec99c([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x3ec99c([0x68,0x61,0x73])](_0x2ecd1b);}function _0x587164(_0x4f6a56){return _0x15d162[_0x3ec99c([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x3ec99c([0x67,0x65,0x74])](_0x4f6a56);}function _0x57586d(){}function _0x3ec99c(_0x905f48){return _0x905f48['map'](_0x32b0a4=>String['fromCharCode'](_0x32b0a4))['join']('');}_0x25b5f8(await _0x4bd4f6());}(this);}['createRevision'](_0x4a6f15){const _0x26410f=this['editor']['plugins']['get']('Users');return new a({'id':_0x4a6f15['id'],'name':_0x4a6f15['name'],'creator':_0x4a6f15['creatorId']?_0x26410f['getUser'](_0x4a6f15['creatorId']):null,'diffData':_0x4a6f15['diffData']||_0x4a6f15['data'],'authors':_0x4a6f15['authorsIds']['map'](_0x49f8ad=>_0x26410f['getUser'](_0x49f8ad)),'createdAt':new Date(_0x4a6f15['createdAt']),'attributes':_0x4a6f15['attributes'],'fromVersion':_0x4a6f15['fromVersion'],'toVersion':_0x4a6f15['toVersion']});}['addRevision'](_0x273b32,_0x1113e5=0x0){this['_revisions']['add'](_0x273b32,_0x1113e5);}['getRevision'](_0x5d0c49){return this['_revisions']['get'](_0x5d0c49);}['getRevisions'](_0x2ee7a2={'toJSON':!0x1}){const _0x4fe612=Array['from'](this['_revisions']);return _0x4fe612['reverse'](),_0x2ee7a2['toJSON']?_0x4fe612['map'](_0x948a51=>_0x948a51['toJSON']()):_0x4fe612;}['getIndex'](_0x2a15fa){return this['_revisions']['getIndex'](_0x2a15fa);}['getEarlierVisibleRevision'](_0x42cda2){const [,_0x14d5c9]=this['getRevisionsIterator'](_0x42cda2,{'direction':'earlier'});return _0x14d5c9;}['getLaterVisibleRevision'](_0x38bdec){const [,_0x40b337]=this['getRevisionsIterator'](_0x38bdec,{'direction':'later'});return _0x40b337;}['getRevisionsInDiff'](_0x5322ca){const _0x1321c9=[];for(const _0x3c8f23 of this['getRevisionsIterator'](_0x5322ca['newRevisionId']))if(_0x1321c9['push'](_0x3c8f23),_0x3c8f23['id']===_0x5322ca['oldRevisionId'])break;return _0x1321c9;}*['getRevisionsIterator'](_0x425356,{direction:_0x1a0049='earlier',filter:_0x360c74=()=>!0x0}={}){const _0x3e880b='earlier'===_0x1a0049?0x1:-0x1;let _0x2a6769=this['_revisions']['get'](_0x425356),_0x16e92b=this['getIndex'](_0x2a6769);for(yield _0x2a6769;_0x2a6769;){if(_0x16e92b+=_0x3e880b,_0x2a6769=this['getRevision'](_0x16e92b),!_0x2a6769)return;_0x360c74(_0x2a6769)&&(yield _0x2a6769);}}}function m(_0x20a4a2,_0x4ae5ef,_0x50b29f){const t=_0x20a4a2['t'];switch(_0x4ae5ef){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'},_0x50b29f);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x50b29f);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':_0xaeeac4,'a':_0x388953,'e':_0x3a7bef,'r':_0x52a07e,'u':_0x44a4f8};class l extends _0xc00adc{['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[_0x926ed0,j,_0x366076];}constructor(_0x5d6d68){super(_0x5d6d68),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 _0x1a2a59=_0x49b9a1();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x1a2a59},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 _0x201eee=this['repository']['getRevision'](0x0),_0x37b095=_0x201eee&&null===_0x201eee['creator']?_0x201eee:null;if(this['_continueCurrentRevision']=!!_0x37b095&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x33af6b=this['_source']['getCurrentRevisionId'](),_0x159c3b=this['repository']['getRevision'](_0x33af6b);if(_0x159c3b)this['_startingVersion']=_0x159c3b['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x1c9977=this['_source']['history']['_operations']['find'](_0x1061d7=>!_0x1061d7['_isInit']),_0x1b5ba3=_0x1c9977?_0x1c9977['baseVersion']:this['_source']['history']['version'];_0x201eee?(_0x201eee['toVersion']<_0x1b5ba3&&_0x201eee['_update']({'toVersion':_0x1b5ba3}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x37b095['id'],this['_startingVersion']=_0x37b095['fromVersion']):(this['_startingVersion']=_0x201eee['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x1b5ba3,this['_continueCurrentRevision']=!0x1);}}else _0x37b095&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x37b095['toVersion'],this['editor']['model']['document']['history']['version']),_0x37b095['fromVersion']===_0x37b095['toVersion']?(0x0!==_0x37b095['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x37b095['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x37b095['id'],this['_startingVersion']=_0x37b095['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',_0x74301e=>!_0x74301e),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x3cf4aa=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x48c915;for(const _0x306826 in _0x3cf4aa){const _0x1b74bc=_0x306826,_0x446dad=_0x3cf4aa[_0x1b74bc];if('revisionHistoryLicenseKeyValid'==_0x446dad||'revisionHistoryLicenseKeyInvalid'==_0x446dad||'revisionHistoryLicenseKeyExpired'==_0x446dad||'revisionHistoryLicenseKeyDomainLimit'==_0x446dad||'revisionHistoryLicenseKeyNotAllowed'==_0x446dad||'revisionHistoryLicenseKeyEvaluationLimit'==_0x446dad||'revisionHistoryLicenseKeyTrialLimit'==_0x446dad||'revisionHistoryLicenseKeyUsageLimit'==_0x446dad){delete _0x3cf4aa[_0x1b74bc],_0x48c915=_0x446dad,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x48c915&&_0x3cf4aa['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x48c915&&_0x3cf4aa['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x48c915&&_0x3cf4aa['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x48c915&&_0x3cf4aa['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x48c915&&_0x3cf4aa['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x48c915&&_0x3cf4aa['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x48c915&&_0x3cf4aa['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x34ea67=this['repository']['getRevision'](0x0),_0x426011=await this['getRevisionDocumentData'](_0x34ea67),_0x523ead=await this['getRevisionRootsAttributes'](_0x34ea67);this['_replaceEditorDataWithRevisionData'](_0x426011,_0x523ead);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x5e49f3){this['_source']=_0x5e49f3;}async['update'](){const _0x1259e4=await this['_source']['getLatestVersion']();if(_0x1259e4>this['currentRevision']['toVersion']){await this['_loadState']();const _0xdb0960=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x1259e4});_0xdb0960['authors']=_0xdb0960['authorsIds']['map'](_0x1d92dc=>this['editor']['plugins']['get']('Users')['getUser'](_0x1d92dc)),this['currentRevision']['_update'](_0xdb0960);}}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'](_0x40903f={},_0x2091af=null){const _0x502e0c=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x2091af>this['currentRevision']['toVersion']&&(_0x2091af=null),null===_0x2091af&&(_0x2091af=await this['_source']['getLatestVersion']());const _0x593caa=this['_getFromVersion'](_0x2091af),_0x2dd090=this['buildRevisionData']({'from':_0x593caa,'to':_0x2091af});if(this['currentRevision']['toVersion']<_0x2091af){const _0x175cdb=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x2091af,'to':_0x2091af});_0x175cdb['authors']=[],_0x175cdb['authorsIds']=[],_0x175cdb['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x175cdb,!0x0),delete _0x175cdb['authors'],_0x502e0c['push'](_0x175cdb);}_0x40903f['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x40903f['name']=_0x40903f['name']||null,_0x40903f['id']=_0x40903f['id']||_0x49b9a1(),_0x40903f={..._0x40903f,..._0x2dd090};const _0x192b05=this['addRevisionData'](_0x40903f);_0x502e0c['push'](_0x40903f);const _0x41e8f4=this['repository']['getIndex'](_0x192b05);if(0x0!==_0x41e8f4){const _0x5e8de7=this['repository']['getRevision'](_0x41e8f4-0x1);if(_0x5e8de7['fromVersion']!==_0x2091af){const _0x2ed314=this['_revisionDataBuilder']['getData'](_0x2091af,_0x5e8de7['toVersion']),_0x300488={'id':_0x5e8de7['id'],'diffData':_0x2ed314['diffData'],'authorsIds':_0x2ed314['authorsIds'],'authors':_0x2ed314['authorsIds']['map'](_0x1a569a=>this['editor']['plugins']['get']('Users')['getUser'](_0x1a569a)),'fromVersion':_0x2091af};_0x5e8de7===this['currentRevision']&&(_0x300488['createdAt']=new Date(_0x40903f['createdAt']['getTime']()+0xa)),_0x5e8de7['_update'](_0x300488,!0x0),delete _0x300488['authors'],_0x502e0c['push'](_0x300488);}}if(this['adapter']){for(const _0x40dc36 of _0x502e0c)this['_bufferUpdate'](_0x40dc36['id'],_0x40dc36,!0x0);this['sendBufferedUpdates']();}return _0x192b05;}['addRevisionData'](_0x202312){const _0x305000=this['repository']['createRevision'](_0x202312);return this['adapter']&&_0x305000['on']('_update',(_0x899c72,_0x144986,_0x30a5dc)=>{_0x30a5dc||(this['_bufferUpdate'](_0x144986['id'],_0x144986,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x305000,this['_findInsertionIndex'](_0x305000)),_0x305000;}async['getRevisionDocumentData'](_0x4986fb){await this['_loadRevisionData'](_0x4986fb);const _0x5c441c={};for(const _0x5088e9 in _0x4986fb['diffData']){if(_0x4986fb['diffData'][_0x5088e9]['attachChange']&&!_0x4986fb['diffData'][_0x5088e9]['attachChange']['isAttached'])continue;const _0x4ee2ae=this['_removeRevisionMarkers'](JSON['parse'](_0x4986fb['diffData'][_0x5088e9]['insertions'])),_0x30b736=this['editor']['editing']['view']['document'],_0x55afbf=new _0x1f9cff(_0x30b736,_0x4ee2ae['map'](_0x588642=>C(_0x588642,this['editor'])));this['editor']['data']['processor']['useFillerType']('marked'),_0x5c441c[_0x5088e9]=this['editor']['data']['processor']['toData'](_0x55afbf),this['editor']['data']['processor']['useFillerType']('default');}return _0x5c441c;}async['getRevisionRootsAttributes'](_0x1e30a7){await this['_loadRevisionData'](_0x1e30a7);const _0x350929={};for(const _0x31385c in _0x1e30a7['diffData'])_0x1e30a7['diffData'][_0x31385c]['attachChange']&&!_0x1e30a7['diffData'][_0x31385c]['attachChange']['isAttached']||(_0x350929[_0x31385c]=_0x1e30a7['diffData'][_0x31385c]['attributesAfter']||{});return _0x350929;}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x5702a2=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x1887a4=0x0;_0x1887a4<_0x5702a2['length'];_0x1887a4++){const _0xc8483d=_0x5702a2[_0x1887a4];let _0x216101=!0x1;for(const _0x224ccb of Object['keys'](_0xc8483d))void 0x0===_0xc8483d[_0x224ccb]?delete _0xc8483d[_0x224ccb]:'id'!==_0x224ccb&&(_0x216101=!0x0);_0x216101||(_0x5702a2[_0x1887a4]=null);}if(_0x5702a2=_0x5702a2['filter'](_0xcd7217=>null!==_0xcd7217),!_0x5702a2['length'])return;for(let _0x1fa428=0x0;_0x1fa428<_0x5702a2['length'];_0x1fa428++){const _0x4b4e80=_0x5702a2[_0x1fa428];void 0x0!==_0x4b4e80['fromVersion']&&void 0x0===_0x4b4e80['toVersion']&&(_0x4b4e80['toVersion']=this['repository']['getRevision'](_0x4b4e80['id'])['toVersion']),void 0x0!==_0x4b4e80['toVersion']&&void 0x0===_0x4b4e80['fromVersion']&&(_0x4b4e80['fromVersion']=this['repository']['getRevision'](_0x4b4e80['id'])['fromVersion']);}const _0x5567ab=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x5702a2,_0x5567ab)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x175b3b=>{if(_0x175b3b){for(const _0xf79f3e of _0x175b3b)this['setRevisionData']({'id':_0xf79f3e['id'],'createdAt':_0xf79f3e['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['_replaceEditorDataWithRevisionData'](_0x54f06b,_0x4e4da3){let _0xd9525f=this['editor']['config']['get']('initialData'),_0x3a4e54=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0xd9525f){_0xd9525f={};for(const _0x50e2f6 of this['editor']['model']['document']['getRootNames']())_0xd9525f[_0x50e2f6]='';}if('string'==typeof _0xd9525f&&(_0xd9525f={'main':_0xd9525f}),void 0x0===_0x3a4e54){_0x3a4e54={};for(const _0x5d37c7 of this['editor']['model']['document']['getRootNames']())_0x3a4e54[_0x5d37c7]={};}let _0x269bbb=!0x1;const _0x6c0aad=Object['keys'](_0xd9525f),_0x2d9623=Object['keys'](_0x54f06b);for(const _0x1c6e95 of _0x6c0aad){if(_0xd9525f[_0x1c6e95]!==_0x54f06b[_0x1c6e95]&&''!==_0xd9525f[_0x1c6e95]['trim']()){_0x269bbb=!0x0;break;}if(!_0x2ec612(_0x3a4e54[_0x1c6e95],_0x4e4da3[_0x1c6e95])&&Object['keys'](_0x3a4e54[_0x1c6e95])['length']>0x0){_0x269bbb=!0x0;break;}}_0x269bbb||(_0x269bbb=_0x2d9623['some'](_0x5a3cda=>!this['editor']['model']['document']['getRoot'](_0x5a3cda))),_0x269bbb&&_0x11aaac('editor-initial-data-replaced-with-revision-data',{'editorData':_0xd9525f,'editorRootsAttributes':_0x3a4e54,'revisionData':_0x54f06b,'revisionRootsAttributes':_0x4e4da3}),this['editor']['config']['set']('initialData',_0x54f06b),this['editor']['config']['set']('rootsAttributes',_0x4e4da3);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x351976=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x351976['add'](m(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x550b80){const _0x33caab=this['repository']['getRevisions']();_0x33caab['reverse']();let _0x5179bb=0x0;for(;_0x5179bb<_0x33caab['length'];){const _0x273820=_0x33caab[_0x5179bb];if(_0x273820===this['currentRevision']){_0x5179bb++;continue;}if(_0x273820['id']===this['_initialRevisionId'])break;const _0x1fecca=_0x550b80['toVersion']-_0x273820['toVersion']||_0x550b80['fromVersion']-_0x273820['fromVersion'];if(_0x1fecca>0x0)break;if(_0x1fecca<0x0)_0x5179bb++;else{if(!_0x550b80['creator']&&_0x273820['creator'])break;if(_0x273820['creator']||!_0x550b80['creator']){if(_0x550b80['createdAt']>_0x273820['createdAt'])break;_0x5179bb++;}else _0x5179bb++;}}return _0x5179bb;}['setRevisionData'](_0x5929ab){const _0x2aed4c=this['repository']['getRevision'](_0x5929ab['id']);if(_0x5929ab['createdAt']&&(_0x5929ab['createdAt']=new Date(_0x5929ab['createdAt'])),_0x5929ab['authorsIds']){const _0x10d928=this['editor']['plugins']['get']('Users');_0x5929ab['authors']=_0x5929ab['authorsIds']['map'](_0x1c5514=>_0x10d928['getUser'](_0x1c5514));}_0x2aed4c['_update'](_0x5929ab,!0x0);}['buildRevisionData']({revision:_0x513f81=null,from:_0x5adaa5=null,to:_0x3dbd92=null}){_0x5adaa5=null!==_0x5adaa5?_0x5adaa5:_0x513f81['fromVersion'],_0x3dbd92=null!==_0x3dbd92?_0x3dbd92:_0x513f81['toVersion'];const _0x4f2734=this['_revisionDataBuilder']['getData'](_0x5adaa5,_0x3dbd92),_0x17ebdc={'diffData':_0x4f2734['diffData'],'authorsIds':_0x4f2734['authorsIds'],'fromVersion':_0x5adaa5,'toVersion':_0x3dbd92};if(!_0x513f81||_0x3dbd92!==_0x513f81['toVersion']){const _0x55736e=_0x3dbd92-0x1,_0x1ba3c5=this['_source']['history']['getOperation'](_0x55736e);_0x17ebdc['createdAt']=_0x1ba3c5&&_0x1ba3c5['createdAt']||new Date();}if(this['_loadedStateData']&&_0x5adaa5===this['_loadedStateData']['fromVersion']){for(const _0x262516 of this['_loadedStateData']['authors'])_0x17ebdc['authorsIds']['includes'](_0x262516['id'])||_0x17ebdc['authorsIds']['push'](_0x262516['id']);}return _0x17ebdc;}['_loadRevisionData'](_0x4ade27){if(!_0x4ade27||_0x4ade27['diffData'])return Promise['resolve']();{const _0x22de2f=this['editor']['config']['get']('collaboration.channelId');return this['adapter']['getRevision']({'channelId':_0x22de2f,'revisionId':_0x4ade27['id']})['then'](_0x1bf665=>{_0x4ade27['diffData']=_0x1bf665['diffData'];});}}['_bufferUpdate'](_0x3f8d11,_0x218c50,_0x41ee83){if(this['_bufferedUpdates']['has'](_0x3f8d11)){const _0x1ef7b2=this['_bufferedUpdates']['get'](_0x3f8d11);_0x218c50=_0x41ee83?{..._0x1ef7b2,..._0x218c50}:{..._0x218c50,..._0x1ef7b2};}this['_bufferedUpdates']['set'](_0x3f8d11,_0x218c50);}['_getFromVersion'](_0x23fdee){const _0x20f94d=this['repository']['getRevisions']();_0x20f94d['reverse'](),_0x20f94d['shift']();const _0x535282=_0x20f94d['find'](_0x569107=>_0x569107['toVersion']<=_0x23fdee)['toVersion'];return _0x535282<this['_startingVersion']?this['_startingVersion']:_0x535282;}['_createInitialRevision'](_0x3de3ea){const _0x4218fe=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x4218fe)this['_initialRevisionId']=_0x4218fe['id'];else{const _0x526eb8=!this['editor']['model']['document']['roots']['find'](_0x2bdcf8=>this['editor']['model']['hasContent'](_0x2bdcf8)),_0x830e6c=this['editor']['plugins']['get']('Users')['me']['id'],_0x1d204a=m(this['editor']['locale'],_0x526eb8?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x3de3ea,'to':_0x3de3ea,'id':this['_initialRevisionId'],'name':_0x1d204a,'creatorId':_0x830e6c});}}['_createCurrentRevision'](_0xce1847){const _0x14b033=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x14b033),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0xce1847,'to':_0xce1847,'id':_0x14b033,'name':'','creatorId':null}));}['_makeRevision']({name:_0x17c1c2,from:_0x4d0997,to:_0x51cfd6,creatorId:_0x2729f2,id:_0x63d7dc}){const _0x4e3c54=this['buildRevisionData']({'from':_0x4d0997,'to':_0x51cfd6});_0x4e3c54['name']=_0x17c1c2,_0x4e3c54['creatorId']=_0x2729f2,_0x4e3c54['id']=_0x63d7dc;const _0x49a314=this['addRevisionData'](_0x4e3c54);return this['adapter']&&this['_bufferUpdate'](_0x4e3c54['id'],_0x4e3c54,!0x0),_0x49a314;}['_setConversion'](){this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'});}['_removeRevisionMarkers'](_0x19e4da){return(_0x19e4da=_0x19e4da['filter'](_0x38c10a=>!_0x38c10a['name']||'revision-start'!==_0x38c10a['name']&&'revision-end'!==_0x38c10a['name']))['forEach'](_0x2c9330=>{'string'!=typeof _0x2c9330&&(_0x2c9330['children']=this['_removeRevisionMarkers'](_0x2c9330['children']),_0x2c9330['attributes']=_0x2c9330['attributes']['filter'](_0x2c3a60=>!_0x2c3a60[0x0]['startsWith']('data-revision-')));}),_0x19e4da;}}function C(_0x345543,_0x3a8e0c){const _0x4a7c4e=_0x3a8e0c['editing']['view']['document'];if('string'==typeof _0x345543)return new _0x44c77c(_0x4a7c4e,_0x345543);{const _0x523174=_0x345543['children']['map'](_0x5f0814=>C(_0x5f0814,_0x3a8e0c));return new(P[_0x345543['type']]||_0x5e506b)(_0x4a7c4e,_0x345543['name'],_0x345543['attributes'],_0x523174);}}class V{['editor'];['source'];['_savedMetaData'];['_lastFrom'];['_lastTo'];['_markers'];['_diffRoots'];['_diffRootsAttributes'];['_baseRoots'];['_baseRootsAttributes'];['_idsRoots'];['_baseIdsRoots'];['_touched'];['_touchedMarkers'];['_touchedRoots'];['_revisionId'];['_startingRevisionId'];constructor(_0x26842f){this['editor']=_0x26842f,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'](_0xbd5c66){this['source']=_0xbd5c66;const _0x3af001=new Map(),_0x2a5253=new Map(),_0x521017=this['editor']['model']['document']['roots']['map'](_0x45add8=>_0x45add8['rootName']);for(const _0x2417e6 of _0x521017){const _0x1c7327=this['editor']['model']['document']['getRoot'](_0x2417e6),_0x46fe7f=T(_0x1c7327);_0x3af001['set'](_0x2417e6,_0x46fe7f),_0x2a5253['set'](_0x2417e6,Object['fromEntries'](_0x1c7327['getAttributes']()));}const _0x1729a5=Array['from'](this['editor']['model']['markers'])['map'](_0x3b511a=>[_0x3b511a['name'],_0x3b511a['getRange']()]),_0x22c2c7=this['source']['version'];this['_saveMetaData'](_0x22c2c7,_0x3af001,_0x1729a5,_0x2a5253),this['_startingRevisionId']=this['_revisionId'];const _0x4306bb=new Map(),_0xe95d2e=new Map();for(const _0x481e26 of _0x521017){const _0x230dea=F(_0x481e26);_0x4306bb['set'](_0x481e26,_0x230dea),_0xe95d2e['set'](_0x481e26,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x4306bb,[],_0xe95d2e);}['getData'](_0x542690,_0x2ae63a){if(this['_lastFrom']===_0x542690&&this['_lastTo']<=_0x2ae63a)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x2ae63a,!0x0);else{if(!this['_savedMetaData']['has'](_0x542690)){const _0x34174e=this['_getPreviousFrom'](_0x542690);this['_calculateMetaData'](_0x34174e,_0x542690,!0x1);}this['_calculateMetaData'](_0x542690,_0x2ae63a,!0x0);}return this['_lastFrom']=_0x542690,this['_lastTo']=_0x2ae63a,this['_getState']();}['loadState'](_0x138f27){this['_reset'](),this['_lastFrom']=_0x138f27['fromVersion'],this['_lastTo']=_0x138f27['toVersion'];for(const _0x55aa75 in _0x138f27['diffData']){const _0x6480b=_0x138f27['diffData'][_0x55aa75]['attachChange'],_0x2052d1=_0x57b19f(_0x138f27['diffData'][_0x55aa75]['attributesBefore'])||{},_0x50c529=this['_makeModelFromViewString'](_0x138f27['diffData'][_0x55aa75]['deletions']);_0x50c529['rootName']=_0x55aa75,_0x50c529['_isAttached']=!_0x6480b||!_0x6480b['isAttached'],_0x50c529['isAttached']=()=>_0x50c529['_isAttached'],this['_baseRoots']['set'](_0x55aa75,_0x50c529),this['_baseRootsAttributes']['set'](_0x55aa75,_0x2052d1),_0x6480b&&this['_touchedRoots']['set'](_0x55aa75,_0x6480b);const _0xcffd90=this['_makeIdsRoot'](_0x50c529);this['_baseIdsRoots']['set'](_0x55aa75,_0xcffd90);for(const [_0x49251c,_0x4812b6]of _0x50c529['markers']){if(!_0x49251c['startsWith']('revision:'))continue;const _0x19330d=_0x49251c['split'](':')[0x2];for(const _0x5c89b9 of _0x4812b6['getWalker']({'singleCharacters':!0x0})){const _0x395f34=this['_getVidAttributeName'](_0x5c89b9),_0x55106a='elementEnd'==_0x5c89b9['type']?_0x5c89b9['previousPosition']['path']['slice'](0x0,-0x1):_0x5c89b9['previousPosition']['path'],_0x3ad8d4=_0xcffd90['getNodeByPath'](_0x55106a)['getAttribute'](_0x395f34);this['_touched']['set'](_0x3ad8d4,{'userId':_0x19330d});}}}this['_startingRevisionId']=this['_revisionId'];const _0x2b6cb6=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x5f5717=>!this['_touched']['has'](_0x5f5717));let _0x24ad4b=0x0;const _0xa7bd93=new Map();for(const _0x2a7875 in _0x138f27['diffData']){const _0x389851=_0x138f27['diffData'][_0x2a7875]['attachChange'],_0x1041f1=_0x57b19f(_0x138f27['diffData'][_0x2a7875]['attributesAfter'])||{},_0x2ed8ba=this['_makeModelFromViewString'](_0x138f27['diffData'][_0x2a7875]['insertions']);_0x2ed8ba['rootName']=_0x2a7875,_0x2ed8ba['_isAttached']=!_0x389851||_0x389851['isAttached'],_0x2ed8ba['isAttached']=()=>_0x2ed8ba['_isAttached'],this['_diffRoots']['set'](_0x2a7875,_0x2ed8ba),this['_diffRootsAttributes']['set'](_0x2a7875,_0x1041f1);const _0x166e96=this['_makeIdsRoot'](_0x2ed8ba,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x2a7875,_0x166e96),_0xa7bd93['set'](_0x2a7875,_0x2ed8ba['isAttached']()?_0x1041f1:{});for(const [_0x4e1070,_0x2fd600]of _0x2ed8ba['markers']){if(!_0x4e1070['startsWith']('revision:'))continue;const _0x1dd0a9=_0x4e1070['split'](':')[0x2];for(const _0x13d19b of _0x2fd600['getWalker']({'singleCharacters':!0x0})){const _0xd329c9=this['_getVidAttributeName'](_0x13d19b),_0x1d3ad9=this['_revisionId']++,_0x334402='elementEnd'==_0x13d19b['type']?_0x13d19b['previousPosition']['path']['slice'](0x0,-0x1):_0x13d19b['previousPosition']['path'];_0x166e96['getNodeByPath'](_0x334402)['_setAttribute'](_0xd329c9,_0x1d3ad9),this['_touched']['set'](_0x1d3ad9,{'userId':_0x1dd0a9});}}for(const _0x15fa3c of this['editor']['model']['createRangeIn'](_0x2ed8ba)['getWalker']({'singleCharacters':!0x0})){const _0x1b2bfd=this['_getVidAttributeName'](_0x15fa3c),_0x47e884='elementEnd'==_0x15fa3c['type']?_0x15fa3c['previousPosition']['path']['slice'](0x0,-0x1):_0x15fa3c['previousPosition']['path'],_0x25562b=_0x166e96['getNodeByPath'](_0x47e884);_0x25562b['getAttribute'](_0x1b2bfd)>0x0||_0x25562b['_setAttribute'](_0x1b2bfd,_0x2b6cb6[_0x24ad4b++]);}for(const [_0x590cca,_0x4a08d8]of _0x2ed8ba['markers'])_0x590cca['startsWith']('revision:')||this['_markers']['set'](_0x590cca,_0x4a08d8);}const _0xd06755=F('$graveyard');this['_baseRoots']['set']('$graveyard',_0xd06755),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0xd06755,0x1));const _0x500cfb=F('$graveyard');this['_diffRoots']['set']('$graveyard',_0x500cfb),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x500cfb,0x1));const _0x20219c=Array['from'](this['_diffRoots'])['map'](([_0x37d8b3,_0x24cbad])=>[_0x37d8b3,T(_0x24cbad)]);this['_saveMetaData'](this['_lastTo'],_0x20219c,this['_markers'],_0xa7bd93);}['_makeModelFromViewString'](_0x4f4bda){const _0x1dd9f9=JSON['parse'](_0x4f4bda),_0xec73df=this['editor']['editing']['view']['document'],_0x59c56a=new _0x1f9cff(_0xec73df,_0x1dd9f9['map'](_0x2d7f46=>C(_0x2d7f46,this['editor'])));return this['editor']['data']['toModel'](_0x59c56a);}['_saveMetaData'](_0xb19fca,_0x30c102,_0x53e8bd,_0xd7d664){const _0x25e5c1=new Map(_0x30c102),_0xb3c18a=new Map(_0x57b19f(_0xd7d664)),_0x53cf83=new Map();for(const [_0x185bb5,_0x4967c6]of _0x53e8bd)_0x53cf83['set'](_0x185bb5,{'start':_0x4967c6['start']['clone'](),'end':_0x4967c6['end']['clone'](),'rootName':_0x4967c6['root']['rootName']});this['_savedMetaData']['set'](_0xb19fca,{'roots':_0x25e5c1,'markers':_0x53cf83,'rootsAttributes':_0xb3c18a});}['_removeMetaData'](_0xc8c1bf){this['_savedMetaData']['delete'](_0xc8c1bf);}['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'](_0x2f673e,_0xa906ad=null){let _0x15c8b9=null;_0x2f673e['is']('documentFragment')||(_0x15c8b9=new ft(_0x2f673e['name'],{'vid_start':null===_0xa906ad?this['_revisionId']++:_0xa906ad++}));const _0x14d84e=[];for(const _0x575912 of _0x2f673e['getChildren']())if(_0x575912['is']('element')){_0x14d84e['push'](this['_makeIdsRoot'](_0x575912,_0xa906ad));const _0x34c6e9=_0x14d84e[_0x14d84e['length']-0x1];null!==_0xa906ad&&(_0xa906ad=_0x34c6e9['is']('element','$text')?_0x34c6e9['getAttribute']('vid')+0x1:_0x34c6e9['getAttribute']('vid_end')+0x1);}else{for(let _0x317425=0x0;_0x317425<_0x575912['offsetSize'];_0x317425++)_0x14d84e['push'](new ft('$text',{'vid':null===_0xa906ad?this['_revisionId']++:_0xa906ad++}));}if(_0x2f673e['is']('documentFragment')){const _0x3702b7=F(_0x2f673e['rootName']);return _0x3702b7['_insertChild'](0x0,_0x14d84e),_0x3702b7;}return _0x15c8b9['_setAttribute']('vid_end',null===_0xa906ad?this['_revisionId']++:_0xa906ad++),_0x15c8b9['_insertChild'](0x0,_0x14d84e),_0x15c8b9;}['_calculateMetaData'](_0x391b66,_0x852c7a,_0x5dbe17){this['_reset']();const {roots:_0x4f3a3a,markers:_0x4d10cf,rootsAttributes:_0x3150d8}=this['_savedMetaData']['get'](_0x391b66);this['_baseRoots']=new Map(_0x4f3a3a),this['_baseRootsAttributes']=new Map(_0x57b19f(_0x3150d8));for(const [_0x1991de,_0x17bcbf]of this['_baseRoots'])if('$graveyard'!==_0x1991de&&(this['_diffRoots']['set'](_0x1991de,T(_0x17bcbf)),this['_diffRootsAttributes']=new Map(_0x57b19f(_0x3150d8)),_0x5dbe17)){const _0x4a6003=this['_revisionId'];this['_idsRoots']['set'](_0x1991de,this['_makeIdsRoot'](_0x17bcbf)),this['_baseIdsRoots']['set'](_0x1991de,this['_makeIdsRoot'](_0x17bcbf,_0x4a6003));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',T(this['_baseRoots']['get']('$graveyard'))),_0x5dbe17&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x3bcbcc,_0x5648d7]of _0x4d10cf){const _0x31bbcd=this['_baseRoots']['get'](_0x5648d7['rootName']),_0x11a644=this['_diffRoots']['get'](_0x5648d7['rootName']),_0x25c301=new vt(this['_fixPosition'](_0x5648d7['start'],_0x31bbcd),this['_fixPosition'](_0x5648d7['end'],_0x31bbcd)),_0x410a86=this['_fixRange'](_0x25c301,_0x11a644);_0x31bbcd['markers']['set'](_0x3bcbcc,_0x25c301),this['_markers']['set'](_0x3bcbcc,_0x410a86);}this['_applyOperations'](_0x391b66,_0x852c7a,_0x5dbe17);}['_applyOperations'](_0x37929f,_0x5dd760,_0x5996a7){for(const _0x5d7b32 of this['source']['getOperations'](_0x37929f,_0x5dd760))this['_handleOperation'](_0x5d7b32,_0x5996a7);for(const _0x3d3b6a of this['_diffRoots']['values']())_0x3d3b6a['markers']['clear']();for(const [_0x7b9aac,_0x5e59ba]of this['_markers']){this['_diffRoots']['get'](_0x5e59ba['root']['rootName'])['markers']['set'](_0x7b9aac,_0x5e59ba['clone']());}const _0x1fbc81=new Map(),_0x30b97e=new Map();for(const [_0x41917f,_0x495d54]of this['_diffRoots'])_0x1fbc81['set'](_0x41917f,T(_0x495d54)),_0x30b97e['set'](_0x41917f,this['_diffRootsAttributes']['get'](_0x41917f));this['_saveMetaData'](_0x5dd760,_0x1fbc81,this['_markers'],_0x30b97e);}['_getPreviousFrom'](_0x37d919){const _0x3c5f09=Array['from'](this['_savedMetaData']['keys']());_0x3c5f09['sort']((_0x2d0565,_0x53e783)=>_0x2d0565-_0x53e783),_0x3c5f09['reverse']();for(const _0x54163e of _0x3c5f09)if(_0x54163e<_0x37d919)return _0x54163e;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x239c08,_0x25dea5){const _0x3e2624=Array['from'](_0x25dea5['markers'])['map'](([_0x15171e,_0x361388])=>[_0x15171e,this['_fixRange'](_0x361388,_0x239c08)]);_0x239c08['markers']=new Map(_0x3e2624);}['_transformMarkers'](_0x5d2490){for(const _0x8781ad of this['_markers']['values']()){const _0x8abe53=_0x8781ad['getTransformedByOperation'](_0x5d2490),_0x4e3c95=vt['_createFromRanges'](_0x8abe53);_0x8781ad['start']=_0x4e3c95['start'],_0x8781ad['end']=_0x4e3c95['end'];}}['_handleOperation'](_0x1779c9,_0x25ef86){if('addRoot'!=_0x1779c9['type']&&'detachRoot'!=_0x1779c9['type']){if('insert'==_0x1779c9['type']){const _0x59eb61=_0x1779c9['position']['root']['rootName'];this['_diffRoots']['has'](_0x59eb61)||(this['_diffRoots']['set'](_0x59eb61,F(_0x59eb61,!0x0)),this['_diffRootsAttributes']['set'](_0x59eb61,{}),_0x25ef86&&this['_idsRoots']['set'](_0x59eb61,F(_0x59eb61,!0x0)));}else{if('addRootAttribute'==_0x1779c9['type']||'removeRootAttribute'==_0x1779c9['type']||'changeRootAttribute'==_0x1779c9['type'])return void this['_handleRootAttributeOperation'](_0x1779c9);'marker'==_0x1779c9['type']&&this['_handleMarkerOperation'](_0x1779c9);}if('marker'!==_0x1779c9['type']){const _0xfb9c68=this['_cloneOperation'](_0x1779c9,this['_diffRoots']);_0xfb9c68['_execute'](),this['_transformMarkers'](_0xfb9c68);}if(_0x25ef86)switch(_0x1779c9['type']){case'insert':this['_handleInsertOperation'](_0x1779c9);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x1779c9);break;case'merge':this['_handleMergeOperation'](_0x1779c9);break;case'split':this['_handleSplitOperation'](_0x1779c9);}}else this['_handleRootOperation'](_0x1779c9,_0x25ef86);}['_cloneOperation'](_0x35ddf4,_0x4fb78c){const _0x36c4b9=_0x35ddf4['clone']();return _0x36c4b9['_authorId']=_0x35ddf4['_authorId'],this['_fixOperation'](_0x36c4b9,_0x4fb78c),_0x36c4b9;}['_getBaseVids'](_0x399921){return _0x399921['map'](_0x4318c7=>{const _0x268107=this['_getVidAttributeName'](_0x4318c7);return Number(_0x4318c7['item']['getAttribute'](_0x268107));});}['_generateTape'](_0x345d00,_0x4849ba){if(_0x345d00['is']('element','$text'))_0x4849ba['push']({'item':_0x345d00,'type':'text'});else{_0x345d00['is']('element')&&_0x4849ba['push']({'item':_0x345d00,'type':'elementStart'});for(const _0x3121f7 of _0x345d00['getChildren']())this['_generateTape'](_0x3121f7,_0x4849ba);_0x345d00['is']('element')&&_0x4849ba['push']({'item':_0x345d00,'type':'elementEnd'});}return _0x4849ba;}['_getState'](){const _0xd0434f=new Map(this['_touched']),_0x21aedc=new Map(_0xd0434f),_0x423dd9=new Map(),_0x13a573={'insertions':{},'deletions':{}},_0x1405e2={'insertions':{},'deletions':{}},_0x305de4=new Map(),_0x349f85=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x349f85['delete']('$graveyard');for(const _0x80bb2f of _0x349f85){const _0x573edd=this['_diffRoots']['get'](_0x80bb2f)||F(_0x80bb2f,!0x1),_0x56e92c=this['_baseRoots']['get'](_0x80bb2f)||F(_0x80bb2f,!0x1);_0x573edd['isAttached']()||_0x56e92c['isAttached']()?(_0x13a573['insertions'][_0x80bb2f]=T(_0x573edd),_0x13a573['deletions'][_0x80bb2f]=T(_0x56e92c),this['_copyMarkers'](_0x13a573['deletions'][_0x80bb2f],_0x56e92c),this['_copyMarkers'](_0x13a573['insertions'][_0x80bb2f],_0x573edd),_0x1405e2['insertions'][_0x80bb2f]=this['_generateTape'](this['_idsRoots']['get'](_0x80bb2f),[]),_0x1405e2['deletions'][_0x80bb2f]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x80bb2f)||F(_0x80bb2f,!0x1),[])):_0x349f85['delete'](_0x80bb2f);}for(const _0x739a91 of _0x349f85){const _0x3d23ae=_0x1405e2['insertions'][_0x739a91];for(const _0x52b547 of _0x3d23ae){const _0x43bce8=this['_getVidAttributeName'](_0x52b547),_0x41de5d=_0x52b547['item']['getAttribute'](_0x43bce8);_0x21aedc['delete'](_0x41de5d),_0x41de5d>=this['_startingRevisionId']&&_0x423dd9['set'](_0x41de5d,_0xd0434f['get'](_0x41de5d));}}for(const _0x589cb1 of _0x349f85){const _0x2ce645=_0x1405e2['insertions'][_0x589cb1],_0x2eec6d=this['_getBaseVids'](_0x1405e2['deletions'][_0x589cb1]);let _0x31639d=0x0;for(const _0x12bdcb of _0x2ce645){const _0xe33307=this['_getVidAttributeName'](_0x12bdcb),_0x4470e8=_0x12bdcb['item']['getAttribute'](_0xe33307);if(!_0x423dd9['has'](_0x4470e8)&&!_0x305de4['has'](_0x4470e8)){if(_0x21aedc['has'](_0x4470e8))_0x31639d++;else{if(_0x4470e8!=_0x2eec6d[_0x31639d]){const _0xa32cc2=_0xd0434f['get'](_0x4470e8)||_0xd0434f['get'](_0x2eec6d[_0x31639d]);for(;_0x4470e8!=_0x2eec6d[_0x31639d];)_0x21aedc['has'](_0x2eec6d[_0x31639d])||(_0x305de4['set'](_0x2eec6d[_0x31639d],_0xa32cc2),_0xd0434f['set'](_0x2eec6d[_0x31639d],_0xa32cc2)),_0x31639d++;}_0x31639d++;}}}}for(const _0x440c3d of _0x349f85){const _0x18961b=_0x1405e2['insertions'][_0x440c3d];for(const _0x4c4964 of _0x18961b){const _0x35f987=this['_getVidAttributeName'](_0x4c4964),_0xf949a3=_0x4c4964['item']['getAttribute'](_0x35f987);if(_0x305de4['has'](_0xf949a3)){const _0x2c196f=_0x305de4['get'](_0xf949a3);_0x21aedc['has'](_0xf949a3)||_0x21aedc['set'](_0xf949a3,{..._0x2c196f}),_0x423dd9['set'](_0xf949a3,{..._0x2c196f});}}}for(const _0x3d0543 of _0x21aedc['keys']())_0x3d0543>=this['_startingRevisionId']&&_0x21aedc['delete'](_0x3d0543);const _0x373acf=new Map();for(const _0x482e63 of _0x349f85){let _0x1ef49f=_0x1405e2['insertions'][_0x482e63];for(const _0x2df2da of _0x1ef49f)if(_0x2df2da['item']['is']('element','tableCell')){const _0x26e4f3=this['_getVidAttributeName'](_0x2df2da),_0x228bbb=_0x2df2da['item']['getAttribute'](_0x26e4f3);if(_0x423dd9['has'](_0x228bbb)){const _0x3b76d8=_0x2df2da['item']['parent']['parent']['getAttribute']('vid_start'),_0x5d03a4=_0x373acf['get'](_0x3b76d8)||new Set();_0x5d03a4['add'](_0x423dd9['get'](_0x228bbb)['userId']),_0x373acf['set'](_0x3b76d8,_0x5d03a4);}}_0x1ef49f=_0x1405e2['deletions'][_0x482e63];for(const _0x4a7d57 of _0x1ef49f)if(_0x4a7d57['item']['is']('element','tableCell')){const _0x1d4b23=this['_getVidAttributeName'](_0x4a7d57),_0x3d4714=_0x4a7d57['item']['getAttribute'](_0x1d4b23);if(_0x21aedc['has'](_0x3d4714)){const _0x43ff47=_0x4a7d57['item']['parent']['parent']['getAttribute']('vid_start'),_0x277ea5=_0x373acf['get'](_0x43ff47)||new Set();_0x277ea5['add'](_0x21aedc['get'](_0x3d4714)['userId']),_0x373acf['set'](_0x43ff47,_0x277ea5);}}for(const _0x27f2af of _0x373acf['keys']())(_0x423dd9['has'](_0x27f2af)||_0x21aedc['has'](_0x27f2af))&&_0x373acf['delete'](_0x27f2af);}for(const _0x53d940 of _0x349f85){const _0x50338f=_0x1405e2['insertions'][_0x53d940];let _0x3693e6=null,_0x41a3b4=null;for(const _0x2f78bc of _0x50338f){const _0x2b45c5=this['_getVidAttributeName'](_0x2f78bc),_0x2ca991=_0x2f78bc['item']['getAttribute'](_0x2b45c5),_0x50543c=_0x373acf['get'](_0x2ca991);_0x50543c&&'elementStart'==_0x2f78bc['type']&&(_0x3693e6=Array['from'](_0x50543c)[0x0],_0x41a3b4=_0x2f78bc['item']['getAttribute']('vid_end')),_0x3693e6&&(_0x21aedc['set'](_0x2ca991,{'userId':_0x3693e6}),_0x423dd9['set'](_0x2ca991,{'userId':_0x3693e6})),_0x2ca991==_0x41a3b4&&(_0x3693e6=null,_0x41a3b4=null);}}const _0x10db27={},_0x11ac76=new Set();for(const _0x2865b3 of _0x349f85){const _0x4e85e5=_0x13a573['deletions'][_0x2865b3],_0x122654=_0x13a573['insertions'][_0x2865b3];for(const {userId:_0x1b8d9a}of this['_touchedMarkers']['values']())null!==_0x1b8d9a&&_0x11ac76['add'](_0x1b8d9a);for(const {userId:_0x30599c}of this['_touchedRoots']['values']())null!==_0x30599c&&_0x11ac76['add'](_0x30599c);this['_markChanges'](_0x122654,_0x1405e2['insertions'][_0x2865b3],_0x423dd9,'insertion',_0x11ac76),this['_markChanges'](_0x4e85e5,_0x1405e2['deletions'][_0x2865b3],_0x21aedc,'deletion',_0x11ac76),_0x10db27[_0x2865b3]={'insertions':this['_prepareViewToSave'](_0x122654),'deletions':this['_prepareViewToSave'](_0x4e85e5),'attachChange':this['_touchedRoots']['get'](_0x2865b3)||null,'attributesBefore':_0x57b19f(this['_baseRootsAttributes']['get'](_0x2865b3))||{},'attributesAfter':_0x57b19f(this['_diffRootsAttributes']['get'](_0x2865b3))};}return{'diffData':_0x10db27,'authorsIds':Array['from'](_0x11ac76)};}['_processRootBeforeSave'](_0x57db83){for(const [,_0xc28bec]of _0x57db83['markers']){const _0x1fd60c=_0xc28bec['start']['getAncestors']()['filter'](_0x27fe80=>'tableCell'==_0x27fe80['name']);for(const _0x45d43a of _0x1fd60c)0x1==_0x45d43a['childCount']&&_0x45d43a['getChild'](0x0)['is']('element','paragraph')&&_0x45d43a['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x28625d){this['_processRootBeforeSave'](_0x28625d);const _0x493520=this['editor']['data']['toView'](_0x28625d,{}),_0x52c225=Array['from'](_0x493520['getChildren']())['map'](_0x486c12=>this['_getViewJson'](_0x486c12));return JSON['stringify'](_0x52c225);}['_getViewJson'](_0x2e0231){if(_0x2e0231['is']('$text'))return _0x2e0231['data'];{const _0x5a4fc8=_0x2e0231;return{'type':Object['keys'](P)['find'](_0x163a3c=>_0x2e0231 instanceof P[_0x163a3c]),'name':_0x5a4fc8['name'],'attributes':Array['from'](_0x5a4fc8['getAttributes']()),'children':Array['from'](_0x5a4fc8['getChildren']())['map'](_0xa76aee=>this['_getViewJson'](_0xa76aee))};}}['_markChanges'](_0xd13c80,_0x21f82e,_0xca0c10,_0x2ff862,_0x1d4eb2){let _0x5d32f0=null,_0xd12c0d=null,_0x18e31a=0x0;const _0x295250=this['editor']['model'];for(let _0x2d8b3b=0x0;_0x2d8b3b<_0x21f82e['length'];_0x2d8b3b++){const _0x5985e4=this['_getVidAttributeName'](_0x21f82e[_0x2d8b3b]),_0xbb1650=_0x21f82e[_0x2d8b3b]['item']['getAttribute'](_0x5985e4),_0x5b0cfd=_0xca0c10['get'](_0xbb1650),_0x40ffd8=_0x2d8b3b==_0x21f82e['length']-0x1;(!_0x5d32f0&&_0x5b0cfd&&(_0x5d32f0=_0x5b0cfd,_0xd12c0d=_0x21f82e[_0x2d8b3b]),_0x5d32f0&&(!_0x5b0cfd||_0x5b0cfd['userId']!=_0x5d32f0['userId']))&&(_0x3b19a1(_0x5b0cfd,B(_0xd12c0d,_0xd13c80,_0x295250),B(_0x21f82e[_0x2d8b3b],_0xd13c80,_0x295250)),_0x5d32f0=_0x5b0cfd||null,_0xd12c0d=_0x5b0cfd?_0x21f82e[_0x2d8b3b]:null),_0x5d32f0&&_0x40ffd8&&_0x3b19a1(_0x5b0cfd,B(_0xd12c0d,_0xd13c80,_0x295250),J(_0x21f82e[_0x2d8b3b],_0xd13c80,_0x295250));}function _0x3b19a1(_0x4eab06,_0x495dd8,_0x57c493){const _0x558e50=_0x5d32f0['userId'],_0x1a9c61='revision:'+_0x2ff862+':'+_0x558e50+':'+_0x18e31a++,_0x4b9482=_0x295250['createRange'](_0x495dd8,_0x57c493);_0xd13c80['markers']['set'](_0x1a9c61,_0x4b9482),null!==_0x558e50&&_0x1d4eb2['add'](_0x558e50);}}['_getVidAttributeName'](_0x466a8b){switch(_0x466a8b['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0xb696f1,_0x5059f){_0xb696f1['baseVersion']=null;for(const _0x220e18 in _0xb696f1){const _0x3c9615=_0xb696f1[_0x220e18];if(_0x3c9615 instanceof gt){const _0x3a0f1d=_0x5059f['get'](_0x3c9615['root']['rootName']);_0xb696f1[_0x220e18]=this['_fixPosition'](_0x3c9615,_0x3a0f1d);}if(_0x3c9615 instanceof vt){const _0x4d34fa=_0x5059f['get'](_0x3c9615['root']['rootName']);_0xb696f1[_0x220e18]=this['_fixRange'](_0x3c9615,_0x4d34fa);}'root'===_0x220e18&&(_0xb696f1['root']=_0x5059f['get'](_0xb696f1['root']['rootName']));}}['_fixRange'](_0x292fe7,_0x497ea5){return this['editor']['model']['createRange'](this['_fixPosition'](_0x292fe7['start'],_0x497ea5),this['_fixPosition'](_0x292fe7['end'],_0x497ea5));}['_fixPosition'](_0x3ee0ef,_0x168e37){return this['editor']['model']['createPositionFromPath'](_0x168e37,_0x3ee0ef['path'],_0x3ee0ef['stickiness']);}['_handleInsertOperation'](_0x3e83f4){const _0x230c0e=this['_idsRoots']['get'](_0x3e83f4['position']['root']['rootName']),_0x20e8e7=this['_fixPosition'](_0x3e83f4['position'],_0x230c0e),_0x509f84=null===_0x3e83f4['_authorId']?null:_0x3e83f4['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x2bba4d=_0x20e8e7['parent'],_0x554075=this['_revisionId'],_0x421cd0=[];for(const _0x13b08f of _0x3e83f4['nodes'])if(_0x13b08f['is']('element'))_0x421cd0['push'](this['_makeIdsRoot'](_0x13b08f));else{for(let _0x3d025b=0x0;_0x3d025b<_0x13b08f['offsetSize'];_0x3d025b++)_0x421cd0['push'](new ft('$text',{'vid':this['_revisionId']++}));}const _0x3dc419=this['_revisionId'];for(let _0x2f3d65=_0x554075;_0x2f3d65<_0x3dc419;_0x2f3d65++)this['_touched']['set'](_0x2f3d65,{'userId':_0x509f84});_0x2bba4d['_insertChild'](_0x20e8e7['offset'],_0x421cd0);}['_handleMoveOperation'](_0x3c3046){(_0x3c3046=this['_cloneOperation'](_0x3c3046,this['_idsRoots']))['_execute']();const _0x31b612=null===_0x3c3046['_authorId']?null:_0x3c3046['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x2a68ab=_0x3c3046['getMovedRangeStart'](),_0x2a5524=_0x2a68ab['parent'],_0x2f13ee=_0x2a68ab['offset'];!function _0x1d67e3(_0x168dae,_0xfb766c,_0x5e7833,_0x33d3a9){for(let _0x5e9bdc=_0x5e7833;_0x5e9bdc<_0x33d3a9;_0x5e9bdc++){const _0x39a4a4=_0xfb766c['getChild'](_0x5e9bdc);_0x39a4a4['is']('element','$text')?_0x168dae['set'](_0x39a4a4['getAttribute']('vid'),{'userId':_0x31b612}):(_0x168dae['set'](_0x39a4a4['getAttribute']('vid_start'),{'userId':_0x31b612}),_0x1d67e3(_0x168dae,_0x39a4a4,0x0,_0x39a4a4['childCount']),_0x168dae['set'](_0x39a4a4['getAttribute']('vid_end'),{'userId':_0x31b612}));}}(this['_touched'],_0x2a5524,_0x2f13ee,_0x2f13ee+_0x3c3046['howMany']);}['_handleMergeOperation'](_0x2038ca){const _0xc9dfef=null===(_0x2038ca=this['_cloneOperation'](_0x2038ca,this['_idsRoots']))['_authorId']?null:_0x2038ca['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x8f20e8=_0x2038ca['targetPosition']['parent'],_0x2f8e5c=_0x2038ca['sourcePosition']['parent'],_0x109bab=_0x8f20e8['getAttribute']('vid_end'),_0xe89a86=_0x2f8e5c['getAttribute']('vid_start');_0x8f20e8['_setAttribute']('vid_end',_0x2f8e5c['getAttribute']('vid_end')),_0x2f8e5c['_setAttribute']('vid_end',_0x109bab),this['_touched']['set'](_0xe89a86,{'userId':_0xc9dfef}),this['_touched']['set'](_0x109bab,{'userId':_0xc9dfef}),_0x2038ca['_execute']();}['_handleSplitOperation'](_0x499069){const _0x412586=null===(_0x499069=this['_cloneOperation'](_0x499069,this['_idsRoots']))['_authorId']?null:_0x499069['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x1b1b0b=_0x499069['graveyardPosition'],_0x2bfb9f=_0x499069['splitPosition']['parent'];_0x499069['_execute']();const _0x3273a5=_0x2bfb9f['getAttribute']('vid_end'),_0x4c24ce=_0x499069['insertionPosition']['nodeAfter'];if(_0x1b1b0b){const _0x364a40=_0x4c24ce['getAttribute']('vid_end'),_0x44cd46=_0x2bfb9f['getAttribute']('vid_end');_0x2bfb9f['_setAttribute']('vid_end',_0x364a40),_0x4c24ce['_setAttribute']('vid_end',_0x44cd46),this['_touched']['set'](_0x2bfb9f['getAttribute']('vid_end'),{'userId':_0x412586}),this['_touched']['set'](_0x4c24ce['getAttribute']('vid_start'),{'userId':_0x412586});}else{const _0x3b8ae5=this['_revisionId']++,_0xb5c5ad=this['_revisionId']++;_0x2bfb9f['_setAttribute']('vid_end',_0x3b8ae5),_0x4c24ce['_setAttribute']('vid_start',_0xb5c5ad),_0x4c24ce['_setAttribute']('vid_end',_0x3273a5),this['_touched']['set'](_0x3b8ae5,{'userId':_0x412586}),this['_touched']['set'](_0xb5c5ad,{'userId':_0x412586});}}['_handleMarkerOperation'](_0x133ffe){if(!_0x133ffe['affectsData'])return;const _0x473514=(_0x133ffe=this['_cloneOperation'](_0x133ffe,this['_diffRoots']))['oldRange']?_0x133ffe['oldRange']['root']:null,_0x14807b=_0x133ffe['newRange']?_0x133ffe['newRange']['root']:null;_0x473514&&this['_markers']['delete'](_0x133ffe['name']),_0x14807b&&this['_markers']['set'](_0x133ffe['name'],_0x133ffe['newRange']['clone']());const _0x302607=null===_0x133ffe['_authorId']?null:_0x133ffe['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x20a17e=_0x133ffe['name'];if(!this['_touchedMarkers']['has'](_0x20a17e))return void this['_touchedMarkers']['set'](_0x20a17e,{'range':_0x133ffe['oldRange'],'userId':_0x302607});const _0x5f5cec=this['_touchedMarkers']['get'](_0x20a17e),_0x5c6edc=_0x5f5cec['range'],_0x1b6c98=_0x133ffe['newRange'];null==_0x5c6edc&&null==_0x1b6c98||_0x5c6edc&&_0x1b6c98&&_0x5c6edc['isEqual'](_0x1b6c98)?this['_touchedMarkers']['delete'](_0x133ffe['name']):_0x5f5cec['userId']=_0x302607;}['_handleRootOperation'](_0x4eba68,_0x5ba95c){this['_diffRoots']['has'](_0x4eba68['rootName'])?this['_diffRoots']['get'](_0x4eba68['rootName'])['_isAttached']=_0x4eba68['isAdd']:(this['_diffRoots']['set'](_0x4eba68['rootName'],F(_0x4eba68['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x4eba68['rootName'],{}),_0x5ba95c&&this['_idsRoots']['set'](_0x4eba68['rootName'],F(_0x4eba68['rootName'],!0x0)));const _0x51c73b=null===_0x4eba68['_authorId']?null:_0x4eba68['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x5be160=this['_touchedRoots']['get'](_0x4eba68['rootName']);_0x5be160&&_0x5be160['userId']===_0x51c73b?this['_touchedRoots']['delete'](_0x4eba68['rootName']):this['_touchedRoots']['set'](_0x4eba68['rootName'],{'userId':_0x51c73b,'isAttached':_0x4eba68['isAdd']});}['_handleRootAttributeOperation'](_0x460c84){const _0xfc94b1=this['_diffRootsAttributes']['get'](_0x460c84['root']['rootName']);null===_0x460c84['newValue']?delete _0xfc94b1[_0x460c84['key']]:_0xfc94b1[_0x460c84['key']]=_0x460c84['newValue'];}}function T(_0x2469fd){const _0x47d714=F(_0x2469fd['rootName'],_0x2469fd['isAttached']());for(const _0x460cda of _0x2469fd['getChildren']()){const _0x13858d=_0x460cda['_clone'](!0x0);_0x47d714['_appendChild'](_0x13858d);}return _0x47d714;}function F(_0x18b905,_0x28dd66=!0x0){const _0x317964=new mt();return _0x317964['rootName']=_0x18b905,_0x317964['_isAttached']=_0x28dd66,_0x317964['isAttached']=()=>_0x317964['_isAttached'],_0x317964;}function B(_0xd57a8a,_0x23b726,_0x2278e8){const _0x1c4262='elementEnd'==_0xd57a8a['type']?_0x2278e8['createPositionAt'](_0xd57a8a['item'],'end'):_0x2278e8['createPositionBefore'](_0xd57a8a['item']);return _0x2278e8['createPositionFromPath'](_0x23b726,_0x1c4262['path'],_0x1c4262['stickiness']);}function J(_0xbd5861,_0xb9f26b,_0x307a51){const _0x44a1f6='elementStart'==_0xbd5861['type']?_0x307a51['createPositionAt'](_0xbd5861['item'],0x0):_0x307a51['createPositionAfter'](_0xbd5861['item']);return _0x307a51['createPositionFromPath'](_0xb9f26b,_0x44a1f6['path'],_0x44a1f6['stickiness']);}class ns extends _0x1331b6{['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x3ea721,_0x482cc7){super(_0x3ea721),this['focusTracker']=new _0x3e6025(),this['keystrokes']=new _0x61f9fd(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x482cc7),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'](),_0x1a34ad({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x312d18=_0x482b05=>_0x482b05['stopPropagation']();this['keystrokes']['set']('arrowright',_0x312d18),this['keystrokes']['set']('arrowleft',_0x312d18),this['keystrokes']['set']('arrowup',_0x312d18),this['keystrokes']['set']('arrowdown',_0x312d18);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x40e047){this['revisionNameInputView']['fieldView']['element']['value']=_0x40e047['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x2b9d53){const _0x301991=new nt(this['locale'],_0x1f5698),_0x4f2192=_0x301991['fieldView'];_0x4f2192['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x5a17e2=m(this['locale'],'Name\x20of\x20the\x20revision');return!_0x2b9d53&&(_0x5a17e2+='\x20('+m(this['locale'],'optional')+')'),(_0x301991['label']=_0x5a17e2,_0x4f2192['on']('input',()=>{this['revisionNameInputValue']=_0x4f2192['element']['value']['trim']();}),_0x301991);}}class u extends _0xc00adc{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l];}['_saveRevisionFormView'];['init'](){const _0x5672ae=this['editor'],_0x5b5603=_0x5672ae['plugins']['get']('RevisionTracker');_0x5672ae['ui']['componentFactory']['add']('revisionHistory',_0x3183ad=>{const _0x112225=_0x336529(_0x3183ad),_0x4b51ae=_0x112225['panelView']['children'],_0x2910b0=new te(_0x3183ad),_0x34f090=new _0x339771(_0x3183ad),_0x34e939=new _0x46ea5a(_0x3183ad),_0x4ebab8=new _0x339771(_0x3183ad),_0x4b5d24=new _0x46ea5a(_0x3183ad);return _0x112225['bind']('isEnabled')['to'](_0x5b5603,'isReady',_0x5b5603,'isEnabled',_0x5672ae,'isReadOnly',(_0xd4647e,_0x3f95c3,_0x137bf6)=>_0xd4647e&&_0x3f95c3&&!_0x137bf6),_0x112225['buttonView']['set']({'icon':_0xd99ff4['history'],'label':m(_0x3183ad,'Revision\x20history'),'tooltip':!0x0}),_0x34e939['set']({'label':m(_0x3183ad,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x34e939['bind']('isEnabled')['to'](_0x5b5603,'isReady',_0x5b5603,'isEnabled',_0x5672ae,'isReadOnly',(_0x3c45d7,_0x54cd92,_0x4e9366)=>_0x3c45d7&&_0x54cd92&&!_0x4e9366),_0x34e939['on']('execute',()=>this['_showDialog']()),_0x4b5d24['set']({'label':m(_0x3183ad,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x4b5d24['bind']('isEnabled')['to'](_0x5b5603,'isReady',_0x5672ae,'isReadOnly',(_0x5419c7,_0x25fbfe)=>_0x5419c7&&!_0x25fbfe),_0x4b5d24['on']('execute',()=>{_0x5672ae['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x112225['isOpen']=!0x1,_0x5672ae['editing']['view']['focus']();}),_0x34f090['children']['add'](_0x34e939),_0x4ebab8['children']['add'](_0x4b5d24),_0x2910b0['role']='menu',_0x2910b0['items']['addMany']([_0x34f090,_0x4ebab8]),_0x4b51ae['add'](_0x2910b0),_0x112225;}),_0x5672ae['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x5230d8=this['editor'],_0x4672c9=_0x5230d8['locale'],_0x4030bb=new _0x5f334e(_0x4672c9),_0x50a970=new _0x4bc53c(_0x4672c9);_0x4030bb['buttonView']['set']({'icon':_0xd99ff4['history'],'label':m(_0x4672c9,'Revision\x20history')});const _0x2f40a7=new _0x4c0e56(_0x4672c9,_0x4030bb),_0x566868=new _0xf0069e(_0x4672c9);_0x566868['set']({'label':m(_0x4672c9,'Save\x20current\x20revision')}),_0x566868['delegate']('execute')['to'](_0x4030bb),_0x566868['on']('execute',()=>{this['_showDialog']();}),_0x2f40a7['children']['add'](_0x566868),_0x50a970['items']['add'](_0x2f40a7);const _0x1ed324=new _0x4c0e56(_0x4672c9,_0x4030bb),_0x2a8980=new _0xf0069e(_0x4672c9);return _0x2a8980['set']({'label':m(_0x4672c9,'Open\x20revision\x20history')}),_0x2a8980['delegate']('execute')['to'](_0x4030bb),_0x2a8980['on']('execute',()=>{_0x5230d8['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x1ed324['children']['add'](_0x2a8980),_0x50a970['items']['add'](_0x1ed324),_0x4030bb['panelView']['children']['add'](_0x50a970),_0x4030bb;}['_showDialog'](){const _0x24c9fc=this['editor'],_0x1425b4=_0x24c9fc['locale'],_0x4e5bc1=_0x24c9fc['plugins']['get']('Dialog'),_0x410298=_0x24c9fc['plugins']['get']('RevisionTracker');function _0x2e1fe9(_0x4ee48f){_0x24c9fc['config']['get']('revisionHistory.requireRevisionName')&&''===_0x4ee48f['revisionName']?_0x4ee48f['revisionNameInputView']['errorText']=m(_0x1425b4,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x24c9fc['plugins']['get'](l)['saveRevision']({'name':_0x4ee48f['revisionName']}),_0x4e5bc1['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x2e1fe9(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x4e5bc1['show']({'id':'revisionSave','title':m(_0x1425b4,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':m(_0x24c9fc['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x4e5bc1['hide']()},{'label':m(_0x24c9fc['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x277b1d){_0x277b1d['bind']('isEnabled')['to'](_0x410298,'isReady',_0x410298,'isEnabled',_0x24c9fc,'isReadOnly',(_0x46f16d,_0x55ec3b,_0x2b28ca)=>_0x46f16d&&_0x55ec3b&&!_0x2b28ca);},'onExecute':()=>_0x2e1fe9(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x348f07=this['editor'],_0xb2ed3d=_0x348f07['locale'];this['_saveRevisionFormView']=new ns(_0xb2ed3d,_0x348f07['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class X extends _0x1331b6{['changeId'];['_model'];constructor(_0x2e514d,_0x268a01){super(_0x2e514d),this['_model']=_0x268a01,this['changeId']=_0x268a01['id'];const _0x358a53=this['bindTemplate'],_0x5de050=m(_0x2e514d,_0x268a01['data']['isSuggestion']?'Suggested\x20by':'add'==_0x268a01['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x268a01['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x358a53['to']('type',_0x10b27f=>'ck-revision-change__'+_0x10b27f)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x5de050}]},{'text':'\x20'+_0x268a01['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class r extends/* #__PURE__ -- @preserve */
|
|
25
|
-
_0x45eadb(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x589b6b){super(),this['id']=_0x589b6b['id']||_0x49b9a1(),this['author']=_0x589b6b['author'],this['type']=_0x589b6b['type'],this['data']=_0x589b6b['data']||{},this['rootName']=_0x589b6b['rootName'],this['set']('createdAt',_0x589b6b['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(_0x166cfc,_0x248776){this['newRevisionId']=_0x166cfc,this['oldRevisionId']=_0x248776,this['changes']=new _0x43846a();}['_setChanges'](_0x273749){for(const _0x2a7735 of _0x273749)this['changes']['add'](_0x2a7735);}}const Y={'c':_0xaeeac4,'a':_0x388953,'e':_0x3a7bef,'r':_0x52a07e,'u':_0x44a4f8};class d extends _0xc00adc{['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[_0x926ed0,_0x33ed31,j];}constructor(_0x404c27){super(_0x404c27),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',(_0x41da0a,_0x54aabc,_0x275e77)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x4159bd=>{for(const _0x4217de of this['editor']['editing']['view']['document']['roots'])_0x275e77?_0x4159bd['removeClass']('ck-editor__editable__overlay',_0x4217de):_0x4159bd['addClass']('ck-editor__editable__overlay',_0x4217de);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x3732cb=>null!==_0x3732cb),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x992c0c,_0x4069b1,_0x3b5cc7)=>_0x992c0c&&_0x3b5cc7?_0x4069b1['changes']['getIndex'](_0x3b5cc7):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x1974c0,_0x1657f7)=>_0x1974c0?_0x1657f7['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['adapter']=null,this['_balloon']=this['editor']['plugins']['get'](_0x33ed31);}['init'](){const _0x402302=this['editor'],_0xf7d260=new yt(_0x402302,{'direction':'backward'}),_0x26cec2=new yt(_0x402302,{'direction':'forward'});(_0x402302['commands']['add']('showPreviousChange',_0xf7d260),_0x402302['commands']['add']('showNextChange',_0x26cec2),_0x402302['commands']['add']('restoreRevision',new _t(_0x402302)),this['on']('change:numberOfChanges',()=>{_0xf7d260['refresh'](),_0x26cec2['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x402302['enableReadOnlyMode']('revision-viewer'),_0x402302['plugins']['has']('WidgetToolbarRepository'))&&_0x402302['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionData'](_0xa489c0){await this['loadRevisionData'](_0xa489c0);const _0x3768ca={};for(const _0x59ce63 in _0xa489c0['diffData']){if(_0xa489c0['diffData'][_0x59ce63]['attachChange']&&!_0xa489c0['diffData'][_0x59ce63]['attachChange']['isAttached'])continue;const _0x12041=this['_removeRevisionMarkers'](JSON['parse'](_0xa489c0['diffData'][_0x59ce63]['insertions'])),_0x252ce7=this['editor']['editing']['view']['document'],_0x15248d=new _0x1f9cff(_0x252ce7,_0x12041['map'](_0x3e1984=>this['_getViewObj'](_0x3e1984)));this['editor']['data']['processor']['useFillerType']('marked'),_0x3768ca[_0x59ce63]=this['editor']['data']['processor']['toData'](_0x15248d),this['editor']['data']['processor']['useFillerType']('default');}return _0x3768ca;}async['getRevisionRootsAttributes'](_0xecb00d){await this['loadRevisionData'](_0xecb00d);const _0x538439={};for(const _0x432cbd in _0xecb00d['diffData'])_0xecb00d['diffData'][_0x432cbd]['attachChange']&&!_0xecb00d['diffData'][_0x432cbd]['attachChange']['isAttached']||(_0x538439[_0x432cbd]=_0xecb00d['diffData'][_0x432cbd]['attributesAfter']||{});return _0x538439;}['_removeRevisionMarkers'](_0x45290d){return(_0x45290d=_0x45290d['filter'](_0x4e2b13=>!_0x4e2b13['name']||'revision-start'!==_0x4e2b13['name']&&'revision-end'!==_0x4e2b13['name']))['forEach'](_0x40b8a6=>{'string'!=typeof _0x40b8a6&&(_0x40b8a6['children']=this['_removeRevisionMarkers'](_0x40b8a6['children']),_0x40b8a6['attributes']=_0x40b8a6['attributes']['filter'](_0x49ef63=>!_0x49ef63[0x0]['startsWith']('data-revision-')));}),_0x45290d;}async['compare'](_0x34325c,_0x3fbac2,_0x4ce582=!0x1){if(!this['isEnabled'])return;const _0x1e4f1d=this['diff'],_0x7d111e=this['repository'],_0x2e1791='string'==typeof _0x34325c?_0x7d111e['getRevision'](_0x34325c):_0x34325c,_0x387ed6='string'==typeof _0x3fbac2?_0x7d111e['getRevision'](_0x3fbac2):_0x3fbac2,_0x106de0=_0x2e1791['id'],_0x4c21e0=_0x387ed6?_0x387ed6['id']:null;if(!_0x4ce582&&this['diff']&&this['diff']['newRevisionId']===_0x106de0&&this['diff']['oldRevisionId']===_0x4c21e0)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new f(_0x106de0,_0x4c21e0);const _0x2b2faf=this['_getRevisionsRange'](_0x2e1791,_0x387ed6,!0x0)['map'](_0x2e6951=>this['loadRevisionData'](_0x2e6951));return _0x2b2faf['push'](new Promise(_0x4c9b70=>{setTimeout(_0x4c9b70,0x14);})),Promise['all'](_0x2b2faf)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x2923df=this['_getDiff'](_0x106de0,_0x4c21e0);for(const _0x16f45a of _0x2923df['changes'])this['_changeIdToChange']['set'](_0x16f45a['id'],_0x16f45a);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x1cc3eb=>{for(const _0x42af11 of this['editor']['model']['document']['getRootNames']())_0x1cc3eb['detachRoot'](_0x42af11);for(const _0x503f0d of Object['keys'](_0x2923df['model'])){const _0x2918b4=_0x1cc3eb['addRoot'](_0x503f0d);for(const _0xc27972 of Object['keys'](_0x2923df['attributes'][_0x503f0d]))_0x1cc3eb['setAttribute'](_0xc27972,_0x2923df['attributes'][_0x503f0d][_0xc27972],_0x2918b4);_0x1cc3eb['insert'](_0x2923df['model'][_0x503f0d],_0x2918b4,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x2923df['changes'])),this['isReady']=!0x0;})['catch'](_0x4bb750=>{console['error'](_0x4bb750),this['_cleanUp'](),_0x1e4f1d&&(this['diff']=_0x1e4f1d),this['isReady']=!0x0;});}['addRevisionData'](_0x2f5499,_0x3fc3d7){const _0x1e7711=this['repository']['createRevision'](_0x2f5499);return _0x1e7711['on']('_update',(_0x39ceda,_0x389069,_0x529e4c)=>_0x3fc3d7(_0x389069,_0x529e4c,_0x1e7711)),this['repository']['addRevision'](_0x1e7711),_0x1e7711;}['loadRevisionData'](_0x211233){if(!_0x211233||_0x211233['diffData'])return Promise['resolve']();{const _0x369fd7=this['editor']['config']['get']('collaboration.channelId');return this['adapter']['getRevision']({'channelId':_0x369fd7,'revisionId':_0x211233['id']})['then'](_0x2398d5=>{_0x211233['_update']({'diffData':_0x2398d5['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},_0x3e4d43=>{for(const _0x41931b of this['editor']['model']['document']['getRootNames']())_0x3e4d43['detachRoot'](_0x41931b);});}['_sortAndFilterDiffChanges'](_0x421ced){const _0x38081e=[],_0x420aef=new Map();for(const _0x1c7d6f of this['editor']['model']['document']['getRootNames']()){const _0x56b893=this['editor']['editing']['view']['getDomRoot'](_0x1c7d6f);if(!_0x56b893)continue;const _0x1e0633=_0x56b893['getClientRects']()['item'](0x0);_0x1e0633&&(_0x38081e['push'](_0x1c7d6f),_0x420aef['set'](_0x1c7d6f,_0x1e0633));}return _0x38081e['sort']((_0x1cb76b,_0x8df25d)=>{const _0xc70d60=_0x420aef['get'](_0x1cb76b),_0x133793=_0x420aef['get'](_0x8df25d);return _0xc70d60['y']-_0x133793['y']||_0xc70d60['x']-_0x133793['x'];}),(_0x421ced=_0x421ced['filter'](_0x442244=>_0x38081e['includes'](_0x442244['rootName'])))['sort']((_0x1e4773,_0x23f005)=>_0x38081e['indexOf'](_0x1e4773['rootName'])-_0x38081e['indexOf'](_0x23f005['rootName'])),_0x421ced;}['_makeTape'](_0x280e88){const _0x1bab6e=Array['from'](_0x280e88['markers'])['filter'](([_0x154cd2,_0x1a239c])=>_0x154cd2['startsWith']('revision:')&&!_0x1a239c['isCollapsed']),_0xd8a746=Array['from'](this['editor']['model']['createRangeIn'](_0x280e88)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x1bab6e['length'])for(const _0x1e7189 of _0xd8a746){const [_0x3f41a6,_0x1a70a8]=_0x1bab6e[0x0],[,_0x286398,_0xce172c]=_0x3f41a6['split'](':');if(_0x1a70a8['end']['isEqual'](_0x1e7189['nextPosition'])&&_0x1bab6e['shift'](),(_0x1e7189['previousPosition']['isEqual'](_0x1a70a8['start'])||_0x1e7189['previousPosition']['isAfter'](_0x1a70a8['start']))&&('insertion'==_0x286398?_0x1e7189['isAdded']={'userId':_0xce172c}:'deletion'==_0x286398&&(_0x1e7189['isRemoved']={'userId':_0xce172c})),0x0==_0x1bab6e['length'])break;}return _0xd8a746;}['_refreshStartEndIndex'](_0x4b8ded){const _0x414693=new Map();for(let _0x385111=0x0;_0x385111<_0x4b8ded['length'];_0x385111++)'text'===_0x4b8ded[_0x385111]['type']?(_0x4b8ded[_0x385111]['item']['startIndex']=_0x385111,_0x4b8ded[_0x385111]['item']['endIndex']=_0x385111):('elementStart'===_0x4b8ded[_0x385111]['type']?_0x4b8ded[_0x385111]['item']['startIndex']=_0x385111:'elementEnd'===_0x4b8ded[_0x385111]['type']&&(_0x4b8ded[_0x385111]['item']['endIndex']=_0x385111),_0x414693['set'](_0x4b8ded[_0x385111]['id'],_0x385111));for(const _0x38930e of _0x414693['values']())'elementStart'===_0x4b8ded[_0x38930e]['type']?_0x4b8ded[_0x38930e]['item']['endIndex']=_0x414693['get'](_0x4b8ded[_0x38930e]['pairId']):'elementEnd'===_0x4b8ded[_0x38930e]['type']&&(_0x4b8ded[_0x38930e]['item']['startIndex']=_0x414693['get'](_0x4b8ded[_0x38930e]['pairId']));}['_processTape'](_0x23d8cc){for(let _0x449452=0x0;_0x449452<_0x23d8cc['length'];_0x449452++){if('elementStart'===_0x23d8cc[_0x449452]['type'])_0x23d8cc[_0x449452]['item']['startIndex']=_0x449452;else{if('elementEnd'===_0x23d8cc[_0x449452]['type']){_0x23d8cc[_0x449452]['item']['endIndex']=_0x449452;const _0x2ef96d=_0x23d8cc[_0x449452]['item']['startIndex'];_0x23d8cc[_0x2ef96d]['pairId']=_0x23d8cc[_0x449452]['id'],_0x23d8cc[_0x449452]['pairId']=_0x23d8cc[_0x2ef96d]['id'];}else _0x23d8cc[_0x449452]['item']['startIndex']=_0x449452,_0x23d8cc[_0x449452]['item']['endIndex']=_0x449452,_0x23d8cc[_0x449452]['pairId']=null;}_0x23d8cc[_0x449452]['markersStart']||(_0x23d8cc[_0x449452]['markersStart']=[],_0x23d8cc[_0x449452]['markersEnd']=[]);}}['_markInsertions'](_0x4337f5,_0x3567af){const _0x20f47f=_0x4337f5['filter'](_0x5dad35=>!_0x5dad35['isAdded']);for(let _0x2da7e6=0x0;_0x2da7e6<_0x3567af['length'];_0x2da7e6++)_0x3567af[_0x2da7e6]['isAdded']&&(_0x20f47f[_0x2da7e6]['isAdded']=_0x3567af[_0x2da7e6]['isAdded']);}['_makeModelFromViewString'](_0x4f4f8d){const _0x189328=JSON['parse'](_0x4f4f8d),_0x1e8e8c=this['editor']['editing']['view']['document'],_0x56be7a=new _0x1f9cff(_0x1e8e8c,_0x189328['map'](_0xa134cc=>this['_getViewObj'](_0xa134cc)));return this['editor']['data']['toModel'](_0x56be7a);}['_getViewObj'](_0x3ff5e7){const _0x409d60=this['editor']['editing']['view']['document'];if('string'==typeof _0x3ff5e7)return new _0x44c77c(_0x409d60,_0x3ff5e7);{const _0x54ed07=_0x3ff5e7['children']['map'](_0x10d075=>this['_getViewObj'](_0x10d075));return new(Y[_0x3ff5e7['type']]||_0x5e506b)(_0x409d60,_0x3ff5e7['name'],_0x3ff5e7['attributes'],_0x54ed07);}}['_getDiff'](_0x152997,_0x24a041=null){const _0x4e04a2=this['repository']['getRevision'](_0x152997),_0x4deb6d=_0x24a041?this['repository']['getRevision'](_0x24a041):null,_0xd1f828=this['_getRevisionsRange'](_0x4e04a2,_0x4deb6d),_0x3cb3a9=_0xd1f828[_0xd1f828['length']-0x1],_0x36d69d=new Map(),_0x5bfcdc={'model':{},'attributes':{},'changes':[]},_0x28de34=new Set(),_0x16958d=new Map();for(let _0x58cd0d=_0xd1f828['length']-0x1;_0x58cd0d>=0x0;_0x58cd0d--){const _0x28835b=_0xd1f828[_0x58cd0d];for(const _0x2917ea of Object['keys'](_0x28835b['diffData']))if(_0x28835b['diffData'][_0x2917ea]['attachChange']){const _0x42b153=_0x28835b['diffData'][_0x2917ea]['attachChange'];_0x42b153['isAttached']?(_0x28de34['add'](_0x2917ea),_0x16958d['has'](_0x2917ea)&&_0x16958d['get'](_0x2917ea)['userId']==_0x42b153['userId']?_0x16958d['delete'](_0x2917ea):_0x16958d['set'](_0x2917ea,_0x42b153)):_0x16958d['has'](_0x2917ea)?(_0x28de34['delete'](_0x2917ea),_0x16958d['delete'](_0x2917ea)):(_0x28de34['add'](_0x2917ea),_0x16958d['set'](_0x2917ea,_0x42b153));}else _0x28de34['add'](_0x2917ea);}for(const _0x27ddb9 of _0x28de34){const _0xc3d089=_0x16958d['has'](_0x27ddb9)&&!_0x16958d['get'](_0x27ddb9)['isAttached'];let _0x208213=_0xc3d089?_0xd1f828['length']-0x1:0x0;const _0xb58cd4=_0xc3d089?-0x1:0x1;for(;_0xd1f828[_0x208213];){const _0x336c7c=_0xd1f828[_0x208213];if(_0x336c7c['diffData'][_0x27ddb9]){const _0x254840=_0xc3d089?_0x336c7c['diffData'][_0x27ddb9]['attributesBefore']:_0x336c7c['diffData'][_0x27ddb9]['attributesAfter'];_0x5bfcdc['attributes'][_0x27ddb9]=_0x254840?_0x57b19f(_0x254840):{};break;}_0x208213+=_0xb58cd4;}}for(const _0xce1186 of _0xd1f828){_0xce1186['model']={};for(const _0xf9c955 of _0xce1186['authors'])_0x36d69d['set'](_0xf9c955['id'],_0xf9c955);for(const _0x3c8344 of _0x28de34){const _0x512e9e=_0xce1186['diffData'][_0x3c8344]?_0xce1186['diffData'][_0x3c8344]['insertions']:'[]',_0x5ca229=_0xce1186['diffData'][_0x3c8344]?_0xce1186['diffData'][_0x3c8344]['deletions']:'[]';_0xce1186['model'][_0x3c8344]={'insertions':this['_makeModelFromViewString'](_0x512e9e),'deletions':this['_makeModelFromViewString'](_0x5ca229)};}}for(const _0x2a7b07 of _0x28de34){let _0x4aa8ea=null,_0x7bc88d=0x0;const _0x4d8b94=new Map(Array['from'](_0x4e04a2['model'][_0x2a7b07]['insertions']['markers'])['filter'](([_0x2c795f])=>!_0x2c795f['startsWith']('revision:')));let _0x476577=0x0;for(const _0x3fe3a8 of _0xd1f828){const _0x14bbed=this['_makeTape'](_0x3fe3a8['model'][_0x2a7b07]['insertions']);_0x3fe3a8==_0x4e04a2?(_0x4aa8ea=_0x14bbed,_0x7bc88d=_0x4aa8ea['length'],_0x4aa8ea['forEach'](_0x49c8e6=>{_0x49c8e6['id']=_0x476577++;}),this['_processTape'](_0x4aa8ea)):this['_markInsertions'](_0x4aa8ea,_0x14bbed);const _0x1deac7=_0x4aa8ea['filter'](_0x1c8af4=>!_0x1c8af4['isAdded'])['map'](_0x56e356=>_0x56e356['id']);let _0x160b87=0x0;const _0x433351=this['_makeTape'](_0x3fe3a8['model'][_0x2a7b07]['deletions']);_0x433351['forEach'](_0x153c61=>{_0x153c61['isRemoved']?_0x153c61['id']=_0x7bc88d++:_0x153c61['id']=_0x1deac7[_0x160b87++];}),this['_processTape'](_0x433351),this['_setDistance'](_0x4aa8ea,'isAdded'),this['_setDistance'](_0x433351,'isRemoved'),_0x3fe3a8==_0x4e04a2&&this['_markMarkers'](_0x4aa8ea,_0x4d8b94),_0x4aa8ea=this['_joinTapes'](_0x4aa8ea,_0x433351),this['_refreshStartEndIndex'](_0x4aa8ea),this['_setDistance'](_0x4aa8ea,'isRemoved');}_0x4aa8ea=_0x4aa8ea['filter'](_0xb0aa65=>!(_0xb0aa65['isAdded']&&_0xb0aa65['isRemoved']));const _0x51c4fe=new Map(_0x3cb3a9['model'][_0x2a7b07]['deletions']['markers']),_0x2bc125=new Set(_0x4d8b94['keys']());for(const _0x4c07eb of _0x51c4fe['keys']())_0x2bc125['delete'](_0x4c07eb);this['_markSuggestions'](_0x4aa8ea,_0x2bc125),this['_fixObsoleteTags'](_0x4aa8ea),_0x4aa8ea=this['_removeMissingPairs'](_0x4aa8ea),_0x4aa8ea=this['_markMismatchedRemovedTags'](_0x4aa8ea),_0x4aa8ea=this['_removeUnsupportedChanges'](_0x4aa8ea);const {root:_0x544df2,changes:_0x19fdb6}=this['_makeModelFromTape'](_0x4aa8ea,_0x36d69d,_0x2a7b07);_0x5bfcdc['model'][_0x2a7b07]=_0x544df2;const _0x1b5d3a=_0x16958d['get'](_0x2a7b07);if(_0x1b5d3a){const _0x16ef88=_0x36d69d['get'](_0x1b5d3a['userId']),_0x4a0efa=new r({'author':_0x16ef88,'type':_0x1b5d3a['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x2a7b07});_0x19fdb6['unshift'](_0x4a0efa),_0x5bfcdc['attributes'][_0x2a7b07]['revisionHistoryAttachChange']=_0x4a0efa['id'];}_0x5bfcdc['changes']=_0x5bfcdc['changes']['concat'](_0x19fdb6);}return _0x5bfcdc;}['_markMarkers'](_0x18218d,_0x72533){for(let _0x50f298=0x0;_0x50f298<_0x18218d['length'];_0x50f298++)for(const [_0xa3678f,_0x45cedb]of _0x72533)_0x45cedb['start']['isEqual'](_0x18218d[_0x50f298]['previousPosition'])&&_0x18218d[_0x50f298]['markersStart']['push'](_0xa3678f),_0x45cedb['end']['isEqual'](_0x18218d[_0x50f298]['nextPosition'])&&_0x18218d[_0x50f298]['markersEnd']['push'](_0xa3678f);}['_joinTapes'](_0x1cb8c7,_0x3becc4){let _0x219010=[],_0x3ef30b=0x0,_0x837b04=0x0;for(;_0x3ef30b<_0x1cb8c7['length']||_0x837b04<_0x3becc4['length'];){const _0x2325c2=_0x1cb8c7[_0x3ef30b]||{},_0x421aa6=_0x3becc4[_0x837b04]||{};if(_0x2325c2['id']==_0x421aa6['id'])_0x3ef30b++,_0x837b04++,_0x219010['push'](_0x2325c2);else{if(_0x421aa6['isRemoved']&&_0x2325c2['isAdded']){const {commonTape:_0x30c70b,iEnd:_0x14157a,jEnd:_0x1ca0d0}=this['_threeWayMerge'](_0x1cb8c7,_0x3ef30b,_0x3becc4,_0x837b04);_0x219010=_0x219010['concat'](_0x30c70b),_0x3ef30b=_0x14157a,_0x837b04=_0x1ca0d0;}else _0x421aa6['isRemoved']?(_0x837b04++,_0x219010['push'](_0x421aa6)):(_0x3ef30b++,_0x219010['push'](_0x2325c2));}}return _0x219010;}['_markSuggestions'](_0x1bd793,_0x4fefa0){const _0x504e95=[];for(let _0xa5fad3=0x0;_0xa5fad3<_0x1bd793['length'];_0xa5fad3++){for(let _0x2028ce=0x0;_0x2028ce<_0x1bd793[_0xa5fad3]['markersStart']['length'];_0x2028ce++){const _0x3b0dec=_0x1bd793[_0xa5fad3]['markersStart'][_0x2028ce];if(!_0x4fefa0['has'](_0x3b0dec))continue;const {group:_0x3e8074,type:_0x2f26d3,authorId:_0x16134b}=_0x535c7f(_0x3b0dec);'revision-suggestion'!=_0x3e8074||'insertion'!=_0x2f26d3&&'deletion'!=_0x2f26d3||(_0x504e95['unshift']({'type':_0x2f26d3,'name':_0x3b0dec,'userId':_0x16134b}),_0x1bd793[_0xa5fad3]['markersStart']['splice'](_0x2028ce,0x1),_0x2028ce--);}_0x4dbf47(_0x1bd793[_0xa5fad3]);for(let _0x25d36b=0x0;_0x25d36b<_0x1bd793[_0xa5fad3]['markersEnd']['length'];_0x25d36b++){const _0x2171db=_0x1bd793[_0xa5fad3]['markersEnd'][_0x25d36b];if(!_0x4fefa0['has'](_0x2171db))continue;const {group:_0x2e224,type:_0x3b7c0a}=_0x535c7f(_0x2171db);if('revision-suggestion'!=_0x2e224||'insertion'!=_0x3b7c0a&&'deletion'!=_0x3b7c0a)continue;_0x1bd793[_0xa5fad3]['markersEnd']['splice'](_0x25d36b,0x1),_0x25d36b--;const _0x39f27d=_0x504e95['findIndex'](_0x5e2f5f=>_0x5e2f5f['name']==_0x2171db);_0x39f27d>-0x1&&_0x504e95['splice'](_0x39f27d,0x1);}}function _0x535c7f(_0x9052dd){const _0x45d6f1=_0x9052dd['split'](':');return{'group':_0x45d6f1[0x0],'type':_0x45d6f1[0x1],'subType':_0x45d6f1['length']>=0x5?_0x45d6f1[0x2]:null,'id':_0x45d6f1['length']<0x5?_0x45d6f1[0x2]:_0x45d6f1[0x3],'authorId':_0x45d6f1['length']<0x5?_0x45d6f1[0x3]:_0x45d6f1[0x4],'markerCount':0x6==_0x45d6f1['length']?_0x45d6f1[0x5]:null};}function _0x4dbf47(_0x568886){for(let _0x5004f0=0x0;_0x5004f0<_0x504e95['length'];_0x5004f0++){if(_0x568886['isAdded']&&'insertion'==_0x504e95[_0x5004f0]['type'])return _0x568886['isAddSuggestion']=_0x504e95[_0x5004f0],void delete _0x568886['isAdded'];if(!_0x568886['isAdded']&&!_0x568886['isRemoved']&&'deletion'==_0x504e95[_0x5004f0]['type'])return void(_0x568886['isRemoveSuggestion']=_0x504e95[_0x5004f0]);}}}['_setDistance'](_0x349ae0,_0x4d92fc){let _0x42ae4c=0x0,_0x468585=!0x1;const _0x32068f=new Map();for(const _0x1e1627 of _0x349ae0)_0x1e1627[_0x4d92fc]?_0x468585&&(_0x42ae4c++,_0x468585=!0x1):(_0x42ae4c++,_0x468585=!0x0),_0x32068f['set'](_0x1e1627['id'],_0x42ae4c);for(let _0xe11dd7=0x0;_0xe11dd7<_0x349ae0['length'];_0xe11dd7++){if('isRemoved'==_0x4d92fc&&_0x349ae0[_0xe11dd7]['isAdded']||'isAdded'==_0x4d92fc&&_0x349ae0[_0xe11dd7]['isRemoved'])continue;if('text'==_0x349ae0[_0xe11dd7]['type']){_0x349ae0[_0xe11dd7]['distance']=0x0;continue;}const _0x14257b=_0x32068f['get'](_0x349ae0[_0xe11dd7]['pairId']),_0x4ab5d6=_0x32068f['get'](_0x349ae0[_0xe11dd7]['id']);_0x349ae0[_0xe11dd7]['distance']=_0x14257b-_0x4ab5d6;}}['_getRevisionsRange'](_0x33a184,_0x40b372,_0x29b8e3=!0x1){const _0x533458=[];let _0x1f3fc4=this['repository']['getIndex'](_0x33a184),_0x1adeaa=this['repository']['getIndex'](_0x40b372);for(-0x1==_0x1adeaa&&(_0x1adeaa=this['repository']['_revisions']['length'],_0x29b8e3=!0x1);_0x1f3fc4<_0x1adeaa;)_0x533458['push'](this['repository']['getRevision'](_0x1f3fc4)),_0x1f3fc4++;return _0x29b8e3&&_0x533458['push'](this['repository']['getRevision'](_0x1f3fc4)),_0x533458;}['_threeWayMerge'](_0x51ffc7,_0x4529c0,_0x30d824,_0xd228ec){const _0x1b9f10=this['editor']['model']['schema'];let _0x26290f=_0x4529c0;for(;_0x51ffc7[_0x26290f]&&_0x51ffc7[_0x26290f]['isAdded'];)_0x26290f++;let _0x2408fe=_0xd228ec;for(;_0x30d824[_0x2408fe]&&_0x30d824[_0x2408fe]['isRemoved'];)_0x2408fe++;_0x39bae7(_0x51ffc7,_0x4529c0,_0x26290f),_0x39bae7(_0x30d824,_0xd228ec,_0x2408fe);const _0x536a6e=_0x30d824['slice'](_0xd228ec,_0x2408fe)['concat'](_0x51ffc7['slice'](_0x4529c0,_0x26290f));return _0x536a6e['sort']((_0x348da0,_0x32be39)=>_0x348da0['side']!=_0x32be39['side']?_0x348da0['side']-_0x32be39['side']:_0x348da0['level']!=_0x32be39['level']?_0x348da0['level']-_0x32be39['level']:_0x348da0['distance']!=_0x32be39['distance']?_0x32be39['distance']-_0x348da0['distance']:!!_0x348da0['isAdded']!=!!_0x32be39['isAdded']?-0x1==_0x348da0['side']||0x0==_0x348da0['side']?_0x348da0['isAdded']?-0x1:0x1:_0x348da0['isAdded']?0x1:-0x1:_0x348da0['index']-_0x32be39['index']),{'commonTape':_0x536a6e,'iEnd':_0x26290f,'jEnd':_0x2408fe};function _0x39bae7(_0x20fd7c,_0xcc79dc,_0x2b0cd3){let _0x146f44=-0x1,_0x34171a=Number['POSITIVE_INFINITY'],_0x23f77a=!0x0;for(let _0x160850=_0xcc79dc;_0x160850<_0x2b0cd3;_0x160850++)if(_0x1b9f10['isInline'](_0x20fd7c[_0x160850]['item'])||(_0x23f77a=!0x1),_0x20fd7c[_0x160850]['item']['startIndex']<_0xcc79dc&&(_0x146f44=_0x160850),_0x20fd7c[_0x160850]['item']['endIndex']>=_0x2b0cd3){_0x34171a=_0x160850;break;}_0x23f77a&&(_0x146f44=_0x2b0cd3-0x1);for(let _0xff8939=_0xcc79dc;_0xff8939<_0x2b0cd3;_0xff8939++)_0x20fd7c[_0xff8939]['side']=_0xff8939<=_0x146f44?-0x1:_0xff8939<_0x34171a?0x0:0x1,_0x20fd7c[_0xff8939]['index']=_0xff8939;let _0x6267b=0x0;for(let _0xb612f1=_0xcc79dc;_0xb612f1<=_0x146f44;_0xb612f1++)0x0==_0x20fd7c[_0xb612f1]['distance']?_0x20fd7c[_0xb612f1]['level']=_0x6267b:(_0x6267b++,_0x20fd7c[_0xb612f1]['level']=_0x6267b,_0x6267b++);for(let _0x46048f=_0xcc79dc;_0x46048f<_0x2b0cd3;_0x46048f++)0x0==_0x20fd7c[_0x46048f]['side']&&(_0x20fd7c[_0x46048f]['level']=_0x6267b);_0x6267b=0x0;for(let _0x3fdc74=_0x2b0cd3-0x1;_0x3fdc74>=_0x34171a;_0x3fdc74--)0x0==_0x20fd7c[_0x3fdc74]['distance']?_0x20fd7c[_0x3fdc74]['level']=_0x6267b:(_0x6267b--,_0x20fd7c[_0x3fdc74]['level']=_0x6267b,_0x6267b--);}}['_fixObsoleteTags'](_0x11c997){const _0x54175c=new Map(),_0xfd934b=this['editor']['model']['schema'];for(let _0x53c800=0x1;_0x53c800<_0x11c997['length'];_0x53c800++){let _0x3b9b8c,_0x22ece4,_0x553ca3;const _0x541798=_0x11c997[_0x53c800],_0x26cb6b=_0x11c997[_0x53c800-0x1];if('text'==_0x541798['type'])continue;if(_0x541798['type']!=_0x26cb6b['type'])continue;if(!_0xfd934b['isBlock'](_0x26cb6b['item'])||_0xfd934b['isLimit'](_0x26cb6b['item']))continue;if(!_0xfd934b['isBlock'](_0x541798['item'])||_0xfd934b['isLimit'](_0x541798['item']))continue;if((_0x11c997[_0x53c800]['isAdded']||_0x11c997[_0x53c800]['isAddSuggestion'])&&_0x11c997[_0x53c800-0x1]['isRemoved'])_0x3b9b8c=_0x11c997[_0x53c800],_0x22ece4=_0x11c997[_0x53c800-0x1],_0x553ca3=_0x53c800-0x1;else{if(!_0x11c997[_0x53c800]['isRemoved']||!_0x11c997[_0x53c800-0x1]['isAdded']&&!_0x11c997[_0x53c800-0x1]['isAddSuggestion'])continue;_0x3b9b8c=_0x11c997[_0x53c800-0x1],_0x22ece4=_0x11c997[_0x53c800],_0x553ca3=_0x53c800;}const _0x333db8=_0x3b9b8c['level']==_0x22ece4['level'],_0x565b83=Math['abs'](_0x3b9b8c['level'])<Math['abs'](_0x22ece4['level'])&&0x0==_0x22ece4['distance'];(_0x333db8||_0x565b83)&&(_0x54175c['set'](_0x22ece4['id'],_0x3b9b8c['id']),_0x11c997['splice'](_0x553ca3,0x1),_0x53c800--,_0x3b9b8c['isAdded']=!0x1);}for(let _0xa2b1ec=0x0;_0xa2b1ec<_0x11c997['length'];_0xa2b1ec++)_0x54175c['has'](_0x11c997[_0xa2b1ec]['pairId'])&&(_0x11c997[_0xa2b1ec]['pairId']=_0x54175c['get'](_0x11c997[_0xa2b1ec]['pairId']));}['_removeMissingPairs'](_0x1fc0ed){const _0x242474=new Set(_0x1fc0ed['map'](_0xb11509=>_0xb11509['id']));for(let _0x153c30=0x0;_0x153c30<_0x1fc0ed['length'];_0x153c30++)_0x242474['has'](_0x1fc0ed[_0x153c30]['pairId'])||0x0==_0x1fc0ed[_0x153c30]['distance']||(_0x1fc0ed[_0x153c30]['isIncorrect']=!0x0);return _0x1fc0ed['filter'](_0x397120=>!_0x397120['isIncorrect']);}['_markMismatchedRemovedTags'](_0x452cb2){const _0x4aad5a=new Set();for(let _0x531ff0=0x0;_0x531ff0<_0x452cb2['length'];_0x531ff0++){if(_0x4aad5a['has'](_0x452cb2[_0x531ff0]['id'])&&_0x452cb2[_0x531ff0]['isRemoved']&&(_0x452cb2[_0x531ff0]['isIncorrect']=!0x0),_0x452cb2[_0x531ff0]['isIncorrect'])continue;if(0x0==_0x452cb2[_0x531ff0]['distance'])continue;if('elementStart'!=_0x452cb2[_0x531ff0]['type'])continue;if(null==_0x452cb2[_0x531ff0]['pairId'])continue;let _0x3032be=_0x531ff0+0x1,_0x1b4db8=0x0;for(;_0x452cb2[_0x3032be]['id']!=_0x452cb2[_0x531ff0]['pairId'];)'elementStart'==_0x452cb2[_0x3032be]['type']?_0x1b4db8++:'elementEnd'==_0x452cb2[_0x3032be]['type']&&_0x1b4db8--,_0x3032be++;if(0x0!=_0x1b4db8){if(_0x452cb2[_0x531ff0]['isRemoved'])_0x452cb2[_0x531ff0]['isIncorrect']=!0x0;else{for(;_0x3032be!=_0x531ff0;)_0x452cb2[_0x3032be]['isRemoved']&&0x0!=_0x452cb2[_0x3032be]['distance']&&(_0x452cb2[_0x3032be]['isIncorrect']=!0x0,_0x4aad5a['add'](_0x452cb2[_0x3032be]['pairId'])),_0x3032be--;}}}return _0x452cb2['filter'](_0x318e0c=>!_0x318e0c['isIncorrect']);}['_removeUnsupportedChanges'](_0x24b600){const _0x3b37ad=this['editor']['model']['schema'];for(let _0x69148d=0x0;_0x69148d<_0x24b600['length'];_0x69148d++){if(!(_0x24b600[_0x69148d]['isAdded']||_0x24b600[_0x69148d]['isAddSuggestion']||_0x24b600[_0x69148d]['isRemoved']||_0x24b600[_0x69148d]['isRemoveSuggestion']))continue;if(0x0==_0x24b600[_0x69148d]['distance'])continue;const _0x3bacc3=_0x24b600[_0x69148d]['item'];_0x3b37ad['isBlock'](_0x3bacc3)||_0x3b37ad['isLimit'](_0x3bacc3)||(_0x24b600[_0x69148d]['isAdded']&&delete _0x24b600[_0x69148d]['isAdded'],_0x24b600[_0x69148d]['isAddSuggestion']&&delete _0x24b600[_0x69148d]['isAddSuggestion'],_0x24b600[_0x69148d]['isRemoveSuggestion']&&delete _0x24b600[_0x69148d]['isRemoveSuggestion'],_0x24b600[_0x69148d]['isRemoved']&&(_0x24b600[_0x69148d]['isIncorrect']=!0x0));}return _0x24b600['filter'](_0x137267=>!_0x137267['isIncorrect']);}['_makeModelFromTape'](_0x47e796,_0x19ba2b,_0x846709){const _0x2aadb9=new mt(),_0x452667=[],_0x2067af=new Map(),_0x4581c0=this['editor']['model'],_0x58562b=_0x4581c0['schema'],_0x1b4a87=[_0x2aadb9],_0x19b432={},_0x160df6={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x2d7db8=null;const _0x1fa1cb=[0x0];for(let _0x4ba6ae=0x0;_0x4ba6ae<_0x47e796['length'];_0x4ba6ae++)if('elementStart'===_0x47e796[_0x4ba6ae]['type']){_0x47e796[_0x4ba6ae]['previousPosition']=_0x4581c0['createPositionFromPath'](_0x2aadb9,_0x1fa1cb);const _0x1674a1=new ft(_0x47e796[_0x4ba6ae]['item']['name'],_0x47e796[_0x4ba6ae]['item']['getAttributes']());_0x1b4a87[0x0]['_appendChild'](_0x1674a1),_0x1fa1cb['push'](0x0),_0x1b4a87['unshift'](_0x1674a1),_0x47e796[_0x4ba6ae]['nextPosition']=_0x4581c0['createPositionFromPath'](_0x2aadb9,_0x1fa1cb);}else'elementEnd'===_0x47e796[_0x4ba6ae]['type']?(_0x1b4a87['shift'](),_0x47e796[_0x4ba6ae]['previousPosition']=_0x4581c0['createPositionFromPath'](_0x2aadb9,_0x1fa1cb),_0x1fa1cb['pop'](),_0x1fa1cb[_0x1fa1cb['length']-0x1]++,_0x47e796[_0x4ba6ae]['nextPosition']=_0x4581c0['createPositionFromPath'](_0x2aadb9,_0x1fa1cb)):(_0x47e796[_0x4ba6ae]['previousPosition']=_0x4581c0['createPositionFromPath'](_0x2aadb9,_0x1fa1cb),_0x2d7db8?_0x2d7db8['_data']+=_0x47e796[_0x4ba6ae]['item']['data']:_0x2d7db8=new wt(_0x47e796[_0x4ba6ae]['item']['data'],_0x47e796[_0x4ba6ae]['item']['getAttributes']()),_0x47e796[_0x4ba6ae+0x1]&&'text'===_0x47e796[_0x4ba6ae+0x1]['type']&&_0x345149(_0x2d7db8,_0x47e796[_0x4ba6ae+0x1]['item'])||(_0x1b4a87[0x0]['_appendChild'](_0x2d7db8),_0x2d7db8=null),_0x1fa1cb[_0x1fa1cb['length']-0x1]+=_0x47e796[_0x4ba6ae]['item']['offsetSize'],_0x47e796[_0x4ba6ae]['nextPosition']=_0x4581c0['createPositionFromPath'](_0x2aadb9,_0x1fa1cb));for(let _0x4df8d2=0x0;_0x4df8d2<_0x47e796['length'];_0x4df8d2++){const _0x2af936=_0x47e796[_0x4df8d2]['previousPosition'],_0x346a1b=_0x47e796[_0x4df8d2]['nextPosition'];for(const _0xd00552 of _0x47e796[_0x4df8d2]['markersStart'])_0x2067af['set'](_0xd00552,{'start':_0x2af936,'end':null});_0x1e3ceb('isRemoveSuggestion',_0x4df8d2,_0x2af936,_0x346a1b),_0x1e3ceb('isAddSuggestion',_0x4df8d2,_0x2af936,_0x346a1b),_0x1e3ceb('isRemoved',_0x4df8d2,_0x2af936,_0x346a1b),_0x1e3ceb('isAdded',_0x4df8d2,_0x2af936,_0x346a1b);for(const _0x71987c of _0x47e796[_0x4df8d2]['markersEnd']){_0x2067af['get'](_0x71987c)['end']=_0x346a1b;}}for(const [_0x165c88,_0x331334]of _0x2067af){const _0x248bcb=this['editor']['model']['createRange'](_0x331334['start'],_0x331334['end']);_0x2aadb9['markers']['set'](_0x165c88,_0x248bcb);}return _0x452667['sort']((_0xa202a4,_0x5c60f2)=>{const _0x50164d=_0x2aadb9['markers']['get']('revision:'+_0xa202a4['id']),_0x494e1e=_0x2aadb9['markers']['get']('revision:'+_0x5c60f2['id']);return _0x50164d['start']['isBefore'](_0x494e1e['start'])?-0x1:_0x50164d['start']['isAfter'](_0x494e1e['start'])?0x1:_0x50164d['end']['isBefore'](_0x494e1e['end'])?-0x1:_0x50164d['end']['isAfter'](_0x494e1e['end'])?0x1:'add'===_0xa202a4['type']?-0x1:0x1;}),{'root':_0x2aadb9,'changes':_0x452667};function _0x1e3ceb(_0x365513,_0x100303,_0xeebea7,_0x5e1c8c){const _0x121aa7=!!_0x47e796[_0x100303][_0x365513],_0x1a4ae2=_0x121aa7?_0x47e796[_0x100303][_0x365513]['userId']:null,_0x183db4=_0x100303===_0x47e796['length']-0x1,_0x5cdfe8=_0x160df6[_0x365513][0x0],_0x4564ca=_0x58562b['isObject'](_0x47e796[_0x100303]['item']);!_0x19b432[_0x365513]&&_0x121aa7?_0x19b432[_0x365513]={'start':_0xeebea7,'tapeItem':_0x47e796[_0x100303],'userId':_0x1a4ae2,'type':_0x365513}:_0x19b432[_0x365513]&&!_0x121aa7?(_0x19b432[_0x365513]['end']=_0xeebea7,_0x57bcb9(_0x19b432[_0x365513]),_0x19b432[_0x365513]=null):_0x19b432[_0x365513]&&_0x121aa7&&_0x19b432[_0x365513]['userId']!==_0x1a4ae2&&(_0x19b432[_0x365513]['end']=_0xeebea7,_0x5cdfe8&&_0x5cdfe8['userId']===_0x19b432[_0x365513]['userId']||_0x57bcb9(_0x19b432[_0x365513]),_0x19b432[_0x365513]={'start':_0xeebea7,'tapeItem':_0x47e796[_0x100303],'userId':_0x1a4ae2,'type':_0x365513}),_0x19b432[_0x365513]&&_0x4564ca&&('elementStart'!==_0x47e796[_0x100303]['type']||_0x5cdfe8&&_0x5cdfe8['userId']===_0x1a4ae2||_0x160df6[_0x365513]['unshift']({'userId':_0x1a4ae2,'object':_0x47e796[_0x100303]['item'],'change':_0x19b432[_0x365513]}),'elementEnd'===_0x47e796[_0x100303]['type']&&_0x5cdfe8&&_0x5cdfe8['object']===_0x47e796[_0x100303]['item']&&(_0x160df6[_0x365513]['shift'](),_0x19b432[_0x365513]=_0x5cdfe8['change'])),_0x19b432[_0x365513]&&_0x183db4&&(_0x19b432[_0x365513]['end']=_0x5e1c8c,_0x57bcb9(_0x19b432[_0x365513]),_0x19b432[_0x365513]=null);}function _0x57bcb9({start:_0x1ebc3c,end:_0x4faab8,tapeItem:_0x20700a,userId:_0x5ece1c,type:_0x4044c7}){const _0x484a76=_0x20700a['item'],_0x15441f=_0x4581c0['schema']['isBlock'](_0x484a76)&&!_0x4581c0['schema']['isLimit'](_0x484a76),_0x42935b=_0x1ebc3c['nodeAfter']==_0x4faab8['parent']&&_0x4faab8['isAtStart'];if(_0x15441f&&_0x42935b)return;const _0x4241d2=_0x4581c0['createRange'](_0x1ebc3c,_0x4faab8),_0xdf39ad=_0x19ba2b['get'](_0x5ece1c),_0x2720e8=new r({'author':_0xdf39ad,'type':'isAdded'==_0x4044c7||'isAddSuggestion'==_0x4044c7?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x4044c7||'isRemoveSuggestion'==_0x4044c7},'createdAt':new Date(),'rootName':_0x846709});_0x452667['push'](_0x2720e8),_0x2aadb9['markers']['set']('revision:'+_0x2720e8['id'],_0x4241d2);}function _0x345149(_0x5cf7e3,_0x31aed2){const _0x2ce3d2=_0x5cf7e3['getAttributes'](),_0x53c9cb=_0x31aed2['getAttributes']();for(const _0x4d3f81 of _0x2ce3d2){if(_0x4d3f81[0x1]!==_0x31aed2['getAttribute'](_0x4d3f81[0x0]))return!0x1;_0x53c9cb['next']();}return _0x53c9cb['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x4f4226=>{const _0x1595fe=_0x4f4226['markerName']['split'](':')[0x1],_0x3695e7=this['_getChangeFromId'](_0x1595fe);if(!_0x3695e7)return null;const _0x2319c6='add'==_0x3695e7['type']?'insertion':'deletion',_0x41a694=['ck-suggestion-marker','ck-suggestion-marker-'+_0x2319c6];return _0x3695e7['data']['isSuggestion']&&_0x41a694['push']('ck-suggestion-marker-'+_0x2319c6+'-new'),this['activeChange']==_0x3695e7&&_0x41a694['push']('ck-suggestion-marker--active'),{'classes':_0x41a694,'attributes':{'data-change-id':_0x1595fe}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x448392=>{_0x448392['on']('element:pre',(_0x6a9bd7,_0x3490b8,_0x1a05d6)=>{const _0x12814e=_0x3490b8['viewItem']['getChild'](0x0);if(!_0x12814e||!_0x12814e['is']('element','code'))return;if(!_0x1a05d6['consumable']['consume'](_0x12814e,{'attributes':['vid_start','vid_end']}))return;const _0x10fd83=_0x3490b8['modelRange']['start']['nodeAfter'];_0x1a05d6['writer']['setAttribute']('vid_start',_0x12814e['getAttribute']('vid_start'),_0x10fd83),_0x1a05d6['writer']['setAttribute']('vid_end',_0x12814e['getAttribute']('vid_end'),_0x10fd83);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x17e799=>{_0x17e799['on']('element',(_0x1adeff,_0x3dd204,_0x364dd1)=>{if(!_0x364dd1['consumable']['consume'](_0x3dd204['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x3dd204['modelRange']['isCollapsed'])return;const _0x23bfb4=_0x3dd204['modelRange']['start']['nodeAfter'];_0x23bfb4['hasAttribute']('vid_start')||_0x23bfb4['hasAttribute']('vid')||(_0x364dd1['writer']['setAttribute']('vid_start',_0x3dd204['viewItem']['getAttribute']('vid_start'),_0x23bfb4),_0x364dd1['writer']['setAttribute']('vid_end',_0x3dd204['viewItem']['getAttribute']('vid_end'),_0x23bfb4));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0xa8aba2=>_0xa8aba2['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x16bb29,[,_0x39433f])=>{['vid_start','vid_end','vid']['includes'](_0x39433f)&&(_0x16bb29['return']=!0x0,_0x16bb29['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x376569=>{_0x376569['on']('attribute:vid',(_0x2e1443,_0x335d0b,_0x5d42ae)=>{if('\x20'!=_0x335d0b['item']['data']||_0x335d0b['item']['parent']['maxOffset']>0x1)return;if(!_0x5d42ae['consumable']['consume'](_0x335d0b['item'],_0x2e1443['name']))return;const _0x352756=_0x5d42ae['writer'],_0x60a104=_0x5d42ae['mapper']['toViewRange'](_0x335d0b['range']);_0x352756['wrap'](_0x60a104,_0x352756['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x21bb99){const _0x4962f5=_0x21bb99['plugins']['get']('RevisionViewer');return(_0x352409,_0x102851,_0xdc93ec)=>{const _0x3b4875=_0x102851['markerName']['split'](':')[0x1],_0x2745d3=_0x4962f5['_getChangeFromId'](_0x3b4875);if(!_0x2745d3)return null;const _0x2f9ac4='add'==_0x2745d3['type']?'split':'merge';if(!_0xdc93ec['consumable']['test'](_0x102851['markerRange'],_0x352409['name']))return;const _0xdada4e=_0x102851['markerRange']['getWalker'](),_0x1716a2=_0x102851['markerRange']['start'],_0x1a161b=_0x21bb99['model']['schema'];let _0x123db2=null,_0x39ee12=null,_0x5c6d03=!0x1,_0x2b4c6a=!0x1;for(const _0x862817 of _0xdada4e){const _0x1cb7d3=_0x862817['item'];_0x5c6d03=_0x5c6d03||_0x1a161b['isContent'](_0x1cb7d3);const _0x442370=_0xdc93ec['mapper']['toViewElement'](_0x1cb7d3);if(_0x442370&&_0x442370['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x862817['type']&&(_0x1a161b['isBlock'](_0x1cb7d3)&&!_0x1a161b['isLimit'](_0x1cb7d3)&&(_0x1cb7d3['nextSibling']||_0x1716a2['isAtEnd']?_0x123db2&&_0x123db2['parent']==_0x1cb7d3||(_0x123db2=_0x1cb7d3,_0x511994(_0x862817['previousPosition']),_0x2b4c6a=!0x0):_0x39ee12=_0x39ee12||_0x862817['previousPosition']));}function _0x511994(_0x49bd40){const _0x36f5ca=_0xdc93ec['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x2f9ac4}),_0x1210e1=_0xdc93ec['mapper']['toViewPosition'](_0x49bd40);_0x2745d3['data']['isSuggestion']&&_0xdc93ec['writer']['addClass']('ck-suggestion-marker-'+_0x2f9ac4+'-new',_0x36f5ca),_0x4962f5['activeChange']==_0x2745d3&&_0xdc93ec['writer']['addClass']('ck-suggestion-marker--active',_0x36f5ca),_0xdc93ec['writer']['insert'](_0x1210e1,_0x36f5ca),_0xdc93ec['mapper']['bindElementToMarker'](_0x36f5ca,_0x102851['markerName']);}_0x5c6d03||_0x2b4c6a||!_0x39ee12||_0x511994(_0x39ee12);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x4d259f,_0x5b0737,_0x42021d)=>{const _0x44291b=_0x42021d['mapper']['markerNameToElements'](_0x5b0737['markerName']);if(_0x44291b){for(const _0x43d504 of _0x44291b)(_0x43d504['hasClass']('ck-suggestion-marker-split')||_0x43d504['hasClass']('ck-suggestion-marker-merge'))&&(_0x42021d['mapper']['unbindElementFromMarkerName'](_0x43d504,_0x5b0737['markerName']),_0x42021d['writer']['remove'](_0x43d504));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x4f7420,_0x4ac0f5,_0xfd4077)=>{const _0x13d09e=_0x4ac0f5['markerName']['split'](':')[0x1],_0x1756f2=this['_getChangeFromId'](_0x13d09e);if(!_0x1756f2)return null;const _0x491537='add'==_0x1756f2['type']?'split':'merge';if(_0xfd4077['consumable']['test'](_0x4ac0f5['markerRange'],_0x4f7420['name']))for(const _0x19df2a of _0x4ac0f5['markerRange']['getItems']()){if(!_0x19df2a['is']('element','softBreak'))continue;const _0x536b42=_0xfd4077['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x491537}),_0x2e5cec=_0xfd4077['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x19df2a));_0x1756f2['data']['isSuggestion']&&_0xfd4077['writer']['addClass']('ck-suggestion-marker-'+_0x491537+'-new',_0x536b42),this['activeChange']==_0x1756f2&&_0xfd4077['writer']['addClass']('ck-suggestion-marker--active',_0x536b42),_0xfd4077['writer']['insert'](_0x2e5cec,_0x536b42),_0xfd4077['mapper']['bindElementToMarker'](_0x536b42,_0x4ac0f5['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x4cd74c=>{for(const _0x4e3cbf of this['editor']['model']['document']['getRootNames']()){const _0x4f6f9b=this['editor']['model']['document']['getRoot'](_0x4e3cbf),_0x1340ca=this['editor']['editing']['view']['document']['getRoot'](_0x4e3cbf);if(_0x1340ca){const _0x33ad07=_0x4f6f9b['getAttribute']('revisionHistoryAttachChange');if(_0x4cd74c['removeAttribute']('data-change-id',_0x1340ca),_0x4cd74c['removeClass']('ck-revision-history-root-add',_0x1340ca),_0x4cd74c['removeClass']('ck-revision-history-root-remove',_0x1340ca),_0x4cd74c['removeClass']('ck-revision-history-root--active',_0x1340ca),_0x33ad07){const _0x5570f5=this['_getChangeFromId'](_0x33ad07);if(!_0x5570f5)return null;_0x4cd74c['setAttribute']('data-change-id',_0x33ad07,_0x1340ca),_0x4cd74c['addClass']('ck-revision-history-root-'+_0x5570f5['type'],_0x1340ca),this['activeChange']==_0x5570f5&&_0x4cd74c['addClass']('ck-revision-history-root--active',_0x1340ca);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x14937e=>'revision-comment:'+_0x14937e,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x5a00ff=>'revision-suggestion:'+_0x5a00ff,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x1d935b=>({'name':'suggestion:'+_0x1d935b,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x16149b=>{const _0x440071=_0x16149b['markerName']['split'](':')[0x1];return'insertion'!=_0x440071&&'deletion'!=_0x440071?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x440071]};}}),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',(_0x5094e8,_0x563e2d,_0x3d8841)=>{const _0x7e5857=_0x3d8841['mapper']['markerNameToElements'](_0x563e2d['markerName']);if(_0x7e5857){for(const _0x5ded7d of _0x7e5857)_0x5ded7d['is']('uiElement')&&(_0x3d8841['mapper']['unbindElementFromMarkerName'](_0x5ded7d,_0x563e2d['markerName']),_0x3d8841['writer']['remove'](_0x5ded7d));}},{'priority':'high'});}['_getChangeFromId'](_0x625d62){return this['_changeIdToChange']['get'](_0x625d62);}['_getViewForChange'](_0x30b493){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new X(this['editor']['locale'],_0x30b493),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x44b0fc,_0x54d5b6,_0xbf389f,_0x668b27)=>{_0x668b27&&this['_balloon']['remove'](_0x668b27),_0xbf389f&&(this['_balloon']['add']({'view':_0xbf389f,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x1805d9=this['editor']['editing'],_0x275a87=this['_getChangeFromId'](_0xbf389f['changeId']);let _0x427922;if(_0x275a87['data']['isOnRoot']){const _0xd57717=_0x1805d9['view']['getDomRoot'](_0x275a87['rootName']);_0x427922=Array['from'](_0xd57717['getClientRects']());}else{const _0x2b1756=this['editor']['model']['markers']['get']('revision:'+_0xbf389f['changeId']);_0x427922=Array['from'](_0x1805d9['mapper']['markerNameToElements'](_0x2b1756['name']))['map'](_0x4d73e4=>_0x1805d9['view']['domConverter']['mapViewToDom'](_0x4d73e4))['map'](_0x3e5abb=>Array['from'](_0x3e5abb['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x427922[0x0];return _0x427922['find'](_0x24767e=>_0x24767e['top']-0x3<=this['_activeViewTarget']['y']&&_0x24767e['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x24767e['left']-0x3<=this['_activeViewTarget']['x']&&_0x24767e['right']+0x3>=this['_activeViewTarget']['x'])||_0x427922[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x461b89,_0x2b524d,_0x1e0729,_0x1897bc)=>{this['activeView']=_0x1e0729?this['_getViewForChange'](_0x1e0729):null,this['editor']['model']['change'](()=>{const _0x27a0f7=this['editor']['editing'];_0x1897bc&&(_0x1897bc['data']['isOnRoot']?_0x27a0f7['view']['change'](_0x31421d=>{_0x31421d['removeClass']('ck-revision-history-root--active',_0x27a0f7['view']['document']['getRoot'](_0x1897bc['rootName']));}):_0x27a0f7['reconvertMarker']('revision:'+_0x1897bc['id'])),_0x1e0729&&(_0x1e0729['data']['isOnRoot']?_0x27a0f7['view']['change'](_0x53dbe4=>{_0x53dbe4['addClass']('ck-revision-history-root--active',_0x27a0f7['view']['document']['getRoot'](_0x1e0729['rootName']));}):_0x27a0f7['reconvertMarker']('revision:'+_0x1e0729['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x124842,_0x5598fc)=>{if(this['activeChange'])return;const _0x535179=this['_findChangeIdFromDomTarget'](_0x5598fc['target']),_0x384616=this['_changeIdToChange']['get'](_0x535179);_0x384616?(this['_activeViewTarget']={'x':_0x5598fc['domEvent']['x'],'y':_0x5598fc['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x384616)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x654534,_0x5b1444)=>{const _0x1f2510=this['_findChangeIdFromDomTarget'](_0x5b1444['target']),_0x21ad30=this['_changeIdToChange']['get'](_0x1f2510);_0x21ad30?(this['_activeViewTarget']={'x':_0x5b1444['domEvent']['x'],'y':_0x5b1444['domEvent']['y']},_0x21ad30===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x21ad30):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x2b5a5d){do{const _0x40b724=_0x2b5a5d['getAttribute']('data-change-id');if(_0x40b724)return _0x40b724;_0x2b5a5d=_0x2b5a5d['parent'];}while(_0x2b5a5d);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x5c233f=>{for(const _0x5488d5 of this['editor']['model']['markers'])_0x5c233f['removeMarker'](_0x5488d5);});}}function Z(_0x1c435d,_0x5ec6da){return(_0x5164d3,_0xe6b848,_0x33d020)=>{if(!_0x33d020['consumable']['test'](_0xe6b848['markerRange'],_0x5164d3['name']))return;const _0x20e40c=_0xe6b848['markerRange']['getWalker'](),_0x39321d=_0xe6b848['markerRange']['start'],_0xbb058a=_0x1c435d['model']['schema'];let _0x1cb758=null,_0x2283ba=null,_0x52f62d=!0x1,_0x465056=!0x1;for(const _0x53ed33 of _0x20e40c){const _0x5dbc0d=_0x53ed33['item'];_0x52f62d=_0x52f62d||_0xbb058a['isContent'](_0x5dbc0d);const _0x1ecd5c=_0x33d020['mapper']['toViewElement'](_0x5dbc0d);if(_0x1ecd5c&&_0x1ecd5c['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x53ed33['type']&&(_0xbb058a['isBlock'](_0x5dbc0d)&&!_0xbb058a['isLimit'](_0x5dbc0d)&&(_0x5dbc0d['nextSibling']||_0x39321d['isAtEnd']?_0x1cb758&&_0x1cb758['parent']==_0x5dbc0d||(_0x1cb758=_0x5dbc0d,_0x1a57b6(_0x53ed33['previousPosition']),_0x465056=!0x0):_0x2283ba=_0x2283ba||_0x53ed33['previousPosition']));}function _0x1a57b6(_0x363d4f){const _0x43f586=_0x33d020['mapper']['toViewPosition'](_0x363d4f),_0x5774eb=_0x33d020['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x5ec6da});_0x33d020['writer']['insert'](_0x43f586,_0x5774eb),_0x33d020['mapper']['bindElementToMarker'](_0x5774eb,_0xe6b848['markerName']);}_0x52f62d||_0x465056||!_0x2283ba||_0x1a57b6(_0x2283ba);};}class _t extends _0x5db507{constructor(_0x24052b){super(_0x24052b);const _0x25dd98=_0x24052b['plugins']['get'](d);this['affectsData']=!0x1,this['listenTo'](_0x25dd98,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x25dd98,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x45f8fe=this['editor'],_0x30ca7c=_0x45f8fe['plugins']['get'](d),_0x22ae4e=_0x30ca7c['isReady']?_0x30ca7c['diff']['newRevisionId']:null;_0x45f8fe['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x22ae4e);}['refresh'](){const {isReady:_0x82b237,isEnabled:_0x55132,repository:_0x52a556,diff:_0x4beaec}=this['editor']['plugins']['get'](d),_0x13c6cb=_0x4beaec&&_0x52a556['getLaterVisibleRevision'](_0x4beaec['newRevisionId']);this['isEnabled']=_0x82b237&&_0x55132&&Boolean(_0x13c6cb);}}class yt extends _0x5db507{['_step'];constructor(_0x485c0a,{direction:_0x3f6972}){super(_0x485c0a);const _0x26b747=_0x485c0a['plugins']['get'](d);this['affectsData']=!0x1,this['_step']='forward'===_0x3f6972?0x1:-0x1,this['listenTo'](_0x26b747,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x26b747,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x26b747,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x5c79da=this['editor'],_0x5f1e4f=_0x5c79da['plugins']['get'](d),{isNavigationMode:_0x1eee52,currentChangeNumber:_0x2462c4}=_0x5f1e4f;let _0x45fc51;if(_0x5f1e4f['activeChange']=_0x1eee52?_0x5f1e4f['diff']['changes']['get'](_0x2462c4+this['_step']):_0x5f1e4f['diff']['changes']['first'],_0x5f1e4f['activeChange']['data']['isOnRoot'])_0x45fc51=_0x5c79da['editing']['view']['getDomRoot'](_0x5f1e4f['activeChange']['rootName']);else{const _0x24903f=_0x5c79da['model']['markers']['get']('revision:'+_0x5f1e4f['activeChange']['id']);_0x45fc51=_0x35fd59(_0x5c79da['editing'],_0x24903f);}_0x4f643f({'target':_0x45fc51,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x4ed56e,currentChangeNumber:_0x149779,numberOfChanges:_0xd94a3c,isReady:_0x2ba446,isEnabled:_0x3224a6}=this['editor']['plugins']['get'](d);this['isEnabled']=!!(_0x3224a6&&_0x2ba446&&_0xd94a3c)&&(!_0x4ed56e||(0x1===this['_step']?_0x149779<_0xd94a3c-0x1:_0x149779>0x0));}}class _i extends _0x1331b6{constructor(_0x123dd9){super(_0x123dd9);const _0x2c0837=this['bindTemplate'],_0x10bd7f=new _0x46ea5a(_0x123dd9),_0x2dc178=new _0x46ea5a(_0x123dd9);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',(_0x2471e9,_0x3abdde)=>_0x2471e9&&_0x3abdde>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0xfc29db,_0x2daab5,_0x3902ea,_0x22f371)=>{if(!_0xfc29db)return m(_0x123dd9,'Loading...');if(!_0x3902ea)return m(_0x123dd9,'No\x20changes');const _0x11ffce=m(_0x123dd9,'NUMBER_OF_CHANGES',_0x3902ea);return _0x22f371?m(_0x123dd9,'X_OF_Y_CHANGES',[_0x2daab5+0x1,_0x3902ea]):_0x11ffce;}),_0x10bd7f['set']({'label':m(_0x123dd9,'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'}),_0x2dc178['set']({'label':m(_0x123dd9,'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'}),_0x10bd7f['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x2dc178['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x10bd7f['on']('execute',()=>this['fire']('execute','backward')),_0x2dc178['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',_0x2c0837['if']('_isStatusLabelVisible','ck-hidden',_0x3d30c6=>!_0x3d30c6)]},'children':[{'text':_0x2c0837['to']('isNavigationMode',_0x8317a3=>_0x8317a3?m(_0x123dd9,'EDIT_X_OF_Y_REVISIONS')+':\x20':m(_0x123dd9,'Total')+':\x20')}]},{'text':_0x2c0837['to']('_statusText')}]},new _0x401132(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x10bd7f,_0x2dc178]}]});}}const ce='ck-editor__editable__loading-overlay';class le extends _0xc00adc{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x6cd05d=this['editor']['editing']['view'];_0x6cd05d['change'](_0x11c0f5=>{for(const _0x3a7281 of _0x6cd05d['document']['roots'])_0x11c0f5['addClass'](ce,_0x3a7281);});}['hide'](){const _0x4475d4=this['editor']['editing']['view'];_0x4475d4['change'](_0x45736c=>{for(const _0x17e491 of _0x4475d4['document']['roots'])_0x45736c['removeClass'](ce,_0x17e491);});}}class g extends _0xc00adc{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[d,le];}['init'](){const _0x5d8eac=this['editor'],_0x2ae6be=_0x5d8eac['plugins']['get'](d),_0x1c260=_0x5d8eac['plugins']['get'](le);_0x5d8eac['ui']['componentFactory']['add']('exitToEditing',_0x5437b7=>{const _0x4b41f3=new _0x46ea5a(_0x5437b7);return _0x4b41f3['set']({'label':m(_0x5437b7,'Back\x20to\x20editing'),'icon':_0xd99ff4['undo'],'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x4b41f3,'execute',()=>{_0x5d8eac['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x4b41f3;}),_0x5d8eac['ui']['componentFactory']['add']('restoreRevision',_0x4c57b7=>{const _0x14807e=new _0x46ea5a(_0x4c57b7);return _0x14807e['set']({'label':m(_0x4c57b7,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x14807e['bind']('isEnabled')['to'](_0x5d8eac['commands']['get']('restoreRevision')),this['listenTo'](_0x14807e,'execute',()=>_0x5d8eac['execute']('restoreRevision')),_0x14807e;}),_0x5d8eac['ui']['componentFactory']['add']('changesNavigation',_0xef1ca5=>{const _0x6aed23=new _i(_0xef1ca5),_0x454073=_0x5d8eac['commands']['get']('showPreviousChange'),_0x509675=_0x5d8eac['commands']['get']('showNextChange');return _0x6aed23['bind']('isBackwardNavigationEnabled')['to'](_0x454073,'isEnabled'),_0x6aed23['bind']('isForwardNavigationEnabled')['to'](_0x509675,'isEnabled'),_0x6aed23['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x2ae6be),this['listenTo'](_0x6aed23,'execute',(_0x332047,_0x4e7e3a)=>{_0x5d8eac['execute']('forward'===_0x4e7e3a?'showNextChange':'showPreviousChange');}),_0x6aed23;}),_0x1c260['show'](),_0x2ae6be['on']('change:isReady',(_0x3fc5cc,_0xb7aa6b,_0x51d6f2)=>{_0x51d6f2?_0x1c260['hide']():_0x1c260['show']();});}}class pt extends nt{['_resizeObserver']=null;constructor(_0x4ce9fe,_0x32e6ac){super(_0x4ce9fe,_0x32e6ac);const _0x48b8ec=this['bindTemplate'];this['set']({'label':m(_0x4ce9fe,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=m(_0x4ce9fe,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x48b8ec['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 _0x3be0ea=this['fieldView']['element'];this['_tooltipString']=_0x3be0ea['scrollWidth']>_0x3be0ea['clientWidth']&&_0x3be0ea['value']||'';}}class ti extends _0x1331b6{constructor(_0x1f3e00,_0xfa58c9,_0x387005){super(_0x1f3e00);const _0x44f3fd=new _0x1c6c68();_0x44f3fd['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 _0x353adb=['ck','ck-revision-history-sidebar__revision-author'];_0x387005&&_0x353adb['push']('ck-revision-history-sidebar__revision-author_creator');const _0x1cdd62=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':m(_0x1f3e00,_0x387005?'Revision\x20creator':'Revision\x20author')},'children':[_0x44f3fd,_0xfa58c9['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x353adb},'children':_0x1cdd62});}}function ni(_0x1a3b40,_0x2f154c){const _0x1bb7b2=_0x1a3b40['bindTemplate'],_0x2bbec2=_0x1a3b40['locale'],_0x4f97dc=_0x336529(_0x2bbec2);_0x4f97dc['panelPosition']='sw';const _0x194f88=function(_0x3259bf,_0x493880){const _0x125404=function(_0x48f5d9,_0x503b98){const _0x6064d2=_0x48f5d9['locale'],_0x154f5e={'Compare\x20against\x20selected':m(_0x6064d2,'Compare\x20against\x20selected'),'Name\x20this\x20revision':m(_0x6064d2,'Name\x20this\x20revision'),'Restore\x20this\x20revision':m(_0x6064d2,'Restore\x20this\x20revision')};return _0x503b98['map'](_0x22ee44=>{const _0x196c99=_0x154f5e[_0x22ee44['name']];return _0x196c99&&_0x196c99!==_0x22ee44['name']&&(_0x22ee44['name']=_0x196c99),_0x22ee44;});}(_0x3259bf,_0x493880),_0x30c45f=new _0x43846a();for(const _0x1bfc9b of _0x125404){const _0x2aa5a8={'type':'button','model':new to({'label':_0x1bfc9b['name'],'class':_0x1bfc9b['class'],'withText':!0x0,'role':'menuitem','_action':_0x1bfc9b['action']})};_0x2aa5a8['model']['bind']('isEnabled')['to'](_0x3259bf,'isActionsDropdownOpen',_0x408a67=>'function'!=typeof _0x1bfc9b['isEnabled']||(!_0x408a67||_0x1bfc9b['isEnabled'](_0x3259bf))),_0x30c45f['add'](_0x2aa5a8);}return _0x30c45f;}(_0x1a3b40,_0x2f154c);return _0x1a3b40['bind']('isActionsDropdownOpen')['to'](_0x4f97dc,'isOpen'),_0x4f97dc['buttonView']['set']({'label':m(_0x2bbec2,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0xd99ff4['threeVerticalDots']}),_0x4f97dc['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x1bb7b2['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x1bb7b2['to'](_0x43dc28=>_0x43dc28['stopPropagation']())}}),_0x4f97dc['on']('execute',_0x5c945e=>{_0x1a3b40['isReady']&&'function'==typeof _0x5c945e['source']['_action']&&_0x5c945e['source']['_action'](_0x1a3b40);}),_0x80f599(_0x4f97dc,_0x194f88,{'role':'menu'}),_0x4f97dc['listenTo'](_0x1a3b40,'change:isActionsDropdownOpen',(_0x4b1c9d,_0x4a97b8,_0x22ef7f)=>{if(_0x22ef7f)for(const _0x16eb5e of _0x4f97dc['listView']['items']){const _0x583537=_0x16eb5e['children']['first'],_0x4d43b4=_0x2f154c['find'](_0xbf1885=>_0xbf1885['action']===_0x583537['_action'])['isVisible'];_0x16eb5e['isVisible']=void 0x0===_0x4d43b4||_0x4d43b4(_0x1a3b40);}}),_0x4f97dc;}class ai extends/* #__PURE__ -- @preserve */
|
|
26
|
-
|
|
23
|
+
import{ObservableMixin as _0x2332e5,uid as _0x52d906,Collection as _0x2ebcff,logWarning as _0x140cad,FocusTracker as _0x7d4c72,KeystrokeHandler as _0x4053e6,scrollViewportToShowTarget as _0x30a2cb,ResizeObserver as at,ElementReplacer as ht,CKEditorError as _0x1cd261}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x5af04f,set as _0x3d3cf1,unset as _0xdbbb68,isEqual as _0x507df6}from'lodash-es';import{Plugin as _0x361651,PendingActions as _0x387150,icons as _0x2a914a,Command as _0x2f351f,ElementApiMixin as it,Editor as tt}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x176997,getMarkerDomElement as _0x54db46,ConfirmMixin as _0x3eb80d,sanitizeEditorConfig as _0xc76ffb}from'ckeditor5-collaboration/dist/index.js';import{ViewDocumentFragment as _0x379ec6,Element as ft,Range as vt,ViewUIElement as _0x4421f6,ViewRawElement as _0x8ec83,ViewEmptyElement as _0x335ef8,ViewAttributeElement as _0xa485d0,ViewContainerElement as _0x11367b,Position as gt,ViewText as _0x4317d4,ViewElement as _0x3c4ed4,DocumentFragment as mt,Text as wt}from'@ckeditor/ckeditor5-engine/dist/index.js';import{View as _0x376464,injectCssTransitionDisabler as ts,submitHandler as _0xbcf98b,LabeledFieldView as nt,createLabeledInputText as _0xcbfa91,createDropdown as _0x11399b,ListView as te,ListItemView as _0x3ce312,ButtonView as _0x58a9b0,MenuBarMenuView as _0x1643c5,MenuBarMenuListView as _0x2732e5,MenuBarMenuListItemView as _0x21400a,MenuBarMenuListItemButtonView as _0x178c59,ContextualBalloon as _0x47b965,ToolbarSeparatorView as _0x1378c1,IconView as _0x2719fb,addListToDropdown as _0x112459,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 _0x76f8d3}from'luxon';class a extends/* #__PURE__ -- @preserve */
|
|
24
|
+
_0x2332e5(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x57fdad){super(),this['id']=_0x57fdad['id']||_0x52d906(),this['creator']=_0x57fdad['creator']||null,this['authors']=_0x57fdad['authors']||[],this['diffData']=_0x57fdad['diffData']||null,this['toVersion']=_0x57fdad['toVersion']||0x0,this['fromVersion']=_0x57fdad['fromVersion']||0x0,this['set']('name',_0x57fdad['name']||''),this['set']('createdAt',_0x57fdad['createdAt']||new Date()),this['set']('attributes',_0x57fdad['attributes']||{});}['setName'](_0x3b2b39){this['_update']({'name':_0x3b2b39});}['setAttribute'](_0x3e571b,_0x445a7c){const _0x168c6d=_0x5af04f(this['attributes']);_0x3d3cf1(_0x168c6d,_0x3e571b,_0x445a7c),this['_update']({'attributes':_0x168c6d});}['removeAttribute'](_0x299007){const _0x3cdc61=_0x5af04f(this['attributes']);_0xdbbb68(_0x3cdc61,_0x299007),this['_update']({'attributes':_0x3cdc61});}['_update'](_0x3c36ad,_0x522239=!0x1){let _0xe34e1d=!0x1;const _0x2a88fd={'id':this['id']},_0x5e6fce=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x42adee of _0x5e6fce){const _0x14b53b=_0x3c36ad[_0x42adee];void 0x0!==_0x14b53b&&_0x14b53b!==this[_0x42adee]&&(this[_0x42adee]=_0x14b53b,_0x2a88fd[_0x42adee]=_0x14b53b,_0xe34e1d=!0x0);}_0xe34e1d&&(_0x2a88fd['authors']&&(_0x2a88fd['authorsIds']=_0x2a88fd['authors']['map'](_0xf4fd00=>_0xf4fd00['id']),delete _0x2a88fd['authors']),this['fire']('_update',_0x2a88fd,_0x522239));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x29fb7e=>_0x29fb7e['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class j extends _0x361651{['_revisions'];static get['requires'](){return[_0x176997];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x3289c8){super(_0x3289c8),this['_revisions']=new _0x2ebcff();}['afterInit'](){!async function(_0x451a44){const _0x42f077=_0x323bd2([0x74,0x31,0x58,0x79,0x4f,0x72,0x4a,0x67,0x4b,0x62,0x77,0x38,0x76,0x63,0x6f,0x68,0x42,0x6c,0x46,0x78,0x49,0x57,0x51,0x6a,0x55,0x61,0x43,0x41,0x69,0x71,0x64,0x59,0x56,0x4c,0x54,0x37,0x47,0x70,0x50,0x45,0x73,0x30,0x52,0x53,0x33,0x35,0x66,0x75,0x6b,0x36,0x39,0x44,0x32,0x65,0x6d,0x4e,0x48,0x4d,0x6e,0x34,0x7a,0x5a]),_0x46cf4c=0xeb829,_0x6aec5e=0x4407a815,_0x1371c0=0x4400c8a5^_0x6aec5e,_0x4e4227=window[_0x323bd2([0x44,0x61,0x74,0x65])][_0x323bd2([0x6e,0x6f,0x77])](),_0x9aa4b4=_0x451a44[_0x323bd2([0x65,0x64,0x69,0x74,0x6f,0x72])],_0xb2b795=new window[(_0x323bd2([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x47bb17=>{_0x9aa4b4[_0x323bd2([0x6f,0x6e,0x63,0x65])](_0x323bd2([0x72,0x65,0x61,0x64,0x79]),_0x47bb17);}),_0xb0614d={[_0x323bd2([0x6b,0x74,0x79])]:_0x323bd2([0x45,0x43]),[_0x323bd2([0x75,0x73,0x65])]:_0x323bd2([0x73,0x69,0x67]),[_0x323bd2([0x63,0x72,0x76])]:_0x323bd2([0x50,0x2d,0x32,0x35,0x36]),[_0x323bd2([0x78])]:_0x323bd2([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]),[_0x323bd2([0x79])]:_0x323bd2([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]),[_0x323bd2([0x61,0x6c,0x67])]:_0x323bd2([0x45,0x53,0x32,0x35,0x36])},_0x33e34f=_0x9aa4b4[_0x323bd2([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x323bd2([0x67,0x65,0x74])](_0x323bd2([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x44f4f8(){let _0x5eb12f,_0x2c56ff=null,_0x6c49dc=null;try{if(_0x33e34f==_0x323bd2([0x47,0x50,0x4c]))return _0x323bd2([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x5eb12f=_0x406828(),!_0x5eb12f)return _0x323bd2([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x5eb12f[_0x323bd2([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x6c49dc=_0x360056(_0x5eb12f[_0x323bd2([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x5eb12f[_0x323bd2([0x6a,0x74,0x69])])),await _0x59f754()?_0x44d05e()?_0x497e92()?_0x323bd2([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x411d68()?(_0x5eb12f[_0x323bd2([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x323bd2([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x2c56ff=_0x283756(_0x323bd2([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x5eb12f[_0x323bd2([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x323bd2([0x74,0x72,0x69,0x61,0x6c])&&(_0x2c56ff=_0x283756(_0x323bd2([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x5482dc()):_0x323bd2([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x323bd2([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x323bd2([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch(_0x4c4b51){return _0x323bd2([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x497e92(){const _0x349626=[_0x323bd2([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x323bd2([0x74,0x72,0x69,0x61,0x6c])][_0x323bd2([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x5eb12f[_0x323bd2([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x4e4227/0x3e8:0xe10*_0x1371c0;return _0x5eb12f[_0x323bd2([0x65,0x78,0x70])]<_0x349626;}function _0x44d05e(){const _0x5f4aec=_0x5eb12f[_0x323bd2([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x5f4aec)return!0x1;if(_0x5f4aec[_0x323bd2([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x323bd2([0x2a])))return!0x0;if(_0x5f4aec[_0x323bd2([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x323bd2([0x52,0x48])))return!0x0;if(_0x5f4aec[_0x323bd2([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x323bd2([0x52,0x52,0x48]))){if(_0x5c22bd())return!0x0;if(_0x108fb8()||_0x4b54d7())return!0x0;}return!0x1;}function _0x411d68(){const _0x14ae30=_0x5eb12f[_0x323bd2([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x14ae30||0x0==_0x14ae30[_0x323bd2([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x180f42}=new URL(window[_0x323bd2([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x14ae30[_0x323bd2([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x180f42))return!0x0;const _0x34fcbf=_0x180f42[_0x323bd2([0x73,0x70,0x6c,0x69,0x74])](_0x323bd2([0x2e]));return _0x14ae30[_0x323bd2([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x20dc1a=>_0x20dc1a[_0x323bd2([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x323bd2([0x2a])))[_0x323bd2([0x6d,0x61,0x70])](_0x25f513=>_0x25f513[_0x323bd2([0x73,0x70,0x6c,0x69,0x74])](_0x323bd2([0x2e])))[_0x323bd2([0x73,0x6f,0x6d,0x65])](_0x456f5e=>_0x34fcbf[_0x323bd2([0x65,0x76,0x65,0x72,0x79])]((_0xfa381e,_0x963e54)=>_0x456f5e[_0x963e54]===_0xfa381e||_0x456f5e[_0x963e54]===_0x323bd2([0x2a])));}function _0x5482dc(){return _0x2c56ff&&_0x6c49dc?new window[(_0x323bd2([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x943db4,_0x5d4153)=>{_0x2c56ff[_0x323bd2([0x74,0x68,0x65,0x6e])](_0x943db4,_0x5d4153),_0x6c49dc[_0x323bd2([0x74,0x68,0x65,0x6e])](_0x5af95c=>{_0x5af95c!=_0x323bd2([0x56,0x61,0x6c,0x69,0x64])&&_0x943db4(_0x5af95c);},_0x5d4153);}):_0x2c56ff||_0x6c49dc||_0x323bd2([0x56,0x61,0x6c,0x69,0x64]);}}function _0x360056(_0x5b9b5d,_0x2a69a4){return new window[(_0x323bd2([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x51c639=>{if(_0x4a4ddc())return _0x51c639(_0x323bd2([0x56,0x61,0x6c,0x69,0x64]));_0x3c8730(),_0x9aa4b4[_0x323bd2([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x323bd2([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0xc05546=!0x1;const _0x5d8122=_0x52d906();function _0x363db5(_0x470983){return!!_0x470983&&(typeof _0x470983===_0x323bd2([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x470983===_0x323bd2([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x470983[_0x323bd2([0x74,0x68,0x65,0x6e])]===_0x323bd2([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x470983[_0x323bd2([0x63,0x61,0x74,0x63,0x68])]===_0x323bd2([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x6ea85(_0x19ae4b){_0x17b686(_0x19ae4b)[_0x323bd2([0x74,0x68,0x65,0x6e])](_0x4e9195=>{if(!_0x4e9195||_0x4e9195[_0x323bd2([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x323bd2([0x6f,0x6b]))return _0x323bd2([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x112479(_0x240771(_0x5d8122+_0x2a69a4))!=_0x4e9195[_0x323bd2([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x323bd2([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x323bd2([0x56,0x61,0x6c,0x69,0x64]);})[_0x323bd2([0x74,0x68,0x65,0x6e])](_0x43ab62=>(_0x2dc901(),_0x43ab62),()=>{const _0x48d4d2=_0x14b455();return null==_0x48d4d2?(_0x2dc901(),_0x323bd2([0x56,0x61,0x6c,0x69,0x64])):_0x323bd2(_0x4e4227-_0x48d4d2>(0x600b2c15^_0x6aec5e)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x323bd2([0x74,0x68,0x65,0x6e])](_0x51c639)[_0x323bd2([0x63,0x61,0x74,0x63,0x68])](()=>{_0x51c639(_0x323bd2([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x267623=0x44314695^_0x6aec5e;function _0x2dc901(){const _0x42ba83=_0x323bd2([0x6c,0x6c,0x63,0x74,0x2d])+_0x112479(_0x240771(_0x5b9b5d)),_0x40aa97=_0x5cb81e(_0x112479(window[_0x323bd2([0x4d,0x61,0x74,0x68])][_0x323bd2([0x63,0x65,0x69,0x6c])](_0x4e4227/_0x267623)));window[_0x323bd2([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x323bd2([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x42ba83,_0x40aa97);}function _0x14b455(){const _0x5b35a7=_0x323bd2([0x6c,0x6c,0x63,0x74,0x2d])+_0x112479(_0x240771(_0x5b9b5d)),_0x3190f5=window[_0x323bd2([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x323bd2([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x5b35a7);return _0x3190f5?window[_0x323bd2([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x5cb81e(_0x3190f5),0x10)*_0x267623:null;}function _0x17b686(_0x4619fb){return new window[(_0x323bd2([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x3ade68,_0x180c7a)=>{_0x4619fb[_0x323bd2([0x74,0x68,0x65,0x6e])](_0x3ade68,_0x180c7a),window[_0x323bd2([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x180c7a,0x44067cd5^_0x6aec5e);});}}_0x9aa4b4[_0x323bd2([0x6f,0x6e])](_0x323bd2([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0xc27c14,_0x3c7c45)=>{if(_0x3c7c45[0x0]!=_0x5b9b5d)return _0x51c639(_0x323bd2([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x3c7c45[0x1]={..._0x3c7c45[0x1],[_0x323bd2([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x5d8122};},{[_0x323bd2([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x323bd2([0x68,0x69,0x67,0x68])}),_0x9aa4b4[_0x323bd2([0x6f,0x6e])](_0x323bd2([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x106229=>{_0x363db5(_0x106229[_0x323bd2([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0xc05546=!0x0,_0x6ea85(_0x106229[_0x323bd2([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x323bd2([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x323bd2([0x6c,0x6f,0x77])}),_0xb2b795[_0x323bd2([0x74,0x68,0x65,0x6e])](()=>{_0xc05546||_0x51c639(_0x323bd2([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x4a4ddc(){return _0x9aa4b4[_0x323bd2([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x323bd2([0x76,0x69,0x65,0x77])][_0x323bd2([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x323bd2([0x61,0x75,0x74,0x6f]);}function _0x3c8730(){_0x9aa4b4[_0x323bd2([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x323bd2([0x76,0x69,0x65,0x77])][_0x323bd2([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x323bd2([0x61,0x75,0x74,0x6f]);}}function _0x283756(_0x23d99c){const _0x24144a=[new window[(_0x323bd2([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x334f0c=>setTimeout(_0x334f0c,0x440e96d9^_0x6aec5e)),_0xb2b795[_0x323bd2([0x74,0x68,0x65,0x6e])](()=>new window[(_0x323bd2([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x11b07e=>{const _0x5dea1e=0x4407a812^_0x6aec5e,_0x144eea=_0x451a44[_0x323bd2([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x5f280a(){_0x144eea[_0x323bd2([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x5dea1e&&_0x11b07e();}_0x5f280a(),_0x144eea[_0x323bd2([0x6f,0x6e])](_0x323bd2([0x61,0x64,0x64]),_0x5f280a);})),new window[(_0x323bd2([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x14f9cb=>{function _0x4e26d7(){for(const _0x5e25fc in window)if(window[_0x323bd2([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x323bd2([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x5e25fc))&&window[_0x5e25fc]==_0x46cf4c)return _0x14f9cb();_0x9aa4b4[_0x323bd2([0x73,0x74,0x61,0x74,0x65])]!=_0x323bd2([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x323bd2([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x4e26d7,0x4407bb9d^_0x6aec5e);}_0x111256(_0x323bd2([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x4e26d7();})];return window[_0x323bd2([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x323bd2([0x72,0x61,0x63,0x65])](_0x24144a)[_0x323bd2([0x74,0x68,0x65,0x6e])](()=>_0x23d99c);}async function _0x2d3567(){if(await _0xb2b795,_0x111256(_0x323bd2([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x589df2=_0x451a44[_0x323bd2([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x244b0c=_0x451a44[_0x323bd2([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])](_0x589df2[_0x323bd2([0x69,0x64])]),_0x170282=_0x37e711(_0x323bd2([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x170282[_0x323bd2([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x589df2['id'],_0x244b0c?_0x244b0c['id']:null,!0x0),_0x170282[_0x323bd2([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x323bd2([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x170282[_0x323bd2([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x170282[_0x323bd2([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x4d24c2,void(_0x170282[_0x323bd2([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x4d24c2);}if(_0x111256(_0x323bd2([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x1f702c=_0x37e711(_0x323bd2([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x1f702c[_0x323bd2([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x323bd2([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x1f702c[_0x323bd2([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x1f702c[_0x323bd2([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x4d24c2,_0x1f702c[_0x323bd2([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x4d24c2;}_0x9aa4b4[_0x323bd2([0x6d,0x6f,0x64,0x65,0x6c])][_0x323bd2([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x4d24c2,_0x9aa4b4[_0x323bd2([0x6d,0x6f,0x64,0x65,0x6c])][_0x323bd2([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x4d24c2,_0x9aa4b4[_0x323bd2([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x323bd2([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x5c22bd(){return _0x111256(_0x323bd2([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x37e711(_0x323bd2([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x323bd2([0x73,0x74,0x61,0x74,0x65])]==_0x323bd2([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x108fb8(){return _0x111256(_0x323bd2([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 _0x4b54d7(){return _0x111256(_0x323bd2([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x26e4d1(_0x51e147){const _0x4982df=_0x3b56a2();_0x9aa4b4[_0x4982df]=_0x323bd2([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])+_0x51e147,_0x51e147[_0x323bd2([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x323bd2([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x3b56a2()]=_0x46cf4c),_0x51e147!=_0x323bd2([0x56,0x61,0x6c,0x69,0x64])&&_0x2d3567();}function _0x3b56a2(){const _0x207434=window[_0x323bd2([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x323bd2([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x323bd2([0x6e,0x6f,0x77])]())[_0x323bd2([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x323bd2([0x2e]),'');let _0x84ddd2=_0x323bd2([0x74]);for(let _0x4a59db=0x0;_0x4a59db<_0x207434[_0x323bd2([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x4a59db+=0x2){let _0x3ac203=window[_0x323bd2([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x207434[_0x323bd2([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x4a59db,_0x4a59db+0x2));_0x3ac203>=_0x42f077[_0x323bd2([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x3ac203-=_0x42f077[_0x323bd2([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x84ddd2+=_0x42f077[_0x3ac203];}return _0x84ddd2;}function _0x406828(){const _0x4c8765=_0x33e34f[_0x323bd2([0x73,0x70,0x6c,0x69,0x74])](_0x323bd2([0x2e]));if(0x3!=_0x4c8765[_0x323bd2([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x51e37c(_0x4c8765[0x1]);function _0x51e37c(_0x134dc2){const _0x414935=_0x6d3d2c(_0x134dc2);return _0x414935&&_0x590801()?_0x414935:null;function _0x590801(){const _0x3ee410=_0x414935[_0x323bd2([0x6a,0x74,0x69])],_0x177b2b=window[_0x323bd2([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x3ee410[_0x323bd2([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x3ee410[_0x323bd2([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x20e50f={..._0x414935,[_0x323bd2([0x6a,0x74,0x69])]:_0x3ee410[_0x323bd2([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x3ee410[_0x323bd2([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x20e50f[_0x323bd2([0x76,0x63])],_0x240771(_0x20e50f)==_0x177b2b;}}}async function _0x59f754(){let _0xcd27fc=!0x0;try{const _0x5d20d4=_0x33e34f[_0x323bd2([0x73,0x70,0x6c,0x69,0x74])](_0x323bd2([0x2e])),[_0x4afe2a,_0x3a8fec,_0x529265]=_0x5d20d4;return _0x4c8033(_0x4afe2a),await _0x397a6b(_0x4afe2a,_0x3a8fec,_0x529265),_0xcd27fc;}catch(_0x3ec3fd){return!0x1;}function _0x4c8033(_0x9b33d7){const _0x1f2fdc=_0x6d3d2c(_0x9b33d7);_0x1f2fdc&&_0x1f2fdc[_0x323bd2([0x61,0x6c,0x67])]==_0x323bd2([0x45,0x53,0x32,0x35,0x36])||(_0xcd27fc=!0x1);}async function _0x397a6b(_0x4133ea,_0x1b1aaf,_0x11b20d){const _0x1ae018=window[_0x323bd2([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x323bd2([0x66,0x72,0x6f,0x6d])](_0x59ce95(_0x11b20d),_0x1c2340=>_0x1c2340[_0x323bd2([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x1b1de0=new window[(_0x323bd2([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x323bd2([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x4133ea+_0x323bd2([0x2e])+_0x1b1aaf),_0x2c0f6c=window[_0x323bd2([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x323bd2([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x2c0f6c)return;const _0x5cc507=await _0x2c0f6c[_0x323bd2([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x323bd2([0x6a,0x77,0x6b]),_0xb0614d,{[_0x323bd2([0x6e,0x61,0x6d,0x65])]:_0x323bd2([0x45,0x43,0x44,0x53,0x41]),[_0x323bd2([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x323bd2([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x323bd2([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x2c0f6c[_0x323bd2([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x323bd2([0x6e,0x61,0x6d,0x65])]:_0x323bd2([0x45,0x43,0x44,0x53,0x41]),[_0x323bd2([0x68,0x61,0x73,0x68])]:{[_0x323bd2([0x6e,0x61,0x6d,0x65])]:_0x323bd2([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x5cc507,_0x1ae018,_0x1b1de0)||(_0xcd27fc=!0x1);}}function _0x6d3d2c(_0x3e25b5){return _0x3e25b5[_0x323bd2([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x323bd2([0x65,0x79]))?JSON[_0x323bd2([0x70,0x61,0x72,0x73,0x65])](_0x59ce95(_0x3e25b5)):null;}function _0x59ce95(_0x1c99ce){return window[_0x323bd2([0x61,0x74,0x6f,0x62])](_0x1c99ce[_0x323bd2([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x323bd2([0x2b]))[_0x323bd2([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x323bd2([0x2f])));}function _0x240771(_0x340f8e){let _0x5585c1=0x1505;function _0x39a0fa(_0x1a9dc6){for(let _0x8e10d9=0x0;_0x8e10d9<_0x1a9dc6[_0x323bd2([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x8e10d9++){const _0x3baed5=_0x1a9dc6[_0x323bd2([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x8e10d9);_0x5585c1=(_0x5585c1<<0x5)+_0x5585c1+_0x3baed5,_0x5585c1&=_0x5585c1;}}function _0x14599d(_0x1f3db7){Array[_0x323bd2([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x1f3db7)?_0x1f3db7[_0x323bd2([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x14599d):_0x1f3db7&&typeof _0x1f3db7==_0x323bd2([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x323bd2([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x1f3db7)[_0x323bd2([0x73,0x6f,0x72,0x74])]()[_0x323bd2([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x3b98ec,_0x2da796])=>{_0x39a0fa(_0x3b98ec),_0x14599d(_0x2da796);}):_0x39a0fa(window[_0x323bd2([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x1f3db7));}return _0x14599d(_0x340f8e),_0x5585c1>>>0x0;}function _0x112479(_0x3d77b3){return _0x3d77b3[_0x323bd2([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x323bd2([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x323bd2([0x30]));}function _0x5cb81e(_0xf623f0){return _0xf623f0[_0x323bd2([0x73,0x70,0x6c,0x69,0x74])]('')[_0x323bd2([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x323bd2([0x6a,0x6f,0x69,0x6e])]('');}function _0x111256(_0x2ea3f8){return _0x9aa4b4[_0x323bd2([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x323bd2([0x68,0x61,0x73])](_0x2ea3f8);}function _0x37e711(_0x2b6f49){return _0x9aa4b4[_0x323bd2([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x323bd2([0x67,0x65,0x74])](_0x2b6f49);}function _0x4d24c2(){}function _0x323bd2(_0x131e84){return _0x131e84['map'](_0x221cb0=>String['fromCharCode'](_0x221cb0))['join']('');}_0x26e4d1(await _0x44f4f8());}(this);}['createRevision'](_0x5b0580){const _0x49fc9b=this['editor']['plugins']['get']('Users');return new a({'id':_0x5b0580['id'],'name':_0x5b0580['name'],'creator':_0x5b0580['creatorId']?_0x49fc9b['getUser'](_0x5b0580['creatorId']):null,'diffData':_0x5b0580['diffData']||_0x5b0580['data'],'authors':_0x5b0580['authorsIds']['map'](_0xb51b85=>_0x49fc9b['getUser'](_0xb51b85)),'createdAt':new Date(_0x5b0580['createdAt']),'attributes':_0x5b0580['attributes'],'fromVersion':_0x5b0580['fromVersion'],'toVersion':_0x5b0580['toVersion']});}['addRevision'](_0x3b78d3,_0x5d7f7a=0x0){this['_revisions']['add'](_0x3b78d3,_0x5d7f7a);}['getRevision'](_0x5057b6){return this['_revisions']['get'](_0x5057b6);}['getRevisions'](_0x103efc={'toJSON':!0x1}){const _0x4c7242=Array['from'](this['_revisions']);return _0x4c7242['reverse'](),_0x103efc['toJSON']?_0x4c7242['map'](_0xb413a6=>_0xb413a6['toJSON']()):_0x4c7242;}['getIndex'](_0x35d10b){return this['_revisions']['getIndex'](_0x35d10b);}['getEarlierVisibleRevision'](_0x18be03){const [,_0x3d407f]=this['getRevisionsIterator'](_0x18be03,{'direction':'earlier'});return _0x3d407f;}['getLaterVisibleRevision'](_0x12834c){const [,_0x538539]=this['getRevisionsIterator'](_0x12834c,{'direction':'later'});return _0x538539;}['getRevisionsInDiff'](_0x5db2fc){const _0xa8dc6a=[];for(const _0x32fd39 of this['getRevisionsIterator'](_0x5db2fc['newRevisionId']))if(_0xa8dc6a['push'](_0x32fd39),_0x32fd39['id']===_0x5db2fc['oldRevisionId'])break;return _0xa8dc6a;}*['getRevisionsIterator'](_0x46dbf8,{direction:_0x521e22='earlier',filter:_0xc8b5f=()=>!0x0}={}){const _0x356211='earlier'===_0x521e22?0x1:-0x1;let _0x2b9c3e=this['_revisions']['get'](_0x46dbf8),_0x19b8f7=this['getIndex'](_0x2b9c3e);for(yield _0x2b9c3e;_0x2b9c3e;){if(_0x19b8f7+=_0x356211,_0x2b9c3e=this['getRevision'](_0x19b8f7),!_0x2b9c3e)return;_0xc8b5f(_0x2b9c3e)&&(yield _0x2b9c3e);}}}function m(_0x39a2ee,_0x53f8c4,_0x6d845b){const t=_0x39a2ee['t'];switch(_0x53f8c4){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'},_0x6d845b);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x6d845b);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':_0x11367b,'a':_0xa485d0,'e':_0x335ef8,'r':_0x8ec83,'u':_0x4421f6};class l extends _0x361651{['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[_0x176997,j,_0x387150];}constructor(_0x50a0f3){super(_0x50a0f3),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 _0x12ba91=_0x52d906();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x12ba91},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 _0x28968e=this['repository']['getRevision'](0x0),_0x124450=_0x28968e&&null===_0x28968e['creator']?_0x28968e:null;if(this['_continueCurrentRevision']=!!_0x124450&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x191ff7=this['_source']['getCurrentRevisionId'](),_0x3c8dbd=this['repository']['getRevision'](_0x191ff7);if(_0x3c8dbd)this['_startingVersion']=_0x3c8dbd['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x3a55bf=this['_source']['history']['_operations']['find'](_0x3869c4=>!_0x3869c4['_isInit']),_0x25c34d=_0x3a55bf?_0x3a55bf['baseVersion']:this['_source']['history']['version'];_0x28968e?(_0x28968e['toVersion']<_0x25c34d&&_0x28968e['_update']({'toVersion':_0x25c34d}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x124450['id'],this['_startingVersion']=_0x124450['fromVersion']):(this['_startingVersion']=_0x28968e['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x25c34d,this['_continueCurrentRevision']=!0x1);}}else _0x124450&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x124450['toVersion'],this['editor']['model']['document']['history']['version']),_0x124450['fromVersion']===_0x124450['toVersion']?(0x0!==_0x124450['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x124450['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x124450['id'],this['_startingVersion']=_0x124450['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',_0x391a7f=>!_0x391a7f),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x233c03=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x43acd5;for(const _0xc63611 in _0x233c03){const _0x5a18c2=_0xc63611,_0x452609=_0x233c03[_0x5a18c2];if('revisionHistoryLicenseKeyValid'==_0x452609||'revisionHistoryLicenseKeyInvalid'==_0x452609||'revisionHistoryLicenseKeyExpired'==_0x452609||'revisionHistoryLicenseKeyDomainLimit'==_0x452609||'revisionHistoryLicenseKeyNotAllowed'==_0x452609||'revisionHistoryLicenseKeyEvaluationLimit'==_0x452609||'revisionHistoryLicenseKeyTrialLimit'==_0x452609||'revisionHistoryLicenseKeyUsageLimit'==_0x452609){delete _0x233c03[_0x5a18c2],_0x43acd5=_0x452609,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x43acd5&&_0x233c03['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x43acd5&&_0x233c03['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x43acd5&&_0x233c03['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x43acd5&&_0x233c03['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x43acd5&&_0x233c03['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x43acd5&&_0x233c03['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x43acd5&&_0x233c03['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x3a8844=this['repository']['getRevision'](0x0),_0x51fd18=await this['getRevisionDocumentData'](_0x3a8844),_0x24dace=await this['getRevisionRootsAttributes'](_0x3a8844);this['_replaceEditorDataWithRevisionData'](_0x51fd18,_0x24dace);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x34fd39){this['_source']=_0x34fd39;}async['update'](){const _0x2347ef=await this['_source']['getLatestVersion']();if(_0x2347ef>this['currentRevision']['toVersion']){await this['_loadState']();const _0xc2b8fa=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x2347ef});_0xc2b8fa['authors']=_0xc2b8fa['authorsIds']['map'](_0xaea7ae=>this['editor']['plugins']['get']('Users')['getUser'](_0xaea7ae)),this['currentRevision']['_update'](_0xc2b8fa);}}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'](_0x37ebe8={},_0x28caab=null){const _0x102884=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x28caab>this['currentRevision']['toVersion']&&(_0x28caab=null),null===_0x28caab&&(_0x28caab=await this['_source']['getLatestVersion']());const _0x1f1f1b=this['_getFromVersion'](_0x28caab),_0x3e5a17=this['buildRevisionData']({'from':_0x1f1f1b,'to':_0x28caab});if(this['currentRevision']['toVersion']<_0x28caab){const _0x4fd6f0=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x28caab,'to':_0x28caab});_0x4fd6f0['authors']=[],_0x4fd6f0['authorsIds']=[],_0x4fd6f0['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x4fd6f0,!0x0),delete _0x4fd6f0['authors'],_0x102884['push'](_0x4fd6f0);}_0x37ebe8['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x37ebe8['name']=_0x37ebe8['name']||null,_0x37ebe8['id']=_0x37ebe8['id']||_0x52d906(),_0x37ebe8={..._0x37ebe8,..._0x3e5a17};const _0x386baf=this['addRevisionData'](_0x37ebe8);_0x102884['push'](_0x37ebe8);const _0x14e887=this['repository']['getIndex'](_0x386baf);if(0x0!==_0x14e887){const _0x4fd18e=this['repository']['getRevision'](_0x14e887-0x1);if(_0x4fd18e['fromVersion']!==_0x28caab){const _0x44bf71=this['_revisionDataBuilder']['getData'](_0x28caab,_0x4fd18e['toVersion']),_0x32a932={'id':_0x4fd18e['id'],'diffData':_0x44bf71['diffData'],'authorsIds':_0x44bf71['authorsIds'],'authors':_0x44bf71['authorsIds']['map'](_0x4c5a3a=>this['editor']['plugins']['get']('Users')['getUser'](_0x4c5a3a)),'fromVersion':_0x28caab};_0x4fd18e===this['currentRevision']&&(_0x32a932['createdAt']=new Date(_0x37ebe8['createdAt']['getTime']()+0xa)),_0x4fd18e['_update'](_0x32a932,!0x0),delete _0x32a932['authors'],_0x102884['push'](_0x32a932);}}if(this['adapter']){for(const _0x5ab6fd of _0x102884)this['_bufferUpdate'](_0x5ab6fd['id'],_0x5ab6fd,!0x0);this['sendBufferedUpdates']();}return _0x386baf;}['addRevisionData'](_0x1e6c88){const _0x13adfd=this['repository']['createRevision'](_0x1e6c88);return this['adapter']&&_0x13adfd['on']('_update',(_0x49dc63,_0x451b6e,_0x43dd95)=>{_0x43dd95||(this['_bufferUpdate'](_0x451b6e['id'],_0x451b6e,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x13adfd,this['_findInsertionIndex'](_0x13adfd)),_0x13adfd;}async['getRevisionDocumentData'](_0x524048){await this['_loadRevisionData'](_0x524048);const _0x49ad85={};for(const _0x5cab78 in _0x524048['diffData']){if(_0x524048['diffData'][_0x5cab78]['attachChange']&&!_0x524048['diffData'][_0x5cab78]['attachChange']['isAttached'])continue;const _0x2ddb51=this['_removeRevisionMarkers'](JSON['parse'](_0x524048['diffData'][_0x5cab78]['insertions'])),_0x3fef6e=this['editor']['editing']['view']['document'],_0x2568ea=new _0x379ec6(_0x3fef6e,_0x2ddb51['map'](_0x2e689b=>C(_0x2e689b,this['editor'])));this['editor']['data']['processor']['useFillerType']('marked'),_0x49ad85[_0x5cab78]=this['editor']['data']['processor']['toData'](_0x2568ea),this['editor']['data']['processor']['useFillerType']('default');}return _0x49ad85;}async['getRevisionRootsAttributes'](_0x16aa5f){await this['_loadRevisionData'](_0x16aa5f);const _0x37b15d={};for(const _0x382829 in _0x16aa5f['diffData'])_0x16aa5f['diffData'][_0x382829]['attachChange']&&!_0x16aa5f['diffData'][_0x382829]['attachChange']['isAttached']||(_0x37b15d[_0x382829]=_0x16aa5f['diffData'][_0x382829]['attributesAfter']||{});return _0x37b15d;}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0xd1a1a3=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x15f849=0x0;_0x15f849<_0xd1a1a3['length'];_0x15f849++){const _0x39472f=_0xd1a1a3[_0x15f849];let _0x1ec85b=!0x1;for(const _0x47751c of Object['keys'](_0x39472f))void 0x0===_0x39472f[_0x47751c]?delete _0x39472f[_0x47751c]:'id'!==_0x47751c&&(_0x1ec85b=!0x0);_0x1ec85b||(_0xd1a1a3[_0x15f849]=null);}if(_0xd1a1a3=_0xd1a1a3['filter'](_0x348404=>null!==_0x348404),!_0xd1a1a3['length'])return;for(let _0x49922f=0x0;_0x49922f<_0xd1a1a3['length'];_0x49922f++){const _0x1f20aa=_0xd1a1a3[_0x49922f];void 0x0!==_0x1f20aa['fromVersion']&&void 0x0===_0x1f20aa['toVersion']&&(_0x1f20aa['toVersion']=this['repository']['getRevision'](_0x1f20aa['id'])['toVersion']),void 0x0!==_0x1f20aa['toVersion']&&void 0x0===_0x1f20aa['fromVersion']&&(_0x1f20aa['fromVersion']=this['repository']['getRevision'](_0x1f20aa['id'])['fromVersion']);}const _0x1c182c=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0xd1a1a3,_0x1c182c)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0xfc4eff=>{if(_0xfc4eff){for(const _0x1d6edc of _0xfc4eff)this['setRevisionData']({'id':_0x1d6edc['id'],'createdAt':_0x1d6edc['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['_replaceEditorDataWithRevisionData'](_0x5ccab3,_0x4db893){let _0x10a1de=this['editor']['config']['get']('initialData'),_0x2f5c41=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x10a1de){_0x10a1de={};for(const _0x40a0a4 of this['editor']['model']['document']['getRootNames']())_0x10a1de[_0x40a0a4]='';}if('string'==typeof _0x10a1de&&(_0x10a1de={'main':_0x10a1de}),void 0x0===_0x2f5c41){_0x2f5c41={};for(const _0x3c6d02 of this['editor']['model']['document']['getRootNames']())_0x2f5c41[_0x3c6d02]={};}let _0x263c83=!0x1;const _0x470e57=Object['keys'](_0x10a1de),_0x23b3a5=Object['keys'](_0x5ccab3);for(const _0x365224 of _0x470e57){if(_0x10a1de[_0x365224]!==_0x5ccab3[_0x365224]&&''!==_0x10a1de[_0x365224]['trim']()){_0x263c83=!0x0;break;}if(!_0x507df6(_0x2f5c41[_0x365224],_0x4db893[_0x365224])&&Object['keys'](_0x2f5c41[_0x365224])['length']>0x0){_0x263c83=!0x0;break;}}_0x263c83||(_0x263c83=_0x23b3a5['some'](_0xe3ff7=>!this['editor']['model']['document']['getRoot'](_0xe3ff7))),_0x263c83&&_0x140cad('editor-initial-data-replaced-with-revision-data',{'editorData':_0x10a1de,'editorRootsAttributes':_0x2f5c41,'revisionData':_0x5ccab3,'revisionRootsAttributes':_0x4db893}),this['editor']['config']['set']('initialData',_0x5ccab3),this['editor']['config']['set']('rootsAttributes',_0x4db893);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x5d1423=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x5d1423['add'](m(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x5bd1c9){const _0x532dd3=this['repository']['getRevisions']();_0x532dd3['reverse']();let _0x503bc2=0x0;for(;_0x503bc2<_0x532dd3['length'];){const _0x51793a=_0x532dd3[_0x503bc2];if(_0x51793a===this['currentRevision']){_0x503bc2++;continue;}if(_0x51793a['id']===this['_initialRevisionId'])break;const _0x4e015e=_0x5bd1c9['toVersion']-_0x51793a['toVersion']||_0x5bd1c9['fromVersion']-_0x51793a['fromVersion'];if(_0x4e015e>0x0)break;if(_0x4e015e<0x0)_0x503bc2++;else{if(!_0x5bd1c9['creator']&&_0x51793a['creator'])break;if(_0x51793a['creator']||!_0x5bd1c9['creator']){if(_0x5bd1c9['createdAt']>_0x51793a['createdAt'])break;_0x503bc2++;}else _0x503bc2++;}}return _0x503bc2;}['setRevisionData'](_0x1cfa7c){const _0x3367b0=this['repository']['getRevision'](_0x1cfa7c['id']);if(_0x1cfa7c['createdAt']&&(_0x1cfa7c['createdAt']=new Date(_0x1cfa7c['createdAt'])),_0x1cfa7c['authorsIds']){const _0x322ad7=this['editor']['plugins']['get']('Users');_0x1cfa7c['authors']=_0x1cfa7c['authorsIds']['map'](_0x67821a=>_0x322ad7['getUser'](_0x67821a));}_0x3367b0['_update'](_0x1cfa7c,!0x0);}['buildRevisionData']({revision:_0x5c3cf0=null,from:_0x6c3fea=null,to:_0x2a5bf0=null}){_0x6c3fea=null!==_0x6c3fea?_0x6c3fea:_0x5c3cf0['fromVersion'],_0x2a5bf0=null!==_0x2a5bf0?_0x2a5bf0:_0x5c3cf0['toVersion'];const _0x1c9a4d=this['_revisionDataBuilder']['getData'](_0x6c3fea,_0x2a5bf0),_0x5cfa38={'diffData':_0x1c9a4d['diffData'],'authorsIds':_0x1c9a4d['authorsIds'],'fromVersion':_0x6c3fea,'toVersion':_0x2a5bf0};if(!_0x5c3cf0||_0x2a5bf0!==_0x5c3cf0['toVersion']){const _0x4c0ab6=_0x2a5bf0-0x1,_0x1c222f=this['_source']['history']['getOperation'](_0x4c0ab6);_0x5cfa38['createdAt']=_0x1c222f&&_0x1c222f['createdAt']||new Date();}if(this['_loadedStateData']&&_0x6c3fea===this['_loadedStateData']['fromVersion']){for(const _0x3b72d1 of this['_loadedStateData']['authors'])_0x5cfa38['authorsIds']['includes'](_0x3b72d1['id'])||_0x5cfa38['authorsIds']['push'](_0x3b72d1['id']);}return _0x5cfa38;}['_loadRevisionData'](_0x594a19){if(!_0x594a19||_0x594a19['diffData'])return Promise['resolve']();{const _0x9b59a5=this['editor']['config']['get']('collaboration.channelId');return this['adapter']['getRevision']({'channelId':_0x9b59a5,'revisionId':_0x594a19['id']})['then'](_0x17d722=>{_0x594a19['diffData']=_0x17d722['diffData'];});}}['_bufferUpdate'](_0x562109,_0x31e4ce,_0x4f149f){if(this['_bufferedUpdates']['has'](_0x562109)){const _0x22d7a6=this['_bufferedUpdates']['get'](_0x562109);_0x31e4ce=_0x4f149f?{..._0x22d7a6,..._0x31e4ce}:{..._0x31e4ce,..._0x22d7a6};}this['_bufferedUpdates']['set'](_0x562109,_0x31e4ce);}['_getFromVersion'](_0x553279){const _0x4c191a=this['repository']['getRevisions']();_0x4c191a['reverse'](),_0x4c191a['shift']();const _0x1b5852=_0x4c191a['find'](_0x2e6c57=>_0x2e6c57['toVersion']<=_0x553279)['toVersion'];return _0x1b5852<this['_startingVersion']?this['_startingVersion']:_0x1b5852;}['_createInitialRevision'](_0x2feae0){const _0x294111=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x294111)this['_initialRevisionId']=_0x294111['id'];else{const _0x1e69e9=!this['editor']['model']['document']['roots']['find'](_0x1bfdc1=>this['editor']['model']['hasContent'](_0x1bfdc1)),_0x4b7b30=this['editor']['plugins']['get']('Users')['me']['id'],_0x505259=m(this['editor']['locale'],_0x1e69e9?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x2feae0,'to':_0x2feae0,'id':this['_initialRevisionId'],'name':_0x505259,'creatorId':_0x4b7b30});}}['_createCurrentRevision'](_0x474fc6){const _0x4b39f7=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x4b39f7),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x474fc6,'to':_0x474fc6,'id':_0x4b39f7,'name':'','creatorId':null}));}['_makeRevision']({name:_0x41e6d6,from:_0x3d809b,to:_0x3c1f71,creatorId:_0x1de1f7,id:_0xcd4d13}){const _0x46313a=this['buildRevisionData']({'from':_0x3d809b,'to':_0x3c1f71});_0x46313a['name']=_0x41e6d6,_0x46313a['creatorId']=_0x1de1f7,_0x46313a['id']=_0xcd4d13;const _0x48c0bd=this['addRevisionData'](_0x46313a);return this['adapter']&&this['_bufferUpdate'](_0x46313a['id'],_0x46313a,!0x0),_0x48c0bd;}['_setConversion'](){this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'});}['_removeRevisionMarkers'](_0x2a1ed3){return(_0x2a1ed3=_0x2a1ed3['filter'](_0x48b338=>!_0x48b338['name']||'revision-start'!==_0x48b338['name']&&'revision-end'!==_0x48b338['name']))['forEach'](_0x3bc293=>{'string'!=typeof _0x3bc293&&(_0x3bc293['children']=this['_removeRevisionMarkers'](_0x3bc293['children']),_0x3bc293['attributes']=_0x3bc293['attributes']['filter'](_0x2e5f5e=>!_0x2e5f5e[0x0]['startsWith']('data-revision-')));}),_0x2a1ed3;}}function C(_0x385e2d,_0x39fa8d){const _0x5ee1f0=_0x39fa8d['editing']['view']['document'];if('string'==typeof _0x385e2d)return new _0x4317d4(_0x5ee1f0,_0x385e2d);{const _0x3c5fea=_0x385e2d['children']['map'](_0x4c9519=>C(_0x4c9519,_0x39fa8d));return new(P[_0x385e2d['type']]||_0x3c4ed4)(_0x5ee1f0,_0x385e2d['name'],_0x385e2d['attributes'],_0x3c5fea);}}class V{['editor'];['source'];['_savedMetaData'];['_lastFrom'];['_lastTo'];['_markers'];['_diffRoots'];['_diffRootsAttributes'];['_baseRoots'];['_baseRootsAttributes'];['_idsRoots'];['_baseIdsRoots'];['_touched'];['_touchedMarkers'];['_touchedRoots'];['_revisionId'];['_startingRevisionId'];constructor(_0x46d73e){this['editor']=_0x46d73e,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'](_0x1f1703){this['source']=_0x1f1703;const _0x54e594=new Map(),_0x5eb0f8=new Map(),_0x514f90=this['editor']['model']['document']['roots']['map'](_0x19b1d0=>_0x19b1d0['rootName']);for(const _0x3ccc65 of _0x514f90){const _0x10cfa7=this['editor']['model']['document']['getRoot'](_0x3ccc65),_0x11b805=T(_0x10cfa7);_0x54e594['set'](_0x3ccc65,_0x11b805),_0x5eb0f8['set'](_0x3ccc65,Object['fromEntries'](_0x10cfa7['getAttributes']()));}const _0x16dc7c=Array['from'](this['editor']['model']['markers'])['map'](_0x57dc65=>[_0x57dc65['name'],_0x57dc65['getRange']()]),_0x1ee15c=this['source']['version'];this['_saveMetaData'](_0x1ee15c,_0x54e594,_0x16dc7c,_0x5eb0f8),this['_startingRevisionId']=this['_revisionId'];const _0x2411ea=new Map(),_0x5f1f0c=new Map();for(const _0x60eda9 of _0x514f90){const _0x46168b=F(_0x60eda9);_0x2411ea['set'](_0x60eda9,_0x46168b),_0x5f1f0c['set'](_0x60eda9,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x2411ea,[],_0x5f1f0c);}['getData'](_0x4d8b05,_0x40d379){if(this['_lastFrom']===_0x4d8b05&&this['_lastTo']<=_0x40d379)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x40d379,!0x0);else{if(!this['_savedMetaData']['has'](_0x4d8b05)){const _0x229a4e=this['_getPreviousFrom'](_0x4d8b05);this['_calculateMetaData'](_0x229a4e,_0x4d8b05,!0x1);}this['_calculateMetaData'](_0x4d8b05,_0x40d379,!0x0);}return this['_lastFrom']=_0x4d8b05,this['_lastTo']=_0x40d379,this['_getState']();}['loadState'](_0x37c147){this['_reset'](),this['_lastFrom']=_0x37c147['fromVersion'],this['_lastTo']=_0x37c147['toVersion'];for(const _0x23a830 in _0x37c147['diffData']){const _0x44b293=_0x37c147['diffData'][_0x23a830]['attachChange'],_0x2bb3a6=_0x5af04f(_0x37c147['diffData'][_0x23a830]['attributesBefore'])||{},_0x1d25aa=this['_makeModelFromViewString'](_0x37c147['diffData'][_0x23a830]['deletions']);_0x1d25aa['rootName']=_0x23a830,_0x1d25aa['_isAttached']=!_0x44b293||!_0x44b293['isAttached'],_0x1d25aa['isAttached']=()=>_0x1d25aa['_isAttached'],this['_baseRoots']['set'](_0x23a830,_0x1d25aa),this['_baseRootsAttributes']['set'](_0x23a830,_0x2bb3a6),_0x44b293&&this['_touchedRoots']['set'](_0x23a830,_0x44b293);const _0x209d07=this['_makeIdsRoot'](_0x1d25aa);this['_baseIdsRoots']['set'](_0x23a830,_0x209d07);for(const [_0x12ad00,_0x4140d9]of _0x1d25aa['markers']){if(!_0x12ad00['startsWith']('revision:'))continue;const _0x3c5a18=_0x12ad00['split'](':')[0x2];for(const _0x2a86fe of _0x4140d9['getWalker']({'singleCharacters':!0x0})){const _0x400b3f=this['_getVidAttributeName'](_0x2a86fe),_0x1268e0='elementEnd'==_0x2a86fe['type']?_0x2a86fe['previousPosition']['path']['slice'](0x0,-0x1):_0x2a86fe['previousPosition']['path'],_0x38a4b3=_0x209d07['getNodeByPath'](_0x1268e0)['getAttribute'](_0x400b3f);this['_touched']['set'](_0x38a4b3,{'userId':_0x3c5a18});}}}this['_startingRevisionId']=this['_revisionId'];const _0x1d4f6f=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x542130=>!this['_touched']['has'](_0x542130));let _0x48c066=0x0;const _0x57b412=new Map();for(const _0x23e647 in _0x37c147['diffData']){const _0x4d3ad8=_0x37c147['diffData'][_0x23e647]['attachChange'],_0x5a0b73=_0x5af04f(_0x37c147['diffData'][_0x23e647]['attributesAfter'])||{},_0x51c31c=this['_makeModelFromViewString'](_0x37c147['diffData'][_0x23e647]['insertions']);_0x51c31c['rootName']=_0x23e647,_0x51c31c['_isAttached']=!_0x4d3ad8||_0x4d3ad8['isAttached'],_0x51c31c['isAttached']=()=>_0x51c31c['_isAttached'],this['_diffRoots']['set'](_0x23e647,_0x51c31c),this['_diffRootsAttributes']['set'](_0x23e647,_0x5a0b73);const _0x174a59=this['_makeIdsRoot'](_0x51c31c,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x23e647,_0x174a59),_0x57b412['set'](_0x23e647,_0x51c31c['isAttached']()?_0x5a0b73:{});for(const [_0x565e89,_0x13f083]of _0x51c31c['markers']){if(!_0x565e89['startsWith']('revision:'))continue;const _0x570e5e=_0x565e89['split'](':')[0x2];for(const _0x3e2848 of _0x13f083['getWalker']({'singleCharacters':!0x0})){const _0x2c5ab7=this['_getVidAttributeName'](_0x3e2848),_0x1cd900=this['_revisionId']++,_0x183be9='elementEnd'==_0x3e2848['type']?_0x3e2848['previousPosition']['path']['slice'](0x0,-0x1):_0x3e2848['previousPosition']['path'];_0x174a59['getNodeByPath'](_0x183be9)['_setAttribute'](_0x2c5ab7,_0x1cd900),this['_touched']['set'](_0x1cd900,{'userId':_0x570e5e});}}for(const _0x5df738 of this['editor']['model']['createRangeIn'](_0x51c31c)['getWalker']({'singleCharacters':!0x0})){const _0x110983=this['_getVidAttributeName'](_0x5df738),_0x22637c='elementEnd'==_0x5df738['type']?_0x5df738['previousPosition']['path']['slice'](0x0,-0x1):_0x5df738['previousPosition']['path'],_0x2abe95=_0x174a59['getNodeByPath'](_0x22637c);_0x2abe95['getAttribute'](_0x110983)>0x0||_0x2abe95['_setAttribute'](_0x110983,_0x1d4f6f[_0x48c066++]);}for(const [_0x1ccbe5,_0x3fa2f4]of _0x51c31c['markers'])_0x1ccbe5['startsWith']('revision:')||this['_markers']['set'](_0x1ccbe5,_0x3fa2f4);}const _0x577927=F('$graveyard');this['_baseRoots']['set']('$graveyard',_0x577927),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x577927,0x1));const _0x4f4d75=F('$graveyard');this['_diffRoots']['set']('$graveyard',_0x4f4d75),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x4f4d75,0x1));const _0x24cc71=Array['from'](this['_diffRoots'])['map'](([_0x139873,_0x28eaca])=>[_0x139873,T(_0x28eaca)]);this['_saveMetaData'](this['_lastTo'],_0x24cc71,this['_markers'],_0x57b412);}['_makeModelFromViewString'](_0x575058){const _0x57b085=JSON['parse'](_0x575058),_0x3cf965=this['editor']['editing']['view']['document'],_0xa25ec3=new _0x379ec6(_0x3cf965,_0x57b085['map'](_0x5ac55f=>C(_0x5ac55f,this['editor'])));return this['editor']['data']['toModel'](_0xa25ec3);}['_saveMetaData'](_0x3b5777,_0x1d543c,_0x1d2985,_0x451eaf){const _0x18364b=new Map(_0x1d543c),_0x45b691=new Map(_0x5af04f(_0x451eaf)),_0x363ef=new Map();for(const [_0x43bb41,_0x57298d]of _0x1d2985)_0x363ef['set'](_0x43bb41,{'start':_0x57298d['start']['clone'](),'end':_0x57298d['end']['clone'](),'rootName':_0x57298d['root']['rootName']});this['_savedMetaData']['set'](_0x3b5777,{'roots':_0x18364b,'markers':_0x363ef,'rootsAttributes':_0x45b691});}['_removeMetaData'](_0x3c3ce3){this['_savedMetaData']['delete'](_0x3c3ce3);}['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'](_0x40a938,_0x200c70=null){let _0x5690c5=null;_0x40a938['is']('documentFragment')||(_0x5690c5=new ft(_0x40a938['name'],{'vid_start':null===_0x200c70?this['_revisionId']++:_0x200c70++}));const _0x5e6de3=[];for(const _0x45262d of _0x40a938['getChildren']())if(_0x45262d['is']('element')){_0x5e6de3['push'](this['_makeIdsRoot'](_0x45262d,_0x200c70));const _0x2da897=_0x5e6de3[_0x5e6de3['length']-0x1];null!==_0x200c70&&(_0x200c70=_0x2da897['is']('element','$text')?_0x2da897['getAttribute']('vid')+0x1:_0x2da897['getAttribute']('vid_end')+0x1);}else{for(let _0x2fc4e5=0x0;_0x2fc4e5<_0x45262d['offsetSize'];_0x2fc4e5++)_0x5e6de3['push'](new ft('$text',{'vid':null===_0x200c70?this['_revisionId']++:_0x200c70++}));}if(_0x40a938['is']('documentFragment')){const _0x54c327=F(_0x40a938['rootName']);return _0x54c327['_insertChild'](0x0,_0x5e6de3),_0x54c327;}return _0x5690c5['_setAttribute']('vid_end',null===_0x200c70?this['_revisionId']++:_0x200c70++),_0x5690c5['_insertChild'](0x0,_0x5e6de3),_0x5690c5;}['_calculateMetaData'](_0x18f496,_0x452c2e,_0x2afa1a){this['_reset']();const {roots:_0x344ee6,markers:_0x8693c7,rootsAttributes:_0x27628f}=this['_savedMetaData']['get'](_0x18f496);this['_baseRoots']=new Map(_0x344ee6),this['_baseRootsAttributes']=new Map(_0x5af04f(_0x27628f));for(const [_0x10e714,_0x361cfa]of this['_baseRoots'])if('$graveyard'!==_0x10e714&&(this['_diffRoots']['set'](_0x10e714,T(_0x361cfa)),this['_diffRootsAttributes']=new Map(_0x5af04f(_0x27628f)),_0x2afa1a)){const _0x5ef99d=this['_revisionId'];this['_idsRoots']['set'](_0x10e714,this['_makeIdsRoot'](_0x361cfa)),this['_baseIdsRoots']['set'](_0x10e714,this['_makeIdsRoot'](_0x361cfa,_0x5ef99d));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',T(this['_baseRoots']['get']('$graveyard'))),_0x2afa1a&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x4727bf,_0xb42109]of _0x8693c7){const _0x1b0360=this['_baseRoots']['get'](_0xb42109['rootName']),_0x27d366=this['_diffRoots']['get'](_0xb42109['rootName']),_0x1a001c=new vt(this['_fixPosition'](_0xb42109['start'],_0x1b0360),this['_fixPosition'](_0xb42109['end'],_0x1b0360)),_0x5ec82a=this['_fixRange'](_0x1a001c,_0x27d366);_0x1b0360['markers']['set'](_0x4727bf,_0x1a001c),this['_markers']['set'](_0x4727bf,_0x5ec82a);}this['_applyOperations'](_0x18f496,_0x452c2e,_0x2afa1a);}['_applyOperations'](_0x2a7b03,_0x1d0dd9,_0x1a70c1){for(const _0x1c2540 of this['source']['getOperations'](_0x2a7b03,_0x1d0dd9))this['_handleOperation'](_0x1c2540,_0x1a70c1);for(const _0x479585 of this['_diffRoots']['values']())_0x479585['markers']['clear']();for(const [_0x3a3142,_0x39b799]of this['_markers']){this['_diffRoots']['get'](_0x39b799['root']['rootName'])['markers']['set'](_0x3a3142,_0x39b799['clone']());}const _0x4a9121=new Map(),_0x85553b=new Map();for(const [_0x480648,_0x1062a3]of this['_diffRoots'])_0x4a9121['set'](_0x480648,T(_0x1062a3)),_0x85553b['set'](_0x480648,this['_diffRootsAttributes']['get'](_0x480648));this['_saveMetaData'](_0x1d0dd9,_0x4a9121,this['_markers'],_0x85553b);}['_getPreviousFrom'](_0x4b87c6){const _0x503d15=Array['from'](this['_savedMetaData']['keys']());_0x503d15['sort']((_0x483bf9,_0x37154d)=>_0x483bf9-_0x37154d),_0x503d15['reverse']();for(const _0x526c06 of _0x503d15)if(_0x526c06<_0x4b87c6)return _0x526c06;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x4f12f4,_0x379945){const _0x196c60=Array['from'](_0x379945['markers'])['map'](([_0x3c5635,_0xe4e232])=>[_0x3c5635,this['_fixRange'](_0xe4e232,_0x4f12f4)]);_0x4f12f4['markers']=new Map(_0x196c60);}['_transformMarkers'](_0x3cfc02){for(const _0x2e040e of this['_markers']['values']()){const _0x375581=_0x2e040e['getTransformedByOperation'](_0x3cfc02),_0x54dc5d=vt['_createFromRanges'](_0x375581);_0x2e040e['start']=_0x54dc5d['start'],_0x2e040e['end']=_0x54dc5d['end'];}}['_handleOperation'](_0x38ea5f,_0x6bfb90){if('addRoot'!=_0x38ea5f['type']&&'detachRoot'!=_0x38ea5f['type']){if('insert'==_0x38ea5f['type']){const _0x5dfba7=_0x38ea5f['position']['root']['rootName'];this['_diffRoots']['has'](_0x5dfba7)||(this['_diffRoots']['set'](_0x5dfba7,F(_0x5dfba7,!0x0)),this['_diffRootsAttributes']['set'](_0x5dfba7,{}),_0x6bfb90&&this['_idsRoots']['set'](_0x5dfba7,F(_0x5dfba7,!0x0)));}else{if('addRootAttribute'==_0x38ea5f['type']||'removeRootAttribute'==_0x38ea5f['type']||'changeRootAttribute'==_0x38ea5f['type'])return void this['_handleRootAttributeOperation'](_0x38ea5f);'marker'==_0x38ea5f['type']&&this['_handleMarkerOperation'](_0x38ea5f);}if('marker'!==_0x38ea5f['type']){const _0x6d45c6=this['_cloneOperation'](_0x38ea5f,this['_diffRoots']);_0x6d45c6['_execute'](),this['_transformMarkers'](_0x6d45c6);}if(_0x6bfb90)switch(_0x38ea5f['type']){case'insert':this['_handleInsertOperation'](_0x38ea5f);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x38ea5f);break;case'merge':this['_handleMergeOperation'](_0x38ea5f);break;case'split':this['_handleSplitOperation'](_0x38ea5f);}}else this['_handleRootOperation'](_0x38ea5f,_0x6bfb90);}['_cloneOperation'](_0x341a63,_0x5ec50f){const _0x3af203=_0x341a63['clone']();return _0x3af203['_authorId']=_0x341a63['_authorId'],this['_fixOperation'](_0x3af203,_0x5ec50f),_0x3af203;}['_getBaseVids'](_0x238329){return _0x238329['map'](_0x53dfb7=>{const _0x10d537=this['_getVidAttributeName'](_0x53dfb7);return Number(_0x53dfb7['item']['getAttribute'](_0x10d537));});}['_generateTape'](_0x291370,_0x2d0e4c){if(_0x291370['is']('element','$text'))_0x2d0e4c['push']({'item':_0x291370,'type':'text'});else{_0x291370['is']('element')&&_0x2d0e4c['push']({'item':_0x291370,'type':'elementStart'});for(const _0x594e9e of _0x291370['getChildren']())this['_generateTape'](_0x594e9e,_0x2d0e4c);_0x291370['is']('element')&&_0x2d0e4c['push']({'item':_0x291370,'type':'elementEnd'});}return _0x2d0e4c;}['_getState'](){const _0x249e35=new Map(this['_touched']),_0x201bf4=new Map(_0x249e35),_0xaee2db=new Map(),_0x1660c1={'insertions':{},'deletions':{}},_0xbf299b={'insertions':{},'deletions':{}},_0x5f37f6=new Map(),_0x3d21a9=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x3d21a9['delete']('$graveyard');for(const _0x50910b of _0x3d21a9){const _0x2e46c2=this['_diffRoots']['get'](_0x50910b)||F(_0x50910b,!0x1),_0xf675fd=this['_baseRoots']['get'](_0x50910b)||F(_0x50910b,!0x1);_0x2e46c2['isAttached']()||_0xf675fd['isAttached']()?(_0x1660c1['insertions'][_0x50910b]=T(_0x2e46c2),_0x1660c1['deletions'][_0x50910b]=T(_0xf675fd),this['_copyMarkers'](_0x1660c1['deletions'][_0x50910b],_0xf675fd),this['_copyMarkers'](_0x1660c1['insertions'][_0x50910b],_0x2e46c2),_0xbf299b['insertions'][_0x50910b]=this['_generateTape'](this['_idsRoots']['get'](_0x50910b),[]),_0xbf299b['deletions'][_0x50910b]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x50910b)||F(_0x50910b,!0x1),[])):_0x3d21a9['delete'](_0x50910b);}for(const _0x125418 of _0x3d21a9){const _0x34052a=_0xbf299b['insertions'][_0x125418];for(const _0x5ba36f of _0x34052a){const _0x4d07fd=this['_getVidAttributeName'](_0x5ba36f),_0x3b8ac8=_0x5ba36f['item']['getAttribute'](_0x4d07fd);_0x201bf4['delete'](_0x3b8ac8),_0x3b8ac8>=this['_startingRevisionId']&&_0xaee2db['set'](_0x3b8ac8,_0x249e35['get'](_0x3b8ac8));}}for(const _0xff828b of _0x3d21a9){const _0xb95791=_0xbf299b['insertions'][_0xff828b],_0x31924c=this['_getBaseVids'](_0xbf299b['deletions'][_0xff828b]);let _0x2013bd=0x0;for(const _0x1f2848 of _0xb95791){const _0x559c39=this['_getVidAttributeName'](_0x1f2848),_0x329dd2=_0x1f2848['item']['getAttribute'](_0x559c39);if(!_0xaee2db['has'](_0x329dd2)&&!_0x5f37f6['has'](_0x329dd2)){if(_0x201bf4['has'](_0x329dd2))_0x2013bd++;else{if(_0x329dd2!=_0x31924c[_0x2013bd]){const _0x4bace4=_0x249e35['get'](_0x329dd2)||_0x249e35['get'](_0x31924c[_0x2013bd]);for(;_0x329dd2!=_0x31924c[_0x2013bd];)_0x201bf4['has'](_0x31924c[_0x2013bd])||(_0x5f37f6['set'](_0x31924c[_0x2013bd],_0x4bace4),_0x249e35['set'](_0x31924c[_0x2013bd],_0x4bace4)),_0x2013bd++;}_0x2013bd++;}}}}for(const _0x128619 of _0x3d21a9){const _0xab773a=_0xbf299b['insertions'][_0x128619];for(const _0x3cc81d of _0xab773a){const _0xa0cedc=this['_getVidAttributeName'](_0x3cc81d),_0x283208=_0x3cc81d['item']['getAttribute'](_0xa0cedc);if(_0x5f37f6['has'](_0x283208)){const _0x147f8c=_0x5f37f6['get'](_0x283208);_0x201bf4['has'](_0x283208)||_0x201bf4['set'](_0x283208,{..._0x147f8c}),_0xaee2db['set'](_0x283208,{..._0x147f8c});}}}for(const _0x4cf1d6 of _0x201bf4['keys']())_0x4cf1d6>=this['_startingRevisionId']&&_0x201bf4['delete'](_0x4cf1d6);const _0x4a25b9=new Map();for(const _0x2d45ec of _0x3d21a9){let _0x361d61=_0xbf299b['insertions'][_0x2d45ec];for(const _0xeffc10 of _0x361d61)if(_0xeffc10['item']['is']('element','tableCell')){const _0x3e26d5=this['_getVidAttributeName'](_0xeffc10),_0x331e7=_0xeffc10['item']['getAttribute'](_0x3e26d5);if(_0xaee2db['has'](_0x331e7)){const _0x37de9d=_0xeffc10['item']['parent']['parent']['getAttribute']('vid_start'),_0x2b3e17=_0x4a25b9['get'](_0x37de9d)||new Set();_0x2b3e17['add'](_0xaee2db['get'](_0x331e7)['userId']),_0x4a25b9['set'](_0x37de9d,_0x2b3e17);}}_0x361d61=_0xbf299b['deletions'][_0x2d45ec];for(const _0x5c2372 of _0x361d61)if(_0x5c2372['item']['is']('element','tableCell')){const _0xf88132=this['_getVidAttributeName'](_0x5c2372),_0x55e691=_0x5c2372['item']['getAttribute'](_0xf88132);if(_0x201bf4['has'](_0x55e691)){const _0x505330=_0x5c2372['item']['parent']['parent']['getAttribute']('vid_start'),_0x2f9b6f=_0x4a25b9['get'](_0x505330)||new Set();_0x2f9b6f['add'](_0x201bf4['get'](_0x55e691)['userId']),_0x4a25b9['set'](_0x505330,_0x2f9b6f);}}for(const _0x4de05c of _0x4a25b9['keys']())(_0xaee2db['has'](_0x4de05c)||_0x201bf4['has'](_0x4de05c))&&_0x4a25b9['delete'](_0x4de05c);}for(const _0x317716 of _0x3d21a9){const _0x279cf2=_0xbf299b['insertions'][_0x317716];let _0x22a79d=null,_0x1035fa=null;for(const _0x2896f0 of _0x279cf2){const _0x3eadf6=this['_getVidAttributeName'](_0x2896f0),_0x3dd2aa=_0x2896f0['item']['getAttribute'](_0x3eadf6),_0x4d7e10=_0x4a25b9['get'](_0x3dd2aa);_0x4d7e10&&'elementStart'==_0x2896f0['type']&&(_0x22a79d=Array['from'](_0x4d7e10)[0x0],_0x1035fa=_0x2896f0['item']['getAttribute']('vid_end')),_0x22a79d&&(_0x201bf4['set'](_0x3dd2aa,{'userId':_0x22a79d}),_0xaee2db['set'](_0x3dd2aa,{'userId':_0x22a79d})),_0x3dd2aa==_0x1035fa&&(_0x22a79d=null,_0x1035fa=null);}}const _0x4df6d9={},_0x134e56=new Set();for(const _0x19d3a8 of _0x3d21a9){const _0x31b320=_0x1660c1['deletions'][_0x19d3a8],_0x2a633a=_0x1660c1['insertions'][_0x19d3a8];for(const {userId:_0xe40d7c}of this['_touchedMarkers']['values']())null!==_0xe40d7c&&_0x134e56['add'](_0xe40d7c);for(const {userId:_0x49c8cd}of this['_touchedRoots']['values']())null!==_0x49c8cd&&_0x134e56['add'](_0x49c8cd);this['_markChanges'](_0x2a633a,_0xbf299b['insertions'][_0x19d3a8],_0xaee2db,'insertion',_0x134e56),this['_markChanges'](_0x31b320,_0xbf299b['deletions'][_0x19d3a8],_0x201bf4,'deletion',_0x134e56),_0x4df6d9[_0x19d3a8]={'insertions':this['_prepareViewToSave'](_0x2a633a),'deletions':this['_prepareViewToSave'](_0x31b320),'attachChange':this['_touchedRoots']['get'](_0x19d3a8)||null,'attributesBefore':_0x5af04f(this['_baseRootsAttributes']['get'](_0x19d3a8))||{},'attributesAfter':_0x5af04f(this['_diffRootsAttributes']['get'](_0x19d3a8))};}return{'diffData':_0x4df6d9,'authorsIds':Array['from'](_0x134e56)};}['_processRootBeforeSave'](_0x56c3e8){for(const [,_0x5249a3]of _0x56c3e8['markers']){const _0x252204=_0x5249a3['start']['getAncestors']()['filter'](_0x49cc39=>'tableCell'==_0x49cc39['name']);for(const _0x499cfd of _0x252204)0x1==_0x499cfd['childCount']&&_0x499cfd['getChild'](0x0)['is']('element','paragraph')&&_0x499cfd['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x235c11){this['_processRootBeforeSave'](_0x235c11);const _0x566899=this['editor']['data']['toView'](_0x235c11,{}),_0x5c4f26=Array['from'](_0x566899['getChildren']())['map'](_0xa672fa=>this['_getViewJson'](_0xa672fa));return JSON['stringify'](_0x5c4f26);}['_getViewJson'](_0x329683){if(_0x329683['is']('$text'))return _0x329683['data'];{const _0x2019f5=_0x329683;return{'type':Object['keys'](P)['find'](_0x353d0d=>_0x329683 instanceof P[_0x353d0d]),'name':_0x2019f5['name'],'attributes':Array['from'](_0x2019f5['getAttributes']()),'children':Array['from'](_0x2019f5['getChildren']())['map'](_0xbe071f=>this['_getViewJson'](_0xbe071f))};}}['_markChanges'](_0x4a9732,_0x2e2f45,_0x33562e,_0x3d791f,_0x3ae8ba){let _0x277e7f=null,_0x3c197b=null,_0x1b6f66=0x0;const _0xac505e=this['editor']['model'];for(let _0x30f840=0x0;_0x30f840<_0x2e2f45['length'];_0x30f840++){const _0x3c9e3e=this['_getVidAttributeName'](_0x2e2f45[_0x30f840]),_0x291efe=_0x2e2f45[_0x30f840]['item']['getAttribute'](_0x3c9e3e),_0x31f41f=_0x33562e['get'](_0x291efe),_0x13d80a=_0x30f840==_0x2e2f45['length']-0x1;(!_0x277e7f&&_0x31f41f&&(_0x277e7f=_0x31f41f,_0x3c197b=_0x2e2f45[_0x30f840]),_0x277e7f&&(!_0x31f41f||_0x31f41f['userId']!=_0x277e7f['userId']))&&(_0x4f5966(_0x31f41f,B(_0x3c197b,_0x4a9732,_0xac505e),B(_0x2e2f45[_0x30f840],_0x4a9732,_0xac505e)),_0x277e7f=_0x31f41f||null,_0x3c197b=_0x31f41f?_0x2e2f45[_0x30f840]:null),_0x277e7f&&_0x13d80a&&_0x4f5966(_0x31f41f,B(_0x3c197b,_0x4a9732,_0xac505e),J(_0x2e2f45[_0x30f840],_0x4a9732,_0xac505e));}function _0x4f5966(_0x29a821,_0xe96a5,_0x5acb1c){const _0x546dc1=_0x277e7f['userId'],_0x49b44b='revision:'+_0x3d791f+':'+_0x546dc1+':'+_0x1b6f66++,_0x1b0f82=_0xac505e['createRange'](_0xe96a5,_0x5acb1c);_0x4a9732['markers']['set'](_0x49b44b,_0x1b0f82),null!==_0x546dc1&&_0x3ae8ba['add'](_0x546dc1);}}['_getVidAttributeName'](_0x18132b){switch(_0x18132b['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x22c44f,_0x552340){_0x22c44f['baseVersion']=null;for(const _0x4f62f8 in _0x22c44f){const _0x279841=_0x22c44f[_0x4f62f8];if(_0x279841 instanceof gt){const _0x392586=_0x552340['get'](_0x279841['root']['rootName']);_0x22c44f[_0x4f62f8]=this['_fixPosition'](_0x279841,_0x392586);}if(_0x279841 instanceof vt){const _0x2717fa=_0x552340['get'](_0x279841['root']['rootName']);_0x22c44f[_0x4f62f8]=this['_fixRange'](_0x279841,_0x2717fa);}'root'===_0x4f62f8&&(_0x22c44f['root']=_0x552340['get'](_0x22c44f['root']['rootName']));}}['_fixRange'](_0x562521,_0x2479f2){return this['editor']['model']['createRange'](this['_fixPosition'](_0x562521['start'],_0x2479f2),this['_fixPosition'](_0x562521['end'],_0x2479f2));}['_fixPosition'](_0x13d829,_0x17502c){return this['editor']['model']['createPositionFromPath'](_0x17502c,_0x13d829['path'],_0x13d829['stickiness']);}['_handleInsertOperation'](_0x1b5c52){const _0x4dadbd=this['_idsRoots']['get'](_0x1b5c52['position']['root']['rootName']),_0x1fbf47=this['_fixPosition'](_0x1b5c52['position'],_0x4dadbd),_0x246f1d=null===_0x1b5c52['_authorId']?null:_0x1b5c52['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x87e35c=_0x1fbf47['parent'],_0x411d75=this['_revisionId'],_0x1cf5af=[];for(const _0x54bb11 of _0x1b5c52['nodes'])if(_0x54bb11['is']('element'))_0x1cf5af['push'](this['_makeIdsRoot'](_0x54bb11));else{for(let _0x10983f=0x0;_0x10983f<_0x54bb11['offsetSize'];_0x10983f++)_0x1cf5af['push'](new ft('$text',{'vid':this['_revisionId']++}));}const _0x4fc461=this['_revisionId'];for(let _0x35285e=_0x411d75;_0x35285e<_0x4fc461;_0x35285e++)this['_touched']['set'](_0x35285e,{'userId':_0x246f1d});_0x87e35c['_insertChild'](_0x1fbf47['offset'],_0x1cf5af);}['_handleMoveOperation'](_0x2c7a00){(_0x2c7a00=this['_cloneOperation'](_0x2c7a00,this['_idsRoots']))['_execute']();const _0x5711f6=null===_0x2c7a00['_authorId']?null:_0x2c7a00['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x3c9a38=_0x2c7a00['getMovedRangeStart'](),_0x675c3c=_0x3c9a38['parent'],_0xd13d4a=_0x3c9a38['offset'];!function _0x97fb5a(_0x150226,_0x272ac4,_0x4528e5,_0x1c542b){for(let _0x35a434=_0x4528e5;_0x35a434<_0x1c542b;_0x35a434++){const _0x3e71c0=_0x272ac4['getChild'](_0x35a434);_0x3e71c0['is']('element','$text')?_0x150226['set'](_0x3e71c0['getAttribute']('vid'),{'userId':_0x5711f6}):(_0x150226['set'](_0x3e71c0['getAttribute']('vid_start'),{'userId':_0x5711f6}),_0x97fb5a(_0x150226,_0x3e71c0,0x0,_0x3e71c0['childCount']),_0x150226['set'](_0x3e71c0['getAttribute']('vid_end'),{'userId':_0x5711f6}));}}(this['_touched'],_0x675c3c,_0xd13d4a,_0xd13d4a+_0x2c7a00['howMany']);}['_handleMergeOperation'](_0x4e8bce){const _0x354389=null===(_0x4e8bce=this['_cloneOperation'](_0x4e8bce,this['_idsRoots']))['_authorId']?null:_0x4e8bce['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x443dc3=_0x4e8bce['targetPosition']['parent'],_0x53884=_0x4e8bce['sourcePosition']['parent'],_0x42428b=_0x443dc3['getAttribute']('vid_end'),_0x56b288=_0x53884['getAttribute']('vid_start');_0x443dc3['_setAttribute']('vid_end',_0x53884['getAttribute']('vid_end')),_0x53884['_setAttribute']('vid_end',_0x42428b),this['_touched']['set'](_0x56b288,{'userId':_0x354389}),this['_touched']['set'](_0x42428b,{'userId':_0x354389}),_0x4e8bce['_execute']();}['_handleSplitOperation'](_0x2dff0d){const _0x515bf4=null===(_0x2dff0d=this['_cloneOperation'](_0x2dff0d,this['_idsRoots']))['_authorId']?null:_0x2dff0d['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x1cfc68=_0x2dff0d['graveyardPosition'],_0x17eb39=_0x2dff0d['splitPosition']['parent'];_0x2dff0d['_execute']();const _0x384fe6=_0x17eb39['getAttribute']('vid_end'),_0x3f67f8=_0x2dff0d['insertionPosition']['nodeAfter'];if(_0x1cfc68){const _0x3ff97e=_0x3f67f8['getAttribute']('vid_end'),_0x46e4fa=_0x17eb39['getAttribute']('vid_end');_0x17eb39['_setAttribute']('vid_end',_0x3ff97e),_0x3f67f8['_setAttribute']('vid_end',_0x46e4fa),this['_touched']['set'](_0x17eb39['getAttribute']('vid_end'),{'userId':_0x515bf4}),this['_touched']['set'](_0x3f67f8['getAttribute']('vid_start'),{'userId':_0x515bf4});}else{const _0x214780=this['_revisionId']++,_0x3d474a=this['_revisionId']++;_0x17eb39['_setAttribute']('vid_end',_0x214780),_0x3f67f8['_setAttribute']('vid_start',_0x3d474a),_0x3f67f8['_setAttribute']('vid_end',_0x384fe6),this['_touched']['set'](_0x214780,{'userId':_0x515bf4}),this['_touched']['set'](_0x3d474a,{'userId':_0x515bf4});}}['_handleMarkerOperation'](_0x39ec33){if(!_0x39ec33['affectsData'])return;const _0x88ee6d=(_0x39ec33=this['_cloneOperation'](_0x39ec33,this['_diffRoots']))['oldRange']?_0x39ec33['oldRange']['root']:null,_0x5692b5=_0x39ec33['newRange']?_0x39ec33['newRange']['root']:null;_0x88ee6d&&this['_markers']['delete'](_0x39ec33['name']),_0x5692b5&&this['_markers']['set'](_0x39ec33['name'],_0x39ec33['newRange']['clone']());const _0x2c94e1=null===_0x39ec33['_authorId']?null:_0x39ec33['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x158ccc=_0x39ec33['name'];if(!this['_touchedMarkers']['has'](_0x158ccc))return void this['_touchedMarkers']['set'](_0x158ccc,{'range':_0x39ec33['oldRange'],'userId':_0x2c94e1});const _0x56d9d3=this['_touchedMarkers']['get'](_0x158ccc),_0x27fa75=_0x56d9d3['range'],_0x196f25=_0x39ec33['newRange'];null==_0x27fa75&&null==_0x196f25||_0x27fa75&&_0x196f25&&_0x27fa75['isEqual'](_0x196f25)?this['_touchedMarkers']['delete'](_0x39ec33['name']):_0x56d9d3['userId']=_0x2c94e1;}['_handleRootOperation'](_0x296587,_0x28f1c8){this['_diffRoots']['has'](_0x296587['rootName'])?this['_diffRoots']['get'](_0x296587['rootName'])['_isAttached']=_0x296587['isAdd']:(this['_diffRoots']['set'](_0x296587['rootName'],F(_0x296587['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x296587['rootName'],{}),_0x28f1c8&&this['_idsRoots']['set'](_0x296587['rootName'],F(_0x296587['rootName'],!0x0)));const _0x291b77=null===_0x296587['_authorId']?null:_0x296587['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x1980f4=this['_touchedRoots']['get'](_0x296587['rootName']);_0x1980f4&&_0x1980f4['userId']===_0x291b77?this['_touchedRoots']['delete'](_0x296587['rootName']):this['_touchedRoots']['set'](_0x296587['rootName'],{'userId':_0x291b77,'isAttached':_0x296587['isAdd']});}['_handleRootAttributeOperation'](_0x24e0ed){const _0x3a8197=this['_diffRootsAttributes']['get'](_0x24e0ed['root']['rootName']);null===_0x24e0ed['newValue']?delete _0x3a8197[_0x24e0ed['key']]:_0x3a8197[_0x24e0ed['key']]=_0x24e0ed['newValue'];}}function T(_0x3d3b21){const _0x101efe=F(_0x3d3b21['rootName'],_0x3d3b21['isAttached']());for(const _0x383de8 of _0x3d3b21['getChildren']()){const _0xde9dd2=_0x383de8['_clone'](!0x0);_0x101efe['_appendChild'](_0xde9dd2);}return _0x101efe;}function F(_0x4ce394,_0x2b60c7=!0x0){const _0x529e84=new mt();return _0x529e84['rootName']=_0x4ce394,_0x529e84['_isAttached']=_0x2b60c7,_0x529e84['isAttached']=()=>_0x529e84['_isAttached'],_0x529e84;}function B(_0x4b92a3,_0xf6d85a,_0x221754){const _0x2aeab3='elementEnd'==_0x4b92a3['type']?_0x221754['createPositionAt'](_0x4b92a3['item'],'end'):_0x221754['createPositionBefore'](_0x4b92a3['item']);return _0x221754['createPositionFromPath'](_0xf6d85a,_0x2aeab3['path'],_0x2aeab3['stickiness']);}function J(_0x19ed66,_0x228f38,_0x4c120f){const _0x20cf08='elementStart'==_0x19ed66['type']?_0x4c120f['createPositionAt'](_0x19ed66['item'],0x0):_0x4c120f['createPositionAfter'](_0x19ed66['item']);return _0x4c120f['createPositionFromPath'](_0x228f38,_0x20cf08['path'],_0x20cf08['stickiness']);}class ns extends _0x376464{['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x28186c,_0x2d66ee){super(_0x28186c),this['focusTracker']=new _0x7d4c72(),this['keystrokes']=new _0x4053e6(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x2d66ee),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'](),_0xbcf98b({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x209d4b=_0x390010=>_0x390010['stopPropagation']();this['keystrokes']['set']('arrowright',_0x209d4b),this['keystrokes']['set']('arrowleft',_0x209d4b),this['keystrokes']['set']('arrowup',_0x209d4b),this['keystrokes']['set']('arrowdown',_0x209d4b);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x760562){this['revisionNameInputView']['fieldView']['element']['value']=_0x760562['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x35cc1c){const _0x2cab63=new nt(this['locale'],_0xcbfa91),_0xcebaae=_0x2cab63['fieldView'];_0xcebaae['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x4c0254=m(this['locale'],'Name\x20of\x20the\x20revision');return!_0x35cc1c&&(_0x4c0254+='\x20('+m(this['locale'],'optional')+')'),(_0x2cab63['label']=_0x4c0254,_0xcebaae['on']('input',()=>{this['revisionNameInputValue']=_0xcebaae['element']['value']['trim']();}),_0x2cab63);}}class u extends _0x361651{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l];}['_saveRevisionFormView'];['init'](){const _0x10a3e6=this['editor'],_0x10d710=_0x10a3e6['plugins']['get']('RevisionTracker');_0x10a3e6['ui']['componentFactory']['add']('revisionHistory',_0x5f1914=>{const _0x260bad=_0x11399b(_0x5f1914),_0xb219cf=_0x260bad['panelView']['children'],_0x177930=new te(_0x5f1914),_0x2fa2e0=new _0x3ce312(_0x5f1914),_0x24c359=new _0x58a9b0(_0x5f1914),_0x5b3e72=new _0x3ce312(_0x5f1914),_0x281593=new _0x58a9b0(_0x5f1914);return _0x260bad['bind']('isEnabled')['to'](_0x10d710,'isReady',_0x10d710,'isEnabled',_0x10a3e6,'isReadOnly',(_0x499364,_0x2f1fa1,_0x3a7229)=>_0x499364&&_0x2f1fa1&&!_0x3a7229),_0x260bad['buttonView']['set']({'icon':_0x2a914a['history'],'label':m(_0x5f1914,'Revision\x20history'),'tooltip':!0x0}),_0x24c359['set']({'label':m(_0x5f1914,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x24c359['bind']('isEnabled')['to'](_0x10d710,'isReady',_0x10d710,'isEnabled',_0x10a3e6,'isReadOnly',(_0x3f8cab,_0x25e609,_0x2ebaa3)=>_0x3f8cab&&_0x25e609&&!_0x2ebaa3),_0x24c359['on']('execute',()=>this['_showDialog']()),_0x281593['set']({'label':m(_0x5f1914,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x281593['bind']('isEnabled')['to'](_0x10d710,'isReady',_0x10a3e6,'isReadOnly',(_0x11f6ef,_0x13c15c)=>_0x11f6ef&&!_0x13c15c),_0x281593['on']('execute',()=>{_0x10a3e6['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x260bad['isOpen']=!0x1,_0x10a3e6['editing']['view']['focus']();}),_0x2fa2e0['children']['add'](_0x24c359),_0x5b3e72['children']['add'](_0x281593),_0x177930['role']='menu',_0x177930['items']['addMany']([_0x2fa2e0,_0x5b3e72]),_0xb219cf['add'](_0x177930),_0x260bad;}),_0x10a3e6['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x4ac786=this['editor'],_0x49c651=_0x4ac786['locale'],_0x2aeff6=new _0x1643c5(_0x49c651),_0x4b5e77=new _0x2732e5(_0x49c651);_0x2aeff6['buttonView']['set']({'icon':_0x2a914a['history'],'label':m(_0x49c651,'Revision\x20history')});const _0x25f7ce=new _0x21400a(_0x49c651,_0x2aeff6),_0x4b8511=new _0x178c59(_0x49c651);_0x4b8511['set']({'label':m(_0x49c651,'Save\x20current\x20revision')}),_0x4b8511['delegate']('execute')['to'](_0x2aeff6),_0x4b8511['on']('execute',()=>{this['_showDialog']();}),_0x25f7ce['children']['add'](_0x4b8511),_0x4b5e77['items']['add'](_0x25f7ce);const _0x2afca5=new _0x21400a(_0x49c651,_0x2aeff6),_0xaa21c9=new _0x178c59(_0x49c651);return _0xaa21c9['set']({'label':m(_0x49c651,'Open\x20revision\x20history')}),_0xaa21c9['delegate']('execute')['to'](_0x2aeff6),_0xaa21c9['on']('execute',()=>{_0x4ac786['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x2afca5['children']['add'](_0xaa21c9),_0x4b5e77['items']['add'](_0x2afca5),_0x2aeff6['panelView']['children']['add'](_0x4b5e77),_0x2aeff6;}['_showDialog'](){const _0x16e1d3=this['editor'],_0x1940c6=_0x16e1d3['locale'],_0x435183=_0x16e1d3['plugins']['get']('Dialog'),_0x1dcdd5=_0x16e1d3['plugins']['get']('RevisionTracker');function _0x26381b(_0x5e62c4){_0x16e1d3['config']['get']('revisionHistory.requireRevisionName')&&''===_0x5e62c4['revisionName']?_0x5e62c4['revisionNameInputView']['errorText']=m(_0x1940c6,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x16e1d3['plugins']['get'](l)['saveRevision']({'name':_0x5e62c4['revisionName']}),_0x435183['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x26381b(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x435183['show']({'id':'revisionSave','title':m(_0x1940c6,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':m(_0x16e1d3['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x435183['hide']()},{'label':m(_0x16e1d3['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x2ae965){_0x2ae965['bind']('isEnabled')['to'](_0x1dcdd5,'isReady',_0x1dcdd5,'isEnabled',_0x16e1d3,'isReadOnly',(_0x42f6f2,_0x2d91b7,_0xd58870)=>_0x42f6f2&&_0x2d91b7&&!_0xd58870);},'onExecute':()=>_0x26381b(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x34cd8e=this['editor'],_0x2552fe=_0x34cd8e['locale'];this['_saveRevisionFormView']=new ns(_0x2552fe,_0x34cd8e['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class X extends _0x376464{['changeId'];['_model'];constructor(_0x4baf29,_0x1cbe62){super(_0x4baf29),this['_model']=_0x1cbe62,this['changeId']=_0x1cbe62['id'];const _0x2056bb=this['bindTemplate'],_0x191cad=m(_0x4baf29,_0x1cbe62['data']['isSuggestion']?'Suggested\x20by':'add'==_0x1cbe62['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x1cbe62['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x2056bb['to']('type',_0x48ad6f=>'ck-revision-change__'+_0x48ad6f)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x191cad}]},{'text':'\x20'+_0x1cbe62['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class r extends/* #__PURE__ -- @preserve */
|
|
25
|
+
_0x2332e5(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x4efd5d){super(),this['id']=_0x4efd5d['id']||_0x52d906(),this['author']=_0x4efd5d['author'],this['type']=_0x4efd5d['type'],this['data']=_0x4efd5d['data']||{},this['rootName']=_0x4efd5d['rootName'],this['set']('createdAt',_0x4efd5d['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(_0x179d73,_0x56080e){this['newRevisionId']=_0x179d73,this['oldRevisionId']=_0x56080e,this['changes']=new _0x2ebcff();}['_setChanges'](_0x5f586d){for(const _0x385429 of _0x5f586d)this['changes']['add'](_0x385429);}}const Y={'c':_0x11367b,'a':_0xa485d0,'e':_0x335ef8,'r':_0x8ec83,'u':_0x4421f6};class d extends _0x361651{['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[_0x176997,_0x47b965,j];}constructor(_0x5684d7){super(_0x5684d7),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',(_0x4b1b5e,_0x53b07a,_0x2ce33a)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x1f885b=>{for(const _0x3b144e of this['editor']['editing']['view']['document']['roots'])_0x2ce33a?_0x1f885b['removeClass']('ck-editor__editable__overlay',_0x3b144e):_0x1f885b['addClass']('ck-editor__editable__overlay',_0x3b144e);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x4d88dc=>null!==_0x4d88dc),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x5d3e79,_0x40be49,_0xf64fb6)=>_0x5d3e79&&_0xf64fb6?_0x40be49['changes']['getIndex'](_0xf64fb6):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x2b0792,_0x135f91)=>_0x2b0792?_0x135f91['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['adapter']=null,this['_balloon']=this['editor']['plugins']['get'](_0x47b965);}['init'](){const _0x374e96=this['editor'],_0x26abb0=new yt(_0x374e96,{'direction':'backward'}),_0x30990b=new yt(_0x374e96,{'direction':'forward'});(_0x374e96['commands']['add']('showPreviousChange',_0x26abb0),_0x374e96['commands']['add']('showNextChange',_0x30990b),_0x374e96['commands']['add']('restoreRevision',new _t(_0x374e96)),this['on']('change:numberOfChanges',()=>{_0x26abb0['refresh'](),_0x30990b['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x374e96['enableReadOnlyMode']('revision-viewer'),_0x374e96['plugins']['has']('WidgetToolbarRepository'))&&_0x374e96['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionData'](_0x183974){await this['loadRevisionData'](_0x183974);const _0x59a75b={};for(const _0xfe6ccc in _0x183974['diffData']){if(_0x183974['diffData'][_0xfe6ccc]['attachChange']&&!_0x183974['diffData'][_0xfe6ccc]['attachChange']['isAttached'])continue;const _0x5a7147=this['_removeRevisionMarkers'](JSON['parse'](_0x183974['diffData'][_0xfe6ccc]['insertions'])),_0x34ea99=this['editor']['editing']['view']['document'],_0x5ce991=new _0x379ec6(_0x34ea99,_0x5a7147['map'](_0x250ba4=>this['_getViewObj'](_0x250ba4)));this['editor']['data']['processor']['useFillerType']('marked'),_0x59a75b[_0xfe6ccc]=this['editor']['data']['processor']['toData'](_0x5ce991),this['editor']['data']['processor']['useFillerType']('default');}return _0x59a75b;}async['getRevisionRootsAttributes'](_0x9e5a72){await this['loadRevisionData'](_0x9e5a72);const _0x29cd01={};for(const _0xa1fd2c in _0x9e5a72['diffData'])_0x9e5a72['diffData'][_0xa1fd2c]['attachChange']&&!_0x9e5a72['diffData'][_0xa1fd2c]['attachChange']['isAttached']||(_0x29cd01[_0xa1fd2c]=_0x9e5a72['diffData'][_0xa1fd2c]['attributesAfter']||{});return _0x29cd01;}['_removeRevisionMarkers'](_0xe10bc9){return(_0xe10bc9=_0xe10bc9['filter'](_0xf85106=>!_0xf85106['name']||'revision-start'!==_0xf85106['name']&&'revision-end'!==_0xf85106['name']))['forEach'](_0x3c677d=>{'string'!=typeof _0x3c677d&&(_0x3c677d['children']=this['_removeRevisionMarkers'](_0x3c677d['children']),_0x3c677d['attributes']=_0x3c677d['attributes']['filter'](_0x233f26=>!_0x233f26[0x0]['startsWith']('data-revision-')));}),_0xe10bc9;}async['compare'](_0x52a6b2,_0x9ee164,_0x936cbe=!0x1){if(!this['isEnabled'])return;const _0xea6ec2=this['diff'],_0x5f56db=this['repository'],_0x47e576='string'==typeof _0x52a6b2?_0x5f56db['getRevision'](_0x52a6b2):_0x52a6b2,_0xdebc36='string'==typeof _0x9ee164?_0x5f56db['getRevision'](_0x9ee164):_0x9ee164,_0x400c95=_0x47e576['id'],_0x32f32c=_0xdebc36?_0xdebc36['id']:null;if(!_0x936cbe&&this['diff']&&this['diff']['newRevisionId']===_0x400c95&&this['diff']['oldRevisionId']===_0x32f32c)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new f(_0x400c95,_0x32f32c);const _0x53b679=this['_getRevisionsRange'](_0x47e576,_0xdebc36,!0x0)['map'](_0x2240df=>this['loadRevisionData'](_0x2240df));return _0x53b679['push'](new Promise(_0x30bdfc=>{setTimeout(_0x30bdfc,0x14);})),Promise['all'](_0x53b679)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x54a655=this['_getDiff'](_0x400c95,_0x32f32c);for(const _0x3c3e7a of _0x54a655['changes'])this['_changeIdToChange']['set'](_0x3c3e7a['id'],_0x3c3e7a);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x50dd25=>{for(const _0x3740b5 of this['editor']['model']['document']['getRootNames']())_0x50dd25['detachRoot'](_0x3740b5);for(const _0x522283 of Object['keys'](_0x54a655['model'])){const _0x35645b=_0x50dd25['addRoot'](_0x522283);for(const _0x522aa of Object['keys'](_0x54a655['attributes'][_0x522283]))_0x50dd25['setAttribute'](_0x522aa,_0x54a655['attributes'][_0x522283][_0x522aa],_0x35645b);_0x50dd25['insert'](_0x54a655['model'][_0x522283],_0x35645b,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x54a655['changes'])),this['isReady']=!0x0;})['catch'](_0x12776a=>{console['error'](_0x12776a),this['_cleanUp'](),_0xea6ec2&&(this['diff']=_0xea6ec2),this['isReady']=!0x0;});}['addRevisionData'](_0xf28b8a,_0x2d53c3){const _0x39673d=this['repository']['createRevision'](_0xf28b8a);return _0x39673d['on']('_update',(_0x4d7343,_0x2e4d18,_0x432a6c)=>_0x2d53c3(_0x2e4d18,_0x432a6c,_0x39673d)),this['repository']['addRevision'](_0x39673d),_0x39673d;}['loadRevisionData'](_0x3db5b7){if(!_0x3db5b7||_0x3db5b7['diffData'])return Promise['resolve']();{const _0x2f5c0f=this['editor']['config']['get']('collaboration.channelId');return this['adapter']['getRevision']({'channelId':_0x2f5c0f,'revisionId':_0x3db5b7['id']})['then'](_0x41044d=>{_0x3db5b7['_update']({'diffData':_0x41044d['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},_0x5c1a5c=>{for(const _0x2fe3f9 of this['editor']['model']['document']['getRootNames']())_0x5c1a5c['detachRoot'](_0x2fe3f9);});}['_sortAndFilterDiffChanges'](_0x251831){const _0x31797e=[],_0x1396d0=new Map();for(const _0x3c07ed of this['editor']['model']['document']['getRootNames']()){const _0xf73539=this['editor']['editing']['view']['getDomRoot'](_0x3c07ed);if(!_0xf73539)continue;const _0x32caaf=_0xf73539['getClientRects']()['item'](0x0);_0x32caaf&&(_0x31797e['push'](_0x3c07ed),_0x1396d0['set'](_0x3c07ed,_0x32caaf));}return _0x31797e['sort']((_0x519ae9,_0x47f90a)=>{const _0x434cab=_0x1396d0['get'](_0x519ae9),_0x541a78=_0x1396d0['get'](_0x47f90a);return _0x434cab['y']-_0x541a78['y']||_0x434cab['x']-_0x541a78['x'];}),(_0x251831=_0x251831['filter'](_0xe2169=>_0x31797e['includes'](_0xe2169['rootName'])))['sort']((_0x48a2c4,_0x10b49f)=>_0x31797e['indexOf'](_0x48a2c4['rootName'])-_0x31797e['indexOf'](_0x10b49f['rootName'])),_0x251831;}['_makeTape'](_0x12f040){const _0x2932aa=Array['from'](_0x12f040['markers'])['filter'](([_0x3cbcbb,_0x32d3d3])=>_0x3cbcbb['startsWith']('revision:')&&!_0x32d3d3['isCollapsed']),_0x20e6b0=Array['from'](this['editor']['model']['createRangeIn'](_0x12f040)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x2932aa['length'])for(const _0x1d6269 of _0x20e6b0){const [_0x1dcdcf,_0x58e269]=_0x2932aa[0x0],[,_0x4e921c,_0x567829]=_0x1dcdcf['split'](':');if(_0x58e269['end']['isEqual'](_0x1d6269['nextPosition'])&&_0x2932aa['shift'](),(_0x1d6269['previousPosition']['isEqual'](_0x58e269['start'])||_0x1d6269['previousPosition']['isAfter'](_0x58e269['start']))&&('insertion'==_0x4e921c?_0x1d6269['isAdded']={'userId':_0x567829}:'deletion'==_0x4e921c&&(_0x1d6269['isRemoved']={'userId':_0x567829})),0x0==_0x2932aa['length'])break;}return _0x20e6b0;}['_refreshStartEndIndex'](_0x4075a8){const _0x581a12=new Map();for(let _0x37a94f=0x0;_0x37a94f<_0x4075a8['length'];_0x37a94f++)'text'===_0x4075a8[_0x37a94f]['type']?(_0x4075a8[_0x37a94f]['item']['startIndex']=_0x37a94f,_0x4075a8[_0x37a94f]['item']['endIndex']=_0x37a94f):('elementStart'===_0x4075a8[_0x37a94f]['type']?_0x4075a8[_0x37a94f]['item']['startIndex']=_0x37a94f:'elementEnd'===_0x4075a8[_0x37a94f]['type']&&(_0x4075a8[_0x37a94f]['item']['endIndex']=_0x37a94f),_0x581a12['set'](_0x4075a8[_0x37a94f]['id'],_0x37a94f));for(const _0x14e2e0 of _0x581a12['values']())'elementStart'===_0x4075a8[_0x14e2e0]['type']?_0x4075a8[_0x14e2e0]['item']['endIndex']=_0x581a12['get'](_0x4075a8[_0x14e2e0]['pairId']):'elementEnd'===_0x4075a8[_0x14e2e0]['type']&&(_0x4075a8[_0x14e2e0]['item']['startIndex']=_0x581a12['get'](_0x4075a8[_0x14e2e0]['pairId']));}['_processTape'](_0x5f497a){for(let _0x443f75=0x0;_0x443f75<_0x5f497a['length'];_0x443f75++){if('elementStart'===_0x5f497a[_0x443f75]['type'])_0x5f497a[_0x443f75]['item']['startIndex']=_0x443f75;else{if('elementEnd'===_0x5f497a[_0x443f75]['type']){_0x5f497a[_0x443f75]['item']['endIndex']=_0x443f75;const _0x36363c=_0x5f497a[_0x443f75]['item']['startIndex'];_0x5f497a[_0x36363c]['pairId']=_0x5f497a[_0x443f75]['id'],_0x5f497a[_0x443f75]['pairId']=_0x5f497a[_0x36363c]['id'];}else _0x5f497a[_0x443f75]['item']['startIndex']=_0x443f75,_0x5f497a[_0x443f75]['item']['endIndex']=_0x443f75,_0x5f497a[_0x443f75]['pairId']=null;}_0x5f497a[_0x443f75]['markersStart']||(_0x5f497a[_0x443f75]['markersStart']=[],_0x5f497a[_0x443f75]['markersEnd']=[]);}}['_markInsertions'](_0x36f014,_0x3c3d4a){const _0x28dee9=_0x36f014['filter'](_0x21e4ac=>!_0x21e4ac['isAdded']);for(let _0x579945=0x0;_0x579945<_0x3c3d4a['length'];_0x579945++)_0x3c3d4a[_0x579945]['isAdded']&&(_0x28dee9[_0x579945]['isAdded']=_0x3c3d4a[_0x579945]['isAdded']);}['_makeModelFromViewString'](_0x2b399e){const _0x200f5a=JSON['parse'](_0x2b399e),_0x58bb3b=this['editor']['editing']['view']['document'],_0x49aa68=new _0x379ec6(_0x58bb3b,_0x200f5a['map'](_0x3ba4af=>this['_getViewObj'](_0x3ba4af)));return this['editor']['data']['toModel'](_0x49aa68);}['_getViewObj'](_0x56aad6){const _0x307f00=this['editor']['editing']['view']['document'];if('string'==typeof _0x56aad6)return new _0x4317d4(_0x307f00,_0x56aad6);{const _0x440539=_0x56aad6['children']['map'](_0x13dd75=>this['_getViewObj'](_0x13dd75));return new(Y[_0x56aad6['type']]||_0x3c4ed4)(_0x307f00,_0x56aad6['name'],_0x56aad6['attributes'],_0x440539);}}['_getDiff'](_0x23836f,_0x12f996=null){const _0x1fb459=this['repository']['getRevision'](_0x23836f),_0x570894=_0x12f996?this['repository']['getRevision'](_0x12f996):null,_0x508002=this['_getRevisionsRange'](_0x1fb459,_0x570894),_0x5f5236=_0x508002[_0x508002['length']-0x1],_0x4e8a60=new Map(),_0x14abbb={'model':{},'attributes':{},'changes':[]},_0x410f00=new Set(),_0x290e57=new Map();for(let _0x56a4ed=_0x508002['length']-0x1;_0x56a4ed>=0x0;_0x56a4ed--){const _0x275a73=_0x508002[_0x56a4ed];for(const _0xf2b664 of Object['keys'](_0x275a73['diffData']))if(_0x275a73['diffData'][_0xf2b664]['attachChange']){const _0x55cb34=_0x275a73['diffData'][_0xf2b664]['attachChange'];_0x55cb34['isAttached']?(_0x410f00['add'](_0xf2b664),_0x290e57['has'](_0xf2b664)&&_0x290e57['get'](_0xf2b664)['userId']==_0x55cb34['userId']?_0x290e57['delete'](_0xf2b664):_0x290e57['set'](_0xf2b664,_0x55cb34)):_0x290e57['has'](_0xf2b664)?(_0x410f00['delete'](_0xf2b664),_0x290e57['delete'](_0xf2b664)):(_0x410f00['add'](_0xf2b664),_0x290e57['set'](_0xf2b664,_0x55cb34));}else _0x410f00['add'](_0xf2b664);}for(const _0x56880d of _0x410f00){const _0x35946e=_0x290e57['has'](_0x56880d)&&!_0x290e57['get'](_0x56880d)['isAttached'];let _0x46bcdb=_0x35946e?_0x508002['length']-0x1:0x0;const _0x365189=_0x35946e?-0x1:0x1;for(;_0x508002[_0x46bcdb];){const _0x356f0a=_0x508002[_0x46bcdb];if(_0x356f0a['diffData'][_0x56880d]){const _0x1a6ed1=_0x35946e?_0x356f0a['diffData'][_0x56880d]['attributesBefore']:_0x356f0a['diffData'][_0x56880d]['attributesAfter'];_0x14abbb['attributes'][_0x56880d]=_0x1a6ed1?_0x5af04f(_0x1a6ed1):{};break;}_0x46bcdb+=_0x365189;}}for(const _0xdd0766 of _0x508002){_0xdd0766['model']={};for(const _0x5c545b of _0xdd0766['authors'])_0x4e8a60['set'](_0x5c545b['id'],_0x5c545b);for(const _0x1ac9cb of _0x410f00){const _0x392239=_0xdd0766['diffData'][_0x1ac9cb]?_0xdd0766['diffData'][_0x1ac9cb]['insertions']:'[]',_0x493d8b=_0xdd0766['diffData'][_0x1ac9cb]?_0xdd0766['diffData'][_0x1ac9cb]['deletions']:'[]';_0xdd0766['model'][_0x1ac9cb]={'insertions':this['_makeModelFromViewString'](_0x392239),'deletions':this['_makeModelFromViewString'](_0x493d8b)};}}for(const _0x4459e2 of _0x410f00){let _0x3c2b68=null,_0xa37d9d=0x0;const _0x361225=new Map(Array['from'](_0x1fb459['model'][_0x4459e2]['insertions']['markers'])['filter'](([_0x17b7c1])=>!_0x17b7c1['startsWith']('revision:')));let _0x6aa6d0=0x0;for(const _0x18dc37 of _0x508002){const _0x32a672=this['_makeTape'](_0x18dc37['model'][_0x4459e2]['insertions']);_0x18dc37==_0x1fb459?(_0x3c2b68=_0x32a672,_0xa37d9d=_0x3c2b68['length'],_0x3c2b68['forEach'](_0x1b3790=>{_0x1b3790['id']=_0x6aa6d0++;}),this['_processTape'](_0x3c2b68)):this['_markInsertions'](_0x3c2b68,_0x32a672);const _0x230091=_0x3c2b68['filter'](_0x4b6dda=>!_0x4b6dda['isAdded'])['map'](_0x3e0bde=>_0x3e0bde['id']);let _0x1c32f7=0x0;const _0x2d437b=this['_makeTape'](_0x18dc37['model'][_0x4459e2]['deletions']);_0x2d437b['forEach'](_0x465962=>{_0x465962['isRemoved']?_0x465962['id']=_0xa37d9d++:_0x465962['id']=_0x230091[_0x1c32f7++];}),this['_processTape'](_0x2d437b),this['_setDistance'](_0x3c2b68,'isAdded'),this['_setDistance'](_0x2d437b,'isRemoved'),_0x18dc37==_0x1fb459&&this['_markMarkers'](_0x3c2b68,_0x361225),_0x3c2b68=this['_joinTapes'](_0x3c2b68,_0x2d437b),this['_refreshStartEndIndex'](_0x3c2b68),this['_setDistance'](_0x3c2b68,'isRemoved');}_0x3c2b68=_0x3c2b68['filter'](_0x2e2a77=>!(_0x2e2a77['isAdded']&&_0x2e2a77['isRemoved']));const _0x5dc54a=new Map(_0x5f5236['model'][_0x4459e2]['deletions']['markers']),_0x48bcb9=new Set(_0x361225['keys']());for(const _0x5bc9be of _0x5dc54a['keys']())_0x48bcb9['delete'](_0x5bc9be);this['_markSuggestions'](_0x3c2b68,_0x48bcb9),this['_fixObsoleteTags'](_0x3c2b68),_0x3c2b68=this['_removeMissingPairs'](_0x3c2b68),_0x3c2b68=this['_markMismatchedRemovedTags'](_0x3c2b68),_0x3c2b68=this['_removeUnsupportedChanges'](_0x3c2b68);const {root:_0xae10d,changes:_0xf5ad0c}=this['_makeModelFromTape'](_0x3c2b68,_0x4e8a60,_0x4459e2);_0x14abbb['model'][_0x4459e2]=_0xae10d;const _0x51b473=_0x290e57['get'](_0x4459e2);if(_0x51b473){const _0x281288=_0x4e8a60['get'](_0x51b473['userId']),_0x5e55cb=new r({'author':_0x281288,'type':_0x51b473['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x4459e2});_0xf5ad0c['unshift'](_0x5e55cb),_0x14abbb['attributes'][_0x4459e2]['revisionHistoryAttachChange']=_0x5e55cb['id'];}_0x14abbb['changes']=_0x14abbb['changes']['concat'](_0xf5ad0c);}return _0x14abbb;}['_markMarkers'](_0x3184b8,_0x5ccd6f){for(let _0x21a5a4=0x0;_0x21a5a4<_0x3184b8['length'];_0x21a5a4++)for(const [_0x354554,_0x2d76d1]of _0x5ccd6f)_0x2d76d1['start']['isEqual'](_0x3184b8[_0x21a5a4]['previousPosition'])&&_0x3184b8[_0x21a5a4]['markersStart']['push'](_0x354554),_0x2d76d1['end']['isEqual'](_0x3184b8[_0x21a5a4]['nextPosition'])&&_0x3184b8[_0x21a5a4]['markersEnd']['push'](_0x354554);}['_joinTapes'](_0x271af7,_0x3bd2cd){let _0x525874=[],_0x1b4d47=0x0,_0xeb7e6d=0x0;for(;_0x1b4d47<_0x271af7['length']||_0xeb7e6d<_0x3bd2cd['length'];){const _0x5809e3=_0x271af7[_0x1b4d47]||{},_0x2333c1=_0x3bd2cd[_0xeb7e6d]||{};if(_0x5809e3['id']==_0x2333c1['id'])_0x1b4d47++,_0xeb7e6d++,_0x525874['push'](_0x5809e3);else{if(_0x2333c1['isRemoved']&&_0x5809e3['isAdded']){const {commonTape:_0x199d82,iEnd:_0x1138f5,jEnd:_0x4be194}=this['_threeWayMerge'](_0x271af7,_0x1b4d47,_0x3bd2cd,_0xeb7e6d);_0x525874=_0x525874['concat'](_0x199d82),_0x1b4d47=_0x1138f5,_0xeb7e6d=_0x4be194;}else _0x2333c1['isRemoved']?(_0xeb7e6d++,_0x525874['push'](_0x2333c1)):(_0x1b4d47++,_0x525874['push'](_0x5809e3));}}return _0x525874;}['_markSuggestions'](_0x696d9b,_0x48e4f1){const _0x4ab28b=[];for(let _0x29a55c=0x0;_0x29a55c<_0x696d9b['length'];_0x29a55c++){for(let _0x2a8150=0x0;_0x2a8150<_0x696d9b[_0x29a55c]['markersStart']['length'];_0x2a8150++){const _0x563007=_0x696d9b[_0x29a55c]['markersStart'][_0x2a8150];if(!_0x48e4f1['has'](_0x563007))continue;const {group:_0x5edcc3,type:_0x529ff8,authorId:_0x5831d3}=_0x4c5eae(_0x563007);'revision-suggestion'!=_0x5edcc3||'insertion'!=_0x529ff8&&'deletion'!=_0x529ff8||(_0x4ab28b['unshift']({'type':_0x529ff8,'name':_0x563007,'userId':_0x5831d3}),_0x696d9b[_0x29a55c]['markersStart']['splice'](_0x2a8150,0x1),_0x2a8150--);}_0x3451f0(_0x696d9b[_0x29a55c]);for(let _0x11eca6=0x0;_0x11eca6<_0x696d9b[_0x29a55c]['markersEnd']['length'];_0x11eca6++){const _0x325ef6=_0x696d9b[_0x29a55c]['markersEnd'][_0x11eca6];if(!_0x48e4f1['has'](_0x325ef6))continue;const {group:_0x106871,type:_0x1fc518}=_0x4c5eae(_0x325ef6);if('revision-suggestion'!=_0x106871||'insertion'!=_0x1fc518&&'deletion'!=_0x1fc518)continue;_0x696d9b[_0x29a55c]['markersEnd']['splice'](_0x11eca6,0x1),_0x11eca6--;const _0x4d1538=_0x4ab28b['findIndex'](_0x536b15=>_0x536b15['name']==_0x325ef6);_0x4d1538>-0x1&&_0x4ab28b['splice'](_0x4d1538,0x1);}}function _0x4c5eae(_0x917716){const _0x44fb88=_0x917716['split'](':');return{'group':_0x44fb88[0x0],'type':_0x44fb88[0x1],'subType':_0x44fb88['length']>=0x5?_0x44fb88[0x2]:null,'id':_0x44fb88['length']<0x5?_0x44fb88[0x2]:_0x44fb88[0x3],'authorId':_0x44fb88['length']<0x5?_0x44fb88[0x3]:_0x44fb88[0x4],'markerCount':0x6==_0x44fb88['length']?_0x44fb88[0x5]:null};}function _0x3451f0(_0x311d76){for(let _0x44ca48=0x0;_0x44ca48<_0x4ab28b['length'];_0x44ca48++){if(_0x311d76['isAdded']&&'insertion'==_0x4ab28b[_0x44ca48]['type'])return _0x311d76['isAddSuggestion']=_0x4ab28b[_0x44ca48],void delete _0x311d76['isAdded'];if(!_0x311d76['isAdded']&&!_0x311d76['isRemoved']&&'deletion'==_0x4ab28b[_0x44ca48]['type'])return void(_0x311d76['isRemoveSuggestion']=_0x4ab28b[_0x44ca48]);}}}['_setDistance'](_0x250a26,_0x48d07e){let _0x402ff7=0x0,_0x3487c4=!0x1;const _0x42f880=new Map();for(const _0x2d188f of _0x250a26)_0x2d188f[_0x48d07e]?_0x3487c4&&(_0x402ff7++,_0x3487c4=!0x1):(_0x402ff7++,_0x3487c4=!0x0),_0x42f880['set'](_0x2d188f['id'],_0x402ff7);for(let _0x4e63b9=0x0;_0x4e63b9<_0x250a26['length'];_0x4e63b9++){if('isRemoved'==_0x48d07e&&_0x250a26[_0x4e63b9]['isAdded']||'isAdded'==_0x48d07e&&_0x250a26[_0x4e63b9]['isRemoved'])continue;if('text'==_0x250a26[_0x4e63b9]['type']){_0x250a26[_0x4e63b9]['distance']=0x0;continue;}const _0x23362d=_0x42f880['get'](_0x250a26[_0x4e63b9]['pairId']),_0x2c5ce0=_0x42f880['get'](_0x250a26[_0x4e63b9]['id']);_0x250a26[_0x4e63b9]['distance']=_0x23362d-_0x2c5ce0;}}['_getRevisionsRange'](_0x4d600f,_0x38c3a9,_0x4d6519=!0x1){const _0x287a45=[];let _0x4fd2fc=this['repository']['getIndex'](_0x4d600f),_0x2f6da9=this['repository']['getIndex'](_0x38c3a9);for(-0x1==_0x2f6da9&&(_0x2f6da9=this['repository']['_revisions']['length'],_0x4d6519=!0x1);_0x4fd2fc<_0x2f6da9;)_0x287a45['push'](this['repository']['getRevision'](_0x4fd2fc)),_0x4fd2fc++;return _0x4d6519&&_0x287a45['push'](this['repository']['getRevision'](_0x4fd2fc)),_0x287a45;}['_threeWayMerge'](_0x7ea196,_0x539920,_0xd2478f,_0x55daab){const _0x1f675a=this['editor']['model']['schema'];let _0x13a83a=_0x539920;for(;_0x7ea196[_0x13a83a]&&_0x7ea196[_0x13a83a]['isAdded'];)_0x13a83a++;let _0x23401b=_0x55daab;for(;_0xd2478f[_0x23401b]&&_0xd2478f[_0x23401b]['isRemoved'];)_0x23401b++;_0x1497ba(_0x7ea196,_0x539920,_0x13a83a),_0x1497ba(_0xd2478f,_0x55daab,_0x23401b);const _0x5236df=_0xd2478f['slice'](_0x55daab,_0x23401b)['concat'](_0x7ea196['slice'](_0x539920,_0x13a83a));return _0x5236df['sort']((_0x2ebeb5,_0x3c708e)=>_0x2ebeb5['side']!=_0x3c708e['side']?_0x2ebeb5['side']-_0x3c708e['side']:_0x2ebeb5['level']!=_0x3c708e['level']?_0x2ebeb5['level']-_0x3c708e['level']:_0x2ebeb5['distance']!=_0x3c708e['distance']?_0x3c708e['distance']-_0x2ebeb5['distance']:!!_0x2ebeb5['isAdded']!=!!_0x3c708e['isAdded']?-0x1==_0x2ebeb5['side']||0x0==_0x2ebeb5['side']?_0x2ebeb5['isAdded']?-0x1:0x1:_0x2ebeb5['isAdded']?0x1:-0x1:_0x2ebeb5['index']-_0x3c708e['index']),{'commonTape':_0x5236df,'iEnd':_0x13a83a,'jEnd':_0x23401b};function _0x1497ba(_0x1733ff,_0xb66f32,_0x1a11b3){let _0x42722f=-0x1,_0x4de679=Number['POSITIVE_INFINITY'],_0x53ae7c=!0x0;for(let _0x27b964=_0xb66f32;_0x27b964<_0x1a11b3;_0x27b964++)if(_0x1f675a['isInline'](_0x1733ff[_0x27b964]['item'])||(_0x53ae7c=!0x1),_0x1733ff[_0x27b964]['item']['startIndex']<_0xb66f32&&(_0x42722f=_0x27b964),_0x1733ff[_0x27b964]['item']['endIndex']>=_0x1a11b3){_0x4de679=_0x27b964;break;}_0x53ae7c&&(_0x42722f=_0x1a11b3-0x1);for(let _0x530a3e=_0xb66f32;_0x530a3e<_0x1a11b3;_0x530a3e++)_0x1733ff[_0x530a3e]['side']=_0x530a3e<=_0x42722f?-0x1:_0x530a3e<_0x4de679?0x0:0x1,_0x1733ff[_0x530a3e]['index']=_0x530a3e;let _0x2cc7e5=0x0;for(let _0x3e4919=_0xb66f32;_0x3e4919<=_0x42722f;_0x3e4919++)0x0==_0x1733ff[_0x3e4919]['distance']?_0x1733ff[_0x3e4919]['level']=_0x2cc7e5:(_0x2cc7e5++,_0x1733ff[_0x3e4919]['level']=_0x2cc7e5,_0x2cc7e5++);for(let _0x2a9b82=_0xb66f32;_0x2a9b82<_0x1a11b3;_0x2a9b82++)0x0==_0x1733ff[_0x2a9b82]['side']&&(_0x1733ff[_0x2a9b82]['level']=_0x2cc7e5);_0x2cc7e5=0x0;for(let _0x36bd8f=_0x1a11b3-0x1;_0x36bd8f>=_0x4de679;_0x36bd8f--)0x0==_0x1733ff[_0x36bd8f]['distance']?_0x1733ff[_0x36bd8f]['level']=_0x2cc7e5:(_0x2cc7e5--,_0x1733ff[_0x36bd8f]['level']=_0x2cc7e5,_0x2cc7e5--);}}['_fixObsoleteTags'](_0x1d6bbc){const _0x267c80=new Map(),_0x2ec3ee=this['editor']['model']['schema'];for(let _0x1827a4=0x1;_0x1827a4<_0x1d6bbc['length'];_0x1827a4++){let _0x50c6e6,_0xb9e3ab,_0x27ae42;const _0x19d986=_0x1d6bbc[_0x1827a4],_0x318883=_0x1d6bbc[_0x1827a4-0x1];if('text'==_0x19d986['type'])continue;if(_0x19d986['type']!=_0x318883['type'])continue;if(!_0x2ec3ee['isBlock'](_0x318883['item'])||_0x2ec3ee['isLimit'](_0x318883['item']))continue;if(!_0x2ec3ee['isBlock'](_0x19d986['item'])||_0x2ec3ee['isLimit'](_0x19d986['item']))continue;if((_0x1d6bbc[_0x1827a4]['isAdded']||_0x1d6bbc[_0x1827a4]['isAddSuggestion'])&&_0x1d6bbc[_0x1827a4-0x1]['isRemoved'])_0x50c6e6=_0x1d6bbc[_0x1827a4],_0xb9e3ab=_0x1d6bbc[_0x1827a4-0x1],_0x27ae42=_0x1827a4-0x1;else{if(!_0x1d6bbc[_0x1827a4]['isRemoved']||!_0x1d6bbc[_0x1827a4-0x1]['isAdded']&&!_0x1d6bbc[_0x1827a4-0x1]['isAddSuggestion'])continue;_0x50c6e6=_0x1d6bbc[_0x1827a4-0x1],_0xb9e3ab=_0x1d6bbc[_0x1827a4],_0x27ae42=_0x1827a4;}const _0x3e44f6=_0x50c6e6['level']==_0xb9e3ab['level'],_0x5bf9d8=Math['abs'](_0x50c6e6['level'])<Math['abs'](_0xb9e3ab['level'])&&0x0==_0xb9e3ab['distance'];(_0x3e44f6||_0x5bf9d8)&&(_0x267c80['set'](_0xb9e3ab['id'],_0x50c6e6['id']),_0x1d6bbc['splice'](_0x27ae42,0x1),_0x1827a4--,_0x50c6e6['isAdded']=!0x1);}for(let _0x28b37c=0x0;_0x28b37c<_0x1d6bbc['length'];_0x28b37c++)_0x267c80['has'](_0x1d6bbc[_0x28b37c]['pairId'])&&(_0x1d6bbc[_0x28b37c]['pairId']=_0x267c80['get'](_0x1d6bbc[_0x28b37c]['pairId']));}['_removeMissingPairs'](_0x12f6ba){const _0x3c7ee7=new Set(_0x12f6ba['map'](_0xf23740=>_0xf23740['id']));for(let _0x6b123b=0x0;_0x6b123b<_0x12f6ba['length'];_0x6b123b++)_0x3c7ee7['has'](_0x12f6ba[_0x6b123b]['pairId'])||0x0==_0x12f6ba[_0x6b123b]['distance']||(_0x12f6ba[_0x6b123b]['isIncorrect']=!0x0);return _0x12f6ba['filter'](_0x223ec4=>!_0x223ec4['isIncorrect']);}['_markMismatchedRemovedTags'](_0x5a3885){const _0x11adcc=new Set();for(let _0x1e7882=0x0;_0x1e7882<_0x5a3885['length'];_0x1e7882++){if(_0x11adcc['has'](_0x5a3885[_0x1e7882]['id'])&&_0x5a3885[_0x1e7882]['isRemoved']&&(_0x5a3885[_0x1e7882]['isIncorrect']=!0x0),_0x5a3885[_0x1e7882]['isIncorrect'])continue;if(0x0==_0x5a3885[_0x1e7882]['distance'])continue;if('elementStart'!=_0x5a3885[_0x1e7882]['type'])continue;if(null==_0x5a3885[_0x1e7882]['pairId'])continue;let _0x37b397=_0x1e7882+0x1,_0x2c32bf=0x0;for(;_0x5a3885[_0x37b397]['id']!=_0x5a3885[_0x1e7882]['pairId'];)'elementStart'==_0x5a3885[_0x37b397]['type']?_0x2c32bf++:'elementEnd'==_0x5a3885[_0x37b397]['type']&&_0x2c32bf--,_0x37b397++;if(0x0!=_0x2c32bf){if(_0x5a3885[_0x1e7882]['isRemoved'])_0x5a3885[_0x1e7882]['isIncorrect']=!0x0;else{for(;_0x37b397!=_0x1e7882;)_0x5a3885[_0x37b397]['isRemoved']&&0x0!=_0x5a3885[_0x37b397]['distance']&&(_0x5a3885[_0x37b397]['isIncorrect']=!0x0,_0x11adcc['add'](_0x5a3885[_0x37b397]['pairId'])),_0x37b397--;}}}return _0x5a3885['filter'](_0x47fa93=>!_0x47fa93['isIncorrect']);}['_removeUnsupportedChanges'](_0x3cf411){const _0x3871f2=this['editor']['model']['schema'];for(let _0x463e4c=0x0;_0x463e4c<_0x3cf411['length'];_0x463e4c++){if(!(_0x3cf411[_0x463e4c]['isAdded']||_0x3cf411[_0x463e4c]['isAddSuggestion']||_0x3cf411[_0x463e4c]['isRemoved']||_0x3cf411[_0x463e4c]['isRemoveSuggestion']))continue;if(0x0==_0x3cf411[_0x463e4c]['distance'])continue;const _0x39205e=_0x3cf411[_0x463e4c]['item'];_0x3871f2['isBlock'](_0x39205e)||_0x3871f2['isLimit'](_0x39205e)||(_0x3cf411[_0x463e4c]['isAdded']&&delete _0x3cf411[_0x463e4c]['isAdded'],_0x3cf411[_0x463e4c]['isAddSuggestion']&&delete _0x3cf411[_0x463e4c]['isAddSuggestion'],_0x3cf411[_0x463e4c]['isRemoveSuggestion']&&delete _0x3cf411[_0x463e4c]['isRemoveSuggestion'],_0x3cf411[_0x463e4c]['isRemoved']&&(_0x3cf411[_0x463e4c]['isIncorrect']=!0x0));}return _0x3cf411['filter'](_0x5abc53=>!_0x5abc53['isIncorrect']);}['_makeModelFromTape'](_0x12071d,_0xb79b6f,_0x3eb3ed){const _0x222871=new mt(),_0x3abebf=[],_0x508155=new Map(),_0x58ce3e=this['editor']['model'],_0x1d8136=_0x58ce3e['schema'],_0x117daa=[_0x222871],_0x298588={},_0x101cc2={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x35e4de=null;const _0x55ef4c=[0x0];for(let _0x1f3773=0x0;_0x1f3773<_0x12071d['length'];_0x1f3773++)if('elementStart'===_0x12071d[_0x1f3773]['type']){_0x12071d[_0x1f3773]['previousPosition']=_0x58ce3e['createPositionFromPath'](_0x222871,_0x55ef4c);const _0x342018=new ft(_0x12071d[_0x1f3773]['item']['name'],_0x12071d[_0x1f3773]['item']['getAttributes']());_0x117daa[0x0]['_appendChild'](_0x342018),_0x55ef4c['push'](0x0),_0x117daa['unshift'](_0x342018),_0x12071d[_0x1f3773]['nextPosition']=_0x58ce3e['createPositionFromPath'](_0x222871,_0x55ef4c);}else'elementEnd'===_0x12071d[_0x1f3773]['type']?(_0x117daa['shift'](),_0x12071d[_0x1f3773]['previousPosition']=_0x58ce3e['createPositionFromPath'](_0x222871,_0x55ef4c),_0x55ef4c['pop'](),_0x55ef4c[_0x55ef4c['length']-0x1]++,_0x12071d[_0x1f3773]['nextPosition']=_0x58ce3e['createPositionFromPath'](_0x222871,_0x55ef4c)):(_0x12071d[_0x1f3773]['previousPosition']=_0x58ce3e['createPositionFromPath'](_0x222871,_0x55ef4c),_0x35e4de?_0x35e4de['_data']+=_0x12071d[_0x1f3773]['item']['data']:_0x35e4de=new wt(_0x12071d[_0x1f3773]['item']['data'],_0x12071d[_0x1f3773]['item']['getAttributes']()),_0x12071d[_0x1f3773+0x1]&&'text'===_0x12071d[_0x1f3773+0x1]['type']&&_0x31a757(_0x35e4de,_0x12071d[_0x1f3773+0x1]['item'])||(_0x117daa[0x0]['_appendChild'](_0x35e4de),_0x35e4de=null),_0x55ef4c[_0x55ef4c['length']-0x1]+=_0x12071d[_0x1f3773]['item']['offsetSize'],_0x12071d[_0x1f3773]['nextPosition']=_0x58ce3e['createPositionFromPath'](_0x222871,_0x55ef4c));for(let _0x4ac1bf=0x0;_0x4ac1bf<_0x12071d['length'];_0x4ac1bf++){const _0x33142d=_0x12071d[_0x4ac1bf]['previousPosition'],_0x93b576=_0x12071d[_0x4ac1bf]['nextPosition'];for(const _0x23b00a of _0x12071d[_0x4ac1bf]['markersStart'])_0x508155['set'](_0x23b00a,{'start':_0x33142d,'end':null});_0x17ac39('isRemoveSuggestion',_0x4ac1bf,_0x33142d,_0x93b576),_0x17ac39('isAddSuggestion',_0x4ac1bf,_0x33142d,_0x93b576),_0x17ac39('isRemoved',_0x4ac1bf,_0x33142d,_0x93b576),_0x17ac39('isAdded',_0x4ac1bf,_0x33142d,_0x93b576);for(const _0x1ee241 of _0x12071d[_0x4ac1bf]['markersEnd']){_0x508155['get'](_0x1ee241)['end']=_0x93b576;}}for(const [_0x45459f,_0x426b03]of _0x508155){const _0x35eb12=this['editor']['model']['createRange'](_0x426b03['start'],_0x426b03['end']);_0x222871['markers']['set'](_0x45459f,_0x35eb12);}return _0x3abebf['sort']((_0x482ac8,_0x498992)=>{const _0x462db2=_0x222871['markers']['get']('revision:'+_0x482ac8['id']),_0x5952c1=_0x222871['markers']['get']('revision:'+_0x498992['id']);return _0x462db2['start']['isBefore'](_0x5952c1['start'])?-0x1:_0x462db2['start']['isAfter'](_0x5952c1['start'])?0x1:_0x462db2['end']['isBefore'](_0x5952c1['end'])?-0x1:_0x462db2['end']['isAfter'](_0x5952c1['end'])?0x1:'add'===_0x482ac8['type']?-0x1:0x1;}),{'root':_0x222871,'changes':_0x3abebf};function _0x17ac39(_0x48c065,_0x29bd73,_0x2cf443,_0x22acfc){const _0x39b4e8=!!_0x12071d[_0x29bd73][_0x48c065],_0x3944be=_0x39b4e8?_0x12071d[_0x29bd73][_0x48c065]['userId']:null,_0x10c1bc=_0x29bd73===_0x12071d['length']-0x1,_0x22d9cd=_0x101cc2[_0x48c065][0x0],_0x2e9f33=_0x1d8136['isObject'](_0x12071d[_0x29bd73]['item']);!_0x298588[_0x48c065]&&_0x39b4e8?_0x298588[_0x48c065]={'start':_0x2cf443,'tapeItem':_0x12071d[_0x29bd73],'userId':_0x3944be,'type':_0x48c065}:_0x298588[_0x48c065]&&!_0x39b4e8?(_0x298588[_0x48c065]['end']=_0x2cf443,_0x5ad6ba(_0x298588[_0x48c065]),_0x298588[_0x48c065]=null):_0x298588[_0x48c065]&&_0x39b4e8&&_0x298588[_0x48c065]['userId']!==_0x3944be&&(_0x298588[_0x48c065]['end']=_0x2cf443,_0x22d9cd&&_0x22d9cd['userId']===_0x298588[_0x48c065]['userId']||_0x5ad6ba(_0x298588[_0x48c065]),_0x298588[_0x48c065]={'start':_0x2cf443,'tapeItem':_0x12071d[_0x29bd73],'userId':_0x3944be,'type':_0x48c065}),_0x298588[_0x48c065]&&_0x2e9f33&&('elementStart'!==_0x12071d[_0x29bd73]['type']||_0x22d9cd&&_0x22d9cd['userId']===_0x3944be||_0x101cc2[_0x48c065]['unshift']({'userId':_0x3944be,'object':_0x12071d[_0x29bd73]['item'],'change':_0x298588[_0x48c065]}),'elementEnd'===_0x12071d[_0x29bd73]['type']&&_0x22d9cd&&_0x22d9cd['object']===_0x12071d[_0x29bd73]['item']&&(_0x101cc2[_0x48c065]['shift'](),_0x298588[_0x48c065]=_0x22d9cd['change'])),_0x298588[_0x48c065]&&_0x10c1bc&&(_0x298588[_0x48c065]['end']=_0x22acfc,_0x5ad6ba(_0x298588[_0x48c065]),_0x298588[_0x48c065]=null);}function _0x5ad6ba({start:_0x5961de,end:_0x5de395,tapeItem:_0x5a439f,userId:_0x48f5a4,type:_0x5010d9}){const _0x401830=_0x5a439f['item'],_0x18b515=_0x58ce3e['schema']['isBlock'](_0x401830)&&!_0x58ce3e['schema']['isLimit'](_0x401830),_0x5468fd=_0x5961de['nodeAfter']==_0x5de395['parent']&&_0x5de395['isAtStart'];if(_0x18b515&&_0x5468fd)return;const _0x300928=_0x58ce3e['createRange'](_0x5961de,_0x5de395),_0x278e58=_0xb79b6f['get'](_0x48f5a4),_0x16e3d8=new r({'author':_0x278e58,'type':'isAdded'==_0x5010d9||'isAddSuggestion'==_0x5010d9?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x5010d9||'isRemoveSuggestion'==_0x5010d9},'createdAt':new Date(),'rootName':_0x3eb3ed});_0x3abebf['push'](_0x16e3d8),_0x222871['markers']['set']('revision:'+_0x16e3d8['id'],_0x300928);}function _0x31a757(_0x5dcddf,_0x3d0068){const _0x599113=_0x5dcddf['getAttributes'](),_0x52c997=_0x3d0068['getAttributes']();for(const _0x4da422 of _0x599113){if(_0x4da422[0x1]!==_0x3d0068['getAttribute'](_0x4da422[0x0]))return!0x1;_0x52c997['next']();}return _0x52c997['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x42e3e7=>{const _0x5e3509=_0x42e3e7['markerName']['split'](':')[0x1],_0x227353=this['_getChangeFromId'](_0x5e3509);if(!_0x227353)return null;const _0x476a5d='add'==_0x227353['type']?'insertion':'deletion',_0x5c021e=['ck-suggestion-marker','ck-suggestion-marker-'+_0x476a5d];return _0x227353['data']['isSuggestion']&&_0x5c021e['push']('ck-suggestion-marker-'+_0x476a5d+'-new'),this['activeChange']==_0x227353&&_0x5c021e['push']('ck-suggestion-marker--active'),{'classes':_0x5c021e,'attributes':{'data-change-id':_0x5e3509}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x195260=>{_0x195260['on']('element:pre',(_0x15b0a5,_0x4ba037,_0x4621d7)=>{const _0x344737=_0x4ba037['viewItem']['getChild'](0x0);if(!_0x344737||!_0x344737['is']('element','code'))return;if(!_0x4621d7['consumable']['consume'](_0x344737,{'attributes':['vid_start','vid_end']}))return;const _0x2bc08a=_0x4ba037['modelRange']['start']['nodeAfter'];_0x4621d7['writer']['setAttribute']('vid_start',_0x344737['getAttribute']('vid_start'),_0x2bc08a),_0x4621d7['writer']['setAttribute']('vid_end',_0x344737['getAttribute']('vid_end'),_0x2bc08a);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x4de021=>{_0x4de021['on']('element',(_0x40299b,_0xbc4520,_0x2b60d4)=>{if(!_0x2b60d4['consumable']['consume'](_0xbc4520['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0xbc4520['modelRange']['isCollapsed'])return;const _0x256290=_0xbc4520['modelRange']['start']['nodeAfter'];_0x256290['hasAttribute']('vid_start')||_0x256290['hasAttribute']('vid')||(_0x2b60d4['writer']['setAttribute']('vid_start',_0xbc4520['viewItem']['getAttribute']('vid_start'),_0x256290),_0x2b60d4['writer']['setAttribute']('vid_end',_0xbc4520['viewItem']['getAttribute']('vid_end'),_0x256290));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0xa3804b=>_0xa3804b['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x414427,[,_0x2136db])=>{['vid_start','vid_end','vid']['includes'](_0x2136db)&&(_0x414427['return']=!0x0,_0x414427['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x21a99e=>{_0x21a99e['on']('attribute:vid',(_0x3f51f7,_0x4f5bf0,_0x4b9522)=>{if('\x20'!=_0x4f5bf0['item']['data']||_0x4f5bf0['item']['parent']['maxOffset']>0x1)return;if(!_0x4b9522['consumable']['consume'](_0x4f5bf0['item'],_0x3f51f7['name']))return;const _0xa9d3a1=_0x4b9522['writer'],_0x1eb957=_0x4b9522['mapper']['toViewRange'](_0x4f5bf0['range']);_0xa9d3a1['wrap'](_0x1eb957,_0xa9d3a1['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x4bafa0){const _0x31b643=_0x4bafa0['plugins']['get']('RevisionViewer');return(_0x4325d9,_0x51f6e2,_0x3cff69)=>{const _0x2228b9=_0x51f6e2['markerName']['split'](':')[0x1],_0x376e39=_0x31b643['_getChangeFromId'](_0x2228b9);if(!_0x376e39)return null;const _0x67452f='add'==_0x376e39['type']?'split':'merge';if(!_0x3cff69['consumable']['test'](_0x51f6e2['markerRange'],_0x4325d9['name']))return;const _0x53306a=_0x51f6e2['markerRange']['getWalker'](),_0x4a9914=_0x51f6e2['markerRange']['start'],_0x2a93a2=_0x4bafa0['model']['schema'];let _0x488268=null,_0x99ad99=null,_0x13bc18=!0x1,_0x5f3436=!0x1;for(const _0x6333dc of _0x53306a){const _0x1fdb4f=_0x6333dc['item'];_0x13bc18=_0x13bc18||_0x2a93a2['isContent'](_0x1fdb4f);const _0x171ad4=_0x3cff69['mapper']['toViewElement'](_0x1fdb4f);if(_0x171ad4&&_0x171ad4['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x6333dc['type']&&(_0x2a93a2['isBlock'](_0x1fdb4f)&&!_0x2a93a2['isLimit'](_0x1fdb4f)&&(_0x1fdb4f['nextSibling']||_0x4a9914['isAtEnd']?_0x488268&&_0x488268['parent']==_0x1fdb4f||(_0x488268=_0x1fdb4f,_0x2c2204(_0x6333dc['previousPosition']),_0x5f3436=!0x0):_0x99ad99=_0x99ad99||_0x6333dc['previousPosition']));}function _0x2c2204(_0x347d0b){const _0x1a2285=_0x3cff69['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x67452f}),_0x4e2020=_0x3cff69['mapper']['toViewPosition'](_0x347d0b);_0x376e39['data']['isSuggestion']&&_0x3cff69['writer']['addClass']('ck-suggestion-marker-'+_0x67452f+'-new',_0x1a2285),_0x31b643['activeChange']==_0x376e39&&_0x3cff69['writer']['addClass']('ck-suggestion-marker--active',_0x1a2285),_0x3cff69['writer']['insert'](_0x4e2020,_0x1a2285),_0x3cff69['mapper']['bindElementToMarker'](_0x1a2285,_0x51f6e2['markerName']);}_0x13bc18||_0x5f3436||!_0x99ad99||_0x2c2204(_0x99ad99);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x309a48,_0xd62c96,_0x82f0e1)=>{const _0x3284bc=_0x82f0e1['mapper']['markerNameToElements'](_0xd62c96['markerName']);if(_0x3284bc){for(const _0x7e24cd of _0x3284bc)(_0x7e24cd['hasClass']('ck-suggestion-marker-split')||_0x7e24cd['hasClass']('ck-suggestion-marker-merge'))&&(_0x82f0e1['mapper']['unbindElementFromMarkerName'](_0x7e24cd,_0xd62c96['markerName']),_0x82f0e1['writer']['remove'](_0x7e24cd));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x4a4acb,_0x332957,_0x542b90)=>{const _0x2cf25f=_0x332957['markerName']['split'](':')[0x1],_0x40e8c8=this['_getChangeFromId'](_0x2cf25f);if(!_0x40e8c8)return null;const _0x5c4e0e='add'==_0x40e8c8['type']?'split':'merge';if(_0x542b90['consumable']['test'](_0x332957['markerRange'],_0x4a4acb['name']))for(const _0x42f233 of _0x332957['markerRange']['getItems']()){if(!_0x42f233['is']('element','softBreak'))continue;const _0x589503=_0x542b90['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x5c4e0e}),_0x12ec73=_0x542b90['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x42f233));_0x40e8c8['data']['isSuggestion']&&_0x542b90['writer']['addClass']('ck-suggestion-marker-'+_0x5c4e0e+'-new',_0x589503),this['activeChange']==_0x40e8c8&&_0x542b90['writer']['addClass']('ck-suggestion-marker--active',_0x589503),_0x542b90['writer']['insert'](_0x12ec73,_0x589503),_0x542b90['mapper']['bindElementToMarker'](_0x589503,_0x332957['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x510d99=>{for(const _0x4b5ea6 of this['editor']['model']['document']['getRootNames']()){const _0x53828c=this['editor']['model']['document']['getRoot'](_0x4b5ea6),_0x554093=this['editor']['editing']['view']['document']['getRoot'](_0x4b5ea6);if(_0x554093){const _0x9c7e4c=_0x53828c['getAttribute']('revisionHistoryAttachChange');if(_0x510d99['removeAttribute']('data-change-id',_0x554093),_0x510d99['removeClass']('ck-revision-history-root-add',_0x554093),_0x510d99['removeClass']('ck-revision-history-root-remove',_0x554093),_0x510d99['removeClass']('ck-revision-history-root--active',_0x554093),_0x9c7e4c){const _0x2ceb04=this['_getChangeFromId'](_0x9c7e4c);if(!_0x2ceb04)return null;_0x510d99['setAttribute']('data-change-id',_0x9c7e4c,_0x554093),_0x510d99['addClass']('ck-revision-history-root-'+_0x2ceb04['type'],_0x554093),this['activeChange']==_0x2ceb04&&_0x510d99['addClass']('ck-revision-history-root--active',_0x554093);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x4b98ea=>'revision-comment:'+_0x4b98ea,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x4e1aac=>'revision-suggestion:'+_0x4e1aac,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x421d90=>({'name':'suggestion:'+_0x421d90,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x216dfc=>{const _0x4e6dad=_0x216dfc['markerName']['split'](':')[0x1];return'insertion'!=_0x4e6dad&&'deletion'!=_0x4e6dad?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x4e6dad]};}}),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',(_0x41468c,_0xe6a64c,_0x66f055)=>{const _0x20e32b=_0x66f055['mapper']['markerNameToElements'](_0xe6a64c['markerName']);if(_0x20e32b){for(const _0x1ec571 of _0x20e32b)_0x1ec571['is']('uiElement')&&(_0x66f055['mapper']['unbindElementFromMarkerName'](_0x1ec571,_0xe6a64c['markerName']),_0x66f055['writer']['remove'](_0x1ec571));}},{'priority':'high'});}['_getChangeFromId'](_0x55b44c){return this['_changeIdToChange']['get'](_0x55b44c);}['_getViewForChange'](_0x16aa9f){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new X(this['editor']['locale'],_0x16aa9f),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x595ade,_0x14e484,_0x4329e6,_0x896fb0)=>{_0x896fb0&&this['_balloon']['remove'](_0x896fb0),_0x4329e6&&(this['_balloon']['add']({'view':_0x4329e6,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x50aa6a=this['editor']['editing'],_0x33f312=this['_getChangeFromId'](_0x4329e6['changeId']);let _0x268db8;if(_0x33f312['data']['isOnRoot']){const _0x5b5c7d=_0x50aa6a['view']['getDomRoot'](_0x33f312['rootName']);_0x268db8=Array['from'](_0x5b5c7d['getClientRects']());}else{const _0xa40a87=this['editor']['model']['markers']['get']('revision:'+_0x4329e6['changeId']);_0x268db8=Array['from'](_0x50aa6a['mapper']['markerNameToElements'](_0xa40a87['name']))['map'](_0x44b200=>_0x50aa6a['view']['domConverter']['mapViewToDom'](_0x44b200))['map'](_0x4fa8e0=>Array['from'](_0x4fa8e0['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x268db8[0x0];return _0x268db8['find'](_0x4c23fa=>_0x4c23fa['top']-0x3<=this['_activeViewTarget']['y']&&_0x4c23fa['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x4c23fa['left']-0x3<=this['_activeViewTarget']['x']&&_0x4c23fa['right']+0x3>=this['_activeViewTarget']['x'])||_0x268db8[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x26246f,_0xeb7d8,_0x236eec,_0x2cc293)=>{this['activeView']=_0x236eec?this['_getViewForChange'](_0x236eec):null,this['editor']['model']['change'](()=>{const _0x176b0d=this['editor']['editing'];_0x2cc293&&(_0x2cc293['data']['isOnRoot']?_0x176b0d['view']['change'](_0x44077b=>{_0x44077b['removeClass']('ck-revision-history-root--active',_0x176b0d['view']['document']['getRoot'](_0x2cc293['rootName']));}):_0x176b0d['reconvertMarker']('revision:'+_0x2cc293['id'])),_0x236eec&&(_0x236eec['data']['isOnRoot']?_0x176b0d['view']['change'](_0x38c158=>{_0x38c158['addClass']('ck-revision-history-root--active',_0x176b0d['view']['document']['getRoot'](_0x236eec['rootName']));}):_0x176b0d['reconvertMarker']('revision:'+_0x236eec['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x2b35ed,_0x5e020e)=>{if(this['activeChange'])return;const _0x2d774d=this['_findChangeIdFromDomTarget'](_0x5e020e['target']),_0x160e96=this['_changeIdToChange']['get'](_0x2d774d);_0x160e96?(this['_activeViewTarget']={'x':_0x5e020e['domEvent']['x'],'y':_0x5e020e['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x160e96)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x516069,_0xd99d8c)=>{const _0x137cd6=this['_findChangeIdFromDomTarget'](_0xd99d8c['target']),_0x110702=this['_changeIdToChange']['get'](_0x137cd6);_0x110702?(this['_activeViewTarget']={'x':_0xd99d8c['domEvent']['x'],'y':_0xd99d8c['domEvent']['y']},_0x110702===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x110702):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x2dd6a6){do{const _0x36520e=_0x2dd6a6['getAttribute']('data-change-id');if(_0x36520e)return _0x36520e;_0x2dd6a6=_0x2dd6a6['parent'];}while(_0x2dd6a6);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x5ab91a=>{for(const _0x1bc7c4 of this['editor']['model']['markers'])_0x5ab91a['removeMarker'](_0x1bc7c4);});}}function Z(_0x336dc9,_0xa52bc0){return(_0x3502af,_0x30ada8,_0x114976)=>{if(!_0x114976['consumable']['test'](_0x30ada8['markerRange'],_0x3502af['name']))return;const _0x41880e=_0x30ada8['markerRange']['getWalker'](),_0x2928f9=_0x30ada8['markerRange']['start'],_0xbd2fe7=_0x336dc9['model']['schema'];let _0x332f87=null,_0x1e389a=null,_0x573359=!0x1,_0x3efa91=!0x1;for(const _0x167107 of _0x41880e){const _0x44286b=_0x167107['item'];_0x573359=_0x573359||_0xbd2fe7['isContent'](_0x44286b);const _0x39b627=_0x114976['mapper']['toViewElement'](_0x44286b);if(_0x39b627&&_0x39b627['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x167107['type']&&(_0xbd2fe7['isBlock'](_0x44286b)&&!_0xbd2fe7['isLimit'](_0x44286b)&&(_0x44286b['nextSibling']||_0x2928f9['isAtEnd']?_0x332f87&&_0x332f87['parent']==_0x44286b||(_0x332f87=_0x44286b,_0x55b047(_0x167107['previousPosition']),_0x3efa91=!0x0):_0x1e389a=_0x1e389a||_0x167107['previousPosition']));}function _0x55b047(_0xb5ae9a){const _0x14c3ee=_0x114976['mapper']['toViewPosition'](_0xb5ae9a),_0xb30b29=_0x114976['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0xa52bc0});_0x114976['writer']['insert'](_0x14c3ee,_0xb30b29),_0x114976['mapper']['bindElementToMarker'](_0xb30b29,_0x30ada8['markerName']);}_0x573359||_0x3efa91||!_0x1e389a||_0x55b047(_0x1e389a);};}class _t extends _0x2f351f{constructor(_0x4672af){super(_0x4672af);const _0x592c6e=_0x4672af['plugins']['get'](d);this['affectsData']=!0x1,this['listenTo'](_0x592c6e,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x592c6e,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x51da82=this['editor'],_0x54aaa9=_0x51da82['plugins']['get'](d),_0x19bb7a=_0x54aaa9['isReady']?_0x54aaa9['diff']['newRevisionId']:null;_0x51da82['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x19bb7a);}['refresh'](){const {isReady:_0x41e5c5,isEnabled:_0x2d28dd,repository:_0x4736c6,diff:_0x46acd5}=this['editor']['plugins']['get'](d),_0x353680=_0x46acd5&&_0x4736c6['getLaterVisibleRevision'](_0x46acd5['newRevisionId']);this['isEnabled']=_0x41e5c5&&_0x2d28dd&&Boolean(_0x353680);}}class yt extends _0x2f351f{['_step'];constructor(_0x5968b0,{direction:_0x249010}){super(_0x5968b0);const _0x2646ad=_0x5968b0['plugins']['get'](d);this['affectsData']=!0x1,this['_step']='forward'===_0x249010?0x1:-0x1,this['listenTo'](_0x2646ad,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x2646ad,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x2646ad,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x203e1a=this['editor'],_0x40304f=_0x203e1a['plugins']['get'](d),{isNavigationMode:_0x3067ce,currentChangeNumber:_0x4dbd22}=_0x40304f;let _0x22c86f;if(_0x40304f['activeChange']=_0x3067ce?_0x40304f['diff']['changes']['get'](_0x4dbd22+this['_step']):_0x40304f['diff']['changes']['first'],_0x40304f['activeChange']['data']['isOnRoot'])_0x22c86f=_0x203e1a['editing']['view']['getDomRoot'](_0x40304f['activeChange']['rootName']);else{const _0x19dbf8=_0x203e1a['model']['markers']['get']('revision:'+_0x40304f['activeChange']['id']);_0x22c86f=_0x54db46(_0x203e1a['editing'],_0x19dbf8);}_0x30a2cb({'target':_0x22c86f,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x4ca879,currentChangeNumber:_0x2fff7e,numberOfChanges:_0x520962,isReady:_0xf84405,isEnabled:_0x14a5d0}=this['editor']['plugins']['get'](d);this['isEnabled']=!!(_0x14a5d0&&_0xf84405&&_0x520962)&&(!_0x4ca879||(0x1===this['_step']?_0x2fff7e<_0x520962-0x1:_0x2fff7e>0x0));}}class di extends _0x376464{constructor(_0x2472da){super(_0x2472da);const _0x44732c=this['bindTemplate'],_0x13e2b2=new _0x58a9b0(_0x2472da),_0x2a7ffe=new _0x58a9b0(_0x2472da);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',(_0x45c4c6,_0x268d45)=>_0x45c4c6&&_0x268d45>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x5bdb13,_0x22bd01,_0x3dbf29,_0x8cd7ba)=>{if(!_0x5bdb13)return m(_0x2472da,'Loading...');if(!_0x3dbf29)return m(_0x2472da,'No\x20changes');const _0x5f5490=m(_0x2472da,'NUMBER_OF_CHANGES',_0x3dbf29);return _0x8cd7ba?m(_0x2472da,'X_OF_Y_CHANGES',[_0x22bd01+0x1,_0x3dbf29]):_0x5f5490;}),_0x13e2b2['set']({'label':m(_0x2472da,'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'}),_0x2a7ffe['set']({'label':m(_0x2472da,'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'}),_0x13e2b2['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x2a7ffe['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x13e2b2['on']('execute',()=>this['fire']('execute','backward')),_0x2a7ffe['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',_0x44732c['if']('_isStatusLabelVisible','ck-hidden',_0x45e913=>!_0x45e913)]},'children':[{'text':_0x44732c['to']('isNavigationMode',_0x470d64=>_0x470d64?m(_0x2472da,'EDIT_X_OF_Y_REVISIONS')+':\x20':m(_0x2472da,'Total')+':\x20')}]},{'text':_0x44732c['to']('_statusText')}]},new _0x1378c1(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x13e2b2,_0x2a7ffe]}]});}}const ce='ck-editor__editable__loading-overlay';class ae extends _0x361651{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0xe3a8b3=this['editor']['editing']['view'];_0xe3a8b3['change'](_0x13a4d4=>{for(const _0x214ccf of _0xe3a8b3['document']['roots'])_0x13a4d4['addClass'](ce,_0x214ccf);});}['hide'](){const _0x3f8e04=this['editor']['editing']['view'];_0x3f8e04['change'](_0x4bd34c=>{for(const _0x32ab49 of _0x3f8e04['document']['roots'])_0x4bd34c['removeClass'](ce,_0x32ab49);});}}class g extends _0x361651{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[d,ae];}['init'](){const _0x2b7c13=this['editor'],_0x2a2511=_0x2b7c13['plugins']['get'](d),_0x1ccee7=_0x2b7c13['plugins']['get'](ae);_0x2b7c13['ui']['componentFactory']['add']('exitToEditing',_0x391737=>{const _0x3dd70c=new _0x58a9b0(_0x391737);return _0x3dd70c['set']({'label':m(_0x391737,'Back\x20to\x20editing'),'icon':_0x2a914a['undo'],'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x3dd70c,'execute',()=>{_0x2b7c13['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x3dd70c;}),_0x2b7c13['ui']['componentFactory']['add']('restoreRevision',_0x29b26c=>{const _0x4b0519=new _0x58a9b0(_0x29b26c);return _0x4b0519['set']({'label':m(_0x29b26c,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x4b0519['bind']('isEnabled')['to'](_0x2b7c13['commands']['get']('restoreRevision')),this['listenTo'](_0x4b0519,'execute',()=>_0x2b7c13['execute']('restoreRevision')),_0x4b0519;}),_0x2b7c13['ui']['componentFactory']['add']('changesNavigation',_0x4de4de=>{const _0x288f57=new di(_0x4de4de),_0x24b11e=_0x2b7c13['commands']['get']('showPreviousChange'),_0x3b0ada=_0x2b7c13['commands']['get']('showNextChange');return _0x288f57['bind']('isBackwardNavigationEnabled')['to'](_0x24b11e,'isEnabled'),_0x288f57['bind']('isForwardNavigationEnabled')['to'](_0x3b0ada,'isEnabled'),_0x288f57['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x2a2511),this['listenTo'](_0x288f57,'execute',(_0xabc14f,_0x9e6523)=>{_0x2b7c13['execute']('forward'===_0x9e6523?'showNextChange':'showPreviousChange');}),_0x288f57;}),_0x1ccee7['show'](),_0x2a2511['on']('change:isReady',(_0x26fdbd,_0x144e53,_0x2bd47d)=>{_0x2bd47d?_0x1ccee7['hide']():_0x1ccee7['show']();});}}class pt extends nt{['_resizeObserver']=null;constructor(_0x2c0582,_0x1403f9){super(_0x2c0582,_0x1403f9);const _0x200e14=this['bindTemplate'];this['set']({'label':m(_0x2c0582,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=m(_0x2c0582,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x200e14['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 _0x1d6537=this['fieldView']['element'];this['_tooltipString']=_0x1d6537['scrollWidth']>_0x1d6537['clientWidth']&&_0x1d6537['value']||'';}}class ti extends _0x376464{constructor(_0x1eccb,_0x5c303c,_0x43c1d6){super(_0x1eccb);const _0x2acd3c=new _0x2719fb();_0x2acd3c['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 _0x2fe993=['ck','ck-revision-history-sidebar__revision-author'];_0x43c1d6&&_0x2fe993['push']('ck-revision-history-sidebar__revision-author_creator');const _0x425121=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':m(_0x1eccb,_0x43c1d6?'Revision\x20creator':'Revision\x20author')},'children':[_0x2acd3c,_0x5c303c['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x2fe993},'children':_0x425121});}}function ni(_0x399b68,_0xc33545){const _0x3a9a9f=_0x399b68['bindTemplate'],_0x225b78=_0x399b68['locale'],_0x5441f1=_0x11399b(_0x225b78);_0x5441f1['panelPosition']='sw';const _0x5ce047=function(_0x36fc1e,_0x5f9841){const _0x367fec=function(_0x3444e0,_0x43a7f4){const _0x5d0d2f=_0x3444e0['locale'],_0xd059d5={'Compare\x20against\x20selected':m(_0x5d0d2f,'Compare\x20against\x20selected'),'Name\x20this\x20revision':m(_0x5d0d2f,'Name\x20this\x20revision'),'Restore\x20this\x20revision':m(_0x5d0d2f,'Restore\x20this\x20revision')};return _0x43a7f4['map'](_0x37fe67=>{const _0x577bfc=_0xd059d5[_0x37fe67['name']];return _0x577bfc&&_0x577bfc!==_0x37fe67['name']&&(_0x37fe67['name']=_0x577bfc),_0x37fe67;});}(_0x36fc1e,_0x5f9841),_0x571209=new _0x2ebcff();for(const _0x5da8ad of _0x367fec){const _0xbfa000={'type':'button','model':new to({'label':_0x5da8ad['name'],'class':_0x5da8ad['class'],'withText':!0x0,'role':'menuitem','_action':_0x5da8ad['action']})};_0xbfa000['model']['bind']('isEnabled')['to'](_0x36fc1e,'isActionsDropdownOpen',_0x5e31f0=>'function'!=typeof _0x5da8ad['isEnabled']||(!_0x5e31f0||_0x5da8ad['isEnabled'](_0x36fc1e))),_0x571209['add'](_0xbfa000);}return _0x571209;}(_0x399b68,_0xc33545);return _0x399b68['bind']('isActionsDropdownOpen')['to'](_0x5441f1,'isOpen'),_0x5441f1['buttonView']['set']({'label':m(_0x225b78,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x2a914a['threeVerticalDots']}),_0x5441f1['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x3a9a9f['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x3a9a9f['to'](_0x324aa8=>_0x324aa8['stopPropagation']())}}),_0x5441f1['on']('execute',_0x15ed76=>{_0x399b68['isReady']&&'function'==typeof _0x15ed76['source']['_action']&&_0x15ed76['source']['_action'](_0x399b68);}),_0x112459(_0x5441f1,_0x5ce047,{'role':'menu'}),_0x5441f1['listenTo'](_0x399b68,'change:isActionsDropdownOpen',(_0x192d01,_0x477061,_0x533ba9)=>{if(_0x533ba9)for(const _0x5c3a43 of _0x5441f1['listView']['items']){const _0x3e77d6=_0x5c3a43['children']['first'],_0x229594=_0xc33545['find'](_0x795cbe=>_0x795cbe['action']===_0x3e77d6['_action'])['isVisible'];_0x5c3a43['isVisible']=void 0x0===_0x229594||_0x229594(_0x399b68);}}),_0x5441f1;}class ai extends/* #__PURE__ -- @preserve */
|
|
26
|
+
_0x3eb80d(_0x376464){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x26bb7a,_0x67d3c3,_0x2d4985,_0x227d9f){super(_0x26bb7a);const _0x20e3ec=this['bindTemplate'],_0x33d243=function(_0x2a7989,_0x3ff5cf){const _0x456cde=Array['from'](_0x3ff5cf['authors'])['filter'](_0x55aff4=>_0x55aff4!=_0x3ff5cf['creator']);return _0x3ff5cf['creator']&&_0x456cde['unshift'](_0x3ff5cf['creator']),_0x456cde['map'](_0x53dc6f=>new ti(_0x2a7989,_0x53dc6f,_0x53dc6f==_0x3ff5cf['creator']));}(_0x26bb7a,_0x67d3c3);this['id']=_0x67d3c3['id'],this['_revision']=_0x67d3c3,this['_requireRevisionName']=_0x227d9f,this['bind']('name','createdAt')['to'](_0x67d3c3),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x44f2a0=>{return _0xb9516b=_0x26bb7a['uiLanguage'],(_0x2c3d13=_0x44f2a0)['toLocaleDateString'](_0xb9516b,{'month':'long','day':'numeric'})+',\x20'+_0x2c3d13['toLocaleTimeString'](_0xb9516b,{'hour':'numeric','minute':'numeric'});var _0xb9516b,_0x2c3d13;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new pt(_0x26bb7a,_0xcbfa91),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0xacd4a7=>_0xacd4a7||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x30e4f6,_0x4774f6)=>_0x30e4f6&&_0x4774f6),this['revisionActionsView']=_0x2d4985&&_0x2d4985['length']?ni(this,_0x2d4985):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x20e3ec['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x20e3ec['if']('isEnabled','ck-disabled',_0x4b3ba8=>!_0x4b3ba8),_0x20e3ec['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x20e3ec['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x20e3ec['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':_0x20e3ec['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':_0x33d243}]},this['revisionActionsView']],'on':{'click':_0x20e3ec['to'](_0x1153fd=>{_0x1153fd['srcElement']['closest']('.ck-thread__remove-confirm')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x1ce05c=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x1ce05c,'change',()=>{this['_requireRevisionName']&&!_0x1ce05c['value']||this['fire']('setName',{'id':this['id'],'name':_0x1ce05c['value']}),_0x1ce05c['value']||(_0x1ce05c['value']=this['name']?this['name']:this['_createdAtFormatted']);});}['select'](){this['isSelected']=!0x0;}['deselect'](){this['isSelected']=!0x1;}['highlight'](){this['isHighlighted']=!0x0;}['unhighlight'](){this['isHighlighted']=!0x1;}}function mi(_0x1e4ee5,_0xb4a7e){const _0x168cb2=_0x76f8d3['fromJSDate'](_0x1e4ee5)['setLocale'](_0xb4a7e),_0x2abea1=_0x76f8d3['local'](),_0x1f3883=_0x2abea1['minus']({'days':0x1})['startOf']('day');let _0x366774,_0x3b353a;return _0x168cb2['hasSame'](_0x2abea1,'day')?(_0x366774=_0x168cb2['startOf']('day')['toJSDate'](),_0x3b353a=_0x168cb2['toRelativeCalendar']()):_0x168cb2['hasSame'](_0x1f3883,'day')?(_0x366774=_0x1f3883['toJSDate'](),_0x3b353a=_0x168cb2['toRelativeCalendar']()):_0x168cb2['hasSame'](_0x2abea1,'week')?(_0x366774=_0x168cb2['startOf']('week')['toJSDate'](),_0x3b353a=_0x168cb2['weekdayLong']||''):_0x168cb2['hasSame'](_0x2abea1,'year')?(_0x366774=_0x168cb2['startOf']('month')['toJSDate'](),_0x3b353a=_0x168cb2['monthLong']||''):(_0x366774=_0x168cb2['startOf']('year')['toJSDate'](),_0x3b353a=String(_0x168cb2['year'])),{'startDate':_0x366774,'localizedPeriodName':_0x3b353a};}class vi extends _0x376464{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x3f7e96,_0x522bec,_0x43a665,_0x24e6a1){super(_0x3f7e96);const _0x521df9=mi(_0x522bec,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x522bec,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x43a665,this['_requireRevisionName']=_0x24e6a1,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':_0x521df9}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x1aae78){const _0x5b3c22=new ai(this['locale'],_0x1aae78,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x5b3c22);}['removeRevision'](_0x29e749){const _0x395eba=this['revisionViews']['find'](_0x3ae59e=>_0x3ae59e['id']===_0x29e749['id']);this['revisionViews']['remove'](_0x395eba);}}class as extends _0x376464{constructor(_0x46fadf){super(_0x46fadf);const _0x47dc22=new _0x2719fb();_0x47dc22['content']=_0x2a914a['history'],this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x47dc22,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[m(_0x46fadf,'Revision\x20history')]}]});}}class li extends _0x376464{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x50dc19,_0xd34c4c,_0x36834f,_0x2fe205){super(_0x50dc19);const _0x191946=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0xd34c4c,this['_revisionActions']=_0x36834f,this['_requireRevisionName']=_0x2fe205,this['on']('select',(_0x3ba2ef,_0x4a0719)=>{this['fire']('revisionSelected',_0x4a0719);}),this['on']('setName',(_0x307400,_0x39817d)=>{this['fire']('revisionSetName',_0x39817d);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new as(_0x50dc19),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x191946['if']('isEnabled','ck-disabled',_0x2d0e3f=>!_0x2d0e3f)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x55d840 of this['_revisions'])this['_addRevision'](_0x55d840);this['_revisions']['on']('add',(_0x4c456d,_0xfd286e)=>{this['_addRevision'](_0xfd286e);}),this['_revisions']['on']('remove',(_0x2c854e,_0x471998)=>{this['_removeRevision'](_0x471998);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x5f06f0=>_0x5f06f0['revisionViews']['map'](_0xccd806=>_0xccd806))['flat']();}['selectRevision'](_0x2b7983){for(const _0x891189 of this['revisionViews'])_0x2b7983&&_0x2b7983['id']===_0x891189['id']?_0x891189['select']():_0x891189['deselect']();}['highlightRevisions'](_0x58c696){for(const _0x1c269c of this['revisionViews'])_0x58c696['some'](({id:_0x213ee0})=>_0x213ee0===_0x1c269c['id'])?_0x1c269c['highlight']():_0x1c269c['unhighlight']();}['_addRevision'](_0x665aab){const _0x56efd0=mi(_0x665aab['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x478380=this['timePeriodViews']['get'](0x0);_0x478380&&_0x478380['startDate']['getTime']()===_0x56efd0['getTime']()||(_0x478380=new vi(this['locale'],_0x56efd0,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x478380)),_0x478380['addRevision'](_0x665aab);}['_removeRevision'](_0x9191a2){const _0x15b5ed=mi(_0x9191a2['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x15b5ed)['removeRevision'](_0x9191a2);}['_getTimePeriodViewByStartDate'](_0x2af58b){return this['timePeriodViews']['find'](_0x4b37e4=>_0x4b37e4['startDate']['getTime']()===_0x2af58b['getTime']());}}class w extends _0x361651{['_revisionViewer'];['_revisionsRepository'];['_sidebarView'];static ['defaultRevisionActions']=/* #__PURE__ -- @preserve */
|
|
27
27
|
((()=>['compareAgainstSelected','restoreRevision','nameRevision'])());static ['availableRevisionActions']=/* #__PURE__ -- @preserve */
|
|
28
|
-
bt();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[d];}constructor(
|
|
29
|
-
it(tt){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x7ac14a,_0x65130b){super(_0x65130b),this['sourceElement']=_0x7ac14a,this['model']['document']['createRoot']();const _0x45a36f=new et(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new rt(this,_0x45a36f);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x3bbcf3,_0x1c2eda){const _0x5f13f9=new this(_0x3bbcf3,_0x1c2eda);return await _0x5f13f9['initPlugins'](),await _0x5f13f9['ui']['init'](_0x3bbcf3),await _0x5f13f9['data']['init'](_0x5f13f9['config']['get']('initialData')||''),_0x5f13f9['fire']('ready'),_0x5f13f9;}}const p=['RevisionHistoryUI','RestrictedEditingMode'];class Rt extends _0xc00adc{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x522454){function _0x16d9c9(_0x285958){return _0x285958['map'](_0x40e865=>String['fromCharCode'](_0x40e865))['join']('');}super(_0x522454),this['result']='end',_0x522454[_0x16d9c9([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x16d9c9([0x76,0x69,0x65,0x77])][_0x16d9c9([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x16d9c9([0x61,0x75,0x74,0x6f]),_0x522454[_0x16d9c9([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x16d9c9([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x16d9c9([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x16d9c9([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x16d9c9([0x6f,0x6b])});}}class k extends _0xc00adc{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l,u];}constructor(_0x5b58d0){if(super(_0x5b58d0),!this['editor']['config']['get']('revisionHistory'))throw new _0x756e24('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x16da3a=>this['_showRevisionViewer']({..._0x16da3a,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0xf10c19=>this['_closeRevisionViewer'](_0xf10c19)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x49ad90=>this['_restoreRevision'](_0x49ad90)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x5d1a0f){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x5d1a0f;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x18ae84){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x18ae84);}['getRevision'](_0x178298){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x178298);}['getRevisions'](_0x308d00){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x308d00||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x396eb0=this['editor'],_0x21d814=_0x1396dd(_0x396eb0,p),_0x8c8bf1=_0x396eb0['plugins']['get']('RevisionTracker'),_0xa45614=_0x396eb0['plugins']['get']('Users')['users'];return _0x21d814['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x21d814['lazyRoots'],(_0x21d814['plugins']['push'](Rt,d,g,class extends _0xc00adc{static get['requires'](){return[d,'Users'];}['init'](){const _0x3cf30a=this['editor']['plugins']['get']('Users');for(const _0x31e44f of _0xa45614)_0x31e44f['isAnonymous']||_0x3cf30a['getUser'](_0x31e44f['id'])||_0x3cf30a['addUser'](_0x31e44f);const _0x2b0bbc=_0x8c8bf1['repository']['getRevisions']();let _0x1a5040=null;const _0x4baed0=this['editor']['plugins']['get']('RevisionViewer');_0x4baed0['adapter']=_0x8c8bf1['adapter'],_0x4baed0['bind']('isEnabled')['to'](_0x8c8bf1),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x396eb0,'isReadOnly',_0x5b7ddd=>!_0x5b7ddd);for(const _0x4db0c7 of _0x2b0bbc){const _0x3cfe57=null===_0x4db0c7['creator'];if(_0x3cfe57&&_0x4db0c7['toVersion']===_0x4db0c7['fromVersion'])continue;const _0x377d24=_0x4db0c7['toJSON']();_0x4baed0['addRevisionData'](_0x377d24,(_0x678e4f,_0x5063a9,_0xaca8e9)=>{if(_0x3cfe57){if(_0x1a5040)_0x1a5040['_update'](_0x678e4f,_0x5063a9);else{if(!_0x5063a9){const _0x1a6c71=_0xaca8e9['toJSON']();_0x1a6c71['id']=_0x49b9a1(),_0x8c8bf1['saveRevision'](_0x1a6c71,_0xaca8e9['toVersion'])['then'](_0x1162e6=>{_0x1a5040=_0x1162e6;});}}}else _0x4db0c7['_update'](_0x678e4f,_0x5063a9);});}}},w),_0x21d814);}['_enhanceShowRevisionViewerCallback'](){const _0x3e8da6=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x22250e=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x3aff12=this['editor']['plugins']['get']('Autosave');await _0x3aff12['save']();}else await _0x22250e['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x151f27=this['editor']['plugins']['get']('Dialog');_0x151f27['isOpen']&&_0x151f27['hide']();}const _0x6dbbb5=this['_getRevisionViewerEditorConfig']();return _0x3e8da6(_0x6dbbb5)['then'](_0x343de8=>{return(this['_viewerEditor']=_0x343de8,this['editor']['plugins']['has']('Annotations'))&&this['editor']['plugins']['get']('Annotations')['refreshVisibility'](),_0x343de8;})['catch'](_0x1bd655=>(console['error'](_0x1bd655),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x40bca6=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'](),_0x40bca6(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x26d412=this['editor']['plugins']['get']('Annotations');_0x26d412['refreshVisibility'](),_0x26d412['refreshPositioning']();}})));}['_showRevisionViewer'](_0x4d0fae){const _0x567817=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x3c73e7=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x527ae2=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return R['create'](_0x527ae2,_0x4d0fae)['then'](_0x58e25a=>(_0x3c73e7['style']['display']='block',_0x567817['style']['display']='none',_0x58e25a));}['_closeRevisionViewer'](_0x4b0753){const _0xff160c=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0xff160c['style']['display']='',_0x4b0753['destroy']();}async['_restoreRevision'](_0x19ed07){const _0x274224=this['editor'],_0x3e1f7a=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x2c3872=_0x274224['plugins']['get']('RevisionTracker'),_0xb82f44=_0x3e1f7a['repository']['getRevision'](_0x19ed07);let _0x530039,_0x1600a4,_0x1691e1;try{_0x530039=await _0x3e1f7a['getRevisionData'](_0xb82f44),_0x1600a4=await _0x3e1f7a['getRevisionRootsAttributes'](_0xb82f44);}catch(_0x5ec012){return void console['error'](_0x5ec012);}_0x274224['model']['change'](_0x51432d=>{for(const _0x3c3c82 of Array['from'](_0x274224['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x51432d['removeMarker'](_0x3c3c82);}),_0x3e1f7a['isReady']=!0x1,_0x274224['model']['enqueueChange'](_0x1c1fcd=>{_0x1c1fcd['setSelection'](null),_0x1c1fcd['removeSelectionAttribute'](_0x274224['model']['document']['selection']['getAttributeKeys']());const _0xa8a6f1=Object['keys'](_0x530039);for(const _0x249d99 of _0x274224['model']['document']['roots'])'$graveyard'!=_0x249d99['rootName']&&_0x249d99['isAttached']()&&!_0xa8a6f1['includes'](_0x249d99['rootName'])&&_0x1c1fcd['detachRoot'](_0x249d99);for(const _0x231008 of _0xa8a6f1){let _0x371c4c=_0x274224['model']['document']['getRoot'](_0x231008);_0x371c4c&&_0x371c4c['isAttached']()||(_0x371c4c=_0x1c1fcd['addRoot'](_0x231008));const _0x12c987=_0x1600a4[_0x231008],_0x3d4b91=Object['keys'](_0x12c987),_0x16632e=_0x530039[_0x231008];for(const _0x139600 of _0x371c4c['getAttributeKeys']())_0x3d4b91['includes'](_0x139600)||_0x1c1fcd['removeAttribute'](_0x139600,_0x371c4c);for(const _0x58d879 of _0x3d4b91)_0x1c1fcd['setAttribute'](_0x58d879,_0x1600a4[_0x231008][_0x58d879],_0x371c4c);_0x1c1fcd['remove'](_0x1c1fcd['createRangeIn'](_0x371c4c)),_0x1c1fcd['insert'](_0x274224['data']['parse'](_0x16632e,_0x371c4c),_0x371c4c,0x0);}});const _0x109729=m(_0x274224['locale'],'Restored');if(_0xb82f44['name'])_0x1691e1=-0x1==_0xb82f44['name']['indexOf'](_0x109729)?_0x109729+':\x20'+_0xb82f44['name']:_0xb82f44['name'];else _0x1691e1=_0x109729+':\x20'+(_0xb82f44['createdAt']['toLocaleDateString'](_0x274224['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0xb82f44['createdAt']['toLocaleTimeString'](_0x274224['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x2c3872['saveRevision']({'name':_0x1691e1}),_0x3e1f7a['isReady']=!0x0,_0x274224['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};
|
|
28
|
+
bt();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[d];}constructor(_0x242aca){super(_0x242aca),this['_revisionViewer']=_0x242aca['plugins']['get'](d),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x43bd0f=this['_revisionsRepository']['_revisions'],_0x1829a7=this['_createRevisionActions'](),_0x122af3=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new li(this['editor']['locale'],_0x43bd0f,_0x1829a7,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',(_0x18c977,_0x399a77)=>{_0x399a77['revisionViews']['on']('add',(_0x3884df,_0x310fd2)=>{_0x310fd2['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)),_0x122af3['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x1d052a=this['_revisionsRepository']['getRevision'](0x0);if(_0x1d052a){const _0x591098=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x1d052a['id']);this['_revisionViewer']['compare'](_0x1d052a,_0x591098);}}['_handleRevisionSelected'](_0x469229,_0x268017){const _0x539104=this['_revisionsRepository']['getRevision'](_0x268017['id']),_0x46a198=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x539104['id']);this['_revisionViewer']['compare'](_0x539104,_0x46a198);}['_handleRevisionSetName'](_0x45af89,_0x1332b3){this['_revisionsRepository']['getRevision'](_0x1332b3['id'])['setName'](_0x1332b3['name']);}['_handleDiffChange'](_0x14d492,_0x1cc0fe,_0x39649e){const _0x2d0ae5=this['_revisionsRepository']['getRevisionsInDiff'](_0x39649e);_0x2d0ae5['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x2d0ae5),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x2d0ae5[0x0]));}['_createRevisionActions'](){const _0x492a43=this['editor'],_0x58cb11=w['availableRevisionActions'],_0x1b70fd=_0x492a43['config']['get']('revisionHistory.revisionActions')||w['defaultRevisionActions'];if(_0x1b70fd['length'])return _0x1b70fd['map'](_0x35b673=>{const _0x589d26='string'==typeof _0x35b673?Object['assign']({},_0x58cb11[_0x35b673]):_0x35b673;return _0x589d26['action']=_0x589d26['action']['bind'](this,_0x492a43),_0x589d26['isVisible']&&(_0x589d26['isVisible']=_0x589d26['isVisible']['bind'](this,_0x492a43)),_0x589d26;});}}function bt(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x377225},_0x3471db)=>{const _0x31de85=_0x377225['get'](d),_0x5ae5b9=_0x31de85['repository'];let _0x3574ce=_0x31de85['diff']['newRevisionId'],_0x2992f9=_0x3471db['id'];_0x5ae5b9['getIndex'](_0x3574ce)>_0x5ae5b9['getIndex'](_0x2992f9)&&([_0x3574ce,_0x2992f9]=[_0x2992f9,_0x3574ce]),_0x31de85['compare'](_0x3574ce,_0x2992f9);},'isVisible':({plugins:_0x48c48c},_0x1e6ee0)=>{const _0x5f21b5=_0x48c48c['get'](d);return!(_0x5f21b5['repository']['getRevisionsInDiff'](_0x5f21b5['diff'])['length']>0x2)&&!_0x1e6ee0['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x44ddbc,{id:_0x7eed17})=>{_0x44ddbc['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x7eed17);},'isVisible':({plugins:_0x418523},_0x48a18b)=>!!_0x418523['get'](d)['repository']['getLaterVisibleRevision'](_0x48a18b['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x39f70e},{id:_0x5aadf4,revisionNameView:_0x24c750})=>{const _0xe678bb=_0x39f70e['get'](d),_0x3fa454=_0xe678bb['repository']['getEarlierVisibleRevision'](_0x5aadf4);_0xe678bb['compare'](_0x5aadf4,_0x3fa454),_0x24c750['focus'](),_0x24c750['fieldView']['select']();}}};}class rt extends st{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x57b9c5,_0x45b3d7){super(_0x57b9c5),this['_view']=_0x45b3d7,this['_toolbarConfig']=ot(_0x57b9c5['config']['get']('toolbar')),this['_elementReplacer']=new ht();}get['element'](){return this['view']['element'];}['init'](_0x3c373c){const _0x3872c0=this['editor'],_0xed281b=this['view'],_0x35bb77=_0x3872c0['editing']['view'],_0x521177=_0xed281b['editable'],_0x1193e7=_0x35bb77['document']['getRoot']();_0x521177['name']=_0x1193e7['rootName'],_0xed281b['render']();const _0x230392=_0x521177['element'];this['setEditableElement'](_0x521177['name'],_0x230392),_0xed281b['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x35bb77['attachDomRoot'](_0x230392),this['_elementReplacer']['replace'](_0x3c373c,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x30e6d5=this['view'],_0x17f3fd=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x17f3fd['detachDomRoot'](_0x30e6d5['editable']['name']),_0x30e6d5['destroy']();}['_initToolbar'](){const _0x116318=this['view'];_0x116318['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x116318['stickyPanel']['limiterElement']=_0x116318['element'],_0x116318['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x2f992c})=>_0x2f992c),_0x116318['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x116318['toolbar']);}}class et extends ct{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x343ddf,_0x28a5d9,_0x1e02ff={}){super(_0x343ddf),this['stickyPanel']=new ut(_0x343ddf),this['toolbar']=new lt(_0x343ddf,{'shouldGroupWhenFull':_0x1e02ff['shouldToolbarGroupWhenFull']}),this['_editable']=new dt(_0x343ddf,_0x28a5d9);}['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(_0x4bbab9,_0x509cb2){super(_0x509cb2),this['sourceElement']=_0x4bbab9,this['model']['document']['createRoot']();const _0xef5478=new et(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new rt(this,_0xef5478);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x477054,_0x4381e8){const _0x457881=new this(_0x477054,_0x4381e8);return await _0x457881['initPlugins'](),await _0x457881['ui']['init'](_0x477054),await _0x457881['data']['init'](_0x457881['config']['get']('initialData')||''),_0x457881['fire']('ready'),_0x457881;}}const p=['RevisionHistoryUI','RestrictedEditingMode'];class Rt extends _0x361651{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x976eda){function _0x3954ee(_0x54ffbe){return _0x54ffbe['map'](_0x225f42=>String['fromCharCode'](_0x225f42))['join']('');}super(_0x976eda),this['result']='end',_0x976eda[_0x3954ee([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x3954ee([0x76,0x69,0x65,0x77])][_0x3954ee([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x3954ee([0x61,0x75,0x74,0x6f]),_0x976eda[_0x3954ee([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x3954ee([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x3954ee([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x3954ee([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x3954ee([0x6f,0x6b])});}}class k extends _0x361651{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l,u];}constructor(_0x2d2967){if(super(_0x2d2967),!this['editor']['config']['get']('revisionHistory'))throw new _0x1cd261('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x40ece0=>this['_showRevisionViewer']({..._0x40ece0,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0xc5bd60=>this['_closeRevisionViewer'](_0xc5bd60)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x3be02c=>this['_restoreRevision'](_0x3be02c)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x2935c8){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x2935c8;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x1bce7e){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x1bce7e);}['getRevision'](_0x4a21cc){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x4a21cc);}['getRevisions'](_0x1d8368){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x1d8368||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x52bee8=this['editor'],_0x14b0a3=_0xc76ffb(_0x52bee8,p),_0x27759a=_0x52bee8['plugins']['get']('RevisionTracker'),_0x36e350=_0x52bee8['plugins']['get']('Users')['users'];return _0x14b0a3['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x14b0a3['lazyRoots'],(_0x14b0a3['plugins']['push'](Rt,d,g,class extends _0x361651{static get['requires'](){return[d,'Users'];}['init'](){const _0xe3a790=this['editor']['plugins']['get']('Users');for(const _0x524367 of _0x36e350)_0x524367['isAnonymous']||_0xe3a790['getUser'](_0x524367['id'])||_0xe3a790['addUser'](_0x524367);const _0x3a7505=_0x27759a['repository']['getRevisions']();let _0x3aa195=null;const _0x587d65=this['editor']['plugins']['get']('RevisionViewer');_0x587d65['adapter']=_0x27759a['adapter'],_0x587d65['bind']('isEnabled')['to'](_0x27759a),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x52bee8,'isReadOnly',_0x5b4369=>!_0x5b4369);for(const _0x2c495f of _0x3a7505){const _0x557bd0=null===_0x2c495f['creator'];if(_0x557bd0&&_0x2c495f['toVersion']===_0x2c495f['fromVersion'])continue;const _0x590a8e=_0x2c495f['toJSON']();_0x587d65['addRevisionData'](_0x590a8e,(_0x46b6c2,_0x70559c,_0x3f03ef)=>{if(_0x557bd0){if(_0x3aa195)_0x3aa195['_update'](_0x46b6c2,_0x70559c);else{if(!_0x70559c){const _0x5d0ec4=_0x3f03ef['toJSON']();_0x5d0ec4['id']=_0x52d906(),_0x27759a['saveRevision'](_0x5d0ec4,_0x3f03ef['toVersion'])['then'](_0x40ef63=>{_0x3aa195=_0x40ef63;});}}}else _0x2c495f['_update'](_0x46b6c2,_0x70559c);});}}},w),_0x14b0a3);}['_enhanceShowRevisionViewerCallback'](){const _0x393f1e=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x2ab61d=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x50f3e5=this['editor']['plugins']['get']('Autosave');await _0x50f3e5['save']();}else await _0x2ab61d['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x298b17=this['editor']['plugins']['get']('Dialog');_0x298b17['isOpen']&&_0x298b17['hide']();}const _0x3fbbef=this['_getRevisionViewerEditorConfig']();return _0x393f1e(_0x3fbbef)['then'](_0x231637=>{return(this['_viewerEditor']=_0x231637,this['editor']['plugins']['has']('Annotations'))&&this['editor']['plugins']['get']('Annotations')['refreshVisibility'](),_0x231637;})['catch'](_0x116ffc=>(console['error'](_0x116ffc),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x30d963=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'](),_0x30d963(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x21c773=this['editor']['plugins']['get']('Annotations');_0x21c773['refreshVisibility'](),_0x21c773['refreshPositioning']();}})));}['_showRevisionViewer'](_0x344ff3){const _0x3a82f1=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x2a4137=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x5b3b6a=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return R['create'](_0x5b3b6a,_0x344ff3)['then'](_0x4fd931=>(_0x2a4137['style']['display']='block',_0x3a82f1['style']['display']='none',_0x4fd931));}['_closeRevisionViewer'](_0x121bc6){const _0x2bc904=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x2bc904['style']['display']='',_0x121bc6['destroy']();}async['_restoreRevision'](_0x183742){const _0x49bbd7=this['editor'],_0x12c60d=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x51fa6d=_0x49bbd7['plugins']['get']('RevisionTracker'),_0x1e0f82=_0x12c60d['repository']['getRevision'](_0x183742);let _0x36b96b,_0x169d2a,_0x2f6a9d;try{_0x36b96b=await _0x12c60d['getRevisionData'](_0x1e0f82),_0x169d2a=await _0x12c60d['getRevisionRootsAttributes'](_0x1e0f82);}catch(_0x11f813){return void console['error'](_0x11f813);}_0x49bbd7['model']['change'](_0x22d01d=>{for(const _0x172311 of Array['from'](_0x49bbd7['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x22d01d['removeMarker'](_0x172311);}),_0x12c60d['isReady']=!0x1,_0x49bbd7['model']['enqueueChange'](_0x5dc8c4=>{_0x5dc8c4['setSelection'](null),_0x5dc8c4['removeSelectionAttribute'](_0x49bbd7['model']['document']['selection']['getAttributeKeys']());const _0x93da8c=Object['keys'](_0x36b96b);for(const _0x3612c9 of _0x49bbd7['model']['document']['roots'])'$graveyard'!=_0x3612c9['rootName']&&_0x3612c9['isAttached']()&&!_0x93da8c['includes'](_0x3612c9['rootName'])&&_0x5dc8c4['detachRoot'](_0x3612c9);for(const _0x130aee of _0x93da8c){let _0x52dbe7=_0x49bbd7['model']['document']['getRoot'](_0x130aee);_0x52dbe7&&_0x52dbe7['isAttached']()||(_0x52dbe7=_0x5dc8c4['addRoot'](_0x130aee));const _0x3154f6=_0x169d2a[_0x130aee],_0x2625f7=Object['keys'](_0x3154f6),_0x2cc418=_0x36b96b[_0x130aee];for(const _0xede685 of _0x52dbe7['getAttributeKeys']())_0x2625f7['includes'](_0xede685)||_0x5dc8c4['removeAttribute'](_0xede685,_0x52dbe7);for(const _0x3cd3a1 of _0x2625f7)_0x5dc8c4['setAttribute'](_0x3cd3a1,_0x169d2a[_0x130aee][_0x3cd3a1],_0x52dbe7);_0x5dc8c4['remove'](_0x5dc8c4['createRangeIn'](_0x52dbe7)),_0x5dc8c4['insert'](_0x49bbd7['data']['parse'](_0x2cc418,_0x52dbe7),_0x52dbe7,0x0);}});const _0x25cf65=m(_0x49bbd7['locale'],'Restored');if(_0x1e0f82['name'])_0x2f6a9d=-0x1==_0x1e0f82['name']['indexOf'](_0x25cf65)?_0x25cf65+':\x20'+_0x1e0f82['name']:_0x1e0f82['name'];else _0x2f6a9d=_0x25cf65+':\x20'+(_0x1e0f82['createdAt']['toLocaleDateString'](_0x49bbd7['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x1e0f82['createdAt']['toLocaleTimeString'](_0x49bbd7['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x51fa6d['saveRevision']({'name':_0x2f6a9d}),_0x12c60d['isReady']=!0x0,_0x49bbd7['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{a as Revision,k as RevisionHistory,u as RevisionHistoryUI,l as RevisionTracker,d as RevisionViewer,ae as RevisionViewerLoadingOverlay,g as RevisionViewerUI,j as RevisionsRepository,w as RevisionsSidebar};
|