@ckeditor/ckeditor5-revision-history 48.2.0-alpha.6 → 48.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (148) hide show
  1. package/dist/index.js +7 -7
  2. package/dist/translations/af.js +1 -1
  3. package/dist/translations/af.umd.js +1 -1
  4. package/dist/translations/ar.js +1 -1
  5. package/dist/translations/ar.umd.js +1 -1
  6. package/dist/translations/ast.js +1 -1
  7. package/dist/translations/ast.umd.js +1 -1
  8. package/dist/translations/az.js +1 -1
  9. package/dist/translations/az.umd.js +1 -1
  10. package/dist/translations/be.js +1 -1
  11. package/dist/translations/be.umd.js +1 -1
  12. package/dist/translations/bg.js +1 -1
  13. package/dist/translations/bg.umd.js +1 -1
  14. package/dist/translations/bn.js +1 -1
  15. package/dist/translations/bn.umd.js +1 -1
  16. package/dist/translations/bs.js +1 -1
  17. package/dist/translations/bs.umd.js +1 -1
  18. package/dist/translations/ca.js +1 -1
  19. package/dist/translations/ca.umd.js +1 -1
  20. package/dist/translations/cs.js +1 -1
  21. package/dist/translations/cs.umd.js +1 -1
  22. package/dist/translations/da.js +1 -1
  23. package/dist/translations/da.umd.js +1 -1
  24. package/dist/translations/de-ch.js +1 -1
  25. package/dist/translations/de-ch.umd.js +1 -1
  26. package/dist/translations/de.js +1 -1
  27. package/dist/translations/de.umd.js +1 -1
  28. package/dist/translations/el.js +1 -1
  29. package/dist/translations/el.umd.js +1 -1
  30. package/dist/translations/en-au.js +1 -1
  31. package/dist/translations/en-au.umd.js +1 -1
  32. package/dist/translations/en-gb.js +1 -1
  33. package/dist/translations/en-gb.umd.js +1 -1
  34. package/dist/translations/en.js +1 -1
  35. package/dist/translations/en.umd.js +1 -1
  36. package/dist/translations/eo.js +1 -1
  37. package/dist/translations/eo.umd.js +1 -1
  38. package/dist/translations/es-co.js +1 -1
  39. package/dist/translations/es-co.umd.js +1 -1
  40. package/dist/translations/es.js +1 -1
  41. package/dist/translations/es.umd.js +1 -1
  42. package/dist/translations/et.js +1 -1
  43. package/dist/translations/et.umd.js +1 -1
  44. package/dist/translations/eu.js +1 -1
  45. package/dist/translations/eu.umd.js +1 -1
  46. package/dist/translations/fa.js +1 -1
  47. package/dist/translations/fa.umd.js +1 -1
  48. package/dist/translations/fi.js +1 -1
  49. package/dist/translations/fi.umd.js +1 -1
  50. package/dist/translations/fr.js +1 -1
  51. package/dist/translations/fr.umd.js +1 -1
  52. package/dist/translations/gl.js +1 -1
  53. package/dist/translations/gl.umd.js +1 -1
  54. package/dist/translations/gu.js +1 -1
  55. package/dist/translations/gu.umd.js +1 -1
  56. package/dist/translations/he.js +1 -1
  57. package/dist/translations/he.umd.js +1 -1
  58. package/dist/translations/hi.js +1 -1
  59. package/dist/translations/hi.umd.js +1 -1
  60. package/dist/translations/hr.js +1 -1
  61. package/dist/translations/hr.umd.js +1 -1
  62. package/dist/translations/hu.js +1 -1
  63. package/dist/translations/hu.umd.js +1 -1
  64. package/dist/translations/hy.js +1 -1
  65. package/dist/translations/hy.umd.js +1 -1
  66. package/dist/translations/id.js +1 -1
  67. package/dist/translations/id.umd.js +1 -1
  68. package/dist/translations/it.js +1 -1
  69. package/dist/translations/it.umd.js +1 -1
  70. package/dist/translations/ja.js +1 -1
  71. package/dist/translations/ja.umd.js +1 -1
  72. package/dist/translations/jv.js +1 -1
  73. package/dist/translations/jv.umd.js +1 -1
  74. package/dist/translations/kk.js +1 -1
  75. package/dist/translations/kk.umd.js +1 -1
  76. package/dist/translations/km.js +1 -1
  77. package/dist/translations/km.umd.js +1 -1
  78. package/dist/translations/kn.js +1 -1
  79. package/dist/translations/kn.umd.js +1 -1
  80. package/dist/translations/ko.js +1 -1
  81. package/dist/translations/ko.umd.js +1 -1
  82. package/dist/translations/ku.js +1 -1
  83. package/dist/translations/ku.umd.js +1 -1
  84. package/dist/translations/lt.js +1 -1
  85. package/dist/translations/lt.umd.js +1 -1
  86. package/dist/translations/lv.js +1 -1
  87. package/dist/translations/lv.umd.js +1 -1
  88. package/dist/translations/ms.js +1 -1
  89. package/dist/translations/ms.umd.js +1 -1
  90. package/dist/translations/nb.js +1 -1
  91. package/dist/translations/nb.umd.js +1 -1
  92. package/dist/translations/ne.js +1 -1
  93. package/dist/translations/ne.umd.js +1 -1
  94. package/dist/translations/nl.js +1 -1
  95. package/dist/translations/nl.umd.js +1 -1
  96. package/dist/translations/no.js +1 -1
  97. package/dist/translations/no.umd.js +1 -1
  98. package/dist/translations/oc.js +1 -1
  99. package/dist/translations/oc.umd.js +1 -1
  100. package/dist/translations/pl.js +1 -1
  101. package/dist/translations/pl.umd.js +1 -1
  102. package/dist/translations/pt-br.js +1 -1
  103. package/dist/translations/pt-br.umd.js +1 -1
  104. package/dist/translations/pt.js +1 -1
  105. package/dist/translations/pt.umd.js +1 -1
  106. package/dist/translations/ro.js +1 -1
  107. package/dist/translations/ro.umd.js +1 -1
  108. package/dist/translations/ru.js +1 -1
  109. package/dist/translations/ru.umd.js +1 -1
  110. package/dist/translations/si.js +1 -1
  111. package/dist/translations/si.umd.js +1 -1
  112. package/dist/translations/sk.js +1 -1
  113. package/dist/translations/sk.umd.js +1 -1
  114. package/dist/translations/sl.js +1 -1
  115. package/dist/translations/sl.umd.js +1 -1
  116. package/dist/translations/sq.js +1 -1
  117. package/dist/translations/sq.umd.js +1 -1
  118. package/dist/translations/sr-latn.js +1 -1
  119. package/dist/translations/sr-latn.umd.js +1 -1
  120. package/dist/translations/sr.js +1 -1
  121. package/dist/translations/sr.umd.js +1 -1
  122. package/dist/translations/sv.js +1 -1
  123. package/dist/translations/sv.umd.js +1 -1
  124. package/dist/translations/th.js +1 -1
  125. package/dist/translations/th.umd.js +1 -1
  126. package/dist/translations/ti.js +1 -1
  127. package/dist/translations/ti.umd.js +1 -1
  128. package/dist/translations/tk.js +1 -1
  129. package/dist/translations/tk.umd.js +1 -1
  130. package/dist/translations/tr.js +1 -1
  131. package/dist/translations/tr.umd.js +1 -1
  132. package/dist/translations/tt.js +1 -1
  133. package/dist/translations/tt.umd.js +1 -1
  134. package/dist/translations/ug.js +1 -1
  135. package/dist/translations/ug.umd.js +1 -1
  136. package/dist/translations/uk.js +1 -1
  137. package/dist/translations/uk.umd.js +1 -1
  138. package/dist/translations/ur.js +1 -1
  139. package/dist/translations/ur.umd.js +1 -1
  140. package/dist/translations/uz.js +1 -1
  141. package/dist/translations/uz.umd.js +1 -1
  142. package/dist/translations/vi.js +1 -1
  143. package/dist/translations/vi.umd.js +1 -1
  144. package/dist/translations/zh-cn.js +1 -1
  145. package/dist/translations/zh-cn.umd.js +1 -1
  146. package/dist/translations/zh.js +1 -1
  147. package/dist/translations/zh.umd.js +1 -1
  148. package/package.json +10 -10
package/dist/index.js CHANGED
@@ -20,11 +20,11 @@
20
20
  *
21
21
  *
22
22
  */
23
- import{ObservableMixin as _0x5f230a,uid as _0x2d6fd8,Collection as _0x1224a0,logWarning as _0xefa158,FocusTracker as _0x4b88e3,KeystrokeHandler as _0x5c26bb,scrollViewportToShowTarget as _0x1e751e,ResizeObserver as _0x3d48f7,ElementReplacer as _0x1e439a,CKEditorError as _0x3684f0}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x531982,set as _0x25f1fc,unset as _0x2b045d,isEqual as _0x2bf393}from'es-toolkit/compat';import{Plugin as _0x4c1791,PendingActions as _0x4daa0a,Command as _0x323c1f,ElementApiMixin as _0x56a52b,Editor as _0x6aac53}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x48a34e,getMarkerDomElement as _0x3ee994,ConfirmMixin as _0x20e358,sanitizeEditorConfig as _0x505333}from'@ckeditor/ckeditor5-collaboration-core/dist/index.js';import{ViewContainerElement as _0x2dbd6b,ViewAttributeElement as _0x44e60f,ViewEmptyElement as _0x4422b1,ViewRawElement as _0x429ee7,ViewUIElement as _0x5af715,ViewDocumentFragment as _0x2ad0df,ViewText as _0x5330b1,ViewElement as _0x9d29a5,ModelElement as _0x4052b4,ModelRange as _0x5cfc88,ModelPosition as _0x627322,ModelDocumentFragment as _0x54af68,ModelText as _0x354290}from'@ckeditor/ckeditor5-engine/dist/index.js';import{IconHistory as _0x3e8fab,IconChevronUp as _0x319b79,IconChevronDown as _0x2d3c17,IconUndo as _0x11cf6a,IconUser as _0x591bb9,IconThreeVerticalDots as _0x2b6cdd}from'@ckeditor/ckeditor5-icons/dist/index.js';import{CssTransitionDisablerMixin as _0x58cdae,View as _0xb27066,submitHandler as _0x6530a,LabeledFieldView as _0x3dc991,createLabeledInputText as _0x110003,createDropdown as _0xaaea9b,ListView as _0x512836,ListItemView as _0xa9b4cb,ButtonView as _0x1b24ae,MenuBarMenuView as _0x185148,MenuBarMenuListView as _0x430aef,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
- _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
- _0x58cdae(_0xb27066){['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x4a982e,_0x11f336){super(_0x4a982e),this['focusTracker']=new _0x4b88e3(),this['keystrokes']=new _0x5c26bb(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x11f336),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'](),_0x6530a({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0xc6621e=_0x15418f=>_0x15418f['stopPropagation']();this['keystrokes']['set']('arrowright',_0xc6621e),this['keystrokes']['set']('arrowleft',_0xc6621e),this['keystrokes']['set']('arrowup',_0xc6621e),this['keystrokes']['set']('arrowdown',_0xc6621e);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x5f2cbb){this['revisionNameInputView']['fieldView']['element']['value']=_0x5f2cbb['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x336fed){const _0x1b9286=new _0x3dc991(this['locale'],_0x110003),_0x25529e=_0x1b9286['fieldView'];_0x25529e['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x5b987a=ft(this['locale'],'Name\x20of\x20the\x20revision');return!_0x336fed&&(_0x5b987a+='\x20('+ft(this['locale'],'optional')+')'),(_0x1b9286['label']=_0x5b987a,_0x25529e['on']('input',()=>{this['revisionNameInputValue']=_0x25529e['element']['value']['trim']();}),_0x1b9286);}}class RevisionHistoryUI extends _0x4c1791{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[RevisionTracker];}['_saveRevisionFormView'];['init'](){const _0x4a221c=this['editor'],_0x5b2734=_0x4a221c['plugins']['get']('RevisionTracker');_0x4a221c['ui']['componentFactory']['add']('revisionHistory',_0x5df140=>{const _0x342999=_0xaaea9b(_0x5df140),_0x191a5a=_0x342999['panelView']['children'],_0x1efc5a=new _0x512836(_0x5df140),_0xcb6b4e=new _0xa9b4cb(_0x5df140),_0x431c4a=this['_createSaveRevisionButton'](_0x1b24ae),_0x2bbc75=new _0xa9b4cb(_0x5df140),_0x13541b=this['_createOpenRevisionButton'](_0x1b24ae);return _0x342999['bind']('isEnabled')['to'](_0x5b2734,'isReady',_0x5b2734,'isEnabled',_0x4a221c,'isReadOnly',(_0x487cf3,_0x71d9eb,_0x1d8d19)=>_0x487cf3&&_0x71d9eb&&!_0x1d8d19),_0x342999['buttonView']['set']({'icon':_0x3e8fab,'label':ft(_0x5df140,'Revision\x20history'),'tooltip':!0x0}),_0x431c4a['set']({'withText':!0x0,'role':'menuitem'}),_0x13541b['set']({'withText':!0x0,'role':'menuitem'}),this['listenTo'](_0x13541b,'execute',()=>{_0x342999['isOpen']=!0x1,_0x4a221c['editing']['view']['focus']();},{'priority':'low'}),_0xcb6b4e['children']['add'](_0x431c4a),_0x2bbc75['children']['add'](_0x13541b),_0x1efc5a['role']='menu',_0x1efc5a['items']['addMany']([_0xcb6b4e,_0x2bbc75]),_0x191a5a['add'](_0x1efc5a),_0x342999;}),_0x4a221c['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x36a748=this['editor'],_0x2fd334=_0x36a748['locale'],_0x2014bc=_0x36a748['plugins']['get']('RevisionTracker'),_0x4db4ef=new _0x185148(_0x2fd334),_0x444812=new _0x430aef(_0x2fd334);_0x4db4ef['bind']('isEnabled')['to'](_0x2014bc,'isReady',_0x2014bc,'isEnabled',_0x36a748,'isReadOnly',(_0x35cc9c,_0x503ff6,_0x10ab33)=>_0x35cc9c&&_0x503ff6&&!_0x10ab33),_0x4db4ef['buttonView']['set']({'icon':_0x3e8fab,'label':ft(_0x2fd334,'Revision\x20history')});const _0x3c8c84=new tt(_0x2fd334,_0x4db4ef),_0x1e8215=this['_createSaveRevisionButton'](it);_0x1e8215['delegate']('execute')['to'](_0x4db4ef),_0x3c8c84['children']['add'](_0x1e8215),_0x444812['items']['add'](_0x3c8c84);const _0x5c9ff3=new tt(_0x2fd334,_0x4db4ef),_0x3e985c=this['_createOpenRevisionButton'](it);return _0x3e985c['delegate']('execute')['to'](_0x4db4ef),_0x5c9ff3['children']['add'](_0x3e985c),_0x444812['items']['add'](_0x5c9ff3),_0x4db4ef['panelView']['children']['add'](_0x444812),_0x4db4ef;}['_createSaveRevisionButton'](_0x6b46ef){const _0x4b0f76=this['editor'],_0x4040b4=_0x4b0f76['plugins']['get']('RevisionTracker'),_0x6e480=new _0x6b46ef(_0x4b0f76['locale']);return _0x6e480['set']({'label':ft(_0x4b0f76['locale'],'Save\x20current\x20revision')}),_0x6e480['bind']('isEnabled')['to'](_0x4040b4,'isReady',_0x4040b4,'isEnabled',_0x4b0f76,'isReadOnly',(_0x345d6e,_0x57f0fe,_0x5db43e)=>_0x345d6e&&_0x57f0fe&&!_0x5db43e),this['listenTo'](_0x6e480,'execute',()=>{this['_showDialog']();}),_0x6e480;}['_createOpenRevisionButton'](_0x115260){const _0x233c2c=this['editor'],_0x29d6e1=_0x233c2c['plugins']['get']('RevisionTracker'),_0x7c2d4d=new _0x115260(_0x233c2c['locale']);return _0x7c2d4d['set']({'label':ft(_0x233c2c['locale'],'Open\x20revision\x20history')}),_0x7c2d4d['bind']('isEnabled')['to'](_0x29d6e1,'isReady',_0x233c2c,'isReadOnly',(_0x4ef588,_0x5573c0)=>_0x4ef588&&!_0x5573c0),this['listenTo'](_0x7c2d4d,'execute',()=>{_0x233c2c['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x7c2d4d;}['_showDialog'](){const _0x46288a=this['editor'],_0x36a7cb=_0x46288a['locale'],_0x54e03e=_0x46288a['plugins']['get']('Dialog'),_0x1ab703=_0x46288a['plugins']['get']('RevisionTracker');function _0x54d523(_0x1f6b6d){_0x46288a['config']['get']('revisionHistory.requireRevisionName')&&''===_0x1f6b6d['revisionName']?_0x1f6b6d['revisionNameInputView']['errorText']=ft(_0x36a7cb,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x46288a['plugins']['get'](RevisionTracker)['saveRevision']({'name':_0x1f6b6d['revisionName']}),_0x54e03e['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x54d523(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x54e03e['show']({'id':'revisionSave','title':ft(_0x36a7cb,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':ft(_0x46288a['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x54e03e['hide']()},{'label':ft(_0x46288a['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x41c949){_0x41c949['bind']('isEnabled')['to'](_0x1ab703,'isReady',_0x1ab703,'isEnabled',_0x46288a,'isReadOnly',(_0x4544f8,_0x389d85,_0x34f32d)=>_0x4544f8&&_0x389d85&&!_0x34f32d);},'onExecute':()=>_0x54d523(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x3b7b85=this['editor'],_0x21a17b=_0x3b7b85['locale'];this['_saveRevisionFormView']=new RevisionHistorySaveRevisionFormView(_0x21a17b,_0x3b7b85['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class ChangeDetailsView extends _0xb27066{['changeId'];['_model'];constructor(_0x27d520,_0x2b0480){super(_0x27d520),this['_model']=_0x2b0480,this['changeId']=_0x2b0480['id'];const _0xd58257=this['bindTemplate'],_0x2e5092=ft(_0x27d520,_0x2b0480['data']['isSuggestion']?'Suggested\x20by':'add'==_0x2b0480['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x2b0480['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0xd58257['to']('type',_0x432bdd=>'ck-revision-change__'+_0x432bdd)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x2e5092}]},{'text':'\x20'+_0x2b0480['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class ChangeItem extends/* #__PURE__ -- @preserve */
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
- _0x20e358(_0xb27066){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x158f59,_0x2386cd,_0x4420c5,_0x4ca5c8){super(_0x158f59);const _0x469784=this['bindTemplate'],_0x14d093=function(_0x2a4f7d,_0x446bbe){const _0x3cb07f=Array['from'](_0x446bbe['authors'])['filter'](_0x5608f4=>_0x5608f4!=_0x446bbe['creator']);return _0x446bbe['creator']&&_0x3cb07f['unshift'](_0x446bbe['creator']),_0x3cb07f['map'](_0x3ab468=>new RevisionAuthorView(_0x2a4f7d,_0x3ab468,_0x3ab468==_0x446bbe['creator']));}(_0x158f59,_0x2386cd);this['id']=_0x2386cd['id'],this['_revision']=_0x2386cd,this['_requireRevisionName']=_0x4ca5c8,this['bind']('name','createdAt')['to'](_0x2386cd),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x3a10bf=>{return _0x22c23c=_0x158f59['uiLanguage'],(_0x5b803c=_0x3a10bf)['toLocaleDateString'](_0x22c23c,{'month':'long','day':'numeric'})+',\x20'+_0x5b803c['toLocaleTimeString'](_0x22c23c,{'hour':'numeric','minute':'numeric'});var _0x22c23c,_0x5b803c;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new RevisionNameView(_0x158f59,_0x110003),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0xad5987=>_0xad5987||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x5175be,_0x322043)=>_0x5175be&&_0x322043),this['revisionActionsView']=_0x4420c5&&_0x4420c5['length']?Rt(this,_0x4420c5):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x469784['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x469784['if']('isEnabled','ck-disabled',_0x1156c6=>!_0x1156c6),_0x469784['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x469784['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x469784['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':_0x469784['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':_0x14d093}]},this['revisionActionsView']],'on':{'click':_0x469784['to'](_0x2a2d2f=>{_0x2a2d2f['srcElement']['closest']('.ck-confirm-view')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x4f1230=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x4f1230,'change',()=>{this['_requireRevisionName']&&!_0x4f1230['value']||this['fire']('setName',{'id':this['id'],'name':_0x4f1230['value']}),_0x4f1230['value']||(_0x4f1230['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(_0x4eeb0b,_0x3915e7){const _0x1cd405=vt['fromJSDate'](_0x4eeb0b)['setLocale'](_0x3915e7),_0x5a3397=vt['local'](),_0x2e675e=_0x5a3397['minus']({'days':0x1})['startOf']('day');let _0x291152,_0x588c13;return _0x1cd405['hasSame'](_0x5a3397,'day')?(_0x291152=_0x1cd405['startOf']('day')['toJSDate'](),_0x588c13=_0x1cd405['toRelativeCalendar']()):_0x1cd405['hasSame'](_0x2e675e,'day')?(_0x291152=_0x2e675e['toJSDate'](),_0x588c13=_0x1cd405['toRelativeCalendar']()):_0x1cd405['hasSame'](_0x5a3397,'week')?(_0x291152=_0x1cd405['startOf']('week')['toJSDate'](),_0x588c13=_0x1cd405['weekdayLong']||''):_0x1cd405['hasSame'](_0x5a3397,'year')?(_0x291152=_0x1cd405['startOf']('month')['toJSDate'](),_0x588c13=_0x1cd405['monthLong']||''):(_0x291152=_0x1cd405['startOf']('year')['toJSDate'](),_0x588c13=String(_0x1cd405['year'])),{'startDate':_0x291152,'localizedPeriodName':_0x588c13};}class RevisionsSidebarTimePeriodView extends _0xb27066{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x470715,_0xbe1584,_0xd1a956,_0x2e08b2){super(_0x470715);const _0x18ec10=bt(_0xbe1584,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0xbe1584,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0xd1a956,this['_requireRevisionName']=_0x2e08b2,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':_0x18ec10}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x2ce0da){const _0xff2d3=new RevisionView(this['locale'],_0x2ce0da,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0xff2d3);}['removeRevision'](_0x41e318){const _0xc694af=this['revisionViews']['find'](_0xfb660b=>_0xfb660b['id']===_0x41e318['id']);this['revisionViews']['remove'](_0xc694af);}}class RevisionsSidebarHeaderView extends _0xb27066{constructor(_0x5d64e3){super(_0x5d64e3);const _0x92491d=new nt();_0x92491d['content']=_0x3e8fab,this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x92491d,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[ft(_0x5d64e3,'Revision\x20history')]}]});}}class RevisionsSidebarView extends _0xb27066{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x1aa5f9,_0x3d49c9,_0x1fc9b0,_0x1c82ce){super(_0x1aa5f9);const _0x2bd4a2=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x3d49c9,this['_revisionActions']=_0x1fc9b0,this['_requireRevisionName']=_0x1c82ce,this['on']('select',(_0x501cf3,_0x23f9f0)=>{this['fire']('revisionSelected',_0x23f9f0);}),this['on']('setName',(_0x4e83b1,_0xd9a4e3)=>{this['fire']('revisionSetName',_0xd9a4e3);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new RevisionsSidebarHeaderView(_0x1aa5f9),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x2bd4a2['if']('isEnabled','ck-disabled',_0x412f55=>!_0x412f55)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x166345 of this['_revisions'])this['_addRevision'](_0x166345);this['_revisions']['on']('add',(_0xcd993a,_0x2cd092)=>{this['_addRevision'](_0x2cd092);}),this['_revisions']['on']('remove',(_0x1bbf4b,_0x21d705)=>{this['_removeRevision'](_0x21d705);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x2885ac=>_0x2885ac['revisionViews']['map'](_0x1921d6=>_0x1921d6))['flat']();}['selectRevision'](_0x37e0b0){for(const _0x4d8efc of this['revisionViews'])_0x37e0b0&&_0x37e0b0['id']===_0x4d8efc['id']?_0x4d8efc['select']():_0x4d8efc['deselect']();}['highlightRevisions'](_0x5b4e4b){for(const _0x4ccc09 of this['revisionViews'])_0x5b4e4b['some'](({id:_0x1fb18d})=>_0x1fb18d===_0x4ccc09['id'])?_0x4ccc09['highlight']():_0x4ccc09['unhighlight']();}['_addRevision'](_0x4bc0d1){const _0x20dd28=bt(_0x4bc0d1['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x19b310=this['_getTimePeriodViewByStartDate'](_0x20dd28);_0x19b310||(_0x19b310=new RevisionsSidebarTimePeriodView(this['locale'],_0x20dd28,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x19b310)),_0x19b310['addRevision'](_0x4bc0d1);}['_removeRevision'](_0x3d3a3d){const _0x4f2227=bt(_0x3d3a3d['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x4f2227)['removeRevision'](_0x3d3a3d);}['_getTimePeriodViewByStartDate'](_0x3bc3c2){return this['timePeriodViews']['find'](_0x573d08=>_0x573d08['startDate']['getTime']()===_0x3bc3c2['getTime']());}}class RevisionsSidebar extends _0x4c1791{['_revisionViewer'];['_revisionsRepository'];['_sidebarView'];static ['defaultRevisionActions']=/* #__PURE__ -- @preserve */
23
+ import{ObservableMixin as _0x4dc482,uid as _0x439976,Collection as _0xe9e71e,logWarning as _0x17d11b,FocusTracker as _0x204a41,KeystrokeHandler as _0x4d6df5,scrollViewportToShowTarget as _0x387e02,ResizeObserver as _0x1a3a9e,ElementReplacer as _0x1d2c7d,CKEditorError as _0x5107d5}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0xea4767,set as _0x19eb55,unset as _0x433876,isEqual as _0x1afd5b}from'es-toolkit/compat';import{Plugin as _0x3b8836,PendingActions as _0x2a4269,Command as _0x2cc57b,ElementApiMixin as _0x5dad88,Editor as _0x305000}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x51d413,getMarkerDomElement as _0x28ad10,ConfirmMixin as _0x37afc1,sanitizeEditorConfig as _0x4d94e7}from'@ckeditor/ckeditor5-collaboration-core/dist/index.js';import{ViewContainerElement as _0x2b3821,ViewAttributeElement as _0x7e8884,ViewEmptyElement as _0x420bb3,ViewRawElement as _0x41e063,ViewUIElement as _0xe4622e,ViewDocumentFragment as _0x3bad1b,ViewText as _0x232386,ViewElement as _0x59eec1,ModelElement as _0x1a0f77,ModelRange as _0x414021,ModelPosition as _0x461e8e,ModelDocumentFragment as _0x538fb3,ModelText as _0xa58127}from'@ckeditor/ckeditor5-engine/dist/index.js';import{IconHistory as _0x184ecc,IconChevronUp as _0x3bea5a,IconChevronDown as _0x32087f,IconUndo as _0x5065e8,IconUser as _0x2f3753,IconThreeVerticalDots as _0x3ed45e}from'@ckeditor/ckeditor5-icons/dist/index.js';import{CssTransitionDisablerMixin as _0xd8f0c9,View as _0x6b0c43,submitHandler as _0x11315e,LabeledFieldView as _0x7cd47d,createLabeledInputText as _0x1fb48d,createDropdown as _0xcc940,ListView as _0x47cf56,ListItemView as _0x55e3f4,ButtonView as _0x8647ff,MenuBarMenuView as _0x564222,MenuBarMenuListView as _0x3cbddb,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
+ _0x4dc482(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x30b1a9){super(),this['id']=_0x30b1a9['id']||_0x439976(),this['creator']=_0x30b1a9['creator']||null,this['authors']=_0x30b1a9['authors']||[],this['diffData']=_0x30b1a9['diffData']||null,this['toVersion']=_0x30b1a9['toVersion']||0x0,this['fromVersion']=_0x30b1a9['fromVersion']||0x0,this['set']('name',_0x30b1a9['name']||''),this['set']('createdAt',_0x30b1a9['createdAt']||new Date()),this['set']('attributes',_0x30b1a9['attributes']||{});}['setName'](_0x1e1926){this['_update']({'name':_0x1e1926});}['setAttribute'](_0x59d306,_0x5b7039){const _0x10a452=_0xea4767(this['attributes']);_0x19eb55(_0x10a452,_0x59d306,_0x5b7039),this['_update']({'attributes':_0x10a452});}['removeAttribute'](_0x5a0fdf){const _0x258253=_0xea4767(this['attributes']);_0x433876(_0x258253,_0x5a0fdf),this['_update']({'attributes':_0x258253});}['_update'](_0x83af5a,_0x432241=!0x1){let _0x4baa68=!0x1;const _0x5490bb={'id':this['id']},_0x110b10=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x44155a of _0x110b10){const _0x52cb3f=_0x83af5a[_0x44155a];void 0x0!==_0x52cb3f&&_0x52cb3f!==this[_0x44155a]&&(this[_0x44155a]=_0x52cb3f,_0x5490bb[_0x44155a]=_0x52cb3f,_0x4baa68=!0x0);}_0x4baa68&&(_0x5490bb['authors']&&(_0x5490bb['authorsIds']=_0x5490bb['authors']['map'](_0x30547d=>_0x30547d['id']),delete _0x5490bb['authors']),this['fire']('_update',_0x5490bb,_0x432241));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x50d070=>_0x50d070['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class RevisionsRepository extends _0x3b8836{['_revisions'];static get['requires'](){return[_0x51d413];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x252061){super(_0x252061),this['_revisions']=new _0xe9e71e();}['afterInit'](){!async function(_0xb295bc){const _0xab70f1=_0x54830e([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]),_0x45e882=0xeb829,_0x1b9c92=0x359e09b0,_0xde71cf=0x35998260^_0x1b9c92,_0x149559=window[_0x54830e([0x44,0x61,0x74,0x65])][_0x54830e([0x6e,0x6f,0x77])](),_0x582c71=_0xb295bc[_0x54830e([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x12ab9a=new window[(_0x54830e([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x5d59c1=>{_0x582c71[_0x54830e([0x6f,0x6e,0x63,0x65])](_0x54830e([0x72,0x65,0x61,0x64,0x79]),_0x5d59c1);}),_0x278bbf={[_0x54830e([0x6b,0x74,0x79])]:_0x54830e([0x45,0x43]),[_0x54830e([0x75,0x73,0x65])]:_0x54830e([0x73,0x69,0x67]),[_0x54830e([0x63,0x72,0x76])]:_0x54830e([0x50,0x2d,0x32,0x35,0x36]),[_0x54830e([0x78])]:_0x54830e([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]),[_0x54830e([0x79])]:_0x54830e([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]),[_0x54830e([0x61,0x6c,0x67])]:_0x54830e([0x45,0x53,0x32,0x35,0x36])},_0x4e7b07=_0x582c71[_0x54830e([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x54830e([0x67,0x65,0x74])](_0x54830e([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x89e8f8(){let _0x19b7ef,_0x462461=null,_0x340397=null;try{if(_0x4e7b07==_0x54830e([0x47,0x50,0x4c]))return _0x54830e([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x19b7ef=_0x21d0eb(),!_0x19b7ef)return _0x54830e([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x19b7ef[_0x54830e([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x340397=_0x12e1a5(_0x19b7ef[_0x54830e([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x19b7ef[_0x54830e([0x6a,0x74,0x69])])),await _0x1c5a17()?_0x58c0e6()?_0x81784()?_0x54830e([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x1c1c12()?(_0x19b7ef[_0x54830e([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x54830e([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x462461=_0x2500cf(_0x54830e([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),await _0x4aeed0()):_0x54830e([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x54830e([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x54830e([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x54830e([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x81784(){const _0xcc318=[_0x54830e([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x54830e([0x74,0x72,0x69,0x61,0x6c])][_0x54830e([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x19b7ef[_0x54830e([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x149559/0x3e8:0xe10*_0xde71cf;return _0x19b7ef[_0x54830e([0x65,0x78,0x70])]<_0xcc318;}function _0x58c0e6(){const _0x2aaca8=_0x19b7ef[_0x54830e([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x2aaca8)return!0x1;if(_0x2aaca8[_0x54830e([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x54830e([0x2a])))return!0x0;if(_0x2aaca8[_0x54830e([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x54830e([0x52,0x48])))return!0x0;if(_0x2aaca8[_0x54830e([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x54830e([0x52,0x52,0x48]))){if(_0x4c2dee())return!0x0;if(_0x54e277()||_0x14d9a8())return!0x0;}return!0x1;}function _0x1c1c12(){const _0x531de9=_0x19b7ef[_0x54830e([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x531de9||0x0==_0x531de9[_0x54830e([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x94ef27}=new URL(window[_0x54830e([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x531de9[_0x54830e([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x94ef27))return!0x0;const _0x36070d=_0x94ef27[_0x54830e([0x73,0x70,0x6c,0x69,0x74])](_0x54830e([0x2e]));return _0x531de9[_0x54830e([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x1fa302=>_0x1fa302[_0x54830e([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x54830e([0x2a])))[_0x54830e([0x6d,0x61,0x70])](_0x591427=>_0x591427[_0x54830e([0x73,0x70,0x6c,0x69,0x74])](_0x54830e([0x2e])))[_0x54830e([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x996cea=>_0x996cea[_0x54830e([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x36070d[_0x54830e([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x54830e([0x6d,0x61,0x70])](_0x47d65=>Array(_0x36070d[_0x54830e([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0x47d65[_0x54830e([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x54830e([0x66,0x69,0x6c,0x6c])](_0x47d65[0x0]===_0x54830e([0x2a])?_0x54830e([0x2a]):'')[_0x54830e([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0x47d65))[_0x54830e([0x73,0x6f,0x6d,0x65])](_0x25fc6d=>_0x36070d[_0x54830e([0x65,0x76,0x65,0x72,0x79])]((_0x2d9632,_0x1cad61)=>_0x25fc6d[_0x1cad61]===_0x2d9632||_0x25fc6d[_0x1cad61]===_0x54830e([0x2a])));}function _0x4aeed0(){return _0x462461&&_0x340397?new window[(_0x54830e([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x6c868e,_0x30b420)=>{_0x462461[_0x54830e([0x74,0x68,0x65,0x6e])](_0x6c868e,_0x30b420),_0x340397[_0x54830e([0x74,0x68,0x65,0x6e])](_0x3d9dc4=>{_0x3d9dc4!=_0x54830e([0x56,0x61,0x6c,0x69,0x64])&&_0x6c868e(_0x3d9dc4);},_0x30b420);}):_0x462461||_0x340397||_0x54830e([0x56,0x61,0x6c,0x69,0x64]);}}function _0x12e1a5(_0x18ac2c,_0x5834e4){return new window[(_0x54830e([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x1800a1=>{if(_0x1ca092())return _0x1800a1(_0x54830e([0x56,0x61,0x6c,0x69,0x64]));_0x1bc309(),_0x582c71[_0x54830e([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x54830e([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x1608ca=!0x1;const _0x87716d=_0x439976();function _0x4e873b(_0x12b019){return!!_0x12b019&&(typeof _0x12b019===_0x54830e([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x12b019===_0x54830e([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x12b019[_0x54830e([0x74,0x68,0x65,0x6e])]===_0x54830e([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x12b019[_0x54830e([0x63,0x61,0x74,0x63,0x68])]===_0x54830e([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x8f42c8(_0x26776f){_0x5e6e93(_0x26776f)[_0x54830e([0x74,0x68,0x65,0x6e])](_0xfd1e03=>{if(!_0xfd1e03||_0xfd1e03[_0x54830e([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x54830e([0x6f,0x6b]))return _0x54830e([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x2d8c88(_0x25486d(_0x87716d+_0x5834e4))!=_0xfd1e03[_0x54830e([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x54830e([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x54830e([0x56,0x61,0x6c,0x69,0x64]);})[_0x54830e([0x74,0x68,0x65,0x6e])](_0x4e2237=>(_0x4caf53(),_0x4e2237),()=>{const _0x110a79=_0x202137();return null==_0x110a79?(_0x4caf53(),_0x54830e([0x56,0x61,0x6c,0x69,0x64])):_0x54830e(_0x149559-_0x110a79>(0x11928db0^_0x1b9c92)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x54830e([0x74,0x68,0x65,0x6e])](_0x1800a1)[_0x54830e([0x63,0x61,0x74,0x63,0x68])](()=>{_0x1800a1(_0x54830e([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x44af92=0x35a8e730^_0x1b9c92;function _0x4caf53(){const _0x50f3bd=_0x54830e([0x6c,0x6c,0x63,0x74,0x2d])+_0x2d8c88(_0x25486d(_0x18ac2c)),_0x5cc271=_0x4d3141(_0x2d8c88(window[_0x54830e([0x4d,0x61,0x74,0x68])][_0x54830e([0x63,0x65,0x69,0x6c])](_0x149559/_0x44af92)));window[_0x54830e([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x54830e([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x50f3bd,_0x5cc271);}function _0x202137(){const _0x1dfa66=_0x54830e([0x6c,0x6c,0x63,0x74,0x2d])+_0x2d8c88(_0x25486d(_0x18ac2c)),_0xb5db0f=window[_0x54830e([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x54830e([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x1dfa66);return _0xb5db0f?window[_0x54830e([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x4d3141(_0xb5db0f),0x10)*_0x44af92:null;}function _0x5e6e93(_0x1ce7d3){return new window[(_0x54830e([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x23c66d,_0x544b11)=>{_0x1ce7d3[_0x54830e([0x74,0x68,0x65,0x6e])](_0x23c66d,_0x544b11),window[_0x54830e([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x544b11,0x359fdd70^_0x1b9c92);});}}_0x582c71[_0x54830e([0x6f,0x6e])](_0x54830e([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x5b4612,_0x46fdda)=>{if(_0x46fdda[0x0]!=_0x18ac2c)return _0x1800a1(_0x54830e([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x46fdda[0x1]={..._0x46fdda[0x1],[_0x54830e([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x87716d};},{[_0x54830e([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x54830e([0x68,0x69,0x67,0x68])}),_0x582c71[_0x54830e([0x6f,0x6e])](_0x54830e([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0xa3b85b=>{_0x4e873b(_0xa3b85b[_0x54830e([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x1608ca=!0x0,_0x8f42c8(_0xa3b85b[_0x54830e([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x54830e([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x54830e([0x6c,0x6f,0x77])}),_0x12ab9a[_0x54830e([0x74,0x68,0x65,0x6e])](()=>{_0x1608ca||_0x1800a1(_0x54830e([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x1ca092(){return _0x582c71[_0x54830e([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x54830e([0x76,0x69,0x65,0x77])][_0x54830e([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x54830e([0x61,0x75,0x74,0x6f]);}function _0x1bc309(){_0x582c71[_0x54830e([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x54830e([0x76,0x69,0x65,0x77])][_0x54830e([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x54830e([0x61,0x75,0x74,0x6f]);}}function _0x2500cf(_0x82e3ec){const _0xad9f7a=[new window[(_0x54830e([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0xad7556=>setTimeout(_0xad7556,0x3597377c^_0x1b9c92)),_0x12ab9a[_0x54830e([0x74,0x68,0x65,0x6e])](()=>new window[(_0x54830e([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x486f99=>{const _0x41097d=0x359e09b7^_0x1b9c92,_0x5f4c7f=_0xb295bc[_0x54830e([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x42580b(){_0x5f4c7f[_0x54830e([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x41097d&&_0x486f99();}_0x42580b(),_0x5f4c7f[_0x54830e([0x6f,0x6e])](_0x54830e([0x61,0x64,0x64]),_0x42580b);})),new window[(_0x54830e([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x178f1e=>{function _0x3aafb7(){for(const _0xbe2a97 in window)if(window[_0x54830e([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x54830e([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0xbe2a97))&&window[_0xbe2a97]==_0x45e882)return _0x178f1e();_0x582c71[_0x54830e([0x73,0x74,0x61,0x74,0x65])]!=_0x54830e([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x54830e([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x3aafb7,0x359e1a38^_0x1b9c92);}_0x36a4fb(_0x54830e([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x3aafb7();})];return window[_0x54830e([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x54830e([0x72,0x61,0x63,0x65])](_0xad9f7a)[_0x54830e([0x74,0x68,0x65,0x6e])](()=>_0x82e3ec);}async function _0x356185(){if(await _0x12ab9a,_0x36a4fb(_0x54830e([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x4f79c0=_0xb295bc[_0x54830e([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x19a0bf=_0xb295bc[_0x54830e([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])](_0x4f79c0[_0x54830e([0x69,0x64])]),_0x30cbe0=_0x374080(_0x54830e([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x30cbe0[_0x54830e([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x4f79c0['id'],_0x19a0bf?_0x19a0bf['id']:null,!0x0),_0x30cbe0[_0x54830e([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x54830e([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x30cbe0[_0x54830e([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x30cbe0[_0x54830e([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x410f39,void(_0x30cbe0[_0x54830e([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x410f39);}if(_0x36a4fb(_0x54830e([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x1392ab=_0x374080(_0x54830e([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x1392ab[_0x54830e([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x54830e([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x1392ab[_0x54830e([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x1392ab[_0x54830e([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x410f39,_0x1392ab[_0x54830e([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x410f39;}_0x582c71[_0x54830e([0x6d,0x6f,0x64,0x65,0x6c])][_0x54830e([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x410f39,_0x582c71[_0x54830e([0x6d,0x6f,0x64,0x65,0x6c])][_0x54830e([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x410f39,_0x582c71[_0x54830e([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x54830e([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x4c2dee(){return _0x36a4fb(_0x54830e([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x374080(_0x54830e([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x54830e([0x73,0x74,0x61,0x74,0x65])]==_0x54830e([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x54e277(){return _0x36a4fb(_0x54830e([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 _0x14d9a8(){return _0x36a4fb(_0x54830e([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0xdb009a(_0x34e88a){const _0x4a9b1e=_0x55164e();_0x582c71[_0x4a9b1e]=_0x54830e([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])+_0x34e88a,_0x34e88a[_0x54830e([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x54830e([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x55164e()]=_0x45e882),_0x34e88a!=_0x54830e([0x56,0x61,0x6c,0x69,0x64])&&_0x356185();}function _0x55164e(){const _0x3470d6=window[_0x54830e([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x54830e([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x54830e([0x6e,0x6f,0x77])]())[_0x54830e([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x54830e([0x2e]),'');let _0x2309c9=_0x54830e([0x76]);for(let _0x2d5521=0x0;_0x2d5521<_0x3470d6[_0x54830e([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x2d5521+=0x2){let _0xbbe506=window[_0x54830e([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x3470d6[_0x54830e([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x2d5521,_0x2d5521+0x2));_0xbbe506>=_0xab70f1[_0x54830e([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0xbbe506-=_0xab70f1[_0x54830e([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x2309c9+=_0xab70f1[_0xbbe506];}return _0x2309c9;}function _0x21d0eb(){const _0x4f36cc=_0x4e7b07[_0x54830e([0x73,0x70,0x6c,0x69,0x74])](_0x54830e([0x2e]));if(0x3!=_0x4f36cc[_0x54830e([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x2a7365(_0x4f36cc[0x1]);function _0x2a7365(_0x558904){const _0x14ab47=_0x1d10fa(_0x558904);return _0x14ab47&&_0x1f7455()?_0x14ab47:null;function _0x1f7455(){const _0x218a80=_0x14ab47[_0x54830e([0x6a,0x74,0x69])],_0x310ed3=window[_0x54830e([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x218a80[_0x54830e([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x218a80[_0x54830e([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x1635ae={..._0x14ab47,[_0x54830e([0x6a,0x74,0x69])]:_0x218a80[_0x54830e([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x218a80[_0x54830e([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x1635ae[_0x54830e([0x76,0x63])],_0x25486d(_0x1635ae)==_0x310ed3;}}}async function _0x1c5a17(){let _0x88354d=!0x0;try{const _0x11bfb6=_0x4e7b07[_0x54830e([0x73,0x70,0x6c,0x69,0x74])](_0x54830e([0x2e])),[_0x559354,_0xdc523e,_0x147f47]=_0x11bfb6;return _0x2cf521(_0x559354),await _0x1b6180(_0x559354,_0xdc523e,_0x147f47),_0x88354d;}catch{return!0x1;}function _0x2cf521(_0x202dc0){const _0x407a76=_0x1d10fa(_0x202dc0);_0x407a76&&_0x407a76[_0x54830e([0x61,0x6c,0x67])]==_0x54830e([0x45,0x53,0x32,0x35,0x36])||(_0x88354d=!0x1);}async function _0x1b6180(_0xb92356,_0x3aa467,_0x146497){const _0x327707=window[_0x54830e([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x54830e([0x66,0x72,0x6f,0x6d])](_0x2013e0(_0x146497),_0x31428d=>_0x31428d[_0x54830e([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x2f1148=new window[(_0x54830e([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x54830e([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0xb92356+_0x54830e([0x2e])+_0x3aa467),_0x5de535=window[_0x54830e([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x54830e([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x5de535)return;const _0x3b7f4a=await _0x5de535[_0x54830e([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x54830e([0x6a,0x77,0x6b]),_0x278bbf,{[_0x54830e([0x6e,0x61,0x6d,0x65])]:_0x54830e([0x45,0x43,0x44,0x53,0x41]),[_0x54830e([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x54830e([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x54830e([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x5de535[_0x54830e([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x54830e([0x6e,0x61,0x6d,0x65])]:_0x54830e([0x45,0x43,0x44,0x53,0x41]),[_0x54830e([0x68,0x61,0x73,0x68])]:{[_0x54830e([0x6e,0x61,0x6d,0x65])]:_0x54830e([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x3b7f4a,_0x327707,_0x2f1148)||(_0x88354d=!0x1);}}function _0x1d10fa(_0x20a692){return _0x20a692[_0x54830e([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x54830e([0x65,0x79]))?JSON[_0x54830e([0x70,0x61,0x72,0x73,0x65])](_0x2013e0(_0x20a692)):null;}function _0x2013e0(_0x4536a4){return window[_0x54830e([0x61,0x74,0x6f,0x62])](_0x4536a4[_0x54830e([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x54830e([0x2b]))[_0x54830e([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x54830e([0x2f])));}function _0x25486d(_0xc76072){let _0x56541a=0x1505;function _0x4c7021(_0x2d064a){for(let _0x433577=0x0;_0x433577<_0x2d064a[_0x54830e([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x433577++){const _0x358769=_0x2d064a[_0x54830e([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x433577);_0x56541a=(_0x56541a<<0x5)+_0x56541a+_0x358769,_0x56541a&=_0x56541a;}}function _0x31fe13(_0x4857ab){Array[_0x54830e([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x4857ab)?_0x4857ab[_0x54830e([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x31fe13):_0x4857ab&&typeof _0x4857ab==_0x54830e([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x54830e([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x4857ab)[_0x54830e([0x73,0x6f,0x72,0x74])]()[_0x54830e([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x9526a3,_0x49ad28])=>{_0x4c7021(_0x9526a3),_0x31fe13(_0x49ad28);}):_0x4c7021(window[_0x54830e([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x4857ab));}return _0x31fe13(_0xc76072),_0x56541a>>>0x0;}function _0x2d8c88(_0xfcfec7){return _0xfcfec7[_0x54830e([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x54830e([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x54830e([0x30]));}function _0x4d3141(_0x410d0e){return _0x410d0e[_0x54830e([0x73,0x70,0x6c,0x69,0x74])]('')[_0x54830e([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x54830e([0x6a,0x6f,0x69,0x6e])]('');}function _0x36a4fb(_0x125440){return _0x582c71[_0x54830e([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x54830e([0x68,0x61,0x73])](_0x125440);}function _0x374080(_0x29bc04){return _0x582c71[_0x54830e([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x54830e([0x67,0x65,0x74])](_0x29bc04);}function _0x410f39(){}function _0x54830e(_0x391b6f){return _0x391b6f['map'](_0x417ce5=>String['fromCharCode'](_0x417ce5))['join']('');}_0xdb009a(await _0x89e8f8());}(this);}['createRevision'](_0x2d6900){const _0x13d148=this['editor']['plugins']['get']('Users');return new Revision({'id':_0x2d6900['id'],'name':_0x2d6900['name'],'creator':_0x2d6900['creatorId']?_0x13d148['getUser'](_0x2d6900['creatorId']):null,'diffData':_0x2d6900['diffData']||_0x2d6900['data'],'authors':_0x2d6900['authorsIds']['map'](_0x31c8f4=>_0x13d148['getUser'](_0x31c8f4)),'createdAt':new Date(_0x2d6900['createdAt']),'attributes':_0x2d6900['attributes'],'fromVersion':_0x2d6900['fromVersion'],'toVersion':_0x2d6900['toVersion']});}['addRevision'](_0x45f265,_0x139966=0x0){this['_revisions']['add'](_0x45f265,_0x139966);}['getRevision'](_0x2b8e51){return this['_revisions']['get'](_0x2b8e51);}['getRevisions'](_0x28174c={'toJSON':!0x1}){const _0xdfb587=Array['from'](this['_revisions']);return _0xdfb587['reverse'](),_0x28174c['toJSON']?_0xdfb587['map'](_0x122240=>_0x122240['toJSON']()):_0xdfb587;}['getIndex'](_0x273bbd){return this['_revisions']['getIndex'](_0x273bbd);}['getEarlierVisibleRevision'](_0x40ee1e){const [,_0xad0447]=this['getRevisionsIterator'](_0x40ee1e,{'direction':'earlier'});return _0xad0447;}['getLaterVisibleRevision'](_0x5c5414){const [,_0x68746a]=this['getRevisionsIterator'](_0x5c5414,{'direction':'later'});return _0x68746a;}['getRevisionsInDiff'](_0x31722c){const _0x5a60a2=[];for(const _0xa9905 of this['getRevisionsIterator'](_0x31722c['newRevisionId']))if(_0x5a60a2['push'](_0xa9905),_0xa9905['id']===_0x31722c['oldRevisionId'])break;return _0x5a60a2;}*['getRevisionsIterator'](_0x215655,{direction:_0x2cacf2='earlier',filter:_0x23e5b4=()=>!0x0}={}){const _0x3424ff='earlier'===_0x2cacf2?0x1:-0x1;let _0x417b4d=this['_revisions']['get'](_0x215655),_0x344a46=this['getIndex'](_0x417b4d);for(yield _0x417b4d;_0x417b4d;){if(_0x344a46+=_0x3424ff,_0x417b4d=this['getRevision'](_0x344a46),!_0x417b4d)return;_0x23e5b4(_0x417b4d)&&(yield _0x417b4d);}}}class RevisionHistoryUtils extends _0x3b8836{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x2b3821,'c'],[_0x7e8884,'a'],[_0x420bb3,'e'],[_0x41e063,'r'],[_0xe4622e,'u']]);['_typeCharToViewClass']=new Map([['c',_0x2b3821],['a',_0x7e8884],['e',_0x420bb3],['r',_0x41e063],['u',_0xe4622e]]);async['loadRevisionData'](_0x360bd3,_0x2429f4){if(_0x360bd3['diffData']||!_0x2429f4)return;const _0x24405e=this['editor']['config']['get']('collaboration.channelId'),_0x3318b7=await _0x2429f4['getRevision']({'channelId':_0x24405e,'revisionId':_0x360bd3['id']});_0x360bd3['diffData']=_0x3318b7['diffData'];}['getRevisionDocumentData'](_0x3f0f7a){const _0x1375ef={};for(const _0x3f14b9 in _0x3f0f7a['diffData']){if(_0x3f0f7a['diffData'][_0x3f14b9]['attachChange']&&!_0x3f0f7a['diffData'][_0x3f14b9]['attachChange']['isAttached'])continue;const _0x8e6a48=this['_removeRevisionMarkers'](JSON['parse'](_0x3f0f7a['diffData'][_0x3f14b9]['insertions'])),_0x54191c=this['editor']['editing']['view']['document'],_0xcfbaec=new _0x3bad1b(_0x54191c,_0x8e6a48['map'](_0x7e0887=>this['_getViewFromDiffObj'](_0x7e0887,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x1375ef[_0x3f14b9]=this['editor']['data']['processor']['toData'](_0xcfbaec),this['editor']['data']['processor']['useFillerType']('default');}return _0x1375ef;}['getRevisionRootsAttributes'](_0x12d362){const _0x95aa09={};for(const _0x25f58a in _0x12d362['diffData'])_0x12d362['diffData'][_0x25f58a]['attachChange']&&!_0x12d362['diffData'][_0x25f58a]['attachChange']['isAttached']||(_0x95aa09[_0x25f58a]=_0x12d362['diffData'][_0x25f58a]['attributesAfter']||{});return _0x95aa09;}['getRevisionRootsModelElements'](_0x52944a){const _0x4ae5e1={};for(const _0x45ddec in _0x52944a['diffData']){if(_0x52944a['diffData'][_0x45ddec]['attachChange']&&!_0x52944a['diffData'][_0x45ddec]['attachChange']['isAttached'])continue;const _0x499c95=_0x52944a['diffData'][_0x45ddec]['rootElementName'];_0x499c95&&(_0x4ae5e1[_0x45ddec]=_0x499c95);}return _0x4ae5e1;}['_getTypeCharForViewElement'](_0x5be5d3){return this['_viewClassToTypeChar']['get'](_0x5be5d3['constructor']);}['_getViewFromDiffObj'](_0x479caa,_0xada8c3){const _0x3e74c8=this['editor']['editing']['view']['document'];if('string'==typeof _0x479caa)return new _0x232386(_0x3e74c8,_0x479caa);{let _0x553a33,_0x5cb5db;_0x5cb5db='u'==_0x479caa['type']||'r'==_0x479caa['type']?[]:_0x479caa['children']['map'](_0x522a1a=>this['_getViewFromDiffObj'](_0x522a1a,_0xada8c3));const _0x3967cc=this['_typeCharToViewClass']['get'](_0x479caa['type'])||_0x59eec1,_0x5d2be0=this['editor']['data']['htmlProcessor']['domConverter'];if(_0x553a33=new _0x3967cc(_0x3e74c8,_0x479caa['name'],_0x479caa['attributes'],_0x5cb5db),'u'==_0x479caa['type']&&_0x479caa['children'][0x0]){const _0x94db7b=_0x479caa['children'][0x0];if(_0x553a33['render']=function(_0x41cb56){const _0x4e6cef=_0x41cb56['createElement']('div');return _0x4e6cef['innerHTML']=_0x94db7b,_0x4e6cef['childNodes'][0x0];},_0xada8c3){const _0x171357=new _0x3bad1b(_0x3e74c8);_0x171357['_appendChild'](_0x553a33);const _0x490f34=Array['from'](_0x5d2be0['viewChildrenToDom'](_0x171357,{'bind':!0x1})),_0x248871=_0x5d2be0['domDocument']['createElement']('div');_0x248871['append'](..._0x490f34),_0x553a33=Array['from'](_0x5d2be0['domChildrenToView'](_0x248871))[0x0];}}else{if('r'==_0x479caa['type']&&_0x479caa['children'][0x0]){const _0x55dae1=_0x479caa['children'][0x0];if(_0x553a33['render']=function(_0x1d1a84){_0x1d1a84['innerHTML']=_0x55dae1;},_0xada8c3){const _0x58db5e=new _0x3bad1b(_0x3e74c8);_0x58db5e['_appendChild'](_0x553a33);const _0x428a23=Array['from'](_0x5d2be0['viewChildrenToDom'](_0x58db5e,{'bind':!0x1})),_0x59f436=_0x5d2be0['domDocument']['createElement']('div');_0x59f436['append'](..._0x428a23);const _0x4358f4=Array['from'](_0x5d2be0['domChildrenToView'](_0x59f436));_0x4358f4['length']>0x1?_0x553a33['_appendChild'](_0x4358f4):_0x553a33=_0x4358f4[0x0];}}}if(_0x479caa['customProperties']){for(const [_0x4a86bb,_0x3fc348]of _0x479caa['customProperties'])_0x553a33['_setCustomProperty'](_0x4a86bb,_0x3fc348);}const _0x1fa5bf=void 0x0===_0x479caa['fillerOffset']?null:_0x479caa['fillerOffset'];return null!==_0x1fa5bf&&(_0x553a33['getFillerOffset']=()=>_0x1fa5bf),_0x553a33;}}['_makeModelFromViewString'](_0x17153e,_0x3c90c7){const _0x5caa3e=JSON['parse'](_0x17153e),_0x2786a6=this['editor']['editing']['view']['document'],_0x2419e3=new _0x3bad1b(_0x2786a6,_0x5caa3e['map'](_0x2e1213=>this['_getViewFromDiffObj'](_0x2e1213,!0x0))),_0x4035f7=this['editor']['data']['toModel'](_0x2419e3,_0x3c90c7);return _0x4035f7['name']=_0x3c90c7,_0x4035f7;}['_removeRevisionMarkers'](_0x41f166){return(_0x41f166=_0x41f166['filter'](_0x366ff3=>!_0x366ff3['name']||'revision-start'!==_0x366ff3['name']&&'revision-end'!==_0x366ff3['name']))['forEach'](_0x5e63b3=>{'string'!=typeof _0x5e63b3&&(_0x5e63b3['children']=this['_removeRevisionMarkers'](_0x5e63b3['children']),_0x5e63b3['attributes']=_0x5e63b3['attributes']['filter'](_0x49810a=>!_0x49810a[0x0]['startsWith']('data-revision-')));}),_0x41f166;}}function ft(_0x18605e,_0x4adfb8,_0x408be8){const t=_0x18605e['t'];switch(_0x4adfb8){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'},_0x408be8);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x408be8);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 _0x3b8836{['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[_0x51d413,RevisionsRepository,RevisionHistoryUtils,_0x2a4269];}constructor(_0xcb5b68){super(_0xcb5b68),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 _0x573643=_0x439976();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x573643},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 _0x33e1d9=this['repository']['getRevision'](0x0),_0x4e3824=_0x33e1d9&&null===_0x33e1d9['creator']?_0x33e1d9:null;if(this['_continueCurrentRevision']=!!_0x4e3824&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x485229=this['_source']['getCurrentRevisionId'](),_0x1d50fc=this['repository']['getRevision'](_0x485229);if(_0x1d50fc)this['_startingVersion']=_0x1d50fc['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x599671=this['_source']['history']['_operations']['find'](_0xe5a3a2=>!_0xe5a3a2['_isInit']),_0x4d2071=_0x599671?_0x599671['baseVersion']:this['_source']['history']['version'];_0x33e1d9?(_0x33e1d9['toVersion']<_0x4d2071&&_0x33e1d9['_update']({'toVersion':_0x4d2071}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x4e3824['id'],this['_startingVersion']=_0x4e3824['fromVersion']):(this['_startingVersion']=_0x33e1d9['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x4d2071,this['_continueCurrentRevision']=!0x1);}}else _0x4e3824&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x4e3824['toVersion'],this['editor']['model']['document']['history']['version']),_0x4e3824['fromVersion']===_0x4e3824['toVersion']?(0x0!==_0x4e3824['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x4e3824['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x4e3824['id'],this['_startingVersion']=_0x4e3824['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',_0x180f23=>!_0x180f23),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x17c4e1=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0xbcb23e;for(const _0x152209 in _0x17c4e1){const _0x2574c3=_0x152209,_0x245520=_0x17c4e1[_0x2574c3];if('revisionHistoryLicenseKeyValid'==_0x245520||'revisionHistoryLicenseKeyInvalid'==_0x245520||'revisionHistoryLicenseKeyExpired'==_0x245520||'revisionHistoryLicenseKeyDomainLimit'==_0x245520||'revisionHistoryLicenseKeyNotAllowed'==_0x245520||'revisionHistoryLicenseKeyEvaluationLimit'==_0x245520||'revisionHistoryLicenseKeyUsageLimit'==_0x245520){delete _0x17c4e1[_0x2574c3],_0xbcb23e=_0x245520,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0xbcb23e&&_0x17c4e1['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0xbcb23e&&_0x17c4e1['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0xbcb23e&&_0x17c4e1['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0xbcb23e&&_0x17c4e1['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0xbcb23e&&_0x17c4e1['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0xbcb23e&&_0x17c4e1['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x22aa97=this['repository']['getRevision'](0x0),_0x233f40=await this['getRevisionDocumentData'](_0x22aa97),_0xe3dc28=await this['getRevisionRootsAttributes'](_0x22aa97),_0x5638c4=this['_utils']['getRevisionRootsModelElements'](_0x22aa97);this['_replaceEditorDataWithRevisionData'](_0x233f40,_0xe3dc28,_0x5638c4);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x378dce){this['_source']=_0x378dce;}async['update'](){const _0x26a658=await this['_source']['getLatestVersion']();if(_0x26a658>this['currentRevision']['toVersion']){await this['_loadState']();const _0x546a56=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x26a658});_0x546a56['authors']=_0x546a56['authorsIds']['map'](_0x3fd987=>this['editor']['plugins']['get']('Users')['getUser'](_0x3fd987)),this['currentRevision']['_update'](_0x546a56);}}async['saveRevision'](_0x39ae69={},_0x35d882=null){const _0x307b49=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x35d882>this['currentRevision']['toVersion']&&(_0x35d882=null),null===_0x35d882&&(_0x35d882=await this['_source']['getLatestVersion']());const _0x342242=this['_getFromVersion'](_0x35d882),_0x514f37=this['buildRevisionData']({'from':_0x342242,'to':_0x35d882});if(this['currentRevision']['toVersion']<_0x35d882){const _0x2c412c=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x35d882,'to':_0x35d882});_0x2c412c['authors']=[],_0x2c412c['authorsIds']=[],_0x2c412c['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x2c412c,!0x0),delete _0x2c412c['authors'],_0x307b49['push'](_0x2c412c);}_0x39ae69['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x39ae69['name']=_0x39ae69['name']||null,_0x39ae69['id']=_0x39ae69['id']||_0x439976(),_0x39ae69={..._0x39ae69,..._0x514f37};const _0x12b6db=this['addRevisionData'](_0x39ae69);_0x307b49['push'](_0x39ae69);const _0x40f440=this['repository']['getIndex'](_0x12b6db);if(0x0!==_0x40f440){const _0x14ff91=this['repository']['getRevision'](_0x40f440-0x1);if(_0x14ff91['fromVersion']!==_0x35d882){const _0x4f6187=this['_revisionDataBuilder']['getData'](_0x35d882,_0x14ff91['toVersion']),_0x5d958f={'id':_0x14ff91['id'],'diffData':_0x4f6187['diffData'],'authorsIds':_0x4f6187['authorsIds'],'authors':_0x4f6187['authorsIds']['map'](_0x5b5500=>this['editor']['plugins']['get']('Users')['getUser'](_0x5b5500)),'fromVersion':_0x35d882};_0x14ff91===this['currentRevision']&&(_0x5d958f['createdAt']=new Date(_0x39ae69['createdAt']['getTime']()+0xa)),_0x14ff91['_update'](_0x5d958f,!0x0),delete _0x5d958f['authors'],_0x307b49['push'](_0x5d958f);}}if(this['adapter']){for(const _0x2871df of _0x307b49)this['_bufferUpdate'](_0x2871df['id'],_0x2871df,!0x0);this['sendBufferedUpdates']();}return _0x12b6db;}['addRevisionData'](_0xc25c9c){const _0x3f219e=this['repository']['createRevision'](_0xc25c9c);return this['adapter']&&_0x3f219e['on']('_update',(_0x12e20c,_0x1954e7,_0x417e6c)=>{_0x417e6c||(this['_bufferUpdate'](_0x1954e7['id'],_0x1954e7,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x3f219e,this['_findInsertionIndex'](_0x3f219e)),_0x3f219e;}async['getRevisionDocumentData'](_0x24f335){return await this['_utils']['loadRevisionData'](_0x24f335,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x24f335);}async['getRevisionRootsAttributes'](_0x31d6e9){return await this['_utils']['loadRevisionData'](_0x31d6e9,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x31d6e9);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x19fd40=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x12454b=0x0;_0x12454b<_0x19fd40['length'];_0x12454b++){const _0x2cd985=_0x19fd40[_0x12454b];let _0x331f6b=!0x1;for(const _0x342790 of Object['keys'](_0x2cd985))void 0x0===_0x2cd985[_0x342790]?delete _0x2cd985[_0x342790]:'id'!==_0x342790&&(_0x331f6b=!0x0);_0x331f6b||(_0x19fd40[_0x12454b]=null);}if(_0x19fd40=_0x19fd40['filter'](_0x1d453f=>null!==_0x1d453f),!_0x19fd40['length'])return;for(let _0x31807a=0x0;_0x31807a<_0x19fd40['length'];_0x31807a++){const _0x426325=_0x19fd40[_0x31807a];void 0x0!==_0x426325['fromVersion']&&void 0x0===_0x426325['toVersion']&&(_0x426325['toVersion']=this['repository']['getRevision'](_0x426325['id'])['toVersion']),void 0x0!==_0x426325['toVersion']&&void 0x0===_0x426325['fromVersion']&&(_0x426325['fromVersion']=this['repository']['getRevision'](_0x426325['id'])['fromVersion']);}const _0x504752=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x19fd40,_0x504752)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x470f05=>{if(_0x470f05){for(const _0x541565 of _0x470f05)this['setRevisionData']({'id':_0x541565['id'],'createdAt':_0x541565['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0x22aaa5=null,from:_0x28aa81=null,to:_0x2d774d=null}){_0x28aa81=null!==_0x28aa81?_0x28aa81:_0x22aaa5['fromVersion'],_0x2d774d=null!==_0x2d774d?_0x2d774d:_0x22aaa5['toVersion'];const _0x315698=this['_revisionDataBuilder']['getData'](_0x28aa81,_0x2d774d),_0x588ee0={'diffData':_0x315698['diffData'],'authorsIds':_0x315698['authorsIds'],'fromVersion':_0x28aa81,'toVersion':_0x2d774d};if(!_0x22aaa5||_0x2d774d!==_0x22aaa5['toVersion']){const _0x59ad26=_0x2d774d-0x1,_0x508702=this['_source']['history']['getOperation'](_0x59ad26);_0x588ee0['createdAt']=_0x508702&&_0x508702['createdAt']||new Date();}if(this['_loadedStateData']&&_0x28aa81===this['_loadedStateData']['fromVersion']){for(const _0xc3d464 of this['_loadedStateData']['authors'])_0x588ee0['authorsIds']['includes'](_0xc3d464['id'])||_0x588ee0['authorsIds']['push'](_0xc3d464['id']);}return _0x588ee0;}['_bufferUpdate'](_0x355e5e,_0x83766c,_0x5a3d85){if(this['_bufferedUpdates']['has'](_0x355e5e)){const _0x365a00=this['_bufferedUpdates']['get'](_0x355e5e);_0x83766c=_0x5a3d85?{..._0x365a00,..._0x83766c}:{..._0x83766c,..._0x365a00};}this['_bufferedUpdates']['set'](_0x355e5e,_0x83766c);}['setRevisionData'](_0x4b005c){const _0x4543ac=this['repository']['getRevision'](_0x4b005c['id']);if(_0x4b005c['createdAt']&&(_0x4b005c['createdAt']=new Date(_0x4b005c['createdAt'])),_0x4b005c['authorsIds']){const _0x2d9f3e=this['editor']['plugins']['get']('Users');_0x4b005c['authors']=_0x4b005c['authorsIds']['map'](_0x326850=>_0x2d9f3e['getUser'](_0x326850));}_0x4543ac['_update'](_0x4b005c,!0x0);}['_createInitialRevision'](_0x4222cb){const _0x1898f6=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x1898f6)this['_initialRevisionId']=_0x1898f6['id'];else{const _0x58448d=!this['editor']['model']['document']['roots']['find'](_0x4ae754=>this['editor']['model']['hasContent'](_0x4ae754)),_0x100b40=this['editor']['plugins']['get']('Users')['me']['id'],_0x5be223=ft(this['editor']['locale'],_0x58448d?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x4222cb,'to':_0x4222cb,'id':this['_initialRevisionId'],'name':_0x5be223,'creatorId':_0x100b40});}}['_createCurrentRevision'](_0x3dbbb3){const _0x3466a2=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x3466a2),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x3dbbb3,'to':_0x3dbbb3,'id':_0x3466a2,'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'](_0x2ea634,_0x47a2df,_0x54265a){const _0x2e3ab0={},_0x4e333b={},_0x279479={},_0xa7157b=this['editor']['config']['get']('roots')||{};for(const [_0x15e21c,_0x4c32c2]of Object['entries'](_0xa7157b))_0x4c32c2['lazyLoad']||(_0x2e3ab0[_0x15e21c]=_0x4c32c2['initialData']??'',_0x4e333b[_0x15e21c]=_0x4c32c2['modelAttributes']||{},_0x4c32c2['modelElement']&&(_0x279479[_0x15e21c]=_0x4c32c2['modelElement']));for(const _0x272916 of this['editor']['model']['document']['getRootNames']())_0x2e3ab0[_0x272916]??='',_0x4e333b[_0x272916]??={};let _0x5e4cec=!0x1;const _0x526ab3=Object['keys'](_0x2e3ab0),_0x405496=Object['keys'](_0x2ea634);for(const _0x459d0e of _0x526ab3){if(_0x2e3ab0[_0x459d0e]!==_0x2ea634[_0x459d0e]&&''!==_0x2e3ab0[_0x459d0e]['trim']()){_0x5e4cec=!0x0;break;}if(!_0x1afd5b(_0x4e333b[_0x459d0e],_0x47a2df[_0x459d0e])&&Object['keys'](_0x4e333b[_0x459d0e])['length']>0x0){_0x5e4cec=!0x0;break;}const _0x452c5e=_0x279479[_0x459d0e],_0x2081d7=_0x54265a[_0x459d0e];if(_0x452c5e&&_0x2081d7&&_0x452c5e!==_0x2081d7){_0x5e4cec=!0x0;break;}}_0x5e4cec||(_0x5e4cec=_0x405496['some'](_0x4bc794=>!this['editor']['model']['document']['getRoot'](_0x4bc794))),_0x5e4cec&&_0x17d11b('editor-initial-data-replaced-with-revision-data',{'editorData':_0x2e3ab0,'editorRootsAttributes':_0x4e333b,'editorRootsModelElements':_0x279479,'revisionData':_0x2ea634,'revisionRootsAttributes':_0x47a2df,'revisionRootsModelElements':_0x54265a});for(const [_0x54dc6c,_0x5da83f]of Object['entries'](_0x2ea634))this['editor']['config']['set']('roots.'+_0x54dc6c+'.initialData',_0x5da83f);for(const [_0x57f5e7,_0x54bb4d]of Object['entries'](_0x47a2df))this['editor']['config']['set']('roots.'+_0x57f5e7+'.modelAttributes',_0x54bb4d);const _0x1c109d=this['editor']['model']['document'];for(const [_0x3372d7,_0x33d187]of Object['entries'](_0x54265a)){this['editor']['config']['set']('roots.'+_0x3372d7+'.modelElement',_0x33d187);const _0x3d4af6=_0x1c109d['getRoot'](_0x3372d7);_0x3d4af6&&_0x3d4af6['name']!==_0x33d187&&(_0x1c109d['roots']['remove'](_0x3372d7),_0x1c109d['createRoot'](_0x33d187,_0x3372d7));}}['_addPendingAction'](){if(!this['_pendingAction']){const _0x3f8b1d=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x3f8b1d['add'](ft(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x186814){const _0x473266=this['repository']['getRevisions']();_0x473266['reverse']();let _0x282ae1=0x0;for(;_0x282ae1<_0x473266['length'];){const _0x5d15ee=_0x473266[_0x282ae1];if(_0x5d15ee===this['currentRevision']){_0x282ae1++;continue;}if(_0x5d15ee['id']===this['_initialRevisionId'])break;const _0x221665=_0x186814['toVersion']-_0x5d15ee['toVersion']||_0x186814['fromVersion']-_0x5d15ee['fromVersion'];if(_0x221665>0x0)break;if(_0x221665<0x0)_0x282ae1++;else{if(!_0x186814['creator']&&_0x5d15ee['creator'])break;if(_0x5d15ee['creator']||!_0x186814['creator']){if(_0x186814['createdAt']>_0x5d15ee['createdAt'])break;_0x282ae1++;}else _0x282ae1++;}}return _0x282ae1;}['_getFromVersion'](_0x11c054){const _0x1365c2=this['repository']['getRevisions']();_0x1365c2['reverse'](),_0x1365c2['shift']();const _0x51f519=_0x1365c2['find'](_0x9d1182=>_0x9d1182['toVersion']<=_0x11c054)['toVersion'];return _0x51f519<this['_startingVersion']?this['_startingVersion']:_0x51f519;}['_makeRevision']({name:_0x5d411a,from:_0xdc99e1,to:_0x370f75,creatorId:_0x49b62a,id:_0x43a85c}){const _0x3cef68=this['buildRevisionData']({'from':_0xdc99e1,'to':_0x370f75});_0x3cef68['name']=_0x5d411a,_0x3cef68['creatorId']=_0x49b62a,_0x3cef68['id']=_0x43a85c;const _0x16cc2e=this['addRevisionData'](_0x3cef68);return this['adapter']&&this['_bufferUpdate'](_0x3cef68['id'],_0x3cef68,!0x0),_0x16cc2e;}['_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(_0x573ad1){this['editor']=_0x573ad1,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'](_0x4302cd){this['source']=_0x4302cd;const _0x4210fa=new Map(),_0x3b18f5=new Map(),_0x50c3f7=this['editor']['model']['document']['roots']['map'](_0x41c842=>_0x41c842['rootName']);for(const _0x70dc41 of _0x50c3f7){const _0x52e810=this['editor']['model']['document']['getRoot'](_0x70dc41),_0x58e998=gt(_0x52e810);_0x4210fa['set'](_0x70dc41,_0x58e998),_0x3b18f5['set'](_0x70dc41,Object['fromEntries'](_0x52e810['getAttributes']()));}const _0xa939c1=Array['from'](this['editor']['model']['markers'])['map'](_0x3ba1ca=>[_0x3ba1ca['name'],_0x3ba1ca['getRange']()]),_0x47b4e3=this['source']['version'];this['_saveMetaData'](_0x47b4e3,_0x4210fa,_0xa939c1,_0x3b18f5),this['_startingRevisionId']=this['_revisionId'];const _0xb1704a=new Map(),_0x5e38d1=new Map();for(const _0x2b934d of _0x50c3f7){const _0x36c470=wt(_0x2b934d,this['editor']['model']['document']['getRoot'](_0x2b934d)['name']);_0xb1704a['set'](_0x2b934d,_0x36c470),_0x5e38d1['set'](_0x2b934d,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0xb1704a,[],_0x5e38d1);}['getData'](_0x4ce374,_0x429aab){if(this['_lastFrom']===_0x4ce374&&this['_lastTo']<=_0x429aab)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x429aab,!0x0);else{if(!this['_savedMetaData']['has'](_0x4ce374)){const _0x15e5aa=this['_getPreviousFrom'](_0x4ce374);this['_calculateMetaData'](_0x15e5aa,_0x4ce374,!0x1);}this['_calculateMetaData'](_0x4ce374,_0x429aab,!0x0);}return this['_lastFrom']=_0x4ce374,this['_lastTo']=_0x429aab,this['_getState']();}['loadState'](_0x39b7e7){if(!this['_savedMetaData']['has'](_0x39b7e7['fromVersion'])){const _0x14c1df=this['_getPreviousFrom'](_0x39b7e7['fromVersion']);this['_calculateMetaData'](_0x14c1df,_0x39b7e7['fromVersion'],!0x1);}this['_calculateMetaData'](_0x39b7e7['fromVersion'],_0x39b7e7['toVersion'],!0x1);const _0x2b306f=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x39b7e7['fromVersion'],this['_lastTo']=_0x39b7e7['toVersion'];for(const _0x116778 in _0x39b7e7['diffData']){const _0x476e91=_0x39b7e7['diffData'][_0x116778]['attachChange'],_0x392e9a=_0xea4767(_0x39b7e7['diffData'][_0x116778]['attributesBefore'])||{},_0x4ac6a6=_0x39b7e7['diffData'][_0x116778],_0x3d3496=_0x2b306f['_makeModelFromViewString'](_0x4ac6a6['deletions'],_0x4ac6a6['rootElementName']||'$root');_0x3d3496['rootName']=_0x116778,_0x3d3496['_isAttached']=!_0x476e91||!_0x476e91['isAttached'],_0x3d3496['isAttached']=()=>_0x3d3496['_isAttached'],this['_baseRoots']['set'](_0x116778,_0x3d3496),this['_baseRootsAttributes']['set'](_0x116778,_0x392e9a),_0x476e91&&this['_touchedRoots']['set'](_0x116778,_0x476e91);const _0x35c68d=this['_makeIdsRoot'](_0x3d3496);this['_baseIdsRoots']['set'](_0x116778,_0x35c68d);for(const [_0x4606d8,_0x50b639]of _0x3d3496['markers']){if(!_0x4606d8['startsWith']('revision:'))continue;const _0x353647=_0x4606d8['split'](':')[0x2];for(const _0x39d492 of _0x50b639['getWalker']({'singleCharacters':!0x0})){const _0x3392aa=this['_getVidAttributeName'](_0x39d492),_0x3697cb='elementEnd'==_0x39d492['type']?_0x39d492['previousPosition']['path']['slice'](0x0,-0x1):_0x39d492['previousPosition']['path'],_0x18cc57=_0x35c68d['getNodeByPath'](_0x3697cb)['getAttribute'](_0x3392aa);this['_touched']['set'](_0x18cc57,{'userId':_0x353647});}_0x3d3496['markers']['delete'](_0x4606d8);}}this['_startingRevisionId']=this['_revisionId'];const _0x442dbb=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x57cdbe=>!this['_touched']['has'](_0x57cdbe));let _0x508236=0x0;const _0x21e4ad=new Map();for(const _0x59b091 in _0x39b7e7['diffData']){const _0x4bbd42=_0x39b7e7['diffData'][_0x59b091]['attachChange'],_0x2b4b3e=_0xea4767(_0x39b7e7['diffData'][_0x59b091]['attributesAfter'])||{},_0x5d567c=_0x39b7e7['diffData'][_0x59b091],_0x259f3b=_0x2b306f['_makeModelFromViewString'](_0x5d567c['insertions'],_0x5d567c['rootElementName']||'$root');_0x259f3b['rootName']=_0x59b091,_0x259f3b['_isAttached']=!_0x4bbd42||_0x4bbd42['isAttached'],_0x259f3b['isAttached']=()=>_0x259f3b['_isAttached'],this['_diffRoots']['set'](_0x59b091,_0x259f3b),this['_diffRootsAttributes']['set'](_0x59b091,_0x2b4b3e);const _0x201e48=this['_makeIdsRoot'](_0x259f3b,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x59b091,_0x201e48),_0x21e4ad['set'](_0x59b091,_0x259f3b['isAttached']()?_0x2b4b3e:{});for(const [_0x284669,_0x1a5869]of _0x259f3b['markers']){if(!_0x284669['startsWith']('revision:'))continue;const _0x5e1826=_0x284669['split'](':')[0x2];for(const _0x244508 of _0x1a5869['getWalker']({'singleCharacters':!0x0})){const _0x1c33a1=this['_getVidAttributeName'](_0x244508),_0x1c3271=this['_revisionId']++,_0x139787='elementEnd'==_0x244508['type']?_0x244508['previousPosition']['path']['slice'](0x0,-0x1):_0x244508['previousPosition']['path'];_0x201e48['getNodeByPath'](_0x139787)['_setAttribute'](_0x1c33a1,_0x1c3271),this['_touched']['set'](_0x1c3271,{'userId':_0x5e1826});}_0x259f3b['markers']['delete'](_0x284669);}for(const _0x549731 of this['editor']['model']['createRangeIn'](_0x259f3b)['getWalker']({'singleCharacters':!0x0})){const _0x281051=this['_getVidAttributeName'](_0x549731),_0x55302a='elementEnd'==_0x549731['type']?_0x549731['previousPosition']['path']['slice'](0x0,-0x1):_0x549731['previousPosition']['path'],_0x569d1c=_0x201e48['getNodeByPath'](_0x55302a);_0x569d1c['getAttribute'](_0x281051)>0x0||_0x569d1c['_setAttribute'](_0x281051,_0x442dbb[_0x508236++]);}for(const [_0xfc5789,_0x57085d]of _0x259f3b['markers'])_0xfc5789['startsWith']('revision:')||this['_markers']['set'](_0xfc5789,_0x57085d);}const {roots:_0x44f246}=this['_savedMetaData']['get'](_0x39b7e7['fromVersion']),{roots:_0x264d6d}=this['_savedMetaData']['get'](_0x39b7e7['toVersion']),_0x4640d2=gt(_0x44f246['get']('$graveyard'));this['_baseRoots']['set']('$graveyard',_0x4640d2),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x4640d2,Number['NEGATIVE_INFINITY']));const _0x2a2e0e=gt(_0x264d6d['get']('$graveyard'));this['_diffRoots']['set']('$graveyard',_0x2a2e0e),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x2a2e0e));const _0x2b3253=Array['from'](this['_diffRoots'])['map'](([_0x5d1338,_0x5a442c])=>[_0x5d1338,gt(_0x5a442c)]);this['_saveMetaData'](this['_lastTo'],_0x2b3253,this['_markers'],_0x21e4ad);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0x17f63b,_0x2c2a1e,_0x2e45b1,_0x59ff43){const _0x3da681=new Map(_0x2c2a1e),_0x55abad=new Map(_0xea4767(_0x59ff43)),_0x3b62c3=new Map();for(const [_0x23cef4,_0x339e5e]of _0x2e45b1)_0x3b62c3['set'](_0x23cef4,{'start':_0x339e5e['start']['clone'](),'end':_0x339e5e['end']['clone'](),'rootName':_0x339e5e['root']['rootName']});this['_savedMetaData']['set'](_0x17f63b,{'roots':_0x3da681,'markers':_0x3b62c3,'rootsAttributes':_0x55abad});}['_removeMetaData'](_0x3f4b84){this['_savedMetaData']['delete'](_0x3f4b84);}['_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'](_0x1717bf,_0x2e453c=null){let _0x4d3283=null;_0x1717bf['is']('documentFragment')||(_0x4d3283=new _0x1a0f77(_0x1717bf['name'],{'vid_start':null===_0x2e453c?this['_revisionId']++:_0x2e453c++}));const _0x3d7c0a=[];for(const _0x157747 of _0x1717bf['getChildren']())if(_0x157747['is']('element')){_0x3d7c0a['push'](this['_makeIdsRoot'](_0x157747,_0x2e453c));const _0x346ff0=_0x3d7c0a[_0x3d7c0a['length']-0x1];null!==_0x2e453c&&(_0x2e453c=_0x346ff0['is']('element','$text')?_0x346ff0['getAttribute']('vid')+0x1:_0x346ff0['getAttribute']('vid_end')+0x1);}else{for(let _0x453a53=0x0;_0x453a53<_0x157747['offsetSize'];_0x453a53++)_0x3d7c0a['push'](new _0x1a0f77('$text',{'vid':null===_0x2e453c?this['_revisionId']++:_0x2e453c++}));}if(_0x1717bf['is']('documentFragment')){const _0x37e8c4=wt(_0x1717bf['rootName'],_0x1717bf['name']);return _0x37e8c4['_insertChild'](0x0,_0x3d7c0a),_0x37e8c4;}return _0x4d3283['_setAttribute']('vid_end',null===_0x2e453c?this['_revisionId']++:_0x2e453c++),_0x4d3283['_insertChild'](0x0,_0x3d7c0a),_0x4d3283;}['_calculateMetaData'](_0xb5ad05,_0x5692a0,_0x3c565a){this['_reset']();const {roots:_0x429e49,markers:_0x152d01,rootsAttributes:_0x25e0d4}=this['_savedMetaData']['get'](_0xb5ad05);this['_baseRoots']=new Map(_0x429e49),this['_baseRootsAttributes']=new Map(_0xea4767(_0x25e0d4));for(const [_0x2a7190,_0x590e4c]of this['_baseRoots'])if('$graveyard'!==_0x2a7190&&(this['_diffRoots']['set'](_0x2a7190,gt(_0x590e4c)),this['_diffRootsAttributes']=new Map(_0xea4767(_0x25e0d4)),_0x3c565a)){const _0x2541f1=this['_revisionId'];this['_idsRoots']['set'](_0x2a7190,this['_makeIdsRoot'](_0x590e4c)),this['_baseIdsRoots']['set'](_0x2a7190,this['_makeIdsRoot'](_0x590e4c,_0x2541f1));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',gt(this['_baseRoots']['get']('$graveyard'))),_0x3c565a&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x26fa8b,_0x3d152c]of _0x152d01){const _0x14f0cc=this['_baseRoots']['get'](_0x3d152c['rootName']),_0xcf4e38=this['_diffRoots']['get'](_0x3d152c['rootName']),_0x18a626=new _0x414021(this['_fixPosition'](_0x3d152c['start'],_0x14f0cc),this['_fixPosition'](_0x3d152c['end'],_0x14f0cc)),_0xe6431a=this['_fixRange'](_0x18a626,_0xcf4e38);_0x14f0cc['markers']['set'](_0x26fa8b,_0x18a626),this['_markers']['set'](_0x26fa8b,_0xe6431a);}this['_applyOperations'](_0xb5ad05,_0x5692a0,_0x3c565a);}['_applyOperations'](_0x5b6abd,_0x22037c,_0x474a13){for(const _0x5ef814 of this['source']['getOperations'](_0x5b6abd,_0x22037c))this['_handleOperation'](_0x5ef814,_0x474a13);for(const _0x166a73 of this['_diffRoots']['values']())_0x166a73['markers']['clear']();for(const [_0x176119,_0x456743]of this['_markers']){this['_diffRoots']['get'](_0x456743['root']['rootName'])['markers']['set'](_0x176119,_0x456743['clone']());}const _0x467501=new Map(),_0x3abc09=new Map();for(const [_0x4ad969,_0x241512]of this['_diffRoots'])_0x467501['set'](_0x4ad969,gt(_0x241512)),_0x3abc09['set'](_0x4ad969,this['_diffRootsAttributes']['get'](_0x4ad969));this['_saveMetaData'](_0x22037c,_0x467501,this['_markers'],_0x3abc09);}['_getPreviousFrom'](_0x5aa7ea){const _0x4cc926=Array['from'](this['_savedMetaData']['keys']());_0x4cc926['sort']((_0x46b668,_0x551649)=>_0x46b668-_0x551649),_0x4cc926['reverse']();for(const _0xf29270 of _0x4cc926)if(_0xf29270<_0x5aa7ea)return _0xf29270;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0xd004e3,_0x372dbc){const _0xf64fb1=Array['from'](_0x372dbc['markers'])['map'](([_0x578073,_0x5f3825])=>[_0x578073,this['_fixRange'](_0x5f3825,_0xd004e3)]);_0xd004e3['markers']=new Map(_0xf64fb1);}['_transformMarkers'](_0x26e316){for(const _0x7a3f30 of this['_markers']['values']()){const _0x58eda4=_0x7a3f30['getTransformedByOperation'](_0x26e316),_0x168bd0=_0x414021['_createFromRanges'](_0x58eda4);_0x7a3f30['start']=_0x168bd0['start'],_0x7a3f30['end']=_0x168bd0['end'];}}['_handleOperation'](_0xf39206,_0x54babc){if('addRoot'!=_0xf39206['type']&&'detachRoot'!=_0xf39206['type']){if('insert'==_0xf39206['type']){const _0x93c46e=_0xf39206['position']['root'],_0x1bd04e=_0x93c46e['rootName'],_0x3353ba=_0x93c46e['name'];this['_diffRoots']['has'](_0x1bd04e)||(this['_diffRoots']['set'](_0x1bd04e,wt(_0x1bd04e,_0x3353ba,!0x0)),this['_diffRootsAttributes']['set'](_0x1bd04e,{}),_0x54babc&&this['_idsRoots']['set'](_0x1bd04e,wt(_0x1bd04e,_0x3353ba,!0x0)));}else{if('addRootAttribute'==_0xf39206['type']||'removeRootAttribute'==_0xf39206['type']||'changeRootAttribute'==_0xf39206['type'])return void this['_handleRootAttributeOperation'](_0xf39206);'marker'==_0xf39206['type']&&this['_handleMarkerOperation'](_0xf39206);}if('marker'!==_0xf39206['type']){const _0x493bcc=this['_cloneOperation'](_0xf39206,this['_diffRoots']);_0x493bcc['_execute'](),this['_transformMarkers'](_0x493bcc);}if(_0x54babc)switch(_0xf39206['type']){case'insert':this['_handleInsertOperation'](_0xf39206);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0xf39206);break;case'merge':this['_handleMergeOperation'](_0xf39206);break;case'split':this['_handleSplitOperation'](_0xf39206);}}else this['_handleRootOperation'](_0xf39206,_0x54babc);}['_cloneOperation'](_0x2ab934,_0x4062bc){const _0x1fd460=_0x2ab934['clone']();return _0x1fd460['_authorId']=_0x2ab934['_authorId'],this['_fixOperation'](_0x1fd460,_0x4062bc),_0x1fd460;}['_getBaseVids'](_0x1864d8){return _0x1864d8['map'](_0x5ae086=>{const _0x1d6cae=this['_getVidAttributeName'](_0x5ae086);return Number(_0x5ae086['item']['getAttribute'](_0x1d6cae));});}['_generateTape'](_0x36903e,_0x52bfd7){if(_0x36903e['is']('element','$text'))_0x52bfd7['push']({'item':_0x36903e,'type':'text'});else{_0x36903e['is']('element')&&_0x52bfd7['push']({'item':_0x36903e,'type':'elementStart'});for(const _0xdb9cf0 of _0x36903e['getChildren']())this['_generateTape'](_0xdb9cf0,_0x52bfd7);_0x36903e['is']('element')&&_0x52bfd7['push']({'item':_0x36903e,'type':'elementEnd'});}return _0x52bfd7;}['_getState'](){const _0x49a05e=new Map(this['_touched']),_0xaf9596=new Map(_0x49a05e),_0x3d6472=new Map(),_0x5d7c04={'insertions':{},'deletions':{}},_0x344ee5={'insertions':{},'deletions':{}},_0x3c5ce0=new Map(),_0x3f845f=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]),_0x3c3dba=new Map();_0x3f845f['delete']('$graveyard');for(const _0x1aa353 of _0x3f845f){const _0x390662=(this['_diffRoots']['get'](_0x1aa353)??this['_baseRoots']['get'](_0x1aa353))['name'],_0x163c35=this['_diffRoots']['get'](_0x1aa353)||wt(_0x1aa353,_0x390662,!0x1),_0x27b526=this['_baseRoots']['get'](_0x1aa353)||wt(_0x1aa353,_0x390662,!0x1);_0x163c35['isAttached']()||_0x27b526['isAttached']()?(_0x3c3dba['set'](_0x1aa353,_0x390662),_0x5d7c04['insertions'][_0x1aa353]=gt(_0x163c35),_0x5d7c04['deletions'][_0x1aa353]=gt(_0x27b526),this['_copyMarkers'](_0x5d7c04['deletions'][_0x1aa353],_0x27b526),this['_copyMarkers'](_0x5d7c04['insertions'][_0x1aa353],_0x163c35),_0x344ee5['insertions'][_0x1aa353]=this['_generateTape'](this['_idsRoots']['get'](_0x1aa353),[]),_0x344ee5['deletions'][_0x1aa353]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x1aa353)||wt(_0x1aa353,_0x390662,!0x1),[])):_0x3f845f['delete'](_0x1aa353);}for(const _0x59d000 of _0x3f845f){const _0x43a895=_0x344ee5['insertions'][_0x59d000];for(const _0x2bf9b1 of _0x43a895){const _0x56561d=this['_getVidAttributeName'](_0x2bf9b1),_0x3aeda9=_0x2bf9b1['item']['getAttribute'](_0x56561d);_0xaf9596['delete'](_0x3aeda9),_0x3aeda9>=this['_startingRevisionId']&&_0x3d6472['set'](_0x3aeda9,_0x49a05e['get'](_0x3aeda9));}}for(const _0x55afb8 of _0x3f845f){const _0x3e5768=_0x344ee5['insertions'][_0x55afb8],_0x4fb406=this['_getBaseVids'](_0x344ee5['deletions'][_0x55afb8]);let _0x187796=0x0;for(const _0x5767ea of _0x3e5768){const _0x531087=this['_getVidAttributeName'](_0x5767ea),_0x3de5e0=_0x5767ea['item']['getAttribute'](_0x531087);if(!_0x3d6472['has'](_0x3de5e0)&&!_0x3c5ce0['has'](_0x3de5e0)){if(_0xaf9596['has'](_0x3de5e0))_0x187796++;else{if(_0x3de5e0!=_0x4fb406[_0x187796]){const _0x429697=_0x49a05e['get'](_0x3de5e0)||_0x49a05e['get'](_0x4fb406[_0x187796]);for(;_0x3de5e0!=_0x4fb406[_0x187796];)_0xaf9596['has'](_0x4fb406[_0x187796])||(_0x3c5ce0['set'](_0x4fb406[_0x187796],_0x429697),_0x49a05e['set'](_0x4fb406[_0x187796],_0x429697)),_0x187796++;}_0x187796++;}}}}for(const _0x30ee68 of _0x3f845f){const _0x2153ad=_0x344ee5['insertions'][_0x30ee68];for(const _0x26375e of _0x2153ad){const _0x5ddea0=this['_getVidAttributeName'](_0x26375e),_0xd733ca=_0x26375e['item']['getAttribute'](_0x5ddea0);if(_0x3c5ce0['has'](_0xd733ca)){const _0x207599=_0x3c5ce0['get'](_0xd733ca);_0xaf9596['has'](_0xd733ca)||_0xaf9596['set'](_0xd733ca,{..._0x207599}),_0x3d6472['set'](_0xd733ca,{..._0x207599});}}}for(const _0x4de775 of _0xaf9596['keys']())_0x4de775>=this['_startingRevisionId']&&_0xaf9596['delete'](_0x4de775);const _0x1e9174=new Map();for(const _0x38ebd5 of _0x3f845f){let _0x5ecf2d=_0x344ee5['insertions'][_0x38ebd5];for(const _0xf9d58e of _0x5ecf2d)if(_0xf9d58e['item']['is']('element','tableCell')){const _0x53619b=this['_getVidAttributeName'](_0xf9d58e),_0x30c529=_0xf9d58e['item']['getAttribute'](_0x53619b);if(_0x3d6472['has'](_0x30c529)){const _0x19d410=_0xf9d58e['item']['parent']['parent']['getAttribute']('vid_start'),_0x5c3fa4=_0x1e9174['get'](_0x19d410)||new Set();_0x5c3fa4['add'](_0x3d6472['get'](_0x30c529)['userId']),_0x1e9174['set'](_0x19d410,_0x5c3fa4);}}_0x5ecf2d=_0x344ee5['deletions'][_0x38ebd5];for(const _0x17bb97 of _0x5ecf2d)if(_0x17bb97['item']['is']('element','tableCell')){const _0x367817=this['_getVidAttributeName'](_0x17bb97),_0x1bb601=_0x17bb97['item']['getAttribute'](_0x367817);if(_0xaf9596['has'](_0x1bb601)){const _0x204d44=_0x17bb97['item']['parent']['parent']['getAttribute']('vid_start'),_0x4ffc08=_0x1e9174['get'](_0x204d44)||new Set();_0x4ffc08['add'](_0xaf9596['get'](_0x1bb601)['userId']),_0x1e9174['set'](_0x204d44,_0x4ffc08);}}for(const _0x2c9d96 of _0x1e9174['keys']())(_0x3d6472['has'](_0x2c9d96)||_0xaf9596['has'](_0x2c9d96))&&_0x1e9174['delete'](_0x2c9d96);}for(const _0xb94ef3 of _0x3f845f){const _0x1f4b15=_0x344ee5['insertions'][_0xb94ef3];let _0x2cd85c=null,_0x2f9813=null;for(const _0x24dbaf of _0x1f4b15){const _0x4569f9=this['_getVidAttributeName'](_0x24dbaf),_0x52c720=_0x24dbaf['item']['getAttribute'](_0x4569f9),_0x84eeee=_0x1e9174['get'](_0x52c720);_0x84eeee&&'elementStart'==_0x24dbaf['type']&&(_0x2cd85c=Array['from'](_0x84eeee)[0x0],_0x2f9813=_0x24dbaf['item']['getAttribute']('vid_end')),_0x2cd85c&&(_0xaf9596['set'](_0x52c720,{'userId':_0x2cd85c}),_0x3d6472['set'](_0x52c720,{'userId':_0x2cd85c})),_0x52c720==_0x2f9813&&(_0x2cd85c=null,_0x2f9813=null);}}const _0x318099={},_0x18ea35=new Set();for(const _0x558e18 of _0x3f845f){const _0x1651ca=_0x5d7c04['deletions'][_0x558e18],_0x5930f9=_0x5d7c04['insertions'][_0x558e18];for(const {userId:_0x2695ea}of this['_touchedMarkers']['values']())null!==_0x2695ea&&_0x18ea35['add'](_0x2695ea);for(const {userId:_0x52b1ba}of this['_touchedRoots']['values']())null!==_0x52b1ba&&_0x18ea35['add'](_0x52b1ba);this['_markChanges'](_0x5930f9,_0x344ee5['insertions'][_0x558e18],_0x3d6472,'insertion',_0x18ea35),this['_markChanges'](_0x1651ca,_0x344ee5['deletions'][_0x558e18],_0xaf9596,'deletion',_0x18ea35),_0x318099[_0x558e18]={'insertions':this['_prepareViewToSave'](_0x5930f9),'deletions':this['_prepareViewToSave'](_0x1651ca),'attachChange':this['_touchedRoots']['get'](_0x558e18)||null,'attributesBefore':_0xea4767(this['_baseRootsAttributes']['get'](_0x558e18))||{},'attributesAfter':_0xea4767(this['_diffRootsAttributes']['get'](_0x558e18)),'rootElementName':_0x3c3dba['get'](_0x558e18)};}return{'diffData':_0x318099,'authorsIds':Array['from'](_0x18ea35)};}['_processRootBeforeSave'](_0x47a45a){for(const [,_0x4f05cb]of _0x47a45a['markers']){const _0x26c417=_0x4f05cb['start']['getAncestors']()['filter'](_0x3c7401=>'tableCell'==_0x3c7401['name']);for(const _0xea631 of _0x26c417)0x1==_0xea631['childCount']&&_0xea631['getChild'](0x0)['is']('element','paragraph')&&_0xea631['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x2bc193){this['_processRootBeforeSave'](_0x2bc193);const _0x35903b=this['editor']['data']['toView'](_0x2bc193,{}),_0x3c8032=Array['from'](_0x35903b['getChildren']())['map'](_0x30780f=>this['_getViewJson'](_0x30780f));return JSON['stringify'](_0x3c8032);}['_getViewJson'](_0x333c81){if(_0x333c81['is']('$text'))return _0x333c81['data'];{const _0x164776=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0x95e634=_0x333c81,_0x3f6192=this['editor']['data']['htmlProcessor']['domConverter'],_0x2b299a={'type':_0x164776['_getTypeCharForViewElement'](_0x95e634),'name':_0x95e634['name'],'attributes':Array['from'](_0x95e634['getAttributes']()),'children':Array['from'](_0x95e634['getChildren']())['map'](_0x2cdaca=>this['_getViewJson'](_0x2cdaca))};if(_0x333c81['is']('uiElement')&&'$comment'!=_0x333c81['name']){const _0x5312f2=_0x333c81['render'](_0x3f6192['domDocument'],_0x3f6192);_0x2b299a['children']['push'](_0x5312f2['outerHTML']);}else{if(_0x333c81['is']('rawElement')){const _0x5899ff=_0x3f6192['domDocument']['createElement'](_0x95e634['name']);_0x333c81['render'](_0x5899ff,_0x3f6192),_0x2b299a['children']['push'](_0x5899ff['innerHTML']);}}const _0x4f5ce1=Array['from'](_0x95e634['getCustomProperties']());_0x4f5ce1['length']>0x0&&(_0x2b299a['customProperties']=_0x4f5ce1);const _0x1518a3=_0x95e634['getFillerOffset']();return null!==_0x1518a3&&(_0x2b299a['fillerOffset']=_0x1518a3),_0x2b299a;}}['_markChanges'](_0x114de9,_0xe95cc5,_0x16964f,_0x2c8b52,_0x53a335){let _0x197b96=null,_0x4eddd6=null,_0x2bb6e9=0x0;const _0x4fa6c6=this['editor']['model'];for(let _0x223d5e=0x0;_0x223d5e<_0xe95cc5['length'];_0x223d5e++){const _0x58b74b=this['_getVidAttributeName'](_0xe95cc5[_0x223d5e]),_0x187c4a=_0xe95cc5[_0x223d5e]['item']['getAttribute'](_0x58b74b),_0x12b2e9=_0x16964f['get'](_0x187c4a),_0x474f01=_0x223d5e==_0xe95cc5['length']-0x1;(!_0x197b96&&_0x12b2e9&&(_0x197b96=_0x12b2e9,_0x4eddd6=_0xe95cc5[_0x223d5e]),_0x197b96&&(!_0x12b2e9||_0x12b2e9['userId']!=_0x197b96['userId']))&&(_0x4c5678(_0x12b2e9,mt(_0x4eddd6,_0x114de9,_0x4fa6c6),mt(_0xe95cc5[_0x223d5e],_0x114de9,_0x4fa6c6)),_0x197b96=_0x12b2e9||null,_0x4eddd6=_0x12b2e9?_0xe95cc5[_0x223d5e]:null),_0x197b96&&_0x474f01&&_0x4c5678(_0x12b2e9,mt(_0x4eddd6,_0x114de9,_0x4fa6c6),pt(_0xe95cc5[_0x223d5e],_0x114de9,_0x4fa6c6));}function _0x4c5678(_0x184712,_0x594349,_0x503cfb){const _0x103255=_0x197b96['userId'],_0x1e7a0e='revision:'+_0x2c8b52+':'+_0x103255+':'+_0x2bb6e9++,_0x93548f=_0x4fa6c6['createRange'](_0x594349,_0x503cfb);_0x114de9['markers']['set'](_0x1e7a0e,_0x93548f),null!==_0x103255&&_0x53a335['add'](_0x103255);}}['_getVidAttributeName'](_0x4ddd6e){switch(_0x4ddd6e['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x1ad9fd,_0x56f0a7){_0x1ad9fd['baseVersion']=null;for(const _0xc6c8df in _0x1ad9fd){const _0x58d05e=_0x1ad9fd[_0xc6c8df];if(_0x58d05e instanceof _0x461e8e){const _0x541848=_0x56f0a7['get'](_0x58d05e['root']['rootName']);_0x1ad9fd[_0xc6c8df]=this['_fixPosition'](_0x58d05e,_0x541848);}if(_0x58d05e instanceof _0x414021){const _0x17813d=_0x56f0a7['get'](_0x58d05e['root']['rootName']);_0x1ad9fd[_0xc6c8df]=this['_fixRange'](_0x58d05e,_0x17813d);}'root'===_0xc6c8df&&(_0x1ad9fd['root']=_0x56f0a7['get'](_0x1ad9fd['root']['rootName']));}}['_fixRange'](_0x1f28ab,_0x3ca4d9){return this['editor']['model']['createRange'](this['_fixPosition'](_0x1f28ab['start'],_0x3ca4d9),this['_fixPosition'](_0x1f28ab['end'],_0x3ca4d9));}['_fixPosition'](_0x1701f2,_0x5c5395){return this['editor']['model']['createPositionFromPath'](_0x5c5395,_0x1701f2['path'],_0x1701f2['stickiness']);}['_handleInsertOperation'](_0x24eeac){const _0x2ceb4b=this['_idsRoots']['get'](_0x24eeac['position']['root']['rootName']),_0x2910e9=this['_fixPosition'](_0x24eeac['position'],_0x2ceb4b),_0x40c43a=null===_0x24eeac['_authorId']?null:_0x24eeac['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x53af5f=_0x2910e9['parent'],_0x10390e=this['_revisionId'],_0x101ff9=[];for(const _0x16c2b7 of _0x24eeac['nodes'])if(_0x16c2b7['is']('element'))_0x101ff9['push'](this['_makeIdsRoot'](_0x16c2b7));else{for(let _0x3b133b=0x0;_0x3b133b<_0x16c2b7['offsetSize'];_0x3b133b++)_0x101ff9['push'](new _0x1a0f77('$text',{'vid':this['_revisionId']++}));}const _0xe231bf=this['_revisionId'];for(let _0x5932ca=_0x10390e;_0x5932ca<_0xe231bf;_0x5932ca++)this['_touched']['set'](_0x5932ca,{'userId':_0x40c43a});_0x53af5f['_insertChild'](_0x2910e9['offset'],_0x101ff9);}['_handleMoveOperation'](_0x5051b9){(_0x5051b9=this['_cloneOperation'](_0x5051b9,this['_idsRoots']))['_execute']();const _0x46d278=null===_0x5051b9['_authorId']?null:_0x5051b9['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x29e5a7=_0x5051b9['getMovedRangeStart'](),_0x2b70b5=_0x29e5a7['parent'],_0x212e6e=_0x29e5a7['offset'];!function _0x394a5c(_0x290c99,_0xd5220e,_0x4714ef,_0x209ab3){for(let _0x42ccb3=_0x4714ef;_0x42ccb3<_0x209ab3;_0x42ccb3++){const _0x533161=_0xd5220e['getChild'](_0x42ccb3);_0x533161['is']('element','$text')?_0x290c99['set'](_0x533161['getAttribute']('vid'),{'userId':_0x46d278}):(_0x290c99['set'](_0x533161['getAttribute']('vid_start'),{'userId':_0x46d278}),_0x394a5c(_0x290c99,_0x533161,0x0,_0x533161['childCount']),_0x290c99['set'](_0x533161['getAttribute']('vid_end'),{'userId':_0x46d278}));}}(this['_touched'],_0x2b70b5,_0x212e6e,_0x212e6e+_0x5051b9['howMany']);}['_handleMergeOperation'](_0x15ce9d){const _0x2254fa=null===(_0x15ce9d=this['_cloneOperation'](_0x15ce9d,this['_idsRoots']))['_authorId']?null:_0x15ce9d['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0xa9f0ca=_0x15ce9d['targetPosition']['parent'],_0x16b58c=_0x15ce9d['sourcePosition']['parent'],_0x47229f=_0xa9f0ca['getAttribute']('vid_end'),_0x176f97=_0x16b58c['getAttribute']('vid_start');_0xa9f0ca['_setAttribute']('vid_end',_0x16b58c['getAttribute']('vid_end')),_0x16b58c['_setAttribute']('vid_end',_0x47229f),this['_touched']['set'](_0x176f97,{'userId':_0x2254fa}),this['_touched']['set'](_0x47229f,{'userId':_0x2254fa}),_0x15ce9d['_execute']();}['_handleSplitOperation'](_0x10ad84){const _0x2cda9c=null===(_0x10ad84=this['_cloneOperation'](_0x10ad84,this['_idsRoots']))['_authorId']?null:_0x10ad84['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x4108a4=_0x10ad84['graveyardPosition'],_0x326094=_0x10ad84['splitPosition']['parent'];_0x10ad84['_execute']();const _0x1a551d=_0x326094['getAttribute']('vid_end'),_0x346672=_0x10ad84['insertionPosition']['nodeAfter'];if(_0x4108a4){const _0x3da3ee=_0x346672['getAttribute']('vid_end'),_0x12324c=_0x326094['getAttribute']('vid_end');_0x326094['_setAttribute']('vid_end',_0x3da3ee),_0x346672['_setAttribute']('vid_end',_0x12324c),this['_touched']['set'](_0x326094['getAttribute']('vid_end'),{'userId':_0x2cda9c}),this['_touched']['set'](_0x346672['getAttribute']('vid_start'),{'userId':_0x2cda9c});}else{const _0x1e4098=this['_revisionId']++,_0x45ddd5=this['_revisionId']++;_0x326094['_setAttribute']('vid_end',_0x1e4098),_0x346672['_setAttribute']('vid_start',_0x45ddd5),_0x346672['_setAttribute']('vid_end',_0x1a551d),this['_touched']['set'](_0x1e4098,{'userId':_0x2cda9c}),this['_touched']['set'](_0x45ddd5,{'userId':_0x2cda9c});}}['_handleMarkerOperation'](_0x10755c){if(!_0x10755c['affectsData'])return;const _0x77a8f2=(_0x10755c=this['_cloneOperation'](_0x10755c,this['_diffRoots']))['oldRange']?_0x10755c['oldRange']['root']:null,_0x389785=_0x10755c['newRange']?_0x10755c['newRange']['root']:null;_0x77a8f2&&this['_markers']['delete'](_0x10755c['name']),_0x389785&&this['_markers']['set'](_0x10755c['name'],_0x10755c['newRange']['clone']());const _0x102ebe=null===_0x10755c['_authorId']?null:_0x10755c['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x5bd12f=_0x10755c['name'];if(!this['_touchedMarkers']['has'](_0x5bd12f))return void this['_touchedMarkers']['set'](_0x5bd12f,{'range':_0x10755c['oldRange'],'userId':_0x102ebe});const _0x38d2eb=this['_touchedMarkers']['get'](_0x5bd12f),_0x104429=_0x38d2eb['range'],_0x2979bd=_0x10755c['newRange'];null==_0x104429&&null==_0x2979bd||_0x104429&&_0x2979bd&&_0x104429['isEqual'](_0x2979bd)?this['_touchedMarkers']['delete'](_0x10755c['name']):_0x38d2eb['userId']=_0x102ebe;}['_handleRootOperation'](_0x26a0f7,_0x5e96e8){this['_diffRoots']['has'](_0x26a0f7['rootName'])?this['_diffRoots']['get'](_0x26a0f7['rootName'])['_isAttached']=_0x26a0f7['isAdd']:(this['_diffRoots']['set'](_0x26a0f7['rootName'],wt(_0x26a0f7['rootName'],_0x26a0f7['elementName'],!0x0)),this['_diffRootsAttributes']['set'](_0x26a0f7['rootName'],{}),_0x5e96e8&&this['_idsRoots']['set'](_0x26a0f7['rootName'],wt(_0x26a0f7['rootName'],_0x26a0f7['elementName'],!0x0)));const _0x5b26a0=null===_0x26a0f7['_authorId']?null:_0x26a0f7['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x2dc95b=this['_touchedRoots']['get'](_0x26a0f7['rootName']);_0x2dc95b&&_0x2dc95b['userId']===_0x5b26a0?this['_touchedRoots']['delete'](_0x26a0f7['rootName']):this['_touchedRoots']['set'](_0x26a0f7['rootName'],{'userId':_0x5b26a0,'isAttached':_0x26a0f7['isAdd']});}['_handleRootAttributeOperation'](_0x515570){const _0xcad375=this['_diffRootsAttributes']['get'](_0x515570['root']['rootName']);null===_0x515570['newValue']?delete _0xcad375[_0x515570['key']]:_0xcad375[_0x515570['key']]=_0x515570['newValue'];}}function gt(_0x59d5fd){const _0x83fd3f=wt(_0x59d5fd['rootName'],_0x59d5fd['name'],_0x59d5fd['isAttached']());for(const _0x1af81e of _0x59d5fd['getChildren']()){const _0x2c6f48=_0x1af81e['_clone'](!0x0);_0x83fd3f['_appendChild'](_0x2c6f48);}return _0x83fd3f;}function wt(_0x536fa1,_0x76c9e9,_0x7ceb7b=!0x0){const _0x212a9a=new _0x538fb3();return _0x212a9a['rootName']=_0x536fa1,_0x212a9a['name']=_0x76c9e9,_0x212a9a['_isAttached']=_0x7ceb7b,_0x212a9a['isAttached']=()=>_0x212a9a['_isAttached'],_0x212a9a;}function mt(_0x38923f,_0x2f51f0,_0x525dc5){const _0x250ba2='elementEnd'==_0x38923f['type']?_0x525dc5['createPositionAt'](_0x38923f['item'],'end'):_0x525dc5['createPositionBefore'](_0x38923f['item']);return _0x525dc5['createPositionFromPath'](_0x2f51f0,_0x250ba2['path'],_0x250ba2['stickiness']);}function pt(_0x17cdce,_0x5ca52c,_0x4a8c1f){const _0x521721='elementStart'==_0x17cdce['type']?_0x4a8c1f['createPositionAt'](_0x17cdce['item'],0x0):_0x4a8c1f['createPositionAfter'](_0x17cdce['item']);return _0x4a8c1f['createPositionFromPath'](_0x5ca52c,_0x521721['path'],_0x521721['stickiness']);}class RevisionHistorySaveRevisionFormView extends/* #__PURE__ -- @preserve */
25
+ _0xd8f0c9(_0x6b0c43){['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x29f6a8,_0x173ee6){super(_0x29f6a8),this['focusTracker']=new _0x204a41(),this['keystrokes']=new _0x4d6df5(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x173ee6),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'](),_0x11315e({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x3e2511=_0x18e73b=>_0x18e73b['stopPropagation']();this['keystrokes']['set']('arrowright',_0x3e2511),this['keystrokes']['set']('arrowleft',_0x3e2511),this['keystrokes']['set']('arrowup',_0x3e2511),this['keystrokes']['set']('arrowdown',_0x3e2511);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x4f5419){this['revisionNameInputView']['fieldView']['element']['value']=_0x4f5419['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x3e8dc2){const _0x384495=new _0x7cd47d(this['locale'],_0x1fb48d),_0x1dd9ac=_0x384495['fieldView'];_0x1dd9ac['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x458ff7=ft(this['locale'],'Name\x20of\x20the\x20revision');return!_0x3e8dc2&&(_0x458ff7+='\x20('+ft(this['locale'],'optional')+')'),(_0x384495['label']=_0x458ff7,_0x1dd9ac['on']('input',()=>{this['revisionNameInputValue']=_0x1dd9ac['element']['value']['trim']();}),_0x384495);}}class RevisionHistoryUI extends _0x3b8836{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[RevisionTracker];}['_saveRevisionFormView'];['init'](){const _0x1e9265=this['editor'],_0xfd7378=_0x1e9265['plugins']['get']('RevisionTracker');_0x1e9265['ui']['componentFactory']['add']('revisionHistory',_0x2fb61f=>{const _0x127f74=_0xcc940(_0x2fb61f),_0x1e4273=_0x127f74['panelView']['children'],_0x4c74cc=new _0x47cf56(_0x2fb61f),_0x46c122=new _0x55e3f4(_0x2fb61f),_0x2ca53d=this['_createSaveRevisionButton'](_0x8647ff),_0x15fdbf=new _0x55e3f4(_0x2fb61f),_0x49f3bc=this['_createOpenRevisionButton'](_0x8647ff);return _0x127f74['bind']('isEnabled')['to'](_0xfd7378,'isReady',_0xfd7378,'isEnabled',_0x1e9265,'isReadOnly',(_0x5a708c,_0x252e8f,_0x200477)=>_0x5a708c&&_0x252e8f&&!_0x200477),_0x127f74['buttonView']['set']({'icon':_0x184ecc,'label':ft(_0x2fb61f,'Revision\x20history'),'tooltip':!0x0}),_0x2ca53d['set']({'withText':!0x0,'role':'menuitem'}),_0x49f3bc['set']({'withText':!0x0,'role':'menuitem'}),this['listenTo'](_0x49f3bc,'execute',()=>{_0x127f74['isOpen']=!0x1,_0x1e9265['editing']['view']['focus']();},{'priority':'low'}),_0x46c122['children']['add'](_0x2ca53d),_0x15fdbf['children']['add'](_0x49f3bc),_0x4c74cc['role']='menu',_0x4c74cc['items']['addMany']([_0x46c122,_0x15fdbf]),_0x1e4273['add'](_0x4c74cc),_0x127f74;}),_0x1e9265['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x3dc3fc=this['editor'],_0x2e42a8=_0x3dc3fc['locale'],_0xf134ff=_0x3dc3fc['plugins']['get']('RevisionTracker'),_0x284d39=new _0x564222(_0x2e42a8),_0x47af08=new _0x3cbddb(_0x2e42a8);_0x284d39['bind']('isEnabled')['to'](_0xf134ff,'isReady',_0xf134ff,'isEnabled',_0x3dc3fc,'isReadOnly',(_0x1363ca,_0xfaf1be,_0x3107ed)=>_0x1363ca&&_0xfaf1be&&!_0x3107ed),_0x284d39['buttonView']['set']({'icon':_0x184ecc,'label':ft(_0x2e42a8,'Revision\x20history')});const _0x439044=new tt(_0x2e42a8,_0x284d39),_0x307148=this['_createSaveRevisionButton'](it);_0x307148['delegate']('execute')['to'](_0x284d39),_0x439044['children']['add'](_0x307148),_0x47af08['items']['add'](_0x439044);const _0x20c8d2=new tt(_0x2e42a8,_0x284d39),_0x8cbace=this['_createOpenRevisionButton'](it);return _0x8cbace['delegate']('execute')['to'](_0x284d39),_0x20c8d2['children']['add'](_0x8cbace),_0x47af08['items']['add'](_0x20c8d2),_0x284d39['panelView']['children']['add'](_0x47af08),_0x284d39;}['_createSaveRevisionButton'](_0x259597){const _0x3e68f1=this['editor'],_0x2b7908=_0x3e68f1['plugins']['get']('RevisionTracker'),_0x37a629=new _0x259597(_0x3e68f1['locale']);return _0x37a629['set']({'label':ft(_0x3e68f1['locale'],'Save\x20current\x20revision')}),_0x37a629['bind']('isEnabled')['to'](_0x2b7908,'isReady',_0x2b7908,'isEnabled',_0x3e68f1,'isReadOnly',(_0x844751,_0x543317,_0x250402)=>_0x844751&&_0x543317&&!_0x250402),this['listenTo'](_0x37a629,'execute',()=>{this['_showDialog']();}),_0x37a629;}['_createOpenRevisionButton'](_0x2428ac){const _0x481437=this['editor'],_0x1bac0f=_0x481437['plugins']['get']('RevisionTracker'),_0x4a58c2=new _0x2428ac(_0x481437['locale']);return _0x4a58c2['set']({'label':ft(_0x481437['locale'],'Open\x20revision\x20history')}),_0x4a58c2['bind']('isEnabled')['to'](_0x1bac0f,'isReady',_0x481437,'isReadOnly',(_0x2b3e10,_0x35cdb5)=>_0x2b3e10&&!_0x35cdb5),this['listenTo'](_0x4a58c2,'execute',()=>{_0x481437['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x4a58c2;}['_showDialog'](){const _0x4fa20b=this['editor'],_0x1f25b8=_0x4fa20b['locale'],_0x8dd9b6=_0x4fa20b['plugins']['get']('Dialog'),_0x355f8d=_0x4fa20b['plugins']['get']('RevisionTracker');function _0x317543(_0x557cea){_0x4fa20b['config']['get']('revisionHistory.requireRevisionName')&&''===_0x557cea['revisionName']?_0x557cea['revisionNameInputView']['errorText']=ft(_0x1f25b8,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x4fa20b['plugins']['get'](RevisionTracker)['saveRevision']({'name':_0x557cea['revisionName']}),_0x8dd9b6['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x317543(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x8dd9b6['show']({'id':'revisionSave','title':ft(_0x1f25b8,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':ft(_0x4fa20b['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x8dd9b6['hide']()},{'label':ft(_0x4fa20b['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x238cd0){_0x238cd0['bind']('isEnabled')['to'](_0x355f8d,'isReady',_0x355f8d,'isEnabled',_0x4fa20b,'isReadOnly',(_0x5db2ad,_0xc6408,_0x59728d)=>_0x5db2ad&&_0xc6408&&!_0x59728d);},'onExecute':()=>_0x317543(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x38c2ed=this['editor'],_0x37484a=_0x38c2ed['locale'];this['_saveRevisionFormView']=new RevisionHistorySaveRevisionFormView(_0x37484a,_0x38c2ed['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class ChangeDetailsView extends _0x6b0c43{['changeId'];['_model'];constructor(_0x2f356d,_0x3109ea){super(_0x2f356d),this['_model']=_0x3109ea,this['changeId']=_0x3109ea['id'];const _0x56f5b7=this['bindTemplate'],_0x34338d=ft(_0x2f356d,_0x3109ea['data']['isSuggestion']?'Suggested\x20by':'add'==_0x3109ea['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x3109ea['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x56f5b7['to']('type',_0x5d1213=>'ck-revision-change__'+_0x5d1213)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x34338d}]},{'text':'\x20'+_0x3109ea['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class ChangeItem extends/* #__PURE__ -- @preserve */
26
+ _0x4dc482(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x65d574){super(),this['id']=_0x65d574['id']||_0x439976(),this['author']=_0x65d574['author'],this['type']=_0x65d574['type'],this['data']=_0x65d574['data']||{},this['rootName']=_0x65d574['rootName'],this['set']('createdAt',_0x65d574['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(_0x56632b,_0x83a169){this['newRevisionId']=_0x56632b,this['oldRevisionId']=_0x83a169,this['changes']=new _0xe9e71e();}['_setChanges'](_0x588f15){for(const _0x32b3c4 of _0x588f15)this['changes']['add'](_0x32b3c4);}}class RevisionViewer extends _0x3b8836{['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[_0x51d413,et,RevisionsRepository,RevisionHistoryUtils];}constructor(_0x474a75){super(_0x474a75),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',(_0x10c252,_0x5563e5,_0x13e526)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x5421fb=>{for(const _0x4bfc70 of this['editor']['editing']['view']['document']['roots'])_0x13e526?_0x5421fb['removeClass']('ck-editor__editable__overlay',_0x4bfc70):_0x5421fb['addClass']('ck-editor__editable__overlay',_0x4bfc70);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x4c4fdf=>null!==_0x4c4fdf),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x5db196,_0x51c636,_0x1989f4)=>_0x5db196&&_0x1989f4?_0x51c636['changes']['getIndex'](_0x1989f4):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x4d407b,_0x2ca930)=>_0x4d407b?_0x2ca930['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](et);}['init'](){const _0x431827=this['editor'],_0x3c4b10=new ShowChangeCommand(_0x431827,{'direction':'backward'}),_0x163eec=new ShowChangeCommand(_0x431827,{'direction':'forward'});(_0x431827['commands']['add']('showPreviousChange',_0x3c4b10),_0x431827['commands']['add']('showNextChange',_0x163eec),_0x431827['commands']['add']('restoreRevision',new RestoreRevisionCommand(_0x431827)),this['on']('change:numberOfChanges',()=>{_0x3c4b10['refresh'](),_0x163eec['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x431827['enableReadOnlyMode']('revision-viewer'),_0x431827['plugins']['has']('WidgetToolbarRepository'))&&_0x431827['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x587509){return await this['_utils']['loadRevisionData'](_0x587509,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x587509);}async['getRevisionRootsAttributes'](_0x4ce3b4){return await this['_utils']['loadRevisionData'](_0x4ce3b4,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x4ce3b4);}async['compare'](_0x1e131e,_0x5c1587,_0x1bac3b=!0x1){if(!this['isEnabled'])return;const _0x17ed86=this['diff'],_0x4d09d8=this['repository'],_0x52da7c='string'==typeof _0x1e131e?_0x4d09d8['getRevision'](_0x1e131e):_0x1e131e,_0x13bfea='string'==typeof _0x5c1587?_0x4d09d8['getRevision'](_0x5c1587):_0x5c1587,_0x31d594=_0x52da7c['id'],_0x1081c9=_0x13bfea?_0x13bfea['id']:null;if(!_0x1bac3b&&this['diff']&&this['diff']['newRevisionId']===_0x31d594&&this['diff']['oldRevisionId']===_0x1081c9)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new RevisionDiff(_0x31d594,_0x1081c9);const _0x62fd0d=this['_getRevisionsRange'](_0x52da7c,_0x13bfea,!0x0)['map'](_0x1a1d93=>this['_utils']['loadRevisionData'](_0x1a1d93,this['adapter']));return _0x62fd0d['push'](new Promise(_0x5e0d06=>{setTimeout(_0x5e0d06,0x14);})),Promise['all'](_0x62fd0d)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x247b5b=this['_getDiff'](_0x31d594,_0x1081c9);for(const _0xcc3849 of _0x247b5b['changes'])this['_changeIdToChange']['set'](_0xcc3849['id'],_0xcc3849);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x1f977e=>{for(const _0x27ed03 of this['editor']['model']['document']['getRootNames']())_0x1f977e['detachRoot'](_0x27ed03);for(const _0x3b6007 of Object['keys'](_0x247b5b['model'])){const _0x117d25=_0x247b5b['model'][_0x3b6007]['name'],_0x108bb5=_0x1f977e['addRoot'](_0x3b6007,_0x117d25);for(const _0x118dfa of Object['keys'](_0x247b5b['attributes'][_0x3b6007]))_0x1f977e['setAttribute'](_0x118dfa,_0x247b5b['attributes'][_0x3b6007][_0x118dfa],_0x108bb5);_0x1f977e['insert'](_0x247b5b['model'][_0x3b6007],_0x108bb5,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x247b5b['changes'])),this['isReady']=!0x0;})['catch'](_0x1693e3=>{console['error'](_0x1693e3),this['_cleanUp'](),_0x17ed86&&(this['diff']=_0x17ed86),this['isReady']=!0x0;});}['addRevisionData'](_0x3bcaf3,_0x82e4c){const _0x1158d2=this['repository']['createRevision'](_0x3bcaf3);return _0x1158d2['on']('_update',(_0x5dcb88,_0x5a2b18,_0x2c06b9)=>_0x82e4c(_0x5a2b18,_0x2c06b9,_0x1158d2)),this['repository']['addRevision'](_0x1158d2),_0x1158d2;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x18fbf4=>{for(const _0xefc35a of this['editor']['model']['document']['getRootNames']())_0x18fbf4['detachRoot'](_0xefc35a);});}['_sortAndFilterDiffChanges'](_0x8e2b36){const _0x13f19c=[],_0x2f79a9=new Map();for(const _0x147839 of this['editor']['model']['document']['getRootNames']()){const _0x3f1987=this['editor']['editing']['view']['getDomRoot'](_0x147839);if(!_0x3f1987)continue;const _0x3f6570=_0x3f1987['getClientRects']()['item'](0x0);_0x3f6570&&(_0x13f19c['push'](_0x147839),_0x2f79a9['set'](_0x147839,_0x3f6570));}return _0x13f19c['sort']((_0x51f851,_0x19a4ee)=>{const _0x5cff2c=_0x2f79a9['get'](_0x51f851),_0x35e32b=_0x2f79a9['get'](_0x19a4ee);return _0x5cff2c['y']-_0x35e32b['y']||_0x5cff2c['x']-_0x35e32b['x'];}),(_0x8e2b36=_0x8e2b36['filter'](_0x3a215d=>_0x13f19c['includes'](_0x3a215d['rootName'])))['sort']((_0x5a5720,_0x1e4820)=>_0x13f19c['indexOf'](_0x5a5720['rootName'])-_0x13f19c['indexOf'](_0x1e4820['rootName'])),_0x8e2b36;}['_makeTape'](_0x3dbf2f){const _0x24dfc9=Array['from'](_0x3dbf2f['markers'])['filter'](([_0x16d8f7,_0x38159f])=>_0x16d8f7['startsWith']('revision:')&&!_0x38159f['isCollapsed']),_0x2f0f6e=Array['from'](this['editor']['model']['createRangeIn'](_0x3dbf2f)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x24dfc9['length'])for(const _0x2ff1e4 of _0x2f0f6e){const [_0x1ada2d,_0x2369a5]=_0x24dfc9[0x0],[,_0x371139,_0x386413]=_0x1ada2d['split'](':');if(_0x2369a5['end']['isEqual'](_0x2ff1e4['nextPosition'])&&_0x24dfc9['shift'](),(_0x2ff1e4['previousPosition']['isEqual'](_0x2369a5['start'])||_0x2ff1e4['previousPosition']['isAfter'](_0x2369a5['start']))&&('insertion'==_0x371139?_0x2ff1e4['isAdded']={'userId':_0x386413}:'deletion'==_0x371139&&(_0x2ff1e4['isRemoved']={'userId':_0x386413})),0x0==_0x24dfc9['length'])break;}return _0x2f0f6e;}['_refreshStartEndIndex'](_0x4ff48a){const _0x50d97f=new Map();for(let _0x5d35cf=0x0;_0x5d35cf<_0x4ff48a['length'];_0x5d35cf++)'text'===_0x4ff48a[_0x5d35cf]['type']?(_0x4ff48a[_0x5d35cf]['item']['startIndex']=_0x5d35cf,_0x4ff48a[_0x5d35cf]['item']['endIndex']=_0x5d35cf):('elementStart'===_0x4ff48a[_0x5d35cf]['type']?_0x4ff48a[_0x5d35cf]['item']['startIndex']=_0x5d35cf:'elementEnd'===_0x4ff48a[_0x5d35cf]['type']&&(_0x4ff48a[_0x5d35cf]['item']['endIndex']=_0x5d35cf),_0x50d97f['set'](_0x4ff48a[_0x5d35cf]['id'],_0x5d35cf));for(const _0x489ccb of _0x50d97f['values']())'elementStart'===_0x4ff48a[_0x489ccb]['type']?_0x4ff48a[_0x489ccb]['item']['endIndex']=_0x50d97f['get'](_0x4ff48a[_0x489ccb]['pairId']):'elementEnd'===_0x4ff48a[_0x489ccb]['type']&&(_0x4ff48a[_0x489ccb]['item']['startIndex']=_0x50d97f['get'](_0x4ff48a[_0x489ccb]['pairId']));}['_processTape'](_0x2f94cf){for(let _0x49aefd=0x0;_0x49aefd<_0x2f94cf['length'];_0x49aefd++){if('elementStart'===_0x2f94cf[_0x49aefd]['type'])_0x2f94cf[_0x49aefd]['item']['startIndex']=_0x49aefd;else{if('elementEnd'===_0x2f94cf[_0x49aefd]['type']){_0x2f94cf[_0x49aefd]['item']['endIndex']=_0x49aefd;const _0x445ccc=_0x2f94cf[_0x49aefd]['item']['startIndex'];_0x2f94cf[_0x445ccc]['pairId']=_0x2f94cf[_0x49aefd]['id'],_0x2f94cf[_0x49aefd]['pairId']=_0x2f94cf[_0x445ccc]['id'];}else _0x2f94cf[_0x49aefd]['item']['startIndex']=_0x49aefd,_0x2f94cf[_0x49aefd]['item']['endIndex']=_0x49aefd,_0x2f94cf[_0x49aefd]['pairId']=null;}_0x2f94cf[_0x49aefd]['markersStart']||(_0x2f94cf[_0x49aefd]['markersStart']=[],_0x2f94cf[_0x49aefd]['markersEnd']=[]);}}['_markInsertions'](_0x7bb8ee,_0x225d6a){const _0x1f590e=_0x7bb8ee['filter'](_0x2885f4=>!_0x2885f4['isAdded']);for(let _0x5e6849=0x0;_0x5e6849<_0x225d6a['length'];_0x5e6849++)_0x225d6a[_0x5e6849]['isAdded']&&(_0x1f590e[_0x5e6849]['isAdded']=_0x225d6a[_0x5e6849]['isAdded']);}['_getDiff'](_0x8b7725,_0x10be1a=null){const _0x2d3875=this['repository']['getRevision'](_0x8b7725),_0x2e6ade=_0x10be1a?this['repository']['getRevision'](_0x10be1a):null,_0x6cc462=this['_getRevisionsRange'](_0x2d3875,_0x2e6ade),_0x18917e=_0x6cc462[_0x6cc462['length']-0x1],_0x446e04=new Map(),_0xd42b23={'model':{},'attributes':{},'changes':[]},_0x37d9f0=new Set(),_0x47af52=new Map();for(let _0x13b140=_0x6cc462['length']-0x1;_0x13b140>=0x0;_0x13b140--){const _0x2518b=_0x6cc462[_0x13b140];for(const _0x192bc2 of Object['keys'](_0x2518b['diffData']))if(_0x2518b['diffData'][_0x192bc2]['attachChange']){const _0xa32cec=_0x2518b['diffData'][_0x192bc2]['attachChange'];_0xa32cec['isAttached']?(_0x37d9f0['add'](_0x192bc2),_0x47af52['has'](_0x192bc2)&&_0x47af52['get'](_0x192bc2)['userId']==_0xa32cec['userId']?_0x47af52['delete'](_0x192bc2):_0x47af52['set'](_0x192bc2,_0xa32cec)):_0x47af52['has'](_0x192bc2)?(_0x37d9f0['delete'](_0x192bc2),_0x47af52['delete'](_0x192bc2)):(_0x37d9f0['add'](_0x192bc2),_0x47af52['set'](_0x192bc2,_0xa32cec));}else _0x37d9f0['add'](_0x192bc2);}for(const _0x5b8f0d of _0x37d9f0){const _0x446b3a=_0x47af52['has'](_0x5b8f0d)&&!_0x47af52['get'](_0x5b8f0d)['isAttached'];let _0x3880b4=_0x446b3a?_0x6cc462['length']-0x1:0x0;const _0x50a582=_0x446b3a?-0x1:0x1;for(;_0x6cc462[_0x3880b4];){const _0x1075fc=_0x6cc462[_0x3880b4];if(_0x1075fc['diffData'][_0x5b8f0d]){const _0x11103e=_0x446b3a?_0x1075fc['diffData'][_0x5b8f0d]['attributesBefore']:_0x1075fc['diffData'][_0x5b8f0d]['attributesAfter'];_0xd42b23['attributes'][_0x5b8f0d]=_0x11103e?_0xea4767(_0x11103e):{};break;}_0x3880b4+=_0x50a582;}}for(const _0x562f86 of _0x6cc462){_0x562f86['model']={};for(const _0x51130d of _0x562f86['authors'])_0x446e04['set'](_0x51130d['id'],_0x51130d);for(const _0x422e50 of _0x37d9f0){const _0x28d2ce=_0x562f86['diffData'][_0x422e50]?_0x562f86['diffData'][_0x422e50]['insertions']:'[]',_0x16cff9=_0x562f86['diffData'][_0x422e50]?_0x562f86['diffData'][_0x422e50]['deletions']:'[]',_0x3abbcf=_0x562f86['diffData'][_0x422e50]?.['rootElementName']||'$root';_0x562f86['model'][_0x422e50]={'insertions':this['_utils']['_makeModelFromViewString'](_0x28d2ce,_0x3abbcf),'deletions':this['_utils']['_makeModelFromViewString'](_0x16cff9,_0x3abbcf)};}}for(const _0xe8de35 of _0x37d9f0){let _0x416ab2=null,_0x33ffc4=0x0;const _0x5a70ea=_0x6cc462['map'](_0x2398da=>_0x2398da['diffData'][_0xe8de35]?.['rootElementName'])['find'](_0x518daa=>void 0x0!==_0x518daa)||'$root',_0x4871b6=new Map(Array['from'](_0x2d3875['model'][_0xe8de35]['insertions']['markers'])['filter'](([_0x108a6d])=>!_0x108a6d['startsWith']('revision:')));let _0x462386=0x0;for(const _0x142c87 of _0x6cc462){const _0x51decc=this['_makeTape'](_0x142c87['model'][_0xe8de35]['insertions']);_0x142c87==_0x2d3875?(_0x416ab2=_0x51decc,_0x33ffc4=_0x416ab2['length'],_0x416ab2['forEach'](_0x2af23c=>{_0x2af23c['id']=_0x462386++;}),this['_processTape'](_0x416ab2)):this['_markInsertions'](_0x416ab2,_0x51decc);const _0x11113a=_0x416ab2['filter'](_0x1d3a7d=>!_0x1d3a7d['isAdded'])['map'](_0x3c3948=>_0x3c3948['id']);let _0x2082e7=0x0;const _0x2c15e2=this['_makeTape'](_0x142c87['model'][_0xe8de35]['deletions']);_0x2c15e2['forEach'](_0x45b21a=>{_0x45b21a['isRemoved']?_0x45b21a['id']=_0x33ffc4++:_0x45b21a['id']=_0x11113a[_0x2082e7++];}),this['_processTape'](_0x2c15e2),this['_setDistance'](_0x416ab2,'isAdded'),this['_setDistance'](_0x2c15e2,'isRemoved'),_0x142c87==_0x2d3875&&this['_markMarkers'](_0x416ab2,_0x4871b6),_0x416ab2=this['_joinTapes'](_0x416ab2,_0x2c15e2),this['_refreshStartEndIndex'](_0x416ab2),this['_setDistance'](_0x416ab2,'isRemoved');}_0x416ab2=_0x416ab2['filter'](_0x1b3017=>!(_0x1b3017['isAdded']&&_0x1b3017['isRemoved']));const _0x471b4f=new Map(_0x18917e['model'][_0xe8de35]['deletions']['markers']),_0x1a9869=new Set(_0x4871b6['keys']());for(const _0x52081f of _0x471b4f['keys']())_0x1a9869['delete'](_0x52081f);this['_markSuggestions'](_0x416ab2,_0x1a9869),this['_fixObsoleteTags'](_0x416ab2),_0x416ab2=this['_removeMissingPairs'](_0x416ab2),_0x416ab2=this['_markMismatchedRemovedTags'](_0x416ab2),_0x416ab2=this['_removeUnsupportedChanges'](_0x416ab2);const {root:_0x28d4f7,changes:_0x5a243e}=this['_makeModelFromTape'](_0x416ab2,_0x446e04,_0xe8de35,_0x5a70ea);_0xd42b23['model'][_0xe8de35]=_0x28d4f7;const _0x33bb30=_0x47af52['get'](_0xe8de35);if(_0x33bb30){const _0x438e4e=_0x446e04['get'](_0x33bb30['userId']),_0x22f44c=new ChangeItem({'author':_0x438e4e,'type':_0x33bb30['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0xe8de35});_0x5a243e['unshift'](_0x22f44c),_0xd42b23['attributes'][_0xe8de35]['revisionHistoryAttachChange']=_0x22f44c['id'];}_0xd42b23['changes']=_0xd42b23['changes']['concat'](_0x5a243e);}return _0xd42b23;}['_markMarkers'](_0x5563cf,_0x23ff7c){for(let _0x19a32f=0x0;_0x19a32f<_0x5563cf['length'];_0x19a32f++)for(const [_0x4dcbae,_0x42964c]of _0x23ff7c)!_0x42964c['isCollapsed']&&_0x42964c['start']['isEqual'](_0x5563cf[_0x19a32f]['previousPosition'])&&_0x5563cf[_0x19a32f]['markersStart']['push'](_0x4dcbae),_0x42964c['end']['isEqual'](_0x5563cf[_0x19a32f]['nextPosition'])&&_0x5563cf[_0x19a32f]['markersEnd']['push'](_0x4dcbae);}['_joinTapes'](_0x4ee215,_0x54ff6c){let _0x3b1536=[],_0x52c376=0x0,_0x252b1b=0x0;for(;_0x52c376<_0x4ee215['length']||_0x252b1b<_0x54ff6c['length'];){const _0x384b74=_0x4ee215[_0x52c376]||{},_0x443916=_0x54ff6c[_0x252b1b]||{};if(_0x384b74['id']==_0x443916['id'])_0x52c376++,_0x252b1b++,_0x3b1536['push'](_0x384b74);else{if(_0x443916['isRemoved']&&_0x384b74['isAdded']){const {commonTape:_0x7c0f8b,iEnd:_0x2829c6,jEnd:_0x268a3d}=this['_threeWayMerge'](_0x4ee215,_0x52c376,_0x54ff6c,_0x252b1b);_0x3b1536=_0x3b1536['concat'](_0x7c0f8b),_0x52c376=_0x2829c6,_0x252b1b=_0x268a3d;}else _0x443916['isRemoved']?(_0x252b1b++,_0x3b1536['push'](_0x443916)):(_0x52c376++,_0x3b1536['push'](_0x384b74));}}return _0x3b1536;}['_markSuggestions'](_0x238493,_0x381672){const _0x40df82=[];for(let _0x4976dc=0x0;_0x4976dc<_0x238493['length'];_0x4976dc++){for(let _0x3ee8db=0x0;_0x3ee8db<_0x238493[_0x4976dc]['markersStart']['length'];_0x3ee8db++){const _0x448af7=_0x238493[_0x4976dc]['markersStart'][_0x3ee8db];if(!_0x381672['has'](_0x448af7))continue;const {group:_0xdef5e,type:_0x10013f,authorId:_0xbd8348}=_0xe8e0f4(_0x448af7);'revision-suggestion'!=_0xdef5e||'insertion'!=_0x10013f&&'deletion'!=_0x10013f||(_0x40df82['unshift']({'type':_0x10013f,'name':_0x448af7,'userId':_0xbd8348}),_0x238493[_0x4976dc]['markersStart']['splice'](_0x3ee8db,0x1),_0x3ee8db--);}_0x345495(_0x238493[_0x4976dc]);for(let _0x482dba=0x0;_0x482dba<_0x238493[_0x4976dc]['markersEnd']['length'];_0x482dba++){const _0xcad840=_0x238493[_0x4976dc]['markersEnd'][_0x482dba];if(!_0x381672['has'](_0xcad840))continue;const {group:_0x7eaf8f,type:_0x59c5a8}=_0xe8e0f4(_0xcad840);if('revision-suggestion'!=_0x7eaf8f||'insertion'!=_0x59c5a8&&'deletion'!=_0x59c5a8)continue;_0x238493[_0x4976dc]['markersEnd']['splice'](_0x482dba,0x1),_0x482dba--;const _0x2e1034=_0x40df82['findIndex'](_0x3225de=>_0x3225de['name']==_0xcad840);_0x2e1034>-0x1&&_0x40df82['splice'](_0x2e1034,0x1);}}function _0xe8e0f4(_0x5a0cb1){const _0x14e1f4=_0x5a0cb1['split'](':');return{'group':_0x14e1f4[0x0],'type':_0x14e1f4[0x1],'subType':_0x14e1f4['length']>=0x5?_0x14e1f4[0x2]:null,'id':_0x14e1f4['length']<0x5?_0x14e1f4[0x2]:_0x14e1f4[0x3],'authorId':_0x14e1f4['length']<0x5?_0x14e1f4[0x3]:_0x14e1f4[0x4],'markerCount':0x6==_0x14e1f4['length']?_0x14e1f4[0x5]:null};}function _0x345495(_0x446c64){for(let _0x3160e1=0x0;_0x3160e1<_0x40df82['length'];_0x3160e1++){if(_0x446c64['isAdded']&&'insertion'==_0x40df82[_0x3160e1]['type']&&_0x446c64['isAdded']['userId']==_0x40df82[_0x3160e1]['userId'])return _0x446c64['isAddSuggestion']=_0x40df82[_0x3160e1],void delete _0x446c64['isAdded'];if(!_0x446c64['isAdded']&&!_0x446c64['isRemoved']&&'deletion'==_0x40df82[_0x3160e1]['type'])return void(_0x446c64['isRemoveSuggestion']=_0x40df82[_0x3160e1]);}}}['_setDistance'](_0x8035d5,_0x165e18){let _0x8ecccc=0x0,_0x367ee6=!0x1;const _0x1ac8a4=new Map();for(const _0x1f6bf4 of _0x8035d5)_0x1f6bf4[_0x165e18]?_0x367ee6&&(_0x8ecccc++,_0x367ee6=!0x1):(_0x8ecccc++,_0x367ee6=!0x0),_0x1ac8a4['set'](_0x1f6bf4['id'],_0x8ecccc);for(let _0x270661=0x0;_0x270661<_0x8035d5['length'];_0x270661++){if('isRemoved'==_0x165e18&&_0x8035d5[_0x270661]['isAdded']||'isAdded'==_0x165e18&&_0x8035d5[_0x270661]['isRemoved'])continue;if('text'==_0x8035d5[_0x270661]['type']){_0x8035d5[_0x270661]['distance']=0x0;continue;}const _0x451265=_0x1ac8a4['get'](_0x8035d5[_0x270661]['pairId']),_0x37f39f=_0x1ac8a4['get'](_0x8035d5[_0x270661]['id']);_0x8035d5[_0x270661]['distance']=_0x451265-_0x37f39f;}}['_getRevisionsRange'](_0x57c18b,_0x4592e8,_0x16edee=!0x1){const _0x38afb6=[];let _0x29bebd=this['repository']['getIndex'](_0x57c18b),_0x1fc45a=this['repository']['getIndex'](_0x4592e8);for(-0x1==_0x1fc45a&&(_0x1fc45a=this['repository']['_revisions']['length'],_0x16edee=!0x1);_0x29bebd<_0x1fc45a;)_0x38afb6['push'](this['repository']['getRevision'](_0x29bebd)),_0x29bebd++;return _0x16edee&&_0x38afb6['push'](this['repository']['getRevision'](_0x29bebd)),_0x38afb6;}['_threeWayMerge'](_0x4436cb,_0x398933,_0x531bb7,_0x2907dd){const _0x51d4d5=this['editor']['model']['schema'];let _0x26bf0d=_0x398933;for(;_0x4436cb[_0x26bf0d]&&_0x4436cb[_0x26bf0d]['isAdded'];)_0x26bf0d++;let _0x5b93e7=_0x2907dd;for(;_0x531bb7[_0x5b93e7]&&_0x531bb7[_0x5b93e7]['isRemoved'];)_0x5b93e7++;_0x190deb(_0x4436cb,_0x398933,_0x26bf0d),_0x190deb(_0x531bb7,_0x2907dd,_0x5b93e7);const _0x46ae0f=_0x531bb7['slice'](_0x2907dd,_0x5b93e7)['concat'](_0x4436cb['slice'](_0x398933,_0x26bf0d));return _0x46ae0f['sort']((_0x4062bb,_0x1e4ffe)=>_0x4062bb['side']!=_0x1e4ffe['side']?_0x4062bb['side']-_0x1e4ffe['side']:_0x4062bb['level']!=_0x1e4ffe['level']?_0x4062bb['level']-_0x1e4ffe['level']:_0x4062bb['distance']!=_0x1e4ffe['distance']?_0x1e4ffe['distance']-_0x4062bb['distance']:!!_0x4062bb['isAdded']!=!!_0x1e4ffe['isAdded']?-0x1==_0x4062bb['side']||0x0==_0x4062bb['side']?_0x4062bb['isAdded']?-0x1:0x1:_0x4062bb['isAdded']?0x1:-0x1:_0x4062bb['index']-_0x1e4ffe['index']),{'commonTape':_0x46ae0f,'iEnd':_0x26bf0d,'jEnd':_0x5b93e7};function _0x190deb(_0x1515fe,_0x2ea8c8,_0x4b5173){let _0x2cd96b=-0x1,_0x5f3028=Number['POSITIVE_INFINITY'],_0x108540=!0x0;for(let _0x3e8198=_0x2ea8c8;_0x3e8198<_0x4b5173;_0x3e8198++)if(_0x51d4d5['isInline'](_0x1515fe[_0x3e8198]['item'])||(_0x108540=!0x1),_0x1515fe[_0x3e8198]['item']['startIndex']<_0x2ea8c8&&(_0x2cd96b=_0x3e8198),_0x1515fe[_0x3e8198]['item']['endIndex']>=_0x4b5173){_0x5f3028=_0x3e8198;break;}_0x108540&&(_0x2cd96b=_0x4b5173-0x1);for(let _0x44a6f1=_0x2ea8c8;_0x44a6f1<_0x4b5173;_0x44a6f1++)_0x1515fe[_0x44a6f1]['side']=_0x44a6f1<=_0x2cd96b?-0x1:_0x44a6f1<_0x5f3028?0x0:0x1,_0x1515fe[_0x44a6f1]['index']=_0x44a6f1;let _0x5f3f1a=0x0;for(let _0x448fb1=_0x2ea8c8;_0x448fb1<=_0x2cd96b;_0x448fb1++)0x0==_0x1515fe[_0x448fb1]['distance']?_0x1515fe[_0x448fb1]['level']=_0x5f3f1a:(_0x5f3f1a++,_0x1515fe[_0x448fb1]['level']=_0x5f3f1a,_0x5f3f1a++);for(let _0x551831=_0x2ea8c8;_0x551831<_0x4b5173;_0x551831++)0x0==_0x1515fe[_0x551831]['side']&&(_0x1515fe[_0x551831]['level']=_0x5f3f1a);_0x5f3f1a=0x0;for(let _0xc940aa=_0x4b5173-0x1;_0xc940aa>=_0x5f3028;_0xc940aa--)0x0==_0x1515fe[_0xc940aa]['distance']?_0x1515fe[_0xc940aa]['level']=_0x5f3f1a:(_0x5f3f1a--,_0x1515fe[_0xc940aa]['level']=_0x5f3f1a,_0x5f3f1a--);}}['_fixObsoleteTags'](_0x2d8002){const _0x177dca=new Map(),_0x206951=this['editor']['model']['schema'];for(let _0x37970b=0x1;_0x37970b<_0x2d8002['length'];_0x37970b++){let _0x3e2859,_0x5dcd9c,_0x3d3db9;const _0x23f470=_0x2d8002[_0x37970b],_0x38689d=_0x2d8002[_0x37970b-0x1];if('text'==_0x23f470['type'])continue;if(_0x23f470['type']!=_0x38689d['type'])continue;if(!_0x206951['isBlock'](_0x38689d['item'])||_0x206951['isLimit'](_0x38689d['item']))continue;if(!_0x206951['isBlock'](_0x23f470['item'])||_0x206951['isLimit'](_0x23f470['item']))continue;if((_0x2d8002[_0x37970b]['isAdded']||_0x2d8002[_0x37970b]['isAddSuggestion'])&&_0x2d8002[_0x37970b-0x1]['isRemoved'])_0x3e2859=_0x2d8002[_0x37970b],_0x5dcd9c=_0x2d8002[_0x37970b-0x1],_0x3d3db9=_0x37970b-0x1;else{if(!_0x2d8002[_0x37970b]['isRemoved']||!_0x2d8002[_0x37970b-0x1]['isAdded']&&!_0x2d8002[_0x37970b-0x1]['isAddSuggestion'])continue;_0x3e2859=_0x2d8002[_0x37970b-0x1],_0x5dcd9c=_0x2d8002[_0x37970b],_0x3d3db9=_0x37970b;}const _0x2ee56f=_0x3e2859['level']==_0x5dcd9c['level'],_0x51eb58=Math['abs'](_0x3e2859['level'])<Math['abs'](_0x5dcd9c['level'])&&0x0==_0x5dcd9c['distance'];(_0x2ee56f||_0x51eb58)&&(_0x177dca['set'](_0x5dcd9c['id'],_0x3e2859['id']),_0x2d8002['splice'](_0x3d3db9,0x1),_0x37970b--,_0x3e2859['isAdded']=!0x1);}for(let _0x13dea4=0x0;_0x13dea4<_0x2d8002['length'];_0x13dea4++)_0x177dca['has'](_0x2d8002[_0x13dea4]['pairId'])&&(_0x2d8002[_0x13dea4]['pairId']=_0x177dca['get'](_0x2d8002[_0x13dea4]['pairId']));}['_removeMissingPairs'](_0x33f6b6){const _0x947edd=new Set(_0x33f6b6['map'](_0x24ee98=>_0x24ee98['id']));for(let _0xced088=0x0;_0xced088<_0x33f6b6['length'];_0xced088++)_0x947edd['has'](_0x33f6b6[_0xced088]['pairId'])||0x0==_0x33f6b6[_0xced088]['distance']||(_0x33f6b6[_0xced088]['isIncorrect']=!0x0);return _0x33f6b6['filter'](_0x183313=>!_0x183313['isIncorrect']);}['_markMismatchedRemovedTags'](_0x864b0d){const _0x7ec546=new Set();for(let _0x47da97=0x0;_0x47da97<_0x864b0d['length'];_0x47da97++){if(_0x7ec546['has'](_0x864b0d[_0x47da97]['id'])&&_0x864b0d[_0x47da97]['isRemoved']&&(_0x864b0d[_0x47da97]['isIncorrect']=!0x0),_0x864b0d[_0x47da97]['isIncorrect'])continue;if(0x0==_0x864b0d[_0x47da97]['distance'])continue;if('elementStart'!=_0x864b0d[_0x47da97]['type'])continue;if(null==_0x864b0d[_0x47da97]['pairId'])continue;let _0x1afdd1=_0x47da97+0x1,_0x52e897=0x0;for(;_0x864b0d[_0x1afdd1]['id']!=_0x864b0d[_0x47da97]['pairId'];)'elementStart'==_0x864b0d[_0x1afdd1]['type']?_0x52e897++:'elementEnd'==_0x864b0d[_0x1afdd1]['type']&&_0x52e897--,_0x1afdd1++;if(0x0!=_0x52e897){if(_0x864b0d[_0x47da97]['isRemoved'])_0x864b0d[_0x47da97]['isIncorrect']=!0x0;else{for(;_0x1afdd1!=_0x47da97;)_0x864b0d[_0x1afdd1]['isRemoved']&&0x0!=_0x864b0d[_0x1afdd1]['distance']&&(_0x864b0d[_0x1afdd1]['isIncorrect']=!0x0,_0x7ec546['add'](_0x864b0d[_0x1afdd1]['pairId'])),_0x1afdd1--;}}}return _0x864b0d['filter'](_0x3180f7=>!_0x3180f7['isIncorrect']);}['_removeUnsupportedChanges'](_0x219000){const _0x55a7bb=this['editor']['model']['schema'];for(let _0x6fed31=0x0;_0x6fed31<_0x219000['length'];_0x6fed31++){if(!(_0x219000[_0x6fed31]['isAdded']||_0x219000[_0x6fed31]['isAddSuggestion']||_0x219000[_0x6fed31]['isRemoved']||_0x219000[_0x6fed31]['isRemoveSuggestion']))continue;if(0x0==_0x219000[_0x6fed31]['distance'])continue;const _0x4c9a52=_0x219000[_0x6fed31]['item'];_0x55a7bb['isBlock'](_0x4c9a52)||_0x55a7bb['isLimit'](_0x4c9a52)||(_0x219000[_0x6fed31]['isAdded']&&delete _0x219000[_0x6fed31]['isAdded'],_0x219000[_0x6fed31]['isAddSuggestion']&&delete _0x219000[_0x6fed31]['isAddSuggestion'],_0x219000[_0x6fed31]['isRemoveSuggestion']&&delete _0x219000[_0x6fed31]['isRemoveSuggestion'],_0x219000[_0x6fed31]['isRemoved']&&(_0x219000[_0x6fed31]['isIncorrect']=!0x0));}return _0x219000['filter'](_0x14535=>!_0x14535['isIncorrect']);}['_makeModelFromTape'](_0x438871,_0x54139a,_0x195adc,_0x317475){const _0xcd5e58=new _0x538fb3(),_0x4c3b69=[],_0x1301d7=new Map(),_0x2d3bb3=this['editor']['model'],_0x199ae7=_0x2d3bb3['schema'],_0x1de5ff=[_0xcd5e58],_0x5c8fda={},_0x32b001={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};_0xcd5e58['name']=_0x317475;let _0x52ef8d=null;const _0x26d06e=[0x0];for(let _0x5a0632=0x0;_0x5a0632<_0x438871['length'];_0x5a0632++)if('elementStart'===_0x438871[_0x5a0632]['type']){_0x438871[_0x5a0632]['previousPosition']=_0x2d3bb3['createPositionFromPath'](_0xcd5e58,_0x26d06e);const _0x299acc=new _0x1a0f77(_0x438871[_0x5a0632]['item']['name'],_0x438871[_0x5a0632]['item']['getAttributes']());_0x1de5ff[0x0]['_appendChild'](_0x299acc),_0x26d06e['push'](0x0),_0x1de5ff['unshift'](_0x299acc),_0x438871[_0x5a0632]['nextPosition']=_0x2d3bb3['createPositionFromPath'](_0xcd5e58,_0x26d06e);}else'elementEnd'===_0x438871[_0x5a0632]['type']?(_0x1de5ff['shift'](),_0x438871[_0x5a0632]['previousPosition']=_0x2d3bb3['createPositionFromPath'](_0xcd5e58,_0x26d06e),_0x26d06e['pop'](),_0x26d06e[_0x26d06e['length']-0x1]++,_0x438871[_0x5a0632]['nextPosition']=_0x2d3bb3['createPositionFromPath'](_0xcd5e58,_0x26d06e)):(_0x438871[_0x5a0632]['previousPosition']=_0x2d3bb3['createPositionFromPath'](_0xcd5e58,_0x26d06e),_0x52ef8d?_0x52ef8d['_data']+=_0x438871[_0x5a0632]['item']['data']:_0x52ef8d=new _0xa58127(_0x438871[_0x5a0632]['item']['data'],_0x438871[_0x5a0632]['item']['getAttributes']()),_0x438871[_0x5a0632+0x1]&&'text'===_0x438871[_0x5a0632+0x1]['type']&&_0x263318(_0x52ef8d,_0x438871[_0x5a0632+0x1]['item'])||(_0x1de5ff[0x0]['_appendChild'](_0x52ef8d),_0x52ef8d=null),_0x26d06e[_0x26d06e['length']-0x1]+=_0x438871[_0x5a0632]['item']['offsetSize'],_0x438871[_0x5a0632]['nextPosition']=_0x2d3bb3['createPositionFromPath'](_0xcd5e58,_0x26d06e));for(let _0x24f01c=0x0;_0x24f01c<_0x438871['length'];_0x24f01c++){const _0x4917ee=_0x438871[_0x24f01c]['previousPosition'],_0x893c8f=_0x438871[_0x24f01c]['nextPosition'];for(const _0x213273 of _0x438871[_0x24f01c]['markersStart'])_0x1301d7['set'](_0x213273,{'start':_0x4917ee,'end':null});_0x4a9edf('isRemoveSuggestion',_0x24f01c,_0x4917ee,_0x893c8f),_0x4a9edf('isAddSuggestion',_0x24f01c,_0x4917ee,_0x893c8f),_0x4a9edf('isRemoved',_0x24f01c,_0x4917ee,_0x893c8f),_0x4a9edf('isAdded',_0x24f01c,_0x4917ee,_0x893c8f);for(const _0x322013 of _0x438871[_0x24f01c]['markersEnd']){const _0x753f7a=_0x1301d7['get'](_0x322013);_0x753f7a?_0x753f7a['end']=_0x893c8f:_0x1301d7['set'](_0x322013,{'start':_0x893c8f,'end':_0x893c8f});}}for(const [_0xae232b,_0xaa26da]of _0x1301d7){const _0x112ec7=this['editor']['model']['createRange'](_0xaa26da['start'],_0xaa26da['end']);_0xcd5e58['markers']['set'](_0xae232b,_0x112ec7);}return _0x4c3b69['sort']((_0x1a417d,_0x253cd9)=>{const _0x4b9b45=_0xcd5e58['markers']['get']('revision:'+_0x1a417d['id']),_0x20abbf=_0xcd5e58['markers']['get']('revision:'+_0x253cd9['id']);return _0x4b9b45['start']['isBefore'](_0x20abbf['start'])?-0x1:_0x4b9b45['start']['isAfter'](_0x20abbf['start'])?0x1:_0x4b9b45['end']['isBefore'](_0x20abbf['end'])?-0x1:_0x4b9b45['end']['isAfter'](_0x20abbf['end'])?0x1:'add'===_0x1a417d['type']?-0x1:0x1;}),{'root':_0xcd5e58,'changes':_0x4c3b69};function _0x4a9edf(_0x248c65,_0x15363e,_0x2ac56e,_0x41ac89){const _0x5d66ba=!!_0x438871[_0x15363e][_0x248c65],_0x5b195a=_0x5d66ba?_0x438871[_0x15363e][_0x248c65]['userId']:null,_0x2176e0=_0x15363e===_0x438871['length']-0x1,_0x102ffd=_0x32b001[_0x248c65][0x0],_0x52f6d2=_0x199ae7['isObject'](_0x438871[_0x15363e]['item']);!_0x5c8fda[_0x248c65]&&_0x5d66ba?_0x5c8fda[_0x248c65]={'start':_0x2ac56e,'tapeItem':_0x438871[_0x15363e],'userId':_0x5b195a,'type':_0x248c65}:_0x5c8fda[_0x248c65]&&!_0x5d66ba?(_0x5c8fda[_0x248c65]['end']=_0x2ac56e,_0x13c675(_0x5c8fda[_0x248c65]),_0x5c8fda[_0x248c65]=null):_0x5c8fda[_0x248c65]&&_0x5d66ba&&_0x5c8fda[_0x248c65]['userId']!==_0x5b195a&&(_0x5c8fda[_0x248c65]['end']=_0x2ac56e,_0x102ffd&&_0x102ffd['userId']===_0x5c8fda[_0x248c65]['userId']||_0x13c675(_0x5c8fda[_0x248c65]),_0x5c8fda[_0x248c65]={'start':_0x2ac56e,'tapeItem':_0x438871[_0x15363e],'userId':_0x5b195a,'type':_0x248c65}),_0x5c8fda[_0x248c65]&&_0x52f6d2&&('elementStart'!==_0x438871[_0x15363e]['type']||_0x102ffd&&_0x102ffd['userId']===_0x5b195a||_0x32b001[_0x248c65]['unshift']({'userId':_0x5b195a,'object':_0x438871[_0x15363e]['item'],'change':_0x5c8fda[_0x248c65]}),'elementEnd'===_0x438871[_0x15363e]['type']&&_0x102ffd&&_0x102ffd['object']===_0x438871[_0x15363e]['item']&&(_0x32b001[_0x248c65]['shift'](),_0x5c8fda[_0x248c65]=_0x102ffd['change'])),_0x5c8fda[_0x248c65]&&_0x2176e0&&(_0x5c8fda[_0x248c65]['end']=_0x41ac89,_0x13c675(_0x5c8fda[_0x248c65]),_0x5c8fda[_0x248c65]=null);}function _0x13c675({start:_0x21f252,end:_0x422127,tapeItem:_0x55c8b3,userId:_0x1ac888,type:_0x5de1c2}){const _0x54d296=_0x55c8b3['item'],_0x398c70=_0x2d3bb3['schema']['isBlock'](_0x54d296)&&!_0x2d3bb3['schema']['isLimit'](_0x54d296),_0x103077=_0x21f252['nodeAfter']==_0x422127['parent']&&_0x422127['isAtStart'];if(_0x398c70&&_0x103077)return;const _0x3545bb=_0x2d3bb3['createRange'](_0x21f252,_0x422127),_0x3ef7ed=_0x54139a['get'](_0x1ac888),_0x27932f=new ChangeItem({'author':_0x3ef7ed,'type':'isAdded'==_0x5de1c2||'isAddSuggestion'==_0x5de1c2?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x5de1c2||'isRemoveSuggestion'==_0x5de1c2},'createdAt':new Date(),'rootName':_0x195adc});_0x4c3b69['push'](_0x27932f),_0xcd5e58['markers']['set']('revision:'+_0x27932f['id'],_0x3545bb);}function _0x263318(_0x312e64,_0x2b0eeb){const _0x4c87d4=_0x312e64['getAttributes'](),_0x2fd296=_0x2b0eeb['getAttributes']();for(const _0x4e19a6 of _0x4c87d4){if(_0x4e19a6[0x1]!==_0x2b0eeb['getAttribute'](_0x4e19a6[0x0]))return!0x1;_0x2fd296['next']();}return _0x2fd296['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x4ca321=>{const _0x3ba7e1=_0x4ca321['markerName']['split'](':')[0x1],_0x71ecdf=this['_getChangeFromId'](_0x3ba7e1);if(!_0x71ecdf)return null;const _0x113ec3='add'==_0x71ecdf['type']?'insertion':'deletion',_0x308ae1=['ck-suggestion-marker','ck-suggestion-marker-'+_0x113ec3];return _0x71ecdf['data']['isSuggestion']&&_0x308ae1['push']('ck-suggestion-marker-'+_0x113ec3+'-new'),this['activeChange']==_0x71ecdf&&_0x308ae1['push']('ck-suggestion-marker--active'),{'classes':_0x308ae1,'attributes':{'data-change-id':_0x3ba7e1}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x109902=>{_0x109902['on']('element:pre',(_0x1da6dd,_0x112c7e,_0x23bebc)=>{const _0x5d9f97=_0x112c7e['viewItem']['getChild'](0x0);if(!_0x5d9f97||!_0x5d9f97['is']('element','code'))return;if(!_0x23bebc['consumable']['consume'](_0x5d9f97,{'attributes':['vid_start','vid_end']}))return;const _0x46292f=_0x112c7e['modelRange']['start']['nodeAfter'];_0x23bebc['writer']['setAttribute']('vid_start',_0x5d9f97['getAttribute']('vid_start'),_0x46292f),_0x23bebc['writer']['setAttribute']('vid_end',_0x5d9f97['getAttribute']('vid_end'),_0x46292f);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x1eb1df=>{_0x1eb1df['on']('element',(_0x21716e,_0xe94ba,_0x2e962d)=>{if(!_0x2e962d['consumable']['consume'](_0xe94ba['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0xe94ba['modelRange']['isCollapsed'])return;const _0x2525ac=_0xe94ba['modelRange']['start']['nodeAfter'];_0x2525ac['hasAttribute']('vid_start')||_0x2525ac['hasAttribute']('vid')||(_0x2e962d['writer']['setAttribute']('vid_start',_0xe94ba['viewItem']['getAttribute']('vid_start'),_0x2525ac),_0x2e962d['writer']['setAttribute']('vid_end',_0xe94ba['viewItem']['getAttribute']('vid_end'),_0x2525ac));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x2a2e48=>_0x2a2e48['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x56535d,[,_0x46d6b0])=>{['vid_start','vid_end','vid']['includes'](_0x46d6b0)&&(_0x56535d['return']=!0x0,_0x56535d['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x2585c8=>{_0x2585c8['on']('attribute:vid',(_0xdf815a,_0x683f4c,_0x3f46fc)=>{if('\x20'!=_0x683f4c['item']['data']||_0x683f4c['item']['parent']['maxOffset']>0x1)return;if(!_0x3f46fc['consumable']['consume'](_0x683f4c['item'],_0xdf815a['name']))return;const _0x4fa5dd=_0x3f46fc['writer'],_0x21eebd=_0x3f46fc['mapper']['toViewRange'](_0x683f4c['range']);_0x4fa5dd['wrap'](_0x21eebd,_0x4fa5dd['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x4f8a50){const _0x4c51f9=_0x4f8a50['plugins']['get']('RevisionViewer');return(_0xd66d3,_0x5221bb,_0xcaf41c)=>{const _0x1f6f6d=_0x5221bb['markerName']['split'](':')[0x1],_0x133e76=_0x4c51f9['_getChangeFromId'](_0x1f6f6d);if(!_0x133e76)return null;const _0x427f65='add'==_0x133e76['type']?'split':'merge';if(!_0xcaf41c['consumable']['test'](_0x5221bb['markerRange'],_0xd66d3['name']))return;const _0x30fdcc=_0x5221bb['markerRange']['getWalker'](),_0x5a2f2b=_0x5221bb['markerRange']['start'],_0xa11795=_0x4f8a50['model']['schema'];let _0x4344ee=null,_0x41f842=null,_0x50e21c=!0x1,_0x21f31c=!0x1;for(const _0xbfc1f9 of _0x30fdcc){const _0x40067d=_0xbfc1f9['item'];_0x50e21c=_0x50e21c||_0xa11795['isContent'](_0x40067d);const _0x879aa2=_0xcaf41c['mapper']['toViewElement'](_0x40067d);if(_0x879aa2&&_0x879aa2['getCustomProperty']('addHighlight'))return;'elementEnd'==_0xbfc1f9['type']&&(_0xa11795['isBlock'](_0x40067d)&&!_0xa11795['isLimit'](_0x40067d)&&(_0x40067d['nextSibling']||_0x5a2f2b['isAtEnd']?_0x4344ee&&_0x4344ee['parent']==_0x40067d||(_0x4344ee=_0x40067d,_0x557e3b(_0xbfc1f9['previousPosition']),_0x21f31c=!0x0):_0x41f842=_0x41f842||_0xbfc1f9['previousPosition']));}function _0x557e3b(_0x2c9414){const _0xb4b426=_0xcaf41c['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x427f65}),_0x1415a2=_0xcaf41c['mapper']['toViewPosition'](_0x2c9414);_0x133e76['data']['isSuggestion']&&_0xcaf41c['writer']['addClass']('ck-suggestion-marker-'+_0x427f65+'-new',_0xb4b426),_0x4c51f9['activeChange']==_0x133e76&&_0xcaf41c['writer']['addClass']('ck-suggestion-marker--active',_0xb4b426),_0xcaf41c['writer']['insert'](_0x1415a2,_0xb4b426),_0xcaf41c['mapper']['bindElementToMarker'](_0xb4b426,_0x5221bb['markerName']);}_0x50e21c||_0x21f31c||!_0x41f842||_0x557e3b(_0x41f842);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x31aa6f,_0x2b4d4b,_0x3e5b91)=>{const _0x1270ae=_0x3e5b91['mapper']['markerNameToElements'](_0x2b4d4b['markerName']);if(_0x1270ae){for(const _0x3a16a2 of _0x1270ae)(_0x3a16a2['hasClass']('ck-suggestion-marker-split')||_0x3a16a2['hasClass']('ck-suggestion-marker-merge'))&&(_0x3e5b91['mapper']['unbindElementFromMarkerName'](_0x3a16a2,_0x2b4d4b['markerName']),_0x3e5b91['writer']['remove'](_0x3a16a2));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x44a605,_0x212349,_0x3d5a75)=>{const _0x2912ea=_0x212349['markerName']['split'](':')[0x1],_0x38d9b9=this['_getChangeFromId'](_0x2912ea);if(!_0x38d9b9)return null;const _0x6bbe4c='add'==_0x38d9b9['type']?'split':'merge';if(_0x3d5a75['consumable']['test'](_0x212349['markerRange'],_0x44a605['name']))for(const _0x13cde6 of _0x212349['markerRange']['getItems']()){if(!_0x13cde6['is']('element','softBreak'))continue;const _0x7d7ba7=_0x3d5a75['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x6bbe4c}),_0x29657b=_0x3d5a75['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x13cde6));_0x38d9b9['data']['isSuggestion']&&_0x3d5a75['writer']['addClass']('ck-suggestion-marker-'+_0x6bbe4c+'-new',_0x7d7ba7),this['activeChange']==_0x38d9b9&&_0x3d5a75['writer']['addClass']('ck-suggestion-marker--active',_0x7d7ba7),_0x3d5a75['writer']['insert'](_0x29657b,_0x7d7ba7),_0x3d5a75['mapper']['bindElementToMarker'](_0x7d7ba7,_0x212349['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x28bb18=>{for(const _0x40e22e of this['editor']['model']['document']['getRootNames']()){const _0x347ecc=this['editor']['model']['document']['getRoot'](_0x40e22e),_0x522894=this['editor']['editing']['view']['document']['getRoot'](_0x40e22e);if(_0x522894){const _0x3e96da=_0x347ecc['getAttribute']('revisionHistoryAttachChange');if(_0x28bb18['removeAttribute']('data-change-id',_0x522894),_0x28bb18['removeClass']('ck-revision-history-root-add',_0x522894),_0x28bb18['removeClass']('ck-revision-history-root-remove',_0x522894),_0x28bb18['removeClass']('ck-revision-history-root--active',_0x522894),_0x3e96da){const _0x1fd27e=this['_getChangeFromId'](_0x3e96da);if(!_0x1fd27e)return null;_0x28bb18['setAttribute']('data-change-id',_0x3e96da,_0x522894),_0x28bb18['addClass']('ck-revision-history-root-'+_0x1fd27e['type'],_0x522894),this['activeChange']==_0x1fd27e&&_0x28bb18['addClass']('ck-revision-history-root--active',_0x522894);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x3a37db=>'revision-comment:'+_0x3a37db,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x587a7a=>'revision-suggestion:'+_0x587a7a,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x73d795=>({'name':'suggestion:'+_0x73d795,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x287202=>{const _0x28a942=_0x287202['markerName']['split'](':')[0x1];return'insertion'!=_0x28a942&&'deletion'!=_0x28a942?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x28a942]};}}),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',(_0x5ec8af,_0x1f800f,_0x4fec45)=>{const _0x4533bf=_0x4fec45['mapper']['markerNameToElements'](_0x1f800f['markerName']);if(_0x4533bf){for(const _0x1fe973 of _0x4533bf)_0x1fe973['is']('uiElement')&&(_0x4fec45['mapper']['unbindElementFromMarkerName'](_0x1fe973,_0x1f800f['markerName']),_0x4fec45['writer']['remove'](_0x1fe973));}},{'priority':'high'});}['_getChangeFromId'](_0x17784e){return this['_changeIdToChange']['get'](_0x17784e);}['_getViewForChange'](_0x2c5bf5){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new ChangeDetailsView(this['editor']['locale'],_0x2c5bf5),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x351c6f,_0x5d13ef,_0x3a2ce9,_0x20fa06)=>{_0x20fa06&&this['_balloon']['remove'](_0x20fa06),_0x3a2ce9&&(this['_balloon']['add']({'view':_0x3a2ce9,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x231985=this['editor']['editing'],_0x5943c4=this['_getChangeFromId'](_0x3a2ce9['changeId']);let _0x3f9445;if(_0x5943c4['data']['isOnRoot']){const _0x4a4e02=_0x231985['view']['getDomRoot'](_0x5943c4['rootName']);_0x3f9445=Array['from'](_0x4a4e02['getClientRects']());}else{const _0x319558=this['editor']['model']['markers']['get']('revision:'+_0x3a2ce9['changeId']);_0x3f9445=Array['from'](_0x231985['mapper']['markerNameToElements'](_0x319558['name']))['map'](_0x497126=>_0x231985['view']['domConverter']['mapViewToDom'](_0x497126))['map'](_0x388566=>Array['from'](_0x388566['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x3f9445[0x0];return _0x3f9445['find'](_0x2ff6b6=>_0x2ff6b6['top']-0x3<=this['_activeViewTarget']['y']&&_0x2ff6b6['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x2ff6b6['left']-0x3<=this['_activeViewTarget']['x']&&_0x2ff6b6['right']+0x3>=this['_activeViewTarget']['x'])||_0x3f9445[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x2d5608,_0x2f17b0,_0x366c27,_0x5712e3)=>{this['activeView']=_0x366c27?this['_getViewForChange'](_0x366c27):null,this['editor']['model']['change'](()=>{const _0x5f28e1=this['editor']['editing'];_0x5712e3&&(_0x5712e3['data']['isOnRoot']?_0x5f28e1['view']['change'](_0x3e4b88=>{_0x3e4b88['removeClass']('ck-revision-history-root--active',_0x5f28e1['view']['document']['getRoot'](_0x5712e3['rootName']));}):_0x5f28e1['reconvertMarker']('revision:'+_0x5712e3['id'])),_0x366c27&&(_0x366c27['data']['isOnRoot']?_0x5f28e1['view']['change'](_0x3be756=>{_0x3be756['addClass']('ck-revision-history-root--active',_0x5f28e1['view']['document']['getRoot'](_0x366c27['rootName']));}):_0x5f28e1['reconvertMarker']('revision:'+_0x366c27['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x1c0e11,_0x2244c8)=>{if(this['activeChange'])return;const _0x515b6f=this['_findChangeIdFromDomTarget'](_0x2244c8['target']),_0x3039b4=this['_changeIdToChange']['get'](_0x515b6f);_0x3039b4?(this['_activeViewTarget']={'x':_0x2244c8['domEvent']['x'],'y':_0x2244c8['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x3039b4)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0xee22b1,_0x319c48)=>{const _0x558e5a=this['_findChangeIdFromDomTarget'](_0x319c48['target']),_0x44c3e3=this['_changeIdToChange']['get'](_0x558e5a);_0x44c3e3?(this['_activeViewTarget']={'x':_0x319c48['domEvent']['x'],'y':_0x319c48['domEvent']['y']},_0x44c3e3===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x44c3e3):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x4490f0){do{const _0x20f6f9=_0x4490f0['getAttribute']('data-change-id');if(_0x20f6f9)return _0x20f6f9;_0x4490f0=_0x4490f0['parent'];}while(_0x4490f0);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x2c0904=>{for(const _0x5cebf4 of this['editor']['model']['markers'])_0x2c0904['removeMarker'](_0x5cebf4);});}}function _t(_0x20e09c,_0xdc43a3){return(_0x5a8047,_0x4917ab,_0x55ba9e)=>{if(!_0x55ba9e['consumable']['test'](_0x4917ab['markerRange'],_0x5a8047['name']))return;const _0x5e5b89=_0x4917ab['markerRange']['getWalker'](),_0xe10d38=_0x4917ab['markerRange']['start'],_0x4d4f8e=_0x20e09c['model']['schema'];let _0x4d1c19=null,_0x3274c2=null,_0x44bfff=!0x1,_0x28598c=!0x1;for(const _0x5ee52a of _0x5e5b89){const _0x5a4907=_0x5ee52a['item'];_0x44bfff=_0x44bfff||_0x4d4f8e['isContent'](_0x5a4907);const _0x5b4a5c=_0x55ba9e['mapper']['toViewElement'](_0x5a4907);if(_0x5b4a5c&&_0x5b4a5c['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x5ee52a['type']&&(_0x4d4f8e['isBlock'](_0x5a4907)&&!_0x4d4f8e['isLimit'](_0x5a4907)&&(_0x5a4907['nextSibling']||_0xe10d38['isAtEnd']?_0x4d1c19&&_0x4d1c19['parent']==_0x5a4907||(_0x4d1c19=_0x5a4907,_0x111501(_0x5ee52a['previousPosition']),_0x28598c=!0x0):_0x3274c2=_0x3274c2||_0x5ee52a['previousPosition']));}function _0x111501(_0x11dc9d){const _0xcb99d3=_0x55ba9e['mapper']['toViewPosition'](_0x11dc9d),_0x4a5f01=_0x55ba9e['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0xdc43a3});_0x55ba9e['writer']['insert'](_0xcb99d3,_0x4a5f01),_0x55ba9e['mapper']['bindElementToMarker'](_0x4a5f01,_0x4917ab['markerName']);}_0x44bfff||_0x28598c||!_0x3274c2||_0x111501(_0x3274c2);};}class RestoreRevisionCommand extends _0x2cc57b{constructor(_0x411625){super(_0x411625);const _0x4f4da0=_0x411625['plugins']['get'](RevisionViewer);this['affectsData']=!0x1,this['listenTo'](_0x4f4da0,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x4f4da0,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x46c389=this['editor'],_0x5b9fae=_0x46c389['plugins']['get'](RevisionViewer),_0xaf3e46=_0x5b9fae['isReady']?_0x5b9fae['diff']['newRevisionId']:null;_0x46c389['config']['get']('revisionHistory')['restoreRevisionCallback'](_0xaf3e46);}['refresh'](){const {isReady:_0x5713f5,isEnabled:_0x5903ad,repository:_0x3078fd,diff:_0x559a6f}=this['editor']['plugins']['get'](RevisionViewer),_0x1bdbd5=_0x559a6f&&_0x3078fd['getLaterVisibleRevision'](_0x559a6f['newRevisionId']);this['isEnabled']=_0x5713f5&&_0x5903ad&&Boolean(_0x1bdbd5);}}class ShowChangeCommand extends _0x2cc57b{['_step'];constructor(_0x437fcd,{direction:_0x4dfabc}){super(_0x437fcd);const _0x2280fb=_0x437fcd['plugins']['get'](RevisionViewer);this['affectsData']=!0x1,this['_step']='forward'===_0x4dfabc?0x1:-0x1,this['listenTo'](_0x2280fb,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x2280fb,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x2280fb,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x1cefc4=this['editor'],_0x35f2e4=_0x1cefc4['plugins']['get'](RevisionViewer),{isNavigationMode:_0x63bdec,currentChangeNumber:_0x3c3914}=_0x35f2e4;let _0x2edfcf;if(_0x35f2e4['activeChange']=_0x63bdec?_0x35f2e4['diff']['changes']['get'](_0x3c3914+this['_step']):_0x35f2e4['diff']['changes']['first'],_0x35f2e4['activeChange']['data']['isOnRoot'])_0x2edfcf=_0x1cefc4['editing']['view']['getDomRoot'](_0x35f2e4['activeChange']['rootName']);else{const _0x168013=_0x1cefc4['model']['markers']['get']('revision:'+_0x35f2e4['activeChange']['id']);_0x2edfcf=_0x28ad10(_0x1cefc4['editing'],_0x168013);}_0x387e02({'target':_0x2edfcf,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x4476ee,currentChangeNumber:_0x5bdfdd,numberOfChanges:_0x198ef,isReady:_0xc8fd53,isEnabled:_0xc8fa64}=this['editor']['plugins']['get'](RevisionViewer);this['isEnabled']=!!(_0xc8fa64&&_0xc8fd53&&_0x198ef)&&(!_0x4476ee||(0x1===this['_step']?_0x5bdfdd<_0x198ef-0x1:_0x5bdfdd>0x0));}}class ChangesNavigationView extends _0x6b0c43{constructor(_0x453ea8){super(_0x453ea8);const _0x510bf0=this['bindTemplate'],_0x4f5970=new _0x8647ff(_0x453ea8),_0x3b9837=new _0x8647ff(_0x453ea8);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',(_0x52c76c,_0x6d0a63)=>_0x52c76c&&_0x6d0a63>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x40e51f,_0x3a48c1,_0x584785,_0x50fd66)=>{if(!_0x40e51f)return ft(_0x453ea8,'Loading...');if(!_0x584785)return ft(_0x453ea8,'No\x20changes');const _0x25cdaa=ft(_0x453ea8,'NUMBER_OF_CHANGES',_0x584785);return _0x50fd66?ft(_0x453ea8,'X_OF_Y_CHANGES',[_0x3a48c1+0x1,_0x584785]):_0x25cdaa;}),_0x4f5970['set']({'label':ft(_0x453ea8,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x3bea5a}),_0x3b9837['set']({'label':ft(_0x453ea8,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x32087f}),_0x4f5970['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x3b9837['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x4f5970['on']('execute',()=>this['fire']('execute','backward')),_0x3b9837['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',_0x510bf0['if']('_isStatusLabelVisible','ck-hidden',_0x14cb2f=>!_0x14cb2f)]},'children':[{'text':_0x510bf0['to']('isNavigationMode',_0x471acc=>_0x471acc?ft(_0x453ea8,'EDIT_X_OF_Y_REVISIONS')+':\x20':ft(_0x453ea8,'Total')+':\x20')}]},{'text':_0x510bf0['to']('_statusText')}]},new st(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x4f5970,_0x3b9837]}]});}}const yt='ck-editor__editable__loading-overlay';class RevisionViewerLoadingOverlay extends _0x3b8836{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x34d756=this['editor']['editing']['view'];_0x34d756['change'](_0xd67f7b=>{for(const _0x206428 of _0x34d756['document']['roots'])_0xd67f7b['addClass'](yt,_0x206428);});}['hide'](){const _0x435976=this['editor']['editing']['view'];_0x435976['change'](_0x2e26c1=>{for(const _0x4be4bc of _0x435976['document']['roots'])_0x2e26c1['removeClass'](yt,_0x4be4bc);});}}class RevisionViewerUI extends _0x3b8836{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[RevisionViewer,RevisionViewerLoadingOverlay];}['init'](){const _0x374879=this['editor'],_0x429e2d=_0x374879['plugins']['get'](RevisionViewer),_0x5226bc=_0x374879['plugins']['get'](RevisionViewerLoadingOverlay);_0x374879['ui']['componentFactory']['add']('exitToEditing',_0x130997=>{const _0x492128=new _0x8647ff(_0x130997);return _0x492128['set']({'label':ft(_0x130997,'Back\x20to\x20editing'),'icon':_0x5065e8,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x492128,'execute',()=>{_0x374879['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x492128;}),_0x374879['ui']['componentFactory']['add']('restoreRevision',_0x4ff1b0=>{const _0x299c0e=new _0x8647ff(_0x4ff1b0);return _0x299c0e['set']({'label':ft(_0x4ff1b0,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x299c0e['bind']('isEnabled')['to'](_0x374879['commands']['get']('restoreRevision')),this['listenTo'](_0x299c0e,'execute',()=>_0x374879['execute']('restoreRevision')),_0x299c0e;}),_0x374879['ui']['componentFactory']['add']('changesNavigation',_0xe919c8=>{const _0x2600f4=new ChangesNavigationView(_0xe919c8),_0x399497=_0x374879['commands']['get']('showPreviousChange'),_0x53bc1d=_0x374879['commands']['get']('showNextChange');return _0x2600f4['bind']('isBackwardNavigationEnabled')['to'](_0x399497,'isEnabled'),_0x2600f4['bind']('isForwardNavigationEnabled')['to'](_0x53bc1d,'isEnabled'),_0x2600f4['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x429e2d),this['listenTo'](_0x2600f4,'execute',(_0x16d42e,_0x52229e)=>{_0x374879['execute']('forward'===_0x52229e?'showNextChange':'showPreviousChange');}),_0x2600f4;}),_0x5226bc['show'](),_0x429e2d['on']('change:isReady',(_0x101f91,_0x524ec1,_0x505b26)=>{_0x505b26?_0x5226bc['hide']():_0x5226bc['show']();});}}class RevisionNameView extends _0x7cd47d{['_resizeObserver']=null;constructor(_0x3f0e16,_0x8bbfa){super(_0x3f0e16,_0x8bbfa);const _0x12d39c=this['bindTemplate'];this['set']({'label':ft(_0x3f0e16,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=ft(_0x3f0e16,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x12d39c['to']('_tooltipString'),'data-cke-tooltip-position':'s','data-cke-tooltip-class':'ck-tooltip_multi-line'}});}['render'](){super['render'](),this['_resizeObserver']=new _0x1a3a9e(this['fieldView']['element'],()=>this['_updateTooltipText']()),this['listenTo'](this['fieldView'],'input',()=>this['_updateTooltipText']());}['destroy'](){super['destroy'](),this['_resizeObserver']&&this['_resizeObserver']['destroy']();}['_updateTooltipText'](){const _0x5f4bc0=this['fieldView']['element'];this['_tooltipString']=_0x5f4bc0['scrollWidth']>_0x5f4bc0['clientWidth']&&_0x5f4bc0['value']||'';}}class RevisionAuthorView extends _0x6b0c43{constructor(_0x598767,_0x9ac6ca,_0x517311){super(_0x598767);const _0x5e4cb4=new nt();_0x5e4cb4['set']({'content':_0x2f3753,'viewBox':'0\x200\x2011\x2010'});const _0x4e6f78=['ck','ck-revision-history-sidebar__revision-author'];_0x517311&&_0x4e6f78['push']('ck-revision-history-sidebar__revision-author_creator');const _0xa7bd7a=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':ft(_0x598767,_0x517311?'Revision\x20creator':'Revision\x20author')},'children':[_0x5e4cb4,_0x9ac6ca['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x4e6f78},'children':_0xa7bd7a});}}function Rt(_0x15612b,_0x4f3e74){const _0x55edac=_0x15612b['bindTemplate'],_0x512625=_0x15612b['locale'],_0x4553a7=_0xcc940(_0x512625);_0x4553a7['panelPosition']='sw';const _0x26d788=function(_0x26e2a5,_0x359774){const _0x72ed7d=function(_0x53d8b1,_0x265985){const _0x55a9ba=_0x53d8b1['locale'],_0x3d8dd9={'Compare\x20against\x20selected':ft(_0x55a9ba,'Compare\x20against\x20selected'),'Name\x20this\x20revision':ft(_0x55a9ba,'Name\x20this\x20revision'),'Restore\x20this\x20revision':ft(_0x55a9ba,'Restore\x20this\x20revision')};return _0x265985['map'](_0x4e92cb=>{const _0x5cb1d9=_0x3d8dd9[_0x4e92cb['name']];return _0x5cb1d9&&_0x5cb1d9!==_0x4e92cb['name']&&(_0x4e92cb['name']=_0x5cb1d9),_0x4e92cb;});}(_0x26e2a5,_0x359774),_0x4e93e2=new _0xe9e71e();for(const _0x14e34f of _0x72ed7d){const _0x1a461b={'type':'button','model':new rt({'label':_0x14e34f['name'],'class':_0x14e34f['class'],'withText':!0x0,'role':'menuitem','_action':_0x14e34f['action']})};_0x1a461b['model']['bind']('isEnabled')['to'](_0x26e2a5,'isActionsDropdownOpen',_0xd842f=>'function'!=typeof _0x14e34f['isEnabled']||(!_0xd842f||_0x14e34f['isEnabled'](_0x26e2a5))),_0x4e93e2['add'](_0x1a461b);}return _0x4e93e2;}(_0x15612b,_0x4f3e74);return _0x15612b['bind']('isActionsDropdownOpen')['to'](_0x4553a7,'isOpen'),_0x4553a7['buttonView']['set']({'label':ft(_0x512625,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x3ed45e}),_0x4553a7['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x55edac['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x55edac['to'](_0x3854c8=>_0x3854c8['stopPropagation']())}}),_0x4553a7['on']('execute',_0x58bf17=>{_0x15612b['isReady']&&'function'==typeof _0x58bf17['source']['_action']&&_0x58bf17['source']['_action'](_0x15612b);}),ot(_0x4553a7,_0x26d788,{'role':'menu'}),_0x4553a7['listenTo'](_0x15612b,'change:isActionsDropdownOpen',(_0x40b7a0,_0x36e4dd,_0x2e68a0)=>{if(_0x2e68a0)for(const _0x34e351 of _0x4553a7['listView']['items']){const _0x1ed540=_0x34e351['children']['first'],_0x255514=_0x4f3e74['find'](_0x3b3f8b=>_0x3b3f8b['action']===_0x1ed540['_action'])['isVisible'];_0x34e351['isVisible']=void 0x0===_0x255514||_0x255514(_0x15612b);}}),_0x4553a7;}class RevisionView extends/* #__PURE__ -- @preserve */
27
+ _0x37afc1(_0x6b0c43){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x1d7df8,_0x579f03,_0x402318,_0x4d6089){super(_0x1d7df8);const _0x23f764=this['bindTemplate'],_0xc70908=function(_0x39f8fb,_0xdf6d9a){const _0x44e4bc=Array['from'](_0xdf6d9a['authors'])['filter'](_0x20305b=>_0x20305b!=_0xdf6d9a['creator']);return _0xdf6d9a['creator']&&_0x44e4bc['unshift'](_0xdf6d9a['creator']),_0x44e4bc['map'](_0xf67fc=>new RevisionAuthorView(_0x39f8fb,_0xf67fc,_0xf67fc==_0xdf6d9a['creator']));}(_0x1d7df8,_0x579f03);this['id']=_0x579f03['id'],this['_revision']=_0x579f03,this['_requireRevisionName']=_0x4d6089,this['bind']('name','createdAt')['to'](_0x579f03),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x475d77=>{return _0x429c5b=_0x1d7df8['uiLanguage'],(_0x780d51=_0x475d77)['toLocaleDateString'](_0x429c5b,{'month':'long','day':'numeric'})+',\x20'+_0x780d51['toLocaleTimeString'](_0x429c5b,{'hour':'numeric','minute':'numeric'});var _0x429c5b,_0x780d51;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new RevisionNameView(_0x1d7df8,_0x1fb48d),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x429c43=>_0x429c43||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x30860c,_0x48531d)=>_0x30860c&&_0x48531d),this['revisionActionsView']=_0x402318&&_0x402318['length']?Rt(this,_0x402318):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x23f764['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x23f764['if']('isEnabled','ck-disabled',_0x29744d=>!_0x29744d),_0x23f764['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x23f764['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x23f764['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':_0x23f764['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':_0xc70908}]},this['revisionActionsView']],'on':{'click':_0x23f764['to'](_0x12d631=>{_0x12d631['srcElement']['closest']('.ck-confirm-view')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x1f7879=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x1f7879,'change',()=>{this['_requireRevisionName']&&!_0x1f7879['value']||this['fire']('setName',{'id':this['id'],'name':_0x1f7879['value']}),_0x1f7879['value']||(_0x1f7879['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(_0x4f0ecc,_0x35cbe1){const _0x33ba67=vt['fromJSDate'](_0x4f0ecc)['setLocale'](_0x35cbe1),_0x885993=vt['local'](),_0x1954b9=_0x885993['minus']({'days':0x1})['startOf']('day');let _0x8813ee,_0x1597ca;return _0x33ba67['hasSame'](_0x885993,'day')?(_0x8813ee=_0x33ba67['startOf']('day')['toJSDate'](),_0x1597ca=_0x33ba67['toRelativeCalendar']()):_0x33ba67['hasSame'](_0x1954b9,'day')?(_0x8813ee=_0x1954b9['toJSDate'](),_0x1597ca=_0x33ba67['toRelativeCalendar']()):_0x33ba67['hasSame'](_0x885993,'week')?(_0x8813ee=_0x33ba67['startOf']('week')['toJSDate'](),_0x1597ca=_0x33ba67['weekdayLong']||''):_0x33ba67['hasSame'](_0x885993,'year')?(_0x8813ee=_0x33ba67['startOf']('month')['toJSDate'](),_0x1597ca=_0x33ba67['monthLong']||''):(_0x8813ee=_0x33ba67['startOf']('year')['toJSDate'](),_0x1597ca=String(_0x33ba67['year'])),{'startDate':_0x8813ee,'localizedPeriodName':_0x1597ca};}class RevisionsSidebarTimePeriodView extends _0x6b0c43{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x1859d2,_0x1564c1,_0x91673b,_0xb89280){super(_0x1859d2);const _0x4165ed=bt(_0x1564c1,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x1564c1,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x91673b,this['_requireRevisionName']=_0xb89280,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':_0x4165ed}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x50b2d3){const _0xa56ea3=new RevisionView(this['locale'],_0x50b2d3,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0xa56ea3);}['removeRevision'](_0x576ae8){const _0x10ee2a=this['revisionViews']['find'](_0x49180f=>_0x49180f['id']===_0x576ae8['id']);this['revisionViews']['remove'](_0x10ee2a);}}class RevisionsSidebarHeaderView extends _0x6b0c43{constructor(_0xfa4a6){super(_0xfa4a6);const _0x31cc40=new nt();_0x31cc40['content']=_0x184ecc,this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x31cc40,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[ft(_0xfa4a6,'Revision\x20history')]}]});}}class RevisionsSidebarView extends _0x6b0c43{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x2bf7db,_0x524061,_0x10b0ef,_0x39e918){super(_0x2bf7db);const _0x29554a=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x524061,this['_revisionActions']=_0x10b0ef,this['_requireRevisionName']=_0x39e918,this['on']('select',(_0x2aee06,_0x35b261)=>{this['fire']('revisionSelected',_0x35b261);}),this['on']('setName',(_0x222de8,_0x8f8a03)=>{this['fire']('revisionSetName',_0x8f8a03);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new RevisionsSidebarHeaderView(_0x2bf7db),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x29554a['if']('isEnabled','ck-disabled',_0xf4d273=>!_0xf4d273)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x189296 of this['_revisions'])this['_addRevision'](_0x189296);this['_revisions']['on']('add',(_0x299755,_0x43d4c8)=>{this['_addRevision'](_0x43d4c8);}),this['_revisions']['on']('remove',(_0x50a2bf,_0x33e267)=>{this['_removeRevision'](_0x33e267);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x2610e3=>_0x2610e3['revisionViews']['map'](_0x567bb7=>_0x567bb7))['flat']();}['selectRevision'](_0x15678f){for(const _0x5f2640 of this['revisionViews'])_0x15678f&&_0x15678f['id']===_0x5f2640['id']?_0x5f2640['select']():_0x5f2640['deselect']();}['highlightRevisions'](_0x4d8a99){for(const _0x5782af of this['revisionViews'])_0x4d8a99['some'](({id:_0x3cbbc5})=>_0x3cbbc5===_0x5782af['id'])?_0x5782af['highlight']():_0x5782af['unhighlight']();}['_addRevision'](_0x25c7de){const _0x58a6c6=bt(_0x25c7de['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x4f843d=this['_getTimePeriodViewByStartDate'](_0x58a6c6);_0x4f843d||(_0x4f843d=new RevisionsSidebarTimePeriodView(this['locale'],_0x58a6c6,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x4f843d)),_0x4f843d['addRevision'](_0x25c7de);}['_removeRevision'](_0x179359){const _0x5a67c5=bt(_0x179359['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x5a67c5)['removeRevision'](_0x179359);}['_getTimePeriodViewByStartDate'](_0x19853f){return this['timePeriodViews']['find'](_0x5a9ba2=>_0x5a9ba2['startDate']['getTime']()===_0x19853f['getTime']());}}class RevisionsSidebar extends _0x3b8836{['_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(_0x123b54){super(_0x123b54),this['_revisionViewer']=_0x123b54['plugins']['get'](RevisionViewer),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x1dbe9a=this['_revisionsRepository']['_revisions'],_0x42081e=this['_createRevisionActions'](),_0x1d0974=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new RevisionsSidebarView(this['editor']['locale'],_0x1dbe9a,_0x42081e,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',(_0x322985,_0xbf876)=>{_0xbf876['revisionViews']['on']('add',(_0x2f134c,_0x107b11)=>{_0x107b11['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)),_0x1d0974['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x112334=this['_revisionsRepository']['getRevision'](0x0);if(_0x112334){const _0x2ab9da=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x112334['id']);this['_revisionViewer']['compare'](_0x112334,_0x2ab9da);}}['_handleRevisionSelected'](_0x3f010,_0x42f6e7){const _0x95f22f=this['_revisionsRepository']['getRevision'](_0x42f6e7['id']),_0x4b98d8=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x95f22f['id']);this['_revisionViewer']['compare'](_0x95f22f,_0x4b98d8);}['_handleRevisionSetName'](_0x2fbe23,_0x56ae4c){this['_revisionsRepository']['getRevision'](_0x56ae4c['id'])['setName'](_0x56ae4c['name']);}['_handleDiffChange'](_0x5a7aee,_0x1b648e,_0x23e7ba){const _0x1415d5=this['_revisionsRepository']['getRevisionsInDiff'](_0x23e7ba);_0x1415d5['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x1415d5),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x1415d5[0x0]));}['_createRevisionActions'](){const _0x537507=this['editor'],_0xa0e41a=RevisionsSidebar['availableRevisionActions'],_0x19a92e=_0x537507['config']['get']('revisionHistory.revisionActions')||RevisionsSidebar['defaultRevisionActions'];if(_0x19a92e['length'])return _0x19a92e['map'](_0x245aee=>{const _0xc74ebf='string'==typeof _0x245aee?Object['assign']({},_0xa0e41a[_0x245aee]):_0x245aee;return _0xc74ebf['action']=_0xc74ebf['action']['bind'](this,_0x537507),_0xc74ebf['isVisible']&&(_0xc74ebf['isVisible']=_0xc74ebf['isVisible']['bind'](this,_0x537507)),_0xc74ebf;});}}function kt(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x167a35},_0x3f4947)=>{const _0x130aba=_0x167a35['get'](RevisionViewer),_0x3ee0fc=_0x130aba['repository'];let _0xa0f5c7=_0x130aba['diff']['newRevisionId'],_0x3abff7=_0x3f4947['id'];_0x3ee0fc['getIndex'](_0xa0f5c7)>_0x3ee0fc['getIndex'](_0x3abff7)&&([_0xa0f5c7,_0x3abff7]=[_0x3abff7,_0xa0f5c7]),_0x130aba['compare'](_0xa0f5c7,_0x3abff7);},'isVisible':({plugins:_0x140d64},_0x524f29)=>{const _0x488cb2=_0x140d64['get'](RevisionViewer);return!(_0x488cb2['repository']['getRevisionsInDiff'](_0x488cb2['diff'])['length']>0x2)&&!_0x524f29['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x12a41a,{id:_0x4ea981})=>{_0x12a41a['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x4ea981);},'isVisible':({plugins:_0x34bfca},_0x77480f)=>!!_0x34bfca['get'](RevisionViewer)['repository']['getLaterVisibleRevision'](_0x77480f['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x4bbd88},{id:_0x32a386,revisionNameView:_0x57e199})=>{const _0x1a8ef3=_0x4bbd88['get'](RevisionViewer),_0x11318a=_0x1a8ef3['repository']['getEarlierVisibleRevision'](_0x32a386);_0x1a8ef3['compare'](_0x32a386,_0x11318a),_0x57e199['focus'](),_0x57e199['fieldView']['select']();}}};}class RevisionViewerEditorUI extends at{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x1f5e2a,_0x24eb67){super(_0x1f5e2a),this['_view']=_0x24eb67,this['_toolbarConfig']=ht(_0x1f5e2a['config']['get']('toolbar')),this['_elementReplacer']=new _0x1e439a();}get['element'](){return this['view']['element'];}['init'](_0x5aaf0a){const _0x310d1d=this['editor'],_0x787ab6=this['view'],_0x581a82=_0x310d1d['editing']['view'],_0x5c13a2=_0x787ab6['editable'],_0x1ccb6e=_0x581a82['document']['getRoot']();_0x5c13a2['name']=_0x1ccb6e['rootName'],_0x787ab6['render']();const _0x67a23e=_0x5c13a2['element'];this['setEditableElement'](_0x5c13a2['name'],_0x67a23e),_0x787ab6['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x581a82['attachDomRoot'](_0x67a23e),this['_elementReplacer']['replace'](_0x5aaf0a,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x27797a=this['view'],_0x517361=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x517361['detachDomRoot'](_0x27797a['editable']['name']),_0x27797a['destroy']();}['_initToolbar'](){const _0x2960b7=this['view'];_0x2960b7['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x2960b7['stickyPanel']['limiterElement']=_0x2960b7['element'],_0x2960b7['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x3a028c})=>_0x3a028c),_0x2960b7['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x2960b7['toolbar']);}}class RevisionViewerEditorUIView extends ct{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x554e29,_0x51f844,_0x3459f3={}){super(_0x554e29),this['stickyPanel']=new lt(_0x554e29),this['toolbar']=new ut(_0x554e29,{'shouldGroupWhenFull':_0x3459f3['shouldToolbarGroupWhenFull']}),this['_editable']=new dt(_0x554e29,_0x51f844);}['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
- _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(_0x52fed5){super(_0x52fed5),this['_revisionViewer']=_0x52fed5['plugins']['get'](RevisionViewer),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x2fa601=this['_revisionsRepository']['_revisions'],_0x27ad72=this['_createRevisionActions'](),_0x8c8200=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new RevisionsSidebarView(this['editor']['locale'],_0x2fa601,_0x27ad72,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',(_0x11d421,_0x1ebfca)=>{_0x1ebfca['revisionViews']['on']('add',(_0x182cf2,_0x4ed3f7)=>{_0x4ed3f7['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)),_0x8c8200['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x5b5390=this['_revisionsRepository']['getRevision'](0x0);if(_0x5b5390){const _0x5ccf76=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x5b5390['id']);this['_revisionViewer']['compare'](_0x5b5390,_0x5ccf76);}}['_handleRevisionSelected'](_0x33fd16,_0xc7f9){const _0x30441f=this['_revisionsRepository']['getRevision'](_0xc7f9['id']),_0x28b450=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x30441f['id']);this['_revisionViewer']['compare'](_0x30441f,_0x28b450);}['_handleRevisionSetName'](_0x5e626a,_0x38e34c){this['_revisionsRepository']['getRevision'](_0x38e34c['id'])['setName'](_0x38e34c['name']);}['_handleDiffChange'](_0x2121bc,_0x280a19,_0x291851){const _0x236367=this['_revisionsRepository']['getRevisionsInDiff'](_0x291851);_0x236367['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x236367),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x236367[0x0]));}['_createRevisionActions'](){const _0x3fbc78=this['editor'],_0x447e89=RevisionsSidebar['availableRevisionActions'],_0x5db38e=_0x3fbc78['config']['get']('revisionHistory.revisionActions')||RevisionsSidebar['defaultRevisionActions'];if(_0x5db38e['length'])return _0x5db38e['map'](_0x23a364=>{const _0x3e6d4b='string'==typeof _0x23a364?Object['assign']({},_0x447e89[_0x23a364]):_0x23a364;return _0x3e6d4b['action']=_0x3e6d4b['action']['bind'](this,_0x3fbc78),_0x3e6d4b['isVisible']&&(_0x3e6d4b['isVisible']=_0x3e6d4b['isVisible']['bind'](this,_0x3fbc78)),_0x3e6d4b;});}}function kt(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x95cdb},_0x47146f)=>{const _0x158baa=_0x95cdb['get'](RevisionViewer),_0xf8ce4f=_0x158baa['repository'];let _0x279be7=_0x158baa['diff']['newRevisionId'],_0x5998ea=_0x47146f['id'];_0xf8ce4f['getIndex'](_0x279be7)>_0xf8ce4f['getIndex'](_0x5998ea)&&([_0x279be7,_0x5998ea]=[_0x5998ea,_0x279be7]),_0x158baa['compare'](_0x279be7,_0x5998ea);},'isVisible':({plugins:_0x20ea1e},_0x401382)=>{const _0x4c56ed=_0x20ea1e['get'](RevisionViewer);return!(_0x4c56ed['repository']['getRevisionsInDiff'](_0x4c56ed['diff'])['length']>0x2)&&!_0x401382['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x5f3d02,{id:_0x101e49})=>{_0x5f3d02['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x101e49);},'isVisible':({plugins:_0x47ce4a},_0x4a5bce)=>!!_0x47ce4a['get'](RevisionViewer)['repository']['getLaterVisibleRevision'](_0x4a5bce['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0xf39c88},{id:_0x5927dc,revisionNameView:_0xdb92f4})=>{const _0x3bfab4=_0xf39c88['get'](RevisionViewer),_0x4268be=_0x3bfab4['repository']['getEarlierVisibleRevision'](_0x5927dc);_0x3bfab4['compare'](_0x5927dc,_0x4268be),_0xdb92f4['focus'](),_0xdb92f4['fieldView']['select']();}}};}class RevisionViewerEditorUI extends at{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x429798,_0x3b7966){super(_0x429798),this['_view']=_0x3b7966,this['_toolbarConfig']=ht(_0x429798['config']['get']('toolbar')),this['_elementReplacer']=new _0x1d2c7d();}get['element'](){return this['view']['element'];}['init'](_0x554d4f){const _0x3066f5=this['editor'],_0x347e20=this['view'],_0x3d95c9=_0x3066f5['editing']['view'],_0x58ce61=_0x347e20['editable'],_0x189eb7=_0x3d95c9['document']['getRoot']();_0x58ce61['name']=_0x189eb7['rootName'],_0x347e20['render']();const _0x454d5a=_0x58ce61['element'];this['setEditableElement'](_0x58ce61['name'],_0x454d5a),_0x347e20['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x3d95c9['attachDomRoot'](_0x454d5a),this['_elementReplacer']['replace'](_0x554d4f,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x3cf4fe=this['view'],_0x16313c=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x16313c['detachDomRoot'](_0x3cf4fe['editable']['name']),_0x3cf4fe['destroy']();}['_initToolbar'](){const _0x5b5502=this['view'];_0x5b5502['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x5b5502['stickyPanel']['limiterElement']=_0x5b5502['element'],_0x5b5502['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x348ffe})=>_0x348ffe),_0x5b5502['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x5b5502['toolbar']);}}class RevisionViewerEditorUIView extends ct{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x152e03,_0x55ceda,_0x308100={}){super(_0x152e03),this['stickyPanel']=new lt(_0x152e03),this['toolbar']=new ut(_0x152e03,{'shouldGroupWhenFull':_0x308100['shouldToolbarGroupWhenFull']}),this['_editable']=new dt(_0x152e03,_0x55ceda);}['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
+ _0x5dad88(_0x305000){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x55d662,_0x29c893){super(_0x29c893),this['sourceElement']=_0x55d662,this['model']['document']['createRoot']();const _0x510ca3=new RevisionViewerEditorUIView(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new RevisionViewerEditorUI(this,_0x510ca3);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x96edd3,_0x21cc1c){const _0x17d4be=new this(_0x96edd3,_0x21cc1c);return await _0x17d4be['initPlugins'](),await _0x17d4be['ui']['init'](_0x96edd3),await _0x17d4be['data']['init'](_0x17d4be['config']['get']('initialData')||''),_0x17d4be['fire']('ready'),_0x17d4be;}}const It=['RevisionHistoryUI','RestrictedEditingMode','AIChat','AIReviewMode','AIBalloon','AIQuickActions','AIActions','AIChatShortcuts','AITranslate'];class RevisionViewerIntegration extends _0x3b8836{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x2c2539){function _0x324207(_0x452fe6){return _0x452fe6['map'](_0xceec89=>String['fromCharCode'](_0xceec89))['join']('');}super(_0x2c2539),this['result']='end',_0x2c2539[_0x324207([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x324207([0x76,0x69,0x65,0x77])][_0x324207([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x324207([0x61,0x75,0x74,0x6f]),_0x2c2539[_0x324207([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x324207([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x324207([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x324207([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x324207([0x6f,0x6b])});}}class RevisionHistory extends _0x3b8836{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[RevisionTracker,RevisionHistoryUI];}constructor(_0x19aee1){if(super(_0x19aee1),!this['editor']['config']['get']('revisionHistory'))throw new _0x5107d5('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x597a1a=>this['_showRevisionViewer']({..._0x597a1a,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x20046c=>this['_closeRevisionViewer'](_0x20046c)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x3d48a9=>this['_restoreRevision'](_0x3d48a9)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x3dbf1b){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x3dbf1b;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x1837c1){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x1837c1);}['getRevision'](_0x7f5545){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x7f5545);}['getRevisions'](_0x211e4c){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x211e4c||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x57e641=this['editor'],_0x10e622=_0x4d94e7(_0x57e641,It),_0x526a81=_0x57e641['plugins']['get']('RevisionTracker'),_0x4c13cf=_0x57e641['plugins']['get'](_0x51d413)['users'];return _0x10e622['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x10e622['lazyRoots'],(_0x10e622['plugins']['push'](RevisionViewerIntegration,RevisionViewer,RevisionViewerUI,class RevisionViewerInit extends _0x3b8836{static get['requires'](){return[RevisionViewer,_0x51d413];}['init'](){const _0x4b4443=this['editor']['plugins']['get'](_0x51d413);for(const _0x2f1ab1 of _0x4c13cf)_0x2f1ab1['isAnonymous']||_0x4b4443['getUser'](_0x2f1ab1['id'])||_0x4b4443['addUser'](_0x2f1ab1);const _0x5e5f0c=_0x526a81['repository']['getRevisions']();let _0x1e0b7a=null;const _0x184cd8=this['editor']['plugins']['get']('RevisionViewer');_0x184cd8['adapter']=_0x526a81['adapter'],_0x184cd8['bind']('isEnabled')['to'](_0x526a81),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x57e641,'isReadOnly',_0x48b063=>!_0x48b063);for(const _0x492f2a of _0x5e5f0c){const _0x313509=null===_0x492f2a['creator'];if(_0x313509&&_0x492f2a['toVersion']===_0x492f2a['fromVersion'])continue;const _0x2f54ef=_0x492f2a['toJSON']();_0x184cd8['addRevisionData'](_0x2f54ef,(_0x51e2e0,_0x2bc932,_0x1854a8)=>{if(_0x313509){if(_0x1e0b7a)_0x1e0b7a['_update'](_0x51e2e0,_0x2bc932);else{if(!_0x2bc932){const _0x1b1e7b=_0x1854a8['toJSON']();_0x1b1e7b['id']=_0x439976(),_0x526a81['saveRevision'](_0x1b1e7b,_0x1854a8['toVersion'])['then'](_0x579c84=>{_0x1e0b7a=_0x579c84;});}}}else _0x492f2a['_update'](_0x51e2e0,_0x2bc932);});}}},RevisionsSidebar),_0x10e622);}['_enhanceShowRevisionViewerCallback'](){const _0x5a7743=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0xd23f52=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x49a1eb=this['editor']['plugins']['get']('Autosave');await _0x49a1eb['save']();}else await _0xd23f52['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x15f620=this['editor']['plugins']['get']('Dialog');_0x15f620['isOpen']&&_0x15f620['hide']();}if(this['editor']['plugins']['has']('AITabs')){const _0x439da6=this['editor']['plugins']['get']('AITabs')['view']['panelViews'];for(const _0xf332c5 of _0x439da6)_0xf332c5['class']=_0xf332c5['class']?_0xf332c5['class']+'\x20ck-tab-panel_disabled':'ck-tab-panel_disabled';if(this['editor']['plugins']['has']('AIChat')){const _0x3ee202=document['querySelector']('.ck-ai-chat__prompt-input\x20.ck-textarea');_0x3ee202&&_0x3ee202['setAttribute']('tabindex','-1');}if(this['editor']['plugins']['has']('AIChatHistory')){const _0x3d2127=document['querySelector']('.ck-ai-chat-history\x20.ck-input');_0x3d2127&&_0x3d2127['setAttribute']('tabindex','-1');}}const _0x534e88=this['_getRevisionViewerEditorConfig']();return _0x5a7743(_0x534e88)['then'](_0x24f063=>{return(this['_viewerEditor']=_0x24f063,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'),_0x24f063);})['catch'](_0x4b6ec3=>(console['error'](_0x4b6ec3),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x404e91=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 _0x54cda3=this['editor']['plugins']['get']('AITabs')['view']['panelViews'];for(const _0x1d1a40 of _0x54cda3)_0x1d1a40['class']='ck-tab-panel_disabled'===_0x1d1a40['class']?'':_0x1d1a40['class']['replace']('\x20ck-tab-panel_disabled','');if(this['editor']['plugins']['has']('AIChat')){const _0x112437=document['querySelector']('.ck-ai-chat__prompt-input\x20.ck-textarea');_0x112437&&_0x112437['removeAttribute']('tabindex');}if(this['editor']['plugins']['has']('AIChatHistory')){const _0x1470fd=document['querySelector']('.ck-ai-chat-history\x20.ck-input');_0x1470fd&&_0x1470fd['removeAttribute']('tabindex');}}return this['_viewerEditor']['plugins']['get']('RevisionViewer')['_cleanUp'](),_0x404e91(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x22e8fc=this['editor']['plugins']['get']('Annotations');_0x22e8fc['refreshVisibility'](),_0x22e8fc['refreshPositioning']();}});});}['_showRevisionViewer'](_0x3bc891){const _0x2ffdfa=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x55865d=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x2b287a=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return RevisionViewerEditor['create'](_0x2b287a,_0x3bc891)['then'](_0x5514f8=>(_0x55865d['style']['display']='block',_0x2ffdfa['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x5514f8));}['_closeRevisionViewer'](_0x4a0dc8){const _0x3a03b5=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x3a03b5['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x4a0dc8['destroy']();}async['_restoreRevision'](_0x122e5b){const _0x5dc9cf=this['editor'],_0x13696b=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x158df2=_0x5dc9cf['plugins']['get']('RevisionTracker'),_0xb55d71=_0x5dc9cf['plugins']['get']('RevisionHistoryUtils'),_0x1b0176=_0x13696b['repository']['getRevision'](_0x122e5b);let _0x5194f3,_0x52e966,_0x87d329;try{await _0xb55d71['loadRevisionData'](_0x1b0176,this['adapter']),_0x5194f3=_0xb55d71['getRevisionDocumentData'](_0x1b0176),_0x52e966=_0xb55d71['getRevisionRootsAttributes'](_0x1b0176);}catch(_0x5507e1){return void console['error'](_0x5507e1);}_0x5dc9cf['model']['change'](_0xe089c6=>{for(const _0x5fac62 of Array['from'](_0x5dc9cf['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0xe089c6['removeMarker'](_0x5fac62);}),_0x13696b['isReady']=!0x1,_0x5dc9cf['model']['enqueueChange'](_0x120bb6=>{_0x120bb6['setSelection'](null),_0x120bb6['removeSelectionAttribute'](_0x5dc9cf['model']['document']['selection']['getAttributeKeys']());const _0x575d52=Object['keys'](_0x5194f3);for(const _0x51fa1 of _0x5dc9cf['model']['document']['roots'])'$graveyard'!=_0x51fa1['rootName']&&_0x51fa1['isAttached']()&&!_0x575d52['includes'](_0x51fa1['rootName'])&&_0x120bb6['detachRoot'](_0x51fa1);for(const _0x2ce684 of _0x575d52){let _0x47fcba=_0x5dc9cf['model']['document']['getRoot'](_0x2ce684);if(!_0x47fcba||!_0x47fcba['isAttached']()){const _0x4ea2a7=_0x1b0176['diffData']?.[_0x2ce684]?.['rootElementName']||'$root';_0x47fcba=_0x120bb6['addRoot'](_0x2ce684,_0x4ea2a7);}const _0xed7c4c=_0x52e966[_0x2ce684],_0x143221=Object['keys'](_0xed7c4c),_0x57ff82=_0x5194f3[_0x2ce684];for(const _0x743e0f of _0x47fcba['getAttributeKeys']())_0x143221['includes'](_0x743e0f)||_0x120bb6['removeAttribute'](_0x743e0f,_0x47fcba);for(const _0x4b2346 of _0x143221)_0x120bb6['setAttribute'](_0x4b2346,_0x52e966[_0x2ce684][_0x4b2346],_0x47fcba);_0x120bb6['remove'](_0x120bb6['createRangeIn'](_0x47fcba)),_0x120bb6['insert'](_0x5dc9cf['data']['parse'](_0x57ff82,_0x47fcba),_0x47fcba,0x0);}});const _0x41fca1=ft(_0x5dc9cf['locale'],'Restored');if(_0x1b0176['name'])_0x87d329=-0x1==_0x1b0176['name']['indexOf'](_0x41fca1)?_0x41fca1+':\x20'+_0x1b0176['name']:_0x1b0176['name'];else _0x87d329=_0x41fca1+':\x20'+(_0x1b0176['createdAt']['toLocaleDateString'](_0x5dc9cf['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x1b0176['createdAt']['toLocaleTimeString'](_0x5dc9cf['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x158df2['saveRevision']({'name':_0x87d329}),_0x13696b['isReady']=!0x0,_0x5dc9cf['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{RestoreRevisionCommand,Revision,RevisionHistory,RevisionHistoryUI,RevisionHistoryUtils,RevisionTracker,RevisionViewer,RevisionViewerEditor,RevisionViewerIntegration,RevisionViewerLoadingOverlay,RevisionViewerUI,RevisionsRepository,RevisionsSidebar,ShowChangeCommand};