@ckeditor/ckeditor5-revision-history 0.0.0-nightly-20241229.0 → 0.0.0-nightly-20241231.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/revision-history.js +1 -1
- package/dist/index.js +6 -6
- package/dist/translations/af.js +1 -1
- package/dist/translations/af.umd.js +1 -1
- package/dist/translations/ar.js +1 -1
- package/dist/translations/ar.umd.js +1 -1
- package/dist/translations/ast.js +1 -1
- package/dist/translations/ast.umd.js +1 -1
- package/dist/translations/az.js +1 -1
- package/dist/translations/az.umd.js +1 -1
- package/dist/translations/bg.js +1 -1
- package/dist/translations/bg.umd.js +1 -1
- package/dist/translations/bn.js +1 -1
- package/dist/translations/bn.umd.js +1 -1
- package/dist/translations/bs.js +1 -1
- package/dist/translations/bs.umd.js +1 -1
- package/dist/translations/ca.js +1 -1
- package/dist/translations/ca.umd.js +1 -1
- package/dist/translations/cs.js +1 -1
- package/dist/translations/cs.umd.js +1 -1
- package/dist/translations/da.js +1 -1
- package/dist/translations/da.umd.js +1 -1
- package/dist/translations/de-ch.js +1 -1
- package/dist/translations/de-ch.umd.js +1 -1
- package/dist/translations/de.js +1 -1
- package/dist/translations/de.umd.js +1 -1
- package/dist/translations/el.js +1 -1
- package/dist/translations/el.umd.js +1 -1
- package/dist/translations/en-au.js +1 -1
- package/dist/translations/en-au.umd.js +1 -1
- package/dist/translations/en-gb.js +1 -1
- package/dist/translations/en-gb.umd.js +1 -1
- package/dist/translations/en.js +1 -1
- package/dist/translations/en.umd.js +1 -1
- package/dist/translations/eo.js +1 -1
- package/dist/translations/eo.umd.js +1 -1
- package/dist/translations/es-co.js +1 -1
- package/dist/translations/es-co.umd.js +1 -1
- package/dist/translations/es.js +1 -1
- package/dist/translations/es.umd.js +1 -1
- package/dist/translations/et.js +1 -1
- package/dist/translations/et.umd.js +1 -1
- package/dist/translations/eu.js +1 -1
- package/dist/translations/eu.umd.js +1 -1
- package/dist/translations/fa.js +1 -1
- package/dist/translations/fa.umd.js +1 -1
- package/dist/translations/fi.js +1 -1
- package/dist/translations/fi.umd.js +1 -1
- package/dist/translations/fr.js +1 -1
- package/dist/translations/fr.umd.js +1 -1
- package/dist/translations/gl.js +1 -1
- package/dist/translations/gl.umd.js +1 -1
- package/dist/translations/gu.js +1 -1
- package/dist/translations/gu.umd.js +1 -1
- package/dist/translations/he.js +1 -1
- package/dist/translations/he.umd.js +1 -1
- package/dist/translations/hi.js +1 -1
- package/dist/translations/hi.umd.js +1 -1
- package/dist/translations/hr.js +1 -1
- package/dist/translations/hr.umd.js +1 -1
- package/dist/translations/hu.js +1 -1
- package/dist/translations/hu.umd.js +1 -1
- package/dist/translations/hy.js +1 -1
- package/dist/translations/hy.umd.js +1 -1
- package/dist/translations/id.js +1 -1
- package/dist/translations/id.umd.js +1 -1
- package/dist/translations/it.js +1 -1
- package/dist/translations/it.umd.js +1 -1
- package/dist/translations/ja.js +1 -1
- package/dist/translations/ja.umd.js +1 -1
- package/dist/translations/jv.js +1 -1
- package/dist/translations/jv.umd.js +1 -1
- package/dist/translations/kk.js +1 -1
- package/dist/translations/kk.umd.js +1 -1
- package/dist/translations/km.js +1 -1
- package/dist/translations/km.umd.js +1 -1
- package/dist/translations/kn.js +1 -1
- package/dist/translations/kn.umd.js +1 -1
- package/dist/translations/ko.js +1 -1
- package/dist/translations/ko.umd.js +1 -1
- package/dist/translations/ku.js +1 -1
- package/dist/translations/ku.umd.js +1 -1
- package/dist/translations/lt.js +1 -1
- package/dist/translations/lt.umd.js +1 -1
- package/dist/translations/lv.js +1 -1
- package/dist/translations/lv.umd.js +1 -1
- package/dist/translations/ms.js +1 -1
- package/dist/translations/ms.umd.js +1 -1
- package/dist/translations/nb.js +1 -1
- package/dist/translations/nb.umd.js +1 -1
- package/dist/translations/ne.js +1 -1
- package/dist/translations/ne.umd.js +1 -1
- package/dist/translations/nl.js +1 -1
- package/dist/translations/nl.umd.js +1 -1
- package/dist/translations/no.js +1 -1
- package/dist/translations/no.umd.js +1 -1
- package/dist/translations/oc.js +1 -1
- package/dist/translations/oc.umd.js +1 -1
- package/dist/translations/pl.js +1 -1
- package/dist/translations/pl.umd.js +1 -1
- package/dist/translations/pt-br.js +1 -1
- package/dist/translations/pt-br.umd.js +1 -1
- package/dist/translations/pt.js +1 -1
- package/dist/translations/pt.umd.js +1 -1
- package/dist/translations/ro.js +1 -1
- package/dist/translations/ro.umd.js +1 -1
- package/dist/translations/ru.js +1 -1
- package/dist/translations/ru.umd.js +1 -1
- package/dist/translations/si.js +1 -1
- package/dist/translations/si.umd.js +1 -1
- package/dist/translations/sk.js +1 -1
- package/dist/translations/sk.umd.js +1 -1
- package/dist/translations/sl.js +1 -1
- package/dist/translations/sl.umd.js +1 -1
- package/dist/translations/sq.js +1 -1
- package/dist/translations/sq.umd.js +1 -1
- package/dist/translations/sr-latn.js +1 -1
- package/dist/translations/sr-latn.umd.js +1 -1
- package/dist/translations/sr.js +1 -1
- package/dist/translations/sr.umd.js +1 -1
- package/dist/translations/sv.js +1 -1
- package/dist/translations/sv.umd.js +1 -1
- package/dist/translations/th.js +1 -1
- package/dist/translations/th.umd.js +1 -1
- package/dist/translations/ti.js +1 -1
- package/dist/translations/ti.umd.js +1 -1
- package/dist/translations/tk.js +1 -1
- package/dist/translations/tk.umd.js +1 -1
- package/dist/translations/tr.js +1 -1
- package/dist/translations/tr.umd.js +1 -1
- package/dist/translations/tt.js +1 -1
- package/dist/translations/tt.umd.js +1 -1
- package/dist/translations/ug.js +1 -1
- package/dist/translations/ug.umd.js +1 -1
- package/dist/translations/uk.js +1 -1
- package/dist/translations/uk.umd.js +1 -1
- package/dist/translations/ur.js +1 -1
- package/dist/translations/ur.umd.js +1 -1
- package/dist/translations/uz.js +1 -1
- package/dist/translations/uz.umd.js +1 -1
- package/dist/translations/vi.js +1 -1
- package/dist/translations/vi.umd.js +1 -1
- package/dist/translations/zh-cn.js +1 -1
- package/dist/translations/zh-cn.umd.js +1 -1
- package/dist/translations/zh.js +1 -1
- package/dist/translations/zh.umd.js +1 -1
- package/package.json +8 -8
- package/src/changeitem.js +2 -2
- package/src/editor/revisionviewereditor.js +2 -2
- package/src/editor/revisionviewereditorui.js +1 -1
- package/src/editor/revisionviewereditoruiview.js +1 -1
- package/src/index.js +1 -1
- package/src/revision.js +2 -2
- package/src/revisiondiff.js +1 -1
- package/src/revisionhistory.js +1 -1
- package/src/revisionsrepository.js +1 -1
- package/src/revisiontracker.js +1 -1
- package/src/revisionviewer.js +1 -1
- package/src/ui/revision/createrevisionactionsdropdown.js +1 -1
- package/src/ui/revision/revisionauthorview.js +1 -1
- package/src/ui/revision/revisionnameview.js +1 -1
- package/src/ui/revision/revisionview.js +2 -2
- package/src/ui/revision/subrevisioncollapserview.js +1 -1
- package/src/ui/revision/subrevisionview.js +1 -1
- package/src/ui/revision/utils.js +1 -1
- package/src/ui/revisionhistory/revisionhistorysaverevisionformview.js +1 -1
- package/src/ui/revisionhistory/revisionhistoryui.js +1 -1
- package/src/ui/revisionssidebar/revisionssidebar.js +1 -1
- package/src/ui/revisionssidebar/revisionssidebarheaderview.js +1 -1
- package/src/ui/revisionssidebar/revisionssidebartimeperiodview.js +1 -1
- package/src/ui/revisionssidebar/revisionssidebarview.js +1 -1
- package/src/ui/revisionssidebar/utils.js +1 -1
- package/src/ui/revisionviewer/changedetailsview.js +1 -1
- package/src/ui/revisionviewer/changesnavigationview.js +1 -1
- package/src/ui/revisionviewer/revisionviewerloadingoverlay.js +1 -1
- package/src/ui/revisionviewer/revisionviewerui.js +1 -1
- package/src/utils/common-translations.js +1 -1
package/dist/index.js
CHANGED
|
@@ -20,10 +20,10 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
import{ObservableMixin as
|
|
24
|
-
_0x5a7f9d(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x30fec8){super(),this['id']=_0x30fec8['id']||_0x4f9a89(),this['creator']=_0x30fec8['creator']||null,this['authors']=_0x30fec8['authors']||[],this['diffData']=_0x30fec8['diffData']||null,this['toVersion']=_0x30fec8['toVersion']||0x0,this['fromVersion']=_0x30fec8['fromVersion']||0x0,this['set']('name',_0x30fec8['name']||''),this['set']('createdAt',_0x30fec8['createdAt']||new Date()),this['set']('attributes',_0x30fec8['attributes']||{});}['setName'](_0x20eeda){this['_update']({'name':_0x20eeda});}['setAttribute'](_0x5c90a8,_0x156729){const _0x113110=_0x1ea11a(this['attributes']);_0x11436e(_0x113110,_0x5c90a8,_0x156729),this['_update']({'attributes':_0x113110});}['removeAttribute'](_0x3d31d0){const _0x36b69b=_0x1ea11a(this['attributes']);_0x5ccbc4(_0x36b69b,_0x3d31d0),this['_update']({'attributes':_0x36b69b});}['_update'](_0xc7157a,_0x10b13d=!0x1){let _0x44855c=!0x1;const _0x3d2b49={'id':this['id']},_0x636f20=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x279396 of _0x636f20){const _0x52398b=_0xc7157a[_0x279396];void 0x0!==_0x52398b&&_0x52398b!==this[_0x279396]&&(this[_0x279396]=_0x52398b,_0x3d2b49[_0x279396]=_0x52398b,_0x44855c=!0x0);}_0x44855c&&(_0x3d2b49['authors']&&(_0x3d2b49['authorsIds']=_0x3d2b49['authors']['map'](_0x2447dc=>_0x2447dc['id']),delete _0x3d2b49['authors']),this['fire']('_update',_0x3d2b49,_0x10b13d));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x2f416b=>_0x2f416b['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class j extends _0x49970d{['_revisions'];static get['requires'](){return[_0x122c7d];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x475269){super(_0x475269),this['_revisions']=new _0x2745a9();}['afterInit'](){!async function(_0x3e8d64){const _0x2f43df=_0x4a7f6a([0x4e,0x76,0x72,0x47,0x75,0x4b,0x57,0x48,0x38,0x45,0x34,0x44,0x6e,0x43,0x33,0x31,0x42,0x70,0x64,0x6c,0x74,0x69,0x50,0x56,0x63,0x78,0x59,0x4d,0x49,0x35,0x73,0x46,0x41,0x6d,0x54,0x51,0x53,0x68,0x5a,0x52,0x61,0x55,0x36,0x4c,0x6f,0x66,0x4a,0x62,0x71,0x65,0x39,0x7a,0x30,0x79,0x32,0x58,0x4f,0x6b,0x6a,0x67,0x77,0x37]),_0x405139=0xeb829,_0xd76ac4=0x7017a267,_0x540a8a=0x7010f977^_0xd76ac4,_0x227bc3=window[_0x4a7f6a([0x44,0x61,0x74,0x65])][_0x4a7f6a([0x6e,0x6f,0x77])](),_0x403453=_0x3e8d64[_0x4a7f6a([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x4d223e=new window[(_0x4a7f6a([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x34c717=>{_0x403453[_0x4a7f6a([0x6f,0x6e,0x63,0x65])](_0x4a7f6a([0x72,0x65,0x61,0x64,0x79]),_0x34c717);}),_0x2580e1={[_0x4a7f6a([0x6b,0x74,0x79])]:_0x4a7f6a([0x45,0x43]),[_0x4a7f6a([0x75,0x73,0x65])]:_0x4a7f6a([0x73,0x69,0x67]),[_0x4a7f6a([0x63,0x72,0x76])]:_0x4a7f6a([0x50,0x2d,0x32,0x35,0x36]),[_0x4a7f6a([0x78])]:_0x4a7f6a([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]),[_0x4a7f6a([0x79])]:_0x4a7f6a([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]),[_0x4a7f6a([0x61,0x6c,0x67])]:_0x4a7f6a([0x45,0x53,0x32,0x35,0x36])},_0x20e0ae=_0x403453[_0x4a7f6a([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x4a7f6a([0x67,0x65,0x74])](_0x4a7f6a([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x36dd41(){let _0x178194,_0x1d2d7e=null,_0x5a55c8=null;try{if(_0x20e0ae==_0x4a7f6a([0x47,0x50,0x4c]))return _0x4a7f6a([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x178194=_0x3debc8(),!_0x178194)return _0x4a7f6a([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x178194[_0x4a7f6a([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x5a55c8=_0x4b0b36(_0x178194[_0x4a7f6a([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x178194[_0x4a7f6a([0x6a,0x74,0x69])])),await _0x4ccc39()?_0x582559()?_0x4a443c()?_0x4a7f6a([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x28809c()?(_0x178194[_0x4a7f6a([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x4a7f6a([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x1d2d7e=_0x196ddd(_0x4a7f6a([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x178194[_0x4a7f6a([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x4a7f6a([0x74,0x72,0x69,0x61,0x6c])&&(_0x1d2d7e=_0x196ddd(_0x4a7f6a([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),_0x178194[_0x4a7f6a([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x4a7f6a([0x64,0x65,0x76,0x65,0x6c,0x6f,0x70,0x6d,0x65,0x6e,0x74])&&(_0x1d2d7e=_0x196ddd(_0x4a7f6a([0x44,0x65,0x76,0x65,0x6c,0x6f,0x70,0x6d,0x65,0x6e,0x74,0x4c,0x69,0x6d,0x69,0x74]))),await _0x341dfb()):_0x4a7f6a([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x4a7f6a([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x4a7f6a([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch(_0x329117){return _0x4a7f6a([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x4a443c(){const _0x1cc659=[_0x4a7f6a([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x4a7f6a([0x74,0x72,0x69,0x61,0x6c])][_0x4a7f6a([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x178194[_0x4a7f6a([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x227bc3/0x3e8:0xe10*_0x540a8a;return _0x178194[_0x4a7f6a([0x65,0x78,0x70])]<_0x1cc659;}function _0x582559(){const _0x52473b=_0x178194[_0x4a7f6a([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x52473b)return!0x1;if(_0x52473b[_0x4a7f6a([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4a7f6a([0x2a])))return!0x0;if(_0x52473b[_0x4a7f6a([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4a7f6a([0x52,0x48])))return!0x0;if(_0x52473b[_0x4a7f6a([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4a7f6a([0x52,0x52,0x48]))){if(_0x46d767())return!0x0;if(_0x315e2b()||_0x55e9fc())return!0x0;}return!0x1;}function _0x28809c(){const _0x21ddb3=_0x178194[_0x4a7f6a([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x21ddb3||0x0==_0x21ddb3[_0x4a7f6a([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x9df43}=new URL(window[_0x4a7f6a([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x21ddb3[_0x4a7f6a([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x9df43))return!0x0;const _0x341453=_0x9df43[_0x4a7f6a([0x73,0x70,0x6c,0x69,0x74])](_0x4a7f6a([0x2e]));return _0x21ddb3[_0x4a7f6a([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x29e8c2=>_0x29e8c2[_0x4a7f6a([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4a7f6a([0x2a])))[_0x4a7f6a([0x6d,0x61,0x70])](_0x3ef4e5=>_0x3ef4e5[_0x4a7f6a([0x73,0x70,0x6c,0x69,0x74])](_0x4a7f6a([0x2e])))[_0x4a7f6a([0x73,0x6f,0x6d,0x65])](_0x4028ec=>_0x341453[_0x4a7f6a([0x65,0x76,0x65,0x72,0x79])]((_0xb4b186,_0x3f5247)=>_0x4028ec[_0x3f5247]===_0xb4b186||_0x4028ec[_0x3f5247]===_0x4a7f6a([0x2a])));}function _0x341dfb(){return _0x1d2d7e&&_0x5a55c8?new window[(_0x4a7f6a([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x43f903,_0x4b6484)=>{_0x1d2d7e[_0x4a7f6a([0x74,0x68,0x65,0x6e])](_0x43f903,_0x4b6484),_0x5a55c8[_0x4a7f6a([0x74,0x68,0x65,0x6e])](_0x2f5d8e=>{_0x2f5d8e!=_0x4a7f6a([0x56,0x61,0x6c,0x69,0x64])&&_0x43f903(_0x2f5d8e);},_0x4b6484);}):_0x1d2d7e||_0x5a55c8||_0x4a7f6a([0x56,0x61,0x6c,0x69,0x64]);}}function _0x4b0b36(_0x316edf,_0x177eb7){return new window[(_0x4a7f6a([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x4baad0=>{if(_0x136d57())return _0x4baad0(_0x4a7f6a([0x56,0x61,0x6c,0x69,0x64]));_0x2a1f79(),_0x403453[_0x4a7f6a([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x4a7f6a([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x34efb4=!0x1;const _0x2689ab=_0x4f9a89();function _0x39833c(_0xc1435b){return!!_0xc1435b&&(typeof _0xc1435b===_0x4a7f6a([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0xc1435b===_0x4a7f6a([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0xc1435b[_0x4a7f6a([0x74,0x68,0x65,0x6e])]===_0x4a7f6a([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0xc1435b[_0x4a7f6a([0x63,0x61,0x74,0x63,0x68])]===_0x4a7f6a([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x200b61(_0x3edb75){_0x185047(_0x3edb75)[_0x4a7f6a([0x74,0x68,0x65,0x6e])](_0x447451=>{if(!_0x447451||_0x447451[_0x4a7f6a([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x4a7f6a([0x6f,0x6b]))return _0x4a7f6a([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x2e250e(_0x2820c2(_0x2689ab+_0x177eb7))!=_0x447451[_0x4a7f6a([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x4a7f6a([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x4a7f6a([0x56,0x61,0x6c,0x69,0x64]);})[_0x4a7f6a([0x74,0x68,0x65,0x6e])](_0x1beec9=>(_0x492dc3(),_0x1beec9),()=>{const _0x1f8cea=_0x379745();return null==_0x1f8cea?(_0x492dc3(),_0x4a7f6a([0x56,0x61,0x6c,0x69,0x64])):_0x4a7f6a(_0x227bc3-_0x1f8cea>(0x541b2667^_0xd76ac4)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x4a7f6a([0x74,0x68,0x65,0x6e])](_0x4baad0)[_0x4a7f6a([0x63,0x61,0x74,0x63,0x68])](()=>{_0x4baad0(_0x4a7f6a([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x209706=0x70214ce7^_0xd76ac4;function _0x492dc3(){const _0x15bbf1=_0x4a7f6a([0x6c,0x6c,0x63,0x74,0x2d])+_0x2e250e(_0x2820c2(_0x316edf)),_0x1a73a9=_0x322e2a(_0x2e250e(window[_0x4a7f6a([0x4d,0x61,0x74,0x68])][_0x4a7f6a([0x63,0x65,0x69,0x6c])](_0x227bc3/_0x209706)));window[_0x4a7f6a([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x4a7f6a([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x15bbf1,_0x1a73a9);}function _0x379745(){const _0x1b34be=_0x4a7f6a([0x6c,0x6c,0x63,0x74,0x2d])+_0x2e250e(_0x2820c2(_0x316edf)),_0x53e696=window[_0x4a7f6a([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x4a7f6a([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x1b34be);return _0x53e696?window[_0x4a7f6a([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x322e2a(_0x53e696),0x10)*_0x209706:null;}function _0x185047(_0x260232){return new window[(_0x4a7f6a([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x4b140,_0x12a538)=>{_0x260232[_0x4a7f6a([0x74,0x68,0x65,0x6e])](_0x4b140,_0x12a538),window[_0x4a7f6a([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x12a538,0x701676a7^_0xd76ac4);});}}_0x403453[_0x4a7f6a([0x6f,0x6e])](_0x4a7f6a([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x5e0bc3,_0x4f222c)=>{if(_0x4f222c[0x0]!=_0x316edf)return _0x4baad0(_0x4a7f6a([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x4f222c[0x1]={..._0x4f222c[0x1],[_0x4a7f6a([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x2689ab};},{[_0x4a7f6a([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x4a7f6a([0x68,0x69,0x67,0x68])}),_0x403453[_0x4a7f6a([0x6f,0x6e])](_0x4a7f6a([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x13f32b=>{_0x39833c(_0x13f32b[_0x4a7f6a([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x34efb4=!0x0,_0x200b61(_0x13f32b[_0x4a7f6a([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x4a7f6a([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x4a7f6a([0x6c,0x6f,0x77])}),_0x4d223e[_0x4a7f6a([0x74,0x68,0x65,0x6e])](()=>{_0x34efb4||_0x4baad0(_0x4a7f6a([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x136d57(){return _0x403453[_0x4a7f6a([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x4a7f6a([0x76,0x69,0x65,0x77])][_0x4a7f6a([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x4a7f6a([0x61,0x75,0x74,0x6f]);}function _0x2a1f79(){_0x403453[_0x4a7f6a([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x4a7f6a([0x76,0x69,0x65,0x77])][_0x4a7f6a([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x4a7f6a([0x61,0x75,0x74,0x6f]);}}function _0x196ddd(_0x25ecbe){const _0x37018d=[new window[(_0x4a7f6a([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x1e99a9=>setTimeout(_0x1e99a9,0x701e9cab^_0xd76ac4)),_0x4d223e[_0x4a7f6a([0x74,0x68,0x65,0x6e])](()=>new window[(_0x4a7f6a([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x1f44ce=>{const _0x10b6fe=0x7017a260^_0xd76ac4,_0x148e9a=_0x3e8d64[_0x4a7f6a([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x382221(){_0x148e9a[_0x4a7f6a([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x10b6fe&&_0x1f44ce();}_0x382221(),_0x148e9a[_0x4a7f6a([0x6f,0x6e])](_0x4a7f6a([0x61,0x64,0x64]),_0x382221);})),new window[(_0x4a7f6a([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x380cd0=>{function _0x2f2305(){for(const _0x44d615 in window)if(window[_0x4a7f6a([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x4a7f6a([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x44d615))&&window[_0x44d615]==_0x405139)return _0x380cd0();_0x403453[_0x4a7f6a([0x73,0x74,0x61,0x74,0x65])]!=_0x4a7f6a([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x4a7f6a([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x2f2305,0x7017b1ef^_0xd76ac4);}_0x141ac2(_0x4a7f6a([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x2f2305();})];return window[_0x4a7f6a([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x4a7f6a([0x72,0x61,0x63,0x65])](_0x37018d)[_0x4a7f6a([0x74,0x68,0x65,0x6e])](()=>_0x25ecbe);}async function _0x40686d(){if(await _0x4d223e,_0x141ac2(_0x4a7f6a([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x1e599f=_0x3e8d64[_0x4a7f6a([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x54b3de=_0x3e8d64[_0x4a7f6a([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])](_0x1e599f[_0x4a7f6a([0x69,0x64])]),_0x43742c=_0x29f32b(_0x4a7f6a([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x43742c[_0x4a7f6a([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x1e599f['id'],_0x54b3de?_0x54b3de['id']:null,!0x0),_0x43742c[_0x4a7f6a([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x4a7f6a([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x43742c[_0x4a7f6a([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x43742c[_0x4a7f6a([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0xd078c,void(_0x43742c[_0x4a7f6a([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0xd078c);}if(_0x141ac2(_0x4a7f6a([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x1061ce=_0x29f32b(_0x4a7f6a([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x1061ce[_0x4a7f6a([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x4a7f6a([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x1061ce[_0x4a7f6a([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x1061ce[_0x4a7f6a([0x75,0x70,0x64,0x61,0x74,0x65])]=_0xd078c,_0x1061ce[_0x4a7f6a([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0xd078c;}_0x403453[_0x4a7f6a([0x6d,0x6f,0x64,0x65,0x6c])][_0x4a7f6a([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0xd078c,_0x403453[_0x4a7f6a([0x6d,0x6f,0x64,0x65,0x6c])][_0x4a7f6a([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0xd078c,_0x403453[_0x4a7f6a([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x4a7f6a([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x46d767(){return _0x141ac2(_0x4a7f6a([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x29f32b(_0x4a7f6a([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x4a7f6a([0x73,0x74,0x61,0x74,0x65])]==_0x4a7f6a([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x315e2b(){return _0x141ac2(_0x4a7f6a([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 _0x55e9fc(){return _0x141ac2(_0x4a7f6a([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x1e9fb1(_0x244e4d){const _0x52d383=_0x2354a0();_0x403453[_0x52d383]=_0x4a7f6a([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])+_0x244e4d,_0x244e4d[_0x4a7f6a([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x4a7f6a([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x2354a0()]=_0x405139),_0x244e4d!=_0x4a7f6a([0x56,0x61,0x6c,0x69,0x64])&&_0x40686d();}function _0x2354a0(){const _0x417e46=window[_0x4a7f6a([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x4a7f6a([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x4a7f6a([0x6e,0x6f,0x77])]())[_0x4a7f6a([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x4a7f6a([0x2e]),'');let _0x5690a1=_0x4a7f6a([0x4e]);for(let _0x17da6e=0x0;_0x17da6e<_0x417e46[_0x4a7f6a([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x17da6e+=0x2){let _0x345bd2=window[_0x4a7f6a([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x417e46[_0x4a7f6a([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x17da6e,_0x17da6e+0x2));_0x345bd2>=_0x2f43df[_0x4a7f6a([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x345bd2-=_0x2f43df[_0x4a7f6a([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x5690a1+=_0x2f43df[_0x345bd2];}return _0x5690a1;}function _0x3debc8(){const _0x135390=_0x20e0ae[_0x4a7f6a([0x73,0x70,0x6c,0x69,0x74])](_0x4a7f6a([0x2e]));if(0x3!=_0x135390[_0x4a7f6a([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x4b11a0(_0x135390[0x1]);function _0x4b11a0(_0x5e5c81){const _0x21fdeb=_0x44d8b8(_0x5e5c81);return _0x21fdeb&&_0x106188()?_0x21fdeb:null;function _0x106188(){const _0x5ee9da=_0x21fdeb[_0x4a7f6a([0x6a,0x74,0x69])],_0x3ef87e=window[_0x4a7f6a([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x5ee9da[_0x4a7f6a([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x5ee9da[_0x4a7f6a([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x11d9cc={..._0x21fdeb,[_0x4a7f6a([0x6a,0x74,0x69])]:_0x5ee9da[_0x4a7f6a([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x5ee9da[_0x4a7f6a([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x11d9cc[_0x4a7f6a([0x76,0x63])],_0x2820c2(_0x11d9cc)==_0x3ef87e;}}}async function _0x4ccc39(){let _0x5a397f=!0x0;try{const _0x55e420=_0x20e0ae[_0x4a7f6a([0x73,0x70,0x6c,0x69,0x74])](_0x4a7f6a([0x2e])),[_0x583da4,_0x2f6a14,_0x238b18]=_0x55e420;return _0x3f654b(_0x583da4),await _0x42656f(_0x583da4,_0x2f6a14,_0x238b18),_0x5a397f;}catch(_0x5c5c15){return!0x1;}function _0x3f654b(_0x555756){const _0x3560a0=_0x44d8b8(_0x555756);_0x3560a0&&_0x3560a0[_0x4a7f6a([0x61,0x6c,0x67])]==_0x4a7f6a([0x45,0x53,0x32,0x35,0x36])||(_0x5a397f=!0x1);}async function _0x42656f(_0x248749,_0x591b88,_0x5b6faa){const _0x5bae9c=window[_0x4a7f6a([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x4a7f6a([0x66,0x72,0x6f,0x6d])](_0x24124d(_0x5b6faa),_0xd6b49d=>_0xd6b49d[_0x4a7f6a([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x46a72c=new window[(_0x4a7f6a([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x4a7f6a([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x248749+_0x4a7f6a([0x2e])+_0x591b88),_0x83fe65=window[_0x4a7f6a([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x4a7f6a([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x83fe65)return;const _0x2b73d1=await _0x83fe65[_0x4a7f6a([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x4a7f6a([0x6a,0x77,0x6b]),_0x2580e1,{[_0x4a7f6a([0x6e,0x61,0x6d,0x65])]:_0x4a7f6a([0x45,0x43,0x44,0x53,0x41]),[_0x4a7f6a([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x4a7f6a([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x4a7f6a([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x83fe65[_0x4a7f6a([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x4a7f6a([0x6e,0x61,0x6d,0x65])]:_0x4a7f6a([0x45,0x43,0x44,0x53,0x41]),[_0x4a7f6a([0x68,0x61,0x73,0x68])]:{[_0x4a7f6a([0x6e,0x61,0x6d,0x65])]:_0x4a7f6a([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x2b73d1,_0x5bae9c,_0x46a72c)||(_0x5a397f=!0x1);}}function _0x44d8b8(_0x322771){return _0x322771[_0x4a7f6a([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x4a7f6a([0x65,0x79]))?JSON[_0x4a7f6a([0x70,0x61,0x72,0x73,0x65])](_0x24124d(_0x322771)):null;}function _0x24124d(_0x21f9db){return window[_0x4a7f6a([0x61,0x74,0x6f,0x62])](_0x21f9db[_0x4a7f6a([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x4a7f6a([0x2b]))[_0x4a7f6a([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x4a7f6a([0x2f])));}function _0x2820c2(_0x1b038e){let _0x413d18=0x1505;function _0x2c9607(_0x5bf73f){for(let _0x1fa0e4=0x0;_0x1fa0e4<_0x5bf73f[_0x4a7f6a([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x1fa0e4++){const _0x5a8e6b=_0x5bf73f[_0x4a7f6a([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x1fa0e4);_0x413d18=(_0x413d18<<0x5)+_0x413d18+_0x5a8e6b,_0x413d18&=_0x413d18;}}function _0x15cf42(_0x2eb0e0){Array[_0x4a7f6a([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x2eb0e0)?_0x2eb0e0[_0x4a7f6a([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x15cf42):_0x2eb0e0&&typeof _0x2eb0e0==_0x4a7f6a([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x4a7f6a([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x2eb0e0)[_0x4a7f6a([0x73,0x6f,0x72,0x74])]()[_0x4a7f6a([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x346356,_0x20cca0])=>{_0x2c9607(_0x346356),_0x15cf42(_0x20cca0);}):_0x2c9607(window[_0x4a7f6a([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x2eb0e0));}return _0x15cf42(_0x1b038e),_0x413d18>>>0x0;}function _0x2e250e(_0x1a2856){return _0x1a2856[_0x4a7f6a([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x4a7f6a([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x4a7f6a([0x30]));}function _0x322e2a(_0x4c34ea){return _0x4c34ea[_0x4a7f6a([0x73,0x70,0x6c,0x69,0x74])]('')[_0x4a7f6a([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x4a7f6a([0x6a,0x6f,0x69,0x6e])]('');}function _0x141ac2(_0x5a8467){return _0x403453[_0x4a7f6a([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x4a7f6a([0x68,0x61,0x73])](_0x5a8467);}function _0x29f32b(_0x336941){return _0x403453[_0x4a7f6a([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x4a7f6a([0x67,0x65,0x74])](_0x336941);}function _0xd078c(){}function _0x4a7f6a(_0x3577e7){return _0x3577e7['map'](_0x4e62fe=>String['fromCharCode'](_0x4e62fe))['join']('');}_0x1e9fb1(await _0x36dd41());}(this);}['createRevision'](_0x3008ae){const _0x4059cf=this['editor']['plugins']['get']('Users');return new a({'id':_0x3008ae['id'],'name':_0x3008ae['name'],'creator':_0x3008ae['creatorId']?_0x4059cf['getUser'](_0x3008ae['creatorId']):null,'diffData':_0x3008ae['diffData']||_0x3008ae['data'],'authors':_0x3008ae['authorsIds']['map'](_0x766065=>_0x4059cf['getUser'](_0x766065)),'createdAt':new Date(_0x3008ae['createdAt']),'attributes':_0x3008ae['attributes'],'fromVersion':_0x3008ae['fromVersion'],'toVersion':_0x3008ae['toVersion']});}['addRevision'](_0x1ebdfc,_0x4e3eb9=0x0){this['_revisions']['add'](_0x1ebdfc,_0x4e3eb9);}['getRevision'](_0x15dd0d){return this['_revisions']['get'](_0x15dd0d);}['getRevisions'](_0x1f55c0={'toJSON':!0x1}){const _0x2941d7=Array['from'](this['_revisions']);return _0x2941d7['reverse'](),_0x1f55c0['toJSON']?_0x2941d7['map'](_0x3610cf=>_0x3610cf['toJSON']()):_0x2941d7;}['getIndex'](_0x39d63f){return this['_revisions']['getIndex'](_0x39d63f);}['getEarlierVisibleRevision'](_0x555108){const [,_0x48f235]=this['getRevisionsIterator'](_0x555108,{'direction':'earlier'});return _0x48f235;}['getLaterVisibleRevision'](_0x19a6a8){const [,_0x3a25b7]=this['getRevisionsIterator'](_0x19a6a8,{'direction':'later'});return _0x3a25b7;}['getRevisionsInDiff'](_0x3c65d9){const _0x7db22b=[];for(const _0x3d6bb1 of this['getRevisionsIterator'](_0x3c65d9['newRevisionId']))if(_0x7db22b['push'](_0x3d6bb1),_0x3d6bb1['id']===_0x3c65d9['oldRevisionId'])break;return _0x7db22b;}*['getRevisionsIterator'](_0x51905c,{direction:_0x89522f='earlier',filter:_0x29510b=()=>!0x0}={}){const _0x11d621='earlier'===_0x89522f?0x1:-0x1;let _0x1a4561=this['_revisions']['get'](_0x51905c),_0x2d517=this['getIndex'](_0x1a4561);for(yield _0x1a4561;_0x1a4561;){if(_0x2d517+=_0x11d621,_0x1a4561=this['getRevision'](_0x2d517),!_0x1a4561)return;_0x29510b(_0x1a4561)&&(yield _0x1a4561);}}}function R(_0x391a0d,_0x36b79f,_0x54025d){const t=_0x391a0d['t'];switch(_0x36b79f){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'},_0x54025d);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x54025d);case'Show\x20previous\x20change':return t('Show\x20previous\x20change');case'Show\x20next\x20change':return t('Show\x20next\x20change');case'EDIT_X_OF_Y_REVISIONS':return t({'string':'Edit','id':'EDIT_X_OF_Y_REVISIONS'});case'Total':return t('Total');case'Revision\x20creator':return t('Revision\x20creator');case'Revision\x20author':return t('Revision\x20author');case'Revision\x20name':return t('Revision\x20name');case'Save\x20current\x20revision':return t('Save\x20current\x20revision');case'Accept':return t('Accept');case'Save':return t('Save');case'Cancel':return t('Cancel');case'Name\x20of\x20the\x20revision':return t('Name\x20of\x20the\x20revision');case'optional':return t('optional');case'PENDING_ACTION_REVISION_HISTORY':return t({'string':'Unsaved\x20change\x20in\x20revision\x20history.','id':'PENDING_ACTION_REVISION_HISTORY'});case'The\x20revision\x20name\x20cannot\x20be\x20empty.':return t('The\x20revision\x20name\x20cannot\x20be\x20empty.');case'Enter\x20the\x20revision\x20name':return t('Enter\x20the\x20revision\x20name');default:return'';}}const C={'c':_0x11e705,'a':_0x25db7e,'e':_0x10f6d4,'r':_0x5d57f5,'u':_0x5bea37};class l extends _0x49970d{['licenseKey'];['_licenseKeyCheckInterval'];['adapter'];['currentRevision'];['repository'];['_revisionDataBuilder'];['_source'];['_initialRevisionId'];['_bufferedUpdates'];['_pendingAction'];['_continueCurrentRevision'];['_startingVersion'];['_loadedStateData'];static get['pluginName'](){return'RevisionTracker';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[_0x122c7d,j,_0x461491];}constructor(_0x36a38c){super(_0x36a38c),this['adapter']=null,this['currentRevision']=null,this['_revisionDataBuilder']=new T(this['editor']),this['_initialRevisionId']=this['editor']['config']['get']('collaboration.channelId')||'initial',this['_bufferedUpdates']=new Map(),this['_loadedStateData']=null;const _0x28b837=_0x4f9a89();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x28b837},this['set']('isReady',!0x1),this['set']('isEnabled',!0x0),this['set']('_isPendingUpdate',!0x1),this['editor']['config']['define']('revisionHistory.resumeUnsavedRevision',!0x0),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'});}['init'](){this['repository']=this['editor']['plugins']['get']('RevisionsRepository'),this['_setConversion'](),this['editor']['data']['on']('ready',()=>{const _0x124a95=this['repository']['getRevision'](0x0),_0x213cd7=_0x124a95&&null===_0x124a95['creator']?_0x124a95:null;if(this['_continueCurrentRevision']=!!_0x213cd7&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x56c156=this['_source']['getCurrentRevisionId'](),_0x3029d5=this['repository']['getRevision'](_0x56c156);if(_0x3029d5)this['_startingVersion']=_0x3029d5['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x2f74de=this['_source']['history']['_operations']['find'](_0x3b3054=>!_0x3b3054['_isInit']),_0x4df33b=_0x2f74de?_0x2f74de['baseVersion']:this['_source']['history']['version'];_0x124a95?(_0x124a95['toVersion']<_0x4df33b&&_0x124a95['_update']({'toVersion':_0x4df33b}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x213cd7['id'],this['_startingVersion']=_0x213cd7['fromVersion']):(this['_startingVersion']=_0x124a95['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x4df33b,this['_continueCurrentRevision']=!0x1);}}else _0x213cd7&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x213cd7['toVersion'],this['editor']['model']['document']['history']['version']),_0x213cd7['fromVersion']===_0x213cd7['toVersion']?(0x0!==_0x213cd7['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x213cd7['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x213cd7['id'],this['_startingVersion']=_0x213cd7['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',_0x262106=>!_0x262106),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0xb6de01=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x445081;for(const _0x2bf605 in _0xb6de01){const _0x50d592=_0x2bf605,_0x5bef91=_0xb6de01[_0x50d592];if('revisionHistoryLicenseKeyValid'==_0x5bef91||'revisionHistoryLicenseKeyInvalid'==_0x5bef91||'revisionHistoryLicenseKeyExpired'==_0x5bef91||'revisionHistoryLicenseKeyDomainLimit'==_0x5bef91||'revisionHistoryLicenseKeyNotAllowed'==_0x5bef91||'revisionHistoryLicenseKeyEvaluationLimit'==_0x5bef91||'revisionHistoryLicenseKeyTrialLimit'==_0x5bef91||'revisionHistoryLicenseKeyDevelopmentLimit'==_0x5bef91||'revisionHistoryLicenseKeyUsageLimit'==_0x5bef91){delete _0xb6de01[_0x50d592],_0x445081=_0x5bef91,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x445081&&_0xb6de01['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x445081&&_0xb6de01['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x445081&&_0xb6de01['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x445081&&_0xb6de01['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x445081&&_0xb6de01['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x445081&&_0xb6de01['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyDevelopmentLimit'==_0x445081&&_0xb6de01['_showLicenseError']('developmentLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x445081&&_0xb6de01['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x2c21bf=this['repository']['getRevision'](0x0),_0x2f79a6=await this['getRevisionDocumentData'](_0x2c21bf),_0x22334c=await this['getRevisionRootsAttributes'](_0x2c21bf);this['_replaceEditorDataWithRevisionData'](_0x2f79a6,_0x22334c);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x4effd6){this['_source']=_0x4effd6;}async['update'](){const _0x138613=await this['_source']['getLatestVersion']();if(_0x138613>this['currentRevision']['toVersion']){await this['_loadState']();const _0x322032=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x138613});_0x322032['authors']=_0x322032['authorsIds']['map'](_0x2d15bb=>this['editor']['plugins']['get']('Users')['getUser'](_0x2d15bb)),this['currentRevision']['_update'](_0x322032);}}async['_loadState'](){this['_continueCurrentRevision']&&!this['_loadedStateData']&&(await this['_loadRevisionData'](this['currentRevision']),this['_revisionDataBuilder']['loadState'](this['currentRevision']),this['_loadedStateData']={'fromVersion':this['currentRevision']['fromVersion'],'authors':this['currentRevision']['authors']['slice']()});}async['saveRevision'](_0x4b9868={},_0x1c1665=null){const _0xedfea6=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x1c1665>this['currentRevision']['toVersion']&&(_0x1c1665=null),null===_0x1c1665&&(_0x1c1665=await this['_source']['getLatestVersion']());const _0x6791d8=this['_getFromVersion'](_0x1c1665),_0x1cd9da=this['buildRevisionData']({'from':_0x6791d8,'to':_0x1c1665});if(this['currentRevision']['toVersion']<_0x1c1665){const _0x59f11d=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x1c1665,'to':_0x1c1665});_0x59f11d['authors']=[],_0x59f11d['authorsIds']=[],_0x59f11d['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x59f11d,!0x0),delete _0x59f11d['authors'],_0xedfea6['push'](_0x59f11d);}_0x4b9868['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x4b9868['name']=_0x4b9868['name']||null,_0x4b9868['id']=_0x4b9868['id']||_0x4f9a89(),_0x4b9868={..._0x4b9868,..._0x1cd9da};const _0x111a6d=this['addRevisionData'](_0x4b9868);_0xedfea6['push'](_0x4b9868);const _0x25fd6c=this['repository']['getIndex'](_0x111a6d);if(0x0!==_0x25fd6c){const _0x42c3f6=this['repository']['getRevision'](_0x25fd6c-0x1);if(_0x42c3f6['fromVersion']!==_0x1c1665){const _0x51585a=this['_revisionDataBuilder']['getData'](_0x1c1665,_0x42c3f6['toVersion']),_0x2bd9f9={'id':_0x42c3f6['id'],'diffData':_0x51585a['diffData'],'authorsIds':_0x51585a['authorsIds'],'authors':_0x51585a['authorsIds']['map'](_0x4cdf38=>this['editor']['plugins']['get']('Users')['getUser'](_0x4cdf38)),'fromVersion':_0x1c1665};_0x42c3f6===this['currentRevision']&&(_0x2bd9f9['createdAt']=new Date(_0x4b9868['createdAt']['getTime']()+0xa)),_0x42c3f6['_update'](_0x2bd9f9,!0x0),delete _0x2bd9f9['authors'],_0xedfea6['push'](_0x2bd9f9);}}if(this['adapter']){for(const _0x3c79de of _0xedfea6)this['_bufferUpdate'](_0x3c79de['id'],_0x3c79de,!0x0);this['sendBufferedUpdates']();}return _0x111a6d;}['addRevisionData'](_0x49ccf0){const _0xae5859=this['repository']['createRevision'](_0x49ccf0);return this['adapter']&&_0xae5859['on']('_update',(_0x326234,_0x4cdcab,_0x3a64d9)=>{_0x3a64d9||(this['_bufferUpdate'](_0x4cdcab['id'],_0x4cdcab,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0xae5859,this['_findInsertionIndex'](_0xae5859)),_0xae5859;}async['getRevisionDocumentData'](_0x371289){await this['_loadRevisionData'](_0x371289);const _0x44e1df={};for(const _0x283f9c in _0x371289['diffData']){if(_0x371289['diffData'][_0x283f9c]['attachChange']&&!_0x371289['diffData'][_0x283f9c]['attachChange']['isAttached'])continue;const _0x56cb27=this['_removeRevisionMarkers'](JSON['parse'](_0x371289['diffData'][_0x283f9c]['insertions'])),_0x5a65f4=this['editor']['editing']['view']['document'],_0x36a869=new _0x59148e(_0x5a65f4,_0x56cb27['map'](_0x859050=>V(_0x859050,this['editor'])));this['editor']['data']['processor']['useFillerType']('marked'),_0x44e1df[_0x283f9c]=this['editor']['data']['processor']['toData'](_0x36a869),this['editor']['data']['processor']['useFillerType']('default');}return _0x44e1df;}async['getRevisionRootsAttributes'](_0x58d38a){await this['_loadRevisionData'](_0x58d38a);const _0x45b92b={};for(const _0x51215b in _0x58d38a['diffData'])_0x58d38a['diffData'][_0x51215b]['attachChange']&&!_0x58d38a['diffData'][_0x51215b]['attachChange']['isAttached']||(_0x45b92b[_0x51215b]=_0x58d38a['diffData'][_0x51215b]['attributesAfter']||{});return _0x45b92b;}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x12cac5=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x31d375=0x0;_0x31d375<_0x12cac5['length'];_0x31d375++){const _0x25879b=_0x12cac5[_0x31d375];let _0x2f864c=!0x1;for(const _0x46da4e of Object['keys'](_0x25879b))void 0x0===_0x25879b[_0x46da4e]?delete _0x25879b[_0x46da4e]:'id'!==_0x46da4e&&(_0x2f864c=!0x0);_0x2f864c||(_0x12cac5[_0x31d375]=null);}if(_0x12cac5=_0x12cac5['filter'](_0x492905=>null!==_0x492905),!_0x12cac5['length'])return;for(let _0x315aca=0x0;_0x315aca<_0x12cac5['length'];_0x315aca++){const _0x572c3c=_0x12cac5[_0x315aca];void 0x0!==_0x572c3c['fromVersion']&&void 0x0===_0x572c3c['toVersion']&&(_0x572c3c['toVersion']=this['repository']['getRevision'](_0x572c3c['id'])['toVersion']),void 0x0!==_0x572c3c['toVersion']&&void 0x0===_0x572c3c['fromVersion']&&(_0x572c3c['fromVersion']=this['repository']['getRevision'](_0x572c3c['id'])['fromVersion']);}const _0x1dec12=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x12cac5,_0x1dec12)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x54a5d4=>{if(_0x54a5d4){for(const _0x1c6a69 of _0x54a5d4)this['setRevisionData']({'id':_0x1c6a69['id'],'createdAt':_0x1c6a69['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['_replaceEditorDataWithRevisionData'](_0x3f31f5,_0x4208b4){let _0x2ccf7f=this['editor']['config']['get']('initialData'),_0x2b9908=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x2ccf7f){_0x2ccf7f={};for(const _0x3a3c24 of this['editor']['model']['document']['getRootNames']())_0x2ccf7f[_0x3a3c24]='';}if('string'==typeof _0x2ccf7f&&(_0x2ccf7f={'main':_0x2ccf7f}),void 0x0===_0x2b9908){_0x2b9908={};for(const _0x5bdd80 of this['editor']['model']['document']['getRootNames']())_0x2b9908[_0x5bdd80]={};}let _0x286c94=!0x1;const _0x5a804f=Object['keys'](_0x2ccf7f),_0x1b04c5=Object['keys'](_0x3f31f5);for(const _0x37bca3 of _0x5a804f){if(_0x2ccf7f[_0x37bca3]!==_0x3f31f5[_0x37bca3]&&''!==_0x2ccf7f[_0x37bca3]['trim']()){_0x286c94=!0x0;break;}if(!_0x4b1bee(_0x2b9908[_0x37bca3],_0x4208b4[_0x37bca3])&&Object['keys'](_0x2b9908[_0x37bca3])['length']>0x0){_0x286c94=!0x0;break;}}_0x286c94||(_0x286c94=_0x1b04c5['some'](_0x2f0fde=>!this['editor']['model']['document']['getRoot'](_0x2f0fde))),_0x286c94&&_0x1b89a0('editor-initial-data-replaced-with-revision-data',{'editorData':_0x2ccf7f,'editorRootsAttributes':_0x2b9908,'revisionData':_0x3f31f5,'revisionRootsAttributes':_0x4208b4}),this['editor']['config']['set']('initialData',_0x3f31f5),this['editor']['config']['set']('rootsAttributes',_0x4208b4);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x3968c1=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x3968c1['add'](R(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x2da0cd){const _0xfd6fb5=this['repository']['getRevisions']();_0xfd6fb5['reverse']();let _0x2786e9=0x0;for(;_0x2786e9<_0xfd6fb5['length'];){const _0x3424e3=_0xfd6fb5[_0x2786e9];if(_0x3424e3===this['currentRevision']){_0x2786e9++;continue;}if(_0x3424e3['id']===this['_initialRevisionId'])break;const _0x5bb1b9=_0x2da0cd['toVersion']-_0x3424e3['toVersion']||_0x2da0cd['fromVersion']-_0x3424e3['fromVersion'];if(_0x5bb1b9>0x0)break;if(_0x5bb1b9<0x0)_0x2786e9++;else{if(!_0x2da0cd['creator']&&_0x3424e3['creator'])break;if(_0x3424e3['creator']||!_0x2da0cd['creator']){if(_0x2da0cd['createdAt']>_0x3424e3['createdAt'])break;_0x2786e9++;}else _0x2786e9++;}}return _0x2786e9;}['setRevisionData'](_0x26828e){const _0x355f1f=this['repository']['getRevision'](_0x26828e['id']);if(_0x26828e['createdAt']&&(_0x26828e['createdAt']=new Date(_0x26828e['createdAt'])),_0x26828e['authorsIds']){const _0x37021d=this['editor']['plugins']['get']('Users');_0x26828e['authors']=_0x26828e['authorsIds']['map'](_0x5dd23c=>_0x37021d['getUser'](_0x5dd23c));}_0x355f1f['_update'](_0x26828e,!0x0);}['buildRevisionData']({revision:_0x573773=null,from:_0x2e7743=null,to:_0x5ab27a=null}){_0x2e7743=null!==_0x2e7743?_0x2e7743:_0x573773['fromVersion'],_0x5ab27a=null!==_0x5ab27a?_0x5ab27a:_0x573773['toVersion'];const _0x5b0c4c=this['_revisionDataBuilder']['getData'](_0x2e7743,_0x5ab27a),_0x54ad77={'diffData':_0x5b0c4c['diffData'],'authorsIds':_0x5b0c4c['authorsIds'],'fromVersion':_0x2e7743,'toVersion':_0x5ab27a};if(!_0x573773||_0x5ab27a!==_0x573773['toVersion']){const _0x2b8874=_0x5ab27a-0x1,_0x20b308=this['_source']['history']['getOperation'](_0x2b8874);_0x54ad77['createdAt']=_0x20b308&&_0x20b308['createdAt']||new Date();}if(this['_loadedStateData']&&_0x2e7743===this['_loadedStateData']['fromVersion']){for(const _0x498f85 of this['_loadedStateData']['authors'])_0x54ad77['authorsIds']['includes'](_0x498f85['id'])||_0x54ad77['authorsIds']['push'](_0x498f85['id']);}return _0x54ad77;}['_loadRevisionData'](_0x5b1bba){if(!_0x5b1bba||_0x5b1bba['diffData'])return Promise['resolve']();{const _0x3836b5=this['editor']['config']['get']('collaboration.channelId');return this['adapter']['getRevision']({'channelId':_0x3836b5,'revisionId':_0x5b1bba['id']})['then'](_0x121d8c=>{_0x5b1bba['diffData']=_0x121d8c['diffData'];});}}['_bufferUpdate'](_0x2b3001,_0xbe8f69,_0x32451d){if(this['_bufferedUpdates']['has'](_0x2b3001)){const _0x8b6601=this['_bufferedUpdates']['get'](_0x2b3001);_0xbe8f69=_0x32451d?{..._0x8b6601,..._0xbe8f69}:{..._0xbe8f69,..._0x8b6601};}this['_bufferedUpdates']['set'](_0x2b3001,_0xbe8f69);}['_getFromVersion'](_0x3b91c6){const _0x308ac0=this['repository']['getRevisions']();_0x308ac0['reverse'](),_0x308ac0['shift']();const _0x58132f=_0x308ac0['find'](_0x14cc2a=>_0x14cc2a['toVersion']<=_0x3b91c6)['toVersion'];return _0x58132f<this['_startingVersion']?this['_startingVersion']:_0x58132f;}['_createInitialRevision'](_0x1666fc){const _0x4de8c5=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x4de8c5)this['_initialRevisionId']=_0x4de8c5['id'];else{const _0x5ac285=!this['editor']['model']['document']['roots']['find'](_0x4ebb2f=>this['editor']['model']['hasContent'](_0x4ebb2f)),_0x20e3c7=this['editor']['plugins']['get']('Users')['me']['id'],_0x35b91e=R(this['editor']['locale'],_0x5ac285?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x1666fc,'to':_0x1666fc,'id':this['_initialRevisionId'],'name':_0x35b91e,'creatorId':_0x20e3c7});}}['_createCurrentRevision'](_0x34c1d6){const _0x5877fe=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x5877fe),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x34c1d6,'to':_0x34c1d6,'id':_0x5877fe,'name':'','creatorId':null}));}['_makeRevision']({name:_0x1017e2,from:_0xb11327,to:_0xbb6088,creatorId:_0xafaeca,id:_0x3346bc}){const _0x170b15=this['buildRevisionData']({'from':_0xb11327,'to':_0xbb6088});_0x170b15['name']=_0x1017e2,_0x170b15['creatorId']=_0xafaeca,_0x170b15['id']=_0x3346bc;const _0x43df31=this['addRevisionData'](_0x170b15);return this['adapter']&&this['_bufferUpdate'](_0x170b15['id'],_0x170b15,!0x0),_0x43df31;}['_setConversion'](){this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'});}['_removeRevisionMarkers'](_0x4969c2){return(_0x4969c2=_0x4969c2['filter'](_0x346384=>!_0x346384['name']||'revision-start'!==_0x346384['name']&&'revision-end'!==_0x346384['name']))['forEach'](_0x48ca1a=>{'string'!=typeof _0x48ca1a&&(_0x48ca1a['children']=this['_removeRevisionMarkers'](_0x48ca1a['children']),_0x48ca1a['attributes']=_0x48ca1a['attributes']['filter'](_0x58c58b=>!_0x58c58b[0x0]['startsWith']('data-revision-')));}),_0x4969c2;}}function V(_0x1377e3,_0xd1e27c){const _0x2ec5d6=_0xd1e27c['editing']['view']['document'];if('string'==typeof _0x1377e3)return new _0x224f95(_0x2ec5d6,_0x1377e3);{const _0xdc117d=_0x1377e3['children']['map'](_0xa680b3=>V(_0xa680b3,_0xd1e27c));return new(C[_0x1377e3['type']]||_0x3dbac4)(_0x2ec5d6,_0x1377e3['name'],_0x1377e3['attributes'],_0xdc117d);}}class T{['editor'];['source'];['_savedMetaData'];['_lastFrom'];['_lastTo'];['_markers'];['_diffRoots'];['_diffRootsAttributes'];['_baseRoots'];['_baseRootsAttributes'];['_idsRoots'];['_baseIdsRoots'];['_touched'];['_touchedMarkers'];['_touchedRoots'];['_revisionId'];['_startingRevisionId'];constructor(_0x28a90a){this['editor']=_0x28a90a,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'](_0x346bad){this['source']=_0x346bad;const _0x267c36=new Map(),_0x2f5f64=new Map(),_0x32a89a=this['editor']['model']['document']['roots']['map'](_0x11ecf5=>_0x11ecf5['rootName']);for(const _0x3aa41d of _0x32a89a){const _0x5310bc=this['editor']['model']['document']['getRoot'](_0x3aa41d),_0x59fdec=F(_0x5310bc);_0x267c36['set'](_0x3aa41d,_0x59fdec),_0x2f5f64['set'](_0x3aa41d,Object['fromEntries'](_0x5310bc['getAttributes']()));}const _0x260ee7=Array['from'](this['editor']['model']['markers'])['map'](_0x8c895a=>[_0x8c895a['name'],_0x8c895a['getRange']()]),_0x54a5d2=this['source']['version'];this['_saveMetaData'](_0x54a5d2,_0x267c36,_0x260ee7,_0x2f5f64),this['_startingRevisionId']=this['_revisionId'];const _0x210101=new Map(),_0x30a0f0=new Map();for(const _0x40c545 of _0x32a89a){const _0x5c00e1=B(_0x40c545);_0x210101['set'](_0x40c545,_0x5c00e1),_0x30a0f0['set'](_0x40c545,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x210101,[],_0x30a0f0);}['getData'](_0x33b9d6,_0x910d45){if(this['_lastFrom']===_0x33b9d6&&this['_lastTo']<=_0x910d45)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x910d45,!0x0);else{if(!this['_savedMetaData']['has'](_0x33b9d6)){const _0x75419b=this['_getPreviousFrom'](_0x33b9d6);this['_calculateMetaData'](_0x75419b,_0x33b9d6,!0x1);}this['_calculateMetaData'](_0x33b9d6,_0x910d45,!0x0);}return this['_lastFrom']=_0x33b9d6,this['_lastTo']=_0x910d45,this['_getState']();}['loadState'](_0x42b94a){this['_reset'](),this['_lastFrom']=_0x42b94a['fromVersion'],this['_lastTo']=_0x42b94a['toVersion'];for(const _0x4e7586 in _0x42b94a['diffData']){const _0x523771=_0x42b94a['diffData'][_0x4e7586]['attachChange'],_0x4513fc=_0x1ea11a(_0x42b94a['diffData'][_0x4e7586]['attributesBefore'])||{},_0x4b6538=this['_makeModelFromViewString'](_0x42b94a['diffData'][_0x4e7586]['deletions']);_0x4b6538['rootName']=_0x4e7586,_0x4b6538['_isAttached']=!_0x523771||!_0x523771['isAttached'],_0x4b6538['isAttached']=()=>_0x4b6538['_isAttached'],this['_baseRoots']['set'](_0x4e7586,_0x4b6538),this['_baseRootsAttributes']['set'](_0x4e7586,_0x4513fc),_0x523771&&this['_touchedRoots']['set'](_0x4e7586,_0x523771);const _0x2c757a=this['_makeIdsRoot'](_0x4b6538);this['_baseIdsRoots']['set'](_0x4e7586,_0x2c757a);for(const [_0x4c5e3f,_0x1368c9]of _0x4b6538['markers']){if(!_0x4c5e3f['startsWith']('revision:'))continue;const _0x145fd2=_0x4c5e3f['split'](':')[0x2];for(const _0x635d22 of _0x1368c9['getWalker']({'singleCharacters':!0x0})){const _0x56be26=this['_getVidAttributeName'](_0x635d22),_0x2fe144='elementEnd'==_0x635d22['type']?_0x635d22['previousPosition']['path']['slice'](0x0,-0x1):_0x635d22['previousPosition']['path'],_0x2ccc10=_0x2c757a['getNodeByPath'](_0x2fe144)['getAttribute'](_0x56be26);this['_touched']['set'](_0x2ccc10,{'userId':_0x145fd2});}}}this['_startingRevisionId']=this['_revisionId'];const _0x4d6a9d=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x3842fc=>!this['_touched']['has'](_0x3842fc));let _0x2eafc0=0x0;const _0x3ae627=new Map();for(const _0x4f0430 in _0x42b94a['diffData']){const _0x330dcf=_0x42b94a['diffData'][_0x4f0430]['attachChange'],_0x41cdf7=_0x1ea11a(_0x42b94a['diffData'][_0x4f0430]['attributesAfter'])||{},_0x360abc=this['_makeModelFromViewString'](_0x42b94a['diffData'][_0x4f0430]['insertions']);_0x360abc['rootName']=_0x4f0430,_0x360abc['_isAttached']=!_0x330dcf||_0x330dcf['isAttached'],_0x360abc['isAttached']=()=>_0x360abc['_isAttached'],this['_diffRoots']['set'](_0x4f0430,_0x360abc),this['_diffRootsAttributes']['set'](_0x4f0430,_0x41cdf7);const _0x3490af=this['_makeIdsRoot'](_0x360abc,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x4f0430,_0x3490af),_0x3ae627['set'](_0x4f0430,_0x360abc['isAttached']()?_0x41cdf7:{});for(const [_0xd55c9a,_0x452afe]of _0x360abc['markers']){if(!_0xd55c9a['startsWith']('revision:'))continue;const _0x18d6de=_0xd55c9a['split'](':')[0x2];for(const _0x5cd301 of _0x452afe['getWalker']({'singleCharacters':!0x0})){const _0xa31dfb=this['_getVidAttributeName'](_0x5cd301),_0x2ffbee=this['_revisionId']++,_0x50f180='elementEnd'==_0x5cd301['type']?_0x5cd301['previousPosition']['path']['slice'](0x0,-0x1):_0x5cd301['previousPosition']['path'];_0x3490af['getNodeByPath'](_0x50f180)['_setAttribute'](_0xa31dfb,_0x2ffbee),this['_touched']['set'](_0x2ffbee,{'userId':_0x18d6de});}}for(const _0x1a8d45 of this['editor']['model']['createRangeIn'](_0x360abc)['getWalker']({'singleCharacters':!0x0})){const _0x3fc989=this['_getVidAttributeName'](_0x1a8d45),_0x31ab9e='elementEnd'==_0x1a8d45['type']?_0x1a8d45['previousPosition']['path']['slice'](0x0,-0x1):_0x1a8d45['previousPosition']['path'],_0x20740d=_0x3490af['getNodeByPath'](_0x31ab9e);_0x20740d['getAttribute'](_0x3fc989)>0x0||_0x20740d['_setAttribute'](_0x3fc989,_0x4d6a9d[_0x2eafc0++]);}for(const [_0xb172f6,_0x4f2846]of _0x360abc['markers'])_0xb172f6['startsWith']('revision:')||this['_markers']['set'](_0xb172f6,_0x4f2846);}const _0x43be6d=B('$graveyard');this['_baseRoots']['set']('$graveyard',_0x43be6d),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x43be6d,0x1));const _0x27a469=B('$graveyard');this['_diffRoots']['set']('$graveyard',_0x27a469),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x27a469,0x1));const _0x55ab50=Array['from'](this['_diffRoots'])['map'](([_0xc297b4,_0x1e151b])=>[_0xc297b4,F(_0x1e151b)]);this['_saveMetaData'](this['_lastTo'],_0x55ab50,this['_markers'],_0x3ae627);}['_makeModelFromViewString'](_0x570c16){const _0x41e887=JSON['parse'](_0x570c16),_0x470243=this['editor']['editing']['view']['document'],_0x3bcfa6=new _0x59148e(_0x470243,_0x41e887['map'](_0x3c19ae=>V(_0x3c19ae,this['editor'])));return this['editor']['data']['toModel'](_0x3bcfa6);}['_saveMetaData'](_0x2978af,_0x15e335,_0xd2be30,_0x145b92){const _0x3a169d=new Map(_0x15e335),_0x12a1c6=new Map(_0x1ea11a(_0x145b92)),_0xc29e2c=new Map();for(const [_0x45b35a,_0xa685bd]of _0xd2be30)_0xc29e2c['set'](_0x45b35a,{'start':_0xa685bd['start']['clone'](),'end':_0xa685bd['end']['clone'](),'rootName':_0xa685bd['root']['rootName']});this['_savedMetaData']['set'](_0x2978af,{'roots':_0x3a169d,'markers':_0xc29e2c,'rootsAttributes':_0x12a1c6});}['_removeMetaData'](_0x22765b){this['_savedMetaData']['delete'](_0x22765b);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_reset'](){this['_touched']['clear'](),this['_touchedMarkers']['clear'](),this['_touchedRoots']['clear'](),this['_diffRoots']['clear'](),this['_diffRootsAttributes']['clear'](),this['_baseRoots']['clear'](),this['_baseRootsAttributes']['clear'](),this['_idsRoots']['clear'](),this['_baseIdsRoots']['clear'](),this['_markers']['clear'](),this['_revisionId']=0x1,this['_startingRevisionId']=this['_revisionId'];}['_makeIdsRoot'](_0x5eee8a,_0x2bf51b=null){let _0x537c92=null;_0x5eee8a['is']('documentFragment')||(_0x537c92=new ft(_0x5eee8a['name'],{'vid_start':null===_0x2bf51b?this['_revisionId']++:_0x2bf51b++}));const _0x3211a6=[];for(const _0x190400 of _0x5eee8a['getChildren']())if(_0x190400['is']('element')){_0x3211a6['push'](this['_makeIdsRoot'](_0x190400,_0x2bf51b));const _0x35e799=_0x3211a6[_0x3211a6['length']-0x1];null!==_0x2bf51b&&(_0x2bf51b=_0x35e799['is']('element','$text')?_0x35e799['getAttribute']('vid')+0x1:_0x35e799['getAttribute']('vid_end')+0x1);}else{for(let _0x49b4f9=0x0;_0x49b4f9<_0x190400['offsetSize'];_0x49b4f9++)_0x3211a6['push'](new ft('$text',{'vid':null===_0x2bf51b?this['_revisionId']++:_0x2bf51b++}));}if(_0x5eee8a['is']('documentFragment')){const _0x215bb5=B(_0x5eee8a['rootName']);return _0x215bb5['_insertChild'](0x0,_0x3211a6),_0x215bb5;}return _0x537c92['_setAttribute']('vid_end',null===_0x2bf51b?this['_revisionId']++:_0x2bf51b++),_0x537c92['_insertChild'](0x0,_0x3211a6),_0x537c92;}['_calculateMetaData'](_0x50af48,_0x45ee70,_0x1ef97e){this['_reset']();const {roots:_0x43f010,markers:_0x29a3ae,rootsAttributes:_0x51657b}=this['_savedMetaData']['get'](_0x50af48);this['_baseRoots']=new Map(_0x43f010),this['_baseRootsAttributes']=new Map(_0x1ea11a(_0x51657b));for(const [_0x5d2aac,_0x1a8558]of this['_baseRoots'])if('$graveyard'!==_0x5d2aac&&(this['_diffRoots']['set'](_0x5d2aac,F(_0x1a8558)),this['_diffRootsAttributes']=new Map(_0x1ea11a(_0x51657b)),_0x1ef97e)){const _0x47410f=this['_revisionId'];this['_idsRoots']['set'](_0x5d2aac,this['_makeIdsRoot'](_0x1a8558)),this['_baseIdsRoots']['set'](_0x5d2aac,this['_makeIdsRoot'](_0x1a8558,_0x47410f));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',F(this['_baseRoots']['get']('$graveyard'))),_0x1ef97e&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x5c7d63,_0x58d476]of _0x29a3ae){const _0x2e42eb=this['_baseRoots']['get'](_0x58d476['rootName']),_0x265495=this['_diffRoots']['get'](_0x58d476['rootName']),_0x20deea=new vt(this['_fixPosition'](_0x58d476['start'],_0x2e42eb),this['_fixPosition'](_0x58d476['end'],_0x2e42eb)),_0x4ade3e=this['_fixRange'](_0x20deea,_0x265495);_0x2e42eb['markers']['set'](_0x5c7d63,_0x20deea),this['_markers']['set'](_0x5c7d63,_0x4ade3e);}this['_applyOperations'](_0x50af48,_0x45ee70,_0x1ef97e);}['_applyOperations'](_0xc43566,_0x2ea13d,_0x20e8c8){for(const _0x3e83aa of this['source']['getOperations'](_0xc43566,_0x2ea13d))this['_handleOperation'](_0x3e83aa,_0x20e8c8);for(const _0x2e9a49 of this['_diffRoots']['values']())_0x2e9a49['markers']['clear']();for(const [_0x57038d,_0x5e55ee]of this['_markers']){this['_diffRoots']['get'](_0x5e55ee['root']['rootName'])['markers']['set'](_0x57038d,_0x5e55ee['clone']());}const _0x1bc2f2=new Map(),_0x197f12=new Map();for(const [_0x136c27,_0xb026b7]of this['_diffRoots'])_0x1bc2f2['set'](_0x136c27,F(_0xb026b7)),_0x197f12['set'](_0x136c27,this['_diffRootsAttributes']['get'](_0x136c27));this['_saveMetaData'](_0x2ea13d,_0x1bc2f2,this['_markers'],_0x197f12);}['_getPreviousFrom'](_0x20d473){const _0x32de64=Array['from'](this['_savedMetaData']['keys']());_0x32de64['sort']((_0x52f229,_0x3183cc)=>_0x52f229-_0x3183cc),_0x32de64['reverse']();for(const _0x3a8c06 of _0x32de64)if(_0x3a8c06<_0x20d473)return _0x3a8c06;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x37d160,_0x5a7e16){const _0x1cde8e=Array['from'](_0x5a7e16['markers'])['map'](([_0x1c92cf,_0x512e13])=>[_0x1c92cf,this['_fixRange'](_0x512e13,_0x37d160)]);_0x37d160['markers']=new Map(_0x1cde8e);}['_transformMarkers'](_0x5f43db){for(const _0x41efb7 of this['_markers']['values']()){const _0x3fd43a=_0x41efb7['getTransformedByOperation'](_0x5f43db),_0x2aa0fc=vt['_createFromRanges'](_0x3fd43a);_0x41efb7['start']=_0x2aa0fc['start'],_0x41efb7['end']=_0x2aa0fc['end'];}}['_handleOperation'](_0x2d5cb3,_0x49e705){if('addRoot'!=_0x2d5cb3['type']&&'detachRoot'!=_0x2d5cb3['type']){if('insert'==_0x2d5cb3['type']){const _0x5a582c=_0x2d5cb3['position']['root']['rootName'];this['_diffRoots']['has'](_0x5a582c)||(this['_diffRoots']['set'](_0x5a582c,B(_0x5a582c,!0x0)),this['_diffRootsAttributes']['set'](_0x5a582c,{}),_0x49e705&&this['_idsRoots']['set'](_0x5a582c,B(_0x5a582c,!0x0)));}else{if('addRootAttribute'==_0x2d5cb3['type']||'removeRootAttribute'==_0x2d5cb3['type']||'changeRootAttribute'==_0x2d5cb3['type'])return void this['_handleRootAttributeOperation'](_0x2d5cb3);'marker'==_0x2d5cb3['type']&&this['_handleMarkerOperation'](_0x2d5cb3);}if('marker'!==_0x2d5cb3['type']){const _0x4fc678=this['_cloneOperation'](_0x2d5cb3,this['_diffRoots']);_0x4fc678['_execute'](),this['_transformMarkers'](_0x4fc678);}if(_0x49e705)switch(_0x2d5cb3['type']){case'insert':this['_handleInsertOperation'](_0x2d5cb3);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x2d5cb3);break;case'merge':this['_handleMergeOperation'](_0x2d5cb3);break;case'split':this['_handleSplitOperation'](_0x2d5cb3);}}else this['_handleRootOperation'](_0x2d5cb3,_0x49e705);}['_cloneOperation'](_0xea492d,_0xac1c47){const _0x141c76=_0xea492d['clone']();return _0x141c76['_authorId']=_0xea492d['_authorId'],this['_fixOperation'](_0x141c76,_0xac1c47),_0x141c76;}['_getBaseVids'](_0x560276){return _0x560276['map'](_0x3fe2b4=>{const _0x75312e=this['_getVidAttributeName'](_0x3fe2b4);return Number(_0x3fe2b4['item']['getAttribute'](_0x75312e));});}['_generateTape'](_0x250834,_0x15b203){if(_0x250834['is']('element','$text'))_0x15b203['push']({'item':_0x250834,'type':'text'});else{_0x250834['is']('element')&&_0x15b203['push']({'item':_0x250834,'type':'elementStart'});for(const _0x558c1a of _0x250834['getChildren']())this['_generateTape'](_0x558c1a,_0x15b203);_0x250834['is']('element')&&_0x15b203['push']({'item':_0x250834,'type':'elementEnd'});}return _0x15b203;}['_getState'](){const _0x5e3d1e=new Map(this['_touched']),_0x5b3a1c=new Map(_0x5e3d1e),_0x2baad2=new Map(),_0x361e90={'insertions':{},'deletions':{}},_0x26cf03={'insertions':{},'deletions':{}},_0x5a3153=new Map(),_0x38fe81=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x38fe81['delete']('$graveyard');for(const _0x488859 of _0x38fe81){const _0x34fbe2=this['_diffRoots']['get'](_0x488859)||B(_0x488859,!0x1),_0x566911=this['_baseRoots']['get'](_0x488859)||B(_0x488859,!0x1);_0x34fbe2['isAttached']()||_0x566911['isAttached']()?(_0x361e90['insertions'][_0x488859]=F(_0x34fbe2),_0x361e90['deletions'][_0x488859]=F(_0x566911),this['_copyMarkers'](_0x361e90['deletions'][_0x488859],_0x566911),this['_copyMarkers'](_0x361e90['insertions'][_0x488859],_0x34fbe2),_0x26cf03['insertions'][_0x488859]=this['_generateTape'](this['_idsRoots']['get'](_0x488859),[]),_0x26cf03['deletions'][_0x488859]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x488859)||B(_0x488859,!0x1),[])):_0x38fe81['delete'](_0x488859);}for(const _0x1dcbf2 of _0x38fe81){const _0x187fdb=_0x26cf03['insertions'][_0x1dcbf2];for(const _0x573e40 of _0x187fdb){const _0x2090e7=this['_getVidAttributeName'](_0x573e40),_0x30b453=_0x573e40['item']['getAttribute'](_0x2090e7);_0x5b3a1c['delete'](_0x30b453),_0x30b453>=this['_startingRevisionId']&&_0x2baad2['set'](_0x30b453,_0x5e3d1e['get'](_0x30b453));}}for(const _0x1cad03 of _0x38fe81){const _0x109c69=_0x26cf03['insertions'][_0x1cad03],_0x193c29=this['_getBaseVids'](_0x26cf03['deletions'][_0x1cad03]);let _0x43ad5a=0x0;for(const _0x1614d7 of _0x109c69){const _0x262247=this['_getVidAttributeName'](_0x1614d7),_0x14d977=_0x1614d7['item']['getAttribute'](_0x262247);if(!_0x2baad2['has'](_0x14d977)&&!_0x5a3153['has'](_0x14d977)){if(_0x5b3a1c['has'](_0x14d977))_0x43ad5a++;else{if(_0x14d977!=_0x193c29[_0x43ad5a]){const _0xf396c6=_0x5e3d1e['get'](_0x14d977)||_0x5e3d1e['get'](_0x193c29[_0x43ad5a]);for(;_0x14d977!=_0x193c29[_0x43ad5a];)_0x5b3a1c['has'](_0x193c29[_0x43ad5a])||(_0x5a3153['set'](_0x193c29[_0x43ad5a],_0xf396c6),_0x5e3d1e['set'](_0x193c29[_0x43ad5a],_0xf396c6)),_0x43ad5a++;}_0x43ad5a++;}}}}for(const _0x4e4dab of _0x38fe81){const _0x1bcc91=_0x26cf03['insertions'][_0x4e4dab];for(const _0x50f89a of _0x1bcc91){const _0x39de11=this['_getVidAttributeName'](_0x50f89a),_0x1fc2df=_0x50f89a['item']['getAttribute'](_0x39de11);if(_0x5a3153['has'](_0x1fc2df)){const _0x20e5b7=_0x5a3153['get'](_0x1fc2df);_0x5b3a1c['has'](_0x1fc2df)||_0x5b3a1c['set'](_0x1fc2df,{..._0x20e5b7}),_0x2baad2['set'](_0x1fc2df,{..._0x20e5b7});}}}for(const _0x39404e of _0x5b3a1c['keys']())_0x39404e>=this['_startingRevisionId']&&_0x5b3a1c['delete'](_0x39404e);const _0x27d029=new Map();for(const _0x40459b of _0x38fe81){let _0x3ecaed=_0x26cf03['insertions'][_0x40459b];for(const _0x1325f0 of _0x3ecaed)if(_0x1325f0['item']['is']('element','tableCell')){const _0x4e1d79=this['_getVidAttributeName'](_0x1325f0),_0x101f63=_0x1325f0['item']['getAttribute'](_0x4e1d79);if(_0x2baad2['has'](_0x101f63)){const _0x2bb805=_0x1325f0['item']['parent']['parent']['getAttribute']('vid_start'),_0x44aa1a=_0x27d029['get'](_0x2bb805)||new Set();_0x44aa1a['add'](_0x2baad2['get'](_0x101f63)['userId']),_0x27d029['set'](_0x2bb805,_0x44aa1a);}}_0x3ecaed=_0x26cf03['deletions'][_0x40459b];for(const _0x4e0d0e of _0x3ecaed)if(_0x4e0d0e['item']['is']('element','tableCell')){const _0x432805=this['_getVidAttributeName'](_0x4e0d0e),_0xbfe5a=_0x4e0d0e['item']['getAttribute'](_0x432805);if(_0x5b3a1c['has'](_0xbfe5a)){const _0x46a0d8=_0x4e0d0e['item']['parent']['parent']['getAttribute']('vid_start'),_0x2559d8=_0x27d029['get'](_0x46a0d8)||new Set();_0x2559d8['add'](_0x5b3a1c['get'](_0xbfe5a)['userId']),_0x27d029['set'](_0x46a0d8,_0x2559d8);}}for(const _0xe4cdeb of _0x27d029['keys']())(_0x2baad2['has'](_0xe4cdeb)||_0x5b3a1c['has'](_0xe4cdeb))&&_0x27d029['delete'](_0xe4cdeb);}for(const _0x4119b7 of _0x38fe81){const _0x2fb93a=_0x26cf03['insertions'][_0x4119b7];let _0x30314d=null,_0x3d2c96=null;for(const _0xe32df5 of _0x2fb93a){const _0x2e931a=this['_getVidAttributeName'](_0xe32df5),_0xace276=_0xe32df5['item']['getAttribute'](_0x2e931a),_0x12cd29=_0x27d029['get'](_0xace276);_0x12cd29&&'elementStart'==_0xe32df5['type']&&(_0x30314d=Array['from'](_0x12cd29)[0x0],_0x3d2c96=_0xe32df5['item']['getAttribute']('vid_end')),_0x30314d&&(_0x5b3a1c['set'](_0xace276,{'userId':_0x30314d}),_0x2baad2['set'](_0xace276,{'userId':_0x30314d})),_0xace276==_0x3d2c96&&(_0x30314d=null,_0x3d2c96=null);}}const _0xc3fbe9={},_0x32ed62=new Set();for(const _0x422ad5 of _0x38fe81){const _0x551607=_0x361e90['deletions'][_0x422ad5],_0x16a072=_0x361e90['insertions'][_0x422ad5];for(const {userId:_0x43f9bd}of this['_touchedMarkers']['values']())null!==_0x43f9bd&&_0x32ed62['add'](_0x43f9bd);for(const {userId:_0x3d2e8c}of this['_touchedRoots']['values']())null!==_0x3d2e8c&&_0x32ed62['add'](_0x3d2e8c);this['_markChanges'](_0x16a072,_0x26cf03['insertions'][_0x422ad5],_0x2baad2,'insertion',_0x32ed62),this['_markChanges'](_0x551607,_0x26cf03['deletions'][_0x422ad5],_0x5b3a1c,'deletion',_0x32ed62),_0xc3fbe9[_0x422ad5]={'insertions':this['_prepareViewToSave'](_0x16a072),'deletions':this['_prepareViewToSave'](_0x551607),'attachChange':this['_touchedRoots']['get'](_0x422ad5)||null,'attributesBefore':_0x1ea11a(this['_baseRootsAttributes']['get'](_0x422ad5))||{},'attributesAfter':_0x1ea11a(this['_diffRootsAttributes']['get'](_0x422ad5))};}return{'diffData':_0xc3fbe9,'authorsIds':Array['from'](_0x32ed62)};}['_processRootBeforeSave'](_0x5058c7){for(const [,_0x1f00f1]of _0x5058c7['markers']){const _0x2e1d37=_0x1f00f1['start']['getAncestors']()['filter'](_0x4f4c57=>'tableCell'==_0x4f4c57['name']);for(const _0xd74906 of _0x2e1d37)0x1==_0xd74906['childCount']&&_0xd74906['getChild'](0x0)['is']('element','paragraph')&&_0xd74906['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x5c524c){this['_processRootBeforeSave'](_0x5c524c);const _0x3edf3f=this['editor']['data']['toView'](_0x5c524c,{}),_0x2bc02f=Array['from'](_0x3edf3f['getChildren']())['map'](_0x26439b=>this['_getViewJson'](_0x26439b));return JSON['stringify'](_0x2bc02f);}['_getViewJson'](_0x41edaf){if(_0x41edaf['is']('$text'))return _0x41edaf['data'];{const _0x59dd43=_0x41edaf;return{'type':Object['keys'](C)['find'](_0x4d01b3=>_0x41edaf instanceof C[_0x4d01b3]),'name':_0x59dd43['name'],'attributes':Array['from'](_0x59dd43['getAttributes']()),'children':Array['from'](_0x59dd43['getChildren']())['map'](_0x5a1a98=>this['_getViewJson'](_0x5a1a98))};}}['_markChanges'](_0x392bc3,_0x19becc,_0x5726af,_0x400ac8,_0x5d40e8){let _0x455b8e=null,_0x42f56b=null,_0x557276=0x0;const _0x4a427d=this['editor']['model'];for(let _0x31bec0=0x0;_0x31bec0<_0x19becc['length'];_0x31bec0++){const _0x57d129=this['_getVidAttributeName'](_0x19becc[_0x31bec0]),_0x3a016a=_0x19becc[_0x31bec0]['item']['getAttribute'](_0x57d129),_0x4a9a45=_0x5726af['get'](_0x3a016a),_0x45999f=_0x31bec0==_0x19becc['length']-0x1;(!_0x455b8e&&_0x4a9a45&&(_0x455b8e=_0x4a9a45,_0x42f56b=_0x19becc[_0x31bec0]),_0x455b8e&&(!_0x4a9a45||_0x4a9a45['userId']!=_0x455b8e['userId']))&&(_0x491a6d(_0x4a9a45,J(_0x42f56b,_0x392bc3,_0x4a427d),J(_0x19becc[_0x31bec0],_0x392bc3,_0x4a427d)),_0x455b8e=_0x4a9a45||null,_0x42f56b=_0x4a9a45?_0x19becc[_0x31bec0]:null),_0x455b8e&&_0x45999f&&_0x491a6d(_0x4a9a45,J(_0x42f56b,_0x392bc3,_0x4a427d),q(_0x19becc[_0x31bec0],_0x392bc3,_0x4a427d));}function _0x491a6d(_0x5eadda,_0x215822,_0x556fc3){const _0x456cab=_0x455b8e['userId'],_0x4d9d4a='revision:'+_0x400ac8+':'+_0x456cab+':'+_0x557276++,_0x206c3b=_0x4a427d['createRange'](_0x215822,_0x556fc3);_0x392bc3['markers']['set'](_0x4d9d4a,_0x206c3b),null!==_0x456cab&&_0x5d40e8['add'](_0x456cab);}}['_getVidAttributeName'](_0x38a7e5){switch(_0x38a7e5['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x79ef66,_0x40baa1){_0x79ef66['baseVersion']=null;for(const _0x57e98b in _0x79ef66){const _0x9b709b=_0x79ef66[_0x57e98b];if(_0x9b709b instanceof gt){const _0x17b22e=_0x40baa1['get'](_0x9b709b['root']['rootName']);_0x79ef66[_0x57e98b]=this['_fixPosition'](_0x9b709b,_0x17b22e);}if(_0x9b709b instanceof vt){const _0x5f2612=_0x40baa1['get'](_0x9b709b['root']['rootName']);_0x79ef66[_0x57e98b]=this['_fixRange'](_0x9b709b,_0x5f2612);}'root'===_0x57e98b&&(_0x79ef66['root']=_0x40baa1['get'](_0x79ef66['root']['rootName']));}}['_fixRange'](_0x44861d,_0x2f2f11){return this['editor']['model']['createRange'](this['_fixPosition'](_0x44861d['start'],_0x2f2f11),this['_fixPosition'](_0x44861d['end'],_0x2f2f11));}['_fixPosition'](_0x52933e,_0x5b0293){return this['editor']['model']['createPositionFromPath'](_0x5b0293,_0x52933e['path'],_0x52933e['stickiness']);}['_handleInsertOperation'](_0x3debaa){const _0xee480f=this['_idsRoots']['get'](_0x3debaa['position']['root']['rootName']),_0x532801=this['_fixPosition'](_0x3debaa['position'],_0xee480f),_0x234014=null===_0x3debaa['_authorId']?null:_0x3debaa['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0xf08828=_0x532801['parent'],_0x147396=this['_revisionId'],_0x2972fe=[];for(const _0x1919a7 of _0x3debaa['nodes'])if(_0x1919a7['is']('element'))_0x2972fe['push'](this['_makeIdsRoot'](_0x1919a7));else{for(let _0x3f8894=0x0;_0x3f8894<_0x1919a7['offsetSize'];_0x3f8894++)_0x2972fe['push'](new ft('$text',{'vid':this['_revisionId']++}));}const _0x1451e6=this['_revisionId'];for(let _0x32be75=_0x147396;_0x32be75<_0x1451e6;_0x32be75++)this['_touched']['set'](_0x32be75,{'userId':_0x234014});_0xf08828['_insertChild'](_0x532801['offset'],_0x2972fe);}['_handleMoveOperation'](_0x599c2f){(_0x599c2f=this['_cloneOperation'](_0x599c2f,this['_idsRoots']))['_execute']();const _0x5f28bf=null===_0x599c2f['_authorId']?null:_0x599c2f['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x28558=_0x599c2f['getMovedRangeStart'](),_0x3e3924=_0x28558['parent'],_0x210b37=_0x28558['offset'];!function _0x2441c4(_0x184ec6,_0x1b2603,_0x4aa027,_0x1851b9){for(let _0x1975a6=_0x4aa027;_0x1975a6<_0x1851b9;_0x1975a6++){const _0x159899=_0x1b2603['getChild'](_0x1975a6);_0x159899['is']('element','$text')?_0x184ec6['set'](_0x159899['getAttribute']('vid'),{'userId':_0x5f28bf}):(_0x184ec6['set'](_0x159899['getAttribute']('vid_start'),{'userId':_0x5f28bf}),_0x2441c4(_0x184ec6,_0x159899,0x0,_0x159899['childCount']),_0x184ec6['set'](_0x159899['getAttribute']('vid_end'),{'userId':_0x5f28bf}));}}(this['_touched'],_0x3e3924,_0x210b37,_0x210b37+_0x599c2f['howMany']);}['_handleMergeOperation'](_0x59e136){const _0x109c3b=null===(_0x59e136=this['_cloneOperation'](_0x59e136,this['_idsRoots']))['_authorId']?null:_0x59e136['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x16348a=_0x59e136['targetPosition']['parent'],_0x4005f1=_0x59e136['sourcePosition']['parent'],_0x1457a4=_0x16348a['getAttribute']('vid_end'),_0x2276c9=_0x4005f1['getAttribute']('vid_start');_0x16348a['_setAttribute']('vid_end',_0x4005f1['getAttribute']('vid_end')),_0x4005f1['_setAttribute']('vid_end',_0x1457a4),this['_touched']['set'](_0x2276c9,{'userId':_0x109c3b}),this['_touched']['set'](_0x1457a4,{'userId':_0x109c3b}),_0x59e136['_execute']();}['_handleSplitOperation'](_0x7275e4){const _0x55ff27=null===(_0x7275e4=this['_cloneOperation'](_0x7275e4,this['_idsRoots']))['_authorId']?null:_0x7275e4['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x27d8de=_0x7275e4['graveyardPosition'],_0x2c9d2b=_0x7275e4['splitPosition']['parent'];_0x7275e4['_execute']();const _0x16e7f1=_0x2c9d2b['getAttribute']('vid_end'),_0x1efcfe=_0x7275e4['insertionPosition']['nodeAfter'];if(_0x27d8de){const _0x483527=_0x1efcfe['getAttribute']('vid_end'),_0x4b7f2a=_0x2c9d2b['getAttribute']('vid_end');_0x2c9d2b['_setAttribute']('vid_end',_0x483527),_0x1efcfe['_setAttribute']('vid_end',_0x4b7f2a),this['_touched']['set'](_0x2c9d2b['getAttribute']('vid_end'),{'userId':_0x55ff27}),this['_touched']['set'](_0x1efcfe['getAttribute']('vid_start'),{'userId':_0x55ff27});}else{const _0x447d25=this['_revisionId']++,_0x51d0e6=this['_revisionId']++;_0x2c9d2b['_setAttribute']('vid_end',_0x447d25),_0x1efcfe['_setAttribute']('vid_start',_0x51d0e6),_0x1efcfe['_setAttribute']('vid_end',_0x16e7f1),this['_touched']['set'](_0x447d25,{'userId':_0x55ff27}),this['_touched']['set'](_0x51d0e6,{'userId':_0x55ff27});}}['_handleMarkerOperation'](_0x543e7a){if(!_0x543e7a['affectsData'])return;const _0x45057b=(_0x543e7a=this['_cloneOperation'](_0x543e7a,this['_diffRoots']))['oldRange']?_0x543e7a['oldRange']['root']:null,_0xf1fc4b=_0x543e7a['newRange']?_0x543e7a['newRange']['root']:null;_0x45057b&&this['_markers']['delete'](_0x543e7a['name']),_0xf1fc4b&&this['_markers']['set'](_0x543e7a['name'],_0x543e7a['newRange']['clone']());const _0x2e11a0=null===_0x543e7a['_authorId']?null:_0x543e7a['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x5dc276=_0x543e7a['name'];if(!this['_touchedMarkers']['has'](_0x5dc276))return void this['_touchedMarkers']['set'](_0x5dc276,{'range':_0x543e7a['oldRange'],'userId':_0x2e11a0});const _0x39d0ad=this['_touchedMarkers']['get'](_0x5dc276),_0x20b91d=_0x39d0ad['range'],_0x245ca3=_0x543e7a['newRange'];null==_0x20b91d&&null==_0x245ca3||_0x20b91d&&_0x245ca3&&_0x20b91d['isEqual'](_0x245ca3)?this['_touchedMarkers']['delete'](_0x543e7a['name']):_0x39d0ad['userId']=_0x2e11a0;}['_handleRootOperation'](_0x41add0,_0x396d3b){this['_diffRoots']['has'](_0x41add0['rootName'])?this['_diffRoots']['get'](_0x41add0['rootName'])['_isAttached']=_0x41add0['isAdd']:(this['_diffRoots']['set'](_0x41add0['rootName'],B(_0x41add0['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x41add0['rootName'],{}),_0x396d3b&&this['_idsRoots']['set'](_0x41add0['rootName'],B(_0x41add0['rootName'],!0x0)));const _0x36c5f7=null===_0x41add0['_authorId']?null:_0x41add0['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x1c7055=this['_touchedRoots']['get'](_0x41add0['rootName']);_0x1c7055&&_0x1c7055['userId']===_0x36c5f7?this['_touchedRoots']['delete'](_0x41add0['rootName']):this['_touchedRoots']['set'](_0x41add0['rootName'],{'userId':_0x36c5f7,'isAttached':_0x41add0['isAdd']});}['_handleRootAttributeOperation'](_0x2c8158){const _0xdf499c=this['_diffRootsAttributes']['get'](_0x2c8158['root']['rootName']);null===_0x2c8158['newValue']?delete _0xdf499c[_0x2c8158['key']]:_0xdf499c[_0x2c8158['key']]=_0x2c8158['newValue'];}}function F(_0x2b555e){const _0x51f5ab=B(_0x2b555e['rootName'],_0x2b555e['isAttached']());for(const _0x29f2ed of _0x2b555e['getChildren']()){const _0x4e56a2=_0x29f2ed['_clone'](!0x0);_0x51f5ab['_appendChild'](_0x4e56a2);}return _0x51f5ab;}function B(_0x568f0a,_0x29bada=!0x0){const _0x524892=new wt();return _0x524892['rootName']=_0x568f0a,_0x524892['_isAttached']=_0x29bada,_0x524892['isAttached']=()=>_0x524892['_isAttached'],_0x524892;}function J(_0x3801e4,_0xbeca1d,_0x4287cc){const _0x42af70='elementEnd'==_0x3801e4['type']?_0x4287cc['createPositionAt'](_0x3801e4['item'],'end'):_0x4287cc['createPositionBefore'](_0x3801e4['item']);return _0x4287cc['createPositionFromPath'](_0xbeca1d,_0x42af70['path'],_0x42af70['stickiness']);}function q(_0x48bbc5,_0x500b24,_0x463853){const _0x400796='elementStart'==_0x48bbc5['type']?_0x463853['createPositionAt'](_0x48bbc5['item'],0x0):_0x463853['createPositionAfter'](_0x48bbc5['item']);return _0x463853['createPositionFromPath'](_0x500b24,_0x400796['path'],_0x400796['stickiness']);}class ns extends _0x225181{['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x5c4ebd,_0x1922fa){super(_0x5c4ebd),this['focusTracker']=new _0xe61897(),this['keystrokes']=new _0x5cf09a(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x1922fa),this['setTemplate']({'tag':'form','attributes':{'class':['ck','ck-revision-history-save-revision-form','ck-responsive-form'],'tabindex':'-1'},'children':[this['revisionNameInputView']]}),ts(this);}['render'](){super['render'](),_0x7d4f2a({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x5748a3=_0x3af286=>_0x3af286['stopPropagation']();this['keystrokes']['set']('arrowright',_0x5748a3),this['keystrokes']['set']('arrowleft',_0x5748a3),this['keystrokes']['set']('arrowup',_0x5748a3),this['keystrokes']['set']('arrowdown',_0x5748a3);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x2915ae){this['revisionNameInputView']['fieldView']['element']['value']=_0x2915ae['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x417067){const _0x29805d=new at(this['locale'],_0x37cab7),_0x36a2d3=_0x29805d['fieldView'];_0x36a2d3['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x4bca6f=R(this['locale'],'Name\x20of\x20the\x20revision');return!_0x417067&&(_0x4bca6f+='\x20('+R(this['locale'],'optional')+')'),(_0x29805d['label']=_0x4bca6f,_0x36a2d3['on']('input',()=>{this['revisionNameInputValue']=_0x36a2d3['element']['value']['trim']();}),_0x29805d);}}class u extends _0x49970d{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l];}['_saveRevisionFormView'];['init'](){const _0x2f1e75=this['editor'],_0x969d48=_0x2f1e75['plugins']['get']('RevisionTracker');_0x2f1e75['ui']['componentFactory']['add']('revisionHistory',_0x511750=>{const _0x43d47c=_0xd76513(_0x511750),_0x58f51e=_0x43d47c['panelView']['children'],_0x514c7c=new te(_0x511750),_0x5f5cea=new _0x1bdf1e(_0x511750),_0x26ee62=new _0x4f59ce(_0x511750),_0x2f3cf7=new _0x1bdf1e(_0x511750),_0x131ed9=new _0x4f59ce(_0x511750);return _0x43d47c['bind']('isEnabled')['to'](_0x969d48,'isReady',_0x969d48,'isEnabled',_0x2f1e75,'isReadOnly',(_0x4d208d,_0x96dbcb,_0x4c358b)=>_0x4d208d&&_0x96dbcb&&!_0x4c358b),_0x43d47c['buttonView']['set']({'icon':_0x429f7b['history'],'label':R(_0x511750,'Revision\x20history'),'tooltip':!0x0}),_0x26ee62['set']({'label':R(_0x511750,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x26ee62['bind']('isEnabled')['to'](_0x969d48,'isReady',_0x969d48,'isEnabled',_0x2f1e75,'isReadOnly',(_0x32ca84,_0x588757,_0x66a5b2)=>_0x32ca84&&_0x588757&&!_0x66a5b2),_0x26ee62['on']('execute',()=>this['_showDialog']()),_0x131ed9['set']({'label':R(_0x511750,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x131ed9['bind']('isEnabled')['to'](_0x969d48,'isReady',_0x2f1e75,'isReadOnly',(_0x815f97,_0x2720dc)=>_0x815f97&&!_0x2720dc),_0x131ed9['on']('execute',()=>{_0x2f1e75['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x43d47c['isOpen']=!0x1,_0x2f1e75['editing']['view']['focus']();}),_0x5f5cea['children']['add'](_0x26ee62),_0x2f3cf7['children']['add'](_0x131ed9),_0x514c7c['role']='menu',_0x514c7c['items']['addMany']([_0x5f5cea,_0x2f3cf7]),_0x58f51e['add'](_0x514c7c),_0x43d47c;}),_0x2f1e75['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x44bfd4=this['editor'],_0x32111d=_0x44bfd4['locale'],_0x5c4fa7=new _0x353dc1(_0x32111d),_0x514043=new _0x545793(_0x32111d);_0x5c4fa7['buttonView']['set']({'icon':_0x429f7b['history'],'label':R(_0x32111d,'Revision\x20history')});const _0x333a90=new _0x3ec8b1(_0x32111d,_0x5c4fa7),_0x41c38a=new _0x554448(_0x32111d);_0x41c38a['set']({'label':R(_0x32111d,'Save\x20current\x20revision')}),_0x41c38a['delegate']('execute')['to'](_0x5c4fa7),_0x41c38a['on']('execute',()=>{this['_showDialog']();}),_0x333a90['children']['add'](_0x41c38a),_0x514043['items']['add'](_0x333a90);const _0x122c39=new _0x3ec8b1(_0x32111d,_0x5c4fa7),_0x3bb9d7=new _0x554448(_0x32111d);return _0x3bb9d7['set']({'label':R(_0x32111d,'Open\x20revision\x20history')}),_0x3bb9d7['delegate']('execute')['to'](_0x5c4fa7),_0x3bb9d7['on']('execute',()=>{_0x44bfd4['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x122c39['children']['add'](_0x3bb9d7),_0x514043['items']['add'](_0x122c39),_0x5c4fa7['panelView']['children']['add'](_0x514043),_0x5c4fa7;}['_showDialog'](){const _0x3f4b6b=this['editor'],_0x9707a1=_0x3f4b6b['locale'],_0x1e88f4=_0x3f4b6b['plugins']['get']('Dialog'),_0x371b1e=_0x3f4b6b['plugins']['get']('RevisionTracker');function _0x4d75b9(_0x1833d6){_0x3f4b6b['config']['get']('revisionHistory.requireRevisionName')&&''===_0x1833d6['revisionName']?_0x1833d6['revisionNameInputView']['errorText']=R(_0x9707a1,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x3f4b6b['plugins']['get'](l)['saveRevision']({'name':_0x1833d6['revisionName']}),_0x1e88f4['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x4d75b9(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x1e88f4['show']({'id':'revisionSave','title':R(_0x9707a1,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':R(_0x3f4b6b['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x1e88f4['hide']()},{'label':R(_0x3f4b6b['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0xb6ca1c){_0xb6ca1c['bind']('isEnabled')['to'](_0x371b1e,'isReady',_0x371b1e,'isEnabled',_0x3f4b6b,'isReadOnly',(_0x3b9850,_0x25b3c3,_0x6aeb53)=>_0x3b9850&&_0x25b3c3&&!_0x6aeb53);},'onExecute':()=>_0x4d75b9(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x77090b=this['editor'],_0x292d0d=_0x77090b['locale'];this['_saveRevisionFormView']=new ns(_0x292d0d,_0x77090b['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class Y extends _0x225181{['changeId'];['_model'];constructor(_0x2587ae,_0x62adc5){super(_0x2587ae),this['_model']=_0x62adc5,this['changeId']=_0x62adc5['id'];const _0x3874fe=this['bindTemplate'],_0x4aea94=R(_0x2587ae,_0x62adc5['data']['isSuggestion']?'Suggested\x20by':'add'==_0x62adc5['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x62adc5['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x3874fe['to']('type',_0x2e2ede=>'ck-revision-change__'+_0x2e2ede)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x4aea94}]},{'text':'\x20'+_0x62adc5['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class r extends/* #__PURE__ -- @preserve */
|
|
25
|
-
_0x5a7f9d(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x429992){super(),this['id']=_0x429992['id']||_0x4f9a89(),this['author']=_0x429992['author'],this['type']=_0x429992['type'],this['data']=_0x429992['data']||{},this['rootName']=_0x429992['rootName'],this['set']('createdAt',_0x429992['createdAt']);}['toJSON'](){return{'id':this['id'],'authorId':this['author']['id'],'type':this['type'],'data':this['data'],'createdAt':this['createdAt']};}}class f{['newRevisionId'];['oldRevisionId'];['changes'];constructor(_0x2ed4c1,_0x4d20f1){this['newRevisionId']=_0x2ed4c1,this['oldRevisionId']=_0x4d20f1,this['changes']=new _0x2745a9();}['_setChanges'](_0x1c816e){for(const _0x31a6f6 of _0x1c816e)this['changes']['add'](_0x31a6f6);}}const Z={'c':_0x11e705,'a':_0x25db7e,'e':_0x10f6d4,'r':_0x5d57f5,'u':_0x5bea37};class d extends _0x49970d{['repository'];['adapter'];['_activeViewTarget'];['_changeView'];['_changeIdToChange'];['_balloon'];static get['pluginName'](){return'RevisionViewer';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[_0x122c7d,_0x1424e1,j];}constructor(_0x1d7001){super(_0x1d7001),this['repository']=this['editor']['plugins']['get']('RevisionsRepository'),this['set']('activeChange',null),this['set']('activeView',null),this['_activeViewTarget']=null,this['set']('diff',null),this['set']('isReady',!0x1),this['set']('isEnabled',!0x0),this['on']('change:isEnabled',(_0x1b0ec5,_0x17619a,_0x56bdb7)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x26429e=>{for(const _0x1e01ef of this['editor']['editing']['view']['document']['roots'])_0x56bdb7?_0x26429e['removeClass']('ck-editor__editable__overlay',_0x1e01ef):_0x26429e['addClass']('ck-editor__editable__overlay',_0x1e01ef);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x391dab=>null!==_0x391dab),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x320b2b,_0xd45e7,_0x5b8f62)=>_0x320b2b&&_0x5b8f62?_0xd45e7['changes']['getIndex'](_0x5b8f62):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x90d6ff,_0x1c4346)=>_0x90d6ff?_0x1c4346['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['adapter']=null,this['_balloon']=this['editor']['plugins']['get'](_0x1424e1);}['init'](){const _0x1aada8=this['editor'],_0x115b22=new bt(_0x1aada8,{'direction':'backward'}),_0x2cdc0f=new bt(_0x1aada8,{'direction':'forward'});(_0x1aada8['commands']['add']('showPreviousChange',_0x115b22),_0x1aada8['commands']['add']('showNextChange',_0x2cdc0f),_0x1aada8['commands']['add']('restoreRevision',new yt(_0x1aada8)),this['on']('change:numberOfChanges',()=>{_0x115b22['refresh'](),_0x2cdc0f['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x1aada8['enableReadOnlyMode']('revision-viewer'),_0x1aada8['plugins']['has']('WidgetToolbarRepository'))&&_0x1aada8['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionData'](_0xfae876){await this['loadRevisionData'](_0xfae876);const _0x1ba1c1={};for(const _0x35484e in _0xfae876['diffData']){if(_0xfae876['diffData'][_0x35484e]['attachChange']&&!_0xfae876['diffData'][_0x35484e]['attachChange']['isAttached'])continue;const _0x3fb135=this['_removeRevisionMarkers'](JSON['parse'](_0xfae876['diffData'][_0x35484e]['insertions'])),_0x2ca721=this['editor']['editing']['view']['document'],_0x369951=new _0x59148e(_0x2ca721,_0x3fb135['map'](_0x3eb38b=>this['_getViewObj'](_0x3eb38b)));this['editor']['data']['processor']['useFillerType']('marked'),_0x1ba1c1[_0x35484e]=this['editor']['data']['processor']['toData'](_0x369951),this['editor']['data']['processor']['useFillerType']('default');}return _0x1ba1c1;}async['getRevisionRootsAttributes'](_0x157560){await this['loadRevisionData'](_0x157560);const _0x15ac43={};for(const _0x49fc79 in _0x157560['diffData'])_0x157560['diffData'][_0x49fc79]['attachChange']&&!_0x157560['diffData'][_0x49fc79]['attachChange']['isAttached']||(_0x15ac43[_0x49fc79]=_0x157560['diffData'][_0x49fc79]['attributesAfter']||{});return _0x15ac43;}['_removeRevisionMarkers'](_0x4729a4){return(_0x4729a4=_0x4729a4['filter'](_0x160a60=>!_0x160a60['name']||'revision-start'!==_0x160a60['name']&&'revision-end'!==_0x160a60['name']))['forEach'](_0x142d33=>{'string'!=typeof _0x142d33&&(_0x142d33['children']=this['_removeRevisionMarkers'](_0x142d33['children']),_0x142d33['attributes']=_0x142d33['attributes']['filter'](_0x55ea99=>!_0x55ea99[0x0]['startsWith']('data-revision-')));}),_0x4729a4;}async['compare'](_0x1b1f4a,_0x132c8a,_0x5044f5=!0x1){if(!this['isEnabled'])return;const _0x4de282=this['diff'],_0x5b725b=this['repository'],_0x235569='string'==typeof _0x1b1f4a?_0x5b725b['getRevision'](_0x1b1f4a):_0x1b1f4a,_0x1bacd7='string'==typeof _0x132c8a?_0x5b725b['getRevision'](_0x132c8a):_0x132c8a,_0x3db792=_0x235569['id'],_0x14e5d9=_0x1bacd7?_0x1bacd7['id']:null;if(!_0x5044f5&&this['diff']&&this['diff']['newRevisionId']===_0x3db792&&this['diff']['oldRevisionId']===_0x14e5d9)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new f(_0x3db792,_0x14e5d9);const _0x70ce92=this['_getRevisionsRange'](_0x235569,_0x1bacd7,!0x0)['map'](_0x2c02b5=>this['loadRevisionData'](_0x2c02b5));return _0x70ce92['push'](new Promise(_0x1f6e86=>{setTimeout(_0x1f6e86,0x14);})),Promise['all'](_0x70ce92)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x522947=this['_getDiff'](_0x3db792,_0x14e5d9);for(const _0x197936 of _0x522947['changes'])this['_changeIdToChange']['set'](_0x197936['id'],_0x197936);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x51f053=>{for(const _0x30b074 of this['editor']['model']['document']['getRootNames']())_0x51f053['detachRoot'](_0x30b074);for(const _0x1a668b of Object['keys'](_0x522947['model'])){const _0x1ef2db=_0x51f053['addRoot'](_0x1a668b);for(const _0x396f19 of Object['keys'](_0x522947['attributes'][_0x1a668b]))_0x51f053['setAttribute'](_0x396f19,_0x522947['attributes'][_0x1a668b][_0x396f19],_0x1ef2db);_0x51f053['insert'](_0x522947['model'][_0x1a668b],_0x1ef2db,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x522947['changes'])),this['isReady']=!0x0;})['catch'](_0x5a6c1b=>{console['error'](_0x5a6c1b),this['_cleanUp'](),_0x4de282&&(this['diff']=_0x4de282),this['isReady']=!0x0;});}['addRevisionData'](_0x10250a,_0x5bf29a){const _0x4c538b=this['repository']['createRevision'](_0x10250a);return _0x4c538b['on']('_update',(_0x54dd6a,_0x5ebd53,_0xe39a0c)=>_0x5bf29a(_0x5ebd53,_0xe39a0c,_0x4c538b)),this['repository']['addRevision'](_0x4c538b),_0x4c538b;}['loadRevisionData'](_0x1a1b4b){if(!_0x1a1b4b||_0x1a1b4b['diffData'])return Promise['resolve']();{const _0x2be3b7=this['editor']['config']['get']('collaboration.channelId');return this['adapter']['getRevision']({'channelId':_0x2be3b7,'revisionId':_0x1a1b4b['id']})['then'](_0xdf2bca=>{_0x1a1b4b['_update']({'diffData':_0xdf2bca['diffData']},!0x0);});}}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x5eeb2e=>{for(const _0x3cd2f2 of this['editor']['model']['document']['getRootNames']())_0x5eeb2e['detachRoot'](_0x3cd2f2);});}['_sortAndFilterDiffChanges'](_0x3897c9){const _0x7cdd9f=[],_0xad7f03=new Map();for(const _0x52e8fc of this['editor']['model']['document']['getRootNames']()){const _0x37bf61=this['editor']['editing']['view']['getDomRoot'](_0x52e8fc);if(!_0x37bf61)continue;const _0x27859a=_0x37bf61['getClientRects']()['item'](0x0);_0x27859a&&(_0x7cdd9f['push'](_0x52e8fc),_0xad7f03['set'](_0x52e8fc,_0x27859a));}return _0x7cdd9f['sort']((_0x54cef3,_0x4e054f)=>{const _0x319017=_0xad7f03['get'](_0x54cef3),_0xa6dc01=_0xad7f03['get'](_0x4e054f);return _0x319017['y']-_0xa6dc01['y']||_0x319017['x']-_0xa6dc01['x'];}),(_0x3897c9=_0x3897c9['filter'](_0x1be132=>_0x7cdd9f['includes'](_0x1be132['rootName'])))['sort']((_0x345994,_0x381076)=>_0x7cdd9f['indexOf'](_0x345994['rootName'])-_0x7cdd9f['indexOf'](_0x381076['rootName'])),_0x3897c9;}['_makeTape'](_0x51e220){const _0x2bbf05=Array['from'](_0x51e220['markers'])['filter'](([_0x2b793f,_0x50489a])=>_0x2b793f['startsWith']('revision:')&&!_0x50489a['isCollapsed']),_0x76d55a=Array['from'](this['editor']['model']['createRangeIn'](_0x51e220)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x2bbf05['length'])for(const _0x57da17 of _0x76d55a){const [_0x1538fc,_0x4ec3cb]=_0x2bbf05[0x0],[,_0x3c4b59,_0x332597]=_0x1538fc['split'](':');if(_0x4ec3cb['end']['isEqual'](_0x57da17['nextPosition'])&&_0x2bbf05['shift'](),(_0x57da17['previousPosition']['isEqual'](_0x4ec3cb['start'])||_0x57da17['previousPosition']['isAfter'](_0x4ec3cb['start']))&&('insertion'==_0x3c4b59?_0x57da17['isAdded']={'userId':_0x332597}:'deletion'==_0x3c4b59&&(_0x57da17['isRemoved']={'userId':_0x332597})),0x0==_0x2bbf05['length'])break;}return _0x76d55a;}['_refreshStartEndIndex'](_0x15af8c){const _0x18491d=new Map();for(let _0x40b96a=0x0;_0x40b96a<_0x15af8c['length'];_0x40b96a++)'text'===_0x15af8c[_0x40b96a]['type']?(_0x15af8c[_0x40b96a]['item']['startIndex']=_0x40b96a,_0x15af8c[_0x40b96a]['item']['endIndex']=_0x40b96a):('elementStart'===_0x15af8c[_0x40b96a]['type']?_0x15af8c[_0x40b96a]['item']['startIndex']=_0x40b96a:'elementEnd'===_0x15af8c[_0x40b96a]['type']&&(_0x15af8c[_0x40b96a]['item']['endIndex']=_0x40b96a),_0x18491d['set'](_0x15af8c[_0x40b96a]['id'],_0x40b96a));for(const _0xdaf3cb of _0x18491d['values']())'elementStart'===_0x15af8c[_0xdaf3cb]['type']?_0x15af8c[_0xdaf3cb]['item']['endIndex']=_0x18491d['get'](_0x15af8c[_0xdaf3cb]['pairId']):'elementEnd'===_0x15af8c[_0xdaf3cb]['type']&&(_0x15af8c[_0xdaf3cb]['item']['startIndex']=_0x18491d['get'](_0x15af8c[_0xdaf3cb]['pairId']));}['_processTape'](_0x55fa22){for(let _0x63e158=0x0;_0x63e158<_0x55fa22['length'];_0x63e158++){if('elementStart'===_0x55fa22[_0x63e158]['type'])_0x55fa22[_0x63e158]['item']['startIndex']=_0x63e158;else{if('elementEnd'===_0x55fa22[_0x63e158]['type']){_0x55fa22[_0x63e158]['item']['endIndex']=_0x63e158;const _0x3a3569=_0x55fa22[_0x63e158]['item']['startIndex'];_0x55fa22[_0x3a3569]['pairId']=_0x55fa22[_0x63e158]['id'],_0x55fa22[_0x63e158]['pairId']=_0x55fa22[_0x3a3569]['id'];}else _0x55fa22[_0x63e158]['item']['startIndex']=_0x63e158,_0x55fa22[_0x63e158]['item']['endIndex']=_0x63e158,_0x55fa22[_0x63e158]['pairId']=null;}_0x55fa22[_0x63e158]['markersStart']||(_0x55fa22[_0x63e158]['markersStart']=[],_0x55fa22[_0x63e158]['markersEnd']=[]);}}['_markInsertions'](_0x1fb08d,_0x3f9e7e){const _0x4b1cbb=_0x1fb08d['filter'](_0x3fc4ed=>!_0x3fc4ed['isAdded']);for(let _0xcc0e01=0x0;_0xcc0e01<_0x3f9e7e['length'];_0xcc0e01++)_0x3f9e7e[_0xcc0e01]['isAdded']&&(_0x4b1cbb[_0xcc0e01]['isAdded']=_0x3f9e7e[_0xcc0e01]['isAdded']);}['_makeModelFromViewString'](_0x469e72){const _0x80c407=JSON['parse'](_0x469e72),_0x5cfc91=this['editor']['editing']['view']['document'],_0x597d1c=new _0x59148e(_0x5cfc91,_0x80c407['map'](_0x5b4b10=>this['_getViewObj'](_0x5b4b10)));return this['editor']['data']['toModel'](_0x597d1c);}['_getViewObj'](_0x3ac506){const _0x100770=this['editor']['editing']['view']['document'];if('string'==typeof _0x3ac506)return new _0x224f95(_0x100770,_0x3ac506);{const _0x4c0fc7=_0x3ac506['children']['map'](_0xbac64=>this['_getViewObj'](_0xbac64));return new(Z[_0x3ac506['type']]||_0x3dbac4)(_0x100770,_0x3ac506['name'],_0x3ac506['attributes'],_0x4c0fc7);}}['_getDiff'](_0x23fd66,_0x4dd0e7=null){const _0x175533=this['repository']['getRevision'](_0x23fd66),_0x6c299e=_0x4dd0e7?this['repository']['getRevision'](_0x4dd0e7):null,_0x5ed37c=this['_getRevisionsRange'](_0x175533,_0x6c299e),_0x4efd08=_0x5ed37c[_0x5ed37c['length']-0x1],_0x5b906a=new Map(),_0x10a9c0={'model':{},'attributes':{},'changes':[]},_0x347ded=new Set(),_0x4af0e2=new Map();for(let _0x42bd42=_0x5ed37c['length']-0x1;_0x42bd42>=0x0;_0x42bd42--){const _0xb3ce28=_0x5ed37c[_0x42bd42];for(const _0x5e7afe of Object['keys'](_0xb3ce28['diffData']))if(_0xb3ce28['diffData'][_0x5e7afe]['attachChange']){const _0x512988=_0xb3ce28['diffData'][_0x5e7afe]['attachChange'];_0x512988['isAttached']?(_0x347ded['add'](_0x5e7afe),_0x4af0e2['has'](_0x5e7afe)&&_0x4af0e2['get'](_0x5e7afe)['userId']==_0x512988['userId']?_0x4af0e2['delete'](_0x5e7afe):_0x4af0e2['set'](_0x5e7afe,_0x512988)):_0x4af0e2['has'](_0x5e7afe)?(_0x347ded['delete'](_0x5e7afe),_0x4af0e2['delete'](_0x5e7afe)):(_0x347ded['add'](_0x5e7afe),_0x4af0e2['set'](_0x5e7afe,_0x512988));}else _0x347ded['add'](_0x5e7afe);}for(const _0x11b99c of _0x347ded){const _0x47e430=_0x4af0e2['has'](_0x11b99c)&&!_0x4af0e2['get'](_0x11b99c)['isAttached'];let _0x4509b2=_0x47e430?_0x5ed37c['length']-0x1:0x0;const _0x267402=_0x47e430?-0x1:0x1;for(;_0x5ed37c[_0x4509b2];){const _0x42a816=_0x5ed37c[_0x4509b2];if(_0x42a816['diffData'][_0x11b99c]){const _0x50a361=_0x47e430?_0x42a816['diffData'][_0x11b99c]['attributesBefore']:_0x42a816['diffData'][_0x11b99c]['attributesAfter'];_0x10a9c0['attributes'][_0x11b99c]=_0x50a361?_0x1ea11a(_0x50a361):{};break;}_0x4509b2+=_0x267402;}}for(const _0x2b7c44 of _0x5ed37c){_0x2b7c44['model']={};for(const _0x36ff83 of _0x2b7c44['authors'])_0x5b906a['set'](_0x36ff83['id'],_0x36ff83);for(const _0x1e0c94 of _0x347ded){const _0x46d1b9=_0x2b7c44['diffData'][_0x1e0c94]?_0x2b7c44['diffData'][_0x1e0c94]['insertions']:'[]',_0x178be2=_0x2b7c44['diffData'][_0x1e0c94]?_0x2b7c44['diffData'][_0x1e0c94]['deletions']:'[]';_0x2b7c44['model'][_0x1e0c94]={'insertions':this['_makeModelFromViewString'](_0x46d1b9),'deletions':this['_makeModelFromViewString'](_0x178be2)};}}for(const _0x27ed92 of _0x347ded){let _0x24bc82=null,_0x4299e7=0x0;const _0x23e8c1=new Map(Array['from'](_0x175533['model'][_0x27ed92]['insertions']['markers'])['filter'](([_0x40df70])=>!_0x40df70['startsWith']('revision:')));let _0x4ec284=0x0;for(const _0x58e2ed of _0x5ed37c){const _0x401c89=this['_makeTape'](_0x58e2ed['model'][_0x27ed92]['insertions']);_0x58e2ed==_0x175533?(_0x24bc82=_0x401c89,_0x4299e7=_0x24bc82['length'],_0x24bc82['forEach'](_0x1b92aa=>{_0x1b92aa['id']=_0x4ec284++;}),this['_processTape'](_0x24bc82)):this['_markInsertions'](_0x24bc82,_0x401c89);const _0x3d89bf=_0x24bc82['filter'](_0x20627b=>!_0x20627b['isAdded'])['map'](_0x1f0db0=>_0x1f0db0['id']);let _0x31c7c1=0x0;const _0x37ac22=this['_makeTape'](_0x58e2ed['model'][_0x27ed92]['deletions']);_0x37ac22['forEach'](_0x38fd59=>{_0x38fd59['isRemoved']?_0x38fd59['id']=_0x4299e7++:_0x38fd59['id']=_0x3d89bf[_0x31c7c1++];}),this['_processTape'](_0x37ac22),this['_setDistance'](_0x24bc82,'isAdded'),this['_setDistance'](_0x37ac22,'isRemoved'),_0x58e2ed==_0x175533&&this['_markMarkers'](_0x24bc82,_0x23e8c1),_0x24bc82=this['_joinTapes'](_0x24bc82,_0x37ac22),this['_refreshStartEndIndex'](_0x24bc82),this['_setDistance'](_0x24bc82,'isRemoved');}_0x24bc82=_0x24bc82['filter'](_0xef2244=>!(_0xef2244['isAdded']&&_0xef2244['isRemoved']));const _0x247f9b=new Map(_0x4efd08['model'][_0x27ed92]['deletions']['markers']),_0x39f197=new Set(_0x23e8c1['keys']());for(const _0x491ca5 of _0x247f9b['keys']())_0x39f197['delete'](_0x491ca5);this['_markSuggestions'](_0x24bc82,_0x39f197),this['_fixObsoleteTags'](_0x24bc82),_0x24bc82=this['_removeMissingPairs'](_0x24bc82),_0x24bc82=this['_markMismatchedRemovedTags'](_0x24bc82),_0x24bc82=this['_removeUnsupportedChanges'](_0x24bc82);const {root:_0x117102,changes:_0x4966fd}=this['_makeModelFromTape'](_0x24bc82,_0x5b906a,_0x27ed92);_0x10a9c0['model'][_0x27ed92]=_0x117102;const _0x541815=_0x4af0e2['get'](_0x27ed92);if(_0x541815){const _0x1202fc=_0x5b906a['get'](_0x541815['userId']),_0x94f5c=new r({'author':_0x1202fc,'type':_0x541815['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x27ed92});_0x4966fd['unshift'](_0x94f5c),_0x10a9c0['attributes'][_0x27ed92]['revisionHistoryAttachChange']=_0x94f5c['id'];}_0x10a9c0['changes']=_0x10a9c0['changes']['concat'](_0x4966fd);}return _0x10a9c0;}['_markMarkers'](_0x13e148,_0x3a5593){for(let _0x41acd7=0x0;_0x41acd7<_0x13e148['length'];_0x41acd7++)for(const [_0x5d029e,_0x1d3713]of _0x3a5593)_0x1d3713['start']['isEqual'](_0x13e148[_0x41acd7]['previousPosition'])&&_0x13e148[_0x41acd7]['markersStart']['push'](_0x5d029e),_0x1d3713['end']['isEqual'](_0x13e148[_0x41acd7]['nextPosition'])&&_0x13e148[_0x41acd7]['markersEnd']['push'](_0x5d029e);}['_joinTapes'](_0x1cf205,_0x1e43d3){let _0x31057b=[],_0x2a00b9=0x0,_0x210d53=0x0;for(;_0x2a00b9<_0x1cf205['length']||_0x210d53<_0x1e43d3['length'];){const _0x4c1ccf=_0x1cf205[_0x2a00b9]||{},_0x1c28d6=_0x1e43d3[_0x210d53]||{};if(_0x4c1ccf['id']==_0x1c28d6['id'])_0x2a00b9++,_0x210d53++,_0x31057b['push'](_0x4c1ccf);else{if(_0x1c28d6['isRemoved']&&_0x4c1ccf['isAdded']){const {commonTape:_0x324ef9,iEnd:_0x1c4a36,jEnd:_0x472607}=this['_threeWayMerge'](_0x1cf205,_0x2a00b9,_0x1e43d3,_0x210d53);_0x31057b=_0x31057b['concat'](_0x324ef9),_0x2a00b9=_0x1c4a36,_0x210d53=_0x472607;}else _0x1c28d6['isRemoved']?(_0x210d53++,_0x31057b['push'](_0x1c28d6)):(_0x2a00b9++,_0x31057b['push'](_0x4c1ccf));}}return _0x31057b;}['_markSuggestions'](_0x389a5a,_0x2d56b5){const _0x37622b=[];for(let _0x217608=0x0;_0x217608<_0x389a5a['length'];_0x217608++){for(let _0x132456=0x0;_0x132456<_0x389a5a[_0x217608]['markersStart']['length'];_0x132456++){const _0x296075=_0x389a5a[_0x217608]['markersStart'][_0x132456];if(!_0x2d56b5['has'](_0x296075))continue;const {group:_0x506e4c,type:_0x51c229,authorId:_0x4577fe}=_0x482036(_0x296075);'revision-suggestion'!=_0x506e4c||'insertion'!=_0x51c229&&'deletion'!=_0x51c229||(_0x37622b['unshift']({'type':_0x51c229,'name':_0x296075,'userId':_0x4577fe}),_0x389a5a[_0x217608]['markersStart']['splice'](_0x132456,0x1),_0x132456--);}_0x49dec6(_0x389a5a[_0x217608]);for(let _0x1f7522=0x0;_0x1f7522<_0x389a5a[_0x217608]['markersEnd']['length'];_0x1f7522++){const _0x16242d=_0x389a5a[_0x217608]['markersEnd'][_0x1f7522];if(!_0x2d56b5['has'](_0x16242d))continue;const {group:_0x3235e1,type:_0x4efdae}=_0x482036(_0x16242d);if('revision-suggestion'!=_0x3235e1||'insertion'!=_0x4efdae&&'deletion'!=_0x4efdae)continue;_0x389a5a[_0x217608]['markersEnd']['splice'](_0x1f7522,0x1),_0x1f7522--;const _0x3616af=_0x37622b['findIndex'](_0x371707=>_0x371707['name']==_0x16242d);_0x3616af>-0x1&&_0x37622b['splice'](_0x3616af,0x1);}}function _0x482036(_0x4708ff){const _0x4653c3=_0x4708ff['split'](':');return{'group':_0x4653c3[0x0],'type':_0x4653c3[0x1],'subType':_0x4653c3['length']>=0x5?_0x4653c3[0x2]:null,'id':_0x4653c3['length']<0x5?_0x4653c3[0x2]:_0x4653c3[0x3],'authorId':_0x4653c3['length']<0x5?_0x4653c3[0x3]:_0x4653c3[0x4],'markerCount':0x6==_0x4653c3['length']?_0x4653c3[0x5]:null};}function _0x49dec6(_0x5c85de){for(let _0x5acbe8=0x0;_0x5acbe8<_0x37622b['length'];_0x5acbe8++){if(_0x5c85de['isAdded']&&'insertion'==_0x37622b[_0x5acbe8]['type'])return _0x5c85de['isAddSuggestion']=_0x37622b[_0x5acbe8],void delete _0x5c85de['isAdded'];if(!_0x5c85de['isAdded']&&!_0x5c85de['isRemoved']&&'deletion'==_0x37622b[_0x5acbe8]['type'])return void(_0x5c85de['isRemoveSuggestion']=_0x37622b[_0x5acbe8]);}}}['_setDistance'](_0x2b27c5,_0xebc218){let _0x10ec70=0x0,_0x20aae3=!0x1;const _0x2a4536=new Map();for(const _0x3dcd57 of _0x2b27c5)_0x3dcd57[_0xebc218]?_0x20aae3&&(_0x10ec70++,_0x20aae3=!0x1):(_0x10ec70++,_0x20aae3=!0x0),_0x2a4536['set'](_0x3dcd57['id'],_0x10ec70);for(let _0x2a830b=0x0;_0x2a830b<_0x2b27c5['length'];_0x2a830b++){if('isRemoved'==_0xebc218&&_0x2b27c5[_0x2a830b]['isAdded']||'isAdded'==_0xebc218&&_0x2b27c5[_0x2a830b]['isRemoved'])continue;if('text'==_0x2b27c5[_0x2a830b]['type']){_0x2b27c5[_0x2a830b]['distance']=0x0;continue;}const _0x2b22b8=_0x2a4536['get'](_0x2b27c5[_0x2a830b]['pairId']),_0x3449d8=_0x2a4536['get'](_0x2b27c5[_0x2a830b]['id']);_0x2b27c5[_0x2a830b]['distance']=_0x2b22b8-_0x3449d8;}}['_getRevisionsRange'](_0x1eb5b0,_0x53e74d,_0x3b0566=!0x1){const _0x592ef9=[];let _0x286088=this['repository']['getIndex'](_0x1eb5b0),_0x2dedde=this['repository']['getIndex'](_0x53e74d);for(-0x1==_0x2dedde&&(_0x2dedde=this['repository']['_revisions']['length'],_0x3b0566=!0x1);_0x286088<_0x2dedde;)_0x592ef9['push'](this['repository']['getRevision'](_0x286088)),_0x286088++;return _0x3b0566&&_0x592ef9['push'](this['repository']['getRevision'](_0x286088)),_0x592ef9;}['_threeWayMerge'](_0x1d82bd,_0x11a084,_0x4f24aa,_0x210957){const _0xd6e01b=this['editor']['model']['schema'];let _0x320a46=_0x11a084;for(;_0x1d82bd[_0x320a46]&&_0x1d82bd[_0x320a46]['isAdded'];)_0x320a46++;let _0xbdb9cc=_0x210957;for(;_0x4f24aa[_0xbdb9cc]&&_0x4f24aa[_0xbdb9cc]['isRemoved'];)_0xbdb9cc++;_0x122b94(_0x1d82bd,_0x11a084,_0x320a46),_0x122b94(_0x4f24aa,_0x210957,_0xbdb9cc);const _0x15c9f3=_0x4f24aa['slice'](_0x210957,_0xbdb9cc)['concat'](_0x1d82bd['slice'](_0x11a084,_0x320a46));return _0x15c9f3['sort']((_0x305d5a,_0x5eab89)=>_0x305d5a['side']!=_0x5eab89['side']?_0x305d5a['side']-_0x5eab89['side']:_0x305d5a['level']!=_0x5eab89['level']?_0x305d5a['level']-_0x5eab89['level']:_0x305d5a['distance']!=_0x5eab89['distance']?_0x5eab89['distance']-_0x305d5a['distance']:!!_0x305d5a['isAdded']!=!!_0x5eab89['isAdded']?-0x1==_0x305d5a['side']||0x0==_0x305d5a['side']?_0x305d5a['isAdded']?-0x1:0x1:_0x305d5a['isAdded']?0x1:-0x1:_0x305d5a['index']-_0x5eab89['index']),{'commonTape':_0x15c9f3,'iEnd':_0x320a46,'jEnd':_0xbdb9cc};function _0x122b94(_0x436155,_0x101406,_0x2b1985){let _0x223830=-0x1,_0x1c2685=Number['POSITIVE_INFINITY'],_0x5e8016=!0x0;for(let _0x22ae25=_0x101406;_0x22ae25<_0x2b1985;_0x22ae25++)if(_0xd6e01b['isInline'](_0x436155[_0x22ae25]['item'])||(_0x5e8016=!0x1),_0x436155[_0x22ae25]['item']['startIndex']<_0x101406&&(_0x223830=_0x22ae25),_0x436155[_0x22ae25]['item']['endIndex']>=_0x2b1985){_0x1c2685=_0x22ae25;break;}_0x5e8016&&(_0x223830=_0x2b1985-0x1);for(let _0x3ef058=_0x101406;_0x3ef058<_0x2b1985;_0x3ef058++)_0x436155[_0x3ef058]['side']=_0x3ef058<=_0x223830?-0x1:_0x3ef058<_0x1c2685?0x0:0x1,_0x436155[_0x3ef058]['index']=_0x3ef058;let _0x25394a=0x0;for(let _0x39e062=_0x101406;_0x39e062<=_0x223830;_0x39e062++)0x0==_0x436155[_0x39e062]['distance']?_0x436155[_0x39e062]['level']=_0x25394a:(_0x25394a++,_0x436155[_0x39e062]['level']=_0x25394a,_0x25394a++);for(let _0x2486bb=_0x101406;_0x2486bb<_0x2b1985;_0x2486bb++)0x0==_0x436155[_0x2486bb]['side']&&(_0x436155[_0x2486bb]['level']=_0x25394a);_0x25394a=0x0;for(let _0x42f6b3=_0x2b1985-0x1;_0x42f6b3>=_0x1c2685;_0x42f6b3--)0x0==_0x436155[_0x42f6b3]['distance']?_0x436155[_0x42f6b3]['level']=_0x25394a:(_0x25394a--,_0x436155[_0x42f6b3]['level']=_0x25394a,_0x25394a--);}}['_fixObsoleteTags'](_0x138f19){const _0x539762=new Map(),_0x1e5636=this['editor']['model']['schema'];for(let _0x538076=0x1;_0x538076<_0x138f19['length'];_0x538076++){let _0x3dd124,_0x5ecca6,_0x3fd587;const _0xa0a554=_0x138f19[_0x538076],_0x263a92=_0x138f19[_0x538076-0x1];if('text'==_0xa0a554['type'])continue;if(_0xa0a554['type']!=_0x263a92['type'])continue;if(!_0x1e5636['isBlock'](_0x263a92['item'])||_0x1e5636['isLimit'](_0x263a92['item']))continue;if(!_0x1e5636['isBlock'](_0xa0a554['item'])||_0x1e5636['isLimit'](_0xa0a554['item']))continue;if((_0x138f19[_0x538076]['isAdded']||_0x138f19[_0x538076]['isAddSuggestion'])&&_0x138f19[_0x538076-0x1]['isRemoved'])_0x3dd124=_0x138f19[_0x538076],_0x5ecca6=_0x138f19[_0x538076-0x1],_0x3fd587=_0x538076-0x1;else{if(!_0x138f19[_0x538076]['isRemoved']||!_0x138f19[_0x538076-0x1]['isAdded']&&!_0x138f19[_0x538076-0x1]['isAddSuggestion'])continue;_0x3dd124=_0x138f19[_0x538076-0x1],_0x5ecca6=_0x138f19[_0x538076],_0x3fd587=_0x538076;}const _0x3dbe07=_0x3dd124['level']==_0x5ecca6['level'],_0x2261db=Math['abs'](_0x3dd124['level'])<Math['abs'](_0x5ecca6['level'])&&0x0==_0x5ecca6['distance'];(_0x3dbe07||_0x2261db)&&(_0x539762['set'](_0x5ecca6['id'],_0x3dd124['id']),_0x138f19['splice'](_0x3fd587,0x1),_0x538076--,_0x3dd124['isAdded']=!0x1);}for(let _0x1c6eb5=0x0;_0x1c6eb5<_0x138f19['length'];_0x1c6eb5++)_0x539762['has'](_0x138f19[_0x1c6eb5]['pairId'])&&(_0x138f19[_0x1c6eb5]['pairId']=_0x539762['get'](_0x138f19[_0x1c6eb5]['pairId']));}['_removeMissingPairs'](_0x2af9ef){const _0x5e1a00=new Set(_0x2af9ef['map'](_0x3f8886=>_0x3f8886['id']));for(let _0x1ff314=0x0;_0x1ff314<_0x2af9ef['length'];_0x1ff314++)_0x5e1a00['has'](_0x2af9ef[_0x1ff314]['pairId'])||0x0==_0x2af9ef[_0x1ff314]['distance']||(_0x2af9ef[_0x1ff314]['isIncorrect']=!0x0);return _0x2af9ef['filter'](_0x3f65ab=>!_0x3f65ab['isIncorrect']);}['_markMismatchedRemovedTags'](_0x43c9bc){const _0x369611=new Set();for(let _0x440f52=0x0;_0x440f52<_0x43c9bc['length'];_0x440f52++){if(_0x369611['has'](_0x43c9bc[_0x440f52]['id'])&&_0x43c9bc[_0x440f52]['isRemoved']&&(_0x43c9bc[_0x440f52]['isIncorrect']=!0x0),_0x43c9bc[_0x440f52]['isIncorrect'])continue;if(0x0==_0x43c9bc[_0x440f52]['distance'])continue;if('elementStart'!=_0x43c9bc[_0x440f52]['type'])continue;if(null==_0x43c9bc[_0x440f52]['pairId'])continue;let _0x2e8dcd=_0x440f52+0x1,_0x44040e=0x0;for(;_0x43c9bc[_0x2e8dcd]['id']!=_0x43c9bc[_0x440f52]['pairId'];)'elementStart'==_0x43c9bc[_0x2e8dcd]['type']?_0x44040e++:'elementEnd'==_0x43c9bc[_0x2e8dcd]['type']&&_0x44040e--,_0x2e8dcd++;if(0x0!=_0x44040e){if(_0x43c9bc[_0x440f52]['isRemoved'])_0x43c9bc[_0x440f52]['isIncorrect']=!0x0;else{for(;_0x2e8dcd!=_0x440f52;)_0x43c9bc[_0x2e8dcd]['isRemoved']&&0x0!=_0x43c9bc[_0x2e8dcd]['distance']&&(_0x43c9bc[_0x2e8dcd]['isIncorrect']=!0x0,_0x369611['add'](_0x43c9bc[_0x2e8dcd]['pairId'])),_0x2e8dcd--;}}}return _0x43c9bc['filter'](_0x4026cf=>!_0x4026cf['isIncorrect']);}['_removeUnsupportedChanges'](_0x27a9de){const _0x1c04a2=this['editor']['model']['schema'];for(let _0x4c0c52=0x0;_0x4c0c52<_0x27a9de['length'];_0x4c0c52++){if(!(_0x27a9de[_0x4c0c52]['isAdded']||_0x27a9de[_0x4c0c52]['isAddSuggestion']||_0x27a9de[_0x4c0c52]['isRemoved']||_0x27a9de[_0x4c0c52]['isRemoveSuggestion']))continue;if(0x0==_0x27a9de[_0x4c0c52]['distance'])continue;const _0x42e8c8=_0x27a9de[_0x4c0c52]['item'];_0x1c04a2['isBlock'](_0x42e8c8)||_0x1c04a2['isLimit'](_0x42e8c8)||(_0x27a9de[_0x4c0c52]['isAdded']&&delete _0x27a9de[_0x4c0c52]['isAdded'],_0x27a9de[_0x4c0c52]['isAddSuggestion']&&delete _0x27a9de[_0x4c0c52]['isAddSuggestion'],_0x27a9de[_0x4c0c52]['isRemoveSuggestion']&&delete _0x27a9de[_0x4c0c52]['isRemoveSuggestion'],_0x27a9de[_0x4c0c52]['isRemoved']&&(_0x27a9de[_0x4c0c52]['isIncorrect']=!0x0));}return _0x27a9de['filter'](_0xea53ca=>!_0xea53ca['isIncorrect']);}['_makeModelFromTape'](_0x5ed6fa,_0x21091b,_0x21ce72){const _0x2a3e5d=new wt(),_0x2b9163=[],_0x590f4b=new Map(),_0x374223=this['editor']['model'],_0x192781=_0x374223['schema'],_0x13c3f2=[_0x2a3e5d],_0x404855={},_0x3157b5={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x1f57b2=null;const _0x41a0f3=[0x0];for(let _0x19cc95=0x0;_0x19cc95<_0x5ed6fa['length'];_0x19cc95++)if('elementStart'===_0x5ed6fa[_0x19cc95]['type']){_0x5ed6fa[_0x19cc95]['previousPosition']=_0x374223['createPositionFromPath'](_0x2a3e5d,_0x41a0f3);const _0xe5b4d=new ft(_0x5ed6fa[_0x19cc95]['item']['name'],_0x5ed6fa[_0x19cc95]['item']['getAttributes']());_0x13c3f2[0x0]['_appendChild'](_0xe5b4d),_0x41a0f3['push'](0x0),_0x13c3f2['unshift'](_0xe5b4d),_0x5ed6fa[_0x19cc95]['nextPosition']=_0x374223['createPositionFromPath'](_0x2a3e5d,_0x41a0f3);}else'elementEnd'===_0x5ed6fa[_0x19cc95]['type']?(_0x13c3f2['shift'](),_0x5ed6fa[_0x19cc95]['previousPosition']=_0x374223['createPositionFromPath'](_0x2a3e5d,_0x41a0f3),_0x41a0f3['pop'](),_0x41a0f3[_0x41a0f3['length']-0x1]++,_0x5ed6fa[_0x19cc95]['nextPosition']=_0x374223['createPositionFromPath'](_0x2a3e5d,_0x41a0f3)):(_0x5ed6fa[_0x19cc95]['previousPosition']=_0x374223['createPositionFromPath'](_0x2a3e5d,_0x41a0f3),_0x1f57b2?_0x1f57b2['_data']+=_0x5ed6fa[_0x19cc95]['item']['data']:_0x1f57b2=new _t(_0x5ed6fa[_0x19cc95]['item']['data'],_0x5ed6fa[_0x19cc95]['item']['getAttributes']()),_0x5ed6fa[_0x19cc95+0x1]&&'text'===_0x5ed6fa[_0x19cc95+0x1]['type']&&_0x2ca999(_0x1f57b2,_0x5ed6fa[_0x19cc95+0x1]['item'])||(_0x13c3f2[0x0]['_appendChild'](_0x1f57b2),_0x1f57b2=null),_0x41a0f3[_0x41a0f3['length']-0x1]+=_0x5ed6fa[_0x19cc95]['item']['offsetSize'],_0x5ed6fa[_0x19cc95]['nextPosition']=_0x374223['createPositionFromPath'](_0x2a3e5d,_0x41a0f3));for(let _0x151034=0x0;_0x151034<_0x5ed6fa['length'];_0x151034++){const _0x9ee905=_0x5ed6fa[_0x151034]['previousPosition'],_0x1be676=_0x5ed6fa[_0x151034]['nextPosition'];for(const _0x5de606 of _0x5ed6fa[_0x151034]['markersStart'])_0x590f4b['set'](_0x5de606,{'start':_0x9ee905,'end':null});_0x2a2434('isRemoveSuggestion',_0x151034,_0x9ee905,_0x1be676),_0x2a2434('isAddSuggestion',_0x151034,_0x9ee905,_0x1be676),_0x2a2434('isRemoved',_0x151034,_0x9ee905,_0x1be676),_0x2a2434('isAdded',_0x151034,_0x9ee905,_0x1be676);for(const _0x34dccd of _0x5ed6fa[_0x151034]['markersEnd']){_0x590f4b['get'](_0x34dccd)['end']=_0x1be676;}}for(const [_0x4ba1c0,_0x31632f]of _0x590f4b){const _0x2ccdd9=this['editor']['model']['createRange'](_0x31632f['start'],_0x31632f['end']);_0x2a3e5d['markers']['set'](_0x4ba1c0,_0x2ccdd9);}return _0x2b9163['sort']((_0x34e11e,_0x5dcf7d)=>{const _0x5c4eb5=_0x2a3e5d['markers']['get']('revision:'+_0x34e11e['id']),_0x2dfb8f=_0x2a3e5d['markers']['get']('revision:'+_0x5dcf7d['id']);return _0x5c4eb5['start']['isBefore'](_0x2dfb8f['start'])?-0x1:_0x5c4eb5['start']['isAfter'](_0x2dfb8f['start'])?0x1:_0x5c4eb5['end']['isBefore'](_0x2dfb8f['end'])?-0x1:_0x5c4eb5['end']['isAfter'](_0x2dfb8f['end'])?0x1:'add'===_0x34e11e['type']?-0x1:0x1;}),{'root':_0x2a3e5d,'changes':_0x2b9163};function _0x2a2434(_0x1d1142,_0xa233b,_0x42fc53,_0x48d484){const _0x271ef2=!!_0x5ed6fa[_0xa233b][_0x1d1142],_0x4ec033=_0x271ef2?_0x5ed6fa[_0xa233b][_0x1d1142]['userId']:null,_0x121618=_0xa233b===_0x5ed6fa['length']-0x1,_0x4e601a=_0x3157b5[_0x1d1142][0x0],_0x3f8459=_0x192781['isObject'](_0x5ed6fa[_0xa233b]['item']);!_0x404855[_0x1d1142]&&_0x271ef2?_0x404855[_0x1d1142]={'start':_0x42fc53,'tapeItem':_0x5ed6fa[_0xa233b],'userId':_0x4ec033,'type':_0x1d1142}:_0x404855[_0x1d1142]&&!_0x271ef2?(_0x404855[_0x1d1142]['end']=_0x42fc53,_0x3b18bd(_0x404855[_0x1d1142]),_0x404855[_0x1d1142]=null):_0x404855[_0x1d1142]&&_0x271ef2&&_0x404855[_0x1d1142]['userId']!==_0x4ec033&&(_0x404855[_0x1d1142]['end']=_0x42fc53,_0x4e601a&&_0x4e601a['userId']===_0x404855[_0x1d1142]['userId']||_0x3b18bd(_0x404855[_0x1d1142]),_0x404855[_0x1d1142]={'start':_0x42fc53,'tapeItem':_0x5ed6fa[_0xa233b],'userId':_0x4ec033,'type':_0x1d1142}),_0x404855[_0x1d1142]&&_0x3f8459&&('elementStart'!==_0x5ed6fa[_0xa233b]['type']||_0x4e601a&&_0x4e601a['userId']===_0x4ec033||_0x3157b5[_0x1d1142]['unshift']({'userId':_0x4ec033,'object':_0x5ed6fa[_0xa233b]['item'],'change':_0x404855[_0x1d1142]}),'elementEnd'===_0x5ed6fa[_0xa233b]['type']&&_0x4e601a&&_0x4e601a['object']===_0x5ed6fa[_0xa233b]['item']&&(_0x3157b5[_0x1d1142]['shift'](),_0x404855[_0x1d1142]=_0x4e601a['change'])),_0x404855[_0x1d1142]&&_0x121618&&(_0x404855[_0x1d1142]['end']=_0x48d484,_0x3b18bd(_0x404855[_0x1d1142]),_0x404855[_0x1d1142]=null);}function _0x3b18bd({start:_0x373461,end:_0x528669,tapeItem:_0x7a8e3a,userId:_0x574551,type:_0x35e60e}){const _0x92eb5a=_0x7a8e3a['item'],_0xeb306f=_0x374223['schema']['isBlock'](_0x92eb5a)&&!_0x374223['schema']['isLimit'](_0x92eb5a),_0x10398c=_0x373461['nodeAfter']==_0x528669['parent']&&_0x528669['isAtStart'];if(_0xeb306f&&_0x10398c)return;const _0x21141b=_0x374223['createRange'](_0x373461,_0x528669),_0x363f78=_0x21091b['get'](_0x574551),_0x28d519=new r({'author':_0x363f78,'type':'isAdded'==_0x35e60e||'isAddSuggestion'==_0x35e60e?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x35e60e||'isRemoveSuggestion'==_0x35e60e},'createdAt':new Date(),'rootName':_0x21ce72});_0x2b9163['push'](_0x28d519),_0x2a3e5d['markers']['set']('revision:'+_0x28d519['id'],_0x21141b);}function _0x2ca999(_0x5eeeac,_0x258f5a){const _0x55cff0=_0x5eeeac['getAttributes'](),_0x342f03=_0x258f5a['getAttributes']();for(const _0x517c43 of _0x55cff0){if(_0x517c43[0x1]!==_0x258f5a['getAttribute'](_0x517c43[0x0]))return!0x1;_0x342f03['next']();}return _0x342f03['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x53fd53=>{const _0x269ae4=_0x53fd53['markerName']['split'](':')[0x1],_0x556ef5=this['_getChangeFromId'](_0x269ae4);if(!_0x556ef5)return null;const _0x1999a3='add'==_0x556ef5['type']?'insertion':'deletion',_0x1bed0f=['ck-suggestion-marker','ck-suggestion-marker-'+_0x1999a3];return _0x556ef5['data']['isSuggestion']&&_0x1bed0f['push']('ck-suggestion-marker-'+_0x1999a3+'-new'),this['activeChange']==_0x556ef5&&_0x1bed0f['push']('ck-suggestion-marker--active'),{'classes':_0x1bed0f,'attributes':{'data-change-id':_0x269ae4}};}}),this['editor']['conversion']['for']('upcast')['add'](_0xeb26d5=>{_0xeb26d5['on']('element:pre',(_0x22da0b,_0x51a1bb,_0x576691)=>{const _0x2f8084=_0x51a1bb['viewItem']['getChild'](0x0);if(!_0x2f8084||!_0x2f8084['is']('element','code'))return;if(!_0x576691['consumable']['consume'](_0x2f8084,{'attributes':['vid_start','vid_end']}))return;const _0x17feee=_0x51a1bb['modelRange']['start']['nodeAfter'];_0x576691['writer']['setAttribute']('vid_start',_0x2f8084['getAttribute']('vid_start'),_0x17feee),_0x576691['writer']['setAttribute']('vid_end',_0x2f8084['getAttribute']('vid_end'),_0x17feee);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x33b075=>{_0x33b075['on']('element',(_0x51f810,_0x18ed93,_0x31ee50)=>{if(!_0x31ee50['consumable']['consume'](_0x18ed93['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x18ed93['modelRange']['isCollapsed'])return;const _0x5ca58b=_0x18ed93['modelRange']['start']['nodeAfter'];_0x5ca58b['hasAttribute']('vid_start')||_0x5ca58b['hasAttribute']('vid')||(_0x31ee50['writer']['setAttribute']('vid_start',_0x18ed93['viewItem']['getAttribute']('vid_start'),_0x5ca58b),_0x31ee50['writer']['setAttribute']('vid_end',_0x18ed93['viewItem']['getAttribute']('vid_end'),_0x5ca58b));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0xd97e17=>_0xd97e17['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x32b396,[,_0x573496])=>{['vid_start','vid_end','vid']['includes'](_0x573496)&&(_0x32b396['return']=!0x0,_0x32b396['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x3f3935=>{_0x3f3935['on']('attribute:vid',(_0x2e8110,_0x203c2b,_0x13e51d)=>{if('\x20'!=_0x203c2b['item']['data']||_0x203c2b['item']['parent']['maxOffset']>0x1)return;if(!_0x13e51d['consumable']['consume'](_0x203c2b['item'],_0x2e8110['name']))return;const _0x29b438=_0x13e51d['writer'],_0x18168f=_0x13e51d['mapper']['toViewRange'](_0x203c2b['range']);_0x29b438['wrap'](_0x18168f,_0x29b438['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x229f13){const _0x2201d7=_0x229f13['plugins']['get']('RevisionViewer');return(_0x2b98a9,_0xf8c091,_0x36e92e)=>{const _0x3f4d4b=_0xf8c091['markerName']['split'](':')[0x1],_0x4a170a=_0x2201d7['_getChangeFromId'](_0x3f4d4b);if(!_0x4a170a)return null;const _0x381abf='add'==_0x4a170a['type']?'split':'merge';if(!_0x36e92e['consumable']['test'](_0xf8c091['markerRange'],_0x2b98a9['name']))return;const _0x347385=_0xf8c091['markerRange']['getWalker'](),_0x5dba07=_0xf8c091['markerRange']['start'],_0x38f0a=_0x229f13['model']['schema'];let _0x25665b=null,_0x7fa1eb=null,_0x5d2052=!0x1,_0xdae4c4=!0x1;for(const _0x501c06 of _0x347385){const _0x445e52=_0x501c06['item'];_0x5d2052=_0x5d2052||_0x38f0a['isContent'](_0x445e52);const _0x34aff3=_0x36e92e['mapper']['toViewElement'](_0x445e52);if(_0x34aff3&&_0x34aff3['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x501c06['type']&&(_0x38f0a['isBlock'](_0x445e52)&&!_0x38f0a['isLimit'](_0x445e52)&&(_0x445e52['nextSibling']||_0x5dba07['isAtEnd']?_0x25665b&&_0x25665b['parent']==_0x445e52||(_0x25665b=_0x445e52,_0x55c430(_0x501c06['previousPosition']),_0xdae4c4=!0x0):_0x7fa1eb=_0x7fa1eb||_0x501c06['previousPosition']));}function _0x55c430(_0x537aa7){const _0x3d77f9=_0x36e92e['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x381abf}),_0x438ba6=_0x36e92e['mapper']['toViewPosition'](_0x537aa7);_0x4a170a['data']['isSuggestion']&&_0x36e92e['writer']['addClass']('ck-suggestion-marker-'+_0x381abf+'-new',_0x3d77f9),_0x2201d7['activeChange']==_0x4a170a&&_0x36e92e['writer']['addClass']('ck-suggestion-marker--active',_0x3d77f9),_0x36e92e['writer']['insert'](_0x438ba6,_0x3d77f9),_0x36e92e['mapper']['bindElementToMarker'](_0x3d77f9,_0xf8c091['markerName']);}_0x5d2052||_0xdae4c4||!_0x7fa1eb||_0x55c430(_0x7fa1eb);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x50c71d,_0x5a0566,_0x3c675b)=>{const _0x324677=_0x3c675b['mapper']['markerNameToElements'](_0x5a0566['markerName']);if(_0x324677){for(const _0x57be17 of _0x324677)(_0x57be17['hasClass']('ck-suggestion-marker-split')||_0x57be17['hasClass']('ck-suggestion-marker-merge'))&&(_0x3c675b['mapper']['unbindElementFromMarkerName'](_0x57be17,_0x5a0566['markerName']),_0x3c675b['writer']['remove'](_0x57be17));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x4b20c3,_0x4c80f5,_0x319c51)=>{const _0x1afb5a=_0x4c80f5['markerName']['split'](':')[0x1],_0x1722d0=this['_getChangeFromId'](_0x1afb5a);if(!_0x1722d0)return null;const _0x753ff0='add'==_0x1722d0['type']?'split':'merge';if(_0x319c51['consumable']['test'](_0x4c80f5['markerRange'],_0x4b20c3['name']))for(const _0x52119c of _0x4c80f5['markerRange']['getItems']()){if(!_0x52119c['is']('element','softBreak'))continue;const _0x59d69f=_0x319c51['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x753ff0}),_0x2e66ec=_0x319c51['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x52119c));_0x1722d0['data']['isSuggestion']&&_0x319c51['writer']['addClass']('ck-suggestion-marker-'+_0x753ff0+'-new',_0x59d69f),this['activeChange']==_0x1722d0&&_0x319c51['writer']['addClass']('ck-suggestion-marker--active',_0x59d69f),_0x319c51['writer']['insert'](_0x2e66ec,_0x59d69f),_0x319c51['mapper']['bindElementToMarker'](_0x59d69f,_0x4c80f5['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x290f40=>{for(const _0x45e516 of this['editor']['model']['document']['getRootNames']()){const _0x163b54=this['editor']['model']['document']['getRoot'](_0x45e516),_0x56cecf=this['editor']['editing']['view']['document']['getRoot'](_0x45e516);if(_0x56cecf){const _0x2c690f=_0x163b54['getAttribute']('revisionHistoryAttachChange');if(_0x290f40['removeAttribute']('data-change-id',_0x56cecf),_0x290f40['removeClass']('ck-revision-history-root-add',_0x56cecf),_0x290f40['removeClass']('ck-revision-history-root-remove',_0x56cecf),_0x290f40['removeClass']('ck-revision-history-root--active',_0x56cecf),_0x2c690f){const _0xfebeca=this['_getChangeFromId'](_0x2c690f);if(!_0xfebeca)return null;_0x290f40['setAttribute']('data-change-id',_0x2c690f,_0x56cecf),_0x290f40['addClass']('ck-revision-history-root-'+_0xfebeca['type'],_0x56cecf),this['activeChange']==_0xfebeca&&_0x290f40['addClass']('ck-revision-history-root--active',_0x56cecf);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x2e6939=>'revision-comment:'+_0x2e6939,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x1353b6=>'revision-suggestion:'+_0x1353b6,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x190771=>({'name':'suggestion:'+_0x190771,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x3e973a=>{const _0x4396c5=_0x3e973a['markerName']['split'](':')[0x1];return'insertion'!=_0x4396c5&&'deletion'!=_0x4396c5?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x4396c5]};}}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:deletion',tt(this['editor'],'merge'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:insertion',tt(this['editor'],'split'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision-suggestion',(_0x36983b,_0x438e5a,_0x40bc60)=>{const _0x27dd5f=_0x40bc60['mapper']['markerNameToElements'](_0x438e5a['markerName']);if(_0x27dd5f){for(const _0x4638e8 of _0x27dd5f)_0x4638e8['is']('uiElement')&&(_0x40bc60['mapper']['unbindElementFromMarkerName'](_0x4638e8,_0x438e5a['markerName']),_0x40bc60['writer']['remove'](_0x4638e8));}},{'priority':'high'});}['_getChangeFromId'](_0x520543){return this['_changeIdToChange']['get'](_0x520543);}['_getViewForChange'](_0x5309f4){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new Y(this['editor']['locale'],_0x5309f4),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x57041a,_0x1bcc92,_0x4bc680,_0x3170e5)=>{_0x3170e5&&this['_balloon']['remove'](_0x3170e5),_0x4bc680&&(this['_balloon']['add']({'view':_0x4bc680,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x26b380=this['editor']['editing'],_0x1800b3=this['_getChangeFromId'](_0x4bc680['changeId']);let _0x5727c8;if(_0x1800b3['data']['isOnRoot']){const _0x26462a=_0x26b380['view']['getDomRoot'](_0x1800b3['rootName']);_0x5727c8=Array['from'](_0x26462a['getClientRects']());}else{const _0x509be4=this['editor']['model']['markers']['get']('revision:'+_0x4bc680['changeId']);_0x5727c8=Array['from'](_0x26b380['mapper']['markerNameToElements'](_0x509be4['name']))['map'](_0x274257=>_0x26b380['view']['domConverter']['mapViewToDom'](_0x274257))['map'](_0x3bae53=>Array['from'](_0x3bae53['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x5727c8[0x0];return _0x5727c8['find'](_0x5ed9f1=>_0x5ed9f1['top']-0x3<=this['_activeViewTarget']['y']&&_0x5ed9f1['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x5ed9f1['left']-0x3<=this['_activeViewTarget']['x']&&_0x5ed9f1['right']+0x3>=this['_activeViewTarget']['x'])||_0x5727c8[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x162fdb,_0x1a8728,_0x5acc81,_0x5dae8d)=>{this['activeView']=_0x5acc81?this['_getViewForChange'](_0x5acc81):null,this['editor']['model']['change'](()=>{const _0x35d72d=this['editor']['editing'];_0x5dae8d&&(_0x5dae8d['data']['isOnRoot']?_0x35d72d['view']['change'](_0xdcfb7d=>{_0xdcfb7d['removeClass']('ck-revision-history-root--active',_0x35d72d['view']['document']['getRoot'](_0x5dae8d['rootName']));}):_0x35d72d['reconvertMarker']('revision:'+_0x5dae8d['id'])),_0x5acc81&&(_0x5acc81['data']['isOnRoot']?_0x35d72d['view']['change'](_0xf5c898=>{_0xf5c898['addClass']('ck-revision-history-root--active',_0x35d72d['view']['document']['getRoot'](_0x5acc81['rootName']));}):_0x35d72d['reconvertMarker']('revision:'+_0x5acc81['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x4f19b1,_0x4aff60)=>{if(this['activeChange'])return;const _0x580d74=this['_findChangeIdFromDomTarget'](_0x4aff60['target']),_0x5a03c1=this['_changeIdToChange']['get'](_0x580d74);_0x5a03c1?(this['_activeViewTarget']={'x':_0x4aff60['domEvent']['x'],'y':_0x4aff60['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x5a03c1)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x449ad6,_0x2b8751)=>{const _0x5994e8=this['_findChangeIdFromDomTarget'](_0x2b8751['target']),_0x39d32e=this['_changeIdToChange']['get'](_0x5994e8);_0x39d32e?(this['_activeViewTarget']={'x':_0x2b8751['domEvent']['x'],'y':_0x2b8751['domEvent']['y']},_0x39d32e===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x39d32e):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x3b66b5){do{const _0x49eb13=_0x3b66b5['getAttribute']('data-change-id');if(_0x49eb13)return _0x49eb13;_0x3b66b5=_0x3b66b5['parent'];}while(_0x3b66b5);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x4cfd05=>{for(const _0x4bb2d9 of this['editor']['model']['markers'])_0x4cfd05['removeMarker'](_0x4bb2d9);});}}function tt(_0x5bfc4e,_0x2126bc){return(_0x4da64b,_0x4a120d,_0x15be05)=>{if(!_0x15be05['consumable']['test'](_0x4a120d['markerRange'],_0x4da64b['name']))return;const _0x121d88=_0x4a120d['markerRange']['getWalker'](),_0x2860d2=_0x4a120d['markerRange']['start'],_0x4fbefa=_0x5bfc4e['model']['schema'];let _0x280a28=null,_0x41f140=null,_0x211dbf=!0x1,_0x315bff=!0x1;for(const _0x11d4dc of _0x121d88){const _0x2cd748=_0x11d4dc['item'];_0x211dbf=_0x211dbf||_0x4fbefa['isContent'](_0x2cd748);const _0x4e4ae7=_0x15be05['mapper']['toViewElement'](_0x2cd748);if(_0x4e4ae7&&_0x4e4ae7['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x11d4dc['type']&&(_0x4fbefa['isBlock'](_0x2cd748)&&!_0x4fbefa['isLimit'](_0x2cd748)&&(_0x2cd748['nextSibling']||_0x2860d2['isAtEnd']?_0x280a28&&_0x280a28['parent']==_0x2cd748||(_0x280a28=_0x2cd748,_0x3ebbfc(_0x11d4dc['previousPosition']),_0x315bff=!0x0):_0x41f140=_0x41f140||_0x11d4dc['previousPosition']));}function _0x3ebbfc(_0x62da2a){const _0x144344=_0x15be05['mapper']['toViewPosition'](_0x62da2a),_0x5e1f85=_0x15be05['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x2126bc});_0x15be05['writer']['insert'](_0x144344,_0x5e1f85),_0x15be05['mapper']['bindElementToMarker'](_0x5e1f85,_0x4a120d['markerName']);}_0x211dbf||_0x315bff||!_0x41f140||_0x3ebbfc(_0x41f140);};}class yt extends _0x98083a{constructor(_0x14a541){super(_0x14a541);const _0x246c06=_0x14a541['plugins']['get'](d);this['affectsData']=!0x1,this['listenTo'](_0x246c06,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x246c06,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x199a4b=this['editor'],_0x4dc064=_0x199a4b['plugins']['get'](d),_0x53eb16=_0x4dc064['isReady']?_0x4dc064['diff']['newRevisionId']:null;_0x199a4b['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x53eb16);}['refresh'](){const {isReady:_0x4a7c94,isEnabled:_0x524250,repository:_0x696fdf,diff:_0x563c6f}=this['editor']['plugins']['get'](d),_0x2d773c=_0x563c6f&&_0x696fdf['getLaterVisibleRevision'](_0x563c6f['newRevisionId']);this['isEnabled']=_0x4a7c94&&_0x524250&&Boolean(_0x2d773c);}}class bt extends _0x98083a{['_step'];constructor(_0x620edd,{direction:_0x132ccf}){super(_0x620edd);const _0x41bb44=_0x620edd['plugins']['get'](d);this['affectsData']=!0x1,this['_step']='forward'===_0x132ccf?0x1:-0x1,this['listenTo'](_0x41bb44,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x41bb44,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x41bb44,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x594a01=this['editor'],_0x3fabe4=_0x594a01['plugins']['get'](d),{isNavigationMode:_0x16d5b3,currentChangeNumber:_0x4f29fe}=_0x3fabe4;let _0x132bbd;if(_0x3fabe4['activeChange']=_0x16d5b3?_0x3fabe4['diff']['changes']['get'](_0x4f29fe+this['_step']):_0x3fabe4['diff']['changes']['first'],_0x3fabe4['activeChange']['data']['isOnRoot'])_0x132bbd=_0x594a01['editing']['view']['getDomRoot'](_0x3fabe4['activeChange']['rootName']);else{const _0x4445be=_0x594a01['model']['markers']['get']('revision:'+_0x3fabe4['activeChange']['id']);_0x132bbd=_0x294892(_0x594a01['editing'],_0x4445be);}_0x252897({'target':_0x132bbd,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x1061d0,currentChangeNumber:_0x239a17,numberOfChanges:_0x53c193,isReady:_0x282ba7,isEnabled:_0x441f16}=this['editor']['plugins']['get'](d);this['isEnabled']=!!(_0x441f16&&_0x282ba7&&_0x53c193)&&(!_0x1061d0||(0x1===this['_step']?_0x239a17<_0x53c193-0x1:_0x239a17>0x0));}}class _i extends _0x225181{constructor(_0x5568c6){super(_0x5568c6);const _0xa40b4c=this['bindTemplate'],_0x42d8f6=new _0x4f59ce(_0x5568c6),_0x19d19f=new _0x4f59ce(_0x5568c6);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',(_0x515089,_0xdfb76a)=>_0x515089&&_0xdfb76a>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x28521a,_0x38e10e,_0x2c1951,_0x129020)=>{if(!_0x28521a)return R(_0x5568c6,'Loading...');if(!_0x2c1951)return R(_0x5568c6,'No\x20changes');const _0x4d7895=R(_0x5568c6,'NUMBER_OF_CHANGES',_0x2c1951);return _0x129020?R(_0x5568c6,'X_OF_Y_CHANGES',[_0x38e10e+0x1,_0x2c1951]):_0x4d7895;}),_0x42d8f6['set']({'label':R(_0x5568c6,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':'<svg\x20viewBox=\x220\x200\x2020\x2020\x22\x20xmlns=\x22http://www.w3.org/2000/svg\x22><path\x20d=\x22M16.435\x2014.494a.75.75\x200\x200\x200\x201.197-.899l-.067-.089-6.992-8a.75.75\x200\x200\x200-1.05-.078l-.079.078-7.008\x208a.75.75\x200\x200\x200\x201.049\x201.066l.08-.078\x206.442-7.354\x206.428\x207.354z\x22/></svg>\x0a'}),_0x19d19f['set']({'label':R(_0x5568c6,'Show\x20next\x20change'),'tooltip':!0x0,'icon':'<svg\x20viewBox=\x220\x200\x2020\x2020\x22\x20xmlns=\x22http://www.w3.org/2000/svg\x22><path\x20d=\x22M16.435\x205.506a.75.75\x200\x200\x201\x201.197.899l-.067.089-6.992\x208a.75.75\x200\x200\x201-1.05.078l-.079-.078-7.008-8a.75.75\x200\x200\x201\x201.049-1.066l.08.078\x206.442\x207.354\x206.428-7.354z\x22/></svg>\x0a'}),_0x42d8f6['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x19d19f['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x42d8f6['on']('execute',()=>this['fire']('execute','backward')),_0x19d19f['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',_0xa40b4c['if']('_isStatusLabelVisible','ck-hidden',_0x474b12=>!_0x474b12)]},'children':[{'text':_0xa40b4c['to']('isNavigationMode',_0x4dc921=>_0x4dc921?R(_0x5568c6,'EDIT_X_OF_Y_REVISIONS')+':\x20':R(_0x5568c6,'Total')+':\x20')}]},{'text':_0xa40b4c['to']('_statusText')}]},new _0x198730(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x42d8f6,_0x19d19f]}]});}}const ce='ck-editor__editable__loading-overlay';class le extends _0x49970d{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x246f0b=this['editor']['editing']['view'];_0x246f0b['change'](_0x2fcaee=>{for(const _0xe1f375 of _0x246f0b['document']['roots'])_0x2fcaee['addClass'](ce,_0xe1f375);});}['hide'](){const _0x148109=this['editor']['editing']['view'];_0x148109['change'](_0x15adb2=>{for(const _0x3d2283 of _0x148109['document']['roots'])_0x15adb2['removeClass'](ce,_0x3d2283);});}}class m extends _0x49970d{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[d,le];}['init'](){const _0x2cd326=this['editor'],_0xfeb391=_0x2cd326['plugins']['get'](d),_0x3eb57c=_0x2cd326['plugins']['get'](le);_0x2cd326['ui']['componentFactory']['add']('exitToEditing',_0x2c8da6=>{const _0xd1d48c=new _0x4f59ce(_0x2c8da6);return _0xd1d48c['set']({'label':R(_0x2c8da6,'Back\x20to\x20editing'),'icon':_0x429f7b['undo'],'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0xd1d48c,'execute',()=>{_0x2cd326['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0xd1d48c;}),_0x2cd326['ui']['componentFactory']['add']('restoreRevision',_0xd9b418=>{const _0x46756a=new _0x4f59ce(_0xd9b418);return _0x46756a['set']({'label':R(_0xd9b418,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x46756a['bind']('isEnabled')['to'](_0x2cd326['commands']['get']('restoreRevision')),this['listenTo'](_0x46756a,'execute',()=>_0x2cd326['execute']('restoreRevision')),_0x46756a;}),_0x2cd326['ui']['componentFactory']['add']('changesNavigation',_0x3c4816=>{const _0x3aef94=new _i(_0x3c4816),_0x4e8820=_0x2cd326['commands']['get']('showPreviousChange'),_0x176728=_0x2cd326['commands']['get']('showNextChange');return _0x3aef94['bind']('isBackwardNavigationEnabled')['to'](_0x4e8820,'isEnabled'),_0x3aef94['bind']('isForwardNavigationEnabled')['to'](_0x176728,'isEnabled'),_0x3aef94['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0xfeb391),this['listenTo'](_0x3aef94,'execute',(_0x3506a4,_0x1751ff)=>{_0x2cd326['execute']('forward'===_0x1751ff?'showNextChange':'showPreviousChange');}),_0x3aef94;}),_0x3eb57c['show'](),_0xfeb391['on']('change:isReady',(_0x38922a,_0xefd014,_0x2b4d76)=>{_0x2b4d76?_0x3eb57c['hide']():_0x3eb57c['show']();});}}class mt extends at{['_resizeObserver']=null;constructor(_0x56b2d7,_0x594bbd){super(_0x56b2d7,_0x594bbd);const _0x3ec3cb=this['bindTemplate'];this['set']({'label':R(_0x56b2d7,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=R(_0x56b2d7,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x3ec3cb['to']('_tooltipString'),'data-cke-tooltip-position':'s','data-cke-tooltip-class':'ck-tooltip_multi-line'}});}['render'](){super['render'](),this['_resizeObserver']=new pt(this['fieldView']['element'],()=>this['_updateTooltipText']()),this['listenTo'](this['fieldView'],'input',()=>this['_updateTooltipText']());}['destroy'](){super['destroy'](),this['_resizeObserver']&&this['_resizeObserver']['destroy']();}['_updateTooltipText'](){const _0x4a7aa=this['fieldView']['element'];this['_tooltipString']=_0x4a7aa['scrollWidth']>_0x4a7aa['clientWidth']&&_0x4a7aa['value']||'';}}class ti extends _0x225181{constructor(_0x16de7a,_0x381a60,_0x3a2665){super(_0x16de7a);const _0x4dd6b1=new _0x263ade();_0x4dd6b1['set']({'content':'<svg\x20viewBox=\x220\x200\x2011\x2010\x22\x20xmlns=\x22http://www.w3.org/2000/svg\x22\x20xmlns:xlink=\x22http://www.w3.org/1999/xlink\x22><path\x20d=\x22M5.5\x205C8.538\x205\x2011\x207.015\x2011\x209.5c0\x20.17-.011.336-.034.5H.034A3.732\x203.732\x200\x200\x201\x200\x209.5C0\x207.015\x202.462\x205\x205.5\x205zm0-5a2.5\x202.5\x200\x201\x201\x200\x205\x202.5\x202.5\x200\x200\x201\x200-5z\x22\x20/></svg>\x0a','viewBox':'0\x200\x2011\x2010'});const _0x5b884f=['ck','ck-revision-history-sidebar__revision-author'];_0x3a2665&&_0x5b884f['push']('ck-revision-history-sidebar__revision-author_creator');const _0x202a2d=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':R(_0x16de7a,_0x3a2665?'Revision\x20creator':'Revision\x20author')},'children':[_0x4dd6b1,_0x381a60['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x5b884f},'children':_0x202a2d});}}function ni(_0x161acc,_0x5cdf51){const _0x5e6a73=_0x161acc['bindTemplate'],_0x82eeac=_0x161acc['locale'],_0x3e9c3d=_0xd76513(_0x82eeac);_0x3e9c3d['panelPosition']='sw';const _0x5030a7=function(_0x25811b,_0x233275){const _0x49852e=function(_0x2337a2,_0xf11ec){const _0x384641=_0x2337a2['locale'],_0x1a609c={'Compare\x20against\x20selected':R(_0x384641,'Compare\x20against\x20selected'),'Name\x20this\x20revision':R(_0x384641,'Name\x20this\x20revision'),'Restore\x20this\x20revision':R(_0x384641,'Restore\x20this\x20revision')};return _0xf11ec['map'](_0x1229c2=>{const _0x106a58=_0x1a609c[_0x1229c2['name']];return _0x106a58&&_0x106a58!==_0x1229c2['name']&&(_0x1229c2['name']=_0x106a58),_0x1229c2;});}(_0x25811b,_0x233275),_0x42844f=new _0x2745a9();for(const _0x4381b7 of _0x49852e){const _0xdbec00={'type':'button','model':new to({'label':_0x4381b7['name'],'class':_0x4381b7['class'],'withText':!0x0,'role':'menuitem','_action':_0x4381b7['action']})};_0xdbec00['model']['bind']('isEnabled')['to'](_0x25811b,'isActionsDropdownOpen',_0xb242a4=>'function'!=typeof _0x4381b7['isEnabled']||(!_0xb242a4||_0x4381b7['isEnabled'](_0x25811b))),_0x42844f['add'](_0xdbec00);}return _0x42844f;}(_0x161acc,_0x5cdf51);return _0x161acc['bind']('isActionsDropdownOpen')['to'](_0x3e9c3d,'isOpen'),_0x3e9c3d['buttonView']['set']({'label':R(_0x82eeac,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x429f7b['threeVerticalDots']}),_0x3e9c3d['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x5e6a73['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x5e6a73['to'](_0x1634cf=>_0x1634cf['stopPropagation']())}}),_0x3e9c3d['on']('execute',_0x39e1e5=>{_0x161acc['isReady']&&'function'==typeof _0x39e1e5['source']['_action']&&_0x39e1e5['source']['_action'](_0x161acc);}),_0x362d35(_0x3e9c3d,_0x5030a7,{'role':'menu'}),_0x3e9c3d['listenTo'](_0x161acc,'change:isActionsDropdownOpen',(_0x500b2c,_0x33bcf7,_0x533880)=>{if(_0x533880)for(const _0x597057 of _0x3e9c3d['listView']['items']){const _0x3e214f=_0x597057['children']['first'],_0x44c3af=_0x5cdf51['find'](_0x515a97=>_0x515a97['action']===_0x3e214f['_action'])['isVisible'];_0x597057['isVisible']=void 0x0===_0x44c3af||_0x44c3af(_0x161acc);}}),_0x3e9c3d;}class ai extends/* #__PURE__ -- @preserve */
|
|
26
|
-
|
|
23
|
+
import{ObservableMixin as _0x4fe546,uid as _0x4d1572,Collection as _0x3461b4,logWarning as _0xe27a3a,FocusTracker as _0x4033fd,KeystrokeHandler as _0x4a5e29,scrollViewportToShowTarget as _0x342911,ResizeObserver as pt,ElementReplacer as ct,CKEditorError as _0xccd322}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x55297f,set as _0x1ac155,unset as _0x37772b,isEqual as _0x12e0da}from'lodash-es';import{Plugin as _0x49d8e7,PendingActions as _0x4f6c30,icons as _0x180720,Command as _0x1209ce,ElementApiMixin as rt,Editor as it}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x211ed4,getMarkerDomElement as _0x123f5b,ConfirmMixin as _0x11f94b,sanitizeEditorConfig as _0x4ba276}from'ckeditor5-collaboration/dist/index.js';import{ViewDocumentFragment as _0xa0965c,ViewText as _0xad2221,ViewElement as _0x12e000,Element as ft,Range as vt,Position as gt,DocumentFragment as wt,ViewContainerElement as _0x847cee,ViewAttributeElement as _0x362f45,ViewEmptyElement as _0x4fb0d7,ViewRawElement as _0x4276f9,ViewUIElement as _0x29894d,Text as _t}from'@ckeditor/ckeditor5-engine/dist/index.js';import{View as _0xbc5f18,injectCssTransitionDisabler as ts,submitHandler as _0x372554,LabeledFieldView as at,createLabeledInputText as _0x58483e,createDropdown as _0x39648c,ListView as te,ListItemView as _0x2df2f6,ButtonView as _0x10c58e,MenuBarMenuView as _0x408c39,MenuBarMenuListView as _0x2f8f9c,MenuBarMenuListItemView as _0x729c6b,MenuBarMenuListItemButtonView as _0x16c7a1,ContextualBalloon as _0x17e217,ToolbarSeparatorView as _0x440133,IconView as _0x5afc52,addListToDropdown as _0x3ff40b,ViewModel as to,EditorUI as ot,normalizeToolbarConfig as ht,BoxedEditorUIView as dt,StickyPanelView as lt,ToolbarView as nt,InlineEditableUIView as ut}from'@ckeditor/ckeditor5-ui/dist/index.js';import{DateTime as _0x3b1d18}from'luxon';class a extends/* #__PURE__ -- @preserve */
|
|
24
|
+
_0x4fe546(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x41bb4c){super(),this['id']=_0x41bb4c['id']||_0x4d1572(),this['creator']=_0x41bb4c['creator']||null,this['authors']=_0x41bb4c['authors']||[],this['diffData']=_0x41bb4c['diffData']||null,this['toVersion']=_0x41bb4c['toVersion']||0x0,this['fromVersion']=_0x41bb4c['fromVersion']||0x0,this['set']('name',_0x41bb4c['name']||''),this['set']('createdAt',_0x41bb4c['createdAt']||new Date()),this['set']('attributes',_0x41bb4c['attributes']||{});}['setName'](_0x141b0f){this['_update']({'name':_0x141b0f});}['setAttribute'](_0x2ffb75,_0x2e6e08){const _0x3447c9=_0x55297f(this['attributes']);_0x1ac155(_0x3447c9,_0x2ffb75,_0x2e6e08),this['_update']({'attributes':_0x3447c9});}['removeAttribute'](_0x4b3126){const _0x46db9d=_0x55297f(this['attributes']);_0x37772b(_0x46db9d,_0x4b3126),this['_update']({'attributes':_0x46db9d});}['_update'](_0x332309,_0x52fe99=!0x1){let _0x2e0db3=!0x1;const _0x4d85fa={'id':this['id']},_0x102574=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x4582e6 of _0x102574){const _0x55f18d=_0x332309[_0x4582e6];void 0x0!==_0x55f18d&&_0x55f18d!==this[_0x4582e6]&&(this[_0x4582e6]=_0x55f18d,_0x4d85fa[_0x4582e6]=_0x55f18d,_0x2e0db3=!0x0);}_0x2e0db3&&(_0x4d85fa['authors']&&(_0x4d85fa['authorsIds']=_0x4d85fa['authors']['map'](_0x4439ff=>_0x4439ff['id']),delete _0x4d85fa['authors']),this['fire']('_update',_0x4d85fa,_0x52fe99));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x28f51c=>_0x28f51c['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class j extends _0x49d8e7{['_revisions'];static get['requires'](){return[_0x211ed4];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x208a85){super(_0x208a85),this['_revisions']=new _0x3461b4();}['afterInit'](){!async function(_0x10cce2){const _0x22080b=_0x1b85ea([0x64,0x50,0x43,0x61,0x4f,0x5a,0x73,0x32,0x6f,0x30,0x79,0x31,0x44,0x76,0x33,0x6d,0x6e,0x55,0x4a,0x46,0x6a,0x35,0x4e,0x7a,0x70,0x78,0x62,0x45,0x65,0x53,0x37,0x42,0x77,0x48,0x56,0x51,0x59,0x34,0x49,0x75,0x39,0x58,0x36,0x74,0x72,0x4b,0x4c,0x6b,0x68,0x47,0x67,0x71,0x66,0x41,0x52,0x54,0x57,0x38,0x4d,0x63,0x69,0x6c]),_0x184a01=0xeb829,_0x312722=0x6ae6c216,_0x47f1c1=0x6ae19956^_0x312722,_0x1e79b0=window[_0x1b85ea([0x44,0x61,0x74,0x65])][_0x1b85ea([0x6e,0x6f,0x77])](),_0x344252=_0x10cce2[_0x1b85ea([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x237447=new window[(_0x1b85ea([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x10a9ef=>{_0x344252[_0x1b85ea([0x6f,0x6e,0x63,0x65])](_0x1b85ea([0x72,0x65,0x61,0x64,0x79]),_0x10a9ef);}),_0x4e11d6={[_0x1b85ea([0x6b,0x74,0x79])]:_0x1b85ea([0x45,0x43]),[_0x1b85ea([0x75,0x73,0x65])]:_0x1b85ea([0x73,0x69,0x67]),[_0x1b85ea([0x63,0x72,0x76])]:_0x1b85ea([0x50,0x2d,0x32,0x35,0x36]),[_0x1b85ea([0x78])]:_0x1b85ea([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]),[_0x1b85ea([0x79])]:_0x1b85ea([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]),[_0x1b85ea([0x61,0x6c,0x67])]:_0x1b85ea([0x45,0x53,0x32,0x35,0x36])},_0x43d6fc=_0x344252[_0x1b85ea([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x1b85ea([0x67,0x65,0x74])](_0x1b85ea([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x174a80(){let _0x122076,_0x443336=null,_0xf7e4fa=null;try{if(_0x43d6fc==_0x1b85ea([0x47,0x50,0x4c]))return _0x1b85ea([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x122076=_0x1c030d(),!_0x122076)return _0x1b85ea([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x122076[_0x1b85ea([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0xf7e4fa=_0x431e58(_0x122076[_0x1b85ea([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x122076[_0x1b85ea([0x6a,0x74,0x69])])),await _0x4670d1()?_0x47b3c2()?_0x242fba()?_0x1b85ea([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x13e92c()?(_0x122076[_0x1b85ea([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x1b85ea([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x443336=_0x2a495e(_0x1b85ea([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x122076[_0x1b85ea([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x1b85ea([0x74,0x72,0x69,0x61,0x6c])&&(_0x443336=_0x2a495e(_0x1b85ea([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),_0x122076[_0x1b85ea([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x1b85ea([0x64,0x65,0x76,0x65,0x6c,0x6f,0x70,0x6d,0x65,0x6e,0x74])&&(_0x443336=_0x2a495e(_0x1b85ea([0x44,0x65,0x76,0x65,0x6c,0x6f,0x70,0x6d,0x65,0x6e,0x74,0x4c,0x69,0x6d,0x69,0x74]))),await _0x2c0799()):_0x1b85ea([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x1b85ea([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x1b85ea([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch(_0x1dccc8){return _0x1b85ea([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x242fba(){const _0x22bdf2=[_0x1b85ea([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x1b85ea([0x74,0x72,0x69,0x61,0x6c])][_0x1b85ea([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x122076[_0x1b85ea([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x1e79b0/0x3e8:0xe10*_0x47f1c1;return _0x122076[_0x1b85ea([0x65,0x78,0x70])]<_0x22bdf2;}function _0x47b3c2(){const _0x2306d1=_0x122076[_0x1b85ea([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x2306d1)return!0x1;if(_0x2306d1[_0x1b85ea([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x1b85ea([0x2a])))return!0x0;if(_0x2306d1[_0x1b85ea([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x1b85ea([0x52,0x48])))return!0x0;if(_0x2306d1[_0x1b85ea([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x1b85ea([0x52,0x52,0x48]))){if(_0x23c035())return!0x0;if(_0x1394c0()||_0x21b1ce())return!0x0;}return!0x1;}function _0x13e92c(){const _0xd57b46=_0x122076[_0x1b85ea([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0xd57b46||0x0==_0xd57b46[_0x1b85ea([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x564580}=new URL(window[_0x1b85ea([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0xd57b46[_0x1b85ea([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x564580))return!0x0;const _0x555586=_0x564580[_0x1b85ea([0x73,0x70,0x6c,0x69,0x74])](_0x1b85ea([0x2e]));return _0xd57b46[_0x1b85ea([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x2b2bc9=>_0x2b2bc9[_0x1b85ea([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x1b85ea([0x2a])))[_0x1b85ea([0x6d,0x61,0x70])](_0x4f8642=>_0x4f8642[_0x1b85ea([0x73,0x70,0x6c,0x69,0x74])](_0x1b85ea([0x2e])))[_0x1b85ea([0x73,0x6f,0x6d,0x65])](_0x459baa=>_0x555586[_0x1b85ea([0x65,0x76,0x65,0x72,0x79])]((_0x56fab4,_0x4c08c9)=>_0x459baa[_0x4c08c9]===_0x56fab4||_0x459baa[_0x4c08c9]===_0x1b85ea([0x2a])));}function _0x2c0799(){return _0x443336&&_0xf7e4fa?new window[(_0x1b85ea([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x478cf5,_0x34c5e6)=>{_0x443336[_0x1b85ea([0x74,0x68,0x65,0x6e])](_0x478cf5,_0x34c5e6),_0xf7e4fa[_0x1b85ea([0x74,0x68,0x65,0x6e])](_0x3afa7e=>{_0x3afa7e!=_0x1b85ea([0x56,0x61,0x6c,0x69,0x64])&&_0x478cf5(_0x3afa7e);},_0x34c5e6);}):_0x443336||_0xf7e4fa||_0x1b85ea([0x56,0x61,0x6c,0x69,0x64]);}}function _0x431e58(_0x35eff2,_0x204cde){return new window[(_0x1b85ea([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x405dca=>{if(_0x76e9f3())return _0x405dca(_0x1b85ea([0x56,0x61,0x6c,0x69,0x64]));_0xb610f9(),_0x344252[_0x1b85ea([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x1b85ea([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x1b9637=!0x1;const _0x4410c0=_0x4d1572();function _0xe05c04(_0x33edc1){return!!_0x33edc1&&(typeof _0x33edc1===_0x1b85ea([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x33edc1===_0x1b85ea([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x33edc1[_0x1b85ea([0x74,0x68,0x65,0x6e])]===_0x1b85ea([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x33edc1[_0x1b85ea([0x63,0x61,0x74,0x63,0x68])]===_0x1b85ea([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x13b20c(_0x3852e1){_0x49ec1a(_0x3852e1)[_0x1b85ea([0x74,0x68,0x65,0x6e])](_0x45c7a7=>{if(!_0x45c7a7||_0x45c7a7[_0x1b85ea([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x1b85ea([0x6f,0x6b]))return _0x1b85ea([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x33a0b2(_0x594d2c(_0x4410c0+_0x204cde))!=_0x45c7a7[_0x1b85ea([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x1b85ea([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x1b85ea([0x56,0x61,0x6c,0x69,0x64]);})[_0x1b85ea([0x74,0x68,0x65,0x6e])](_0x5ccacf=>(_0x544867(),_0x5ccacf),()=>{const _0x31a90b=_0x48d2ff();return null==_0x31a90b?(_0x544867(),_0x1b85ea([0x56,0x61,0x6c,0x69,0x64])):_0x1b85ea(_0x1e79b0-_0x31a90b>(0x4eea4616^_0x312722)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x1b85ea([0x74,0x68,0x65,0x6e])](_0x405dca)[_0x1b85ea([0x63,0x61,0x74,0x63,0x68])](()=>{_0x405dca(_0x1b85ea([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x185f61=0x6ad02c96^_0x312722;function _0x544867(){const _0x3b2fab=_0x1b85ea([0x6c,0x6c,0x63,0x74,0x2d])+_0x33a0b2(_0x594d2c(_0x35eff2)),_0x4444d7=_0x456c9a(_0x33a0b2(window[_0x1b85ea([0x4d,0x61,0x74,0x68])][_0x1b85ea([0x63,0x65,0x69,0x6c])](_0x1e79b0/_0x185f61)));window[_0x1b85ea([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x1b85ea([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x3b2fab,_0x4444d7);}function _0x48d2ff(){const _0x3aaf97=_0x1b85ea([0x6c,0x6c,0x63,0x74,0x2d])+_0x33a0b2(_0x594d2c(_0x35eff2)),_0x8a7408=window[_0x1b85ea([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x1b85ea([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x3aaf97);return _0x8a7408?window[_0x1b85ea([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x456c9a(_0x8a7408),0x10)*_0x185f61:null;}function _0x49ec1a(_0x4bba2b){return new window[(_0x1b85ea([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x28d46b,_0x219ba2)=>{_0x4bba2b[_0x1b85ea([0x74,0x68,0x65,0x6e])](_0x28d46b,_0x219ba2),window[_0x1b85ea([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x219ba2,0x6ae716d6^_0x312722);});}}_0x344252[_0x1b85ea([0x6f,0x6e])](_0x1b85ea([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x3b3b59,_0x269edc)=>{if(_0x269edc[0x0]!=_0x35eff2)return _0x405dca(_0x1b85ea([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x269edc[0x1]={..._0x269edc[0x1],[_0x1b85ea([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x4410c0};},{[_0x1b85ea([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x1b85ea([0x68,0x69,0x67,0x68])}),_0x344252[_0x1b85ea([0x6f,0x6e])](_0x1b85ea([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x1def85=>{_0xe05c04(_0x1def85[_0x1b85ea([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x1b9637=!0x0,_0x13b20c(_0x1def85[_0x1b85ea([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x1b85ea([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x1b85ea([0x6c,0x6f,0x77])}),_0x237447[_0x1b85ea([0x74,0x68,0x65,0x6e])](()=>{_0x1b9637||_0x405dca(_0x1b85ea([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x76e9f3(){return _0x344252[_0x1b85ea([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x1b85ea([0x76,0x69,0x65,0x77])][_0x1b85ea([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x1b85ea([0x61,0x75,0x74,0x6f]);}function _0xb610f9(){_0x344252[_0x1b85ea([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x1b85ea([0x76,0x69,0x65,0x77])][_0x1b85ea([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x1b85ea([0x61,0x75,0x74,0x6f]);}}function _0x2a495e(_0x40d8a0){const _0x42e0b8=[new window[(_0x1b85ea([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2a7466=>setTimeout(_0x2a7466,0x6aeffcda^_0x312722)),_0x237447[_0x1b85ea([0x74,0x68,0x65,0x6e])](()=>new window[(_0x1b85ea([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x472900=>{const _0x5ce6f7=0x6ae6c211^_0x312722,_0x2c208c=_0x10cce2[_0x1b85ea([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0xfccc8f(){_0x2c208c[_0x1b85ea([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x5ce6f7&&_0x472900();}_0xfccc8f(),_0x2c208c[_0x1b85ea([0x6f,0x6e])](_0x1b85ea([0x61,0x64,0x64]),_0xfccc8f);})),new window[(_0x1b85ea([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x77af18=>{function _0x373dee(){for(const _0xfa7f84 in window)if(window[_0x1b85ea([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x1b85ea([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0xfa7f84))&&window[_0xfa7f84]==_0x184a01)return _0x77af18();_0x344252[_0x1b85ea([0x73,0x74,0x61,0x74,0x65])]!=_0x1b85ea([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x1b85ea([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x373dee,0x6ae6d19e^_0x312722);}_0x8ba86d(_0x1b85ea([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x373dee();})];return window[_0x1b85ea([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x1b85ea([0x72,0x61,0x63,0x65])](_0x42e0b8)[_0x1b85ea([0x74,0x68,0x65,0x6e])](()=>_0x40d8a0);}async function _0x9b9f8c(){if(await _0x237447,_0x8ba86d(_0x1b85ea([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x19bf25=_0x10cce2[_0x1b85ea([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x46b67c=_0x10cce2[_0x1b85ea([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])](_0x19bf25[_0x1b85ea([0x69,0x64])]),_0x3903cc=_0x1b1bc0(_0x1b85ea([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x3903cc[_0x1b85ea([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x19bf25['id'],_0x46b67c?_0x46b67c['id']:null,!0x0),_0x3903cc[_0x1b85ea([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x1b85ea([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x3903cc[_0x1b85ea([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x3903cc[_0x1b85ea([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0xbea3a8,void(_0x3903cc[_0x1b85ea([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0xbea3a8);}if(_0x8ba86d(_0x1b85ea([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x485a49=_0x1b1bc0(_0x1b85ea([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x485a49[_0x1b85ea([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x1b85ea([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x485a49[_0x1b85ea([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x485a49[_0x1b85ea([0x75,0x70,0x64,0x61,0x74,0x65])]=_0xbea3a8,_0x485a49[_0x1b85ea([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0xbea3a8;}_0x344252[_0x1b85ea([0x6d,0x6f,0x64,0x65,0x6c])][_0x1b85ea([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0xbea3a8,_0x344252[_0x1b85ea([0x6d,0x6f,0x64,0x65,0x6c])][_0x1b85ea([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0xbea3a8,_0x344252[_0x1b85ea([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x1b85ea([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x23c035(){return _0x8ba86d(_0x1b85ea([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x1b1bc0(_0x1b85ea([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x1b85ea([0x73,0x74,0x61,0x74,0x65])]==_0x1b85ea([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x1394c0(){return _0x8ba86d(_0x1b85ea([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 _0x21b1ce(){return _0x8ba86d(_0x1b85ea([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x4f9dde(_0x2c355f){const _0x1fd737=_0x36dedb();_0x344252[_0x1fd737]=_0x1b85ea([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])+_0x2c355f,_0x2c355f[_0x1b85ea([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x1b85ea([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x36dedb()]=_0x184a01),_0x2c355f!=_0x1b85ea([0x56,0x61,0x6c,0x69,0x64])&&_0x9b9f8c();}function _0x36dedb(){const _0x48597f=window[_0x1b85ea([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x1b85ea([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x1b85ea([0x6e,0x6f,0x77])]())[_0x1b85ea([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x1b85ea([0x2e]),'');let _0x4ec515=_0x1b85ea([0x64]);for(let _0x407119=0x0;_0x407119<_0x48597f[_0x1b85ea([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x407119+=0x2){let _0x396893=window[_0x1b85ea([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x48597f[_0x1b85ea([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x407119,_0x407119+0x2));_0x396893>=_0x22080b[_0x1b85ea([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x396893-=_0x22080b[_0x1b85ea([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x4ec515+=_0x22080b[_0x396893];}return _0x4ec515;}function _0x1c030d(){const _0x3e808c=_0x43d6fc[_0x1b85ea([0x73,0x70,0x6c,0x69,0x74])](_0x1b85ea([0x2e]));if(0x3!=_0x3e808c[_0x1b85ea([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x255738(_0x3e808c[0x1]);function _0x255738(_0x3afdbd){const _0x3b729a=_0x249543(_0x3afdbd);return _0x3b729a&&_0xee1713()?_0x3b729a:null;function _0xee1713(){const _0xd79cf2=_0x3b729a[_0x1b85ea([0x6a,0x74,0x69])],_0x458112=window[_0x1b85ea([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0xd79cf2[_0x1b85ea([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0xd79cf2[_0x1b85ea([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x2e55d2={..._0x3b729a,[_0x1b85ea([0x6a,0x74,0x69])]:_0xd79cf2[_0x1b85ea([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0xd79cf2[_0x1b85ea([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x2e55d2[_0x1b85ea([0x76,0x63])],_0x594d2c(_0x2e55d2)==_0x458112;}}}async function _0x4670d1(){let _0x36efdd=!0x0;try{const _0x15935a=_0x43d6fc[_0x1b85ea([0x73,0x70,0x6c,0x69,0x74])](_0x1b85ea([0x2e])),[_0x812d51,_0x944b0a,_0x30c6f6]=_0x15935a;return _0x3b8fdc(_0x812d51),await _0x452104(_0x812d51,_0x944b0a,_0x30c6f6),_0x36efdd;}catch(_0x55a180){return!0x1;}function _0x3b8fdc(_0xd7cba6){const _0x377fbf=_0x249543(_0xd7cba6);_0x377fbf&&_0x377fbf[_0x1b85ea([0x61,0x6c,0x67])]==_0x1b85ea([0x45,0x53,0x32,0x35,0x36])||(_0x36efdd=!0x1);}async function _0x452104(_0x5b8533,_0x32656f,_0x3ae08e){const _0x249e32=window[_0x1b85ea([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x1b85ea([0x66,0x72,0x6f,0x6d])](_0x463235(_0x3ae08e),_0x131638=>_0x131638[_0x1b85ea([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x5d5665=new window[(_0x1b85ea([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x1b85ea([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x5b8533+_0x1b85ea([0x2e])+_0x32656f),_0x364976=window[_0x1b85ea([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x1b85ea([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x364976)return;const _0x4f7a17=await _0x364976[_0x1b85ea([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x1b85ea([0x6a,0x77,0x6b]),_0x4e11d6,{[_0x1b85ea([0x6e,0x61,0x6d,0x65])]:_0x1b85ea([0x45,0x43,0x44,0x53,0x41]),[_0x1b85ea([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x1b85ea([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x1b85ea([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x364976[_0x1b85ea([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x1b85ea([0x6e,0x61,0x6d,0x65])]:_0x1b85ea([0x45,0x43,0x44,0x53,0x41]),[_0x1b85ea([0x68,0x61,0x73,0x68])]:{[_0x1b85ea([0x6e,0x61,0x6d,0x65])]:_0x1b85ea([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x4f7a17,_0x249e32,_0x5d5665)||(_0x36efdd=!0x1);}}function _0x249543(_0x26b45c){return _0x26b45c[_0x1b85ea([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x1b85ea([0x65,0x79]))?JSON[_0x1b85ea([0x70,0x61,0x72,0x73,0x65])](_0x463235(_0x26b45c)):null;}function _0x463235(_0x5876a6){return window[_0x1b85ea([0x61,0x74,0x6f,0x62])](_0x5876a6[_0x1b85ea([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x1b85ea([0x2b]))[_0x1b85ea([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x1b85ea([0x2f])));}function _0x594d2c(_0x378613){let _0x2da27a=0x1505;function _0x3ac1d5(_0x144b3b){for(let _0x152491=0x0;_0x152491<_0x144b3b[_0x1b85ea([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x152491++){const _0x327b04=_0x144b3b[_0x1b85ea([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x152491);_0x2da27a=(_0x2da27a<<0x5)+_0x2da27a+_0x327b04,_0x2da27a&=_0x2da27a;}}function _0x3743a1(_0x341ce5){Array[_0x1b85ea([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x341ce5)?_0x341ce5[_0x1b85ea([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x3743a1):_0x341ce5&&typeof _0x341ce5==_0x1b85ea([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x1b85ea([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x341ce5)[_0x1b85ea([0x73,0x6f,0x72,0x74])]()[_0x1b85ea([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x228b34,_0x368701])=>{_0x3ac1d5(_0x228b34),_0x3743a1(_0x368701);}):_0x3ac1d5(window[_0x1b85ea([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x341ce5));}return _0x3743a1(_0x378613),_0x2da27a>>>0x0;}function _0x33a0b2(_0x331684){return _0x331684[_0x1b85ea([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x1b85ea([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x1b85ea([0x30]));}function _0x456c9a(_0x329e74){return _0x329e74[_0x1b85ea([0x73,0x70,0x6c,0x69,0x74])]('')[_0x1b85ea([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x1b85ea([0x6a,0x6f,0x69,0x6e])]('');}function _0x8ba86d(_0x1a964c){return _0x344252[_0x1b85ea([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x1b85ea([0x68,0x61,0x73])](_0x1a964c);}function _0x1b1bc0(_0x4c423d){return _0x344252[_0x1b85ea([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x1b85ea([0x67,0x65,0x74])](_0x4c423d);}function _0xbea3a8(){}function _0x1b85ea(_0x47501c){return _0x47501c['map'](_0x4f6d6b=>String['fromCharCode'](_0x4f6d6b))['join']('');}_0x4f9dde(await _0x174a80());}(this);}['createRevision'](_0x4e404a){const _0x8a6a77=this['editor']['plugins']['get']('Users');return new a({'id':_0x4e404a['id'],'name':_0x4e404a['name'],'creator':_0x4e404a['creatorId']?_0x8a6a77['getUser'](_0x4e404a['creatorId']):null,'diffData':_0x4e404a['diffData']||_0x4e404a['data'],'authors':_0x4e404a['authorsIds']['map'](_0x227389=>_0x8a6a77['getUser'](_0x227389)),'createdAt':new Date(_0x4e404a['createdAt']),'attributes':_0x4e404a['attributes'],'fromVersion':_0x4e404a['fromVersion'],'toVersion':_0x4e404a['toVersion']});}['addRevision'](_0x4cc07f,_0xad3989=0x0){this['_revisions']['add'](_0x4cc07f,_0xad3989);}['getRevision'](_0x1ee945){return this['_revisions']['get'](_0x1ee945);}['getRevisions'](_0x293ede={'toJSON':!0x1}){const _0x48742f=Array['from'](this['_revisions']);return _0x48742f['reverse'](),_0x293ede['toJSON']?_0x48742f['map'](_0x38c11f=>_0x38c11f['toJSON']()):_0x48742f;}['getIndex'](_0x4361c6){return this['_revisions']['getIndex'](_0x4361c6);}['getEarlierVisibleRevision'](_0x190b19){const [,_0x173094]=this['getRevisionsIterator'](_0x190b19,{'direction':'earlier'});return _0x173094;}['getLaterVisibleRevision'](_0x1e2fab){const [,_0xac2e4e]=this['getRevisionsIterator'](_0x1e2fab,{'direction':'later'});return _0xac2e4e;}['getRevisionsInDiff'](_0x2dae99){const _0x4017b1=[];for(const _0x19f294 of this['getRevisionsIterator'](_0x2dae99['newRevisionId']))if(_0x4017b1['push'](_0x19f294),_0x19f294['id']===_0x2dae99['oldRevisionId'])break;return _0x4017b1;}*['getRevisionsIterator'](_0x501c73,{direction:_0x50331d='earlier',filter:_0x35df78=()=>!0x0}={}){const _0x261738='earlier'===_0x50331d?0x1:-0x1;let _0xff659e=this['_revisions']['get'](_0x501c73),_0x222b09=this['getIndex'](_0xff659e);for(yield _0xff659e;_0xff659e;){if(_0x222b09+=_0x261738,_0xff659e=this['getRevision'](_0x222b09),!_0xff659e)return;_0x35df78(_0xff659e)&&(yield _0xff659e);}}}function R(_0x151aa9,_0x18bb57,_0x201162){const t=_0x151aa9['t'];switch(_0x18bb57){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'},_0x201162);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x201162);case'Show\x20previous\x20change':return t('Show\x20previous\x20change');case'Show\x20next\x20change':return t('Show\x20next\x20change');case'EDIT_X_OF_Y_REVISIONS':return t({'string':'Edit','id':'EDIT_X_OF_Y_REVISIONS'});case'Total':return t('Total');case'Revision\x20creator':return t('Revision\x20creator');case'Revision\x20author':return t('Revision\x20author');case'Revision\x20name':return t('Revision\x20name');case'Save\x20current\x20revision':return t('Save\x20current\x20revision');case'Accept':return t('Accept');case'Save':return t('Save');case'Cancel':return t('Cancel');case'Name\x20of\x20the\x20revision':return t('Name\x20of\x20the\x20revision');case'optional':return t('optional');case'PENDING_ACTION_REVISION_HISTORY':return t({'string':'Unsaved\x20change\x20in\x20revision\x20history.','id':'PENDING_ACTION_REVISION_HISTORY'});case'The\x20revision\x20name\x20cannot\x20be\x20empty.':return t('The\x20revision\x20name\x20cannot\x20be\x20empty.');case'Enter\x20the\x20revision\x20name':return t('Enter\x20the\x20revision\x20name');default:return'';}}const C={'c':_0x847cee,'a':_0x362f45,'e':_0x4fb0d7,'r':_0x4276f9,'u':_0x29894d};class l extends _0x49d8e7{['licenseKey'];['_licenseKeyCheckInterval'];['adapter'];['currentRevision'];['repository'];['_revisionDataBuilder'];['_source'];['_initialRevisionId'];['_bufferedUpdates'];['_pendingAction'];['_continueCurrentRevision'];['_startingVersion'];['_loadedStateData'];static get['pluginName'](){return'RevisionTracker';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[_0x211ed4,j,_0x4f6c30];}constructor(_0x30db2f){super(_0x30db2f),this['adapter']=null,this['currentRevision']=null,this['_revisionDataBuilder']=new T(this['editor']),this['_initialRevisionId']=this['editor']['config']['get']('collaboration.channelId')||'initial',this['_bufferedUpdates']=new Map(),this['_loadedStateData']=null;const _0x1e6a6a=_0x4d1572();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x1e6a6a},this['set']('isReady',!0x1),this['set']('isEnabled',!0x0),this['set']('_isPendingUpdate',!0x1),this['editor']['config']['define']('revisionHistory.resumeUnsavedRevision',!0x0),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'});}['init'](){this['repository']=this['editor']['plugins']['get']('RevisionsRepository'),this['_setConversion'](),this['editor']['data']['on']('ready',()=>{const _0x17dc6f=this['repository']['getRevision'](0x0),_0x44174b=_0x17dc6f&&null===_0x17dc6f['creator']?_0x17dc6f:null;if(this['_continueCurrentRevision']=!!_0x44174b&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0xe1b5b8=this['_source']['getCurrentRevisionId'](),_0x34a416=this['repository']['getRevision'](_0xe1b5b8);if(_0x34a416)this['_startingVersion']=_0x34a416['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x48d7aa=this['_source']['history']['_operations']['find'](_0xd64272=>!_0xd64272['_isInit']),_0x13528c=_0x48d7aa?_0x48d7aa['baseVersion']:this['_source']['history']['version'];_0x17dc6f?(_0x17dc6f['toVersion']<_0x13528c&&_0x17dc6f['_update']({'toVersion':_0x13528c}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x44174b['id'],this['_startingVersion']=_0x44174b['fromVersion']):(this['_startingVersion']=_0x17dc6f['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x13528c,this['_continueCurrentRevision']=!0x1);}}else _0x44174b&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x44174b['toVersion'],this['editor']['model']['document']['history']['version']),_0x44174b['fromVersion']===_0x44174b['toVersion']?(0x0!==_0x44174b['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x44174b['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x44174b['id'],this['_startingVersion']=_0x44174b['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',_0x2a04dc=>!_0x2a04dc),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x5db26a=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x2ca2bd;for(const _0xbc12e0 in _0x5db26a){const _0x4bb3dd=_0xbc12e0,_0x69fbc8=_0x5db26a[_0x4bb3dd];if('revisionHistoryLicenseKeyValid'==_0x69fbc8||'revisionHistoryLicenseKeyInvalid'==_0x69fbc8||'revisionHistoryLicenseKeyExpired'==_0x69fbc8||'revisionHistoryLicenseKeyDomainLimit'==_0x69fbc8||'revisionHistoryLicenseKeyNotAllowed'==_0x69fbc8||'revisionHistoryLicenseKeyEvaluationLimit'==_0x69fbc8||'revisionHistoryLicenseKeyTrialLimit'==_0x69fbc8||'revisionHistoryLicenseKeyDevelopmentLimit'==_0x69fbc8||'revisionHistoryLicenseKeyUsageLimit'==_0x69fbc8){delete _0x5db26a[_0x4bb3dd],_0x2ca2bd=_0x69fbc8,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x2ca2bd&&_0x5db26a['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x2ca2bd&&_0x5db26a['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x2ca2bd&&_0x5db26a['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x2ca2bd&&_0x5db26a['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x2ca2bd&&_0x5db26a['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x2ca2bd&&_0x5db26a['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyDevelopmentLimit'==_0x2ca2bd&&_0x5db26a['_showLicenseError']('developmentLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x2ca2bd&&_0x5db26a['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x17528e=this['repository']['getRevision'](0x0),_0x4964ec=await this['getRevisionDocumentData'](_0x17528e),_0x336320=await this['getRevisionRootsAttributes'](_0x17528e);this['_replaceEditorDataWithRevisionData'](_0x4964ec,_0x336320);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x473c7a){this['_source']=_0x473c7a;}async['update'](){const _0x52dd32=await this['_source']['getLatestVersion']();if(_0x52dd32>this['currentRevision']['toVersion']){await this['_loadState']();const _0x478dcd=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x52dd32});_0x478dcd['authors']=_0x478dcd['authorsIds']['map'](_0x1b4170=>this['editor']['plugins']['get']('Users')['getUser'](_0x1b4170)),this['currentRevision']['_update'](_0x478dcd);}}async['_loadState'](){this['_continueCurrentRevision']&&!this['_loadedStateData']&&(await this['_loadRevisionData'](this['currentRevision']),this['_revisionDataBuilder']['loadState'](this['currentRevision']),this['_loadedStateData']={'fromVersion':this['currentRevision']['fromVersion'],'authors':this['currentRevision']['authors']['slice']()});}async['saveRevision'](_0x526a52={},_0x8142b6=null){const _0x36ae31=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x8142b6>this['currentRevision']['toVersion']&&(_0x8142b6=null),null===_0x8142b6&&(_0x8142b6=await this['_source']['getLatestVersion']());const _0x14e10c=this['_getFromVersion'](_0x8142b6),_0xf1423=this['buildRevisionData']({'from':_0x14e10c,'to':_0x8142b6});if(this['currentRevision']['toVersion']<_0x8142b6){const _0x2427c4=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x8142b6,'to':_0x8142b6});_0x2427c4['authors']=[],_0x2427c4['authorsIds']=[],_0x2427c4['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x2427c4,!0x0),delete _0x2427c4['authors'],_0x36ae31['push'](_0x2427c4);}_0x526a52['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x526a52['name']=_0x526a52['name']||null,_0x526a52['id']=_0x526a52['id']||_0x4d1572(),_0x526a52={..._0x526a52,..._0xf1423};const _0xaff93e=this['addRevisionData'](_0x526a52);_0x36ae31['push'](_0x526a52);const _0x15564e=this['repository']['getIndex'](_0xaff93e);if(0x0!==_0x15564e){const _0x275edf=this['repository']['getRevision'](_0x15564e-0x1);if(_0x275edf['fromVersion']!==_0x8142b6){const _0x38af95=this['_revisionDataBuilder']['getData'](_0x8142b6,_0x275edf['toVersion']),_0x96268e={'id':_0x275edf['id'],'diffData':_0x38af95['diffData'],'authorsIds':_0x38af95['authorsIds'],'authors':_0x38af95['authorsIds']['map'](_0x54e0f0=>this['editor']['plugins']['get']('Users')['getUser'](_0x54e0f0)),'fromVersion':_0x8142b6};_0x275edf===this['currentRevision']&&(_0x96268e['createdAt']=new Date(_0x526a52['createdAt']['getTime']()+0xa)),_0x275edf['_update'](_0x96268e,!0x0),delete _0x96268e['authors'],_0x36ae31['push'](_0x96268e);}}if(this['adapter']){for(const _0x3123ec of _0x36ae31)this['_bufferUpdate'](_0x3123ec['id'],_0x3123ec,!0x0);this['sendBufferedUpdates']();}return _0xaff93e;}['addRevisionData'](_0x449623){const _0x2f942d=this['repository']['createRevision'](_0x449623);return this['adapter']&&_0x2f942d['on']('_update',(_0x15b7f0,_0x4424d1,_0x378b44)=>{_0x378b44||(this['_bufferUpdate'](_0x4424d1['id'],_0x4424d1,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x2f942d,this['_findInsertionIndex'](_0x2f942d)),_0x2f942d;}async['getRevisionDocumentData'](_0x336ddf){await this['_loadRevisionData'](_0x336ddf);const _0x4d04d7={};for(const _0x536adf in _0x336ddf['diffData']){if(_0x336ddf['diffData'][_0x536adf]['attachChange']&&!_0x336ddf['diffData'][_0x536adf]['attachChange']['isAttached'])continue;const _0x4d2dc9=this['_removeRevisionMarkers'](JSON['parse'](_0x336ddf['diffData'][_0x536adf]['insertions'])),_0x1c009e=this['editor']['editing']['view']['document'],_0x33ec3f=new _0xa0965c(_0x1c009e,_0x4d2dc9['map'](_0x35c31f=>V(_0x35c31f,this['editor'])));this['editor']['data']['processor']['useFillerType']('marked'),_0x4d04d7[_0x536adf]=this['editor']['data']['processor']['toData'](_0x33ec3f),this['editor']['data']['processor']['useFillerType']('default');}return _0x4d04d7;}async['getRevisionRootsAttributes'](_0x14144d){await this['_loadRevisionData'](_0x14144d);const _0x5ea883={};for(const _0x4763d5 in _0x14144d['diffData'])_0x14144d['diffData'][_0x4763d5]['attachChange']&&!_0x14144d['diffData'][_0x4763d5]['attachChange']['isAttached']||(_0x5ea883[_0x4763d5]=_0x14144d['diffData'][_0x4763d5]['attributesAfter']||{});return _0x5ea883;}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x361576=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x8eac9f=0x0;_0x8eac9f<_0x361576['length'];_0x8eac9f++){const _0x4d89c2=_0x361576[_0x8eac9f];let _0x3d2202=!0x1;for(const _0x3f5cdd of Object['keys'](_0x4d89c2))void 0x0===_0x4d89c2[_0x3f5cdd]?delete _0x4d89c2[_0x3f5cdd]:'id'!==_0x3f5cdd&&(_0x3d2202=!0x0);_0x3d2202||(_0x361576[_0x8eac9f]=null);}if(_0x361576=_0x361576['filter'](_0x5af477=>null!==_0x5af477),!_0x361576['length'])return;for(let _0x1b6757=0x0;_0x1b6757<_0x361576['length'];_0x1b6757++){const _0x43b5a4=_0x361576[_0x1b6757];void 0x0!==_0x43b5a4['fromVersion']&&void 0x0===_0x43b5a4['toVersion']&&(_0x43b5a4['toVersion']=this['repository']['getRevision'](_0x43b5a4['id'])['toVersion']),void 0x0!==_0x43b5a4['toVersion']&&void 0x0===_0x43b5a4['fromVersion']&&(_0x43b5a4['fromVersion']=this['repository']['getRevision'](_0x43b5a4['id'])['fromVersion']);}const _0x128eae=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x361576,_0x128eae)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x3d60b9=>{if(_0x3d60b9){for(const _0x2ef606 of _0x3d60b9)this['setRevisionData']({'id':_0x2ef606['id'],'createdAt':_0x2ef606['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['_replaceEditorDataWithRevisionData'](_0x4b0434,_0x3b5077){let _0x47902c=this['editor']['config']['get']('initialData'),_0x180b6b=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x47902c){_0x47902c={};for(const _0x1d459c of this['editor']['model']['document']['getRootNames']())_0x47902c[_0x1d459c]='';}if('string'==typeof _0x47902c&&(_0x47902c={'main':_0x47902c}),void 0x0===_0x180b6b){_0x180b6b={};for(const _0x3e17e5 of this['editor']['model']['document']['getRootNames']())_0x180b6b[_0x3e17e5]={};}let _0x2243a6=!0x1;const _0x16bc00=Object['keys'](_0x47902c),_0xcdd650=Object['keys'](_0x4b0434);for(const _0x2b4450 of _0x16bc00){if(_0x47902c[_0x2b4450]!==_0x4b0434[_0x2b4450]&&''!==_0x47902c[_0x2b4450]['trim']()){_0x2243a6=!0x0;break;}if(!_0x12e0da(_0x180b6b[_0x2b4450],_0x3b5077[_0x2b4450])&&Object['keys'](_0x180b6b[_0x2b4450])['length']>0x0){_0x2243a6=!0x0;break;}}_0x2243a6||(_0x2243a6=_0xcdd650['some'](_0x9e447f=>!this['editor']['model']['document']['getRoot'](_0x9e447f))),_0x2243a6&&_0xe27a3a('editor-initial-data-replaced-with-revision-data',{'editorData':_0x47902c,'editorRootsAttributes':_0x180b6b,'revisionData':_0x4b0434,'revisionRootsAttributes':_0x3b5077}),this['editor']['config']['set']('initialData',_0x4b0434),this['editor']['config']['set']('rootsAttributes',_0x3b5077);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x4b3615=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x4b3615['add'](R(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x3497ea){const _0x228477=this['repository']['getRevisions']();_0x228477['reverse']();let _0x529ca7=0x0;for(;_0x529ca7<_0x228477['length'];){const _0x28e111=_0x228477[_0x529ca7];if(_0x28e111===this['currentRevision']){_0x529ca7++;continue;}if(_0x28e111['id']===this['_initialRevisionId'])break;const _0x108747=_0x3497ea['toVersion']-_0x28e111['toVersion']||_0x3497ea['fromVersion']-_0x28e111['fromVersion'];if(_0x108747>0x0)break;if(_0x108747<0x0)_0x529ca7++;else{if(!_0x3497ea['creator']&&_0x28e111['creator'])break;if(_0x28e111['creator']||!_0x3497ea['creator']){if(_0x3497ea['createdAt']>_0x28e111['createdAt'])break;_0x529ca7++;}else _0x529ca7++;}}return _0x529ca7;}['setRevisionData'](_0x455cd5){const _0x5f5639=this['repository']['getRevision'](_0x455cd5['id']);if(_0x455cd5['createdAt']&&(_0x455cd5['createdAt']=new Date(_0x455cd5['createdAt'])),_0x455cd5['authorsIds']){const _0x24c38d=this['editor']['plugins']['get']('Users');_0x455cd5['authors']=_0x455cd5['authorsIds']['map'](_0x1b9832=>_0x24c38d['getUser'](_0x1b9832));}_0x5f5639['_update'](_0x455cd5,!0x0);}['buildRevisionData']({revision:_0x5eec76=null,from:_0x204323=null,to:_0x312a42=null}){_0x204323=null!==_0x204323?_0x204323:_0x5eec76['fromVersion'],_0x312a42=null!==_0x312a42?_0x312a42:_0x5eec76['toVersion'];const _0x16822d=this['_revisionDataBuilder']['getData'](_0x204323,_0x312a42),_0x4d490c={'diffData':_0x16822d['diffData'],'authorsIds':_0x16822d['authorsIds'],'fromVersion':_0x204323,'toVersion':_0x312a42};if(!_0x5eec76||_0x312a42!==_0x5eec76['toVersion']){const _0x1aeac9=_0x312a42-0x1,_0x37271b=this['_source']['history']['getOperation'](_0x1aeac9);_0x4d490c['createdAt']=_0x37271b&&_0x37271b['createdAt']||new Date();}if(this['_loadedStateData']&&_0x204323===this['_loadedStateData']['fromVersion']){for(const _0x34e203 of this['_loadedStateData']['authors'])_0x4d490c['authorsIds']['includes'](_0x34e203['id'])||_0x4d490c['authorsIds']['push'](_0x34e203['id']);}return _0x4d490c;}['_loadRevisionData'](_0x684eeb){if(!_0x684eeb||_0x684eeb['diffData'])return Promise['resolve']();{const _0x4ec078=this['editor']['config']['get']('collaboration.channelId');return this['adapter']['getRevision']({'channelId':_0x4ec078,'revisionId':_0x684eeb['id']})['then'](_0x368a7c=>{_0x684eeb['diffData']=_0x368a7c['diffData'];});}}['_bufferUpdate'](_0x2e3535,_0x5c94dd,_0x2a6bb8){if(this['_bufferedUpdates']['has'](_0x2e3535)){const _0x1801e1=this['_bufferedUpdates']['get'](_0x2e3535);_0x5c94dd=_0x2a6bb8?{..._0x1801e1,..._0x5c94dd}:{..._0x5c94dd,..._0x1801e1};}this['_bufferedUpdates']['set'](_0x2e3535,_0x5c94dd);}['_getFromVersion'](_0x1751d5){const _0x4a793e=this['repository']['getRevisions']();_0x4a793e['reverse'](),_0x4a793e['shift']();const _0x41297d=_0x4a793e['find'](_0x5889a6=>_0x5889a6['toVersion']<=_0x1751d5)['toVersion'];return _0x41297d<this['_startingVersion']?this['_startingVersion']:_0x41297d;}['_createInitialRevision'](_0x3d0ce2){const _0x5bbd4c=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x5bbd4c)this['_initialRevisionId']=_0x5bbd4c['id'];else{const _0x25eb0e=!this['editor']['model']['document']['roots']['find'](_0x20e907=>this['editor']['model']['hasContent'](_0x20e907)),_0x3f964d=this['editor']['plugins']['get']('Users')['me']['id'],_0x18a938=R(this['editor']['locale'],_0x25eb0e?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x3d0ce2,'to':_0x3d0ce2,'id':this['_initialRevisionId'],'name':_0x18a938,'creatorId':_0x3f964d});}}['_createCurrentRevision'](_0x31bf4e){const _0x1a29a8=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x1a29a8),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x31bf4e,'to':_0x31bf4e,'id':_0x1a29a8,'name':'','creatorId':null}));}['_makeRevision']({name:_0x34aac1,from:_0x3f0239,to:_0x25a45e,creatorId:_0xc8ef38,id:_0x7fd78}){const _0x1db0cf=this['buildRevisionData']({'from':_0x3f0239,'to':_0x25a45e});_0x1db0cf['name']=_0x34aac1,_0x1db0cf['creatorId']=_0xc8ef38,_0x1db0cf['id']=_0x7fd78;const _0x7456c9=this['addRevisionData'](_0x1db0cf);return this['adapter']&&this['_bufferUpdate'](_0x1db0cf['id'],_0x1db0cf,!0x0),_0x7456c9;}['_setConversion'](){this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'});}['_removeRevisionMarkers'](_0x569fb9){return(_0x569fb9=_0x569fb9['filter'](_0x39ef89=>!_0x39ef89['name']||'revision-start'!==_0x39ef89['name']&&'revision-end'!==_0x39ef89['name']))['forEach'](_0x28feef=>{'string'!=typeof _0x28feef&&(_0x28feef['children']=this['_removeRevisionMarkers'](_0x28feef['children']),_0x28feef['attributes']=_0x28feef['attributes']['filter'](_0x1ee0a5=>!_0x1ee0a5[0x0]['startsWith']('data-revision-')));}),_0x569fb9;}}function V(_0x24f8e5,_0x5c6c24){const _0x49fc8d=_0x5c6c24['editing']['view']['document'];if('string'==typeof _0x24f8e5)return new _0xad2221(_0x49fc8d,_0x24f8e5);{const _0x4984bc=_0x24f8e5['children']['map'](_0x1e46f4=>V(_0x1e46f4,_0x5c6c24));return new(C[_0x24f8e5['type']]||_0x12e000)(_0x49fc8d,_0x24f8e5['name'],_0x24f8e5['attributes'],_0x4984bc);}}class T{['editor'];['source'];['_savedMetaData'];['_lastFrom'];['_lastTo'];['_markers'];['_diffRoots'];['_diffRootsAttributes'];['_baseRoots'];['_baseRootsAttributes'];['_idsRoots'];['_baseIdsRoots'];['_touched'];['_touchedMarkers'];['_touchedRoots'];['_revisionId'];['_startingRevisionId'];constructor(_0x5a04a7){this['editor']=_0x5a04a7,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'](_0x5a23f1){this['source']=_0x5a23f1;const _0x319936=new Map(),_0x684c7d=new Map(),_0xc118=this['editor']['model']['document']['roots']['map'](_0x104bfb=>_0x104bfb['rootName']);for(const _0x59d573 of _0xc118){const _0x4979a8=this['editor']['model']['document']['getRoot'](_0x59d573),_0x479efb=F(_0x4979a8);_0x319936['set'](_0x59d573,_0x479efb),_0x684c7d['set'](_0x59d573,Object['fromEntries'](_0x4979a8['getAttributes']()));}const _0x533a2e=Array['from'](this['editor']['model']['markers'])['map'](_0x2b752a=>[_0x2b752a['name'],_0x2b752a['getRange']()]),_0x27244d=this['source']['version'];this['_saveMetaData'](_0x27244d,_0x319936,_0x533a2e,_0x684c7d),this['_startingRevisionId']=this['_revisionId'];const _0x325830=new Map(),_0x263888=new Map();for(const _0x42b1a5 of _0xc118){const _0x354129=B(_0x42b1a5);_0x325830['set'](_0x42b1a5,_0x354129),_0x263888['set'](_0x42b1a5,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x325830,[],_0x263888);}['getData'](_0x52d6bb,_0xd35128){if(this['_lastFrom']===_0x52d6bb&&this['_lastTo']<=_0xd35128)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0xd35128,!0x0);else{if(!this['_savedMetaData']['has'](_0x52d6bb)){const _0x5ca27b=this['_getPreviousFrom'](_0x52d6bb);this['_calculateMetaData'](_0x5ca27b,_0x52d6bb,!0x1);}this['_calculateMetaData'](_0x52d6bb,_0xd35128,!0x0);}return this['_lastFrom']=_0x52d6bb,this['_lastTo']=_0xd35128,this['_getState']();}['loadState'](_0x3c0798){this['_reset'](),this['_lastFrom']=_0x3c0798['fromVersion'],this['_lastTo']=_0x3c0798['toVersion'];for(const _0x1d649e in _0x3c0798['diffData']){const _0x59297b=_0x3c0798['diffData'][_0x1d649e]['attachChange'],_0x134f16=_0x55297f(_0x3c0798['diffData'][_0x1d649e]['attributesBefore'])||{},_0x7ec839=this['_makeModelFromViewString'](_0x3c0798['diffData'][_0x1d649e]['deletions']);_0x7ec839['rootName']=_0x1d649e,_0x7ec839['_isAttached']=!_0x59297b||!_0x59297b['isAttached'],_0x7ec839['isAttached']=()=>_0x7ec839['_isAttached'],this['_baseRoots']['set'](_0x1d649e,_0x7ec839),this['_baseRootsAttributes']['set'](_0x1d649e,_0x134f16),_0x59297b&&this['_touchedRoots']['set'](_0x1d649e,_0x59297b);const _0x141e3=this['_makeIdsRoot'](_0x7ec839);this['_baseIdsRoots']['set'](_0x1d649e,_0x141e3);for(const [_0x535fb0,_0x419bf8]of _0x7ec839['markers']){if(!_0x535fb0['startsWith']('revision:'))continue;const _0x5d281c=_0x535fb0['split'](':')[0x2];for(const _0x2e7a2b of _0x419bf8['getWalker']({'singleCharacters':!0x0})){const _0x5a20ab=this['_getVidAttributeName'](_0x2e7a2b),_0xbf056f='elementEnd'==_0x2e7a2b['type']?_0x2e7a2b['previousPosition']['path']['slice'](0x0,-0x1):_0x2e7a2b['previousPosition']['path'],_0x276597=_0x141e3['getNodeByPath'](_0xbf056f)['getAttribute'](_0x5a20ab);this['_touched']['set'](_0x276597,{'userId':_0x5d281c});}}}this['_startingRevisionId']=this['_revisionId'];const _0x277bf6=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x3c51f2=>!this['_touched']['has'](_0x3c51f2));let _0x3d6d3c=0x0;const _0x5f05e4=new Map();for(const _0x21234f in _0x3c0798['diffData']){const _0x4a5449=_0x3c0798['diffData'][_0x21234f]['attachChange'],_0x100879=_0x55297f(_0x3c0798['diffData'][_0x21234f]['attributesAfter'])||{},_0x5445b9=this['_makeModelFromViewString'](_0x3c0798['diffData'][_0x21234f]['insertions']);_0x5445b9['rootName']=_0x21234f,_0x5445b9['_isAttached']=!_0x4a5449||_0x4a5449['isAttached'],_0x5445b9['isAttached']=()=>_0x5445b9['_isAttached'],this['_diffRoots']['set'](_0x21234f,_0x5445b9),this['_diffRootsAttributes']['set'](_0x21234f,_0x100879);const _0x1b04df=this['_makeIdsRoot'](_0x5445b9,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x21234f,_0x1b04df),_0x5f05e4['set'](_0x21234f,_0x5445b9['isAttached']()?_0x100879:{});for(const [_0x451524,_0x3e8c7b]of _0x5445b9['markers']){if(!_0x451524['startsWith']('revision:'))continue;const _0x3dedb1=_0x451524['split'](':')[0x2];for(const _0x142fac of _0x3e8c7b['getWalker']({'singleCharacters':!0x0})){const _0xa1901=this['_getVidAttributeName'](_0x142fac),_0x2a86b5=this['_revisionId']++,_0xb2055a='elementEnd'==_0x142fac['type']?_0x142fac['previousPosition']['path']['slice'](0x0,-0x1):_0x142fac['previousPosition']['path'];_0x1b04df['getNodeByPath'](_0xb2055a)['_setAttribute'](_0xa1901,_0x2a86b5),this['_touched']['set'](_0x2a86b5,{'userId':_0x3dedb1});}}for(const _0x4b1edc of this['editor']['model']['createRangeIn'](_0x5445b9)['getWalker']({'singleCharacters':!0x0})){const _0x53ab7f=this['_getVidAttributeName'](_0x4b1edc),_0x2bca11='elementEnd'==_0x4b1edc['type']?_0x4b1edc['previousPosition']['path']['slice'](0x0,-0x1):_0x4b1edc['previousPosition']['path'],_0xec5bdf=_0x1b04df['getNodeByPath'](_0x2bca11);_0xec5bdf['getAttribute'](_0x53ab7f)>0x0||_0xec5bdf['_setAttribute'](_0x53ab7f,_0x277bf6[_0x3d6d3c++]);}for(const [_0x478dde,_0x4c75c8]of _0x5445b9['markers'])_0x478dde['startsWith']('revision:')||this['_markers']['set'](_0x478dde,_0x4c75c8);}const _0x5c2629=B('$graveyard');this['_baseRoots']['set']('$graveyard',_0x5c2629),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x5c2629,0x1));const _0x5a0015=B('$graveyard');this['_diffRoots']['set']('$graveyard',_0x5a0015),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x5a0015,0x1));const _0x30be41=Array['from'](this['_diffRoots'])['map'](([_0x455854,_0x334d7d])=>[_0x455854,F(_0x334d7d)]);this['_saveMetaData'](this['_lastTo'],_0x30be41,this['_markers'],_0x5f05e4);}['_makeModelFromViewString'](_0x5bb026){const _0x2f82cb=JSON['parse'](_0x5bb026),_0x198bc5=this['editor']['editing']['view']['document'],_0x2576a1=new _0xa0965c(_0x198bc5,_0x2f82cb['map'](_0x4a8310=>V(_0x4a8310,this['editor'])));return this['editor']['data']['toModel'](_0x2576a1);}['_saveMetaData'](_0x51b960,_0x4002b3,_0x153b5b,_0xef5b1d){const _0x53b242=new Map(_0x4002b3),_0x3aee03=new Map(_0x55297f(_0xef5b1d)),_0x5167f1=new Map();for(const [_0x141e81,_0x117fcf]of _0x153b5b)_0x5167f1['set'](_0x141e81,{'start':_0x117fcf['start']['clone'](),'end':_0x117fcf['end']['clone'](),'rootName':_0x117fcf['root']['rootName']});this['_savedMetaData']['set'](_0x51b960,{'roots':_0x53b242,'markers':_0x5167f1,'rootsAttributes':_0x3aee03});}['_removeMetaData'](_0x23fcc9){this['_savedMetaData']['delete'](_0x23fcc9);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_reset'](){this['_touched']['clear'](),this['_touchedMarkers']['clear'](),this['_touchedRoots']['clear'](),this['_diffRoots']['clear'](),this['_diffRootsAttributes']['clear'](),this['_baseRoots']['clear'](),this['_baseRootsAttributes']['clear'](),this['_idsRoots']['clear'](),this['_baseIdsRoots']['clear'](),this['_markers']['clear'](),this['_revisionId']=0x1,this['_startingRevisionId']=this['_revisionId'];}['_makeIdsRoot'](_0x33a2b7,_0x54e103=null){let _0x2d8a18=null;_0x33a2b7['is']('documentFragment')||(_0x2d8a18=new ft(_0x33a2b7['name'],{'vid_start':null===_0x54e103?this['_revisionId']++:_0x54e103++}));const _0x4156fb=[];for(const _0x17b13b of _0x33a2b7['getChildren']())if(_0x17b13b['is']('element')){_0x4156fb['push'](this['_makeIdsRoot'](_0x17b13b,_0x54e103));const _0x2da078=_0x4156fb[_0x4156fb['length']-0x1];null!==_0x54e103&&(_0x54e103=_0x2da078['is']('element','$text')?_0x2da078['getAttribute']('vid')+0x1:_0x2da078['getAttribute']('vid_end')+0x1);}else{for(let _0xb80d74=0x0;_0xb80d74<_0x17b13b['offsetSize'];_0xb80d74++)_0x4156fb['push'](new ft('$text',{'vid':null===_0x54e103?this['_revisionId']++:_0x54e103++}));}if(_0x33a2b7['is']('documentFragment')){const _0x29c399=B(_0x33a2b7['rootName']);return _0x29c399['_insertChild'](0x0,_0x4156fb),_0x29c399;}return _0x2d8a18['_setAttribute']('vid_end',null===_0x54e103?this['_revisionId']++:_0x54e103++),_0x2d8a18['_insertChild'](0x0,_0x4156fb),_0x2d8a18;}['_calculateMetaData'](_0x169d02,_0x4d33c1,_0x121a8c){this['_reset']();const {roots:_0x294c87,markers:_0xc5b704,rootsAttributes:_0x4b24f1}=this['_savedMetaData']['get'](_0x169d02);this['_baseRoots']=new Map(_0x294c87),this['_baseRootsAttributes']=new Map(_0x55297f(_0x4b24f1));for(const [_0x24c069,_0x29d0de]of this['_baseRoots'])if('$graveyard'!==_0x24c069&&(this['_diffRoots']['set'](_0x24c069,F(_0x29d0de)),this['_diffRootsAttributes']=new Map(_0x55297f(_0x4b24f1)),_0x121a8c)){const _0x10898d=this['_revisionId'];this['_idsRoots']['set'](_0x24c069,this['_makeIdsRoot'](_0x29d0de)),this['_baseIdsRoots']['set'](_0x24c069,this['_makeIdsRoot'](_0x29d0de,_0x10898d));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',F(this['_baseRoots']['get']('$graveyard'))),_0x121a8c&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x2deaea,_0x40e0d9]of _0xc5b704){const _0x56f6fc=this['_baseRoots']['get'](_0x40e0d9['rootName']),_0x4e6249=this['_diffRoots']['get'](_0x40e0d9['rootName']),_0x1db10c=new vt(this['_fixPosition'](_0x40e0d9['start'],_0x56f6fc),this['_fixPosition'](_0x40e0d9['end'],_0x56f6fc)),_0x3a7681=this['_fixRange'](_0x1db10c,_0x4e6249);_0x56f6fc['markers']['set'](_0x2deaea,_0x1db10c),this['_markers']['set'](_0x2deaea,_0x3a7681);}this['_applyOperations'](_0x169d02,_0x4d33c1,_0x121a8c);}['_applyOperations'](_0x26dab7,_0x1d9fed,_0x15b904){for(const _0x2ad27a of this['source']['getOperations'](_0x26dab7,_0x1d9fed))this['_handleOperation'](_0x2ad27a,_0x15b904);for(const _0x4ad47f of this['_diffRoots']['values']())_0x4ad47f['markers']['clear']();for(const [_0xd149fd,_0x453d4d]of this['_markers']){this['_diffRoots']['get'](_0x453d4d['root']['rootName'])['markers']['set'](_0xd149fd,_0x453d4d['clone']());}const _0x17b766=new Map(),_0x4b12af=new Map();for(const [_0x22a693,_0x1a35fc]of this['_diffRoots'])_0x17b766['set'](_0x22a693,F(_0x1a35fc)),_0x4b12af['set'](_0x22a693,this['_diffRootsAttributes']['get'](_0x22a693));this['_saveMetaData'](_0x1d9fed,_0x17b766,this['_markers'],_0x4b12af);}['_getPreviousFrom'](_0x9a6d43){const _0x40a8ac=Array['from'](this['_savedMetaData']['keys']());_0x40a8ac['sort']((_0x38b3a0,_0x5ecb5d)=>_0x38b3a0-_0x5ecb5d),_0x40a8ac['reverse']();for(const _0x2a7ef4 of _0x40a8ac)if(_0x2a7ef4<_0x9a6d43)return _0x2a7ef4;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x30e580,_0x5bbbc4){const _0x5d8a9a=Array['from'](_0x5bbbc4['markers'])['map'](([_0x4e5896,_0x5d5c1f])=>[_0x4e5896,this['_fixRange'](_0x5d5c1f,_0x30e580)]);_0x30e580['markers']=new Map(_0x5d8a9a);}['_transformMarkers'](_0x4d3b46){for(const _0x449ccd of this['_markers']['values']()){const _0x168013=_0x449ccd['getTransformedByOperation'](_0x4d3b46),_0x18903e=vt['_createFromRanges'](_0x168013);_0x449ccd['start']=_0x18903e['start'],_0x449ccd['end']=_0x18903e['end'];}}['_handleOperation'](_0x54ff35,_0x52185b){if('addRoot'!=_0x54ff35['type']&&'detachRoot'!=_0x54ff35['type']){if('insert'==_0x54ff35['type']){const _0x1096cc=_0x54ff35['position']['root']['rootName'];this['_diffRoots']['has'](_0x1096cc)||(this['_diffRoots']['set'](_0x1096cc,B(_0x1096cc,!0x0)),this['_diffRootsAttributes']['set'](_0x1096cc,{}),_0x52185b&&this['_idsRoots']['set'](_0x1096cc,B(_0x1096cc,!0x0)));}else{if('addRootAttribute'==_0x54ff35['type']||'removeRootAttribute'==_0x54ff35['type']||'changeRootAttribute'==_0x54ff35['type'])return void this['_handleRootAttributeOperation'](_0x54ff35);'marker'==_0x54ff35['type']&&this['_handleMarkerOperation'](_0x54ff35);}if('marker'!==_0x54ff35['type']){const _0x590853=this['_cloneOperation'](_0x54ff35,this['_diffRoots']);_0x590853['_execute'](),this['_transformMarkers'](_0x590853);}if(_0x52185b)switch(_0x54ff35['type']){case'insert':this['_handleInsertOperation'](_0x54ff35);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x54ff35);break;case'merge':this['_handleMergeOperation'](_0x54ff35);break;case'split':this['_handleSplitOperation'](_0x54ff35);}}else this['_handleRootOperation'](_0x54ff35,_0x52185b);}['_cloneOperation'](_0x59b716,_0x1ac1bc){const _0x2fb04c=_0x59b716['clone']();return _0x2fb04c['_authorId']=_0x59b716['_authorId'],this['_fixOperation'](_0x2fb04c,_0x1ac1bc),_0x2fb04c;}['_getBaseVids'](_0x1dab9e){return _0x1dab9e['map'](_0x2be254=>{const _0x2a550b=this['_getVidAttributeName'](_0x2be254);return Number(_0x2be254['item']['getAttribute'](_0x2a550b));});}['_generateTape'](_0x1afbe9,_0x4481c4){if(_0x1afbe9['is']('element','$text'))_0x4481c4['push']({'item':_0x1afbe9,'type':'text'});else{_0x1afbe9['is']('element')&&_0x4481c4['push']({'item':_0x1afbe9,'type':'elementStart'});for(const _0x1e4776 of _0x1afbe9['getChildren']())this['_generateTape'](_0x1e4776,_0x4481c4);_0x1afbe9['is']('element')&&_0x4481c4['push']({'item':_0x1afbe9,'type':'elementEnd'});}return _0x4481c4;}['_getState'](){const _0x253ad7=new Map(this['_touched']),_0x114b7d=new Map(_0x253ad7),_0x1c1eac=new Map(),_0x3f6676={'insertions':{},'deletions':{}},_0x13898e={'insertions':{},'deletions':{}},_0x44de6b=new Map(),_0x58e13e=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x58e13e['delete']('$graveyard');for(const _0x5d616b of _0x58e13e){const _0x2a9b8b=this['_diffRoots']['get'](_0x5d616b)||B(_0x5d616b,!0x1),_0xefa9c8=this['_baseRoots']['get'](_0x5d616b)||B(_0x5d616b,!0x1);_0x2a9b8b['isAttached']()||_0xefa9c8['isAttached']()?(_0x3f6676['insertions'][_0x5d616b]=F(_0x2a9b8b),_0x3f6676['deletions'][_0x5d616b]=F(_0xefa9c8),this['_copyMarkers'](_0x3f6676['deletions'][_0x5d616b],_0xefa9c8),this['_copyMarkers'](_0x3f6676['insertions'][_0x5d616b],_0x2a9b8b),_0x13898e['insertions'][_0x5d616b]=this['_generateTape'](this['_idsRoots']['get'](_0x5d616b),[]),_0x13898e['deletions'][_0x5d616b]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x5d616b)||B(_0x5d616b,!0x1),[])):_0x58e13e['delete'](_0x5d616b);}for(const _0x414ba8 of _0x58e13e){const _0x303dd7=_0x13898e['insertions'][_0x414ba8];for(const _0xefbb5e of _0x303dd7){const _0x4240db=this['_getVidAttributeName'](_0xefbb5e),_0x2c092c=_0xefbb5e['item']['getAttribute'](_0x4240db);_0x114b7d['delete'](_0x2c092c),_0x2c092c>=this['_startingRevisionId']&&_0x1c1eac['set'](_0x2c092c,_0x253ad7['get'](_0x2c092c));}}for(const _0x3b3ba0 of _0x58e13e){const _0x5c604e=_0x13898e['insertions'][_0x3b3ba0],_0x5a52f8=this['_getBaseVids'](_0x13898e['deletions'][_0x3b3ba0]);let _0x885a2a=0x0;for(const _0x27c3ec of _0x5c604e){const _0x5a02c1=this['_getVidAttributeName'](_0x27c3ec),_0x2fe779=_0x27c3ec['item']['getAttribute'](_0x5a02c1);if(!_0x1c1eac['has'](_0x2fe779)&&!_0x44de6b['has'](_0x2fe779)){if(_0x114b7d['has'](_0x2fe779))_0x885a2a++;else{if(_0x2fe779!=_0x5a52f8[_0x885a2a]){const _0x2c52dd=_0x253ad7['get'](_0x2fe779)||_0x253ad7['get'](_0x5a52f8[_0x885a2a]);for(;_0x2fe779!=_0x5a52f8[_0x885a2a];)_0x114b7d['has'](_0x5a52f8[_0x885a2a])||(_0x44de6b['set'](_0x5a52f8[_0x885a2a],_0x2c52dd),_0x253ad7['set'](_0x5a52f8[_0x885a2a],_0x2c52dd)),_0x885a2a++;}_0x885a2a++;}}}}for(const _0x5b80d0 of _0x58e13e){const _0x19980e=_0x13898e['insertions'][_0x5b80d0];for(const _0x11eb84 of _0x19980e){const _0x495513=this['_getVidAttributeName'](_0x11eb84),_0x48008d=_0x11eb84['item']['getAttribute'](_0x495513);if(_0x44de6b['has'](_0x48008d)){const _0x23898a=_0x44de6b['get'](_0x48008d);_0x114b7d['has'](_0x48008d)||_0x114b7d['set'](_0x48008d,{..._0x23898a}),_0x1c1eac['set'](_0x48008d,{..._0x23898a});}}}for(const _0x2a947b of _0x114b7d['keys']())_0x2a947b>=this['_startingRevisionId']&&_0x114b7d['delete'](_0x2a947b);const _0x5ce927=new Map();for(const _0x2fc666 of _0x58e13e){let _0xa4f33=_0x13898e['insertions'][_0x2fc666];for(const _0x308c66 of _0xa4f33)if(_0x308c66['item']['is']('element','tableCell')){const _0xfde284=this['_getVidAttributeName'](_0x308c66),_0x352628=_0x308c66['item']['getAttribute'](_0xfde284);if(_0x1c1eac['has'](_0x352628)){const _0x341867=_0x308c66['item']['parent']['parent']['getAttribute']('vid_start'),_0xef2ea8=_0x5ce927['get'](_0x341867)||new Set();_0xef2ea8['add'](_0x1c1eac['get'](_0x352628)['userId']),_0x5ce927['set'](_0x341867,_0xef2ea8);}}_0xa4f33=_0x13898e['deletions'][_0x2fc666];for(const _0x3f48cb of _0xa4f33)if(_0x3f48cb['item']['is']('element','tableCell')){const _0x5d5d6d=this['_getVidAttributeName'](_0x3f48cb),_0x554844=_0x3f48cb['item']['getAttribute'](_0x5d5d6d);if(_0x114b7d['has'](_0x554844)){const _0x354f16=_0x3f48cb['item']['parent']['parent']['getAttribute']('vid_start'),_0x4aca5a=_0x5ce927['get'](_0x354f16)||new Set();_0x4aca5a['add'](_0x114b7d['get'](_0x554844)['userId']),_0x5ce927['set'](_0x354f16,_0x4aca5a);}}for(const _0x28613e of _0x5ce927['keys']())(_0x1c1eac['has'](_0x28613e)||_0x114b7d['has'](_0x28613e))&&_0x5ce927['delete'](_0x28613e);}for(const _0x420ed5 of _0x58e13e){const _0x56adf4=_0x13898e['insertions'][_0x420ed5];let _0x261f9d=null,_0x367543=null;for(const _0x12219f of _0x56adf4){const _0x205bf8=this['_getVidAttributeName'](_0x12219f),_0x5b17fb=_0x12219f['item']['getAttribute'](_0x205bf8),_0xc78218=_0x5ce927['get'](_0x5b17fb);_0xc78218&&'elementStart'==_0x12219f['type']&&(_0x261f9d=Array['from'](_0xc78218)[0x0],_0x367543=_0x12219f['item']['getAttribute']('vid_end')),_0x261f9d&&(_0x114b7d['set'](_0x5b17fb,{'userId':_0x261f9d}),_0x1c1eac['set'](_0x5b17fb,{'userId':_0x261f9d})),_0x5b17fb==_0x367543&&(_0x261f9d=null,_0x367543=null);}}const _0x196069={},_0x5b9f7a=new Set();for(const _0x18b835 of _0x58e13e){const _0x922c0e=_0x3f6676['deletions'][_0x18b835],_0x141463=_0x3f6676['insertions'][_0x18b835];for(const {userId:_0x13db78}of this['_touchedMarkers']['values']())null!==_0x13db78&&_0x5b9f7a['add'](_0x13db78);for(const {userId:_0x450592}of this['_touchedRoots']['values']())null!==_0x450592&&_0x5b9f7a['add'](_0x450592);this['_markChanges'](_0x141463,_0x13898e['insertions'][_0x18b835],_0x1c1eac,'insertion',_0x5b9f7a),this['_markChanges'](_0x922c0e,_0x13898e['deletions'][_0x18b835],_0x114b7d,'deletion',_0x5b9f7a),_0x196069[_0x18b835]={'insertions':this['_prepareViewToSave'](_0x141463),'deletions':this['_prepareViewToSave'](_0x922c0e),'attachChange':this['_touchedRoots']['get'](_0x18b835)||null,'attributesBefore':_0x55297f(this['_baseRootsAttributes']['get'](_0x18b835))||{},'attributesAfter':_0x55297f(this['_diffRootsAttributes']['get'](_0x18b835))};}return{'diffData':_0x196069,'authorsIds':Array['from'](_0x5b9f7a)};}['_processRootBeforeSave'](_0x3e4bf4){for(const [,_0x37dae3]of _0x3e4bf4['markers']){const _0x4ccf43=_0x37dae3['start']['getAncestors']()['filter'](_0x27a181=>'tableCell'==_0x27a181['name']);for(const _0x290af6 of _0x4ccf43)0x1==_0x290af6['childCount']&&_0x290af6['getChild'](0x0)['is']('element','paragraph')&&_0x290af6['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x186dcc){this['_processRootBeforeSave'](_0x186dcc);const _0x43d1e5=this['editor']['data']['toView'](_0x186dcc,{}),_0x15545e=Array['from'](_0x43d1e5['getChildren']())['map'](_0x2a1fda=>this['_getViewJson'](_0x2a1fda));return JSON['stringify'](_0x15545e);}['_getViewJson'](_0x11b1d8){if(_0x11b1d8['is']('$text'))return _0x11b1d8['data'];{const _0x4fe2e0=_0x11b1d8;return{'type':Object['keys'](C)['find'](_0x16c364=>_0x11b1d8 instanceof C[_0x16c364]),'name':_0x4fe2e0['name'],'attributes':Array['from'](_0x4fe2e0['getAttributes']()),'children':Array['from'](_0x4fe2e0['getChildren']())['map'](_0x30cdff=>this['_getViewJson'](_0x30cdff))};}}['_markChanges'](_0x2b6639,_0x3dd141,_0x501748,_0x133304,_0x11d149){let _0x13048d=null,_0x745bd7=null,_0x506e1d=0x0;const _0x7a9f75=this['editor']['model'];for(let _0x1d412d=0x0;_0x1d412d<_0x3dd141['length'];_0x1d412d++){const _0xdea71b=this['_getVidAttributeName'](_0x3dd141[_0x1d412d]),_0x42c23d=_0x3dd141[_0x1d412d]['item']['getAttribute'](_0xdea71b),_0x2c5dea=_0x501748['get'](_0x42c23d),_0x393cec=_0x1d412d==_0x3dd141['length']-0x1;(!_0x13048d&&_0x2c5dea&&(_0x13048d=_0x2c5dea,_0x745bd7=_0x3dd141[_0x1d412d]),_0x13048d&&(!_0x2c5dea||_0x2c5dea['userId']!=_0x13048d['userId']))&&(_0x597179(_0x2c5dea,J(_0x745bd7,_0x2b6639,_0x7a9f75),J(_0x3dd141[_0x1d412d],_0x2b6639,_0x7a9f75)),_0x13048d=_0x2c5dea||null,_0x745bd7=_0x2c5dea?_0x3dd141[_0x1d412d]:null),_0x13048d&&_0x393cec&&_0x597179(_0x2c5dea,J(_0x745bd7,_0x2b6639,_0x7a9f75),q(_0x3dd141[_0x1d412d],_0x2b6639,_0x7a9f75));}function _0x597179(_0x574d91,_0x37dbe9,_0x46a8f9){const _0xe0afd8=_0x13048d['userId'],_0x5268cb='revision:'+_0x133304+':'+_0xe0afd8+':'+_0x506e1d++,_0x98e53=_0x7a9f75['createRange'](_0x37dbe9,_0x46a8f9);_0x2b6639['markers']['set'](_0x5268cb,_0x98e53),null!==_0xe0afd8&&_0x11d149['add'](_0xe0afd8);}}['_getVidAttributeName'](_0x44f5a8){switch(_0x44f5a8['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x14e63f,_0x1a06d0){_0x14e63f['baseVersion']=null;for(const _0x40d66b in _0x14e63f){const _0x4f450b=_0x14e63f[_0x40d66b];if(_0x4f450b instanceof gt){const _0x4bbfb5=_0x1a06d0['get'](_0x4f450b['root']['rootName']);_0x14e63f[_0x40d66b]=this['_fixPosition'](_0x4f450b,_0x4bbfb5);}if(_0x4f450b instanceof vt){const _0x501178=_0x1a06d0['get'](_0x4f450b['root']['rootName']);_0x14e63f[_0x40d66b]=this['_fixRange'](_0x4f450b,_0x501178);}'root'===_0x40d66b&&(_0x14e63f['root']=_0x1a06d0['get'](_0x14e63f['root']['rootName']));}}['_fixRange'](_0x48ab3b,_0x3acb65){return this['editor']['model']['createRange'](this['_fixPosition'](_0x48ab3b['start'],_0x3acb65),this['_fixPosition'](_0x48ab3b['end'],_0x3acb65));}['_fixPosition'](_0x2ca903,_0x53be8b){return this['editor']['model']['createPositionFromPath'](_0x53be8b,_0x2ca903['path'],_0x2ca903['stickiness']);}['_handleInsertOperation'](_0x586a6d){const _0x11843b=this['_idsRoots']['get'](_0x586a6d['position']['root']['rootName']),_0x184688=this['_fixPosition'](_0x586a6d['position'],_0x11843b),_0x4751ac=null===_0x586a6d['_authorId']?null:_0x586a6d['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x2e3bcc=_0x184688['parent'],_0x36b6f5=this['_revisionId'],_0x553c2f=[];for(const _0x3ae5ba of _0x586a6d['nodes'])if(_0x3ae5ba['is']('element'))_0x553c2f['push'](this['_makeIdsRoot'](_0x3ae5ba));else{for(let _0x303810=0x0;_0x303810<_0x3ae5ba['offsetSize'];_0x303810++)_0x553c2f['push'](new ft('$text',{'vid':this['_revisionId']++}));}const _0x249579=this['_revisionId'];for(let _0x5dc63e=_0x36b6f5;_0x5dc63e<_0x249579;_0x5dc63e++)this['_touched']['set'](_0x5dc63e,{'userId':_0x4751ac});_0x2e3bcc['_insertChild'](_0x184688['offset'],_0x553c2f);}['_handleMoveOperation'](_0x3d8a89){(_0x3d8a89=this['_cloneOperation'](_0x3d8a89,this['_idsRoots']))['_execute']();const _0x267a7f=null===_0x3d8a89['_authorId']?null:_0x3d8a89['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x33ca90=_0x3d8a89['getMovedRangeStart'](),_0x1b9770=_0x33ca90['parent'],_0x45c5b5=_0x33ca90['offset'];!function _0x411a05(_0x51d9dc,_0x51bcfc,_0x3a1a89,_0x1bde17){for(let _0x4093cb=_0x3a1a89;_0x4093cb<_0x1bde17;_0x4093cb++){const _0x35f2fc=_0x51bcfc['getChild'](_0x4093cb);_0x35f2fc['is']('element','$text')?_0x51d9dc['set'](_0x35f2fc['getAttribute']('vid'),{'userId':_0x267a7f}):(_0x51d9dc['set'](_0x35f2fc['getAttribute']('vid_start'),{'userId':_0x267a7f}),_0x411a05(_0x51d9dc,_0x35f2fc,0x0,_0x35f2fc['childCount']),_0x51d9dc['set'](_0x35f2fc['getAttribute']('vid_end'),{'userId':_0x267a7f}));}}(this['_touched'],_0x1b9770,_0x45c5b5,_0x45c5b5+_0x3d8a89['howMany']);}['_handleMergeOperation'](_0x3c82cc){const _0x2e2b71=null===(_0x3c82cc=this['_cloneOperation'](_0x3c82cc,this['_idsRoots']))['_authorId']?null:_0x3c82cc['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x21c7fd=_0x3c82cc['targetPosition']['parent'],_0x4e7138=_0x3c82cc['sourcePosition']['parent'],_0x4779fc=_0x21c7fd['getAttribute']('vid_end'),_0x42eeee=_0x4e7138['getAttribute']('vid_start');_0x21c7fd['_setAttribute']('vid_end',_0x4e7138['getAttribute']('vid_end')),_0x4e7138['_setAttribute']('vid_end',_0x4779fc),this['_touched']['set'](_0x42eeee,{'userId':_0x2e2b71}),this['_touched']['set'](_0x4779fc,{'userId':_0x2e2b71}),_0x3c82cc['_execute']();}['_handleSplitOperation'](_0x47ac17){const _0x2bac79=null===(_0x47ac17=this['_cloneOperation'](_0x47ac17,this['_idsRoots']))['_authorId']?null:_0x47ac17['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x273ea7=_0x47ac17['graveyardPosition'],_0x14790f=_0x47ac17['splitPosition']['parent'];_0x47ac17['_execute']();const _0x3bccd9=_0x14790f['getAttribute']('vid_end'),_0x1e1a5c=_0x47ac17['insertionPosition']['nodeAfter'];if(_0x273ea7){const _0x1f2b93=_0x1e1a5c['getAttribute']('vid_end'),_0x58124d=_0x14790f['getAttribute']('vid_end');_0x14790f['_setAttribute']('vid_end',_0x1f2b93),_0x1e1a5c['_setAttribute']('vid_end',_0x58124d),this['_touched']['set'](_0x14790f['getAttribute']('vid_end'),{'userId':_0x2bac79}),this['_touched']['set'](_0x1e1a5c['getAttribute']('vid_start'),{'userId':_0x2bac79});}else{const _0x1c4e8f=this['_revisionId']++,_0x1e6acd=this['_revisionId']++;_0x14790f['_setAttribute']('vid_end',_0x1c4e8f),_0x1e1a5c['_setAttribute']('vid_start',_0x1e6acd),_0x1e1a5c['_setAttribute']('vid_end',_0x3bccd9),this['_touched']['set'](_0x1c4e8f,{'userId':_0x2bac79}),this['_touched']['set'](_0x1e6acd,{'userId':_0x2bac79});}}['_handleMarkerOperation'](_0x2834e6){if(!_0x2834e6['affectsData'])return;const _0x282ad6=(_0x2834e6=this['_cloneOperation'](_0x2834e6,this['_diffRoots']))['oldRange']?_0x2834e6['oldRange']['root']:null,_0x1f7ac2=_0x2834e6['newRange']?_0x2834e6['newRange']['root']:null;_0x282ad6&&this['_markers']['delete'](_0x2834e6['name']),_0x1f7ac2&&this['_markers']['set'](_0x2834e6['name'],_0x2834e6['newRange']['clone']());const _0x542f76=null===_0x2834e6['_authorId']?null:_0x2834e6['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x18a72a=_0x2834e6['name'];if(!this['_touchedMarkers']['has'](_0x18a72a))return void this['_touchedMarkers']['set'](_0x18a72a,{'range':_0x2834e6['oldRange'],'userId':_0x542f76});const _0x43777c=this['_touchedMarkers']['get'](_0x18a72a),_0xa2f217=_0x43777c['range'],_0x42f2fa=_0x2834e6['newRange'];null==_0xa2f217&&null==_0x42f2fa||_0xa2f217&&_0x42f2fa&&_0xa2f217['isEqual'](_0x42f2fa)?this['_touchedMarkers']['delete'](_0x2834e6['name']):_0x43777c['userId']=_0x542f76;}['_handleRootOperation'](_0x161d4a,_0x2141cd){this['_diffRoots']['has'](_0x161d4a['rootName'])?this['_diffRoots']['get'](_0x161d4a['rootName'])['_isAttached']=_0x161d4a['isAdd']:(this['_diffRoots']['set'](_0x161d4a['rootName'],B(_0x161d4a['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x161d4a['rootName'],{}),_0x2141cd&&this['_idsRoots']['set'](_0x161d4a['rootName'],B(_0x161d4a['rootName'],!0x0)));const _0x1b53d5=null===_0x161d4a['_authorId']?null:_0x161d4a['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x480f4c=this['_touchedRoots']['get'](_0x161d4a['rootName']);_0x480f4c&&_0x480f4c['userId']===_0x1b53d5?this['_touchedRoots']['delete'](_0x161d4a['rootName']):this['_touchedRoots']['set'](_0x161d4a['rootName'],{'userId':_0x1b53d5,'isAttached':_0x161d4a['isAdd']});}['_handleRootAttributeOperation'](_0x1037b5){const _0x401b7c=this['_diffRootsAttributes']['get'](_0x1037b5['root']['rootName']);null===_0x1037b5['newValue']?delete _0x401b7c[_0x1037b5['key']]:_0x401b7c[_0x1037b5['key']]=_0x1037b5['newValue'];}}function F(_0x68d3cb){const _0x2829d4=B(_0x68d3cb['rootName'],_0x68d3cb['isAttached']());for(const _0x3d95ce of _0x68d3cb['getChildren']()){const _0x2a78ac=_0x3d95ce['_clone'](!0x0);_0x2829d4['_appendChild'](_0x2a78ac);}return _0x2829d4;}function B(_0x2b65c8,_0x1dfe5b=!0x0){const _0x17c18e=new wt();return _0x17c18e['rootName']=_0x2b65c8,_0x17c18e['_isAttached']=_0x1dfe5b,_0x17c18e['isAttached']=()=>_0x17c18e['_isAttached'],_0x17c18e;}function J(_0x4083d1,_0x24dec0,_0x67e46){const _0x4016c4='elementEnd'==_0x4083d1['type']?_0x67e46['createPositionAt'](_0x4083d1['item'],'end'):_0x67e46['createPositionBefore'](_0x4083d1['item']);return _0x67e46['createPositionFromPath'](_0x24dec0,_0x4016c4['path'],_0x4016c4['stickiness']);}function q(_0x59cfd9,_0x2adc8f,_0x295e2d){const _0x228151='elementStart'==_0x59cfd9['type']?_0x295e2d['createPositionAt'](_0x59cfd9['item'],0x0):_0x295e2d['createPositionAfter'](_0x59cfd9['item']);return _0x295e2d['createPositionFromPath'](_0x2adc8f,_0x228151['path'],_0x228151['stickiness']);}class ns extends _0xbc5f18{['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x3b54b3,_0x4662a8){super(_0x3b54b3),this['focusTracker']=new _0x4033fd(),this['keystrokes']=new _0x4a5e29(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x4662a8),this['setTemplate']({'tag':'form','attributes':{'class':['ck','ck-revision-history-save-revision-form','ck-responsive-form'],'tabindex':'-1'},'children':[this['revisionNameInputView']]}),ts(this);}['render'](){super['render'](),_0x372554({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x5d49f1=_0x2fb9e9=>_0x2fb9e9['stopPropagation']();this['keystrokes']['set']('arrowright',_0x5d49f1),this['keystrokes']['set']('arrowleft',_0x5d49f1),this['keystrokes']['set']('arrowup',_0x5d49f1),this['keystrokes']['set']('arrowdown',_0x5d49f1);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0xa4723b){this['revisionNameInputView']['fieldView']['element']['value']=_0xa4723b['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x5833ed){const _0xe57170=new at(this['locale'],_0x58483e),_0x38d7e1=_0xe57170['fieldView'];_0x38d7e1['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x4fab2c=R(this['locale'],'Name\x20of\x20the\x20revision');return!_0x5833ed&&(_0x4fab2c+='\x20('+R(this['locale'],'optional')+')'),(_0xe57170['label']=_0x4fab2c,_0x38d7e1['on']('input',()=>{this['revisionNameInputValue']=_0x38d7e1['element']['value']['trim']();}),_0xe57170);}}class u extends _0x49d8e7{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l];}['_saveRevisionFormView'];['init'](){const _0x1a0ef9=this['editor'],_0x20ae63=_0x1a0ef9['plugins']['get']('RevisionTracker');_0x1a0ef9['ui']['componentFactory']['add']('revisionHistory',_0xfe2609=>{const _0x495988=_0x39648c(_0xfe2609),_0x347e9a=_0x495988['panelView']['children'],_0x1f0893=new te(_0xfe2609),_0x3e459c=new _0x2df2f6(_0xfe2609),_0x48ce24=new _0x10c58e(_0xfe2609),_0x3f456f=new _0x2df2f6(_0xfe2609),_0x3d9357=new _0x10c58e(_0xfe2609);return _0x495988['bind']('isEnabled')['to'](_0x20ae63,'isReady',_0x20ae63,'isEnabled',_0x1a0ef9,'isReadOnly',(_0x2f7f11,_0x5e28d4,_0x24f53e)=>_0x2f7f11&&_0x5e28d4&&!_0x24f53e),_0x495988['buttonView']['set']({'icon':_0x180720['history'],'label':R(_0xfe2609,'Revision\x20history'),'tooltip':!0x0}),_0x48ce24['set']({'label':R(_0xfe2609,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x48ce24['bind']('isEnabled')['to'](_0x20ae63,'isReady',_0x20ae63,'isEnabled',_0x1a0ef9,'isReadOnly',(_0x1724cd,_0x1c2399,_0x1575ad)=>_0x1724cd&&_0x1c2399&&!_0x1575ad),_0x48ce24['on']('execute',()=>this['_showDialog']()),_0x3d9357['set']({'label':R(_0xfe2609,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x3d9357['bind']('isEnabled')['to'](_0x20ae63,'isReady',_0x1a0ef9,'isReadOnly',(_0x376bb0,_0x35aea7)=>_0x376bb0&&!_0x35aea7),_0x3d9357['on']('execute',()=>{_0x1a0ef9['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x495988['isOpen']=!0x1,_0x1a0ef9['editing']['view']['focus']();}),_0x3e459c['children']['add'](_0x48ce24),_0x3f456f['children']['add'](_0x3d9357),_0x1f0893['role']='menu',_0x1f0893['items']['addMany']([_0x3e459c,_0x3f456f]),_0x347e9a['add'](_0x1f0893),_0x495988;}),_0x1a0ef9['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x48bed2=this['editor'],_0x453f3b=_0x48bed2['locale'],_0x4b0d7e=new _0x408c39(_0x453f3b),_0xe6cc4d=new _0x2f8f9c(_0x453f3b);_0x4b0d7e['buttonView']['set']({'icon':_0x180720['history'],'label':R(_0x453f3b,'Revision\x20history')});const _0x16a656=new _0x729c6b(_0x453f3b,_0x4b0d7e),_0x264ab6=new _0x16c7a1(_0x453f3b);_0x264ab6['set']({'label':R(_0x453f3b,'Save\x20current\x20revision')}),_0x264ab6['delegate']('execute')['to'](_0x4b0d7e),_0x264ab6['on']('execute',()=>{this['_showDialog']();}),_0x16a656['children']['add'](_0x264ab6),_0xe6cc4d['items']['add'](_0x16a656);const _0xce0138=new _0x729c6b(_0x453f3b,_0x4b0d7e),_0x34568a=new _0x16c7a1(_0x453f3b);return _0x34568a['set']({'label':R(_0x453f3b,'Open\x20revision\x20history')}),_0x34568a['delegate']('execute')['to'](_0x4b0d7e),_0x34568a['on']('execute',()=>{_0x48bed2['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0xce0138['children']['add'](_0x34568a),_0xe6cc4d['items']['add'](_0xce0138),_0x4b0d7e['panelView']['children']['add'](_0xe6cc4d),_0x4b0d7e;}['_showDialog'](){const _0x2375d1=this['editor'],_0x4e5f01=_0x2375d1['locale'],_0x23414e=_0x2375d1['plugins']['get']('Dialog'),_0xd168f6=_0x2375d1['plugins']['get']('RevisionTracker');function _0x40e4b6(_0x492fd5){_0x2375d1['config']['get']('revisionHistory.requireRevisionName')&&''===_0x492fd5['revisionName']?_0x492fd5['revisionNameInputView']['errorText']=R(_0x4e5f01,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x2375d1['plugins']['get'](l)['saveRevision']({'name':_0x492fd5['revisionName']}),_0x23414e['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x40e4b6(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x23414e['show']({'id':'revisionSave','title':R(_0x4e5f01,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':R(_0x2375d1['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x23414e['hide']()},{'label':R(_0x2375d1['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x2c865a){_0x2c865a['bind']('isEnabled')['to'](_0xd168f6,'isReady',_0xd168f6,'isEnabled',_0x2375d1,'isReadOnly',(_0x3875be,_0x4211ac,_0x49082e)=>_0x3875be&&_0x4211ac&&!_0x49082e);},'onExecute':()=>_0x40e4b6(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x445e72=this['editor'],_0x31a723=_0x445e72['locale'];this['_saveRevisionFormView']=new ns(_0x31a723,_0x445e72['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class Y extends _0xbc5f18{['changeId'];['_model'];constructor(_0xbe7eba,_0x4bb9c3){super(_0xbe7eba),this['_model']=_0x4bb9c3,this['changeId']=_0x4bb9c3['id'];const _0x5f3970=this['bindTemplate'],_0x347621=R(_0xbe7eba,_0x4bb9c3['data']['isSuggestion']?'Suggested\x20by':'add'==_0x4bb9c3['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x4bb9c3['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x5f3970['to']('type',_0x44edbe=>'ck-revision-change__'+_0x44edbe)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x347621}]},{'text':'\x20'+_0x4bb9c3['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class r extends/* #__PURE__ -- @preserve */
|
|
25
|
+
_0x4fe546(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x545509){super(),this['id']=_0x545509['id']||_0x4d1572(),this['author']=_0x545509['author'],this['type']=_0x545509['type'],this['data']=_0x545509['data']||{},this['rootName']=_0x545509['rootName'],this['set']('createdAt',_0x545509['createdAt']);}['toJSON'](){return{'id':this['id'],'authorId':this['author']['id'],'type':this['type'],'data':this['data'],'createdAt':this['createdAt']};}}class f{['newRevisionId'];['oldRevisionId'];['changes'];constructor(_0x5c5f47,_0x5c1931){this['newRevisionId']=_0x5c5f47,this['oldRevisionId']=_0x5c1931,this['changes']=new _0x3461b4();}['_setChanges'](_0x6d5829){for(const _0x509930 of _0x6d5829)this['changes']['add'](_0x509930);}}const Z={'c':_0x847cee,'a':_0x362f45,'e':_0x4fb0d7,'r':_0x4276f9,'u':_0x29894d};class d extends _0x49d8e7{['repository'];['adapter'];['_activeViewTarget'];['_changeView'];['_changeIdToChange'];['_balloon'];static get['pluginName'](){return'RevisionViewer';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[_0x211ed4,_0x17e217,j];}constructor(_0xe2cc7b){super(_0xe2cc7b),this['repository']=this['editor']['plugins']['get']('RevisionsRepository'),this['set']('activeChange',null),this['set']('activeView',null),this['_activeViewTarget']=null,this['set']('diff',null),this['set']('isReady',!0x1),this['set']('isEnabled',!0x0),this['on']('change:isEnabled',(_0x5277c3,_0x1c7a9c,_0x5d88ff)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x15f931=>{for(const _0x3c9cf4 of this['editor']['editing']['view']['document']['roots'])_0x5d88ff?_0x15f931['removeClass']('ck-editor__editable__overlay',_0x3c9cf4):_0x15f931['addClass']('ck-editor__editable__overlay',_0x3c9cf4);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x277163=>null!==_0x277163),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x54d621,_0x3528f5,_0xbbcb1f)=>_0x54d621&&_0xbbcb1f?_0x3528f5['changes']['getIndex'](_0xbbcb1f):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x5ec11e,_0x12c461)=>_0x5ec11e?_0x12c461['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['adapter']=null,this['_balloon']=this['editor']['plugins']['get'](_0x17e217);}['init'](){const _0x33d24d=this['editor'],_0x4b3240=new bt(_0x33d24d,{'direction':'backward'}),_0x56b921=new bt(_0x33d24d,{'direction':'forward'});(_0x33d24d['commands']['add']('showPreviousChange',_0x4b3240),_0x33d24d['commands']['add']('showNextChange',_0x56b921),_0x33d24d['commands']['add']('restoreRevision',new yt(_0x33d24d)),this['on']('change:numberOfChanges',()=>{_0x4b3240['refresh'](),_0x56b921['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x33d24d['enableReadOnlyMode']('revision-viewer'),_0x33d24d['plugins']['has']('WidgetToolbarRepository'))&&_0x33d24d['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionData'](_0x376045){await this['loadRevisionData'](_0x376045);const _0x14f657={};for(const _0x30251b in _0x376045['diffData']){if(_0x376045['diffData'][_0x30251b]['attachChange']&&!_0x376045['diffData'][_0x30251b]['attachChange']['isAttached'])continue;const _0x1bf760=this['_removeRevisionMarkers'](JSON['parse'](_0x376045['diffData'][_0x30251b]['insertions'])),_0xee3d34=this['editor']['editing']['view']['document'],_0x3072ad=new _0xa0965c(_0xee3d34,_0x1bf760['map'](_0x26ff90=>this['_getViewObj'](_0x26ff90)));this['editor']['data']['processor']['useFillerType']('marked'),_0x14f657[_0x30251b]=this['editor']['data']['processor']['toData'](_0x3072ad),this['editor']['data']['processor']['useFillerType']('default');}return _0x14f657;}async['getRevisionRootsAttributes'](_0x4fbef1){await this['loadRevisionData'](_0x4fbef1);const _0x70d300={};for(const _0x5d106f in _0x4fbef1['diffData'])_0x4fbef1['diffData'][_0x5d106f]['attachChange']&&!_0x4fbef1['diffData'][_0x5d106f]['attachChange']['isAttached']||(_0x70d300[_0x5d106f]=_0x4fbef1['diffData'][_0x5d106f]['attributesAfter']||{});return _0x70d300;}['_removeRevisionMarkers'](_0xa87e2d){return(_0xa87e2d=_0xa87e2d['filter'](_0x46d6b6=>!_0x46d6b6['name']||'revision-start'!==_0x46d6b6['name']&&'revision-end'!==_0x46d6b6['name']))['forEach'](_0x1b3854=>{'string'!=typeof _0x1b3854&&(_0x1b3854['children']=this['_removeRevisionMarkers'](_0x1b3854['children']),_0x1b3854['attributes']=_0x1b3854['attributes']['filter'](_0x559e2f=>!_0x559e2f[0x0]['startsWith']('data-revision-')));}),_0xa87e2d;}async['compare'](_0x2e6705,_0x2395aa,_0x5766f7=!0x1){if(!this['isEnabled'])return;const _0x3fecaa=this['diff'],_0x3f706b=this['repository'],_0x105932='string'==typeof _0x2e6705?_0x3f706b['getRevision'](_0x2e6705):_0x2e6705,_0x580a40='string'==typeof _0x2395aa?_0x3f706b['getRevision'](_0x2395aa):_0x2395aa,_0x2d5758=_0x105932['id'],_0x38cb49=_0x580a40?_0x580a40['id']:null;if(!_0x5766f7&&this['diff']&&this['diff']['newRevisionId']===_0x2d5758&&this['diff']['oldRevisionId']===_0x38cb49)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new f(_0x2d5758,_0x38cb49);const _0x1881e1=this['_getRevisionsRange'](_0x105932,_0x580a40,!0x0)['map'](_0x44de19=>this['loadRevisionData'](_0x44de19));return _0x1881e1['push'](new Promise(_0x47083e=>{setTimeout(_0x47083e,0x14);})),Promise['all'](_0x1881e1)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x145e56=this['_getDiff'](_0x2d5758,_0x38cb49);for(const _0x27269e of _0x145e56['changes'])this['_changeIdToChange']['set'](_0x27269e['id'],_0x27269e);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x4abde0=>{for(const _0x1a4fa3 of this['editor']['model']['document']['getRootNames']())_0x4abde0['detachRoot'](_0x1a4fa3);for(const _0x3d2104 of Object['keys'](_0x145e56['model'])){const _0x5952c5=_0x4abde0['addRoot'](_0x3d2104);for(const _0x28d61d of Object['keys'](_0x145e56['attributes'][_0x3d2104]))_0x4abde0['setAttribute'](_0x28d61d,_0x145e56['attributes'][_0x3d2104][_0x28d61d],_0x5952c5);_0x4abde0['insert'](_0x145e56['model'][_0x3d2104],_0x5952c5,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x145e56['changes'])),this['isReady']=!0x0;})['catch'](_0x3dddc6=>{console['error'](_0x3dddc6),this['_cleanUp'](),_0x3fecaa&&(this['diff']=_0x3fecaa),this['isReady']=!0x0;});}['addRevisionData'](_0x4c579c,_0x4a52f4){const _0x19ee21=this['repository']['createRevision'](_0x4c579c);return _0x19ee21['on']('_update',(_0x179478,_0x508708,_0x50ab81)=>_0x4a52f4(_0x508708,_0x50ab81,_0x19ee21)),this['repository']['addRevision'](_0x19ee21),_0x19ee21;}['loadRevisionData'](_0x40ed44){if(!_0x40ed44||_0x40ed44['diffData'])return Promise['resolve']();{const _0xe78c28=this['editor']['config']['get']('collaboration.channelId');return this['adapter']['getRevision']({'channelId':_0xe78c28,'revisionId':_0x40ed44['id']})['then'](_0x215a09=>{_0x40ed44['_update']({'diffData':_0x215a09['diffData']},!0x0);});}}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x37a0b7=>{for(const _0x396a5f of this['editor']['model']['document']['getRootNames']())_0x37a0b7['detachRoot'](_0x396a5f);});}['_sortAndFilterDiffChanges'](_0x4c8e21){const _0x21db6e=[],_0x457022=new Map();for(const _0x47071c of this['editor']['model']['document']['getRootNames']()){const _0x1d8425=this['editor']['editing']['view']['getDomRoot'](_0x47071c);if(!_0x1d8425)continue;const _0x290dde=_0x1d8425['getClientRects']()['item'](0x0);_0x290dde&&(_0x21db6e['push'](_0x47071c),_0x457022['set'](_0x47071c,_0x290dde));}return _0x21db6e['sort']((_0x262e7b,_0x4d6c2d)=>{const _0x16e404=_0x457022['get'](_0x262e7b),_0x4078f1=_0x457022['get'](_0x4d6c2d);return _0x16e404['y']-_0x4078f1['y']||_0x16e404['x']-_0x4078f1['x'];}),(_0x4c8e21=_0x4c8e21['filter'](_0x2264bd=>_0x21db6e['includes'](_0x2264bd['rootName'])))['sort']((_0x14fccf,_0xf7dd8a)=>_0x21db6e['indexOf'](_0x14fccf['rootName'])-_0x21db6e['indexOf'](_0xf7dd8a['rootName'])),_0x4c8e21;}['_makeTape'](_0xc1f0ae){const _0xe5f094=Array['from'](_0xc1f0ae['markers'])['filter'](([_0x25ad7a,_0x273a23])=>_0x25ad7a['startsWith']('revision:')&&!_0x273a23['isCollapsed']),_0x25284c=Array['from'](this['editor']['model']['createRangeIn'](_0xc1f0ae)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0xe5f094['length'])for(const _0x4ae9f8 of _0x25284c){const [_0x436060,_0x34058b]=_0xe5f094[0x0],[,_0x256ae5,_0x541454]=_0x436060['split'](':');if(_0x34058b['end']['isEqual'](_0x4ae9f8['nextPosition'])&&_0xe5f094['shift'](),(_0x4ae9f8['previousPosition']['isEqual'](_0x34058b['start'])||_0x4ae9f8['previousPosition']['isAfter'](_0x34058b['start']))&&('insertion'==_0x256ae5?_0x4ae9f8['isAdded']={'userId':_0x541454}:'deletion'==_0x256ae5&&(_0x4ae9f8['isRemoved']={'userId':_0x541454})),0x0==_0xe5f094['length'])break;}return _0x25284c;}['_refreshStartEndIndex'](_0x229a22){const _0x1f1165=new Map();for(let _0x50f8ff=0x0;_0x50f8ff<_0x229a22['length'];_0x50f8ff++)'text'===_0x229a22[_0x50f8ff]['type']?(_0x229a22[_0x50f8ff]['item']['startIndex']=_0x50f8ff,_0x229a22[_0x50f8ff]['item']['endIndex']=_0x50f8ff):('elementStart'===_0x229a22[_0x50f8ff]['type']?_0x229a22[_0x50f8ff]['item']['startIndex']=_0x50f8ff:'elementEnd'===_0x229a22[_0x50f8ff]['type']&&(_0x229a22[_0x50f8ff]['item']['endIndex']=_0x50f8ff),_0x1f1165['set'](_0x229a22[_0x50f8ff]['id'],_0x50f8ff));for(const _0x36d1cc of _0x1f1165['values']())'elementStart'===_0x229a22[_0x36d1cc]['type']?_0x229a22[_0x36d1cc]['item']['endIndex']=_0x1f1165['get'](_0x229a22[_0x36d1cc]['pairId']):'elementEnd'===_0x229a22[_0x36d1cc]['type']&&(_0x229a22[_0x36d1cc]['item']['startIndex']=_0x1f1165['get'](_0x229a22[_0x36d1cc]['pairId']));}['_processTape'](_0x55c063){for(let _0x1c6dce=0x0;_0x1c6dce<_0x55c063['length'];_0x1c6dce++){if('elementStart'===_0x55c063[_0x1c6dce]['type'])_0x55c063[_0x1c6dce]['item']['startIndex']=_0x1c6dce;else{if('elementEnd'===_0x55c063[_0x1c6dce]['type']){_0x55c063[_0x1c6dce]['item']['endIndex']=_0x1c6dce;const _0x16fc84=_0x55c063[_0x1c6dce]['item']['startIndex'];_0x55c063[_0x16fc84]['pairId']=_0x55c063[_0x1c6dce]['id'],_0x55c063[_0x1c6dce]['pairId']=_0x55c063[_0x16fc84]['id'];}else _0x55c063[_0x1c6dce]['item']['startIndex']=_0x1c6dce,_0x55c063[_0x1c6dce]['item']['endIndex']=_0x1c6dce,_0x55c063[_0x1c6dce]['pairId']=null;}_0x55c063[_0x1c6dce]['markersStart']||(_0x55c063[_0x1c6dce]['markersStart']=[],_0x55c063[_0x1c6dce]['markersEnd']=[]);}}['_markInsertions'](_0xcc6e5,_0x4c5cde){const _0x39aa5a=_0xcc6e5['filter'](_0x17fd9f=>!_0x17fd9f['isAdded']);for(let _0x1fb9b3=0x0;_0x1fb9b3<_0x4c5cde['length'];_0x1fb9b3++)_0x4c5cde[_0x1fb9b3]['isAdded']&&(_0x39aa5a[_0x1fb9b3]['isAdded']=_0x4c5cde[_0x1fb9b3]['isAdded']);}['_makeModelFromViewString'](_0x13d7b7){const _0x23b771=JSON['parse'](_0x13d7b7),_0x599b65=this['editor']['editing']['view']['document'],_0x207e73=new _0xa0965c(_0x599b65,_0x23b771['map'](_0x31b107=>this['_getViewObj'](_0x31b107)));return this['editor']['data']['toModel'](_0x207e73);}['_getViewObj'](_0x5a32d1){const _0x1773fe=this['editor']['editing']['view']['document'];if('string'==typeof _0x5a32d1)return new _0xad2221(_0x1773fe,_0x5a32d1);{const _0x549a4b=_0x5a32d1['children']['map'](_0x1507fb=>this['_getViewObj'](_0x1507fb));return new(Z[_0x5a32d1['type']]||_0x12e000)(_0x1773fe,_0x5a32d1['name'],_0x5a32d1['attributes'],_0x549a4b);}}['_getDiff'](_0x464de2,_0x4cbead=null){const _0x5564e4=this['repository']['getRevision'](_0x464de2),_0x1bc5c9=_0x4cbead?this['repository']['getRevision'](_0x4cbead):null,_0x418da1=this['_getRevisionsRange'](_0x5564e4,_0x1bc5c9),_0x383c7b=_0x418da1[_0x418da1['length']-0x1],_0x503a3e=new Map(),_0x38fbb4={'model':{},'attributes':{},'changes':[]},_0x43d8fa=new Set(),_0x546dcf=new Map();for(let _0x23da13=_0x418da1['length']-0x1;_0x23da13>=0x0;_0x23da13--){const _0x2eefb9=_0x418da1[_0x23da13];for(const _0x3db89f of Object['keys'](_0x2eefb9['diffData']))if(_0x2eefb9['diffData'][_0x3db89f]['attachChange']){const _0x25beea=_0x2eefb9['diffData'][_0x3db89f]['attachChange'];_0x25beea['isAttached']?(_0x43d8fa['add'](_0x3db89f),_0x546dcf['has'](_0x3db89f)&&_0x546dcf['get'](_0x3db89f)['userId']==_0x25beea['userId']?_0x546dcf['delete'](_0x3db89f):_0x546dcf['set'](_0x3db89f,_0x25beea)):_0x546dcf['has'](_0x3db89f)?(_0x43d8fa['delete'](_0x3db89f),_0x546dcf['delete'](_0x3db89f)):(_0x43d8fa['add'](_0x3db89f),_0x546dcf['set'](_0x3db89f,_0x25beea));}else _0x43d8fa['add'](_0x3db89f);}for(const _0x4ab8a9 of _0x43d8fa){const _0x1f0f62=_0x546dcf['has'](_0x4ab8a9)&&!_0x546dcf['get'](_0x4ab8a9)['isAttached'];let _0x579f81=_0x1f0f62?_0x418da1['length']-0x1:0x0;const _0x5c9646=_0x1f0f62?-0x1:0x1;for(;_0x418da1[_0x579f81];){const _0x122f5e=_0x418da1[_0x579f81];if(_0x122f5e['diffData'][_0x4ab8a9]){const _0x500e60=_0x1f0f62?_0x122f5e['diffData'][_0x4ab8a9]['attributesBefore']:_0x122f5e['diffData'][_0x4ab8a9]['attributesAfter'];_0x38fbb4['attributes'][_0x4ab8a9]=_0x500e60?_0x55297f(_0x500e60):{};break;}_0x579f81+=_0x5c9646;}}for(const _0x59a4de of _0x418da1){_0x59a4de['model']={};for(const _0x500cad of _0x59a4de['authors'])_0x503a3e['set'](_0x500cad['id'],_0x500cad);for(const _0x24d987 of _0x43d8fa){const _0x24ac39=_0x59a4de['diffData'][_0x24d987]?_0x59a4de['diffData'][_0x24d987]['insertions']:'[]',_0x269f7a=_0x59a4de['diffData'][_0x24d987]?_0x59a4de['diffData'][_0x24d987]['deletions']:'[]';_0x59a4de['model'][_0x24d987]={'insertions':this['_makeModelFromViewString'](_0x24ac39),'deletions':this['_makeModelFromViewString'](_0x269f7a)};}}for(const _0x47dcb0 of _0x43d8fa){let _0x49cf3c=null,_0xf5c70c=0x0;const _0x1a69ed=new Map(Array['from'](_0x5564e4['model'][_0x47dcb0]['insertions']['markers'])['filter'](([_0x2244a5])=>!_0x2244a5['startsWith']('revision:')));let _0xa7460a=0x0;for(const _0x2f3484 of _0x418da1){const _0x200585=this['_makeTape'](_0x2f3484['model'][_0x47dcb0]['insertions']);_0x2f3484==_0x5564e4?(_0x49cf3c=_0x200585,_0xf5c70c=_0x49cf3c['length'],_0x49cf3c['forEach'](_0x550363=>{_0x550363['id']=_0xa7460a++;}),this['_processTape'](_0x49cf3c)):this['_markInsertions'](_0x49cf3c,_0x200585);const _0x2ab8df=_0x49cf3c['filter'](_0x1f1894=>!_0x1f1894['isAdded'])['map'](_0x4fee18=>_0x4fee18['id']);let _0x351fa8=0x0;const _0x5c03f0=this['_makeTape'](_0x2f3484['model'][_0x47dcb0]['deletions']);_0x5c03f0['forEach'](_0x2a4e83=>{_0x2a4e83['isRemoved']?_0x2a4e83['id']=_0xf5c70c++:_0x2a4e83['id']=_0x2ab8df[_0x351fa8++];}),this['_processTape'](_0x5c03f0),this['_setDistance'](_0x49cf3c,'isAdded'),this['_setDistance'](_0x5c03f0,'isRemoved'),_0x2f3484==_0x5564e4&&this['_markMarkers'](_0x49cf3c,_0x1a69ed),_0x49cf3c=this['_joinTapes'](_0x49cf3c,_0x5c03f0),this['_refreshStartEndIndex'](_0x49cf3c),this['_setDistance'](_0x49cf3c,'isRemoved');}_0x49cf3c=_0x49cf3c['filter'](_0x3a5844=>!(_0x3a5844['isAdded']&&_0x3a5844['isRemoved']));const _0x18df74=new Map(_0x383c7b['model'][_0x47dcb0]['deletions']['markers']),_0x5cd180=new Set(_0x1a69ed['keys']());for(const _0x3e359c of _0x18df74['keys']())_0x5cd180['delete'](_0x3e359c);this['_markSuggestions'](_0x49cf3c,_0x5cd180),this['_fixObsoleteTags'](_0x49cf3c),_0x49cf3c=this['_removeMissingPairs'](_0x49cf3c),_0x49cf3c=this['_markMismatchedRemovedTags'](_0x49cf3c),_0x49cf3c=this['_removeUnsupportedChanges'](_0x49cf3c);const {root:_0x3d2e29,changes:_0x81d25c}=this['_makeModelFromTape'](_0x49cf3c,_0x503a3e,_0x47dcb0);_0x38fbb4['model'][_0x47dcb0]=_0x3d2e29;const _0x4a255d=_0x546dcf['get'](_0x47dcb0);if(_0x4a255d){const _0x167810=_0x503a3e['get'](_0x4a255d['userId']),_0x180ba2=new r({'author':_0x167810,'type':_0x4a255d['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x47dcb0});_0x81d25c['unshift'](_0x180ba2),_0x38fbb4['attributes'][_0x47dcb0]['revisionHistoryAttachChange']=_0x180ba2['id'];}_0x38fbb4['changes']=_0x38fbb4['changes']['concat'](_0x81d25c);}return _0x38fbb4;}['_markMarkers'](_0xc91a68,_0x4e27fc){for(let _0x4548cb=0x0;_0x4548cb<_0xc91a68['length'];_0x4548cb++)for(const [_0xc6cd08,_0x1e570d]of _0x4e27fc)_0x1e570d['start']['isEqual'](_0xc91a68[_0x4548cb]['previousPosition'])&&_0xc91a68[_0x4548cb]['markersStart']['push'](_0xc6cd08),_0x1e570d['end']['isEqual'](_0xc91a68[_0x4548cb]['nextPosition'])&&_0xc91a68[_0x4548cb]['markersEnd']['push'](_0xc6cd08);}['_joinTapes'](_0x1dfc88,_0x300f49){let _0x31347e=[],_0x409903=0x0,_0x5c924d=0x0;for(;_0x409903<_0x1dfc88['length']||_0x5c924d<_0x300f49['length'];){const _0x466a5e=_0x1dfc88[_0x409903]||{},_0x4900ec=_0x300f49[_0x5c924d]||{};if(_0x466a5e['id']==_0x4900ec['id'])_0x409903++,_0x5c924d++,_0x31347e['push'](_0x466a5e);else{if(_0x4900ec['isRemoved']&&_0x466a5e['isAdded']){const {commonTape:_0x314faf,iEnd:_0xdf0667,jEnd:_0x124ccc}=this['_threeWayMerge'](_0x1dfc88,_0x409903,_0x300f49,_0x5c924d);_0x31347e=_0x31347e['concat'](_0x314faf),_0x409903=_0xdf0667,_0x5c924d=_0x124ccc;}else _0x4900ec['isRemoved']?(_0x5c924d++,_0x31347e['push'](_0x4900ec)):(_0x409903++,_0x31347e['push'](_0x466a5e));}}return _0x31347e;}['_markSuggestions'](_0x22fbed,_0x36dfd2){const _0x3eebe6=[];for(let _0x1265c9=0x0;_0x1265c9<_0x22fbed['length'];_0x1265c9++){for(let _0x12022b=0x0;_0x12022b<_0x22fbed[_0x1265c9]['markersStart']['length'];_0x12022b++){const _0x1ca55e=_0x22fbed[_0x1265c9]['markersStart'][_0x12022b];if(!_0x36dfd2['has'](_0x1ca55e))continue;const {group:_0x36e0d,type:_0xe8344,authorId:_0x5c97a2}=_0x316f89(_0x1ca55e);'revision-suggestion'!=_0x36e0d||'insertion'!=_0xe8344&&'deletion'!=_0xe8344||(_0x3eebe6['unshift']({'type':_0xe8344,'name':_0x1ca55e,'userId':_0x5c97a2}),_0x22fbed[_0x1265c9]['markersStart']['splice'](_0x12022b,0x1),_0x12022b--);}_0x12d1f8(_0x22fbed[_0x1265c9]);for(let _0x18b1b3=0x0;_0x18b1b3<_0x22fbed[_0x1265c9]['markersEnd']['length'];_0x18b1b3++){const _0x1de632=_0x22fbed[_0x1265c9]['markersEnd'][_0x18b1b3];if(!_0x36dfd2['has'](_0x1de632))continue;const {group:_0x4ab477,type:_0x3f497c}=_0x316f89(_0x1de632);if('revision-suggestion'!=_0x4ab477||'insertion'!=_0x3f497c&&'deletion'!=_0x3f497c)continue;_0x22fbed[_0x1265c9]['markersEnd']['splice'](_0x18b1b3,0x1),_0x18b1b3--;const _0x45d6a1=_0x3eebe6['findIndex'](_0x1fbe91=>_0x1fbe91['name']==_0x1de632);_0x45d6a1>-0x1&&_0x3eebe6['splice'](_0x45d6a1,0x1);}}function _0x316f89(_0x1f24ed){const _0x312711=_0x1f24ed['split'](':');return{'group':_0x312711[0x0],'type':_0x312711[0x1],'subType':_0x312711['length']>=0x5?_0x312711[0x2]:null,'id':_0x312711['length']<0x5?_0x312711[0x2]:_0x312711[0x3],'authorId':_0x312711['length']<0x5?_0x312711[0x3]:_0x312711[0x4],'markerCount':0x6==_0x312711['length']?_0x312711[0x5]:null};}function _0x12d1f8(_0x1795b1){for(let _0x2b86bc=0x0;_0x2b86bc<_0x3eebe6['length'];_0x2b86bc++){if(_0x1795b1['isAdded']&&'insertion'==_0x3eebe6[_0x2b86bc]['type'])return _0x1795b1['isAddSuggestion']=_0x3eebe6[_0x2b86bc],void delete _0x1795b1['isAdded'];if(!_0x1795b1['isAdded']&&!_0x1795b1['isRemoved']&&'deletion'==_0x3eebe6[_0x2b86bc]['type'])return void(_0x1795b1['isRemoveSuggestion']=_0x3eebe6[_0x2b86bc]);}}}['_setDistance'](_0x605cd5,_0x10f254){let _0x38decc=0x0,_0x249302=!0x1;const _0x14e231=new Map();for(const _0x46bd4b of _0x605cd5)_0x46bd4b[_0x10f254]?_0x249302&&(_0x38decc++,_0x249302=!0x1):(_0x38decc++,_0x249302=!0x0),_0x14e231['set'](_0x46bd4b['id'],_0x38decc);for(let _0x2427c8=0x0;_0x2427c8<_0x605cd5['length'];_0x2427c8++){if('isRemoved'==_0x10f254&&_0x605cd5[_0x2427c8]['isAdded']||'isAdded'==_0x10f254&&_0x605cd5[_0x2427c8]['isRemoved'])continue;if('text'==_0x605cd5[_0x2427c8]['type']){_0x605cd5[_0x2427c8]['distance']=0x0;continue;}const _0x32b8ff=_0x14e231['get'](_0x605cd5[_0x2427c8]['pairId']),_0x503f7f=_0x14e231['get'](_0x605cd5[_0x2427c8]['id']);_0x605cd5[_0x2427c8]['distance']=_0x32b8ff-_0x503f7f;}}['_getRevisionsRange'](_0x204964,_0x119649,_0x7b0dbb=!0x1){const _0x233ed1=[];let _0x428ba2=this['repository']['getIndex'](_0x204964),_0x513f9b=this['repository']['getIndex'](_0x119649);for(-0x1==_0x513f9b&&(_0x513f9b=this['repository']['_revisions']['length'],_0x7b0dbb=!0x1);_0x428ba2<_0x513f9b;)_0x233ed1['push'](this['repository']['getRevision'](_0x428ba2)),_0x428ba2++;return _0x7b0dbb&&_0x233ed1['push'](this['repository']['getRevision'](_0x428ba2)),_0x233ed1;}['_threeWayMerge'](_0x4185fa,_0x944a3a,_0x54e1d8,_0x5999ca){const _0x28a44f=this['editor']['model']['schema'];let _0x2519fa=_0x944a3a;for(;_0x4185fa[_0x2519fa]&&_0x4185fa[_0x2519fa]['isAdded'];)_0x2519fa++;let _0x2ec46b=_0x5999ca;for(;_0x54e1d8[_0x2ec46b]&&_0x54e1d8[_0x2ec46b]['isRemoved'];)_0x2ec46b++;_0x233636(_0x4185fa,_0x944a3a,_0x2519fa),_0x233636(_0x54e1d8,_0x5999ca,_0x2ec46b);const _0xc29082=_0x54e1d8['slice'](_0x5999ca,_0x2ec46b)['concat'](_0x4185fa['slice'](_0x944a3a,_0x2519fa));return _0xc29082['sort']((_0x74da57,_0x2c6655)=>_0x74da57['side']!=_0x2c6655['side']?_0x74da57['side']-_0x2c6655['side']:_0x74da57['level']!=_0x2c6655['level']?_0x74da57['level']-_0x2c6655['level']:_0x74da57['distance']!=_0x2c6655['distance']?_0x2c6655['distance']-_0x74da57['distance']:!!_0x74da57['isAdded']!=!!_0x2c6655['isAdded']?-0x1==_0x74da57['side']||0x0==_0x74da57['side']?_0x74da57['isAdded']?-0x1:0x1:_0x74da57['isAdded']?0x1:-0x1:_0x74da57['index']-_0x2c6655['index']),{'commonTape':_0xc29082,'iEnd':_0x2519fa,'jEnd':_0x2ec46b};function _0x233636(_0x1c029a,_0x1333de,_0x4ee846){let _0x3b0efc=-0x1,_0x279dde=Number['POSITIVE_INFINITY'],_0x1eff22=!0x0;for(let _0x6a78ac=_0x1333de;_0x6a78ac<_0x4ee846;_0x6a78ac++)if(_0x28a44f['isInline'](_0x1c029a[_0x6a78ac]['item'])||(_0x1eff22=!0x1),_0x1c029a[_0x6a78ac]['item']['startIndex']<_0x1333de&&(_0x3b0efc=_0x6a78ac),_0x1c029a[_0x6a78ac]['item']['endIndex']>=_0x4ee846){_0x279dde=_0x6a78ac;break;}_0x1eff22&&(_0x3b0efc=_0x4ee846-0x1);for(let _0x4e71c6=_0x1333de;_0x4e71c6<_0x4ee846;_0x4e71c6++)_0x1c029a[_0x4e71c6]['side']=_0x4e71c6<=_0x3b0efc?-0x1:_0x4e71c6<_0x279dde?0x0:0x1,_0x1c029a[_0x4e71c6]['index']=_0x4e71c6;let _0x1973c3=0x0;for(let _0x32d022=_0x1333de;_0x32d022<=_0x3b0efc;_0x32d022++)0x0==_0x1c029a[_0x32d022]['distance']?_0x1c029a[_0x32d022]['level']=_0x1973c3:(_0x1973c3++,_0x1c029a[_0x32d022]['level']=_0x1973c3,_0x1973c3++);for(let _0x58d8d9=_0x1333de;_0x58d8d9<_0x4ee846;_0x58d8d9++)0x0==_0x1c029a[_0x58d8d9]['side']&&(_0x1c029a[_0x58d8d9]['level']=_0x1973c3);_0x1973c3=0x0;for(let _0x1cb547=_0x4ee846-0x1;_0x1cb547>=_0x279dde;_0x1cb547--)0x0==_0x1c029a[_0x1cb547]['distance']?_0x1c029a[_0x1cb547]['level']=_0x1973c3:(_0x1973c3--,_0x1c029a[_0x1cb547]['level']=_0x1973c3,_0x1973c3--);}}['_fixObsoleteTags'](_0x156116){const _0x129cf0=new Map(),_0x191c1c=this['editor']['model']['schema'];for(let _0x507d53=0x1;_0x507d53<_0x156116['length'];_0x507d53++){let _0x28f56c,_0x209d41,_0x32eefb;const _0x3d3ef5=_0x156116[_0x507d53],_0x278c39=_0x156116[_0x507d53-0x1];if('text'==_0x3d3ef5['type'])continue;if(_0x3d3ef5['type']!=_0x278c39['type'])continue;if(!_0x191c1c['isBlock'](_0x278c39['item'])||_0x191c1c['isLimit'](_0x278c39['item']))continue;if(!_0x191c1c['isBlock'](_0x3d3ef5['item'])||_0x191c1c['isLimit'](_0x3d3ef5['item']))continue;if((_0x156116[_0x507d53]['isAdded']||_0x156116[_0x507d53]['isAddSuggestion'])&&_0x156116[_0x507d53-0x1]['isRemoved'])_0x28f56c=_0x156116[_0x507d53],_0x209d41=_0x156116[_0x507d53-0x1],_0x32eefb=_0x507d53-0x1;else{if(!_0x156116[_0x507d53]['isRemoved']||!_0x156116[_0x507d53-0x1]['isAdded']&&!_0x156116[_0x507d53-0x1]['isAddSuggestion'])continue;_0x28f56c=_0x156116[_0x507d53-0x1],_0x209d41=_0x156116[_0x507d53],_0x32eefb=_0x507d53;}const _0x48dadb=_0x28f56c['level']==_0x209d41['level'],_0x1d21ae=Math['abs'](_0x28f56c['level'])<Math['abs'](_0x209d41['level'])&&0x0==_0x209d41['distance'];(_0x48dadb||_0x1d21ae)&&(_0x129cf0['set'](_0x209d41['id'],_0x28f56c['id']),_0x156116['splice'](_0x32eefb,0x1),_0x507d53--,_0x28f56c['isAdded']=!0x1);}for(let _0x2b6b12=0x0;_0x2b6b12<_0x156116['length'];_0x2b6b12++)_0x129cf0['has'](_0x156116[_0x2b6b12]['pairId'])&&(_0x156116[_0x2b6b12]['pairId']=_0x129cf0['get'](_0x156116[_0x2b6b12]['pairId']));}['_removeMissingPairs'](_0x9f11b6){const _0x518a00=new Set(_0x9f11b6['map'](_0x445068=>_0x445068['id']));for(let _0x1d5c40=0x0;_0x1d5c40<_0x9f11b6['length'];_0x1d5c40++)_0x518a00['has'](_0x9f11b6[_0x1d5c40]['pairId'])||0x0==_0x9f11b6[_0x1d5c40]['distance']||(_0x9f11b6[_0x1d5c40]['isIncorrect']=!0x0);return _0x9f11b6['filter'](_0x1d7e55=>!_0x1d7e55['isIncorrect']);}['_markMismatchedRemovedTags'](_0xd47609){const _0x9d5af9=new Set();for(let _0x43110f=0x0;_0x43110f<_0xd47609['length'];_0x43110f++){if(_0x9d5af9['has'](_0xd47609[_0x43110f]['id'])&&_0xd47609[_0x43110f]['isRemoved']&&(_0xd47609[_0x43110f]['isIncorrect']=!0x0),_0xd47609[_0x43110f]['isIncorrect'])continue;if(0x0==_0xd47609[_0x43110f]['distance'])continue;if('elementStart'!=_0xd47609[_0x43110f]['type'])continue;if(null==_0xd47609[_0x43110f]['pairId'])continue;let _0x4a8bcc=_0x43110f+0x1,_0x7277c4=0x0;for(;_0xd47609[_0x4a8bcc]['id']!=_0xd47609[_0x43110f]['pairId'];)'elementStart'==_0xd47609[_0x4a8bcc]['type']?_0x7277c4++:'elementEnd'==_0xd47609[_0x4a8bcc]['type']&&_0x7277c4--,_0x4a8bcc++;if(0x0!=_0x7277c4){if(_0xd47609[_0x43110f]['isRemoved'])_0xd47609[_0x43110f]['isIncorrect']=!0x0;else{for(;_0x4a8bcc!=_0x43110f;)_0xd47609[_0x4a8bcc]['isRemoved']&&0x0!=_0xd47609[_0x4a8bcc]['distance']&&(_0xd47609[_0x4a8bcc]['isIncorrect']=!0x0,_0x9d5af9['add'](_0xd47609[_0x4a8bcc]['pairId'])),_0x4a8bcc--;}}}return _0xd47609['filter'](_0x3247ab=>!_0x3247ab['isIncorrect']);}['_removeUnsupportedChanges'](_0x5e0046){const _0xafb6ce=this['editor']['model']['schema'];for(let _0x4dd003=0x0;_0x4dd003<_0x5e0046['length'];_0x4dd003++){if(!(_0x5e0046[_0x4dd003]['isAdded']||_0x5e0046[_0x4dd003]['isAddSuggestion']||_0x5e0046[_0x4dd003]['isRemoved']||_0x5e0046[_0x4dd003]['isRemoveSuggestion']))continue;if(0x0==_0x5e0046[_0x4dd003]['distance'])continue;const _0x1b8909=_0x5e0046[_0x4dd003]['item'];_0xafb6ce['isBlock'](_0x1b8909)||_0xafb6ce['isLimit'](_0x1b8909)||(_0x5e0046[_0x4dd003]['isAdded']&&delete _0x5e0046[_0x4dd003]['isAdded'],_0x5e0046[_0x4dd003]['isAddSuggestion']&&delete _0x5e0046[_0x4dd003]['isAddSuggestion'],_0x5e0046[_0x4dd003]['isRemoveSuggestion']&&delete _0x5e0046[_0x4dd003]['isRemoveSuggestion'],_0x5e0046[_0x4dd003]['isRemoved']&&(_0x5e0046[_0x4dd003]['isIncorrect']=!0x0));}return _0x5e0046['filter'](_0x59f20f=>!_0x59f20f['isIncorrect']);}['_makeModelFromTape'](_0x41c46c,_0x5878d6,_0x58fb81){const _0x19533d=new wt(),_0x45307f=[],_0x32f0a6=new Map(),_0x521597=this['editor']['model'],_0xd07678=_0x521597['schema'],_0x3e1264=[_0x19533d],_0x225e96={},_0x2be31a={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x3937a1=null;const _0x4d8b32=[0x0];for(let _0x118d2f=0x0;_0x118d2f<_0x41c46c['length'];_0x118d2f++)if('elementStart'===_0x41c46c[_0x118d2f]['type']){_0x41c46c[_0x118d2f]['previousPosition']=_0x521597['createPositionFromPath'](_0x19533d,_0x4d8b32);const _0x1082f8=new ft(_0x41c46c[_0x118d2f]['item']['name'],_0x41c46c[_0x118d2f]['item']['getAttributes']());_0x3e1264[0x0]['_appendChild'](_0x1082f8),_0x4d8b32['push'](0x0),_0x3e1264['unshift'](_0x1082f8),_0x41c46c[_0x118d2f]['nextPosition']=_0x521597['createPositionFromPath'](_0x19533d,_0x4d8b32);}else'elementEnd'===_0x41c46c[_0x118d2f]['type']?(_0x3e1264['shift'](),_0x41c46c[_0x118d2f]['previousPosition']=_0x521597['createPositionFromPath'](_0x19533d,_0x4d8b32),_0x4d8b32['pop'](),_0x4d8b32[_0x4d8b32['length']-0x1]++,_0x41c46c[_0x118d2f]['nextPosition']=_0x521597['createPositionFromPath'](_0x19533d,_0x4d8b32)):(_0x41c46c[_0x118d2f]['previousPosition']=_0x521597['createPositionFromPath'](_0x19533d,_0x4d8b32),_0x3937a1?_0x3937a1['_data']+=_0x41c46c[_0x118d2f]['item']['data']:_0x3937a1=new _t(_0x41c46c[_0x118d2f]['item']['data'],_0x41c46c[_0x118d2f]['item']['getAttributes']()),_0x41c46c[_0x118d2f+0x1]&&'text'===_0x41c46c[_0x118d2f+0x1]['type']&&_0x132ef1(_0x3937a1,_0x41c46c[_0x118d2f+0x1]['item'])||(_0x3e1264[0x0]['_appendChild'](_0x3937a1),_0x3937a1=null),_0x4d8b32[_0x4d8b32['length']-0x1]+=_0x41c46c[_0x118d2f]['item']['offsetSize'],_0x41c46c[_0x118d2f]['nextPosition']=_0x521597['createPositionFromPath'](_0x19533d,_0x4d8b32));for(let _0x5b6101=0x0;_0x5b6101<_0x41c46c['length'];_0x5b6101++){const _0xe953c7=_0x41c46c[_0x5b6101]['previousPosition'],_0x50cbc7=_0x41c46c[_0x5b6101]['nextPosition'];for(const _0x5a6124 of _0x41c46c[_0x5b6101]['markersStart'])_0x32f0a6['set'](_0x5a6124,{'start':_0xe953c7,'end':null});_0x24e63a('isRemoveSuggestion',_0x5b6101,_0xe953c7,_0x50cbc7),_0x24e63a('isAddSuggestion',_0x5b6101,_0xe953c7,_0x50cbc7),_0x24e63a('isRemoved',_0x5b6101,_0xe953c7,_0x50cbc7),_0x24e63a('isAdded',_0x5b6101,_0xe953c7,_0x50cbc7);for(const _0x43013c of _0x41c46c[_0x5b6101]['markersEnd']){_0x32f0a6['get'](_0x43013c)['end']=_0x50cbc7;}}for(const [_0x1c59b4,_0x435ff1]of _0x32f0a6){const _0xb2d109=this['editor']['model']['createRange'](_0x435ff1['start'],_0x435ff1['end']);_0x19533d['markers']['set'](_0x1c59b4,_0xb2d109);}return _0x45307f['sort']((_0x203708,_0x38aefb)=>{const _0x34fb20=_0x19533d['markers']['get']('revision:'+_0x203708['id']),_0x4719ef=_0x19533d['markers']['get']('revision:'+_0x38aefb['id']);return _0x34fb20['start']['isBefore'](_0x4719ef['start'])?-0x1:_0x34fb20['start']['isAfter'](_0x4719ef['start'])?0x1:_0x34fb20['end']['isBefore'](_0x4719ef['end'])?-0x1:_0x34fb20['end']['isAfter'](_0x4719ef['end'])?0x1:'add'===_0x203708['type']?-0x1:0x1;}),{'root':_0x19533d,'changes':_0x45307f};function _0x24e63a(_0x47756a,_0x3c681a,_0x5e7131,_0x15b23b){const _0x43fec6=!!_0x41c46c[_0x3c681a][_0x47756a],_0x5103a9=_0x43fec6?_0x41c46c[_0x3c681a][_0x47756a]['userId']:null,_0x5b93be=_0x3c681a===_0x41c46c['length']-0x1,_0x5578ed=_0x2be31a[_0x47756a][0x0],_0x4b80a6=_0xd07678['isObject'](_0x41c46c[_0x3c681a]['item']);!_0x225e96[_0x47756a]&&_0x43fec6?_0x225e96[_0x47756a]={'start':_0x5e7131,'tapeItem':_0x41c46c[_0x3c681a],'userId':_0x5103a9,'type':_0x47756a}:_0x225e96[_0x47756a]&&!_0x43fec6?(_0x225e96[_0x47756a]['end']=_0x5e7131,_0x312be7(_0x225e96[_0x47756a]),_0x225e96[_0x47756a]=null):_0x225e96[_0x47756a]&&_0x43fec6&&_0x225e96[_0x47756a]['userId']!==_0x5103a9&&(_0x225e96[_0x47756a]['end']=_0x5e7131,_0x5578ed&&_0x5578ed['userId']===_0x225e96[_0x47756a]['userId']||_0x312be7(_0x225e96[_0x47756a]),_0x225e96[_0x47756a]={'start':_0x5e7131,'tapeItem':_0x41c46c[_0x3c681a],'userId':_0x5103a9,'type':_0x47756a}),_0x225e96[_0x47756a]&&_0x4b80a6&&('elementStart'!==_0x41c46c[_0x3c681a]['type']||_0x5578ed&&_0x5578ed['userId']===_0x5103a9||_0x2be31a[_0x47756a]['unshift']({'userId':_0x5103a9,'object':_0x41c46c[_0x3c681a]['item'],'change':_0x225e96[_0x47756a]}),'elementEnd'===_0x41c46c[_0x3c681a]['type']&&_0x5578ed&&_0x5578ed['object']===_0x41c46c[_0x3c681a]['item']&&(_0x2be31a[_0x47756a]['shift'](),_0x225e96[_0x47756a]=_0x5578ed['change'])),_0x225e96[_0x47756a]&&_0x5b93be&&(_0x225e96[_0x47756a]['end']=_0x15b23b,_0x312be7(_0x225e96[_0x47756a]),_0x225e96[_0x47756a]=null);}function _0x312be7({start:_0x248615,end:_0x4d4b4b,tapeItem:_0x3d2b32,userId:_0x209a6a,type:_0x353c0a}){const _0x2d3aa9=_0x3d2b32['item'],_0x5bf27d=_0x521597['schema']['isBlock'](_0x2d3aa9)&&!_0x521597['schema']['isLimit'](_0x2d3aa9),_0x3e129d=_0x248615['nodeAfter']==_0x4d4b4b['parent']&&_0x4d4b4b['isAtStart'];if(_0x5bf27d&&_0x3e129d)return;const _0x31f40e=_0x521597['createRange'](_0x248615,_0x4d4b4b),_0x344907=_0x5878d6['get'](_0x209a6a),_0x1291c4=new r({'author':_0x344907,'type':'isAdded'==_0x353c0a||'isAddSuggestion'==_0x353c0a?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x353c0a||'isRemoveSuggestion'==_0x353c0a},'createdAt':new Date(),'rootName':_0x58fb81});_0x45307f['push'](_0x1291c4),_0x19533d['markers']['set']('revision:'+_0x1291c4['id'],_0x31f40e);}function _0x132ef1(_0xd8194d,_0x456f04){const _0x45d869=_0xd8194d['getAttributes'](),_0x33ec7d=_0x456f04['getAttributes']();for(const _0x48aefd of _0x45d869){if(_0x48aefd[0x1]!==_0x456f04['getAttribute'](_0x48aefd[0x0]))return!0x1;_0x33ec7d['next']();}return _0x33ec7d['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x4b7334=>{const _0x316a52=_0x4b7334['markerName']['split'](':')[0x1],_0x26672c=this['_getChangeFromId'](_0x316a52);if(!_0x26672c)return null;const _0x420240='add'==_0x26672c['type']?'insertion':'deletion',_0x5605f4=['ck-suggestion-marker','ck-suggestion-marker-'+_0x420240];return _0x26672c['data']['isSuggestion']&&_0x5605f4['push']('ck-suggestion-marker-'+_0x420240+'-new'),this['activeChange']==_0x26672c&&_0x5605f4['push']('ck-suggestion-marker--active'),{'classes':_0x5605f4,'attributes':{'data-change-id':_0x316a52}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x410f27=>{_0x410f27['on']('element:pre',(_0x476a48,_0x170532,_0x5130c5)=>{const _0x1f3737=_0x170532['viewItem']['getChild'](0x0);if(!_0x1f3737||!_0x1f3737['is']('element','code'))return;if(!_0x5130c5['consumable']['consume'](_0x1f3737,{'attributes':['vid_start','vid_end']}))return;const _0x46b1b8=_0x170532['modelRange']['start']['nodeAfter'];_0x5130c5['writer']['setAttribute']('vid_start',_0x1f3737['getAttribute']('vid_start'),_0x46b1b8),_0x5130c5['writer']['setAttribute']('vid_end',_0x1f3737['getAttribute']('vid_end'),_0x46b1b8);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0xd70b5c=>{_0xd70b5c['on']('element',(_0x26bc96,_0x1a88b0,_0x44ccaf)=>{if(!_0x44ccaf['consumable']['consume'](_0x1a88b0['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x1a88b0['modelRange']['isCollapsed'])return;const _0x394b63=_0x1a88b0['modelRange']['start']['nodeAfter'];_0x394b63['hasAttribute']('vid_start')||_0x394b63['hasAttribute']('vid')||(_0x44ccaf['writer']['setAttribute']('vid_start',_0x1a88b0['viewItem']['getAttribute']('vid_start'),_0x394b63),_0x44ccaf['writer']['setAttribute']('vid_end',_0x1a88b0['viewItem']['getAttribute']('vid_end'),_0x394b63));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x4407e7=>_0x4407e7['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x8559d8,[,_0x13f619])=>{['vid_start','vid_end','vid']['includes'](_0x13f619)&&(_0x8559d8['return']=!0x0,_0x8559d8['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x36ac36=>{_0x36ac36['on']('attribute:vid',(_0xac463f,_0x52e2df,_0x554167)=>{if('\x20'!=_0x52e2df['item']['data']||_0x52e2df['item']['parent']['maxOffset']>0x1)return;if(!_0x554167['consumable']['consume'](_0x52e2df['item'],_0xac463f['name']))return;const _0x42ab09=_0x554167['writer'],_0x1f6f5e=_0x554167['mapper']['toViewRange'](_0x52e2df['range']);_0x42ab09['wrap'](_0x1f6f5e,_0x42ab09['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x582a4c){const _0x8430d7=_0x582a4c['plugins']['get']('RevisionViewer');return(_0x2032d6,_0x1cc5eb,_0x3af471)=>{const _0x1833f8=_0x1cc5eb['markerName']['split'](':')[0x1],_0x5c09b7=_0x8430d7['_getChangeFromId'](_0x1833f8);if(!_0x5c09b7)return null;const _0x5a7542='add'==_0x5c09b7['type']?'split':'merge';if(!_0x3af471['consumable']['test'](_0x1cc5eb['markerRange'],_0x2032d6['name']))return;const _0x3776fb=_0x1cc5eb['markerRange']['getWalker'](),_0x142ee9=_0x1cc5eb['markerRange']['start'],_0x4d8f2e=_0x582a4c['model']['schema'];let _0x427081=null,_0x3215af=null,_0x6511a=!0x1,_0x235738=!0x1;for(const _0x3328e2 of _0x3776fb){const _0x19c286=_0x3328e2['item'];_0x6511a=_0x6511a||_0x4d8f2e['isContent'](_0x19c286);const _0x439745=_0x3af471['mapper']['toViewElement'](_0x19c286);if(_0x439745&&_0x439745['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x3328e2['type']&&(_0x4d8f2e['isBlock'](_0x19c286)&&!_0x4d8f2e['isLimit'](_0x19c286)&&(_0x19c286['nextSibling']||_0x142ee9['isAtEnd']?_0x427081&&_0x427081['parent']==_0x19c286||(_0x427081=_0x19c286,_0x407edf(_0x3328e2['previousPosition']),_0x235738=!0x0):_0x3215af=_0x3215af||_0x3328e2['previousPosition']));}function _0x407edf(_0xfa06a4){const _0x132830=_0x3af471['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x5a7542}),_0x5f4c2b=_0x3af471['mapper']['toViewPosition'](_0xfa06a4);_0x5c09b7['data']['isSuggestion']&&_0x3af471['writer']['addClass']('ck-suggestion-marker-'+_0x5a7542+'-new',_0x132830),_0x8430d7['activeChange']==_0x5c09b7&&_0x3af471['writer']['addClass']('ck-suggestion-marker--active',_0x132830),_0x3af471['writer']['insert'](_0x5f4c2b,_0x132830),_0x3af471['mapper']['bindElementToMarker'](_0x132830,_0x1cc5eb['markerName']);}_0x6511a||_0x235738||!_0x3215af||_0x407edf(_0x3215af);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x116dcb,_0x3b4cc8,_0x240be8)=>{const _0x9b88f7=_0x240be8['mapper']['markerNameToElements'](_0x3b4cc8['markerName']);if(_0x9b88f7){for(const _0x4e2ff3 of _0x9b88f7)(_0x4e2ff3['hasClass']('ck-suggestion-marker-split')||_0x4e2ff3['hasClass']('ck-suggestion-marker-merge'))&&(_0x240be8['mapper']['unbindElementFromMarkerName'](_0x4e2ff3,_0x3b4cc8['markerName']),_0x240be8['writer']['remove'](_0x4e2ff3));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x311c95,_0x5a779f,_0x121ffe)=>{const _0x556d47=_0x5a779f['markerName']['split'](':')[0x1],_0x14b619=this['_getChangeFromId'](_0x556d47);if(!_0x14b619)return null;const _0x4faff5='add'==_0x14b619['type']?'split':'merge';if(_0x121ffe['consumable']['test'](_0x5a779f['markerRange'],_0x311c95['name']))for(const _0x54343e of _0x5a779f['markerRange']['getItems']()){if(!_0x54343e['is']('element','softBreak'))continue;const _0x21a9a8=_0x121ffe['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x4faff5}),_0x63f21c=_0x121ffe['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x54343e));_0x14b619['data']['isSuggestion']&&_0x121ffe['writer']['addClass']('ck-suggestion-marker-'+_0x4faff5+'-new',_0x21a9a8),this['activeChange']==_0x14b619&&_0x121ffe['writer']['addClass']('ck-suggestion-marker--active',_0x21a9a8),_0x121ffe['writer']['insert'](_0x63f21c,_0x21a9a8),_0x121ffe['mapper']['bindElementToMarker'](_0x21a9a8,_0x5a779f['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x20fe6e=>{for(const _0x4af5b0 of this['editor']['model']['document']['getRootNames']()){const _0x10b57e=this['editor']['model']['document']['getRoot'](_0x4af5b0),_0x441716=this['editor']['editing']['view']['document']['getRoot'](_0x4af5b0);if(_0x441716){const _0x1a754d=_0x10b57e['getAttribute']('revisionHistoryAttachChange');if(_0x20fe6e['removeAttribute']('data-change-id',_0x441716),_0x20fe6e['removeClass']('ck-revision-history-root-add',_0x441716),_0x20fe6e['removeClass']('ck-revision-history-root-remove',_0x441716),_0x20fe6e['removeClass']('ck-revision-history-root--active',_0x441716),_0x1a754d){const _0x364267=this['_getChangeFromId'](_0x1a754d);if(!_0x364267)return null;_0x20fe6e['setAttribute']('data-change-id',_0x1a754d,_0x441716),_0x20fe6e['addClass']('ck-revision-history-root-'+_0x364267['type'],_0x441716),this['activeChange']==_0x364267&&_0x20fe6e['addClass']('ck-revision-history-root--active',_0x441716);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x595d93=>'revision-comment:'+_0x595d93,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x372ada=>'revision-suggestion:'+_0x372ada,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x59312d=>({'name':'suggestion:'+_0x59312d,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x3b4ff7=>{const _0x5644=_0x3b4ff7['markerName']['split'](':')[0x1];return'insertion'!=_0x5644&&'deletion'!=_0x5644?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x5644]};}}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:deletion',tt(this['editor'],'merge'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:insertion',tt(this['editor'],'split'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision-suggestion',(_0x2fe8bb,_0x350b68,_0x131ece)=>{const _0x24bef6=_0x131ece['mapper']['markerNameToElements'](_0x350b68['markerName']);if(_0x24bef6){for(const _0x27a433 of _0x24bef6)_0x27a433['is']('uiElement')&&(_0x131ece['mapper']['unbindElementFromMarkerName'](_0x27a433,_0x350b68['markerName']),_0x131ece['writer']['remove'](_0x27a433));}},{'priority':'high'});}['_getChangeFromId'](_0x386f07){return this['_changeIdToChange']['get'](_0x386f07);}['_getViewForChange'](_0x120a3b){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new Y(this['editor']['locale'],_0x120a3b),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x33d7e5,_0x2b5e70,_0x5454d1,_0x5e32b2)=>{_0x5e32b2&&this['_balloon']['remove'](_0x5e32b2),_0x5454d1&&(this['_balloon']['add']({'view':_0x5454d1,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x33e030=this['editor']['editing'],_0x2415b1=this['_getChangeFromId'](_0x5454d1['changeId']);let _0x2041e3;if(_0x2415b1['data']['isOnRoot']){const _0x56389c=_0x33e030['view']['getDomRoot'](_0x2415b1['rootName']);_0x2041e3=Array['from'](_0x56389c['getClientRects']());}else{const _0x5b72fa=this['editor']['model']['markers']['get']('revision:'+_0x5454d1['changeId']);_0x2041e3=Array['from'](_0x33e030['mapper']['markerNameToElements'](_0x5b72fa['name']))['map'](_0x2dae25=>_0x33e030['view']['domConverter']['mapViewToDom'](_0x2dae25))['map'](_0x47a9fc=>Array['from'](_0x47a9fc['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x2041e3[0x0];return _0x2041e3['find'](_0x5731ce=>_0x5731ce['top']-0x3<=this['_activeViewTarget']['y']&&_0x5731ce['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x5731ce['left']-0x3<=this['_activeViewTarget']['x']&&_0x5731ce['right']+0x3>=this['_activeViewTarget']['x'])||_0x2041e3[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x470ca9,_0x203da5,_0x3e88ad,_0x20d1d7)=>{this['activeView']=_0x3e88ad?this['_getViewForChange'](_0x3e88ad):null,this['editor']['model']['change'](()=>{const _0xea6154=this['editor']['editing'];_0x20d1d7&&(_0x20d1d7['data']['isOnRoot']?_0xea6154['view']['change'](_0x20fac7=>{_0x20fac7['removeClass']('ck-revision-history-root--active',_0xea6154['view']['document']['getRoot'](_0x20d1d7['rootName']));}):_0xea6154['reconvertMarker']('revision:'+_0x20d1d7['id'])),_0x3e88ad&&(_0x3e88ad['data']['isOnRoot']?_0xea6154['view']['change'](_0x24bec8=>{_0x24bec8['addClass']('ck-revision-history-root--active',_0xea6154['view']['document']['getRoot'](_0x3e88ad['rootName']));}):_0xea6154['reconvertMarker']('revision:'+_0x3e88ad['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x573783,_0x3b5212)=>{if(this['activeChange'])return;const _0x5b0017=this['_findChangeIdFromDomTarget'](_0x3b5212['target']),_0x4fa498=this['_changeIdToChange']['get'](_0x5b0017);_0x4fa498?(this['_activeViewTarget']={'x':_0x3b5212['domEvent']['x'],'y':_0x3b5212['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x4fa498)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x3e4d05,_0x4b965d)=>{const _0x4b4631=this['_findChangeIdFromDomTarget'](_0x4b965d['target']),_0x5bf161=this['_changeIdToChange']['get'](_0x4b4631);_0x5bf161?(this['_activeViewTarget']={'x':_0x4b965d['domEvent']['x'],'y':_0x4b965d['domEvent']['y']},_0x5bf161===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x5bf161):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x4ef2b2){do{const _0x39c20d=_0x4ef2b2['getAttribute']('data-change-id');if(_0x39c20d)return _0x39c20d;_0x4ef2b2=_0x4ef2b2['parent'];}while(_0x4ef2b2);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x3950d5=>{for(const _0x566a8d of this['editor']['model']['markers'])_0x3950d5['removeMarker'](_0x566a8d);});}}function tt(_0x546054,_0x4c2ab8){return(_0x51f047,_0x4af7cf,_0x5bbe68)=>{if(!_0x5bbe68['consumable']['test'](_0x4af7cf['markerRange'],_0x51f047['name']))return;const _0x308786=_0x4af7cf['markerRange']['getWalker'](),_0xc48cab=_0x4af7cf['markerRange']['start'],_0x49dfe4=_0x546054['model']['schema'];let _0x14577c=null,_0x2b9a57=null,_0x3a15b4=!0x1,_0x4af19d=!0x1;for(const _0xb42322 of _0x308786){const _0x859f64=_0xb42322['item'];_0x3a15b4=_0x3a15b4||_0x49dfe4['isContent'](_0x859f64);const _0x38b6f3=_0x5bbe68['mapper']['toViewElement'](_0x859f64);if(_0x38b6f3&&_0x38b6f3['getCustomProperty']('addHighlight'))return;'elementEnd'==_0xb42322['type']&&(_0x49dfe4['isBlock'](_0x859f64)&&!_0x49dfe4['isLimit'](_0x859f64)&&(_0x859f64['nextSibling']||_0xc48cab['isAtEnd']?_0x14577c&&_0x14577c['parent']==_0x859f64||(_0x14577c=_0x859f64,_0x246e0d(_0xb42322['previousPosition']),_0x4af19d=!0x0):_0x2b9a57=_0x2b9a57||_0xb42322['previousPosition']));}function _0x246e0d(_0x22db84){const _0xd02cbc=_0x5bbe68['mapper']['toViewPosition'](_0x22db84),_0x2f03fc=_0x5bbe68['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x4c2ab8});_0x5bbe68['writer']['insert'](_0xd02cbc,_0x2f03fc),_0x5bbe68['mapper']['bindElementToMarker'](_0x2f03fc,_0x4af7cf['markerName']);}_0x3a15b4||_0x4af19d||!_0x2b9a57||_0x246e0d(_0x2b9a57);};}class yt extends _0x1209ce{constructor(_0x206b7b){super(_0x206b7b);const _0x31563e=_0x206b7b['plugins']['get'](d);this['affectsData']=!0x1,this['listenTo'](_0x31563e,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x31563e,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x5c41ce=this['editor'],_0x55f519=_0x5c41ce['plugins']['get'](d),_0x9874a7=_0x55f519['isReady']?_0x55f519['diff']['newRevisionId']:null;_0x5c41ce['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x9874a7);}['refresh'](){const {isReady:_0x45afcd,isEnabled:_0x40b336,repository:_0x4fa29a,diff:_0x2e3de3}=this['editor']['plugins']['get'](d),_0x3878d0=_0x2e3de3&&_0x4fa29a['getLaterVisibleRevision'](_0x2e3de3['newRevisionId']);this['isEnabled']=_0x45afcd&&_0x40b336&&Boolean(_0x3878d0);}}class bt extends _0x1209ce{['_step'];constructor(_0xbb7a5d,{direction:_0x493abe}){super(_0xbb7a5d);const _0x7e1df6=_0xbb7a5d['plugins']['get'](d);this['affectsData']=!0x1,this['_step']='forward'===_0x493abe?0x1:-0x1,this['listenTo'](_0x7e1df6,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x7e1df6,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x7e1df6,'change:activeChange',()=>this['refresh']());}['execute'](){const _0xb80eaa=this['editor'],_0x359ee8=_0xb80eaa['plugins']['get'](d),{isNavigationMode:_0x5a8ec2,currentChangeNumber:_0x2f373f}=_0x359ee8;let _0x9e47f5;if(_0x359ee8['activeChange']=_0x5a8ec2?_0x359ee8['diff']['changes']['get'](_0x2f373f+this['_step']):_0x359ee8['diff']['changes']['first'],_0x359ee8['activeChange']['data']['isOnRoot'])_0x9e47f5=_0xb80eaa['editing']['view']['getDomRoot'](_0x359ee8['activeChange']['rootName']);else{const _0x1b23b7=_0xb80eaa['model']['markers']['get']('revision:'+_0x359ee8['activeChange']['id']);_0x9e47f5=_0x123f5b(_0xb80eaa['editing'],_0x1b23b7);}_0x342911({'target':_0x9e47f5,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0xedc712,currentChangeNumber:_0x4c568,numberOfChanges:_0x292730,isReady:_0x40fa5c,isEnabled:_0x2ba38e}=this['editor']['plugins']['get'](d);this['isEnabled']=!!(_0x2ba38e&&_0x40fa5c&&_0x292730)&&(!_0xedc712||(0x1===this['_step']?_0x4c568<_0x292730-0x1:_0x4c568>0x0));}}class di extends _0xbc5f18{constructor(_0x35def8){super(_0x35def8);const _0x2dcd96=this['bindTemplate'],_0x18af22=new _0x10c58e(_0x35def8),_0x482ad3=new _0x10c58e(_0x35def8);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',(_0x5253e7,_0x15e477)=>_0x5253e7&&_0x15e477>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x15d86d,_0x2b7133,_0x3e05b7,_0x24b3b5)=>{if(!_0x15d86d)return R(_0x35def8,'Loading...');if(!_0x3e05b7)return R(_0x35def8,'No\x20changes');const _0xe4f320=R(_0x35def8,'NUMBER_OF_CHANGES',_0x3e05b7);return _0x24b3b5?R(_0x35def8,'X_OF_Y_CHANGES',[_0x2b7133+0x1,_0x3e05b7]):_0xe4f320;}),_0x18af22['set']({'label':R(_0x35def8,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':'<svg\x20viewBox=\x220\x200\x2020\x2020\x22\x20xmlns=\x22http://www.w3.org/2000/svg\x22><path\x20d=\x22M16.435\x2014.494a.75.75\x200\x200\x200\x201.197-.899l-.067-.089-6.992-8a.75.75\x200\x200\x200-1.05-.078l-.079.078-7.008\x208a.75.75\x200\x200\x200\x201.049\x201.066l.08-.078\x206.442-7.354\x206.428\x207.354z\x22/></svg>\x0a'}),_0x482ad3['set']({'label':R(_0x35def8,'Show\x20next\x20change'),'tooltip':!0x0,'icon':'<svg\x20viewBox=\x220\x200\x2020\x2020\x22\x20xmlns=\x22http://www.w3.org/2000/svg\x22><path\x20d=\x22M16.435\x205.506a.75.75\x200\x200\x201\x201.197.899l-.067.089-6.992\x208a.75.75\x200\x200\x201-1.05.078l-.079-.078-7.008-8a.75.75\x200\x200\x201\x201.049-1.066l.08.078\x206.442\x207.354\x206.428-7.354z\x22/></svg>\x0a'}),_0x18af22['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x482ad3['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x18af22['on']('execute',()=>this['fire']('execute','backward')),_0x482ad3['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',_0x2dcd96['if']('_isStatusLabelVisible','ck-hidden',_0x51b83c=>!_0x51b83c)]},'children':[{'text':_0x2dcd96['to']('isNavigationMode',_0x178b81=>_0x178b81?R(_0x35def8,'EDIT_X_OF_Y_REVISIONS')+':\x20':R(_0x35def8,'Total')+':\x20')}]},{'text':_0x2dcd96['to']('_statusText')}]},new _0x440133(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x18af22,_0x482ad3]}]});}}const ce='ck-editor__editable__loading-overlay';class ae extends _0x49d8e7{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x5f1c60=this['editor']['editing']['view'];_0x5f1c60['change'](_0x49438f=>{for(const _0x3cfcd1 of _0x5f1c60['document']['roots'])_0x49438f['addClass'](ce,_0x3cfcd1);});}['hide'](){const _0x11821c=this['editor']['editing']['view'];_0x11821c['change'](_0x307750=>{for(const _0x3561f2 of _0x11821c['document']['roots'])_0x307750['removeClass'](ce,_0x3561f2);});}}class m extends _0x49d8e7{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[d,ae];}['init'](){const _0x5272eb=this['editor'],_0x2eb286=_0x5272eb['plugins']['get'](d),_0x536138=_0x5272eb['plugins']['get'](ae);_0x5272eb['ui']['componentFactory']['add']('exitToEditing',_0x3d684e=>{const _0x3de9fa=new _0x10c58e(_0x3d684e);return _0x3de9fa['set']({'label':R(_0x3d684e,'Back\x20to\x20editing'),'icon':_0x180720['undo'],'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x3de9fa,'execute',()=>{_0x5272eb['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x3de9fa;}),_0x5272eb['ui']['componentFactory']['add']('restoreRevision',_0x34ad52=>{const _0x3db68c=new _0x10c58e(_0x34ad52);return _0x3db68c['set']({'label':R(_0x34ad52,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x3db68c['bind']('isEnabled')['to'](_0x5272eb['commands']['get']('restoreRevision')),this['listenTo'](_0x3db68c,'execute',()=>_0x5272eb['execute']('restoreRevision')),_0x3db68c;}),_0x5272eb['ui']['componentFactory']['add']('changesNavigation',_0x31cc1c=>{const _0x59f187=new di(_0x31cc1c),_0x5af0a5=_0x5272eb['commands']['get']('showPreviousChange'),_0x410057=_0x5272eb['commands']['get']('showNextChange');return _0x59f187['bind']('isBackwardNavigationEnabled')['to'](_0x5af0a5,'isEnabled'),_0x59f187['bind']('isForwardNavigationEnabled')['to'](_0x410057,'isEnabled'),_0x59f187['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x2eb286),this['listenTo'](_0x59f187,'execute',(_0x280b88,_0xfd3b9d)=>{_0x5272eb['execute']('forward'===_0xfd3b9d?'showNextChange':'showPreviousChange');}),_0x59f187;}),_0x536138['show'](),_0x2eb286['on']('change:isReady',(_0x144fce,_0x14e589,_0x3766c5)=>{_0x3766c5?_0x536138['hide']():_0x536138['show']();});}}class mt extends at{['_resizeObserver']=null;constructor(_0x5654fa,_0x11b9d3){super(_0x5654fa,_0x11b9d3);const _0x497a33=this['bindTemplate'];this['set']({'label':R(_0x5654fa,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=R(_0x5654fa,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x497a33['to']('_tooltipString'),'data-cke-tooltip-position':'s','data-cke-tooltip-class':'ck-tooltip_multi-line'}});}['render'](){super['render'](),this['_resizeObserver']=new pt(this['fieldView']['element'],()=>this['_updateTooltipText']()),this['listenTo'](this['fieldView'],'input',()=>this['_updateTooltipText']());}['destroy'](){super['destroy'](),this['_resizeObserver']&&this['_resizeObserver']['destroy']();}['_updateTooltipText'](){const _0x16bce7=this['fieldView']['element'];this['_tooltipString']=_0x16bce7['scrollWidth']>_0x16bce7['clientWidth']&&_0x16bce7['value']||'';}}class ti extends _0xbc5f18{constructor(_0x1331fc,_0x34ffa2,_0x193c17){super(_0x1331fc);const _0xcd9202=new _0x5afc52();_0xcd9202['set']({'content':'<svg\x20viewBox=\x220\x200\x2011\x2010\x22\x20xmlns=\x22http://www.w3.org/2000/svg\x22\x20xmlns:xlink=\x22http://www.w3.org/1999/xlink\x22><path\x20d=\x22M5.5\x205C8.538\x205\x2011\x207.015\x2011\x209.5c0\x20.17-.011.336-.034.5H.034A3.732\x203.732\x200\x200\x201\x200\x209.5C0\x207.015\x202.462\x205\x205.5\x205zm0-5a2.5\x202.5\x200\x201\x201\x200\x205\x202.5\x202.5\x200\x200\x201\x200-5z\x22\x20/></svg>\x0a','viewBox':'0\x200\x2011\x2010'});const _0xdceda3=['ck','ck-revision-history-sidebar__revision-author'];_0x193c17&&_0xdceda3['push']('ck-revision-history-sidebar__revision-author_creator');const _0x2d0b06=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':R(_0x1331fc,_0x193c17?'Revision\x20creator':'Revision\x20author')},'children':[_0xcd9202,_0x34ffa2['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0xdceda3},'children':_0x2d0b06});}}function ni(_0x1a77cd,_0x38c21e){const _0x14d581=_0x1a77cd['bindTemplate'],_0x140746=_0x1a77cd['locale'],_0x7b184=_0x39648c(_0x140746);_0x7b184['panelPosition']='sw';const _0x440751=function(_0x3cc6b6,_0x3a04c5){const _0x17d2d0=function(_0x43f21d,_0x2cc2b9){const _0x1d4e63=_0x43f21d['locale'],_0x3a8de6={'Compare\x20against\x20selected':R(_0x1d4e63,'Compare\x20against\x20selected'),'Name\x20this\x20revision':R(_0x1d4e63,'Name\x20this\x20revision'),'Restore\x20this\x20revision':R(_0x1d4e63,'Restore\x20this\x20revision')};return _0x2cc2b9['map'](_0x15fe8e=>{const _0x2334ee=_0x3a8de6[_0x15fe8e['name']];return _0x2334ee&&_0x2334ee!==_0x15fe8e['name']&&(_0x15fe8e['name']=_0x2334ee),_0x15fe8e;});}(_0x3cc6b6,_0x3a04c5),_0x1b865f=new _0x3461b4();for(const _0x219182 of _0x17d2d0){const _0x218e3b={'type':'button','model':new to({'label':_0x219182['name'],'class':_0x219182['class'],'withText':!0x0,'role':'menuitem','_action':_0x219182['action']})};_0x218e3b['model']['bind']('isEnabled')['to'](_0x3cc6b6,'isActionsDropdownOpen',_0x58ed2b=>'function'!=typeof _0x219182['isEnabled']||(!_0x58ed2b||_0x219182['isEnabled'](_0x3cc6b6))),_0x1b865f['add'](_0x218e3b);}return _0x1b865f;}(_0x1a77cd,_0x38c21e);return _0x1a77cd['bind']('isActionsDropdownOpen')['to'](_0x7b184,'isOpen'),_0x7b184['buttonView']['set']({'label':R(_0x140746,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x180720['threeVerticalDots']}),_0x7b184['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x14d581['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x14d581['to'](_0x51f31c=>_0x51f31c['stopPropagation']())}}),_0x7b184['on']('execute',_0x1d834d=>{_0x1a77cd['isReady']&&'function'==typeof _0x1d834d['source']['_action']&&_0x1d834d['source']['_action'](_0x1a77cd);}),_0x3ff40b(_0x7b184,_0x440751,{'role':'menu'}),_0x7b184['listenTo'](_0x1a77cd,'change:isActionsDropdownOpen',(_0x2ab381,_0x3d06ca,_0x2e036f)=>{if(_0x2e036f)for(const _0x481d85 of _0x7b184['listView']['items']){const _0x296a80=_0x481d85['children']['first'],_0x2ac0a7=_0x38c21e['find'](_0x8d88ff=>_0x8d88ff['action']===_0x296a80['_action'])['isVisible'];_0x481d85['isVisible']=void 0x0===_0x2ac0a7||_0x2ac0a7(_0x1a77cd);}}),_0x7b184;}class ai extends/* #__PURE__ -- @preserve */
|
|
26
|
+
_0x11f94b(_0xbc5f18){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x1da1a2,_0x21c030,_0x38f7f2,_0x29e38f){super(_0x1da1a2);const _0x38e2cc=this['bindTemplate'],_0xdfd580=function(_0x51b93b,_0x499248){const _0x3e3b48=Array['from'](_0x499248['authors'])['filter'](_0x28f4c7=>_0x28f4c7!=_0x499248['creator']);return _0x499248['creator']&&_0x3e3b48['unshift'](_0x499248['creator']),_0x3e3b48['map'](_0x37e995=>new ti(_0x51b93b,_0x37e995,_0x37e995==_0x499248['creator']));}(_0x1da1a2,_0x21c030);this['id']=_0x21c030['id'],this['_revision']=_0x21c030,this['_requireRevisionName']=_0x29e38f,this['bind']('name','createdAt')['to'](_0x21c030),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0xe99069=>{return _0x3130c8=_0x1da1a2['uiLanguage'],(_0x54ac72=_0xe99069)['toLocaleDateString'](_0x3130c8,{'month':'long','day':'numeric'})+',\x20'+_0x54ac72['toLocaleTimeString'](_0x3130c8,{'hour':'numeric','minute':'numeric'});var _0x3130c8,_0x54ac72;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new mt(_0x1da1a2,_0x58483e),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x4c45c9=>_0x4c45c9||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x5ad0ae,_0x40455a)=>_0x5ad0ae&&_0x40455a),this['revisionActionsView']=_0x38f7f2&&_0x38f7f2['length']?ni(this,_0x38f7f2):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x38e2cc['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x38e2cc['if']('isEnabled','ck-disabled',_0x306db3=>!_0x306db3),_0x38e2cc['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x38e2cc['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x38e2cc['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':_0x38e2cc['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':_0xdfd580}]},this['revisionActionsView']],'on':{'click':_0x38e2cc['to'](_0x48eedb=>{_0x48eedb['srcElement']['closest']('.ck-thread__remove-confirm')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x26fe60=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x26fe60,'change',()=>{this['_requireRevisionName']&&!_0x26fe60['value']||this['fire']('setName',{'id':this['id'],'name':_0x26fe60['value']}),_0x26fe60['value']||(_0x26fe60['value']=this['name']?this['name']:this['_createdAtFormatted']);});}['select'](){this['isSelected']=!0x0;}['deselect'](){this['isSelected']=!0x1;}['highlight'](){this['isHighlighted']=!0x0;}['unhighlight'](){this['isHighlighted']=!0x1;}}function mi(_0x49179a,_0x480fa3){const _0x296641=_0x3b1d18['fromJSDate'](_0x49179a)['setLocale'](_0x480fa3),_0x2ce268=_0x3b1d18['local'](),_0x169e0f=_0x2ce268['minus']({'days':0x1})['startOf']('day');let _0x42fcb5,_0x1b724f;return _0x296641['hasSame'](_0x2ce268,'day')?(_0x42fcb5=_0x296641['startOf']('day')['toJSDate'](),_0x1b724f=_0x296641['toRelativeCalendar']()):_0x296641['hasSame'](_0x169e0f,'day')?(_0x42fcb5=_0x169e0f['toJSDate'](),_0x1b724f=_0x296641['toRelativeCalendar']()):_0x296641['hasSame'](_0x2ce268,'week')?(_0x42fcb5=_0x296641['startOf']('week')['toJSDate'](),_0x1b724f=_0x296641['weekdayLong']||''):_0x296641['hasSame'](_0x2ce268,'year')?(_0x42fcb5=_0x296641['startOf']('month')['toJSDate'](),_0x1b724f=_0x296641['monthLong']||''):(_0x42fcb5=_0x296641['startOf']('year')['toJSDate'](),_0x1b724f=String(_0x296641['year'])),{'startDate':_0x42fcb5,'localizedPeriodName':_0x1b724f};}class vi extends _0xbc5f18{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x2c229e,_0x59ff54,_0x468ac3,_0x1b1b7e){super(_0x2c229e);const _0x3f48f7=mi(_0x59ff54,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x59ff54,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x468ac3,this['_requireRevisionName']=_0x1b1b7e,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':_0x3f48f7}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x5b1584){const _0x9eb9ea=new ai(this['locale'],_0x5b1584,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x9eb9ea);}['removeRevision'](_0x162d65){const _0x31c48d=this['revisionViews']['find'](_0x46cf29=>_0x46cf29['id']===_0x162d65['id']);this['revisionViews']['remove'](_0x31c48d);}}class as extends _0xbc5f18{constructor(_0x7c2717){super(_0x7c2717);const _0x39c835=new _0x5afc52();_0x39c835['content']=_0x180720['history'],this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x39c835,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[R(_0x7c2717,'Revision\x20history')]}]});}}class li extends _0xbc5f18{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0xf57bf0,_0x53f40b,_0x1956cc,_0x491d25){super(_0xf57bf0);const _0x23cee9=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x53f40b,this['_revisionActions']=_0x1956cc,this['_requireRevisionName']=_0x491d25,this['on']('select',(_0xef3975,_0x2a0bd8)=>{this['fire']('revisionSelected',_0x2a0bd8);}),this['on']('setName',(_0x164341,_0x5739c4)=>{this['fire']('revisionSetName',_0x5739c4);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new as(_0xf57bf0),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x23cee9['if']('isEnabled','ck-disabled',_0x41412a=>!_0x41412a)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x47656c of this['_revisions'])this['_addRevision'](_0x47656c);this['_revisions']['on']('add',(_0x2f4ca5,_0x1810fe)=>{this['_addRevision'](_0x1810fe);}),this['_revisions']['on']('remove',(_0x19d3fc,_0x59e776)=>{this['_removeRevision'](_0x59e776);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x5a9882=>_0x5a9882['revisionViews']['map'](_0x3c754b=>_0x3c754b))['flat']();}['selectRevision'](_0x279e7d){for(const _0xc3013 of this['revisionViews'])_0x279e7d&&_0x279e7d['id']===_0xc3013['id']?_0xc3013['select']():_0xc3013['deselect']();}['highlightRevisions'](_0x5ea8a9){for(const _0x58cfd9 of this['revisionViews'])_0x5ea8a9['some'](({id:_0xcd87fc})=>_0xcd87fc===_0x58cfd9['id'])?_0x58cfd9['highlight']():_0x58cfd9['unhighlight']();}['_addRevision'](_0x37e212){const _0x1f19b4=mi(_0x37e212['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x22652e=this['timePeriodViews']['get'](0x0);_0x22652e&&_0x22652e['startDate']['getTime']()===_0x1f19b4['getTime']()||(_0x22652e=new vi(this['locale'],_0x1f19b4,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x22652e)),_0x22652e['addRevision'](_0x37e212);}['_removeRevision'](_0x1e977b){const _0x2ee3b7=mi(_0x1e977b['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x2ee3b7)['removeRevision'](_0x1e977b);}['_getTimePeriodViewByStartDate'](_0x45eb01){return this['timePeriodViews']['find'](_0x1d299a=>_0x1d299a['startDate']['getTime']()===_0x45eb01['getTime']());}}class g extends _0x49d8e7{['_revisionViewer'];['_revisionsRepository'];['_sidebarView'];static ['defaultRevisionActions']=/* #__PURE__ -- @preserve */
|
|
27
27
|
((()=>['compareAgainstSelected','restoreRevision','nameRevision'])());static ['availableRevisionActions']=/* #__PURE__ -- @preserve */
|
|
28
|
-
Rt();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[d];}constructor(
|
|
29
|
-
rt(it){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x2819fb,_0x418d49){super(_0x418d49),this['sourceElement']=_0x2819fb,this['model']['document']['createRoot']();const _0x868744=new st(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new et(this,_0x868744);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x4d38ba,_0x86b037){const _0x1ba017=new this(_0x4d38ba,_0x86b037);return await _0x1ba017['initPlugins'](),await _0x1ba017['ui']['init'](_0x4d38ba),await _0x1ba017['data']['init'](_0x1ba017['config']['get']('initialData')||''),_0x1ba017['fire']('ready'),_0x1ba017;}}const p=['RevisionHistoryUI','RestrictedEditingMode'];class k extends _0x49970d{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x233a39){function _0x42923f(_0x4cc187){return _0x4cc187['map'](_0x51cb7e=>String['fromCharCode'](_0x51cb7e))['join']('');}super(_0x233a39),this['result']='end',_0x233a39[_0x42923f([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x42923f([0x76,0x69,0x65,0x77])][_0x42923f([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x42923f([0x61,0x75,0x74,0x6f]),_0x233a39[_0x42923f([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x42923f([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x42923f([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x42923f([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x42923f([0x6f,0x6b])});}}class H extends _0x49970d{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l,u];}constructor(_0x5a0d95){if(super(_0x5a0d95),!this['editor']['config']['get']('revisionHistory'))throw new _0x1f287f('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x347559=>this['_showRevisionViewer']({..._0x347559,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0xa68891=>this['_closeRevisionViewer'](_0xa68891)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x46edca=>this['_restoreRevision'](_0x46edca)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x452dd9){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x452dd9;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x4e8a67){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x4e8a67);}['getRevision'](_0x421e05){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x421e05);}['getRevisions'](_0x9c6cc5){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x9c6cc5||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x3cbc5f=this['editor'],_0x4e6cb1=_0x2c872e(_0x3cbc5f,p),_0x457c7e=_0x3cbc5f['plugins']['get']('RevisionTracker'),_0x46c11d=_0x3cbc5f['plugins']['get']('Users')['users'];return _0x4e6cb1['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x4e6cb1['lazyRoots'],(_0x4e6cb1['plugins']['push'](k,d,m,class extends _0x49970d{static get['requires'](){return[d,'Users'];}['init'](){const _0x154762=this['editor']['plugins']['get']('Users');for(const _0x19800c of _0x46c11d)_0x19800c['isAnonymous']||_0x154762['getUser'](_0x19800c['id'])||_0x154762['addUser'](_0x19800c);const _0x51d101=_0x457c7e['repository']['getRevisions']();let _0x745ad2=null;const _0x49e391=this['editor']['plugins']['get']('RevisionViewer');_0x49e391['adapter']=_0x457c7e['adapter'],_0x49e391['bind']('isEnabled')['to'](_0x457c7e),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x3cbc5f,'isReadOnly',_0x3d606b=>!_0x3d606b);for(const _0x22a153 of _0x51d101){const _0x16f0fa=null===_0x22a153['creator'];if(_0x16f0fa&&_0x22a153['toVersion']===_0x22a153['fromVersion'])continue;const _0x5081e4=_0x22a153['toJSON']();_0x49e391['addRevisionData'](_0x5081e4,(_0x46e359,_0x5ced2e,_0x7c0235)=>{if(_0x16f0fa){if(_0x745ad2)_0x745ad2['_update'](_0x46e359,_0x5ced2e);else{if(!_0x5ced2e){const _0x2c7351=_0x7c0235['toJSON']();_0x2c7351['id']=_0x4f9a89(),_0x457c7e['saveRevision'](_0x2c7351,_0x7c0235['toVersion'])['then'](_0x3e1544=>{_0x745ad2=_0x3e1544;});}}}else _0x22a153['_update'](_0x46e359,_0x5ced2e);});}}},g),_0x4e6cb1);}['_enhanceShowRevisionViewerCallback'](){const _0xb8ed06=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x3130dc=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x119914=this['editor']['plugins']['get']('Autosave');await _0x119914['save']();}else await _0x3130dc['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x33ef7d=this['editor']['plugins']['get']('Dialog');_0x33ef7d['isOpen']&&_0x33ef7d['hide']();}const _0x1d3110=this['_getRevisionViewerEditorConfig']();return _0xb8ed06(_0x1d3110)['then'](_0x108411=>{return(this['_viewerEditor']=_0x108411,this['editor']['plugins']['has']('Annotations'))&&this['editor']['plugins']['get']('Annotations')['refreshVisibility'](),_0x108411;})['catch'](_0x19c120=>(console['error'](_0x19c120),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x282d1b=this['editor']['config']['get']('revisionHistory')['closeRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.closeRevisionViewerCallback',()=>(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['_viewerEditor']['plugins']['get']('RevisionViewer')['_cleanUp'](),_0x282d1b(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x4c6bd3=this['editor']['plugins']['get']('Annotations');_0x4c6bd3['refreshVisibility'](),_0x4c6bd3['refreshPositioning']();}})));}['_showRevisionViewer'](_0x20bb93){const _0x4a2d2e=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x499a79=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x1ccab4=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return w['create'](_0x1ccab4,_0x20bb93)['then'](_0x258509=>(_0x499a79['style']['display']='block',_0x4a2d2e['style']['display']='none',_0x258509));}['_closeRevisionViewer'](_0x1bdbff){const _0x298569=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x298569['style']['display']='',_0x1bdbff['destroy']();}async['_restoreRevision'](_0x323bfe){const _0xf0f63f=this['editor'],_0x5f52c8=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x3c730a=_0xf0f63f['plugins']['get']('RevisionTracker'),_0x15eb02=_0x5f52c8['repository']['getRevision'](_0x323bfe);let _0x13f9f1,_0x2e599c,_0x1778aa;try{_0x13f9f1=await _0x5f52c8['getRevisionData'](_0x15eb02),_0x2e599c=await _0x5f52c8['getRevisionRootsAttributes'](_0x15eb02);}catch(_0x24b58e){return void console['error'](_0x24b58e);}_0xf0f63f['model']['change'](_0x497a39=>{for(const _0x1b31c9 of Array['from'](_0xf0f63f['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x497a39['removeMarker'](_0x1b31c9);}),_0x5f52c8['isReady']=!0x1,_0xf0f63f['model']['enqueueChange'](_0x39437f=>{_0x39437f['setSelection'](null),_0x39437f['removeSelectionAttribute'](_0xf0f63f['model']['document']['selection']['getAttributeKeys']());const _0xd2ea6e=Object['keys'](_0x13f9f1);for(const _0x28bc20 of _0xf0f63f['model']['document']['roots'])'$graveyard'!=_0x28bc20['rootName']&&_0x28bc20['isAttached']()&&!_0xd2ea6e['includes'](_0x28bc20['rootName'])&&_0x39437f['detachRoot'](_0x28bc20);for(const _0x4c3bd2 of _0xd2ea6e){let _0xbe2190=_0xf0f63f['model']['document']['getRoot'](_0x4c3bd2);_0xbe2190&&_0xbe2190['isAttached']()||(_0xbe2190=_0x39437f['addRoot'](_0x4c3bd2));const _0x9ad024=_0x2e599c[_0x4c3bd2],_0x203fd5=Object['keys'](_0x9ad024),_0x224059=_0x13f9f1[_0x4c3bd2];for(const _0x1ac577 of _0xbe2190['getAttributeKeys']())_0x203fd5['includes'](_0x1ac577)||_0x39437f['removeAttribute'](_0x1ac577,_0xbe2190);for(const _0xce3f7c of _0x203fd5)_0x39437f['setAttribute'](_0xce3f7c,_0x2e599c[_0x4c3bd2][_0xce3f7c],_0xbe2190);_0x39437f['remove'](_0x39437f['createRangeIn'](_0xbe2190)),_0x39437f['insert'](_0xf0f63f['data']['parse'](_0x224059,_0xbe2190),_0xbe2190,0x0);}});const _0x445c1a=R(_0xf0f63f['locale'],'Restored');if(_0x15eb02['name'])_0x1778aa=-0x1==_0x15eb02['name']['indexOf'](_0x445c1a)?_0x445c1a+':\x20'+_0x15eb02['name']:_0x15eb02['name'];else _0x1778aa=_0x445c1a+':\x20'+(_0x15eb02['createdAt']['toLocaleDateString'](_0xf0f63f['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x15eb02['createdAt']['toLocaleTimeString'](_0xf0f63f['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x3c730a['saveRevision']({'name':_0x1778aa}),_0x5f52c8['isReady']=!0x0,_0xf0f63f['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{a as Revision,H as RevisionHistory,u as RevisionHistoryUI,l as RevisionTracker,d as RevisionViewer,le as RevisionViewerLoadingOverlay,m as RevisionViewerUI,j as RevisionsRepository,g as RevisionsSidebar};
|
|
28
|
+
Rt();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[d];}constructor(_0x303e57){super(_0x303e57),this['_revisionViewer']=_0x303e57['plugins']['get'](d),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0xb2fd90=this['_revisionsRepository']['_revisions'],_0x520a32=this['_createRevisionActions'](),_0x5216e4=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new li(this['editor']['locale'],_0xb2fd90,_0x520a32,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',(_0x3928f2,_0x5392fe)=>{_0x5392fe['revisionViews']['on']('add',(_0xdc9c8,_0x18c740)=>{_0x18c740['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)),_0x5216e4['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x26f7b9=this['_revisionsRepository']['getRevision'](0x0);if(_0x26f7b9){const _0xed270=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x26f7b9['id']);this['_revisionViewer']['compare'](_0x26f7b9,_0xed270);}}['_handleRevisionSelected'](_0x4ab5f5,_0x4602a6){const _0x3ba180=this['_revisionsRepository']['getRevision'](_0x4602a6['id']),_0x2a93c4=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x3ba180['id']);this['_revisionViewer']['compare'](_0x3ba180,_0x2a93c4);}['_handleRevisionSetName'](_0x482ef1,_0x18c9be){this['_revisionsRepository']['getRevision'](_0x18c9be['id'])['setName'](_0x18c9be['name']);}['_handleDiffChange'](_0x33ce4d,_0x3b83ea,_0x3d54a4){const _0x3efa0d=this['_revisionsRepository']['getRevisionsInDiff'](_0x3d54a4);_0x3efa0d['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x3efa0d),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x3efa0d[0x0]));}['_createRevisionActions'](){const _0x3ca2e9=this['editor'],_0x12b7e3=g['availableRevisionActions'],_0x24bd9e=_0x3ca2e9['config']['get']('revisionHistory.revisionActions')||g['defaultRevisionActions'];if(_0x24bd9e['length'])return _0x24bd9e['map'](_0x4b6165=>{const _0x25733e='string'==typeof _0x4b6165?Object['assign']({},_0x12b7e3[_0x4b6165]):_0x4b6165;return _0x25733e['action']=_0x25733e['action']['bind'](this,_0x3ca2e9),_0x25733e['isVisible']&&(_0x25733e['isVisible']=_0x25733e['isVisible']['bind'](this,_0x3ca2e9)),_0x25733e;});}}function Rt(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x462e94},_0x3a15f4)=>{const _0x5c94bd=_0x462e94['get'](d),_0x1b728c=_0x5c94bd['repository'];let _0x4f3c13=_0x5c94bd['diff']['newRevisionId'],_0x91a1b2=_0x3a15f4['id'];_0x1b728c['getIndex'](_0x4f3c13)>_0x1b728c['getIndex'](_0x91a1b2)&&([_0x4f3c13,_0x91a1b2]=[_0x91a1b2,_0x4f3c13]),_0x5c94bd['compare'](_0x4f3c13,_0x91a1b2);},'isVisible':({plugins:_0x5a7693},_0x6bd97b)=>{const _0x93a6e2=_0x5a7693['get'](d);return!(_0x93a6e2['repository']['getRevisionsInDiff'](_0x93a6e2['diff'])['length']>0x2)&&!_0x6bd97b['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x16c78b,{id:_0x463967})=>{_0x16c78b['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x463967);},'isVisible':({plugins:_0x112b5b},_0x264845)=>!!_0x112b5b['get'](d)['repository']['getLaterVisibleRevision'](_0x264845['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x4dd54c},{id:_0x2cb1af,revisionNameView:_0x2f8b3c})=>{const _0x4eb84a=_0x4dd54c['get'](d),_0x7a0b09=_0x4eb84a['repository']['getEarlierVisibleRevision'](_0x2cb1af);_0x4eb84a['compare'](_0x2cb1af,_0x7a0b09),_0x2f8b3c['focus'](),_0x2f8b3c['fieldView']['select']();}}};}class et extends ot{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x1641cf,_0x5d15a9){super(_0x1641cf),this['_view']=_0x5d15a9,this['_toolbarConfig']=ht(_0x1641cf['config']['get']('toolbar')),this['_elementReplacer']=new ct();}get['element'](){return this['view']['element'];}['init'](_0x4e108e){const _0x360461=this['editor'],_0x45c35d=this['view'],_0x2dcfdc=_0x360461['editing']['view'],_0x209ce1=_0x45c35d['editable'],_0x35fa62=_0x2dcfdc['document']['getRoot']();_0x209ce1['name']=_0x35fa62['rootName'],_0x45c35d['render']();const _0x2a0a11=_0x209ce1['element'];this['setEditableElement'](_0x209ce1['name'],_0x2a0a11),_0x45c35d['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x2dcfdc['attachDomRoot'](_0x2a0a11),this['_elementReplacer']['replace'](_0x4e108e,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x469cd3=this['view'],_0x1b862e=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x1b862e['detachDomRoot'](_0x469cd3['editable']['name']),_0x469cd3['destroy']();}['_initToolbar'](){const _0x15d520=this['view'];_0x15d520['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x15d520['stickyPanel']['limiterElement']=_0x15d520['element'],_0x15d520['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x4abafe})=>_0x4abafe),_0x15d520['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x15d520['toolbar']);}}class st extends dt{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x3f926a,_0xde324,_0x104f63={}){super(_0x3f926a),this['stickyPanel']=new lt(_0x3f926a),this['toolbar']=new nt(_0x3f926a,{'shouldGroupWhenFull':_0x104f63['shouldToolbarGroupWhenFull']}),this['_editable']=new ut(_0x3f926a,_0xde324);}['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
|
+
rt(it){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x3e32a7,_0x160909){super(_0x160909),this['sourceElement']=_0x3e32a7,this['model']['document']['createRoot']();const _0x173c51=new st(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new et(this,_0x173c51);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x12d15a,_0x4cf4fd){const _0x191abb=new this(_0x12d15a,_0x4cf4fd);return await _0x191abb['initPlugins'](),await _0x191abb['ui']['init'](_0x12d15a),await _0x191abb['data']['init'](_0x191abb['config']['get']('initialData')||''),_0x191abb['fire']('ready'),_0x191abb;}}const p=['RevisionHistoryUI','RestrictedEditingMode'];class k extends _0x49d8e7{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x258b16){function _0xedca5c(_0x444070){return _0x444070['map'](_0xab79e6=>String['fromCharCode'](_0xab79e6))['join']('');}super(_0x258b16),this['result']='end',_0x258b16[_0xedca5c([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0xedca5c([0x76,0x69,0x65,0x77])][_0xedca5c([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0xedca5c([0x61,0x75,0x74,0x6f]),_0x258b16[_0xedca5c([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0xedca5c([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0xedca5c([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0xedca5c([0x73,0x74,0x61,0x74,0x75,0x73])]:_0xedca5c([0x6f,0x6b])});}}class H extends _0x49d8e7{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l,u];}constructor(_0x57cac3){if(super(_0x57cac3),!this['editor']['config']['get']('revisionHistory'))throw new _0xccd322('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x40ed1e=>this['_showRevisionViewer']({..._0x40ed1e,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x971bd=>this['_closeRevisionViewer'](_0x971bd)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x3e7830=>this['_restoreRevision'](_0x3e7830)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x20fdff){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x20fdff;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x1e86cb){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x1e86cb);}['getRevision'](_0x29bf93){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x29bf93);}['getRevisions'](_0x3d58fe){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x3d58fe||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x24d3ba=this['editor'],_0x4ceef4=_0x4ba276(_0x24d3ba,p),_0x45beee=_0x24d3ba['plugins']['get']('RevisionTracker'),_0x195227=_0x24d3ba['plugins']['get']('Users')['users'];return _0x4ceef4['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x4ceef4['lazyRoots'],(_0x4ceef4['plugins']['push'](k,d,m,class extends _0x49d8e7{static get['requires'](){return[d,'Users'];}['init'](){const _0x5d599c=this['editor']['plugins']['get']('Users');for(const _0x3f27d5 of _0x195227)_0x3f27d5['isAnonymous']||_0x5d599c['getUser'](_0x3f27d5['id'])||_0x5d599c['addUser'](_0x3f27d5);const _0x4cddd0=_0x45beee['repository']['getRevisions']();let _0x54d7f1=null;const _0x5c7f2d=this['editor']['plugins']['get']('RevisionViewer');_0x5c7f2d['adapter']=_0x45beee['adapter'],_0x5c7f2d['bind']('isEnabled')['to'](_0x45beee),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x24d3ba,'isReadOnly',_0xe2f4e9=>!_0xe2f4e9);for(const _0x4cdc4f of _0x4cddd0){const _0x46780f=null===_0x4cdc4f['creator'];if(_0x46780f&&_0x4cdc4f['toVersion']===_0x4cdc4f['fromVersion'])continue;const _0x53a704=_0x4cdc4f['toJSON']();_0x5c7f2d['addRevisionData'](_0x53a704,(_0x4c713b,_0xdbc1dd,_0x12d135)=>{if(_0x46780f){if(_0x54d7f1)_0x54d7f1['_update'](_0x4c713b,_0xdbc1dd);else{if(!_0xdbc1dd){const _0x292927=_0x12d135['toJSON']();_0x292927['id']=_0x4d1572(),_0x45beee['saveRevision'](_0x292927,_0x12d135['toVersion'])['then'](_0x36663b=>{_0x54d7f1=_0x36663b;});}}}else _0x4cdc4f['_update'](_0x4c713b,_0xdbc1dd);});}}},g),_0x4ceef4);}['_enhanceShowRevisionViewerCallback'](){const _0x8aa1d3=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x18a414=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x741472=this['editor']['plugins']['get']('Autosave');await _0x741472['save']();}else await _0x18a414['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x4186ce=this['editor']['plugins']['get']('Dialog');_0x4186ce['isOpen']&&_0x4186ce['hide']();}const _0x387b66=this['_getRevisionViewerEditorConfig']();return _0x8aa1d3(_0x387b66)['then'](_0x1e46ca=>{return(this['_viewerEditor']=_0x1e46ca,this['editor']['plugins']['has']('Annotations'))&&this['editor']['plugins']['get']('Annotations')['refreshVisibility'](),_0x1e46ca;})['catch'](_0xbcca9c=>(console['error'](_0xbcca9c),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x159733=this['editor']['config']['get']('revisionHistory')['closeRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.closeRevisionViewerCallback',()=>(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['_viewerEditor']['plugins']['get']('RevisionViewer')['_cleanUp'](),_0x159733(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x46b32e=this['editor']['plugins']['get']('Annotations');_0x46b32e['refreshVisibility'](),_0x46b32e['refreshPositioning']();}})));}['_showRevisionViewer'](_0x3b771d){const _0x529cb7=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x4402ec=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x174554=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return w['create'](_0x174554,_0x3b771d)['then'](_0x445155=>(_0x4402ec['style']['display']='block',_0x529cb7['style']['display']='none',_0x445155));}['_closeRevisionViewer'](_0x3904d6){const _0x3322a9=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x3322a9['style']['display']='',_0x3904d6['destroy']();}async['_restoreRevision'](_0x4be4df){const _0x40aca4=this['editor'],_0x575302=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x2310f9=_0x40aca4['plugins']['get']('RevisionTracker'),_0x3eb0e2=_0x575302['repository']['getRevision'](_0x4be4df);let _0x5286be,_0x3e46b0,_0xb5bda8;try{_0x5286be=await _0x575302['getRevisionData'](_0x3eb0e2),_0x3e46b0=await _0x575302['getRevisionRootsAttributes'](_0x3eb0e2);}catch(_0x3f0434){return void console['error'](_0x3f0434);}_0x40aca4['model']['change'](_0x24307a=>{for(const _0x1d1e41 of Array['from'](_0x40aca4['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x24307a['removeMarker'](_0x1d1e41);}),_0x575302['isReady']=!0x1,_0x40aca4['model']['enqueueChange'](_0x585cfa=>{_0x585cfa['setSelection'](null),_0x585cfa['removeSelectionAttribute'](_0x40aca4['model']['document']['selection']['getAttributeKeys']());const _0x5d6b60=Object['keys'](_0x5286be);for(const _0x13b699 of _0x40aca4['model']['document']['roots'])'$graveyard'!=_0x13b699['rootName']&&_0x13b699['isAttached']()&&!_0x5d6b60['includes'](_0x13b699['rootName'])&&_0x585cfa['detachRoot'](_0x13b699);for(const _0x3d6b57 of _0x5d6b60){let _0x14b4ff=_0x40aca4['model']['document']['getRoot'](_0x3d6b57);_0x14b4ff&&_0x14b4ff['isAttached']()||(_0x14b4ff=_0x585cfa['addRoot'](_0x3d6b57));const _0x3f22c9=_0x3e46b0[_0x3d6b57],_0xa8226d=Object['keys'](_0x3f22c9),_0x2426c6=_0x5286be[_0x3d6b57];for(const _0x10ec08 of _0x14b4ff['getAttributeKeys']())_0xa8226d['includes'](_0x10ec08)||_0x585cfa['removeAttribute'](_0x10ec08,_0x14b4ff);for(const _0x248a92 of _0xa8226d)_0x585cfa['setAttribute'](_0x248a92,_0x3e46b0[_0x3d6b57][_0x248a92],_0x14b4ff);_0x585cfa['remove'](_0x585cfa['createRangeIn'](_0x14b4ff)),_0x585cfa['insert'](_0x40aca4['data']['parse'](_0x2426c6,_0x14b4ff),_0x14b4ff,0x0);}});const _0xf25929=R(_0x40aca4['locale'],'Restored');if(_0x3eb0e2['name'])_0xb5bda8=-0x1==_0x3eb0e2['name']['indexOf'](_0xf25929)?_0xf25929+':\x20'+_0x3eb0e2['name']:_0x3eb0e2['name'];else _0xb5bda8=_0xf25929+':\x20'+(_0x3eb0e2['createdAt']['toLocaleDateString'](_0x40aca4['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x3eb0e2['createdAt']['toLocaleTimeString'](_0x40aca4['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x2310f9['saveRevision']({'name':_0xb5bda8}),_0x575302['isReady']=!0x0,_0x40aca4['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{a as Revision,H as RevisionHistory,u as RevisionHistoryUI,l as RevisionTracker,d as RevisionViewer,ae as RevisionViewerLoadingOverlay,m as RevisionViewerUI,j as RevisionsRepository,g as RevisionsSidebar};
|