@ckeditor/ckeditor5-revision-history 0.0.0-nightly-20250615.0 → 0.0.0-nightly-20250617.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (182) 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 +11 -11
  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.d.ts +2 -2
  157. package/src/revisiondiff.js +1 -1
  158. package/src/revisionhistory.js +1 -1
  159. package/src/revisionhistoryutils.js +1 -1
  160. package/src/revisionsrepository.js +1 -1
  161. package/src/revisiontracker.d.ts +1 -1
  162. package/src/revisiontracker.js +1 -1
  163. package/src/revisionviewer.js +1 -1
  164. package/src/ui/revision/createrevisionactionsdropdown.js +1 -1
  165. package/src/ui/revision/revisionauthorview.js +1 -1
  166. package/src/ui/revision/revisionnameview.js +1 -1
  167. package/src/ui/revision/revisionview.js +2 -2
  168. package/src/ui/revision/subrevisioncollapserview.js +1 -1
  169. package/src/ui/revision/subrevisionview.js +1 -1
  170. package/src/ui/revision/utils.js +1 -1
  171. package/src/ui/revisionhistory/revisionhistorysaverevisionformview.js +2 -2
  172. package/src/ui/revisionhistory/revisionhistoryui.js +1 -1
  173. package/src/ui/revisionssidebar/revisionssidebar.js +1 -1
  174. package/src/ui/revisionssidebar/revisionssidebarheaderview.js +1 -1
  175. package/src/ui/revisionssidebar/revisionssidebartimeperiodview.js +1 -1
  176. package/src/ui/revisionssidebar/revisionssidebarview.js +1 -1
  177. package/src/ui/revisionssidebar/utils.js +1 -1
  178. package/src/ui/revisionviewer/changedetailsview.js +1 -1
  179. package/src/ui/revisionviewer/changesnavigationview.js +1 -1
  180. package/src/ui/revisionviewer/revisionviewerloadingoverlay.js +1 -1
  181. package/src/ui/revisionviewer/revisionviewerui.js +1 -1
  182. 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 _0x5629d1,uid as _0x582bfa,Collection as _0x5351d9,logWarning as _0x21fa3f,FocusTracker as _0x395cd5,KeystrokeHandler as _0xec8ea2,scrollViewportToShowTarget as _0xe286a,ResizeObserver as ot,ElementReplacer as it,CKEditorError as _0x10ec0c}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x5bd50a,set as _0xb3f645,unset as _0x231146,isEqual as _0x1cf957}from'es-toolkit/compat';import{Plugin as _0x49c0fc,PendingActions as _0x9fd341,Command as _0x52166d,ElementApiMixin as _0x12e486,Editor as _0x4072d7}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x55d287,getMarkerDomElement as _0x455182,ConfirmMixin as _0x43c7e1,sanitizeEditorConfig as _0x100442}from'ckeditor5-collaboration/dist/index.js';import{ViewContainerElement as _0x49a4e7,ViewAttributeElement as _0x31ccdf,ViewEmptyElement as _0x58a7b2,ViewRawElement as _0x4ba155,ViewUIElement as _0x1ef793,ViewDocumentFragment as _0x4da5c5,ViewText as _0x215957,ViewElement as _0x274f6f,Element as nt,Range as rt,Position as at,DocumentFragment as ht,Text as ct}from'@ckeditor/ckeditor5-engine/dist/index.js';import{IconHistory as _0x4269eb,IconChevronUp as _0x1bcada,IconChevronDown as _0x32e08a,IconUndo as _0x408ae0,IconUser as _0x1d5032,IconThreeVerticalDots as _0x503d3e}from'@ckeditor/ckeditor5-icons/dist/index.js';import{CssTransitionDisablerMixin as _0x129d59,View as _0x52b0b2,submitHandler as _0x5da359,LabeledFieldView as et,createLabeledInputText as ti,createDropdown as _0x4933a7,ListView as _0x3fdd7d,ListItemView as _0x5ebb18,ButtonView as _0x3c378a,MenuBarMenuView as _0x517f02,MenuBarMenuListView as _0x3c4af2,MenuBarMenuListItemView as _0x286350,MenuBarMenuListItemButtonView as _0x3c827c,ContextualBalloon as _0x441216,ToolbarSeparatorView as _0x34c55a,IconView as _0xc5dda1,addListToDropdown as _0x3686ed,UIModel as to,EditorUI as tt,normalizeToolbarConfig as st,BoxedEditorUIView as _0x1f2958,StickyPanelView as _0x2ec8f1,ToolbarView as _0x42bc33,InlineEditableUIView as te}from'@ckeditor/ckeditor5-ui/dist/index.js';import{DateTime as _0x3dd3d2}from'luxon';class I extends/* #__PURE__ -- @preserve */
24
- _0x5629d1(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x5d32e3){super(),this['id']=_0x5d32e3['id']||_0x582bfa(),this['creator']=_0x5d32e3['creator']||null,this['authors']=_0x5d32e3['authors']||[],this['diffData']=_0x5d32e3['diffData']||null,this['toVersion']=_0x5d32e3['toVersion']||0x0,this['fromVersion']=_0x5d32e3['fromVersion']||0x0,this['set']('name',_0x5d32e3['name']||''),this['set']('createdAt',_0x5d32e3['createdAt']||new Date()),this['set']('attributes',_0x5d32e3['attributes']||{});}['setName'](_0x5ddb62){this['_update']({'name':_0x5ddb62});}['setAttribute'](_0x47302b,_0x31da46){const _0x3cc491=_0x5bd50a(this['attributes']);_0xb3f645(_0x3cc491,_0x47302b,_0x31da46),this['_update']({'attributes':_0x3cc491});}['removeAttribute'](_0x448a82){const _0x2ae7c1=_0x5bd50a(this['attributes']);_0x231146(_0x2ae7c1,_0x448a82),this['_update']({'attributes':_0x2ae7c1});}['_update'](_0x30f804,_0x1c8322=!0x1){let _0x35d4a4=!0x1;const _0x5e38c3={'id':this['id']},_0x31fdf5=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x4ac3f1 of _0x31fdf5){const _0x3fa43a=_0x30f804[_0x4ac3f1];void 0x0!==_0x3fa43a&&_0x3fa43a!==this[_0x4ac3f1]&&(this[_0x4ac3f1]=_0x3fa43a,_0x5e38c3[_0x4ac3f1]=_0x3fa43a,_0x35d4a4=!0x0);}_0x35d4a4&&(_0x5e38c3['authors']&&(_0x5e38c3['authorsIds']=_0x5e38c3['authors']['map'](_0x5ad16d=>_0x5ad16d['id']),delete _0x5e38c3['authors']),this['fire']('_update',_0x5e38c3,_0x1c8322));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x518d31=>_0x518d31['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class S extends _0x49c0fc{['_revisions'];static get['requires'](){return[_0x55d287];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x1e305e){super(_0x1e305e),this['_revisions']=new _0x5351d9();}['afterInit'](){!async function(_0x41a107){const _0x1b2a77=_0x5709f9([0x6f,0x51,0x62,0x77,0x34,0x6d,0x4a,0x46,0x36,0x42,0x6c,0x53,0x50,0x39,0x45,0x41,0x31,0x55,0x70,0x4c,0x63,0x7a,0x33,0x32,0x57,0x47,0x73,0x61,0x6e,0x37,0x72,0x49,0x43,0x65,0x76,0x4e,0x71,0x64,0x4b,0x30,0x5a,0x6b,0x75,0x4f,0x68,0x59,0x4d,0x35,0x48,0x79,0x52,0x74,0x78,0x66,0x54,0x56,0x69,0x44,0x38,0x67,0x58,0x6a]),_0x5135f6=0xeb829,_0x5df872=0x52529800,_0x38c861=0x5255f2d0^_0x5df872,_0x461d87=window[_0x5709f9([0x44,0x61,0x74,0x65])][_0x5709f9([0x6e,0x6f,0x77])](),_0x11fb7f=_0x41a107[_0x5709f9([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x247d0e=new window[(_0x5709f9([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x14b777=>{_0x11fb7f[_0x5709f9([0x6f,0x6e,0x63,0x65])](_0x5709f9([0x72,0x65,0x61,0x64,0x79]),_0x14b777);}),_0x55ee75={[_0x5709f9([0x6b,0x74,0x79])]:_0x5709f9([0x45,0x43]),[_0x5709f9([0x75,0x73,0x65])]:_0x5709f9([0x73,0x69,0x67]),[_0x5709f9([0x63,0x72,0x76])]:_0x5709f9([0x50,0x2d,0x32,0x35,0x36]),[_0x5709f9([0x78])]:_0x5709f9([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]),[_0x5709f9([0x79])]:_0x5709f9([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]),[_0x5709f9([0x61,0x6c,0x67])]:_0x5709f9([0x45,0x53,0x32,0x35,0x36])},_0xdde362=_0x11fb7f[_0x5709f9([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x5709f9([0x67,0x65,0x74])](_0x5709f9([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x31c4a9(){let _0x33f04c,_0x205e00=null,_0x32ad26=null;try{if(_0xdde362==_0x5709f9([0x47,0x50,0x4c]))return _0x5709f9([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x33f04c=_0x54b342(),!_0x33f04c)return _0x5709f9([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x33f04c[_0x5709f9([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x32ad26=_0x4f9c01(_0x33f04c[_0x5709f9([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x33f04c[_0x5709f9([0x6a,0x74,0x69])])),await _0x4c696e()?_0x5afcb0()?_0x4b28b1()?_0x5709f9([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x2a1a9a()?(_0x33f04c[_0x5709f9([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x5709f9([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x205e00=_0x416b18(_0x5709f9([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x33f04c[_0x5709f9([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x5709f9([0x74,0x72,0x69,0x61,0x6c])&&(_0x205e00=_0x416b18(_0x5709f9([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x4f8502()):_0x5709f9([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x5709f9([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x5709f9([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x5709f9([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x4b28b1(){const _0x294eb3=[_0x5709f9([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x5709f9([0x74,0x72,0x69,0x61,0x6c])][_0x5709f9([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x33f04c[_0x5709f9([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x461d87/0x3e8:0xe10*_0x38c861;return _0x33f04c[_0x5709f9([0x65,0x78,0x70])]<_0x294eb3;}function _0x5afcb0(){const _0x5bb4c2=_0x33f04c[_0x5709f9([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x5bb4c2)return!0x1;if(_0x5bb4c2[_0x5709f9([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x5709f9([0x2a])))return!0x0;if(_0x5bb4c2[_0x5709f9([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x5709f9([0x52,0x48])))return!0x0;if(_0x5bb4c2[_0x5709f9([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x5709f9([0x52,0x52,0x48]))){if(_0x34de27())return!0x0;if(_0x5bc240()||_0x4fae09())return!0x0;}return!0x1;}function _0x2a1a9a(){const _0xf064d5=_0x33f04c[_0x5709f9([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0xf064d5||0x0==_0xf064d5[_0x5709f9([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x424051}=new URL(window[_0x5709f9([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0xf064d5[_0x5709f9([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x424051))return!0x0;const _0x48a19e=_0x424051[_0x5709f9([0x73,0x70,0x6c,0x69,0x74])](_0x5709f9([0x2e]));return _0xf064d5[_0x5709f9([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x2d6a0b=>_0x2d6a0b[_0x5709f9([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x5709f9([0x2a])))[_0x5709f9([0x6d,0x61,0x70])](_0x349e0c=>_0x349e0c[_0x5709f9([0x73,0x70,0x6c,0x69,0x74])](_0x5709f9([0x2e])))[_0x5709f9([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x116c65=>_0x116c65[_0x5709f9([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x48a19e[_0x5709f9([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x5709f9([0x6d,0x61,0x70])](_0x56348d=>Array(_0x48a19e[_0x5709f9([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0x56348d[_0x5709f9([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x5709f9([0x66,0x69,0x6c,0x6c])](_0x56348d[0x0]===_0x5709f9([0x2a])?_0x5709f9([0x2a]):'')[_0x5709f9([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0x56348d))[_0x5709f9([0x73,0x6f,0x6d,0x65])](_0x24e184=>_0x48a19e[_0x5709f9([0x65,0x76,0x65,0x72,0x79])]((_0x34c759,_0x4c5c2a)=>_0x24e184[_0x4c5c2a]===_0x34c759||_0x24e184[_0x4c5c2a]===_0x5709f9([0x2a])));}function _0x4f8502(){return _0x205e00&&_0x32ad26?new window[(_0x5709f9([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x5bcad9,_0x24d2bd)=>{_0x205e00[_0x5709f9([0x74,0x68,0x65,0x6e])](_0x5bcad9,_0x24d2bd),_0x32ad26[_0x5709f9([0x74,0x68,0x65,0x6e])](_0x271e44=>{_0x271e44!=_0x5709f9([0x56,0x61,0x6c,0x69,0x64])&&_0x5bcad9(_0x271e44);},_0x24d2bd);}):_0x205e00||_0x32ad26||_0x5709f9([0x56,0x61,0x6c,0x69,0x64]);}}function _0x4f9c01(_0xe1d5f0,_0x543255){return new window[(_0x5709f9([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x4f4ba9=>{if(_0x2acce2())return _0x4f4ba9(_0x5709f9([0x56,0x61,0x6c,0x69,0x64]));_0x149947(),_0x11fb7f[_0x5709f9([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x5709f9([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x2fc894=!0x1;const _0x50f657=_0x582bfa();function _0x5721eb(_0x1bb87a){return!!_0x1bb87a&&(typeof _0x1bb87a===_0x5709f9([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x1bb87a===_0x5709f9([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x1bb87a[_0x5709f9([0x74,0x68,0x65,0x6e])]===_0x5709f9([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x1bb87a[_0x5709f9([0x63,0x61,0x74,0x63,0x68])]===_0x5709f9([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x474fe8(_0x3f349b){_0x1b6ea9(_0x3f349b)[_0x5709f9([0x74,0x68,0x65,0x6e])](_0x51544d=>{if(!_0x51544d||_0x51544d[_0x5709f9([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x5709f9([0x6f,0x6b]))return _0x5709f9([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x455a69(_0x177f54(_0x50f657+_0x543255))!=_0x51544d[_0x5709f9([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x5709f9([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x5709f9([0x56,0x61,0x6c,0x69,0x64]);})[_0x5709f9([0x74,0x68,0x65,0x6e])](_0x2b00e2=>(_0xdf6f03(),_0x2b00e2),()=>{const _0xd2738b=_0x5dac53();return null==_0xd2738b?(_0xdf6f03(),_0x5709f9([0x56,0x61,0x6c,0x69,0x64])):_0x5709f9(_0x461d87-_0xd2738b>(0x765e1c00^_0x5df872)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x5709f9([0x74,0x68,0x65,0x6e])](_0x4f4ba9)[_0x5709f9([0x63,0x61,0x74,0x63,0x68])](()=>{_0x4f4ba9(_0x5709f9([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x4ad8c4=0x52647680^_0x5df872;function _0xdf6f03(){const _0x1aecc2=_0x5709f9([0x6c,0x6c,0x63,0x74,0x2d])+_0x455a69(_0x177f54(_0xe1d5f0)),_0xb015f4=_0x51062f(_0x455a69(window[_0x5709f9([0x4d,0x61,0x74,0x68])][_0x5709f9([0x63,0x65,0x69,0x6c])](_0x461d87/_0x4ad8c4)));window[_0x5709f9([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x5709f9([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x1aecc2,_0xb015f4);}function _0x5dac53(){const _0x55ae94=_0x5709f9([0x6c,0x6c,0x63,0x74,0x2d])+_0x455a69(_0x177f54(_0xe1d5f0)),_0x2f7055=window[_0x5709f9([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x5709f9([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x55ae94);return _0x2f7055?window[_0x5709f9([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x51062f(_0x2f7055),0x10)*_0x4ad8c4:null;}function _0x1b6ea9(_0x14c2ab){return new window[(_0x5709f9([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x1d0062,_0x1eb8f0)=>{_0x14c2ab[_0x5709f9([0x74,0x68,0x65,0x6e])](_0x1d0062,_0x1eb8f0),window[_0x5709f9([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x1eb8f0,0x52534cc0^_0x5df872);});}}_0x11fb7f[_0x5709f9([0x6f,0x6e])](_0x5709f9([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x1d06a5,_0x3747e0)=>{if(_0x3747e0[0x0]!=_0xe1d5f0)return _0x4f4ba9(_0x5709f9([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x3747e0[0x1]={..._0x3747e0[0x1],[_0x5709f9([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x50f657};},{[_0x5709f9([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x5709f9([0x68,0x69,0x67,0x68])}),_0x11fb7f[_0x5709f9([0x6f,0x6e])](_0x5709f9([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x560da0=>{_0x5721eb(_0x560da0[_0x5709f9([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x2fc894=!0x0,_0x474fe8(_0x560da0[_0x5709f9([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x5709f9([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x5709f9([0x6c,0x6f,0x77])}),_0x247d0e[_0x5709f9([0x74,0x68,0x65,0x6e])](()=>{_0x2fc894||_0x4f4ba9(_0x5709f9([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x2acce2(){return _0x11fb7f[_0x5709f9([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x5709f9([0x76,0x69,0x65,0x77])][_0x5709f9([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x5709f9([0x61,0x75,0x74,0x6f]);}function _0x149947(){_0x11fb7f[_0x5709f9([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x5709f9([0x76,0x69,0x65,0x77])][_0x5709f9([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x5709f9([0x61,0x75,0x74,0x6f]);}}function _0x416b18(_0x2376c8){const _0x3f0961=[new window[(_0x5709f9([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x24d1f9=>setTimeout(_0x24d1f9,0x525ba6cc^_0x5df872)),_0x247d0e[_0x5709f9([0x74,0x68,0x65,0x6e])](()=>new window[(_0x5709f9([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x3f8b33=>{const _0x1d0288=0x52529807^_0x5df872,_0x3826e4=_0x41a107[_0x5709f9([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x48f72a(){_0x3826e4[_0x5709f9([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x1d0288&&_0x3f8b33();}_0x48f72a(),_0x3826e4[_0x5709f9([0x6f,0x6e])](_0x5709f9([0x61,0x64,0x64]),_0x48f72a);})),new window[(_0x5709f9([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x521a9f=>{function _0x3309be(){for(const _0x9127c0 in window)if(window[_0x5709f9([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x5709f9([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x9127c0))&&window[_0x9127c0]==_0x5135f6)return _0x521a9f();_0x11fb7f[_0x5709f9([0x73,0x74,0x61,0x74,0x65])]!=_0x5709f9([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x5709f9([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x3309be,0x52528b88^_0x5df872);}_0x52bb3d(_0x5709f9([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x3309be();})];return window[_0x5709f9([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x5709f9([0x72,0x61,0x63,0x65])](_0x3f0961)[_0x5709f9([0x74,0x68,0x65,0x6e])](()=>_0x2376c8);}async function _0xeaa60b(){if(await _0x247d0e,_0x52bb3d(_0x5709f9([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x5d821e=_0x41a107[_0x5709f9([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x6eab92=_0x41a107[_0x5709f9([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])](_0x5d821e[_0x5709f9([0x69,0x64])]),_0xf3138d=_0xca50ca(_0x5709f9([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0xf3138d[_0x5709f9([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x5d821e['id'],_0x6eab92?_0x6eab92['id']:null,!0x0),_0xf3138d[_0x5709f9([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x5709f9([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0xf3138d[_0x5709f9([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0xf3138d[_0x5709f9([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x20d552,void(_0xf3138d[_0x5709f9([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x20d552);}if(_0x52bb3d(_0x5709f9([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x4ea9bd=_0xca50ca(_0x5709f9([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x4ea9bd[_0x5709f9([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x5709f9([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x4ea9bd[_0x5709f9([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x4ea9bd[_0x5709f9([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x20d552,_0x4ea9bd[_0x5709f9([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x20d552;}_0x11fb7f[_0x5709f9([0x6d,0x6f,0x64,0x65,0x6c])][_0x5709f9([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x20d552,_0x11fb7f[_0x5709f9([0x6d,0x6f,0x64,0x65,0x6c])][_0x5709f9([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x20d552,_0x11fb7f[_0x5709f9([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x5709f9([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x34de27(){return _0x52bb3d(_0x5709f9([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0xca50ca(_0x5709f9([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x5709f9([0x73,0x74,0x61,0x74,0x65])]==_0x5709f9([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x5bc240(){return _0x52bb3d(_0x5709f9([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 _0x4fae09(){return _0x52bb3d(_0x5709f9([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x52039c(_0xedbf28){const _0x3ea9de=_0x14b6db();_0x11fb7f[_0x3ea9de]=_0x5709f9([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])+_0xedbf28,_0xedbf28[_0x5709f9([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x5709f9([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x14b6db()]=_0x5135f6),_0xedbf28!=_0x5709f9([0x56,0x61,0x6c,0x69,0x64])&&_0xeaa60b();}function _0x14b6db(){const _0x2dc424=window[_0x5709f9([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x5709f9([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x5709f9([0x6e,0x6f,0x77])]())[_0x5709f9([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x5709f9([0x2e]),'');let _0x1716cd=_0x5709f9([0x6f]);for(let _0x4d84a3=0x0;_0x4d84a3<_0x2dc424[_0x5709f9([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x4d84a3+=0x2){let _0x1b1b67=window[_0x5709f9([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x2dc424[_0x5709f9([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x4d84a3,_0x4d84a3+0x2));_0x1b1b67>=_0x1b2a77[_0x5709f9([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x1b1b67-=_0x1b2a77[_0x5709f9([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x1716cd+=_0x1b2a77[_0x1b1b67];}return _0x1716cd;}function _0x54b342(){const _0x4a12a9=_0xdde362[_0x5709f9([0x73,0x70,0x6c,0x69,0x74])](_0x5709f9([0x2e]));if(0x3!=_0x4a12a9[_0x5709f9([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x171045(_0x4a12a9[0x1]);function _0x171045(_0xbaeb70){const _0x384013=_0x2ff87d(_0xbaeb70);return _0x384013&&_0x4692d0()?_0x384013:null;function _0x4692d0(){const _0x4a2a12=_0x384013[_0x5709f9([0x6a,0x74,0x69])],_0x24822f=window[_0x5709f9([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x4a2a12[_0x5709f9([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x4a2a12[_0x5709f9([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x27ad59={..._0x384013,[_0x5709f9([0x6a,0x74,0x69])]:_0x4a2a12[_0x5709f9([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x4a2a12[_0x5709f9([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x27ad59[_0x5709f9([0x76,0x63])],_0x177f54(_0x27ad59)==_0x24822f;}}}async function _0x4c696e(){let _0x51bad5=!0x0;try{const _0x407663=_0xdde362[_0x5709f9([0x73,0x70,0x6c,0x69,0x74])](_0x5709f9([0x2e])),[_0x12cf70,_0x407f4c,_0x1de17f]=_0x407663;return _0x3ca50e(_0x12cf70),await _0x3f7884(_0x12cf70,_0x407f4c,_0x1de17f),_0x51bad5;}catch{return!0x1;}function _0x3ca50e(_0x3c974a){const _0x35cbba=_0x2ff87d(_0x3c974a);_0x35cbba&&_0x35cbba[_0x5709f9([0x61,0x6c,0x67])]==_0x5709f9([0x45,0x53,0x32,0x35,0x36])||(_0x51bad5=!0x1);}async function _0x3f7884(_0x3c6bee,_0x5c5bbc,_0x290a87){const _0x461a2c=window[_0x5709f9([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x5709f9([0x66,0x72,0x6f,0x6d])](_0x4ee0b2(_0x290a87),_0x106c85=>_0x106c85[_0x5709f9([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x4d757a=new window[(_0x5709f9([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x5709f9([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x3c6bee+_0x5709f9([0x2e])+_0x5c5bbc),_0x56b853=window[_0x5709f9([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x5709f9([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x56b853)return;const _0x5edbf1=await _0x56b853[_0x5709f9([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x5709f9([0x6a,0x77,0x6b]),_0x55ee75,{[_0x5709f9([0x6e,0x61,0x6d,0x65])]:_0x5709f9([0x45,0x43,0x44,0x53,0x41]),[_0x5709f9([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x5709f9([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x5709f9([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x56b853[_0x5709f9([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x5709f9([0x6e,0x61,0x6d,0x65])]:_0x5709f9([0x45,0x43,0x44,0x53,0x41]),[_0x5709f9([0x68,0x61,0x73,0x68])]:{[_0x5709f9([0x6e,0x61,0x6d,0x65])]:_0x5709f9([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x5edbf1,_0x461a2c,_0x4d757a)||(_0x51bad5=!0x1);}}function _0x2ff87d(_0x5dd7bb){return _0x5dd7bb[_0x5709f9([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x5709f9([0x65,0x79]))?JSON[_0x5709f9([0x70,0x61,0x72,0x73,0x65])](_0x4ee0b2(_0x5dd7bb)):null;}function _0x4ee0b2(_0x2a8aa9){return window[_0x5709f9([0x61,0x74,0x6f,0x62])](_0x2a8aa9[_0x5709f9([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x5709f9([0x2b]))[_0x5709f9([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x5709f9([0x2f])));}function _0x177f54(_0x68f47a){let _0x17046a=0x1505;function _0x3d6f96(_0x3c12c2){for(let _0x1a7753=0x0;_0x1a7753<_0x3c12c2[_0x5709f9([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x1a7753++){const _0x33fe6a=_0x3c12c2[_0x5709f9([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x1a7753);_0x17046a=(_0x17046a<<0x5)+_0x17046a+_0x33fe6a,_0x17046a&=_0x17046a;}}function _0x11f8bf(_0xbf7b9a){Array[_0x5709f9([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0xbf7b9a)?_0xbf7b9a[_0x5709f9([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x11f8bf):_0xbf7b9a&&typeof _0xbf7b9a==_0x5709f9([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x5709f9([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0xbf7b9a)[_0x5709f9([0x73,0x6f,0x72,0x74])]()[_0x5709f9([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x3b5752,_0x17e983])=>{_0x3d6f96(_0x3b5752),_0x11f8bf(_0x17e983);}):_0x3d6f96(window[_0x5709f9([0x53,0x74,0x72,0x69,0x6e,0x67])](_0xbf7b9a));}return _0x11f8bf(_0x68f47a),_0x17046a>>>0x0;}function _0x455a69(_0x57ee76){return _0x57ee76[_0x5709f9([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x5709f9([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x5709f9([0x30]));}function _0x51062f(_0x250b60){return _0x250b60[_0x5709f9([0x73,0x70,0x6c,0x69,0x74])]('')[_0x5709f9([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x5709f9([0x6a,0x6f,0x69,0x6e])]('');}function _0x52bb3d(_0x39eaf8){return _0x11fb7f[_0x5709f9([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x5709f9([0x68,0x61,0x73])](_0x39eaf8);}function _0xca50ca(_0x5e94d8){return _0x11fb7f[_0x5709f9([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x5709f9([0x67,0x65,0x74])](_0x5e94d8);}function _0x20d552(){}function _0x5709f9(_0x3c376e){return _0x3c376e['map'](_0x50cdf6=>String['fromCharCode'](_0x50cdf6))['join']('');}_0x52039c(await _0x31c4a9());}(this);}['createRevision'](_0x1b298c){const _0x207a59=this['editor']['plugins']['get']('Users');return new I({'id':_0x1b298c['id'],'name':_0x1b298c['name'],'creator':_0x1b298c['creatorId']?_0x207a59['getUser'](_0x1b298c['creatorId']):null,'diffData':_0x1b298c['diffData']||_0x1b298c['data'],'authors':_0x1b298c['authorsIds']['map'](_0x39ff23=>_0x207a59['getUser'](_0x39ff23)),'createdAt':new Date(_0x1b298c['createdAt']),'attributes':_0x1b298c['attributes'],'fromVersion':_0x1b298c['fromVersion'],'toVersion':_0x1b298c['toVersion']});}['addRevision'](_0x25d9d0,_0x15e8dc=0x0){this['_revisions']['add'](_0x25d9d0,_0x15e8dc);}['getRevision'](_0x1bd64c){return this['_revisions']['get'](_0x1bd64c);}['getRevisions'](_0x1037dd={'toJSON':!0x1}){const _0x1737df=Array['from'](this['_revisions']);return _0x1737df['reverse'](),_0x1037dd['toJSON']?_0x1737df['map'](_0x4b359c=>_0x4b359c['toJSON']()):_0x1737df;}['getIndex'](_0x3ef66c){return this['_revisions']['getIndex'](_0x3ef66c);}['getEarlierVisibleRevision'](_0x29a416){const [,_0x4e9438]=this['getRevisionsIterator'](_0x29a416,{'direction':'earlier'});return _0x4e9438;}['getLaterVisibleRevision'](_0x52542f){const [,_0x189198]=this['getRevisionsIterator'](_0x52542f,{'direction':'later'});return _0x189198;}['getRevisionsInDiff'](_0x43e8ce){const _0x37378c=[];for(const _0x73fadb of this['getRevisionsIterator'](_0x43e8ce['newRevisionId']))if(_0x37378c['push'](_0x73fadb),_0x73fadb['id']===_0x43e8ce['oldRevisionId'])break;return _0x37378c;}*['getRevisionsIterator'](_0x554239,{direction:_0x372d89='earlier',filter:_0x533f38=()=>!0x0}={}){const _0x2685de='earlier'===_0x372d89?0x1:-0x1;let _0xc2d62a=this['_revisions']['get'](_0x554239),_0xf78192=this['getIndex'](_0xc2d62a);for(yield _0xc2d62a;_0xc2d62a;){if(_0xf78192+=_0x2685de,_0xc2d62a=this['getRevision'](_0xf78192),!_0xc2d62a)return;_0x533f38(_0xc2d62a)&&(yield _0xc2d62a);}}}class $ extends _0x49c0fc{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x49a4e7,'c'],[_0x31ccdf,'a'],[_0x58a7b2,'e'],[_0x4ba155,'r'],[_0x1ef793,'u']]);['_typeCharToViewClass']=new Map([['c',_0x49a4e7],['a',_0x31ccdf],['e',_0x58a7b2],['r',_0x4ba155],['u',_0x1ef793]]);async['loadRevisionData'](_0x4170a5,_0x1681d9){if(_0x4170a5['diffData']||!_0x1681d9)return;const _0x3cc34c=this['editor']['config']['get']('collaboration.channelId'),_0x527c2e=await _0x1681d9['getRevision']({'channelId':_0x3cc34c,'revisionId':_0x4170a5['id']});_0x4170a5['diffData']=_0x527c2e['diffData'];}['getRevisionDocumentData'](_0x38935b){const _0x4befd5={};for(const _0x2db0c4 in _0x38935b['diffData']){if(_0x38935b['diffData'][_0x2db0c4]['attachChange']&&!_0x38935b['diffData'][_0x2db0c4]['attachChange']['isAttached'])continue;const _0x5e14c6=this['_removeRevisionMarkers'](JSON['parse'](_0x38935b['diffData'][_0x2db0c4]['insertions'])),_0x1c9ea4=this['editor']['editing']['view']['document'],_0x460abf=new _0x4da5c5(_0x1c9ea4,_0x5e14c6['map'](_0x2677b2=>this['_getViewFromDiffObj'](_0x2677b2,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x4befd5[_0x2db0c4]=this['editor']['data']['processor']['toData'](_0x460abf),this['editor']['data']['processor']['useFillerType']('default');}return _0x4befd5;}['getRevisionRootsAttributes'](_0x55e7f3){const _0x54cf95={};for(const _0xff7a7e in _0x55e7f3['diffData'])_0x55e7f3['diffData'][_0xff7a7e]['attachChange']&&!_0x55e7f3['diffData'][_0xff7a7e]['attachChange']['isAttached']||(_0x54cf95[_0xff7a7e]=_0x55e7f3['diffData'][_0xff7a7e]['attributesAfter']||{});return _0x54cf95;}['_getTypeCharForViewElement'](_0x2b60bf){return this['_viewClassToTypeChar']['get'](_0x2b60bf['constructor']);}['_getViewFromDiffObj'](_0x3c3a5f,_0x2030d0){const _0x24b243=this['editor']['editing']['view']['document'];if('string'==typeof _0x3c3a5f)return new _0x215957(_0x24b243,_0x3c3a5f);{let _0x47263c,_0x53f997;_0x53f997='u'==_0x3c3a5f['type']||'r'==_0x3c3a5f['type']?[]:_0x3c3a5f['children']['map'](_0x2a69aa=>this['_getViewFromDiffObj'](_0x2a69aa,_0x2030d0));const _0x3ea701=this['_typeCharToViewClass']['get'](_0x3c3a5f['type'])||_0x274f6f,_0x415670=this['editor']['data']['htmlProcessor']['domConverter'];if(_0x47263c=new _0x3ea701(_0x24b243,_0x3c3a5f['name'],_0x3c3a5f['attributes'],_0x53f997),'u'==_0x3c3a5f['type']&&_0x3c3a5f['children'][0x0]){const _0x5338d7=_0x3c3a5f['children'][0x0];if(_0x47263c['render']=function(_0x36b994){const _0x35b69b=_0x36b994['createElement']('div');return _0x35b69b['innerHTML']=_0x5338d7,_0x35b69b['childNodes'][0x0];},_0x2030d0){const _0x418c42=new _0x4da5c5(_0x24b243);_0x418c42['_appendChild'](_0x47263c);const _0x5857c8=Array['from'](_0x415670['viewChildrenToDom'](_0x418c42,{'bind':!0x1})),_0x5b534e=_0x415670['domDocument']['createElement']('div');_0x5b534e['append'](..._0x5857c8),_0x47263c=Array['from'](_0x415670['domChildrenToView'](_0x5b534e))[0x0];}}else{if('r'==_0x3c3a5f['type']&&_0x3c3a5f['children'][0x0]){const _0x2a381e=_0x3c3a5f['children'][0x0];if(_0x47263c['render']=function(_0x103399){_0x103399['innerHTML']=_0x2a381e;},_0x2030d0){const _0x4191c2=new _0x4da5c5(_0x24b243);_0x4191c2['_appendChild'](_0x47263c);const _0x789e53=Array['from'](_0x415670['viewChildrenToDom'](_0x4191c2,{'bind':!0x1})),_0xea9e52=_0x415670['domDocument']['createElement']('div');_0xea9e52['append'](..._0x789e53);const _0x35d785=Array['from'](_0x415670['domChildrenToView'](_0xea9e52));_0x35d785['length']>0x1?_0x47263c['_appendChild'](_0x35d785):_0x47263c=_0x35d785[0x0];}}}if(_0x3c3a5f['customProperties']){for(const [_0x3b1bce,_0x409b92]of _0x3c3a5f['customProperties'])_0x47263c['_setCustomProperty'](_0x3b1bce,_0x409b92);}const _0x295d73=void 0x0===_0x3c3a5f['fillerOffset']?null:_0x3c3a5f['fillerOffset'];return null!==_0x295d73&&(_0x47263c['getFillerOffset']=()=>_0x295d73),_0x47263c;}}['_makeModelFromViewString'](_0x3338b5){const _0x110152=JSON['parse'](_0x3338b5),_0xf02035=this['editor']['editing']['view']['document'],_0x5c4203=new _0x4da5c5(_0xf02035,_0x110152['map'](_0x4bbbdf=>this['_getViewFromDiffObj'](_0x4bbbdf,!0x0)));return this['editor']['data']['toModel'](_0x5c4203);}['_removeRevisionMarkers'](_0x4b5d3e){return(_0x4b5d3e=_0x4b5d3e['filter'](_0x84970=>!_0x84970['name']||'revision-start'!==_0x84970['name']&&'revision-end'!==_0x84970['name']))['forEach'](_0x3a144c=>{'string'!=typeof _0x3a144c&&(_0x3a144c['children']=this['_removeRevisionMarkers'](_0x3a144c['children']),_0x3a144c['attributes']=_0x3a144c['attributes']['filter'](_0x58969f=>!_0x58969f[0x0]['startsWith']('data-revision-')));}),_0x4b5d3e;}}function R(_0x34bcbc,_0xc6e8b,_0x38feb2){const t=_0x34bcbc['t'];switch(_0xc6e8b){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'},_0x38feb2);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x38feb2);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 _0x49c0fc{['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[_0x55d287,S,$,_0x9fd341];}constructor(_0x5cdaf0){super(_0x5cdaf0),this['repository']=this['editor']['plugins']['get']('RevisionsRepository'),this['_utils']=this['editor']['plugins']['get']('RevisionHistoryUtils'),this['_revisionDataBuilder']=new K(this['editor']),this['_initialRevisionId']=this['editor']['config']['get']('collaboration.channelId')||'initial',this['_bufferedUpdates']=new Map(),this['_loadedStateData']=null;const _0x320fa2=_0x582bfa();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x320fa2},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 _0x38bd39=this['repository']['getRevision'](0x0),_0x37cdda=_0x38bd39&&null===_0x38bd39['creator']?_0x38bd39:null;if(this['_continueCurrentRevision']=!!_0x37cdda&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x34f661=this['_source']['getCurrentRevisionId'](),_0x49bc33=this['repository']['getRevision'](_0x34f661);if(_0x49bc33)this['_startingVersion']=_0x49bc33['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x4e639a=this['_source']['history']['_operations']['find'](_0x4f7428=>!_0x4f7428['_isInit']),_0x23d4e0=_0x4e639a?_0x4e639a['baseVersion']:this['_source']['history']['version'];_0x38bd39?(_0x38bd39['toVersion']<_0x23d4e0&&_0x38bd39['_update']({'toVersion':_0x23d4e0}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x37cdda['id'],this['_startingVersion']=_0x37cdda['fromVersion']):(this['_startingVersion']=_0x38bd39['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x23d4e0,this['_continueCurrentRevision']=!0x1);}}else _0x37cdda&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x37cdda['toVersion'],this['editor']['model']['document']['history']['version']),_0x37cdda['fromVersion']===_0x37cdda['toVersion']?(0x0!==_0x37cdda['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x37cdda['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x37cdda['id'],this['_startingVersion']=_0x37cdda['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',_0x464e43=>!_0x464e43),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x39ee1b=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x5cd089;for(const _0x122663 in _0x39ee1b){const _0x9e1337=_0x122663,_0x5c273e=_0x39ee1b[_0x9e1337];if('revisionHistoryLicenseKeyValid'==_0x5c273e||'revisionHistoryLicenseKeyInvalid'==_0x5c273e||'revisionHistoryLicenseKeyExpired'==_0x5c273e||'revisionHistoryLicenseKeyDomainLimit'==_0x5c273e||'revisionHistoryLicenseKeyNotAllowed'==_0x5c273e||'revisionHistoryLicenseKeyEvaluationLimit'==_0x5c273e||'revisionHistoryLicenseKeyTrialLimit'==_0x5c273e||'revisionHistoryLicenseKeyUsageLimit'==_0x5c273e){delete _0x39ee1b[_0x9e1337],_0x5cd089=_0x5c273e,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x5cd089&&_0x39ee1b['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x5cd089&&_0x39ee1b['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x5cd089&&_0x39ee1b['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x5cd089&&_0x39ee1b['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x5cd089&&_0x39ee1b['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x5cd089&&_0x39ee1b['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x5cd089&&_0x39ee1b['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x9ef8f1=this['repository']['getRevision'](0x0),_0x48090f=await this['getRevisionDocumentData'](_0x9ef8f1),_0x45feab=await this['getRevisionRootsAttributes'](_0x9ef8f1);this['_replaceEditorDataWithRevisionData'](_0x48090f,_0x45feab);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x335b62){this['_source']=_0x335b62;}async['update'](){const _0x3f3e30=await this['_source']['getLatestVersion']();if(_0x3f3e30>this['currentRevision']['toVersion']){await this['_loadState']();const _0x52915c=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x3f3e30});_0x52915c['authors']=_0x52915c['authorsIds']['map'](_0x261307=>this['editor']['plugins']['get']('Users')['getUser'](_0x261307)),this['currentRevision']['_update'](_0x52915c);}}async['saveRevision'](_0x4fecd2={},_0x3177f0=null){const _0x3be1bb=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x3177f0>this['currentRevision']['toVersion']&&(_0x3177f0=null),null===_0x3177f0&&(_0x3177f0=await this['_source']['getLatestVersion']());const _0x2951c9=this['_getFromVersion'](_0x3177f0),_0x97c1aa=this['buildRevisionData']({'from':_0x2951c9,'to':_0x3177f0});if(this['currentRevision']['toVersion']<_0x3177f0){const _0x789e34=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x3177f0,'to':_0x3177f0});_0x789e34['authors']=[],_0x789e34['authorsIds']=[],_0x789e34['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x789e34,!0x0),delete _0x789e34['authors'],_0x3be1bb['push'](_0x789e34);}_0x4fecd2['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x4fecd2['name']=_0x4fecd2['name']||null,_0x4fecd2['id']=_0x4fecd2['id']||_0x582bfa(),_0x4fecd2={..._0x4fecd2,..._0x97c1aa};const _0x5a7b29=this['addRevisionData'](_0x4fecd2);_0x3be1bb['push'](_0x4fecd2);const _0xe55d74=this['repository']['getIndex'](_0x5a7b29);if(0x0!==_0xe55d74){const _0x4e5110=this['repository']['getRevision'](_0xe55d74-0x1);if(_0x4e5110['fromVersion']!==_0x3177f0){const _0x13f22b=this['_revisionDataBuilder']['getData'](_0x3177f0,_0x4e5110['toVersion']),_0x51c810={'id':_0x4e5110['id'],'diffData':_0x13f22b['diffData'],'authorsIds':_0x13f22b['authorsIds'],'authors':_0x13f22b['authorsIds']['map'](_0x34122d=>this['editor']['plugins']['get']('Users')['getUser'](_0x34122d)),'fromVersion':_0x3177f0};_0x4e5110===this['currentRevision']&&(_0x51c810['createdAt']=new Date(_0x4fecd2['createdAt']['getTime']()+0xa)),_0x4e5110['_update'](_0x51c810,!0x0),delete _0x51c810['authors'],_0x3be1bb['push'](_0x51c810);}}if(this['adapter']){for(const _0x3c027c of _0x3be1bb)this['_bufferUpdate'](_0x3c027c['id'],_0x3c027c,!0x0);this['sendBufferedUpdates']();}return _0x5a7b29;}['addRevisionData'](_0x5083a3){const _0x46f8bc=this['repository']['createRevision'](_0x5083a3);return this['adapter']&&_0x46f8bc['on']('_update',(_0x29c6d4,_0x3cfd21,_0x4a6420)=>{_0x4a6420||(this['_bufferUpdate'](_0x3cfd21['id'],_0x3cfd21,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x46f8bc,this['_findInsertionIndex'](_0x46f8bc)),_0x46f8bc;}async['getRevisionDocumentData'](_0xac1689){return await this['_utils']['loadRevisionData'](_0xac1689,this['adapter']),this['_utils']['getRevisionDocumentData'](_0xac1689);}async['getRevisionRootsAttributes'](_0x15d6c6){return await this['_utils']['loadRevisionData'](_0x15d6c6,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x15d6c6);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x2b77cc=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x489319=0x0;_0x489319<_0x2b77cc['length'];_0x489319++){const _0x2ec330=_0x2b77cc[_0x489319];let _0x42637b=!0x1;for(const _0x37e605 of Object['keys'](_0x2ec330))void 0x0===_0x2ec330[_0x37e605]?delete _0x2ec330[_0x37e605]:'id'!==_0x37e605&&(_0x42637b=!0x0);_0x42637b||(_0x2b77cc[_0x489319]=null);}if(_0x2b77cc=_0x2b77cc['filter'](_0x3aeb78=>null!==_0x3aeb78),!_0x2b77cc['length'])return;for(let _0x4c0111=0x0;_0x4c0111<_0x2b77cc['length'];_0x4c0111++){const _0x125aa4=_0x2b77cc[_0x4c0111];void 0x0!==_0x125aa4['fromVersion']&&void 0x0===_0x125aa4['toVersion']&&(_0x125aa4['toVersion']=this['repository']['getRevision'](_0x125aa4['id'])['toVersion']),void 0x0!==_0x125aa4['toVersion']&&void 0x0===_0x125aa4['fromVersion']&&(_0x125aa4['fromVersion']=this['repository']['getRevision'](_0x125aa4['id'])['fromVersion']);}const _0xc14236=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x2b77cc,_0xc14236)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x521c27=>{if(_0x521c27){for(const _0x336241 of _0x521c27)this['setRevisionData']({'id':_0x336241['id'],'createdAt':_0x336241['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0xc7dae4=null,from:_0x469598=null,to:_0x3b33f8=null}){_0x469598=null!==_0x469598?_0x469598:_0xc7dae4['fromVersion'],_0x3b33f8=null!==_0x3b33f8?_0x3b33f8:_0xc7dae4['toVersion'];const _0x7aba9a=this['_revisionDataBuilder']['getData'](_0x469598,_0x3b33f8),_0x76429f={'diffData':_0x7aba9a['diffData'],'authorsIds':_0x7aba9a['authorsIds'],'fromVersion':_0x469598,'toVersion':_0x3b33f8};if(!_0xc7dae4||_0x3b33f8!==_0xc7dae4['toVersion']){const _0x2099e9=_0x3b33f8-0x1,_0x2a16fd=this['_source']['history']['getOperation'](_0x2099e9);_0x76429f['createdAt']=_0x2a16fd&&_0x2a16fd['createdAt']||new Date();}if(this['_loadedStateData']&&_0x469598===this['_loadedStateData']['fromVersion']){for(const _0x3d779b of this['_loadedStateData']['authors'])_0x76429f['authorsIds']['includes'](_0x3d779b['id'])||_0x76429f['authorsIds']['push'](_0x3d779b['id']);}return _0x76429f;}['_bufferUpdate'](_0xfd521f,_0x250624,_0x5b878e){if(this['_bufferedUpdates']['has'](_0xfd521f)){const _0x258680=this['_bufferedUpdates']['get'](_0xfd521f);_0x250624=_0x5b878e?{..._0x258680,..._0x250624}:{..._0x250624,..._0x258680};}this['_bufferedUpdates']['set'](_0xfd521f,_0x250624);}['setRevisionData'](_0x429106){const _0x517c09=this['repository']['getRevision'](_0x429106['id']);if(_0x429106['createdAt']&&(_0x429106['createdAt']=new Date(_0x429106['createdAt'])),_0x429106['authorsIds']){const _0x3e5820=this['editor']['plugins']['get']('Users');_0x429106['authors']=_0x429106['authorsIds']['map'](_0x47bf91=>_0x3e5820['getUser'](_0x47bf91));}_0x517c09['_update'](_0x429106,!0x0);}['_createInitialRevision'](_0x13eb6e){const _0x5c5dc6=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x5c5dc6)this['_initialRevisionId']=_0x5c5dc6['id'];else{const _0x1b5530=!this['editor']['model']['document']['roots']['find'](_0x4331d6=>this['editor']['model']['hasContent'](_0x4331d6)),_0x59635b=this['editor']['plugins']['get']('Users')['me']['id'],_0x22543a=R(this['editor']['locale'],_0x1b5530?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x13eb6e,'to':_0x13eb6e,'id':this['_initialRevisionId'],'name':_0x22543a,'creatorId':_0x59635b});}}['_createCurrentRevision'](_0x467615){const _0x50d5d5=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x50d5d5),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x467615,'to':_0x467615,'id':_0x50d5d5,'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'](_0x3fe725,_0x587627){let _0x4828a7=this['editor']['config']['get']('initialData'),_0xc28e55=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x4828a7){_0x4828a7={};for(const _0x5d47a7 of this['editor']['model']['document']['getRootNames']())_0x4828a7[_0x5d47a7]='';}if('string'==typeof _0x4828a7&&(_0x4828a7={'main':_0x4828a7}),void 0x0===_0xc28e55){_0xc28e55={};for(const _0x317bb1 of this['editor']['model']['document']['getRootNames']())_0xc28e55[_0x317bb1]={};}let _0x37c129=!0x1;const _0x4aab0c=Object['keys'](_0x4828a7),_0x1233f4=Object['keys'](_0x3fe725);for(const _0x39139e of _0x4aab0c){if(_0x4828a7[_0x39139e]!==_0x3fe725[_0x39139e]&&''!==_0x4828a7[_0x39139e]['trim']()){_0x37c129=!0x0;break;}if(!_0x1cf957(_0xc28e55[_0x39139e],_0x587627[_0x39139e])&&Object['keys'](_0xc28e55[_0x39139e])['length']>0x0){_0x37c129=!0x0;break;}}_0x37c129||(_0x37c129=_0x1233f4['some'](_0xdaeedd=>!this['editor']['model']['document']['getRoot'](_0xdaeedd))),_0x37c129&&_0x21fa3f('editor-initial-data-replaced-with-revision-data',{'editorData':_0x4828a7,'editorRootsAttributes':_0xc28e55,'revisionData':_0x3fe725,'revisionRootsAttributes':_0x587627}),this['editor']['config']['set']('initialData',_0x3fe725),this['editor']['config']['set']('rootsAttributes',_0x587627);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x5e1a52=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x5e1a52['add'](R(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x3cae70){const _0x1efce4=this['repository']['getRevisions']();_0x1efce4['reverse']();let _0x2e256f=0x0;for(;_0x2e256f<_0x1efce4['length'];){const _0x84c52b=_0x1efce4[_0x2e256f];if(_0x84c52b===this['currentRevision']){_0x2e256f++;continue;}if(_0x84c52b['id']===this['_initialRevisionId'])break;const _0x22cdea=_0x3cae70['toVersion']-_0x84c52b['toVersion']||_0x3cae70['fromVersion']-_0x84c52b['fromVersion'];if(_0x22cdea>0x0)break;if(_0x22cdea<0x0)_0x2e256f++;else{if(!_0x3cae70['creator']&&_0x84c52b['creator'])break;if(_0x84c52b['creator']||!_0x3cae70['creator']){if(_0x3cae70['createdAt']>_0x84c52b['createdAt'])break;_0x2e256f++;}else _0x2e256f++;}}return _0x2e256f;}['_getFromVersion'](_0x52eea3){const _0x56014a=this['repository']['getRevisions']();_0x56014a['reverse'](),_0x56014a['shift']();const _0x2ba585=_0x56014a['find'](_0x21ba38=>_0x21ba38['toVersion']<=_0x52eea3)['toVersion'];return _0x2ba585<this['_startingVersion']?this['_startingVersion']:_0x2ba585;}['_makeRevision']({name:_0x3f48ad,from:_0x965214,to:_0x161cc8,creatorId:_0x49f432,id:_0x5bac8a}){const _0x2dbcd7=this['buildRevisionData']({'from':_0x965214,'to':_0x161cc8});_0x2dbcd7['name']=_0x3f48ad,_0x2dbcd7['creatorId']=_0x49f432,_0x2dbcd7['id']=_0x5bac8a;const _0x4af694=this['addRevisionData'](_0x2dbcd7);return this['adapter']&&this['_bufferUpdate'](_0x2dbcd7['id'],_0x2dbcd7,!0x0),_0x4af694;}['_setConversion'](){this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'});}}class K{['editor'];['source'];['_savedMetaData'];['_lastFrom'];['_lastTo'];['_markers'];['_diffRoots'];['_diffRootsAttributes'];['_baseRoots'];['_baseRootsAttributes'];['_idsRoots'];['_baseIdsRoots'];['_touched'];['_touchedMarkers'];['_touchedRoots'];['_revisionId'];['_startingRevisionId'];constructor(_0x46840c){this['editor']=_0x46840c,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'](_0x1cd4bb){this['source']=_0x1cd4bb;const _0x2e34af=new Map(),_0x5ea521=new Map(),_0xc06ca3=this['editor']['model']['document']['roots']['map'](_0x2a5e04=>_0x2a5e04['rootName']);for(const _0x24d7c7 of _0xc06ca3){const _0x30c099=this['editor']['model']['document']['getRoot'](_0x24d7c7),_0x1c6eda=x(_0x30c099);_0x2e34af['set'](_0x24d7c7,_0x1c6eda),_0x5ea521['set'](_0x24d7c7,Object['fromEntries'](_0x30c099['getAttributes']()));}const _0x5b5e22=Array['from'](this['editor']['model']['markers'])['map'](_0x161edb=>[_0x161edb['name'],_0x161edb['getRange']()]),_0x21fd62=this['source']['version'];this['_saveMetaData'](_0x21fd62,_0x2e34af,_0x5b5e22,_0x5ea521),this['_startingRevisionId']=this['_revisionId'];const _0x5b0727=new Map(),_0x5213d0=new Map();for(const _0x58f120 of _0xc06ca3){const _0x3d2569=N(_0x58f120);_0x5b0727['set'](_0x58f120,_0x3d2569),_0x5213d0['set'](_0x58f120,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x5b0727,[],_0x5213d0);}['getData'](_0xb4eab1,_0x3452f0){if(this['_lastFrom']===_0xb4eab1&&this['_lastTo']<=_0x3452f0)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x3452f0,!0x0);else{if(!this['_savedMetaData']['has'](_0xb4eab1)){const _0x52b847=this['_getPreviousFrom'](_0xb4eab1);this['_calculateMetaData'](_0x52b847,_0xb4eab1,!0x1);}this['_calculateMetaData'](_0xb4eab1,_0x3452f0,!0x0);}return this['_lastFrom']=_0xb4eab1,this['_lastTo']=_0x3452f0,this['_getState']();}['loadState'](_0x1e635a){const _0x9cb59e=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x1e635a['fromVersion'],this['_lastTo']=_0x1e635a['toVersion'];for(const _0x49eba7 in _0x1e635a['diffData']){const _0x3b60ef=_0x1e635a['diffData'][_0x49eba7]['attachChange'],_0x526844=_0x5bd50a(_0x1e635a['diffData'][_0x49eba7]['attributesBefore'])||{},_0x4ee532=_0x9cb59e['_makeModelFromViewString'](_0x1e635a['diffData'][_0x49eba7]['deletions']);_0x4ee532['rootName']=_0x49eba7,_0x4ee532['_isAttached']=!_0x3b60ef||!_0x3b60ef['isAttached'],_0x4ee532['isAttached']=()=>_0x4ee532['_isAttached'],this['_baseRoots']['set'](_0x49eba7,_0x4ee532),this['_baseRootsAttributes']['set'](_0x49eba7,_0x526844),_0x3b60ef&&this['_touchedRoots']['set'](_0x49eba7,_0x3b60ef);const _0x7e6e82=this['_makeIdsRoot'](_0x4ee532);this['_baseIdsRoots']['set'](_0x49eba7,_0x7e6e82);for(const [_0x306688,_0x26ee13]of _0x4ee532['markers']){if(!_0x306688['startsWith']('revision:'))continue;const _0x69848f=_0x306688['split'](':')[0x2];for(const _0x1f5719 of _0x26ee13['getWalker']({'singleCharacters':!0x0})){const _0x773346=this['_getVidAttributeName'](_0x1f5719),_0x1b1548='elementEnd'==_0x1f5719['type']?_0x1f5719['previousPosition']['path']['slice'](0x0,-0x1):_0x1f5719['previousPosition']['path'],_0x354bcc=_0x7e6e82['getNodeByPath'](_0x1b1548)['getAttribute'](_0x773346);this['_touched']['set'](_0x354bcc,{'userId':_0x69848f});}}}this['_startingRevisionId']=this['_revisionId'];const _0x23e9f6=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x432e86=>!this['_touched']['has'](_0x432e86));let _0x150003=0x0;const _0x516b8d=new Map();for(const _0x26a608 in _0x1e635a['diffData']){const _0x13cb8b=_0x1e635a['diffData'][_0x26a608]['attachChange'],_0x424071=_0x5bd50a(_0x1e635a['diffData'][_0x26a608]['attributesAfter'])||{},_0x43bdc1=_0x9cb59e['_makeModelFromViewString'](_0x1e635a['diffData'][_0x26a608]['insertions']);_0x43bdc1['rootName']=_0x26a608,_0x43bdc1['_isAttached']=!_0x13cb8b||_0x13cb8b['isAttached'],_0x43bdc1['isAttached']=()=>_0x43bdc1['_isAttached'],this['_diffRoots']['set'](_0x26a608,_0x43bdc1),this['_diffRootsAttributes']['set'](_0x26a608,_0x424071);const _0x5d416c=this['_makeIdsRoot'](_0x43bdc1,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x26a608,_0x5d416c),_0x516b8d['set'](_0x26a608,_0x43bdc1['isAttached']()?_0x424071:{});for(const [_0x330445,_0x8aef74]of _0x43bdc1['markers']){if(!_0x330445['startsWith']('revision:'))continue;const _0x137572=_0x330445['split'](':')[0x2];for(const _0x2b786b of _0x8aef74['getWalker']({'singleCharacters':!0x0})){const _0x38d969=this['_getVidAttributeName'](_0x2b786b),_0x47a567=this['_revisionId']++,_0x185a93='elementEnd'==_0x2b786b['type']?_0x2b786b['previousPosition']['path']['slice'](0x0,-0x1):_0x2b786b['previousPosition']['path'];_0x5d416c['getNodeByPath'](_0x185a93)['_setAttribute'](_0x38d969,_0x47a567),this['_touched']['set'](_0x47a567,{'userId':_0x137572});}}for(const _0x243e7c of this['editor']['model']['createRangeIn'](_0x43bdc1)['getWalker']({'singleCharacters':!0x0})){const _0x461546=this['_getVidAttributeName'](_0x243e7c),_0x1501b1='elementEnd'==_0x243e7c['type']?_0x243e7c['previousPosition']['path']['slice'](0x0,-0x1):_0x243e7c['previousPosition']['path'],_0x4b8f37=_0x5d416c['getNodeByPath'](_0x1501b1);_0x4b8f37['getAttribute'](_0x461546)>0x0||_0x4b8f37['_setAttribute'](_0x461546,_0x23e9f6[_0x150003++]);}for(const [_0x223b85,_0x3c59ce]of _0x43bdc1['markers'])_0x223b85['startsWith']('revision:')||this['_markers']['set'](_0x223b85,_0x3c59ce);}const _0x1131c4=N('$graveyard');this['_baseRoots']['set']('$graveyard',_0x1131c4),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x1131c4,0x1));const _0x4bbda3=N('$graveyard');this['_diffRoots']['set']('$graveyard',_0x4bbda3),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x4bbda3,0x1));const _0x2498cd=Array['from'](this['_diffRoots'])['map'](([_0x878057,_0x356c75])=>[_0x878057,x(_0x356c75)]);this['_saveMetaData'](this['_lastTo'],_0x2498cd,this['_markers'],_0x516b8d);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0x1f2834,_0x593f17,_0x3ae434,_0x412140){const _0x57ddb2=new Map(_0x593f17),_0x4d9fc6=new Map(_0x5bd50a(_0x412140)),_0xe5d346=new Map();for(const [_0x59b050,_0x2b43e4]of _0x3ae434)_0xe5d346['set'](_0x59b050,{'start':_0x2b43e4['start']['clone'](),'end':_0x2b43e4['end']['clone'](),'rootName':_0x2b43e4['root']['rootName']});this['_savedMetaData']['set'](_0x1f2834,{'roots':_0x57ddb2,'markers':_0xe5d346,'rootsAttributes':_0x4d9fc6});}['_removeMetaData'](_0x7e7cf7){this['_savedMetaData']['delete'](_0x7e7cf7);}['_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'](_0x2a6507,_0x1fb3df=null){let _0x3a2470=null;_0x2a6507['is']('documentFragment')||(_0x3a2470=new nt(_0x2a6507['name'],{'vid_start':null===_0x1fb3df?this['_revisionId']++:_0x1fb3df++}));const _0x26f74b=[];for(const _0x48633c of _0x2a6507['getChildren']())if(_0x48633c['is']('element')){_0x26f74b['push'](this['_makeIdsRoot'](_0x48633c,_0x1fb3df));const _0x57ed34=_0x26f74b[_0x26f74b['length']-0x1];null!==_0x1fb3df&&(_0x1fb3df=_0x57ed34['is']('element','$text')?_0x57ed34['getAttribute']('vid')+0x1:_0x57ed34['getAttribute']('vid_end')+0x1);}else{for(let _0xac8fb0=0x0;_0xac8fb0<_0x48633c['offsetSize'];_0xac8fb0++)_0x26f74b['push'](new nt('$text',{'vid':null===_0x1fb3df?this['_revisionId']++:_0x1fb3df++}));}if(_0x2a6507['is']('documentFragment')){const _0x2bdbdb=N(_0x2a6507['rootName']);return _0x2bdbdb['_insertChild'](0x0,_0x26f74b),_0x2bdbdb;}return _0x3a2470['_setAttribute']('vid_end',null===_0x1fb3df?this['_revisionId']++:_0x1fb3df++),_0x3a2470['_insertChild'](0x0,_0x26f74b),_0x3a2470;}['_calculateMetaData'](_0x3288a7,_0x39d405,_0x5e9413){this['_reset']();const {roots:_0x5b148b,markers:_0x54ac9d,rootsAttributes:_0x3bd61b}=this['_savedMetaData']['get'](_0x3288a7);this['_baseRoots']=new Map(_0x5b148b),this['_baseRootsAttributes']=new Map(_0x5bd50a(_0x3bd61b));for(const [_0xe1c2a8,_0x5de45a]of this['_baseRoots'])if('$graveyard'!==_0xe1c2a8&&(this['_diffRoots']['set'](_0xe1c2a8,x(_0x5de45a)),this['_diffRootsAttributes']=new Map(_0x5bd50a(_0x3bd61b)),_0x5e9413)){const _0x4f4d35=this['_revisionId'];this['_idsRoots']['set'](_0xe1c2a8,this['_makeIdsRoot'](_0x5de45a)),this['_baseIdsRoots']['set'](_0xe1c2a8,this['_makeIdsRoot'](_0x5de45a,_0x4f4d35));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',x(this['_baseRoots']['get']('$graveyard'))),_0x5e9413&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x24b660,_0x2be682]of _0x54ac9d){const _0x325d4e=this['_baseRoots']['get'](_0x2be682['rootName']),_0x5e5f38=this['_diffRoots']['get'](_0x2be682['rootName']),_0x4d0703=new rt(this['_fixPosition'](_0x2be682['start'],_0x325d4e),this['_fixPosition'](_0x2be682['end'],_0x325d4e)),_0x1a8d98=this['_fixRange'](_0x4d0703,_0x5e5f38);_0x325d4e['markers']['set'](_0x24b660,_0x4d0703),this['_markers']['set'](_0x24b660,_0x1a8d98);}this['_applyOperations'](_0x3288a7,_0x39d405,_0x5e9413);}['_applyOperations'](_0x2ea8ca,_0x2b0f18,_0x201be2){for(const _0x5a8ef7 of this['source']['getOperations'](_0x2ea8ca,_0x2b0f18))this['_handleOperation'](_0x5a8ef7,_0x201be2);for(const _0x2d9598 of this['_diffRoots']['values']())_0x2d9598['markers']['clear']();for(const [_0x259bd8,_0x3ff188]of this['_markers']){this['_diffRoots']['get'](_0x3ff188['root']['rootName'])['markers']['set'](_0x259bd8,_0x3ff188['clone']());}const _0x2d7507=new Map(),_0x33ac8d=new Map();for(const [_0x28f812,_0x1fd2c9]of this['_diffRoots'])_0x2d7507['set'](_0x28f812,x(_0x1fd2c9)),_0x33ac8d['set'](_0x28f812,this['_diffRootsAttributes']['get'](_0x28f812));this['_saveMetaData'](_0x2b0f18,_0x2d7507,this['_markers'],_0x33ac8d);}['_getPreviousFrom'](_0x4828b9){const _0x5b8ee0=Array['from'](this['_savedMetaData']['keys']());_0x5b8ee0['sort']((_0x3ae9e8,_0x5d84c1)=>_0x3ae9e8-_0x5d84c1),_0x5b8ee0['reverse']();for(const _0x332e0d of _0x5b8ee0)if(_0x332e0d<_0x4828b9)return _0x332e0d;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x119ff1,_0x2e5579){const _0x416bf0=Array['from'](_0x2e5579['markers'])['map'](([_0x426784,_0x57d973])=>[_0x426784,this['_fixRange'](_0x57d973,_0x119ff1)]);_0x119ff1['markers']=new Map(_0x416bf0);}['_transformMarkers'](_0x3ff9ca){for(const _0x7ef098 of this['_markers']['values']()){const _0x2c07dd=_0x7ef098['getTransformedByOperation'](_0x3ff9ca),_0x2c870a=rt['_createFromRanges'](_0x2c07dd);_0x7ef098['start']=_0x2c870a['start'],_0x7ef098['end']=_0x2c870a['end'];}}['_handleOperation'](_0x3c0285,_0x3ad631){if('addRoot'!=_0x3c0285['type']&&'detachRoot'!=_0x3c0285['type']){if('insert'==_0x3c0285['type']){const _0x25b7d8=_0x3c0285['position']['root']['rootName'];this['_diffRoots']['has'](_0x25b7d8)||(this['_diffRoots']['set'](_0x25b7d8,N(_0x25b7d8,!0x0)),this['_diffRootsAttributes']['set'](_0x25b7d8,{}),_0x3ad631&&this['_idsRoots']['set'](_0x25b7d8,N(_0x25b7d8,!0x0)));}else{if('addRootAttribute'==_0x3c0285['type']||'removeRootAttribute'==_0x3c0285['type']||'changeRootAttribute'==_0x3c0285['type'])return void this['_handleRootAttributeOperation'](_0x3c0285);'marker'==_0x3c0285['type']&&this['_handleMarkerOperation'](_0x3c0285);}if('marker'!==_0x3c0285['type']){const _0x5bc0d8=this['_cloneOperation'](_0x3c0285,this['_diffRoots']);_0x5bc0d8['_execute'](),this['_transformMarkers'](_0x5bc0d8);}if(_0x3ad631)switch(_0x3c0285['type']){case'insert':this['_handleInsertOperation'](_0x3c0285);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x3c0285);break;case'merge':this['_handleMergeOperation'](_0x3c0285);break;case'split':this['_handleSplitOperation'](_0x3c0285);}}else this['_handleRootOperation'](_0x3c0285,_0x3ad631);}['_cloneOperation'](_0x43c0e3,_0x2de403){const _0x2640ea=_0x43c0e3['clone']();return _0x2640ea['_authorId']=_0x43c0e3['_authorId'],this['_fixOperation'](_0x2640ea,_0x2de403),_0x2640ea;}['_getBaseVids'](_0x1422ac){return _0x1422ac['map'](_0x3159cb=>{const _0x264be5=this['_getVidAttributeName'](_0x3159cb);return Number(_0x3159cb['item']['getAttribute'](_0x264be5));});}['_generateTape'](_0x4f9fd4,_0x5d814c){if(_0x4f9fd4['is']('element','$text'))_0x5d814c['push']({'item':_0x4f9fd4,'type':'text'});else{_0x4f9fd4['is']('element')&&_0x5d814c['push']({'item':_0x4f9fd4,'type':'elementStart'});for(const _0x24bf36 of _0x4f9fd4['getChildren']())this['_generateTape'](_0x24bf36,_0x5d814c);_0x4f9fd4['is']('element')&&_0x5d814c['push']({'item':_0x4f9fd4,'type':'elementEnd'});}return _0x5d814c;}['_getState'](){const _0x8ce480=new Map(this['_touched']),_0x31a666=new Map(_0x8ce480),_0x1bfb4d=new Map(),_0x28a140={'insertions':{},'deletions':{}},_0x1f0aa6={'insertions':{},'deletions':{}},_0x37a9fd=new Map(),_0x30efb7=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x30efb7['delete']('$graveyard');for(const _0x2828cd of _0x30efb7){const _0x3be7a6=this['_diffRoots']['get'](_0x2828cd)||N(_0x2828cd,!0x1),_0x434032=this['_baseRoots']['get'](_0x2828cd)||N(_0x2828cd,!0x1);_0x3be7a6['isAttached']()||_0x434032['isAttached']()?(_0x28a140['insertions'][_0x2828cd]=x(_0x3be7a6),_0x28a140['deletions'][_0x2828cd]=x(_0x434032),this['_copyMarkers'](_0x28a140['deletions'][_0x2828cd],_0x434032),this['_copyMarkers'](_0x28a140['insertions'][_0x2828cd],_0x3be7a6),_0x1f0aa6['insertions'][_0x2828cd]=this['_generateTape'](this['_idsRoots']['get'](_0x2828cd),[]),_0x1f0aa6['deletions'][_0x2828cd]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x2828cd)||N(_0x2828cd,!0x1),[])):_0x30efb7['delete'](_0x2828cd);}for(const _0xb71811 of _0x30efb7){const _0x38ee08=_0x1f0aa6['insertions'][_0xb71811];for(const _0xecbe95 of _0x38ee08){const _0x459168=this['_getVidAttributeName'](_0xecbe95),_0x3625ef=_0xecbe95['item']['getAttribute'](_0x459168);_0x31a666['delete'](_0x3625ef),_0x3625ef>=this['_startingRevisionId']&&_0x1bfb4d['set'](_0x3625ef,_0x8ce480['get'](_0x3625ef));}}for(const _0x39cedc of _0x30efb7){const _0x5bc8f8=_0x1f0aa6['insertions'][_0x39cedc],_0x518d61=this['_getBaseVids'](_0x1f0aa6['deletions'][_0x39cedc]);let _0x23d362=0x0;for(const _0x4b7700 of _0x5bc8f8){const _0x242b7d=this['_getVidAttributeName'](_0x4b7700),_0xd8e54f=_0x4b7700['item']['getAttribute'](_0x242b7d);if(!_0x1bfb4d['has'](_0xd8e54f)&&!_0x37a9fd['has'](_0xd8e54f)){if(_0x31a666['has'](_0xd8e54f))_0x23d362++;else{if(_0xd8e54f!=_0x518d61[_0x23d362]){const _0x53a099=_0x8ce480['get'](_0xd8e54f)||_0x8ce480['get'](_0x518d61[_0x23d362]);for(;_0xd8e54f!=_0x518d61[_0x23d362];)_0x31a666['has'](_0x518d61[_0x23d362])||(_0x37a9fd['set'](_0x518d61[_0x23d362],_0x53a099),_0x8ce480['set'](_0x518d61[_0x23d362],_0x53a099)),_0x23d362++;}_0x23d362++;}}}}for(const _0xb72e0b of _0x30efb7){const _0x2e2632=_0x1f0aa6['insertions'][_0xb72e0b];for(const _0x3f9ee9 of _0x2e2632){const _0x106009=this['_getVidAttributeName'](_0x3f9ee9),_0x15b4c6=_0x3f9ee9['item']['getAttribute'](_0x106009);if(_0x37a9fd['has'](_0x15b4c6)){const _0x6d74bf=_0x37a9fd['get'](_0x15b4c6);_0x31a666['has'](_0x15b4c6)||_0x31a666['set'](_0x15b4c6,{..._0x6d74bf}),_0x1bfb4d['set'](_0x15b4c6,{..._0x6d74bf});}}}for(const _0x1d3564 of _0x31a666['keys']())_0x1d3564>=this['_startingRevisionId']&&_0x31a666['delete'](_0x1d3564);const _0x20d532=new Map();for(const _0x36ffd6 of _0x30efb7){let _0x3905bf=_0x1f0aa6['insertions'][_0x36ffd6];for(const _0x4bd6b6 of _0x3905bf)if(_0x4bd6b6['item']['is']('element','tableCell')){const _0x45744d=this['_getVidAttributeName'](_0x4bd6b6),_0x3950bb=_0x4bd6b6['item']['getAttribute'](_0x45744d);if(_0x1bfb4d['has'](_0x3950bb)){const _0x36beb5=_0x4bd6b6['item']['parent']['parent']['getAttribute']('vid_start'),_0x575096=_0x20d532['get'](_0x36beb5)||new Set();_0x575096['add'](_0x1bfb4d['get'](_0x3950bb)['userId']),_0x20d532['set'](_0x36beb5,_0x575096);}}_0x3905bf=_0x1f0aa6['deletions'][_0x36ffd6];for(const _0x2a329f of _0x3905bf)if(_0x2a329f['item']['is']('element','tableCell')){const _0x3ca84f=this['_getVidAttributeName'](_0x2a329f),_0x14bbcc=_0x2a329f['item']['getAttribute'](_0x3ca84f);if(_0x31a666['has'](_0x14bbcc)){const _0x981c23=_0x2a329f['item']['parent']['parent']['getAttribute']('vid_start'),_0x38b13b=_0x20d532['get'](_0x981c23)||new Set();_0x38b13b['add'](_0x31a666['get'](_0x14bbcc)['userId']),_0x20d532['set'](_0x981c23,_0x38b13b);}}for(const _0x249910 of _0x20d532['keys']())(_0x1bfb4d['has'](_0x249910)||_0x31a666['has'](_0x249910))&&_0x20d532['delete'](_0x249910);}for(const _0x1b27bd of _0x30efb7){const _0x11b75f=_0x1f0aa6['insertions'][_0x1b27bd];let _0x4191a1=null,_0xbe85c=null;for(const _0x23df06 of _0x11b75f){const _0x14e9da=this['_getVidAttributeName'](_0x23df06),_0x1537e4=_0x23df06['item']['getAttribute'](_0x14e9da),_0x4edd88=_0x20d532['get'](_0x1537e4);_0x4edd88&&'elementStart'==_0x23df06['type']&&(_0x4191a1=Array['from'](_0x4edd88)[0x0],_0xbe85c=_0x23df06['item']['getAttribute']('vid_end')),_0x4191a1&&(_0x31a666['set'](_0x1537e4,{'userId':_0x4191a1}),_0x1bfb4d['set'](_0x1537e4,{'userId':_0x4191a1})),_0x1537e4==_0xbe85c&&(_0x4191a1=null,_0xbe85c=null);}}const _0x5a8179={},_0x2fc6cf=new Set();for(const _0x43ec78 of _0x30efb7){const _0x407cc7=_0x28a140['deletions'][_0x43ec78],_0x114826=_0x28a140['insertions'][_0x43ec78];for(const {userId:_0x9d8078}of this['_touchedMarkers']['values']())null!==_0x9d8078&&_0x2fc6cf['add'](_0x9d8078);for(const {userId:_0x203a59}of this['_touchedRoots']['values']())null!==_0x203a59&&_0x2fc6cf['add'](_0x203a59);this['_markChanges'](_0x114826,_0x1f0aa6['insertions'][_0x43ec78],_0x1bfb4d,'insertion',_0x2fc6cf),this['_markChanges'](_0x407cc7,_0x1f0aa6['deletions'][_0x43ec78],_0x31a666,'deletion',_0x2fc6cf),_0x5a8179[_0x43ec78]={'insertions':this['_prepareViewToSave'](_0x114826),'deletions':this['_prepareViewToSave'](_0x407cc7),'attachChange':this['_touchedRoots']['get'](_0x43ec78)||null,'attributesBefore':_0x5bd50a(this['_baseRootsAttributes']['get'](_0x43ec78))||{},'attributesAfter':_0x5bd50a(this['_diffRootsAttributes']['get'](_0x43ec78))};}return{'diffData':_0x5a8179,'authorsIds':Array['from'](_0x2fc6cf)};}['_processRootBeforeSave'](_0x5522df){for(const [,_0x4093bf]of _0x5522df['markers']){const _0x11f600=_0x4093bf['start']['getAncestors']()['filter'](_0x1a1506=>'tableCell'==_0x1a1506['name']);for(const _0x510ee9 of _0x11f600)0x1==_0x510ee9['childCount']&&_0x510ee9['getChild'](0x0)['is']('element','paragraph')&&_0x510ee9['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x2f2abb){this['_processRootBeforeSave'](_0x2f2abb);const _0x3c0ff9=this['editor']['data']['toView'](_0x2f2abb,{}),_0xfb56ad=Array['from'](_0x3c0ff9['getChildren']())['map'](_0x40493b=>this['_getViewJson'](_0x40493b));return JSON['stringify'](_0xfb56ad);}['_getViewJson'](_0x2a9974){if(_0x2a9974['is']('$text'))return _0x2a9974['data'];{const _0xdc3654=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0x23a47a=_0x2a9974,_0x2bf6fc=this['editor']['data']['htmlProcessor']['domConverter'],_0x7225bd={'type':_0xdc3654['_getTypeCharForViewElement'](_0x23a47a),'name':_0x23a47a['name'],'attributes':Array['from'](_0x23a47a['getAttributes']()),'children':Array['from'](_0x23a47a['getChildren']())['map'](_0x4071f0=>this['_getViewJson'](_0x4071f0))};if(_0x2a9974['is']('uiElement')&&'$comment'!=_0x2a9974['name']){const _0x1d1211=_0x2a9974['render'](_0x2bf6fc['domDocument'],_0x2bf6fc);_0x7225bd['children']['push'](_0x1d1211['outerHTML']);}else{if(_0x2a9974['is']('rawElement')){const _0x24b6c4=_0x2bf6fc['domDocument']['createElement'](_0x23a47a['name']);_0x2a9974['render'](_0x24b6c4,_0x2bf6fc),_0x7225bd['children']['push'](_0x24b6c4['innerHTML']);}}const _0x215f9d=Array['from'](_0x23a47a['getCustomProperties']());_0x215f9d['length']>0x0&&(_0x7225bd['customProperties']=_0x215f9d);const _0x21aefc=_0x23a47a['getFillerOffset']();return null!==_0x21aefc&&(_0x7225bd['fillerOffset']=_0x21aefc),_0x7225bd;}}['_markChanges'](_0x5e8cb9,_0x3720d,_0x234ccb,_0x253c9e,_0x33259e){let _0x24c9a1=null,_0x12260a=null,_0x61a632=0x0;const _0x514bdc=this['editor']['model'];for(let _0x31f5a5=0x0;_0x31f5a5<_0x3720d['length'];_0x31f5a5++){const _0x2671bc=this['_getVidAttributeName'](_0x3720d[_0x31f5a5]),_0x44511a=_0x3720d[_0x31f5a5]['item']['getAttribute'](_0x2671bc),_0x33966e=_0x234ccb['get'](_0x44511a),_0x42f776=_0x31f5a5==_0x3720d['length']-0x1;(!_0x24c9a1&&_0x33966e&&(_0x24c9a1=_0x33966e,_0x12260a=_0x3720d[_0x31f5a5]),_0x24c9a1&&(!_0x33966e||_0x33966e['userId']!=_0x24c9a1['userId']))&&(_0x3f10a6(_0x33966e,P(_0x12260a,_0x5e8cb9,_0x514bdc),P(_0x3720d[_0x31f5a5],_0x5e8cb9,_0x514bdc)),_0x24c9a1=_0x33966e||null,_0x12260a=_0x33966e?_0x3720d[_0x31f5a5]:null),_0x24c9a1&&_0x42f776&&_0x3f10a6(_0x33966e,P(_0x12260a,_0x5e8cb9,_0x514bdc),V(_0x3720d[_0x31f5a5],_0x5e8cb9,_0x514bdc));}function _0x3f10a6(_0xc89e0f,_0x29bcba,_0x49a40e){const _0x1f9e96=_0x24c9a1['userId'],_0x411bf8='revision:'+_0x253c9e+':'+_0x1f9e96+':'+_0x61a632++,_0x19fdd2=_0x514bdc['createRange'](_0x29bcba,_0x49a40e);_0x5e8cb9['markers']['set'](_0x411bf8,_0x19fdd2),null!==_0x1f9e96&&_0x33259e['add'](_0x1f9e96);}}['_getVidAttributeName'](_0x213619){switch(_0x213619['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x30dab5,_0x4bb42e){_0x30dab5['baseVersion']=null;for(const _0x31db13 in _0x30dab5){const _0x18eaa9=_0x30dab5[_0x31db13];if(_0x18eaa9 instanceof at){const _0x2b32f0=_0x4bb42e['get'](_0x18eaa9['root']['rootName']);_0x30dab5[_0x31db13]=this['_fixPosition'](_0x18eaa9,_0x2b32f0);}if(_0x18eaa9 instanceof rt){const _0x3eb372=_0x4bb42e['get'](_0x18eaa9['root']['rootName']);_0x30dab5[_0x31db13]=this['_fixRange'](_0x18eaa9,_0x3eb372);}'root'===_0x31db13&&(_0x30dab5['root']=_0x4bb42e['get'](_0x30dab5['root']['rootName']));}}['_fixRange'](_0x3d498f,_0x159d00){return this['editor']['model']['createRange'](this['_fixPosition'](_0x3d498f['start'],_0x159d00),this['_fixPosition'](_0x3d498f['end'],_0x159d00));}['_fixPosition'](_0x28a467,_0x1f9e71){return this['editor']['model']['createPositionFromPath'](_0x1f9e71,_0x28a467['path'],_0x28a467['stickiness']);}['_handleInsertOperation'](_0x36390e){const _0x686bb9=this['_idsRoots']['get'](_0x36390e['position']['root']['rootName']),_0x45ae8d=this['_fixPosition'](_0x36390e['position'],_0x686bb9),_0x20f414=null===_0x36390e['_authorId']?null:_0x36390e['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x2457e5=_0x45ae8d['parent'],_0x24e471=this['_revisionId'],_0x59f5bd=[];for(const _0x32eba3 of _0x36390e['nodes'])if(_0x32eba3['is']('element'))_0x59f5bd['push'](this['_makeIdsRoot'](_0x32eba3));else{for(let _0x1793af=0x0;_0x1793af<_0x32eba3['offsetSize'];_0x1793af++)_0x59f5bd['push'](new nt('$text',{'vid':this['_revisionId']++}));}const _0x2eaa1e=this['_revisionId'];for(let _0x5088b9=_0x24e471;_0x5088b9<_0x2eaa1e;_0x5088b9++)this['_touched']['set'](_0x5088b9,{'userId':_0x20f414});_0x2457e5['_insertChild'](_0x45ae8d['offset'],_0x59f5bd);}['_handleMoveOperation'](_0x2f4d93){(_0x2f4d93=this['_cloneOperation'](_0x2f4d93,this['_idsRoots']))['_execute']();const _0x3d5b48=null===_0x2f4d93['_authorId']?null:_0x2f4d93['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x5f1566=_0x2f4d93['getMovedRangeStart'](),_0x498d38=_0x5f1566['parent'],_0x4a00b2=_0x5f1566['offset'];!function _0x4c4483(_0x1eb555,_0x5d06cd,_0x8033a3,_0x5de118){for(let _0x2b0468=_0x8033a3;_0x2b0468<_0x5de118;_0x2b0468++){const _0x10f0cf=_0x5d06cd['getChild'](_0x2b0468);_0x10f0cf['is']('element','$text')?_0x1eb555['set'](_0x10f0cf['getAttribute']('vid'),{'userId':_0x3d5b48}):(_0x1eb555['set'](_0x10f0cf['getAttribute']('vid_start'),{'userId':_0x3d5b48}),_0x4c4483(_0x1eb555,_0x10f0cf,0x0,_0x10f0cf['childCount']),_0x1eb555['set'](_0x10f0cf['getAttribute']('vid_end'),{'userId':_0x3d5b48}));}}(this['_touched'],_0x498d38,_0x4a00b2,_0x4a00b2+_0x2f4d93['howMany']);}['_handleMergeOperation'](_0x9e866a){const _0x4feb63=null===(_0x9e866a=this['_cloneOperation'](_0x9e866a,this['_idsRoots']))['_authorId']?null:_0x9e866a['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x15ebf2=_0x9e866a['targetPosition']['parent'],_0x4c5e49=_0x9e866a['sourcePosition']['parent'],_0x33a2cc=_0x15ebf2['getAttribute']('vid_end'),_0x2bb93b=_0x4c5e49['getAttribute']('vid_start');_0x15ebf2['_setAttribute']('vid_end',_0x4c5e49['getAttribute']('vid_end')),_0x4c5e49['_setAttribute']('vid_end',_0x33a2cc),this['_touched']['set'](_0x2bb93b,{'userId':_0x4feb63}),this['_touched']['set'](_0x33a2cc,{'userId':_0x4feb63}),_0x9e866a['_execute']();}['_handleSplitOperation'](_0x460920){const _0x45a9a1=null===(_0x460920=this['_cloneOperation'](_0x460920,this['_idsRoots']))['_authorId']?null:_0x460920['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x25d474=_0x460920['graveyardPosition'],_0x196d4b=_0x460920['splitPosition']['parent'];_0x460920['_execute']();const _0x416cdd=_0x196d4b['getAttribute']('vid_end'),_0x151264=_0x460920['insertionPosition']['nodeAfter'];if(_0x25d474){const _0x496a58=_0x151264['getAttribute']('vid_end'),_0x2f6f44=_0x196d4b['getAttribute']('vid_end');_0x196d4b['_setAttribute']('vid_end',_0x496a58),_0x151264['_setAttribute']('vid_end',_0x2f6f44),this['_touched']['set'](_0x196d4b['getAttribute']('vid_end'),{'userId':_0x45a9a1}),this['_touched']['set'](_0x151264['getAttribute']('vid_start'),{'userId':_0x45a9a1});}else{const _0x1c9d97=this['_revisionId']++,_0xb4a95a=this['_revisionId']++;_0x196d4b['_setAttribute']('vid_end',_0x1c9d97),_0x151264['_setAttribute']('vid_start',_0xb4a95a),_0x151264['_setAttribute']('vid_end',_0x416cdd),this['_touched']['set'](_0x1c9d97,{'userId':_0x45a9a1}),this['_touched']['set'](_0xb4a95a,{'userId':_0x45a9a1});}}['_handleMarkerOperation'](_0x2134a1){if(!_0x2134a1['affectsData'])return;const _0x4f2fd6=(_0x2134a1=this['_cloneOperation'](_0x2134a1,this['_diffRoots']))['oldRange']?_0x2134a1['oldRange']['root']:null,_0x252940=_0x2134a1['newRange']?_0x2134a1['newRange']['root']:null;_0x4f2fd6&&this['_markers']['delete'](_0x2134a1['name']),_0x252940&&this['_markers']['set'](_0x2134a1['name'],_0x2134a1['newRange']['clone']());const _0x4935c6=null===_0x2134a1['_authorId']?null:_0x2134a1['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x57a975=_0x2134a1['name'];if(!this['_touchedMarkers']['has'](_0x57a975))return void this['_touchedMarkers']['set'](_0x57a975,{'range':_0x2134a1['oldRange'],'userId':_0x4935c6});const _0x8b07b1=this['_touchedMarkers']['get'](_0x57a975),_0x164141=_0x8b07b1['range'],_0x4610ba=_0x2134a1['newRange'];null==_0x164141&&null==_0x4610ba||_0x164141&&_0x4610ba&&_0x164141['isEqual'](_0x4610ba)?this['_touchedMarkers']['delete'](_0x2134a1['name']):_0x8b07b1['userId']=_0x4935c6;}['_handleRootOperation'](_0x2ac03e,_0x20586e){this['_diffRoots']['has'](_0x2ac03e['rootName'])?this['_diffRoots']['get'](_0x2ac03e['rootName'])['_isAttached']=_0x2ac03e['isAdd']:(this['_diffRoots']['set'](_0x2ac03e['rootName'],N(_0x2ac03e['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x2ac03e['rootName'],{}),_0x20586e&&this['_idsRoots']['set'](_0x2ac03e['rootName'],N(_0x2ac03e['rootName'],!0x0)));const _0x532061=null===_0x2ac03e['_authorId']?null:_0x2ac03e['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x4dd955=this['_touchedRoots']['get'](_0x2ac03e['rootName']);_0x4dd955&&_0x4dd955['userId']===_0x532061?this['_touchedRoots']['delete'](_0x2ac03e['rootName']):this['_touchedRoots']['set'](_0x2ac03e['rootName'],{'userId':_0x532061,'isAttached':_0x2ac03e['isAdd']});}['_handleRootAttributeOperation'](_0x1725b6){const _0x3f97f4=this['_diffRootsAttributes']['get'](_0x1725b6['root']['rootName']);null===_0x1725b6['newValue']?delete _0x3f97f4[_0x1725b6['key']]:_0x3f97f4[_0x1725b6['key']]=_0x1725b6['newValue'];}}function x(_0x2fc876){const _0x5c5e3d=N(_0x2fc876['rootName'],_0x2fc876['isAttached']());for(const _0x162e9e of _0x2fc876['getChildren']()){const _0xea80ba=_0x162e9e['_clone'](!0x0);_0x5c5e3d['_appendChild'](_0xea80ba);}return _0x5c5e3d;}function N(_0x4e49be,_0x2b8f3d=!0x0){const _0x24dd5f=new ht();return _0x24dd5f['rootName']=_0x4e49be,_0x24dd5f['_isAttached']=_0x2b8f3d,_0x24dd5f['isAttached']=()=>_0x24dd5f['_isAttached'],_0x24dd5f;}function P(_0x5d1ad8,_0x14a879,_0x400f59){const _0x52e5d7='elementEnd'==_0x5d1ad8['type']?_0x400f59['createPositionAt'](_0x5d1ad8['item'],'end'):_0x400f59['createPositionBefore'](_0x5d1ad8['item']);return _0x400f59['createPositionFromPath'](_0x14a879,_0x52e5d7['path'],_0x52e5d7['stickiness']);}function V(_0xcdfb7,_0x448109,_0x32b4f6){const _0x282254='elementStart'==_0xcdfb7['type']?_0x32b4f6['createPositionAt'](_0xcdfb7['item'],0x0):_0x32b4f6['createPositionAfter'](_0xcdfb7['item']);return _0x32b4f6['createPositionFromPath'](_0x448109,_0x282254['path'],_0x282254['stickiness']);}class me extends/* #__PURE__ -- @preserve */
25
- _0x129d59(_0x52b0b2){['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x703041,_0xd6701e){super(_0x703041),this['focusTracker']=new _0x395cd5(),this['keystrokes']=new _0xec8ea2(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0xd6701e),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'](),_0x5da359({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x991eeb=_0x3ee530=>_0x3ee530['stopPropagation']();this['keystrokes']['set']('arrowright',_0x991eeb),this['keystrokes']['set']('arrowleft',_0x991eeb),this['keystrokes']['set']('arrowup',_0x991eeb),this['keystrokes']['set']('arrowdown',_0x991eeb);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x382d96){this['revisionNameInputView']['fieldView']['element']['value']=_0x382d96['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x16e8ae){const _0x284d75=new et(this['locale'],ti),_0x1b2074=_0x284d75['fieldView'];_0x1b2074['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x441ecc=R(this['locale'],'Name\x20of\x20the\x20revision');return!_0x16e8ae&&(_0x441ecc+='\x20('+R(this['locale'],'optional')+')'),(_0x284d75['label']=_0x441ecc,_0x1b2074['on']('input',()=>{this['revisionNameInputValue']=_0x1b2074['element']['value']['trim']();}),_0x284d75);}}class v extends _0x49c0fc{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h];}['_saveRevisionFormView'];['init'](){const _0x438900=this['editor'],_0x5658ef=_0x438900['plugins']['get']('RevisionTracker');_0x438900['ui']['componentFactory']['add']('revisionHistory',_0x39332f=>{const _0x22f594=_0x4933a7(_0x39332f),_0x190020=_0x22f594['panelView']['children'],_0x186c4b=new _0x3fdd7d(_0x39332f),_0x3ab596=new _0x5ebb18(_0x39332f),_0x186ee9=new _0x3c378a(_0x39332f),_0x223301=new _0x5ebb18(_0x39332f),_0xc4e157=new _0x3c378a(_0x39332f);return _0x22f594['bind']('isEnabled')['to'](_0x5658ef,'isReady',_0x5658ef,'isEnabled',_0x438900,'isReadOnly',(_0xfe9a0f,_0x5510c1,_0x331578)=>_0xfe9a0f&&_0x5510c1&&!_0x331578),_0x22f594['buttonView']['set']({'icon':_0x4269eb,'label':R(_0x39332f,'Revision\x20history'),'tooltip':!0x0}),_0x186ee9['set']({'label':R(_0x39332f,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x186ee9['bind']('isEnabled')['to'](_0x5658ef,'isReady',_0x5658ef,'isEnabled',_0x438900,'isReadOnly',(_0x4a5182,_0x5d3c8d,_0x4d953a)=>_0x4a5182&&_0x5d3c8d&&!_0x4d953a),_0x186ee9['on']('execute',()=>this['_showDialog']()),_0xc4e157['set']({'label':R(_0x39332f,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0xc4e157['bind']('isEnabled')['to'](_0x5658ef,'isReady',_0x438900,'isReadOnly',(_0x332945,_0x12abaf)=>_0x332945&&!_0x12abaf),_0xc4e157['on']('execute',()=>{_0x438900['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x22f594['isOpen']=!0x1,_0x438900['editing']['view']['focus']();}),_0x3ab596['children']['add'](_0x186ee9),_0x223301['children']['add'](_0xc4e157),_0x186c4b['role']='menu',_0x186c4b['items']['addMany']([_0x3ab596,_0x223301]),_0x190020['add'](_0x186c4b),_0x22f594;}),_0x438900['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x2784fd=this['editor'],_0x247e9e=_0x2784fd['locale'],_0xd4117b=new _0x517f02(_0x247e9e),_0x43eb69=new _0x3c4af2(_0x247e9e);_0xd4117b['buttonView']['set']({'icon':_0x4269eb,'label':R(_0x247e9e,'Revision\x20history')});const _0x4a4657=new _0x286350(_0x247e9e,_0xd4117b),_0x230644=new _0x3c827c(_0x247e9e);_0x230644['set']({'label':R(_0x247e9e,'Save\x20current\x20revision')}),_0x230644['delegate']('execute')['to'](_0xd4117b),_0x230644['on']('execute',()=>{this['_showDialog']();}),_0x4a4657['children']['add'](_0x230644),_0x43eb69['items']['add'](_0x4a4657);const _0x255ef9=new _0x286350(_0x247e9e,_0xd4117b),_0x560671=new _0x3c827c(_0x247e9e);return _0x560671['set']({'label':R(_0x247e9e,'Open\x20revision\x20history')}),_0x560671['delegate']('execute')['to'](_0xd4117b),_0x560671['on']('execute',()=>{_0x2784fd['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x255ef9['children']['add'](_0x560671),_0x43eb69['items']['add'](_0x255ef9),_0xd4117b['panelView']['children']['add'](_0x43eb69),_0xd4117b;}['_showDialog'](){const _0xaa75c8=this['editor'],_0x4ad05a=_0xaa75c8['locale'],_0xd56d36=_0xaa75c8['plugins']['get']('Dialog'),_0x3a434b=_0xaa75c8['plugins']['get']('RevisionTracker');function _0x20c8b3(_0x345e65){_0xaa75c8['config']['get']('revisionHistory.requireRevisionName')&&''===_0x345e65['revisionName']?_0x345e65['revisionNameInputView']['errorText']=R(_0x4ad05a,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0xaa75c8['plugins']['get'](h)['saveRevision']({'name':_0x345e65['revisionName']}),_0xd56d36['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x20c8b3(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0xd56d36['show']({'id':'revisionSave','title':R(_0x4ad05a,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':R(_0xaa75c8['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0xd56d36['hide']()},{'label':R(_0xaa75c8['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x40cf5b){_0x40cf5b['bind']('isEnabled')['to'](_0x3a434b,'isReady',_0x3a434b,'isEnabled',_0xaa75c8,'isReadOnly',(_0x1a5a9c,_0x539ad4,_0x14b474)=>_0x1a5a9c&&_0x539ad4&&!_0x14b474);},'onExecute':()=>_0x20c8b3(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x3fa054=this['editor'],_0x572079=_0x3fa054['locale'];this['_saveRevisionFormView']=new me(_0x572079,_0x3fa054['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class z extends _0x52b0b2{['changeId'];['_model'];constructor(_0x2ccd3e,_0xd35a60){super(_0x2ccd3e),this['_model']=_0xd35a60,this['changeId']=_0xd35a60['id'];const _0x386d20=this['bindTemplate'],_0x5158ed=R(_0x2ccd3e,_0xd35a60['data']['isSuggestion']?'Suggested\x20by':'add'==_0xd35a60['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0xd35a60['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x386d20['to']('type',_0x1f59c5=>'ck-revision-change__'+_0x1f59c5)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x5158ed}]},{'text':'\x20'+_0xd35a60['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class G extends/* #__PURE__ -- @preserve */
26
- _0x5629d1(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x2ac0aa){super(),this['id']=_0x2ac0aa['id']||_0x582bfa(),this['author']=_0x2ac0aa['author'],this['type']=_0x2ac0aa['type'],this['data']=_0x2ac0aa['data']||{},this['rootName']=_0x2ac0aa['rootName'],this['set']('createdAt',_0x2ac0aa['createdAt']);}['toJSON'](){return{'id':this['id'],'authorId':this['author']['id'],'type':this['type'],'data':this['data'],'createdAt':this['createdAt']};}}class J{['newRevisionId'];['oldRevisionId'];['changes'];constructor(_0x3fc1ed,_0x4a828d){this['newRevisionId']=_0x3fc1ed,this['oldRevisionId']=_0x4a828d,this['changes']=new _0x5351d9();}['_setChanges'](_0x1c5d1a){for(const _0x5dbd98 of _0x1c5d1a)this['changes']['add'](_0x5dbd98);}}class l extends _0x49c0fc{['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[_0x55d287,_0x441216,S,$];}constructor(_0x5166d1){super(_0x5166d1),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',(_0x14f8b4,_0x17299c,_0xa50564)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x227e15=>{for(const _0x553930 of this['editor']['editing']['view']['document']['roots'])_0xa50564?_0x227e15['removeClass']('ck-editor__editable__overlay',_0x553930):_0x227e15['addClass']('ck-editor__editable__overlay',_0x553930);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x473f73=>null!==_0x473f73),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x50d58c,_0x4143e3,_0xb699ed)=>_0x50d58c&&_0xb699ed?_0x4143e3['changes']['getIndex'](_0xb699ed):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x317c64,_0x5a7f08)=>_0x317c64?_0x5a7f08['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0x441216);}['init'](){const _0x310ee2=this['editor'],_0x3250ba=new lt(_0x310ee2,{'direction':'backward'}),_0x48eec3=new lt(_0x310ee2,{'direction':'forward'});(_0x310ee2['commands']['add']('showPreviousChange',_0x3250ba),_0x310ee2['commands']['add']('showNextChange',_0x48eec3),_0x310ee2['commands']['add']('restoreRevision',new ut(_0x310ee2)),this['on']('change:numberOfChanges',()=>{_0x3250ba['refresh'](),_0x48eec3['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x310ee2['enableReadOnlyMode']('revision-viewer'),_0x310ee2['plugins']['has']('WidgetToolbarRepository'))&&_0x310ee2['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x52550e){return await this['_utils']['loadRevisionData'](_0x52550e,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x52550e);}async['getRevisionRootsAttributes'](_0x482048){return await this['_utils']['loadRevisionData'](_0x482048,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x482048);}async['compare'](_0xdf3ff3,_0x174577,_0x27cdda=!0x1){if(!this['isEnabled'])return;const _0x2108d7=this['diff'],_0x3abe38=this['repository'],_0x8853a3='string'==typeof _0xdf3ff3?_0x3abe38['getRevision'](_0xdf3ff3):_0xdf3ff3,_0x5bd2c5='string'==typeof _0x174577?_0x3abe38['getRevision'](_0x174577):_0x174577,_0x53d894=_0x8853a3['id'],_0x4d15eb=_0x5bd2c5?_0x5bd2c5['id']:null;if(!_0x27cdda&&this['diff']&&this['diff']['newRevisionId']===_0x53d894&&this['diff']['oldRevisionId']===_0x4d15eb)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new J(_0x53d894,_0x4d15eb);const _0x22e61d=this['_getRevisionsRange'](_0x8853a3,_0x5bd2c5,!0x0)['map'](_0x87ea9d=>this['_utils']['loadRevisionData'](_0x87ea9d,this['adapter']));return _0x22e61d['push'](new Promise(_0x1d851b=>{setTimeout(_0x1d851b,0x14);})),Promise['all'](_0x22e61d)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x3fe41b=this['_getDiff'](_0x53d894,_0x4d15eb);for(const _0x23c59e of _0x3fe41b['changes'])this['_changeIdToChange']['set'](_0x23c59e['id'],_0x23c59e);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x3affd1=>{for(const _0x202e21 of this['editor']['model']['document']['getRootNames']())_0x3affd1['detachRoot'](_0x202e21);for(const _0x363f47 of Object['keys'](_0x3fe41b['model'])){const _0x303d16=_0x3affd1['addRoot'](_0x363f47);for(const _0x5c0c83 of Object['keys'](_0x3fe41b['attributes'][_0x363f47]))_0x3affd1['setAttribute'](_0x5c0c83,_0x3fe41b['attributes'][_0x363f47][_0x5c0c83],_0x303d16);_0x3affd1['insert'](_0x3fe41b['model'][_0x363f47],_0x303d16,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x3fe41b['changes'])),this['isReady']=!0x0;})['catch'](_0x58ad7e=>{console['error'](_0x58ad7e),this['_cleanUp'](),_0x2108d7&&(this['diff']=_0x2108d7),this['isReady']=!0x0;});}['addRevisionData'](_0x4e8b95,_0x3de775){const _0x4aa52e=this['repository']['createRevision'](_0x4e8b95);return _0x4aa52e['on']('_update',(_0x12a23c,_0xd4970f,_0x446e89)=>_0x3de775(_0xd4970f,_0x446e89,_0x4aa52e)),this['repository']['addRevision'](_0x4aa52e),_0x4aa52e;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x5d6548=>{for(const _0x25c45b of this['editor']['model']['document']['getRootNames']())_0x5d6548['detachRoot'](_0x25c45b);});}['_sortAndFilterDiffChanges'](_0x22c674){const _0x54ae85=[],_0x179c43=new Map();for(const _0x561a15 of this['editor']['model']['document']['getRootNames']()){const _0x4a4090=this['editor']['editing']['view']['getDomRoot'](_0x561a15);if(!_0x4a4090)continue;const _0x22c6eb=_0x4a4090['getClientRects']()['item'](0x0);_0x22c6eb&&(_0x54ae85['push'](_0x561a15),_0x179c43['set'](_0x561a15,_0x22c6eb));}return _0x54ae85['sort']((_0x1e1a58,_0x429148)=>{const _0x4ca570=_0x179c43['get'](_0x1e1a58),_0x1926fb=_0x179c43['get'](_0x429148);return _0x4ca570['y']-_0x1926fb['y']||_0x4ca570['x']-_0x1926fb['x'];}),(_0x22c674=_0x22c674['filter'](_0x21e387=>_0x54ae85['includes'](_0x21e387['rootName'])))['sort']((_0x327665,_0x1b7405)=>_0x54ae85['indexOf'](_0x327665['rootName'])-_0x54ae85['indexOf'](_0x1b7405['rootName'])),_0x22c674;}['_makeTape'](_0x144db4){const _0x54b27a=Array['from'](_0x144db4['markers'])['filter'](([_0x491c96,_0x4abbff])=>_0x491c96['startsWith']('revision:')&&!_0x4abbff['isCollapsed']),_0x344107=Array['from'](this['editor']['model']['createRangeIn'](_0x144db4)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x54b27a['length'])for(const _0x4a1145 of _0x344107){const [_0x1942dd,_0xf58926]=_0x54b27a[0x0],[,_0x562e6e,_0x4b9705]=_0x1942dd['split'](':');if(_0xf58926['end']['isEqual'](_0x4a1145['nextPosition'])&&_0x54b27a['shift'](),(_0x4a1145['previousPosition']['isEqual'](_0xf58926['start'])||_0x4a1145['previousPosition']['isAfter'](_0xf58926['start']))&&('insertion'==_0x562e6e?_0x4a1145['isAdded']={'userId':_0x4b9705}:'deletion'==_0x562e6e&&(_0x4a1145['isRemoved']={'userId':_0x4b9705})),0x0==_0x54b27a['length'])break;}return _0x344107;}['_refreshStartEndIndex'](_0x4a0e31){const _0x550513=new Map();for(let _0x3baafe=0x0;_0x3baafe<_0x4a0e31['length'];_0x3baafe++)'text'===_0x4a0e31[_0x3baafe]['type']?(_0x4a0e31[_0x3baafe]['item']['startIndex']=_0x3baafe,_0x4a0e31[_0x3baafe]['item']['endIndex']=_0x3baafe):('elementStart'===_0x4a0e31[_0x3baafe]['type']?_0x4a0e31[_0x3baafe]['item']['startIndex']=_0x3baafe:'elementEnd'===_0x4a0e31[_0x3baafe]['type']&&(_0x4a0e31[_0x3baafe]['item']['endIndex']=_0x3baafe),_0x550513['set'](_0x4a0e31[_0x3baafe]['id'],_0x3baafe));for(const _0x4e5d4d of _0x550513['values']())'elementStart'===_0x4a0e31[_0x4e5d4d]['type']?_0x4a0e31[_0x4e5d4d]['item']['endIndex']=_0x550513['get'](_0x4a0e31[_0x4e5d4d]['pairId']):'elementEnd'===_0x4a0e31[_0x4e5d4d]['type']&&(_0x4a0e31[_0x4e5d4d]['item']['startIndex']=_0x550513['get'](_0x4a0e31[_0x4e5d4d]['pairId']));}['_processTape'](_0x4a5bb7){for(let _0x1eba4d=0x0;_0x1eba4d<_0x4a5bb7['length'];_0x1eba4d++){if('elementStart'===_0x4a5bb7[_0x1eba4d]['type'])_0x4a5bb7[_0x1eba4d]['item']['startIndex']=_0x1eba4d;else{if('elementEnd'===_0x4a5bb7[_0x1eba4d]['type']){_0x4a5bb7[_0x1eba4d]['item']['endIndex']=_0x1eba4d;const _0xb31249=_0x4a5bb7[_0x1eba4d]['item']['startIndex'];_0x4a5bb7[_0xb31249]['pairId']=_0x4a5bb7[_0x1eba4d]['id'],_0x4a5bb7[_0x1eba4d]['pairId']=_0x4a5bb7[_0xb31249]['id'];}else _0x4a5bb7[_0x1eba4d]['item']['startIndex']=_0x1eba4d,_0x4a5bb7[_0x1eba4d]['item']['endIndex']=_0x1eba4d,_0x4a5bb7[_0x1eba4d]['pairId']=null;}_0x4a5bb7[_0x1eba4d]['markersStart']||(_0x4a5bb7[_0x1eba4d]['markersStart']=[],_0x4a5bb7[_0x1eba4d]['markersEnd']=[]);}}['_markInsertions'](_0x165426,_0x2018b1){const _0x5361a4=_0x165426['filter'](_0x479f69=>!_0x479f69['isAdded']);for(let _0x44448c=0x0;_0x44448c<_0x2018b1['length'];_0x44448c++)_0x2018b1[_0x44448c]['isAdded']&&(_0x5361a4[_0x44448c]['isAdded']=_0x2018b1[_0x44448c]['isAdded']);}['_getDiff'](_0x31fee7,_0x4d9b14=null){const _0x4dd1c5=this['repository']['getRevision'](_0x31fee7),_0x47cf70=_0x4d9b14?this['repository']['getRevision'](_0x4d9b14):null,_0xd4d8b7=this['_getRevisionsRange'](_0x4dd1c5,_0x47cf70),_0x36b3c7=_0xd4d8b7[_0xd4d8b7['length']-0x1],_0x546d22=new Map(),_0x3d7aeb={'model':{},'attributes':{},'changes':[]},_0x11887a=new Set(),_0x4f342a=new Map();for(let _0xb3310a=_0xd4d8b7['length']-0x1;_0xb3310a>=0x0;_0xb3310a--){const _0x17098e=_0xd4d8b7[_0xb3310a];for(const _0x15e31b of Object['keys'](_0x17098e['diffData']))if(_0x17098e['diffData'][_0x15e31b]['attachChange']){const _0x558858=_0x17098e['diffData'][_0x15e31b]['attachChange'];_0x558858['isAttached']?(_0x11887a['add'](_0x15e31b),_0x4f342a['has'](_0x15e31b)&&_0x4f342a['get'](_0x15e31b)['userId']==_0x558858['userId']?_0x4f342a['delete'](_0x15e31b):_0x4f342a['set'](_0x15e31b,_0x558858)):_0x4f342a['has'](_0x15e31b)?(_0x11887a['delete'](_0x15e31b),_0x4f342a['delete'](_0x15e31b)):(_0x11887a['add'](_0x15e31b),_0x4f342a['set'](_0x15e31b,_0x558858));}else _0x11887a['add'](_0x15e31b);}for(const _0x297330 of _0x11887a){const _0x150449=_0x4f342a['has'](_0x297330)&&!_0x4f342a['get'](_0x297330)['isAttached'];let _0x37ea14=_0x150449?_0xd4d8b7['length']-0x1:0x0;const _0x2107aa=_0x150449?-0x1:0x1;for(;_0xd4d8b7[_0x37ea14];){const _0x4a70e8=_0xd4d8b7[_0x37ea14];if(_0x4a70e8['diffData'][_0x297330]){const _0x1d35ab=_0x150449?_0x4a70e8['diffData'][_0x297330]['attributesBefore']:_0x4a70e8['diffData'][_0x297330]['attributesAfter'];_0x3d7aeb['attributes'][_0x297330]=_0x1d35ab?_0x5bd50a(_0x1d35ab):{};break;}_0x37ea14+=_0x2107aa;}}for(const _0x4b1657 of _0xd4d8b7){_0x4b1657['model']={};for(const _0x10447f of _0x4b1657['authors'])_0x546d22['set'](_0x10447f['id'],_0x10447f);for(const _0xa764d6 of _0x11887a){const _0x4f78c4=_0x4b1657['diffData'][_0xa764d6]?_0x4b1657['diffData'][_0xa764d6]['insertions']:'[]',_0x34de36=_0x4b1657['diffData'][_0xa764d6]?_0x4b1657['diffData'][_0xa764d6]['deletions']:'[]';_0x4b1657['model'][_0xa764d6]={'insertions':this['_utils']['_makeModelFromViewString'](_0x4f78c4),'deletions':this['_utils']['_makeModelFromViewString'](_0x34de36)};}}for(const _0x5bae3c of _0x11887a){let _0x178a40=null,_0x110955=0x0;const _0x5f3a33=new Map(Array['from'](_0x4dd1c5['model'][_0x5bae3c]['insertions']['markers'])['filter'](([_0x11b898])=>!_0x11b898['startsWith']('revision:')));let _0x1d1196=0x0;for(const _0x12feea of _0xd4d8b7){const _0x2f905e=this['_makeTape'](_0x12feea['model'][_0x5bae3c]['insertions']);_0x12feea==_0x4dd1c5?(_0x178a40=_0x2f905e,_0x110955=_0x178a40['length'],_0x178a40['forEach'](_0x22ce05=>{_0x22ce05['id']=_0x1d1196++;}),this['_processTape'](_0x178a40)):this['_markInsertions'](_0x178a40,_0x2f905e);const _0x2b647b=_0x178a40['filter'](_0x23dcb2=>!_0x23dcb2['isAdded'])['map'](_0x339c33=>_0x339c33['id']);let _0x2bff7a=0x0;const _0x36a1cb=this['_makeTape'](_0x12feea['model'][_0x5bae3c]['deletions']);_0x36a1cb['forEach'](_0x21d18b=>{_0x21d18b['isRemoved']?_0x21d18b['id']=_0x110955++:_0x21d18b['id']=_0x2b647b[_0x2bff7a++];}),this['_processTape'](_0x36a1cb),this['_setDistance'](_0x178a40,'isAdded'),this['_setDistance'](_0x36a1cb,'isRemoved'),_0x12feea==_0x4dd1c5&&this['_markMarkers'](_0x178a40,_0x5f3a33),_0x178a40=this['_joinTapes'](_0x178a40,_0x36a1cb),this['_refreshStartEndIndex'](_0x178a40),this['_setDistance'](_0x178a40,'isRemoved');}_0x178a40=_0x178a40['filter'](_0x2a006f=>!(_0x2a006f['isAdded']&&_0x2a006f['isRemoved']));const _0x1385d5=new Map(_0x36b3c7['model'][_0x5bae3c]['deletions']['markers']),_0x93f598=new Set(_0x5f3a33['keys']());for(const _0xd9fcac of _0x1385d5['keys']())_0x93f598['delete'](_0xd9fcac);this['_markSuggestions'](_0x178a40,_0x93f598),this['_fixObsoleteTags'](_0x178a40),_0x178a40=this['_removeMissingPairs'](_0x178a40),_0x178a40=this['_markMismatchedRemovedTags'](_0x178a40),_0x178a40=this['_removeUnsupportedChanges'](_0x178a40);const {root:_0x442f8a,changes:_0x2d7219}=this['_makeModelFromTape'](_0x178a40,_0x546d22,_0x5bae3c);_0x3d7aeb['model'][_0x5bae3c]=_0x442f8a;const _0x21c3ae=_0x4f342a['get'](_0x5bae3c);if(_0x21c3ae){const _0x3d2a78=_0x546d22['get'](_0x21c3ae['userId']),_0x186c16=new G({'author':_0x3d2a78,'type':_0x21c3ae['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x5bae3c});_0x2d7219['unshift'](_0x186c16),_0x3d7aeb['attributes'][_0x5bae3c]['revisionHistoryAttachChange']=_0x186c16['id'];}_0x3d7aeb['changes']=_0x3d7aeb['changes']['concat'](_0x2d7219);}return _0x3d7aeb;}['_markMarkers'](_0x17fcde,_0x18f304){for(let _0x17df9e=0x0;_0x17df9e<_0x17fcde['length'];_0x17df9e++)for(const [_0x4fbe85,_0x13ffc6]of _0x18f304)!_0x13ffc6['isCollapsed']&&_0x13ffc6['start']['isEqual'](_0x17fcde[_0x17df9e]['previousPosition'])&&_0x17fcde[_0x17df9e]['markersStart']['push'](_0x4fbe85),_0x13ffc6['end']['isEqual'](_0x17fcde[_0x17df9e]['nextPosition'])&&_0x17fcde[_0x17df9e]['markersEnd']['push'](_0x4fbe85);}['_joinTapes'](_0x98d0f9,_0x12e2f0){let _0x406643=[],_0x4aa0d1=0x0,_0x304ef5=0x0;for(;_0x4aa0d1<_0x98d0f9['length']||_0x304ef5<_0x12e2f0['length'];){const _0x29ebd4=_0x98d0f9[_0x4aa0d1]||{},_0x26d7f9=_0x12e2f0[_0x304ef5]||{};if(_0x29ebd4['id']==_0x26d7f9['id'])_0x4aa0d1++,_0x304ef5++,_0x406643['push'](_0x29ebd4);else{if(_0x26d7f9['isRemoved']&&_0x29ebd4['isAdded']){const {commonTape:_0x496244,iEnd:_0x62b8c1,jEnd:_0x3f5e93}=this['_threeWayMerge'](_0x98d0f9,_0x4aa0d1,_0x12e2f0,_0x304ef5);_0x406643=_0x406643['concat'](_0x496244),_0x4aa0d1=_0x62b8c1,_0x304ef5=_0x3f5e93;}else _0x26d7f9['isRemoved']?(_0x304ef5++,_0x406643['push'](_0x26d7f9)):(_0x4aa0d1++,_0x406643['push'](_0x29ebd4));}}return _0x406643;}['_markSuggestions'](_0x36dbbb,_0x498f8e){const _0x38fa35=[];for(let _0x3aafcd=0x0;_0x3aafcd<_0x36dbbb['length'];_0x3aafcd++){for(let _0x5f112e=0x0;_0x5f112e<_0x36dbbb[_0x3aafcd]['markersStart']['length'];_0x5f112e++){const _0x30dcc5=_0x36dbbb[_0x3aafcd]['markersStart'][_0x5f112e];if(!_0x498f8e['has'](_0x30dcc5))continue;const {group:_0x14b0b5,type:_0x1d9574,authorId:_0x3a847f}=_0x53459a(_0x30dcc5);'revision-suggestion'!=_0x14b0b5||'insertion'!=_0x1d9574&&'deletion'!=_0x1d9574||(_0x38fa35['unshift']({'type':_0x1d9574,'name':_0x30dcc5,'userId':_0x3a847f}),_0x36dbbb[_0x3aafcd]['markersStart']['splice'](_0x5f112e,0x1),_0x5f112e--);}_0x372b36(_0x36dbbb[_0x3aafcd]);for(let _0x3bbacf=0x0;_0x3bbacf<_0x36dbbb[_0x3aafcd]['markersEnd']['length'];_0x3bbacf++){const _0x51d504=_0x36dbbb[_0x3aafcd]['markersEnd'][_0x3bbacf];if(!_0x498f8e['has'](_0x51d504))continue;const {group:_0x5dff13,type:_0x14873b}=_0x53459a(_0x51d504);if('revision-suggestion'!=_0x5dff13||'insertion'!=_0x14873b&&'deletion'!=_0x14873b)continue;_0x36dbbb[_0x3aafcd]['markersEnd']['splice'](_0x3bbacf,0x1),_0x3bbacf--;const _0x25295e=_0x38fa35['findIndex'](_0x5d7bb4=>_0x5d7bb4['name']==_0x51d504);_0x25295e>-0x1&&_0x38fa35['splice'](_0x25295e,0x1);}}function _0x53459a(_0x4c6777){const _0x948d0=_0x4c6777['split'](':');return{'group':_0x948d0[0x0],'type':_0x948d0[0x1],'subType':_0x948d0['length']>=0x5?_0x948d0[0x2]:null,'id':_0x948d0['length']<0x5?_0x948d0[0x2]:_0x948d0[0x3],'authorId':_0x948d0['length']<0x5?_0x948d0[0x3]:_0x948d0[0x4],'markerCount':0x6==_0x948d0['length']?_0x948d0[0x5]:null};}function _0x372b36(_0xc0097a){for(let _0x53eaf8=0x0;_0x53eaf8<_0x38fa35['length'];_0x53eaf8++){if(_0xc0097a['isAdded']&&'insertion'==_0x38fa35[_0x53eaf8]['type']&&_0xc0097a['isAdded']['userId']==_0x38fa35[_0x53eaf8]['userId'])return _0xc0097a['isAddSuggestion']=_0x38fa35[_0x53eaf8],void delete _0xc0097a['isAdded'];if(!_0xc0097a['isAdded']&&!_0xc0097a['isRemoved']&&'deletion'==_0x38fa35[_0x53eaf8]['type'])return void(_0xc0097a['isRemoveSuggestion']=_0x38fa35[_0x53eaf8]);}}}['_setDistance'](_0x47e340,_0x5e5713){let _0x3a72fb=0x0,_0x535ddc=!0x1;const _0x15c8a8=new Map();for(const _0x481511 of _0x47e340)_0x481511[_0x5e5713]?_0x535ddc&&(_0x3a72fb++,_0x535ddc=!0x1):(_0x3a72fb++,_0x535ddc=!0x0),_0x15c8a8['set'](_0x481511['id'],_0x3a72fb);for(let _0x4331d4=0x0;_0x4331d4<_0x47e340['length'];_0x4331d4++){if('isRemoved'==_0x5e5713&&_0x47e340[_0x4331d4]['isAdded']||'isAdded'==_0x5e5713&&_0x47e340[_0x4331d4]['isRemoved'])continue;if('text'==_0x47e340[_0x4331d4]['type']){_0x47e340[_0x4331d4]['distance']=0x0;continue;}const _0x1a941a=_0x15c8a8['get'](_0x47e340[_0x4331d4]['pairId']),_0x49947d=_0x15c8a8['get'](_0x47e340[_0x4331d4]['id']);_0x47e340[_0x4331d4]['distance']=_0x1a941a-_0x49947d;}}['_getRevisionsRange'](_0x45a55e,_0x172803,_0x3357c2=!0x1){const _0x1d5c07=[];let _0x37bae6=this['repository']['getIndex'](_0x45a55e),_0x3078be=this['repository']['getIndex'](_0x172803);for(-0x1==_0x3078be&&(_0x3078be=this['repository']['_revisions']['length'],_0x3357c2=!0x1);_0x37bae6<_0x3078be;)_0x1d5c07['push'](this['repository']['getRevision'](_0x37bae6)),_0x37bae6++;return _0x3357c2&&_0x1d5c07['push'](this['repository']['getRevision'](_0x37bae6)),_0x1d5c07;}['_threeWayMerge'](_0x29ad8e,_0x97a9c8,_0x5cc75b,_0x58134c){const _0x22cd87=this['editor']['model']['schema'];let _0x3567e6=_0x97a9c8;for(;_0x29ad8e[_0x3567e6]&&_0x29ad8e[_0x3567e6]['isAdded'];)_0x3567e6++;let _0x16e176=_0x58134c;for(;_0x5cc75b[_0x16e176]&&_0x5cc75b[_0x16e176]['isRemoved'];)_0x16e176++;_0x1b454(_0x29ad8e,_0x97a9c8,_0x3567e6),_0x1b454(_0x5cc75b,_0x58134c,_0x16e176);const _0x56ba99=_0x5cc75b['slice'](_0x58134c,_0x16e176)['concat'](_0x29ad8e['slice'](_0x97a9c8,_0x3567e6));return _0x56ba99['sort']((_0x20e444,_0x14524d)=>_0x20e444['side']!=_0x14524d['side']?_0x20e444['side']-_0x14524d['side']:_0x20e444['level']!=_0x14524d['level']?_0x20e444['level']-_0x14524d['level']:_0x20e444['distance']!=_0x14524d['distance']?_0x14524d['distance']-_0x20e444['distance']:!!_0x20e444['isAdded']!=!!_0x14524d['isAdded']?-0x1==_0x20e444['side']||0x0==_0x20e444['side']?_0x20e444['isAdded']?-0x1:0x1:_0x20e444['isAdded']?0x1:-0x1:_0x20e444['index']-_0x14524d['index']),{'commonTape':_0x56ba99,'iEnd':_0x3567e6,'jEnd':_0x16e176};function _0x1b454(_0x2f4439,_0x198924,_0x4e3d93){let _0x2d87f9=-0x1,_0x2eec35=Number['POSITIVE_INFINITY'],_0x32d538=!0x0;for(let _0x213d96=_0x198924;_0x213d96<_0x4e3d93;_0x213d96++)if(_0x22cd87['isInline'](_0x2f4439[_0x213d96]['item'])||(_0x32d538=!0x1),_0x2f4439[_0x213d96]['item']['startIndex']<_0x198924&&(_0x2d87f9=_0x213d96),_0x2f4439[_0x213d96]['item']['endIndex']>=_0x4e3d93){_0x2eec35=_0x213d96;break;}_0x32d538&&(_0x2d87f9=_0x4e3d93-0x1);for(let _0x319ff7=_0x198924;_0x319ff7<_0x4e3d93;_0x319ff7++)_0x2f4439[_0x319ff7]['side']=_0x319ff7<=_0x2d87f9?-0x1:_0x319ff7<_0x2eec35?0x0:0x1,_0x2f4439[_0x319ff7]['index']=_0x319ff7;let _0x58a169=0x0;for(let _0x114669=_0x198924;_0x114669<=_0x2d87f9;_0x114669++)0x0==_0x2f4439[_0x114669]['distance']?_0x2f4439[_0x114669]['level']=_0x58a169:(_0x58a169++,_0x2f4439[_0x114669]['level']=_0x58a169,_0x58a169++);for(let _0x3d4cad=_0x198924;_0x3d4cad<_0x4e3d93;_0x3d4cad++)0x0==_0x2f4439[_0x3d4cad]['side']&&(_0x2f4439[_0x3d4cad]['level']=_0x58a169);_0x58a169=0x0;for(let _0x1e4977=_0x4e3d93-0x1;_0x1e4977>=_0x2eec35;_0x1e4977--)0x0==_0x2f4439[_0x1e4977]['distance']?_0x2f4439[_0x1e4977]['level']=_0x58a169:(_0x58a169--,_0x2f4439[_0x1e4977]['level']=_0x58a169,_0x58a169--);}}['_fixObsoleteTags'](_0x349757){const _0x25f23c=new Map(),_0x56b68f=this['editor']['model']['schema'];for(let _0x2c972f=0x1;_0x2c972f<_0x349757['length'];_0x2c972f++){let _0x3f581c,_0x47117b,_0x13122f;const _0x30e203=_0x349757[_0x2c972f],_0x431d5e=_0x349757[_0x2c972f-0x1];if('text'==_0x30e203['type'])continue;if(_0x30e203['type']!=_0x431d5e['type'])continue;if(!_0x56b68f['isBlock'](_0x431d5e['item'])||_0x56b68f['isLimit'](_0x431d5e['item']))continue;if(!_0x56b68f['isBlock'](_0x30e203['item'])||_0x56b68f['isLimit'](_0x30e203['item']))continue;if((_0x349757[_0x2c972f]['isAdded']||_0x349757[_0x2c972f]['isAddSuggestion'])&&_0x349757[_0x2c972f-0x1]['isRemoved'])_0x3f581c=_0x349757[_0x2c972f],_0x47117b=_0x349757[_0x2c972f-0x1],_0x13122f=_0x2c972f-0x1;else{if(!_0x349757[_0x2c972f]['isRemoved']||!_0x349757[_0x2c972f-0x1]['isAdded']&&!_0x349757[_0x2c972f-0x1]['isAddSuggestion'])continue;_0x3f581c=_0x349757[_0x2c972f-0x1],_0x47117b=_0x349757[_0x2c972f],_0x13122f=_0x2c972f;}const _0x55b9cd=_0x3f581c['level']==_0x47117b['level'],_0x30727f=Math['abs'](_0x3f581c['level'])<Math['abs'](_0x47117b['level'])&&0x0==_0x47117b['distance'];(_0x55b9cd||_0x30727f)&&(_0x25f23c['set'](_0x47117b['id'],_0x3f581c['id']),_0x349757['splice'](_0x13122f,0x1),_0x2c972f--,_0x3f581c['isAdded']=!0x1);}for(let _0x4e297a=0x0;_0x4e297a<_0x349757['length'];_0x4e297a++)_0x25f23c['has'](_0x349757[_0x4e297a]['pairId'])&&(_0x349757[_0x4e297a]['pairId']=_0x25f23c['get'](_0x349757[_0x4e297a]['pairId']));}['_removeMissingPairs'](_0x27c657){const _0x4a41b8=new Set(_0x27c657['map'](_0x5ee634=>_0x5ee634['id']));for(let _0x3aa9a2=0x0;_0x3aa9a2<_0x27c657['length'];_0x3aa9a2++)_0x4a41b8['has'](_0x27c657[_0x3aa9a2]['pairId'])||0x0==_0x27c657[_0x3aa9a2]['distance']||(_0x27c657[_0x3aa9a2]['isIncorrect']=!0x0);return _0x27c657['filter'](_0x9f3572=>!_0x9f3572['isIncorrect']);}['_markMismatchedRemovedTags'](_0x54a14b){const _0xb20e40=new Set();for(let _0x34a25a=0x0;_0x34a25a<_0x54a14b['length'];_0x34a25a++){if(_0xb20e40['has'](_0x54a14b[_0x34a25a]['id'])&&_0x54a14b[_0x34a25a]['isRemoved']&&(_0x54a14b[_0x34a25a]['isIncorrect']=!0x0),_0x54a14b[_0x34a25a]['isIncorrect'])continue;if(0x0==_0x54a14b[_0x34a25a]['distance'])continue;if('elementStart'!=_0x54a14b[_0x34a25a]['type'])continue;if(null==_0x54a14b[_0x34a25a]['pairId'])continue;let _0x5b3b7e=_0x34a25a+0x1,_0xc114a9=0x0;for(;_0x54a14b[_0x5b3b7e]['id']!=_0x54a14b[_0x34a25a]['pairId'];)'elementStart'==_0x54a14b[_0x5b3b7e]['type']?_0xc114a9++:'elementEnd'==_0x54a14b[_0x5b3b7e]['type']&&_0xc114a9--,_0x5b3b7e++;if(0x0!=_0xc114a9){if(_0x54a14b[_0x34a25a]['isRemoved'])_0x54a14b[_0x34a25a]['isIncorrect']=!0x0;else{for(;_0x5b3b7e!=_0x34a25a;)_0x54a14b[_0x5b3b7e]['isRemoved']&&0x0!=_0x54a14b[_0x5b3b7e]['distance']&&(_0x54a14b[_0x5b3b7e]['isIncorrect']=!0x0,_0xb20e40['add'](_0x54a14b[_0x5b3b7e]['pairId'])),_0x5b3b7e--;}}}return _0x54a14b['filter'](_0x49050e=>!_0x49050e['isIncorrect']);}['_removeUnsupportedChanges'](_0x453c82){const _0x1260e4=this['editor']['model']['schema'];for(let _0x4558f7=0x0;_0x4558f7<_0x453c82['length'];_0x4558f7++){if(!(_0x453c82[_0x4558f7]['isAdded']||_0x453c82[_0x4558f7]['isAddSuggestion']||_0x453c82[_0x4558f7]['isRemoved']||_0x453c82[_0x4558f7]['isRemoveSuggestion']))continue;if(0x0==_0x453c82[_0x4558f7]['distance'])continue;const _0x3249ea=_0x453c82[_0x4558f7]['item'];_0x1260e4['isBlock'](_0x3249ea)||_0x1260e4['isLimit'](_0x3249ea)||(_0x453c82[_0x4558f7]['isAdded']&&delete _0x453c82[_0x4558f7]['isAdded'],_0x453c82[_0x4558f7]['isAddSuggestion']&&delete _0x453c82[_0x4558f7]['isAddSuggestion'],_0x453c82[_0x4558f7]['isRemoveSuggestion']&&delete _0x453c82[_0x4558f7]['isRemoveSuggestion'],_0x453c82[_0x4558f7]['isRemoved']&&(_0x453c82[_0x4558f7]['isIncorrect']=!0x0));}return _0x453c82['filter'](_0x49520a=>!_0x49520a['isIncorrect']);}['_makeModelFromTape'](_0x1a3840,_0xee0ec2,_0x49947c){const _0x4b3b8c=new ht(),_0x32b519=[],_0x4d1800=new Map(),_0x21d54b=this['editor']['model'],_0x3b8a7c=_0x21d54b['schema'],_0x166b3c=[_0x4b3b8c],_0x40b2b5={},_0x22eb1b={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x4af940=null;const _0x5d2905=[0x0];for(let _0x569548=0x0;_0x569548<_0x1a3840['length'];_0x569548++)if('elementStart'===_0x1a3840[_0x569548]['type']){_0x1a3840[_0x569548]['previousPosition']=_0x21d54b['createPositionFromPath'](_0x4b3b8c,_0x5d2905);const _0x40eea1=new nt(_0x1a3840[_0x569548]['item']['name'],_0x1a3840[_0x569548]['item']['getAttributes']());_0x166b3c[0x0]['_appendChild'](_0x40eea1),_0x5d2905['push'](0x0),_0x166b3c['unshift'](_0x40eea1),_0x1a3840[_0x569548]['nextPosition']=_0x21d54b['createPositionFromPath'](_0x4b3b8c,_0x5d2905);}else'elementEnd'===_0x1a3840[_0x569548]['type']?(_0x166b3c['shift'](),_0x1a3840[_0x569548]['previousPosition']=_0x21d54b['createPositionFromPath'](_0x4b3b8c,_0x5d2905),_0x5d2905['pop'](),_0x5d2905[_0x5d2905['length']-0x1]++,_0x1a3840[_0x569548]['nextPosition']=_0x21d54b['createPositionFromPath'](_0x4b3b8c,_0x5d2905)):(_0x1a3840[_0x569548]['previousPosition']=_0x21d54b['createPositionFromPath'](_0x4b3b8c,_0x5d2905),_0x4af940?_0x4af940['_data']+=_0x1a3840[_0x569548]['item']['data']:_0x4af940=new ct(_0x1a3840[_0x569548]['item']['data'],_0x1a3840[_0x569548]['item']['getAttributes']()),_0x1a3840[_0x569548+0x1]&&'text'===_0x1a3840[_0x569548+0x1]['type']&&_0x2272a0(_0x4af940,_0x1a3840[_0x569548+0x1]['item'])||(_0x166b3c[0x0]['_appendChild'](_0x4af940),_0x4af940=null),_0x5d2905[_0x5d2905['length']-0x1]+=_0x1a3840[_0x569548]['item']['offsetSize'],_0x1a3840[_0x569548]['nextPosition']=_0x21d54b['createPositionFromPath'](_0x4b3b8c,_0x5d2905));for(let _0x4e176b=0x0;_0x4e176b<_0x1a3840['length'];_0x4e176b++){const _0x218b4c=_0x1a3840[_0x4e176b]['previousPosition'],_0x2a3b48=_0x1a3840[_0x4e176b]['nextPosition'];for(const _0x5abbe2 of _0x1a3840[_0x4e176b]['markersStart'])_0x4d1800['set'](_0x5abbe2,{'start':_0x218b4c,'end':null});_0x1ed553('isRemoveSuggestion',_0x4e176b,_0x218b4c,_0x2a3b48),_0x1ed553('isAddSuggestion',_0x4e176b,_0x218b4c,_0x2a3b48),_0x1ed553('isRemoved',_0x4e176b,_0x218b4c,_0x2a3b48),_0x1ed553('isAdded',_0x4e176b,_0x218b4c,_0x2a3b48);for(const _0x30bf88 of _0x1a3840[_0x4e176b]['markersEnd']){const _0x17a75d=_0x4d1800['get'](_0x30bf88);_0x17a75d?_0x17a75d['end']=_0x2a3b48:_0x4d1800['set'](_0x30bf88,{'start':_0x2a3b48,'end':_0x2a3b48});}}for(const [_0x5e65ba,_0x2e7bf2]of _0x4d1800){const _0x2a23d2=this['editor']['model']['createRange'](_0x2e7bf2['start'],_0x2e7bf2['end']);_0x4b3b8c['markers']['set'](_0x5e65ba,_0x2a23d2);}return _0x32b519['sort']((_0x2ffd34,_0x507902)=>{const _0x33b8db=_0x4b3b8c['markers']['get']('revision:'+_0x2ffd34['id']),_0x573970=_0x4b3b8c['markers']['get']('revision:'+_0x507902['id']);return _0x33b8db['start']['isBefore'](_0x573970['start'])?-0x1:_0x33b8db['start']['isAfter'](_0x573970['start'])?0x1:_0x33b8db['end']['isBefore'](_0x573970['end'])?-0x1:_0x33b8db['end']['isAfter'](_0x573970['end'])?0x1:'add'===_0x2ffd34['type']?-0x1:0x1;}),{'root':_0x4b3b8c,'changes':_0x32b519};function _0x1ed553(_0x38675a,_0xd60c89,_0xae5aa2,_0x1624d5){const _0xd32d=!!_0x1a3840[_0xd60c89][_0x38675a],_0xb50e55=_0xd32d?_0x1a3840[_0xd60c89][_0x38675a]['userId']:null,_0x5527ff=_0xd60c89===_0x1a3840['length']-0x1,_0x59a6d2=_0x22eb1b[_0x38675a][0x0],_0x43ef04=_0x3b8a7c['isObject'](_0x1a3840[_0xd60c89]['item']);!_0x40b2b5[_0x38675a]&&_0xd32d?_0x40b2b5[_0x38675a]={'start':_0xae5aa2,'tapeItem':_0x1a3840[_0xd60c89],'userId':_0xb50e55,'type':_0x38675a}:_0x40b2b5[_0x38675a]&&!_0xd32d?(_0x40b2b5[_0x38675a]['end']=_0xae5aa2,_0x525459(_0x40b2b5[_0x38675a]),_0x40b2b5[_0x38675a]=null):_0x40b2b5[_0x38675a]&&_0xd32d&&_0x40b2b5[_0x38675a]['userId']!==_0xb50e55&&(_0x40b2b5[_0x38675a]['end']=_0xae5aa2,_0x59a6d2&&_0x59a6d2['userId']===_0x40b2b5[_0x38675a]['userId']||_0x525459(_0x40b2b5[_0x38675a]),_0x40b2b5[_0x38675a]={'start':_0xae5aa2,'tapeItem':_0x1a3840[_0xd60c89],'userId':_0xb50e55,'type':_0x38675a}),_0x40b2b5[_0x38675a]&&_0x43ef04&&('elementStart'!==_0x1a3840[_0xd60c89]['type']||_0x59a6d2&&_0x59a6d2['userId']===_0xb50e55||_0x22eb1b[_0x38675a]['unshift']({'userId':_0xb50e55,'object':_0x1a3840[_0xd60c89]['item'],'change':_0x40b2b5[_0x38675a]}),'elementEnd'===_0x1a3840[_0xd60c89]['type']&&_0x59a6d2&&_0x59a6d2['object']===_0x1a3840[_0xd60c89]['item']&&(_0x22eb1b[_0x38675a]['shift'](),_0x40b2b5[_0x38675a]=_0x59a6d2['change'])),_0x40b2b5[_0x38675a]&&_0x5527ff&&(_0x40b2b5[_0x38675a]['end']=_0x1624d5,_0x525459(_0x40b2b5[_0x38675a]),_0x40b2b5[_0x38675a]=null);}function _0x525459({start:_0x283b30,end:_0x4deddd,tapeItem:_0x1dc184,userId:_0x56900b,type:_0x3031a9}){const _0x30ee61=_0x1dc184['item'],_0x44b9da=_0x21d54b['schema']['isBlock'](_0x30ee61)&&!_0x21d54b['schema']['isLimit'](_0x30ee61),_0xf87f27=_0x283b30['nodeAfter']==_0x4deddd['parent']&&_0x4deddd['isAtStart'];if(_0x44b9da&&_0xf87f27)return;const _0x32392e=_0x21d54b['createRange'](_0x283b30,_0x4deddd),_0x2022f1=_0xee0ec2['get'](_0x56900b),_0x23e83c=new G({'author':_0x2022f1,'type':'isAdded'==_0x3031a9||'isAddSuggestion'==_0x3031a9?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x3031a9||'isRemoveSuggestion'==_0x3031a9},'createdAt':new Date(),'rootName':_0x49947c});_0x32b519['push'](_0x23e83c),_0x4b3b8c['markers']['set']('revision:'+_0x23e83c['id'],_0x32392e);}function _0x2272a0(_0x4f482d,_0x2e0a99){const _0x181453=_0x4f482d['getAttributes'](),_0x1cb2dd=_0x2e0a99['getAttributes']();for(const _0x5538ed of _0x181453){if(_0x5538ed[0x1]!==_0x2e0a99['getAttribute'](_0x5538ed[0x0]))return!0x1;_0x1cb2dd['next']();}return _0x1cb2dd['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x332117=>{const _0x58f906=_0x332117['markerName']['split'](':')[0x1],_0x4a78ec=this['_getChangeFromId'](_0x58f906);if(!_0x4a78ec)return null;const _0x4b0ec1='add'==_0x4a78ec['type']?'insertion':'deletion',_0x1b9a1c=['ck-suggestion-marker','ck-suggestion-marker-'+_0x4b0ec1];return _0x4a78ec['data']['isSuggestion']&&_0x1b9a1c['push']('ck-suggestion-marker-'+_0x4b0ec1+'-new'),this['activeChange']==_0x4a78ec&&_0x1b9a1c['push']('ck-suggestion-marker--active'),{'classes':_0x1b9a1c,'attributes':{'data-change-id':_0x58f906}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x3799ee=>{_0x3799ee['on']('element:pre',(_0x1e410d,_0x439a23,_0x5ba9da)=>{const _0xcb75c2=_0x439a23['viewItem']['getChild'](0x0);if(!_0xcb75c2||!_0xcb75c2['is']('element','code'))return;if(!_0x5ba9da['consumable']['consume'](_0xcb75c2,{'attributes':['vid_start','vid_end']}))return;const _0x3c39bd=_0x439a23['modelRange']['start']['nodeAfter'];_0x5ba9da['writer']['setAttribute']('vid_start',_0xcb75c2['getAttribute']('vid_start'),_0x3c39bd),_0x5ba9da['writer']['setAttribute']('vid_end',_0xcb75c2['getAttribute']('vid_end'),_0x3c39bd);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x280a9f=>{_0x280a9f['on']('element',(_0xcd21b5,_0x13e1cb,_0x27c6e1)=>{if(!_0x27c6e1['consumable']['consume'](_0x13e1cb['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x13e1cb['modelRange']['isCollapsed'])return;const _0xf352ce=_0x13e1cb['modelRange']['start']['nodeAfter'];_0xf352ce['hasAttribute']('vid_start')||_0xf352ce['hasAttribute']('vid')||(_0x27c6e1['writer']['setAttribute']('vid_start',_0x13e1cb['viewItem']['getAttribute']('vid_start'),_0xf352ce),_0x27c6e1['writer']['setAttribute']('vid_end',_0x13e1cb['viewItem']['getAttribute']('vid_end'),_0xf352ce));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x1bd09e=>_0x1bd09e['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x41baec,[,_0x3c8c5e])=>{['vid_start','vid_end','vid']['includes'](_0x3c8c5e)&&(_0x41baec['return']=!0x0,_0x41baec['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x24ad4b=>{_0x24ad4b['on']('attribute:vid',(_0x25b26b,_0x598151,_0x1b81c5)=>{if('\x20'!=_0x598151['item']['data']||_0x598151['item']['parent']['maxOffset']>0x1)return;if(!_0x1b81c5['consumable']['consume'](_0x598151['item'],_0x25b26b['name']))return;const _0x1e3558=_0x1b81c5['writer'],_0x17c118=_0x1b81c5['mapper']['toViewRange'](_0x598151['range']);_0x1e3558['wrap'](_0x17c118,_0x1e3558['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x2b5eb9){const _0x3fdd37=_0x2b5eb9['plugins']['get']('RevisionViewer');return(_0x1b9999,_0x306fa5,_0x3acc3c)=>{const _0x140ffc=_0x306fa5['markerName']['split'](':')[0x1],_0x349bd6=_0x3fdd37['_getChangeFromId'](_0x140ffc);if(!_0x349bd6)return null;const _0x553908='add'==_0x349bd6['type']?'split':'merge';if(!_0x3acc3c['consumable']['test'](_0x306fa5['markerRange'],_0x1b9999['name']))return;const _0x47438d=_0x306fa5['markerRange']['getWalker'](),_0x3ecf98=_0x306fa5['markerRange']['start'],_0x3e8e4b=_0x2b5eb9['model']['schema'];let _0x1db888=null,_0xf4f75b=null,_0x46fdbe=!0x1,_0x429840=!0x1;for(const _0x1a17dd of _0x47438d){const _0x534048=_0x1a17dd['item'];_0x46fdbe=_0x46fdbe||_0x3e8e4b['isContent'](_0x534048);const _0x2968e7=_0x3acc3c['mapper']['toViewElement'](_0x534048);if(_0x2968e7&&_0x2968e7['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x1a17dd['type']&&(_0x3e8e4b['isBlock'](_0x534048)&&!_0x3e8e4b['isLimit'](_0x534048)&&(_0x534048['nextSibling']||_0x3ecf98['isAtEnd']?_0x1db888&&_0x1db888['parent']==_0x534048||(_0x1db888=_0x534048,_0x38db05(_0x1a17dd['previousPosition']),_0x429840=!0x0):_0xf4f75b=_0xf4f75b||_0x1a17dd['previousPosition']));}function _0x38db05(_0x32d09f){const _0x503a7d=_0x3acc3c['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x553908}),_0x216760=_0x3acc3c['mapper']['toViewPosition'](_0x32d09f);_0x349bd6['data']['isSuggestion']&&_0x3acc3c['writer']['addClass']('ck-suggestion-marker-'+_0x553908+'-new',_0x503a7d),_0x3fdd37['activeChange']==_0x349bd6&&_0x3acc3c['writer']['addClass']('ck-suggestion-marker--active',_0x503a7d),_0x3acc3c['writer']['insert'](_0x216760,_0x503a7d),_0x3acc3c['mapper']['bindElementToMarker'](_0x503a7d,_0x306fa5['markerName']);}_0x46fdbe||_0x429840||!_0xf4f75b||_0x38db05(_0xf4f75b);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x1de37b,_0x422c76,_0x310b71)=>{const _0x2769e2=_0x310b71['mapper']['markerNameToElements'](_0x422c76['markerName']);if(_0x2769e2){for(const _0x424144 of _0x2769e2)(_0x424144['hasClass']('ck-suggestion-marker-split')||_0x424144['hasClass']('ck-suggestion-marker-merge'))&&(_0x310b71['mapper']['unbindElementFromMarkerName'](_0x424144,_0x422c76['markerName']),_0x310b71['writer']['remove'](_0x424144));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x58c5e8,_0x604dbc,_0x224b5b)=>{const _0x5d10c3=_0x604dbc['markerName']['split'](':')[0x1],_0xb2a7b8=this['_getChangeFromId'](_0x5d10c3);if(!_0xb2a7b8)return null;const _0x3f9a2d='add'==_0xb2a7b8['type']?'split':'merge';if(_0x224b5b['consumable']['test'](_0x604dbc['markerRange'],_0x58c5e8['name']))for(const _0x31775d of _0x604dbc['markerRange']['getItems']()){if(!_0x31775d['is']('element','softBreak'))continue;const _0x14fd0b=_0x224b5b['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x3f9a2d}),_0x3c9834=_0x224b5b['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x31775d));_0xb2a7b8['data']['isSuggestion']&&_0x224b5b['writer']['addClass']('ck-suggestion-marker-'+_0x3f9a2d+'-new',_0x14fd0b),this['activeChange']==_0xb2a7b8&&_0x224b5b['writer']['addClass']('ck-suggestion-marker--active',_0x14fd0b),_0x224b5b['writer']['insert'](_0x3c9834,_0x14fd0b),_0x224b5b['mapper']['bindElementToMarker'](_0x14fd0b,_0x604dbc['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0xb41f71=>{for(const _0x326054 of this['editor']['model']['document']['getRootNames']()){const _0x368c97=this['editor']['model']['document']['getRoot'](_0x326054),_0x59272b=this['editor']['editing']['view']['document']['getRoot'](_0x326054);if(_0x59272b){const _0x905181=_0x368c97['getAttribute']('revisionHistoryAttachChange');if(_0xb41f71['removeAttribute']('data-change-id',_0x59272b),_0xb41f71['removeClass']('ck-revision-history-root-add',_0x59272b),_0xb41f71['removeClass']('ck-revision-history-root-remove',_0x59272b),_0xb41f71['removeClass']('ck-revision-history-root--active',_0x59272b),_0x905181){const _0x13ea58=this['_getChangeFromId'](_0x905181);if(!_0x13ea58)return null;_0xb41f71['setAttribute']('data-change-id',_0x905181,_0x59272b),_0xb41f71['addClass']('ck-revision-history-root-'+_0x13ea58['type'],_0x59272b),this['activeChange']==_0x13ea58&&_0xb41f71['addClass']('ck-revision-history-root--active',_0x59272b);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x2529b7=>'revision-comment:'+_0x2529b7,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x459af8=>'revision-suggestion:'+_0x459af8,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x1d3b83=>({'name':'suggestion:'+_0x1d3b83,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x223236=>{const _0x5dec9a=_0x223236['markerName']['split'](':')[0x1];return'insertion'!=_0x5dec9a&&'deletion'!=_0x5dec9a?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x5dec9a]};}}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:deletion',Q(this['editor'],'merge'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:insertion',Q(this['editor'],'split'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision-suggestion',(_0x515361,_0x530aa3,_0x2f58e1)=>{const _0x212df6=_0x2f58e1['mapper']['markerNameToElements'](_0x530aa3['markerName']);if(_0x212df6){for(const _0x433281 of _0x212df6)_0x433281['is']('uiElement')&&(_0x2f58e1['mapper']['unbindElementFromMarkerName'](_0x433281,_0x530aa3['markerName']),_0x2f58e1['writer']['remove'](_0x433281));}},{'priority':'high'});}['_getChangeFromId'](_0x51962c){return this['_changeIdToChange']['get'](_0x51962c);}['_getViewForChange'](_0x23f250){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new z(this['editor']['locale'],_0x23f250),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x44bf82,_0x2d7129,_0x220c31,_0x2ed55c)=>{_0x2ed55c&&this['_balloon']['remove'](_0x2ed55c),_0x220c31&&(this['_balloon']['add']({'view':_0x220c31,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x2fa278=this['editor']['editing'],_0xe796d6=this['_getChangeFromId'](_0x220c31['changeId']);let _0x34ac77;if(_0xe796d6['data']['isOnRoot']){const _0x4f76f0=_0x2fa278['view']['getDomRoot'](_0xe796d6['rootName']);_0x34ac77=Array['from'](_0x4f76f0['getClientRects']());}else{const _0x207eb1=this['editor']['model']['markers']['get']('revision:'+_0x220c31['changeId']);_0x34ac77=Array['from'](_0x2fa278['mapper']['markerNameToElements'](_0x207eb1['name']))['map'](_0x1f6531=>_0x2fa278['view']['domConverter']['mapViewToDom'](_0x1f6531))['map'](_0x4180dd=>Array['from'](_0x4180dd['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x34ac77[0x0];return _0x34ac77['find'](_0x3b359b=>_0x3b359b['top']-0x3<=this['_activeViewTarget']['y']&&_0x3b359b['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x3b359b['left']-0x3<=this['_activeViewTarget']['x']&&_0x3b359b['right']+0x3>=this['_activeViewTarget']['x'])||_0x34ac77[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x2cda9f,_0x4ad579,_0x18799b,_0x2a6553)=>{this['activeView']=_0x18799b?this['_getViewForChange'](_0x18799b):null,this['editor']['model']['change'](()=>{const _0x3c5cf9=this['editor']['editing'];_0x2a6553&&(_0x2a6553['data']['isOnRoot']?_0x3c5cf9['view']['change'](_0x1c016b=>{_0x1c016b['removeClass']('ck-revision-history-root--active',_0x3c5cf9['view']['document']['getRoot'](_0x2a6553['rootName']));}):_0x3c5cf9['reconvertMarker']('revision:'+_0x2a6553['id'])),_0x18799b&&(_0x18799b['data']['isOnRoot']?_0x3c5cf9['view']['change'](_0x4b4c60=>{_0x4b4c60['addClass']('ck-revision-history-root--active',_0x3c5cf9['view']['document']['getRoot'](_0x18799b['rootName']));}):_0x3c5cf9['reconvertMarker']('revision:'+_0x18799b['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x2fd6c0,_0x42125e)=>{if(this['activeChange'])return;const _0x1191fa=this['_findChangeIdFromDomTarget'](_0x42125e['target']),_0x2dba7d=this['_changeIdToChange']['get'](_0x1191fa);_0x2dba7d?(this['_activeViewTarget']={'x':_0x42125e['domEvent']['x'],'y':_0x42125e['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x2dba7d)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x110588,_0x265cb8)=>{const _0x1eb657=this['_findChangeIdFromDomTarget'](_0x265cb8['target']),_0x384fcf=this['_changeIdToChange']['get'](_0x1eb657);_0x384fcf?(this['_activeViewTarget']={'x':_0x265cb8['domEvent']['x'],'y':_0x265cb8['domEvent']['y']},_0x384fcf===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x384fcf):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x56d381){do{const _0x395786=_0x56d381['getAttribute']('data-change-id');if(_0x395786)return _0x395786;_0x56d381=_0x56d381['parent'];}while(_0x56d381);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x4d69c6=>{for(const _0x2295df of this['editor']['model']['markers'])_0x4d69c6['removeMarker'](_0x2295df);});}}function Q(_0xafb4e0,_0x2a6b39){return(_0x35ed94,_0x3b3d0c,_0x4e2ded)=>{if(!_0x4e2ded['consumable']['test'](_0x3b3d0c['markerRange'],_0x35ed94['name']))return;const _0x4ab2d5=_0x3b3d0c['markerRange']['getWalker'](),_0x59e927=_0x3b3d0c['markerRange']['start'],_0x3c3b97=_0xafb4e0['model']['schema'];let _0x524bb6=null,_0x54f1fa=null,_0x1a1566=!0x1,_0x2c54d2=!0x1;for(const _0x1c6512 of _0x4ab2d5){const _0x3033ea=_0x1c6512['item'];_0x1a1566=_0x1a1566||_0x3c3b97['isContent'](_0x3033ea);const _0xa0e262=_0x4e2ded['mapper']['toViewElement'](_0x3033ea);if(_0xa0e262&&_0xa0e262['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x1c6512['type']&&(_0x3c3b97['isBlock'](_0x3033ea)&&!_0x3c3b97['isLimit'](_0x3033ea)&&(_0x3033ea['nextSibling']||_0x59e927['isAtEnd']?_0x524bb6&&_0x524bb6['parent']==_0x3033ea||(_0x524bb6=_0x3033ea,_0x306276(_0x1c6512['previousPosition']),_0x2c54d2=!0x0):_0x54f1fa=_0x54f1fa||_0x1c6512['previousPosition']));}function _0x306276(_0xcfe5d){const _0x3326cc=_0x4e2ded['mapper']['toViewPosition'](_0xcfe5d),_0x1581b3=_0x4e2ded['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x2a6b39});_0x4e2ded['writer']['insert'](_0x3326cc,_0x1581b3),_0x4e2ded['mapper']['bindElementToMarker'](_0x1581b3,_0x3b3d0c['markerName']);}_0x1a1566||_0x2c54d2||!_0x54f1fa||_0x306276(_0x54f1fa);};}class ut extends _0x52166d{constructor(_0xeb7fec){super(_0xeb7fec);const _0xbe0a77=_0xeb7fec['plugins']['get'](l);this['affectsData']=!0x1,this['listenTo'](_0xbe0a77,'change:isReady',()=>this['refresh']()),this['listenTo'](_0xbe0a77,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x52d281=this['editor'],_0x5c8352=_0x52d281['plugins']['get'](l),_0x4ed2c9=_0x5c8352['isReady']?_0x5c8352['diff']['newRevisionId']:null;_0x52d281['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x4ed2c9);}['refresh'](){const {isReady:_0x148c67,isEnabled:_0x3ec758,repository:_0x5dab21,diff:_0x39f62d}=this['editor']['plugins']['get'](l),_0x298bf8=_0x39f62d&&_0x5dab21['getLaterVisibleRevision'](_0x39f62d['newRevisionId']);this['isEnabled']=_0x148c67&&_0x3ec758&&Boolean(_0x298bf8);}}class lt extends _0x52166d{['_step'];constructor(_0x4e0fe5,{direction:_0x1b1359}){super(_0x4e0fe5);const _0x3097e5=_0x4e0fe5['plugins']['get'](l);this['affectsData']=!0x1,this['_step']='forward'===_0x1b1359?0x1:-0x1,this['listenTo'](_0x3097e5,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x3097e5,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x3097e5,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x27c156=this['editor'],_0x4aa107=_0x27c156['plugins']['get'](l),{isNavigationMode:_0x1bc78e,currentChangeNumber:_0x170c49}=_0x4aa107;let _0x5f2742;if(_0x4aa107['activeChange']=_0x1bc78e?_0x4aa107['diff']['changes']['get'](_0x170c49+this['_step']):_0x4aa107['diff']['changes']['first'],_0x4aa107['activeChange']['data']['isOnRoot'])_0x5f2742=_0x27c156['editing']['view']['getDomRoot'](_0x4aa107['activeChange']['rootName']);else{const _0x41b0a7=_0x27c156['model']['markers']['get']('revision:'+_0x4aa107['activeChange']['id']);_0x5f2742=_0x455182(_0x27c156['editing'],_0x41b0a7);}_0xe286a({'target':_0x5f2742,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x500b1a,currentChangeNumber:_0x55cb1e,numberOfChanges:_0x1f5e71,isReady:_0x36b7d8,isEnabled:_0x3ced1b}=this['editor']['plugins']['get'](l);this['isEnabled']=!!(_0x3ced1b&&_0x36b7d8&&_0x1f5e71)&&(!_0x500b1a||(0x1===this['_step']?_0x55cb1e<_0x1f5e71-0x1:_0x55cb1e>0x0));}}class Ri extends _0x52b0b2{constructor(_0x4506dc){super(_0x4506dc);const _0x21429a=this['bindTemplate'],_0x1e6b00=new _0x3c378a(_0x4506dc),_0x2594e9=new _0x3c378a(_0x4506dc);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',(_0xbee70b,_0x136389)=>_0xbee70b&&_0x136389>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x25cf8c,_0x536ee7,_0x9ef816,_0x8de97a)=>{if(!_0x25cf8c)return R(_0x4506dc,'Loading...');if(!_0x9ef816)return R(_0x4506dc,'No\x20changes');const _0x27d88f=R(_0x4506dc,'NUMBER_OF_CHANGES',_0x9ef816);return _0x8de97a?R(_0x4506dc,'X_OF_Y_CHANGES',[_0x536ee7+0x1,_0x9ef816]):_0x27d88f;}),_0x1e6b00['set']({'label':R(_0x4506dc,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x1bcada}),_0x2594e9['set']({'label':R(_0x4506dc,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x32e08a}),_0x1e6b00['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x2594e9['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x1e6b00['on']('execute',()=>this['fire']('execute','backward')),_0x2594e9['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',_0x21429a['if']('_isStatusLabelVisible','ck-hidden',_0x39194e=>!_0x39194e)]},'children':[{'text':_0x21429a['to']('isNavigationMode',_0x429b72=>_0x429b72?R(_0x4506dc,'EDIT_X_OF_Y_REVISIONS')+':\x20':R(_0x4506dc,'Total')+':\x20')}]},{'text':_0x21429a['to']('_statusText')}]},new _0x34c55a(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x1e6b00,_0x2594e9]}]});}}const ge='ck-editor__editable__loading-overlay';class ji extends _0x49c0fc{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x239596=this['editor']['editing']['view'];_0x239596['change'](_0xaf19c5=>{for(const _0x21cb7b of _0x239596['document']['roots'])_0xaf19c5['addClass'](ge,_0x21cb7b);});}['hide'](){const _0x63fa39=this['editor']['editing']['view'];_0x63fa39['change'](_0x591ba5=>{for(const _0x438f2a of _0x63fa39['document']['roots'])_0x591ba5['removeClass'](ge,_0x438f2a);});}}class u extends _0x49c0fc{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l,ji];}['init'](){const _0x88cd86=this['editor'],_0x89263e=_0x88cd86['plugins']['get'](l),_0x387e92=_0x88cd86['plugins']['get'](ji);_0x88cd86['ui']['componentFactory']['add']('exitToEditing',_0x4fd872=>{const _0x264d55=new _0x3c378a(_0x4fd872);return _0x264d55['set']({'label':R(_0x4fd872,'Back\x20to\x20editing'),'icon':_0x408ae0,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x264d55,'execute',()=>{_0x88cd86['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x264d55;}),_0x88cd86['ui']['componentFactory']['add']('restoreRevision',_0x5da1bb=>{const _0x3e412c=new _0x3c378a(_0x5da1bb);return _0x3e412c['set']({'label':R(_0x5da1bb,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x3e412c['bind']('isEnabled')['to'](_0x88cd86['commands']['get']('restoreRevision')),this['listenTo'](_0x3e412c,'execute',()=>_0x88cd86['execute']('restoreRevision')),_0x3e412c;}),_0x88cd86['ui']['componentFactory']['add']('changesNavigation',_0xb8690e=>{const _0x1b69e1=new Ri(_0xb8690e),_0x51b678=_0x88cd86['commands']['get']('showPreviousChange'),_0x1d33f4=_0x88cd86['commands']['get']('showNextChange');return _0x1b69e1['bind']('isBackwardNavigationEnabled')['to'](_0x51b678,'isEnabled'),_0x1b69e1['bind']('isForwardNavigationEnabled')['to'](_0x1d33f4,'isEnabled'),_0x1b69e1['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x89263e),this['listenTo'](_0x1b69e1,'execute',(_0x2ee20f,_0x2f355e)=>{_0x88cd86['execute']('forward'===_0x2f355e?'showNextChange':'showPreviousChange');}),_0x1b69e1;}),_0x387e92['show'](),_0x89263e['on']('change:isReady',(_0x54b29c,_0x5894aa,_0x1dfeea)=>{_0x1dfeea?_0x387e92['hide']():_0x387e92['show']();});}}class hi extends et{['_resizeObserver']=null;constructor(_0x19fa40,_0x1fdf7f){super(_0x19fa40,_0x1fdf7f);const _0x2486a4=this['bindTemplate'];this['set']({'label':R(_0x19fa40,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=R(_0x19fa40,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x2486a4['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 _0xe9fa16=this['fieldView']['element'];this['_tooltipString']=_0xe9fa16['scrollWidth']>_0xe9fa16['clientWidth']&&_0xe9fa16['value']||'';}}class ni extends _0x52b0b2{constructor(_0x1a5a40,_0x19a3ab,_0x260fb4){super(_0x1a5a40);const _0xbb222e=new _0xc5dda1();_0xbb222e['set']({'content':_0x1d5032,'viewBox':'0\x200\x2011\x2010'});const _0x3f9e2b=['ck','ck-revision-history-sidebar__revision-author'];_0x260fb4&&_0x3f9e2b['push']('ck-revision-history-sidebar__revision-author_creator');const _0x1625d6=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':R(_0x1a5a40,_0x260fb4?'Revision\x20creator':'Revision\x20author')},'children':[_0xbb222e,_0x19a3ab['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x3f9e2b},'children':_0x1625d6});}}function ci(_0x3045f9,_0x5a440a){const _0x496ab4=_0x3045f9['bindTemplate'],_0x59fc45=_0x3045f9['locale'],_0x174fd7=_0x4933a7(_0x59fc45);_0x174fd7['panelPosition']='sw';const _0x5e6d0=function(_0x35b190,_0x1dfb92){const _0x5b757c=function(_0x155f02,_0x8c1fe0){const _0x21b700=_0x155f02['locale'],_0x126f55={'Compare\x20against\x20selected':R(_0x21b700,'Compare\x20against\x20selected'),'Name\x20this\x20revision':R(_0x21b700,'Name\x20this\x20revision'),'Restore\x20this\x20revision':R(_0x21b700,'Restore\x20this\x20revision')};return _0x8c1fe0['map'](_0x346169=>{const _0x387ae9=_0x126f55[_0x346169['name']];return _0x387ae9&&_0x387ae9!==_0x346169['name']&&(_0x346169['name']=_0x387ae9),_0x346169;});}(_0x35b190,_0x1dfb92),_0x1db8fb=new _0x5351d9();for(const _0x51b5ff of _0x5b757c){const _0xe1c804={'type':'button','model':new to({'label':_0x51b5ff['name'],'class':_0x51b5ff['class'],'withText':!0x0,'role':'menuitem','_action':_0x51b5ff['action']})};_0xe1c804['model']['bind']('isEnabled')['to'](_0x35b190,'isActionsDropdownOpen',_0x3eedcf=>'function'!=typeof _0x51b5ff['isEnabled']||(!_0x3eedcf||_0x51b5ff['isEnabled'](_0x35b190))),_0x1db8fb['add'](_0xe1c804);}return _0x1db8fb;}(_0x3045f9,_0x5a440a);return _0x3045f9['bind']('isActionsDropdownOpen')['to'](_0x174fd7,'isOpen'),_0x174fd7['buttonView']['set']({'label':R(_0x59fc45,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x503d3e}),_0x174fd7['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x496ab4['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x496ab4['to'](_0x74dcbc=>_0x74dcbc['stopPropagation']())}}),_0x174fd7['on']('execute',_0x376a89=>{_0x3045f9['isReady']&&'function'==typeof _0x376a89['source']['_action']&&_0x376a89['source']['_action'](_0x3045f9);}),_0x3686ed(_0x174fd7,_0x5e6d0,{'role':'menu'}),_0x174fd7['listenTo'](_0x3045f9,'change:isActionsDropdownOpen',(_0x4c0b6d,_0x4f31ba,_0x14fb0c)=>{if(_0x14fb0c)for(const _0x26060c of _0x174fd7['listView']['items']){const _0xf89eae=_0x26060c['children']['first'],_0x559de0=_0x5a440a['find'](_0x2f26bb=>_0x2f26bb['action']===_0xf89eae['_action'])['isVisible'];_0x26060c['isVisible']=void 0x0===_0x559de0||_0x559de0(_0x3045f9);}}),_0x174fd7;}class _i extends/* #__PURE__ -- @preserve */
27
- _0x43c7e1(_0x52b0b2){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x411d6b,_0xd2cce2,_0x346634,_0x1b7d74){super(_0x411d6b);const _0x144e03=this['bindTemplate'],_0x10f0ab=function(_0x216b7c,_0x2f25f0){const _0x233b55=Array['from'](_0x2f25f0['authors'])['filter'](_0x4dbee4=>_0x4dbee4!=_0x2f25f0['creator']);return _0x2f25f0['creator']&&_0x233b55['unshift'](_0x2f25f0['creator']),_0x233b55['map'](_0x3d6a1f=>new ni(_0x216b7c,_0x3d6a1f,_0x3d6a1f==_0x2f25f0['creator']));}(_0x411d6b,_0xd2cce2);this['id']=_0xd2cce2['id'],this['_revision']=_0xd2cce2,this['_requireRevisionName']=_0x1b7d74,this['bind']('name','createdAt')['to'](_0xd2cce2),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x49cac9=>{return _0x5d815d=_0x411d6b['uiLanguage'],(_0x342566=_0x49cac9)['toLocaleDateString'](_0x5d815d,{'month':'long','day':'numeric'})+',\x20'+_0x342566['toLocaleTimeString'](_0x5d815d,{'hour':'numeric','minute':'numeric'});var _0x5d815d,_0x342566;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new hi(_0x411d6b,ti),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x513e47=>_0x513e47||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x5efa51,_0xaa12db)=>_0x5efa51&&_0xaa12db),this['revisionActionsView']=_0x346634&&_0x346634['length']?ci(this,_0x346634):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x144e03['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x144e03['if']('isEnabled','ck-disabled',_0x472c4b=>!_0x472c4b),_0x144e03['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x144e03['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x144e03['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':_0x144e03['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':_0x10f0ab}]},this['revisionActionsView']],'on':{'click':_0x144e03['to'](_0x2d8312=>{_0x2d8312['srcElement']['closest']('.ck-thread__remove-confirm')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x6e4a12=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x6e4a12,'change',()=>{this['_requireRevisionName']&&!_0x6e4a12['value']||this['fire']('setName',{'id':this['id'],'name':_0x6e4a12['value']}),_0x6e4a12['value']||(_0x6e4a12['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(_0x1fbcb1,_0x5ab3de){const _0xd6bb6a=_0x3dd3d2['fromJSDate'](_0x1fbcb1)['setLocale'](_0x5ab3de),_0x29c7e9=_0x3dd3d2['local'](),_0x568caa=_0x29c7e9['minus']({'days':0x1})['startOf']('day');let _0x9f7a1a,_0x9673b9;return _0xd6bb6a['hasSame'](_0x29c7e9,'day')?(_0x9f7a1a=_0xd6bb6a['startOf']('day')['toJSDate'](),_0x9673b9=_0xd6bb6a['toRelativeCalendar']()):_0xd6bb6a['hasSame'](_0x568caa,'day')?(_0x9f7a1a=_0x568caa['toJSDate'](),_0x9673b9=_0xd6bb6a['toRelativeCalendar']()):_0xd6bb6a['hasSame'](_0x29c7e9,'week')?(_0x9f7a1a=_0xd6bb6a['startOf']('week')['toJSDate'](),_0x9673b9=_0xd6bb6a['weekdayLong']||''):_0xd6bb6a['hasSame'](_0x29c7e9,'year')?(_0x9f7a1a=_0xd6bb6a['startOf']('month')['toJSDate'](),_0x9673b9=_0xd6bb6a['monthLong']||''):(_0x9f7a1a=_0xd6bb6a['startOf']('year')['toJSDate'](),_0x9673b9=String(_0xd6bb6a['year'])),{'startDate':_0x9f7a1a,'localizedPeriodName':_0x9673b9};}class bi extends _0x52b0b2{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x47b5a0,_0x13c912,_0x26b7eb,_0x1523c2){super(_0x47b5a0);const _0x595ec6=li(_0x13c912,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x13c912,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x26b7eb,this['_requireRevisionName']=_0x1523c2,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':_0x595ec6}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x4c79b1){const _0x85e2af=new _i(this['locale'],_0x4c79b1,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x85e2af);}['removeRevision'](_0x395212){const _0x3a62dc=this['revisionViews']['find'](_0x55bd89=>_0x55bd89['id']===_0x395212['id']);this['revisionViews']['remove'](_0x3a62dc);}}class fi extends _0x52b0b2{constructor(_0x22fdc6){super(_0x22fdc6);const _0x550d18=new _0xc5dda1();_0x550d18['content']=_0x4269eb,this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x550d18,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[R(_0x22fdc6,'Revision\x20history')]}]});}}class di extends _0x52b0b2{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x2eb811,_0x1d8d3d,_0x42f95e,_0x114520){super(_0x2eb811);const _0x1f59f6=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x1d8d3d,this['_revisionActions']=_0x42f95e,this['_requireRevisionName']=_0x114520,this['on']('select',(_0x3006bf,_0x3766a1)=>{this['fire']('revisionSelected',_0x3766a1);}),this['on']('setName',(_0x3b065f,_0x4e5ae1)=>{this['fire']('revisionSetName',_0x4e5ae1);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new fi(_0x2eb811),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x1f59f6['if']('isEnabled','ck-disabled',_0x4acfbf=>!_0x4acfbf)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x5e03ba of this['_revisions'])this['_addRevision'](_0x5e03ba);this['_revisions']['on']('add',(_0x22f9e5,_0xd21223)=>{this['_addRevision'](_0xd21223);}),this['_revisions']['on']('remove',(_0x3eb845,_0x230648)=>{this['_removeRevision'](_0x230648);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x63a1f5=>_0x63a1f5['revisionViews']['map'](_0x2f7b97=>_0x2f7b97))['flat']();}['selectRevision'](_0x885090){for(const _0x319b9e of this['revisionViews'])_0x885090&&_0x885090['id']===_0x319b9e['id']?_0x319b9e['select']():_0x319b9e['deselect']();}['highlightRevisions'](_0x5665db){for(const _0x5e397d of this['revisionViews'])_0x5665db['some'](({id:_0x291dbc})=>_0x291dbc===_0x5e397d['id'])?_0x5e397d['highlight']():_0x5e397d['unhighlight']();}['_addRevision'](_0xf8f6f9){const _0x56f506=li(_0xf8f6f9['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x505c99=this['timePeriodViews']['get'](0x0);_0x505c99&&_0x505c99['startDate']['getTime']()===_0x56f506['getTime']()||(_0x505c99=new bi(this['locale'],_0x56f506,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x505c99)),_0x505c99['addRevision'](_0xf8f6f9);}['_removeRevision'](_0x2d9403){const _0x2ccdd3=li(_0x2d9403['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x2ccdd3)['removeRevision'](_0x2d9403);}['_getTimePeriodViewByStartDate'](_0x2b93ba){return this['timePeriodViews']['find'](_0x5897e3=>_0x5897e3['startDate']['getTime']()===_0x2b93ba['getTime']());}}class f extends _0x49c0fc{['_revisionViewer'];['_revisionsRepository'];['_sidebarView'];static ['defaultRevisionActions']=/* #__PURE__ -- @preserve */
23
+ import{ObservableMixin as _0x208a0d,uid as _0x17ccda,Collection as _0x2e7af1,logWarning as _0x10c5ab,FocusTracker as _0x5edbfd,KeystrokeHandler as _0x389bed,scrollViewportToShowTarget as _0x5c62f,ResizeObserver as et,ElementReplacer as it,CKEditorError as _0x3a46b6}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x5d7334,set as _0x59cccf,unset as _0x4f119a,isEqual as _0x2dbdeb}from'es-toolkit/compat';import{Plugin as _0x3a7117,PendingActions as _0x178404,Command as _0x2a2d7a,ElementApiMixin as _0x28a0f5,Editor as _0x5c66f2}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x315441,getMarkerDomElement as _0x56f66f,ConfirmMixin as _0xe95daa,sanitizeEditorConfig as _0x4cde83}from'ckeditor5-collaboration/dist/index.js';import{ViewContainerElement as _0x49f7fb,ViewAttributeElement as _0x319301,ViewEmptyElement as _0x56653d,ViewRawElement as _0x4b14f6,ViewUIElement as _0x3dc868,ViewDocumentFragment as _0x5c6a22,ViewText as _0x14b7d4,ViewElement as _0x3421ca,ModelElement as _0x17ffdc,ModelRange as _0x4fa97a,ModelPosition as _0x3b6bf5,ModelDocumentFragment as _0x3dd9df,ModelText as _0xedef05}from'@ckeditor/ckeditor5-engine/dist/index.js';import{IconHistory as _0x80b955,IconChevronUp as _0x24bb4f,IconChevronDown as _0x3a97a7,IconUndo as _0x3772c5,IconUser as _0xb4cbd9,IconThreeVerticalDots as _0x357701}from'@ckeditor/ckeditor5-icons/dist/index.js';import{CssTransitionDisablerMixin as _0x380409,View as _0x49001e,submitHandler as _0xfab003,LabeledFieldView as ti,createLabeledInputText as _0x1f20a,createDropdown as _0x546af5,ListView as _0x3694dd,ListItemView as _0x4af6be,ButtonView as _0x356661,MenuBarMenuView as _0x2037e5,MenuBarMenuListView as _0x40df4f,MenuBarMenuListItemView as _0x1c4f9c,MenuBarMenuListItemButtonView as _0x1e03e7,ContextualBalloon as _0x46b4da,ToolbarSeparatorView as _0x4da8fb,IconView as _0x3d47ac,addListToDropdown as _0x58c2ad,UIModel as to,EditorUI as tt,normalizeToolbarConfig as st,BoxedEditorUIView as _0x4c6a60,StickyPanelView as _0x32d525,ToolbarView as _0x3da8a5,InlineEditableUIView as te}from'@ckeditor/ckeditor5-ui/dist/index.js';import{DateTime as _0x452b52}from'luxon';class I extends/* #__PURE__ -- @preserve */
24
+ _0x208a0d(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x68770){super(),this['id']=_0x68770['id']||_0x17ccda(),this['creator']=_0x68770['creator']||null,this['authors']=_0x68770['authors']||[],this['diffData']=_0x68770['diffData']||null,this['toVersion']=_0x68770['toVersion']||0x0,this['fromVersion']=_0x68770['fromVersion']||0x0,this['set']('name',_0x68770['name']||''),this['set']('createdAt',_0x68770['createdAt']||new Date()),this['set']('attributes',_0x68770['attributes']||{});}['setName'](_0xa91b71){this['_update']({'name':_0xa91b71});}['setAttribute'](_0x197852,_0x12ac02){const _0x28d124=_0x5d7334(this['attributes']);_0x59cccf(_0x28d124,_0x197852,_0x12ac02),this['_update']({'attributes':_0x28d124});}['removeAttribute'](_0x5a44f9){const _0x2c3ff3=_0x5d7334(this['attributes']);_0x4f119a(_0x2c3ff3,_0x5a44f9),this['_update']({'attributes':_0x2c3ff3});}['_update'](_0x26106d,_0x5b0ab8=!0x1){let _0xc62403=!0x1;const _0x563390={'id':this['id']},_0x3936b1=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x1ee875 of _0x3936b1){const _0x569a4a=_0x26106d[_0x1ee875];void 0x0!==_0x569a4a&&_0x569a4a!==this[_0x1ee875]&&(this[_0x1ee875]=_0x569a4a,_0x563390[_0x1ee875]=_0x569a4a,_0xc62403=!0x0);}_0xc62403&&(_0x563390['authors']&&(_0x563390['authorsIds']=_0x563390['authors']['map'](_0x238f2c=>_0x238f2c['id']),delete _0x563390['authors']),this['fire']('_update',_0x563390,_0x5b0ab8));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x1a2b8c=>_0x1a2b8c['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class S extends _0x3a7117{['_revisions'];static get['requires'](){return[_0x315441];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x41f56e){super(_0x41f56e),this['_revisions']=new _0x2e7af1();}['afterInit'](){!async function(_0x5a9e24){const _0x3e8904=_0xc8919f([0x6b,0x34,0x43,0x35,0x65,0x74,0x32,0x33,0x37,0x78,0x63,0x4b,0x77,0x75,0x4a,0x30,0x61,0x6d,0x39,0x50,0x55,0x6a,0x72,0x4f,0x45,0x31,0x69,0x57,0x4c,0x44,0x49,0x66,0x38,0x36,0x53,0x67,0x58,0x6f,0x59,0x68,0x54,0x79,0x7a,0x52,0x70,0x6e,0x76,0x4d,0x41,0x73,0x6c,0x5a,0x48,0x42,0x46,0x64,0x71,0x4e,0x56,0x47,0x51,0x62]),_0x286a8c=0xeb829,_0x518166=0x42cd85c4,_0x4427b7=0x42caeec4^_0x518166,_0x73577c=window[_0xc8919f([0x44,0x61,0x74,0x65])][_0xc8919f([0x6e,0x6f,0x77])](),_0x4eb92e=_0x5a9e24[_0xc8919f([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x488430=new window[(_0xc8919f([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x1ed85c=>{_0x4eb92e[_0xc8919f([0x6f,0x6e,0x63,0x65])](_0xc8919f([0x72,0x65,0x61,0x64,0x79]),_0x1ed85c);}),_0x69dfd3={[_0xc8919f([0x6b,0x74,0x79])]:_0xc8919f([0x45,0x43]),[_0xc8919f([0x75,0x73,0x65])]:_0xc8919f([0x73,0x69,0x67]),[_0xc8919f([0x63,0x72,0x76])]:_0xc8919f([0x50,0x2d,0x32,0x35,0x36]),[_0xc8919f([0x78])]:_0xc8919f([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]),[_0xc8919f([0x79])]:_0xc8919f([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]),[_0xc8919f([0x61,0x6c,0x67])]:_0xc8919f([0x45,0x53,0x32,0x35,0x36])},_0x48a99c=_0x4eb92e[_0xc8919f([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0xc8919f([0x67,0x65,0x74])](_0xc8919f([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x18f863(){let _0x155d0a,_0x452420=null,_0x2d1b9e=null;try{if(_0x48a99c==_0xc8919f([0x47,0x50,0x4c]))return _0xc8919f([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x155d0a=_0x2ff459(),!_0x155d0a)return _0xc8919f([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x155d0a[_0xc8919f([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x2d1b9e=_0x498ed4(_0x155d0a[_0xc8919f([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x155d0a[_0xc8919f([0x6a,0x74,0x69])])),await _0x262125()?_0x422269()?_0x5936a6()?_0xc8919f([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x4c318a()?(_0x155d0a[_0xc8919f([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0xc8919f([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x452420=_0x5b3f23(_0xc8919f([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x155d0a[_0xc8919f([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0xc8919f([0x74,0x72,0x69,0x61,0x6c])&&(_0x452420=_0x5b3f23(_0xc8919f([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x25f13d()):_0xc8919f([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0xc8919f([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0xc8919f([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0xc8919f([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x5936a6(){const _0x5b3ccd=[_0xc8919f([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0xc8919f([0x74,0x72,0x69,0x61,0x6c])][_0xc8919f([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x155d0a[_0xc8919f([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x73577c/0x3e8:0xe10*_0x4427b7;return _0x155d0a[_0xc8919f([0x65,0x78,0x70])]<_0x5b3ccd;}function _0x422269(){const _0x2b5635=_0x155d0a[_0xc8919f([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x2b5635)return!0x1;if(_0x2b5635[_0xc8919f([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0xc8919f([0x2a])))return!0x0;if(_0x2b5635[_0xc8919f([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0xc8919f([0x52,0x48])))return!0x0;if(_0x2b5635[_0xc8919f([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0xc8919f([0x52,0x52,0x48]))){if(_0x2a581d())return!0x0;if(_0x3bb71c()||_0x24ee12())return!0x0;}return!0x1;}function _0x4c318a(){const _0x133170=_0x155d0a[_0xc8919f([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x133170||0x0==_0x133170[_0xc8919f([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x21c312}=new URL(window[_0xc8919f([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x133170[_0xc8919f([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x21c312))return!0x0;const _0x17590b=_0x21c312[_0xc8919f([0x73,0x70,0x6c,0x69,0x74])](_0xc8919f([0x2e]));return _0x133170[_0xc8919f([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x43a6f0=>_0x43a6f0[_0xc8919f([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0xc8919f([0x2a])))[_0xc8919f([0x6d,0x61,0x70])](_0x983880=>_0x983880[_0xc8919f([0x73,0x70,0x6c,0x69,0x74])](_0xc8919f([0x2e])))[_0xc8919f([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x25e3bc=>_0x25e3bc[_0xc8919f([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x17590b[_0xc8919f([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0xc8919f([0x6d,0x61,0x70])](_0x3803f1=>Array(_0x17590b[_0xc8919f([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0x3803f1[_0xc8919f([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0xc8919f([0x66,0x69,0x6c,0x6c])](_0x3803f1[0x0]===_0xc8919f([0x2a])?_0xc8919f([0x2a]):'')[_0xc8919f([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0x3803f1))[_0xc8919f([0x73,0x6f,0x6d,0x65])](_0x4ee425=>_0x17590b[_0xc8919f([0x65,0x76,0x65,0x72,0x79])]((_0x53e574,_0x21c95f)=>_0x4ee425[_0x21c95f]===_0x53e574||_0x4ee425[_0x21c95f]===_0xc8919f([0x2a])));}function _0x25f13d(){return _0x452420&&_0x2d1b9e?new window[(_0xc8919f([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x26168b,_0x178ab4)=>{_0x452420[_0xc8919f([0x74,0x68,0x65,0x6e])](_0x26168b,_0x178ab4),_0x2d1b9e[_0xc8919f([0x74,0x68,0x65,0x6e])](_0xd5c8a8=>{_0xd5c8a8!=_0xc8919f([0x56,0x61,0x6c,0x69,0x64])&&_0x26168b(_0xd5c8a8);},_0x178ab4);}):_0x452420||_0x2d1b9e||_0xc8919f([0x56,0x61,0x6c,0x69,0x64]);}}function _0x498ed4(_0x19e678,_0x55f17b){return new window[(_0xc8919f([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x255e25=>{if(_0x1232b9())return _0x255e25(_0xc8919f([0x56,0x61,0x6c,0x69,0x64]));_0x1e0ca0(),_0x4eb92e[_0xc8919f([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0xc8919f([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x1970fd=!0x1;const _0x113bf7=_0x17ccda();function _0x2c0190(_0x129dcf){return!!_0x129dcf&&(typeof _0x129dcf===_0xc8919f([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x129dcf===_0xc8919f([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x129dcf[_0xc8919f([0x74,0x68,0x65,0x6e])]===_0xc8919f([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x129dcf[_0xc8919f([0x63,0x61,0x74,0x63,0x68])]===_0xc8919f([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0xbe8315(_0x555d88){_0xb41ba1(_0x555d88)[_0xc8919f([0x74,0x68,0x65,0x6e])](_0x509cb8=>{if(!_0x509cb8||_0x509cb8[_0xc8919f([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0xc8919f([0x6f,0x6b]))return _0xc8919f([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x53a2e7(_0x36ca41(_0x113bf7+_0x55f17b))!=_0x509cb8[_0xc8919f([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0xc8919f([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0xc8919f([0x56,0x61,0x6c,0x69,0x64]);})[_0xc8919f([0x74,0x68,0x65,0x6e])](_0x295bd0=>(_0x35e1eb(),_0x295bd0),()=>{const _0x1d7b73=_0x5804e6();return null==_0x1d7b73?(_0x35e1eb(),_0xc8919f([0x56,0x61,0x6c,0x69,0x64])):_0xc8919f(_0x73577c-_0x1d7b73>(0x66c101c4^_0x518166)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0xc8919f([0x74,0x68,0x65,0x6e])](_0x255e25)[_0xc8919f([0x63,0x61,0x74,0x63,0x68])](()=>{_0x255e25(_0xc8919f([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x4d02bb=0x42fb6b44^_0x518166;function _0x35e1eb(){const _0x1419c3=_0xc8919f([0x6c,0x6c,0x63,0x74,0x2d])+_0x53a2e7(_0x36ca41(_0x19e678)),_0x99c667=_0x562460(_0x53a2e7(window[_0xc8919f([0x4d,0x61,0x74,0x68])][_0xc8919f([0x63,0x65,0x69,0x6c])](_0x73577c/_0x4d02bb)));window[_0xc8919f([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0xc8919f([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x1419c3,_0x99c667);}function _0x5804e6(){const _0x104c37=_0xc8919f([0x6c,0x6c,0x63,0x74,0x2d])+_0x53a2e7(_0x36ca41(_0x19e678)),_0x7a6a0b=window[_0xc8919f([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0xc8919f([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x104c37);return _0x7a6a0b?window[_0xc8919f([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x562460(_0x7a6a0b),0x10)*_0x4d02bb:null;}function _0xb41ba1(_0x517230){return new window[(_0xc8919f([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x2c99a4,_0x3276a8)=>{_0x517230[_0xc8919f([0x74,0x68,0x65,0x6e])](_0x2c99a4,_0x3276a8),window[_0xc8919f([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x3276a8,0x42cc5104^_0x518166);});}}_0x4eb92e[_0xc8919f([0x6f,0x6e])](_0xc8919f([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x1517de,_0x119119)=>{if(_0x119119[0x0]!=_0x19e678)return _0x255e25(_0xc8919f([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x119119[0x1]={..._0x119119[0x1],[_0xc8919f([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x113bf7};},{[_0xc8919f([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0xc8919f([0x68,0x69,0x67,0x68])}),_0x4eb92e[_0xc8919f([0x6f,0x6e])](_0xc8919f([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x26c6f9=>{_0x2c0190(_0x26c6f9[_0xc8919f([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x1970fd=!0x0,_0xbe8315(_0x26c6f9[_0xc8919f([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0xc8919f([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0xc8919f([0x6c,0x6f,0x77])}),_0x488430[_0xc8919f([0x74,0x68,0x65,0x6e])](()=>{_0x1970fd||_0x255e25(_0xc8919f([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x1232b9(){return _0x4eb92e[_0xc8919f([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0xc8919f([0x76,0x69,0x65,0x77])][_0xc8919f([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0xc8919f([0x61,0x75,0x74,0x6f]);}function _0x1e0ca0(){_0x4eb92e[_0xc8919f([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0xc8919f([0x76,0x69,0x65,0x77])][_0xc8919f([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0xc8919f([0x61,0x75,0x74,0x6f]);}}function _0x5b3f23(_0x1fad05){const _0x3bfaba=[new window[(_0xc8919f([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2ebc86=>setTimeout(_0x2ebc86,0x42c4bb08^_0x518166)),_0x488430[_0xc8919f([0x74,0x68,0x65,0x6e])](()=>new window[(_0xc8919f([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x5f2976=>{const _0x1ec9a0=0x42cd85c3^_0x518166,_0x1040d7=_0x5a9e24[_0xc8919f([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0xa9ac92(){_0x1040d7[_0xc8919f([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x1ec9a0&&_0x5f2976();}_0xa9ac92(),_0x1040d7[_0xc8919f([0x6f,0x6e])](_0xc8919f([0x61,0x64,0x64]),_0xa9ac92);})),new window[(_0xc8919f([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x290e35=>{function _0x44ff2e(){for(const _0x6b0b56 in window)if(window[_0xc8919f([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0xc8919f([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x6b0b56))&&window[_0x6b0b56]==_0x286a8c)return _0x290e35();_0x4eb92e[_0xc8919f([0x73,0x74,0x61,0x74,0x65])]!=_0xc8919f([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0xc8919f([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x44ff2e,0x42cd964c^_0x518166);}_0x2b7e36(_0xc8919f([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x44ff2e();})];return window[_0xc8919f([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0xc8919f([0x72,0x61,0x63,0x65])](_0x3bfaba)[_0xc8919f([0x74,0x68,0x65,0x6e])](()=>_0x1fad05);}async function _0x4507e7(){if(await _0x488430,_0x2b7e36(_0xc8919f([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x350730=_0x5a9e24[_0xc8919f([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x32cf20=_0x5a9e24[_0xc8919f([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])](_0x350730[_0xc8919f([0x69,0x64])]),_0x3df525=_0x85de41(_0xc8919f([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x3df525[_0xc8919f([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x350730['id'],_0x32cf20?_0x32cf20['id']:null,!0x0),_0x3df525[_0xc8919f([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0xc8919f([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x3df525[_0xc8919f([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x3df525[_0xc8919f([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x5f3a66,void(_0x3df525[_0xc8919f([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x5f3a66);}if(_0x2b7e36(_0xc8919f([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x189e30=_0x85de41(_0xc8919f([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x189e30[_0xc8919f([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0xc8919f([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x189e30[_0xc8919f([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x189e30[_0xc8919f([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x5f3a66,_0x189e30[_0xc8919f([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x5f3a66;}_0x4eb92e[_0xc8919f([0x6d,0x6f,0x64,0x65,0x6c])][_0xc8919f([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x5f3a66,_0x4eb92e[_0xc8919f([0x6d,0x6f,0x64,0x65,0x6c])][_0xc8919f([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x5f3a66,_0x4eb92e[_0xc8919f([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0xc8919f([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x2a581d(){return _0x2b7e36(_0xc8919f([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x85de41(_0xc8919f([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0xc8919f([0x73,0x74,0x61,0x74,0x65])]==_0xc8919f([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x3bb71c(){return _0x2b7e36(_0xc8919f([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 _0x24ee12(){return _0x2b7e36(_0xc8919f([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x261f00(_0x40af74){const _0x67480f=_0x11ef18();_0x4eb92e[_0x67480f]=_0xc8919f([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])+_0x40af74,_0x40af74[_0xc8919f([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0xc8919f([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x11ef18()]=_0x286a8c),_0x40af74!=_0xc8919f([0x56,0x61,0x6c,0x69,0x64])&&_0x4507e7();}function _0x11ef18(){const _0x1a087b=window[_0xc8919f([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0xc8919f([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0xc8919f([0x6e,0x6f,0x77])]())[_0xc8919f([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0xc8919f([0x2e]),'');let _0x30460a=_0xc8919f([0x6b]);for(let _0x309c85=0x0;_0x309c85<_0x1a087b[_0xc8919f([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x309c85+=0x2){let _0x5118ab=window[_0xc8919f([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x1a087b[_0xc8919f([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x309c85,_0x309c85+0x2));_0x5118ab>=_0x3e8904[_0xc8919f([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x5118ab-=_0x3e8904[_0xc8919f([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x30460a+=_0x3e8904[_0x5118ab];}return _0x30460a;}function _0x2ff459(){const _0x2b4938=_0x48a99c[_0xc8919f([0x73,0x70,0x6c,0x69,0x74])](_0xc8919f([0x2e]));if(0x3!=_0x2b4938[_0xc8919f([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x1423b6(_0x2b4938[0x1]);function _0x1423b6(_0x2c4cf9){const _0x2a7114=_0x395502(_0x2c4cf9);return _0x2a7114&&_0x1ce50f()?_0x2a7114:null;function _0x1ce50f(){const _0x564a77=_0x2a7114[_0xc8919f([0x6a,0x74,0x69])],_0x4d8d87=window[_0xc8919f([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x564a77[_0xc8919f([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x564a77[_0xc8919f([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0xa23e6a={..._0x2a7114,[_0xc8919f([0x6a,0x74,0x69])]:_0x564a77[_0xc8919f([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x564a77[_0xc8919f([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0xa23e6a[_0xc8919f([0x76,0x63])],_0x36ca41(_0xa23e6a)==_0x4d8d87;}}}async function _0x262125(){let _0x3a46e3=!0x0;try{const _0x54b483=_0x48a99c[_0xc8919f([0x73,0x70,0x6c,0x69,0x74])](_0xc8919f([0x2e])),[_0x262d11,_0x5e2673,_0x4ef650]=_0x54b483;return _0x5d3e7b(_0x262d11),await _0x23f6c3(_0x262d11,_0x5e2673,_0x4ef650),_0x3a46e3;}catch{return!0x1;}function _0x5d3e7b(_0x3c6f33){const _0x42b7c1=_0x395502(_0x3c6f33);_0x42b7c1&&_0x42b7c1[_0xc8919f([0x61,0x6c,0x67])]==_0xc8919f([0x45,0x53,0x32,0x35,0x36])||(_0x3a46e3=!0x1);}async function _0x23f6c3(_0x28b88c,_0xf2b7a2,_0x2a18e8){const _0x54ed28=window[_0xc8919f([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0xc8919f([0x66,0x72,0x6f,0x6d])](_0x5ca73a(_0x2a18e8),_0x4ff104=>_0x4ff104[_0xc8919f([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x2739ad=new window[(_0xc8919f([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0xc8919f([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x28b88c+_0xc8919f([0x2e])+_0xf2b7a2),_0x46cd3e=window[_0xc8919f([0x63,0x72,0x79,0x70,0x74,0x6f])][_0xc8919f([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x46cd3e)return;const _0x599773=await _0x46cd3e[_0xc8919f([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0xc8919f([0x6a,0x77,0x6b]),_0x69dfd3,{[_0xc8919f([0x6e,0x61,0x6d,0x65])]:_0xc8919f([0x45,0x43,0x44,0x53,0x41]),[_0xc8919f([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0xc8919f([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0xc8919f([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x46cd3e[_0xc8919f([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0xc8919f([0x6e,0x61,0x6d,0x65])]:_0xc8919f([0x45,0x43,0x44,0x53,0x41]),[_0xc8919f([0x68,0x61,0x73,0x68])]:{[_0xc8919f([0x6e,0x61,0x6d,0x65])]:_0xc8919f([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x599773,_0x54ed28,_0x2739ad)||(_0x3a46e3=!0x1);}}function _0x395502(_0x35de65){return _0x35de65[_0xc8919f([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0xc8919f([0x65,0x79]))?JSON[_0xc8919f([0x70,0x61,0x72,0x73,0x65])](_0x5ca73a(_0x35de65)):null;}function _0x5ca73a(_0x2a64a4){return window[_0xc8919f([0x61,0x74,0x6f,0x62])](_0x2a64a4[_0xc8919f([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0xc8919f([0x2b]))[_0xc8919f([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0xc8919f([0x2f])));}function _0x36ca41(_0x382049){let _0x315666=0x1505;function _0xba9ff7(_0x475a4e){for(let _0x537272=0x0;_0x537272<_0x475a4e[_0xc8919f([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x537272++){const _0x4c6dcc=_0x475a4e[_0xc8919f([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x537272);_0x315666=(_0x315666<<0x5)+_0x315666+_0x4c6dcc,_0x315666&=_0x315666;}}function _0x4bed39(_0x3c231f){Array[_0xc8919f([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x3c231f)?_0x3c231f[_0xc8919f([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x4bed39):_0x3c231f&&typeof _0x3c231f==_0xc8919f([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0xc8919f([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x3c231f)[_0xc8919f([0x73,0x6f,0x72,0x74])]()[_0xc8919f([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x629fb7,_0x4b231c])=>{_0xba9ff7(_0x629fb7),_0x4bed39(_0x4b231c);}):_0xba9ff7(window[_0xc8919f([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x3c231f));}return _0x4bed39(_0x382049),_0x315666>>>0x0;}function _0x53a2e7(_0x4976fd){return _0x4976fd[_0xc8919f([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0xc8919f([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0xc8919f([0x30]));}function _0x562460(_0x176f25){return _0x176f25[_0xc8919f([0x73,0x70,0x6c,0x69,0x74])]('')[_0xc8919f([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0xc8919f([0x6a,0x6f,0x69,0x6e])]('');}function _0x2b7e36(_0x1064a3){return _0x4eb92e[_0xc8919f([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0xc8919f([0x68,0x61,0x73])](_0x1064a3);}function _0x85de41(_0x4272a5){return _0x4eb92e[_0xc8919f([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0xc8919f([0x67,0x65,0x74])](_0x4272a5);}function _0x5f3a66(){}function _0xc8919f(_0x48e4e8){return _0x48e4e8['map'](_0x17dcbe=>String['fromCharCode'](_0x17dcbe))['join']('');}_0x261f00(await _0x18f863());}(this);}['createRevision'](_0x91b987){const _0x3e4afb=this['editor']['plugins']['get']('Users');return new I({'id':_0x91b987['id'],'name':_0x91b987['name'],'creator':_0x91b987['creatorId']?_0x3e4afb['getUser'](_0x91b987['creatorId']):null,'diffData':_0x91b987['diffData']||_0x91b987['data'],'authors':_0x91b987['authorsIds']['map'](_0x1679f3=>_0x3e4afb['getUser'](_0x1679f3)),'createdAt':new Date(_0x91b987['createdAt']),'attributes':_0x91b987['attributes'],'fromVersion':_0x91b987['fromVersion'],'toVersion':_0x91b987['toVersion']});}['addRevision'](_0x2d6c69,_0x346cb3=0x0){this['_revisions']['add'](_0x2d6c69,_0x346cb3);}['getRevision'](_0x47b8b8){return this['_revisions']['get'](_0x47b8b8);}['getRevisions'](_0x3be38a={'toJSON':!0x1}){const _0x4d26ed=Array['from'](this['_revisions']);return _0x4d26ed['reverse'](),_0x3be38a['toJSON']?_0x4d26ed['map'](_0x552c78=>_0x552c78['toJSON']()):_0x4d26ed;}['getIndex'](_0x4639d1){return this['_revisions']['getIndex'](_0x4639d1);}['getEarlierVisibleRevision'](_0x5cc8dd){const [,_0x591c98]=this['getRevisionsIterator'](_0x5cc8dd,{'direction':'earlier'});return _0x591c98;}['getLaterVisibleRevision'](_0x43cf4c){const [,_0x31deac]=this['getRevisionsIterator'](_0x43cf4c,{'direction':'later'});return _0x31deac;}['getRevisionsInDiff'](_0x419e0c){const _0x5bd21e=[];for(const _0x184623 of this['getRevisionsIterator'](_0x419e0c['newRevisionId']))if(_0x5bd21e['push'](_0x184623),_0x184623['id']===_0x419e0c['oldRevisionId'])break;return _0x5bd21e;}*['getRevisionsIterator'](_0x2ee11e,{direction:_0x358dc6='earlier',filter:_0x562415=()=>!0x0}={}){const _0x48fb9a='earlier'===_0x358dc6?0x1:-0x1;let _0x11ce02=this['_revisions']['get'](_0x2ee11e),_0x10b34b=this['getIndex'](_0x11ce02);for(yield _0x11ce02;_0x11ce02;){if(_0x10b34b+=_0x48fb9a,_0x11ce02=this['getRevision'](_0x10b34b),!_0x11ce02)return;_0x562415(_0x11ce02)&&(yield _0x11ce02);}}}class $ extends _0x3a7117{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x49f7fb,'c'],[_0x319301,'a'],[_0x56653d,'e'],[_0x4b14f6,'r'],[_0x3dc868,'u']]);['_typeCharToViewClass']=new Map([['c',_0x49f7fb],['a',_0x319301],['e',_0x56653d],['r',_0x4b14f6],['u',_0x3dc868]]);async['loadRevisionData'](_0x5e6b59,_0x352b22){if(_0x5e6b59['diffData']||!_0x352b22)return;const _0x49f9b4=this['editor']['config']['get']('collaboration.channelId'),_0x2fd645=await _0x352b22['getRevision']({'channelId':_0x49f9b4,'revisionId':_0x5e6b59['id']});_0x5e6b59['diffData']=_0x2fd645['diffData'];}['getRevisionDocumentData'](_0x21b703){const _0x1ee87d={};for(const _0x492974 in _0x21b703['diffData']){if(_0x21b703['diffData'][_0x492974]['attachChange']&&!_0x21b703['diffData'][_0x492974]['attachChange']['isAttached'])continue;const _0x19664c=this['_removeRevisionMarkers'](JSON['parse'](_0x21b703['diffData'][_0x492974]['insertions'])),_0x4faff0=this['editor']['editing']['view']['document'],_0x2b3b32=new _0x5c6a22(_0x4faff0,_0x19664c['map'](_0x47da3b=>this['_getViewFromDiffObj'](_0x47da3b,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x1ee87d[_0x492974]=this['editor']['data']['processor']['toData'](_0x2b3b32),this['editor']['data']['processor']['useFillerType']('default');}return _0x1ee87d;}['getRevisionRootsAttributes'](_0x405ca2){const _0x1f2591={};for(const _0x5090c1 in _0x405ca2['diffData'])_0x405ca2['diffData'][_0x5090c1]['attachChange']&&!_0x405ca2['diffData'][_0x5090c1]['attachChange']['isAttached']||(_0x1f2591[_0x5090c1]=_0x405ca2['diffData'][_0x5090c1]['attributesAfter']||{});return _0x1f2591;}['_getTypeCharForViewElement'](_0x51d776){return this['_viewClassToTypeChar']['get'](_0x51d776['constructor']);}['_getViewFromDiffObj'](_0x5f2b99,_0x130032){const _0x474034=this['editor']['editing']['view']['document'];if('string'==typeof _0x5f2b99)return new _0x14b7d4(_0x474034,_0x5f2b99);{let _0x2ce231,_0x4417ad;_0x4417ad='u'==_0x5f2b99['type']||'r'==_0x5f2b99['type']?[]:_0x5f2b99['children']['map'](_0x387331=>this['_getViewFromDiffObj'](_0x387331,_0x130032));const _0x22c51d=this['_typeCharToViewClass']['get'](_0x5f2b99['type'])||_0x3421ca,_0x47fc1e=this['editor']['data']['htmlProcessor']['domConverter'];if(_0x2ce231=new _0x22c51d(_0x474034,_0x5f2b99['name'],_0x5f2b99['attributes'],_0x4417ad),'u'==_0x5f2b99['type']&&_0x5f2b99['children'][0x0]){const _0x52912f=_0x5f2b99['children'][0x0];if(_0x2ce231['render']=function(_0x288fed){const _0x532af0=_0x288fed['createElement']('div');return _0x532af0['innerHTML']=_0x52912f,_0x532af0['childNodes'][0x0];},_0x130032){const _0x57e37a=new _0x5c6a22(_0x474034);_0x57e37a['_appendChild'](_0x2ce231);const _0x906f44=Array['from'](_0x47fc1e['viewChildrenToDom'](_0x57e37a,{'bind':!0x1})),_0x1b1297=_0x47fc1e['domDocument']['createElement']('div');_0x1b1297['append'](..._0x906f44),_0x2ce231=Array['from'](_0x47fc1e['domChildrenToView'](_0x1b1297))[0x0];}}else{if('r'==_0x5f2b99['type']&&_0x5f2b99['children'][0x0]){const _0x508164=_0x5f2b99['children'][0x0];if(_0x2ce231['render']=function(_0x11fee5){_0x11fee5['innerHTML']=_0x508164;},_0x130032){const _0x27d0e0=new _0x5c6a22(_0x474034);_0x27d0e0['_appendChild'](_0x2ce231);const _0xd224b6=Array['from'](_0x47fc1e['viewChildrenToDom'](_0x27d0e0,{'bind':!0x1})),_0x33584f=_0x47fc1e['domDocument']['createElement']('div');_0x33584f['append'](..._0xd224b6);const _0x1f17fb=Array['from'](_0x47fc1e['domChildrenToView'](_0x33584f));_0x1f17fb['length']>0x1?_0x2ce231['_appendChild'](_0x1f17fb):_0x2ce231=_0x1f17fb[0x0];}}}if(_0x5f2b99['customProperties']){for(const [_0xa3fee6,_0x45401b]of _0x5f2b99['customProperties'])_0x2ce231['_setCustomProperty'](_0xa3fee6,_0x45401b);}const _0x28337c=void 0x0===_0x5f2b99['fillerOffset']?null:_0x5f2b99['fillerOffset'];return null!==_0x28337c&&(_0x2ce231['getFillerOffset']=()=>_0x28337c),_0x2ce231;}}['_makeModelFromViewString'](_0x178985){const _0x5a3980=JSON['parse'](_0x178985),_0x808bf=this['editor']['editing']['view']['document'],_0x38196e=new _0x5c6a22(_0x808bf,_0x5a3980['map'](_0x189fa2=>this['_getViewFromDiffObj'](_0x189fa2,!0x0)));return this['editor']['data']['toModel'](_0x38196e);}['_removeRevisionMarkers'](_0x2a372b){return(_0x2a372b=_0x2a372b['filter'](_0x31be9b=>!_0x31be9b['name']||'revision-start'!==_0x31be9b['name']&&'revision-end'!==_0x31be9b['name']))['forEach'](_0x162a09=>{'string'!=typeof _0x162a09&&(_0x162a09['children']=this['_removeRevisionMarkers'](_0x162a09['children']),_0x162a09['attributes']=_0x162a09['attributes']['filter'](_0x3dc56e=>!_0x3dc56e[0x0]['startsWith']('data-revision-')));}),_0x2a372b;}}function R(_0x3f83d1,_0x276ce2,_0x248964){const t=_0x3f83d1['t'];switch(_0x276ce2){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'},_0x248964);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x248964);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 _0x3a7117{['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[_0x315441,S,$,_0x178404];}constructor(_0x42d3ae){super(_0x42d3ae),this['repository']=this['editor']['plugins']['get']('RevisionsRepository'),this['_utils']=this['editor']['plugins']['get']('RevisionHistoryUtils'),this['_revisionDataBuilder']=new E(this['editor']),this['_initialRevisionId']=this['editor']['config']['get']('collaboration.channelId')||'initial',this['_bufferedUpdates']=new Map(),this['_loadedStateData']=null;const _0x2a0199=_0x17ccda();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x2a0199},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 _0x1d42c9=this['repository']['getRevision'](0x0),_0x2c5180=_0x1d42c9&&null===_0x1d42c9['creator']?_0x1d42c9:null;if(this['_continueCurrentRevision']=!!_0x2c5180&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x509fc7=this['_source']['getCurrentRevisionId'](),_0x25a1e7=this['repository']['getRevision'](_0x509fc7);if(_0x25a1e7)this['_startingVersion']=_0x25a1e7['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x608af4=this['_source']['history']['_operations']['find'](_0x5933b6=>!_0x5933b6['_isInit']),_0x1480be=_0x608af4?_0x608af4['baseVersion']:this['_source']['history']['version'];_0x1d42c9?(_0x1d42c9['toVersion']<_0x1480be&&_0x1d42c9['_update']({'toVersion':_0x1480be}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x2c5180['id'],this['_startingVersion']=_0x2c5180['fromVersion']):(this['_startingVersion']=_0x1d42c9['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x1480be,this['_continueCurrentRevision']=!0x1);}}else _0x2c5180&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x2c5180['toVersion'],this['editor']['model']['document']['history']['version']),_0x2c5180['fromVersion']===_0x2c5180['toVersion']?(0x0!==_0x2c5180['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x2c5180['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x2c5180['id'],this['_startingVersion']=_0x2c5180['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',_0x347a08=>!_0x347a08),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x299867=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x33c005;for(const _0x11d034 in _0x299867){const _0x17741f=_0x11d034,_0x4d943a=_0x299867[_0x17741f];if('revisionHistoryLicenseKeyValid'==_0x4d943a||'revisionHistoryLicenseKeyInvalid'==_0x4d943a||'revisionHistoryLicenseKeyExpired'==_0x4d943a||'revisionHistoryLicenseKeyDomainLimit'==_0x4d943a||'revisionHistoryLicenseKeyNotAllowed'==_0x4d943a||'revisionHistoryLicenseKeyEvaluationLimit'==_0x4d943a||'revisionHistoryLicenseKeyTrialLimit'==_0x4d943a||'revisionHistoryLicenseKeyUsageLimit'==_0x4d943a){delete _0x299867[_0x17741f],_0x33c005=_0x4d943a,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x33c005&&_0x299867['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x33c005&&_0x299867['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x33c005&&_0x299867['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x33c005&&_0x299867['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x33c005&&_0x299867['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x33c005&&_0x299867['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x33c005&&_0x299867['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x4d33a0=this['repository']['getRevision'](0x0),_0x28040c=await this['getRevisionDocumentData'](_0x4d33a0),_0x110eee=await this['getRevisionRootsAttributes'](_0x4d33a0);this['_replaceEditorDataWithRevisionData'](_0x28040c,_0x110eee);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x4ab248){this['_source']=_0x4ab248;}async['update'](){const _0x360961=await this['_source']['getLatestVersion']();if(_0x360961>this['currentRevision']['toVersion']){await this['_loadState']();const _0x1212c8=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x360961});_0x1212c8['authors']=_0x1212c8['authorsIds']['map'](_0x286abf=>this['editor']['plugins']['get']('Users')['getUser'](_0x286abf)),this['currentRevision']['_update'](_0x1212c8);}}async['saveRevision'](_0x44b267={},_0x186cb9=null){const _0x2a9224=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x186cb9>this['currentRevision']['toVersion']&&(_0x186cb9=null),null===_0x186cb9&&(_0x186cb9=await this['_source']['getLatestVersion']());const _0x1363d3=this['_getFromVersion'](_0x186cb9),_0x68994c=this['buildRevisionData']({'from':_0x1363d3,'to':_0x186cb9});if(this['currentRevision']['toVersion']<_0x186cb9){const _0x1c138f=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x186cb9,'to':_0x186cb9});_0x1c138f['authors']=[],_0x1c138f['authorsIds']=[],_0x1c138f['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x1c138f,!0x0),delete _0x1c138f['authors'],_0x2a9224['push'](_0x1c138f);}_0x44b267['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x44b267['name']=_0x44b267['name']||null,_0x44b267['id']=_0x44b267['id']||_0x17ccda(),_0x44b267={..._0x44b267,..._0x68994c};const _0x48610d=this['addRevisionData'](_0x44b267);_0x2a9224['push'](_0x44b267);const _0xaaa6e8=this['repository']['getIndex'](_0x48610d);if(0x0!==_0xaaa6e8){const _0x3ab849=this['repository']['getRevision'](_0xaaa6e8-0x1);if(_0x3ab849['fromVersion']!==_0x186cb9){const _0x48e8ee=this['_revisionDataBuilder']['getData'](_0x186cb9,_0x3ab849['toVersion']),_0x8192ff={'id':_0x3ab849['id'],'diffData':_0x48e8ee['diffData'],'authorsIds':_0x48e8ee['authorsIds'],'authors':_0x48e8ee['authorsIds']['map'](_0x69c2e3=>this['editor']['plugins']['get']('Users')['getUser'](_0x69c2e3)),'fromVersion':_0x186cb9};_0x3ab849===this['currentRevision']&&(_0x8192ff['createdAt']=new Date(_0x44b267['createdAt']['getTime']()+0xa)),_0x3ab849['_update'](_0x8192ff,!0x0),delete _0x8192ff['authors'],_0x2a9224['push'](_0x8192ff);}}if(this['adapter']){for(const _0x3eb121 of _0x2a9224)this['_bufferUpdate'](_0x3eb121['id'],_0x3eb121,!0x0);this['sendBufferedUpdates']();}return _0x48610d;}['addRevisionData'](_0x771495){const _0x5b1043=this['repository']['createRevision'](_0x771495);return this['adapter']&&_0x5b1043['on']('_update',(_0xa86546,_0x2e6eb1,_0x655235)=>{_0x655235||(this['_bufferUpdate'](_0x2e6eb1['id'],_0x2e6eb1,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x5b1043,this['_findInsertionIndex'](_0x5b1043)),_0x5b1043;}async['getRevisionDocumentData'](_0xe781a4){return await this['_utils']['loadRevisionData'](_0xe781a4,this['adapter']),this['_utils']['getRevisionDocumentData'](_0xe781a4);}async['getRevisionRootsAttributes'](_0x10726c){return await this['_utils']['loadRevisionData'](_0x10726c,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x10726c);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x5e8988=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x26f7df=0x0;_0x26f7df<_0x5e8988['length'];_0x26f7df++){const _0x3819c2=_0x5e8988[_0x26f7df];let _0x379af5=!0x1;for(const _0x4da3ad of Object['keys'](_0x3819c2))void 0x0===_0x3819c2[_0x4da3ad]?delete _0x3819c2[_0x4da3ad]:'id'!==_0x4da3ad&&(_0x379af5=!0x0);_0x379af5||(_0x5e8988[_0x26f7df]=null);}if(_0x5e8988=_0x5e8988['filter'](_0x1ca9e8=>null!==_0x1ca9e8),!_0x5e8988['length'])return;for(let _0x50bbd3=0x0;_0x50bbd3<_0x5e8988['length'];_0x50bbd3++){const _0x3bfdaf=_0x5e8988[_0x50bbd3];void 0x0!==_0x3bfdaf['fromVersion']&&void 0x0===_0x3bfdaf['toVersion']&&(_0x3bfdaf['toVersion']=this['repository']['getRevision'](_0x3bfdaf['id'])['toVersion']),void 0x0!==_0x3bfdaf['toVersion']&&void 0x0===_0x3bfdaf['fromVersion']&&(_0x3bfdaf['fromVersion']=this['repository']['getRevision'](_0x3bfdaf['id'])['fromVersion']);}const _0x5744eb=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x5e8988,_0x5744eb)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x13cc87=>{if(_0x13cc87){for(const _0x23f761 of _0x13cc87)this['setRevisionData']({'id':_0x23f761['id'],'createdAt':_0x23f761['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0x1f96c4=null,from:_0x6dbad7=null,to:_0x52806c=null}){_0x6dbad7=null!==_0x6dbad7?_0x6dbad7:_0x1f96c4['fromVersion'],_0x52806c=null!==_0x52806c?_0x52806c:_0x1f96c4['toVersion'];const _0x512523=this['_revisionDataBuilder']['getData'](_0x6dbad7,_0x52806c),_0x260b35={'diffData':_0x512523['diffData'],'authorsIds':_0x512523['authorsIds'],'fromVersion':_0x6dbad7,'toVersion':_0x52806c};if(!_0x1f96c4||_0x52806c!==_0x1f96c4['toVersion']){const _0x4b9125=_0x52806c-0x1,_0x39746e=this['_source']['history']['getOperation'](_0x4b9125);_0x260b35['createdAt']=_0x39746e&&_0x39746e['createdAt']||new Date();}if(this['_loadedStateData']&&_0x6dbad7===this['_loadedStateData']['fromVersion']){for(const _0x4501fb of this['_loadedStateData']['authors'])_0x260b35['authorsIds']['includes'](_0x4501fb['id'])||_0x260b35['authorsIds']['push'](_0x4501fb['id']);}return _0x260b35;}['_bufferUpdate'](_0x166b61,_0x502c5b,_0x4d212c){if(this['_bufferedUpdates']['has'](_0x166b61)){const _0x2ca2fd=this['_bufferedUpdates']['get'](_0x166b61);_0x502c5b=_0x4d212c?{..._0x2ca2fd,..._0x502c5b}:{..._0x502c5b,..._0x2ca2fd};}this['_bufferedUpdates']['set'](_0x166b61,_0x502c5b);}['setRevisionData'](_0x1396fd){const _0x474da8=this['repository']['getRevision'](_0x1396fd['id']);if(_0x1396fd['createdAt']&&(_0x1396fd['createdAt']=new Date(_0x1396fd['createdAt'])),_0x1396fd['authorsIds']){const _0x28aac7=this['editor']['plugins']['get']('Users');_0x1396fd['authors']=_0x1396fd['authorsIds']['map'](_0x4d2b3d=>_0x28aac7['getUser'](_0x4d2b3d));}_0x474da8['_update'](_0x1396fd,!0x0);}['_createInitialRevision'](_0x25a46c){const _0x2cad4b=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x2cad4b)this['_initialRevisionId']=_0x2cad4b['id'];else{const _0x2a349a=!this['editor']['model']['document']['roots']['find'](_0x446b38=>this['editor']['model']['hasContent'](_0x446b38)),_0x8d43bd=this['editor']['plugins']['get']('Users')['me']['id'],_0x20de04=R(this['editor']['locale'],_0x2a349a?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x25a46c,'to':_0x25a46c,'id':this['_initialRevisionId'],'name':_0x20de04,'creatorId':_0x8d43bd});}}['_createCurrentRevision'](_0x25332b){const _0x1f88e2=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x1f88e2),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x25332b,'to':_0x25332b,'id':_0x1f88e2,'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'](_0x2dccb6,_0x497247){let _0x15c8c2=this['editor']['config']['get']('initialData'),_0x34ff63=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x15c8c2){_0x15c8c2={};for(const _0x5aaed3 of this['editor']['model']['document']['getRootNames']())_0x15c8c2[_0x5aaed3]='';}if('string'==typeof _0x15c8c2&&(_0x15c8c2={'main':_0x15c8c2}),void 0x0===_0x34ff63){_0x34ff63={};for(const _0x482051 of this['editor']['model']['document']['getRootNames']())_0x34ff63[_0x482051]={};}let _0x5788fb=!0x1;const _0x3ccf8b=Object['keys'](_0x15c8c2),_0x23de0f=Object['keys'](_0x2dccb6);for(const _0x20be7e of _0x3ccf8b){if(_0x15c8c2[_0x20be7e]!==_0x2dccb6[_0x20be7e]&&''!==_0x15c8c2[_0x20be7e]['trim']()){_0x5788fb=!0x0;break;}if(!_0x2dbdeb(_0x34ff63[_0x20be7e],_0x497247[_0x20be7e])&&Object['keys'](_0x34ff63[_0x20be7e])['length']>0x0){_0x5788fb=!0x0;break;}}_0x5788fb||(_0x5788fb=_0x23de0f['some'](_0x336cd5=>!this['editor']['model']['document']['getRoot'](_0x336cd5))),_0x5788fb&&_0x10c5ab('editor-initial-data-replaced-with-revision-data',{'editorData':_0x15c8c2,'editorRootsAttributes':_0x34ff63,'revisionData':_0x2dccb6,'revisionRootsAttributes':_0x497247}),this['editor']['config']['set']('initialData',_0x2dccb6),this['editor']['config']['set']('rootsAttributes',_0x497247);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x28c594=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x28c594['add'](R(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x550e2e){const _0x230c53=this['repository']['getRevisions']();_0x230c53['reverse']();let _0x277508=0x0;for(;_0x277508<_0x230c53['length'];){const _0x7f9824=_0x230c53[_0x277508];if(_0x7f9824===this['currentRevision']){_0x277508++;continue;}if(_0x7f9824['id']===this['_initialRevisionId'])break;const _0x1ba5dc=_0x550e2e['toVersion']-_0x7f9824['toVersion']||_0x550e2e['fromVersion']-_0x7f9824['fromVersion'];if(_0x1ba5dc>0x0)break;if(_0x1ba5dc<0x0)_0x277508++;else{if(!_0x550e2e['creator']&&_0x7f9824['creator'])break;if(_0x7f9824['creator']||!_0x550e2e['creator']){if(_0x550e2e['createdAt']>_0x7f9824['createdAt'])break;_0x277508++;}else _0x277508++;}}return _0x277508;}['_getFromVersion'](_0x2e4e59){const _0x122eb4=this['repository']['getRevisions']();_0x122eb4['reverse'](),_0x122eb4['shift']();const _0x256b66=_0x122eb4['find'](_0x5ba383=>_0x5ba383['toVersion']<=_0x2e4e59)['toVersion'];return _0x256b66<this['_startingVersion']?this['_startingVersion']:_0x256b66;}['_makeRevision']({name:_0x87a477,from:_0x32ee11,to:_0x3a5d83,creatorId:_0x38bc9a,id:_0x5aab01}){const _0x2cc7cc=this['buildRevisionData']({'from':_0x32ee11,'to':_0x3a5d83});_0x2cc7cc['name']=_0x87a477,_0x2cc7cc['creatorId']=_0x38bc9a,_0x2cc7cc['id']=_0x5aab01;const _0x3485f2=this['addRevisionData'](_0x2cc7cc);return this['adapter']&&this['_bufferUpdate'](_0x2cc7cc['id'],_0x2cc7cc,!0x0),_0x3485f2;}['_setConversion'](){this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'});}}class E{['editor'];['source'];['_savedMetaData'];['_lastFrom'];['_lastTo'];['_markers'];['_diffRoots'];['_diffRootsAttributes'];['_baseRoots'];['_baseRootsAttributes'];['_idsRoots'];['_baseIdsRoots'];['_touched'];['_touchedMarkers'];['_touchedRoots'];['_revisionId'];['_startingRevisionId'];constructor(_0x5e6008){this['editor']=_0x5e6008,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'](_0x12d16d){this['source']=_0x12d16d;const _0x1bd085=new Map(),_0x2546e2=new Map(),_0x52821c=this['editor']['model']['document']['roots']['map'](_0xbfe9db=>_0xbfe9db['rootName']);for(const _0x38706c of _0x52821c){const _0x486e0f=this['editor']['model']['document']['getRoot'](_0x38706c),_0x3a4ad4=x(_0x486e0f);_0x1bd085['set'](_0x38706c,_0x3a4ad4),_0x2546e2['set'](_0x38706c,Object['fromEntries'](_0x486e0f['getAttributes']()));}const _0x1e1590=Array['from'](this['editor']['model']['markers'])['map'](_0x23ed7c=>[_0x23ed7c['name'],_0x23ed7c['getRange']()]),_0x5c83f0=this['source']['version'];this['_saveMetaData'](_0x5c83f0,_0x1bd085,_0x1e1590,_0x2546e2),this['_startingRevisionId']=this['_revisionId'];const _0x25e057=new Map(),_0x5c1c50=new Map();for(const _0x2c1b58 of _0x52821c){const _0x1dd70a=N(_0x2c1b58);_0x25e057['set'](_0x2c1b58,_0x1dd70a),_0x5c1c50['set'](_0x2c1b58,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x25e057,[],_0x5c1c50);}['getData'](_0x1e27c8,_0x95fc05){if(this['_lastFrom']===_0x1e27c8&&this['_lastTo']<=_0x95fc05)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x95fc05,!0x0);else{if(!this['_savedMetaData']['has'](_0x1e27c8)){const _0x407a67=this['_getPreviousFrom'](_0x1e27c8);this['_calculateMetaData'](_0x407a67,_0x1e27c8,!0x1);}this['_calculateMetaData'](_0x1e27c8,_0x95fc05,!0x0);}return this['_lastFrom']=_0x1e27c8,this['_lastTo']=_0x95fc05,this['_getState']();}['loadState'](_0x32c47d){const _0x5388d4=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x32c47d['fromVersion'],this['_lastTo']=_0x32c47d['toVersion'];for(const _0x3521ed in _0x32c47d['diffData']){const _0x84039e=_0x32c47d['diffData'][_0x3521ed]['attachChange'],_0x336d96=_0x5d7334(_0x32c47d['diffData'][_0x3521ed]['attributesBefore'])||{},_0x20978a=_0x5388d4['_makeModelFromViewString'](_0x32c47d['diffData'][_0x3521ed]['deletions']);_0x20978a['rootName']=_0x3521ed,_0x20978a['_isAttached']=!_0x84039e||!_0x84039e['isAttached'],_0x20978a['isAttached']=()=>_0x20978a['_isAttached'],this['_baseRoots']['set'](_0x3521ed,_0x20978a),this['_baseRootsAttributes']['set'](_0x3521ed,_0x336d96),_0x84039e&&this['_touchedRoots']['set'](_0x3521ed,_0x84039e);const _0x5be4dd=this['_makeIdsRoot'](_0x20978a);this['_baseIdsRoots']['set'](_0x3521ed,_0x5be4dd);for(const [_0x27f8e4,_0x21bfa1]of _0x20978a['markers']){if(!_0x27f8e4['startsWith']('revision:'))continue;const _0x48c819=_0x27f8e4['split'](':')[0x2];for(const _0x1b1866 of _0x21bfa1['getWalker']({'singleCharacters':!0x0})){const _0x10ebe0=this['_getVidAttributeName'](_0x1b1866),_0x4349bc='elementEnd'==_0x1b1866['type']?_0x1b1866['previousPosition']['path']['slice'](0x0,-0x1):_0x1b1866['previousPosition']['path'],_0xfa569a=_0x5be4dd['getNodeByPath'](_0x4349bc)['getAttribute'](_0x10ebe0);this['_touched']['set'](_0xfa569a,{'userId':_0x48c819});}}}this['_startingRevisionId']=this['_revisionId'];const _0xf13447=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x2a5c5b=>!this['_touched']['has'](_0x2a5c5b));let _0x584616=0x0;const _0x43f16c=new Map();for(const _0x4b605b in _0x32c47d['diffData']){const _0x294d81=_0x32c47d['diffData'][_0x4b605b]['attachChange'],_0x2db036=_0x5d7334(_0x32c47d['diffData'][_0x4b605b]['attributesAfter'])||{},_0x2e86b6=_0x5388d4['_makeModelFromViewString'](_0x32c47d['diffData'][_0x4b605b]['insertions']);_0x2e86b6['rootName']=_0x4b605b,_0x2e86b6['_isAttached']=!_0x294d81||_0x294d81['isAttached'],_0x2e86b6['isAttached']=()=>_0x2e86b6['_isAttached'],this['_diffRoots']['set'](_0x4b605b,_0x2e86b6),this['_diffRootsAttributes']['set'](_0x4b605b,_0x2db036);const _0x1f9e36=this['_makeIdsRoot'](_0x2e86b6,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x4b605b,_0x1f9e36),_0x43f16c['set'](_0x4b605b,_0x2e86b6['isAttached']()?_0x2db036:{});for(const [_0x4e5cd3,_0x4492da]of _0x2e86b6['markers']){if(!_0x4e5cd3['startsWith']('revision:'))continue;const _0x39db4f=_0x4e5cd3['split'](':')[0x2];for(const _0x179ecc of _0x4492da['getWalker']({'singleCharacters':!0x0})){const _0x42e116=this['_getVidAttributeName'](_0x179ecc),_0x11bbc5=this['_revisionId']++,_0x511922='elementEnd'==_0x179ecc['type']?_0x179ecc['previousPosition']['path']['slice'](0x0,-0x1):_0x179ecc['previousPosition']['path'];_0x1f9e36['getNodeByPath'](_0x511922)['_setAttribute'](_0x42e116,_0x11bbc5),this['_touched']['set'](_0x11bbc5,{'userId':_0x39db4f});}}for(const _0x2ef586 of this['editor']['model']['createRangeIn'](_0x2e86b6)['getWalker']({'singleCharacters':!0x0})){const _0x5e4652=this['_getVidAttributeName'](_0x2ef586),_0x7e3c06='elementEnd'==_0x2ef586['type']?_0x2ef586['previousPosition']['path']['slice'](0x0,-0x1):_0x2ef586['previousPosition']['path'],_0x256f99=_0x1f9e36['getNodeByPath'](_0x7e3c06);_0x256f99['getAttribute'](_0x5e4652)>0x0||_0x256f99['_setAttribute'](_0x5e4652,_0xf13447[_0x584616++]);}for(const [_0x391d7d,_0x4d14be]of _0x2e86b6['markers'])_0x391d7d['startsWith']('revision:')||this['_markers']['set'](_0x391d7d,_0x4d14be);}const _0x5588f0=N('$graveyard');this['_baseRoots']['set']('$graveyard',_0x5588f0),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x5588f0,0x1));const _0x60a79e=N('$graveyard');this['_diffRoots']['set']('$graveyard',_0x60a79e),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x60a79e,0x1));const _0x2cc97f=Array['from'](this['_diffRoots'])['map'](([_0x3b34fd,_0x384b93])=>[_0x3b34fd,x(_0x384b93)]);this['_saveMetaData'](this['_lastTo'],_0x2cc97f,this['_markers'],_0x43f16c);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0x17cfa9,_0x16e4fb,_0x71766,_0xeb1aa){const _0x31baff=new Map(_0x16e4fb),_0x11f0e8=new Map(_0x5d7334(_0xeb1aa)),_0x17002c=new Map();for(const [_0x154cbf,_0x2cccb8]of _0x71766)_0x17002c['set'](_0x154cbf,{'start':_0x2cccb8['start']['clone'](),'end':_0x2cccb8['end']['clone'](),'rootName':_0x2cccb8['root']['rootName']});this['_savedMetaData']['set'](_0x17cfa9,{'roots':_0x31baff,'markers':_0x17002c,'rootsAttributes':_0x11f0e8});}['_removeMetaData'](_0x1bf9c2){this['_savedMetaData']['delete'](_0x1bf9c2);}['_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'](_0x2c34e2,_0x5cc363=null){let _0x2dcd65=null;_0x2c34e2['is']('documentFragment')||(_0x2dcd65=new _0x17ffdc(_0x2c34e2['name'],{'vid_start':null===_0x5cc363?this['_revisionId']++:_0x5cc363++}));const _0x4a6182=[];for(const _0x3c2e87 of _0x2c34e2['getChildren']())if(_0x3c2e87['is']('element')){_0x4a6182['push'](this['_makeIdsRoot'](_0x3c2e87,_0x5cc363));const _0x3b3679=_0x4a6182[_0x4a6182['length']-0x1];null!==_0x5cc363&&(_0x5cc363=_0x3b3679['is']('element','$text')?_0x3b3679['getAttribute']('vid')+0x1:_0x3b3679['getAttribute']('vid_end')+0x1);}else{for(let _0x3fc53b=0x0;_0x3fc53b<_0x3c2e87['offsetSize'];_0x3fc53b++)_0x4a6182['push'](new _0x17ffdc('$text',{'vid':null===_0x5cc363?this['_revisionId']++:_0x5cc363++}));}if(_0x2c34e2['is']('documentFragment')){const _0x2d1aa5=N(_0x2c34e2['rootName']);return _0x2d1aa5['_insertChild'](0x0,_0x4a6182),_0x2d1aa5;}return _0x2dcd65['_setAttribute']('vid_end',null===_0x5cc363?this['_revisionId']++:_0x5cc363++),_0x2dcd65['_insertChild'](0x0,_0x4a6182),_0x2dcd65;}['_calculateMetaData'](_0x5bfd2a,_0x482e51,_0x1e64c0){this['_reset']();const {roots:_0x37ae8f,markers:_0x572c63,rootsAttributes:_0x4d4021}=this['_savedMetaData']['get'](_0x5bfd2a);this['_baseRoots']=new Map(_0x37ae8f),this['_baseRootsAttributes']=new Map(_0x5d7334(_0x4d4021));for(const [_0x2b2c64,_0x11b695]of this['_baseRoots'])if('$graveyard'!==_0x2b2c64&&(this['_diffRoots']['set'](_0x2b2c64,x(_0x11b695)),this['_diffRootsAttributes']=new Map(_0x5d7334(_0x4d4021)),_0x1e64c0)){const _0x36c7ae=this['_revisionId'];this['_idsRoots']['set'](_0x2b2c64,this['_makeIdsRoot'](_0x11b695)),this['_baseIdsRoots']['set'](_0x2b2c64,this['_makeIdsRoot'](_0x11b695,_0x36c7ae));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',x(this['_baseRoots']['get']('$graveyard'))),_0x1e64c0&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x21406b,_0x5e688a]of _0x572c63){const _0x3c09fd=this['_baseRoots']['get'](_0x5e688a['rootName']),_0x3e6080=this['_diffRoots']['get'](_0x5e688a['rootName']),_0x50cb3c=new _0x4fa97a(this['_fixPosition'](_0x5e688a['start'],_0x3c09fd),this['_fixPosition'](_0x5e688a['end'],_0x3c09fd)),_0xa39d3c=this['_fixRange'](_0x50cb3c,_0x3e6080);_0x3c09fd['markers']['set'](_0x21406b,_0x50cb3c),this['_markers']['set'](_0x21406b,_0xa39d3c);}this['_applyOperations'](_0x5bfd2a,_0x482e51,_0x1e64c0);}['_applyOperations'](_0x1807a7,_0x1bf03d,_0x107c04){for(const _0x455b8b of this['source']['getOperations'](_0x1807a7,_0x1bf03d))this['_handleOperation'](_0x455b8b,_0x107c04);for(const _0x26f689 of this['_diffRoots']['values']())_0x26f689['markers']['clear']();for(const [_0x529855,_0xc31ba0]of this['_markers']){this['_diffRoots']['get'](_0xc31ba0['root']['rootName'])['markers']['set'](_0x529855,_0xc31ba0['clone']());}const _0x3d952d=new Map(),_0x57f1ab=new Map();for(const [_0x3d1471,_0x5ad74c]of this['_diffRoots'])_0x3d952d['set'](_0x3d1471,x(_0x5ad74c)),_0x57f1ab['set'](_0x3d1471,this['_diffRootsAttributes']['get'](_0x3d1471));this['_saveMetaData'](_0x1bf03d,_0x3d952d,this['_markers'],_0x57f1ab);}['_getPreviousFrom'](_0x1d2c5b){const _0x383fe5=Array['from'](this['_savedMetaData']['keys']());_0x383fe5['sort']((_0x3b6108,_0x40da9e)=>_0x3b6108-_0x40da9e),_0x383fe5['reverse']();for(const _0x1a337b of _0x383fe5)if(_0x1a337b<_0x1d2c5b)return _0x1a337b;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x1ab6c1,_0x4879c1){const _0x1a4358=Array['from'](_0x4879c1['markers'])['map'](([_0x153f4b,_0x1f6958])=>[_0x153f4b,this['_fixRange'](_0x1f6958,_0x1ab6c1)]);_0x1ab6c1['markers']=new Map(_0x1a4358);}['_transformMarkers'](_0x2f72b9){for(const _0x5d6fe8 of this['_markers']['values']()){const _0x1626b1=_0x5d6fe8['getTransformedByOperation'](_0x2f72b9),_0x57371b=_0x4fa97a['_createFromRanges'](_0x1626b1);_0x5d6fe8['start']=_0x57371b['start'],_0x5d6fe8['end']=_0x57371b['end'];}}['_handleOperation'](_0x24c033,_0x3c9a5a){if('addRoot'!=_0x24c033['type']&&'detachRoot'!=_0x24c033['type']){if('insert'==_0x24c033['type']){const _0x2b14a6=_0x24c033['position']['root']['rootName'];this['_diffRoots']['has'](_0x2b14a6)||(this['_diffRoots']['set'](_0x2b14a6,N(_0x2b14a6,!0x0)),this['_diffRootsAttributes']['set'](_0x2b14a6,{}),_0x3c9a5a&&this['_idsRoots']['set'](_0x2b14a6,N(_0x2b14a6,!0x0)));}else{if('addRootAttribute'==_0x24c033['type']||'removeRootAttribute'==_0x24c033['type']||'changeRootAttribute'==_0x24c033['type'])return void this['_handleRootAttributeOperation'](_0x24c033);'marker'==_0x24c033['type']&&this['_handleMarkerOperation'](_0x24c033);}if('marker'!==_0x24c033['type']){const _0x2cedfc=this['_cloneOperation'](_0x24c033,this['_diffRoots']);_0x2cedfc['_execute'](),this['_transformMarkers'](_0x2cedfc);}if(_0x3c9a5a)switch(_0x24c033['type']){case'insert':this['_handleInsertOperation'](_0x24c033);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x24c033);break;case'merge':this['_handleMergeOperation'](_0x24c033);break;case'split':this['_handleSplitOperation'](_0x24c033);}}else this['_handleRootOperation'](_0x24c033,_0x3c9a5a);}['_cloneOperation'](_0x33e9c5,_0x4065c7){const _0x1848a0=_0x33e9c5['clone']();return _0x1848a0['_authorId']=_0x33e9c5['_authorId'],this['_fixOperation'](_0x1848a0,_0x4065c7),_0x1848a0;}['_getBaseVids'](_0x1cb37a){return _0x1cb37a['map'](_0x40e3cb=>{const _0x49a359=this['_getVidAttributeName'](_0x40e3cb);return Number(_0x40e3cb['item']['getAttribute'](_0x49a359));});}['_generateTape'](_0x12309a,_0x30c018){if(_0x12309a['is']('element','$text'))_0x30c018['push']({'item':_0x12309a,'type':'text'});else{_0x12309a['is']('element')&&_0x30c018['push']({'item':_0x12309a,'type':'elementStart'});for(const _0x4b8b33 of _0x12309a['getChildren']())this['_generateTape'](_0x4b8b33,_0x30c018);_0x12309a['is']('element')&&_0x30c018['push']({'item':_0x12309a,'type':'elementEnd'});}return _0x30c018;}['_getState'](){const _0x226370=new Map(this['_touched']),_0x2dde7e=new Map(_0x226370),_0x5f37cf=new Map(),_0x41bc66={'insertions':{},'deletions':{}},_0xfdc9b7={'insertions':{},'deletions':{}},_0x33dcb4=new Map(),_0x3f43d7=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x3f43d7['delete']('$graveyard');for(const _0x5856ee of _0x3f43d7){const _0x9dfdac=this['_diffRoots']['get'](_0x5856ee)||N(_0x5856ee,!0x1),_0x2b1253=this['_baseRoots']['get'](_0x5856ee)||N(_0x5856ee,!0x1);_0x9dfdac['isAttached']()||_0x2b1253['isAttached']()?(_0x41bc66['insertions'][_0x5856ee]=x(_0x9dfdac),_0x41bc66['deletions'][_0x5856ee]=x(_0x2b1253),this['_copyMarkers'](_0x41bc66['deletions'][_0x5856ee],_0x2b1253),this['_copyMarkers'](_0x41bc66['insertions'][_0x5856ee],_0x9dfdac),_0xfdc9b7['insertions'][_0x5856ee]=this['_generateTape'](this['_idsRoots']['get'](_0x5856ee),[]),_0xfdc9b7['deletions'][_0x5856ee]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x5856ee)||N(_0x5856ee,!0x1),[])):_0x3f43d7['delete'](_0x5856ee);}for(const _0x1e9688 of _0x3f43d7){const _0x33f166=_0xfdc9b7['insertions'][_0x1e9688];for(const _0x103253 of _0x33f166){const _0x5d9ad4=this['_getVidAttributeName'](_0x103253),_0x42b2c4=_0x103253['item']['getAttribute'](_0x5d9ad4);_0x2dde7e['delete'](_0x42b2c4),_0x42b2c4>=this['_startingRevisionId']&&_0x5f37cf['set'](_0x42b2c4,_0x226370['get'](_0x42b2c4));}}for(const _0x3d04c4 of _0x3f43d7){const _0x5d0196=_0xfdc9b7['insertions'][_0x3d04c4],_0x424e50=this['_getBaseVids'](_0xfdc9b7['deletions'][_0x3d04c4]);let _0x1425c0=0x0;for(const _0x1d8408 of _0x5d0196){const _0x1cd86a=this['_getVidAttributeName'](_0x1d8408),_0x573c6a=_0x1d8408['item']['getAttribute'](_0x1cd86a);if(!_0x5f37cf['has'](_0x573c6a)&&!_0x33dcb4['has'](_0x573c6a)){if(_0x2dde7e['has'](_0x573c6a))_0x1425c0++;else{if(_0x573c6a!=_0x424e50[_0x1425c0]){const _0x3cb0b1=_0x226370['get'](_0x573c6a)||_0x226370['get'](_0x424e50[_0x1425c0]);for(;_0x573c6a!=_0x424e50[_0x1425c0];)_0x2dde7e['has'](_0x424e50[_0x1425c0])||(_0x33dcb4['set'](_0x424e50[_0x1425c0],_0x3cb0b1),_0x226370['set'](_0x424e50[_0x1425c0],_0x3cb0b1)),_0x1425c0++;}_0x1425c0++;}}}}for(const _0x485c2b of _0x3f43d7){const _0x31538f=_0xfdc9b7['insertions'][_0x485c2b];for(const _0x1e4dda of _0x31538f){const _0x292b59=this['_getVidAttributeName'](_0x1e4dda),_0x23aa16=_0x1e4dda['item']['getAttribute'](_0x292b59);if(_0x33dcb4['has'](_0x23aa16)){const _0x2cb763=_0x33dcb4['get'](_0x23aa16);_0x2dde7e['has'](_0x23aa16)||_0x2dde7e['set'](_0x23aa16,{..._0x2cb763}),_0x5f37cf['set'](_0x23aa16,{..._0x2cb763});}}}for(const _0x2bd52d of _0x2dde7e['keys']())_0x2bd52d>=this['_startingRevisionId']&&_0x2dde7e['delete'](_0x2bd52d);const _0x1d7eb3=new Map();for(const _0xebf462 of _0x3f43d7){let _0x3a4bcb=_0xfdc9b7['insertions'][_0xebf462];for(const _0x38e722 of _0x3a4bcb)if(_0x38e722['item']['is']('element','tableCell')){const _0xdc8c8=this['_getVidAttributeName'](_0x38e722),_0x58ebf2=_0x38e722['item']['getAttribute'](_0xdc8c8);if(_0x5f37cf['has'](_0x58ebf2)){const _0xcd6923=_0x38e722['item']['parent']['parent']['getAttribute']('vid_start'),_0x4420a1=_0x1d7eb3['get'](_0xcd6923)||new Set();_0x4420a1['add'](_0x5f37cf['get'](_0x58ebf2)['userId']),_0x1d7eb3['set'](_0xcd6923,_0x4420a1);}}_0x3a4bcb=_0xfdc9b7['deletions'][_0xebf462];for(const _0x5bd3f1 of _0x3a4bcb)if(_0x5bd3f1['item']['is']('element','tableCell')){const _0x2dc4b8=this['_getVidAttributeName'](_0x5bd3f1),_0x5ab705=_0x5bd3f1['item']['getAttribute'](_0x2dc4b8);if(_0x2dde7e['has'](_0x5ab705)){const _0x1815b1=_0x5bd3f1['item']['parent']['parent']['getAttribute']('vid_start'),_0x35feda=_0x1d7eb3['get'](_0x1815b1)||new Set();_0x35feda['add'](_0x2dde7e['get'](_0x5ab705)['userId']),_0x1d7eb3['set'](_0x1815b1,_0x35feda);}}for(const _0x4347f9 of _0x1d7eb3['keys']())(_0x5f37cf['has'](_0x4347f9)||_0x2dde7e['has'](_0x4347f9))&&_0x1d7eb3['delete'](_0x4347f9);}for(const _0x444470 of _0x3f43d7){const _0x452d85=_0xfdc9b7['insertions'][_0x444470];let _0x7c5392=null,_0x5bfae4=null;for(const _0x30abbb of _0x452d85){const _0x2201b2=this['_getVidAttributeName'](_0x30abbb),_0x7b7218=_0x30abbb['item']['getAttribute'](_0x2201b2),_0x126235=_0x1d7eb3['get'](_0x7b7218);_0x126235&&'elementStart'==_0x30abbb['type']&&(_0x7c5392=Array['from'](_0x126235)[0x0],_0x5bfae4=_0x30abbb['item']['getAttribute']('vid_end')),_0x7c5392&&(_0x2dde7e['set'](_0x7b7218,{'userId':_0x7c5392}),_0x5f37cf['set'](_0x7b7218,{'userId':_0x7c5392})),_0x7b7218==_0x5bfae4&&(_0x7c5392=null,_0x5bfae4=null);}}const _0x524cc4={},_0x5cf0fb=new Set();for(const _0xeb92c7 of _0x3f43d7){const _0x433482=_0x41bc66['deletions'][_0xeb92c7],_0x41885c=_0x41bc66['insertions'][_0xeb92c7];for(const {userId:_0x1a7682}of this['_touchedMarkers']['values']())null!==_0x1a7682&&_0x5cf0fb['add'](_0x1a7682);for(const {userId:_0x21c2f2}of this['_touchedRoots']['values']())null!==_0x21c2f2&&_0x5cf0fb['add'](_0x21c2f2);this['_markChanges'](_0x41885c,_0xfdc9b7['insertions'][_0xeb92c7],_0x5f37cf,'insertion',_0x5cf0fb),this['_markChanges'](_0x433482,_0xfdc9b7['deletions'][_0xeb92c7],_0x2dde7e,'deletion',_0x5cf0fb),_0x524cc4[_0xeb92c7]={'insertions':this['_prepareViewToSave'](_0x41885c),'deletions':this['_prepareViewToSave'](_0x433482),'attachChange':this['_touchedRoots']['get'](_0xeb92c7)||null,'attributesBefore':_0x5d7334(this['_baseRootsAttributes']['get'](_0xeb92c7))||{},'attributesAfter':_0x5d7334(this['_diffRootsAttributes']['get'](_0xeb92c7))};}return{'diffData':_0x524cc4,'authorsIds':Array['from'](_0x5cf0fb)};}['_processRootBeforeSave'](_0x1f2fb8){for(const [,_0x37322d]of _0x1f2fb8['markers']){const _0x152cac=_0x37322d['start']['getAncestors']()['filter'](_0x5236ef=>'tableCell'==_0x5236ef['name']);for(const _0x22322a of _0x152cac)0x1==_0x22322a['childCount']&&_0x22322a['getChild'](0x0)['is']('element','paragraph')&&_0x22322a['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x7b2648){this['_processRootBeforeSave'](_0x7b2648);const _0x22065d=this['editor']['data']['toView'](_0x7b2648,{}),_0x5aa7ab=Array['from'](_0x22065d['getChildren']())['map'](_0xe1459a=>this['_getViewJson'](_0xe1459a));return JSON['stringify'](_0x5aa7ab);}['_getViewJson'](_0x14d7cc){if(_0x14d7cc['is']('$text'))return _0x14d7cc['data'];{const _0x190cbd=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0xa39848=_0x14d7cc,_0xa2ed6f=this['editor']['data']['htmlProcessor']['domConverter'],_0x4b50bf={'type':_0x190cbd['_getTypeCharForViewElement'](_0xa39848),'name':_0xa39848['name'],'attributes':Array['from'](_0xa39848['getAttributes']()),'children':Array['from'](_0xa39848['getChildren']())['map'](_0x3b1021=>this['_getViewJson'](_0x3b1021))};if(_0x14d7cc['is']('uiElement')&&'$comment'!=_0x14d7cc['name']){const _0x250b43=_0x14d7cc['render'](_0xa2ed6f['domDocument'],_0xa2ed6f);_0x4b50bf['children']['push'](_0x250b43['outerHTML']);}else{if(_0x14d7cc['is']('rawElement')){const _0x10be4b=_0xa2ed6f['domDocument']['createElement'](_0xa39848['name']);_0x14d7cc['render'](_0x10be4b,_0xa2ed6f),_0x4b50bf['children']['push'](_0x10be4b['innerHTML']);}}const _0x12e60e=Array['from'](_0xa39848['getCustomProperties']());_0x12e60e['length']>0x0&&(_0x4b50bf['customProperties']=_0x12e60e);const _0x420443=_0xa39848['getFillerOffset']();return null!==_0x420443&&(_0x4b50bf['fillerOffset']=_0x420443),_0x4b50bf;}}['_markChanges'](_0x467163,_0x51dac4,_0x535ba3,_0x596d80,_0x73d203){let _0x54eded=null,_0x37e2ef=null,_0x540eff=0x0;const _0x3a7611=this['editor']['model'];for(let _0x38a656=0x0;_0x38a656<_0x51dac4['length'];_0x38a656++){const _0x52fc51=this['_getVidAttributeName'](_0x51dac4[_0x38a656]),_0x21a424=_0x51dac4[_0x38a656]['item']['getAttribute'](_0x52fc51),_0x1ecb45=_0x535ba3['get'](_0x21a424),_0x579dbf=_0x38a656==_0x51dac4['length']-0x1;(!_0x54eded&&_0x1ecb45&&(_0x54eded=_0x1ecb45,_0x37e2ef=_0x51dac4[_0x38a656]),_0x54eded&&(!_0x1ecb45||_0x1ecb45['userId']!=_0x54eded['userId']))&&(_0x4baa3e(_0x1ecb45,P(_0x37e2ef,_0x467163,_0x3a7611),P(_0x51dac4[_0x38a656],_0x467163,_0x3a7611)),_0x54eded=_0x1ecb45||null,_0x37e2ef=_0x1ecb45?_0x51dac4[_0x38a656]:null),_0x54eded&&_0x579dbf&&_0x4baa3e(_0x1ecb45,P(_0x37e2ef,_0x467163,_0x3a7611),V(_0x51dac4[_0x38a656],_0x467163,_0x3a7611));}function _0x4baa3e(_0x41e028,_0x33243a,_0x5cce14){const _0x11e0b8=_0x54eded['userId'],_0x44dc29='revision:'+_0x596d80+':'+_0x11e0b8+':'+_0x540eff++,_0x1ed623=_0x3a7611['createRange'](_0x33243a,_0x5cce14);_0x467163['markers']['set'](_0x44dc29,_0x1ed623),null!==_0x11e0b8&&_0x73d203['add'](_0x11e0b8);}}['_getVidAttributeName'](_0x6bef37){switch(_0x6bef37['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x3d44dd,_0x558ccf){_0x3d44dd['baseVersion']=null;for(const _0x55a952 in _0x3d44dd){const _0x1ec816=_0x3d44dd[_0x55a952];if(_0x1ec816 instanceof _0x3b6bf5){const _0xfd4afa=_0x558ccf['get'](_0x1ec816['root']['rootName']);_0x3d44dd[_0x55a952]=this['_fixPosition'](_0x1ec816,_0xfd4afa);}if(_0x1ec816 instanceof _0x4fa97a){const _0x50d790=_0x558ccf['get'](_0x1ec816['root']['rootName']);_0x3d44dd[_0x55a952]=this['_fixRange'](_0x1ec816,_0x50d790);}'root'===_0x55a952&&(_0x3d44dd['root']=_0x558ccf['get'](_0x3d44dd['root']['rootName']));}}['_fixRange'](_0x5f0fbe,_0x439bab){return this['editor']['model']['createRange'](this['_fixPosition'](_0x5f0fbe['start'],_0x439bab),this['_fixPosition'](_0x5f0fbe['end'],_0x439bab));}['_fixPosition'](_0x3a90d0,_0x1cc79b){return this['editor']['model']['createPositionFromPath'](_0x1cc79b,_0x3a90d0['path'],_0x3a90d0['stickiness']);}['_handleInsertOperation'](_0x31126a){const _0x4b1205=this['_idsRoots']['get'](_0x31126a['position']['root']['rootName']),_0x588ad2=this['_fixPosition'](_0x31126a['position'],_0x4b1205),_0x258bd4=null===_0x31126a['_authorId']?null:_0x31126a['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x43ef90=_0x588ad2['parent'],_0x1fc98b=this['_revisionId'],_0x24bdaf=[];for(const _0x384d82 of _0x31126a['nodes'])if(_0x384d82['is']('element'))_0x24bdaf['push'](this['_makeIdsRoot'](_0x384d82));else{for(let _0x3b1bbd=0x0;_0x3b1bbd<_0x384d82['offsetSize'];_0x3b1bbd++)_0x24bdaf['push'](new _0x17ffdc('$text',{'vid':this['_revisionId']++}));}const _0x2f6638=this['_revisionId'];for(let _0x5efcd5=_0x1fc98b;_0x5efcd5<_0x2f6638;_0x5efcd5++)this['_touched']['set'](_0x5efcd5,{'userId':_0x258bd4});_0x43ef90['_insertChild'](_0x588ad2['offset'],_0x24bdaf);}['_handleMoveOperation'](_0x243bb3){(_0x243bb3=this['_cloneOperation'](_0x243bb3,this['_idsRoots']))['_execute']();const _0x4ad82f=null===_0x243bb3['_authorId']?null:_0x243bb3['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x25d0d9=_0x243bb3['getMovedRangeStart'](),_0x2c4b88=_0x25d0d9['parent'],_0x3b2b40=_0x25d0d9['offset'];!function _0x246ebf(_0x421561,_0x53fc9d,_0x81434a,_0x5c91e0){for(let _0x207784=_0x81434a;_0x207784<_0x5c91e0;_0x207784++){const _0x2c0bc9=_0x53fc9d['getChild'](_0x207784);_0x2c0bc9['is']('element','$text')?_0x421561['set'](_0x2c0bc9['getAttribute']('vid'),{'userId':_0x4ad82f}):(_0x421561['set'](_0x2c0bc9['getAttribute']('vid_start'),{'userId':_0x4ad82f}),_0x246ebf(_0x421561,_0x2c0bc9,0x0,_0x2c0bc9['childCount']),_0x421561['set'](_0x2c0bc9['getAttribute']('vid_end'),{'userId':_0x4ad82f}));}}(this['_touched'],_0x2c4b88,_0x3b2b40,_0x3b2b40+_0x243bb3['howMany']);}['_handleMergeOperation'](_0x41d6cc){const _0x60dd73=null===(_0x41d6cc=this['_cloneOperation'](_0x41d6cc,this['_idsRoots']))['_authorId']?null:_0x41d6cc['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x5d5e99=_0x41d6cc['targetPosition']['parent'],_0x2eeac2=_0x41d6cc['sourcePosition']['parent'],_0x40563a=_0x5d5e99['getAttribute']('vid_end'),_0x25c222=_0x2eeac2['getAttribute']('vid_start');_0x5d5e99['_setAttribute']('vid_end',_0x2eeac2['getAttribute']('vid_end')),_0x2eeac2['_setAttribute']('vid_end',_0x40563a),this['_touched']['set'](_0x25c222,{'userId':_0x60dd73}),this['_touched']['set'](_0x40563a,{'userId':_0x60dd73}),_0x41d6cc['_execute']();}['_handleSplitOperation'](_0x205b9a){const _0x4bfecd=null===(_0x205b9a=this['_cloneOperation'](_0x205b9a,this['_idsRoots']))['_authorId']?null:_0x205b9a['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x52c995=_0x205b9a['graveyardPosition'],_0x2c1bbb=_0x205b9a['splitPosition']['parent'];_0x205b9a['_execute']();const _0x1d1770=_0x2c1bbb['getAttribute']('vid_end'),_0x313705=_0x205b9a['insertionPosition']['nodeAfter'];if(_0x52c995){const _0x262da1=_0x313705['getAttribute']('vid_end'),_0x882c1=_0x2c1bbb['getAttribute']('vid_end');_0x2c1bbb['_setAttribute']('vid_end',_0x262da1),_0x313705['_setAttribute']('vid_end',_0x882c1),this['_touched']['set'](_0x2c1bbb['getAttribute']('vid_end'),{'userId':_0x4bfecd}),this['_touched']['set'](_0x313705['getAttribute']('vid_start'),{'userId':_0x4bfecd});}else{const _0x273a80=this['_revisionId']++,_0x19ae3e=this['_revisionId']++;_0x2c1bbb['_setAttribute']('vid_end',_0x273a80),_0x313705['_setAttribute']('vid_start',_0x19ae3e),_0x313705['_setAttribute']('vid_end',_0x1d1770),this['_touched']['set'](_0x273a80,{'userId':_0x4bfecd}),this['_touched']['set'](_0x19ae3e,{'userId':_0x4bfecd});}}['_handleMarkerOperation'](_0xe99de7){if(!_0xe99de7['affectsData'])return;const _0x104869=(_0xe99de7=this['_cloneOperation'](_0xe99de7,this['_diffRoots']))['oldRange']?_0xe99de7['oldRange']['root']:null,_0x15518c=_0xe99de7['newRange']?_0xe99de7['newRange']['root']:null;_0x104869&&this['_markers']['delete'](_0xe99de7['name']),_0x15518c&&this['_markers']['set'](_0xe99de7['name'],_0xe99de7['newRange']['clone']());const _0x26c401=null===_0xe99de7['_authorId']?null:_0xe99de7['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0xb4814=_0xe99de7['name'];if(!this['_touchedMarkers']['has'](_0xb4814))return void this['_touchedMarkers']['set'](_0xb4814,{'range':_0xe99de7['oldRange'],'userId':_0x26c401});const _0x25465c=this['_touchedMarkers']['get'](_0xb4814),_0x20f811=_0x25465c['range'],_0x510360=_0xe99de7['newRange'];null==_0x20f811&&null==_0x510360||_0x20f811&&_0x510360&&_0x20f811['isEqual'](_0x510360)?this['_touchedMarkers']['delete'](_0xe99de7['name']):_0x25465c['userId']=_0x26c401;}['_handleRootOperation'](_0x2debdd,_0x22c4b4){this['_diffRoots']['has'](_0x2debdd['rootName'])?this['_diffRoots']['get'](_0x2debdd['rootName'])['_isAttached']=_0x2debdd['isAdd']:(this['_diffRoots']['set'](_0x2debdd['rootName'],N(_0x2debdd['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x2debdd['rootName'],{}),_0x22c4b4&&this['_idsRoots']['set'](_0x2debdd['rootName'],N(_0x2debdd['rootName'],!0x0)));const _0x38444c=null===_0x2debdd['_authorId']?null:_0x2debdd['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x1f8848=this['_touchedRoots']['get'](_0x2debdd['rootName']);_0x1f8848&&_0x1f8848['userId']===_0x38444c?this['_touchedRoots']['delete'](_0x2debdd['rootName']):this['_touchedRoots']['set'](_0x2debdd['rootName'],{'userId':_0x38444c,'isAttached':_0x2debdd['isAdd']});}['_handleRootAttributeOperation'](_0x247f91){const _0x34ed7e=this['_diffRootsAttributes']['get'](_0x247f91['root']['rootName']);null===_0x247f91['newValue']?delete _0x34ed7e[_0x247f91['key']]:_0x34ed7e[_0x247f91['key']]=_0x247f91['newValue'];}}function x(_0x51b27d){const _0x15a7e1=N(_0x51b27d['rootName'],_0x51b27d['isAttached']());for(const _0x27c568 of _0x51b27d['getChildren']()){const _0x10d759=_0x27c568['_clone'](!0x0);_0x15a7e1['_appendChild'](_0x10d759);}return _0x15a7e1;}function N(_0x2860d9,_0x59ff27=!0x0){const _0x3c23a5=new _0x3dd9df();return _0x3c23a5['rootName']=_0x2860d9,_0x3c23a5['_isAttached']=_0x59ff27,_0x3c23a5['isAttached']=()=>_0x3c23a5['_isAttached'],_0x3c23a5;}function P(_0x4e9ff2,_0x466e64,_0x894de0){const _0x129a62='elementEnd'==_0x4e9ff2['type']?_0x894de0['createPositionAt'](_0x4e9ff2['item'],'end'):_0x894de0['createPositionBefore'](_0x4e9ff2['item']);return _0x894de0['createPositionFromPath'](_0x466e64,_0x129a62['path'],_0x129a62['stickiness']);}function V(_0x48e81c,_0x1c82df,_0x38a139){const _0x2137c2='elementStart'==_0x48e81c['type']?_0x38a139['createPositionAt'](_0x48e81c['item'],0x0):_0x38a139['createPositionAfter'](_0x48e81c['item']);return _0x38a139['createPositionFromPath'](_0x1c82df,_0x2137c2['path'],_0x2137c2['stickiness']);}class he extends/* #__PURE__ -- @preserve */
25
+ _0x380409(_0x49001e){['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x31d51b,_0x5411f0){super(_0x31d51b),this['focusTracker']=new _0x5edbfd(),this['keystrokes']=new _0x389bed(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x5411f0),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'](),_0xfab003({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x2cdfa2=_0x491511=>_0x491511['stopPropagation']();this['keystrokes']['set']('arrowright',_0x2cdfa2),this['keystrokes']['set']('arrowleft',_0x2cdfa2),this['keystrokes']['set']('arrowup',_0x2cdfa2),this['keystrokes']['set']('arrowdown',_0x2cdfa2);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x29dba8){this['revisionNameInputView']['fieldView']['element']['value']=_0x29dba8['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x420848){const _0x330929=new ti(this['locale'],_0x1f20a),_0x4fbcf3=_0x330929['fieldView'];_0x4fbcf3['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x39af00=R(this['locale'],'Name\x20of\x20the\x20revision');return!_0x420848&&(_0x39af00+='\x20('+R(this['locale'],'optional')+')'),(_0x330929['label']=_0x39af00,_0x4fbcf3['on']('input',()=>{this['revisionNameInputValue']=_0x4fbcf3['element']['value']['trim']();}),_0x330929);}}class v extends _0x3a7117{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h];}['_saveRevisionFormView'];['init'](){const _0x27a983=this['editor'],_0x240c15=_0x27a983['plugins']['get']('RevisionTracker');_0x27a983['ui']['componentFactory']['add']('revisionHistory',_0x27d8ae=>{const _0x58ddd4=_0x546af5(_0x27d8ae),_0xb55ee0=_0x58ddd4['panelView']['children'],_0x4e1c77=new _0x3694dd(_0x27d8ae),_0x1e64d2=new _0x4af6be(_0x27d8ae),_0x2407f5=new _0x356661(_0x27d8ae),_0x5cea8c=new _0x4af6be(_0x27d8ae),_0x6f5eaf=new _0x356661(_0x27d8ae);return _0x58ddd4['bind']('isEnabled')['to'](_0x240c15,'isReady',_0x240c15,'isEnabled',_0x27a983,'isReadOnly',(_0x48269f,_0x204c5f,_0x296a8f)=>_0x48269f&&_0x204c5f&&!_0x296a8f),_0x58ddd4['buttonView']['set']({'icon':_0x80b955,'label':R(_0x27d8ae,'Revision\x20history'),'tooltip':!0x0}),_0x2407f5['set']({'label':R(_0x27d8ae,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x2407f5['bind']('isEnabled')['to'](_0x240c15,'isReady',_0x240c15,'isEnabled',_0x27a983,'isReadOnly',(_0x7eb0e6,_0x5a6e98,_0xda837e)=>_0x7eb0e6&&_0x5a6e98&&!_0xda837e),_0x2407f5['on']('execute',()=>this['_showDialog']()),_0x6f5eaf['set']({'label':R(_0x27d8ae,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x6f5eaf['bind']('isEnabled')['to'](_0x240c15,'isReady',_0x27a983,'isReadOnly',(_0x16885a,_0x50a20c)=>_0x16885a&&!_0x50a20c),_0x6f5eaf['on']('execute',()=>{_0x27a983['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x58ddd4['isOpen']=!0x1,_0x27a983['editing']['view']['focus']();}),_0x1e64d2['children']['add'](_0x2407f5),_0x5cea8c['children']['add'](_0x6f5eaf),_0x4e1c77['role']='menu',_0x4e1c77['items']['addMany']([_0x1e64d2,_0x5cea8c]),_0xb55ee0['add'](_0x4e1c77),_0x58ddd4;}),_0x27a983['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x3df317=this['editor'],_0x1bc9f0=_0x3df317['locale'],_0xbe4785=new _0x2037e5(_0x1bc9f0),_0xce3a58=new _0x40df4f(_0x1bc9f0);_0xbe4785['buttonView']['set']({'icon':_0x80b955,'label':R(_0x1bc9f0,'Revision\x20history')});const _0x283809=new _0x1c4f9c(_0x1bc9f0,_0xbe4785),_0x36c091=new _0x1e03e7(_0x1bc9f0);_0x36c091['set']({'label':R(_0x1bc9f0,'Save\x20current\x20revision')}),_0x36c091['delegate']('execute')['to'](_0xbe4785),_0x36c091['on']('execute',()=>{this['_showDialog']();}),_0x283809['children']['add'](_0x36c091),_0xce3a58['items']['add'](_0x283809);const _0x197229=new _0x1c4f9c(_0x1bc9f0,_0xbe4785),_0x5c8000=new _0x1e03e7(_0x1bc9f0);return _0x5c8000['set']({'label':R(_0x1bc9f0,'Open\x20revision\x20history')}),_0x5c8000['delegate']('execute')['to'](_0xbe4785),_0x5c8000['on']('execute',()=>{_0x3df317['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x197229['children']['add'](_0x5c8000),_0xce3a58['items']['add'](_0x197229),_0xbe4785['panelView']['children']['add'](_0xce3a58),_0xbe4785;}['_showDialog'](){const _0x3d2bbd=this['editor'],_0x1937ab=_0x3d2bbd['locale'],_0x2ad05=_0x3d2bbd['plugins']['get']('Dialog'),_0x395208=_0x3d2bbd['plugins']['get']('RevisionTracker');function _0x3b291a(_0x142318){_0x3d2bbd['config']['get']('revisionHistory.requireRevisionName')&&''===_0x142318['revisionName']?_0x142318['revisionNameInputView']['errorText']=R(_0x1937ab,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x3d2bbd['plugins']['get'](h)['saveRevision']({'name':_0x142318['revisionName']}),_0x2ad05['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x3b291a(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x2ad05['show']({'id':'revisionSave','title':R(_0x1937ab,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':R(_0x3d2bbd['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x2ad05['hide']()},{'label':R(_0x3d2bbd['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x4f89eb){_0x4f89eb['bind']('isEnabled')['to'](_0x395208,'isReady',_0x395208,'isEnabled',_0x3d2bbd,'isReadOnly',(_0x59b1a6,_0x4deea5,_0x5c8cb0)=>_0x59b1a6&&_0x4deea5&&!_0x5c8cb0);},'onExecute':()=>_0x3b291a(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x37c8d9=this['editor'],_0xa3547e=_0x37c8d9['locale'];this['_saveRevisionFormView']=new he(_0xa3547e,_0x37c8d9['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class z extends _0x49001e{['changeId'];['_model'];constructor(_0x205252,_0x37531f){super(_0x205252),this['_model']=_0x37531f,this['changeId']=_0x37531f['id'];const _0x3a84ab=this['bindTemplate'],_0x1e22c3=R(_0x205252,_0x37531f['data']['isSuggestion']?'Suggested\x20by':'add'==_0x37531f['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x37531f['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x3a84ab['to']('type',_0x245c9d=>'ck-revision-change__'+_0x245c9d)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x1e22c3}]},{'text':'\x20'+_0x37531f['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class G extends/* #__PURE__ -- @preserve */
26
+ _0x208a0d(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0xed8031){super(),this['id']=_0xed8031['id']||_0x17ccda(),this['author']=_0xed8031['author'],this['type']=_0xed8031['type'],this['data']=_0xed8031['data']||{},this['rootName']=_0xed8031['rootName'],this['set']('createdAt',_0xed8031['createdAt']);}['toJSON'](){return{'id':this['id'],'authorId':this['author']['id'],'type':this['type'],'data':this['data'],'createdAt':this['createdAt']};}}class J{['newRevisionId'];['oldRevisionId'];['changes'];constructor(_0x1c815f,_0x4a60e6){this['newRevisionId']=_0x1c815f,this['oldRevisionId']=_0x4a60e6,this['changes']=new _0x2e7af1();}['_setChanges'](_0xf1db79){for(const _0x2b7dcd of _0xf1db79)this['changes']['add'](_0x2b7dcd);}}class l extends _0x3a7117{['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[_0x315441,_0x46b4da,S,$];}constructor(_0x2a3c09){super(_0x2a3c09),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',(_0x1ddabc,_0x4a5c18,_0x326841)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x284fe0=>{for(const _0xf4a196 of this['editor']['editing']['view']['document']['roots'])_0x326841?_0x284fe0['removeClass']('ck-editor__editable__overlay',_0xf4a196):_0x284fe0['addClass']('ck-editor__editable__overlay',_0xf4a196);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x301061=>null!==_0x301061),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x3d6f9a,_0x19a934,_0x10ff48)=>_0x3d6f9a&&_0x10ff48?_0x19a934['changes']['getIndex'](_0x10ff48):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x535f62,_0x54cd7a)=>_0x535f62?_0x54cd7a['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0x46b4da);}['init'](){const _0x2dc82d=this['editor'],_0xff7f56=new ot(_0x2dc82d,{'direction':'backward'}),_0x169b6b=new ot(_0x2dc82d,{'direction':'forward'});(_0x2dc82d['commands']['add']('showPreviousChange',_0xff7f56),_0x2dc82d['commands']['add']('showNextChange',_0x169b6b),_0x2dc82d['commands']['add']('restoreRevision',new nt(_0x2dc82d)),this['on']('change:numberOfChanges',()=>{_0xff7f56['refresh'](),_0x169b6b['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x2dc82d['enableReadOnlyMode']('revision-viewer'),_0x2dc82d['plugins']['has']('WidgetToolbarRepository'))&&_0x2dc82d['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x19c13b){return await this['_utils']['loadRevisionData'](_0x19c13b,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x19c13b);}async['getRevisionRootsAttributes'](_0x37a517){return await this['_utils']['loadRevisionData'](_0x37a517,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x37a517);}async['compare'](_0x423e1b,_0x1cf020,_0x3cac5d=!0x1){if(!this['isEnabled'])return;const _0x4fe04c=this['diff'],_0x157fc=this['repository'],_0x47deef='string'==typeof _0x423e1b?_0x157fc['getRevision'](_0x423e1b):_0x423e1b,_0x5a2295='string'==typeof _0x1cf020?_0x157fc['getRevision'](_0x1cf020):_0x1cf020,_0x1b4b94=_0x47deef['id'],_0x3be0b3=_0x5a2295?_0x5a2295['id']:null;if(!_0x3cac5d&&this['diff']&&this['diff']['newRevisionId']===_0x1b4b94&&this['diff']['oldRevisionId']===_0x3be0b3)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new J(_0x1b4b94,_0x3be0b3);const _0x95795c=this['_getRevisionsRange'](_0x47deef,_0x5a2295,!0x0)['map'](_0x2f19d0=>this['_utils']['loadRevisionData'](_0x2f19d0,this['adapter']));return _0x95795c['push'](new Promise(_0x48cb5d=>{setTimeout(_0x48cb5d,0x14);})),Promise['all'](_0x95795c)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x498cc2=this['_getDiff'](_0x1b4b94,_0x3be0b3);for(const _0x5bf397 of _0x498cc2['changes'])this['_changeIdToChange']['set'](_0x5bf397['id'],_0x5bf397);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x477d5d=>{for(const _0x34acf1 of this['editor']['model']['document']['getRootNames']())_0x477d5d['detachRoot'](_0x34acf1);for(const _0x54b2f1 of Object['keys'](_0x498cc2['model'])){const _0x1f58b5=_0x477d5d['addRoot'](_0x54b2f1);for(const _0x1d9ec0 of Object['keys'](_0x498cc2['attributes'][_0x54b2f1]))_0x477d5d['setAttribute'](_0x1d9ec0,_0x498cc2['attributes'][_0x54b2f1][_0x1d9ec0],_0x1f58b5);_0x477d5d['insert'](_0x498cc2['model'][_0x54b2f1],_0x1f58b5,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x498cc2['changes'])),this['isReady']=!0x0;})['catch'](_0x226b6b=>{console['error'](_0x226b6b),this['_cleanUp'](),_0x4fe04c&&(this['diff']=_0x4fe04c),this['isReady']=!0x0;});}['addRevisionData'](_0x362815,_0x529ae4){const _0x5eec4b=this['repository']['createRevision'](_0x362815);return _0x5eec4b['on']('_update',(_0x15ad0e,_0x29e090,_0x3a9740)=>_0x529ae4(_0x29e090,_0x3a9740,_0x5eec4b)),this['repository']['addRevision'](_0x5eec4b),_0x5eec4b;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x2879e0=>{for(const _0x109f9b of this['editor']['model']['document']['getRootNames']())_0x2879e0['detachRoot'](_0x109f9b);});}['_sortAndFilterDiffChanges'](_0x4cf3cf){const _0x473c69=[],_0x49bf98=new Map();for(const _0x422e0d of this['editor']['model']['document']['getRootNames']()){const _0x4bf183=this['editor']['editing']['view']['getDomRoot'](_0x422e0d);if(!_0x4bf183)continue;const _0x55b4a6=_0x4bf183['getClientRects']()['item'](0x0);_0x55b4a6&&(_0x473c69['push'](_0x422e0d),_0x49bf98['set'](_0x422e0d,_0x55b4a6));}return _0x473c69['sort']((_0x3fee38,_0x4dada6)=>{const _0x5bdef7=_0x49bf98['get'](_0x3fee38),_0x2c95ab=_0x49bf98['get'](_0x4dada6);return _0x5bdef7['y']-_0x2c95ab['y']||_0x5bdef7['x']-_0x2c95ab['x'];}),(_0x4cf3cf=_0x4cf3cf['filter'](_0x29c67b=>_0x473c69['includes'](_0x29c67b['rootName'])))['sort']((_0x142bb7,_0x200679)=>_0x473c69['indexOf'](_0x142bb7['rootName'])-_0x473c69['indexOf'](_0x200679['rootName'])),_0x4cf3cf;}['_makeTape'](_0x522578){const _0x340e36=Array['from'](_0x522578['markers'])['filter'](([_0x492cd4,_0x5d43dc])=>_0x492cd4['startsWith']('revision:')&&!_0x5d43dc['isCollapsed']),_0x46ade3=Array['from'](this['editor']['model']['createRangeIn'](_0x522578)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x340e36['length'])for(const _0x5b4bf7 of _0x46ade3){const [_0x41106a,_0x1c407d]=_0x340e36[0x0],[,_0x310d60,_0x558c6b]=_0x41106a['split'](':');if(_0x1c407d['end']['isEqual'](_0x5b4bf7['nextPosition'])&&_0x340e36['shift'](),(_0x5b4bf7['previousPosition']['isEqual'](_0x1c407d['start'])||_0x5b4bf7['previousPosition']['isAfter'](_0x1c407d['start']))&&('insertion'==_0x310d60?_0x5b4bf7['isAdded']={'userId':_0x558c6b}:'deletion'==_0x310d60&&(_0x5b4bf7['isRemoved']={'userId':_0x558c6b})),0x0==_0x340e36['length'])break;}return _0x46ade3;}['_refreshStartEndIndex'](_0x4fa494){const _0x171f12=new Map();for(let _0x390053=0x0;_0x390053<_0x4fa494['length'];_0x390053++)'text'===_0x4fa494[_0x390053]['type']?(_0x4fa494[_0x390053]['item']['startIndex']=_0x390053,_0x4fa494[_0x390053]['item']['endIndex']=_0x390053):('elementStart'===_0x4fa494[_0x390053]['type']?_0x4fa494[_0x390053]['item']['startIndex']=_0x390053:'elementEnd'===_0x4fa494[_0x390053]['type']&&(_0x4fa494[_0x390053]['item']['endIndex']=_0x390053),_0x171f12['set'](_0x4fa494[_0x390053]['id'],_0x390053));for(const _0x3d106e of _0x171f12['values']())'elementStart'===_0x4fa494[_0x3d106e]['type']?_0x4fa494[_0x3d106e]['item']['endIndex']=_0x171f12['get'](_0x4fa494[_0x3d106e]['pairId']):'elementEnd'===_0x4fa494[_0x3d106e]['type']&&(_0x4fa494[_0x3d106e]['item']['startIndex']=_0x171f12['get'](_0x4fa494[_0x3d106e]['pairId']));}['_processTape'](_0x2f8af2){for(let _0x428d6f=0x0;_0x428d6f<_0x2f8af2['length'];_0x428d6f++){if('elementStart'===_0x2f8af2[_0x428d6f]['type'])_0x2f8af2[_0x428d6f]['item']['startIndex']=_0x428d6f;else{if('elementEnd'===_0x2f8af2[_0x428d6f]['type']){_0x2f8af2[_0x428d6f]['item']['endIndex']=_0x428d6f;const _0x36b180=_0x2f8af2[_0x428d6f]['item']['startIndex'];_0x2f8af2[_0x36b180]['pairId']=_0x2f8af2[_0x428d6f]['id'],_0x2f8af2[_0x428d6f]['pairId']=_0x2f8af2[_0x36b180]['id'];}else _0x2f8af2[_0x428d6f]['item']['startIndex']=_0x428d6f,_0x2f8af2[_0x428d6f]['item']['endIndex']=_0x428d6f,_0x2f8af2[_0x428d6f]['pairId']=null;}_0x2f8af2[_0x428d6f]['markersStart']||(_0x2f8af2[_0x428d6f]['markersStart']=[],_0x2f8af2[_0x428d6f]['markersEnd']=[]);}}['_markInsertions'](_0x40a0d6,_0x1ce931){const _0x1abeeb=_0x40a0d6['filter'](_0x2c174f=>!_0x2c174f['isAdded']);for(let _0x50fb62=0x0;_0x50fb62<_0x1ce931['length'];_0x50fb62++)_0x1ce931[_0x50fb62]['isAdded']&&(_0x1abeeb[_0x50fb62]['isAdded']=_0x1ce931[_0x50fb62]['isAdded']);}['_getDiff'](_0xd18861,_0x471013=null){const _0x3d51af=this['repository']['getRevision'](_0xd18861),_0xffb1bc=_0x471013?this['repository']['getRevision'](_0x471013):null,_0x1c2045=this['_getRevisionsRange'](_0x3d51af,_0xffb1bc),_0x180fe1=_0x1c2045[_0x1c2045['length']-0x1],_0x224581=new Map(),_0x4f3b7f={'model':{},'attributes':{},'changes':[]},_0x1249ba=new Set(),_0x4dc627=new Map();for(let _0x493cb9=_0x1c2045['length']-0x1;_0x493cb9>=0x0;_0x493cb9--){const _0x148797=_0x1c2045[_0x493cb9];for(const _0xfb59c1 of Object['keys'](_0x148797['diffData']))if(_0x148797['diffData'][_0xfb59c1]['attachChange']){const _0x76d278=_0x148797['diffData'][_0xfb59c1]['attachChange'];_0x76d278['isAttached']?(_0x1249ba['add'](_0xfb59c1),_0x4dc627['has'](_0xfb59c1)&&_0x4dc627['get'](_0xfb59c1)['userId']==_0x76d278['userId']?_0x4dc627['delete'](_0xfb59c1):_0x4dc627['set'](_0xfb59c1,_0x76d278)):_0x4dc627['has'](_0xfb59c1)?(_0x1249ba['delete'](_0xfb59c1),_0x4dc627['delete'](_0xfb59c1)):(_0x1249ba['add'](_0xfb59c1),_0x4dc627['set'](_0xfb59c1,_0x76d278));}else _0x1249ba['add'](_0xfb59c1);}for(const _0xc1de74 of _0x1249ba){const _0x5ad2ae=_0x4dc627['has'](_0xc1de74)&&!_0x4dc627['get'](_0xc1de74)['isAttached'];let _0x317307=_0x5ad2ae?_0x1c2045['length']-0x1:0x0;const _0x52f756=_0x5ad2ae?-0x1:0x1;for(;_0x1c2045[_0x317307];){const _0x25c8ee=_0x1c2045[_0x317307];if(_0x25c8ee['diffData'][_0xc1de74]){const _0x2045e3=_0x5ad2ae?_0x25c8ee['diffData'][_0xc1de74]['attributesBefore']:_0x25c8ee['diffData'][_0xc1de74]['attributesAfter'];_0x4f3b7f['attributes'][_0xc1de74]=_0x2045e3?_0x5d7334(_0x2045e3):{};break;}_0x317307+=_0x52f756;}}for(const _0x622b01 of _0x1c2045){_0x622b01['model']={};for(const _0x4f19c2 of _0x622b01['authors'])_0x224581['set'](_0x4f19c2['id'],_0x4f19c2);for(const _0x17706b of _0x1249ba){const _0x11c886=_0x622b01['diffData'][_0x17706b]?_0x622b01['diffData'][_0x17706b]['insertions']:'[]',_0x2b291a=_0x622b01['diffData'][_0x17706b]?_0x622b01['diffData'][_0x17706b]['deletions']:'[]';_0x622b01['model'][_0x17706b]={'insertions':this['_utils']['_makeModelFromViewString'](_0x11c886),'deletions':this['_utils']['_makeModelFromViewString'](_0x2b291a)};}}for(const _0x4dedb1 of _0x1249ba){let _0xe99f86=null,_0x2e8aba=0x0;const _0x2a941f=new Map(Array['from'](_0x3d51af['model'][_0x4dedb1]['insertions']['markers'])['filter'](([_0x4fc545])=>!_0x4fc545['startsWith']('revision:')));let _0x424bd6=0x0;for(const _0x6c685d of _0x1c2045){const _0x28492f=this['_makeTape'](_0x6c685d['model'][_0x4dedb1]['insertions']);_0x6c685d==_0x3d51af?(_0xe99f86=_0x28492f,_0x2e8aba=_0xe99f86['length'],_0xe99f86['forEach'](_0x22fd39=>{_0x22fd39['id']=_0x424bd6++;}),this['_processTape'](_0xe99f86)):this['_markInsertions'](_0xe99f86,_0x28492f);const _0x400361=_0xe99f86['filter'](_0x497e6d=>!_0x497e6d['isAdded'])['map'](_0x2b62b2=>_0x2b62b2['id']);let _0x3333d9=0x0;const _0x52bf5b=this['_makeTape'](_0x6c685d['model'][_0x4dedb1]['deletions']);_0x52bf5b['forEach'](_0x105230=>{_0x105230['isRemoved']?_0x105230['id']=_0x2e8aba++:_0x105230['id']=_0x400361[_0x3333d9++];}),this['_processTape'](_0x52bf5b),this['_setDistance'](_0xe99f86,'isAdded'),this['_setDistance'](_0x52bf5b,'isRemoved'),_0x6c685d==_0x3d51af&&this['_markMarkers'](_0xe99f86,_0x2a941f),_0xe99f86=this['_joinTapes'](_0xe99f86,_0x52bf5b),this['_refreshStartEndIndex'](_0xe99f86),this['_setDistance'](_0xe99f86,'isRemoved');}_0xe99f86=_0xe99f86['filter'](_0xe98ec1=>!(_0xe98ec1['isAdded']&&_0xe98ec1['isRemoved']));const _0x2554f7=new Map(_0x180fe1['model'][_0x4dedb1]['deletions']['markers']),_0x28eac2=new Set(_0x2a941f['keys']());for(const _0xa044e3 of _0x2554f7['keys']())_0x28eac2['delete'](_0xa044e3);this['_markSuggestions'](_0xe99f86,_0x28eac2),this['_fixObsoleteTags'](_0xe99f86),_0xe99f86=this['_removeMissingPairs'](_0xe99f86),_0xe99f86=this['_markMismatchedRemovedTags'](_0xe99f86),_0xe99f86=this['_removeUnsupportedChanges'](_0xe99f86);const {root:_0x642397,changes:_0x8524f7}=this['_makeModelFromTape'](_0xe99f86,_0x224581,_0x4dedb1);_0x4f3b7f['model'][_0x4dedb1]=_0x642397;const _0x505d2f=_0x4dc627['get'](_0x4dedb1);if(_0x505d2f){const _0x1587aa=_0x224581['get'](_0x505d2f['userId']),_0x45be6b=new G({'author':_0x1587aa,'type':_0x505d2f['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x4dedb1});_0x8524f7['unshift'](_0x45be6b),_0x4f3b7f['attributes'][_0x4dedb1]['revisionHistoryAttachChange']=_0x45be6b['id'];}_0x4f3b7f['changes']=_0x4f3b7f['changes']['concat'](_0x8524f7);}return _0x4f3b7f;}['_markMarkers'](_0x4396ab,_0xcd348f){for(let _0x3bb5f5=0x0;_0x3bb5f5<_0x4396ab['length'];_0x3bb5f5++)for(const [_0x3b6333,_0x65a022]of _0xcd348f)!_0x65a022['isCollapsed']&&_0x65a022['start']['isEqual'](_0x4396ab[_0x3bb5f5]['previousPosition'])&&_0x4396ab[_0x3bb5f5]['markersStart']['push'](_0x3b6333),_0x65a022['end']['isEqual'](_0x4396ab[_0x3bb5f5]['nextPosition'])&&_0x4396ab[_0x3bb5f5]['markersEnd']['push'](_0x3b6333);}['_joinTapes'](_0x1994ba,_0x372420){let _0x4cd127=[],_0x5acb27=0x0,_0x15fecd=0x0;for(;_0x5acb27<_0x1994ba['length']||_0x15fecd<_0x372420['length'];){const _0x3aafb1=_0x1994ba[_0x5acb27]||{},_0x4fbde3=_0x372420[_0x15fecd]||{};if(_0x3aafb1['id']==_0x4fbde3['id'])_0x5acb27++,_0x15fecd++,_0x4cd127['push'](_0x3aafb1);else{if(_0x4fbde3['isRemoved']&&_0x3aafb1['isAdded']){const {commonTape:_0x24f498,iEnd:_0x159e7a,jEnd:_0x27b4dd}=this['_threeWayMerge'](_0x1994ba,_0x5acb27,_0x372420,_0x15fecd);_0x4cd127=_0x4cd127['concat'](_0x24f498),_0x5acb27=_0x159e7a,_0x15fecd=_0x27b4dd;}else _0x4fbde3['isRemoved']?(_0x15fecd++,_0x4cd127['push'](_0x4fbde3)):(_0x5acb27++,_0x4cd127['push'](_0x3aafb1));}}return _0x4cd127;}['_markSuggestions'](_0x28d2fc,_0x37e4fd){const _0x168b52=[];for(let _0x23cdab=0x0;_0x23cdab<_0x28d2fc['length'];_0x23cdab++){for(let _0x2f1e2f=0x0;_0x2f1e2f<_0x28d2fc[_0x23cdab]['markersStart']['length'];_0x2f1e2f++){const _0x3a5047=_0x28d2fc[_0x23cdab]['markersStart'][_0x2f1e2f];if(!_0x37e4fd['has'](_0x3a5047))continue;const {group:_0x51962b,type:_0xd5137b,authorId:_0x36bb70}=_0x236cda(_0x3a5047);'revision-suggestion'!=_0x51962b||'insertion'!=_0xd5137b&&'deletion'!=_0xd5137b||(_0x168b52['unshift']({'type':_0xd5137b,'name':_0x3a5047,'userId':_0x36bb70}),_0x28d2fc[_0x23cdab]['markersStart']['splice'](_0x2f1e2f,0x1),_0x2f1e2f--);}_0x24ff76(_0x28d2fc[_0x23cdab]);for(let _0xffa4f2=0x0;_0xffa4f2<_0x28d2fc[_0x23cdab]['markersEnd']['length'];_0xffa4f2++){const _0x4307cb=_0x28d2fc[_0x23cdab]['markersEnd'][_0xffa4f2];if(!_0x37e4fd['has'](_0x4307cb))continue;const {group:_0x12124d,type:_0x3b3bcc}=_0x236cda(_0x4307cb);if('revision-suggestion'!=_0x12124d||'insertion'!=_0x3b3bcc&&'deletion'!=_0x3b3bcc)continue;_0x28d2fc[_0x23cdab]['markersEnd']['splice'](_0xffa4f2,0x1),_0xffa4f2--;const _0x22c694=_0x168b52['findIndex'](_0x149b68=>_0x149b68['name']==_0x4307cb);_0x22c694>-0x1&&_0x168b52['splice'](_0x22c694,0x1);}}function _0x236cda(_0x3d25bb){const _0x13e6c4=_0x3d25bb['split'](':');return{'group':_0x13e6c4[0x0],'type':_0x13e6c4[0x1],'subType':_0x13e6c4['length']>=0x5?_0x13e6c4[0x2]:null,'id':_0x13e6c4['length']<0x5?_0x13e6c4[0x2]:_0x13e6c4[0x3],'authorId':_0x13e6c4['length']<0x5?_0x13e6c4[0x3]:_0x13e6c4[0x4],'markerCount':0x6==_0x13e6c4['length']?_0x13e6c4[0x5]:null};}function _0x24ff76(_0x1597d2){for(let _0x4ba59d=0x0;_0x4ba59d<_0x168b52['length'];_0x4ba59d++){if(_0x1597d2['isAdded']&&'insertion'==_0x168b52[_0x4ba59d]['type']&&_0x1597d2['isAdded']['userId']==_0x168b52[_0x4ba59d]['userId'])return _0x1597d2['isAddSuggestion']=_0x168b52[_0x4ba59d],void delete _0x1597d2['isAdded'];if(!_0x1597d2['isAdded']&&!_0x1597d2['isRemoved']&&'deletion'==_0x168b52[_0x4ba59d]['type'])return void(_0x1597d2['isRemoveSuggestion']=_0x168b52[_0x4ba59d]);}}}['_setDistance'](_0x13665a,_0x5929bb){let _0x20fe60=0x0,_0x113098=!0x1;const _0xbd8623=new Map();for(const _0x39cd8c of _0x13665a)_0x39cd8c[_0x5929bb]?_0x113098&&(_0x20fe60++,_0x113098=!0x1):(_0x20fe60++,_0x113098=!0x0),_0xbd8623['set'](_0x39cd8c['id'],_0x20fe60);for(let _0x1e57d8=0x0;_0x1e57d8<_0x13665a['length'];_0x1e57d8++){if('isRemoved'==_0x5929bb&&_0x13665a[_0x1e57d8]['isAdded']||'isAdded'==_0x5929bb&&_0x13665a[_0x1e57d8]['isRemoved'])continue;if('text'==_0x13665a[_0x1e57d8]['type']){_0x13665a[_0x1e57d8]['distance']=0x0;continue;}const _0x2637b4=_0xbd8623['get'](_0x13665a[_0x1e57d8]['pairId']),_0x4ae732=_0xbd8623['get'](_0x13665a[_0x1e57d8]['id']);_0x13665a[_0x1e57d8]['distance']=_0x2637b4-_0x4ae732;}}['_getRevisionsRange'](_0x5ab780,_0x169853,_0x2c9001=!0x1){const _0x8c427d=[];let _0x1dec20=this['repository']['getIndex'](_0x5ab780),_0x3f8c89=this['repository']['getIndex'](_0x169853);for(-0x1==_0x3f8c89&&(_0x3f8c89=this['repository']['_revisions']['length'],_0x2c9001=!0x1);_0x1dec20<_0x3f8c89;)_0x8c427d['push'](this['repository']['getRevision'](_0x1dec20)),_0x1dec20++;return _0x2c9001&&_0x8c427d['push'](this['repository']['getRevision'](_0x1dec20)),_0x8c427d;}['_threeWayMerge'](_0x314fe0,_0x1a6f02,_0x30bc34,_0x5a0455){const _0x1a656a=this['editor']['model']['schema'];let _0x2cc467=_0x1a6f02;for(;_0x314fe0[_0x2cc467]&&_0x314fe0[_0x2cc467]['isAdded'];)_0x2cc467++;let _0x7dc418=_0x5a0455;for(;_0x30bc34[_0x7dc418]&&_0x30bc34[_0x7dc418]['isRemoved'];)_0x7dc418++;_0x4e5ebd(_0x314fe0,_0x1a6f02,_0x2cc467),_0x4e5ebd(_0x30bc34,_0x5a0455,_0x7dc418);const _0x55cbc1=_0x30bc34['slice'](_0x5a0455,_0x7dc418)['concat'](_0x314fe0['slice'](_0x1a6f02,_0x2cc467));return _0x55cbc1['sort']((_0x138b39,_0x33f610)=>_0x138b39['side']!=_0x33f610['side']?_0x138b39['side']-_0x33f610['side']:_0x138b39['level']!=_0x33f610['level']?_0x138b39['level']-_0x33f610['level']:_0x138b39['distance']!=_0x33f610['distance']?_0x33f610['distance']-_0x138b39['distance']:!!_0x138b39['isAdded']!=!!_0x33f610['isAdded']?-0x1==_0x138b39['side']||0x0==_0x138b39['side']?_0x138b39['isAdded']?-0x1:0x1:_0x138b39['isAdded']?0x1:-0x1:_0x138b39['index']-_0x33f610['index']),{'commonTape':_0x55cbc1,'iEnd':_0x2cc467,'jEnd':_0x7dc418};function _0x4e5ebd(_0x1161a7,_0x1210a1,_0x5b2482){let _0x36df28=-0x1,_0x3297e1=Number['POSITIVE_INFINITY'],_0xd6911f=!0x0;for(let _0x2c22e5=_0x1210a1;_0x2c22e5<_0x5b2482;_0x2c22e5++)if(_0x1a656a['isInline'](_0x1161a7[_0x2c22e5]['item'])||(_0xd6911f=!0x1),_0x1161a7[_0x2c22e5]['item']['startIndex']<_0x1210a1&&(_0x36df28=_0x2c22e5),_0x1161a7[_0x2c22e5]['item']['endIndex']>=_0x5b2482){_0x3297e1=_0x2c22e5;break;}_0xd6911f&&(_0x36df28=_0x5b2482-0x1);for(let _0x38370b=_0x1210a1;_0x38370b<_0x5b2482;_0x38370b++)_0x1161a7[_0x38370b]['side']=_0x38370b<=_0x36df28?-0x1:_0x38370b<_0x3297e1?0x0:0x1,_0x1161a7[_0x38370b]['index']=_0x38370b;let _0x224c26=0x0;for(let _0xd9cc9f=_0x1210a1;_0xd9cc9f<=_0x36df28;_0xd9cc9f++)0x0==_0x1161a7[_0xd9cc9f]['distance']?_0x1161a7[_0xd9cc9f]['level']=_0x224c26:(_0x224c26++,_0x1161a7[_0xd9cc9f]['level']=_0x224c26,_0x224c26++);for(let _0x12c519=_0x1210a1;_0x12c519<_0x5b2482;_0x12c519++)0x0==_0x1161a7[_0x12c519]['side']&&(_0x1161a7[_0x12c519]['level']=_0x224c26);_0x224c26=0x0;for(let _0x1ab84c=_0x5b2482-0x1;_0x1ab84c>=_0x3297e1;_0x1ab84c--)0x0==_0x1161a7[_0x1ab84c]['distance']?_0x1161a7[_0x1ab84c]['level']=_0x224c26:(_0x224c26--,_0x1161a7[_0x1ab84c]['level']=_0x224c26,_0x224c26--);}}['_fixObsoleteTags'](_0x3b9975){const _0x257d5e=new Map(),_0x2a9209=this['editor']['model']['schema'];for(let _0x46d17f=0x1;_0x46d17f<_0x3b9975['length'];_0x46d17f++){let _0x169467,_0x105e2f,_0x20bf42;const _0x383483=_0x3b9975[_0x46d17f],_0x348687=_0x3b9975[_0x46d17f-0x1];if('text'==_0x383483['type'])continue;if(_0x383483['type']!=_0x348687['type'])continue;if(!_0x2a9209['isBlock'](_0x348687['item'])||_0x2a9209['isLimit'](_0x348687['item']))continue;if(!_0x2a9209['isBlock'](_0x383483['item'])||_0x2a9209['isLimit'](_0x383483['item']))continue;if((_0x3b9975[_0x46d17f]['isAdded']||_0x3b9975[_0x46d17f]['isAddSuggestion'])&&_0x3b9975[_0x46d17f-0x1]['isRemoved'])_0x169467=_0x3b9975[_0x46d17f],_0x105e2f=_0x3b9975[_0x46d17f-0x1],_0x20bf42=_0x46d17f-0x1;else{if(!_0x3b9975[_0x46d17f]['isRemoved']||!_0x3b9975[_0x46d17f-0x1]['isAdded']&&!_0x3b9975[_0x46d17f-0x1]['isAddSuggestion'])continue;_0x169467=_0x3b9975[_0x46d17f-0x1],_0x105e2f=_0x3b9975[_0x46d17f],_0x20bf42=_0x46d17f;}const _0x2794f5=_0x169467['level']==_0x105e2f['level'],_0x7eacb9=Math['abs'](_0x169467['level'])<Math['abs'](_0x105e2f['level'])&&0x0==_0x105e2f['distance'];(_0x2794f5||_0x7eacb9)&&(_0x257d5e['set'](_0x105e2f['id'],_0x169467['id']),_0x3b9975['splice'](_0x20bf42,0x1),_0x46d17f--,_0x169467['isAdded']=!0x1);}for(let _0x5514d0=0x0;_0x5514d0<_0x3b9975['length'];_0x5514d0++)_0x257d5e['has'](_0x3b9975[_0x5514d0]['pairId'])&&(_0x3b9975[_0x5514d0]['pairId']=_0x257d5e['get'](_0x3b9975[_0x5514d0]['pairId']));}['_removeMissingPairs'](_0x5bf95a){const _0x25e849=new Set(_0x5bf95a['map'](_0x590c6f=>_0x590c6f['id']));for(let _0x41257f=0x0;_0x41257f<_0x5bf95a['length'];_0x41257f++)_0x25e849['has'](_0x5bf95a[_0x41257f]['pairId'])||0x0==_0x5bf95a[_0x41257f]['distance']||(_0x5bf95a[_0x41257f]['isIncorrect']=!0x0);return _0x5bf95a['filter'](_0x2ffb2a=>!_0x2ffb2a['isIncorrect']);}['_markMismatchedRemovedTags'](_0x2d6145){const _0xf16770=new Set();for(let _0x169f1b=0x0;_0x169f1b<_0x2d6145['length'];_0x169f1b++){if(_0xf16770['has'](_0x2d6145[_0x169f1b]['id'])&&_0x2d6145[_0x169f1b]['isRemoved']&&(_0x2d6145[_0x169f1b]['isIncorrect']=!0x0),_0x2d6145[_0x169f1b]['isIncorrect'])continue;if(0x0==_0x2d6145[_0x169f1b]['distance'])continue;if('elementStart'!=_0x2d6145[_0x169f1b]['type'])continue;if(null==_0x2d6145[_0x169f1b]['pairId'])continue;let _0x15a7a3=_0x169f1b+0x1,_0x1e1bdc=0x0;for(;_0x2d6145[_0x15a7a3]['id']!=_0x2d6145[_0x169f1b]['pairId'];)'elementStart'==_0x2d6145[_0x15a7a3]['type']?_0x1e1bdc++:'elementEnd'==_0x2d6145[_0x15a7a3]['type']&&_0x1e1bdc--,_0x15a7a3++;if(0x0!=_0x1e1bdc){if(_0x2d6145[_0x169f1b]['isRemoved'])_0x2d6145[_0x169f1b]['isIncorrect']=!0x0;else{for(;_0x15a7a3!=_0x169f1b;)_0x2d6145[_0x15a7a3]['isRemoved']&&0x0!=_0x2d6145[_0x15a7a3]['distance']&&(_0x2d6145[_0x15a7a3]['isIncorrect']=!0x0,_0xf16770['add'](_0x2d6145[_0x15a7a3]['pairId'])),_0x15a7a3--;}}}return _0x2d6145['filter'](_0x29706b=>!_0x29706b['isIncorrect']);}['_removeUnsupportedChanges'](_0x234114){const _0x59cabd=this['editor']['model']['schema'];for(let _0x21daad=0x0;_0x21daad<_0x234114['length'];_0x21daad++){if(!(_0x234114[_0x21daad]['isAdded']||_0x234114[_0x21daad]['isAddSuggestion']||_0x234114[_0x21daad]['isRemoved']||_0x234114[_0x21daad]['isRemoveSuggestion']))continue;if(0x0==_0x234114[_0x21daad]['distance'])continue;const _0x27fc02=_0x234114[_0x21daad]['item'];_0x59cabd['isBlock'](_0x27fc02)||_0x59cabd['isLimit'](_0x27fc02)||(_0x234114[_0x21daad]['isAdded']&&delete _0x234114[_0x21daad]['isAdded'],_0x234114[_0x21daad]['isAddSuggestion']&&delete _0x234114[_0x21daad]['isAddSuggestion'],_0x234114[_0x21daad]['isRemoveSuggestion']&&delete _0x234114[_0x21daad]['isRemoveSuggestion'],_0x234114[_0x21daad]['isRemoved']&&(_0x234114[_0x21daad]['isIncorrect']=!0x0));}return _0x234114['filter'](_0x5d7d98=>!_0x5d7d98['isIncorrect']);}['_makeModelFromTape'](_0x4be3d3,_0x579813,_0x240cc1){const _0x316954=new _0x3dd9df(),_0x310129=[],_0x29193e=new Map(),_0x164ca1=this['editor']['model'],_0x418693=_0x164ca1['schema'],_0x25ead6=[_0x316954],_0x96d7b4={},_0x5c744c={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x55a6a4=null;const _0x4cb274=[0x0];for(let _0x42d5d7=0x0;_0x42d5d7<_0x4be3d3['length'];_0x42d5d7++)if('elementStart'===_0x4be3d3[_0x42d5d7]['type']){_0x4be3d3[_0x42d5d7]['previousPosition']=_0x164ca1['createPositionFromPath'](_0x316954,_0x4cb274);const _0xbb580e=new _0x17ffdc(_0x4be3d3[_0x42d5d7]['item']['name'],_0x4be3d3[_0x42d5d7]['item']['getAttributes']());_0x25ead6[0x0]['_appendChild'](_0xbb580e),_0x4cb274['push'](0x0),_0x25ead6['unshift'](_0xbb580e),_0x4be3d3[_0x42d5d7]['nextPosition']=_0x164ca1['createPositionFromPath'](_0x316954,_0x4cb274);}else'elementEnd'===_0x4be3d3[_0x42d5d7]['type']?(_0x25ead6['shift'](),_0x4be3d3[_0x42d5d7]['previousPosition']=_0x164ca1['createPositionFromPath'](_0x316954,_0x4cb274),_0x4cb274['pop'](),_0x4cb274[_0x4cb274['length']-0x1]++,_0x4be3d3[_0x42d5d7]['nextPosition']=_0x164ca1['createPositionFromPath'](_0x316954,_0x4cb274)):(_0x4be3d3[_0x42d5d7]['previousPosition']=_0x164ca1['createPositionFromPath'](_0x316954,_0x4cb274),_0x55a6a4?_0x55a6a4['_data']+=_0x4be3d3[_0x42d5d7]['item']['data']:_0x55a6a4=new _0xedef05(_0x4be3d3[_0x42d5d7]['item']['data'],_0x4be3d3[_0x42d5d7]['item']['getAttributes']()),_0x4be3d3[_0x42d5d7+0x1]&&'text'===_0x4be3d3[_0x42d5d7+0x1]['type']&&_0x4f0c18(_0x55a6a4,_0x4be3d3[_0x42d5d7+0x1]['item'])||(_0x25ead6[0x0]['_appendChild'](_0x55a6a4),_0x55a6a4=null),_0x4cb274[_0x4cb274['length']-0x1]+=_0x4be3d3[_0x42d5d7]['item']['offsetSize'],_0x4be3d3[_0x42d5d7]['nextPosition']=_0x164ca1['createPositionFromPath'](_0x316954,_0x4cb274));for(let _0x489134=0x0;_0x489134<_0x4be3d3['length'];_0x489134++){const _0x4ed15e=_0x4be3d3[_0x489134]['previousPosition'],_0x246425=_0x4be3d3[_0x489134]['nextPosition'];for(const _0x4daac8 of _0x4be3d3[_0x489134]['markersStart'])_0x29193e['set'](_0x4daac8,{'start':_0x4ed15e,'end':null});_0x3a6861('isRemoveSuggestion',_0x489134,_0x4ed15e,_0x246425),_0x3a6861('isAddSuggestion',_0x489134,_0x4ed15e,_0x246425),_0x3a6861('isRemoved',_0x489134,_0x4ed15e,_0x246425),_0x3a6861('isAdded',_0x489134,_0x4ed15e,_0x246425);for(const _0xd45477 of _0x4be3d3[_0x489134]['markersEnd']){const _0x84c8ed=_0x29193e['get'](_0xd45477);_0x84c8ed?_0x84c8ed['end']=_0x246425:_0x29193e['set'](_0xd45477,{'start':_0x246425,'end':_0x246425});}}for(const [_0x301c8b,_0x5ad4dd]of _0x29193e){const _0x511be1=this['editor']['model']['createRange'](_0x5ad4dd['start'],_0x5ad4dd['end']);_0x316954['markers']['set'](_0x301c8b,_0x511be1);}return _0x310129['sort']((_0x424326,_0x27e7bc)=>{const _0x3a2d7b=_0x316954['markers']['get']('revision:'+_0x424326['id']),_0x18017a=_0x316954['markers']['get']('revision:'+_0x27e7bc['id']);return _0x3a2d7b['start']['isBefore'](_0x18017a['start'])?-0x1:_0x3a2d7b['start']['isAfter'](_0x18017a['start'])?0x1:_0x3a2d7b['end']['isBefore'](_0x18017a['end'])?-0x1:_0x3a2d7b['end']['isAfter'](_0x18017a['end'])?0x1:'add'===_0x424326['type']?-0x1:0x1;}),{'root':_0x316954,'changes':_0x310129};function _0x3a6861(_0x1ba05e,_0xb5ce88,_0x12510e,_0x9e50cf){const _0x321690=!!_0x4be3d3[_0xb5ce88][_0x1ba05e],_0x11f80f=_0x321690?_0x4be3d3[_0xb5ce88][_0x1ba05e]['userId']:null,_0x4d543d=_0xb5ce88===_0x4be3d3['length']-0x1,_0x5238c2=_0x5c744c[_0x1ba05e][0x0],_0x357692=_0x418693['isObject'](_0x4be3d3[_0xb5ce88]['item']);!_0x96d7b4[_0x1ba05e]&&_0x321690?_0x96d7b4[_0x1ba05e]={'start':_0x12510e,'tapeItem':_0x4be3d3[_0xb5ce88],'userId':_0x11f80f,'type':_0x1ba05e}:_0x96d7b4[_0x1ba05e]&&!_0x321690?(_0x96d7b4[_0x1ba05e]['end']=_0x12510e,_0x2d3177(_0x96d7b4[_0x1ba05e]),_0x96d7b4[_0x1ba05e]=null):_0x96d7b4[_0x1ba05e]&&_0x321690&&_0x96d7b4[_0x1ba05e]['userId']!==_0x11f80f&&(_0x96d7b4[_0x1ba05e]['end']=_0x12510e,_0x5238c2&&_0x5238c2['userId']===_0x96d7b4[_0x1ba05e]['userId']||_0x2d3177(_0x96d7b4[_0x1ba05e]),_0x96d7b4[_0x1ba05e]={'start':_0x12510e,'tapeItem':_0x4be3d3[_0xb5ce88],'userId':_0x11f80f,'type':_0x1ba05e}),_0x96d7b4[_0x1ba05e]&&_0x357692&&('elementStart'!==_0x4be3d3[_0xb5ce88]['type']||_0x5238c2&&_0x5238c2['userId']===_0x11f80f||_0x5c744c[_0x1ba05e]['unshift']({'userId':_0x11f80f,'object':_0x4be3d3[_0xb5ce88]['item'],'change':_0x96d7b4[_0x1ba05e]}),'elementEnd'===_0x4be3d3[_0xb5ce88]['type']&&_0x5238c2&&_0x5238c2['object']===_0x4be3d3[_0xb5ce88]['item']&&(_0x5c744c[_0x1ba05e]['shift'](),_0x96d7b4[_0x1ba05e]=_0x5238c2['change'])),_0x96d7b4[_0x1ba05e]&&_0x4d543d&&(_0x96d7b4[_0x1ba05e]['end']=_0x9e50cf,_0x2d3177(_0x96d7b4[_0x1ba05e]),_0x96d7b4[_0x1ba05e]=null);}function _0x2d3177({start:_0x272575,end:_0x3a4520,tapeItem:_0xe04d61,userId:_0x21ada4,type:_0x57332a}){const _0x3410f3=_0xe04d61['item'],_0x453f41=_0x164ca1['schema']['isBlock'](_0x3410f3)&&!_0x164ca1['schema']['isLimit'](_0x3410f3),_0x3b5e9c=_0x272575['nodeAfter']==_0x3a4520['parent']&&_0x3a4520['isAtStart'];if(_0x453f41&&_0x3b5e9c)return;const _0x3341f1=_0x164ca1['createRange'](_0x272575,_0x3a4520),_0x5debff=_0x579813['get'](_0x21ada4),_0x453076=new G({'author':_0x5debff,'type':'isAdded'==_0x57332a||'isAddSuggestion'==_0x57332a?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x57332a||'isRemoveSuggestion'==_0x57332a},'createdAt':new Date(),'rootName':_0x240cc1});_0x310129['push'](_0x453076),_0x316954['markers']['set']('revision:'+_0x453076['id'],_0x3341f1);}function _0x4f0c18(_0x3c061f,_0x23f483){const _0x3f13bb=_0x3c061f['getAttributes'](),_0xcd32b=_0x23f483['getAttributes']();for(const _0x4a9164 of _0x3f13bb){if(_0x4a9164[0x1]!==_0x23f483['getAttribute'](_0x4a9164[0x0]))return!0x1;_0xcd32b['next']();}return _0xcd32b['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x26eca3=>{const _0x59684b=_0x26eca3['markerName']['split'](':')[0x1],_0x343770=this['_getChangeFromId'](_0x59684b);if(!_0x343770)return null;const _0x350a5c='add'==_0x343770['type']?'insertion':'deletion',_0x40140b=['ck-suggestion-marker','ck-suggestion-marker-'+_0x350a5c];return _0x343770['data']['isSuggestion']&&_0x40140b['push']('ck-suggestion-marker-'+_0x350a5c+'-new'),this['activeChange']==_0x343770&&_0x40140b['push']('ck-suggestion-marker--active'),{'classes':_0x40140b,'attributes':{'data-change-id':_0x59684b}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x1d8a3e=>{_0x1d8a3e['on']('element:pre',(_0x11b769,_0x5ed34a,_0x306f29)=>{const _0x334322=_0x5ed34a['viewItem']['getChild'](0x0);if(!_0x334322||!_0x334322['is']('element','code'))return;if(!_0x306f29['consumable']['consume'](_0x334322,{'attributes':['vid_start','vid_end']}))return;const _0x1f3e49=_0x5ed34a['modelRange']['start']['nodeAfter'];_0x306f29['writer']['setAttribute']('vid_start',_0x334322['getAttribute']('vid_start'),_0x1f3e49),_0x306f29['writer']['setAttribute']('vid_end',_0x334322['getAttribute']('vid_end'),_0x1f3e49);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x276cc8=>{_0x276cc8['on']('element',(_0x4a81c7,_0x4a3bcf,_0x28ba7c)=>{if(!_0x28ba7c['consumable']['consume'](_0x4a3bcf['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x4a3bcf['modelRange']['isCollapsed'])return;const _0x13406f=_0x4a3bcf['modelRange']['start']['nodeAfter'];_0x13406f['hasAttribute']('vid_start')||_0x13406f['hasAttribute']('vid')||(_0x28ba7c['writer']['setAttribute']('vid_start',_0x4a3bcf['viewItem']['getAttribute']('vid_start'),_0x13406f),_0x28ba7c['writer']['setAttribute']('vid_end',_0x4a3bcf['viewItem']['getAttribute']('vid_end'),_0x13406f));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x3499ff=>_0x3499ff['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x47c338,[,_0x5dcfae])=>{['vid_start','vid_end','vid']['includes'](_0x5dcfae)&&(_0x47c338['return']=!0x0,_0x47c338['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x919355=>{_0x919355['on']('attribute:vid',(_0x5bc4b5,_0x51443a,_0x17682e)=>{if('\x20'!=_0x51443a['item']['data']||_0x51443a['item']['parent']['maxOffset']>0x1)return;if(!_0x17682e['consumable']['consume'](_0x51443a['item'],_0x5bc4b5['name']))return;const _0x3c9d29=_0x17682e['writer'],_0x59026d=_0x17682e['mapper']['toViewRange'](_0x51443a['range']);_0x3c9d29['wrap'](_0x59026d,_0x3c9d29['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x52e79c){const _0x412801=_0x52e79c['plugins']['get']('RevisionViewer');return(_0x2e64b4,_0x27ddc2,_0x3a5924)=>{const _0x430446=_0x27ddc2['markerName']['split'](':')[0x1],_0x3ac925=_0x412801['_getChangeFromId'](_0x430446);if(!_0x3ac925)return null;const _0x4bd026='add'==_0x3ac925['type']?'split':'merge';if(!_0x3a5924['consumable']['test'](_0x27ddc2['markerRange'],_0x2e64b4['name']))return;const _0x32929d=_0x27ddc2['markerRange']['getWalker'](),_0x54b46f=_0x27ddc2['markerRange']['start'],_0x4a4c7f=_0x52e79c['model']['schema'];let _0x3e31e2=null,_0x23f43b=null,_0x375548=!0x1,_0x2370ae=!0x1;for(const _0x510257 of _0x32929d){const _0x4a7c19=_0x510257['item'];_0x375548=_0x375548||_0x4a4c7f['isContent'](_0x4a7c19);const _0x138ded=_0x3a5924['mapper']['toViewElement'](_0x4a7c19);if(_0x138ded&&_0x138ded['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x510257['type']&&(_0x4a4c7f['isBlock'](_0x4a7c19)&&!_0x4a4c7f['isLimit'](_0x4a7c19)&&(_0x4a7c19['nextSibling']||_0x54b46f['isAtEnd']?_0x3e31e2&&_0x3e31e2['parent']==_0x4a7c19||(_0x3e31e2=_0x4a7c19,_0x17e527(_0x510257['previousPosition']),_0x2370ae=!0x0):_0x23f43b=_0x23f43b||_0x510257['previousPosition']));}function _0x17e527(_0x508de6){const _0x213b89=_0x3a5924['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x4bd026}),_0x510428=_0x3a5924['mapper']['toViewPosition'](_0x508de6);_0x3ac925['data']['isSuggestion']&&_0x3a5924['writer']['addClass']('ck-suggestion-marker-'+_0x4bd026+'-new',_0x213b89),_0x412801['activeChange']==_0x3ac925&&_0x3a5924['writer']['addClass']('ck-suggestion-marker--active',_0x213b89),_0x3a5924['writer']['insert'](_0x510428,_0x213b89),_0x3a5924['mapper']['bindElementToMarker'](_0x213b89,_0x27ddc2['markerName']);}_0x375548||_0x2370ae||!_0x23f43b||_0x17e527(_0x23f43b);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0xd88761,_0x3502ad,_0x5eda7c)=>{const _0x4ac11f=_0x5eda7c['mapper']['markerNameToElements'](_0x3502ad['markerName']);if(_0x4ac11f){for(const _0x3cabbb of _0x4ac11f)(_0x3cabbb['hasClass']('ck-suggestion-marker-split')||_0x3cabbb['hasClass']('ck-suggestion-marker-merge'))&&(_0x5eda7c['mapper']['unbindElementFromMarkerName'](_0x3cabbb,_0x3502ad['markerName']),_0x5eda7c['writer']['remove'](_0x3cabbb));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x503dbe,_0x33cf90,_0x2c795f)=>{const _0x4fd9fa=_0x33cf90['markerName']['split'](':')[0x1],_0x3328dc=this['_getChangeFromId'](_0x4fd9fa);if(!_0x3328dc)return null;const _0x499b6a='add'==_0x3328dc['type']?'split':'merge';if(_0x2c795f['consumable']['test'](_0x33cf90['markerRange'],_0x503dbe['name']))for(const _0x56a413 of _0x33cf90['markerRange']['getItems']()){if(!_0x56a413['is']('element','softBreak'))continue;const _0x53e0d1=_0x2c795f['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x499b6a}),_0x23dd86=_0x2c795f['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x56a413));_0x3328dc['data']['isSuggestion']&&_0x2c795f['writer']['addClass']('ck-suggestion-marker-'+_0x499b6a+'-new',_0x53e0d1),this['activeChange']==_0x3328dc&&_0x2c795f['writer']['addClass']('ck-suggestion-marker--active',_0x53e0d1),_0x2c795f['writer']['insert'](_0x23dd86,_0x53e0d1),_0x2c795f['mapper']['bindElementToMarker'](_0x53e0d1,_0x33cf90['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x301f89=>{for(const _0x479147 of this['editor']['model']['document']['getRootNames']()){const _0x8f7c66=this['editor']['model']['document']['getRoot'](_0x479147),_0x26e636=this['editor']['editing']['view']['document']['getRoot'](_0x479147);if(_0x26e636){const _0x6d5de=_0x8f7c66['getAttribute']('revisionHistoryAttachChange');if(_0x301f89['removeAttribute']('data-change-id',_0x26e636),_0x301f89['removeClass']('ck-revision-history-root-add',_0x26e636),_0x301f89['removeClass']('ck-revision-history-root-remove',_0x26e636),_0x301f89['removeClass']('ck-revision-history-root--active',_0x26e636),_0x6d5de){const _0x21b74c=this['_getChangeFromId'](_0x6d5de);if(!_0x21b74c)return null;_0x301f89['setAttribute']('data-change-id',_0x6d5de,_0x26e636),_0x301f89['addClass']('ck-revision-history-root-'+_0x21b74c['type'],_0x26e636),this['activeChange']==_0x21b74c&&_0x301f89['addClass']('ck-revision-history-root--active',_0x26e636);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0xa5a55a=>'revision-comment:'+_0xa5a55a,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x4573e6=>'revision-suggestion:'+_0x4573e6,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0xff03fc=>({'name':'suggestion:'+_0xff03fc,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x4ebdf4=>{const _0x1e5983=_0x4ebdf4['markerName']['split'](':')[0x1];return'insertion'!=_0x1e5983&&'deletion'!=_0x1e5983?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x1e5983]};}}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:deletion',Q(this['editor'],'merge'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:insertion',Q(this['editor'],'split'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision-suggestion',(_0x5709f1,_0x15ddb2,_0x35310a)=>{const _0x2e2f99=_0x35310a['mapper']['markerNameToElements'](_0x15ddb2['markerName']);if(_0x2e2f99){for(const _0x1ffbb3 of _0x2e2f99)_0x1ffbb3['is']('uiElement')&&(_0x35310a['mapper']['unbindElementFromMarkerName'](_0x1ffbb3,_0x15ddb2['markerName']),_0x35310a['writer']['remove'](_0x1ffbb3));}},{'priority':'high'});}['_getChangeFromId'](_0xdeef5){return this['_changeIdToChange']['get'](_0xdeef5);}['_getViewForChange'](_0xf68929){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new z(this['editor']['locale'],_0xf68929),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x5de827,_0x1da559,_0x52eb91,_0x3072c8)=>{_0x3072c8&&this['_balloon']['remove'](_0x3072c8),_0x52eb91&&(this['_balloon']['add']({'view':_0x52eb91,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x5ed05e=this['editor']['editing'],_0x21d330=this['_getChangeFromId'](_0x52eb91['changeId']);let _0x274d42;if(_0x21d330['data']['isOnRoot']){const _0x37bfd6=_0x5ed05e['view']['getDomRoot'](_0x21d330['rootName']);_0x274d42=Array['from'](_0x37bfd6['getClientRects']());}else{const _0x4d297f=this['editor']['model']['markers']['get']('revision:'+_0x52eb91['changeId']);_0x274d42=Array['from'](_0x5ed05e['mapper']['markerNameToElements'](_0x4d297f['name']))['map'](_0x2780bb=>_0x5ed05e['view']['domConverter']['mapViewToDom'](_0x2780bb))['map'](_0x57d968=>Array['from'](_0x57d968['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x274d42[0x0];return _0x274d42['find'](_0x58f00a=>_0x58f00a['top']-0x3<=this['_activeViewTarget']['y']&&_0x58f00a['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x58f00a['left']-0x3<=this['_activeViewTarget']['x']&&_0x58f00a['right']+0x3>=this['_activeViewTarget']['x'])||_0x274d42[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0xb49dec,_0x5d4f07,_0xbfa34d,_0x5da6f3)=>{this['activeView']=_0xbfa34d?this['_getViewForChange'](_0xbfa34d):null,this['editor']['model']['change'](()=>{const _0x4171e9=this['editor']['editing'];_0x5da6f3&&(_0x5da6f3['data']['isOnRoot']?_0x4171e9['view']['change'](_0x163223=>{_0x163223['removeClass']('ck-revision-history-root--active',_0x4171e9['view']['document']['getRoot'](_0x5da6f3['rootName']));}):_0x4171e9['reconvertMarker']('revision:'+_0x5da6f3['id'])),_0xbfa34d&&(_0xbfa34d['data']['isOnRoot']?_0x4171e9['view']['change'](_0x1df5de=>{_0x1df5de['addClass']('ck-revision-history-root--active',_0x4171e9['view']['document']['getRoot'](_0xbfa34d['rootName']));}):_0x4171e9['reconvertMarker']('revision:'+_0xbfa34d['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x1bf2f3,_0x2a1f30)=>{if(this['activeChange'])return;const _0x3cc363=this['_findChangeIdFromDomTarget'](_0x2a1f30['target']),_0x27b940=this['_changeIdToChange']['get'](_0x3cc363);_0x27b940?(this['_activeViewTarget']={'x':_0x2a1f30['domEvent']['x'],'y':_0x2a1f30['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x27b940)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x91ea9,_0x4cc18e)=>{const _0x11afb2=this['_findChangeIdFromDomTarget'](_0x4cc18e['target']),_0xb22845=this['_changeIdToChange']['get'](_0x11afb2);_0xb22845?(this['_activeViewTarget']={'x':_0x4cc18e['domEvent']['x'],'y':_0x4cc18e['domEvent']['y']},_0xb22845===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0xb22845):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x1d7ae6){do{const _0x1fd79d=_0x1d7ae6['getAttribute']('data-change-id');if(_0x1fd79d)return _0x1fd79d;_0x1d7ae6=_0x1d7ae6['parent'];}while(_0x1d7ae6);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x55fe28=>{for(const _0x1abfc0 of this['editor']['model']['markers'])_0x55fe28['removeMarker'](_0x1abfc0);});}}function Q(_0x4181d0,_0x1247dc){return(_0x19997b,_0x5c382f,_0x52fc1e)=>{if(!_0x52fc1e['consumable']['test'](_0x5c382f['markerRange'],_0x19997b['name']))return;const _0x10f2bb=_0x5c382f['markerRange']['getWalker'](),_0x1089dd=_0x5c382f['markerRange']['start'],_0x1d48dc=_0x4181d0['model']['schema'];let _0x370515=null,_0x412824=null,_0x4ba8e3=!0x1,_0x3d02af=!0x1;for(const _0x221a25 of _0x10f2bb){const _0x2903b2=_0x221a25['item'];_0x4ba8e3=_0x4ba8e3||_0x1d48dc['isContent'](_0x2903b2);const _0x2577da=_0x52fc1e['mapper']['toViewElement'](_0x2903b2);if(_0x2577da&&_0x2577da['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x221a25['type']&&(_0x1d48dc['isBlock'](_0x2903b2)&&!_0x1d48dc['isLimit'](_0x2903b2)&&(_0x2903b2['nextSibling']||_0x1089dd['isAtEnd']?_0x370515&&_0x370515['parent']==_0x2903b2||(_0x370515=_0x2903b2,_0x43a5c5(_0x221a25['previousPosition']),_0x3d02af=!0x0):_0x412824=_0x412824||_0x221a25['previousPosition']));}function _0x43a5c5(_0x2dc621){const _0x298827=_0x52fc1e['mapper']['toViewPosition'](_0x2dc621),_0x4633f8=_0x52fc1e['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x1247dc});_0x52fc1e['writer']['insert'](_0x298827,_0x4633f8),_0x52fc1e['mapper']['bindElementToMarker'](_0x4633f8,_0x5c382f['markerName']);}_0x4ba8e3||_0x3d02af||!_0x412824||_0x43a5c5(_0x412824);};}class nt extends _0x2a2d7a{constructor(_0x1f1665){super(_0x1f1665);const _0x18183e=_0x1f1665['plugins']['get'](l);this['affectsData']=!0x1,this['listenTo'](_0x18183e,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x18183e,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0xc0c317=this['editor'],_0x19af00=_0xc0c317['plugins']['get'](l),_0x412923=_0x19af00['isReady']?_0x19af00['diff']['newRevisionId']:null;_0xc0c317['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x412923);}['refresh'](){const {isReady:_0x5a01cb,isEnabled:_0x24e4c5,repository:_0x41f550,diff:_0x4bf6ba}=this['editor']['plugins']['get'](l),_0x2116e7=_0x4bf6ba&&_0x41f550['getLaterVisibleRevision'](_0x4bf6ba['newRevisionId']);this['isEnabled']=_0x5a01cb&&_0x24e4c5&&Boolean(_0x2116e7);}}class ot extends _0x2a2d7a{['_step'];constructor(_0x212806,{direction:_0x576425}){super(_0x212806);const _0x23735d=_0x212806['plugins']['get'](l);this['affectsData']=!0x1,this['_step']='forward'===_0x576425?0x1:-0x1,this['listenTo'](_0x23735d,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x23735d,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x23735d,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x42285d=this['editor'],_0x18d670=_0x42285d['plugins']['get'](l),{isNavigationMode:_0x13cec6,currentChangeNumber:_0x40a02b}=_0x18d670;let _0x109eef;if(_0x18d670['activeChange']=_0x13cec6?_0x18d670['diff']['changes']['get'](_0x40a02b+this['_step']):_0x18d670['diff']['changes']['first'],_0x18d670['activeChange']['data']['isOnRoot'])_0x109eef=_0x42285d['editing']['view']['getDomRoot'](_0x18d670['activeChange']['rootName']);else{const _0x4ed9a9=_0x42285d['model']['markers']['get']('revision:'+_0x18d670['activeChange']['id']);_0x109eef=_0x56f66f(_0x42285d['editing'],_0x4ed9a9);}_0x5c62f({'target':_0x109eef,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x2baafe,currentChangeNumber:_0xf30925,numberOfChanges:_0x2b233e,isReady:_0x2122b8,isEnabled:_0x1354f5}=this['editor']['plugins']['get'](l);this['isEnabled']=!!(_0x1354f5&&_0x2122b8&&_0x2b233e)&&(!_0x2baafe||(0x1===this['_step']?_0xf30925<_0x2b233e-0x1:_0xf30925>0x0));}}class Ri extends _0x49001e{constructor(_0x108a25){super(_0x108a25);const _0x14c3ae=this['bindTemplate'],_0x5da553=new _0x356661(_0x108a25),_0x37c049=new _0x356661(_0x108a25);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',(_0x409636,_0x5f83cb)=>_0x409636&&_0x5f83cb>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x2f0042,_0x28c561,_0x3bafd6,_0x46440c)=>{if(!_0x2f0042)return R(_0x108a25,'Loading...');if(!_0x3bafd6)return R(_0x108a25,'No\x20changes');const _0x1f6225=R(_0x108a25,'NUMBER_OF_CHANGES',_0x3bafd6);return _0x46440c?R(_0x108a25,'X_OF_Y_CHANGES',[_0x28c561+0x1,_0x3bafd6]):_0x1f6225;}),_0x5da553['set']({'label':R(_0x108a25,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x24bb4f}),_0x37c049['set']({'label':R(_0x108a25,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x3a97a7}),_0x5da553['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x37c049['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x5da553['on']('execute',()=>this['fire']('execute','backward')),_0x37c049['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',_0x14c3ae['if']('_isStatusLabelVisible','ck-hidden',_0x4cc972=>!_0x4cc972)]},'children':[{'text':_0x14c3ae['to']('isNavigationMode',_0x2031bb=>_0x2031bb?R(_0x108a25,'EDIT_X_OF_Y_REVISIONS')+':\x20':R(_0x108a25,'Total')+':\x20')}]},{'text':_0x14c3ae['to']('_statusText')}]},new _0x4da8fb(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x5da553,_0x37c049]}]});}}const ge='ck-editor__editable__loading-overlay';class ji extends _0x3a7117{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x3205fc=this['editor']['editing']['view'];_0x3205fc['change'](_0x3b7453=>{for(const _0x59747f of _0x3205fc['document']['roots'])_0x3b7453['addClass'](ge,_0x59747f);});}['hide'](){const _0x11d385=this['editor']['editing']['view'];_0x11d385['change'](_0x40f0d5=>{for(const _0x508cf1 of _0x11d385['document']['roots'])_0x40f0d5['removeClass'](ge,_0x508cf1);});}}class u extends _0x3a7117{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l,ji];}['init'](){const _0x564b4e=this['editor'],_0xe4ba47=_0x564b4e['plugins']['get'](l),_0x2dd81a=_0x564b4e['plugins']['get'](ji);_0x564b4e['ui']['componentFactory']['add']('exitToEditing',_0x22ee87=>{const _0x3e0d29=new _0x356661(_0x22ee87);return _0x3e0d29['set']({'label':R(_0x22ee87,'Back\x20to\x20editing'),'icon':_0x3772c5,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x3e0d29,'execute',()=>{_0x564b4e['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x3e0d29;}),_0x564b4e['ui']['componentFactory']['add']('restoreRevision',_0x15b847=>{const _0x280006=new _0x356661(_0x15b847);return _0x280006['set']({'label':R(_0x15b847,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x280006['bind']('isEnabled')['to'](_0x564b4e['commands']['get']('restoreRevision')),this['listenTo'](_0x280006,'execute',()=>_0x564b4e['execute']('restoreRevision')),_0x280006;}),_0x564b4e['ui']['componentFactory']['add']('changesNavigation',_0x1fe85b=>{const _0x558daa=new Ri(_0x1fe85b),_0x235f46=_0x564b4e['commands']['get']('showPreviousChange'),_0x24537c=_0x564b4e['commands']['get']('showNextChange');return _0x558daa['bind']('isBackwardNavigationEnabled')['to'](_0x235f46,'isEnabled'),_0x558daa['bind']('isForwardNavigationEnabled')['to'](_0x24537c,'isEnabled'),_0x558daa['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0xe4ba47),this['listenTo'](_0x558daa,'execute',(_0x3e9cce,_0x32288e)=>{_0x564b4e['execute']('forward'===_0x32288e?'showNextChange':'showPreviousChange');}),_0x558daa;}),_0x2dd81a['show'](),_0xe4ba47['on']('change:isReady',(_0x36d940,_0x3863cd,_0x1d8b11)=>{_0x1d8b11?_0x2dd81a['hide']():_0x2dd81a['show']();});}}class li extends ti{['_resizeObserver']=null;constructor(_0x33af1b,_0x156a80){super(_0x33af1b,_0x156a80);const _0x25bc6c=this['bindTemplate'];this['set']({'label':R(_0x33af1b,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=R(_0x33af1b,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x25bc6c['to']('_tooltipString'),'data-cke-tooltip-position':'s','data-cke-tooltip-class':'ck-tooltip_multi-line'}});}['render'](){super['render'](),this['_resizeObserver']=new et(this['fieldView']['element'],()=>this['_updateTooltipText']()),this['listenTo'](this['fieldView'],'input',()=>this['_updateTooltipText']());}['destroy'](){super['destroy'](),this['_resizeObserver']&&this['_resizeObserver']['destroy']();}['_updateTooltipText'](){const _0x4fa5b8=this['fieldView']['element'];this['_tooltipString']=_0x4fa5b8['scrollWidth']>_0x4fa5b8['clientWidth']&&_0x4fa5b8['value']||'';}}class vi extends _0x49001e{constructor(_0x3b4f42,_0x3ed192,_0x57a796){super(_0x3b4f42);const _0x18d9ab=new _0x3d47ac();_0x18d9ab['set']({'content':_0xb4cbd9,'viewBox':'0\x200\x2011\x2010'});const _0x5e7ed2=['ck','ck-revision-history-sidebar__revision-author'];_0x57a796&&_0x5e7ed2['push']('ck-revision-history-sidebar__revision-author_creator');const _0x4cf9b2=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':R(_0x3b4f42,_0x57a796?'Revision\x20creator':'Revision\x20author')},'children':[_0x18d9ab,_0x3ed192['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x5e7ed2},'children':_0x4cf9b2});}}function mi(_0x1bc0e3,_0x3628d2){const _0x1f3047=_0x1bc0e3['bindTemplate'],_0x1884f8=_0x1bc0e3['locale'],_0x32f8d6=_0x546af5(_0x1884f8);_0x32f8d6['panelPosition']='sw';const _0x479525=function(_0x5df991,_0x2e635a){const _0x16ec54=function(_0x20f376,_0x2c0421){const _0x46c716=_0x20f376['locale'],_0x49081d={'Compare\x20against\x20selected':R(_0x46c716,'Compare\x20against\x20selected'),'Name\x20this\x20revision':R(_0x46c716,'Name\x20this\x20revision'),'Restore\x20this\x20revision':R(_0x46c716,'Restore\x20this\x20revision')};return _0x2c0421['map'](_0x4423e2=>{const _0x4ac044=_0x49081d[_0x4423e2['name']];return _0x4ac044&&_0x4ac044!==_0x4423e2['name']&&(_0x4423e2['name']=_0x4ac044),_0x4423e2;});}(_0x5df991,_0x2e635a),_0x3c4433=new _0x2e7af1();for(const _0x5da960 of _0x16ec54){const _0x243db4={'type':'button','model':new to({'label':_0x5da960['name'],'class':_0x5da960['class'],'withText':!0x0,'role':'menuitem','_action':_0x5da960['action']})};_0x243db4['model']['bind']('isEnabled')['to'](_0x5df991,'isActionsDropdownOpen',_0x18b5be=>'function'!=typeof _0x5da960['isEnabled']||(!_0x18b5be||_0x5da960['isEnabled'](_0x5df991))),_0x3c4433['add'](_0x243db4);}return _0x3c4433;}(_0x1bc0e3,_0x3628d2);return _0x1bc0e3['bind']('isActionsDropdownOpen')['to'](_0x32f8d6,'isOpen'),_0x32f8d6['buttonView']['set']({'label':R(_0x1884f8,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x357701}),_0x32f8d6['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x1f3047['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x1f3047['to'](_0x281e8f=>_0x281e8f['stopPropagation']())}}),_0x32f8d6['on']('execute',_0x244138=>{_0x1bc0e3['isReady']&&'function'==typeof _0x244138['source']['_action']&&_0x244138['source']['_action'](_0x1bc0e3);}),_0x58c2ad(_0x32f8d6,_0x479525,{'role':'menu'}),_0x32f8d6['listenTo'](_0x1bc0e3,'change:isActionsDropdownOpen',(_0x3455fd,_0x284583,_0x190581)=>{if(_0x190581)for(const _0x15bd05 of _0x32f8d6['listView']['items']){const _0x38a82f=_0x15bd05['children']['first'],_0x5b051c=_0x3628d2['find'](_0x33536b=>_0x33536b['action']===_0x38a82f['_action'])['isVisible'];_0x15bd05['isVisible']=void 0x0===_0x5b051c||_0x5b051c(_0x1bc0e3);}}),_0x32f8d6;}class pi extends/* #__PURE__ -- @preserve */
27
+ _0xe95daa(_0x49001e){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x4fefe8,_0x397c9d,_0x5ea9f2,_0x4369da){super(_0x4fefe8);const _0x48ae73=this['bindTemplate'],_0x475bc2=function(_0x4e79a4,_0x159a50){const _0x15d68b=Array['from'](_0x159a50['authors'])['filter'](_0x25d726=>_0x25d726!=_0x159a50['creator']);return _0x159a50['creator']&&_0x15d68b['unshift'](_0x159a50['creator']),_0x15d68b['map'](_0x3fc8c2=>new vi(_0x4e79a4,_0x3fc8c2,_0x3fc8c2==_0x159a50['creator']));}(_0x4fefe8,_0x397c9d);this['id']=_0x397c9d['id'],this['_revision']=_0x397c9d,this['_requireRevisionName']=_0x4369da,this['bind']('name','createdAt')['to'](_0x397c9d),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x2fb6b4=>{return _0x1a73e8=_0x4fefe8['uiLanguage'],(_0x1c58ba=_0x2fb6b4)['toLocaleDateString'](_0x1a73e8,{'month':'long','day':'numeric'})+',\x20'+_0x1c58ba['toLocaleTimeString'](_0x1a73e8,{'hour':'numeric','minute':'numeric'});var _0x1a73e8,_0x1c58ba;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new li(_0x4fefe8,_0x1f20a),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x2133fa=>_0x2133fa||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x41e97f,_0x5af75d)=>_0x41e97f&&_0x5af75d),this['revisionActionsView']=_0x5ea9f2&&_0x5ea9f2['length']?mi(this,_0x5ea9f2):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x48ae73['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x48ae73['if']('isEnabled','ck-disabled',_0x26fcd8=>!_0x26fcd8),_0x48ae73['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x48ae73['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x48ae73['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':_0x48ae73['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':_0x475bc2}]},this['revisionActionsView']],'on':{'click':_0x48ae73['to'](_0x2a36e7=>{_0x2a36e7['srcElement']['closest']('.ck-thread__remove-confirm')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x30d5cd=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x30d5cd,'change',()=>{this['_requireRevisionName']&&!_0x30d5cd['value']||this['fire']('setName',{'id':this['id'],'name':_0x30d5cd['value']}),_0x30d5cd['value']||(_0x30d5cd['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(_0x14683c,_0x3ac396){const _0x2da286=_0x452b52['fromJSDate'](_0x14683c)['setLocale'](_0x3ac396),_0x3f3068=_0x452b52['local'](),_0x252920=_0x3f3068['minus']({'days':0x1})['startOf']('day');let _0x1adb4c,_0x440177;return _0x2da286['hasSame'](_0x3f3068,'day')?(_0x1adb4c=_0x2da286['startOf']('day')['toJSDate'](),_0x440177=_0x2da286['toRelativeCalendar']()):_0x2da286['hasSame'](_0x252920,'day')?(_0x1adb4c=_0x252920['toJSDate'](),_0x440177=_0x2da286['toRelativeCalendar']()):_0x2da286['hasSame'](_0x3f3068,'week')?(_0x1adb4c=_0x2da286['startOf']('week')['toJSDate'](),_0x440177=_0x2da286['weekdayLong']||''):_0x2da286['hasSame'](_0x3f3068,'year')?(_0x1adb4c=_0x2da286['startOf']('month')['toJSDate'](),_0x440177=_0x2da286['monthLong']||''):(_0x1adb4c=_0x2da286['startOf']('year')['toJSDate'](),_0x440177=String(_0x2da286['year'])),{'startDate':_0x1adb4c,'localizedPeriodName':_0x440177};}class fi extends _0x49001e{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x8f03fe,_0x5ad2b6,_0x55cfb5,_0x5665ff){super(_0x8f03fe);const _0x4eb762=bi(_0x5ad2b6,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x5ad2b6,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x55cfb5,this['_requireRevisionName']=_0x5665ff,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':_0x4eb762}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x4f5388){const _0x2875fb=new pi(this['locale'],_0x4f5388,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x2875fb);}['removeRevision'](_0x5dc129){const _0x46e383=this['revisionViews']['find'](_0x164a04=>_0x164a04['id']===_0x5dc129['id']);this['revisionViews']['remove'](_0x46e383);}}class ki extends _0x49001e{constructor(_0x1498f1){super(_0x1498f1);const _0x548fb8=new _0x3d47ac();_0x548fb8['content']=_0x80b955,this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x548fb8,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[R(_0x1498f1,'Revision\x20history')]}]});}}class ui extends _0x49001e{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x560e3a,_0x5226b9,_0x34d85d,_0x1875cc){super(_0x560e3a);const _0x53b89b=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x5226b9,this['_revisionActions']=_0x34d85d,this['_requireRevisionName']=_0x1875cc,this['on']('select',(_0x2ca6dd,_0x1e6336)=>{this['fire']('revisionSelected',_0x1e6336);}),this['on']('setName',(_0x25913b,_0x30ce3f)=>{this['fire']('revisionSetName',_0x30ce3f);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new ki(_0x560e3a),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x53b89b['if']('isEnabled','ck-disabled',_0xeea031=>!_0xeea031)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x43c66b of this['_revisions'])this['_addRevision'](_0x43c66b);this['_revisions']['on']('add',(_0x53b1d2,_0x52dd5e)=>{this['_addRevision'](_0x52dd5e);}),this['_revisions']['on']('remove',(_0x3321c3,_0x4b3d60)=>{this['_removeRevision'](_0x4b3d60);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x16806a=>_0x16806a['revisionViews']['map'](_0x21eac4=>_0x21eac4))['flat']();}['selectRevision'](_0x2d1add){for(const _0x5812c0 of this['revisionViews'])_0x2d1add&&_0x2d1add['id']===_0x5812c0['id']?_0x5812c0['select']():_0x5812c0['deselect']();}['highlightRevisions'](_0x4f87d6){for(const _0xdae37a of this['revisionViews'])_0x4f87d6['some'](({id:_0x3155ff})=>_0x3155ff===_0xdae37a['id'])?_0xdae37a['highlight']():_0xdae37a['unhighlight']();}['_addRevision'](_0x4d0af8){const _0x4cd1df=bi(_0x4d0af8['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x5cbc80=this['timePeriodViews']['get'](0x0);_0x5cbc80&&_0x5cbc80['startDate']['getTime']()===_0x4cd1df['getTime']()||(_0x5cbc80=new fi(this['locale'],_0x4cd1df,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x5cbc80)),_0x5cbc80['addRevision'](_0x4d0af8);}['_removeRevision'](_0x439d94){const _0x5ad3c4=bi(_0x439d94['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x5ad3c4)['removeRevision'](_0x439d94);}['_getTimePeriodViewByStartDate'](_0x3cd4c6){return this['timePeriodViews']['find'](_0x9017d7=>_0x9017d7['startDate']['getTime']()===_0x3cd4c6['getTime']());}}class f extends _0x3a7117{['_revisionViewer'];['_revisionsRepository'];['_sidebarView'];static ['defaultRevisionActions']=/* #__PURE__ -- @preserve */
28
28
  ((()=>['compareAgainstSelected','restoreRevision','nameRevision'])());static ['availableRevisionActions']=/* #__PURE__ -- @preserve */
29
- dt();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l];}constructor(_0x2135f1){super(_0x2135f1),this['_revisionViewer']=_0x2135f1['plugins']['get'](l),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x2be50c=this['_revisionsRepository']['_revisions'],_0x304965=this['_createRevisionActions'](),_0x1cd9d2=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new di(this['editor']['locale'],_0x2be50c,_0x304965,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',(_0x556c63,_0x16fffa)=>{_0x16fffa['revisionViews']['on']('add',(_0x131d5e,_0x2b5d4e)=>{_0x2b5d4e['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)),_0x1cd9d2['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0xd008cb=this['_revisionsRepository']['getRevision'](0x0);if(_0xd008cb){const _0x1a1a09=this['_revisionsRepository']['getEarlierVisibleRevision'](_0xd008cb['id']);this['_revisionViewer']['compare'](_0xd008cb,_0x1a1a09);}}['_handleRevisionSelected'](_0x3ba028,_0x2f7d18){const _0x521182=this['_revisionsRepository']['getRevision'](_0x2f7d18['id']),_0x3aa2ca=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x521182['id']);this['_revisionViewer']['compare'](_0x521182,_0x3aa2ca);}['_handleRevisionSetName'](_0x26da33,_0x584bba){this['_revisionsRepository']['getRevision'](_0x584bba['id'])['setName'](_0x584bba['name']);}['_handleDiffChange'](_0x4be192,_0x46f5d4,_0x5126fc){const _0x5b5aa0=this['_revisionsRepository']['getRevisionsInDiff'](_0x5126fc);_0x5b5aa0['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x5b5aa0),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x5b5aa0[0x0]));}['_createRevisionActions'](){const _0x3d12b8=this['editor'],_0x4dfb0a=f['availableRevisionActions'],_0x13b56a=_0x3d12b8['config']['get']('revisionHistory.revisionActions')||f['defaultRevisionActions'];if(_0x13b56a['length'])return _0x13b56a['map'](_0xcfb761=>{const _0x41ccef='string'==typeof _0xcfb761?Object['assign']({},_0x4dfb0a[_0xcfb761]):_0xcfb761;return _0x41ccef['action']=_0x41ccef['action']['bind'](this,_0x3d12b8),_0x41ccef['isVisible']&&(_0x41ccef['isVisible']=_0x41ccef['isVisible']['bind'](this,_0x3d12b8)),_0x41ccef;});}}function dt(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x3725fe},_0x5c61bc)=>{const _0x34f621=_0x3725fe['get'](l),_0x4bc29f=_0x34f621['repository'];let _0x43f293=_0x34f621['diff']['newRevisionId'],_0x29f52a=_0x5c61bc['id'];_0x4bc29f['getIndex'](_0x43f293)>_0x4bc29f['getIndex'](_0x29f52a)&&([_0x43f293,_0x29f52a]=[_0x29f52a,_0x43f293]),_0x34f621['compare'](_0x43f293,_0x29f52a);},'isVisible':({plugins:_0x189d3b},_0x22eb8b)=>{const _0x521ae6=_0x189d3b['get'](l);return!(_0x521ae6['repository']['getRevisionsInDiff'](_0x521ae6['diff'])['length']>0x2)&&!_0x22eb8b['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x57080b,{id:_0x5dc67c})=>{_0x57080b['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x5dc67c);},'isVisible':({plugins:_0x597af5},_0x42d083)=>!!_0x597af5['get'](l)['repository']['getLaterVisibleRevision'](_0x42d083['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x1db458},{id:_0x1da78b,revisionNameView:_0x2e24e0})=>{const _0x340088=_0x1db458['get'](l),_0x57a585=_0x340088['repository']['getEarlierVisibleRevision'](_0x1da78b);_0x340088['compare'](_0x1da78b,_0x57a585),_0x2e24e0['focus'](),_0x2e24e0['fieldView']['select']();}}};}class Z extends tt{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x14818a,_0x247521){super(_0x14818a),this['_view']=_0x247521,this['_toolbarConfig']=st(_0x14818a['config']['get']('toolbar')),this['_elementReplacer']=new it();}get['element'](){return this['view']['element'];}['init'](_0x16197f){const _0x430208=this['editor'],_0x2d835c=this['view'],_0x1c84e4=_0x430208['editing']['view'],_0x9d6cfd=_0x2d835c['editable'],_0x2e8fe5=_0x1c84e4['document']['getRoot']();_0x9d6cfd['name']=_0x2e8fe5['rootName'],_0x2d835c['render']();const _0x939d39=_0x9d6cfd['element'];this['setEditableElement'](_0x9d6cfd['name'],_0x939d39),_0x2d835c['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x1c84e4['attachDomRoot'](_0x939d39),this['_elementReplacer']['replace'](_0x16197f,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x42356f=this['view'],_0x53fa53=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x53fa53['detachDomRoot'](_0x42356f['editable']['name']),_0x42356f['destroy']();}['_initToolbar'](){const _0x501f18=this['view'];_0x501f18['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x501f18['stickyPanel']['limiterElement']=_0x501f18['element'],_0x501f18['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x397c2f})=>_0x397c2f),_0x501f18['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x501f18['toolbar']);}}class ii extends _0x1f2958{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x279976,_0x51340c,_0xfe0b0f={}){super(_0x279976),this['stickyPanel']=new _0x2ec8f1(_0x279976),this['toolbar']=new _0x42bc33(_0x279976,{'shouldGroupWhenFull':_0xfe0b0f['shouldToolbarGroupWhenFull']}),this['_editable']=new te(_0x279976,_0x51340c);}['render'](){super['render'](),this['stickyPanel']['content']['add'](this['toolbar']),this['top']['add'](this['stickyPanel']),this['main']['add'](this['editable']);}}class m extends/* #__PURE__ -- @preserve */
30
- _0x12e486(_0x4072d7){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x1fc164,_0xba5f4c){super(_0xba5f4c),this['sourceElement']=_0x1fc164,this['model']['document']['createRoot']();const _0x4918c0=new ii(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new Z(this,_0x4918c0);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x4097ee,_0x484b66){const _0x2e3c71=new this(_0x4097ee,_0x484b66);return await _0x2e3c71['initPlugins'](),await _0x2e3c71['ui']['init'](_0x4097ee),await _0x2e3c71['data']['init'](_0x2e3c71['config']['get']('initialData')||''),_0x2e3c71['fire']('ready'),_0x2e3c71;}}const d=['RevisionHistoryUI','RestrictedEditingMode'];class ft extends _0x49c0fc{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x525b9d){function _0x2932d3(_0xc45707){return _0xc45707['map'](_0x292c1f=>String['fromCharCode'](_0x292c1f))['join']('');}super(_0x525b9d),this['result']='end',_0x525b9d[_0x2932d3([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x2932d3([0x76,0x69,0x65,0x77])][_0x2932d3([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x2932d3([0x61,0x75,0x74,0x6f]),_0x525b9d[_0x2932d3([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x2932d3([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x2932d3([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x2932d3([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x2932d3([0x6f,0x6b])});}}class vt extends _0x49c0fc{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h,v];}constructor(_0x346ee4){if(super(_0x346ee4),!this['editor']['config']['get']('revisionHistory'))throw new _0x10ec0c('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x431bd4=>this['_showRevisionViewer']({..._0x431bd4,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x56a35c=>this['_closeRevisionViewer'](_0x56a35c)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0xa4c71b=>this['_restoreRevision'](_0xa4c71b)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x36e3b6){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x36e3b6;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x5eb50f){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x5eb50f);}['getRevision'](_0x23d8ce){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x23d8ce);}['getRevisions'](_0x38571f){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x38571f||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x5da811=this['editor'],_0x1930b8=_0x100442(_0x5da811,d),_0x54d113=_0x5da811['plugins']['get']('RevisionTracker'),_0x1bff7b=_0x5da811['plugins']['get']('Users')['users'];return _0x1930b8['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x1930b8['lazyRoots'],(_0x1930b8['plugins']['push'](ft,l,u,class extends _0x49c0fc{static get['requires'](){return[l,'Users'];}['init'](){const _0x39d7b7=this['editor']['plugins']['get']('Users');for(const _0x1ab2e4 of _0x1bff7b)_0x1ab2e4['isAnonymous']||_0x39d7b7['getUser'](_0x1ab2e4['id'])||_0x39d7b7['addUser'](_0x1ab2e4);const _0x275f33=_0x54d113['repository']['getRevisions']();let _0x271f85=null;const _0x16e048=this['editor']['plugins']['get']('RevisionViewer');_0x16e048['adapter']=_0x54d113['adapter'],_0x16e048['bind']('isEnabled')['to'](_0x54d113),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x5da811,'isReadOnly',_0x5ab781=>!_0x5ab781);for(const _0x417007 of _0x275f33){const _0x4006ab=null===_0x417007['creator'];if(_0x4006ab&&_0x417007['toVersion']===_0x417007['fromVersion'])continue;const _0x58990b=_0x417007['toJSON']();_0x16e048['addRevisionData'](_0x58990b,(_0x2ce5da,_0x10175b,_0x2b4508)=>{if(_0x4006ab){if(_0x271f85)_0x271f85['_update'](_0x2ce5da,_0x10175b);else{if(!_0x10175b){const _0x5db2a9=_0x2b4508['toJSON']();_0x5db2a9['id']=_0x582bfa(),_0x54d113['saveRevision'](_0x5db2a9,_0x2b4508['toVersion'])['then'](_0x53fba3=>{_0x271f85=_0x53fba3;});}}}else _0x417007['_update'](_0x2ce5da,_0x10175b);});}}},f),_0x1930b8);}['_enhanceShowRevisionViewerCallback'](){const _0x1ff613=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x5eba94=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x15337c=this['editor']['plugins']['get']('Autosave');await _0x15337c['save']();}else await _0x5eba94['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x39bce3=this['editor']['plugins']['get']('Dialog');_0x39bce3['isOpen']&&_0x39bce3['hide']();}const _0x41dc80=this['_getRevisionViewerEditorConfig']();return _0x1ff613(_0x41dc80)['then'](_0x1cd1ab=>{return(this['_viewerEditor']=_0x1cd1ab,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'),_0x1cd1ab);})['catch'](_0x2add57=>(console['error'](_0x2add57),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x2f095a=this['editor']['config']['get']('revisionHistory')['closeRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.closeRevisionViewerCallback',()=>(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('DocumentOutline')&&(this['editor']['plugins']['get']('DocumentOutlineUI')['view']['element']['style']['display']=''),this['_viewerEditor']['plugins']['get']('RevisionViewer')['_cleanUp'](),_0x2f095a(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x4498bf=this['editor']['plugins']['get']('Annotations');_0x4498bf['refreshVisibility'](),_0x4498bf['refreshPositioning']();}})));}['_showRevisionViewer'](_0x2809dd){const _0x394e96=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x4e66da=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x18af3b=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return m['create'](_0x18af3b,_0x2809dd)['then'](_0x154cc7=>(_0x4e66da['style']['display']='block',_0x394e96['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x154cc7));}['_closeRevisionViewer'](_0x333408){const _0x38411d=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x38411d['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x333408['destroy']();}async['_restoreRevision'](_0x203228){const _0xb5aa62=this['editor'],_0x27903c=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x128de5=_0xb5aa62['plugins']['get']('RevisionTracker'),_0x514dcd=_0xb5aa62['plugins']['get']('RevisionHistoryUtils'),_0x5173cc=_0x27903c['repository']['getRevision'](_0x203228);let _0x5c4d1e,_0x3bddf1,_0x338390;try{await _0x514dcd['loadRevisionData'](_0x5173cc,this['adapter']),_0x5c4d1e=_0x514dcd['getRevisionDocumentData'](_0x5173cc),_0x3bddf1=_0x514dcd['getRevisionRootsAttributes'](_0x5173cc);}catch(_0x117df0){return void console['error'](_0x117df0);}_0xb5aa62['model']['change'](_0x46a693=>{for(const _0x3d2254 of Array['from'](_0xb5aa62['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x46a693['removeMarker'](_0x3d2254);}),_0x27903c['isReady']=!0x1,_0xb5aa62['model']['enqueueChange'](_0x12aeda=>{_0x12aeda['setSelection'](null),_0x12aeda['removeSelectionAttribute'](_0xb5aa62['model']['document']['selection']['getAttributeKeys']());const _0x48341f=Object['keys'](_0x5c4d1e);for(const _0x546793 of _0xb5aa62['model']['document']['roots'])'$graveyard'!=_0x546793['rootName']&&_0x546793['isAttached']()&&!_0x48341f['includes'](_0x546793['rootName'])&&_0x12aeda['detachRoot'](_0x546793);for(const _0x2fba9f of _0x48341f){let _0x5e24f2=_0xb5aa62['model']['document']['getRoot'](_0x2fba9f);_0x5e24f2&&_0x5e24f2['isAttached']()||(_0x5e24f2=_0x12aeda['addRoot'](_0x2fba9f));const _0x55c5a1=_0x3bddf1[_0x2fba9f],_0x220da2=Object['keys'](_0x55c5a1),_0x43eca7=_0x5c4d1e[_0x2fba9f];for(const _0x163c95 of _0x5e24f2['getAttributeKeys']())_0x220da2['includes'](_0x163c95)||_0x12aeda['removeAttribute'](_0x163c95,_0x5e24f2);for(const _0xa9846 of _0x220da2)_0x12aeda['setAttribute'](_0xa9846,_0x3bddf1[_0x2fba9f][_0xa9846],_0x5e24f2);_0x12aeda['remove'](_0x12aeda['createRangeIn'](_0x5e24f2)),_0x12aeda['insert'](_0xb5aa62['data']['parse'](_0x43eca7,_0x5e24f2),_0x5e24f2,0x0);}});const _0x396d09=R(_0xb5aa62['locale'],'Restored');if(_0x5173cc['name'])_0x338390=-0x1==_0x5173cc['name']['indexOf'](_0x396d09)?_0x396d09+':\x20'+_0x5173cc['name']:_0x5173cc['name'];else _0x338390=_0x396d09+':\x20'+(_0x5173cc['createdAt']['toLocaleDateString'](_0xb5aa62['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x5173cc['createdAt']['toLocaleTimeString'](_0xb5aa62['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x128de5['saveRevision']({'name':_0x338390}),_0x27903c['isReady']=!0x0,_0xb5aa62['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{ut as RestoreRevisionCommand,I as Revision,vt as RevisionHistory,v as RevisionHistoryUI,$ as RevisionHistoryUtils,h as RevisionTracker,l as RevisionViewer,m as RevisionViewerEditor,ji as RevisionViewerLoadingOverlay,u as RevisionViewerUI,S as RevisionsRepository,f as RevisionsSidebar,lt as ShowChangeCommand};
29
+ rt();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l];}constructor(_0x57090f){super(_0x57090f),this['_revisionViewer']=_0x57090f['plugins']['get'](l),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x1007c8=this['_revisionsRepository']['_revisions'],_0x30261d=this['_createRevisionActions'](),_0xc6170f=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new ui(this['editor']['locale'],_0x1007c8,_0x30261d,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',(_0x167d1d,_0x5f20fc)=>{_0x5f20fc['revisionViews']['on']('add',(_0x3e9129,_0x310ccf)=>{_0x310ccf['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)),_0xc6170f['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x3ddec1=this['_revisionsRepository']['getRevision'](0x0);if(_0x3ddec1){const _0x4d85c6=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x3ddec1['id']);this['_revisionViewer']['compare'](_0x3ddec1,_0x4d85c6);}}['_handleRevisionSelected'](_0x1b8194,_0x158276){const _0x5cd750=this['_revisionsRepository']['getRevision'](_0x158276['id']),_0x2b9c97=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x5cd750['id']);this['_revisionViewer']['compare'](_0x5cd750,_0x2b9c97);}['_handleRevisionSetName'](_0x15ff66,_0x1b75bf){this['_revisionsRepository']['getRevision'](_0x1b75bf['id'])['setName'](_0x1b75bf['name']);}['_handleDiffChange'](_0x427ee1,_0x32c6cd,_0x25de01){const _0xed9a32=this['_revisionsRepository']['getRevisionsInDiff'](_0x25de01);_0xed9a32['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0xed9a32),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0xed9a32[0x0]));}['_createRevisionActions'](){const _0x461dad=this['editor'],_0x4283ee=f['availableRevisionActions'],_0x301c4e=_0x461dad['config']['get']('revisionHistory.revisionActions')||f['defaultRevisionActions'];if(_0x301c4e['length'])return _0x301c4e['map'](_0x2eb647=>{const _0x596884='string'==typeof _0x2eb647?Object['assign']({},_0x4283ee[_0x2eb647]):_0x2eb647;return _0x596884['action']=_0x596884['action']['bind'](this,_0x461dad),_0x596884['isVisible']&&(_0x596884['isVisible']=_0x596884['isVisible']['bind'](this,_0x461dad)),_0x596884;});}}function rt(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x582b50},_0x386263)=>{const _0x3d9b00=_0x582b50['get'](l),_0x5de1cb=_0x3d9b00['repository'];let _0x42582b=_0x3d9b00['diff']['newRevisionId'],_0x55c5ad=_0x386263['id'];_0x5de1cb['getIndex'](_0x42582b)>_0x5de1cb['getIndex'](_0x55c5ad)&&([_0x42582b,_0x55c5ad]=[_0x55c5ad,_0x42582b]),_0x3d9b00['compare'](_0x42582b,_0x55c5ad);},'isVisible':({plugins:_0x3f92cf},_0x24c123)=>{const _0x17343e=_0x3f92cf['get'](l);return!(_0x17343e['repository']['getRevisionsInDiff'](_0x17343e['diff'])['length']>0x2)&&!_0x24c123['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0xf8f6c6,{id:_0x5a7a3b})=>{_0xf8f6c6['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x5a7a3b);},'isVisible':({plugins:_0x3e3a35},_0x2d06a3)=>!!_0x3e3a35['get'](l)['repository']['getLaterVisibleRevision'](_0x2d06a3['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x22ef25},{id:_0x2e6c3d,revisionNameView:_0x3b0c3e})=>{const _0xafeb5=_0x22ef25['get'](l),_0x614b16=_0xafeb5['repository']['getEarlierVisibleRevision'](_0x2e6c3d);_0xafeb5['compare'](_0x2e6c3d,_0x614b16),_0x3b0c3e['focus'](),_0x3b0c3e['fieldView']['select']();}}};}class Z extends tt{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x45a63d,_0x512014){super(_0x45a63d),this['_view']=_0x512014,this['_toolbarConfig']=st(_0x45a63d['config']['get']('toolbar')),this['_elementReplacer']=new it();}get['element'](){return this['view']['element'];}['init'](_0x4c1ee0){const _0xdd9973=this['editor'],_0x1d22a7=this['view'],_0x286482=_0xdd9973['editing']['view'],_0x3bcbaf=_0x1d22a7['editable'],_0x2d4ae0=_0x286482['document']['getRoot']();_0x3bcbaf['name']=_0x2d4ae0['rootName'],_0x1d22a7['render']();const _0x8bcd21=_0x3bcbaf['element'];this['setEditableElement'](_0x3bcbaf['name'],_0x8bcd21),_0x1d22a7['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x286482['attachDomRoot'](_0x8bcd21),this['_elementReplacer']['replace'](_0x4c1ee0,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x1cc47d=this['view'],_0xc84654=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0xc84654['detachDomRoot'](_0x1cc47d['editable']['name']),_0x1cc47d['destroy']();}['_initToolbar'](){const _0x481506=this['view'];_0x481506['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x481506['stickyPanel']['limiterElement']=_0x481506['element'],_0x481506['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x5f1c6d})=>_0x5f1c6d),_0x481506['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x481506['toolbar']);}}class ii extends _0x4c6a60{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x77353d,_0x23cce9,_0x4c0933={}){super(_0x77353d),this['stickyPanel']=new _0x32d525(_0x77353d),this['toolbar']=new _0x3da8a5(_0x77353d,{'shouldGroupWhenFull':_0x4c0933['shouldToolbarGroupWhenFull']}),this['_editable']=new te(_0x77353d,_0x23cce9);}['render'](){super['render'](),this['stickyPanel']['content']['add'](this['toolbar']),this['top']['add'](this['stickyPanel']),this['main']['add'](this['editable']);}}class m extends/* #__PURE__ -- @preserve */
30
+ _0x28a0f5(_0x5c66f2){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x587e18,_0x16a77a){super(_0x16a77a),this['sourceElement']=_0x587e18,this['model']['document']['createRoot']();const _0x4d2b1a=new ii(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new Z(this,_0x4d2b1a);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x472bee,_0x10e0e2){const _0x39d28a=new this(_0x472bee,_0x10e0e2);return await _0x39d28a['initPlugins'](),await _0x39d28a['ui']['init'](_0x472bee),await _0x39d28a['data']['init'](_0x39d28a['config']['get']('initialData')||''),_0x39d28a['fire']('ready'),_0x39d28a;}}const d=['RevisionHistoryUI','RestrictedEditingMode'];class at extends _0x3a7117{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x5dcd3f){function _0x137ab5(_0x3f0ccb){return _0x3f0ccb['map'](_0x267e97=>String['fromCharCode'](_0x267e97))['join']('');}super(_0x5dcd3f),this['result']='end',_0x5dcd3f[_0x137ab5([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x137ab5([0x76,0x69,0x65,0x77])][_0x137ab5([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x137ab5([0x61,0x75,0x74,0x6f]),_0x5dcd3f[_0x137ab5([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x137ab5([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x137ab5([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x137ab5([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x137ab5([0x6f,0x6b])});}}class ht extends _0x3a7117{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h,v];}constructor(_0x2a32e4){if(super(_0x2a32e4),!this['editor']['config']['get']('revisionHistory'))throw new _0x3a46b6('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x104802=>this['_showRevisionViewer']({..._0x104802,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x38b652=>this['_closeRevisionViewer'](_0x38b652)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x245fec=>this['_restoreRevision'](_0x245fec)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x15fd87){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x15fd87;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x18737a){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x18737a);}['getRevision'](_0x19a433){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x19a433);}['getRevisions'](_0x4f7994){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x4f7994||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x303d7c=this['editor'],_0x39ffc7=_0x4cde83(_0x303d7c,d),_0x28b80f=_0x303d7c['plugins']['get']('RevisionTracker'),_0x3b8004=_0x303d7c['plugins']['get']('Users')['users'];return _0x39ffc7['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x39ffc7['lazyRoots'],(_0x39ffc7['plugins']['push'](at,l,u,class extends _0x3a7117{static get['requires'](){return[l,'Users'];}['init'](){const _0x138748=this['editor']['plugins']['get']('Users');for(const _0x2b972f of _0x3b8004)_0x2b972f['isAnonymous']||_0x138748['getUser'](_0x2b972f['id'])||_0x138748['addUser'](_0x2b972f);const _0x24413d=_0x28b80f['repository']['getRevisions']();let _0xa7c4f4=null;const _0x3cbb0d=this['editor']['plugins']['get']('RevisionViewer');_0x3cbb0d['adapter']=_0x28b80f['adapter'],_0x3cbb0d['bind']('isEnabled')['to'](_0x28b80f),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x303d7c,'isReadOnly',_0x2d1da4=>!_0x2d1da4);for(const _0x2f080f of _0x24413d){const _0x46ac98=null===_0x2f080f['creator'];if(_0x46ac98&&_0x2f080f['toVersion']===_0x2f080f['fromVersion'])continue;const _0x35fa19=_0x2f080f['toJSON']();_0x3cbb0d['addRevisionData'](_0x35fa19,(_0x2c82dc,_0x18b1bd,_0x450bf3)=>{if(_0x46ac98){if(_0xa7c4f4)_0xa7c4f4['_update'](_0x2c82dc,_0x18b1bd);else{if(!_0x18b1bd){const _0xe0dd17=_0x450bf3['toJSON']();_0xe0dd17['id']=_0x17ccda(),_0x28b80f['saveRevision'](_0xe0dd17,_0x450bf3['toVersion'])['then'](_0x3863fa=>{_0xa7c4f4=_0x3863fa;});}}}else _0x2f080f['_update'](_0x2c82dc,_0x18b1bd);});}}},f),_0x39ffc7);}['_enhanceShowRevisionViewerCallback'](){const _0x45ee20=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x4491ff=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x4f1ba4=this['editor']['plugins']['get']('Autosave');await _0x4f1ba4['save']();}else await _0x4491ff['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x493cc9=this['editor']['plugins']['get']('Dialog');_0x493cc9['isOpen']&&_0x493cc9['hide']();}const _0x396494=this['_getRevisionViewerEditorConfig']();return _0x45ee20(_0x396494)['then'](_0x55d139=>{return(this['_viewerEditor']=_0x55d139,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'),_0x55d139);})['catch'](_0x334c92=>(console['error'](_0x334c92),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x25211f=this['editor']['config']['get']('revisionHistory')['closeRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.closeRevisionViewerCallback',()=>(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('DocumentOutline')&&(this['editor']['plugins']['get']('DocumentOutlineUI')['view']['element']['style']['display']=''),this['_viewerEditor']['plugins']['get']('RevisionViewer')['_cleanUp'](),_0x25211f(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x413b4b=this['editor']['plugins']['get']('Annotations');_0x413b4b['refreshVisibility'](),_0x413b4b['refreshPositioning']();}})));}['_showRevisionViewer'](_0x369af9){const _0x475deb=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x2399de=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x127515=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return m['create'](_0x127515,_0x369af9)['then'](_0x299d01=>(_0x2399de['style']['display']='block',_0x475deb['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x299d01));}['_closeRevisionViewer'](_0xd88538){const _0x234e3b=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x234e3b['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0xd88538['destroy']();}async['_restoreRevision'](_0x2fdfb8){const _0x3d8c0a=this['editor'],_0x2043ca=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x2fd70c=_0x3d8c0a['plugins']['get']('RevisionTracker'),_0x3116d4=_0x3d8c0a['plugins']['get']('RevisionHistoryUtils'),_0x4e9f16=_0x2043ca['repository']['getRevision'](_0x2fdfb8);let _0xbdceec,_0x353971,_0xa2f989;try{await _0x3116d4['loadRevisionData'](_0x4e9f16,this['adapter']),_0xbdceec=_0x3116d4['getRevisionDocumentData'](_0x4e9f16),_0x353971=_0x3116d4['getRevisionRootsAttributes'](_0x4e9f16);}catch(_0x27949d){return void console['error'](_0x27949d);}_0x3d8c0a['model']['change'](_0x2c45db=>{for(const _0x3c55a2 of Array['from'](_0x3d8c0a['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x2c45db['removeMarker'](_0x3c55a2);}),_0x2043ca['isReady']=!0x1,_0x3d8c0a['model']['enqueueChange'](_0x5df158=>{_0x5df158['setSelection'](null),_0x5df158['removeSelectionAttribute'](_0x3d8c0a['model']['document']['selection']['getAttributeKeys']());const _0x5e8885=Object['keys'](_0xbdceec);for(const _0x18a040 of _0x3d8c0a['model']['document']['roots'])'$graveyard'!=_0x18a040['rootName']&&_0x18a040['isAttached']()&&!_0x5e8885['includes'](_0x18a040['rootName'])&&_0x5df158['detachRoot'](_0x18a040);for(const _0x1b16e6 of _0x5e8885){let _0x3485cb=_0x3d8c0a['model']['document']['getRoot'](_0x1b16e6);_0x3485cb&&_0x3485cb['isAttached']()||(_0x3485cb=_0x5df158['addRoot'](_0x1b16e6));const _0x4db3f2=_0x353971[_0x1b16e6],_0x1838d0=Object['keys'](_0x4db3f2),_0x5a25f6=_0xbdceec[_0x1b16e6];for(const _0x391eed of _0x3485cb['getAttributeKeys']())_0x1838d0['includes'](_0x391eed)||_0x5df158['removeAttribute'](_0x391eed,_0x3485cb);for(const _0x405a0d of _0x1838d0)_0x5df158['setAttribute'](_0x405a0d,_0x353971[_0x1b16e6][_0x405a0d],_0x3485cb);_0x5df158['remove'](_0x5df158['createRangeIn'](_0x3485cb)),_0x5df158['insert'](_0x3d8c0a['data']['parse'](_0x5a25f6,_0x3485cb),_0x3485cb,0x0);}});const _0x1b2ba1=R(_0x3d8c0a['locale'],'Restored');if(_0x4e9f16['name'])_0xa2f989=-0x1==_0x4e9f16['name']['indexOf'](_0x1b2ba1)?_0x1b2ba1+':\x20'+_0x4e9f16['name']:_0x4e9f16['name'];else _0xa2f989=_0x1b2ba1+':\x20'+(_0x4e9f16['createdAt']['toLocaleDateString'](_0x3d8c0a['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x4e9f16['createdAt']['toLocaleTimeString'](_0x3d8c0a['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x2fd70c['saveRevision']({'name':_0xa2f989}),_0x2043ca['isReady']=!0x0,_0x3d8c0a['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{nt as RestoreRevisionCommand,I as Revision,ht as RevisionHistory,v as RevisionHistoryUI,$ as RevisionHistoryUtils,h as RevisionTracker,l as RevisionViewer,m as RevisionViewerEditor,ji as RevisionViewerLoadingOverlay,u as RevisionViewerUI,S as RevisionsRepository,f as RevisionsSidebar,ot as ShowChangeCommand};