@ckeditor/ckeditor5-revision-history 45.1.0-alpha.5 → 45.1.0-alpha.6
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/be.js +1 -1
- package/dist/translations/be.umd.js +1 -1
- package/dist/translations/bg.js +1 -1
- package/dist/translations/bg.umd.js +1 -1
- package/dist/translations/bn.js +1 -1
- package/dist/translations/bn.umd.js +1 -1
- package/dist/translations/bs.js +1 -1
- package/dist/translations/bs.umd.js +1 -1
- package/dist/translations/ca.js +1 -1
- package/dist/translations/ca.umd.js +1 -1
- package/dist/translations/cs.js +1 -1
- package/dist/translations/cs.umd.js +1 -1
- package/dist/translations/da.js +1 -1
- package/dist/translations/da.umd.js +1 -1
- package/dist/translations/de-ch.js +1 -1
- package/dist/translations/de-ch.umd.js +1 -1
- package/dist/translations/de.js +1 -1
- package/dist/translations/de.umd.js +1 -1
- package/dist/translations/el.js +1 -1
- package/dist/translations/el.umd.js +1 -1
- package/dist/translations/en-au.js +1 -1
- package/dist/translations/en-au.umd.js +1 -1
- package/dist/translations/en-gb.js +1 -1
- package/dist/translations/en-gb.umd.js +1 -1
- package/dist/translations/en.js +1 -1
- package/dist/translations/en.umd.js +1 -1
- package/dist/translations/eo.js +1 -1
- package/dist/translations/eo.umd.js +1 -1
- package/dist/translations/es-co.js +1 -1
- package/dist/translations/es-co.umd.js +1 -1
- package/dist/translations/es.js +1 -1
- package/dist/translations/es.umd.js +1 -1
- package/dist/translations/et.js +1 -1
- package/dist/translations/et.umd.js +1 -1
- package/dist/translations/eu.js +1 -1
- package/dist/translations/eu.umd.js +1 -1
- package/dist/translations/fa.js +1 -1
- package/dist/translations/fa.umd.js +1 -1
- package/dist/translations/fi.js +1 -1
- package/dist/translations/fi.umd.js +1 -1
- package/dist/translations/fr.js +1 -1
- package/dist/translations/fr.umd.js +1 -1
- package/dist/translations/gl.js +1 -1
- package/dist/translations/gl.umd.js +1 -1
- package/dist/translations/gu.js +1 -1
- package/dist/translations/gu.umd.js +1 -1
- package/dist/translations/he.js +1 -1
- package/dist/translations/he.umd.js +1 -1
- package/dist/translations/hi.js +1 -1
- package/dist/translations/hi.umd.js +1 -1
- package/dist/translations/hr.js +1 -1
- package/dist/translations/hr.umd.js +1 -1
- package/dist/translations/hu.js +1 -1
- package/dist/translations/hu.umd.js +1 -1
- package/dist/translations/hy.js +1 -1
- package/dist/translations/hy.umd.js +1 -1
- package/dist/translations/id.js +1 -1
- package/dist/translations/id.umd.js +1 -1
- package/dist/translations/it.js +1 -1
- package/dist/translations/it.umd.js +1 -1
- package/dist/translations/ja.js +1 -1
- package/dist/translations/ja.umd.js +1 -1
- package/dist/translations/jv.js +1 -1
- package/dist/translations/jv.umd.js +1 -1
- package/dist/translations/kk.js +1 -1
- package/dist/translations/kk.umd.js +1 -1
- package/dist/translations/km.js +1 -1
- package/dist/translations/km.umd.js +1 -1
- package/dist/translations/kn.js +1 -1
- package/dist/translations/kn.umd.js +1 -1
- package/dist/translations/ko.js +1 -1
- package/dist/translations/ko.umd.js +1 -1
- package/dist/translations/ku.js +1 -1
- package/dist/translations/ku.umd.js +1 -1
- package/dist/translations/lt.js +1 -1
- package/dist/translations/lt.umd.js +1 -1
- package/dist/translations/lv.js +1 -1
- package/dist/translations/lv.umd.js +1 -1
- package/dist/translations/ms.js +1 -1
- package/dist/translations/ms.umd.js +1 -1
- package/dist/translations/nb.js +1 -1
- package/dist/translations/nb.umd.js +1 -1
- package/dist/translations/ne.js +1 -1
- package/dist/translations/ne.umd.js +1 -1
- package/dist/translations/nl.js +1 -1
- package/dist/translations/nl.umd.js +1 -1
- package/dist/translations/no.js +1 -1
- package/dist/translations/no.umd.js +1 -1
- package/dist/translations/oc.js +1 -1
- package/dist/translations/oc.umd.js +1 -1
- package/dist/translations/pl.js +1 -1
- package/dist/translations/pl.umd.js +1 -1
- package/dist/translations/pt-br.js +1 -1
- package/dist/translations/pt-br.umd.js +1 -1
- package/dist/translations/pt.js +1 -1
- package/dist/translations/pt.umd.js +1 -1
- package/dist/translations/ro.js +1 -1
- package/dist/translations/ro.umd.js +1 -1
- package/dist/translations/ru.js +1 -1
- package/dist/translations/ru.umd.js +1 -1
- package/dist/translations/si.js +1 -1
- package/dist/translations/si.umd.js +1 -1
- package/dist/translations/sk.js +1 -1
- package/dist/translations/sk.umd.js +1 -1
- package/dist/translations/sl.js +1 -1
- package/dist/translations/sl.umd.js +1 -1
- package/dist/translations/sq.js +1 -1
- package/dist/translations/sq.umd.js +1 -1
- package/dist/translations/sr-latn.js +1 -1
- package/dist/translations/sr-latn.umd.js +1 -1
- package/dist/translations/sr.js +1 -1
- package/dist/translations/sr.umd.js +1 -1
- package/dist/translations/sv.js +1 -1
- package/dist/translations/sv.umd.js +1 -1
- package/dist/translations/th.js +1 -1
- package/dist/translations/th.umd.js +1 -1
- package/dist/translations/ti.js +1 -1
- package/dist/translations/ti.umd.js +1 -1
- package/dist/translations/tk.js +1 -1
- package/dist/translations/tk.umd.js +1 -1
- package/dist/translations/tr.js +1 -1
- package/dist/translations/tr.umd.js +1 -1
- package/dist/translations/tt.js +1 -1
- package/dist/translations/tt.umd.js +1 -1
- package/dist/translations/ug.js +1 -1
- package/dist/translations/ug.umd.js +1 -1
- package/dist/translations/uk.js +1 -1
- package/dist/translations/uk.umd.js +1 -1
- package/dist/translations/ur.js +1 -1
- package/dist/translations/ur.umd.js +1 -1
- package/dist/translations/uz.js +1 -1
- package/dist/translations/uz.umd.js +1 -1
- package/dist/translations/vi.js +1 -1
- package/dist/translations/vi.umd.js +1 -1
- package/dist/translations/zh-cn.js +1 -1
- package/dist/translations/zh-cn.umd.js +1 -1
- package/dist/translations/zh.js +1 -1
- package/dist/translations/zh.umd.js +1 -1
- package/package.json +11 -11
- package/src/changeitem.js +2 -2
- package/src/editor/revisionviewereditor.js +2 -2
- package/src/editor/revisionviewereditorui.js +1 -1
- package/src/editor/revisionviewereditoruiview.js +1 -1
- package/src/index.js +1 -1
- package/src/revision.js +2 -2
- package/src/revisiondiff.js +1 -1
- package/src/revisionhistory.js +1 -1
- package/src/revisionhistoryutils.js +1 -1
- package/src/revisionsrepository.js +1 -1
- package/src/revisiontracker.js +1 -1
- package/src/revisionviewer.js +1 -1
- package/src/ui/revision/createrevisionactionsdropdown.js +1 -1
- package/src/ui/revision/revisionauthorview.js +1 -1
- package/src/ui/revision/revisionnameview.js +1 -1
- package/src/ui/revision/revisionview.js +2 -2
- package/src/ui/revision/subrevisioncollapserview.js +1 -1
- package/src/ui/revision/subrevisionview.js +1 -1
- package/src/ui/revision/utils.js +1 -1
- package/src/ui/revisionhistory/revisionhistorysaverevisionformview.js +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
|
-
_0x11f117(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x408d45){super(),this['id']=_0x408d45['id']||_0x571ba5(),this['creator']=_0x408d45['creator']||null,this['authors']=_0x408d45['authors']||[],this['diffData']=_0x408d45['diffData']||null,this['toVersion']=_0x408d45['toVersion']||0x0,this['fromVersion']=_0x408d45['fromVersion']||0x0,this['set']('name',_0x408d45['name']||''),this['set']('createdAt',_0x408d45['createdAt']||new Date()),this['set']('attributes',_0x408d45['attributes']||{});}['setName'](_0xf6fbf7){this['_update']({'name':_0xf6fbf7});}['setAttribute'](_0xfe05b7,_0xd80ffd){const _0x4ac458=_0x503699(this['attributes']);_0x2bcce7(_0x4ac458,_0xfe05b7,_0xd80ffd),this['_update']({'attributes':_0x4ac458});}['removeAttribute'](_0x75282){const _0x2c20eb=_0x503699(this['attributes']);_0x1e57ba(_0x2c20eb,_0x75282),this['_update']({'attributes':_0x2c20eb});}['_update'](_0x1569d2,_0x1fa4b9=!0x1){let _0x25c99b=!0x1;const _0x58e708={'id':this['id']},_0x490b1c=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0xe5ae21 of _0x490b1c){const _0x2b530e=_0x1569d2[_0xe5ae21];void 0x0!==_0x2b530e&&_0x2b530e!==this[_0xe5ae21]&&(this[_0xe5ae21]=_0x2b530e,_0x58e708[_0xe5ae21]=_0x2b530e,_0x25c99b=!0x0);}_0x25c99b&&(_0x58e708['authors']&&(_0x58e708['authorsIds']=_0x58e708['authors']['map'](_0x1a6265=>_0x1a6265['id']),delete _0x58e708['authors']),this['fire']('_update',_0x58e708,_0x1fa4b9));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x28ffff=>_0x28ffff['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class I extends _0x527fd9{['_revisions'];static get['requires'](){return[_0x386857];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x31ce5b){super(_0x31ce5b),this['_revisions']=new _0x3f8e7a();}['afterInit'](){!async function(_0x4c6d4b){const _0x275c70=_0x371acd([0x6f,0x58,0x44,0x49,0x6d,0x70,0x4f,0x71,0x59,0x56,0x50,0x69,0x42,0x5a,0x4c,0x61,0x51,0x6b,0x55,0x45,0x77,0x54,0x75,0x65,0x30,0x68,0x79,0x66,0x73,0x43,0x33,0x78,0x48,0x37,0x6e,0x41,0x31,0x4b,0x76,0x74,0x7a,0x35,0x53,0x38,0x4d,0x64,0x62,0x32,0x57,0x72,0x34,0x47,0x6c,0x67,0x46,0x36,0x6a,0x39,0x52,0x4e,0x63,0x4a]),_0x148032=0xeb829,_0x23f593=0x74310026,_0x2c53b1=0x74366786^_0x23f593,_0x591bcc=window[_0x371acd([0x44,0x61,0x74,0x65])][_0x371acd([0x6e,0x6f,0x77])](),_0x4e8151=_0x4c6d4b[_0x371acd([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x41e0c0=new window[(_0x371acd([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x3ddf6f=>{_0x4e8151[_0x371acd([0x6f,0x6e,0x63,0x65])](_0x371acd([0x72,0x65,0x61,0x64,0x79]),_0x3ddf6f);}),_0x30b444={[_0x371acd([0x6b,0x74,0x79])]:_0x371acd([0x45,0x43]),[_0x371acd([0x75,0x73,0x65])]:_0x371acd([0x73,0x69,0x67]),[_0x371acd([0x63,0x72,0x76])]:_0x371acd([0x50,0x2d,0x32,0x35,0x36]),[_0x371acd([0x78])]:_0x371acd([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]),[_0x371acd([0x79])]:_0x371acd([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]),[_0x371acd([0x61,0x6c,0x67])]:_0x371acd([0x45,0x53,0x32,0x35,0x36])},_0x21271d=_0x4e8151[_0x371acd([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x371acd([0x67,0x65,0x74])](_0x371acd([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x3e512f(){let _0x11ad8d,_0x5d565f=null,_0x48989a=null;try{if(_0x21271d==_0x371acd([0x47,0x50,0x4c]))return _0x371acd([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x11ad8d=_0x5b5781(),!_0x11ad8d)return _0x371acd([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x11ad8d[_0x371acd([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x48989a=_0x431915(_0x11ad8d[_0x371acd([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x11ad8d[_0x371acd([0x6a,0x74,0x69])])),await _0x23a642()?_0x357e7a()?_0x40146d()?_0x371acd([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x111f6a()?(_0x11ad8d[_0x371acd([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x371acd([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x5d565f=_0x4066c1(_0x371acd([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x11ad8d[_0x371acd([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x371acd([0x74,0x72,0x69,0x61,0x6c])&&(_0x5d565f=_0x4066c1(_0x371acd([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x236632()):_0x371acd([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x371acd([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x371acd([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch(_0x129e8a){return _0x371acd([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x40146d(){const _0x44ccb3=[_0x371acd([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x371acd([0x74,0x72,0x69,0x61,0x6c])][_0x371acd([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x11ad8d[_0x371acd([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x591bcc/0x3e8:0xe10*_0x2c53b1;return _0x11ad8d[_0x371acd([0x65,0x78,0x70])]<_0x44ccb3;}function _0x357e7a(){const _0x34be3f=_0x11ad8d[_0x371acd([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x34be3f)return!0x1;if(_0x34be3f[_0x371acd([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x371acd([0x2a])))return!0x0;if(_0x34be3f[_0x371acd([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x371acd([0x52,0x48])))return!0x0;if(_0x34be3f[_0x371acd([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x371acd([0x52,0x52,0x48]))){if(_0x172e2f())return!0x0;if(_0xb05257()||_0x2f2051())return!0x0;}return!0x1;}function _0x111f6a(){const _0x23cea5=_0x11ad8d[_0x371acd([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x23cea5||0x0==_0x23cea5[_0x371acd([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x118d22}=new URL(window[_0x371acd([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x23cea5[_0x371acd([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x118d22))return!0x0;const _0x397b9e=_0x118d22[_0x371acd([0x73,0x70,0x6c,0x69,0x74])](_0x371acd([0x2e]));return _0x23cea5[_0x371acd([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x4b18f1=>_0x4b18f1[_0x371acd([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x371acd([0x2a])))[_0x371acd([0x6d,0x61,0x70])](_0x54b25e=>_0x54b25e[_0x371acd([0x73,0x70,0x6c,0x69,0x74])](_0x371acd([0x2e])))[_0x371acd([0x73,0x6f,0x6d,0x65])](_0x486200=>_0x397b9e[_0x371acd([0x65,0x76,0x65,0x72,0x79])]((_0x26d6bc,_0x156da6)=>_0x486200[_0x156da6]===_0x26d6bc||_0x486200[_0x156da6]===_0x371acd([0x2a])));}function _0x236632(){return _0x5d565f&&_0x48989a?new window[(_0x371acd([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x3fe3d4,_0x3a7078)=>{_0x5d565f[_0x371acd([0x74,0x68,0x65,0x6e])](_0x3fe3d4,_0x3a7078),_0x48989a[_0x371acd([0x74,0x68,0x65,0x6e])](_0x3d5484=>{_0x3d5484!=_0x371acd([0x56,0x61,0x6c,0x69,0x64])&&_0x3fe3d4(_0x3d5484);},_0x3a7078);}):_0x5d565f||_0x48989a||_0x371acd([0x56,0x61,0x6c,0x69,0x64]);}}function _0x431915(_0x52950c,_0x385b68){return new window[(_0x371acd([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x21a937=>{if(_0x533c81())return _0x21a937(_0x371acd([0x56,0x61,0x6c,0x69,0x64]));_0x5caa17(),_0x4e8151[_0x371acd([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x371acd([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x57522a=!0x1;const _0x2a4360=_0x571ba5();function _0x2e8e23(_0x2b334a){return!!_0x2b334a&&(typeof _0x2b334a===_0x371acd([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x2b334a===_0x371acd([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x2b334a[_0x371acd([0x74,0x68,0x65,0x6e])]===_0x371acd([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x2b334a[_0x371acd([0x63,0x61,0x74,0x63,0x68])]===_0x371acd([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x20f254(_0x5839f3){_0xc7964b(_0x5839f3)[_0x371acd([0x74,0x68,0x65,0x6e])](_0x5e2324=>{if(!_0x5e2324||_0x5e2324[_0x371acd([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x371acd([0x6f,0x6b]))return _0x371acd([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x452209(_0x3cb4bf(_0x2a4360+_0x385b68))!=_0x5e2324[_0x371acd([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x371acd([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x371acd([0x56,0x61,0x6c,0x69,0x64]);})[_0x371acd([0x74,0x68,0x65,0x6e])](_0x5519e6=>(_0x5505d7(),_0x5519e6),()=>{const _0x28e6a1=_0x15693f();return null==_0x28e6a1?(_0x5505d7(),_0x371acd([0x56,0x61,0x6c,0x69,0x64])):_0x371acd(_0x591bcc-_0x28e6a1>(0x503d8426^_0x23f593)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x371acd([0x74,0x68,0x65,0x6e])](_0x21a937)[_0x371acd([0x63,0x61,0x74,0x63,0x68])](()=>{_0x21a937(_0x371acd([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x1dfa89=0x7407eea6^_0x23f593;function _0x5505d7(){const _0x313a27=_0x371acd([0x6c,0x6c,0x63,0x74,0x2d])+_0x452209(_0x3cb4bf(_0x52950c)),_0x1e9b9d=_0x10cd24(_0x452209(window[_0x371acd([0x4d,0x61,0x74,0x68])][_0x371acd([0x63,0x65,0x69,0x6c])](_0x591bcc/_0x1dfa89)));window[_0x371acd([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x371acd([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x313a27,_0x1e9b9d);}function _0x15693f(){const _0xc448f2=_0x371acd([0x6c,0x6c,0x63,0x74,0x2d])+_0x452209(_0x3cb4bf(_0x52950c)),_0x3e84b1=window[_0x371acd([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x371acd([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0xc448f2);return _0x3e84b1?window[_0x371acd([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x10cd24(_0x3e84b1),0x10)*_0x1dfa89:null;}function _0xc7964b(_0x24d03e){return new window[(_0x371acd([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x44ad74,_0x3a4f6c)=>{_0x24d03e[_0x371acd([0x74,0x68,0x65,0x6e])](_0x44ad74,_0x3a4f6c),window[_0x371acd([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x3a4f6c,0x7430d4e6^_0x23f593);});}}_0x4e8151[_0x371acd([0x6f,0x6e])](_0x371acd([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x3c200d,_0x1dd4dc)=>{if(_0x1dd4dc[0x0]!=_0x52950c)return _0x21a937(_0x371acd([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x1dd4dc[0x1]={..._0x1dd4dc[0x1],[_0x371acd([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x2a4360};},{[_0x371acd([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x371acd([0x68,0x69,0x67,0x68])}),_0x4e8151[_0x371acd([0x6f,0x6e])](_0x371acd([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x4a44c1=>{_0x2e8e23(_0x4a44c1[_0x371acd([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x57522a=!0x0,_0x20f254(_0x4a44c1[_0x371acd([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x371acd([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x371acd([0x6c,0x6f,0x77])}),_0x41e0c0[_0x371acd([0x74,0x68,0x65,0x6e])](()=>{_0x57522a||_0x21a937(_0x371acd([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x533c81(){return _0x4e8151[_0x371acd([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x371acd([0x76,0x69,0x65,0x77])][_0x371acd([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x371acd([0x61,0x75,0x74,0x6f]);}function _0x5caa17(){_0x4e8151[_0x371acd([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x371acd([0x76,0x69,0x65,0x77])][_0x371acd([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x371acd([0x61,0x75,0x74,0x6f]);}}function _0x4066c1(_0x432961){const _0xd0cac9=[new window[(_0x371acd([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x438487=>setTimeout(_0x438487,0x74383eea^_0x23f593)),_0x41e0c0[_0x371acd([0x74,0x68,0x65,0x6e])](()=>new window[(_0x371acd([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x3822fd=>{const _0x20575e=0x74310021^_0x23f593,_0x15927a=_0x4c6d4b[_0x371acd([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x319c45(){_0x15927a[_0x371acd([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x20575e&&_0x3822fd();}_0x319c45(),_0x15927a[_0x371acd([0x6f,0x6e])](_0x371acd([0x61,0x64,0x64]),_0x319c45);})),new window[(_0x371acd([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2cd7bb=>{function _0x5dd09d(){for(const _0x469a07 in window)if(window[_0x371acd([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x371acd([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x469a07))&&window[_0x469a07]==_0x148032)return _0x2cd7bb();_0x4e8151[_0x371acd([0x73,0x74,0x61,0x74,0x65])]!=_0x371acd([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x371acd([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x5dd09d,0x743113ae^_0x23f593);}_0x43a36d(_0x371acd([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x5dd09d();})];return window[_0x371acd([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x371acd([0x72,0x61,0x63,0x65])](_0xd0cac9)[_0x371acd([0x74,0x68,0x65,0x6e])](()=>_0x432961);}async function _0x1cbf0f(){if(await _0x41e0c0,_0x43a36d(_0x371acd([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x2378a9=_0x4c6d4b[_0x371acd([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x13d73b=_0x4c6d4b[_0x371acd([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])](_0x2378a9[_0x371acd([0x69,0x64])]),_0x1c78b1=_0x3b1c42(_0x371acd([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x1c78b1[_0x371acd([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x2378a9['id'],_0x13d73b?_0x13d73b['id']:null,!0x0),_0x1c78b1[_0x371acd([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x371acd([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x1c78b1[_0x371acd([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x1c78b1[_0x371acd([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x57d93e,void(_0x1c78b1[_0x371acd([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x57d93e);}if(_0x43a36d(_0x371acd([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x4bdd5b=_0x3b1c42(_0x371acd([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x4bdd5b[_0x371acd([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x371acd([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x4bdd5b[_0x371acd([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x4bdd5b[_0x371acd([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x57d93e,_0x4bdd5b[_0x371acd([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x57d93e;}_0x4e8151[_0x371acd([0x6d,0x6f,0x64,0x65,0x6c])][_0x371acd([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x57d93e,_0x4e8151[_0x371acd([0x6d,0x6f,0x64,0x65,0x6c])][_0x371acd([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x57d93e,_0x4e8151[_0x371acd([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x371acd([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x172e2f(){return _0x43a36d(_0x371acd([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x3b1c42(_0x371acd([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x371acd([0x73,0x74,0x61,0x74,0x65])]==_0x371acd([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0xb05257(){return _0x43a36d(_0x371acd([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 _0x2f2051(){return _0x43a36d(_0x371acd([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x1fc88a(_0x569cae){const _0x37d17f=_0x49e22d();_0x4e8151[_0x37d17f]=_0x371acd([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])+_0x569cae,_0x569cae[_0x371acd([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x371acd([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x49e22d()]=_0x148032),_0x569cae!=_0x371acd([0x56,0x61,0x6c,0x69,0x64])&&_0x1cbf0f();}function _0x49e22d(){const _0x175cf9=window[_0x371acd([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x371acd([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x371acd([0x6e,0x6f,0x77])]())[_0x371acd([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x371acd([0x2e]),'');let _0x3573f1=_0x371acd([0x6f]);for(let _0x2fc839=0x0;_0x2fc839<_0x175cf9[_0x371acd([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x2fc839+=0x2){let _0x15cdc6=window[_0x371acd([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x175cf9[_0x371acd([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x2fc839,_0x2fc839+0x2));_0x15cdc6>=_0x275c70[_0x371acd([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x15cdc6-=_0x275c70[_0x371acd([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x3573f1+=_0x275c70[_0x15cdc6];}return _0x3573f1;}function _0x5b5781(){const _0x1ba081=_0x21271d[_0x371acd([0x73,0x70,0x6c,0x69,0x74])](_0x371acd([0x2e]));if(0x3!=_0x1ba081[_0x371acd([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x771669(_0x1ba081[0x1]);function _0x771669(_0x2e2c39){const _0x355817=_0x559308(_0x2e2c39);return _0x355817&&_0x54e42e()?_0x355817:null;function _0x54e42e(){const _0x501817=_0x355817[_0x371acd([0x6a,0x74,0x69])],_0x4b1f57=window[_0x371acd([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x501817[_0x371acd([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x501817[_0x371acd([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x3f3b78={..._0x355817,[_0x371acd([0x6a,0x74,0x69])]:_0x501817[_0x371acd([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x501817[_0x371acd([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x3f3b78[_0x371acd([0x76,0x63])],_0x3cb4bf(_0x3f3b78)==_0x4b1f57;}}}async function _0x23a642(){let _0x46b36e=!0x0;try{const _0x48cf51=_0x21271d[_0x371acd([0x73,0x70,0x6c,0x69,0x74])](_0x371acd([0x2e])),[_0x49ebd9,_0x3b2293,_0x33866d]=_0x48cf51;return _0x3e6858(_0x49ebd9),await _0x1abdcb(_0x49ebd9,_0x3b2293,_0x33866d),_0x46b36e;}catch(_0x4b7b2b){return!0x1;}function _0x3e6858(_0xb6949c){const _0x2f0a8d=_0x559308(_0xb6949c);_0x2f0a8d&&_0x2f0a8d[_0x371acd([0x61,0x6c,0x67])]==_0x371acd([0x45,0x53,0x32,0x35,0x36])||(_0x46b36e=!0x1);}async function _0x1abdcb(_0x3b9b34,_0xa6a0c1,_0x25b84a){const _0x2d0121=window[_0x371acd([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x371acd([0x66,0x72,0x6f,0x6d])](_0x6c7c96(_0x25b84a),_0x2b2a72=>_0x2b2a72[_0x371acd([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x397b71=new window[(_0x371acd([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x371acd([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x3b9b34+_0x371acd([0x2e])+_0xa6a0c1),_0xd0578b=window[_0x371acd([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x371acd([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0xd0578b)return;const _0x47e91d=await _0xd0578b[_0x371acd([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x371acd([0x6a,0x77,0x6b]),_0x30b444,{[_0x371acd([0x6e,0x61,0x6d,0x65])]:_0x371acd([0x45,0x43,0x44,0x53,0x41]),[_0x371acd([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x371acd([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x371acd([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0xd0578b[_0x371acd([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x371acd([0x6e,0x61,0x6d,0x65])]:_0x371acd([0x45,0x43,0x44,0x53,0x41]),[_0x371acd([0x68,0x61,0x73,0x68])]:{[_0x371acd([0x6e,0x61,0x6d,0x65])]:_0x371acd([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x47e91d,_0x2d0121,_0x397b71)||(_0x46b36e=!0x1);}}function _0x559308(_0xd12f45){return _0xd12f45[_0x371acd([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x371acd([0x65,0x79]))?JSON[_0x371acd([0x70,0x61,0x72,0x73,0x65])](_0x6c7c96(_0xd12f45)):null;}function _0x6c7c96(_0xae4422){return window[_0x371acd([0x61,0x74,0x6f,0x62])](_0xae4422[_0x371acd([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x371acd([0x2b]))[_0x371acd([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x371acd([0x2f])));}function _0x3cb4bf(_0x5083e1){let _0x3272a7=0x1505;function _0x58a10e(_0x2d58ce){for(let _0x110984=0x0;_0x110984<_0x2d58ce[_0x371acd([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x110984++){const _0x4c1530=_0x2d58ce[_0x371acd([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x110984);_0x3272a7=(_0x3272a7<<0x5)+_0x3272a7+_0x4c1530,_0x3272a7&=_0x3272a7;}}function _0x5642c6(_0x4201e9){Array[_0x371acd([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x4201e9)?_0x4201e9[_0x371acd([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x5642c6):_0x4201e9&&typeof _0x4201e9==_0x371acd([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x371acd([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x4201e9)[_0x371acd([0x73,0x6f,0x72,0x74])]()[_0x371acd([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x3129dd,_0x5f204a])=>{_0x58a10e(_0x3129dd),_0x5642c6(_0x5f204a);}):_0x58a10e(window[_0x371acd([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x4201e9));}return _0x5642c6(_0x5083e1),_0x3272a7>>>0x0;}function _0x452209(_0xd6d1a9){return _0xd6d1a9[_0x371acd([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x371acd([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x371acd([0x30]));}function _0x10cd24(_0x12dac8){return _0x12dac8[_0x371acd([0x73,0x70,0x6c,0x69,0x74])]('')[_0x371acd([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x371acd([0x6a,0x6f,0x69,0x6e])]('');}function _0x43a36d(_0x4aae98){return _0x4e8151[_0x371acd([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x371acd([0x68,0x61,0x73])](_0x4aae98);}function _0x3b1c42(_0x23a91a){return _0x4e8151[_0x371acd([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x371acd([0x67,0x65,0x74])](_0x23a91a);}function _0x57d93e(){}function _0x371acd(_0x285ae5){return _0x285ae5['map'](_0x373614=>String['fromCharCode'](_0x373614))['join']('');}_0x1fc88a(await _0x3e512f());}(this);}['createRevision'](_0x5c03c1){const _0x572a34=this['editor']['plugins']['get']('Users');return new h({'id':_0x5c03c1['id'],'name':_0x5c03c1['name'],'creator':_0x5c03c1['creatorId']?_0x572a34['getUser'](_0x5c03c1['creatorId']):null,'diffData':_0x5c03c1['diffData']||_0x5c03c1['data'],'authors':_0x5c03c1['authorsIds']['map'](_0x3aa779=>_0x572a34['getUser'](_0x3aa779)),'createdAt':new Date(_0x5c03c1['createdAt']),'attributes':_0x5c03c1['attributes'],'fromVersion':_0x5c03c1['fromVersion'],'toVersion':_0x5c03c1['toVersion']});}['addRevision'](_0x21335f,_0x74c996=0x0){this['_revisions']['add'](_0x21335f,_0x74c996);}['getRevision'](_0x2ae2fd){return this['_revisions']['get'](_0x2ae2fd);}['getRevisions'](_0x3d5396={'toJSON':!0x1}){const _0x426e6c=Array['from'](this['_revisions']);return _0x426e6c['reverse'](),_0x3d5396['toJSON']?_0x426e6c['map'](_0x4930d5=>_0x4930d5['toJSON']()):_0x426e6c;}['getIndex'](_0x41efe2){return this['_revisions']['getIndex'](_0x41efe2);}['getEarlierVisibleRevision'](_0x2ec4f7){const [,_0x5de7f0]=this['getRevisionsIterator'](_0x2ec4f7,{'direction':'earlier'});return _0x5de7f0;}['getLaterVisibleRevision'](_0x44e130){const [,_0x1af220]=this['getRevisionsIterator'](_0x44e130,{'direction':'later'});return _0x1af220;}['getRevisionsInDiff'](_0x1352fa){const _0x4af426=[];for(const _0x2c2fe9 of this['getRevisionsIterator'](_0x1352fa['newRevisionId']))if(_0x4af426['push'](_0x2c2fe9),_0x2c2fe9['id']===_0x1352fa['oldRevisionId'])break;return _0x4af426;}*['getRevisionsIterator'](_0x5d6e5b,{direction:_0x212603='earlier',filter:_0x3e9ae0=()=>!0x0}={}){const _0x3e8a0a='earlier'===_0x212603?0x1:-0x1;let _0x854c50=this['_revisions']['get'](_0x5d6e5b),_0x228c09=this['getIndex'](_0x854c50);for(yield _0x854c50;_0x854c50;){if(_0x228c09+=_0x3e8a0a,_0x854c50=this['getRevision'](_0x228c09),!_0x854c50)return;_0x3e9ae0(_0x854c50)&&(yield _0x854c50);}}}class V extends _0x527fd9{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x5942a7,'c'],[_0x49ccc4,'a'],[_0x409f3d,'e'],[_0x4d034c,'r'],[_0x20e593,'u']]);['_typeCharToViewClass']=new Map([['c',_0x5942a7],['a',_0x49ccc4],['e',_0x409f3d],['r',_0x4d034c],['u',_0x20e593]]);async['loadRevisionData'](_0x3aeb95,_0x5c4e77){if(_0x3aeb95['diffData']||!_0x5c4e77)return;const _0xac0a39=this['editor']['config']['get']('collaboration.channelId'),_0x36ba67=await _0x5c4e77['getRevision']({'channelId':_0xac0a39,'revisionId':_0x3aeb95['id']});_0x3aeb95['diffData']=_0x36ba67['diffData'];}['getRevisionDocumentData'](_0x10b2e9){const _0x4aae16={};for(const _0x4a6378 in _0x10b2e9['diffData']){if(_0x10b2e9['diffData'][_0x4a6378]['attachChange']&&!_0x10b2e9['diffData'][_0x4a6378]['attachChange']['isAttached'])continue;const _0x23184a=this['_removeRevisionMarkers'](JSON['parse'](_0x10b2e9['diffData'][_0x4a6378]['insertions'])),_0x5bbf91=this['editor']['editing']['view']['document'],_0x3bc2c0=new _0x2a3854(_0x5bbf91,_0x23184a['map'](_0x3d6a78=>this['_getViewFromDiffObj'](_0x3d6a78,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x4aae16[_0x4a6378]=this['editor']['data']['processor']['toData'](_0x3bc2c0),this['editor']['data']['processor']['useFillerType']('default');}return _0x4aae16;}['getRevisionRootsAttributes'](_0x406dba){const _0x31aca6={};for(const _0x33a023 in _0x406dba['diffData'])_0x406dba['diffData'][_0x33a023]['attachChange']&&!_0x406dba['diffData'][_0x33a023]['attachChange']['isAttached']||(_0x31aca6[_0x33a023]=_0x406dba['diffData'][_0x33a023]['attributesAfter']||{});return _0x31aca6;}['_getTypeCharForViewElement'](_0x5e124d){return this['_viewClassToTypeChar']['get'](_0x5e124d['constructor']);}['_getViewFromDiffObj'](_0x2f15f3,_0x44b356){const _0x52b9be=this['editor']['editing']['view']['document'];if('string'==typeof _0x2f15f3)return new _0x48de41(_0x52b9be,_0x2f15f3);{let _0x233b36,_0x3273ff;_0x3273ff='u'==_0x2f15f3['type']||'r'==_0x2f15f3['type']?[]:_0x2f15f3['children']['map'](_0x291fd9=>this['_getViewFromDiffObj'](_0x291fd9,_0x44b356));const _0x24bebf=this['_typeCharToViewClass']['get'](_0x2f15f3['type'])||_0x257259,_0x3bf825=this['editor']['data']['htmlProcessor']['domConverter'];if(_0x233b36=new _0x24bebf(_0x52b9be,_0x2f15f3['name'],_0x2f15f3['attributes'],_0x3273ff),'u'==_0x2f15f3['type']&&_0x2f15f3['children'][0x0]){const _0x24db8a=_0x2f15f3['children'][0x0];if(_0x233b36['render']=function(_0x1a66db){const _0x55f5c3=_0x1a66db['createElement']('div');return _0x55f5c3['innerHTML']=_0x24db8a,_0x55f5c3['childNodes'][0x0];},_0x44b356){const _0x518064=new _0x2a3854(_0x52b9be);_0x518064['_appendChild'](_0x233b36);const _0x3f04db=Array['from'](_0x3bf825['viewChildrenToDom'](_0x518064,{'bind':!0x1})),_0x192348=_0x3bf825['domDocument']['createElement']('div');_0x192348['append'](..._0x3f04db),_0x233b36=Array['from'](_0x3bf825['domChildrenToView'](_0x192348))[0x0];}}else{if('r'==_0x2f15f3['type']&&_0x2f15f3['children'][0x0]){const _0x50dcd0=_0x2f15f3['children'][0x0];if(_0x233b36['render']=function(_0x4224d8){_0x4224d8['innerHTML']=_0x50dcd0;},_0x44b356){const _0x1c1c08=new _0x2a3854(_0x52b9be);_0x1c1c08['_appendChild'](_0x233b36);const _0x496d30=Array['from'](_0x3bf825['viewChildrenToDom'](_0x1c1c08,{'bind':!0x1})),_0x118d21=_0x3bf825['domDocument']['createElement']('div');_0x118d21['append'](..._0x496d30);const _0x42cb02=Array['from'](_0x3bf825['domChildrenToView'](_0x118d21));_0x42cb02['length']>0x1?_0x233b36['_appendChild'](_0x42cb02):_0x233b36=_0x42cb02[0x0];}}}if(_0x2f15f3['customProperties']){for(const [_0x10bc91,_0x3595e6]of _0x2f15f3['customProperties'])_0x233b36['_setCustomProperty'](_0x10bc91,_0x3595e6);}const _0x4fc294=void 0x0===_0x2f15f3['fillerOffset']?null:_0x2f15f3['fillerOffset'];return null!==_0x4fc294&&(_0x233b36['getFillerOffset']=()=>_0x4fc294),_0x233b36;}}['_makeModelFromViewString'](_0x400915){const _0x1e96bc=JSON['parse'](_0x400915),_0x5c7efb=this['editor']['editing']['view']['document'],_0x540d07=new _0x2a3854(_0x5c7efb,_0x1e96bc['map'](_0x2d5fdc=>this['_getViewFromDiffObj'](_0x2d5fdc,!0x0)));return this['editor']['data']['toModel'](_0x540d07);}['_removeRevisionMarkers'](_0x4f50cb){return(_0x4f50cb=_0x4f50cb['filter'](_0x2f8a7d=>!_0x2f8a7d['name']||'revision-start'!==_0x2f8a7d['name']&&'revision-end'!==_0x2f8a7d['name']))['forEach'](_0x1c4f20=>{'string'!=typeof _0x1c4f20&&(_0x1c4f20['children']=this['_removeRevisionMarkers'](_0x1c4f20['children']),_0x1c4f20['attributes']=_0x1c4f20['attributes']['filter'](_0x50b40f=>!_0x50b40f[0x0]['startsWith']('data-revision-')));}),_0x4f50cb;}}function g(_0x4917e7,_0x22760b,_0x22c408){const t=_0x4917e7['t'];switch(_0x22760b){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'},_0x22c408);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x22c408);case'Show\x20previous\x20change':return t('Show\x20previous\x20change');case'Show\x20next\x20change':return t('Show\x20next\x20change');case'EDIT_X_OF_Y_REVISIONS':return t({'string':'Edit','id':'EDIT_X_OF_Y_REVISIONS'});case'Total':return t('Total');case'Revision\x20creator':return t('Revision\x20creator');case'Revision\x20author':return t('Revision\x20author');case'Revision\x20name':return t('Revision\x20name');case'Save\x20current\x20revision':return t('Save\x20current\x20revision');case'Accept':return t('Accept');case'Save':return t('Save');case'Cancel':return t('Cancel');case'Name\x20of\x20the\x20revision':return t('Name\x20of\x20the\x20revision');case'optional':return t('optional');case'PENDING_ACTION_REVISION_HISTORY':return t({'string':'Unsaved\x20change\x20in\x20revision\x20history.','id':'PENDING_ACTION_REVISION_HISTORY'});case'The\x20revision\x20name\x20cannot\x20be\x20empty.':return t('The\x20revision\x20name\x20cannot\x20be\x20empty.');case'Enter\x20the\x20revision\x20name':return t('Enter\x20the\x20revision\x20name');default:return'';}}class u extends _0x527fd9{['licenseKey'];['_licenseKeyCheckInterval'];['currentRevision']=null;['repository'];['adapter']=null;['_revisionDataBuilder'];['_source'];['_initialRevisionId'];['_bufferedUpdates'];['_utils'];['_pendingAction'];['_continueCurrentRevision'];['_startingVersion'];['_loadedStateData'];static get['pluginName'](){return'RevisionTracker';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[_0x386857,I,V,_0x3d46e5];}constructor(_0x2a6b48){super(_0x2a6b48),this['repository']=this['editor']['plugins']['get']('RevisionsRepository'),this['_utils']=this['editor']['plugins']['get']('RevisionHistoryUtils'),this['_revisionDataBuilder']=new x(this['editor']),this['_initialRevisionId']=this['editor']['config']['get']('collaboration.channelId')||'initial',this['_bufferedUpdates']=new Map(),this['_loadedStateData']=null;const _0x21e870=_0x571ba5();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x21e870},this['set']('isReady',!0x1),this['set']('isEnabled',!0x0),this['set']('_isPendingUpdate',!0x1),this['editor']['config']['define']('revisionHistory.resumeUnsavedRevision',!0x0),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'});}['init'](){this['_setConversion'](),this['editor']['data']['on']('ready',()=>{const _0x157f2b=this['repository']['getRevision'](0x0),_0x29dd66=_0x157f2b&&null===_0x157f2b['creator']?_0x157f2b:null;if(this['_continueCurrentRevision']=!!_0x29dd66&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x4c1059=this['_source']['getCurrentRevisionId'](),_0x31a70a=this['repository']['getRevision'](_0x4c1059);if(_0x31a70a)this['_startingVersion']=_0x31a70a['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x30a907=this['_source']['history']['_operations']['find'](_0x4741e1=>!_0x4741e1['_isInit']),_0x29ee48=_0x30a907?_0x30a907['baseVersion']:this['_source']['history']['version'];_0x157f2b?(_0x157f2b['toVersion']<_0x29ee48&&_0x157f2b['_update']({'toVersion':_0x29ee48}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x29dd66['id'],this['_startingVersion']=_0x29dd66['fromVersion']):(this['_startingVersion']=_0x157f2b['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x29ee48,this['_continueCurrentRevision']=!0x1);}}else _0x29dd66&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x29dd66['toVersion'],this['editor']['model']['document']['history']['version']),_0x29dd66['fromVersion']===_0x29dd66['toVersion']?(0x0!==_0x29dd66['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x29dd66['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x29dd66['id'],this['_startingVersion']=_0x29dd66['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',_0xfc4b36=>!_0xfc4b36),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x6584c0=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x227248;for(const _0x41eb56 in _0x6584c0){const _0x3cd98c=_0x41eb56,_0x46b09a=_0x6584c0[_0x3cd98c];if('revisionHistoryLicenseKeyValid'==_0x46b09a||'revisionHistoryLicenseKeyInvalid'==_0x46b09a||'revisionHistoryLicenseKeyExpired'==_0x46b09a||'revisionHistoryLicenseKeyDomainLimit'==_0x46b09a||'revisionHistoryLicenseKeyNotAllowed'==_0x46b09a||'revisionHistoryLicenseKeyEvaluationLimit'==_0x46b09a||'revisionHistoryLicenseKeyTrialLimit'==_0x46b09a||'revisionHistoryLicenseKeyUsageLimit'==_0x46b09a){delete _0x6584c0[_0x3cd98c],_0x227248=_0x46b09a,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x227248&&_0x6584c0['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x227248&&_0x6584c0['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x227248&&_0x6584c0['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x227248&&_0x6584c0['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x227248&&_0x6584c0['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x227248&&_0x6584c0['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x227248&&_0x6584c0['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x2dcea3=this['repository']['getRevision'](0x0),_0x45ca3e=await this['getRevisionDocumentData'](_0x2dcea3),_0x22e769=await this['getRevisionRootsAttributes'](_0x2dcea3);this['_replaceEditorDataWithRevisionData'](_0x45ca3e,_0x22e769);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0xe2ebc){this['_source']=_0xe2ebc;}async['update'](){const _0x57a85d=await this['_source']['getLatestVersion']();if(_0x57a85d>this['currentRevision']['toVersion']){await this['_loadState']();const _0x1edd1b=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x57a85d});_0x1edd1b['authors']=_0x1edd1b['authorsIds']['map'](_0x2ba4ac=>this['editor']['plugins']['get']('Users')['getUser'](_0x2ba4ac)),this['currentRevision']['_update'](_0x1edd1b);}}async['saveRevision'](_0x3493b0={},_0x33aac7=null){const _0x397d2c=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x33aac7>this['currentRevision']['toVersion']&&(_0x33aac7=null),null===_0x33aac7&&(_0x33aac7=await this['_source']['getLatestVersion']());const _0x58b93a=this['_getFromVersion'](_0x33aac7),_0x3d1981=this['buildRevisionData']({'from':_0x58b93a,'to':_0x33aac7});if(this['currentRevision']['toVersion']<_0x33aac7){const _0x52f280=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x33aac7,'to':_0x33aac7});_0x52f280['authors']=[],_0x52f280['authorsIds']=[],_0x52f280['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x52f280,!0x0),delete _0x52f280['authors'],_0x397d2c['push'](_0x52f280);}_0x3493b0['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x3493b0['name']=_0x3493b0['name']||null,_0x3493b0['id']=_0x3493b0['id']||_0x571ba5(),_0x3493b0={..._0x3493b0,..._0x3d1981};const _0x8c7929=this['addRevisionData'](_0x3493b0);_0x397d2c['push'](_0x3493b0);const _0x14e00b=this['repository']['getIndex'](_0x8c7929);if(0x0!==_0x14e00b){const _0x54a669=this['repository']['getRevision'](_0x14e00b-0x1);if(_0x54a669['fromVersion']!==_0x33aac7){const _0x2f4753=this['_revisionDataBuilder']['getData'](_0x33aac7,_0x54a669['toVersion']),_0x542573={'id':_0x54a669['id'],'diffData':_0x2f4753['diffData'],'authorsIds':_0x2f4753['authorsIds'],'authors':_0x2f4753['authorsIds']['map'](_0x4322aa=>this['editor']['plugins']['get']('Users')['getUser'](_0x4322aa)),'fromVersion':_0x33aac7};_0x54a669===this['currentRevision']&&(_0x542573['createdAt']=new Date(_0x3493b0['createdAt']['getTime']()+0xa)),_0x54a669['_update'](_0x542573,!0x0),delete _0x542573['authors'],_0x397d2c['push'](_0x542573);}}if(this['adapter']){for(const _0x2c6285 of _0x397d2c)this['_bufferUpdate'](_0x2c6285['id'],_0x2c6285,!0x0);this['sendBufferedUpdates']();}return _0x8c7929;}['addRevisionData'](_0x6f7716){const _0x3551be=this['repository']['createRevision'](_0x6f7716);return this['adapter']&&_0x3551be['on']('_update',(_0x1adbca,_0x3e7eb5,_0x5400d0)=>{_0x5400d0||(this['_bufferUpdate'](_0x3e7eb5['id'],_0x3e7eb5,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x3551be,this['_findInsertionIndex'](_0x3551be)),_0x3551be;}async['getRevisionDocumentData'](_0xe4c2fd){return await this['_utils']['loadRevisionData'](_0xe4c2fd,this['adapter']),this['_utils']['getRevisionDocumentData'](_0xe4c2fd);}async['getRevisionRootsAttributes'](_0x36d713){return await this['_utils']['loadRevisionData'](_0x36d713,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x36d713);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x1783eb=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0xb48b60=0x0;_0xb48b60<_0x1783eb['length'];_0xb48b60++){const _0x770c7a=_0x1783eb[_0xb48b60];let _0xd2a88=!0x1;for(const _0x2d1774 of Object['keys'](_0x770c7a))void 0x0===_0x770c7a[_0x2d1774]?delete _0x770c7a[_0x2d1774]:'id'!==_0x2d1774&&(_0xd2a88=!0x0);_0xd2a88||(_0x1783eb[_0xb48b60]=null);}if(_0x1783eb=_0x1783eb['filter'](_0xde170a=>null!==_0xde170a),!_0x1783eb['length'])return;for(let _0x2e7095=0x0;_0x2e7095<_0x1783eb['length'];_0x2e7095++){const _0x53508a=_0x1783eb[_0x2e7095];void 0x0!==_0x53508a['fromVersion']&&void 0x0===_0x53508a['toVersion']&&(_0x53508a['toVersion']=this['repository']['getRevision'](_0x53508a['id'])['toVersion']),void 0x0!==_0x53508a['toVersion']&&void 0x0===_0x53508a['fromVersion']&&(_0x53508a['fromVersion']=this['repository']['getRevision'](_0x53508a['id'])['fromVersion']);}const _0x3e231a=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x1783eb,_0x3e231a)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x3bc62a=>{if(_0x3bc62a){for(const _0x22bfdb of _0x3bc62a)this['setRevisionData']({'id':_0x22bfdb['id'],'createdAt':_0x22bfdb['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0x4a2a31=null,from:_0x4c5bd6=null,to:_0x8b62c8=null}){_0x4c5bd6=null!==_0x4c5bd6?_0x4c5bd6:_0x4a2a31['fromVersion'],_0x8b62c8=null!==_0x8b62c8?_0x8b62c8:_0x4a2a31['toVersion'];const _0x2cd34b=this['_revisionDataBuilder']['getData'](_0x4c5bd6,_0x8b62c8),_0x2a8c9a={'diffData':_0x2cd34b['diffData'],'authorsIds':_0x2cd34b['authorsIds'],'fromVersion':_0x4c5bd6,'toVersion':_0x8b62c8};if(!_0x4a2a31||_0x8b62c8!==_0x4a2a31['toVersion']){const _0x615994=_0x8b62c8-0x1,_0x4c08e8=this['_source']['history']['getOperation'](_0x615994);_0x2a8c9a['createdAt']=_0x4c08e8&&_0x4c08e8['createdAt']||new Date();}if(this['_loadedStateData']&&_0x4c5bd6===this['_loadedStateData']['fromVersion']){for(const _0x510bd0 of this['_loadedStateData']['authors'])_0x2a8c9a['authorsIds']['includes'](_0x510bd0['id'])||_0x2a8c9a['authorsIds']['push'](_0x510bd0['id']);}return _0x2a8c9a;}['_bufferUpdate'](_0x7e9a56,_0x27ab6f,_0x3b674d){if(this['_bufferedUpdates']['has'](_0x7e9a56)){const _0x372bf9=this['_bufferedUpdates']['get'](_0x7e9a56);_0x27ab6f=_0x3b674d?{..._0x372bf9,..._0x27ab6f}:{..._0x27ab6f,..._0x372bf9};}this['_bufferedUpdates']['set'](_0x7e9a56,_0x27ab6f);}['setRevisionData'](_0x1ec3b8){const _0x2d48dd=this['repository']['getRevision'](_0x1ec3b8['id']);if(_0x1ec3b8['createdAt']&&(_0x1ec3b8['createdAt']=new Date(_0x1ec3b8['createdAt'])),_0x1ec3b8['authorsIds']){const _0x228e4f=this['editor']['plugins']['get']('Users');_0x1ec3b8['authors']=_0x1ec3b8['authorsIds']['map'](_0x4cdfd3=>_0x228e4f['getUser'](_0x4cdfd3));}_0x2d48dd['_update'](_0x1ec3b8,!0x0);}['_createInitialRevision'](_0x18f10d){const _0x39e626=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x39e626)this['_initialRevisionId']=_0x39e626['id'];else{const _0x3d5c00=!this['editor']['model']['document']['roots']['find'](_0x1e0731=>this['editor']['model']['hasContent'](_0x1e0731)),_0x7e3dd7=this['editor']['plugins']['get']('Users')['me']['id'],_0x359e8a=g(this['editor']['locale'],_0x3d5c00?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x18f10d,'to':_0x18f10d,'id':this['_initialRevisionId'],'name':_0x359e8a,'creatorId':_0x7e3dd7});}}['_createCurrentRevision'](_0x5347f1){const _0x58adcc=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x58adcc),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x5347f1,'to':_0x5347f1,'id':_0x58adcc,'name':'','creatorId':null}));}async['_loadState'](){this['_continueCurrentRevision']&&!this['_loadedStateData']&&(await this['_utils']['loadRevisionData'](this['currentRevision'],this['adapter']),this['_revisionDataBuilder']['loadState'](this['currentRevision']),this['_loadedStateData']={'fromVersion':this['currentRevision']['fromVersion'],'authors':this['currentRevision']['authors']['slice']()});}['_replaceEditorDataWithRevisionData'](_0x49b57b,_0x199762){let _0x214b29=this['editor']['config']['get']('initialData'),_0x5e9787=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x214b29){_0x214b29={};for(const _0x47f412 of this['editor']['model']['document']['getRootNames']())_0x214b29[_0x47f412]='';}if('string'==typeof _0x214b29&&(_0x214b29={'main':_0x214b29}),void 0x0===_0x5e9787){_0x5e9787={};for(const _0x45bfaa of this['editor']['model']['document']['getRootNames']())_0x5e9787[_0x45bfaa]={};}let _0x4f7bc1=!0x1;const _0xeb1312=Object['keys'](_0x214b29),_0x1f9d52=Object['keys'](_0x49b57b);for(const _0x830ae8 of _0xeb1312){if(_0x214b29[_0x830ae8]!==_0x49b57b[_0x830ae8]&&''!==_0x214b29[_0x830ae8]['trim']()){_0x4f7bc1=!0x0;break;}if(!_0x3cd36b(_0x5e9787[_0x830ae8],_0x199762[_0x830ae8])&&Object['keys'](_0x5e9787[_0x830ae8])['length']>0x0){_0x4f7bc1=!0x0;break;}}_0x4f7bc1||(_0x4f7bc1=_0x1f9d52['some'](_0x18752f=>!this['editor']['model']['document']['getRoot'](_0x18752f))),_0x4f7bc1&&_0x39c6af('editor-initial-data-replaced-with-revision-data',{'editorData':_0x214b29,'editorRootsAttributes':_0x5e9787,'revisionData':_0x49b57b,'revisionRootsAttributes':_0x199762}),this['editor']['config']['set']('initialData',_0x49b57b),this['editor']['config']['set']('rootsAttributes',_0x199762);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x440bac=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x440bac['add'](g(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x2ec110){const _0x190ec8=this['repository']['getRevisions']();_0x190ec8['reverse']();let _0x2d22a7=0x0;for(;_0x2d22a7<_0x190ec8['length'];){const _0x14e7dc=_0x190ec8[_0x2d22a7];if(_0x14e7dc===this['currentRevision']){_0x2d22a7++;continue;}if(_0x14e7dc['id']===this['_initialRevisionId'])break;const _0x3bd044=_0x2ec110['toVersion']-_0x14e7dc['toVersion']||_0x2ec110['fromVersion']-_0x14e7dc['fromVersion'];if(_0x3bd044>0x0)break;if(_0x3bd044<0x0)_0x2d22a7++;else{if(!_0x2ec110['creator']&&_0x14e7dc['creator'])break;if(_0x14e7dc['creator']||!_0x2ec110['creator']){if(_0x2ec110['createdAt']>_0x14e7dc['createdAt'])break;_0x2d22a7++;}else _0x2d22a7++;}}return _0x2d22a7;}['_getFromVersion'](_0x378600){const _0x1106d7=this['repository']['getRevisions']();_0x1106d7['reverse'](),_0x1106d7['shift']();const _0x418666=_0x1106d7['find'](_0xce3534=>_0xce3534['toVersion']<=_0x378600)['toVersion'];return _0x418666<this['_startingVersion']?this['_startingVersion']:_0x418666;}['_makeRevision']({name:_0x1ea1e9,from:_0x1ccb30,to:_0x500fb1,creatorId:_0x17c560,id:_0x2e303c}){const _0x210f51=this['buildRevisionData']({'from':_0x1ccb30,'to':_0x500fb1});_0x210f51['name']=_0x1ea1e9,_0x210f51['creatorId']=_0x17c560,_0x210f51['id']=_0x2e303c;const _0x5e4b5a=this['addRevisionData'](_0x210f51);return this['adapter']&&this['_bufferUpdate'](_0x210f51['id'],_0x210f51,!0x0),_0x5e4b5a;}['_setConversion'](){this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'});}}class x{['editor'];['source'];['_savedMetaData'];['_lastFrom'];['_lastTo'];['_markers'];['_diffRoots'];['_diffRootsAttributes'];['_baseRoots'];['_baseRootsAttributes'];['_idsRoots'];['_baseIdsRoots'];['_touched'];['_touchedMarkers'];['_touchedRoots'];['_revisionId'];['_startingRevisionId'];constructor(_0x2ca331){this['editor']=_0x2ca331,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'](_0x1645bb){this['source']=_0x1645bb;const _0x3054af=new Map(),_0x4cedda=new Map(),_0x3e5e87=this['editor']['model']['document']['roots']['map'](_0x1e858d=>_0x1e858d['rootName']);for(const _0x1a3d2c of _0x3e5e87){const _0x20d70a=this['editor']['model']['document']['getRoot'](_0x1a3d2c),_0x7fa2e7=N(_0x20d70a);_0x3054af['set'](_0x1a3d2c,_0x7fa2e7),_0x4cedda['set'](_0x1a3d2c,Object['fromEntries'](_0x20d70a['getAttributes']()));}const _0x5dfdfc=Array['from'](this['editor']['model']['markers'])['map'](_0x179739=>[_0x179739['name'],_0x179739['getRange']()]),_0x4fc635=this['source']['version'];this['_saveMetaData'](_0x4fc635,_0x3054af,_0x5dfdfc,_0x4cedda),this['_startingRevisionId']=this['_revisionId'];const _0x17fcf3=new Map(),_0x327f22=new Map();for(const _0x216880 of _0x3e5e87){const _0x5aac02=P(_0x216880);_0x17fcf3['set'](_0x216880,_0x5aac02),_0x327f22['set'](_0x216880,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x17fcf3,[],_0x327f22);}['getData'](_0x581ac7,_0xd0821b){if(this['_lastFrom']===_0x581ac7&&this['_lastTo']<=_0xd0821b)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0xd0821b,!0x0);else{if(!this['_savedMetaData']['has'](_0x581ac7)){const _0x1fea35=this['_getPreviousFrom'](_0x581ac7);this['_calculateMetaData'](_0x1fea35,_0x581ac7,!0x1);}this['_calculateMetaData'](_0x581ac7,_0xd0821b,!0x0);}return this['_lastFrom']=_0x581ac7,this['_lastTo']=_0xd0821b,this['_getState']();}['loadState'](_0x2e9b86){const _0x2da9f3=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x2e9b86['fromVersion'],this['_lastTo']=_0x2e9b86['toVersion'];for(const _0x3a7156 in _0x2e9b86['diffData']){const _0xcaf1b6=_0x2e9b86['diffData'][_0x3a7156]['attachChange'],_0xb57cd4=_0x503699(_0x2e9b86['diffData'][_0x3a7156]['attributesBefore'])||{},_0x12688e=_0x2da9f3['_makeModelFromViewString'](_0x2e9b86['diffData'][_0x3a7156]['deletions']);_0x12688e['rootName']=_0x3a7156,_0x12688e['_isAttached']=!_0xcaf1b6||!_0xcaf1b6['isAttached'],_0x12688e['isAttached']=()=>_0x12688e['_isAttached'],this['_baseRoots']['set'](_0x3a7156,_0x12688e),this['_baseRootsAttributes']['set'](_0x3a7156,_0xb57cd4),_0xcaf1b6&&this['_touchedRoots']['set'](_0x3a7156,_0xcaf1b6);const _0x439802=this['_makeIdsRoot'](_0x12688e);this['_baseIdsRoots']['set'](_0x3a7156,_0x439802);for(const [_0x340f26,_0x66d8ad]of _0x12688e['markers']){if(!_0x340f26['startsWith']('revision:'))continue;const _0x592163=_0x340f26['split'](':')[0x2];for(const _0x241227 of _0x66d8ad['getWalker']({'singleCharacters':!0x0})){const _0x5e3e01=this['_getVidAttributeName'](_0x241227),_0x270b01='elementEnd'==_0x241227['type']?_0x241227['previousPosition']['path']['slice'](0x0,-0x1):_0x241227['previousPosition']['path'],_0x16c09a=_0x439802['getNodeByPath'](_0x270b01)['getAttribute'](_0x5e3e01);this['_touched']['set'](_0x16c09a,{'userId':_0x592163});}}}this['_startingRevisionId']=this['_revisionId'];const _0x48a19a=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x29c533=>!this['_touched']['has'](_0x29c533));let _0x140049=0x0;const _0x5cf1b0=new Map();for(const _0x156ef8 in _0x2e9b86['diffData']){const _0x2f3103=_0x2e9b86['diffData'][_0x156ef8]['attachChange'],_0x983bc4=_0x503699(_0x2e9b86['diffData'][_0x156ef8]['attributesAfter'])||{},_0x57bb25=_0x2da9f3['_makeModelFromViewString'](_0x2e9b86['diffData'][_0x156ef8]['insertions']);_0x57bb25['rootName']=_0x156ef8,_0x57bb25['_isAttached']=!_0x2f3103||_0x2f3103['isAttached'],_0x57bb25['isAttached']=()=>_0x57bb25['_isAttached'],this['_diffRoots']['set'](_0x156ef8,_0x57bb25),this['_diffRootsAttributes']['set'](_0x156ef8,_0x983bc4);const _0x247f0d=this['_makeIdsRoot'](_0x57bb25,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x156ef8,_0x247f0d),_0x5cf1b0['set'](_0x156ef8,_0x57bb25['isAttached']()?_0x983bc4:{});for(const [_0x44f326,_0x52d035]of _0x57bb25['markers']){if(!_0x44f326['startsWith']('revision:'))continue;const _0x5b0cbe=_0x44f326['split'](':')[0x2];for(const _0x545058 of _0x52d035['getWalker']({'singleCharacters':!0x0})){const _0x430116=this['_getVidAttributeName'](_0x545058),_0x286cf9=this['_revisionId']++,_0x37b0fb='elementEnd'==_0x545058['type']?_0x545058['previousPosition']['path']['slice'](0x0,-0x1):_0x545058['previousPosition']['path'];_0x247f0d['getNodeByPath'](_0x37b0fb)['_setAttribute'](_0x430116,_0x286cf9),this['_touched']['set'](_0x286cf9,{'userId':_0x5b0cbe});}}for(const _0x3d16d9 of this['editor']['model']['createRangeIn'](_0x57bb25)['getWalker']({'singleCharacters':!0x0})){const _0x4004ee=this['_getVidAttributeName'](_0x3d16d9),_0x2fae26='elementEnd'==_0x3d16d9['type']?_0x3d16d9['previousPosition']['path']['slice'](0x0,-0x1):_0x3d16d9['previousPosition']['path'],_0x234cf1=_0x247f0d['getNodeByPath'](_0x2fae26);_0x234cf1['getAttribute'](_0x4004ee)>0x0||_0x234cf1['_setAttribute'](_0x4004ee,_0x48a19a[_0x140049++]);}for(const [_0x28d46b,_0x5a4b01]of _0x57bb25['markers'])_0x28d46b['startsWith']('revision:')||this['_markers']['set'](_0x28d46b,_0x5a4b01);}const _0x1591a1=P('$graveyard');this['_baseRoots']['set']('$graveyard',_0x1591a1),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x1591a1,0x1));const _0x57cd79=P('$graveyard');this['_diffRoots']['set']('$graveyard',_0x57cd79),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x57cd79,0x1));const _0x10c2cf=Array['from'](this['_diffRoots'])['map'](([_0x3ffd21,_0x4c3ef6])=>[_0x3ffd21,N(_0x4c3ef6)]);this['_saveMetaData'](this['_lastTo'],_0x10c2cf,this['_markers'],_0x5cf1b0);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0x482aa0,_0x3a8ff9,_0x1eeed1,_0x5bdc42){const _0x3cad58=new Map(_0x3a8ff9),_0x4f2fc0=new Map(_0x503699(_0x5bdc42)),_0x482106=new Map();for(const [_0x3ecc23,_0x57d99f]of _0x1eeed1)_0x482106['set'](_0x3ecc23,{'start':_0x57d99f['start']['clone'](),'end':_0x57d99f['end']['clone'](),'rootName':_0x57d99f['root']['rootName']});this['_savedMetaData']['set'](_0x482aa0,{'roots':_0x3cad58,'markers':_0x482106,'rootsAttributes':_0x4f2fc0});}['_removeMetaData'](_0x372795){this['_savedMetaData']['delete'](_0x372795);}['_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'](_0x6e0fd0,_0x493ebd=null){let _0xd2cd14=null;_0x6e0fd0['is']('documentFragment')||(_0xd2cd14=new ut(_0x6e0fd0['name'],{'vid_start':null===_0x493ebd?this['_revisionId']++:_0x493ebd++}));const _0x2f5e9a=[];for(const _0x4dab57 of _0x6e0fd0['getChildren']())if(_0x4dab57['is']('element')){_0x2f5e9a['push'](this['_makeIdsRoot'](_0x4dab57,_0x493ebd));const _0x4512d6=_0x2f5e9a[_0x2f5e9a['length']-0x1];null!==_0x493ebd&&(_0x493ebd=_0x4512d6['is']('element','$text')?_0x4512d6['getAttribute']('vid')+0x1:_0x4512d6['getAttribute']('vid_end')+0x1);}else{for(let _0x24327f=0x0;_0x24327f<_0x4dab57['offsetSize'];_0x24327f++)_0x2f5e9a['push'](new ut('$text',{'vid':null===_0x493ebd?this['_revisionId']++:_0x493ebd++}));}if(_0x6e0fd0['is']('documentFragment')){const _0x413220=P(_0x6e0fd0['rootName']);return _0x413220['_insertChild'](0x0,_0x2f5e9a),_0x413220;}return _0xd2cd14['_setAttribute']('vid_end',null===_0x493ebd?this['_revisionId']++:_0x493ebd++),_0xd2cd14['_insertChild'](0x0,_0x2f5e9a),_0xd2cd14;}['_calculateMetaData'](_0x45b379,_0x14af63,_0x9e84ce){this['_reset']();const {roots:_0xf328f0,markers:_0x4e681a,rootsAttributes:_0x4b3531}=this['_savedMetaData']['get'](_0x45b379);this['_baseRoots']=new Map(_0xf328f0),this['_baseRootsAttributes']=new Map(_0x503699(_0x4b3531));for(const [_0x17d4ac,_0x4a019c]of this['_baseRoots'])if('$graveyard'!==_0x17d4ac&&(this['_diffRoots']['set'](_0x17d4ac,N(_0x4a019c)),this['_diffRootsAttributes']=new Map(_0x503699(_0x4b3531)),_0x9e84ce)){const _0x5507a8=this['_revisionId'];this['_idsRoots']['set'](_0x17d4ac,this['_makeIdsRoot'](_0x4a019c)),this['_baseIdsRoots']['set'](_0x17d4ac,this['_makeIdsRoot'](_0x4a019c,_0x5507a8));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',N(this['_baseRoots']['get']('$graveyard'))),_0x9e84ce&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x3d68b5,_0x3fb929]of _0x4e681a){const _0x129126=this['_baseRoots']['get'](_0x3fb929['rootName']),_0x29327e=this['_diffRoots']['get'](_0x3fb929['rootName']),_0x1ff541=new lt(this['_fixPosition'](_0x3fb929['start'],_0x129126),this['_fixPosition'](_0x3fb929['end'],_0x129126)),_0x3a6f2a=this['_fixRange'](_0x1ff541,_0x29327e);_0x129126['markers']['set'](_0x3d68b5,_0x1ff541),this['_markers']['set'](_0x3d68b5,_0x3a6f2a);}this['_applyOperations'](_0x45b379,_0x14af63,_0x9e84ce);}['_applyOperations'](_0x2b4f0a,_0x1e0beb,_0x2ff5be){for(const _0x4ec24c of this['source']['getOperations'](_0x2b4f0a,_0x1e0beb))this['_handleOperation'](_0x4ec24c,_0x2ff5be);for(const _0x2019ab of this['_diffRoots']['values']())_0x2019ab['markers']['clear']();for(const [_0x479fc7,_0x1de13f]of this['_markers']){this['_diffRoots']['get'](_0x1de13f['root']['rootName'])['markers']['set'](_0x479fc7,_0x1de13f['clone']());}const _0x38f8a7=new Map(),_0x14dd33=new Map();for(const [_0xa85956,_0x76851e]of this['_diffRoots'])_0x38f8a7['set'](_0xa85956,N(_0x76851e)),_0x14dd33['set'](_0xa85956,this['_diffRootsAttributes']['get'](_0xa85956));this['_saveMetaData'](_0x1e0beb,_0x38f8a7,this['_markers'],_0x14dd33);}['_getPreviousFrom'](_0xc13d9b){const _0x59df54=Array['from'](this['_savedMetaData']['keys']());_0x59df54['sort']((_0x3090ed,_0x3109c7)=>_0x3090ed-_0x3109c7),_0x59df54['reverse']();for(const _0x5493a3 of _0x59df54)if(_0x5493a3<_0xc13d9b)return _0x5493a3;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x5d0c8a,_0x582693){const _0x56015a=Array['from'](_0x582693['markers'])['map'](([_0x5d87de,_0x317851])=>[_0x5d87de,this['_fixRange'](_0x317851,_0x5d0c8a)]);_0x5d0c8a['markers']=new Map(_0x56015a);}['_transformMarkers'](_0x1f997f){for(const _0xc87d57 of this['_markers']['values']()){const _0x1c9e12=_0xc87d57['getTransformedByOperation'](_0x1f997f),_0x21c3b2=lt['_createFromRanges'](_0x1c9e12);_0xc87d57['start']=_0x21c3b2['start'],_0xc87d57['end']=_0x21c3b2['end'];}}['_handleOperation'](_0x3382ef,_0x4ab8e9){if('addRoot'!=_0x3382ef['type']&&'detachRoot'!=_0x3382ef['type']){if('insert'==_0x3382ef['type']){const _0x1464d2=_0x3382ef['position']['root']['rootName'];this['_diffRoots']['has'](_0x1464d2)||(this['_diffRoots']['set'](_0x1464d2,P(_0x1464d2,!0x0)),this['_diffRootsAttributes']['set'](_0x1464d2,{}),_0x4ab8e9&&this['_idsRoots']['set'](_0x1464d2,P(_0x1464d2,!0x0)));}else{if('addRootAttribute'==_0x3382ef['type']||'removeRootAttribute'==_0x3382ef['type']||'changeRootAttribute'==_0x3382ef['type'])return void this['_handleRootAttributeOperation'](_0x3382ef);'marker'==_0x3382ef['type']&&this['_handleMarkerOperation'](_0x3382ef);}if('marker'!==_0x3382ef['type']){const _0x4f6a26=this['_cloneOperation'](_0x3382ef,this['_diffRoots']);_0x4f6a26['_execute'](),this['_transformMarkers'](_0x4f6a26);}if(_0x4ab8e9)switch(_0x3382ef['type']){case'insert':this['_handleInsertOperation'](_0x3382ef);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x3382ef);break;case'merge':this['_handleMergeOperation'](_0x3382ef);break;case'split':this['_handleSplitOperation'](_0x3382ef);}}else this['_handleRootOperation'](_0x3382ef,_0x4ab8e9);}['_cloneOperation'](_0x117202,_0x40b1c6){const _0x5c1d89=_0x117202['clone']();return _0x5c1d89['_authorId']=_0x117202['_authorId'],this['_fixOperation'](_0x5c1d89,_0x40b1c6),_0x5c1d89;}['_getBaseVids'](_0x3d9dd9){return _0x3d9dd9['map'](_0x7a6b3=>{const _0x34b29d=this['_getVidAttributeName'](_0x7a6b3);return Number(_0x7a6b3['item']['getAttribute'](_0x34b29d));});}['_generateTape'](_0x4b04eb,_0x22b0c0){if(_0x4b04eb['is']('element','$text'))_0x22b0c0['push']({'item':_0x4b04eb,'type':'text'});else{_0x4b04eb['is']('element')&&_0x22b0c0['push']({'item':_0x4b04eb,'type':'elementStart'});for(const _0x3ed753 of _0x4b04eb['getChildren']())this['_generateTape'](_0x3ed753,_0x22b0c0);_0x4b04eb['is']('element')&&_0x22b0c0['push']({'item':_0x4b04eb,'type':'elementEnd'});}return _0x22b0c0;}['_getState'](){const _0x3e9ac0=new Map(this['_touched']),_0x5511bb=new Map(_0x3e9ac0),_0x14fe7e=new Map(),_0x402779={'insertions':{},'deletions':{}},_0x3f84ab={'insertions':{},'deletions':{}},_0x2c671e=new Map(),_0x21c775=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x21c775['delete']('$graveyard');for(const _0x19d4c6 of _0x21c775){const _0x263028=this['_diffRoots']['get'](_0x19d4c6)||P(_0x19d4c6,!0x1),_0x363621=this['_baseRoots']['get'](_0x19d4c6)||P(_0x19d4c6,!0x1);_0x263028['isAttached']()||_0x363621['isAttached']()?(_0x402779['insertions'][_0x19d4c6]=N(_0x263028),_0x402779['deletions'][_0x19d4c6]=N(_0x363621),this['_copyMarkers'](_0x402779['deletions'][_0x19d4c6],_0x363621),this['_copyMarkers'](_0x402779['insertions'][_0x19d4c6],_0x263028),_0x3f84ab['insertions'][_0x19d4c6]=this['_generateTape'](this['_idsRoots']['get'](_0x19d4c6),[]),_0x3f84ab['deletions'][_0x19d4c6]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x19d4c6)||P(_0x19d4c6,!0x1),[])):_0x21c775['delete'](_0x19d4c6);}for(const _0x1d93f2 of _0x21c775){const _0x2471e2=_0x3f84ab['insertions'][_0x1d93f2];for(const _0x5460f6 of _0x2471e2){const _0x551665=this['_getVidAttributeName'](_0x5460f6),_0x36edba=_0x5460f6['item']['getAttribute'](_0x551665);_0x5511bb['delete'](_0x36edba),_0x36edba>=this['_startingRevisionId']&&_0x14fe7e['set'](_0x36edba,_0x3e9ac0['get'](_0x36edba));}}for(const _0x4ac217 of _0x21c775){const _0x921fd2=_0x3f84ab['insertions'][_0x4ac217],_0x385e83=this['_getBaseVids'](_0x3f84ab['deletions'][_0x4ac217]);let _0xab8508=0x0;for(const _0x5e5e00 of _0x921fd2){const _0x461518=this['_getVidAttributeName'](_0x5e5e00),_0x3d1696=_0x5e5e00['item']['getAttribute'](_0x461518);if(!_0x14fe7e['has'](_0x3d1696)&&!_0x2c671e['has'](_0x3d1696)){if(_0x5511bb['has'](_0x3d1696))_0xab8508++;else{if(_0x3d1696!=_0x385e83[_0xab8508]){const _0x2f6e47=_0x3e9ac0['get'](_0x3d1696)||_0x3e9ac0['get'](_0x385e83[_0xab8508]);for(;_0x3d1696!=_0x385e83[_0xab8508];)_0x5511bb['has'](_0x385e83[_0xab8508])||(_0x2c671e['set'](_0x385e83[_0xab8508],_0x2f6e47),_0x3e9ac0['set'](_0x385e83[_0xab8508],_0x2f6e47)),_0xab8508++;}_0xab8508++;}}}}for(const _0x38a27c of _0x21c775){const _0x400157=_0x3f84ab['insertions'][_0x38a27c];for(const _0x183a6f of _0x400157){const _0x46dcec=this['_getVidAttributeName'](_0x183a6f),_0x19268a=_0x183a6f['item']['getAttribute'](_0x46dcec);if(_0x2c671e['has'](_0x19268a)){const _0xcdbae3=_0x2c671e['get'](_0x19268a);_0x5511bb['has'](_0x19268a)||_0x5511bb['set'](_0x19268a,{..._0xcdbae3}),_0x14fe7e['set'](_0x19268a,{..._0xcdbae3});}}}for(const _0x2fee6b of _0x5511bb['keys']())_0x2fee6b>=this['_startingRevisionId']&&_0x5511bb['delete'](_0x2fee6b);const _0x23aa80=new Map();for(const _0x2b3c80 of _0x21c775){let _0x2ec329=_0x3f84ab['insertions'][_0x2b3c80];for(const _0x158b43 of _0x2ec329)if(_0x158b43['item']['is']('element','tableCell')){const _0x258223=this['_getVidAttributeName'](_0x158b43),_0x1a3248=_0x158b43['item']['getAttribute'](_0x258223);if(_0x14fe7e['has'](_0x1a3248)){const _0x3b67d3=_0x158b43['item']['parent']['parent']['getAttribute']('vid_start'),_0x3447b4=_0x23aa80['get'](_0x3b67d3)||new Set();_0x3447b4['add'](_0x14fe7e['get'](_0x1a3248)['userId']),_0x23aa80['set'](_0x3b67d3,_0x3447b4);}}_0x2ec329=_0x3f84ab['deletions'][_0x2b3c80];for(const _0x1b9585 of _0x2ec329)if(_0x1b9585['item']['is']('element','tableCell')){const _0x1b1363=this['_getVidAttributeName'](_0x1b9585),_0x113cad=_0x1b9585['item']['getAttribute'](_0x1b1363);if(_0x5511bb['has'](_0x113cad)){const _0x51be68=_0x1b9585['item']['parent']['parent']['getAttribute']('vid_start'),_0x4aec15=_0x23aa80['get'](_0x51be68)||new Set();_0x4aec15['add'](_0x5511bb['get'](_0x113cad)['userId']),_0x23aa80['set'](_0x51be68,_0x4aec15);}}for(const _0xe425f7 of _0x23aa80['keys']())(_0x14fe7e['has'](_0xe425f7)||_0x5511bb['has'](_0xe425f7))&&_0x23aa80['delete'](_0xe425f7);}for(const _0x58c92f of _0x21c775){const _0x5a9d10=_0x3f84ab['insertions'][_0x58c92f];let _0x319528=null,_0x3f7675=null;for(const _0x104fb6 of _0x5a9d10){const _0x10a90f=this['_getVidAttributeName'](_0x104fb6),_0x641baf=_0x104fb6['item']['getAttribute'](_0x10a90f),_0x1a2008=_0x23aa80['get'](_0x641baf);_0x1a2008&&'elementStart'==_0x104fb6['type']&&(_0x319528=Array['from'](_0x1a2008)[0x0],_0x3f7675=_0x104fb6['item']['getAttribute']('vid_end')),_0x319528&&(_0x5511bb['set'](_0x641baf,{'userId':_0x319528}),_0x14fe7e['set'](_0x641baf,{'userId':_0x319528})),_0x641baf==_0x3f7675&&(_0x319528=null,_0x3f7675=null);}}const _0x348b54={},_0x3a92bd=new Set();for(const _0x4e1ac1 of _0x21c775){const _0x466893=_0x402779['deletions'][_0x4e1ac1],_0x5d9327=_0x402779['insertions'][_0x4e1ac1];for(const {userId:_0x4132e9}of this['_touchedMarkers']['values']())null!==_0x4132e9&&_0x3a92bd['add'](_0x4132e9);for(const {userId:_0x5263d4}of this['_touchedRoots']['values']())null!==_0x5263d4&&_0x3a92bd['add'](_0x5263d4);this['_markChanges'](_0x5d9327,_0x3f84ab['insertions'][_0x4e1ac1],_0x14fe7e,'insertion',_0x3a92bd),this['_markChanges'](_0x466893,_0x3f84ab['deletions'][_0x4e1ac1],_0x5511bb,'deletion',_0x3a92bd),_0x348b54[_0x4e1ac1]={'insertions':this['_prepareViewToSave'](_0x5d9327),'deletions':this['_prepareViewToSave'](_0x466893),'attachChange':this['_touchedRoots']['get'](_0x4e1ac1)||null,'attributesBefore':_0x503699(this['_baseRootsAttributes']['get'](_0x4e1ac1))||{},'attributesAfter':_0x503699(this['_diffRootsAttributes']['get'](_0x4e1ac1))};}return{'diffData':_0x348b54,'authorsIds':Array['from'](_0x3a92bd)};}['_processRootBeforeSave'](_0x257207){for(const [,_0x4e6c0a]of _0x257207['markers']){const _0x5e0656=_0x4e6c0a['start']['getAncestors']()['filter'](_0x162967=>'tableCell'==_0x162967['name']);for(const _0x28ceac of _0x5e0656)0x1==_0x28ceac['childCount']&&_0x28ceac['getChild'](0x0)['is']('element','paragraph')&&_0x28ceac['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x159fb7){this['_processRootBeforeSave'](_0x159fb7);const _0x37c62d=this['editor']['data']['toView'](_0x159fb7,{}),_0xfbad4f=Array['from'](_0x37c62d['getChildren']())['map'](_0x515960=>this['_getViewJson'](_0x515960));return JSON['stringify'](_0xfbad4f);}['_getViewJson'](_0xec7e43){if(_0xec7e43['is']('$text'))return _0xec7e43['data'];{const _0x15edab=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0x2ecf0c=_0xec7e43,_0x364721=this['editor']['data']['htmlProcessor']['domConverter'],_0x1ef8f8={'type':_0x15edab['_getTypeCharForViewElement'](_0x2ecf0c),'name':_0x2ecf0c['name'],'attributes':Array['from'](_0x2ecf0c['getAttributes']()),'children':Array['from'](_0x2ecf0c['getChildren']())['map'](_0x4d90d8=>this['_getViewJson'](_0x4d90d8))};if(_0xec7e43['is']('uiElement')&&'$comment'!=_0xec7e43['name']){const _0x2469ec=_0xec7e43['render'](_0x364721['domDocument'],_0x364721);_0x1ef8f8['children']['push'](_0x2469ec['outerHTML']);}else{if(_0xec7e43['is']('rawElement')){const _0x4d05ea=_0x364721['domDocument']['createElement'](_0x2ecf0c['name']);_0xec7e43['render'](_0x4d05ea,_0x364721),_0x1ef8f8['children']['push'](_0x4d05ea['innerHTML']);}}const _0x42d960=Array['from'](_0x2ecf0c['getCustomProperties']());_0x42d960['length']>0x0&&(_0x1ef8f8['customProperties']=_0x42d960);const _0x1ce9df=_0x2ecf0c['getFillerOffset']();return null!==_0x1ce9df&&(_0x1ef8f8['fillerOffset']=_0x1ce9df),_0x1ef8f8;}}['_markChanges'](_0x4f2b13,_0x2b1de4,_0x5c468a,_0x16c94c,_0x2bb321){let _0x52de19=null,_0x170b96=null,_0x2df86d=0x0;const _0x28bb43=this['editor']['model'];for(let _0x4290c2=0x0;_0x4290c2<_0x2b1de4['length'];_0x4290c2++){const _0x13cd8b=this['_getVidAttributeName'](_0x2b1de4[_0x4290c2]),_0x1ea9a4=_0x2b1de4[_0x4290c2]['item']['getAttribute'](_0x13cd8b),_0x290892=_0x5c468a['get'](_0x1ea9a4),_0xc52387=_0x4290c2==_0x2b1de4['length']-0x1;(!_0x52de19&&_0x290892&&(_0x52de19=_0x290892,_0x170b96=_0x2b1de4[_0x4290c2]),_0x52de19&&(!_0x290892||_0x290892['userId']!=_0x52de19['userId']))&&(_0x2120f4(_0x290892,F(_0x170b96,_0x4f2b13,_0x28bb43),F(_0x2b1de4[_0x4290c2],_0x4f2b13,_0x28bb43)),_0x52de19=_0x290892||null,_0x170b96=_0x290892?_0x2b1de4[_0x4290c2]:null),_0x52de19&&_0xc52387&&_0x2120f4(_0x290892,F(_0x170b96,_0x4f2b13,_0x28bb43),B(_0x2b1de4[_0x4290c2],_0x4f2b13,_0x28bb43));}function _0x2120f4(_0x46d2cd,_0x2593ce,_0x19ee85){const _0x495a4f=_0x52de19['userId'],_0x303314='revision:'+_0x16c94c+':'+_0x495a4f+':'+_0x2df86d++,_0xded9e8=_0x28bb43['createRange'](_0x2593ce,_0x19ee85);_0x4f2b13['markers']['set'](_0x303314,_0xded9e8),null!==_0x495a4f&&_0x2bb321['add'](_0x495a4f);}}['_getVidAttributeName'](_0x3b914f){switch(_0x3b914f['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x287c91,_0x2832bb){_0x287c91['baseVersion']=null;for(const _0x33fb5e in _0x287c91){const _0x1e27c6=_0x287c91[_0x33fb5e];if(_0x1e27c6 instanceof ft){const _0x3e4fb1=_0x2832bb['get'](_0x1e27c6['root']['rootName']);_0x287c91[_0x33fb5e]=this['_fixPosition'](_0x1e27c6,_0x3e4fb1);}if(_0x1e27c6 instanceof lt){const _0x4e54cf=_0x2832bb['get'](_0x1e27c6['root']['rootName']);_0x287c91[_0x33fb5e]=this['_fixRange'](_0x1e27c6,_0x4e54cf);}'root'===_0x33fb5e&&(_0x287c91['root']=_0x2832bb['get'](_0x287c91['root']['rootName']));}}['_fixRange'](_0x203400,_0x294a60){return this['editor']['model']['createRange'](this['_fixPosition'](_0x203400['start'],_0x294a60),this['_fixPosition'](_0x203400['end'],_0x294a60));}['_fixPosition'](_0x302a24,_0x56c3f1){return this['editor']['model']['createPositionFromPath'](_0x56c3f1,_0x302a24['path'],_0x302a24['stickiness']);}['_handleInsertOperation'](_0x786b99){const _0x3dfbd4=this['_idsRoots']['get'](_0x786b99['position']['root']['rootName']),_0x1b1b7e=this['_fixPosition'](_0x786b99['position'],_0x3dfbd4),_0x117ee7=null===_0x786b99['_authorId']?null:_0x786b99['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x35eac2=_0x1b1b7e['parent'],_0x27b3bd=this['_revisionId'],_0x279afa=[];for(const _0x478db8 of _0x786b99['nodes'])if(_0x478db8['is']('element'))_0x279afa['push'](this['_makeIdsRoot'](_0x478db8));else{for(let _0x3b5e54=0x0;_0x3b5e54<_0x478db8['offsetSize'];_0x3b5e54++)_0x279afa['push'](new ut('$text',{'vid':this['_revisionId']++}));}const _0x53bb97=this['_revisionId'];for(let _0xcfdeed=_0x27b3bd;_0xcfdeed<_0x53bb97;_0xcfdeed++)this['_touched']['set'](_0xcfdeed,{'userId':_0x117ee7});_0x35eac2['_insertChild'](_0x1b1b7e['offset'],_0x279afa);}['_handleMoveOperation'](_0x1da144){(_0x1da144=this['_cloneOperation'](_0x1da144,this['_idsRoots']))['_execute']();const _0x5b4921=null===_0x1da144['_authorId']?null:_0x1da144['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x2bddf2=_0x1da144['getMovedRangeStart'](),_0x3bc832=_0x2bddf2['parent'],_0x2c31bb=_0x2bddf2['offset'];!function _0x19dff1(_0x5cc820,_0x212a2d,_0x4f01db,_0x1f2d12){for(let _0x1a2814=_0x4f01db;_0x1a2814<_0x1f2d12;_0x1a2814++){const _0x31aab2=_0x212a2d['getChild'](_0x1a2814);_0x31aab2['is']('element','$text')?_0x5cc820['set'](_0x31aab2['getAttribute']('vid'),{'userId':_0x5b4921}):(_0x5cc820['set'](_0x31aab2['getAttribute']('vid_start'),{'userId':_0x5b4921}),_0x19dff1(_0x5cc820,_0x31aab2,0x0,_0x31aab2['childCount']),_0x5cc820['set'](_0x31aab2['getAttribute']('vid_end'),{'userId':_0x5b4921}));}}(this['_touched'],_0x3bc832,_0x2c31bb,_0x2c31bb+_0x1da144['howMany']);}['_handleMergeOperation'](_0x55ccc3){const _0x51a1a0=null===(_0x55ccc3=this['_cloneOperation'](_0x55ccc3,this['_idsRoots']))['_authorId']?null:_0x55ccc3['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x4c30c9=_0x55ccc3['targetPosition']['parent'],_0xb82a6e=_0x55ccc3['sourcePosition']['parent'],_0x4583b9=_0x4c30c9['getAttribute']('vid_end'),_0x11e8ff=_0xb82a6e['getAttribute']('vid_start');_0x4c30c9['_setAttribute']('vid_end',_0xb82a6e['getAttribute']('vid_end')),_0xb82a6e['_setAttribute']('vid_end',_0x4583b9),this['_touched']['set'](_0x11e8ff,{'userId':_0x51a1a0}),this['_touched']['set'](_0x4583b9,{'userId':_0x51a1a0}),_0x55ccc3['_execute']();}['_handleSplitOperation'](_0x26b862){const _0x5ca6ec=null===(_0x26b862=this['_cloneOperation'](_0x26b862,this['_idsRoots']))['_authorId']?null:_0x26b862['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x282d39=_0x26b862['graveyardPosition'],_0x221e14=_0x26b862['splitPosition']['parent'];_0x26b862['_execute']();const _0x41e470=_0x221e14['getAttribute']('vid_end'),_0x283e03=_0x26b862['insertionPosition']['nodeAfter'];if(_0x282d39){const _0x62956a=_0x283e03['getAttribute']('vid_end'),_0x8dcce5=_0x221e14['getAttribute']('vid_end');_0x221e14['_setAttribute']('vid_end',_0x62956a),_0x283e03['_setAttribute']('vid_end',_0x8dcce5),this['_touched']['set'](_0x221e14['getAttribute']('vid_end'),{'userId':_0x5ca6ec}),this['_touched']['set'](_0x283e03['getAttribute']('vid_start'),{'userId':_0x5ca6ec});}else{const _0x4c1862=this['_revisionId']++,_0x50299f=this['_revisionId']++;_0x221e14['_setAttribute']('vid_end',_0x4c1862),_0x283e03['_setAttribute']('vid_start',_0x50299f),_0x283e03['_setAttribute']('vid_end',_0x41e470),this['_touched']['set'](_0x4c1862,{'userId':_0x5ca6ec}),this['_touched']['set'](_0x50299f,{'userId':_0x5ca6ec});}}['_handleMarkerOperation'](_0x51c16c){if(!_0x51c16c['affectsData'])return;const _0x55fb07=(_0x51c16c=this['_cloneOperation'](_0x51c16c,this['_diffRoots']))['oldRange']?_0x51c16c['oldRange']['root']:null,_0x5212a7=_0x51c16c['newRange']?_0x51c16c['newRange']['root']:null;_0x55fb07&&this['_markers']['delete'](_0x51c16c['name']),_0x5212a7&&this['_markers']['set'](_0x51c16c['name'],_0x51c16c['newRange']['clone']());const _0x15f448=null===_0x51c16c['_authorId']?null:_0x51c16c['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x442e0a=_0x51c16c['name'];if(!this['_touchedMarkers']['has'](_0x442e0a))return void this['_touchedMarkers']['set'](_0x442e0a,{'range':_0x51c16c['oldRange'],'userId':_0x15f448});const _0x4483fb=this['_touchedMarkers']['get'](_0x442e0a),_0x13f00a=_0x4483fb['range'],_0x1214cf=_0x51c16c['newRange'];null==_0x13f00a&&null==_0x1214cf||_0x13f00a&&_0x1214cf&&_0x13f00a['isEqual'](_0x1214cf)?this['_touchedMarkers']['delete'](_0x51c16c['name']):_0x4483fb['userId']=_0x15f448;}['_handleRootOperation'](_0x525dd0,_0x1b2359){this['_diffRoots']['has'](_0x525dd0['rootName'])?this['_diffRoots']['get'](_0x525dd0['rootName'])['_isAttached']=_0x525dd0['isAdd']:(this['_diffRoots']['set'](_0x525dd0['rootName'],P(_0x525dd0['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x525dd0['rootName'],{}),_0x1b2359&&this['_idsRoots']['set'](_0x525dd0['rootName'],P(_0x525dd0['rootName'],!0x0)));const _0x1c8d48=null===_0x525dd0['_authorId']?null:_0x525dd0['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x1f3741=this['_touchedRoots']['get'](_0x525dd0['rootName']);_0x1f3741&&_0x1f3741['userId']===_0x1c8d48?this['_touchedRoots']['delete'](_0x525dd0['rootName']):this['_touchedRoots']['set'](_0x525dd0['rootName'],{'userId':_0x1c8d48,'isAttached':_0x525dd0['isAdd']});}['_handleRootAttributeOperation'](_0x207f05){const _0x1cd77a=this['_diffRootsAttributes']['get'](_0x207f05['root']['rootName']);null===_0x207f05['newValue']?delete _0x1cd77a[_0x207f05['key']]:_0x1cd77a[_0x207f05['key']]=_0x207f05['newValue'];}}function N(_0x26dcde){const _0x43fd28=P(_0x26dcde['rootName'],_0x26dcde['isAttached']());for(const _0xef7cc1 of _0x26dcde['getChildren']()){const _0x9ceddb=_0xef7cc1['_clone'](!0x0);_0x43fd28['_appendChild'](_0x9ceddb);}return _0x43fd28;}function P(_0x410093,_0x45d856=!0x0){const _0x521664=new vt();return _0x521664['rootName']=_0x410093,_0x521664['_isAttached']=_0x45d856,_0x521664['isAttached']=()=>_0x521664['_isAttached'],_0x521664;}function F(_0x2ca3a6,_0x21d78c,_0x16871a){const _0x57689a='elementEnd'==_0x2ca3a6['type']?_0x16871a['createPositionAt'](_0x2ca3a6['item'],'end'):_0x16871a['createPositionBefore'](_0x2ca3a6['item']);return _0x16871a['createPositionFromPath'](_0x21d78c,_0x57689a['path'],_0x57689a['stickiness']);}function B(_0xea1aaf,_0x529d1f,_0x58e4f8){const _0x1a7187='elementStart'==_0xea1aaf['type']?_0x58e4f8['createPositionAt'](_0xea1aaf['item'],0x0):_0x58e4f8['createPositionAfter'](_0xea1aaf['item']);return _0x58e4f8['createPositionFromPath'](_0x529d1f,_0x1a7187['path'],_0x1a7187['stickiness']);}class hs extends ts{['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x1ca0c2,_0x4541e5){super(_0x1ca0c2),this['focusTracker']=new _0x338ab8(),this['keystrokes']=new _0x143d1e(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x4541e5),this['setTemplate']({'tag':'form','attributes':{'class':['ck','ck-revision-history-save-revision-form','ck-responsive-form'],'tabindex':'-1'},'children':[this['revisionNameInputView']]}),_0x149bf4(this);}['render'](){super['render'](),_0x451b44({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x5a9473=_0x292e1b=>_0x292e1b['stopPropagation']();this['keystrokes']['set']('arrowright',_0x5a9473),this['keystrokes']['set']('arrowleft',_0x5a9473),this['keystrokes']['set']('arrowup',_0x5a9473),this['keystrokes']['set']('arrowdown',_0x5a9473);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x567d7a){this['revisionNameInputView']['fieldView']['element']['value']=_0x567d7a['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x34c37a){const _0x8213db=new _0x4a54d4(this['locale'],_0x37da91),_0x1a9223=_0x8213db['fieldView'];_0x1a9223['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x2c993c=g(this['locale'],'Name\x20of\x20the\x20revision');return!_0x34c37a&&(_0x2c993c+='\x20('+g(this['locale'],'optional')+')'),(_0x8213db['label']=_0x2c993c,_0x1a9223['on']('input',()=>{this['revisionNameInputValue']=_0x1a9223['element']['value']['trim']();}),_0x8213db);}}class f extends _0x527fd9{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u];}['_saveRevisionFormView'];['init'](){const _0x4ce05c=this['editor'],_0x554009=_0x4ce05c['plugins']['get']('RevisionTracker');_0x4ce05c['ui']['componentFactory']['add']('revisionHistory',_0x48d4d3=>{const _0x17220b=_0x2bb1f1(_0x48d4d3),_0x17ec5c=_0x17220b['panelView']['children'],_0x17c61f=new _0x28cadf(_0x48d4d3),_0x4a78d3=new _0x3bce81(_0x48d4d3),_0x2c1bcf=new te(_0x48d4d3),_0x272fdb=new _0x3bce81(_0x48d4d3),_0x4664e4=new te(_0x48d4d3);return _0x17220b['bind']('isEnabled')['to'](_0x554009,'isReady',_0x554009,'isEnabled',_0x4ce05c,'isReadOnly',(_0x451021,_0x2612f2,_0x262831)=>_0x451021&&_0x2612f2&&!_0x262831),_0x17220b['buttonView']['set']({'icon':_0x278e4f,'label':g(_0x48d4d3,'Revision\x20history'),'tooltip':!0x0}),_0x2c1bcf['set']({'label':g(_0x48d4d3,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x2c1bcf['bind']('isEnabled')['to'](_0x554009,'isReady',_0x554009,'isEnabled',_0x4ce05c,'isReadOnly',(_0x2909b3,_0x57f6e0,_0x56981c)=>_0x2909b3&&_0x57f6e0&&!_0x56981c),_0x2c1bcf['on']('execute',()=>this['_showDialog']()),_0x4664e4['set']({'label':g(_0x48d4d3,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x4664e4['bind']('isEnabled')['to'](_0x554009,'isReady',_0x4ce05c,'isReadOnly',(_0xbbb33,_0x327778)=>_0xbbb33&&!_0x327778),_0x4664e4['on']('execute',()=>{_0x4ce05c['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x17220b['isOpen']=!0x1,_0x4ce05c['editing']['view']['focus']();}),_0x4a78d3['children']['add'](_0x2c1bcf),_0x272fdb['children']['add'](_0x4664e4),_0x17c61f['role']='menu',_0x17c61f['items']['addMany']([_0x4a78d3,_0x272fdb]),_0x17ec5c['add'](_0x17c61f),_0x17220b;}),_0x4ce05c['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x513175=this['editor'],_0x5969a7=_0x513175['locale'],_0x24f03d=new _0x77737(_0x5969a7),_0xd574ec=new _0x4c1111(_0x5969a7);_0x24f03d['buttonView']['set']({'icon':_0x278e4f,'label':g(_0x5969a7,'Revision\x20history')});const _0x1bac82=new _0x94bb0e(_0x5969a7,_0x24f03d),_0x585fed=new _0x1308fb(_0x5969a7);_0x585fed['set']({'label':g(_0x5969a7,'Save\x20current\x20revision')}),_0x585fed['delegate']('execute')['to'](_0x24f03d),_0x585fed['on']('execute',()=>{this['_showDialog']();}),_0x1bac82['children']['add'](_0x585fed),_0xd574ec['items']['add'](_0x1bac82);const _0x522c98=new _0x94bb0e(_0x5969a7,_0x24f03d),_0x521d34=new _0x1308fb(_0x5969a7);return _0x521d34['set']({'label':g(_0x5969a7,'Open\x20revision\x20history')}),_0x521d34['delegate']('execute')['to'](_0x24f03d),_0x521d34['on']('execute',()=>{_0x513175['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x522c98['children']['add'](_0x521d34),_0xd574ec['items']['add'](_0x522c98),_0x24f03d['panelView']['children']['add'](_0xd574ec),_0x24f03d;}['_showDialog'](){const _0x5042e9=this['editor'],_0x1580d9=_0x5042e9['locale'],_0x1fa9b1=_0x5042e9['plugins']['get']('Dialog'),_0x53167c=_0x5042e9['plugins']['get']('RevisionTracker');function _0x3d0c96(_0x5bcf5b){_0x5042e9['config']['get']('revisionHistory.requireRevisionName')&&''===_0x5bcf5b['revisionName']?_0x5bcf5b['revisionNameInputView']['errorText']=g(_0x1580d9,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x5042e9['plugins']['get'](u)['saveRevision']({'name':_0x5bcf5b['revisionName']}),_0x1fa9b1['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x3d0c96(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x1fa9b1['show']({'id':'revisionSave','title':g(_0x1580d9,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':g(_0x5042e9['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x1fa9b1['hide']()},{'label':g(_0x5042e9['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x13aa57){_0x13aa57['bind']('isEnabled')['to'](_0x53167c,'isReady',_0x53167c,'isEnabled',_0x5042e9,'isReadOnly',(_0x4d5d57,_0x37d435,_0x14d916)=>_0x4d5d57&&_0x37d435&&!_0x14d916);},'onExecute':()=>_0x3d0c96(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x5519fd=this['editor'],_0x41dbc8=_0x5519fd['locale'];this['_saveRevisionFormView']=new hs(_0x41dbc8,_0x5519fd['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class Q extends ts{['changeId'];['_model'];constructor(_0x1cacb3,_0x3c05f4){super(_0x1cacb3),this['_model']=_0x3c05f4,this['changeId']=_0x3c05f4['id'];const _0x409b70=this['bindTemplate'],_0x47aa75=g(_0x1cacb3,_0x3c05f4['data']['isSuggestion']?'Suggested\x20by':'add'==_0x3c05f4['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x3c05f4['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x409b70['to']('type',_0x36f106=>'ck-revision-change__'+_0x36f106)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x47aa75}]},{'text':'\x20'+_0x3c05f4['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class r extends/* #__PURE__ -- @preserve */
|
|
25
|
-
_0x11f117(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x253aff){super(),this['id']=_0x253aff['id']||_0x571ba5(),this['author']=_0x253aff['author'],this['type']=_0x253aff['type'],this['data']=_0x253aff['data']||{},this['rootName']=_0x253aff['rootName'],this['set']('createdAt',_0x253aff['createdAt']);}['toJSON'](){return{'id':this['id'],'authorId':this['author']['id'],'type':this['type'],'data':this['data'],'createdAt':this['createdAt']};}}class c{['newRevisionId'];['oldRevisionId'];['changes'];constructor(_0x1a6ed2,_0x895860){this['newRevisionId']=_0x1a6ed2,this['oldRevisionId']=_0x895860,this['changes']=new _0x3f8e7a();}['_setChanges'](_0x3f39b2){for(const _0x2f0088 of _0x3f39b2)this['changes']['add'](_0x2f0088);}}class m extends _0x527fd9{['repository'];['adapter']=null;['_utils'];['_activeViewTarget'];['_changeView'];['_changeIdToChange'];['_balloon'];static get['pluginName'](){return'RevisionViewer';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[_0x386857,_0x3e17e6,I,V];}constructor(_0x1dd1c3){super(_0x1dd1c3),this['repository']=this['editor']['plugins']['get']('RevisionsRepository'),this['_utils']=this['editor']['plugins']['get']('RevisionHistoryUtils'),this['set']('activeChange',null),this['set']('activeView',null),this['_activeViewTarget']=null,this['set']('diff',null),this['set']('isReady',!0x1),this['set']('isEnabled',!0x0),this['on']('change:isEnabled',(_0x5becc3,_0x210ad7,_0x54e0e3)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x40460d=>{for(const _0x528ec0 of this['editor']['editing']['view']['document']['roots'])_0x54e0e3?_0x40460d['removeClass']('ck-editor__editable__overlay',_0x528ec0):_0x40460d['addClass']('ck-editor__editable__overlay',_0x528ec0);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x38ae94=>null!==_0x38ae94),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x57d97c,_0x224b26,_0x6af041)=>_0x57d97c&&_0x6af041?_0x224b26['changes']['getIndex'](_0x6af041):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x454e24,_0x122338)=>_0x454e24?_0x122338['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0x3e17e6);}['init'](){const _0x2c3997=this['editor'],_0x5a1920=new wt(_0x2c3997,{'direction':'backward'}),_0x519c02=new wt(_0x2c3997,{'direction':'forward'});(_0x2c3997['commands']['add']('showPreviousChange',_0x5a1920),_0x2c3997['commands']['add']('showNextChange',_0x519c02),_0x2c3997['commands']['add']('restoreRevision',new mt(_0x2c3997)),this['on']('change:numberOfChanges',()=>{_0x5a1920['refresh'](),_0x519c02['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x2c3997['enableReadOnlyMode']('revision-viewer'),_0x2c3997['plugins']['has']('WidgetToolbarRepository'))&&_0x2c3997['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x437f93){return await this['_utils']['loadRevisionData'](_0x437f93,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x437f93);}async['getRevisionRootsAttributes'](_0xba2e0b){return await this['_utils']['loadRevisionData'](_0xba2e0b,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0xba2e0b);}async['compare'](_0x4f86d7,_0x55b7ed,_0xf09334=!0x1){if(!this['isEnabled'])return;const _0x328380=this['diff'],_0x11f5af=this['repository'],_0x20a247='string'==typeof _0x4f86d7?_0x11f5af['getRevision'](_0x4f86d7):_0x4f86d7,_0x22a647='string'==typeof _0x55b7ed?_0x11f5af['getRevision'](_0x55b7ed):_0x55b7ed,_0xd878a6=_0x20a247['id'],_0x33bdbe=_0x22a647?_0x22a647['id']:null;if(!_0xf09334&&this['diff']&&this['diff']['newRevisionId']===_0xd878a6&&this['diff']['oldRevisionId']===_0x33bdbe)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new c(_0xd878a6,_0x33bdbe);const _0x1d9c29=this['_getRevisionsRange'](_0x20a247,_0x22a647,!0x0)['map'](_0xa4931f=>this['_utils']['loadRevisionData'](_0xa4931f,this['adapter']));return _0x1d9c29['push'](new Promise(_0x3c5f2d=>{setTimeout(_0x3c5f2d,0x14);})),Promise['all'](_0x1d9c29)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x31796e=this['_getDiff'](_0xd878a6,_0x33bdbe);for(const _0xc998c2 of _0x31796e['changes'])this['_changeIdToChange']['set'](_0xc998c2['id'],_0xc998c2);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x566424=>{for(const _0x346a1c of this['editor']['model']['document']['getRootNames']())_0x566424['detachRoot'](_0x346a1c);for(const _0x3164ab of Object['keys'](_0x31796e['model'])){const _0x203c40=_0x566424['addRoot'](_0x3164ab);for(const _0x43d868 of Object['keys'](_0x31796e['attributes'][_0x3164ab]))_0x566424['setAttribute'](_0x43d868,_0x31796e['attributes'][_0x3164ab][_0x43d868],_0x203c40);_0x566424['insert'](_0x31796e['model'][_0x3164ab],_0x203c40,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x31796e['changes'])),this['isReady']=!0x0;})['catch'](_0x283fbf=>{console['error'](_0x283fbf),this['_cleanUp'](),_0x328380&&(this['diff']=_0x328380),this['isReady']=!0x0;});}['addRevisionData'](_0x3aa9c4,_0x164fbb){const _0x47a7b1=this['repository']['createRevision'](_0x3aa9c4);return _0x47a7b1['on']('_update',(_0x228d10,_0x34f80b,_0x194101)=>_0x164fbb(_0x34f80b,_0x194101,_0x47a7b1)),this['repository']['addRevision'](_0x47a7b1),_0x47a7b1;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x124721=>{for(const _0x3fdf97 of this['editor']['model']['document']['getRootNames']())_0x124721['detachRoot'](_0x3fdf97);});}['_sortAndFilterDiffChanges'](_0x23e84){const _0x128e46=[],_0x4b101a=new Map();for(const _0x238495 of this['editor']['model']['document']['getRootNames']()){const _0x38b158=this['editor']['editing']['view']['getDomRoot'](_0x238495);if(!_0x38b158)continue;const _0x139342=_0x38b158['getClientRects']()['item'](0x0);_0x139342&&(_0x128e46['push'](_0x238495),_0x4b101a['set'](_0x238495,_0x139342));}return _0x128e46['sort']((_0x2deba7,_0x14431c)=>{const _0x53e630=_0x4b101a['get'](_0x2deba7),_0x1d2af1=_0x4b101a['get'](_0x14431c);return _0x53e630['y']-_0x1d2af1['y']||_0x53e630['x']-_0x1d2af1['x'];}),(_0x23e84=_0x23e84['filter'](_0x3cab61=>_0x128e46['includes'](_0x3cab61['rootName'])))['sort']((_0x1a805a,_0x2ce7b5)=>_0x128e46['indexOf'](_0x1a805a['rootName'])-_0x128e46['indexOf'](_0x2ce7b5['rootName'])),_0x23e84;}['_makeTape'](_0x3e9d4e){const _0x1daaa7=Array['from'](_0x3e9d4e['markers'])['filter'](([_0xa53cc4,_0x1a4de6])=>_0xa53cc4['startsWith']('revision:')&&!_0x1a4de6['isCollapsed']),_0x260c07=Array['from'](this['editor']['model']['createRangeIn'](_0x3e9d4e)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x1daaa7['length'])for(const _0x5becb3 of _0x260c07){const [_0x14b6bb,_0x544c2d]=_0x1daaa7[0x0],[,_0x30e500,_0xc58016]=_0x14b6bb['split'](':');if(_0x544c2d['end']['isEqual'](_0x5becb3['nextPosition'])&&_0x1daaa7['shift'](),(_0x5becb3['previousPosition']['isEqual'](_0x544c2d['start'])||_0x5becb3['previousPosition']['isAfter'](_0x544c2d['start']))&&('insertion'==_0x30e500?_0x5becb3['isAdded']={'userId':_0xc58016}:'deletion'==_0x30e500&&(_0x5becb3['isRemoved']={'userId':_0xc58016})),0x0==_0x1daaa7['length'])break;}return _0x260c07;}['_refreshStartEndIndex'](_0x5cf851){const _0x30e2c1=new Map();for(let _0x21adf4=0x0;_0x21adf4<_0x5cf851['length'];_0x21adf4++)'text'===_0x5cf851[_0x21adf4]['type']?(_0x5cf851[_0x21adf4]['item']['startIndex']=_0x21adf4,_0x5cf851[_0x21adf4]['item']['endIndex']=_0x21adf4):('elementStart'===_0x5cf851[_0x21adf4]['type']?_0x5cf851[_0x21adf4]['item']['startIndex']=_0x21adf4:'elementEnd'===_0x5cf851[_0x21adf4]['type']&&(_0x5cf851[_0x21adf4]['item']['endIndex']=_0x21adf4),_0x30e2c1['set'](_0x5cf851[_0x21adf4]['id'],_0x21adf4));for(const _0x422fdf of _0x30e2c1['values']())'elementStart'===_0x5cf851[_0x422fdf]['type']?_0x5cf851[_0x422fdf]['item']['endIndex']=_0x30e2c1['get'](_0x5cf851[_0x422fdf]['pairId']):'elementEnd'===_0x5cf851[_0x422fdf]['type']&&(_0x5cf851[_0x422fdf]['item']['startIndex']=_0x30e2c1['get'](_0x5cf851[_0x422fdf]['pairId']));}['_processTape'](_0xc090ec){for(let _0xa8889c=0x0;_0xa8889c<_0xc090ec['length'];_0xa8889c++){if('elementStart'===_0xc090ec[_0xa8889c]['type'])_0xc090ec[_0xa8889c]['item']['startIndex']=_0xa8889c;else{if('elementEnd'===_0xc090ec[_0xa8889c]['type']){_0xc090ec[_0xa8889c]['item']['endIndex']=_0xa8889c;const _0x39ef01=_0xc090ec[_0xa8889c]['item']['startIndex'];_0xc090ec[_0x39ef01]['pairId']=_0xc090ec[_0xa8889c]['id'],_0xc090ec[_0xa8889c]['pairId']=_0xc090ec[_0x39ef01]['id'];}else _0xc090ec[_0xa8889c]['item']['startIndex']=_0xa8889c,_0xc090ec[_0xa8889c]['item']['endIndex']=_0xa8889c,_0xc090ec[_0xa8889c]['pairId']=null;}_0xc090ec[_0xa8889c]['markersStart']||(_0xc090ec[_0xa8889c]['markersStart']=[],_0xc090ec[_0xa8889c]['markersEnd']=[]);}}['_markInsertions'](_0x3f7fd9,_0x495c69){const _0x1e92ad=_0x3f7fd9['filter'](_0x41b05e=>!_0x41b05e['isAdded']);for(let _0x5a3b56=0x0;_0x5a3b56<_0x495c69['length'];_0x5a3b56++)_0x495c69[_0x5a3b56]['isAdded']&&(_0x1e92ad[_0x5a3b56]['isAdded']=_0x495c69[_0x5a3b56]['isAdded']);}['_getDiff'](_0x75545d,_0x5ef397=null){const _0x4558cb=this['repository']['getRevision'](_0x75545d),_0x546ea9=_0x5ef397?this['repository']['getRevision'](_0x5ef397):null,_0x4f98a8=this['_getRevisionsRange'](_0x4558cb,_0x546ea9),_0x3eeac5=_0x4f98a8[_0x4f98a8['length']-0x1],_0x59af94=new Map(),_0x287e29={'model':{},'attributes':{},'changes':[]},_0x4ec825=new Set(),_0x8af27d=new Map();for(let _0x1a2d33=_0x4f98a8['length']-0x1;_0x1a2d33>=0x0;_0x1a2d33--){const _0x2933b8=_0x4f98a8[_0x1a2d33];for(const _0x1d3762 of Object['keys'](_0x2933b8['diffData']))if(_0x2933b8['diffData'][_0x1d3762]['attachChange']){const _0x288a47=_0x2933b8['diffData'][_0x1d3762]['attachChange'];_0x288a47['isAttached']?(_0x4ec825['add'](_0x1d3762),_0x8af27d['has'](_0x1d3762)&&_0x8af27d['get'](_0x1d3762)['userId']==_0x288a47['userId']?_0x8af27d['delete'](_0x1d3762):_0x8af27d['set'](_0x1d3762,_0x288a47)):_0x8af27d['has'](_0x1d3762)?(_0x4ec825['delete'](_0x1d3762),_0x8af27d['delete'](_0x1d3762)):(_0x4ec825['add'](_0x1d3762),_0x8af27d['set'](_0x1d3762,_0x288a47));}else _0x4ec825['add'](_0x1d3762);}for(const _0x5c972a of _0x4ec825){const _0x4fb16c=_0x8af27d['has'](_0x5c972a)&&!_0x8af27d['get'](_0x5c972a)['isAttached'];let _0x330ad9=_0x4fb16c?_0x4f98a8['length']-0x1:0x0;const _0x116570=_0x4fb16c?-0x1:0x1;for(;_0x4f98a8[_0x330ad9];){const _0x402781=_0x4f98a8[_0x330ad9];if(_0x402781['diffData'][_0x5c972a]){const _0x88df65=_0x4fb16c?_0x402781['diffData'][_0x5c972a]['attributesBefore']:_0x402781['diffData'][_0x5c972a]['attributesAfter'];_0x287e29['attributes'][_0x5c972a]=_0x88df65?_0x503699(_0x88df65):{};break;}_0x330ad9+=_0x116570;}}for(const _0x1a417c of _0x4f98a8){_0x1a417c['model']={};for(const _0x54a338 of _0x1a417c['authors'])_0x59af94['set'](_0x54a338['id'],_0x54a338);for(const _0x157c72 of _0x4ec825){const _0x252230=_0x1a417c['diffData'][_0x157c72]?_0x1a417c['diffData'][_0x157c72]['insertions']:'[]',_0x38401b=_0x1a417c['diffData'][_0x157c72]?_0x1a417c['diffData'][_0x157c72]['deletions']:'[]';_0x1a417c['model'][_0x157c72]={'insertions':this['_utils']['_makeModelFromViewString'](_0x252230),'deletions':this['_utils']['_makeModelFromViewString'](_0x38401b)};}}for(const _0x329e3b of _0x4ec825){let _0xe25347=null,_0x2fc05f=0x0;const _0x21878a=new Map(Array['from'](_0x4558cb['model'][_0x329e3b]['insertions']['markers'])['filter'](([_0x57035b])=>!_0x57035b['startsWith']('revision:')));let _0x3d97a0=0x0;for(const _0x35195b of _0x4f98a8){const _0x415d2e=this['_makeTape'](_0x35195b['model'][_0x329e3b]['insertions']);_0x35195b==_0x4558cb?(_0xe25347=_0x415d2e,_0x2fc05f=_0xe25347['length'],_0xe25347['forEach'](_0x1df6d8=>{_0x1df6d8['id']=_0x3d97a0++;}),this['_processTape'](_0xe25347)):this['_markInsertions'](_0xe25347,_0x415d2e);const _0x36549e=_0xe25347['filter'](_0xbeb9b8=>!_0xbeb9b8['isAdded'])['map'](_0x127970=>_0x127970['id']);let _0x263539=0x0;const _0x32dfcf=this['_makeTape'](_0x35195b['model'][_0x329e3b]['deletions']);_0x32dfcf['forEach'](_0x5583e9=>{_0x5583e9['isRemoved']?_0x5583e9['id']=_0x2fc05f++:_0x5583e9['id']=_0x36549e[_0x263539++];}),this['_processTape'](_0x32dfcf),this['_setDistance'](_0xe25347,'isAdded'),this['_setDistance'](_0x32dfcf,'isRemoved'),_0x35195b==_0x4558cb&&this['_markMarkers'](_0xe25347,_0x21878a),_0xe25347=this['_joinTapes'](_0xe25347,_0x32dfcf),this['_refreshStartEndIndex'](_0xe25347),this['_setDistance'](_0xe25347,'isRemoved');}_0xe25347=_0xe25347['filter'](_0xebf1c8=>!(_0xebf1c8['isAdded']&&_0xebf1c8['isRemoved']));const _0x4e8a9f=new Map(_0x3eeac5['model'][_0x329e3b]['deletions']['markers']),_0x557213=new Set(_0x21878a['keys']());for(const _0x267684 of _0x4e8a9f['keys']())_0x557213['delete'](_0x267684);this['_markSuggestions'](_0xe25347,_0x557213),this['_fixObsoleteTags'](_0xe25347),_0xe25347=this['_removeMissingPairs'](_0xe25347),_0xe25347=this['_markMismatchedRemovedTags'](_0xe25347),_0xe25347=this['_removeUnsupportedChanges'](_0xe25347);const {root:_0x333b09,changes:_0x44d4f4}=this['_makeModelFromTape'](_0xe25347,_0x59af94,_0x329e3b);_0x287e29['model'][_0x329e3b]=_0x333b09;const _0x4c43ce=_0x8af27d['get'](_0x329e3b);if(_0x4c43ce){const _0x3a2a1=_0x59af94['get'](_0x4c43ce['userId']),_0x1896d6=new r({'author':_0x3a2a1,'type':_0x4c43ce['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x329e3b});_0x44d4f4['unshift'](_0x1896d6),_0x287e29['attributes'][_0x329e3b]['revisionHistoryAttachChange']=_0x1896d6['id'];}_0x287e29['changes']=_0x287e29['changes']['concat'](_0x44d4f4);}return _0x287e29;}['_markMarkers'](_0x1468a5,_0x49146c){for(let _0x3db2c3=0x0;_0x3db2c3<_0x1468a5['length'];_0x3db2c3++)for(const [_0x2256a3,_0x5e4845]of _0x49146c)!_0x5e4845['isCollapsed']&&_0x5e4845['start']['isEqual'](_0x1468a5[_0x3db2c3]['previousPosition'])&&_0x1468a5[_0x3db2c3]['markersStart']['push'](_0x2256a3),_0x5e4845['end']['isEqual'](_0x1468a5[_0x3db2c3]['nextPosition'])&&_0x1468a5[_0x3db2c3]['markersEnd']['push'](_0x2256a3);}['_joinTapes'](_0x5037db,_0x5e9a5c){let _0x280aa8=[],_0x5e1954=0x0,_0xd27869=0x0;for(;_0x5e1954<_0x5037db['length']||_0xd27869<_0x5e9a5c['length'];){const _0xa4ec85=_0x5037db[_0x5e1954]||{},_0x1f23bc=_0x5e9a5c[_0xd27869]||{};if(_0xa4ec85['id']==_0x1f23bc['id'])_0x5e1954++,_0xd27869++,_0x280aa8['push'](_0xa4ec85);else{if(_0x1f23bc['isRemoved']&&_0xa4ec85['isAdded']){const {commonTape:_0x13afdd,iEnd:_0xd27a06,jEnd:_0x263395}=this['_threeWayMerge'](_0x5037db,_0x5e1954,_0x5e9a5c,_0xd27869);_0x280aa8=_0x280aa8['concat'](_0x13afdd),_0x5e1954=_0xd27a06,_0xd27869=_0x263395;}else _0x1f23bc['isRemoved']?(_0xd27869++,_0x280aa8['push'](_0x1f23bc)):(_0x5e1954++,_0x280aa8['push'](_0xa4ec85));}}return _0x280aa8;}['_markSuggestions'](_0x277f9b,_0x47bf89){const _0x198514=[];for(let _0x5d6a3b=0x0;_0x5d6a3b<_0x277f9b['length'];_0x5d6a3b++){for(let _0x1cc03a=0x0;_0x1cc03a<_0x277f9b[_0x5d6a3b]['markersStart']['length'];_0x1cc03a++){const _0x2ee5b8=_0x277f9b[_0x5d6a3b]['markersStart'][_0x1cc03a];if(!_0x47bf89['has'](_0x2ee5b8))continue;const {group:_0x34dd80,type:_0x652bcb,authorId:_0x5bf87d}=_0x5655b3(_0x2ee5b8);'revision-suggestion'!=_0x34dd80||'insertion'!=_0x652bcb&&'deletion'!=_0x652bcb||(_0x198514['unshift']({'type':_0x652bcb,'name':_0x2ee5b8,'userId':_0x5bf87d}),_0x277f9b[_0x5d6a3b]['markersStart']['splice'](_0x1cc03a,0x1),_0x1cc03a--);}_0x55b51b(_0x277f9b[_0x5d6a3b]);for(let _0x19d849=0x0;_0x19d849<_0x277f9b[_0x5d6a3b]['markersEnd']['length'];_0x19d849++){const _0x9fbcf1=_0x277f9b[_0x5d6a3b]['markersEnd'][_0x19d849];if(!_0x47bf89['has'](_0x9fbcf1))continue;const {group:_0x127cc1,type:_0x297969}=_0x5655b3(_0x9fbcf1);if('revision-suggestion'!=_0x127cc1||'insertion'!=_0x297969&&'deletion'!=_0x297969)continue;_0x277f9b[_0x5d6a3b]['markersEnd']['splice'](_0x19d849,0x1),_0x19d849--;const _0x1b551c=_0x198514['findIndex'](_0x1c4c10=>_0x1c4c10['name']==_0x9fbcf1);_0x1b551c>-0x1&&_0x198514['splice'](_0x1b551c,0x1);}}function _0x5655b3(_0x4254c3){const _0xe72989=_0x4254c3['split'](':');return{'group':_0xe72989[0x0],'type':_0xe72989[0x1],'subType':_0xe72989['length']>=0x5?_0xe72989[0x2]:null,'id':_0xe72989['length']<0x5?_0xe72989[0x2]:_0xe72989[0x3],'authorId':_0xe72989['length']<0x5?_0xe72989[0x3]:_0xe72989[0x4],'markerCount':0x6==_0xe72989['length']?_0xe72989[0x5]:null};}function _0x55b51b(_0x1e4ee2){for(let _0x90c871=0x0;_0x90c871<_0x198514['length'];_0x90c871++){if(_0x1e4ee2['isAdded']&&'insertion'==_0x198514[_0x90c871]['type'])return _0x1e4ee2['isAddSuggestion']=_0x198514[_0x90c871],void delete _0x1e4ee2['isAdded'];if(!_0x1e4ee2['isAdded']&&!_0x1e4ee2['isRemoved']&&'deletion'==_0x198514[_0x90c871]['type'])return void(_0x1e4ee2['isRemoveSuggestion']=_0x198514[_0x90c871]);}}}['_setDistance'](_0x9542b7,_0xb04dba){let _0x4bf894=0x0,_0x2d045f=!0x1;const _0x5b5ce2=new Map();for(const _0x5761bc of _0x9542b7)_0x5761bc[_0xb04dba]?_0x2d045f&&(_0x4bf894++,_0x2d045f=!0x1):(_0x4bf894++,_0x2d045f=!0x0),_0x5b5ce2['set'](_0x5761bc['id'],_0x4bf894);for(let _0xb7c195=0x0;_0xb7c195<_0x9542b7['length'];_0xb7c195++){if('isRemoved'==_0xb04dba&&_0x9542b7[_0xb7c195]['isAdded']||'isAdded'==_0xb04dba&&_0x9542b7[_0xb7c195]['isRemoved'])continue;if('text'==_0x9542b7[_0xb7c195]['type']){_0x9542b7[_0xb7c195]['distance']=0x0;continue;}const _0x346dfc=_0x5b5ce2['get'](_0x9542b7[_0xb7c195]['pairId']),_0x2ca361=_0x5b5ce2['get'](_0x9542b7[_0xb7c195]['id']);_0x9542b7[_0xb7c195]['distance']=_0x346dfc-_0x2ca361;}}['_getRevisionsRange'](_0x5e88da,_0x5e966a,_0x464190=!0x1){const _0x4839ce=[];let _0x1387af=this['repository']['getIndex'](_0x5e88da),_0x2c9ff1=this['repository']['getIndex'](_0x5e966a);for(-0x1==_0x2c9ff1&&(_0x2c9ff1=this['repository']['_revisions']['length'],_0x464190=!0x1);_0x1387af<_0x2c9ff1;)_0x4839ce['push'](this['repository']['getRevision'](_0x1387af)),_0x1387af++;return _0x464190&&_0x4839ce['push'](this['repository']['getRevision'](_0x1387af)),_0x4839ce;}['_threeWayMerge'](_0x4847c4,_0x395594,_0x39da08,_0x2e0239){const _0x18efee=this['editor']['model']['schema'];let _0x47c013=_0x395594;for(;_0x4847c4[_0x47c013]&&_0x4847c4[_0x47c013]['isAdded'];)_0x47c013++;let _0x228614=_0x2e0239;for(;_0x39da08[_0x228614]&&_0x39da08[_0x228614]['isRemoved'];)_0x228614++;_0x7ff3ae(_0x4847c4,_0x395594,_0x47c013),_0x7ff3ae(_0x39da08,_0x2e0239,_0x228614);const _0x47c286=_0x39da08['slice'](_0x2e0239,_0x228614)['concat'](_0x4847c4['slice'](_0x395594,_0x47c013));return _0x47c286['sort']((_0x1f4e4a,_0x449b74)=>_0x1f4e4a['side']!=_0x449b74['side']?_0x1f4e4a['side']-_0x449b74['side']:_0x1f4e4a['level']!=_0x449b74['level']?_0x1f4e4a['level']-_0x449b74['level']:_0x1f4e4a['distance']!=_0x449b74['distance']?_0x449b74['distance']-_0x1f4e4a['distance']:!!_0x1f4e4a['isAdded']!=!!_0x449b74['isAdded']?-0x1==_0x1f4e4a['side']||0x0==_0x1f4e4a['side']?_0x1f4e4a['isAdded']?-0x1:0x1:_0x1f4e4a['isAdded']?0x1:-0x1:_0x1f4e4a['index']-_0x449b74['index']),{'commonTape':_0x47c286,'iEnd':_0x47c013,'jEnd':_0x228614};function _0x7ff3ae(_0x34b949,_0x3d313b,_0x26b072){let _0x4e4573=-0x1,_0x55ba00=Number['POSITIVE_INFINITY'],_0x11c89e=!0x0;for(let _0x2d289c=_0x3d313b;_0x2d289c<_0x26b072;_0x2d289c++)if(_0x18efee['isInline'](_0x34b949[_0x2d289c]['item'])||(_0x11c89e=!0x1),_0x34b949[_0x2d289c]['item']['startIndex']<_0x3d313b&&(_0x4e4573=_0x2d289c),_0x34b949[_0x2d289c]['item']['endIndex']>=_0x26b072){_0x55ba00=_0x2d289c;break;}_0x11c89e&&(_0x4e4573=_0x26b072-0x1);for(let _0x26cbc5=_0x3d313b;_0x26cbc5<_0x26b072;_0x26cbc5++)_0x34b949[_0x26cbc5]['side']=_0x26cbc5<=_0x4e4573?-0x1:_0x26cbc5<_0x55ba00?0x0:0x1,_0x34b949[_0x26cbc5]['index']=_0x26cbc5;let _0x2633c5=0x0;for(let _0x4fb02d=_0x3d313b;_0x4fb02d<=_0x4e4573;_0x4fb02d++)0x0==_0x34b949[_0x4fb02d]['distance']?_0x34b949[_0x4fb02d]['level']=_0x2633c5:(_0x2633c5++,_0x34b949[_0x4fb02d]['level']=_0x2633c5,_0x2633c5++);for(let _0x1e73ef=_0x3d313b;_0x1e73ef<_0x26b072;_0x1e73ef++)0x0==_0x34b949[_0x1e73ef]['side']&&(_0x34b949[_0x1e73ef]['level']=_0x2633c5);_0x2633c5=0x0;for(let _0x1a4c66=_0x26b072-0x1;_0x1a4c66>=_0x55ba00;_0x1a4c66--)0x0==_0x34b949[_0x1a4c66]['distance']?_0x34b949[_0x1a4c66]['level']=_0x2633c5:(_0x2633c5--,_0x34b949[_0x1a4c66]['level']=_0x2633c5,_0x2633c5--);}}['_fixObsoleteTags'](_0xb6ad90){const _0x244a79=new Map(),_0x4858c9=this['editor']['model']['schema'];for(let _0x5ce53b=0x1;_0x5ce53b<_0xb6ad90['length'];_0x5ce53b++){let _0x600e39,_0xad19b0,_0x1f49f6;const _0x55ffa3=_0xb6ad90[_0x5ce53b],_0x11d1d4=_0xb6ad90[_0x5ce53b-0x1];if('text'==_0x55ffa3['type'])continue;if(_0x55ffa3['type']!=_0x11d1d4['type'])continue;if(!_0x4858c9['isBlock'](_0x11d1d4['item'])||_0x4858c9['isLimit'](_0x11d1d4['item']))continue;if(!_0x4858c9['isBlock'](_0x55ffa3['item'])||_0x4858c9['isLimit'](_0x55ffa3['item']))continue;if((_0xb6ad90[_0x5ce53b]['isAdded']||_0xb6ad90[_0x5ce53b]['isAddSuggestion'])&&_0xb6ad90[_0x5ce53b-0x1]['isRemoved'])_0x600e39=_0xb6ad90[_0x5ce53b],_0xad19b0=_0xb6ad90[_0x5ce53b-0x1],_0x1f49f6=_0x5ce53b-0x1;else{if(!_0xb6ad90[_0x5ce53b]['isRemoved']||!_0xb6ad90[_0x5ce53b-0x1]['isAdded']&&!_0xb6ad90[_0x5ce53b-0x1]['isAddSuggestion'])continue;_0x600e39=_0xb6ad90[_0x5ce53b-0x1],_0xad19b0=_0xb6ad90[_0x5ce53b],_0x1f49f6=_0x5ce53b;}const _0x18192e=_0x600e39['level']==_0xad19b0['level'],_0x527312=Math['abs'](_0x600e39['level'])<Math['abs'](_0xad19b0['level'])&&0x0==_0xad19b0['distance'];(_0x18192e||_0x527312)&&(_0x244a79['set'](_0xad19b0['id'],_0x600e39['id']),_0xb6ad90['splice'](_0x1f49f6,0x1),_0x5ce53b--,_0x600e39['isAdded']=!0x1);}for(let _0x43cab4=0x0;_0x43cab4<_0xb6ad90['length'];_0x43cab4++)_0x244a79['has'](_0xb6ad90[_0x43cab4]['pairId'])&&(_0xb6ad90[_0x43cab4]['pairId']=_0x244a79['get'](_0xb6ad90[_0x43cab4]['pairId']));}['_removeMissingPairs'](_0x342ba3){const _0x256a15=new Set(_0x342ba3['map'](_0x5f2a87=>_0x5f2a87['id']));for(let _0x464805=0x0;_0x464805<_0x342ba3['length'];_0x464805++)_0x256a15['has'](_0x342ba3[_0x464805]['pairId'])||0x0==_0x342ba3[_0x464805]['distance']||(_0x342ba3[_0x464805]['isIncorrect']=!0x0);return _0x342ba3['filter'](_0x33529e=>!_0x33529e['isIncorrect']);}['_markMismatchedRemovedTags'](_0x3d56f3){const _0x32f81a=new Set();for(let _0x406e56=0x0;_0x406e56<_0x3d56f3['length'];_0x406e56++){if(_0x32f81a['has'](_0x3d56f3[_0x406e56]['id'])&&_0x3d56f3[_0x406e56]['isRemoved']&&(_0x3d56f3[_0x406e56]['isIncorrect']=!0x0),_0x3d56f3[_0x406e56]['isIncorrect'])continue;if(0x0==_0x3d56f3[_0x406e56]['distance'])continue;if('elementStart'!=_0x3d56f3[_0x406e56]['type'])continue;if(null==_0x3d56f3[_0x406e56]['pairId'])continue;let _0x1a9a8f=_0x406e56+0x1,_0x30b2b0=0x0;for(;_0x3d56f3[_0x1a9a8f]['id']!=_0x3d56f3[_0x406e56]['pairId'];)'elementStart'==_0x3d56f3[_0x1a9a8f]['type']?_0x30b2b0++:'elementEnd'==_0x3d56f3[_0x1a9a8f]['type']&&_0x30b2b0--,_0x1a9a8f++;if(0x0!=_0x30b2b0){if(_0x3d56f3[_0x406e56]['isRemoved'])_0x3d56f3[_0x406e56]['isIncorrect']=!0x0;else{for(;_0x1a9a8f!=_0x406e56;)_0x3d56f3[_0x1a9a8f]['isRemoved']&&0x0!=_0x3d56f3[_0x1a9a8f]['distance']&&(_0x3d56f3[_0x1a9a8f]['isIncorrect']=!0x0,_0x32f81a['add'](_0x3d56f3[_0x1a9a8f]['pairId'])),_0x1a9a8f--;}}}return _0x3d56f3['filter'](_0x2752f1=>!_0x2752f1['isIncorrect']);}['_removeUnsupportedChanges'](_0x239ffe){const _0x37c986=this['editor']['model']['schema'];for(let _0x3a54a9=0x0;_0x3a54a9<_0x239ffe['length'];_0x3a54a9++){if(!(_0x239ffe[_0x3a54a9]['isAdded']||_0x239ffe[_0x3a54a9]['isAddSuggestion']||_0x239ffe[_0x3a54a9]['isRemoved']||_0x239ffe[_0x3a54a9]['isRemoveSuggestion']))continue;if(0x0==_0x239ffe[_0x3a54a9]['distance'])continue;const _0x365ca4=_0x239ffe[_0x3a54a9]['item'];_0x37c986['isBlock'](_0x365ca4)||_0x37c986['isLimit'](_0x365ca4)||(_0x239ffe[_0x3a54a9]['isAdded']&&delete _0x239ffe[_0x3a54a9]['isAdded'],_0x239ffe[_0x3a54a9]['isAddSuggestion']&&delete _0x239ffe[_0x3a54a9]['isAddSuggestion'],_0x239ffe[_0x3a54a9]['isRemoveSuggestion']&&delete _0x239ffe[_0x3a54a9]['isRemoveSuggestion'],_0x239ffe[_0x3a54a9]['isRemoved']&&(_0x239ffe[_0x3a54a9]['isIncorrect']=!0x0));}return _0x239ffe['filter'](_0x201f80=>!_0x201f80['isIncorrect']);}['_makeModelFromTape'](_0x37ea90,_0x1a47a8,_0x5c46c7){const _0x5cd9a2=new vt(),_0x82b986=[],_0x3667eb=new Map(),_0x10dcd3=this['editor']['model'],_0x206739=_0x10dcd3['schema'],_0x1c48fa=[_0x5cd9a2],_0x113d5f={},_0xf90ebc={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x466087=null;const _0x5399e9=[0x0];for(let _0x5aae9e=0x0;_0x5aae9e<_0x37ea90['length'];_0x5aae9e++)if('elementStart'===_0x37ea90[_0x5aae9e]['type']){_0x37ea90[_0x5aae9e]['previousPosition']=_0x10dcd3['createPositionFromPath'](_0x5cd9a2,_0x5399e9);const _0x4b86fc=new ut(_0x37ea90[_0x5aae9e]['item']['name'],_0x37ea90[_0x5aae9e]['item']['getAttributes']());_0x1c48fa[0x0]['_appendChild'](_0x4b86fc),_0x5399e9['push'](0x0),_0x1c48fa['unshift'](_0x4b86fc),_0x37ea90[_0x5aae9e]['nextPosition']=_0x10dcd3['createPositionFromPath'](_0x5cd9a2,_0x5399e9);}else'elementEnd'===_0x37ea90[_0x5aae9e]['type']?(_0x1c48fa['shift'](),_0x37ea90[_0x5aae9e]['previousPosition']=_0x10dcd3['createPositionFromPath'](_0x5cd9a2,_0x5399e9),_0x5399e9['pop'](),_0x5399e9[_0x5399e9['length']-0x1]++,_0x37ea90[_0x5aae9e]['nextPosition']=_0x10dcd3['createPositionFromPath'](_0x5cd9a2,_0x5399e9)):(_0x37ea90[_0x5aae9e]['previousPosition']=_0x10dcd3['createPositionFromPath'](_0x5cd9a2,_0x5399e9),_0x466087?_0x466087['_data']+=_0x37ea90[_0x5aae9e]['item']['data']:_0x466087=new gt(_0x37ea90[_0x5aae9e]['item']['data'],_0x37ea90[_0x5aae9e]['item']['getAttributes']()),_0x37ea90[_0x5aae9e+0x1]&&'text'===_0x37ea90[_0x5aae9e+0x1]['type']&&_0x2a9e66(_0x466087,_0x37ea90[_0x5aae9e+0x1]['item'])||(_0x1c48fa[0x0]['_appendChild'](_0x466087),_0x466087=null),_0x5399e9[_0x5399e9['length']-0x1]+=_0x37ea90[_0x5aae9e]['item']['offsetSize'],_0x37ea90[_0x5aae9e]['nextPosition']=_0x10dcd3['createPositionFromPath'](_0x5cd9a2,_0x5399e9));for(let _0x5abf0b=0x0;_0x5abf0b<_0x37ea90['length'];_0x5abf0b++){const _0x324513=_0x37ea90[_0x5abf0b]['previousPosition'],_0x94a945=_0x37ea90[_0x5abf0b]['nextPosition'];for(const _0x540336 of _0x37ea90[_0x5abf0b]['markersStart'])_0x3667eb['set'](_0x540336,{'start':_0x324513,'end':null});_0x18e9c4('isRemoveSuggestion',_0x5abf0b,_0x324513,_0x94a945),_0x18e9c4('isAddSuggestion',_0x5abf0b,_0x324513,_0x94a945),_0x18e9c4('isRemoved',_0x5abf0b,_0x324513,_0x94a945),_0x18e9c4('isAdded',_0x5abf0b,_0x324513,_0x94a945);for(const _0x570079 of _0x37ea90[_0x5abf0b]['markersEnd']){const _0x2a63e0=_0x3667eb['get'](_0x570079);_0x2a63e0?_0x2a63e0['end']=_0x94a945:_0x3667eb['set'](_0x570079,{'start':_0x94a945,'end':_0x94a945});}}for(const [_0x33c0f5,_0x373c11]of _0x3667eb){const _0x4a2dd4=this['editor']['model']['createRange'](_0x373c11['start'],_0x373c11['end']);_0x5cd9a2['markers']['set'](_0x33c0f5,_0x4a2dd4);}return _0x82b986['sort']((_0x52bad1,_0x1caf35)=>{const _0x337f39=_0x5cd9a2['markers']['get']('revision:'+_0x52bad1['id']),_0x236b26=_0x5cd9a2['markers']['get']('revision:'+_0x1caf35['id']);return _0x337f39['start']['isBefore'](_0x236b26['start'])?-0x1:_0x337f39['start']['isAfter'](_0x236b26['start'])?0x1:_0x337f39['end']['isBefore'](_0x236b26['end'])?-0x1:_0x337f39['end']['isAfter'](_0x236b26['end'])?0x1:'add'===_0x52bad1['type']?-0x1:0x1;}),{'root':_0x5cd9a2,'changes':_0x82b986};function _0x18e9c4(_0x269b3e,_0x4b40c4,_0x396fc1,_0x41ee96){const _0x2a3695=!!_0x37ea90[_0x4b40c4][_0x269b3e],_0x238472=_0x2a3695?_0x37ea90[_0x4b40c4][_0x269b3e]['userId']:null,_0x5af510=_0x4b40c4===_0x37ea90['length']-0x1,_0x4c6b11=_0xf90ebc[_0x269b3e][0x0],_0x375854=_0x206739['isObject'](_0x37ea90[_0x4b40c4]['item']);!_0x113d5f[_0x269b3e]&&_0x2a3695?_0x113d5f[_0x269b3e]={'start':_0x396fc1,'tapeItem':_0x37ea90[_0x4b40c4],'userId':_0x238472,'type':_0x269b3e}:_0x113d5f[_0x269b3e]&&!_0x2a3695?(_0x113d5f[_0x269b3e]['end']=_0x396fc1,_0x5899db(_0x113d5f[_0x269b3e]),_0x113d5f[_0x269b3e]=null):_0x113d5f[_0x269b3e]&&_0x2a3695&&_0x113d5f[_0x269b3e]['userId']!==_0x238472&&(_0x113d5f[_0x269b3e]['end']=_0x396fc1,_0x4c6b11&&_0x4c6b11['userId']===_0x113d5f[_0x269b3e]['userId']||_0x5899db(_0x113d5f[_0x269b3e]),_0x113d5f[_0x269b3e]={'start':_0x396fc1,'tapeItem':_0x37ea90[_0x4b40c4],'userId':_0x238472,'type':_0x269b3e}),_0x113d5f[_0x269b3e]&&_0x375854&&('elementStart'!==_0x37ea90[_0x4b40c4]['type']||_0x4c6b11&&_0x4c6b11['userId']===_0x238472||_0xf90ebc[_0x269b3e]['unshift']({'userId':_0x238472,'object':_0x37ea90[_0x4b40c4]['item'],'change':_0x113d5f[_0x269b3e]}),'elementEnd'===_0x37ea90[_0x4b40c4]['type']&&_0x4c6b11&&_0x4c6b11['object']===_0x37ea90[_0x4b40c4]['item']&&(_0xf90ebc[_0x269b3e]['shift'](),_0x113d5f[_0x269b3e]=_0x4c6b11['change'])),_0x113d5f[_0x269b3e]&&_0x5af510&&(_0x113d5f[_0x269b3e]['end']=_0x41ee96,_0x5899db(_0x113d5f[_0x269b3e]),_0x113d5f[_0x269b3e]=null);}function _0x5899db({start:_0x58243b,end:_0x59f6b2,tapeItem:_0x5e6da2,userId:_0x254ece,type:_0x21ba89}){const _0x4a7831=_0x5e6da2['item'],_0x50e784=_0x10dcd3['schema']['isBlock'](_0x4a7831)&&!_0x10dcd3['schema']['isLimit'](_0x4a7831),_0x1dc322=_0x58243b['nodeAfter']==_0x59f6b2['parent']&&_0x59f6b2['isAtStart'];if(_0x50e784&&_0x1dc322)return;const _0x58908e=_0x10dcd3['createRange'](_0x58243b,_0x59f6b2),_0x41d8de=_0x1a47a8['get'](_0x254ece),_0x53ecb3=new r({'author':_0x41d8de,'type':'isAdded'==_0x21ba89||'isAddSuggestion'==_0x21ba89?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x21ba89||'isRemoveSuggestion'==_0x21ba89},'createdAt':new Date(),'rootName':_0x5c46c7});_0x82b986['push'](_0x53ecb3),_0x5cd9a2['markers']['set']('revision:'+_0x53ecb3['id'],_0x58908e);}function _0x2a9e66(_0x282c53,_0x10bf63){const _0x57109e=_0x282c53['getAttributes'](),_0x390368=_0x10bf63['getAttributes']();for(const _0x18ca9b of _0x57109e){if(_0x18ca9b[0x1]!==_0x10bf63['getAttribute'](_0x18ca9b[0x0]))return!0x1;_0x390368['next']();}return _0x390368['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x31f81a=>{const _0x3dc948=_0x31f81a['markerName']['split'](':')[0x1],_0x251e01=this['_getChangeFromId'](_0x3dc948);if(!_0x251e01)return null;const _0x55c873='add'==_0x251e01['type']?'insertion':'deletion',_0x47eb62=['ck-suggestion-marker','ck-suggestion-marker-'+_0x55c873];return _0x251e01['data']['isSuggestion']&&_0x47eb62['push']('ck-suggestion-marker-'+_0x55c873+'-new'),this['activeChange']==_0x251e01&&_0x47eb62['push']('ck-suggestion-marker--active'),{'classes':_0x47eb62,'attributes':{'data-change-id':_0x3dc948}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x391f9f=>{_0x391f9f['on']('element:pre',(_0xd160f7,_0x1fc00b,_0x16e90a)=>{const _0x446d02=_0x1fc00b['viewItem']['getChild'](0x0);if(!_0x446d02||!_0x446d02['is']('element','code'))return;if(!_0x16e90a['consumable']['consume'](_0x446d02,{'attributes':['vid_start','vid_end']}))return;const _0x15b785=_0x1fc00b['modelRange']['start']['nodeAfter'];_0x16e90a['writer']['setAttribute']('vid_start',_0x446d02['getAttribute']('vid_start'),_0x15b785),_0x16e90a['writer']['setAttribute']('vid_end',_0x446d02['getAttribute']('vid_end'),_0x15b785);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x33c033=>{_0x33c033['on']('element',(_0x2dbf55,_0x322e3a,_0x1a13f0)=>{if(!_0x1a13f0['consumable']['consume'](_0x322e3a['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x322e3a['modelRange']['isCollapsed'])return;const _0x51e728=_0x322e3a['modelRange']['start']['nodeAfter'];_0x51e728['hasAttribute']('vid_start')||_0x51e728['hasAttribute']('vid')||(_0x1a13f0['writer']['setAttribute']('vid_start',_0x322e3a['viewItem']['getAttribute']('vid_start'),_0x51e728),_0x1a13f0['writer']['setAttribute']('vid_end',_0x322e3a['viewItem']['getAttribute']('vid_end'),_0x51e728));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x2058ea=>_0x2058ea['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x4cebfc,[,_0x408deb])=>{['vid_start','vid_end','vid']['includes'](_0x408deb)&&(_0x4cebfc['return']=!0x0,_0x4cebfc['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x27ac04=>{_0x27ac04['on']('attribute:vid',(_0x3d60c9,_0x8406a9,_0x15d7a4)=>{if('\x20'!=_0x8406a9['item']['data']||_0x8406a9['item']['parent']['maxOffset']>0x1)return;if(!_0x15d7a4['consumable']['consume'](_0x8406a9['item'],_0x3d60c9['name']))return;const _0x15d895=_0x15d7a4['writer'],_0x3359e9=_0x15d7a4['mapper']['toViewRange'](_0x8406a9['range']);_0x15d895['wrap'](_0x3359e9,_0x15d895['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x426ceb){const _0x5912f0=_0x426ceb['plugins']['get']('RevisionViewer');return(_0x3e1b1c,_0x979899,_0x4429ec)=>{const _0x43e6d8=_0x979899['markerName']['split'](':')[0x1],_0x15af5a=_0x5912f0['_getChangeFromId'](_0x43e6d8);if(!_0x15af5a)return null;const _0xdb6807='add'==_0x15af5a['type']?'split':'merge';if(!_0x4429ec['consumable']['test'](_0x979899['markerRange'],_0x3e1b1c['name']))return;const _0x3ad1c4=_0x979899['markerRange']['getWalker'](),_0x3fa402=_0x979899['markerRange']['start'],_0x1eb02a=_0x426ceb['model']['schema'];let _0x56f287=null,_0xf4bd57=null,_0x39e551=!0x1,_0x944709=!0x1;for(const _0x40c01a of _0x3ad1c4){const _0x3058e6=_0x40c01a['item'];_0x39e551=_0x39e551||_0x1eb02a['isContent'](_0x3058e6);const _0x40530e=_0x4429ec['mapper']['toViewElement'](_0x3058e6);if(_0x40530e&&_0x40530e['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x40c01a['type']&&(_0x1eb02a['isBlock'](_0x3058e6)&&!_0x1eb02a['isLimit'](_0x3058e6)&&(_0x3058e6['nextSibling']||_0x3fa402['isAtEnd']?_0x56f287&&_0x56f287['parent']==_0x3058e6||(_0x56f287=_0x3058e6,_0x587040(_0x40c01a['previousPosition']),_0x944709=!0x0):_0xf4bd57=_0xf4bd57||_0x40c01a['previousPosition']));}function _0x587040(_0x17acb5){const _0x3fc307=_0x4429ec['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0xdb6807}),_0x5eb475=_0x4429ec['mapper']['toViewPosition'](_0x17acb5);_0x15af5a['data']['isSuggestion']&&_0x4429ec['writer']['addClass']('ck-suggestion-marker-'+_0xdb6807+'-new',_0x3fc307),_0x5912f0['activeChange']==_0x15af5a&&_0x4429ec['writer']['addClass']('ck-suggestion-marker--active',_0x3fc307),_0x4429ec['writer']['insert'](_0x5eb475,_0x3fc307),_0x4429ec['mapper']['bindElementToMarker'](_0x3fc307,_0x979899['markerName']);}_0x39e551||_0x944709||!_0xf4bd57||_0x587040(_0xf4bd57);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x4376fb,_0x55b8fe,_0x48549e)=>{const _0x34a320=_0x48549e['mapper']['markerNameToElements'](_0x55b8fe['markerName']);if(_0x34a320){for(const _0x12721b of _0x34a320)(_0x12721b['hasClass']('ck-suggestion-marker-split')||_0x12721b['hasClass']('ck-suggestion-marker-merge'))&&(_0x48549e['mapper']['unbindElementFromMarkerName'](_0x12721b,_0x55b8fe['markerName']),_0x48549e['writer']['remove'](_0x12721b));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x114ba2,_0x5c7dfd,_0x4eecf3)=>{const _0x222c45=_0x5c7dfd['markerName']['split'](':')[0x1],_0x4fac09=this['_getChangeFromId'](_0x222c45);if(!_0x4fac09)return null;const _0x343d1e='add'==_0x4fac09['type']?'split':'merge';if(_0x4eecf3['consumable']['test'](_0x5c7dfd['markerRange'],_0x114ba2['name']))for(const _0x95efa4 of _0x5c7dfd['markerRange']['getItems']()){if(!_0x95efa4['is']('element','softBreak'))continue;const _0x3cc952=_0x4eecf3['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x343d1e}),_0x2d3298=_0x4eecf3['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x95efa4));_0x4fac09['data']['isSuggestion']&&_0x4eecf3['writer']['addClass']('ck-suggestion-marker-'+_0x343d1e+'-new',_0x3cc952),this['activeChange']==_0x4fac09&&_0x4eecf3['writer']['addClass']('ck-suggestion-marker--active',_0x3cc952),_0x4eecf3['writer']['insert'](_0x2d3298,_0x3cc952),_0x4eecf3['mapper']['bindElementToMarker'](_0x3cc952,_0x5c7dfd['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x31b3fc=>{for(const _0x32872a of this['editor']['model']['document']['getRootNames']()){const _0x37e8ef=this['editor']['model']['document']['getRoot'](_0x32872a),_0x5b8a3b=this['editor']['editing']['view']['document']['getRoot'](_0x32872a);if(_0x5b8a3b){const _0x46e241=_0x37e8ef['getAttribute']('revisionHistoryAttachChange');if(_0x31b3fc['removeAttribute']('data-change-id',_0x5b8a3b),_0x31b3fc['removeClass']('ck-revision-history-root-add',_0x5b8a3b),_0x31b3fc['removeClass']('ck-revision-history-root-remove',_0x5b8a3b),_0x31b3fc['removeClass']('ck-revision-history-root--active',_0x5b8a3b),_0x46e241){const _0x1c0102=this['_getChangeFromId'](_0x46e241);if(!_0x1c0102)return null;_0x31b3fc['setAttribute']('data-change-id',_0x46e241,_0x5b8a3b),_0x31b3fc['addClass']('ck-revision-history-root-'+_0x1c0102['type'],_0x5b8a3b),this['activeChange']==_0x1c0102&&_0x31b3fc['addClass']('ck-revision-history-root--active',_0x5b8a3b);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x1d9192=>'revision-comment:'+_0x1d9192,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x53766d=>'revision-suggestion:'+_0x53766d,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x2f9459=>({'name':'suggestion:'+_0x2f9459,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x2e9ebf=>{const _0x5edc1d=_0x2e9ebf['markerName']['split'](':')[0x1];return'insertion'!=_0x5edc1d&&'deletion'!=_0x5edc1d?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x5edc1d]};}}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:deletion',X(this['editor'],'merge'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:insertion',X(this['editor'],'split'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision-suggestion',(_0x4d3297,_0x3c220a,_0x59a23c)=>{const _0x30b8ba=_0x59a23c['mapper']['markerNameToElements'](_0x3c220a['markerName']);if(_0x30b8ba){for(const _0x58ed7e of _0x30b8ba)_0x58ed7e['is']('uiElement')&&(_0x59a23c['mapper']['unbindElementFromMarkerName'](_0x58ed7e,_0x3c220a['markerName']),_0x59a23c['writer']['remove'](_0x58ed7e));}},{'priority':'high'});}['_getChangeFromId'](_0x361e03){return this['_changeIdToChange']['get'](_0x361e03);}['_getViewForChange'](_0x51af90){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new Q(this['editor']['locale'],_0x51af90),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x160778,_0x3cf478,_0x35cad6,_0xa54c46)=>{_0xa54c46&&this['_balloon']['remove'](_0xa54c46),_0x35cad6&&(this['_balloon']['add']({'view':_0x35cad6,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x5f2c9d=this['editor']['editing'],_0x334f63=this['_getChangeFromId'](_0x35cad6['changeId']);let _0x9ec5b0;if(_0x334f63['data']['isOnRoot']){const _0x104e76=_0x5f2c9d['view']['getDomRoot'](_0x334f63['rootName']);_0x9ec5b0=Array['from'](_0x104e76['getClientRects']());}else{const _0x315257=this['editor']['model']['markers']['get']('revision:'+_0x35cad6['changeId']);_0x9ec5b0=Array['from'](_0x5f2c9d['mapper']['markerNameToElements'](_0x315257['name']))['map'](_0x1adb0c=>_0x5f2c9d['view']['domConverter']['mapViewToDom'](_0x1adb0c))['map'](_0x5eeb0f=>Array['from'](_0x5eeb0f['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x9ec5b0[0x0];return _0x9ec5b0['find'](_0x4bcb0c=>_0x4bcb0c['top']-0x3<=this['_activeViewTarget']['y']&&_0x4bcb0c['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x4bcb0c['left']-0x3<=this['_activeViewTarget']['x']&&_0x4bcb0c['right']+0x3>=this['_activeViewTarget']['x'])||_0x9ec5b0[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x12179b,_0x3d1aa9,_0x47fa00,_0x44099d)=>{this['activeView']=_0x47fa00?this['_getViewForChange'](_0x47fa00):null,this['editor']['model']['change'](()=>{const _0x3554d3=this['editor']['editing'];_0x44099d&&(_0x44099d['data']['isOnRoot']?_0x3554d3['view']['change'](_0x21f997=>{_0x21f997['removeClass']('ck-revision-history-root--active',_0x3554d3['view']['document']['getRoot'](_0x44099d['rootName']));}):_0x3554d3['reconvertMarker']('revision:'+_0x44099d['id'])),_0x47fa00&&(_0x47fa00['data']['isOnRoot']?_0x3554d3['view']['change'](_0x51d479=>{_0x51d479['addClass']('ck-revision-history-root--active',_0x3554d3['view']['document']['getRoot'](_0x47fa00['rootName']));}):_0x3554d3['reconvertMarker']('revision:'+_0x47fa00['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x350e3f,_0x30e265)=>{if(this['activeChange'])return;const _0x23aced=this['_findChangeIdFromDomTarget'](_0x30e265['target']),_0x218af2=this['_changeIdToChange']['get'](_0x23aced);_0x218af2?(this['_activeViewTarget']={'x':_0x30e265['domEvent']['x'],'y':_0x30e265['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x218af2)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x3256d8,_0x37f44a)=>{const _0x43147f=this['_findChangeIdFromDomTarget'](_0x37f44a['target']),_0x186679=this['_changeIdToChange']['get'](_0x43147f);_0x186679?(this['_activeViewTarget']={'x':_0x37f44a['domEvent']['x'],'y':_0x37f44a['domEvent']['y']},_0x186679===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x186679):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x4ff235){do{const _0x4f51bb=_0x4ff235['getAttribute']('data-change-id');if(_0x4f51bb)return _0x4f51bb;_0x4ff235=_0x4ff235['parent'];}while(_0x4ff235);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x5cb495=>{for(const _0x1aab4d of this['editor']['model']['markers'])_0x5cb495['removeMarker'](_0x1aab4d);});}}function X(_0x1a21b7,_0x305b97){return(_0x3d09c4,_0x599b4f,_0x35d54f)=>{if(!_0x35d54f['consumable']['test'](_0x599b4f['markerRange'],_0x3d09c4['name']))return;const _0x34eee5=_0x599b4f['markerRange']['getWalker'](),_0x50edde=_0x599b4f['markerRange']['start'],_0x5988bd=_0x1a21b7['model']['schema'];let _0x78ae48=null,_0x181b0b=null,_0x33544a=!0x1,_0xa43ebf=!0x1;for(const _0x589763 of _0x34eee5){const _0x58d8e5=_0x589763['item'];_0x33544a=_0x33544a||_0x5988bd['isContent'](_0x58d8e5);const _0x37e8a1=_0x35d54f['mapper']['toViewElement'](_0x58d8e5);if(_0x37e8a1&&_0x37e8a1['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x589763['type']&&(_0x5988bd['isBlock'](_0x58d8e5)&&!_0x5988bd['isLimit'](_0x58d8e5)&&(_0x58d8e5['nextSibling']||_0x50edde['isAtEnd']?_0x78ae48&&_0x78ae48['parent']==_0x58d8e5||(_0x78ae48=_0x58d8e5,_0x4eb303(_0x589763['previousPosition']),_0xa43ebf=!0x0):_0x181b0b=_0x181b0b||_0x589763['previousPosition']));}function _0x4eb303(_0xc5603f){const _0x2344d7=_0x35d54f['mapper']['toViewPosition'](_0xc5603f),_0x4bbe58=_0x35d54f['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x305b97});_0x35d54f['writer']['insert'](_0x2344d7,_0x4bbe58),_0x35d54f['mapper']['bindElementToMarker'](_0x4bbe58,_0x599b4f['markerName']);}_0x33544a||_0xa43ebf||!_0x181b0b||_0x4eb303(_0x181b0b);};}class mt extends _0x4a9630{constructor(_0x2e4f94){super(_0x2e4f94);const _0x4598e7=_0x2e4f94['plugins']['get'](m);this['affectsData']=!0x1,this['listenTo'](_0x4598e7,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x4598e7,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x4bf6d8=this['editor'],_0x22c68b=_0x4bf6d8['plugins']['get'](m),_0x19b425=_0x22c68b['isReady']?_0x22c68b['diff']['newRevisionId']:null;_0x4bf6d8['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x19b425);}['refresh'](){const {isReady:_0x3dd120,isEnabled:_0x509da8,repository:_0x5c476d,diff:_0x15aba8}=this['editor']['plugins']['get'](m),_0x5a86fb=_0x15aba8&&_0x5c476d['getLaterVisibleRevision'](_0x15aba8['newRevisionId']);this['isEnabled']=_0x3dd120&&_0x509da8&&Boolean(_0x5a86fb);}}class wt extends _0x4a9630{['_step'];constructor(_0x5a2e3a,{direction:_0x1c4218}){super(_0x5a2e3a);const _0x369bd5=_0x5a2e3a['plugins']['get'](m);this['affectsData']=!0x1,this['_step']='forward'===_0x1c4218?0x1:-0x1,this['listenTo'](_0x369bd5,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x369bd5,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x369bd5,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x2902f9=this['editor'],_0x16f3a1=_0x2902f9['plugins']['get'](m),{isNavigationMode:_0x2bfbef,currentChangeNumber:_0x2d6c1f}=_0x16f3a1;let _0x391921;if(_0x16f3a1['activeChange']=_0x2bfbef?_0x16f3a1['diff']['changes']['get'](_0x2d6c1f+this['_step']):_0x16f3a1['diff']['changes']['first'],_0x16f3a1['activeChange']['data']['isOnRoot'])_0x391921=_0x2902f9['editing']['view']['getDomRoot'](_0x16f3a1['activeChange']['rootName']);else{const _0xdfbb75=_0x2902f9['model']['markers']['get']('revision:'+_0x16f3a1['activeChange']['id']);_0x391921=_0x5b2979(_0x2902f9['editing'],_0xdfbb75);}_0x47b4d2({'target':_0x391921,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x13a5cc,currentChangeNumber:_0x692dfd,numberOfChanges:_0x4ac6b2,isReady:_0x89b8c,isEnabled:_0x9b5018}=this['editor']['plugins']['get'](m);this['isEnabled']=!!(_0x9b5018&&_0x89b8c&&_0x4ac6b2)&&(!_0x13a5cc||(0x1===this['_step']?_0x692dfd<_0x4ac6b2-0x1:_0x692dfd>0x0));}}class _i extends ts{constructor(_0x18983a){super(_0x18983a);const _0x48f58a=this['bindTemplate'],_0x4d8ce4=new te(_0x18983a),_0x4627df=new te(_0x18983a);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',(_0x419542,_0x52f120)=>_0x419542&&_0x52f120>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x2ae850,_0x2d8317,_0x508e65,_0x4dc1de)=>{if(!_0x2ae850)return g(_0x18983a,'Loading...');if(!_0x508e65)return g(_0x18983a,'No\x20changes');const _0x3e1935=g(_0x18983a,'NUMBER_OF_CHANGES',_0x508e65);return _0x4dc1de?g(_0x18983a,'X_OF_Y_CHANGES',[_0x2d8317+0x1,_0x508e65]):_0x3e1935;}),_0x4d8ce4['set']({'label':g(_0x18983a,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x157ddd}),_0x4627df['set']({'label':g(_0x18983a,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x577587}),_0x4d8ce4['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x4627df['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x4d8ce4['on']('execute',()=>this['fire']('execute','backward')),_0x4627df['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',_0x48f58a['if']('_isStatusLabelVisible','ck-hidden',_0x59cff6=>!_0x59cff6)]},'children':[{'text':_0x48f58a['to']('isNavigationMode',_0x3ec7fd=>_0x3ec7fd?g(_0x18983a,'EDIT_X_OF_Y_REVISIONS')+':\x20':g(_0x18983a,'Total')+':\x20')}]},{'text':_0x48f58a['to']('_statusText')}]},new _0x2f1e4b(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x4d8ce4,_0x4627df]}]});}}const le='ck-editor__editable__loading-overlay';class ge extends _0x527fd9{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x464daa=this['editor']['editing']['view'];_0x464daa['change'](_0x1ef803=>{for(const _0x1f4796 of _0x464daa['document']['roots'])_0x1ef803['addClass'](le,_0x1f4796);});}['hide'](){const _0x5e9186=this['editor']['editing']['view'];_0x5e9186['change'](_0x3535d2=>{for(const _0x3b5e57 of _0x5e9186['document']['roots'])_0x3535d2['removeClass'](le,_0x3b5e57);});}}class R extends _0x527fd9{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[m,ge];}['init'](){const _0xc18f7f=this['editor'],_0x191463=_0xc18f7f['plugins']['get'](m),_0x40015e=_0xc18f7f['plugins']['get'](ge);_0xc18f7f['ui']['componentFactory']['add']('exitToEditing',_0x2b1c1d=>{const _0x13ecdd=new te(_0x2b1c1d);return _0x13ecdd['set']({'label':g(_0x2b1c1d,'Back\x20to\x20editing'),'icon':_0x42d483,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x13ecdd,'execute',()=>{_0xc18f7f['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x13ecdd;}),_0xc18f7f['ui']['componentFactory']['add']('restoreRevision',_0x24b2a9=>{const _0x328dfa=new te(_0x24b2a9);return _0x328dfa['set']({'label':g(_0x24b2a9,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x328dfa['bind']('isEnabled')['to'](_0xc18f7f['commands']['get']('restoreRevision')),this['listenTo'](_0x328dfa,'execute',()=>_0xc18f7f['execute']('restoreRevision')),_0x328dfa;}),_0xc18f7f['ui']['componentFactory']['add']('changesNavigation',_0x5bab2d=>{const _0x3a7217=new _i(_0x5bab2d),_0x5007ec=_0xc18f7f['commands']['get']('showPreviousChange'),_0x1d91da=_0xc18f7f['commands']['get']('showNextChange');return _0x3a7217['bind']('isBackwardNavigationEnabled')['to'](_0x5007ec,'isEnabled'),_0x3a7217['bind']('isForwardNavigationEnabled')['to'](_0x1d91da,'isEnabled'),_0x3a7217['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x191463),this['listenTo'](_0x3a7217,'execute',(_0x5f5bd4,_0x38da09)=>{_0xc18f7f['execute']('forward'===_0x38da09?'showNextChange':'showPreviousChange');}),_0x3a7217;}),_0x40015e['show'](),_0x191463['on']('change:isReady',(_0x3be478,_0x2bf95e,_0x20c766)=>{_0x20c766?_0x40015e['hide']():_0x40015e['show']();});}}class at extends _0x4a54d4{['_resizeObserver']=null;constructor(_0xeaf4e5,_0x556b6a){super(_0xeaf4e5,_0x556b6a);const _0x1b177f=this['bindTemplate'];this['set']({'label':g(_0xeaf4e5,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=g(_0xeaf4e5,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x1b177f['to']('_tooltipString'),'data-cke-tooltip-position':'s','data-cke-tooltip-class':'ck-tooltip_multi-line'}});}['render'](){super['render'](),this['_resizeObserver']=new nt(this['fieldView']['element'],()=>this['_updateTooltipText']()),this['listenTo'](this['fieldView'],'input',()=>this['_updateTooltipText']());}['destroy'](){super['destroy'](),this['_resizeObserver']&&this['_resizeObserver']['destroy']();}['_updateTooltipText'](){const _0x21b878=this['fieldView']['element'];this['_tooltipString']=_0x21b878['scrollWidth']>_0x21b878['clientWidth']&&_0x21b878['value']||'';}}class si extends ts{constructor(_0x5cb450,_0x1c32b1,_0x42c249){super(_0x5cb450);const _0x32c643=new _0x226077();_0x32c643['set']({'content':_0x594709,'viewBox':'0\x200\x2011\x2010'});const _0x399691=['ck','ck-revision-history-sidebar__revision-author'];_0x42c249&&_0x399691['push']('ck-revision-history-sidebar__revision-author_creator');const _0x577c93=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':g(_0x5cb450,_0x42c249?'Revision\x20creator':'Revision\x20author')},'children':[_0x32c643,_0x1c32b1['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x399691},'children':_0x577c93});}}function oi(_0x2cbca3,_0x4202e2){const _0x23ce54=_0x2cbca3['bindTemplate'],_0x209843=_0x2cbca3['locale'],_0x31201b=_0x2bb1f1(_0x209843);_0x31201b['panelPosition']='sw';const _0x971c67=function(_0xf56ed5,_0x46471d){const _0x565a00=function(_0x51203a,_0xff4db8){const _0x45ec51=_0x51203a['locale'],_0xaec155={'Compare\x20against\x20selected':g(_0x45ec51,'Compare\x20against\x20selected'),'Name\x20this\x20revision':g(_0x45ec51,'Name\x20this\x20revision'),'Restore\x20this\x20revision':g(_0x45ec51,'Restore\x20this\x20revision')};return _0xff4db8['map'](_0x28420b=>{const _0x316dba=_0xaec155[_0x28420b['name']];return _0x316dba&&_0x316dba!==_0x28420b['name']&&(_0x28420b['name']=_0x316dba),_0x28420b;});}(_0xf56ed5,_0x46471d),_0x417525=new _0x3f8e7a();for(const _0x1fac61 of _0x565a00){const _0x25906a={'type':'button','model':new to({'label':_0x1fac61['name'],'class':_0x1fac61['class'],'withText':!0x0,'role':'menuitem','_action':_0x1fac61['action']})};_0x25906a['model']['bind']('isEnabled')['to'](_0xf56ed5,'isActionsDropdownOpen',_0x226431=>'function'!=typeof _0x1fac61['isEnabled']||(!_0x226431||_0x1fac61['isEnabled'](_0xf56ed5))),_0x417525['add'](_0x25906a);}return _0x417525;}(_0x2cbca3,_0x4202e2);return _0x2cbca3['bind']('isActionsDropdownOpen')['to'](_0x31201b,'isOpen'),_0x31201b['buttonView']['set']({'label':g(_0x209843,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x14de33}),_0x31201b['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x23ce54['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x23ce54['to'](_0x5e4434=>_0x5e4434['stopPropagation']())}}),_0x31201b['on']('execute',_0x36705e=>{_0x2cbca3['isReady']&&'function'==typeof _0x36705e['source']['_action']&&_0x36705e['source']['_action'](_0x2cbca3);}),_0x43d39a(_0x31201b,_0x971c67,{'role':'menu'}),_0x31201b['listenTo'](_0x2cbca3,'change:isActionsDropdownOpen',(_0x40c076,_0xde275d,_0x4fc435)=>{if(_0x4fc435)for(const _0x3a59d6 of _0x31201b['listView']['items']){const _0x176a4e=_0x3a59d6['children']['first'],_0x17ba6b=_0x4202e2['find'](_0x249e50=>_0x249e50['action']===_0x176a4e['_action'])['isVisible'];_0x3a59d6['isVisible']=void 0x0===_0x17ba6b||_0x17ba6b(_0x2cbca3);}}),_0x31201b;}class hi extends/* #__PURE__ -- @preserve */
|
|
26
|
-
|
|
23
|
+
import{ObservableMixin as _0x1a0236,uid as _0x335623,Collection as _0x3b3f60,logWarning as _0x223dbb,FocusTracker as _0x3d5f91,KeystrokeHandler as _0x583348,scrollViewportToShowTarget as _0x2b83d3,ResizeObserver as nt,ElementReplacer as ot,CKEditorError as _0x382e41}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x25c995,set as _0x18567d,unset as _0x23a879,isEqual as _0xf42df9}from'es-toolkit/compat';import{Plugin as _0x215f3d,PendingActions as _0x23f0a8,Command as _0x209300,ElementApiMixin as _0x33a608,Editor as _0x180b1b}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x1efa5c,getMarkerDomElement as _0x1a9bee,ConfirmMixin as _0x3e9bdc,sanitizeEditorConfig as _0x16f0f7}from'ckeditor5-collaboration/dist/index.js';import{ViewContainerElement as _0x15f24b,ViewAttributeElement as _0x5946e2,ViewEmptyElement as _0x2065b8,ViewRawElement as _0x501869,ViewUIElement as _0x4a6e43,ViewDocumentFragment as _0x12e64f,ViewText as _0x2e1387,ViewElement as _0x204b8d,Element as ut,Range as lt,Position as ft,DocumentFragment as vt,Text as gt}from'@ckeditor/ckeditor5-engine/dist/index.js';import{IconHistory as _0x14d782,IconChevronUp as _0x314266,IconChevronDown as _0x1ae486,IconUndo as _0x1a92ae,IconUser as _0xcd8008,IconThreeVerticalDots as _0x57e1b8}from'@ckeditor/ckeditor5-icons/dist/index.js';import{View as ts,injectCssTransitionDisabler as _0x25b1f2,submitHandler as _0x50411b,LabeledFieldView as _0x53f8a9,createLabeledInputText as _0x33ff0f,createDropdown as _0x41d57a,ListView as _0x21eec4,ListItemView as _0xbcd986,ButtonView as te,MenuBarMenuView as _0x3cb039,MenuBarMenuListView as _0x34a253,MenuBarMenuListItemView as _0x4b57e6,MenuBarMenuListItemButtonView as _0x51584f,ContextualBalloon as _0x5401b0,ToolbarSeparatorView as _0x49f084,IconView as _0x4d07d2,addListToDropdown as _0x31792c,ViewModel as to,EditorUI as st,normalizeToolbarConfig as et,BoxedEditorUIView as rt,StickyPanelView as ht,ToolbarView as dt,InlineEditableUIView as ct}from'@ckeditor/ckeditor5-ui/dist/index.js';import{DateTime as _0x5e9815}from'luxon';class h extends/* #__PURE__ -- @preserve */
|
|
24
|
+
_0x1a0236(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x2c36aa){super(),this['id']=_0x2c36aa['id']||_0x335623(),this['creator']=_0x2c36aa['creator']||null,this['authors']=_0x2c36aa['authors']||[],this['diffData']=_0x2c36aa['diffData']||null,this['toVersion']=_0x2c36aa['toVersion']||0x0,this['fromVersion']=_0x2c36aa['fromVersion']||0x0,this['set']('name',_0x2c36aa['name']||''),this['set']('createdAt',_0x2c36aa['createdAt']||new Date()),this['set']('attributes',_0x2c36aa['attributes']||{});}['setName'](_0x1a6298){this['_update']({'name':_0x1a6298});}['setAttribute'](_0x3fb2e6,_0xc02ce9){const _0x1614f1=_0x25c995(this['attributes']);_0x18567d(_0x1614f1,_0x3fb2e6,_0xc02ce9),this['_update']({'attributes':_0x1614f1});}['removeAttribute'](_0xc6948c){const _0x29c86b=_0x25c995(this['attributes']);_0x23a879(_0x29c86b,_0xc6948c),this['_update']({'attributes':_0x29c86b});}['_update'](_0x3fa65b,_0x419545=!0x1){let _0x20136b=!0x1;const _0x3c6d17={'id':this['id']},_0x484e6c=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x7e0c7e of _0x484e6c){const _0x13736d=_0x3fa65b[_0x7e0c7e];void 0x0!==_0x13736d&&_0x13736d!==this[_0x7e0c7e]&&(this[_0x7e0c7e]=_0x13736d,_0x3c6d17[_0x7e0c7e]=_0x13736d,_0x20136b=!0x0);}_0x20136b&&(_0x3c6d17['authors']&&(_0x3c6d17['authorsIds']=_0x3c6d17['authors']['map'](_0x260c50=>_0x260c50['id']),delete _0x3c6d17['authors']),this['fire']('_update',_0x3c6d17,_0x419545));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x5d0612=>_0x5d0612['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class I extends _0x215f3d{['_revisions'];static get['requires'](){return[_0x1efa5c];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x18abe6){super(_0x18abe6),this['_revisions']=new _0x3b3f60();}['afterInit'](){!async function(_0x14594b){const _0x4afd28=_0x386b0c([0x5a,0x72,0x6e,0x54,0x74,0x32,0x62,0x6f,0x48,0x51,0x30,0x56,0x71,0x67,0x33,0x7a,0x73,0x44,0x69,0x46,0x53,0x64,0x45,0x77,0x6c,0x39,0x57,0x4a,0x4c,0x4d,0x43,0x68,0x34,0x6d,0x58,0x4f,0x6a,0x50,0x31,0x78,0x61,0x4e,0x59,0x70,0x47,0x41,0x55,0x75,0x79,0x49,0x35,0x65,0x36,0x4b,0x66,0x63,0x6b,0x42,0x38,0x76,0x37,0x52]),_0x180735=0xeb829,_0xaf5918=0x36bc9b11,_0x473f43=0x36bbfca9^_0xaf5918,_0x8ffc35=window[_0x386b0c([0x44,0x61,0x74,0x65])][_0x386b0c([0x6e,0x6f,0x77])](),_0x34fec8=_0x14594b[_0x386b0c([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x2735fb=new window[(_0x386b0c([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x42a4f1=>{_0x34fec8[_0x386b0c([0x6f,0x6e,0x63,0x65])](_0x386b0c([0x72,0x65,0x61,0x64,0x79]),_0x42a4f1);}),_0x70747d={[_0x386b0c([0x6b,0x74,0x79])]:_0x386b0c([0x45,0x43]),[_0x386b0c([0x75,0x73,0x65])]:_0x386b0c([0x73,0x69,0x67]),[_0x386b0c([0x63,0x72,0x76])]:_0x386b0c([0x50,0x2d,0x32,0x35,0x36]),[_0x386b0c([0x78])]:_0x386b0c([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]),[_0x386b0c([0x79])]:_0x386b0c([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]),[_0x386b0c([0x61,0x6c,0x67])]:_0x386b0c([0x45,0x53,0x32,0x35,0x36])},_0x38d1c7=_0x34fec8[_0x386b0c([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x386b0c([0x67,0x65,0x74])](_0x386b0c([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x267c78(){let _0x58ef18,_0x980717=null,_0x565d62=null;try{if(_0x38d1c7==_0x386b0c([0x47,0x50,0x4c]))return _0x386b0c([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x58ef18=_0x315cba(),!_0x58ef18)return _0x386b0c([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x58ef18[_0x386b0c([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x565d62=_0x4e8268(_0x58ef18[_0x386b0c([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x58ef18[_0x386b0c([0x6a,0x74,0x69])])),await _0x36be25()?_0x13ec46()?_0x3554a0()?_0x386b0c([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x5caf85()?(_0x58ef18[_0x386b0c([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x386b0c([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x980717=_0x31fd7a(_0x386b0c([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x58ef18[_0x386b0c([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x386b0c([0x74,0x72,0x69,0x61,0x6c])&&(_0x980717=_0x31fd7a(_0x386b0c([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x25af09()):_0x386b0c([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x386b0c([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x386b0c([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch(_0x2623a6){return _0x386b0c([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x3554a0(){const _0x364077=[_0x386b0c([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x386b0c([0x74,0x72,0x69,0x61,0x6c])][_0x386b0c([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x58ef18[_0x386b0c([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x8ffc35/0x3e8:0xe10*_0x473f43;return _0x58ef18[_0x386b0c([0x65,0x78,0x70])]<_0x364077;}function _0x13ec46(){const _0x10046c=_0x58ef18[_0x386b0c([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x10046c)return!0x1;if(_0x10046c[_0x386b0c([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x386b0c([0x2a])))return!0x0;if(_0x10046c[_0x386b0c([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x386b0c([0x52,0x48])))return!0x0;if(_0x10046c[_0x386b0c([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x386b0c([0x52,0x52,0x48]))){if(_0x1ea812())return!0x0;if(_0x7480d()||_0x394e0b())return!0x0;}return!0x1;}function _0x5caf85(){const _0x2717bb=_0x58ef18[_0x386b0c([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x2717bb||0x0==_0x2717bb[_0x386b0c([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x360d1a}=new URL(window[_0x386b0c([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x2717bb[_0x386b0c([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x360d1a))return!0x0;const _0x3c9ed5=_0x360d1a[_0x386b0c([0x73,0x70,0x6c,0x69,0x74])](_0x386b0c([0x2e]));return _0x2717bb[_0x386b0c([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x2531e2=>_0x2531e2[_0x386b0c([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x386b0c([0x2a])))[_0x386b0c([0x6d,0x61,0x70])](_0x3790f4=>_0x3790f4[_0x386b0c([0x73,0x70,0x6c,0x69,0x74])](_0x386b0c([0x2e])))[_0x386b0c([0x73,0x6f,0x6d,0x65])](_0x4cabbd=>_0x3c9ed5[_0x386b0c([0x65,0x76,0x65,0x72,0x79])]((_0x135999,_0x35acaa)=>_0x4cabbd[_0x35acaa]===_0x135999||_0x4cabbd[_0x35acaa]===_0x386b0c([0x2a])));}function _0x25af09(){return _0x980717&&_0x565d62?new window[(_0x386b0c([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x48e0bb,_0x4ec57d)=>{_0x980717[_0x386b0c([0x74,0x68,0x65,0x6e])](_0x48e0bb,_0x4ec57d),_0x565d62[_0x386b0c([0x74,0x68,0x65,0x6e])](_0xe1b56c=>{_0xe1b56c!=_0x386b0c([0x56,0x61,0x6c,0x69,0x64])&&_0x48e0bb(_0xe1b56c);},_0x4ec57d);}):_0x980717||_0x565d62||_0x386b0c([0x56,0x61,0x6c,0x69,0x64]);}}function _0x4e8268(_0x5212a1,_0x4740ee){return new window[(_0x386b0c([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2461cb=>{if(_0x300537())return _0x2461cb(_0x386b0c([0x56,0x61,0x6c,0x69,0x64]));_0x844af7(),_0x34fec8[_0x386b0c([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x386b0c([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x289002=!0x1;const _0xc719a1=_0x335623();function _0x2a4e92(_0x10aa75){return!!_0x10aa75&&(typeof _0x10aa75===_0x386b0c([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x10aa75===_0x386b0c([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x10aa75[_0x386b0c([0x74,0x68,0x65,0x6e])]===_0x386b0c([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x10aa75[_0x386b0c([0x63,0x61,0x74,0x63,0x68])]===_0x386b0c([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x52fae6(_0x4ed1eb){_0x527fc8(_0x4ed1eb)[_0x386b0c([0x74,0x68,0x65,0x6e])](_0x56cb36=>{if(!_0x56cb36||_0x56cb36[_0x386b0c([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x386b0c([0x6f,0x6b]))return _0x386b0c([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0xd12c68(_0x1ea4a9(_0xc719a1+_0x4740ee))!=_0x56cb36[_0x386b0c([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x386b0c([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x386b0c([0x56,0x61,0x6c,0x69,0x64]);})[_0x386b0c([0x74,0x68,0x65,0x6e])](_0x4720ca=>(_0x16ee47(),_0x4720ca),()=>{const _0x3d4424=_0x2c9021();return null==_0x3d4424?(_0x16ee47(),_0x386b0c([0x56,0x61,0x6c,0x69,0x64])):_0x386b0c(_0x8ffc35-_0x3d4424>(0x12b01f11^_0xaf5918)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x386b0c([0x74,0x68,0x65,0x6e])](_0x2461cb)[_0x386b0c([0x63,0x61,0x74,0x63,0x68])](()=>{_0x2461cb(_0x386b0c([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x1bbe7f=0x368a7591^_0xaf5918;function _0x16ee47(){const _0x23d18e=_0x386b0c([0x6c,0x6c,0x63,0x74,0x2d])+_0xd12c68(_0x1ea4a9(_0x5212a1)),_0x2a20d9=_0x3735fb(_0xd12c68(window[_0x386b0c([0x4d,0x61,0x74,0x68])][_0x386b0c([0x63,0x65,0x69,0x6c])](_0x8ffc35/_0x1bbe7f)));window[_0x386b0c([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x386b0c([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x23d18e,_0x2a20d9);}function _0x2c9021(){const _0x3df395=_0x386b0c([0x6c,0x6c,0x63,0x74,0x2d])+_0xd12c68(_0x1ea4a9(_0x5212a1)),_0x470684=window[_0x386b0c([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x386b0c([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x3df395);return _0x470684?window[_0x386b0c([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x3735fb(_0x470684),0x10)*_0x1bbe7f:null;}function _0x527fc8(_0x24a231){return new window[(_0x386b0c([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x21a8fc,_0x117e27)=>{_0x24a231[_0x386b0c([0x74,0x68,0x65,0x6e])](_0x21a8fc,_0x117e27),window[_0x386b0c([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x117e27,0x36bd4fd1^_0xaf5918);});}}_0x34fec8[_0x386b0c([0x6f,0x6e])](_0x386b0c([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x91ddc1,_0x1aae29)=>{if(_0x1aae29[0x0]!=_0x5212a1)return _0x2461cb(_0x386b0c([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x1aae29[0x1]={..._0x1aae29[0x1],[_0x386b0c([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0xc719a1};},{[_0x386b0c([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x386b0c([0x68,0x69,0x67,0x68])}),_0x34fec8[_0x386b0c([0x6f,0x6e])](_0x386b0c([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x10a55a=>{_0x2a4e92(_0x10a55a[_0x386b0c([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x289002=!0x0,_0x52fae6(_0x10a55a[_0x386b0c([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x386b0c([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x386b0c([0x6c,0x6f,0x77])}),_0x2735fb[_0x386b0c([0x74,0x68,0x65,0x6e])](()=>{_0x289002||_0x2461cb(_0x386b0c([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x300537(){return _0x34fec8[_0x386b0c([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x386b0c([0x76,0x69,0x65,0x77])][_0x386b0c([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x386b0c([0x61,0x75,0x74,0x6f]);}function _0x844af7(){_0x34fec8[_0x386b0c([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x386b0c([0x76,0x69,0x65,0x77])][_0x386b0c([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x386b0c([0x61,0x75,0x74,0x6f]);}}function _0x31fd7a(_0x3e053a){const _0x516652=[new window[(_0x386b0c([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x3a4b3c=>setTimeout(_0x3a4b3c,0x36b5a5dd^_0xaf5918)),_0x2735fb[_0x386b0c([0x74,0x68,0x65,0x6e])](()=>new window[(_0x386b0c([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x1b8da3=>{const _0xd2b6ca=0x36bc9b16^_0xaf5918,_0x3ccb9e=_0x14594b[_0x386b0c([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x2d57dc(){_0x3ccb9e[_0x386b0c([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0xd2b6ca&&_0x1b8da3();}_0x2d57dc(),_0x3ccb9e[_0x386b0c([0x6f,0x6e])](_0x386b0c([0x61,0x64,0x64]),_0x2d57dc);})),new window[(_0x386b0c([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x55d044=>{function _0x468511(){for(const _0x1de420 in window)if(window[_0x386b0c([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x386b0c([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x1de420))&&window[_0x1de420]==_0x180735)return _0x55d044();_0x34fec8[_0x386b0c([0x73,0x74,0x61,0x74,0x65])]!=_0x386b0c([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x386b0c([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x468511,0x36bc8899^_0xaf5918);}_0x27fccc(_0x386b0c([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x468511();})];return window[_0x386b0c([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x386b0c([0x72,0x61,0x63,0x65])](_0x516652)[_0x386b0c([0x74,0x68,0x65,0x6e])](()=>_0x3e053a);}async function _0xbbbdc2(){if(await _0x2735fb,_0x27fccc(_0x386b0c([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x21c26b=_0x14594b[_0x386b0c([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x490ffd=_0x14594b[_0x386b0c([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])](_0x21c26b[_0x386b0c([0x69,0x64])]),_0xe42292=_0xf349fe(_0x386b0c([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0xe42292[_0x386b0c([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x21c26b['id'],_0x490ffd?_0x490ffd['id']:null,!0x0),_0xe42292[_0x386b0c([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x386b0c([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0xe42292[_0x386b0c([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0xe42292[_0x386b0c([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x13664a,void(_0xe42292[_0x386b0c([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x13664a);}if(_0x27fccc(_0x386b0c([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x465a3c=_0xf349fe(_0x386b0c([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x465a3c[_0x386b0c([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x386b0c([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x465a3c[_0x386b0c([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x465a3c[_0x386b0c([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x13664a,_0x465a3c[_0x386b0c([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x13664a;}_0x34fec8[_0x386b0c([0x6d,0x6f,0x64,0x65,0x6c])][_0x386b0c([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x13664a,_0x34fec8[_0x386b0c([0x6d,0x6f,0x64,0x65,0x6c])][_0x386b0c([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x13664a,_0x34fec8[_0x386b0c([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x386b0c([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x1ea812(){return _0x27fccc(_0x386b0c([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0xf349fe(_0x386b0c([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x386b0c([0x73,0x74,0x61,0x74,0x65])]==_0x386b0c([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x7480d(){return _0x27fccc(_0x386b0c([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 _0x394e0b(){return _0x27fccc(_0x386b0c([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x81db4(_0x16246f){const _0xa34784=_0x25e0e0();_0x34fec8[_0xa34784]=_0x386b0c([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])+_0x16246f,_0x16246f[_0x386b0c([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x386b0c([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x25e0e0()]=_0x180735),_0x16246f!=_0x386b0c([0x56,0x61,0x6c,0x69,0x64])&&_0xbbbdc2();}function _0x25e0e0(){const _0x3ed3c1=window[_0x386b0c([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x386b0c([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x386b0c([0x6e,0x6f,0x77])]())[_0x386b0c([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x386b0c([0x2e]),'');let _0x683b8f=_0x386b0c([0x5a]);for(let _0x595a47=0x0;_0x595a47<_0x3ed3c1[_0x386b0c([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x595a47+=0x2){let _0x1a2fda=window[_0x386b0c([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x3ed3c1[_0x386b0c([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x595a47,_0x595a47+0x2));_0x1a2fda>=_0x4afd28[_0x386b0c([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x1a2fda-=_0x4afd28[_0x386b0c([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x683b8f+=_0x4afd28[_0x1a2fda];}return _0x683b8f;}function _0x315cba(){const _0x21c5d7=_0x38d1c7[_0x386b0c([0x73,0x70,0x6c,0x69,0x74])](_0x386b0c([0x2e]));if(0x3!=_0x21c5d7[_0x386b0c([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x2b85e6(_0x21c5d7[0x1]);function _0x2b85e6(_0xef9f6d){const _0x5f0c3d=_0x5b28ab(_0xef9f6d);return _0x5f0c3d&&_0x4c3b4b()?_0x5f0c3d:null;function _0x4c3b4b(){const _0x5b133e=_0x5f0c3d[_0x386b0c([0x6a,0x74,0x69])],_0x34d961=window[_0x386b0c([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x5b133e[_0x386b0c([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x5b133e[_0x386b0c([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x121d48={..._0x5f0c3d,[_0x386b0c([0x6a,0x74,0x69])]:_0x5b133e[_0x386b0c([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x5b133e[_0x386b0c([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x121d48[_0x386b0c([0x76,0x63])],_0x1ea4a9(_0x121d48)==_0x34d961;}}}async function _0x36be25(){let _0x11be14=!0x0;try{const _0x10c688=_0x38d1c7[_0x386b0c([0x73,0x70,0x6c,0x69,0x74])](_0x386b0c([0x2e])),[_0x7be484,_0xc5eca1,_0x44859d]=_0x10c688;return _0x2b1c99(_0x7be484),await _0x13a158(_0x7be484,_0xc5eca1,_0x44859d),_0x11be14;}catch(_0x2c7327){return!0x1;}function _0x2b1c99(_0x36be5e){const _0x372f46=_0x5b28ab(_0x36be5e);_0x372f46&&_0x372f46[_0x386b0c([0x61,0x6c,0x67])]==_0x386b0c([0x45,0x53,0x32,0x35,0x36])||(_0x11be14=!0x1);}async function _0x13a158(_0x5f2801,_0x284adc,_0x54404e){const _0xae9a33=window[_0x386b0c([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x386b0c([0x66,0x72,0x6f,0x6d])](_0x4429b6(_0x54404e),_0x38bb35=>_0x38bb35[_0x386b0c([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x55f15b=new window[(_0x386b0c([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x386b0c([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x5f2801+_0x386b0c([0x2e])+_0x284adc),_0x24bd32=window[_0x386b0c([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x386b0c([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x24bd32)return;const _0xd52f4c=await _0x24bd32[_0x386b0c([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x386b0c([0x6a,0x77,0x6b]),_0x70747d,{[_0x386b0c([0x6e,0x61,0x6d,0x65])]:_0x386b0c([0x45,0x43,0x44,0x53,0x41]),[_0x386b0c([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x386b0c([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x386b0c([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x24bd32[_0x386b0c([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x386b0c([0x6e,0x61,0x6d,0x65])]:_0x386b0c([0x45,0x43,0x44,0x53,0x41]),[_0x386b0c([0x68,0x61,0x73,0x68])]:{[_0x386b0c([0x6e,0x61,0x6d,0x65])]:_0x386b0c([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0xd52f4c,_0xae9a33,_0x55f15b)||(_0x11be14=!0x1);}}function _0x5b28ab(_0x149da5){return _0x149da5[_0x386b0c([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x386b0c([0x65,0x79]))?JSON[_0x386b0c([0x70,0x61,0x72,0x73,0x65])](_0x4429b6(_0x149da5)):null;}function _0x4429b6(_0x540ffb){return window[_0x386b0c([0x61,0x74,0x6f,0x62])](_0x540ffb[_0x386b0c([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x386b0c([0x2b]))[_0x386b0c([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x386b0c([0x2f])));}function _0x1ea4a9(_0x519ab2){let _0x35d539=0x1505;function _0xce56f3(_0x463ebe){for(let _0x7dd36f=0x0;_0x7dd36f<_0x463ebe[_0x386b0c([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x7dd36f++){const _0x19d306=_0x463ebe[_0x386b0c([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x7dd36f);_0x35d539=(_0x35d539<<0x5)+_0x35d539+_0x19d306,_0x35d539&=_0x35d539;}}function _0x28826e(_0x371cd0){Array[_0x386b0c([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x371cd0)?_0x371cd0[_0x386b0c([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x28826e):_0x371cd0&&typeof _0x371cd0==_0x386b0c([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x386b0c([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x371cd0)[_0x386b0c([0x73,0x6f,0x72,0x74])]()[_0x386b0c([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x24d509,_0x4bfb37])=>{_0xce56f3(_0x24d509),_0x28826e(_0x4bfb37);}):_0xce56f3(window[_0x386b0c([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x371cd0));}return _0x28826e(_0x519ab2),_0x35d539>>>0x0;}function _0xd12c68(_0x4dc006){return _0x4dc006[_0x386b0c([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x386b0c([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x386b0c([0x30]));}function _0x3735fb(_0x5c08b4){return _0x5c08b4[_0x386b0c([0x73,0x70,0x6c,0x69,0x74])]('')[_0x386b0c([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x386b0c([0x6a,0x6f,0x69,0x6e])]('');}function _0x27fccc(_0x415c8a){return _0x34fec8[_0x386b0c([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x386b0c([0x68,0x61,0x73])](_0x415c8a);}function _0xf349fe(_0x43ad45){return _0x34fec8[_0x386b0c([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x386b0c([0x67,0x65,0x74])](_0x43ad45);}function _0x13664a(){}function _0x386b0c(_0x5ac132){return _0x5ac132['map'](_0xd79ad6=>String['fromCharCode'](_0xd79ad6))['join']('');}_0x81db4(await _0x267c78());}(this);}['createRevision'](_0x11fd7e){const _0x51b820=this['editor']['plugins']['get']('Users');return new h({'id':_0x11fd7e['id'],'name':_0x11fd7e['name'],'creator':_0x11fd7e['creatorId']?_0x51b820['getUser'](_0x11fd7e['creatorId']):null,'diffData':_0x11fd7e['diffData']||_0x11fd7e['data'],'authors':_0x11fd7e['authorsIds']['map'](_0x1b2875=>_0x51b820['getUser'](_0x1b2875)),'createdAt':new Date(_0x11fd7e['createdAt']),'attributes':_0x11fd7e['attributes'],'fromVersion':_0x11fd7e['fromVersion'],'toVersion':_0x11fd7e['toVersion']});}['addRevision'](_0x22b97b,_0xc4e0e5=0x0){this['_revisions']['add'](_0x22b97b,_0xc4e0e5);}['getRevision'](_0x5b2994){return this['_revisions']['get'](_0x5b2994);}['getRevisions'](_0x5a275f={'toJSON':!0x1}){const _0x2e7e72=Array['from'](this['_revisions']);return _0x2e7e72['reverse'](),_0x5a275f['toJSON']?_0x2e7e72['map'](_0x533dfa=>_0x533dfa['toJSON']()):_0x2e7e72;}['getIndex'](_0x50c824){return this['_revisions']['getIndex'](_0x50c824);}['getEarlierVisibleRevision'](_0x57ac9a){const [,_0x106c52]=this['getRevisionsIterator'](_0x57ac9a,{'direction':'earlier'});return _0x106c52;}['getLaterVisibleRevision'](_0x1ce793){const [,_0x3c01fe]=this['getRevisionsIterator'](_0x1ce793,{'direction':'later'});return _0x3c01fe;}['getRevisionsInDiff'](_0x1cea82){const _0x1f420c=[];for(const _0x2eec60 of this['getRevisionsIterator'](_0x1cea82['newRevisionId']))if(_0x1f420c['push'](_0x2eec60),_0x2eec60['id']===_0x1cea82['oldRevisionId'])break;return _0x1f420c;}*['getRevisionsIterator'](_0x38b6a5,{direction:_0x1aa24a='earlier',filter:_0x38193c=()=>!0x0}={}){const _0xc0b25b='earlier'===_0x1aa24a?0x1:-0x1;let _0xb1ddad=this['_revisions']['get'](_0x38b6a5),_0x4e3f8e=this['getIndex'](_0xb1ddad);for(yield _0xb1ddad;_0xb1ddad;){if(_0x4e3f8e+=_0xc0b25b,_0xb1ddad=this['getRevision'](_0x4e3f8e),!_0xb1ddad)return;_0x38193c(_0xb1ddad)&&(yield _0xb1ddad);}}}class V extends _0x215f3d{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x15f24b,'c'],[_0x5946e2,'a'],[_0x2065b8,'e'],[_0x501869,'r'],[_0x4a6e43,'u']]);['_typeCharToViewClass']=new Map([['c',_0x15f24b],['a',_0x5946e2],['e',_0x2065b8],['r',_0x501869],['u',_0x4a6e43]]);async['loadRevisionData'](_0x32e951,_0x1c1dd8){if(_0x32e951['diffData']||!_0x1c1dd8)return;const _0x35f2a7=this['editor']['config']['get']('collaboration.channelId'),_0x2c8619=await _0x1c1dd8['getRevision']({'channelId':_0x35f2a7,'revisionId':_0x32e951['id']});_0x32e951['diffData']=_0x2c8619['diffData'];}['getRevisionDocumentData'](_0x311cc6){const _0x2a98ef={};for(const _0x2deda3 in _0x311cc6['diffData']){if(_0x311cc6['diffData'][_0x2deda3]['attachChange']&&!_0x311cc6['diffData'][_0x2deda3]['attachChange']['isAttached'])continue;const _0x51da3b=this['_removeRevisionMarkers'](JSON['parse'](_0x311cc6['diffData'][_0x2deda3]['insertions'])),_0x1623fb=this['editor']['editing']['view']['document'],_0x47012a=new _0x12e64f(_0x1623fb,_0x51da3b['map'](_0x3f061c=>this['_getViewFromDiffObj'](_0x3f061c,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x2a98ef[_0x2deda3]=this['editor']['data']['processor']['toData'](_0x47012a),this['editor']['data']['processor']['useFillerType']('default');}return _0x2a98ef;}['getRevisionRootsAttributes'](_0x4fc66a){const _0x5c5b9d={};for(const _0x491059 in _0x4fc66a['diffData'])_0x4fc66a['diffData'][_0x491059]['attachChange']&&!_0x4fc66a['diffData'][_0x491059]['attachChange']['isAttached']||(_0x5c5b9d[_0x491059]=_0x4fc66a['diffData'][_0x491059]['attributesAfter']||{});return _0x5c5b9d;}['_getTypeCharForViewElement'](_0x5aca2f){return this['_viewClassToTypeChar']['get'](_0x5aca2f['constructor']);}['_getViewFromDiffObj'](_0x4af402,_0x209e36){const _0x580b1a=this['editor']['editing']['view']['document'];if('string'==typeof _0x4af402)return new _0x2e1387(_0x580b1a,_0x4af402);{let _0x301726,_0x398728;_0x398728='u'==_0x4af402['type']||'r'==_0x4af402['type']?[]:_0x4af402['children']['map'](_0x47f511=>this['_getViewFromDiffObj'](_0x47f511,_0x209e36));const _0xb412b=this['_typeCharToViewClass']['get'](_0x4af402['type'])||_0x204b8d,_0x282a70=this['editor']['data']['htmlProcessor']['domConverter'];if(_0x301726=new _0xb412b(_0x580b1a,_0x4af402['name'],_0x4af402['attributes'],_0x398728),'u'==_0x4af402['type']&&_0x4af402['children'][0x0]){const _0x2da4ab=_0x4af402['children'][0x0];if(_0x301726['render']=function(_0x5e6ba5){const _0x5200a9=_0x5e6ba5['createElement']('div');return _0x5200a9['innerHTML']=_0x2da4ab,_0x5200a9['childNodes'][0x0];},_0x209e36){const _0x1a3057=new _0x12e64f(_0x580b1a);_0x1a3057['_appendChild'](_0x301726);const _0x14f837=Array['from'](_0x282a70['viewChildrenToDom'](_0x1a3057,{'bind':!0x1})),_0x5c3ccb=_0x282a70['domDocument']['createElement']('div');_0x5c3ccb['append'](..._0x14f837),_0x301726=Array['from'](_0x282a70['domChildrenToView'](_0x5c3ccb))[0x0];}}else{if('r'==_0x4af402['type']&&_0x4af402['children'][0x0]){const _0x20acc6=_0x4af402['children'][0x0];if(_0x301726['render']=function(_0x153aae){_0x153aae['innerHTML']=_0x20acc6;},_0x209e36){const _0xa62ac6=new _0x12e64f(_0x580b1a);_0xa62ac6['_appendChild'](_0x301726);const _0x49a9dd=Array['from'](_0x282a70['viewChildrenToDom'](_0xa62ac6,{'bind':!0x1})),_0x4ff72c=_0x282a70['domDocument']['createElement']('div');_0x4ff72c['append'](..._0x49a9dd);const _0x30c2b=Array['from'](_0x282a70['domChildrenToView'](_0x4ff72c));_0x30c2b['length']>0x1?_0x301726['_appendChild'](_0x30c2b):_0x301726=_0x30c2b[0x0];}}}if(_0x4af402['customProperties']){for(const [_0x147073,_0xa81481]of _0x4af402['customProperties'])_0x301726['_setCustomProperty'](_0x147073,_0xa81481);}const _0x132715=void 0x0===_0x4af402['fillerOffset']?null:_0x4af402['fillerOffset'];return null!==_0x132715&&(_0x301726['getFillerOffset']=()=>_0x132715),_0x301726;}}['_makeModelFromViewString'](_0xae7999){const _0x2b9f29=JSON['parse'](_0xae7999),_0x18043b=this['editor']['editing']['view']['document'],_0x58fcc0=new _0x12e64f(_0x18043b,_0x2b9f29['map'](_0x5ceb40=>this['_getViewFromDiffObj'](_0x5ceb40,!0x0)));return this['editor']['data']['toModel'](_0x58fcc0);}['_removeRevisionMarkers'](_0x4aaa89){return(_0x4aaa89=_0x4aaa89['filter'](_0xe65fad=>!_0xe65fad['name']||'revision-start'!==_0xe65fad['name']&&'revision-end'!==_0xe65fad['name']))['forEach'](_0x4edcb7=>{'string'!=typeof _0x4edcb7&&(_0x4edcb7['children']=this['_removeRevisionMarkers'](_0x4edcb7['children']),_0x4edcb7['attributes']=_0x4edcb7['attributes']['filter'](_0x295ac1=>!_0x295ac1[0x0]['startsWith']('data-revision-')));}),_0x4aaa89;}}function g(_0x2aea13,_0x59cff8,_0x5a1029){const t=_0x2aea13['t'];switch(_0x59cff8){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'},_0x5a1029);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x5a1029);case'Show\x20previous\x20change':return t('Show\x20previous\x20change');case'Show\x20next\x20change':return t('Show\x20next\x20change');case'EDIT_X_OF_Y_REVISIONS':return t({'string':'Edit','id':'EDIT_X_OF_Y_REVISIONS'});case'Total':return t('Total');case'Revision\x20creator':return t('Revision\x20creator');case'Revision\x20author':return t('Revision\x20author');case'Revision\x20name':return t('Revision\x20name');case'Save\x20current\x20revision':return t('Save\x20current\x20revision');case'Accept':return t('Accept');case'Save':return t('Save');case'Cancel':return t('Cancel');case'Name\x20of\x20the\x20revision':return t('Name\x20of\x20the\x20revision');case'optional':return t('optional');case'PENDING_ACTION_REVISION_HISTORY':return t({'string':'Unsaved\x20change\x20in\x20revision\x20history.','id':'PENDING_ACTION_REVISION_HISTORY'});case'The\x20revision\x20name\x20cannot\x20be\x20empty.':return t('The\x20revision\x20name\x20cannot\x20be\x20empty.');case'Enter\x20the\x20revision\x20name':return t('Enter\x20the\x20revision\x20name');default:return'';}}class u extends _0x215f3d{['licenseKey'];['_licenseKeyCheckInterval'];['currentRevision']=null;['repository'];['adapter']=null;['_revisionDataBuilder'];['_source'];['_initialRevisionId'];['_bufferedUpdates'];['_utils'];['_pendingAction'];['_continueCurrentRevision'];['_startingVersion'];['_loadedStateData'];static get['pluginName'](){return'RevisionTracker';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[_0x1efa5c,I,V,_0x23f0a8];}constructor(_0x477aea){super(_0x477aea),this['repository']=this['editor']['plugins']['get']('RevisionsRepository'),this['_utils']=this['editor']['plugins']['get']('RevisionHistoryUtils'),this['_revisionDataBuilder']=new x(this['editor']),this['_initialRevisionId']=this['editor']['config']['get']('collaboration.channelId')||'initial',this['_bufferedUpdates']=new Map(),this['_loadedStateData']=null;const _0x2bb52a=_0x335623();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x2bb52a},this['set']('isReady',!0x1),this['set']('isEnabled',!0x0),this['set']('_isPendingUpdate',!0x1),this['editor']['config']['define']('revisionHistory.resumeUnsavedRevision',!0x0),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'});}['init'](){this['_setConversion'](),this['editor']['data']['on']('ready',()=>{const _0xe362ff=this['repository']['getRevision'](0x0),_0x3149ef=_0xe362ff&&null===_0xe362ff['creator']?_0xe362ff:null;if(this['_continueCurrentRevision']=!!_0x3149ef&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x573a0c=this['_source']['getCurrentRevisionId'](),_0x58f01c=this['repository']['getRevision'](_0x573a0c);if(_0x58f01c)this['_startingVersion']=_0x58f01c['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x518c15=this['_source']['history']['_operations']['find'](_0x545472=>!_0x545472['_isInit']),_0x2ec8c4=_0x518c15?_0x518c15['baseVersion']:this['_source']['history']['version'];_0xe362ff?(_0xe362ff['toVersion']<_0x2ec8c4&&_0xe362ff['_update']({'toVersion':_0x2ec8c4}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x3149ef['id'],this['_startingVersion']=_0x3149ef['fromVersion']):(this['_startingVersion']=_0xe362ff['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x2ec8c4,this['_continueCurrentRevision']=!0x1);}}else _0x3149ef&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x3149ef['toVersion'],this['editor']['model']['document']['history']['version']),_0x3149ef['fromVersion']===_0x3149ef['toVersion']?(0x0!==_0x3149ef['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x3149ef['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x3149ef['id'],this['_startingVersion']=_0x3149ef['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',_0x1637b0=>!_0x1637b0),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x1ef8b7=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x4957b9;for(const _0x31545e in _0x1ef8b7){const _0x28e1a4=_0x31545e,_0x5ed9e4=_0x1ef8b7[_0x28e1a4];if('revisionHistoryLicenseKeyValid'==_0x5ed9e4||'revisionHistoryLicenseKeyInvalid'==_0x5ed9e4||'revisionHistoryLicenseKeyExpired'==_0x5ed9e4||'revisionHistoryLicenseKeyDomainLimit'==_0x5ed9e4||'revisionHistoryLicenseKeyNotAllowed'==_0x5ed9e4||'revisionHistoryLicenseKeyEvaluationLimit'==_0x5ed9e4||'revisionHistoryLicenseKeyTrialLimit'==_0x5ed9e4||'revisionHistoryLicenseKeyUsageLimit'==_0x5ed9e4){delete _0x1ef8b7[_0x28e1a4],_0x4957b9=_0x5ed9e4,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x4957b9&&_0x1ef8b7['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x4957b9&&_0x1ef8b7['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x4957b9&&_0x1ef8b7['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x4957b9&&_0x1ef8b7['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x4957b9&&_0x1ef8b7['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x4957b9&&_0x1ef8b7['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x4957b9&&_0x1ef8b7['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x1291a7=this['repository']['getRevision'](0x0),_0x27d2c2=await this['getRevisionDocumentData'](_0x1291a7),_0x11cd41=await this['getRevisionRootsAttributes'](_0x1291a7);this['_replaceEditorDataWithRevisionData'](_0x27d2c2,_0x11cd41);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x517a5d){this['_source']=_0x517a5d;}async['update'](){const _0x15a05b=await this['_source']['getLatestVersion']();if(_0x15a05b>this['currentRevision']['toVersion']){await this['_loadState']();const _0x36fce2=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x15a05b});_0x36fce2['authors']=_0x36fce2['authorsIds']['map'](_0x1392d3=>this['editor']['plugins']['get']('Users')['getUser'](_0x1392d3)),this['currentRevision']['_update'](_0x36fce2);}}async['saveRevision'](_0x2afc6e={},_0x18d4d0=null){const _0xc66a54=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x18d4d0>this['currentRevision']['toVersion']&&(_0x18d4d0=null),null===_0x18d4d0&&(_0x18d4d0=await this['_source']['getLatestVersion']());const _0x457953=this['_getFromVersion'](_0x18d4d0),_0x12470d=this['buildRevisionData']({'from':_0x457953,'to':_0x18d4d0});if(this['currentRevision']['toVersion']<_0x18d4d0){const _0x23b956=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x18d4d0,'to':_0x18d4d0});_0x23b956['authors']=[],_0x23b956['authorsIds']=[],_0x23b956['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x23b956,!0x0),delete _0x23b956['authors'],_0xc66a54['push'](_0x23b956);}_0x2afc6e['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x2afc6e['name']=_0x2afc6e['name']||null,_0x2afc6e['id']=_0x2afc6e['id']||_0x335623(),_0x2afc6e={..._0x2afc6e,..._0x12470d};const _0x597ba8=this['addRevisionData'](_0x2afc6e);_0xc66a54['push'](_0x2afc6e);const _0x7fc491=this['repository']['getIndex'](_0x597ba8);if(0x0!==_0x7fc491){const _0x508861=this['repository']['getRevision'](_0x7fc491-0x1);if(_0x508861['fromVersion']!==_0x18d4d0){const _0x255559=this['_revisionDataBuilder']['getData'](_0x18d4d0,_0x508861['toVersion']),_0x295919={'id':_0x508861['id'],'diffData':_0x255559['diffData'],'authorsIds':_0x255559['authorsIds'],'authors':_0x255559['authorsIds']['map'](_0x1d5ec1=>this['editor']['plugins']['get']('Users')['getUser'](_0x1d5ec1)),'fromVersion':_0x18d4d0};_0x508861===this['currentRevision']&&(_0x295919['createdAt']=new Date(_0x2afc6e['createdAt']['getTime']()+0xa)),_0x508861['_update'](_0x295919,!0x0),delete _0x295919['authors'],_0xc66a54['push'](_0x295919);}}if(this['adapter']){for(const _0x1114f8 of _0xc66a54)this['_bufferUpdate'](_0x1114f8['id'],_0x1114f8,!0x0);this['sendBufferedUpdates']();}return _0x597ba8;}['addRevisionData'](_0x2f7885){const _0x51bc38=this['repository']['createRevision'](_0x2f7885);return this['adapter']&&_0x51bc38['on']('_update',(_0x1ebe60,_0x59e2e0,_0x3bb40d)=>{_0x3bb40d||(this['_bufferUpdate'](_0x59e2e0['id'],_0x59e2e0,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x51bc38,this['_findInsertionIndex'](_0x51bc38)),_0x51bc38;}async['getRevisionDocumentData'](_0x3e2942){return await this['_utils']['loadRevisionData'](_0x3e2942,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x3e2942);}async['getRevisionRootsAttributes'](_0x224d7b){return await this['_utils']['loadRevisionData'](_0x224d7b,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x224d7b);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x4545b8=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x31ab4f=0x0;_0x31ab4f<_0x4545b8['length'];_0x31ab4f++){const _0x4af8ef=_0x4545b8[_0x31ab4f];let _0x35b950=!0x1;for(const _0x2dc392 of Object['keys'](_0x4af8ef))void 0x0===_0x4af8ef[_0x2dc392]?delete _0x4af8ef[_0x2dc392]:'id'!==_0x2dc392&&(_0x35b950=!0x0);_0x35b950||(_0x4545b8[_0x31ab4f]=null);}if(_0x4545b8=_0x4545b8['filter'](_0x5962e4=>null!==_0x5962e4),!_0x4545b8['length'])return;for(let _0x5e3da6=0x0;_0x5e3da6<_0x4545b8['length'];_0x5e3da6++){const _0x3b568e=_0x4545b8[_0x5e3da6];void 0x0!==_0x3b568e['fromVersion']&&void 0x0===_0x3b568e['toVersion']&&(_0x3b568e['toVersion']=this['repository']['getRevision'](_0x3b568e['id'])['toVersion']),void 0x0!==_0x3b568e['toVersion']&&void 0x0===_0x3b568e['fromVersion']&&(_0x3b568e['fromVersion']=this['repository']['getRevision'](_0x3b568e['id'])['fromVersion']);}const _0x53c2de=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x4545b8,_0x53c2de)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x2e34dd=>{if(_0x2e34dd){for(const _0x170eb8 of _0x2e34dd)this['setRevisionData']({'id':_0x170eb8['id'],'createdAt':_0x170eb8['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0x10de7e=null,from:_0x1e6efa=null,to:_0x55e1fd=null}){_0x1e6efa=null!==_0x1e6efa?_0x1e6efa:_0x10de7e['fromVersion'],_0x55e1fd=null!==_0x55e1fd?_0x55e1fd:_0x10de7e['toVersion'];const _0x14a586=this['_revisionDataBuilder']['getData'](_0x1e6efa,_0x55e1fd),_0x5ad0c2={'diffData':_0x14a586['diffData'],'authorsIds':_0x14a586['authorsIds'],'fromVersion':_0x1e6efa,'toVersion':_0x55e1fd};if(!_0x10de7e||_0x55e1fd!==_0x10de7e['toVersion']){const _0x110d72=_0x55e1fd-0x1,_0x353bba=this['_source']['history']['getOperation'](_0x110d72);_0x5ad0c2['createdAt']=_0x353bba&&_0x353bba['createdAt']||new Date();}if(this['_loadedStateData']&&_0x1e6efa===this['_loadedStateData']['fromVersion']){for(const _0x49ec15 of this['_loadedStateData']['authors'])_0x5ad0c2['authorsIds']['includes'](_0x49ec15['id'])||_0x5ad0c2['authorsIds']['push'](_0x49ec15['id']);}return _0x5ad0c2;}['_bufferUpdate'](_0x33ec95,_0x1facdb,_0x4864a7){if(this['_bufferedUpdates']['has'](_0x33ec95)){const _0x4234f6=this['_bufferedUpdates']['get'](_0x33ec95);_0x1facdb=_0x4864a7?{..._0x4234f6,..._0x1facdb}:{..._0x1facdb,..._0x4234f6};}this['_bufferedUpdates']['set'](_0x33ec95,_0x1facdb);}['setRevisionData'](_0x284cf0){const _0x54bf8b=this['repository']['getRevision'](_0x284cf0['id']);if(_0x284cf0['createdAt']&&(_0x284cf0['createdAt']=new Date(_0x284cf0['createdAt'])),_0x284cf0['authorsIds']){const _0xa67d99=this['editor']['plugins']['get']('Users');_0x284cf0['authors']=_0x284cf0['authorsIds']['map'](_0xb3b1d9=>_0xa67d99['getUser'](_0xb3b1d9));}_0x54bf8b['_update'](_0x284cf0,!0x0);}['_createInitialRevision'](_0x411a19){const _0x440078=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x440078)this['_initialRevisionId']=_0x440078['id'];else{const _0x52df6a=!this['editor']['model']['document']['roots']['find'](_0x861855=>this['editor']['model']['hasContent'](_0x861855)),_0x5d8871=this['editor']['plugins']['get']('Users')['me']['id'],_0x56f9c1=g(this['editor']['locale'],_0x52df6a?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x411a19,'to':_0x411a19,'id':this['_initialRevisionId'],'name':_0x56f9c1,'creatorId':_0x5d8871});}}['_createCurrentRevision'](_0x3b2b60){const _0x8e36eb=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x8e36eb),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x3b2b60,'to':_0x3b2b60,'id':_0x8e36eb,'name':'','creatorId':null}));}async['_loadState'](){this['_continueCurrentRevision']&&!this['_loadedStateData']&&(await this['_utils']['loadRevisionData'](this['currentRevision'],this['adapter']),this['_revisionDataBuilder']['loadState'](this['currentRevision']),this['_loadedStateData']={'fromVersion':this['currentRevision']['fromVersion'],'authors':this['currentRevision']['authors']['slice']()});}['_replaceEditorDataWithRevisionData'](_0x1bcdc8,_0x37f80c){let _0x4555cb=this['editor']['config']['get']('initialData'),_0x5a23d5=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x4555cb){_0x4555cb={};for(const _0x558216 of this['editor']['model']['document']['getRootNames']())_0x4555cb[_0x558216]='';}if('string'==typeof _0x4555cb&&(_0x4555cb={'main':_0x4555cb}),void 0x0===_0x5a23d5){_0x5a23d5={};for(const _0x3926c6 of this['editor']['model']['document']['getRootNames']())_0x5a23d5[_0x3926c6]={};}let _0x57a604=!0x1;const _0x43e347=Object['keys'](_0x4555cb),_0x8b3aa5=Object['keys'](_0x1bcdc8);for(const _0x2cf1ba of _0x43e347){if(_0x4555cb[_0x2cf1ba]!==_0x1bcdc8[_0x2cf1ba]&&''!==_0x4555cb[_0x2cf1ba]['trim']()){_0x57a604=!0x0;break;}if(!_0xf42df9(_0x5a23d5[_0x2cf1ba],_0x37f80c[_0x2cf1ba])&&Object['keys'](_0x5a23d5[_0x2cf1ba])['length']>0x0){_0x57a604=!0x0;break;}}_0x57a604||(_0x57a604=_0x8b3aa5['some'](_0x4acd88=>!this['editor']['model']['document']['getRoot'](_0x4acd88))),_0x57a604&&_0x223dbb('editor-initial-data-replaced-with-revision-data',{'editorData':_0x4555cb,'editorRootsAttributes':_0x5a23d5,'revisionData':_0x1bcdc8,'revisionRootsAttributes':_0x37f80c}),this['editor']['config']['set']('initialData',_0x1bcdc8),this['editor']['config']['set']('rootsAttributes',_0x37f80c);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x12d69b=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x12d69b['add'](g(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0xa87917){const _0x56203a=this['repository']['getRevisions']();_0x56203a['reverse']();let _0x193483=0x0;for(;_0x193483<_0x56203a['length'];){const _0x523058=_0x56203a[_0x193483];if(_0x523058===this['currentRevision']){_0x193483++;continue;}if(_0x523058['id']===this['_initialRevisionId'])break;const _0x3255e8=_0xa87917['toVersion']-_0x523058['toVersion']||_0xa87917['fromVersion']-_0x523058['fromVersion'];if(_0x3255e8>0x0)break;if(_0x3255e8<0x0)_0x193483++;else{if(!_0xa87917['creator']&&_0x523058['creator'])break;if(_0x523058['creator']||!_0xa87917['creator']){if(_0xa87917['createdAt']>_0x523058['createdAt'])break;_0x193483++;}else _0x193483++;}}return _0x193483;}['_getFromVersion'](_0xed989e){const _0x157b1a=this['repository']['getRevisions']();_0x157b1a['reverse'](),_0x157b1a['shift']();const _0x9cd9a4=_0x157b1a['find'](_0x58318c=>_0x58318c['toVersion']<=_0xed989e)['toVersion'];return _0x9cd9a4<this['_startingVersion']?this['_startingVersion']:_0x9cd9a4;}['_makeRevision']({name:_0x10290b,from:_0x29d036,to:_0x24d72d,creatorId:_0xaf2fb9,id:_0x4726f2}){const _0x4df6b4=this['buildRevisionData']({'from':_0x29d036,'to':_0x24d72d});_0x4df6b4['name']=_0x10290b,_0x4df6b4['creatorId']=_0xaf2fb9,_0x4df6b4['id']=_0x4726f2;const _0xed83c2=this['addRevisionData'](_0x4df6b4);return this['adapter']&&this['_bufferUpdate'](_0x4df6b4['id'],_0x4df6b4,!0x0),_0xed83c2;}['_setConversion'](){this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'});}}class x{['editor'];['source'];['_savedMetaData'];['_lastFrom'];['_lastTo'];['_markers'];['_diffRoots'];['_diffRootsAttributes'];['_baseRoots'];['_baseRootsAttributes'];['_idsRoots'];['_baseIdsRoots'];['_touched'];['_touchedMarkers'];['_touchedRoots'];['_revisionId'];['_startingRevisionId'];constructor(_0x4c04fa){this['editor']=_0x4c04fa,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'](_0x5120cb){this['source']=_0x5120cb;const _0xc04b3d=new Map(),_0x1126db=new Map(),_0x1c773a=this['editor']['model']['document']['roots']['map'](_0x25edd6=>_0x25edd6['rootName']);for(const _0x34a53f of _0x1c773a){const _0x323e56=this['editor']['model']['document']['getRoot'](_0x34a53f),_0x3cffb7=N(_0x323e56);_0xc04b3d['set'](_0x34a53f,_0x3cffb7),_0x1126db['set'](_0x34a53f,Object['fromEntries'](_0x323e56['getAttributes']()));}const _0x5079b3=Array['from'](this['editor']['model']['markers'])['map'](_0x49502d=>[_0x49502d['name'],_0x49502d['getRange']()]),_0x3c92c2=this['source']['version'];this['_saveMetaData'](_0x3c92c2,_0xc04b3d,_0x5079b3,_0x1126db),this['_startingRevisionId']=this['_revisionId'];const _0x6ba6e=new Map(),_0x23dbe5=new Map();for(const _0x5e2131 of _0x1c773a){const _0xaa6ce2=P(_0x5e2131);_0x6ba6e['set'](_0x5e2131,_0xaa6ce2),_0x23dbe5['set'](_0x5e2131,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x6ba6e,[],_0x23dbe5);}['getData'](_0x28902c,_0x2fe3fe){if(this['_lastFrom']===_0x28902c&&this['_lastTo']<=_0x2fe3fe)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x2fe3fe,!0x0);else{if(!this['_savedMetaData']['has'](_0x28902c)){const _0x25893a=this['_getPreviousFrom'](_0x28902c);this['_calculateMetaData'](_0x25893a,_0x28902c,!0x1);}this['_calculateMetaData'](_0x28902c,_0x2fe3fe,!0x0);}return this['_lastFrom']=_0x28902c,this['_lastTo']=_0x2fe3fe,this['_getState']();}['loadState'](_0x1179ca){const _0x1a8346=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x1179ca['fromVersion'],this['_lastTo']=_0x1179ca['toVersion'];for(const _0x73737 in _0x1179ca['diffData']){const _0x5b0269=_0x1179ca['diffData'][_0x73737]['attachChange'],_0x3a3656=_0x25c995(_0x1179ca['diffData'][_0x73737]['attributesBefore'])||{},_0x3abb0f=_0x1a8346['_makeModelFromViewString'](_0x1179ca['diffData'][_0x73737]['deletions']);_0x3abb0f['rootName']=_0x73737,_0x3abb0f['_isAttached']=!_0x5b0269||!_0x5b0269['isAttached'],_0x3abb0f['isAttached']=()=>_0x3abb0f['_isAttached'],this['_baseRoots']['set'](_0x73737,_0x3abb0f),this['_baseRootsAttributes']['set'](_0x73737,_0x3a3656),_0x5b0269&&this['_touchedRoots']['set'](_0x73737,_0x5b0269);const _0x2691c0=this['_makeIdsRoot'](_0x3abb0f);this['_baseIdsRoots']['set'](_0x73737,_0x2691c0);for(const [_0x5d4685,_0x2fef9b]of _0x3abb0f['markers']){if(!_0x5d4685['startsWith']('revision:'))continue;const _0x1e7141=_0x5d4685['split'](':')[0x2];for(const _0x45f5fa of _0x2fef9b['getWalker']({'singleCharacters':!0x0})){const _0x452f6c=this['_getVidAttributeName'](_0x45f5fa),_0x15d8e6='elementEnd'==_0x45f5fa['type']?_0x45f5fa['previousPosition']['path']['slice'](0x0,-0x1):_0x45f5fa['previousPosition']['path'],_0x5c6f0d=_0x2691c0['getNodeByPath'](_0x15d8e6)['getAttribute'](_0x452f6c);this['_touched']['set'](_0x5c6f0d,{'userId':_0x1e7141});}}}this['_startingRevisionId']=this['_revisionId'];const _0x4ac088=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x551f63=>!this['_touched']['has'](_0x551f63));let _0xdf3893=0x0;const _0x387b01=new Map();for(const _0x599360 in _0x1179ca['diffData']){const _0x3c19a3=_0x1179ca['diffData'][_0x599360]['attachChange'],_0x21e6ec=_0x25c995(_0x1179ca['diffData'][_0x599360]['attributesAfter'])||{},_0x38ca7f=_0x1a8346['_makeModelFromViewString'](_0x1179ca['diffData'][_0x599360]['insertions']);_0x38ca7f['rootName']=_0x599360,_0x38ca7f['_isAttached']=!_0x3c19a3||_0x3c19a3['isAttached'],_0x38ca7f['isAttached']=()=>_0x38ca7f['_isAttached'],this['_diffRoots']['set'](_0x599360,_0x38ca7f),this['_diffRootsAttributes']['set'](_0x599360,_0x21e6ec);const _0x5a73ac=this['_makeIdsRoot'](_0x38ca7f,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x599360,_0x5a73ac),_0x387b01['set'](_0x599360,_0x38ca7f['isAttached']()?_0x21e6ec:{});for(const [_0x358dad,_0x4e88e1]of _0x38ca7f['markers']){if(!_0x358dad['startsWith']('revision:'))continue;const _0x388827=_0x358dad['split'](':')[0x2];for(const _0x4e6ee7 of _0x4e88e1['getWalker']({'singleCharacters':!0x0})){const _0x33fa1b=this['_getVidAttributeName'](_0x4e6ee7),_0x16b1bf=this['_revisionId']++,_0x4f710f='elementEnd'==_0x4e6ee7['type']?_0x4e6ee7['previousPosition']['path']['slice'](0x0,-0x1):_0x4e6ee7['previousPosition']['path'];_0x5a73ac['getNodeByPath'](_0x4f710f)['_setAttribute'](_0x33fa1b,_0x16b1bf),this['_touched']['set'](_0x16b1bf,{'userId':_0x388827});}}for(const _0x2bbb20 of this['editor']['model']['createRangeIn'](_0x38ca7f)['getWalker']({'singleCharacters':!0x0})){const _0x458ba9=this['_getVidAttributeName'](_0x2bbb20),_0x2900fb='elementEnd'==_0x2bbb20['type']?_0x2bbb20['previousPosition']['path']['slice'](0x0,-0x1):_0x2bbb20['previousPosition']['path'],_0x2e9a18=_0x5a73ac['getNodeByPath'](_0x2900fb);_0x2e9a18['getAttribute'](_0x458ba9)>0x0||_0x2e9a18['_setAttribute'](_0x458ba9,_0x4ac088[_0xdf3893++]);}for(const [_0x4bd67,_0x5335cf]of _0x38ca7f['markers'])_0x4bd67['startsWith']('revision:')||this['_markers']['set'](_0x4bd67,_0x5335cf);}const _0x4bf626=P('$graveyard');this['_baseRoots']['set']('$graveyard',_0x4bf626),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x4bf626,0x1));const _0x32c9aa=P('$graveyard');this['_diffRoots']['set']('$graveyard',_0x32c9aa),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x32c9aa,0x1));const _0x34a0f6=Array['from'](this['_diffRoots'])['map'](([_0x344654,_0x2d4cd1])=>[_0x344654,N(_0x2d4cd1)]);this['_saveMetaData'](this['_lastTo'],_0x34a0f6,this['_markers'],_0x387b01);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0x1e984e,_0xefeb57,_0x390152,_0x482da2){const _0x32f7c3=new Map(_0xefeb57),_0x5e75f4=new Map(_0x25c995(_0x482da2)),_0x4772b3=new Map();for(const [_0x3436cc,_0x5f5685]of _0x390152)_0x4772b3['set'](_0x3436cc,{'start':_0x5f5685['start']['clone'](),'end':_0x5f5685['end']['clone'](),'rootName':_0x5f5685['root']['rootName']});this['_savedMetaData']['set'](_0x1e984e,{'roots':_0x32f7c3,'markers':_0x4772b3,'rootsAttributes':_0x5e75f4});}['_removeMetaData'](_0x2229f6){this['_savedMetaData']['delete'](_0x2229f6);}['_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'](_0x4f99ab,_0x9e87d3=null){let _0x3d76b9=null;_0x4f99ab['is']('documentFragment')||(_0x3d76b9=new ut(_0x4f99ab['name'],{'vid_start':null===_0x9e87d3?this['_revisionId']++:_0x9e87d3++}));const _0x2efa4c=[];for(const _0x12fbad of _0x4f99ab['getChildren']())if(_0x12fbad['is']('element')){_0x2efa4c['push'](this['_makeIdsRoot'](_0x12fbad,_0x9e87d3));const _0xb652=_0x2efa4c[_0x2efa4c['length']-0x1];null!==_0x9e87d3&&(_0x9e87d3=_0xb652['is']('element','$text')?_0xb652['getAttribute']('vid')+0x1:_0xb652['getAttribute']('vid_end')+0x1);}else{for(let _0x170b52=0x0;_0x170b52<_0x12fbad['offsetSize'];_0x170b52++)_0x2efa4c['push'](new ut('$text',{'vid':null===_0x9e87d3?this['_revisionId']++:_0x9e87d3++}));}if(_0x4f99ab['is']('documentFragment')){const _0x13966c=P(_0x4f99ab['rootName']);return _0x13966c['_insertChild'](0x0,_0x2efa4c),_0x13966c;}return _0x3d76b9['_setAttribute']('vid_end',null===_0x9e87d3?this['_revisionId']++:_0x9e87d3++),_0x3d76b9['_insertChild'](0x0,_0x2efa4c),_0x3d76b9;}['_calculateMetaData'](_0x2abfc6,_0xcd5ef1,_0x1b164f){this['_reset']();const {roots:_0xea737f,markers:_0xf50550,rootsAttributes:_0x3e6f14}=this['_savedMetaData']['get'](_0x2abfc6);this['_baseRoots']=new Map(_0xea737f),this['_baseRootsAttributes']=new Map(_0x25c995(_0x3e6f14));for(const [_0x2af116,_0x37706c]of this['_baseRoots'])if('$graveyard'!==_0x2af116&&(this['_diffRoots']['set'](_0x2af116,N(_0x37706c)),this['_diffRootsAttributes']=new Map(_0x25c995(_0x3e6f14)),_0x1b164f)){const _0x2011dc=this['_revisionId'];this['_idsRoots']['set'](_0x2af116,this['_makeIdsRoot'](_0x37706c)),this['_baseIdsRoots']['set'](_0x2af116,this['_makeIdsRoot'](_0x37706c,_0x2011dc));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',N(this['_baseRoots']['get']('$graveyard'))),_0x1b164f&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x38e2e5,_0x3d1390]of _0xf50550){const _0xe60c6c=this['_baseRoots']['get'](_0x3d1390['rootName']),_0x5bfda3=this['_diffRoots']['get'](_0x3d1390['rootName']),_0x5b8dc5=new lt(this['_fixPosition'](_0x3d1390['start'],_0xe60c6c),this['_fixPosition'](_0x3d1390['end'],_0xe60c6c)),_0xc9ed2e=this['_fixRange'](_0x5b8dc5,_0x5bfda3);_0xe60c6c['markers']['set'](_0x38e2e5,_0x5b8dc5),this['_markers']['set'](_0x38e2e5,_0xc9ed2e);}this['_applyOperations'](_0x2abfc6,_0xcd5ef1,_0x1b164f);}['_applyOperations'](_0x22fb97,_0x4b83e0,_0x3cfddc){for(const _0x5989eb of this['source']['getOperations'](_0x22fb97,_0x4b83e0))this['_handleOperation'](_0x5989eb,_0x3cfddc);for(const _0x5c868c of this['_diffRoots']['values']())_0x5c868c['markers']['clear']();for(const [_0x5eb9d1,_0x24d1f6]of this['_markers']){this['_diffRoots']['get'](_0x24d1f6['root']['rootName'])['markers']['set'](_0x5eb9d1,_0x24d1f6['clone']());}const _0x273477=new Map(),_0x24c3d5=new Map();for(const [_0x3cd6f,_0x3becf5]of this['_diffRoots'])_0x273477['set'](_0x3cd6f,N(_0x3becf5)),_0x24c3d5['set'](_0x3cd6f,this['_diffRootsAttributes']['get'](_0x3cd6f));this['_saveMetaData'](_0x4b83e0,_0x273477,this['_markers'],_0x24c3d5);}['_getPreviousFrom'](_0x154033){const _0x5401cf=Array['from'](this['_savedMetaData']['keys']());_0x5401cf['sort']((_0x42b91b,_0x403ccf)=>_0x42b91b-_0x403ccf),_0x5401cf['reverse']();for(const _0x178476 of _0x5401cf)if(_0x178476<_0x154033)return _0x178476;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x3abc87,_0x1ec519){const _0x1fc907=Array['from'](_0x1ec519['markers'])['map'](([_0x18e322,_0x51bc2e])=>[_0x18e322,this['_fixRange'](_0x51bc2e,_0x3abc87)]);_0x3abc87['markers']=new Map(_0x1fc907);}['_transformMarkers'](_0x3eab88){for(const _0xba8b0b of this['_markers']['values']()){const _0x1850bd=_0xba8b0b['getTransformedByOperation'](_0x3eab88),_0x233d72=lt['_createFromRanges'](_0x1850bd);_0xba8b0b['start']=_0x233d72['start'],_0xba8b0b['end']=_0x233d72['end'];}}['_handleOperation'](_0x13f00c,_0x285104){if('addRoot'!=_0x13f00c['type']&&'detachRoot'!=_0x13f00c['type']){if('insert'==_0x13f00c['type']){const _0x12a8a8=_0x13f00c['position']['root']['rootName'];this['_diffRoots']['has'](_0x12a8a8)||(this['_diffRoots']['set'](_0x12a8a8,P(_0x12a8a8,!0x0)),this['_diffRootsAttributes']['set'](_0x12a8a8,{}),_0x285104&&this['_idsRoots']['set'](_0x12a8a8,P(_0x12a8a8,!0x0)));}else{if('addRootAttribute'==_0x13f00c['type']||'removeRootAttribute'==_0x13f00c['type']||'changeRootAttribute'==_0x13f00c['type'])return void this['_handleRootAttributeOperation'](_0x13f00c);'marker'==_0x13f00c['type']&&this['_handleMarkerOperation'](_0x13f00c);}if('marker'!==_0x13f00c['type']){const _0x66bcf=this['_cloneOperation'](_0x13f00c,this['_diffRoots']);_0x66bcf['_execute'](),this['_transformMarkers'](_0x66bcf);}if(_0x285104)switch(_0x13f00c['type']){case'insert':this['_handleInsertOperation'](_0x13f00c);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x13f00c);break;case'merge':this['_handleMergeOperation'](_0x13f00c);break;case'split':this['_handleSplitOperation'](_0x13f00c);}}else this['_handleRootOperation'](_0x13f00c,_0x285104);}['_cloneOperation'](_0x47c126,_0x14aca0){const _0x3725da=_0x47c126['clone']();return _0x3725da['_authorId']=_0x47c126['_authorId'],this['_fixOperation'](_0x3725da,_0x14aca0),_0x3725da;}['_getBaseVids'](_0x109ba9){return _0x109ba9['map'](_0x2cc91d=>{const _0x644a53=this['_getVidAttributeName'](_0x2cc91d);return Number(_0x2cc91d['item']['getAttribute'](_0x644a53));});}['_generateTape'](_0x46fea3,_0x12680d){if(_0x46fea3['is']('element','$text'))_0x12680d['push']({'item':_0x46fea3,'type':'text'});else{_0x46fea3['is']('element')&&_0x12680d['push']({'item':_0x46fea3,'type':'elementStart'});for(const _0x4adbe3 of _0x46fea3['getChildren']())this['_generateTape'](_0x4adbe3,_0x12680d);_0x46fea3['is']('element')&&_0x12680d['push']({'item':_0x46fea3,'type':'elementEnd'});}return _0x12680d;}['_getState'](){const _0x354dc7=new Map(this['_touched']),_0x47144c=new Map(_0x354dc7),_0x464adf=new Map(),_0x13f58e={'insertions':{},'deletions':{}},_0x538d61={'insertions':{},'deletions':{}},_0x3973ff=new Map(),_0x505d5e=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x505d5e['delete']('$graveyard');for(const _0x4087f8 of _0x505d5e){const _0x33aa2a=this['_diffRoots']['get'](_0x4087f8)||P(_0x4087f8,!0x1),_0xb17227=this['_baseRoots']['get'](_0x4087f8)||P(_0x4087f8,!0x1);_0x33aa2a['isAttached']()||_0xb17227['isAttached']()?(_0x13f58e['insertions'][_0x4087f8]=N(_0x33aa2a),_0x13f58e['deletions'][_0x4087f8]=N(_0xb17227),this['_copyMarkers'](_0x13f58e['deletions'][_0x4087f8],_0xb17227),this['_copyMarkers'](_0x13f58e['insertions'][_0x4087f8],_0x33aa2a),_0x538d61['insertions'][_0x4087f8]=this['_generateTape'](this['_idsRoots']['get'](_0x4087f8),[]),_0x538d61['deletions'][_0x4087f8]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x4087f8)||P(_0x4087f8,!0x1),[])):_0x505d5e['delete'](_0x4087f8);}for(const _0x275d40 of _0x505d5e){const _0x24c96b=_0x538d61['insertions'][_0x275d40];for(const _0x578276 of _0x24c96b){const _0x42567a=this['_getVidAttributeName'](_0x578276),_0x3abb74=_0x578276['item']['getAttribute'](_0x42567a);_0x47144c['delete'](_0x3abb74),_0x3abb74>=this['_startingRevisionId']&&_0x464adf['set'](_0x3abb74,_0x354dc7['get'](_0x3abb74));}}for(const _0x3d2ee7 of _0x505d5e){const _0x2fa0a3=_0x538d61['insertions'][_0x3d2ee7],_0x24e41f=this['_getBaseVids'](_0x538d61['deletions'][_0x3d2ee7]);let _0xe18952=0x0;for(const _0x3da0fc of _0x2fa0a3){const _0x586cf1=this['_getVidAttributeName'](_0x3da0fc),_0x3ff1e9=_0x3da0fc['item']['getAttribute'](_0x586cf1);if(!_0x464adf['has'](_0x3ff1e9)&&!_0x3973ff['has'](_0x3ff1e9)){if(_0x47144c['has'](_0x3ff1e9))_0xe18952++;else{if(_0x3ff1e9!=_0x24e41f[_0xe18952]){const _0x3ccf81=_0x354dc7['get'](_0x3ff1e9)||_0x354dc7['get'](_0x24e41f[_0xe18952]);for(;_0x3ff1e9!=_0x24e41f[_0xe18952];)_0x47144c['has'](_0x24e41f[_0xe18952])||(_0x3973ff['set'](_0x24e41f[_0xe18952],_0x3ccf81),_0x354dc7['set'](_0x24e41f[_0xe18952],_0x3ccf81)),_0xe18952++;}_0xe18952++;}}}}for(const _0x2c23ba of _0x505d5e){const _0x2f8e78=_0x538d61['insertions'][_0x2c23ba];for(const _0x58c871 of _0x2f8e78){const _0x39ce01=this['_getVidAttributeName'](_0x58c871),_0x3635f0=_0x58c871['item']['getAttribute'](_0x39ce01);if(_0x3973ff['has'](_0x3635f0)){const _0x41af37=_0x3973ff['get'](_0x3635f0);_0x47144c['has'](_0x3635f0)||_0x47144c['set'](_0x3635f0,{..._0x41af37}),_0x464adf['set'](_0x3635f0,{..._0x41af37});}}}for(const _0x19d768 of _0x47144c['keys']())_0x19d768>=this['_startingRevisionId']&&_0x47144c['delete'](_0x19d768);const _0x3d3078=new Map();for(const _0x599b7e of _0x505d5e){let _0x1723d9=_0x538d61['insertions'][_0x599b7e];for(const _0x3e4a1f of _0x1723d9)if(_0x3e4a1f['item']['is']('element','tableCell')){const _0x2156d7=this['_getVidAttributeName'](_0x3e4a1f),_0x3e7dd9=_0x3e4a1f['item']['getAttribute'](_0x2156d7);if(_0x464adf['has'](_0x3e7dd9)){const _0x3f4ed1=_0x3e4a1f['item']['parent']['parent']['getAttribute']('vid_start'),_0x3aaff5=_0x3d3078['get'](_0x3f4ed1)||new Set();_0x3aaff5['add'](_0x464adf['get'](_0x3e7dd9)['userId']),_0x3d3078['set'](_0x3f4ed1,_0x3aaff5);}}_0x1723d9=_0x538d61['deletions'][_0x599b7e];for(const _0x1507c4 of _0x1723d9)if(_0x1507c4['item']['is']('element','tableCell')){const _0x23ec8d=this['_getVidAttributeName'](_0x1507c4),_0x465afe=_0x1507c4['item']['getAttribute'](_0x23ec8d);if(_0x47144c['has'](_0x465afe)){const _0x130d09=_0x1507c4['item']['parent']['parent']['getAttribute']('vid_start'),_0x4ac467=_0x3d3078['get'](_0x130d09)||new Set();_0x4ac467['add'](_0x47144c['get'](_0x465afe)['userId']),_0x3d3078['set'](_0x130d09,_0x4ac467);}}for(const _0x4d7dca of _0x3d3078['keys']())(_0x464adf['has'](_0x4d7dca)||_0x47144c['has'](_0x4d7dca))&&_0x3d3078['delete'](_0x4d7dca);}for(const _0x334894 of _0x505d5e){const _0x45e9ef=_0x538d61['insertions'][_0x334894];let _0x369ef8=null,_0x72ce2d=null;for(const _0x8df839 of _0x45e9ef){const _0x45c1f0=this['_getVidAttributeName'](_0x8df839),_0x9a0bbe=_0x8df839['item']['getAttribute'](_0x45c1f0),_0x3794cb=_0x3d3078['get'](_0x9a0bbe);_0x3794cb&&'elementStart'==_0x8df839['type']&&(_0x369ef8=Array['from'](_0x3794cb)[0x0],_0x72ce2d=_0x8df839['item']['getAttribute']('vid_end')),_0x369ef8&&(_0x47144c['set'](_0x9a0bbe,{'userId':_0x369ef8}),_0x464adf['set'](_0x9a0bbe,{'userId':_0x369ef8})),_0x9a0bbe==_0x72ce2d&&(_0x369ef8=null,_0x72ce2d=null);}}const _0x4ef524={},_0xab38a5=new Set();for(const _0xf53f51 of _0x505d5e){const _0x30600d=_0x13f58e['deletions'][_0xf53f51],_0xb764f7=_0x13f58e['insertions'][_0xf53f51];for(const {userId:_0x521f89}of this['_touchedMarkers']['values']())null!==_0x521f89&&_0xab38a5['add'](_0x521f89);for(const {userId:_0xde5afc}of this['_touchedRoots']['values']())null!==_0xde5afc&&_0xab38a5['add'](_0xde5afc);this['_markChanges'](_0xb764f7,_0x538d61['insertions'][_0xf53f51],_0x464adf,'insertion',_0xab38a5),this['_markChanges'](_0x30600d,_0x538d61['deletions'][_0xf53f51],_0x47144c,'deletion',_0xab38a5),_0x4ef524[_0xf53f51]={'insertions':this['_prepareViewToSave'](_0xb764f7),'deletions':this['_prepareViewToSave'](_0x30600d),'attachChange':this['_touchedRoots']['get'](_0xf53f51)||null,'attributesBefore':_0x25c995(this['_baseRootsAttributes']['get'](_0xf53f51))||{},'attributesAfter':_0x25c995(this['_diffRootsAttributes']['get'](_0xf53f51))};}return{'diffData':_0x4ef524,'authorsIds':Array['from'](_0xab38a5)};}['_processRootBeforeSave'](_0x1d9ced){for(const [,_0x4f0624]of _0x1d9ced['markers']){const _0x19febb=_0x4f0624['start']['getAncestors']()['filter'](_0x4917d3=>'tableCell'==_0x4917d3['name']);for(const _0x48204f of _0x19febb)0x1==_0x48204f['childCount']&&_0x48204f['getChild'](0x0)['is']('element','paragraph')&&_0x48204f['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0xf5712){this['_processRootBeforeSave'](_0xf5712);const _0x4e06df=this['editor']['data']['toView'](_0xf5712,{}),_0x2a201c=Array['from'](_0x4e06df['getChildren']())['map'](_0x5792ed=>this['_getViewJson'](_0x5792ed));return JSON['stringify'](_0x2a201c);}['_getViewJson'](_0x41900e){if(_0x41900e['is']('$text'))return _0x41900e['data'];{const _0x520b47=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0x4fba9b=_0x41900e,_0x28647b=this['editor']['data']['htmlProcessor']['domConverter'],_0x30a975={'type':_0x520b47['_getTypeCharForViewElement'](_0x4fba9b),'name':_0x4fba9b['name'],'attributes':Array['from'](_0x4fba9b['getAttributes']()),'children':Array['from'](_0x4fba9b['getChildren']())['map'](_0x18ff13=>this['_getViewJson'](_0x18ff13))};if(_0x41900e['is']('uiElement')&&'$comment'!=_0x41900e['name']){const _0x404899=_0x41900e['render'](_0x28647b['domDocument'],_0x28647b);_0x30a975['children']['push'](_0x404899['outerHTML']);}else{if(_0x41900e['is']('rawElement')){const _0x2cae44=_0x28647b['domDocument']['createElement'](_0x4fba9b['name']);_0x41900e['render'](_0x2cae44,_0x28647b),_0x30a975['children']['push'](_0x2cae44['innerHTML']);}}const _0x355988=Array['from'](_0x4fba9b['getCustomProperties']());_0x355988['length']>0x0&&(_0x30a975['customProperties']=_0x355988);const _0x40d6b2=_0x4fba9b['getFillerOffset']();return null!==_0x40d6b2&&(_0x30a975['fillerOffset']=_0x40d6b2),_0x30a975;}}['_markChanges'](_0x10ef42,_0x5500ab,_0x5d4ded,_0x46f5d3,_0x37c1f2){let _0x3b17e1=null,_0x15c1d8=null,_0x292228=0x0;const _0x2d0ad8=this['editor']['model'];for(let _0x241c03=0x0;_0x241c03<_0x5500ab['length'];_0x241c03++){const _0x4f37a2=this['_getVidAttributeName'](_0x5500ab[_0x241c03]),_0x2c434d=_0x5500ab[_0x241c03]['item']['getAttribute'](_0x4f37a2),_0x106d43=_0x5d4ded['get'](_0x2c434d),_0x49bf25=_0x241c03==_0x5500ab['length']-0x1;(!_0x3b17e1&&_0x106d43&&(_0x3b17e1=_0x106d43,_0x15c1d8=_0x5500ab[_0x241c03]),_0x3b17e1&&(!_0x106d43||_0x106d43['userId']!=_0x3b17e1['userId']))&&(_0x2fbec5(_0x106d43,F(_0x15c1d8,_0x10ef42,_0x2d0ad8),F(_0x5500ab[_0x241c03],_0x10ef42,_0x2d0ad8)),_0x3b17e1=_0x106d43||null,_0x15c1d8=_0x106d43?_0x5500ab[_0x241c03]:null),_0x3b17e1&&_0x49bf25&&_0x2fbec5(_0x106d43,F(_0x15c1d8,_0x10ef42,_0x2d0ad8),B(_0x5500ab[_0x241c03],_0x10ef42,_0x2d0ad8));}function _0x2fbec5(_0x1b6153,_0xe05ac3,_0x100a92){const _0x2effbc=_0x3b17e1['userId'],_0x5da5f2='revision:'+_0x46f5d3+':'+_0x2effbc+':'+_0x292228++,_0x3d05e9=_0x2d0ad8['createRange'](_0xe05ac3,_0x100a92);_0x10ef42['markers']['set'](_0x5da5f2,_0x3d05e9),null!==_0x2effbc&&_0x37c1f2['add'](_0x2effbc);}}['_getVidAttributeName'](_0xfc135f){switch(_0xfc135f['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x4b8fb4,_0x4cbac9){_0x4b8fb4['baseVersion']=null;for(const _0x2fbbe0 in _0x4b8fb4){const _0x4b5d0a=_0x4b8fb4[_0x2fbbe0];if(_0x4b5d0a instanceof ft){const _0x49c01f=_0x4cbac9['get'](_0x4b5d0a['root']['rootName']);_0x4b8fb4[_0x2fbbe0]=this['_fixPosition'](_0x4b5d0a,_0x49c01f);}if(_0x4b5d0a instanceof lt){const _0x36a329=_0x4cbac9['get'](_0x4b5d0a['root']['rootName']);_0x4b8fb4[_0x2fbbe0]=this['_fixRange'](_0x4b5d0a,_0x36a329);}'root'===_0x2fbbe0&&(_0x4b8fb4['root']=_0x4cbac9['get'](_0x4b8fb4['root']['rootName']));}}['_fixRange'](_0x16d3e0,_0x2ceb92){return this['editor']['model']['createRange'](this['_fixPosition'](_0x16d3e0['start'],_0x2ceb92),this['_fixPosition'](_0x16d3e0['end'],_0x2ceb92));}['_fixPosition'](_0x2a3412,_0x2b6b51){return this['editor']['model']['createPositionFromPath'](_0x2b6b51,_0x2a3412['path'],_0x2a3412['stickiness']);}['_handleInsertOperation'](_0x1f3263){const _0x33c76e=this['_idsRoots']['get'](_0x1f3263['position']['root']['rootName']),_0x2125f0=this['_fixPosition'](_0x1f3263['position'],_0x33c76e),_0x578857=null===_0x1f3263['_authorId']?null:_0x1f3263['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x29f67f=_0x2125f0['parent'],_0x504074=this['_revisionId'],_0x3d40bf=[];for(const _0x3926ae of _0x1f3263['nodes'])if(_0x3926ae['is']('element'))_0x3d40bf['push'](this['_makeIdsRoot'](_0x3926ae));else{for(let _0x2003c2=0x0;_0x2003c2<_0x3926ae['offsetSize'];_0x2003c2++)_0x3d40bf['push'](new ut('$text',{'vid':this['_revisionId']++}));}const _0x39dc8a=this['_revisionId'];for(let _0x206df5=_0x504074;_0x206df5<_0x39dc8a;_0x206df5++)this['_touched']['set'](_0x206df5,{'userId':_0x578857});_0x29f67f['_insertChild'](_0x2125f0['offset'],_0x3d40bf);}['_handleMoveOperation'](_0x42fb48){(_0x42fb48=this['_cloneOperation'](_0x42fb48,this['_idsRoots']))['_execute']();const _0x409576=null===_0x42fb48['_authorId']?null:_0x42fb48['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x41ad12=_0x42fb48['getMovedRangeStart'](),_0x138513=_0x41ad12['parent'],_0x39af18=_0x41ad12['offset'];!function _0x4f49bb(_0x4bad2a,_0x48b6ef,_0xe7f4d,_0x2a4194){for(let _0x9bc8f6=_0xe7f4d;_0x9bc8f6<_0x2a4194;_0x9bc8f6++){const _0x146e81=_0x48b6ef['getChild'](_0x9bc8f6);_0x146e81['is']('element','$text')?_0x4bad2a['set'](_0x146e81['getAttribute']('vid'),{'userId':_0x409576}):(_0x4bad2a['set'](_0x146e81['getAttribute']('vid_start'),{'userId':_0x409576}),_0x4f49bb(_0x4bad2a,_0x146e81,0x0,_0x146e81['childCount']),_0x4bad2a['set'](_0x146e81['getAttribute']('vid_end'),{'userId':_0x409576}));}}(this['_touched'],_0x138513,_0x39af18,_0x39af18+_0x42fb48['howMany']);}['_handleMergeOperation'](_0x478f9a){const _0x5c34e4=null===(_0x478f9a=this['_cloneOperation'](_0x478f9a,this['_idsRoots']))['_authorId']?null:_0x478f9a['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x501d5d=_0x478f9a['targetPosition']['parent'],_0x11c400=_0x478f9a['sourcePosition']['parent'],_0x4c16ea=_0x501d5d['getAttribute']('vid_end'),_0x41448e=_0x11c400['getAttribute']('vid_start');_0x501d5d['_setAttribute']('vid_end',_0x11c400['getAttribute']('vid_end')),_0x11c400['_setAttribute']('vid_end',_0x4c16ea),this['_touched']['set'](_0x41448e,{'userId':_0x5c34e4}),this['_touched']['set'](_0x4c16ea,{'userId':_0x5c34e4}),_0x478f9a['_execute']();}['_handleSplitOperation'](_0x15da8b){const _0x137c93=null===(_0x15da8b=this['_cloneOperation'](_0x15da8b,this['_idsRoots']))['_authorId']?null:_0x15da8b['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x17bb4f=_0x15da8b['graveyardPosition'],_0xf48711=_0x15da8b['splitPosition']['parent'];_0x15da8b['_execute']();const _0x44a56e=_0xf48711['getAttribute']('vid_end'),_0x489215=_0x15da8b['insertionPosition']['nodeAfter'];if(_0x17bb4f){const _0x1b4a88=_0x489215['getAttribute']('vid_end'),_0x363f11=_0xf48711['getAttribute']('vid_end');_0xf48711['_setAttribute']('vid_end',_0x1b4a88),_0x489215['_setAttribute']('vid_end',_0x363f11),this['_touched']['set'](_0xf48711['getAttribute']('vid_end'),{'userId':_0x137c93}),this['_touched']['set'](_0x489215['getAttribute']('vid_start'),{'userId':_0x137c93});}else{const _0x5a878e=this['_revisionId']++,_0x41b7cb=this['_revisionId']++;_0xf48711['_setAttribute']('vid_end',_0x5a878e),_0x489215['_setAttribute']('vid_start',_0x41b7cb),_0x489215['_setAttribute']('vid_end',_0x44a56e),this['_touched']['set'](_0x5a878e,{'userId':_0x137c93}),this['_touched']['set'](_0x41b7cb,{'userId':_0x137c93});}}['_handleMarkerOperation'](_0x3b1254){if(!_0x3b1254['affectsData'])return;const _0x5a8866=(_0x3b1254=this['_cloneOperation'](_0x3b1254,this['_diffRoots']))['oldRange']?_0x3b1254['oldRange']['root']:null,_0xc04de4=_0x3b1254['newRange']?_0x3b1254['newRange']['root']:null;_0x5a8866&&this['_markers']['delete'](_0x3b1254['name']),_0xc04de4&&this['_markers']['set'](_0x3b1254['name'],_0x3b1254['newRange']['clone']());const _0x2a4534=null===_0x3b1254['_authorId']?null:_0x3b1254['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x32a439=_0x3b1254['name'];if(!this['_touchedMarkers']['has'](_0x32a439))return void this['_touchedMarkers']['set'](_0x32a439,{'range':_0x3b1254['oldRange'],'userId':_0x2a4534});const _0x1460eb=this['_touchedMarkers']['get'](_0x32a439),_0x3fde65=_0x1460eb['range'],_0x3e7911=_0x3b1254['newRange'];null==_0x3fde65&&null==_0x3e7911||_0x3fde65&&_0x3e7911&&_0x3fde65['isEqual'](_0x3e7911)?this['_touchedMarkers']['delete'](_0x3b1254['name']):_0x1460eb['userId']=_0x2a4534;}['_handleRootOperation'](_0x316c4f,_0x5a8e93){this['_diffRoots']['has'](_0x316c4f['rootName'])?this['_diffRoots']['get'](_0x316c4f['rootName'])['_isAttached']=_0x316c4f['isAdd']:(this['_diffRoots']['set'](_0x316c4f['rootName'],P(_0x316c4f['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x316c4f['rootName'],{}),_0x5a8e93&&this['_idsRoots']['set'](_0x316c4f['rootName'],P(_0x316c4f['rootName'],!0x0)));const _0x201e72=null===_0x316c4f['_authorId']?null:_0x316c4f['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x4ce410=this['_touchedRoots']['get'](_0x316c4f['rootName']);_0x4ce410&&_0x4ce410['userId']===_0x201e72?this['_touchedRoots']['delete'](_0x316c4f['rootName']):this['_touchedRoots']['set'](_0x316c4f['rootName'],{'userId':_0x201e72,'isAttached':_0x316c4f['isAdd']});}['_handleRootAttributeOperation'](_0x4a5d27){const _0x2924f4=this['_diffRootsAttributes']['get'](_0x4a5d27['root']['rootName']);null===_0x4a5d27['newValue']?delete _0x2924f4[_0x4a5d27['key']]:_0x2924f4[_0x4a5d27['key']]=_0x4a5d27['newValue'];}}function N(_0x116dec){const _0x4ca5f8=P(_0x116dec['rootName'],_0x116dec['isAttached']());for(const _0x334958 of _0x116dec['getChildren']()){const _0x2a7659=_0x334958['_clone'](!0x0);_0x4ca5f8['_appendChild'](_0x2a7659);}return _0x4ca5f8;}function P(_0x5e38e9,_0x43d658=!0x0){const _0x9a54c9=new vt();return _0x9a54c9['rootName']=_0x5e38e9,_0x9a54c9['_isAttached']=_0x43d658,_0x9a54c9['isAttached']=()=>_0x9a54c9['_isAttached'],_0x9a54c9;}function F(_0x2babcc,_0x3a22c5,_0x5e7f94){const _0x2c308e='elementEnd'==_0x2babcc['type']?_0x5e7f94['createPositionAt'](_0x2babcc['item'],'end'):_0x5e7f94['createPositionBefore'](_0x2babcc['item']);return _0x5e7f94['createPositionFromPath'](_0x3a22c5,_0x2c308e['path'],_0x2c308e['stickiness']);}function B(_0x3ef295,_0x79ba40,_0x1651dc){const _0x38a995='elementStart'==_0x3ef295['type']?_0x1651dc['createPositionAt'](_0x3ef295['item'],0x0):_0x1651dc['createPositionAfter'](_0x3ef295['item']);return _0x1651dc['createPositionFromPath'](_0x79ba40,_0x38a995['path'],_0x38a995['stickiness']);}class hs extends ts{['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x1bcd9d,_0x171027){super(_0x1bcd9d),this['focusTracker']=new _0x3d5f91(),this['keystrokes']=new _0x583348(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x171027),this['setTemplate']({'tag':'form','attributes':{'class':['ck','ck-revision-history-save-revision-form','ck-responsive-form'],'tabindex':'-1'},'children':[this['revisionNameInputView']]}),_0x25b1f2(this);}['render'](){super['render'](),_0x50411b({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x3d4464=_0x3376bb=>_0x3376bb['stopPropagation']();this['keystrokes']['set']('arrowright',_0x3d4464),this['keystrokes']['set']('arrowleft',_0x3d4464),this['keystrokes']['set']('arrowup',_0x3d4464),this['keystrokes']['set']('arrowdown',_0x3d4464);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x59cb39){this['revisionNameInputView']['fieldView']['element']['value']=_0x59cb39['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x24b823){const _0x72ba45=new _0x53f8a9(this['locale'],_0x33ff0f),_0x5c4374=_0x72ba45['fieldView'];_0x5c4374['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x37bb55=g(this['locale'],'Name\x20of\x20the\x20revision');return!_0x24b823&&(_0x37bb55+='\x20('+g(this['locale'],'optional')+')'),(_0x72ba45['label']=_0x37bb55,_0x5c4374['on']('input',()=>{this['revisionNameInputValue']=_0x5c4374['element']['value']['trim']();}),_0x72ba45);}}class f extends _0x215f3d{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u];}['_saveRevisionFormView'];['init'](){const _0x119e27=this['editor'],_0x1b06b5=_0x119e27['plugins']['get']('RevisionTracker');_0x119e27['ui']['componentFactory']['add']('revisionHistory',_0x184c84=>{const _0x49468e=_0x41d57a(_0x184c84),_0x28288a=_0x49468e['panelView']['children'],_0x1649b5=new _0x21eec4(_0x184c84),_0x1252c9=new _0xbcd986(_0x184c84),_0x9a6a8=new te(_0x184c84),_0x2abaa9=new _0xbcd986(_0x184c84),_0x1e1645=new te(_0x184c84);return _0x49468e['bind']('isEnabled')['to'](_0x1b06b5,'isReady',_0x1b06b5,'isEnabled',_0x119e27,'isReadOnly',(_0x5c29f6,_0x1fa5a2,_0x3af306)=>_0x5c29f6&&_0x1fa5a2&&!_0x3af306),_0x49468e['buttonView']['set']({'icon':_0x14d782,'label':g(_0x184c84,'Revision\x20history'),'tooltip':!0x0}),_0x9a6a8['set']({'label':g(_0x184c84,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x9a6a8['bind']('isEnabled')['to'](_0x1b06b5,'isReady',_0x1b06b5,'isEnabled',_0x119e27,'isReadOnly',(_0x47a5cc,_0x1c48e7,_0xe84d24)=>_0x47a5cc&&_0x1c48e7&&!_0xe84d24),_0x9a6a8['on']('execute',()=>this['_showDialog']()),_0x1e1645['set']({'label':g(_0x184c84,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x1e1645['bind']('isEnabled')['to'](_0x1b06b5,'isReady',_0x119e27,'isReadOnly',(_0x42a621,_0x513d39)=>_0x42a621&&!_0x513d39),_0x1e1645['on']('execute',()=>{_0x119e27['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x49468e['isOpen']=!0x1,_0x119e27['editing']['view']['focus']();}),_0x1252c9['children']['add'](_0x9a6a8),_0x2abaa9['children']['add'](_0x1e1645),_0x1649b5['role']='menu',_0x1649b5['items']['addMany']([_0x1252c9,_0x2abaa9]),_0x28288a['add'](_0x1649b5),_0x49468e;}),_0x119e27['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x282ad5=this['editor'],_0x26ac4b=_0x282ad5['locale'],_0x5da082=new _0x3cb039(_0x26ac4b),_0x3e3268=new _0x34a253(_0x26ac4b);_0x5da082['buttonView']['set']({'icon':_0x14d782,'label':g(_0x26ac4b,'Revision\x20history')});const _0x16057b=new _0x4b57e6(_0x26ac4b,_0x5da082),_0x365ff8=new _0x51584f(_0x26ac4b);_0x365ff8['set']({'label':g(_0x26ac4b,'Save\x20current\x20revision')}),_0x365ff8['delegate']('execute')['to'](_0x5da082),_0x365ff8['on']('execute',()=>{this['_showDialog']();}),_0x16057b['children']['add'](_0x365ff8),_0x3e3268['items']['add'](_0x16057b);const _0x5b2859=new _0x4b57e6(_0x26ac4b,_0x5da082),_0x3ec97f=new _0x51584f(_0x26ac4b);return _0x3ec97f['set']({'label':g(_0x26ac4b,'Open\x20revision\x20history')}),_0x3ec97f['delegate']('execute')['to'](_0x5da082),_0x3ec97f['on']('execute',()=>{_0x282ad5['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x5b2859['children']['add'](_0x3ec97f),_0x3e3268['items']['add'](_0x5b2859),_0x5da082['panelView']['children']['add'](_0x3e3268),_0x5da082;}['_showDialog'](){const _0x4a6d86=this['editor'],_0x305005=_0x4a6d86['locale'],_0x10305c=_0x4a6d86['plugins']['get']('Dialog'),_0x2cc5b6=_0x4a6d86['plugins']['get']('RevisionTracker');function _0x3c7004(_0x18a622){_0x4a6d86['config']['get']('revisionHistory.requireRevisionName')&&''===_0x18a622['revisionName']?_0x18a622['revisionNameInputView']['errorText']=g(_0x305005,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x4a6d86['plugins']['get'](u)['saveRevision']({'name':_0x18a622['revisionName']}),_0x10305c['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x3c7004(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x10305c['show']({'id':'revisionSave','title':g(_0x305005,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':g(_0x4a6d86['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x10305c['hide']()},{'label':g(_0x4a6d86['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x4b0b12){_0x4b0b12['bind']('isEnabled')['to'](_0x2cc5b6,'isReady',_0x2cc5b6,'isEnabled',_0x4a6d86,'isReadOnly',(_0x27937f,_0x5c1373,_0x23d2db)=>_0x27937f&&_0x5c1373&&!_0x23d2db);},'onExecute':()=>_0x3c7004(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x1c0e5f=this['editor'],_0x552dae=_0x1c0e5f['locale'];this['_saveRevisionFormView']=new hs(_0x552dae,_0x1c0e5f['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class Q extends ts{['changeId'];['_model'];constructor(_0x45c588,_0x530daf){super(_0x45c588),this['_model']=_0x530daf,this['changeId']=_0x530daf['id'];const _0x425495=this['bindTemplate'],_0x59ac6b=g(_0x45c588,_0x530daf['data']['isSuggestion']?'Suggested\x20by':'add'==_0x530daf['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x530daf['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x425495['to']('type',_0x478871=>'ck-revision-change__'+_0x478871)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x59ac6b}]},{'text':'\x20'+_0x530daf['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class r extends/* #__PURE__ -- @preserve */
|
|
25
|
+
_0x1a0236(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x5bdb4b){super(),this['id']=_0x5bdb4b['id']||_0x335623(),this['author']=_0x5bdb4b['author'],this['type']=_0x5bdb4b['type'],this['data']=_0x5bdb4b['data']||{},this['rootName']=_0x5bdb4b['rootName'],this['set']('createdAt',_0x5bdb4b['createdAt']);}['toJSON'](){return{'id':this['id'],'authorId':this['author']['id'],'type':this['type'],'data':this['data'],'createdAt':this['createdAt']};}}class c{['newRevisionId'];['oldRevisionId'];['changes'];constructor(_0x25b89d,_0x1bad84){this['newRevisionId']=_0x25b89d,this['oldRevisionId']=_0x1bad84,this['changes']=new _0x3b3f60();}['_setChanges'](_0x429355){for(const _0x14184b of _0x429355)this['changes']['add'](_0x14184b);}}class m extends _0x215f3d{['repository'];['adapter']=null;['_utils'];['_activeViewTarget'];['_changeView'];['_changeIdToChange'];['_balloon'];static get['pluginName'](){return'RevisionViewer';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[_0x1efa5c,_0x5401b0,I,V];}constructor(_0x443bf7){super(_0x443bf7),this['repository']=this['editor']['plugins']['get']('RevisionsRepository'),this['_utils']=this['editor']['plugins']['get']('RevisionHistoryUtils'),this['set']('activeChange',null),this['set']('activeView',null),this['_activeViewTarget']=null,this['set']('diff',null),this['set']('isReady',!0x1),this['set']('isEnabled',!0x0),this['on']('change:isEnabled',(_0x542954,_0x4ec691,_0x17921f)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x41c03c=>{for(const _0x418215 of this['editor']['editing']['view']['document']['roots'])_0x17921f?_0x41c03c['removeClass']('ck-editor__editable__overlay',_0x418215):_0x41c03c['addClass']('ck-editor__editable__overlay',_0x418215);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x11f3b0=>null!==_0x11f3b0),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x2d7d9e,_0x44febb,_0x2427d3)=>_0x2d7d9e&&_0x2427d3?_0x44febb['changes']['getIndex'](_0x2427d3):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x554932,_0x23621d)=>_0x554932?_0x23621d['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0x5401b0);}['init'](){const _0x32bcf4=this['editor'],_0xc560fd=new wt(_0x32bcf4,{'direction':'backward'}),_0x4c84d6=new wt(_0x32bcf4,{'direction':'forward'});(_0x32bcf4['commands']['add']('showPreviousChange',_0xc560fd),_0x32bcf4['commands']['add']('showNextChange',_0x4c84d6),_0x32bcf4['commands']['add']('restoreRevision',new mt(_0x32bcf4)),this['on']('change:numberOfChanges',()=>{_0xc560fd['refresh'](),_0x4c84d6['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x32bcf4['enableReadOnlyMode']('revision-viewer'),_0x32bcf4['plugins']['has']('WidgetToolbarRepository'))&&_0x32bcf4['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x279240){return await this['_utils']['loadRevisionData'](_0x279240,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x279240);}async['getRevisionRootsAttributes'](_0x14deba){return await this['_utils']['loadRevisionData'](_0x14deba,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x14deba);}async['compare'](_0x5c1b04,_0x146707,_0xc993b1=!0x1){if(!this['isEnabled'])return;const _0x3c15eb=this['diff'],_0x1291d0=this['repository'],_0x21638a='string'==typeof _0x5c1b04?_0x1291d0['getRevision'](_0x5c1b04):_0x5c1b04,_0x5ce675='string'==typeof _0x146707?_0x1291d0['getRevision'](_0x146707):_0x146707,_0x3d9f53=_0x21638a['id'],_0x367cda=_0x5ce675?_0x5ce675['id']:null;if(!_0xc993b1&&this['diff']&&this['diff']['newRevisionId']===_0x3d9f53&&this['diff']['oldRevisionId']===_0x367cda)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new c(_0x3d9f53,_0x367cda);const _0xc81f89=this['_getRevisionsRange'](_0x21638a,_0x5ce675,!0x0)['map'](_0x2be2a3=>this['_utils']['loadRevisionData'](_0x2be2a3,this['adapter']));return _0xc81f89['push'](new Promise(_0x4c52d4=>{setTimeout(_0x4c52d4,0x14);})),Promise['all'](_0xc81f89)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x617663=this['_getDiff'](_0x3d9f53,_0x367cda);for(const _0x511edb of _0x617663['changes'])this['_changeIdToChange']['set'](_0x511edb['id'],_0x511edb);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0xfecebc=>{for(const _0x171f5a of this['editor']['model']['document']['getRootNames']())_0xfecebc['detachRoot'](_0x171f5a);for(const _0x4c8bc1 of Object['keys'](_0x617663['model'])){const _0x3396ac=_0xfecebc['addRoot'](_0x4c8bc1);for(const _0x37b119 of Object['keys'](_0x617663['attributes'][_0x4c8bc1]))_0xfecebc['setAttribute'](_0x37b119,_0x617663['attributes'][_0x4c8bc1][_0x37b119],_0x3396ac);_0xfecebc['insert'](_0x617663['model'][_0x4c8bc1],_0x3396ac,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x617663['changes'])),this['isReady']=!0x0;})['catch'](_0x365081=>{console['error'](_0x365081),this['_cleanUp'](),_0x3c15eb&&(this['diff']=_0x3c15eb),this['isReady']=!0x0;});}['addRevisionData'](_0x5e7c5d,_0x55d9d9){const _0x486019=this['repository']['createRevision'](_0x5e7c5d);return _0x486019['on']('_update',(_0x32a0e4,_0x188abe,_0x47f203)=>_0x55d9d9(_0x188abe,_0x47f203,_0x486019)),this['repository']['addRevision'](_0x486019),_0x486019;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x1701c5=>{for(const _0x4052a5 of this['editor']['model']['document']['getRootNames']())_0x1701c5['detachRoot'](_0x4052a5);});}['_sortAndFilterDiffChanges'](_0x16cc85){const _0x15e873=[],_0x2e57c3=new Map();for(const _0x261f62 of this['editor']['model']['document']['getRootNames']()){const _0x1bffe2=this['editor']['editing']['view']['getDomRoot'](_0x261f62);if(!_0x1bffe2)continue;const _0x1c055f=_0x1bffe2['getClientRects']()['item'](0x0);_0x1c055f&&(_0x15e873['push'](_0x261f62),_0x2e57c3['set'](_0x261f62,_0x1c055f));}return _0x15e873['sort']((_0x45ae13,_0x235637)=>{const _0x3d407a=_0x2e57c3['get'](_0x45ae13),_0x3c39c2=_0x2e57c3['get'](_0x235637);return _0x3d407a['y']-_0x3c39c2['y']||_0x3d407a['x']-_0x3c39c2['x'];}),(_0x16cc85=_0x16cc85['filter'](_0xadf6ef=>_0x15e873['includes'](_0xadf6ef['rootName'])))['sort']((_0x498e59,_0x24a189)=>_0x15e873['indexOf'](_0x498e59['rootName'])-_0x15e873['indexOf'](_0x24a189['rootName'])),_0x16cc85;}['_makeTape'](_0x220416){const _0x55f052=Array['from'](_0x220416['markers'])['filter'](([_0x1f28a5,_0xb92cd2])=>_0x1f28a5['startsWith']('revision:')&&!_0xb92cd2['isCollapsed']),_0x2d5451=Array['from'](this['editor']['model']['createRangeIn'](_0x220416)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x55f052['length'])for(const _0x48007e of _0x2d5451){const [_0x3efb83,_0x47d4b1]=_0x55f052[0x0],[,_0x45ca6a,_0x159c04]=_0x3efb83['split'](':');if(_0x47d4b1['end']['isEqual'](_0x48007e['nextPosition'])&&_0x55f052['shift'](),(_0x48007e['previousPosition']['isEqual'](_0x47d4b1['start'])||_0x48007e['previousPosition']['isAfter'](_0x47d4b1['start']))&&('insertion'==_0x45ca6a?_0x48007e['isAdded']={'userId':_0x159c04}:'deletion'==_0x45ca6a&&(_0x48007e['isRemoved']={'userId':_0x159c04})),0x0==_0x55f052['length'])break;}return _0x2d5451;}['_refreshStartEndIndex'](_0x23fadd){const _0x1c3b25=new Map();for(let _0x2f165c=0x0;_0x2f165c<_0x23fadd['length'];_0x2f165c++)'text'===_0x23fadd[_0x2f165c]['type']?(_0x23fadd[_0x2f165c]['item']['startIndex']=_0x2f165c,_0x23fadd[_0x2f165c]['item']['endIndex']=_0x2f165c):('elementStart'===_0x23fadd[_0x2f165c]['type']?_0x23fadd[_0x2f165c]['item']['startIndex']=_0x2f165c:'elementEnd'===_0x23fadd[_0x2f165c]['type']&&(_0x23fadd[_0x2f165c]['item']['endIndex']=_0x2f165c),_0x1c3b25['set'](_0x23fadd[_0x2f165c]['id'],_0x2f165c));for(const _0x4d7f99 of _0x1c3b25['values']())'elementStart'===_0x23fadd[_0x4d7f99]['type']?_0x23fadd[_0x4d7f99]['item']['endIndex']=_0x1c3b25['get'](_0x23fadd[_0x4d7f99]['pairId']):'elementEnd'===_0x23fadd[_0x4d7f99]['type']&&(_0x23fadd[_0x4d7f99]['item']['startIndex']=_0x1c3b25['get'](_0x23fadd[_0x4d7f99]['pairId']));}['_processTape'](_0x3acb9d){for(let _0x1f40b0=0x0;_0x1f40b0<_0x3acb9d['length'];_0x1f40b0++){if('elementStart'===_0x3acb9d[_0x1f40b0]['type'])_0x3acb9d[_0x1f40b0]['item']['startIndex']=_0x1f40b0;else{if('elementEnd'===_0x3acb9d[_0x1f40b0]['type']){_0x3acb9d[_0x1f40b0]['item']['endIndex']=_0x1f40b0;const _0x252c79=_0x3acb9d[_0x1f40b0]['item']['startIndex'];_0x3acb9d[_0x252c79]['pairId']=_0x3acb9d[_0x1f40b0]['id'],_0x3acb9d[_0x1f40b0]['pairId']=_0x3acb9d[_0x252c79]['id'];}else _0x3acb9d[_0x1f40b0]['item']['startIndex']=_0x1f40b0,_0x3acb9d[_0x1f40b0]['item']['endIndex']=_0x1f40b0,_0x3acb9d[_0x1f40b0]['pairId']=null;}_0x3acb9d[_0x1f40b0]['markersStart']||(_0x3acb9d[_0x1f40b0]['markersStart']=[],_0x3acb9d[_0x1f40b0]['markersEnd']=[]);}}['_markInsertions'](_0x3f7efe,_0x153b37){const _0x42904d=_0x3f7efe['filter'](_0x534754=>!_0x534754['isAdded']);for(let _0x27f049=0x0;_0x27f049<_0x153b37['length'];_0x27f049++)_0x153b37[_0x27f049]['isAdded']&&(_0x42904d[_0x27f049]['isAdded']=_0x153b37[_0x27f049]['isAdded']);}['_getDiff'](_0x20a7e3,_0x3f37f1=null){const _0x46052c=this['repository']['getRevision'](_0x20a7e3),_0x297299=_0x3f37f1?this['repository']['getRevision'](_0x3f37f1):null,_0x174451=this['_getRevisionsRange'](_0x46052c,_0x297299),_0x44d5c2=_0x174451[_0x174451['length']-0x1],_0x17eb88=new Map(),_0x569d30={'model':{},'attributes':{},'changes':[]},_0x4c32d1=new Set(),_0x5f5a77=new Map();for(let _0x5d1bb9=_0x174451['length']-0x1;_0x5d1bb9>=0x0;_0x5d1bb9--){const _0x3f8a63=_0x174451[_0x5d1bb9];for(const _0x50f849 of Object['keys'](_0x3f8a63['diffData']))if(_0x3f8a63['diffData'][_0x50f849]['attachChange']){const _0x27baa4=_0x3f8a63['diffData'][_0x50f849]['attachChange'];_0x27baa4['isAttached']?(_0x4c32d1['add'](_0x50f849),_0x5f5a77['has'](_0x50f849)&&_0x5f5a77['get'](_0x50f849)['userId']==_0x27baa4['userId']?_0x5f5a77['delete'](_0x50f849):_0x5f5a77['set'](_0x50f849,_0x27baa4)):_0x5f5a77['has'](_0x50f849)?(_0x4c32d1['delete'](_0x50f849),_0x5f5a77['delete'](_0x50f849)):(_0x4c32d1['add'](_0x50f849),_0x5f5a77['set'](_0x50f849,_0x27baa4));}else _0x4c32d1['add'](_0x50f849);}for(const _0x386b65 of _0x4c32d1){const _0x3626bd=_0x5f5a77['has'](_0x386b65)&&!_0x5f5a77['get'](_0x386b65)['isAttached'];let _0x5592df=_0x3626bd?_0x174451['length']-0x1:0x0;const _0x373434=_0x3626bd?-0x1:0x1;for(;_0x174451[_0x5592df];){const _0xded708=_0x174451[_0x5592df];if(_0xded708['diffData'][_0x386b65]){const _0x555f19=_0x3626bd?_0xded708['diffData'][_0x386b65]['attributesBefore']:_0xded708['diffData'][_0x386b65]['attributesAfter'];_0x569d30['attributes'][_0x386b65]=_0x555f19?_0x25c995(_0x555f19):{};break;}_0x5592df+=_0x373434;}}for(const _0x216f91 of _0x174451){_0x216f91['model']={};for(const _0x597d31 of _0x216f91['authors'])_0x17eb88['set'](_0x597d31['id'],_0x597d31);for(const _0x8def27 of _0x4c32d1){const _0x37fd15=_0x216f91['diffData'][_0x8def27]?_0x216f91['diffData'][_0x8def27]['insertions']:'[]',_0x5d830f=_0x216f91['diffData'][_0x8def27]?_0x216f91['diffData'][_0x8def27]['deletions']:'[]';_0x216f91['model'][_0x8def27]={'insertions':this['_utils']['_makeModelFromViewString'](_0x37fd15),'deletions':this['_utils']['_makeModelFromViewString'](_0x5d830f)};}}for(const _0x51bcbb of _0x4c32d1){let _0x52044e=null,_0x2d6bbc=0x0;const _0x279280=new Map(Array['from'](_0x46052c['model'][_0x51bcbb]['insertions']['markers'])['filter'](([_0x32f771])=>!_0x32f771['startsWith']('revision:')));let _0x41c4be=0x0;for(const _0x54f702 of _0x174451){const _0x1a8f65=this['_makeTape'](_0x54f702['model'][_0x51bcbb]['insertions']);_0x54f702==_0x46052c?(_0x52044e=_0x1a8f65,_0x2d6bbc=_0x52044e['length'],_0x52044e['forEach'](_0x4a12a6=>{_0x4a12a6['id']=_0x41c4be++;}),this['_processTape'](_0x52044e)):this['_markInsertions'](_0x52044e,_0x1a8f65);const _0x366672=_0x52044e['filter'](_0x2e3c3b=>!_0x2e3c3b['isAdded'])['map'](_0x14a510=>_0x14a510['id']);let _0x338849=0x0;const _0x3fafc3=this['_makeTape'](_0x54f702['model'][_0x51bcbb]['deletions']);_0x3fafc3['forEach'](_0x1aab1c=>{_0x1aab1c['isRemoved']?_0x1aab1c['id']=_0x2d6bbc++:_0x1aab1c['id']=_0x366672[_0x338849++];}),this['_processTape'](_0x3fafc3),this['_setDistance'](_0x52044e,'isAdded'),this['_setDistance'](_0x3fafc3,'isRemoved'),_0x54f702==_0x46052c&&this['_markMarkers'](_0x52044e,_0x279280),_0x52044e=this['_joinTapes'](_0x52044e,_0x3fafc3),this['_refreshStartEndIndex'](_0x52044e),this['_setDistance'](_0x52044e,'isRemoved');}_0x52044e=_0x52044e['filter'](_0x254598=>!(_0x254598['isAdded']&&_0x254598['isRemoved']));const _0xfe8330=new Map(_0x44d5c2['model'][_0x51bcbb]['deletions']['markers']),_0x10efb2=new Set(_0x279280['keys']());for(const _0x14a15e of _0xfe8330['keys']())_0x10efb2['delete'](_0x14a15e);this['_markSuggestions'](_0x52044e,_0x10efb2),this['_fixObsoleteTags'](_0x52044e),_0x52044e=this['_removeMissingPairs'](_0x52044e),_0x52044e=this['_markMismatchedRemovedTags'](_0x52044e),_0x52044e=this['_removeUnsupportedChanges'](_0x52044e);const {root:_0x2d1eb7,changes:_0x409eef}=this['_makeModelFromTape'](_0x52044e,_0x17eb88,_0x51bcbb);_0x569d30['model'][_0x51bcbb]=_0x2d1eb7;const _0x25baf9=_0x5f5a77['get'](_0x51bcbb);if(_0x25baf9){const _0x48bae6=_0x17eb88['get'](_0x25baf9['userId']),_0x208a02=new r({'author':_0x48bae6,'type':_0x25baf9['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x51bcbb});_0x409eef['unshift'](_0x208a02),_0x569d30['attributes'][_0x51bcbb]['revisionHistoryAttachChange']=_0x208a02['id'];}_0x569d30['changes']=_0x569d30['changes']['concat'](_0x409eef);}return _0x569d30;}['_markMarkers'](_0x175951,_0x3b2d6a){for(let _0x309841=0x0;_0x309841<_0x175951['length'];_0x309841++)for(const [_0x245ced,_0x690b02]of _0x3b2d6a)!_0x690b02['isCollapsed']&&_0x690b02['start']['isEqual'](_0x175951[_0x309841]['previousPosition'])&&_0x175951[_0x309841]['markersStart']['push'](_0x245ced),_0x690b02['end']['isEqual'](_0x175951[_0x309841]['nextPosition'])&&_0x175951[_0x309841]['markersEnd']['push'](_0x245ced);}['_joinTapes'](_0x52cbb4,_0x27e696){let _0x1a0c9e=[],_0x261f6e=0x0,_0x537444=0x0;for(;_0x261f6e<_0x52cbb4['length']||_0x537444<_0x27e696['length'];){const _0x4316e9=_0x52cbb4[_0x261f6e]||{},_0x5607af=_0x27e696[_0x537444]||{};if(_0x4316e9['id']==_0x5607af['id'])_0x261f6e++,_0x537444++,_0x1a0c9e['push'](_0x4316e9);else{if(_0x5607af['isRemoved']&&_0x4316e9['isAdded']){const {commonTape:_0x51d01c,iEnd:_0x2376b8,jEnd:_0x4d9671}=this['_threeWayMerge'](_0x52cbb4,_0x261f6e,_0x27e696,_0x537444);_0x1a0c9e=_0x1a0c9e['concat'](_0x51d01c),_0x261f6e=_0x2376b8,_0x537444=_0x4d9671;}else _0x5607af['isRemoved']?(_0x537444++,_0x1a0c9e['push'](_0x5607af)):(_0x261f6e++,_0x1a0c9e['push'](_0x4316e9));}}return _0x1a0c9e;}['_markSuggestions'](_0x2e2369,_0x198ba7){const _0x3e1470=[];for(let _0x3ccf89=0x0;_0x3ccf89<_0x2e2369['length'];_0x3ccf89++){for(let _0x3391b0=0x0;_0x3391b0<_0x2e2369[_0x3ccf89]['markersStart']['length'];_0x3391b0++){const _0x2a2bb8=_0x2e2369[_0x3ccf89]['markersStart'][_0x3391b0];if(!_0x198ba7['has'](_0x2a2bb8))continue;const {group:_0x449865,type:_0x959440,authorId:_0x4e951f}=_0x8d6776(_0x2a2bb8);'revision-suggestion'!=_0x449865||'insertion'!=_0x959440&&'deletion'!=_0x959440||(_0x3e1470['unshift']({'type':_0x959440,'name':_0x2a2bb8,'userId':_0x4e951f}),_0x2e2369[_0x3ccf89]['markersStart']['splice'](_0x3391b0,0x1),_0x3391b0--);}_0x25e76d(_0x2e2369[_0x3ccf89]);for(let _0xce2bce=0x0;_0xce2bce<_0x2e2369[_0x3ccf89]['markersEnd']['length'];_0xce2bce++){const _0x137c0f=_0x2e2369[_0x3ccf89]['markersEnd'][_0xce2bce];if(!_0x198ba7['has'](_0x137c0f))continue;const {group:_0x4eb838,type:_0x1d4cf0}=_0x8d6776(_0x137c0f);if('revision-suggestion'!=_0x4eb838||'insertion'!=_0x1d4cf0&&'deletion'!=_0x1d4cf0)continue;_0x2e2369[_0x3ccf89]['markersEnd']['splice'](_0xce2bce,0x1),_0xce2bce--;const _0x1cf932=_0x3e1470['findIndex'](_0xbe8092=>_0xbe8092['name']==_0x137c0f);_0x1cf932>-0x1&&_0x3e1470['splice'](_0x1cf932,0x1);}}function _0x8d6776(_0x595bad){const _0x217b93=_0x595bad['split'](':');return{'group':_0x217b93[0x0],'type':_0x217b93[0x1],'subType':_0x217b93['length']>=0x5?_0x217b93[0x2]:null,'id':_0x217b93['length']<0x5?_0x217b93[0x2]:_0x217b93[0x3],'authorId':_0x217b93['length']<0x5?_0x217b93[0x3]:_0x217b93[0x4],'markerCount':0x6==_0x217b93['length']?_0x217b93[0x5]:null};}function _0x25e76d(_0x264148){for(let _0x2929cd=0x0;_0x2929cd<_0x3e1470['length'];_0x2929cd++){if(_0x264148['isAdded']&&'insertion'==_0x3e1470[_0x2929cd]['type'])return _0x264148['isAddSuggestion']=_0x3e1470[_0x2929cd],void delete _0x264148['isAdded'];if(!_0x264148['isAdded']&&!_0x264148['isRemoved']&&'deletion'==_0x3e1470[_0x2929cd]['type'])return void(_0x264148['isRemoveSuggestion']=_0x3e1470[_0x2929cd]);}}}['_setDistance'](_0x2e3f78,_0x27aad1){let _0xc3be9c=0x0,_0x13d4f0=!0x1;const _0x279b08=new Map();for(const _0x381e96 of _0x2e3f78)_0x381e96[_0x27aad1]?_0x13d4f0&&(_0xc3be9c++,_0x13d4f0=!0x1):(_0xc3be9c++,_0x13d4f0=!0x0),_0x279b08['set'](_0x381e96['id'],_0xc3be9c);for(let _0x460fd6=0x0;_0x460fd6<_0x2e3f78['length'];_0x460fd6++){if('isRemoved'==_0x27aad1&&_0x2e3f78[_0x460fd6]['isAdded']||'isAdded'==_0x27aad1&&_0x2e3f78[_0x460fd6]['isRemoved'])continue;if('text'==_0x2e3f78[_0x460fd6]['type']){_0x2e3f78[_0x460fd6]['distance']=0x0;continue;}const _0x370a27=_0x279b08['get'](_0x2e3f78[_0x460fd6]['pairId']),_0x3f1cbf=_0x279b08['get'](_0x2e3f78[_0x460fd6]['id']);_0x2e3f78[_0x460fd6]['distance']=_0x370a27-_0x3f1cbf;}}['_getRevisionsRange'](_0x5f5dc6,_0x1164f9,_0x1e0295=!0x1){const _0x2cb1a9=[];let _0x1a6813=this['repository']['getIndex'](_0x5f5dc6),_0x2d3e4d=this['repository']['getIndex'](_0x1164f9);for(-0x1==_0x2d3e4d&&(_0x2d3e4d=this['repository']['_revisions']['length'],_0x1e0295=!0x1);_0x1a6813<_0x2d3e4d;)_0x2cb1a9['push'](this['repository']['getRevision'](_0x1a6813)),_0x1a6813++;return _0x1e0295&&_0x2cb1a9['push'](this['repository']['getRevision'](_0x1a6813)),_0x2cb1a9;}['_threeWayMerge'](_0xdef9f6,_0x4225e3,_0x2fac45,_0x4ca110){const _0x1480c3=this['editor']['model']['schema'];let _0x29f207=_0x4225e3;for(;_0xdef9f6[_0x29f207]&&_0xdef9f6[_0x29f207]['isAdded'];)_0x29f207++;let _0x371d05=_0x4ca110;for(;_0x2fac45[_0x371d05]&&_0x2fac45[_0x371d05]['isRemoved'];)_0x371d05++;_0x6faf4(_0xdef9f6,_0x4225e3,_0x29f207),_0x6faf4(_0x2fac45,_0x4ca110,_0x371d05);const _0x5ca918=_0x2fac45['slice'](_0x4ca110,_0x371d05)['concat'](_0xdef9f6['slice'](_0x4225e3,_0x29f207));return _0x5ca918['sort']((_0x5b5bae,_0x47d3d6)=>_0x5b5bae['side']!=_0x47d3d6['side']?_0x5b5bae['side']-_0x47d3d6['side']:_0x5b5bae['level']!=_0x47d3d6['level']?_0x5b5bae['level']-_0x47d3d6['level']:_0x5b5bae['distance']!=_0x47d3d6['distance']?_0x47d3d6['distance']-_0x5b5bae['distance']:!!_0x5b5bae['isAdded']!=!!_0x47d3d6['isAdded']?-0x1==_0x5b5bae['side']||0x0==_0x5b5bae['side']?_0x5b5bae['isAdded']?-0x1:0x1:_0x5b5bae['isAdded']?0x1:-0x1:_0x5b5bae['index']-_0x47d3d6['index']),{'commonTape':_0x5ca918,'iEnd':_0x29f207,'jEnd':_0x371d05};function _0x6faf4(_0x54ed29,_0x2fbc66,_0x5ef6c7){let _0xba47b=-0x1,_0x57e9db=Number['POSITIVE_INFINITY'],_0x1f6ac0=!0x0;for(let _0x51ad29=_0x2fbc66;_0x51ad29<_0x5ef6c7;_0x51ad29++)if(_0x1480c3['isInline'](_0x54ed29[_0x51ad29]['item'])||(_0x1f6ac0=!0x1),_0x54ed29[_0x51ad29]['item']['startIndex']<_0x2fbc66&&(_0xba47b=_0x51ad29),_0x54ed29[_0x51ad29]['item']['endIndex']>=_0x5ef6c7){_0x57e9db=_0x51ad29;break;}_0x1f6ac0&&(_0xba47b=_0x5ef6c7-0x1);for(let _0xf0f2b6=_0x2fbc66;_0xf0f2b6<_0x5ef6c7;_0xf0f2b6++)_0x54ed29[_0xf0f2b6]['side']=_0xf0f2b6<=_0xba47b?-0x1:_0xf0f2b6<_0x57e9db?0x0:0x1,_0x54ed29[_0xf0f2b6]['index']=_0xf0f2b6;let _0x526fa8=0x0;for(let _0x3922b7=_0x2fbc66;_0x3922b7<=_0xba47b;_0x3922b7++)0x0==_0x54ed29[_0x3922b7]['distance']?_0x54ed29[_0x3922b7]['level']=_0x526fa8:(_0x526fa8++,_0x54ed29[_0x3922b7]['level']=_0x526fa8,_0x526fa8++);for(let _0x989a4=_0x2fbc66;_0x989a4<_0x5ef6c7;_0x989a4++)0x0==_0x54ed29[_0x989a4]['side']&&(_0x54ed29[_0x989a4]['level']=_0x526fa8);_0x526fa8=0x0;for(let _0x416e80=_0x5ef6c7-0x1;_0x416e80>=_0x57e9db;_0x416e80--)0x0==_0x54ed29[_0x416e80]['distance']?_0x54ed29[_0x416e80]['level']=_0x526fa8:(_0x526fa8--,_0x54ed29[_0x416e80]['level']=_0x526fa8,_0x526fa8--);}}['_fixObsoleteTags'](_0x5c0dab){const _0x2fe606=new Map(),_0x463155=this['editor']['model']['schema'];for(let _0x4036c9=0x1;_0x4036c9<_0x5c0dab['length'];_0x4036c9++){let _0xf7173e,_0x483493,_0x2b76d8;const _0x29822f=_0x5c0dab[_0x4036c9],_0x34ca7a=_0x5c0dab[_0x4036c9-0x1];if('text'==_0x29822f['type'])continue;if(_0x29822f['type']!=_0x34ca7a['type'])continue;if(!_0x463155['isBlock'](_0x34ca7a['item'])||_0x463155['isLimit'](_0x34ca7a['item']))continue;if(!_0x463155['isBlock'](_0x29822f['item'])||_0x463155['isLimit'](_0x29822f['item']))continue;if((_0x5c0dab[_0x4036c9]['isAdded']||_0x5c0dab[_0x4036c9]['isAddSuggestion'])&&_0x5c0dab[_0x4036c9-0x1]['isRemoved'])_0xf7173e=_0x5c0dab[_0x4036c9],_0x483493=_0x5c0dab[_0x4036c9-0x1],_0x2b76d8=_0x4036c9-0x1;else{if(!_0x5c0dab[_0x4036c9]['isRemoved']||!_0x5c0dab[_0x4036c9-0x1]['isAdded']&&!_0x5c0dab[_0x4036c9-0x1]['isAddSuggestion'])continue;_0xf7173e=_0x5c0dab[_0x4036c9-0x1],_0x483493=_0x5c0dab[_0x4036c9],_0x2b76d8=_0x4036c9;}const _0xf2bc27=_0xf7173e['level']==_0x483493['level'],_0x905b52=Math['abs'](_0xf7173e['level'])<Math['abs'](_0x483493['level'])&&0x0==_0x483493['distance'];(_0xf2bc27||_0x905b52)&&(_0x2fe606['set'](_0x483493['id'],_0xf7173e['id']),_0x5c0dab['splice'](_0x2b76d8,0x1),_0x4036c9--,_0xf7173e['isAdded']=!0x1);}for(let _0x101115=0x0;_0x101115<_0x5c0dab['length'];_0x101115++)_0x2fe606['has'](_0x5c0dab[_0x101115]['pairId'])&&(_0x5c0dab[_0x101115]['pairId']=_0x2fe606['get'](_0x5c0dab[_0x101115]['pairId']));}['_removeMissingPairs'](_0x40595e){const _0x22c3cf=new Set(_0x40595e['map'](_0x3a933c=>_0x3a933c['id']));for(let _0x46a835=0x0;_0x46a835<_0x40595e['length'];_0x46a835++)_0x22c3cf['has'](_0x40595e[_0x46a835]['pairId'])||0x0==_0x40595e[_0x46a835]['distance']||(_0x40595e[_0x46a835]['isIncorrect']=!0x0);return _0x40595e['filter'](_0x4c8193=>!_0x4c8193['isIncorrect']);}['_markMismatchedRemovedTags'](_0x335b92){const _0x151e88=new Set();for(let _0x55a7d0=0x0;_0x55a7d0<_0x335b92['length'];_0x55a7d0++){if(_0x151e88['has'](_0x335b92[_0x55a7d0]['id'])&&_0x335b92[_0x55a7d0]['isRemoved']&&(_0x335b92[_0x55a7d0]['isIncorrect']=!0x0),_0x335b92[_0x55a7d0]['isIncorrect'])continue;if(0x0==_0x335b92[_0x55a7d0]['distance'])continue;if('elementStart'!=_0x335b92[_0x55a7d0]['type'])continue;if(null==_0x335b92[_0x55a7d0]['pairId'])continue;let _0x1e8664=_0x55a7d0+0x1,_0x4c86e2=0x0;for(;_0x335b92[_0x1e8664]['id']!=_0x335b92[_0x55a7d0]['pairId'];)'elementStart'==_0x335b92[_0x1e8664]['type']?_0x4c86e2++:'elementEnd'==_0x335b92[_0x1e8664]['type']&&_0x4c86e2--,_0x1e8664++;if(0x0!=_0x4c86e2){if(_0x335b92[_0x55a7d0]['isRemoved'])_0x335b92[_0x55a7d0]['isIncorrect']=!0x0;else{for(;_0x1e8664!=_0x55a7d0;)_0x335b92[_0x1e8664]['isRemoved']&&0x0!=_0x335b92[_0x1e8664]['distance']&&(_0x335b92[_0x1e8664]['isIncorrect']=!0x0,_0x151e88['add'](_0x335b92[_0x1e8664]['pairId'])),_0x1e8664--;}}}return _0x335b92['filter'](_0x11eec9=>!_0x11eec9['isIncorrect']);}['_removeUnsupportedChanges'](_0x132981){const _0x5ad288=this['editor']['model']['schema'];for(let _0x2a6267=0x0;_0x2a6267<_0x132981['length'];_0x2a6267++){if(!(_0x132981[_0x2a6267]['isAdded']||_0x132981[_0x2a6267]['isAddSuggestion']||_0x132981[_0x2a6267]['isRemoved']||_0x132981[_0x2a6267]['isRemoveSuggestion']))continue;if(0x0==_0x132981[_0x2a6267]['distance'])continue;const _0x327a47=_0x132981[_0x2a6267]['item'];_0x5ad288['isBlock'](_0x327a47)||_0x5ad288['isLimit'](_0x327a47)||(_0x132981[_0x2a6267]['isAdded']&&delete _0x132981[_0x2a6267]['isAdded'],_0x132981[_0x2a6267]['isAddSuggestion']&&delete _0x132981[_0x2a6267]['isAddSuggestion'],_0x132981[_0x2a6267]['isRemoveSuggestion']&&delete _0x132981[_0x2a6267]['isRemoveSuggestion'],_0x132981[_0x2a6267]['isRemoved']&&(_0x132981[_0x2a6267]['isIncorrect']=!0x0));}return _0x132981['filter'](_0x3cb6ad=>!_0x3cb6ad['isIncorrect']);}['_makeModelFromTape'](_0x4a118c,_0x2cab0a,_0x26ee84){const _0x30aba6=new vt(),_0x546c22=[],_0x5bb673=new Map(),_0x3ce2c7=this['editor']['model'],_0x189feb=_0x3ce2c7['schema'],_0x1720fb=[_0x30aba6],_0x25e388={},_0x4150f9={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0xe706d3=null;const _0x34cac6=[0x0];for(let _0x47bcec=0x0;_0x47bcec<_0x4a118c['length'];_0x47bcec++)if('elementStart'===_0x4a118c[_0x47bcec]['type']){_0x4a118c[_0x47bcec]['previousPosition']=_0x3ce2c7['createPositionFromPath'](_0x30aba6,_0x34cac6);const _0x5459e3=new ut(_0x4a118c[_0x47bcec]['item']['name'],_0x4a118c[_0x47bcec]['item']['getAttributes']());_0x1720fb[0x0]['_appendChild'](_0x5459e3),_0x34cac6['push'](0x0),_0x1720fb['unshift'](_0x5459e3),_0x4a118c[_0x47bcec]['nextPosition']=_0x3ce2c7['createPositionFromPath'](_0x30aba6,_0x34cac6);}else'elementEnd'===_0x4a118c[_0x47bcec]['type']?(_0x1720fb['shift'](),_0x4a118c[_0x47bcec]['previousPosition']=_0x3ce2c7['createPositionFromPath'](_0x30aba6,_0x34cac6),_0x34cac6['pop'](),_0x34cac6[_0x34cac6['length']-0x1]++,_0x4a118c[_0x47bcec]['nextPosition']=_0x3ce2c7['createPositionFromPath'](_0x30aba6,_0x34cac6)):(_0x4a118c[_0x47bcec]['previousPosition']=_0x3ce2c7['createPositionFromPath'](_0x30aba6,_0x34cac6),_0xe706d3?_0xe706d3['_data']+=_0x4a118c[_0x47bcec]['item']['data']:_0xe706d3=new gt(_0x4a118c[_0x47bcec]['item']['data'],_0x4a118c[_0x47bcec]['item']['getAttributes']()),_0x4a118c[_0x47bcec+0x1]&&'text'===_0x4a118c[_0x47bcec+0x1]['type']&&_0x34df15(_0xe706d3,_0x4a118c[_0x47bcec+0x1]['item'])||(_0x1720fb[0x0]['_appendChild'](_0xe706d3),_0xe706d3=null),_0x34cac6[_0x34cac6['length']-0x1]+=_0x4a118c[_0x47bcec]['item']['offsetSize'],_0x4a118c[_0x47bcec]['nextPosition']=_0x3ce2c7['createPositionFromPath'](_0x30aba6,_0x34cac6));for(let _0x43bd6a=0x0;_0x43bd6a<_0x4a118c['length'];_0x43bd6a++){const _0x2b2fd9=_0x4a118c[_0x43bd6a]['previousPosition'],_0x22006b=_0x4a118c[_0x43bd6a]['nextPosition'];for(const _0x47f61d of _0x4a118c[_0x43bd6a]['markersStart'])_0x5bb673['set'](_0x47f61d,{'start':_0x2b2fd9,'end':null});_0x380397('isRemoveSuggestion',_0x43bd6a,_0x2b2fd9,_0x22006b),_0x380397('isAddSuggestion',_0x43bd6a,_0x2b2fd9,_0x22006b),_0x380397('isRemoved',_0x43bd6a,_0x2b2fd9,_0x22006b),_0x380397('isAdded',_0x43bd6a,_0x2b2fd9,_0x22006b);for(const _0x422179 of _0x4a118c[_0x43bd6a]['markersEnd']){const _0x12702f=_0x5bb673['get'](_0x422179);_0x12702f?_0x12702f['end']=_0x22006b:_0x5bb673['set'](_0x422179,{'start':_0x22006b,'end':_0x22006b});}}for(const [_0x50f586,_0x2e3949]of _0x5bb673){const _0x2d7f9b=this['editor']['model']['createRange'](_0x2e3949['start'],_0x2e3949['end']);_0x30aba6['markers']['set'](_0x50f586,_0x2d7f9b);}return _0x546c22['sort']((_0x2d81d9,_0x5a126f)=>{const _0x528a5e=_0x30aba6['markers']['get']('revision:'+_0x2d81d9['id']),_0x3e7beb=_0x30aba6['markers']['get']('revision:'+_0x5a126f['id']);return _0x528a5e['start']['isBefore'](_0x3e7beb['start'])?-0x1:_0x528a5e['start']['isAfter'](_0x3e7beb['start'])?0x1:_0x528a5e['end']['isBefore'](_0x3e7beb['end'])?-0x1:_0x528a5e['end']['isAfter'](_0x3e7beb['end'])?0x1:'add'===_0x2d81d9['type']?-0x1:0x1;}),{'root':_0x30aba6,'changes':_0x546c22};function _0x380397(_0x8e8a34,_0x24267c,_0x44b92e,_0x512336){const _0x529406=!!_0x4a118c[_0x24267c][_0x8e8a34],_0x17c700=_0x529406?_0x4a118c[_0x24267c][_0x8e8a34]['userId']:null,_0x154c97=_0x24267c===_0x4a118c['length']-0x1,_0x192811=_0x4150f9[_0x8e8a34][0x0],_0x34def0=_0x189feb['isObject'](_0x4a118c[_0x24267c]['item']);!_0x25e388[_0x8e8a34]&&_0x529406?_0x25e388[_0x8e8a34]={'start':_0x44b92e,'tapeItem':_0x4a118c[_0x24267c],'userId':_0x17c700,'type':_0x8e8a34}:_0x25e388[_0x8e8a34]&&!_0x529406?(_0x25e388[_0x8e8a34]['end']=_0x44b92e,_0x2114bf(_0x25e388[_0x8e8a34]),_0x25e388[_0x8e8a34]=null):_0x25e388[_0x8e8a34]&&_0x529406&&_0x25e388[_0x8e8a34]['userId']!==_0x17c700&&(_0x25e388[_0x8e8a34]['end']=_0x44b92e,_0x192811&&_0x192811['userId']===_0x25e388[_0x8e8a34]['userId']||_0x2114bf(_0x25e388[_0x8e8a34]),_0x25e388[_0x8e8a34]={'start':_0x44b92e,'tapeItem':_0x4a118c[_0x24267c],'userId':_0x17c700,'type':_0x8e8a34}),_0x25e388[_0x8e8a34]&&_0x34def0&&('elementStart'!==_0x4a118c[_0x24267c]['type']||_0x192811&&_0x192811['userId']===_0x17c700||_0x4150f9[_0x8e8a34]['unshift']({'userId':_0x17c700,'object':_0x4a118c[_0x24267c]['item'],'change':_0x25e388[_0x8e8a34]}),'elementEnd'===_0x4a118c[_0x24267c]['type']&&_0x192811&&_0x192811['object']===_0x4a118c[_0x24267c]['item']&&(_0x4150f9[_0x8e8a34]['shift'](),_0x25e388[_0x8e8a34]=_0x192811['change'])),_0x25e388[_0x8e8a34]&&_0x154c97&&(_0x25e388[_0x8e8a34]['end']=_0x512336,_0x2114bf(_0x25e388[_0x8e8a34]),_0x25e388[_0x8e8a34]=null);}function _0x2114bf({start:_0x22bae4,end:_0x4ac3ba,tapeItem:_0x3b16c5,userId:_0x2cf8ad,type:_0x42a602}){const _0x2e34e2=_0x3b16c5['item'],_0x529e95=_0x3ce2c7['schema']['isBlock'](_0x2e34e2)&&!_0x3ce2c7['schema']['isLimit'](_0x2e34e2),_0x504938=_0x22bae4['nodeAfter']==_0x4ac3ba['parent']&&_0x4ac3ba['isAtStart'];if(_0x529e95&&_0x504938)return;const _0x4ad0ba=_0x3ce2c7['createRange'](_0x22bae4,_0x4ac3ba),_0x4c0c3d=_0x2cab0a['get'](_0x2cf8ad),_0x4e1177=new r({'author':_0x4c0c3d,'type':'isAdded'==_0x42a602||'isAddSuggestion'==_0x42a602?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x42a602||'isRemoveSuggestion'==_0x42a602},'createdAt':new Date(),'rootName':_0x26ee84});_0x546c22['push'](_0x4e1177),_0x30aba6['markers']['set']('revision:'+_0x4e1177['id'],_0x4ad0ba);}function _0x34df15(_0x3339df,_0x330719){const _0x553e27=_0x3339df['getAttributes'](),_0x421b56=_0x330719['getAttributes']();for(const _0x2fdc11 of _0x553e27){if(_0x2fdc11[0x1]!==_0x330719['getAttribute'](_0x2fdc11[0x0]))return!0x1;_0x421b56['next']();}return _0x421b56['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x253e3b=>{const _0x1338ef=_0x253e3b['markerName']['split'](':')[0x1],_0xd88bf5=this['_getChangeFromId'](_0x1338ef);if(!_0xd88bf5)return null;const _0x415ca9='add'==_0xd88bf5['type']?'insertion':'deletion',_0x4e6f96=['ck-suggestion-marker','ck-suggestion-marker-'+_0x415ca9];return _0xd88bf5['data']['isSuggestion']&&_0x4e6f96['push']('ck-suggestion-marker-'+_0x415ca9+'-new'),this['activeChange']==_0xd88bf5&&_0x4e6f96['push']('ck-suggestion-marker--active'),{'classes':_0x4e6f96,'attributes':{'data-change-id':_0x1338ef}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x49482c=>{_0x49482c['on']('element:pre',(_0x3a98e5,_0x376003,_0x3f8d9a)=>{const _0x12fb35=_0x376003['viewItem']['getChild'](0x0);if(!_0x12fb35||!_0x12fb35['is']('element','code'))return;if(!_0x3f8d9a['consumable']['consume'](_0x12fb35,{'attributes':['vid_start','vid_end']}))return;const _0x1a8164=_0x376003['modelRange']['start']['nodeAfter'];_0x3f8d9a['writer']['setAttribute']('vid_start',_0x12fb35['getAttribute']('vid_start'),_0x1a8164),_0x3f8d9a['writer']['setAttribute']('vid_end',_0x12fb35['getAttribute']('vid_end'),_0x1a8164);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x289e63=>{_0x289e63['on']('element',(_0x30d5d1,_0x11db2d,_0x4e1c78)=>{if(!_0x4e1c78['consumable']['consume'](_0x11db2d['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x11db2d['modelRange']['isCollapsed'])return;const _0x1017dc=_0x11db2d['modelRange']['start']['nodeAfter'];_0x1017dc['hasAttribute']('vid_start')||_0x1017dc['hasAttribute']('vid')||(_0x4e1c78['writer']['setAttribute']('vid_start',_0x11db2d['viewItem']['getAttribute']('vid_start'),_0x1017dc),_0x4e1c78['writer']['setAttribute']('vid_end',_0x11db2d['viewItem']['getAttribute']('vid_end'),_0x1017dc));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x123810=>_0x123810['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x16cad1,[,_0x142b37])=>{['vid_start','vid_end','vid']['includes'](_0x142b37)&&(_0x16cad1['return']=!0x0,_0x16cad1['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0xdbdae5=>{_0xdbdae5['on']('attribute:vid',(_0x2e6096,_0x54f0f9,_0x10ecee)=>{if('\x20'!=_0x54f0f9['item']['data']||_0x54f0f9['item']['parent']['maxOffset']>0x1)return;if(!_0x10ecee['consumable']['consume'](_0x54f0f9['item'],_0x2e6096['name']))return;const _0x1f674d=_0x10ecee['writer'],_0x350c24=_0x10ecee['mapper']['toViewRange'](_0x54f0f9['range']);_0x1f674d['wrap'](_0x350c24,_0x1f674d['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x153ffd){const _0x5d06eb=_0x153ffd['plugins']['get']('RevisionViewer');return(_0xfc29cb,_0x28f332,_0x4615a0)=>{const _0x5e2473=_0x28f332['markerName']['split'](':')[0x1],_0x32f487=_0x5d06eb['_getChangeFromId'](_0x5e2473);if(!_0x32f487)return null;const _0xb503ad='add'==_0x32f487['type']?'split':'merge';if(!_0x4615a0['consumable']['test'](_0x28f332['markerRange'],_0xfc29cb['name']))return;const _0x5cd5a8=_0x28f332['markerRange']['getWalker'](),_0x43020f=_0x28f332['markerRange']['start'],_0x2e52a7=_0x153ffd['model']['schema'];let _0x1b8f73=null,_0x287c8d=null,_0x31665f=!0x1,_0x73c3f6=!0x1;for(const _0x4a4b0c of _0x5cd5a8){const _0x4327da=_0x4a4b0c['item'];_0x31665f=_0x31665f||_0x2e52a7['isContent'](_0x4327da);const _0x3f399d=_0x4615a0['mapper']['toViewElement'](_0x4327da);if(_0x3f399d&&_0x3f399d['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x4a4b0c['type']&&(_0x2e52a7['isBlock'](_0x4327da)&&!_0x2e52a7['isLimit'](_0x4327da)&&(_0x4327da['nextSibling']||_0x43020f['isAtEnd']?_0x1b8f73&&_0x1b8f73['parent']==_0x4327da||(_0x1b8f73=_0x4327da,_0x5b2296(_0x4a4b0c['previousPosition']),_0x73c3f6=!0x0):_0x287c8d=_0x287c8d||_0x4a4b0c['previousPosition']));}function _0x5b2296(_0x1abc6a){const _0x2dbde6=_0x4615a0['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0xb503ad}),_0xf38e9c=_0x4615a0['mapper']['toViewPosition'](_0x1abc6a);_0x32f487['data']['isSuggestion']&&_0x4615a0['writer']['addClass']('ck-suggestion-marker-'+_0xb503ad+'-new',_0x2dbde6),_0x5d06eb['activeChange']==_0x32f487&&_0x4615a0['writer']['addClass']('ck-suggestion-marker--active',_0x2dbde6),_0x4615a0['writer']['insert'](_0xf38e9c,_0x2dbde6),_0x4615a0['mapper']['bindElementToMarker'](_0x2dbde6,_0x28f332['markerName']);}_0x31665f||_0x73c3f6||!_0x287c8d||_0x5b2296(_0x287c8d);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x15174c,_0x16a14c,_0x363a54)=>{const _0x108f5f=_0x363a54['mapper']['markerNameToElements'](_0x16a14c['markerName']);if(_0x108f5f){for(const _0x503142 of _0x108f5f)(_0x503142['hasClass']('ck-suggestion-marker-split')||_0x503142['hasClass']('ck-suggestion-marker-merge'))&&(_0x363a54['mapper']['unbindElementFromMarkerName'](_0x503142,_0x16a14c['markerName']),_0x363a54['writer']['remove'](_0x503142));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x1a2b58,_0x4892bb,_0x2c5d2f)=>{const _0x504202=_0x4892bb['markerName']['split'](':')[0x1],_0x42c0af=this['_getChangeFromId'](_0x504202);if(!_0x42c0af)return null;const _0x5fc982='add'==_0x42c0af['type']?'split':'merge';if(_0x2c5d2f['consumable']['test'](_0x4892bb['markerRange'],_0x1a2b58['name']))for(const _0x4e416d of _0x4892bb['markerRange']['getItems']()){if(!_0x4e416d['is']('element','softBreak'))continue;const _0xbc7042=_0x2c5d2f['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x5fc982}),_0x185e73=_0x2c5d2f['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x4e416d));_0x42c0af['data']['isSuggestion']&&_0x2c5d2f['writer']['addClass']('ck-suggestion-marker-'+_0x5fc982+'-new',_0xbc7042),this['activeChange']==_0x42c0af&&_0x2c5d2f['writer']['addClass']('ck-suggestion-marker--active',_0xbc7042),_0x2c5d2f['writer']['insert'](_0x185e73,_0xbc7042),_0x2c5d2f['mapper']['bindElementToMarker'](_0xbc7042,_0x4892bb['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x1caf1a=>{for(const _0x2cf07c of this['editor']['model']['document']['getRootNames']()){const _0x2aca9a=this['editor']['model']['document']['getRoot'](_0x2cf07c),_0x128998=this['editor']['editing']['view']['document']['getRoot'](_0x2cf07c);if(_0x128998){const _0x59ac6a=_0x2aca9a['getAttribute']('revisionHistoryAttachChange');if(_0x1caf1a['removeAttribute']('data-change-id',_0x128998),_0x1caf1a['removeClass']('ck-revision-history-root-add',_0x128998),_0x1caf1a['removeClass']('ck-revision-history-root-remove',_0x128998),_0x1caf1a['removeClass']('ck-revision-history-root--active',_0x128998),_0x59ac6a){const _0xbf9699=this['_getChangeFromId'](_0x59ac6a);if(!_0xbf9699)return null;_0x1caf1a['setAttribute']('data-change-id',_0x59ac6a,_0x128998),_0x1caf1a['addClass']('ck-revision-history-root-'+_0xbf9699['type'],_0x128998),this['activeChange']==_0xbf9699&&_0x1caf1a['addClass']('ck-revision-history-root--active',_0x128998);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x3bc41b=>'revision-comment:'+_0x3bc41b,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0xdf1611=>'revision-suggestion:'+_0xdf1611,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x52beb7=>({'name':'suggestion:'+_0x52beb7,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x1b9b1f=>{const _0x1685b3=_0x1b9b1f['markerName']['split'](':')[0x1];return'insertion'!=_0x1685b3&&'deletion'!=_0x1685b3?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x1685b3]};}}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:deletion',X(this['editor'],'merge'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:insertion',X(this['editor'],'split'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision-suggestion',(_0x57fb81,_0x30effa,_0x34f326)=>{const _0x5277a6=_0x34f326['mapper']['markerNameToElements'](_0x30effa['markerName']);if(_0x5277a6){for(const _0x209dbc of _0x5277a6)_0x209dbc['is']('uiElement')&&(_0x34f326['mapper']['unbindElementFromMarkerName'](_0x209dbc,_0x30effa['markerName']),_0x34f326['writer']['remove'](_0x209dbc));}},{'priority':'high'});}['_getChangeFromId'](_0x2220eb){return this['_changeIdToChange']['get'](_0x2220eb);}['_getViewForChange'](_0x5429a6){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new Q(this['editor']['locale'],_0x5429a6),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x5e0962,_0xe4f77c,_0x346c4f,_0x2f4619)=>{_0x2f4619&&this['_balloon']['remove'](_0x2f4619),_0x346c4f&&(this['_balloon']['add']({'view':_0x346c4f,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x2bf01c=this['editor']['editing'],_0x2a69d3=this['_getChangeFromId'](_0x346c4f['changeId']);let _0x5ba45a;if(_0x2a69d3['data']['isOnRoot']){const _0x46b9fd=_0x2bf01c['view']['getDomRoot'](_0x2a69d3['rootName']);_0x5ba45a=Array['from'](_0x46b9fd['getClientRects']());}else{const _0x279f07=this['editor']['model']['markers']['get']('revision:'+_0x346c4f['changeId']);_0x5ba45a=Array['from'](_0x2bf01c['mapper']['markerNameToElements'](_0x279f07['name']))['map'](_0x10b914=>_0x2bf01c['view']['domConverter']['mapViewToDom'](_0x10b914))['map'](_0x46a6cc=>Array['from'](_0x46a6cc['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x5ba45a[0x0];return _0x5ba45a['find'](_0x983814=>_0x983814['top']-0x3<=this['_activeViewTarget']['y']&&_0x983814['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x983814['left']-0x3<=this['_activeViewTarget']['x']&&_0x983814['right']+0x3>=this['_activeViewTarget']['x'])||_0x5ba45a[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0xecb74f,_0x99d789,_0x33a802,_0x1aa5e6)=>{this['activeView']=_0x33a802?this['_getViewForChange'](_0x33a802):null,this['editor']['model']['change'](()=>{const _0x1a1dfc=this['editor']['editing'];_0x1aa5e6&&(_0x1aa5e6['data']['isOnRoot']?_0x1a1dfc['view']['change'](_0x596388=>{_0x596388['removeClass']('ck-revision-history-root--active',_0x1a1dfc['view']['document']['getRoot'](_0x1aa5e6['rootName']));}):_0x1a1dfc['reconvertMarker']('revision:'+_0x1aa5e6['id'])),_0x33a802&&(_0x33a802['data']['isOnRoot']?_0x1a1dfc['view']['change'](_0x1fd2b0=>{_0x1fd2b0['addClass']('ck-revision-history-root--active',_0x1a1dfc['view']['document']['getRoot'](_0x33a802['rootName']));}):_0x1a1dfc['reconvertMarker']('revision:'+_0x33a802['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x59634a,_0x573c8a)=>{if(this['activeChange'])return;const _0x518df7=this['_findChangeIdFromDomTarget'](_0x573c8a['target']),_0x357b7d=this['_changeIdToChange']['get'](_0x518df7);_0x357b7d?(this['_activeViewTarget']={'x':_0x573c8a['domEvent']['x'],'y':_0x573c8a['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x357b7d)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x135bc5,_0x2503ff)=>{const _0x760a80=this['_findChangeIdFromDomTarget'](_0x2503ff['target']),_0x5607e3=this['_changeIdToChange']['get'](_0x760a80);_0x5607e3?(this['_activeViewTarget']={'x':_0x2503ff['domEvent']['x'],'y':_0x2503ff['domEvent']['y']},_0x5607e3===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x5607e3):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x584f50){do{const _0x3b1322=_0x584f50['getAttribute']('data-change-id');if(_0x3b1322)return _0x3b1322;_0x584f50=_0x584f50['parent'];}while(_0x584f50);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x50d6c6=>{for(const _0x413a77 of this['editor']['model']['markers'])_0x50d6c6['removeMarker'](_0x413a77);});}}function X(_0x476962,_0x41432b){return(_0x189a40,_0x21bcf0,_0x16e814)=>{if(!_0x16e814['consumable']['test'](_0x21bcf0['markerRange'],_0x189a40['name']))return;const _0x253303=_0x21bcf0['markerRange']['getWalker'](),_0x536c75=_0x21bcf0['markerRange']['start'],_0x1d1149=_0x476962['model']['schema'];let _0x3f0fa5=null,_0x1fcdec=null,_0x53b069=!0x1,_0x597dde=!0x1;for(const _0x2ed082 of _0x253303){const _0x1f559d=_0x2ed082['item'];_0x53b069=_0x53b069||_0x1d1149['isContent'](_0x1f559d);const _0x14d91d=_0x16e814['mapper']['toViewElement'](_0x1f559d);if(_0x14d91d&&_0x14d91d['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x2ed082['type']&&(_0x1d1149['isBlock'](_0x1f559d)&&!_0x1d1149['isLimit'](_0x1f559d)&&(_0x1f559d['nextSibling']||_0x536c75['isAtEnd']?_0x3f0fa5&&_0x3f0fa5['parent']==_0x1f559d||(_0x3f0fa5=_0x1f559d,_0x59cebd(_0x2ed082['previousPosition']),_0x597dde=!0x0):_0x1fcdec=_0x1fcdec||_0x2ed082['previousPosition']));}function _0x59cebd(_0x214af3){const _0x410fb9=_0x16e814['mapper']['toViewPosition'](_0x214af3),_0x2316c0=_0x16e814['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x41432b});_0x16e814['writer']['insert'](_0x410fb9,_0x2316c0),_0x16e814['mapper']['bindElementToMarker'](_0x2316c0,_0x21bcf0['markerName']);}_0x53b069||_0x597dde||!_0x1fcdec||_0x59cebd(_0x1fcdec);};}class mt extends _0x209300{constructor(_0x148142){super(_0x148142);const _0xaefba7=_0x148142['plugins']['get'](m);this['affectsData']=!0x1,this['listenTo'](_0xaefba7,'change:isReady',()=>this['refresh']()),this['listenTo'](_0xaefba7,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x18aba6=this['editor'],_0x2b1a91=_0x18aba6['plugins']['get'](m),_0x25d4f6=_0x2b1a91['isReady']?_0x2b1a91['diff']['newRevisionId']:null;_0x18aba6['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x25d4f6);}['refresh'](){const {isReady:_0x225d48,isEnabled:_0x1c74c2,repository:_0x51662e,diff:_0x58b2d6}=this['editor']['plugins']['get'](m),_0x5dc396=_0x58b2d6&&_0x51662e['getLaterVisibleRevision'](_0x58b2d6['newRevisionId']);this['isEnabled']=_0x225d48&&_0x1c74c2&&Boolean(_0x5dc396);}}class wt extends _0x209300{['_step'];constructor(_0x29c5d4,{direction:_0x4662bf}){super(_0x29c5d4);const _0x262bc9=_0x29c5d4['plugins']['get'](m);this['affectsData']=!0x1,this['_step']='forward'===_0x4662bf?0x1:-0x1,this['listenTo'](_0x262bc9,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x262bc9,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x262bc9,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x1b423c=this['editor'],_0x22b18c=_0x1b423c['plugins']['get'](m),{isNavigationMode:_0x5b0976,currentChangeNumber:_0xc3c2aa}=_0x22b18c;let _0x53f1d8;if(_0x22b18c['activeChange']=_0x5b0976?_0x22b18c['diff']['changes']['get'](_0xc3c2aa+this['_step']):_0x22b18c['diff']['changes']['first'],_0x22b18c['activeChange']['data']['isOnRoot'])_0x53f1d8=_0x1b423c['editing']['view']['getDomRoot'](_0x22b18c['activeChange']['rootName']);else{const _0x39317d=_0x1b423c['model']['markers']['get']('revision:'+_0x22b18c['activeChange']['id']);_0x53f1d8=_0x1a9bee(_0x1b423c['editing'],_0x39317d);}_0x2b83d3({'target':_0x53f1d8,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x56bef2,currentChangeNumber:_0x464245,numberOfChanges:_0x1bb179,isReady:_0x4233e9,isEnabled:_0x26bff1}=this['editor']['plugins']['get'](m);this['isEnabled']=!!(_0x26bff1&&_0x4233e9&&_0x1bb179)&&(!_0x56bef2||(0x1===this['_step']?_0x464245<_0x1bb179-0x1:_0x464245>0x0));}}class li extends ts{constructor(_0x3a0239){super(_0x3a0239);const _0x242d7f=this['bindTemplate'],_0x186097=new te(_0x3a0239),_0xb922c7=new te(_0x3a0239);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',(_0x276e02,_0x39d3c9)=>_0x276e02&&_0x39d3c9>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x485d4c,_0x4881ee,_0x1eddbd,_0x17a0ac)=>{if(!_0x485d4c)return g(_0x3a0239,'Loading...');if(!_0x1eddbd)return g(_0x3a0239,'No\x20changes');const _0xa7707a=g(_0x3a0239,'NUMBER_OF_CHANGES',_0x1eddbd);return _0x17a0ac?g(_0x3a0239,'X_OF_Y_CHANGES',[_0x4881ee+0x1,_0x1eddbd]):_0xa7707a;}),_0x186097['set']({'label':g(_0x3a0239,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x314266}),_0xb922c7['set']({'label':g(_0x3a0239,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x1ae486}),_0x186097['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0xb922c7['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x186097['on']('execute',()=>this['fire']('execute','backward')),_0xb922c7['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',_0x242d7f['if']('_isStatusLabelVisible','ck-hidden',_0x3e7539=>!_0x3e7539)]},'children':[{'text':_0x242d7f['to']('isNavigationMode',_0xf22d5c=>_0xf22d5c?g(_0x3a0239,'EDIT_X_OF_Y_REVISIONS')+':\x20':g(_0x3a0239,'Total')+':\x20')}]},{'text':_0x242d7f['to']('_statusText')}]},new _0x49f084(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x186097,_0xb922c7]}]});}}const le='ck-editor__editable__loading-overlay';class ge extends _0x215f3d{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x37471e=this['editor']['editing']['view'];_0x37471e['change'](_0x4a1572=>{for(const _0x315402 of _0x37471e['document']['roots'])_0x4a1572['addClass'](le,_0x315402);});}['hide'](){const _0x5ee7db=this['editor']['editing']['view'];_0x5ee7db['change'](_0x453b54=>{for(const _0xe36358 of _0x5ee7db['document']['roots'])_0x453b54['removeClass'](le,_0xe36358);});}}class R extends _0x215f3d{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[m,ge];}['init'](){const _0x31d7e3=this['editor'],_0x5d474e=_0x31d7e3['plugins']['get'](m),_0x2badda=_0x31d7e3['plugins']['get'](ge);_0x31d7e3['ui']['componentFactory']['add']('exitToEditing',_0x15c24c=>{const _0x4cbd2f=new te(_0x15c24c);return _0x4cbd2f['set']({'label':g(_0x15c24c,'Back\x20to\x20editing'),'icon':_0x1a92ae,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x4cbd2f,'execute',()=>{_0x31d7e3['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x4cbd2f;}),_0x31d7e3['ui']['componentFactory']['add']('restoreRevision',_0x5df51c=>{const _0x19d1e4=new te(_0x5df51c);return _0x19d1e4['set']({'label':g(_0x5df51c,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x19d1e4['bind']('isEnabled')['to'](_0x31d7e3['commands']['get']('restoreRevision')),this['listenTo'](_0x19d1e4,'execute',()=>_0x31d7e3['execute']('restoreRevision')),_0x19d1e4;}),_0x31d7e3['ui']['componentFactory']['add']('changesNavigation',_0x4dcd74=>{const _0x27bf6c=new li(_0x4dcd74),_0x1c1e33=_0x31d7e3['commands']['get']('showPreviousChange'),_0x568bb3=_0x31d7e3['commands']['get']('showNextChange');return _0x27bf6c['bind']('isBackwardNavigationEnabled')['to'](_0x1c1e33,'isEnabled'),_0x27bf6c['bind']('isForwardNavigationEnabled')['to'](_0x568bb3,'isEnabled'),_0x27bf6c['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x5d474e),this['listenTo'](_0x27bf6c,'execute',(_0x5b48b6,_0x208e73)=>{_0x31d7e3['execute']('forward'===_0x208e73?'showNextChange':'showPreviousChange');}),_0x27bf6c;}),_0x2badda['show'](),_0x5d474e['on']('change:isReady',(_0x5a5883,_0x18bf31,_0x55f504)=>{_0x55f504?_0x2badda['hide']():_0x2badda['show']();});}}class at extends _0x53f8a9{['_resizeObserver']=null;constructor(_0x427673,_0x356113){super(_0x427673,_0x356113);const _0x327939=this['bindTemplate'];this['set']({'label':g(_0x427673,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=g(_0x427673,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x327939['to']('_tooltipString'),'data-cke-tooltip-position':'s','data-cke-tooltip-class':'ck-tooltip_multi-line'}});}['render'](){super['render'](),this['_resizeObserver']=new nt(this['fieldView']['element'],()=>this['_updateTooltipText']()),this['listenTo'](this['fieldView'],'input',()=>this['_updateTooltipText']());}['destroy'](){super['destroy'](),this['_resizeObserver']&&this['_resizeObserver']['destroy']();}['_updateTooltipText'](){const _0x4e3a4c=this['fieldView']['element'];this['_tooltipString']=_0x4e3a4c['scrollWidth']>_0x4e3a4c['clientWidth']&&_0x4e3a4c['value']||'';}}class oi extends ts{constructor(_0x56bc1d,_0xb43b6c,_0xf7cc27){super(_0x56bc1d);const _0x5afac8=new _0x4d07d2();_0x5afac8['set']({'content':_0xcd8008,'viewBox':'0\x200\x2011\x2010'});const _0x330a9b=['ck','ck-revision-history-sidebar__revision-author'];_0xf7cc27&&_0x330a9b['push']('ck-revision-history-sidebar__revision-author_creator');const _0x5347e7=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':g(_0x56bc1d,_0xf7cc27?'Revision\x20creator':'Revision\x20author')},'children':[_0x5afac8,_0xb43b6c['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x330a9b},'children':_0x5347e7});}}function ai(_0x41062a,_0xd318fb){const _0x5c291b=_0x41062a['bindTemplate'],_0x339987=_0x41062a['locale'],_0x2a579e=_0x41d57a(_0x339987);_0x2a579e['panelPosition']='sw';const _0x547932=function(_0x58c3f7,_0x32a392){const _0x5bc5a5=function(_0x36ba59,_0x1eef44){const _0x1c40b8=_0x36ba59['locale'],_0x4fe729={'Compare\x20against\x20selected':g(_0x1c40b8,'Compare\x20against\x20selected'),'Name\x20this\x20revision':g(_0x1c40b8,'Name\x20this\x20revision'),'Restore\x20this\x20revision':g(_0x1c40b8,'Restore\x20this\x20revision')};return _0x1eef44['map'](_0x13e099=>{const _0x66efd=_0x4fe729[_0x13e099['name']];return _0x66efd&&_0x66efd!==_0x13e099['name']&&(_0x13e099['name']=_0x66efd),_0x13e099;});}(_0x58c3f7,_0x32a392),_0x3bf32e=new _0x3b3f60();for(const _0xa58a08 of _0x5bc5a5){const _0x1573bc={'type':'button','model':new to({'label':_0xa58a08['name'],'class':_0xa58a08['class'],'withText':!0x0,'role':'menuitem','_action':_0xa58a08['action']})};_0x1573bc['model']['bind']('isEnabled')['to'](_0x58c3f7,'isActionsDropdownOpen',_0x70cb65=>'function'!=typeof _0xa58a08['isEnabled']||(!_0x70cb65||_0xa58a08['isEnabled'](_0x58c3f7))),_0x3bf32e['add'](_0x1573bc);}return _0x3bf32e;}(_0x41062a,_0xd318fb);return _0x41062a['bind']('isActionsDropdownOpen')['to'](_0x2a579e,'isOpen'),_0x2a579e['buttonView']['set']({'label':g(_0x339987,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x57e1b8}),_0x2a579e['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x5c291b['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x5c291b['to'](_0x1b68d3=>_0x1b68d3['stopPropagation']())}}),_0x2a579e['on']('execute',_0xcc8977=>{_0x41062a['isReady']&&'function'==typeof _0xcc8977['source']['_action']&&_0xcc8977['source']['_action'](_0x41062a);}),_0x31792c(_0x2a579e,_0x547932,{'role':'menu'}),_0x2a579e['listenTo'](_0x41062a,'change:isActionsDropdownOpen',(_0x4c62a1,_0x4d98e4,_0x264dc0)=>{if(_0x264dc0)for(const _0x5207fd of _0x2a579e['listView']['items']){const _0x45b32d=_0x5207fd['children']['first'],_0x14b045=_0xd318fb['find'](_0x4d34cc=>_0x4d34cc['action']===_0x45b32d['_action'])['isVisible'];_0x5207fd['isVisible']=void 0x0===_0x14b045||_0x14b045(_0x41062a);}}),_0x2a579e;}class si extends/* #__PURE__ -- @preserve */
|
|
26
|
+
_0x3e9bdc(ts){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x5ed471,_0x2c0a74,_0x5ec0a0,_0x1ae1ae){super(_0x5ed471);const _0xdf98cc=this['bindTemplate'],_0x57273b=function(_0x28fb6f,_0xa2fe69){const _0x18c250=Array['from'](_0xa2fe69['authors'])['filter'](_0xd350c3=>_0xd350c3!=_0xa2fe69['creator']);return _0xa2fe69['creator']&&_0x18c250['unshift'](_0xa2fe69['creator']),_0x18c250['map'](_0x4ac90d=>new oi(_0x28fb6f,_0x4ac90d,_0x4ac90d==_0xa2fe69['creator']));}(_0x5ed471,_0x2c0a74);this['id']=_0x2c0a74['id'],this['_revision']=_0x2c0a74,this['_requireRevisionName']=_0x1ae1ae,this['bind']('name','createdAt')['to'](_0x2c0a74),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x563934=>{return _0x5a6752=_0x5ed471['uiLanguage'],(_0x4f8c6e=_0x563934)['toLocaleDateString'](_0x5a6752,{'month':'long','day':'numeric'})+',\x20'+_0x4f8c6e['toLocaleTimeString'](_0x5a6752,{'hour':'numeric','minute':'numeric'});var _0x5a6752,_0x4f8c6e;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new at(_0x5ed471,_0x33ff0f),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x4184b8=>_0x4184b8||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x428c53,_0x250875)=>_0x428c53&&_0x250875),this['revisionActionsView']=_0x5ec0a0&&_0x5ec0a0['length']?ai(this,_0x5ec0a0):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0xdf98cc['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0xdf98cc['if']('isEnabled','ck-disabled',_0x471127=>!_0x471127),_0xdf98cc['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0xdf98cc['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0xdf98cc['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':_0xdf98cc['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':_0x57273b}]},this['revisionActionsView']],'on':{'click':_0xdf98cc['to'](_0xb19bbf=>{_0xb19bbf['srcElement']['closest']('.ck-thread__remove-confirm')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x5d7f1d=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x5d7f1d,'change',()=>{this['_requireRevisionName']&&!_0x5d7f1d['value']||this['fire']('setName',{'id':this['id'],'name':_0x5d7f1d['value']}),_0x5d7f1d['value']||(_0x5d7f1d['value']=this['name']?this['name']:this['_createdAtFormatted']);});}['select'](){this['isSelected']=!0x0;}['deselect'](){this['isSelected']=!0x1;}['highlight'](){this['isHighlighted']=!0x0;}['unhighlight'](){this['isHighlighted']=!0x1;}}function ti(_0x39d303,_0x3adcd5){const _0x1ed52b=_0x5e9815['fromJSDate'](_0x39d303)['setLocale'](_0x3adcd5),_0x27e8f7=_0x5e9815['local'](),_0x43c0ca=_0x27e8f7['minus']({'days':0x1})['startOf']('day');let _0x2c504f,_0x432f;return _0x1ed52b['hasSame'](_0x27e8f7,'day')?(_0x2c504f=_0x1ed52b['startOf']('day')['toJSDate'](),_0x432f=_0x1ed52b['toRelativeCalendar']()):_0x1ed52b['hasSame'](_0x43c0ca,'day')?(_0x2c504f=_0x43c0ca['toJSDate'](),_0x432f=_0x1ed52b['toRelativeCalendar']()):_0x1ed52b['hasSame'](_0x27e8f7,'week')?(_0x2c504f=_0x1ed52b['startOf']('week')['toJSDate'](),_0x432f=_0x1ed52b['weekdayLong']||''):_0x1ed52b['hasSame'](_0x27e8f7,'year')?(_0x2c504f=_0x1ed52b['startOf']('month')['toJSDate'](),_0x432f=_0x1ed52b['monthLong']||''):(_0x2c504f=_0x1ed52b['startOf']('year')['toJSDate'](),_0x432f=String(_0x1ed52b['year'])),{'startDate':_0x2c504f,'localizedPeriodName':_0x432f};}class ei extends ts{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x494409,_0x5723a9,_0x37e194,_0x2385e2){super(_0x494409);const _0x40b105=ti(_0x5723a9,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x5723a9,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x37e194,this['_requireRevisionName']=_0x2385e2,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':_0x40b105}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x177ecd){const _0x572b0d=new si(this['locale'],_0x177ecd,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x572b0d);}['removeRevision'](_0x377bda){const _0x54ce61=this['revisionViews']['find'](_0x2dba2f=>_0x2dba2f['id']===_0x377bda['id']);this['revisionViews']['remove'](_0x54ce61);}}class cs extends ts{constructor(_0x5079d2){super(_0x5079d2);const _0x53c341=new _0x4d07d2();_0x53c341['content']=_0x14d782,this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x53c341,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[g(_0x5079d2,'Revision\x20history')]}]});}}class ii extends ts{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x21ef0c,_0x211e17,_0x3423bf,_0x5731f0){super(_0x21ef0c);const _0x35e760=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x211e17,this['_revisionActions']=_0x3423bf,this['_requireRevisionName']=_0x5731f0,this['on']('select',(_0xa40c6d,_0x75f5c4)=>{this['fire']('revisionSelected',_0x75f5c4);}),this['on']('setName',(_0x931023,_0x2ba2fa)=>{this['fire']('revisionSetName',_0x2ba2fa);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new cs(_0x21ef0c),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x35e760['if']('isEnabled','ck-disabled',_0x256c48=>!_0x256c48)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x6f397f of this['_revisions'])this['_addRevision'](_0x6f397f);this['_revisions']['on']('add',(_0x423801,_0x54de3e)=>{this['_addRevision'](_0x54de3e);}),this['_revisions']['on']('remove',(_0x48ca86,_0x521efc)=>{this['_removeRevision'](_0x521efc);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x5cadef=>_0x5cadef['revisionViews']['map'](_0x12f123=>_0x12f123))['flat']();}['selectRevision'](_0x43d87c){for(const _0x2010e2 of this['revisionViews'])_0x43d87c&&_0x43d87c['id']===_0x2010e2['id']?_0x2010e2['select']():_0x2010e2['deselect']();}['highlightRevisions'](_0xd9ee2d){for(const _0xd9e50c of this['revisionViews'])_0xd9ee2d['some'](({id:_0x1e0bd7})=>_0x1e0bd7===_0xd9e50c['id'])?_0xd9e50c['highlight']():_0xd9e50c['unhighlight']();}['_addRevision'](_0x41fc11){const _0xd1673e=ti(_0x41fc11['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x204d4b=this['timePeriodViews']['get'](0x0);_0x204d4b&&_0x204d4b['startDate']['getTime']()===_0xd1673e['getTime']()||(_0x204d4b=new ei(this['locale'],_0xd1673e,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x204d4b)),_0x204d4b['addRevision'](_0x41fc11);}['_removeRevision'](_0x360324){const _0x2343fe=ti(_0x360324['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x2343fe)['removeRevision'](_0x360324);}['_getTimePeriodViewByStartDate'](_0x541d7f){return this['timePeriodViews']['find'](_0x11358c=>_0x11358c['startDate']['getTime']()===_0x541d7f['getTime']());}}class d extends _0x215f3d{['_revisionViewer'];['_revisionsRepository'];['_sidebarView'];static ['defaultRevisionActions']=/* #__PURE__ -- @preserve */
|
|
27
27
|
((()=>['compareAgainstSelected','restoreRevision','nameRevision'])());static ['availableRevisionActions']=/* #__PURE__ -- @preserve */
|
|
28
|
-
pt();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[m];}constructor(
|
|
29
|
-
_0x52547e(_0x3270d8){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x723ecf,_0x44effd){super(_0x44effd),this['sourceElement']=_0x723ecf,this['model']['document']['createRoot']();const _0x418b62=new it(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new tt(this,_0x418b62);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x1b5bc8,_0x24ee4a){const _0x2e5d00=new this(_0x1b5bc8,_0x24ee4a);return await _0x2e5d00['initPlugins'](),await _0x2e5d00['ui']['init'](_0x1b5bc8),await _0x2e5d00['data']['init'](_0x2e5d00['config']['get']('initialData')||''),_0x2e5d00['fire']('ready'),_0x2e5d00;}}const p=['RevisionHistoryUI','RestrictedEditingMode'];class _t extends _0x527fd9{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x381c68){function _0x424474(_0x18adeb){return _0x18adeb['map'](_0x1c44cb=>String['fromCharCode'](_0x1c44cb))['join']('');}super(_0x381c68),this['result']='end',_0x381c68[_0x424474([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x424474([0x76,0x69,0x65,0x77])][_0x424474([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x424474([0x61,0x75,0x74,0x6f]),_0x381c68[_0x424474([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x424474([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x424474([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x424474([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x424474([0x6f,0x6b])});}}class k extends _0x527fd9{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u,f];}constructor(_0x45d8be){if(super(_0x45d8be),!this['editor']['config']['get']('revisionHistory'))throw new _0x5afe82('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x1928c5=>this['_showRevisionViewer']({..._0x1928c5,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x148853=>this['_closeRevisionViewer'](_0x148853)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x523f3f=>this['_restoreRevision'](_0x523f3f)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x4f6ee5){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x4f6ee5;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0xb76c5b){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0xb76c5b);}['getRevision'](_0x572d6d){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x572d6d);}['getRevisions'](_0x16fd41){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x16fd41||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x4117b1=this['editor'],_0x12e5b3=_0x5ba2f0(_0x4117b1,p),_0x2dfb8e=_0x4117b1['plugins']['get']('RevisionTracker'),_0x2805d2=_0x4117b1['plugins']['get']('Users')['users'];return _0x12e5b3['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x12e5b3['lazyRoots'],(_0x12e5b3['plugins']['push'](_t,m,R,class extends _0x527fd9{static get['requires'](){return[m,'Users'];}['init'](){const _0xf5b3eb=this['editor']['plugins']['get']('Users');for(const _0x1fe626 of _0x2805d2)_0x1fe626['isAnonymous']||_0xf5b3eb['getUser'](_0x1fe626['id'])||_0xf5b3eb['addUser'](_0x1fe626);const _0x5bc591=_0x2dfb8e['repository']['getRevisions']();let _0x6c076=null;const _0x472af6=this['editor']['plugins']['get']('RevisionViewer');_0x472af6['adapter']=_0x2dfb8e['adapter'],_0x472af6['bind']('isEnabled')['to'](_0x2dfb8e),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x4117b1,'isReadOnly',_0x125992=>!_0x125992);for(const _0x2d6f51 of _0x5bc591){const _0x53139a=null===_0x2d6f51['creator'];if(_0x53139a&&_0x2d6f51['toVersion']===_0x2d6f51['fromVersion'])continue;const _0x100b1c=_0x2d6f51['toJSON']();_0x472af6['addRevisionData'](_0x100b1c,(_0xd6d8f2,_0x54f86e,_0x13168a)=>{if(_0x53139a){if(_0x6c076)_0x6c076['_update'](_0xd6d8f2,_0x54f86e);else{if(!_0x54f86e){const _0x4584d5=_0x13168a['toJSON']();_0x4584d5['id']=_0x571ba5(),_0x2dfb8e['saveRevision'](_0x4584d5,_0x13168a['toVersion'])['then'](_0xe2ba43=>{_0x6c076=_0xe2ba43;});}}}else _0x2d6f51['_update'](_0xd6d8f2,_0x54f86e);});}}},d),_0x12e5b3);}['_enhanceShowRevisionViewerCallback'](){const _0x33f819=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x2bbd20=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x12a507=this['editor']['plugins']['get']('Autosave');await _0x12a507['save']();}else await _0x2bbd20['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0xbdde47=this['editor']['plugins']['get']('Dialog');_0xbdde47['isOpen']&&_0xbdde47['hide']();}const _0x160676=this['_getRevisionViewerEditorConfig']();return _0x33f819(_0x160676)['then'](_0x6d07bf=>{return(this['_viewerEditor']=_0x6d07bf,this['editor']['plugins']['has']('Annotations'))&&this['editor']['plugins']['get']('Annotations')['refreshVisibility'](),(this['editor']['plugins']['has']('DocumentOutline')&&(this['editor']['plugins']['get']('DocumentOutlineUI')['view']['element']['style']['display']='none'),_0x6d07bf);})['catch'](_0x122322=>(console['error'](_0x122322),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x5fe5f1=this['editor']['config']['get']('revisionHistory')['closeRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.closeRevisionViewerCallback',()=>(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('DocumentOutline')&&(this['editor']['plugins']['get']('DocumentOutlineUI')['view']['element']['style']['display']=''),this['_viewerEditor']['plugins']['get']('RevisionViewer')['_cleanUp'](),_0x5fe5f1(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x5081c2=this['editor']['plugins']['get']('Annotations');_0x5081c2['refreshVisibility'](),_0x5081c2['refreshPositioning']();}})));}['_showRevisionViewer'](_0x42af73){const _0x19b2ff=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x41bef6=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x45f63d=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return w['create'](_0x45f63d,_0x42af73)['then'](_0xa4032f=>(_0x41bef6['style']['display']='block',_0x19b2ff['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0xa4032f));}['_closeRevisionViewer'](_0x5769b2){const _0x3de08a=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x3de08a['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x5769b2['destroy']();}async['_restoreRevision'](_0x22349c){const _0xf7e22f=this['editor'],_0x3f71f5=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x395d84=_0xf7e22f['plugins']['get']('RevisionTracker'),_0x11e497=_0xf7e22f['plugins']['get']('RevisionHistoryUtils'),_0x26c4b8=_0x3f71f5['repository']['getRevision'](_0x22349c);let _0x457d7b,_0x5855c0,_0x2122ff;try{await _0x11e497['loadRevisionData'](_0x26c4b8,this['adapter']),_0x457d7b=_0x11e497['getRevisionDocumentData'](_0x26c4b8),_0x5855c0=_0x11e497['getRevisionRootsAttributes'](_0x26c4b8);}catch(_0x16ddd8){return void console['error'](_0x16ddd8);}_0xf7e22f['model']['change'](_0x3ad997=>{for(const _0x574d99 of Array['from'](_0xf7e22f['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x3ad997['removeMarker'](_0x574d99);}),_0x3f71f5['isReady']=!0x1,_0xf7e22f['model']['enqueueChange'](_0x45c660=>{_0x45c660['setSelection'](null),_0x45c660['removeSelectionAttribute'](_0xf7e22f['model']['document']['selection']['getAttributeKeys']());const _0x4358e9=Object['keys'](_0x457d7b);for(const _0x34b67c of _0xf7e22f['model']['document']['roots'])'$graveyard'!=_0x34b67c['rootName']&&_0x34b67c['isAttached']()&&!_0x4358e9['includes'](_0x34b67c['rootName'])&&_0x45c660['detachRoot'](_0x34b67c);for(const _0x12599f of _0x4358e9){let _0x40aaa8=_0xf7e22f['model']['document']['getRoot'](_0x12599f);_0x40aaa8&&_0x40aaa8['isAttached']()||(_0x40aaa8=_0x45c660['addRoot'](_0x12599f));const _0x2fd5c0=_0x5855c0[_0x12599f],_0x4df9c8=Object['keys'](_0x2fd5c0),_0x43c17a=_0x457d7b[_0x12599f];for(const _0x2974b9 of _0x40aaa8['getAttributeKeys']())_0x4df9c8['includes'](_0x2974b9)||_0x45c660['removeAttribute'](_0x2974b9,_0x40aaa8);for(const _0x47907f of _0x4df9c8)_0x45c660['setAttribute'](_0x47907f,_0x5855c0[_0x12599f][_0x47907f],_0x40aaa8);_0x45c660['remove'](_0x45c660['createRangeIn'](_0x40aaa8)),_0x45c660['insert'](_0xf7e22f['data']['parse'](_0x43c17a,_0x40aaa8),_0x40aaa8,0x0);}});const _0xcd5846=g(_0xf7e22f['locale'],'Restored');if(_0x26c4b8['name'])_0x2122ff=-0x1==_0x26c4b8['name']['indexOf'](_0xcd5846)?_0xcd5846+':\x20'+_0x26c4b8['name']:_0x26c4b8['name'];else _0x2122ff=_0xcd5846+':\x20'+(_0x26c4b8['createdAt']['toLocaleDateString'](_0xf7e22f['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x26c4b8['createdAt']['toLocaleTimeString'](_0xf7e22f['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x395d84['saveRevision']({'name':_0x2122ff}),_0x3f71f5['isReady']=!0x0,_0xf7e22f['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{h as Revision,k as RevisionHistory,f as RevisionHistoryUI,V as RevisionHistoryUtils,u as RevisionTracker,m as RevisionViewer,w as RevisionViewerEditor,ge as RevisionViewerLoadingOverlay,R as RevisionViewerUI,I as RevisionsRepository,d as RevisionsSidebar};
|
|
28
|
+
pt();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[m];}constructor(_0x24a816){super(_0x24a816),this['_revisionViewer']=_0x24a816['plugins']['get'](m),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x2681fd=this['_revisionsRepository']['_revisions'],_0x5ede8f=this['_createRevisionActions'](),_0x43f8f0=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new ii(this['editor']['locale'],_0x2681fd,_0x5ede8f,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',(_0x379ee7,_0x21a002)=>{_0x21a002['revisionViews']['on']('add',(_0x53dcdf,_0x2ecdd5)=>{_0x2ecdd5['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)),_0x43f8f0['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x231057=this['_revisionsRepository']['getRevision'](0x0);if(_0x231057){const _0x55467c=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x231057['id']);this['_revisionViewer']['compare'](_0x231057,_0x55467c);}}['_handleRevisionSelected'](_0x494c6c,_0x612a0f){const _0x4be7bc=this['_revisionsRepository']['getRevision'](_0x612a0f['id']),_0x584b31=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x4be7bc['id']);this['_revisionViewer']['compare'](_0x4be7bc,_0x584b31);}['_handleRevisionSetName'](_0x4e9d82,_0x3263c2){this['_revisionsRepository']['getRevision'](_0x3263c2['id'])['setName'](_0x3263c2['name']);}['_handleDiffChange'](_0x15dce8,_0x1b146b,_0x4aa41f){const _0x18fadf=this['_revisionsRepository']['getRevisionsInDiff'](_0x4aa41f);_0x18fadf['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x18fadf),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x18fadf[0x0]));}['_createRevisionActions'](){const _0x806938=this['editor'],_0x4fb459=d['availableRevisionActions'],_0x6e5361=_0x806938['config']['get']('revisionHistory.revisionActions')||d['defaultRevisionActions'];if(_0x6e5361['length'])return _0x6e5361['map'](_0x149f32=>{const _0xbbf6b6='string'==typeof _0x149f32?Object['assign']({},_0x4fb459[_0x149f32]):_0x149f32;return _0xbbf6b6['action']=_0xbbf6b6['action']['bind'](this,_0x806938),_0xbbf6b6['isVisible']&&(_0xbbf6b6['isVisible']=_0xbbf6b6['isVisible']['bind'](this,_0x806938)),_0xbbf6b6;});}}function pt(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x324f76},_0x585a6a)=>{const _0x208fd2=_0x324f76['get'](m),_0x1a1b31=_0x208fd2['repository'];let _0x505a11=_0x208fd2['diff']['newRevisionId'],_0x3878ed=_0x585a6a['id'];_0x1a1b31['getIndex'](_0x505a11)>_0x1a1b31['getIndex'](_0x3878ed)&&([_0x505a11,_0x3878ed]=[_0x3878ed,_0x505a11]),_0x208fd2['compare'](_0x505a11,_0x3878ed);},'isVisible':({plugins:_0x10d4e1},_0x20a2f3)=>{const _0x5b9ffc=_0x10d4e1['get'](m);return!(_0x5b9ffc['repository']['getRevisionsInDiff'](_0x5b9ffc['diff'])['length']>0x2)&&!_0x20a2f3['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x3f7c5f,{id:_0x16692f})=>{_0x3f7c5f['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x16692f);},'isVisible':({plugins:_0x21fe71},_0x391363)=>!!_0x21fe71['get'](m)['repository']['getLaterVisibleRevision'](_0x391363['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x1a8ebe},{id:_0x42ea71,revisionNameView:_0x30490a})=>{const _0x4abd35=_0x1a8ebe['get'](m),_0x4a5ec6=_0x4abd35['repository']['getEarlierVisibleRevision'](_0x42ea71);_0x4abd35['compare'](_0x42ea71,_0x4a5ec6),_0x30490a['focus'](),_0x30490a['fieldView']['select']();}}};}class tt extends st{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x215a40,_0x17dd7d){super(_0x215a40),this['_view']=_0x17dd7d,this['_toolbarConfig']=et(_0x215a40['config']['get']('toolbar')),this['_elementReplacer']=new ot();}get['element'](){return this['view']['element'];}['init'](_0xf46f17){const _0x59ced2=this['editor'],_0x56bc12=this['view'],_0x13d2b4=_0x59ced2['editing']['view'],_0x582215=_0x56bc12['editable'],_0x4d3c91=_0x13d2b4['document']['getRoot']();_0x582215['name']=_0x4d3c91['rootName'],_0x56bc12['render']();const _0x21bbed=_0x582215['element'];this['setEditableElement'](_0x582215['name'],_0x21bbed),_0x56bc12['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x13d2b4['attachDomRoot'](_0x21bbed),this['_elementReplacer']['replace'](_0xf46f17,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x1da2ac=this['view'],_0x39a562=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x39a562['detachDomRoot'](_0x1da2ac['editable']['name']),_0x1da2ac['destroy']();}['_initToolbar'](){const _0x11e8e8=this['view'];_0x11e8e8['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x11e8e8['stickyPanel']['limiterElement']=_0x11e8e8['element'],_0x11e8e8['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x5f048e})=>_0x5f048e),_0x11e8e8['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x11e8e8['toolbar']);}}class it extends rt{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x9ae6f,_0x5588c0,_0x4b9d5b={}){super(_0x9ae6f),this['stickyPanel']=new ht(_0x9ae6f),this['toolbar']=new dt(_0x9ae6f,{'shouldGroupWhenFull':_0x4b9d5b['shouldToolbarGroupWhenFull']}),this['_editable']=new ct(_0x9ae6f,_0x5588c0);}['render'](){super['render'](),this['stickyPanel']['content']['add'](this['toolbar']),this['top']['add'](this['stickyPanel']),this['main']['add'](this['editable']);}}class w extends/* #__PURE__ -- @preserve */
|
|
29
|
+
_0x33a608(_0x180b1b){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x44cbef,_0x14de9c){super(_0x14de9c),this['sourceElement']=_0x44cbef,this['model']['document']['createRoot']();const _0x476c92=new it(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new tt(this,_0x476c92);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x1984c4,_0x2c1841){const _0x30d9ea=new this(_0x1984c4,_0x2c1841);return await _0x30d9ea['initPlugins'](),await _0x30d9ea['ui']['init'](_0x1984c4),await _0x30d9ea['data']['init'](_0x30d9ea['config']['get']('initialData')||''),_0x30d9ea['fire']('ready'),_0x30d9ea;}}const p=['RevisionHistoryUI','RestrictedEditingMode'];class _t extends _0x215f3d{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x990472){function _0x553106(_0x4df8a0){return _0x4df8a0['map'](_0x3116dd=>String['fromCharCode'](_0x3116dd))['join']('');}super(_0x990472),this['result']='end',_0x990472[_0x553106([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x553106([0x76,0x69,0x65,0x77])][_0x553106([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x553106([0x61,0x75,0x74,0x6f]),_0x990472[_0x553106([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x553106([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x553106([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x553106([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x553106([0x6f,0x6b])});}}class k extends _0x215f3d{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u,f];}constructor(_0x2289bb){if(super(_0x2289bb),!this['editor']['config']['get']('revisionHistory'))throw new _0x382e41('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x45131a=>this['_showRevisionViewer']({..._0x45131a,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x4c32e5=>this['_closeRevisionViewer'](_0x4c32e5)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0xa147=>this['_restoreRevision'](_0xa147)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x36e6c2){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x36e6c2;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x2eb2c7){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x2eb2c7);}['getRevision'](_0x117dec){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x117dec);}['getRevisions'](_0x34f763){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x34f763||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x808730=this['editor'],_0x499083=_0x16f0f7(_0x808730,p),_0x4eef47=_0x808730['plugins']['get']('RevisionTracker'),_0x171348=_0x808730['plugins']['get']('Users')['users'];return _0x499083['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x499083['lazyRoots'],(_0x499083['plugins']['push'](_t,m,R,class extends _0x215f3d{static get['requires'](){return[m,'Users'];}['init'](){const _0x5e1539=this['editor']['plugins']['get']('Users');for(const _0x465378 of _0x171348)_0x465378['isAnonymous']||_0x5e1539['getUser'](_0x465378['id'])||_0x5e1539['addUser'](_0x465378);const _0x499a82=_0x4eef47['repository']['getRevisions']();let _0x59eb44=null;const _0xd9801f=this['editor']['plugins']['get']('RevisionViewer');_0xd9801f['adapter']=_0x4eef47['adapter'],_0xd9801f['bind']('isEnabled')['to'](_0x4eef47),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x808730,'isReadOnly',_0x537acf=>!_0x537acf);for(const _0x1ba452 of _0x499a82){const _0x592dcf=null===_0x1ba452['creator'];if(_0x592dcf&&_0x1ba452['toVersion']===_0x1ba452['fromVersion'])continue;const _0x1328d7=_0x1ba452['toJSON']();_0xd9801f['addRevisionData'](_0x1328d7,(_0x3b9f68,_0x54b2ae,_0x4e243b)=>{if(_0x592dcf){if(_0x59eb44)_0x59eb44['_update'](_0x3b9f68,_0x54b2ae);else{if(!_0x54b2ae){const _0x14e003=_0x4e243b['toJSON']();_0x14e003['id']=_0x335623(),_0x4eef47['saveRevision'](_0x14e003,_0x4e243b['toVersion'])['then'](_0x16be2f=>{_0x59eb44=_0x16be2f;});}}}else _0x1ba452['_update'](_0x3b9f68,_0x54b2ae);});}}},d),_0x499083);}['_enhanceShowRevisionViewerCallback'](){const _0x166b4b=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x49dfa7=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x16768f=this['editor']['plugins']['get']('Autosave');await _0x16768f['save']();}else await _0x49dfa7['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x4f0ecd=this['editor']['plugins']['get']('Dialog');_0x4f0ecd['isOpen']&&_0x4f0ecd['hide']();}const _0x315f2d=this['_getRevisionViewerEditorConfig']();return _0x166b4b(_0x315f2d)['then'](_0x4d1443=>{return(this['_viewerEditor']=_0x4d1443,this['editor']['plugins']['has']('Annotations'))&&this['editor']['plugins']['get']('Annotations')['refreshVisibility'](),(this['editor']['plugins']['has']('DocumentOutline')&&(this['editor']['plugins']['get']('DocumentOutlineUI')['view']['element']['style']['display']='none'),_0x4d1443);})['catch'](_0x85e347=>(console['error'](_0x85e347),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0xce0e77=this['editor']['config']['get']('revisionHistory')['closeRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.closeRevisionViewerCallback',()=>(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('DocumentOutline')&&(this['editor']['plugins']['get']('DocumentOutlineUI')['view']['element']['style']['display']=''),this['_viewerEditor']['plugins']['get']('RevisionViewer')['_cleanUp'](),_0xce0e77(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x3b8e37=this['editor']['plugins']['get']('Annotations');_0x3b8e37['refreshVisibility'](),_0x3b8e37['refreshPositioning']();}})));}['_showRevisionViewer'](_0x151442){const _0x3e548d=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x156fa8=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x1c816a=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return w['create'](_0x1c816a,_0x151442)['then'](_0x2b43f8=>(_0x156fa8['style']['display']='block',_0x3e548d['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x2b43f8));}['_closeRevisionViewer'](_0x301e89){const _0x75a4f8=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x75a4f8['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x301e89['destroy']();}async['_restoreRevision'](_0x400692){const _0x350725=this['editor'],_0x398ae6=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x21e80e=_0x350725['plugins']['get']('RevisionTracker'),_0x4c5370=_0x350725['plugins']['get']('RevisionHistoryUtils'),_0x4b3df4=_0x398ae6['repository']['getRevision'](_0x400692);let _0x50efb2,_0x5978f8,_0x544035;try{await _0x4c5370['loadRevisionData'](_0x4b3df4,this['adapter']),_0x50efb2=_0x4c5370['getRevisionDocumentData'](_0x4b3df4),_0x5978f8=_0x4c5370['getRevisionRootsAttributes'](_0x4b3df4);}catch(_0x578d26){return void console['error'](_0x578d26);}_0x350725['model']['change'](_0x3b1792=>{for(const _0x28d86c of Array['from'](_0x350725['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x3b1792['removeMarker'](_0x28d86c);}),_0x398ae6['isReady']=!0x1,_0x350725['model']['enqueueChange'](_0x19b597=>{_0x19b597['setSelection'](null),_0x19b597['removeSelectionAttribute'](_0x350725['model']['document']['selection']['getAttributeKeys']());const _0x518e0d=Object['keys'](_0x50efb2);for(const _0x440edf of _0x350725['model']['document']['roots'])'$graveyard'!=_0x440edf['rootName']&&_0x440edf['isAttached']()&&!_0x518e0d['includes'](_0x440edf['rootName'])&&_0x19b597['detachRoot'](_0x440edf);for(const _0x397b65 of _0x518e0d){let _0x2f8b72=_0x350725['model']['document']['getRoot'](_0x397b65);_0x2f8b72&&_0x2f8b72['isAttached']()||(_0x2f8b72=_0x19b597['addRoot'](_0x397b65));const _0x1dbd51=_0x5978f8[_0x397b65],_0x4b5f27=Object['keys'](_0x1dbd51),_0x1bdb6f=_0x50efb2[_0x397b65];for(const _0x5d57cb of _0x2f8b72['getAttributeKeys']())_0x4b5f27['includes'](_0x5d57cb)||_0x19b597['removeAttribute'](_0x5d57cb,_0x2f8b72);for(const _0x146618 of _0x4b5f27)_0x19b597['setAttribute'](_0x146618,_0x5978f8[_0x397b65][_0x146618],_0x2f8b72);_0x19b597['remove'](_0x19b597['createRangeIn'](_0x2f8b72)),_0x19b597['insert'](_0x350725['data']['parse'](_0x1bdb6f,_0x2f8b72),_0x2f8b72,0x0);}});const _0x4d3fdf=g(_0x350725['locale'],'Restored');if(_0x4b3df4['name'])_0x544035=-0x1==_0x4b3df4['name']['indexOf'](_0x4d3fdf)?_0x4d3fdf+':\x20'+_0x4b3df4['name']:_0x4b3df4['name'];else _0x544035=_0x4d3fdf+':\x20'+(_0x4b3df4['createdAt']['toLocaleDateString'](_0x350725['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x4b3df4['createdAt']['toLocaleTimeString'](_0x350725['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x21e80e['saveRevision']({'name':_0x544035}),_0x398ae6['isReady']=!0x0,_0x350725['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{h as Revision,k as RevisionHistory,f as RevisionHistoryUI,V as RevisionHistoryUtils,u as RevisionTracker,m as RevisionViewer,w as RevisionViewerEditor,ge as RevisionViewerLoadingOverlay,R as RevisionViewerUI,I as RevisionsRepository,d as RevisionsSidebar};
|