@ckeditor/ckeditor5-revision-history 47.7.2 → 47.7.3

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 (180) hide show
  1. package/build/revision-history.js +1 -1
  2. package/dist/index.js +7 -7
  3. package/dist/translations/af.js +1 -1
  4. package/dist/translations/af.umd.js +1 -1
  5. package/dist/translations/ar.js +1 -1
  6. package/dist/translations/ar.umd.js +1 -1
  7. package/dist/translations/ast.js +1 -1
  8. package/dist/translations/ast.umd.js +1 -1
  9. package/dist/translations/az.js +1 -1
  10. package/dist/translations/az.umd.js +1 -1
  11. package/dist/translations/be.js +1 -1
  12. package/dist/translations/be.umd.js +1 -1
  13. package/dist/translations/bg.js +1 -1
  14. package/dist/translations/bg.umd.js +1 -1
  15. package/dist/translations/bn.js +1 -1
  16. package/dist/translations/bn.umd.js +1 -1
  17. package/dist/translations/bs.js +1 -1
  18. package/dist/translations/bs.umd.js +1 -1
  19. package/dist/translations/ca.js +1 -1
  20. package/dist/translations/ca.umd.js +1 -1
  21. package/dist/translations/cs.js +1 -1
  22. package/dist/translations/cs.umd.js +1 -1
  23. package/dist/translations/da.js +1 -1
  24. package/dist/translations/da.umd.js +1 -1
  25. package/dist/translations/de-ch.js +1 -1
  26. package/dist/translations/de-ch.umd.js +1 -1
  27. package/dist/translations/de.js +1 -1
  28. package/dist/translations/de.umd.js +1 -1
  29. package/dist/translations/el.js +1 -1
  30. package/dist/translations/el.umd.js +1 -1
  31. package/dist/translations/en-au.js +1 -1
  32. package/dist/translations/en-au.umd.js +1 -1
  33. package/dist/translations/en-gb.js +1 -1
  34. package/dist/translations/en-gb.umd.js +1 -1
  35. package/dist/translations/en.js +1 -1
  36. package/dist/translations/en.umd.js +1 -1
  37. package/dist/translations/eo.js +1 -1
  38. package/dist/translations/eo.umd.js +1 -1
  39. package/dist/translations/es-co.js +1 -1
  40. package/dist/translations/es-co.umd.js +1 -1
  41. package/dist/translations/es.js +1 -1
  42. package/dist/translations/es.umd.js +1 -1
  43. package/dist/translations/et.js +1 -1
  44. package/dist/translations/et.umd.js +1 -1
  45. package/dist/translations/eu.js +1 -1
  46. package/dist/translations/eu.umd.js +1 -1
  47. package/dist/translations/fa.js +1 -1
  48. package/dist/translations/fa.umd.js +1 -1
  49. package/dist/translations/fi.js +1 -1
  50. package/dist/translations/fi.umd.js +1 -1
  51. package/dist/translations/fr.js +1 -1
  52. package/dist/translations/fr.umd.js +1 -1
  53. package/dist/translations/gl.js +1 -1
  54. package/dist/translations/gl.umd.js +1 -1
  55. package/dist/translations/gu.js +1 -1
  56. package/dist/translations/gu.umd.js +1 -1
  57. package/dist/translations/he.js +1 -1
  58. package/dist/translations/he.umd.js +1 -1
  59. package/dist/translations/hi.js +1 -1
  60. package/dist/translations/hi.umd.js +1 -1
  61. package/dist/translations/hr.js +1 -1
  62. package/dist/translations/hr.umd.js +1 -1
  63. package/dist/translations/hu.js +1 -1
  64. package/dist/translations/hu.umd.js +1 -1
  65. package/dist/translations/hy.js +1 -1
  66. package/dist/translations/hy.umd.js +1 -1
  67. package/dist/translations/id.js +1 -1
  68. package/dist/translations/id.umd.js +1 -1
  69. package/dist/translations/it.js +1 -1
  70. package/dist/translations/it.umd.js +1 -1
  71. package/dist/translations/ja.js +1 -1
  72. package/dist/translations/ja.umd.js +1 -1
  73. package/dist/translations/jv.js +1 -1
  74. package/dist/translations/jv.umd.js +1 -1
  75. package/dist/translations/kk.js +1 -1
  76. package/dist/translations/kk.umd.js +1 -1
  77. package/dist/translations/km.js +1 -1
  78. package/dist/translations/km.umd.js +1 -1
  79. package/dist/translations/kn.js +1 -1
  80. package/dist/translations/kn.umd.js +1 -1
  81. package/dist/translations/ko.js +1 -1
  82. package/dist/translations/ko.umd.js +1 -1
  83. package/dist/translations/ku.js +1 -1
  84. package/dist/translations/ku.umd.js +1 -1
  85. package/dist/translations/lt.js +1 -1
  86. package/dist/translations/lt.umd.js +1 -1
  87. package/dist/translations/lv.js +1 -1
  88. package/dist/translations/lv.umd.js +1 -1
  89. package/dist/translations/ms.js +1 -1
  90. package/dist/translations/ms.umd.js +1 -1
  91. package/dist/translations/nb.js +1 -1
  92. package/dist/translations/nb.umd.js +1 -1
  93. package/dist/translations/ne.js +1 -1
  94. package/dist/translations/ne.umd.js +1 -1
  95. package/dist/translations/nl.js +1 -1
  96. package/dist/translations/nl.umd.js +1 -1
  97. package/dist/translations/no.js +1 -1
  98. package/dist/translations/no.umd.js +1 -1
  99. package/dist/translations/oc.js +1 -1
  100. package/dist/translations/oc.umd.js +1 -1
  101. package/dist/translations/pl.js +1 -1
  102. package/dist/translations/pl.umd.js +1 -1
  103. package/dist/translations/pt-br.js +1 -1
  104. package/dist/translations/pt-br.umd.js +1 -1
  105. package/dist/translations/pt.js +1 -1
  106. package/dist/translations/pt.umd.js +1 -1
  107. package/dist/translations/ro.js +1 -1
  108. package/dist/translations/ro.umd.js +1 -1
  109. package/dist/translations/ru.js +1 -1
  110. package/dist/translations/ru.umd.js +1 -1
  111. package/dist/translations/si.js +1 -1
  112. package/dist/translations/si.umd.js +1 -1
  113. package/dist/translations/sk.js +1 -1
  114. package/dist/translations/sk.umd.js +1 -1
  115. package/dist/translations/sl.js +1 -1
  116. package/dist/translations/sl.umd.js +1 -1
  117. package/dist/translations/sq.js +1 -1
  118. package/dist/translations/sq.umd.js +1 -1
  119. package/dist/translations/sr-latn.js +1 -1
  120. package/dist/translations/sr-latn.umd.js +1 -1
  121. package/dist/translations/sr.js +1 -1
  122. package/dist/translations/sr.umd.js +1 -1
  123. package/dist/translations/sv.js +1 -1
  124. package/dist/translations/sv.umd.js +1 -1
  125. package/dist/translations/th.js +1 -1
  126. package/dist/translations/th.umd.js +1 -1
  127. package/dist/translations/ti.js +1 -1
  128. package/dist/translations/ti.umd.js +1 -1
  129. package/dist/translations/tk.js +1 -1
  130. package/dist/translations/tk.umd.js +1 -1
  131. package/dist/translations/tr.js +1 -1
  132. package/dist/translations/tr.umd.js +1 -1
  133. package/dist/translations/tt.js +1 -1
  134. package/dist/translations/tt.umd.js +1 -1
  135. package/dist/translations/ug.js +1 -1
  136. package/dist/translations/ug.umd.js +1 -1
  137. package/dist/translations/uk.js +1 -1
  138. package/dist/translations/uk.umd.js +1 -1
  139. package/dist/translations/ur.js +1 -1
  140. package/dist/translations/ur.umd.js +1 -1
  141. package/dist/translations/uz.js +1 -1
  142. package/dist/translations/uz.umd.js +1 -1
  143. package/dist/translations/vi.js +1 -1
  144. package/dist/translations/vi.umd.js +1 -1
  145. package/dist/translations/zh-cn.js +1 -1
  146. package/dist/translations/zh-cn.umd.js +1 -1
  147. package/dist/translations/zh.js +1 -1
  148. package/dist/translations/zh.umd.js +1 -1
  149. package/package.json +12 -12
  150. package/src/changeitem.js +2 -2
  151. package/src/editor/revisionviewereditor.js +2 -2
  152. package/src/editor/revisionviewereditorui.js +1 -1
  153. package/src/editor/revisionviewereditoruiview.js +1 -1
  154. package/src/index.js +1 -1
  155. package/src/revision.js +2 -2
  156. package/src/revisiondiff.js +1 -1
  157. package/src/revisionhistory.js +1 -1
  158. package/src/revisionhistoryutils.js +1 -1
  159. package/src/revisionsrepository.js +1 -1
  160. package/src/revisiontracker.js +1 -1
  161. package/src/revisionviewer.js +1 -1
  162. package/src/ui/revision/createrevisionactionsdropdown.js +1 -1
  163. package/src/ui/revision/revisionauthorview.js +1 -1
  164. package/src/ui/revision/revisionnameview.js +1 -1
  165. package/src/ui/revision/revisionview.js +2 -2
  166. package/src/ui/revision/subrevisioncollapserview.js +1 -1
  167. package/src/ui/revision/subrevisionview.js +1 -1
  168. package/src/ui/revision/utils.js +1 -1
  169. package/src/ui/revisionhistory/revisionhistorysaverevisionformview.js +2 -2
  170. package/src/ui/revisionhistory/revisionhistoryui.js +1 -1
  171. package/src/ui/revisionssidebar/revisionssidebar.js +1 -1
  172. package/src/ui/revisionssidebar/revisionssidebarheaderview.js +1 -1
  173. package/src/ui/revisionssidebar/revisionssidebartimeperiodview.js +1 -1
  174. package/src/ui/revisionssidebar/revisionssidebarview.js +1 -1
  175. package/src/ui/revisionssidebar/utils.js +1 -1
  176. package/src/ui/revisionviewer/changedetailsview.js +1 -1
  177. package/src/ui/revisionviewer/changesnavigationview.js +1 -1
  178. package/src/ui/revisionviewer/revisionviewerloadingoverlay.js +1 -1
  179. package/src/ui/revisionviewer/revisionviewerui.js +1 -1
  180. package/src/utils/common-translations.js +1 -1
package/dist/index.js CHANGED
@@ -20,11 +20,11 @@
20
20
  *
21
21
  *
22
22
  */
23
- import{ObservableMixin as _0x8df1b4,uid as _0xefa39,Collection as _0x4fc9f6,logWarning as _0x28dcdd,FocusTracker as _0x1e7ab2,KeystrokeHandler as _0x248400,scrollViewportToShowTarget as _0x5bc707,ResizeObserver as ot,ElementReplacer as it,CKEditorError as _0x2fd89f}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0xadda3d,set as _0x5a4877,unset as _0x281fc9,isEqual as _0x21fc28}from'es-toolkit/compat';import{Plugin as _0xde4b58,PendingActions as _0xa7f6d0,Command as _0x5c344b,ElementApiMixin as _0x1bf367,Editor as _0x5a3aa2}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x405575,getMarkerDomElement as _0xcc7916,ConfirmMixin as _0x635858,sanitizeEditorConfig as _0x3f3d11}from'ckeditor5-collaboration/dist/index.js';import{ViewContainerElement as _0x1d2e44,ViewAttributeElement as _0x594ba8,ViewEmptyElement as _0x475abc,ViewRawElement as _0x36f97a,ViewUIElement as _0x53adbf,ViewDocumentFragment as _0x263cbd,ViewText as _0x14b755,ViewElement as _0x33d88c,ModelElement as _0x39812c,ModelRange as _0x1474a8,ModelPosition as _0x5273bc,ModelDocumentFragment as _0xa6ead0,ModelText as _0x58927f}from'@ckeditor/ckeditor5-engine/dist/index.js';import{IconHistory as _0x173b8e,IconChevronUp as _0xf8e6f0,IconChevronDown as _0x532e88,IconUndo as _0x13d588,IconUser as _0x4e060a,IconThreeVerticalDots as _0x14f165}from'@ckeditor/ckeditor5-icons/dist/index.js';import{CssTransitionDisablerMixin as _0x2e53b2,View as _0x584d23,submitHandler as _0x4935d8,LabeledFieldView as et,createLabeledInputText as ti,createDropdown as _0x4c9aaf,ListView as _0x277762,ListItemView as _0x9334aa,ButtonView as _0x56b48b,MenuBarMenuView as _0x27668a,MenuBarMenuListView as _0x432d32,MenuBarMenuListItemView as _0x594efc,MenuBarMenuListItemButtonView as _0x426818,ContextualBalloon as _0x5f3958,ToolbarSeparatorView as _0x4be757,IconView as _0x5649b5,addListToDropdown as _0x35149e,UIModel as to,EditorUI as tt,normalizeToolbarConfig as st,BoxedEditorUIView as _0x2af41,StickyPanelView as _0x1e83cf,ToolbarView as _0x8564d3,InlineEditableUIView as te}from'@ckeditor/ckeditor5-ui/dist/index.js';import{DateTime as _0x156a48}from'luxon';class I extends/* #__PURE__ -- @preserve */
24
- _0x8df1b4(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x445e39){super(),this['id']=_0x445e39['id']||_0xefa39(),this['creator']=_0x445e39['creator']||null,this['authors']=_0x445e39['authors']||[],this['diffData']=_0x445e39['diffData']||null,this['toVersion']=_0x445e39['toVersion']||0x0,this['fromVersion']=_0x445e39['fromVersion']||0x0,this['set']('name',_0x445e39['name']||''),this['set']('createdAt',_0x445e39['createdAt']||new Date()),this['set']('attributes',_0x445e39['attributes']||{});}['setName'](_0x557063){this['_update']({'name':_0x557063});}['setAttribute'](_0x29c2e9,_0x58903e){const _0x57113b=_0xadda3d(this['attributes']);_0x5a4877(_0x57113b,_0x29c2e9,_0x58903e),this['_update']({'attributes':_0x57113b});}['removeAttribute'](_0x40ccb8){const _0x593580=_0xadda3d(this['attributes']);_0x281fc9(_0x593580,_0x40ccb8),this['_update']({'attributes':_0x593580});}['_update'](_0x2de636,_0x53b07a=!0x1){let _0x4be27b=!0x1;const _0xdf86e2={'id':this['id']},_0x457c3f=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x5da00f of _0x457c3f){const _0x3a1608=_0x2de636[_0x5da00f];void 0x0!==_0x3a1608&&_0x3a1608!==this[_0x5da00f]&&(this[_0x5da00f]=_0x3a1608,_0xdf86e2[_0x5da00f]=_0x3a1608,_0x4be27b=!0x0);}_0x4be27b&&(_0xdf86e2['authors']&&(_0xdf86e2['authorsIds']=_0xdf86e2['authors']['map'](_0xec4aa7=>_0xec4aa7['id']),delete _0xdf86e2['authors']),this['fire']('_update',_0xdf86e2,_0x53b07a));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x48aa05=>_0x48aa05['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class S extends _0xde4b58{['_revisions'];static get['requires'](){return[_0x405575];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0xe93777){super(_0xe93777),this['_revisions']=new _0x4fc9f6();}['afterInit'](){!async function(_0x89b19f){const _0x2a0cd4=_0x274a2d([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]),_0x1be935=0xeb829,_0xe7bdd6=0x359e09b0,_0x46907b=0x359983d8^_0xe7bdd6,_0x3d1fa8=window[_0x274a2d([0x44,0x61,0x74,0x65])][_0x274a2d([0x6e,0x6f,0x77])](),_0x40c97d=_0x89b19f[_0x274a2d([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x2fb214=new window[(_0x274a2d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x4e4379=>{_0x40c97d[_0x274a2d([0x6f,0x6e,0x63,0x65])](_0x274a2d([0x72,0x65,0x61,0x64,0x79]),_0x4e4379);}),_0x57d0e4={[_0x274a2d([0x6b,0x74,0x79])]:_0x274a2d([0x45,0x43]),[_0x274a2d([0x75,0x73,0x65])]:_0x274a2d([0x73,0x69,0x67]),[_0x274a2d([0x63,0x72,0x76])]:_0x274a2d([0x50,0x2d,0x32,0x35,0x36]),[_0x274a2d([0x78])]:_0x274a2d([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]),[_0x274a2d([0x79])]:_0x274a2d([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]),[_0x274a2d([0x61,0x6c,0x67])]:_0x274a2d([0x45,0x53,0x32,0x35,0x36])},_0x52579c=_0x40c97d[_0x274a2d([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x274a2d([0x67,0x65,0x74])](_0x274a2d([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x4b60db(){let _0xf300b5,_0x374cb9=null,_0x46f256=null;try{if(_0x52579c==_0x274a2d([0x47,0x50,0x4c]))return _0x274a2d([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0xf300b5=_0x3aeacb(),!_0xf300b5)return _0x274a2d([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0xf300b5[_0x274a2d([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x46f256=_0xac709a(_0xf300b5[_0x274a2d([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0xf300b5[_0x274a2d([0x6a,0x74,0x69])])),await _0x105df1()?_0x5707be()?_0x325375()?_0x274a2d([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x42fe6d()?(_0xf300b5[_0x274a2d([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x274a2d([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x374cb9=_0x173f21(_0x274a2d([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),await _0x13f770()):_0x274a2d([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x274a2d([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x274a2d([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x274a2d([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x325375(){const _0x54170e=[_0x274a2d([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x274a2d([0x74,0x72,0x69,0x61,0x6c])][_0x274a2d([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0xf300b5[_0x274a2d([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x3d1fa8/0x3e8:0xe10*_0x46907b;return _0xf300b5[_0x274a2d([0x65,0x78,0x70])]<_0x54170e;}function _0x5707be(){const _0x2d0593=_0xf300b5[_0x274a2d([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x2d0593)return!0x1;if(_0x2d0593[_0x274a2d([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x274a2d([0x2a])))return!0x0;if(_0x2d0593[_0x274a2d([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x274a2d([0x52,0x48])))return!0x0;if(_0x2d0593[_0x274a2d([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x274a2d([0x52,0x52,0x48]))){if(_0xab4c6c())return!0x0;if(_0x225569()||_0x6e20a5())return!0x0;}return!0x1;}function _0x42fe6d(){const _0x602e4d=_0xf300b5[_0x274a2d([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x602e4d||0x0==_0x602e4d[_0x274a2d([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x27836c}=new URL(window[_0x274a2d([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x602e4d[_0x274a2d([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x27836c))return!0x0;const _0x4f7002=_0x27836c[_0x274a2d([0x73,0x70,0x6c,0x69,0x74])](_0x274a2d([0x2e]));return _0x602e4d[_0x274a2d([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x3476ba=>_0x3476ba[_0x274a2d([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x274a2d([0x2a])))[_0x274a2d([0x6d,0x61,0x70])](_0x1af132=>_0x1af132[_0x274a2d([0x73,0x70,0x6c,0x69,0x74])](_0x274a2d([0x2e])))[_0x274a2d([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x116329=>_0x116329[_0x274a2d([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x4f7002[_0x274a2d([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x274a2d([0x6d,0x61,0x70])](_0x327b65=>Array(_0x4f7002[_0x274a2d([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0x327b65[_0x274a2d([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x274a2d([0x66,0x69,0x6c,0x6c])](_0x327b65[0x0]===_0x274a2d([0x2a])?_0x274a2d([0x2a]):'')[_0x274a2d([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0x327b65))[_0x274a2d([0x73,0x6f,0x6d,0x65])](_0x3e5bc1=>_0x4f7002[_0x274a2d([0x65,0x76,0x65,0x72,0x79])]((_0x1f1ab7,_0x517577)=>_0x3e5bc1[_0x517577]===_0x1f1ab7||_0x3e5bc1[_0x517577]===_0x274a2d([0x2a])));}function _0x13f770(){return _0x374cb9&&_0x46f256?new window[(_0x274a2d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x2fa9df,_0x11d356)=>{_0x374cb9[_0x274a2d([0x74,0x68,0x65,0x6e])](_0x2fa9df,_0x11d356),_0x46f256[_0x274a2d([0x74,0x68,0x65,0x6e])](_0xd1acb5=>{_0xd1acb5!=_0x274a2d([0x56,0x61,0x6c,0x69,0x64])&&_0x2fa9df(_0xd1acb5);},_0x11d356);}):_0x374cb9||_0x46f256||_0x274a2d([0x56,0x61,0x6c,0x69,0x64]);}}function _0xac709a(_0x6c56bc,_0x36a860){return new window[(_0x274a2d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x52712e=>{if(_0x124306())return _0x52712e(_0x274a2d([0x56,0x61,0x6c,0x69,0x64]));_0x4dc0ed(),_0x40c97d[_0x274a2d([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x274a2d([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x530320=!0x1;const _0x1c73ed=_0xefa39();function _0x37eeef(_0x1b08b7){return!!_0x1b08b7&&(typeof _0x1b08b7===_0x274a2d([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x1b08b7===_0x274a2d([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x1b08b7[_0x274a2d([0x74,0x68,0x65,0x6e])]===_0x274a2d([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x1b08b7[_0x274a2d([0x63,0x61,0x74,0x63,0x68])]===_0x274a2d([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x1b64bb(_0x14b166){_0x5e3cae(_0x14b166)[_0x274a2d([0x74,0x68,0x65,0x6e])](_0x5d686c=>{if(!_0x5d686c||_0x5d686c[_0x274a2d([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x274a2d([0x6f,0x6b]))return _0x274a2d([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x572f9e(_0x5cab68(_0x1c73ed+_0x36a860))!=_0x5d686c[_0x274a2d([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x274a2d([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x274a2d([0x56,0x61,0x6c,0x69,0x64]);})[_0x274a2d([0x74,0x68,0x65,0x6e])](_0x4ef0f6=>(_0x2e4dcd(),_0x4ef0f6),()=>{const _0xd8fcea=_0x1a8595();return null==_0xd8fcea?(_0x2e4dcd(),_0x274a2d([0x56,0x61,0x6c,0x69,0x64])):_0x274a2d(_0x3d1fa8-_0xd8fcea>(0x11928db0^_0xe7bdd6)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x274a2d([0x74,0x68,0x65,0x6e])](_0x52712e)[_0x274a2d([0x63,0x61,0x74,0x63,0x68])](()=>{_0x52712e(_0x274a2d([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x48282=0x35a8e730^_0xe7bdd6;function _0x2e4dcd(){const _0x1f53ed=_0x274a2d([0x6c,0x6c,0x63,0x74,0x2d])+_0x572f9e(_0x5cab68(_0x6c56bc)),_0x24e72b=_0x166a64(_0x572f9e(window[_0x274a2d([0x4d,0x61,0x74,0x68])][_0x274a2d([0x63,0x65,0x69,0x6c])](_0x3d1fa8/_0x48282)));window[_0x274a2d([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x274a2d([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x1f53ed,_0x24e72b);}function _0x1a8595(){const _0x36e015=_0x274a2d([0x6c,0x6c,0x63,0x74,0x2d])+_0x572f9e(_0x5cab68(_0x6c56bc)),_0x3777bf=window[_0x274a2d([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x274a2d([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x36e015);return _0x3777bf?window[_0x274a2d([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x166a64(_0x3777bf),0x10)*_0x48282:null;}function _0x5e3cae(_0x1ae478){return new window[(_0x274a2d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x37e41e,_0x257cc0)=>{_0x1ae478[_0x274a2d([0x74,0x68,0x65,0x6e])](_0x37e41e,_0x257cc0),window[_0x274a2d([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x257cc0,0x359fdd70^_0xe7bdd6);});}}_0x40c97d[_0x274a2d([0x6f,0x6e])](_0x274a2d([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x25ef96,_0x32b6a7)=>{if(_0x32b6a7[0x0]!=_0x6c56bc)return _0x52712e(_0x274a2d([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x32b6a7[0x1]={..._0x32b6a7[0x1],[_0x274a2d([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x1c73ed};},{[_0x274a2d([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x274a2d([0x68,0x69,0x67,0x68])}),_0x40c97d[_0x274a2d([0x6f,0x6e])](_0x274a2d([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x305a0b=>{_0x37eeef(_0x305a0b[_0x274a2d([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x530320=!0x0,_0x1b64bb(_0x305a0b[_0x274a2d([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x274a2d([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x274a2d([0x6c,0x6f,0x77])}),_0x2fb214[_0x274a2d([0x74,0x68,0x65,0x6e])](()=>{_0x530320||_0x52712e(_0x274a2d([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x124306(){return _0x40c97d[_0x274a2d([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x274a2d([0x76,0x69,0x65,0x77])][_0x274a2d([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x274a2d([0x61,0x75,0x74,0x6f]);}function _0x4dc0ed(){_0x40c97d[_0x274a2d([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x274a2d([0x76,0x69,0x65,0x77])][_0x274a2d([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x274a2d([0x61,0x75,0x74,0x6f]);}}function _0x173f21(_0x4d77a6){const _0x242c57=[new window[(_0x274a2d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x476bef=>setTimeout(_0x476bef,0x3597377c^_0xe7bdd6)),_0x2fb214[_0x274a2d([0x74,0x68,0x65,0x6e])](()=>new window[(_0x274a2d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x145e83=>{const _0x3babe0=0x359e09b7^_0xe7bdd6,_0x27415b=_0x89b19f[_0x274a2d([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x4fc00c(){_0x27415b[_0x274a2d([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x3babe0&&_0x145e83();}_0x4fc00c(),_0x27415b[_0x274a2d([0x6f,0x6e])](_0x274a2d([0x61,0x64,0x64]),_0x4fc00c);})),new window[(_0x274a2d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x484a08=>{function _0x233c77(){for(const _0x3702bf in window)if(window[_0x274a2d([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x274a2d([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x3702bf))&&window[_0x3702bf]==_0x1be935)return _0x484a08();_0x40c97d[_0x274a2d([0x73,0x74,0x61,0x74,0x65])]!=_0x274a2d([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x274a2d([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x233c77,0x359e1a38^_0xe7bdd6);}_0x553444(_0x274a2d([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x233c77();})];return window[_0x274a2d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x274a2d([0x72,0x61,0x63,0x65])](_0x242c57)[_0x274a2d([0x74,0x68,0x65,0x6e])](()=>_0x4d77a6);}async function _0x5fb0f8(){if(await _0x2fb214,_0x553444(_0x274a2d([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x3cc9fd=_0x89b19f[_0x274a2d([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x1e5270=_0x89b19f[_0x274a2d([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])](_0x3cc9fd[_0x274a2d([0x69,0x64])]),_0x38acc9=_0x3af929(_0x274a2d([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x38acc9[_0x274a2d([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x3cc9fd['id'],_0x1e5270?_0x1e5270['id']:null,!0x0),_0x38acc9[_0x274a2d([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x274a2d([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x38acc9[_0x274a2d([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x38acc9[_0x274a2d([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x524d64,void(_0x38acc9[_0x274a2d([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x524d64);}if(_0x553444(_0x274a2d([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0xeeee43=_0x3af929(_0x274a2d([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0xeeee43[_0x274a2d([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x274a2d([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0xeeee43[_0x274a2d([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0xeeee43[_0x274a2d([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x524d64,_0xeeee43[_0x274a2d([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x524d64;}_0x40c97d[_0x274a2d([0x6d,0x6f,0x64,0x65,0x6c])][_0x274a2d([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x524d64,_0x40c97d[_0x274a2d([0x6d,0x6f,0x64,0x65,0x6c])][_0x274a2d([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x524d64,_0x40c97d[_0x274a2d([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x274a2d([0x6d,0x6f,0x64,0x65,0x6c]));}function _0xab4c6c(){return _0x553444(_0x274a2d([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x3af929(_0x274a2d([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x274a2d([0x73,0x74,0x61,0x74,0x65])]==_0x274a2d([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x225569(){return _0x553444(_0x274a2d([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 _0x6e20a5(){return _0x553444(_0x274a2d([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x5ca9c1(_0x57a697){const _0x30e666=_0x1b7049();_0x40c97d[_0x30e666]=_0x274a2d([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])+_0x57a697,_0x57a697[_0x274a2d([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x274a2d([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x1b7049()]=_0x1be935),_0x57a697!=_0x274a2d([0x56,0x61,0x6c,0x69,0x64])&&_0x5fb0f8();}function _0x1b7049(){const _0x2bdcd7=window[_0x274a2d([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x274a2d([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x274a2d([0x6e,0x6f,0x77])]())[_0x274a2d([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x274a2d([0x2e]),'');let _0x51d203=_0x274a2d([0x76]);for(let _0x4454cb=0x0;_0x4454cb<_0x2bdcd7[_0x274a2d([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x4454cb+=0x2){let _0x1a27e1=window[_0x274a2d([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x2bdcd7[_0x274a2d([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x4454cb,_0x4454cb+0x2));_0x1a27e1>=_0x2a0cd4[_0x274a2d([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x1a27e1-=_0x2a0cd4[_0x274a2d([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x51d203+=_0x2a0cd4[_0x1a27e1];}return _0x51d203;}function _0x3aeacb(){const _0x5a87c8=_0x52579c[_0x274a2d([0x73,0x70,0x6c,0x69,0x74])](_0x274a2d([0x2e]));if(0x3!=_0x5a87c8[_0x274a2d([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x47c0c1(_0x5a87c8[0x1]);function _0x47c0c1(_0x39c620){const _0x3c87a2=_0x5db9cd(_0x39c620);return _0x3c87a2&&_0x425369()?_0x3c87a2:null;function _0x425369(){const _0x4828a4=_0x3c87a2[_0x274a2d([0x6a,0x74,0x69])],_0x34399e=window[_0x274a2d([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x4828a4[_0x274a2d([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x4828a4[_0x274a2d([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0xc27958={..._0x3c87a2,[_0x274a2d([0x6a,0x74,0x69])]:_0x4828a4[_0x274a2d([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x4828a4[_0x274a2d([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0xc27958[_0x274a2d([0x76,0x63])],_0x5cab68(_0xc27958)==_0x34399e;}}}async function _0x105df1(){let _0x2baa86=!0x0;try{const _0x5eabc9=_0x52579c[_0x274a2d([0x73,0x70,0x6c,0x69,0x74])](_0x274a2d([0x2e])),[_0x4f3b0e,_0x3e3e9e,_0x433b34]=_0x5eabc9;return _0x34a2c8(_0x4f3b0e),await _0x382697(_0x4f3b0e,_0x3e3e9e,_0x433b34),_0x2baa86;}catch{return!0x1;}function _0x34a2c8(_0x195d0b){const _0x3867bb=_0x5db9cd(_0x195d0b);_0x3867bb&&_0x3867bb[_0x274a2d([0x61,0x6c,0x67])]==_0x274a2d([0x45,0x53,0x32,0x35,0x36])||(_0x2baa86=!0x1);}async function _0x382697(_0xd4425e,_0x1fb35e,_0x20ca30){const _0x1ce6e8=window[_0x274a2d([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x274a2d([0x66,0x72,0x6f,0x6d])](_0x59c287(_0x20ca30),_0x48db4b=>_0x48db4b[_0x274a2d([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x4171c0=new window[(_0x274a2d([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x274a2d([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0xd4425e+_0x274a2d([0x2e])+_0x1fb35e),_0x486888=window[_0x274a2d([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x274a2d([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x486888)return;const _0xd9b566=await _0x486888[_0x274a2d([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x274a2d([0x6a,0x77,0x6b]),_0x57d0e4,{[_0x274a2d([0x6e,0x61,0x6d,0x65])]:_0x274a2d([0x45,0x43,0x44,0x53,0x41]),[_0x274a2d([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x274a2d([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x274a2d([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x486888[_0x274a2d([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x274a2d([0x6e,0x61,0x6d,0x65])]:_0x274a2d([0x45,0x43,0x44,0x53,0x41]),[_0x274a2d([0x68,0x61,0x73,0x68])]:{[_0x274a2d([0x6e,0x61,0x6d,0x65])]:_0x274a2d([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0xd9b566,_0x1ce6e8,_0x4171c0)||(_0x2baa86=!0x1);}}function _0x5db9cd(_0x3b19f8){return _0x3b19f8[_0x274a2d([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x274a2d([0x65,0x79]))?JSON[_0x274a2d([0x70,0x61,0x72,0x73,0x65])](_0x59c287(_0x3b19f8)):null;}function _0x59c287(_0x2f75dc){return window[_0x274a2d([0x61,0x74,0x6f,0x62])](_0x2f75dc[_0x274a2d([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x274a2d([0x2b]))[_0x274a2d([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x274a2d([0x2f])));}function _0x5cab68(_0x4dc278){let _0x4d5660=0x1505;function _0x1367e1(_0x507ba5){for(let _0x28c07c=0x0;_0x28c07c<_0x507ba5[_0x274a2d([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x28c07c++){const _0xf1e31f=_0x507ba5[_0x274a2d([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x28c07c);_0x4d5660=(_0x4d5660<<0x5)+_0x4d5660+_0xf1e31f,_0x4d5660&=_0x4d5660;}}function _0x58eb84(_0x5cf2a3){Array[_0x274a2d([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x5cf2a3)?_0x5cf2a3[_0x274a2d([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x58eb84):_0x5cf2a3&&typeof _0x5cf2a3==_0x274a2d([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x274a2d([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x5cf2a3)[_0x274a2d([0x73,0x6f,0x72,0x74])]()[_0x274a2d([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x5e86cc,_0x18aa7b])=>{_0x1367e1(_0x5e86cc),_0x58eb84(_0x18aa7b);}):_0x1367e1(window[_0x274a2d([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x5cf2a3));}return _0x58eb84(_0x4dc278),_0x4d5660>>>0x0;}function _0x572f9e(_0x31472c){return _0x31472c[_0x274a2d([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x274a2d([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x274a2d([0x30]));}function _0x166a64(_0x3b0632){return _0x3b0632[_0x274a2d([0x73,0x70,0x6c,0x69,0x74])]('')[_0x274a2d([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x274a2d([0x6a,0x6f,0x69,0x6e])]('');}function _0x553444(_0x115a10){return _0x40c97d[_0x274a2d([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x274a2d([0x68,0x61,0x73])](_0x115a10);}function _0x3af929(_0x5178d4){return _0x40c97d[_0x274a2d([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x274a2d([0x67,0x65,0x74])](_0x5178d4);}function _0x524d64(){}function _0x274a2d(_0x15a050){return _0x15a050['map'](_0x1f2744=>String['fromCharCode'](_0x1f2744))['join']('');}_0x5ca9c1(await _0x4b60db());}(this);}['createRevision'](_0x57cd67){const _0x500981=this['editor']['plugins']['get']('Users');return new I({'id':_0x57cd67['id'],'name':_0x57cd67['name'],'creator':_0x57cd67['creatorId']?_0x500981['getUser'](_0x57cd67['creatorId']):null,'diffData':_0x57cd67['diffData']||_0x57cd67['data'],'authors':_0x57cd67['authorsIds']['map'](_0x5a4a60=>_0x500981['getUser'](_0x5a4a60)),'createdAt':new Date(_0x57cd67['createdAt']),'attributes':_0x57cd67['attributes'],'fromVersion':_0x57cd67['fromVersion'],'toVersion':_0x57cd67['toVersion']});}['addRevision'](_0x5c941,_0x3d24c5=0x0){this['_revisions']['add'](_0x5c941,_0x3d24c5);}['getRevision'](_0x479b04){return this['_revisions']['get'](_0x479b04);}['getRevisions'](_0x531792={'toJSON':!0x1}){const _0x1051a6=Array['from'](this['_revisions']);return _0x1051a6['reverse'](),_0x531792['toJSON']?_0x1051a6['map'](_0x1e7c97=>_0x1e7c97['toJSON']()):_0x1051a6;}['getIndex'](_0x3f8986){return this['_revisions']['getIndex'](_0x3f8986);}['getEarlierVisibleRevision'](_0x1938d9){const [,_0x563ca5]=this['getRevisionsIterator'](_0x1938d9,{'direction':'earlier'});return _0x563ca5;}['getLaterVisibleRevision'](_0x59346d){const [,_0x29e489]=this['getRevisionsIterator'](_0x59346d,{'direction':'later'});return _0x29e489;}['getRevisionsInDiff'](_0x16d5f9){const _0x583e8b=[];for(const _0x56690e of this['getRevisionsIterator'](_0x16d5f9['newRevisionId']))if(_0x583e8b['push'](_0x56690e),_0x56690e['id']===_0x16d5f9['oldRevisionId'])break;return _0x583e8b;}*['getRevisionsIterator'](_0x4f2734,{direction:_0x2f9bf7='earlier',filter:_0x35c646=()=>!0x0}={}){const _0x106f50='earlier'===_0x2f9bf7?0x1:-0x1;let _0x12d643=this['_revisions']['get'](_0x4f2734),_0x9ffebc=this['getIndex'](_0x12d643);for(yield _0x12d643;_0x12d643;){if(_0x9ffebc+=_0x106f50,_0x12d643=this['getRevision'](_0x9ffebc),!_0x12d643)return;_0x35c646(_0x12d643)&&(yield _0x12d643);}}}class $ extends _0xde4b58{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x1d2e44,'c'],[_0x594ba8,'a'],[_0x475abc,'e'],[_0x36f97a,'r'],[_0x53adbf,'u']]);['_typeCharToViewClass']=new Map([['c',_0x1d2e44],['a',_0x594ba8],['e',_0x475abc],['r',_0x36f97a],['u',_0x53adbf]]);async['loadRevisionData'](_0xc8bcf1,_0x2e5a87){if(_0xc8bcf1['diffData']||!_0x2e5a87)return;const _0x323034=this['editor']['config']['get']('collaboration.channelId'),_0x1e846d=await _0x2e5a87['getRevision']({'channelId':_0x323034,'revisionId':_0xc8bcf1['id']});_0xc8bcf1['diffData']=_0x1e846d['diffData'];}['getRevisionDocumentData'](_0x5f2ebb){const _0x4f9af8={};for(const _0x31747c in _0x5f2ebb['diffData']){if(_0x5f2ebb['diffData'][_0x31747c]['attachChange']&&!_0x5f2ebb['diffData'][_0x31747c]['attachChange']['isAttached'])continue;const _0x11c6dc=this['_removeRevisionMarkers'](JSON['parse'](_0x5f2ebb['diffData'][_0x31747c]['insertions'])),_0x1ce308=this['editor']['editing']['view']['document'],_0xcb3da6=new _0x263cbd(_0x1ce308,_0x11c6dc['map'](_0x167b4f=>this['_getViewFromDiffObj'](_0x167b4f,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x4f9af8[_0x31747c]=this['editor']['data']['processor']['toData'](_0xcb3da6),this['editor']['data']['processor']['useFillerType']('default');}return _0x4f9af8;}['getRevisionRootsAttributes'](_0x19b2c0){const _0x4e5fec={};for(const _0x21c072 in _0x19b2c0['diffData'])_0x19b2c0['diffData'][_0x21c072]['attachChange']&&!_0x19b2c0['diffData'][_0x21c072]['attachChange']['isAttached']||(_0x4e5fec[_0x21c072]=_0x19b2c0['diffData'][_0x21c072]['attributesAfter']||{});return _0x4e5fec;}['_getTypeCharForViewElement'](_0x14a8a9){return this['_viewClassToTypeChar']['get'](_0x14a8a9['constructor']);}['_getViewFromDiffObj'](_0x4f4089,_0x3354ff){const _0x24a836=this['editor']['editing']['view']['document'];if('string'==typeof _0x4f4089)return new _0x14b755(_0x24a836,_0x4f4089);{let _0x5bb1ee,_0x48732a;_0x48732a='u'==_0x4f4089['type']||'r'==_0x4f4089['type']?[]:_0x4f4089['children']['map'](_0x4e2217=>this['_getViewFromDiffObj'](_0x4e2217,_0x3354ff));const _0x285396=this['_typeCharToViewClass']['get'](_0x4f4089['type'])||_0x33d88c,_0x5e3290=this['editor']['data']['htmlProcessor']['domConverter'];if(_0x5bb1ee=new _0x285396(_0x24a836,_0x4f4089['name'],_0x4f4089['attributes'],_0x48732a),'u'==_0x4f4089['type']&&_0x4f4089['children'][0x0]){const _0x40252a=_0x4f4089['children'][0x0];if(_0x5bb1ee['render']=function(_0x6d199a){const _0x17e8ac=_0x6d199a['createElement']('div');return _0x17e8ac['innerHTML']=_0x40252a,_0x17e8ac['childNodes'][0x0];},_0x3354ff){const _0x483f2a=new _0x263cbd(_0x24a836);_0x483f2a['_appendChild'](_0x5bb1ee);const _0xfb0061=Array['from'](_0x5e3290['viewChildrenToDom'](_0x483f2a,{'bind':!0x1})),_0x2c95d3=_0x5e3290['domDocument']['createElement']('div');_0x2c95d3['append'](..._0xfb0061),_0x5bb1ee=Array['from'](_0x5e3290['domChildrenToView'](_0x2c95d3))[0x0];}}else{if('r'==_0x4f4089['type']&&_0x4f4089['children'][0x0]){const _0x10cfa2=_0x4f4089['children'][0x0];if(_0x5bb1ee['render']=function(_0x5555df){_0x5555df['innerHTML']=_0x10cfa2;},_0x3354ff){const _0x3a3470=new _0x263cbd(_0x24a836);_0x3a3470['_appendChild'](_0x5bb1ee);const _0x2afba3=Array['from'](_0x5e3290['viewChildrenToDom'](_0x3a3470,{'bind':!0x1})),_0x1ee551=_0x5e3290['domDocument']['createElement']('div');_0x1ee551['append'](..._0x2afba3);const _0x29ccf7=Array['from'](_0x5e3290['domChildrenToView'](_0x1ee551));_0x29ccf7['length']>0x1?_0x5bb1ee['_appendChild'](_0x29ccf7):_0x5bb1ee=_0x29ccf7[0x0];}}}if(_0x4f4089['customProperties']){for(const [_0x5100ac,_0x379d02]of _0x4f4089['customProperties'])_0x5bb1ee['_setCustomProperty'](_0x5100ac,_0x379d02);}const _0x3b8bcc=void 0x0===_0x4f4089['fillerOffset']?null:_0x4f4089['fillerOffset'];return null!==_0x3b8bcc&&(_0x5bb1ee['getFillerOffset']=()=>_0x3b8bcc),_0x5bb1ee;}}['_makeModelFromViewString'](_0x56d67b){const _0x2d1239=JSON['parse'](_0x56d67b),_0x41f91e=this['editor']['editing']['view']['document'],_0x5e2264=new _0x263cbd(_0x41f91e,_0x2d1239['map'](_0x3e0311=>this['_getViewFromDiffObj'](_0x3e0311,!0x0)));return this['editor']['data']['toModel'](_0x5e2264);}['_removeRevisionMarkers'](_0x20cbf2){return(_0x20cbf2=_0x20cbf2['filter'](_0x186dcd=>!_0x186dcd['name']||'revision-start'!==_0x186dcd['name']&&'revision-end'!==_0x186dcd['name']))['forEach'](_0x369be3=>{'string'!=typeof _0x369be3&&(_0x369be3['children']=this['_removeRevisionMarkers'](_0x369be3['children']),_0x369be3['attributes']=_0x369be3['attributes']['filter'](_0x230eca=>!_0x230eca[0x0]['startsWith']('data-revision-')));}),_0x20cbf2;}}function m(_0x451335,_0x28824e,_0x4eb934){const t=_0x451335['t'];switch(_0x28824e){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'},_0x4eb934);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x4eb934);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 h extends _0xde4b58{['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[_0x405575,S,$,_0xa7f6d0];}constructor(_0x27a8ae){super(_0x27a8ae),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 _0x36e07d=_0xefa39();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x36e07d},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 _0x5abac9=this['repository']['getRevision'](0x0),_0x53e5bd=_0x5abac9&&null===_0x5abac9['creator']?_0x5abac9:null;if(this['_continueCurrentRevision']=!!_0x53e5bd&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x4f8632=this['_source']['getCurrentRevisionId'](),_0x311c0b=this['repository']['getRevision'](_0x4f8632);if(_0x311c0b)this['_startingVersion']=_0x311c0b['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x4cee2e=this['_source']['history']['_operations']['find'](_0x17f2cc=>!_0x17f2cc['_isInit']),_0x141b09=_0x4cee2e?_0x4cee2e['baseVersion']:this['_source']['history']['version'];_0x5abac9?(_0x5abac9['toVersion']<_0x141b09&&_0x5abac9['_update']({'toVersion':_0x141b09}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x53e5bd['id'],this['_startingVersion']=_0x53e5bd['fromVersion']):(this['_startingVersion']=_0x5abac9['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x141b09,this['_continueCurrentRevision']=!0x1);}}else _0x53e5bd&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x53e5bd['toVersion'],this['editor']['model']['document']['history']['version']),_0x53e5bd['fromVersion']===_0x53e5bd['toVersion']?(0x0!==_0x53e5bd['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x53e5bd['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x53e5bd['id'],this['_startingVersion']=_0x53e5bd['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',_0x4d4ba3=>!_0x4d4ba3),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x4d774a=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x4cde37;for(const _0x47fa3f in _0x4d774a){const _0x10a5a1=_0x47fa3f,_0x5252d0=_0x4d774a[_0x10a5a1];if('revisionHistoryLicenseKeyValid'==_0x5252d0||'revisionHistoryLicenseKeyInvalid'==_0x5252d0||'revisionHistoryLicenseKeyExpired'==_0x5252d0||'revisionHistoryLicenseKeyDomainLimit'==_0x5252d0||'revisionHistoryLicenseKeyNotAllowed'==_0x5252d0||'revisionHistoryLicenseKeyEvaluationLimit'==_0x5252d0||'revisionHistoryLicenseKeyUsageLimit'==_0x5252d0){delete _0x4d774a[_0x10a5a1],_0x4cde37=_0x5252d0,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x4cde37&&_0x4d774a['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x4cde37&&_0x4d774a['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x4cde37&&_0x4d774a['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x4cde37&&_0x4d774a['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x4cde37&&_0x4d774a['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x4cde37&&_0x4d774a['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x243892=this['repository']['getRevision'](0x0),_0x3640d7=await this['getRevisionDocumentData'](_0x243892),_0xed130e=await this['getRevisionRootsAttributes'](_0x243892);this['_replaceEditorDataWithRevisionData'](_0x3640d7,_0xed130e);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x339994){this['_source']=_0x339994;}async['update'](){const _0x1ea8e5=await this['_source']['getLatestVersion']();if(_0x1ea8e5>this['currentRevision']['toVersion']){await this['_loadState']();const _0x15a71e=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x1ea8e5});_0x15a71e['authors']=_0x15a71e['authorsIds']['map'](_0x56c8ae=>this['editor']['plugins']['get']('Users')['getUser'](_0x56c8ae)),this['currentRevision']['_update'](_0x15a71e);}}async['saveRevision'](_0x4ef420={},_0x559d42=null){const _0x4c5413=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x559d42>this['currentRevision']['toVersion']&&(_0x559d42=null),null===_0x559d42&&(_0x559d42=await this['_source']['getLatestVersion']());const _0x528fef=this['_getFromVersion'](_0x559d42),_0x29ce71=this['buildRevisionData']({'from':_0x528fef,'to':_0x559d42});if(this['currentRevision']['toVersion']<_0x559d42){const _0x521b37=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x559d42,'to':_0x559d42});_0x521b37['authors']=[],_0x521b37['authorsIds']=[],_0x521b37['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x521b37,!0x0),delete _0x521b37['authors'],_0x4c5413['push'](_0x521b37);}_0x4ef420['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x4ef420['name']=_0x4ef420['name']||null,_0x4ef420['id']=_0x4ef420['id']||_0xefa39(),_0x4ef420={..._0x4ef420,..._0x29ce71};const _0x320bcc=this['addRevisionData'](_0x4ef420);_0x4c5413['push'](_0x4ef420);const _0x224583=this['repository']['getIndex'](_0x320bcc);if(0x0!==_0x224583){const _0x4cae7c=this['repository']['getRevision'](_0x224583-0x1);if(_0x4cae7c['fromVersion']!==_0x559d42){const _0x362d9c=this['_revisionDataBuilder']['getData'](_0x559d42,_0x4cae7c['toVersion']),_0x145b35={'id':_0x4cae7c['id'],'diffData':_0x362d9c['diffData'],'authorsIds':_0x362d9c['authorsIds'],'authors':_0x362d9c['authorsIds']['map'](_0x467c03=>this['editor']['plugins']['get']('Users')['getUser'](_0x467c03)),'fromVersion':_0x559d42};_0x4cae7c===this['currentRevision']&&(_0x145b35['createdAt']=new Date(_0x4ef420['createdAt']['getTime']()+0xa)),_0x4cae7c['_update'](_0x145b35,!0x0),delete _0x145b35['authors'],_0x4c5413['push'](_0x145b35);}}if(this['adapter']){for(const _0x81e4b8 of _0x4c5413)this['_bufferUpdate'](_0x81e4b8['id'],_0x81e4b8,!0x0);this['sendBufferedUpdates']();}return _0x320bcc;}['addRevisionData'](_0x4124b0){const _0x5e27be=this['repository']['createRevision'](_0x4124b0);return this['adapter']&&_0x5e27be['on']('_update',(_0x59c2fd,_0xdc164e,_0x2ef9fa)=>{_0x2ef9fa||(this['_bufferUpdate'](_0xdc164e['id'],_0xdc164e,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x5e27be,this['_findInsertionIndex'](_0x5e27be)),_0x5e27be;}async['getRevisionDocumentData'](_0x57ebc1){return await this['_utils']['loadRevisionData'](_0x57ebc1,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x57ebc1);}async['getRevisionRootsAttributes'](_0x16fe12){return await this['_utils']['loadRevisionData'](_0x16fe12,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x16fe12);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x20f00f=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x5e47c5=0x0;_0x5e47c5<_0x20f00f['length'];_0x5e47c5++){const _0x15727f=_0x20f00f[_0x5e47c5];let _0x33949f=!0x1;for(const _0x2ec992 of Object['keys'](_0x15727f))void 0x0===_0x15727f[_0x2ec992]?delete _0x15727f[_0x2ec992]:'id'!==_0x2ec992&&(_0x33949f=!0x0);_0x33949f||(_0x20f00f[_0x5e47c5]=null);}if(_0x20f00f=_0x20f00f['filter'](_0x28cd8b=>null!==_0x28cd8b),!_0x20f00f['length'])return;for(let _0x5976c4=0x0;_0x5976c4<_0x20f00f['length'];_0x5976c4++){const _0x380fe1=_0x20f00f[_0x5976c4];void 0x0!==_0x380fe1['fromVersion']&&void 0x0===_0x380fe1['toVersion']&&(_0x380fe1['toVersion']=this['repository']['getRevision'](_0x380fe1['id'])['toVersion']),void 0x0!==_0x380fe1['toVersion']&&void 0x0===_0x380fe1['fromVersion']&&(_0x380fe1['fromVersion']=this['repository']['getRevision'](_0x380fe1['id'])['fromVersion']);}const _0x1d1034=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x20f00f,_0x1d1034)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x52d56f=>{if(_0x52d56f){for(const _0x4bd7b1 of _0x52d56f)this['setRevisionData']({'id':_0x4bd7b1['id'],'createdAt':_0x4bd7b1['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0x4ee428=null,from:_0x3eb486=null,to:_0x40c57b=null}){_0x3eb486=null!==_0x3eb486?_0x3eb486:_0x4ee428['fromVersion'],_0x40c57b=null!==_0x40c57b?_0x40c57b:_0x4ee428['toVersion'];const _0x13ad2e=this['_revisionDataBuilder']['getData'](_0x3eb486,_0x40c57b),_0x2f2bd6={'diffData':_0x13ad2e['diffData'],'authorsIds':_0x13ad2e['authorsIds'],'fromVersion':_0x3eb486,'toVersion':_0x40c57b};if(!_0x4ee428||_0x40c57b!==_0x4ee428['toVersion']){const _0x2801fe=_0x40c57b-0x1,_0x2e135a=this['_source']['history']['getOperation'](_0x2801fe);_0x2f2bd6['createdAt']=_0x2e135a&&_0x2e135a['createdAt']||new Date();}if(this['_loadedStateData']&&_0x3eb486===this['_loadedStateData']['fromVersion']){for(const _0xc8de72 of this['_loadedStateData']['authors'])_0x2f2bd6['authorsIds']['includes'](_0xc8de72['id'])||_0x2f2bd6['authorsIds']['push'](_0xc8de72['id']);}return _0x2f2bd6;}['_bufferUpdate'](_0x17aebd,_0x401c7e,_0x2663f6){if(this['_bufferedUpdates']['has'](_0x17aebd)){const _0x3fedc7=this['_bufferedUpdates']['get'](_0x17aebd);_0x401c7e=_0x2663f6?{..._0x3fedc7,..._0x401c7e}:{..._0x401c7e,..._0x3fedc7};}this['_bufferedUpdates']['set'](_0x17aebd,_0x401c7e);}['setRevisionData'](_0x4c8e29){const _0x3f0a1e=this['repository']['getRevision'](_0x4c8e29['id']);if(_0x4c8e29['createdAt']&&(_0x4c8e29['createdAt']=new Date(_0x4c8e29['createdAt'])),_0x4c8e29['authorsIds']){const _0x456c77=this['editor']['plugins']['get']('Users');_0x4c8e29['authors']=_0x4c8e29['authorsIds']['map'](_0x311aa1=>_0x456c77['getUser'](_0x311aa1));}_0x3f0a1e['_update'](_0x4c8e29,!0x0);}['_createInitialRevision'](_0x26e75f){const _0x3c5af4=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x3c5af4)this['_initialRevisionId']=_0x3c5af4['id'];else{const _0x1e1555=!this['editor']['model']['document']['roots']['find'](_0x31260a=>this['editor']['model']['hasContent'](_0x31260a)),_0x11e933=this['editor']['plugins']['get']('Users')['me']['id'],_0x2faf52=m(this['editor']['locale'],_0x1e1555?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x26e75f,'to':_0x26e75f,'id':this['_initialRevisionId'],'name':_0x2faf52,'creatorId':_0x11e933});}}['_createCurrentRevision'](_0x2052cc){const _0xa54ff0=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0xa54ff0),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x2052cc,'to':_0x2052cc,'id':_0xa54ff0,'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'](_0xbf5154,_0x5d83bb){let _0x2f84e5=this['editor']['config']['get']('initialData'),_0x58d250=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x2f84e5){_0x2f84e5={};for(const _0x1802b6 of this['editor']['model']['document']['getRootNames']())_0x2f84e5[_0x1802b6]='';}if('string'==typeof _0x2f84e5&&(_0x2f84e5={'main':_0x2f84e5}),void 0x0===_0x58d250){_0x58d250={};for(const _0x48543a of this['editor']['model']['document']['getRootNames']())_0x58d250[_0x48543a]={};}let _0x4f5a66=!0x1;const _0xde5694=Object['keys'](_0x2f84e5),_0x233ec4=Object['keys'](_0xbf5154);for(const _0x117c1f of _0xde5694){if(_0x2f84e5[_0x117c1f]!==_0xbf5154[_0x117c1f]&&''!==_0x2f84e5[_0x117c1f]['trim']()){_0x4f5a66=!0x0;break;}if(!_0x21fc28(_0x58d250[_0x117c1f],_0x5d83bb[_0x117c1f])&&Object['keys'](_0x58d250[_0x117c1f])['length']>0x0){_0x4f5a66=!0x0;break;}}_0x4f5a66||(_0x4f5a66=_0x233ec4['some'](_0x111577=>!this['editor']['model']['document']['getRoot'](_0x111577))),_0x4f5a66&&_0x28dcdd('editor-initial-data-replaced-with-revision-data',{'editorData':_0x2f84e5,'editorRootsAttributes':_0x58d250,'revisionData':_0xbf5154,'revisionRootsAttributes':_0x5d83bb}),this['editor']['config']['set']('initialData',_0xbf5154),this['editor']['config']['set']('rootsAttributes',_0x5d83bb);}['_addPendingAction'](){if(!this['_pendingAction']){const _0xc7726e=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0xc7726e['add'](m(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x1603ca){const _0x40c754=this['repository']['getRevisions']();_0x40c754['reverse']();let _0x4c4ab4=0x0;for(;_0x4c4ab4<_0x40c754['length'];){const _0x5e6c9c=_0x40c754[_0x4c4ab4];if(_0x5e6c9c===this['currentRevision']){_0x4c4ab4++;continue;}if(_0x5e6c9c['id']===this['_initialRevisionId'])break;const _0x291a15=_0x1603ca['toVersion']-_0x5e6c9c['toVersion']||_0x1603ca['fromVersion']-_0x5e6c9c['fromVersion'];if(_0x291a15>0x0)break;if(_0x291a15<0x0)_0x4c4ab4++;else{if(!_0x1603ca['creator']&&_0x5e6c9c['creator'])break;if(_0x5e6c9c['creator']||!_0x1603ca['creator']){if(_0x1603ca['createdAt']>_0x5e6c9c['createdAt'])break;_0x4c4ab4++;}else _0x4c4ab4++;}}return _0x4c4ab4;}['_getFromVersion'](_0x354fad){const _0x9df09d=this['repository']['getRevisions']();_0x9df09d['reverse'](),_0x9df09d['shift']();const _0x4469c1=_0x9df09d['find'](_0x425ef3=>_0x425ef3['toVersion']<=_0x354fad)['toVersion'];return _0x4469c1<this['_startingVersion']?this['_startingVersion']:_0x4469c1;}['_makeRevision']({name:_0x48cb2b,from:_0x176bba,to:_0x43a149,creatorId:_0x2ae5bd,id:_0x167bed}){const _0x1fc7ff=this['buildRevisionData']({'from':_0x176bba,'to':_0x43a149});_0x1fc7ff['name']=_0x48cb2b,_0x1fc7ff['creatorId']=_0x2ae5bd,_0x1fc7ff['id']=_0x167bed;const _0x2b2f9e=this['addRevisionData'](_0x1fc7ff);return this['adapter']&&this['_bufferUpdate'](_0x1fc7ff['id'],_0x1fc7ff,!0x0),_0x2b2f9e;}['_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(_0x26ea60){this['editor']=_0x26ea60,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'](_0x4f1123){this['source']=_0x4f1123;const _0x1643b9=new Map(),_0x16c1a3=new Map(),_0x3229d5=this['editor']['model']['document']['roots']['map'](_0x1a79e7=>_0x1a79e7['rootName']);for(const _0x479c77 of _0x3229d5){const _0x53bb12=this['editor']['model']['document']['getRoot'](_0x479c77),_0x9fbe40=x(_0x53bb12);_0x1643b9['set'](_0x479c77,_0x9fbe40),_0x16c1a3['set'](_0x479c77,Object['fromEntries'](_0x53bb12['getAttributes']()));}const _0x19f898=Array['from'](this['editor']['model']['markers'])['map'](_0x4f7772=>[_0x4f7772['name'],_0x4f7772['getRange']()]),_0x986bfb=this['source']['version'];this['_saveMetaData'](_0x986bfb,_0x1643b9,_0x19f898,_0x16c1a3),this['_startingRevisionId']=this['_revisionId'];const _0x141668=new Map(),_0x5c90e5=new Map();for(const _0x386cdb of _0x3229d5){const _0x571cab=K(_0x386cdb);_0x141668['set'](_0x386cdb,_0x571cab),_0x5c90e5['set'](_0x386cdb,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x141668,[],_0x5c90e5);}['getData'](_0x482aaa,_0x185ac4){if(this['_lastFrom']===_0x482aaa&&this['_lastTo']<=_0x185ac4)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x185ac4,!0x0);else{if(!this['_savedMetaData']['has'](_0x482aaa)){const _0xf218b2=this['_getPreviousFrom'](_0x482aaa);this['_calculateMetaData'](_0xf218b2,_0x482aaa,!0x1);}this['_calculateMetaData'](_0x482aaa,_0x185ac4,!0x0);}return this['_lastFrom']=_0x482aaa,this['_lastTo']=_0x185ac4,this['_getState']();}['loadState'](_0x3b91ff){if(!this['_savedMetaData']['has'](_0x3b91ff['fromVersion'])){const _0x2ec08f=this['_getPreviousFrom'](_0x3b91ff['fromVersion']);this['_calculateMetaData'](_0x2ec08f,_0x3b91ff['fromVersion'],!0x1);}this['_calculateMetaData'](_0x3b91ff['fromVersion'],_0x3b91ff['toVersion'],!0x1);const _0x88e899=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x3b91ff['fromVersion'],this['_lastTo']=_0x3b91ff['toVersion'];for(const _0x45139d in _0x3b91ff['diffData']){const _0x157302=_0x3b91ff['diffData'][_0x45139d]['attachChange'],_0x255a24=_0xadda3d(_0x3b91ff['diffData'][_0x45139d]['attributesBefore'])||{},_0xe6fc24=_0x88e899['_makeModelFromViewString'](_0x3b91ff['diffData'][_0x45139d]['deletions']);_0xe6fc24['rootName']=_0x45139d,_0xe6fc24['_isAttached']=!_0x157302||!_0x157302['isAttached'],_0xe6fc24['isAttached']=()=>_0xe6fc24['_isAttached'],this['_baseRoots']['set'](_0x45139d,_0xe6fc24),this['_baseRootsAttributes']['set'](_0x45139d,_0x255a24),_0x157302&&this['_touchedRoots']['set'](_0x45139d,_0x157302);const _0x340d0e=this['_makeIdsRoot'](_0xe6fc24);this['_baseIdsRoots']['set'](_0x45139d,_0x340d0e);for(const [_0x2733f4,_0x45c48d]of _0xe6fc24['markers']){if(!_0x2733f4['startsWith']('revision:'))continue;const _0x40e2b9=_0x2733f4['split'](':')[0x2];for(const _0x48cc9a of _0x45c48d['getWalker']({'singleCharacters':!0x0})){const _0x52c477=this['_getVidAttributeName'](_0x48cc9a),_0x3c490c='elementEnd'==_0x48cc9a['type']?_0x48cc9a['previousPosition']['path']['slice'](0x0,-0x1):_0x48cc9a['previousPosition']['path'],_0x5b6962=_0x340d0e['getNodeByPath'](_0x3c490c)['getAttribute'](_0x52c477);this['_touched']['set'](_0x5b6962,{'userId':_0x40e2b9});}_0xe6fc24['markers']['delete'](_0x2733f4);}}this['_startingRevisionId']=this['_revisionId'];const _0x523abb=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x393daf=>!this['_touched']['has'](_0x393daf));let _0x591b86=0x0;const _0x1112db=new Map();for(const _0x4877f7 in _0x3b91ff['diffData']){const _0x5390c5=_0x3b91ff['diffData'][_0x4877f7]['attachChange'],_0x5ac59f=_0xadda3d(_0x3b91ff['diffData'][_0x4877f7]['attributesAfter'])||{},_0x4c85c9=_0x88e899['_makeModelFromViewString'](_0x3b91ff['diffData'][_0x4877f7]['insertions']);_0x4c85c9['rootName']=_0x4877f7,_0x4c85c9['_isAttached']=!_0x5390c5||_0x5390c5['isAttached'],_0x4c85c9['isAttached']=()=>_0x4c85c9['_isAttached'],this['_diffRoots']['set'](_0x4877f7,_0x4c85c9),this['_diffRootsAttributes']['set'](_0x4877f7,_0x5ac59f);const _0x284541=this['_makeIdsRoot'](_0x4c85c9,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x4877f7,_0x284541),_0x1112db['set'](_0x4877f7,_0x4c85c9['isAttached']()?_0x5ac59f:{});for(const [_0x5b613a,_0x54912a]of _0x4c85c9['markers']){if(!_0x5b613a['startsWith']('revision:'))continue;const _0x5d4903=_0x5b613a['split'](':')[0x2];for(const _0xae3a65 of _0x54912a['getWalker']({'singleCharacters':!0x0})){const _0x2a6919=this['_getVidAttributeName'](_0xae3a65),_0x37c532=this['_revisionId']++,_0x417639='elementEnd'==_0xae3a65['type']?_0xae3a65['previousPosition']['path']['slice'](0x0,-0x1):_0xae3a65['previousPosition']['path'];_0x284541['getNodeByPath'](_0x417639)['_setAttribute'](_0x2a6919,_0x37c532),this['_touched']['set'](_0x37c532,{'userId':_0x5d4903});}_0x4c85c9['markers']['delete'](_0x5b613a);}for(const _0x278ae0 of this['editor']['model']['createRangeIn'](_0x4c85c9)['getWalker']({'singleCharacters':!0x0})){const _0x55ab07=this['_getVidAttributeName'](_0x278ae0),_0xac09bf='elementEnd'==_0x278ae0['type']?_0x278ae0['previousPosition']['path']['slice'](0x0,-0x1):_0x278ae0['previousPosition']['path'],_0x474aef=_0x284541['getNodeByPath'](_0xac09bf);_0x474aef['getAttribute'](_0x55ab07)>0x0||_0x474aef['_setAttribute'](_0x55ab07,_0x523abb[_0x591b86++]);}for(const [_0x358366,_0x1fd9de]of _0x4c85c9['markers'])_0x358366['startsWith']('revision:')||this['_markers']['set'](_0x358366,_0x1fd9de);}const {roots:_0x499f94}=this['_savedMetaData']['get'](_0x3b91ff['fromVersion']),{roots:_0x193a02}=this['_savedMetaData']['get'](_0x3b91ff['toVersion']),_0x535749=x(_0x499f94['get']('$graveyard'));this['_baseRoots']['set']('$graveyard',_0x535749),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x535749,Number['NEGATIVE_INFINITY']));const _0x51b3e3=x(_0x193a02['get']('$graveyard'));this['_diffRoots']['set']('$graveyard',_0x51b3e3),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x51b3e3));const _0xacd9a0=Array['from'](this['_diffRoots'])['map'](([_0x357228,_0x656044])=>[_0x357228,x(_0x656044)]);this['_saveMetaData'](this['_lastTo'],_0xacd9a0,this['_markers'],_0x1112db);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0x1cb157,_0x15052c,_0x495e02,_0x1a3e5d){const _0x226027=new Map(_0x15052c),_0x1146a4=new Map(_0xadda3d(_0x1a3e5d)),_0xb0241c=new Map();for(const [_0x423568,_0x220d9f]of _0x495e02)_0xb0241c['set'](_0x423568,{'start':_0x220d9f['start']['clone'](),'end':_0x220d9f['end']['clone'](),'rootName':_0x220d9f['root']['rootName']});this['_savedMetaData']['set'](_0x1cb157,{'roots':_0x226027,'markers':_0xb0241c,'rootsAttributes':_0x1146a4});}['_removeMetaData'](_0x3fc7d7){this['_savedMetaData']['delete'](_0x3fc7d7);}['_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'](_0x237755,_0x3cd596=null){let _0x5721fa=null;_0x237755['is']('documentFragment')||(_0x5721fa=new _0x39812c(_0x237755['name'],{'vid_start':null===_0x3cd596?this['_revisionId']++:_0x3cd596++}));const _0x28c8ec=[];for(const _0x3dab47 of _0x237755['getChildren']())if(_0x3dab47['is']('element')){_0x28c8ec['push'](this['_makeIdsRoot'](_0x3dab47,_0x3cd596));const _0x3ad0ae=_0x28c8ec[_0x28c8ec['length']-0x1];null!==_0x3cd596&&(_0x3cd596=_0x3ad0ae['is']('element','$text')?_0x3ad0ae['getAttribute']('vid')+0x1:_0x3ad0ae['getAttribute']('vid_end')+0x1);}else{for(let _0x197f07=0x0;_0x197f07<_0x3dab47['offsetSize'];_0x197f07++)_0x28c8ec['push'](new _0x39812c('$text',{'vid':null===_0x3cd596?this['_revisionId']++:_0x3cd596++}));}if(_0x237755['is']('documentFragment')){const _0x992e82=K(_0x237755['rootName']);return _0x992e82['_insertChild'](0x0,_0x28c8ec),_0x992e82;}return _0x5721fa['_setAttribute']('vid_end',null===_0x3cd596?this['_revisionId']++:_0x3cd596++),_0x5721fa['_insertChild'](0x0,_0x28c8ec),_0x5721fa;}['_calculateMetaData'](_0x4ee247,_0x5e3095,_0x1b1751){this['_reset']();const {roots:_0x25f46e,markers:_0x35c3d5,rootsAttributes:_0x1a2827}=this['_savedMetaData']['get'](_0x4ee247);this['_baseRoots']=new Map(_0x25f46e),this['_baseRootsAttributes']=new Map(_0xadda3d(_0x1a2827));for(const [_0x55edb,_0x1ea9f0]of this['_baseRoots'])if('$graveyard'!==_0x55edb&&(this['_diffRoots']['set'](_0x55edb,x(_0x1ea9f0)),this['_diffRootsAttributes']=new Map(_0xadda3d(_0x1a2827)),_0x1b1751)){const _0x7c5689=this['_revisionId'];this['_idsRoots']['set'](_0x55edb,this['_makeIdsRoot'](_0x1ea9f0)),this['_baseIdsRoots']['set'](_0x55edb,this['_makeIdsRoot'](_0x1ea9f0,_0x7c5689));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',x(this['_baseRoots']['get']('$graveyard'))),_0x1b1751&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x1ade6e,_0x403bcc]of _0x35c3d5){const _0x9ae3b2=this['_baseRoots']['get'](_0x403bcc['rootName']),_0x31f0ea=this['_diffRoots']['get'](_0x403bcc['rootName']),_0x46fd7f=new _0x1474a8(this['_fixPosition'](_0x403bcc['start'],_0x9ae3b2),this['_fixPosition'](_0x403bcc['end'],_0x9ae3b2)),_0x187bd9=this['_fixRange'](_0x46fd7f,_0x31f0ea);_0x9ae3b2['markers']['set'](_0x1ade6e,_0x46fd7f),this['_markers']['set'](_0x1ade6e,_0x187bd9);}this['_applyOperations'](_0x4ee247,_0x5e3095,_0x1b1751);}['_applyOperations'](_0x19ead7,_0x9a391e,_0x17f493){for(const _0x4fb365 of this['source']['getOperations'](_0x19ead7,_0x9a391e))this['_handleOperation'](_0x4fb365,_0x17f493);for(const _0x52872b of this['_diffRoots']['values']())_0x52872b['markers']['clear']();for(const [_0x2edd06,_0xeb9ae9]of this['_markers']){this['_diffRoots']['get'](_0xeb9ae9['root']['rootName'])['markers']['set'](_0x2edd06,_0xeb9ae9['clone']());}const _0x36240f=new Map(),_0x44bf85=new Map();for(const [_0x472e28,_0xd31f59]of this['_diffRoots'])_0x36240f['set'](_0x472e28,x(_0xd31f59)),_0x44bf85['set'](_0x472e28,this['_diffRootsAttributes']['get'](_0x472e28));this['_saveMetaData'](_0x9a391e,_0x36240f,this['_markers'],_0x44bf85);}['_getPreviousFrom'](_0x46496b){const _0x251d3e=Array['from'](this['_savedMetaData']['keys']());_0x251d3e['sort']((_0x3076e3,_0x15f2d7)=>_0x3076e3-_0x15f2d7),_0x251d3e['reverse']();for(const _0x1c46b5 of _0x251d3e)if(_0x1c46b5<_0x46496b)return _0x1c46b5;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x1ecba8,_0x3eb11a){const _0x94f920=Array['from'](_0x3eb11a['markers'])['map'](([_0x1bd74f,_0x4ce912])=>[_0x1bd74f,this['_fixRange'](_0x4ce912,_0x1ecba8)]);_0x1ecba8['markers']=new Map(_0x94f920);}['_transformMarkers'](_0x38106f){for(const _0x68519b of this['_markers']['values']()){const _0x259bca=_0x68519b['getTransformedByOperation'](_0x38106f),_0x5c7637=_0x1474a8['_createFromRanges'](_0x259bca);_0x68519b['start']=_0x5c7637['start'],_0x68519b['end']=_0x5c7637['end'];}}['_handleOperation'](_0x55a5e0,_0x4a23ba){if('addRoot'!=_0x55a5e0['type']&&'detachRoot'!=_0x55a5e0['type']){if('insert'==_0x55a5e0['type']){const _0x51bf3c=_0x55a5e0['position']['root']['rootName'];this['_diffRoots']['has'](_0x51bf3c)||(this['_diffRoots']['set'](_0x51bf3c,K(_0x51bf3c,!0x0)),this['_diffRootsAttributes']['set'](_0x51bf3c,{}),_0x4a23ba&&this['_idsRoots']['set'](_0x51bf3c,K(_0x51bf3c,!0x0)));}else{if('addRootAttribute'==_0x55a5e0['type']||'removeRootAttribute'==_0x55a5e0['type']||'changeRootAttribute'==_0x55a5e0['type'])return void this['_handleRootAttributeOperation'](_0x55a5e0);'marker'==_0x55a5e0['type']&&this['_handleMarkerOperation'](_0x55a5e0);}if('marker'!==_0x55a5e0['type']){const _0x3948eb=this['_cloneOperation'](_0x55a5e0,this['_diffRoots']);_0x3948eb['_execute'](),this['_transformMarkers'](_0x3948eb);}if(_0x4a23ba)switch(_0x55a5e0['type']){case'insert':this['_handleInsertOperation'](_0x55a5e0);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x55a5e0);break;case'merge':this['_handleMergeOperation'](_0x55a5e0);break;case'split':this['_handleSplitOperation'](_0x55a5e0);}}else this['_handleRootOperation'](_0x55a5e0,_0x4a23ba);}['_cloneOperation'](_0x31bd35,_0x17cca7){const _0x43ba33=_0x31bd35['clone']();return _0x43ba33['_authorId']=_0x31bd35['_authorId'],this['_fixOperation'](_0x43ba33,_0x17cca7),_0x43ba33;}['_getBaseVids'](_0x526fe9){return _0x526fe9['map'](_0x3f059b=>{const _0x3a07c1=this['_getVidAttributeName'](_0x3f059b);return Number(_0x3f059b['item']['getAttribute'](_0x3a07c1));});}['_generateTape'](_0x2ae66d,_0x4a2c7d){if(_0x2ae66d['is']('element','$text'))_0x4a2c7d['push']({'item':_0x2ae66d,'type':'text'});else{_0x2ae66d['is']('element')&&_0x4a2c7d['push']({'item':_0x2ae66d,'type':'elementStart'});for(const _0x3edc24 of _0x2ae66d['getChildren']())this['_generateTape'](_0x3edc24,_0x4a2c7d);_0x2ae66d['is']('element')&&_0x4a2c7d['push']({'item':_0x2ae66d,'type':'elementEnd'});}return _0x4a2c7d;}['_getState'](){const _0xfa4b63=new Map(this['_touched']),_0x479f5e=new Map(_0xfa4b63),_0x475d86=new Map(),_0x581f9e={'insertions':{},'deletions':{}},_0x1c13ba={'insertions':{},'deletions':{}},_0x3d3a6b=new Map(),_0xffb8eb=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0xffb8eb['delete']('$graveyard');for(const _0x3356f2 of _0xffb8eb){const _0x23201c=this['_diffRoots']['get'](_0x3356f2)||K(_0x3356f2,!0x1),_0x43d5e3=this['_baseRoots']['get'](_0x3356f2)||K(_0x3356f2,!0x1);_0x23201c['isAttached']()||_0x43d5e3['isAttached']()?(_0x581f9e['insertions'][_0x3356f2]=x(_0x23201c),_0x581f9e['deletions'][_0x3356f2]=x(_0x43d5e3),this['_copyMarkers'](_0x581f9e['deletions'][_0x3356f2],_0x43d5e3),this['_copyMarkers'](_0x581f9e['insertions'][_0x3356f2],_0x23201c),_0x1c13ba['insertions'][_0x3356f2]=this['_generateTape'](this['_idsRoots']['get'](_0x3356f2),[]),_0x1c13ba['deletions'][_0x3356f2]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x3356f2)||K(_0x3356f2,!0x1),[])):_0xffb8eb['delete'](_0x3356f2);}for(const _0x2c2794 of _0xffb8eb){const _0x2833d0=_0x1c13ba['insertions'][_0x2c2794];for(const _0x2dc0ea of _0x2833d0){const _0x53b45b=this['_getVidAttributeName'](_0x2dc0ea),_0x4fd530=_0x2dc0ea['item']['getAttribute'](_0x53b45b);_0x479f5e['delete'](_0x4fd530),_0x4fd530>=this['_startingRevisionId']&&_0x475d86['set'](_0x4fd530,_0xfa4b63['get'](_0x4fd530));}}for(const _0x2af78f of _0xffb8eb){const _0x31c382=_0x1c13ba['insertions'][_0x2af78f],_0x2486d5=this['_getBaseVids'](_0x1c13ba['deletions'][_0x2af78f]);let _0xf6af98=0x0;for(const _0x5db13b of _0x31c382){const _0x264edc=this['_getVidAttributeName'](_0x5db13b),_0x1ef0b3=_0x5db13b['item']['getAttribute'](_0x264edc);if(!_0x475d86['has'](_0x1ef0b3)&&!_0x3d3a6b['has'](_0x1ef0b3)){if(_0x479f5e['has'](_0x1ef0b3))_0xf6af98++;else{if(_0x1ef0b3!=_0x2486d5[_0xf6af98]){const _0x203328=_0xfa4b63['get'](_0x1ef0b3)||_0xfa4b63['get'](_0x2486d5[_0xf6af98]);for(;_0x1ef0b3!=_0x2486d5[_0xf6af98];)_0x479f5e['has'](_0x2486d5[_0xf6af98])||(_0x3d3a6b['set'](_0x2486d5[_0xf6af98],_0x203328),_0xfa4b63['set'](_0x2486d5[_0xf6af98],_0x203328)),_0xf6af98++;}_0xf6af98++;}}}}for(const _0x11ab80 of _0xffb8eb){const _0x4c9b8c=_0x1c13ba['insertions'][_0x11ab80];for(const _0x223af0 of _0x4c9b8c){const _0xe202f1=this['_getVidAttributeName'](_0x223af0),_0x5e1490=_0x223af0['item']['getAttribute'](_0xe202f1);if(_0x3d3a6b['has'](_0x5e1490)){const _0xc40e8c=_0x3d3a6b['get'](_0x5e1490);_0x479f5e['has'](_0x5e1490)||_0x479f5e['set'](_0x5e1490,{..._0xc40e8c}),_0x475d86['set'](_0x5e1490,{..._0xc40e8c});}}}for(const _0x584ca2 of _0x479f5e['keys']())_0x584ca2>=this['_startingRevisionId']&&_0x479f5e['delete'](_0x584ca2);const _0x12021d=new Map();for(const _0x1e658d of _0xffb8eb){let _0x126a25=_0x1c13ba['insertions'][_0x1e658d];for(const _0x226e68 of _0x126a25)if(_0x226e68['item']['is']('element','tableCell')){const _0x6018d2=this['_getVidAttributeName'](_0x226e68),_0x2950eb=_0x226e68['item']['getAttribute'](_0x6018d2);if(_0x475d86['has'](_0x2950eb)){const _0x277865=_0x226e68['item']['parent']['parent']['getAttribute']('vid_start'),_0x20a32b=_0x12021d['get'](_0x277865)||new Set();_0x20a32b['add'](_0x475d86['get'](_0x2950eb)['userId']),_0x12021d['set'](_0x277865,_0x20a32b);}}_0x126a25=_0x1c13ba['deletions'][_0x1e658d];for(const _0xcae134 of _0x126a25)if(_0xcae134['item']['is']('element','tableCell')){const _0x5e87c0=this['_getVidAttributeName'](_0xcae134),_0x461cc4=_0xcae134['item']['getAttribute'](_0x5e87c0);if(_0x479f5e['has'](_0x461cc4)){const _0x4434d6=_0xcae134['item']['parent']['parent']['getAttribute']('vid_start'),_0x5c769a=_0x12021d['get'](_0x4434d6)||new Set();_0x5c769a['add'](_0x479f5e['get'](_0x461cc4)['userId']),_0x12021d['set'](_0x4434d6,_0x5c769a);}}for(const _0x189e86 of _0x12021d['keys']())(_0x475d86['has'](_0x189e86)||_0x479f5e['has'](_0x189e86))&&_0x12021d['delete'](_0x189e86);}for(const _0x39f488 of _0xffb8eb){const _0x581eec=_0x1c13ba['insertions'][_0x39f488];let _0x3e317b=null,_0x4ad4ea=null;for(const _0x344283 of _0x581eec){const _0x9ada8e=this['_getVidAttributeName'](_0x344283),_0x57de65=_0x344283['item']['getAttribute'](_0x9ada8e),_0x14485d=_0x12021d['get'](_0x57de65);_0x14485d&&'elementStart'==_0x344283['type']&&(_0x3e317b=Array['from'](_0x14485d)[0x0],_0x4ad4ea=_0x344283['item']['getAttribute']('vid_end')),_0x3e317b&&(_0x479f5e['set'](_0x57de65,{'userId':_0x3e317b}),_0x475d86['set'](_0x57de65,{'userId':_0x3e317b})),_0x57de65==_0x4ad4ea&&(_0x3e317b=null,_0x4ad4ea=null);}}const _0x315e5c={},_0x4fd422=new Set();for(const _0x2345f1 of _0xffb8eb){const _0x538297=_0x581f9e['deletions'][_0x2345f1],_0x2cc6b1=_0x581f9e['insertions'][_0x2345f1];for(const {userId:_0x3e62e0}of this['_touchedMarkers']['values']())null!==_0x3e62e0&&_0x4fd422['add'](_0x3e62e0);for(const {userId:_0x4424fe}of this['_touchedRoots']['values']())null!==_0x4424fe&&_0x4fd422['add'](_0x4424fe);this['_markChanges'](_0x2cc6b1,_0x1c13ba['insertions'][_0x2345f1],_0x475d86,'insertion',_0x4fd422),this['_markChanges'](_0x538297,_0x1c13ba['deletions'][_0x2345f1],_0x479f5e,'deletion',_0x4fd422),_0x315e5c[_0x2345f1]={'insertions':this['_prepareViewToSave'](_0x2cc6b1),'deletions':this['_prepareViewToSave'](_0x538297),'attachChange':this['_touchedRoots']['get'](_0x2345f1)||null,'attributesBefore':_0xadda3d(this['_baseRootsAttributes']['get'](_0x2345f1))||{},'attributesAfter':_0xadda3d(this['_diffRootsAttributes']['get'](_0x2345f1))};}return{'diffData':_0x315e5c,'authorsIds':Array['from'](_0x4fd422)};}['_processRootBeforeSave'](_0x530d82){for(const [,_0x399e50]of _0x530d82['markers']){const _0x5aa8b9=_0x399e50['start']['getAncestors']()['filter'](_0x1c1056=>'tableCell'==_0x1c1056['name']);for(const _0x5cceb5 of _0x5aa8b9)0x1==_0x5cceb5['childCount']&&_0x5cceb5['getChild'](0x0)['is']('element','paragraph')&&_0x5cceb5['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x5d711c){this['_processRootBeforeSave'](_0x5d711c);const _0x2103f8=this['editor']['data']['toView'](_0x5d711c,{}),_0x5dfc9d=Array['from'](_0x2103f8['getChildren']())['map'](_0x75ae56=>this['_getViewJson'](_0x75ae56));return JSON['stringify'](_0x5dfc9d);}['_getViewJson'](_0x31e5b5){if(_0x31e5b5['is']('$text'))return _0x31e5b5['data'];{const _0x38f5a2=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0x40b711=_0x31e5b5,_0x461bb2=this['editor']['data']['htmlProcessor']['domConverter'],_0x5e99bb={'type':_0x38f5a2['_getTypeCharForViewElement'](_0x40b711),'name':_0x40b711['name'],'attributes':Array['from'](_0x40b711['getAttributes']()),'children':Array['from'](_0x40b711['getChildren']())['map'](_0x37c71e=>this['_getViewJson'](_0x37c71e))};if(_0x31e5b5['is']('uiElement')&&'$comment'!=_0x31e5b5['name']){const _0x9d1ea8=_0x31e5b5['render'](_0x461bb2['domDocument'],_0x461bb2);_0x5e99bb['children']['push'](_0x9d1ea8['outerHTML']);}else{if(_0x31e5b5['is']('rawElement')){const _0x433dd1=_0x461bb2['domDocument']['createElement'](_0x40b711['name']);_0x31e5b5['render'](_0x433dd1,_0x461bb2),_0x5e99bb['children']['push'](_0x433dd1['innerHTML']);}}const _0x4a2399=Array['from'](_0x40b711['getCustomProperties']());_0x4a2399['length']>0x0&&(_0x5e99bb['customProperties']=_0x4a2399);const _0x576c62=_0x40b711['getFillerOffset']();return null!==_0x576c62&&(_0x5e99bb['fillerOffset']=_0x576c62),_0x5e99bb;}}['_markChanges'](_0x595801,_0x4d0195,_0x1b2ecc,_0xaa40de,_0x5d8655){let _0xb5e926=null,_0x58aa89=null,_0x1540c2=0x0;const _0x5a7ad8=this['editor']['model'];for(let _0x58e0bb=0x0;_0x58e0bb<_0x4d0195['length'];_0x58e0bb++){const _0x50375e=this['_getVidAttributeName'](_0x4d0195[_0x58e0bb]),_0x247b9d=_0x4d0195[_0x58e0bb]['item']['getAttribute'](_0x50375e),_0x1f859f=_0x1b2ecc['get'](_0x247b9d),_0x3a5ef3=_0x58e0bb==_0x4d0195['length']-0x1;(!_0xb5e926&&_0x1f859f&&(_0xb5e926=_0x1f859f,_0x58aa89=_0x4d0195[_0x58e0bb]),_0xb5e926&&(!_0x1f859f||_0x1f859f['userId']!=_0xb5e926['userId']))&&(_0x3ed823(_0x1f859f,N(_0x58aa89,_0x595801,_0x5a7ad8),N(_0x4d0195[_0x58e0bb],_0x595801,_0x5a7ad8)),_0xb5e926=_0x1f859f||null,_0x58aa89=_0x1f859f?_0x4d0195[_0x58e0bb]:null),_0xb5e926&&_0x3a5ef3&&_0x3ed823(_0x1f859f,N(_0x58aa89,_0x595801,_0x5a7ad8),P(_0x4d0195[_0x58e0bb],_0x595801,_0x5a7ad8));}function _0x3ed823(_0x353536,_0x40b5b9,_0x16eb5c){const _0x46c8c3=_0xb5e926['userId'],_0x18dab6='revision:'+_0xaa40de+':'+_0x46c8c3+':'+_0x1540c2++,_0x2a10ff=_0x5a7ad8['createRange'](_0x40b5b9,_0x16eb5c);_0x595801['markers']['set'](_0x18dab6,_0x2a10ff),null!==_0x46c8c3&&_0x5d8655['add'](_0x46c8c3);}}['_getVidAttributeName'](_0x319d77){switch(_0x319d77['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x53ddd8,_0xdb2f54){_0x53ddd8['baseVersion']=null;for(const _0x2a8749 in _0x53ddd8){const _0x43cd15=_0x53ddd8[_0x2a8749];if(_0x43cd15 instanceof _0x5273bc){const _0x3155a5=_0xdb2f54['get'](_0x43cd15['root']['rootName']);_0x53ddd8[_0x2a8749]=this['_fixPosition'](_0x43cd15,_0x3155a5);}if(_0x43cd15 instanceof _0x1474a8){const _0x1d85fd=_0xdb2f54['get'](_0x43cd15['root']['rootName']);_0x53ddd8[_0x2a8749]=this['_fixRange'](_0x43cd15,_0x1d85fd);}'root'===_0x2a8749&&(_0x53ddd8['root']=_0xdb2f54['get'](_0x53ddd8['root']['rootName']));}}['_fixRange'](_0x214fad,_0x4aa16a){return this['editor']['model']['createRange'](this['_fixPosition'](_0x214fad['start'],_0x4aa16a),this['_fixPosition'](_0x214fad['end'],_0x4aa16a));}['_fixPosition'](_0x5d3109,_0x744f6a){return this['editor']['model']['createPositionFromPath'](_0x744f6a,_0x5d3109['path'],_0x5d3109['stickiness']);}['_handleInsertOperation'](_0x5edc0c){const _0x2b703f=this['_idsRoots']['get'](_0x5edc0c['position']['root']['rootName']),_0x4b273e=this['_fixPosition'](_0x5edc0c['position'],_0x2b703f),_0x52e2f3=null===_0x5edc0c['_authorId']?null:_0x5edc0c['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x1edb1a=_0x4b273e['parent'],_0x13be3a=this['_revisionId'],_0x44a51e=[];for(const _0x5aa8d1 of _0x5edc0c['nodes'])if(_0x5aa8d1['is']('element'))_0x44a51e['push'](this['_makeIdsRoot'](_0x5aa8d1));else{for(let _0x5e322c=0x0;_0x5e322c<_0x5aa8d1['offsetSize'];_0x5e322c++)_0x44a51e['push'](new _0x39812c('$text',{'vid':this['_revisionId']++}));}const _0x11da70=this['_revisionId'];for(let _0x2fea9c=_0x13be3a;_0x2fea9c<_0x11da70;_0x2fea9c++)this['_touched']['set'](_0x2fea9c,{'userId':_0x52e2f3});_0x1edb1a['_insertChild'](_0x4b273e['offset'],_0x44a51e);}['_handleMoveOperation'](_0x24af5f){(_0x24af5f=this['_cloneOperation'](_0x24af5f,this['_idsRoots']))['_execute']();const _0x1b3091=null===_0x24af5f['_authorId']?null:_0x24af5f['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x1b103a=_0x24af5f['getMovedRangeStart'](),_0x3b5434=_0x1b103a['parent'],_0x3fb061=_0x1b103a['offset'];!function _0x314b1d(_0x546819,_0x4ec841,_0x5e74ef,_0x43ec29){for(let _0x582575=_0x5e74ef;_0x582575<_0x43ec29;_0x582575++){const _0xc66710=_0x4ec841['getChild'](_0x582575);_0xc66710['is']('element','$text')?_0x546819['set'](_0xc66710['getAttribute']('vid'),{'userId':_0x1b3091}):(_0x546819['set'](_0xc66710['getAttribute']('vid_start'),{'userId':_0x1b3091}),_0x314b1d(_0x546819,_0xc66710,0x0,_0xc66710['childCount']),_0x546819['set'](_0xc66710['getAttribute']('vid_end'),{'userId':_0x1b3091}));}}(this['_touched'],_0x3b5434,_0x3fb061,_0x3fb061+_0x24af5f['howMany']);}['_handleMergeOperation'](_0x4bd4cc){const _0x2b0983=null===(_0x4bd4cc=this['_cloneOperation'](_0x4bd4cc,this['_idsRoots']))['_authorId']?null:_0x4bd4cc['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x1848ac=_0x4bd4cc['targetPosition']['parent'],_0x4c5d65=_0x4bd4cc['sourcePosition']['parent'],_0x59f4f1=_0x1848ac['getAttribute']('vid_end'),_0x4f5c8e=_0x4c5d65['getAttribute']('vid_start');_0x1848ac['_setAttribute']('vid_end',_0x4c5d65['getAttribute']('vid_end')),_0x4c5d65['_setAttribute']('vid_end',_0x59f4f1),this['_touched']['set'](_0x4f5c8e,{'userId':_0x2b0983}),this['_touched']['set'](_0x59f4f1,{'userId':_0x2b0983}),_0x4bd4cc['_execute']();}['_handleSplitOperation'](_0x322727){const _0x366a4a=null===(_0x322727=this['_cloneOperation'](_0x322727,this['_idsRoots']))['_authorId']?null:_0x322727['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0xdb4b33=_0x322727['graveyardPosition'],_0x63e1b7=_0x322727['splitPosition']['parent'];_0x322727['_execute']();const _0x36670e=_0x63e1b7['getAttribute']('vid_end'),_0x481996=_0x322727['insertionPosition']['nodeAfter'];if(_0xdb4b33){const _0x27741d=_0x481996['getAttribute']('vid_end'),_0x16174e=_0x63e1b7['getAttribute']('vid_end');_0x63e1b7['_setAttribute']('vid_end',_0x27741d),_0x481996['_setAttribute']('vid_end',_0x16174e),this['_touched']['set'](_0x63e1b7['getAttribute']('vid_end'),{'userId':_0x366a4a}),this['_touched']['set'](_0x481996['getAttribute']('vid_start'),{'userId':_0x366a4a});}else{const _0x23c1c3=this['_revisionId']++,_0x48a760=this['_revisionId']++;_0x63e1b7['_setAttribute']('vid_end',_0x23c1c3),_0x481996['_setAttribute']('vid_start',_0x48a760),_0x481996['_setAttribute']('vid_end',_0x36670e),this['_touched']['set'](_0x23c1c3,{'userId':_0x366a4a}),this['_touched']['set'](_0x48a760,{'userId':_0x366a4a});}}['_handleMarkerOperation'](_0x33c16b){if(!_0x33c16b['affectsData'])return;const _0x2a7872=(_0x33c16b=this['_cloneOperation'](_0x33c16b,this['_diffRoots']))['oldRange']?_0x33c16b['oldRange']['root']:null,_0x2022e5=_0x33c16b['newRange']?_0x33c16b['newRange']['root']:null;_0x2a7872&&this['_markers']['delete'](_0x33c16b['name']),_0x2022e5&&this['_markers']['set'](_0x33c16b['name'],_0x33c16b['newRange']['clone']());const _0x4d6d1a=null===_0x33c16b['_authorId']?null:_0x33c16b['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x9aa64=_0x33c16b['name'];if(!this['_touchedMarkers']['has'](_0x9aa64))return void this['_touchedMarkers']['set'](_0x9aa64,{'range':_0x33c16b['oldRange'],'userId':_0x4d6d1a});const _0xb3a1ec=this['_touchedMarkers']['get'](_0x9aa64),_0x34cf19=_0xb3a1ec['range'],_0x49ce3a=_0x33c16b['newRange'];null==_0x34cf19&&null==_0x49ce3a||_0x34cf19&&_0x49ce3a&&_0x34cf19['isEqual'](_0x49ce3a)?this['_touchedMarkers']['delete'](_0x33c16b['name']):_0xb3a1ec['userId']=_0x4d6d1a;}['_handleRootOperation'](_0x496230,_0x15169a){this['_diffRoots']['has'](_0x496230['rootName'])?this['_diffRoots']['get'](_0x496230['rootName'])['_isAttached']=_0x496230['isAdd']:(this['_diffRoots']['set'](_0x496230['rootName'],K(_0x496230['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x496230['rootName'],{}),_0x15169a&&this['_idsRoots']['set'](_0x496230['rootName'],K(_0x496230['rootName'],!0x0)));const _0x5d625b=null===_0x496230['_authorId']?null:_0x496230['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x55cba9=this['_touchedRoots']['get'](_0x496230['rootName']);_0x55cba9&&_0x55cba9['userId']===_0x5d625b?this['_touchedRoots']['delete'](_0x496230['rootName']):this['_touchedRoots']['set'](_0x496230['rootName'],{'userId':_0x5d625b,'isAttached':_0x496230['isAdd']});}['_handleRootAttributeOperation'](_0x1b7a74){const _0x116918=this['_diffRootsAttributes']['get'](_0x1b7a74['root']['rootName']);null===_0x1b7a74['newValue']?delete _0x116918[_0x1b7a74['key']]:_0x116918[_0x1b7a74['key']]=_0x1b7a74['newValue'];}}function x(_0x18c186){const _0x48b675=K(_0x18c186['rootName'],_0x18c186['isAttached']());for(const _0x4e7424 of _0x18c186['getChildren']()){const _0x505965=_0x4e7424['_clone'](!0x0);_0x48b675['_appendChild'](_0x505965);}return _0x48b675;}function K(_0x442c0d,_0x38c3fc=!0x0){const _0xa1adfc=new _0xa6ead0();return _0xa1adfc['rootName']=_0x442c0d,_0xa1adfc['_isAttached']=_0x38c3fc,_0xa1adfc['isAttached']=()=>_0xa1adfc['_isAttached'],_0xa1adfc;}function N(_0x295a82,_0xf66722,_0x198310){const _0x28f14e='elementEnd'==_0x295a82['type']?_0x198310['createPositionAt'](_0x295a82['item'],'end'):_0x198310['createPositionBefore'](_0x295a82['item']);return _0x198310['createPositionFromPath'](_0xf66722,_0x28f14e['path'],_0x28f14e['stickiness']);}function P(_0x2c0175,_0x2513b6,_0x2e522c){const _0x291c4d='elementStart'==_0x2c0175['type']?_0x2e522c['createPositionAt'](_0x2c0175['item'],0x0):_0x2e522c['createPositionAfter'](_0x2c0175['item']);return _0x2e522c['createPositionFromPath'](_0x2513b6,_0x291c4d['path'],_0x291c4d['stickiness']);}class he extends/* #__PURE__ -- @preserve */
25
- _0x2e53b2(_0x584d23){['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x125920,_0x4678f8){super(_0x125920),this['focusTracker']=new _0x1e7ab2(),this['keystrokes']=new _0x248400(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x4678f8),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'](),_0x4935d8({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x525d77=_0x4637e9=>_0x4637e9['stopPropagation']();this['keystrokes']['set']('arrowright',_0x525d77),this['keystrokes']['set']('arrowleft',_0x525d77),this['keystrokes']['set']('arrowup',_0x525d77),this['keystrokes']['set']('arrowdown',_0x525d77);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0xcbadb0){this['revisionNameInputView']['fieldView']['element']['value']=_0xcbadb0['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x4f5458){const _0x235a9f=new et(this['locale'],ti),_0x70fa8a=_0x235a9f['fieldView'];_0x70fa8a['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x1b4d29=m(this['locale'],'Name\x20of\x20the\x20revision');return!_0x4f5458&&(_0x1b4d29+='\x20('+m(this['locale'],'optional')+')'),(_0x235a9f['label']=_0x1b4d29,_0x70fa8a['on']('input',()=>{this['revisionNameInputValue']=_0x70fa8a['element']['value']['trim']();}),_0x235a9f);}}class l extends _0xde4b58{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h];}['_saveRevisionFormView'];['init'](){const _0x5b72d3=this['editor'],_0x33a4af=_0x5b72d3['plugins']['get']('RevisionTracker');_0x5b72d3['ui']['componentFactory']['add']('revisionHistory',_0x5707aa=>{const _0x309d26=_0x4c9aaf(_0x5707aa),_0x2972df=_0x309d26['panelView']['children'],_0x456669=new _0x277762(_0x5707aa),_0x14a9c2=new _0x9334aa(_0x5707aa),_0xac83c5=this['_createSaveRevisionButton'](_0x56b48b),_0xe3385=new _0x9334aa(_0x5707aa),_0x3c3546=this['_createOpenRevisionButton'](_0x56b48b);return _0x309d26['bind']('isEnabled')['to'](_0x33a4af,'isReady',_0x33a4af,'isEnabled',_0x5b72d3,'isReadOnly',(_0x41cdea,_0x1020f1,_0x3fc69e)=>_0x41cdea&&_0x1020f1&&!_0x3fc69e),_0x309d26['buttonView']['set']({'icon':_0x173b8e,'label':m(_0x5707aa,'Revision\x20history'),'tooltip':!0x0}),_0xac83c5['set']({'withText':!0x0,'role':'menuitem'}),_0x3c3546['set']({'withText':!0x0,'role':'menuitem'}),this['listenTo'](_0x3c3546,'execute',()=>{_0x309d26['isOpen']=!0x1,_0x5b72d3['editing']['view']['focus']();},{'priority':'low'}),_0x14a9c2['children']['add'](_0xac83c5),_0xe3385['children']['add'](_0x3c3546),_0x456669['role']='menu',_0x456669['items']['addMany']([_0x14a9c2,_0xe3385]),_0x2972df['add'](_0x456669),_0x309d26;}),_0x5b72d3['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x228d40=this['editor'],_0x4d2d0c=_0x228d40['locale'],_0x50227b=_0x228d40['plugins']['get']('RevisionTracker'),_0x49c996=new _0x27668a(_0x4d2d0c),_0x4f67cd=new _0x432d32(_0x4d2d0c);_0x49c996['bind']('isEnabled')['to'](_0x50227b,'isReady',_0x50227b,'isEnabled',_0x228d40,'isReadOnly',(_0x2a3d3c,_0x100d82,_0x47cceb)=>_0x2a3d3c&&_0x100d82&&!_0x47cceb),_0x49c996['buttonView']['set']({'icon':_0x173b8e,'label':m(_0x4d2d0c,'Revision\x20history')});const _0x405a57=new _0x594efc(_0x4d2d0c,_0x49c996),_0x5d9f9e=this['_createSaveRevisionButton'](_0x426818);_0x5d9f9e['delegate']('execute')['to'](_0x49c996),_0x405a57['children']['add'](_0x5d9f9e),_0x4f67cd['items']['add'](_0x405a57);const _0x1657fb=new _0x594efc(_0x4d2d0c,_0x49c996),_0x1bfdb8=this['_createOpenRevisionButton'](_0x426818);return _0x1bfdb8['delegate']('execute')['to'](_0x49c996),_0x1657fb['children']['add'](_0x1bfdb8),_0x4f67cd['items']['add'](_0x1657fb),_0x49c996['panelView']['children']['add'](_0x4f67cd),_0x49c996;}['_createSaveRevisionButton'](_0x19764a){const _0x241a9a=this['editor'],_0x321f2d=_0x241a9a['plugins']['get']('RevisionTracker'),_0x2559a8=new _0x19764a(_0x241a9a['locale']);return _0x2559a8['set']({'label':m(_0x241a9a['locale'],'Save\x20current\x20revision')}),_0x2559a8['bind']('isEnabled')['to'](_0x321f2d,'isReady',_0x321f2d,'isEnabled',_0x241a9a,'isReadOnly',(_0x3c3017,_0x2286c4,_0x1d297b)=>_0x3c3017&&_0x2286c4&&!_0x1d297b),this['listenTo'](_0x2559a8,'execute',()=>{this['_showDialog']();}),_0x2559a8;}['_createOpenRevisionButton'](_0x40a1bc){const _0x429738=this['editor'],_0x4ee8d6=_0x429738['plugins']['get']('RevisionTracker'),_0x8199cc=new _0x40a1bc(_0x429738['locale']);return _0x8199cc['set']({'label':m(_0x429738['locale'],'Open\x20revision\x20history')}),_0x8199cc['bind']('isEnabled')['to'](_0x4ee8d6,'isReady',_0x429738,'isReadOnly',(_0xa5baf7,_0x403c54)=>_0xa5baf7&&!_0x403c54),this['listenTo'](_0x8199cc,'execute',()=>{_0x429738['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x8199cc;}['_showDialog'](){const _0x318cda=this['editor'],_0xfeede7=_0x318cda['locale'],_0x5499d1=_0x318cda['plugins']['get']('Dialog'),_0x20942a=_0x318cda['plugins']['get']('RevisionTracker');function _0x229143(_0x431bb2){_0x318cda['config']['get']('revisionHistory.requireRevisionName')&&''===_0x431bb2['revisionName']?_0x431bb2['revisionNameInputView']['errorText']=m(_0xfeede7,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x318cda['plugins']['get'](h)['saveRevision']({'name':_0x431bb2['revisionName']}),_0x5499d1['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x229143(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x5499d1['show']({'id':'revisionSave','title':m(_0xfeede7,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':m(_0x318cda['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x5499d1['hide']()},{'label':m(_0x318cda['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x268d97){_0x268d97['bind']('isEnabled')['to'](_0x20942a,'isReady',_0x20942a,'isEnabled',_0x318cda,'isReadOnly',(_0x4c9daf,_0x37822e,_0x567b40)=>_0x4c9daf&&_0x37822e&&!_0x567b40);},'onExecute':()=>_0x229143(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x30b69a=this['editor'],_0x2cb2d0=_0x30b69a['locale'];this['_saveRevisionFormView']=new he(_0x2cb2d0,_0x30b69a['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class q extends _0x584d23{['changeId'];['_model'];constructor(_0x3c9781,_0x904145){super(_0x3c9781),this['_model']=_0x904145,this['changeId']=_0x904145['id'];const _0x4f031b=this['bindTemplate'],_0x278dce=m(_0x3c9781,_0x904145['data']['isSuggestion']?'Suggested\x20by':'add'==_0x904145['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x904145['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x4f031b['to']('type',_0x33e6fe=>'ck-revision-change__'+_0x33e6fe)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x278dce}]},{'text':'\x20'+_0x904145['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class z extends/* #__PURE__ -- @preserve */
26
- _0x8df1b4(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x2335c1){super(),this['id']=_0x2335c1['id']||_0xefa39(),this['author']=_0x2335c1['author'],this['type']=_0x2335c1['type'],this['data']=_0x2335c1['data']||{},this['rootName']=_0x2335c1['rootName'],this['set']('createdAt',_0x2335c1['createdAt']);}['toJSON'](){return{'id':this['id'],'authorId':this['author']['id'],'type':this['type'],'data':this['data'],'createdAt':this['createdAt']};}}class G{['newRevisionId'];['oldRevisionId'];['changes'];constructor(_0x501f75,_0x47a27a){this['newRevisionId']=_0x501f75,this['oldRevisionId']=_0x47a27a,this['changes']=new _0x4fc9f6();}['_setChanges'](_0x392fba){for(const _0x4e515a of _0x392fba)this['changes']['add'](_0x4e515a);}}class u extends _0xde4b58{['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[_0x405575,_0x5f3958,S,$];}constructor(_0x4188bc){super(_0x4188bc),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',(_0x47d235,_0x527f0c,_0x254b88)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x5a2136=>{for(const _0x288a7e of this['editor']['editing']['view']['document']['roots'])_0x254b88?_0x5a2136['removeClass']('ck-editor__editable__overlay',_0x288a7e):_0x5a2136['addClass']('ck-editor__editable__overlay',_0x288a7e);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0xddfbea=>null!==_0xddfbea),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x2e101d,_0x2b2153,_0x45acfd)=>_0x2e101d&&_0x45acfd?_0x2b2153['changes']['getIndex'](_0x45acfd):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x15c572,_0x1be50d)=>_0x15c572?_0x1be50d['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0x5f3958);}['init'](){const _0x57aacf=this['editor'],_0x59b423=new ShowChangeCommand(_0x57aacf,{'direction':'backward'}),_0x2d60f1=new ShowChangeCommand(_0x57aacf,{'direction':'forward'});(_0x57aacf['commands']['add']('showPreviousChange',_0x59b423),_0x57aacf['commands']['add']('showNextChange',_0x2d60f1),_0x57aacf['commands']['add']('restoreRevision',new RestoreRevisionCommand(_0x57aacf)),this['on']('change:numberOfChanges',()=>{_0x59b423['refresh'](),_0x2d60f1['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x57aacf['enableReadOnlyMode']('revision-viewer'),_0x57aacf['plugins']['has']('WidgetToolbarRepository'))&&_0x57aacf['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x4500f9){return await this['_utils']['loadRevisionData'](_0x4500f9,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x4500f9);}async['getRevisionRootsAttributes'](_0x27eda5){return await this['_utils']['loadRevisionData'](_0x27eda5,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x27eda5);}async['compare'](_0x50ab96,_0x502465,_0x234530=!0x1){if(!this['isEnabled'])return;const _0x595c4b=this['diff'],_0x2f2b5a=this['repository'],_0x38f289='string'==typeof _0x50ab96?_0x2f2b5a['getRevision'](_0x50ab96):_0x50ab96,_0x54fb7e='string'==typeof _0x502465?_0x2f2b5a['getRevision'](_0x502465):_0x502465,_0x1c19a5=_0x38f289['id'],_0x51fdd4=_0x54fb7e?_0x54fb7e['id']:null;if(!_0x234530&&this['diff']&&this['diff']['newRevisionId']===_0x1c19a5&&this['diff']['oldRevisionId']===_0x51fdd4)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new G(_0x1c19a5,_0x51fdd4);const _0x1895ce=this['_getRevisionsRange'](_0x38f289,_0x54fb7e,!0x0)['map'](_0x3c676e=>this['_utils']['loadRevisionData'](_0x3c676e,this['adapter']));return _0x1895ce['push'](new Promise(_0x57958d=>{setTimeout(_0x57958d,0x14);})),Promise['all'](_0x1895ce)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x19e0d9=this['_getDiff'](_0x1c19a5,_0x51fdd4);for(const _0x3580f0 of _0x19e0d9['changes'])this['_changeIdToChange']['set'](_0x3580f0['id'],_0x3580f0);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x95e9f2=>{for(const _0x1da430 of this['editor']['model']['document']['getRootNames']())_0x95e9f2['detachRoot'](_0x1da430);for(const _0x34aa93 of Object['keys'](_0x19e0d9['model'])){const _0x55fbed=_0x95e9f2['addRoot'](_0x34aa93);for(const _0x127eb9 of Object['keys'](_0x19e0d9['attributes'][_0x34aa93]))_0x95e9f2['setAttribute'](_0x127eb9,_0x19e0d9['attributes'][_0x34aa93][_0x127eb9],_0x55fbed);_0x95e9f2['insert'](_0x19e0d9['model'][_0x34aa93],_0x55fbed,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x19e0d9['changes'])),this['isReady']=!0x0;})['catch'](_0x3f0142=>{console['error'](_0x3f0142),this['_cleanUp'](),_0x595c4b&&(this['diff']=_0x595c4b),this['isReady']=!0x0;});}['addRevisionData'](_0x259723,_0x1764b2){const _0x750d20=this['repository']['createRevision'](_0x259723);return _0x750d20['on']('_update',(_0x36ef9c,_0x3c2e84,_0x506de0)=>_0x1764b2(_0x3c2e84,_0x506de0,_0x750d20)),this['repository']['addRevision'](_0x750d20),_0x750d20;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x3e148c=>{for(const _0x5c23a5 of this['editor']['model']['document']['getRootNames']())_0x3e148c['detachRoot'](_0x5c23a5);});}['_sortAndFilterDiffChanges'](_0x14163a){const _0x505de3=[],_0x47a5c3=new Map();for(const _0x569403 of this['editor']['model']['document']['getRootNames']()){const _0x493fdd=this['editor']['editing']['view']['getDomRoot'](_0x569403);if(!_0x493fdd)continue;const _0x2327d8=_0x493fdd['getClientRects']()['item'](0x0);_0x2327d8&&(_0x505de3['push'](_0x569403),_0x47a5c3['set'](_0x569403,_0x2327d8));}return _0x505de3['sort']((_0x39bbc1,_0x3f161e)=>{const _0x170fc2=_0x47a5c3['get'](_0x39bbc1),_0xb4741d=_0x47a5c3['get'](_0x3f161e);return _0x170fc2['y']-_0xb4741d['y']||_0x170fc2['x']-_0xb4741d['x'];}),(_0x14163a=_0x14163a['filter'](_0x169d5a=>_0x505de3['includes'](_0x169d5a['rootName'])))['sort']((_0x3685dd,_0x271223)=>_0x505de3['indexOf'](_0x3685dd['rootName'])-_0x505de3['indexOf'](_0x271223['rootName'])),_0x14163a;}['_makeTape'](_0xabb255){const _0x38f6e3=Array['from'](_0xabb255['markers'])['filter'](([_0x893df,_0x540d3d])=>_0x893df['startsWith']('revision:')&&!_0x540d3d['isCollapsed']),_0x399fea=Array['from'](this['editor']['model']['createRangeIn'](_0xabb255)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x38f6e3['length'])for(const _0x487ef7 of _0x399fea){const [_0x396bb9,_0x2ed1f3]=_0x38f6e3[0x0],[,_0x1f91cb,_0x229aa9]=_0x396bb9['split'](':');if(_0x2ed1f3['end']['isEqual'](_0x487ef7['nextPosition'])&&_0x38f6e3['shift'](),(_0x487ef7['previousPosition']['isEqual'](_0x2ed1f3['start'])||_0x487ef7['previousPosition']['isAfter'](_0x2ed1f3['start']))&&('insertion'==_0x1f91cb?_0x487ef7['isAdded']={'userId':_0x229aa9}:'deletion'==_0x1f91cb&&(_0x487ef7['isRemoved']={'userId':_0x229aa9})),0x0==_0x38f6e3['length'])break;}return _0x399fea;}['_refreshStartEndIndex'](_0x63f346){const _0x26e232=new Map();for(let _0xf7deb6=0x0;_0xf7deb6<_0x63f346['length'];_0xf7deb6++)'text'===_0x63f346[_0xf7deb6]['type']?(_0x63f346[_0xf7deb6]['item']['startIndex']=_0xf7deb6,_0x63f346[_0xf7deb6]['item']['endIndex']=_0xf7deb6):('elementStart'===_0x63f346[_0xf7deb6]['type']?_0x63f346[_0xf7deb6]['item']['startIndex']=_0xf7deb6:'elementEnd'===_0x63f346[_0xf7deb6]['type']&&(_0x63f346[_0xf7deb6]['item']['endIndex']=_0xf7deb6),_0x26e232['set'](_0x63f346[_0xf7deb6]['id'],_0xf7deb6));for(const _0x305516 of _0x26e232['values']())'elementStart'===_0x63f346[_0x305516]['type']?_0x63f346[_0x305516]['item']['endIndex']=_0x26e232['get'](_0x63f346[_0x305516]['pairId']):'elementEnd'===_0x63f346[_0x305516]['type']&&(_0x63f346[_0x305516]['item']['startIndex']=_0x26e232['get'](_0x63f346[_0x305516]['pairId']));}['_processTape'](_0x266076){for(let _0x3384ce=0x0;_0x3384ce<_0x266076['length'];_0x3384ce++){if('elementStart'===_0x266076[_0x3384ce]['type'])_0x266076[_0x3384ce]['item']['startIndex']=_0x3384ce;else{if('elementEnd'===_0x266076[_0x3384ce]['type']){_0x266076[_0x3384ce]['item']['endIndex']=_0x3384ce;const _0x72d8fc=_0x266076[_0x3384ce]['item']['startIndex'];_0x266076[_0x72d8fc]['pairId']=_0x266076[_0x3384ce]['id'],_0x266076[_0x3384ce]['pairId']=_0x266076[_0x72d8fc]['id'];}else _0x266076[_0x3384ce]['item']['startIndex']=_0x3384ce,_0x266076[_0x3384ce]['item']['endIndex']=_0x3384ce,_0x266076[_0x3384ce]['pairId']=null;}_0x266076[_0x3384ce]['markersStart']||(_0x266076[_0x3384ce]['markersStart']=[],_0x266076[_0x3384ce]['markersEnd']=[]);}}['_markInsertions'](_0x2cb660,_0x26217b){const _0xe1805e=_0x2cb660['filter'](_0x39823a=>!_0x39823a['isAdded']);for(let _0x2c39a7=0x0;_0x2c39a7<_0x26217b['length'];_0x2c39a7++)_0x26217b[_0x2c39a7]['isAdded']&&(_0xe1805e[_0x2c39a7]['isAdded']=_0x26217b[_0x2c39a7]['isAdded']);}['_getDiff'](_0x3d93b8,_0x402e6b=null){const _0x1b8483=this['repository']['getRevision'](_0x3d93b8),_0x3a824b=_0x402e6b?this['repository']['getRevision'](_0x402e6b):null,_0x224e8a=this['_getRevisionsRange'](_0x1b8483,_0x3a824b),_0x19d501=_0x224e8a[_0x224e8a['length']-0x1],_0x29f267=new Map(),_0x58b754={'model':{},'attributes':{},'changes':[]},_0x541a20=new Set(),_0x473096=new Map();for(let _0x223fcb=_0x224e8a['length']-0x1;_0x223fcb>=0x0;_0x223fcb--){const _0x445b35=_0x224e8a[_0x223fcb];for(const _0x261009 of Object['keys'](_0x445b35['diffData']))if(_0x445b35['diffData'][_0x261009]['attachChange']){const _0x1face7=_0x445b35['diffData'][_0x261009]['attachChange'];_0x1face7['isAttached']?(_0x541a20['add'](_0x261009),_0x473096['has'](_0x261009)&&_0x473096['get'](_0x261009)['userId']==_0x1face7['userId']?_0x473096['delete'](_0x261009):_0x473096['set'](_0x261009,_0x1face7)):_0x473096['has'](_0x261009)?(_0x541a20['delete'](_0x261009),_0x473096['delete'](_0x261009)):(_0x541a20['add'](_0x261009),_0x473096['set'](_0x261009,_0x1face7));}else _0x541a20['add'](_0x261009);}for(const _0x1e2396 of _0x541a20){const _0x2f0008=_0x473096['has'](_0x1e2396)&&!_0x473096['get'](_0x1e2396)['isAttached'];let _0x226db7=_0x2f0008?_0x224e8a['length']-0x1:0x0;const _0x84437b=_0x2f0008?-0x1:0x1;for(;_0x224e8a[_0x226db7];){const _0xd65d93=_0x224e8a[_0x226db7];if(_0xd65d93['diffData'][_0x1e2396]){const _0x46b24b=_0x2f0008?_0xd65d93['diffData'][_0x1e2396]['attributesBefore']:_0xd65d93['diffData'][_0x1e2396]['attributesAfter'];_0x58b754['attributes'][_0x1e2396]=_0x46b24b?_0xadda3d(_0x46b24b):{};break;}_0x226db7+=_0x84437b;}}for(const _0x293370 of _0x224e8a){_0x293370['model']={};for(const _0x33ecf3 of _0x293370['authors'])_0x29f267['set'](_0x33ecf3['id'],_0x33ecf3);for(const _0x1b7ec4 of _0x541a20){const _0x3b5d35=_0x293370['diffData'][_0x1b7ec4]?_0x293370['diffData'][_0x1b7ec4]['insertions']:'[]',_0x46ac88=_0x293370['diffData'][_0x1b7ec4]?_0x293370['diffData'][_0x1b7ec4]['deletions']:'[]';_0x293370['model'][_0x1b7ec4]={'insertions':this['_utils']['_makeModelFromViewString'](_0x3b5d35),'deletions':this['_utils']['_makeModelFromViewString'](_0x46ac88)};}}for(const _0x4efa68 of _0x541a20){let _0x575dd3=null,_0x13d893=0x0;const _0x4f21a1=new Map(Array['from'](_0x1b8483['model'][_0x4efa68]['insertions']['markers'])['filter'](([_0x2bf6da])=>!_0x2bf6da['startsWith']('revision:')));let _0x242c9b=0x0;for(const _0x1ccadd of _0x224e8a){const _0x567d68=this['_makeTape'](_0x1ccadd['model'][_0x4efa68]['insertions']);_0x1ccadd==_0x1b8483?(_0x575dd3=_0x567d68,_0x13d893=_0x575dd3['length'],_0x575dd3['forEach'](_0x4959e9=>{_0x4959e9['id']=_0x242c9b++;}),this['_processTape'](_0x575dd3)):this['_markInsertions'](_0x575dd3,_0x567d68);const _0x364edb=_0x575dd3['filter'](_0x29c16f=>!_0x29c16f['isAdded'])['map'](_0x3cc407=>_0x3cc407['id']);let _0x443177=0x0;const _0x39ac40=this['_makeTape'](_0x1ccadd['model'][_0x4efa68]['deletions']);_0x39ac40['forEach'](_0x4ded40=>{_0x4ded40['isRemoved']?_0x4ded40['id']=_0x13d893++:_0x4ded40['id']=_0x364edb[_0x443177++];}),this['_processTape'](_0x39ac40),this['_setDistance'](_0x575dd3,'isAdded'),this['_setDistance'](_0x39ac40,'isRemoved'),_0x1ccadd==_0x1b8483&&this['_markMarkers'](_0x575dd3,_0x4f21a1),_0x575dd3=this['_joinTapes'](_0x575dd3,_0x39ac40),this['_refreshStartEndIndex'](_0x575dd3),this['_setDistance'](_0x575dd3,'isRemoved');}_0x575dd3=_0x575dd3['filter'](_0x5687dd=>!(_0x5687dd['isAdded']&&_0x5687dd['isRemoved']));const _0x4ae3e6=new Map(_0x19d501['model'][_0x4efa68]['deletions']['markers']),_0x59e87a=new Set(_0x4f21a1['keys']());for(const _0xca55b7 of _0x4ae3e6['keys']())_0x59e87a['delete'](_0xca55b7);this['_markSuggestions'](_0x575dd3,_0x59e87a),this['_fixObsoleteTags'](_0x575dd3),_0x575dd3=this['_removeMissingPairs'](_0x575dd3),_0x575dd3=this['_markMismatchedRemovedTags'](_0x575dd3),_0x575dd3=this['_removeUnsupportedChanges'](_0x575dd3);const {root:_0x2c04d1,changes:_0x466373}=this['_makeModelFromTape'](_0x575dd3,_0x29f267,_0x4efa68);_0x58b754['model'][_0x4efa68]=_0x2c04d1;const _0x53a74c=_0x473096['get'](_0x4efa68);if(_0x53a74c){const _0x532ef6=_0x29f267['get'](_0x53a74c['userId']),_0x3b2fde=new z({'author':_0x532ef6,'type':_0x53a74c['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x4efa68});_0x466373['unshift'](_0x3b2fde),_0x58b754['attributes'][_0x4efa68]['revisionHistoryAttachChange']=_0x3b2fde['id'];}_0x58b754['changes']=_0x58b754['changes']['concat'](_0x466373);}return _0x58b754;}['_markMarkers'](_0x3c257a,_0x405059){for(let _0x4e9bee=0x0;_0x4e9bee<_0x3c257a['length'];_0x4e9bee++)for(const [_0x237fea,_0x7b17a5]of _0x405059)!_0x7b17a5['isCollapsed']&&_0x7b17a5['start']['isEqual'](_0x3c257a[_0x4e9bee]['previousPosition'])&&_0x3c257a[_0x4e9bee]['markersStart']['push'](_0x237fea),_0x7b17a5['end']['isEqual'](_0x3c257a[_0x4e9bee]['nextPosition'])&&_0x3c257a[_0x4e9bee]['markersEnd']['push'](_0x237fea);}['_joinTapes'](_0x3349c6,_0x5155d2){let _0x19274d=[],_0x432015=0x0,_0x2be771=0x0;for(;_0x432015<_0x3349c6['length']||_0x2be771<_0x5155d2['length'];){const _0x4ac142=_0x3349c6[_0x432015]||{},_0x41a95c=_0x5155d2[_0x2be771]||{};if(_0x4ac142['id']==_0x41a95c['id'])_0x432015++,_0x2be771++,_0x19274d['push'](_0x4ac142);else{if(_0x41a95c['isRemoved']&&_0x4ac142['isAdded']){const {commonTape:_0x162940,iEnd:_0x50352a,jEnd:_0x505f2d}=this['_threeWayMerge'](_0x3349c6,_0x432015,_0x5155d2,_0x2be771);_0x19274d=_0x19274d['concat'](_0x162940),_0x432015=_0x50352a,_0x2be771=_0x505f2d;}else _0x41a95c['isRemoved']?(_0x2be771++,_0x19274d['push'](_0x41a95c)):(_0x432015++,_0x19274d['push'](_0x4ac142));}}return _0x19274d;}['_markSuggestions'](_0x3a281c,_0x4eccfd){const _0x2a518b=[];for(let _0x30d06d=0x0;_0x30d06d<_0x3a281c['length'];_0x30d06d++){for(let _0x5c4543=0x0;_0x5c4543<_0x3a281c[_0x30d06d]['markersStart']['length'];_0x5c4543++){const _0xffcaac=_0x3a281c[_0x30d06d]['markersStart'][_0x5c4543];if(!_0x4eccfd['has'](_0xffcaac))continue;const {group:_0x4eaeac,type:_0x52f94e,authorId:_0x156f9a}=_0x5a5e50(_0xffcaac);'revision-suggestion'!=_0x4eaeac||'insertion'!=_0x52f94e&&'deletion'!=_0x52f94e||(_0x2a518b['unshift']({'type':_0x52f94e,'name':_0xffcaac,'userId':_0x156f9a}),_0x3a281c[_0x30d06d]['markersStart']['splice'](_0x5c4543,0x1),_0x5c4543--);}_0x1ada5f(_0x3a281c[_0x30d06d]);for(let _0xd9bc2a=0x0;_0xd9bc2a<_0x3a281c[_0x30d06d]['markersEnd']['length'];_0xd9bc2a++){const _0x5d0999=_0x3a281c[_0x30d06d]['markersEnd'][_0xd9bc2a];if(!_0x4eccfd['has'](_0x5d0999))continue;const {group:_0x3902a9,type:_0x3437d5}=_0x5a5e50(_0x5d0999);if('revision-suggestion'!=_0x3902a9||'insertion'!=_0x3437d5&&'deletion'!=_0x3437d5)continue;_0x3a281c[_0x30d06d]['markersEnd']['splice'](_0xd9bc2a,0x1),_0xd9bc2a--;const _0x244fdf=_0x2a518b['findIndex'](_0x253592=>_0x253592['name']==_0x5d0999);_0x244fdf>-0x1&&_0x2a518b['splice'](_0x244fdf,0x1);}}function _0x5a5e50(_0x267212){const _0x3cc075=_0x267212['split'](':');return{'group':_0x3cc075[0x0],'type':_0x3cc075[0x1],'subType':_0x3cc075['length']>=0x5?_0x3cc075[0x2]:null,'id':_0x3cc075['length']<0x5?_0x3cc075[0x2]:_0x3cc075[0x3],'authorId':_0x3cc075['length']<0x5?_0x3cc075[0x3]:_0x3cc075[0x4],'markerCount':0x6==_0x3cc075['length']?_0x3cc075[0x5]:null};}function _0x1ada5f(_0x5dfccb){for(let _0x4a4093=0x0;_0x4a4093<_0x2a518b['length'];_0x4a4093++){if(_0x5dfccb['isAdded']&&'insertion'==_0x2a518b[_0x4a4093]['type']&&_0x5dfccb['isAdded']['userId']==_0x2a518b[_0x4a4093]['userId'])return _0x5dfccb['isAddSuggestion']=_0x2a518b[_0x4a4093],void delete _0x5dfccb['isAdded'];if(!_0x5dfccb['isAdded']&&!_0x5dfccb['isRemoved']&&'deletion'==_0x2a518b[_0x4a4093]['type'])return void(_0x5dfccb['isRemoveSuggestion']=_0x2a518b[_0x4a4093]);}}}['_setDistance'](_0x4e5387,_0x23067e){let _0x1b4805=0x0,_0x1d0857=!0x1;const _0x5a1d0d=new Map();for(const _0x31ef9d of _0x4e5387)_0x31ef9d[_0x23067e]?_0x1d0857&&(_0x1b4805++,_0x1d0857=!0x1):(_0x1b4805++,_0x1d0857=!0x0),_0x5a1d0d['set'](_0x31ef9d['id'],_0x1b4805);for(let _0x4d5fae=0x0;_0x4d5fae<_0x4e5387['length'];_0x4d5fae++){if('isRemoved'==_0x23067e&&_0x4e5387[_0x4d5fae]['isAdded']||'isAdded'==_0x23067e&&_0x4e5387[_0x4d5fae]['isRemoved'])continue;if('text'==_0x4e5387[_0x4d5fae]['type']){_0x4e5387[_0x4d5fae]['distance']=0x0;continue;}const _0x2fdcd6=_0x5a1d0d['get'](_0x4e5387[_0x4d5fae]['pairId']),_0x4f90e1=_0x5a1d0d['get'](_0x4e5387[_0x4d5fae]['id']);_0x4e5387[_0x4d5fae]['distance']=_0x2fdcd6-_0x4f90e1;}}['_getRevisionsRange'](_0x46b6d5,_0xaaadda,_0x19c1bc=!0x1){const _0x340f92=[];let _0x380c93=this['repository']['getIndex'](_0x46b6d5),_0xfa9a9c=this['repository']['getIndex'](_0xaaadda);for(-0x1==_0xfa9a9c&&(_0xfa9a9c=this['repository']['_revisions']['length'],_0x19c1bc=!0x1);_0x380c93<_0xfa9a9c;)_0x340f92['push'](this['repository']['getRevision'](_0x380c93)),_0x380c93++;return _0x19c1bc&&_0x340f92['push'](this['repository']['getRevision'](_0x380c93)),_0x340f92;}['_threeWayMerge'](_0x1db2d6,_0x5035d4,_0x39ef38,_0x1c1b42){const _0x2f866a=this['editor']['model']['schema'];let _0x5093df=_0x5035d4;for(;_0x1db2d6[_0x5093df]&&_0x1db2d6[_0x5093df]['isAdded'];)_0x5093df++;let _0xabd3a3=_0x1c1b42;for(;_0x39ef38[_0xabd3a3]&&_0x39ef38[_0xabd3a3]['isRemoved'];)_0xabd3a3++;_0x16b88d(_0x1db2d6,_0x5035d4,_0x5093df),_0x16b88d(_0x39ef38,_0x1c1b42,_0xabd3a3);const _0x588bb4=_0x39ef38['slice'](_0x1c1b42,_0xabd3a3)['concat'](_0x1db2d6['slice'](_0x5035d4,_0x5093df));return _0x588bb4['sort']((_0x3212b6,_0xe1f872)=>_0x3212b6['side']!=_0xe1f872['side']?_0x3212b6['side']-_0xe1f872['side']:_0x3212b6['level']!=_0xe1f872['level']?_0x3212b6['level']-_0xe1f872['level']:_0x3212b6['distance']!=_0xe1f872['distance']?_0xe1f872['distance']-_0x3212b6['distance']:!!_0x3212b6['isAdded']!=!!_0xe1f872['isAdded']?-0x1==_0x3212b6['side']||0x0==_0x3212b6['side']?_0x3212b6['isAdded']?-0x1:0x1:_0x3212b6['isAdded']?0x1:-0x1:_0x3212b6['index']-_0xe1f872['index']),{'commonTape':_0x588bb4,'iEnd':_0x5093df,'jEnd':_0xabd3a3};function _0x16b88d(_0x526a23,_0x366b09,_0x944a86){let _0x5ae45c=-0x1,_0x215716=Number['POSITIVE_INFINITY'],_0x1bfd3e=!0x0;for(let _0x27ed7b=_0x366b09;_0x27ed7b<_0x944a86;_0x27ed7b++)if(_0x2f866a['isInline'](_0x526a23[_0x27ed7b]['item'])||(_0x1bfd3e=!0x1),_0x526a23[_0x27ed7b]['item']['startIndex']<_0x366b09&&(_0x5ae45c=_0x27ed7b),_0x526a23[_0x27ed7b]['item']['endIndex']>=_0x944a86){_0x215716=_0x27ed7b;break;}_0x1bfd3e&&(_0x5ae45c=_0x944a86-0x1);for(let _0x2c9427=_0x366b09;_0x2c9427<_0x944a86;_0x2c9427++)_0x526a23[_0x2c9427]['side']=_0x2c9427<=_0x5ae45c?-0x1:_0x2c9427<_0x215716?0x0:0x1,_0x526a23[_0x2c9427]['index']=_0x2c9427;let _0x1cc9e5=0x0;for(let _0x186283=_0x366b09;_0x186283<=_0x5ae45c;_0x186283++)0x0==_0x526a23[_0x186283]['distance']?_0x526a23[_0x186283]['level']=_0x1cc9e5:(_0x1cc9e5++,_0x526a23[_0x186283]['level']=_0x1cc9e5,_0x1cc9e5++);for(let _0x30bfd9=_0x366b09;_0x30bfd9<_0x944a86;_0x30bfd9++)0x0==_0x526a23[_0x30bfd9]['side']&&(_0x526a23[_0x30bfd9]['level']=_0x1cc9e5);_0x1cc9e5=0x0;for(let _0x1b5b83=_0x944a86-0x1;_0x1b5b83>=_0x215716;_0x1b5b83--)0x0==_0x526a23[_0x1b5b83]['distance']?_0x526a23[_0x1b5b83]['level']=_0x1cc9e5:(_0x1cc9e5--,_0x526a23[_0x1b5b83]['level']=_0x1cc9e5,_0x1cc9e5--);}}['_fixObsoleteTags'](_0x48d975){const _0x1ade8c=new Map(),_0xa2e947=this['editor']['model']['schema'];for(let _0x2869a3=0x1;_0x2869a3<_0x48d975['length'];_0x2869a3++){let _0x3e3fd1,_0x1499df,_0x40f521;const _0x45f183=_0x48d975[_0x2869a3],_0x5a3b93=_0x48d975[_0x2869a3-0x1];if('text'==_0x45f183['type'])continue;if(_0x45f183['type']!=_0x5a3b93['type'])continue;if(!_0xa2e947['isBlock'](_0x5a3b93['item'])||_0xa2e947['isLimit'](_0x5a3b93['item']))continue;if(!_0xa2e947['isBlock'](_0x45f183['item'])||_0xa2e947['isLimit'](_0x45f183['item']))continue;if((_0x48d975[_0x2869a3]['isAdded']||_0x48d975[_0x2869a3]['isAddSuggestion'])&&_0x48d975[_0x2869a3-0x1]['isRemoved'])_0x3e3fd1=_0x48d975[_0x2869a3],_0x1499df=_0x48d975[_0x2869a3-0x1],_0x40f521=_0x2869a3-0x1;else{if(!_0x48d975[_0x2869a3]['isRemoved']||!_0x48d975[_0x2869a3-0x1]['isAdded']&&!_0x48d975[_0x2869a3-0x1]['isAddSuggestion'])continue;_0x3e3fd1=_0x48d975[_0x2869a3-0x1],_0x1499df=_0x48d975[_0x2869a3],_0x40f521=_0x2869a3;}const _0x223561=_0x3e3fd1['level']==_0x1499df['level'],_0x5dcec6=Math['abs'](_0x3e3fd1['level'])<Math['abs'](_0x1499df['level'])&&0x0==_0x1499df['distance'];(_0x223561||_0x5dcec6)&&(_0x1ade8c['set'](_0x1499df['id'],_0x3e3fd1['id']),_0x48d975['splice'](_0x40f521,0x1),_0x2869a3--,_0x3e3fd1['isAdded']=!0x1);}for(let _0x3dac13=0x0;_0x3dac13<_0x48d975['length'];_0x3dac13++)_0x1ade8c['has'](_0x48d975[_0x3dac13]['pairId'])&&(_0x48d975[_0x3dac13]['pairId']=_0x1ade8c['get'](_0x48d975[_0x3dac13]['pairId']));}['_removeMissingPairs'](_0x1ae0cb){const _0x4b7b33=new Set(_0x1ae0cb['map'](_0x520ffc=>_0x520ffc['id']));for(let _0x1779c6=0x0;_0x1779c6<_0x1ae0cb['length'];_0x1779c6++)_0x4b7b33['has'](_0x1ae0cb[_0x1779c6]['pairId'])||0x0==_0x1ae0cb[_0x1779c6]['distance']||(_0x1ae0cb[_0x1779c6]['isIncorrect']=!0x0);return _0x1ae0cb['filter'](_0x1daba5=>!_0x1daba5['isIncorrect']);}['_markMismatchedRemovedTags'](_0x3a7b50){const _0x713e1b=new Set();for(let _0x49c1c9=0x0;_0x49c1c9<_0x3a7b50['length'];_0x49c1c9++){if(_0x713e1b['has'](_0x3a7b50[_0x49c1c9]['id'])&&_0x3a7b50[_0x49c1c9]['isRemoved']&&(_0x3a7b50[_0x49c1c9]['isIncorrect']=!0x0),_0x3a7b50[_0x49c1c9]['isIncorrect'])continue;if(0x0==_0x3a7b50[_0x49c1c9]['distance'])continue;if('elementStart'!=_0x3a7b50[_0x49c1c9]['type'])continue;if(null==_0x3a7b50[_0x49c1c9]['pairId'])continue;let _0x3fe499=_0x49c1c9+0x1,_0x597b25=0x0;for(;_0x3a7b50[_0x3fe499]['id']!=_0x3a7b50[_0x49c1c9]['pairId'];)'elementStart'==_0x3a7b50[_0x3fe499]['type']?_0x597b25++:'elementEnd'==_0x3a7b50[_0x3fe499]['type']&&_0x597b25--,_0x3fe499++;if(0x0!=_0x597b25){if(_0x3a7b50[_0x49c1c9]['isRemoved'])_0x3a7b50[_0x49c1c9]['isIncorrect']=!0x0;else{for(;_0x3fe499!=_0x49c1c9;)_0x3a7b50[_0x3fe499]['isRemoved']&&0x0!=_0x3a7b50[_0x3fe499]['distance']&&(_0x3a7b50[_0x3fe499]['isIncorrect']=!0x0,_0x713e1b['add'](_0x3a7b50[_0x3fe499]['pairId'])),_0x3fe499--;}}}return _0x3a7b50['filter'](_0x5de244=>!_0x5de244['isIncorrect']);}['_removeUnsupportedChanges'](_0x515b41){const _0x1aff8e=this['editor']['model']['schema'];for(let _0x5187e9=0x0;_0x5187e9<_0x515b41['length'];_0x5187e9++){if(!(_0x515b41[_0x5187e9]['isAdded']||_0x515b41[_0x5187e9]['isAddSuggestion']||_0x515b41[_0x5187e9]['isRemoved']||_0x515b41[_0x5187e9]['isRemoveSuggestion']))continue;if(0x0==_0x515b41[_0x5187e9]['distance'])continue;const _0x8a9d7=_0x515b41[_0x5187e9]['item'];_0x1aff8e['isBlock'](_0x8a9d7)||_0x1aff8e['isLimit'](_0x8a9d7)||(_0x515b41[_0x5187e9]['isAdded']&&delete _0x515b41[_0x5187e9]['isAdded'],_0x515b41[_0x5187e9]['isAddSuggestion']&&delete _0x515b41[_0x5187e9]['isAddSuggestion'],_0x515b41[_0x5187e9]['isRemoveSuggestion']&&delete _0x515b41[_0x5187e9]['isRemoveSuggestion'],_0x515b41[_0x5187e9]['isRemoved']&&(_0x515b41[_0x5187e9]['isIncorrect']=!0x0));}return _0x515b41['filter'](_0x14c85f=>!_0x14c85f['isIncorrect']);}['_makeModelFromTape'](_0x587e55,_0x5a4b6f,_0x64dd3c){const _0x5dcfb0=new _0xa6ead0(),_0x4dd24f=[],_0x2ae8cc=new Map(),_0x3a8c9d=this['editor']['model'],_0x21c71c=_0x3a8c9d['schema'],_0x2946e3=[_0x5dcfb0],_0x5a7f01={},_0x1b400a={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x2ce3c7=null;const _0x41ba2f=[0x0];for(let _0x330cbc=0x0;_0x330cbc<_0x587e55['length'];_0x330cbc++)if('elementStart'===_0x587e55[_0x330cbc]['type']){_0x587e55[_0x330cbc]['previousPosition']=_0x3a8c9d['createPositionFromPath'](_0x5dcfb0,_0x41ba2f);const _0x9c82ca=new _0x39812c(_0x587e55[_0x330cbc]['item']['name'],_0x587e55[_0x330cbc]['item']['getAttributes']());_0x2946e3[0x0]['_appendChild'](_0x9c82ca),_0x41ba2f['push'](0x0),_0x2946e3['unshift'](_0x9c82ca),_0x587e55[_0x330cbc]['nextPosition']=_0x3a8c9d['createPositionFromPath'](_0x5dcfb0,_0x41ba2f);}else'elementEnd'===_0x587e55[_0x330cbc]['type']?(_0x2946e3['shift'](),_0x587e55[_0x330cbc]['previousPosition']=_0x3a8c9d['createPositionFromPath'](_0x5dcfb0,_0x41ba2f),_0x41ba2f['pop'](),_0x41ba2f[_0x41ba2f['length']-0x1]++,_0x587e55[_0x330cbc]['nextPosition']=_0x3a8c9d['createPositionFromPath'](_0x5dcfb0,_0x41ba2f)):(_0x587e55[_0x330cbc]['previousPosition']=_0x3a8c9d['createPositionFromPath'](_0x5dcfb0,_0x41ba2f),_0x2ce3c7?_0x2ce3c7['_data']+=_0x587e55[_0x330cbc]['item']['data']:_0x2ce3c7=new _0x58927f(_0x587e55[_0x330cbc]['item']['data'],_0x587e55[_0x330cbc]['item']['getAttributes']()),_0x587e55[_0x330cbc+0x1]&&'text'===_0x587e55[_0x330cbc+0x1]['type']&&_0x4cea60(_0x2ce3c7,_0x587e55[_0x330cbc+0x1]['item'])||(_0x2946e3[0x0]['_appendChild'](_0x2ce3c7),_0x2ce3c7=null),_0x41ba2f[_0x41ba2f['length']-0x1]+=_0x587e55[_0x330cbc]['item']['offsetSize'],_0x587e55[_0x330cbc]['nextPosition']=_0x3a8c9d['createPositionFromPath'](_0x5dcfb0,_0x41ba2f));for(let _0x47d089=0x0;_0x47d089<_0x587e55['length'];_0x47d089++){const _0x8541d7=_0x587e55[_0x47d089]['previousPosition'],_0x25be19=_0x587e55[_0x47d089]['nextPosition'];for(const _0x3043e4 of _0x587e55[_0x47d089]['markersStart'])_0x2ae8cc['set'](_0x3043e4,{'start':_0x8541d7,'end':null});_0x46af74('isRemoveSuggestion',_0x47d089,_0x8541d7,_0x25be19),_0x46af74('isAddSuggestion',_0x47d089,_0x8541d7,_0x25be19),_0x46af74('isRemoved',_0x47d089,_0x8541d7,_0x25be19),_0x46af74('isAdded',_0x47d089,_0x8541d7,_0x25be19);for(const _0x3c220c of _0x587e55[_0x47d089]['markersEnd']){const _0x31a57a=_0x2ae8cc['get'](_0x3c220c);_0x31a57a?_0x31a57a['end']=_0x25be19:_0x2ae8cc['set'](_0x3c220c,{'start':_0x25be19,'end':_0x25be19});}}for(const [_0x27f326,_0x5bed66]of _0x2ae8cc){const _0x159f85=this['editor']['model']['createRange'](_0x5bed66['start'],_0x5bed66['end']);_0x5dcfb0['markers']['set'](_0x27f326,_0x159f85);}return _0x4dd24f['sort']((_0x144661,_0x1e5e1f)=>{const _0x510d5d=_0x5dcfb0['markers']['get']('revision:'+_0x144661['id']),_0x2bc5d2=_0x5dcfb0['markers']['get']('revision:'+_0x1e5e1f['id']);return _0x510d5d['start']['isBefore'](_0x2bc5d2['start'])?-0x1:_0x510d5d['start']['isAfter'](_0x2bc5d2['start'])?0x1:_0x510d5d['end']['isBefore'](_0x2bc5d2['end'])?-0x1:_0x510d5d['end']['isAfter'](_0x2bc5d2['end'])?0x1:'add'===_0x144661['type']?-0x1:0x1;}),{'root':_0x5dcfb0,'changes':_0x4dd24f};function _0x46af74(_0x49db35,_0x85049,_0x3e3cf5,_0x12f4b8){const _0x3921c2=!!_0x587e55[_0x85049][_0x49db35],_0x44dc6e=_0x3921c2?_0x587e55[_0x85049][_0x49db35]['userId']:null,_0x28a4e9=_0x85049===_0x587e55['length']-0x1,_0x2144ff=_0x1b400a[_0x49db35][0x0],_0x472ff9=_0x21c71c['isObject'](_0x587e55[_0x85049]['item']);!_0x5a7f01[_0x49db35]&&_0x3921c2?_0x5a7f01[_0x49db35]={'start':_0x3e3cf5,'tapeItem':_0x587e55[_0x85049],'userId':_0x44dc6e,'type':_0x49db35}:_0x5a7f01[_0x49db35]&&!_0x3921c2?(_0x5a7f01[_0x49db35]['end']=_0x3e3cf5,_0x2e6ce9(_0x5a7f01[_0x49db35]),_0x5a7f01[_0x49db35]=null):_0x5a7f01[_0x49db35]&&_0x3921c2&&_0x5a7f01[_0x49db35]['userId']!==_0x44dc6e&&(_0x5a7f01[_0x49db35]['end']=_0x3e3cf5,_0x2144ff&&_0x2144ff['userId']===_0x5a7f01[_0x49db35]['userId']||_0x2e6ce9(_0x5a7f01[_0x49db35]),_0x5a7f01[_0x49db35]={'start':_0x3e3cf5,'tapeItem':_0x587e55[_0x85049],'userId':_0x44dc6e,'type':_0x49db35}),_0x5a7f01[_0x49db35]&&_0x472ff9&&('elementStart'!==_0x587e55[_0x85049]['type']||_0x2144ff&&_0x2144ff['userId']===_0x44dc6e||_0x1b400a[_0x49db35]['unshift']({'userId':_0x44dc6e,'object':_0x587e55[_0x85049]['item'],'change':_0x5a7f01[_0x49db35]}),'elementEnd'===_0x587e55[_0x85049]['type']&&_0x2144ff&&_0x2144ff['object']===_0x587e55[_0x85049]['item']&&(_0x1b400a[_0x49db35]['shift'](),_0x5a7f01[_0x49db35]=_0x2144ff['change'])),_0x5a7f01[_0x49db35]&&_0x28a4e9&&(_0x5a7f01[_0x49db35]['end']=_0x12f4b8,_0x2e6ce9(_0x5a7f01[_0x49db35]),_0x5a7f01[_0x49db35]=null);}function _0x2e6ce9({start:_0x243d1a,end:_0x160776,tapeItem:_0x2995e8,userId:_0x414401,type:_0x2c7755}){const _0x36ba15=_0x2995e8['item'],_0x30a6ce=_0x3a8c9d['schema']['isBlock'](_0x36ba15)&&!_0x3a8c9d['schema']['isLimit'](_0x36ba15),_0x5ebf8a=_0x243d1a['nodeAfter']==_0x160776['parent']&&_0x160776['isAtStart'];if(_0x30a6ce&&_0x5ebf8a)return;const _0x16afa4=_0x3a8c9d['createRange'](_0x243d1a,_0x160776),_0x16994a=_0x5a4b6f['get'](_0x414401),_0x524806=new z({'author':_0x16994a,'type':'isAdded'==_0x2c7755||'isAddSuggestion'==_0x2c7755?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x2c7755||'isRemoveSuggestion'==_0x2c7755},'createdAt':new Date(),'rootName':_0x64dd3c});_0x4dd24f['push'](_0x524806),_0x5dcfb0['markers']['set']('revision:'+_0x524806['id'],_0x16afa4);}function _0x4cea60(_0x13ac3b,_0x3091bd){const _0x47ead2=_0x13ac3b['getAttributes'](),_0x13e630=_0x3091bd['getAttributes']();for(const _0x419f93 of _0x47ead2){if(_0x419f93[0x1]!==_0x3091bd['getAttribute'](_0x419f93[0x0]))return!0x1;_0x13e630['next']();}return _0x13e630['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x986e32=>{const _0xae71c=_0x986e32['markerName']['split'](':')[0x1],_0x145123=this['_getChangeFromId'](_0xae71c);if(!_0x145123)return null;const _0x545d55='add'==_0x145123['type']?'insertion':'deletion',_0x529696=['ck-suggestion-marker','ck-suggestion-marker-'+_0x545d55];return _0x145123['data']['isSuggestion']&&_0x529696['push']('ck-suggestion-marker-'+_0x545d55+'-new'),this['activeChange']==_0x145123&&_0x529696['push']('ck-suggestion-marker--active'),{'classes':_0x529696,'attributes':{'data-change-id':_0xae71c}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x104279=>{_0x104279['on']('element:pre',(_0x484060,_0x53be68,_0x215fde)=>{const _0x5b5f21=_0x53be68['viewItem']['getChild'](0x0);if(!_0x5b5f21||!_0x5b5f21['is']('element','code'))return;if(!_0x215fde['consumable']['consume'](_0x5b5f21,{'attributes':['vid_start','vid_end']}))return;const _0x3d3e27=_0x53be68['modelRange']['start']['nodeAfter'];_0x215fde['writer']['setAttribute']('vid_start',_0x5b5f21['getAttribute']('vid_start'),_0x3d3e27),_0x215fde['writer']['setAttribute']('vid_end',_0x5b5f21['getAttribute']('vid_end'),_0x3d3e27);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x37576f=>{_0x37576f['on']('element',(_0x4f96fd,_0x18a30c,_0x4bfbfc)=>{if(!_0x4bfbfc['consumable']['consume'](_0x18a30c['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x18a30c['modelRange']['isCollapsed'])return;const _0x1f1ea6=_0x18a30c['modelRange']['start']['nodeAfter'];_0x1f1ea6['hasAttribute']('vid_start')||_0x1f1ea6['hasAttribute']('vid')||(_0x4bfbfc['writer']['setAttribute']('vid_start',_0x18a30c['viewItem']['getAttribute']('vid_start'),_0x1f1ea6),_0x4bfbfc['writer']['setAttribute']('vid_end',_0x18a30c['viewItem']['getAttribute']('vid_end'),_0x1f1ea6));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x10af3c=>_0x10af3c['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x5e6df0,[,_0xbdeb60])=>{['vid_start','vid_end','vid']['includes'](_0xbdeb60)&&(_0x5e6df0['return']=!0x0,_0x5e6df0['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x2127b9=>{_0x2127b9['on']('attribute:vid',(_0x43a43a,_0x521727,_0x593855)=>{if('\x20'!=_0x521727['item']['data']||_0x521727['item']['parent']['maxOffset']>0x1)return;if(!_0x593855['consumable']['consume'](_0x521727['item'],_0x43a43a['name']))return;const _0x110284=_0x593855['writer'],_0x2ce7b8=_0x593855['mapper']['toViewRange'](_0x521727['range']);_0x110284['wrap'](_0x2ce7b8,_0x110284['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x152f2c){const _0x914b93=_0x152f2c['plugins']['get']('RevisionViewer');return(_0x1d3a3a,_0x1ab433,_0x305c2b)=>{const _0x261d8a=_0x1ab433['markerName']['split'](':')[0x1],_0x17cd28=_0x914b93['_getChangeFromId'](_0x261d8a);if(!_0x17cd28)return null;const _0x3ef76d='add'==_0x17cd28['type']?'split':'merge';if(!_0x305c2b['consumable']['test'](_0x1ab433['markerRange'],_0x1d3a3a['name']))return;const _0x8d48a4=_0x1ab433['markerRange']['getWalker'](),_0x8fc5c3=_0x1ab433['markerRange']['start'],_0x277122=_0x152f2c['model']['schema'];let _0x550329=null,_0x3f8a7f=null,_0x1275f9=!0x1,_0x212d02=!0x1;for(const _0x48e68f of _0x8d48a4){const _0xebe208=_0x48e68f['item'];_0x1275f9=_0x1275f9||_0x277122['isContent'](_0xebe208);const _0x4b3e6c=_0x305c2b['mapper']['toViewElement'](_0xebe208);if(_0x4b3e6c&&_0x4b3e6c['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x48e68f['type']&&(_0x277122['isBlock'](_0xebe208)&&!_0x277122['isLimit'](_0xebe208)&&(_0xebe208['nextSibling']||_0x8fc5c3['isAtEnd']?_0x550329&&_0x550329['parent']==_0xebe208||(_0x550329=_0xebe208,_0x10c187(_0x48e68f['previousPosition']),_0x212d02=!0x0):_0x3f8a7f=_0x3f8a7f||_0x48e68f['previousPosition']));}function _0x10c187(_0xf7fd28){const _0x2d1d55=_0x305c2b['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x3ef76d}),_0x22bee1=_0x305c2b['mapper']['toViewPosition'](_0xf7fd28);_0x17cd28['data']['isSuggestion']&&_0x305c2b['writer']['addClass']('ck-suggestion-marker-'+_0x3ef76d+'-new',_0x2d1d55),_0x914b93['activeChange']==_0x17cd28&&_0x305c2b['writer']['addClass']('ck-suggestion-marker--active',_0x2d1d55),_0x305c2b['writer']['insert'](_0x22bee1,_0x2d1d55),_0x305c2b['mapper']['bindElementToMarker'](_0x2d1d55,_0x1ab433['markerName']);}_0x1275f9||_0x212d02||!_0x3f8a7f||_0x10c187(_0x3f8a7f);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x39d5fe,_0x49695c,_0xf5d037)=>{const _0x11c387=_0xf5d037['mapper']['markerNameToElements'](_0x49695c['markerName']);if(_0x11c387){for(const _0x2f34f4 of _0x11c387)(_0x2f34f4['hasClass']('ck-suggestion-marker-split')||_0x2f34f4['hasClass']('ck-suggestion-marker-merge'))&&(_0xf5d037['mapper']['unbindElementFromMarkerName'](_0x2f34f4,_0x49695c['markerName']),_0xf5d037['writer']['remove'](_0x2f34f4));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x96b40e,_0xa10d7e,_0x7fee52)=>{const _0x101ca3=_0xa10d7e['markerName']['split'](':')[0x1],_0x2e14ae=this['_getChangeFromId'](_0x101ca3);if(!_0x2e14ae)return null;const _0x471db6='add'==_0x2e14ae['type']?'split':'merge';if(_0x7fee52['consumable']['test'](_0xa10d7e['markerRange'],_0x96b40e['name']))for(const _0x558f4d of _0xa10d7e['markerRange']['getItems']()){if(!_0x558f4d['is']('element','softBreak'))continue;const _0x45bb9f=_0x7fee52['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x471db6}),_0x422889=_0x7fee52['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x558f4d));_0x2e14ae['data']['isSuggestion']&&_0x7fee52['writer']['addClass']('ck-suggestion-marker-'+_0x471db6+'-new',_0x45bb9f),this['activeChange']==_0x2e14ae&&_0x7fee52['writer']['addClass']('ck-suggestion-marker--active',_0x45bb9f),_0x7fee52['writer']['insert'](_0x422889,_0x45bb9f),_0x7fee52['mapper']['bindElementToMarker'](_0x45bb9f,_0xa10d7e['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x43bc1f=>{for(const _0x4148f6 of this['editor']['model']['document']['getRootNames']()){const _0x33d59e=this['editor']['model']['document']['getRoot'](_0x4148f6),_0x7dd3be=this['editor']['editing']['view']['document']['getRoot'](_0x4148f6);if(_0x7dd3be){const _0xb15caa=_0x33d59e['getAttribute']('revisionHistoryAttachChange');if(_0x43bc1f['removeAttribute']('data-change-id',_0x7dd3be),_0x43bc1f['removeClass']('ck-revision-history-root-add',_0x7dd3be),_0x43bc1f['removeClass']('ck-revision-history-root-remove',_0x7dd3be),_0x43bc1f['removeClass']('ck-revision-history-root--active',_0x7dd3be),_0xb15caa){const _0x345092=this['_getChangeFromId'](_0xb15caa);if(!_0x345092)return null;_0x43bc1f['setAttribute']('data-change-id',_0xb15caa,_0x7dd3be),_0x43bc1f['addClass']('ck-revision-history-root-'+_0x345092['type'],_0x7dd3be),this['activeChange']==_0x345092&&_0x43bc1f['addClass']('ck-revision-history-root--active',_0x7dd3be);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x12b850=>'revision-comment:'+_0x12b850,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x2cd961=>'revision-suggestion:'+_0x2cd961,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x15781e=>({'name':'suggestion:'+_0x15781e,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x16ac05=>{const _0x9d1c=_0x16ac05['markerName']['split'](':')[0x1];return'insertion'!=_0x9d1c&&'deletion'!=_0x9d1c?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x9d1c]};}}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:deletion',J(this['editor'],'merge'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:insertion',J(this['editor'],'split'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision-suggestion',(_0x54fb05,_0x588b49,_0x5180cb)=>{const _0x4f5f04=_0x5180cb['mapper']['markerNameToElements'](_0x588b49['markerName']);if(_0x4f5f04){for(const _0x229d2a of _0x4f5f04)_0x229d2a['is']('uiElement')&&(_0x5180cb['mapper']['unbindElementFromMarkerName'](_0x229d2a,_0x588b49['markerName']),_0x5180cb['writer']['remove'](_0x229d2a));}},{'priority':'high'});}['_getChangeFromId'](_0x2f768d){return this['_changeIdToChange']['get'](_0x2f768d);}['_getViewForChange'](_0x2a66ea){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new q(this['editor']['locale'],_0x2a66ea),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x515d92,_0x3fe225,_0x386e2c,_0x5548df)=>{_0x5548df&&this['_balloon']['remove'](_0x5548df),_0x386e2c&&(this['_balloon']['add']({'view':_0x386e2c,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x403b02=this['editor']['editing'],_0x13cd7a=this['_getChangeFromId'](_0x386e2c['changeId']);let _0x561e47;if(_0x13cd7a['data']['isOnRoot']){const _0x12b9df=_0x403b02['view']['getDomRoot'](_0x13cd7a['rootName']);_0x561e47=Array['from'](_0x12b9df['getClientRects']());}else{const _0x3bc540=this['editor']['model']['markers']['get']('revision:'+_0x386e2c['changeId']);_0x561e47=Array['from'](_0x403b02['mapper']['markerNameToElements'](_0x3bc540['name']))['map'](_0x235082=>_0x403b02['view']['domConverter']['mapViewToDom'](_0x235082))['map'](_0x2eb365=>Array['from'](_0x2eb365['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x561e47[0x0];return _0x561e47['find'](_0x3f449d=>_0x3f449d['top']-0x3<=this['_activeViewTarget']['y']&&_0x3f449d['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x3f449d['left']-0x3<=this['_activeViewTarget']['x']&&_0x3f449d['right']+0x3>=this['_activeViewTarget']['x'])||_0x561e47[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x50c388,_0x293b59,_0x263ed7,_0x2c4196)=>{this['activeView']=_0x263ed7?this['_getViewForChange'](_0x263ed7):null,this['editor']['model']['change'](()=>{const _0x454500=this['editor']['editing'];_0x2c4196&&(_0x2c4196['data']['isOnRoot']?_0x454500['view']['change'](_0x49bfa8=>{_0x49bfa8['removeClass']('ck-revision-history-root--active',_0x454500['view']['document']['getRoot'](_0x2c4196['rootName']));}):_0x454500['reconvertMarker']('revision:'+_0x2c4196['id'])),_0x263ed7&&(_0x263ed7['data']['isOnRoot']?_0x454500['view']['change'](_0x53a8e1=>{_0x53a8e1['addClass']('ck-revision-history-root--active',_0x454500['view']['document']['getRoot'](_0x263ed7['rootName']));}):_0x454500['reconvertMarker']('revision:'+_0x263ed7['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x5dfd6a,_0x5258b1)=>{if(this['activeChange'])return;const _0x1598ad=this['_findChangeIdFromDomTarget'](_0x5258b1['target']),_0x514c92=this['_changeIdToChange']['get'](_0x1598ad);_0x514c92?(this['_activeViewTarget']={'x':_0x5258b1['domEvent']['x'],'y':_0x5258b1['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x514c92)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x395716,_0x46f4e1)=>{const _0x26c823=this['_findChangeIdFromDomTarget'](_0x46f4e1['target']),_0x163d52=this['_changeIdToChange']['get'](_0x26c823);_0x163d52?(this['_activeViewTarget']={'x':_0x46f4e1['domEvent']['x'],'y':_0x46f4e1['domEvent']['y']},_0x163d52===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x163d52):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x1bdd41){do{const _0x52298d=_0x1bdd41['getAttribute']('data-change-id');if(_0x52298d)return _0x52298d;_0x1bdd41=_0x1bdd41['parent'];}while(_0x1bdd41);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x1d5508=>{for(const _0x3f9b54 of this['editor']['model']['markers'])_0x1d5508['removeMarker'](_0x3f9b54);});}}function J(_0x12f743,_0x2a541e){return(_0x4c9dbe,_0x5db29d,_0x41261e)=>{if(!_0x41261e['consumable']['test'](_0x5db29d['markerRange'],_0x4c9dbe['name']))return;const _0x128640=_0x5db29d['markerRange']['getWalker'](),_0x7ada83=_0x5db29d['markerRange']['start'],_0x3bbf8c=_0x12f743['model']['schema'];let _0x20afed=null,_0x5876c9=null,_0x133116=!0x1,_0x4fb599=!0x1;for(const _0xde1f22 of _0x128640){const _0x55a8d1=_0xde1f22['item'];_0x133116=_0x133116||_0x3bbf8c['isContent'](_0x55a8d1);const _0x2d785f=_0x41261e['mapper']['toViewElement'](_0x55a8d1);if(_0x2d785f&&_0x2d785f['getCustomProperty']('addHighlight'))return;'elementEnd'==_0xde1f22['type']&&(_0x3bbf8c['isBlock'](_0x55a8d1)&&!_0x3bbf8c['isLimit'](_0x55a8d1)&&(_0x55a8d1['nextSibling']||_0x7ada83['isAtEnd']?_0x20afed&&_0x20afed['parent']==_0x55a8d1||(_0x20afed=_0x55a8d1,_0x5c8740(_0xde1f22['previousPosition']),_0x4fb599=!0x0):_0x5876c9=_0x5876c9||_0xde1f22['previousPosition']));}function _0x5c8740(_0x26b9bb){const _0x36c7c5=_0x41261e['mapper']['toViewPosition'](_0x26b9bb),_0x251a71=_0x41261e['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x2a541e});_0x41261e['writer']['insert'](_0x36c7c5,_0x251a71),_0x41261e['mapper']['bindElementToMarker'](_0x251a71,_0x5db29d['markerName']);}_0x133116||_0x4fb599||!_0x5876c9||_0x5c8740(_0x5876c9);};}class RestoreRevisionCommand extends _0x5c344b{constructor(_0x184cb0){super(_0x184cb0);const _0x4fb37e=_0x184cb0['plugins']['get'](u);this['affectsData']=!0x1,this['listenTo'](_0x4fb37e,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x4fb37e,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0xaffa08=this['editor'],_0x52cdff=_0xaffa08['plugins']['get'](u),_0x372155=_0x52cdff['isReady']?_0x52cdff['diff']['newRevisionId']:null;_0xaffa08['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x372155);}['refresh'](){const {isReady:_0xd6960a,isEnabled:_0x2de3f6,repository:_0x50d16d,diff:_0x3aaf3a}=this['editor']['plugins']['get'](u),_0x524cc3=_0x3aaf3a&&_0x50d16d['getLaterVisibleRevision'](_0x3aaf3a['newRevisionId']);this['isEnabled']=_0xd6960a&&_0x2de3f6&&Boolean(_0x524cc3);}}class ShowChangeCommand extends _0x5c344b{['_step'];constructor(_0xfa6684,{direction:_0x5b7f31}){super(_0xfa6684);const _0x1a6731=_0xfa6684['plugins']['get'](u);this['affectsData']=!0x1,this['_step']='forward'===_0x5b7f31?0x1:-0x1,this['listenTo'](_0x1a6731,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x1a6731,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x1a6731,'change:activeChange',()=>this['refresh']());}['execute'](){const _0xf44fb5=this['editor'],_0x31d662=_0xf44fb5['plugins']['get'](u),{isNavigationMode:_0x1d8f78,currentChangeNumber:_0x5a5463}=_0x31d662;let _0x462bdd;if(_0x31d662['activeChange']=_0x1d8f78?_0x31d662['diff']['changes']['get'](_0x5a5463+this['_step']):_0x31d662['diff']['changes']['first'],_0x31d662['activeChange']['data']['isOnRoot'])_0x462bdd=_0xf44fb5['editing']['view']['getDomRoot'](_0x31d662['activeChange']['rootName']);else{const _0x450b43=_0xf44fb5['model']['markers']['get']('revision:'+_0x31d662['activeChange']['id']);_0x462bdd=_0xcc7916(_0xf44fb5['editing'],_0x450b43);}_0x5bc707({'target':_0x462bdd,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x4cc27b,currentChangeNumber:_0x25134b,numberOfChanges:_0x1e31be,isReady:_0x3d150c,isEnabled:_0xadba43}=this['editor']['plugins']['get'](u);this['isEnabled']=!!(_0xadba43&&_0x3d150c&&_0x1e31be)&&(!_0x4cc27b||(0x1===this['_step']?_0x25134b<_0x1e31be-0x1:_0x25134b>0x0));}}class xi extends _0x584d23{constructor(_0x2cfdaa){super(_0x2cfdaa);const _0x3e6be6=this['bindTemplate'],_0x9d3d7a=new _0x56b48b(_0x2cfdaa),_0x1ce0d2=new _0x56b48b(_0x2cfdaa);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',(_0x44afec,_0x576530)=>_0x44afec&&_0x576530>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x2e600d,_0x1a3b3f,_0x1a2207,_0x5baa71)=>{if(!_0x2e600d)return m(_0x2cfdaa,'Loading...');if(!_0x1a2207)return m(_0x2cfdaa,'No\x20changes');const _0x1f5466=m(_0x2cfdaa,'NUMBER_OF_CHANGES',_0x1a2207);return _0x5baa71?m(_0x2cfdaa,'X_OF_Y_CHANGES',[_0x1a3b3f+0x1,_0x1a2207]):_0x1f5466;}),_0x9d3d7a['set']({'label':m(_0x2cfdaa,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0xf8e6f0}),_0x1ce0d2['set']({'label':m(_0x2cfdaa,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x532e88}),_0x9d3d7a['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x1ce0d2['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x9d3d7a['on']('execute',()=>this['fire']('execute','backward')),_0x1ce0d2['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',_0x3e6be6['if']('_isStatusLabelVisible','ck-hidden',_0x411b5e=>!_0x411b5e)]},'children':[{'text':_0x3e6be6['to']('isNavigationMode',_0x454704=>_0x454704?m(_0x2cfdaa,'EDIT_X_OF_Y_REVISIONS')+':\x20':m(_0x2cfdaa,'Total')+':\x20')}]},{'text':_0x3e6be6['to']('_statusText')}]},new _0x4be757(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x9d3d7a,_0x1ce0d2]}]});}}const ge='ck-editor__editable__loading-overlay';class Ri extends _0xde4b58{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x5ecf49=this['editor']['editing']['view'];_0x5ecf49['change'](_0x22e7fc=>{for(const _0x3384ad of _0x5ecf49['document']['roots'])_0x22e7fc['addClass'](ge,_0x3384ad);});}['hide'](){const _0x17f29a=this['editor']['editing']['view'];_0x17f29a['change'](_0x181a8e=>{for(const _0x203613 of _0x17f29a['document']['roots'])_0x181a8e['removeClass'](ge,_0x203613);});}}class v extends _0xde4b58{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u,Ri];}['init'](){const _0x7947a4=this['editor'],_0xec57d0=_0x7947a4['plugins']['get'](u),_0x3dee91=_0x7947a4['plugins']['get'](Ri);_0x7947a4['ui']['componentFactory']['add']('exitToEditing',_0xa96691=>{const _0x5cf08c=new _0x56b48b(_0xa96691);return _0x5cf08c['set']({'label':m(_0xa96691,'Back\x20to\x20editing'),'icon':_0x13d588,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x5cf08c,'execute',()=>{_0x7947a4['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x5cf08c;}),_0x7947a4['ui']['componentFactory']['add']('restoreRevision',_0x491fce=>{const _0x37d6b4=new _0x56b48b(_0x491fce);return _0x37d6b4['set']({'label':m(_0x491fce,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x37d6b4['bind']('isEnabled')['to'](_0x7947a4['commands']['get']('restoreRevision')),this['listenTo'](_0x37d6b4,'execute',()=>_0x7947a4['execute']('restoreRevision')),_0x37d6b4;}),_0x7947a4['ui']['componentFactory']['add']('changesNavigation',_0x231abd=>{const _0x3ed9f6=new xi(_0x231abd),_0x786a4=_0x7947a4['commands']['get']('showPreviousChange'),_0xfd272e=_0x7947a4['commands']['get']('showNextChange');return _0x3ed9f6['bind']('isBackwardNavigationEnabled')['to'](_0x786a4,'isEnabled'),_0x3ed9f6['bind']('isForwardNavigationEnabled')['to'](_0xfd272e,'isEnabled'),_0x3ed9f6['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0xec57d0),this['listenTo'](_0x3ed9f6,'execute',(_0x3a24af,_0x5c8ab7)=>{_0x7947a4['execute']('forward'===_0x5c8ab7?'showNextChange':'showPreviousChange');}),_0x3ed9f6;}),_0x3dee91['show'](),_0xec57d0['on']('change:isReady',(_0x223f77,_0x14b3ef,_0x5ef9c3)=>{_0x5ef9c3?_0x3dee91['hide']():_0x3dee91['show']();});}}class oi extends et{['_resizeObserver']=null;constructor(_0x11b090,_0x259ada){super(_0x11b090,_0x259ada);const _0x292a09=this['bindTemplate'];this['set']({'label':m(_0x11b090,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=m(_0x11b090,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x292a09['to']('_tooltipString'),'data-cke-tooltip-position':'s','data-cke-tooltip-class':'ck-tooltip_multi-line'}});}['render'](){super['render'](),this['_resizeObserver']=new ot(this['fieldView']['element'],()=>this['_updateTooltipText']()),this['listenTo'](this['fieldView'],'input',()=>this['_updateTooltipText']());}['destroy'](){super['destroy'](),this['_resizeObserver']&&this['_resizeObserver']['destroy']();}['_updateTooltipText'](){const _0x38c930=this['fieldView']['element'];this['_tooltipString']=_0x38c930['scrollWidth']>_0x38c930['clientWidth']&&_0x38c930['value']||'';}}class hi extends _0x584d23{constructor(_0x460a09,_0x33f9ba,_0x1a73ed){super(_0x460a09);const _0x45e1cf=new _0x5649b5();_0x45e1cf['set']({'content':_0x4e060a,'viewBox':'0\x200\x2011\x2010'});const _0x2fa30c=['ck','ck-revision-history-sidebar__revision-author'];_0x1a73ed&&_0x2fa30c['push']('ck-revision-history-sidebar__revision-author_creator');const _0x3d4f6c=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':m(_0x460a09,_0x1a73ed?'Revision\x20creator':'Revision\x20author')},'children':[_0x45e1cf,_0x33f9ba['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x2fa30c},'children':_0x3d4f6c});}}function ci(_0x241a7b,_0x14130e){const _0x20999b=_0x241a7b['bindTemplate'],_0x9517c3=_0x241a7b['locale'],_0x48c831=_0x4c9aaf(_0x9517c3);_0x48c831['panelPosition']='sw';const _0x4d0389=function(_0x407266,_0xa7a917){const _0x191ced=function(_0x1d90f8,_0x4cbcf1){const _0x4fdaf5=_0x1d90f8['locale'],_0x1e2a0b={'Compare\x20against\x20selected':m(_0x4fdaf5,'Compare\x20against\x20selected'),'Name\x20this\x20revision':m(_0x4fdaf5,'Name\x20this\x20revision'),'Restore\x20this\x20revision':m(_0x4fdaf5,'Restore\x20this\x20revision')};return _0x4cbcf1['map'](_0x180bcb=>{const _0x20dc3a=_0x1e2a0b[_0x180bcb['name']];return _0x20dc3a&&_0x20dc3a!==_0x180bcb['name']&&(_0x180bcb['name']=_0x20dc3a),_0x180bcb;});}(_0x407266,_0xa7a917),_0x452e45=new _0x4fc9f6();for(const _0x282ee1 of _0x191ced){const _0x431cc4={'type':'button','model':new to({'label':_0x282ee1['name'],'class':_0x282ee1['class'],'withText':!0x0,'role':'menuitem','_action':_0x282ee1['action']})};_0x431cc4['model']['bind']('isEnabled')['to'](_0x407266,'isActionsDropdownOpen',_0x33d9eb=>'function'!=typeof _0x282ee1['isEnabled']||(!_0x33d9eb||_0x282ee1['isEnabled'](_0x407266))),_0x452e45['add'](_0x431cc4);}return _0x452e45;}(_0x241a7b,_0x14130e);return _0x241a7b['bind']('isActionsDropdownOpen')['to'](_0x48c831,'isOpen'),_0x48c831['buttonView']['set']({'label':m(_0x9517c3,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x14f165}),_0x48c831['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x20999b['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x20999b['to'](_0x26e90c=>_0x26e90c['stopPropagation']())}}),_0x48c831['on']('execute',_0x3dd8a4=>{_0x241a7b['isReady']&&'function'==typeof _0x3dd8a4['source']['_action']&&_0x3dd8a4['source']['_action'](_0x241a7b);}),_0x35149e(_0x48c831,_0x4d0389,{'role':'menu'}),_0x48c831['listenTo'](_0x241a7b,'change:isActionsDropdownOpen',(_0x507fc5,_0x227520,_0x35cd25)=>{if(_0x35cd25)for(const _0x463f4a of _0x48c831['listView']['items']){const _0x363b6a=_0x463f4a['children']['first'],_0x8602bb=_0x14130e['find'](_0x162117=>_0x162117['action']===_0x363b6a['_action'])['isVisible'];_0x463f4a['isVisible']=void 0x0===_0x8602bb||_0x8602bb(_0x241a7b);}}),_0x48c831;}class _i extends/* #__PURE__ -- @preserve */
27
- _0x635858(_0x584d23){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x3a039e,_0x22c720,_0x50516b,_0x379e7f){super(_0x3a039e);const _0x19d3ba=this['bindTemplate'],_0x516369=function(_0x59f3aa,_0x362190){const _0x4e6510=Array['from'](_0x362190['authors'])['filter'](_0x1828ca=>_0x1828ca!=_0x362190['creator']);return _0x362190['creator']&&_0x4e6510['unshift'](_0x362190['creator']),_0x4e6510['map'](_0x10ca5c=>new hi(_0x59f3aa,_0x10ca5c,_0x10ca5c==_0x362190['creator']));}(_0x3a039e,_0x22c720);this['id']=_0x22c720['id'],this['_revision']=_0x22c720,this['_requireRevisionName']=_0x379e7f,this['bind']('name','createdAt')['to'](_0x22c720),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x44c539=>{return _0x3dff72=_0x3a039e['uiLanguage'],(_0x2c173b=_0x44c539)['toLocaleDateString'](_0x3dff72,{'month':'long','day':'numeric'})+',\x20'+_0x2c173b['toLocaleTimeString'](_0x3dff72,{'hour':'numeric','minute':'numeric'});var _0x3dff72,_0x2c173b;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new oi(_0x3a039e,ti),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x35f00d=>_0x35f00d||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0xe2a3a4,_0x46db64)=>_0xe2a3a4&&_0x46db64),this['revisionActionsView']=_0x50516b&&_0x50516b['length']?ci(this,_0x50516b):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x19d3ba['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x19d3ba['if']('isEnabled','ck-disabled',_0x1beeea=>!_0x1beeea),_0x19d3ba['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x19d3ba['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x19d3ba['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':_0x19d3ba['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':_0x516369}]},this['revisionActionsView']],'on':{'click':_0x19d3ba['to'](_0x5c9428=>{_0x5c9428['srcElement']['closest']('.ck-confirm-view')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x1d588b=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x1d588b,'change',()=>{this['_requireRevisionName']&&!_0x1d588b['value']||this['fire']('setName',{'id':this['id'],'name':_0x1d588b['value']}),_0x1d588b['value']||(_0x1d588b['value']=this['name']?this['name']:this['_createdAtFormatted']);});}['select'](){this['isSelected']=!0x0;}['deselect'](){this['isSelected']=!0x1;}['highlight'](){this['isHighlighted']=!0x0;}['unhighlight'](){this['isHighlighted']=!0x1;}}function li(_0x5b2b69,_0x1faa8c){const _0x322e7c=_0x156a48['fromJSDate'](_0x5b2b69)['setLocale'](_0x1faa8c),_0x1d394b=_0x156a48['local'](),_0x323b38=_0x1d394b['minus']({'days':0x1})['startOf']('day');let _0x279bb6,_0x3c1dce;return _0x322e7c['hasSame'](_0x1d394b,'day')?(_0x279bb6=_0x322e7c['startOf']('day')['toJSDate'](),_0x3c1dce=_0x322e7c['toRelativeCalendar']()):_0x322e7c['hasSame'](_0x323b38,'day')?(_0x279bb6=_0x323b38['toJSDate'](),_0x3c1dce=_0x322e7c['toRelativeCalendar']()):_0x322e7c['hasSame'](_0x1d394b,'week')?(_0x279bb6=_0x322e7c['startOf']('week')['toJSDate'](),_0x3c1dce=_0x322e7c['weekdayLong']||''):_0x322e7c['hasSame'](_0x1d394b,'year')?(_0x279bb6=_0x322e7c['startOf']('month')['toJSDate'](),_0x3c1dce=_0x322e7c['monthLong']||''):(_0x279bb6=_0x322e7c['startOf']('year')['toJSDate'](),_0x3c1dce=String(_0x322e7c['year'])),{'startDate':_0x279bb6,'localizedPeriodName':_0x3c1dce};}class bi extends _0x584d23{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x279ca5,_0x433b44,_0x1f2b6c,_0x231012){super(_0x279ca5);const _0x13ab7b=li(_0x433b44,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x433b44,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x1f2b6c,this['_requireRevisionName']=_0x231012,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':_0x13ab7b}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x27bd7c){const _0xaddd9d=new _i(this['locale'],_0x27bd7c,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0xaddd9d);}['removeRevision'](_0x1067ac){const _0x158812=this['revisionViews']['find'](_0x5b320e=>_0x5b320e['id']===_0x1067ac['id']);this['revisionViews']['remove'](_0x158812);}}class fi extends _0x584d23{constructor(_0x1ec3ff){super(_0x1ec3ff);const _0x3243ab=new _0x5649b5();_0x3243ab['content']=_0x173b8e,this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x3243ab,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[m(_0x1ec3ff,'Revision\x20history')]}]});}}class di extends _0x584d23{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x4e3718,_0x1c05e9,_0x21a9d7,_0x5bce30){super(_0x4e3718);const _0x169c00=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x1c05e9,this['_revisionActions']=_0x21a9d7,this['_requireRevisionName']=_0x5bce30,this['on']('select',(_0x269cef,_0x136262)=>{this['fire']('revisionSelected',_0x136262);}),this['on']('setName',(_0x20de6c,_0x3f00ee)=>{this['fire']('revisionSetName',_0x3f00ee);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new fi(_0x4e3718),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x169c00['if']('isEnabled','ck-disabled',_0x1935ea=>!_0x1935ea)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x37b427 of this['_revisions'])this['_addRevision'](_0x37b427);this['_revisions']['on']('add',(_0x13dde0,_0x304b5c)=>{this['_addRevision'](_0x304b5c);}),this['_revisions']['on']('remove',(_0x4d4922,_0x3e9b03)=>{this['_removeRevision'](_0x3e9b03);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x1383b9=>_0x1383b9['revisionViews']['map'](_0x36f64d=>_0x36f64d))['flat']();}['selectRevision'](_0x244e86){for(const _0x52908f of this['revisionViews'])_0x244e86&&_0x244e86['id']===_0x52908f['id']?_0x52908f['select']():_0x52908f['deselect']();}['highlightRevisions'](_0x56ddc2){for(const _0x396214 of this['revisionViews'])_0x56ddc2['some'](({id:_0x2d3815})=>_0x2d3815===_0x396214['id'])?_0x396214['highlight']():_0x396214['unhighlight']();}['_addRevision'](_0x5ba493){const _0x3694ca=li(_0x5ba493['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x40a096=this['timePeriodViews']['get'](0x0);_0x40a096&&_0x40a096['startDate']['getTime']()===_0x3694ca['getTime']()||(_0x40a096=new bi(this['locale'],_0x3694ca,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x40a096)),_0x40a096['addRevision'](_0x5ba493);}['_removeRevision'](_0x476940){const _0x2745f2=li(_0x476940['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x2745f2)['removeRevision'](_0x476940);}['_getTimePeriodViewByStartDate'](_0x2184d9){return this['timePeriodViews']['find'](_0x44588c=>_0x44588c['startDate']['getTime']()===_0x2184d9['getTime']());}}class d extends _0xde4b58{['_revisionViewer'];['_revisionsRepository'];['_sidebarView'];static ['defaultRevisionActions']=/* #__PURE__ -- @preserve */
23
+ import{ObservableMixin as _0x31e13c,uid as _0x8d6220,Collection as _0x4cfa07,logWarning as _0x9fdb5c,FocusTracker as _0x5a9408,KeystrokeHandler as _0x459fc5,scrollViewportToShowTarget as _0x37c45d,ResizeObserver as ot,ElementReplacer as it,CKEditorError as _0x49908e}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0xc930c3,set as _0x5c8f0c,unset as _0x1aed36,isEqual as _0xba9853}from'es-toolkit/compat';import{Plugin as _0x5ac587,PendingActions as _0x3dfd76,Command as _0x3d5106,ElementApiMixin as _0x14531e,Editor as _0x2daf9f}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x280554,getMarkerDomElement as _0x284dea,ConfirmMixin as _0x379a5a,sanitizeEditorConfig as _0x5d6dc8}from'ckeditor5-collaboration/dist/index.js';import{ViewContainerElement as _0x28f766,ViewAttributeElement as _0x32b442,ViewEmptyElement as _0x304e10,ViewRawElement as _0x483df8,ViewUIElement as _0x27969c,ViewDocumentFragment as _0x2bc6e7,ViewText as _0x3879cc,ViewElement as _0x49516b,ModelElement as _0xe30740,ModelRange as _0x4577a5,ModelPosition as _0x391495,ModelDocumentFragment as _0x308cc0,ModelText as _0xf9337}from'@ckeditor/ckeditor5-engine/dist/index.js';import{IconHistory as _0x1e1fa6,IconChevronUp as _0x475a7a,IconChevronDown as _0x16b634,IconUndo as _0x43dc61,IconUser as _0x17cfe1,IconThreeVerticalDots as _0x5e37df}from'@ckeditor/ckeditor5-icons/dist/index.js';import{CssTransitionDisablerMixin as _0xdbdcec,View as _0x340389,submitHandler as _0x27bdd1,LabeledFieldView as et,createLabeledInputText as ti,createDropdown as _0x37cd46,ListView as _0x143685,ListItemView as _0x19cc88,ButtonView as _0x3d7f7c,MenuBarMenuView as _0x14b3d5,MenuBarMenuListView as _0x48c1ad,MenuBarMenuListItemView as _0x3f4a16,MenuBarMenuListItemButtonView as _0xa76307,ContextualBalloon as _0xcf2f43,ToolbarSeparatorView as _0x530a8f,IconView as _0x4e3434,addListToDropdown as _0x3e11ba,UIModel as to,EditorUI as tt,normalizeToolbarConfig as st,BoxedEditorUIView as _0xaa43ba,StickyPanelView as _0x48a15c,ToolbarView as _0x2b9f1b,InlineEditableUIView as te}from'@ckeditor/ckeditor5-ui/dist/index.js';import{DateTime as _0xc5fc85}from'luxon';class I extends/* #__PURE__ -- @preserve */
24
+ _0x31e13c(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x1b4298){super(),this['id']=_0x1b4298['id']||_0x8d6220(),this['creator']=_0x1b4298['creator']||null,this['authors']=_0x1b4298['authors']||[],this['diffData']=_0x1b4298['diffData']||null,this['toVersion']=_0x1b4298['toVersion']||0x0,this['fromVersion']=_0x1b4298['fromVersion']||0x0,this['set']('name',_0x1b4298['name']||''),this['set']('createdAt',_0x1b4298['createdAt']||new Date()),this['set']('attributes',_0x1b4298['attributes']||{});}['setName'](_0x5a7c42){this['_update']({'name':_0x5a7c42});}['setAttribute'](_0x780424,_0x5c90d2){const _0x583bef=_0xc930c3(this['attributes']);_0x5c8f0c(_0x583bef,_0x780424,_0x5c90d2),this['_update']({'attributes':_0x583bef});}['removeAttribute'](_0x66de74){const _0x2195ec=_0xc930c3(this['attributes']);_0x1aed36(_0x2195ec,_0x66de74),this['_update']({'attributes':_0x2195ec});}['_update'](_0x59f0b4,_0x410720=!0x1){let _0x81d53e=!0x1;const _0x2be502={'id':this['id']},_0x1e1d11=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x2dedee of _0x1e1d11){const _0x4870ff=_0x59f0b4[_0x2dedee];void 0x0!==_0x4870ff&&_0x4870ff!==this[_0x2dedee]&&(this[_0x2dedee]=_0x4870ff,_0x2be502[_0x2dedee]=_0x4870ff,_0x81d53e=!0x0);}_0x81d53e&&(_0x2be502['authors']&&(_0x2be502['authorsIds']=_0x2be502['authors']['map'](_0x49ba66=>_0x49ba66['id']),delete _0x2be502['authors']),this['fire']('_update',_0x2be502,_0x410720));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x58da6a=>_0x58da6a['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class S extends _0x5ac587{['_revisions'];static get['requires'](){return[_0x280554];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x1e8042){super(_0x1e8042),this['_revisions']=new _0x4cfa07();}['afterInit'](){!async function(_0x70a1ae){const _0x55fb2c=_0xe4d228([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]),_0x19d5e9=0xeb829,_0x47043d=0x359e09b0,_0x557056=0x35998670^_0x47043d,_0x3605fc=window[_0xe4d228([0x44,0x61,0x74,0x65])][_0xe4d228([0x6e,0x6f,0x77])](),_0x5f140a=_0x70a1ae[_0xe4d228([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x20f4cf=new window[(_0xe4d228([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x1de109=>{_0x5f140a[_0xe4d228([0x6f,0x6e,0x63,0x65])](_0xe4d228([0x72,0x65,0x61,0x64,0x79]),_0x1de109);}),_0x2339f5={[_0xe4d228([0x6b,0x74,0x79])]:_0xe4d228([0x45,0x43]),[_0xe4d228([0x75,0x73,0x65])]:_0xe4d228([0x73,0x69,0x67]),[_0xe4d228([0x63,0x72,0x76])]:_0xe4d228([0x50,0x2d,0x32,0x35,0x36]),[_0xe4d228([0x78])]:_0xe4d228([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]),[_0xe4d228([0x79])]:_0xe4d228([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]),[_0xe4d228([0x61,0x6c,0x67])]:_0xe4d228([0x45,0x53,0x32,0x35,0x36])},_0x49d941=_0x5f140a[_0xe4d228([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0xe4d228([0x67,0x65,0x74])](_0xe4d228([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x52195d(){let _0x403da0,_0x4f1c1d=null,_0x2ec3d6=null;try{if(_0x49d941==_0xe4d228([0x47,0x50,0x4c]))return _0xe4d228([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x403da0=_0x111605(),!_0x403da0)return _0xe4d228([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x403da0[_0xe4d228([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x2ec3d6=_0x551cd0(_0x403da0[_0xe4d228([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x403da0[_0xe4d228([0x6a,0x74,0x69])])),await _0x433434()?_0x25fbff()?_0x2c6243()?_0xe4d228([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x404dcd()?(_0x403da0[_0xe4d228([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0xe4d228([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x4f1c1d=_0x58343a(_0xe4d228([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),await _0x3f7a98()):_0xe4d228([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0xe4d228([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0xe4d228([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0xe4d228([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x2c6243(){const _0x527111=[_0xe4d228([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0xe4d228([0x74,0x72,0x69,0x61,0x6c])][_0xe4d228([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x403da0[_0xe4d228([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x3605fc/0x3e8:0xe10*_0x557056;return _0x403da0[_0xe4d228([0x65,0x78,0x70])]<_0x527111;}function _0x25fbff(){const _0x180b31=_0x403da0[_0xe4d228([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x180b31)return!0x1;if(_0x180b31[_0xe4d228([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0xe4d228([0x2a])))return!0x0;if(_0x180b31[_0xe4d228([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0xe4d228([0x52,0x48])))return!0x0;if(_0x180b31[_0xe4d228([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0xe4d228([0x52,0x52,0x48]))){if(_0x1202d9())return!0x0;if(_0x1bc499()||_0x15c4da())return!0x0;}return!0x1;}function _0x404dcd(){const _0x511a43=_0x403da0[_0xe4d228([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x511a43||0x0==_0x511a43[_0xe4d228([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0xc0d5b6}=new URL(window[_0xe4d228([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x511a43[_0xe4d228([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0xc0d5b6))return!0x0;const _0x222d36=_0xc0d5b6[_0xe4d228([0x73,0x70,0x6c,0x69,0x74])](_0xe4d228([0x2e]));return _0x511a43[_0xe4d228([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x4e84f4=>_0x4e84f4[_0xe4d228([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0xe4d228([0x2a])))[_0xe4d228([0x6d,0x61,0x70])](_0x3d8330=>_0x3d8330[_0xe4d228([0x73,0x70,0x6c,0x69,0x74])](_0xe4d228([0x2e])))[_0xe4d228([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x3cf6b8=>_0x3cf6b8[_0xe4d228([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x222d36[_0xe4d228([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0xe4d228([0x6d,0x61,0x70])](_0x25cfee=>Array(_0x222d36[_0xe4d228([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0x25cfee[_0xe4d228([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0xe4d228([0x66,0x69,0x6c,0x6c])](_0x25cfee[0x0]===_0xe4d228([0x2a])?_0xe4d228([0x2a]):'')[_0xe4d228([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0x25cfee))[_0xe4d228([0x73,0x6f,0x6d,0x65])](_0x162c78=>_0x222d36[_0xe4d228([0x65,0x76,0x65,0x72,0x79])]((_0x5a643e,_0x1f1435)=>_0x162c78[_0x1f1435]===_0x5a643e||_0x162c78[_0x1f1435]===_0xe4d228([0x2a])));}function _0x3f7a98(){return _0x4f1c1d&&_0x2ec3d6?new window[(_0xe4d228([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x4f7430,_0xbeff6a)=>{_0x4f1c1d[_0xe4d228([0x74,0x68,0x65,0x6e])](_0x4f7430,_0xbeff6a),_0x2ec3d6[_0xe4d228([0x74,0x68,0x65,0x6e])](_0x42f516=>{_0x42f516!=_0xe4d228([0x56,0x61,0x6c,0x69,0x64])&&_0x4f7430(_0x42f516);},_0xbeff6a);}):_0x4f1c1d||_0x2ec3d6||_0xe4d228([0x56,0x61,0x6c,0x69,0x64]);}}function _0x551cd0(_0x48dc0d,_0x1a25c4){return new window[(_0xe4d228([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2de4f1=>{if(_0x308708())return _0x2de4f1(_0xe4d228([0x56,0x61,0x6c,0x69,0x64]));_0x2cf589(),_0x5f140a[_0xe4d228([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0xe4d228([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x20c004=!0x1;const _0x30582e=_0x8d6220();function _0x561c2d(_0x15694a){return!!_0x15694a&&(typeof _0x15694a===_0xe4d228([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x15694a===_0xe4d228([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x15694a[_0xe4d228([0x74,0x68,0x65,0x6e])]===_0xe4d228([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x15694a[_0xe4d228([0x63,0x61,0x74,0x63,0x68])]===_0xe4d228([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x4f908c(_0xc3ee1a){_0xfe746d(_0xc3ee1a)[_0xe4d228([0x74,0x68,0x65,0x6e])](_0x434249=>{if(!_0x434249||_0x434249[_0xe4d228([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0xe4d228([0x6f,0x6b]))return _0xe4d228([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x218aad(_0x247f5e(_0x30582e+_0x1a25c4))!=_0x434249[_0xe4d228([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0xe4d228([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0xe4d228([0x56,0x61,0x6c,0x69,0x64]);})[_0xe4d228([0x74,0x68,0x65,0x6e])](_0x17b855=>(_0x4110b9(),_0x17b855),()=>{const _0x32fbb8=_0x5a7395();return null==_0x32fbb8?(_0x4110b9(),_0xe4d228([0x56,0x61,0x6c,0x69,0x64])):_0xe4d228(_0x3605fc-_0x32fbb8>(0x11928db0^_0x47043d)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0xe4d228([0x74,0x68,0x65,0x6e])](_0x2de4f1)[_0xe4d228([0x63,0x61,0x74,0x63,0x68])](()=>{_0x2de4f1(_0xe4d228([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0xf2b023=0x35a8e730^_0x47043d;function _0x4110b9(){const _0x1f3d95=_0xe4d228([0x6c,0x6c,0x63,0x74,0x2d])+_0x218aad(_0x247f5e(_0x48dc0d)),_0x2d5c25=_0x13fb57(_0x218aad(window[_0xe4d228([0x4d,0x61,0x74,0x68])][_0xe4d228([0x63,0x65,0x69,0x6c])](_0x3605fc/_0xf2b023)));window[_0xe4d228([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0xe4d228([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x1f3d95,_0x2d5c25);}function _0x5a7395(){const _0x3408cc=_0xe4d228([0x6c,0x6c,0x63,0x74,0x2d])+_0x218aad(_0x247f5e(_0x48dc0d)),_0x1df657=window[_0xe4d228([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0xe4d228([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x3408cc);return _0x1df657?window[_0xe4d228([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x13fb57(_0x1df657),0x10)*_0xf2b023:null;}function _0xfe746d(_0x5bc49d){return new window[(_0xe4d228([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x1a9785,_0x29ba09)=>{_0x5bc49d[_0xe4d228([0x74,0x68,0x65,0x6e])](_0x1a9785,_0x29ba09),window[_0xe4d228([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x29ba09,0x359fdd70^_0x47043d);});}}_0x5f140a[_0xe4d228([0x6f,0x6e])](_0xe4d228([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x571cc9,_0x4452e0)=>{if(_0x4452e0[0x0]!=_0x48dc0d)return _0x2de4f1(_0xe4d228([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x4452e0[0x1]={..._0x4452e0[0x1],[_0xe4d228([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x30582e};},{[_0xe4d228([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0xe4d228([0x68,0x69,0x67,0x68])}),_0x5f140a[_0xe4d228([0x6f,0x6e])](_0xe4d228([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x3d7445=>{_0x561c2d(_0x3d7445[_0xe4d228([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x20c004=!0x0,_0x4f908c(_0x3d7445[_0xe4d228([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0xe4d228([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0xe4d228([0x6c,0x6f,0x77])}),_0x20f4cf[_0xe4d228([0x74,0x68,0x65,0x6e])](()=>{_0x20c004||_0x2de4f1(_0xe4d228([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x308708(){return _0x5f140a[_0xe4d228([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0xe4d228([0x76,0x69,0x65,0x77])][_0xe4d228([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0xe4d228([0x61,0x75,0x74,0x6f]);}function _0x2cf589(){_0x5f140a[_0xe4d228([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0xe4d228([0x76,0x69,0x65,0x77])][_0xe4d228([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0xe4d228([0x61,0x75,0x74,0x6f]);}}function _0x58343a(_0x1dc50b){const _0x39107a=[new window[(_0xe4d228([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x74fe5a=>setTimeout(_0x74fe5a,0x3597377c^_0x47043d)),_0x20f4cf[_0xe4d228([0x74,0x68,0x65,0x6e])](()=>new window[(_0xe4d228([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x54038f=>{const _0x4edabf=0x359e09b7^_0x47043d,_0x4e8e6a=_0x70a1ae[_0xe4d228([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x145456(){_0x4e8e6a[_0xe4d228([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x4edabf&&_0x54038f();}_0x145456(),_0x4e8e6a[_0xe4d228([0x6f,0x6e])](_0xe4d228([0x61,0x64,0x64]),_0x145456);})),new window[(_0xe4d228([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x4347dc=>{function _0x32a5d9(){for(const _0x4f9ebd in window)if(window[_0xe4d228([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0xe4d228([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x4f9ebd))&&window[_0x4f9ebd]==_0x19d5e9)return _0x4347dc();_0x5f140a[_0xe4d228([0x73,0x74,0x61,0x74,0x65])]!=_0xe4d228([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0xe4d228([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x32a5d9,0x359e1a38^_0x47043d);}_0x3a42b0(_0xe4d228([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x32a5d9();})];return window[_0xe4d228([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0xe4d228([0x72,0x61,0x63,0x65])](_0x39107a)[_0xe4d228([0x74,0x68,0x65,0x6e])](()=>_0x1dc50b);}async function _0x225c48(){if(await _0x20f4cf,_0x3a42b0(_0xe4d228([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x51f8e7=_0x70a1ae[_0xe4d228([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x1e7772=_0x70a1ae[_0xe4d228([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])](_0x51f8e7[_0xe4d228([0x69,0x64])]),_0x52ab4b=_0x479ae7(_0xe4d228([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x52ab4b[_0xe4d228([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x51f8e7['id'],_0x1e7772?_0x1e7772['id']:null,!0x0),_0x52ab4b[_0xe4d228([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0xe4d228([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x52ab4b[_0xe4d228([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x52ab4b[_0xe4d228([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x1f5f31,void(_0x52ab4b[_0xe4d228([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x1f5f31);}if(_0x3a42b0(_0xe4d228([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x102e7f=_0x479ae7(_0xe4d228([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x102e7f[_0xe4d228([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0xe4d228([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x102e7f[_0xe4d228([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x102e7f[_0xe4d228([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x1f5f31,_0x102e7f[_0xe4d228([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x1f5f31;}_0x5f140a[_0xe4d228([0x6d,0x6f,0x64,0x65,0x6c])][_0xe4d228([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x1f5f31,_0x5f140a[_0xe4d228([0x6d,0x6f,0x64,0x65,0x6c])][_0xe4d228([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x1f5f31,_0x5f140a[_0xe4d228([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0xe4d228([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x1202d9(){return _0x3a42b0(_0xe4d228([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x479ae7(_0xe4d228([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0xe4d228([0x73,0x74,0x61,0x74,0x65])]==_0xe4d228([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x1bc499(){return _0x3a42b0(_0xe4d228([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 _0x15c4da(){return _0x3a42b0(_0xe4d228([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x4b7743(_0x2364e9){const _0x524053=_0x4ba275();_0x5f140a[_0x524053]=_0xe4d228([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])+_0x2364e9,_0x2364e9[_0xe4d228([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0xe4d228([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x4ba275()]=_0x19d5e9),_0x2364e9!=_0xe4d228([0x56,0x61,0x6c,0x69,0x64])&&_0x225c48();}function _0x4ba275(){const _0x38be9d=window[_0xe4d228([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0xe4d228([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0xe4d228([0x6e,0x6f,0x77])]())[_0xe4d228([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0xe4d228([0x2e]),'');let _0x56180c=_0xe4d228([0x76]);for(let _0x33d121=0x0;_0x33d121<_0x38be9d[_0xe4d228([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x33d121+=0x2){let _0x5b0d61=window[_0xe4d228([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x38be9d[_0xe4d228([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x33d121,_0x33d121+0x2));_0x5b0d61>=_0x55fb2c[_0xe4d228([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x5b0d61-=_0x55fb2c[_0xe4d228([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x56180c+=_0x55fb2c[_0x5b0d61];}return _0x56180c;}function _0x111605(){const _0x217fa2=_0x49d941[_0xe4d228([0x73,0x70,0x6c,0x69,0x74])](_0xe4d228([0x2e]));if(0x3!=_0x217fa2[_0xe4d228([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0xf5ac26(_0x217fa2[0x1]);function _0xf5ac26(_0x3fcb0d){const _0x158569=_0x289829(_0x3fcb0d);return _0x158569&&_0xb34f62()?_0x158569:null;function _0xb34f62(){const _0x2ac830=_0x158569[_0xe4d228([0x6a,0x74,0x69])],_0x94a66a=window[_0xe4d228([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x2ac830[_0xe4d228([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x2ac830[_0xe4d228([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x5b315b={..._0x158569,[_0xe4d228([0x6a,0x74,0x69])]:_0x2ac830[_0xe4d228([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x2ac830[_0xe4d228([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x5b315b[_0xe4d228([0x76,0x63])],_0x247f5e(_0x5b315b)==_0x94a66a;}}}async function _0x433434(){let _0x246458=!0x0;try{const _0x330ec8=_0x49d941[_0xe4d228([0x73,0x70,0x6c,0x69,0x74])](_0xe4d228([0x2e])),[_0x4b77fe,_0x40af3e,_0x2f37d9]=_0x330ec8;return _0x25a7f2(_0x4b77fe),await _0x20d782(_0x4b77fe,_0x40af3e,_0x2f37d9),_0x246458;}catch{return!0x1;}function _0x25a7f2(_0xdaeee3){const _0x5e4cee=_0x289829(_0xdaeee3);_0x5e4cee&&_0x5e4cee[_0xe4d228([0x61,0x6c,0x67])]==_0xe4d228([0x45,0x53,0x32,0x35,0x36])||(_0x246458=!0x1);}async function _0x20d782(_0x2af54b,_0x25e25b,_0x24c66e){const _0x476c07=window[_0xe4d228([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0xe4d228([0x66,0x72,0x6f,0x6d])](_0x588d75(_0x24c66e),_0x23c16d=>_0x23c16d[_0xe4d228([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x50bace=new window[(_0xe4d228([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0xe4d228([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x2af54b+_0xe4d228([0x2e])+_0x25e25b),_0x5dc7d1=window[_0xe4d228([0x63,0x72,0x79,0x70,0x74,0x6f])][_0xe4d228([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x5dc7d1)return;const _0x3e0aae=await _0x5dc7d1[_0xe4d228([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0xe4d228([0x6a,0x77,0x6b]),_0x2339f5,{[_0xe4d228([0x6e,0x61,0x6d,0x65])]:_0xe4d228([0x45,0x43,0x44,0x53,0x41]),[_0xe4d228([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0xe4d228([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0xe4d228([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x5dc7d1[_0xe4d228([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0xe4d228([0x6e,0x61,0x6d,0x65])]:_0xe4d228([0x45,0x43,0x44,0x53,0x41]),[_0xe4d228([0x68,0x61,0x73,0x68])]:{[_0xe4d228([0x6e,0x61,0x6d,0x65])]:_0xe4d228([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x3e0aae,_0x476c07,_0x50bace)||(_0x246458=!0x1);}}function _0x289829(_0x2eb837){return _0x2eb837[_0xe4d228([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0xe4d228([0x65,0x79]))?JSON[_0xe4d228([0x70,0x61,0x72,0x73,0x65])](_0x588d75(_0x2eb837)):null;}function _0x588d75(_0x3ceb26){return window[_0xe4d228([0x61,0x74,0x6f,0x62])](_0x3ceb26[_0xe4d228([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0xe4d228([0x2b]))[_0xe4d228([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0xe4d228([0x2f])));}function _0x247f5e(_0x7506d5){let _0x3556a8=0x1505;function _0x2d209f(_0x118129){for(let _0x550142=0x0;_0x550142<_0x118129[_0xe4d228([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x550142++){const _0x27180c=_0x118129[_0xe4d228([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x550142);_0x3556a8=(_0x3556a8<<0x5)+_0x3556a8+_0x27180c,_0x3556a8&=_0x3556a8;}}function _0x8b254c(_0x4b5668){Array[_0xe4d228([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x4b5668)?_0x4b5668[_0xe4d228([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x8b254c):_0x4b5668&&typeof _0x4b5668==_0xe4d228([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0xe4d228([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x4b5668)[_0xe4d228([0x73,0x6f,0x72,0x74])]()[_0xe4d228([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x10c803,_0x2c598b])=>{_0x2d209f(_0x10c803),_0x8b254c(_0x2c598b);}):_0x2d209f(window[_0xe4d228([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x4b5668));}return _0x8b254c(_0x7506d5),_0x3556a8>>>0x0;}function _0x218aad(_0x474a24){return _0x474a24[_0xe4d228([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0xe4d228([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0xe4d228([0x30]));}function _0x13fb57(_0x2ae56b){return _0x2ae56b[_0xe4d228([0x73,0x70,0x6c,0x69,0x74])]('')[_0xe4d228([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0xe4d228([0x6a,0x6f,0x69,0x6e])]('');}function _0x3a42b0(_0x3b73ee){return _0x5f140a[_0xe4d228([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0xe4d228([0x68,0x61,0x73])](_0x3b73ee);}function _0x479ae7(_0x23dd46){return _0x5f140a[_0xe4d228([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0xe4d228([0x67,0x65,0x74])](_0x23dd46);}function _0x1f5f31(){}function _0xe4d228(_0x1f4e2e){return _0x1f4e2e['map'](_0x4aa5f1=>String['fromCharCode'](_0x4aa5f1))['join']('');}_0x4b7743(await _0x52195d());}(this);}['createRevision'](_0x463026){const _0x9bd8c2=this['editor']['plugins']['get']('Users');return new I({'id':_0x463026['id'],'name':_0x463026['name'],'creator':_0x463026['creatorId']?_0x9bd8c2['getUser'](_0x463026['creatorId']):null,'diffData':_0x463026['diffData']||_0x463026['data'],'authors':_0x463026['authorsIds']['map'](_0x3d70cf=>_0x9bd8c2['getUser'](_0x3d70cf)),'createdAt':new Date(_0x463026['createdAt']),'attributes':_0x463026['attributes'],'fromVersion':_0x463026['fromVersion'],'toVersion':_0x463026['toVersion']});}['addRevision'](_0x560ad2,_0xb7d956=0x0){this['_revisions']['add'](_0x560ad2,_0xb7d956);}['getRevision'](_0x20c0a1){return this['_revisions']['get'](_0x20c0a1);}['getRevisions'](_0x5e091b={'toJSON':!0x1}){const _0x152591=Array['from'](this['_revisions']);return _0x152591['reverse'](),_0x5e091b['toJSON']?_0x152591['map'](_0x40922a=>_0x40922a['toJSON']()):_0x152591;}['getIndex'](_0x19b21e){return this['_revisions']['getIndex'](_0x19b21e);}['getEarlierVisibleRevision'](_0xc1585f){const [,_0x33e82b]=this['getRevisionsIterator'](_0xc1585f,{'direction':'earlier'});return _0x33e82b;}['getLaterVisibleRevision'](_0x114a48){const [,_0x5af305]=this['getRevisionsIterator'](_0x114a48,{'direction':'later'});return _0x5af305;}['getRevisionsInDiff'](_0x259123){const _0xb70c69=[];for(const _0x24cb14 of this['getRevisionsIterator'](_0x259123['newRevisionId']))if(_0xb70c69['push'](_0x24cb14),_0x24cb14['id']===_0x259123['oldRevisionId'])break;return _0xb70c69;}*['getRevisionsIterator'](_0xc3f09a,{direction:_0x106547='earlier',filter:_0x415dfa=()=>!0x0}={}){const _0x2d4375='earlier'===_0x106547?0x1:-0x1;let _0x29006c=this['_revisions']['get'](_0xc3f09a),_0x27f626=this['getIndex'](_0x29006c);for(yield _0x29006c;_0x29006c;){if(_0x27f626+=_0x2d4375,_0x29006c=this['getRevision'](_0x27f626),!_0x29006c)return;_0x415dfa(_0x29006c)&&(yield _0x29006c);}}}class $ extends _0x5ac587{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x28f766,'c'],[_0x32b442,'a'],[_0x304e10,'e'],[_0x483df8,'r'],[_0x27969c,'u']]);['_typeCharToViewClass']=new Map([['c',_0x28f766],['a',_0x32b442],['e',_0x304e10],['r',_0x483df8],['u',_0x27969c]]);async['loadRevisionData'](_0x515d69,_0x2ea901){if(_0x515d69['diffData']||!_0x2ea901)return;const _0x23c602=this['editor']['config']['get']('collaboration.channelId'),_0x1949a5=await _0x2ea901['getRevision']({'channelId':_0x23c602,'revisionId':_0x515d69['id']});_0x515d69['diffData']=_0x1949a5['diffData'];}['getRevisionDocumentData'](_0x5ccdfd){const _0x500fdb={};for(const _0x29af07 in _0x5ccdfd['diffData']){if(_0x5ccdfd['diffData'][_0x29af07]['attachChange']&&!_0x5ccdfd['diffData'][_0x29af07]['attachChange']['isAttached'])continue;const _0x3fca47=this['_removeRevisionMarkers'](JSON['parse'](_0x5ccdfd['diffData'][_0x29af07]['insertions'])),_0xf97bb1=this['editor']['editing']['view']['document'],_0x6cae4b=new _0x2bc6e7(_0xf97bb1,_0x3fca47['map'](_0x4084b0=>this['_getViewFromDiffObj'](_0x4084b0,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x500fdb[_0x29af07]=this['editor']['data']['processor']['toData'](_0x6cae4b),this['editor']['data']['processor']['useFillerType']('default');}return _0x500fdb;}['getRevisionRootsAttributes'](_0x1defe1){const _0x29c1b4={};for(const _0x2c873a in _0x1defe1['diffData'])_0x1defe1['diffData'][_0x2c873a]['attachChange']&&!_0x1defe1['diffData'][_0x2c873a]['attachChange']['isAttached']||(_0x29c1b4[_0x2c873a]=_0x1defe1['diffData'][_0x2c873a]['attributesAfter']||{});return _0x29c1b4;}['_getTypeCharForViewElement'](_0x385e88){return this['_viewClassToTypeChar']['get'](_0x385e88['constructor']);}['_getViewFromDiffObj'](_0x4e834f,_0x1db870){const _0xda8d44=this['editor']['editing']['view']['document'];if('string'==typeof _0x4e834f)return new _0x3879cc(_0xda8d44,_0x4e834f);{let _0x4556fb,_0x1c09b0;_0x1c09b0='u'==_0x4e834f['type']||'r'==_0x4e834f['type']?[]:_0x4e834f['children']['map'](_0x3a8f06=>this['_getViewFromDiffObj'](_0x3a8f06,_0x1db870));const _0x2d829b=this['_typeCharToViewClass']['get'](_0x4e834f['type'])||_0x49516b,_0x517921=this['editor']['data']['htmlProcessor']['domConverter'];if(_0x4556fb=new _0x2d829b(_0xda8d44,_0x4e834f['name'],_0x4e834f['attributes'],_0x1c09b0),'u'==_0x4e834f['type']&&_0x4e834f['children'][0x0]){const _0x24827c=_0x4e834f['children'][0x0];if(_0x4556fb['render']=function(_0x48b203){const _0x5c0204=_0x48b203['createElement']('div');return _0x5c0204['innerHTML']=_0x24827c,_0x5c0204['childNodes'][0x0];},_0x1db870){const _0x78cbdf=new _0x2bc6e7(_0xda8d44);_0x78cbdf['_appendChild'](_0x4556fb);const _0x32453e=Array['from'](_0x517921['viewChildrenToDom'](_0x78cbdf,{'bind':!0x1})),_0x1f9af4=_0x517921['domDocument']['createElement']('div');_0x1f9af4['append'](..._0x32453e),_0x4556fb=Array['from'](_0x517921['domChildrenToView'](_0x1f9af4))[0x0];}}else{if('r'==_0x4e834f['type']&&_0x4e834f['children'][0x0]){const _0x528c85=_0x4e834f['children'][0x0];if(_0x4556fb['render']=function(_0x4c0cb1){_0x4c0cb1['innerHTML']=_0x528c85;},_0x1db870){const _0x119cd2=new _0x2bc6e7(_0xda8d44);_0x119cd2['_appendChild'](_0x4556fb);const _0x1584ed=Array['from'](_0x517921['viewChildrenToDom'](_0x119cd2,{'bind':!0x1})),_0x376ef9=_0x517921['domDocument']['createElement']('div');_0x376ef9['append'](..._0x1584ed);const _0x1da21d=Array['from'](_0x517921['domChildrenToView'](_0x376ef9));_0x1da21d['length']>0x1?_0x4556fb['_appendChild'](_0x1da21d):_0x4556fb=_0x1da21d[0x0];}}}if(_0x4e834f['customProperties']){for(const [_0x2ea926,_0x250380]of _0x4e834f['customProperties'])_0x4556fb['_setCustomProperty'](_0x2ea926,_0x250380);}const _0x3cbaeb=void 0x0===_0x4e834f['fillerOffset']?null:_0x4e834f['fillerOffset'];return null!==_0x3cbaeb&&(_0x4556fb['getFillerOffset']=()=>_0x3cbaeb),_0x4556fb;}}['_makeModelFromViewString'](_0x48b9cd){const _0x24c21e=JSON['parse'](_0x48b9cd),_0x2fd077=this['editor']['editing']['view']['document'],_0x2277ec=new _0x2bc6e7(_0x2fd077,_0x24c21e['map'](_0x51be80=>this['_getViewFromDiffObj'](_0x51be80,!0x0)));return this['editor']['data']['toModel'](_0x2277ec);}['_removeRevisionMarkers'](_0x10fb33){return(_0x10fb33=_0x10fb33['filter'](_0x1f7b77=>!_0x1f7b77['name']||'revision-start'!==_0x1f7b77['name']&&'revision-end'!==_0x1f7b77['name']))['forEach'](_0x5752f4=>{'string'!=typeof _0x5752f4&&(_0x5752f4['children']=this['_removeRevisionMarkers'](_0x5752f4['children']),_0x5752f4['attributes']=_0x5752f4['attributes']['filter'](_0x2a0690=>!_0x2a0690[0x0]['startsWith']('data-revision-')));}),_0x10fb33;}}function m(_0x296eba,_0x675470,_0x528f2b){const t=_0x296eba['t'];switch(_0x675470){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'},_0x528f2b);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x528f2b);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 h extends _0x5ac587{['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[_0x280554,S,$,_0x3dfd76];}constructor(_0x52c055){super(_0x52c055),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 _0x3ba58a=_0x8d6220();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x3ba58a},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 _0x4e65b9=this['repository']['getRevision'](0x0),_0x46764b=_0x4e65b9&&null===_0x4e65b9['creator']?_0x4e65b9:null;if(this['_continueCurrentRevision']=!!_0x46764b&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x3cf894=this['_source']['getCurrentRevisionId'](),_0x7033c8=this['repository']['getRevision'](_0x3cf894);if(_0x7033c8)this['_startingVersion']=_0x7033c8['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x110cef=this['_source']['history']['_operations']['find'](_0x1477cb=>!_0x1477cb['_isInit']),_0x112b02=_0x110cef?_0x110cef['baseVersion']:this['_source']['history']['version'];_0x4e65b9?(_0x4e65b9['toVersion']<_0x112b02&&_0x4e65b9['_update']({'toVersion':_0x112b02}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x46764b['id'],this['_startingVersion']=_0x46764b['fromVersion']):(this['_startingVersion']=_0x4e65b9['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x112b02,this['_continueCurrentRevision']=!0x1);}}else _0x46764b&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x46764b['toVersion'],this['editor']['model']['document']['history']['version']),_0x46764b['fromVersion']===_0x46764b['toVersion']?(0x0!==_0x46764b['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x46764b['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x46764b['id'],this['_startingVersion']=_0x46764b['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',_0x4a356a=>!_0x4a356a),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x48c82f=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x32cc5c;for(const _0x1e33bb in _0x48c82f){const _0xa5da74=_0x1e33bb,_0x15a8fb=_0x48c82f[_0xa5da74];if('revisionHistoryLicenseKeyValid'==_0x15a8fb||'revisionHistoryLicenseKeyInvalid'==_0x15a8fb||'revisionHistoryLicenseKeyExpired'==_0x15a8fb||'revisionHistoryLicenseKeyDomainLimit'==_0x15a8fb||'revisionHistoryLicenseKeyNotAllowed'==_0x15a8fb||'revisionHistoryLicenseKeyEvaluationLimit'==_0x15a8fb||'revisionHistoryLicenseKeyUsageLimit'==_0x15a8fb){delete _0x48c82f[_0xa5da74],_0x32cc5c=_0x15a8fb,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x32cc5c&&_0x48c82f['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x32cc5c&&_0x48c82f['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x32cc5c&&_0x48c82f['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x32cc5c&&_0x48c82f['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x32cc5c&&_0x48c82f['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x32cc5c&&_0x48c82f['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x14768c=this['repository']['getRevision'](0x0),_0x20f4d1=await this['getRevisionDocumentData'](_0x14768c),_0x4f0265=await this['getRevisionRootsAttributes'](_0x14768c);this['_replaceEditorDataWithRevisionData'](_0x20f4d1,_0x4f0265);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x381bdd){this['_source']=_0x381bdd;}async['update'](){const _0x2d43e5=await this['_source']['getLatestVersion']();if(_0x2d43e5>this['currentRevision']['toVersion']){await this['_loadState']();const _0x3ba9e3=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x2d43e5});_0x3ba9e3['authors']=_0x3ba9e3['authorsIds']['map'](_0x35b5b3=>this['editor']['plugins']['get']('Users')['getUser'](_0x35b5b3)),this['currentRevision']['_update'](_0x3ba9e3);}}async['saveRevision'](_0x3686a3={},_0x11a03e=null){const _0x3fab5f=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x11a03e>this['currentRevision']['toVersion']&&(_0x11a03e=null),null===_0x11a03e&&(_0x11a03e=await this['_source']['getLatestVersion']());const _0x416096=this['_getFromVersion'](_0x11a03e),_0x52e4e9=this['buildRevisionData']({'from':_0x416096,'to':_0x11a03e});if(this['currentRevision']['toVersion']<_0x11a03e){const _0x306e6d=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x11a03e,'to':_0x11a03e});_0x306e6d['authors']=[],_0x306e6d['authorsIds']=[],_0x306e6d['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x306e6d,!0x0),delete _0x306e6d['authors'],_0x3fab5f['push'](_0x306e6d);}_0x3686a3['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x3686a3['name']=_0x3686a3['name']||null,_0x3686a3['id']=_0x3686a3['id']||_0x8d6220(),_0x3686a3={..._0x3686a3,..._0x52e4e9};const _0x99d7d8=this['addRevisionData'](_0x3686a3);_0x3fab5f['push'](_0x3686a3);const _0x11d4b4=this['repository']['getIndex'](_0x99d7d8);if(0x0!==_0x11d4b4){const _0x16e271=this['repository']['getRevision'](_0x11d4b4-0x1);if(_0x16e271['fromVersion']!==_0x11a03e){const _0x48edd4=this['_revisionDataBuilder']['getData'](_0x11a03e,_0x16e271['toVersion']),_0x43362b={'id':_0x16e271['id'],'diffData':_0x48edd4['diffData'],'authorsIds':_0x48edd4['authorsIds'],'authors':_0x48edd4['authorsIds']['map'](_0x556fe5=>this['editor']['plugins']['get']('Users')['getUser'](_0x556fe5)),'fromVersion':_0x11a03e};_0x16e271===this['currentRevision']&&(_0x43362b['createdAt']=new Date(_0x3686a3['createdAt']['getTime']()+0xa)),_0x16e271['_update'](_0x43362b,!0x0),delete _0x43362b['authors'],_0x3fab5f['push'](_0x43362b);}}if(this['adapter']){for(const _0x50498b of _0x3fab5f)this['_bufferUpdate'](_0x50498b['id'],_0x50498b,!0x0);this['sendBufferedUpdates']();}return _0x99d7d8;}['addRevisionData'](_0x27cb1d){const _0x408bff=this['repository']['createRevision'](_0x27cb1d);return this['adapter']&&_0x408bff['on']('_update',(_0x252eef,_0x3f71bc,_0x201098)=>{_0x201098||(this['_bufferUpdate'](_0x3f71bc['id'],_0x3f71bc,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x408bff,this['_findInsertionIndex'](_0x408bff)),_0x408bff;}async['getRevisionDocumentData'](_0x3d1b3c){return await this['_utils']['loadRevisionData'](_0x3d1b3c,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x3d1b3c);}async['getRevisionRootsAttributes'](_0x2b9e06){return await this['_utils']['loadRevisionData'](_0x2b9e06,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x2b9e06);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x252d01=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x40382c=0x0;_0x40382c<_0x252d01['length'];_0x40382c++){const _0x294063=_0x252d01[_0x40382c];let _0xf5944c=!0x1;for(const _0x1100dd of Object['keys'](_0x294063))void 0x0===_0x294063[_0x1100dd]?delete _0x294063[_0x1100dd]:'id'!==_0x1100dd&&(_0xf5944c=!0x0);_0xf5944c||(_0x252d01[_0x40382c]=null);}if(_0x252d01=_0x252d01['filter'](_0x336af0=>null!==_0x336af0),!_0x252d01['length'])return;for(let _0x4ef9c1=0x0;_0x4ef9c1<_0x252d01['length'];_0x4ef9c1++){const _0x595d7b=_0x252d01[_0x4ef9c1];void 0x0!==_0x595d7b['fromVersion']&&void 0x0===_0x595d7b['toVersion']&&(_0x595d7b['toVersion']=this['repository']['getRevision'](_0x595d7b['id'])['toVersion']),void 0x0!==_0x595d7b['toVersion']&&void 0x0===_0x595d7b['fromVersion']&&(_0x595d7b['fromVersion']=this['repository']['getRevision'](_0x595d7b['id'])['fromVersion']);}const _0x516c8d=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x252d01,_0x516c8d)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x51e624=>{if(_0x51e624){for(const _0x1ea385 of _0x51e624)this['setRevisionData']({'id':_0x1ea385['id'],'createdAt':_0x1ea385['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0x1f0c27=null,from:_0x6a26f6=null,to:_0x429caa=null}){_0x6a26f6=null!==_0x6a26f6?_0x6a26f6:_0x1f0c27['fromVersion'],_0x429caa=null!==_0x429caa?_0x429caa:_0x1f0c27['toVersion'];const _0x13bf40=this['_revisionDataBuilder']['getData'](_0x6a26f6,_0x429caa),_0x4d0f61={'diffData':_0x13bf40['diffData'],'authorsIds':_0x13bf40['authorsIds'],'fromVersion':_0x6a26f6,'toVersion':_0x429caa};if(!_0x1f0c27||_0x429caa!==_0x1f0c27['toVersion']){const _0x59c9bf=_0x429caa-0x1,_0x5c2f16=this['_source']['history']['getOperation'](_0x59c9bf);_0x4d0f61['createdAt']=_0x5c2f16&&_0x5c2f16['createdAt']||new Date();}if(this['_loadedStateData']&&_0x6a26f6===this['_loadedStateData']['fromVersion']){for(const _0x3063f6 of this['_loadedStateData']['authors'])_0x4d0f61['authorsIds']['includes'](_0x3063f6['id'])||_0x4d0f61['authorsIds']['push'](_0x3063f6['id']);}return _0x4d0f61;}['_bufferUpdate'](_0x503fd8,_0x2db9bc,_0x19ccd4){if(this['_bufferedUpdates']['has'](_0x503fd8)){const _0x1d6c0c=this['_bufferedUpdates']['get'](_0x503fd8);_0x2db9bc=_0x19ccd4?{..._0x1d6c0c,..._0x2db9bc}:{..._0x2db9bc,..._0x1d6c0c};}this['_bufferedUpdates']['set'](_0x503fd8,_0x2db9bc);}['setRevisionData'](_0x3361d3){const _0x4e9992=this['repository']['getRevision'](_0x3361d3['id']);if(_0x3361d3['createdAt']&&(_0x3361d3['createdAt']=new Date(_0x3361d3['createdAt'])),_0x3361d3['authorsIds']){const _0xaf87e6=this['editor']['plugins']['get']('Users');_0x3361d3['authors']=_0x3361d3['authorsIds']['map'](_0x345804=>_0xaf87e6['getUser'](_0x345804));}_0x4e9992['_update'](_0x3361d3,!0x0);}['_createInitialRevision'](_0x4f6df3){const _0x4f1eec=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x4f1eec)this['_initialRevisionId']=_0x4f1eec['id'];else{const _0x4f7934=!this['editor']['model']['document']['roots']['find'](_0x487fcc=>this['editor']['model']['hasContent'](_0x487fcc)),_0x21659a=this['editor']['plugins']['get']('Users')['me']['id'],_0x2e1bde=m(this['editor']['locale'],_0x4f7934?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x4f6df3,'to':_0x4f6df3,'id':this['_initialRevisionId'],'name':_0x2e1bde,'creatorId':_0x21659a});}}['_createCurrentRevision'](_0x2d2335){const _0x115344=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x115344),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x2d2335,'to':_0x2d2335,'id':_0x115344,'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'](_0x228aef,_0x1de01a){let _0xded6a2=this['editor']['config']['get']('initialData'),_0x4d683e=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0xded6a2){_0xded6a2={};for(const _0x227a21 of this['editor']['model']['document']['getRootNames']())_0xded6a2[_0x227a21]='';}if('string'==typeof _0xded6a2&&(_0xded6a2={'main':_0xded6a2}),void 0x0===_0x4d683e){_0x4d683e={};for(const _0x5377b of this['editor']['model']['document']['getRootNames']())_0x4d683e[_0x5377b]={};}let _0x9d97a8=!0x1;const _0x4457ef=Object['keys'](_0xded6a2),_0x261e5a=Object['keys'](_0x228aef);for(const _0x31b775 of _0x4457ef){if(_0xded6a2[_0x31b775]!==_0x228aef[_0x31b775]&&''!==_0xded6a2[_0x31b775]['trim']()){_0x9d97a8=!0x0;break;}if(!_0xba9853(_0x4d683e[_0x31b775],_0x1de01a[_0x31b775])&&Object['keys'](_0x4d683e[_0x31b775])['length']>0x0){_0x9d97a8=!0x0;break;}}_0x9d97a8||(_0x9d97a8=_0x261e5a['some'](_0x489739=>!this['editor']['model']['document']['getRoot'](_0x489739))),_0x9d97a8&&_0x9fdb5c('editor-initial-data-replaced-with-revision-data',{'editorData':_0xded6a2,'editorRootsAttributes':_0x4d683e,'revisionData':_0x228aef,'revisionRootsAttributes':_0x1de01a}),this['editor']['config']['set']('initialData',_0x228aef),this['editor']['config']['set']('rootsAttributes',_0x1de01a);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x2c0899=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x2c0899['add'](m(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x4b3402){const _0x5db21d=this['repository']['getRevisions']();_0x5db21d['reverse']();let _0x10f661=0x0;for(;_0x10f661<_0x5db21d['length'];){const _0x2678ea=_0x5db21d[_0x10f661];if(_0x2678ea===this['currentRevision']){_0x10f661++;continue;}if(_0x2678ea['id']===this['_initialRevisionId'])break;const _0x2e900b=_0x4b3402['toVersion']-_0x2678ea['toVersion']||_0x4b3402['fromVersion']-_0x2678ea['fromVersion'];if(_0x2e900b>0x0)break;if(_0x2e900b<0x0)_0x10f661++;else{if(!_0x4b3402['creator']&&_0x2678ea['creator'])break;if(_0x2678ea['creator']||!_0x4b3402['creator']){if(_0x4b3402['createdAt']>_0x2678ea['createdAt'])break;_0x10f661++;}else _0x10f661++;}}return _0x10f661;}['_getFromVersion'](_0x4addea){const _0x3b7462=this['repository']['getRevisions']();_0x3b7462['reverse'](),_0x3b7462['shift']();const _0x3a3fe2=_0x3b7462['find'](_0x386532=>_0x386532['toVersion']<=_0x4addea)['toVersion'];return _0x3a3fe2<this['_startingVersion']?this['_startingVersion']:_0x3a3fe2;}['_makeRevision']({name:_0x1ec3e3,from:_0x290f7d,to:_0xfbc591,creatorId:_0x471319,id:_0x4205da}){const _0x320542=this['buildRevisionData']({'from':_0x290f7d,'to':_0xfbc591});_0x320542['name']=_0x1ec3e3,_0x320542['creatorId']=_0x471319,_0x320542['id']=_0x4205da;const _0x475d7f=this['addRevisionData'](_0x320542);return this['adapter']&&this['_bufferUpdate'](_0x320542['id'],_0x320542,!0x0),_0x475d7f;}['_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(_0x49b250){this['editor']=_0x49b250,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'](_0x59635b){this['source']=_0x59635b;const _0x1ea777=new Map(),_0x20ead8=new Map(),_0x54ab82=this['editor']['model']['document']['roots']['map'](_0x138099=>_0x138099['rootName']);for(const _0x1e4d80 of _0x54ab82){const _0x7c6221=this['editor']['model']['document']['getRoot'](_0x1e4d80),_0x228ce6=x(_0x7c6221);_0x1ea777['set'](_0x1e4d80,_0x228ce6),_0x20ead8['set'](_0x1e4d80,Object['fromEntries'](_0x7c6221['getAttributes']()));}const _0x4f7f6f=Array['from'](this['editor']['model']['markers'])['map'](_0x4a65d1=>[_0x4a65d1['name'],_0x4a65d1['getRange']()]),_0x3fe714=this['source']['version'];this['_saveMetaData'](_0x3fe714,_0x1ea777,_0x4f7f6f,_0x20ead8),this['_startingRevisionId']=this['_revisionId'];const _0x3e5eb6=new Map(),_0x32fde6=new Map();for(const _0x5d1319 of _0x54ab82){const _0x37560e=K(_0x5d1319);_0x3e5eb6['set'](_0x5d1319,_0x37560e),_0x32fde6['set'](_0x5d1319,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x3e5eb6,[],_0x32fde6);}['getData'](_0x577ad9,_0x5a2055){if(this['_lastFrom']===_0x577ad9&&this['_lastTo']<=_0x5a2055)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x5a2055,!0x0);else{if(!this['_savedMetaData']['has'](_0x577ad9)){const _0x18a1d6=this['_getPreviousFrom'](_0x577ad9);this['_calculateMetaData'](_0x18a1d6,_0x577ad9,!0x1);}this['_calculateMetaData'](_0x577ad9,_0x5a2055,!0x0);}return this['_lastFrom']=_0x577ad9,this['_lastTo']=_0x5a2055,this['_getState']();}['loadState'](_0x2d1745){if(!this['_savedMetaData']['has'](_0x2d1745['fromVersion'])){const _0x442be=this['_getPreviousFrom'](_0x2d1745['fromVersion']);this['_calculateMetaData'](_0x442be,_0x2d1745['fromVersion'],!0x1);}this['_calculateMetaData'](_0x2d1745['fromVersion'],_0x2d1745['toVersion'],!0x1);const _0x68448a=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x2d1745['fromVersion'],this['_lastTo']=_0x2d1745['toVersion'];for(const _0xfbc9bc in _0x2d1745['diffData']){const _0x8afae8=_0x2d1745['diffData'][_0xfbc9bc]['attachChange'],_0x1e34e1=_0xc930c3(_0x2d1745['diffData'][_0xfbc9bc]['attributesBefore'])||{},_0x25b8af=_0x68448a['_makeModelFromViewString'](_0x2d1745['diffData'][_0xfbc9bc]['deletions']);_0x25b8af['rootName']=_0xfbc9bc,_0x25b8af['_isAttached']=!_0x8afae8||!_0x8afae8['isAttached'],_0x25b8af['isAttached']=()=>_0x25b8af['_isAttached'],this['_baseRoots']['set'](_0xfbc9bc,_0x25b8af),this['_baseRootsAttributes']['set'](_0xfbc9bc,_0x1e34e1),_0x8afae8&&this['_touchedRoots']['set'](_0xfbc9bc,_0x8afae8);const _0x5f2934=this['_makeIdsRoot'](_0x25b8af);this['_baseIdsRoots']['set'](_0xfbc9bc,_0x5f2934);for(const [_0x46c90d,_0x1674c0]of _0x25b8af['markers']){if(!_0x46c90d['startsWith']('revision:'))continue;const _0x253150=_0x46c90d['split'](':')[0x2];for(const _0x361ed9 of _0x1674c0['getWalker']({'singleCharacters':!0x0})){const _0x57408e=this['_getVidAttributeName'](_0x361ed9),_0x27a543='elementEnd'==_0x361ed9['type']?_0x361ed9['previousPosition']['path']['slice'](0x0,-0x1):_0x361ed9['previousPosition']['path'],_0x227ec5=_0x5f2934['getNodeByPath'](_0x27a543)['getAttribute'](_0x57408e);this['_touched']['set'](_0x227ec5,{'userId':_0x253150});}_0x25b8af['markers']['delete'](_0x46c90d);}}this['_startingRevisionId']=this['_revisionId'];const _0x117395=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x151dc8=>!this['_touched']['has'](_0x151dc8));let _0x293e22=0x0;const _0x19366d=new Map();for(const _0x20abfe in _0x2d1745['diffData']){const _0x3fe7f0=_0x2d1745['diffData'][_0x20abfe]['attachChange'],_0x47a309=_0xc930c3(_0x2d1745['diffData'][_0x20abfe]['attributesAfter'])||{},_0x2cc620=_0x68448a['_makeModelFromViewString'](_0x2d1745['diffData'][_0x20abfe]['insertions']);_0x2cc620['rootName']=_0x20abfe,_0x2cc620['_isAttached']=!_0x3fe7f0||_0x3fe7f0['isAttached'],_0x2cc620['isAttached']=()=>_0x2cc620['_isAttached'],this['_diffRoots']['set'](_0x20abfe,_0x2cc620),this['_diffRootsAttributes']['set'](_0x20abfe,_0x47a309);const _0x488e2b=this['_makeIdsRoot'](_0x2cc620,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x20abfe,_0x488e2b),_0x19366d['set'](_0x20abfe,_0x2cc620['isAttached']()?_0x47a309:{});for(const [_0x10cf82,_0x58db15]of _0x2cc620['markers']){if(!_0x10cf82['startsWith']('revision:'))continue;const _0x5c5169=_0x10cf82['split'](':')[0x2];for(const _0x33c621 of _0x58db15['getWalker']({'singleCharacters':!0x0})){const _0x1caa1d=this['_getVidAttributeName'](_0x33c621),_0x1ded96=this['_revisionId']++,_0x55e04b='elementEnd'==_0x33c621['type']?_0x33c621['previousPosition']['path']['slice'](0x0,-0x1):_0x33c621['previousPosition']['path'];_0x488e2b['getNodeByPath'](_0x55e04b)['_setAttribute'](_0x1caa1d,_0x1ded96),this['_touched']['set'](_0x1ded96,{'userId':_0x5c5169});}_0x2cc620['markers']['delete'](_0x10cf82);}for(const _0x156cad of this['editor']['model']['createRangeIn'](_0x2cc620)['getWalker']({'singleCharacters':!0x0})){const _0x1e6509=this['_getVidAttributeName'](_0x156cad),_0x3368f6='elementEnd'==_0x156cad['type']?_0x156cad['previousPosition']['path']['slice'](0x0,-0x1):_0x156cad['previousPosition']['path'],_0x14c0fd=_0x488e2b['getNodeByPath'](_0x3368f6);_0x14c0fd['getAttribute'](_0x1e6509)>0x0||_0x14c0fd['_setAttribute'](_0x1e6509,_0x117395[_0x293e22++]);}for(const [_0x22367d,_0x270c02]of _0x2cc620['markers'])_0x22367d['startsWith']('revision:')||this['_markers']['set'](_0x22367d,_0x270c02);}const {roots:_0xd77193}=this['_savedMetaData']['get'](_0x2d1745['fromVersion']),{roots:_0x32de1}=this['_savedMetaData']['get'](_0x2d1745['toVersion']),_0x3fb246=x(_0xd77193['get']('$graveyard'));this['_baseRoots']['set']('$graveyard',_0x3fb246),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x3fb246,Number['NEGATIVE_INFINITY']));const _0x24dc78=x(_0x32de1['get']('$graveyard'));this['_diffRoots']['set']('$graveyard',_0x24dc78),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x24dc78));const _0x49d8d9=Array['from'](this['_diffRoots'])['map'](([_0xa10316,_0x12cb6c])=>[_0xa10316,x(_0x12cb6c)]);this['_saveMetaData'](this['_lastTo'],_0x49d8d9,this['_markers'],_0x19366d);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0x52d892,_0x499a03,_0x4132cb,_0x566062){const _0x2c32c2=new Map(_0x499a03),_0x23107c=new Map(_0xc930c3(_0x566062)),_0x49637d=new Map();for(const [_0x57aab9,_0x20ca1e]of _0x4132cb)_0x49637d['set'](_0x57aab9,{'start':_0x20ca1e['start']['clone'](),'end':_0x20ca1e['end']['clone'](),'rootName':_0x20ca1e['root']['rootName']});this['_savedMetaData']['set'](_0x52d892,{'roots':_0x2c32c2,'markers':_0x49637d,'rootsAttributes':_0x23107c});}['_removeMetaData'](_0x5bcca3){this['_savedMetaData']['delete'](_0x5bcca3);}['_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'](_0x4e3453,_0x27475c=null){let _0x58e25a=null;_0x4e3453['is']('documentFragment')||(_0x58e25a=new _0xe30740(_0x4e3453['name'],{'vid_start':null===_0x27475c?this['_revisionId']++:_0x27475c++}));const _0x227d03=[];for(const _0x446231 of _0x4e3453['getChildren']())if(_0x446231['is']('element')){_0x227d03['push'](this['_makeIdsRoot'](_0x446231,_0x27475c));const _0x2232b0=_0x227d03[_0x227d03['length']-0x1];null!==_0x27475c&&(_0x27475c=_0x2232b0['is']('element','$text')?_0x2232b0['getAttribute']('vid')+0x1:_0x2232b0['getAttribute']('vid_end')+0x1);}else{for(let _0x454519=0x0;_0x454519<_0x446231['offsetSize'];_0x454519++)_0x227d03['push'](new _0xe30740('$text',{'vid':null===_0x27475c?this['_revisionId']++:_0x27475c++}));}if(_0x4e3453['is']('documentFragment')){const _0x3e6693=K(_0x4e3453['rootName']);return _0x3e6693['_insertChild'](0x0,_0x227d03),_0x3e6693;}return _0x58e25a['_setAttribute']('vid_end',null===_0x27475c?this['_revisionId']++:_0x27475c++),_0x58e25a['_insertChild'](0x0,_0x227d03),_0x58e25a;}['_calculateMetaData'](_0x132cae,_0x5a556f,_0x10a594){this['_reset']();const {roots:_0x39077a,markers:_0x134ae2,rootsAttributes:_0x3b9c02}=this['_savedMetaData']['get'](_0x132cae);this['_baseRoots']=new Map(_0x39077a),this['_baseRootsAttributes']=new Map(_0xc930c3(_0x3b9c02));for(const [_0x2f60fa,_0x34b069]of this['_baseRoots'])if('$graveyard'!==_0x2f60fa&&(this['_diffRoots']['set'](_0x2f60fa,x(_0x34b069)),this['_diffRootsAttributes']=new Map(_0xc930c3(_0x3b9c02)),_0x10a594)){const _0x4adf61=this['_revisionId'];this['_idsRoots']['set'](_0x2f60fa,this['_makeIdsRoot'](_0x34b069)),this['_baseIdsRoots']['set'](_0x2f60fa,this['_makeIdsRoot'](_0x34b069,_0x4adf61));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',x(this['_baseRoots']['get']('$graveyard'))),_0x10a594&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x4fcd69,_0x582cbf]of _0x134ae2){const _0x1f0a64=this['_baseRoots']['get'](_0x582cbf['rootName']),_0x2cfa93=this['_diffRoots']['get'](_0x582cbf['rootName']),_0x905684=new _0x4577a5(this['_fixPosition'](_0x582cbf['start'],_0x1f0a64),this['_fixPosition'](_0x582cbf['end'],_0x1f0a64)),_0x262341=this['_fixRange'](_0x905684,_0x2cfa93);_0x1f0a64['markers']['set'](_0x4fcd69,_0x905684),this['_markers']['set'](_0x4fcd69,_0x262341);}this['_applyOperations'](_0x132cae,_0x5a556f,_0x10a594);}['_applyOperations'](_0x207c8c,_0x14eed8,_0x1ea17a){for(const _0x328adc of this['source']['getOperations'](_0x207c8c,_0x14eed8))this['_handleOperation'](_0x328adc,_0x1ea17a);for(const _0x2ee460 of this['_diffRoots']['values']())_0x2ee460['markers']['clear']();for(const [_0x131bbb,_0x536640]of this['_markers']){this['_diffRoots']['get'](_0x536640['root']['rootName'])['markers']['set'](_0x131bbb,_0x536640['clone']());}const _0x5752ba=new Map(),_0x392bbf=new Map();for(const [_0x237e86,_0x1cb41d]of this['_diffRoots'])_0x5752ba['set'](_0x237e86,x(_0x1cb41d)),_0x392bbf['set'](_0x237e86,this['_diffRootsAttributes']['get'](_0x237e86));this['_saveMetaData'](_0x14eed8,_0x5752ba,this['_markers'],_0x392bbf);}['_getPreviousFrom'](_0x45acd0){const _0x4011b9=Array['from'](this['_savedMetaData']['keys']());_0x4011b9['sort']((_0x2961a3,_0x1c04cf)=>_0x2961a3-_0x1c04cf),_0x4011b9['reverse']();for(const _0x12576c of _0x4011b9)if(_0x12576c<_0x45acd0)return _0x12576c;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x37bda9,_0x20ba83){const _0x493246=Array['from'](_0x20ba83['markers'])['map'](([_0x15e221,_0xb9b7b6])=>[_0x15e221,this['_fixRange'](_0xb9b7b6,_0x37bda9)]);_0x37bda9['markers']=new Map(_0x493246);}['_transformMarkers'](_0x2bf28e){for(const _0x509986 of this['_markers']['values']()){const _0x4582d7=_0x509986['getTransformedByOperation'](_0x2bf28e),_0x4a66b1=_0x4577a5['_createFromRanges'](_0x4582d7);_0x509986['start']=_0x4a66b1['start'],_0x509986['end']=_0x4a66b1['end'];}}['_handleOperation'](_0x13ec01,_0x39d500){if('addRoot'!=_0x13ec01['type']&&'detachRoot'!=_0x13ec01['type']){if('insert'==_0x13ec01['type']){const _0x17a7f0=_0x13ec01['position']['root']['rootName'];this['_diffRoots']['has'](_0x17a7f0)||(this['_diffRoots']['set'](_0x17a7f0,K(_0x17a7f0,!0x0)),this['_diffRootsAttributes']['set'](_0x17a7f0,{}),_0x39d500&&this['_idsRoots']['set'](_0x17a7f0,K(_0x17a7f0,!0x0)));}else{if('addRootAttribute'==_0x13ec01['type']||'removeRootAttribute'==_0x13ec01['type']||'changeRootAttribute'==_0x13ec01['type'])return void this['_handleRootAttributeOperation'](_0x13ec01);'marker'==_0x13ec01['type']&&this['_handleMarkerOperation'](_0x13ec01);}if('marker'!==_0x13ec01['type']){const _0x522356=this['_cloneOperation'](_0x13ec01,this['_diffRoots']);_0x522356['_execute'](),this['_transformMarkers'](_0x522356);}if(_0x39d500)switch(_0x13ec01['type']){case'insert':this['_handleInsertOperation'](_0x13ec01);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x13ec01);break;case'merge':this['_handleMergeOperation'](_0x13ec01);break;case'split':this['_handleSplitOperation'](_0x13ec01);}}else this['_handleRootOperation'](_0x13ec01,_0x39d500);}['_cloneOperation'](_0x635c71,_0x39ba5f){const _0x4feb8c=_0x635c71['clone']();return _0x4feb8c['_authorId']=_0x635c71['_authorId'],this['_fixOperation'](_0x4feb8c,_0x39ba5f),_0x4feb8c;}['_getBaseVids'](_0x1c1eb7){return _0x1c1eb7['map'](_0x12075c=>{const _0x3d2bcc=this['_getVidAttributeName'](_0x12075c);return Number(_0x12075c['item']['getAttribute'](_0x3d2bcc));});}['_generateTape'](_0x15ebcb,_0x5403fc){if(_0x15ebcb['is']('element','$text'))_0x5403fc['push']({'item':_0x15ebcb,'type':'text'});else{_0x15ebcb['is']('element')&&_0x5403fc['push']({'item':_0x15ebcb,'type':'elementStart'});for(const _0x54e41b of _0x15ebcb['getChildren']())this['_generateTape'](_0x54e41b,_0x5403fc);_0x15ebcb['is']('element')&&_0x5403fc['push']({'item':_0x15ebcb,'type':'elementEnd'});}return _0x5403fc;}['_getState'](){const _0x2d1a4e=new Map(this['_touched']),_0x182ad5=new Map(_0x2d1a4e),_0x5980dd=new Map(),_0x34edc6={'insertions':{},'deletions':{}},_0x126fdc={'insertions':{},'deletions':{}},_0x5c1395=new Map(),_0x6b46b=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x6b46b['delete']('$graveyard');for(const _0x3b8cac of _0x6b46b){const _0x14ed00=this['_diffRoots']['get'](_0x3b8cac)||K(_0x3b8cac,!0x1),_0x2f19ac=this['_baseRoots']['get'](_0x3b8cac)||K(_0x3b8cac,!0x1);_0x14ed00['isAttached']()||_0x2f19ac['isAttached']()?(_0x34edc6['insertions'][_0x3b8cac]=x(_0x14ed00),_0x34edc6['deletions'][_0x3b8cac]=x(_0x2f19ac),this['_copyMarkers'](_0x34edc6['deletions'][_0x3b8cac],_0x2f19ac),this['_copyMarkers'](_0x34edc6['insertions'][_0x3b8cac],_0x14ed00),_0x126fdc['insertions'][_0x3b8cac]=this['_generateTape'](this['_idsRoots']['get'](_0x3b8cac),[]),_0x126fdc['deletions'][_0x3b8cac]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x3b8cac)||K(_0x3b8cac,!0x1),[])):_0x6b46b['delete'](_0x3b8cac);}for(const _0x35a79d of _0x6b46b){const _0x519ba8=_0x126fdc['insertions'][_0x35a79d];for(const _0x29f0cc of _0x519ba8){const _0x738a90=this['_getVidAttributeName'](_0x29f0cc),_0x370d78=_0x29f0cc['item']['getAttribute'](_0x738a90);_0x182ad5['delete'](_0x370d78),_0x370d78>=this['_startingRevisionId']&&_0x5980dd['set'](_0x370d78,_0x2d1a4e['get'](_0x370d78));}}for(const _0x2e0109 of _0x6b46b){const _0x1d4f8f=_0x126fdc['insertions'][_0x2e0109],_0x2bf76e=this['_getBaseVids'](_0x126fdc['deletions'][_0x2e0109]);let _0x1dcf7e=0x0;for(const _0x429779 of _0x1d4f8f){const _0x26565b=this['_getVidAttributeName'](_0x429779),_0xd7c0b9=_0x429779['item']['getAttribute'](_0x26565b);if(!_0x5980dd['has'](_0xd7c0b9)&&!_0x5c1395['has'](_0xd7c0b9)){if(_0x182ad5['has'](_0xd7c0b9))_0x1dcf7e++;else{if(_0xd7c0b9!=_0x2bf76e[_0x1dcf7e]){const _0x4ec39d=_0x2d1a4e['get'](_0xd7c0b9)||_0x2d1a4e['get'](_0x2bf76e[_0x1dcf7e]);for(;_0xd7c0b9!=_0x2bf76e[_0x1dcf7e];)_0x182ad5['has'](_0x2bf76e[_0x1dcf7e])||(_0x5c1395['set'](_0x2bf76e[_0x1dcf7e],_0x4ec39d),_0x2d1a4e['set'](_0x2bf76e[_0x1dcf7e],_0x4ec39d)),_0x1dcf7e++;}_0x1dcf7e++;}}}}for(const _0x58cb67 of _0x6b46b){const _0x447268=_0x126fdc['insertions'][_0x58cb67];for(const _0x35f2c1 of _0x447268){const _0x25db03=this['_getVidAttributeName'](_0x35f2c1),_0x4c03ee=_0x35f2c1['item']['getAttribute'](_0x25db03);if(_0x5c1395['has'](_0x4c03ee)){const _0x138610=_0x5c1395['get'](_0x4c03ee);_0x182ad5['has'](_0x4c03ee)||_0x182ad5['set'](_0x4c03ee,{..._0x138610}),_0x5980dd['set'](_0x4c03ee,{..._0x138610});}}}for(const _0x276ee5 of _0x182ad5['keys']())_0x276ee5>=this['_startingRevisionId']&&_0x182ad5['delete'](_0x276ee5);const _0x37ac9c=new Map();for(const _0xf0e0dc of _0x6b46b){let _0x430307=_0x126fdc['insertions'][_0xf0e0dc];for(const _0xd10711 of _0x430307)if(_0xd10711['item']['is']('element','tableCell')){const _0x45d52f=this['_getVidAttributeName'](_0xd10711),_0x393fae=_0xd10711['item']['getAttribute'](_0x45d52f);if(_0x5980dd['has'](_0x393fae)){const _0x178ed9=_0xd10711['item']['parent']['parent']['getAttribute']('vid_start'),_0x22079c=_0x37ac9c['get'](_0x178ed9)||new Set();_0x22079c['add'](_0x5980dd['get'](_0x393fae)['userId']),_0x37ac9c['set'](_0x178ed9,_0x22079c);}}_0x430307=_0x126fdc['deletions'][_0xf0e0dc];for(const _0xb733d0 of _0x430307)if(_0xb733d0['item']['is']('element','tableCell')){const _0x3fb61f=this['_getVidAttributeName'](_0xb733d0),_0x54f581=_0xb733d0['item']['getAttribute'](_0x3fb61f);if(_0x182ad5['has'](_0x54f581)){const _0x454db0=_0xb733d0['item']['parent']['parent']['getAttribute']('vid_start'),_0x576c76=_0x37ac9c['get'](_0x454db0)||new Set();_0x576c76['add'](_0x182ad5['get'](_0x54f581)['userId']),_0x37ac9c['set'](_0x454db0,_0x576c76);}}for(const _0x104932 of _0x37ac9c['keys']())(_0x5980dd['has'](_0x104932)||_0x182ad5['has'](_0x104932))&&_0x37ac9c['delete'](_0x104932);}for(const _0x3a8287 of _0x6b46b){const _0x18c8b3=_0x126fdc['insertions'][_0x3a8287];let _0x21d9ea=null,_0x63137e=null;for(const _0x41da9e of _0x18c8b3){const _0x173a6d=this['_getVidAttributeName'](_0x41da9e),_0x231147=_0x41da9e['item']['getAttribute'](_0x173a6d),_0x2941b3=_0x37ac9c['get'](_0x231147);_0x2941b3&&'elementStart'==_0x41da9e['type']&&(_0x21d9ea=Array['from'](_0x2941b3)[0x0],_0x63137e=_0x41da9e['item']['getAttribute']('vid_end')),_0x21d9ea&&(_0x182ad5['set'](_0x231147,{'userId':_0x21d9ea}),_0x5980dd['set'](_0x231147,{'userId':_0x21d9ea})),_0x231147==_0x63137e&&(_0x21d9ea=null,_0x63137e=null);}}const _0x4ddb15={},_0x1df29e=new Set();for(const _0x1308a2 of _0x6b46b){const _0x577525=_0x34edc6['deletions'][_0x1308a2],_0x46a408=_0x34edc6['insertions'][_0x1308a2];for(const {userId:_0x280607}of this['_touchedMarkers']['values']())null!==_0x280607&&_0x1df29e['add'](_0x280607);for(const {userId:_0x23ce63}of this['_touchedRoots']['values']())null!==_0x23ce63&&_0x1df29e['add'](_0x23ce63);this['_markChanges'](_0x46a408,_0x126fdc['insertions'][_0x1308a2],_0x5980dd,'insertion',_0x1df29e),this['_markChanges'](_0x577525,_0x126fdc['deletions'][_0x1308a2],_0x182ad5,'deletion',_0x1df29e),_0x4ddb15[_0x1308a2]={'insertions':this['_prepareViewToSave'](_0x46a408),'deletions':this['_prepareViewToSave'](_0x577525),'attachChange':this['_touchedRoots']['get'](_0x1308a2)||null,'attributesBefore':_0xc930c3(this['_baseRootsAttributes']['get'](_0x1308a2))||{},'attributesAfter':_0xc930c3(this['_diffRootsAttributes']['get'](_0x1308a2))};}return{'diffData':_0x4ddb15,'authorsIds':Array['from'](_0x1df29e)};}['_processRootBeforeSave'](_0x394818){for(const [,_0xb7e67e]of _0x394818['markers']){const _0x49f15d=_0xb7e67e['start']['getAncestors']()['filter'](_0x2cbdfb=>'tableCell'==_0x2cbdfb['name']);for(const _0x58f527 of _0x49f15d)0x1==_0x58f527['childCount']&&_0x58f527['getChild'](0x0)['is']('element','paragraph')&&_0x58f527['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x4b47ae){this['_processRootBeforeSave'](_0x4b47ae);const _0x3fd13b=this['editor']['data']['toView'](_0x4b47ae,{}),_0x868f34=Array['from'](_0x3fd13b['getChildren']())['map'](_0xd71a07=>this['_getViewJson'](_0xd71a07));return JSON['stringify'](_0x868f34);}['_getViewJson'](_0x1425b4){if(_0x1425b4['is']('$text'))return _0x1425b4['data'];{const _0x29aaa8=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0x49c88e=_0x1425b4,_0x9b1597=this['editor']['data']['htmlProcessor']['domConverter'],_0x3610b4={'type':_0x29aaa8['_getTypeCharForViewElement'](_0x49c88e),'name':_0x49c88e['name'],'attributes':Array['from'](_0x49c88e['getAttributes']()),'children':Array['from'](_0x49c88e['getChildren']())['map'](_0x1b44b8=>this['_getViewJson'](_0x1b44b8))};if(_0x1425b4['is']('uiElement')&&'$comment'!=_0x1425b4['name']){const _0x3fcc00=_0x1425b4['render'](_0x9b1597['domDocument'],_0x9b1597);_0x3610b4['children']['push'](_0x3fcc00['outerHTML']);}else{if(_0x1425b4['is']('rawElement')){const _0x138f0b=_0x9b1597['domDocument']['createElement'](_0x49c88e['name']);_0x1425b4['render'](_0x138f0b,_0x9b1597),_0x3610b4['children']['push'](_0x138f0b['innerHTML']);}}const _0x562661=Array['from'](_0x49c88e['getCustomProperties']());_0x562661['length']>0x0&&(_0x3610b4['customProperties']=_0x562661);const _0x27a117=_0x49c88e['getFillerOffset']();return null!==_0x27a117&&(_0x3610b4['fillerOffset']=_0x27a117),_0x3610b4;}}['_markChanges'](_0x3a0138,_0x21410d,_0x433b42,_0x45026a,_0x3c43dc){let _0x257a98=null,_0x3b1c30=null,_0x25f726=0x0;const _0x510df6=this['editor']['model'];for(let _0x1492dc=0x0;_0x1492dc<_0x21410d['length'];_0x1492dc++){const _0x4566ae=this['_getVidAttributeName'](_0x21410d[_0x1492dc]),_0xe3cd47=_0x21410d[_0x1492dc]['item']['getAttribute'](_0x4566ae),_0xfc76ce=_0x433b42['get'](_0xe3cd47),_0x5dc223=_0x1492dc==_0x21410d['length']-0x1;(!_0x257a98&&_0xfc76ce&&(_0x257a98=_0xfc76ce,_0x3b1c30=_0x21410d[_0x1492dc]),_0x257a98&&(!_0xfc76ce||_0xfc76ce['userId']!=_0x257a98['userId']))&&(_0x2016ed(_0xfc76ce,N(_0x3b1c30,_0x3a0138,_0x510df6),N(_0x21410d[_0x1492dc],_0x3a0138,_0x510df6)),_0x257a98=_0xfc76ce||null,_0x3b1c30=_0xfc76ce?_0x21410d[_0x1492dc]:null),_0x257a98&&_0x5dc223&&_0x2016ed(_0xfc76ce,N(_0x3b1c30,_0x3a0138,_0x510df6),P(_0x21410d[_0x1492dc],_0x3a0138,_0x510df6));}function _0x2016ed(_0x512106,_0xdf01b0,_0x393215){const _0x39b1bb=_0x257a98['userId'],_0x12e1ae='revision:'+_0x45026a+':'+_0x39b1bb+':'+_0x25f726++,_0x5afbfe=_0x510df6['createRange'](_0xdf01b0,_0x393215);_0x3a0138['markers']['set'](_0x12e1ae,_0x5afbfe),null!==_0x39b1bb&&_0x3c43dc['add'](_0x39b1bb);}}['_getVidAttributeName'](_0x287608){switch(_0x287608['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x59bce5,_0x40dace){_0x59bce5['baseVersion']=null;for(const _0x202b64 in _0x59bce5){const _0x64683=_0x59bce5[_0x202b64];if(_0x64683 instanceof _0x391495){const _0x2fbe03=_0x40dace['get'](_0x64683['root']['rootName']);_0x59bce5[_0x202b64]=this['_fixPosition'](_0x64683,_0x2fbe03);}if(_0x64683 instanceof _0x4577a5){const _0x3bd29d=_0x40dace['get'](_0x64683['root']['rootName']);_0x59bce5[_0x202b64]=this['_fixRange'](_0x64683,_0x3bd29d);}'root'===_0x202b64&&(_0x59bce5['root']=_0x40dace['get'](_0x59bce5['root']['rootName']));}}['_fixRange'](_0x34f456,_0xf9ef13){return this['editor']['model']['createRange'](this['_fixPosition'](_0x34f456['start'],_0xf9ef13),this['_fixPosition'](_0x34f456['end'],_0xf9ef13));}['_fixPosition'](_0x435f4e,_0x51d091){return this['editor']['model']['createPositionFromPath'](_0x51d091,_0x435f4e['path'],_0x435f4e['stickiness']);}['_handleInsertOperation'](_0x26a1a2){const _0x3664bd=this['_idsRoots']['get'](_0x26a1a2['position']['root']['rootName']),_0x5ca3d8=this['_fixPosition'](_0x26a1a2['position'],_0x3664bd),_0x948513=null===_0x26a1a2['_authorId']?null:_0x26a1a2['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x3cd7b1=_0x5ca3d8['parent'],_0x40f4e3=this['_revisionId'],_0x3959f0=[];for(const _0x500002 of _0x26a1a2['nodes'])if(_0x500002['is']('element'))_0x3959f0['push'](this['_makeIdsRoot'](_0x500002));else{for(let _0x5245ad=0x0;_0x5245ad<_0x500002['offsetSize'];_0x5245ad++)_0x3959f0['push'](new _0xe30740('$text',{'vid':this['_revisionId']++}));}const _0x2474d8=this['_revisionId'];for(let _0xe59467=_0x40f4e3;_0xe59467<_0x2474d8;_0xe59467++)this['_touched']['set'](_0xe59467,{'userId':_0x948513});_0x3cd7b1['_insertChild'](_0x5ca3d8['offset'],_0x3959f0);}['_handleMoveOperation'](_0x2dd276){(_0x2dd276=this['_cloneOperation'](_0x2dd276,this['_idsRoots']))['_execute']();const _0x79851=null===_0x2dd276['_authorId']?null:_0x2dd276['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x5042be=_0x2dd276['getMovedRangeStart'](),_0x5ce462=_0x5042be['parent'],_0x3bdeb3=_0x5042be['offset'];!function _0x273303(_0x5c2419,_0x25c01d,_0x1137e2,_0x3e6c98){for(let _0x30eba6=_0x1137e2;_0x30eba6<_0x3e6c98;_0x30eba6++){const _0x5ba05f=_0x25c01d['getChild'](_0x30eba6);_0x5ba05f['is']('element','$text')?_0x5c2419['set'](_0x5ba05f['getAttribute']('vid'),{'userId':_0x79851}):(_0x5c2419['set'](_0x5ba05f['getAttribute']('vid_start'),{'userId':_0x79851}),_0x273303(_0x5c2419,_0x5ba05f,0x0,_0x5ba05f['childCount']),_0x5c2419['set'](_0x5ba05f['getAttribute']('vid_end'),{'userId':_0x79851}));}}(this['_touched'],_0x5ce462,_0x3bdeb3,_0x3bdeb3+_0x2dd276['howMany']);}['_handleMergeOperation'](_0x4deb15){const _0x3aba63=null===(_0x4deb15=this['_cloneOperation'](_0x4deb15,this['_idsRoots']))['_authorId']?null:_0x4deb15['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x1d1451=_0x4deb15['targetPosition']['parent'],_0x1fbfeb=_0x4deb15['sourcePosition']['parent'],_0x4b7d50=_0x1d1451['getAttribute']('vid_end'),_0x4cd1c0=_0x1fbfeb['getAttribute']('vid_start');_0x1d1451['_setAttribute']('vid_end',_0x1fbfeb['getAttribute']('vid_end')),_0x1fbfeb['_setAttribute']('vid_end',_0x4b7d50),this['_touched']['set'](_0x4cd1c0,{'userId':_0x3aba63}),this['_touched']['set'](_0x4b7d50,{'userId':_0x3aba63}),_0x4deb15['_execute']();}['_handleSplitOperation'](_0x21fdc1){const _0x5b3b7b=null===(_0x21fdc1=this['_cloneOperation'](_0x21fdc1,this['_idsRoots']))['_authorId']?null:_0x21fdc1['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x37f4ba=_0x21fdc1['graveyardPosition'],_0x2d6d11=_0x21fdc1['splitPosition']['parent'];_0x21fdc1['_execute']();const _0x21ea3a=_0x2d6d11['getAttribute']('vid_end'),_0x3caa9b=_0x21fdc1['insertionPosition']['nodeAfter'];if(_0x37f4ba){const _0x400634=_0x3caa9b['getAttribute']('vid_end'),_0x267fbb=_0x2d6d11['getAttribute']('vid_end');_0x2d6d11['_setAttribute']('vid_end',_0x400634),_0x3caa9b['_setAttribute']('vid_end',_0x267fbb),this['_touched']['set'](_0x2d6d11['getAttribute']('vid_end'),{'userId':_0x5b3b7b}),this['_touched']['set'](_0x3caa9b['getAttribute']('vid_start'),{'userId':_0x5b3b7b});}else{const _0xaaafd5=this['_revisionId']++,_0x33cdc0=this['_revisionId']++;_0x2d6d11['_setAttribute']('vid_end',_0xaaafd5),_0x3caa9b['_setAttribute']('vid_start',_0x33cdc0),_0x3caa9b['_setAttribute']('vid_end',_0x21ea3a),this['_touched']['set'](_0xaaafd5,{'userId':_0x5b3b7b}),this['_touched']['set'](_0x33cdc0,{'userId':_0x5b3b7b});}}['_handleMarkerOperation'](_0x59172e){if(!_0x59172e['affectsData'])return;const _0x19c149=(_0x59172e=this['_cloneOperation'](_0x59172e,this['_diffRoots']))['oldRange']?_0x59172e['oldRange']['root']:null,_0xfc6223=_0x59172e['newRange']?_0x59172e['newRange']['root']:null;_0x19c149&&this['_markers']['delete'](_0x59172e['name']),_0xfc6223&&this['_markers']['set'](_0x59172e['name'],_0x59172e['newRange']['clone']());const _0x280396=null===_0x59172e['_authorId']?null:_0x59172e['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x1bed8d=_0x59172e['name'];if(!this['_touchedMarkers']['has'](_0x1bed8d))return void this['_touchedMarkers']['set'](_0x1bed8d,{'range':_0x59172e['oldRange'],'userId':_0x280396});const _0x3b34e5=this['_touchedMarkers']['get'](_0x1bed8d),_0x51dbeb=_0x3b34e5['range'],_0x25aafd=_0x59172e['newRange'];null==_0x51dbeb&&null==_0x25aafd||_0x51dbeb&&_0x25aafd&&_0x51dbeb['isEqual'](_0x25aafd)?this['_touchedMarkers']['delete'](_0x59172e['name']):_0x3b34e5['userId']=_0x280396;}['_handleRootOperation'](_0x5654ee,_0x26ba7c){this['_diffRoots']['has'](_0x5654ee['rootName'])?this['_diffRoots']['get'](_0x5654ee['rootName'])['_isAttached']=_0x5654ee['isAdd']:(this['_diffRoots']['set'](_0x5654ee['rootName'],K(_0x5654ee['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x5654ee['rootName'],{}),_0x26ba7c&&this['_idsRoots']['set'](_0x5654ee['rootName'],K(_0x5654ee['rootName'],!0x0)));const _0x5bd89a=null===_0x5654ee['_authorId']?null:_0x5654ee['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x4d3aac=this['_touchedRoots']['get'](_0x5654ee['rootName']);_0x4d3aac&&_0x4d3aac['userId']===_0x5bd89a?this['_touchedRoots']['delete'](_0x5654ee['rootName']):this['_touchedRoots']['set'](_0x5654ee['rootName'],{'userId':_0x5bd89a,'isAttached':_0x5654ee['isAdd']});}['_handleRootAttributeOperation'](_0x29587d){const _0x45f123=this['_diffRootsAttributes']['get'](_0x29587d['root']['rootName']);null===_0x29587d['newValue']?delete _0x45f123[_0x29587d['key']]:_0x45f123[_0x29587d['key']]=_0x29587d['newValue'];}}function x(_0x49e935){const _0x36f2df=K(_0x49e935['rootName'],_0x49e935['isAttached']());for(const _0x57115a of _0x49e935['getChildren']()){const _0x5f325f=_0x57115a['_clone'](!0x0);_0x36f2df['_appendChild'](_0x5f325f);}return _0x36f2df;}function K(_0x3c6d9a,_0x2a8f3f=!0x0){const _0x21d5df=new _0x308cc0();return _0x21d5df['rootName']=_0x3c6d9a,_0x21d5df['_isAttached']=_0x2a8f3f,_0x21d5df['isAttached']=()=>_0x21d5df['_isAttached'],_0x21d5df;}function N(_0x1e2594,_0x3d4ce5,_0x1da441){const _0x3328b4='elementEnd'==_0x1e2594['type']?_0x1da441['createPositionAt'](_0x1e2594['item'],'end'):_0x1da441['createPositionBefore'](_0x1e2594['item']);return _0x1da441['createPositionFromPath'](_0x3d4ce5,_0x3328b4['path'],_0x3328b4['stickiness']);}function P(_0x931f41,_0x312efd,_0x39c9d4){const _0x18e761='elementStart'==_0x931f41['type']?_0x39c9d4['createPositionAt'](_0x931f41['item'],0x0):_0x39c9d4['createPositionAfter'](_0x931f41['item']);return _0x39c9d4['createPositionFromPath'](_0x312efd,_0x18e761['path'],_0x18e761['stickiness']);}class he extends/* #__PURE__ -- @preserve */
25
+ _0xdbdcec(_0x340389){['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x4256c0,_0x46e2cf){super(_0x4256c0),this['focusTracker']=new _0x5a9408(),this['keystrokes']=new _0x459fc5(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x46e2cf),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'](),_0x27bdd1({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x5ad8b4=_0x41d6c0=>_0x41d6c0['stopPropagation']();this['keystrokes']['set']('arrowright',_0x5ad8b4),this['keystrokes']['set']('arrowleft',_0x5ad8b4),this['keystrokes']['set']('arrowup',_0x5ad8b4),this['keystrokes']['set']('arrowdown',_0x5ad8b4);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x42f535){this['revisionNameInputView']['fieldView']['element']['value']=_0x42f535['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x3c856e){const _0x469075=new et(this['locale'],ti),_0x5c9761=_0x469075['fieldView'];_0x5c9761['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x3fe167=m(this['locale'],'Name\x20of\x20the\x20revision');return!_0x3c856e&&(_0x3fe167+='\x20('+m(this['locale'],'optional')+')'),(_0x469075['label']=_0x3fe167,_0x5c9761['on']('input',()=>{this['revisionNameInputValue']=_0x5c9761['element']['value']['trim']();}),_0x469075);}}class l extends _0x5ac587{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h];}['_saveRevisionFormView'];['init'](){const _0x553dc1=this['editor'],_0x2bbf4a=_0x553dc1['plugins']['get']('RevisionTracker');_0x553dc1['ui']['componentFactory']['add']('revisionHistory',_0x2a12e5=>{const _0x37d255=_0x37cd46(_0x2a12e5),_0x3f63ea=_0x37d255['panelView']['children'],_0x25e376=new _0x143685(_0x2a12e5),_0x3e3bd3=new _0x19cc88(_0x2a12e5),_0x428a37=this['_createSaveRevisionButton'](_0x3d7f7c),_0x2711c7=new _0x19cc88(_0x2a12e5),_0x48d81e=this['_createOpenRevisionButton'](_0x3d7f7c);return _0x37d255['bind']('isEnabled')['to'](_0x2bbf4a,'isReady',_0x2bbf4a,'isEnabled',_0x553dc1,'isReadOnly',(_0x3d382a,_0x4f36dc,_0x449a4b)=>_0x3d382a&&_0x4f36dc&&!_0x449a4b),_0x37d255['buttonView']['set']({'icon':_0x1e1fa6,'label':m(_0x2a12e5,'Revision\x20history'),'tooltip':!0x0}),_0x428a37['set']({'withText':!0x0,'role':'menuitem'}),_0x48d81e['set']({'withText':!0x0,'role':'menuitem'}),this['listenTo'](_0x48d81e,'execute',()=>{_0x37d255['isOpen']=!0x1,_0x553dc1['editing']['view']['focus']();},{'priority':'low'}),_0x3e3bd3['children']['add'](_0x428a37),_0x2711c7['children']['add'](_0x48d81e),_0x25e376['role']='menu',_0x25e376['items']['addMany']([_0x3e3bd3,_0x2711c7]),_0x3f63ea['add'](_0x25e376),_0x37d255;}),_0x553dc1['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x426146=this['editor'],_0x1eb2e2=_0x426146['locale'],_0xe8251c=_0x426146['plugins']['get']('RevisionTracker'),_0x27cf03=new _0x14b3d5(_0x1eb2e2),_0x3b9982=new _0x48c1ad(_0x1eb2e2);_0x27cf03['bind']('isEnabled')['to'](_0xe8251c,'isReady',_0xe8251c,'isEnabled',_0x426146,'isReadOnly',(_0x52c295,_0x214252,_0x1e7b80)=>_0x52c295&&_0x214252&&!_0x1e7b80),_0x27cf03['buttonView']['set']({'icon':_0x1e1fa6,'label':m(_0x1eb2e2,'Revision\x20history')});const _0x1212b7=new _0x3f4a16(_0x1eb2e2,_0x27cf03),_0x473534=this['_createSaveRevisionButton'](_0xa76307);_0x473534['delegate']('execute')['to'](_0x27cf03),_0x1212b7['children']['add'](_0x473534),_0x3b9982['items']['add'](_0x1212b7);const _0x517145=new _0x3f4a16(_0x1eb2e2,_0x27cf03),_0x2adb08=this['_createOpenRevisionButton'](_0xa76307);return _0x2adb08['delegate']('execute')['to'](_0x27cf03),_0x517145['children']['add'](_0x2adb08),_0x3b9982['items']['add'](_0x517145),_0x27cf03['panelView']['children']['add'](_0x3b9982),_0x27cf03;}['_createSaveRevisionButton'](_0x3fba0b){const _0x581367=this['editor'],_0x15ba2a=_0x581367['plugins']['get']('RevisionTracker'),_0x4b93fb=new _0x3fba0b(_0x581367['locale']);return _0x4b93fb['set']({'label':m(_0x581367['locale'],'Save\x20current\x20revision')}),_0x4b93fb['bind']('isEnabled')['to'](_0x15ba2a,'isReady',_0x15ba2a,'isEnabled',_0x581367,'isReadOnly',(_0x26b0ec,_0x42e344,_0x34d539)=>_0x26b0ec&&_0x42e344&&!_0x34d539),this['listenTo'](_0x4b93fb,'execute',()=>{this['_showDialog']();}),_0x4b93fb;}['_createOpenRevisionButton'](_0x5d963b){const _0xcb2b8=this['editor'],_0x3a9dd9=_0xcb2b8['plugins']['get']('RevisionTracker'),_0x21d703=new _0x5d963b(_0xcb2b8['locale']);return _0x21d703['set']({'label':m(_0xcb2b8['locale'],'Open\x20revision\x20history')}),_0x21d703['bind']('isEnabled')['to'](_0x3a9dd9,'isReady',_0xcb2b8,'isReadOnly',(_0x22de5,_0x432d86)=>_0x22de5&&!_0x432d86),this['listenTo'](_0x21d703,'execute',()=>{_0xcb2b8['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x21d703;}['_showDialog'](){const _0x3f7be8=this['editor'],_0x5a6e15=_0x3f7be8['locale'],_0x3847b1=_0x3f7be8['plugins']['get']('Dialog'),_0x3c117f=_0x3f7be8['plugins']['get']('RevisionTracker');function _0x137279(_0x23e74a){_0x3f7be8['config']['get']('revisionHistory.requireRevisionName')&&''===_0x23e74a['revisionName']?_0x23e74a['revisionNameInputView']['errorText']=m(_0x5a6e15,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x3f7be8['plugins']['get'](h)['saveRevision']({'name':_0x23e74a['revisionName']}),_0x3847b1['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x137279(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x3847b1['show']({'id':'revisionSave','title':m(_0x5a6e15,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':m(_0x3f7be8['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x3847b1['hide']()},{'label':m(_0x3f7be8['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x42d08c){_0x42d08c['bind']('isEnabled')['to'](_0x3c117f,'isReady',_0x3c117f,'isEnabled',_0x3f7be8,'isReadOnly',(_0x3f7ee8,_0x4ba52e,_0x3218d8)=>_0x3f7ee8&&_0x4ba52e&&!_0x3218d8);},'onExecute':()=>_0x137279(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x15e46e=this['editor'],_0x6f5efc=_0x15e46e['locale'];this['_saveRevisionFormView']=new he(_0x6f5efc,_0x15e46e['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class q extends _0x340389{['changeId'];['_model'];constructor(_0x381332,_0x1dac45){super(_0x381332),this['_model']=_0x1dac45,this['changeId']=_0x1dac45['id'];const _0xfa76f0=this['bindTemplate'],_0x31bf32=m(_0x381332,_0x1dac45['data']['isSuggestion']?'Suggested\x20by':'add'==_0x1dac45['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x1dac45['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0xfa76f0['to']('type',_0x3aebfc=>'ck-revision-change__'+_0x3aebfc)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x31bf32}]},{'text':'\x20'+_0x1dac45['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class z extends/* #__PURE__ -- @preserve */
26
+ _0x31e13c(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x2692bf){super(),this['id']=_0x2692bf['id']||_0x8d6220(),this['author']=_0x2692bf['author'],this['type']=_0x2692bf['type'],this['data']=_0x2692bf['data']||{},this['rootName']=_0x2692bf['rootName'],this['set']('createdAt',_0x2692bf['createdAt']);}['toJSON'](){return{'id':this['id'],'authorId':this['author']['id'],'type':this['type'],'data':this['data'],'createdAt':this['createdAt']};}}class G{['newRevisionId'];['oldRevisionId'];['changes'];constructor(_0x568a45,_0x5c184c){this['newRevisionId']=_0x568a45,this['oldRevisionId']=_0x5c184c,this['changes']=new _0x4cfa07();}['_setChanges'](_0x42a0ed){for(const _0x5b7119 of _0x42a0ed)this['changes']['add'](_0x5b7119);}}class u extends _0x5ac587{['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[_0x280554,_0xcf2f43,S,$];}constructor(_0x5a6895){super(_0x5a6895),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',(_0x35cbb9,_0x16a8dc,_0x4d38a3)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x2d3b22=>{for(const _0x44edba of this['editor']['editing']['view']['document']['roots'])_0x4d38a3?_0x2d3b22['removeClass']('ck-editor__editable__overlay',_0x44edba):_0x2d3b22['addClass']('ck-editor__editable__overlay',_0x44edba);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x57ea21=>null!==_0x57ea21),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x4a02c7,_0x311c0b,_0x4fa7e9)=>_0x4a02c7&&_0x4fa7e9?_0x311c0b['changes']['getIndex'](_0x4fa7e9):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x1492e7,_0x38a5fe)=>_0x1492e7?_0x38a5fe['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0xcf2f43);}['init'](){const _0x4a612a=this['editor'],_0x4f2adb=new ShowChangeCommand(_0x4a612a,{'direction':'backward'}),_0x50170f=new ShowChangeCommand(_0x4a612a,{'direction':'forward'});(_0x4a612a['commands']['add']('showPreviousChange',_0x4f2adb),_0x4a612a['commands']['add']('showNextChange',_0x50170f),_0x4a612a['commands']['add']('restoreRevision',new RestoreRevisionCommand(_0x4a612a)),this['on']('change:numberOfChanges',()=>{_0x4f2adb['refresh'](),_0x50170f['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x4a612a['enableReadOnlyMode']('revision-viewer'),_0x4a612a['plugins']['has']('WidgetToolbarRepository'))&&_0x4a612a['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x5c6cff){return await this['_utils']['loadRevisionData'](_0x5c6cff,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x5c6cff);}async['getRevisionRootsAttributes'](_0x41b25f){return await this['_utils']['loadRevisionData'](_0x41b25f,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x41b25f);}async['compare'](_0x402764,_0x13d431,_0x353417=!0x1){if(!this['isEnabled'])return;const _0x5cefe3=this['diff'],_0x384fae=this['repository'],_0x2b7b11='string'==typeof _0x402764?_0x384fae['getRevision'](_0x402764):_0x402764,_0x2cc18c='string'==typeof _0x13d431?_0x384fae['getRevision'](_0x13d431):_0x13d431,_0xda7b4=_0x2b7b11['id'],_0x2f403a=_0x2cc18c?_0x2cc18c['id']:null;if(!_0x353417&&this['diff']&&this['diff']['newRevisionId']===_0xda7b4&&this['diff']['oldRevisionId']===_0x2f403a)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new G(_0xda7b4,_0x2f403a);const _0x450cf9=this['_getRevisionsRange'](_0x2b7b11,_0x2cc18c,!0x0)['map'](_0x577f48=>this['_utils']['loadRevisionData'](_0x577f48,this['adapter']));return _0x450cf9['push'](new Promise(_0x29620c=>{setTimeout(_0x29620c,0x14);})),Promise['all'](_0x450cf9)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x4e538e=this['_getDiff'](_0xda7b4,_0x2f403a);for(const _0x2c551d of _0x4e538e['changes'])this['_changeIdToChange']['set'](_0x2c551d['id'],_0x2c551d);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x3309c2=>{for(const _0x5f6dbb of this['editor']['model']['document']['getRootNames']())_0x3309c2['detachRoot'](_0x5f6dbb);for(const _0x30f87b of Object['keys'](_0x4e538e['model'])){const _0x344d22=_0x3309c2['addRoot'](_0x30f87b);for(const _0x72b7dc of Object['keys'](_0x4e538e['attributes'][_0x30f87b]))_0x3309c2['setAttribute'](_0x72b7dc,_0x4e538e['attributes'][_0x30f87b][_0x72b7dc],_0x344d22);_0x3309c2['insert'](_0x4e538e['model'][_0x30f87b],_0x344d22,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x4e538e['changes'])),this['isReady']=!0x0;})['catch'](_0x52a2aa=>{console['error'](_0x52a2aa),this['_cleanUp'](),_0x5cefe3&&(this['diff']=_0x5cefe3),this['isReady']=!0x0;});}['addRevisionData'](_0x2653d5,_0x233b60){const _0x12b90a=this['repository']['createRevision'](_0x2653d5);return _0x12b90a['on']('_update',(_0x1b24e8,_0x271727,_0xd77ba0)=>_0x233b60(_0x271727,_0xd77ba0,_0x12b90a)),this['repository']['addRevision'](_0x12b90a),_0x12b90a;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x22bc7f=>{for(const _0x586869 of this['editor']['model']['document']['getRootNames']())_0x22bc7f['detachRoot'](_0x586869);});}['_sortAndFilterDiffChanges'](_0x3150e6){const _0x1478fa=[],_0x15faf5=new Map();for(const _0x4a9f7f of this['editor']['model']['document']['getRootNames']()){const _0x1ba9b5=this['editor']['editing']['view']['getDomRoot'](_0x4a9f7f);if(!_0x1ba9b5)continue;const _0x4d07a1=_0x1ba9b5['getClientRects']()['item'](0x0);_0x4d07a1&&(_0x1478fa['push'](_0x4a9f7f),_0x15faf5['set'](_0x4a9f7f,_0x4d07a1));}return _0x1478fa['sort']((_0x96296e,_0x259d84)=>{const _0x9ec9e5=_0x15faf5['get'](_0x96296e),_0x488480=_0x15faf5['get'](_0x259d84);return _0x9ec9e5['y']-_0x488480['y']||_0x9ec9e5['x']-_0x488480['x'];}),(_0x3150e6=_0x3150e6['filter'](_0x5b37ca=>_0x1478fa['includes'](_0x5b37ca['rootName'])))['sort']((_0x459249,_0x24f05d)=>_0x1478fa['indexOf'](_0x459249['rootName'])-_0x1478fa['indexOf'](_0x24f05d['rootName'])),_0x3150e6;}['_makeTape'](_0x56f8e2){const _0x532616=Array['from'](_0x56f8e2['markers'])['filter'](([_0x368f71,_0x3ddbe6])=>_0x368f71['startsWith']('revision:')&&!_0x3ddbe6['isCollapsed']),_0x38bab2=Array['from'](this['editor']['model']['createRangeIn'](_0x56f8e2)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x532616['length'])for(const _0x58e8ff of _0x38bab2){const [_0x32a8cb,_0x187fb9]=_0x532616[0x0],[,_0x592f29,_0x3e278f]=_0x32a8cb['split'](':');if(_0x187fb9['end']['isEqual'](_0x58e8ff['nextPosition'])&&_0x532616['shift'](),(_0x58e8ff['previousPosition']['isEqual'](_0x187fb9['start'])||_0x58e8ff['previousPosition']['isAfter'](_0x187fb9['start']))&&('insertion'==_0x592f29?_0x58e8ff['isAdded']={'userId':_0x3e278f}:'deletion'==_0x592f29&&(_0x58e8ff['isRemoved']={'userId':_0x3e278f})),0x0==_0x532616['length'])break;}return _0x38bab2;}['_refreshStartEndIndex'](_0x51b994){const _0x139d74=new Map();for(let _0x1affcb=0x0;_0x1affcb<_0x51b994['length'];_0x1affcb++)'text'===_0x51b994[_0x1affcb]['type']?(_0x51b994[_0x1affcb]['item']['startIndex']=_0x1affcb,_0x51b994[_0x1affcb]['item']['endIndex']=_0x1affcb):('elementStart'===_0x51b994[_0x1affcb]['type']?_0x51b994[_0x1affcb]['item']['startIndex']=_0x1affcb:'elementEnd'===_0x51b994[_0x1affcb]['type']&&(_0x51b994[_0x1affcb]['item']['endIndex']=_0x1affcb),_0x139d74['set'](_0x51b994[_0x1affcb]['id'],_0x1affcb));for(const _0x6692c2 of _0x139d74['values']())'elementStart'===_0x51b994[_0x6692c2]['type']?_0x51b994[_0x6692c2]['item']['endIndex']=_0x139d74['get'](_0x51b994[_0x6692c2]['pairId']):'elementEnd'===_0x51b994[_0x6692c2]['type']&&(_0x51b994[_0x6692c2]['item']['startIndex']=_0x139d74['get'](_0x51b994[_0x6692c2]['pairId']));}['_processTape'](_0x359014){for(let _0x317659=0x0;_0x317659<_0x359014['length'];_0x317659++){if('elementStart'===_0x359014[_0x317659]['type'])_0x359014[_0x317659]['item']['startIndex']=_0x317659;else{if('elementEnd'===_0x359014[_0x317659]['type']){_0x359014[_0x317659]['item']['endIndex']=_0x317659;const _0x1a0ecf=_0x359014[_0x317659]['item']['startIndex'];_0x359014[_0x1a0ecf]['pairId']=_0x359014[_0x317659]['id'],_0x359014[_0x317659]['pairId']=_0x359014[_0x1a0ecf]['id'];}else _0x359014[_0x317659]['item']['startIndex']=_0x317659,_0x359014[_0x317659]['item']['endIndex']=_0x317659,_0x359014[_0x317659]['pairId']=null;}_0x359014[_0x317659]['markersStart']||(_0x359014[_0x317659]['markersStart']=[],_0x359014[_0x317659]['markersEnd']=[]);}}['_markInsertions'](_0x93e60f,_0x2da65c){const _0x14b2ed=_0x93e60f['filter'](_0x259913=>!_0x259913['isAdded']);for(let _0x194768=0x0;_0x194768<_0x2da65c['length'];_0x194768++)_0x2da65c[_0x194768]['isAdded']&&(_0x14b2ed[_0x194768]['isAdded']=_0x2da65c[_0x194768]['isAdded']);}['_getDiff'](_0xeeba9c,_0x96ced1=null){const _0x47aa9f=this['repository']['getRevision'](_0xeeba9c),_0x56c71f=_0x96ced1?this['repository']['getRevision'](_0x96ced1):null,_0x156306=this['_getRevisionsRange'](_0x47aa9f,_0x56c71f),_0x98a9d=_0x156306[_0x156306['length']-0x1],_0x3f3898=new Map(),_0x494c34={'model':{},'attributes':{},'changes':[]},_0x44aa20=new Set(),_0x2d7d79=new Map();for(let _0x4a617a=_0x156306['length']-0x1;_0x4a617a>=0x0;_0x4a617a--){const _0x1aa196=_0x156306[_0x4a617a];for(const _0x1c4211 of Object['keys'](_0x1aa196['diffData']))if(_0x1aa196['diffData'][_0x1c4211]['attachChange']){const _0x150090=_0x1aa196['diffData'][_0x1c4211]['attachChange'];_0x150090['isAttached']?(_0x44aa20['add'](_0x1c4211),_0x2d7d79['has'](_0x1c4211)&&_0x2d7d79['get'](_0x1c4211)['userId']==_0x150090['userId']?_0x2d7d79['delete'](_0x1c4211):_0x2d7d79['set'](_0x1c4211,_0x150090)):_0x2d7d79['has'](_0x1c4211)?(_0x44aa20['delete'](_0x1c4211),_0x2d7d79['delete'](_0x1c4211)):(_0x44aa20['add'](_0x1c4211),_0x2d7d79['set'](_0x1c4211,_0x150090));}else _0x44aa20['add'](_0x1c4211);}for(const _0x3c48d4 of _0x44aa20){const _0x43a9ea=_0x2d7d79['has'](_0x3c48d4)&&!_0x2d7d79['get'](_0x3c48d4)['isAttached'];let _0x433b28=_0x43a9ea?_0x156306['length']-0x1:0x0;const _0x52fae7=_0x43a9ea?-0x1:0x1;for(;_0x156306[_0x433b28];){const _0x1ed291=_0x156306[_0x433b28];if(_0x1ed291['diffData'][_0x3c48d4]){const _0x57c5b4=_0x43a9ea?_0x1ed291['diffData'][_0x3c48d4]['attributesBefore']:_0x1ed291['diffData'][_0x3c48d4]['attributesAfter'];_0x494c34['attributes'][_0x3c48d4]=_0x57c5b4?_0xc930c3(_0x57c5b4):{};break;}_0x433b28+=_0x52fae7;}}for(const _0x529608 of _0x156306){_0x529608['model']={};for(const _0x45ad49 of _0x529608['authors'])_0x3f3898['set'](_0x45ad49['id'],_0x45ad49);for(const _0x484859 of _0x44aa20){const _0x39f6b9=_0x529608['diffData'][_0x484859]?_0x529608['diffData'][_0x484859]['insertions']:'[]',_0x209faa=_0x529608['diffData'][_0x484859]?_0x529608['diffData'][_0x484859]['deletions']:'[]';_0x529608['model'][_0x484859]={'insertions':this['_utils']['_makeModelFromViewString'](_0x39f6b9),'deletions':this['_utils']['_makeModelFromViewString'](_0x209faa)};}}for(const _0x30c186 of _0x44aa20){let _0x27cdc4=null,_0x2bf3e6=0x0;const _0x2049ad=new Map(Array['from'](_0x47aa9f['model'][_0x30c186]['insertions']['markers'])['filter'](([_0x25232a])=>!_0x25232a['startsWith']('revision:')));let _0x5c14c5=0x0;for(const _0x4f83df of _0x156306){const _0x65aabd=this['_makeTape'](_0x4f83df['model'][_0x30c186]['insertions']);_0x4f83df==_0x47aa9f?(_0x27cdc4=_0x65aabd,_0x2bf3e6=_0x27cdc4['length'],_0x27cdc4['forEach'](_0x38385d=>{_0x38385d['id']=_0x5c14c5++;}),this['_processTape'](_0x27cdc4)):this['_markInsertions'](_0x27cdc4,_0x65aabd);const _0xa78864=_0x27cdc4['filter'](_0x1ed5e1=>!_0x1ed5e1['isAdded'])['map'](_0x514c05=>_0x514c05['id']);let _0x2baace=0x0;const _0x35bc96=this['_makeTape'](_0x4f83df['model'][_0x30c186]['deletions']);_0x35bc96['forEach'](_0x333d67=>{_0x333d67['isRemoved']?_0x333d67['id']=_0x2bf3e6++:_0x333d67['id']=_0xa78864[_0x2baace++];}),this['_processTape'](_0x35bc96),this['_setDistance'](_0x27cdc4,'isAdded'),this['_setDistance'](_0x35bc96,'isRemoved'),_0x4f83df==_0x47aa9f&&this['_markMarkers'](_0x27cdc4,_0x2049ad),_0x27cdc4=this['_joinTapes'](_0x27cdc4,_0x35bc96),this['_refreshStartEndIndex'](_0x27cdc4),this['_setDistance'](_0x27cdc4,'isRemoved');}_0x27cdc4=_0x27cdc4['filter'](_0x153bb2=>!(_0x153bb2['isAdded']&&_0x153bb2['isRemoved']));const _0x3f719a=new Map(_0x98a9d['model'][_0x30c186]['deletions']['markers']),_0x6eef8e=new Set(_0x2049ad['keys']());for(const _0x19c94d of _0x3f719a['keys']())_0x6eef8e['delete'](_0x19c94d);this['_markSuggestions'](_0x27cdc4,_0x6eef8e),this['_fixObsoleteTags'](_0x27cdc4),_0x27cdc4=this['_removeMissingPairs'](_0x27cdc4),_0x27cdc4=this['_markMismatchedRemovedTags'](_0x27cdc4),_0x27cdc4=this['_removeUnsupportedChanges'](_0x27cdc4);const {root:_0x3290f8,changes:_0x29384a}=this['_makeModelFromTape'](_0x27cdc4,_0x3f3898,_0x30c186);_0x494c34['model'][_0x30c186]=_0x3290f8;const _0x22d3df=_0x2d7d79['get'](_0x30c186);if(_0x22d3df){const _0x37ab62=_0x3f3898['get'](_0x22d3df['userId']),_0x55a88f=new z({'author':_0x37ab62,'type':_0x22d3df['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x30c186});_0x29384a['unshift'](_0x55a88f),_0x494c34['attributes'][_0x30c186]['revisionHistoryAttachChange']=_0x55a88f['id'];}_0x494c34['changes']=_0x494c34['changes']['concat'](_0x29384a);}return _0x494c34;}['_markMarkers'](_0x51e0e8,_0x22f93){for(let _0x41ecbc=0x0;_0x41ecbc<_0x51e0e8['length'];_0x41ecbc++)for(const [_0x48a41f,_0x323c8e]of _0x22f93)!_0x323c8e['isCollapsed']&&_0x323c8e['start']['isEqual'](_0x51e0e8[_0x41ecbc]['previousPosition'])&&_0x51e0e8[_0x41ecbc]['markersStart']['push'](_0x48a41f),_0x323c8e['end']['isEqual'](_0x51e0e8[_0x41ecbc]['nextPosition'])&&_0x51e0e8[_0x41ecbc]['markersEnd']['push'](_0x48a41f);}['_joinTapes'](_0x1ab2ef,_0x1c5ec5){let _0x19528e=[],_0x4bd71b=0x0,_0x45ffef=0x0;for(;_0x4bd71b<_0x1ab2ef['length']||_0x45ffef<_0x1c5ec5['length'];){const _0x569347=_0x1ab2ef[_0x4bd71b]||{},_0x4d13a1=_0x1c5ec5[_0x45ffef]||{};if(_0x569347['id']==_0x4d13a1['id'])_0x4bd71b++,_0x45ffef++,_0x19528e['push'](_0x569347);else{if(_0x4d13a1['isRemoved']&&_0x569347['isAdded']){const {commonTape:_0x59f8a8,iEnd:_0x1bd148,jEnd:_0x47278f}=this['_threeWayMerge'](_0x1ab2ef,_0x4bd71b,_0x1c5ec5,_0x45ffef);_0x19528e=_0x19528e['concat'](_0x59f8a8),_0x4bd71b=_0x1bd148,_0x45ffef=_0x47278f;}else _0x4d13a1['isRemoved']?(_0x45ffef++,_0x19528e['push'](_0x4d13a1)):(_0x4bd71b++,_0x19528e['push'](_0x569347));}}return _0x19528e;}['_markSuggestions'](_0x146e97,_0x29e521){const _0x6ffdb1=[];for(let _0x48146b=0x0;_0x48146b<_0x146e97['length'];_0x48146b++){for(let _0x456d27=0x0;_0x456d27<_0x146e97[_0x48146b]['markersStart']['length'];_0x456d27++){const _0x2a47c5=_0x146e97[_0x48146b]['markersStart'][_0x456d27];if(!_0x29e521['has'](_0x2a47c5))continue;const {group:_0x1a220d,type:_0x503a15,authorId:_0x425f49}=_0x1938f1(_0x2a47c5);'revision-suggestion'!=_0x1a220d||'insertion'!=_0x503a15&&'deletion'!=_0x503a15||(_0x6ffdb1['unshift']({'type':_0x503a15,'name':_0x2a47c5,'userId':_0x425f49}),_0x146e97[_0x48146b]['markersStart']['splice'](_0x456d27,0x1),_0x456d27--);}_0x115afc(_0x146e97[_0x48146b]);for(let _0xc3acd5=0x0;_0xc3acd5<_0x146e97[_0x48146b]['markersEnd']['length'];_0xc3acd5++){const _0x5b3d30=_0x146e97[_0x48146b]['markersEnd'][_0xc3acd5];if(!_0x29e521['has'](_0x5b3d30))continue;const {group:_0x2d71f0,type:_0x73f5f2}=_0x1938f1(_0x5b3d30);if('revision-suggestion'!=_0x2d71f0||'insertion'!=_0x73f5f2&&'deletion'!=_0x73f5f2)continue;_0x146e97[_0x48146b]['markersEnd']['splice'](_0xc3acd5,0x1),_0xc3acd5--;const _0x74f3b6=_0x6ffdb1['findIndex'](_0x364db8=>_0x364db8['name']==_0x5b3d30);_0x74f3b6>-0x1&&_0x6ffdb1['splice'](_0x74f3b6,0x1);}}function _0x1938f1(_0x1d043d){const _0x34b094=_0x1d043d['split'](':');return{'group':_0x34b094[0x0],'type':_0x34b094[0x1],'subType':_0x34b094['length']>=0x5?_0x34b094[0x2]:null,'id':_0x34b094['length']<0x5?_0x34b094[0x2]:_0x34b094[0x3],'authorId':_0x34b094['length']<0x5?_0x34b094[0x3]:_0x34b094[0x4],'markerCount':0x6==_0x34b094['length']?_0x34b094[0x5]:null};}function _0x115afc(_0x319e99){for(let _0x31461d=0x0;_0x31461d<_0x6ffdb1['length'];_0x31461d++){if(_0x319e99['isAdded']&&'insertion'==_0x6ffdb1[_0x31461d]['type']&&_0x319e99['isAdded']['userId']==_0x6ffdb1[_0x31461d]['userId'])return _0x319e99['isAddSuggestion']=_0x6ffdb1[_0x31461d],void delete _0x319e99['isAdded'];if(!_0x319e99['isAdded']&&!_0x319e99['isRemoved']&&'deletion'==_0x6ffdb1[_0x31461d]['type'])return void(_0x319e99['isRemoveSuggestion']=_0x6ffdb1[_0x31461d]);}}}['_setDistance'](_0xad9f25,_0x45c70d){let _0x51fd1d=0x0,_0x254379=!0x1;const _0x10dc5e=new Map();for(const _0x24e36e of _0xad9f25)_0x24e36e[_0x45c70d]?_0x254379&&(_0x51fd1d++,_0x254379=!0x1):(_0x51fd1d++,_0x254379=!0x0),_0x10dc5e['set'](_0x24e36e['id'],_0x51fd1d);for(let _0x4d8559=0x0;_0x4d8559<_0xad9f25['length'];_0x4d8559++){if('isRemoved'==_0x45c70d&&_0xad9f25[_0x4d8559]['isAdded']||'isAdded'==_0x45c70d&&_0xad9f25[_0x4d8559]['isRemoved'])continue;if('text'==_0xad9f25[_0x4d8559]['type']){_0xad9f25[_0x4d8559]['distance']=0x0;continue;}const _0x750231=_0x10dc5e['get'](_0xad9f25[_0x4d8559]['pairId']),_0xe74e03=_0x10dc5e['get'](_0xad9f25[_0x4d8559]['id']);_0xad9f25[_0x4d8559]['distance']=_0x750231-_0xe74e03;}}['_getRevisionsRange'](_0x191b1e,_0x49f487,_0xf6d9d1=!0x1){const _0x2228df=[];let _0x309274=this['repository']['getIndex'](_0x191b1e),_0x3b9428=this['repository']['getIndex'](_0x49f487);for(-0x1==_0x3b9428&&(_0x3b9428=this['repository']['_revisions']['length'],_0xf6d9d1=!0x1);_0x309274<_0x3b9428;)_0x2228df['push'](this['repository']['getRevision'](_0x309274)),_0x309274++;return _0xf6d9d1&&_0x2228df['push'](this['repository']['getRevision'](_0x309274)),_0x2228df;}['_threeWayMerge'](_0x4b4ac5,_0x3f1dea,_0x54be32,_0x56e981){const _0x3ef521=this['editor']['model']['schema'];let _0x4b8fd0=_0x3f1dea;for(;_0x4b4ac5[_0x4b8fd0]&&_0x4b4ac5[_0x4b8fd0]['isAdded'];)_0x4b8fd0++;let _0x2e116b=_0x56e981;for(;_0x54be32[_0x2e116b]&&_0x54be32[_0x2e116b]['isRemoved'];)_0x2e116b++;_0x143331(_0x4b4ac5,_0x3f1dea,_0x4b8fd0),_0x143331(_0x54be32,_0x56e981,_0x2e116b);const _0x391a64=_0x54be32['slice'](_0x56e981,_0x2e116b)['concat'](_0x4b4ac5['slice'](_0x3f1dea,_0x4b8fd0));return _0x391a64['sort']((_0x4b6bfd,_0x128253)=>_0x4b6bfd['side']!=_0x128253['side']?_0x4b6bfd['side']-_0x128253['side']:_0x4b6bfd['level']!=_0x128253['level']?_0x4b6bfd['level']-_0x128253['level']:_0x4b6bfd['distance']!=_0x128253['distance']?_0x128253['distance']-_0x4b6bfd['distance']:!!_0x4b6bfd['isAdded']!=!!_0x128253['isAdded']?-0x1==_0x4b6bfd['side']||0x0==_0x4b6bfd['side']?_0x4b6bfd['isAdded']?-0x1:0x1:_0x4b6bfd['isAdded']?0x1:-0x1:_0x4b6bfd['index']-_0x128253['index']),{'commonTape':_0x391a64,'iEnd':_0x4b8fd0,'jEnd':_0x2e116b};function _0x143331(_0x57bf2f,_0x45de6b,_0x151204){let _0x94137e=-0x1,_0x42e239=Number['POSITIVE_INFINITY'],_0x34da8a=!0x0;for(let _0x3e1481=_0x45de6b;_0x3e1481<_0x151204;_0x3e1481++)if(_0x3ef521['isInline'](_0x57bf2f[_0x3e1481]['item'])||(_0x34da8a=!0x1),_0x57bf2f[_0x3e1481]['item']['startIndex']<_0x45de6b&&(_0x94137e=_0x3e1481),_0x57bf2f[_0x3e1481]['item']['endIndex']>=_0x151204){_0x42e239=_0x3e1481;break;}_0x34da8a&&(_0x94137e=_0x151204-0x1);for(let _0x233de0=_0x45de6b;_0x233de0<_0x151204;_0x233de0++)_0x57bf2f[_0x233de0]['side']=_0x233de0<=_0x94137e?-0x1:_0x233de0<_0x42e239?0x0:0x1,_0x57bf2f[_0x233de0]['index']=_0x233de0;let _0x4fc3d6=0x0;for(let _0x3cebe6=_0x45de6b;_0x3cebe6<=_0x94137e;_0x3cebe6++)0x0==_0x57bf2f[_0x3cebe6]['distance']?_0x57bf2f[_0x3cebe6]['level']=_0x4fc3d6:(_0x4fc3d6++,_0x57bf2f[_0x3cebe6]['level']=_0x4fc3d6,_0x4fc3d6++);for(let _0x2c2e58=_0x45de6b;_0x2c2e58<_0x151204;_0x2c2e58++)0x0==_0x57bf2f[_0x2c2e58]['side']&&(_0x57bf2f[_0x2c2e58]['level']=_0x4fc3d6);_0x4fc3d6=0x0;for(let _0x996405=_0x151204-0x1;_0x996405>=_0x42e239;_0x996405--)0x0==_0x57bf2f[_0x996405]['distance']?_0x57bf2f[_0x996405]['level']=_0x4fc3d6:(_0x4fc3d6--,_0x57bf2f[_0x996405]['level']=_0x4fc3d6,_0x4fc3d6--);}}['_fixObsoleteTags'](_0x8b739d){const _0x526a85=new Map(),_0x23101c=this['editor']['model']['schema'];for(let _0x1b5222=0x1;_0x1b5222<_0x8b739d['length'];_0x1b5222++){let _0x344cda,_0x28f625,_0x3d4b8b;const _0x43dde6=_0x8b739d[_0x1b5222],_0x1f46a7=_0x8b739d[_0x1b5222-0x1];if('text'==_0x43dde6['type'])continue;if(_0x43dde6['type']!=_0x1f46a7['type'])continue;if(!_0x23101c['isBlock'](_0x1f46a7['item'])||_0x23101c['isLimit'](_0x1f46a7['item']))continue;if(!_0x23101c['isBlock'](_0x43dde6['item'])||_0x23101c['isLimit'](_0x43dde6['item']))continue;if((_0x8b739d[_0x1b5222]['isAdded']||_0x8b739d[_0x1b5222]['isAddSuggestion'])&&_0x8b739d[_0x1b5222-0x1]['isRemoved'])_0x344cda=_0x8b739d[_0x1b5222],_0x28f625=_0x8b739d[_0x1b5222-0x1],_0x3d4b8b=_0x1b5222-0x1;else{if(!_0x8b739d[_0x1b5222]['isRemoved']||!_0x8b739d[_0x1b5222-0x1]['isAdded']&&!_0x8b739d[_0x1b5222-0x1]['isAddSuggestion'])continue;_0x344cda=_0x8b739d[_0x1b5222-0x1],_0x28f625=_0x8b739d[_0x1b5222],_0x3d4b8b=_0x1b5222;}const _0x50a2c9=_0x344cda['level']==_0x28f625['level'],_0x521c7e=Math['abs'](_0x344cda['level'])<Math['abs'](_0x28f625['level'])&&0x0==_0x28f625['distance'];(_0x50a2c9||_0x521c7e)&&(_0x526a85['set'](_0x28f625['id'],_0x344cda['id']),_0x8b739d['splice'](_0x3d4b8b,0x1),_0x1b5222--,_0x344cda['isAdded']=!0x1);}for(let _0x3ad0b9=0x0;_0x3ad0b9<_0x8b739d['length'];_0x3ad0b9++)_0x526a85['has'](_0x8b739d[_0x3ad0b9]['pairId'])&&(_0x8b739d[_0x3ad0b9]['pairId']=_0x526a85['get'](_0x8b739d[_0x3ad0b9]['pairId']));}['_removeMissingPairs'](_0x1f1706){const _0x2577e9=new Set(_0x1f1706['map'](_0x379a72=>_0x379a72['id']));for(let _0x470237=0x0;_0x470237<_0x1f1706['length'];_0x470237++)_0x2577e9['has'](_0x1f1706[_0x470237]['pairId'])||0x0==_0x1f1706[_0x470237]['distance']||(_0x1f1706[_0x470237]['isIncorrect']=!0x0);return _0x1f1706['filter'](_0x33ce4e=>!_0x33ce4e['isIncorrect']);}['_markMismatchedRemovedTags'](_0x45d10a){const _0x675b4b=new Set();for(let _0x5d7245=0x0;_0x5d7245<_0x45d10a['length'];_0x5d7245++){if(_0x675b4b['has'](_0x45d10a[_0x5d7245]['id'])&&_0x45d10a[_0x5d7245]['isRemoved']&&(_0x45d10a[_0x5d7245]['isIncorrect']=!0x0),_0x45d10a[_0x5d7245]['isIncorrect'])continue;if(0x0==_0x45d10a[_0x5d7245]['distance'])continue;if('elementStart'!=_0x45d10a[_0x5d7245]['type'])continue;if(null==_0x45d10a[_0x5d7245]['pairId'])continue;let _0x1a2371=_0x5d7245+0x1,_0x5cf0c7=0x0;for(;_0x45d10a[_0x1a2371]['id']!=_0x45d10a[_0x5d7245]['pairId'];)'elementStart'==_0x45d10a[_0x1a2371]['type']?_0x5cf0c7++:'elementEnd'==_0x45d10a[_0x1a2371]['type']&&_0x5cf0c7--,_0x1a2371++;if(0x0!=_0x5cf0c7){if(_0x45d10a[_0x5d7245]['isRemoved'])_0x45d10a[_0x5d7245]['isIncorrect']=!0x0;else{for(;_0x1a2371!=_0x5d7245;)_0x45d10a[_0x1a2371]['isRemoved']&&0x0!=_0x45d10a[_0x1a2371]['distance']&&(_0x45d10a[_0x1a2371]['isIncorrect']=!0x0,_0x675b4b['add'](_0x45d10a[_0x1a2371]['pairId'])),_0x1a2371--;}}}return _0x45d10a['filter'](_0x1ecb3a=>!_0x1ecb3a['isIncorrect']);}['_removeUnsupportedChanges'](_0x24bddd){const _0x5263b8=this['editor']['model']['schema'];for(let _0x9b510e=0x0;_0x9b510e<_0x24bddd['length'];_0x9b510e++){if(!(_0x24bddd[_0x9b510e]['isAdded']||_0x24bddd[_0x9b510e]['isAddSuggestion']||_0x24bddd[_0x9b510e]['isRemoved']||_0x24bddd[_0x9b510e]['isRemoveSuggestion']))continue;if(0x0==_0x24bddd[_0x9b510e]['distance'])continue;const _0x10f768=_0x24bddd[_0x9b510e]['item'];_0x5263b8['isBlock'](_0x10f768)||_0x5263b8['isLimit'](_0x10f768)||(_0x24bddd[_0x9b510e]['isAdded']&&delete _0x24bddd[_0x9b510e]['isAdded'],_0x24bddd[_0x9b510e]['isAddSuggestion']&&delete _0x24bddd[_0x9b510e]['isAddSuggestion'],_0x24bddd[_0x9b510e]['isRemoveSuggestion']&&delete _0x24bddd[_0x9b510e]['isRemoveSuggestion'],_0x24bddd[_0x9b510e]['isRemoved']&&(_0x24bddd[_0x9b510e]['isIncorrect']=!0x0));}return _0x24bddd['filter'](_0x4f7483=>!_0x4f7483['isIncorrect']);}['_makeModelFromTape'](_0x11af2c,_0x5161a8,_0x2d409f){const _0x311135=new _0x308cc0(),_0x29bf90=[],_0x3844bc=new Map(),_0xe377cc=this['editor']['model'],_0x212a05=_0xe377cc['schema'],_0xff6901=[_0x311135],_0x451dde={},_0x1cbdcd={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x49ce9d=null;const _0x1e4884=[0x0];for(let _0x840db2=0x0;_0x840db2<_0x11af2c['length'];_0x840db2++)if('elementStart'===_0x11af2c[_0x840db2]['type']){_0x11af2c[_0x840db2]['previousPosition']=_0xe377cc['createPositionFromPath'](_0x311135,_0x1e4884);const _0x5853ef=new _0xe30740(_0x11af2c[_0x840db2]['item']['name'],_0x11af2c[_0x840db2]['item']['getAttributes']());_0xff6901[0x0]['_appendChild'](_0x5853ef),_0x1e4884['push'](0x0),_0xff6901['unshift'](_0x5853ef),_0x11af2c[_0x840db2]['nextPosition']=_0xe377cc['createPositionFromPath'](_0x311135,_0x1e4884);}else'elementEnd'===_0x11af2c[_0x840db2]['type']?(_0xff6901['shift'](),_0x11af2c[_0x840db2]['previousPosition']=_0xe377cc['createPositionFromPath'](_0x311135,_0x1e4884),_0x1e4884['pop'](),_0x1e4884[_0x1e4884['length']-0x1]++,_0x11af2c[_0x840db2]['nextPosition']=_0xe377cc['createPositionFromPath'](_0x311135,_0x1e4884)):(_0x11af2c[_0x840db2]['previousPosition']=_0xe377cc['createPositionFromPath'](_0x311135,_0x1e4884),_0x49ce9d?_0x49ce9d['_data']+=_0x11af2c[_0x840db2]['item']['data']:_0x49ce9d=new _0xf9337(_0x11af2c[_0x840db2]['item']['data'],_0x11af2c[_0x840db2]['item']['getAttributes']()),_0x11af2c[_0x840db2+0x1]&&'text'===_0x11af2c[_0x840db2+0x1]['type']&&_0x2b39f8(_0x49ce9d,_0x11af2c[_0x840db2+0x1]['item'])||(_0xff6901[0x0]['_appendChild'](_0x49ce9d),_0x49ce9d=null),_0x1e4884[_0x1e4884['length']-0x1]+=_0x11af2c[_0x840db2]['item']['offsetSize'],_0x11af2c[_0x840db2]['nextPosition']=_0xe377cc['createPositionFromPath'](_0x311135,_0x1e4884));for(let _0x54506f=0x0;_0x54506f<_0x11af2c['length'];_0x54506f++){const _0x4584f8=_0x11af2c[_0x54506f]['previousPosition'],_0x2c052e=_0x11af2c[_0x54506f]['nextPosition'];for(const _0x34508b of _0x11af2c[_0x54506f]['markersStart'])_0x3844bc['set'](_0x34508b,{'start':_0x4584f8,'end':null});_0x6835d0('isRemoveSuggestion',_0x54506f,_0x4584f8,_0x2c052e),_0x6835d0('isAddSuggestion',_0x54506f,_0x4584f8,_0x2c052e),_0x6835d0('isRemoved',_0x54506f,_0x4584f8,_0x2c052e),_0x6835d0('isAdded',_0x54506f,_0x4584f8,_0x2c052e);for(const _0x13619a of _0x11af2c[_0x54506f]['markersEnd']){const _0x177ffa=_0x3844bc['get'](_0x13619a);_0x177ffa?_0x177ffa['end']=_0x2c052e:_0x3844bc['set'](_0x13619a,{'start':_0x2c052e,'end':_0x2c052e});}}for(const [_0x18d7eb,_0xd41bd6]of _0x3844bc){const _0x67c7d=this['editor']['model']['createRange'](_0xd41bd6['start'],_0xd41bd6['end']);_0x311135['markers']['set'](_0x18d7eb,_0x67c7d);}return _0x29bf90['sort']((_0x8bbd0f,_0x359155)=>{const _0x73bc7e=_0x311135['markers']['get']('revision:'+_0x8bbd0f['id']),_0x4d8c96=_0x311135['markers']['get']('revision:'+_0x359155['id']);return _0x73bc7e['start']['isBefore'](_0x4d8c96['start'])?-0x1:_0x73bc7e['start']['isAfter'](_0x4d8c96['start'])?0x1:_0x73bc7e['end']['isBefore'](_0x4d8c96['end'])?-0x1:_0x73bc7e['end']['isAfter'](_0x4d8c96['end'])?0x1:'add'===_0x8bbd0f['type']?-0x1:0x1;}),{'root':_0x311135,'changes':_0x29bf90};function _0x6835d0(_0xbe730b,_0x1c33b0,_0x5aa241,_0x4d0ec2){const _0x508168=!!_0x11af2c[_0x1c33b0][_0xbe730b],_0x5c773a=_0x508168?_0x11af2c[_0x1c33b0][_0xbe730b]['userId']:null,_0x72aa63=_0x1c33b0===_0x11af2c['length']-0x1,_0x3c0870=_0x1cbdcd[_0xbe730b][0x0],_0x164b92=_0x212a05['isObject'](_0x11af2c[_0x1c33b0]['item']);!_0x451dde[_0xbe730b]&&_0x508168?_0x451dde[_0xbe730b]={'start':_0x5aa241,'tapeItem':_0x11af2c[_0x1c33b0],'userId':_0x5c773a,'type':_0xbe730b}:_0x451dde[_0xbe730b]&&!_0x508168?(_0x451dde[_0xbe730b]['end']=_0x5aa241,_0x49ecb1(_0x451dde[_0xbe730b]),_0x451dde[_0xbe730b]=null):_0x451dde[_0xbe730b]&&_0x508168&&_0x451dde[_0xbe730b]['userId']!==_0x5c773a&&(_0x451dde[_0xbe730b]['end']=_0x5aa241,_0x3c0870&&_0x3c0870['userId']===_0x451dde[_0xbe730b]['userId']||_0x49ecb1(_0x451dde[_0xbe730b]),_0x451dde[_0xbe730b]={'start':_0x5aa241,'tapeItem':_0x11af2c[_0x1c33b0],'userId':_0x5c773a,'type':_0xbe730b}),_0x451dde[_0xbe730b]&&_0x164b92&&('elementStart'!==_0x11af2c[_0x1c33b0]['type']||_0x3c0870&&_0x3c0870['userId']===_0x5c773a||_0x1cbdcd[_0xbe730b]['unshift']({'userId':_0x5c773a,'object':_0x11af2c[_0x1c33b0]['item'],'change':_0x451dde[_0xbe730b]}),'elementEnd'===_0x11af2c[_0x1c33b0]['type']&&_0x3c0870&&_0x3c0870['object']===_0x11af2c[_0x1c33b0]['item']&&(_0x1cbdcd[_0xbe730b]['shift'](),_0x451dde[_0xbe730b]=_0x3c0870['change'])),_0x451dde[_0xbe730b]&&_0x72aa63&&(_0x451dde[_0xbe730b]['end']=_0x4d0ec2,_0x49ecb1(_0x451dde[_0xbe730b]),_0x451dde[_0xbe730b]=null);}function _0x49ecb1({start:_0x13a7ed,end:_0x328781,tapeItem:_0x351102,userId:_0xb24ff6,type:_0x4efb8c}){const _0x33058b=_0x351102['item'],_0x57c69a=_0xe377cc['schema']['isBlock'](_0x33058b)&&!_0xe377cc['schema']['isLimit'](_0x33058b),_0x128a3d=_0x13a7ed['nodeAfter']==_0x328781['parent']&&_0x328781['isAtStart'];if(_0x57c69a&&_0x128a3d)return;const _0x285e7e=_0xe377cc['createRange'](_0x13a7ed,_0x328781),_0x37b786=_0x5161a8['get'](_0xb24ff6),_0x5beaca=new z({'author':_0x37b786,'type':'isAdded'==_0x4efb8c||'isAddSuggestion'==_0x4efb8c?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x4efb8c||'isRemoveSuggestion'==_0x4efb8c},'createdAt':new Date(),'rootName':_0x2d409f});_0x29bf90['push'](_0x5beaca),_0x311135['markers']['set']('revision:'+_0x5beaca['id'],_0x285e7e);}function _0x2b39f8(_0x179e65,_0x17a2ec){const _0x1bc4ec=_0x179e65['getAttributes'](),_0x229965=_0x17a2ec['getAttributes']();for(const _0x5dd648 of _0x1bc4ec){if(_0x5dd648[0x1]!==_0x17a2ec['getAttribute'](_0x5dd648[0x0]))return!0x1;_0x229965['next']();}return _0x229965['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x5246e1=>{const _0x55c0e3=_0x5246e1['markerName']['split'](':')[0x1],_0x7bb92d=this['_getChangeFromId'](_0x55c0e3);if(!_0x7bb92d)return null;const _0xc8e2d5='add'==_0x7bb92d['type']?'insertion':'deletion',_0x51b74f=['ck-suggestion-marker','ck-suggestion-marker-'+_0xc8e2d5];return _0x7bb92d['data']['isSuggestion']&&_0x51b74f['push']('ck-suggestion-marker-'+_0xc8e2d5+'-new'),this['activeChange']==_0x7bb92d&&_0x51b74f['push']('ck-suggestion-marker--active'),{'classes':_0x51b74f,'attributes':{'data-change-id':_0x55c0e3}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x2a3ef9=>{_0x2a3ef9['on']('element:pre',(_0x30aeb6,_0x28baee,_0x1c1e39)=>{const _0x2be7cd=_0x28baee['viewItem']['getChild'](0x0);if(!_0x2be7cd||!_0x2be7cd['is']('element','code'))return;if(!_0x1c1e39['consumable']['consume'](_0x2be7cd,{'attributes':['vid_start','vid_end']}))return;const _0x170e95=_0x28baee['modelRange']['start']['nodeAfter'];_0x1c1e39['writer']['setAttribute']('vid_start',_0x2be7cd['getAttribute']('vid_start'),_0x170e95),_0x1c1e39['writer']['setAttribute']('vid_end',_0x2be7cd['getAttribute']('vid_end'),_0x170e95);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x3b83ca=>{_0x3b83ca['on']('element',(_0x4bca86,_0x1e094d,_0x3f756b)=>{if(!_0x3f756b['consumable']['consume'](_0x1e094d['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x1e094d['modelRange']['isCollapsed'])return;const _0x430e6b=_0x1e094d['modelRange']['start']['nodeAfter'];_0x430e6b['hasAttribute']('vid_start')||_0x430e6b['hasAttribute']('vid')||(_0x3f756b['writer']['setAttribute']('vid_start',_0x1e094d['viewItem']['getAttribute']('vid_start'),_0x430e6b),_0x3f756b['writer']['setAttribute']('vid_end',_0x1e094d['viewItem']['getAttribute']('vid_end'),_0x430e6b));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x2511a2=>_0x2511a2['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x853b30,[,_0xfaa37f])=>{['vid_start','vid_end','vid']['includes'](_0xfaa37f)&&(_0x853b30['return']=!0x0,_0x853b30['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x4cbb83=>{_0x4cbb83['on']('attribute:vid',(_0x4344ee,_0x44cc7e,_0xf41754)=>{if('\x20'!=_0x44cc7e['item']['data']||_0x44cc7e['item']['parent']['maxOffset']>0x1)return;if(!_0xf41754['consumable']['consume'](_0x44cc7e['item'],_0x4344ee['name']))return;const _0x5a9203=_0xf41754['writer'],_0x2c035e=_0xf41754['mapper']['toViewRange'](_0x44cc7e['range']);_0x5a9203['wrap'](_0x2c035e,_0x5a9203['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x5c45ab){const _0x5e3d47=_0x5c45ab['plugins']['get']('RevisionViewer');return(_0x6b4c26,_0x344035,_0x2f81d5)=>{const _0xe26339=_0x344035['markerName']['split'](':')[0x1],_0xf7ebc8=_0x5e3d47['_getChangeFromId'](_0xe26339);if(!_0xf7ebc8)return null;const _0x167b16='add'==_0xf7ebc8['type']?'split':'merge';if(!_0x2f81d5['consumable']['test'](_0x344035['markerRange'],_0x6b4c26['name']))return;const _0x4b1493=_0x344035['markerRange']['getWalker'](),_0x2e6e8a=_0x344035['markerRange']['start'],_0x2dd78d=_0x5c45ab['model']['schema'];let _0x396f42=null,_0x30f578=null,_0x21f1fc=!0x1,_0xb01f89=!0x1;for(const _0x206d14 of _0x4b1493){const _0x5e3f14=_0x206d14['item'];_0x21f1fc=_0x21f1fc||_0x2dd78d['isContent'](_0x5e3f14);const _0x19f5df=_0x2f81d5['mapper']['toViewElement'](_0x5e3f14);if(_0x19f5df&&_0x19f5df['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x206d14['type']&&(_0x2dd78d['isBlock'](_0x5e3f14)&&!_0x2dd78d['isLimit'](_0x5e3f14)&&(_0x5e3f14['nextSibling']||_0x2e6e8a['isAtEnd']?_0x396f42&&_0x396f42['parent']==_0x5e3f14||(_0x396f42=_0x5e3f14,_0xa996c9(_0x206d14['previousPosition']),_0xb01f89=!0x0):_0x30f578=_0x30f578||_0x206d14['previousPosition']));}function _0xa996c9(_0x20b691){const _0x1f43fc=_0x2f81d5['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x167b16}),_0x353889=_0x2f81d5['mapper']['toViewPosition'](_0x20b691);_0xf7ebc8['data']['isSuggestion']&&_0x2f81d5['writer']['addClass']('ck-suggestion-marker-'+_0x167b16+'-new',_0x1f43fc),_0x5e3d47['activeChange']==_0xf7ebc8&&_0x2f81d5['writer']['addClass']('ck-suggestion-marker--active',_0x1f43fc),_0x2f81d5['writer']['insert'](_0x353889,_0x1f43fc),_0x2f81d5['mapper']['bindElementToMarker'](_0x1f43fc,_0x344035['markerName']);}_0x21f1fc||_0xb01f89||!_0x30f578||_0xa996c9(_0x30f578);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x1baddb,_0x591b06,_0x39023f)=>{const _0x3b44f8=_0x39023f['mapper']['markerNameToElements'](_0x591b06['markerName']);if(_0x3b44f8){for(const _0x566e11 of _0x3b44f8)(_0x566e11['hasClass']('ck-suggestion-marker-split')||_0x566e11['hasClass']('ck-suggestion-marker-merge'))&&(_0x39023f['mapper']['unbindElementFromMarkerName'](_0x566e11,_0x591b06['markerName']),_0x39023f['writer']['remove'](_0x566e11));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x44b985,_0x5a0199,_0x18c487)=>{const _0x4c3175=_0x5a0199['markerName']['split'](':')[0x1],_0x2e7eb4=this['_getChangeFromId'](_0x4c3175);if(!_0x2e7eb4)return null;const _0x29e600='add'==_0x2e7eb4['type']?'split':'merge';if(_0x18c487['consumable']['test'](_0x5a0199['markerRange'],_0x44b985['name']))for(const _0x573ae8 of _0x5a0199['markerRange']['getItems']()){if(!_0x573ae8['is']('element','softBreak'))continue;const _0x539628=_0x18c487['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x29e600}),_0x3cab6d=_0x18c487['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x573ae8));_0x2e7eb4['data']['isSuggestion']&&_0x18c487['writer']['addClass']('ck-suggestion-marker-'+_0x29e600+'-new',_0x539628),this['activeChange']==_0x2e7eb4&&_0x18c487['writer']['addClass']('ck-suggestion-marker--active',_0x539628),_0x18c487['writer']['insert'](_0x3cab6d,_0x539628),_0x18c487['mapper']['bindElementToMarker'](_0x539628,_0x5a0199['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x2caaa0=>{for(const _0x4e16aa of this['editor']['model']['document']['getRootNames']()){const _0x2c818c=this['editor']['model']['document']['getRoot'](_0x4e16aa),_0x5100ec=this['editor']['editing']['view']['document']['getRoot'](_0x4e16aa);if(_0x5100ec){const _0x1aeada=_0x2c818c['getAttribute']('revisionHistoryAttachChange');if(_0x2caaa0['removeAttribute']('data-change-id',_0x5100ec),_0x2caaa0['removeClass']('ck-revision-history-root-add',_0x5100ec),_0x2caaa0['removeClass']('ck-revision-history-root-remove',_0x5100ec),_0x2caaa0['removeClass']('ck-revision-history-root--active',_0x5100ec),_0x1aeada){const _0x463cb9=this['_getChangeFromId'](_0x1aeada);if(!_0x463cb9)return null;_0x2caaa0['setAttribute']('data-change-id',_0x1aeada,_0x5100ec),_0x2caaa0['addClass']('ck-revision-history-root-'+_0x463cb9['type'],_0x5100ec),this['activeChange']==_0x463cb9&&_0x2caaa0['addClass']('ck-revision-history-root--active',_0x5100ec);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x2a46af=>'revision-comment:'+_0x2a46af,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x26845a=>'revision-suggestion:'+_0x26845a,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x179c20=>({'name':'suggestion:'+_0x179c20,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x3c6c29=>{const _0x195b79=_0x3c6c29['markerName']['split'](':')[0x1];return'insertion'!=_0x195b79&&'deletion'!=_0x195b79?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x195b79]};}}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:deletion',J(this['editor'],'merge'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:insertion',J(this['editor'],'split'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision-suggestion',(_0x2446ee,_0x46dc9a,_0x3cdf45)=>{const _0x4072d7=_0x3cdf45['mapper']['markerNameToElements'](_0x46dc9a['markerName']);if(_0x4072d7){for(const _0x4d789a of _0x4072d7)_0x4d789a['is']('uiElement')&&(_0x3cdf45['mapper']['unbindElementFromMarkerName'](_0x4d789a,_0x46dc9a['markerName']),_0x3cdf45['writer']['remove'](_0x4d789a));}},{'priority':'high'});}['_getChangeFromId'](_0x4d7163){return this['_changeIdToChange']['get'](_0x4d7163);}['_getViewForChange'](_0x3c4900){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new q(this['editor']['locale'],_0x3c4900),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x1fd126,_0x1ee548,_0x256b16,_0x289692)=>{_0x289692&&this['_balloon']['remove'](_0x289692),_0x256b16&&(this['_balloon']['add']({'view':_0x256b16,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x10a916=this['editor']['editing'],_0x11870b=this['_getChangeFromId'](_0x256b16['changeId']);let _0x44c1aa;if(_0x11870b['data']['isOnRoot']){const _0x229066=_0x10a916['view']['getDomRoot'](_0x11870b['rootName']);_0x44c1aa=Array['from'](_0x229066['getClientRects']());}else{const _0x123898=this['editor']['model']['markers']['get']('revision:'+_0x256b16['changeId']);_0x44c1aa=Array['from'](_0x10a916['mapper']['markerNameToElements'](_0x123898['name']))['map'](_0x1e57f4=>_0x10a916['view']['domConverter']['mapViewToDom'](_0x1e57f4))['map'](_0xaac7ac=>Array['from'](_0xaac7ac['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x44c1aa[0x0];return _0x44c1aa['find'](_0x549707=>_0x549707['top']-0x3<=this['_activeViewTarget']['y']&&_0x549707['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x549707['left']-0x3<=this['_activeViewTarget']['x']&&_0x549707['right']+0x3>=this['_activeViewTarget']['x'])||_0x44c1aa[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x3b43b5,_0x341c3a,_0x3ff408,_0x2da3b7)=>{this['activeView']=_0x3ff408?this['_getViewForChange'](_0x3ff408):null,this['editor']['model']['change'](()=>{const _0x10b551=this['editor']['editing'];_0x2da3b7&&(_0x2da3b7['data']['isOnRoot']?_0x10b551['view']['change'](_0x5be78c=>{_0x5be78c['removeClass']('ck-revision-history-root--active',_0x10b551['view']['document']['getRoot'](_0x2da3b7['rootName']));}):_0x10b551['reconvertMarker']('revision:'+_0x2da3b7['id'])),_0x3ff408&&(_0x3ff408['data']['isOnRoot']?_0x10b551['view']['change'](_0x50061d=>{_0x50061d['addClass']('ck-revision-history-root--active',_0x10b551['view']['document']['getRoot'](_0x3ff408['rootName']));}):_0x10b551['reconvertMarker']('revision:'+_0x3ff408['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x18a620,_0x20aa4e)=>{if(this['activeChange'])return;const _0x1c5620=this['_findChangeIdFromDomTarget'](_0x20aa4e['target']),_0x40a9c6=this['_changeIdToChange']['get'](_0x1c5620);_0x40a9c6?(this['_activeViewTarget']={'x':_0x20aa4e['domEvent']['x'],'y':_0x20aa4e['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x40a9c6)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x553548,_0x5c3fc)=>{const _0x57d0c2=this['_findChangeIdFromDomTarget'](_0x5c3fc['target']),_0x3ada6b=this['_changeIdToChange']['get'](_0x57d0c2);_0x3ada6b?(this['_activeViewTarget']={'x':_0x5c3fc['domEvent']['x'],'y':_0x5c3fc['domEvent']['y']},_0x3ada6b===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x3ada6b):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x1b41c6){do{const _0x4e9e54=_0x1b41c6['getAttribute']('data-change-id');if(_0x4e9e54)return _0x4e9e54;_0x1b41c6=_0x1b41c6['parent'];}while(_0x1b41c6);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x48d737=>{for(const _0x493edd of this['editor']['model']['markers'])_0x48d737['removeMarker'](_0x493edd);});}}function J(_0x4b8b1d,_0x1b76b3){return(_0x100c8b,_0x5795ab,_0xb96ec9)=>{if(!_0xb96ec9['consumable']['test'](_0x5795ab['markerRange'],_0x100c8b['name']))return;const _0x4f0a66=_0x5795ab['markerRange']['getWalker'](),_0xd79c3b=_0x5795ab['markerRange']['start'],_0x1d89de=_0x4b8b1d['model']['schema'];let _0x5a21d0=null,_0x8b141f=null,_0x123ca6=!0x1,_0x19435a=!0x1;for(const _0x494d69 of _0x4f0a66){const _0x30c327=_0x494d69['item'];_0x123ca6=_0x123ca6||_0x1d89de['isContent'](_0x30c327);const _0xcb64a1=_0xb96ec9['mapper']['toViewElement'](_0x30c327);if(_0xcb64a1&&_0xcb64a1['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x494d69['type']&&(_0x1d89de['isBlock'](_0x30c327)&&!_0x1d89de['isLimit'](_0x30c327)&&(_0x30c327['nextSibling']||_0xd79c3b['isAtEnd']?_0x5a21d0&&_0x5a21d0['parent']==_0x30c327||(_0x5a21d0=_0x30c327,_0x2d9a7f(_0x494d69['previousPosition']),_0x19435a=!0x0):_0x8b141f=_0x8b141f||_0x494d69['previousPosition']));}function _0x2d9a7f(_0x3917e1){const _0xa71ea0=_0xb96ec9['mapper']['toViewPosition'](_0x3917e1),_0x11d5e7=_0xb96ec9['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x1b76b3});_0xb96ec9['writer']['insert'](_0xa71ea0,_0x11d5e7),_0xb96ec9['mapper']['bindElementToMarker'](_0x11d5e7,_0x5795ab['markerName']);}_0x123ca6||_0x19435a||!_0x8b141f||_0x2d9a7f(_0x8b141f);};}class RestoreRevisionCommand extends _0x3d5106{constructor(_0xe3aa2f){super(_0xe3aa2f);const _0x2ebddb=_0xe3aa2f['plugins']['get'](u);this['affectsData']=!0x1,this['listenTo'](_0x2ebddb,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x2ebddb,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x56e963=this['editor'],_0x3a6c76=_0x56e963['plugins']['get'](u),_0x409297=_0x3a6c76['isReady']?_0x3a6c76['diff']['newRevisionId']:null;_0x56e963['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x409297);}['refresh'](){const {isReady:_0x11a8c5,isEnabled:_0x11e574,repository:_0xa0de05,diff:_0x100d00}=this['editor']['plugins']['get'](u),_0x48c461=_0x100d00&&_0xa0de05['getLaterVisibleRevision'](_0x100d00['newRevisionId']);this['isEnabled']=_0x11a8c5&&_0x11e574&&Boolean(_0x48c461);}}class ShowChangeCommand extends _0x3d5106{['_step'];constructor(_0x1dab61,{direction:_0x70bfd7}){super(_0x1dab61);const _0x47f473=_0x1dab61['plugins']['get'](u);this['affectsData']=!0x1,this['_step']='forward'===_0x70bfd7?0x1:-0x1,this['listenTo'](_0x47f473,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x47f473,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x47f473,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x5f3833=this['editor'],_0x65c633=_0x5f3833['plugins']['get'](u),{isNavigationMode:_0x342688,currentChangeNumber:_0x3803f5}=_0x65c633;let _0x18442c;if(_0x65c633['activeChange']=_0x342688?_0x65c633['diff']['changes']['get'](_0x3803f5+this['_step']):_0x65c633['diff']['changes']['first'],_0x65c633['activeChange']['data']['isOnRoot'])_0x18442c=_0x5f3833['editing']['view']['getDomRoot'](_0x65c633['activeChange']['rootName']);else{const _0x124684=_0x5f3833['model']['markers']['get']('revision:'+_0x65c633['activeChange']['id']);_0x18442c=_0x284dea(_0x5f3833['editing'],_0x124684);}_0x37c45d({'target':_0x18442c,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x518e44,currentChangeNumber:_0x348280,numberOfChanges:_0x2d4aec,isReady:_0x57bd9f,isEnabled:_0x1eb6d5}=this['editor']['plugins']['get'](u);this['isEnabled']=!!(_0x1eb6d5&&_0x57bd9f&&_0x2d4aec)&&(!_0x518e44||(0x1===this['_step']?_0x348280<_0x2d4aec-0x1:_0x348280>0x0));}}class pi extends _0x340389{constructor(_0x568693){super(_0x568693);const _0x4bb8d3=this['bindTemplate'],_0xfc7f4=new _0x3d7f7c(_0x568693),_0x51072c=new _0x3d7f7c(_0x568693);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',(_0x398a04,_0x3104c5)=>_0x398a04&&_0x3104c5>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x489822,_0x50a5d3,_0x82328b,_0x4f84ef)=>{if(!_0x489822)return m(_0x568693,'Loading...');if(!_0x82328b)return m(_0x568693,'No\x20changes');const _0x2bbcec=m(_0x568693,'NUMBER_OF_CHANGES',_0x82328b);return _0x4f84ef?m(_0x568693,'X_OF_Y_CHANGES',[_0x50a5d3+0x1,_0x82328b]):_0x2bbcec;}),_0xfc7f4['set']({'label':m(_0x568693,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x475a7a}),_0x51072c['set']({'label':m(_0x568693,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x16b634}),_0xfc7f4['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x51072c['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0xfc7f4['on']('execute',()=>this['fire']('execute','backward')),_0x51072c['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',_0x4bb8d3['if']('_isStatusLabelVisible','ck-hidden',_0x1ee0b9=>!_0x1ee0b9)]},'children':[{'text':_0x4bb8d3['to']('isNavigationMode',_0x50f011=>_0x50f011?m(_0x568693,'EDIT_X_OF_Y_REVISIONS')+':\x20':m(_0x568693,'Total')+':\x20')}]},{'text':_0x4bb8d3['to']('_statusText')}]},new _0x530a8f(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0xfc7f4,_0x51072c]}]});}}const ge='ck-editor__editable__loading-overlay';class fi extends _0x5ac587{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x2f9e34=this['editor']['editing']['view'];_0x2f9e34['change'](_0x393b36=>{for(const _0x3c2b50 of _0x2f9e34['document']['roots'])_0x393b36['addClass'](ge,_0x3c2b50);});}['hide'](){const _0x2f6a04=this['editor']['editing']['view'];_0x2f6a04['change'](_0x46e965=>{for(const _0x564477 of _0x2f6a04['document']['roots'])_0x46e965['removeClass'](ge,_0x564477);});}}class v extends _0x5ac587{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u,fi];}['init'](){const _0x513332=this['editor'],_0x4be9bf=_0x513332['plugins']['get'](u),_0x460f71=_0x513332['plugins']['get'](fi);_0x513332['ui']['componentFactory']['add']('exitToEditing',_0x381a3e=>{const _0x125bcd=new _0x3d7f7c(_0x381a3e);return _0x125bcd['set']({'label':m(_0x381a3e,'Back\x20to\x20editing'),'icon':_0x43dc61,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x125bcd,'execute',()=>{_0x513332['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x125bcd;}),_0x513332['ui']['componentFactory']['add']('restoreRevision',_0xe91f=>{const _0x55b28f=new _0x3d7f7c(_0xe91f);return _0x55b28f['set']({'label':m(_0xe91f,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x55b28f['bind']('isEnabled')['to'](_0x513332['commands']['get']('restoreRevision')),this['listenTo'](_0x55b28f,'execute',()=>_0x513332['execute']('restoreRevision')),_0x55b28f;}),_0x513332['ui']['componentFactory']['add']('changesNavigation',_0x4803a8=>{const _0x444f69=new pi(_0x4803a8),_0x283e57=_0x513332['commands']['get']('showPreviousChange'),_0x109e5c=_0x513332['commands']['get']('showNextChange');return _0x444f69['bind']('isBackwardNavigationEnabled')['to'](_0x283e57,'isEnabled'),_0x444f69['bind']('isForwardNavigationEnabled')['to'](_0x109e5c,'isEnabled'),_0x444f69['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x4be9bf),this['listenTo'](_0x444f69,'execute',(_0x15e8f7,_0x3164e8)=>{_0x513332['execute']('forward'===_0x3164e8?'showNextChange':'showPreviousChange');}),_0x444f69;}),_0x460f71['show'](),_0x4be9bf['on']('change:isReady',(_0x37f363,_0x37c634,_0x394378)=>{_0x394378?_0x460f71['hide']():_0x460f71['show']();});}}class oi extends et{['_resizeObserver']=null;constructor(_0x272ea7,_0x35cf34){super(_0x272ea7,_0x35cf34);const _0x68d967=this['bindTemplate'];this['set']({'label':m(_0x272ea7,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=m(_0x272ea7,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x68d967['to']('_tooltipString'),'data-cke-tooltip-position':'s','data-cke-tooltip-class':'ck-tooltip_multi-line'}});}['render'](){super['render'](),this['_resizeObserver']=new ot(this['fieldView']['element'],()=>this['_updateTooltipText']()),this['listenTo'](this['fieldView'],'input',()=>this['_updateTooltipText']());}['destroy'](){super['destroy'](),this['_resizeObserver']&&this['_resizeObserver']['destroy']();}['_updateTooltipText'](){const _0x5eb140=this['fieldView']['element'];this['_tooltipString']=_0x5eb140['scrollWidth']>_0x5eb140['clientWidth']&&_0x5eb140['value']||'';}}class hi extends _0x340389{constructor(_0x1ae06e,_0x341575,_0x215acd){super(_0x1ae06e);const _0x5ebc49=new _0x4e3434();_0x5ebc49['set']({'content':_0x17cfe1,'viewBox':'0\x200\x2011\x2010'});const _0x43b40a=['ck','ck-revision-history-sidebar__revision-author'];_0x215acd&&_0x43b40a['push']('ck-revision-history-sidebar__revision-author_creator');const _0x502a09=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':m(_0x1ae06e,_0x215acd?'Revision\x20creator':'Revision\x20author')},'children':[_0x5ebc49,_0x341575['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x43b40a},'children':_0x502a09});}}function ci(_0x182897,_0x4ecd6e){const _0x4b6114=_0x182897['bindTemplate'],_0xafb9d6=_0x182897['locale'],_0x243b84=_0x37cd46(_0xafb9d6);_0x243b84['panelPosition']='sw';const _0x246c34=function(_0x506b92,_0x3507bf){const _0x4f667b=function(_0x375eac,_0x9c309){const _0x264748=_0x375eac['locale'],_0x2f4359={'Compare\x20against\x20selected':m(_0x264748,'Compare\x20against\x20selected'),'Name\x20this\x20revision':m(_0x264748,'Name\x20this\x20revision'),'Restore\x20this\x20revision':m(_0x264748,'Restore\x20this\x20revision')};return _0x9c309['map'](_0x451dff=>{const _0x316b5d=_0x2f4359[_0x451dff['name']];return _0x316b5d&&_0x316b5d!==_0x451dff['name']&&(_0x451dff['name']=_0x316b5d),_0x451dff;});}(_0x506b92,_0x3507bf),_0x4c07ac=new _0x4cfa07();for(const _0x482f6e of _0x4f667b){const _0x44b6d7={'type':'button','model':new to({'label':_0x482f6e['name'],'class':_0x482f6e['class'],'withText':!0x0,'role':'menuitem','_action':_0x482f6e['action']})};_0x44b6d7['model']['bind']('isEnabled')['to'](_0x506b92,'isActionsDropdownOpen',_0x40d7f4=>'function'!=typeof _0x482f6e['isEnabled']||(!_0x40d7f4||_0x482f6e['isEnabled'](_0x506b92))),_0x4c07ac['add'](_0x44b6d7);}return _0x4c07ac;}(_0x182897,_0x4ecd6e);return _0x182897['bind']('isActionsDropdownOpen')['to'](_0x243b84,'isOpen'),_0x243b84['buttonView']['set']({'label':m(_0xafb9d6,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x5e37df}),_0x243b84['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x4b6114['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x4b6114['to'](_0x2a7034=>_0x2a7034['stopPropagation']())}}),_0x243b84['on']('execute',_0x45f1db=>{_0x182897['isReady']&&'function'==typeof _0x45f1db['source']['_action']&&_0x45f1db['source']['_action'](_0x182897);}),_0x3e11ba(_0x243b84,_0x246c34,{'role':'menu'}),_0x243b84['listenTo'](_0x182897,'change:isActionsDropdownOpen',(_0x1db24d,_0x26f138,_0x57de59)=>{if(_0x57de59)for(const _0x3ffa8d of _0x243b84['listView']['items']){const _0x387337=_0x3ffa8d['children']['first'],_0x17a082=_0x4ecd6e['find'](_0x1fac80=>_0x1fac80['action']===_0x387337['_action'])['isVisible'];_0x3ffa8d['isVisible']=void 0x0===_0x17a082||_0x17a082(_0x182897);}}),_0x243b84;}class _i extends/* #__PURE__ -- @preserve */
27
+ _0x379a5a(_0x340389){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x35ac7c,_0x31beb5,_0x2a8ed8,_0x8f0cf4){super(_0x35ac7c);const _0x398552=this['bindTemplate'],_0x591fb2=function(_0x1defc4,_0x43d4f3){const _0x43ae5f=Array['from'](_0x43d4f3['authors'])['filter'](_0x4f3f2f=>_0x4f3f2f!=_0x43d4f3['creator']);return _0x43d4f3['creator']&&_0x43ae5f['unshift'](_0x43d4f3['creator']),_0x43ae5f['map'](_0x1df52e=>new hi(_0x1defc4,_0x1df52e,_0x1df52e==_0x43d4f3['creator']));}(_0x35ac7c,_0x31beb5);this['id']=_0x31beb5['id'],this['_revision']=_0x31beb5,this['_requireRevisionName']=_0x8f0cf4,this['bind']('name','createdAt')['to'](_0x31beb5),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x4cb4f8=>{return _0x318c93=_0x35ac7c['uiLanguage'],(_0xdb1bf6=_0x4cb4f8)['toLocaleDateString'](_0x318c93,{'month':'long','day':'numeric'})+',\x20'+_0xdb1bf6['toLocaleTimeString'](_0x318c93,{'hour':'numeric','minute':'numeric'});var _0x318c93,_0xdb1bf6;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new oi(_0x35ac7c,ti),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x61443b=>_0x61443b||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x179910,_0x8fe0a5)=>_0x179910&&_0x8fe0a5),this['revisionActionsView']=_0x2a8ed8&&_0x2a8ed8['length']?ci(this,_0x2a8ed8):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x398552['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x398552['if']('isEnabled','ck-disabled',_0x51947c=>!_0x51947c),_0x398552['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x398552['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x398552['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':_0x398552['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':_0x591fb2}]},this['revisionActionsView']],'on':{'click':_0x398552['to'](_0xc43b03=>{_0xc43b03['srcElement']['closest']('.ck-confirm-view')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x86687c=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x86687c,'change',()=>{this['_requireRevisionName']&&!_0x86687c['value']||this['fire']('setName',{'id':this['id'],'name':_0x86687c['value']}),_0x86687c['value']||(_0x86687c['value']=this['name']?this['name']:this['_createdAtFormatted']);});}['select'](){this['isSelected']=!0x0;}['deselect'](){this['isSelected']=!0x1;}['highlight'](){this['isHighlighted']=!0x0;}['unhighlight'](){this['isHighlighted']=!0x1;}}function bi(_0x5c1bcf,_0x1ee328){const _0x2cb3ab=_0xc5fc85['fromJSDate'](_0x5c1bcf)['setLocale'](_0x1ee328),_0x47e02f=_0xc5fc85['local'](),_0x4c421c=_0x47e02f['minus']({'days':0x1})['startOf']('day');let _0x184002,_0x4021fe;return _0x2cb3ab['hasSame'](_0x47e02f,'day')?(_0x184002=_0x2cb3ab['startOf']('day')['toJSDate'](),_0x4021fe=_0x2cb3ab['toRelativeCalendar']()):_0x2cb3ab['hasSame'](_0x4c421c,'day')?(_0x184002=_0x4c421c['toJSDate'](),_0x4021fe=_0x2cb3ab['toRelativeCalendar']()):_0x2cb3ab['hasSame'](_0x47e02f,'week')?(_0x184002=_0x2cb3ab['startOf']('week')['toJSDate'](),_0x4021fe=_0x2cb3ab['weekdayLong']||''):_0x2cb3ab['hasSame'](_0x47e02f,'year')?(_0x184002=_0x2cb3ab['startOf']('month')['toJSDate'](),_0x4021fe=_0x2cb3ab['monthLong']||''):(_0x184002=_0x2cb3ab['startOf']('year')['toJSDate'](),_0x4021fe=String(_0x2cb3ab['year'])),{'startDate':_0x184002,'localizedPeriodName':_0x4021fe};}class ki extends _0x340389{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x2349b1,_0x2294c2,_0x1f4d18,_0x1a6075){super(_0x2349b1);const _0x54af66=bi(_0x2294c2,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x2294c2,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x1f4d18,this['_requireRevisionName']=_0x1a6075,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':_0x54af66}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x356b33){const _0x16b09b=new _i(this['locale'],_0x356b33,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x16b09b);}['removeRevision'](_0x3ec686){const _0x35f7b9=this['revisionViews']['find'](_0x411ba8=>_0x411ba8['id']===_0x3ec686['id']);this['revisionViews']['remove'](_0x35f7b9);}}class ji extends _0x340389{constructor(_0x187cb9){super(_0x187cb9);const _0x8969c=new _0x4e3434();_0x8969c['content']=_0x1e1fa6,this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x8969c,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[m(_0x187cb9,'Revision\x20history')]}]});}}class Ri extends _0x340389{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x524f7c,_0x24fbef,_0x18b4ce,_0x446921){super(_0x524f7c);const _0xa6df55=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x24fbef,this['_revisionActions']=_0x18b4ce,this['_requireRevisionName']=_0x446921,this['on']('select',(_0x3de216,_0x7efc99)=>{this['fire']('revisionSelected',_0x7efc99);}),this['on']('setName',(_0x43da9d,_0x2efcb1)=>{this['fire']('revisionSetName',_0x2efcb1);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new ji(_0x524f7c),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0xa6df55['if']('isEnabled','ck-disabled',_0x5acde6=>!_0x5acde6)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x2b1da8 of this['_revisions'])this['_addRevision'](_0x2b1da8);this['_revisions']['on']('add',(_0x5832f9,_0x15a6c7)=>{this['_addRevision'](_0x15a6c7);}),this['_revisions']['on']('remove',(_0x219ea8,_0x465776)=>{this['_removeRevision'](_0x465776);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x3a377f=>_0x3a377f['revisionViews']['map'](_0x855d15=>_0x855d15))['flat']();}['selectRevision'](_0x316c7c){for(const _0x27fa33 of this['revisionViews'])_0x316c7c&&_0x316c7c['id']===_0x27fa33['id']?_0x27fa33['select']():_0x27fa33['deselect']();}['highlightRevisions'](_0x3c96df){for(const _0x2cd09f of this['revisionViews'])_0x3c96df['some'](({id:_0x383f85})=>_0x383f85===_0x2cd09f['id'])?_0x2cd09f['highlight']():_0x2cd09f['unhighlight']();}['_addRevision'](_0x1f686a){const _0x184503=bi(_0x1f686a['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x4e39c8=this['timePeriodViews']['get'](0x0);_0x4e39c8&&_0x4e39c8['startDate']['getTime']()===_0x184503['getTime']()||(_0x4e39c8=new ki(this['locale'],_0x184503,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x4e39c8)),_0x4e39c8['addRevision'](_0x1f686a);}['_removeRevision'](_0x55ad5f){const _0x5c0633=bi(_0x55ad5f['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x5c0633)['removeRevision'](_0x55ad5f);}['_getTimePeriodViewByStartDate'](_0x487dc7){return this['timePeriodViews']['find'](_0x1d1b39=>_0x1d1b39['startDate']['getTime']()===_0x487dc7['getTime']());}}class d extends _0x5ac587{['_revisionViewer'];['_revisionsRepository'];['_sidebarView'];static ['defaultRevisionActions']=/* #__PURE__ -- @preserve */
28
28
  ((()=>['compareAgainstSelected','restoreRevision','nameRevision'])());static ['availableRevisionActions']=/* #__PURE__ -- @preserve */
29
- nt();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u];}constructor(_0x1deea9){super(_0x1deea9),this['_revisionViewer']=_0x1deea9['plugins']['get'](u),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x5873f9=this['_revisionsRepository']['_revisions'],_0x4f633a=this['_createRevisionActions'](),_0x1598be=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new di(this['editor']['locale'],_0x5873f9,_0x4f633a,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',(_0x54d1fb,_0x11c022)=>{_0x11c022['revisionViews']['on']('add',(_0x533d01,_0x437334)=>{_0x437334['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)),_0x1598be['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x29b80f=this['_revisionsRepository']['getRevision'](0x0);if(_0x29b80f){const _0x369041=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x29b80f['id']);this['_revisionViewer']['compare'](_0x29b80f,_0x369041);}}['_handleRevisionSelected'](_0x1000e3,_0x4f9fd9){const _0x2e74a8=this['_revisionsRepository']['getRevision'](_0x4f9fd9['id']),_0x505cc9=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x2e74a8['id']);this['_revisionViewer']['compare'](_0x2e74a8,_0x505cc9);}['_handleRevisionSetName'](_0x527088,_0x35b563){this['_revisionsRepository']['getRevision'](_0x35b563['id'])['setName'](_0x35b563['name']);}['_handleDiffChange'](_0x4eb2a8,_0x46ee57,_0x2b2337){const _0x31d459=this['_revisionsRepository']['getRevisionsInDiff'](_0x2b2337);_0x31d459['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x31d459),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x31d459[0x0]));}['_createRevisionActions'](){const _0x3a218f=this['editor'],_0x28c93f=d['availableRevisionActions'],_0x29ee58=_0x3a218f['config']['get']('revisionHistory.revisionActions')||d['defaultRevisionActions'];if(_0x29ee58['length'])return _0x29ee58['map'](_0x55ce93=>{const _0x57442e='string'==typeof _0x55ce93?Object['assign']({},_0x28c93f[_0x55ce93]):_0x55ce93;return _0x57442e['action']=_0x57442e['action']['bind'](this,_0x3a218f),_0x57442e['isVisible']&&(_0x57442e['isVisible']=_0x57442e['isVisible']['bind'](this,_0x3a218f)),_0x57442e;});}}function nt(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x340133},_0x51a092)=>{const _0xbb0924=_0x340133['get'](u),_0x54c0d6=_0xbb0924['repository'];let _0x3ea9eb=_0xbb0924['diff']['newRevisionId'],_0x39724e=_0x51a092['id'];_0x54c0d6['getIndex'](_0x3ea9eb)>_0x54c0d6['getIndex'](_0x39724e)&&([_0x3ea9eb,_0x39724e]=[_0x39724e,_0x3ea9eb]),_0xbb0924['compare'](_0x3ea9eb,_0x39724e);},'isVisible':({plugins:_0x26f10f},_0x506ec2)=>{const _0x31a185=_0x26f10f['get'](u);return!(_0x31a185['repository']['getRevisionsInDiff'](_0x31a185['diff'])['length']>0x2)&&!_0x506ec2['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0xaa1952,{id:_0xa073c9})=>{_0xaa1952['config']['get']('revisionHistory')['restoreRevisionCallback'](_0xa073c9);},'isVisible':({plugins:_0x4c9435},_0x196a56)=>!!_0x4c9435['get'](u)['repository']['getLaterVisibleRevision'](_0x196a56['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x3dc11c},{id:_0x52cb56,revisionNameView:_0x236c70})=>{const _0x56093f=_0x3dc11c['get'](u),_0xa55268=_0x56093f['repository']['getEarlierVisibleRevision'](_0x52cb56);_0x56093f['compare'](_0x52cb56,_0xa55268),_0x236c70['focus'](),_0x236c70['fieldView']['select']();}}};}class Y extends tt{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x2dc5a7,_0x2444c3){super(_0x2dc5a7),this['_view']=_0x2444c3,this['_toolbarConfig']=st(_0x2dc5a7['config']['get']('toolbar')),this['_elementReplacer']=new it();}get['element'](){return this['view']['element'];}['init'](_0x341b6f){const _0x188206=this['editor'],_0x386139=this['view'],_0xb9da2e=_0x188206['editing']['view'],_0x21a361=_0x386139['editable'],_0x1af3bf=_0xb9da2e['document']['getRoot']();_0x21a361['name']=_0x1af3bf['rootName'],_0x386139['render']();const _0x3f93f4=_0x21a361['element'];this['setEditableElement'](_0x21a361['name'],_0x3f93f4),_0x386139['editable']['bind']('isFocused')['to'](this['focusTracker']),_0xb9da2e['attachDomRoot'](_0x3f93f4),this['_elementReplacer']['replace'](_0x341b6f,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x5a9036=this['view'],_0x55e57e=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x55e57e['detachDomRoot'](_0x5a9036['editable']['name']),_0x5a9036['destroy']();}['_initToolbar'](){const _0x3b070d=this['view'];_0x3b070d['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x3b070d['stickyPanel']['limiterElement']=_0x3b070d['element'],_0x3b070d['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x28a8b2})=>_0x28a8b2),_0x3b070d['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x3b070d['toolbar']);}}class Z extends _0x2af41{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x240382,_0x5a4e02,_0x32d369={}){super(_0x240382),this['stickyPanel']=new _0x1e83cf(_0x240382),this['toolbar']=new _0x8564d3(_0x240382,{'shouldGroupWhenFull':_0x32d369['shouldToolbarGroupWhenFull']}),this['_editable']=new te(_0x240382,_0x5a4e02);}['render'](){super['render'](),this['stickyPanel']['content']['add'](this['toolbar']),this['top']['add'](this['stickyPanel']),this['main']['add'](this['editable']);}}class f extends/* #__PURE__ -- @preserve */
30
- _0x1bf367(_0x5a3aa2){['_ui'];get['ui'](){return this['_ui'];}constructor(_0xd33cf4,_0x1b12a8){super(_0x1b12a8),this['sourceElement']=_0xd33cf4,this['model']['document']['createRoot']();const _0x3aafc2=new Z(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new Y(this,_0x3aafc2);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x7cca60,_0x4bc95c){const _0x41c65b=new this(_0x7cca60,_0x4bc95c);return await _0x41c65b['initPlugins'](),await _0x41c65b['ui']['init'](_0x7cca60),await _0x41c65b['data']['init'](_0x41c65b['config']['get']('initialData')||''),_0x41c65b['fire']('ready'),_0x41c65b;}}const p=['RevisionHistoryUI','RestrictedEditingMode','AIChat','AIReviewMode','AIBalloon','AIQuickActions','AIActions','AIChatShortcuts','AITranslate'];class RevisionViewerIntegration extends _0xde4b58{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x10a1ee){function _0x36b4e3(_0xeafd88){return _0xeafd88['map'](_0x4cf5e7=>String['fromCharCode'](_0x4cf5e7))['join']('');}super(_0x10a1ee),this['result']='end',_0x10a1ee[_0x36b4e3([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x36b4e3([0x76,0x69,0x65,0x77])][_0x36b4e3([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x36b4e3([0x61,0x75,0x74,0x6f]),_0x10a1ee[_0x36b4e3([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x36b4e3([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x36b4e3([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x36b4e3([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x36b4e3([0x6f,0x6b])});}}class RevisionHistory extends _0xde4b58{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h,l];}constructor(_0x56fb59){if(super(_0x56fb59),!this['editor']['config']['get']('revisionHistory'))throw new _0x2fd89f('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x2d11f0=>this['_showRevisionViewer']({..._0x2d11f0,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x39e9f8=>this['_closeRevisionViewer'](_0x39e9f8)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x11ca94=>this['_restoreRevision'](_0x11ca94)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x2bdd63){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x2bdd63;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x4693a2){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x4693a2);}['getRevision'](_0x99087f){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x99087f);}['getRevisions'](_0x2016d9){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x2016d9||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0xb0e21c=this['editor'],_0x3eed13=_0x3f3d11(_0xb0e21c,p),_0x470edd=_0xb0e21c['plugins']['get']('RevisionTracker'),_0x383ac2=_0xb0e21c['plugins']['get']('Users')['users'];return _0x3eed13['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x3eed13['lazyRoots'],(_0x3eed13['plugins']['push'](RevisionViewerIntegration,u,v,class RevisionViewerInit extends _0xde4b58{static get['requires'](){return[u,'Users'];}['init'](){const _0x58a5af=this['editor']['plugins']['get']('Users');for(const _0xf320a6 of _0x383ac2)_0xf320a6['isAnonymous']||_0x58a5af['getUser'](_0xf320a6['id'])||_0x58a5af['addUser'](_0xf320a6);const _0xbbb359=_0x470edd['repository']['getRevisions']();let _0x40cea0=null;const _0x3662d8=this['editor']['plugins']['get']('RevisionViewer');_0x3662d8['adapter']=_0x470edd['adapter'],_0x3662d8['bind']('isEnabled')['to'](_0x470edd),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0xb0e21c,'isReadOnly',_0x4353f1=>!_0x4353f1);for(const _0x9f4da6 of _0xbbb359){const _0x51df37=null===_0x9f4da6['creator'];if(_0x51df37&&_0x9f4da6['toVersion']===_0x9f4da6['fromVersion'])continue;const _0x511f3b=_0x9f4da6['toJSON']();_0x3662d8['addRevisionData'](_0x511f3b,(_0x54d319,_0x340e2c,_0x30ea1b)=>{if(_0x51df37){if(_0x40cea0)_0x40cea0['_update'](_0x54d319,_0x340e2c);else{if(!_0x340e2c){const _0x51f5a2=_0x30ea1b['toJSON']();_0x51f5a2['id']=_0xefa39(),_0x470edd['saveRevision'](_0x51f5a2,_0x30ea1b['toVersion'])['then'](_0x1a279c=>{_0x40cea0=_0x1a279c;});}}}else _0x9f4da6['_update'](_0x54d319,_0x340e2c);});}}},d),_0x3eed13);}['_enhanceShowRevisionViewerCallback'](){const _0x5978dc=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x5a937f=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x552b33=this['editor']['plugins']['get']('Autosave');await _0x552b33['save']();}else await _0x5a937f['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x1728c1=this['editor']['plugins']['get']('Dialog');_0x1728c1['isOpen']&&_0x1728c1['hide']();}if(this['editor']['plugins']['has']('AITabs')){const _0xac2d2d=this['editor']['plugins']['get']('AITabs')['view']['panelViews'];for(const _0x3bc176 of _0xac2d2d)_0x3bc176['class']=_0x3bc176['class']?_0x3bc176['class']+'\x20ck-tab-panel_disabled':'ck-tab-panel_disabled';if(this['editor']['plugins']['has']('AIChat')){const _0x12d880=document['querySelector']('.ck-ai-chat__prompt-input\x20.ck-textarea');_0x12d880&&_0x12d880['setAttribute']('tabindex','-1');}if(this['editor']['plugins']['has']('AIChatHistory')){const _0x357c5e=document['querySelector']('.ck-ai-chat-history\x20.ck-input');_0x357c5e&&_0x357c5e['setAttribute']('tabindex','-1');}}const _0x27da1f=this['_getRevisionViewerEditorConfig']();return _0x5978dc(_0x27da1f)['then'](_0x4b5bde=>{return(this['_viewerEditor']=_0x4b5bde,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'),_0x4b5bde);})['catch'](_0x4fca9e=>(console['error'](_0x4fca9e),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0xa741ea=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 _0x4b643b=this['editor']['plugins']['get']('AITabs')['view']['panelViews'];for(const _0xeb8d0e of _0x4b643b)_0xeb8d0e['class']='ck-tab-panel_disabled'===_0xeb8d0e['class']?'':_0xeb8d0e['class']['replace']('\x20ck-tab-panel_disabled','');if(this['editor']['plugins']['has']('AIChat')){const _0x46e95f=document['querySelector']('.ck-ai-chat__prompt-input\x20.ck-textarea');_0x46e95f&&_0x46e95f['removeAttribute']('tabindex');}if(this['editor']['plugins']['has']('AIChatHistory')){const _0x52e2d0=document['querySelector']('.ck-ai-chat-history\x20.ck-input');_0x52e2d0&&_0x52e2d0['removeAttribute']('tabindex');}}return this['_viewerEditor']['plugins']['get']('RevisionViewer')['_cleanUp'](),_0xa741ea(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x4b2904=this['editor']['plugins']['get']('Annotations');_0x4b2904['refreshVisibility'](),_0x4b2904['refreshPositioning']();}});});}['_showRevisionViewer'](_0xce72ef){const _0x3355b1=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x584313=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x235184=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return f['create'](_0x235184,_0xce72ef)['then'](_0x291ca9=>(_0x584313['style']['display']='block',_0x3355b1['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x291ca9));}['_closeRevisionViewer'](_0x25b953){const _0xa7e474=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0xa7e474['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x25b953['destroy']();}async['_restoreRevision'](_0x45b73e){const _0x2ad9f2=this['editor'],_0x45143b=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x573069=_0x2ad9f2['plugins']['get']('RevisionTracker'),_0x2c9ccb=_0x2ad9f2['plugins']['get']('RevisionHistoryUtils'),_0x46f86f=_0x45143b['repository']['getRevision'](_0x45b73e);let _0x3e4630,_0x20e647,_0x254973;try{await _0x2c9ccb['loadRevisionData'](_0x46f86f,this['adapter']),_0x3e4630=_0x2c9ccb['getRevisionDocumentData'](_0x46f86f),_0x20e647=_0x2c9ccb['getRevisionRootsAttributes'](_0x46f86f);}catch(_0x33418d){return void console['error'](_0x33418d);}_0x2ad9f2['model']['change'](_0x5547d4=>{for(const _0x2c7db2 of Array['from'](_0x2ad9f2['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x5547d4['removeMarker'](_0x2c7db2);}),_0x45143b['isReady']=!0x1,_0x2ad9f2['model']['enqueueChange'](_0x387ddf=>{_0x387ddf['setSelection'](null),_0x387ddf['removeSelectionAttribute'](_0x2ad9f2['model']['document']['selection']['getAttributeKeys']());const _0x440516=Object['keys'](_0x3e4630);for(const _0x3da25e of _0x2ad9f2['model']['document']['roots'])'$graveyard'!=_0x3da25e['rootName']&&_0x3da25e['isAttached']()&&!_0x440516['includes'](_0x3da25e['rootName'])&&_0x387ddf['detachRoot'](_0x3da25e);for(const _0x112070 of _0x440516){let _0x2b2f60=_0x2ad9f2['model']['document']['getRoot'](_0x112070);_0x2b2f60&&_0x2b2f60['isAttached']()||(_0x2b2f60=_0x387ddf['addRoot'](_0x112070));const _0x5dd270=_0x20e647[_0x112070],_0x1e77e4=Object['keys'](_0x5dd270),_0x69aecc=_0x3e4630[_0x112070];for(const _0x195799 of _0x2b2f60['getAttributeKeys']())_0x1e77e4['includes'](_0x195799)||_0x387ddf['removeAttribute'](_0x195799,_0x2b2f60);for(const _0x199726 of _0x1e77e4)_0x387ddf['setAttribute'](_0x199726,_0x20e647[_0x112070][_0x199726],_0x2b2f60);_0x387ddf['remove'](_0x387ddf['createRangeIn'](_0x2b2f60)),_0x387ddf['insert'](_0x2ad9f2['data']['parse'](_0x69aecc,_0x2b2f60),_0x2b2f60,0x0);}});const _0xe42191=m(_0x2ad9f2['locale'],'Restored');if(_0x46f86f['name'])_0x254973=-0x1==_0x46f86f['name']['indexOf'](_0xe42191)?_0xe42191+':\x20'+_0x46f86f['name']:_0x46f86f['name'];else _0x254973=_0xe42191+':\x20'+(_0x46f86f['createdAt']['toLocaleDateString'](_0x2ad9f2['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x46f86f['createdAt']['toLocaleTimeString'](_0x2ad9f2['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x573069['saveRevision']({'name':_0x254973}),_0x45143b['isReady']=!0x0,_0x2ad9f2['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{RestoreRevisionCommand,I as Revision,RevisionHistory,l as RevisionHistoryUI,$ as RevisionHistoryUtils,h as RevisionTracker,u as RevisionViewer,f as RevisionViewerEditor,RevisionViewerIntegration,Ri as RevisionViewerLoadingOverlay,v as RevisionViewerUI,S as RevisionsRepository,d as RevisionsSidebar,ShowChangeCommand};
29
+ nt();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u];}constructor(_0x2b1513){super(_0x2b1513),this['_revisionViewer']=_0x2b1513['plugins']['get'](u),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x3d58b3=this['_revisionsRepository']['_revisions'],_0x1158f1=this['_createRevisionActions'](),_0x3341bf=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new Ri(this['editor']['locale'],_0x3d58b3,_0x1158f1,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',(_0x1dd74b,_0x215cd4)=>{_0x215cd4['revisionViews']['on']('add',(_0x1a3139,_0x42f6cb)=>{_0x42f6cb['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)),_0x3341bf['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x271b1c=this['_revisionsRepository']['getRevision'](0x0);if(_0x271b1c){const _0x2cdc2b=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x271b1c['id']);this['_revisionViewer']['compare'](_0x271b1c,_0x2cdc2b);}}['_handleRevisionSelected'](_0x223655,_0x41e34f){const _0x5d99f0=this['_revisionsRepository']['getRevision'](_0x41e34f['id']),_0x4c2310=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x5d99f0['id']);this['_revisionViewer']['compare'](_0x5d99f0,_0x4c2310);}['_handleRevisionSetName'](_0x428b48,_0x28d094){this['_revisionsRepository']['getRevision'](_0x28d094['id'])['setName'](_0x28d094['name']);}['_handleDiffChange'](_0x4797b1,_0x2a313a,_0x4fbb74){const _0x12882e=this['_revisionsRepository']['getRevisionsInDiff'](_0x4fbb74);_0x12882e['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x12882e),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x12882e[0x0]));}['_createRevisionActions'](){const _0x2d7fbd=this['editor'],_0x7b270f=d['availableRevisionActions'],_0x262e71=_0x2d7fbd['config']['get']('revisionHistory.revisionActions')||d['defaultRevisionActions'];if(_0x262e71['length'])return _0x262e71['map'](_0x5455cc=>{const _0x5d76c0='string'==typeof _0x5455cc?Object['assign']({},_0x7b270f[_0x5455cc]):_0x5455cc;return _0x5d76c0['action']=_0x5d76c0['action']['bind'](this,_0x2d7fbd),_0x5d76c0['isVisible']&&(_0x5d76c0['isVisible']=_0x5d76c0['isVisible']['bind'](this,_0x2d7fbd)),_0x5d76c0;});}}function nt(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x40e676},_0x3059ec)=>{const _0x25cb20=_0x40e676['get'](u),_0xe54e09=_0x25cb20['repository'];let _0x3b191a=_0x25cb20['diff']['newRevisionId'],_0x497740=_0x3059ec['id'];_0xe54e09['getIndex'](_0x3b191a)>_0xe54e09['getIndex'](_0x497740)&&([_0x3b191a,_0x497740]=[_0x497740,_0x3b191a]),_0x25cb20['compare'](_0x3b191a,_0x497740);},'isVisible':({plugins:_0x5b8a87},_0x4d84a1)=>{const _0x230f66=_0x5b8a87['get'](u);return!(_0x230f66['repository']['getRevisionsInDiff'](_0x230f66['diff'])['length']>0x2)&&!_0x4d84a1['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x26a762,{id:_0x4fc38e})=>{_0x26a762['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x4fc38e);},'isVisible':({plugins:_0x3f2535},_0x3b0111)=>!!_0x3f2535['get'](u)['repository']['getLaterVisibleRevision'](_0x3b0111['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x3a0187},{id:_0x12387a,revisionNameView:_0x5eec55})=>{const _0x3b0cc3=_0x3a0187['get'](u),_0x208975=_0x3b0cc3['repository']['getEarlierVisibleRevision'](_0x12387a);_0x3b0cc3['compare'](_0x12387a,_0x208975),_0x5eec55['focus'](),_0x5eec55['fieldView']['select']();}}};}class Y extends tt{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x568fad,_0x54a414){super(_0x568fad),this['_view']=_0x54a414,this['_toolbarConfig']=st(_0x568fad['config']['get']('toolbar')),this['_elementReplacer']=new it();}get['element'](){return this['view']['element'];}['init'](_0x1fb5c4){const _0x18fedd=this['editor'],_0x572c6d=this['view'],_0x3a6bff=_0x18fedd['editing']['view'],_0xaa668=_0x572c6d['editable'],_0x172fba=_0x3a6bff['document']['getRoot']();_0xaa668['name']=_0x172fba['rootName'],_0x572c6d['render']();const _0x4edf14=_0xaa668['element'];this['setEditableElement'](_0xaa668['name'],_0x4edf14),_0x572c6d['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x3a6bff['attachDomRoot'](_0x4edf14),this['_elementReplacer']['replace'](_0x1fb5c4,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x20d2c5=this['view'],_0x5d89a6=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x5d89a6['detachDomRoot'](_0x20d2c5['editable']['name']),_0x20d2c5['destroy']();}['_initToolbar'](){const _0x36236d=this['view'];_0x36236d['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x36236d['stickyPanel']['limiterElement']=_0x36236d['element'],_0x36236d['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x241712})=>_0x241712),_0x36236d['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x36236d['toolbar']);}}class Z extends _0xaa43ba{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x42ee57,_0x591d29,_0x2c1ff5={}){super(_0x42ee57),this['stickyPanel']=new _0x48a15c(_0x42ee57),this['toolbar']=new _0x2b9f1b(_0x42ee57,{'shouldGroupWhenFull':_0x2c1ff5['shouldToolbarGroupWhenFull']}),this['_editable']=new te(_0x42ee57,_0x591d29);}['render'](){super['render'](),this['stickyPanel']['content']['add'](this['toolbar']),this['top']['add'](this['stickyPanel']),this['main']['add'](this['editable']);}}class f extends/* #__PURE__ -- @preserve */
30
+ _0x14531e(_0x2daf9f){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x140fb9,_0x4100cd){super(_0x4100cd),this['sourceElement']=_0x140fb9,this['model']['document']['createRoot']();const _0x6d6569=new Z(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new Y(this,_0x6d6569);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x72d515,_0x38b497){const _0x2df430=new this(_0x72d515,_0x38b497);return await _0x2df430['initPlugins'](),await _0x2df430['ui']['init'](_0x72d515),await _0x2df430['data']['init'](_0x2df430['config']['get']('initialData')||''),_0x2df430['fire']('ready'),_0x2df430;}}const p=['RevisionHistoryUI','RestrictedEditingMode','AIChat','AIReviewMode','AIBalloon','AIQuickActions','AIActions','AIChatShortcuts','AITranslate'];class RevisionViewerIntegration extends _0x5ac587{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x3067fb){function _0x540395(_0x2f05c0){return _0x2f05c0['map'](_0x31ab71=>String['fromCharCode'](_0x31ab71))['join']('');}super(_0x3067fb),this['result']='end',_0x3067fb[_0x540395([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x540395([0x76,0x69,0x65,0x77])][_0x540395([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x540395([0x61,0x75,0x74,0x6f]),_0x3067fb[_0x540395([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x540395([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x540395([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x540395([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x540395([0x6f,0x6b])});}}class RevisionHistory extends _0x5ac587{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h,l];}constructor(_0x16c2ab){if(super(_0x16c2ab),!this['editor']['config']['get']('revisionHistory'))throw new _0x49908e('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x3e1459=>this['_showRevisionViewer']({..._0x3e1459,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x302764=>this['_closeRevisionViewer'](_0x302764)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x541085=>this['_restoreRevision'](_0x541085)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x1ab2a6){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x1ab2a6;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x5bf19b){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x5bf19b);}['getRevision'](_0x4431b6){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x4431b6);}['getRevisions'](_0x2e6e28){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x2e6e28||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x7df6d5=this['editor'],_0x5b422e=_0x5d6dc8(_0x7df6d5,p),_0x261758=_0x7df6d5['plugins']['get']('RevisionTracker'),_0x5b1ace=_0x7df6d5['plugins']['get']('Users')['users'];return _0x5b422e['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x5b422e['lazyRoots'],(_0x5b422e['plugins']['push'](RevisionViewerIntegration,u,v,class RevisionViewerInit extends _0x5ac587{static get['requires'](){return[u,'Users'];}['init'](){const _0x35d4a6=this['editor']['plugins']['get']('Users');for(const _0x2ed163 of _0x5b1ace)_0x2ed163['isAnonymous']||_0x35d4a6['getUser'](_0x2ed163['id'])||_0x35d4a6['addUser'](_0x2ed163);const _0x4c6ecb=_0x261758['repository']['getRevisions']();let _0x4e168b=null;const _0x40f6a7=this['editor']['plugins']['get']('RevisionViewer');_0x40f6a7['adapter']=_0x261758['adapter'],_0x40f6a7['bind']('isEnabled')['to'](_0x261758),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x7df6d5,'isReadOnly',_0x2b60e9=>!_0x2b60e9);for(const _0x1be185 of _0x4c6ecb){const _0x1997bf=null===_0x1be185['creator'];if(_0x1997bf&&_0x1be185['toVersion']===_0x1be185['fromVersion'])continue;const _0xefbff7=_0x1be185['toJSON']();_0x40f6a7['addRevisionData'](_0xefbff7,(_0x212125,_0x3fa893,_0x115c32)=>{if(_0x1997bf){if(_0x4e168b)_0x4e168b['_update'](_0x212125,_0x3fa893);else{if(!_0x3fa893){const _0x4a3380=_0x115c32['toJSON']();_0x4a3380['id']=_0x8d6220(),_0x261758['saveRevision'](_0x4a3380,_0x115c32['toVersion'])['then'](_0x5be1aa=>{_0x4e168b=_0x5be1aa;});}}}else _0x1be185['_update'](_0x212125,_0x3fa893);});}}},d),_0x5b422e);}['_enhanceShowRevisionViewerCallback'](){const _0x5e45ec=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x3751e4=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x59454e=this['editor']['plugins']['get']('Autosave');await _0x59454e['save']();}else await _0x3751e4['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x3bfd95=this['editor']['plugins']['get']('Dialog');_0x3bfd95['isOpen']&&_0x3bfd95['hide']();}if(this['editor']['plugins']['has']('AITabs')){const _0x518633=this['editor']['plugins']['get']('AITabs')['view']['panelViews'];for(const _0x1108d9 of _0x518633)_0x1108d9['class']=_0x1108d9['class']?_0x1108d9['class']+'\x20ck-tab-panel_disabled':'ck-tab-panel_disabled';if(this['editor']['plugins']['has']('AIChat')){const _0x35d28d=document['querySelector']('.ck-ai-chat__prompt-input\x20.ck-textarea');_0x35d28d&&_0x35d28d['setAttribute']('tabindex','-1');}if(this['editor']['plugins']['has']('AIChatHistory')){const _0xfe3176=document['querySelector']('.ck-ai-chat-history\x20.ck-input');_0xfe3176&&_0xfe3176['setAttribute']('tabindex','-1');}}const _0x476a7f=this['_getRevisionViewerEditorConfig']();return _0x5e45ec(_0x476a7f)['then'](_0x4876ee=>{return(this['_viewerEditor']=_0x4876ee,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'),_0x4876ee);})['catch'](_0x103d6b=>(console['error'](_0x103d6b),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x49490e=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 _0x3b066b=this['editor']['plugins']['get']('AITabs')['view']['panelViews'];for(const _0x11dbbd of _0x3b066b)_0x11dbbd['class']='ck-tab-panel_disabled'===_0x11dbbd['class']?'':_0x11dbbd['class']['replace']('\x20ck-tab-panel_disabled','');if(this['editor']['plugins']['has']('AIChat')){const _0xaa2f94=document['querySelector']('.ck-ai-chat__prompt-input\x20.ck-textarea');_0xaa2f94&&_0xaa2f94['removeAttribute']('tabindex');}if(this['editor']['plugins']['has']('AIChatHistory')){const _0x841191=document['querySelector']('.ck-ai-chat-history\x20.ck-input');_0x841191&&_0x841191['removeAttribute']('tabindex');}}return this['_viewerEditor']['plugins']['get']('RevisionViewer')['_cleanUp'](),_0x49490e(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x41bbbc=this['editor']['plugins']['get']('Annotations');_0x41bbbc['refreshVisibility'](),_0x41bbbc['refreshPositioning']();}});});}['_showRevisionViewer'](_0x330c49){const _0x5737d2=this['editor']['config']['get']('revisionHistory.editorContainer'),_0xb393f1=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x482817=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return f['create'](_0x482817,_0x330c49)['then'](_0x4fe4f2=>(_0xb393f1['style']['display']='block',_0x5737d2['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x4fe4f2));}['_closeRevisionViewer'](_0x29da3f){const _0x30ef07=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x30ef07['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x29da3f['destroy']();}async['_restoreRevision'](_0x3ac97f){const _0x11873f=this['editor'],_0x3871fd=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x158ce2=_0x11873f['plugins']['get']('RevisionTracker'),_0x131650=_0x11873f['plugins']['get']('RevisionHistoryUtils'),_0x5d02a0=_0x3871fd['repository']['getRevision'](_0x3ac97f);let _0x1a8d7e,_0x5204a5,_0x45af7c;try{await _0x131650['loadRevisionData'](_0x5d02a0,this['adapter']),_0x1a8d7e=_0x131650['getRevisionDocumentData'](_0x5d02a0),_0x5204a5=_0x131650['getRevisionRootsAttributes'](_0x5d02a0);}catch(_0x47a9b7){return void console['error'](_0x47a9b7);}_0x11873f['model']['change'](_0x42538d=>{for(const _0x2d6067 of Array['from'](_0x11873f['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x42538d['removeMarker'](_0x2d6067);}),_0x3871fd['isReady']=!0x1,_0x11873f['model']['enqueueChange'](_0x94261e=>{_0x94261e['setSelection'](null),_0x94261e['removeSelectionAttribute'](_0x11873f['model']['document']['selection']['getAttributeKeys']());const _0x575f89=Object['keys'](_0x1a8d7e);for(const _0x4a1747 of _0x11873f['model']['document']['roots'])'$graveyard'!=_0x4a1747['rootName']&&_0x4a1747['isAttached']()&&!_0x575f89['includes'](_0x4a1747['rootName'])&&_0x94261e['detachRoot'](_0x4a1747);for(const _0x5cee67 of _0x575f89){let _0x327df3=_0x11873f['model']['document']['getRoot'](_0x5cee67);_0x327df3&&_0x327df3['isAttached']()||(_0x327df3=_0x94261e['addRoot'](_0x5cee67));const _0x2aa642=_0x5204a5[_0x5cee67],_0x1ff3de=Object['keys'](_0x2aa642),_0x540e27=_0x1a8d7e[_0x5cee67];for(const _0x415296 of _0x327df3['getAttributeKeys']())_0x1ff3de['includes'](_0x415296)||_0x94261e['removeAttribute'](_0x415296,_0x327df3);for(const _0xe2fac0 of _0x1ff3de)_0x94261e['setAttribute'](_0xe2fac0,_0x5204a5[_0x5cee67][_0xe2fac0],_0x327df3);_0x94261e['remove'](_0x94261e['createRangeIn'](_0x327df3)),_0x94261e['insert'](_0x11873f['data']['parse'](_0x540e27,_0x327df3),_0x327df3,0x0);}});const _0x233b03=m(_0x11873f['locale'],'Restored');if(_0x5d02a0['name'])_0x45af7c=-0x1==_0x5d02a0['name']['indexOf'](_0x233b03)?_0x233b03+':\x20'+_0x5d02a0['name']:_0x5d02a0['name'];else _0x45af7c=_0x233b03+':\x20'+(_0x5d02a0['createdAt']['toLocaleDateString'](_0x11873f['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x5d02a0['createdAt']['toLocaleTimeString'](_0x11873f['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x158ce2['saveRevision']({'name':_0x45af7c}),_0x3871fd['isReady']=!0x0,_0x11873f['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{RestoreRevisionCommand,I as Revision,RevisionHistory,l as RevisionHistoryUI,$ as RevisionHistoryUtils,h as RevisionTracker,u as RevisionViewer,f as RevisionViewerEditor,RevisionViewerIntegration,fi as RevisionViewerLoadingOverlay,v as RevisionViewerUI,S as RevisionsRepository,d as RevisionsSidebar,ShowChangeCommand};