@ckeditor/ckeditor5-revision-history 0.0.0-nightly-20250428.0 → 0.0.0-nightly-20250429.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 (180) hide show
  1. package/build/revision-history.js +1 -1
  2. package/dist/index.js +6 -6
  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.js +1 -1
  157. package/src/revisionhistory.js +1 -1
  158. package/src/revisionhistoryutils.js +1 -1
  159. package/src/revisionsrepository.js +1 -1
  160. package/src/revisiontracker.js +1 -1
  161. package/src/revisionviewer.js +1 -1
  162. package/src/ui/revision/createrevisionactionsdropdown.js +1 -1
  163. package/src/ui/revision/revisionauthorview.js +1 -1
  164. package/src/ui/revision/revisionnameview.js +1 -1
  165. package/src/ui/revision/revisionview.js +2 -2
  166. package/src/ui/revision/subrevisioncollapserview.js +1 -1
  167. package/src/ui/revision/subrevisionview.js +1 -1
  168. package/src/ui/revision/utils.js +1 -1
  169. package/src/ui/revisionhistory/revisionhistorysaverevisionformview.js +1 -1
  170. package/src/ui/revisionhistory/revisionhistoryui.js +1 -1
  171. package/src/ui/revisionssidebar/revisionssidebar.js +1 -1
  172. package/src/ui/revisionssidebar/revisionssidebarheaderview.js +1 -1
  173. package/src/ui/revisionssidebar/revisionssidebartimeperiodview.js +1 -1
  174. package/src/ui/revisionssidebar/revisionssidebarview.js +1 -1
  175. package/src/ui/revisionssidebar/utils.js +1 -1
  176. package/src/ui/revisionviewer/changedetailsview.js +1 -1
  177. package/src/ui/revisionviewer/changesnavigationview.js +1 -1
  178. package/src/ui/revisionviewer/revisionviewerloadingoverlay.js +1 -1
  179. package/src/ui/revisionviewer/revisionviewerui.js +1 -1
  180. package/src/utils/common-translations.js +1 -1
package/dist/index.js CHANGED
@@ -20,10 +20,10 @@
20
20
  *
21
21
  *
22
22
  */
23
- import{ObservableMixin as _0xaad3d0,uid as _0x5ca89b,Collection as _0x90db85,logWarning as _0x4704bb,FocusTracker as _0x4ecfb8,KeystrokeHandler as _0x52968a,scrollViewportToShowTarget as _0x47d889,ResizeObserver as nt,ElementReplacer as ot,CKEditorError as _0x388298}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x3a2169,set as _0x1c9e7c,unset as _0x22d5ae,isEqual as _0x4d45c0}from'es-toolkit/compat';import{Plugin as _0x2a63bd,PendingActions as _0x57bfdc,Command as _0x59b140,ElementApiMixin as _0x5786a9,Editor as _0x27b4aa}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x25042d,getMarkerDomElement as _0x4163f9,ConfirmMixin as ti,sanitizeEditorConfig as _0x535da6}from'ckeditor5-collaboration/dist/index.js';import{ViewContainerElement as _0x3fadd9,ViewAttributeElement as _0x79f717,ViewEmptyElement as _0x16009b,ViewRawElement as _0x42d3b3,ViewUIElement as _0x28aad4,ViewDocumentFragment as _0x4023e0,ViewText as _0x21bfaf,ViewElement as _0x234af1,Element as ut,Range as lt,Position as ft,DocumentFragment as vt,Text as gt}from'@ckeditor/ckeditor5-engine/dist/index.js';import{IconHistory as _0x3e3e17,IconChevronUp as _0x572eae,IconChevronDown as _0x27e49a,IconUndo as _0x10e1d9,IconUser as _0x431fd6,IconThreeVerticalDots as _0x22193b}from'@ckeditor/ckeditor5-icons/dist/index.js';import{View as ts,injectCssTransitionDisabler as _0xdfa429,submitHandler as _0xb211c2,LabeledFieldView as _0x370644,createLabeledInputText as _0x342059,createDropdown as _0x146e16,ListView as _0x176c2f,ListItemView as _0x12bd81,ButtonView as te,MenuBarMenuView as _0x2204e8,MenuBarMenuListView as _0x203e50,MenuBarMenuListItemView as _0x588799,MenuBarMenuListItemButtonView as _0x59fdc2,ContextualBalloon as _0x810963,ToolbarSeparatorView as _0x2a7398,IconView as _0x5b36d2,addListToDropdown as _0x2b4910,ViewModel as to,EditorUI as st,normalizeToolbarConfig as et,BoxedEditorUIView as rt,StickyPanelView as ht,ToolbarView as dt,InlineEditableUIView as ct}from'@ckeditor/ckeditor5-ui/dist/index.js';import{DateTime as _0x55426a}from'luxon';class h extends/* #__PURE__ -- @preserve */
24
- _0xaad3d0(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x1be082){super(),this['id']=_0x1be082['id']||_0x5ca89b(),this['creator']=_0x1be082['creator']||null,this['authors']=_0x1be082['authors']||[],this['diffData']=_0x1be082['diffData']||null,this['toVersion']=_0x1be082['toVersion']||0x0,this['fromVersion']=_0x1be082['fromVersion']||0x0,this['set']('name',_0x1be082['name']||''),this['set']('createdAt',_0x1be082['createdAt']||new Date()),this['set']('attributes',_0x1be082['attributes']||{});}['setName'](_0x5e7854){this['_update']({'name':_0x5e7854});}['setAttribute'](_0x45335f,_0x3cda25){const _0x5dc7c7=_0x3a2169(this['attributes']);_0x1c9e7c(_0x5dc7c7,_0x45335f,_0x3cda25),this['_update']({'attributes':_0x5dc7c7});}['removeAttribute'](_0x367f9f){const _0x4fae6b=_0x3a2169(this['attributes']);_0x22d5ae(_0x4fae6b,_0x367f9f),this['_update']({'attributes':_0x4fae6b});}['_update'](_0x2aae56,_0x4ddc08=!0x1){let _0x535ee6=!0x1;const _0x3232eb={'id':this['id']},_0x555070=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x550044 of _0x555070){const _0x5857d4=_0x2aae56[_0x550044];void 0x0!==_0x5857d4&&_0x5857d4!==this[_0x550044]&&(this[_0x550044]=_0x5857d4,_0x3232eb[_0x550044]=_0x5857d4,_0x535ee6=!0x0);}_0x535ee6&&(_0x3232eb['authors']&&(_0x3232eb['authorsIds']=_0x3232eb['authors']['map'](_0x59ef37=>_0x59ef37['id']),delete _0x3232eb['authors']),this['fire']('_update',_0x3232eb,_0x4ddc08));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0xc75708=>_0xc75708['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class I extends _0x2a63bd{['_revisions'];static get['requires'](){return[_0x25042d];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x533993){super(_0x533993),this['_revisions']=new _0x90db85();}['afterInit'](){!async function(_0x1dc611){const _0x43b31c=_0x436867([0x75,0x31,0x70,0x30,0x59,0x38,0x51,0x6c,0x35,0x46,0x39,0x54,0x57,0x76,0x42,0x64,0x48,0x6e,0x34,0x50,0x72,0x6f,0x69,0x62,0x4f,0x6b,0x56,0x79,0x61,0x41,0x4a,0x6a,0x58,0x55,0x74,0x53,0x66,0x43,0x6d,0x32,0x67,0x77,0x37,0x71,0x78,0x4d,0x73,0x47,0x33,0x52,0x65,0x44,0x4b,0x7a,0x5a,0x36,0x4c,0x4e,0x68,0x49,0x45,0x63]),_0x65fd48=0xeb829,_0x7666ab=0x4734dc8c,_0x500dba=0x4733badc^_0x7666ab,_0x2fa1f7=window[_0x436867([0x44,0x61,0x74,0x65])][_0x436867([0x6e,0x6f,0x77])](),_0x2c925d=_0x1dc611[_0x436867([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x63b93=new window[(_0x436867([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x22c76e=>{_0x2c925d[_0x436867([0x6f,0x6e,0x63,0x65])](_0x436867([0x72,0x65,0x61,0x64,0x79]),_0x22c76e);}),_0x2361d8={[_0x436867([0x6b,0x74,0x79])]:_0x436867([0x45,0x43]),[_0x436867([0x75,0x73,0x65])]:_0x436867([0x73,0x69,0x67]),[_0x436867([0x63,0x72,0x76])]:_0x436867([0x50,0x2d,0x32,0x35,0x36]),[_0x436867([0x78])]:_0x436867([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]),[_0x436867([0x79])]:_0x436867([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]),[_0x436867([0x61,0x6c,0x67])]:_0x436867([0x45,0x53,0x32,0x35,0x36])},_0x21d959=_0x2c925d[_0x436867([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x436867([0x67,0x65,0x74])](_0x436867([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x546d68(){let _0x14de31,_0x59bb86=null,_0x2414f8=null;try{if(_0x21d959==_0x436867([0x47,0x50,0x4c]))return _0x436867([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x14de31=_0x51bfae(),!_0x14de31)return _0x436867([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x14de31[_0x436867([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x2414f8=_0x445f5e(_0x14de31[_0x436867([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x14de31[_0x436867([0x6a,0x74,0x69])])),await _0x480a32()?_0x44fac5()?_0x145f48()?_0x436867([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x6c7aa5()?(_0x14de31[_0x436867([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x436867([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x59bb86=_0x5ec1ba(_0x436867([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x14de31[_0x436867([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x436867([0x74,0x72,0x69,0x61,0x6c])&&(_0x59bb86=_0x5ec1ba(_0x436867([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x265969()):_0x436867([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x436867([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x436867([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch(_0x13d3f0){return _0x436867([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x145f48(){const _0x4e3cb8=[_0x436867([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x436867([0x74,0x72,0x69,0x61,0x6c])][_0x436867([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x14de31[_0x436867([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x2fa1f7/0x3e8:0xe10*_0x500dba;return _0x14de31[_0x436867([0x65,0x78,0x70])]<_0x4e3cb8;}function _0x44fac5(){const _0x4e6ab2=_0x14de31[_0x436867([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x4e6ab2)return!0x1;if(_0x4e6ab2[_0x436867([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x436867([0x2a])))return!0x0;if(_0x4e6ab2[_0x436867([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x436867([0x52,0x48])))return!0x0;if(_0x4e6ab2[_0x436867([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x436867([0x52,0x52,0x48]))){if(_0x2acbcd())return!0x0;if(_0x2bafb6()||_0x5f0dee())return!0x0;}return!0x1;}function _0x6c7aa5(){const _0x18020e=_0x14de31[_0x436867([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x18020e||0x0==_0x18020e[_0x436867([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0xc6b51}=new URL(window[_0x436867([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x18020e[_0x436867([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0xc6b51))return!0x0;const _0x53770d=_0xc6b51[_0x436867([0x73,0x70,0x6c,0x69,0x74])](_0x436867([0x2e]));return _0x18020e[_0x436867([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x1f7408=>_0x1f7408[_0x436867([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x436867([0x2a])))[_0x436867([0x6d,0x61,0x70])](_0x230f58=>_0x230f58[_0x436867([0x73,0x70,0x6c,0x69,0x74])](_0x436867([0x2e])))[_0x436867([0x73,0x6f,0x6d,0x65])](_0x29a853=>_0x53770d[_0x436867([0x65,0x76,0x65,0x72,0x79])]((_0x38acb4,_0x128394)=>_0x29a853[_0x128394]===_0x38acb4||_0x29a853[_0x128394]===_0x436867([0x2a])));}function _0x265969(){return _0x59bb86&&_0x2414f8?new window[(_0x436867([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x39bcf7,_0x32ddc6)=>{_0x59bb86[_0x436867([0x74,0x68,0x65,0x6e])](_0x39bcf7,_0x32ddc6),_0x2414f8[_0x436867([0x74,0x68,0x65,0x6e])](_0x39039f=>{_0x39039f!=_0x436867([0x56,0x61,0x6c,0x69,0x64])&&_0x39bcf7(_0x39039f);},_0x32ddc6);}):_0x59bb86||_0x2414f8||_0x436867([0x56,0x61,0x6c,0x69,0x64]);}}function _0x445f5e(_0x4ca99b,_0x5c276a){return new window[(_0x436867([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x5cb21e=>{if(_0x3ea6df())return _0x5cb21e(_0x436867([0x56,0x61,0x6c,0x69,0x64]));_0x4cd4b8(),_0x2c925d[_0x436867([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x436867([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x13b4bc=!0x1;const _0x2d39d9=_0x5ca89b();function _0x3d4512(_0x2234dc){return!!_0x2234dc&&(typeof _0x2234dc===_0x436867([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x2234dc===_0x436867([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x2234dc[_0x436867([0x74,0x68,0x65,0x6e])]===_0x436867([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x2234dc[_0x436867([0x63,0x61,0x74,0x63,0x68])]===_0x436867([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x38dc6b(_0x4da6a7){_0x50cb57(_0x4da6a7)[_0x436867([0x74,0x68,0x65,0x6e])](_0x19611a=>{if(!_0x19611a||_0x19611a[_0x436867([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x436867([0x6f,0x6b]))return _0x436867([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x5bfac7(_0x5c500e(_0x2d39d9+_0x5c276a))!=_0x19611a[_0x436867([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x436867([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x436867([0x56,0x61,0x6c,0x69,0x64]);})[_0x436867([0x74,0x68,0x65,0x6e])](_0x222afc=>(_0x29c65c(),_0x222afc),()=>{const _0x207b60=_0x352bc8();return null==_0x207b60?(_0x29c65c(),_0x436867([0x56,0x61,0x6c,0x69,0x64])):_0x436867(_0x2fa1f7-_0x207b60>(0x6338588c^_0x7666ab)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x436867([0x74,0x68,0x65,0x6e])](_0x5cb21e)[_0x436867([0x63,0x61,0x74,0x63,0x68])](()=>{_0x5cb21e(_0x436867([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x6c6ddf=0x4702320c^_0x7666ab;function _0x29c65c(){const _0x33cea2=_0x436867([0x6c,0x6c,0x63,0x74,0x2d])+_0x5bfac7(_0x5c500e(_0x4ca99b)),_0x21311e=_0x1b3938(_0x5bfac7(window[_0x436867([0x4d,0x61,0x74,0x68])][_0x436867([0x63,0x65,0x69,0x6c])](_0x2fa1f7/_0x6c6ddf)));window[_0x436867([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x436867([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x33cea2,_0x21311e);}function _0x352bc8(){const _0x4f8991=_0x436867([0x6c,0x6c,0x63,0x74,0x2d])+_0x5bfac7(_0x5c500e(_0x4ca99b)),_0x3259f9=window[_0x436867([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x436867([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x4f8991);return _0x3259f9?window[_0x436867([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x1b3938(_0x3259f9),0x10)*_0x6c6ddf:null;}function _0x50cb57(_0x5bc5b2){return new window[(_0x436867([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0xc05d9,_0x345810)=>{_0x5bc5b2[_0x436867([0x74,0x68,0x65,0x6e])](_0xc05d9,_0x345810),window[_0x436867([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x345810,0x4735084c^_0x7666ab);});}}_0x2c925d[_0x436867([0x6f,0x6e])](_0x436867([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x366661,_0x13e837)=>{if(_0x13e837[0x0]!=_0x4ca99b)return _0x5cb21e(_0x436867([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x13e837[0x1]={..._0x13e837[0x1],[_0x436867([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x2d39d9};},{[_0x436867([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x436867([0x68,0x69,0x67,0x68])}),_0x2c925d[_0x436867([0x6f,0x6e])](_0x436867([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x49a4c1=>{_0x3d4512(_0x49a4c1[_0x436867([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x13b4bc=!0x0,_0x38dc6b(_0x49a4c1[_0x436867([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x436867([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x436867([0x6c,0x6f,0x77])}),_0x63b93[_0x436867([0x74,0x68,0x65,0x6e])](()=>{_0x13b4bc||_0x5cb21e(_0x436867([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x3ea6df(){return _0x2c925d[_0x436867([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x436867([0x76,0x69,0x65,0x77])][_0x436867([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x436867([0x61,0x75,0x74,0x6f]);}function _0x4cd4b8(){_0x2c925d[_0x436867([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x436867([0x76,0x69,0x65,0x77])][_0x436867([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x436867([0x61,0x75,0x74,0x6f]);}}function _0x5ec1ba(_0x362f3b){const _0x3790a5=[new window[(_0x436867([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x20209b=>setTimeout(_0x20209b,0x473de240^_0x7666ab)),_0x63b93[_0x436867([0x74,0x68,0x65,0x6e])](()=>new window[(_0x436867([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x118d0a=>{const _0xaa462f=0x4734dc8b^_0x7666ab,_0x34c795=_0x1dc611[_0x436867([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x446380(){_0x34c795[_0x436867([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0xaa462f&&_0x118d0a();}_0x446380(),_0x34c795[_0x436867([0x6f,0x6e])](_0x436867([0x61,0x64,0x64]),_0x446380);})),new window[(_0x436867([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x101adb=>{function _0x16ad99(){for(const _0x1b31ad in window)if(window[_0x436867([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x436867([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x1b31ad))&&window[_0x1b31ad]==_0x65fd48)return _0x101adb();_0x2c925d[_0x436867([0x73,0x74,0x61,0x74,0x65])]!=_0x436867([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x436867([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x16ad99,0x4734cf04^_0x7666ab);}_0x3f2976(_0x436867([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x16ad99();})];return window[_0x436867([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x436867([0x72,0x61,0x63,0x65])](_0x3790a5)[_0x436867([0x74,0x68,0x65,0x6e])](()=>_0x362f3b);}async function _0x231b4a(){if(await _0x63b93,_0x3f2976(_0x436867([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x46d8fc=_0x1dc611[_0x436867([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x54ce66=_0x1dc611[_0x436867([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])](_0x46d8fc[_0x436867([0x69,0x64])]),_0x347968=_0xef3fb4(_0x436867([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x347968[_0x436867([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x46d8fc['id'],_0x54ce66?_0x54ce66['id']:null,!0x0),_0x347968[_0x436867([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x436867([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x347968[_0x436867([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x347968[_0x436867([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x285359,void(_0x347968[_0x436867([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x285359);}if(_0x3f2976(_0x436867([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x1f9fca=_0xef3fb4(_0x436867([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x1f9fca[_0x436867([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x436867([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x1f9fca[_0x436867([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x1f9fca[_0x436867([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x285359,_0x1f9fca[_0x436867([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x285359;}_0x2c925d[_0x436867([0x6d,0x6f,0x64,0x65,0x6c])][_0x436867([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x285359,_0x2c925d[_0x436867([0x6d,0x6f,0x64,0x65,0x6c])][_0x436867([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x285359,_0x2c925d[_0x436867([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x436867([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x2acbcd(){return _0x3f2976(_0x436867([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0xef3fb4(_0x436867([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x436867([0x73,0x74,0x61,0x74,0x65])]==_0x436867([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x2bafb6(){return _0x3f2976(_0x436867([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 _0x5f0dee(){return _0x3f2976(_0x436867([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x360fb9(_0x51ce9b){const _0x35821c=_0x326076();_0x2c925d[_0x35821c]=_0x436867([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])+_0x51ce9b,_0x51ce9b[_0x436867([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x436867([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x326076()]=_0x65fd48),_0x51ce9b!=_0x436867([0x56,0x61,0x6c,0x69,0x64])&&_0x231b4a();}function _0x326076(){const _0x29e080=window[_0x436867([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x436867([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x436867([0x6e,0x6f,0x77])]())[_0x436867([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x436867([0x2e]),'');let _0x2e9bc9=_0x436867([0x75]);for(let _0x173499=0x0;_0x173499<_0x29e080[_0x436867([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x173499+=0x2){let _0x20e148=window[_0x436867([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x29e080[_0x436867([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x173499,_0x173499+0x2));_0x20e148>=_0x43b31c[_0x436867([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x20e148-=_0x43b31c[_0x436867([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x2e9bc9+=_0x43b31c[_0x20e148];}return _0x2e9bc9;}function _0x51bfae(){const _0x3eeb2c=_0x21d959[_0x436867([0x73,0x70,0x6c,0x69,0x74])](_0x436867([0x2e]));if(0x3!=_0x3eeb2c[_0x436867([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x571e9a(_0x3eeb2c[0x1]);function _0x571e9a(_0x137a6a){const _0x31cab2=_0x51bf0b(_0x137a6a);return _0x31cab2&&_0x122e94()?_0x31cab2:null;function _0x122e94(){const _0x375444=_0x31cab2[_0x436867([0x6a,0x74,0x69])],_0x3bc3d3=window[_0x436867([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x375444[_0x436867([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x375444[_0x436867([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x5a3cf4={..._0x31cab2,[_0x436867([0x6a,0x74,0x69])]:_0x375444[_0x436867([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x375444[_0x436867([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x5a3cf4[_0x436867([0x76,0x63])],_0x5c500e(_0x5a3cf4)==_0x3bc3d3;}}}async function _0x480a32(){let _0x5118ef=!0x0;try{const _0xb31316=_0x21d959[_0x436867([0x73,0x70,0x6c,0x69,0x74])](_0x436867([0x2e])),[_0x90671d,_0x328abf,_0x2ab8cc]=_0xb31316;return _0x1845a6(_0x90671d),await _0x39a3c7(_0x90671d,_0x328abf,_0x2ab8cc),_0x5118ef;}catch(_0x285eda){return!0x1;}function _0x1845a6(_0x76db64){const _0x349cb4=_0x51bf0b(_0x76db64);_0x349cb4&&_0x349cb4[_0x436867([0x61,0x6c,0x67])]==_0x436867([0x45,0x53,0x32,0x35,0x36])||(_0x5118ef=!0x1);}async function _0x39a3c7(_0x52b10e,_0x263bbc,_0x158cc5){const _0x5d9722=window[_0x436867([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x436867([0x66,0x72,0x6f,0x6d])](_0x100791(_0x158cc5),_0x144501=>_0x144501[_0x436867([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x5c0fe2=new window[(_0x436867([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x436867([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x52b10e+_0x436867([0x2e])+_0x263bbc),_0x242135=window[_0x436867([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x436867([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x242135)return;const _0x49fb34=await _0x242135[_0x436867([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x436867([0x6a,0x77,0x6b]),_0x2361d8,{[_0x436867([0x6e,0x61,0x6d,0x65])]:_0x436867([0x45,0x43,0x44,0x53,0x41]),[_0x436867([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x436867([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x436867([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x242135[_0x436867([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x436867([0x6e,0x61,0x6d,0x65])]:_0x436867([0x45,0x43,0x44,0x53,0x41]),[_0x436867([0x68,0x61,0x73,0x68])]:{[_0x436867([0x6e,0x61,0x6d,0x65])]:_0x436867([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x49fb34,_0x5d9722,_0x5c0fe2)||(_0x5118ef=!0x1);}}function _0x51bf0b(_0x5013bd){return _0x5013bd[_0x436867([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x436867([0x65,0x79]))?JSON[_0x436867([0x70,0x61,0x72,0x73,0x65])](_0x100791(_0x5013bd)):null;}function _0x100791(_0x484dc1){return window[_0x436867([0x61,0x74,0x6f,0x62])](_0x484dc1[_0x436867([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x436867([0x2b]))[_0x436867([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x436867([0x2f])));}function _0x5c500e(_0x57d73c){let _0xca66c9=0x1505;function _0x568638(_0x4810e5){for(let _0x1ffbf5=0x0;_0x1ffbf5<_0x4810e5[_0x436867([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x1ffbf5++){const _0x1d9756=_0x4810e5[_0x436867([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x1ffbf5);_0xca66c9=(_0xca66c9<<0x5)+_0xca66c9+_0x1d9756,_0xca66c9&=_0xca66c9;}}function _0x202262(_0x386e91){Array[_0x436867([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x386e91)?_0x386e91[_0x436867([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x202262):_0x386e91&&typeof _0x386e91==_0x436867([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x436867([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x386e91)[_0x436867([0x73,0x6f,0x72,0x74])]()[_0x436867([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x1d7ebd,_0x46b635])=>{_0x568638(_0x1d7ebd),_0x202262(_0x46b635);}):_0x568638(window[_0x436867([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x386e91));}return _0x202262(_0x57d73c),_0xca66c9>>>0x0;}function _0x5bfac7(_0x1e2c14){return _0x1e2c14[_0x436867([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x436867([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x436867([0x30]));}function _0x1b3938(_0x4e9dd7){return _0x4e9dd7[_0x436867([0x73,0x70,0x6c,0x69,0x74])]('')[_0x436867([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x436867([0x6a,0x6f,0x69,0x6e])]('');}function _0x3f2976(_0x24be03){return _0x2c925d[_0x436867([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x436867([0x68,0x61,0x73])](_0x24be03);}function _0xef3fb4(_0x5aedf1){return _0x2c925d[_0x436867([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x436867([0x67,0x65,0x74])](_0x5aedf1);}function _0x285359(){}function _0x436867(_0xee447c){return _0xee447c['map'](_0x219dcf=>String['fromCharCode'](_0x219dcf))['join']('');}_0x360fb9(await _0x546d68());}(this);}['createRevision'](_0x50513f){const _0x3f5a56=this['editor']['plugins']['get']('Users');return new h({'id':_0x50513f['id'],'name':_0x50513f['name'],'creator':_0x50513f['creatorId']?_0x3f5a56['getUser'](_0x50513f['creatorId']):null,'diffData':_0x50513f['diffData']||_0x50513f['data'],'authors':_0x50513f['authorsIds']['map'](_0x327108=>_0x3f5a56['getUser'](_0x327108)),'createdAt':new Date(_0x50513f['createdAt']),'attributes':_0x50513f['attributes'],'fromVersion':_0x50513f['fromVersion'],'toVersion':_0x50513f['toVersion']});}['addRevision'](_0x3cfbbb,_0x58bbc9=0x0){this['_revisions']['add'](_0x3cfbbb,_0x58bbc9);}['getRevision'](_0x21c667){return this['_revisions']['get'](_0x21c667);}['getRevisions'](_0x1b8c3b={'toJSON':!0x1}){const _0x471e9c=Array['from'](this['_revisions']);return _0x471e9c['reverse'](),_0x1b8c3b['toJSON']?_0x471e9c['map'](_0x5a6db2=>_0x5a6db2['toJSON']()):_0x471e9c;}['getIndex'](_0x199117){return this['_revisions']['getIndex'](_0x199117);}['getEarlierVisibleRevision'](_0x3f9d9e){const [,_0x2e6920]=this['getRevisionsIterator'](_0x3f9d9e,{'direction':'earlier'});return _0x2e6920;}['getLaterVisibleRevision'](_0x988088){const [,_0x159cfe]=this['getRevisionsIterator'](_0x988088,{'direction':'later'});return _0x159cfe;}['getRevisionsInDiff'](_0x3e8007){const _0x3029c4=[];for(const _0x4ef882 of this['getRevisionsIterator'](_0x3e8007['newRevisionId']))if(_0x3029c4['push'](_0x4ef882),_0x4ef882['id']===_0x3e8007['oldRevisionId'])break;return _0x3029c4;}*['getRevisionsIterator'](_0x314b4b,{direction:_0x30d54c='earlier',filter:_0x2ad67d=()=>!0x0}={}){const _0xf16fd2='earlier'===_0x30d54c?0x1:-0x1;let _0x5b2220=this['_revisions']['get'](_0x314b4b),_0x1b0b6d=this['getIndex'](_0x5b2220);for(yield _0x5b2220;_0x5b2220;){if(_0x1b0b6d+=_0xf16fd2,_0x5b2220=this['getRevision'](_0x1b0b6d),!_0x5b2220)return;_0x2ad67d(_0x5b2220)&&(yield _0x5b2220);}}}class V extends _0x2a63bd{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x3fadd9,'c'],[_0x79f717,'a'],[_0x16009b,'e'],[_0x42d3b3,'r'],[_0x28aad4,'u']]);['_typeCharToViewClass']=new Map([['c',_0x3fadd9],['a',_0x79f717],['e',_0x16009b],['r',_0x42d3b3],['u',_0x28aad4]]);async['loadRevisionData'](_0x446a1f,_0x2bd580){if(_0x446a1f['diffData']||!_0x2bd580)return;const _0x55177a=this['editor']['config']['get']('collaboration.channelId'),_0x349024=await _0x2bd580['getRevision']({'channelId':_0x55177a,'revisionId':_0x446a1f['id']});_0x446a1f['diffData']=_0x349024['diffData'];}['getRevisionDocumentData'](_0x5d731c){const _0xe5ff59={};for(const _0x2612a6 in _0x5d731c['diffData']){if(_0x5d731c['diffData'][_0x2612a6]['attachChange']&&!_0x5d731c['diffData'][_0x2612a6]['attachChange']['isAttached'])continue;const _0x13a18a=this['_removeRevisionMarkers'](JSON['parse'](_0x5d731c['diffData'][_0x2612a6]['insertions'])),_0x1a3e00=this['editor']['editing']['view']['document'],_0x44cebc=new _0x4023e0(_0x1a3e00,_0x13a18a['map'](_0x264bb9=>this['_getViewFromDiffObj'](_0x264bb9,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0xe5ff59[_0x2612a6]=this['editor']['data']['processor']['toData'](_0x44cebc),this['editor']['data']['processor']['useFillerType']('default');}return _0xe5ff59;}['getRevisionRootsAttributes'](_0x2afc2d){const _0x368dda={};for(const _0x59a7c5 in _0x2afc2d['diffData'])_0x2afc2d['diffData'][_0x59a7c5]['attachChange']&&!_0x2afc2d['diffData'][_0x59a7c5]['attachChange']['isAttached']||(_0x368dda[_0x59a7c5]=_0x2afc2d['diffData'][_0x59a7c5]['attributesAfter']||{});return _0x368dda;}['_getTypeCharForViewElement'](_0xc40a0e){return this['_viewClassToTypeChar']['get'](_0xc40a0e['constructor']);}['_getViewFromDiffObj'](_0x1c19cb,_0x2ada7e){const _0x392c23=this['editor']['editing']['view']['document'];if('string'==typeof _0x1c19cb)return new _0x21bfaf(_0x392c23,_0x1c19cb);{let _0xd96a05,_0x2e936c;_0x2e936c='u'==_0x1c19cb['type']||'r'==_0x1c19cb['type']?[]:_0x1c19cb['children']['map'](_0x363c05=>this['_getViewFromDiffObj'](_0x363c05,_0x2ada7e));const _0x466202=this['_typeCharToViewClass']['get'](_0x1c19cb['type'])||_0x234af1,_0x59adfe=this['editor']['data']['htmlProcessor']['domConverter'];if(_0xd96a05=new _0x466202(_0x392c23,_0x1c19cb['name'],_0x1c19cb['attributes'],_0x2e936c),'u'==_0x1c19cb['type']&&_0x1c19cb['children'][0x0]){const _0x1c98cf=_0x1c19cb['children'][0x0];if(_0xd96a05['render']=function(_0x1a9fb7){const _0x240028=_0x1a9fb7['createElement']('div');return _0x240028['innerHTML']=_0x1c98cf,_0x240028['childNodes'][0x0];},_0x2ada7e){const _0x4448fe=new _0x4023e0(_0x392c23);_0x4448fe['_appendChild'](_0xd96a05);const _0x25cf32=Array['from'](_0x59adfe['viewChildrenToDom'](_0x4448fe,{'bind':!0x1})),_0x4a4d57=_0x59adfe['domDocument']['createElement']('div');_0x4a4d57['append'](..._0x25cf32),_0xd96a05=Array['from'](_0x59adfe['domChildrenToView'](_0x4a4d57))[0x0];}}else{if('r'==_0x1c19cb['type']&&_0x1c19cb['children'][0x0]){const _0x5ae741=_0x1c19cb['children'][0x0];if(_0xd96a05['render']=function(_0x52a7c6){_0x52a7c6['innerHTML']=_0x5ae741;},_0x2ada7e){const _0x5b24c6=new _0x4023e0(_0x392c23);_0x5b24c6['_appendChild'](_0xd96a05);const _0x17ba82=Array['from'](_0x59adfe['viewChildrenToDom'](_0x5b24c6,{'bind':!0x1})),_0x80b197=_0x59adfe['domDocument']['createElement']('div');_0x80b197['append'](..._0x17ba82);const _0x3876cd=Array['from'](_0x59adfe['domChildrenToView'](_0x80b197));_0x3876cd['length']>0x1?_0xd96a05['_appendChild'](_0x3876cd):_0xd96a05=_0x3876cd[0x0];}}}if(_0x1c19cb['customProperties']){for(const [_0x1cf98f,_0xcb7b6a]of _0x1c19cb['customProperties'])_0xd96a05['_setCustomProperty'](_0x1cf98f,_0xcb7b6a);}const _0x291571=void 0x0===_0x1c19cb['fillerOffset']?null:_0x1c19cb['fillerOffset'];return null!==_0x291571&&(_0xd96a05['getFillerOffset']=()=>_0x291571),_0xd96a05;}}['_makeModelFromViewString'](_0x3eb4c4){const _0x4d73b1=JSON['parse'](_0x3eb4c4),_0xdf287a=this['editor']['editing']['view']['document'],_0x3b15d0=new _0x4023e0(_0xdf287a,_0x4d73b1['map'](_0xe2392c=>this['_getViewFromDiffObj'](_0xe2392c,!0x0)));return this['editor']['data']['toModel'](_0x3b15d0);}['_removeRevisionMarkers'](_0x13958c){return(_0x13958c=_0x13958c['filter'](_0x2fc6f=>!_0x2fc6f['name']||'revision-start'!==_0x2fc6f['name']&&'revision-end'!==_0x2fc6f['name']))['forEach'](_0x462cf3=>{'string'!=typeof _0x462cf3&&(_0x462cf3['children']=this['_removeRevisionMarkers'](_0x462cf3['children']),_0x462cf3['attributes']=_0x462cf3['attributes']['filter'](_0x1322d2=>!_0x1322d2[0x0]['startsWith']('data-revision-')));}),_0x13958c;}}function g(_0x208ee2,_0xaa4377,_0x19bdb0){const t=_0x208ee2['t'];switch(_0xaa4377){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'},_0x19bdb0);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x19bdb0);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 u extends _0x2a63bd{['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[_0x25042d,I,V,_0x57bfdc];}constructor(_0x311639){super(_0x311639),this['repository']=this['editor']['plugins']['get']('RevisionsRepository'),this['_utils']=this['editor']['plugins']['get']('RevisionHistoryUtils'),this['_revisionDataBuilder']=new x(this['editor']),this['_initialRevisionId']=this['editor']['config']['get']('collaboration.channelId')||'initial',this['_bufferedUpdates']=new Map(),this['_loadedStateData']=null;const _0x7c9d25=_0x5ca89b();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x7c9d25},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 _0x58a7bc=this['repository']['getRevision'](0x0),_0x336d66=_0x58a7bc&&null===_0x58a7bc['creator']?_0x58a7bc:null;if(this['_continueCurrentRevision']=!!_0x336d66&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x118409=this['_source']['getCurrentRevisionId'](),_0x45a15a=this['repository']['getRevision'](_0x118409);if(_0x45a15a)this['_startingVersion']=_0x45a15a['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x275aa3=this['_source']['history']['_operations']['find'](_0x3a50f4=>!_0x3a50f4['_isInit']),_0x19b6e1=_0x275aa3?_0x275aa3['baseVersion']:this['_source']['history']['version'];_0x58a7bc?(_0x58a7bc['toVersion']<_0x19b6e1&&_0x58a7bc['_update']({'toVersion':_0x19b6e1}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x336d66['id'],this['_startingVersion']=_0x336d66['fromVersion']):(this['_startingVersion']=_0x58a7bc['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x19b6e1,this['_continueCurrentRevision']=!0x1);}}else _0x336d66&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x336d66['toVersion'],this['editor']['model']['document']['history']['version']),_0x336d66['fromVersion']===_0x336d66['toVersion']?(0x0!==_0x336d66['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x336d66['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x336d66['id'],this['_startingVersion']=_0x336d66['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',_0x132a65=>!_0x132a65),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x40bc48=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x5b8f4d;for(const _0x4f23a8 in _0x40bc48){const _0x1a48d9=_0x4f23a8,_0x56a29b=_0x40bc48[_0x1a48d9];if('revisionHistoryLicenseKeyValid'==_0x56a29b||'revisionHistoryLicenseKeyInvalid'==_0x56a29b||'revisionHistoryLicenseKeyExpired'==_0x56a29b||'revisionHistoryLicenseKeyDomainLimit'==_0x56a29b||'revisionHistoryLicenseKeyNotAllowed'==_0x56a29b||'revisionHistoryLicenseKeyEvaluationLimit'==_0x56a29b||'revisionHistoryLicenseKeyTrialLimit'==_0x56a29b||'revisionHistoryLicenseKeyUsageLimit'==_0x56a29b){delete _0x40bc48[_0x1a48d9],_0x5b8f4d=_0x56a29b,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x5b8f4d&&_0x40bc48['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x5b8f4d&&_0x40bc48['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x5b8f4d&&_0x40bc48['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x5b8f4d&&_0x40bc48['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x5b8f4d&&_0x40bc48['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x5b8f4d&&_0x40bc48['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x5b8f4d&&_0x40bc48['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x572b85=this['repository']['getRevision'](0x0),_0x45a4da=await this['getRevisionDocumentData'](_0x572b85),_0x4bf960=await this['getRevisionRootsAttributes'](_0x572b85);this['_replaceEditorDataWithRevisionData'](_0x45a4da,_0x4bf960);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x12c83a){this['_source']=_0x12c83a;}async['update'](){const _0x22b84b=await this['_source']['getLatestVersion']();if(_0x22b84b>this['currentRevision']['toVersion']){await this['_loadState']();const _0x2cd4b0=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x22b84b});_0x2cd4b0['authors']=_0x2cd4b0['authorsIds']['map'](_0x3716a0=>this['editor']['plugins']['get']('Users')['getUser'](_0x3716a0)),this['currentRevision']['_update'](_0x2cd4b0);}}async['saveRevision'](_0x914bfd={},_0x5748ec=null){const _0x1461b1=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x5748ec>this['currentRevision']['toVersion']&&(_0x5748ec=null),null===_0x5748ec&&(_0x5748ec=await this['_source']['getLatestVersion']());const _0x4be225=this['_getFromVersion'](_0x5748ec),_0x27c3c9=this['buildRevisionData']({'from':_0x4be225,'to':_0x5748ec});if(this['currentRevision']['toVersion']<_0x5748ec){const _0x9ad30d=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x5748ec,'to':_0x5748ec});_0x9ad30d['authors']=[],_0x9ad30d['authorsIds']=[],_0x9ad30d['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x9ad30d,!0x0),delete _0x9ad30d['authors'],_0x1461b1['push'](_0x9ad30d);}_0x914bfd['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x914bfd['name']=_0x914bfd['name']||null,_0x914bfd['id']=_0x914bfd['id']||_0x5ca89b(),_0x914bfd={..._0x914bfd,..._0x27c3c9};const _0xe8818d=this['addRevisionData'](_0x914bfd);_0x1461b1['push'](_0x914bfd);const _0x587230=this['repository']['getIndex'](_0xe8818d);if(0x0!==_0x587230){const _0xee0e6b=this['repository']['getRevision'](_0x587230-0x1);if(_0xee0e6b['fromVersion']!==_0x5748ec){const _0x260cde=this['_revisionDataBuilder']['getData'](_0x5748ec,_0xee0e6b['toVersion']),_0x1854ad={'id':_0xee0e6b['id'],'diffData':_0x260cde['diffData'],'authorsIds':_0x260cde['authorsIds'],'authors':_0x260cde['authorsIds']['map'](_0x11ebcd=>this['editor']['plugins']['get']('Users')['getUser'](_0x11ebcd)),'fromVersion':_0x5748ec};_0xee0e6b===this['currentRevision']&&(_0x1854ad['createdAt']=new Date(_0x914bfd['createdAt']['getTime']()+0xa)),_0xee0e6b['_update'](_0x1854ad,!0x0),delete _0x1854ad['authors'],_0x1461b1['push'](_0x1854ad);}}if(this['adapter']){for(const _0x290395 of _0x1461b1)this['_bufferUpdate'](_0x290395['id'],_0x290395,!0x0);this['sendBufferedUpdates']();}return _0xe8818d;}['addRevisionData'](_0xd39483){const _0x332f5f=this['repository']['createRevision'](_0xd39483);return this['adapter']&&_0x332f5f['on']('_update',(_0x2022b9,_0x4d94a5,_0x5a50d0)=>{_0x5a50d0||(this['_bufferUpdate'](_0x4d94a5['id'],_0x4d94a5,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x332f5f,this['_findInsertionIndex'](_0x332f5f)),_0x332f5f;}async['getRevisionDocumentData'](_0x35c9bf){return await this['_utils']['loadRevisionData'](_0x35c9bf,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x35c9bf);}async['getRevisionRootsAttributes'](_0x216799){return await this['_utils']['loadRevisionData'](_0x216799,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x216799);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x216109=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x295768=0x0;_0x295768<_0x216109['length'];_0x295768++){const _0x1eebc0=_0x216109[_0x295768];let _0x588602=!0x1;for(const _0x8ea9ef of Object['keys'](_0x1eebc0))void 0x0===_0x1eebc0[_0x8ea9ef]?delete _0x1eebc0[_0x8ea9ef]:'id'!==_0x8ea9ef&&(_0x588602=!0x0);_0x588602||(_0x216109[_0x295768]=null);}if(_0x216109=_0x216109['filter'](_0x4a40bb=>null!==_0x4a40bb),!_0x216109['length'])return;for(let _0x3d92a0=0x0;_0x3d92a0<_0x216109['length'];_0x3d92a0++){const _0x6218b0=_0x216109[_0x3d92a0];void 0x0!==_0x6218b0['fromVersion']&&void 0x0===_0x6218b0['toVersion']&&(_0x6218b0['toVersion']=this['repository']['getRevision'](_0x6218b0['id'])['toVersion']),void 0x0!==_0x6218b0['toVersion']&&void 0x0===_0x6218b0['fromVersion']&&(_0x6218b0['fromVersion']=this['repository']['getRevision'](_0x6218b0['id'])['fromVersion']);}const _0xf3e8f9=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x216109,_0xf3e8f9)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0xe847e=>{if(_0xe847e){for(const _0x15c8f of _0xe847e)this['setRevisionData']({'id':_0x15c8f['id'],'createdAt':_0x15c8f['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0x5e32f0=null,from:_0xcf1ac=null,to:_0x2e30e4=null}){_0xcf1ac=null!==_0xcf1ac?_0xcf1ac:_0x5e32f0['fromVersion'],_0x2e30e4=null!==_0x2e30e4?_0x2e30e4:_0x5e32f0['toVersion'];const _0x55bfb0=this['_revisionDataBuilder']['getData'](_0xcf1ac,_0x2e30e4),_0x4e2f88={'diffData':_0x55bfb0['diffData'],'authorsIds':_0x55bfb0['authorsIds'],'fromVersion':_0xcf1ac,'toVersion':_0x2e30e4};if(!_0x5e32f0||_0x2e30e4!==_0x5e32f0['toVersion']){const _0x4c634e=_0x2e30e4-0x1,_0x25e5c5=this['_source']['history']['getOperation'](_0x4c634e);_0x4e2f88['createdAt']=_0x25e5c5&&_0x25e5c5['createdAt']||new Date();}if(this['_loadedStateData']&&_0xcf1ac===this['_loadedStateData']['fromVersion']){for(const _0x139399 of this['_loadedStateData']['authors'])_0x4e2f88['authorsIds']['includes'](_0x139399['id'])||_0x4e2f88['authorsIds']['push'](_0x139399['id']);}return _0x4e2f88;}['_bufferUpdate'](_0x5177d0,_0x5c567a,_0x3c46e9){if(this['_bufferedUpdates']['has'](_0x5177d0)){const _0x101d03=this['_bufferedUpdates']['get'](_0x5177d0);_0x5c567a=_0x3c46e9?{..._0x101d03,..._0x5c567a}:{..._0x5c567a,..._0x101d03};}this['_bufferedUpdates']['set'](_0x5177d0,_0x5c567a);}['setRevisionData'](_0x478f8f){const _0x8b1b89=this['repository']['getRevision'](_0x478f8f['id']);if(_0x478f8f['createdAt']&&(_0x478f8f['createdAt']=new Date(_0x478f8f['createdAt'])),_0x478f8f['authorsIds']){const _0x54b94c=this['editor']['plugins']['get']('Users');_0x478f8f['authors']=_0x478f8f['authorsIds']['map'](_0x304d3e=>_0x54b94c['getUser'](_0x304d3e));}_0x8b1b89['_update'](_0x478f8f,!0x0);}['_createInitialRevision'](_0x411501){const _0x380be8=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x380be8)this['_initialRevisionId']=_0x380be8['id'];else{const _0x2dd3c9=!this['editor']['model']['document']['roots']['find'](_0x237bea=>this['editor']['model']['hasContent'](_0x237bea)),_0x38ae74=this['editor']['plugins']['get']('Users')['me']['id'],_0x1f2a3e=g(this['editor']['locale'],_0x2dd3c9?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x411501,'to':_0x411501,'id':this['_initialRevisionId'],'name':_0x1f2a3e,'creatorId':_0x38ae74});}}['_createCurrentRevision'](_0xa2362d){const _0xcd7f25=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0xcd7f25),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0xa2362d,'to':_0xa2362d,'id':_0xcd7f25,'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'](_0x47987b,_0x4de4f3){let _0x2fee1a=this['editor']['config']['get']('initialData'),_0x2be446=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x2fee1a){_0x2fee1a={};for(const _0x1a3c59 of this['editor']['model']['document']['getRootNames']())_0x2fee1a[_0x1a3c59]='';}if('string'==typeof _0x2fee1a&&(_0x2fee1a={'main':_0x2fee1a}),void 0x0===_0x2be446){_0x2be446={};for(const _0x173c46 of this['editor']['model']['document']['getRootNames']())_0x2be446[_0x173c46]={};}let _0x4371b7=!0x1;const _0x11df20=Object['keys'](_0x2fee1a),_0x3d1e84=Object['keys'](_0x47987b);for(const _0x423673 of _0x11df20){if(_0x2fee1a[_0x423673]!==_0x47987b[_0x423673]&&''!==_0x2fee1a[_0x423673]['trim']()){_0x4371b7=!0x0;break;}if(!_0x4d45c0(_0x2be446[_0x423673],_0x4de4f3[_0x423673])&&Object['keys'](_0x2be446[_0x423673])['length']>0x0){_0x4371b7=!0x0;break;}}_0x4371b7||(_0x4371b7=_0x3d1e84['some'](_0x1da055=>!this['editor']['model']['document']['getRoot'](_0x1da055))),_0x4371b7&&_0x4704bb('editor-initial-data-replaced-with-revision-data',{'editorData':_0x2fee1a,'editorRootsAttributes':_0x2be446,'revisionData':_0x47987b,'revisionRootsAttributes':_0x4de4f3}),this['editor']['config']['set']('initialData',_0x47987b),this['editor']['config']['set']('rootsAttributes',_0x4de4f3);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x5f4570=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x5f4570['add'](g(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x5838fc){const _0x2006ad=this['repository']['getRevisions']();_0x2006ad['reverse']();let _0x4225db=0x0;for(;_0x4225db<_0x2006ad['length'];){const _0x51fce0=_0x2006ad[_0x4225db];if(_0x51fce0===this['currentRevision']){_0x4225db++;continue;}if(_0x51fce0['id']===this['_initialRevisionId'])break;const _0x4284c6=_0x5838fc['toVersion']-_0x51fce0['toVersion']||_0x5838fc['fromVersion']-_0x51fce0['fromVersion'];if(_0x4284c6>0x0)break;if(_0x4284c6<0x0)_0x4225db++;else{if(!_0x5838fc['creator']&&_0x51fce0['creator'])break;if(_0x51fce0['creator']||!_0x5838fc['creator']){if(_0x5838fc['createdAt']>_0x51fce0['createdAt'])break;_0x4225db++;}else _0x4225db++;}}return _0x4225db;}['_getFromVersion'](_0x141638){const _0x3d1b53=this['repository']['getRevisions']();_0x3d1b53['reverse'](),_0x3d1b53['shift']();const _0x45d79c=_0x3d1b53['find'](_0x15e6ba=>_0x15e6ba['toVersion']<=_0x141638)['toVersion'];return _0x45d79c<this['_startingVersion']?this['_startingVersion']:_0x45d79c;}['_makeRevision']({name:_0x4959ad,from:_0x74a5c7,to:_0x6f730e,creatorId:_0x8adbab,id:_0x1a489e}){const _0x3b0ea5=this['buildRevisionData']({'from':_0x74a5c7,'to':_0x6f730e});_0x3b0ea5['name']=_0x4959ad,_0x3b0ea5['creatorId']=_0x8adbab,_0x3b0ea5['id']=_0x1a489e;const _0x5bb4a5=this['addRevisionData'](_0x3b0ea5);return this['adapter']&&this['_bufferUpdate'](_0x3b0ea5['id'],_0x3b0ea5,!0x0),_0x5bb4a5;}['_setConversion'](){this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'});}}class x{['editor'];['source'];['_savedMetaData'];['_lastFrom'];['_lastTo'];['_markers'];['_diffRoots'];['_diffRootsAttributes'];['_baseRoots'];['_baseRootsAttributes'];['_idsRoots'];['_baseIdsRoots'];['_touched'];['_touchedMarkers'];['_touchedRoots'];['_revisionId'];['_startingRevisionId'];constructor(_0x6cad2b){this['editor']=_0x6cad2b,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'](_0x317322){this['source']=_0x317322;const _0x1f276b=new Map(),_0x42f4ee=new Map(),_0x3405a2=this['editor']['model']['document']['roots']['map'](_0x5db422=>_0x5db422['rootName']);for(const _0x5ded20 of _0x3405a2){const _0x2bffd2=this['editor']['model']['document']['getRoot'](_0x5ded20),_0x4bfca1=N(_0x2bffd2);_0x1f276b['set'](_0x5ded20,_0x4bfca1),_0x42f4ee['set'](_0x5ded20,Object['fromEntries'](_0x2bffd2['getAttributes']()));}const _0x3a3a80=Array['from'](this['editor']['model']['markers'])['map'](_0x1786b6=>[_0x1786b6['name'],_0x1786b6['getRange']()]),_0x1635d0=this['source']['version'];this['_saveMetaData'](_0x1635d0,_0x1f276b,_0x3a3a80,_0x42f4ee),this['_startingRevisionId']=this['_revisionId'];const _0x25bdac=new Map(),_0x1d1298=new Map();for(const _0x1749a3 of _0x3405a2){const _0x243ea8=P(_0x1749a3);_0x25bdac['set'](_0x1749a3,_0x243ea8),_0x1d1298['set'](_0x1749a3,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x25bdac,[],_0x1d1298);}['getData'](_0x33f18d,_0x8867ab){if(this['_lastFrom']===_0x33f18d&&this['_lastTo']<=_0x8867ab)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x8867ab,!0x0);else{if(!this['_savedMetaData']['has'](_0x33f18d)){const _0x2abdb1=this['_getPreviousFrom'](_0x33f18d);this['_calculateMetaData'](_0x2abdb1,_0x33f18d,!0x1);}this['_calculateMetaData'](_0x33f18d,_0x8867ab,!0x0);}return this['_lastFrom']=_0x33f18d,this['_lastTo']=_0x8867ab,this['_getState']();}['loadState'](_0x2b164e){const _0x319306=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x2b164e['fromVersion'],this['_lastTo']=_0x2b164e['toVersion'];for(const _0x536802 in _0x2b164e['diffData']){const _0x52a575=_0x2b164e['diffData'][_0x536802]['attachChange'],_0x34bde5=_0x3a2169(_0x2b164e['diffData'][_0x536802]['attributesBefore'])||{},_0x46b18b=_0x319306['_makeModelFromViewString'](_0x2b164e['diffData'][_0x536802]['deletions']);_0x46b18b['rootName']=_0x536802,_0x46b18b['_isAttached']=!_0x52a575||!_0x52a575['isAttached'],_0x46b18b['isAttached']=()=>_0x46b18b['_isAttached'],this['_baseRoots']['set'](_0x536802,_0x46b18b),this['_baseRootsAttributes']['set'](_0x536802,_0x34bde5),_0x52a575&&this['_touchedRoots']['set'](_0x536802,_0x52a575);const _0x2f3b11=this['_makeIdsRoot'](_0x46b18b);this['_baseIdsRoots']['set'](_0x536802,_0x2f3b11);for(const [_0x371e77,_0x189649]of _0x46b18b['markers']){if(!_0x371e77['startsWith']('revision:'))continue;const _0x3025f3=_0x371e77['split'](':')[0x2];for(const _0x5aeeb0 of _0x189649['getWalker']({'singleCharacters':!0x0})){const _0x4e7677=this['_getVidAttributeName'](_0x5aeeb0),_0x4b0530='elementEnd'==_0x5aeeb0['type']?_0x5aeeb0['previousPosition']['path']['slice'](0x0,-0x1):_0x5aeeb0['previousPosition']['path'],_0x47891e=_0x2f3b11['getNodeByPath'](_0x4b0530)['getAttribute'](_0x4e7677);this['_touched']['set'](_0x47891e,{'userId':_0x3025f3});}}}this['_startingRevisionId']=this['_revisionId'];const _0x1c5b11=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x550209=>!this['_touched']['has'](_0x550209));let _0x4caaa0=0x0;const _0xe32d8c=new Map();for(const _0x31b42f in _0x2b164e['diffData']){const _0x2acf6a=_0x2b164e['diffData'][_0x31b42f]['attachChange'],_0x377500=_0x3a2169(_0x2b164e['diffData'][_0x31b42f]['attributesAfter'])||{},_0x38e107=_0x319306['_makeModelFromViewString'](_0x2b164e['diffData'][_0x31b42f]['insertions']);_0x38e107['rootName']=_0x31b42f,_0x38e107['_isAttached']=!_0x2acf6a||_0x2acf6a['isAttached'],_0x38e107['isAttached']=()=>_0x38e107['_isAttached'],this['_diffRoots']['set'](_0x31b42f,_0x38e107),this['_diffRootsAttributes']['set'](_0x31b42f,_0x377500);const _0x34a40e=this['_makeIdsRoot'](_0x38e107,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x31b42f,_0x34a40e),_0xe32d8c['set'](_0x31b42f,_0x38e107['isAttached']()?_0x377500:{});for(const [_0x579ea7,_0x23829e]of _0x38e107['markers']){if(!_0x579ea7['startsWith']('revision:'))continue;const _0x544189=_0x579ea7['split'](':')[0x2];for(const _0x475b13 of _0x23829e['getWalker']({'singleCharacters':!0x0})){const _0x2e6056=this['_getVidAttributeName'](_0x475b13),_0x3b6afe=this['_revisionId']++,_0x18c4c3='elementEnd'==_0x475b13['type']?_0x475b13['previousPosition']['path']['slice'](0x0,-0x1):_0x475b13['previousPosition']['path'];_0x34a40e['getNodeByPath'](_0x18c4c3)['_setAttribute'](_0x2e6056,_0x3b6afe),this['_touched']['set'](_0x3b6afe,{'userId':_0x544189});}}for(const _0x503a8b of this['editor']['model']['createRangeIn'](_0x38e107)['getWalker']({'singleCharacters':!0x0})){const _0x1fd300=this['_getVidAttributeName'](_0x503a8b),_0x4b3132='elementEnd'==_0x503a8b['type']?_0x503a8b['previousPosition']['path']['slice'](0x0,-0x1):_0x503a8b['previousPosition']['path'],_0x4fd2e8=_0x34a40e['getNodeByPath'](_0x4b3132);_0x4fd2e8['getAttribute'](_0x1fd300)>0x0||_0x4fd2e8['_setAttribute'](_0x1fd300,_0x1c5b11[_0x4caaa0++]);}for(const [_0x265d5b,_0x247a53]of _0x38e107['markers'])_0x265d5b['startsWith']('revision:')||this['_markers']['set'](_0x265d5b,_0x247a53);}const _0x2406d6=P('$graveyard');this['_baseRoots']['set']('$graveyard',_0x2406d6),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x2406d6,0x1));const _0x444fed=P('$graveyard');this['_diffRoots']['set']('$graveyard',_0x444fed),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x444fed,0x1));const _0x2b0147=Array['from'](this['_diffRoots'])['map'](([_0x226e01,_0x54f886])=>[_0x226e01,N(_0x54f886)]);this['_saveMetaData'](this['_lastTo'],_0x2b0147,this['_markers'],_0xe32d8c);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0x3686d0,_0x4697a5,_0x539d70,_0x4f183d){const _0x39cd55=new Map(_0x4697a5),_0x56e07e=new Map(_0x3a2169(_0x4f183d)),_0x43dbb6=new Map();for(const [_0x2d7cef,_0x3e1b10]of _0x539d70)_0x43dbb6['set'](_0x2d7cef,{'start':_0x3e1b10['start']['clone'](),'end':_0x3e1b10['end']['clone'](),'rootName':_0x3e1b10['root']['rootName']});this['_savedMetaData']['set'](_0x3686d0,{'roots':_0x39cd55,'markers':_0x43dbb6,'rootsAttributes':_0x56e07e});}['_removeMetaData'](_0x2a5d24){this['_savedMetaData']['delete'](_0x2a5d24);}['_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'](_0x49e2db,_0x2b6a5b=null){let _0x407c42=null;_0x49e2db['is']('documentFragment')||(_0x407c42=new ut(_0x49e2db['name'],{'vid_start':null===_0x2b6a5b?this['_revisionId']++:_0x2b6a5b++}));const _0x230f33=[];for(const _0x5b9592 of _0x49e2db['getChildren']())if(_0x5b9592['is']('element')){_0x230f33['push'](this['_makeIdsRoot'](_0x5b9592,_0x2b6a5b));const _0x175a1c=_0x230f33[_0x230f33['length']-0x1];null!==_0x2b6a5b&&(_0x2b6a5b=_0x175a1c['is']('element','$text')?_0x175a1c['getAttribute']('vid')+0x1:_0x175a1c['getAttribute']('vid_end')+0x1);}else{for(let _0x55f5d4=0x0;_0x55f5d4<_0x5b9592['offsetSize'];_0x55f5d4++)_0x230f33['push'](new ut('$text',{'vid':null===_0x2b6a5b?this['_revisionId']++:_0x2b6a5b++}));}if(_0x49e2db['is']('documentFragment')){const _0x50e285=P(_0x49e2db['rootName']);return _0x50e285['_insertChild'](0x0,_0x230f33),_0x50e285;}return _0x407c42['_setAttribute']('vid_end',null===_0x2b6a5b?this['_revisionId']++:_0x2b6a5b++),_0x407c42['_insertChild'](0x0,_0x230f33),_0x407c42;}['_calculateMetaData'](_0x457cdf,_0x111453,_0x210917){this['_reset']();const {roots:_0x118998,markers:_0x8a41bd,rootsAttributes:_0x4e2de3}=this['_savedMetaData']['get'](_0x457cdf);this['_baseRoots']=new Map(_0x118998),this['_baseRootsAttributes']=new Map(_0x3a2169(_0x4e2de3));for(const [_0x346cde,_0x506b32]of this['_baseRoots'])if('$graveyard'!==_0x346cde&&(this['_diffRoots']['set'](_0x346cde,N(_0x506b32)),this['_diffRootsAttributes']=new Map(_0x3a2169(_0x4e2de3)),_0x210917)){const _0x2b81c9=this['_revisionId'];this['_idsRoots']['set'](_0x346cde,this['_makeIdsRoot'](_0x506b32)),this['_baseIdsRoots']['set'](_0x346cde,this['_makeIdsRoot'](_0x506b32,_0x2b81c9));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',N(this['_baseRoots']['get']('$graveyard'))),_0x210917&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x4fdb17,_0x4de31b]of _0x8a41bd){const _0x22fb3a=this['_baseRoots']['get'](_0x4de31b['rootName']),_0x3327c1=this['_diffRoots']['get'](_0x4de31b['rootName']),_0x46fac4=new lt(this['_fixPosition'](_0x4de31b['start'],_0x22fb3a),this['_fixPosition'](_0x4de31b['end'],_0x22fb3a)),_0x51d222=this['_fixRange'](_0x46fac4,_0x3327c1);_0x22fb3a['markers']['set'](_0x4fdb17,_0x46fac4),this['_markers']['set'](_0x4fdb17,_0x51d222);}this['_applyOperations'](_0x457cdf,_0x111453,_0x210917);}['_applyOperations'](_0x21c7df,_0x26bf8a,_0x4b9a5f){for(const _0x1059d8 of this['source']['getOperations'](_0x21c7df,_0x26bf8a))this['_handleOperation'](_0x1059d8,_0x4b9a5f);for(const _0x182e61 of this['_diffRoots']['values']())_0x182e61['markers']['clear']();for(const [_0x25d37a,_0x1f389e]of this['_markers']){this['_diffRoots']['get'](_0x1f389e['root']['rootName'])['markers']['set'](_0x25d37a,_0x1f389e['clone']());}const _0x311b42=new Map(),_0x565731=new Map();for(const [_0x41650b,_0x1a0f65]of this['_diffRoots'])_0x311b42['set'](_0x41650b,N(_0x1a0f65)),_0x565731['set'](_0x41650b,this['_diffRootsAttributes']['get'](_0x41650b));this['_saveMetaData'](_0x26bf8a,_0x311b42,this['_markers'],_0x565731);}['_getPreviousFrom'](_0x1c7c70){const _0x466669=Array['from'](this['_savedMetaData']['keys']());_0x466669['sort']((_0x4ed0f1,_0x8676f9)=>_0x4ed0f1-_0x8676f9),_0x466669['reverse']();for(const _0x3bc995 of _0x466669)if(_0x3bc995<_0x1c7c70)return _0x3bc995;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x4ac190,_0x241d67){const _0x5a2d86=Array['from'](_0x241d67['markers'])['map'](([_0x58deef,_0x320c0a])=>[_0x58deef,this['_fixRange'](_0x320c0a,_0x4ac190)]);_0x4ac190['markers']=new Map(_0x5a2d86);}['_transformMarkers'](_0x491666){for(const _0x1e7fdd of this['_markers']['values']()){const _0x1852fe=_0x1e7fdd['getTransformedByOperation'](_0x491666),_0x3007bb=lt['_createFromRanges'](_0x1852fe);_0x1e7fdd['start']=_0x3007bb['start'],_0x1e7fdd['end']=_0x3007bb['end'];}}['_handleOperation'](_0x183426,_0x4898e1){if('addRoot'!=_0x183426['type']&&'detachRoot'!=_0x183426['type']){if('insert'==_0x183426['type']){const _0x5f0ef5=_0x183426['position']['root']['rootName'];this['_diffRoots']['has'](_0x5f0ef5)||(this['_diffRoots']['set'](_0x5f0ef5,P(_0x5f0ef5,!0x0)),this['_diffRootsAttributes']['set'](_0x5f0ef5,{}),_0x4898e1&&this['_idsRoots']['set'](_0x5f0ef5,P(_0x5f0ef5,!0x0)));}else{if('addRootAttribute'==_0x183426['type']||'removeRootAttribute'==_0x183426['type']||'changeRootAttribute'==_0x183426['type'])return void this['_handleRootAttributeOperation'](_0x183426);'marker'==_0x183426['type']&&this['_handleMarkerOperation'](_0x183426);}if('marker'!==_0x183426['type']){const _0x3a4cc6=this['_cloneOperation'](_0x183426,this['_diffRoots']);_0x3a4cc6['_execute'](),this['_transformMarkers'](_0x3a4cc6);}if(_0x4898e1)switch(_0x183426['type']){case'insert':this['_handleInsertOperation'](_0x183426);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x183426);break;case'merge':this['_handleMergeOperation'](_0x183426);break;case'split':this['_handleSplitOperation'](_0x183426);}}else this['_handleRootOperation'](_0x183426,_0x4898e1);}['_cloneOperation'](_0xa1e0f3,_0x14e46b){const _0x41c8b4=_0xa1e0f3['clone']();return _0x41c8b4['_authorId']=_0xa1e0f3['_authorId'],this['_fixOperation'](_0x41c8b4,_0x14e46b),_0x41c8b4;}['_getBaseVids'](_0x251a11){return _0x251a11['map'](_0x58b302=>{const _0x275afa=this['_getVidAttributeName'](_0x58b302);return Number(_0x58b302['item']['getAttribute'](_0x275afa));});}['_generateTape'](_0x29a52e,_0x477a27){if(_0x29a52e['is']('element','$text'))_0x477a27['push']({'item':_0x29a52e,'type':'text'});else{_0x29a52e['is']('element')&&_0x477a27['push']({'item':_0x29a52e,'type':'elementStart'});for(const _0x162811 of _0x29a52e['getChildren']())this['_generateTape'](_0x162811,_0x477a27);_0x29a52e['is']('element')&&_0x477a27['push']({'item':_0x29a52e,'type':'elementEnd'});}return _0x477a27;}['_getState'](){const _0x18379f=new Map(this['_touched']),_0x2317c1=new Map(_0x18379f),_0x19f272=new Map(),_0x52058c={'insertions':{},'deletions':{}},_0x7cf3f1={'insertions':{},'deletions':{}},_0x4ca1be=new Map(),_0x55b14c=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x55b14c['delete']('$graveyard');for(const _0x3a7661 of _0x55b14c){const _0xd41588=this['_diffRoots']['get'](_0x3a7661)||P(_0x3a7661,!0x1),_0x16b6ef=this['_baseRoots']['get'](_0x3a7661)||P(_0x3a7661,!0x1);_0xd41588['isAttached']()||_0x16b6ef['isAttached']()?(_0x52058c['insertions'][_0x3a7661]=N(_0xd41588),_0x52058c['deletions'][_0x3a7661]=N(_0x16b6ef),this['_copyMarkers'](_0x52058c['deletions'][_0x3a7661],_0x16b6ef),this['_copyMarkers'](_0x52058c['insertions'][_0x3a7661],_0xd41588),_0x7cf3f1['insertions'][_0x3a7661]=this['_generateTape'](this['_idsRoots']['get'](_0x3a7661),[]),_0x7cf3f1['deletions'][_0x3a7661]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x3a7661)||P(_0x3a7661,!0x1),[])):_0x55b14c['delete'](_0x3a7661);}for(const _0x4e3a65 of _0x55b14c){const _0x142738=_0x7cf3f1['insertions'][_0x4e3a65];for(const _0x54bece of _0x142738){const _0x42caa2=this['_getVidAttributeName'](_0x54bece),_0x382023=_0x54bece['item']['getAttribute'](_0x42caa2);_0x2317c1['delete'](_0x382023),_0x382023>=this['_startingRevisionId']&&_0x19f272['set'](_0x382023,_0x18379f['get'](_0x382023));}}for(const _0x47195f of _0x55b14c){const _0x1fff3f=_0x7cf3f1['insertions'][_0x47195f],_0x3408fb=this['_getBaseVids'](_0x7cf3f1['deletions'][_0x47195f]);let _0x2512af=0x0;for(const _0x11c836 of _0x1fff3f){const _0x5a8421=this['_getVidAttributeName'](_0x11c836),_0x4ba4c2=_0x11c836['item']['getAttribute'](_0x5a8421);if(!_0x19f272['has'](_0x4ba4c2)&&!_0x4ca1be['has'](_0x4ba4c2)){if(_0x2317c1['has'](_0x4ba4c2))_0x2512af++;else{if(_0x4ba4c2!=_0x3408fb[_0x2512af]){const _0x1c3228=_0x18379f['get'](_0x4ba4c2)||_0x18379f['get'](_0x3408fb[_0x2512af]);for(;_0x4ba4c2!=_0x3408fb[_0x2512af];)_0x2317c1['has'](_0x3408fb[_0x2512af])||(_0x4ca1be['set'](_0x3408fb[_0x2512af],_0x1c3228),_0x18379f['set'](_0x3408fb[_0x2512af],_0x1c3228)),_0x2512af++;}_0x2512af++;}}}}for(const _0x5b4ce2 of _0x55b14c){const _0xfa4451=_0x7cf3f1['insertions'][_0x5b4ce2];for(const _0x5422d6 of _0xfa4451){const _0x205479=this['_getVidAttributeName'](_0x5422d6),_0x4b82da=_0x5422d6['item']['getAttribute'](_0x205479);if(_0x4ca1be['has'](_0x4b82da)){const _0x211941=_0x4ca1be['get'](_0x4b82da);_0x2317c1['has'](_0x4b82da)||_0x2317c1['set'](_0x4b82da,{..._0x211941}),_0x19f272['set'](_0x4b82da,{..._0x211941});}}}for(const _0x38432c of _0x2317c1['keys']())_0x38432c>=this['_startingRevisionId']&&_0x2317c1['delete'](_0x38432c);const _0x3fafc5=new Map();for(const _0x558579 of _0x55b14c){let _0x67b65e=_0x7cf3f1['insertions'][_0x558579];for(const _0x3acb37 of _0x67b65e)if(_0x3acb37['item']['is']('element','tableCell')){const _0xecaee7=this['_getVidAttributeName'](_0x3acb37),_0x4789ec=_0x3acb37['item']['getAttribute'](_0xecaee7);if(_0x19f272['has'](_0x4789ec)){const _0x5d1724=_0x3acb37['item']['parent']['parent']['getAttribute']('vid_start'),_0x14f504=_0x3fafc5['get'](_0x5d1724)||new Set();_0x14f504['add'](_0x19f272['get'](_0x4789ec)['userId']),_0x3fafc5['set'](_0x5d1724,_0x14f504);}}_0x67b65e=_0x7cf3f1['deletions'][_0x558579];for(const _0x480fee of _0x67b65e)if(_0x480fee['item']['is']('element','tableCell')){const _0x3413f1=this['_getVidAttributeName'](_0x480fee),_0x535127=_0x480fee['item']['getAttribute'](_0x3413f1);if(_0x2317c1['has'](_0x535127)){const _0x275f81=_0x480fee['item']['parent']['parent']['getAttribute']('vid_start'),_0x1fdf54=_0x3fafc5['get'](_0x275f81)||new Set();_0x1fdf54['add'](_0x2317c1['get'](_0x535127)['userId']),_0x3fafc5['set'](_0x275f81,_0x1fdf54);}}for(const _0x225748 of _0x3fafc5['keys']())(_0x19f272['has'](_0x225748)||_0x2317c1['has'](_0x225748))&&_0x3fafc5['delete'](_0x225748);}for(const _0x41e32e of _0x55b14c){const _0x14045f=_0x7cf3f1['insertions'][_0x41e32e];let _0x5e58e4=null,_0x260402=null;for(const _0x12dae7 of _0x14045f){const _0x586fcd=this['_getVidAttributeName'](_0x12dae7),_0x377728=_0x12dae7['item']['getAttribute'](_0x586fcd),_0x590016=_0x3fafc5['get'](_0x377728);_0x590016&&'elementStart'==_0x12dae7['type']&&(_0x5e58e4=Array['from'](_0x590016)[0x0],_0x260402=_0x12dae7['item']['getAttribute']('vid_end')),_0x5e58e4&&(_0x2317c1['set'](_0x377728,{'userId':_0x5e58e4}),_0x19f272['set'](_0x377728,{'userId':_0x5e58e4})),_0x377728==_0x260402&&(_0x5e58e4=null,_0x260402=null);}}const _0x56a5eb={},_0x44aa4a=new Set();for(const _0x182262 of _0x55b14c){const _0xfca9eb=_0x52058c['deletions'][_0x182262],_0x22f56a=_0x52058c['insertions'][_0x182262];for(const {userId:_0x343790}of this['_touchedMarkers']['values']())null!==_0x343790&&_0x44aa4a['add'](_0x343790);for(const {userId:_0x16c5f0}of this['_touchedRoots']['values']())null!==_0x16c5f0&&_0x44aa4a['add'](_0x16c5f0);this['_markChanges'](_0x22f56a,_0x7cf3f1['insertions'][_0x182262],_0x19f272,'insertion',_0x44aa4a),this['_markChanges'](_0xfca9eb,_0x7cf3f1['deletions'][_0x182262],_0x2317c1,'deletion',_0x44aa4a),_0x56a5eb[_0x182262]={'insertions':this['_prepareViewToSave'](_0x22f56a),'deletions':this['_prepareViewToSave'](_0xfca9eb),'attachChange':this['_touchedRoots']['get'](_0x182262)||null,'attributesBefore':_0x3a2169(this['_baseRootsAttributes']['get'](_0x182262))||{},'attributesAfter':_0x3a2169(this['_diffRootsAttributes']['get'](_0x182262))};}return{'diffData':_0x56a5eb,'authorsIds':Array['from'](_0x44aa4a)};}['_processRootBeforeSave'](_0x2fa8f1){for(const [,_0x128144]of _0x2fa8f1['markers']){const _0x1c8080=_0x128144['start']['getAncestors']()['filter'](_0x16f0a2=>'tableCell'==_0x16f0a2['name']);for(const _0x5a1bee of _0x1c8080)0x1==_0x5a1bee['childCount']&&_0x5a1bee['getChild'](0x0)['is']('element','paragraph')&&_0x5a1bee['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x4f7935){this['_processRootBeforeSave'](_0x4f7935);const _0x43ebfc=this['editor']['data']['toView'](_0x4f7935,{}),_0x4a9283=Array['from'](_0x43ebfc['getChildren']())['map'](_0x39f85f=>this['_getViewJson'](_0x39f85f));return JSON['stringify'](_0x4a9283);}['_getViewJson'](_0x3f6968){if(_0x3f6968['is']('$text'))return _0x3f6968['data'];{const _0x3e2439=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0x2b12dd=_0x3f6968,_0x2de653=this['editor']['data']['htmlProcessor']['domConverter'],_0x262dbf={'type':_0x3e2439['_getTypeCharForViewElement'](_0x2b12dd),'name':_0x2b12dd['name'],'attributes':Array['from'](_0x2b12dd['getAttributes']()),'children':Array['from'](_0x2b12dd['getChildren']())['map'](_0x59ee86=>this['_getViewJson'](_0x59ee86))};if(_0x3f6968['is']('uiElement')&&'$comment'!=_0x3f6968['name']){const _0x30869c=_0x3f6968['render'](_0x2de653['domDocument'],_0x2de653);_0x262dbf['children']['push'](_0x30869c['outerHTML']);}else{if(_0x3f6968['is']('rawElement')){const _0x5105d1=_0x2de653['domDocument']['createElement'](_0x2b12dd['name']);_0x3f6968['render'](_0x5105d1,_0x2de653),_0x262dbf['children']['push'](_0x5105d1['innerHTML']);}}const _0x2c1f26=Array['from'](_0x2b12dd['getCustomProperties']());_0x2c1f26['length']>0x0&&(_0x262dbf['customProperties']=_0x2c1f26);const _0x3b7a78=_0x2b12dd['getFillerOffset']();return null!==_0x3b7a78&&(_0x262dbf['fillerOffset']=_0x3b7a78),_0x262dbf;}}['_markChanges'](_0x3e97b7,_0x56981c,_0x4a6ef3,_0x9057cb,_0x34fdf4){let _0x2a5748=null,_0xb30c8c=null,_0x4b7cf7=0x0;const _0x37065d=this['editor']['model'];for(let _0x49dfa1=0x0;_0x49dfa1<_0x56981c['length'];_0x49dfa1++){const _0x1c4d45=this['_getVidAttributeName'](_0x56981c[_0x49dfa1]),_0x2c28d0=_0x56981c[_0x49dfa1]['item']['getAttribute'](_0x1c4d45),_0x20c904=_0x4a6ef3['get'](_0x2c28d0),_0x24c505=_0x49dfa1==_0x56981c['length']-0x1;(!_0x2a5748&&_0x20c904&&(_0x2a5748=_0x20c904,_0xb30c8c=_0x56981c[_0x49dfa1]),_0x2a5748&&(!_0x20c904||_0x20c904['userId']!=_0x2a5748['userId']))&&(_0x280862(_0x20c904,F(_0xb30c8c,_0x3e97b7,_0x37065d),F(_0x56981c[_0x49dfa1],_0x3e97b7,_0x37065d)),_0x2a5748=_0x20c904||null,_0xb30c8c=_0x20c904?_0x56981c[_0x49dfa1]:null),_0x2a5748&&_0x24c505&&_0x280862(_0x20c904,F(_0xb30c8c,_0x3e97b7,_0x37065d),B(_0x56981c[_0x49dfa1],_0x3e97b7,_0x37065d));}function _0x280862(_0x47c93a,_0x38f900,_0x178edc){const _0x5c3743=_0x2a5748['userId'],_0x2b99bc='revision:'+_0x9057cb+':'+_0x5c3743+':'+_0x4b7cf7++,_0xa99a35=_0x37065d['createRange'](_0x38f900,_0x178edc);_0x3e97b7['markers']['set'](_0x2b99bc,_0xa99a35),null!==_0x5c3743&&_0x34fdf4['add'](_0x5c3743);}}['_getVidAttributeName'](_0x29a7c3){switch(_0x29a7c3['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x21e69b,_0x572543){_0x21e69b['baseVersion']=null;for(const _0x194e41 in _0x21e69b){const _0x258a11=_0x21e69b[_0x194e41];if(_0x258a11 instanceof ft){const _0xebf113=_0x572543['get'](_0x258a11['root']['rootName']);_0x21e69b[_0x194e41]=this['_fixPosition'](_0x258a11,_0xebf113);}if(_0x258a11 instanceof lt){const _0x39f939=_0x572543['get'](_0x258a11['root']['rootName']);_0x21e69b[_0x194e41]=this['_fixRange'](_0x258a11,_0x39f939);}'root'===_0x194e41&&(_0x21e69b['root']=_0x572543['get'](_0x21e69b['root']['rootName']));}}['_fixRange'](_0x5a7d02,_0xa7721c){return this['editor']['model']['createRange'](this['_fixPosition'](_0x5a7d02['start'],_0xa7721c),this['_fixPosition'](_0x5a7d02['end'],_0xa7721c));}['_fixPosition'](_0x1e2351,_0x5eb2a8){return this['editor']['model']['createPositionFromPath'](_0x5eb2a8,_0x1e2351['path'],_0x1e2351['stickiness']);}['_handleInsertOperation'](_0x1765ca){const _0x43aa0a=this['_idsRoots']['get'](_0x1765ca['position']['root']['rootName']),_0x389fc5=this['_fixPosition'](_0x1765ca['position'],_0x43aa0a),_0x19b710=null===_0x1765ca['_authorId']?null:_0x1765ca['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x334498=_0x389fc5['parent'],_0x4f7cca=this['_revisionId'],_0x3bd1c0=[];for(const _0x5bea77 of _0x1765ca['nodes'])if(_0x5bea77['is']('element'))_0x3bd1c0['push'](this['_makeIdsRoot'](_0x5bea77));else{for(let _0x4db5dc=0x0;_0x4db5dc<_0x5bea77['offsetSize'];_0x4db5dc++)_0x3bd1c0['push'](new ut('$text',{'vid':this['_revisionId']++}));}const _0x134d37=this['_revisionId'];for(let _0x1880b0=_0x4f7cca;_0x1880b0<_0x134d37;_0x1880b0++)this['_touched']['set'](_0x1880b0,{'userId':_0x19b710});_0x334498['_insertChild'](_0x389fc5['offset'],_0x3bd1c0);}['_handleMoveOperation'](_0x1e2b8c){(_0x1e2b8c=this['_cloneOperation'](_0x1e2b8c,this['_idsRoots']))['_execute']();const _0x1ae87a=null===_0x1e2b8c['_authorId']?null:_0x1e2b8c['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x36f67d=_0x1e2b8c['getMovedRangeStart'](),_0x2bb33f=_0x36f67d['parent'],_0x9e8b56=_0x36f67d['offset'];!function _0x49ff94(_0x440590,_0x44617b,_0x243c47,_0x1676f7){for(let _0xd19598=_0x243c47;_0xd19598<_0x1676f7;_0xd19598++){const _0x15f0fa=_0x44617b['getChild'](_0xd19598);_0x15f0fa['is']('element','$text')?_0x440590['set'](_0x15f0fa['getAttribute']('vid'),{'userId':_0x1ae87a}):(_0x440590['set'](_0x15f0fa['getAttribute']('vid_start'),{'userId':_0x1ae87a}),_0x49ff94(_0x440590,_0x15f0fa,0x0,_0x15f0fa['childCount']),_0x440590['set'](_0x15f0fa['getAttribute']('vid_end'),{'userId':_0x1ae87a}));}}(this['_touched'],_0x2bb33f,_0x9e8b56,_0x9e8b56+_0x1e2b8c['howMany']);}['_handleMergeOperation'](_0xf57cb7){const _0x4c90ce=null===(_0xf57cb7=this['_cloneOperation'](_0xf57cb7,this['_idsRoots']))['_authorId']?null:_0xf57cb7['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x45f18c=_0xf57cb7['targetPosition']['parent'],_0x159676=_0xf57cb7['sourcePosition']['parent'],_0x3c2f68=_0x45f18c['getAttribute']('vid_end'),_0x1745c0=_0x159676['getAttribute']('vid_start');_0x45f18c['_setAttribute']('vid_end',_0x159676['getAttribute']('vid_end')),_0x159676['_setAttribute']('vid_end',_0x3c2f68),this['_touched']['set'](_0x1745c0,{'userId':_0x4c90ce}),this['_touched']['set'](_0x3c2f68,{'userId':_0x4c90ce}),_0xf57cb7['_execute']();}['_handleSplitOperation'](_0x2ae6aa){const _0x2553a1=null===(_0x2ae6aa=this['_cloneOperation'](_0x2ae6aa,this['_idsRoots']))['_authorId']?null:_0x2ae6aa['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x3f9166=_0x2ae6aa['graveyardPosition'],_0x1b315d=_0x2ae6aa['splitPosition']['parent'];_0x2ae6aa['_execute']();const _0xa4c09b=_0x1b315d['getAttribute']('vid_end'),_0xc587df=_0x2ae6aa['insertionPosition']['nodeAfter'];if(_0x3f9166){const _0x2030b0=_0xc587df['getAttribute']('vid_end'),_0x54d97b=_0x1b315d['getAttribute']('vid_end');_0x1b315d['_setAttribute']('vid_end',_0x2030b0),_0xc587df['_setAttribute']('vid_end',_0x54d97b),this['_touched']['set'](_0x1b315d['getAttribute']('vid_end'),{'userId':_0x2553a1}),this['_touched']['set'](_0xc587df['getAttribute']('vid_start'),{'userId':_0x2553a1});}else{const _0x1f051a=this['_revisionId']++,_0x3df4aa=this['_revisionId']++;_0x1b315d['_setAttribute']('vid_end',_0x1f051a),_0xc587df['_setAttribute']('vid_start',_0x3df4aa),_0xc587df['_setAttribute']('vid_end',_0xa4c09b),this['_touched']['set'](_0x1f051a,{'userId':_0x2553a1}),this['_touched']['set'](_0x3df4aa,{'userId':_0x2553a1});}}['_handleMarkerOperation'](_0x2ca51c){if(!_0x2ca51c['affectsData'])return;const _0x1907f7=(_0x2ca51c=this['_cloneOperation'](_0x2ca51c,this['_diffRoots']))['oldRange']?_0x2ca51c['oldRange']['root']:null,_0x2de1e0=_0x2ca51c['newRange']?_0x2ca51c['newRange']['root']:null;_0x1907f7&&this['_markers']['delete'](_0x2ca51c['name']),_0x2de1e0&&this['_markers']['set'](_0x2ca51c['name'],_0x2ca51c['newRange']['clone']());const _0x47e724=null===_0x2ca51c['_authorId']?null:_0x2ca51c['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x26f9d2=_0x2ca51c['name'];if(!this['_touchedMarkers']['has'](_0x26f9d2))return void this['_touchedMarkers']['set'](_0x26f9d2,{'range':_0x2ca51c['oldRange'],'userId':_0x47e724});const _0x23ad3e=this['_touchedMarkers']['get'](_0x26f9d2),_0x3c0a58=_0x23ad3e['range'],_0x439360=_0x2ca51c['newRange'];null==_0x3c0a58&&null==_0x439360||_0x3c0a58&&_0x439360&&_0x3c0a58['isEqual'](_0x439360)?this['_touchedMarkers']['delete'](_0x2ca51c['name']):_0x23ad3e['userId']=_0x47e724;}['_handleRootOperation'](_0x39d36c,_0x45112e){this['_diffRoots']['has'](_0x39d36c['rootName'])?this['_diffRoots']['get'](_0x39d36c['rootName'])['_isAttached']=_0x39d36c['isAdd']:(this['_diffRoots']['set'](_0x39d36c['rootName'],P(_0x39d36c['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x39d36c['rootName'],{}),_0x45112e&&this['_idsRoots']['set'](_0x39d36c['rootName'],P(_0x39d36c['rootName'],!0x0)));const _0x506a10=null===_0x39d36c['_authorId']?null:_0x39d36c['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x145d8b=this['_touchedRoots']['get'](_0x39d36c['rootName']);_0x145d8b&&_0x145d8b['userId']===_0x506a10?this['_touchedRoots']['delete'](_0x39d36c['rootName']):this['_touchedRoots']['set'](_0x39d36c['rootName'],{'userId':_0x506a10,'isAttached':_0x39d36c['isAdd']});}['_handleRootAttributeOperation'](_0x1f1084){const _0x10cef3=this['_diffRootsAttributes']['get'](_0x1f1084['root']['rootName']);null===_0x1f1084['newValue']?delete _0x10cef3[_0x1f1084['key']]:_0x10cef3[_0x1f1084['key']]=_0x1f1084['newValue'];}}function N(_0x35f662){const _0x1abcce=P(_0x35f662['rootName'],_0x35f662['isAttached']());for(const _0x2b2f3d of _0x35f662['getChildren']()){const _0x48ddcc=_0x2b2f3d['_clone'](!0x0);_0x1abcce['_appendChild'](_0x48ddcc);}return _0x1abcce;}function P(_0x65c46e,_0x1056bf=!0x0){const _0x5801db=new vt();return _0x5801db['rootName']=_0x65c46e,_0x5801db['_isAttached']=_0x1056bf,_0x5801db['isAttached']=()=>_0x5801db['_isAttached'],_0x5801db;}function F(_0x598ea2,_0x34f147,_0xd38c4b){const _0xa55e27='elementEnd'==_0x598ea2['type']?_0xd38c4b['createPositionAt'](_0x598ea2['item'],'end'):_0xd38c4b['createPositionBefore'](_0x598ea2['item']);return _0xd38c4b['createPositionFromPath'](_0x34f147,_0xa55e27['path'],_0xa55e27['stickiness']);}function B(_0x181d6b,_0x24f84,_0x2fbdb4){const _0x1c215f='elementStart'==_0x181d6b['type']?_0x2fbdb4['createPositionAt'](_0x181d6b['item'],0x0):_0x2fbdb4['createPositionAfter'](_0x181d6b['item']);return _0x2fbdb4['createPositionFromPath'](_0x24f84,_0x1c215f['path'],_0x1c215f['stickiness']);}class hs extends ts{['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0xe2f767,_0x319ab9){super(_0xe2f767),this['focusTracker']=new _0x4ecfb8(),this['keystrokes']=new _0x52968a(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x319ab9),this['setTemplate']({'tag':'form','attributes':{'class':['ck','ck-revision-history-save-revision-form','ck-responsive-form'],'tabindex':'-1'},'children':[this['revisionNameInputView']]}),_0xdfa429(this);}['render'](){super['render'](),_0xb211c2({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x3acd8d=_0x5b58f1=>_0x5b58f1['stopPropagation']();this['keystrokes']['set']('arrowright',_0x3acd8d),this['keystrokes']['set']('arrowleft',_0x3acd8d),this['keystrokes']['set']('arrowup',_0x3acd8d),this['keystrokes']['set']('arrowdown',_0x3acd8d);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x1f1532){this['revisionNameInputView']['fieldView']['element']['value']=_0x1f1532['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x5695c6){const _0x3afdc2=new _0x370644(this['locale'],_0x342059),_0x1fdec7=_0x3afdc2['fieldView'];_0x1fdec7['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x35425b=g(this['locale'],'Name\x20of\x20the\x20revision');return!_0x5695c6&&(_0x35425b+='\x20('+g(this['locale'],'optional')+')'),(_0x3afdc2['label']=_0x35425b,_0x1fdec7['on']('input',()=>{this['revisionNameInputValue']=_0x1fdec7['element']['value']['trim']();}),_0x3afdc2);}}class f extends _0x2a63bd{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u];}['_saveRevisionFormView'];['init'](){const _0x4969ea=this['editor'],_0x586a39=_0x4969ea['plugins']['get']('RevisionTracker');_0x4969ea['ui']['componentFactory']['add']('revisionHistory',_0x53fee5=>{const _0x1dae0c=_0x146e16(_0x53fee5),_0x4f9584=_0x1dae0c['panelView']['children'],_0x94fc59=new _0x176c2f(_0x53fee5),_0x409661=new _0x12bd81(_0x53fee5),_0x3d96c8=new te(_0x53fee5),_0x16983b=new _0x12bd81(_0x53fee5),_0x3d2edd=new te(_0x53fee5);return _0x1dae0c['bind']('isEnabled')['to'](_0x586a39,'isReady',_0x586a39,'isEnabled',_0x4969ea,'isReadOnly',(_0x428949,_0x2929c4,_0x2c1fd2)=>_0x428949&&_0x2929c4&&!_0x2c1fd2),_0x1dae0c['buttonView']['set']({'icon':_0x3e3e17,'label':g(_0x53fee5,'Revision\x20history'),'tooltip':!0x0}),_0x3d96c8['set']({'label':g(_0x53fee5,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x3d96c8['bind']('isEnabled')['to'](_0x586a39,'isReady',_0x586a39,'isEnabled',_0x4969ea,'isReadOnly',(_0x51eb6f,_0x44411b,_0xa4f85e)=>_0x51eb6f&&_0x44411b&&!_0xa4f85e),_0x3d96c8['on']('execute',()=>this['_showDialog']()),_0x3d2edd['set']({'label':g(_0x53fee5,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x3d2edd['bind']('isEnabled')['to'](_0x586a39,'isReady',_0x4969ea,'isReadOnly',(_0x47e106,_0x55d0a0)=>_0x47e106&&!_0x55d0a0),_0x3d2edd['on']('execute',()=>{_0x4969ea['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x1dae0c['isOpen']=!0x1,_0x4969ea['editing']['view']['focus']();}),_0x409661['children']['add'](_0x3d96c8),_0x16983b['children']['add'](_0x3d2edd),_0x94fc59['role']='menu',_0x94fc59['items']['addMany']([_0x409661,_0x16983b]),_0x4f9584['add'](_0x94fc59),_0x1dae0c;}),_0x4969ea['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0xd41a02=this['editor'],_0x34dd36=_0xd41a02['locale'],_0x23d4a2=new _0x2204e8(_0x34dd36),_0x34d231=new _0x203e50(_0x34dd36);_0x23d4a2['buttonView']['set']({'icon':_0x3e3e17,'label':g(_0x34dd36,'Revision\x20history')});const _0x44d102=new _0x588799(_0x34dd36,_0x23d4a2),_0x47fc8e=new _0x59fdc2(_0x34dd36);_0x47fc8e['set']({'label':g(_0x34dd36,'Save\x20current\x20revision')}),_0x47fc8e['delegate']('execute')['to'](_0x23d4a2),_0x47fc8e['on']('execute',()=>{this['_showDialog']();}),_0x44d102['children']['add'](_0x47fc8e),_0x34d231['items']['add'](_0x44d102);const _0x39bbb1=new _0x588799(_0x34dd36,_0x23d4a2),_0x2ef9bc=new _0x59fdc2(_0x34dd36);return _0x2ef9bc['set']({'label':g(_0x34dd36,'Open\x20revision\x20history')}),_0x2ef9bc['delegate']('execute')['to'](_0x23d4a2),_0x2ef9bc['on']('execute',()=>{_0xd41a02['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x39bbb1['children']['add'](_0x2ef9bc),_0x34d231['items']['add'](_0x39bbb1),_0x23d4a2['panelView']['children']['add'](_0x34d231),_0x23d4a2;}['_showDialog'](){const _0x5d95d6=this['editor'],_0x1e6fb2=_0x5d95d6['locale'],_0x222b6b=_0x5d95d6['plugins']['get']('Dialog'),_0x43149c=_0x5d95d6['plugins']['get']('RevisionTracker');function _0x4f7bcf(_0x3d04ab){_0x5d95d6['config']['get']('revisionHistory.requireRevisionName')&&''===_0x3d04ab['revisionName']?_0x3d04ab['revisionNameInputView']['errorText']=g(_0x1e6fb2,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x5d95d6['plugins']['get'](u)['saveRevision']({'name':_0x3d04ab['revisionName']}),_0x222b6b['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x4f7bcf(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x222b6b['show']({'id':'revisionSave','title':g(_0x1e6fb2,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':g(_0x5d95d6['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x222b6b['hide']()},{'label':g(_0x5d95d6['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x26bc2f){_0x26bc2f['bind']('isEnabled')['to'](_0x43149c,'isReady',_0x43149c,'isEnabled',_0x5d95d6,'isReadOnly',(_0x4465b3,_0x401ba9,_0x5ef50d)=>_0x4465b3&&_0x401ba9&&!_0x5ef50d);},'onExecute':()=>_0x4f7bcf(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x122fc2=this['editor'],_0x15e1a6=_0x122fc2['locale'];this['_saveRevisionFormView']=new hs(_0x15e1a6,_0x122fc2['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class Q extends ts{['changeId'];['_model'];constructor(_0x1aa482,_0xa3ed1f){super(_0x1aa482),this['_model']=_0xa3ed1f,this['changeId']=_0xa3ed1f['id'];const _0x5dac60=this['bindTemplate'],_0x13f1a0=g(_0x1aa482,_0xa3ed1f['data']['isSuggestion']?'Suggested\x20by':'add'==_0xa3ed1f['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0xa3ed1f['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x5dac60['to']('type',_0x228a5c=>'ck-revision-change__'+_0x228a5c)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x13f1a0}]},{'text':'\x20'+_0xa3ed1f['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class r extends/* #__PURE__ -- @preserve */
25
- _0xaad3d0(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x39df36){super(),this['id']=_0x39df36['id']||_0x5ca89b(),this['author']=_0x39df36['author'],this['type']=_0x39df36['type'],this['data']=_0x39df36['data']||{},this['rootName']=_0x39df36['rootName'],this['set']('createdAt',_0x39df36['createdAt']);}['toJSON'](){return{'id':this['id'],'authorId':this['author']['id'],'type':this['type'],'data':this['data'],'createdAt':this['createdAt']};}}class c{['newRevisionId'];['oldRevisionId'];['changes'];constructor(_0x3c1c49,_0x52ec0d){this['newRevisionId']=_0x3c1c49,this['oldRevisionId']=_0x52ec0d,this['changes']=new _0x90db85();}['_setChanges'](_0x478165){for(const _0x151955 of _0x478165)this['changes']['add'](_0x151955);}}class m extends _0x2a63bd{['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[_0x25042d,_0x810963,I,V];}constructor(_0x1f2549){super(_0x1f2549),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',(_0x1b3ad5,_0x1b2550,_0x52737a)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x38c66d=>{for(const _0x4b3691 of this['editor']['editing']['view']['document']['roots'])_0x52737a?_0x38c66d['removeClass']('ck-editor__editable__overlay',_0x4b3691):_0x38c66d['addClass']('ck-editor__editable__overlay',_0x4b3691);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x4fb846=>null!==_0x4fb846),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x36aa31,_0x319b61,_0x465b3f)=>_0x36aa31&&_0x465b3f?_0x319b61['changes']['getIndex'](_0x465b3f):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x5ae20f,_0x5149da)=>_0x5ae20f?_0x5149da['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0x810963);}['init'](){const _0x9ae0d2=this['editor'],_0x227d1f=new wt(_0x9ae0d2,{'direction':'backward'}),_0x4c8685=new wt(_0x9ae0d2,{'direction':'forward'});(_0x9ae0d2['commands']['add']('showPreviousChange',_0x227d1f),_0x9ae0d2['commands']['add']('showNextChange',_0x4c8685),_0x9ae0d2['commands']['add']('restoreRevision',new mt(_0x9ae0d2)),this['on']('change:numberOfChanges',()=>{_0x227d1f['refresh'](),_0x4c8685['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x9ae0d2['enableReadOnlyMode']('revision-viewer'),_0x9ae0d2['plugins']['has']('WidgetToolbarRepository'))&&_0x9ae0d2['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x22894e){return await this['_utils']['loadRevisionData'](_0x22894e,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x22894e);}async['getRevisionRootsAttributes'](_0x594719){return await this['_utils']['loadRevisionData'](_0x594719,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x594719);}async['compare'](_0xc7b2ad,_0x48cb08,_0x273cbd=!0x1){if(!this['isEnabled'])return;const _0x339482=this['diff'],_0x1bb1e7=this['repository'],_0x188d95='string'==typeof _0xc7b2ad?_0x1bb1e7['getRevision'](_0xc7b2ad):_0xc7b2ad,_0x4dfa28='string'==typeof _0x48cb08?_0x1bb1e7['getRevision'](_0x48cb08):_0x48cb08,_0x17f5bc=_0x188d95['id'],_0x5216ac=_0x4dfa28?_0x4dfa28['id']:null;if(!_0x273cbd&&this['diff']&&this['diff']['newRevisionId']===_0x17f5bc&&this['diff']['oldRevisionId']===_0x5216ac)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new c(_0x17f5bc,_0x5216ac);const _0x2e2901=this['_getRevisionsRange'](_0x188d95,_0x4dfa28,!0x0)['map'](_0x5841f7=>this['_utils']['loadRevisionData'](_0x5841f7,this['adapter']));return _0x2e2901['push'](new Promise(_0x4ad914=>{setTimeout(_0x4ad914,0x14);})),Promise['all'](_0x2e2901)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x577371=this['_getDiff'](_0x17f5bc,_0x5216ac);for(const _0x2effd3 of _0x577371['changes'])this['_changeIdToChange']['set'](_0x2effd3['id'],_0x2effd3);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x589a1c=>{for(const _0x3a409f of this['editor']['model']['document']['getRootNames']())_0x589a1c['detachRoot'](_0x3a409f);for(const _0x534f5f of Object['keys'](_0x577371['model'])){const _0x41e537=_0x589a1c['addRoot'](_0x534f5f);for(const _0x5ed506 of Object['keys'](_0x577371['attributes'][_0x534f5f]))_0x589a1c['setAttribute'](_0x5ed506,_0x577371['attributes'][_0x534f5f][_0x5ed506],_0x41e537);_0x589a1c['insert'](_0x577371['model'][_0x534f5f],_0x41e537,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x577371['changes'])),this['isReady']=!0x0;})['catch'](_0x5347a1=>{console['error'](_0x5347a1),this['_cleanUp'](),_0x339482&&(this['diff']=_0x339482),this['isReady']=!0x0;});}['addRevisionData'](_0x22a1ef,_0x46537f){const _0x2d4578=this['repository']['createRevision'](_0x22a1ef);return _0x2d4578['on']('_update',(_0x6a3c9,_0x1b86df,_0x1399c8)=>_0x46537f(_0x1b86df,_0x1399c8,_0x2d4578)),this['repository']['addRevision'](_0x2d4578),_0x2d4578;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x42b418=>{for(const _0x286685 of this['editor']['model']['document']['getRootNames']())_0x42b418['detachRoot'](_0x286685);});}['_sortAndFilterDiffChanges'](_0x17ef3b){const _0x4b465b=[],_0x505020=new Map();for(const _0x6164f1 of this['editor']['model']['document']['getRootNames']()){const _0x401fc8=this['editor']['editing']['view']['getDomRoot'](_0x6164f1);if(!_0x401fc8)continue;const _0x413b72=_0x401fc8['getClientRects']()['item'](0x0);_0x413b72&&(_0x4b465b['push'](_0x6164f1),_0x505020['set'](_0x6164f1,_0x413b72));}return _0x4b465b['sort']((_0x2d95da,_0x1711fd)=>{const _0x18e43f=_0x505020['get'](_0x2d95da),_0x351ae7=_0x505020['get'](_0x1711fd);return _0x18e43f['y']-_0x351ae7['y']||_0x18e43f['x']-_0x351ae7['x'];}),(_0x17ef3b=_0x17ef3b['filter'](_0x56d3ae=>_0x4b465b['includes'](_0x56d3ae['rootName'])))['sort']((_0x435507,_0xdab53a)=>_0x4b465b['indexOf'](_0x435507['rootName'])-_0x4b465b['indexOf'](_0xdab53a['rootName'])),_0x17ef3b;}['_makeTape'](_0xdc7fc9){const _0x268d2c=Array['from'](_0xdc7fc9['markers'])['filter'](([_0x1c3042,_0x10beaa])=>_0x1c3042['startsWith']('revision:')&&!_0x10beaa['isCollapsed']),_0x5520c8=Array['from'](this['editor']['model']['createRangeIn'](_0xdc7fc9)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x268d2c['length'])for(const _0x5a2ea2 of _0x5520c8){const [_0x5a08ef,_0x1f0702]=_0x268d2c[0x0],[,_0x316b2a,_0x1b21f8]=_0x5a08ef['split'](':');if(_0x1f0702['end']['isEqual'](_0x5a2ea2['nextPosition'])&&_0x268d2c['shift'](),(_0x5a2ea2['previousPosition']['isEqual'](_0x1f0702['start'])||_0x5a2ea2['previousPosition']['isAfter'](_0x1f0702['start']))&&('insertion'==_0x316b2a?_0x5a2ea2['isAdded']={'userId':_0x1b21f8}:'deletion'==_0x316b2a&&(_0x5a2ea2['isRemoved']={'userId':_0x1b21f8})),0x0==_0x268d2c['length'])break;}return _0x5520c8;}['_refreshStartEndIndex'](_0x440bf2){const _0x335b93=new Map();for(let _0x7973e8=0x0;_0x7973e8<_0x440bf2['length'];_0x7973e8++)'text'===_0x440bf2[_0x7973e8]['type']?(_0x440bf2[_0x7973e8]['item']['startIndex']=_0x7973e8,_0x440bf2[_0x7973e8]['item']['endIndex']=_0x7973e8):('elementStart'===_0x440bf2[_0x7973e8]['type']?_0x440bf2[_0x7973e8]['item']['startIndex']=_0x7973e8:'elementEnd'===_0x440bf2[_0x7973e8]['type']&&(_0x440bf2[_0x7973e8]['item']['endIndex']=_0x7973e8),_0x335b93['set'](_0x440bf2[_0x7973e8]['id'],_0x7973e8));for(const _0x19c8af of _0x335b93['values']())'elementStart'===_0x440bf2[_0x19c8af]['type']?_0x440bf2[_0x19c8af]['item']['endIndex']=_0x335b93['get'](_0x440bf2[_0x19c8af]['pairId']):'elementEnd'===_0x440bf2[_0x19c8af]['type']&&(_0x440bf2[_0x19c8af]['item']['startIndex']=_0x335b93['get'](_0x440bf2[_0x19c8af]['pairId']));}['_processTape'](_0x804dc){for(let _0x373c10=0x0;_0x373c10<_0x804dc['length'];_0x373c10++){if('elementStart'===_0x804dc[_0x373c10]['type'])_0x804dc[_0x373c10]['item']['startIndex']=_0x373c10;else{if('elementEnd'===_0x804dc[_0x373c10]['type']){_0x804dc[_0x373c10]['item']['endIndex']=_0x373c10;const _0x52e685=_0x804dc[_0x373c10]['item']['startIndex'];_0x804dc[_0x52e685]['pairId']=_0x804dc[_0x373c10]['id'],_0x804dc[_0x373c10]['pairId']=_0x804dc[_0x52e685]['id'];}else _0x804dc[_0x373c10]['item']['startIndex']=_0x373c10,_0x804dc[_0x373c10]['item']['endIndex']=_0x373c10,_0x804dc[_0x373c10]['pairId']=null;}_0x804dc[_0x373c10]['markersStart']||(_0x804dc[_0x373c10]['markersStart']=[],_0x804dc[_0x373c10]['markersEnd']=[]);}}['_markInsertions'](_0x2723ba,_0x29e1de){const _0x3416d2=_0x2723ba['filter'](_0x509273=>!_0x509273['isAdded']);for(let _0x49330d=0x0;_0x49330d<_0x29e1de['length'];_0x49330d++)_0x29e1de[_0x49330d]['isAdded']&&(_0x3416d2[_0x49330d]['isAdded']=_0x29e1de[_0x49330d]['isAdded']);}['_getDiff'](_0x197954,_0x1e8c81=null){const _0x405923=this['repository']['getRevision'](_0x197954),_0x5780bc=_0x1e8c81?this['repository']['getRevision'](_0x1e8c81):null,_0x124787=this['_getRevisionsRange'](_0x405923,_0x5780bc),_0xc88fb3=_0x124787[_0x124787['length']-0x1],_0x2be45d=new Map(),_0x2a45be={'model':{},'attributes':{},'changes':[]},_0xd81f0b=new Set(),_0x17e982=new Map();for(let _0x57ba94=_0x124787['length']-0x1;_0x57ba94>=0x0;_0x57ba94--){const _0x287978=_0x124787[_0x57ba94];for(const _0x405198 of Object['keys'](_0x287978['diffData']))if(_0x287978['diffData'][_0x405198]['attachChange']){const _0x21b1af=_0x287978['diffData'][_0x405198]['attachChange'];_0x21b1af['isAttached']?(_0xd81f0b['add'](_0x405198),_0x17e982['has'](_0x405198)&&_0x17e982['get'](_0x405198)['userId']==_0x21b1af['userId']?_0x17e982['delete'](_0x405198):_0x17e982['set'](_0x405198,_0x21b1af)):_0x17e982['has'](_0x405198)?(_0xd81f0b['delete'](_0x405198),_0x17e982['delete'](_0x405198)):(_0xd81f0b['add'](_0x405198),_0x17e982['set'](_0x405198,_0x21b1af));}else _0xd81f0b['add'](_0x405198);}for(const _0x2293be of _0xd81f0b){const _0x16b43f=_0x17e982['has'](_0x2293be)&&!_0x17e982['get'](_0x2293be)['isAttached'];let _0x2b3b8b=_0x16b43f?_0x124787['length']-0x1:0x0;const _0x4be916=_0x16b43f?-0x1:0x1;for(;_0x124787[_0x2b3b8b];){const _0x241da6=_0x124787[_0x2b3b8b];if(_0x241da6['diffData'][_0x2293be]){const _0x340b3b=_0x16b43f?_0x241da6['diffData'][_0x2293be]['attributesBefore']:_0x241da6['diffData'][_0x2293be]['attributesAfter'];_0x2a45be['attributes'][_0x2293be]=_0x340b3b?_0x3a2169(_0x340b3b):{};break;}_0x2b3b8b+=_0x4be916;}}for(const _0x3521b9 of _0x124787){_0x3521b9['model']={};for(const _0x2254ba of _0x3521b9['authors'])_0x2be45d['set'](_0x2254ba['id'],_0x2254ba);for(const _0x4c9831 of _0xd81f0b){const _0x374fe1=_0x3521b9['diffData'][_0x4c9831]?_0x3521b9['diffData'][_0x4c9831]['insertions']:'[]',_0x113f83=_0x3521b9['diffData'][_0x4c9831]?_0x3521b9['diffData'][_0x4c9831]['deletions']:'[]';_0x3521b9['model'][_0x4c9831]={'insertions':this['_utils']['_makeModelFromViewString'](_0x374fe1),'deletions':this['_utils']['_makeModelFromViewString'](_0x113f83)};}}for(const _0x28a685 of _0xd81f0b){let _0x48ac04=null,_0x2f979e=0x0;const _0x14a913=new Map(Array['from'](_0x405923['model'][_0x28a685]['insertions']['markers'])['filter'](([_0x2a101b])=>!_0x2a101b['startsWith']('revision:')));let _0x25ae26=0x0;for(const _0x165823 of _0x124787){const _0x14f35a=this['_makeTape'](_0x165823['model'][_0x28a685]['insertions']);_0x165823==_0x405923?(_0x48ac04=_0x14f35a,_0x2f979e=_0x48ac04['length'],_0x48ac04['forEach'](_0x33501b=>{_0x33501b['id']=_0x25ae26++;}),this['_processTape'](_0x48ac04)):this['_markInsertions'](_0x48ac04,_0x14f35a);const _0x5e7282=_0x48ac04['filter'](_0x5dab15=>!_0x5dab15['isAdded'])['map'](_0x22fd46=>_0x22fd46['id']);let _0x33eeb9=0x0;const _0x5d39f8=this['_makeTape'](_0x165823['model'][_0x28a685]['deletions']);_0x5d39f8['forEach'](_0x2588eb=>{_0x2588eb['isRemoved']?_0x2588eb['id']=_0x2f979e++:_0x2588eb['id']=_0x5e7282[_0x33eeb9++];}),this['_processTape'](_0x5d39f8),this['_setDistance'](_0x48ac04,'isAdded'),this['_setDistance'](_0x5d39f8,'isRemoved'),_0x165823==_0x405923&&this['_markMarkers'](_0x48ac04,_0x14a913),_0x48ac04=this['_joinTapes'](_0x48ac04,_0x5d39f8),this['_refreshStartEndIndex'](_0x48ac04),this['_setDistance'](_0x48ac04,'isRemoved');}_0x48ac04=_0x48ac04['filter'](_0x4554cc=>!(_0x4554cc['isAdded']&&_0x4554cc['isRemoved']));const _0x20f732=new Map(_0xc88fb3['model'][_0x28a685]['deletions']['markers']),_0x13c700=new Set(_0x14a913['keys']());for(const _0x8bf92e of _0x20f732['keys']())_0x13c700['delete'](_0x8bf92e);this['_markSuggestions'](_0x48ac04,_0x13c700),this['_fixObsoleteTags'](_0x48ac04),_0x48ac04=this['_removeMissingPairs'](_0x48ac04),_0x48ac04=this['_markMismatchedRemovedTags'](_0x48ac04),_0x48ac04=this['_removeUnsupportedChanges'](_0x48ac04);const {root:_0xf679c9,changes:_0x1fcc74}=this['_makeModelFromTape'](_0x48ac04,_0x2be45d,_0x28a685);_0x2a45be['model'][_0x28a685]=_0xf679c9;const _0x542042=_0x17e982['get'](_0x28a685);if(_0x542042){const _0x4b547a=_0x2be45d['get'](_0x542042['userId']),_0xf522e9=new r({'author':_0x4b547a,'type':_0x542042['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x28a685});_0x1fcc74['unshift'](_0xf522e9),_0x2a45be['attributes'][_0x28a685]['revisionHistoryAttachChange']=_0xf522e9['id'];}_0x2a45be['changes']=_0x2a45be['changes']['concat'](_0x1fcc74);}return _0x2a45be;}['_markMarkers'](_0x23ab39,_0x5988be){for(let _0x4ccda9=0x0;_0x4ccda9<_0x23ab39['length'];_0x4ccda9++)for(const [_0x47da5f,_0x236891]of _0x5988be)!_0x236891['isCollapsed']&&_0x236891['start']['isEqual'](_0x23ab39[_0x4ccda9]['previousPosition'])&&_0x23ab39[_0x4ccda9]['markersStart']['push'](_0x47da5f),_0x236891['end']['isEqual'](_0x23ab39[_0x4ccda9]['nextPosition'])&&_0x23ab39[_0x4ccda9]['markersEnd']['push'](_0x47da5f);}['_joinTapes'](_0x2e3191,_0x4fa8a6){let _0x381991=[],_0x23e257=0x0,_0x19a631=0x0;for(;_0x23e257<_0x2e3191['length']||_0x19a631<_0x4fa8a6['length'];){const _0xcce79d=_0x2e3191[_0x23e257]||{},_0x4f75ce=_0x4fa8a6[_0x19a631]||{};if(_0xcce79d['id']==_0x4f75ce['id'])_0x23e257++,_0x19a631++,_0x381991['push'](_0xcce79d);else{if(_0x4f75ce['isRemoved']&&_0xcce79d['isAdded']){const {commonTape:_0x2d8c67,iEnd:_0x20bbfb,jEnd:_0x1b6adf}=this['_threeWayMerge'](_0x2e3191,_0x23e257,_0x4fa8a6,_0x19a631);_0x381991=_0x381991['concat'](_0x2d8c67),_0x23e257=_0x20bbfb,_0x19a631=_0x1b6adf;}else _0x4f75ce['isRemoved']?(_0x19a631++,_0x381991['push'](_0x4f75ce)):(_0x23e257++,_0x381991['push'](_0xcce79d));}}return _0x381991;}['_markSuggestions'](_0x33c475,_0x1c69c1){const _0x5a04ea=[];for(let _0x2d45ca=0x0;_0x2d45ca<_0x33c475['length'];_0x2d45ca++){for(let _0xe3cbc1=0x0;_0xe3cbc1<_0x33c475[_0x2d45ca]['markersStart']['length'];_0xe3cbc1++){const _0x2f7526=_0x33c475[_0x2d45ca]['markersStart'][_0xe3cbc1];if(!_0x1c69c1['has'](_0x2f7526))continue;const {group:_0xe70000,type:_0x3563d6,authorId:_0x3d6900}=_0x4261a2(_0x2f7526);'revision-suggestion'!=_0xe70000||'insertion'!=_0x3563d6&&'deletion'!=_0x3563d6||(_0x5a04ea['unshift']({'type':_0x3563d6,'name':_0x2f7526,'userId':_0x3d6900}),_0x33c475[_0x2d45ca]['markersStart']['splice'](_0xe3cbc1,0x1),_0xe3cbc1--);}_0x391641(_0x33c475[_0x2d45ca]);for(let _0x4d9ee5=0x0;_0x4d9ee5<_0x33c475[_0x2d45ca]['markersEnd']['length'];_0x4d9ee5++){const _0x156f9d=_0x33c475[_0x2d45ca]['markersEnd'][_0x4d9ee5];if(!_0x1c69c1['has'](_0x156f9d))continue;const {group:_0x567251,type:_0x56bf18}=_0x4261a2(_0x156f9d);if('revision-suggestion'!=_0x567251||'insertion'!=_0x56bf18&&'deletion'!=_0x56bf18)continue;_0x33c475[_0x2d45ca]['markersEnd']['splice'](_0x4d9ee5,0x1),_0x4d9ee5--;const _0x2854b7=_0x5a04ea['findIndex'](_0x1a28ee=>_0x1a28ee['name']==_0x156f9d);_0x2854b7>-0x1&&_0x5a04ea['splice'](_0x2854b7,0x1);}}function _0x4261a2(_0x82d045){const _0x4a03da=_0x82d045['split'](':');return{'group':_0x4a03da[0x0],'type':_0x4a03da[0x1],'subType':_0x4a03da['length']>=0x5?_0x4a03da[0x2]:null,'id':_0x4a03da['length']<0x5?_0x4a03da[0x2]:_0x4a03da[0x3],'authorId':_0x4a03da['length']<0x5?_0x4a03da[0x3]:_0x4a03da[0x4],'markerCount':0x6==_0x4a03da['length']?_0x4a03da[0x5]:null};}function _0x391641(_0x794267){for(let _0x47edd8=0x0;_0x47edd8<_0x5a04ea['length'];_0x47edd8++){if(_0x794267['isAdded']&&'insertion'==_0x5a04ea[_0x47edd8]['type'])return _0x794267['isAddSuggestion']=_0x5a04ea[_0x47edd8],void delete _0x794267['isAdded'];if(!_0x794267['isAdded']&&!_0x794267['isRemoved']&&'deletion'==_0x5a04ea[_0x47edd8]['type'])return void(_0x794267['isRemoveSuggestion']=_0x5a04ea[_0x47edd8]);}}}['_setDistance'](_0x280abd,_0x1940e9){let _0x1b5c85=0x0,_0x231953=!0x1;const _0x3d6ffb=new Map();for(const _0x4fa28d of _0x280abd)_0x4fa28d[_0x1940e9]?_0x231953&&(_0x1b5c85++,_0x231953=!0x1):(_0x1b5c85++,_0x231953=!0x0),_0x3d6ffb['set'](_0x4fa28d['id'],_0x1b5c85);for(let _0x48ee38=0x0;_0x48ee38<_0x280abd['length'];_0x48ee38++){if('isRemoved'==_0x1940e9&&_0x280abd[_0x48ee38]['isAdded']||'isAdded'==_0x1940e9&&_0x280abd[_0x48ee38]['isRemoved'])continue;if('text'==_0x280abd[_0x48ee38]['type']){_0x280abd[_0x48ee38]['distance']=0x0;continue;}const _0x24b09c=_0x3d6ffb['get'](_0x280abd[_0x48ee38]['pairId']),_0xb685ff=_0x3d6ffb['get'](_0x280abd[_0x48ee38]['id']);_0x280abd[_0x48ee38]['distance']=_0x24b09c-_0xb685ff;}}['_getRevisionsRange'](_0x5eedc5,_0x5e7501,_0x3cdd1d=!0x1){const _0x267a0a=[];let _0x4f4f62=this['repository']['getIndex'](_0x5eedc5),_0x5709cf=this['repository']['getIndex'](_0x5e7501);for(-0x1==_0x5709cf&&(_0x5709cf=this['repository']['_revisions']['length'],_0x3cdd1d=!0x1);_0x4f4f62<_0x5709cf;)_0x267a0a['push'](this['repository']['getRevision'](_0x4f4f62)),_0x4f4f62++;return _0x3cdd1d&&_0x267a0a['push'](this['repository']['getRevision'](_0x4f4f62)),_0x267a0a;}['_threeWayMerge'](_0x43c989,_0x2f5469,_0x34fe2f,_0x5db6c3){const _0x3e6f8d=this['editor']['model']['schema'];let _0x4a9950=_0x2f5469;for(;_0x43c989[_0x4a9950]&&_0x43c989[_0x4a9950]['isAdded'];)_0x4a9950++;let _0x3e205e=_0x5db6c3;for(;_0x34fe2f[_0x3e205e]&&_0x34fe2f[_0x3e205e]['isRemoved'];)_0x3e205e++;_0x3c932d(_0x43c989,_0x2f5469,_0x4a9950),_0x3c932d(_0x34fe2f,_0x5db6c3,_0x3e205e);const _0x1c96db=_0x34fe2f['slice'](_0x5db6c3,_0x3e205e)['concat'](_0x43c989['slice'](_0x2f5469,_0x4a9950));return _0x1c96db['sort']((_0x1091a6,_0x40d4bd)=>_0x1091a6['side']!=_0x40d4bd['side']?_0x1091a6['side']-_0x40d4bd['side']:_0x1091a6['level']!=_0x40d4bd['level']?_0x1091a6['level']-_0x40d4bd['level']:_0x1091a6['distance']!=_0x40d4bd['distance']?_0x40d4bd['distance']-_0x1091a6['distance']:!!_0x1091a6['isAdded']!=!!_0x40d4bd['isAdded']?-0x1==_0x1091a6['side']||0x0==_0x1091a6['side']?_0x1091a6['isAdded']?-0x1:0x1:_0x1091a6['isAdded']?0x1:-0x1:_0x1091a6['index']-_0x40d4bd['index']),{'commonTape':_0x1c96db,'iEnd':_0x4a9950,'jEnd':_0x3e205e};function _0x3c932d(_0x3fa17a,_0x37fb2f,_0x4a75c9){let _0x3ceeff=-0x1,_0x4e9436=Number['POSITIVE_INFINITY'],_0xe99eae=!0x0;for(let _0x38240c=_0x37fb2f;_0x38240c<_0x4a75c9;_0x38240c++)if(_0x3e6f8d['isInline'](_0x3fa17a[_0x38240c]['item'])||(_0xe99eae=!0x1),_0x3fa17a[_0x38240c]['item']['startIndex']<_0x37fb2f&&(_0x3ceeff=_0x38240c),_0x3fa17a[_0x38240c]['item']['endIndex']>=_0x4a75c9){_0x4e9436=_0x38240c;break;}_0xe99eae&&(_0x3ceeff=_0x4a75c9-0x1);for(let _0x3de4c1=_0x37fb2f;_0x3de4c1<_0x4a75c9;_0x3de4c1++)_0x3fa17a[_0x3de4c1]['side']=_0x3de4c1<=_0x3ceeff?-0x1:_0x3de4c1<_0x4e9436?0x0:0x1,_0x3fa17a[_0x3de4c1]['index']=_0x3de4c1;let _0x22b464=0x0;for(let _0x5f80fc=_0x37fb2f;_0x5f80fc<=_0x3ceeff;_0x5f80fc++)0x0==_0x3fa17a[_0x5f80fc]['distance']?_0x3fa17a[_0x5f80fc]['level']=_0x22b464:(_0x22b464++,_0x3fa17a[_0x5f80fc]['level']=_0x22b464,_0x22b464++);for(let _0x4bddf1=_0x37fb2f;_0x4bddf1<_0x4a75c9;_0x4bddf1++)0x0==_0x3fa17a[_0x4bddf1]['side']&&(_0x3fa17a[_0x4bddf1]['level']=_0x22b464);_0x22b464=0x0;for(let _0x3e19b5=_0x4a75c9-0x1;_0x3e19b5>=_0x4e9436;_0x3e19b5--)0x0==_0x3fa17a[_0x3e19b5]['distance']?_0x3fa17a[_0x3e19b5]['level']=_0x22b464:(_0x22b464--,_0x3fa17a[_0x3e19b5]['level']=_0x22b464,_0x22b464--);}}['_fixObsoleteTags'](_0xb6b813){const _0xa21336=new Map(),_0x2931fc=this['editor']['model']['schema'];for(let _0x5828b4=0x1;_0x5828b4<_0xb6b813['length'];_0x5828b4++){let _0x5cee27,_0x406184,_0x248bd8;const _0x445368=_0xb6b813[_0x5828b4],_0x51af08=_0xb6b813[_0x5828b4-0x1];if('text'==_0x445368['type'])continue;if(_0x445368['type']!=_0x51af08['type'])continue;if(!_0x2931fc['isBlock'](_0x51af08['item'])||_0x2931fc['isLimit'](_0x51af08['item']))continue;if(!_0x2931fc['isBlock'](_0x445368['item'])||_0x2931fc['isLimit'](_0x445368['item']))continue;if((_0xb6b813[_0x5828b4]['isAdded']||_0xb6b813[_0x5828b4]['isAddSuggestion'])&&_0xb6b813[_0x5828b4-0x1]['isRemoved'])_0x5cee27=_0xb6b813[_0x5828b4],_0x406184=_0xb6b813[_0x5828b4-0x1],_0x248bd8=_0x5828b4-0x1;else{if(!_0xb6b813[_0x5828b4]['isRemoved']||!_0xb6b813[_0x5828b4-0x1]['isAdded']&&!_0xb6b813[_0x5828b4-0x1]['isAddSuggestion'])continue;_0x5cee27=_0xb6b813[_0x5828b4-0x1],_0x406184=_0xb6b813[_0x5828b4],_0x248bd8=_0x5828b4;}const _0x50b7a0=_0x5cee27['level']==_0x406184['level'],_0x141efb=Math['abs'](_0x5cee27['level'])<Math['abs'](_0x406184['level'])&&0x0==_0x406184['distance'];(_0x50b7a0||_0x141efb)&&(_0xa21336['set'](_0x406184['id'],_0x5cee27['id']),_0xb6b813['splice'](_0x248bd8,0x1),_0x5828b4--,_0x5cee27['isAdded']=!0x1);}for(let _0x88a74f=0x0;_0x88a74f<_0xb6b813['length'];_0x88a74f++)_0xa21336['has'](_0xb6b813[_0x88a74f]['pairId'])&&(_0xb6b813[_0x88a74f]['pairId']=_0xa21336['get'](_0xb6b813[_0x88a74f]['pairId']));}['_removeMissingPairs'](_0x16438e){const _0x21a5b2=new Set(_0x16438e['map'](_0x44cac1=>_0x44cac1['id']));for(let _0x750b73=0x0;_0x750b73<_0x16438e['length'];_0x750b73++)_0x21a5b2['has'](_0x16438e[_0x750b73]['pairId'])||0x0==_0x16438e[_0x750b73]['distance']||(_0x16438e[_0x750b73]['isIncorrect']=!0x0);return _0x16438e['filter'](_0x1af7d0=>!_0x1af7d0['isIncorrect']);}['_markMismatchedRemovedTags'](_0x4c185d){const _0x35efec=new Set();for(let _0x4a46a8=0x0;_0x4a46a8<_0x4c185d['length'];_0x4a46a8++){if(_0x35efec['has'](_0x4c185d[_0x4a46a8]['id'])&&_0x4c185d[_0x4a46a8]['isRemoved']&&(_0x4c185d[_0x4a46a8]['isIncorrect']=!0x0),_0x4c185d[_0x4a46a8]['isIncorrect'])continue;if(0x0==_0x4c185d[_0x4a46a8]['distance'])continue;if('elementStart'!=_0x4c185d[_0x4a46a8]['type'])continue;if(null==_0x4c185d[_0x4a46a8]['pairId'])continue;let _0x203362=_0x4a46a8+0x1,_0x253163=0x0;for(;_0x4c185d[_0x203362]['id']!=_0x4c185d[_0x4a46a8]['pairId'];)'elementStart'==_0x4c185d[_0x203362]['type']?_0x253163++:'elementEnd'==_0x4c185d[_0x203362]['type']&&_0x253163--,_0x203362++;if(0x0!=_0x253163){if(_0x4c185d[_0x4a46a8]['isRemoved'])_0x4c185d[_0x4a46a8]['isIncorrect']=!0x0;else{for(;_0x203362!=_0x4a46a8;)_0x4c185d[_0x203362]['isRemoved']&&0x0!=_0x4c185d[_0x203362]['distance']&&(_0x4c185d[_0x203362]['isIncorrect']=!0x0,_0x35efec['add'](_0x4c185d[_0x203362]['pairId'])),_0x203362--;}}}return _0x4c185d['filter'](_0x5689b2=>!_0x5689b2['isIncorrect']);}['_removeUnsupportedChanges'](_0x271924){const _0x89bca=this['editor']['model']['schema'];for(let _0x5963f3=0x0;_0x5963f3<_0x271924['length'];_0x5963f3++){if(!(_0x271924[_0x5963f3]['isAdded']||_0x271924[_0x5963f3]['isAddSuggestion']||_0x271924[_0x5963f3]['isRemoved']||_0x271924[_0x5963f3]['isRemoveSuggestion']))continue;if(0x0==_0x271924[_0x5963f3]['distance'])continue;const _0xc3a62b=_0x271924[_0x5963f3]['item'];_0x89bca['isBlock'](_0xc3a62b)||_0x89bca['isLimit'](_0xc3a62b)||(_0x271924[_0x5963f3]['isAdded']&&delete _0x271924[_0x5963f3]['isAdded'],_0x271924[_0x5963f3]['isAddSuggestion']&&delete _0x271924[_0x5963f3]['isAddSuggestion'],_0x271924[_0x5963f3]['isRemoveSuggestion']&&delete _0x271924[_0x5963f3]['isRemoveSuggestion'],_0x271924[_0x5963f3]['isRemoved']&&(_0x271924[_0x5963f3]['isIncorrect']=!0x0));}return _0x271924['filter'](_0x471964=>!_0x471964['isIncorrect']);}['_makeModelFromTape'](_0x28679a,_0x52d7c8,_0x4f9410){const _0x59a163=new vt(),_0x478a6e=[],_0x46e881=new Map(),_0x330299=this['editor']['model'],_0x299456=_0x330299['schema'],_0x50cae1=[_0x59a163],_0x269d1c={},_0x3ca894={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0xa6d5ca=null;const _0x2d40e2=[0x0];for(let _0xb425b3=0x0;_0xb425b3<_0x28679a['length'];_0xb425b3++)if('elementStart'===_0x28679a[_0xb425b3]['type']){_0x28679a[_0xb425b3]['previousPosition']=_0x330299['createPositionFromPath'](_0x59a163,_0x2d40e2);const _0x5b2984=new ut(_0x28679a[_0xb425b3]['item']['name'],_0x28679a[_0xb425b3]['item']['getAttributes']());_0x50cae1[0x0]['_appendChild'](_0x5b2984),_0x2d40e2['push'](0x0),_0x50cae1['unshift'](_0x5b2984),_0x28679a[_0xb425b3]['nextPosition']=_0x330299['createPositionFromPath'](_0x59a163,_0x2d40e2);}else'elementEnd'===_0x28679a[_0xb425b3]['type']?(_0x50cae1['shift'](),_0x28679a[_0xb425b3]['previousPosition']=_0x330299['createPositionFromPath'](_0x59a163,_0x2d40e2),_0x2d40e2['pop'](),_0x2d40e2[_0x2d40e2['length']-0x1]++,_0x28679a[_0xb425b3]['nextPosition']=_0x330299['createPositionFromPath'](_0x59a163,_0x2d40e2)):(_0x28679a[_0xb425b3]['previousPosition']=_0x330299['createPositionFromPath'](_0x59a163,_0x2d40e2),_0xa6d5ca?_0xa6d5ca['_data']+=_0x28679a[_0xb425b3]['item']['data']:_0xa6d5ca=new gt(_0x28679a[_0xb425b3]['item']['data'],_0x28679a[_0xb425b3]['item']['getAttributes']()),_0x28679a[_0xb425b3+0x1]&&'text'===_0x28679a[_0xb425b3+0x1]['type']&&_0x187e69(_0xa6d5ca,_0x28679a[_0xb425b3+0x1]['item'])||(_0x50cae1[0x0]['_appendChild'](_0xa6d5ca),_0xa6d5ca=null),_0x2d40e2[_0x2d40e2['length']-0x1]+=_0x28679a[_0xb425b3]['item']['offsetSize'],_0x28679a[_0xb425b3]['nextPosition']=_0x330299['createPositionFromPath'](_0x59a163,_0x2d40e2));for(let _0x544fbf=0x0;_0x544fbf<_0x28679a['length'];_0x544fbf++){const _0x4bff48=_0x28679a[_0x544fbf]['previousPosition'],_0x4bf70d=_0x28679a[_0x544fbf]['nextPosition'];for(const _0x34a0bd of _0x28679a[_0x544fbf]['markersStart'])_0x46e881['set'](_0x34a0bd,{'start':_0x4bff48,'end':null});_0x5321cf('isRemoveSuggestion',_0x544fbf,_0x4bff48,_0x4bf70d),_0x5321cf('isAddSuggestion',_0x544fbf,_0x4bff48,_0x4bf70d),_0x5321cf('isRemoved',_0x544fbf,_0x4bff48,_0x4bf70d),_0x5321cf('isAdded',_0x544fbf,_0x4bff48,_0x4bf70d);for(const _0x34de90 of _0x28679a[_0x544fbf]['markersEnd']){const _0x1fe3c9=_0x46e881['get'](_0x34de90);_0x1fe3c9?_0x1fe3c9['end']=_0x4bf70d:_0x46e881['set'](_0x34de90,{'start':_0x4bf70d,'end':_0x4bf70d});}}for(const [_0x1a010a,_0x372418]of _0x46e881){const _0x1ef6c6=this['editor']['model']['createRange'](_0x372418['start'],_0x372418['end']);_0x59a163['markers']['set'](_0x1a010a,_0x1ef6c6);}return _0x478a6e['sort']((_0x4687c7,_0x30597d)=>{const _0x13440b=_0x59a163['markers']['get']('revision:'+_0x4687c7['id']),_0x417277=_0x59a163['markers']['get']('revision:'+_0x30597d['id']);return _0x13440b['start']['isBefore'](_0x417277['start'])?-0x1:_0x13440b['start']['isAfter'](_0x417277['start'])?0x1:_0x13440b['end']['isBefore'](_0x417277['end'])?-0x1:_0x13440b['end']['isAfter'](_0x417277['end'])?0x1:'add'===_0x4687c7['type']?-0x1:0x1;}),{'root':_0x59a163,'changes':_0x478a6e};function _0x5321cf(_0x4e974d,_0x4099a4,_0x478057,_0x245956){const _0x7d6494=!!_0x28679a[_0x4099a4][_0x4e974d],_0x3228a4=_0x7d6494?_0x28679a[_0x4099a4][_0x4e974d]['userId']:null,_0x3c2b1a=_0x4099a4===_0x28679a['length']-0x1,_0x16f29d=_0x3ca894[_0x4e974d][0x0],_0x16af49=_0x299456['isObject'](_0x28679a[_0x4099a4]['item']);!_0x269d1c[_0x4e974d]&&_0x7d6494?_0x269d1c[_0x4e974d]={'start':_0x478057,'tapeItem':_0x28679a[_0x4099a4],'userId':_0x3228a4,'type':_0x4e974d}:_0x269d1c[_0x4e974d]&&!_0x7d6494?(_0x269d1c[_0x4e974d]['end']=_0x478057,_0x1658f2(_0x269d1c[_0x4e974d]),_0x269d1c[_0x4e974d]=null):_0x269d1c[_0x4e974d]&&_0x7d6494&&_0x269d1c[_0x4e974d]['userId']!==_0x3228a4&&(_0x269d1c[_0x4e974d]['end']=_0x478057,_0x16f29d&&_0x16f29d['userId']===_0x269d1c[_0x4e974d]['userId']||_0x1658f2(_0x269d1c[_0x4e974d]),_0x269d1c[_0x4e974d]={'start':_0x478057,'tapeItem':_0x28679a[_0x4099a4],'userId':_0x3228a4,'type':_0x4e974d}),_0x269d1c[_0x4e974d]&&_0x16af49&&('elementStart'!==_0x28679a[_0x4099a4]['type']||_0x16f29d&&_0x16f29d['userId']===_0x3228a4||_0x3ca894[_0x4e974d]['unshift']({'userId':_0x3228a4,'object':_0x28679a[_0x4099a4]['item'],'change':_0x269d1c[_0x4e974d]}),'elementEnd'===_0x28679a[_0x4099a4]['type']&&_0x16f29d&&_0x16f29d['object']===_0x28679a[_0x4099a4]['item']&&(_0x3ca894[_0x4e974d]['shift'](),_0x269d1c[_0x4e974d]=_0x16f29d['change'])),_0x269d1c[_0x4e974d]&&_0x3c2b1a&&(_0x269d1c[_0x4e974d]['end']=_0x245956,_0x1658f2(_0x269d1c[_0x4e974d]),_0x269d1c[_0x4e974d]=null);}function _0x1658f2({start:_0x583aa3,end:_0x59f54a,tapeItem:_0x56aed4,userId:_0x3f42e2,type:_0x24ad0e}){const _0x4ccb81=_0x56aed4['item'],_0x1780f0=_0x330299['schema']['isBlock'](_0x4ccb81)&&!_0x330299['schema']['isLimit'](_0x4ccb81),_0x3cdaba=_0x583aa3['nodeAfter']==_0x59f54a['parent']&&_0x59f54a['isAtStart'];if(_0x1780f0&&_0x3cdaba)return;const _0x32a063=_0x330299['createRange'](_0x583aa3,_0x59f54a),_0x51c126=_0x52d7c8['get'](_0x3f42e2),_0x36c763=new r({'author':_0x51c126,'type':'isAdded'==_0x24ad0e||'isAddSuggestion'==_0x24ad0e?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x24ad0e||'isRemoveSuggestion'==_0x24ad0e},'createdAt':new Date(),'rootName':_0x4f9410});_0x478a6e['push'](_0x36c763),_0x59a163['markers']['set']('revision:'+_0x36c763['id'],_0x32a063);}function _0x187e69(_0x324bf0,_0xa69e71){const _0x33358b=_0x324bf0['getAttributes'](),_0x3295ef=_0xa69e71['getAttributes']();for(const _0xc8bd68 of _0x33358b){if(_0xc8bd68[0x1]!==_0xa69e71['getAttribute'](_0xc8bd68[0x0]))return!0x1;_0x3295ef['next']();}return _0x3295ef['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x27c804=>{const _0x118dba=_0x27c804['markerName']['split'](':')[0x1],_0x5e3f94=this['_getChangeFromId'](_0x118dba);if(!_0x5e3f94)return null;const _0xcbb041='add'==_0x5e3f94['type']?'insertion':'deletion',_0x45ee23=['ck-suggestion-marker','ck-suggestion-marker-'+_0xcbb041];return _0x5e3f94['data']['isSuggestion']&&_0x45ee23['push']('ck-suggestion-marker-'+_0xcbb041+'-new'),this['activeChange']==_0x5e3f94&&_0x45ee23['push']('ck-suggestion-marker--active'),{'classes':_0x45ee23,'attributes':{'data-change-id':_0x118dba}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x3a1425=>{_0x3a1425['on']('element:pre',(_0x310860,_0x7b0d77,_0x56d39a)=>{const _0x38fc0b=_0x7b0d77['viewItem']['getChild'](0x0);if(!_0x38fc0b||!_0x38fc0b['is']('element','code'))return;if(!_0x56d39a['consumable']['consume'](_0x38fc0b,{'attributes':['vid_start','vid_end']}))return;const _0x48acd6=_0x7b0d77['modelRange']['start']['nodeAfter'];_0x56d39a['writer']['setAttribute']('vid_start',_0x38fc0b['getAttribute']('vid_start'),_0x48acd6),_0x56d39a['writer']['setAttribute']('vid_end',_0x38fc0b['getAttribute']('vid_end'),_0x48acd6);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x1e1e1c=>{_0x1e1e1c['on']('element',(_0x196a6e,_0x54f202,_0x7d446e)=>{if(!_0x7d446e['consumable']['consume'](_0x54f202['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x54f202['modelRange']['isCollapsed'])return;const _0x4e27b4=_0x54f202['modelRange']['start']['nodeAfter'];_0x4e27b4['hasAttribute']('vid_start')||_0x4e27b4['hasAttribute']('vid')||(_0x7d446e['writer']['setAttribute']('vid_start',_0x54f202['viewItem']['getAttribute']('vid_start'),_0x4e27b4),_0x7d446e['writer']['setAttribute']('vid_end',_0x54f202['viewItem']['getAttribute']('vid_end'),_0x4e27b4));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x508f14=>_0x508f14['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x5a993b,[,_0x37317d])=>{['vid_start','vid_end','vid']['includes'](_0x37317d)&&(_0x5a993b['return']=!0x0,_0x5a993b['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x13fcf9=>{_0x13fcf9['on']('attribute:vid',(_0x2fe1f2,_0x499b60,_0x223e8e)=>{if('\x20'!=_0x499b60['item']['data']||_0x499b60['item']['parent']['maxOffset']>0x1)return;if(!_0x223e8e['consumable']['consume'](_0x499b60['item'],_0x2fe1f2['name']))return;const _0x191d95=_0x223e8e['writer'],_0x292b04=_0x223e8e['mapper']['toViewRange'](_0x499b60['range']);_0x191d95['wrap'](_0x292b04,_0x191d95['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x7b710d){const _0x2a373e=_0x7b710d['plugins']['get']('RevisionViewer');return(_0x31f449,_0xd1935a,_0x1e843f)=>{const _0x3bb161=_0xd1935a['markerName']['split'](':')[0x1],_0x2155eb=_0x2a373e['_getChangeFromId'](_0x3bb161);if(!_0x2155eb)return null;const _0x5b577e='add'==_0x2155eb['type']?'split':'merge';if(!_0x1e843f['consumable']['test'](_0xd1935a['markerRange'],_0x31f449['name']))return;const _0x110d43=_0xd1935a['markerRange']['getWalker'](),_0x256daf=_0xd1935a['markerRange']['start'],_0x33d9bd=_0x7b710d['model']['schema'];let _0x5a53df=null,_0x47a5d5=null,_0x44dd88=!0x1,_0x30a9a0=!0x1;for(const _0x59e69b of _0x110d43){const _0x3ad103=_0x59e69b['item'];_0x44dd88=_0x44dd88||_0x33d9bd['isContent'](_0x3ad103);const _0x5f09af=_0x1e843f['mapper']['toViewElement'](_0x3ad103);if(_0x5f09af&&_0x5f09af['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x59e69b['type']&&(_0x33d9bd['isBlock'](_0x3ad103)&&!_0x33d9bd['isLimit'](_0x3ad103)&&(_0x3ad103['nextSibling']||_0x256daf['isAtEnd']?_0x5a53df&&_0x5a53df['parent']==_0x3ad103||(_0x5a53df=_0x3ad103,_0x258231(_0x59e69b['previousPosition']),_0x30a9a0=!0x0):_0x47a5d5=_0x47a5d5||_0x59e69b['previousPosition']));}function _0x258231(_0x238088){const _0x205d3d=_0x1e843f['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x5b577e}),_0x181e59=_0x1e843f['mapper']['toViewPosition'](_0x238088);_0x2155eb['data']['isSuggestion']&&_0x1e843f['writer']['addClass']('ck-suggestion-marker-'+_0x5b577e+'-new',_0x205d3d),_0x2a373e['activeChange']==_0x2155eb&&_0x1e843f['writer']['addClass']('ck-suggestion-marker--active',_0x205d3d),_0x1e843f['writer']['insert'](_0x181e59,_0x205d3d),_0x1e843f['mapper']['bindElementToMarker'](_0x205d3d,_0xd1935a['markerName']);}_0x44dd88||_0x30a9a0||!_0x47a5d5||_0x258231(_0x47a5d5);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x203566,_0x1dbc48,_0x36a638)=>{const _0x2faaf8=_0x36a638['mapper']['markerNameToElements'](_0x1dbc48['markerName']);if(_0x2faaf8){for(const _0x3aa40c of _0x2faaf8)(_0x3aa40c['hasClass']('ck-suggestion-marker-split')||_0x3aa40c['hasClass']('ck-suggestion-marker-merge'))&&(_0x36a638['mapper']['unbindElementFromMarkerName'](_0x3aa40c,_0x1dbc48['markerName']),_0x36a638['writer']['remove'](_0x3aa40c));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x83ff51,_0x553b04,_0x12a3af)=>{const _0x3f3994=_0x553b04['markerName']['split'](':')[0x1],_0x48d242=this['_getChangeFromId'](_0x3f3994);if(!_0x48d242)return null;const _0x5b5b3a='add'==_0x48d242['type']?'split':'merge';if(_0x12a3af['consumable']['test'](_0x553b04['markerRange'],_0x83ff51['name']))for(const _0x5add88 of _0x553b04['markerRange']['getItems']()){if(!_0x5add88['is']('element','softBreak'))continue;const _0x5953dc=_0x12a3af['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x5b5b3a}),_0x2c9fe4=_0x12a3af['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x5add88));_0x48d242['data']['isSuggestion']&&_0x12a3af['writer']['addClass']('ck-suggestion-marker-'+_0x5b5b3a+'-new',_0x5953dc),this['activeChange']==_0x48d242&&_0x12a3af['writer']['addClass']('ck-suggestion-marker--active',_0x5953dc),_0x12a3af['writer']['insert'](_0x2c9fe4,_0x5953dc),_0x12a3af['mapper']['bindElementToMarker'](_0x5953dc,_0x553b04['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x51bfb6=>{for(const _0x5ba4e5 of this['editor']['model']['document']['getRootNames']()){const _0xbbf501=this['editor']['model']['document']['getRoot'](_0x5ba4e5),_0x27e5dd=this['editor']['editing']['view']['document']['getRoot'](_0x5ba4e5);if(_0x27e5dd){const _0x1ea0ce=_0xbbf501['getAttribute']('revisionHistoryAttachChange');if(_0x51bfb6['removeAttribute']('data-change-id',_0x27e5dd),_0x51bfb6['removeClass']('ck-revision-history-root-add',_0x27e5dd),_0x51bfb6['removeClass']('ck-revision-history-root-remove',_0x27e5dd),_0x51bfb6['removeClass']('ck-revision-history-root--active',_0x27e5dd),_0x1ea0ce){const _0x59d2d6=this['_getChangeFromId'](_0x1ea0ce);if(!_0x59d2d6)return null;_0x51bfb6['setAttribute']('data-change-id',_0x1ea0ce,_0x27e5dd),_0x51bfb6['addClass']('ck-revision-history-root-'+_0x59d2d6['type'],_0x27e5dd),this['activeChange']==_0x59d2d6&&_0x51bfb6['addClass']('ck-revision-history-root--active',_0x27e5dd);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x3223a4=>'revision-comment:'+_0x3223a4,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x50dd27=>'revision-suggestion:'+_0x50dd27,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x2f169a=>({'name':'suggestion:'+_0x2f169a,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x183a89=>{const _0x4a9dc6=_0x183a89['markerName']['split'](':')[0x1];return'insertion'!=_0x4a9dc6&&'deletion'!=_0x4a9dc6?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x4a9dc6]};}}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:deletion',X(this['editor'],'merge'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:insertion',X(this['editor'],'split'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision-suggestion',(_0x311a93,_0x422257,_0x17868a)=>{const _0xe54013=_0x17868a['mapper']['markerNameToElements'](_0x422257['markerName']);if(_0xe54013){for(const _0x15464a of _0xe54013)_0x15464a['is']('uiElement')&&(_0x17868a['mapper']['unbindElementFromMarkerName'](_0x15464a,_0x422257['markerName']),_0x17868a['writer']['remove'](_0x15464a));}},{'priority':'high'});}['_getChangeFromId'](_0x3b1849){return this['_changeIdToChange']['get'](_0x3b1849);}['_getViewForChange'](_0x2fdd91){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new Q(this['editor']['locale'],_0x2fdd91),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x37bc03,_0x3dbf9e,_0x16537b,_0x32184e)=>{_0x32184e&&this['_balloon']['remove'](_0x32184e),_0x16537b&&(this['_balloon']['add']({'view':_0x16537b,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x2adf88=this['editor']['editing'],_0x333662=this['_getChangeFromId'](_0x16537b['changeId']);let _0x13b497;if(_0x333662['data']['isOnRoot']){const _0x4fcb7f=_0x2adf88['view']['getDomRoot'](_0x333662['rootName']);_0x13b497=Array['from'](_0x4fcb7f['getClientRects']());}else{const _0x30f481=this['editor']['model']['markers']['get']('revision:'+_0x16537b['changeId']);_0x13b497=Array['from'](_0x2adf88['mapper']['markerNameToElements'](_0x30f481['name']))['map'](_0x4541ac=>_0x2adf88['view']['domConverter']['mapViewToDom'](_0x4541ac))['map'](_0x125fe5=>Array['from'](_0x125fe5['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x13b497[0x0];return _0x13b497['find'](_0x7b992c=>_0x7b992c['top']-0x3<=this['_activeViewTarget']['y']&&_0x7b992c['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x7b992c['left']-0x3<=this['_activeViewTarget']['x']&&_0x7b992c['right']+0x3>=this['_activeViewTarget']['x'])||_0x13b497[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x11c0d4,_0x33654b,_0x54f383,_0x46e173)=>{this['activeView']=_0x54f383?this['_getViewForChange'](_0x54f383):null,this['editor']['model']['change'](()=>{const _0x4a58ac=this['editor']['editing'];_0x46e173&&(_0x46e173['data']['isOnRoot']?_0x4a58ac['view']['change'](_0x305dea=>{_0x305dea['removeClass']('ck-revision-history-root--active',_0x4a58ac['view']['document']['getRoot'](_0x46e173['rootName']));}):_0x4a58ac['reconvertMarker']('revision:'+_0x46e173['id'])),_0x54f383&&(_0x54f383['data']['isOnRoot']?_0x4a58ac['view']['change'](_0x4fef8c=>{_0x4fef8c['addClass']('ck-revision-history-root--active',_0x4a58ac['view']['document']['getRoot'](_0x54f383['rootName']));}):_0x4a58ac['reconvertMarker']('revision:'+_0x54f383['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x393d26,_0x5d7fb8)=>{if(this['activeChange'])return;const _0x16f810=this['_findChangeIdFromDomTarget'](_0x5d7fb8['target']),_0x50495e=this['_changeIdToChange']['get'](_0x16f810);_0x50495e?(this['_activeViewTarget']={'x':_0x5d7fb8['domEvent']['x'],'y':_0x5d7fb8['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x50495e)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x1ac039,_0x558d39)=>{const _0x23c41b=this['_findChangeIdFromDomTarget'](_0x558d39['target']),_0x31e392=this['_changeIdToChange']['get'](_0x23c41b);_0x31e392?(this['_activeViewTarget']={'x':_0x558d39['domEvent']['x'],'y':_0x558d39['domEvent']['y']},_0x31e392===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x31e392):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x266770){do{const _0x40bcef=_0x266770['getAttribute']('data-change-id');if(_0x40bcef)return _0x40bcef;_0x266770=_0x266770['parent'];}while(_0x266770);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0xffb09=>{for(const _0x47b0db of this['editor']['model']['markers'])_0xffb09['removeMarker'](_0x47b0db);});}}function X(_0x1e1e06,_0x5ac01b){return(_0xd93700,_0x4ce257,_0x232026)=>{if(!_0x232026['consumable']['test'](_0x4ce257['markerRange'],_0xd93700['name']))return;const _0x376b83=_0x4ce257['markerRange']['getWalker'](),_0xbe8eed=_0x4ce257['markerRange']['start'],_0xf74dbb=_0x1e1e06['model']['schema'];let _0x251e5e=null,_0x2d2aec=null,_0x5f1a5b=!0x1,_0x3d70cd=!0x1;for(const _0xf0640a of _0x376b83){const _0x542f0c=_0xf0640a['item'];_0x5f1a5b=_0x5f1a5b||_0xf74dbb['isContent'](_0x542f0c);const _0x1b202a=_0x232026['mapper']['toViewElement'](_0x542f0c);if(_0x1b202a&&_0x1b202a['getCustomProperty']('addHighlight'))return;'elementEnd'==_0xf0640a['type']&&(_0xf74dbb['isBlock'](_0x542f0c)&&!_0xf74dbb['isLimit'](_0x542f0c)&&(_0x542f0c['nextSibling']||_0xbe8eed['isAtEnd']?_0x251e5e&&_0x251e5e['parent']==_0x542f0c||(_0x251e5e=_0x542f0c,_0x5df1cf(_0xf0640a['previousPosition']),_0x3d70cd=!0x0):_0x2d2aec=_0x2d2aec||_0xf0640a['previousPosition']));}function _0x5df1cf(_0x1e66d5){const _0x145696=_0x232026['mapper']['toViewPosition'](_0x1e66d5),_0x3e8866=_0x232026['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x5ac01b});_0x232026['writer']['insert'](_0x145696,_0x3e8866),_0x232026['mapper']['bindElementToMarker'](_0x3e8866,_0x4ce257['markerName']);}_0x5f1a5b||_0x3d70cd||!_0x2d2aec||_0x5df1cf(_0x2d2aec);};}class mt extends _0x59b140{constructor(_0x43ad56){super(_0x43ad56);const _0x2168dd=_0x43ad56['plugins']['get'](m);this['affectsData']=!0x1,this['listenTo'](_0x2168dd,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x2168dd,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x4b9f1a=this['editor'],_0x155916=_0x4b9f1a['plugins']['get'](m),_0x1f2d85=_0x155916['isReady']?_0x155916['diff']['newRevisionId']:null;_0x4b9f1a['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x1f2d85);}['refresh'](){const {isReady:_0x57b1f2,isEnabled:_0x383a8e,repository:_0x3db07b,diff:_0x4f75c0}=this['editor']['plugins']['get'](m),_0x2472b7=_0x4f75c0&&_0x3db07b['getLaterVisibleRevision'](_0x4f75c0['newRevisionId']);this['isEnabled']=_0x57b1f2&&_0x383a8e&&Boolean(_0x2472b7);}}class wt extends _0x59b140{['_step'];constructor(_0xd15682,{direction:_0x139087}){super(_0xd15682);const _0x16ceb0=_0xd15682['plugins']['get'](m);this['affectsData']=!0x1,this['_step']='forward'===_0x139087?0x1:-0x1,this['listenTo'](_0x16ceb0,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x16ceb0,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x16ceb0,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x127d7a=this['editor'],_0x4b4b59=_0x127d7a['plugins']['get'](m),{isNavigationMode:_0x2d3f36,currentChangeNumber:_0x3fda7a}=_0x4b4b59;let _0x24d8eb;if(_0x4b4b59['activeChange']=_0x2d3f36?_0x4b4b59['diff']['changes']['get'](_0x3fda7a+this['_step']):_0x4b4b59['diff']['changes']['first'],_0x4b4b59['activeChange']['data']['isOnRoot'])_0x24d8eb=_0x127d7a['editing']['view']['getDomRoot'](_0x4b4b59['activeChange']['rootName']);else{const _0x3beae5=_0x127d7a['model']['markers']['get']('revision:'+_0x4b4b59['activeChange']['id']);_0x24d8eb=_0x4163f9(_0x127d7a['editing'],_0x3beae5);}_0x47d889({'target':_0x24d8eb,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x3afa61,currentChangeNumber:_0x35ff9b,numberOfChanges:_0x29d50f,isReady:_0x2ef8cf,isEnabled:_0x366b34}=this['editor']['plugins']['get'](m);this['isEnabled']=!!(_0x366b34&&_0x2ef8cf&&_0x29d50f)&&(!_0x3afa61||(0x1===this['_step']?_0x35ff9b<_0x29d50f-0x1:_0x35ff9b>0x0));}}class _i extends ts{constructor(_0x4c6392){super(_0x4c6392);const _0x36b418=this['bindTemplate'],_0x556be1=new te(_0x4c6392),_0x158657=new te(_0x4c6392);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',(_0x6ec2f9,_0x564759)=>_0x6ec2f9&&_0x564759>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x1d4596,_0x252bd9,_0x5588cc,_0x5151b3)=>{if(!_0x1d4596)return g(_0x4c6392,'Loading...');if(!_0x5588cc)return g(_0x4c6392,'No\x20changes');const _0x486373=g(_0x4c6392,'NUMBER_OF_CHANGES',_0x5588cc);return _0x5151b3?g(_0x4c6392,'X_OF_Y_CHANGES',[_0x252bd9+0x1,_0x5588cc]):_0x486373;}),_0x556be1['set']({'label':g(_0x4c6392,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x572eae}),_0x158657['set']({'label':g(_0x4c6392,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x27e49a}),_0x556be1['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x158657['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x556be1['on']('execute',()=>this['fire']('execute','backward')),_0x158657['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',_0x36b418['if']('_isStatusLabelVisible','ck-hidden',_0x5c2a3f=>!_0x5c2a3f)]},'children':[{'text':_0x36b418['to']('isNavigationMode',_0x127424=>_0x127424?g(_0x4c6392,'EDIT_X_OF_Y_REVISIONS')+':\x20':g(_0x4c6392,'Total')+':\x20')}]},{'text':_0x36b418['to']('_statusText')}]},new _0x2a7398(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x556be1,_0x158657]}]});}}const le='ck-editor__editable__loading-overlay';class ge extends _0x2a63bd{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x2eca66=this['editor']['editing']['view'];_0x2eca66['change'](_0x253bc6=>{for(const _0x19c3a3 of _0x2eca66['document']['roots'])_0x253bc6['addClass'](le,_0x19c3a3);});}['hide'](){const _0x49adf1=this['editor']['editing']['view'];_0x49adf1['change'](_0x23d29e=>{for(const _0x22dfc6 of _0x49adf1['document']['roots'])_0x23d29e['removeClass'](le,_0x22dfc6);});}}class R extends _0x2a63bd{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[m,ge];}['init'](){const _0x3b9ce2=this['editor'],_0x4c4dd9=_0x3b9ce2['plugins']['get'](m),_0x59bb71=_0x3b9ce2['plugins']['get'](ge);_0x3b9ce2['ui']['componentFactory']['add']('exitToEditing',_0x40f0d3=>{const _0x54c739=new te(_0x40f0d3);return _0x54c739['set']({'label':g(_0x40f0d3,'Back\x20to\x20editing'),'icon':_0x10e1d9,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x54c739,'execute',()=>{_0x3b9ce2['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x54c739;}),_0x3b9ce2['ui']['componentFactory']['add']('restoreRevision',_0x2b70ca=>{const _0x50bd82=new te(_0x2b70ca);return _0x50bd82['set']({'label':g(_0x2b70ca,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x50bd82['bind']('isEnabled')['to'](_0x3b9ce2['commands']['get']('restoreRevision')),this['listenTo'](_0x50bd82,'execute',()=>_0x3b9ce2['execute']('restoreRevision')),_0x50bd82;}),_0x3b9ce2['ui']['componentFactory']['add']('changesNavigation',_0x1d734f=>{const _0x1c67af=new _i(_0x1d734f),_0x391133=_0x3b9ce2['commands']['get']('showPreviousChange'),_0xe32da3=_0x3b9ce2['commands']['get']('showNextChange');return _0x1c67af['bind']('isBackwardNavigationEnabled')['to'](_0x391133,'isEnabled'),_0x1c67af['bind']('isForwardNavigationEnabled')['to'](_0xe32da3,'isEnabled'),_0x1c67af['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x4c4dd9),this['listenTo'](_0x1c67af,'execute',(_0x4c9ac4,_0x3aef84)=>{_0x3b9ce2['execute']('forward'===_0x3aef84?'showNextChange':'showPreviousChange');}),_0x1c67af;}),_0x59bb71['show'](),_0x4c4dd9['on']('change:isReady',(_0x417831,_0x290ad5,_0x18f042)=>{_0x18f042?_0x59bb71['hide']():_0x59bb71['show']();});}}class at extends _0x370644{['_resizeObserver']=null;constructor(_0x2bf779,_0x6227a8){super(_0x2bf779,_0x6227a8);const _0x5c8f6f=this['bindTemplate'];this['set']({'label':g(_0x2bf779,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=g(_0x2bf779,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x5c8f6f['to']('_tooltipString'),'data-cke-tooltip-position':'s','data-cke-tooltip-class':'ck-tooltip_multi-line'}});}['render'](){super['render'](),this['_resizeObserver']=new nt(this['fieldView']['element'],()=>this['_updateTooltipText']()),this['listenTo'](this['fieldView'],'input',()=>this['_updateTooltipText']());}['destroy'](){super['destroy'](),this['_resizeObserver']&&this['_resizeObserver']['destroy']();}['_updateTooltipText'](){const _0x267059=this['fieldView']['element'];this['_tooltipString']=_0x267059['scrollWidth']>_0x267059['clientWidth']&&_0x267059['value']||'';}}class si extends ts{constructor(_0x31ef3f,_0x396f97,_0x9d42b7){super(_0x31ef3f);const _0x203add=new _0x5b36d2();_0x203add['set']({'content':_0x431fd6,'viewBox':'0\x200\x2011\x2010'});const _0x5ee178=['ck','ck-revision-history-sidebar__revision-author'];_0x9d42b7&&_0x5ee178['push']('ck-revision-history-sidebar__revision-author_creator');const _0xf430b8=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':g(_0x31ef3f,_0x9d42b7?'Revision\x20creator':'Revision\x20author')},'children':[_0x203add,_0x396f97['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x5ee178},'children':_0xf430b8});}}function oi(_0x1db76c,_0x12c107){const _0x52e033=_0x1db76c['bindTemplate'],_0xa20df7=_0x1db76c['locale'],_0x3f5143=_0x146e16(_0xa20df7);_0x3f5143['panelPosition']='sw';const _0x118331=function(_0x4dede3,_0x1bc164){const _0x24bc08=function(_0x3afd63,_0x443709){const _0x279d78=_0x3afd63['locale'],_0x5d0f44={'Compare\x20against\x20selected':g(_0x279d78,'Compare\x20against\x20selected'),'Name\x20this\x20revision':g(_0x279d78,'Name\x20this\x20revision'),'Restore\x20this\x20revision':g(_0x279d78,'Restore\x20this\x20revision')};return _0x443709['map'](_0x4ab76d=>{const _0x5dfaa2=_0x5d0f44[_0x4ab76d['name']];return _0x5dfaa2&&_0x5dfaa2!==_0x4ab76d['name']&&(_0x4ab76d['name']=_0x5dfaa2),_0x4ab76d;});}(_0x4dede3,_0x1bc164),_0x8dd6ed=new _0x90db85();for(const _0x168502 of _0x24bc08){const _0x380d83={'type':'button','model':new to({'label':_0x168502['name'],'class':_0x168502['class'],'withText':!0x0,'role':'menuitem','_action':_0x168502['action']})};_0x380d83['model']['bind']('isEnabled')['to'](_0x4dede3,'isActionsDropdownOpen',_0x48e67c=>'function'!=typeof _0x168502['isEnabled']||(!_0x48e67c||_0x168502['isEnabled'](_0x4dede3))),_0x8dd6ed['add'](_0x380d83);}return _0x8dd6ed;}(_0x1db76c,_0x12c107);return _0x1db76c['bind']('isActionsDropdownOpen')['to'](_0x3f5143,'isOpen'),_0x3f5143['buttonView']['set']({'label':g(_0xa20df7,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x22193b}),_0x3f5143['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x52e033['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x52e033['to'](_0x3bdde7=>_0x3bdde7['stopPropagation']())}}),_0x3f5143['on']('execute',_0x336d50=>{_0x1db76c['isReady']&&'function'==typeof _0x336d50['source']['_action']&&_0x336d50['source']['_action'](_0x1db76c);}),_0x2b4910(_0x3f5143,_0x118331,{'role':'menu'}),_0x3f5143['listenTo'](_0x1db76c,'change:isActionsDropdownOpen',(_0x4b9bbe,_0xe9322a,_0x371791)=>{if(_0x371791)for(const _0x2c9bac of _0x3f5143['listView']['items']){const _0x5b88e1=_0x2c9bac['children']['first'],_0xfe5a52=_0x12c107['find'](_0x48ac7b=>_0x48ac7b['action']===_0x5b88e1['_action'])['isVisible'];_0x2c9bac['isVisible']=void 0x0===_0xfe5a52||_0xfe5a52(_0x1db76c);}}),_0x3f5143;}class hi extends/* #__PURE__ -- @preserve */
26
- ti(ts){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x117ec8,_0x230a2b,_0x3c8cde,_0x5a88be){super(_0x117ec8);const _0x55ffd9=this['bindTemplate'],_0x31d539=function(_0x41331f,_0x4735c1){const _0x4cf1a2=Array['from'](_0x4735c1['authors'])['filter'](_0x40d397=>_0x40d397!=_0x4735c1['creator']);return _0x4735c1['creator']&&_0x4cf1a2['unshift'](_0x4735c1['creator']),_0x4cf1a2['map'](_0x1ea3be=>new si(_0x41331f,_0x1ea3be,_0x1ea3be==_0x4735c1['creator']));}(_0x117ec8,_0x230a2b);this['id']=_0x230a2b['id'],this['_revision']=_0x230a2b,this['_requireRevisionName']=_0x5a88be,this['bind']('name','createdAt')['to'](_0x230a2b),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0xaa416e=>{return _0x946be=_0x117ec8['uiLanguage'],(_0x4a5af0=_0xaa416e)['toLocaleDateString'](_0x946be,{'month':'long','day':'numeric'})+',\x20'+_0x4a5af0['toLocaleTimeString'](_0x946be,{'hour':'numeric','minute':'numeric'});var _0x946be,_0x4a5af0;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new at(_0x117ec8,_0x342059),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x10013b=>_0x10013b||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x24c8cb,_0x1c951f)=>_0x24c8cb&&_0x1c951f),this['revisionActionsView']=_0x3c8cde&&_0x3c8cde['length']?oi(this,_0x3c8cde):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x55ffd9['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x55ffd9['if']('isEnabled','ck-disabled',_0x188bc1=>!_0x188bc1),_0x55ffd9['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x55ffd9['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x55ffd9['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':_0x55ffd9['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':_0x31d539}]},this['revisionActionsView']],'on':{'click':_0x55ffd9['to'](_0x44425b=>{_0x44425b['srcElement']['closest']('.ck-thread__remove-confirm')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0xa8cc17=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0xa8cc17,'change',()=>{this['_requireRevisionName']&&!_0xa8cc17['value']||this['fire']('setName',{'id':this['id'],'name':_0xa8cc17['value']}),_0xa8cc17['value']||(_0xa8cc17['value']=this['name']?this['name']:this['_createdAtFormatted']);});}['select'](){this['isSelected']=!0x0;}['deselect'](){this['isSelected']=!0x1;}['highlight'](){this['isHighlighted']=!0x0;}['unhighlight'](){this['isHighlighted']=!0x1;}}function ai(_0x45d36c,_0x5ee36f){const _0xf81fc3=_0x55426a['fromJSDate'](_0x45d36c)['setLocale'](_0x5ee36f),_0x3c8130=_0x55426a['local'](),_0x4e2542=_0x3c8130['minus']({'days':0x1})['startOf']('day');let _0x394196,_0x523131;return _0xf81fc3['hasSame'](_0x3c8130,'day')?(_0x394196=_0xf81fc3['startOf']('day')['toJSDate'](),_0x523131=_0xf81fc3['toRelativeCalendar']()):_0xf81fc3['hasSame'](_0x4e2542,'day')?(_0x394196=_0x4e2542['toJSDate'](),_0x523131=_0xf81fc3['toRelativeCalendar']()):_0xf81fc3['hasSame'](_0x3c8130,'week')?(_0x394196=_0xf81fc3['startOf']('week')['toJSDate'](),_0x523131=_0xf81fc3['weekdayLong']||''):_0xf81fc3['hasSame'](_0x3c8130,'year')?(_0x394196=_0xf81fc3['startOf']('month')['toJSDate'](),_0x523131=_0xf81fc3['monthLong']||''):(_0x394196=_0xf81fc3['startOf']('year')['toJSDate'](),_0x523131=String(_0xf81fc3['year'])),{'startDate':_0x394196,'localizedPeriodName':_0x523131};}class di extends ts{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x1aa45f,_0x3f03c0,_0x49092a,_0xc846bb){super(_0x1aa45f);const _0x31c43c=ai(_0x3f03c0,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x3f03c0,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x49092a,this['_requireRevisionName']=_0xc846bb,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':_0x31c43c}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x24473a){const _0x37f989=new hi(this['locale'],_0x24473a,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x37f989);}['removeRevision'](_0x22eea0){const _0x588c7a=this['revisionViews']['find'](_0x1c23cb=>_0x1c23cb['id']===_0x22eea0['id']);this['revisionViews']['remove'](_0x588c7a);}}class as extends ts{constructor(_0x4d7a78){super(_0x4d7a78);const _0x5e9962=new _0x5b36d2();_0x5e9962['content']=_0x3e3e17,this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x5e9962,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[g(_0x4d7a78,'Revision\x20history')]}]});}}class ni extends ts{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x596e9a,_0x51885f,_0x5f0ddb,_0x437fce){super(_0x596e9a);const _0x582bad=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x51885f,this['_revisionActions']=_0x5f0ddb,this['_requireRevisionName']=_0x437fce,this['on']('select',(_0x32cfdf,_0x453f74)=>{this['fire']('revisionSelected',_0x453f74);}),this['on']('setName',(_0x50d10f,_0x5b05fc)=>{this['fire']('revisionSetName',_0x5b05fc);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new as(_0x596e9a),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x582bad['if']('isEnabled','ck-disabled',_0x41b693=>!_0x41b693)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x410ff9 of this['_revisions'])this['_addRevision'](_0x410ff9);this['_revisions']['on']('add',(_0x597e7b,_0x4a115b)=>{this['_addRevision'](_0x4a115b);}),this['_revisions']['on']('remove',(_0x1d3566,_0x4b9ea9)=>{this['_removeRevision'](_0x4b9ea9);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x3b40f9=>_0x3b40f9['revisionViews']['map'](_0x59d635=>_0x59d635))['flat']();}['selectRevision'](_0xde8fea){for(const _0x47cea8 of this['revisionViews'])_0xde8fea&&_0xde8fea['id']===_0x47cea8['id']?_0x47cea8['select']():_0x47cea8['deselect']();}['highlightRevisions'](_0x192093){for(const _0x4751ef of this['revisionViews'])_0x192093['some'](({id:_0x49109b})=>_0x49109b===_0x4751ef['id'])?_0x4751ef['highlight']():_0x4751ef['unhighlight']();}['_addRevision'](_0x5ee396){const _0x3f0dad=ai(_0x5ee396['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x2c9482=this['timePeriodViews']['get'](0x0);_0x2c9482&&_0x2c9482['startDate']['getTime']()===_0x3f0dad['getTime']()||(_0x2c9482=new di(this['locale'],_0x3f0dad,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x2c9482)),_0x2c9482['addRevision'](_0x5ee396);}['_removeRevision'](_0x5871fa){const _0x37a468=ai(_0x5871fa['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x37a468)['removeRevision'](_0x5871fa);}['_getTimePeriodViewByStartDate'](_0x5dadef){return this['timePeriodViews']['find'](_0x38a7de=>_0x38a7de['startDate']['getTime']()===_0x5dadef['getTime']());}}class d extends _0x2a63bd{['_revisionViewer'];['_revisionsRepository'];['_sidebarView'];static ['defaultRevisionActions']=/* #__PURE__ -- @preserve */
23
+ import{ObservableMixin as _0x11aaf9,uid as _0x19f1f8,Collection as _0x58fbc2,logWarning as _0x9f97ee,FocusTracker as _0x3442d6,KeystrokeHandler as _0x47111d,scrollViewportToShowTarget as _0x31a828,ResizeObserver as nt,ElementReplacer as ot,CKEditorError as _0x3f46eb}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x54f69d,set as _0x3c8c83,unset as _0x39b3c1,isEqual as _0x73df34}from'es-toolkit/compat';import{Plugin as _0xc858c4,PendingActions as _0x2c2110,Command as _0x4ca95f,ElementApiMixin as _0x1cb442,Editor as _0x3afd4d}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x27c92d,getMarkerDomElement as _0x3ab3e0,ConfirmMixin as ti,sanitizeEditorConfig as _0x4a9536}from'ckeditor5-collaboration/dist/index.js';import{ViewContainerElement as _0x33ae4a,ViewAttributeElement as _0x343ac3,ViewEmptyElement as _0x363faa,ViewRawElement as _0x4f743a,ViewUIElement as _0x37d218,ViewDocumentFragment as _0x34ebf2,ViewText as _0x21dd2f,ViewElement as _0x390be8,Element as ut,Range as lt,Position as ft,DocumentFragment as vt,Text as gt}from'@ckeditor/ckeditor5-engine/dist/index.js';import{IconHistory as _0x3e9cd6,IconChevronUp as _0x561f5e,IconChevronDown as _0x4300e8,IconUndo as _0x4cc4d4,IconUser as _0x29cf36,IconThreeVerticalDots as _0x5e73cb}from'@ckeditor/ckeditor5-icons/dist/index.js';import{View as ts,injectCssTransitionDisabler as _0x46a33f,submitHandler as _0x51f4e9,LabeledFieldView as _0xacc8af,createLabeledInputText as _0x5442b6,createDropdown as _0x5f4b44,ListView as _0x5320ef,ListItemView as _0x215dab,ButtonView as te,MenuBarMenuView as _0x444fc6,MenuBarMenuListView as _0x2a7399,MenuBarMenuListItemView as _0x42e37e,MenuBarMenuListItemButtonView as _0x182e41,ContextualBalloon as _0x962635,ToolbarSeparatorView as _0x134577,IconView as _0x2e0193,addListToDropdown as _0x44ae0e,ViewModel as to,EditorUI as st,normalizeToolbarConfig as et,BoxedEditorUIView as rt,StickyPanelView as ht,ToolbarView as dt,InlineEditableUIView as ct}from'@ckeditor/ckeditor5-ui/dist/index.js';import{DateTime as _0x5730c1}from'luxon';class h extends/* #__PURE__ -- @preserve */
24
+ _0x11aaf9(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x3c160d){super(),this['id']=_0x3c160d['id']||_0x19f1f8(),this['creator']=_0x3c160d['creator']||null,this['authors']=_0x3c160d['authors']||[],this['diffData']=_0x3c160d['diffData']||null,this['toVersion']=_0x3c160d['toVersion']||0x0,this['fromVersion']=_0x3c160d['fromVersion']||0x0,this['set']('name',_0x3c160d['name']||''),this['set']('createdAt',_0x3c160d['createdAt']||new Date()),this['set']('attributes',_0x3c160d['attributes']||{});}['setName'](_0x139ee4){this['_update']({'name':_0x139ee4});}['setAttribute'](_0x872cb8,_0x38d341){const _0x4a5fd6=_0x54f69d(this['attributes']);_0x3c8c83(_0x4a5fd6,_0x872cb8,_0x38d341),this['_update']({'attributes':_0x4a5fd6});}['removeAttribute'](_0x377807){const _0x529737=_0x54f69d(this['attributes']);_0x39b3c1(_0x529737,_0x377807),this['_update']({'attributes':_0x529737});}['_update'](_0x2c7da3,_0x16fb00=!0x1){let _0x19c693=!0x1;const _0x357367={'id':this['id']},_0x58ea55=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x2be8d7 of _0x58ea55){const _0x31599a=_0x2c7da3[_0x2be8d7];void 0x0!==_0x31599a&&_0x31599a!==this[_0x2be8d7]&&(this[_0x2be8d7]=_0x31599a,_0x357367[_0x2be8d7]=_0x31599a,_0x19c693=!0x0);}_0x19c693&&(_0x357367['authors']&&(_0x357367['authorsIds']=_0x357367['authors']['map'](_0x166a31=>_0x166a31['id']),delete _0x357367['authors']),this['fire']('_update',_0x357367,_0x16fb00));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x180eae=>_0x180eae['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class I extends _0xc858c4{['_revisions'];static get['requires'](){return[_0x27c92d];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x85f94b){super(_0x85f94b),this['_revisions']=new _0x58fbc2();}['afterInit'](){!async function(_0x46e289){const _0x29bfdc=_0x5aba64([0x66,0x70,0x76,0x72,0x7a,0x31,0x43,0x6d,0x52,0x55,0x54,0x65,0x69,0x53,0x46,0x77,0x38,0x68,0x6b,0x64,0x35,0x58,0x30,0x51,0x73,0x41,0x56,0x6a,0x39,0x33,0x37,0x44,0x4f,0x4b,0x57,0x4c,0x4a,0x50,0x36,0x74,0x5a,0x6c,0x4e,0x49,0x34,0x61,0x59,0x71,0x4d,0x75,0x6e,0x47,0x6f,0x32,0x79,0x42,0x45,0x48,0x63,0x62,0x67,0x78]),_0x478c7f=0xeb829,_0x15a894=0xf3ce7bc,_0x94880c=0xf3b81d4^_0x15a894,_0x5a4d9c=window[_0x5aba64([0x44,0x61,0x74,0x65])][_0x5aba64([0x6e,0x6f,0x77])](),_0x50f42c=_0x46e289[_0x5aba64([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x3ffb7d=new window[(_0x5aba64([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x565170=>{_0x50f42c[_0x5aba64([0x6f,0x6e,0x63,0x65])](_0x5aba64([0x72,0x65,0x61,0x64,0x79]),_0x565170);}),_0x1feae9={[_0x5aba64([0x6b,0x74,0x79])]:_0x5aba64([0x45,0x43]),[_0x5aba64([0x75,0x73,0x65])]:_0x5aba64([0x73,0x69,0x67]),[_0x5aba64([0x63,0x72,0x76])]:_0x5aba64([0x50,0x2d,0x32,0x35,0x36]),[_0x5aba64([0x78])]:_0x5aba64([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]),[_0x5aba64([0x79])]:_0x5aba64([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]),[_0x5aba64([0x61,0x6c,0x67])]:_0x5aba64([0x45,0x53,0x32,0x35,0x36])},_0x3c3e10=_0x50f42c[_0x5aba64([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x5aba64([0x67,0x65,0x74])](_0x5aba64([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x2602be(){let _0x52dfdc,_0xd00e88=null,_0x50758a=null;try{if(_0x3c3e10==_0x5aba64([0x47,0x50,0x4c]))return _0x5aba64([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x52dfdc=_0x2cda6a(),!_0x52dfdc)return _0x5aba64([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x52dfdc[_0x5aba64([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x50758a=_0x3d8922(_0x52dfdc[_0x5aba64([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x52dfdc[_0x5aba64([0x6a,0x74,0x69])])),await _0x4d9b95()?_0xb2fda2()?_0x50e936()?_0x5aba64([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x2151d5()?(_0x52dfdc[_0x5aba64([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x5aba64([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0xd00e88=_0x5af87e(_0x5aba64([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x52dfdc[_0x5aba64([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x5aba64([0x74,0x72,0x69,0x61,0x6c])&&(_0xd00e88=_0x5af87e(_0x5aba64([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x411e9a()):_0x5aba64([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x5aba64([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x5aba64([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch(_0x34438f){return _0x5aba64([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x50e936(){const _0x16e218=[_0x5aba64([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x5aba64([0x74,0x72,0x69,0x61,0x6c])][_0x5aba64([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x52dfdc[_0x5aba64([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x5a4d9c/0x3e8:0xe10*_0x94880c;return _0x52dfdc[_0x5aba64([0x65,0x78,0x70])]<_0x16e218;}function _0xb2fda2(){const _0x1c11c0=_0x52dfdc[_0x5aba64([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x1c11c0)return!0x1;if(_0x1c11c0[_0x5aba64([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x5aba64([0x2a])))return!0x0;if(_0x1c11c0[_0x5aba64([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x5aba64([0x52,0x48])))return!0x0;if(_0x1c11c0[_0x5aba64([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x5aba64([0x52,0x52,0x48]))){if(_0x7418e5())return!0x0;if(_0x1ba3fa()||_0x4465e6())return!0x0;}return!0x1;}function _0x2151d5(){const _0x57e195=_0x52dfdc[_0x5aba64([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x57e195||0x0==_0x57e195[_0x5aba64([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x1a0002}=new URL(window[_0x5aba64([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x57e195[_0x5aba64([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x1a0002))return!0x0;const _0x529c96=_0x1a0002[_0x5aba64([0x73,0x70,0x6c,0x69,0x74])](_0x5aba64([0x2e]));return _0x57e195[_0x5aba64([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x5cb7db=>_0x5cb7db[_0x5aba64([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x5aba64([0x2a])))[_0x5aba64([0x6d,0x61,0x70])](_0x38dfdc=>_0x38dfdc[_0x5aba64([0x73,0x70,0x6c,0x69,0x74])](_0x5aba64([0x2e])))[_0x5aba64([0x73,0x6f,0x6d,0x65])](_0x1112cb=>_0x529c96[_0x5aba64([0x65,0x76,0x65,0x72,0x79])]((_0x42942e,_0xd4b84b)=>_0x1112cb[_0xd4b84b]===_0x42942e||_0x1112cb[_0xd4b84b]===_0x5aba64([0x2a])));}function _0x411e9a(){return _0xd00e88&&_0x50758a?new window[(_0x5aba64([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x4fba3b,_0x367e40)=>{_0xd00e88[_0x5aba64([0x74,0x68,0x65,0x6e])](_0x4fba3b,_0x367e40),_0x50758a[_0x5aba64([0x74,0x68,0x65,0x6e])](_0x55cf4b=>{_0x55cf4b!=_0x5aba64([0x56,0x61,0x6c,0x69,0x64])&&_0x4fba3b(_0x55cf4b);},_0x367e40);}):_0xd00e88||_0x50758a||_0x5aba64([0x56,0x61,0x6c,0x69,0x64]);}}function _0x3d8922(_0x4b373f,_0x4563a8){return new window[(_0x5aba64([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x7124e1=>{if(_0x23528b())return _0x7124e1(_0x5aba64([0x56,0x61,0x6c,0x69,0x64]));_0xdd7081(),_0x50f42c[_0x5aba64([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x5aba64([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x1ada3d=!0x1;const _0xbf93e=_0x19f1f8();function _0x21a9fd(_0x4aaa24){return!!_0x4aaa24&&(typeof _0x4aaa24===_0x5aba64([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x4aaa24===_0x5aba64([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x4aaa24[_0x5aba64([0x74,0x68,0x65,0x6e])]===_0x5aba64([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x4aaa24[_0x5aba64([0x63,0x61,0x74,0x63,0x68])]===_0x5aba64([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x3185d3(_0x5de0b8){_0x28261c(_0x5de0b8)[_0x5aba64([0x74,0x68,0x65,0x6e])](_0x53f970=>{if(!_0x53f970||_0x53f970[_0x5aba64([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x5aba64([0x6f,0x6b]))return _0x5aba64([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x40a50c(_0x49585f(_0xbf93e+_0x4563a8))!=_0x53f970[_0x5aba64([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x5aba64([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x5aba64([0x56,0x61,0x6c,0x69,0x64]);})[_0x5aba64([0x74,0x68,0x65,0x6e])](_0x36e3fb=>(_0x4c8220(),_0x36e3fb),()=>{const _0x4a46c3=_0x1da40f();return null==_0x4a46c3?(_0x4c8220(),_0x5aba64([0x56,0x61,0x6c,0x69,0x64])):_0x5aba64(_0x5a4d9c-_0x4a46c3>(0x2b3063bc^_0x15a894)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x5aba64([0x74,0x68,0x65,0x6e])](_0x7124e1)[_0x5aba64([0x63,0x61,0x74,0x63,0x68])](()=>{_0x7124e1(_0x5aba64([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x1fa18c=0xf0a093c^_0x15a894;function _0x4c8220(){const _0x26c815=_0x5aba64([0x6c,0x6c,0x63,0x74,0x2d])+_0x40a50c(_0x49585f(_0x4b373f)),_0x388381=_0x11a4f3(_0x40a50c(window[_0x5aba64([0x4d,0x61,0x74,0x68])][_0x5aba64([0x63,0x65,0x69,0x6c])](_0x5a4d9c/_0x1fa18c)));window[_0x5aba64([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x5aba64([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x26c815,_0x388381);}function _0x1da40f(){const _0x2b6579=_0x5aba64([0x6c,0x6c,0x63,0x74,0x2d])+_0x40a50c(_0x49585f(_0x4b373f)),_0x2fffd0=window[_0x5aba64([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x5aba64([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x2b6579);return _0x2fffd0?window[_0x5aba64([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x11a4f3(_0x2fffd0),0x10)*_0x1fa18c:null;}function _0x28261c(_0x5d0363){return new window[(_0x5aba64([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x22214b,_0x62c9f0)=>{_0x5d0363[_0x5aba64([0x74,0x68,0x65,0x6e])](_0x22214b,_0x62c9f0),window[_0x5aba64([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x62c9f0,0xf3d337c^_0x15a894);});}}_0x50f42c[_0x5aba64([0x6f,0x6e])](_0x5aba64([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x599887,_0x63ff45)=>{if(_0x63ff45[0x0]!=_0x4b373f)return _0x7124e1(_0x5aba64([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x63ff45[0x1]={..._0x63ff45[0x1],[_0x5aba64([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0xbf93e};},{[_0x5aba64([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x5aba64([0x68,0x69,0x67,0x68])}),_0x50f42c[_0x5aba64([0x6f,0x6e])](_0x5aba64([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x50cc85=>{_0x21a9fd(_0x50cc85[_0x5aba64([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x1ada3d=!0x0,_0x3185d3(_0x50cc85[_0x5aba64([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x5aba64([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x5aba64([0x6c,0x6f,0x77])}),_0x3ffb7d[_0x5aba64([0x74,0x68,0x65,0x6e])](()=>{_0x1ada3d||_0x7124e1(_0x5aba64([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x23528b(){return _0x50f42c[_0x5aba64([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x5aba64([0x76,0x69,0x65,0x77])][_0x5aba64([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x5aba64([0x61,0x75,0x74,0x6f]);}function _0xdd7081(){_0x50f42c[_0x5aba64([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x5aba64([0x76,0x69,0x65,0x77])][_0x5aba64([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x5aba64([0x61,0x75,0x74,0x6f]);}}function _0x5af87e(_0x54cde9){const _0x53376e=[new window[(_0x5aba64([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x5132f9=>setTimeout(_0x5132f9,0xf35d970^_0x15a894)),_0x3ffb7d[_0x5aba64([0x74,0x68,0x65,0x6e])](()=>new window[(_0x5aba64([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x25f90f=>{const _0x450e98=0xf3ce7bb^_0x15a894,_0x5ab28f=_0x46e289[_0x5aba64([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x5619e2(){_0x5ab28f[_0x5aba64([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x450e98&&_0x25f90f();}_0x5619e2(),_0x5ab28f[_0x5aba64([0x6f,0x6e])](_0x5aba64([0x61,0x64,0x64]),_0x5619e2);})),new window[(_0x5aba64([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x3c637a=>{function _0x1fcf0b(){for(const _0x40743a in window)if(window[_0x5aba64([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x5aba64([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x40743a))&&window[_0x40743a]==_0x478c7f)return _0x3c637a();_0x50f42c[_0x5aba64([0x73,0x74,0x61,0x74,0x65])]!=_0x5aba64([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x5aba64([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x1fcf0b,0xf3cf434^_0x15a894);}_0x164a77(_0x5aba64([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x1fcf0b();})];return window[_0x5aba64([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x5aba64([0x72,0x61,0x63,0x65])](_0x53376e)[_0x5aba64([0x74,0x68,0x65,0x6e])](()=>_0x54cde9);}async function _0x104e3a(){if(await _0x3ffb7d,_0x164a77(_0x5aba64([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x1e7a30=_0x46e289[_0x5aba64([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x11f653=_0x46e289[_0x5aba64([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])](_0x1e7a30[_0x5aba64([0x69,0x64])]),_0x3c2fea=_0x5199dc(_0x5aba64([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x3c2fea[_0x5aba64([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x1e7a30['id'],_0x11f653?_0x11f653['id']:null,!0x0),_0x3c2fea[_0x5aba64([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x5aba64([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x3c2fea[_0x5aba64([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x3c2fea[_0x5aba64([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x590fa6,void(_0x3c2fea[_0x5aba64([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x590fa6);}if(_0x164a77(_0x5aba64([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x53351=_0x5199dc(_0x5aba64([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x53351[_0x5aba64([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x5aba64([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x53351[_0x5aba64([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x53351[_0x5aba64([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x590fa6,_0x53351[_0x5aba64([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x590fa6;}_0x50f42c[_0x5aba64([0x6d,0x6f,0x64,0x65,0x6c])][_0x5aba64([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x590fa6,_0x50f42c[_0x5aba64([0x6d,0x6f,0x64,0x65,0x6c])][_0x5aba64([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x590fa6,_0x50f42c[_0x5aba64([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x5aba64([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x7418e5(){return _0x164a77(_0x5aba64([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x5199dc(_0x5aba64([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x5aba64([0x73,0x74,0x61,0x74,0x65])]==_0x5aba64([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x1ba3fa(){return _0x164a77(_0x5aba64([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 _0x4465e6(){return _0x164a77(_0x5aba64([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x262afc(_0x3f81bd){const _0x1542af=_0x25cdc3();_0x50f42c[_0x1542af]=_0x5aba64([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])+_0x3f81bd,_0x3f81bd[_0x5aba64([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x5aba64([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x25cdc3()]=_0x478c7f),_0x3f81bd!=_0x5aba64([0x56,0x61,0x6c,0x69,0x64])&&_0x104e3a();}function _0x25cdc3(){const _0x5256b1=window[_0x5aba64([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x5aba64([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x5aba64([0x6e,0x6f,0x77])]())[_0x5aba64([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x5aba64([0x2e]),'');let _0x457ca3=_0x5aba64([0x66]);for(let _0x557d83=0x0;_0x557d83<_0x5256b1[_0x5aba64([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x557d83+=0x2){let _0x2fafca=window[_0x5aba64([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x5256b1[_0x5aba64([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x557d83,_0x557d83+0x2));_0x2fafca>=_0x29bfdc[_0x5aba64([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x2fafca-=_0x29bfdc[_0x5aba64([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x457ca3+=_0x29bfdc[_0x2fafca];}return _0x457ca3;}function _0x2cda6a(){const _0x24a86=_0x3c3e10[_0x5aba64([0x73,0x70,0x6c,0x69,0x74])](_0x5aba64([0x2e]));if(0x3!=_0x24a86[_0x5aba64([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x1f7849(_0x24a86[0x1]);function _0x1f7849(_0x2b7f6a){const _0x2bf260=_0x19c548(_0x2b7f6a);return _0x2bf260&&_0x51ec79()?_0x2bf260:null;function _0x51ec79(){const _0x12d07d=_0x2bf260[_0x5aba64([0x6a,0x74,0x69])],_0x6b79eb=window[_0x5aba64([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x12d07d[_0x5aba64([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x12d07d[_0x5aba64([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x36ec77={..._0x2bf260,[_0x5aba64([0x6a,0x74,0x69])]:_0x12d07d[_0x5aba64([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x12d07d[_0x5aba64([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x36ec77[_0x5aba64([0x76,0x63])],_0x49585f(_0x36ec77)==_0x6b79eb;}}}async function _0x4d9b95(){let _0x54bc90=!0x0;try{const _0x5705cd=_0x3c3e10[_0x5aba64([0x73,0x70,0x6c,0x69,0x74])](_0x5aba64([0x2e])),[_0x308924,_0x208a14,_0x305aac]=_0x5705cd;return _0x54f968(_0x308924),await _0x1fefb1(_0x308924,_0x208a14,_0x305aac),_0x54bc90;}catch(_0x4ae01f){return!0x1;}function _0x54f968(_0x52c45e){const _0x4aae44=_0x19c548(_0x52c45e);_0x4aae44&&_0x4aae44[_0x5aba64([0x61,0x6c,0x67])]==_0x5aba64([0x45,0x53,0x32,0x35,0x36])||(_0x54bc90=!0x1);}async function _0x1fefb1(_0x74cf8,_0x2f033c,_0x444668){const _0x7a3c90=window[_0x5aba64([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x5aba64([0x66,0x72,0x6f,0x6d])](_0x26da1f(_0x444668),_0x13bcc2=>_0x13bcc2[_0x5aba64([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0xfbeb66=new window[(_0x5aba64([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x5aba64([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x74cf8+_0x5aba64([0x2e])+_0x2f033c),_0x56e8e3=window[_0x5aba64([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x5aba64([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x56e8e3)return;const _0x3a2cef=await _0x56e8e3[_0x5aba64([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x5aba64([0x6a,0x77,0x6b]),_0x1feae9,{[_0x5aba64([0x6e,0x61,0x6d,0x65])]:_0x5aba64([0x45,0x43,0x44,0x53,0x41]),[_0x5aba64([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x5aba64([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x5aba64([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x56e8e3[_0x5aba64([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x5aba64([0x6e,0x61,0x6d,0x65])]:_0x5aba64([0x45,0x43,0x44,0x53,0x41]),[_0x5aba64([0x68,0x61,0x73,0x68])]:{[_0x5aba64([0x6e,0x61,0x6d,0x65])]:_0x5aba64([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x3a2cef,_0x7a3c90,_0xfbeb66)||(_0x54bc90=!0x1);}}function _0x19c548(_0x3a520f){return _0x3a520f[_0x5aba64([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x5aba64([0x65,0x79]))?JSON[_0x5aba64([0x70,0x61,0x72,0x73,0x65])](_0x26da1f(_0x3a520f)):null;}function _0x26da1f(_0x3b5c64){return window[_0x5aba64([0x61,0x74,0x6f,0x62])](_0x3b5c64[_0x5aba64([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x5aba64([0x2b]))[_0x5aba64([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x5aba64([0x2f])));}function _0x49585f(_0x133caa){let _0x3cbdfa=0x1505;function _0x2a8452(_0x129f3e){for(let _0x23e361=0x0;_0x23e361<_0x129f3e[_0x5aba64([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x23e361++){const _0x52a0fc=_0x129f3e[_0x5aba64([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x23e361);_0x3cbdfa=(_0x3cbdfa<<0x5)+_0x3cbdfa+_0x52a0fc,_0x3cbdfa&=_0x3cbdfa;}}function _0x289389(_0x1b2c60){Array[_0x5aba64([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x1b2c60)?_0x1b2c60[_0x5aba64([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x289389):_0x1b2c60&&typeof _0x1b2c60==_0x5aba64([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x5aba64([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x1b2c60)[_0x5aba64([0x73,0x6f,0x72,0x74])]()[_0x5aba64([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0xa11949,_0x3f1c40])=>{_0x2a8452(_0xa11949),_0x289389(_0x3f1c40);}):_0x2a8452(window[_0x5aba64([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x1b2c60));}return _0x289389(_0x133caa),_0x3cbdfa>>>0x0;}function _0x40a50c(_0x339765){return _0x339765[_0x5aba64([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x5aba64([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x5aba64([0x30]));}function _0x11a4f3(_0x541ac2){return _0x541ac2[_0x5aba64([0x73,0x70,0x6c,0x69,0x74])]('')[_0x5aba64([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x5aba64([0x6a,0x6f,0x69,0x6e])]('');}function _0x164a77(_0x41196e){return _0x50f42c[_0x5aba64([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x5aba64([0x68,0x61,0x73])](_0x41196e);}function _0x5199dc(_0x19ad76){return _0x50f42c[_0x5aba64([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x5aba64([0x67,0x65,0x74])](_0x19ad76);}function _0x590fa6(){}function _0x5aba64(_0x3ee344){return _0x3ee344['map'](_0x6f62ad=>String['fromCharCode'](_0x6f62ad))['join']('');}_0x262afc(await _0x2602be());}(this);}['createRevision'](_0x37663c){const _0x3efebd=this['editor']['plugins']['get']('Users');return new h({'id':_0x37663c['id'],'name':_0x37663c['name'],'creator':_0x37663c['creatorId']?_0x3efebd['getUser'](_0x37663c['creatorId']):null,'diffData':_0x37663c['diffData']||_0x37663c['data'],'authors':_0x37663c['authorsIds']['map'](_0x3584e3=>_0x3efebd['getUser'](_0x3584e3)),'createdAt':new Date(_0x37663c['createdAt']),'attributes':_0x37663c['attributes'],'fromVersion':_0x37663c['fromVersion'],'toVersion':_0x37663c['toVersion']});}['addRevision'](_0x52852f,_0x55178e=0x0){this['_revisions']['add'](_0x52852f,_0x55178e);}['getRevision'](_0x301e0d){return this['_revisions']['get'](_0x301e0d);}['getRevisions'](_0x35fd3e={'toJSON':!0x1}){const _0x7e8203=Array['from'](this['_revisions']);return _0x7e8203['reverse'](),_0x35fd3e['toJSON']?_0x7e8203['map'](_0x21b377=>_0x21b377['toJSON']()):_0x7e8203;}['getIndex'](_0x4007c8){return this['_revisions']['getIndex'](_0x4007c8);}['getEarlierVisibleRevision'](_0x31cf5c){const [,_0x41750f]=this['getRevisionsIterator'](_0x31cf5c,{'direction':'earlier'});return _0x41750f;}['getLaterVisibleRevision'](_0xa6cee6){const [,_0x37e405]=this['getRevisionsIterator'](_0xa6cee6,{'direction':'later'});return _0x37e405;}['getRevisionsInDiff'](_0xffee14){const _0x30ea8b=[];for(const _0x403648 of this['getRevisionsIterator'](_0xffee14['newRevisionId']))if(_0x30ea8b['push'](_0x403648),_0x403648['id']===_0xffee14['oldRevisionId'])break;return _0x30ea8b;}*['getRevisionsIterator'](_0x3a8b58,{direction:_0x4181ea='earlier',filter:_0x597410=()=>!0x0}={}){const _0x12f1f0='earlier'===_0x4181ea?0x1:-0x1;let _0x50d3ea=this['_revisions']['get'](_0x3a8b58),_0x39d02a=this['getIndex'](_0x50d3ea);for(yield _0x50d3ea;_0x50d3ea;){if(_0x39d02a+=_0x12f1f0,_0x50d3ea=this['getRevision'](_0x39d02a),!_0x50d3ea)return;_0x597410(_0x50d3ea)&&(yield _0x50d3ea);}}}class V extends _0xc858c4{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x33ae4a,'c'],[_0x343ac3,'a'],[_0x363faa,'e'],[_0x4f743a,'r'],[_0x37d218,'u']]);['_typeCharToViewClass']=new Map([['c',_0x33ae4a],['a',_0x343ac3],['e',_0x363faa],['r',_0x4f743a],['u',_0x37d218]]);async['loadRevisionData'](_0xec7c84,_0x33ce00){if(_0xec7c84['diffData']||!_0x33ce00)return;const _0xbec91a=this['editor']['config']['get']('collaboration.channelId'),_0x2fb7ea=await _0x33ce00['getRevision']({'channelId':_0xbec91a,'revisionId':_0xec7c84['id']});_0xec7c84['diffData']=_0x2fb7ea['diffData'];}['getRevisionDocumentData'](_0x2597c4){const _0x3ac074={};for(const _0x484dc3 in _0x2597c4['diffData']){if(_0x2597c4['diffData'][_0x484dc3]['attachChange']&&!_0x2597c4['diffData'][_0x484dc3]['attachChange']['isAttached'])continue;const _0x5906e5=this['_removeRevisionMarkers'](JSON['parse'](_0x2597c4['diffData'][_0x484dc3]['insertions'])),_0x2a3caa=this['editor']['editing']['view']['document'],_0x19fdba=new _0x34ebf2(_0x2a3caa,_0x5906e5['map'](_0x5462c6=>this['_getViewFromDiffObj'](_0x5462c6,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x3ac074[_0x484dc3]=this['editor']['data']['processor']['toData'](_0x19fdba),this['editor']['data']['processor']['useFillerType']('default');}return _0x3ac074;}['getRevisionRootsAttributes'](_0x587212){const _0x1599c4={};for(const _0x36c0c5 in _0x587212['diffData'])_0x587212['diffData'][_0x36c0c5]['attachChange']&&!_0x587212['diffData'][_0x36c0c5]['attachChange']['isAttached']||(_0x1599c4[_0x36c0c5]=_0x587212['diffData'][_0x36c0c5]['attributesAfter']||{});return _0x1599c4;}['_getTypeCharForViewElement'](_0x9be74){return this['_viewClassToTypeChar']['get'](_0x9be74['constructor']);}['_getViewFromDiffObj'](_0x250c35,_0x2d4b0d){const _0xce3400=this['editor']['editing']['view']['document'];if('string'==typeof _0x250c35)return new _0x21dd2f(_0xce3400,_0x250c35);{let _0x38a6b6,_0x3c93bb;_0x3c93bb='u'==_0x250c35['type']||'r'==_0x250c35['type']?[]:_0x250c35['children']['map'](_0xdd4262=>this['_getViewFromDiffObj'](_0xdd4262,_0x2d4b0d));const _0x2963ea=this['_typeCharToViewClass']['get'](_0x250c35['type'])||_0x390be8,_0x50812b=this['editor']['data']['htmlProcessor']['domConverter'];if(_0x38a6b6=new _0x2963ea(_0xce3400,_0x250c35['name'],_0x250c35['attributes'],_0x3c93bb),'u'==_0x250c35['type']&&_0x250c35['children'][0x0]){const _0x58eb9b=_0x250c35['children'][0x0];if(_0x38a6b6['render']=function(_0x3c3fff){const _0x51e0da=_0x3c3fff['createElement']('div');return _0x51e0da['innerHTML']=_0x58eb9b,_0x51e0da['childNodes'][0x0];},_0x2d4b0d){const _0x1a4212=new _0x34ebf2(_0xce3400);_0x1a4212['_appendChild'](_0x38a6b6);const _0x3773ad=Array['from'](_0x50812b['viewChildrenToDom'](_0x1a4212,{'bind':!0x1})),_0x1d8748=_0x50812b['domDocument']['createElement']('div');_0x1d8748['append'](..._0x3773ad),_0x38a6b6=Array['from'](_0x50812b['domChildrenToView'](_0x1d8748))[0x0];}}else{if('r'==_0x250c35['type']&&_0x250c35['children'][0x0]){const _0x3c20ae=_0x250c35['children'][0x0];if(_0x38a6b6['render']=function(_0x1f4ac6){_0x1f4ac6['innerHTML']=_0x3c20ae;},_0x2d4b0d){const _0xaa0113=new _0x34ebf2(_0xce3400);_0xaa0113['_appendChild'](_0x38a6b6);const _0x6b0f5f=Array['from'](_0x50812b['viewChildrenToDom'](_0xaa0113,{'bind':!0x1})),_0x31f9bf=_0x50812b['domDocument']['createElement']('div');_0x31f9bf['append'](..._0x6b0f5f);const _0x45d051=Array['from'](_0x50812b['domChildrenToView'](_0x31f9bf));_0x45d051['length']>0x1?_0x38a6b6['_appendChild'](_0x45d051):_0x38a6b6=_0x45d051[0x0];}}}if(_0x250c35['customProperties']){for(const [_0x206b17,_0x4260c7]of _0x250c35['customProperties'])_0x38a6b6['_setCustomProperty'](_0x206b17,_0x4260c7);}const _0x474181=void 0x0===_0x250c35['fillerOffset']?null:_0x250c35['fillerOffset'];return null!==_0x474181&&(_0x38a6b6['getFillerOffset']=()=>_0x474181),_0x38a6b6;}}['_makeModelFromViewString'](_0x139fdc){const _0x22ad92=JSON['parse'](_0x139fdc),_0x2c254b=this['editor']['editing']['view']['document'],_0x399aa9=new _0x34ebf2(_0x2c254b,_0x22ad92['map'](_0x424cff=>this['_getViewFromDiffObj'](_0x424cff,!0x0)));return this['editor']['data']['toModel'](_0x399aa9);}['_removeRevisionMarkers'](_0x337d35){return(_0x337d35=_0x337d35['filter'](_0x33a5a8=>!_0x33a5a8['name']||'revision-start'!==_0x33a5a8['name']&&'revision-end'!==_0x33a5a8['name']))['forEach'](_0x376c1a=>{'string'!=typeof _0x376c1a&&(_0x376c1a['children']=this['_removeRevisionMarkers'](_0x376c1a['children']),_0x376c1a['attributes']=_0x376c1a['attributes']['filter'](_0x384487=>!_0x384487[0x0]['startsWith']('data-revision-')));}),_0x337d35;}}function g(_0x31c67c,_0x58385e,_0x53b528){const t=_0x31c67c['t'];switch(_0x58385e){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'},_0x53b528);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x53b528);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 u extends _0xc858c4{['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[_0x27c92d,I,V,_0x2c2110];}constructor(_0x1d9046){super(_0x1d9046),this['repository']=this['editor']['plugins']['get']('RevisionsRepository'),this['_utils']=this['editor']['plugins']['get']('RevisionHistoryUtils'),this['_revisionDataBuilder']=new x(this['editor']),this['_initialRevisionId']=this['editor']['config']['get']('collaboration.channelId')||'initial',this['_bufferedUpdates']=new Map(),this['_loadedStateData']=null;const _0x568b58=_0x19f1f8();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x568b58},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 _0x4f14f3=this['repository']['getRevision'](0x0),_0x3c228e=_0x4f14f3&&null===_0x4f14f3['creator']?_0x4f14f3:null;if(this['_continueCurrentRevision']=!!_0x3c228e&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x906072=this['_source']['getCurrentRevisionId'](),_0x5a1120=this['repository']['getRevision'](_0x906072);if(_0x5a1120)this['_startingVersion']=_0x5a1120['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x3dbafc=this['_source']['history']['_operations']['find'](_0x42d9d7=>!_0x42d9d7['_isInit']),_0x15a0f2=_0x3dbafc?_0x3dbafc['baseVersion']:this['_source']['history']['version'];_0x4f14f3?(_0x4f14f3['toVersion']<_0x15a0f2&&_0x4f14f3['_update']({'toVersion':_0x15a0f2}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x3c228e['id'],this['_startingVersion']=_0x3c228e['fromVersion']):(this['_startingVersion']=_0x4f14f3['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x15a0f2,this['_continueCurrentRevision']=!0x1);}}else _0x3c228e&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x3c228e['toVersion'],this['editor']['model']['document']['history']['version']),_0x3c228e['fromVersion']===_0x3c228e['toVersion']?(0x0!==_0x3c228e['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x3c228e['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x3c228e['id'],this['_startingVersion']=_0x3c228e['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',_0x4ae295=>!_0x4ae295),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x40767a=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x3903a5;for(const _0x4398d9 in _0x40767a){const _0x57e0f0=_0x4398d9,_0xa3212a=_0x40767a[_0x57e0f0];if('revisionHistoryLicenseKeyValid'==_0xa3212a||'revisionHistoryLicenseKeyInvalid'==_0xa3212a||'revisionHistoryLicenseKeyExpired'==_0xa3212a||'revisionHistoryLicenseKeyDomainLimit'==_0xa3212a||'revisionHistoryLicenseKeyNotAllowed'==_0xa3212a||'revisionHistoryLicenseKeyEvaluationLimit'==_0xa3212a||'revisionHistoryLicenseKeyTrialLimit'==_0xa3212a||'revisionHistoryLicenseKeyUsageLimit'==_0xa3212a){delete _0x40767a[_0x57e0f0],_0x3903a5=_0xa3212a,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x3903a5&&_0x40767a['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x3903a5&&_0x40767a['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x3903a5&&_0x40767a['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x3903a5&&_0x40767a['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x3903a5&&_0x40767a['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x3903a5&&_0x40767a['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x3903a5&&_0x40767a['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x4058fc=this['repository']['getRevision'](0x0),_0x5a839c=await this['getRevisionDocumentData'](_0x4058fc),_0x111702=await this['getRevisionRootsAttributes'](_0x4058fc);this['_replaceEditorDataWithRevisionData'](_0x5a839c,_0x111702);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x3c4b8f){this['_source']=_0x3c4b8f;}async['update'](){const _0x346ee8=await this['_source']['getLatestVersion']();if(_0x346ee8>this['currentRevision']['toVersion']){await this['_loadState']();const _0x1697ef=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x346ee8});_0x1697ef['authors']=_0x1697ef['authorsIds']['map'](_0xcd495a=>this['editor']['plugins']['get']('Users')['getUser'](_0xcd495a)),this['currentRevision']['_update'](_0x1697ef);}}async['saveRevision'](_0xbd04e9={},_0x3618c9=null){const _0x405009=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x3618c9>this['currentRevision']['toVersion']&&(_0x3618c9=null),null===_0x3618c9&&(_0x3618c9=await this['_source']['getLatestVersion']());const _0x27ea4b=this['_getFromVersion'](_0x3618c9),_0x1045f5=this['buildRevisionData']({'from':_0x27ea4b,'to':_0x3618c9});if(this['currentRevision']['toVersion']<_0x3618c9){const _0x140062=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x3618c9,'to':_0x3618c9});_0x140062['authors']=[],_0x140062['authorsIds']=[],_0x140062['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x140062,!0x0),delete _0x140062['authors'],_0x405009['push'](_0x140062);}_0xbd04e9['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0xbd04e9['name']=_0xbd04e9['name']||null,_0xbd04e9['id']=_0xbd04e9['id']||_0x19f1f8(),_0xbd04e9={..._0xbd04e9,..._0x1045f5};const _0x5572ad=this['addRevisionData'](_0xbd04e9);_0x405009['push'](_0xbd04e9);const _0x50dd59=this['repository']['getIndex'](_0x5572ad);if(0x0!==_0x50dd59){const _0x3c70b5=this['repository']['getRevision'](_0x50dd59-0x1);if(_0x3c70b5['fromVersion']!==_0x3618c9){const _0x327492=this['_revisionDataBuilder']['getData'](_0x3618c9,_0x3c70b5['toVersion']),_0x1502ea={'id':_0x3c70b5['id'],'diffData':_0x327492['diffData'],'authorsIds':_0x327492['authorsIds'],'authors':_0x327492['authorsIds']['map'](_0x286387=>this['editor']['plugins']['get']('Users')['getUser'](_0x286387)),'fromVersion':_0x3618c9};_0x3c70b5===this['currentRevision']&&(_0x1502ea['createdAt']=new Date(_0xbd04e9['createdAt']['getTime']()+0xa)),_0x3c70b5['_update'](_0x1502ea,!0x0),delete _0x1502ea['authors'],_0x405009['push'](_0x1502ea);}}if(this['adapter']){for(const _0x33ceca of _0x405009)this['_bufferUpdate'](_0x33ceca['id'],_0x33ceca,!0x0);this['sendBufferedUpdates']();}return _0x5572ad;}['addRevisionData'](_0x1cbbb7){const _0x1464a0=this['repository']['createRevision'](_0x1cbbb7);return this['adapter']&&_0x1464a0['on']('_update',(_0x3fbf69,_0x28bb22,_0x4d72ce)=>{_0x4d72ce||(this['_bufferUpdate'](_0x28bb22['id'],_0x28bb22,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x1464a0,this['_findInsertionIndex'](_0x1464a0)),_0x1464a0;}async['getRevisionDocumentData'](_0x44aefd){return await this['_utils']['loadRevisionData'](_0x44aefd,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x44aefd);}async['getRevisionRootsAttributes'](_0x563c4e){return await this['_utils']['loadRevisionData'](_0x563c4e,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x563c4e);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x4143a7=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x21c763=0x0;_0x21c763<_0x4143a7['length'];_0x21c763++){const _0xfc8f4=_0x4143a7[_0x21c763];let _0x13b7d4=!0x1;for(const _0x48453d of Object['keys'](_0xfc8f4))void 0x0===_0xfc8f4[_0x48453d]?delete _0xfc8f4[_0x48453d]:'id'!==_0x48453d&&(_0x13b7d4=!0x0);_0x13b7d4||(_0x4143a7[_0x21c763]=null);}if(_0x4143a7=_0x4143a7['filter'](_0x40c71c=>null!==_0x40c71c),!_0x4143a7['length'])return;for(let _0x443c4a=0x0;_0x443c4a<_0x4143a7['length'];_0x443c4a++){const _0x5d97c0=_0x4143a7[_0x443c4a];void 0x0!==_0x5d97c0['fromVersion']&&void 0x0===_0x5d97c0['toVersion']&&(_0x5d97c0['toVersion']=this['repository']['getRevision'](_0x5d97c0['id'])['toVersion']),void 0x0!==_0x5d97c0['toVersion']&&void 0x0===_0x5d97c0['fromVersion']&&(_0x5d97c0['fromVersion']=this['repository']['getRevision'](_0x5d97c0['id'])['fromVersion']);}const _0x457661=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x4143a7,_0x457661)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x412f6f=>{if(_0x412f6f){for(const _0x2089ab of _0x412f6f)this['setRevisionData']({'id':_0x2089ab['id'],'createdAt':_0x2089ab['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0x3659b5=null,from:_0x30cdb5=null,to:_0x57dd53=null}){_0x30cdb5=null!==_0x30cdb5?_0x30cdb5:_0x3659b5['fromVersion'],_0x57dd53=null!==_0x57dd53?_0x57dd53:_0x3659b5['toVersion'];const _0x2079b7=this['_revisionDataBuilder']['getData'](_0x30cdb5,_0x57dd53),_0x28a51d={'diffData':_0x2079b7['diffData'],'authorsIds':_0x2079b7['authorsIds'],'fromVersion':_0x30cdb5,'toVersion':_0x57dd53};if(!_0x3659b5||_0x57dd53!==_0x3659b5['toVersion']){const _0x494a88=_0x57dd53-0x1,_0x2653cb=this['_source']['history']['getOperation'](_0x494a88);_0x28a51d['createdAt']=_0x2653cb&&_0x2653cb['createdAt']||new Date();}if(this['_loadedStateData']&&_0x30cdb5===this['_loadedStateData']['fromVersion']){for(const _0x575f07 of this['_loadedStateData']['authors'])_0x28a51d['authorsIds']['includes'](_0x575f07['id'])||_0x28a51d['authorsIds']['push'](_0x575f07['id']);}return _0x28a51d;}['_bufferUpdate'](_0x23e498,_0xa5edd1,_0x175049){if(this['_bufferedUpdates']['has'](_0x23e498)){const _0x649e3=this['_bufferedUpdates']['get'](_0x23e498);_0xa5edd1=_0x175049?{..._0x649e3,..._0xa5edd1}:{..._0xa5edd1,..._0x649e3};}this['_bufferedUpdates']['set'](_0x23e498,_0xa5edd1);}['setRevisionData'](_0x356536){const _0x38bde5=this['repository']['getRevision'](_0x356536['id']);if(_0x356536['createdAt']&&(_0x356536['createdAt']=new Date(_0x356536['createdAt'])),_0x356536['authorsIds']){const _0xb53ba6=this['editor']['plugins']['get']('Users');_0x356536['authors']=_0x356536['authorsIds']['map'](_0x3f3ecd=>_0xb53ba6['getUser'](_0x3f3ecd));}_0x38bde5['_update'](_0x356536,!0x0);}['_createInitialRevision'](_0x3a25b4){const _0x17d87d=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x17d87d)this['_initialRevisionId']=_0x17d87d['id'];else{const _0x1f49f1=!this['editor']['model']['document']['roots']['find'](_0x4953e9=>this['editor']['model']['hasContent'](_0x4953e9)),_0x56b1d3=this['editor']['plugins']['get']('Users')['me']['id'],_0x35ab16=g(this['editor']['locale'],_0x1f49f1?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x3a25b4,'to':_0x3a25b4,'id':this['_initialRevisionId'],'name':_0x35ab16,'creatorId':_0x56b1d3});}}['_createCurrentRevision'](_0x3745a1){const _0x2cabff=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x2cabff),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x3745a1,'to':_0x3745a1,'id':_0x2cabff,'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'](_0x313c98,_0x1eab5a){let _0x5eca31=this['editor']['config']['get']('initialData'),_0x2a3cfc=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x5eca31){_0x5eca31={};for(const _0x37b3bf of this['editor']['model']['document']['getRootNames']())_0x5eca31[_0x37b3bf]='';}if('string'==typeof _0x5eca31&&(_0x5eca31={'main':_0x5eca31}),void 0x0===_0x2a3cfc){_0x2a3cfc={};for(const _0xc7a53 of this['editor']['model']['document']['getRootNames']())_0x2a3cfc[_0xc7a53]={};}let _0x337586=!0x1;const _0x1e6593=Object['keys'](_0x5eca31),_0x2e310f=Object['keys'](_0x313c98);for(const _0x501f17 of _0x1e6593){if(_0x5eca31[_0x501f17]!==_0x313c98[_0x501f17]&&''!==_0x5eca31[_0x501f17]['trim']()){_0x337586=!0x0;break;}if(!_0x73df34(_0x2a3cfc[_0x501f17],_0x1eab5a[_0x501f17])&&Object['keys'](_0x2a3cfc[_0x501f17])['length']>0x0){_0x337586=!0x0;break;}}_0x337586||(_0x337586=_0x2e310f['some'](_0x47cd78=>!this['editor']['model']['document']['getRoot'](_0x47cd78))),_0x337586&&_0x9f97ee('editor-initial-data-replaced-with-revision-data',{'editorData':_0x5eca31,'editorRootsAttributes':_0x2a3cfc,'revisionData':_0x313c98,'revisionRootsAttributes':_0x1eab5a}),this['editor']['config']['set']('initialData',_0x313c98),this['editor']['config']['set']('rootsAttributes',_0x1eab5a);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x52da5f=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x52da5f['add'](g(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x4da092){const _0x4e5d7a=this['repository']['getRevisions']();_0x4e5d7a['reverse']();let _0xe7eec4=0x0;for(;_0xe7eec4<_0x4e5d7a['length'];){const _0x23ce38=_0x4e5d7a[_0xe7eec4];if(_0x23ce38===this['currentRevision']){_0xe7eec4++;continue;}if(_0x23ce38['id']===this['_initialRevisionId'])break;const _0x208d05=_0x4da092['toVersion']-_0x23ce38['toVersion']||_0x4da092['fromVersion']-_0x23ce38['fromVersion'];if(_0x208d05>0x0)break;if(_0x208d05<0x0)_0xe7eec4++;else{if(!_0x4da092['creator']&&_0x23ce38['creator'])break;if(_0x23ce38['creator']||!_0x4da092['creator']){if(_0x4da092['createdAt']>_0x23ce38['createdAt'])break;_0xe7eec4++;}else _0xe7eec4++;}}return _0xe7eec4;}['_getFromVersion'](_0x3855ab){const _0x34952c=this['repository']['getRevisions']();_0x34952c['reverse'](),_0x34952c['shift']();const _0x1bf69d=_0x34952c['find'](_0x5ef564=>_0x5ef564['toVersion']<=_0x3855ab)['toVersion'];return _0x1bf69d<this['_startingVersion']?this['_startingVersion']:_0x1bf69d;}['_makeRevision']({name:_0x418b1c,from:_0x23c46b,to:_0x477443,creatorId:_0x4806de,id:_0x20054b}){const _0xdfc9ba=this['buildRevisionData']({'from':_0x23c46b,'to':_0x477443});_0xdfc9ba['name']=_0x418b1c,_0xdfc9ba['creatorId']=_0x4806de,_0xdfc9ba['id']=_0x20054b;const _0x5cd572=this['addRevisionData'](_0xdfc9ba);return this['adapter']&&this['_bufferUpdate'](_0xdfc9ba['id'],_0xdfc9ba,!0x0),_0x5cd572;}['_setConversion'](){this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'});}}class x{['editor'];['source'];['_savedMetaData'];['_lastFrom'];['_lastTo'];['_markers'];['_diffRoots'];['_diffRootsAttributes'];['_baseRoots'];['_baseRootsAttributes'];['_idsRoots'];['_baseIdsRoots'];['_touched'];['_touchedMarkers'];['_touchedRoots'];['_revisionId'];['_startingRevisionId'];constructor(_0x1da8c0){this['editor']=_0x1da8c0,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'](_0x543a04){this['source']=_0x543a04;const _0x51ed07=new Map(),_0x513999=new Map(),_0x31f6cb=this['editor']['model']['document']['roots']['map'](_0x1b00f2=>_0x1b00f2['rootName']);for(const _0x1df524 of _0x31f6cb){const _0x3e8d54=this['editor']['model']['document']['getRoot'](_0x1df524),_0x1a4442=N(_0x3e8d54);_0x51ed07['set'](_0x1df524,_0x1a4442),_0x513999['set'](_0x1df524,Object['fromEntries'](_0x3e8d54['getAttributes']()));}const _0x442967=Array['from'](this['editor']['model']['markers'])['map'](_0x324f6e=>[_0x324f6e['name'],_0x324f6e['getRange']()]),_0x5aba8c=this['source']['version'];this['_saveMetaData'](_0x5aba8c,_0x51ed07,_0x442967,_0x513999),this['_startingRevisionId']=this['_revisionId'];const _0xdbcb16=new Map(),_0x2714aa=new Map();for(const _0x21685f of _0x31f6cb){const _0x1b0b81=P(_0x21685f);_0xdbcb16['set'](_0x21685f,_0x1b0b81),_0x2714aa['set'](_0x21685f,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0xdbcb16,[],_0x2714aa);}['getData'](_0x2d342c,_0x78af48){if(this['_lastFrom']===_0x2d342c&&this['_lastTo']<=_0x78af48)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x78af48,!0x0);else{if(!this['_savedMetaData']['has'](_0x2d342c)){const _0x4167f5=this['_getPreviousFrom'](_0x2d342c);this['_calculateMetaData'](_0x4167f5,_0x2d342c,!0x1);}this['_calculateMetaData'](_0x2d342c,_0x78af48,!0x0);}return this['_lastFrom']=_0x2d342c,this['_lastTo']=_0x78af48,this['_getState']();}['loadState'](_0x2dacfc){const _0x2e984f=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x2dacfc['fromVersion'],this['_lastTo']=_0x2dacfc['toVersion'];for(const _0x4d2054 in _0x2dacfc['diffData']){const _0x167a65=_0x2dacfc['diffData'][_0x4d2054]['attachChange'],_0x248e9b=_0x54f69d(_0x2dacfc['diffData'][_0x4d2054]['attributesBefore'])||{},_0x3bceb2=_0x2e984f['_makeModelFromViewString'](_0x2dacfc['diffData'][_0x4d2054]['deletions']);_0x3bceb2['rootName']=_0x4d2054,_0x3bceb2['_isAttached']=!_0x167a65||!_0x167a65['isAttached'],_0x3bceb2['isAttached']=()=>_0x3bceb2['_isAttached'],this['_baseRoots']['set'](_0x4d2054,_0x3bceb2),this['_baseRootsAttributes']['set'](_0x4d2054,_0x248e9b),_0x167a65&&this['_touchedRoots']['set'](_0x4d2054,_0x167a65);const _0x485893=this['_makeIdsRoot'](_0x3bceb2);this['_baseIdsRoots']['set'](_0x4d2054,_0x485893);for(const [_0x579e04,_0x273c66]of _0x3bceb2['markers']){if(!_0x579e04['startsWith']('revision:'))continue;const _0x25f6f0=_0x579e04['split'](':')[0x2];for(const _0xbc2bd4 of _0x273c66['getWalker']({'singleCharacters':!0x0})){const _0x4a2663=this['_getVidAttributeName'](_0xbc2bd4),_0x29c95e='elementEnd'==_0xbc2bd4['type']?_0xbc2bd4['previousPosition']['path']['slice'](0x0,-0x1):_0xbc2bd4['previousPosition']['path'],_0x13448c=_0x485893['getNodeByPath'](_0x29c95e)['getAttribute'](_0x4a2663);this['_touched']['set'](_0x13448c,{'userId':_0x25f6f0});}}}this['_startingRevisionId']=this['_revisionId'];const _0x27fb75=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x2e7573=>!this['_touched']['has'](_0x2e7573));let _0xb010be=0x0;const _0x44961a=new Map();for(const _0x5e12fe in _0x2dacfc['diffData']){const _0x154da0=_0x2dacfc['diffData'][_0x5e12fe]['attachChange'],_0x1614f0=_0x54f69d(_0x2dacfc['diffData'][_0x5e12fe]['attributesAfter'])||{},_0x216368=_0x2e984f['_makeModelFromViewString'](_0x2dacfc['diffData'][_0x5e12fe]['insertions']);_0x216368['rootName']=_0x5e12fe,_0x216368['_isAttached']=!_0x154da0||_0x154da0['isAttached'],_0x216368['isAttached']=()=>_0x216368['_isAttached'],this['_diffRoots']['set'](_0x5e12fe,_0x216368),this['_diffRootsAttributes']['set'](_0x5e12fe,_0x1614f0);const _0x119807=this['_makeIdsRoot'](_0x216368,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x5e12fe,_0x119807),_0x44961a['set'](_0x5e12fe,_0x216368['isAttached']()?_0x1614f0:{});for(const [_0x238fe7,_0x1131fa]of _0x216368['markers']){if(!_0x238fe7['startsWith']('revision:'))continue;const _0x51f2b5=_0x238fe7['split'](':')[0x2];for(const _0x1357d9 of _0x1131fa['getWalker']({'singleCharacters':!0x0})){const _0x426316=this['_getVidAttributeName'](_0x1357d9),_0x1429c2=this['_revisionId']++,_0x194a7f='elementEnd'==_0x1357d9['type']?_0x1357d9['previousPosition']['path']['slice'](0x0,-0x1):_0x1357d9['previousPosition']['path'];_0x119807['getNodeByPath'](_0x194a7f)['_setAttribute'](_0x426316,_0x1429c2),this['_touched']['set'](_0x1429c2,{'userId':_0x51f2b5});}}for(const _0x4d837c of this['editor']['model']['createRangeIn'](_0x216368)['getWalker']({'singleCharacters':!0x0})){const _0x47e5a7=this['_getVidAttributeName'](_0x4d837c),_0x5f10d='elementEnd'==_0x4d837c['type']?_0x4d837c['previousPosition']['path']['slice'](0x0,-0x1):_0x4d837c['previousPosition']['path'],_0x1887bf=_0x119807['getNodeByPath'](_0x5f10d);_0x1887bf['getAttribute'](_0x47e5a7)>0x0||_0x1887bf['_setAttribute'](_0x47e5a7,_0x27fb75[_0xb010be++]);}for(const [_0x597aca,_0x5be7fb]of _0x216368['markers'])_0x597aca['startsWith']('revision:')||this['_markers']['set'](_0x597aca,_0x5be7fb);}const _0x2776d6=P('$graveyard');this['_baseRoots']['set']('$graveyard',_0x2776d6),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x2776d6,0x1));const _0x35204f=P('$graveyard');this['_diffRoots']['set']('$graveyard',_0x35204f),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x35204f,0x1));const _0x38b449=Array['from'](this['_diffRoots'])['map'](([_0x5e3548,_0x2f2ed4])=>[_0x5e3548,N(_0x2f2ed4)]);this['_saveMetaData'](this['_lastTo'],_0x38b449,this['_markers'],_0x44961a);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0x55fbf4,_0x106938,_0x208e98,_0x4a3de3){const _0x440517=new Map(_0x106938),_0x16508b=new Map(_0x54f69d(_0x4a3de3)),_0x4bf060=new Map();for(const [_0x7487e2,_0x23b0b7]of _0x208e98)_0x4bf060['set'](_0x7487e2,{'start':_0x23b0b7['start']['clone'](),'end':_0x23b0b7['end']['clone'](),'rootName':_0x23b0b7['root']['rootName']});this['_savedMetaData']['set'](_0x55fbf4,{'roots':_0x440517,'markers':_0x4bf060,'rootsAttributes':_0x16508b});}['_removeMetaData'](_0x28d732){this['_savedMetaData']['delete'](_0x28d732);}['_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'](_0x324945,_0x4ccb89=null){let _0x7b9a10=null;_0x324945['is']('documentFragment')||(_0x7b9a10=new ut(_0x324945['name'],{'vid_start':null===_0x4ccb89?this['_revisionId']++:_0x4ccb89++}));const _0x3d47f9=[];for(const _0x431f10 of _0x324945['getChildren']())if(_0x431f10['is']('element')){_0x3d47f9['push'](this['_makeIdsRoot'](_0x431f10,_0x4ccb89));const _0x4202d8=_0x3d47f9[_0x3d47f9['length']-0x1];null!==_0x4ccb89&&(_0x4ccb89=_0x4202d8['is']('element','$text')?_0x4202d8['getAttribute']('vid')+0x1:_0x4202d8['getAttribute']('vid_end')+0x1);}else{for(let _0x6e1d58=0x0;_0x6e1d58<_0x431f10['offsetSize'];_0x6e1d58++)_0x3d47f9['push'](new ut('$text',{'vid':null===_0x4ccb89?this['_revisionId']++:_0x4ccb89++}));}if(_0x324945['is']('documentFragment')){const _0x491600=P(_0x324945['rootName']);return _0x491600['_insertChild'](0x0,_0x3d47f9),_0x491600;}return _0x7b9a10['_setAttribute']('vid_end',null===_0x4ccb89?this['_revisionId']++:_0x4ccb89++),_0x7b9a10['_insertChild'](0x0,_0x3d47f9),_0x7b9a10;}['_calculateMetaData'](_0x397c23,_0x534a93,_0x10bf37){this['_reset']();const {roots:_0x536656,markers:_0x1069ea,rootsAttributes:_0x7867f6}=this['_savedMetaData']['get'](_0x397c23);this['_baseRoots']=new Map(_0x536656),this['_baseRootsAttributes']=new Map(_0x54f69d(_0x7867f6));for(const [_0x32fdb0,_0x31b768]of this['_baseRoots'])if('$graveyard'!==_0x32fdb0&&(this['_diffRoots']['set'](_0x32fdb0,N(_0x31b768)),this['_diffRootsAttributes']=new Map(_0x54f69d(_0x7867f6)),_0x10bf37)){const _0x2eeb29=this['_revisionId'];this['_idsRoots']['set'](_0x32fdb0,this['_makeIdsRoot'](_0x31b768)),this['_baseIdsRoots']['set'](_0x32fdb0,this['_makeIdsRoot'](_0x31b768,_0x2eeb29));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',N(this['_baseRoots']['get']('$graveyard'))),_0x10bf37&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x3b9ac5,_0x5debc8]of _0x1069ea){const _0x19debd=this['_baseRoots']['get'](_0x5debc8['rootName']),_0x1ffedb=this['_diffRoots']['get'](_0x5debc8['rootName']),_0x3824ef=new lt(this['_fixPosition'](_0x5debc8['start'],_0x19debd),this['_fixPosition'](_0x5debc8['end'],_0x19debd)),_0x3ccc70=this['_fixRange'](_0x3824ef,_0x1ffedb);_0x19debd['markers']['set'](_0x3b9ac5,_0x3824ef),this['_markers']['set'](_0x3b9ac5,_0x3ccc70);}this['_applyOperations'](_0x397c23,_0x534a93,_0x10bf37);}['_applyOperations'](_0x358ed3,_0xe3b869,_0x52d28e){for(const _0x487bbb of this['source']['getOperations'](_0x358ed3,_0xe3b869))this['_handleOperation'](_0x487bbb,_0x52d28e);for(const _0x397f05 of this['_diffRoots']['values']())_0x397f05['markers']['clear']();for(const [_0x53ff4f,_0x463c33]of this['_markers']){this['_diffRoots']['get'](_0x463c33['root']['rootName'])['markers']['set'](_0x53ff4f,_0x463c33['clone']());}const _0x2d52a8=new Map(),_0x17be50=new Map();for(const [_0x173405,_0x4a7220]of this['_diffRoots'])_0x2d52a8['set'](_0x173405,N(_0x4a7220)),_0x17be50['set'](_0x173405,this['_diffRootsAttributes']['get'](_0x173405));this['_saveMetaData'](_0xe3b869,_0x2d52a8,this['_markers'],_0x17be50);}['_getPreviousFrom'](_0x2d97a8){const _0x151cbb=Array['from'](this['_savedMetaData']['keys']());_0x151cbb['sort']((_0x1242ee,_0x3c9056)=>_0x1242ee-_0x3c9056),_0x151cbb['reverse']();for(const _0x3fadc8 of _0x151cbb)if(_0x3fadc8<_0x2d97a8)return _0x3fadc8;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x439d0a,_0x10b04d){const _0x59f501=Array['from'](_0x10b04d['markers'])['map'](([_0x2c7aaf,_0x48869e])=>[_0x2c7aaf,this['_fixRange'](_0x48869e,_0x439d0a)]);_0x439d0a['markers']=new Map(_0x59f501);}['_transformMarkers'](_0xd31a1d){for(const _0x4257fa of this['_markers']['values']()){const _0x4b5ff4=_0x4257fa['getTransformedByOperation'](_0xd31a1d),_0x7bc138=lt['_createFromRanges'](_0x4b5ff4);_0x4257fa['start']=_0x7bc138['start'],_0x4257fa['end']=_0x7bc138['end'];}}['_handleOperation'](_0x431018,_0x31a8ab){if('addRoot'!=_0x431018['type']&&'detachRoot'!=_0x431018['type']){if('insert'==_0x431018['type']){const _0x4ede0c=_0x431018['position']['root']['rootName'];this['_diffRoots']['has'](_0x4ede0c)||(this['_diffRoots']['set'](_0x4ede0c,P(_0x4ede0c,!0x0)),this['_diffRootsAttributes']['set'](_0x4ede0c,{}),_0x31a8ab&&this['_idsRoots']['set'](_0x4ede0c,P(_0x4ede0c,!0x0)));}else{if('addRootAttribute'==_0x431018['type']||'removeRootAttribute'==_0x431018['type']||'changeRootAttribute'==_0x431018['type'])return void this['_handleRootAttributeOperation'](_0x431018);'marker'==_0x431018['type']&&this['_handleMarkerOperation'](_0x431018);}if('marker'!==_0x431018['type']){const _0x400a4a=this['_cloneOperation'](_0x431018,this['_diffRoots']);_0x400a4a['_execute'](),this['_transformMarkers'](_0x400a4a);}if(_0x31a8ab)switch(_0x431018['type']){case'insert':this['_handleInsertOperation'](_0x431018);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x431018);break;case'merge':this['_handleMergeOperation'](_0x431018);break;case'split':this['_handleSplitOperation'](_0x431018);}}else this['_handleRootOperation'](_0x431018,_0x31a8ab);}['_cloneOperation'](_0x3f0e76,_0x2f38e6){const _0x3c94f3=_0x3f0e76['clone']();return _0x3c94f3['_authorId']=_0x3f0e76['_authorId'],this['_fixOperation'](_0x3c94f3,_0x2f38e6),_0x3c94f3;}['_getBaseVids'](_0x4bb6ad){return _0x4bb6ad['map'](_0x4ad059=>{const _0x24060c=this['_getVidAttributeName'](_0x4ad059);return Number(_0x4ad059['item']['getAttribute'](_0x24060c));});}['_generateTape'](_0x44ce61,_0x5d2fbe){if(_0x44ce61['is']('element','$text'))_0x5d2fbe['push']({'item':_0x44ce61,'type':'text'});else{_0x44ce61['is']('element')&&_0x5d2fbe['push']({'item':_0x44ce61,'type':'elementStart'});for(const _0x45c5a9 of _0x44ce61['getChildren']())this['_generateTape'](_0x45c5a9,_0x5d2fbe);_0x44ce61['is']('element')&&_0x5d2fbe['push']({'item':_0x44ce61,'type':'elementEnd'});}return _0x5d2fbe;}['_getState'](){const _0x5d7ec9=new Map(this['_touched']),_0x3988e3=new Map(_0x5d7ec9),_0x5940bc=new Map(),_0x4a0b7a={'insertions':{},'deletions':{}},_0xa71202={'insertions':{},'deletions':{}},_0xc5c8d7=new Map(),_0x4621eb=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x4621eb['delete']('$graveyard');for(const _0x148f43 of _0x4621eb){const _0x27337f=this['_diffRoots']['get'](_0x148f43)||P(_0x148f43,!0x1),_0x47f213=this['_baseRoots']['get'](_0x148f43)||P(_0x148f43,!0x1);_0x27337f['isAttached']()||_0x47f213['isAttached']()?(_0x4a0b7a['insertions'][_0x148f43]=N(_0x27337f),_0x4a0b7a['deletions'][_0x148f43]=N(_0x47f213),this['_copyMarkers'](_0x4a0b7a['deletions'][_0x148f43],_0x47f213),this['_copyMarkers'](_0x4a0b7a['insertions'][_0x148f43],_0x27337f),_0xa71202['insertions'][_0x148f43]=this['_generateTape'](this['_idsRoots']['get'](_0x148f43),[]),_0xa71202['deletions'][_0x148f43]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x148f43)||P(_0x148f43,!0x1),[])):_0x4621eb['delete'](_0x148f43);}for(const _0x410bfe of _0x4621eb){const _0x4f4263=_0xa71202['insertions'][_0x410bfe];for(const _0x4505bb of _0x4f4263){const _0x395657=this['_getVidAttributeName'](_0x4505bb),_0x4c7e7f=_0x4505bb['item']['getAttribute'](_0x395657);_0x3988e3['delete'](_0x4c7e7f),_0x4c7e7f>=this['_startingRevisionId']&&_0x5940bc['set'](_0x4c7e7f,_0x5d7ec9['get'](_0x4c7e7f));}}for(const _0x40a083 of _0x4621eb){const _0x13d8de=_0xa71202['insertions'][_0x40a083],_0x5dd7d1=this['_getBaseVids'](_0xa71202['deletions'][_0x40a083]);let _0x5c206c=0x0;for(const _0x2daa70 of _0x13d8de){const _0x138e11=this['_getVidAttributeName'](_0x2daa70),_0x382e81=_0x2daa70['item']['getAttribute'](_0x138e11);if(!_0x5940bc['has'](_0x382e81)&&!_0xc5c8d7['has'](_0x382e81)){if(_0x3988e3['has'](_0x382e81))_0x5c206c++;else{if(_0x382e81!=_0x5dd7d1[_0x5c206c]){const _0x21e5bb=_0x5d7ec9['get'](_0x382e81)||_0x5d7ec9['get'](_0x5dd7d1[_0x5c206c]);for(;_0x382e81!=_0x5dd7d1[_0x5c206c];)_0x3988e3['has'](_0x5dd7d1[_0x5c206c])||(_0xc5c8d7['set'](_0x5dd7d1[_0x5c206c],_0x21e5bb),_0x5d7ec9['set'](_0x5dd7d1[_0x5c206c],_0x21e5bb)),_0x5c206c++;}_0x5c206c++;}}}}for(const _0x4ba497 of _0x4621eb){const _0x32f766=_0xa71202['insertions'][_0x4ba497];for(const _0x39ba70 of _0x32f766){const _0x10d9b8=this['_getVidAttributeName'](_0x39ba70),_0x2bd3e8=_0x39ba70['item']['getAttribute'](_0x10d9b8);if(_0xc5c8d7['has'](_0x2bd3e8)){const _0x1204aa=_0xc5c8d7['get'](_0x2bd3e8);_0x3988e3['has'](_0x2bd3e8)||_0x3988e3['set'](_0x2bd3e8,{..._0x1204aa}),_0x5940bc['set'](_0x2bd3e8,{..._0x1204aa});}}}for(const _0x9bbac5 of _0x3988e3['keys']())_0x9bbac5>=this['_startingRevisionId']&&_0x3988e3['delete'](_0x9bbac5);const _0x23cf73=new Map();for(const _0x43e04f of _0x4621eb){let _0x39b137=_0xa71202['insertions'][_0x43e04f];for(const _0x44993f of _0x39b137)if(_0x44993f['item']['is']('element','tableCell')){const _0x271ac8=this['_getVidAttributeName'](_0x44993f),_0x507042=_0x44993f['item']['getAttribute'](_0x271ac8);if(_0x5940bc['has'](_0x507042)){const _0x358ec3=_0x44993f['item']['parent']['parent']['getAttribute']('vid_start'),_0x40fb08=_0x23cf73['get'](_0x358ec3)||new Set();_0x40fb08['add'](_0x5940bc['get'](_0x507042)['userId']),_0x23cf73['set'](_0x358ec3,_0x40fb08);}}_0x39b137=_0xa71202['deletions'][_0x43e04f];for(const _0x4a41be of _0x39b137)if(_0x4a41be['item']['is']('element','tableCell')){const _0x397c95=this['_getVidAttributeName'](_0x4a41be),_0x251ed5=_0x4a41be['item']['getAttribute'](_0x397c95);if(_0x3988e3['has'](_0x251ed5)){const _0x355389=_0x4a41be['item']['parent']['parent']['getAttribute']('vid_start'),_0x5b00d2=_0x23cf73['get'](_0x355389)||new Set();_0x5b00d2['add'](_0x3988e3['get'](_0x251ed5)['userId']),_0x23cf73['set'](_0x355389,_0x5b00d2);}}for(const _0x4e9ddb of _0x23cf73['keys']())(_0x5940bc['has'](_0x4e9ddb)||_0x3988e3['has'](_0x4e9ddb))&&_0x23cf73['delete'](_0x4e9ddb);}for(const _0x5e432b of _0x4621eb){const _0x159178=_0xa71202['insertions'][_0x5e432b];let _0x558381=null,_0x548d39=null;for(const _0x35bacf of _0x159178){const _0x895bb0=this['_getVidAttributeName'](_0x35bacf),_0x32fc35=_0x35bacf['item']['getAttribute'](_0x895bb0),_0x5d1225=_0x23cf73['get'](_0x32fc35);_0x5d1225&&'elementStart'==_0x35bacf['type']&&(_0x558381=Array['from'](_0x5d1225)[0x0],_0x548d39=_0x35bacf['item']['getAttribute']('vid_end')),_0x558381&&(_0x3988e3['set'](_0x32fc35,{'userId':_0x558381}),_0x5940bc['set'](_0x32fc35,{'userId':_0x558381})),_0x32fc35==_0x548d39&&(_0x558381=null,_0x548d39=null);}}const _0x201722={},_0x1d9e82=new Set();for(const _0x3e62d7 of _0x4621eb){const _0x192676=_0x4a0b7a['deletions'][_0x3e62d7],_0x42d549=_0x4a0b7a['insertions'][_0x3e62d7];for(const {userId:_0x144854}of this['_touchedMarkers']['values']())null!==_0x144854&&_0x1d9e82['add'](_0x144854);for(const {userId:_0x56f147}of this['_touchedRoots']['values']())null!==_0x56f147&&_0x1d9e82['add'](_0x56f147);this['_markChanges'](_0x42d549,_0xa71202['insertions'][_0x3e62d7],_0x5940bc,'insertion',_0x1d9e82),this['_markChanges'](_0x192676,_0xa71202['deletions'][_0x3e62d7],_0x3988e3,'deletion',_0x1d9e82),_0x201722[_0x3e62d7]={'insertions':this['_prepareViewToSave'](_0x42d549),'deletions':this['_prepareViewToSave'](_0x192676),'attachChange':this['_touchedRoots']['get'](_0x3e62d7)||null,'attributesBefore':_0x54f69d(this['_baseRootsAttributes']['get'](_0x3e62d7))||{},'attributesAfter':_0x54f69d(this['_diffRootsAttributes']['get'](_0x3e62d7))};}return{'diffData':_0x201722,'authorsIds':Array['from'](_0x1d9e82)};}['_processRootBeforeSave'](_0x2da0c1){for(const [,_0x31b920]of _0x2da0c1['markers']){const _0x5d9b47=_0x31b920['start']['getAncestors']()['filter'](_0x2fefc0=>'tableCell'==_0x2fefc0['name']);for(const _0x6f3e6b of _0x5d9b47)0x1==_0x6f3e6b['childCount']&&_0x6f3e6b['getChild'](0x0)['is']('element','paragraph')&&_0x6f3e6b['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x3fe36b){this['_processRootBeforeSave'](_0x3fe36b);const _0x56f6b3=this['editor']['data']['toView'](_0x3fe36b,{}),_0x50e4fb=Array['from'](_0x56f6b3['getChildren']())['map'](_0x557389=>this['_getViewJson'](_0x557389));return JSON['stringify'](_0x50e4fb);}['_getViewJson'](_0xc9dc3a){if(_0xc9dc3a['is']('$text'))return _0xc9dc3a['data'];{const _0x36a55c=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0x4b4f61=_0xc9dc3a,_0x4c727e=this['editor']['data']['htmlProcessor']['domConverter'],_0x3616fa={'type':_0x36a55c['_getTypeCharForViewElement'](_0x4b4f61),'name':_0x4b4f61['name'],'attributes':Array['from'](_0x4b4f61['getAttributes']()),'children':Array['from'](_0x4b4f61['getChildren']())['map'](_0x3d752b=>this['_getViewJson'](_0x3d752b))};if(_0xc9dc3a['is']('uiElement')&&'$comment'!=_0xc9dc3a['name']){const _0x5a8525=_0xc9dc3a['render'](_0x4c727e['domDocument'],_0x4c727e);_0x3616fa['children']['push'](_0x5a8525['outerHTML']);}else{if(_0xc9dc3a['is']('rawElement')){const _0x4980a5=_0x4c727e['domDocument']['createElement'](_0x4b4f61['name']);_0xc9dc3a['render'](_0x4980a5,_0x4c727e),_0x3616fa['children']['push'](_0x4980a5['innerHTML']);}}const _0x5930a0=Array['from'](_0x4b4f61['getCustomProperties']());_0x5930a0['length']>0x0&&(_0x3616fa['customProperties']=_0x5930a0);const _0x11d68b=_0x4b4f61['getFillerOffset']();return null!==_0x11d68b&&(_0x3616fa['fillerOffset']=_0x11d68b),_0x3616fa;}}['_markChanges'](_0x1a5ba8,_0x2351a5,_0x560649,_0x2b51d8,_0x25c2db){let _0x1d17b9=null,_0x2bebc6=null,_0x46b2fd=0x0;const _0x77191e=this['editor']['model'];for(let _0x5c53ab=0x0;_0x5c53ab<_0x2351a5['length'];_0x5c53ab++){const _0x2c48de=this['_getVidAttributeName'](_0x2351a5[_0x5c53ab]),_0x4f2438=_0x2351a5[_0x5c53ab]['item']['getAttribute'](_0x2c48de),_0x5da8cf=_0x560649['get'](_0x4f2438),_0x111c99=_0x5c53ab==_0x2351a5['length']-0x1;(!_0x1d17b9&&_0x5da8cf&&(_0x1d17b9=_0x5da8cf,_0x2bebc6=_0x2351a5[_0x5c53ab]),_0x1d17b9&&(!_0x5da8cf||_0x5da8cf['userId']!=_0x1d17b9['userId']))&&(_0x5b465f(_0x5da8cf,F(_0x2bebc6,_0x1a5ba8,_0x77191e),F(_0x2351a5[_0x5c53ab],_0x1a5ba8,_0x77191e)),_0x1d17b9=_0x5da8cf||null,_0x2bebc6=_0x5da8cf?_0x2351a5[_0x5c53ab]:null),_0x1d17b9&&_0x111c99&&_0x5b465f(_0x5da8cf,F(_0x2bebc6,_0x1a5ba8,_0x77191e),B(_0x2351a5[_0x5c53ab],_0x1a5ba8,_0x77191e));}function _0x5b465f(_0x1e54fe,_0xbd65e2,_0x3d52a1){const _0x22e2db=_0x1d17b9['userId'],_0x46c591='revision:'+_0x2b51d8+':'+_0x22e2db+':'+_0x46b2fd++,_0xeb91a1=_0x77191e['createRange'](_0xbd65e2,_0x3d52a1);_0x1a5ba8['markers']['set'](_0x46c591,_0xeb91a1),null!==_0x22e2db&&_0x25c2db['add'](_0x22e2db);}}['_getVidAttributeName'](_0x1ed2b4){switch(_0x1ed2b4['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x56cc3d,_0x3c78b3){_0x56cc3d['baseVersion']=null;for(const _0xdf3167 in _0x56cc3d){const _0x325184=_0x56cc3d[_0xdf3167];if(_0x325184 instanceof ft){const _0x583252=_0x3c78b3['get'](_0x325184['root']['rootName']);_0x56cc3d[_0xdf3167]=this['_fixPosition'](_0x325184,_0x583252);}if(_0x325184 instanceof lt){const _0x3083e9=_0x3c78b3['get'](_0x325184['root']['rootName']);_0x56cc3d[_0xdf3167]=this['_fixRange'](_0x325184,_0x3083e9);}'root'===_0xdf3167&&(_0x56cc3d['root']=_0x3c78b3['get'](_0x56cc3d['root']['rootName']));}}['_fixRange'](_0x5be114,_0x537ba9){return this['editor']['model']['createRange'](this['_fixPosition'](_0x5be114['start'],_0x537ba9),this['_fixPosition'](_0x5be114['end'],_0x537ba9));}['_fixPosition'](_0x2a5a7e,_0x57b6df){return this['editor']['model']['createPositionFromPath'](_0x57b6df,_0x2a5a7e['path'],_0x2a5a7e['stickiness']);}['_handleInsertOperation'](_0x1acda9){const _0x776252=this['_idsRoots']['get'](_0x1acda9['position']['root']['rootName']),_0x576370=this['_fixPosition'](_0x1acda9['position'],_0x776252),_0x30a106=null===_0x1acda9['_authorId']?null:_0x1acda9['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x2371ca=_0x576370['parent'],_0x4e9c5f=this['_revisionId'],_0x48a86f=[];for(const _0x3f0b50 of _0x1acda9['nodes'])if(_0x3f0b50['is']('element'))_0x48a86f['push'](this['_makeIdsRoot'](_0x3f0b50));else{for(let _0x1ffe56=0x0;_0x1ffe56<_0x3f0b50['offsetSize'];_0x1ffe56++)_0x48a86f['push'](new ut('$text',{'vid':this['_revisionId']++}));}const _0x4bc14b=this['_revisionId'];for(let _0x17d058=_0x4e9c5f;_0x17d058<_0x4bc14b;_0x17d058++)this['_touched']['set'](_0x17d058,{'userId':_0x30a106});_0x2371ca['_insertChild'](_0x576370['offset'],_0x48a86f);}['_handleMoveOperation'](_0xbec353){(_0xbec353=this['_cloneOperation'](_0xbec353,this['_idsRoots']))['_execute']();const _0x1b9538=null===_0xbec353['_authorId']?null:_0xbec353['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x1f30a4=_0xbec353['getMovedRangeStart'](),_0x2a576c=_0x1f30a4['parent'],_0xd0345b=_0x1f30a4['offset'];!function _0xaa7bf1(_0x24eeaa,_0x301865,_0x3aa057,_0x431421){for(let _0x53542f=_0x3aa057;_0x53542f<_0x431421;_0x53542f++){const _0x36dba2=_0x301865['getChild'](_0x53542f);_0x36dba2['is']('element','$text')?_0x24eeaa['set'](_0x36dba2['getAttribute']('vid'),{'userId':_0x1b9538}):(_0x24eeaa['set'](_0x36dba2['getAttribute']('vid_start'),{'userId':_0x1b9538}),_0xaa7bf1(_0x24eeaa,_0x36dba2,0x0,_0x36dba2['childCount']),_0x24eeaa['set'](_0x36dba2['getAttribute']('vid_end'),{'userId':_0x1b9538}));}}(this['_touched'],_0x2a576c,_0xd0345b,_0xd0345b+_0xbec353['howMany']);}['_handleMergeOperation'](_0x3e90b2){const _0x45ac57=null===(_0x3e90b2=this['_cloneOperation'](_0x3e90b2,this['_idsRoots']))['_authorId']?null:_0x3e90b2['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x4d208a=_0x3e90b2['targetPosition']['parent'],_0x1dc0ca=_0x3e90b2['sourcePosition']['parent'],_0x25fd57=_0x4d208a['getAttribute']('vid_end'),_0x5e71ed=_0x1dc0ca['getAttribute']('vid_start');_0x4d208a['_setAttribute']('vid_end',_0x1dc0ca['getAttribute']('vid_end')),_0x1dc0ca['_setAttribute']('vid_end',_0x25fd57),this['_touched']['set'](_0x5e71ed,{'userId':_0x45ac57}),this['_touched']['set'](_0x25fd57,{'userId':_0x45ac57}),_0x3e90b2['_execute']();}['_handleSplitOperation'](_0x49f0f3){const _0x113edf=null===(_0x49f0f3=this['_cloneOperation'](_0x49f0f3,this['_idsRoots']))['_authorId']?null:_0x49f0f3['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x40249c=_0x49f0f3['graveyardPosition'],_0xd181b1=_0x49f0f3['splitPosition']['parent'];_0x49f0f3['_execute']();const _0x5ca433=_0xd181b1['getAttribute']('vid_end'),_0x2fcc8d=_0x49f0f3['insertionPosition']['nodeAfter'];if(_0x40249c){const _0x283d31=_0x2fcc8d['getAttribute']('vid_end'),_0x58f27f=_0xd181b1['getAttribute']('vid_end');_0xd181b1['_setAttribute']('vid_end',_0x283d31),_0x2fcc8d['_setAttribute']('vid_end',_0x58f27f),this['_touched']['set'](_0xd181b1['getAttribute']('vid_end'),{'userId':_0x113edf}),this['_touched']['set'](_0x2fcc8d['getAttribute']('vid_start'),{'userId':_0x113edf});}else{const _0x219843=this['_revisionId']++,_0x1da697=this['_revisionId']++;_0xd181b1['_setAttribute']('vid_end',_0x219843),_0x2fcc8d['_setAttribute']('vid_start',_0x1da697),_0x2fcc8d['_setAttribute']('vid_end',_0x5ca433),this['_touched']['set'](_0x219843,{'userId':_0x113edf}),this['_touched']['set'](_0x1da697,{'userId':_0x113edf});}}['_handleMarkerOperation'](_0x3d35dd){if(!_0x3d35dd['affectsData'])return;const _0x130738=(_0x3d35dd=this['_cloneOperation'](_0x3d35dd,this['_diffRoots']))['oldRange']?_0x3d35dd['oldRange']['root']:null,_0x3fbfd1=_0x3d35dd['newRange']?_0x3d35dd['newRange']['root']:null;_0x130738&&this['_markers']['delete'](_0x3d35dd['name']),_0x3fbfd1&&this['_markers']['set'](_0x3d35dd['name'],_0x3d35dd['newRange']['clone']());const _0x23b889=null===_0x3d35dd['_authorId']?null:_0x3d35dd['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x2dc3ef=_0x3d35dd['name'];if(!this['_touchedMarkers']['has'](_0x2dc3ef))return void this['_touchedMarkers']['set'](_0x2dc3ef,{'range':_0x3d35dd['oldRange'],'userId':_0x23b889});const _0x30dced=this['_touchedMarkers']['get'](_0x2dc3ef),_0x1b3ff1=_0x30dced['range'],_0x366b42=_0x3d35dd['newRange'];null==_0x1b3ff1&&null==_0x366b42||_0x1b3ff1&&_0x366b42&&_0x1b3ff1['isEqual'](_0x366b42)?this['_touchedMarkers']['delete'](_0x3d35dd['name']):_0x30dced['userId']=_0x23b889;}['_handleRootOperation'](_0x38ddfd,_0x196618){this['_diffRoots']['has'](_0x38ddfd['rootName'])?this['_diffRoots']['get'](_0x38ddfd['rootName'])['_isAttached']=_0x38ddfd['isAdd']:(this['_diffRoots']['set'](_0x38ddfd['rootName'],P(_0x38ddfd['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x38ddfd['rootName'],{}),_0x196618&&this['_idsRoots']['set'](_0x38ddfd['rootName'],P(_0x38ddfd['rootName'],!0x0)));const _0x52ebf0=null===_0x38ddfd['_authorId']?null:_0x38ddfd['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x3da717=this['_touchedRoots']['get'](_0x38ddfd['rootName']);_0x3da717&&_0x3da717['userId']===_0x52ebf0?this['_touchedRoots']['delete'](_0x38ddfd['rootName']):this['_touchedRoots']['set'](_0x38ddfd['rootName'],{'userId':_0x52ebf0,'isAttached':_0x38ddfd['isAdd']});}['_handleRootAttributeOperation'](_0x5b6d75){const _0x32471c=this['_diffRootsAttributes']['get'](_0x5b6d75['root']['rootName']);null===_0x5b6d75['newValue']?delete _0x32471c[_0x5b6d75['key']]:_0x32471c[_0x5b6d75['key']]=_0x5b6d75['newValue'];}}function N(_0x366c71){const _0xdeb410=P(_0x366c71['rootName'],_0x366c71['isAttached']());for(const _0x2b6e3a of _0x366c71['getChildren']()){const _0x10865f=_0x2b6e3a['_clone'](!0x0);_0xdeb410['_appendChild'](_0x10865f);}return _0xdeb410;}function P(_0x17a83c,_0x2461e4=!0x0){const _0x52ae14=new vt();return _0x52ae14['rootName']=_0x17a83c,_0x52ae14['_isAttached']=_0x2461e4,_0x52ae14['isAttached']=()=>_0x52ae14['_isAttached'],_0x52ae14;}function F(_0x5bf3b4,_0x25f096,_0x1a0b25){const _0x22db31='elementEnd'==_0x5bf3b4['type']?_0x1a0b25['createPositionAt'](_0x5bf3b4['item'],'end'):_0x1a0b25['createPositionBefore'](_0x5bf3b4['item']);return _0x1a0b25['createPositionFromPath'](_0x25f096,_0x22db31['path'],_0x22db31['stickiness']);}function B(_0x510e72,_0x1d35af,_0x145048){const _0x2e8d6e='elementStart'==_0x510e72['type']?_0x145048['createPositionAt'](_0x510e72['item'],0x0):_0x145048['createPositionAfter'](_0x510e72['item']);return _0x145048['createPositionFromPath'](_0x1d35af,_0x2e8d6e['path'],_0x2e8d6e['stickiness']);}class hs extends ts{['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x1b15a4,_0x9325b5){super(_0x1b15a4),this['focusTracker']=new _0x3442d6(),this['keystrokes']=new _0x47111d(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x9325b5),this['setTemplate']({'tag':'form','attributes':{'class':['ck','ck-revision-history-save-revision-form','ck-responsive-form'],'tabindex':'-1'},'children':[this['revisionNameInputView']]}),_0x46a33f(this);}['render'](){super['render'](),_0x51f4e9({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x24a592=_0x566f5e=>_0x566f5e['stopPropagation']();this['keystrokes']['set']('arrowright',_0x24a592),this['keystrokes']['set']('arrowleft',_0x24a592),this['keystrokes']['set']('arrowup',_0x24a592),this['keystrokes']['set']('arrowdown',_0x24a592);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0xe70d6a){this['revisionNameInputView']['fieldView']['element']['value']=_0xe70d6a['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x1b07cf){const _0x2cb692=new _0xacc8af(this['locale'],_0x5442b6),_0x5502a0=_0x2cb692['fieldView'];_0x5502a0['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x561228=g(this['locale'],'Name\x20of\x20the\x20revision');return!_0x1b07cf&&(_0x561228+='\x20('+g(this['locale'],'optional')+')'),(_0x2cb692['label']=_0x561228,_0x5502a0['on']('input',()=>{this['revisionNameInputValue']=_0x5502a0['element']['value']['trim']();}),_0x2cb692);}}class f extends _0xc858c4{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u];}['_saveRevisionFormView'];['init'](){const _0x1f6f43=this['editor'],_0x40bcf9=_0x1f6f43['plugins']['get']('RevisionTracker');_0x1f6f43['ui']['componentFactory']['add']('revisionHistory',_0x4bb923=>{const _0x49b523=_0x5f4b44(_0x4bb923),_0x499e36=_0x49b523['panelView']['children'],_0x27b66d=new _0x5320ef(_0x4bb923),_0x3284d2=new _0x215dab(_0x4bb923),_0x401854=new te(_0x4bb923),_0x5ec544=new _0x215dab(_0x4bb923),_0x373cb9=new te(_0x4bb923);return _0x49b523['bind']('isEnabled')['to'](_0x40bcf9,'isReady',_0x40bcf9,'isEnabled',_0x1f6f43,'isReadOnly',(_0x51a778,_0x5e3ec4,_0x2071c2)=>_0x51a778&&_0x5e3ec4&&!_0x2071c2),_0x49b523['buttonView']['set']({'icon':_0x3e9cd6,'label':g(_0x4bb923,'Revision\x20history'),'tooltip':!0x0}),_0x401854['set']({'label':g(_0x4bb923,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x401854['bind']('isEnabled')['to'](_0x40bcf9,'isReady',_0x40bcf9,'isEnabled',_0x1f6f43,'isReadOnly',(_0x40cb5d,_0x2fbb83,_0x232fa9)=>_0x40cb5d&&_0x2fbb83&&!_0x232fa9),_0x401854['on']('execute',()=>this['_showDialog']()),_0x373cb9['set']({'label':g(_0x4bb923,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x373cb9['bind']('isEnabled')['to'](_0x40bcf9,'isReady',_0x1f6f43,'isReadOnly',(_0x437989,_0x5b9181)=>_0x437989&&!_0x5b9181),_0x373cb9['on']('execute',()=>{_0x1f6f43['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x49b523['isOpen']=!0x1,_0x1f6f43['editing']['view']['focus']();}),_0x3284d2['children']['add'](_0x401854),_0x5ec544['children']['add'](_0x373cb9),_0x27b66d['role']='menu',_0x27b66d['items']['addMany']([_0x3284d2,_0x5ec544]),_0x499e36['add'](_0x27b66d),_0x49b523;}),_0x1f6f43['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x30b237=this['editor'],_0x1b3b4a=_0x30b237['locale'],_0x1a459c=new _0x444fc6(_0x1b3b4a),_0x34ff47=new _0x2a7399(_0x1b3b4a);_0x1a459c['buttonView']['set']({'icon':_0x3e9cd6,'label':g(_0x1b3b4a,'Revision\x20history')});const _0x267bb2=new _0x42e37e(_0x1b3b4a,_0x1a459c),_0x54f602=new _0x182e41(_0x1b3b4a);_0x54f602['set']({'label':g(_0x1b3b4a,'Save\x20current\x20revision')}),_0x54f602['delegate']('execute')['to'](_0x1a459c),_0x54f602['on']('execute',()=>{this['_showDialog']();}),_0x267bb2['children']['add'](_0x54f602),_0x34ff47['items']['add'](_0x267bb2);const _0x144630=new _0x42e37e(_0x1b3b4a,_0x1a459c),_0x3f2705=new _0x182e41(_0x1b3b4a);return _0x3f2705['set']({'label':g(_0x1b3b4a,'Open\x20revision\x20history')}),_0x3f2705['delegate']('execute')['to'](_0x1a459c),_0x3f2705['on']('execute',()=>{_0x30b237['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x144630['children']['add'](_0x3f2705),_0x34ff47['items']['add'](_0x144630),_0x1a459c['panelView']['children']['add'](_0x34ff47),_0x1a459c;}['_showDialog'](){const _0x54a095=this['editor'],_0x5a5a5b=_0x54a095['locale'],_0x416e93=_0x54a095['plugins']['get']('Dialog'),_0x8f4382=_0x54a095['plugins']['get']('RevisionTracker');function _0x1c24b4(_0x39b13b){_0x54a095['config']['get']('revisionHistory.requireRevisionName')&&''===_0x39b13b['revisionName']?_0x39b13b['revisionNameInputView']['errorText']=g(_0x5a5a5b,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x54a095['plugins']['get'](u)['saveRevision']({'name':_0x39b13b['revisionName']}),_0x416e93['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x1c24b4(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x416e93['show']({'id':'revisionSave','title':g(_0x5a5a5b,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':g(_0x54a095['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x416e93['hide']()},{'label':g(_0x54a095['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x5889ec){_0x5889ec['bind']('isEnabled')['to'](_0x8f4382,'isReady',_0x8f4382,'isEnabled',_0x54a095,'isReadOnly',(_0x1a34a5,_0x58c978,_0x37cb2c)=>_0x1a34a5&&_0x58c978&&!_0x37cb2c);},'onExecute':()=>_0x1c24b4(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0xaa9d19=this['editor'],_0x414fe9=_0xaa9d19['locale'];this['_saveRevisionFormView']=new hs(_0x414fe9,_0xaa9d19['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class Q extends ts{['changeId'];['_model'];constructor(_0x9ed90,_0x1a6d1f){super(_0x9ed90),this['_model']=_0x1a6d1f,this['changeId']=_0x1a6d1f['id'];const _0x206e47=this['bindTemplate'],_0x2e09cf=g(_0x9ed90,_0x1a6d1f['data']['isSuggestion']?'Suggested\x20by':'add'==_0x1a6d1f['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x1a6d1f['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x206e47['to']('type',_0x2776ff=>'ck-revision-change__'+_0x2776ff)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x2e09cf}]},{'text':'\x20'+_0x1a6d1f['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class r extends/* #__PURE__ -- @preserve */
25
+ _0x11aaf9(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x3248ff){super(),this['id']=_0x3248ff['id']||_0x19f1f8(),this['author']=_0x3248ff['author'],this['type']=_0x3248ff['type'],this['data']=_0x3248ff['data']||{},this['rootName']=_0x3248ff['rootName'],this['set']('createdAt',_0x3248ff['createdAt']);}['toJSON'](){return{'id':this['id'],'authorId':this['author']['id'],'type':this['type'],'data':this['data'],'createdAt':this['createdAt']};}}class c{['newRevisionId'];['oldRevisionId'];['changes'];constructor(_0x32210a,_0x112860){this['newRevisionId']=_0x32210a,this['oldRevisionId']=_0x112860,this['changes']=new _0x58fbc2();}['_setChanges'](_0x558d48){for(const _0x47a24a of _0x558d48)this['changes']['add'](_0x47a24a);}}class m extends _0xc858c4{['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[_0x27c92d,_0x962635,I,V];}constructor(_0x216d0d){super(_0x216d0d),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',(_0x9d1b35,_0x12cf94,_0x250b02)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x3953eb=>{for(const _0xecfee2 of this['editor']['editing']['view']['document']['roots'])_0x250b02?_0x3953eb['removeClass']('ck-editor__editable__overlay',_0xecfee2):_0x3953eb['addClass']('ck-editor__editable__overlay',_0xecfee2);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x4a8df6=>null!==_0x4a8df6),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x4fdb2f,_0x2dfbd0,_0x3c8d52)=>_0x4fdb2f&&_0x3c8d52?_0x2dfbd0['changes']['getIndex'](_0x3c8d52):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x3a4b72,_0x18635b)=>_0x3a4b72?_0x18635b['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0x962635);}['init'](){const _0x22a05d=this['editor'],_0x414b5b=new wt(_0x22a05d,{'direction':'backward'}),_0xd51eb0=new wt(_0x22a05d,{'direction':'forward'});(_0x22a05d['commands']['add']('showPreviousChange',_0x414b5b),_0x22a05d['commands']['add']('showNextChange',_0xd51eb0),_0x22a05d['commands']['add']('restoreRevision',new mt(_0x22a05d)),this['on']('change:numberOfChanges',()=>{_0x414b5b['refresh'](),_0xd51eb0['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x22a05d['enableReadOnlyMode']('revision-viewer'),_0x22a05d['plugins']['has']('WidgetToolbarRepository'))&&_0x22a05d['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0xcc180b){return await this['_utils']['loadRevisionData'](_0xcc180b,this['adapter']),this['_utils']['getRevisionDocumentData'](_0xcc180b);}async['getRevisionRootsAttributes'](_0x21a0ce){return await this['_utils']['loadRevisionData'](_0x21a0ce,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x21a0ce);}async['compare'](_0x4ec6a7,_0x1d59a4,_0x3e29b7=!0x1){if(!this['isEnabled'])return;const _0x525fe0=this['diff'],_0x57659f=this['repository'],_0x583422='string'==typeof _0x4ec6a7?_0x57659f['getRevision'](_0x4ec6a7):_0x4ec6a7,_0x20a33c='string'==typeof _0x1d59a4?_0x57659f['getRevision'](_0x1d59a4):_0x1d59a4,_0x74519=_0x583422['id'],_0x1f0d85=_0x20a33c?_0x20a33c['id']:null;if(!_0x3e29b7&&this['diff']&&this['diff']['newRevisionId']===_0x74519&&this['diff']['oldRevisionId']===_0x1f0d85)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new c(_0x74519,_0x1f0d85);const _0x2ff330=this['_getRevisionsRange'](_0x583422,_0x20a33c,!0x0)['map'](_0x1a4ec8=>this['_utils']['loadRevisionData'](_0x1a4ec8,this['adapter']));return _0x2ff330['push'](new Promise(_0xc11032=>{setTimeout(_0xc11032,0x14);})),Promise['all'](_0x2ff330)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x13ecec=this['_getDiff'](_0x74519,_0x1f0d85);for(const _0x51f1b2 of _0x13ecec['changes'])this['_changeIdToChange']['set'](_0x51f1b2['id'],_0x51f1b2);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x15dec7=>{for(const _0x585fc0 of this['editor']['model']['document']['getRootNames']())_0x15dec7['detachRoot'](_0x585fc0);for(const _0x5c905b of Object['keys'](_0x13ecec['model'])){const _0x14e3db=_0x15dec7['addRoot'](_0x5c905b);for(const _0x2ee198 of Object['keys'](_0x13ecec['attributes'][_0x5c905b]))_0x15dec7['setAttribute'](_0x2ee198,_0x13ecec['attributes'][_0x5c905b][_0x2ee198],_0x14e3db);_0x15dec7['insert'](_0x13ecec['model'][_0x5c905b],_0x14e3db,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x13ecec['changes'])),this['isReady']=!0x0;})['catch'](_0x31d2fa=>{console['error'](_0x31d2fa),this['_cleanUp'](),_0x525fe0&&(this['diff']=_0x525fe0),this['isReady']=!0x0;});}['addRevisionData'](_0x3ee9aa,_0x47ddd1){const _0x2aa328=this['repository']['createRevision'](_0x3ee9aa);return _0x2aa328['on']('_update',(_0x5a1f1f,_0x3e7d66,_0x428840)=>_0x47ddd1(_0x3e7d66,_0x428840,_0x2aa328)),this['repository']['addRevision'](_0x2aa328),_0x2aa328;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x571b37=>{for(const _0x3e5247 of this['editor']['model']['document']['getRootNames']())_0x571b37['detachRoot'](_0x3e5247);});}['_sortAndFilterDiffChanges'](_0xdf7a5b){const _0x2b1f67=[],_0x237209=new Map();for(const _0x3ffa69 of this['editor']['model']['document']['getRootNames']()){const _0x1ff0e5=this['editor']['editing']['view']['getDomRoot'](_0x3ffa69);if(!_0x1ff0e5)continue;const _0x43b7b9=_0x1ff0e5['getClientRects']()['item'](0x0);_0x43b7b9&&(_0x2b1f67['push'](_0x3ffa69),_0x237209['set'](_0x3ffa69,_0x43b7b9));}return _0x2b1f67['sort']((_0x3315f3,_0x4d2549)=>{const _0x59bc6e=_0x237209['get'](_0x3315f3),_0x45c686=_0x237209['get'](_0x4d2549);return _0x59bc6e['y']-_0x45c686['y']||_0x59bc6e['x']-_0x45c686['x'];}),(_0xdf7a5b=_0xdf7a5b['filter'](_0x164a6c=>_0x2b1f67['includes'](_0x164a6c['rootName'])))['sort']((_0x1adeea,_0x5cec34)=>_0x2b1f67['indexOf'](_0x1adeea['rootName'])-_0x2b1f67['indexOf'](_0x5cec34['rootName'])),_0xdf7a5b;}['_makeTape'](_0x74560f){const _0x153b21=Array['from'](_0x74560f['markers'])['filter'](([_0x111a0c,_0x458742])=>_0x111a0c['startsWith']('revision:')&&!_0x458742['isCollapsed']),_0xa8d4c2=Array['from'](this['editor']['model']['createRangeIn'](_0x74560f)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x153b21['length'])for(const _0x4b6db7 of _0xa8d4c2){const [_0x4b8ad4,_0x2f8d60]=_0x153b21[0x0],[,_0x433789,_0x429d2c]=_0x4b8ad4['split'](':');if(_0x2f8d60['end']['isEqual'](_0x4b6db7['nextPosition'])&&_0x153b21['shift'](),(_0x4b6db7['previousPosition']['isEqual'](_0x2f8d60['start'])||_0x4b6db7['previousPosition']['isAfter'](_0x2f8d60['start']))&&('insertion'==_0x433789?_0x4b6db7['isAdded']={'userId':_0x429d2c}:'deletion'==_0x433789&&(_0x4b6db7['isRemoved']={'userId':_0x429d2c})),0x0==_0x153b21['length'])break;}return _0xa8d4c2;}['_refreshStartEndIndex'](_0xa06635){const _0x5b5fa7=new Map();for(let _0x1f0fbd=0x0;_0x1f0fbd<_0xa06635['length'];_0x1f0fbd++)'text'===_0xa06635[_0x1f0fbd]['type']?(_0xa06635[_0x1f0fbd]['item']['startIndex']=_0x1f0fbd,_0xa06635[_0x1f0fbd]['item']['endIndex']=_0x1f0fbd):('elementStart'===_0xa06635[_0x1f0fbd]['type']?_0xa06635[_0x1f0fbd]['item']['startIndex']=_0x1f0fbd:'elementEnd'===_0xa06635[_0x1f0fbd]['type']&&(_0xa06635[_0x1f0fbd]['item']['endIndex']=_0x1f0fbd),_0x5b5fa7['set'](_0xa06635[_0x1f0fbd]['id'],_0x1f0fbd));for(const _0x2d066b of _0x5b5fa7['values']())'elementStart'===_0xa06635[_0x2d066b]['type']?_0xa06635[_0x2d066b]['item']['endIndex']=_0x5b5fa7['get'](_0xa06635[_0x2d066b]['pairId']):'elementEnd'===_0xa06635[_0x2d066b]['type']&&(_0xa06635[_0x2d066b]['item']['startIndex']=_0x5b5fa7['get'](_0xa06635[_0x2d066b]['pairId']));}['_processTape'](_0x205fc3){for(let _0x458e2d=0x0;_0x458e2d<_0x205fc3['length'];_0x458e2d++){if('elementStart'===_0x205fc3[_0x458e2d]['type'])_0x205fc3[_0x458e2d]['item']['startIndex']=_0x458e2d;else{if('elementEnd'===_0x205fc3[_0x458e2d]['type']){_0x205fc3[_0x458e2d]['item']['endIndex']=_0x458e2d;const _0x504820=_0x205fc3[_0x458e2d]['item']['startIndex'];_0x205fc3[_0x504820]['pairId']=_0x205fc3[_0x458e2d]['id'],_0x205fc3[_0x458e2d]['pairId']=_0x205fc3[_0x504820]['id'];}else _0x205fc3[_0x458e2d]['item']['startIndex']=_0x458e2d,_0x205fc3[_0x458e2d]['item']['endIndex']=_0x458e2d,_0x205fc3[_0x458e2d]['pairId']=null;}_0x205fc3[_0x458e2d]['markersStart']||(_0x205fc3[_0x458e2d]['markersStart']=[],_0x205fc3[_0x458e2d]['markersEnd']=[]);}}['_markInsertions'](_0x10783f,_0x8470af){const _0x25b02e=_0x10783f['filter'](_0x300172=>!_0x300172['isAdded']);for(let _0xad2dcb=0x0;_0xad2dcb<_0x8470af['length'];_0xad2dcb++)_0x8470af[_0xad2dcb]['isAdded']&&(_0x25b02e[_0xad2dcb]['isAdded']=_0x8470af[_0xad2dcb]['isAdded']);}['_getDiff'](_0x41c06c,_0x5bf205=null){const _0x5d9c0b=this['repository']['getRevision'](_0x41c06c),_0x37d3a9=_0x5bf205?this['repository']['getRevision'](_0x5bf205):null,_0x4285be=this['_getRevisionsRange'](_0x5d9c0b,_0x37d3a9),_0x35f8e8=_0x4285be[_0x4285be['length']-0x1],_0x268680=new Map(),_0x2b89ac={'model':{},'attributes':{},'changes':[]},_0x3df1fb=new Set(),_0x5b4e5b=new Map();for(let _0x5eefc9=_0x4285be['length']-0x1;_0x5eefc9>=0x0;_0x5eefc9--){const _0x2a0d4d=_0x4285be[_0x5eefc9];for(const _0x4e8e28 of Object['keys'](_0x2a0d4d['diffData']))if(_0x2a0d4d['diffData'][_0x4e8e28]['attachChange']){const _0x3473b8=_0x2a0d4d['diffData'][_0x4e8e28]['attachChange'];_0x3473b8['isAttached']?(_0x3df1fb['add'](_0x4e8e28),_0x5b4e5b['has'](_0x4e8e28)&&_0x5b4e5b['get'](_0x4e8e28)['userId']==_0x3473b8['userId']?_0x5b4e5b['delete'](_0x4e8e28):_0x5b4e5b['set'](_0x4e8e28,_0x3473b8)):_0x5b4e5b['has'](_0x4e8e28)?(_0x3df1fb['delete'](_0x4e8e28),_0x5b4e5b['delete'](_0x4e8e28)):(_0x3df1fb['add'](_0x4e8e28),_0x5b4e5b['set'](_0x4e8e28,_0x3473b8));}else _0x3df1fb['add'](_0x4e8e28);}for(const _0x2c943c of _0x3df1fb){const _0x22c7ae=_0x5b4e5b['has'](_0x2c943c)&&!_0x5b4e5b['get'](_0x2c943c)['isAttached'];let _0x5a6b08=_0x22c7ae?_0x4285be['length']-0x1:0x0;const _0x3b9650=_0x22c7ae?-0x1:0x1;for(;_0x4285be[_0x5a6b08];){const _0x354f97=_0x4285be[_0x5a6b08];if(_0x354f97['diffData'][_0x2c943c]){const _0x3de2dc=_0x22c7ae?_0x354f97['diffData'][_0x2c943c]['attributesBefore']:_0x354f97['diffData'][_0x2c943c]['attributesAfter'];_0x2b89ac['attributes'][_0x2c943c]=_0x3de2dc?_0x54f69d(_0x3de2dc):{};break;}_0x5a6b08+=_0x3b9650;}}for(const _0x403c78 of _0x4285be){_0x403c78['model']={};for(const _0x42d6b9 of _0x403c78['authors'])_0x268680['set'](_0x42d6b9['id'],_0x42d6b9);for(const _0x1aca70 of _0x3df1fb){const _0x4ad9f9=_0x403c78['diffData'][_0x1aca70]?_0x403c78['diffData'][_0x1aca70]['insertions']:'[]',_0x305bda=_0x403c78['diffData'][_0x1aca70]?_0x403c78['diffData'][_0x1aca70]['deletions']:'[]';_0x403c78['model'][_0x1aca70]={'insertions':this['_utils']['_makeModelFromViewString'](_0x4ad9f9),'deletions':this['_utils']['_makeModelFromViewString'](_0x305bda)};}}for(const _0x1dacce of _0x3df1fb){let _0x1ccf6a=null,_0xc934f3=0x0;const _0x4ac61a=new Map(Array['from'](_0x5d9c0b['model'][_0x1dacce]['insertions']['markers'])['filter'](([_0x1f2338])=>!_0x1f2338['startsWith']('revision:')));let _0x438b78=0x0;for(const _0x5cbc83 of _0x4285be){const _0xd5acd1=this['_makeTape'](_0x5cbc83['model'][_0x1dacce]['insertions']);_0x5cbc83==_0x5d9c0b?(_0x1ccf6a=_0xd5acd1,_0xc934f3=_0x1ccf6a['length'],_0x1ccf6a['forEach'](_0x9e6bc1=>{_0x9e6bc1['id']=_0x438b78++;}),this['_processTape'](_0x1ccf6a)):this['_markInsertions'](_0x1ccf6a,_0xd5acd1);const _0x37b4ca=_0x1ccf6a['filter'](_0x1fcec5=>!_0x1fcec5['isAdded'])['map'](_0x20319c=>_0x20319c['id']);let _0x3c8c54=0x0;const _0x3f710e=this['_makeTape'](_0x5cbc83['model'][_0x1dacce]['deletions']);_0x3f710e['forEach'](_0x153173=>{_0x153173['isRemoved']?_0x153173['id']=_0xc934f3++:_0x153173['id']=_0x37b4ca[_0x3c8c54++];}),this['_processTape'](_0x3f710e),this['_setDistance'](_0x1ccf6a,'isAdded'),this['_setDistance'](_0x3f710e,'isRemoved'),_0x5cbc83==_0x5d9c0b&&this['_markMarkers'](_0x1ccf6a,_0x4ac61a),_0x1ccf6a=this['_joinTapes'](_0x1ccf6a,_0x3f710e),this['_refreshStartEndIndex'](_0x1ccf6a),this['_setDistance'](_0x1ccf6a,'isRemoved');}_0x1ccf6a=_0x1ccf6a['filter'](_0x37da1a=>!(_0x37da1a['isAdded']&&_0x37da1a['isRemoved']));const _0x4e604a=new Map(_0x35f8e8['model'][_0x1dacce]['deletions']['markers']),_0x322186=new Set(_0x4ac61a['keys']());for(const _0x46d5bb of _0x4e604a['keys']())_0x322186['delete'](_0x46d5bb);this['_markSuggestions'](_0x1ccf6a,_0x322186),this['_fixObsoleteTags'](_0x1ccf6a),_0x1ccf6a=this['_removeMissingPairs'](_0x1ccf6a),_0x1ccf6a=this['_markMismatchedRemovedTags'](_0x1ccf6a),_0x1ccf6a=this['_removeUnsupportedChanges'](_0x1ccf6a);const {root:_0x3e7a5d,changes:_0x5675de}=this['_makeModelFromTape'](_0x1ccf6a,_0x268680,_0x1dacce);_0x2b89ac['model'][_0x1dacce]=_0x3e7a5d;const _0x5b284e=_0x5b4e5b['get'](_0x1dacce);if(_0x5b284e){const _0x6eadf2=_0x268680['get'](_0x5b284e['userId']),_0x188091=new r({'author':_0x6eadf2,'type':_0x5b284e['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x1dacce});_0x5675de['unshift'](_0x188091),_0x2b89ac['attributes'][_0x1dacce]['revisionHistoryAttachChange']=_0x188091['id'];}_0x2b89ac['changes']=_0x2b89ac['changes']['concat'](_0x5675de);}return _0x2b89ac;}['_markMarkers'](_0x3bd946,_0x2c0ce0){for(let _0x358289=0x0;_0x358289<_0x3bd946['length'];_0x358289++)for(const [_0x4204af,_0x48e57f]of _0x2c0ce0)!_0x48e57f['isCollapsed']&&_0x48e57f['start']['isEqual'](_0x3bd946[_0x358289]['previousPosition'])&&_0x3bd946[_0x358289]['markersStart']['push'](_0x4204af),_0x48e57f['end']['isEqual'](_0x3bd946[_0x358289]['nextPosition'])&&_0x3bd946[_0x358289]['markersEnd']['push'](_0x4204af);}['_joinTapes'](_0x56c162,_0x398cec){let _0x2e70d2=[],_0xee1920=0x0,_0x16b71a=0x0;for(;_0xee1920<_0x56c162['length']||_0x16b71a<_0x398cec['length'];){const _0xfa4f95=_0x56c162[_0xee1920]||{},_0x589428=_0x398cec[_0x16b71a]||{};if(_0xfa4f95['id']==_0x589428['id'])_0xee1920++,_0x16b71a++,_0x2e70d2['push'](_0xfa4f95);else{if(_0x589428['isRemoved']&&_0xfa4f95['isAdded']){const {commonTape:_0x4cf7cb,iEnd:_0x2f5e5d,jEnd:_0x3ddc9b}=this['_threeWayMerge'](_0x56c162,_0xee1920,_0x398cec,_0x16b71a);_0x2e70d2=_0x2e70d2['concat'](_0x4cf7cb),_0xee1920=_0x2f5e5d,_0x16b71a=_0x3ddc9b;}else _0x589428['isRemoved']?(_0x16b71a++,_0x2e70d2['push'](_0x589428)):(_0xee1920++,_0x2e70d2['push'](_0xfa4f95));}}return _0x2e70d2;}['_markSuggestions'](_0x1af635,_0x3b4e0e){const _0xfe5817=[];for(let _0x1f923a=0x0;_0x1f923a<_0x1af635['length'];_0x1f923a++){for(let _0x53c53c=0x0;_0x53c53c<_0x1af635[_0x1f923a]['markersStart']['length'];_0x53c53c++){const _0x52ecdd=_0x1af635[_0x1f923a]['markersStart'][_0x53c53c];if(!_0x3b4e0e['has'](_0x52ecdd))continue;const {group:_0xf66c6,type:_0x246c3f,authorId:_0x2fdf2a}=_0x561bfd(_0x52ecdd);'revision-suggestion'!=_0xf66c6||'insertion'!=_0x246c3f&&'deletion'!=_0x246c3f||(_0xfe5817['unshift']({'type':_0x246c3f,'name':_0x52ecdd,'userId':_0x2fdf2a}),_0x1af635[_0x1f923a]['markersStart']['splice'](_0x53c53c,0x1),_0x53c53c--);}_0x3a69b4(_0x1af635[_0x1f923a]);for(let _0x28cceb=0x0;_0x28cceb<_0x1af635[_0x1f923a]['markersEnd']['length'];_0x28cceb++){const _0x169b88=_0x1af635[_0x1f923a]['markersEnd'][_0x28cceb];if(!_0x3b4e0e['has'](_0x169b88))continue;const {group:_0x246c25,type:_0x823824}=_0x561bfd(_0x169b88);if('revision-suggestion'!=_0x246c25||'insertion'!=_0x823824&&'deletion'!=_0x823824)continue;_0x1af635[_0x1f923a]['markersEnd']['splice'](_0x28cceb,0x1),_0x28cceb--;const _0x4df0c8=_0xfe5817['findIndex'](_0x1d748d=>_0x1d748d['name']==_0x169b88);_0x4df0c8>-0x1&&_0xfe5817['splice'](_0x4df0c8,0x1);}}function _0x561bfd(_0x5c91b2){const _0xd241cf=_0x5c91b2['split'](':');return{'group':_0xd241cf[0x0],'type':_0xd241cf[0x1],'subType':_0xd241cf['length']>=0x5?_0xd241cf[0x2]:null,'id':_0xd241cf['length']<0x5?_0xd241cf[0x2]:_0xd241cf[0x3],'authorId':_0xd241cf['length']<0x5?_0xd241cf[0x3]:_0xd241cf[0x4],'markerCount':0x6==_0xd241cf['length']?_0xd241cf[0x5]:null};}function _0x3a69b4(_0x4f5b74){for(let _0x1a6b90=0x0;_0x1a6b90<_0xfe5817['length'];_0x1a6b90++){if(_0x4f5b74['isAdded']&&'insertion'==_0xfe5817[_0x1a6b90]['type'])return _0x4f5b74['isAddSuggestion']=_0xfe5817[_0x1a6b90],void delete _0x4f5b74['isAdded'];if(!_0x4f5b74['isAdded']&&!_0x4f5b74['isRemoved']&&'deletion'==_0xfe5817[_0x1a6b90]['type'])return void(_0x4f5b74['isRemoveSuggestion']=_0xfe5817[_0x1a6b90]);}}}['_setDistance'](_0x4343bd,_0x3e38f0){let _0x5546ed=0x0,_0x24a36d=!0x1;const _0x448662=new Map();for(const _0x2a5014 of _0x4343bd)_0x2a5014[_0x3e38f0]?_0x24a36d&&(_0x5546ed++,_0x24a36d=!0x1):(_0x5546ed++,_0x24a36d=!0x0),_0x448662['set'](_0x2a5014['id'],_0x5546ed);for(let _0x1afae3=0x0;_0x1afae3<_0x4343bd['length'];_0x1afae3++){if('isRemoved'==_0x3e38f0&&_0x4343bd[_0x1afae3]['isAdded']||'isAdded'==_0x3e38f0&&_0x4343bd[_0x1afae3]['isRemoved'])continue;if('text'==_0x4343bd[_0x1afae3]['type']){_0x4343bd[_0x1afae3]['distance']=0x0;continue;}const _0x5acab4=_0x448662['get'](_0x4343bd[_0x1afae3]['pairId']),_0x5a2b89=_0x448662['get'](_0x4343bd[_0x1afae3]['id']);_0x4343bd[_0x1afae3]['distance']=_0x5acab4-_0x5a2b89;}}['_getRevisionsRange'](_0x804df9,_0xbb5281,_0x4333b2=!0x1){const _0x4ae7fb=[];let _0x1e82a7=this['repository']['getIndex'](_0x804df9),_0x3766ec=this['repository']['getIndex'](_0xbb5281);for(-0x1==_0x3766ec&&(_0x3766ec=this['repository']['_revisions']['length'],_0x4333b2=!0x1);_0x1e82a7<_0x3766ec;)_0x4ae7fb['push'](this['repository']['getRevision'](_0x1e82a7)),_0x1e82a7++;return _0x4333b2&&_0x4ae7fb['push'](this['repository']['getRevision'](_0x1e82a7)),_0x4ae7fb;}['_threeWayMerge'](_0x103f1b,_0x296212,_0x125d29,_0x11d4d3){const _0x1529fe=this['editor']['model']['schema'];let _0x5e1d61=_0x296212;for(;_0x103f1b[_0x5e1d61]&&_0x103f1b[_0x5e1d61]['isAdded'];)_0x5e1d61++;let _0x4d1f43=_0x11d4d3;for(;_0x125d29[_0x4d1f43]&&_0x125d29[_0x4d1f43]['isRemoved'];)_0x4d1f43++;_0x246161(_0x103f1b,_0x296212,_0x5e1d61),_0x246161(_0x125d29,_0x11d4d3,_0x4d1f43);const _0x14c392=_0x125d29['slice'](_0x11d4d3,_0x4d1f43)['concat'](_0x103f1b['slice'](_0x296212,_0x5e1d61));return _0x14c392['sort']((_0x520b04,_0x565b23)=>_0x520b04['side']!=_0x565b23['side']?_0x520b04['side']-_0x565b23['side']:_0x520b04['level']!=_0x565b23['level']?_0x520b04['level']-_0x565b23['level']:_0x520b04['distance']!=_0x565b23['distance']?_0x565b23['distance']-_0x520b04['distance']:!!_0x520b04['isAdded']!=!!_0x565b23['isAdded']?-0x1==_0x520b04['side']||0x0==_0x520b04['side']?_0x520b04['isAdded']?-0x1:0x1:_0x520b04['isAdded']?0x1:-0x1:_0x520b04['index']-_0x565b23['index']),{'commonTape':_0x14c392,'iEnd':_0x5e1d61,'jEnd':_0x4d1f43};function _0x246161(_0x5eebc9,_0x1bb94c,_0x368922){let _0x59a91c=-0x1,_0x1b0bef=Number['POSITIVE_INFINITY'],_0x2bf4f9=!0x0;for(let _0x21ca5a=_0x1bb94c;_0x21ca5a<_0x368922;_0x21ca5a++)if(_0x1529fe['isInline'](_0x5eebc9[_0x21ca5a]['item'])||(_0x2bf4f9=!0x1),_0x5eebc9[_0x21ca5a]['item']['startIndex']<_0x1bb94c&&(_0x59a91c=_0x21ca5a),_0x5eebc9[_0x21ca5a]['item']['endIndex']>=_0x368922){_0x1b0bef=_0x21ca5a;break;}_0x2bf4f9&&(_0x59a91c=_0x368922-0x1);for(let _0xcc7546=_0x1bb94c;_0xcc7546<_0x368922;_0xcc7546++)_0x5eebc9[_0xcc7546]['side']=_0xcc7546<=_0x59a91c?-0x1:_0xcc7546<_0x1b0bef?0x0:0x1,_0x5eebc9[_0xcc7546]['index']=_0xcc7546;let _0xf4fbe6=0x0;for(let _0x11ad34=_0x1bb94c;_0x11ad34<=_0x59a91c;_0x11ad34++)0x0==_0x5eebc9[_0x11ad34]['distance']?_0x5eebc9[_0x11ad34]['level']=_0xf4fbe6:(_0xf4fbe6++,_0x5eebc9[_0x11ad34]['level']=_0xf4fbe6,_0xf4fbe6++);for(let _0x2b6147=_0x1bb94c;_0x2b6147<_0x368922;_0x2b6147++)0x0==_0x5eebc9[_0x2b6147]['side']&&(_0x5eebc9[_0x2b6147]['level']=_0xf4fbe6);_0xf4fbe6=0x0;for(let _0xd1e902=_0x368922-0x1;_0xd1e902>=_0x1b0bef;_0xd1e902--)0x0==_0x5eebc9[_0xd1e902]['distance']?_0x5eebc9[_0xd1e902]['level']=_0xf4fbe6:(_0xf4fbe6--,_0x5eebc9[_0xd1e902]['level']=_0xf4fbe6,_0xf4fbe6--);}}['_fixObsoleteTags'](_0x61b3e5){const _0x1377da=new Map(),_0x1186d7=this['editor']['model']['schema'];for(let _0x5228be=0x1;_0x5228be<_0x61b3e5['length'];_0x5228be++){let _0x123233,_0x21e33f,_0x38f541;const _0x308370=_0x61b3e5[_0x5228be],_0x56d069=_0x61b3e5[_0x5228be-0x1];if('text'==_0x308370['type'])continue;if(_0x308370['type']!=_0x56d069['type'])continue;if(!_0x1186d7['isBlock'](_0x56d069['item'])||_0x1186d7['isLimit'](_0x56d069['item']))continue;if(!_0x1186d7['isBlock'](_0x308370['item'])||_0x1186d7['isLimit'](_0x308370['item']))continue;if((_0x61b3e5[_0x5228be]['isAdded']||_0x61b3e5[_0x5228be]['isAddSuggestion'])&&_0x61b3e5[_0x5228be-0x1]['isRemoved'])_0x123233=_0x61b3e5[_0x5228be],_0x21e33f=_0x61b3e5[_0x5228be-0x1],_0x38f541=_0x5228be-0x1;else{if(!_0x61b3e5[_0x5228be]['isRemoved']||!_0x61b3e5[_0x5228be-0x1]['isAdded']&&!_0x61b3e5[_0x5228be-0x1]['isAddSuggestion'])continue;_0x123233=_0x61b3e5[_0x5228be-0x1],_0x21e33f=_0x61b3e5[_0x5228be],_0x38f541=_0x5228be;}const _0x15fa3a=_0x123233['level']==_0x21e33f['level'],_0x111fa1=Math['abs'](_0x123233['level'])<Math['abs'](_0x21e33f['level'])&&0x0==_0x21e33f['distance'];(_0x15fa3a||_0x111fa1)&&(_0x1377da['set'](_0x21e33f['id'],_0x123233['id']),_0x61b3e5['splice'](_0x38f541,0x1),_0x5228be--,_0x123233['isAdded']=!0x1);}for(let _0x2635ce=0x0;_0x2635ce<_0x61b3e5['length'];_0x2635ce++)_0x1377da['has'](_0x61b3e5[_0x2635ce]['pairId'])&&(_0x61b3e5[_0x2635ce]['pairId']=_0x1377da['get'](_0x61b3e5[_0x2635ce]['pairId']));}['_removeMissingPairs'](_0x53e4a8){const _0x4413bf=new Set(_0x53e4a8['map'](_0x567dd5=>_0x567dd5['id']));for(let _0x38035d=0x0;_0x38035d<_0x53e4a8['length'];_0x38035d++)_0x4413bf['has'](_0x53e4a8[_0x38035d]['pairId'])||0x0==_0x53e4a8[_0x38035d]['distance']||(_0x53e4a8[_0x38035d]['isIncorrect']=!0x0);return _0x53e4a8['filter'](_0x401a68=>!_0x401a68['isIncorrect']);}['_markMismatchedRemovedTags'](_0x32b4c8){const _0x216d84=new Set();for(let _0x76f8fd=0x0;_0x76f8fd<_0x32b4c8['length'];_0x76f8fd++){if(_0x216d84['has'](_0x32b4c8[_0x76f8fd]['id'])&&_0x32b4c8[_0x76f8fd]['isRemoved']&&(_0x32b4c8[_0x76f8fd]['isIncorrect']=!0x0),_0x32b4c8[_0x76f8fd]['isIncorrect'])continue;if(0x0==_0x32b4c8[_0x76f8fd]['distance'])continue;if('elementStart'!=_0x32b4c8[_0x76f8fd]['type'])continue;if(null==_0x32b4c8[_0x76f8fd]['pairId'])continue;let _0x537653=_0x76f8fd+0x1,_0x3cc816=0x0;for(;_0x32b4c8[_0x537653]['id']!=_0x32b4c8[_0x76f8fd]['pairId'];)'elementStart'==_0x32b4c8[_0x537653]['type']?_0x3cc816++:'elementEnd'==_0x32b4c8[_0x537653]['type']&&_0x3cc816--,_0x537653++;if(0x0!=_0x3cc816){if(_0x32b4c8[_0x76f8fd]['isRemoved'])_0x32b4c8[_0x76f8fd]['isIncorrect']=!0x0;else{for(;_0x537653!=_0x76f8fd;)_0x32b4c8[_0x537653]['isRemoved']&&0x0!=_0x32b4c8[_0x537653]['distance']&&(_0x32b4c8[_0x537653]['isIncorrect']=!0x0,_0x216d84['add'](_0x32b4c8[_0x537653]['pairId'])),_0x537653--;}}}return _0x32b4c8['filter'](_0x49f4bd=>!_0x49f4bd['isIncorrect']);}['_removeUnsupportedChanges'](_0x59b051){const _0x3fb34d=this['editor']['model']['schema'];for(let _0x2657cf=0x0;_0x2657cf<_0x59b051['length'];_0x2657cf++){if(!(_0x59b051[_0x2657cf]['isAdded']||_0x59b051[_0x2657cf]['isAddSuggestion']||_0x59b051[_0x2657cf]['isRemoved']||_0x59b051[_0x2657cf]['isRemoveSuggestion']))continue;if(0x0==_0x59b051[_0x2657cf]['distance'])continue;const _0x2a8dd3=_0x59b051[_0x2657cf]['item'];_0x3fb34d['isBlock'](_0x2a8dd3)||_0x3fb34d['isLimit'](_0x2a8dd3)||(_0x59b051[_0x2657cf]['isAdded']&&delete _0x59b051[_0x2657cf]['isAdded'],_0x59b051[_0x2657cf]['isAddSuggestion']&&delete _0x59b051[_0x2657cf]['isAddSuggestion'],_0x59b051[_0x2657cf]['isRemoveSuggestion']&&delete _0x59b051[_0x2657cf]['isRemoveSuggestion'],_0x59b051[_0x2657cf]['isRemoved']&&(_0x59b051[_0x2657cf]['isIncorrect']=!0x0));}return _0x59b051['filter'](_0x251ad8=>!_0x251ad8['isIncorrect']);}['_makeModelFromTape'](_0x5bc502,_0x1ba39a,_0x2c5f87){const _0x32c31b=new vt(),_0x1f71dd=[],_0x2a032c=new Map(),_0x149e4d=this['editor']['model'],_0xc8f48d=_0x149e4d['schema'],_0x2ffc95=[_0x32c31b],_0x3567e8={},_0x36e3cd={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x18ba53=null;const _0x5c4347=[0x0];for(let _0x5028a4=0x0;_0x5028a4<_0x5bc502['length'];_0x5028a4++)if('elementStart'===_0x5bc502[_0x5028a4]['type']){_0x5bc502[_0x5028a4]['previousPosition']=_0x149e4d['createPositionFromPath'](_0x32c31b,_0x5c4347);const _0x5f2d4e=new ut(_0x5bc502[_0x5028a4]['item']['name'],_0x5bc502[_0x5028a4]['item']['getAttributes']());_0x2ffc95[0x0]['_appendChild'](_0x5f2d4e),_0x5c4347['push'](0x0),_0x2ffc95['unshift'](_0x5f2d4e),_0x5bc502[_0x5028a4]['nextPosition']=_0x149e4d['createPositionFromPath'](_0x32c31b,_0x5c4347);}else'elementEnd'===_0x5bc502[_0x5028a4]['type']?(_0x2ffc95['shift'](),_0x5bc502[_0x5028a4]['previousPosition']=_0x149e4d['createPositionFromPath'](_0x32c31b,_0x5c4347),_0x5c4347['pop'](),_0x5c4347[_0x5c4347['length']-0x1]++,_0x5bc502[_0x5028a4]['nextPosition']=_0x149e4d['createPositionFromPath'](_0x32c31b,_0x5c4347)):(_0x5bc502[_0x5028a4]['previousPosition']=_0x149e4d['createPositionFromPath'](_0x32c31b,_0x5c4347),_0x18ba53?_0x18ba53['_data']+=_0x5bc502[_0x5028a4]['item']['data']:_0x18ba53=new gt(_0x5bc502[_0x5028a4]['item']['data'],_0x5bc502[_0x5028a4]['item']['getAttributes']()),_0x5bc502[_0x5028a4+0x1]&&'text'===_0x5bc502[_0x5028a4+0x1]['type']&&_0x5232db(_0x18ba53,_0x5bc502[_0x5028a4+0x1]['item'])||(_0x2ffc95[0x0]['_appendChild'](_0x18ba53),_0x18ba53=null),_0x5c4347[_0x5c4347['length']-0x1]+=_0x5bc502[_0x5028a4]['item']['offsetSize'],_0x5bc502[_0x5028a4]['nextPosition']=_0x149e4d['createPositionFromPath'](_0x32c31b,_0x5c4347));for(let _0x3a8803=0x0;_0x3a8803<_0x5bc502['length'];_0x3a8803++){const _0x2807ee=_0x5bc502[_0x3a8803]['previousPosition'],_0x571e23=_0x5bc502[_0x3a8803]['nextPosition'];for(const _0x41fcea of _0x5bc502[_0x3a8803]['markersStart'])_0x2a032c['set'](_0x41fcea,{'start':_0x2807ee,'end':null});_0x5804f9('isRemoveSuggestion',_0x3a8803,_0x2807ee,_0x571e23),_0x5804f9('isAddSuggestion',_0x3a8803,_0x2807ee,_0x571e23),_0x5804f9('isRemoved',_0x3a8803,_0x2807ee,_0x571e23),_0x5804f9('isAdded',_0x3a8803,_0x2807ee,_0x571e23);for(const _0x2a28e4 of _0x5bc502[_0x3a8803]['markersEnd']){const _0xe8ef85=_0x2a032c['get'](_0x2a28e4);_0xe8ef85?_0xe8ef85['end']=_0x571e23:_0x2a032c['set'](_0x2a28e4,{'start':_0x571e23,'end':_0x571e23});}}for(const [_0x12bb72,_0x152c8b]of _0x2a032c){const _0x548e4c=this['editor']['model']['createRange'](_0x152c8b['start'],_0x152c8b['end']);_0x32c31b['markers']['set'](_0x12bb72,_0x548e4c);}return _0x1f71dd['sort']((_0x3f7b0e,_0x36672d)=>{const _0x493bf2=_0x32c31b['markers']['get']('revision:'+_0x3f7b0e['id']),_0xa3afb6=_0x32c31b['markers']['get']('revision:'+_0x36672d['id']);return _0x493bf2['start']['isBefore'](_0xa3afb6['start'])?-0x1:_0x493bf2['start']['isAfter'](_0xa3afb6['start'])?0x1:_0x493bf2['end']['isBefore'](_0xa3afb6['end'])?-0x1:_0x493bf2['end']['isAfter'](_0xa3afb6['end'])?0x1:'add'===_0x3f7b0e['type']?-0x1:0x1;}),{'root':_0x32c31b,'changes':_0x1f71dd};function _0x5804f9(_0x1af983,_0x31b5f6,_0x5b2e9e,_0x4c730b){const _0xed9f79=!!_0x5bc502[_0x31b5f6][_0x1af983],_0x840e00=_0xed9f79?_0x5bc502[_0x31b5f6][_0x1af983]['userId']:null,_0x19df2c=_0x31b5f6===_0x5bc502['length']-0x1,_0x5b5f15=_0x36e3cd[_0x1af983][0x0],_0x42c1a1=_0xc8f48d['isObject'](_0x5bc502[_0x31b5f6]['item']);!_0x3567e8[_0x1af983]&&_0xed9f79?_0x3567e8[_0x1af983]={'start':_0x5b2e9e,'tapeItem':_0x5bc502[_0x31b5f6],'userId':_0x840e00,'type':_0x1af983}:_0x3567e8[_0x1af983]&&!_0xed9f79?(_0x3567e8[_0x1af983]['end']=_0x5b2e9e,_0x3db3bb(_0x3567e8[_0x1af983]),_0x3567e8[_0x1af983]=null):_0x3567e8[_0x1af983]&&_0xed9f79&&_0x3567e8[_0x1af983]['userId']!==_0x840e00&&(_0x3567e8[_0x1af983]['end']=_0x5b2e9e,_0x5b5f15&&_0x5b5f15['userId']===_0x3567e8[_0x1af983]['userId']||_0x3db3bb(_0x3567e8[_0x1af983]),_0x3567e8[_0x1af983]={'start':_0x5b2e9e,'tapeItem':_0x5bc502[_0x31b5f6],'userId':_0x840e00,'type':_0x1af983}),_0x3567e8[_0x1af983]&&_0x42c1a1&&('elementStart'!==_0x5bc502[_0x31b5f6]['type']||_0x5b5f15&&_0x5b5f15['userId']===_0x840e00||_0x36e3cd[_0x1af983]['unshift']({'userId':_0x840e00,'object':_0x5bc502[_0x31b5f6]['item'],'change':_0x3567e8[_0x1af983]}),'elementEnd'===_0x5bc502[_0x31b5f6]['type']&&_0x5b5f15&&_0x5b5f15['object']===_0x5bc502[_0x31b5f6]['item']&&(_0x36e3cd[_0x1af983]['shift'](),_0x3567e8[_0x1af983]=_0x5b5f15['change'])),_0x3567e8[_0x1af983]&&_0x19df2c&&(_0x3567e8[_0x1af983]['end']=_0x4c730b,_0x3db3bb(_0x3567e8[_0x1af983]),_0x3567e8[_0x1af983]=null);}function _0x3db3bb({start:_0x35dcd2,end:_0x1252ed,tapeItem:_0x357b2d,userId:_0x2abe0a,type:_0x33a14a}){const _0x267144=_0x357b2d['item'],_0x521ee8=_0x149e4d['schema']['isBlock'](_0x267144)&&!_0x149e4d['schema']['isLimit'](_0x267144),_0x51914f=_0x35dcd2['nodeAfter']==_0x1252ed['parent']&&_0x1252ed['isAtStart'];if(_0x521ee8&&_0x51914f)return;const _0x1ca38f=_0x149e4d['createRange'](_0x35dcd2,_0x1252ed),_0x5e08c4=_0x1ba39a['get'](_0x2abe0a),_0x439565=new r({'author':_0x5e08c4,'type':'isAdded'==_0x33a14a||'isAddSuggestion'==_0x33a14a?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x33a14a||'isRemoveSuggestion'==_0x33a14a},'createdAt':new Date(),'rootName':_0x2c5f87});_0x1f71dd['push'](_0x439565),_0x32c31b['markers']['set']('revision:'+_0x439565['id'],_0x1ca38f);}function _0x5232db(_0x59290e,_0x5978ad){const _0x13b412=_0x59290e['getAttributes'](),_0x188141=_0x5978ad['getAttributes']();for(const _0x53774c of _0x13b412){if(_0x53774c[0x1]!==_0x5978ad['getAttribute'](_0x53774c[0x0]))return!0x1;_0x188141['next']();}return _0x188141['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x4935f5=>{const _0x2eb3e7=_0x4935f5['markerName']['split'](':')[0x1],_0x37a93d=this['_getChangeFromId'](_0x2eb3e7);if(!_0x37a93d)return null;const _0x50a848='add'==_0x37a93d['type']?'insertion':'deletion',_0x15523f=['ck-suggestion-marker','ck-suggestion-marker-'+_0x50a848];return _0x37a93d['data']['isSuggestion']&&_0x15523f['push']('ck-suggestion-marker-'+_0x50a848+'-new'),this['activeChange']==_0x37a93d&&_0x15523f['push']('ck-suggestion-marker--active'),{'classes':_0x15523f,'attributes':{'data-change-id':_0x2eb3e7}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x35ee84=>{_0x35ee84['on']('element:pre',(_0x9e2c6d,_0x374c19,_0x274650)=>{const _0x89b1d9=_0x374c19['viewItem']['getChild'](0x0);if(!_0x89b1d9||!_0x89b1d9['is']('element','code'))return;if(!_0x274650['consumable']['consume'](_0x89b1d9,{'attributes':['vid_start','vid_end']}))return;const _0x305a81=_0x374c19['modelRange']['start']['nodeAfter'];_0x274650['writer']['setAttribute']('vid_start',_0x89b1d9['getAttribute']('vid_start'),_0x305a81),_0x274650['writer']['setAttribute']('vid_end',_0x89b1d9['getAttribute']('vid_end'),_0x305a81);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x45721f=>{_0x45721f['on']('element',(_0x21fedd,_0x1b3dcf,_0x5aac4f)=>{if(!_0x5aac4f['consumable']['consume'](_0x1b3dcf['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x1b3dcf['modelRange']['isCollapsed'])return;const _0x5184f2=_0x1b3dcf['modelRange']['start']['nodeAfter'];_0x5184f2['hasAttribute']('vid_start')||_0x5184f2['hasAttribute']('vid')||(_0x5aac4f['writer']['setAttribute']('vid_start',_0x1b3dcf['viewItem']['getAttribute']('vid_start'),_0x5184f2),_0x5aac4f['writer']['setAttribute']('vid_end',_0x1b3dcf['viewItem']['getAttribute']('vid_end'),_0x5184f2));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x3fb7a5=>_0x3fb7a5['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0xf6cca7,[,_0x1c60e1])=>{['vid_start','vid_end','vid']['includes'](_0x1c60e1)&&(_0xf6cca7['return']=!0x0,_0xf6cca7['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x1f8cb3=>{_0x1f8cb3['on']('attribute:vid',(_0x332934,_0x33fe17,_0x42e93a)=>{if('\x20'!=_0x33fe17['item']['data']||_0x33fe17['item']['parent']['maxOffset']>0x1)return;if(!_0x42e93a['consumable']['consume'](_0x33fe17['item'],_0x332934['name']))return;const _0x5c0632=_0x42e93a['writer'],_0x45b476=_0x42e93a['mapper']['toViewRange'](_0x33fe17['range']);_0x5c0632['wrap'](_0x45b476,_0x5c0632['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x12df12){const _0x4ab972=_0x12df12['plugins']['get']('RevisionViewer');return(_0x24ce7b,_0x38f7d2,_0x40e190)=>{const _0x22244b=_0x38f7d2['markerName']['split'](':')[0x1],_0x99176e=_0x4ab972['_getChangeFromId'](_0x22244b);if(!_0x99176e)return null;const _0x475eba='add'==_0x99176e['type']?'split':'merge';if(!_0x40e190['consumable']['test'](_0x38f7d2['markerRange'],_0x24ce7b['name']))return;const _0xdc65b9=_0x38f7d2['markerRange']['getWalker'](),_0x5e30e9=_0x38f7d2['markerRange']['start'],_0x1f976=_0x12df12['model']['schema'];let _0x20aec9=null,_0x35bded=null,_0x4dc5ce=!0x1,_0x23d39a=!0x1;for(const _0x3b9368 of _0xdc65b9){const _0x11483a=_0x3b9368['item'];_0x4dc5ce=_0x4dc5ce||_0x1f976['isContent'](_0x11483a);const _0x475a53=_0x40e190['mapper']['toViewElement'](_0x11483a);if(_0x475a53&&_0x475a53['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x3b9368['type']&&(_0x1f976['isBlock'](_0x11483a)&&!_0x1f976['isLimit'](_0x11483a)&&(_0x11483a['nextSibling']||_0x5e30e9['isAtEnd']?_0x20aec9&&_0x20aec9['parent']==_0x11483a||(_0x20aec9=_0x11483a,_0x1bb138(_0x3b9368['previousPosition']),_0x23d39a=!0x0):_0x35bded=_0x35bded||_0x3b9368['previousPosition']));}function _0x1bb138(_0x590278){const _0x23f5e5=_0x40e190['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x475eba}),_0xa48fbc=_0x40e190['mapper']['toViewPosition'](_0x590278);_0x99176e['data']['isSuggestion']&&_0x40e190['writer']['addClass']('ck-suggestion-marker-'+_0x475eba+'-new',_0x23f5e5),_0x4ab972['activeChange']==_0x99176e&&_0x40e190['writer']['addClass']('ck-suggestion-marker--active',_0x23f5e5),_0x40e190['writer']['insert'](_0xa48fbc,_0x23f5e5),_0x40e190['mapper']['bindElementToMarker'](_0x23f5e5,_0x38f7d2['markerName']);}_0x4dc5ce||_0x23d39a||!_0x35bded||_0x1bb138(_0x35bded);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x26e0e2,_0x1147b1,_0xac7386)=>{const _0x2f1bb1=_0xac7386['mapper']['markerNameToElements'](_0x1147b1['markerName']);if(_0x2f1bb1){for(const _0x3a992d of _0x2f1bb1)(_0x3a992d['hasClass']('ck-suggestion-marker-split')||_0x3a992d['hasClass']('ck-suggestion-marker-merge'))&&(_0xac7386['mapper']['unbindElementFromMarkerName'](_0x3a992d,_0x1147b1['markerName']),_0xac7386['writer']['remove'](_0x3a992d));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x2b81b5,_0x52efda,_0x323221)=>{const _0x85da72=_0x52efda['markerName']['split'](':')[0x1],_0x42d7dc=this['_getChangeFromId'](_0x85da72);if(!_0x42d7dc)return null;const _0x252d7a='add'==_0x42d7dc['type']?'split':'merge';if(_0x323221['consumable']['test'](_0x52efda['markerRange'],_0x2b81b5['name']))for(const _0x1b65d7 of _0x52efda['markerRange']['getItems']()){if(!_0x1b65d7['is']('element','softBreak'))continue;const _0x2bcbab=_0x323221['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x252d7a}),_0x511154=_0x323221['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x1b65d7));_0x42d7dc['data']['isSuggestion']&&_0x323221['writer']['addClass']('ck-suggestion-marker-'+_0x252d7a+'-new',_0x2bcbab),this['activeChange']==_0x42d7dc&&_0x323221['writer']['addClass']('ck-suggestion-marker--active',_0x2bcbab),_0x323221['writer']['insert'](_0x511154,_0x2bcbab),_0x323221['mapper']['bindElementToMarker'](_0x2bcbab,_0x52efda['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x1bef15=>{for(const _0x39efc8 of this['editor']['model']['document']['getRootNames']()){const _0x2c9ad6=this['editor']['model']['document']['getRoot'](_0x39efc8),_0x145467=this['editor']['editing']['view']['document']['getRoot'](_0x39efc8);if(_0x145467){const _0x4dba2f=_0x2c9ad6['getAttribute']('revisionHistoryAttachChange');if(_0x1bef15['removeAttribute']('data-change-id',_0x145467),_0x1bef15['removeClass']('ck-revision-history-root-add',_0x145467),_0x1bef15['removeClass']('ck-revision-history-root-remove',_0x145467),_0x1bef15['removeClass']('ck-revision-history-root--active',_0x145467),_0x4dba2f){const _0x2e6f79=this['_getChangeFromId'](_0x4dba2f);if(!_0x2e6f79)return null;_0x1bef15['setAttribute']('data-change-id',_0x4dba2f,_0x145467),_0x1bef15['addClass']('ck-revision-history-root-'+_0x2e6f79['type'],_0x145467),this['activeChange']==_0x2e6f79&&_0x1bef15['addClass']('ck-revision-history-root--active',_0x145467);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x396cdd=>'revision-comment:'+_0x396cdd,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x3f504e=>'revision-suggestion:'+_0x3f504e,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x5899c7=>({'name':'suggestion:'+_0x5899c7,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0xbd161d=>{const _0x315f6c=_0xbd161d['markerName']['split'](':')[0x1];return'insertion'!=_0x315f6c&&'deletion'!=_0x315f6c?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x315f6c]};}}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:deletion',X(this['editor'],'merge'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:insertion',X(this['editor'],'split'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision-suggestion',(_0x23edeb,_0x16491f,_0x591cfb)=>{const _0x4f82a4=_0x591cfb['mapper']['markerNameToElements'](_0x16491f['markerName']);if(_0x4f82a4){for(const _0x46e315 of _0x4f82a4)_0x46e315['is']('uiElement')&&(_0x591cfb['mapper']['unbindElementFromMarkerName'](_0x46e315,_0x16491f['markerName']),_0x591cfb['writer']['remove'](_0x46e315));}},{'priority':'high'});}['_getChangeFromId'](_0x233a80){return this['_changeIdToChange']['get'](_0x233a80);}['_getViewForChange'](_0x125bd3){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new Q(this['editor']['locale'],_0x125bd3),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x3d8687,_0x2fc7d2,_0x6eae58,_0x1fd23c)=>{_0x1fd23c&&this['_balloon']['remove'](_0x1fd23c),_0x6eae58&&(this['_balloon']['add']({'view':_0x6eae58,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x3aa70c=this['editor']['editing'],_0x15d673=this['_getChangeFromId'](_0x6eae58['changeId']);let _0x4049f3;if(_0x15d673['data']['isOnRoot']){const _0x30d04=_0x3aa70c['view']['getDomRoot'](_0x15d673['rootName']);_0x4049f3=Array['from'](_0x30d04['getClientRects']());}else{const _0x349f9a=this['editor']['model']['markers']['get']('revision:'+_0x6eae58['changeId']);_0x4049f3=Array['from'](_0x3aa70c['mapper']['markerNameToElements'](_0x349f9a['name']))['map'](_0x4a10af=>_0x3aa70c['view']['domConverter']['mapViewToDom'](_0x4a10af))['map'](_0x2ed3ec=>Array['from'](_0x2ed3ec['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x4049f3[0x0];return _0x4049f3['find'](_0x39d29d=>_0x39d29d['top']-0x3<=this['_activeViewTarget']['y']&&_0x39d29d['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x39d29d['left']-0x3<=this['_activeViewTarget']['x']&&_0x39d29d['right']+0x3>=this['_activeViewTarget']['x'])||_0x4049f3[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x5a78f9,_0x42979b,_0x4cb6af,_0x1dd68c)=>{this['activeView']=_0x4cb6af?this['_getViewForChange'](_0x4cb6af):null,this['editor']['model']['change'](()=>{const _0x36f02b=this['editor']['editing'];_0x1dd68c&&(_0x1dd68c['data']['isOnRoot']?_0x36f02b['view']['change'](_0x49fd32=>{_0x49fd32['removeClass']('ck-revision-history-root--active',_0x36f02b['view']['document']['getRoot'](_0x1dd68c['rootName']));}):_0x36f02b['reconvertMarker']('revision:'+_0x1dd68c['id'])),_0x4cb6af&&(_0x4cb6af['data']['isOnRoot']?_0x36f02b['view']['change'](_0x343cfd=>{_0x343cfd['addClass']('ck-revision-history-root--active',_0x36f02b['view']['document']['getRoot'](_0x4cb6af['rootName']));}):_0x36f02b['reconvertMarker']('revision:'+_0x4cb6af['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x35f5e0,_0x27ced9)=>{if(this['activeChange'])return;const _0x337c06=this['_findChangeIdFromDomTarget'](_0x27ced9['target']),_0x59395e=this['_changeIdToChange']['get'](_0x337c06);_0x59395e?(this['_activeViewTarget']={'x':_0x27ced9['domEvent']['x'],'y':_0x27ced9['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x59395e)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x50dd28,_0xfe73a6)=>{const _0x579086=this['_findChangeIdFromDomTarget'](_0xfe73a6['target']),_0x363b13=this['_changeIdToChange']['get'](_0x579086);_0x363b13?(this['_activeViewTarget']={'x':_0xfe73a6['domEvent']['x'],'y':_0xfe73a6['domEvent']['y']},_0x363b13===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x363b13):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x413b9b){do{const _0x3f8117=_0x413b9b['getAttribute']('data-change-id');if(_0x3f8117)return _0x3f8117;_0x413b9b=_0x413b9b['parent'];}while(_0x413b9b);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x47374f=>{for(const _0x3fbfad of this['editor']['model']['markers'])_0x47374f['removeMarker'](_0x3fbfad);});}}function X(_0x3086fe,_0x446f6f){return(_0xd65762,_0x5bd82f,_0x2b52fc)=>{if(!_0x2b52fc['consumable']['test'](_0x5bd82f['markerRange'],_0xd65762['name']))return;const _0x430e51=_0x5bd82f['markerRange']['getWalker'](),_0x2ef472=_0x5bd82f['markerRange']['start'],_0x43ce7b=_0x3086fe['model']['schema'];let _0xaa6f72=null,_0x446d6e=null,_0x424941=!0x1,_0x49235f=!0x1;for(const _0x1fbbec of _0x430e51){const _0x4bb688=_0x1fbbec['item'];_0x424941=_0x424941||_0x43ce7b['isContent'](_0x4bb688);const _0x52f37f=_0x2b52fc['mapper']['toViewElement'](_0x4bb688);if(_0x52f37f&&_0x52f37f['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x1fbbec['type']&&(_0x43ce7b['isBlock'](_0x4bb688)&&!_0x43ce7b['isLimit'](_0x4bb688)&&(_0x4bb688['nextSibling']||_0x2ef472['isAtEnd']?_0xaa6f72&&_0xaa6f72['parent']==_0x4bb688||(_0xaa6f72=_0x4bb688,_0x4aa3ce(_0x1fbbec['previousPosition']),_0x49235f=!0x0):_0x446d6e=_0x446d6e||_0x1fbbec['previousPosition']));}function _0x4aa3ce(_0x19023d){const _0xc7c72=_0x2b52fc['mapper']['toViewPosition'](_0x19023d),_0x3a1625=_0x2b52fc['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x446f6f});_0x2b52fc['writer']['insert'](_0xc7c72,_0x3a1625),_0x2b52fc['mapper']['bindElementToMarker'](_0x3a1625,_0x5bd82f['markerName']);}_0x424941||_0x49235f||!_0x446d6e||_0x4aa3ce(_0x446d6e);};}class mt extends _0x4ca95f{constructor(_0x57c5b3){super(_0x57c5b3);const _0x13efda=_0x57c5b3['plugins']['get'](m);this['affectsData']=!0x1,this['listenTo'](_0x13efda,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x13efda,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x59066d=this['editor'],_0x55f735=_0x59066d['plugins']['get'](m),_0x1acd66=_0x55f735['isReady']?_0x55f735['diff']['newRevisionId']:null;_0x59066d['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x1acd66);}['refresh'](){const {isReady:_0x21d116,isEnabled:_0xa5f3a8,repository:_0x10025a,diff:_0x24c1a8}=this['editor']['plugins']['get'](m),_0x47b049=_0x24c1a8&&_0x10025a['getLaterVisibleRevision'](_0x24c1a8['newRevisionId']);this['isEnabled']=_0x21d116&&_0xa5f3a8&&Boolean(_0x47b049);}}class wt extends _0x4ca95f{['_step'];constructor(_0x18995d,{direction:_0x406a83}){super(_0x18995d);const _0xa13017=_0x18995d['plugins']['get'](m);this['affectsData']=!0x1,this['_step']='forward'===_0x406a83?0x1:-0x1,this['listenTo'](_0xa13017,'change:isReady',()=>this['refresh']()),this['listenTo'](_0xa13017,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0xa13017,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x272af7=this['editor'],_0x268998=_0x272af7['plugins']['get'](m),{isNavigationMode:_0x759eee,currentChangeNumber:_0x1b704c}=_0x268998;let _0x3cb1dc;if(_0x268998['activeChange']=_0x759eee?_0x268998['diff']['changes']['get'](_0x1b704c+this['_step']):_0x268998['diff']['changes']['first'],_0x268998['activeChange']['data']['isOnRoot'])_0x3cb1dc=_0x272af7['editing']['view']['getDomRoot'](_0x268998['activeChange']['rootName']);else{const _0x268ff9=_0x272af7['model']['markers']['get']('revision:'+_0x268998['activeChange']['id']);_0x3cb1dc=_0x3ab3e0(_0x272af7['editing'],_0x268ff9);}_0x31a828({'target':_0x3cb1dc,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x5b54bd,currentChangeNumber:_0x136e71,numberOfChanges:_0xd0161f,isReady:_0x5cb2b7,isEnabled:_0x4279cb}=this['editor']['plugins']['get'](m);this['isEnabled']=!!(_0x4279cb&&_0x5cb2b7&&_0xd0161f)&&(!_0x5b54bd||(0x1===this['_step']?_0x136e71<_0xd0161f-0x1:_0x136e71>0x0));}}class _i extends ts{constructor(_0x4c3e9f){super(_0x4c3e9f);const _0xed3b11=this['bindTemplate'],_0x454b66=new te(_0x4c3e9f),_0x21faec=new te(_0x4c3e9f);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',(_0x1de24e,_0x5d7927)=>_0x1de24e&&_0x5d7927>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0xf016b4,_0x5c0ff3,_0x37b934,_0x19edea)=>{if(!_0xf016b4)return g(_0x4c3e9f,'Loading...');if(!_0x37b934)return g(_0x4c3e9f,'No\x20changes');const _0x175153=g(_0x4c3e9f,'NUMBER_OF_CHANGES',_0x37b934);return _0x19edea?g(_0x4c3e9f,'X_OF_Y_CHANGES',[_0x5c0ff3+0x1,_0x37b934]):_0x175153;}),_0x454b66['set']({'label':g(_0x4c3e9f,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x561f5e}),_0x21faec['set']({'label':g(_0x4c3e9f,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x4300e8}),_0x454b66['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x21faec['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x454b66['on']('execute',()=>this['fire']('execute','backward')),_0x21faec['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',_0xed3b11['if']('_isStatusLabelVisible','ck-hidden',_0x1c35a4=>!_0x1c35a4)]},'children':[{'text':_0xed3b11['to']('isNavigationMode',_0x5cfd99=>_0x5cfd99?g(_0x4c3e9f,'EDIT_X_OF_Y_REVISIONS')+':\x20':g(_0x4c3e9f,'Total')+':\x20')}]},{'text':_0xed3b11['to']('_statusText')}]},new _0x134577(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x454b66,_0x21faec]}]});}}const le='ck-editor__editable__loading-overlay';class ge extends _0xc858c4{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x5fad74=this['editor']['editing']['view'];_0x5fad74['change'](_0xe1fdce=>{for(const _0x542d07 of _0x5fad74['document']['roots'])_0xe1fdce['addClass'](le,_0x542d07);});}['hide'](){const _0x10898c=this['editor']['editing']['view'];_0x10898c['change'](_0x120ed8=>{for(const _0x52123 of _0x10898c['document']['roots'])_0x120ed8['removeClass'](le,_0x52123);});}}class R extends _0xc858c4{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[m,ge];}['init'](){const _0x44be6f=this['editor'],_0x4df2d2=_0x44be6f['plugins']['get'](m),_0x119492=_0x44be6f['plugins']['get'](ge);_0x44be6f['ui']['componentFactory']['add']('exitToEditing',_0x6bb6e=>{const _0x5bbbd0=new te(_0x6bb6e);return _0x5bbbd0['set']({'label':g(_0x6bb6e,'Back\x20to\x20editing'),'icon':_0x4cc4d4,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x5bbbd0,'execute',()=>{_0x44be6f['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x5bbbd0;}),_0x44be6f['ui']['componentFactory']['add']('restoreRevision',_0x2fdf29=>{const _0x1930f7=new te(_0x2fdf29);return _0x1930f7['set']({'label':g(_0x2fdf29,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x1930f7['bind']('isEnabled')['to'](_0x44be6f['commands']['get']('restoreRevision')),this['listenTo'](_0x1930f7,'execute',()=>_0x44be6f['execute']('restoreRevision')),_0x1930f7;}),_0x44be6f['ui']['componentFactory']['add']('changesNavigation',_0x3c7a83=>{const _0xb9970e=new _i(_0x3c7a83),_0x44b122=_0x44be6f['commands']['get']('showPreviousChange'),_0x48886a=_0x44be6f['commands']['get']('showNextChange');return _0xb9970e['bind']('isBackwardNavigationEnabled')['to'](_0x44b122,'isEnabled'),_0xb9970e['bind']('isForwardNavigationEnabled')['to'](_0x48886a,'isEnabled'),_0xb9970e['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x4df2d2),this['listenTo'](_0xb9970e,'execute',(_0x2a6fa9,_0x4486d4)=>{_0x44be6f['execute']('forward'===_0x4486d4?'showNextChange':'showPreviousChange');}),_0xb9970e;}),_0x119492['show'](),_0x4df2d2['on']('change:isReady',(_0x5e27dc,_0x143995,_0x304909)=>{_0x304909?_0x119492['hide']():_0x119492['show']();});}}class at extends _0xacc8af{['_resizeObserver']=null;constructor(_0x3025c3,_0x405efb){super(_0x3025c3,_0x405efb);const _0x29a35f=this['bindTemplate'];this['set']({'label':g(_0x3025c3,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=g(_0x3025c3,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x29a35f['to']('_tooltipString'),'data-cke-tooltip-position':'s','data-cke-tooltip-class':'ck-tooltip_multi-line'}});}['render'](){super['render'](),this['_resizeObserver']=new nt(this['fieldView']['element'],()=>this['_updateTooltipText']()),this['listenTo'](this['fieldView'],'input',()=>this['_updateTooltipText']());}['destroy'](){super['destroy'](),this['_resizeObserver']&&this['_resizeObserver']['destroy']();}['_updateTooltipText'](){const _0x297952=this['fieldView']['element'];this['_tooltipString']=_0x297952['scrollWidth']>_0x297952['clientWidth']&&_0x297952['value']||'';}}class si extends ts{constructor(_0x47d80a,_0x31a209,_0x7cd034){super(_0x47d80a);const _0x1dde40=new _0x2e0193();_0x1dde40['set']({'content':_0x29cf36,'viewBox':'0\x200\x2011\x2010'});const _0x1cd870=['ck','ck-revision-history-sidebar__revision-author'];_0x7cd034&&_0x1cd870['push']('ck-revision-history-sidebar__revision-author_creator');const _0x84586a=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':g(_0x47d80a,_0x7cd034?'Revision\x20creator':'Revision\x20author')},'children':[_0x1dde40,_0x31a209['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x1cd870},'children':_0x84586a});}}function oi(_0x26a25c,_0x54f18f){const _0xed0ffc=_0x26a25c['bindTemplate'],_0x1da4ad=_0x26a25c['locale'],_0x8710a4=_0x5f4b44(_0x1da4ad);_0x8710a4['panelPosition']='sw';const _0x21db9=function(_0x55426f,_0x32a27d){const _0x267756=function(_0x141a73,_0x965485){const _0x46654d=_0x141a73['locale'],_0x2bb6cc={'Compare\x20against\x20selected':g(_0x46654d,'Compare\x20against\x20selected'),'Name\x20this\x20revision':g(_0x46654d,'Name\x20this\x20revision'),'Restore\x20this\x20revision':g(_0x46654d,'Restore\x20this\x20revision')};return _0x965485['map'](_0x22e879=>{const _0x3797d0=_0x2bb6cc[_0x22e879['name']];return _0x3797d0&&_0x3797d0!==_0x22e879['name']&&(_0x22e879['name']=_0x3797d0),_0x22e879;});}(_0x55426f,_0x32a27d),_0x2f4fbe=new _0x58fbc2();for(const _0x1d2aea of _0x267756){const _0x2761={'type':'button','model':new to({'label':_0x1d2aea['name'],'class':_0x1d2aea['class'],'withText':!0x0,'role':'menuitem','_action':_0x1d2aea['action']})};_0x2761['model']['bind']('isEnabled')['to'](_0x55426f,'isActionsDropdownOpen',_0x6585ec=>'function'!=typeof _0x1d2aea['isEnabled']||(!_0x6585ec||_0x1d2aea['isEnabled'](_0x55426f))),_0x2f4fbe['add'](_0x2761);}return _0x2f4fbe;}(_0x26a25c,_0x54f18f);return _0x26a25c['bind']('isActionsDropdownOpen')['to'](_0x8710a4,'isOpen'),_0x8710a4['buttonView']['set']({'label':g(_0x1da4ad,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x5e73cb}),_0x8710a4['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0xed0ffc['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0xed0ffc['to'](_0x5bff71=>_0x5bff71['stopPropagation']())}}),_0x8710a4['on']('execute',_0x561373=>{_0x26a25c['isReady']&&'function'==typeof _0x561373['source']['_action']&&_0x561373['source']['_action'](_0x26a25c);}),_0x44ae0e(_0x8710a4,_0x21db9,{'role':'menu'}),_0x8710a4['listenTo'](_0x26a25c,'change:isActionsDropdownOpen',(_0x4a8d56,_0x151541,_0x26ad81)=>{if(_0x26ad81)for(const _0x571e1e of _0x8710a4['listView']['items']){const _0x338d8b=_0x571e1e['children']['first'],_0x175c04=_0x54f18f['find'](_0x3f1de9=>_0x3f1de9['action']===_0x338d8b['_action'])['isVisible'];_0x571e1e['isVisible']=void 0x0===_0x175c04||_0x175c04(_0x26a25c);}}),_0x8710a4;}class hi extends/* #__PURE__ -- @preserve */
26
+ ti(ts){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x471617,_0x1077de,_0x8314d3,_0x5cc5d2){super(_0x471617);const _0x2fe018=this['bindTemplate'],_0x4ba4fd=function(_0x325d08,_0x5e0ba3){const _0x17426a=Array['from'](_0x5e0ba3['authors'])['filter'](_0xc4b516=>_0xc4b516!=_0x5e0ba3['creator']);return _0x5e0ba3['creator']&&_0x17426a['unshift'](_0x5e0ba3['creator']),_0x17426a['map'](_0x248081=>new si(_0x325d08,_0x248081,_0x248081==_0x5e0ba3['creator']));}(_0x471617,_0x1077de);this['id']=_0x1077de['id'],this['_revision']=_0x1077de,this['_requireRevisionName']=_0x5cc5d2,this['bind']('name','createdAt')['to'](_0x1077de),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x5c6e5e=>{return _0xa20034=_0x471617['uiLanguage'],(_0x143c3a=_0x5c6e5e)['toLocaleDateString'](_0xa20034,{'month':'long','day':'numeric'})+',\x20'+_0x143c3a['toLocaleTimeString'](_0xa20034,{'hour':'numeric','minute':'numeric'});var _0xa20034,_0x143c3a;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new at(_0x471617,_0x5442b6),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x1a5319=>_0x1a5319||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x52c4c7,_0x10477a)=>_0x52c4c7&&_0x10477a),this['revisionActionsView']=_0x8314d3&&_0x8314d3['length']?oi(this,_0x8314d3):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x2fe018['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x2fe018['if']('isEnabled','ck-disabled',_0xad1f5b=>!_0xad1f5b),_0x2fe018['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x2fe018['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x2fe018['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':_0x2fe018['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':_0x4ba4fd}]},this['revisionActionsView']],'on':{'click':_0x2fe018['to'](_0x42245b=>{_0x42245b['srcElement']['closest']('.ck-thread__remove-confirm')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x590f9b=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x590f9b,'change',()=>{this['_requireRevisionName']&&!_0x590f9b['value']||this['fire']('setName',{'id':this['id'],'name':_0x590f9b['value']}),_0x590f9b['value']||(_0x590f9b['value']=this['name']?this['name']:this['_createdAtFormatted']);});}['select'](){this['isSelected']=!0x0;}['deselect'](){this['isSelected']=!0x1;}['highlight'](){this['isHighlighted']=!0x0;}['unhighlight'](){this['isHighlighted']=!0x1;}}function ai(_0x16aa5d,_0x2e2d69){const _0x5a216a=_0x5730c1['fromJSDate'](_0x16aa5d)['setLocale'](_0x2e2d69),_0x27aee2=_0x5730c1['local'](),_0x7e537b=_0x27aee2['minus']({'days':0x1})['startOf']('day');let _0x29e702,_0x418c9f;return _0x5a216a['hasSame'](_0x27aee2,'day')?(_0x29e702=_0x5a216a['startOf']('day')['toJSDate'](),_0x418c9f=_0x5a216a['toRelativeCalendar']()):_0x5a216a['hasSame'](_0x7e537b,'day')?(_0x29e702=_0x7e537b['toJSDate'](),_0x418c9f=_0x5a216a['toRelativeCalendar']()):_0x5a216a['hasSame'](_0x27aee2,'week')?(_0x29e702=_0x5a216a['startOf']('week')['toJSDate'](),_0x418c9f=_0x5a216a['weekdayLong']||''):_0x5a216a['hasSame'](_0x27aee2,'year')?(_0x29e702=_0x5a216a['startOf']('month')['toJSDate'](),_0x418c9f=_0x5a216a['monthLong']||''):(_0x29e702=_0x5a216a['startOf']('year')['toJSDate'](),_0x418c9f=String(_0x5a216a['year'])),{'startDate':_0x29e702,'localizedPeriodName':_0x418c9f};}class di extends ts{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x17ce47,_0xbb8cdb,_0x2b5a83,_0x111906){super(_0x17ce47);const _0x31234d=ai(_0xbb8cdb,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0xbb8cdb,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x2b5a83,this['_requireRevisionName']=_0x111906,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':_0x31234d}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x50b3d6){const _0x854ac=new hi(this['locale'],_0x50b3d6,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x854ac);}['removeRevision'](_0x347dc1){const _0x180405=this['revisionViews']['find'](_0x3489a8=>_0x3489a8['id']===_0x347dc1['id']);this['revisionViews']['remove'](_0x180405);}}class as extends ts{constructor(_0x36e367){super(_0x36e367);const _0x184924=new _0x2e0193();_0x184924['content']=_0x3e9cd6,this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x184924,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[g(_0x36e367,'Revision\x20history')]}]});}}class ni extends ts{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x42a04f,_0x39deba,_0x52f179,_0x44f009){super(_0x42a04f);const _0x204a33=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x39deba,this['_revisionActions']=_0x52f179,this['_requireRevisionName']=_0x44f009,this['on']('select',(_0x632583,_0x2a5de5)=>{this['fire']('revisionSelected',_0x2a5de5);}),this['on']('setName',(_0x7d7df3,_0x505625)=>{this['fire']('revisionSetName',_0x505625);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new as(_0x42a04f),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x204a33['if']('isEnabled','ck-disabled',_0x464fc7=>!_0x464fc7)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x1ba809 of this['_revisions'])this['_addRevision'](_0x1ba809);this['_revisions']['on']('add',(_0x1b7f07,_0x44aa57)=>{this['_addRevision'](_0x44aa57);}),this['_revisions']['on']('remove',(_0x2112a8,_0x4b8040)=>{this['_removeRevision'](_0x4b8040);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x242d52=>_0x242d52['revisionViews']['map'](_0x52f8ed=>_0x52f8ed))['flat']();}['selectRevision'](_0x5644b6){for(const _0x3e5375 of this['revisionViews'])_0x5644b6&&_0x5644b6['id']===_0x3e5375['id']?_0x3e5375['select']():_0x3e5375['deselect']();}['highlightRevisions'](_0x1fc638){for(const _0x517d2a of this['revisionViews'])_0x1fc638['some'](({id:_0x1c643e})=>_0x1c643e===_0x517d2a['id'])?_0x517d2a['highlight']():_0x517d2a['unhighlight']();}['_addRevision'](_0x251591){const _0x569d71=ai(_0x251591['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x31b6bc=this['timePeriodViews']['get'](0x0);_0x31b6bc&&_0x31b6bc['startDate']['getTime']()===_0x569d71['getTime']()||(_0x31b6bc=new di(this['locale'],_0x569d71,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x31b6bc)),_0x31b6bc['addRevision'](_0x251591);}['_removeRevision'](_0x262c78){const _0x44f725=ai(_0x262c78['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x44f725)['removeRevision'](_0x262c78);}['_getTimePeriodViewByStartDate'](_0x4fb95a){return this['timePeriodViews']['find'](_0x4bcfe2=>_0x4bcfe2['startDate']['getTime']()===_0x4fb95a['getTime']());}}class d extends _0xc858c4{['_revisionViewer'];['_revisionsRepository'];['_sidebarView'];static ['defaultRevisionActions']=/* #__PURE__ -- @preserve */
27
27
  ((()=>['compareAgainstSelected','restoreRevision','nameRevision'])());static ['availableRevisionActions']=/* #__PURE__ -- @preserve */
28
- pt();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[m];}constructor(_0x5997e6){super(_0x5997e6),this['_revisionViewer']=_0x5997e6['plugins']['get'](m),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x4cb4b4=this['_revisionsRepository']['_revisions'],_0x14766d=this['_createRevisionActions'](),_0x4e5b0c=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new ni(this['editor']['locale'],_0x4cb4b4,_0x14766d,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',(_0x56266c,_0x3c5e8f)=>{_0x3c5e8f['revisionViews']['on']('add',(_0x5ebfdf,_0x4ef007)=>{_0x4ef007['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)),_0x4e5b0c['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x1fbfe3=this['_revisionsRepository']['getRevision'](0x0);if(_0x1fbfe3){const _0x4f1e74=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x1fbfe3['id']);this['_revisionViewer']['compare'](_0x1fbfe3,_0x4f1e74);}}['_handleRevisionSelected'](_0x524a11,_0x5e2462){const _0x2ea8d2=this['_revisionsRepository']['getRevision'](_0x5e2462['id']),_0x21a980=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x2ea8d2['id']);this['_revisionViewer']['compare'](_0x2ea8d2,_0x21a980);}['_handleRevisionSetName'](_0x1ddf2e,_0x51e409){this['_revisionsRepository']['getRevision'](_0x51e409['id'])['setName'](_0x51e409['name']);}['_handleDiffChange'](_0xea11ff,_0x167f14,_0xb30ebc){const _0x369637=this['_revisionsRepository']['getRevisionsInDiff'](_0xb30ebc);_0x369637['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x369637),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x369637[0x0]));}['_createRevisionActions'](){const _0x26d894=this['editor'],_0x4b2581=d['availableRevisionActions'],_0x502fa1=_0x26d894['config']['get']('revisionHistory.revisionActions')||d['defaultRevisionActions'];if(_0x502fa1['length'])return _0x502fa1['map'](_0x69ff2c=>{const _0x1870bb='string'==typeof _0x69ff2c?Object['assign']({},_0x4b2581[_0x69ff2c]):_0x69ff2c;return _0x1870bb['action']=_0x1870bb['action']['bind'](this,_0x26d894),_0x1870bb['isVisible']&&(_0x1870bb['isVisible']=_0x1870bb['isVisible']['bind'](this,_0x26d894)),_0x1870bb;});}}function pt(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x30d40e},_0x58e702)=>{const _0x368eda=_0x30d40e['get'](m),_0x3f079f=_0x368eda['repository'];let _0x5ea206=_0x368eda['diff']['newRevisionId'],_0x2b25b7=_0x58e702['id'];_0x3f079f['getIndex'](_0x5ea206)>_0x3f079f['getIndex'](_0x2b25b7)&&([_0x5ea206,_0x2b25b7]=[_0x2b25b7,_0x5ea206]),_0x368eda['compare'](_0x5ea206,_0x2b25b7);},'isVisible':({plugins:_0x3b990c},_0x544151)=>{const _0x526a6a=_0x3b990c['get'](m);return!(_0x526a6a['repository']['getRevisionsInDiff'](_0x526a6a['diff'])['length']>0x2)&&!_0x544151['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x1e8c50,{id:_0x1b225e})=>{_0x1e8c50['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x1b225e);},'isVisible':({plugins:_0x4363b7},_0x57a5da)=>!!_0x4363b7['get'](m)['repository']['getLaterVisibleRevision'](_0x57a5da['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x1e1893},{id:_0x145d3c,revisionNameView:_0x50fb7d})=>{const _0x41eb02=_0x1e1893['get'](m),_0x2c89de=_0x41eb02['repository']['getEarlierVisibleRevision'](_0x145d3c);_0x41eb02['compare'](_0x145d3c,_0x2c89de),_0x50fb7d['focus'](),_0x50fb7d['fieldView']['select']();}}};}class tt extends st{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x36f386,_0x21917a){super(_0x36f386),this['_view']=_0x21917a,this['_toolbarConfig']=et(_0x36f386['config']['get']('toolbar')),this['_elementReplacer']=new ot();}get['element'](){return this['view']['element'];}['init'](_0x1ff221){const _0x897231=this['editor'],_0x1869cb=this['view'],_0x586d47=_0x897231['editing']['view'],_0x21df8d=_0x1869cb['editable'],_0x55b1d2=_0x586d47['document']['getRoot']();_0x21df8d['name']=_0x55b1d2['rootName'],_0x1869cb['render']();const _0x54deb0=_0x21df8d['element'];this['setEditableElement'](_0x21df8d['name'],_0x54deb0),_0x1869cb['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x586d47['attachDomRoot'](_0x54deb0),this['_elementReplacer']['replace'](_0x1ff221,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x55648e=this['view'],_0x5d8281=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x5d8281['detachDomRoot'](_0x55648e['editable']['name']),_0x55648e['destroy']();}['_initToolbar'](){const _0x5cae3b=this['view'];_0x5cae3b['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x5cae3b['stickyPanel']['limiterElement']=_0x5cae3b['element'],_0x5cae3b['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x5b0658})=>_0x5b0658),_0x5cae3b['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x5cae3b['toolbar']);}}class it extends rt{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x48964b,_0x533ce3,_0x34877a={}){super(_0x48964b),this['stickyPanel']=new ht(_0x48964b),this['toolbar']=new dt(_0x48964b,{'shouldGroupWhenFull':_0x34877a['shouldToolbarGroupWhenFull']}),this['_editable']=new ct(_0x48964b,_0x533ce3);}['render'](){super['render'](),this['stickyPanel']['content']['add'](this['toolbar']),this['top']['add'](this['stickyPanel']),this['main']['add'](this['editable']);}}class w extends/* #__PURE__ -- @preserve */
29
- _0x5786a9(_0x27b4aa){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x12f1e7,_0x541526){super(_0x541526),this['sourceElement']=_0x12f1e7,this['model']['document']['createRoot']();const _0x55b9d7=new it(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new tt(this,_0x55b9d7);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x35fde0,_0xdab364){const _0x2941ae=new this(_0x35fde0,_0xdab364);return await _0x2941ae['initPlugins'](),await _0x2941ae['ui']['init'](_0x35fde0),await _0x2941ae['data']['init'](_0x2941ae['config']['get']('initialData')||''),_0x2941ae['fire']('ready'),_0x2941ae;}}const p=['RevisionHistoryUI','RestrictedEditingMode'];class _t extends _0x2a63bd{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x1dba42){function _0x3d6921(_0x8d91d9){return _0x8d91d9['map'](_0x4a8161=>String['fromCharCode'](_0x4a8161))['join']('');}super(_0x1dba42),this['result']='end',_0x1dba42[_0x3d6921([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x3d6921([0x76,0x69,0x65,0x77])][_0x3d6921([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x3d6921([0x61,0x75,0x74,0x6f]),_0x1dba42[_0x3d6921([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x3d6921([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x3d6921([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x3d6921([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x3d6921([0x6f,0x6b])});}}class k extends _0x2a63bd{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u,f];}constructor(_0x282f99){if(super(_0x282f99),!this['editor']['config']['get']('revisionHistory'))throw new _0x388298('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x1e9ff6=>this['_showRevisionViewer']({..._0x1e9ff6,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x3c1d66=>this['_closeRevisionViewer'](_0x3c1d66)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x5f4164=>this['_restoreRevision'](_0x5f4164)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x49030f){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x49030f;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x1937c6){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x1937c6);}['getRevision'](_0x453edd){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x453edd);}['getRevisions'](_0x5086cc){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x5086cc||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x466841=this['editor'],_0x59c4f7=_0x535da6(_0x466841,p),_0x6abd15=_0x466841['plugins']['get']('RevisionTracker'),_0x53f6bf=_0x466841['plugins']['get']('Users')['users'];return _0x59c4f7['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x59c4f7['lazyRoots'],(_0x59c4f7['plugins']['push'](_t,m,R,class extends _0x2a63bd{static get['requires'](){return[m,'Users'];}['init'](){const _0xe4dac1=this['editor']['plugins']['get']('Users');for(const _0x5bd403 of _0x53f6bf)_0x5bd403['isAnonymous']||_0xe4dac1['getUser'](_0x5bd403['id'])||_0xe4dac1['addUser'](_0x5bd403);const _0x5bb846=_0x6abd15['repository']['getRevisions']();let _0x1313c8=null;const _0x4a3415=this['editor']['plugins']['get']('RevisionViewer');_0x4a3415['adapter']=_0x6abd15['adapter'],_0x4a3415['bind']('isEnabled')['to'](_0x6abd15),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x466841,'isReadOnly',_0x47a950=>!_0x47a950);for(const _0x32fb75 of _0x5bb846){const _0x411cbc=null===_0x32fb75['creator'];if(_0x411cbc&&_0x32fb75['toVersion']===_0x32fb75['fromVersion'])continue;const _0x514753=_0x32fb75['toJSON']();_0x4a3415['addRevisionData'](_0x514753,(_0x2c0986,_0x3065ea,_0x56db00)=>{if(_0x411cbc){if(_0x1313c8)_0x1313c8['_update'](_0x2c0986,_0x3065ea);else{if(!_0x3065ea){const _0x54747e=_0x56db00['toJSON']();_0x54747e['id']=_0x5ca89b(),_0x6abd15['saveRevision'](_0x54747e,_0x56db00['toVersion'])['then'](_0x29685e=>{_0x1313c8=_0x29685e;});}}}else _0x32fb75['_update'](_0x2c0986,_0x3065ea);});}}},d),_0x59c4f7);}['_enhanceShowRevisionViewerCallback'](){const _0x1a0ddb=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x51a4ee=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x591271=this['editor']['plugins']['get']('Autosave');await _0x591271['save']();}else await _0x51a4ee['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x40753e=this['editor']['plugins']['get']('Dialog');_0x40753e['isOpen']&&_0x40753e['hide']();}const _0x318e8b=this['_getRevisionViewerEditorConfig']();return _0x1a0ddb(_0x318e8b)['then'](_0x1616c6=>{return(this['_viewerEditor']=_0x1616c6,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'),_0x1616c6);})['catch'](_0x4ecbec=>(console['error'](_0x4ecbec),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x1a4094=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'](),_0x1a4094(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x17a323=this['editor']['plugins']['get']('Annotations');_0x17a323['refreshVisibility'](),_0x17a323['refreshPositioning']();}})));}['_showRevisionViewer'](_0x5bd938){const _0x2844b7=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x4b3bb7=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x521cee=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return w['create'](_0x521cee,_0x5bd938)['then'](_0x35ab25=>(_0x4b3bb7['style']['display']='block',_0x2844b7['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x35ab25));}['_closeRevisionViewer'](_0x228b8f){const _0x53e796=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x53e796['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x228b8f['destroy']();}async['_restoreRevision'](_0x1d3ecb){const _0x1e0c2=this['editor'],_0x187611=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x2af643=_0x1e0c2['plugins']['get']('RevisionTracker'),_0xa77a27=_0x1e0c2['plugins']['get']('RevisionHistoryUtils'),_0x191d2d=_0x187611['repository']['getRevision'](_0x1d3ecb);let _0x55e1b8,_0x363b48,_0x54be80;try{await _0xa77a27['loadRevisionData'](_0x191d2d,this['adapter']),_0x55e1b8=_0xa77a27['getRevisionDocumentData'](_0x191d2d),_0x363b48=_0xa77a27['getRevisionRootsAttributes'](_0x191d2d);}catch(_0x185c3d){return void console['error'](_0x185c3d);}_0x1e0c2['model']['change'](_0x1dce09=>{for(const _0x188f00 of Array['from'](_0x1e0c2['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x1dce09['removeMarker'](_0x188f00);}),_0x187611['isReady']=!0x1,_0x1e0c2['model']['enqueueChange'](_0x569d1e=>{_0x569d1e['setSelection'](null),_0x569d1e['removeSelectionAttribute'](_0x1e0c2['model']['document']['selection']['getAttributeKeys']());const _0x348de3=Object['keys'](_0x55e1b8);for(const _0x13a51a of _0x1e0c2['model']['document']['roots'])'$graveyard'!=_0x13a51a['rootName']&&_0x13a51a['isAttached']()&&!_0x348de3['includes'](_0x13a51a['rootName'])&&_0x569d1e['detachRoot'](_0x13a51a);for(const _0x4e4ee2 of _0x348de3){let _0x2c50db=_0x1e0c2['model']['document']['getRoot'](_0x4e4ee2);_0x2c50db&&_0x2c50db['isAttached']()||(_0x2c50db=_0x569d1e['addRoot'](_0x4e4ee2));const _0x144a44=_0x363b48[_0x4e4ee2],_0x23ce5c=Object['keys'](_0x144a44),_0x3f19a2=_0x55e1b8[_0x4e4ee2];for(const _0x598a53 of _0x2c50db['getAttributeKeys']())_0x23ce5c['includes'](_0x598a53)||_0x569d1e['removeAttribute'](_0x598a53,_0x2c50db);for(const _0x3ba2f3 of _0x23ce5c)_0x569d1e['setAttribute'](_0x3ba2f3,_0x363b48[_0x4e4ee2][_0x3ba2f3],_0x2c50db);_0x569d1e['remove'](_0x569d1e['createRangeIn'](_0x2c50db)),_0x569d1e['insert'](_0x1e0c2['data']['parse'](_0x3f19a2,_0x2c50db),_0x2c50db,0x0);}});const _0x5d741c=g(_0x1e0c2['locale'],'Restored');if(_0x191d2d['name'])_0x54be80=-0x1==_0x191d2d['name']['indexOf'](_0x5d741c)?_0x5d741c+':\x20'+_0x191d2d['name']:_0x191d2d['name'];else _0x54be80=_0x5d741c+':\x20'+(_0x191d2d['createdAt']['toLocaleDateString'](_0x1e0c2['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x191d2d['createdAt']['toLocaleTimeString'](_0x1e0c2['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x2af643['saveRevision']({'name':_0x54be80}),_0x187611['isReady']=!0x0,_0x1e0c2['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{h as Revision,k as RevisionHistory,f as RevisionHistoryUI,V as RevisionHistoryUtils,u as RevisionTracker,m as RevisionViewer,w as RevisionViewerEditor,ge as RevisionViewerLoadingOverlay,R as RevisionViewerUI,I as RevisionsRepository,d as RevisionsSidebar};
28
+ pt();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[m];}constructor(_0x1a2505){super(_0x1a2505),this['_revisionViewer']=_0x1a2505['plugins']['get'](m),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x3a4f72=this['_revisionsRepository']['_revisions'],_0x34c77d=this['_createRevisionActions'](),_0x943de3=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new ni(this['editor']['locale'],_0x3a4f72,_0x34c77d,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',(_0x3050fb,_0x70ea82)=>{_0x70ea82['revisionViews']['on']('add',(_0x111148,_0x4517a8)=>{_0x4517a8['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)),_0x943de3['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0xb1219f=this['_revisionsRepository']['getRevision'](0x0);if(_0xb1219f){const _0x1f8b9b=this['_revisionsRepository']['getEarlierVisibleRevision'](_0xb1219f['id']);this['_revisionViewer']['compare'](_0xb1219f,_0x1f8b9b);}}['_handleRevisionSelected'](_0xda91ee,_0x2cbc70){const _0x367250=this['_revisionsRepository']['getRevision'](_0x2cbc70['id']),_0x2cb59f=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x367250['id']);this['_revisionViewer']['compare'](_0x367250,_0x2cb59f);}['_handleRevisionSetName'](_0x5afb99,_0x32c4c7){this['_revisionsRepository']['getRevision'](_0x32c4c7['id'])['setName'](_0x32c4c7['name']);}['_handleDiffChange'](_0x2a77be,_0x31bf91,_0x2a72d1){const _0x7e963f=this['_revisionsRepository']['getRevisionsInDiff'](_0x2a72d1);_0x7e963f['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x7e963f),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x7e963f[0x0]));}['_createRevisionActions'](){const _0xa56d9e=this['editor'],_0x3211e0=d['availableRevisionActions'],_0x43771b=_0xa56d9e['config']['get']('revisionHistory.revisionActions')||d['defaultRevisionActions'];if(_0x43771b['length'])return _0x43771b['map'](_0x16db90=>{const _0x136a3f='string'==typeof _0x16db90?Object['assign']({},_0x3211e0[_0x16db90]):_0x16db90;return _0x136a3f['action']=_0x136a3f['action']['bind'](this,_0xa56d9e),_0x136a3f['isVisible']&&(_0x136a3f['isVisible']=_0x136a3f['isVisible']['bind'](this,_0xa56d9e)),_0x136a3f;});}}function pt(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x565f4f},_0x2a1e62)=>{const _0x33d8eb=_0x565f4f['get'](m),_0x4ceb99=_0x33d8eb['repository'];let _0x440407=_0x33d8eb['diff']['newRevisionId'],_0x55da83=_0x2a1e62['id'];_0x4ceb99['getIndex'](_0x440407)>_0x4ceb99['getIndex'](_0x55da83)&&([_0x440407,_0x55da83]=[_0x55da83,_0x440407]),_0x33d8eb['compare'](_0x440407,_0x55da83);},'isVisible':({plugins:_0x3b4df7},_0x333505)=>{const _0x3ff11b=_0x3b4df7['get'](m);return!(_0x3ff11b['repository']['getRevisionsInDiff'](_0x3ff11b['diff'])['length']>0x2)&&!_0x333505['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x4ceaa0,{id:_0x51f221})=>{_0x4ceaa0['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x51f221);},'isVisible':({plugins:_0x459d48},_0x520078)=>!!_0x459d48['get'](m)['repository']['getLaterVisibleRevision'](_0x520078['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x5969d9},{id:_0x2efe34,revisionNameView:_0x56c998})=>{const _0x2bd16d=_0x5969d9['get'](m),_0x1c0128=_0x2bd16d['repository']['getEarlierVisibleRevision'](_0x2efe34);_0x2bd16d['compare'](_0x2efe34,_0x1c0128),_0x56c998['focus'](),_0x56c998['fieldView']['select']();}}};}class tt extends st{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x46b900,_0x4af92a){super(_0x46b900),this['_view']=_0x4af92a,this['_toolbarConfig']=et(_0x46b900['config']['get']('toolbar')),this['_elementReplacer']=new ot();}get['element'](){return this['view']['element'];}['init'](_0x2484b9){const _0x453222=this['editor'],_0x3a2c0b=this['view'],_0x1e880b=_0x453222['editing']['view'],_0x78b82=_0x3a2c0b['editable'],_0x19503b=_0x1e880b['document']['getRoot']();_0x78b82['name']=_0x19503b['rootName'],_0x3a2c0b['render']();const _0x6a7a0d=_0x78b82['element'];this['setEditableElement'](_0x78b82['name'],_0x6a7a0d),_0x3a2c0b['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x1e880b['attachDomRoot'](_0x6a7a0d),this['_elementReplacer']['replace'](_0x2484b9,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x22cd83=this['view'],_0x28f30a=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x28f30a['detachDomRoot'](_0x22cd83['editable']['name']),_0x22cd83['destroy']();}['_initToolbar'](){const _0x18a01a=this['view'];_0x18a01a['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x18a01a['stickyPanel']['limiterElement']=_0x18a01a['element'],_0x18a01a['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x31fa51})=>_0x31fa51),_0x18a01a['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x18a01a['toolbar']);}}class it extends rt{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x48ca6b,_0x112f1d,_0xc0277e={}){super(_0x48ca6b),this['stickyPanel']=new ht(_0x48ca6b),this['toolbar']=new dt(_0x48ca6b,{'shouldGroupWhenFull':_0xc0277e['shouldToolbarGroupWhenFull']}),this['_editable']=new ct(_0x48ca6b,_0x112f1d);}['render'](){super['render'](),this['stickyPanel']['content']['add'](this['toolbar']),this['top']['add'](this['stickyPanel']),this['main']['add'](this['editable']);}}class w extends/* #__PURE__ -- @preserve */
29
+ _0x1cb442(_0x3afd4d){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x2ac9f8,_0x46c345){super(_0x46c345),this['sourceElement']=_0x2ac9f8,this['model']['document']['createRoot']();const _0x45b857=new it(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new tt(this,_0x45b857);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x30c123,_0x567354){const _0xabfeba=new this(_0x30c123,_0x567354);return await _0xabfeba['initPlugins'](),await _0xabfeba['ui']['init'](_0x30c123),await _0xabfeba['data']['init'](_0xabfeba['config']['get']('initialData')||''),_0xabfeba['fire']('ready'),_0xabfeba;}}const p=['RevisionHistoryUI','RestrictedEditingMode'];class _t extends _0xc858c4{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x43dfcd){function _0x126fba(_0x20f857){return _0x20f857['map'](_0x516a34=>String['fromCharCode'](_0x516a34))['join']('');}super(_0x43dfcd),this['result']='end',_0x43dfcd[_0x126fba([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x126fba([0x76,0x69,0x65,0x77])][_0x126fba([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x126fba([0x61,0x75,0x74,0x6f]),_0x43dfcd[_0x126fba([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x126fba([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x126fba([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x126fba([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x126fba([0x6f,0x6b])});}}class k extends _0xc858c4{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u,f];}constructor(_0x2d40fb){if(super(_0x2d40fb),!this['editor']['config']['get']('revisionHistory'))throw new _0x3f46eb('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x15e0bc=>this['_showRevisionViewer']({..._0x15e0bc,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x454b64=>this['_closeRevisionViewer'](_0x454b64)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x3f7b38=>this['_restoreRevision'](_0x3f7b38)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x23fb61){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x23fb61;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x5f229d){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x5f229d);}['getRevision'](_0x2ac619){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x2ac619);}['getRevisions'](_0x348f08){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x348f08||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x12fd0b=this['editor'],_0x50a022=_0x4a9536(_0x12fd0b,p),_0x1e0211=_0x12fd0b['plugins']['get']('RevisionTracker'),_0x7273f2=_0x12fd0b['plugins']['get']('Users')['users'];return _0x50a022['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x50a022['lazyRoots'],(_0x50a022['plugins']['push'](_t,m,R,class extends _0xc858c4{static get['requires'](){return[m,'Users'];}['init'](){const _0x4996af=this['editor']['plugins']['get']('Users');for(const _0x15cd47 of _0x7273f2)_0x15cd47['isAnonymous']||_0x4996af['getUser'](_0x15cd47['id'])||_0x4996af['addUser'](_0x15cd47);const _0x4e5271=_0x1e0211['repository']['getRevisions']();let _0x3bd4ba=null;const _0x1f2f6f=this['editor']['plugins']['get']('RevisionViewer');_0x1f2f6f['adapter']=_0x1e0211['adapter'],_0x1f2f6f['bind']('isEnabled')['to'](_0x1e0211),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x12fd0b,'isReadOnly',_0x56161d=>!_0x56161d);for(const _0x2e4940 of _0x4e5271){const _0x55312d=null===_0x2e4940['creator'];if(_0x55312d&&_0x2e4940['toVersion']===_0x2e4940['fromVersion'])continue;const _0x545ea2=_0x2e4940['toJSON']();_0x1f2f6f['addRevisionData'](_0x545ea2,(_0x36b3df,_0x51b1f3,_0x1664eb)=>{if(_0x55312d){if(_0x3bd4ba)_0x3bd4ba['_update'](_0x36b3df,_0x51b1f3);else{if(!_0x51b1f3){const _0x580cca=_0x1664eb['toJSON']();_0x580cca['id']=_0x19f1f8(),_0x1e0211['saveRevision'](_0x580cca,_0x1664eb['toVersion'])['then'](_0xd400a6=>{_0x3bd4ba=_0xd400a6;});}}}else _0x2e4940['_update'](_0x36b3df,_0x51b1f3);});}}},d),_0x50a022);}['_enhanceShowRevisionViewerCallback'](){const _0x57f5f5=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x433c88=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x29d274=this['editor']['plugins']['get']('Autosave');await _0x29d274['save']();}else await _0x433c88['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x381a12=this['editor']['plugins']['get']('Dialog');_0x381a12['isOpen']&&_0x381a12['hide']();}const _0x2113fc=this['_getRevisionViewerEditorConfig']();return _0x57f5f5(_0x2113fc)['then'](_0x23a8c2=>{return(this['_viewerEditor']=_0x23a8c2,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'),_0x23a8c2);})['catch'](_0x51cbf4=>(console['error'](_0x51cbf4),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x262a6e=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'](),_0x262a6e(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x1d3481=this['editor']['plugins']['get']('Annotations');_0x1d3481['refreshVisibility'](),_0x1d3481['refreshPositioning']();}})));}['_showRevisionViewer'](_0x284d16){const _0x58c7db=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x33b00c=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x297d7c=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return w['create'](_0x297d7c,_0x284d16)['then'](_0x10735d=>(_0x33b00c['style']['display']='block',_0x58c7db['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x10735d));}['_closeRevisionViewer'](_0x3bba5a){const _0x3c5c81=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x3c5c81['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x3bba5a['destroy']();}async['_restoreRevision'](_0x111e1f){const _0x2af53c=this['editor'],_0x3f79a0=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x3ff8be=_0x2af53c['plugins']['get']('RevisionTracker'),_0x3546a7=_0x2af53c['plugins']['get']('RevisionHistoryUtils'),_0x479099=_0x3f79a0['repository']['getRevision'](_0x111e1f);let _0x3f6a0f,_0x5c45aa,_0xafdf38;try{await _0x3546a7['loadRevisionData'](_0x479099,this['adapter']),_0x3f6a0f=_0x3546a7['getRevisionDocumentData'](_0x479099),_0x5c45aa=_0x3546a7['getRevisionRootsAttributes'](_0x479099);}catch(_0xf20f58){return void console['error'](_0xf20f58);}_0x2af53c['model']['change'](_0x356cb1=>{for(const _0x467d49 of Array['from'](_0x2af53c['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x356cb1['removeMarker'](_0x467d49);}),_0x3f79a0['isReady']=!0x1,_0x2af53c['model']['enqueueChange'](_0x19dce6=>{_0x19dce6['setSelection'](null),_0x19dce6['removeSelectionAttribute'](_0x2af53c['model']['document']['selection']['getAttributeKeys']());const _0x1a1299=Object['keys'](_0x3f6a0f);for(const _0xa0ce94 of _0x2af53c['model']['document']['roots'])'$graveyard'!=_0xa0ce94['rootName']&&_0xa0ce94['isAttached']()&&!_0x1a1299['includes'](_0xa0ce94['rootName'])&&_0x19dce6['detachRoot'](_0xa0ce94);for(const _0x2f4c22 of _0x1a1299){let _0x49c7b0=_0x2af53c['model']['document']['getRoot'](_0x2f4c22);_0x49c7b0&&_0x49c7b0['isAttached']()||(_0x49c7b0=_0x19dce6['addRoot'](_0x2f4c22));const _0xb1f898=_0x5c45aa[_0x2f4c22],_0x2c4091=Object['keys'](_0xb1f898),_0x47ed49=_0x3f6a0f[_0x2f4c22];for(const _0x1c8431 of _0x49c7b0['getAttributeKeys']())_0x2c4091['includes'](_0x1c8431)||_0x19dce6['removeAttribute'](_0x1c8431,_0x49c7b0);for(const _0x124e9e of _0x2c4091)_0x19dce6['setAttribute'](_0x124e9e,_0x5c45aa[_0x2f4c22][_0x124e9e],_0x49c7b0);_0x19dce6['remove'](_0x19dce6['createRangeIn'](_0x49c7b0)),_0x19dce6['insert'](_0x2af53c['data']['parse'](_0x47ed49,_0x49c7b0),_0x49c7b0,0x0);}});const _0x757063=g(_0x2af53c['locale'],'Restored');if(_0x479099['name'])_0xafdf38=-0x1==_0x479099['name']['indexOf'](_0x757063)?_0x757063+':\x20'+_0x479099['name']:_0x479099['name'];else _0xafdf38=_0x757063+':\x20'+(_0x479099['createdAt']['toLocaleDateString'](_0x2af53c['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x479099['createdAt']['toLocaleTimeString'](_0x2af53c['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x3ff8be['saveRevision']({'name':_0xafdf38}),_0x3f79a0['isReady']=!0x0,_0x2af53c['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{h as Revision,k as RevisionHistory,f as RevisionHistoryUI,V as RevisionHistoryUtils,u as RevisionTracker,m as RevisionViewer,w as RevisionViewerEditor,ge as RevisionViewerLoadingOverlay,R as RevisionViewerUI,I as RevisionsRepository,d as RevisionsSidebar};