@ckeditor/ckeditor5-revision-history 48.2.0-alpha.6 → 48.2.0-alpha.7
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/dist/index.js +7 -7
- package/dist/translations/af.js +1 -1
- package/dist/translations/af.umd.js +1 -1
- package/dist/translations/ar.js +1 -1
- package/dist/translations/ar.umd.js +1 -1
- package/dist/translations/ast.js +1 -1
- package/dist/translations/ast.umd.js +1 -1
- package/dist/translations/az.js +1 -1
- package/dist/translations/az.umd.js +1 -1
- package/dist/translations/be.js +1 -1
- package/dist/translations/be.umd.js +1 -1
- package/dist/translations/bg.js +1 -1
- package/dist/translations/bg.umd.js +1 -1
- package/dist/translations/bn.js +1 -1
- package/dist/translations/bn.umd.js +1 -1
- package/dist/translations/bs.js +1 -1
- package/dist/translations/bs.umd.js +1 -1
- package/dist/translations/ca.js +1 -1
- package/dist/translations/ca.umd.js +1 -1
- package/dist/translations/cs.js +1 -1
- package/dist/translations/cs.umd.js +1 -1
- package/dist/translations/da.js +1 -1
- package/dist/translations/da.umd.js +1 -1
- package/dist/translations/de-ch.js +1 -1
- package/dist/translations/de-ch.umd.js +1 -1
- package/dist/translations/de.js +1 -1
- package/dist/translations/de.umd.js +1 -1
- package/dist/translations/el.js +1 -1
- package/dist/translations/el.umd.js +1 -1
- package/dist/translations/en-au.js +1 -1
- package/dist/translations/en-au.umd.js +1 -1
- package/dist/translations/en-gb.js +1 -1
- package/dist/translations/en-gb.umd.js +1 -1
- package/dist/translations/en.js +1 -1
- package/dist/translations/en.umd.js +1 -1
- package/dist/translations/eo.js +1 -1
- package/dist/translations/eo.umd.js +1 -1
- package/dist/translations/es-co.js +1 -1
- package/dist/translations/es-co.umd.js +1 -1
- package/dist/translations/es.js +1 -1
- package/dist/translations/es.umd.js +1 -1
- package/dist/translations/et.js +1 -1
- package/dist/translations/et.umd.js +1 -1
- package/dist/translations/eu.js +1 -1
- package/dist/translations/eu.umd.js +1 -1
- package/dist/translations/fa.js +1 -1
- package/dist/translations/fa.umd.js +1 -1
- package/dist/translations/fi.js +1 -1
- package/dist/translations/fi.umd.js +1 -1
- package/dist/translations/fr.js +1 -1
- package/dist/translations/fr.umd.js +1 -1
- package/dist/translations/gl.js +1 -1
- package/dist/translations/gl.umd.js +1 -1
- package/dist/translations/gu.js +1 -1
- package/dist/translations/gu.umd.js +1 -1
- package/dist/translations/he.js +1 -1
- package/dist/translations/he.umd.js +1 -1
- package/dist/translations/hi.js +1 -1
- package/dist/translations/hi.umd.js +1 -1
- package/dist/translations/hr.js +1 -1
- package/dist/translations/hr.umd.js +1 -1
- package/dist/translations/hu.js +1 -1
- package/dist/translations/hu.umd.js +1 -1
- package/dist/translations/hy.js +1 -1
- package/dist/translations/hy.umd.js +1 -1
- package/dist/translations/id.js +1 -1
- package/dist/translations/id.umd.js +1 -1
- package/dist/translations/it.js +1 -1
- package/dist/translations/it.umd.js +1 -1
- package/dist/translations/ja.js +1 -1
- package/dist/translations/ja.umd.js +1 -1
- package/dist/translations/jv.js +1 -1
- package/dist/translations/jv.umd.js +1 -1
- package/dist/translations/kk.js +1 -1
- package/dist/translations/kk.umd.js +1 -1
- package/dist/translations/km.js +1 -1
- package/dist/translations/km.umd.js +1 -1
- package/dist/translations/kn.js +1 -1
- package/dist/translations/kn.umd.js +1 -1
- package/dist/translations/ko.js +1 -1
- package/dist/translations/ko.umd.js +1 -1
- package/dist/translations/ku.js +1 -1
- package/dist/translations/ku.umd.js +1 -1
- package/dist/translations/lt.js +1 -1
- package/dist/translations/lt.umd.js +1 -1
- package/dist/translations/lv.js +1 -1
- package/dist/translations/lv.umd.js +1 -1
- package/dist/translations/ms.js +1 -1
- package/dist/translations/ms.umd.js +1 -1
- package/dist/translations/nb.js +1 -1
- package/dist/translations/nb.umd.js +1 -1
- package/dist/translations/ne.js +1 -1
- package/dist/translations/ne.umd.js +1 -1
- package/dist/translations/nl.js +1 -1
- package/dist/translations/nl.umd.js +1 -1
- package/dist/translations/no.js +1 -1
- package/dist/translations/no.umd.js +1 -1
- package/dist/translations/oc.js +1 -1
- package/dist/translations/oc.umd.js +1 -1
- package/dist/translations/pl.js +1 -1
- package/dist/translations/pl.umd.js +1 -1
- package/dist/translations/pt-br.js +1 -1
- package/dist/translations/pt-br.umd.js +1 -1
- package/dist/translations/pt.js +1 -1
- package/dist/translations/pt.umd.js +1 -1
- package/dist/translations/ro.js +1 -1
- package/dist/translations/ro.umd.js +1 -1
- package/dist/translations/ru.js +1 -1
- package/dist/translations/ru.umd.js +1 -1
- package/dist/translations/si.js +1 -1
- package/dist/translations/si.umd.js +1 -1
- package/dist/translations/sk.js +1 -1
- package/dist/translations/sk.umd.js +1 -1
- package/dist/translations/sl.js +1 -1
- package/dist/translations/sl.umd.js +1 -1
- package/dist/translations/sq.js +1 -1
- package/dist/translations/sq.umd.js +1 -1
- package/dist/translations/sr-latn.js +1 -1
- package/dist/translations/sr-latn.umd.js +1 -1
- package/dist/translations/sr.js +1 -1
- package/dist/translations/sr.umd.js +1 -1
- package/dist/translations/sv.js +1 -1
- package/dist/translations/sv.umd.js +1 -1
- package/dist/translations/th.js +1 -1
- package/dist/translations/th.umd.js +1 -1
- package/dist/translations/ti.js +1 -1
- package/dist/translations/ti.umd.js +1 -1
- package/dist/translations/tk.js +1 -1
- package/dist/translations/tk.umd.js +1 -1
- package/dist/translations/tr.js +1 -1
- package/dist/translations/tr.umd.js +1 -1
- package/dist/translations/tt.js +1 -1
- package/dist/translations/tt.umd.js +1 -1
- package/dist/translations/ug.js +1 -1
- package/dist/translations/ug.umd.js +1 -1
- package/dist/translations/uk.js +1 -1
- package/dist/translations/uk.umd.js +1 -1
- package/dist/translations/ur.js +1 -1
- package/dist/translations/ur.umd.js +1 -1
- package/dist/translations/uz.js +1 -1
- package/dist/translations/uz.umd.js +1 -1
- package/dist/translations/vi.js +1 -1
- package/dist/translations/vi.umd.js +1 -1
- package/dist/translations/zh-cn.js +1 -1
- package/dist/translations/zh-cn.umd.js +1 -1
- package/dist/translations/zh.js +1 -1
- package/dist/translations/zh.umd.js +1 -1
- package/package.json +10 -10
package/dist/index.js
CHANGED
|
@@ -20,11 +20,11 @@
|
|
|
20
20
|
*
|
|
21
21
|
*
|
|
22
22
|
*/
|
|
23
|
-
import{ObservableMixin as
|
|
24
|
-
_0x5f230a(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x4aa323){super(),this['id']=_0x4aa323['id']||_0x2d6fd8(),this['creator']=_0x4aa323['creator']||null,this['authors']=_0x4aa323['authors']||[],this['diffData']=_0x4aa323['diffData']||null,this['toVersion']=_0x4aa323['toVersion']||0x0,this['fromVersion']=_0x4aa323['fromVersion']||0x0,this['set']('name',_0x4aa323['name']||''),this['set']('createdAt',_0x4aa323['createdAt']||new Date()),this['set']('attributes',_0x4aa323['attributes']||{});}['setName'](_0x4cd5e0){this['_update']({'name':_0x4cd5e0});}['setAttribute'](_0x49ed16,_0x14b546){const _0x297b3c=_0x531982(this['attributes']);_0x25f1fc(_0x297b3c,_0x49ed16,_0x14b546),this['_update']({'attributes':_0x297b3c});}['removeAttribute'](_0x3d4da6){const _0x476038=_0x531982(this['attributes']);_0x2b045d(_0x476038,_0x3d4da6),this['_update']({'attributes':_0x476038});}['_update'](_0x4655e0,_0x58568e=!0x1){let _0xce9280=!0x1;const _0xbce1bc={'id':this['id']},_0x50d158=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x53d466 of _0x50d158){const _0x4e1dfc=_0x4655e0[_0x53d466];void 0x0!==_0x4e1dfc&&_0x4e1dfc!==this[_0x53d466]&&(this[_0x53d466]=_0x4e1dfc,_0xbce1bc[_0x53d466]=_0x4e1dfc,_0xce9280=!0x0);}_0xce9280&&(_0xbce1bc['authors']&&(_0xbce1bc['authorsIds']=_0xbce1bc['authors']['map'](_0x2ec7ec=>_0x2ec7ec['id']),delete _0xbce1bc['authors']),this['fire']('_update',_0xbce1bc,_0x58568e));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x3b2bee=>_0x3b2bee['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class RevisionsRepository extends _0x4c1791{['_revisions'];static get['requires'](){return[_0x48a34e];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x4fdad5){super(_0x4fdad5),this['_revisions']=new _0x1224a0();}['afterInit'](){!async function(_0x463011){const _0x4d8d36=_0x17e474([0x76,0x73,0x6d,0x4c,0x34,0x54,0x50,0x70,0x75,0x52,0x35,0x33,0x4d,0x6c,0x71,0x53,0x6a,0x32,0x56,0x58,0x77,0x48,0x39,0x6f,0x45,0x41,0x4e,0x38,0x46,0x78,0x4a,0x74,0x47,0x55,0x4f,0x64,0x62,0x44,0x43,0x5a,0x30,0x31,0x69,0x68,0x79,0x66,0x6b,0x42,0x51,0x59,0x36,0x61,0x63,0x67,0x7a,0x37,0x72,0x49,0x65,0x57,0x4b,0x6e]),_0x125fb0=0xeb829,_0x36718a=0x359e09b0,_0x3e38ac=0x35998208^_0x36718a,_0x936f3=window[_0x17e474([0x44,0x61,0x74,0x65])][_0x17e474([0x6e,0x6f,0x77])](),_0x1ab0a7=_0x463011[_0x17e474([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x800d1a=new window[(_0x17e474([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x23c86a=>{_0x1ab0a7[_0x17e474([0x6f,0x6e,0x63,0x65])](_0x17e474([0x72,0x65,0x61,0x64,0x79]),_0x23c86a);}),_0x3547a6={[_0x17e474([0x6b,0x74,0x79])]:_0x17e474([0x45,0x43]),[_0x17e474([0x75,0x73,0x65])]:_0x17e474([0x73,0x69,0x67]),[_0x17e474([0x63,0x72,0x76])]:_0x17e474([0x50,0x2d,0x32,0x35,0x36]),[_0x17e474([0x78])]:_0x17e474([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]),[_0x17e474([0x79])]:_0x17e474([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]),[_0x17e474([0x61,0x6c,0x67])]:_0x17e474([0x45,0x53,0x32,0x35,0x36])},_0x23c136=_0x1ab0a7[_0x17e474([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x17e474([0x67,0x65,0x74])](_0x17e474([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x18f393(){let _0x5899bd,_0x312b33=null,_0xa89ca3=null;try{if(_0x23c136==_0x17e474([0x47,0x50,0x4c]))return _0x17e474([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x5899bd=_0x2af01(),!_0x5899bd)return _0x17e474([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x5899bd[_0x17e474([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0xa89ca3=_0x3f5daa(_0x5899bd[_0x17e474([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x5899bd[_0x17e474([0x6a,0x74,0x69])])),await _0x133759()?_0x29da75()?_0x16859a()?_0x17e474([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x3c1e9f()?(_0x5899bd[_0x17e474([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x17e474([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x312b33=_0x1b4a26(_0x17e474([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),await _0x1e4322()):_0x17e474([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x17e474([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x17e474([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x17e474([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x16859a(){const _0x44758c=[_0x17e474([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x17e474([0x74,0x72,0x69,0x61,0x6c])][_0x17e474([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x5899bd[_0x17e474([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x936f3/0x3e8:0xe10*_0x3e38ac;return _0x5899bd[_0x17e474([0x65,0x78,0x70])]<_0x44758c;}function _0x29da75(){const _0x5b9317=_0x5899bd[_0x17e474([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x5b9317)return!0x1;if(_0x5b9317[_0x17e474([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x17e474([0x2a])))return!0x0;if(_0x5b9317[_0x17e474([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x17e474([0x52,0x48])))return!0x0;if(_0x5b9317[_0x17e474([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x17e474([0x52,0x52,0x48]))){if(_0x2f456a())return!0x0;if(_0x370d0c()||_0x9fd755())return!0x0;}return!0x1;}function _0x3c1e9f(){const _0x324ba8=_0x5899bd[_0x17e474([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x324ba8||0x0==_0x324ba8[_0x17e474([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x5d9802}=new URL(window[_0x17e474([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x324ba8[_0x17e474([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x5d9802))return!0x0;const _0x25185e=_0x5d9802[_0x17e474([0x73,0x70,0x6c,0x69,0x74])](_0x17e474([0x2e]));return _0x324ba8[_0x17e474([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x503f59=>_0x503f59[_0x17e474([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x17e474([0x2a])))[_0x17e474([0x6d,0x61,0x70])](_0x2b0f10=>_0x2b0f10[_0x17e474([0x73,0x70,0x6c,0x69,0x74])](_0x17e474([0x2e])))[_0x17e474([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x2e0921=>_0x2e0921[_0x17e474([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x25185e[_0x17e474([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x17e474([0x6d,0x61,0x70])](_0x1be6b5=>Array(_0x25185e[_0x17e474([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0x1be6b5[_0x17e474([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x17e474([0x66,0x69,0x6c,0x6c])](_0x1be6b5[0x0]===_0x17e474([0x2a])?_0x17e474([0x2a]):'')[_0x17e474([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0x1be6b5))[_0x17e474([0x73,0x6f,0x6d,0x65])](_0x1d803f=>_0x25185e[_0x17e474([0x65,0x76,0x65,0x72,0x79])]((_0x30e1d3,_0x1bac18)=>_0x1d803f[_0x1bac18]===_0x30e1d3||_0x1d803f[_0x1bac18]===_0x17e474([0x2a])));}function _0x1e4322(){return _0x312b33&&_0xa89ca3?new window[(_0x17e474([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x49881e,_0x8a4150)=>{_0x312b33[_0x17e474([0x74,0x68,0x65,0x6e])](_0x49881e,_0x8a4150),_0xa89ca3[_0x17e474([0x74,0x68,0x65,0x6e])](_0x54c236=>{_0x54c236!=_0x17e474([0x56,0x61,0x6c,0x69,0x64])&&_0x49881e(_0x54c236);},_0x8a4150);}):_0x312b33||_0xa89ca3||_0x17e474([0x56,0x61,0x6c,0x69,0x64]);}}function _0x3f5daa(_0x1d7309,_0x1ead11){return new window[(_0x17e474([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x4ed887=>{if(_0x91f4f1())return _0x4ed887(_0x17e474([0x56,0x61,0x6c,0x69,0x64]));_0xc1418d(),_0x1ab0a7[_0x17e474([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x17e474([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x9f1c31=!0x1;const _0x2efab9=_0x2d6fd8();function _0x275f79(_0x3bd8ab){return!!_0x3bd8ab&&(typeof _0x3bd8ab===_0x17e474([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x3bd8ab===_0x17e474([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x3bd8ab[_0x17e474([0x74,0x68,0x65,0x6e])]===_0x17e474([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x3bd8ab[_0x17e474([0x63,0x61,0x74,0x63,0x68])]===_0x17e474([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x3a6ea6(_0x11c162){_0x387f0a(_0x11c162)[_0x17e474([0x74,0x68,0x65,0x6e])](_0x3f3565=>{if(!_0x3f3565||_0x3f3565[_0x17e474([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x17e474([0x6f,0x6b]))return _0x17e474([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x52f33f(_0x516eea(_0x2efab9+_0x1ead11))!=_0x3f3565[_0x17e474([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x17e474([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x17e474([0x56,0x61,0x6c,0x69,0x64]);})[_0x17e474([0x74,0x68,0x65,0x6e])](_0x4bb4fd=>(_0x3ffa2a(),_0x4bb4fd),()=>{const _0x1e6fe2=_0x2e163d();return null==_0x1e6fe2?(_0x3ffa2a(),_0x17e474([0x56,0x61,0x6c,0x69,0x64])):_0x17e474(_0x936f3-_0x1e6fe2>(0x11928db0^_0x36718a)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x17e474([0x74,0x68,0x65,0x6e])](_0x4ed887)[_0x17e474([0x63,0x61,0x74,0x63,0x68])](()=>{_0x4ed887(_0x17e474([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x38a358=0x35a8e730^_0x36718a;function _0x3ffa2a(){const _0x251110=_0x17e474([0x6c,0x6c,0x63,0x74,0x2d])+_0x52f33f(_0x516eea(_0x1d7309)),_0x18c247=_0x156085(_0x52f33f(window[_0x17e474([0x4d,0x61,0x74,0x68])][_0x17e474([0x63,0x65,0x69,0x6c])](_0x936f3/_0x38a358)));window[_0x17e474([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x17e474([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x251110,_0x18c247);}function _0x2e163d(){const _0x4a0156=_0x17e474([0x6c,0x6c,0x63,0x74,0x2d])+_0x52f33f(_0x516eea(_0x1d7309)),_0x9c8764=window[_0x17e474([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x17e474([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x4a0156);return _0x9c8764?window[_0x17e474([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x156085(_0x9c8764),0x10)*_0x38a358:null;}function _0x387f0a(_0x128ff4){return new window[(_0x17e474([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x221823,_0x180ab3)=>{_0x128ff4[_0x17e474([0x74,0x68,0x65,0x6e])](_0x221823,_0x180ab3),window[_0x17e474([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x180ab3,0x359fdd70^_0x36718a);});}}_0x1ab0a7[_0x17e474([0x6f,0x6e])](_0x17e474([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x54ccef,_0x355965)=>{if(_0x355965[0x0]!=_0x1d7309)return _0x4ed887(_0x17e474([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x355965[0x1]={..._0x355965[0x1],[_0x17e474([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x2efab9};},{[_0x17e474([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x17e474([0x68,0x69,0x67,0x68])}),_0x1ab0a7[_0x17e474([0x6f,0x6e])](_0x17e474([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x1013f7=>{_0x275f79(_0x1013f7[_0x17e474([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x9f1c31=!0x0,_0x3a6ea6(_0x1013f7[_0x17e474([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x17e474([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x17e474([0x6c,0x6f,0x77])}),_0x800d1a[_0x17e474([0x74,0x68,0x65,0x6e])](()=>{_0x9f1c31||_0x4ed887(_0x17e474([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x91f4f1(){return _0x1ab0a7[_0x17e474([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x17e474([0x76,0x69,0x65,0x77])][_0x17e474([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x17e474([0x61,0x75,0x74,0x6f]);}function _0xc1418d(){_0x1ab0a7[_0x17e474([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x17e474([0x76,0x69,0x65,0x77])][_0x17e474([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x17e474([0x61,0x75,0x74,0x6f]);}}function _0x1b4a26(_0x541f9b){const _0x46b5f5=[new window[(_0x17e474([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x47b8aa=>setTimeout(_0x47b8aa,0x3597377c^_0x36718a)),_0x800d1a[_0x17e474([0x74,0x68,0x65,0x6e])](()=>new window[(_0x17e474([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x14472e=>{const _0x562358=0x359e09b7^_0x36718a,_0x3b2717=_0x463011[_0x17e474([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x594fb4(){_0x3b2717[_0x17e474([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x562358&&_0x14472e();}_0x594fb4(),_0x3b2717[_0x17e474([0x6f,0x6e])](_0x17e474([0x61,0x64,0x64]),_0x594fb4);})),new window[(_0x17e474([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x36b567=>{function _0x582376(){for(const _0x4eab03 in window)if(window[_0x17e474([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x17e474([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x4eab03))&&window[_0x4eab03]==_0x125fb0)return _0x36b567();_0x1ab0a7[_0x17e474([0x73,0x74,0x61,0x74,0x65])]!=_0x17e474([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x17e474([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x582376,0x359e1a38^_0x36718a);}_0x287a96(_0x17e474([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x582376();})];return window[_0x17e474([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x17e474([0x72,0x61,0x63,0x65])](_0x46b5f5)[_0x17e474([0x74,0x68,0x65,0x6e])](()=>_0x541f9b);}async function _0x5d8167(){if(await _0x800d1a,_0x287a96(_0x17e474([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x36dee2=_0x463011[_0x17e474([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x399613=_0x463011[_0x17e474([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])](_0x36dee2[_0x17e474([0x69,0x64])]),_0x271071=_0x5f167c(_0x17e474([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x271071[_0x17e474([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x36dee2['id'],_0x399613?_0x399613['id']:null,!0x0),_0x271071[_0x17e474([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x17e474([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x271071[_0x17e474([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x271071[_0x17e474([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x4983bf,void(_0x271071[_0x17e474([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x4983bf);}if(_0x287a96(_0x17e474([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x36df06=_0x5f167c(_0x17e474([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x36df06[_0x17e474([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x17e474([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x36df06[_0x17e474([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x36df06[_0x17e474([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x4983bf,_0x36df06[_0x17e474([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x4983bf;}_0x1ab0a7[_0x17e474([0x6d,0x6f,0x64,0x65,0x6c])][_0x17e474([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x4983bf,_0x1ab0a7[_0x17e474([0x6d,0x6f,0x64,0x65,0x6c])][_0x17e474([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x4983bf,_0x1ab0a7[_0x17e474([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x17e474([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x2f456a(){return _0x287a96(_0x17e474([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x5f167c(_0x17e474([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x17e474([0x73,0x74,0x61,0x74,0x65])]==_0x17e474([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x370d0c(){return _0x287a96(_0x17e474([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 _0x9fd755(){return _0x287a96(_0x17e474([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x43d0a5(_0x29a60b){const _0x15f55b=_0x53eb3b();_0x1ab0a7[_0x15f55b]=_0x17e474([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])+_0x29a60b,_0x29a60b[_0x17e474([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x17e474([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x53eb3b()]=_0x125fb0),_0x29a60b!=_0x17e474([0x56,0x61,0x6c,0x69,0x64])&&_0x5d8167();}function _0x53eb3b(){const _0x346b24=window[_0x17e474([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x17e474([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x17e474([0x6e,0x6f,0x77])]())[_0x17e474([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x17e474([0x2e]),'');let _0x51a028=_0x17e474([0x76]);for(let _0xa99a68=0x0;_0xa99a68<_0x346b24[_0x17e474([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0xa99a68+=0x2){let _0xb91487=window[_0x17e474([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x346b24[_0x17e474([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0xa99a68,_0xa99a68+0x2));_0xb91487>=_0x4d8d36[_0x17e474([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0xb91487-=_0x4d8d36[_0x17e474([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x51a028+=_0x4d8d36[_0xb91487];}return _0x51a028;}function _0x2af01(){const _0x2c6069=_0x23c136[_0x17e474([0x73,0x70,0x6c,0x69,0x74])](_0x17e474([0x2e]));if(0x3!=_0x2c6069[_0x17e474([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x66cebb(_0x2c6069[0x1]);function _0x66cebb(_0x2f4452){const _0x144a8e=_0x20cc43(_0x2f4452);return _0x144a8e&&_0x4299ea()?_0x144a8e:null;function _0x4299ea(){const _0xc8a8a9=_0x144a8e[_0x17e474([0x6a,0x74,0x69])],_0x3ad73f=window[_0x17e474([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0xc8a8a9[_0x17e474([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0xc8a8a9[_0x17e474([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x519f1f={..._0x144a8e,[_0x17e474([0x6a,0x74,0x69])]:_0xc8a8a9[_0x17e474([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0xc8a8a9[_0x17e474([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x519f1f[_0x17e474([0x76,0x63])],_0x516eea(_0x519f1f)==_0x3ad73f;}}}async function _0x133759(){let _0x433baf=!0x0;try{const _0x277748=_0x23c136[_0x17e474([0x73,0x70,0x6c,0x69,0x74])](_0x17e474([0x2e])),[_0x47b0c4,_0x40a6a5,_0x4a0c1b]=_0x277748;return _0x3613d6(_0x47b0c4),await _0x3c6782(_0x47b0c4,_0x40a6a5,_0x4a0c1b),_0x433baf;}catch{return!0x1;}function _0x3613d6(_0x5cdc1f){const _0x400f6f=_0x20cc43(_0x5cdc1f);_0x400f6f&&_0x400f6f[_0x17e474([0x61,0x6c,0x67])]==_0x17e474([0x45,0x53,0x32,0x35,0x36])||(_0x433baf=!0x1);}async function _0x3c6782(_0x2bc847,_0xef9056,_0x3c0ad3){const _0x42d89e=window[_0x17e474([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x17e474([0x66,0x72,0x6f,0x6d])](_0x2fc4a7(_0x3c0ad3),_0x1e55df=>_0x1e55df[_0x17e474([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x2811a7=new window[(_0x17e474([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x17e474([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x2bc847+_0x17e474([0x2e])+_0xef9056),_0x189878=window[_0x17e474([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x17e474([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x189878)return;const _0x33c973=await _0x189878[_0x17e474([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x17e474([0x6a,0x77,0x6b]),_0x3547a6,{[_0x17e474([0x6e,0x61,0x6d,0x65])]:_0x17e474([0x45,0x43,0x44,0x53,0x41]),[_0x17e474([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x17e474([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x17e474([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x189878[_0x17e474([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x17e474([0x6e,0x61,0x6d,0x65])]:_0x17e474([0x45,0x43,0x44,0x53,0x41]),[_0x17e474([0x68,0x61,0x73,0x68])]:{[_0x17e474([0x6e,0x61,0x6d,0x65])]:_0x17e474([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x33c973,_0x42d89e,_0x2811a7)||(_0x433baf=!0x1);}}function _0x20cc43(_0x26085e){return _0x26085e[_0x17e474([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x17e474([0x65,0x79]))?JSON[_0x17e474([0x70,0x61,0x72,0x73,0x65])](_0x2fc4a7(_0x26085e)):null;}function _0x2fc4a7(_0x38b9ae){return window[_0x17e474([0x61,0x74,0x6f,0x62])](_0x38b9ae[_0x17e474([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x17e474([0x2b]))[_0x17e474([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x17e474([0x2f])));}function _0x516eea(_0x3e7315){let _0x329eeb=0x1505;function _0x1c4c5e(_0x2037fa){for(let _0x13ab88=0x0;_0x13ab88<_0x2037fa[_0x17e474([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x13ab88++){const _0x491617=_0x2037fa[_0x17e474([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x13ab88);_0x329eeb=(_0x329eeb<<0x5)+_0x329eeb+_0x491617,_0x329eeb&=_0x329eeb;}}function _0x57db41(_0x44de19){Array[_0x17e474([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x44de19)?_0x44de19[_0x17e474([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x57db41):_0x44de19&&typeof _0x44de19==_0x17e474([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x17e474([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x44de19)[_0x17e474([0x73,0x6f,0x72,0x74])]()[_0x17e474([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x3c8a4f,_0xc6b367])=>{_0x1c4c5e(_0x3c8a4f),_0x57db41(_0xc6b367);}):_0x1c4c5e(window[_0x17e474([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x44de19));}return _0x57db41(_0x3e7315),_0x329eeb>>>0x0;}function _0x52f33f(_0x37cc26){return _0x37cc26[_0x17e474([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x17e474([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x17e474([0x30]));}function _0x156085(_0x584327){return _0x584327[_0x17e474([0x73,0x70,0x6c,0x69,0x74])]('')[_0x17e474([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x17e474([0x6a,0x6f,0x69,0x6e])]('');}function _0x287a96(_0x454bcd){return _0x1ab0a7[_0x17e474([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x17e474([0x68,0x61,0x73])](_0x454bcd);}function _0x5f167c(_0x510f49){return _0x1ab0a7[_0x17e474([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x17e474([0x67,0x65,0x74])](_0x510f49);}function _0x4983bf(){}function _0x17e474(_0x12a4e7){return _0x12a4e7['map'](_0x9ca815=>String['fromCharCode'](_0x9ca815))['join']('');}_0x43d0a5(await _0x18f393());}(this);}['createRevision'](_0x24bf8d){const _0x4bc6a2=this['editor']['plugins']['get']('Users');return new Revision({'id':_0x24bf8d['id'],'name':_0x24bf8d['name'],'creator':_0x24bf8d['creatorId']?_0x4bc6a2['getUser'](_0x24bf8d['creatorId']):null,'diffData':_0x24bf8d['diffData']||_0x24bf8d['data'],'authors':_0x24bf8d['authorsIds']['map'](_0x28d523=>_0x4bc6a2['getUser'](_0x28d523)),'createdAt':new Date(_0x24bf8d['createdAt']),'attributes':_0x24bf8d['attributes'],'fromVersion':_0x24bf8d['fromVersion'],'toVersion':_0x24bf8d['toVersion']});}['addRevision'](_0x518a20,_0x8ea72f=0x0){this['_revisions']['add'](_0x518a20,_0x8ea72f);}['getRevision'](_0x3bcae5){return this['_revisions']['get'](_0x3bcae5);}['getRevisions'](_0x57ac3b={'toJSON':!0x1}){const _0x259a57=Array['from'](this['_revisions']);return _0x259a57['reverse'](),_0x57ac3b['toJSON']?_0x259a57['map'](_0x527cfb=>_0x527cfb['toJSON']()):_0x259a57;}['getIndex'](_0x95d44b){return this['_revisions']['getIndex'](_0x95d44b);}['getEarlierVisibleRevision'](_0x5b1cc6){const [,_0x213f95]=this['getRevisionsIterator'](_0x5b1cc6,{'direction':'earlier'});return _0x213f95;}['getLaterVisibleRevision'](_0x3264b3){const [,_0x2791de]=this['getRevisionsIterator'](_0x3264b3,{'direction':'later'});return _0x2791de;}['getRevisionsInDiff'](_0x2b4fa0){const _0x43cbe7=[];for(const _0x5abc7c of this['getRevisionsIterator'](_0x2b4fa0['newRevisionId']))if(_0x43cbe7['push'](_0x5abc7c),_0x5abc7c['id']===_0x2b4fa0['oldRevisionId'])break;return _0x43cbe7;}*['getRevisionsIterator'](_0x22cf98,{direction:_0x57bf13='earlier',filter:_0x35280f=()=>!0x0}={}){const _0x525c19='earlier'===_0x57bf13?0x1:-0x1;let _0xa2ecd5=this['_revisions']['get'](_0x22cf98),_0x10d0ca=this['getIndex'](_0xa2ecd5);for(yield _0xa2ecd5;_0xa2ecd5;){if(_0x10d0ca+=_0x525c19,_0xa2ecd5=this['getRevision'](_0x10d0ca),!_0xa2ecd5)return;_0x35280f(_0xa2ecd5)&&(yield _0xa2ecd5);}}}class RevisionHistoryUtils extends _0x4c1791{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x2dbd6b,'c'],[_0x44e60f,'a'],[_0x4422b1,'e'],[_0x429ee7,'r'],[_0x5af715,'u']]);['_typeCharToViewClass']=new Map([['c',_0x2dbd6b],['a',_0x44e60f],['e',_0x4422b1],['r',_0x429ee7],['u',_0x5af715]]);async['loadRevisionData'](_0x2f79b5,_0xc05254){if(_0x2f79b5['diffData']||!_0xc05254)return;const _0x3eb933=this['editor']['config']['get']('collaboration.channelId'),_0x453386=await _0xc05254['getRevision']({'channelId':_0x3eb933,'revisionId':_0x2f79b5['id']});_0x2f79b5['diffData']=_0x453386['diffData'];}['getRevisionDocumentData'](_0x285d04){const _0x5ea559={};for(const _0xfbe7 in _0x285d04['diffData']){if(_0x285d04['diffData'][_0xfbe7]['attachChange']&&!_0x285d04['diffData'][_0xfbe7]['attachChange']['isAttached'])continue;const _0x53c64a=this['_removeRevisionMarkers'](JSON['parse'](_0x285d04['diffData'][_0xfbe7]['insertions'])),_0x22e91c=this['editor']['editing']['view']['document'],_0x518041=new _0x2ad0df(_0x22e91c,_0x53c64a['map'](_0x5ad449=>this['_getViewFromDiffObj'](_0x5ad449,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x5ea559[_0xfbe7]=this['editor']['data']['processor']['toData'](_0x518041),this['editor']['data']['processor']['useFillerType']('default');}return _0x5ea559;}['getRevisionRootsAttributes'](_0x417f41){const _0xd5aca7={};for(const _0x4951a4 in _0x417f41['diffData'])_0x417f41['diffData'][_0x4951a4]['attachChange']&&!_0x417f41['diffData'][_0x4951a4]['attachChange']['isAttached']||(_0xd5aca7[_0x4951a4]=_0x417f41['diffData'][_0x4951a4]['attributesAfter']||{});return _0xd5aca7;}['getRevisionRootsModelElements'](_0x939b6){const _0x443466={};for(const _0x2e2f5f in _0x939b6['diffData']){if(_0x939b6['diffData'][_0x2e2f5f]['attachChange']&&!_0x939b6['diffData'][_0x2e2f5f]['attachChange']['isAttached'])continue;const _0x17e138=_0x939b6['diffData'][_0x2e2f5f]['rootElementName'];_0x17e138&&(_0x443466[_0x2e2f5f]=_0x17e138);}return _0x443466;}['_getTypeCharForViewElement'](_0x180b73){return this['_viewClassToTypeChar']['get'](_0x180b73['constructor']);}['_getViewFromDiffObj'](_0x411b78,_0x6b5484){const _0x30ddbb=this['editor']['editing']['view']['document'];if('string'==typeof _0x411b78)return new _0x5330b1(_0x30ddbb,_0x411b78);{let _0x442292,_0x5df528;_0x5df528='u'==_0x411b78['type']||'r'==_0x411b78['type']?[]:_0x411b78['children']['map'](_0x4e6e70=>this['_getViewFromDiffObj'](_0x4e6e70,_0x6b5484));const _0x198bd0=this['_typeCharToViewClass']['get'](_0x411b78['type'])||_0x9d29a5,_0x62c6d1=this['editor']['data']['htmlProcessor']['domConverter'];if(_0x442292=new _0x198bd0(_0x30ddbb,_0x411b78['name'],_0x411b78['attributes'],_0x5df528),'u'==_0x411b78['type']&&_0x411b78['children'][0x0]){const _0xc31763=_0x411b78['children'][0x0];if(_0x442292['render']=function(_0x2f8229){const _0x10e791=_0x2f8229['createElement']('div');return _0x10e791['innerHTML']=_0xc31763,_0x10e791['childNodes'][0x0];},_0x6b5484){const _0x1292ff=new _0x2ad0df(_0x30ddbb);_0x1292ff['_appendChild'](_0x442292);const _0x572f7f=Array['from'](_0x62c6d1['viewChildrenToDom'](_0x1292ff,{'bind':!0x1})),_0x3ace78=_0x62c6d1['domDocument']['createElement']('div');_0x3ace78['append'](..._0x572f7f),_0x442292=Array['from'](_0x62c6d1['domChildrenToView'](_0x3ace78))[0x0];}}else{if('r'==_0x411b78['type']&&_0x411b78['children'][0x0]){const _0x2feb1c=_0x411b78['children'][0x0];if(_0x442292['render']=function(_0x305f56){_0x305f56['innerHTML']=_0x2feb1c;},_0x6b5484){const _0x3b502a=new _0x2ad0df(_0x30ddbb);_0x3b502a['_appendChild'](_0x442292);const _0x1f5a4c=Array['from'](_0x62c6d1['viewChildrenToDom'](_0x3b502a,{'bind':!0x1})),_0x29efa0=_0x62c6d1['domDocument']['createElement']('div');_0x29efa0['append'](..._0x1f5a4c);const _0x457c1c=Array['from'](_0x62c6d1['domChildrenToView'](_0x29efa0));_0x457c1c['length']>0x1?_0x442292['_appendChild'](_0x457c1c):_0x442292=_0x457c1c[0x0];}}}if(_0x411b78['customProperties']){for(const [_0x39d042,_0xb4f424]of _0x411b78['customProperties'])_0x442292['_setCustomProperty'](_0x39d042,_0xb4f424);}const _0x48cf30=void 0x0===_0x411b78['fillerOffset']?null:_0x411b78['fillerOffset'];return null!==_0x48cf30&&(_0x442292['getFillerOffset']=()=>_0x48cf30),_0x442292;}}['_makeModelFromViewString'](_0x10412c,_0x47980){const _0x242659=JSON['parse'](_0x10412c),_0x2dad49=this['editor']['editing']['view']['document'],_0x448075=new _0x2ad0df(_0x2dad49,_0x242659['map'](_0x199eca=>this['_getViewFromDiffObj'](_0x199eca,!0x0))),_0x2389e7=this['editor']['data']['toModel'](_0x448075,_0x47980);return _0x2389e7['name']=_0x47980,_0x2389e7;}['_removeRevisionMarkers'](_0x50f278){return(_0x50f278=_0x50f278['filter'](_0x366439=>!_0x366439['name']||'revision-start'!==_0x366439['name']&&'revision-end'!==_0x366439['name']))['forEach'](_0x4e7e06=>{'string'!=typeof _0x4e7e06&&(_0x4e7e06['children']=this['_removeRevisionMarkers'](_0x4e7e06['children']),_0x4e7e06['attributes']=_0x4e7e06['attributes']['filter'](_0x276060=>!_0x276060[0x0]['startsWith']('data-revision-')));}),_0x50f278;}}function ft(_0x1a62a0,_0x446e0d,_0xede47b){const t=_0x1a62a0['t'];switch(_0x446e0d){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'},_0xede47b);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0xede47b);case'Show\x20previous\x20change':return t('Show\x20previous\x20change');case'Show\x20next\x20change':return t('Show\x20next\x20change');case'EDIT_X_OF_Y_REVISIONS':return t({'string':'Edit','id':'EDIT_X_OF_Y_REVISIONS'});case'Total':return t('Total');case'Revision\x20creator':return t('Revision\x20creator');case'Revision\x20author':return t('Revision\x20author');case'Revision\x20name':return t('Revision\x20name');case'Save\x20current\x20revision':return t('Save\x20current\x20revision');case'Accept':return t('Accept');case'Save':return t('Save');case'Cancel':return t('Cancel');case'Name\x20of\x20the\x20revision':return t('Name\x20of\x20the\x20revision');case'optional':return t('optional');case'PENDING_ACTION_REVISION_HISTORY':return t({'string':'Unsaved\x20change\x20in\x20revision\x20history.','id':'PENDING_ACTION_REVISION_HISTORY'});case'The\x20revision\x20name\x20cannot\x20be\x20empty.':return t('The\x20revision\x20name\x20cannot\x20be\x20empty.');case'Enter\x20the\x20revision\x20name':return t('Enter\x20the\x20revision\x20name');default:return'';}}class RevisionTracker extends _0x4c1791{['licenseKey'];['_licenseKeyCheckInterval'];['currentRevision']=null;['repository'];['adapter']=null;['_revisionDataBuilder'];['_source'];['_initialRevisionId'];['_bufferedUpdates'];['_utils'];['_pendingAction'];['_continueCurrentRevision'];['_startingVersion'];['_loadedStateData'];static get['pluginName'](){return'RevisionTracker';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[_0x48a34e,RevisionsRepository,RevisionHistoryUtils,_0x4daa0a];}constructor(_0x5e1f53){super(_0x5e1f53),this['repository']=this['editor']['plugins']['get']('RevisionsRepository'),this['_utils']=this['editor']['plugins']['get']('RevisionHistoryUtils'),this['_revisionDataBuilder']=new RevisionDataBuilder(this['editor']),this['_initialRevisionId']=this['editor']['config']['get']('collaboration.channelId')||'initial',this['_bufferedUpdates']=new Map(),this['_loadedStateData']=null;const _0x52a6e3=_0x2d6fd8();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x52a6e3},this['set']('isReady',!0x1),this['set']('isEnabled',!0x0),this['set']('_isPendingUpdate',!0x1),this['editor']['config']['define']('revisionHistory.resumeUnsavedRevision',!0x0),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'});}['init'](){this['_setConversion'](),this['editor']['data']['on']('ready',()=>{const _0x3a9ccc=this['repository']['getRevision'](0x0),_0x495f7e=_0x3a9ccc&&null===_0x3a9ccc['creator']?_0x3a9ccc:null;if(this['_continueCurrentRevision']=!!_0x495f7e&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x37b0c5=this['_source']['getCurrentRevisionId'](),_0x33098b=this['repository']['getRevision'](_0x37b0c5);if(_0x33098b)this['_startingVersion']=_0x33098b['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x1c430e=this['_source']['history']['_operations']['find'](_0x467602=>!_0x467602['_isInit']),_0x3db7d8=_0x1c430e?_0x1c430e['baseVersion']:this['_source']['history']['version'];_0x3a9ccc?(_0x3a9ccc['toVersion']<_0x3db7d8&&_0x3a9ccc['_update']({'toVersion':_0x3db7d8}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x495f7e['id'],this['_startingVersion']=_0x495f7e['fromVersion']):(this['_startingVersion']=_0x3a9ccc['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x3db7d8,this['_continueCurrentRevision']=!0x1);}}else _0x495f7e&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x495f7e['toVersion'],this['editor']['model']['document']['history']['version']),_0x495f7e['fromVersion']===_0x495f7e['toVersion']?(0x0!==_0x495f7e['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x495f7e['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x495f7e['id'],this['_startingVersion']=_0x495f7e['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',_0x1cb934=>!_0x1cb934),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x56977b=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x5e5b5d;for(const _0xa84caa in _0x56977b){const _0x3e1fce=_0xa84caa,_0x5be92f=_0x56977b[_0x3e1fce];if('revisionHistoryLicenseKeyValid'==_0x5be92f||'revisionHistoryLicenseKeyInvalid'==_0x5be92f||'revisionHistoryLicenseKeyExpired'==_0x5be92f||'revisionHistoryLicenseKeyDomainLimit'==_0x5be92f||'revisionHistoryLicenseKeyNotAllowed'==_0x5be92f||'revisionHistoryLicenseKeyEvaluationLimit'==_0x5be92f||'revisionHistoryLicenseKeyUsageLimit'==_0x5be92f){delete _0x56977b[_0x3e1fce],_0x5e5b5d=_0x5be92f,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x5e5b5d&&_0x56977b['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x5e5b5d&&_0x56977b['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x5e5b5d&&_0x56977b['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x5e5b5d&&_0x56977b['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x5e5b5d&&_0x56977b['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x5e5b5d&&_0x56977b['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x4a861b=this['repository']['getRevision'](0x0),_0x52e0c7=await this['getRevisionDocumentData'](_0x4a861b),_0x1e7c8f=await this['getRevisionRootsAttributes'](_0x4a861b),_0x301146=this['_utils']['getRevisionRootsModelElements'](_0x4a861b);this['_replaceEditorDataWithRevisionData'](_0x52e0c7,_0x1e7c8f,_0x301146);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x239c15){this['_source']=_0x239c15;}async['update'](){const _0x383926=await this['_source']['getLatestVersion']();if(_0x383926>this['currentRevision']['toVersion']){await this['_loadState']();const _0x3a92c3=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x383926});_0x3a92c3['authors']=_0x3a92c3['authorsIds']['map'](_0x5e9485=>this['editor']['plugins']['get']('Users')['getUser'](_0x5e9485)),this['currentRevision']['_update'](_0x3a92c3);}}async['saveRevision'](_0x3da11d={},_0x59fe4d=null){const _0x5572a4=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x59fe4d>this['currentRevision']['toVersion']&&(_0x59fe4d=null),null===_0x59fe4d&&(_0x59fe4d=await this['_source']['getLatestVersion']());const _0x9b4179=this['_getFromVersion'](_0x59fe4d),_0x22b02d=this['buildRevisionData']({'from':_0x9b4179,'to':_0x59fe4d});if(this['currentRevision']['toVersion']<_0x59fe4d){const _0x2f419e=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x59fe4d,'to':_0x59fe4d});_0x2f419e['authors']=[],_0x2f419e['authorsIds']=[],_0x2f419e['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x2f419e,!0x0),delete _0x2f419e['authors'],_0x5572a4['push'](_0x2f419e);}_0x3da11d['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x3da11d['name']=_0x3da11d['name']||null,_0x3da11d['id']=_0x3da11d['id']||_0x2d6fd8(),_0x3da11d={..._0x3da11d,..._0x22b02d};const _0x306188=this['addRevisionData'](_0x3da11d);_0x5572a4['push'](_0x3da11d);const _0x20524c=this['repository']['getIndex'](_0x306188);if(0x0!==_0x20524c){const _0x336c07=this['repository']['getRevision'](_0x20524c-0x1);if(_0x336c07['fromVersion']!==_0x59fe4d){const _0x403d34=this['_revisionDataBuilder']['getData'](_0x59fe4d,_0x336c07['toVersion']),_0x431c7a={'id':_0x336c07['id'],'diffData':_0x403d34['diffData'],'authorsIds':_0x403d34['authorsIds'],'authors':_0x403d34['authorsIds']['map'](_0x1cf5ce=>this['editor']['plugins']['get']('Users')['getUser'](_0x1cf5ce)),'fromVersion':_0x59fe4d};_0x336c07===this['currentRevision']&&(_0x431c7a['createdAt']=new Date(_0x3da11d['createdAt']['getTime']()+0xa)),_0x336c07['_update'](_0x431c7a,!0x0),delete _0x431c7a['authors'],_0x5572a4['push'](_0x431c7a);}}if(this['adapter']){for(const _0x268f48 of _0x5572a4)this['_bufferUpdate'](_0x268f48['id'],_0x268f48,!0x0);this['sendBufferedUpdates']();}return _0x306188;}['addRevisionData'](_0x19d87c){const _0xfbf94f=this['repository']['createRevision'](_0x19d87c);return this['adapter']&&_0xfbf94f['on']('_update',(_0x22a871,_0x390aa2,_0x46bf1b)=>{_0x46bf1b||(this['_bufferUpdate'](_0x390aa2['id'],_0x390aa2,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0xfbf94f,this['_findInsertionIndex'](_0xfbf94f)),_0xfbf94f;}async['getRevisionDocumentData'](_0x4f18f9){return await this['_utils']['loadRevisionData'](_0x4f18f9,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x4f18f9);}async['getRevisionRootsAttributes'](_0x2deeee){return await this['_utils']['loadRevisionData'](_0x2deeee,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x2deeee);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x113191=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x2139c2=0x0;_0x2139c2<_0x113191['length'];_0x2139c2++){const _0x1f07b0=_0x113191[_0x2139c2];let _0x2d93ae=!0x1;for(const _0x420ee3 of Object['keys'](_0x1f07b0))void 0x0===_0x1f07b0[_0x420ee3]?delete _0x1f07b0[_0x420ee3]:'id'!==_0x420ee3&&(_0x2d93ae=!0x0);_0x2d93ae||(_0x113191[_0x2139c2]=null);}if(_0x113191=_0x113191['filter'](_0xad6aa9=>null!==_0xad6aa9),!_0x113191['length'])return;for(let _0x53c8cb=0x0;_0x53c8cb<_0x113191['length'];_0x53c8cb++){const _0x1edf22=_0x113191[_0x53c8cb];void 0x0!==_0x1edf22['fromVersion']&&void 0x0===_0x1edf22['toVersion']&&(_0x1edf22['toVersion']=this['repository']['getRevision'](_0x1edf22['id'])['toVersion']),void 0x0!==_0x1edf22['toVersion']&&void 0x0===_0x1edf22['fromVersion']&&(_0x1edf22['fromVersion']=this['repository']['getRevision'](_0x1edf22['id'])['fromVersion']);}const _0x14c6c4=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x113191,_0x14c6c4)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x2d0b54=>{if(_0x2d0b54){for(const _0x46a191 of _0x2d0b54)this['setRevisionData']({'id':_0x46a191['id'],'createdAt':_0x46a191['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0x1ee010=null,from:_0x13b7f7=null,to:_0x861d39=null}){_0x13b7f7=null!==_0x13b7f7?_0x13b7f7:_0x1ee010['fromVersion'],_0x861d39=null!==_0x861d39?_0x861d39:_0x1ee010['toVersion'];const _0x2294d3=this['_revisionDataBuilder']['getData'](_0x13b7f7,_0x861d39),_0x1c8669={'diffData':_0x2294d3['diffData'],'authorsIds':_0x2294d3['authorsIds'],'fromVersion':_0x13b7f7,'toVersion':_0x861d39};if(!_0x1ee010||_0x861d39!==_0x1ee010['toVersion']){const _0x56fbdb=_0x861d39-0x1,_0x3db3f3=this['_source']['history']['getOperation'](_0x56fbdb);_0x1c8669['createdAt']=_0x3db3f3&&_0x3db3f3['createdAt']||new Date();}if(this['_loadedStateData']&&_0x13b7f7===this['_loadedStateData']['fromVersion']){for(const _0x469ee7 of this['_loadedStateData']['authors'])_0x1c8669['authorsIds']['includes'](_0x469ee7['id'])||_0x1c8669['authorsIds']['push'](_0x469ee7['id']);}return _0x1c8669;}['_bufferUpdate'](_0x30a2fe,_0x382c3b,_0x4c9ec7){if(this['_bufferedUpdates']['has'](_0x30a2fe)){const _0x2b258e=this['_bufferedUpdates']['get'](_0x30a2fe);_0x382c3b=_0x4c9ec7?{..._0x2b258e,..._0x382c3b}:{..._0x382c3b,..._0x2b258e};}this['_bufferedUpdates']['set'](_0x30a2fe,_0x382c3b);}['setRevisionData'](_0x2bdf1b){const _0x423736=this['repository']['getRevision'](_0x2bdf1b['id']);if(_0x2bdf1b['createdAt']&&(_0x2bdf1b['createdAt']=new Date(_0x2bdf1b['createdAt'])),_0x2bdf1b['authorsIds']){const _0x3bc4e6=this['editor']['plugins']['get']('Users');_0x2bdf1b['authors']=_0x2bdf1b['authorsIds']['map'](_0x198403=>_0x3bc4e6['getUser'](_0x198403));}_0x423736['_update'](_0x2bdf1b,!0x0);}['_createInitialRevision'](_0x5c8289){const _0x1c9a71=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x1c9a71)this['_initialRevisionId']=_0x1c9a71['id'];else{const _0x3e5661=!this['editor']['model']['document']['roots']['find'](_0x3811fe=>this['editor']['model']['hasContent'](_0x3811fe)),_0x30d761=this['editor']['plugins']['get']('Users')['me']['id'],_0x4f1191=ft(this['editor']['locale'],_0x3e5661?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x5c8289,'to':_0x5c8289,'id':this['_initialRevisionId'],'name':_0x4f1191,'creatorId':_0x30d761});}}['_createCurrentRevision'](_0x44a006){const _0x5baf35=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x5baf35),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x44a006,'to':_0x44a006,'id':_0x5baf35,'name':'','creatorId':null}));}async['_loadState'](){this['_continueCurrentRevision']&&!this['_loadedStateData']&&(await this['_utils']['loadRevisionData'](this['currentRevision'],this['adapter']),this['_revisionDataBuilder']['loadState'](this['currentRevision']),this['_loadedStateData']={'fromVersion':this['currentRevision']['fromVersion'],'authors':this['currentRevision']['authors']['slice']()});}['_replaceEditorDataWithRevisionData'](_0x598fd0,_0x41692a,_0x226e94){const _0x34f95c={},_0x5dac26={},_0xe40283={},_0x153d2d=this['editor']['config']['get']('roots')||{};for(const [_0x24aa90,_0x34a9ff]of Object['entries'](_0x153d2d))_0x34a9ff['lazyLoad']||(_0x34f95c[_0x24aa90]=_0x34a9ff['initialData']??'',_0x5dac26[_0x24aa90]=_0x34a9ff['modelAttributes']||{},_0x34a9ff['modelElement']&&(_0xe40283[_0x24aa90]=_0x34a9ff['modelElement']));for(const _0x23e084 of this['editor']['model']['document']['getRootNames']())_0x34f95c[_0x23e084]??='',_0x5dac26[_0x23e084]??={};let _0xba4806=!0x1;const _0x3f73ba=Object['keys'](_0x34f95c),_0x517cf7=Object['keys'](_0x598fd0);for(const _0x4660c3 of _0x3f73ba){if(_0x34f95c[_0x4660c3]!==_0x598fd0[_0x4660c3]&&''!==_0x34f95c[_0x4660c3]['trim']()){_0xba4806=!0x0;break;}if(!_0x2bf393(_0x5dac26[_0x4660c3],_0x41692a[_0x4660c3])&&Object['keys'](_0x5dac26[_0x4660c3])['length']>0x0){_0xba4806=!0x0;break;}const _0x1ec3be=_0xe40283[_0x4660c3],_0x824470=_0x226e94[_0x4660c3];if(_0x1ec3be&&_0x824470&&_0x1ec3be!==_0x824470){_0xba4806=!0x0;break;}}_0xba4806||(_0xba4806=_0x517cf7['some'](_0x1fe738=>!this['editor']['model']['document']['getRoot'](_0x1fe738))),_0xba4806&&_0xefa158('editor-initial-data-replaced-with-revision-data',{'editorData':_0x34f95c,'editorRootsAttributes':_0x5dac26,'editorRootsModelElements':_0xe40283,'revisionData':_0x598fd0,'revisionRootsAttributes':_0x41692a,'revisionRootsModelElements':_0x226e94});for(const [_0x7e59a1,_0x7ec2fe]of Object['entries'](_0x598fd0))this['editor']['config']['set']('roots.'+_0x7e59a1+'.initialData',_0x7ec2fe);for(const [_0x5463c0,_0x1107ac]of Object['entries'](_0x41692a))this['editor']['config']['set']('roots.'+_0x5463c0+'.modelAttributes',_0x1107ac);const _0x59b162=this['editor']['model']['document'];for(const [_0x5a5a4b,_0x5f5dfd]of Object['entries'](_0x226e94)){this['editor']['config']['set']('roots.'+_0x5a5a4b+'.modelElement',_0x5f5dfd);const _0x5d546b=_0x59b162['getRoot'](_0x5a5a4b);_0x5d546b&&_0x5d546b['name']!==_0x5f5dfd&&(_0x59b162['roots']['remove'](_0x5a5a4b),_0x59b162['createRoot'](_0x5f5dfd,_0x5a5a4b));}}['_addPendingAction'](){if(!this['_pendingAction']){const _0x56a0bd=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x56a0bd['add'](ft(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x1d3c67){const _0x1ad665=this['repository']['getRevisions']();_0x1ad665['reverse']();let _0x5a563d=0x0;for(;_0x5a563d<_0x1ad665['length'];){const _0x6d79c1=_0x1ad665[_0x5a563d];if(_0x6d79c1===this['currentRevision']){_0x5a563d++;continue;}if(_0x6d79c1['id']===this['_initialRevisionId'])break;const _0x46e726=_0x1d3c67['toVersion']-_0x6d79c1['toVersion']||_0x1d3c67['fromVersion']-_0x6d79c1['fromVersion'];if(_0x46e726>0x0)break;if(_0x46e726<0x0)_0x5a563d++;else{if(!_0x1d3c67['creator']&&_0x6d79c1['creator'])break;if(_0x6d79c1['creator']||!_0x1d3c67['creator']){if(_0x1d3c67['createdAt']>_0x6d79c1['createdAt'])break;_0x5a563d++;}else _0x5a563d++;}}return _0x5a563d;}['_getFromVersion'](_0x27553f){const _0x35cf2b=this['repository']['getRevisions']();_0x35cf2b['reverse'](),_0x35cf2b['shift']();const _0x1638f9=_0x35cf2b['find'](_0x47cd53=>_0x47cd53['toVersion']<=_0x27553f)['toVersion'];return _0x1638f9<this['_startingVersion']?this['_startingVersion']:_0x1638f9;}['_makeRevision']({name:_0x10ff85,from:_0x16d921,to:_0x2286ec,creatorId:_0x2a0a3f,id:_0x29af07}){const _0x56e74e=this['buildRevisionData']({'from':_0x16d921,'to':_0x2286ec});_0x56e74e['name']=_0x10ff85,_0x56e74e['creatorId']=_0x2a0a3f,_0x56e74e['id']=_0x29af07;const _0x5a950d=this['addRevisionData'](_0x56e74e);return this['adapter']&&this['_bufferUpdate'](_0x56e74e['id'],_0x56e74e,!0x0),_0x5a950d;}['_setConversion'](){this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'});}}class RevisionDataBuilder{['editor'];['source'];['_savedMetaData'];['_lastFrom'];['_lastTo'];['_markers'];['_diffRoots'];['_diffRootsAttributes'];['_baseRoots'];['_baseRootsAttributes'];['_idsRoots'];['_baseIdsRoots'];['_touched'];['_touchedMarkers'];['_touchedRoots'];['_revisionId'];['_startingRevisionId'];constructor(_0x99929e){this['editor']=_0x99929e,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'](_0x51cf5c){this['source']=_0x51cf5c;const _0xc20ab8=new Map(),_0x3f885b=new Map(),_0x3ca0b5=this['editor']['model']['document']['roots']['map'](_0x42aa4b=>_0x42aa4b['rootName']);for(const _0x16296b of _0x3ca0b5){const _0x1b6244=this['editor']['model']['document']['getRoot'](_0x16296b),_0x47923b=gt(_0x1b6244);_0xc20ab8['set'](_0x16296b,_0x47923b),_0x3f885b['set'](_0x16296b,Object['fromEntries'](_0x1b6244['getAttributes']()));}const _0x1b45d6=Array['from'](this['editor']['model']['markers'])['map'](_0x275b52=>[_0x275b52['name'],_0x275b52['getRange']()]),_0x497326=this['source']['version'];this['_saveMetaData'](_0x497326,_0xc20ab8,_0x1b45d6,_0x3f885b),this['_startingRevisionId']=this['_revisionId'];const _0xe1965a=new Map(),_0x42026d=new Map();for(const _0x5839a9 of _0x3ca0b5){const _0x4c5061=wt(_0x5839a9,this['editor']['model']['document']['getRoot'](_0x5839a9)['name']);_0xe1965a['set'](_0x5839a9,_0x4c5061),_0x42026d['set'](_0x5839a9,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0xe1965a,[],_0x42026d);}['getData'](_0x7e3ef7,_0x3d1683){if(this['_lastFrom']===_0x7e3ef7&&this['_lastTo']<=_0x3d1683)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x3d1683,!0x0);else{if(!this['_savedMetaData']['has'](_0x7e3ef7)){const _0xab1349=this['_getPreviousFrom'](_0x7e3ef7);this['_calculateMetaData'](_0xab1349,_0x7e3ef7,!0x1);}this['_calculateMetaData'](_0x7e3ef7,_0x3d1683,!0x0);}return this['_lastFrom']=_0x7e3ef7,this['_lastTo']=_0x3d1683,this['_getState']();}['loadState'](_0x80476){if(!this['_savedMetaData']['has'](_0x80476['fromVersion'])){const _0x150b8a=this['_getPreviousFrom'](_0x80476['fromVersion']);this['_calculateMetaData'](_0x150b8a,_0x80476['fromVersion'],!0x1);}this['_calculateMetaData'](_0x80476['fromVersion'],_0x80476['toVersion'],!0x1);const _0x196996=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x80476['fromVersion'],this['_lastTo']=_0x80476['toVersion'];for(const _0x5c48a3 in _0x80476['diffData']){const _0x51a866=_0x80476['diffData'][_0x5c48a3]['attachChange'],_0x58e058=_0x531982(_0x80476['diffData'][_0x5c48a3]['attributesBefore'])||{},_0x46a168=_0x80476['diffData'][_0x5c48a3],_0x490ab7=_0x196996['_makeModelFromViewString'](_0x46a168['deletions'],_0x46a168['rootElementName']||'$root');_0x490ab7['rootName']=_0x5c48a3,_0x490ab7['_isAttached']=!_0x51a866||!_0x51a866['isAttached'],_0x490ab7['isAttached']=()=>_0x490ab7['_isAttached'],this['_baseRoots']['set'](_0x5c48a3,_0x490ab7),this['_baseRootsAttributes']['set'](_0x5c48a3,_0x58e058),_0x51a866&&this['_touchedRoots']['set'](_0x5c48a3,_0x51a866);const _0x127e12=this['_makeIdsRoot'](_0x490ab7);this['_baseIdsRoots']['set'](_0x5c48a3,_0x127e12);for(const [_0x5a0aed,_0x53ac30]of _0x490ab7['markers']){if(!_0x5a0aed['startsWith']('revision:'))continue;const _0x30e68d=_0x5a0aed['split'](':')[0x2];for(const _0x117459 of _0x53ac30['getWalker']({'singleCharacters':!0x0})){const _0x452f21=this['_getVidAttributeName'](_0x117459),_0x1793df='elementEnd'==_0x117459['type']?_0x117459['previousPosition']['path']['slice'](0x0,-0x1):_0x117459['previousPosition']['path'],_0x3f845f=_0x127e12['getNodeByPath'](_0x1793df)['getAttribute'](_0x452f21);this['_touched']['set'](_0x3f845f,{'userId':_0x30e68d});}_0x490ab7['markers']['delete'](_0x5a0aed);}}this['_startingRevisionId']=this['_revisionId'];const _0x2f6385=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x485160=>!this['_touched']['has'](_0x485160));let _0x34ac50=0x0;const _0x1b2298=new Map();for(const _0x263fc7 in _0x80476['diffData']){const _0x3e6199=_0x80476['diffData'][_0x263fc7]['attachChange'],_0x3cff37=_0x531982(_0x80476['diffData'][_0x263fc7]['attributesAfter'])||{},_0x45c5f8=_0x80476['diffData'][_0x263fc7],_0x13cb5b=_0x196996['_makeModelFromViewString'](_0x45c5f8['insertions'],_0x45c5f8['rootElementName']||'$root');_0x13cb5b['rootName']=_0x263fc7,_0x13cb5b['_isAttached']=!_0x3e6199||_0x3e6199['isAttached'],_0x13cb5b['isAttached']=()=>_0x13cb5b['_isAttached'],this['_diffRoots']['set'](_0x263fc7,_0x13cb5b),this['_diffRootsAttributes']['set'](_0x263fc7,_0x3cff37);const _0x1d6ca5=this['_makeIdsRoot'](_0x13cb5b,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x263fc7,_0x1d6ca5),_0x1b2298['set'](_0x263fc7,_0x13cb5b['isAttached']()?_0x3cff37:{});for(const [_0x3b5eb6,_0x178ca8]of _0x13cb5b['markers']){if(!_0x3b5eb6['startsWith']('revision:'))continue;const _0x3d84e2=_0x3b5eb6['split'](':')[0x2];for(const _0x1aaf7f of _0x178ca8['getWalker']({'singleCharacters':!0x0})){const _0x50f638=this['_getVidAttributeName'](_0x1aaf7f),_0x2d974e=this['_revisionId']++,_0x299e20='elementEnd'==_0x1aaf7f['type']?_0x1aaf7f['previousPosition']['path']['slice'](0x0,-0x1):_0x1aaf7f['previousPosition']['path'];_0x1d6ca5['getNodeByPath'](_0x299e20)['_setAttribute'](_0x50f638,_0x2d974e),this['_touched']['set'](_0x2d974e,{'userId':_0x3d84e2});}_0x13cb5b['markers']['delete'](_0x3b5eb6);}for(const _0x44726c of this['editor']['model']['createRangeIn'](_0x13cb5b)['getWalker']({'singleCharacters':!0x0})){const _0x317763=this['_getVidAttributeName'](_0x44726c),_0x278a52='elementEnd'==_0x44726c['type']?_0x44726c['previousPosition']['path']['slice'](0x0,-0x1):_0x44726c['previousPosition']['path'],_0x5b4d00=_0x1d6ca5['getNodeByPath'](_0x278a52);_0x5b4d00['getAttribute'](_0x317763)>0x0||_0x5b4d00['_setAttribute'](_0x317763,_0x2f6385[_0x34ac50++]);}for(const [_0x4fd6fd,_0x28c76a]of _0x13cb5b['markers'])_0x4fd6fd['startsWith']('revision:')||this['_markers']['set'](_0x4fd6fd,_0x28c76a);}const {roots:_0x28a61e}=this['_savedMetaData']['get'](_0x80476['fromVersion']),{roots:_0x51707b}=this['_savedMetaData']['get'](_0x80476['toVersion']),_0x502bb0=gt(_0x28a61e['get']('$graveyard'));this['_baseRoots']['set']('$graveyard',_0x502bb0),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x502bb0,Number['NEGATIVE_INFINITY']));const _0x2cb6fc=gt(_0x51707b['get']('$graveyard'));this['_diffRoots']['set']('$graveyard',_0x2cb6fc),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x2cb6fc));const _0x1cf0f3=Array['from'](this['_diffRoots'])['map'](([_0x57eb33,_0x2fe268])=>[_0x57eb33,gt(_0x2fe268)]);this['_saveMetaData'](this['_lastTo'],_0x1cf0f3,this['_markers'],_0x1b2298);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0x1a3a0f,_0x4cd1ee,_0x12119e,_0x41e98b){const _0x15af4d=new Map(_0x4cd1ee),_0x2d47af=new Map(_0x531982(_0x41e98b)),_0x3de88f=new Map();for(const [_0x5c466d,_0x125400]of _0x12119e)_0x3de88f['set'](_0x5c466d,{'start':_0x125400['start']['clone'](),'end':_0x125400['end']['clone'](),'rootName':_0x125400['root']['rootName']});this['_savedMetaData']['set'](_0x1a3a0f,{'roots':_0x15af4d,'markers':_0x3de88f,'rootsAttributes':_0x2d47af});}['_removeMetaData'](_0x20c1df){this['_savedMetaData']['delete'](_0x20c1df);}['_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'](_0x31415e,_0x2c95d3=null){let _0x3ebfb0=null;_0x31415e['is']('documentFragment')||(_0x3ebfb0=new _0x4052b4(_0x31415e['name'],{'vid_start':null===_0x2c95d3?this['_revisionId']++:_0x2c95d3++}));const _0x21e7cf=[];for(const _0x5c60cf of _0x31415e['getChildren']())if(_0x5c60cf['is']('element')){_0x21e7cf['push'](this['_makeIdsRoot'](_0x5c60cf,_0x2c95d3));const _0x1221c2=_0x21e7cf[_0x21e7cf['length']-0x1];null!==_0x2c95d3&&(_0x2c95d3=_0x1221c2['is']('element','$text')?_0x1221c2['getAttribute']('vid')+0x1:_0x1221c2['getAttribute']('vid_end')+0x1);}else{for(let _0x53957a=0x0;_0x53957a<_0x5c60cf['offsetSize'];_0x53957a++)_0x21e7cf['push'](new _0x4052b4('$text',{'vid':null===_0x2c95d3?this['_revisionId']++:_0x2c95d3++}));}if(_0x31415e['is']('documentFragment')){const _0x47275e=wt(_0x31415e['rootName'],_0x31415e['name']);return _0x47275e['_insertChild'](0x0,_0x21e7cf),_0x47275e;}return _0x3ebfb0['_setAttribute']('vid_end',null===_0x2c95d3?this['_revisionId']++:_0x2c95d3++),_0x3ebfb0['_insertChild'](0x0,_0x21e7cf),_0x3ebfb0;}['_calculateMetaData'](_0xb60ab7,_0x1078de,_0x5510a9){this['_reset']();const {roots:_0x6c66bf,markers:_0x5dd0d,rootsAttributes:_0x59b3fc}=this['_savedMetaData']['get'](_0xb60ab7);this['_baseRoots']=new Map(_0x6c66bf),this['_baseRootsAttributes']=new Map(_0x531982(_0x59b3fc));for(const [_0x2d6a1e,_0x2bf8b4]of this['_baseRoots'])if('$graveyard'!==_0x2d6a1e&&(this['_diffRoots']['set'](_0x2d6a1e,gt(_0x2bf8b4)),this['_diffRootsAttributes']=new Map(_0x531982(_0x59b3fc)),_0x5510a9)){const _0x33e155=this['_revisionId'];this['_idsRoots']['set'](_0x2d6a1e,this['_makeIdsRoot'](_0x2bf8b4)),this['_baseIdsRoots']['set'](_0x2d6a1e,this['_makeIdsRoot'](_0x2bf8b4,_0x33e155));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',gt(this['_baseRoots']['get']('$graveyard'))),_0x5510a9&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x38cf72,_0x45398d]of _0x5dd0d){const _0x3cfec4=this['_baseRoots']['get'](_0x45398d['rootName']),_0x2cb9a4=this['_diffRoots']['get'](_0x45398d['rootName']),_0x1bda5e=new _0x5cfc88(this['_fixPosition'](_0x45398d['start'],_0x3cfec4),this['_fixPosition'](_0x45398d['end'],_0x3cfec4)),_0x3f474a=this['_fixRange'](_0x1bda5e,_0x2cb9a4);_0x3cfec4['markers']['set'](_0x38cf72,_0x1bda5e),this['_markers']['set'](_0x38cf72,_0x3f474a);}this['_applyOperations'](_0xb60ab7,_0x1078de,_0x5510a9);}['_applyOperations'](_0xd47e8f,_0x1e878a,_0x28bf53){for(const _0x30bfe4 of this['source']['getOperations'](_0xd47e8f,_0x1e878a))this['_handleOperation'](_0x30bfe4,_0x28bf53);for(const _0x413fdd of this['_diffRoots']['values']())_0x413fdd['markers']['clear']();for(const [_0x1dfa0d,_0x23a275]of this['_markers']){this['_diffRoots']['get'](_0x23a275['root']['rootName'])['markers']['set'](_0x1dfa0d,_0x23a275['clone']());}const _0x378780=new Map(),_0x5274b2=new Map();for(const [_0x2d50f4,_0x3b599a]of this['_diffRoots'])_0x378780['set'](_0x2d50f4,gt(_0x3b599a)),_0x5274b2['set'](_0x2d50f4,this['_diffRootsAttributes']['get'](_0x2d50f4));this['_saveMetaData'](_0x1e878a,_0x378780,this['_markers'],_0x5274b2);}['_getPreviousFrom'](_0x31d52c){const _0x44f95e=Array['from'](this['_savedMetaData']['keys']());_0x44f95e['sort']((_0x3ab1a4,_0x40285c)=>_0x3ab1a4-_0x40285c),_0x44f95e['reverse']();for(const _0xb1edee of _0x44f95e)if(_0xb1edee<_0x31d52c)return _0xb1edee;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x10c667,_0x19681b){const _0x51a115=Array['from'](_0x19681b['markers'])['map'](([_0xc10721,_0x15a2fb])=>[_0xc10721,this['_fixRange'](_0x15a2fb,_0x10c667)]);_0x10c667['markers']=new Map(_0x51a115);}['_transformMarkers'](_0x2b403a){for(const _0x1b0598 of this['_markers']['values']()){const _0x32fc0c=_0x1b0598['getTransformedByOperation'](_0x2b403a),_0x5c7e67=_0x5cfc88['_createFromRanges'](_0x32fc0c);_0x1b0598['start']=_0x5c7e67['start'],_0x1b0598['end']=_0x5c7e67['end'];}}['_handleOperation'](_0x1363d1,_0x28c31d){if('addRoot'!=_0x1363d1['type']&&'detachRoot'!=_0x1363d1['type']){if('insert'==_0x1363d1['type']){const _0x2bf7d9=_0x1363d1['position']['root'],_0x169e7d=_0x2bf7d9['rootName'],_0x48d866=_0x2bf7d9['name'];this['_diffRoots']['has'](_0x169e7d)||(this['_diffRoots']['set'](_0x169e7d,wt(_0x169e7d,_0x48d866,!0x0)),this['_diffRootsAttributes']['set'](_0x169e7d,{}),_0x28c31d&&this['_idsRoots']['set'](_0x169e7d,wt(_0x169e7d,_0x48d866,!0x0)));}else{if('addRootAttribute'==_0x1363d1['type']||'removeRootAttribute'==_0x1363d1['type']||'changeRootAttribute'==_0x1363d1['type'])return void this['_handleRootAttributeOperation'](_0x1363d1);'marker'==_0x1363d1['type']&&this['_handleMarkerOperation'](_0x1363d1);}if('marker'!==_0x1363d1['type']){const _0x117846=this['_cloneOperation'](_0x1363d1,this['_diffRoots']);_0x117846['_execute'](),this['_transformMarkers'](_0x117846);}if(_0x28c31d)switch(_0x1363d1['type']){case'insert':this['_handleInsertOperation'](_0x1363d1);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x1363d1);break;case'merge':this['_handleMergeOperation'](_0x1363d1);break;case'split':this['_handleSplitOperation'](_0x1363d1);}}else this['_handleRootOperation'](_0x1363d1,_0x28c31d);}['_cloneOperation'](_0x5226e4,_0x160e3d){const _0x37b3c7=_0x5226e4['clone']();return _0x37b3c7['_authorId']=_0x5226e4['_authorId'],this['_fixOperation'](_0x37b3c7,_0x160e3d),_0x37b3c7;}['_getBaseVids'](_0x477e90){return _0x477e90['map'](_0x5d84dc=>{const _0x2efc09=this['_getVidAttributeName'](_0x5d84dc);return Number(_0x5d84dc['item']['getAttribute'](_0x2efc09));});}['_generateTape'](_0x493163,_0x418ac7){if(_0x493163['is']('element','$text'))_0x418ac7['push']({'item':_0x493163,'type':'text'});else{_0x493163['is']('element')&&_0x418ac7['push']({'item':_0x493163,'type':'elementStart'});for(const _0x3d7794 of _0x493163['getChildren']())this['_generateTape'](_0x3d7794,_0x418ac7);_0x493163['is']('element')&&_0x418ac7['push']({'item':_0x493163,'type':'elementEnd'});}return _0x418ac7;}['_getState'](){const _0x42f030=new Map(this['_touched']),_0x7ec812=new Map(_0x42f030),_0x3f8aac=new Map(),_0x8469a3={'insertions':{},'deletions':{}},_0xb9e6c={'insertions':{},'deletions':{}},_0x2c8539=new Map(),_0x31986c=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]),_0x5b9438=new Map();_0x31986c['delete']('$graveyard');for(const _0xe5da85 of _0x31986c){const _0x4cc9df=(this['_diffRoots']['get'](_0xe5da85)??this['_baseRoots']['get'](_0xe5da85))['name'],_0x2391a8=this['_diffRoots']['get'](_0xe5da85)||wt(_0xe5da85,_0x4cc9df,!0x1),_0xf8c285=this['_baseRoots']['get'](_0xe5da85)||wt(_0xe5da85,_0x4cc9df,!0x1);_0x2391a8['isAttached']()||_0xf8c285['isAttached']()?(_0x5b9438['set'](_0xe5da85,_0x4cc9df),_0x8469a3['insertions'][_0xe5da85]=gt(_0x2391a8),_0x8469a3['deletions'][_0xe5da85]=gt(_0xf8c285),this['_copyMarkers'](_0x8469a3['deletions'][_0xe5da85],_0xf8c285),this['_copyMarkers'](_0x8469a3['insertions'][_0xe5da85],_0x2391a8),_0xb9e6c['insertions'][_0xe5da85]=this['_generateTape'](this['_idsRoots']['get'](_0xe5da85),[]),_0xb9e6c['deletions'][_0xe5da85]=this['_generateTape'](this['_baseIdsRoots']['get'](_0xe5da85)||wt(_0xe5da85,_0x4cc9df,!0x1),[])):_0x31986c['delete'](_0xe5da85);}for(const _0x19cf6c of _0x31986c){const _0x5cf8ea=_0xb9e6c['insertions'][_0x19cf6c];for(const _0x29306e of _0x5cf8ea){const _0x3c5e5b=this['_getVidAttributeName'](_0x29306e),_0x219601=_0x29306e['item']['getAttribute'](_0x3c5e5b);_0x7ec812['delete'](_0x219601),_0x219601>=this['_startingRevisionId']&&_0x3f8aac['set'](_0x219601,_0x42f030['get'](_0x219601));}}for(const _0x4fb4f9 of _0x31986c){const _0x1b78f0=_0xb9e6c['insertions'][_0x4fb4f9],_0x14e479=this['_getBaseVids'](_0xb9e6c['deletions'][_0x4fb4f9]);let _0x119ae7=0x0;for(const _0x567b2e of _0x1b78f0){const _0x122264=this['_getVidAttributeName'](_0x567b2e),_0x4b5d17=_0x567b2e['item']['getAttribute'](_0x122264);if(!_0x3f8aac['has'](_0x4b5d17)&&!_0x2c8539['has'](_0x4b5d17)){if(_0x7ec812['has'](_0x4b5d17))_0x119ae7++;else{if(_0x4b5d17!=_0x14e479[_0x119ae7]){const _0xc9d14c=_0x42f030['get'](_0x4b5d17)||_0x42f030['get'](_0x14e479[_0x119ae7]);for(;_0x4b5d17!=_0x14e479[_0x119ae7];)_0x7ec812['has'](_0x14e479[_0x119ae7])||(_0x2c8539['set'](_0x14e479[_0x119ae7],_0xc9d14c),_0x42f030['set'](_0x14e479[_0x119ae7],_0xc9d14c)),_0x119ae7++;}_0x119ae7++;}}}}for(const _0x4d5e60 of _0x31986c){const _0x4d7999=_0xb9e6c['insertions'][_0x4d5e60];for(const _0xaaa407 of _0x4d7999){const _0xb08980=this['_getVidAttributeName'](_0xaaa407),_0x39110b=_0xaaa407['item']['getAttribute'](_0xb08980);if(_0x2c8539['has'](_0x39110b)){const _0x427f97=_0x2c8539['get'](_0x39110b);_0x7ec812['has'](_0x39110b)||_0x7ec812['set'](_0x39110b,{..._0x427f97}),_0x3f8aac['set'](_0x39110b,{..._0x427f97});}}}for(const _0x24c032 of _0x7ec812['keys']())_0x24c032>=this['_startingRevisionId']&&_0x7ec812['delete'](_0x24c032);const _0x5c1165=new Map();for(const _0x461eb3 of _0x31986c){let _0x4e8897=_0xb9e6c['insertions'][_0x461eb3];for(const _0x10b655 of _0x4e8897)if(_0x10b655['item']['is']('element','tableCell')){const _0x1af7a0=this['_getVidAttributeName'](_0x10b655),_0x426669=_0x10b655['item']['getAttribute'](_0x1af7a0);if(_0x3f8aac['has'](_0x426669)){const _0x13e55d=_0x10b655['item']['parent']['parent']['getAttribute']('vid_start'),_0x2f4ec8=_0x5c1165['get'](_0x13e55d)||new Set();_0x2f4ec8['add'](_0x3f8aac['get'](_0x426669)['userId']),_0x5c1165['set'](_0x13e55d,_0x2f4ec8);}}_0x4e8897=_0xb9e6c['deletions'][_0x461eb3];for(const _0x2d410f of _0x4e8897)if(_0x2d410f['item']['is']('element','tableCell')){const _0x2624c3=this['_getVidAttributeName'](_0x2d410f),_0x2a7dc8=_0x2d410f['item']['getAttribute'](_0x2624c3);if(_0x7ec812['has'](_0x2a7dc8)){const _0x201f69=_0x2d410f['item']['parent']['parent']['getAttribute']('vid_start'),_0xbadd9=_0x5c1165['get'](_0x201f69)||new Set();_0xbadd9['add'](_0x7ec812['get'](_0x2a7dc8)['userId']),_0x5c1165['set'](_0x201f69,_0xbadd9);}}for(const _0x1bada5 of _0x5c1165['keys']())(_0x3f8aac['has'](_0x1bada5)||_0x7ec812['has'](_0x1bada5))&&_0x5c1165['delete'](_0x1bada5);}for(const _0x2e01cd of _0x31986c){const _0x49d514=_0xb9e6c['insertions'][_0x2e01cd];let _0x34c147=null,_0xdf2b6d=null;for(const _0x899a7b of _0x49d514){const _0x4ede06=this['_getVidAttributeName'](_0x899a7b),_0x38a2eb=_0x899a7b['item']['getAttribute'](_0x4ede06),_0xd9cb59=_0x5c1165['get'](_0x38a2eb);_0xd9cb59&&'elementStart'==_0x899a7b['type']&&(_0x34c147=Array['from'](_0xd9cb59)[0x0],_0xdf2b6d=_0x899a7b['item']['getAttribute']('vid_end')),_0x34c147&&(_0x7ec812['set'](_0x38a2eb,{'userId':_0x34c147}),_0x3f8aac['set'](_0x38a2eb,{'userId':_0x34c147})),_0x38a2eb==_0xdf2b6d&&(_0x34c147=null,_0xdf2b6d=null);}}const _0x45c2be={},_0x2f2aa1=new Set();for(const _0x1a69b0 of _0x31986c){const _0x543e35=_0x8469a3['deletions'][_0x1a69b0],_0x3b6e30=_0x8469a3['insertions'][_0x1a69b0];for(const {userId:_0x10d25e}of this['_touchedMarkers']['values']())null!==_0x10d25e&&_0x2f2aa1['add'](_0x10d25e);for(const {userId:_0x2d9adf}of this['_touchedRoots']['values']())null!==_0x2d9adf&&_0x2f2aa1['add'](_0x2d9adf);this['_markChanges'](_0x3b6e30,_0xb9e6c['insertions'][_0x1a69b0],_0x3f8aac,'insertion',_0x2f2aa1),this['_markChanges'](_0x543e35,_0xb9e6c['deletions'][_0x1a69b0],_0x7ec812,'deletion',_0x2f2aa1),_0x45c2be[_0x1a69b0]={'insertions':this['_prepareViewToSave'](_0x3b6e30),'deletions':this['_prepareViewToSave'](_0x543e35),'attachChange':this['_touchedRoots']['get'](_0x1a69b0)||null,'attributesBefore':_0x531982(this['_baseRootsAttributes']['get'](_0x1a69b0))||{},'attributesAfter':_0x531982(this['_diffRootsAttributes']['get'](_0x1a69b0)),'rootElementName':_0x5b9438['get'](_0x1a69b0)};}return{'diffData':_0x45c2be,'authorsIds':Array['from'](_0x2f2aa1)};}['_processRootBeforeSave'](_0xe6c319){for(const [,_0x261b40]of _0xe6c319['markers']){const _0x5634f3=_0x261b40['start']['getAncestors']()['filter'](_0x20b0fc=>'tableCell'==_0x20b0fc['name']);for(const _0xa6c863 of _0x5634f3)0x1==_0xa6c863['childCount']&&_0xa6c863['getChild'](0x0)['is']('element','paragraph')&&_0xa6c863['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x401aff){this['_processRootBeforeSave'](_0x401aff);const _0x4b6a3f=this['editor']['data']['toView'](_0x401aff,{}),_0x44b53f=Array['from'](_0x4b6a3f['getChildren']())['map'](_0x2fb6fa=>this['_getViewJson'](_0x2fb6fa));return JSON['stringify'](_0x44b53f);}['_getViewJson'](_0x2e48cd){if(_0x2e48cd['is']('$text'))return _0x2e48cd['data'];{const _0x5d83d1=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0x24040b=_0x2e48cd,_0xe936bf=this['editor']['data']['htmlProcessor']['domConverter'],_0x270901={'type':_0x5d83d1['_getTypeCharForViewElement'](_0x24040b),'name':_0x24040b['name'],'attributes':Array['from'](_0x24040b['getAttributes']()),'children':Array['from'](_0x24040b['getChildren']())['map'](_0x28b709=>this['_getViewJson'](_0x28b709))};if(_0x2e48cd['is']('uiElement')&&'$comment'!=_0x2e48cd['name']){const _0x2f0370=_0x2e48cd['render'](_0xe936bf['domDocument'],_0xe936bf);_0x270901['children']['push'](_0x2f0370['outerHTML']);}else{if(_0x2e48cd['is']('rawElement')){const _0x46d480=_0xe936bf['domDocument']['createElement'](_0x24040b['name']);_0x2e48cd['render'](_0x46d480,_0xe936bf),_0x270901['children']['push'](_0x46d480['innerHTML']);}}const _0x391fec=Array['from'](_0x24040b['getCustomProperties']());_0x391fec['length']>0x0&&(_0x270901['customProperties']=_0x391fec);const _0x40412e=_0x24040b['getFillerOffset']();return null!==_0x40412e&&(_0x270901['fillerOffset']=_0x40412e),_0x270901;}}['_markChanges'](_0xf652dc,_0x2de51d,_0x227f58,_0x221bf6,_0x3678fb){let _0x61f713=null,_0x5a337a=null,_0x4b253b=0x0;const _0x249314=this['editor']['model'];for(let _0x1d9809=0x0;_0x1d9809<_0x2de51d['length'];_0x1d9809++){const _0x4a7d60=this['_getVidAttributeName'](_0x2de51d[_0x1d9809]),_0x15a9dc=_0x2de51d[_0x1d9809]['item']['getAttribute'](_0x4a7d60),_0x1fb9ad=_0x227f58['get'](_0x15a9dc),_0x2076e3=_0x1d9809==_0x2de51d['length']-0x1;(!_0x61f713&&_0x1fb9ad&&(_0x61f713=_0x1fb9ad,_0x5a337a=_0x2de51d[_0x1d9809]),_0x61f713&&(!_0x1fb9ad||_0x1fb9ad['userId']!=_0x61f713['userId']))&&(_0x4254c9(_0x1fb9ad,mt(_0x5a337a,_0xf652dc,_0x249314),mt(_0x2de51d[_0x1d9809],_0xf652dc,_0x249314)),_0x61f713=_0x1fb9ad||null,_0x5a337a=_0x1fb9ad?_0x2de51d[_0x1d9809]:null),_0x61f713&&_0x2076e3&&_0x4254c9(_0x1fb9ad,mt(_0x5a337a,_0xf652dc,_0x249314),pt(_0x2de51d[_0x1d9809],_0xf652dc,_0x249314));}function _0x4254c9(_0x28e232,_0x33241d,_0x12b683){const _0x2c7bda=_0x61f713['userId'],_0xfd2ec4='revision:'+_0x221bf6+':'+_0x2c7bda+':'+_0x4b253b++,_0x334e7e=_0x249314['createRange'](_0x33241d,_0x12b683);_0xf652dc['markers']['set'](_0xfd2ec4,_0x334e7e),null!==_0x2c7bda&&_0x3678fb['add'](_0x2c7bda);}}['_getVidAttributeName'](_0x35e007){switch(_0x35e007['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x2b8739,_0x5404cc){_0x2b8739['baseVersion']=null;for(const _0x2a9301 in _0x2b8739){const _0x167b5c=_0x2b8739[_0x2a9301];if(_0x167b5c instanceof _0x627322){const _0x173229=_0x5404cc['get'](_0x167b5c['root']['rootName']);_0x2b8739[_0x2a9301]=this['_fixPosition'](_0x167b5c,_0x173229);}if(_0x167b5c instanceof _0x5cfc88){const _0x5ee572=_0x5404cc['get'](_0x167b5c['root']['rootName']);_0x2b8739[_0x2a9301]=this['_fixRange'](_0x167b5c,_0x5ee572);}'root'===_0x2a9301&&(_0x2b8739['root']=_0x5404cc['get'](_0x2b8739['root']['rootName']));}}['_fixRange'](_0x18cb91,_0x1211b2){return this['editor']['model']['createRange'](this['_fixPosition'](_0x18cb91['start'],_0x1211b2),this['_fixPosition'](_0x18cb91['end'],_0x1211b2));}['_fixPosition'](_0xe6231a,_0x530fa1){return this['editor']['model']['createPositionFromPath'](_0x530fa1,_0xe6231a['path'],_0xe6231a['stickiness']);}['_handleInsertOperation'](_0x59bbe8){const _0x2bd0f3=this['_idsRoots']['get'](_0x59bbe8['position']['root']['rootName']),_0x10f372=this['_fixPosition'](_0x59bbe8['position'],_0x2bd0f3),_0x4bde77=null===_0x59bbe8['_authorId']?null:_0x59bbe8['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x5d73ca=_0x10f372['parent'],_0x2709a5=this['_revisionId'],_0x1c5d4c=[];for(const _0x247fcd of _0x59bbe8['nodes'])if(_0x247fcd['is']('element'))_0x1c5d4c['push'](this['_makeIdsRoot'](_0x247fcd));else{for(let _0x1439bc=0x0;_0x1439bc<_0x247fcd['offsetSize'];_0x1439bc++)_0x1c5d4c['push'](new _0x4052b4('$text',{'vid':this['_revisionId']++}));}const _0x492124=this['_revisionId'];for(let _0x5997f3=_0x2709a5;_0x5997f3<_0x492124;_0x5997f3++)this['_touched']['set'](_0x5997f3,{'userId':_0x4bde77});_0x5d73ca['_insertChild'](_0x10f372['offset'],_0x1c5d4c);}['_handleMoveOperation'](_0x2eaa69){(_0x2eaa69=this['_cloneOperation'](_0x2eaa69,this['_idsRoots']))['_execute']();const _0x39df17=null===_0x2eaa69['_authorId']?null:_0x2eaa69['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x5916b7=_0x2eaa69['getMovedRangeStart'](),_0x5e3689=_0x5916b7['parent'],_0xba6304=_0x5916b7['offset'];!function _0x1a7997(_0x1a799e,_0x22f36,_0x3e0ce3,_0x16015f){for(let _0x462ec3=_0x3e0ce3;_0x462ec3<_0x16015f;_0x462ec3++){const _0x598fe4=_0x22f36['getChild'](_0x462ec3);_0x598fe4['is']('element','$text')?_0x1a799e['set'](_0x598fe4['getAttribute']('vid'),{'userId':_0x39df17}):(_0x1a799e['set'](_0x598fe4['getAttribute']('vid_start'),{'userId':_0x39df17}),_0x1a7997(_0x1a799e,_0x598fe4,0x0,_0x598fe4['childCount']),_0x1a799e['set'](_0x598fe4['getAttribute']('vid_end'),{'userId':_0x39df17}));}}(this['_touched'],_0x5e3689,_0xba6304,_0xba6304+_0x2eaa69['howMany']);}['_handleMergeOperation'](_0x5d05a2){const _0x201d3f=null===(_0x5d05a2=this['_cloneOperation'](_0x5d05a2,this['_idsRoots']))['_authorId']?null:_0x5d05a2['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x3d3055=_0x5d05a2['targetPosition']['parent'],_0x588b33=_0x5d05a2['sourcePosition']['parent'],_0x34a58d=_0x3d3055['getAttribute']('vid_end'),_0x514556=_0x588b33['getAttribute']('vid_start');_0x3d3055['_setAttribute']('vid_end',_0x588b33['getAttribute']('vid_end')),_0x588b33['_setAttribute']('vid_end',_0x34a58d),this['_touched']['set'](_0x514556,{'userId':_0x201d3f}),this['_touched']['set'](_0x34a58d,{'userId':_0x201d3f}),_0x5d05a2['_execute']();}['_handleSplitOperation'](_0x30fec9){const _0xcdaec9=null===(_0x30fec9=this['_cloneOperation'](_0x30fec9,this['_idsRoots']))['_authorId']?null:_0x30fec9['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x354d24=_0x30fec9['graveyardPosition'],_0x172354=_0x30fec9['splitPosition']['parent'];_0x30fec9['_execute']();const _0x43f716=_0x172354['getAttribute']('vid_end'),_0x4c76d6=_0x30fec9['insertionPosition']['nodeAfter'];if(_0x354d24){const _0x11741f=_0x4c76d6['getAttribute']('vid_end'),_0x2889e9=_0x172354['getAttribute']('vid_end');_0x172354['_setAttribute']('vid_end',_0x11741f),_0x4c76d6['_setAttribute']('vid_end',_0x2889e9),this['_touched']['set'](_0x172354['getAttribute']('vid_end'),{'userId':_0xcdaec9}),this['_touched']['set'](_0x4c76d6['getAttribute']('vid_start'),{'userId':_0xcdaec9});}else{const _0x451109=this['_revisionId']++,_0x13fe8f=this['_revisionId']++;_0x172354['_setAttribute']('vid_end',_0x451109),_0x4c76d6['_setAttribute']('vid_start',_0x13fe8f),_0x4c76d6['_setAttribute']('vid_end',_0x43f716),this['_touched']['set'](_0x451109,{'userId':_0xcdaec9}),this['_touched']['set'](_0x13fe8f,{'userId':_0xcdaec9});}}['_handleMarkerOperation'](_0x1b12c1){if(!_0x1b12c1['affectsData'])return;const _0x4bb4f8=(_0x1b12c1=this['_cloneOperation'](_0x1b12c1,this['_diffRoots']))['oldRange']?_0x1b12c1['oldRange']['root']:null,_0xc84738=_0x1b12c1['newRange']?_0x1b12c1['newRange']['root']:null;_0x4bb4f8&&this['_markers']['delete'](_0x1b12c1['name']),_0xc84738&&this['_markers']['set'](_0x1b12c1['name'],_0x1b12c1['newRange']['clone']());const _0x14dd2d=null===_0x1b12c1['_authorId']?null:_0x1b12c1['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x1693a3=_0x1b12c1['name'];if(!this['_touchedMarkers']['has'](_0x1693a3))return void this['_touchedMarkers']['set'](_0x1693a3,{'range':_0x1b12c1['oldRange'],'userId':_0x14dd2d});const _0x1324e7=this['_touchedMarkers']['get'](_0x1693a3),_0x48180e=_0x1324e7['range'],_0x54fbcb=_0x1b12c1['newRange'];null==_0x48180e&&null==_0x54fbcb||_0x48180e&&_0x54fbcb&&_0x48180e['isEqual'](_0x54fbcb)?this['_touchedMarkers']['delete'](_0x1b12c1['name']):_0x1324e7['userId']=_0x14dd2d;}['_handleRootOperation'](_0x835289,_0x4feee0){this['_diffRoots']['has'](_0x835289['rootName'])?this['_diffRoots']['get'](_0x835289['rootName'])['_isAttached']=_0x835289['isAdd']:(this['_diffRoots']['set'](_0x835289['rootName'],wt(_0x835289['rootName'],_0x835289['elementName'],!0x0)),this['_diffRootsAttributes']['set'](_0x835289['rootName'],{}),_0x4feee0&&this['_idsRoots']['set'](_0x835289['rootName'],wt(_0x835289['rootName'],_0x835289['elementName'],!0x0)));const _0x825b9b=null===_0x835289['_authorId']?null:_0x835289['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x53a538=this['_touchedRoots']['get'](_0x835289['rootName']);_0x53a538&&_0x53a538['userId']===_0x825b9b?this['_touchedRoots']['delete'](_0x835289['rootName']):this['_touchedRoots']['set'](_0x835289['rootName'],{'userId':_0x825b9b,'isAttached':_0x835289['isAdd']});}['_handleRootAttributeOperation'](_0x137f66){const _0x2b664c=this['_diffRootsAttributes']['get'](_0x137f66['root']['rootName']);null===_0x137f66['newValue']?delete _0x2b664c[_0x137f66['key']]:_0x2b664c[_0x137f66['key']]=_0x137f66['newValue'];}}function gt(_0x46074a){const _0x584579=wt(_0x46074a['rootName'],_0x46074a['name'],_0x46074a['isAttached']());for(const _0x3e8156 of _0x46074a['getChildren']()){const _0x3f7721=_0x3e8156['_clone'](!0x0);_0x584579['_appendChild'](_0x3f7721);}return _0x584579;}function wt(_0x39f560,_0x2ed003,_0x21a4d6=!0x0){const _0x18dde3=new _0x54af68();return _0x18dde3['rootName']=_0x39f560,_0x18dde3['name']=_0x2ed003,_0x18dde3['_isAttached']=_0x21a4d6,_0x18dde3['isAttached']=()=>_0x18dde3['_isAttached'],_0x18dde3;}function mt(_0x505135,_0x844fbe,_0x3aa038){const _0x5b323d='elementEnd'==_0x505135['type']?_0x3aa038['createPositionAt'](_0x505135['item'],'end'):_0x3aa038['createPositionBefore'](_0x505135['item']);return _0x3aa038['createPositionFromPath'](_0x844fbe,_0x5b323d['path'],_0x5b323d['stickiness']);}function pt(_0x5904c6,_0x1d3913,_0x4ade7a){const _0x8a4dc='elementStart'==_0x5904c6['type']?_0x4ade7a['createPositionAt'](_0x5904c6['item'],0x0):_0x4ade7a['createPositionAfter'](_0x5904c6['item']);return _0x4ade7a['createPositionFromPath'](_0x1d3913,_0x8a4dc['path'],_0x8a4dc['stickiness']);}class RevisionHistorySaveRevisionFormView extends/* #__PURE__ -- @preserve */
|
|
25
|
-
|
|
26
|
-
_0x5f230a(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x219384){super(),this['id']=_0x219384['id']||_0x2d6fd8(),this['author']=_0x219384['author'],this['type']=_0x219384['type'],this['data']=_0x219384['data']||{},this['rootName']=_0x219384['rootName'],this['set']('createdAt',_0x219384['createdAt']);}['toJSON'](){return{'id':this['id'],'authorId':this['author']['id'],'type':this['type'],'data':this['data'],'createdAt':this['createdAt']};}}class RevisionDiff{['newRevisionId'];['oldRevisionId'];['changes'];constructor(_0x183b57,_0x155985){this['newRevisionId']=_0x183b57,this['oldRevisionId']=_0x155985,this['changes']=new _0x1224a0();}['_setChanges'](_0x1e6b12){for(const _0x31800c of _0x1e6b12)this['changes']['add'](_0x31800c);}}class RevisionViewer extends _0x4c1791{['repository'];['adapter']=null;['_utils'];['_activeViewTarget'];['_changeView'];['_changeIdToChange'];['_balloon'];static get['pluginName'](){return'RevisionViewer';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[_0x48a34e,et,RevisionsRepository,RevisionHistoryUtils];}constructor(_0x162671){super(_0x162671),this['repository']=this['editor']['plugins']['get']('RevisionsRepository'),this['_utils']=this['editor']['plugins']['get']('RevisionHistoryUtils'),this['set']('activeChange',null),this['set']('activeView',null),this['_activeViewTarget']=null,this['set']('diff',null),this['set']('isReady',!0x1),this['set']('isEnabled',!0x0),this['on']('change:isEnabled',(_0x39608e,_0x44afcb,_0x5c3675)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x205179=>{for(const _0x1b72f9 of this['editor']['editing']['view']['document']['roots'])_0x5c3675?_0x205179['removeClass']('ck-editor__editable__overlay',_0x1b72f9):_0x205179['addClass']('ck-editor__editable__overlay',_0x1b72f9);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x472864=>null!==_0x472864),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x1902f1,_0x32bd1f,_0x188d01)=>_0x1902f1&&_0x188d01?_0x32bd1f['changes']['getIndex'](_0x188d01):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0xd60269,_0x43b1ea)=>_0xd60269?_0x43b1ea['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](et);}['init'](){const _0x117afc=this['editor'],_0x283beb=new ShowChangeCommand(_0x117afc,{'direction':'backward'}),_0x5680a3=new ShowChangeCommand(_0x117afc,{'direction':'forward'});(_0x117afc['commands']['add']('showPreviousChange',_0x283beb),_0x117afc['commands']['add']('showNextChange',_0x5680a3),_0x117afc['commands']['add']('restoreRevision',new RestoreRevisionCommand(_0x117afc)),this['on']('change:numberOfChanges',()=>{_0x283beb['refresh'](),_0x5680a3['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x117afc['enableReadOnlyMode']('revision-viewer'),_0x117afc['plugins']['has']('WidgetToolbarRepository'))&&_0x117afc['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x35ca6d){return await this['_utils']['loadRevisionData'](_0x35ca6d,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x35ca6d);}async['getRevisionRootsAttributes'](_0x3fd282){return await this['_utils']['loadRevisionData'](_0x3fd282,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x3fd282);}async['compare'](_0x510073,_0x56dbae,_0x67bcd1=!0x1){if(!this['isEnabled'])return;const _0x74563c=this['diff'],_0x4ec142=this['repository'],_0x8eb14e='string'==typeof _0x510073?_0x4ec142['getRevision'](_0x510073):_0x510073,_0x538f41='string'==typeof _0x56dbae?_0x4ec142['getRevision'](_0x56dbae):_0x56dbae,_0xd74e25=_0x8eb14e['id'],_0x38e911=_0x538f41?_0x538f41['id']:null;if(!_0x67bcd1&&this['diff']&&this['diff']['newRevisionId']===_0xd74e25&&this['diff']['oldRevisionId']===_0x38e911)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new RevisionDiff(_0xd74e25,_0x38e911);const _0x3d8187=this['_getRevisionsRange'](_0x8eb14e,_0x538f41,!0x0)['map'](_0x4ec14d=>this['_utils']['loadRevisionData'](_0x4ec14d,this['adapter']));return _0x3d8187['push'](new Promise(_0x655a90=>{setTimeout(_0x655a90,0x14);})),Promise['all'](_0x3d8187)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x5454a9=this['_getDiff'](_0xd74e25,_0x38e911);for(const _0x238e9b of _0x5454a9['changes'])this['_changeIdToChange']['set'](_0x238e9b['id'],_0x238e9b);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x37166d=>{for(const _0x4d53b1 of this['editor']['model']['document']['getRootNames']())_0x37166d['detachRoot'](_0x4d53b1);for(const _0x2fd3e0 of Object['keys'](_0x5454a9['model'])){const _0x5856ba=_0x5454a9['model'][_0x2fd3e0]['name'],_0x48fe0f=_0x37166d['addRoot'](_0x2fd3e0,_0x5856ba);for(const _0x40b6d4 of Object['keys'](_0x5454a9['attributes'][_0x2fd3e0]))_0x37166d['setAttribute'](_0x40b6d4,_0x5454a9['attributes'][_0x2fd3e0][_0x40b6d4],_0x48fe0f);_0x37166d['insert'](_0x5454a9['model'][_0x2fd3e0],_0x48fe0f,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x5454a9['changes'])),this['isReady']=!0x0;})['catch'](_0x1f57e3=>{console['error'](_0x1f57e3),this['_cleanUp'](),_0x74563c&&(this['diff']=_0x74563c),this['isReady']=!0x0;});}['addRevisionData'](_0x45835e,_0x25f159){const _0x9c4aca=this['repository']['createRevision'](_0x45835e);return _0x9c4aca['on']('_update',(_0x45df78,_0x376199,_0x3b6947)=>_0x25f159(_0x376199,_0x3b6947,_0x9c4aca)),this['repository']['addRevision'](_0x9c4aca),_0x9c4aca;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x498da7=>{for(const _0x4fafc8 of this['editor']['model']['document']['getRootNames']())_0x498da7['detachRoot'](_0x4fafc8);});}['_sortAndFilterDiffChanges'](_0x3601d6){const _0x38d010=[],_0x1dbab9=new Map();for(const _0x504f05 of this['editor']['model']['document']['getRootNames']()){const _0x4ddebb=this['editor']['editing']['view']['getDomRoot'](_0x504f05);if(!_0x4ddebb)continue;const _0x54e068=_0x4ddebb['getClientRects']()['item'](0x0);_0x54e068&&(_0x38d010['push'](_0x504f05),_0x1dbab9['set'](_0x504f05,_0x54e068));}return _0x38d010['sort']((_0x48d2d0,_0xed31e0)=>{const _0xa36d57=_0x1dbab9['get'](_0x48d2d0),_0x5a5ebd=_0x1dbab9['get'](_0xed31e0);return _0xa36d57['y']-_0x5a5ebd['y']||_0xa36d57['x']-_0x5a5ebd['x'];}),(_0x3601d6=_0x3601d6['filter'](_0x49667e=>_0x38d010['includes'](_0x49667e['rootName'])))['sort']((_0xe13d7c,_0x20857c)=>_0x38d010['indexOf'](_0xe13d7c['rootName'])-_0x38d010['indexOf'](_0x20857c['rootName'])),_0x3601d6;}['_makeTape'](_0x11abe3){const _0x63838f=Array['from'](_0x11abe3['markers'])['filter'](([_0x3d77ed,_0x414d32])=>_0x3d77ed['startsWith']('revision:')&&!_0x414d32['isCollapsed']),_0x19f01f=Array['from'](this['editor']['model']['createRangeIn'](_0x11abe3)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x63838f['length'])for(const _0x45ed1a of _0x19f01f){const [_0x397ec3,_0x2809d0]=_0x63838f[0x0],[,_0x4af740,_0x3f225f]=_0x397ec3['split'](':');if(_0x2809d0['end']['isEqual'](_0x45ed1a['nextPosition'])&&_0x63838f['shift'](),(_0x45ed1a['previousPosition']['isEqual'](_0x2809d0['start'])||_0x45ed1a['previousPosition']['isAfter'](_0x2809d0['start']))&&('insertion'==_0x4af740?_0x45ed1a['isAdded']={'userId':_0x3f225f}:'deletion'==_0x4af740&&(_0x45ed1a['isRemoved']={'userId':_0x3f225f})),0x0==_0x63838f['length'])break;}return _0x19f01f;}['_refreshStartEndIndex'](_0x36375f){const _0x3abcfb=new Map();for(let _0x5e7ae9=0x0;_0x5e7ae9<_0x36375f['length'];_0x5e7ae9++)'text'===_0x36375f[_0x5e7ae9]['type']?(_0x36375f[_0x5e7ae9]['item']['startIndex']=_0x5e7ae9,_0x36375f[_0x5e7ae9]['item']['endIndex']=_0x5e7ae9):('elementStart'===_0x36375f[_0x5e7ae9]['type']?_0x36375f[_0x5e7ae9]['item']['startIndex']=_0x5e7ae9:'elementEnd'===_0x36375f[_0x5e7ae9]['type']&&(_0x36375f[_0x5e7ae9]['item']['endIndex']=_0x5e7ae9),_0x3abcfb['set'](_0x36375f[_0x5e7ae9]['id'],_0x5e7ae9));for(const _0x56c721 of _0x3abcfb['values']())'elementStart'===_0x36375f[_0x56c721]['type']?_0x36375f[_0x56c721]['item']['endIndex']=_0x3abcfb['get'](_0x36375f[_0x56c721]['pairId']):'elementEnd'===_0x36375f[_0x56c721]['type']&&(_0x36375f[_0x56c721]['item']['startIndex']=_0x3abcfb['get'](_0x36375f[_0x56c721]['pairId']));}['_processTape'](_0x4d8de8){for(let _0x34ec0a=0x0;_0x34ec0a<_0x4d8de8['length'];_0x34ec0a++){if('elementStart'===_0x4d8de8[_0x34ec0a]['type'])_0x4d8de8[_0x34ec0a]['item']['startIndex']=_0x34ec0a;else{if('elementEnd'===_0x4d8de8[_0x34ec0a]['type']){_0x4d8de8[_0x34ec0a]['item']['endIndex']=_0x34ec0a;const _0x2de3b3=_0x4d8de8[_0x34ec0a]['item']['startIndex'];_0x4d8de8[_0x2de3b3]['pairId']=_0x4d8de8[_0x34ec0a]['id'],_0x4d8de8[_0x34ec0a]['pairId']=_0x4d8de8[_0x2de3b3]['id'];}else _0x4d8de8[_0x34ec0a]['item']['startIndex']=_0x34ec0a,_0x4d8de8[_0x34ec0a]['item']['endIndex']=_0x34ec0a,_0x4d8de8[_0x34ec0a]['pairId']=null;}_0x4d8de8[_0x34ec0a]['markersStart']||(_0x4d8de8[_0x34ec0a]['markersStart']=[],_0x4d8de8[_0x34ec0a]['markersEnd']=[]);}}['_markInsertions'](_0x4d4b5d,_0x36ff53){const _0x48b14d=_0x4d4b5d['filter'](_0xa0bafd=>!_0xa0bafd['isAdded']);for(let _0x25da61=0x0;_0x25da61<_0x36ff53['length'];_0x25da61++)_0x36ff53[_0x25da61]['isAdded']&&(_0x48b14d[_0x25da61]['isAdded']=_0x36ff53[_0x25da61]['isAdded']);}['_getDiff'](_0x354ae4,_0x4b5dbb=null){const _0x4d22f8=this['repository']['getRevision'](_0x354ae4),_0x35b4cb=_0x4b5dbb?this['repository']['getRevision'](_0x4b5dbb):null,_0x454da0=this['_getRevisionsRange'](_0x4d22f8,_0x35b4cb),_0x4874a8=_0x454da0[_0x454da0['length']-0x1],_0x4b5001=new Map(),_0x2442d8={'model':{},'attributes':{},'changes':[]},_0x714344=new Set(),_0x24cf69=new Map();for(let _0x2bc41a=_0x454da0['length']-0x1;_0x2bc41a>=0x0;_0x2bc41a--){const _0x3a1d55=_0x454da0[_0x2bc41a];for(const _0x3b3914 of Object['keys'](_0x3a1d55['diffData']))if(_0x3a1d55['diffData'][_0x3b3914]['attachChange']){const _0x3dc5de=_0x3a1d55['diffData'][_0x3b3914]['attachChange'];_0x3dc5de['isAttached']?(_0x714344['add'](_0x3b3914),_0x24cf69['has'](_0x3b3914)&&_0x24cf69['get'](_0x3b3914)['userId']==_0x3dc5de['userId']?_0x24cf69['delete'](_0x3b3914):_0x24cf69['set'](_0x3b3914,_0x3dc5de)):_0x24cf69['has'](_0x3b3914)?(_0x714344['delete'](_0x3b3914),_0x24cf69['delete'](_0x3b3914)):(_0x714344['add'](_0x3b3914),_0x24cf69['set'](_0x3b3914,_0x3dc5de));}else _0x714344['add'](_0x3b3914);}for(const _0x2140fb of _0x714344){const _0x311328=_0x24cf69['has'](_0x2140fb)&&!_0x24cf69['get'](_0x2140fb)['isAttached'];let _0x1f2fce=_0x311328?_0x454da0['length']-0x1:0x0;const _0x296360=_0x311328?-0x1:0x1;for(;_0x454da0[_0x1f2fce];){const _0x31fa7e=_0x454da0[_0x1f2fce];if(_0x31fa7e['diffData'][_0x2140fb]){const _0x1046e7=_0x311328?_0x31fa7e['diffData'][_0x2140fb]['attributesBefore']:_0x31fa7e['diffData'][_0x2140fb]['attributesAfter'];_0x2442d8['attributes'][_0x2140fb]=_0x1046e7?_0x531982(_0x1046e7):{};break;}_0x1f2fce+=_0x296360;}}for(const _0x287e14 of _0x454da0){_0x287e14['model']={};for(const _0x559543 of _0x287e14['authors'])_0x4b5001['set'](_0x559543['id'],_0x559543);for(const _0x268536 of _0x714344){const _0x35f2d6=_0x287e14['diffData'][_0x268536]?_0x287e14['diffData'][_0x268536]['insertions']:'[]',_0x295d95=_0x287e14['diffData'][_0x268536]?_0x287e14['diffData'][_0x268536]['deletions']:'[]',_0x5b4c0e=_0x287e14['diffData'][_0x268536]?.['rootElementName']||'$root';_0x287e14['model'][_0x268536]={'insertions':this['_utils']['_makeModelFromViewString'](_0x35f2d6,_0x5b4c0e),'deletions':this['_utils']['_makeModelFromViewString'](_0x295d95,_0x5b4c0e)};}}for(const _0x54a6a4 of _0x714344){let _0x1499c9=null,_0x211841=0x0;const _0x5253ad=_0x454da0['map'](_0xd118f5=>_0xd118f5['diffData'][_0x54a6a4]?.['rootElementName'])['find'](_0x565b0c=>void 0x0!==_0x565b0c)||'$root',_0x27e4bd=new Map(Array['from'](_0x4d22f8['model'][_0x54a6a4]['insertions']['markers'])['filter'](([_0x11f507])=>!_0x11f507['startsWith']('revision:')));let _0x4afa9c=0x0;for(const _0x34ee06 of _0x454da0){const _0x252e3b=this['_makeTape'](_0x34ee06['model'][_0x54a6a4]['insertions']);_0x34ee06==_0x4d22f8?(_0x1499c9=_0x252e3b,_0x211841=_0x1499c9['length'],_0x1499c9['forEach'](_0x1d94b8=>{_0x1d94b8['id']=_0x4afa9c++;}),this['_processTape'](_0x1499c9)):this['_markInsertions'](_0x1499c9,_0x252e3b);const _0x4eb54d=_0x1499c9['filter'](_0x2b5956=>!_0x2b5956['isAdded'])['map'](_0x4ffbdf=>_0x4ffbdf['id']);let _0x23c5c0=0x0;const _0x35faf3=this['_makeTape'](_0x34ee06['model'][_0x54a6a4]['deletions']);_0x35faf3['forEach'](_0x54c510=>{_0x54c510['isRemoved']?_0x54c510['id']=_0x211841++:_0x54c510['id']=_0x4eb54d[_0x23c5c0++];}),this['_processTape'](_0x35faf3),this['_setDistance'](_0x1499c9,'isAdded'),this['_setDistance'](_0x35faf3,'isRemoved'),_0x34ee06==_0x4d22f8&&this['_markMarkers'](_0x1499c9,_0x27e4bd),_0x1499c9=this['_joinTapes'](_0x1499c9,_0x35faf3),this['_refreshStartEndIndex'](_0x1499c9),this['_setDistance'](_0x1499c9,'isRemoved');}_0x1499c9=_0x1499c9['filter'](_0x530397=>!(_0x530397['isAdded']&&_0x530397['isRemoved']));const _0x10d1a5=new Map(_0x4874a8['model'][_0x54a6a4]['deletions']['markers']),_0x322ca0=new Set(_0x27e4bd['keys']());for(const _0x104cfc of _0x10d1a5['keys']())_0x322ca0['delete'](_0x104cfc);this['_markSuggestions'](_0x1499c9,_0x322ca0),this['_fixObsoleteTags'](_0x1499c9),_0x1499c9=this['_removeMissingPairs'](_0x1499c9),_0x1499c9=this['_markMismatchedRemovedTags'](_0x1499c9),_0x1499c9=this['_removeUnsupportedChanges'](_0x1499c9);const {root:_0x121142,changes:_0x42a9fd}=this['_makeModelFromTape'](_0x1499c9,_0x4b5001,_0x54a6a4,_0x5253ad);_0x2442d8['model'][_0x54a6a4]=_0x121142;const _0x508fe2=_0x24cf69['get'](_0x54a6a4);if(_0x508fe2){const _0x52c6b4=_0x4b5001['get'](_0x508fe2['userId']),_0x58d6b4=new ChangeItem({'author':_0x52c6b4,'type':_0x508fe2['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x54a6a4});_0x42a9fd['unshift'](_0x58d6b4),_0x2442d8['attributes'][_0x54a6a4]['revisionHistoryAttachChange']=_0x58d6b4['id'];}_0x2442d8['changes']=_0x2442d8['changes']['concat'](_0x42a9fd);}return _0x2442d8;}['_markMarkers'](_0x1a52a8,_0x2b7e58){for(let _0x59e219=0x0;_0x59e219<_0x1a52a8['length'];_0x59e219++)for(const [_0x214a22,_0x48c6db]of _0x2b7e58)!_0x48c6db['isCollapsed']&&_0x48c6db['start']['isEqual'](_0x1a52a8[_0x59e219]['previousPosition'])&&_0x1a52a8[_0x59e219]['markersStart']['push'](_0x214a22),_0x48c6db['end']['isEqual'](_0x1a52a8[_0x59e219]['nextPosition'])&&_0x1a52a8[_0x59e219]['markersEnd']['push'](_0x214a22);}['_joinTapes'](_0x4cdb65,_0x3d9f0b){let _0x1746e7=[],_0x1a801c=0x0,_0x214fab=0x0;for(;_0x1a801c<_0x4cdb65['length']||_0x214fab<_0x3d9f0b['length'];){const _0x46b4e7=_0x4cdb65[_0x1a801c]||{},_0x16731c=_0x3d9f0b[_0x214fab]||{};if(_0x46b4e7['id']==_0x16731c['id'])_0x1a801c++,_0x214fab++,_0x1746e7['push'](_0x46b4e7);else{if(_0x16731c['isRemoved']&&_0x46b4e7['isAdded']){const {commonTape:_0x53ec21,iEnd:_0x5604c7,jEnd:_0x9f9011}=this['_threeWayMerge'](_0x4cdb65,_0x1a801c,_0x3d9f0b,_0x214fab);_0x1746e7=_0x1746e7['concat'](_0x53ec21),_0x1a801c=_0x5604c7,_0x214fab=_0x9f9011;}else _0x16731c['isRemoved']?(_0x214fab++,_0x1746e7['push'](_0x16731c)):(_0x1a801c++,_0x1746e7['push'](_0x46b4e7));}}return _0x1746e7;}['_markSuggestions'](_0x1d6e33,_0x30c208){const _0x1fcd0d=[];for(let _0x2a5d06=0x0;_0x2a5d06<_0x1d6e33['length'];_0x2a5d06++){for(let _0xa7c797=0x0;_0xa7c797<_0x1d6e33[_0x2a5d06]['markersStart']['length'];_0xa7c797++){const _0x1bb251=_0x1d6e33[_0x2a5d06]['markersStart'][_0xa7c797];if(!_0x30c208['has'](_0x1bb251))continue;const {group:_0xdaed7a,type:_0x175f99,authorId:_0x33dd05}=_0xc75c41(_0x1bb251);'revision-suggestion'!=_0xdaed7a||'insertion'!=_0x175f99&&'deletion'!=_0x175f99||(_0x1fcd0d['unshift']({'type':_0x175f99,'name':_0x1bb251,'userId':_0x33dd05}),_0x1d6e33[_0x2a5d06]['markersStart']['splice'](_0xa7c797,0x1),_0xa7c797--);}_0x9dff67(_0x1d6e33[_0x2a5d06]);for(let _0x5c25be=0x0;_0x5c25be<_0x1d6e33[_0x2a5d06]['markersEnd']['length'];_0x5c25be++){const _0x1d297e=_0x1d6e33[_0x2a5d06]['markersEnd'][_0x5c25be];if(!_0x30c208['has'](_0x1d297e))continue;const {group:_0x51144c,type:_0x5d6f83}=_0xc75c41(_0x1d297e);if('revision-suggestion'!=_0x51144c||'insertion'!=_0x5d6f83&&'deletion'!=_0x5d6f83)continue;_0x1d6e33[_0x2a5d06]['markersEnd']['splice'](_0x5c25be,0x1),_0x5c25be--;const _0x567c66=_0x1fcd0d['findIndex'](_0x1ca64b=>_0x1ca64b['name']==_0x1d297e);_0x567c66>-0x1&&_0x1fcd0d['splice'](_0x567c66,0x1);}}function _0xc75c41(_0x4a495e){const _0x3c87d2=_0x4a495e['split'](':');return{'group':_0x3c87d2[0x0],'type':_0x3c87d2[0x1],'subType':_0x3c87d2['length']>=0x5?_0x3c87d2[0x2]:null,'id':_0x3c87d2['length']<0x5?_0x3c87d2[0x2]:_0x3c87d2[0x3],'authorId':_0x3c87d2['length']<0x5?_0x3c87d2[0x3]:_0x3c87d2[0x4],'markerCount':0x6==_0x3c87d2['length']?_0x3c87d2[0x5]:null};}function _0x9dff67(_0x296f35){for(let _0x5f290b=0x0;_0x5f290b<_0x1fcd0d['length'];_0x5f290b++){if(_0x296f35['isAdded']&&'insertion'==_0x1fcd0d[_0x5f290b]['type']&&_0x296f35['isAdded']['userId']==_0x1fcd0d[_0x5f290b]['userId'])return _0x296f35['isAddSuggestion']=_0x1fcd0d[_0x5f290b],void delete _0x296f35['isAdded'];if(!_0x296f35['isAdded']&&!_0x296f35['isRemoved']&&'deletion'==_0x1fcd0d[_0x5f290b]['type'])return void(_0x296f35['isRemoveSuggestion']=_0x1fcd0d[_0x5f290b]);}}}['_setDistance'](_0x255eee,_0x116d63){let _0x163dc3=0x0,_0x198b6a=!0x1;const _0x5b8db1=new Map();for(const _0x5a152a of _0x255eee)_0x5a152a[_0x116d63]?_0x198b6a&&(_0x163dc3++,_0x198b6a=!0x1):(_0x163dc3++,_0x198b6a=!0x0),_0x5b8db1['set'](_0x5a152a['id'],_0x163dc3);for(let _0x1cbd63=0x0;_0x1cbd63<_0x255eee['length'];_0x1cbd63++){if('isRemoved'==_0x116d63&&_0x255eee[_0x1cbd63]['isAdded']||'isAdded'==_0x116d63&&_0x255eee[_0x1cbd63]['isRemoved'])continue;if('text'==_0x255eee[_0x1cbd63]['type']){_0x255eee[_0x1cbd63]['distance']=0x0;continue;}const _0x3cddae=_0x5b8db1['get'](_0x255eee[_0x1cbd63]['pairId']),_0x11b238=_0x5b8db1['get'](_0x255eee[_0x1cbd63]['id']);_0x255eee[_0x1cbd63]['distance']=_0x3cddae-_0x11b238;}}['_getRevisionsRange'](_0x4fae8c,_0x37fad4,_0x5c3fb4=!0x1){const _0x23f733=[];let _0x811003=this['repository']['getIndex'](_0x4fae8c),_0x5e2a3a=this['repository']['getIndex'](_0x37fad4);for(-0x1==_0x5e2a3a&&(_0x5e2a3a=this['repository']['_revisions']['length'],_0x5c3fb4=!0x1);_0x811003<_0x5e2a3a;)_0x23f733['push'](this['repository']['getRevision'](_0x811003)),_0x811003++;return _0x5c3fb4&&_0x23f733['push'](this['repository']['getRevision'](_0x811003)),_0x23f733;}['_threeWayMerge'](_0x2bbcd4,_0x3de3af,_0x30e862,_0x491e00){const _0x2f0671=this['editor']['model']['schema'];let _0x56c311=_0x3de3af;for(;_0x2bbcd4[_0x56c311]&&_0x2bbcd4[_0x56c311]['isAdded'];)_0x56c311++;let _0x51ed61=_0x491e00;for(;_0x30e862[_0x51ed61]&&_0x30e862[_0x51ed61]['isRemoved'];)_0x51ed61++;_0x261ca0(_0x2bbcd4,_0x3de3af,_0x56c311),_0x261ca0(_0x30e862,_0x491e00,_0x51ed61);const _0x4bf8e9=_0x30e862['slice'](_0x491e00,_0x51ed61)['concat'](_0x2bbcd4['slice'](_0x3de3af,_0x56c311));return _0x4bf8e9['sort']((_0x843709,_0x4cdda2)=>_0x843709['side']!=_0x4cdda2['side']?_0x843709['side']-_0x4cdda2['side']:_0x843709['level']!=_0x4cdda2['level']?_0x843709['level']-_0x4cdda2['level']:_0x843709['distance']!=_0x4cdda2['distance']?_0x4cdda2['distance']-_0x843709['distance']:!!_0x843709['isAdded']!=!!_0x4cdda2['isAdded']?-0x1==_0x843709['side']||0x0==_0x843709['side']?_0x843709['isAdded']?-0x1:0x1:_0x843709['isAdded']?0x1:-0x1:_0x843709['index']-_0x4cdda2['index']),{'commonTape':_0x4bf8e9,'iEnd':_0x56c311,'jEnd':_0x51ed61};function _0x261ca0(_0x20f5f1,_0xc3da9d,_0xa09841){let _0x44e730=-0x1,_0x41db30=Number['POSITIVE_INFINITY'],_0x52b57b=!0x0;for(let _0x5b76b2=_0xc3da9d;_0x5b76b2<_0xa09841;_0x5b76b2++)if(_0x2f0671['isInline'](_0x20f5f1[_0x5b76b2]['item'])||(_0x52b57b=!0x1),_0x20f5f1[_0x5b76b2]['item']['startIndex']<_0xc3da9d&&(_0x44e730=_0x5b76b2),_0x20f5f1[_0x5b76b2]['item']['endIndex']>=_0xa09841){_0x41db30=_0x5b76b2;break;}_0x52b57b&&(_0x44e730=_0xa09841-0x1);for(let _0xfc0447=_0xc3da9d;_0xfc0447<_0xa09841;_0xfc0447++)_0x20f5f1[_0xfc0447]['side']=_0xfc0447<=_0x44e730?-0x1:_0xfc0447<_0x41db30?0x0:0x1,_0x20f5f1[_0xfc0447]['index']=_0xfc0447;let _0x546629=0x0;for(let _0x589fe8=_0xc3da9d;_0x589fe8<=_0x44e730;_0x589fe8++)0x0==_0x20f5f1[_0x589fe8]['distance']?_0x20f5f1[_0x589fe8]['level']=_0x546629:(_0x546629++,_0x20f5f1[_0x589fe8]['level']=_0x546629,_0x546629++);for(let _0x1459bd=_0xc3da9d;_0x1459bd<_0xa09841;_0x1459bd++)0x0==_0x20f5f1[_0x1459bd]['side']&&(_0x20f5f1[_0x1459bd]['level']=_0x546629);_0x546629=0x0;for(let _0xb39797=_0xa09841-0x1;_0xb39797>=_0x41db30;_0xb39797--)0x0==_0x20f5f1[_0xb39797]['distance']?_0x20f5f1[_0xb39797]['level']=_0x546629:(_0x546629--,_0x20f5f1[_0xb39797]['level']=_0x546629,_0x546629--);}}['_fixObsoleteTags'](_0x2d4d4c){const _0x443790=new Map(),_0x4d7be1=this['editor']['model']['schema'];for(let _0x4a1dfd=0x1;_0x4a1dfd<_0x2d4d4c['length'];_0x4a1dfd++){let _0x8002e8,_0x1eae36,_0x6fd57a;const _0x421241=_0x2d4d4c[_0x4a1dfd],_0x591388=_0x2d4d4c[_0x4a1dfd-0x1];if('text'==_0x421241['type'])continue;if(_0x421241['type']!=_0x591388['type'])continue;if(!_0x4d7be1['isBlock'](_0x591388['item'])||_0x4d7be1['isLimit'](_0x591388['item']))continue;if(!_0x4d7be1['isBlock'](_0x421241['item'])||_0x4d7be1['isLimit'](_0x421241['item']))continue;if((_0x2d4d4c[_0x4a1dfd]['isAdded']||_0x2d4d4c[_0x4a1dfd]['isAddSuggestion'])&&_0x2d4d4c[_0x4a1dfd-0x1]['isRemoved'])_0x8002e8=_0x2d4d4c[_0x4a1dfd],_0x1eae36=_0x2d4d4c[_0x4a1dfd-0x1],_0x6fd57a=_0x4a1dfd-0x1;else{if(!_0x2d4d4c[_0x4a1dfd]['isRemoved']||!_0x2d4d4c[_0x4a1dfd-0x1]['isAdded']&&!_0x2d4d4c[_0x4a1dfd-0x1]['isAddSuggestion'])continue;_0x8002e8=_0x2d4d4c[_0x4a1dfd-0x1],_0x1eae36=_0x2d4d4c[_0x4a1dfd],_0x6fd57a=_0x4a1dfd;}const _0x255562=_0x8002e8['level']==_0x1eae36['level'],_0x37b72a=Math['abs'](_0x8002e8['level'])<Math['abs'](_0x1eae36['level'])&&0x0==_0x1eae36['distance'];(_0x255562||_0x37b72a)&&(_0x443790['set'](_0x1eae36['id'],_0x8002e8['id']),_0x2d4d4c['splice'](_0x6fd57a,0x1),_0x4a1dfd--,_0x8002e8['isAdded']=!0x1);}for(let _0x4a0a7b=0x0;_0x4a0a7b<_0x2d4d4c['length'];_0x4a0a7b++)_0x443790['has'](_0x2d4d4c[_0x4a0a7b]['pairId'])&&(_0x2d4d4c[_0x4a0a7b]['pairId']=_0x443790['get'](_0x2d4d4c[_0x4a0a7b]['pairId']));}['_removeMissingPairs'](_0x19a302){const _0x189a03=new Set(_0x19a302['map'](_0x1fd3df=>_0x1fd3df['id']));for(let _0x34d9dd=0x0;_0x34d9dd<_0x19a302['length'];_0x34d9dd++)_0x189a03['has'](_0x19a302[_0x34d9dd]['pairId'])||0x0==_0x19a302[_0x34d9dd]['distance']||(_0x19a302[_0x34d9dd]['isIncorrect']=!0x0);return _0x19a302['filter'](_0x3e3dd0=>!_0x3e3dd0['isIncorrect']);}['_markMismatchedRemovedTags'](_0x18a3dd){const _0x2be8a6=new Set();for(let _0xeb55ef=0x0;_0xeb55ef<_0x18a3dd['length'];_0xeb55ef++){if(_0x2be8a6['has'](_0x18a3dd[_0xeb55ef]['id'])&&_0x18a3dd[_0xeb55ef]['isRemoved']&&(_0x18a3dd[_0xeb55ef]['isIncorrect']=!0x0),_0x18a3dd[_0xeb55ef]['isIncorrect'])continue;if(0x0==_0x18a3dd[_0xeb55ef]['distance'])continue;if('elementStart'!=_0x18a3dd[_0xeb55ef]['type'])continue;if(null==_0x18a3dd[_0xeb55ef]['pairId'])continue;let _0x4d54a1=_0xeb55ef+0x1,_0x1d460e=0x0;for(;_0x18a3dd[_0x4d54a1]['id']!=_0x18a3dd[_0xeb55ef]['pairId'];)'elementStart'==_0x18a3dd[_0x4d54a1]['type']?_0x1d460e++:'elementEnd'==_0x18a3dd[_0x4d54a1]['type']&&_0x1d460e--,_0x4d54a1++;if(0x0!=_0x1d460e){if(_0x18a3dd[_0xeb55ef]['isRemoved'])_0x18a3dd[_0xeb55ef]['isIncorrect']=!0x0;else{for(;_0x4d54a1!=_0xeb55ef;)_0x18a3dd[_0x4d54a1]['isRemoved']&&0x0!=_0x18a3dd[_0x4d54a1]['distance']&&(_0x18a3dd[_0x4d54a1]['isIncorrect']=!0x0,_0x2be8a6['add'](_0x18a3dd[_0x4d54a1]['pairId'])),_0x4d54a1--;}}}return _0x18a3dd['filter'](_0x4fcb34=>!_0x4fcb34['isIncorrect']);}['_removeUnsupportedChanges'](_0x479e35){const _0x4716b6=this['editor']['model']['schema'];for(let _0x599afa=0x0;_0x599afa<_0x479e35['length'];_0x599afa++){if(!(_0x479e35[_0x599afa]['isAdded']||_0x479e35[_0x599afa]['isAddSuggestion']||_0x479e35[_0x599afa]['isRemoved']||_0x479e35[_0x599afa]['isRemoveSuggestion']))continue;if(0x0==_0x479e35[_0x599afa]['distance'])continue;const _0x293ed3=_0x479e35[_0x599afa]['item'];_0x4716b6['isBlock'](_0x293ed3)||_0x4716b6['isLimit'](_0x293ed3)||(_0x479e35[_0x599afa]['isAdded']&&delete _0x479e35[_0x599afa]['isAdded'],_0x479e35[_0x599afa]['isAddSuggestion']&&delete _0x479e35[_0x599afa]['isAddSuggestion'],_0x479e35[_0x599afa]['isRemoveSuggestion']&&delete _0x479e35[_0x599afa]['isRemoveSuggestion'],_0x479e35[_0x599afa]['isRemoved']&&(_0x479e35[_0x599afa]['isIncorrect']=!0x0));}return _0x479e35['filter'](_0x779802=>!_0x779802['isIncorrect']);}['_makeModelFromTape'](_0x36b11b,_0x28f457,_0x5d5804,_0x3bdbdb){const _0x2f4e81=new _0x54af68(),_0x237905=[],_0x597e61=new Map(),_0x45fb40=this['editor']['model'],_0x168b4b=_0x45fb40['schema'],_0x2ede75=[_0x2f4e81],_0x28fe32={},_0x5cc3cf={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};_0x2f4e81['name']=_0x3bdbdb;let _0x2a4966=null;const _0x497cab=[0x0];for(let _0x5745c0=0x0;_0x5745c0<_0x36b11b['length'];_0x5745c0++)if('elementStart'===_0x36b11b[_0x5745c0]['type']){_0x36b11b[_0x5745c0]['previousPosition']=_0x45fb40['createPositionFromPath'](_0x2f4e81,_0x497cab);const _0x29a3e6=new _0x4052b4(_0x36b11b[_0x5745c0]['item']['name'],_0x36b11b[_0x5745c0]['item']['getAttributes']());_0x2ede75[0x0]['_appendChild'](_0x29a3e6),_0x497cab['push'](0x0),_0x2ede75['unshift'](_0x29a3e6),_0x36b11b[_0x5745c0]['nextPosition']=_0x45fb40['createPositionFromPath'](_0x2f4e81,_0x497cab);}else'elementEnd'===_0x36b11b[_0x5745c0]['type']?(_0x2ede75['shift'](),_0x36b11b[_0x5745c0]['previousPosition']=_0x45fb40['createPositionFromPath'](_0x2f4e81,_0x497cab),_0x497cab['pop'](),_0x497cab[_0x497cab['length']-0x1]++,_0x36b11b[_0x5745c0]['nextPosition']=_0x45fb40['createPositionFromPath'](_0x2f4e81,_0x497cab)):(_0x36b11b[_0x5745c0]['previousPosition']=_0x45fb40['createPositionFromPath'](_0x2f4e81,_0x497cab),_0x2a4966?_0x2a4966['_data']+=_0x36b11b[_0x5745c0]['item']['data']:_0x2a4966=new _0x354290(_0x36b11b[_0x5745c0]['item']['data'],_0x36b11b[_0x5745c0]['item']['getAttributes']()),_0x36b11b[_0x5745c0+0x1]&&'text'===_0x36b11b[_0x5745c0+0x1]['type']&&_0x19377f(_0x2a4966,_0x36b11b[_0x5745c0+0x1]['item'])||(_0x2ede75[0x0]['_appendChild'](_0x2a4966),_0x2a4966=null),_0x497cab[_0x497cab['length']-0x1]+=_0x36b11b[_0x5745c0]['item']['offsetSize'],_0x36b11b[_0x5745c0]['nextPosition']=_0x45fb40['createPositionFromPath'](_0x2f4e81,_0x497cab));for(let _0x9cc260=0x0;_0x9cc260<_0x36b11b['length'];_0x9cc260++){const _0x48120d=_0x36b11b[_0x9cc260]['previousPosition'],_0x690a10=_0x36b11b[_0x9cc260]['nextPosition'];for(const _0x5b780f of _0x36b11b[_0x9cc260]['markersStart'])_0x597e61['set'](_0x5b780f,{'start':_0x48120d,'end':null});_0x448fb2('isRemoveSuggestion',_0x9cc260,_0x48120d,_0x690a10),_0x448fb2('isAddSuggestion',_0x9cc260,_0x48120d,_0x690a10),_0x448fb2('isRemoved',_0x9cc260,_0x48120d,_0x690a10),_0x448fb2('isAdded',_0x9cc260,_0x48120d,_0x690a10);for(const _0x204e71 of _0x36b11b[_0x9cc260]['markersEnd']){const _0x30935b=_0x597e61['get'](_0x204e71);_0x30935b?_0x30935b['end']=_0x690a10:_0x597e61['set'](_0x204e71,{'start':_0x690a10,'end':_0x690a10});}}for(const [_0x35e5bd,_0x11305c]of _0x597e61){const _0x563fe5=this['editor']['model']['createRange'](_0x11305c['start'],_0x11305c['end']);_0x2f4e81['markers']['set'](_0x35e5bd,_0x563fe5);}return _0x237905['sort']((_0x4d0100,_0x396778)=>{const _0x4f6d05=_0x2f4e81['markers']['get']('revision:'+_0x4d0100['id']),_0x3e753e=_0x2f4e81['markers']['get']('revision:'+_0x396778['id']);return _0x4f6d05['start']['isBefore'](_0x3e753e['start'])?-0x1:_0x4f6d05['start']['isAfter'](_0x3e753e['start'])?0x1:_0x4f6d05['end']['isBefore'](_0x3e753e['end'])?-0x1:_0x4f6d05['end']['isAfter'](_0x3e753e['end'])?0x1:'add'===_0x4d0100['type']?-0x1:0x1;}),{'root':_0x2f4e81,'changes':_0x237905};function _0x448fb2(_0x173b18,_0x55b6bc,_0x4cc16f,_0x3faadf){const _0x2b1420=!!_0x36b11b[_0x55b6bc][_0x173b18],_0x2f62f2=_0x2b1420?_0x36b11b[_0x55b6bc][_0x173b18]['userId']:null,_0x1e05bd=_0x55b6bc===_0x36b11b['length']-0x1,_0x4af08f=_0x5cc3cf[_0x173b18][0x0],_0x3ec54d=_0x168b4b['isObject'](_0x36b11b[_0x55b6bc]['item']);!_0x28fe32[_0x173b18]&&_0x2b1420?_0x28fe32[_0x173b18]={'start':_0x4cc16f,'tapeItem':_0x36b11b[_0x55b6bc],'userId':_0x2f62f2,'type':_0x173b18}:_0x28fe32[_0x173b18]&&!_0x2b1420?(_0x28fe32[_0x173b18]['end']=_0x4cc16f,_0x56b558(_0x28fe32[_0x173b18]),_0x28fe32[_0x173b18]=null):_0x28fe32[_0x173b18]&&_0x2b1420&&_0x28fe32[_0x173b18]['userId']!==_0x2f62f2&&(_0x28fe32[_0x173b18]['end']=_0x4cc16f,_0x4af08f&&_0x4af08f['userId']===_0x28fe32[_0x173b18]['userId']||_0x56b558(_0x28fe32[_0x173b18]),_0x28fe32[_0x173b18]={'start':_0x4cc16f,'tapeItem':_0x36b11b[_0x55b6bc],'userId':_0x2f62f2,'type':_0x173b18}),_0x28fe32[_0x173b18]&&_0x3ec54d&&('elementStart'!==_0x36b11b[_0x55b6bc]['type']||_0x4af08f&&_0x4af08f['userId']===_0x2f62f2||_0x5cc3cf[_0x173b18]['unshift']({'userId':_0x2f62f2,'object':_0x36b11b[_0x55b6bc]['item'],'change':_0x28fe32[_0x173b18]}),'elementEnd'===_0x36b11b[_0x55b6bc]['type']&&_0x4af08f&&_0x4af08f['object']===_0x36b11b[_0x55b6bc]['item']&&(_0x5cc3cf[_0x173b18]['shift'](),_0x28fe32[_0x173b18]=_0x4af08f['change'])),_0x28fe32[_0x173b18]&&_0x1e05bd&&(_0x28fe32[_0x173b18]['end']=_0x3faadf,_0x56b558(_0x28fe32[_0x173b18]),_0x28fe32[_0x173b18]=null);}function _0x56b558({start:_0x29b660,end:_0x221d45,tapeItem:_0x22fdd1,userId:_0xf986b9,type:_0x59ad}){const _0x48d9c2=_0x22fdd1['item'],_0x3897a5=_0x45fb40['schema']['isBlock'](_0x48d9c2)&&!_0x45fb40['schema']['isLimit'](_0x48d9c2),_0x29670c=_0x29b660['nodeAfter']==_0x221d45['parent']&&_0x221d45['isAtStart'];if(_0x3897a5&&_0x29670c)return;const _0x14e340=_0x45fb40['createRange'](_0x29b660,_0x221d45),_0x1d94ad=_0x28f457['get'](_0xf986b9),_0x102985=new ChangeItem({'author':_0x1d94ad,'type':'isAdded'==_0x59ad||'isAddSuggestion'==_0x59ad?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x59ad||'isRemoveSuggestion'==_0x59ad},'createdAt':new Date(),'rootName':_0x5d5804});_0x237905['push'](_0x102985),_0x2f4e81['markers']['set']('revision:'+_0x102985['id'],_0x14e340);}function _0x19377f(_0x356de3,_0x19f075){const _0x543e22=_0x356de3['getAttributes'](),_0x2fdcc1=_0x19f075['getAttributes']();for(const _0x278ebb of _0x543e22){if(_0x278ebb[0x1]!==_0x19f075['getAttribute'](_0x278ebb[0x0]))return!0x1;_0x2fdcc1['next']();}return _0x2fdcc1['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x3baa12=>{const _0x49a3f0=_0x3baa12['markerName']['split'](':')[0x1],_0x240f05=this['_getChangeFromId'](_0x49a3f0);if(!_0x240f05)return null;const _0x1b4968='add'==_0x240f05['type']?'insertion':'deletion',_0x3c80cb=['ck-suggestion-marker','ck-suggestion-marker-'+_0x1b4968];return _0x240f05['data']['isSuggestion']&&_0x3c80cb['push']('ck-suggestion-marker-'+_0x1b4968+'-new'),this['activeChange']==_0x240f05&&_0x3c80cb['push']('ck-suggestion-marker--active'),{'classes':_0x3c80cb,'attributes':{'data-change-id':_0x49a3f0}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x298d88=>{_0x298d88['on']('element:pre',(_0x4d6ed9,_0xdf650b,_0x3e147d)=>{const _0x4dc136=_0xdf650b['viewItem']['getChild'](0x0);if(!_0x4dc136||!_0x4dc136['is']('element','code'))return;if(!_0x3e147d['consumable']['consume'](_0x4dc136,{'attributes':['vid_start','vid_end']}))return;const _0xb8ca72=_0xdf650b['modelRange']['start']['nodeAfter'];_0x3e147d['writer']['setAttribute']('vid_start',_0x4dc136['getAttribute']('vid_start'),_0xb8ca72),_0x3e147d['writer']['setAttribute']('vid_end',_0x4dc136['getAttribute']('vid_end'),_0xb8ca72);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x59b10a=>{_0x59b10a['on']('element',(_0x746663,_0x4d90db,_0x226b58)=>{if(!_0x226b58['consumable']['consume'](_0x4d90db['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x4d90db['modelRange']['isCollapsed'])return;const _0x46e4e5=_0x4d90db['modelRange']['start']['nodeAfter'];_0x46e4e5['hasAttribute']('vid_start')||_0x46e4e5['hasAttribute']('vid')||(_0x226b58['writer']['setAttribute']('vid_start',_0x4d90db['viewItem']['getAttribute']('vid_start'),_0x46e4e5),_0x226b58['writer']['setAttribute']('vid_end',_0x4d90db['viewItem']['getAttribute']('vid_end'),_0x46e4e5));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x4e9f55=>_0x4e9f55['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x801a79,[,_0x78612c])=>{['vid_start','vid_end','vid']['includes'](_0x78612c)&&(_0x801a79['return']=!0x0,_0x801a79['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x5863d0=>{_0x5863d0['on']('attribute:vid',(_0x1a2b6e,_0x539579,_0x4f59b9)=>{if('\x20'!=_0x539579['item']['data']||_0x539579['item']['parent']['maxOffset']>0x1)return;if(!_0x4f59b9['consumable']['consume'](_0x539579['item'],_0x1a2b6e['name']))return;const _0x3abb1f=_0x4f59b9['writer'],_0x12e68e=_0x4f59b9['mapper']['toViewRange'](_0x539579['range']);_0x3abb1f['wrap'](_0x12e68e,_0x3abb1f['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0xcb31fe){const _0x378e0f=_0xcb31fe['plugins']['get']('RevisionViewer');return(_0x4aa5a8,_0x118288,_0x15aa10)=>{const _0x1c70a1=_0x118288['markerName']['split'](':')[0x1],_0x444722=_0x378e0f['_getChangeFromId'](_0x1c70a1);if(!_0x444722)return null;const _0x1d7823='add'==_0x444722['type']?'split':'merge';if(!_0x15aa10['consumable']['test'](_0x118288['markerRange'],_0x4aa5a8['name']))return;const _0x1aeeb2=_0x118288['markerRange']['getWalker'](),_0x5a5368=_0x118288['markerRange']['start'],_0x263dca=_0xcb31fe['model']['schema'];let _0x1bf1e2=null,_0x494b92=null,_0x468c4e=!0x1,_0x5deedd=!0x1;for(const _0x472a78 of _0x1aeeb2){const _0x247d9e=_0x472a78['item'];_0x468c4e=_0x468c4e||_0x263dca['isContent'](_0x247d9e);const _0x2cd0e2=_0x15aa10['mapper']['toViewElement'](_0x247d9e);if(_0x2cd0e2&&_0x2cd0e2['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x472a78['type']&&(_0x263dca['isBlock'](_0x247d9e)&&!_0x263dca['isLimit'](_0x247d9e)&&(_0x247d9e['nextSibling']||_0x5a5368['isAtEnd']?_0x1bf1e2&&_0x1bf1e2['parent']==_0x247d9e||(_0x1bf1e2=_0x247d9e,_0x519bcb(_0x472a78['previousPosition']),_0x5deedd=!0x0):_0x494b92=_0x494b92||_0x472a78['previousPosition']));}function _0x519bcb(_0xf461ac){const _0x3f9b43=_0x15aa10['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x1d7823}),_0x31ed0b=_0x15aa10['mapper']['toViewPosition'](_0xf461ac);_0x444722['data']['isSuggestion']&&_0x15aa10['writer']['addClass']('ck-suggestion-marker-'+_0x1d7823+'-new',_0x3f9b43),_0x378e0f['activeChange']==_0x444722&&_0x15aa10['writer']['addClass']('ck-suggestion-marker--active',_0x3f9b43),_0x15aa10['writer']['insert'](_0x31ed0b,_0x3f9b43),_0x15aa10['mapper']['bindElementToMarker'](_0x3f9b43,_0x118288['markerName']);}_0x468c4e||_0x5deedd||!_0x494b92||_0x519bcb(_0x494b92);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x2cb00b,_0xc6b23f,_0x2f7304)=>{const _0x3d16b0=_0x2f7304['mapper']['markerNameToElements'](_0xc6b23f['markerName']);if(_0x3d16b0){for(const _0x1cc6d7 of _0x3d16b0)(_0x1cc6d7['hasClass']('ck-suggestion-marker-split')||_0x1cc6d7['hasClass']('ck-suggestion-marker-merge'))&&(_0x2f7304['mapper']['unbindElementFromMarkerName'](_0x1cc6d7,_0xc6b23f['markerName']),_0x2f7304['writer']['remove'](_0x1cc6d7));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x1c9578,_0x3a42ad,_0xab6bcf)=>{const _0x1f2dad=_0x3a42ad['markerName']['split'](':')[0x1],_0x4af67b=this['_getChangeFromId'](_0x1f2dad);if(!_0x4af67b)return null;const _0x341a4c='add'==_0x4af67b['type']?'split':'merge';if(_0xab6bcf['consumable']['test'](_0x3a42ad['markerRange'],_0x1c9578['name']))for(const _0x4924d8 of _0x3a42ad['markerRange']['getItems']()){if(!_0x4924d8['is']('element','softBreak'))continue;const _0x44b871=_0xab6bcf['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x341a4c}),_0x1cd1c7=_0xab6bcf['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x4924d8));_0x4af67b['data']['isSuggestion']&&_0xab6bcf['writer']['addClass']('ck-suggestion-marker-'+_0x341a4c+'-new',_0x44b871),this['activeChange']==_0x4af67b&&_0xab6bcf['writer']['addClass']('ck-suggestion-marker--active',_0x44b871),_0xab6bcf['writer']['insert'](_0x1cd1c7,_0x44b871),_0xab6bcf['mapper']['bindElementToMarker'](_0x44b871,_0x3a42ad['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x3ca6b7=>{for(const _0x2d8a54 of this['editor']['model']['document']['getRootNames']()){const _0x28ffcd=this['editor']['model']['document']['getRoot'](_0x2d8a54),_0x4c434c=this['editor']['editing']['view']['document']['getRoot'](_0x2d8a54);if(_0x4c434c){const _0x131aa2=_0x28ffcd['getAttribute']('revisionHistoryAttachChange');if(_0x3ca6b7['removeAttribute']('data-change-id',_0x4c434c),_0x3ca6b7['removeClass']('ck-revision-history-root-add',_0x4c434c),_0x3ca6b7['removeClass']('ck-revision-history-root-remove',_0x4c434c),_0x3ca6b7['removeClass']('ck-revision-history-root--active',_0x4c434c),_0x131aa2){const _0x3895ca=this['_getChangeFromId'](_0x131aa2);if(!_0x3895ca)return null;_0x3ca6b7['setAttribute']('data-change-id',_0x131aa2,_0x4c434c),_0x3ca6b7['addClass']('ck-revision-history-root-'+_0x3895ca['type'],_0x4c434c),this['activeChange']==_0x3895ca&&_0x3ca6b7['addClass']('ck-revision-history-root--active',_0x4c434c);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0xa772d3=>'revision-comment:'+_0xa772d3,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x302613=>'revision-suggestion:'+_0x302613,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x384d21=>({'name':'suggestion:'+_0x384d21,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x3d12b2=>{const _0x4a43bd=_0x3d12b2['markerName']['split'](':')[0x1];return'insertion'!=_0x4a43bd&&'deletion'!=_0x4a43bd?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x4a43bd]};}}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:deletion',_t(this['editor'],'merge'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:insertion',_t(this['editor'],'split'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision-suggestion',(_0x40594f,_0xad0cb7,_0x481386)=>{const _0x1e9036=_0x481386['mapper']['markerNameToElements'](_0xad0cb7['markerName']);if(_0x1e9036){for(const _0x4c4c21 of _0x1e9036)_0x4c4c21['is']('uiElement')&&(_0x481386['mapper']['unbindElementFromMarkerName'](_0x4c4c21,_0xad0cb7['markerName']),_0x481386['writer']['remove'](_0x4c4c21));}},{'priority':'high'});}['_getChangeFromId'](_0x48de8a){return this['_changeIdToChange']['get'](_0x48de8a);}['_getViewForChange'](_0x1a40d0){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new ChangeDetailsView(this['editor']['locale'],_0x1a40d0),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x5b8068,_0x321146,_0x5785c1,_0x3d8271)=>{_0x3d8271&&this['_balloon']['remove'](_0x3d8271),_0x5785c1&&(this['_balloon']['add']({'view':_0x5785c1,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x1cb870=this['editor']['editing'],_0x130803=this['_getChangeFromId'](_0x5785c1['changeId']);let _0x217e1b;if(_0x130803['data']['isOnRoot']){const _0x259e45=_0x1cb870['view']['getDomRoot'](_0x130803['rootName']);_0x217e1b=Array['from'](_0x259e45['getClientRects']());}else{const _0x3788b6=this['editor']['model']['markers']['get']('revision:'+_0x5785c1['changeId']);_0x217e1b=Array['from'](_0x1cb870['mapper']['markerNameToElements'](_0x3788b6['name']))['map'](_0x2d4a51=>_0x1cb870['view']['domConverter']['mapViewToDom'](_0x2d4a51))['map'](_0x4e2225=>Array['from'](_0x4e2225['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x217e1b[0x0];return _0x217e1b['find'](_0x15179f=>_0x15179f['top']-0x3<=this['_activeViewTarget']['y']&&_0x15179f['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x15179f['left']-0x3<=this['_activeViewTarget']['x']&&_0x15179f['right']+0x3>=this['_activeViewTarget']['x'])||_0x217e1b[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x2d0e4b,_0x3a639f,_0x26247e,_0x452baf)=>{this['activeView']=_0x26247e?this['_getViewForChange'](_0x26247e):null,this['editor']['model']['change'](()=>{const _0x10678b=this['editor']['editing'];_0x452baf&&(_0x452baf['data']['isOnRoot']?_0x10678b['view']['change'](_0x1f6c76=>{_0x1f6c76['removeClass']('ck-revision-history-root--active',_0x10678b['view']['document']['getRoot'](_0x452baf['rootName']));}):_0x10678b['reconvertMarker']('revision:'+_0x452baf['id'])),_0x26247e&&(_0x26247e['data']['isOnRoot']?_0x10678b['view']['change'](_0x50a55e=>{_0x50a55e['addClass']('ck-revision-history-root--active',_0x10678b['view']['document']['getRoot'](_0x26247e['rootName']));}):_0x10678b['reconvertMarker']('revision:'+_0x26247e['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x502f4f,_0x5b8772)=>{if(this['activeChange'])return;const _0x151560=this['_findChangeIdFromDomTarget'](_0x5b8772['target']),_0x49b4f1=this['_changeIdToChange']['get'](_0x151560);_0x49b4f1?(this['_activeViewTarget']={'x':_0x5b8772['domEvent']['x'],'y':_0x5b8772['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x49b4f1)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x226e02,_0x9e8c80)=>{const _0x42465c=this['_findChangeIdFromDomTarget'](_0x9e8c80['target']),_0x5695d6=this['_changeIdToChange']['get'](_0x42465c);_0x5695d6?(this['_activeViewTarget']={'x':_0x9e8c80['domEvent']['x'],'y':_0x9e8c80['domEvent']['y']},_0x5695d6===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x5695d6):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x596d17){do{const _0x3f891c=_0x596d17['getAttribute']('data-change-id');if(_0x3f891c)return _0x3f891c;_0x596d17=_0x596d17['parent'];}while(_0x596d17);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x7f8db8=>{for(const _0x4dcba4 of this['editor']['model']['markers'])_0x7f8db8['removeMarker'](_0x4dcba4);});}}function _t(_0x4cb298,_0x581253){return(_0x3ae655,_0x1a71cd,_0x25c597)=>{if(!_0x25c597['consumable']['test'](_0x1a71cd['markerRange'],_0x3ae655['name']))return;const _0x4786a2=_0x1a71cd['markerRange']['getWalker'](),_0x5ae3de=_0x1a71cd['markerRange']['start'],_0x5b0920=_0x4cb298['model']['schema'];let _0x23efbe=null,_0x5a3942=null,_0x28ad02=!0x1,_0x16bd44=!0x1;for(const _0x4c9566 of _0x4786a2){const _0x27a8ee=_0x4c9566['item'];_0x28ad02=_0x28ad02||_0x5b0920['isContent'](_0x27a8ee);const _0x189e94=_0x25c597['mapper']['toViewElement'](_0x27a8ee);if(_0x189e94&&_0x189e94['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x4c9566['type']&&(_0x5b0920['isBlock'](_0x27a8ee)&&!_0x5b0920['isLimit'](_0x27a8ee)&&(_0x27a8ee['nextSibling']||_0x5ae3de['isAtEnd']?_0x23efbe&&_0x23efbe['parent']==_0x27a8ee||(_0x23efbe=_0x27a8ee,_0x14c0a0(_0x4c9566['previousPosition']),_0x16bd44=!0x0):_0x5a3942=_0x5a3942||_0x4c9566['previousPosition']));}function _0x14c0a0(_0x1eddca){const _0x2a884f=_0x25c597['mapper']['toViewPosition'](_0x1eddca),_0x4b2c29=_0x25c597['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x581253});_0x25c597['writer']['insert'](_0x2a884f,_0x4b2c29),_0x25c597['mapper']['bindElementToMarker'](_0x4b2c29,_0x1a71cd['markerName']);}_0x28ad02||_0x16bd44||!_0x5a3942||_0x14c0a0(_0x5a3942);};}class RestoreRevisionCommand extends _0x323c1f{constructor(_0x3aa5f7){super(_0x3aa5f7);const _0x8247f8=_0x3aa5f7['plugins']['get'](RevisionViewer);this['affectsData']=!0x1,this['listenTo'](_0x8247f8,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x8247f8,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x25f2a1=this['editor'],_0x2b0f27=_0x25f2a1['plugins']['get'](RevisionViewer),_0x2c483c=_0x2b0f27['isReady']?_0x2b0f27['diff']['newRevisionId']:null;_0x25f2a1['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x2c483c);}['refresh'](){const {isReady:_0x5ba73e,isEnabled:_0x333fe0,repository:_0x1e9e7b,diff:_0x2d26e9}=this['editor']['plugins']['get'](RevisionViewer),_0x165c9d=_0x2d26e9&&_0x1e9e7b['getLaterVisibleRevision'](_0x2d26e9['newRevisionId']);this['isEnabled']=_0x5ba73e&&_0x333fe0&&Boolean(_0x165c9d);}}class ShowChangeCommand extends _0x323c1f{['_step'];constructor(_0xf3e6b2,{direction:_0xf94ce2}){super(_0xf3e6b2);const _0x327da8=_0xf3e6b2['plugins']['get'](RevisionViewer);this['affectsData']=!0x1,this['_step']='forward'===_0xf94ce2?0x1:-0x1,this['listenTo'](_0x327da8,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x327da8,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x327da8,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x4a8e2a=this['editor'],_0x39508b=_0x4a8e2a['plugins']['get'](RevisionViewer),{isNavigationMode:_0x37e613,currentChangeNumber:_0x5bba4a}=_0x39508b;let _0x5ec5f2;if(_0x39508b['activeChange']=_0x37e613?_0x39508b['diff']['changes']['get'](_0x5bba4a+this['_step']):_0x39508b['diff']['changes']['first'],_0x39508b['activeChange']['data']['isOnRoot'])_0x5ec5f2=_0x4a8e2a['editing']['view']['getDomRoot'](_0x39508b['activeChange']['rootName']);else{const _0x581151=_0x4a8e2a['model']['markers']['get']('revision:'+_0x39508b['activeChange']['id']);_0x5ec5f2=_0x3ee994(_0x4a8e2a['editing'],_0x581151);}_0x1e751e({'target':_0x5ec5f2,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x473acc,currentChangeNumber:_0x4b9530,numberOfChanges:_0x43be2c,isReady:_0x846367,isEnabled:_0x46bbd9}=this['editor']['plugins']['get'](RevisionViewer);this['isEnabled']=!!(_0x46bbd9&&_0x846367&&_0x43be2c)&&(!_0x473acc||(0x1===this['_step']?_0x4b9530<_0x43be2c-0x1:_0x4b9530>0x0));}}class ChangesNavigationView extends _0xb27066{constructor(_0x34f37e){super(_0x34f37e);const _0x1cbc9e=this['bindTemplate'],_0x2969d0=new _0x1b24ae(_0x34f37e),_0x3424fa=new _0x1b24ae(_0x34f37e);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',(_0xe622c6,_0x576131)=>_0xe622c6&&_0x576131>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x5c1192,_0x12e51b,_0x59c8c8,_0x24b9b2)=>{if(!_0x5c1192)return ft(_0x34f37e,'Loading...');if(!_0x59c8c8)return ft(_0x34f37e,'No\x20changes');const _0x480656=ft(_0x34f37e,'NUMBER_OF_CHANGES',_0x59c8c8);return _0x24b9b2?ft(_0x34f37e,'X_OF_Y_CHANGES',[_0x12e51b+0x1,_0x59c8c8]):_0x480656;}),_0x2969d0['set']({'label':ft(_0x34f37e,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x319b79}),_0x3424fa['set']({'label':ft(_0x34f37e,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x2d3c17}),_0x2969d0['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x3424fa['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x2969d0['on']('execute',()=>this['fire']('execute','backward')),_0x3424fa['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',_0x1cbc9e['if']('_isStatusLabelVisible','ck-hidden',_0x59231e=>!_0x59231e)]},'children':[{'text':_0x1cbc9e['to']('isNavigationMode',_0x461cbf=>_0x461cbf?ft(_0x34f37e,'EDIT_X_OF_Y_REVISIONS')+':\x20':ft(_0x34f37e,'Total')+':\x20')}]},{'text':_0x1cbc9e['to']('_statusText')}]},new st(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x2969d0,_0x3424fa]}]});}}const yt='ck-editor__editable__loading-overlay';class RevisionViewerLoadingOverlay extends _0x4c1791{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x361bbf=this['editor']['editing']['view'];_0x361bbf['change'](_0x4b9712=>{for(const _0x3c0d9a of _0x361bbf['document']['roots'])_0x4b9712['addClass'](yt,_0x3c0d9a);});}['hide'](){const _0xb6ff16=this['editor']['editing']['view'];_0xb6ff16['change'](_0x5aee2f=>{for(const _0x2fe0c0 of _0xb6ff16['document']['roots'])_0x5aee2f['removeClass'](yt,_0x2fe0c0);});}}class RevisionViewerUI extends _0x4c1791{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[RevisionViewer,RevisionViewerLoadingOverlay];}['init'](){const _0x5acb46=this['editor'],_0x6f9529=_0x5acb46['plugins']['get'](RevisionViewer),_0x5911a4=_0x5acb46['plugins']['get'](RevisionViewerLoadingOverlay);_0x5acb46['ui']['componentFactory']['add']('exitToEditing',_0x27ca45=>{const _0x3646f8=new _0x1b24ae(_0x27ca45);return _0x3646f8['set']({'label':ft(_0x27ca45,'Back\x20to\x20editing'),'icon':_0x11cf6a,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x3646f8,'execute',()=>{_0x5acb46['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x3646f8;}),_0x5acb46['ui']['componentFactory']['add']('restoreRevision',_0x3524a8=>{const _0x210f2b=new _0x1b24ae(_0x3524a8);return _0x210f2b['set']({'label':ft(_0x3524a8,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x210f2b['bind']('isEnabled')['to'](_0x5acb46['commands']['get']('restoreRevision')),this['listenTo'](_0x210f2b,'execute',()=>_0x5acb46['execute']('restoreRevision')),_0x210f2b;}),_0x5acb46['ui']['componentFactory']['add']('changesNavigation',_0xfb2b8c=>{const _0x32db19=new ChangesNavigationView(_0xfb2b8c),_0x2f030f=_0x5acb46['commands']['get']('showPreviousChange'),_0x535a28=_0x5acb46['commands']['get']('showNextChange');return _0x32db19['bind']('isBackwardNavigationEnabled')['to'](_0x2f030f,'isEnabled'),_0x32db19['bind']('isForwardNavigationEnabled')['to'](_0x535a28,'isEnabled'),_0x32db19['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x6f9529),this['listenTo'](_0x32db19,'execute',(_0x56fe7b,_0x196295)=>{_0x5acb46['execute']('forward'===_0x196295?'showNextChange':'showPreviousChange');}),_0x32db19;}),_0x5911a4['show'](),_0x6f9529['on']('change:isReady',(_0x3e2977,_0x16e669,_0x5d7930)=>{_0x5d7930?_0x5911a4['hide']():_0x5911a4['show']();});}}class RevisionNameView extends _0x3dc991{['_resizeObserver']=null;constructor(_0x2008eb,_0xea898e){super(_0x2008eb,_0xea898e);const _0x227e56=this['bindTemplate'];this['set']({'label':ft(_0x2008eb,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=ft(_0x2008eb,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x227e56['to']('_tooltipString'),'data-cke-tooltip-position':'s','data-cke-tooltip-class':'ck-tooltip_multi-line'}});}['render'](){super['render'](),this['_resizeObserver']=new _0x3d48f7(this['fieldView']['element'],()=>this['_updateTooltipText']()),this['listenTo'](this['fieldView'],'input',()=>this['_updateTooltipText']());}['destroy'](){super['destroy'](),this['_resizeObserver']&&this['_resizeObserver']['destroy']();}['_updateTooltipText'](){const _0x489e58=this['fieldView']['element'];this['_tooltipString']=_0x489e58['scrollWidth']>_0x489e58['clientWidth']&&_0x489e58['value']||'';}}class RevisionAuthorView extends _0xb27066{constructor(_0x2101a8,_0x1320d3,_0x53ea4a){super(_0x2101a8);const _0x40ecde=new nt();_0x40ecde['set']({'content':_0x591bb9,'viewBox':'0\x200\x2011\x2010'});const _0x158c8f=['ck','ck-revision-history-sidebar__revision-author'];_0x53ea4a&&_0x158c8f['push']('ck-revision-history-sidebar__revision-author_creator');const _0x260845=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':ft(_0x2101a8,_0x53ea4a?'Revision\x20creator':'Revision\x20author')},'children':[_0x40ecde,_0x1320d3['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x158c8f},'children':_0x260845});}}function Rt(_0x2ec855,_0x6e7244){const _0x565ce2=_0x2ec855['bindTemplate'],_0x116b89=_0x2ec855['locale'],_0x425b88=_0xaaea9b(_0x116b89);_0x425b88['panelPosition']='sw';const _0x5a5a4e=function(_0x3fe75e,_0x4c21f1){const _0x35fb47=function(_0x37a6a6,_0x526335){const _0x390633=_0x37a6a6['locale'],_0x4f19d7={'Compare\x20against\x20selected':ft(_0x390633,'Compare\x20against\x20selected'),'Name\x20this\x20revision':ft(_0x390633,'Name\x20this\x20revision'),'Restore\x20this\x20revision':ft(_0x390633,'Restore\x20this\x20revision')};return _0x526335['map'](_0x2669ef=>{const _0x3482f9=_0x4f19d7[_0x2669ef['name']];return _0x3482f9&&_0x3482f9!==_0x2669ef['name']&&(_0x2669ef['name']=_0x3482f9),_0x2669ef;});}(_0x3fe75e,_0x4c21f1),_0x2f0b91=new _0x1224a0();for(const _0x3319fa of _0x35fb47){const _0xfa8f4f={'type':'button','model':new rt({'label':_0x3319fa['name'],'class':_0x3319fa['class'],'withText':!0x0,'role':'menuitem','_action':_0x3319fa['action']})};_0xfa8f4f['model']['bind']('isEnabled')['to'](_0x3fe75e,'isActionsDropdownOpen',_0xa80d9a=>'function'!=typeof _0x3319fa['isEnabled']||(!_0xa80d9a||_0x3319fa['isEnabled'](_0x3fe75e))),_0x2f0b91['add'](_0xfa8f4f);}return _0x2f0b91;}(_0x2ec855,_0x6e7244);return _0x2ec855['bind']('isActionsDropdownOpen')['to'](_0x425b88,'isOpen'),_0x425b88['buttonView']['set']({'label':ft(_0x116b89,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x2b6cdd}),_0x425b88['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x565ce2['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x565ce2['to'](_0x565168=>_0x565168['stopPropagation']())}}),_0x425b88['on']('execute',_0x2b01d7=>{_0x2ec855['isReady']&&'function'==typeof _0x2b01d7['source']['_action']&&_0x2b01d7['source']['_action'](_0x2ec855);}),ot(_0x425b88,_0x5a5a4e,{'role':'menu'}),_0x425b88['listenTo'](_0x2ec855,'change:isActionsDropdownOpen',(_0x3bba49,_0x31ab44,_0x2c1e2e)=>{if(_0x2c1e2e)for(const _0x5b3c0c of _0x425b88['listView']['items']){const _0x5ae243=_0x5b3c0c['children']['first'],_0x388969=_0x6e7244['find'](_0x2a4ea0=>_0x2a4ea0['action']===_0x5ae243['_action'])['isVisible'];_0x5b3c0c['isVisible']=void 0x0===_0x388969||_0x388969(_0x2ec855);}}),_0x425b88;}class RevisionView extends/* #__PURE__ -- @preserve */
|
|
27
|
-
|
|
23
|
+
import{ObservableMixin as _0xf684e0,uid as _0x51ceb2,Collection as _0x3625c9,logWarning as _0x1b67c3,FocusTracker as _0x28ca2c,KeystrokeHandler as _0x2f638f,scrollViewportToShowTarget as _0x4fee1d,ResizeObserver as _0x39f055,ElementReplacer as _0x4acda2,CKEditorError as _0x423177}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x8c5550,set as _0x49f456,unset as _0x1ca3fa,isEqual as _0x5af7ec}from'es-toolkit/compat';import{Plugin as _0x538071,PendingActions as _0x3985ee,Command as _0x3dad1f,ElementApiMixin as _0x26f772,Editor as _0x278490}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x2baa1d,getMarkerDomElement as _0x205b94,ConfirmMixin as _0x1f967d,sanitizeEditorConfig as _0x21c68e}from'@ckeditor/ckeditor5-collaboration-core/dist/index.js';import{ViewContainerElement as _0x20af03,ViewAttributeElement as _0x4babb5,ViewEmptyElement as _0x4ed8f7,ViewRawElement as _0x4e0b8b,ViewUIElement as _0x103961,ViewDocumentFragment as _0x862c9,ViewText as _0x460563,ViewElement as _0x2c71cb,ModelElement as _0x46d26f,ModelRange as _0xa8802c,ModelPosition as _0x10f6fa,ModelDocumentFragment as _0x59fcbe,ModelText as _0x3b5bf9}from'@ckeditor/ckeditor5-engine/dist/index.js';import{IconHistory as _0x5ea9e8,IconChevronUp as _0x37d115,IconChevronDown as _0x27b0d7,IconUndo as _0x2c0af7,IconUser as _0x185391,IconThreeVerticalDots as _0x5379e9}from'@ckeditor/ckeditor5-icons/dist/index.js';import{CssTransitionDisablerMixin as _0x151f05,View as _0xafec90,submitHandler as _0x33eb0a,LabeledFieldView as _0x17e56b,createLabeledInputText as _0x238b41,createDropdown as _0x182132,ListView as _0x44c12a,ListItemView as _0x4582a8,ButtonView as _0x135801,MenuBarMenuView as _0x48deab,MenuBarMenuListView as _0x41b7d1,MenuBarMenuListItemView as tt,MenuBarMenuListItemButtonView as it,ContextualBalloon as et,ToolbarSeparatorView as st,IconView as nt,addListToDropdown as ot,UIModel as rt,EditorUI as at,normalizeToolbarConfig as ht,BoxedEditorUIView as ct,StickyPanelView as lt,ToolbarView as ut,InlineEditableUIView as dt}from'@ckeditor/ckeditor5-ui/dist/index.js';import{DateTime as vt}from'luxon';class Revision extends/* #__PURE__ -- @preserve */
|
|
24
|
+
_0xf684e0(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0xbcc8a2){super(),this['id']=_0xbcc8a2['id']||_0x51ceb2(),this['creator']=_0xbcc8a2['creator']||null,this['authors']=_0xbcc8a2['authors']||[],this['diffData']=_0xbcc8a2['diffData']||null,this['toVersion']=_0xbcc8a2['toVersion']||0x0,this['fromVersion']=_0xbcc8a2['fromVersion']||0x0,this['set']('name',_0xbcc8a2['name']||''),this['set']('createdAt',_0xbcc8a2['createdAt']||new Date()),this['set']('attributes',_0xbcc8a2['attributes']||{});}['setName'](_0x150791){this['_update']({'name':_0x150791});}['setAttribute'](_0x56add3,_0x2547a0){const _0xc5668c=_0x8c5550(this['attributes']);_0x49f456(_0xc5668c,_0x56add3,_0x2547a0),this['_update']({'attributes':_0xc5668c});}['removeAttribute'](_0xe43243){const _0x4e080b=_0x8c5550(this['attributes']);_0x1ca3fa(_0x4e080b,_0xe43243),this['_update']({'attributes':_0x4e080b});}['_update'](_0x32e4e1,_0x2f35a3=!0x1){let _0x3aa059=!0x1;const _0x1da0e1={'id':this['id']},_0x196ba5=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x3e1c76 of _0x196ba5){const _0x39fd51=_0x32e4e1[_0x3e1c76];void 0x0!==_0x39fd51&&_0x39fd51!==this[_0x3e1c76]&&(this[_0x3e1c76]=_0x39fd51,_0x1da0e1[_0x3e1c76]=_0x39fd51,_0x3aa059=!0x0);}_0x3aa059&&(_0x1da0e1['authors']&&(_0x1da0e1['authorsIds']=_0x1da0e1['authors']['map'](_0x583edd=>_0x583edd['id']),delete _0x1da0e1['authors']),this['fire']('_update',_0x1da0e1,_0x2f35a3));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x141b53=>_0x141b53['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class RevisionsRepository extends _0x538071{['_revisions'];static get['requires'](){return[_0x2baa1d];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x2699be){super(_0x2699be),this['_revisions']=new _0x3625c9();}['afterInit'](){!async function(_0x3bb343){const _0x24b7ef=_0x498e7a([0x76,0x73,0x6d,0x4c,0x34,0x54,0x50,0x70,0x75,0x52,0x35,0x33,0x4d,0x6c,0x71,0x53,0x6a,0x32,0x56,0x58,0x77,0x48,0x39,0x6f,0x45,0x41,0x4e,0x38,0x46,0x78,0x4a,0x74,0x47,0x55,0x4f,0x64,0x62,0x44,0x43,0x5a,0x30,0x31,0x69,0x68,0x79,0x66,0x6b,0x42,0x51,0x59,0x36,0x61,0x63,0x67,0x7a,0x37,0x72,0x49,0x65,0x57,0x4b,0x6e]),_0x386ccc=0xeb829,_0x271916=0x359e09b0,_0x56ab77=0x35998260^_0x271916,_0x469276=window[_0x498e7a([0x44,0x61,0x74,0x65])][_0x498e7a([0x6e,0x6f,0x77])](),_0x22c383=_0x3bb343[_0x498e7a([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x1dc45d=new window[(_0x498e7a([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x5ca87b=>{_0x22c383[_0x498e7a([0x6f,0x6e,0x63,0x65])](_0x498e7a([0x72,0x65,0x61,0x64,0x79]),_0x5ca87b);}),_0x2207e8={[_0x498e7a([0x6b,0x74,0x79])]:_0x498e7a([0x45,0x43]),[_0x498e7a([0x75,0x73,0x65])]:_0x498e7a([0x73,0x69,0x67]),[_0x498e7a([0x63,0x72,0x76])]:_0x498e7a([0x50,0x2d,0x32,0x35,0x36]),[_0x498e7a([0x78])]:_0x498e7a([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]),[_0x498e7a([0x79])]:_0x498e7a([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]),[_0x498e7a([0x61,0x6c,0x67])]:_0x498e7a([0x45,0x53,0x32,0x35,0x36])},_0x2d9ff2=_0x22c383[_0x498e7a([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x498e7a([0x67,0x65,0x74])](_0x498e7a([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x28fbe8(){let _0x50f855,_0x5c6019=null,_0x3aaf94=null;try{if(_0x2d9ff2==_0x498e7a([0x47,0x50,0x4c]))return _0x498e7a([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x50f855=_0x25327a(),!_0x50f855)return _0x498e7a([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x50f855[_0x498e7a([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x3aaf94=_0x42fd34(_0x50f855[_0x498e7a([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x50f855[_0x498e7a([0x6a,0x74,0x69])])),await _0x381c2f()?_0x144643()?_0x11b6ce()?_0x498e7a([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x10bf9b()?(_0x50f855[_0x498e7a([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x498e7a([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x5c6019=_0x4ab8b8(_0x498e7a([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),await _0x52fbb8()):_0x498e7a([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x498e7a([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x498e7a([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x498e7a([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x11b6ce(){const _0x3b6d21=[_0x498e7a([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x498e7a([0x74,0x72,0x69,0x61,0x6c])][_0x498e7a([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x50f855[_0x498e7a([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x469276/0x3e8:0xe10*_0x56ab77;return _0x50f855[_0x498e7a([0x65,0x78,0x70])]<_0x3b6d21;}function _0x144643(){const _0x445867=_0x50f855[_0x498e7a([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x445867)return!0x1;if(_0x445867[_0x498e7a([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x498e7a([0x2a])))return!0x0;if(_0x445867[_0x498e7a([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x498e7a([0x52,0x48])))return!0x0;if(_0x445867[_0x498e7a([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x498e7a([0x52,0x52,0x48]))){if(_0x298ef9())return!0x0;if(_0x597463()||_0x5a5a99())return!0x0;}return!0x1;}function _0x10bf9b(){const _0x3f5bd4=_0x50f855[_0x498e7a([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x3f5bd4||0x0==_0x3f5bd4[_0x498e7a([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x1c290c}=new URL(window[_0x498e7a([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x3f5bd4[_0x498e7a([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x1c290c))return!0x0;const _0x3d836c=_0x1c290c[_0x498e7a([0x73,0x70,0x6c,0x69,0x74])](_0x498e7a([0x2e]));return _0x3f5bd4[_0x498e7a([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x23fc64=>_0x23fc64[_0x498e7a([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x498e7a([0x2a])))[_0x498e7a([0x6d,0x61,0x70])](_0x3db965=>_0x3db965[_0x498e7a([0x73,0x70,0x6c,0x69,0x74])](_0x498e7a([0x2e])))[_0x498e7a([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x465372=>_0x465372[_0x498e7a([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x3d836c[_0x498e7a([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x498e7a([0x6d,0x61,0x70])](_0xfaa118=>Array(_0x3d836c[_0x498e7a([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0xfaa118[_0x498e7a([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x498e7a([0x66,0x69,0x6c,0x6c])](_0xfaa118[0x0]===_0x498e7a([0x2a])?_0x498e7a([0x2a]):'')[_0x498e7a([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0xfaa118))[_0x498e7a([0x73,0x6f,0x6d,0x65])](_0x2fbc2d=>_0x3d836c[_0x498e7a([0x65,0x76,0x65,0x72,0x79])]((_0x281b5c,_0x353512)=>_0x2fbc2d[_0x353512]===_0x281b5c||_0x2fbc2d[_0x353512]===_0x498e7a([0x2a])));}function _0x52fbb8(){return _0x5c6019&&_0x3aaf94?new window[(_0x498e7a([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x2c8092,_0x2c4e83)=>{_0x5c6019[_0x498e7a([0x74,0x68,0x65,0x6e])](_0x2c8092,_0x2c4e83),_0x3aaf94[_0x498e7a([0x74,0x68,0x65,0x6e])](_0x54a092=>{_0x54a092!=_0x498e7a([0x56,0x61,0x6c,0x69,0x64])&&_0x2c8092(_0x54a092);},_0x2c4e83);}):_0x5c6019||_0x3aaf94||_0x498e7a([0x56,0x61,0x6c,0x69,0x64]);}}function _0x42fd34(_0x3b4a9a,_0x1b455b){return new window[(_0x498e7a([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x408fcb=>{if(_0x455e26())return _0x408fcb(_0x498e7a([0x56,0x61,0x6c,0x69,0x64]));_0x349ac3(),_0x22c383[_0x498e7a([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x498e7a([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x4444fd=!0x1;const _0x17b2e1=_0x51ceb2();function _0xf67011(_0x56bcaf){return!!_0x56bcaf&&(typeof _0x56bcaf===_0x498e7a([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x56bcaf===_0x498e7a([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x56bcaf[_0x498e7a([0x74,0x68,0x65,0x6e])]===_0x498e7a([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x56bcaf[_0x498e7a([0x63,0x61,0x74,0x63,0x68])]===_0x498e7a([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x1f25df(_0xd10a06){_0x49d510(_0xd10a06)[_0x498e7a([0x74,0x68,0x65,0x6e])](_0x1c1eab=>{if(!_0x1c1eab||_0x1c1eab[_0x498e7a([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x498e7a([0x6f,0x6b]))return _0x498e7a([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0xa8a720(_0x2a726d(_0x17b2e1+_0x1b455b))!=_0x1c1eab[_0x498e7a([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x498e7a([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x498e7a([0x56,0x61,0x6c,0x69,0x64]);})[_0x498e7a([0x74,0x68,0x65,0x6e])](_0x1a5d91=>(_0x3d1e72(),_0x1a5d91),()=>{const _0x268a52=_0x509a51();return null==_0x268a52?(_0x3d1e72(),_0x498e7a([0x56,0x61,0x6c,0x69,0x64])):_0x498e7a(_0x469276-_0x268a52>(0x11928db0^_0x271916)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x498e7a([0x74,0x68,0x65,0x6e])](_0x408fcb)[_0x498e7a([0x63,0x61,0x74,0x63,0x68])](()=>{_0x408fcb(_0x498e7a([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x4315b5=0x35a8e730^_0x271916;function _0x3d1e72(){const _0x2f7578=_0x498e7a([0x6c,0x6c,0x63,0x74,0x2d])+_0xa8a720(_0x2a726d(_0x3b4a9a)),_0x3d93a1=_0x2a1fd5(_0xa8a720(window[_0x498e7a([0x4d,0x61,0x74,0x68])][_0x498e7a([0x63,0x65,0x69,0x6c])](_0x469276/_0x4315b5)));window[_0x498e7a([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x498e7a([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x2f7578,_0x3d93a1);}function _0x509a51(){const _0x767272=_0x498e7a([0x6c,0x6c,0x63,0x74,0x2d])+_0xa8a720(_0x2a726d(_0x3b4a9a)),_0x3604b4=window[_0x498e7a([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x498e7a([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x767272);return _0x3604b4?window[_0x498e7a([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x2a1fd5(_0x3604b4),0x10)*_0x4315b5:null;}function _0x49d510(_0x97052){return new window[(_0x498e7a([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x55f76a,_0x9feba4)=>{_0x97052[_0x498e7a([0x74,0x68,0x65,0x6e])](_0x55f76a,_0x9feba4),window[_0x498e7a([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x9feba4,0x359fdd70^_0x271916);});}}_0x22c383[_0x498e7a([0x6f,0x6e])](_0x498e7a([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x4e4a82,_0x246c43)=>{if(_0x246c43[0x0]!=_0x3b4a9a)return _0x408fcb(_0x498e7a([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x246c43[0x1]={..._0x246c43[0x1],[_0x498e7a([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x17b2e1};},{[_0x498e7a([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x498e7a([0x68,0x69,0x67,0x68])}),_0x22c383[_0x498e7a([0x6f,0x6e])](_0x498e7a([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x309642=>{_0xf67011(_0x309642[_0x498e7a([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x4444fd=!0x0,_0x1f25df(_0x309642[_0x498e7a([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x498e7a([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x498e7a([0x6c,0x6f,0x77])}),_0x1dc45d[_0x498e7a([0x74,0x68,0x65,0x6e])](()=>{_0x4444fd||_0x408fcb(_0x498e7a([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x455e26(){return _0x22c383[_0x498e7a([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x498e7a([0x76,0x69,0x65,0x77])][_0x498e7a([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x498e7a([0x61,0x75,0x74,0x6f]);}function _0x349ac3(){_0x22c383[_0x498e7a([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x498e7a([0x76,0x69,0x65,0x77])][_0x498e7a([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x498e7a([0x61,0x75,0x74,0x6f]);}}function _0x4ab8b8(_0x3ec652){const _0x327053=[new window[(_0x498e7a([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x1bc0cb=>setTimeout(_0x1bc0cb,0x3597377c^_0x271916)),_0x1dc45d[_0x498e7a([0x74,0x68,0x65,0x6e])](()=>new window[(_0x498e7a([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2ef61f=>{const _0x49d176=0x359e09b7^_0x271916,_0x23492b=_0x3bb343[_0x498e7a([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x300ae6(){_0x23492b[_0x498e7a([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x49d176&&_0x2ef61f();}_0x300ae6(),_0x23492b[_0x498e7a([0x6f,0x6e])](_0x498e7a([0x61,0x64,0x64]),_0x300ae6);})),new window[(_0x498e7a([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x4d327f=>{function _0x4c9491(){for(const _0x3432cc in window)if(window[_0x498e7a([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x498e7a([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x3432cc))&&window[_0x3432cc]==_0x386ccc)return _0x4d327f();_0x22c383[_0x498e7a([0x73,0x74,0x61,0x74,0x65])]!=_0x498e7a([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x498e7a([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x4c9491,0x359e1a38^_0x271916);}_0x3d3cf9(_0x498e7a([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x4c9491();})];return window[_0x498e7a([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x498e7a([0x72,0x61,0x63,0x65])](_0x327053)[_0x498e7a([0x74,0x68,0x65,0x6e])](()=>_0x3ec652);}async function _0xea7be2(){if(await _0x1dc45d,_0x3d3cf9(_0x498e7a([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x5e969f=_0x3bb343[_0x498e7a([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x25398c=_0x3bb343[_0x498e7a([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])](_0x5e969f[_0x498e7a([0x69,0x64])]),_0x19495b=_0x45cdde(_0x498e7a([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x19495b[_0x498e7a([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x5e969f['id'],_0x25398c?_0x25398c['id']:null,!0x0),_0x19495b[_0x498e7a([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x498e7a([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x19495b[_0x498e7a([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x19495b[_0x498e7a([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x516f48,void(_0x19495b[_0x498e7a([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x516f48);}if(_0x3d3cf9(_0x498e7a([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x4308be=_0x45cdde(_0x498e7a([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x4308be[_0x498e7a([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x498e7a([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x4308be[_0x498e7a([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x4308be[_0x498e7a([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x516f48,_0x4308be[_0x498e7a([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x516f48;}_0x22c383[_0x498e7a([0x6d,0x6f,0x64,0x65,0x6c])][_0x498e7a([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x516f48,_0x22c383[_0x498e7a([0x6d,0x6f,0x64,0x65,0x6c])][_0x498e7a([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x516f48,_0x22c383[_0x498e7a([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x498e7a([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x298ef9(){return _0x3d3cf9(_0x498e7a([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x45cdde(_0x498e7a([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x498e7a([0x73,0x74,0x61,0x74,0x65])]==_0x498e7a([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x597463(){return _0x3d3cf9(_0x498e7a([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 _0x5a5a99(){return _0x3d3cf9(_0x498e7a([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x3e6a63(_0x42b122){const _0x4246bb=_0x25e5aa();_0x22c383[_0x4246bb]=_0x498e7a([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])+_0x42b122,_0x42b122[_0x498e7a([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x498e7a([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x25e5aa()]=_0x386ccc),_0x42b122!=_0x498e7a([0x56,0x61,0x6c,0x69,0x64])&&_0xea7be2();}function _0x25e5aa(){const _0x4da422=window[_0x498e7a([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x498e7a([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x498e7a([0x6e,0x6f,0x77])]())[_0x498e7a([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x498e7a([0x2e]),'');let _0x4ed06c=_0x498e7a([0x76]);for(let _0x5c6f64=0x0;_0x5c6f64<_0x4da422[_0x498e7a([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x5c6f64+=0x2){let _0x94c79a=window[_0x498e7a([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x4da422[_0x498e7a([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x5c6f64,_0x5c6f64+0x2));_0x94c79a>=_0x24b7ef[_0x498e7a([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x94c79a-=_0x24b7ef[_0x498e7a([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x4ed06c+=_0x24b7ef[_0x94c79a];}return _0x4ed06c;}function _0x25327a(){const _0x3356ce=_0x2d9ff2[_0x498e7a([0x73,0x70,0x6c,0x69,0x74])](_0x498e7a([0x2e]));if(0x3!=_0x3356ce[_0x498e7a([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x5b583f(_0x3356ce[0x1]);function _0x5b583f(_0x572e73){const _0x408f68=_0x43a3a7(_0x572e73);return _0x408f68&&_0x4641ab()?_0x408f68:null;function _0x4641ab(){const _0x206313=_0x408f68[_0x498e7a([0x6a,0x74,0x69])],_0x30805e=window[_0x498e7a([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x206313[_0x498e7a([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x206313[_0x498e7a([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0xdcd8c5={..._0x408f68,[_0x498e7a([0x6a,0x74,0x69])]:_0x206313[_0x498e7a([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x206313[_0x498e7a([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0xdcd8c5[_0x498e7a([0x76,0x63])],_0x2a726d(_0xdcd8c5)==_0x30805e;}}}async function _0x381c2f(){let _0x3f4276=!0x0;try{const _0x3d890e=_0x2d9ff2[_0x498e7a([0x73,0x70,0x6c,0x69,0x74])](_0x498e7a([0x2e])),[_0x1618fe,_0x158d8f,_0x5b1bb3]=_0x3d890e;return _0x2f71a6(_0x1618fe),await _0x24dedc(_0x1618fe,_0x158d8f,_0x5b1bb3),_0x3f4276;}catch{return!0x1;}function _0x2f71a6(_0x3dfe4b){const _0x4bd4d5=_0x43a3a7(_0x3dfe4b);_0x4bd4d5&&_0x4bd4d5[_0x498e7a([0x61,0x6c,0x67])]==_0x498e7a([0x45,0x53,0x32,0x35,0x36])||(_0x3f4276=!0x1);}async function _0x24dedc(_0x387599,_0x3d80b8,_0x42102f){const _0xf2d3c8=window[_0x498e7a([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x498e7a([0x66,0x72,0x6f,0x6d])](_0x297178(_0x42102f),_0x4c2cb3=>_0x4c2cb3[_0x498e7a([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x1293ac=new window[(_0x498e7a([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x498e7a([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x387599+_0x498e7a([0x2e])+_0x3d80b8),_0x15dbb8=window[_0x498e7a([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x498e7a([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x15dbb8)return;const _0x150a72=await _0x15dbb8[_0x498e7a([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x498e7a([0x6a,0x77,0x6b]),_0x2207e8,{[_0x498e7a([0x6e,0x61,0x6d,0x65])]:_0x498e7a([0x45,0x43,0x44,0x53,0x41]),[_0x498e7a([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x498e7a([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x498e7a([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x15dbb8[_0x498e7a([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x498e7a([0x6e,0x61,0x6d,0x65])]:_0x498e7a([0x45,0x43,0x44,0x53,0x41]),[_0x498e7a([0x68,0x61,0x73,0x68])]:{[_0x498e7a([0x6e,0x61,0x6d,0x65])]:_0x498e7a([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x150a72,_0xf2d3c8,_0x1293ac)||(_0x3f4276=!0x1);}}function _0x43a3a7(_0x3f5026){return _0x3f5026[_0x498e7a([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x498e7a([0x65,0x79]))?JSON[_0x498e7a([0x70,0x61,0x72,0x73,0x65])](_0x297178(_0x3f5026)):null;}function _0x297178(_0x97576f){return window[_0x498e7a([0x61,0x74,0x6f,0x62])](_0x97576f[_0x498e7a([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x498e7a([0x2b]))[_0x498e7a([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x498e7a([0x2f])));}function _0x2a726d(_0x1ba69b){let _0x5a6c57=0x1505;function _0x427c53(_0x3bb3df){for(let _0x53f346=0x0;_0x53f346<_0x3bb3df[_0x498e7a([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x53f346++){const _0x2185e9=_0x3bb3df[_0x498e7a([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x53f346);_0x5a6c57=(_0x5a6c57<<0x5)+_0x5a6c57+_0x2185e9,_0x5a6c57&=_0x5a6c57;}}function _0x378de7(_0x57f8a9){Array[_0x498e7a([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x57f8a9)?_0x57f8a9[_0x498e7a([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x378de7):_0x57f8a9&&typeof _0x57f8a9==_0x498e7a([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x498e7a([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x57f8a9)[_0x498e7a([0x73,0x6f,0x72,0x74])]()[_0x498e7a([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x4a986a,_0x3b15a4])=>{_0x427c53(_0x4a986a),_0x378de7(_0x3b15a4);}):_0x427c53(window[_0x498e7a([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x57f8a9));}return _0x378de7(_0x1ba69b),_0x5a6c57>>>0x0;}function _0xa8a720(_0x2eb342){return _0x2eb342[_0x498e7a([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x498e7a([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x498e7a([0x30]));}function _0x2a1fd5(_0x3712d3){return _0x3712d3[_0x498e7a([0x73,0x70,0x6c,0x69,0x74])]('')[_0x498e7a([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x498e7a([0x6a,0x6f,0x69,0x6e])]('');}function _0x3d3cf9(_0x1984df){return _0x22c383[_0x498e7a([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x498e7a([0x68,0x61,0x73])](_0x1984df);}function _0x45cdde(_0x22d666){return _0x22c383[_0x498e7a([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x498e7a([0x67,0x65,0x74])](_0x22d666);}function _0x516f48(){}function _0x498e7a(_0x229300){return _0x229300['map'](_0xf2c0cb=>String['fromCharCode'](_0xf2c0cb))['join']('');}_0x3e6a63(await _0x28fbe8());}(this);}['createRevision'](_0xad21c6){const _0x19b9b2=this['editor']['plugins']['get']('Users');return new Revision({'id':_0xad21c6['id'],'name':_0xad21c6['name'],'creator':_0xad21c6['creatorId']?_0x19b9b2['getUser'](_0xad21c6['creatorId']):null,'diffData':_0xad21c6['diffData']||_0xad21c6['data'],'authors':_0xad21c6['authorsIds']['map'](_0x290311=>_0x19b9b2['getUser'](_0x290311)),'createdAt':new Date(_0xad21c6['createdAt']),'attributes':_0xad21c6['attributes'],'fromVersion':_0xad21c6['fromVersion'],'toVersion':_0xad21c6['toVersion']});}['addRevision'](_0x5006e4,_0x2d4031=0x0){this['_revisions']['add'](_0x5006e4,_0x2d4031);}['getRevision'](_0xfef6e2){return this['_revisions']['get'](_0xfef6e2);}['getRevisions'](_0x5eac0b={'toJSON':!0x1}){const _0x5734b4=Array['from'](this['_revisions']);return _0x5734b4['reverse'](),_0x5eac0b['toJSON']?_0x5734b4['map'](_0x18b5e7=>_0x18b5e7['toJSON']()):_0x5734b4;}['getIndex'](_0x14352f){return this['_revisions']['getIndex'](_0x14352f);}['getEarlierVisibleRevision'](_0x33ed78){const [,_0x5c2b]=this['getRevisionsIterator'](_0x33ed78,{'direction':'earlier'});return _0x5c2b;}['getLaterVisibleRevision'](_0x456a10){const [,_0x563eed]=this['getRevisionsIterator'](_0x456a10,{'direction':'later'});return _0x563eed;}['getRevisionsInDiff'](_0x467eaf){const _0x1a6098=[];for(const _0x1112ab of this['getRevisionsIterator'](_0x467eaf['newRevisionId']))if(_0x1a6098['push'](_0x1112ab),_0x1112ab['id']===_0x467eaf['oldRevisionId'])break;return _0x1a6098;}*['getRevisionsIterator'](_0x2f8983,{direction:_0x338a9f='earlier',filter:_0x2369f2=()=>!0x0}={}){const _0x3172ed='earlier'===_0x338a9f?0x1:-0x1;let _0x842a40=this['_revisions']['get'](_0x2f8983),_0x58e3c6=this['getIndex'](_0x842a40);for(yield _0x842a40;_0x842a40;){if(_0x58e3c6+=_0x3172ed,_0x842a40=this['getRevision'](_0x58e3c6),!_0x842a40)return;_0x2369f2(_0x842a40)&&(yield _0x842a40);}}}class RevisionHistoryUtils extends _0x538071{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x20af03,'c'],[_0x4babb5,'a'],[_0x4ed8f7,'e'],[_0x4e0b8b,'r'],[_0x103961,'u']]);['_typeCharToViewClass']=new Map([['c',_0x20af03],['a',_0x4babb5],['e',_0x4ed8f7],['r',_0x4e0b8b],['u',_0x103961]]);async['loadRevisionData'](_0x55c3e4,_0x4e0463){if(_0x55c3e4['diffData']||!_0x4e0463)return;const _0x2fd230=this['editor']['config']['get']('collaboration.channelId'),_0x152e2b=await _0x4e0463['getRevision']({'channelId':_0x2fd230,'revisionId':_0x55c3e4['id']});_0x55c3e4['diffData']=_0x152e2b['diffData'];}['getRevisionDocumentData'](_0x50a1f8){const _0x57ea1a={};for(const _0x3f01c0 in _0x50a1f8['diffData']){if(_0x50a1f8['diffData'][_0x3f01c0]['attachChange']&&!_0x50a1f8['diffData'][_0x3f01c0]['attachChange']['isAttached'])continue;const _0x2999e0=this['_removeRevisionMarkers'](JSON['parse'](_0x50a1f8['diffData'][_0x3f01c0]['insertions'])),_0x3de638=this['editor']['editing']['view']['document'],_0x175dd8=new _0x862c9(_0x3de638,_0x2999e0['map'](_0x37287f=>this['_getViewFromDiffObj'](_0x37287f,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x57ea1a[_0x3f01c0]=this['editor']['data']['processor']['toData'](_0x175dd8),this['editor']['data']['processor']['useFillerType']('default');}return _0x57ea1a;}['getRevisionRootsAttributes'](_0x44dd12){const _0x5f3947={};for(const _0x5dfbea in _0x44dd12['diffData'])_0x44dd12['diffData'][_0x5dfbea]['attachChange']&&!_0x44dd12['diffData'][_0x5dfbea]['attachChange']['isAttached']||(_0x5f3947[_0x5dfbea]=_0x44dd12['diffData'][_0x5dfbea]['attributesAfter']||{});return _0x5f3947;}['getRevisionRootsModelElements'](_0x4846cf){const _0x4470d3={};for(const _0x1c80d6 in _0x4846cf['diffData']){if(_0x4846cf['diffData'][_0x1c80d6]['attachChange']&&!_0x4846cf['diffData'][_0x1c80d6]['attachChange']['isAttached'])continue;const _0x3b78c7=_0x4846cf['diffData'][_0x1c80d6]['rootElementName'];_0x3b78c7&&(_0x4470d3[_0x1c80d6]=_0x3b78c7);}return _0x4470d3;}['_getTypeCharForViewElement'](_0x6d4805){return this['_viewClassToTypeChar']['get'](_0x6d4805['constructor']);}['_getViewFromDiffObj'](_0x4c3c4e,_0x5b7304){const _0x1f8ab5=this['editor']['editing']['view']['document'];if('string'==typeof _0x4c3c4e)return new _0x460563(_0x1f8ab5,_0x4c3c4e);{let _0xc2e5d2,_0x22dec4;_0x22dec4='u'==_0x4c3c4e['type']||'r'==_0x4c3c4e['type']?[]:_0x4c3c4e['children']['map'](_0x16b42a=>this['_getViewFromDiffObj'](_0x16b42a,_0x5b7304));const _0x3d2e01=this['_typeCharToViewClass']['get'](_0x4c3c4e['type'])||_0x2c71cb,_0x5286af=this['editor']['data']['htmlProcessor']['domConverter'];if(_0xc2e5d2=new _0x3d2e01(_0x1f8ab5,_0x4c3c4e['name'],_0x4c3c4e['attributes'],_0x22dec4),'u'==_0x4c3c4e['type']&&_0x4c3c4e['children'][0x0]){const _0x75d162=_0x4c3c4e['children'][0x0];if(_0xc2e5d2['render']=function(_0x2124e0){const _0x51d014=_0x2124e0['createElement']('div');return _0x51d014['innerHTML']=_0x75d162,_0x51d014['childNodes'][0x0];},_0x5b7304){const _0x37128c=new _0x862c9(_0x1f8ab5);_0x37128c['_appendChild'](_0xc2e5d2);const _0x56982d=Array['from'](_0x5286af['viewChildrenToDom'](_0x37128c,{'bind':!0x1})),_0x39f4ea=_0x5286af['domDocument']['createElement']('div');_0x39f4ea['append'](..._0x56982d),_0xc2e5d2=Array['from'](_0x5286af['domChildrenToView'](_0x39f4ea))[0x0];}}else{if('r'==_0x4c3c4e['type']&&_0x4c3c4e['children'][0x0]){const _0xd5359f=_0x4c3c4e['children'][0x0];if(_0xc2e5d2['render']=function(_0x492940){_0x492940['innerHTML']=_0xd5359f;},_0x5b7304){const _0xf5df63=new _0x862c9(_0x1f8ab5);_0xf5df63['_appendChild'](_0xc2e5d2);const _0x25a64b=Array['from'](_0x5286af['viewChildrenToDom'](_0xf5df63,{'bind':!0x1})),_0x5c5401=_0x5286af['domDocument']['createElement']('div');_0x5c5401['append'](..._0x25a64b);const _0xb2048=Array['from'](_0x5286af['domChildrenToView'](_0x5c5401));_0xb2048['length']>0x1?_0xc2e5d2['_appendChild'](_0xb2048):_0xc2e5d2=_0xb2048[0x0];}}}if(_0x4c3c4e['customProperties']){for(const [_0x84ff7e,_0x110a01]of _0x4c3c4e['customProperties'])_0xc2e5d2['_setCustomProperty'](_0x84ff7e,_0x110a01);}const _0x4405d9=void 0x0===_0x4c3c4e['fillerOffset']?null:_0x4c3c4e['fillerOffset'];return null!==_0x4405d9&&(_0xc2e5d2['getFillerOffset']=()=>_0x4405d9),_0xc2e5d2;}}['_makeModelFromViewString'](_0x2c588e,_0x5a223f){const _0x17d549=JSON['parse'](_0x2c588e),_0x5814ca=this['editor']['editing']['view']['document'],_0x212b7b=new _0x862c9(_0x5814ca,_0x17d549['map'](_0x3b75cc=>this['_getViewFromDiffObj'](_0x3b75cc,!0x0))),_0x42430d=this['editor']['data']['toModel'](_0x212b7b,_0x5a223f);return _0x42430d['name']=_0x5a223f,_0x42430d;}['_removeRevisionMarkers'](_0x47e219){return(_0x47e219=_0x47e219['filter'](_0x1ea34b=>!_0x1ea34b['name']||'revision-start'!==_0x1ea34b['name']&&'revision-end'!==_0x1ea34b['name']))['forEach'](_0xa61a26=>{'string'!=typeof _0xa61a26&&(_0xa61a26['children']=this['_removeRevisionMarkers'](_0xa61a26['children']),_0xa61a26['attributes']=_0xa61a26['attributes']['filter'](_0x261e43=>!_0x261e43[0x0]['startsWith']('data-revision-')));}),_0x47e219;}}function ft(_0x2e7e40,_0x5db6bd,_0x5f30ef){const t=_0x2e7e40['t'];switch(_0x5db6bd){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'},_0x5f30ef);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x5f30ef);case'Show\x20previous\x20change':return t('Show\x20previous\x20change');case'Show\x20next\x20change':return t('Show\x20next\x20change');case'EDIT_X_OF_Y_REVISIONS':return t({'string':'Edit','id':'EDIT_X_OF_Y_REVISIONS'});case'Total':return t('Total');case'Revision\x20creator':return t('Revision\x20creator');case'Revision\x20author':return t('Revision\x20author');case'Revision\x20name':return t('Revision\x20name');case'Save\x20current\x20revision':return t('Save\x20current\x20revision');case'Accept':return t('Accept');case'Save':return t('Save');case'Cancel':return t('Cancel');case'Name\x20of\x20the\x20revision':return t('Name\x20of\x20the\x20revision');case'optional':return t('optional');case'PENDING_ACTION_REVISION_HISTORY':return t({'string':'Unsaved\x20change\x20in\x20revision\x20history.','id':'PENDING_ACTION_REVISION_HISTORY'});case'The\x20revision\x20name\x20cannot\x20be\x20empty.':return t('The\x20revision\x20name\x20cannot\x20be\x20empty.');case'Enter\x20the\x20revision\x20name':return t('Enter\x20the\x20revision\x20name');default:return'';}}class RevisionTracker extends _0x538071{['licenseKey'];['_licenseKeyCheckInterval'];['currentRevision']=null;['repository'];['adapter']=null;['_revisionDataBuilder'];['_source'];['_initialRevisionId'];['_bufferedUpdates'];['_utils'];['_pendingAction'];['_continueCurrentRevision'];['_startingVersion'];['_loadedStateData'];static get['pluginName'](){return'RevisionTracker';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[_0x2baa1d,RevisionsRepository,RevisionHistoryUtils,_0x3985ee];}constructor(_0x3ebfbd){super(_0x3ebfbd),this['repository']=this['editor']['plugins']['get']('RevisionsRepository'),this['_utils']=this['editor']['plugins']['get']('RevisionHistoryUtils'),this['_revisionDataBuilder']=new RevisionDataBuilder(this['editor']),this['_initialRevisionId']=this['editor']['config']['get']('collaboration.channelId')||'initial',this['_bufferedUpdates']=new Map(),this['_loadedStateData']=null;const _0x2017a7=_0x51ceb2();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x2017a7},this['set']('isReady',!0x1),this['set']('isEnabled',!0x0),this['set']('_isPendingUpdate',!0x1),this['editor']['config']['define']('revisionHistory.resumeUnsavedRevision',!0x0),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'});}['init'](){this['_setConversion'](),this['editor']['data']['on']('ready',()=>{const _0x321e41=this['repository']['getRevision'](0x0),_0x14c78c=_0x321e41&&null===_0x321e41['creator']?_0x321e41:null;if(this['_continueCurrentRevision']=!!_0x14c78c&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x52d718=this['_source']['getCurrentRevisionId'](),_0x4363ef=this['repository']['getRevision'](_0x52d718);if(_0x4363ef)this['_startingVersion']=_0x4363ef['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x22e759=this['_source']['history']['_operations']['find'](_0x5d6329=>!_0x5d6329['_isInit']),_0x136122=_0x22e759?_0x22e759['baseVersion']:this['_source']['history']['version'];_0x321e41?(_0x321e41['toVersion']<_0x136122&&_0x321e41['_update']({'toVersion':_0x136122}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x14c78c['id'],this['_startingVersion']=_0x14c78c['fromVersion']):(this['_startingVersion']=_0x321e41['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x136122,this['_continueCurrentRevision']=!0x1);}}else _0x14c78c&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x14c78c['toVersion'],this['editor']['model']['document']['history']['version']),_0x14c78c['fromVersion']===_0x14c78c['toVersion']?(0x0!==_0x14c78c['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x14c78c['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x14c78c['id'],this['_startingVersion']=_0x14c78c['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',_0x1370a8=>!_0x1370a8),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x2c5d54=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x1beeaa;for(const _0x13f036 in _0x2c5d54){const _0x1e908a=_0x13f036,_0x267c22=_0x2c5d54[_0x1e908a];if('revisionHistoryLicenseKeyValid'==_0x267c22||'revisionHistoryLicenseKeyInvalid'==_0x267c22||'revisionHistoryLicenseKeyExpired'==_0x267c22||'revisionHistoryLicenseKeyDomainLimit'==_0x267c22||'revisionHistoryLicenseKeyNotAllowed'==_0x267c22||'revisionHistoryLicenseKeyEvaluationLimit'==_0x267c22||'revisionHistoryLicenseKeyUsageLimit'==_0x267c22){delete _0x2c5d54[_0x1e908a],_0x1beeaa=_0x267c22,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x1beeaa&&_0x2c5d54['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x1beeaa&&_0x2c5d54['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x1beeaa&&_0x2c5d54['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x1beeaa&&_0x2c5d54['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x1beeaa&&_0x2c5d54['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x1beeaa&&_0x2c5d54['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0xa404b8=this['repository']['getRevision'](0x0),_0x5c0f45=await this['getRevisionDocumentData'](_0xa404b8),_0xf90263=await this['getRevisionRootsAttributes'](_0xa404b8),_0x279884=this['_utils']['getRevisionRootsModelElements'](_0xa404b8);this['_replaceEditorDataWithRevisionData'](_0x5c0f45,_0xf90263,_0x279884);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0xdc7e84){this['_source']=_0xdc7e84;}async['update'](){const _0x3924f9=await this['_source']['getLatestVersion']();if(_0x3924f9>this['currentRevision']['toVersion']){await this['_loadState']();const _0x24912f=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x3924f9});_0x24912f['authors']=_0x24912f['authorsIds']['map'](_0x4c3377=>this['editor']['plugins']['get']('Users')['getUser'](_0x4c3377)),this['currentRevision']['_update'](_0x24912f);}}async['saveRevision'](_0x1ab741={},_0x70072c=null){const _0x3b94b7=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x70072c>this['currentRevision']['toVersion']&&(_0x70072c=null),null===_0x70072c&&(_0x70072c=await this['_source']['getLatestVersion']());const _0x38f5d5=this['_getFromVersion'](_0x70072c),_0x3068d5=this['buildRevisionData']({'from':_0x38f5d5,'to':_0x70072c});if(this['currentRevision']['toVersion']<_0x70072c){const _0x5eee93=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x70072c,'to':_0x70072c});_0x5eee93['authors']=[],_0x5eee93['authorsIds']=[],_0x5eee93['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x5eee93,!0x0),delete _0x5eee93['authors'],_0x3b94b7['push'](_0x5eee93);}_0x1ab741['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x1ab741['name']=_0x1ab741['name']||null,_0x1ab741['id']=_0x1ab741['id']||_0x51ceb2(),_0x1ab741={..._0x1ab741,..._0x3068d5};const _0x525b51=this['addRevisionData'](_0x1ab741);_0x3b94b7['push'](_0x1ab741);const _0x3eaf98=this['repository']['getIndex'](_0x525b51);if(0x0!==_0x3eaf98){const _0x40b3ff=this['repository']['getRevision'](_0x3eaf98-0x1);if(_0x40b3ff['fromVersion']!==_0x70072c){const _0x1544b7=this['_revisionDataBuilder']['getData'](_0x70072c,_0x40b3ff['toVersion']),_0x599be5={'id':_0x40b3ff['id'],'diffData':_0x1544b7['diffData'],'authorsIds':_0x1544b7['authorsIds'],'authors':_0x1544b7['authorsIds']['map'](_0x5c5666=>this['editor']['plugins']['get']('Users')['getUser'](_0x5c5666)),'fromVersion':_0x70072c};_0x40b3ff===this['currentRevision']&&(_0x599be5['createdAt']=new Date(_0x1ab741['createdAt']['getTime']()+0xa)),_0x40b3ff['_update'](_0x599be5,!0x0),delete _0x599be5['authors'],_0x3b94b7['push'](_0x599be5);}}if(this['adapter']){for(const _0x1f06b6 of _0x3b94b7)this['_bufferUpdate'](_0x1f06b6['id'],_0x1f06b6,!0x0);this['sendBufferedUpdates']();}return _0x525b51;}['addRevisionData'](_0x260be9){const _0x45f6a8=this['repository']['createRevision'](_0x260be9);return this['adapter']&&_0x45f6a8['on']('_update',(_0x29697d,_0xfc796c,_0x181695)=>{_0x181695||(this['_bufferUpdate'](_0xfc796c['id'],_0xfc796c,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x45f6a8,this['_findInsertionIndex'](_0x45f6a8)),_0x45f6a8;}async['getRevisionDocumentData'](_0x310cc2){return await this['_utils']['loadRevisionData'](_0x310cc2,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x310cc2);}async['getRevisionRootsAttributes'](_0x4f15ad){return await this['_utils']['loadRevisionData'](_0x4f15ad,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x4f15ad);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x56d21d=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x264145=0x0;_0x264145<_0x56d21d['length'];_0x264145++){const _0x36bc31=_0x56d21d[_0x264145];let _0x1d7359=!0x1;for(const _0x5689eb of Object['keys'](_0x36bc31))void 0x0===_0x36bc31[_0x5689eb]?delete _0x36bc31[_0x5689eb]:'id'!==_0x5689eb&&(_0x1d7359=!0x0);_0x1d7359||(_0x56d21d[_0x264145]=null);}if(_0x56d21d=_0x56d21d['filter'](_0x1c9830=>null!==_0x1c9830),!_0x56d21d['length'])return;for(let _0x54acad=0x0;_0x54acad<_0x56d21d['length'];_0x54acad++){const _0x2b76b3=_0x56d21d[_0x54acad];void 0x0!==_0x2b76b3['fromVersion']&&void 0x0===_0x2b76b3['toVersion']&&(_0x2b76b3['toVersion']=this['repository']['getRevision'](_0x2b76b3['id'])['toVersion']),void 0x0!==_0x2b76b3['toVersion']&&void 0x0===_0x2b76b3['fromVersion']&&(_0x2b76b3['fromVersion']=this['repository']['getRevision'](_0x2b76b3['id'])['fromVersion']);}const _0x9c8e1=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x56d21d,_0x9c8e1)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x245954=>{if(_0x245954){for(const _0x1d9ad8 of _0x245954)this['setRevisionData']({'id':_0x1d9ad8['id'],'createdAt':_0x1d9ad8['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0x5394ac=null,from:_0x3edae7=null,to:_0x38283e=null}){_0x3edae7=null!==_0x3edae7?_0x3edae7:_0x5394ac['fromVersion'],_0x38283e=null!==_0x38283e?_0x38283e:_0x5394ac['toVersion'];const _0x2c41fb=this['_revisionDataBuilder']['getData'](_0x3edae7,_0x38283e),_0x2c058c={'diffData':_0x2c41fb['diffData'],'authorsIds':_0x2c41fb['authorsIds'],'fromVersion':_0x3edae7,'toVersion':_0x38283e};if(!_0x5394ac||_0x38283e!==_0x5394ac['toVersion']){const _0x424d15=_0x38283e-0x1,_0x8a2f34=this['_source']['history']['getOperation'](_0x424d15);_0x2c058c['createdAt']=_0x8a2f34&&_0x8a2f34['createdAt']||new Date();}if(this['_loadedStateData']&&_0x3edae7===this['_loadedStateData']['fromVersion']){for(const _0x46072e of this['_loadedStateData']['authors'])_0x2c058c['authorsIds']['includes'](_0x46072e['id'])||_0x2c058c['authorsIds']['push'](_0x46072e['id']);}return _0x2c058c;}['_bufferUpdate'](_0x4a2d1f,_0x1ec4c7,_0x329f73){if(this['_bufferedUpdates']['has'](_0x4a2d1f)){const _0x1f02d3=this['_bufferedUpdates']['get'](_0x4a2d1f);_0x1ec4c7=_0x329f73?{..._0x1f02d3,..._0x1ec4c7}:{..._0x1ec4c7,..._0x1f02d3};}this['_bufferedUpdates']['set'](_0x4a2d1f,_0x1ec4c7);}['setRevisionData'](_0x1aa24e){const _0x3605df=this['repository']['getRevision'](_0x1aa24e['id']);if(_0x1aa24e['createdAt']&&(_0x1aa24e['createdAt']=new Date(_0x1aa24e['createdAt'])),_0x1aa24e['authorsIds']){const _0x1d63e1=this['editor']['plugins']['get']('Users');_0x1aa24e['authors']=_0x1aa24e['authorsIds']['map'](_0x5a240d=>_0x1d63e1['getUser'](_0x5a240d));}_0x3605df['_update'](_0x1aa24e,!0x0);}['_createInitialRevision'](_0x3f0feb){const _0x410cac=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x410cac)this['_initialRevisionId']=_0x410cac['id'];else{const _0x531cc3=!this['editor']['model']['document']['roots']['find'](_0x578f7d=>this['editor']['model']['hasContent'](_0x578f7d)),_0x5a4d40=this['editor']['plugins']['get']('Users')['me']['id'],_0x159109=ft(this['editor']['locale'],_0x531cc3?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x3f0feb,'to':_0x3f0feb,'id':this['_initialRevisionId'],'name':_0x159109,'creatorId':_0x5a4d40});}}['_createCurrentRevision'](_0x1ee7f0){const _0x259188=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x259188),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x1ee7f0,'to':_0x1ee7f0,'id':_0x259188,'name':'','creatorId':null}));}async['_loadState'](){this['_continueCurrentRevision']&&!this['_loadedStateData']&&(await this['_utils']['loadRevisionData'](this['currentRevision'],this['adapter']),this['_revisionDataBuilder']['loadState'](this['currentRevision']),this['_loadedStateData']={'fromVersion':this['currentRevision']['fromVersion'],'authors':this['currentRevision']['authors']['slice']()});}['_replaceEditorDataWithRevisionData'](_0x1101b7,_0x29487c,_0x17360e){const _0x4b4502={},_0x2e604a={},_0x2ed59b={},_0x231d70=this['editor']['config']['get']('roots')||{};for(const [_0x260741,_0x231e95]of Object['entries'](_0x231d70))_0x231e95['lazyLoad']||(_0x4b4502[_0x260741]=_0x231e95['initialData']??'',_0x2e604a[_0x260741]=_0x231e95['modelAttributes']||{},_0x231e95['modelElement']&&(_0x2ed59b[_0x260741]=_0x231e95['modelElement']));for(const _0x4a58a6 of this['editor']['model']['document']['getRootNames']())_0x4b4502[_0x4a58a6]??='',_0x2e604a[_0x4a58a6]??={};let _0x4d7287=!0x1;const _0x51430c=Object['keys'](_0x4b4502),_0x3ff515=Object['keys'](_0x1101b7);for(const _0x16ceb1 of _0x51430c){if(_0x4b4502[_0x16ceb1]!==_0x1101b7[_0x16ceb1]&&''!==_0x4b4502[_0x16ceb1]['trim']()){_0x4d7287=!0x0;break;}if(!_0x5af7ec(_0x2e604a[_0x16ceb1],_0x29487c[_0x16ceb1])&&Object['keys'](_0x2e604a[_0x16ceb1])['length']>0x0){_0x4d7287=!0x0;break;}const _0x4bd16b=_0x2ed59b[_0x16ceb1],_0x34401f=_0x17360e[_0x16ceb1];if(_0x4bd16b&&_0x34401f&&_0x4bd16b!==_0x34401f){_0x4d7287=!0x0;break;}}_0x4d7287||(_0x4d7287=_0x3ff515['some'](_0x4bdc40=>!this['editor']['model']['document']['getRoot'](_0x4bdc40))),_0x4d7287&&_0x1b67c3('editor-initial-data-replaced-with-revision-data',{'editorData':_0x4b4502,'editorRootsAttributes':_0x2e604a,'editorRootsModelElements':_0x2ed59b,'revisionData':_0x1101b7,'revisionRootsAttributes':_0x29487c,'revisionRootsModelElements':_0x17360e});for(const [_0x553a0c,_0x1341be]of Object['entries'](_0x1101b7))this['editor']['config']['set']('roots.'+_0x553a0c+'.initialData',_0x1341be);for(const [_0x48bb13,_0x1d72b9]of Object['entries'](_0x29487c))this['editor']['config']['set']('roots.'+_0x48bb13+'.modelAttributes',_0x1d72b9);const _0x108f46=this['editor']['model']['document'];for(const [_0x1c0e9c,_0x11b3a2]of Object['entries'](_0x17360e)){this['editor']['config']['set']('roots.'+_0x1c0e9c+'.modelElement',_0x11b3a2);const _0x20a363=_0x108f46['getRoot'](_0x1c0e9c);_0x20a363&&_0x20a363['name']!==_0x11b3a2&&(_0x108f46['roots']['remove'](_0x1c0e9c),_0x108f46['createRoot'](_0x11b3a2,_0x1c0e9c));}}['_addPendingAction'](){if(!this['_pendingAction']){const _0x7716aa=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x7716aa['add'](ft(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x245ee0){const _0x454408=this['repository']['getRevisions']();_0x454408['reverse']();let _0x3a452e=0x0;for(;_0x3a452e<_0x454408['length'];){const _0x5a0c28=_0x454408[_0x3a452e];if(_0x5a0c28===this['currentRevision']){_0x3a452e++;continue;}if(_0x5a0c28['id']===this['_initialRevisionId'])break;const _0x1ef849=_0x245ee0['toVersion']-_0x5a0c28['toVersion']||_0x245ee0['fromVersion']-_0x5a0c28['fromVersion'];if(_0x1ef849>0x0)break;if(_0x1ef849<0x0)_0x3a452e++;else{if(!_0x245ee0['creator']&&_0x5a0c28['creator'])break;if(_0x5a0c28['creator']||!_0x245ee0['creator']){if(_0x245ee0['createdAt']>_0x5a0c28['createdAt'])break;_0x3a452e++;}else _0x3a452e++;}}return _0x3a452e;}['_getFromVersion'](_0x1ad5e8){const _0x211216=this['repository']['getRevisions']();_0x211216['reverse'](),_0x211216['shift']();const _0x59a928=_0x211216['find'](_0x59dcd5=>_0x59dcd5['toVersion']<=_0x1ad5e8)['toVersion'];return _0x59a928<this['_startingVersion']?this['_startingVersion']:_0x59a928;}['_makeRevision']({name:_0x149ed4,from:_0x45feba,to:_0x37f6b0,creatorId:_0x54e6c3,id:_0x115e11}){const _0x65fab4=this['buildRevisionData']({'from':_0x45feba,'to':_0x37f6b0});_0x65fab4['name']=_0x149ed4,_0x65fab4['creatorId']=_0x54e6c3,_0x65fab4['id']=_0x115e11;const _0x592f28=this['addRevisionData'](_0x65fab4);return this['adapter']&&this['_bufferUpdate'](_0x65fab4['id'],_0x65fab4,!0x0),_0x592f28;}['_setConversion'](){this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'});}}class RevisionDataBuilder{['editor'];['source'];['_savedMetaData'];['_lastFrom'];['_lastTo'];['_markers'];['_diffRoots'];['_diffRootsAttributes'];['_baseRoots'];['_baseRootsAttributes'];['_idsRoots'];['_baseIdsRoots'];['_touched'];['_touchedMarkers'];['_touchedRoots'];['_revisionId'];['_startingRevisionId'];constructor(_0x164171){this['editor']=_0x164171,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'](_0x33119e){this['source']=_0x33119e;const _0x4501da=new Map(),_0x3dc4c2=new Map(),_0x262070=this['editor']['model']['document']['roots']['map'](_0xded587=>_0xded587['rootName']);for(const _0x6d3e10 of _0x262070){const _0x48e352=this['editor']['model']['document']['getRoot'](_0x6d3e10),_0x215bd9=gt(_0x48e352);_0x4501da['set'](_0x6d3e10,_0x215bd9),_0x3dc4c2['set'](_0x6d3e10,Object['fromEntries'](_0x48e352['getAttributes']()));}const _0xee17e8=Array['from'](this['editor']['model']['markers'])['map'](_0x1621f7=>[_0x1621f7['name'],_0x1621f7['getRange']()]),_0x562e94=this['source']['version'];this['_saveMetaData'](_0x562e94,_0x4501da,_0xee17e8,_0x3dc4c2),this['_startingRevisionId']=this['_revisionId'];const _0x2ec43b=new Map(),_0x212caf=new Map();for(const _0x107aa5 of _0x262070){const _0x3b2616=wt(_0x107aa5,this['editor']['model']['document']['getRoot'](_0x107aa5)['name']);_0x2ec43b['set'](_0x107aa5,_0x3b2616),_0x212caf['set'](_0x107aa5,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x2ec43b,[],_0x212caf);}['getData'](_0xcbd783,_0x51460d){if(this['_lastFrom']===_0xcbd783&&this['_lastTo']<=_0x51460d)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x51460d,!0x0);else{if(!this['_savedMetaData']['has'](_0xcbd783)){const _0x3e8b30=this['_getPreviousFrom'](_0xcbd783);this['_calculateMetaData'](_0x3e8b30,_0xcbd783,!0x1);}this['_calculateMetaData'](_0xcbd783,_0x51460d,!0x0);}return this['_lastFrom']=_0xcbd783,this['_lastTo']=_0x51460d,this['_getState']();}['loadState'](_0x1201a5){if(!this['_savedMetaData']['has'](_0x1201a5['fromVersion'])){const _0x28eb52=this['_getPreviousFrom'](_0x1201a5['fromVersion']);this['_calculateMetaData'](_0x28eb52,_0x1201a5['fromVersion'],!0x1);}this['_calculateMetaData'](_0x1201a5['fromVersion'],_0x1201a5['toVersion'],!0x1);const _0x10d26a=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x1201a5['fromVersion'],this['_lastTo']=_0x1201a5['toVersion'];for(const _0x211530 in _0x1201a5['diffData']){const _0x51cf05=_0x1201a5['diffData'][_0x211530]['attachChange'],_0x4c9364=_0x8c5550(_0x1201a5['diffData'][_0x211530]['attributesBefore'])||{},_0xfee157=_0x1201a5['diffData'][_0x211530],_0x187e6b=_0x10d26a['_makeModelFromViewString'](_0xfee157['deletions'],_0xfee157['rootElementName']||'$root');_0x187e6b['rootName']=_0x211530,_0x187e6b['_isAttached']=!_0x51cf05||!_0x51cf05['isAttached'],_0x187e6b['isAttached']=()=>_0x187e6b['_isAttached'],this['_baseRoots']['set'](_0x211530,_0x187e6b),this['_baseRootsAttributes']['set'](_0x211530,_0x4c9364),_0x51cf05&&this['_touchedRoots']['set'](_0x211530,_0x51cf05);const _0x317bef=this['_makeIdsRoot'](_0x187e6b);this['_baseIdsRoots']['set'](_0x211530,_0x317bef);for(const [_0x2d419c,_0x39e7d8]of _0x187e6b['markers']){if(!_0x2d419c['startsWith']('revision:'))continue;const _0x85dca2=_0x2d419c['split'](':')[0x2];for(const _0x2fc59f of _0x39e7d8['getWalker']({'singleCharacters':!0x0})){const _0x4261b9=this['_getVidAttributeName'](_0x2fc59f),_0x24abd4='elementEnd'==_0x2fc59f['type']?_0x2fc59f['previousPosition']['path']['slice'](0x0,-0x1):_0x2fc59f['previousPosition']['path'],_0x14b4ea=_0x317bef['getNodeByPath'](_0x24abd4)['getAttribute'](_0x4261b9);this['_touched']['set'](_0x14b4ea,{'userId':_0x85dca2});}_0x187e6b['markers']['delete'](_0x2d419c);}}this['_startingRevisionId']=this['_revisionId'];const _0x117c30=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x449d9b=>!this['_touched']['has'](_0x449d9b));let _0x28b160=0x0;const _0xb84af2=new Map();for(const _0x2a08f5 in _0x1201a5['diffData']){const _0x24b249=_0x1201a5['diffData'][_0x2a08f5]['attachChange'],_0x5364f4=_0x8c5550(_0x1201a5['diffData'][_0x2a08f5]['attributesAfter'])||{},_0x90ced3=_0x1201a5['diffData'][_0x2a08f5],_0x26ea02=_0x10d26a['_makeModelFromViewString'](_0x90ced3['insertions'],_0x90ced3['rootElementName']||'$root');_0x26ea02['rootName']=_0x2a08f5,_0x26ea02['_isAttached']=!_0x24b249||_0x24b249['isAttached'],_0x26ea02['isAttached']=()=>_0x26ea02['_isAttached'],this['_diffRoots']['set'](_0x2a08f5,_0x26ea02),this['_diffRootsAttributes']['set'](_0x2a08f5,_0x5364f4);const _0x16d1e2=this['_makeIdsRoot'](_0x26ea02,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x2a08f5,_0x16d1e2),_0xb84af2['set'](_0x2a08f5,_0x26ea02['isAttached']()?_0x5364f4:{});for(const [_0x3f4e35,_0x3131bf]of _0x26ea02['markers']){if(!_0x3f4e35['startsWith']('revision:'))continue;const _0x5e860a=_0x3f4e35['split'](':')[0x2];for(const _0x41bf19 of _0x3131bf['getWalker']({'singleCharacters':!0x0})){const _0xecb73=this['_getVidAttributeName'](_0x41bf19),_0x23f593=this['_revisionId']++,_0x154940='elementEnd'==_0x41bf19['type']?_0x41bf19['previousPosition']['path']['slice'](0x0,-0x1):_0x41bf19['previousPosition']['path'];_0x16d1e2['getNodeByPath'](_0x154940)['_setAttribute'](_0xecb73,_0x23f593),this['_touched']['set'](_0x23f593,{'userId':_0x5e860a});}_0x26ea02['markers']['delete'](_0x3f4e35);}for(const _0x349204 of this['editor']['model']['createRangeIn'](_0x26ea02)['getWalker']({'singleCharacters':!0x0})){const _0x43a2c9=this['_getVidAttributeName'](_0x349204),_0x52beb8='elementEnd'==_0x349204['type']?_0x349204['previousPosition']['path']['slice'](0x0,-0x1):_0x349204['previousPosition']['path'],_0x46d6aa=_0x16d1e2['getNodeByPath'](_0x52beb8);_0x46d6aa['getAttribute'](_0x43a2c9)>0x0||_0x46d6aa['_setAttribute'](_0x43a2c9,_0x117c30[_0x28b160++]);}for(const [_0x3e31ba,_0x34ec82]of _0x26ea02['markers'])_0x3e31ba['startsWith']('revision:')||this['_markers']['set'](_0x3e31ba,_0x34ec82);}const {roots:_0x2b9d50}=this['_savedMetaData']['get'](_0x1201a5['fromVersion']),{roots:_0x3d187d}=this['_savedMetaData']['get'](_0x1201a5['toVersion']),_0x5cef6d=gt(_0x2b9d50['get']('$graveyard'));this['_baseRoots']['set']('$graveyard',_0x5cef6d),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x5cef6d,Number['NEGATIVE_INFINITY']));const _0x2148e5=gt(_0x3d187d['get']('$graveyard'));this['_diffRoots']['set']('$graveyard',_0x2148e5),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x2148e5));const _0x492936=Array['from'](this['_diffRoots'])['map'](([_0x2ac7d4,_0x3f4de4])=>[_0x2ac7d4,gt(_0x3f4de4)]);this['_saveMetaData'](this['_lastTo'],_0x492936,this['_markers'],_0xb84af2);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0x4f890f,_0x353e3a,_0x54f1f1,_0xa875f2){const _0x212390=new Map(_0x353e3a),_0x3a9824=new Map(_0x8c5550(_0xa875f2)),_0x295916=new Map();for(const [_0xfc152a,_0x5c8b30]of _0x54f1f1)_0x295916['set'](_0xfc152a,{'start':_0x5c8b30['start']['clone'](),'end':_0x5c8b30['end']['clone'](),'rootName':_0x5c8b30['root']['rootName']});this['_savedMetaData']['set'](_0x4f890f,{'roots':_0x212390,'markers':_0x295916,'rootsAttributes':_0x3a9824});}['_removeMetaData'](_0x242cb1){this['_savedMetaData']['delete'](_0x242cb1);}['_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'](_0x51cfdc,_0x4fd686=null){let _0xb18c96=null;_0x51cfdc['is']('documentFragment')||(_0xb18c96=new _0x46d26f(_0x51cfdc['name'],{'vid_start':null===_0x4fd686?this['_revisionId']++:_0x4fd686++}));const _0x5b25c5=[];for(const _0x5189ec of _0x51cfdc['getChildren']())if(_0x5189ec['is']('element')){_0x5b25c5['push'](this['_makeIdsRoot'](_0x5189ec,_0x4fd686));const _0x14341a=_0x5b25c5[_0x5b25c5['length']-0x1];null!==_0x4fd686&&(_0x4fd686=_0x14341a['is']('element','$text')?_0x14341a['getAttribute']('vid')+0x1:_0x14341a['getAttribute']('vid_end')+0x1);}else{for(let _0x518f86=0x0;_0x518f86<_0x5189ec['offsetSize'];_0x518f86++)_0x5b25c5['push'](new _0x46d26f('$text',{'vid':null===_0x4fd686?this['_revisionId']++:_0x4fd686++}));}if(_0x51cfdc['is']('documentFragment')){const _0x57e8b1=wt(_0x51cfdc['rootName'],_0x51cfdc['name']);return _0x57e8b1['_insertChild'](0x0,_0x5b25c5),_0x57e8b1;}return _0xb18c96['_setAttribute']('vid_end',null===_0x4fd686?this['_revisionId']++:_0x4fd686++),_0xb18c96['_insertChild'](0x0,_0x5b25c5),_0xb18c96;}['_calculateMetaData'](_0x71d2b6,_0x359751,_0xf3f40f){this['_reset']();const {roots:_0x497925,markers:_0x276976,rootsAttributes:_0x43d613}=this['_savedMetaData']['get'](_0x71d2b6);this['_baseRoots']=new Map(_0x497925),this['_baseRootsAttributes']=new Map(_0x8c5550(_0x43d613));for(const [_0x2f9351,_0x3f6294]of this['_baseRoots'])if('$graveyard'!==_0x2f9351&&(this['_diffRoots']['set'](_0x2f9351,gt(_0x3f6294)),this['_diffRootsAttributes']=new Map(_0x8c5550(_0x43d613)),_0xf3f40f)){const _0x251ed0=this['_revisionId'];this['_idsRoots']['set'](_0x2f9351,this['_makeIdsRoot'](_0x3f6294)),this['_baseIdsRoots']['set'](_0x2f9351,this['_makeIdsRoot'](_0x3f6294,_0x251ed0));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',gt(this['_baseRoots']['get']('$graveyard'))),_0xf3f40f&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x1ff339,_0x58f781]of _0x276976){const _0x4c87bb=this['_baseRoots']['get'](_0x58f781['rootName']),_0x400a2b=this['_diffRoots']['get'](_0x58f781['rootName']),_0x493579=new _0xa8802c(this['_fixPosition'](_0x58f781['start'],_0x4c87bb),this['_fixPosition'](_0x58f781['end'],_0x4c87bb)),_0x4d3a48=this['_fixRange'](_0x493579,_0x400a2b);_0x4c87bb['markers']['set'](_0x1ff339,_0x493579),this['_markers']['set'](_0x1ff339,_0x4d3a48);}this['_applyOperations'](_0x71d2b6,_0x359751,_0xf3f40f);}['_applyOperations'](_0xe16e56,_0x12d519,_0x401274){for(const _0x5bc536 of this['source']['getOperations'](_0xe16e56,_0x12d519))this['_handleOperation'](_0x5bc536,_0x401274);for(const _0x268993 of this['_diffRoots']['values']())_0x268993['markers']['clear']();for(const [_0x57ab43,_0x32c083]of this['_markers']){this['_diffRoots']['get'](_0x32c083['root']['rootName'])['markers']['set'](_0x57ab43,_0x32c083['clone']());}const _0x29ae54=new Map(),_0x16acdd=new Map();for(const [_0x2cd0ed,_0x486b34]of this['_diffRoots'])_0x29ae54['set'](_0x2cd0ed,gt(_0x486b34)),_0x16acdd['set'](_0x2cd0ed,this['_diffRootsAttributes']['get'](_0x2cd0ed));this['_saveMetaData'](_0x12d519,_0x29ae54,this['_markers'],_0x16acdd);}['_getPreviousFrom'](_0x42ccd6){const _0x3d8500=Array['from'](this['_savedMetaData']['keys']());_0x3d8500['sort']((_0x3f7b1e,_0x110bc1)=>_0x3f7b1e-_0x110bc1),_0x3d8500['reverse']();for(const _0x451b8c of _0x3d8500)if(_0x451b8c<_0x42ccd6)return _0x451b8c;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0xf6b1ae,_0x31ebde){const _0x344456=Array['from'](_0x31ebde['markers'])['map'](([_0x26eb8a,_0x16ec26])=>[_0x26eb8a,this['_fixRange'](_0x16ec26,_0xf6b1ae)]);_0xf6b1ae['markers']=new Map(_0x344456);}['_transformMarkers'](_0x502668){for(const _0x3a8607 of this['_markers']['values']()){const _0x199645=_0x3a8607['getTransformedByOperation'](_0x502668),_0xd35267=_0xa8802c['_createFromRanges'](_0x199645);_0x3a8607['start']=_0xd35267['start'],_0x3a8607['end']=_0xd35267['end'];}}['_handleOperation'](_0x5f203e,_0x3d8baf){if('addRoot'!=_0x5f203e['type']&&'detachRoot'!=_0x5f203e['type']){if('insert'==_0x5f203e['type']){const _0x516341=_0x5f203e['position']['root'],_0xded08d=_0x516341['rootName'],_0x22033e=_0x516341['name'];this['_diffRoots']['has'](_0xded08d)||(this['_diffRoots']['set'](_0xded08d,wt(_0xded08d,_0x22033e,!0x0)),this['_diffRootsAttributes']['set'](_0xded08d,{}),_0x3d8baf&&this['_idsRoots']['set'](_0xded08d,wt(_0xded08d,_0x22033e,!0x0)));}else{if('addRootAttribute'==_0x5f203e['type']||'removeRootAttribute'==_0x5f203e['type']||'changeRootAttribute'==_0x5f203e['type'])return void this['_handleRootAttributeOperation'](_0x5f203e);'marker'==_0x5f203e['type']&&this['_handleMarkerOperation'](_0x5f203e);}if('marker'!==_0x5f203e['type']){const _0x4d0984=this['_cloneOperation'](_0x5f203e,this['_diffRoots']);_0x4d0984['_execute'](),this['_transformMarkers'](_0x4d0984);}if(_0x3d8baf)switch(_0x5f203e['type']){case'insert':this['_handleInsertOperation'](_0x5f203e);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x5f203e);break;case'merge':this['_handleMergeOperation'](_0x5f203e);break;case'split':this['_handleSplitOperation'](_0x5f203e);}}else this['_handleRootOperation'](_0x5f203e,_0x3d8baf);}['_cloneOperation'](_0x572ade,_0x39a48a){const _0x3c9641=_0x572ade['clone']();return _0x3c9641['_authorId']=_0x572ade['_authorId'],this['_fixOperation'](_0x3c9641,_0x39a48a),_0x3c9641;}['_getBaseVids'](_0x469ce3){return _0x469ce3['map'](_0xb10902=>{const _0x193f78=this['_getVidAttributeName'](_0xb10902);return Number(_0xb10902['item']['getAttribute'](_0x193f78));});}['_generateTape'](_0x16873e,_0x5b3e11){if(_0x16873e['is']('element','$text'))_0x5b3e11['push']({'item':_0x16873e,'type':'text'});else{_0x16873e['is']('element')&&_0x5b3e11['push']({'item':_0x16873e,'type':'elementStart'});for(const _0x26501a of _0x16873e['getChildren']())this['_generateTape'](_0x26501a,_0x5b3e11);_0x16873e['is']('element')&&_0x5b3e11['push']({'item':_0x16873e,'type':'elementEnd'});}return _0x5b3e11;}['_getState'](){const _0x32e8f1=new Map(this['_touched']),_0x517942=new Map(_0x32e8f1),_0xe11ea5=new Map(),_0x1e4185={'insertions':{},'deletions':{}},_0x39c24a={'insertions':{},'deletions':{}},_0x10cb30=new Map(),_0x3ee65b=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]),_0x21a4e7=new Map();_0x3ee65b['delete']('$graveyard');for(const _0x561e4b of _0x3ee65b){const _0x5d6d67=(this['_diffRoots']['get'](_0x561e4b)??this['_baseRoots']['get'](_0x561e4b))['name'],_0x2a2107=this['_diffRoots']['get'](_0x561e4b)||wt(_0x561e4b,_0x5d6d67,!0x1),_0x56cf55=this['_baseRoots']['get'](_0x561e4b)||wt(_0x561e4b,_0x5d6d67,!0x1);_0x2a2107['isAttached']()||_0x56cf55['isAttached']()?(_0x21a4e7['set'](_0x561e4b,_0x5d6d67),_0x1e4185['insertions'][_0x561e4b]=gt(_0x2a2107),_0x1e4185['deletions'][_0x561e4b]=gt(_0x56cf55),this['_copyMarkers'](_0x1e4185['deletions'][_0x561e4b],_0x56cf55),this['_copyMarkers'](_0x1e4185['insertions'][_0x561e4b],_0x2a2107),_0x39c24a['insertions'][_0x561e4b]=this['_generateTape'](this['_idsRoots']['get'](_0x561e4b),[]),_0x39c24a['deletions'][_0x561e4b]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x561e4b)||wt(_0x561e4b,_0x5d6d67,!0x1),[])):_0x3ee65b['delete'](_0x561e4b);}for(const _0x1c4dd4 of _0x3ee65b){const _0x5e54e9=_0x39c24a['insertions'][_0x1c4dd4];for(const _0x3cba97 of _0x5e54e9){const _0x197fd0=this['_getVidAttributeName'](_0x3cba97),_0x25f53a=_0x3cba97['item']['getAttribute'](_0x197fd0);_0x517942['delete'](_0x25f53a),_0x25f53a>=this['_startingRevisionId']&&_0xe11ea5['set'](_0x25f53a,_0x32e8f1['get'](_0x25f53a));}}for(const _0x36ca0d of _0x3ee65b){const _0x3f2d56=_0x39c24a['insertions'][_0x36ca0d],_0x5add97=this['_getBaseVids'](_0x39c24a['deletions'][_0x36ca0d]);let _0x31d4a8=0x0;for(const _0x4b3695 of _0x3f2d56){const _0x2dd340=this['_getVidAttributeName'](_0x4b3695),_0x3f2f70=_0x4b3695['item']['getAttribute'](_0x2dd340);if(!_0xe11ea5['has'](_0x3f2f70)&&!_0x10cb30['has'](_0x3f2f70)){if(_0x517942['has'](_0x3f2f70))_0x31d4a8++;else{if(_0x3f2f70!=_0x5add97[_0x31d4a8]){const _0x16ab01=_0x32e8f1['get'](_0x3f2f70)||_0x32e8f1['get'](_0x5add97[_0x31d4a8]);for(;_0x3f2f70!=_0x5add97[_0x31d4a8];)_0x517942['has'](_0x5add97[_0x31d4a8])||(_0x10cb30['set'](_0x5add97[_0x31d4a8],_0x16ab01),_0x32e8f1['set'](_0x5add97[_0x31d4a8],_0x16ab01)),_0x31d4a8++;}_0x31d4a8++;}}}}for(const _0x481365 of _0x3ee65b){const _0x1053d0=_0x39c24a['insertions'][_0x481365];for(const _0x1a6049 of _0x1053d0){const _0x3c6d17=this['_getVidAttributeName'](_0x1a6049),_0x22a8b2=_0x1a6049['item']['getAttribute'](_0x3c6d17);if(_0x10cb30['has'](_0x22a8b2)){const _0x3a0224=_0x10cb30['get'](_0x22a8b2);_0x517942['has'](_0x22a8b2)||_0x517942['set'](_0x22a8b2,{..._0x3a0224}),_0xe11ea5['set'](_0x22a8b2,{..._0x3a0224});}}}for(const _0x16e062 of _0x517942['keys']())_0x16e062>=this['_startingRevisionId']&&_0x517942['delete'](_0x16e062);const _0x215c00=new Map();for(const _0x37fd1a of _0x3ee65b){let _0x59ab1f=_0x39c24a['insertions'][_0x37fd1a];for(const _0x4b2cf4 of _0x59ab1f)if(_0x4b2cf4['item']['is']('element','tableCell')){const _0xf1ec7e=this['_getVidAttributeName'](_0x4b2cf4),_0x5a41d8=_0x4b2cf4['item']['getAttribute'](_0xf1ec7e);if(_0xe11ea5['has'](_0x5a41d8)){const _0x43d712=_0x4b2cf4['item']['parent']['parent']['getAttribute']('vid_start'),_0x58facd=_0x215c00['get'](_0x43d712)||new Set();_0x58facd['add'](_0xe11ea5['get'](_0x5a41d8)['userId']),_0x215c00['set'](_0x43d712,_0x58facd);}}_0x59ab1f=_0x39c24a['deletions'][_0x37fd1a];for(const _0x182e11 of _0x59ab1f)if(_0x182e11['item']['is']('element','tableCell')){const _0x44bc24=this['_getVidAttributeName'](_0x182e11),_0x1c43d7=_0x182e11['item']['getAttribute'](_0x44bc24);if(_0x517942['has'](_0x1c43d7)){const _0x174d00=_0x182e11['item']['parent']['parent']['getAttribute']('vid_start'),_0x1c7ec9=_0x215c00['get'](_0x174d00)||new Set();_0x1c7ec9['add'](_0x517942['get'](_0x1c43d7)['userId']),_0x215c00['set'](_0x174d00,_0x1c7ec9);}}for(const _0x991cbe of _0x215c00['keys']())(_0xe11ea5['has'](_0x991cbe)||_0x517942['has'](_0x991cbe))&&_0x215c00['delete'](_0x991cbe);}for(const _0x2963ba of _0x3ee65b){const _0x361207=_0x39c24a['insertions'][_0x2963ba];let _0x1dc649=null,_0x5eefa8=null;for(const _0xad7e45 of _0x361207){const _0x48b5a7=this['_getVidAttributeName'](_0xad7e45),_0xc31246=_0xad7e45['item']['getAttribute'](_0x48b5a7),_0x3b1b3f=_0x215c00['get'](_0xc31246);_0x3b1b3f&&'elementStart'==_0xad7e45['type']&&(_0x1dc649=Array['from'](_0x3b1b3f)[0x0],_0x5eefa8=_0xad7e45['item']['getAttribute']('vid_end')),_0x1dc649&&(_0x517942['set'](_0xc31246,{'userId':_0x1dc649}),_0xe11ea5['set'](_0xc31246,{'userId':_0x1dc649})),_0xc31246==_0x5eefa8&&(_0x1dc649=null,_0x5eefa8=null);}}const _0x22e1a1={},_0xcaa8f7=new Set();for(const _0xd6eff of _0x3ee65b){const _0x31bc05=_0x1e4185['deletions'][_0xd6eff],_0x4a3c69=_0x1e4185['insertions'][_0xd6eff];for(const {userId:_0x27730a}of this['_touchedMarkers']['values']())null!==_0x27730a&&_0xcaa8f7['add'](_0x27730a);for(const {userId:_0x4e3642}of this['_touchedRoots']['values']())null!==_0x4e3642&&_0xcaa8f7['add'](_0x4e3642);this['_markChanges'](_0x4a3c69,_0x39c24a['insertions'][_0xd6eff],_0xe11ea5,'insertion',_0xcaa8f7),this['_markChanges'](_0x31bc05,_0x39c24a['deletions'][_0xd6eff],_0x517942,'deletion',_0xcaa8f7),_0x22e1a1[_0xd6eff]={'insertions':this['_prepareViewToSave'](_0x4a3c69),'deletions':this['_prepareViewToSave'](_0x31bc05),'attachChange':this['_touchedRoots']['get'](_0xd6eff)||null,'attributesBefore':_0x8c5550(this['_baseRootsAttributes']['get'](_0xd6eff))||{},'attributesAfter':_0x8c5550(this['_diffRootsAttributes']['get'](_0xd6eff)),'rootElementName':_0x21a4e7['get'](_0xd6eff)};}return{'diffData':_0x22e1a1,'authorsIds':Array['from'](_0xcaa8f7)};}['_processRootBeforeSave'](_0x4d42fe){for(const [,_0x4472c6]of _0x4d42fe['markers']){const _0x2a1b6d=_0x4472c6['start']['getAncestors']()['filter'](_0x32e81b=>'tableCell'==_0x32e81b['name']);for(const _0x35a162 of _0x2a1b6d)0x1==_0x35a162['childCount']&&_0x35a162['getChild'](0x0)['is']('element','paragraph')&&_0x35a162['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x5c6af6){this['_processRootBeforeSave'](_0x5c6af6);const _0x2ba76a=this['editor']['data']['toView'](_0x5c6af6,{}),_0x81cd09=Array['from'](_0x2ba76a['getChildren']())['map'](_0x24127b=>this['_getViewJson'](_0x24127b));return JSON['stringify'](_0x81cd09);}['_getViewJson'](_0x4723a9){if(_0x4723a9['is']('$text'))return _0x4723a9['data'];{const _0x3970a2=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0x517df2=_0x4723a9,_0x4123fe=this['editor']['data']['htmlProcessor']['domConverter'],_0x17b8ec={'type':_0x3970a2['_getTypeCharForViewElement'](_0x517df2),'name':_0x517df2['name'],'attributes':Array['from'](_0x517df2['getAttributes']()),'children':Array['from'](_0x517df2['getChildren']())['map'](_0x469e84=>this['_getViewJson'](_0x469e84))};if(_0x4723a9['is']('uiElement')&&'$comment'!=_0x4723a9['name']){const _0x52c1b8=_0x4723a9['render'](_0x4123fe['domDocument'],_0x4123fe);_0x17b8ec['children']['push'](_0x52c1b8['outerHTML']);}else{if(_0x4723a9['is']('rawElement')){const _0x3cb671=_0x4123fe['domDocument']['createElement'](_0x517df2['name']);_0x4723a9['render'](_0x3cb671,_0x4123fe),_0x17b8ec['children']['push'](_0x3cb671['innerHTML']);}}const _0x415623=Array['from'](_0x517df2['getCustomProperties']());_0x415623['length']>0x0&&(_0x17b8ec['customProperties']=_0x415623);const _0x1bc014=_0x517df2['getFillerOffset']();return null!==_0x1bc014&&(_0x17b8ec['fillerOffset']=_0x1bc014),_0x17b8ec;}}['_markChanges'](_0x5850af,_0x3eae41,_0x35197e,_0x2c421c,_0x30f1b4){let _0x4e52a7=null,_0x54b41d=null,_0x2b4d0a=0x0;const _0x28f694=this['editor']['model'];for(let _0x374f70=0x0;_0x374f70<_0x3eae41['length'];_0x374f70++){const _0x5dfde2=this['_getVidAttributeName'](_0x3eae41[_0x374f70]),_0xe52493=_0x3eae41[_0x374f70]['item']['getAttribute'](_0x5dfde2),_0x4069e5=_0x35197e['get'](_0xe52493),_0x47d802=_0x374f70==_0x3eae41['length']-0x1;(!_0x4e52a7&&_0x4069e5&&(_0x4e52a7=_0x4069e5,_0x54b41d=_0x3eae41[_0x374f70]),_0x4e52a7&&(!_0x4069e5||_0x4069e5['userId']!=_0x4e52a7['userId']))&&(_0x36f0a7(_0x4069e5,mt(_0x54b41d,_0x5850af,_0x28f694),mt(_0x3eae41[_0x374f70],_0x5850af,_0x28f694)),_0x4e52a7=_0x4069e5||null,_0x54b41d=_0x4069e5?_0x3eae41[_0x374f70]:null),_0x4e52a7&&_0x47d802&&_0x36f0a7(_0x4069e5,mt(_0x54b41d,_0x5850af,_0x28f694),pt(_0x3eae41[_0x374f70],_0x5850af,_0x28f694));}function _0x36f0a7(_0x50243e,_0x4345de,_0x3e580c){const _0x55b49=_0x4e52a7['userId'],_0x1344ae='revision:'+_0x2c421c+':'+_0x55b49+':'+_0x2b4d0a++,_0x42d8df=_0x28f694['createRange'](_0x4345de,_0x3e580c);_0x5850af['markers']['set'](_0x1344ae,_0x42d8df),null!==_0x55b49&&_0x30f1b4['add'](_0x55b49);}}['_getVidAttributeName'](_0x46068d){switch(_0x46068d['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x12cf26,_0x38bb9e){_0x12cf26['baseVersion']=null;for(const _0x16d468 in _0x12cf26){const _0x34a8ae=_0x12cf26[_0x16d468];if(_0x34a8ae instanceof _0x10f6fa){const _0x1678ed=_0x38bb9e['get'](_0x34a8ae['root']['rootName']);_0x12cf26[_0x16d468]=this['_fixPosition'](_0x34a8ae,_0x1678ed);}if(_0x34a8ae instanceof _0xa8802c){const _0x4065d7=_0x38bb9e['get'](_0x34a8ae['root']['rootName']);_0x12cf26[_0x16d468]=this['_fixRange'](_0x34a8ae,_0x4065d7);}'root'===_0x16d468&&(_0x12cf26['root']=_0x38bb9e['get'](_0x12cf26['root']['rootName']));}}['_fixRange'](_0x22c10a,_0x28db87){return this['editor']['model']['createRange'](this['_fixPosition'](_0x22c10a['start'],_0x28db87),this['_fixPosition'](_0x22c10a['end'],_0x28db87));}['_fixPosition'](_0x1dab09,_0x3d987a){return this['editor']['model']['createPositionFromPath'](_0x3d987a,_0x1dab09['path'],_0x1dab09['stickiness']);}['_handleInsertOperation'](_0x15e7c2){const _0x5511fb=this['_idsRoots']['get'](_0x15e7c2['position']['root']['rootName']),_0x21d529=this['_fixPosition'](_0x15e7c2['position'],_0x5511fb),_0x9e9774=null===_0x15e7c2['_authorId']?null:_0x15e7c2['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x3ab51c=_0x21d529['parent'],_0xd16ecc=this['_revisionId'],_0x4521d7=[];for(const _0xd4730f of _0x15e7c2['nodes'])if(_0xd4730f['is']('element'))_0x4521d7['push'](this['_makeIdsRoot'](_0xd4730f));else{for(let _0x3cea2e=0x0;_0x3cea2e<_0xd4730f['offsetSize'];_0x3cea2e++)_0x4521d7['push'](new _0x46d26f('$text',{'vid':this['_revisionId']++}));}const _0xa5968c=this['_revisionId'];for(let _0x3010f3=_0xd16ecc;_0x3010f3<_0xa5968c;_0x3010f3++)this['_touched']['set'](_0x3010f3,{'userId':_0x9e9774});_0x3ab51c['_insertChild'](_0x21d529['offset'],_0x4521d7);}['_handleMoveOperation'](_0x41fd63){(_0x41fd63=this['_cloneOperation'](_0x41fd63,this['_idsRoots']))['_execute']();const _0xb4d941=null===_0x41fd63['_authorId']?null:_0x41fd63['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x4bb2c9=_0x41fd63['getMovedRangeStart'](),_0x40c354=_0x4bb2c9['parent'],_0x4fc2dd=_0x4bb2c9['offset'];!function _0xd00e9c(_0x26143d,_0x3128cc,_0x2384b0,_0x4778db){for(let _0xaf4fca=_0x2384b0;_0xaf4fca<_0x4778db;_0xaf4fca++){const _0x3b2859=_0x3128cc['getChild'](_0xaf4fca);_0x3b2859['is']('element','$text')?_0x26143d['set'](_0x3b2859['getAttribute']('vid'),{'userId':_0xb4d941}):(_0x26143d['set'](_0x3b2859['getAttribute']('vid_start'),{'userId':_0xb4d941}),_0xd00e9c(_0x26143d,_0x3b2859,0x0,_0x3b2859['childCount']),_0x26143d['set'](_0x3b2859['getAttribute']('vid_end'),{'userId':_0xb4d941}));}}(this['_touched'],_0x40c354,_0x4fc2dd,_0x4fc2dd+_0x41fd63['howMany']);}['_handleMergeOperation'](_0x3ba458){const _0x5e020f=null===(_0x3ba458=this['_cloneOperation'](_0x3ba458,this['_idsRoots']))['_authorId']?null:_0x3ba458['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x3c7e0a=_0x3ba458['targetPosition']['parent'],_0x3f042f=_0x3ba458['sourcePosition']['parent'],_0x441931=_0x3c7e0a['getAttribute']('vid_end'),_0x584552=_0x3f042f['getAttribute']('vid_start');_0x3c7e0a['_setAttribute']('vid_end',_0x3f042f['getAttribute']('vid_end')),_0x3f042f['_setAttribute']('vid_end',_0x441931),this['_touched']['set'](_0x584552,{'userId':_0x5e020f}),this['_touched']['set'](_0x441931,{'userId':_0x5e020f}),_0x3ba458['_execute']();}['_handleSplitOperation'](_0x180775){const _0x46bd48=null===(_0x180775=this['_cloneOperation'](_0x180775,this['_idsRoots']))['_authorId']?null:_0x180775['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x414665=_0x180775['graveyardPosition'],_0x5f3f48=_0x180775['splitPosition']['parent'];_0x180775['_execute']();const _0x566450=_0x5f3f48['getAttribute']('vid_end'),_0x5020eb=_0x180775['insertionPosition']['nodeAfter'];if(_0x414665){const _0x4fdc97=_0x5020eb['getAttribute']('vid_end'),_0x22afc5=_0x5f3f48['getAttribute']('vid_end');_0x5f3f48['_setAttribute']('vid_end',_0x4fdc97),_0x5020eb['_setAttribute']('vid_end',_0x22afc5),this['_touched']['set'](_0x5f3f48['getAttribute']('vid_end'),{'userId':_0x46bd48}),this['_touched']['set'](_0x5020eb['getAttribute']('vid_start'),{'userId':_0x46bd48});}else{const _0x28ca35=this['_revisionId']++,_0x10808f=this['_revisionId']++;_0x5f3f48['_setAttribute']('vid_end',_0x28ca35),_0x5020eb['_setAttribute']('vid_start',_0x10808f),_0x5020eb['_setAttribute']('vid_end',_0x566450),this['_touched']['set'](_0x28ca35,{'userId':_0x46bd48}),this['_touched']['set'](_0x10808f,{'userId':_0x46bd48});}}['_handleMarkerOperation'](_0x4d5f2c){if(!_0x4d5f2c['affectsData'])return;const _0x25fe3c=(_0x4d5f2c=this['_cloneOperation'](_0x4d5f2c,this['_diffRoots']))['oldRange']?_0x4d5f2c['oldRange']['root']:null,_0x4ea0f1=_0x4d5f2c['newRange']?_0x4d5f2c['newRange']['root']:null;_0x25fe3c&&this['_markers']['delete'](_0x4d5f2c['name']),_0x4ea0f1&&this['_markers']['set'](_0x4d5f2c['name'],_0x4d5f2c['newRange']['clone']());const _0x5e25b0=null===_0x4d5f2c['_authorId']?null:_0x4d5f2c['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x36a9c4=_0x4d5f2c['name'];if(!this['_touchedMarkers']['has'](_0x36a9c4))return void this['_touchedMarkers']['set'](_0x36a9c4,{'range':_0x4d5f2c['oldRange'],'userId':_0x5e25b0});const _0x5ee2df=this['_touchedMarkers']['get'](_0x36a9c4),_0x5b806f=_0x5ee2df['range'],_0x3e57db=_0x4d5f2c['newRange'];null==_0x5b806f&&null==_0x3e57db||_0x5b806f&&_0x3e57db&&_0x5b806f['isEqual'](_0x3e57db)?this['_touchedMarkers']['delete'](_0x4d5f2c['name']):_0x5ee2df['userId']=_0x5e25b0;}['_handleRootOperation'](_0x29a9e2,_0x37652){this['_diffRoots']['has'](_0x29a9e2['rootName'])?this['_diffRoots']['get'](_0x29a9e2['rootName'])['_isAttached']=_0x29a9e2['isAdd']:(this['_diffRoots']['set'](_0x29a9e2['rootName'],wt(_0x29a9e2['rootName'],_0x29a9e2['elementName'],!0x0)),this['_diffRootsAttributes']['set'](_0x29a9e2['rootName'],{}),_0x37652&&this['_idsRoots']['set'](_0x29a9e2['rootName'],wt(_0x29a9e2['rootName'],_0x29a9e2['elementName'],!0x0)));const _0x1bde0f=null===_0x29a9e2['_authorId']?null:_0x29a9e2['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x31661c=this['_touchedRoots']['get'](_0x29a9e2['rootName']);_0x31661c&&_0x31661c['userId']===_0x1bde0f?this['_touchedRoots']['delete'](_0x29a9e2['rootName']):this['_touchedRoots']['set'](_0x29a9e2['rootName'],{'userId':_0x1bde0f,'isAttached':_0x29a9e2['isAdd']});}['_handleRootAttributeOperation'](_0x482cd0){const _0x53a3c7=this['_diffRootsAttributes']['get'](_0x482cd0['root']['rootName']);null===_0x482cd0['newValue']?delete _0x53a3c7[_0x482cd0['key']]:_0x53a3c7[_0x482cd0['key']]=_0x482cd0['newValue'];}}function gt(_0x5b7250){const _0x6e69ca=wt(_0x5b7250['rootName'],_0x5b7250['name'],_0x5b7250['isAttached']());for(const _0xe954d5 of _0x5b7250['getChildren']()){const _0x279586=_0xe954d5['_clone'](!0x0);_0x6e69ca['_appendChild'](_0x279586);}return _0x6e69ca;}function wt(_0x5cfaa0,_0x3ffb37,_0x4de986=!0x0){const _0x5301ff=new _0x59fcbe();return _0x5301ff['rootName']=_0x5cfaa0,_0x5301ff['name']=_0x3ffb37,_0x5301ff['_isAttached']=_0x4de986,_0x5301ff['isAttached']=()=>_0x5301ff['_isAttached'],_0x5301ff;}function mt(_0x5a0253,_0x58073d,_0x478435){const _0x5bea26='elementEnd'==_0x5a0253['type']?_0x478435['createPositionAt'](_0x5a0253['item'],'end'):_0x478435['createPositionBefore'](_0x5a0253['item']);return _0x478435['createPositionFromPath'](_0x58073d,_0x5bea26['path'],_0x5bea26['stickiness']);}function pt(_0xd0b542,_0x413ef8,_0x51d605){const _0xc66955='elementStart'==_0xd0b542['type']?_0x51d605['createPositionAt'](_0xd0b542['item'],0x0):_0x51d605['createPositionAfter'](_0xd0b542['item']);return _0x51d605['createPositionFromPath'](_0x413ef8,_0xc66955['path'],_0xc66955['stickiness']);}class RevisionHistorySaveRevisionFormView extends/* #__PURE__ -- @preserve */
|
|
25
|
+
_0x151f05(_0xafec90){['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0xfe7fa8,_0x339212){super(_0xfe7fa8),this['focusTracker']=new _0x28ca2c(),this['keystrokes']=new _0x2f638f(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x339212),this['setTemplate']({'tag':'form','attributes':{'class':['ck','ck-revision-history-save-revision-form','ck-responsive-form'],'tabindex':'-1'},'children':[this['revisionNameInputView']]}),this['initializeCssTransitionDisablerMixin']();}['render'](){super['render'](),_0x33eb0a({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x26f1e1=_0x3ec8c0=>_0x3ec8c0['stopPropagation']();this['keystrokes']['set']('arrowright',_0x26f1e1),this['keystrokes']['set']('arrowleft',_0x26f1e1),this['keystrokes']['set']('arrowup',_0x26f1e1),this['keystrokes']['set']('arrowdown',_0x26f1e1);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x4d3635){this['revisionNameInputView']['fieldView']['element']['value']=_0x4d3635['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x5890ab){const _0x161b39=new _0x17e56b(this['locale'],_0x238b41),_0x1eb624=_0x161b39['fieldView'];_0x1eb624['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x590dff=ft(this['locale'],'Name\x20of\x20the\x20revision');return!_0x5890ab&&(_0x590dff+='\x20('+ft(this['locale'],'optional')+')'),(_0x161b39['label']=_0x590dff,_0x1eb624['on']('input',()=>{this['revisionNameInputValue']=_0x1eb624['element']['value']['trim']();}),_0x161b39);}}class RevisionHistoryUI extends _0x538071{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[RevisionTracker];}['_saveRevisionFormView'];['init'](){const _0x38749d=this['editor'],_0x28c204=_0x38749d['plugins']['get']('RevisionTracker');_0x38749d['ui']['componentFactory']['add']('revisionHistory',_0x3cbb7c=>{const _0x3378a2=_0x182132(_0x3cbb7c),_0x46b311=_0x3378a2['panelView']['children'],_0x5cfb71=new _0x44c12a(_0x3cbb7c),_0x57f7bb=new _0x4582a8(_0x3cbb7c),_0x17e2b8=this['_createSaveRevisionButton'](_0x135801),_0x168889=new _0x4582a8(_0x3cbb7c),_0x1aec2b=this['_createOpenRevisionButton'](_0x135801);return _0x3378a2['bind']('isEnabled')['to'](_0x28c204,'isReady',_0x28c204,'isEnabled',_0x38749d,'isReadOnly',(_0x3a8b78,_0x280dc1,_0x2c94fa)=>_0x3a8b78&&_0x280dc1&&!_0x2c94fa),_0x3378a2['buttonView']['set']({'icon':_0x5ea9e8,'label':ft(_0x3cbb7c,'Revision\x20history'),'tooltip':!0x0}),_0x17e2b8['set']({'withText':!0x0,'role':'menuitem'}),_0x1aec2b['set']({'withText':!0x0,'role':'menuitem'}),this['listenTo'](_0x1aec2b,'execute',()=>{_0x3378a2['isOpen']=!0x1,_0x38749d['editing']['view']['focus']();},{'priority':'low'}),_0x57f7bb['children']['add'](_0x17e2b8),_0x168889['children']['add'](_0x1aec2b),_0x5cfb71['role']='menu',_0x5cfb71['items']['addMany']([_0x57f7bb,_0x168889]),_0x46b311['add'](_0x5cfb71),_0x3378a2;}),_0x38749d['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x4f0c61=this['editor'],_0x453a89=_0x4f0c61['locale'],_0x453312=_0x4f0c61['plugins']['get']('RevisionTracker'),_0x896a83=new _0x48deab(_0x453a89),_0x593d62=new _0x41b7d1(_0x453a89);_0x896a83['bind']('isEnabled')['to'](_0x453312,'isReady',_0x453312,'isEnabled',_0x4f0c61,'isReadOnly',(_0x471ca6,_0x3f96a0,_0x4d4944)=>_0x471ca6&&_0x3f96a0&&!_0x4d4944),_0x896a83['buttonView']['set']({'icon':_0x5ea9e8,'label':ft(_0x453a89,'Revision\x20history')});const _0x2608c4=new tt(_0x453a89,_0x896a83),_0x495459=this['_createSaveRevisionButton'](it);_0x495459['delegate']('execute')['to'](_0x896a83),_0x2608c4['children']['add'](_0x495459),_0x593d62['items']['add'](_0x2608c4);const _0x1eb7eb=new tt(_0x453a89,_0x896a83),_0x271a18=this['_createOpenRevisionButton'](it);return _0x271a18['delegate']('execute')['to'](_0x896a83),_0x1eb7eb['children']['add'](_0x271a18),_0x593d62['items']['add'](_0x1eb7eb),_0x896a83['panelView']['children']['add'](_0x593d62),_0x896a83;}['_createSaveRevisionButton'](_0x5398a5){const _0x4a5261=this['editor'],_0x3534d4=_0x4a5261['plugins']['get']('RevisionTracker'),_0x2315b6=new _0x5398a5(_0x4a5261['locale']);return _0x2315b6['set']({'label':ft(_0x4a5261['locale'],'Save\x20current\x20revision')}),_0x2315b6['bind']('isEnabled')['to'](_0x3534d4,'isReady',_0x3534d4,'isEnabled',_0x4a5261,'isReadOnly',(_0x95cec3,_0x2c45f1,_0x2e4e40)=>_0x95cec3&&_0x2c45f1&&!_0x2e4e40),this['listenTo'](_0x2315b6,'execute',()=>{this['_showDialog']();}),_0x2315b6;}['_createOpenRevisionButton'](_0x10ddf7){const _0xbdf08=this['editor'],_0x1baffd=_0xbdf08['plugins']['get']('RevisionTracker'),_0x552029=new _0x10ddf7(_0xbdf08['locale']);return _0x552029['set']({'label':ft(_0xbdf08['locale'],'Open\x20revision\x20history')}),_0x552029['bind']('isEnabled')['to'](_0x1baffd,'isReady',_0xbdf08,'isReadOnly',(_0x284df5,_0x76b3bf)=>_0x284df5&&!_0x76b3bf),this['listenTo'](_0x552029,'execute',()=>{_0xbdf08['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x552029;}['_showDialog'](){const _0x3f0b7b=this['editor'],_0x31111e=_0x3f0b7b['locale'],_0x39f321=_0x3f0b7b['plugins']['get']('Dialog'),_0x1583e2=_0x3f0b7b['plugins']['get']('RevisionTracker');function _0x182f40(_0x248563){_0x3f0b7b['config']['get']('revisionHistory.requireRevisionName')&&''===_0x248563['revisionName']?_0x248563['revisionNameInputView']['errorText']=ft(_0x31111e,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x3f0b7b['plugins']['get'](RevisionTracker)['saveRevision']({'name':_0x248563['revisionName']}),_0x39f321['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x182f40(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x39f321['show']({'id':'revisionSave','title':ft(_0x31111e,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':ft(_0x3f0b7b['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x39f321['hide']()},{'label':ft(_0x3f0b7b['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x287ee1){_0x287ee1['bind']('isEnabled')['to'](_0x1583e2,'isReady',_0x1583e2,'isEnabled',_0x3f0b7b,'isReadOnly',(_0x3874b8,_0x925459,_0x5e95f3)=>_0x3874b8&&_0x925459&&!_0x5e95f3);},'onExecute':()=>_0x182f40(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0xfd874e=this['editor'],_0x3870b5=_0xfd874e['locale'];this['_saveRevisionFormView']=new RevisionHistorySaveRevisionFormView(_0x3870b5,_0xfd874e['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class ChangeDetailsView extends _0xafec90{['changeId'];['_model'];constructor(_0x443e51,_0x59f26b){super(_0x443e51),this['_model']=_0x59f26b,this['changeId']=_0x59f26b['id'];const _0x7e2ecb=this['bindTemplate'],_0x1757e6=ft(_0x443e51,_0x59f26b['data']['isSuggestion']?'Suggested\x20by':'add'==_0x59f26b['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x59f26b['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x7e2ecb['to']('type',_0x18732f=>'ck-revision-change__'+_0x18732f)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x1757e6}]},{'text':'\x20'+_0x59f26b['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class ChangeItem extends/* #__PURE__ -- @preserve */
|
|
26
|
+
_0xf684e0(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x37dd15){super(),this['id']=_0x37dd15['id']||_0x51ceb2(),this['author']=_0x37dd15['author'],this['type']=_0x37dd15['type'],this['data']=_0x37dd15['data']||{},this['rootName']=_0x37dd15['rootName'],this['set']('createdAt',_0x37dd15['createdAt']);}['toJSON'](){return{'id':this['id'],'authorId':this['author']['id'],'type':this['type'],'data':this['data'],'createdAt':this['createdAt']};}}class RevisionDiff{['newRevisionId'];['oldRevisionId'];['changes'];constructor(_0x3029fd,_0x28b2cc){this['newRevisionId']=_0x3029fd,this['oldRevisionId']=_0x28b2cc,this['changes']=new _0x3625c9();}['_setChanges'](_0x134fe2){for(const _0x405e3d of _0x134fe2)this['changes']['add'](_0x405e3d);}}class RevisionViewer extends _0x538071{['repository'];['adapter']=null;['_utils'];['_activeViewTarget'];['_changeView'];['_changeIdToChange'];['_balloon'];static get['pluginName'](){return'RevisionViewer';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[_0x2baa1d,et,RevisionsRepository,RevisionHistoryUtils];}constructor(_0x1f6b81){super(_0x1f6b81),this['repository']=this['editor']['plugins']['get']('RevisionsRepository'),this['_utils']=this['editor']['plugins']['get']('RevisionHistoryUtils'),this['set']('activeChange',null),this['set']('activeView',null),this['_activeViewTarget']=null,this['set']('diff',null),this['set']('isReady',!0x1),this['set']('isEnabled',!0x0),this['on']('change:isEnabled',(_0x2e70a3,_0x44c010,_0x48f2ea)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x8940e5=>{for(const _0x19b166 of this['editor']['editing']['view']['document']['roots'])_0x48f2ea?_0x8940e5['removeClass']('ck-editor__editable__overlay',_0x19b166):_0x8940e5['addClass']('ck-editor__editable__overlay',_0x19b166);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x1b2c12=>null!==_0x1b2c12),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x5cb3da,_0xa89e5c,_0x3022cf)=>_0x5cb3da&&_0x3022cf?_0xa89e5c['changes']['getIndex'](_0x3022cf):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x44925d,_0xe3fdb3)=>_0x44925d?_0xe3fdb3['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](et);}['init'](){const _0x13e5eb=this['editor'],_0x25d4a2=new ShowChangeCommand(_0x13e5eb,{'direction':'backward'}),_0x310e10=new ShowChangeCommand(_0x13e5eb,{'direction':'forward'});(_0x13e5eb['commands']['add']('showPreviousChange',_0x25d4a2),_0x13e5eb['commands']['add']('showNextChange',_0x310e10),_0x13e5eb['commands']['add']('restoreRevision',new RestoreRevisionCommand(_0x13e5eb)),this['on']('change:numberOfChanges',()=>{_0x25d4a2['refresh'](),_0x310e10['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x13e5eb['enableReadOnlyMode']('revision-viewer'),_0x13e5eb['plugins']['has']('WidgetToolbarRepository'))&&_0x13e5eb['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x4815ad){return await this['_utils']['loadRevisionData'](_0x4815ad,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x4815ad);}async['getRevisionRootsAttributes'](_0x250cc2){return await this['_utils']['loadRevisionData'](_0x250cc2,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x250cc2);}async['compare'](_0x4af679,_0x2df7c2,_0x5747a4=!0x1){if(!this['isEnabled'])return;const _0x14688f=this['diff'],_0x1138f5=this['repository'],_0x35aa88='string'==typeof _0x4af679?_0x1138f5['getRevision'](_0x4af679):_0x4af679,_0x588858='string'==typeof _0x2df7c2?_0x1138f5['getRevision'](_0x2df7c2):_0x2df7c2,_0x4e156b=_0x35aa88['id'],_0x342c79=_0x588858?_0x588858['id']:null;if(!_0x5747a4&&this['diff']&&this['diff']['newRevisionId']===_0x4e156b&&this['diff']['oldRevisionId']===_0x342c79)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new RevisionDiff(_0x4e156b,_0x342c79);const _0x474d5d=this['_getRevisionsRange'](_0x35aa88,_0x588858,!0x0)['map'](_0x22c3bc=>this['_utils']['loadRevisionData'](_0x22c3bc,this['adapter']));return _0x474d5d['push'](new Promise(_0xa5bdad=>{setTimeout(_0xa5bdad,0x14);})),Promise['all'](_0x474d5d)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x17d443=this['_getDiff'](_0x4e156b,_0x342c79);for(const _0x360094 of _0x17d443['changes'])this['_changeIdToChange']['set'](_0x360094['id'],_0x360094);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x5835cd=>{for(const _0xb8cba5 of this['editor']['model']['document']['getRootNames']())_0x5835cd['detachRoot'](_0xb8cba5);for(const _0x568b63 of Object['keys'](_0x17d443['model'])){const _0x158d70=_0x17d443['model'][_0x568b63]['name'],_0x578e8d=_0x5835cd['addRoot'](_0x568b63,_0x158d70);for(const _0x102a85 of Object['keys'](_0x17d443['attributes'][_0x568b63]))_0x5835cd['setAttribute'](_0x102a85,_0x17d443['attributes'][_0x568b63][_0x102a85],_0x578e8d);_0x5835cd['insert'](_0x17d443['model'][_0x568b63],_0x578e8d,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x17d443['changes'])),this['isReady']=!0x0;})['catch'](_0x7b6451=>{console['error'](_0x7b6451),this['_cleanUp'](),_0x14688f&&(this['diff']=_0x14688f),this['isReady']=!0x0;});}['addRevisionData'](_0x46b69d,_0x507b66){const _0x5b1fe7=this['repository']['createRevision'](_0x46b69d);return _0x5b1fe7['on']('_update',(_0x2384ef,_0x2f9ced,_0x24b795)=>_0x507b66(_0x2f9ced,_0x24b795,_0x5b1fe7)),this['repository']['addRevision'](_0x5b1fe7),_0x5b1fe7;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x439218=>{for(const _0x451e15 of this['editor']['model']['document']['getRootNames']())_0x439218['detachRoot'](_0x451e15);});}['_sortAndFilterDiffChanges'](_0x228591){const _0x2ae375=[],_0xcd331c=new Map();for(const _0x26baf4 of this['editor']['model']['document']['getRootNames']()){const _0x4fb61e=this['editor']['editing']['view']['getDomRoot'](_0x26baf4);if(!_0x4fb61e)continue;const _0x1f20a0=_0x4fb61e['getClientRects']()['item'](0x0);_0x1f20a0&&(_0x2ae375['push'](_0x26baf4),_0xcd331c['set'](_0x26baf4,_0x1f20a0));}return _0x2ae375['sort']((_0x5c7636,_0x37b74a)=>{const _0x41b7b4=_0xcd331c['get'](_0x5c7636),_0x13697c=_0xcd331c['get'](_0x37b74a);return _0x41b7b4['y']-_0x13697c['y']||_0x41b7b4['x']-_0x13697c['x'];}),(_0x228591=_0x228591['filter'](_0x5ed611=>_0x2ae375['includes'](_0x5ed611['rootName'])))['sort']((_0x2392cb,_0x2d3ed0)=>_0x2ae375['indexOf'](_0x2392cb['rootName'])-_0x2ae375['indexOf'](_0x2d3ed0['rootName'])),_0x228591;}['_makeTape'](_0x585f2f){const _0x1cf1ec=Array['from'](_0x585f2f['markers'])['filter'](([_0x2c51ed,_0x5f0504])=>_0x2c51ed['startsWith']('revision:')&&!_0x5f0504['isCollapsed']),_0x506e7=Array['from'](this['editor']['model']['createRangeIn'](_0x585f2f)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x1cf1ec['length'])for(const _0x12eafa of _0x506e7){const [_0x349f54,_0x5860b1]=_0x1cf1ec[0x0],[,_0x3da456,_0x56982a]=_0x349f54['split'](':');if(_0x5860b1['end']['isEqual'](_0x12eafa['nextPosition'])&&_0x1cf1ec['shift'](),(_0x12eafa['previousPosition']['isEqual'](_0x5860b1['start'])||_0x12eafa['previousPosition']['isAfter'](_0x5860b1['start']))&&('insertion'==_0x3da456?_0x12eafa['isAdded']={'userId':_0x56982a}:'deletion'==_0x3da456&&(_0x12eafa['isRemoved']={'userId':_0x56982a})),0x0==_0x1cf1ec['length'])break;}return _0x506e7;}['_refreshStartEndIndex'](_0x4884d4){const _0x217dc0=new Map();for(let _0x57d5de=0x0;_0x57d5de<_0x4884d4['length'];_0x57d5de++)'text'===_0x4884d4[_0x57d5de]['type']?(_0x4884d4[_0x57d5de]['item']['startIndex']=_0x57d5de,_0x4884d4[_0x57d5de]['item']['endIndex']=_0x57d5de):('elementStart'===_0x4884d4[_0x57d5de]['type']?_0x4884d4[_0x57d5de]['item']['startIndex']=_0x57d5de:'elementEnd'===_0x4884d4[_0x57d5de]['type']&&(_0x4884d4[_0x57d5de]['item']['endIndex']=_0x57d5de),_0x217dc0['set'](_0x4884d4[_0x57d5de]['id'],_0x57d5de));for(const _0x298dce of _0x217dc0['values']())'elementStart'===_0x4884d4[_0x298dce]['type']?_0x4884d4[_0x298dce]['item']['endIndex']=_0x217dc0['get'](_0x4884d4[_0x298dce]['pairId']):'elementEnd'===_0x4884d4[_0x298dce]['type']&&(_0x4884d4[_0x298dce]['item']['startIndex']=_0x217dc0['get'](_0x4884d4[_0x298dce]['pairId']));}['_processTape'](_0x193b02){for(let _0x562603=0x0;_0x562603<_0x193b02['length'];_0x562603++){if('elementStart'===_0x193b02[_0x562603]['type'])_0x193b02[_0x562603]['item']['startIndex']=_0x562603;else{if('elementEnd'===_0x193b02[_0x562603]['type']){_0x193b02[_0x562603]['item']['endIndex']=_0x562603;const _0x5af6f2=_0x193b02[_0x562603]['item']['startIndex'];_0x193b02[_0x5af6f2]['pairId']=_0x193b02[_0x562603]['id'],_0x193b02[_0x562603]['pairId']=_0x193b02[_0x5af6f2]['id'];}else _0x193b02[_0x562603]['item']['startIndex']=_0x562603,_0x193b02[_0x562603]['item']['endIndex']=_0x562603,_0x193b02[_0x562603]['pairId']=null;}_0x193b02[_0x562603]['markersStart']||(_0x193b02[_0x562603]['markersStart']=[],_0x193b02[_0x562603]['markersEnd']=[]);}}['_markInsertions'](_0x2c16d4,_0x21d65c){const _0x5adc1d=_0x2c16d4['filter'](_0x57b230=>!_0x57b230['isAdded']);for(let _0x17b966=0x0;_0x17b966<_0x21d65c['length'];_0x17b966++)_0x21d65c[_0x17b966]['isAdded']&&(_0x5adc1d[_0x17b966]['isAdded']=_0x21d65c[_0x17b966]['isAdded']);}['_getDiff'](_0x24654d,_0x2513c7=null){const _0x132981=this['repository']['getRevision'](_0x24654d),_0x29e9e3=_0x2513c7?this['repository']['getRevision'](_0x2513c7):null,_0x479c93=this['_getRevisionsRange'](_0x132981,_0x29e9e3),_0x451e3f=_0x479c93[_0x479c93['length']-0x1],_0x498bb6=new Map(),_0x4602b={'model':{},'attributes':{},'changes':[]},_0x484ac1=new Set(),_0x11d5c0=new Map();for(let _0x75bee4=_0x479c93['length']-0x1;_0x75bee4>=0x0;_0x75bee4--){const _0x44d253=_0x479c93[_0x75bee4];for(const _0x226559 of Object['keys'](_0x44d253['diffData']))if(_0x44d253['diffData'][_0x226559]['attachChange']){const _0x2daa82=_0x44d253['diffData'][_0x226559]['attachChange'];_0x2daa82['isAttached']?(_0x484ac1['add'](_0x226559),_0x11d5c0['has'](_0x226559)&&_0x11d5c0['get'](_0x226559)['userId']==_0x2daa82['userId']?_0x11d5c0['delete'](_0x226559):_0x11d5c0['set'](_0x226559,_0x2daa82)):_0x11d5c0['has'](_0x226559)?(_0x484ac1['delete'](_0x226559),_0x11d5c0['delete'](_0x226559)):(_0x484ac1['add'](_0x226559),_0x11d5c0['set'](_0x226559,_0x2daa82));}else _0x484ac1['add'](_0x226559);}for(const _0x6b1811 of _0x484ac1){const _0x1c2c98=_0x11d5c0['has'](_0x6b1811)&&!_0x11d5c0['get'](_0x6b1811)['isAttached'];let _0x56b2c3=_0x1c2c98?_0x479c93['length']-0x1:0x0;const _0x2e0135=_0x1c2c98?-0x1:0x1;for(;_0x479c93[_0x56b2c3];){const _0x19fe49=_0x479c93[_0x56b2c3];if(_0x19fe49['diffData'][_0x6b1811]){const _0xbe2521=_0x1c2c98?_0x19fe49['diffData'][_0x6b1811]['attributesBefore']:_0x19fe49['diffData'][_0x6b1811]['attributesAfter'];_0x4602b['attributes'][_0x6b1811]=_0xbe2521?_0x8c5550(_0xbe2521):{};break;}_0x56b2c3+=_0x2e0135;}}for(const _0x44761b of _0x479c93){_0x44761b['model']={};for(const _0x11c5d4 of _0x44761b['authors'])_0x498bb6['set'](_0x11c5d4['id'],_0x11c5d4);for(const _0x19ed31 of _0x484ac1){const _0x4c14b7=_0x44761b['diffData'][_0x19ed31]?_0x44761b['diffData'][_0x19ed31]['insertions']:'[]',_0x345575=_0x44761b['diffData'][_0x19ed31]?_0x44761b['diffData'][_0x19ed31]['deletions']:'[]',_0x34c947=_0x44761b['diffData'][_0x19ed31]?.['rootElementName']||'$root';_0x44761b['model'][_0x19ed31]={'insertions':this['_utils']['_makeModelFromViewString'](_0x4c14b7,_0x34c947),'deletions':this['_utils']['_makeModelFromViewString'](_0x345575,_0x34c947)};}}for(const _0x4e0e14 of _0x484ac1){let _0x4c5c6e=null,_0x101c51=0x0;const _0x12fd16=_0x479c93['map'](_0x81b411=>_0x81b411['diffData'][_0x4e0e14]?.['rootElementName'])['find'](_0x5ae716=>void 0x0!==_0x5ae716)||'$root',_0x11e7cc=new Map(Array['from'](_0x132981['model'][_0x4e0e14]['insertions']['markers'])['filter'](([_0x3ea4c2])=>!_0x3ea4c2['startsWith']('revision:')));let _0x1ee92f=0x0;for(const _0x38f7b9 of _0x479c93){const _0xb67f69=this['_makeTape'](_0x38f7b9['model'][_0x4e0e14]['insertions']);_0x38f7b9==_0x132981?(_0x4c5c6e=_0xb67f69,_0x101c51=_0x4c5c6e['length'],_0x4c5c6e['forEach'](_0x12298a=>{_0x12298a['id']=_0x1ee92f++;}),this['_processTape'](_0x4c5c6e)):this['_markInsertions'](_0x4c5c6e,_0xb67f69);const _0xd2c30c=_0x4c5c6e['filter'](_0x352f6d=>!_0x352f6d['isAdded'])['map'](_0x45d26f=>_0x45d26f['id']);let _0x43dba3=0x0;const _0x572f28=this['_makeTape'](_0x38f7b9['model'][_0x4e0e14]['deletions']);_0x572f28['forEach'](_0x18a67f=>{_0x18a67f['isRemoved']?_0x18a67f['id']=_0x101c51++:_0x18a67f['id']=_0xd2c30c[_0x43dba3++];}),this['_processTape'](_0x572f28),this['_setDistance'](_0x4c5c6e,'isAdded'),this['_setDistance'](_0x572f28,'isRemoved'),_0x38f7b9==_0x132981&&this['_markMarkers'](_0x4c5c6e,_0x11e7cc),_0x4c5c6e=this['_joinTapes'](_0x4c5c6e,_0x572f28),this['_refreshStartEndIndex'](_0x4c5c6e),this['_setDistance'](_0x4c5c6e,'isRemoved');}_0x4c5c6e=_0x4c5c6e['filter'](_0x252808=>!(_0x252808['isAdded']&&_0x252808['isRemoved']));const _0x4232eb=new Map(_0x451e3f['model'][_0x4e0e14]['deletions']['markers']),_0x8d1a1c=new Set(_0x11e7cc['keys']());for(const _0x27c90b of _0x4232eb['keys']())_0x8d1a1c['delete'](_0x27c90b);this['_markSuggestions'](_0x4c5c6e,_0x8d1a1c),this['_fixObsoleteTags'](_0x4c5c6e),_0x4c5c6e=this['_removeMissingPairs'](_0x4c5c6e),_0x4c5c6e=this['_markMismatchedRemovedTags'](_0x4c5c6e),_0x4c5c6e=this['_removeUnsupportedChanges'](_0x4c5c6e);const {root:_0x4ca19a,changes:_0x1fea3e}=this['_makeModelFromTape'](_0x4c5c6e,_0x498bb6,_0x4e0e14,_0x12fd16);_0x4602b['model'][_0x4e0e14]=_0x4ca19a;const _0x103ef3=_0x11d5c0['get'](_0x4e0e14);if(_0x103ef3){const _0x271619=_0x498bb6['get'](_0x103ef3['userId']),_0x1c7939=new ChangeItem({'author':_0x271619,'type':_0x103ef3['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x4e0e14});_0x1fea3e['unshift'](_0x1c7939),_0x4602b['attributes'][_0x4e0e14]['revisionHistoryAttachChange']=_0x1c7939['id'];}_0x4602b['changes']=_0x4602b['changes']['concat'](_0x1fea3e);}return _0x4602b;}['_markMarkers'](_0x1f23fd,_0x49ed24){for(let _0xa0bf4c=0x0;_0xa0bf4c<_0x1f23fd['length'];_0xa0bf4c++)for(const [_0xf257f,_0x4ba272]of _0x49ed24)!_0x4ba272['isCollapsed']&&_0x4ba272['start']['isEqual'](_0x1f23fd[_0xa0bf4c]['previousPosition'])&&_0x1f23fd[_0xa0bf4c]['markersStart']['push'](_0xf257f),_0x4ba272['end']['isEqual'](_0x1f23fd[_0xa0bf4c]['nextPosition'])&&_0x1f23fd[_0xa0bf4c]['markersEnd']['push'](_0xf257f);}['_joinTapes'](_0x55c82b,_0x38ba99){let _0x3caae1=[],_0x14217f=0x0,_0x1160ee=0x0;for(;_0x14217f<_0x55c82b['length']||_0x1160ee<_0x38ba99['length'];){const _0x387726=_0x55c82b[_0x14217f]||{},_0x56df7f=_0x38ba99[_0x1160ee]||{};if(_0x387726['id']==_0x56df7f['id'])_0x14217f++,_0x1160ee++,_0x3caae1['push'](_0x387726);else{if(_0x56df7f['isRemoved']&&_0x387726['isAdded']){const {commonTape:_0x24aed7,iEnd:_0x534b36,jEnd:_0xc21037}=this['_threeWayMerge'](_0x55c82b,_0x14217f,_0x38ba99,_0x1160ee);_0x3caae1=_0x3caae1['concat'](_0x24aed7),_0x14217f=_0x534b36,_0x1160ee=_0xc21037;}else _0x56df7f['isRemoved']?(_0x1160ee++,_0x3caae1['push'](_0x56df7f)):(_0x14217f++,_0x3caae1['push'](_0x387726));}}return _0x3caae1;}['_markSuggestions'](_0x4c116a,_0x31e591){const _0x26dc55=[];for(let _0x451106=0x0;_0x451106<_0x4c116a['length'];_0x451106++){for(let _0x4cd69b=0x0;_0x4cd69b<_0x4c116a[_0x451106]['markersStart']['length'];_0x4cd69b++){const _0x463e98=_0x4c116a[_0x451106]['markersStart'][_0x4cd69b];if(!_0x31e591['has'](_0x463e98))continue;const {group:_0xed4190,type:_0x2611a1,authorId:_0xc19edd}=_0x36a5b8(_0x463e98);'revision-suggestion'!=_0xed4190||'insertion'!=_0x2611a1&&'deletion'!=_0x2611a1||(_0x26dc55['unshift']({'type':_0x2611a1,'name':_0x463e98,'userId':_0xc19edd}),_0x4c116a[_0x451106]['markersStart']['splice'](_0x4cd69b,0x1),_0x4cd69b--);}_0x49f12d(_0x4c116a[_0x451106]);for(let _0x16a0be=0x0;_0x16a0be<_0x4c116a[_0x451106]['markersEnd']['length'];_0x16a0be++){const _0x311343=_0x4c116a[_0x451106]['markersEnd'][_0x16a0be];if(!_0x31e591['has'](_0x311343))continue;const {group:_0xe621f6,type:_0x556335}=_0x36a5b8(_0x311343);if('revision-suggestion'!=_0xe621f6||'insertion'!=_0x556335&&'deletion'!=_0x556335)continue;_0x4c116a[_0x451106]['markersEnd']['splice'](_0x16a0be,0x1),_0x16a0be--;const _0x48cec3=_0x26dc55['findIndex'](_0x8d9591=>_0x8d9591['name']==_0x311343);_0x48cec3>-0x1&&_0x26dc55['splice'](_0x48cec3,0x1);}}function _0x36a5b8(_0x3d9a1a){const _0x2dfc41=_0x3d9a1a['split'](':');return{'group':_0x2dfc41[0x0],'type':_0x2dfc41[0x1],'subType':_0x2dfc41['length']>=0x5?_0x2dfc41[0x2]:null,'id':_0x2dfc41['length']<0x5?_0x2dfc41[0x2]:_0x2dfc41[0x3],'authorId':_0x2dfc41['length']<0x5?_0x2dfc41[0x3]:_0x2dfc41[0x4],'markerCount':0x6==_0x2dfc41['length']?_0x2dfc41[0x5]:null};}function _0x49f12d(_0x20cb22){for(let _0x552b0e=0x0;_0x552b0e<_0x26dc55['length'];_0x552b0e++){if(_0x20cb22['isAdded']&&'insertion'==_0x26dc55[_0x552b0e]['type']&&_0x20cb22['isAdded']['userId']==_0x26dc55[_0x552b0e]['userId'])return _0x20cb22['isAddSuggestion']=_0x26dc55[_0x552b0e],void delete _0x20cb22['isAdded'];if(!_0x20cb22['isAdded']&&!_0x20cb22['isRemoved']&&'deletion'==_0x26dc55[_0x552b0e]['type'])return void(_0x20cb22['isRemoveSuggestion']=_0x26dc55[_0x552b0e]);}}}['_setDistance'](_0x227e23,_0x1f81b2){let _0x19f6fc=0x0,_0x21efea=!0x1;const _0x4cd35c=new Map();for(const _0x1698c5 of _0x227e23)_0x1698c5[_0x1f81b2]?_0x21efea&&(_0x19f6fc++,_0x21efea=!0x1):(_0x19f6fc++,_0x21efea=!0x0),_0x4cd35c['set'](_0x1698c5['id'],_0x19f6fc);for(let _0x354ae6=0x0;_0x354ae6<_0x227e23['length'];_0x354ae6++){if('isRemoved'==_0x1f81b2&&_0x227e23[_0x354ae6]['isAdded']||'isAdded'==_0x1f81b2&&_0x227e23[_0x354ae6]['isRemoved'])continue;if('text'==_0x227e23[_0x354ae6]['type']){_0x227e23[_0x354ae6]['distance']=0x0;continue;}const _0x1732b8=_0x4cd35c['get'](_0x227e23[_0x354ae6]['pairId']),_0x16557d=_0x4cd35c['get'](_0x227e23[_0x354ae6]['id']);_0x227e23[_0x354ae6]['distance']=_0x1732b8-_0x16557d;}}['_getRevisionsRange'](_0x4d4d1d,_0x51a2f9,_0x2f2b1c=!0x1){const _0x1366ba=[];let _0x3b9789=this['repository']['getIndex'](_0x4d4d1d),_0x5a736f=this['repository']['getIndex'](_0x51a2f9);for(-0x1==_0x5a736f&&(_0x5a736f=this['repository']['_revisions']['length'],_0x2f2b1c=!0x1);_0x3b9789<_0x5a736f;)_0x1366ba['push'](this['repository']['getRevision'](_0x3b9789)),_0x3b9789++;return _0x2f2b1c&&_0x1366ba['push'](this['repository']['getRevision'](_0x3b9789)),_0x1366ba;}['_threeWayMerge'](_0x508ece,_0xef125e,_0x5d45da,_0x2029a0){const _0x6371a1=this['editor']['model']['schema'];let _0x5d745d=_0xef125e;for(;_0x508ece[_0x5d745d]&&_0x508ece[_0x5d745d]['isAdded'];)_0x5d745d++;let _0x240043=_0x2029a0;for(;_0x5d45da[_0x240043]&&_0x5d45da[_0x240043]['isRemoved'];)_0x240043++;_0x2f9b74(_0x508ece,_0xef125e,_0x5d745d),_0x2f9b74(_0x5d45da,_0x2029a0,_0x240043);const _0x1c5872=_0x5d45da['slice'](_0x2029a0,_0x240043)['concat'](_0x508ece['slice'](_0xef125e,_0x5d745d));return _0x1c5872['sort']((_0x92e18b,_0x4d72b1)=>_0x92e18b['side']!=_0x4d72b1['side']?_0x92e18b['side']-_0x4d72b1['side']:_0x92e18b['level']!=_0x4d72b1['level']?_0x92e18b['level']-_0x4d72b1['level']:_0x92e18b['distance']!=_0x4d72b1['distance']?_0x4d72b1['distance']-_0x92e18b['distance']:!!_0x92e18b['isAdded']!=!!_0x4d72b1['isAdded']?-0x1==_0x92e18b['side']||0x0==_0x92e18b['side']?_0x92e18b['isAdded']?-0x1:0x1:_0x92e18b['isAdded']?0x1:-0x1:_0x92e18b['index']-_0x4d72b1['index']),{'commonTape':_0x1c5872,'iEnd':_0x5d745d,'jEnd':_0x240043};function _0x2f9b74(_0x188a7c,_0x578f86,_0x480cb6){let _0x42a372=-0x1,_0x366020=Number['POSITIVE_INFINITY'],_0x51c75f=!0x0;for(let _0x3dfac7=_0x578f86;_0x3dfac7<_0x480cb6;_0x3dfac7++)if(_0x6371a1['isInline'](_0x188a7c[_0x3dfac7]['item'])||(_0x51c75f=!0x1),_0x188a7c[_0x3dfac7]['item']['startIndex']<_0x578f86&&(_0x42a372=_0x3dfac7),_0x188a7c[_0x3dfac7]['item']['endIndex']>=_0x480cb6){_0x366020=_0x3dfac7;break;}_0x51c75f&&(_0x42a372=_0x480cb6-0x1);for(let _0x375afa=_0x578f86;_0x375afa<_0x480cb6;_0x375afa++)_0x188a7c[_0x375afa]['side']=_0x375afa<=_0x42a372?-0x1:_0x375afa<_0x366020?0x0:0x1,_0x188a7c[_0x375afa]['index']=_0x375afa;let _0x46001b=0x0;for(let _0x31db8a=_0x578f86;_0x31db8a<=_0x42a372;_0x31db8a++)0x0==_0x188a7c[_0x31db8a]['distance']?_0x188a7c[_0x31db8a]['level']=_0x46001b:(_0x46001b++,_0x188a7c[_0x31db8a]['level']=_0x46001b,_0x46001b++);for(let _0x115e75=_0x578f86;_0x115e75<_0x480cb6;_0x115e75++)0x0==_0x188a7c[_0x115e75]['side']&&(_0x188a7c[_0x115e75]['level']=_0x46001b);_0x46001b=0x0;for(let _0x544949=_0x480cb6-0x1;_0x544949>=_0x366020;_0x544949--)0x0==_0x188a7c[_0x544949]['distance']?_0x188a7c[_0x544949]['level']=_0x46001b:(_0x46001b--,_0x188a7c[_0x544949]['level']=_0x46001b,_0x46001b--);}}['_fixObsoleteTags'](_0x271139){const _0x1a738c=new Map(),_0x302d73=this['editor']['model']['schema'];for(let _0x257544=0x1;_0x257544<_0x271139['length'];_0x257544++){let _0x420f3c,_0x2a80b3,_0x1f98fb;const _0x49a10e=_0x271139[_0x257544],_0x655fe2=_0x271139[_0x257544-0x1];if('text'==_0x49a10e['type'])continue;if(_0x49a10e['type']!=_0x655fe2['type'])continue;if(!_0x302d73['isBlock'](_0x655fe2['item'])||_0x302d73['isLimit'](_0x655fe2['item']))continue;if(!_0x302d73['isBlock'](_0x49a10e['item'])||_0x302d73['isLimit'](_0x49a10e['item']))continue;if((_0x271139[_0x257544]['isAdded']||_0x271139[_0x257544]['isAddSuggestion'])&&_0x271139[_0x257544-0x1]['isRemoved'])_0x420f3c=_0x271139[_0x257544],_0x2a80b3=_0x271139[_0x257544-0x1],_0x1f98fb=_0x257544-0x1;else{if(!_0x271139[_0x257544]['isRemoved']||!_0x271139[_0x257544-0x1]['isAdded']&&!_0x271139[_0x257544-0x1]['isAddSuggestion'])continue;_0x420f3c=_0x271139[_0x257544-0x1],_0x2a80b3=_0x271139[_0x257544],_0x1f98fb=_0x257544;}const _0x2d211d=_0x420f3c['level']==_0x2a80b3['level'],_0x4b2c86=Math['abs'](_0x420f3c['level'])<Math['abs'](_0x2a80b3['level'])&&0x0==_0x2a80b3['distance'];(_0x2d211d||_0x4b2c86)&&(_0x1a738c['set'](_0x2a80b3['id'],_0x420f3c['id']),_0x271139['splice'](_0x1f98fb,0x1),_0x257544--,_0x420f3c['isAdded']=!0x1);}for(let _0x2f3649=0x0;_0x2f3649<_0x271139['length'];_0x2f3649++)_0x1a738c['has'](_0x271139[_0x2f3649]['pairId'])&&(_0x271139[_0x2f3649]['pairId']=_0x1a738c['get'](_0x271139[_0x2f3649]['pairId']));}['_removeMissingPairs'](_0x30d36d){const _0x3b0fee=new Set(_0x30d36d['map'](_0x5912b5=>_0x5912b5['id']));for(let _0x203a9e=0x0;_0x203a9e<_0x30d36d['length'];_0x203a9e++)_0x3b0fee['has'](_0x30d36d[_0x203a9e]['pairId'])||0x0==_0x30d36d[_0x203a9e]['distance']||(_0x30d36d[_0x203a9e]['isIncorrect']=!0x0);return _0x30d36d['filter'](_0x41171=>!_0x41171['isIncorrect']);}['_markMismatchedRemovedTags'](_0x5b39b8){const _0x3a5a86=new Set();for(let _0x309895=0x0;_0x309895<_0x5b39b8['length'];_0x309895++){if(_0x3a5a86['has'](_0x5b39b8[_0x309895]['id'])&&_0x5b39b8[_0x309895]['isRemoved']&&(_0x5b39b8[_0x309895]['isIncorrect']=!0x0),_0x5b39b8[_0x309895]['isIncorrect'])continue;if(0x0==_0x5b39b8[_0x309895]['distance'])continue;if('elementStart'!=_0x5b39b8[_0x309895]['type'])continue;if(null==_0x5b39b8[_0x309895]['pairId'])continue;let _0x42955a=_0x309895+0x1,_0x26a4c4=0x0;for(;_0x5b39b8[_0x42955a]['id']!=_0x5b39b8[_0x309895]['pairId'];)'elementStart'==_0x5b39b8[_0x42955a]['type']?_0x26a4c4++:'elementEnd'==_0x5b39b8[_0x42955a]['type']&&_0x26a4c4--,_0x42955a++;if(0x0!=_0x26a4c4){if(_0x5b39b8[_0x309895]['isRemoved'])_0x5b39b8[_0x309895]['isIncorrect']=!0x0;else{for(;_0x42955a!=_0x309895;)_0x5b39b8[_0x42955a]['isRemoved']&&0x0!=_0x5b39b8[_0x42955a]['distance']&&(_0x5b39b8[_0x42955a]['isIncorrect']=!0x0,_0x3a5a86['add'](_0x5b39b8[_0x42955a]['pairId'])),_0x42955a--;}}}return _0x5b39b8['filter'](_0x5e157f=>!_0x5e157f['isIncorrect']);}['_removeUnsupportedChanges'](_0x5c76d2){const _0x2dabd4=this['editor']['model']['schema'];for(let _0x16b180=0x0;_0x16b180<_0x5c76d2['length'];_0x16b180++){if(!(_0x5c76d2[_0x16b180]['isAdded']||_0x5c76d2[_0x16b180]['isAddSuggestion']||_0x5c76d2[_0x16b180]['isRemoved']||_0x5c76d2[_0x16b180]['isRemoveSuggestion']))continue;if(0x0==_0x5c76d2[_0x16b180]['distance'])continue;const _0x2e40b2=_0x5c76d2[_0x16b180]['item'];_0x2dabd4['isBlock'](_0x2e40b2)||_0x2dabd4['isLimit'](_0x2e40b2)||(_0x5c76d2[_0x16b180]['isAdded']&&delete _0x5c76d2[_0x16b180]['isAdded'],_0x5c76d2[_0x16b180]['isAddSuggestion']&&delete _0x5c76d2[_0x16b180]['isAddSuggestion'],_0x5c76d2[_0x16b180]['isRemoveSuggestion']&&delete _0x5c76d2[_0x16b180]['isRemoveSuggestion'],_0x5c76d2[_0x16b180]['isRemoved']&&(_0x5c76d2[_0x16b180]['isIncorrect']=!0x0));}return _0x5c76d2['filter'](_0x12986d=>!_0x12986d['isIncorrect']);}['_makeModelFromTape'](_0x1af85a,_0xa2c4a0,_0xca466f,_0x303001){const _0x277e01=new _0x59fcbe(),_0x19066b=[],_0x3feab7=new Map(),_0x1d2bba=this['editor']['model'],_0x2168ad=_0x1d2bba['schema'],_0x35b34d=[_0x277e01],_0xa6b095={},_0x5387f0={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};_0x277e01['name']=_0x303001;let _0x251f82=null;const _0x5c1d67=[0x0];for(let _0x553d53=0x0;_0x553d53<_0x1af85a['length'];_0x553d53++)if('elementStart'===_0x1af85a[_0x553d53]['type']){_0x1af85a[_0x553d53]['previousPosition']=_0x1d2bba['createPositionFromPath'](_0x277e01,_0x5c1d67);const _0x5b2b27=new _0x46d26f(_0x1af85a[_0x553d53]['item']['name'],_0x1af85a[_0x553d53]['item']['getAttributes']());_0x35b34d[0x0]['_appendChild'](_0x5b2b27),_0x5c1d67['push'](0x0),_0x35b34d['unshift'](_0x5b2b27),_0x1af85a[_0x553d53]['nextPosition']=_0x1d2bba['createPositionFromPath'](_0x277e01,_0x5c1d67);}else'elementEnd'===_0x1af85a[_0x553d53]['type']?(_0x35b34d['shift'](),_0x1af85a[_0x553d53]['previousPosition']=_0x1d2bba['createPositionFromPath'](_0x277e01,_0x5c1d67),_0x5c1d67['pop'](),_0x5c1d67[_0x5c1d67['length']-0x1]++,_0x1af85a[_0x553d53]['nextPosition']=_0x1d2bba['createPositionFromPath'](_0x277e01,_0x5c1d67)):(_0x1af85a[_0x553d53]['previousPosition']=_0x1d2bba['createPositionFromPath'](_0x277e01,_0x5c1d67),_0x251f82?_0x251f82['_data']+=_0x1af85a[_0x553d53]['item']['data']:_0x251f82=new _0x3b5bf9(_0x1af85a[_0x553d53]['item']['data'],_0x1af85a[_0x553d53]['item']['getAttributes']()),_0x1af85a[_0x553d53+0x1]&&'text'===_0x1af85a[_0x553d53+0x1]['type']&&_0x5722d1(_0x251f82,_0x1af85a[_0x553d53+0x1]['item'])||(_0x35b34d[0x0]['_appendChild'](_0x251f82),_0x251f82=null),_0x5c1d67[_0x5c1d67['length']-0x1]+=_0x1af85a[_0x553d53]['item']['offsetSize'],_0x1af85a[_0x553d53]['nextPosition']=_0x1d2bba['createPositionFromPath'](_0x277e01,_0x5c1d67));for(let _0x40cf51=0x0;_0x40cf51<_0x1af85a['length'];_0x40cf51++){const _0x3dbcfd=_0x1af85a[_0x40cf51]['previousPosition'],_0x22899a=_0x1af85a[_0x40cf51]['nextPosition'];for(const _0x3249bb of _0x1af85a[_0x40cf51]['markersStart'])_0x3feab7['set'](_0x3249bb,{'start':_0x3dbcfd,'end':null});_0xedf4cf('isRemoveSuggestion',_0x40cf51,_0x3dbcfd,_0x22899a),_0xedf4cf('isAddSuggestion',_0x40cf51,_0x3dbcfd,_0x22899a),_0xedf4cf('isRemoved',_0x40cf51,_0x3dbcfd,_0x22899a),_0xedf4cf('isAdded',_0x40cf51,_0x3dbcfd,_0x22899a);for(const _0x1d0044 of _0x1af85a[_0x40cf51]['markersEnd']){const _0x4e99a4=_0x3feab7['get'](_0x1d0044);_0x4e99a4?_0x4e99a4['end']=_0x22899a:_0x3feab7['set'](_0x1d0044,{'start':_0x22899a,'end':_0x22899a});}}for(const [_0x36cf7b,_0x560e15]of _0x3feab7){const _0x527f42=this['editor']['model']['createRange'](_0x560e15['start'],_0x560e15['end']);_0x277e01['markers']['set'](_0x36cf7b,_0x527f42);}return _0x19066b['sort']((_0x17bd8f,_0x18e3e5)=>{const _0x2e6b7d=_0x277e01['markers']['get']('revision:'+_0x17bd8f['id']),_0x1158db=_0x277e01['markers']['get']('revision:'+_0x18e3e5['id']);return _0x2e6b7d['start']['isBefore'](_0x1158db['start'])?-0x1:_0x2e6b7d['start']['isAfter'](_0x1158db['start'])?0x1:_0x2e6b7d['end']['isBefore'](_0x1158db['end'])?-0x1:_0x2e6b7d['end']['isAfter'](_0x1158db['end'])?0x1:'add'===_0x17bd8f['type']?-0x1:0x1;}),{'root':_0x277e01,'changes':_0x19066b};function _0xedf4cf(_0x4dfa2c,_0x4ba9d6,_0x2ccd39,_0x4aef7b){const _0xf388d0=!!_0x1af85a[_0x4ba9d6][_0x4dfa2c],_0xbff0aa=_0xf388d0?_0x1af85a[_0x4ba9d6][_0x4dfa2c]['userId']:null,_0xe0aca2=_0x4ba9d6===_0x1af85a['length']-0x1,_0x477d7f=_0x5387f0[_0x4dfa2c][0x0],_0x3e7036=_0x2168ad['isObject'](_0x1af85a[_0x4ba9d6]['item']);!_0xa6b095[_0x4dfa2c]&&_0xf388d0?_0xa6b095[_0x4dfa2c]={'start':_0x2ccd39,'tapeItem':_0x1af85a[_0x4ba9d6],'userId':_0xbff0aa,'type':_0x4dfa2c}:_0xa6b095[_0x4dfa2c]&&!_0xf388d0?(_0xa6b095[_0x4dfa2c]['end']=_0x2ccd39,_0x5471a9(_0xa6b095[_0x4dfa2c]),_0xa6b095[_0x4dfa2c]=null):_0xa6b095[_0x4dfa2c]&&_0xf388d0&&_0xa6b095[_0x4dfa2c]['userId']!==_0xbff0aa&&(_0xa6b095[_0x4dfa2c]['end']=_0x2ccd39,_0x477d7f&&_0x477d7f['userId']===_0xa6b095[_0x4dfa2c]['userId']||_0x5471a9(_0xa6b095[_0x4dfa2c]),_0xa6b095[_0x4dfa2c]={'start':_0x2ccd39,'tapeItem':_0x1af85a[_0x4ba9d6],'userId':_0xbff0aa,'type':_0x4dfa2c}),_0xa6b095[_0x4dfa2c]&&_0x3e7036&&('elementStart'!==_0x1af85a[_0x4ba9d6]['type']||_0x477d7f&&_0x477d7f['userId']===_0xbff0aa||_0x5387f0[_0x4dfa2c]['unshift']({'userId':_0xbff0aa,'object':_0x1af85a[_0x4ba9d6]['item'],'change':_0xa6b095[_0x4dfa2c]}),'elementEnd'===_0x1af85a[_0x4ba9d6]['type']&&_0x477d7f&&_0x477d7f['object']===_0x1af85a[_0x4ba9d6]['item']&&(_0x5387f0[_0x4dfa2c]['shift'](),_0xa6b095[_0x4dfa2c]=_0x477d7f['change'])),_0xa6b095[_0x4dfa2c]&&_0xe0aca2&&(_0xa6b095[_0x4dfa2c]['end']=_0x4aef7b,_0x5471a9(_0xa6b095[_0x4dfa2c]),_0xa6b095[_0x4dfa2c]=null);}function _0x5471a9({start:_0x4d1824,end:_0x27eba2,tapeItem:_0x5274ef,userId:_0x55336a,type:_0x22c3f3}){const _0x5c513e=_0x5274ef['item'],_0x2fc9e4=_0x1d2bba['schema']['isBlock'](_0x5c513e)&&!_0x1d2bba['schema']['isLimit'](_0x5c513e),_0x2e3e1f=_0x4d1824['nodeAfter']==_0x27eba2['parent']&&_0x27eba2['isAtStart'];if(_0x2fc9e4&&_0x2e3e1f)return;const _0x52fbce=_0x1d2bba['createRange'](_0x4d1824,_0x27eba2),_0xd74f6c=_0xa2c4a0['get'](_0x55336a),_0x3627ef=new ChangeItem({'author':_0xd74f6c,'type':'isAdded'==_0x22c3f3||'isAddSuggestion'==_0x22c3f3?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x22c3f3||'isRemoveSuggestion'==_0x22c3f3},'createdAt':new Date(),'rootName':_0xca466f});_0x19066b['push'](_0x3627ef),_0x277e01['markers']['set']('revision:'+_0x3627ef['id'],_0x52fbce);}function _0x5722d1(_0x324ba3,_0x28711d){const _0x528e18=_0x324ba3['getAttributes'](),_0x3d5eed=_0x28711d['getAttributes']();for(const _0x10d9ab of _0x528e18){if(_0x10d9ab[0x1]!==_0x28711d['getAttribute'](_0x10d9ab[0x0]))return!0x1;_0x3d5eed['next']();}return _0x3d5eed['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0xc032db=>{const _0x58c13a=_0xc032db['markerName']['split'](':')[0x1],_0xcde035=this['_getChangeFromId'](_0x58c13a);if(!_0xcde035)return null;const _0x3c62cc='add'==_0xcde035['type']?'insertion':'deletion',_0x2c02eb=['ck-suggestion-marker','ck-suggestion-marker-'+_0x3c62cc];return _0xcde035['data']['isSuggestion']&&_0x2c02eb['push']('ck-suggestion-marker-'+_0x3c62cc+'-new'),this['activeChange']==_0xcde035&&_0x2c02eb['push']('ck-suggestion-marker--active'),{'classes':_0x2c02eb,'attributes':{'data-change-id':_0x58c13a}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x32467e=>{_0x32467e['on']('element:pre',(_0x34f7e7,_0x32a629,_0x5ea890)=>{const _0x3edb61=_0x32a629['viewItem']['getChild'](0x0);if(!_0x3edb61||!_0x3edb61['is']('element','code'))return;if(!_0x5ea890['consumable']['consume'](_0x3edb61,{'attributes':['vid_start','vid_end']}))return;const _0x1b5092=_0x32a629['modelRange']['start']['nodeAfter'];_0x5ea890['writer']['setAttribute']('vid_start',_0x3edb61['getAttribute']('vid_start'),_0x1b5092),_0x5ea890['writer']['setAttribute']('vid_end',_0x3edb61['getAttribute']('vid_end'),_0x1b5092);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x56f587=>{_0x56f587['on']('element',(_0x3ba932,_0x4523de,_0x5e6125)=>{if(!_0x5e6125['consumable']['consume'](_0x4523de['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x4523de['modelRange']['isCollapsed'])return;const _0x43766a=_0x4523de['modelRange']['start']['nodeAfter'];_0x43766a['hasAttribute']('vid_start')||_0x43766a['hasAttribute']('vid')||(_0x5e6125['writer']['setAttribute']('vid_start',_0x4523de['viewItem']['getAttribute']('vid_start'),_0x43766a),_0x5e6125['writer']['setAttribute']('vid_end',_0x4523de['viewItem']['getAttribute']('vid_end'),_0x43766a));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x6a95f=>_0x6a95f['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x13b1ca,[,_0x2d359e])=>{['vid_start','vid_end','vid']['includes'](_0x2d359e)&&(_0x13b1ca['return']=!0x0,_0x13b1ca['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x5be889=>{_0x5be889['on']('attribute:vid',(_0xdb58a0,_0x478600,_0x2c574c)=>{if('\x20'!=_0x478600['item']['data']||_0x478600['item']['parent']['maxOffset']>0x1)return;if(!_0x2c574c['consumable']['consume'](_0x478600['item'],_0xdb58a0['name']))return;const _0x2f1495=_0x2c574c['writer'],_0x599cb8=_0x2c574c['mapper']['toViewRange'](_0x478600['range']);_0x2f1495['wrap'](_0x599cb8,_0x2f1495['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x8bbcf4){const _0x298c55=_0x8bbcf4['plugins']['get']('RevisionViewer');return(_0x382cfc,_0xc973e8,_0x2a30f8)=>{const _0x1fc9f1=_0xc973e8['markerName']['split'](':')[0x1],_0x157221=_0x298c55['_getChangeFromId'](_0x1fc9f1);if(!_0x157221)return null;const _0x3a0390='add'==_0x157221['type']?'split':'merge';if(!_0x2a30f8['consumable']['test'](_0xc973e8['markerRange'],_0x382cfc['name']))return;const _0xf95050=_0xc973e8['markerRange']['getWalker'](),_0x57cfb7=_0xc973e8['markerRange']['start'],_0x244cce=_0x8bbcf4['model']['schema'];let _0x16a133=null,_0x47cd11=null,_0x23c538=!0x1,_0x2de000=!0x1;for(const _0x342bb1 of _0xf95050){const _0xa1281f=_0x342bb1['item'];_0x23c538=_0x23c538||_0x244cce['isContent'](_0xa1281f);const _0x36453e=_0x2a30f8['mapper']['toViewElement'](_0xa1281f);if(_0x36453e&&_0x36453e['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x342bb1['type']&&(_0x244cce['isBlock'](_0xa1281f)&&!_0x244cce['isLimit'](_0xa1281f)&&(_0xa1281f['nextSibling']||_0x57cfb7['isAtEnd']?_0x16a133&&_0x16a133['parent']==_0xa1281f||(_0x16a133=_0xa1281f,_0xcc5857(_0x342bb1['previousPosition']),_0x2de000=!0x0):_0x47cd11=_0x47cd11||_0x342bb1['previousPosition']));}function _0xcc5857(_0x522352){const _0x2bf8f2=_0x2a30f8['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x3a0390}),_0xa7d1ca=_0x2a30f8['mapper']['toViewPosition'](_0x522352);_0x157221['data']['isSuggestion']&&_0x2a30f8['writer']['addClass']('ck-suggestion-marker-'+_0x3a0390+'-new',_0x2bf8f2),_0x298c55['activeChange']==_0x157221&&_0x2a30f8['writer']['addClass']('ck-suggestion-marker--active',_0x2bf8f2),_0x2a30f8['writer']['insert'](_0xa7d1ca,_0x2bf8f2),_0x2a30f8['mapper']['bindElementToMarker'](_0x2bf8f2,_0xc973e8['markerName']);}_0x23c538||_0x2de000||!_0x47cd11||_0xcc5857(_0x47cd11);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x1dd817,_0x2c8b2c,_0x284efe)=>{const _0xc40ba3=_0x284efe['mapper']['markerNameToElements'](_0x2c8b2c['markerName']);if(_0xc40ba3){for(const _0x2ebb78 of _0xc40ba3)(_0x2ebb78['hasClass']('ck-suggestion-marker-split')||_0x2ebb78['hasClass']('ck-suggestion-marker-merge'))&&(_0x284efe['mapper']['unbindElementFromMarkerName'](_0x2ebb78,_0x2c8b2c['markerName']),_0x284efe['writer']['remove'](_0x2ebb78));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x1010e8,_0x23a913,_0x1ca828)=>{const _0x35bd91=_0x23a913['markerName']['split'](':')[0x1],_0x239cf4=this['_getChangeFromId'](_0x35bd91);if(!_0x239cf4)return null;const _0x216d1a='add'==_0x239cf4['type']?'split':'merge';if(_0x1ca828['consumable']['test'](_0x23a913['markerRange'],_0x1010e8['name']))for(const _0x5b541e of _0x23a913['markerRange']['getItems']()){if(!_0x5b541e['is']('element','softBreak'))continue;const _0x546af9=_0x1ca828['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x216d1a}),_0x3f57be=_0x1ca828['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x5b541e));_0x239cf4['data']['isSuggestion']&&_0x1ca828['writer']['addClass']('ck-suggestion-marker-'+_0x216d1a+'-new',_0x546af9),this['activeChange']==_0x239cf4&&_0x1ca828['writer']['addClass']('ck-suggestion-marker--active',_0x546af9),_0x1ca828['writer']['insert'](_0x3f57be,_0x546af9),_0x1ca828['mapper']['bindElementToMarker'](_0x546af9,_0x23a913['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x1d86d9=>{for(const _0x5b0800 of this['editor']['model']['document']['getRootNames']()){const _0x55cad1=this['editor']['model']['document']['getRoot'](_0x5b0800),_0xde906d=this['editor']['editing']['view']['document']['getRoot'](_0x5b0800);if(_0xde906d){const _0x2e0126=_0x55cad1['getAttribute']('revisionHistoryAttachChange');if(_0x1d86d9['removeAttribute']('data-change-id',_0xde906d),_0x1d86d9['removeClass']('ck-revision-history-root-add',_0xde906d),_0x1d86d9['removeClass']('ck-revision-history-root-remove',_0xde906d),_0x1d86d9['removeClass']('ck-revision-history-root--active',_0xde906d),_0x2e0126){const _0x43f2f7=this['_getChangeFromId'](_0x2e0126);if(!_0x43f2f7)return null;_0x1d86d9['setAttribute']('data-change-id',_0x2e0126,_0xde906d),_0x1d86d9['addClass']('ck-revision-history-root-'+_0x43f2f7['type'],_0xde906d),this['activeChange']==_0x43f2f7&&_0x1d86d9['addClass']('ck-revision-history-root--active',_0xde906d);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x22157d=>'revision-comment:'+_0x22157d,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x2b0152=>'revision-suggestion:'+_0x2b0152,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x5bf65c=>({'name':'suggestion:'+_0x5bf65c,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x33315d=>{const _0x19aba7=_0x33315d['markerName']['split'](':')[0x1];return'insertion'!=_0x19aba7&&'deletion'!=_0x19aba7?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x19aba7]};}}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:deletion',_t(this['editor'],'merge'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:insertion',_t(this['editor'],'split'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision-suggestion',(_0x56ee8e,_0x1ebf2a,_0x2585c5)=>{const _0x2fee29=_0x2585c5['mapper']['markerNameToElements'](_0x1ebf2a['markerName']);if(_0x2fee29){for(const _0x3b3a8f of _0x2fee29)_0x3b3a8f['is']('uiElement')&&(_0x2585c5['mapper']['unbindElementFromMarkerName'](_0x3b3a8f,_0x1ebf2a['markerName']),_0x2585c5['writer']['remove'](_0x3b3a8f));}},{'priority':'high'});}['_getChangeFromId'](_0xd84258){return this['_changeIdToChange']['get'](_0xd84258);}['_getViewForChange'](_0x3dab98){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new ChangeDetailsView(this['editor']['locale'],_0x3dab98),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x3bc98c,_0xf3c307,_0x4c0e1c,_0x29f304)=>{_0x29f304&&this['_balloon']['remove'](_0x29f304),_0x4c0e1c&&(this['_balloon']['add']({'view':_0x4c0e1c,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x7af140=this['editor']['editing'],_0x25325a=this['_getChangeFromId'](_0x4c0e1c['changeId']);let _0x31c69f;if(_0x25325a['data']['isOnRoot']){const _0x46e62b=_0x7af140['view']['getDomRoot'](_0x25325a['rootName']);_0x31c69f=Array['from'](_0x46e62b['getClientRects']());}else{const _0xaaa48f=this['editor']['model']['markers']['get']('revision:'+_0x4c0e1c['changeId']);_0x31c69f=Array['from'](_0x7af140['mapper']['markerNameToElements'](_0xaaa48f['name']))['map'](_0x12f8d5=>_0x7af140['view']['domConverter']['mapViewToDom'](_0x12f8d5))['map'](_0x3ac84e=>Array['from'](_0x3ac84e['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x31c69f[0x0];return _0x31c69f['find'](_0x15cca5=>_0x15cca5['top']-0x3<=this['_activeViewTarget']['y']&&_0x15cca5['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x15cca5['left']-0x3<=this['_activeViewTarget']['x']&&_0x15cca5['right']+0x3>=this['_activeViewTarget']['x'])||_0x31c69f[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x4eb8fc,_0x27be5c,_0x35f561,_0x8177d2)=>{this['activeView']=_0x35f561?this['_getViewForChange'](_0x35f561):null,this['editor']['model']['change'](()=>{const _0x43104a=this['editor']['editing'];_0x8177d2&&(_0x8177d2['data']['isOnRoot']?_0x43104a['view']['change'](_0x1c635c=>{_0x1c635c['removeClass']('ck-revision-history-root--active',_0x43104a['view']['document']['getRoot'](_0x8177d2['rootName']));}):_0x43104a['reconvertMarker']('revision:'+_0x8177d2['id'])),_0x35f561&&(_0x35f561['data']['isOnRoot']?_0x43104a['view']['change'](_0x51e934=>{_0x51e934['addClass']('ck-revision-history-root--active',_0x43104a['view']['document']['getRoot'](_0x35f561['rootName']));}):_0x43104a['reconvertMarker']('revision:'+_0x35f561['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x1088d0,_0x5d50f1)=>{if(this['activeChange'])return;const _0x3317de=this['_findChangeIdFromDomTarget'](_0x5d50f1['target']),_0x3df386=this['_changeIdToChange']['get'](_0x3317de);_0x3df386?(this['_activeViewTarget']={'x':_0x5d50f1['domEvent']['x'],'y':_0x5d50f1['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x3df386)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x11ef1c,_0x34530f)=>{const _0xa80260=this['_findChangeIdFromDomTarget'](_0x34530f['target']),_0x124857=this['_changeIdToChange']['get'](_0xa80260);_0x124857?(this['_activeViewTarget']={'x':_0x34530f['domEvent']['x'],'y':_0x34530f['domEvent']['y']},_0x124857===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x124857):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x3072e6){do{const _0x5584f8=_0x3072e6['getAttribute']('data-change-id');if(_0x5584f8)return _0x5584f8;_0x3072e6=_0x3072e6['parent'];}while(_0x3072e6);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x3478d8=>{for(const _0x2b7999 of this['editor']['model']['markers'])_0x3478d8['removeMarker'](_0x2b7999);});}}function _t(_0x174649,_0x161c99){return(_0x4dbc24,_0x278d4e,_0x52ebdb)=>{if(!_0x52ebdb['consumable']['test'](_0x278d4e['markerRange'],_0x4dbc24['name']))return;const _0x598280=_0x278d4e['markerRange']['getWalker'](),_0xd90dd=_0x278d4e['markerRange']['start'],_0x582593=_0x174649['model']['schema'];let _0x1e471c=null,_0x2f7fb9=null,_0x251231=!0x1,_0x1eaf8e=!0x1;for(const _0xd417be of _0x598280){const _0x3566e4=_0xd417be['item'];_0x251231=_0x251231||_0x582593['isContent'](_0x3566e4);const _0x29c569=_0x52ebdb['mapper']['toViewElement'](_0x3566e4);if(_0x29c569&&_0x29c569['getCustomProperty']('addHighlight'))return;'elementEnd'==_0xd417be['type']&&(_0x582593['isBlock'](_0x3566e4)&&!_0x582593['isLimit'](_0x3566e4)&&(_0x3566e4['nextSibling']||_0xd90dd['isAtEnd']?_0x1e471c&&_0x1e471c['parent']==_0x3566e4||(_0x1e471c=_0x3566e4,_0x2fbd48(_0xd417be['previousPosition']),_0x1eaf8e=!0x0):_0x2f7fb9=_0x2f7fb9||_0xd417be['previousPosition']));}function _0x2fbd48(_0x572b3a){const _0x59d550=_0x52ebdb['mapper']['toViewPosition'](_0x572b3a),_0x7930a7=_0x52ebdb['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x161c99});_0x52ebdb['writer']['insert'](_0x59d550,_0x7930a7),_0x52ebdb['mapper']['bindElementToMarker'](_0x7930a7,_0x278d4e['markerName']);}_0x251231||_0x1eaf8e||!_0x2f7fb9||_0x2fbd48(_0x2f7fb9);};}class RestoreRevisionCommand extends _0x3dad1f{constructor(_0x1a3418){super(_0x1a3418);const _0x3888cc=_0x1a3418['plugins']['get'](RevisionViewer);this['affectsData']=!0x1,this['listenTo'](_0x3888cc,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x3888cc,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x3298d8=this['editor'],_0x27692c=_0x3298d8['plugins']['get'](RevisionViewer),_0x5774f0=_0x27692c['isReady']?_0x27692c['diff']['newRevisionId']:null;_0x3298d8['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x5774f0);}['refresh'](){const {isReady:_0x3cee8f,isEnabled:_0x147887,repository:_0x29288a,diff:_0x5ac106}=this['editor']['plugins']['get'](RevisionViewer),_0x4ab354=_0x5ac106&&_0x29288a['getLaterVisibleRevision'](_0x5ac106['newRevisionId']);this['isEnabled']=_0x3cee8f&&_0x147887&&Boolean(_0x4ab354);}}class ShowChangeCommand extends _0x3dad1f{['_step'];constructor(_0x8a95a5,{direction:_0x5ba60e}){super(_0x8a95a5);const _0xc6402=_0x8a95a5['plugins']['get'](RevisionViewer);this['affectsData']=!0x1,this['_step']='forward'===_0x5ba60e?0x1:-0x1,this['listenTo'](_0xc6402,'change:isReady',()=>this['refresh']()),this['listenTo'](_0xc6402,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0xc6402,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x9d0bc=this['editor'],_0x5b16a7=_0x9d0bc['plugins']['get'](RevisionViewer),{isNavigationMode:_0x57ae37,currentChangeNumber:_0x47a554}=_0x5b16a7;let _0x5590b7;if(_0x5b16a7['activeChange']=_0x57ae37?_0x5b16a7['diff']['changes']['get'](_0x47a554+this['_step']):_0x5b16a7['diff']['changes']['first'],_0x5b16a7['activeChange']['data']['isOnRoot'])_0x5590b7=_0x9d0bc['editing']['view']['getDomRoot'](_0x5b16a7['activeChange']['rootName']);else{const _0x21d5ce=_0x9d0bc['model']['markers']['get']('revision:'+_0x5b16a7['activeChange']['id']);_0x5590b7=_0x205b94(_0x9d0bc['editing'],_0x21d5ce);}_0x4fee1d({'target':_0x5590b7,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x3e0e39,currentChangeNumber:_0x4eea59,numberOfChanges:_0x271a1b,isReady:_0x328e1e,isEnabled:_0x54e47c}=this['editor']['plugins']['get'](RevisionViewer);this['isEnabled']=!!(_0x54e47c&&_0x328e1e&&_0x271a1b)&&(!_0x3e0e39||(0x1===this['_step']?_0x4eea59<_0x271a1b-0x1:_0x4eea59>0x0));}}class ChangesNavigationView extends _0xafec90{constructor(_0x27335b){super(_0x27335b);const _0x266b2e=this['bindTemplate'],_0x33036a=new _0x135801(_0x27335b),_0x257ec0=new _0x135801(_0x27335b);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',(_0x26f1d5,_0x3e8ae6)=>_0x26f1d5&&_0x3e8ae6>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x56d9d7,_0x339ef8,_0x2f420a,_0x3cc2e8)=>{if(!_0x56d9d7)return ft(_0x27335b,'Loading...');if(!_0x2f420a)return ft(_0x27335b,'No\x20changes');const _0x3bd669=ft(_0x27335b,'NUMBER_OF_CHANGES',_0x2f420a);return _0x3cc2e8?ft(_0x27335b,'X_OF_Y_CHANGES',[_0x339ef8+0x1,_0x2f420a]):_0x3bd669;}),_0x33036a['set']({'label':ft(_0x27335b,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x37d115}),_0x257ec0['set']({'label':ft(_0x27335b,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x27b0d7}),_0x33036a['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x257ec0['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x33036a['on']('execute',()=>this['fire']('execute','backward')),_0x257ec0['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',_0x266b2e['if']('_isStatusLabelVisible','ck-hidden',_0x55912d=>!_0x55912d)]},'children':[{'text':_0x266b2e['to']('isNavigationMode',_0xbf806c=>_0xbf806c?ft(_0x27335b,'EDIT_X_OF_Y_REVISIONS')+':\x20':ft(_0x27335b,'Total')+':\x20')}]},{'text':_0x266b2e['to']('_statusText')}]},new st(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x33036a,_0x257ec0]}]});}}const yt='ck-editor__editable__loading-overlay';class RevisionViewerLoadingOverlay extends _0x538071{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x4a4826=this['editor']['editing']['view'];_0x4a4826['change'](_0x1a8a86=>{for(const _0x4770c0 of _0x4a4826['document']['roots'])_0x1a8a86['addClass'](yt,_0x4770c0);});}['hide'](){const _0x528adb=this['editor']['editing']['view'];_0x528adb['change'](_0x4860f0=>{for(const _0x473b2b of _0x528adb['document']['roots'])_0x4860f0['removeClass'](yt,_0x473b2b);});}}class RevisionViewerUI extends _0x538071{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[RevisionViewer,RevisionViewerLoadingOverlay];}['init'](){const _0x4729c4=this['editor'],_0x1bbf48=_0x4729c4['plugins']['get'](RevisionViewer),_0x46f328=_0x4729c4['plugins']['get'](RevisionViewerLoadingOverlay);_0x4729c4['ui']['componentFactory']['add']('exitToEditing',_0x5e3d11=>{const _0xc0794=new _0x135801(_0x5e3d11);return _0xc0794['set']({'label':ft(_0x5e3d11,'Back\x20to\x20editing'),'icon':_0x2c0af7,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0xc0794,'execute',()=>{_0x4729c4['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0xc0794;}),_0x4729c4['ui']['componentFactory']['add']('restoreRevision',_0x326f75=>{const _0x47b0cf=new _0x135801(_0x326f75);return _0x47b0cf['set']({'label':ft(_0x326f75,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x47b0cf['bind']('isEnabled')['to'](_0x4729c4['commands']['get']('restoreRevision')),this['listenTo'](_0x47b0cf,'execute',()=>_0x4729c4['execute']('restoreRevision')),_0x47b0cf;}),_0x4729c4['ui']['componentFactory']['add']('changesNavigation',_0x3f2fc3=>{const _0x4868a1=new ChangesNavigationView(_0x3f2fc3),_0x20cf63=_0x4729c4['commands']['get']('showPreviousChange'),_0x3c1bf1=_0x4729c4['commands']['get']('showNextChange');return _0x4868a1['bind']('isBackwardNavigationEnabled')['to'](_0x20cf63,'isEnabled'),_0x4868a1['bind']('isForwardNavigationEnabled')['to'](_0x3c1bf1,'isEnabled'),_0x4868a1['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x1bbf48),this['listenTo'](_0x4868a1,'execute',(_0x52c49a,_0x1a7d83)=>{_0x4729c4['execute']('forward'===_0x1a7d83?'showNextChange':'showPreviousChange');}),_0x4868a1;}),_0x46f328['show'](),_0x1bbf48['on']('change:isReady',(_0x4598fb,_0x4bb2a0,_0x2f00ff)=>{_0x2f00ff?_0x46f328['hide']():_0x46f328['show']();});}}class RevisionNameView extends _0x17e56b{['_resizeObserver']=null;constructor(_0xc08aca,_0x5e463b){super(_0xc08aca,_0x5e463b);const _0x26ce64=this['bindTemplate'];this['set']({'label':ft(_0xc08aca,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=ft(_0xc08aca,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x26ce64['to']('_tooltipString'),'data-cke-tooltip-position':'s','data-cke-tooltip-class':'ck-tooltip_multi-line'}});}['render'](){super['render'](),this['_resizeObserver']=new _0x39f055(this['fieldView']['element'],()=>this['_updateTooltipText']()),this['listenTo'](this['fieldView'],'input',()=>this['_updateTooltipText']());}['destroy'](){super['destroy'](),this['_resizeObserver']&&this['_resizeObserver']['destroy']();}['_updateTooltipText'](){const _0x2705ae=this['fieldView']['element'];this['_tooltipString']=_0x2705ae['scrollWidth']>_0x2705ae['clientWidth']&&_0x2705ae['value']||'';}}class RevisionAuthorView extends _0xafec90{constructor(_0x5dfb96,_0x169a71,_0xa5cc3a){super(_0x5dfb96);const _0x41afe7=new nt();_0x41afe7['set']({'content':_0x185391,'viewBox':'0\x200\x2011\x2010'});const _0x9539ff=['ck','ck-revision-history-sidebar__revision-author'];_0xa5cc3a&&_0x9539ff['push']('ck-revision-history-sidebar__revision-author_creator');const _0x557798=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':ft(_0x5dfb96,_0xa5cc3a?'Revision\x20creator':'Revision\x20author')},'children':[_0x41afe7,_0x169a71['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x9539ff},'children':_0x557798});}}function Rt(_0x7d78c5,_0x5b62a9){const _0x40a8ce=_0x7d78c5['bindTemplate'],_0xe9a06e=_0x7d78c5['locale'],_0x3ed543=_0x182132(_0xe9a06e);_0x3ed543['panelPosition']='sw';const _0x40ee4b=function(_0x2b9254,_0x440ca6){const _0x58d883=function(_0x59e4c2,_0x5edcd2){const _0x53f9cd=_0x59e4c2['locale'],_0x211183={'Compare\x20against\x20selected':ft(_0x53f9cd,'Compare\x20against\x20selected'),'Name\x20this\x20revision':ft(_0x53f9cd,'Name\x20this\x20revision'),'Restore\x20this\x20revision':ft(_0x53f9cd,'Restore\x20this\x20revision')};return _0x5edcd2['map'](_0x338a09=>{const _0x51b170=_0x211183[_0x338a09['name']];return _0x51b170&&_0x51b170!==_0x338a09['name']&&(_0x338a09['name']=_0x51b170),_0x338a09;});}(_0x2b9254,_0x440ca6),_0x286a7c=new _0x3625c9();for(const _0x868898 of _0x58d883){const _0x470cd8={'type':'button','model':new rt({'label':_0x868898['name'],'class':_0x868898['class'],'withText':!0x0,'role':'menuitem','_action':_0x868898['action']})};_0x470cd8['model']['bind']('isEnabled')['to'](_0x2b9254,'isActionsDropdownOpen',_0x24eaae=>'function'!=typeof _0x868898['isEnabled']||(!_0x24eaae||_0x868898['isEnabled'](_0x2b9254))),_0x286a7c['add'](_0x470cd8);}return _0x286a7c;}(_0x7d78c5,_0x5b62a9);return _0x7d78c5['bind']('isActionsDropdownOpen')['to'](_0x3ed543,'isOpen'),_0x3ed543['buttonView']['set']({'label':ft(_0xe9a06e,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x5379e9}),_0x3ed543['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x40a8ce['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x40a8ce['to'](_0x42f41a=>_0x42f41a['stopPropagation']())}}),_0x3ed543['on']('execute',_0x5b827f=>{_0x7d78c5['isReady']&&'function'==typeof _0x5b827f['source']['_action']&&_0x5b827f['source']['_action'](_0x7d78c5);}),ot(_0x3ed543,_0x40ee4b,{'role':'menu'}),_0x3ed543['listenTo'](_0x7d78c5,'change:isActionsDropdownOpen',(_0x41ee18,_0x4368fa,_0x2ab2b2)=>{if(_0x2ab2b2)for(const _0x41606b of _0x3ed543['listView']['items']){const _0x16da51=_0x41606b['children']['first'],_0x2e0e83=_0x5b62a9['find'](_0x1ad6f1=>_0x1ad6f1['action']===_0x16da51['_action'])['isVisible'];_0x41606b['isVisible']=void 0x0===_0x2e0e83||_0x2e0e83(_0x7d78c5);}}),_0x3ed543;}class RevisionView extends/* #__PURE__ -- @preserve */
|
|
27
|
+
_0x1f967d(_0xafec90){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x524caf,_0xd38c8e,_0x892ae0,_0x23c543){super(_0x524caf);const _0x4ca3e6=this['bindTemplate'],_0x59c01d=function(_0x384b27,_0x4f43ac){const _0x52e3ba=Array['from'](_0x4f43ac['authors'])['filter'](_0x20d6b7=>_0x20d6b7!=_0x4f43ac['creator']);return _0x4f43ac['creator']&&_0x52e3ba['unshift'](_0x4f43ac['creator']),_0x52e3ba['map'](_0x14cde7=>new RevisionAuthorView(_0x384b27,_0x14cde7,_0x14cde7==_0x4f43ac['creator']));}(_0x524caf,_0xd38c8e);this['id']=_0xd38c8e['id'],this['_revision']=_0xd38c8e,this['_requireRevisionName']=_0x23c543,this['bind']('name','createdAt')['to'](_0xd38c8e),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x12bc82=>{return _0x21c992=_0x524caf['uiLanguage'],(_0x44af9c=_0x12bc82)['toLocaleDateString'](_0x21c992,{'month':'long','day':'numeric'})+',\x20'+_0x44af9c['toLocaleTimeString'](_0x21c992,{'hour':'numeric','minute':'numeric'});var _0x21c992,_0x44af9c;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new RevisionNameView(_0x524caf,_0x238b41),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x1e3443=>_0x1e3443||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x2033c4,_0x10916f)=>_0x2033c4&&_0x10916f),this['revisionActionsView']=_0x892ae0&&_0x892ae0['length']?Rt(this,_0x892ae0):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x4ca3e6['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x4ca3e6['if']('isEnabled','ck-disabled',_0x42dddc=>!_0x42dddc),_0x4ca3e6['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x4ca3e6['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x4ca3e6['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':_0x4ca3e6['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':_0x59c01d}]},this['revisionActionsView']],'on':{'click':_0x4ca3e6['to'](_0x5835f7=>{_0x5835f7['srcElement']['closest']('.ck-confirm-view')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x2cc92a=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x2cc92a,'change',()=>{this['_requireRevisionName']&&!_0x2cc92a['value']||this['fire']('setName',{'id':this['id'],'name':_0x2cc92a['value']}),_0x2cc92a['value']||(_0x2cc92a['value']=this['name']?this['name']:this['_createdAtFormatted']);});}['select'](){this['isSelected']=!0x0;}['deselect'](){this['isSelected']=!0x1;}['highlight'](){this['isHighlighted']=!0x0;}['unhighlight'](){this['isHighlighted']=!0x1;}}function bt(_0xe1aff4,_0x22f11f){const _0x142ad6=vt['fromJSDate'](_0xe1aff4)['setLocale'](_0x22f11f),_0x46df4f=vt['local'](),_0x1876d2=_0x46df4f['minus']({'days':0x1})['startOf']('day');let _0x12bbdf,_0x30bae6;return _0x142ad6['hasSame'](_0x46df4f,'day')?(_0x12bbdf=_0x142ad6['startOf']('day')['toJSDate'](),_0x30bae6=_0x142ad6['toRelativeCalendar']()):_0x142ad6['hasSame'](_0x1876d2,'day')?(_0x12bbdf=_0x1876d2['toJSDate'](),_0x30bae6=_0x142ad6['toRelativeCalendar']()):_0x142ad6['hasSame'](_0x46df4f,'week')?(_0x12bbdf=_0x142ad6['startOf']('week')['toJSDate'](),_0x30bae6=_0x142ad6['weekdayLong']||''):_0x142ad6['hasSame'](_0x46df4f,'year')?(_0x12bbdf=_0x142ad6['startOf']('month')['toJSDate'](),_0x30bae6=_0x142ad6['monthLong']||''):(_0x12bbdf=_0x142ad6['startOf']('year')['toJSDate'](),_0x30bae6=String(_0x142ad6['year'])),{'startDate':_0x12bbdf,'localizedPeriodName':_0x30bae6};}class RevisionsSidebarTimePeriodView extends _0xafec90{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x25a448,_0x169b2a,_0x1118a2,_0x51acd8){super(_0x25a448);const _0x1d4d64=bt(_0x169b2a,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x169b2a,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x1118a2,this['_requireRevisionName']=_0x51acd8,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':_0x1d4d64}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x59fca8){const _0x1fadce=new RevisionView(this['locale'],_0x59fca8,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x1fadce);}['removeRevision'](_0x446c37){const _0x6b7bba=this['revisionViews']['find'](_0x410590=>_0x410590['id']===_0x446c37['id']);this['revisionViews']['remove'](_0x6b7bba);}}class RevisionsSidebarHeaderView extends _0xafec90{constructor(_0x1cc838){super(_0x1cc838);const _0xf5d2b4=new nt();_0xf5d2b4['content']=_0x5ea9e8,this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0xf5d2b4,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[ft(_0x1cc838,'Revision\x20history')]}]});}}class RevisionsSidebarView extends _0xafec90{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x44a43e,_0x46cbea,_0x42c5f7,_0x3baee3){super(_0x44a43e);const _0x55e156=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x46cbea,this['_revisionActions']=_0x42c5f7,this['_requireRevisionName']=_0x3baee3,this['on']('select',(_0x13bca6,_0x1b73eb)=>{this['fire']('revisionSelected',_0x1b73eb);}),this['on']('setName',(_0x187e10,_0x37f373)=>{this['fire']('revisionSetName',_0x37f373);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new RevisionsSidebarHeaderView(_0x44a43e),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x55e156['if']('isEnabled','ck-disabled',_0x3724b5=>!_0x3724b5)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x38a787 of this['_revisions'])this['_addRevision'](_0x38a787);this['_revisions']['on']('add',(_0x2d8765,_0x2f0ea8)=>{this['_addRevision'](_0x2f0ea8);}),this['_revisions']['on']('remove',(_0x14937c,_0x513568)=>{this['_removeRevision'](_0x513568);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0xc09a4=>_0xc09a4['revisionViews']['map'](_0x1f176b=>_0x1f176b))['flat']();}['selectRevision'](_0x514d18){for(const _0x23d5cc of this['revisionViews'])_0x514d18&&_0x514d18['id']===_0x23d5cc['id']?_0x23d5cc['select']():_0x23d5cc['deselect']();}['highlightRevisions'](_0x53b33d){for(const _0x3ba440 of this['revisionViews'])_0x53b33d['some'](({id:_0x12db71})=>_0x12db71===_0x3ba440['id'])?_0x3ba440['highlight']():_0x3ba440['unhighlight']();}['_addRevision'](_0x76edce){const _0x100b74=bt(_0x76edce['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x22ccd9=this['_getTimePeriodViewByStartDate'](_0x100b74);_0x22ccd9||(_0x22ccd9=new RevisionsSidebarTimePeriodView(this['locale'],_0x100b74,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x22ccd9)),_0x22ccd9['addRevision'](_0x76edce);}['_removeRevision'](_0x34e946){const _0xd124a9=bt(_0x34e946['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0xd124a9)['removeRevision'](_0x34e946);}['_getTimePeriodViewByStartDate'](_0x7e638f){return this['timePeriodViews']['find'](_0x2a79be=>_0x2a79be['startDate']['getTime']()===_0x7e638f['getTime']());}}class RevisionsSidebar extends _0x538071{['_revisionViewer'];['_revisionsRepository'];['_sidebarView'];static ['defaultRevisionActions']=/* #__PURE__ -- @preserve */
|
|
28
28
|
((()=>['compareAgainstSelected','restoreRevision','nameRevision'])());static ['availableRevisionActions']=/* #__PURE__ -- @preserve */
|
|
29
|
-
kt();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[RevisionViewer];}constructor(
|
|
30
|
-
_0x56a52b(_0x6aac53){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x430863,_0x4fa3f7){super(_0x4fa3f7),this['sourceElement']=_0x430863,this['model']['document']['createRoot']();const _0x294859=new RevisionViewerEditorUIView(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new RevisionViewerEditorUI(this,_0x294859);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x24597c,_0x1beaaf){const _0x3996bf=new this(_0x24597c,_0x1beaaf);return await _0x3996bf['initPlugins'](),await _0x3996bf['ui']['init'](_0x24597c),await _0x3996bf['data']['init'](_0x3996bf['config']['get']('initialData')||''),_0x3996bf['fire']('ready'),_0x3996bf;}}const It=['RevisionHistoryUI','RestrictedEditingMode','AIChat','AIReviewMode','AIBalloon','AIQuickActions','AIActions','AIChatShortcuts','AITranslate'];class RevisionViewerIntegration extends _0x4c1791{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x118be4){function _0x58617c(_0x3c7d96){return _0x3c7d96['map'](_0x5ca131=>String['fromCharCode'](_0x5ca131))['join']('');}super(_0x118be4),this['result']='end',_0x118be4[_0x58617c([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x58617c([0x76,0x69,0x65,0x77])][_0x58617c([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x58617c([0x61,0x75,0x74,0x6f]),_0x118be4[_0x58617c([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x58617c([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x58617c([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x58617c([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x58617c([0x6f,0x6b])});}}class RevisionHistory extends _0x4c1791{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[RevisionTracker,RevisionHistoryUI];}constructor(_0x331291){if(super(_0x331291),!this['editor']['config']['get']('revisionHistory'))throw new _0x3684f0('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x356364=>this['_showRevisionViewer']({..._0x356364,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x573149=>this['_closeRevisionViewer'](_0x573149)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x1958aa=>this['_restoreRevision'](_0x1958aa)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x14de42){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x14de42;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x19d833){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x19d833);}['getRevision'](_0x3e376c){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x3e376c);}['getRevisions'](_0xe1cad0){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0xe1cad0||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x351cb2=this['editor'],_0x404193=_0x505333(_0x351cb2,It),_0x1f38a2=_0x351cb2['plugins']['get']('RevisionTracker'),_0x320195=_0x351cb2['plugins']['get'](_0x48a34e)['users'];return _0x404193['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x404193['lazyRoots'],(_0x404193['plugins']['push'](RevisionViewerIntegration,RevisionViewer,RevisionViewerUI,class RevisionViewerInit extends _0x4c1791{static get['requires'](){return[RevisionViewer,_0x48a34e];}['init'](){const _0x4510d7=this['editor']['plugins']['get'](_0x48a34e);for(const _0x26feef of _0x320195)_0x26feef['isAnonymous']||_0x4510d7['getUser'](_0x26feef['id'])||_0x4510d7['addUser'](_0x26feef);const _0xbbe26d=_0x1f38a2['repository']['getRevisions']();let _0x30da85=null;const _0x52e974=this['editor']['plugins']['get']('RevisionViewer');_0x52e974['adapter']=_0x1f38a2['adapter'],_0x52e974['bind']('isEnabled')['to'](_0x1f38a2),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x351cb2,'isReadOnly',_0x1bfd69=>!_0x1bfd69);for(const _0xce74f8 of _0xbbe26d){const _0x5d8d3a=null===_0xce74f8['creator'];if(_0x5d8d3a&&_0xce74f8['toVersion']===_0xce74f8['fromVersion'])continue;const _0x3c99ed=_0xce74f8['toJSON']();_0x52e974['addRevisionData'](_0x3c99ed,(_0x2b7e41,_0x4f1dcf,_0x2a082c)=>{if(_0x5d8d3a){if(_0x30da85)_0x30da85['_update'](_0x2b7e41,_0x4f1dcf);else{if(!_0x4f1dcf){const _0x15aa0c=_0x2a082c['toJSON']();_0x15aa0c['id']=_0x2d6fd8(),_0x1f38a2['saveRevision'](_0x15aa0c,_0x2a082c['toVersion'])['then'](_0x146bf1=>{_0x30da85=_0x146bf1;});}}}else _0xce74f8['_update'](_0x2b7e41,_0x4f1dcf);});}}},RevisionsSidebar),_0x404193);}['_enhanceShowRevisionViewerCallback'](){const _0x5cf093=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x48db78=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x4ed889=this['editor']['plugins']['get']('Autosave');await _0x4ed889['save']();}else await _0x48db78['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x16ed47=this['editor']['plugins']['get']('Dialog');_0x16ed47['isOpen']&&_0x16ed47['hide']();}if(this['editor']['plugins']['has']('AITabs')){const _0x5bc464=this['editor']['plugins']['get']('AITabs')['view']['panelViews'];for(const _0x514c6a of _0x5bc464)_0x514c6a['class']=_0x514c6a['class']?_0x514c6a['class']+'\x20ck-tab-panel_disabled':'ck-tab-panel_disabled';if(this['editor']['plugins']['has']('AIChat')){const _0x20ce0d=document['querySelector']('.ck-ai-chat__prompt-input\x20.ck-textarea');_0x20ce0d&&_0x20ce0d['setAttribute']('tabindex','-1');}if(this['editor']['plugins']['has']('AIChatHistory')){const _0x18202f=document['querySelector']('.ck-ai-chat-history\x20.ck-input');_0x18202f&&_0x18202f['setAttribute']('tabindex','-1');}}const _0x2dd13f=this['_getRevisionViewerEditorConfig']();return _0x5cf093(_0x2dd13f)['then'](_0x17aeef=>{return(this['_viewerEditor']=_0x17aeef,this['editor']['plugins']['has']('Annotations'))&&this['editor']['plugins']['get']('Annotations')['refreshVisibility'](),(this['editor']['plugins']['has']('DocumentOutline')&&(this['editor']['plugins']['get']('DocumentOutlineUI')['view']['element']['style']['display']='none'),_0x17aeef);})['catch'](_0x2ec643=>(console['error'](_0x2ec643),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x481898=this['editor']['config']['get']('revisionHistory')['closeRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.closeRevisionViewerCallback',()=>{if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('DocumentOutline')&&(this['editor']['plugins']['get']('DocumentOutlineUI')['view']['element']['style']['display']=''),this['editor']['plugins']['has']('AITabs')){const _0x358fe8=this['editor']['plugins']['get']('AITabs')['view']['panelViews'];for(const _0x5f211a of _0x358fe8)_0x5f211a['class']='ck-tab-panel_disabled'===_0x5f211a['class']?'':_0x5f211a['class']['replace']('\x20ck-tab-panel_disabled','');if(this['editor']['plugins']['has']('AIChat')){const _0x172839=document['querySelector']('.ck-ai-chat__prompt-input\x20.ck-textarea');_0x172839&&_0x172839['removeAttribute']('tabindex');}if(this['editor']['plugins']['has']('AIChatHistory')){const _0x458696=document['querySelector']('.ck-ai-chat-history\x20.ck-input');_0x458696&&_0x458696['removeAttribute']('tabindex');}}return this['_viewerEditor']['plugins']['get']('RevisionViewer')['_cleanUp'](),_0x481898(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x53e059=this['editor']['plugins']['get']('Annotations');_0x53e059['refreshVisibility'](),_0x53e059['refreshPositioning']();}});});}['_showRevisionViewer'](_0x41a5df){const _0x173308=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x574e5f=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x22f0ce=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return RevisionViewerEditor['create'](_0x22f0ce,_0x41a5df)['then'](_0x597980=>(_0x574e5f['style']['display']='block',_0x173308['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x597980));}['_closeRevisionViewer'](_0x29c03c){const _0x2a1ec9=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x2a1ec9['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x29c03c['destroy']();}async['_restoreRevision'](_0x246f2a){const _0x4fac05=this['editor'],_0x5151ca=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x471e0f=_0x4fac05['plugins']['get']('RevisionTracker'),_0x2c4355=_0x4fac05['plugins']['get']('RevisionHistoryUtils'),_0x536061=_0x5151ca['repository']['getRevision'](_0x246f2a);let _0x371744,_0x41944d,_0x35480b;try{await _0x2c4355['loadRevisionData'](_0x536061,this['adapter']),_0x371744=_0x2c4355['getRevisionDocumentData'](_0x536061),_0x41944d=_0x2c4355['getRevisionRootsAttributes'](_0x536061);}catch(_0x4efd2d){return void console['error'](_0x4efd2d);}_0x4fac05['model']['change'](_0x5b542e=>{for(const _0x7f24ee of Array['from'](_0x4fac05['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x5b542e['removeMarker'](_0x7f24ee);}),_0x5151ca['isReady']=!0x1,_0x4fac05['model']['enqueueChange'](_0x2cbf47=>{_0x2cbf47['setSelection'](null),_0x2cbf47['removeSelectionAttribute'](_0x4fac05['model']['document']['selection']['getAttributeKeys']());const _0x1c2c1c=Object['keys'](_0x371744);for(const _0x245f55 of _0x4fac05['model']['document']['roots'])'$graveyard'!=_0x245f55['rootName']&&_0x245f55['isAttached']()&&!_0x1c2c1c['includes'](_0x245f55['rootName'])&&_0x2cbf47['detachRoot'](_0x245f55);for(const _0x6fe4a5 of _0x1c2c1c){let _0x338207=_0x4fac05['model']['document']['getRoot'](_0x6fe4a5);if(!_0x338207||!_0x338207['isAttached']()){const _0x5dfa25=_0x536061['diffData']?.[_0x6fe4a5]?.['rootElementName']||'$root';_0x338207=_0x2cbf47['addRoot'](_0x6fe4a5,_0x5dfa25);}const _0x409623=_0x41944d[_0x6fe4a5],_0x4f0ffb=Object['keys'](_0x409623),_0x3a56d7=_0x371744[_0x6fe4a5];for(const _0xf67af3 of _0x338207['getAttributeKeys']())_0x4f0ffb['includes'](_0xf67af3)||_0x2cbf47['removeAttribute'](_0xf67af3,_0x338207);for(const _0x1b4f9f of _0x4f0ffb)_0x2cbf47['setAttribute'](_0x1b4f9f,_0x41944d[_0x6fe4a5][_0x1b4f9f],_0x338207);_0x2cbf47['remove'](_0x2cbf47['createRangeIn'](_0x338207)),_0x2cbf47['insert'](_0x4fac05['data']['parse'](_0x3a56d7,_0x338207),_0x338207,0x0);}});const _0x41b83f=ft(_0x4fac05['locale'],'Restored');if(_0x536061['name'])_0x35480b=-0x1==_0x536061['name']['indexOf'](_0x41b83f)?_0x41b83f+':\x20'+_0x536061['name']:_0x536061['name'];else _0x35480b=_0x41b83f+':\x20'+(_0x536061['createdAt']['toLocaleDateString'](_0x4fac05['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x536061['createdAt']['toLocaleTimeString'](_0x4fac05['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x471e0f['saveRevision']({'name':_0x35480b}),_0x5151ca['isReady']=!0x0,_0x4fac05['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{RestoreRevisionCommand,Revision,RevisionHistory,RevisionHistoryUI,RevisionHistoryUtils,RevisionTracker,RevisionViewer,RevisionViewerEditor,RevisionViewerIntegration,RevisionViewerLoadingOverlay,RevisionViewerUI,RevisionsRepository,RevisionsSidebar,ShowChangeCommand};
|
|
29
|
+
kt();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[RevisionViewer];}constructor(_0x227219){super(_0x227219),this['_revisionViewer']=_0x227219['plugins']['get'](RevisionViewer),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x21125c=this['_revisionsRepository']['_revisions'],_0x5c9c41=this['_createRevisionActions'](),_0x3843e3=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new RevisionsSidebarView(this['editor']['locale'],_0x21125c,_0x5c9c41,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',(_0x29155c,_0x335fbe)=>{_0x335fbe['revisionViews']['on']('add',(_0x35fd6a,_0x449fc7)=>{_0x449fc7['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)),_0x3843e3['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x4f1985=this['_revisionsRepository']['getRevision'](0x0);if(_0x4f1985){const _0x482c07=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x4f1985['id']);this['_revisionViewer']['compare'](_0x4f1985,_0x482c07);}}['_handleRevisionSelected'](_0x1b7f6d,_0x487502){const _0x3b5523=this['_revisionsRepository']['getRevision'](_0x487502['id']),_0x41a1c2=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x3b5523['id']);this['_revisionViewer']['compare'](_0x3b5523,_0x41a1c2);}['_handleRevisionSetName'](_0x1bd895,_0x408a49){this['_revisionsRepository']['getRevision'](_0x408a49['id'])['setName'](_0x408a49['name']);}['_handleDiffChange'](_0x25d356,_0x149c79,_0x5a3051){const _0x29cea5=this['_revisionsRepository']['getRevisionsInDiff'](_0x5a3051);_0x29cea5['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x29cea5),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x29cea5[0x0]));}['_createRevisionActions'](){const _0x2a654d=this['editor'],_0x2c15ea=RevisionsSidebar['availableRevisionActions'],_0x594257=_0x2a654d['config']['get']('revisionHistory.revisionActions')||RevisionsSidebar['defaultRevisionActions'];if(_0x594257['length'])return _0x594257['map'](_0x51b8e3=>{const _0x2f6007='string'==typeof _0x51b8e3?Object['assign']({},_0x2c15ea[_0x51b8e3]):_0x51b8e3;return _0x2f6007['action']=_0x2f6007['action']['bind'](this,_0x2a654d),_0x2f6007['isVisible']&&(_0x2f6007['isVisible']=_0x2f6007['isVisible']['bind'](this,_0x2a654d)),_0x2f6007;});}}function kt(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x485f5b},_0x1762e9)=>{const _0x2e936f=_0x485f5b['get'](RevisionViewer),_0xebfede=_0x2e936f['repository'];let _0x4aa954=_0x2e936f['diff']['newRevisionId'],_0x5bfdf3=_0x1762e9['id'];_0xebfede['getIndex'](_0x4aa954)>_0xebfede['getIndex'](_0x5bfdf3)&&([_0x4aa954,_0x5bfdf3]=[_0x5bfdf3,_0x4aa954]),_0x2e936f['compare'](_0x4aa954,_0x5bfdf3);},'isVisible':({plugins:_0x4c4ca2},_0x295afe)=>{const _0x11d9c8=_0x4c4ca2['get'](RevisionViewer);return!(_0x11d9c8['repository']['getRevisionsInDiff'](_0x11d9c8['diff'])['length']>0x2)&&!_0x295afe['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x5c9556,{id:_0x5e0520})=>{_0x5c9556['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x5e0520);},'isVisible':({plugins:_0x5f14b2},_0x48bcef)=>!!_0x5f14b2['get'](RevisionViewer)['repository']['getLaterVisibleRevision'](_0x48bcef['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x43d540},{id:_0x1e3b7f,revisionNameView:_0x2e4300})=>{const _0x76c0e=_0x43d540['get'](RevisionViewer),_0x3e757a=_0x76c0e['repository']['getEarlierVisibleRevision'](_0x1e3b7f);_0x76c0e['compare'](_0x1e3b7f,_0x3e757a),_0x2e4300['focus'](),_0x2e4300['fieldView']['select']();}}};}class RevisionViewerEditorUI extends at{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x167372,_0x17f6f4){super(_0x167372),this['_view']=_0x17f6f4,this['_toolbarConfig']=ht(_0x167372['config']['get']('toolbar')),this['_elementReplacer']=new _0x4acda2();}get['element'](){return this['view']['element'];}['init'](_0x1c0db9){const _0x115b80=this['editor'],_0x40e973=this['view'],_0x3d1770=_0x115b80['editing']['view'],_0x4a87c4=_0x40e973['editable'],_0x3bed59=_0x3d1770['document']['getRoot']();_0x4a87c4['name']=_0x3bed59['rootName'],_0x40e973['render']();const _0x3858bf=_0x4a87c4['element'];this['setEditableElement'](_0x4a87c4['name'],_0x3858bf),_0x40e973['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x3d1770['attachDomRoot'](_0x3858bf),this['_elementReplacer']['replace'](_0x1c0db9,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x2b3488=this['view'],_0x3d62f7=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x3d62f7['detachDomRoot'](_0x2b3488['editable']['name']),_0x2b3488['destroy']();}['_initToolbar'](){const _0x21c161=this['view'];_0x21c161['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x21c161['stickyPanel']['limiterElement']=_0x21c161['element'],_0x21c161['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x163c20})=>_0x163c20),_0x21c161['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x21c161['toolbar']);}}class RevisionViewerEditorUIView extends ct{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x4e866c,_0x92f590,_0xe508e={}){super(_0x4e866c),this['stickyPanel']=new lt(_0x4e866c),this['toolbar']=new ut(_0x4e866c,{'shouldGroupWhenFull':_0xe508e['shouldToolbarGroupWhenFull']}),this['_editable']=new dt(_0x4e866c,_0x92f590);}['render'](){super['render'](),this['stickyPanel']['content']['add'](this['toolbar']),this['top']['add'](this['stickyPanel']),this['main']['add'](this['editable']);}}class RevisionViewerEditor extends/* #__PURE__ -- @preserve */
|
|
30
|
+
_0x26f772(_0x278490){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x30d062,_0x324efb){super(_0x324efb),this['sourceElement']=_0x30d062,this['model']['document']['createRoot']();const _0x178446=new RevisionViewerEditorUIView(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new RevisionViewerEditorUI(this,_0x178446);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x22d809,_0x594e46){const _0x3c4bdd=new this(_0x22d809,_0x594e46);return await _0x3c4bdd['initPlugins'](),await _0x3c4bdd['ui']['init'](_0x22d809),await _0x3c4bdd['data']['init'](_0x3c4bdd['config']['get']('initialData')||''),_0x3c4bdd['fire']('ready'),_0x3c4bdd;}}const It=['RevisionHistoryUI','RestrictedEditingMode','AIChat','AIReviewMode','AIBalloon','AIQuickActions','AIActions','AIChatShortcuts','AITranslate'];class RevisionViewerIntegration extends _0x538071{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x49cfe4){function _0x5e6a65(_0x540a43){return _0x540a43['map'](_0x101a32=>String['fromCharCode'](_0x101a32))['join']('');}super(_0x49cfe4),this['result']='end',_0x49cfe4[_0x5e6a65([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x5e6a65([0x76,0x69,0x65,0x77])][_0x5e6a65([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x5e6a65([0x61,0x75,0x74,0x6f]),_0x49cfe4[_0x5e6a65([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x5e6a65([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x5e6a65([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x5e6a65([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x5e6a65([0x6f,0x6b])});}}class RevisionHistory extends _0x538071{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[RevisionTracker,RevisionHistoryUI];}constructor(_0x264422){if(super(_0x264422),!this['editor']['config']['get']('revisionHistory'))throw new _0x423177('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x4a757f=>this['_showRevisionViewer']({..._0x4a757f,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x22069a=>this['_closeRevisionViewer'](_0x22069a)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x56da53=>this['_restoreRevision'](_0x56da53)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x3e5258){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x3e5258;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x584264){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x584264);}['getRevision'](_0x55530f){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x55530f);}['getRevisions'](_0x582463){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x582463||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x38d81a=this['editor'],_0x5454fa=_0x21c68e(_0x38d81a,It),_0x5eb4c5=_0x38d81a['plugins']['get']('RevisionTracker'),_0x123db3=_0x38d81a['plugins']['get'](_0x2baa1d)['users'];return _0x5454fa['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x5454fa['lazyRoots'],(_0x5454fa['plugins']['push'](RevisionViewerIntegration,RevisionViewer,RevisionViewerUI,class RevisionViewerInit extends _0x538071{static get['requires'](){return[RevisionViewer,_0x2baa1d];}['init'](){const _0x130a3b=this['editor']['plugins']['get'](_0x2baa1d);for(const _0x534a86 of _0x123db3)_0x534a86['isAnonymous']||_0x130a3b['getUser'](_0x534a86['id'])||_0x130a3b['addUser'](_0x534a86);const _0x41eac1=_0x5eb4c5['repository']['getRevisions']();let _0x5944d2=null;const _0x814115=this['editor']['plugins']['get']('RevisionViewer');_0x814115['adapter']=_0x5eb4c5['adapter'],_0x814115['bind']('isEnabled')['to'](_0x5eb4c5),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x38d81a,'isReadOnly',_0x462ebb=>!_0x462ebb);for(const _0x3efddb of _0x41eac1){const _0x19b5e6=null===_0x3efddb['creator'];if(_0x19b5e6&&_0x3efddb['toVersion']===_0x3efddb['fromVersion'])continue;const _0x4c82cc=_0x3efddb['toJSON']();_0x814115['addRevisionData'](_0x4c82cc,(_0x2493d6,_0x3f6772,_0x4ed8cb)=>{if(_0x19b5e6){if(_0x5944d2)_0x5944d2['_update'](_0x2493d6,_0x3f6772);else{if(!_0x3f6772){const _0x13f9bf=_0x4ed8cb['toJSON']();_0x13f9bf['id']=_0x51ceb2(),_0x5eb4c5['saveRevision'](_0x13f9bf,_0x4ed8cb['toVersion'])['then'](_0x39cb61=>{_0x5944d2=_0x39cb61;});}}}else _0x3efddb['_update'](_0x2493d6,_0x3f6772);});}}},RevisionsSidebar),_0x5454fa);}['_enhanceShowRevisionViewerCallback'](){const _0x2c64ae=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0xd083d4=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x90b6a7=this['editor']['plugins']['get']('Autosave');await _0x90b6a7['save']();}else await _0xd083d4['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x30581e=this['editor']['plugins']['get']('Dialog');_0x30581e['isOpen']&&_0x30581e['hide']();}if(this['editor']['plugins']['has']('AITabs')){const _0x11d570=this['editor']['plugins']['get']('AITabs')['view']['panelViews'];for(const _0x4fc634 of _0x11d570)_0x4fc634['class']=_0x4fc634['class']?_0x4fc634['class']+'\x20ck-tab-panel_disabled':'ck-tab-panel_disabled';if(this['editor']['plugins']['has']('AIChat')){const _0x4e2bf4=document['querySelector']('.ck-ai-chat__prompt-input\x20.ck-textarea');_0x4e2bf4&&_0x4e2bf4['setAttribute']('tabindex','-1');}if(this['editor']['plugins']['has']('AIChatHistory')){const _0x2d1bb6=document['querySelector']('.ck-ai-chat-history\x20.ck-input');_0x2d1bb6&&_0x2d1bb6['setAttribute']('tabindex','-1');}}const _0x235bdd=this['_getRevisionViewerEditorConfig']();return _0x2c64ae(_0x235bdd)['then'](_0x593705=>{return(this['_viewerEditor']=_0x593705,this['editor']['plugins']['has']('Annotations'))&&this['editor']['plugins']['get']('Annotations')['refreshVisibility'](),(this['editor']['plugins']['has']('DocumentOutline')&&(this['editor']['plugins']['get']('DocumentOutlineUI')['view']['element']['style']['display']='none'),_0x593705);})['catch'](_0x523aa0=>(console['error'](_0x523aa0),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x2be4c7=this['editor']['config']['get']('revisionHistory')['closeRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.closeRevisionViewerCallback',()=>{if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('DocumentOutline')&&(this['editor']['plugins']['get']('DocumentOutlineUI')['view']['element']['style']['display']=''),this['editor']['plugins']['has']('AITabs')){const _0x5bf701=this['editor']['plugins']['get']('AITabs')['view']['panelViews'];for(const _0x1f2318 of _0x5bf701)_0x1f2318['class']='ck-tab-panel_disabled'===_0x1f2318['class']?'':_0x1f2318['class']['replace']('\x20ck-tab-panel_disabled','');if(this['editor']['plugins']['has']('AIChat')){const _0x21c3a7=document['querySelector']('.ck-ai-chat__prompt-input\x20.ck-textarea');_0x21c3a7&&_0x21c3a7['removeAttribute']('tabindex');}if(this['editor']['plugins']['has']('AIChatHistory')){const _0x594fb3=document['querySelector']('.ck-ai-chat-history\x20.ck-input');_0x594fb3&&_0x594fb3['removeAttribute']('tabindex');}}return this['_viewerEditor']['plugins']['get']('RevisionViewer')['_cleanUp'](),_0x2be4c7(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x40bc5d=this['editor']['plugins']['get']('Annotations');_0x40bc5d['refreshVisibility'](),_0x40bc5d['refreshPositioning']();}});});}['_showRevisionViewer'](_0x2fb4a4){const _0xa5650b=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x326c1c=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x43e08b=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return RevisionViewerEditor['create'](_0x43e08b,_0x2fb4a4)['then'](_0x452fe6=>(_0x326c1c['style']['display']='block',_0xa5650b['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x452fe6));}['_closeRevisionViewer'](_0x20e5fe){const _0x2ac452=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x2ac452['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x20e5fe['destroy']();}async['_restoreRevision'](_0x431c98){const _0x107210=this['editor'],_0x404013=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x1ceed1=_0x107210['plugins']['get']('RevisionTracker'),_0x3610db=_0x107210['plugins']['get']('RevisionHistoryUtils'),_0x3e8d5f=_0x404013['repository']['getRevision'](_0x431c98);let _0x3e2678,_0x28f619,_0xf51379;try{await _0x3610db['loadRevisionData'](_0x3e8d5f,this['adapter']),_0x3e2678=_0x3610db['getRevisionDocumentData'](_0x3e8d5f),_0x28f619=_0x3610db['getRevisionRootsAttributes'](_0x3e8d5f);}catch(_0x3aaa59){return void console['error'](_0x3aaa59);}_0x107210['model']['change'](_0x327e00=>{for(const _0x5447aa of Array['from'](_0x107210['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x327e00['removeMarker'](_0x5447aa);}),_0x404013['isReady']=!0x1,_0x107210['model']['enqueueChange'](_0x267580=>{_0x267580['setSelection'](null),_0x267580['removeSelectionAttribute'](_0x107210['model']['document']['selection']['getAttributeKeys']());const _0x40f7ff=Object['keys'](_0x3e2678);for(const _0x399431 of _0x107210['model']['document']['roots'])'$graveyard'!=_0x399431['rootName']&&_0x399431['isAttached']()&&!_0x40f7ff['includes'](_0x399431['rootName'])&&_0x267580['detachRoot'](_0x399431);for(const _0x82696e of _0x40f7ff){let _0x3f62a2=_0x107210['model']['document']['getRoot'](_0x82696e);if(!_0x3f62a2||!_0x3f62a2['isAttached']()){const _0x51b12d=_0x3e8d5f['diffData']?.[_0x82696e]?.['rootElementName']||'$root';_0x3f62a2=_0x267580['addRoot'](_0x82696e,_0x51b12d);}const _0x26fb4b=_0x28f619[_0x82696e],_0x14d467=Object['keys'](_0x26fb4b),_0x41eb21=_0x3e2678[_0x82696e];for(const _0x2a6693 of _0x3f62a2['getAttributeKeys']())_0x14d467['includes'](_0x2a6693)||_0x267580['removeAttribute'](_0x2a6693,_0x3f62a2);for(const _0x25c5aa of _0x14d467)_0x267580['setAttribute'](_0x25c5aa,_0x28f619[_0x82696e][_0x25c5aa],_0x3f62a2);_0x267580['remove'](_0x267580['createRangeIn'](_0x3f62a2)),_0x267580['insert'](_0x107210['data']['parse'](_0x41eb21,_0x3f62a2),_0x3f62a2,0x0);}});const _0x36ca26=ft(_0x107210['locale'],'Restored');if(_0x3e8d5f['name'])_0xf51379=-0x1==_0x3e8d5f['name']['indexOf'](_0x36ca26)?_0x36ca26+':\x20'+_0x3e8d5f['name']:_0x3e8d5f['name'];else _0xf51379=_0x36ca26+':\x20'+(_0x3e8d5f['createdAt']['toLocaleDateString'](_0x107210['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x3e8d5f['createdAt']['toLocaleTimeString'](_0x107210['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x1ceed1['saveRevision']({'name':_0xf51379}),_0x404013['isReady']=!0x0,_0x107210['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{RestoreRevisionCommand,Revision,RevisionHistory,RevisionHistoryUI,RevisionHistoryUtils,RevisionTracker,RevisionViewer,RevisionViewerEditor,RevisionViewerIntegration,RevisionViewerLoadingOverlay,RevisionViewerUI,RevisionsRepository,RevisionsSidebar,ShowChangeCommand};
|