@ckeditor/ckeditor5-revision-history 0.0.0-nightly-20250422.0 → 0.0.0-nightly-20250423.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 _0x289f1c,uid as _0x5c32ae,Collection as _0x1dfd6a,logWarning as _0x3d53e2,FocusTracker as _0xd6fb6,KeystrokeHandler as _0x10d155,scrollViewportToShowTarget as _0x314267,ResizeObserver as at,ElementReplacer as ot,CKEditorError as _0x253854}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x51eea2,set as _0x3d1d55,unset as _0x456875,isEqual as _0x5398e3}from'es-toolkit/compat';import{Plugin as _0x2a1981,PendingActions as _0x53bda2,Command as _0x1a5677,ElementApiMixin as _0x2d2992,Editor as _0x6db5f7}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0xcbcc6a,getMarkerDomElement as _0x5bd190,ConfirmMixin as _0x1a2d37,sanitizeEditorConfig as _0x57ea3d}from'ckeditor5-collaboration/dist/index.js';import{ViewContainerElement as _0x190407,ViewAttributeElement as _0x55bd0c,ViewEmptyElement as _0x2334fc,ViewRawElement as _0x1c65e9,ViewUIElement as _0x35f568,ViewDocumentFragment as _0x296b83,ViewText as _0x2d0b9c,ViewElement as _0x705c9e,Element as ut,Range as ft,Position as vt,DocumentFragment as gt,Text as mt}from'@ckeditor/ckeditor5-engine/dist/index.js';import{IconHistory as _0x4d50e2,IconChevronUp as _0x3d5cf8,IconChevronDown as _0x3ea13e,IconUndo as _0x4113d1,IconUser as _0x4e5b48,IconThreeVerticalDots as _0x43e497}from'@ckeditor/ckeditor5-icons/dist/index.js';import{View as _0x2019f7,injectCssTransitionDisabler as ts,submitHandler as _0x515eaa,LabeledFieldView as nt,createLabeledInputText as ti,createDropdown as _0x43dd89,ListView as _0x52357d,ListItemView as te,ButtonView as _0xca59d9,MenuBarMenuView as _0x54876c,MenuBarMenuListView as _0x1ff1fe,MenuBarMenuListItemView as _0x2b081c,MenuBarMenuListItemButtonView as _0x1eef6c,ContextualBalloon as _0x532509,ToolbarSeparatorView as _0x1504bd,IconView as _0x482110,addListToDropdown as _0x1dd007,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 _0x4311f8}from'luxon';class h extends/* #__PURE__ -- @preserve */
24
- _0x289f1c(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x1da0f7){super(),this['id']=_0x1da0f7['id']||_0x5c32ae(),this['creator']=_0x1da0f7['creator']||null,this['authors']=_0x1da0f7['authors']||[],this['diffData']=_0x1da0f7['diffData']||null,this['toVersion']=_0x1da0f7['toVersion']||0x0,this['fromVersion']=_0x1da0f7['fromVersion']||0x0,this['set']('name',_0x1da0f7['name']||''),this['set']('createdAt',_0x1da0f7['createdAt']||new Date()),this['set']('attributes',_0x1da0f7['attributes']||{});}['setName'](_0x568a81){this['_update']({'name':_0x568a81});}['setAttribute'](_0x3827ec,_0x51929f){const _0x42f688=_0x51eea2(this['attributes']);_0x3d1d55(_0x42f688,_0x3827ec,_0x51929f),this['_update']({'attributes':_0x42f688});}['removeAttribute'](_0x250df4){const _0x288687=_0x51eea2(this['attributes']);_0x456875(_0x288687,_0x250df4),this['_update']({'attributes':_0x288687});}['_update'](_0x500461,_0x164aa0=!0x1){let _0x4355b2=!0x1;const _0x3c4f12={'id':this['id']},_0x380c10=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x2533b9 of _0x380c10){const _0x5e301a=_0x500461[_0x2533b9];void 0x0!==_0x5e301a&&_0x5e301a!==this[_0x2533b9]&&(this[_0x2533b9]=_0x5e301a,_0x3c4f12[_0x2533b9]=_0x5e301a,_0x4355b2=!0x0);}_0x4355b2&&(_0x3c4f12['authors']&&(_0x3c4f12['authorsIds']=_0x3c4f12['authors']['map'](_0x49234e=>_0x49234e['id']),delete _0x3c4f12['authors']),this['fire']('_update',_0x3c4f12,_0x164aa0));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x6ffd43=>_0x6ffd43['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class I extends _0x2a1981{['_revisions'];static get['requires'](){return[_0xcbcc6a];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0xf21e14){super(_0xf21e14),this['_revisions']=new _0x1dfd6a();}['afterInit'](){!async function(_0x5947bb){const _0x5345cd=_0x34c5ca([0x38,0x44,0x54,0x51,0x78,0x59,0x52,0x35,0x4d,0x69,0x32,0x53,0x6c,0x4f,0x64,0x75,0x4e,0x39,0x58,0x37,0x30,0x41,0x31,0x36,0x48,0x6f,0x50,0x72,0x42,0x71,0x5a,0x46,0x34,0x77,0x56,0x55,0x4a,0x33,0x4b,0x4c,0x79,0x6d,0x6e,0x47,0x67,0x61,0x73,0x74,0x45,0x57,0x68,0x6b,0x49,0x6a,0x62,0x70,0x66,0x76,0x43,0x65,0x7a,0x63]),_0x5518d9=0xeb829,_0x4e5d74=0x249d80d8,_0x376624=0x249ae518^_0x4e5d74,_0x340873=window[_0x34c5ca([0x44,0x61,0x74,0x65])][_0x34c5ca([0x6e,0x6f,0x77])](),_0x4f8296=_0x5947bb[_0x34c5ca([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x2918d1=new window[(_0x34c5ca([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x5b52a7=>{_0x4f8296[_0x34c5ca([0x6f,0x6e,0x63,0x65])](_0x34c5ca([0x72,0x65,0x61,0x64,0x79]),_0x5b52a7);}),_0x175c20={[_0x34c5ca([0x6b,0x74,0x79])]:_0x34c5ca([0x45,0x43]),[_0x34c5ca([0x75,0x73,0x65])]:_0x34c5ca([0x73,0x69,0x67]),[_0x34c5ca([0x63,0x72,0x76])]:_0x34c5ca([0x50,0x2d,0x32,0x35,0x36]),[_0x34c5ca([0x78])]:_0x34c5ca([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]),[_0x34c5ca([0x79])]:_0x34c5ca([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]),[_0x34c5ca([0x61,0x6c,0x67])]:_0x34c5ca([0x45,0x53,0x32,0x35,0x36])},_0x1ab7d9=_0x4f8296[_0x34c5ca([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x34c5ca([0x67,0x65,0x74])](_0x34c5ca([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x2eceda(){let _0x3fe636,_0x59150d=null,_0x228ed9=null;try{if(_0x1ab7d9==_0x34c5ca([0x47,0x50,0x4c]))return _0x34c5ca([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x3fe636=_0x49905f(),!_0x3fe636)return _0x34c5ca([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x3fe636[_0x34c5ca([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x228ed9=_0x16a367(_0x3fe636[_0x34c5ca([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x3fe636[_0x34c5ca([0x6a,0x74,0x69])])),await _0x3b2420()?_0x35374f()?_0x4ac937()?_0x34c5ca([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x39744d()?(_0x3fe636[_0x34c5ca([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x34c5ca([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x59150d=_0x1027d7(_0x34c5ca([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x3fe636[_0x34c5ca([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x34c5ca([0x74,0x72,0x69,0x61,0x6c])&&(_0x59150d=_0x1027d7(_0x34c5ca([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x2345f8()):_0x34c5ca([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x34c5ca([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x34c5ca([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch(_0xb0731f){return _0x34c5ca([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x4ac937(){const _0x54f2d8=[_0x34c5ca([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x34c5ca([0x74,0x72,0x69,0x61,0x6c])][_0x34c5ca([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x3fe636[_0x34c5ca([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x340873/0x3e8:0xe10*_0x376624;return _0x3fe636[_0x34c5ca([0x65,0x78,0x70])]<_0x54f2d8;}function _0x35374f(){const _0x4776d3=_0x3fe636[_0x34c5ca([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x4776d3)return!0x1;if(_0x4776d3[_0x34c5ca([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x34c5ca([0x2a])))return!0x0;if(_0x4776d3[_0x34c5ca([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x34c5ca([0x52,0x48])))return!0x0;if(_0x4776d3[_0x34c5ca([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x34c5ca([0x52,0x52,0x48]))){if(_0x4f9717())return!0x0;if(_0x5d1fa6()||_0x193bfb())return!0x0;}return!0x1;}function _0x39744d(){const _0x5cce38=_0x3fe636[_0x34c5ca([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x5cce38||0x0==_0x5cce38[_0x34c5ca([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x1fabd4}=new URL(window[_0x34c5ca([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x5cce38[_0x34c5ca([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x1fabd4))return!0x0;const _0x139b1e=_0x1fabd4[_0x34c5ca([0x73,0x70,0x6c,0x69,0x74])](_0x34c5ca([0x2e]));return _0x5cce38[_0x34c5ca([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x49a4df=>_0x49a4df[_0x34c5ca([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x34c5ca([0x2a])))[_0x34c5ca([0x6d,0x61,0x70])](_0x5aad5b=>_0x5aad5b[_0x34c5ca([0x73,0x70,0x6c,0x69,0x74])](_0x34c5ca([0x2e])))[_0x34c5ca([0x73,0x6f,0x6d,0x65])](_0x554d1b=>_0x139b1e[_0x34c5ca([0x65,0x76,0x65,0x72,0x79])]((_0x2092d8,_0x5df487)=>_0x554d1b[_0x5df487]===_0x2092d8||_0x554d1b[_0x5df487]===_0x34c5ca([0x2a])));}function _0x2345f8(){return _0x59150d&&_0x228ed9?new window[(_0x34c5ca([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x3025f2,_0x3d4f94)=>{_0x59150d[_0x34c5ca([0x74,0x68,0x65,0x6e])](_0x3025f2,_0x3d4f94),_0x228ed9[_0x34c5ca([0x74,0x68,0x65,0x6e])](_0x4246ea=>{_0x4246ea!=_0x34c5ca([0x56,0x61,0x6c,0x69,0x64])&&_0x3025f2(_0x4246ea);},_0x3d4f94);}):_0x59150d||_0x228ed9||_0x34c5ca([0x56,0x61,0x6c,0x69,0x64]);}}function _0x16a367(_0x46ed1b,_0x5a91fd){return new window[(_0x34c5ca([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x44af77=>{if(_0x1a5c0f())return _0x44af77(_0x34c5ca([0x56,0x61,0x6c,0x69,0x64]));_0x123f91(),_0x4f8296[_0x34c5ca([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x34c5ca([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x4b2ef8=!0x1;const _0x2bff34=_0x5c32ae();function _0x449fa8(_0x2c37fc){return!!_0x2c37fc&&(typeof _0x2c37fc===_0x34c5ca([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x2c37fc===_0x34c5ca([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x2c37fc[_0x34c5ca([0x74,0x68,0x65,0x6e])]===_0x34c5ca([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x2c37fc[_0x34c5ca([0x63,0x61,0x74,0x63,0x68])]===_0x34c5ca([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x3513ef(_0x568e05){_0x32d1c8(_0x568e05)[_0x34c5ca([0x74,0x68,0x65,0x6e])](_0x1c693b=>{if(!_0x1c693b||_0x1c693b[_0x34c5ca([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x34c5ca([0x6f,0x6b]))return _0x34c5ca([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x67a70b(_0x34cf51(_0x2bff34+_0x5a91fd))!=_0x1c693b[_0x34c5ca([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x34c5ca([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x34c5ca([0x56,0x61,0x6c,0x69,0x64]);})[_0x34c5ca([0x74,0x68,0x65,0x6e])](_0x5cea51=>(_0x104aa0(),_0x5cea51),()=>{const _0x53c3a4=_0x5106e5();return null==_0x53c3a4?(_0x104aa0(),_0x34c5ca([0x56,0x61,0x6c,0x69,0x64])):_0x34c5ca(_0x340873-_0x53c3a4>(0x9104d8^_0x4e5d74)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x34c5ca([0x74,0x68,0x65,0x6e])](_0x44af77)[_0x34c5ca([0x63,0x61,0x74,0x63,0x68])](()=>{_0x44af77(_0x34c5ca([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x28b43b=0x24ab6e58^_0x4e5d74;function _0x104aa0(){const _0x1ddc57=_0x34c5ca([0x6c,0x6c,0x63,0x74,0x2d])+_0x67a70b(_0x34cf51(_0x46ed1b)),_0x43ef74=_0x521b27(_0x67a70b(window[_0x34c5ca([0x4d,0x61,0x74,0x68])][_0x34c5ca([0x63,0x65,0x69,0x6c])](_0x340873/_0x28b43b)));window[_0x34c5ca([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x34c5ca([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x1ddc57,_0x43ef74);}function _0x5106e5(){const _0x4498e4=_0x34c5ca([0x6c,0x6c,0x63,0x74,0x2d])+_0x67a70b(_0x34cf51(_0x46ed1b)),_0xf11140=window[_0x34c5ca([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x34c5ca([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x4498e4);return _0xf11140?window[_0x34c5ca([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x521b27(_0xf11140),0x10)*_0x28b43b:null;}function _0x32d1c8(_0x52e354){return new window[(_0x34c5ca([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x234382,_0x1fc262)=>{_0x52e354[_0x34c5ca([0x74,0x68,0x65,0x6e])](_0x234382,_0x1fc262),window[_0x34c5ca([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x1fc262,0x249c5418^_0x4e5d74);});}}_0x4f8296[_0x34c5ca([0x6f,0x6e])](_0x34c5ca([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x594390,_0x268f21)=>{if(_0x268f21[0x0]!=_0x46ed1b)return _0x44af77(_0x34c5ca([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x268f21[0x1]={..._0x268f21[0x1],[_0x34c5ca([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x2bff34};},{[_0x34c5ca([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x34c5ca([0x68,0x69,0x67,0x68])}),_0x4f8296[_0x34c5ca([0x6f,0x6e])](_0x34c5ca([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x1c022e=>{_0x449fa8(_0x1c022e[_0x34c5ca([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x4b2ef8=!0x0,_0x3513ef(_0x1c022e[_0x34c5ca([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x34c5ca([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x34c5ca([0x6c,0x6f,0x77])}),_0x2918d1[_0x34c5ca([0x74,0x68,0x65,0x6e])](()=>{_0x4b2ef8||_0x44af77(_0x34c5ca([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x1a5c0f(){return _0x4f8296[_0x34c5ca([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x34c5ca([0x76,0x69,0x65,0x77])][_0x34c5ca([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x34c5ca([0x61,0x75,0x74,0x6f]);}function _0x123f91(){_0x4f8296[_0x34c5ca([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x34c5ca([0x76,0x69,0x65,0x77])][_0x34c5ca([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x34c5ca([0x61,0x75,0x74,0x6f]);}}function _0x1027d7(_0x586e97){const _0x4d69f0=[new window[(_0x34c5ca([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x876f24=>setTimeout(_0x876f24,0x2494be14^_0x4e5d74)),_0x2918d1[_0x34c5ca([0x74,0x68,0x65,0x6e])](()=>new window[(_0x34c5ca([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x17b329=>{const _0x46f851=0x249d80df^_0x4e5d74,_0xd65e8d=_0x5947bb[_0x34c5ca([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x3a5628(){_0xd65e8d[_0x34c5ca([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x46f851&&_0x17b329();}_0x3a5628(),_0xd65e8d[_0x34c5ca([0x6f,0x6e])](_0x34c5ca([0x61,0x64,0x64]),_0x3a5628);})),new window[(_0x34c5ca([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x458996=>{function _0x15825b(){for(const _0x5e913a in window)if(window[_0x34c5ca([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x34c5ca([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x5e913a))&&window[_0x5e913a]==_0x5518d9)return _0x458996();_0x4f8296[_0x34c5ca([0x73,0x74,0x61,0x74,0x65])]!=_0x34c5ca([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x34c5ca([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x15825b,0x249d9350^_0x4e5d74);}_0x4c320b(_0x34c5ca([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x15825b();})];return window[_0x34c5ca([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x34c5ca([0x72,0x61,0x63,0x65])](_0x4d69f0)[_0x34c5ca([0x74,0x68,0x65,0x6e])](()=>_0x586e97);}async function _0x443c1d(){if(await _0x2918d1,_0x4c320b(_0x34c5ca([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0xb53537=_0x5947bb[_0x34c5ca([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x170350=_0x5947bb[_0x34c5ca([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])](_0xb53537[_0x34c5ca([0x69,0x64])]),_0x13e2ac=_0x296140(_0x34c5ca([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x13e2ac[_0x34c5ca([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0xb53537['id'],_0x170350?_0x170350['id']:null,!0x0),_0x13e2ac[_0x34c5ca([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x34c5ca([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x13e2ac[_0x34c5ca([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x13e2ac[_0x34c5ca([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x35287d,void(_0x13e2ac[_0x34c5ca([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x35287d);}if(_0x4c320b(_0x34c5ca([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x162cc1=_0x296140(_0x34c5ca([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x162cc1[_0x34c5ca([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x34c5ca([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x162cc1[_0x34c5ca([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x162cc1[_0x34c5ca([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x35287d,_0x162cc1[_0x34c5ca([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x35287d;}_0x4f8296[_0x34c5ca([0x6d,0x6f,0x64,0x65,0x6c])][_0x34c5ca([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x35287d,_0x4f8296[_0x34c5ca([0x6d,0x6f,0x64,0x65,0x6c])][_0x34c5ca([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x35287d,_0x4f8296[_0x34c5ca([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x34c5ca([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x4f9717(){return _0x4c320b(_0x34c5ca([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x296140(_0x34c5ca([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x34c5ca([0x73,0x74,0x61,0x74,0x65])]==_0x34c5ca([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x5d1fa6(){return _0x4c320b(_0x34c5ca([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 _0x193bfb(){return _0x4c320b(_0x34c5ca([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x15e52f(_0xd8f945){const _0x43c7ff=_0x571a8f();_0x4f8296[_0x43c7ff]=_0x34c5ca([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])+_0xd8f945,_0xd8f945[_0x34c5ca([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x34c5ca([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x571a8f()]=_0x5518d9),_0xd8f945!=_0x34c5ca([0x56,0x61,0x6c,0x69,0x64])&&_0x443c1d();}function _0x571a8f(){const _0x54c64c=window[_0x34c5ca([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x34c5ca([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x34c5ca([0x6e,0x6f,0x77])]())[_0x34c5ca([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x34c5ca([0x2e]),'');let _0x1b4bc0=_0x34c5ca([0x44]);for(let _0x55bdc8=0x0;_0x55bdc8<_0x54c64c[_0x34c5ca([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x55bdc8+=0x2){let _0x1bc708=window[_0x34c5ca([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x54c64c[_0x34c5ca([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x55bdc8,_0x55bdc8+0x2));_0x1bc708>=_0x5345cd[_0x34c5ca([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x1bc708-=_0x5345cd[_0x34c5ca([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x1b4bc0+=_0x5345cd[_0x1bc708];}return _0x1b4bc0;}function _0x49905f(){const _0xd478ec=_0x1ab7d9[_0x34c5ca([0x73,0x70,0x6c,0x69,0x74])](_0x34c5ca([0x2e]));if(0x3!=_0xd478ec[_0x34c5ca([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0xad5373(_0xd478ec[0x1]);function _0xad5373(_0x782df2){const _0x347277=_0xe98554(_0x782df2);return _0x347277&&_0x3d75d0()?_0x347277:null;function _0x3d75d0(){const _0x5217dd=_0x347277[_0x34c5ca([0x6a,0x74,0x69])],_0x48b25c=window[_0x34c5ca([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x5217dd[_0x34c5ca([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x5217dd[_0x34c5ca([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x150fe6={..._0x347277,[_0x34c5ca([0x6a,0x74,0x69])]:_0x5217dd[_0x34c5ca([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x5217dd[_0x34c5ca([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x150fe6[_0x34c5ca([0x76,0x63])],_0x34cf51(_0x150fe6)==_0x48b25c;}}}async function _0x3b2420(){let _0x4cfae8=!0x0;try{const _0x4b12b8=_0x1ab7d9[_0x34c5ca([0x73,0x70,0x6c,0x69,0x74])](_0x34c5ca([0x2e])),[_0x23d130,_0x671ad8,_0x5210b7]=_0x4b12b8;return _0x5dc663(_0x23d130),await _0x1300f8(_0x23d130,_0x671ad8,_0x5210b7),_0x4cfae8;}catch(_0x2ab567){return!0x1;}function _0x5dc663(_0xd4dbe){const _0x1b7b07=_0xe98554(_0xd4dbe);_0x1b7b07&&_0x1b7b07[_0x34c5ca([0x61,0x6c,0x67])]==_0x34c5ca([0x45,0x53,0x32,0x35,0x36])||(_0x4cfae8=!0x1);}async function _0x1300f8(_0x2d0445,_0x174c12,_0x463ff2){const _0xe23dc6=window[_0x34c5ca([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x34c5ca([0x66,0x72,0x6f,0x6d])](_0x4ed29a(_0x463ff2),_0x183137=>_0x183137[_0x34c5ca([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x365737=new window[(_0x34c5ca([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x34c5ca([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x2d0445+_0x34c5ca([0x2e])+_0x174c12),_0x59eb2a=window[_0x34c5ca([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x34c5ca([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x59eb2a)return;const _0x2ceabb=await _0x59eb2a[_0x34c5ca([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x34c5ca([0x6a,0x77,0x6b]),_0x175c20,{[_0x34c5ca([0x6e,0x61,0x6d,0x65])]:_0x34c5ca([0x45,0x43,0x44,0x53,0x41]),[_0x34c5ca([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x34c5ca([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x34c5ca([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x59eb2a[_0x34c5ca([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x34c5ca([0x6e,0x61,0x6d,0x65])]:_0x34c5ca([0x45,0x43,0x44,0x53,0x41]),[_0x34c5ca([0x68,0x61,0x73,0x68])]:{[_0x34c5ca([0x6e,0x61,0x6d,0x65])]:_0x34c5ca([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x2ceabb,_0xe23dc6,_0x365737)||(_0x4cfae8=!0x1);}}function _0xe98554(_0x3b8602){return _0x3b8602[_0x34c5ca([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x34c5ca([0x65,0x79]))?JSON[_0x34c5ca([0x70,0x61,0x72,0x73,0x65])](_0x4ed29a(_0x3b8602)):null;}function _0x4ed29a(_0x26e0a9){return window[_0x34c5ca([0x61,0x74,0x6f,0x62])](_0x26e0a9[_0x34c5ca([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x34c5ca([0x2b]))[_0x34c5ca([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x34c5ca([0x2f])));}function _0x34cf51(_0x470f7e){let _0x5a6c65=0x1505;function _0x504b27(_0x3eca46){for(let _0x59fbf2=0x0;_0x59fbf2<_0x3eca46[_0x34c5ca([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x59fbf2++){const _0x3cbf6a=_0x3eca46[_0x34c5ca([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x59fbf2);_0x5a6c65=(_0x5a6c65<<0x5)+_0x5a6c65+_0x3cbf6a,_0x5a6c65&=_0x5a6c65;}}function _0x2564c9(_0x18670b){Array[_0x34c5ca([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x18670b)?_0x18670b[_0x34c5ca([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x2564c9):_0x18670b&&typeof _0x18670b==_0x34c5ca([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x34c5ca([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x18670b)[_0x34c5ca([0x73,0x6f,0x72,0x74])]()[_0x34c5ca([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x3c089b,_0x354dab])=>{_0x504b27(_0x3c089b),_0x2564c9(_0x354dab);}):_0x504b27(window[_0x34c5ca([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x18670b));}return _0x2564c9(_0x470f7e),_0x5a6c65>>>0x0;}function _0x67a70b(_0x50f8b3){return _0x50f8b3[_0x34c5ca([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x34c5ca([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x34c5ca([0x30]));}function _0x521b27(_0x56efca){return _0x56efca[_0x34c5ca([0x73,0x70,0x6c,0x69,0x74])]('')[_0x34c5ca([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x34c5ca([0x6a,0x6f,0x69,0x6e])]('');}function _0x4c320b(_0x4977b4){return _0x4f8296[_0x34c5ca([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x34c5ca([0x68,0x61,0x73])](_0x4977b4);}function _0x296140(_0x308a8e){return _0x4f8296[_0x34c5ca([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x34c5ca([0x67,0x65,0x74])](_0x308a8e);}function _0x35287d(){}function _0x34c5ca(_0x4efd6c){return _0x4efd6c['map'](_0x4f5fb2=>String['fromCharCode'](_0x4f5fb2))['join']('');}_0x15e52f(await _0x2eceda());}(this);}['createRevision'](_0x4e0d91){const _0x296812=this['editor']['plugins']['get']('Users');return new h({'id':_0x4e0d91['id'],'name':_0x4e0d91['name'],'creator':_0x4e0d91['creatorId']?_0x296812['getUser'](_0x4e0d91['creatorId']):null,'diffData':_0x4e0d91['diffData']||_0x4e0d91['data'],'authors':_0x4e0d91['authorsIds']['map'](_0x4f2f2a=>_0x296812['getUser'](_0x4f2f2a)),'createdAt':new Date(_0x4e0d91['createdAt']),'attributes':_0x4e0d91['attributes'],'fromVersion':_0x4e0d91['fromVersion'],'toVersion':_0x4e0d91['toVersion']});}['addRevision'](_0xd62461,_0x3466d5=0x0){this['_revisions']['add'](_0xd62461,_0x3466d5);}['getRevision'](_0x2e58da){return this['_revisions']['get'](_0x2e58da);}['getRevisions'](_0x5407b4={'toJSON':!0x1}){const _0x40a93f=Array['from'](this['_revisions']);return _0x40a93f['reverse'](),_0x5407b4['toJSON']?_0x40a93f['map'](_0x44535f=>_0x44535f['toJSON']()):_0x40a93f;}['getIndex'](_0x4ef45e){return this['_revisions']['getIndex'](_0x4ef45e);}['getEarlierVisibleRevision'](_0x2a4232){const [,_0x89d673]=this['getRevisionsIterator'](_0x2a4232,{'direction':'earlier'});return _0x89d673;}['getLaterVisibleRevision'](_0x337834){const [,_0x3f9172]=this['getRevisionsIterator'](_0x337834,{'direction':'later'});return _0x3f9172;}['getRevisionsInDiff'](_0x59d2aa){const _0x478bc5=[];for(const _0x2aff1a of this['getRevisionsIterator'](_0x59d2aa['newRevisionId']))if(_0x478bc5['push'](_0x2aff1a),_0x2aff1a['id']===_0x59d2aa['oldRevisionId'])break;return _0x478bc5;}*['getRevisionsIterator'](_0x294f9c,{direction:_0xdf907e='earlier',filter:_0x53751d=()=>!0x0}={}){const _0x2b3517='earlier'===_0xdf907e?0x1:-0x1;let _0x5d6409=this['_revisions']['get'](_0x294f9c),_0x31a53a=this['getIndex'](_0x5d6409);for(yield _0x5d6409;_0x5d6409;){if(_0x31a53a+=_0x2b3517,_0x5d6409=this['getRevision'](_0x31a53a),!_0x5d6409)return;_0x53751d(_0x5d6409)&&(yield _0x5d6409);}}}class V extends _0x2a1981{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x190407,'c'],[_0x55bd0c,'a'],[_0x2334fc,'e'],[_0x1c65e9,'r'],[_0x35f568,'u']]);['_typeCharToViewClass']=new Map([['c',_0x190407],['a',_0x55bd0c],['e',_0x2334fc],['r',_0x1c65e9],['u',_0x35f568]]);async['loadRevisionData'](_0x408224,_0x2c66d3){if(_0x408224['diffData']||!_0x2c66d3)return;const _0xf40a61=this['editor']['config']['get']('collaboration.channelId'),_0x84eb10=await _0x2c66d3['getRevision']({'channelId':_0xf40a61,'revisionId':_0x408224['id']});_0x408224['diffData']=_0x84eb10['diffData'];}['getRevisionDocumentData'](_0x2a6d9f){const _0x5ec203={};for(const _0x514c5d in _0x2a6d9f['diffData']){if(_0x2a6d9f['diffData'][_0x514c5d]['attachChange']&&!_0x2a6d9f['diffData'][_0x514c5d]['attachChange']['isAttached'])continue;const _0x510847=this['_removeRevisionMarkers'](JSON['parse'](_0x2a6d9f['diffData'][_0x514c5d]['insertions'])),_0x11c463=this['editor']['editing']['view']['document'],_0x5c8fe2=new _0x296b83(_0x11c463,_0x510847['map'](_0x56b461=>this['_getViewFromDiffObj'](_0x56b461,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x5ec203[_0x514c5d]=this['editor']['data']['processor']['toData'](_0x5c8fe2),this['editor']['data']['processor']['useFillerType']('default');}return _0x5ec203;}['getRevisionRootsAttributes'](_0x5d0a6b){const _0x341a1f={};for(const _0x735797 in _0x5d0a6b['diffData'])_0x5d0a6b['diffData'][_0x735797]['attachChange']&&!_0x5d0a6b['diffData'][_0x735797]['attachChange']['isAttached']||(_0x341a1f[_0x735797]=_0x5d0a6b['diffData'][_0x735797]['attributesAfter']||{});return _0x341a1f;}['_getTypeCharForViewElement'](_0x9041ee){return this['_viewClassToTypeChar']['get'](_0x9041ee['constructor']);}['_getViewFromDiffObj'](_0x5221c6,_0x24e908){const _0x2ab5c6=this['editor']['editing']['view']['document'];if('string'==typeof _0x5221c6)return new _0x2d0b9c(_0x2ab5c6,_0x5221c6);{let _0x5263cf,_0x95600c;_0x95600c='u'==_0x5221c6['type']||'r'==_0x5221c6['type']?[]:_0x5221c6['children']['map'](_0x5967fa=>this['_getViewFromDiffObj'](_0x5967fa,_0x24e908));const _0xedafa8=this['_typeCharToViewClass']['get'](_0x5221c6['type'])||_0x705c9e,_0x4e1b53=this['editor']['data']['htmlProcessor']['domConverter'];if(_0x5263cf=new _0xedafa8(_0x2ab5c6,_0x5221c6['name'],_0x5221c6['attributes'],_0x95600c),'u'==_0x5221c6['type']&&_0x5221c6['children'][0x0]){const _0x52e640=_0x5221c6['children'][0x0];if(_0x5263cf['render']=function(_0x35b4d1){const _0x576a84=_0x35b4d1['createElement']('div');return _0x576a84['innerHTML']=_0x52e640,_0x576a84['childNodes'][0x0];},_0x24e908){const _0x10cab9=new _0x296b83(_0x2ab5c6);_0x10cab9['_appendChild'](_0x5263cf);const _0x1249c0=Array['from'](_0x4e1b53['viewChildrenToDom'](_0x10cab9,{'bind':!0x1})),_0x495c79=_0x4e1b53['domDocument']['createElement']('div');_0x495c79['append'](..._0x1249c0),_0x5263cf=Array['from'](_0x4e1b53['domChildrenToView'](_0x495c79))[0x0];}}else{if('r'==_0x5221c6['type']&&_0x5221c6['children'][0x0]){const _0x560cfb=_0x5221c6['children'][0x0];if(_0x5263cf['render']=function(_0x490826){_0x490826['innerHTML']=_0x560cfb;},_0x24e908){const _0x148479=new _0x296b83(_0x2ab5c6);_0x148479['_appendChild'](_0x5263cf);const _0x48bf0c=Array['from'](_0x4e1b53['viewChildrenToDom'](_0x148479,{'bind':!0x1})),_0x363a23=_0x4e1b53['domDocument']['createElement']('div');_0x363a23['append'](..._0x48bf0c);const _0x3cd6b9=Array['from'](_0x4e1b53['domChildrenToView'](_0x363a23));_0x3cd6b9['length']>0x1?_0x5263cf['_appendChild'](_0x3cd6b9):_0x5263cf=_0x3cd6b9[0x0];}}}if(_0x5221c6['customProperties']){for(const [_0x5629d2,_0x25178d]of _0x5221c6['customProperties'])_0x5263cf['_setCustomProperty'](_0x5629d2,_0x25178d);}const _0x3b2171=void 0x0===_0x5221c6['fillerOffset']?null:_0x5221c6['fillerOffset'];return null!==_0x3b2171&&(_0x5263cf['getFillerOffset']=()=>_0x3b2171),_0x5263cf;}}['_makeModelFromViewString'](_0x274578){const _0x4ea042=JSON['parse'](_0x274578),_0x1b237c=this['editor']['editing']['view']['document'],_0x18f4e1=new _0x296b83(_0x1b237c,_0x4ea042['map'](_0x24f470=>this['_getViewFromDiffObj'](_0x24f470,!0x0)));return this['editor']['data']['toModel'](_0x18f4e1);}['_removeRevisionMarkers'](_0x2ad58b){return(_0x2ad58b=_0x2ad58b['filter'](_0x146db3=>!_0x146db3['name']||'revision-start'!==_0x146db3['name']&&'revision-end'!==_0x146db3['name']))['forEach'](_0x1bc83f=>{'string'!=typeof _0x1bc83f&&(_0x1bc83f['children']=this['_removeRevisionMarkers'](_0x1bc83f['children']),_0x1bc83f['attributes']=_0x1bc83f['attributes']['filter'](_0x155e72=>!_0x155e72[0x0]['startsWith']('data-revision-')));}),_0x2ad58b;}}function g(_0x37eaf4,_0x5bd74c,_0x511ea6){const t=_0x37eaf4['t'];switch(_0x5bd74c){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'},_0x511ea6);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x511ea6);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 _0x2a1981{['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[_0xcbcc6a,I,V,_0x53bda2];}constructor(_0x365382){super(_0x365382),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 _0x514cd6=_0x5c32ae();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x514cd6},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 _0x5b2bcb=this['repository']['getRevision'](0x0),_0x56f394=_0x5b2bcb&&null===_0x5b2bcb['creator']?_0x5b2bcb:null;if(this['_continueCurrentRevision']=!!_0x56f394&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x4e545d=this['_source']['getCurrentRevisionId'](),_0x3594af=this['repository']['getRevision'](_0x4e545d);if(_0x3594af)this['_startingVersion']=_0x3594af['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x4dee35=this['_source']['history']['_operations']['find'](_0x52e4c9=>!_0x52e4c9['_isInit']),_0x2a2c9e=_0x4dee35?_0x4dee35['baseVersion']:this['_source']['history']['version'];_0x5b2bcb?(_0x5b2bcb['toVersion']<_0x2a2c9e&&_0x5b2bcb['_update']({'toVersion':_0x2a2c9e}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x56f394['id'],this['_startingVersion']=_0x56f394['fromVersion']):(this['_startingVersion']=_0x5b2bcb['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x2a2c9e,this['_continueCurrentRevision']=!0x1);}}else _0x56f394&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x56f394['toVersion'],this['editor']['model']['document']['history']['version']),_0x56f394['fromVersion']===_0x56f394['toVersion']?(0x0!==_0x56f394['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x56f394['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x56f394['id'],this['_startingVersion']=_0x56f394['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',_0x1a2b14=>!_0x1a2b14),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x1b9d11=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x2fc94c;for(const _0x2ed458 in _0x1b9d11){const _0x5f379e=_0x2ed458,_0x93134e=_0x1b9d11[_0x5f379e];if('revisionHistoryLicenseKeyValid'==_0x93134e||'revisionHistoryLicenseKeyInvalid'==_0x93134e||'revisionHistoryLicenseKeyExpired'==_0x93134e||'revisionHistoryLicenseKeyDomainLimit'==_0x93134e||'revisionHistoryLicenseKeyNotAllowed'==_0x93134e||'revisionHistoryLicenseKeyEvaluationLimit'==_0x93134e||'revisionHistoryLicenseKeyTrialLimit'==_0x93134e||'revisionHistoryLicenseKeyUsageLimit'==_0x93134e){delete _0x1b9d11[_0x5f379e],_0x2fc94c=_0x93134e,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x2fc94c&&_0x1b9d11['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x2fc94c&&_0x1b9d11['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x2fc94c&&_0x1b9d11['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x2fc94c&&_0x1b9d11['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x2fc94c&&_0x1b9d11['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x2fc94c&&_0x1b9d11['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x2fc94c&&_0x1b9d11['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x4ef210=this['repository']['getRevision'](0x0),_0x4edd1c=await this['getRevisionDocumentData'](_0x4ef210),_0x39cda4=await this['getRevisionRootsAttributes'](_0x4ef210);this['_replaceEditorDataWithRevisionData'](_0x4edd1c,_0x39cda4);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x36e0cb){this['_source']=_0x36e0cb;}async['update'](){const _0x3e33ed=await this['_source']['getLatestVersion']();if(_0x3e33ed>this['currentRevision']['toVersion']){await this['_loadState']();const _0x5d76fe=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x3e33ed});_0x5d76fe['authors']=_0x5d76fe['authorsIds']['map'](_0xa3467e=>this['editor']['plugins']['get']('Users')['getUser'](_0xa3467e)),this['currentRevision']['_update'](_0x5d76fe);}}async['saveRevision'](_0x547b10={},_0x314292=null){const _0x58c0de=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x314292>this['currentRevision']['toVersion']&&(_0x314292=null),null===_0x314292&&(_0x314292=await this['_source']['getLatestVersion']());const _0x35a8c0=this['_getFromVersion'](_0x314292),_0x19ce78=this['buildRevisionData']({'from':_0x35a8c0,'to':_0x314292});if(this['currentRevision']['toVersion']<_0x314292){const _0x1b4db7=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x314292,'to':_0x314292});_0x1b4db7['authors']=[],_0x1b4db7['authorsIds']=[],_0x1b4db7['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x1b4db7,!0x0),delete _0x1b4db7['authors'],_0x58c0de['push'](_0x1b4db7);}_0x547b10['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x547b10['name']=_0x547b10['name']||null,_0x547b10['id']=_0x547b10['id']||_0x5c32ae(),_0x547b10={..._0x547b10,..._0x19ce78};const _0x10b356=this['addRevisionData'](_0x547b10);_0x58c0de['push'](_0x547b10);const _0x50db5e=this['repository']['getIndex'](_0x10b356);if(0x0!==_0x50db5e){const _0x265741=this['repository']['getRevision'](_0x50db5e-0x1);if(_0x265741['fromVersion']!==_0x314292){const _0x220aef=this['_revisionDataBuilder']['getData'](_0x314292,_0x265741['toVersion']),_0x245aae={'id':_0x265741['id'],'diffData':_0x220aef['diffData'],'authorsIds':_0x220aef['authorsIds'],'authors':_0x220aef['authorsIds']['map'](_0x34edef=>this['editor']['plugins']['get']('Users')['getUser'](_0x34edef)),'fromVersion':_0x314292};_0x265741===this['currentRevision']&&(_0x245aae['createdAt']=new Date(_0x547b10['createdAt']['getTime']()+0xa)),_0x265741['_update'](_0x245aae,!0x0),delete _0x245aae['authors'],_0x58c0de['push'](_0x245aae);}}if(this['adapter']){for(const _0x73b7c9 of _0x58c0de)this['_bufferUpdate'](_0x73b7c9['id'],_0x73b7c9,!0x0);this['sendBufferedUpdates']();}return _0x10b356;}['addRevisionData'](_0x531f99){const _0x2cfd15=this['repository']['createRevision'](_0x531f99);return this['adapter']&&_0x2cfd15['on']('_update',(_0x1f1121,_0x416379,_0x964f4f)=>{_0x964f4f||(this['_bufferUpdate'](_0x416379['id'],_0x416379,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x2cfd15,this['_findInsertionIndex'](_0x2cfd15)),_0x2cfd15;}async['getRevisionDocumentData'](_0x5918b0){return await this['_utils']['loadRevisionData'](_0x5918b0,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x5918b0);}async['getRevisionRootsAttributes'](_0x440c63){return await this['_utils']['loadRevisionData'](_0x440c63,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x440c63);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x4a8537=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x4d8195=0x0;_0x4d8195<_0x4a8537['length'];_0x4d8195++){const _0x3e4dd2=_0x4a8537[_0x4d8195];let _0x545d8f=!0x1;for(const _0x4a44c0 of Object['keys'](_0x3e4dd2))void 0x0===_0x3e4dd2[_0x4a44c0]?delete _0x3e4dd2[_0x4a44c0]:'id'!==_0x4a44c0&&(_0x545d8f=!0x0);_0x545d8f||(_0x4a8537[_0x4d8195]=null);}if(_0x4a8537=_0x4a8537['filter'](_0x4c21da=>null!==_0x4c21da),!_0x4a8537['length'])return;for(let _0x14b040=0x0;_0x14b040<_0x4a8537['length'];_0x14b040++){const _0x5efd21=_0x4a8537[_0x14b040];void 0x0!==_0x5efd21['fromVersion']&&void 0x0===_0x5efd21['toVersion']&&(_0x5efd21['toVersion']=this['repository']['getRevision'](_0x5efd21['id'])['toVersion']),void 0x0!==_0x5efd21['toVersion']&&void 0x0===_0x5efd21['fromVersion']&&(_0x5efd21['fromVersion']=this['repository']['getRevision'](_0x5efd21['id'])['fromVersion']);}const _0x468820=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x4a8537,_0x468820)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x1657a1=>{if(_0x1657a1){for(const _0x4ee7df of _0x1657a1)this['setRevisionData']({'id':_0x4ee7df['id'],'createdAt':_0x4ee7df['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0x464828=null,from:_0x5bae5d=null,to:_0x1f43f1=null}){_0x5bae5d=null!==_0x5bae5d?_0x5bae5d:_0x464828['fromVersion'],_0x1f43f1=null!==_0x1f43f1?_0x1f43f1:_0x464828['toVersion'];const _0x47e863=this['_revisionDataBuilder']['getData'](_0x5bae5d,_0x1f43f1),_0x5baf5a={'diffData':_0x47e863['diffData'],'authorsIds':_0x47e863['authorsIds'],'fromVersion':_0x5bae5d,'toVersion':_0x1f43f1};if(!_0x464828||_0x1f43f1!==_0x464828['toVersion']){const _0x2a0bce=_0x1f43f1-0x1,_0x2e79b7=this['_source']['history']['getOperation'](_0x2a0bce);_0x5baf5a['createdAt']=_0x2e79b7&&_0x2e79b7['createdAt']||new Date();}if(this['_loadedStateData']&&_0x5bae5d===this['_loadedStateData']['fromVersion']){for(const _0x1fb109 of this['_loadedStateData']['authors'])_0x5baf5a['authorsIds']['includes'](_0x1fb109['id'])||_0x5baf5a['authorsIds']['push'](_0x1fb109['id']);}return _0x5baf5a;}['_bufferUpdate'](_0x5c093d,_0x140890,_0x1e8e5d){if(this['_bufferedUpdates']['has'](_0x5c093d)){const _0x38ebf7=this['_bufferedUpdates']['get'](_0x5c093d);_0x140890=_0x1e8e5d?{..._0x38ebf7,..._0x140890}:{..._0x140890,..._0x38ebf7};}this['_bufferedUpdates']['set'](_0x5c093d,_0x140890);}['setRevisionData'](_0x2b0c88){const _0x567036=this['repository']['getRevision'](_0x2b0c88['id']);if(_0x2b0c88['createdAt']&&(_0x2b0c88['createdAt']=new Date(_0x2b0c88['createdAt'])),_0x2b0c88['authorsIds']){const _0x1ed6ef=this['editor']['plugins']['get']('Users');_0x2b0c88['authors']=_0x2b0c88['authorsIds']['map'](_0x5d92a0=>_0x1ed6ef['getUser'](_0x5d92a0));}_0x567036['_update'](_0x2b0c88,!0x0);}['_createInitialRevision'](_0x52e91f){const _0x56cbfd=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x56cbfd)this['_initialRevisionId']=_0x56cbfd['id'];else{const _0x1c8df7=!this['editor']['model']['document']['roots']['find'](_0x500f71=>this['editor']['model']['hasContent'](_0x500f71)),_0x386416=this['editor']['plugins']['get']('Users')['me']['id'],_0x5650e7=g(this['editor']['locale'],_0x1c8df7?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x52e91f,'to':_0x52e91f,'id':this['_initialRevisionId'],'name':_0x5650e7,'creatorId':_0x386416});}}['_createCurrentRevision'](_0x28faa6){const _0x1c0cc1=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x1c0cc1),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x28faa6,'to':_0x28faa6,'id':_0x1c0cc1,'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'](_0x1dfdcd,_0x2f5030){let _0x3f679a=this['editor']['config']['get']('initialData'),_0x5a8d6e=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x3f679a){_0x3f679a={};for(const _0x51c88b of this['editor']['model']['document']['getRootNames']())_0x3f679a[_0x51c88b]='';}if('string'==typeof _0x3f679a&&(_0x3f679a={'main':_0x3f679a}),void 0x0===_0x5a8d6e){_0x5a8d6e={};for(const _0x1e8086 of this['editor']['model']['document']['getRootNames']())_0x5a8d6e[_0x1e8086]={};}let _0x4fab23=!0x1;const _0x16d648=Object['keys'](_0x3f679a),_0x1e3d17=Object['keys'](_0x1dfdcd);for(const _0x517ba2 of _0x16d648){if(_0x3f679a[_0x517ba2]!==_0x1dfdcd[_0x517ba2]&&''!==_0x3f679a[_0x517ba2]['trim']()){_0x4fab23=!0x0;break;}if(!_0x5398e3(_0x5a8d6e[_0x517ba2],_0x2f5030[_0x517ba2])&&Object['keys'](_0x5a8d6e[_0x517ba2])['length']>0x0){_0x4fab23=!0x0;break;}}_0x4fab23||(_0x4fab23=_0x1e3d17['some'](_0x533c59=>!this['editor']['model']['document']['getRoot'](_0x533c59))),_0x4fab23&&_0x3d53e2('editor-initial-data-replaced-with-revision-data',{'editorData':_0x3f679a,'editorRootsAttributes':_0x5a8d6e,'revisionData':_0x1dfdcd,'revisionRootsAttributes':_0x2f5030}),this['editor']['config']['set']('initialData',_0x1dfdcd),this['editor']['config']['set']('rootsAttributes',_0x2f5030);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x31be75=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x31be75['add'](g(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x50d3da){const _0x1829b8=this['repository']['getRevisions']();_0x1829b8['reverse']();let _0x1d1aa4=0x0;for(;_0x1d1aa4<_0x1829b8['length'];){const _0x27500b=_0x1829b8[_0x1d1aa4];if(_0x27500b===this['currentRevision']){_0x1d1aa4++;continue;}if(_0x27500b['id']===this['_initialRevisionId'])break;const _0x2f481b=_0x50d3da['toVersion']-_0x27500b['toVersion']||_0x50d3da['fromVersion']-_0x27500b['fromVersion'];if(_0x2f481b>0x0)break;if(_0x2f481b<0x0)_0x1d1aa4++;else{if(!_0x50d3da['creator']&&_0x27500b['creator'])break;if(_0x27500b['creator']||!_0x50d3da['creator']){if(_0x50d3da['createdAt']>_0x27500b['createdAt'])break;_0x1d1aa4++;}else _0x1d1aa4++;}}return _0x1d1aa4;}['_getFromVersion'](_0x50a997){const _0x1114db=this['repository']['getRevisions']();_0x1114db['reverse'](),_0x1114db['shift']();const _0x2f4151=_0x1114db['find'](_0x34320d=>_0x34320d['toVersion']<=_0x50a997)['toVersion'];return _0x2f4151<this['_startingVersion']?this['_startingVersion']:_0x2f4151;}['_makeRevision']({name:_0x13b4cc,from:_0x3c7f14,to:_0x243632,creatorId:_0x343ba2,id:_0x2560aa}){const _0x375c61=this['buildRevisionData']({'from':_0x3c7f14,'to':_0x243632});_0x375c61['name']=_0x13b4cc,_0x375c61['creatorId']=_0x343ba2,_0x375c61['id']=_0x2560aa;const _0xc78379=this['addRevisionData'](_0x375c61);return this['adapter']&&this['_bufferUpdate'](_0x375c61['id'],_0x375c61,!0x0),_0xc78379;}['_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(_0x4dcd1c){this['editor']=_0x4dcd1c,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'](_0x54ec77){this['source']=_0x54ec77;const _0x5005f0=new Map(),_0x58d40d=new Map(),_0x5cfd99=this['editor']['model']['document']['roots']['map'](_0x5eed03=>_0x5eed03['rootName']);for(const _0x94e56a of _0x5cfd99){const _0x5d5256=this['editor']['model']['document']['getRoot'](_0x94e56a),_0x4ed80c=N(_0x5d5256);_0x5005f0['set'](_0x94e56a,_0x4ed80c),_0x58d40d['set'](_0x94e56a,Object['fromEntries'](_0x5d5256['getAttributes']()));}const _0x1807c1=Array['from'](this['editor']['model']['markers'])['map'](_0x87e46a=>[_0x87e46a['name'],_0x87e46a['getRange']()]),_0xd51af4=this['source']['version'];this['_saveMetaData'](_0xd51af4,_0x5005f0,_0x1807c1,_0x58d40d),this['_startingRevisionId']=this['_revisionId'];const _0x18f8bf=new Map(),_0x4a04e0=new Map();for(const _0x15cd6f of _0x5cfd99){const _0x3bbf2=P(_0x15cd6f);_0x18f8bf['set'](_0x15cd6f,_0x3bbf2),_0x4a04e0['set'](_0x15cd6f,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x18f8bf,[],_0x4a04e0);}['getData'](_0xe83ca5,_0x238eb6){if(this['_lastFrom']===_0xe83ca5&&this['_lastTo']<=_0x238eb6)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x238eb6,!0x0);else{if(!this['_savedMetaData']['has'](_0xe83ca5)){const _0x197036=this['_getPreviousFrom'](_0xe83ca5);this['_calculateMetaData'](_0x197036,_0xe83ca5,!0x1);}this['_calculateMetaData'](_0xe83ca5,_0x238eb6,!0x0);}return this['_lastFrom']=_0xe83ca5,this['_lastTo']=_0x238eb6,this['_getState']();}['loadState'](_0xa9774c){const _0x251e12=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0xa9774c['fromVersion'],this['_lastTo']=_0xa9774c['toVersion'];for(const _0x448413 in _0xa9774c['diffData']){const _0x5e332b=_0xa9774c['diffData'][_0x448413]['attachChange'],_0x3f0dcd=_0x51eea2(_0xa9774c['diffData'][_0x448413]['attributesBefore'])||{},_0x326aee=_0x251e12['_makeModelFromViewString'](_0xa9774c['diffData'][_0x448413]['deletions']);_0x326aee['rootName']=_0x448413,_0x326aee['_isAttached']=!_0x5e332b||!_0x5e332b['isAttached'],_0x326aee['isAttached']=()=>_0x326aee['_isAttached'],this['_baseRoots']['set'](_0x448413,_0x326aee),this['_baseRootsAttributes']['set'](_0x448413,_0x3f0dcd),_0x5e332b&&this['_touchedRoots']['set'](_0x448413,_0x5e332b);const _0x3c6ee8=this['_makeIdsRoot'](_0x326aee);this['_baseIdsRoots']['set'](_0x448413,_0x3c6ee8);for(const [_0xa88701,_0x443794]of _0x326aee['markers']){if(!_0xa88701['startsWith']('revision:'))continue;const _0x37b298=_0xa88701['split'](':')[0x2];for(const _0x1efbe5 of _0x443794['getWalker']({'singleCharacters':!0x0})){const _0x56086b=this['_getVidAttributeName'](_0x1efbe5),_0x2291ce='elementEnd'==_0x1efbe5['type']?_0x1efbe5['previousPosition']['path']['slice'](0x0,-0x1):_0x1efbe5['previousPosition']['path'],_0x25d7e1=_0x3c6ee8['getNodeByPath'](_0x2291ce)['getAttribute'](_0x56086b);this['_touched']['set'](_0x25d7e1,{'userId':_0x37b298});}}}this['_startingRevisionId']=this['_revisionId'];const _0x2219d1=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x1399a5=>!this['_touched']['has'](_0x1399a5));let _0x3bda02=0x0;const _0x80c566=new Map();for(const _0x66b3af in _0xa9774c['diffData']){const _0x23c619=_0xa9774c['diffData'][_0x66b3af]['attachChange'],_0x40d948=_0x51eea2(_0xa9774c['diffData'][_0x66b3af]['attributesAfter'])||{},_0x4ac102=_0x251e12['_makeModelFromViewString'](_0xa9774c['diffData'][_0x66b3af]['insertions']);_0x4ac102['rootName']=_0x66b3af,_0x4ac102['_isAttached']=!_0x23c619||_0x23c619['isAttached'],_0x4ac102['isAttached']=()=>_0x4ac102['_isAttached'],this['_diffRoots']['set'](_0x66b3af,_0x4ac102),this['_diffRootsAttributes']['set'](_0x66b3af,_0x40d948);const _0x238119=this['_makeIdsRoot'](_0x4ac102,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x66b3af,_0x238119),_0x80c566['set'](_0x66b3af,_0x4ac102['isAttached']()?_0x40d948:{});for(const [_0x5d4952,_0x5a73c4]of _0x4ac102['markers']){if(!_0x5d4952['startsWith']('revision:'))continue;const _0x3da67c=_0x5d4952['split'](':')[0x2];for(const _0x18ebb9 of _0x5a73c4['getWalker']({'singleCharacters':!0x0})){const _0x2c7b95=this['_getVidAttributeName'](_0x18ebb9),_0x2143ab=this['_revisionId']++,_0x593e5e='elementEnd'==_0x18ebb9['type']?_0x18ebb9['previousPosition']['path']['slice'](0x0,-0x1):_0x18ebb9['previousPosition']['path'];_0x238119['getNodeByPath'](_0x593e5e)['_setAttribute'](_0x2c7b95,_0x2143ab),this['_touched']['set'](_0x2143ab,{'userId':_0x3da67c});}}for(const _0x3ed35 of this['editor']['model']['createRangeIn'](_0x4ac102)['getWalker']({'singleCharacters':!0x0})){const _0x1c7477=this['_getVidAttributeName'](_0x3ed35),_0x416d42='elementEnd'==_0x3ed35['type']?_0x3ed35['previousPosition']['path']['slice'](0x0,-0x1):_0x3ed35['previousPosition']['path'],_0x55a9c1=_0x238119['getNodeByPath'](_0x416d42);_0x55a9c1['getAttribute'](_0x1c7477)>0x0||_0x55a9c1['_setAttribute'](_0x1c7477,_0x2219d1[_0x3bda02++]);}for(const [_0x35c387,_0x2c8109]of _0x4ac102['markers'])_0x35c387['startsWith']('revision:')||this['_markers']['set'](_0x35c387,_0x2c8109);}const _0x27b1b3=P('$graveyard');this['_baseRoots']['set']('$graveyard',_0x27b1b3),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x27b1b3,0x1));const _0xcf4ab7=P('$graveyard');this['_diffRoots']['set']('$graveyard',_0xcf4ab7),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0xcf4ab7,0x1));const _0x2eaaac=Array['from'](this['_diffRoots'])['map'](([_0x18058c,_0x59af23])=>[_0x18058c,N(_0x59af23)]);this['_saveMetaData'](this['_lastTo'],_0x2eaaac,this['_markers'],_0x80c566);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0x2deaf8,_0x292bbd,_0x3ce53d,_0x7d03e8){const _0x5345c7=new Map(_0x292bbd),_0x41089e=new Map(_0x51eea2(_0x7d03e8)),_0x52976d=new Map();for(const [_0x3c6460,_0x76b29e]of _0x3ce53d)_0x52976d['set'](_0x3c6460,{'start':_0x76b29e['start']['clone'](),'end':_0x76b29e['end']['clone'](),'rootName':_0x76b29e['root']['rootName']});this['_savedMetaData']['set'](_0x2deaf8,{'roots':_0x5345c7,'markers':_0x52976d,'rootsAttributes':_0x41089e});}['_removeMetaData'](_0x256db8){this['_savedMetaData']['delete'](_0x256db8);}['_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'](_0x20358e,_0x56624a=null){let _0x3bc36=null;_0x20358e['is']('documentFragment')||(_0x3bc36=new ut(_0x20358e['name'],{'vid_start':null===_0x56624a?this['_revisionId']++:_0x56624a++}));const _0x1b37f6=[];for(const _0x1c0f91 of _0x20358e['getChildren']())if(_0x1c0f91['is']('element')){_0x1b37f6['push'](this['_makeIdsRoot'](_0x1c0f91,_0x56624a));const _0x2226c3=_0x1b37f6[_0x1b37f6['length']-0x1];null!==_0x56624a&&(_0x56624a=_0x2226c3['is']('element','$text')?_0x2226c3['getAttribute']('vid')+0x1:_0x2226c3['getAttribute']('vid_end')+0x1);}else{for(let _0x3de458=0x0;_0x3de458<_0x1c0f91['offsetSize'];_0x3de458++)_0x1b37f6['push'](new ut('$text',{'vid':null===_0x56624a?this['_revisionId']++:_0x56624a++}));}if(_0x20358e['is']('documentFragment')){const _0x342b82=P(_0x20358e['rootName']);return _0x342b82['_insertChild'](0x0,_0x1b37f6),_0x342b82;}return _0x3bc36['_setAttribute']('vid_end',null===_0x56624a?this['_revisionId']++:_0x56624a++),_0x3bc36['_insertChild'](0x0,_0x1b37f6),_0x3bc36;}['_calculateMetaData'](_0x3b0abe,_0x2c3399,_0x58f0e7){this['_reset']();const {roots:_0x3d13e3,markers:_0x67f679,rootsAttributes:_0x5b39bc}=this['_savedMetaData']['get'](_0x3b0abe);this['_baseRoots']=new Map(_0x3d13e3),this['_baseRootsAttributes']=new Map(_0x51eea2(_0x5b39bc));for(const [_0x3447c7,_0x458e9]of this['_baseRoots'])if('$graveyard'!==_0x3447c7&&(this['_diffRoots']['set'](_0x3447c7,N(_0x458e9)),this['_diffRootsAttributes']=new Map(_0x51eea2(_0x5b39bc)),_0x58f0e7)){const _0x286d8b=this['_revisionId'];this['_idsRoots']['set'](_0x3447c7,this['_makeIdsRoot'](_0x458e9)),this['_baseIdsRoots']['set'](_0x3447c7,this['_makeIdsRoot'](_0x458e9,_0x286d8b));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',N(this['_baseRoots']['get']('$graveyard'))),_0x58f0e7&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x422572,_0x1ddd23]of _0x67f679){const _0x3565c9=this['_baseRoots']['get'](_0x1ddd23['rootName']),_0x51e1a5=this['_diffRoots']['get'](_0x1ddd23['rootName']),_0x408fd7=new ft(this['_fixPosition'](_0x1ddd23['start'],_0x3565c9),this['_fixPosition'](_0x1ddd23['end'],_0x3565c9)),_0x501572=this['_fixRange'](_0x408fd7,_0x51e1a5);_0x3565c9['markers']['set'](_0x422572,_0x408fd7),this['_markers']['set'](_0x422572,_0x501572);}this['_applyOperations'](_0x3b0abe,_0x2c3399,_0x58f0e7);}['_applyOperations'](_0x325651,_0x6ff6e0,_0x5bb541){for(const _0x2b1d37 of this['source']['getOperations'](_0x325651,_0x6ff6e0))this['_handleOperation'](_0x2b1d37,_0x5bb541);for(const _0x12550d of this['_diffRoots']['values']())_0x12550d['markers']['clear']();for(const [_0x568b50,_0x383dff]of this['_markers']){this['_diffRoots']['get'](_0x383dff['root']['rootName'])['markers']['set'](_0x568b50,_0x383dff['clone']());}const _0x541267=new Map(),_0x197ae2=new Map();for(const [_0x4dd02b,_0x45992b]of this['_diffRoots'])_0x541267['set'](_0x4dd02b,N(_0x45992b)),_0x197ae2['set'](_0x4dd02b,this['_diffRootsAttributes']['get'](_0x4dd02b));this['_saveMetaData'](_0x6ff6e0,_0x541267,this['_markers'],_0x197ae2);}['_getPreviousFrom'](_0x54e653){const _0x10b739=Array['from'](this['_savedMetaData']['keys']());_0x10b739['sort']((_0xe4663a,_0x30e8d7)=>_0xe4663a-_0x30e8d7),_0x10b739['reverse']();for(const _0x3f8118 of _0x10b739)if(_0x3f8118<_0x54e653)return _0x3f8118;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x19c9d3,_0x4ff1af){const _0x3a481f=Array['from'](_0x4ff1af['markers'])['map'](([_0x5cc9d1,_0x4f5dff])=>[_0x5cc9d1,this['_fixRange'](_0x4f5dff,_0x19c9d3)]);_0x19c9d3['markers']=new Map(_0x3a481f);}['_transformMarkers'](_0x9c854d){for(const _0x32c0c7 of this['_markers']['values']()){const _0x5b1d6a=_0x32c0c7['getTransformedByOperation'](_0x9c854d),_0x250992=ft['_createFromRanges'](_0x5b1d6a);_0x32c0c7['start']=_0x250992['start'],_0x32c0c7['end']=_0x250992['end'];}}['_handleOperation'](_0x1f01db,_0xe1983c){if('addRoot'!=_0x1f01db['type']&&'detachRoot'!=_0x1f01db['type']){if('insert'==_0x1f01db['type']){const _0x823597=_0x1f01db['position']['root']['rootName'];this['_diffRoots']['has'](_0x823597)||(this['_diffRoots']['set'](_0x823597,P(_0x823597,!0x0)),this['_diffRootsAttributes']['set'](_0x823597,{}),_0xe1983c&&this['_idsRoots']['set'](_0x823597,P(_0x823597,!0x0)));}else{if('addRootAttribute'==_0x1f01db['type']||'removeRootAttribute'==_0x1f01db['type']||'changeRootAttribute'==_0x1f01db['type'])return void this['_handleRootAttributeOperation'](_0x1f01db);'marker'==_0x1f01db['type']&&this['_handleMarkerOperation'](_0x1f01db);}if('marker'!==_0x1f01db['type']){const _0x5390e8=this['_cloneOperation'](_0x1f01db,this['_diffRoots']);_0x5390e8['_execute'](),this['_transformMarkers'](_0x5390e8);}if(_0xe1983c)switch(_0x1f01db['type']){case'insert':this['_handleInsertOperation'](_0x1f01db);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x1f01db);break;case'merge':this['_handleMergeOperation'](_0x1f01db);break;case'split':this['_handleSplitOperation'](_0x1f01db);}}else this['_handleRootOperation'](_0x1f01db,_0xe1983c);}['_cloneOperation'](_0x332fa7,_0x6732be){const _0x4d0df3=_0x332fa7['clone']();return _0x4d0df3['_authorId']=_0x332fa7['_authorId'],this['_fixOperation'](_0x4d0df3,_0x6732be),_0x4d0df3;}['_getBaseVids'](_0x530f14){return _0x530f14['map'](_0x30937b=>{const _0x1bb1bf=this['_getVidAttributeName'](_0x30937b);return Number(_0x30937b['item']['getAttribute'](_0x1bb1bf));});}['_generateTape'](_0x1f287f,_0x139e50){if(_0x1f287f['is']('element','$text'))_0x139e50['push']({'item':_0x1f287f,'type':'text'});else{_0x1f287f['is']('element')&&_0x139e50['push']({'item':_0x1f287f,'type':'elementStart'});for(const _0x4c9704 of _0x1f287f['getChildren']())this['_generateTape'](_0x4c9704,_0x139e50);_0x1f287f['is']('element')&&_0x139e50['push']({'item':_0x1f287f,'type':'elementEnd'});}return _0x139e50;}['_getState'](){const _0x157b78=new Map(this['_touched']),_0x1fe63e=new Map(_0x157b78),_0x1a7374=new Map(),_0x23c8b0={'insertions':{},'deletions':{}},_0x30a708={'insertions':{},'deletions':{}},_0x2fb519=new Map(),_0x38b334=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x38b334['delete']('$graveyard');for(const _0x1746d0 of _0x38b334){const _0x5bc281=this['_diffRoots']['get'](_0x1746d0)||P(_0x1746d0,!0x1),_0x11579c=this['_baseRoots']['get'](_0x1746d0)||P(_0x1746d0,!0x1);_0x5bc281['isAttached']()||_0x11579c['isAttached']()?(_0x23c8b0['insertions'][_0x1746d0]=N(_0x5bc281),_0x23c8b0['deletions'][_0x1746d0]=N(_0x11579c),this['_copyMarkers'](_0x23c8b0['deletions'][_0x1746d0],_0x11579c),this['_copyMarkers'](_0x23c8b0['insertions'][_0x1746d0],_0x5bc281),_0x30a708['insertions'][_0x1746d0]=this['_generateTape'](this['_idsRoots']['get'](_0x1746d0),[]),_0x30a708['deletions'][_0x1746d0]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x1746d0)||P(_0x1746d0,!0x1),[])):_0x38b334['delete'](_0x1746d0);}for(const _0x39e5bc of _0x38b334){const _0x2d123d=_0x30a708['insertions'][_0x39e5bc];for(const _0x27d74e of _0x2d123d){const _0x473b59=this['_getVidAttributeName'](_0x27d74e),_0x408ffc=_0x27d74e['item']['getAttribute'](_0x473b59);_0x1fe63e['delete'](_0x408ffc),_0x408ffc>=this['_startingRevisionId']&&_0x1a7374['set'](_0x408ffc,_0x157b78['get'](_0x408ffc));}}for(const _0x3b47b8 of _0x38b334){const _0x51e15d=_0x30a708['insertions'][_0x3b47b8],_0x3fbe66=this['_getBaseVids'](_0x30a708['deletions'][_0x3b47b8]);let _0x23401a=0x0;for(const _0x57334e of _0x51e15d){const _0x44c40a=this['_getVidAttributeName'](_0x57334e),_0x3ad2cc=_0x57334e['item']['getAttribute'](_0x44c40a);if(!_0x1a7374['has'](_0x3ad2cc)&&!_0x2fb519['has'](_0x3ad2cc)){if(_0x1fe63e['has'](_0x3ad2cc))_0x23401a++;else{if(_0x3ad2cc!=_0x3fbe66[_0x23401a]){const _0x56e665=_0x157b78['get'](_0x3ad2cc)||_0x157b78['get'](_0x3fbe66[_0x23401a]);for(;_0x3ad2cc!=_0x3fbe66[_0x23401a];)_0x1fe63e['has'](_0x3fbe66[_0x23401a])||(_0x2fb519['set'](_0x3fbe66[_0x23401a],_0x56e665),_0x157b78['set'](_0x3fbe66[_0x23401a],_0x56e665)),_0x23401a++;}_0x23401a++;}}}}for(const _0x8b2e68 of _0x38b334){const _0x45a8c9=_0x30a708['insertions'][_0x8b2e68];for(const _0x289b45 of _0x45a8c9){const _0x438529=this['_getVidAttributeName'](_0x289b45),_0x3cb91f=_0x289b45['item']['getAttribute'](_0x438529);if(_0x2fb519['has'](_0x3cb91f)){const _0xb9ade=_0x2fb519['get'](_0x3cb91f);_0x1fe63e['has'](_0x3cb91f)||_0x1fe63e['set'](_0x3cb91f,{..._0xb9ade}),_0x1a7374['set'](_0x3cb91f,{..._0xb9ade});}}}for(const _0x19bdcc of _0x1fe63e['keys']())_0x19bdcc>=this['_startingRevisionId']&&_0x1fe63e['delete'](_0x19bdcc);const _0xfe3f21=new Map();for(const _0x41b401 of _0x38b334){let _0x5c1823=_0x30a708['insertions'][_0x41b401];for(const _0x464136 of _0x5c1823)if(_0x464136['item']['is']('element','tableCell')){const _0x22583d=this['_getVidAttributeName'](_0x464136),_0xe3ee60=_0x464136['item']['getAttribute'](_0x22583d);if(_0x1a7374['has'](_0xe3ee60)){const _0x1daaef=_0x464136['item']['parent']['parent']['getAttribute']('vid_start'),_0x3ece1e=_0xfe3f21['get'](_0x1daaef)||new Set();_0x3ece1e['add'](_0x1a7374['get'](_0xe3ee60)['userId']),_0xfe3f21['set'](_0x1daaef,_0x3ece1e);}}_0x5c1823=_0x30a708['deletions'][_0x41b401];for(const _0x15a406 of _0x5c1823)if(_0x15a406['item']['is']('element','tableCell')){const _0x3c8c8a=this['_getVidAttributeName'](_0x15a406),_0x4bd97b=_0x15a406['item']['getAttribute'](_0x3c8c8a);if(_0x1fe63e['has'](_0x4bd97b)){const _0x57856f=_0x15a406['item']['parent']['parent']['getAttribute']('vid_start'),_0x179eca=_0xfe3f21['get'](_0x57856f)||new Set();_0x179eca['add'](_0x1fe63e['get'](_0x4bd97b)['userId']),_0xfe3f21['set'](_0x57856f,_0x179eca);}}for(const _0x1735e2 of _0xfe3f21['keys']())(_0x1a7374['has'](_0x1735e2)||_0x1fe63e['has'](_0x1735e2))&&_0xfe3f21['delete'](_0x1735e2);}for(const _0x2b3974 of _0x38b334){const _0x25229d=_0x30a708['insertions'][_0x2b3974];let _0xf12d20=null,_0x3acb93=null;for(const _0x254cef of _0x25229d){const _0x5b5f68=this['_getVidAttributeName'](_0x254cef),_0x2592a0=_0x254cef['item']['getAttribute'](_0x5b5f68),_0x5a7ad6=_0xfe3f21['get'](_0x2592a0);_0x5a7ad6&&'elementStart'==_0x254cef['type']&&(_0xf12d20=Array['from'](_0x5a7ad6)[0x0],_0x3acb93=_0x254cef['item']['getAttribute']('vid_end')),_0xf12d20&&(_0x1fe63e['set'](_0x2592a0,{'userId':_0xf12d20}),_0x1a7374['set'](_0x2592a0,{'userId':_0xf12d20})),_0x2592a0==_0x3acb93&&(_0xf12d20=null,_0x3acb93=null);}}const _0x5655a1={},_0x603f92=new Set();for(const _0x2c10e5 of _0x38b334){const _0x27a330=_0x23c8b0['deletions'][_0x2c10e5],_0x2a8fc8=_0x23c8b0['insertions'][_0x2c10e5];for(const {userId:_0x59b961}of this['_touchedMarkers']['values']())null!==_0x59b961&&_0x603f92['add'](_0x59b961);for(const {userId:_0x177c97}of this['_touchedRoots']['values']())null!==_0x177c97&&_0x603f92['add'](_0x177c97);this['_markChanges'](_0x2a8fc8,_0x30a708['insertions'][_0x2c10e5],_0x1a7374,'insertion',_0x603f92),this['_markChanges'](_0x27a330,_0x30a708['deletions'][_0x2c10e5],_0x1fe63e,'deletion',_0x603f92),_0x5655a1[_0x2c10e5]={'insertions':this['_prepareViewToSave'](_0x2a8fc8),'deletions':this['_prepareViewToSave'](_0x27a330),'attachChange':this['_touchedRoots']['get'](_0x2c10e5)||null,'attributesBefore':_0x51eea2(this['_baseRootsAttributes']['get'](_0x2c10e5))||{},'attributesAfter':_0x51eea2(this['_diffRootsAttributes']['get'](_0x2c10e5))};}return{'diffData':_0x5655a1,'authorsIds':Array['from'](_0x603f92)};}['_processRootBeforeSave'](_0x27d8fe){for(const [,_0x27c65d]of _0x27d8fe['markers']){const _0x57bc67=_0x27c65d['start']['getAncestors']()['filter'](_0x52ef14=>'tableCell'==_0x52ef14['name']);for(const _0x3f1f6f of _0x57bc67)0x1==_0x3f1f6f['childCount']&&_0x3f1f6f['getChild'](0x0)['is']('element','paragraph')&&_0x3f1f6f['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x4e5e4c){this['_processRootBeforeSave'](_0x4e5e4c);const _0x4b6024=this['editor']['data']['toView'](_0x4e5e4c,{}),_0x137e90=Array['from'](_0x4b6024['getChildren']())['map'](_0x57bac5=>this['_getViewJson'](_0x57bac5));return JSON['stringify'](_0x137e90);}['_getViewJson'](_0x33d569){if(_0x33d569['is']('$text'))return _0x33d569['data'];{const _0x2d5c17=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0x234119=_0x33d569,_0x39361e=this['editor']['data']['htmlProcessor']['domConverter'],_0xfda901={'type':_0x2d5c17['_getTypeCharForViewElement'](_0x234119),'name':_0x234119['name'],'attributes':Array['from'](_0x234119['getAttributes']()),'children':Array['from'](_0x234119['getChildren']())['map'](_0x3d18de=>this['_getViewJson'](_0x3d18de))};if(_0x33d569['is']('uiElement')&&'$comment'!=_0x33d569['name']){const _0x356bff=_0x33d569['render'](_0x39361e['domDocument'],_0x39361e);_0xfda901['children']['push'](_0x356bff['outerHTML']);}else{if(_0x33d569['is']('rawElement')){const _0x1596fc=_0x39361e['domDocument']['createElement'](_0x234119['name']);_0x33d569['render'](_0x1596fc,_0x39361e),_0xfda901['children']['push'](_0x1596fc['innerHTML']);}}const _0x40729d=Array['from'](_0x234119['getCustomProperties']());_0x40729d['length']>0x0&&(_0xfda901['customProperties']=_0x40729d);const _0x1a5923=_0x234119['getFillerOffset']();return null!==_0x1a5923&&(_0xfda901['fillerOffset']=_0x1a5923),_0xfda901;}}['_markChanges'](_0xf18577,_0x3064ff,_0x437fe9,_0x4e08a5,_0x313e76){let _0x3d6061=null,_0x164ae9=null,_0x65cffb=0x0;const _0x4902d5=this['editor']['model'];for(let _0x5e293c=0x0;_0x5e293c<_0x3064ff['length'];_0x5e293c++){const _0x4ee48c=this['_getVidAttributeName'](_0x3064ff[_0x5e293c]),_0x30ec42=_0x3064ff[_0x5e293c]['item']['getAttribute'](_0x4ee48c),_0x328a0c=_0x437fe9['get'](_0x30ec42),_0x1e7f30=_0x5e293c==_0x3064ff['length']-0x1;(!_0x3d6061&&_0x328a0c&&(_0x3d6061=_0x328a0c,_0x164ae9=_0x3064ff[_0x5e293c]),_0x3d6061&&(!_0x328a0c||_0x328a0c['userId']!=_0x3d6061['userId']))&&(_0x4d3f79(_0x328a0c,F(_0x164ae9,_0xf18577,_0x4902d5),F(_0x3064ff[_0x5e293c],_0xf18577,_0x4902d5)),_0x3d6061=_0x328a0c||null,_0x164ae9=_0x328a0c?_0x3064ff[_0x5e293c]:null),_0x3d6061&&_0x1e7f30&&_0x4d3f79(_0x328a0c,F(_0x164ae9,_0xf18577,_0x4902d5),B(_0x3064ff[_0x5e293c],_0xf18577,_0x4902d5));}function _0x4d3f79(_0x20df49,_0x31f537,_0x56fa1e){const _0x63d1d4=_0x3d6061['userId'],_0x2e74f3='revision:'+_0x4e08a5+':'+_0x63d1d4+':'+_0x65cffb++,_0x4cba74=_0x4902d5['createRange'](_0x31f537,_0x56fa1e);_0xf18577['markers']['set'](_0x2e74f3,_0x4cba74),null!==_0x63d1d4&&_0x313e76['add'](_0x63d1d4);}}['_getVidAttributeName'](_0x11fa7b){switch(_0x11fa7b['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x351307,_0x457400){_0x351307['baseVersion']=null;for(const _0x1e06fa in _0x351307){const _0x559407=_0x351307[_0x1e06fa];if(_0x559407 instanceof vt){const _0x2f4a09=_0x457400['get'](_0x559407['root']['rootName']);_0x351307[_0x1e06fa]=this['_fixPosition'](_0x559407,_0x2f4a09);}if(_0x559407 instanceof ft){const _0x29af5f=_0x457400['get'](_0x559407['root']['rootName']);_0x351307[_0x1e06fa]=this['_fixRange'](_0x559407,_0x29af5f);}'root'===_0x1e06fa&&(_0x351307['root']=_0x457400['get'](_0x351307['root']['rootName']));}}['_fixRange'](_0x265ed8,_0x3587f2){return this['editor']['model']['createRange'](this['_fixPosition'](_0x265ed8['start'],_0x3587f2),this['_fixPosition'](_0x265ed8['end'],_0x3587f2));}['_fixPosition'](_0x383f9c,_0x32520f){return this['editor']['model']['createPositionFromPath'](_0x32520f,_0x383f9c['path'],_0x383f9c['stickiness']);}['_handleInsertOperation'](_0x5df376){const _0x1d0632=this['_idsRoots']['get'](_0x5df376['position']['root']['rootName']),_0xcdbfb2=this['_fixPosition'](_0x5df376['position'],_0x1d0632),_0x47971c=null===_0x5df376['_authorId']?null:_0x5df376['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x2b89ce=_0xcdbfb2['parent'],_0x2f3dd6=this['_revisionId'],_0xbcaeb5=[];for(const _0x17a489 of _0x5df376['nodes'])if(_0x17a489['is']('element'))_0xbcaeb5['push'](this['_makeIdsRoot'](_0x17a489));else{for(let _0x4f7c26=0x0;_0x4f7c26<_0x17a489['offsetSize'];_0x4f7c26++)_0xbcaeb5['push'](new ut('$text',{'vid':this['_revisionId']++}));}const _0xae020a=this['_revisionId'];for(let _0x5ea81f=_0x2f3dd6;_0x5ea81f<_0xae020a;_0x5ea81f++)this['_touched']['set'](_0x5ea81f,{'userId':_0x47971c});_0x2b89ce['_insertChild'](_0xcdbfb2['offset'],_0xbcaeb5);}['_handleMoveOperation'](_0x2b06be){(_0x2b06be=this['_cloneOperation'](_0x2b06be,this['_idsRoots']))['_execute']();const _0x5f4cc5=null===_0x2b06be['_authorId']?null:_0x2b06be['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x105261=_0x2b06be['getMovedRangeStart'](),_0x5af0de=_0x105261['parent'],_0x1139cc=_0x105261['offset'];!function _0x23faaf(_0xedb6f4,_0x1da9d3,_0x38fcd5,_0x54df8c){for(let _0x1ca23a=_0x38fcd5;_0x1ca23a<_0x54df8c;_0x1ca23a++){const _0x58bc0b=_0x1da9d3['getChild'](_0x1ca23a);_0x58bc0b['is']('element','$text')?_0xedb6f4['set'](_0x58bc0b['getAttribute']('vid'),{'userId':_0x5f4cc5}):(_0xedb6f4['set'](_0x58bc0b['getAttribute']('vid_start'),{'userId':_0x5f4cc5}),_0x23faaf(_0xedb6f4,_0x58bc0b,0x0,_0x58bc0b['childCount']),_0xedb6f4['set'](_0x58bc0b['getAttribute']('vid_end'),{'userId':_0x5f4cc5}));}}(this['_touched'],_0x5af0de,_0x1139cc,_0x1139cc+_0x2b06be['howMany']);}['_handleMergeOperation'](_0xc7ac76){const _0x149b4c=null===(_0xc7ac76=this['_cloneOperation'](_0xc7ac76,this['_idsRoots']))['_authorId']?null:_0xc7ac76['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x11228e=_0xc7ac76['targetPosition']['parent'],_0x5d46ef=_0xc7ac76['sourcePosition']['parent'],_0x4c00e0=_0x11228e['getAttribute']('vid_end'),_0x2c854d=_0x5d46ef['getAttribute']('vid_start');_0x11228e['_setAttribute']('vid_end',_0x5d46ef['getAttribute']('vid_end')),_0x5d46ef['_setAttribute']('vid_end',_0x4c00e0),this['_touched']['set'](_0x2c854d,{'userId':_0x149b4c}),this['_touched']['set'](_0x4c00e0,{'userId':_0x149b4c}),_0xc7ac76['_execute']();}['_handleSplitOperation'](_0x4dae4d){const _0x4617f2=null===(_0x4dae4d=this['_cloneOperation'](_0x4dae4d,this['_idsRoots']))['_authorId']?null:_0x4dae4d['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x3efbf2=_0x4dae4d['graveyardPosition'],_0x2a727d=_0x4dae4d['splitPosition']['parent'];_0x4dae4d['_execute']();const _0x198fa2=_0x2a727d['getAttribute']('vid_end'),_0x2b0553=_0x4dae4d['insertionPosition']['nodeAfter'];if(_0x3efbf2){const _0x4f8dba=_0x2b0553['getAttribute']('vid_end'),_0x37fd74=_0x2a727d['getAttribute']('vid_end');_0x2a727d['_setAttribute']('vid_end',_0x4f8dba),_0x2b0553['_setAttribute']('vid_end',_0x37fd74),this['_touched']['set'](_0x2a727d['getAttribute']('vid_end'),{'userId':_0x4617f2}),this['_touched']['set'](_0x2b0553['getAttribute']('vid_start'),{'userId':_0x4617f2});}else{const _0x468718=this['_revisionId']++,_0x2c1e46=this['_revisionId']++;_0x2a727d['_setAttribute']('vid_end',_0x468718),_0x2b0553['_setAttribute']('vid_start',_0x2c1e46),_0x2b0553['_setAttribute']('vid_end',_0x198fa2),this['_touched']['set'](_0x468718,{'userId':_0x4617f2}),this['_touched']['set'](_0x2c1e46,{'userId':_0x4617f2});}}['_handleMarkerOperation'](_0xc1dbc5){if(!_0xc1dbc5['affectsData'])return;const _0x4db042=(_0xc1dbc5=this['_cloneOperation'](_0xc1dbc5,this['_diffRoots']))['oldRange']?_0xc1dbc5['oldRange']['root']:null,_0x54a8e3=_0xc1dbc5['newRange']?_0xc1dbc5['newRange']['root']:null;_0x4db042&&this['_markers']['delete'](_0xc1dbc5['name']),_0x54a8e3&&this['_markers']['set'](_0xc1dbc5['name'],_0xc1dbc5['newRange']['clone']());const _0x509309=null===_0xc1dbc5['_authorId']?null:_0xc1dbc5['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x122cb5=_0xc1dbc5['name'];if(!this['_touchedMarkers']['has'](_0x122cb5))return void this['_touchedMarkers']['set'](_0x122cb5,{'range':_0xc1dbc5['oldRange'],'userId':_0x509309});const _0xb6214e=this['_touchedMarkers']['get'](_0x122cb5),_0x79942=_0xb6214e['range'],_0x9dbdfc=_0xc1dbc5['newRange'];null==_0x79942&&null==_0x9dbdfc||_0x79942&&_0x9dbdfc&&_0x79942['isEqual'](_0x9dbdfc)?this['_touchedMarkers']['delete'](_0xc1dbc5['name']):_0xb6214e['userId']=_0x509309;}['_handleRootOperation'](_0x442b06,_0x415db2){this['_diffRoots']['has'](_0x442b06['rootName'])?this['_diffRoots']['get'](_0x442b06['rootName'])['_isAttached']=_0x442b06['isAdd']:(this['_diffRoots']['set'](_0x442b06['rootName'],P(_0x442b06['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x442b06['rootName'],{}),_0x415db2&&this['_idsRoots']['set'](_0x442b06['rootName'],P(_0x442b06['rootName'],!0x0)));const _0x55cd06=null===_0x442b06['_authorId']?null:_0x442b06['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x103957=this['_touchedRoots']['get'](_0x442b06['rootName']);_0x103957&&_0x103957['userId']===_0x55cd06?this['_touchedRoots']['delete'](_0x442b06['rootName']):this['_touchedRoots']['set'](_0x442b06['rootName'],{'userId':_0x55cd06,'isAttached':_0x442b06['isAdd']});}['_handleRootAttributeOperation'](_0x2be69c){const _0x36a413=this['_diffRootsAttributes']['get'](_0x2be69c['root']['rootName']);null===_0x2be69c['newValue']?delete _0x36a413[_0x2be69c['key']]:_0x36a413[_0x2be69c['key']]=_0x2be69c['newValue'];}}function N(_0x796fbd){const _0x4498b6=P(_0x796fbd['rootName'],_0x796fbd['isAttached']());for(const _0x43d1f0 of _0x796fbd['getChildren']()){const _0x3a6c7c=_0x43d1f0['_clone'](!0x0);_0x4498b6['_appendChild'](_0x3a6c7c);}return _0x4498b6;}function P(_0x4c16fa,_0x13fe2b=!0x0){const _0x12ab79=new gt();return _0x12ab79['rootName']=_0x4c16fa,_0x12ab79['_isAttached']=_0x13fe2b,_0x12ab79['isAttached']=()=>_0x12ab79['_isAttached'],_0x12ab79;}function F(_0x197dfe,_0x34a460,_0x2c96bf){const _0x559966='elementEnd'==_0x197dfe['type']?_0x2c96bf['createPositionAt'](_0x197dfe['item'],'end'):_0x2c96bf['createPositionBefore'](_0x197dfe['item']);return _0x2c96bf['createPositionFromPath'](_0x34a460,_0x559966['path'],_0x559966['stickiness']);}function B(_0x15b895,_0x1fb8fa,_0xf18627){const _0x2e9693='elementStart'==_0x15b895['type']?_0xf18627['createPositionAt'](_0x15b895['item'],0x0):_0xf18627['createPositionAfter'](_0x15b895['item']);return _0xf18627['createPositionFromPath'](_0x1fb8fa,_0x2e9693['path'],_0x2e9693['stickiness']);}class os extends _0x2019f7{['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x5b1455,_0x4732b3){super(_0x5b1455),this['focusTracker']=new _0xd6fb6(),this['keystrokes']=new _0x10d155(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x4732b3),this['setTemplate']({'tag':'form','attributes':{'class':['ck','ck-revision-history-save-revision-form','ck-responsive-form'],'tabindex':'-1'},'children':[this['revisionNameInputView']]}),ts(this);}['render'](){super['render'](),_0x515eaa({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x1b42d3=_0x2c4495=>_0x2c4495['stopPropagation']();this['keystrokes']['set']('arrowright',_0x1b42d3),this['keystrokes']['set']('arrowleft',_0x1b42d3),this['keystrokes']['set']('arrowup',_0x1b42d3),this['keystrokes']['set']('arrowdown',_0x1b42d3);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x5ad910){this['revisionNameInputView']['fieldView']['element']['value']=_0x5ad910['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x2eb365){const _0x47939d=new nt(this['locale'],ti),_0x3b6e56=_0x47939d['fieldView'];_0x3b6e56['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x1baac2=g(this['locale'],'Name\x20of\x20the\x20revision');return!_0x2eb365&&(_0x1baac2+='\x20('+g(this['locale'],'optional')+')'),(_0x47939d['label']=_0x1baac2,_0x3b6e56['on']('input',()=>{this['revisionNameInputValue']=_0x3b6e56['element']['value']['trim']();}),_0x47939d);}}class f extends _0x2a1981{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u];}['_saveRevisionFormView'];['init'](){const _0xef02a9=this['editor'],_0x2092d6=_0xef02a9['plugins']['get']('RevisionTracker');_0xef02a9['ui']['componentFactory']['add']('revisionHistory',_0x2a5a00=>{const _0x54dc18=_0x43dd89(_0x2a5a00),_0x1bab23=_0x54dc18['panelView']['children'],_0x20dd2c=new _0x52357d(_0x2a5a00),_0x1b701c=new te(_0x2a5a00),_0xedc9a4=new _0xca59d9(_0x2a5a00),_0x1a0e63=new te(_0x2a5a00),_0x1414cd=new _0xca59d9(_0x2a5a00);return _0x54dc18['bind']('isEnabled')['to'](_0x2092d6,'isReady',_0x2092d6,'isEnabled',_0xef02a9,'isReadOnly',(_0x2f67d0,_0x2a3d05,_0x5c2c3e)=>_0x2f67d0&&_0x2a3d05&&!_0x5c2c3e),_0x54dc18['buttonView']['set']({'icon':_0x4d50e2,'label':g(_0x2a5a00,'Revision\x20history'),'tooltip':!0x0}),_0xedc9a4['set']({'label':g(_0x2a5a00,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0xedc9a4['bind']('isEnabled')['to'](_0x2092d6,'isReady',_0x2092d6,'isEnabled',_0xef02a9,'isReadOnly',(_0x420ed4,_0x2a1bca,_0x3b914b)=>_0x420ed4&&_0x2a1bca&&!_0x3b914b),_0xedc9a4['on']('execute',()=>this['_showDialog']()),_0x1414cd['set']({'label':g(_0x2a5a00,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x1414cd['bind']('isEnabled')['to'](_0x2092d6,'isReady',_0xef02a9,'isReadOnly',(_0x3837a0,_0x1bf3f6)=>_0x3837a0&&!_0x1bf3f6),_0x1414cd['on']('execute',()=>{_0xef02a9['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x54dc18['isOpen']=!0x1,_0xef02a9['editing']['view']['focus']();}),_0x1b701c['children']['add'](_0xedc9a4),_0x1a0e63['children']['add'](_0x1414cd),_0x20dd2c['role']='menu',_0x20dd2c['items']['addMany']([_0x1b701c,_0x1a0e63]),_0x1bab23['add'](_0x20dd2c),_0x54dc18;}),_0xef02a9['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x3dce17=this['editor'],_0x437a8f=_0x3dce17['locale'],_0x34dd81=new _0x54876c(_0x437a8f),_0x4c2802=new _0x1ff1fe(_0x437a8f);_0x34dd81['buttonView']['set']({'icon':_0x4d50e2,'label':g(_0x437a8f,'Revision\x20history')});const _0x7c8b00=new _0x2b081c(_0x437a8f,_0x34dd81),_0x19357b=new _0x1eef6c(_0x437a8f);_0x19357b['set']({'label':g(_0x437a8f,'Save\x20current\x20revision')}),_0x19357b['delegate']('execute')['to'](_0x34dd81),_0x19357b['on']('execute',()=>{this['_showDialog']();}),_0x7c8b00['children']['add'](_0x19357b),_0x4c2802['items']['add'](_0x7c8b00);const _0x320435=new _0x2b081c(_0x437a8f,_0x34dd81),_0x4ab065=new _0x1eef6c(_0x437a8f);return _0x4ab065['set']({'label':g(_0x437a8f,'Open\x20revision\x20history')}),_0x4ab065['delegate']('execute')['to'](_0x34dd81),_0x4ab065['on']('execute',()=>{_0x3dce17['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x320435['children']['add'](_0x4ab065),_0x4c2802['items']['add'](_0x320435),_0x34dd81['panelView']['children']['add'](_0x4c2802),_0x34dd81;}['_showDialog'](){const _0x82d667=this['editor'],_0x5be4f6=_0x82d667['locale'],_0x279d27=_0x82d667['plugins']['get']('Dialog'),_0x16783e=_0x82d667['plugins']['get']('RevisionTracker');function _0x2c1b05(_0x54b614){_0x82d667['config']['get']('revisionHistory.requireRevisionName')&&''===_0x54b614['revisionName']?_0x54b614['revisionNameInputView']['errorText']=g(_0x5be4f6,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x82d667['plugins']['get'](u)['saveRevision']({'name':_0x54b614['revisionName']}),_0x279d27['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x2c1b05(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x279d27['show']({'id':'revisionSave','title':g(_0x5be4f6,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':g(_0x82d667['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x279d27['hide']()},{'label':g(_0x82d667['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x29ade3){_0x29ade3['bind']('isEnabled')['to'](_0x16783e,'isReady',_0x16783e,'isEnabled',_0x82d667,'isReadOnly',(_0x35944a,_0x5e3248,_0x29e48a)=>_0x35944a&&_0x5e3248&&!_0x29e48a);},'onExecute':()=>_0x2c1b05(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x29f6c4=this['editor'],_0x5117d5=_0x29f6c4['locale'];this['_saveRevisionFormView']=new os(_0x5117d5,_0x29f6c4['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class Q extends _0x2019f7{['changeId'];['_model'];constructor(_0x1304ac,_0xc5846b){super(_0x1304ac),this['_model']=_0xc5846b,this['changeId']=_0xc5846b['id'];const _0x360485=this['bindTemplate'],_0xecc348=g(_0x1304ac,_0xc5846b['data']['isSuggestion']?'Suggested\x20by':'add'==_0xc5846b['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0xc5846b['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x360485['to']('type',_0x826588=>'ck-revision-change__'+_0x826588)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0xecc348}]},{'text':'\x20'+_0xc5846b['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class r extends/* #__PURE__ -- @preserve */
25
- _0x289f1c(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x17e6ef){super(),this['id']=_0x17e6ef['id']||_0x5c32ae(),this['author']=_0x17e6ef['author'],this['type']=_0x17e6ef['type'],this['data']=_0x17e6ef['data']||{},this['rootName']=_0x17e6ef['rootName'],this['set']('createdAt',_0x17e6ef['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(_0x11e37d,_0x4bb62c){this['newRevisionId']=_0x11e37d,this['oldRevisionId']=_0x4bb62c,this['changes']=new _0x1dfd6a();}['_setChanges'](_0x3a7595){for(const _0x46462f of _0x3a7595)this['changes']['add'](_0x46462f);}}class m extends _0x2a1981{['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[_0xcbcc6a,_0x532509,I,V];}constructor(_0x5ac025){super(_0x5ac025),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',(_0x355038,_0x514dcd,_0xfd63a2)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x18e750=>{for(const _0x2800a9 of this['editor']['editing']['view']['document']['roots'])_0xfd63a2?_0x18e750['removeClass']('ck-editor__editable__overlay',_0x2800a9):_0x18e750['addClass']('ck-editor__editable__overlay',_0x2800a9);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x1c81ff=>null!==_0x1c81ff),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x4e3a27,_0x857606,_0x20b58e)=>_0x4e3a27&&_0x20b58e?_0x857606['changes']['getIndex'](_0x20b58e):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x5c5ffa,_0x5c2974)=>_0x5c5ffa?_0x5c2974['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0x532509);}['init'](){const _0xe7360b=this['editor'],_0x57d7bb=new pt(_0xe7360b,{'direction':'backward'}),_0x5cc8f7=new pt(_0xe7360b,{'direction':'forward'});(_0xe7360b['commands']['add']('showPreviousChange',_0x57d7bb),_0xe7360b['commands']['add']('showNextChange',_0x5cc8f7),_0xe7360b['commands']['add']('restoreRevision',new wt(_0xe7360b)),this['on']('change:numberOfChanges',()=>{_0x57d7bb['refresh'](),_0x5cc8f7['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0xe7360b['enableReadOnlyMode']('revision-viewer'),_0xe7360b['plugins']['has']('WidgetToolbarRepository'))&&_0xe7360b['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0xddc372){return await this['_utils']['loadRevisionData'](_0xddc372,this['adapter']),this['_utils']['getRevisionDocumentData'](_0xddc372);}async['getRevisionRootsAttributes'](_0x4ac3ef){return await this['_utils']['loadRevisionData'](_0x4ac3ef,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x4ac3ef);}async['compare'](_0xf30fc0,_0xa144c,_0x4e3f73=!0x1){if(!this['isEnabled'])return;const _0xcfee19=this['diff'],_0x5c49b9=this['repository'],_0x120f28='string'==typeof _0xf30fc0?_0x5c49b9['getRevision'](_0xf30fc0):_0xf30fc0,_0x25f471='string'==typeof _0xa144c?_0x5c49b9['getRevision'](_0xa144c):_0xa144c,_0x2697ad=_0x120f28['id'],_0x46e59e=_0x25f471?_0x25f471['id']:null;if(!_0x4e3f73&&this['diff']&&this['diff']['newRevisionId']===_0x2697ad&&this['diff']['oldRevisionId']===_0x46e59e)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new c(_0x2697ad,_0x46e59e);const _0x149e96=this['_getRevisionsRange'](_0x120f28,_0x25f471,!0x0)['map'](_0x2533b7=>this['_utils']['loadRevisionData'](_0x2533b7,this['adapter']));return _0x149e96['push'](new Promise(_0x2168ed=>{setTimeout(_0x2168ed,0x14);})),Promise['all'](_0x149e96)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x377f42=this['_getDiff'](_0x2697ad,_0x46e59e);for(const _0x460e99 of _0x377f42['changes'])this['_changeIdToChange']['set'](_0x460e99['id'],_0x460e99);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x46f765=>{for(const _0x5b766a of this['editor']['model']['document']['getRootNames']())_0x46f765['detachRoot'](_0x5b766a);for(const _0x4c8956 of Object['keys'](_0x377f42['model'])){const _0x2797a8=_0x46f765['addRoot'](_0x4c8956);for(const _0x30fd7a of Object['keys'](_0x377f42['attributes'][_0x4c8956]))_0x46f765['setAttribute'](_0x30fd7a,_0x377f42['attributes'][_0x4c8956][_0x30fd7a],_0x2797a8);_0x46f765['insert'](_0x377f42['model'][_0x4c8956],_0x2797a8,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x377f42['changes'])),this['isReady']=!0x0;})['catch'](_0x155183=>{console['error'](_0x155183),this['_cleanUp'](),_0xcfee19&&(this['diff']=_0xcfee19),this['isReady']=!0x0;});}['addRevisionData'](_0x115de1,_0x4887a2){const _0x50169d=this['repository']['createRevision'](_0x115de1);return _0x50169d['on']('_update',(_0x5d4314,_0x27740c,_0x158bcb)=>_0x4887a2(_0x27740c,_0x158bcb,_0x50169d)),this['repository']['addRevision'](_0x50169d),_0x50169d;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x23e759=>{for(const _0x4394c1 of this['editor']['model']['document']['getRootNames']())_0x23e759['detachRoot'](_0x4394c1);});}['_sortAndFilterDiffChanges'](_0x11b58d){const _0x2c6056=[],_0x3d2e75=new Map();for(const _0x2edcaf of this['editor']['model']['document']['getRootNames']()){const _0x56d069=this['editor']['editing']['view']['getDomRoot'](_0x2edcaf);if(!_0x56d069)continue;const _0x52712a=_0x56d069['getClientRects']()['item'](0x0);_0x52712a&&(_0x2c6056['push'](_0x2edcaf),_0x3d2e75['set'](_0x2edcaf,_0x52712a));}return _0x2c6056['sort']((_0x3ed9a5,_0x2697c2)=>{const _0xe9b8db=_0x3d2e75['get'](_0x3ed9a5),_0x1d1a1d=_0x3d2e75['get'](_0x2697c2);return _0xe9b8db['y']-_0x1d1a1d['y']||_0xe9b8db['x']-_0x1d1a1d['x'];}),(_0x11b58d=_0x11b58d['filter'](_0x33b9b4=>_0x2c6056['includes'](_0x33b9b4['rootName'])))['sort']((_0x754e61,_0x5a0315)=>_0x2c6056['indexOf'](_0x754e61['rootName'])-_0x2c6056['indexOf'](_0x5a0315['rootName'])),_0x11b58d;}['_makeTape'](_0x1c9877){const _0x31761f=Array['from'](_0x1c9877['markers'])['filter'](([_0xc56b1a,_0x45e305])=>_0xc56b1a['startsWith']('revision:')&&!_0x45e305['isCollapsed']),_0x934e2d=Array['from'](this['editor']['model']['createRangeIn'](_0x1c9877)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x31761f['length'])for(const _0x433468 of _0x934e2d){const [_0x355d02,_0x441da0]=_0x31761f[0x0],[,_0x1d365b,_0x48445d]=_0x355d02['split'](':');if(_0x441da0['end']['isEqual'](_0x433468['nextPosition'])&&_0x31761f['shift'](),(_0x433468['previousPosition']['isEqual'](_0x441da0['start'])||_0x433468['previousPosition']['isAfter'](_0x441da0['start']))&&('insertion'==_0x1d365b?_0x433468['isAdded']={'userId':_0x48445d}:'deletion'==_0x1d365b&&(_0x433468['isRemoved']={'userId':_0x48445d})),0x0==_0x31761f['length'])break;}return _0x934e2d;}['_refreshStartEndIndex'](_0x47e4b6){const _0x2d8616=new Map();for(let _0x17ea82=0x0;_0x17ea82<_0x47e4b6['length'];_0x17ea82++)'text'===_0x47e4b6[_0x17ea82]['type']?(_0x47e4b6[_0x17ea82]['item']['startIndex']=_0x17ea82,_0x47e4b6[_0x17ea82]['item']['endIndex']=_0x17ea82):('elementStart'===_0x47e4b6[_0x17ea82]['type']?_0x47e4b6[_0x17ea82]['item']['startIndex']=_0x17ea82:'elementEnd'===_0x47e4b6[_0x17ea82]['type']&&(_0x47e4b6[_0x17ea82]['item']['endIndex']=_0x17ea82),_0x2d8616['set'](_0x47e4b6[_0x17ea82]['id'],_0x17ea82));for(const _0xf701f9 of _0x2d8616['values']())'elementStart'===_0x47e4b6[_0xf701f9]['type']?_0x47e4b6[_0xf701f9]['item']['endIndex']=_0x2d8616['get'](_0x47e4b6[_0xf701f9]['pairId']):'elementEnd'===_0x47e4b6[_0xf701f9]['type']&&(_0x47e4b6[_0xf701f9]['item']['startIndex']=_0x2d8616['get'](_0x47e4b6[_0xf701f9]['pairId']));}['_processTape'](_0x3bfffc){for(let _0x12b3ea=0x0;_0x12b3ea<_0x3bfffc['length'];_0x12b3ea++){if('elementStart'===_0x3bfffc[_0x12b3ea]['type'])_0x3bfffc[_0x12b3ea]['item']['startIndex']=_0x12b3ea;else{if('elementEnd'===_0x3bfffc[_0x12b3ea]['type']){_0x3bfffc[_0x12b3ea]['item']['endIndex']=_0x12b3ea;const _0x31bf89=_0x3bfffc[_0x12b3ea]['item']['startIndex'];_0x3bfffc[_0x31bf89]['pairId']=_0x3bfffc[_0x12b3ea]['id'],_0x3bfffc[_0x12b3ea]['pairId']=_0x3bfffc[_0x31bf89]['id'];}else _0x3bfffc[_0x12b3ea]['item']['startIndex']=_0x12b3ea,_0x3bfffc[_0x12b3ea]['item']['endIndex']=_0x12b3ea,_0x3bfffc[_0x12b3ea]['pairId']=null;}_0x3bfffc[_0x12b3ea]['markersStart']||(_0x3bfffc[_0x12b3ea]['markersStart']=[],_0x3bfffc[_0x12b3ea]['markersEnd']=[]);}}['_markInsertions'](_0x2615a6,_0x551926){const _0x597b9a=_0x2615a6['filter'](_0x102aba=>!_0x102aba['isAdded']);for(let _0x5b7383=0x0;_0x5b7383<_0x551926['length'];_0x5b7383++)_0x551926[_0x5b7383]['isAdded']&&(_0x597b9a[_0x5b7383]['isAdded']=_0x551926[_0x5b7383]['isAdded']);}['_getDiff'](_0x16a429,_0x5dafc5=null){const _0x2aab43=this['repository']['getRevision'](_0x16a429),_0x224f6c=_0x5dafc5?this['repository']['getRevision'](_0x5dafc5):null,_0x574b04=this['_getRevisionsRange'](_0x2aab43,_0x224f6c),_0x26eb99=_0x574b04[_0x574b04['length']-0x1],_0x4607c0=new Map(),_0x39cb58={'model':{},'attributes':{},'changes':[]},_0x3c385c=new Set(),_0x1c06a9=new Map();for(let _0x38ebc5=_0x574b04['length']-0x1;_0x38ebc5>=0x0;_0x38ebc5--){const _0x40ef37=_0x574b04[_0x38ebc5];for(const _0x4bcb1f of Object['keys'](_0x40ef37['diffData']))if(_0x40ef37['diffData'][_0x4bcb1f]['attachChange']){const _0x2c91bc=_0x40ef37['diffData'][_0x4bcb1f]['attachChange'];_0x2c91bc['isAttached']?(_0x3c385c['add'](_0x4bcb1f),_0x1c06a9['has'](_0x4bcb1f)&&_0x1c06a9['get'](_0x4bcb1f)['userId']==_0x2c91bc['userId']?_0x1c06a9['delete'](_0x4bcb1f):_0x1c06a9['set'](_0x4bcb1f,_0x2c91bc)):_0x1c06a9['has'](_0x4bcb1f)?(_0x3c385c['delete'](_0x4bcb1f),_0x1c06a9['delete'](_0x4bcb1f)):(_0x3c385c['add'](_0x4bcb1f),_0x1c06a9['set'](_0x4bcb1f,_0x2c91bc));}else _0x3c385c['add'](_0x4bcb1f);}for(const _0x18472a of _0x3c385c){const _0x47372a=_0x1c06a9['has'](_0x18472a)&&!_0x1c06a9['get'](_0x18472a)['isAttached'];let _0x1c7356=_0x47372a?_0x574b04['length']-0x1:0x0;const _0x4eefab=_0x47372a?-0x1:0x1;for(;_0x574b04[_0x1c7356];){const _0xe53a34=_0x574b04[_0x1c7356];if(_0xe53a34['diffData'][_0x18472a]){const _0x424d78=_0x47372a?_0xe53a34['diffData'][_0x18472a]['attributesBefore']:_0xe53a34['diffData'][_0x18472a]['attributesAfter'];_0x39cb58['attributes'][_0x18472a]=_0x424d78?_0x51eea2(_0x424d78):{};break;}_0x1c7356+=_0x4eefab;}}for(const _0x39681a of _0x574b04){_0x39681a['model']={};for(const _0x512d56 of _0x39681a['authors'])_0x4607c0['set'](_0x512d56['id'],_0x512d56);for(const _0x42e9e6 of _0x3c385c){const _0x120943=_0x39681a['diffData'][_0x42e9e6]?_0x39681a['diffData'][_0x42e9e6]['insertions']:'[]',_0x5822bd=_0x39681a['diffData'][_0x42e9e6]?_0x39681a['diffData'][_0x42e9e6]['deletions']:'[]';_0x39681a['model'][_0x42e9e6]={'insertions':this['_utils']['_makeModelFromViewString'](_0x120943),'deletions':this['_utils']['_makeModelFromViewString'](_0x5822bd)};}}for(const _0x42d9bb of _0x3c385c){let _0x1a0b8c=null,_0x3ffe1a=0x0;const _0x3c56ff=new Map(Array['from'](_0x2aab43['model'][_0x42d9bb]['insertions']['markers'])['filter'](([_0x11528b])=>!_0x11528b['startsWith']('revision:')));let _0x4f86aa=0x0;for(const _0x46c5ad of _0x574b04){const _0xeb1577=this['_makeTape'](_0x46c5ad['model'][_0x42d9bb]['insertions']);_0x46c5ad==_0x2aab43?(_0x1a0b8c=_0xeb1577,_0x3ffe1a=_0x1a0b8c['length'],_0x1a0b8c['forEach'](_0x374506=>{_0x374506['id']=_0x4f86aa++;}),this['_processTape'](_0x1a0b8c)):this['_markInsertions'](_0x1a0b8c,_0xeb1577);const _0x319649=_0x1a0b8c['filter'](_0x13d522=>!_0x13d522['isAdded'])['map'](_0x1fe965=>_0x1fe965['id']);let _0x39e92e=0x0;const _0x51e2af=this['_makeTape'](_0x46c5ad['model'][_0x42d9bb]['deletions']);_0x51e2af['forEach'](_0x5d9336=>{_0x5d9336['isRemoved']?_0x5d9336['id']=_0x3ffe1a++:_0x5d9336['id']=_0x319649[_0x39e92e++];}),this['_processTape'](_0x51e2af),this['_setDistance'](_0x1a0b8c,'isAdded'),this['_setDistance'](_0x51e2af,'isRemoved'),_0x46c5ad==_0x2aab43&&this['_markMarkers'](_0x1a0b8c,_0x3c56ff),_0x1a0b8c=this['_joinTapes'](_0x1a0b8c,_0x51e2af),this['_refreshStartEndIndex'](_0x1a0b8c),this['_setDistance'](_0x1a0b8c,'isRemoved');}_0x1a0b8c=_0x1a0b8c['filter'](_0x47a9a9=>!(_0x47a9a9['isAdded']&&_0x47a9a9['isRemoved']));const _0x3b2262=new Map(_0x26eb99['model'][_0x42d9bb]['deletions']['markers']),_0x2c3a39=new Set(_0x3c56ff['keys']());for(const _0x3b67ed of _0x3b2262['keys']())_0x2c3a39['delete'](_0x3b67ed);this['_markSuggestions'](_0x1a0b8c,_0x2c3a39),this['_fixObsoleteTags'](_0x1a0b8c),_0x1a0b8c=this['_removeMissingPairs'](_0x1a0b8c),_0x1a0b8c=this['_markMismatchedRemovedTags'](_0x1a0b8c),_0x1a0b8c=this['_removeUnsupportedChanges'](_0x1a0b8c);const {root:_0x2aebc0,changes:_0x5601d5}=this['_makeModelFromTape'](_0x1a0b8c,_0x4607c0,_0x42d9bb);_0x39cb58['model'][_0x42d9bb]=_0x2aebc0;const _0x44df97=_0x1c06a9['get'](_0x42d9bb);if(_0x44df97){const _0x5838af=_0x4607c0['get'](_0x44df97['userId']),_0x360bc5=new r({'author':_0x5838af,'type':_0x44df97['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x42d9bb});_0x5601d5['unshift'](_0x360bc5),_0x39cb58['attributes'][_0x42d9bb]['revisionHistoryAttachChange']=_0x360bc5['id'];}_0x39cb58['changes']=_0x39cb58['changes']['concat'](_0x5601d5);}return _0x39cb58;}['_markMarkers'](_0x2afd08,_0x24d599){for(let _0x249057=0x0;_0x249057<_0x2afd08['length'];_0x249057++)for(const [_0x3a6566,_0x55dd2e]of _0x24d599)!_0x55dd2e['isCollapsed']&&_0x55dd2e['start']['isEqual'](_0x2afd08[_0x249057]['previousPosition'])&&_0x2afd08[_0x249057]['markersStart']['push'](_0x3a6566),_0x55dd2e['end']['isEqual'](_0x2afd08[_0x249057]['nextPosition'])&&_0x2afd08[_0x249057]['markersEnd']['push'](_0x3a6566);}['_joinTapes'](_0x35af4d,_0x4935ab){let _0x42f0a2=[],_0x3576ec=0x0,_0x3687ca=0x0;for(;_0x3576ec<_0x35af4d['length']||_0x3687ca<_0x4935ab['length'];){const _0x27d30b=_0x35af4d[_0x3576ec]||{},_0x18467a=_0x4935ab[_0x3687ca]||{};if(_0x27d30b['id']==_0x18467a['id'])_0x3576ec++,_0x3687ca++,_0x42f0a2['push'](_0x27d30b);else{if(_0x18467a['isRemoved']&&_0x27d30b['isAdded']){const {commonTape:_0x914e2d,iEnd:_0x50627c,jEnd:_0x12b854}=this['_threeWayMerge'](_0x35af4d,_0x3576ec,_0x4935ab,_0x3687ca);_0x42f0a2=_0x42f0a2['concat'](_0x914e2d),_0x3576ec=_0x50627c,_0x3687ca=_0x12b854;}else _0x18467a['isRemoved']?(_0x3687ca++,_0x42f0a2['push'](_0x18467a)):(_0x3576ec++,_0x42f0a2['push'](_0x27d30b));}}return _0x42f0a2;}['_markSuggestions'](_0x476215,_0x550ed1){const _0x262565=[];for(let _0x6fe4f1=0x0;_0x6fe4f1<_0x476215['length'];_0x6fe4f1++){for(let _0x8ec9a7=0x0;_0x8ec9a7<_0x476215[_0x6fe4f1]['markersStart']['length'];_0x8ec9a7++){const _0x4f96f0=_0x476215[_0x6fe4f1]['markersStart'][_0x8ec9a7];if(!_0x550ed1['has'](_0x4f96f0))continue;const {group:_0xead7f8,type:_0x4298f8,authorId:_0x36195c}=_0x4eecf8(_0x4f96f0);'revision-suggestion'!=_0xead7f8||'insertion'!=_0x4298f8&&'deletion'!=_0x4298f8||(_0x262565['unshift']({'type':_0x4298f8,'name':_0x4f96f0,'userId':_0x36195c}),_0x476215[_0x6fe4f1]['markersStart']['splice'](_0x8ec9a7,0x1),_0x8ec9a7--);}_0x265464(_0x476215[_0x6fe4f1]);for(let _0x22ebaf=0x0;_0x22ebaf<_0x476215[_0x6fe4f1]['markersEnd']['length'];_0x22ebaf++){const _0x228efe=_0x476215[_0x6fe4f1]['markersEnd'][_0x22ebaf];if(!_0x550ed1['has'](_0x228efe))continue;const {group:_0x291363,type:_0x3f8f6a}=_0x4eecf8(_0x228efe);if('revision-suggestion'!=_0x291363||'insertion'!=_0x3f8f6a&&'deletion'!=_0x3f8f6a)continue;_0x476215[_0x6fe4f1]['markersEnd']['splice'](_0x22ebaf,0x1),_0x22ebaf--;const _0x426782=_0x262565['findIndex'](_0x5a52b8=>_0x5a52b8['name']==_0x228efe);_0x426782>-0x1&&_0x262565['splice'](_0x426782,0x1);}}function _0x4eecf8(_0x11403d){const _0x5cc4a4=_0x11403d['split'](':');return{'group':_0x5cc4a4[0x0],'type':_0x5cc4a4[0x1],'subType':_0x5cc4a4['length']>=0x5?_0x5cc4a4[0x2]:null,'id':_0x5cc4a4['length']<0x5?_0x5cc4a4[0x2]:_0x5cc4a4[0x3],'authorId':_0x5cc4a4['length']<0x5?_0x5cc4a4[0x3]:_0x5cc4a4[0x4],'markerCount':0x6==_0x5cc4a4['length']?_0x5cc4a4[0x5]:null};}function _0x265464(_0x5f57f7){for(let _0x247c52=0x0;_0x247c52<_0x262565['length'];_0x247c52++){if(_0x5f57f7['isAdded']&&'insertion'==_0x262565[_0x247c52]['type'])return _0x5f57f7['isAddSuggestion']=_0x262565[_0x247c52],void delete _0x5f57f7['isAdded'];if(!_0x5f57f7['isAdded']&&!_0x5f57f7['isRemoved']&&'deletion'==_0x262565[_0x247c52]['type'])return void(_0x5f57f7['isRemoveSuggestion']=_0x262565[_0x247c52]);}}}['_setDistance'](_0xf7e2a6,_0x3588d4){let _0x3c8bf4=0x0,_0x2987cd=!0x1;const _0xf58450=new Map();for(const _0x49789d of _0xf7e2a6)_0x49789d[_0x3588d4]?_0x2987cd&&(_0x3c8bf4++,_0x2987cd=!0x1):(_0x3c8bf4++,_0x2987cd=!0x0),_0xf58450['set'](_0x49789d['id'],_0x3c8bf4);for(let _0x1cc82c=0x0;_0x1cc82c<_0xf7e2a6['length'];_0x1cc82c++){if('isRemoved'==_0x3588d4&&_0xf7e2a6[_0x1cc82c]['isAdded']||'isAdded'==_0x3588d4&&_0xf7e2a6[_0x1cc82c]['isRemoved'])continue;if('text'==_0xf7e2a6[_0x1cc82c]['type']){_0xf7e2a6[_0x1cc82c]['distance']=0x0;continue;}const _0x3ada74=_0xf58450['get'](_0xf7e2a6[_0x1cc82c]['pairId']),_0x467bb2=_0xf58450['get'](_0xf7e2a6[_0x1cc82c]['id']);_0xf7e2a6[_0x1cc82c]['distance']=_0x3ada74-_0x467bb2;}}['_getRevisionsRange'](_0x344f27,_0x333e9e,_0x31a521=!0x1){const _0x38586c=[];let _0x23d9f3=this['repository']['getIndex'](_0x344f27),_0x14eff3=this['repository']['getIndex'](_0x333e9e);for(-0x1==_0x14eff3&&(_0x14eff3=this['repository']['_revisions']['length'],_0x31a521=!0x1);_0x23d9f3<_0x14eff3;)_0x38586c['push'](this['repository']['getRevision'](_0x23d9f3)),_0x23d9f3++;return _0x31a521&&_0x38586c['push'](this['repository']['getRevision'](_0x23d9f3)),_0x38586c;}['_threeWayMerge'](_0x55dba4,_0x2ec940,_0x49e031,_0xcd50c2){const _0x2942f8=this['editor']['model']['schema'];let _0x347c27=_0x2ec940;for(;_0x55dba4[_0x347c27]&&_0x55dba4[_0x347c27]['isAdded'];)_0x347c27++;let _0x286c07=_0xcd50c2;for(;_0x49e031[_0x286c07]&&_0x49e031[_0x286c07]['isRemoved'];)_0x286c07++;_0x18cd8d(_0x55dba4,_0x2ec940,_0x347c27),_0x18cd8d(_0x49e031,_0xcd50c2,_0x286c07);const _0x462925=_0x49e031['slice'](_0xcd50c2,_0x286c07)['concat'](_0x55dba4['slice'](_0x2ec940,_0x347c27));return _0x462925['sort']((_0x26daed,_0xd5086e)=>_0x26daed['side']!=_0xd5086e['side']?_0x26daed['side']-_0xd5086e['side']:_0x26daed['level']!=_0xd5086e['level']?_0x26daed['level']-_0xd5086e['level']:_0x26daed['distance']!=_0xd5086e['distance']?_0xd5086e['distance']-_0x26daed['distance']:!!_0x26daed['isAdded']!=!!_0xd5086e['isAdded']?-0x1==_0x26daed['side']||0x0==_0x26daed['side']?_0x26daed['isAdded']?-0x1:0x1:_0x26daed['isAdded']?0x1:-0x1:_0x26daed['index']-_0xd5086e['index']),{'commonTape':_0x462925,'iEnd':_0x347c27,'jEnd':_0x286c07};function _0x18cd8d(_0x5e4955,_0x5de981,_0x5d088b){let _0x1a0a02=-0x1,_0x55894b=Number['POSITIVE_INFINITY'],_0x3c7175=!0x0;for(let _0x1eb32e=_0x5de981;_0x1eb32e<_0x5d088b;_0x1eb32e++)if(_0x2942f8['isInline'](_0x5e4955[_0x1eb32e]['item'])||(_0x3c7175=!0x1),_0x5e4955[_0x1eb32e]['item']['startIndex']<_0x5de981&&(_0x1a0a02=_0x1eb32e),_0x5e4955[_0x1eb32e]['item']['endIndex']>=_0x5d088b){_0x55894b=_0x1eb32e;break;}_0x3c7175&&(_0x1a0a02=_0x5d088b-0x1);for(let _0x153cbf=_0x5de981;_0x153cbf<_0x5d088b;_0x153cbf++)_0x5e4955[_0x153cbf]['side']=_0x153cbf<=_0x1a0a02?-0x1:_0x153cbf<_0x55894b?0x0:0x1,_0x5e4955[_0x153cbf]['index']=_0x153cbf;let _0x38c48c=0x0;for(let _0x58c933=_0x5de981;_0x58c933<=_0x1a0a02;_0x58c933++)0x0==_0x5e4955[_0x58c933]['distance']?_0x5e4955[_0x58c933]['level']=_0x38c48c:(_0x38c48c++,_0x5e4955[_0x58c933]['level']=_0x38c48c,_0x38c48c++);for(let _0x261877=_0x5de981;_0x261877<_0x5d088b;_0x261877++)0x0==_0x5e4955[_0x261877]['side']&&(_0x5e4955[_0x261877]['level']=_0x38c48c);_0x38c48c=0x0;for(let _0x108305=_0x5d088b-0x1;_0x108305>=_0x55894b;_0x108305--)0x0==_0x5e4955[_0x108305]['distance']?_0x5e4955[_0x108305]['level']=_0x38c48c:(_0x38c48c--,_0x5e4955[_0x108305]['level']=_0x38c48c,_0x38c48c--);}}['_fixObsoleteTags'](_0x19addc){const _0x437c47=new Map(),_0x5d353b=this['editor']['model']['schema'];for(let _0x424193=0x1;_0x424193<_0x19addc['length'];_0x424193++){let _0x9d49d5,_0x917392,_0x3f7b72;const _0x13c57f=_0x19addc[_0x424193],_0x1ed88e=_0x19addc[_0x424193-0x1];if('text'==_0x13c57f['type'])continue;if(_0x13c57f['type']!=_0x1ed88e['type'])continue;if(!_0x5d353b['isBlock'](_0x1ed88e['item'])||_0x5d353b['isLimit'](_0x1ed88e['item']))continue;if(!_0x5d353b['isBlock'](_0x13c57f['item'])||_0x5d353b['isLimit'](_0x13c57f['item']))continue;if((_0x19addc[_0x424193]['isAdded']||_0x19addc[_0x424193]['isAddSuggestion'])&&_0x19addc[_0x424193-0x1]['isRemoved'])_0x9d49d5=_0x19addc[_0x424193],_0x917392=_0x19addc[_0x424193-0x1],_0x3f7b72=_0x424193-0x1;else{if(!_0x19addc[_0x424193]['isRemoved']||!_0x19addc[_0x424193-0x1]['isAdded']&&!_0x19addc[_0x424193-0x1]['isAddSuggestion'])continue;_0x9d49d5=_0x19addc[_0x424193-0x1],_0x917392=_0x19addc[_0x424193],_0x3f7b72=_0x424193;}const _0x6e9cb3=_0x9d49d5['level']==_0x917392['level'],_0x1f811e=Math['abs'](_0x9d49d5['level'])<Math['abs'](_0x917392['level'])&&0x0==_0x917392['distance'];(_0x6e9cb3||_0x1f811e)&&(_0x437c47['set'](_0x917392['id'],_0x9d49d5['id']),_0x19addc['splice'](_0x3f7b72,0x1),_0x424193--,_0x9d49d5['isAdded']=!0x1);}for(let _0x55d913=0x0;_0x55d913<_0x19addc['length'];_0x55d913++)_0x437c47['has'](_0x19addc[_0x55d913]['pairId'])&&(_0x19addc[_0x55d913]['pairId']=_0x437c47['get'](_0x19addc[_0x55d913]['pairId']));}['_removeMissingPairs'](_0x5591c3){const _0x1d16a0=new Set(_0x5591c3['map'](_0x32c600=>_0x32c600['id']));for(let _0x41ea38=0x0;_0x41ea38<_0x5591c3['length'];_0x41ea38++)_0x1d16a0['has'](_0x5591c3[_0x41ea38]['pairId'])||0x0==_0x5591c3[_0x41ea38]['distance']||(_0x5591c3[_0x41ea38]['isIncorrect']=!0x0);return _0x5591c3['filter'](_0x24a11a=>!_0x24a11a['isIncorrect']);}['_markMismatchedRemovedTags'](_0x766037){const _0x345ac6=new Set();for(let _0x5b823d=0x0;_0x5b823d<_0x766037['length'];_0x5b823d++){if(_0x345ac6['has'](_0x766037[_0x5b823d]['id'])&&_0x766037[_0x5b823d]['isRemoved']&&(_0x766037[_0x5b823d]['isIncorrect']=!0x0),_0x766037[_0x5b823d]['isIncorrect'])continue;if(0x0==_0x766037[_0x5b823d]['distance'])continue;if('elementStart'!=_0x766037[_0x5b823d]['type'])continue;if(null==_0x766037[_0x5b823d]['pairId'])continue;let _0x46be3=_0x5b823d+0x1,_0x3b89d8=0x0;for(;_0x766037[_0x46be3]['id']!=_0x766037[_0x5b823d]['pairId'];)'elementStart'==_0x766037[_0x46be3]['type']?_0x3b89d8++:'elementEnd'==_0x766037[_0x46be3]['type']&&_0x3b89d8--,_0x46be3++;if(0x0!=_0x3b89d8){if(_0x766037[_0x5b823d]['isRemoved'])_0x766037[_0x5b823d]['isIncorrect']=!0x0;else{for(;_0x46be3!=_0x5b823d;)_0x766037[_0x46be3]['isRemoved']&&0x0!=_0x766037[_0x46be3]['distance']&&(_0x766037[_0x46be3]['isIncorrect']=!0x0,_0x345ac6['add'](_0x766037[_0x46be3]['pairId'])),_0x46be3--;}}}return _0x766037['filter'](_0x446e0e=>!_0x446e0e['isIncorrect']);}['_removeUnsupportedChanges'](_0x4a7977){const _0x3c9f8f=this['editor']['model']['schema'];for(let _0x15729b=0x0;_0x15729b<_0x4a7977['length'];_0x15729b++){if(!(_0x4a7977[_0x15729b]['isAdded']||_0x4a7977[_0x15729b]['isAddSuggestion']||_0x4a7977[_0x15729b]['isRemoved']||_0x4a7977[_0x15729b]['isRemoveSuggestion']))continue;if(0x0==_0x4a7977[_0x15729b]['distance'])continue;const _0x2d5159=_0x4a7977[_0x15729b]['item'];_0x3c9f8f['isBlock'](_0x2d5159)||_0x3c9f8f['isLimit'](_0x2d5159)||(_0x4a7977[_0x15729b]['isAdded']&&delete _0x4a7977[_0x15729b]['isAdded'],_0x4a7977[_0x15729b]['isAddSuggestion']&&delete _0x4a7977[_0x15729b]['isAddSuggestion'],_0x4a7977[_0x15729b]['isRemoveSuggestion']&&delete _0x4a7977[_0x15729b]['isRemoveSuggestion'],_0x4a7977[_0x15729b]['isRemoved']&&(_0x4a7977[_0x15729b]['isIncorrect']=!0x0));}return _0x4a7977['filter'](_0x36ce88=>!_0x36ce88['isIncorrect']);}['_makeModelFromTape'](_0xf28d43,_0x5a90f8,_0x5b92d0){const _0x1a5936=new gt(),_0x3409c6=[],_0x1aa263=new Map(),_0x20292c=this['editor']['model'],_0x2db0c=_0x20292c['schema'],_0x42049a=[_0x1a5936],_0x103dc3={},_0x49afd6={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x455b06=null;const _0x580383=[0x0];for(let _0x1b72d1=0x0;_0x1b72d1<_0xf28d43['length'];_0x1b72d1++)if('elementStart'===_0xf28d43[_0x1b72d1]['type']){_0xf28d43[_0x1b72d1]['previousPosition']=_0x20292c['createPositionFromPath'](_0x1a5936,_0x580383);const _0x186182=new ut(_0xf28d43[_0x1b72d1]['item']['name'],_0xf28d43[_0x1b72d1]['item']['getAttributes']());_0x42049a[0x0]['_appendChild'](_0x186182),_0x580383['push'](0x0),_0x42049a['unshift'](_0x186182),_0xf28d43[_0x1b72d1]['nextPosition']=_0x20292c['createPositionFromPath'](_0x1a5936,_0x580383);}else'elementEnd'===_0xf28d43[_0x1b72d1]['type']?(_0x42049a['shift'](),_0xf28d43[_0x1b72d1]['previousPosition']=_0x20292c['createPositionFromPath'](_0x1a5936,_0x580383),_0x580383['pop'](),_0x580383[_0x580383['length']-0x1]++,_0xf28d43[_0x1b72d1]['nextPosition']=_0x20292c['createPositionFromPath'](_0x1a5936,_0x580383)):(_0xf28d43[_0x1b72d1]['previousPosition']=_0x20292c['createPositionFromPath'](_0x1a5936,_0x580383),_0x455b06?_0x455b06['_data']+=_0xf28d43[_0x1b72d1]['item']['data']:_0x455b06=new mt(_0xf28d43[_0x1b72d1]['item']['data'],_0xf28d43[_0x1b72d1]['item']['getAttributes']()),_0xf28d43[_0x1b72d1+0x1]&&'text'===_0xf28d43[_0x1b72d1+0x1]['type']&&_0x21cf9a(_0x455b06,_0xf28d43[_0x1b72d1+0x1]['item'])||(_0x42049a[0x0]['_appendChild'](_0x455b06),_0x455b06=null),_0x580383[_0x580383['length']-0x1]+=_0xf28d43[_0x1b72d1]['item']['offsetSize'],_0xf28d43[_0x1b72d1]['nextPosition']=_0x20292c['createPositionFromPath'](_0x1a5936,_0x580383));for(let _0x1a140a=0x0;_0x1a140a<_0xf28d43['length'];_0x1a140a++){const _0x5b84af=_0xf28d43[_0x1a140a]['previousPosition'],_0x3b29e0=_0xf28d43[_0x1a140a]['nextPosition'];for(const _0x10696f of _0xf28d43[_0x1a140a]['markersStart'])_0x1aa263['set'](_0x10696f,{'start':_0x5b84af,'end':null});_0x409a10('isRemoveSuggestion',_0x1a140a,_0x5b84af,_0x3b29e0),_0x409a10('isAddSuggestion',_0x1a140a,_0x5b84af,_0x3b29e0),_0x409a10('isRemoved',_0x1a140a,_0x5b84af,_0x3b29e0),_0x409a10('isAdded',_0x1a140a,_0x5b84af,_0x3b29e0);for(const _0x1d7622 of _0xf28d43[_0x1a140a]['markersEnd']){const _0x1ded04=_0x1aa263['get'](_0x1d7622);_0x1ded04?_0x1ded04['end']=_0x3b29e0:_0x1aa263['set'](_0x1d7622,{'start':_0x3b29e0,'end':_0x3b29e0});}}for(const [_0xed8574,_0xf5038]of _0x1aa263){const _0x46a5b9=this['editor']['model']['createRange'](_0xf5038['start'],_0xf5038['end']);_0x1a5936['markers']['set'](_0xed8574,_0x46a5b9);}return _0x3409c6['sort']((_0x1c5bb9,_0x175618)=>{const _0x1757f4=_0x1a5936['markers']['get']('revision:'+_0x1c5bb9['id']),_0x16f28a=_0x1a5936['markers']['get']('revision:'+_0x175618['id']);return _0x1757f4['start']['isBefore'](_0x16f28a['start'])?-0x1:_0x1757f4['start']['isAfter'](_0x16f28a['start'])?0x1:_0x1757f4['end']['isBefore'](_0x16f28a['end'])?-0x1:_0x1757f4['end']['isAfter'](_0x16f28a['end'])?0x1:'add'===_0x1c5bb9['type']?-0x1:0x1;}),{'root':_0x1a5936,'changes':_0x3409c6};function _0x409a10(_0x5a36e7,_0x4657e4,_0x5a0071,_0x180c6d){const _0x29dc61=!!_0xf28d43[_0x4657e4][_0x5a36e7],_0x5566bd=_0x29dc61?_0xf28d43[_0x4657e4][_0x5a36e7]['userId']:null,_0x2f78d8=_0x4657e4===_0xf28d43['length']-0x1,_0x526ec0=_0x49afd6[_0x5a36e7][0x0],_0x50af33=_0x2db0c['isObject'](_0xf28d43[_0x4657e4]['item']);!_0x103dc3[_0x5a36e7]&&_0x29dc61?_0x103dc3[_0x5a36e7]={'start':_0x5a0071,'tapeItem':_0xf28d43[_0x4657e4],'userId':_0x5566bd,'type':_0x5a36e7}:_0x103dc3[_0x5a36e7]&&!_0x29dc61?(_0x103dc3[_0x5a36e7]['end']=_0x5a0071,_0x219c3e(_0x103dc3[_0x5a36e7]),_0x103dc3[_0x5a36e7]=null):_0x103dc3[_0x5a36e7]&&_0x29dc61&&_0x103dc3[_0x5a36e7]['userId']!==_0x5566bd&&(_0x103dc3[_0x5a36e7]['end']=_0x5a0071,_0x526ec0&&_0x526ec0['userId']===_0x103dc3[_0x5a36e7]['userId']||_0x219c3e(_0x103dc3[_0x5a36e7]),_0x103dc3[_0x5a36e7]={'start':_0x5a0071,'tapeItem':_0xf28d43[_0x4657e4],'userId':_0x5566bd,'type':_0x5a36e7}),_0x103dc3[_0x5a36e7]&&_0x50af33&&('elementStart'!==_0xf28d43[_0x4657e4]['type']||_0x526ec0&&_0x526ec0['userId']===_0x5566bd||_0x49afd6[_0x5a36e7]['unshift']({'userId':_0x5566bd,'object':_0xf28d43[_0x4657e4]['item'],'change':_0x103dc3[_0x5a36e7]}),'elementEnd'===_0xf28d43[_0x4657e4]['type']&&_0x526ec0&&_0x526ec0['object']===_0xf28d43[_0x4657e4]['item']&&(_0x49afd6[_0x5a36e7]['shift'](),_0x103dc3[_0x5a36e7]=_0x526ec0['change'])),_0x103dc3[_0x5a36e7]&&_0x2f78d8&&(_0x103dc3[_0x5a36e7]['end']=_0x180c6d,_0x219c3e(_0x103dc3[_0x5a36e7]),_0x103dc3[_0x5a36e7]=null);}function _0x219c3e({start:_0x9c97a9,end:_0x2d9483,tapeItem:_0x5df7b4,userId:_0x18106c,type:_0x40c452}){const _0x5e22b5=_0x5df7b4['item'],_0x50667d=_0x20292c['schema']['isBlock'](_0x5e22b5)&&!_0x20292c['schema']['isLimit'](_0x5e22b5),_0x3368de=_0x9c97a9['nodeAfter']==_0x2d9483['parent']&&_0x2d9483['isAtStart'];if(_0x50667d&&_0x3368de)return;const _0x247a8d=_0x20292c['createRange'](_0x9c97a9,_0x2d9483),_0x40f7b6=_0x5a90f8['get'](_0x18106c),_0x1c1bdb=new r({'author':_0x40f7b6,'type':'isAdded'==_0x40c452||'isAddSuggestion'==_0x40c452?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x40c452||'isRemoveSuggestion'==_0x40c452},'createdAt':new Date(),'rootName':_0x5b92d0});_0x3409c6['push'](_0x1c1bdb),_0x1a5936['markers']['set']('revision:'+_0x1c1bdb['id'],_0x247a8d);}function _0x21cf9a(_0x2f0d82,_0x5dddbf){const _0x100476=_0x2f0d82['getAttributes'](),_0x1875bb=_0x5dddbf['getAttributes']();for(const _0x5f59da of _0x100476){if(_0x5f59da[0x1]!==_0x5dddbf['getAttribute'](_0x5f59da[0x0]))return!0x1;_0x1875bb['next']();}return _0x1875bb['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x3185a0=>{const _0x2c8096=_0x3185a0['markerName']['split'](':')[0x1],_0x159565=this['_getChangeFromId'](_0x2c8096);if(!_0x159565)return null;const _0x1a8afd='add'==_0x159565['type']?'insertion':'deletion',_0xd7bb5f=['ck-suggestion-marker','ck-suggestion-marker-'+_0x1a8afd];return _0x159565['data']['isSuggestion']&&_0xd7bb5f['push']('ck-suggestion-marker-'+_0x1a8afd+'-new'),this['activeChange']==_0x159565&&_0xd7bb5f['push']('ck-suggestion-marker--active'),{'classes':_0xd7bb5f,'attributes':{'data-change-id':_0x2c8096}};}}),this['editor']['conversion']['for']('upcast')['add'](_0xce38a8=>{_0xce38a8['on']('element:pre',(_0x10dc08,_0x1fc9c4,_0x32b62a)=>{const _0x2292fb=_0x1fc9c4['viewItem']['getChild'](0x0);if(!_0x2292fb||!_0x2292fb['is']('element','code'))return;if(!_0x32b62a['consumable']['consume'](_0x2292fb,{'attributes':['vid_start','vid_end']}))return;const _0x1ed86e=_0x1fc9c4['modelRange']['start']['nodeAfter'];_0x32b62a['writer']['setAttribute']('vid_start',_0x2292fb['getAttribute']('vid_start'),_0x1ed86e),_0x32b62a['writer']['setAttribute']('vid_end',_0x2292fb['getAttribute']('vid_end'),_0x1ed86e);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x10292b=>{_0x10292b['on']('element',(_0x23598f,_0x597616,_0x1c6b17)=>{if(!_0x1c6b17['consumable']['consume'](_0x597616['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x597616['modelRange']['isCollapsed'])return;const _0x31a7a6=_0x597616['modelRange']['start']['nodeAfter'];_0x31a7a6['hasAttribute']('vid_start')||_0x31a7a6['hasAttribute']('vid')||(_0x1c6b17['writer']['setAttribute']('vid_start',_0x597616['viewItem']['getAttribute']('vid_start'),_0x31a7a6),_0x1c6b17['writer']['setAttribute']('vid_end',_0x597616['viewItem']['getAttribute']('vid_end'),_0x31a7a6));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x58b3aa=>_0x58b3aa['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x341ed0,[,_0x51871d])=>{['vid_start','vid_end','vid']['includes'](_0x51871d)&&(_0x341ed0['return']=!0x0,_0x341ed0['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x54f6ca=>{_0x54f6ca['on']('attribute:vid',(_0xdc568b,_0x2ee0ff,_0x4c6b22)=>{if('\x20'!=_0x2ee0ff['item']['data']||_0x2ee0ff['item']['parent']['maxOffset']>0x1)return;if(!_0x4c6b22['consumable']['consume'](_0x2ee0ff['item'],_0xdc568b['name']))return;const _0x3d580b=_0x4c6b22['writer'],_0x341b51=_0x4c6b22['mapper']['toViewRange'](_0x2ee0ff['range']);_0x3d580b['wrap'](_0x341b51,_0x3d580b['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x34955d){const _0x1e746b=_0x34955d['plugins']['get']('RevisionViewer');return(_0x30db15,_0x215830,_0x2653df)=>{const _0x28c937=_0x215830['markerName']['split'](':')[0x1],_0x42d675=_0x1e746b['_getChangeFromId'](_0x28c937);if(!_0x42d675)return null;const _0x17f98b='add'==_0x42d675['type']?'split':'merge';if(!_0x2653df['consumable']['test'](_0x215830['markerRange'],_0x30db15['name']))return;const _0x3093ac=_0x215830['markerRange']['getWalker'](),_0x5e4efb=_0x215830['markerRange']['start'],_0x51879a=_0x34955d['model']['schema'];let _0x76ea30=null,_0x1dc841=null,_0x14f66f=!0x1,_0x26a702=!0x1;for(const _0xb11f7c of _0x3093ac){const _0x3583e4=_0xb11f7c['item'];_0x14f66f=_0x14f66f||_0x51879a['isContent'](_0x3583e4);const _0x54372b=_0x2653df['mapper']['toViewElement'](_0x3583e4);if(_0x54372b&&_0x54372b['getCustomProperty']('addHighlight'))return;'elementEnd'==_0xb11f7c['type']&&(_0x51879a['isBlock'](_0x3583e4)&&!_0x51879a['isLimit'](_0x3583e4)&&(_0x3583e4['nextSibling']||_0x5e4efb['isAtEnd']?_0x76ea30&&_0x76ea30['parent']==_0x3583e4||(_0x76ea30=_0x3583e4,_0x2ddffa(_0xb11f7c['previousPosition']),_0x26a702=!0x0):_0x1dc841=_0x1dc841||_0xb11f7c['previousPosition']));}function _0x2ddffa(_0x191907){const _0x5a3518=_0x2653df['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x17f98b}),_0x5129af=_0x2653df['mapper']['toViewPosition'](_0x191907);_0x42d675['data']['isSuggestion']&&_0x2653df['writer']['addClass']('ck-suggestion-marker-'+_0x17f98b+'-new',_0x5a3518),_0x1e746b['activeChange']==_0x42d675&&_0x2653df['writer']['addClass']('ck-suggestion-marker--active',_0x5a3518),_0x2653df['writer']['insert'](_0x5129af,_0x5a3518),_0x2653df['mapper']['bindElementToMarker'](_0x5a3518,_0x215830['markerName']);}_0x14f66f||_0x26a702||!_0x1dc841||_0x2ddffa(_0x1dc841);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x7e8334,_0x2bfc25,_0x34be73)=>{const _0x4b7367=_0x34be73['mapper']['markerNameToElements'](_0x2bfc25['markerName']);if(_0x4b7367){for(const _0x379ccf of _0x4b7367)(_0x379ccf['hasClass']('ck-suggestion-marker-split')||_0x379ccf['hasClass']('ck-suggestion-marker-merge'))&&(_0x34be73['mapper']['unbindElementFromMarkerName'](_0x379ccf,_0x2bfc25['markerName']),_0x34be73['writer']['remove'](_0x379ccf));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x1cc976,_0x72e1a1,_0xf7d4ce)=>{const _0x3e6364=_0x72e1a1['markerName']['split'](':')[0x1],_0xe750f9=this['_getChangeFromId'](_0x3e6364);if(!_0xe750f9)return null;const _0x3c3e5c='add'==_0xe750f9['type']?'split':'merge';if(_0xf7d4ce['consumable']['test'](_0x72e1a1['markerRange'],_0x1cc976['name']))for(const _0x26a69b of _0x72e1a1['markerRange']['getItems']()){if(!_0x26a69b['is']('element','softBreak'))continue;const _0x2a82de=_0xf7d4ce['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x3c3e5c}),_0x247477=_0xf7d4ce['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x26a69b));_0xe750f9['data']['isSuggestion']&&_0xf7d4ce['writer']['addClass']('ck-suggestion-marker-'+_0x3c3e5c+'-new',_0x2a82de),this['activeChange']==_0xe750f9&&_0xf7d4ce['writer']['addClass']('ck-suggestion-marker--active',_0x2a82de),_0xf7d4ce['writer']['insert'](_0x247477,_0x2a82de),_0xf7d4ce['mapper']['bindElementToMarker'](_0x2a82de,_0x72e1a1['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0xdecf3e=>{for(const _0x51be46 of this['editor']['model']['document']['getRootNames']()){const _0x3e23cb=this['editor']['model']['document']['getRoot'](_0x51be46),_0xf81354=this['editor']['editing']['view']['document']['getRoot'](_0x51be46);if(_0xf81354){const _0x2a743f=_0x3e23cb['getAttribute']('revisionHistoryAttachChange');if(_0xdecf3e['removeAttribute']('data-change-id',_0xf81354),_0xdecf3e['removeClass']('ck-revision-history-root-add',_0xf81354),_0xdecf3e['removeClass']('ck-revision-history-root-remove',_0xf81354),_0xdecf3e['removeClass']('ck-revision-history-root--active',_0xf81354),_0x2a743f){const _0xbc6c5d=this['_getChangeFromId'](_0x2a743f);if(!_0xbc6c5d)return null;_0xdecf3e['setAttribute']('data-change-id',_0x2a743f,_0xf81354),_0xdecf3e['addClass']('ck-revision-history-root-'+_0xbc6c5d['type'],_0xf81354),this['activeChange']==_0xbc6c5d&&_0xdecf3e['addClass']('ck-revision-history-root--active',_0xf81354);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x3f5843=>'revision-comment:'+_0x3f5843,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x136c35=>'revision-suggestion:'+_0x136c35,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x3211ce=>({'name':'suggestion:'+_0x3211ce,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x4da4ba=>{const _0x4ce358=_0x4da4ba['markerName']['split'](':')[0x1];return'insertion'!=_0x4ce358&&'deletion'!=_0x4ce358?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x4ce358]};}}),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',(_0x17ef7c,_0x3e2e9b,_0x5f0058)=>{const _0x213161=_0x5f0058['mapper']['markerNameToElements'](_0x3e2e9b['markerName']);if(_0x213161){for(const _0x1d6cf4 of _0x213161)_0x1d6cf4['is']('uiElement')&&(_0x5f0058['mapper']['unbindElementFromMarkerName'](_0x1d6cf4,_0x3e2e9b['markerName']),_0x5f0058['writer']['remove'](_0x1d6cf4));}},{'priority':'high'});}['_getChangeFromId'](_0x573feb){return this['_changeIdToChange']['get'](_0x573feb);}['_getViewForChange'](_0x482185){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new Q(this['editor']['locale'],_0x482185),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x320211,_0x13e0c4,_0x2377fb,_0x1fd7a8)=>{_0x1fd7a8&&this['_balloon']['remove'](_0x1fd7a8),_0x2377fb&&(this['_balloon']['add']({'view':_0x2377fb,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x56fed3=this['editor']['editing'],_0xdf2129=this['_getChangeFromId'](_0x2377fb['changeId']);let _0xf8155e;if(_0xdf2129['data']['isOnRoot']){const _0x4f5e4e=_0x56fed3['view']['getDomRoot'](_0xdf2129['rootName']);_0xf8155e=Array['from'](_0x4f5e4e['getClientRects']());}else{const _0xd21b3d=this['editor']['model']['markers']['get']('revision:'+_0x2377fb['changeId']);_0xf8155e=Array['from'](_0x56fed3['mapper']['markerNameToElements'](_0xd21b3d['name']))['map'](_0x46a548=>_0x56fed3['view']['domConverter']['mapViewToDom'](_0x46a548))['map'](_0x34d874=>Array['from'](_0x34d874['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0xf8155e[0x0];return _0xf8155e['find'](_0x2f3e9d=>_0x2f3e9d['top']-0x3<=this['_activeViewTarget']['y']&&_0x2f3e9d['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x2f3e9d['left']-0x3<=this['_activeViewTarget']['x']&&_0x2f3e9d['right']+0x3>=this['_activeViewTarget']['x'])||_0xf8155e[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x11b115,_0x123df4,_0x664aed,_0x38dd72)=>{this['activeView']=_0x664aed?this['_getViewForChange'](_0x664aed):null,this['editor']['model']['change'](()=>{const _0x19e2b3=this['editor']['editing'];_0x38dd72&&(_0x38dd72['data']['isOnRoot']?_0x19e2b3['view']['change'](_0x5aff83=>{_0x5aff83['removeClass']('ck-revision-history-root--active',_0x19e2b3['view']['document']['getRoot'](_0x38dd72['rootName']));}):_0x19e2b3['reconvertMarker']('revision:'+_0x38dd72['id'])),_0x664aed&&(_0x664aed['data']['isOnRoot']?_0x19e2b3['view']['change'](_0x323ceb=>{_0x323ceb['addClass']('ck-revision-history-root--active',_0x19e2b3['view']['document']['getRoot'](_0x664aed['rootName']));}):_0x19e2b3['reconvertMarker']('revision:'+_0x664aed['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x1d3c9f,_0x3c763c)=>{if(this['activeChange'])return;const _0xc4e6ab=this['_findChangeIdFromDomTarget'](_0x3c763c['target']),_0x30fdae=this['_changeIdToChange']['get'](_0xc4e6ab);_0x30fdae?(this['_activeViewTarget']={'x':_0x3c763c['domEvent']['x'],'y':_0x3c763c['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x30fdae)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x41eb74,_0x273584)=>{const _0x27074c=this['_findChangeIdFromDomTarget'](_0x273584['target']),_0x4d8883=this['_changeIdToChange']['get'](_0x27074c);_0x4d8883?(this['_activeViewTarget']={'x':_0x273584['domEvent']['x'],'y':_0x273584['domEvent']['y']},_0x4d8883===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x4d8883):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x1c5146){do{const _0xf6b1c1=_0x1c5146['getAttribute']('data-change-id');if(_0xf6b1c1)return _0xf6b1c1;_0x1c5146=_0x1c5146['parent'];}while(_0x1c5146);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x4e0adb=>{for(const _0x568719 of this['editor']['model']['markers'])_0x4e0adb['removeMarker'](_0x568719);});}}function X(_0x11004e,_0x27f685){return(_0x48d54a,_0x2ad1a6,_0xfa1d19)=>{if(!_0xfa1d19['consumable']['test'](_0x2ad1a6['markerRange'],_0x48d54a['name']))return;const _0x4c9061=_0x2ad1a6['markerRange']['getWalker'](),_0x48b2bb=_0x2ad1a6['markerRange']['start'],_0x571fdd=_0x11004e['model']['schema'];let _0x23fcdf=null,_0x513277=null,_0x3a2489=!0x1,_0xb9b689=!0x1;for(const _0x37c049 of _0x4c9061){const _0xfa1cfc=_0x37c049['item'];_0x3a2489=_0x3a2489||_0x571fdd['isContent'](_0xfa1cfc);const _0x2a0a3a=_0xfa1d19['mapper']['toViewElement'](_0xfa1cfc);if(_0x2a0a3a&&_0x2a0a3a['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x37c049['type']&&(_0x571fdd['isBlock'](_0xfa1cfc)&&!_0x571fdd['isLimit'](_0xfa1cfc)&&(_0xfa1cfc['nextSibling']||_0x48b2bb['isAtEnd']?_0x23fcdf&&_0x23fcdf['parent']==_0xfa1cfc||(_0x23fcdf=_0xfa1cfc,_0x268e1a(_0x37c049['previousPosition']),_0xb9b689=!0x0):_0x513277=_0x513277||_0x37c049['previousPosition']));}function _0x268e1a(_0x30d670){const _0x1602c2=_0xfa1d19['mapper']['toViewPosition'](_0x30d670),_0x518aff=_0xfa1d19['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x27f685});_0xfa1d19['writer']['insert'](_0x1602c2,_0x518aff),_0xfa1d19['mapper']['bindElementToMarker'](_0x518aff,_0x2ad1a6['markerName']);}_0x3a2489||_0xb9b689||!_0x513277||_0x268e1a(_0x513277);};}class wt extends _0x1a5677{constructor(_0x44298b){super(_0x44298b);const _0xd5a516=_0x44298b['plugins']['get'](m);this['affectsData']=!0x1,this['listenTo'](_0xd5a516,'change:isReady',()=>this['refresh']()),this['listenTo'](_0xd5a516,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x52bd82=this['editor'],_0x217b7d=_0x52bd82['plugins']['get'](m),_0x16eea0=_0x217b7d['isReady']?_0x217b7d['diff']['newRevisionId']:null;_0x52bd82['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x16eea0);}['refresh'](){const {isReady:_0x4435b0,isEnabled:_0x54e12e,repository:_0x11de72,diff:_0xde7eaf}=this['editor']['plugins']['get'](m),_0x39e788=_0xde7eaf&&_0x11de72['getLaterVisibleRevision'](_0xde7eaf['newRevisionId']);this['isEnabled']=_0x4435b0&&_0x54e12e&&Boolean(_0x39e788);}}class pt extends _0x1a5677{['_step'];constructor(_0x111665,{direction:_0x33d9a7}){super(_0x111665);const _0x20a243=_0x111665['plugins']['get'](m);this['affectsData']=!0x1,this['_step']='forward'===_0x33d9a7?0x1:-0x1,this['listenTo'](_0x20a243,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x20a243,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x20a243,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x2c5994=this['editor'],_0x43b676=_0x2c5994['plugins']['get'](m),{isNavigationMode:_0x16196d,currentChangeNumber:_0x3e0c0f}=_0x43b676;let _0x24f031;if(_0x43b676['activeChange']=_0x16196d?_0x43b676['diff']['changes']['get'](_0x3e0c0f+this['_step']):_0x43b676['diff']['changes']['first'],_0x43b676['activeChange']['data']['isOnRoot'])_0x24f031=_0x2c5994['editing']['view']['getDomRoot'](_0x43b676['activeChange']['rootName']);else{const _0x1b35cb=_0x2c5994['model']['markers']['get']('revision:'+_0x43b676['activeChange']['id']);_0x24f031=_0x5bd190(_0x2c5994['editing'],_0x1b35cb);}_0x314267({'target':_0x24f031,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0xf98395,currentChangeNumber:_0x52eeab,numberOfChanges:_0x3706bb,isReady:_0x362929,isEnabled:_0x24683f}=this['editor']['plugins']['get'](m);this['isEnabled']=!!(_0x24683f&&_0x362929&&_0x3706bb)&&(!_0xf98395||(0x1===this['_step']?_0x52eeab<_0x3706bb-0x1:_0x52eeab>0x0));}}class _i extends _0x2019f7{constructor(_0x139914){super(_0x139914);const _0x13e4cf=this['bindTemplate'],_0x282a01=new _0xca59d9(_0x139914),_0x4d8eea=new _0xca59d9(_0x139914);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',(_0x41d51c,_0x4efb84)=>_0x41d51c&&_0x4efb84>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x29110e,_0xe3d9a5,_0x398327,_0x4a1bcd)=>{if(!_0x29110e)return g(_0x139914,'Loading...');if(!_0x398327)return g(_0x139914,'No\x20changes');const _0x1bc6fc=g(_0x139914,'NUMBER_OF_CHANGES',_0x398327);return _0x4a1bcd?g(_0x139914,'X_OF_Y_CHANGES',[_0xe3d9a5+0x1,_0x398327]):_0x1bc6fc;}),_0x282a01['set']({'label':g(_0x139914,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x3d5cf8}),_0x4d8eea['set']({'label':g(_0x139914,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x3ea13e}),_0x282a01['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x4d8eea['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x282a01['on']('execute',()=>this['fire']('execute','backward')),_0x4d8eea['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',_0x13e4cf['if']('_isStatusLabelVisible','ck-hidden',_0xf68abe=>!_0xf68abe)]},'children':[{'text':_0x13e4cf['to']('isNavigationMode',_0x43efad=>_0x43efad?g(_0x139914,'EDIT_X_OF_Y_REVISIONS')+':\x20':g(_0x139914,'Total')+':\x20')}]},{'text':_0x13e4cf['to']('_statusText')}]},new _0x1504bd(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x282a01,_0x4d8eea]}]});}}const ce='ck-editor__editable__loading-overlay';class le extends _0x2a1981{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0xd562f6=this['editor']['editing']['view'];_0xd562f6['change'](_0x4f6afc=>{for(const _0x4d5206 of _0xd562f6['document']['roots'])_0x4f6afc['addClass'](ce,_0x4d5206);});}['hide'](){const _0xbdfee3=this['editor']['editing']['view'];_0xbdfee3['change'](_0x552033=>{for(const _0x105d3a of _0xbdfee3['document']['roots'])_0x552033['removeClass'](ce,_0x105d3a);});}}class R extends _0x2a1981{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[m,le];}['init'](){const _0xc6916e=this['editor'],_0x4bce3d=_0xc6916e['plugins']['get'](m),_0x1bf76e=_0xc6916e['plugins']['get'](le);_0xc6916e['ui']['componentFactory']['add']('exitToEditing',_0x399b72=>{const _0x21a11d=new _0xca59d9(_0x399b72);return _0x21a11d['set']({'label':g(_0x399b72,'Back\x20to\x20editing'),'icon':_0x4113d1,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x21a11d,'execute',()=>{_0xc6916e['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x21a11d;}),_0xc6916e['ui']['componentFactory']['add']('restoreRevision',_0x349f49=>{const _0x416d1b=new _0xca59d9(_0x349f49);return _0x416d1b['set']({'label':g(_0x349f49,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x416d1b['bind']('isEnabled')['to'](_0xc6916e['commands']['get']('restoreRevision')),this['listenTo'](_0x416d1b,'execute',()=>_0xc6916e['execute']('restoreRevision')),_0x416d1b;}),_0xc6916e['ui']['componentFactory']['add']('changesNavigation',_0x262f9c=>{const _0x388aee=new _i(_0x262f9c),_0x244a70=_0xc6916e['commands']['get']('showPreviousChange'),_0x85b41f=_0xc6916e['commands']['get']('showNextChange');return _0x388aee['bind']('isBackwardNavigationEnabled')['to'](_0x244a70,'isEnabled'),_0x388aee['bind']('isForwardNavigationEnabled')['to'](_0x85b41f,'isEnabled'),_0x388aee['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x4bce3d),this['listenTo'](_0x388aee,'execute',(_0xf64406,_0x2a8a30)=>{_0xc6916e['execute']('forward'===_0x2a8a30?'showNextChange':'showPreviousChange');}),_0x388aee;}),_0x1bf76e['show'](),_0x4bce3d['on']('change:isReady',(_0x46dc89,_0x96a126,_0x3c40b2)=>{_0x3c40b2?_0x1bf76e['hide']():_0x1bf76e['show']();});}}class lt extends nt{['_resizeObserver']=null;constructor(_0x2fae9e,_0x2b1429){super(_0x2fae9e,_0x2b1429);const _0x147a7b=this['bindTemplate'];this['set']({'label':g(_0x2fae9e,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=g(_0x2fae9e,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x147a7b['to']('_tooltipString'),'data-cke-tooltip-position':'s','data-cke-tooltip-class':'ck-tooltip_multi-line'}});}['render'](){super['render'](),this['_resizeObserver']=new at(this['fieldView']['element'],()=>this['_updateTooltipText']()),this['listenTo'](this['fieldView'],'input',()=>this['_updateTooltipText']());}['destroy'](){super['destroy'](),this['_resizeObserver']&&this['_resizeObserver']['destroy']();}['_updateTooltipText'](){const _0x477ae0=this['fieldView']['element'];this['_tooltipString']=_0x477ae0['scrollWidth']>_0x477ae0['clientWidth']&&_0x477ae0['value']||'';}}class oi extends _0x2019f7{constructor(_0x42e01f,_0x3e24be,_0x57db2d){super(_0x42e01f);const _0x1474f0=new _0x482110();_0x1474f0['set']({'content':_0x4e5b48,'viewBox':'0\x200\x2011\x2010'});const _0xf09df7=['ck','ck-revision-history-sidebar__revision-author'];_0x57db2d&&_0xf09df7['push']('ck-revision-history-sidebar__revision-author_creator');const _0x3dc08b=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':g(_0x42e01f,_0x57db2d?'Revision\x20creator':'Revision\x20author')},'children':[_0x1474f0,_0x3e24be['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0xf09df7},'children':_0x3dc08b});}}function ni(_0x3733ae,_0x40de5f){const _0xdc14da=_0x3733ae['bindTemplate'],_0x216f91=_0x3733ae['locale'],_0x4d3ebc=_0x43dd89(_0x216f91);_0x4d3ebc['panelPosition']='sw';const _0x5ea6a2=function(_0xf29cd4,_0x56a6bf){const _0x4fa1a1=function(_0x190816,_0x371011){const _0x23a76f=_0x190816['locale'],_0xf3b6c={'Compare\x20against\x20selected':g(_0x23a76f,'Compare\x20against\x20selected'),'Name\x20this\x20revision':g(_0x23a76f,'Name\x20this\x20revision'),'Restore\x20this\x20revision':g(_0x23a76f,'Restore\x20this\x20revision')};return _0x371011['map'](_0x434fbb=>{const _0x5b8073=_0xf3b6c[_0x434fbb['name']];return _0x5b8073&&_0x5b8073!==_0x434fbb['name']&&(_0x434fbb['name']=_0x5b8073),_0x434fbb;});}(_0xf29cd4,_0x56a6bf),_0x42e248=new _0x1dfd6a();for(const _0x528c2d of _0x4fa1a1){const _0x549165={'type':'button','model':new to({'label':_0x528c2d['name'],'class':_0x528c2d['class'],'withText':!0x0,'role':'menuitem','_action':_0x528c2d['action']})};_0x549165['model']['bind']('isEnabled')['to'](_0xf29cd4,'isActionsDropdownOpen',_0x195996=>'function'!=typeof _0x528c2d['isEnabled']||(!_0x195996||_0x528c2d['isEnabled'](_0xf29cd4))),_0x42e248['add'](_0x549165);}return _0x42e248;}(_0x3733ae,_0x40de5f);return _0x3733ae['bind']('isActionsDropdownOpen')['to'](_0x4d3ebc,'isOpen'),_0x4d3ebc['buttonView']['set']({'label':g(_0x216f91,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x43e497}),_0x4d3ebc['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0xdc14da['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0xdc14da['to'](_0x2d3e8f=>_0x2d3e8f['stopPropagation']())}}),_0x4d3ebc['on']('execute',_0x6efbdb=>{_0x3733ae['isReady']&&'function'==typeof _0x6efbdb['source']['_action']&&_0x6efbdb['source']['_action'](_0x3733ae);}),_0x1dd007(_0x4d3ebc,_0x5ea6a2,{'role':'menu'}),_0x4d3ebc['listenTo'](_0x3733ae,'change:isActionsDropdownOpen',(_0x56da5e,_0x327320,_0x2ea7b5)=>{if(_0x2ea7b5)for(const _0x57dfcc of _0x4d3ebc['listView']['items']){const _0x207dd1=_0x57dfcc['children']['first'],_0x4ebdcd=_0x40de5f['find'](_0x7b5ab2=>_0x7b5ab2['action']===_0x207dd1['_action'])['isVisible'];_0x57dfcc['isVisible']=void 0x0===_0x4ebdcd||_0x4ebdcd(_0x3733ae);}}),_0x4d3ebc;}class ai extends/* #__PURE__ -- @preserve */
26
- _0x1a2d37(_0x2019f7){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x470083,_0x238c07,_0x17c20a,_0x21ed52){super(_0x470083);const _0x2b8182=this['bindTemplate'],_0x1ef854=function(_0x19f52e,_0x2f2eb1){const _0x427d42=Array['from'](_0x2f2eb1['authors'])['filter'](_0x210b9e=>_0x210b9e!=_0x2f2eb1['creator']);return _0x2f2eb1['creator']&&_0x427d42['unshift'](_0x2f2eb1['creator']),_0x427d42['map'](_0x485823=>new oi(_0x19f52e,_0x485823,_0x485823==_0x2f2eb1['creator']));}(_0x470083,_0x238c07);this['id']=_0x238c07['id'],this['_revision']=_0x238c07,this['_requireRevisionName']=_0x21ed52,this['bind']('name','createdAt')['to'](_0x238c07),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x217e46=>{return _0x237fb1=_0x470083['uiLanguage'],(_0x54f6ae=_0x217e46)['toLocaleDateString'](_0x237fb1,{'month':'long','day':'numeric'})+',\x20'+_0x54f6ae['toLocaleTimeString'](_0x237fb1,{'hour':'numeric','minute':'numeric'});var _0x237fb1,_0x54f6ae;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new lt(_0x470083,ti),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x349b7c=>_0x349b7c||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x334d52,_0x3747db)=>_0x334d52&&_0x3747db),this['revisionActionsView']=_0x17c20a&&_0x17c20a['length']?ni(this,_0x17c20a):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x2b8182['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x2b8182['if']('isEnabled','ck-disabled',_0x2ce3df=>!_0x2ce3df),_0x2b8182['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x2b8182['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x2b8182['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':_0x2b8182['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':_0x1ef854}]},this['revisionActionsView']],'on':{'click':_0x2b8182['to'](_0x43737d=>{_0x43737d['srcElement']['closest']('.ck-thread__remove-confirm')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x3124e8=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x3124e8,'change',()=>{this['_requireRevisionName']&&!_0x3124e8['value']||this['fire']('setName',{'id':this['id'],'name':_0x3124e8['value']}),_0x3124e8['value']||(_0x3124e8['value']=this['name']?this['name']:this['_createdAtFormatted']);});}['select'](){this['isSelected']=!0x0;}['deselect'](){this['isSelected']=!0x1;}['highlight'](){this['isHighlighted']=!0x0;}['unhighlight'](){this['isHighlighted']=!0x1;}}function vi(_0x9f969f,_0x7921e3){const _0x58ab99=_0x4311f8['fromJSDate'](_0x9f969f)['setLocale'](_0x7921e3),_0x5a4b69=_0x4311f8['local'](),_0x31e8fa=_0x5a4b69['minus']({'days':0x1})['startOf']('day');let _0x38c039,_0x59a8ef;return _0x58ab99['hasSame'](_0x5a4b69,'day')?(_0x38c039=_0x58ab99['startOf']('day')['toJSDate'](),_0x59a8ef=_0x58ab99['toRelativeCalendar']()):_0x58ab99['hasSame'](_0x31e8fa,'day')?(_0x38c039=_0x31e8fa['toJSDate'](),_0x59a8ef=_0x58ab99['toRelativeCalendar']()):_0x58ab99['hasSame'](_0x5a4b69,'week')?(_0x38c039=_0x58ab99['startOf']('week')['toJSDate'](),_0x59a8ef=_0x58ab99['weekdayLong']||''):_0x58ab99['hasSame'](_0x5a4b69,'year')?(_0x38c039=_0x58ab99['startOf']('month')['toJSDate'](),_0x59a8ef=_0x58ab99['monthLong']||''):(_0x38c039=_0x58ab99['startOf']('year')['toJSDate'](),_0x59a8ef=String(_0x58ab99['year'])),{'startDate':_0x38c039,'localizedPeriodName':_0x59a8ef};}class mi extends _0x2019f7{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x2c2235,_0x3fb568,_0x101428,_0x571a6c){super(_0x2c2235);const _0x52337a=vi(_0x3fb568,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x3fb568,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x101428,this['_requireRevisionName']=_0x571a6c,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':_0x52337a}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x1613c5){const _0x54edb2=new ai(this['locale'],_0x1613c5,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x54edb2);}['removeRevision'](_0x479b11){const _0x368e05=this['revisionViews']['find'](_0x61c94c=>_0x61c94c['id']===_0x479b11['id']);this['revisionViews']['remove'](_0x368e05);}}class as extends _0x2019f7{constructor(_0x1a5c9d){super(_0x1a5c9d);const _0x522e9f=new _0x482110();_0x522e9f['content']=_0x4d50e2,this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x522e9f,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[g(_0x1a5c9d,'Revision\x20history')]}]});}}class di extends _0x2019f7{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x214b01,_0x8ac6f6,_0xa657d,_0x1eb80d){super(_0x214b01);const _0x53919=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x8ac6f6,this['_revisionActions']=_0xa657d,this['_requireRevisionName']=_0x1eb80d,this['on']('select',(_0x5c5d83,_0x4164d2)=>{this['fire']('revisionSelected',_0x4164d2);}),this['on']('setName',(_0x17ad9a,_0x518a1a)=>{this['fire']('revisionSetName',_0x518a1a);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new as(_0x214b01),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x53919['if']('isEnabled','ck-disabled',_0x5ed45a=>!_0x5ed45a)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x230984 of this['_revisions'])this['_addRevision'](_0x230984);this['_revisions']['on']('add',(_0x410674,_0x42373f)=>{this['_addRevision'](_0x42373f);}),this['_revisions']['on']('remove',(_0x5c76fb,_0x58e0a4)=>{this['_removeRevision'](_0x58e0a4);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x1d4f84=>_0x1d4f84['revisionViews']['map'](_0x1b5143=>_0x1b5143))['flat']();}['selectRevision'](_0x451ba4){for(const _0x268bcf of this['revisionViews'])_0x451ba4&&_0x451ba4['id']===_0x268bcf['id']?_0x268bcf['select']():_0x268bcf['deselect']();}['highlightRevisions'](_0x33d308){for(const _0x26ade6 of this['revisionViews'])_0x33d308['some'](({id:_0x502132})=>_0x502132===_0x26ade6['id'])?_0x26ade6['highlight']():_0x26ade6['unhighlight']();}['_addRevision'](_0x17abcb){const _0x57957c=vi(_0x17abcb['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x7cb927=this['timePeriodViews']['get'](0x0);_0x7cb927&&_0x7cb927['startDate']['getTime']()===_0x57957c['getTime']()||(_0x7cb927=new mi(this['locale'],_0x57957c,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x7cb927)),_0x7cb927['addRevision'](_0x17abcb);}['_removeRevision'](_0xce8f6){const _0x257229=vi(_0xce8f6['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x257229)['removeRevision'](_0xce8f6);}['_getTimePeriodViewByStartDate'](_0x87e86){return this['timePeriodViews']['find'](_0x483aaa=>_0x483aaa['startDate']['getTime']()===_0x87e86['getTime']());}}class d extends _0x2a1981{['_revisionViewer'];['_revisionsRepository'];['_sidebarView'];static ['defaultRevisionActions']=/* #__PURE__ -- @preserve */
23
+ import{ObservableMixin as _0x59fa04,uid as _0x46489c,Collection as _0x204bd9,logWarning as _0x5975bf,FocusTracker as _0x2cbbc2,KeystrokeHandler as _0x498725,scrollViewportToShowTarget as _0x549517,ResizeObserver as at,ElementReplacer as ot,CKEditorError as _0x5e4045}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x503a70,set as _0x14b2f7,unset as _0x24213a,isEqual as _0x4f4ed8}from'es-toolkit/compat';import{Plugin as _0x310a6b,PendingActions as _0x26e452,Command as _0x300e49,ElementApiMixin as _0x5cd351,Editor as _0x4da541}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x49a6e3,getMarkerDomElement as _0x587168,ConfirmMixin as _0x3011d5,sanitizeEditorConfig as _0x56ae90}from'ckeditor5-collaboration/dist/index.js';import{ViewContainerElement as _0x13cd95,ViewAttributeElement as _0x447971,ViewEmptyElement as _0x2644d0,ViewRawElement as _0xe193c5,ViewUIElement as _0x5c325e,ViewDocumentFragment as _0x268e5c,ViewText as _0x1de2b4,ViewElement as _0x3a19da,Element as ut,Range as ft,Position as vt,DocumentFragment as gt,Text as mt}from'@ckeditor/ckeditor5-engine/dist/index.js';import{IconHistory as _0x4e40f2,IconChevronUp as _0x51bc46,IconChevronDown as _0x4ffe2c,IconUndo as _0x2ff47d,IconUser as _0x568aa7,IconThreeVerticalDots as _0x35640b}from'@ckeditor/ckeditor5-icons/dist/index.js';import{View as _0x328aa1,injectCssTransitionDisabler as ts,submitHandler as _0x48d35c,LabeledFieldView as nt,createLabeledInputText as ti,createDropdown as _0x49a6db,ListView as _0x40d04c,ListItemView as te,ButtonView as _0x4e381a,MenuBarMenuView as _0x3b7261,MenuBarMenuListView as _0x237439,MenuBarMenuListItemView as _0x31da87,MenuBarMenuListItemButtonView as _0x2a56a1,ContextualBalloon as _0x37c732,ToolbarSeparatorView as _0x586274,IconView as _0x458840,addListToDropdown as _0x250f1a,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 _0x2123bd}from'luxon';class h extends/* #__PURE__ -- @preserve */
24
+ _0x59fa04(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x1b71f0){super(),this['id']=_0x1b71f0['id']||_0x46489c(),this['creator']=_0x1b71f0['creator']||null,this['authors']=_0x1b71f0['authors']||[],this['diffData']=_0x1b71f0['diffData']||null,this['toVersion']=_0x1b71f0['toVersion']||0x0,this['fromVersion']=_0x1b71f0['fromVersion']||0x0,this['set']('name',_0x1b71f0['name']||''),this['set']('createdAt',_0x1b71f0['createdAt']||new Date()),this['set']('attributes',_0x1b71f0['attributes']||{});}['setName'](_0x4e25e0){this['_update']({'name':_0x4e25e0});}['setAttribute'](_0x1346e8,_0x1e5650){const _0x7782bc=_0x503a70(this['attributes']);_0x14b2f7(_0x7782bc,_0x1346e8,_0x1e5650),this['_update']({'attributes':_0x7782bc});}['removeAttribute'](_0x3870eb){const _0x381129=_0x503a70(this['attributes']);_0x24213a(_0x381129,_0x3870eb),this['_update']({'attributes':_0x381129});}['_update'](_0x2c88ab,_0x2b195a=!0x1){let _0x1629bb=!0x1;const _0x377180={'id':this['id']},_0x18fc46=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x2638c0 of _0x18fc46){const _0x43fe91=_0x2c88ab[_0x2638c0];void 0x0!==_0x43fe91&&_0x43fe91!==this[_0x2638c0]&&(this[_0x2638c0]=_0x43fe91,_0x377180[_0x2638c0]=_0x43fe91,_0x1629bb=!0x0);}_0x1629bb&&(_0x377180['authors']&&(_0x377180['authorsIds']=_0x377180['authors']['map'](_0x35a2ad=>_0x35a2ad['id']),delete _0x377180['authors']),this['fire']('_update',_0x377180,_0x2b195a));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0xb2c7d7=>_0xb2c7d7['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class I extends _0x310a6b{['_revisions'];static get['requires'](){return[_0x49a6e3];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x597987){super(_0x597987),this['_revisions']=new _0x204bd9();}['afterInit'](){!async function(_0x2b6c94){const _0x12b289=_0x492c85([0x56,0x6b,0x6c,0x47,0x64,0x48,0x46,0x6f,0x53,0x62,0x4f,0x69,0x6e,0x75,0x61,0x4c,0x52,0x36,0x72,0x58,0x5a,0x65,0x55,0x79,0x37,0x43,0x35,0x39,0x32,0x71,0x66,0x77,0x67,0x78,0x54,0x30,0x49,0x6d,0x74,0x7a,0x70,0x63,0x42,0x4a,0x4e,0x38,0x57,0x41,0x33,0x44,0x68,0x31,0x4d,0x73,0x76,0x6a,0x59,0x34,0x51,0x4b,0x45,0x50]),_0xd359e4=0xeb829,_0xbf5c24=0x35609901,_0x5636d8=0x3567fcd9^_0xbf5c24,_0x178c0e=window[_0x492c85([0x44,0x61,0x74,0x65])][_0x492c85([0x6e,0x6f,0x77])](),_0x1aa6ee=_0x2b6c94[_0x492c85([0x65,0x64,0x69,0x74,0x6f,0x72])],_0xe4c89b=new window[(_0x492c85([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x4dfd97=>{_0x1aa6ee[_0x492c85([0x6f,0x6e,0x63,0x65])](_0x492c85([0x72,0x65,0x61,0x64,0x79]),_0x4dfd97);}),_0x4eddb3={[_0x492c85([0x6b,0x74,0x79])]:_0x492c85([0x45,0x43]),[_0x492c85([0x75,0x73,0x65])]:_0x492c85([0x73,0x69,0x67]),[_0x492c85([0x63,0x72,0x76])]:_0x492c85([0x50,0x2d,0x32,0x35,0x36]),[_0x492c85([0x78])]:_0x492c85([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]),[_0x492c85([0x79])]:_0x492c85([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]),[_0x492c85([0x61,0x6c,0x67])]:_0x492c85([0x45,0x53,0x32,0x35,0x36])},_0x23acf7=_0x1aa6ee[_0x492c85([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x492c85([0x67,0x65,0x74])](_0x492c85([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x3e5ea3(){let _0x35775a,_0x52a4c6=null,_0x4db835=null;try{if(_0x23acf7==_0x492c85([0x47,0x50,0x4c]))return _0x492c85([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x35775a=_0x2eec82(),!_0x35775a)return _0x492c85([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x35775a[_0x492c85([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x4db835=_0x49fd73(_0x35775a[_0x492c85([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x35775a[_0x492c85([0x6a,0x74,0x69])])),await _0x4a1b88()?_0x14fa0d()?_0x86fadf()?_0x492c85([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x1d1b28()?(_0x35775a[_0x492c85([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x492c85([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x52a4c6=_0x301823(_0x492c85([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x35775a[_0x492c85([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x492c85([0x74,0x72,0x69,0x61,0x6c])&&(_0x52a4c6=_0x301823(_0x492c85([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x1cb86a()):_0x492c85([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x492c85([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x492c85([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch(_0x39f9e9){return _0x492c85([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x86fadf(){const _0x215e1f=[_0x492c85([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x492c85([0x74,0x72,0x69,0x61,0x6c])][_0x492c85([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x35775a[_0x492c85([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x178c0e/0x3e8:0xe10*_0x5636d8;return _0x35775a[_0x492c85([0x65,0x78,0x70])]<_0x215e1f;}function _0x14fa0d(){const _0x415429=_0x35775a[_0x492c85([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x415429)return!0x1;if(_0x415429[_0x492c85([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x492c85([0x2a])))return!0x0;if(_0x415429[_0x492c85([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x492c85([0x52,0x48])))return!0x0;if(_0x415429[_0x492c85([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x492c85([0x52,0x52,0x48]))){if(_0x18fef0())return!0x0;if(_0x35558a()||_0xb5f25c())return!0x0;}return!0x1;}function _0x1d1b28(){const _0x22366b=_0x35775a[_0x492c85([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x22366b||0x0==_0x22366b[_0x492c85([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x4bf595}=new URL(window[_0x492c85([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x22366b[_0x492c85([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4bf595))return!0x0;const _0xd4601=_0x4bf595[_0x492c85([0x73,0x70,0x6c,0x69,0x74])](_0x492c85([0x2e]));return _0x22366b[_0x492c85([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x56c53c=>_0x56c53c[_0x492c85([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x492c85([0x2a])))[_0x492c85([0x6d,0x61,0x70])](_0x54d209=>_0x54d209[_0x492c85([0x73,0x70,0x6c,0x69,0x74])](_0x492c85([0x2e])))[_0x492c85([0x73,0x6f,0x6d,0x65])](_0x25edc8=>_0xd4601[_0x492c85([0x65,0x76,0x65,0x72,0x79])]((_0x184360,_0x4a7492)=>_0x25edc8[_0x4a7492]===_0x184360||_0x25edc8[_0x4a7492]===_0x492c85([0x2a])));}function _0x1cb86a(){return _0x52a4c6&&_0x4db835?new window[(_0x492c85([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x4e997b,_0x14591c)=>{_0x52a4c6[_0x492c85([0x74,0x68,0x65,0x6e])](_0x4e997b,_0x14591c),_0x4db835[_0x492c85([0x74,0x68,0x65,0x6e])](_0x26883c=>{_0x26883c!=_0x492c85([0x56,0x61,0x6c,0x69,0x64])&&_0x4e997b(_0x26883c);},_0x14591c);}):_0x52a4c6||_0x4db835||_0x492c85([0x56,0x61,0x6c,0x69,0x64]);}}function _0x49fd73(_0x3178a0,_0x3fe16e){return new window[(_0x492c85([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x436aa4=>{if(_0x359da0())return _0x436aa4(_0x492c85([0x56,0x61,0x6c,0x69,0x64]));_0x21314a(),_0x1aa6ee[_0x492c85([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x492c85([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0xcb1cee=!0x1;const _0x157048=_0x46489c();function _0x473914(_0x41d7c9){return!!_0x41d7c9&&(typeof _0x41d7c9===_0x492c85([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x41d7c9===_0x492c85([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x41d7c9[_0x492c85([0x74,0x68,0x65,0x6e])]===_0x492c85([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x41d7c9[_0x492c85([0x63,0x61,0x74,0x63,0x68])]===_0x492c85([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x4fd33b(_0x3268a7){_0x5f4582(_0x3268a7)[_0x492c85([0x74,0x68,0x65,0x6e])](_0x162ef6=>{if(!_0x162ef6||_0x162ef6[_0x492c85([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x492c85([0x6f,0x6b]))return _0x492c85([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0xec71c4(_0x457c08(_0x157048+_0x3fe16e))!=_0x162ef6[_0x492c85([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x492c85([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x492c85([0x56,0x61,0x6c,0x69,0x64]);})[_0x492c85([0x74,0x68,0x65,0x6e])](_0x28ce20=>(_0x5a5cec(),_0x28ce20),()=>{const _0xac87a4=_0x168362();return null==_0xac87a4?(_0x5a5cec(),_0x492c85([0x56,0x61,0x6c,0x69,0x64])):_0x492c85(_0x178c0e-_0xac87a4>(0x116c1d01^_0xbf5c24)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x492c85([0x74,0x68,0x65,0x6e])](_0x436aa4)[_0x492c85([0x63,0x61,0x74,0x63,0x68])](()=>{_0x436aa4(_0x492c85([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x1185bf=0x35567781^_0xbf5c24;function _0x5a5cec(){const _0x4b512b=_0x492c85([0x6c,0x6c,0x63,0x74,0x2d])+_0xec71c4(_0x457c08(_0x3178a0)),_0x3cdb4a=_0x5577a5(_0xec71c4(window[_0x492c85([0x4d,0x61,0x74,0x68])][_0x492c85([0x63,0x65,0x69,0x6c])](_0x178c0e/_0x1185bf)));window[_0x492c85([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x492c85([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x4b512b,_0x3cdb4a);}function _0x168362(){const _0xb7c21e=_0x492c85([0x6c,0x6c,0x63,0x74,0x2d])+_0xec71c4(_0x457c08(_0x3178a0)),_0x4adeb3=window[_0x492c85([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x492c85([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0xb7c21e);return _0x4adeb3?window[_0x492c85([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x5577a5(_0x4adeb3),0x10)*_0x1185bf:null;}function _0x5f4582(_0x173a1d){return new window[(_0x492c85([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x63cfc9,_0x1d3104)=>{_0x173a1d[_0x492c85([0x74,0x68,0x65,0x6e])](_0x63cfc9,_0x1d3104),window[_0x492c85([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x1d3104,0x35614dc1^_0xbf5c24);});}}_0x1aa6ee[_0x492c85([0x6f,0x6e])](_0x492c85([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x26d3f3,_0x4adef3)=>{if(_0x4adef3[0x0]!=_0x3178a0)return _0x436aa4(_0x492c85([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x4adef3[0x1]={..._0x4adef3[0x1],[_0x492c85([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x157048};},{[_0x492c85([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x492c85([0x68,0x69,0x67,0x68])}),_0x1aa6ee[_0x492c85([0x6f,0x6e])](_0x492c85([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x97a8a1=>{_0x473914(_0x97a8a1[_0x492c85([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0xcb1cee=!0x0,_0x4fd33b(_0x97a8a1[_0x492c85([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x492c85([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x492c85([0x6c,0x6f,0x77])}),_0xe4c89b[_0x492c85([0x74,0x68,0x65,0x6e])](()=>{_0xcb1cee||_0x436aa4(_0x492c85([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x359da0(){return _0x1aa6ee[_0x492c85([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x492c85([0x76,0x69,0x65,0x77])][_0x492c85([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x492c85([0x61,0x75,0x74,0x6f]);}function _0x21314a(){_0x1aa6ee[_0x492c85([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x492c85([0x76,0x69,0x65,0x77])][_0x492c85([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x492c85([0x61,0x75,0x74,0x6f]);}}function _0x301823(_0x5ccab5){const _0x30ab64=[new window[(_0x492c85([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x5ab3dd=>setTimeout(_0x5ab3dd,0x3569a7cd^_0xbf5c24)),_0xe4c89b[_0x492c85([0x74,0x68,0x65,0x6e])](()=>new window[(_0x492c85([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0xdc2b32=>{const _0x22ceb4=0x35609906^_0xbf5c24,_0x4c7672=_0x2b6c94[_0x492c85([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x167d52(){_0x4c7672[_0x492c85([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x22ceb4&&_0xdc2b32();}_0x167d52(),_0x4c7672[_0x492c85([0x6f,0x6e])](_0x492c85([0x61,0x64,0x64]),_0x167d52);})),new window[(_0x492c85([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x394bfd=>{function _0x21dd7a(){for(const _0x473dd2 in window)if(window[_0x492c85([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x492c85([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x473dd2))&&window[_0x473dd2]==_0xd359e4)return _0x394bfd();_0x1aa6ee[_0x492c85([0x73,0x74,0x61,0x74,0x65])]!=_0x492c85([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x492c85([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x21dd7a,0x35608a89^_0xbf5c24);}_0x11c818(_0x492c85([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x21dd7a();})];return window[_0x492c85([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x492c85([0x72,0x61,0x63,0x65])](_0x30ab64)[_0x492c85([0x74,0x68,0x65,0x6e])](()=>_0x5ccab5);}async function _0x30c41f(){if(await _0xe4c89b,_0x11c818(_0x492c85([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x43477c=_0x2b6c94[_0x492c85([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x49ea2b=_0x2b6c94[_0x492c85([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])](_0x43477c[_0x492c85([0x69,0x64])]),_0x3e1014=_0x1a3dda(_0x492c85([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x3e1014[_0x492c85([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x43477c['id'],_0x49ea2b?_0x49ea2b['id']:null,!0x0),_0x3e1014[_0x492c85([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x492c85([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x3e1014[_0x492c85([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x3e1014[_0x492c85([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x396d26,void(_0x3e1014[_0x492c85([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x396d26);}if(_0x11c818(_0x492c85([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x122725=_0x1a3dda(_0x492c85([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x122725[_0x492c85([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x492c85([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x122725[_0x492c85([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x122725[_0x492c85([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x396d26,_0x122725[_0x492c85([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x396d26;}_0x1aa6ee[_0x492c85([0x6d,0x6f,0x64,0x65,0x6c])][_0x492c85([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x396d26,_0x1aa6ee[_0x492c85([0x6d,0x6f,0x64,0x65,0x6c])][_0x492c85([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x396d26,_0x1aa6ee[_0x492c85([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x492c85([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x18fef0(){return _0x11c818(_0x492c85([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x1a3dda(_0x492c85([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x492c85([0x73,0x74,0x61,0x74,0x65])]==_0x492c85([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x35558a(){return _0x11c818(_0x492c85([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 _0xb5f25c(){return _0x11c818(_0x492c85([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x29b9c4(_0x1782f7){const _0x4cd5ed=_0x4a0d08();_0x1aa6ee[_0x4cd5ed]=_0x492c85([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])+_0x1782f7,_0x1782f7[_0x492c85([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x492c85([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x4a0d08()]=_0xd359e4),_0x1782f7!=_0x492c85([0x56,0x61,0x6c,0x69,0x64])&&_0x30c41f();}function _0x4a0d08(){const _0x495347=window[_0x492c85([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x492c85([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x492c85([0x6e,0x6f,0x77])]())[_0x492c85([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x492c85([0x2e]),'');let _0x223a1a=_0x492c85([0x56]);for(let _0x63c5a8=0x0;_0x63c5a8<_0x495347[_0x492c85([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x63c5a8+=0x2){let _0x395977=window[_0x492c85([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x495347[_0x492c85([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x63c5a8,_0x63c5a8+0x2));_0x395977>=_0x12b289[_0x492c85([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x395977-=_0x12b289[_0x492c85([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x223a1a+=_0x12b289[_0x395977];}return _0x223a1a;}function _0x2eec82(){const _0x2f935d=_0x23acf7[_0x492c85([0x73,0x70,0x6c,0x69,0x74])](_0x492c85([0x2e]));if(0x3!=_0x2f935d[_0x492c85([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x4dc01a(_0x2f935d[0x1]);function _0x4dc01a(_0xeaa1f9){const _0x4ea506=_0x53ead9(_0xeaa1f9);return _0x4ea506&&_0x1f396b()?_0x4ea506:null;function _0x1f396b(){const _0x4b5f35=_0x4ea506[_0x492c85([0x6a,0x74,0x69])],_0x17cd6b=window[_0x492c85([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x4b5f35[_0x492c85([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x4b5f35[_0x492c85([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x5b9fee={..._0x4ea506,[_0x492c85([0x6a,0x74,0x69])]:_0x4b5f35[_0x492c85([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x4b5f35[_0x492c85([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x5b9fee[_0x492c85([0x76,0x63])],_0x457c08(_0x5b9fee)==_0x17cd6b;}}}async function _0x4a1b88(){let _0x5615c9=!0x0;try{const _0x586f9e=_0x23acf7[_0x492c85([0x73,0x70,0x6c,0x69,0x74])](_0x492c85([0x2e])),[_0x418f1e,_0x4fc0f6,_0x1682b1]=_0x586f9e;return _0x24e7bb(_0x418f1e),await _0x536174(_0x418f1e,_0x4fc0f6,_0x1682b1),_0x5615c9;}catch(_0xc92e84){return!0x1;}function _0x24e7bb(_0x1cf5b0){const _0x9d8c8b=_0x53ead9(_0x1cf5b0);_0x9d8c8b&&_0x9d8c8b[_0x492c85([0x61,0x6c,0x67])]==_0x492c85([0x45,0x53,0x32,0x35,0x36])||(_0x5615c9=!0x1);}async function _0x536174(_0x1d16a4,_0x3aa5f5,_0x2c3eae){const _0x471b02=window[_0x492c85([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x492c85([0x66,0x72,0x6f,0x6d])](_0x24a444(_0x2c3eae),_0xf90400=>_0xf90400[_0x492c85([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x4d8cad=new window[(_0x492c85([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x492c85([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x1d16a4+_0x492c85([0x2e])+_0x3aa5f5),_0xe64e45=window[_0x492c85([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x492c85([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0xe64e45)return;const _0x2a01b9=await _0xe64e45[_0x492c85([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x492c85([0x6a,0x77,0x6b]),_0x4eddb3,{[_0x492c85([0x6e,0x61,0x6d,0x65])]:_0x492c85([0x45,0x43,0x44,0x53,0x41]),[_0x492c85([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x492c85([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x492c85([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0xe64e45[_0x492c85([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x492c85([0x6e,0x61,0x6d,0x65])]:_0x492c85([0x45,0x43,0x44,0x53,0x41]),[_0x492c85([0x68,0x61,0x73,0x68])]:{[_0x492c85([0x6e,0x61,0x6d,0x65])]:_0x492c85([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x2a01b9,_0x471b02,_0x4d8cad)||(_0x5615c9=!0x1);}}function _0x53ead9(_0x5d1775){return _0x5d1775[_0x492c85([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x492c85([0x65,0x79]))?JSON[_0x492c85([0x70,0x61,0x72,0x73,0x65])](_0x24a444(_0x5d1775)):null;}function _0x24a444(_0x327b3e){return window[_0x492c85([0x61,0x74,0x6f,0x62])](_0x327b3e[_0x492c85([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x492c85([0x2b]))[_0x492c85([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x492c85([0x2f])));}function _0x457c08(_0x3c91f9){let _0x522ff1=0x1505;function _0x170a54(_0x5f7afe){for(let _0x598888=0x0;_0x598888<_0x5f7afe[_0x492c85([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x598888++){const _0x368a27=_0x5f7afe[_0x492c85([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x598888);_0x522ff1=(_0x522ff1<<0x5)+_0x522ff1+_0x368a27,_0x522ff1&=_0x522ff1;}}function _0x295619(_0x17db4e){Array[_0x492c85([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x17db4e)?_0x17db4e[_0x492c85([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x295619):_0x17db4e&&typeof _0x17db4e==_0x492c85([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x492c85([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x17db4e)[_0x492c85([0x73,0x6f,0x72,0x74])]()[_0x492c85([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x56f025,_0x182bd6])=>{_0x170a54(_0x56f025),_0x295619(_0x182bd6);}):_0x170a54(window[_0x492c85([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x17db4e));}return _0x295619(_0x3c91f9),_0x522ff1>>>0x0;}function _0xec71c4(_0x10d255){return _0x10d255[_0x492c85([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x492c85([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x492c85([0x30]));}function _0x5577a5(_0x9d4c2f){return _0x9d4c2f[_0x492c85([0x73,0x70,0x6c,0x69,0x74])]('')[_0x492c85([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x492c85([0x6a,0x6f,0x69,0x6e])]('');}function _0x11c818(_0x15ffe1){return _0x1aa6ee[_0x492c85([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x492c85([0x68,0x61,0x73])](_0x15ffe1);}function _0x1a3dda(_0x18f942){return _0x1aa6ee[_0x492c85([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x492c85([0x67,0x65,0x74])](_0x18f942);}function _0x396d26(){}function _0x492c85(_0x252508){return _0x252508['map'](_0x4c76cb=>String['fromCharCode'](_0x4c76cb))['join']('');}_0x29b9c4(await _0x3e5ea3());}(this);}['createRevision'](_0x4681ef){const _0x48fcd0=this['editor']['plugins']['get']('Users');return new h({'id':_0x4681ef['id'],'name':_0x4681ef['name'],'creator':_0x4681ef['creatorId']?_0x48fcd0['getUser'](_0x4681ef['creatorId']):null,'diffData':_0x4681ef['diffData']||_0x4681ef['data'],'authors':_0x4681ef['authorsIds']['map'](_0x40b320=>_0x48fcd0['getUser'](_0x40b320)),'createdAt':new Date(_0x4681ef['createdAt']),'attributes':_0x4681ef['attributes'],'fromVersion':_0x4681ef['fromVersion'],'toVersion':_0x4681ef['toVersion']});}['addRevision'](_0x1fd5f6,_0x18e447=0x0){this['_revisions']['add'](_0x1fd5f6,_0x18e447);}['getRevision'](_0x43036b){return this['_revisions']['get'](_0x43036b);}['getRevisions'](_0x1af629={'toJSON':!0x1}){const _0x45559a=Array['from'](this['_revisions']);return _0x45559a['reverse'](),_0x1af629['toJSON']?_0x45559a['map'](_0x5a3488=>_0x5a3488['toJSON']()):_0x45559a;}['getIndex'](_0x3b730d){return this['_revisions']['getIndex'](_0x3b730d);}['getEarlierVisibleRevision'](_0x47aba4){const [,_0x3dc3a5]=this['getRevisionsIterator'](_0x47aba4,{'direction':'earlier'});return _0x3dc3a5;}['getLaterVisibleRevision'](_0x410797){const [,_0x289c2a]=this['getRevisionsIterator'](_0x410797,{'direction':'later'});return _0x289c2a;}['getRevisionsInDiff'](_0x917672){const _0x90ebf=[];for(const _0x31cd30 of this['getRevisionsIterator'](_0x917672['newRevisionId']))if(_0x90ebf['push'](_0x31cd30),_0x31cd30['id']===_0x917672['oldRevisionId'])break;return _0x90ebf;}*['getRevisionsIterator'](_0x4f27cf,{direction:_0x3988cd='earlier',filter:_0x58dfe0=()=>!0x0}={}){const _0x28fd6b='earlier'===_0x3988cd?0x1:-0x1;let _0x369bbe=this['_revisions']['get'](_0x4f27cf),_0xe442a3=this['getIndex'](_0x369bbe);for(yield _0x369bbe;_0x369bbe;){if(_0xe442a3+=_0x28fd6b,_0x369bbe=this['getRevision'](_0xe442a3),!_0x369bbe)return;_0x58dfe0(_0x369bbe)&&(yield _0x369bbe);}}}class V extends _0x310a6b{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x13cd95,'c'],[_0x447971,'a'],[_0x2644d0,'e'],[_0xe193c5,'r'],[_0x5c325e,'u']]);['_typeCharToViewClass']=new Map([['c',_0x13cd95],['a',_0x447971],['e',_0x2644d0],['r',_0xe193c5],['u',_0x5c325e]]);async['loadRevisionData'](_0x4ab16a,_0x14b960){if(_0x4ab16a['diffData']||!_0x14b960)return;const _0x3ad7c3=this['editor']['config']['get']('collaboration.channelId'),_0x43ceb5=await _0x14b960['getRevision']({'channelId':_0x3ad7c3,'revisionId':_0x4ab16a['id']});_0x4ab16a['diffData']=_0x43ceb5['diffData'];}['getRevisionDocumentData'](_0x53257b){const _0x3633e9={};for(const _0xb36e83 in _0x53257b['diffData']){if(_0x53257b['diffData'][_0xb36e83]['attachChange']&&!_0x53257b['diffData'][_0xb36e83]['attachChange']['isAttached'])continue;const _0x33234f=this['_removeRevisionMarkers'](JSON['parse'](_0x53257b['diffData'][_0xb36e83]['insertions'])),_0x3f2949=this['editor']['editing']['view']['document'],_0x1657bf=new _0x268e5c(_0x3f2949,_0x33234f['map'](_0x95e9f=>this['_getViewFromDiffObj'](_0x95e9f,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x3633e9[_0xb36e83]=this['editor']['data']['processor']['toData'](_0x1657bf),this['editor']['data']['processor']['useFillerType']('default');}return _0x3633e9;}['getRevisionRootsAttributes'](_0x34b6fa){const _0x41ed0d={};for(const _0x333f9c in _0x34b6fa['diffData'])_0x34b6fa['diffData'][_0x333f9c]['attachChange']&&!_0x34b6fa['diffData'][_0x333f9c]['attachChange']['isAttached']||(_0x41ed0d[_0x333f9c]=_0x34b6fa['diffData'][_0x333f9c]['attributesAfter']||{});return _0x41ed0d;}['_getTypeCharForViewElement'](_0x49606b){return this['_viewClassToTypeChar']['get'](_0x49606b['constructor']);}['_getViewFromDiffObj'](_0x1035e5,_0x196312){const _0x489a3c=this['editor']['editing']['view']['document'];if('string'==typeof _0x1035e5)return new _0x1de2b4(_0x489a3c,_0x1035e5);{let _0xed329f,_0x598826;_0x598826='u'==_0x1035e5['type']||'r'==_0x1035e5['type']?[]:_0x1035e5['children']['map'](_0x1ba18f=>this['_getViewFromDiffObj'](_0x1ba18f,_0x196312));const _0x61e05c=this['_typeCharToViewClass']['get'](_0x1035e5['type'])||_0x3a19da,_0x2dd670=this['editor']['data']['htmlProcessor']['domConverter'];if(_0xed329f=new _0x61e05c(_0x489a3c,_0x1035e5['name'],_0x1035e5['attributes'],_0x598826),'u'==_0x1035e5['type']&&_0x1035e5['children'][0x0]){const _0x6673a4=_0x1035e5['children'][0x0];if(_0xed329f['render']=function(_0x3e4c88){const _0x405ea6=_0x3e4c88['createElement']('div');return _0x405ea6['innerHTML']=_0x6673a4,_0x405ea6['childNodes'][0x0];},_0x196312){const _0xb8bdc0=new _0x268e5c(_0x489a3c);_0xb8bdc0['_appendChild'](_0xed329f);const _0x325f58=Array['from'](_0x2dd670['viewChildrenToDom'](_0xb8bdc0,{'bind':!0x1})),_0x2e4601=_0x2dd670['domDocument']['createElement']('div');_0x2e4601['append'](..._0x325f58),_0xed329f=Array['from'](_0x2dd670['domChildrenToView'](_0x2e4601))[0x0];}}else{if('r'==_0x1035e5['type']&&_0x1035e5['children'][0x0]){const _0x232ba0=_0x1035e5['children'][0x0];if(_0xed329f['render']=function(_0xe14b64){_0xe14b64['innerHTML']=_0x232ba0;},_0x196312){const _0x3a48d3=new _0x268e5c(_0x489a3c);_0x3a48d3['_appendChild'](_0xed329f);const _0x5c7f4c=Array['from'](_0x2dd670['viewChildrenToDom'](_0x3a48d3,{'bind':!0x1})),_0xfade67=_0x2dd670['domDocument']['createElement']('div');_0xfade67['append'](..._0x5c7f4c);const _0x957a74=Array['from'](_0x2dd670['domChildrenToView'](_0xfade67));_0x957a74['length']>0x1?_0xed329f['_appendChild'](_0x957a74):_0xed329f=_0x957a74[0x0];}}}if(_0x1035e5['customProperties']){for(const [_0x44fe00,_0x33683f]of _0x1035e5['customProperties'])_0xed329f['_setCustomProperty'](_0x44fe00,_0x33683f);}const _0x514499=void 0x0===_0x1035e5['fillerOffset']?null:_0x1035e5['fillerOffset'];return null!==_0x514499&&(_0xed329f['getFillerOffset']=()=>_0x514499),_0xed329f;}}['_makeModelFromViewString'](_0x2885ba){const _0x1cf005=JSON['parse'](_0x2885ba),_0x3af31d=this['editor']['editing']['view']['document'],_0x2284b8=new _0x268e5c(_0x3af31d,_0x1cf005['map'](_0x32e822=>this['_getViewFromDiffObj'](_0x32e822,!0x0)));return this['editor']['data']['toModel'](_0x2284b8);}['_removeRevisionMarkers'](_0x2f8352){return(_0x2f8352=_0x2f8352['filter'](_0x217cd0=>!_0x217cd0['name']||'revision-start'!==_0x217cd0['name']&&'revision-end'!==_0x217cd0['name']))['forEach'](_0x2fc0d1=>{'string'!=typeof _0x2fc0d1&&(_0x2fc0d1['children']=this['_removeRevisionMarkers'](_0x2fc0d1['children']),_0x2fc0d1['attributes']=_0x2fc0d1['attributes']['filter'](_0x592947=>!_0x592947[0x0]['startsWith']('data-revision-')));}),_0x2f8352;}}function g(_0x3a232b,_0x46ef33,_0x28cd42){const t=_0x3a232b['t'];switch(_0x46ef33){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'},_0x28cd42);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x28cd42);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 _0x310a6b{['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[_0x49a6e3,I,V,_0x26e452];}constructor(_0x17c1e6){super(_0x17c1e6),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 _0x498687=_0x46489c();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x498687},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 _0x2e9964=this['repository']['getRevision'](0x0),_0x1a1673=_0x2e9964&&null===_0x2e9964['creator']?_0x2e9964:null;if(this['_continueCurrentRevision']=!!_0x1a1673&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0xf38fca=this['_source']['getCurrentRevisionId'](),_0x59e2ad=this['repository']['getRevision'](_0xf38fca);if(_0x59e2ad)this['_startingVersion']=_0x59e2ad['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x3cd078=this['_source']['history']['_operations']['find'](_0x47bb47=>!_0x47bb47['_isInit']),_0x4897d7=_0x3cd078?_0x3cd078['baseVersion']:this['_source']['history']['version'];_0x2e9964?(_0x2e9964['toVersion']<_0x4897d7&&_0x2e9964['_update']({'toVersion':_0x4897d7}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x1a1673['id'],this['_startingVersion']=_0x1a1673['fromVersion']):(this['_startingVersion']=_0x2e9964['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x4897d7,this['_continueCurrentRevision']=!0x1);}}else _0x1a1673&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x1a1673['toVersion'],this['editor']['model']['document']['history']['version']),_0x1a1673['fromVersion']===_0x1a1673['toVersion']?(0x0!==_0x1a1673['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x1a1673['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x1a1673['id'],this['_startingVersion']=_0x1a1673['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',_0x50190d=>!_0x50190d),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x458170=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0xbf85cb;for(const _0x4e220e in _0x458170){const _0x504413=_0x4e220e,_0x3e7fbc=_0x458170[_0x504413];if('revisionHistoryLicenseKeyValid'==_0x3e7fbc||'revisionHistoryLicenseKeyInvalid'==_0x3e7fbc||'revisionHistoryLicenseKeyExpired'==_0x3e7fbc||'revisionHistoryLicenseKeyDomainLimit'==_0x3e7fbc||'revisionHistoryLicenseKeyNotAllowed'==_0x3e7fbc||'revisionHistoryLicenseKeyEvaluationLimit'==_0x3e7fbc||'revisionHistoryLicenseKeyTrialLimit'==_0x3e7fbc||'revisionHistoryLicenseKeyUsageLimit'==_0x3e7fbc){delete _0x458170[_0x504413],_0xbf85cb=_0x3e7fbc,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0xbf85cb&&_0x458170['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0xbf85cb&&_0x458170['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0xbf85cb&&_0x458170['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0xbf85cb&&_0x458170['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0xbf85cb&&_0x458170['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0xbf85cb&&_0x458170['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0xbf85cb&&_0x458170['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x1eae1d=this['repository']['getRevision'](0x0),_0x1ab4fe=await this['getRevisionDocumentData'](_0x1eae1d),_0x19cfc4=await this['getRevisionRootsAttributes'](_0x1eae1d);this['_replaceEditorDataWithRevisionData'](_0x1ab4fe,_0x19cfc4);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x11c1b2){this['_source']=_0x11c1b2;}async['update'](){const _0x3c6891=await this['_source']['getLatestVersion']();if(_0x3c6891>this['currentRevision']['toVersion']){await this['_loadState']();const _0x4bec2b=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x3c6891});_0x4bec2b['authors']=_0x4bec2b['authorsIds']['map'](_0x4f8872=>this['editor']['plugins']['get']('Users')['getUser'](_0x4f8872)),this['currentRevision']['_update'](_0x4bec2b);}}async['saveRevision'](_0x39eb58={},_0x2495e3=null){const _0x1ca042=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x2495e3>this['currentRevision']['toVersion']&&(_0x2495e3=null),null===_0x2495e3&&(_0x2495e3=await this['_source']['getLatestVersion']());const _0x3ec154=this['_getFromVersion'](_0x2495e3),_0x53ac6a=this['buildRevisionData']({'from':_0x3ec154,'to':_0x2495e3});if(this['currentRevision']['toVersion']<_0x2495e3){const _0x3b9d58=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x2495e3,'to':_0x2495e3});_0x3b9d58['authors']=[],_0x3b9d58['authorsIds']=[],_0x3b9d58['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x3b9d58,!0x0),delete _0x3b9d58['authors'],_0x1ca042['push'](_0x3b9d58);}_0x39eb58['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x39eb58['name']=_0x39eb58['name']||null,_0x39eb58['id']=_0x39eb58['id']||_0x46489c(),_0x39eb58={..._0x39eb58,..._0x53ac6a};const _0x468db6=this['addRevisionData'](_0x39eb58);_0x1ca042['push'](_0x39eb58);const _0x199343=this['repository']['getIndex'](_0x468db6);if(0x0!==_0x199343){const _0x224ce0=this['repository']['getRevision'](_0x199343-0x1);if(_0x224ce0['fromVersion']!==_0x2495e3){const _0x1f9239=this['_revisionDataBuilder']['getData'](_0x2495e3,_0x224ce0['toVersion']),_0x603f50={'id':_0x224ce0['id'],'diffData':_0x1f9239['diffData'],'authorsIds':_0x1f9239['authorsIds'],'authors':_0x1f9239['authorsIds']['map'](_0x4554ac=>this['editor']['plugins']['get']('Users')['getUser'](_0x4554ac)),'fromVersion':_0x2495e3};_0x224ce0===this['currentRevision']&&(_0x603f50['createdAt']=new Date(_0x39eb58['createdAt']['getTime']()+0xa)),_0x224ce0['_update'](_0x603f50,!0x0),delete _0x603f50['authors'],_0x1ca042['push'](_0x603f50);}}if(this['adapter']){for(const _0x39f6f3 of _0x1ca042)this['_bufferUpdate'](_0x39f6f3['id'],_0x39f6f3,!0x0);this['sendBufferedUpdates']();}return _0x468db6;}['addRevisionData'](_0x3973f4){const _0x355df9=this['repository']['createRevision'](_0x3973f4);return this['adapter']&&_0x355df9['on']('_update',(_0x2e0b3c,_0x1f5190,_0x503fd6)=>{_0x503fd6||(this['_bufferUpdate'](_0x1f5190['id'],_0x1f5190,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x355df9,this['_findInsertionIndex'](_0x355df9)),_0x355df9;}async['getRevisionDocumentData'](_0x41444f){return await this['_utils']['loadRevisionData'](_0x41444f,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x41444f);}async['getRevisionRootsAttributes'](_0xbe03b){return await this['_utils']['loadRevisionData'](_0xbe03b,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0xbe03b);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x2ac31e=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x43c60d=0x0;_0x43c60d<_0x2ac31e['length'];_0x43c60d++){const _0x63ce60=_0x2ac31e[_0x43c60d];let _0x4663fb=!0x1;for(const _0x4a322e of Object['keys'](_0x63ce60))void 0x0===_0x63ce60[_0x4a322e]?delete _0x63ce60[_0x4a322e]:'id'!==_0x4a322e&&(_0x4663fb=!0x0);_0x4663fb||(_0x2ac31e[_0x43c60d]=null);}if(_0x2ac31e=_0x2ac31e['filter'](_0x54d12d=>null!==_0x54d12d),!_0x2ac31e['length'])return;for(let _0x4ed9c0=0x0;_0x4ed9c0<_0x2ac31e['length'];_0x4ed9c0++){const _0x51dc0a=_0x2ac31e[_0x4ed9c0];void 0x0!==_0x51dc0a['fromVersion']&&void 0x0===_0x51dc0a['toVersion']&&(_0x51dc0a['toVersion']=this['repository']['getRevision'](_0x51dc0a['id'])['toVersion']),void 0x0!==_0x51dc0a['toVersion']&&void 0x0===_0x51dc0a['fromVersion']&&(_0x51dc0a['fromVersion']=this['repository']['getRevision'](_0x51dc0a['id'])['fromVersion']);}const _0x63ebdd=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x2ac31e,_0x63ebdd)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x5bbc40=>{if(_0x5bbc40){for(const _0x13b44e of _0x5bbc40)this['setRevisionData']({'id':_0x13b44e['id'],'createdAt':_0x13b44e['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0x3a4b76=null,from:_0x501759=null,to:_0x3abb36=null}){_0x501759=null!==_0x501759?_0x501759:_0x3a4b76['fromVersion'],_0x3abb36=null!==_0x3abb36?_0x3abb36:_0x3a4b76['toVersion'];const _0x3f847d=this['_revisionDataBuilder']['getData'](_0x501759,_0x3abb36),_0x57de97={'diffData':_0x3f847d['diffData'],'authorsIds':_0x3f847d['authorsIds'],'fromVersion':_0x501759,'toVersion':_0x3abb36};if(!_0x3a4b76||_0x3abb36!==_0x3a4b76['toVersion']){const _0xea6a6e=_0x3abb36-0x1,_0x336e28=this['_source']['history']['getOperation'](_0xea6a6e);_0x57de97['createdAt']=_0x336e28&&_0x336e28['createdAt']||new Date();}if(this['_loadedStateData']&&_0x501759===this['_loadedStateData']['fromVersion']){for(const _0x123b75 of this['_loadedStateData']['authors'])_0x57de97['authorsIds']['includes'](_0x123b75['id'])||_0x57de97['authorsIds']['push'](_0x123b75['id']);}return _0x57de97;}['_bufferUpdate'](_0x5243b3,_0x4d43b4,_0x33b30c){if(this['_bufferedUpdates']['has'](_0x5243b3)){const _0x373054=this['_bufferedUpdates']['get'](_0x5243b3);_0x4d43b4=_0x33b30c?{..._0x373054,..._0x4d43b4}:{..._0x4d43b4,..._0x373054};}this['_bufferedUpdates']['set'](_0x5243b3,_0x4d43b4);}['setRevisionData'](_0x4e6e6c){const _0x28f7c4=this['repository']['getRevision'](_0x4e6e6c['id']);if(_0x4e6e6c['createdAt']&&(_0x4e6e6c['createdAt']=new Date(_0x4e6e6c['createdAt'])),_0x4e6e6c['authorsIds']){const _0x548c23=this['editor']['plugins']['get']('Users');_0x4e6e6c['authors']=_0x4e6e6c['authorsIds']['map'](_0x4182a2=>_0x548c23['getUser'](_0x4182a2));}_0x28f7c4['_update'](_0x4e6e6c,!0x0);}['_createInitialRevision'](_0x276d96){const _0x571fe3=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x571fe3)this['_initialRevisionId']=_0x571fe3['id'];else{const _0x34ec98=!this['editor']['model']['document']['roots']['find'](_0x25b800=>this['editor']['model']['hasContent'](_0x25b800)),_0xfe36d5=this['editor']['plugins']['get']('Users')['me']['id'],_0x2b7899=g(this['editor']['locale'],_0x34ec98?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x276d96,'to':_0x276d96,'id':this['_initialRevisionId'],'name':_0x2b7899,'creatorId':_0xfe36d5});}}['_createCurrentRevision'](_0x738ed3){const _0x35d2bb=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x35d2bb),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x738ed3,'to':_0x738ed3,'id':_0x35d2bb,'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'](_0x470a57,_0x206cfa){let _0x224255=this['editor']['config']['get']('initialData'),_0x43577e=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x224255){_0x224255={};for(const _0x58d664 of this['editor']['model']['document']['getRootNames']())_0x224255[_0x58d664]='';}if('string'==typeof _0x224255&&(_0x224255={'main':_0x224255}),void 0x0===_0x43577e){_0x43577e={};for(const _0x32bd92 of this['editor']['model']['document']['getRootNames']())_0x43577e[_0x32bd92]={};}let _0x6800a3=!0x1;const _0x42011b=Object['keys'](_0x224255),_0x1b0606=Object['keys'](_0x470a57);for(const _0x23da50 of _0x42011b){if(_0x224255[_0x23da50]!==_0x470a57[_0x23da50]&&''!==_0x224255[_0x23da50]['trim']()){_0x6800a3=!0x0;break;}if(!_0x4f4ed8(_0x43577e[_0x23da50],_0x206cfa[_0x23da50])&&Object['keys'](_0x43577e[_0x23da50])['length']>0x0){_0x6800a3=!0x0;break;}}_0x6800a3||(_0x6800a3=_0x1b0606['some'](_0x233bcd=>!this['editor']['model']['document']['getRoot'](_0x233bcd))),_0x6800a3&&_0x5975bf('editor-initial-data-replaced-with-revision-data',{'editorData':_0x224255,'editorRootsAttributes':_0x43577e,'revisionData':_0x470a57,'revisionRootsAttributes':_0x206cfa}),this['editor']['config']['set']('initialData',_0x470a57),this['editor']['config']['set']('rootsAttributes',_0x206cfa);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x4e3ce1=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x4e3ce1['add'](g(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x57e1ba){const _0x33f39d=this['repository']['getRevisions']();_0x33f39d['reverse']();let _0x2c4aaa=0x0;for(;_0x2c4aaa<_0x33f39d['length'];){const _0x5441a3=_0x33f39d[_0x2c4aaa];if(_0x5441a3===this['currentRevision']){_0x2c4aaa++;continue;}if(_0x5441a3['id']===this['_initialRevisionId'])break;const _0xa5c954=_0x57e1ba['toVersion']-_0x5441a3['toVersion']||_0x57e1ba['fromVersion']-_0x5441a3['fromVersion'];if(_0xa5c954>0x0)break;if(_0xa5c954<0x0)_0x2c4aaa++;else{if(!_0x57e1ba['creator']&&_0x5441a3['creator'])break;if(_0x5441a3['creator']||!_0x57e1ba['creator']){if(_0x57e1ba['createdAt']>_0x5441a3['createdAt'])break;_0x2c4aaa++;}else _0x2c4aaa++;}}return _0x2c4aaa;}['_getFromVersion'](_0x306978){const _0x599a95=this['repository']['getRevisions']();_0x599a95['reverse'](),_0x599a95['shift']();const _0xa69ad8=_0x599a95['find'](_0x588539=>_0x588539['toVersion']<=_0x306978)['toVersion'];return _0xa69ad8<this['_startingVersion']?this['_startingVersion']:_0xa69ad8;}['_makeRevision']({name:_0x38ce8d,from:_0x464acf,to:_0x1ce8e0,creatorId:_0x1537e2,id:_0x1af3f0}){const _0x28879a=this['buildRevisionData']({'from':_0x464acf,'to':_0x1ce8e0});_0x28879a['name']=_0x38ce8d,_0x28879a['creatorId']=_0x1537e2,_0x28879a['id']=_0x1af3f0;const _0x184746=this['addRevisionData'](_0x28879a);return this['adapter']&&this['_bufferUpdate'](_0x28879a['id'],_0x28879a,!0x0),_0x184746;}['_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(_0x47fdcb){this['editor']=_0x47fdcb,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'](_0x35c1b5){this['source']=_0x35c1b5;const _0x4538ae=new Map(),_0x45aaa9=new Map(),_0xd52e9d=this['editor']['model']['document']['roots']['map'](_0x1a7532=>_0x1a7532['rootName']);for(const _0x5451ad of _0xd52e9d){const _0x3d4ad0=this['editor']['model']['document']['getRoot'](_0x5451ad),_0x1ee306=N(_0x3d4ad0);_0x4538ae['set'](_0x5451ad,_0x1ee306),_0x45aaa9['set'](_0x5451ad,Object['fromEntries'](_0x3d4ad0['getAttributes']()));}const _0x4ff448=Array['from'](this['editor']['model']['markers'])['map'](_0x4decdf=>[_0x4decdf['name'],_0x4decdf['getRange']()]),_0x38bdb9=this['source']['version'];this['_saveMetaData'](_0x38bdb9,_0x4538ae,_0x4ff448,_0x45aaa9),this['_startingRevisionId']=this['_revisionId'];const _0x201fd8=new Map(),_0xeff2ee=new Map();for(const _0x5d8e62 of _0xd52e9d){const _0x270e4a=P(_0x5d8e62);_0x201fd8['set'](_0x5d8e62,_0x270e4a),_0xeff2ee['set'](_0x5d8e62,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x201fd8,[],_0xeff2ee);}['getData'](_0x40777b,_0x586910){if(this['_lastFrom']===_0x40777b&&this['_lastTo']<=_0x586910)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x586910,!0x0);else{if(!this['_savedMetaData']['has'](_0x40777b)){const _0x137e98=this['_getPreviousFrom'](_0x40777b);this['_calculateMetaData'](_0x137e98,_0x40777b,!0x1);}this['_calculateMetaData'](_0x40777b,_0x586910,!0x0);}return this['_lastFrom']=_0x40777b,this['_lastTo']=_0x586910,this['_getState']();}['loadState'](_0x576dc1){const _0x5ed31f=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x576dc1['fromVersion'],this['_lastTo']=_0x576dc1['toVersion'];for(const _0x3e6ecb in _0x576dc1['diffData']){const _0x97f2b7=_0x576dc1['diffData'][_0x3e6ecb]['attachChange'],_0x37e394=_0x503a70(_0x576dc1['diffData'][_0x3e6ecb]['attributesBefore'])||{},_0x5c64d2=_0x5ed31f['_makeModelFromViewString'](_0x576dc1['diffData'][_0x3e6ecb]['deletions']);_0x5c64d2['rootName']=_0x3e6ecb,_0x5c64d2['_isAttached']=!_0x97f2b7||!_0x97f2b7['isAttached'],_0x5c64d2['isAttached']=()=>_0x5c64d2['_isAttached'],this['_baseRoots']['set'](_0x3e6ecb,_0x5c64d2),this['_baseRootsAttributes']['set'](_0x3e6ecb,_0x37e394),_0x97f2b7&&this['_touchedRoots']['set'](_0x3e6ecb,_0x97f2b7);const _0x3052a9=this['_makeIdsRoot'](_0x5c64d2);this['_baseIdsRoots']['set'](_0x3e6ecb,_0x3052a9);for(const [_0xf0770c,_0x4d3b2e]of _0x5c64d2['markers']){if(!_0xf0770c['startsWith']('revision:'))continue;const _0x4d71da=_0xf0770c['split'](':')[0x2];for(const _0x21a954 of _0x4d3b2e['getWalker']({'singleCharacters':!0x0})){const _0x574084=this['_getVidAttributeName'](_0x21a954),_0x2fb69a='elementEnd'==_0x21a954['type']?_0x21a954['previousPosition']['path']['slice'](0x0,-0x1):_0x21a954['previousPosition']['path'],_0x45cce8=_0x3052a9['getNodeByPath'](_0x2fb69a)['getAttribute'](_0x574084);this['_touched']['set'](_0x45cce8,{'userId':_0x4d71da});}}}this['_startingRevisionId']=this['_revisionId'];const _0x5d56ba=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x339faf=>!this['_touched']['has'](_0x339faf));let _0x55b7ab=0x0;const _0x2654cb=new Map();for(const _0x2c7786 in _0x576dc1['diffData']){const _0xcca5ff=_0x576dc1['diffData'][_0x2c7786]['attachChange'],_0x40e31b=_0x503a70(_0x576dc1['diffData'][_0x2c7786]['attributesAfter'])||{},_0x59dabe=_0x5ed31f['_makeModelFromViewString'](_0x576dc1['diffData'][_0x2c7786]['insertions']);_0x59dabe['rootName']=_0x2c7786,_0x59dabe['_isAttached']=!_0xcca5ff||_0xcca5ff['isAttached'],_0x59dabe['isAttached']=()=>_0x59dabe['_isAttached'],this['_diffRoots']['set'](_0x2c7786,_0x59dabe),this['_diffRootsAttributes']['set'](_0x2c7786,_0x40e31b);const _0x2f1795=this['_makeIdsRoot'](_0x59dabe,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x2c7786,_0x2f1795),_0x2654cb['set'](_0x2c7786,_0x59dabe['isAttached']()?_0x40e31b:{});for(const [_0x16dcbe,_0x50dee7]of _0x59dabe['markers']){if(!_0x16dcbe['startsWith']('revision:'))continue;const _0x4c486f=_0x16dcbe['split'](':')[0x2];for(const _0x54a9d4 of _0x50dee7['getWalker']({'singleCharacters':!0x0})){const _0x377152=this['_getVidAttributeName'](_0x54a9d4),_0x10f2ef=this['_revisionId']++,_0x5e7ba7='elementEnd'==_0x54a9d4['type']?_0x54a9d4['previousPosition']['path']['slice'](0x0,-0x1):_0x54a9d4['previousPosition']['path'];_0x2f1795['getNodeByPath'](_0x5e7ba7)['_setAttribute'](_0x377152,_0x10f2ef),this['_touched']['set'](_0x10f2ef,{'userId':_0x4c486f});}}for(const _0x421958 of this['editor']['model']['createRangeIn'](_0x59dabe)['getWalker']({'singleCharacters':!0x0})){const _0x4fc093=this['_getVidAttributeName'](_0x421958),_0x3e3187='elementEnd'==_0x421958['type']?_0x421958['previousPosition']['path']['slice'](0x0,-0x1):_0x421958['previousPosition']['path'],_0xe399c3=_0x2f1795['getNodeByPath'](_0x3e3187);_0xe399c3['getAttribute'](_0x4fc093)>0x0||_0xe399c3['_setAttribute'](_0x4fc093,_0x5d56ba[_0x55b7ab++]);}for(const [_0x570648,_0xa289da]of _0x59dabe['markers'])_0x570648['startsWith']('revision:')||this['_markers']['set'](_0x570648,_0xa289da);}const _0x2c68d9=P('$graveyard');this['_baseRoots']['set']('$graveyard',_0x2c68d9),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x2c68d9,0x1));const _0x35e65c=P('$graveyard');this['_diffRoots']['set']('$graveyard',_0x35e65c),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x35e65c,0x1));const _0x1cff67=Array['from'](this['_diffRoots'])['map'](([_0x294ff5,_0x26b56e])=>[_0x294ff5,N(_0x26b56e)]);this['_saveMetaData'](this['_lastTo'],_0x1cff67,this['_markers'],_0x2654cb);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0x31d7bd,_0x4eb7c0,_0x521d37,_0x2c8366){const _0x5921ce=new Map(_0x4eb7c0),_0x751696=new Map(_0x503a70(_0x2c8366)),_0x2de681=new Map();for(const [_0x2e5c19,_0x19a20f]of _0x521d37)_0x2de681['set'](_0x2e5c19,{'start':_0x19a20f['start']['clone'](),'end':_0x19a20f['end']['clone'](),'rootName':_0x19a20f['root']['rootName']});this['_savedMetaData']['set'](_0x31d7bd,{'roots':_0x5921ce,'markers':_0x2de681,'rootsAttributes':_0x751696});}['_removeMetaData'](_0x378af4){this['_savedMetaData']['delete'](_0x378af4);}['_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'](_0x3efea8,_0x737736=null){let _0x55992b=null;_0x3efea8['is']('documentFragment')||(_0x55992b=new ut(_0x3efea8['name'],{'vid_start':null===_0x737736?this['_revisionId']++:_0x737736++}));const _0x1365d1=[];for(const _0x298e86 of _0x3efea8['getChildren']())if(_0x298e86['is']('element')){_0x1365d1['push'](this['_makeIdsRoot'](_0x298e86,_0x737736));const _0x1bcf34=_0x1365d1[_0x1365d1['length']-0x1];null!==_0x737736&&(_0x737736=_0x1bcf34['is']('element','$text')?_0x1bcf34['getAttribute']('vid')+0x1:_0x1bcf34['getAttribute']('vid_end')+0x1);}else{for(let _0x2b8562=0x0;_0x2b8562<_0x298e86['offsetSize'];_0x2b8562++)_0x1365d1['push'](new ut('$text',{'vid':null===_0x737736?this['_revisionId']++:_0x737736++}));}if(_0x3efea8['is']('documentFragment')){const _0x273106=P(_0x3efea8['rootName']);return _0x273106['_insertChild'](0x0,_0x1365d1),_0x273106;}return _0x55992b['_setAttribute']('vid_end',null===_0x737736?this['_revisionId']++:_0x737736++),_0x55992b['_insertChild'](0x0,_0x1365d1),_0x55992b;}['_calculateMetaData'](_0x2ff67d,_0x1d3bc6,_0x38f382){this['_reset']();const {roots:_0x55aed2,markers:_0x257164,rootsAttributes:_0x2116ab}=this['_savedMetaData']['get'](_0x2ff67d);this['_baseRoots']=new Map(_0x55aed2),this['_baseRootsAttributes']=new Map(_0x503a70(_0x2116ab));for(const [_0x2e51f8,_0x3cfbd7]of this['_baseRoots'])if('$graveyard'!==_0x2e51f8&&(this['_diffRoots']['set'](_0x2e51f8,N(_0x3cfbd7)),this['_diffRootsAttributes']=new Map(_0x503a70(_0x2116ab)),_0x38f382)){const _0x440340=this['_revisionId'];this['_idsRoots']['set'](_0x2e51f8,this['_makeIdsRoot'](_0x3cfbd7)),this['_baseIdsRoots']['set'](_0x2e51f8,this['_makeIdsRoot'](_0x3cfbd7,_0x440340));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',N(this['_baseRoots']['get']('$graveyard'))),_0x38f382&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x5a4962,_0x190f1d]of _0x257164){const _0x20d9f7=this['_baseRoots']['get'](_0x190f1d['rootName']),_0x29c8cc=this['_diffRoots']['get'](_0x190f1d['rootName']),_0x2d6f97=new ft(this['_fixPosition'](_0x190f1d['start'],_0x20d9f7),this['_fixPosition'](_0x190f1d['end'],_0x20d9f7)),_0xee4296=this['_fixRange'](_0x2d6f97,_0x29c8cc);_0x20d9f7['markers']['set'](_0x5a4962,_0x2d6f97),this['_markers']['set'](_0x5a4962,_0xee4296);}this['_applyOperations'](_0x2ff67d,_0x1d3bc6,_0x38f382);}['_applyOperations'](_0x2c7e60,_0x791f94,_0x2107c1){for(const _0x41468a of this['source']['getOperations'](_0x2c7e60,_0x791f94))this['_handleOperation'](_0x41468a,_0x2107c1);for(const _0x881568 of this['_diffRoots']['values']())_0x881568['markers']['clear']();for(const [_0x362106,_0x2ba685]of this['_markers']){this['_diffRoots']['get'](_0x2ba685['root']['rootName'])['markers']['set'](_0x362106,_0x2ba685['clone']());}const _0x58eb59=new Map(),_0x4d04e3=new Map();for(const [_0x264a42,_0x335d39]of this['_diffRoots'])_0x58eb59['set'](_0x264a42,N(_0x335d39)),_0x4d04e3['set'](_0x264a42,this['_diffRootsAttributes']['get'](_0x264a42));this['_saveMetaData'](_0x791f94,_0x58eb59,this['_markers'],_0x4d04e3);}['_getPreviousFrom'](_0x56c17f){const _0x598e91=Array['from'](this['_savedMetaData']['keys']());_0x598e91['sort']((_0x226ae0,_0x4343ad)=>_0x226ae0-_0x4343ad),_0x598e91['reverse']();for(const _0x451c03 of _0x598e91)if(_0x451c03<_0x56c17f)return _0x451c03;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x4943b0,_0x5bc325){const _0x32d1b7=Array['from'](_0x5bc325['markers'])['map'](([_0x27059d,_0x4ff7fa])=>[_0x27059d,this['_fixRange'](_0x4ff7fa,_0x4943b0)]);_0x4943b0['markers']=new Map(_0x32d1b7);}['_transformMarkers'](_0x9cef6d){for(const _0x353d85 of this['_markers']['values']()){const _0xaa06c3=_0x353d85['getTransformedByOperation'](_0x9cef6d),_0x2d382b=ft['_createFromRanges'](_0xaa06c3);_0x353d85['start']=_0x2d382b['start'],_0x353d85['end']=_0x2d382b['end'];}}['_handleOperation'](_0x48e12f,_0x391870){if('addRoot'!=_0x48e12f['type']&&'detachRoot'!=_0x48e12f['type']){if('insert'==_0x48e12f['type']){const _0x18782e=_0x48e12f['position']['root']['rootName'];this['_diffRoots']['has'](_0x18782e)||(this['_diffRoots']['set'](_0x18782e,P(_0x18782e,!0x0)),this['_diffRootsAttributes']['set'](_0x18782e,{}),_0x391870&&this['_idsRoots']['set'](_0x18782e,P(_0x18782e,!0x0)));}else{if('addRootAttribute'==_0x48e12f['type']||'removeRootAttribute'==_0x48e12f['type']||'changeRootAttribute'==_0x48e12f['type'])return void this['_handleRootAttributeOperation'](_0x48e12f);'marker'==_0x48e12f['type']&&this['_handleMarkerOperation'](_0x48e12f);}if('marker'!==_0x48e12f['type']){const _0x524ba6=this['_cloneOperation'](_0x48e12f,this['_diffRoots']);_0x524ba6['_execute'](),this['_transformMarkers'](_0x524ba6);}if(_0x391870)switch(_0x48e12f['type']){case'insert':this['_handleInsertOperation'](_0x48e12f);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x48e12f);break;case'merge':this['_handleMergeOperation'](_0x48e12f);break;case'split':this['_handleSplitOperation'](_0x48e12f);}}else this['_handleRootOperation'](_0x48e12f,_0x391870);}['_cloneOperation'](_0x4e9060,_0x18c5b6){const _0x5ec972=_0x4e9060['clone']();return _0x5ec972['_authorId']=_0x4e9060['_authorId'],this['_fixOperation'](_0x5ec972,_0x18c5b6),_0x5ec972;}['_getBaseVids'](_0x533104){return _0x533104['map'](_0x3f729e=>{const _0x23b4b2=this['_getVidAttributeName'](_0x3f729e);return Number(_0x3f729e['item']['getAttribute'](_0x23b4b2));});}['_generateTape'](_0x3df73d,_0x1499ee){if(_0x3df73d['is']('element','$text'))_0x1499ee['push']({'item':_0x3df73d,'type':'text'});else{_0x3df73d['is']('element')&&_0x1499ee['push']({'item':_0x3df73d,'type':'elementStart'});for(const _0x19fcd7 of _0x3df73d['getChildren']())this['_generateTape'](_0x19fcd7,_0x1499ee);_0x3df73d['is']('element')&&_0x1499ee['push']({'item':_0x3df73d,'type':'elementEnd'});}return _0x1499ee;}['_getState'](){const _0x3020ca=new Map(this['_touched']),_0x37de39=new Map(_0x3020ca),_0x1f8611=new Map(),_0xa5570={'insertions':{},'deletions':{}},_0x4f2c9c={'insertions':{},'deletions':{}},_0x25780a=new Map(),_0x1401f7=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x1401f7['delete']('$graveyard');for(const _0x4c9ee4 of _0x1401f7){const _0x1fc220=this['_diffRoots']['get'](_0x4c9ee4)||P(_0x4c9ee4,!0x1),_0x206909=this['_baseRoots']['get'](_0x4c9ee4)||P(_0x4c9ee4,!0x1);_0x1fc220['isAttached']()||_0x206909['isAttached']()?(_0xa5570['insertions'][_0x4c9ee4]=N(_0x1fc220),_0xa5570['deletions'][_0x4c9ee4]=N(_0x206909),this['_copyMarkers'](_0xa5570['deletions'][_0x4c9ee4],_0x206909),this['_copyMarkers'](_0xa5570['insertions'][_0x4c9ee4],_0x1fc220),_0x4f2c9c['insertions'][_0x4c9ee4]=this['_generateTape'](this['_idsRoots']['get'](_0x4c9ee4),[]),_0x4f2c9c['deletions'][_0x4c9ee4]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x4c9ee4)||P(_0x4c9ee4,!0x1),[])):_0x1401f7['delete'](_0x4c9ee4);}for(const _0x244f6a of _0x1401f7){const _0x55eaa0=_0x4f2c9c['insertions'][_0x244f6a];for(const _0x1494a6 of _0x55eaa0){const _0x1be497=this['_getVidAttributeName'](_0x1494a6),_0x11649b=_0x1494a6['item']['getAttribute'](_0x1be497);_0x37de39['delete'](_0x11649b),_0x11649b>=this['_startingRevisionId']&&_0x1f8611['set'](_0x11649b,_0x3020ca['get'](_0x11649b));}}for(const _0x37b9c4 of _0x1401f7){const _0x5ab2cf=_0x4f2c9c['insertions'][_0x37b9c4],_0x488ccf=this['_getBaseVids'](_0x4f2c9c['deletions'][_0x37b9c4]);let _0x857ebe=0x0;for(const _0x633f6a of _0x5ab2cf){const _0x541df7=this['_getVidAttributeName'](_0x633f6a),_0x9cb71=_0x633f6a['item']['getAttribute'](_0x541df7);if(!_0x1f8611['has'](_0x9cb71)&&!_0x25780a['has'](_0x9cb71)){if(_0x37de39['has'](_0x9cb71))_0x857ebe++;else{if(_0x9cb71!=_0x488ccf[_0x857ebe]){const _0x2f2046=_0x3020ca['get'](_0x9cb71)||_0x3020ca['get'](_0x488ccf[_0x857ebe]);for(;_0x9cb71!=_0x488ccf[_0x857ebe];)_0x37de39['has'](_0x488ccf[_0x857ebe])||(_0x25780a['set'](_0x488ccf[_0x857ebe],_0x2f2046),_0x3020ca['set'](_0x488ccf[_0x857ebe],_0x2f2046)),_0x857ebe++;}_0x857ebe++;}}}}for(const _0xd17563 of _0x1401f7){const _0x595052=_0x4f2c9c['insertions'][_0xd17563];for(const _0x394c55 of _0x595052){const _0x28d891=this['_getVidAttributeName'](_0x394c55),_0x1ac0c4=_0x394c55['item']['getAttribute'](_0x28d891);if(_0x25780a['has'](_0x1ac0c4)){const _0x4712ae=_0x25780a['get'](_0x1ac0c4);_0x37de39['has'](_0x1ac0c4)||_0x37de39['set'](_0x1ac0c4,{..._0x4712ae}),_0x1f8611['set'](_0x1ac0c4,{..._0x4712ae});}}}for(const _0x2c3604 of _0x37de39['keys']())_0x2c3604>=this['_startingRevisionId']&&_0x37de39['delete'](_0x2c3604);const _0x296b2f=new Map();for(const _0x424ca0 of _0x1401f7){let _0x394242=_0x4f2c9c['insertions'][_0x424ca0];for(const _0x3e4129 of _0x394242)if(_0x3e4129['item']['is']('element','tableCell')){const _0x504fe2=this['_getVidAttributeName'](_0x3e4129),_0x4797cd=_0x3e4129['item']['getAttribute'](_0x504fe2);if(_0x1f8611['has'](_0x4797cd)){const _0x31aca8=_0x3e4129['item']['parent']['parent']['getAttribute']('vid_start'),_0x32df1f=_0x296b2f['get'](_0x31aca8)||new Set();_0x32df1f['add'](_0x1f8611['get'](_0x4797cd)['userId']),_0x296b2f['set'](_0x31aca8,_0x32df1f);}}_0x394242=_0x4f2c9c['deletions'][_0x424ca0];for(const _0x41e1e4 of _0x394242)if(_0x41e1e4['item']['is']('element','tableCell')){const _0x2bd75e=this['_getVidAttributeName'](_0x41e1e4),_0x7e74d2=_0x41e1e4['item']['getAttribute'](_0x2bd75e);if(_0x37de39['has'](_0x7e74d2)){const _0x32e1d2=_0x41e1e4['item']['parent']['parent']['getAttribute']('vid_start'),_0x252713=_0x296b2f['get'](_0x32e1d2)||new Set();_0x252713['add'](_0x37de39['get'](_0x7e74d2)['userId']),_0x296b2f['set'](_0x32e1d2,_0x252713);}}for(const _0x10ecf3 of _0x296b2f['keys']())(_0x1f8611['has'](_0x10ecf3)||_0x37de39['has'](_0x10ecf3))&&_0x296b2f['delete'](_0x10ecf3);}for(const _0xd1b7fa of _0x1401f7){const _0x41d0ae=_0x4f2c9c['insertions'][_0xd1b7fa];let _0x13f46b=null,_0x2a3e32=null;for(const _0x1c027d of _0x41d0ae){const _0x23455e=this['_getVidAttributeName'](_0x1c027d),_0x4ac3b6=_0x1c027d['item']['getAttribute'](_0x23455e),_0x5c2e58=_0x296b2f['get'](_0x4ac3b6);_0x5c2e58&&'elementStart'==_0x1c027d['type']&&(_0x13f46b=Array['from'](_0x5c2e58)[0x0],_0x2a3e32=_0x1c027d['item']['getAttribute']('vid_end')),_0x13f46b&&(_0x37de39['set'](_0x4ac3b6,{'userId':_0x13f46b}),_0x1f8611['set'](_0x4ac3b6,{'userId':_0x13f46b})),_0x4ac3b6==_0x2a3e32&&(_0x13f46b=null,_0x2a3e32=null);}}const _0xa0f5cb={},_0x2a9618=new Set();for(const _0x84a165 of _0x1401f7){const _0x287fc3=_0xa5570['deletions'][_0x84a165],_0x23974f=_0xa5570['insertions'][_0x84a165];for(const {userId:_0x4b1f73}of this['_touchedMarkers']['values']())null!==_0x4b1f73&&_0x2a9618['add'](_0x4b1f73);for(const {userId:_0x56ecb4}of this['_touchedRoots']['values']())null!==_0x56ecb4&&_0x2a9618['add'](_0x56ecb4);this['_markChanges'](_0x23974f,_0x4f2c9c['insertions'][_0x84a165],_0x1f8611,'insertion',_0x2a9618),this['_markChanges'](_0x287fc3,_0x4f2c9c['deletions'][_0x84a165],_0x37de39,'deletion',_0x2a9618),_0xa0f5cb[_0x84a165]={'insertions':this['_prepareViewToSave'](_0x23974f),'deletions':this['_prepareViewToSave'](_0x287fc3),'attachChange':this['_touchedRoots']['get'](_0x84a165)||null,'attributesBefore':_0x503a70(this['_baseRootsAttributes']['get'](_0x84a165))||{},'attributesAfter':_0x503a70(this['_diffRootsAttributes']['get'](_0x84a165))};}return{'diffData':_0xa0f5cb,'authorsIds':Array['from'](_0x2a9618)};}['_processRootBeforeSave'](_0x5749b2){for(const [,_0x10e9cd]of _0x5749b2['markers']){const _0x198175=_0x10e9cd['start']['getAncestors']()['filter'](_0x5911b9=>'tableCell'==_0x5911b9['name']);for(const _0x463b21 of _0x198175)0x1==_0x463b21['childCount']&&_0x463b21['getChild'](0x0)['is']('element','paragraph')&&_0x463b21['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x168134){this['_processRootBeforeSave'](_0x168134);const _0x2d1667=this['editor']['data']['toView'](_0x168134,{}),_0x2e9f13=Array['from'](_0x2d1667['getChildren']())['map'](_0x381b62=>this['_getViewJson'](_0x381b62));return JSON['stringify'](_0x2e9f13);}['_getViewJson'](_0x4df3d2){if(_0x4df3d2['is']('$text'))return _0x4df3d2['data'];{const _0x4cdf9d=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0x33d834=_0x4df3d2,_0x34390d=this['editor']['data']['htmlProcessor']['domConverter'],_0x4d96a8={'type':_0x4cdf9d['_getTypeCharForViewElement'](_0x33d834),'name':_0x33d834['name'],'attributes':Array['from'](_0x33d834['getAttributes']()),'children':Array['from'](_0x33d834['getChildren']())['map'](_0x4adb9d=>this['_getViewJson'](_0x4adb9d))};if(_0x4df3d2['is']('uiElement')&&'$comment'!=_0x4df3d2['name']){const _0x2e788d=_0x4df3d2['render'](_0x34390d['domDocument'],_0x34390d);_0x4d96a8['children']['push'](_0x2e788d['outerHTML']);}else{if(_0x4df3d2['is']('rawElement')){const _0x55cb90=_0x34390d['domDocument']['createElement'](_0x33d834['name']);_0x4df3d2['render'](_0x55cb90,_0x34390d),_0x4d96a8['children']['push'](_0x55cb90['innerHTML']);}}const _0x1b3fa0=Array['from'](_0x33d834['getCustomProperties']());_0x1b3fa0['length']>0x0&&(_0x4d96a8['customProperties']=_0x1b3fa0);const _0x33981e=_0x33d834['getFillerOffset']();return null!==_0x33981e&&(_0x4d96a8['fillerOffset']=_0x33981e),_0x4d96a8;}}['_markChanges'](_0x54642f,_0x5961bd,_0x2a7cf9,_0x217791,_0x2a1669){let _0x2af4c5=null,_0x7b34d4=null,_0x5306bc=0x0;const _0x1864ea=this['editor']['model'];for(let _0x289e3d=0x0;_0x289e3d<_0x5961bd['length'];_0x289e3d++){const _0x286b17=this['_getVidAttributeName'](_0x5961bd[_0x289e3d]),_0x144a16=_0x5961bd[_0x289e3d]['item']['getAttribute'](_0x286b17),_0x55011b=_0x2a7cf9['get'](_0x144a16),_0x106538=_0x289e3d==_0x5961bd['length']-0x1;(!_0x2af4c5&&_0x55011b&&(_0x2af4c5=_0x55011b,_0x7b34d4=_0x5961bd[_0x289e3d]),_0x2af4c5&&(!_0x55011b||_0x55011b['userId']!=_0x2af4c5['userId']))&&(_0x42e02a(_0x55011b,F(_0x7b34d4,_0x54642f,_0x1864ea),F(_0x5961bd[_0x289e3d],_0x54642f,_0x1864ea)),_0x2af4c5=_0x55011b||null,_0x7b34d4=_0x55011b?_0x5961bd[_0x289e3d]:null),_0x2af4c5&&_0x106538&&_0x42e02a(_0x55011b,F(_0x7b34d4,_0x54642f,_0x1864ea),B(_0x5961bd[_0x289e3d],_0x54642f,_0x1864ea));}function _0x42e02a(_0xf32d64,_0x31d401,_0x672d04){const _0x137ef4=_0x2af4c5['userId'],_0x5ef1aa='revision:'+_0x217791+':'+_0x137ef4+':'+_0x5306bc++,_0x5b66dd=_0x1864ea['createRange'](_0x31d401,_0x672d04);_0x54642f['markers']['set'](_0x5ef1aa,_0x5b66dd),null!==_0x137ef4&&_0x2a1669['add'](_0x137ef4);}}['_getVidAttributeName'](_0xa5a328){switch(_0xa5a328['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x144b45,_0xbda5b){_0x144b45['baseVersion']=null;for(const _0x505192 in _0x144b45){const _0x17fa01=_0x144b45[_0x505192];if(_0x17fa01 instanceof vt){const _0x2192f1=_0xbda5b['get'](_0x17fa01['root']['rootName']);_0x144b45[_0x505192]=this['_fixPosition'](_0x17fa01,_0x2192f1);}if(_0x17fa01 instanceof ft){const _0x4b8dbf=_0xbda5b['get'](_0x17fa01['root']['rootName']);_0x144b45[_0x505192]=this['_fixRange'](_0x17fa01,_0x4b8dbf);}'root'===_0x505192&&(_0x144b45['root']=_0xbda5b['get'](_0x144b45['root']['rootName']));}}['_fixRange'](_0x2f3de7,_0x380aac){return this['editor']['model']['createRange'](this['_fixPosition'](_0x2f3de7['start'],_0x380aac),this['_fixPosition'](_0x2f3de7['end'],_0x380aac));}['_fixPosition'](_0x1dd9d9,_0x446ca9){return this['editor']['model']['createPositionFromPath'](_0x446ca9,_0x1dd9d9['path'],_0x1dd9d9['stickiness']);}['_handleInsertOperation'](_0x5aeac2){const _0x1e2945=this['_idsRoots']['get'](_0x5aeac2['position']['root']['rootName']),_0x322256=this['_fixPosition'](_0x5aeac2['position'],_0x1e2945),_0x407c5b=null===_0x5aeac2['_authorId']?null:_0x5aeac2['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x2bbab6=_0x322256['parent'],_0x5b0ae9=this['_revisionId'],_0x1abccd=[];for(const _0x3465f6 of _0x5aeac2['nodes'])if(_0x3465f6['is']('element'))_0x1abccd['push'](this['_makeIdsRoot'](_0x3465f6));else{for(let _0x1c629a=0x0;_0x1c629a<_0x3465f6['offsetSize'];_0x1c629a++)_0x1abccd['push'](new ut('$text',{'vid':this['_revisionId']++}));}const _0x1abd2e=this['_revisionId'];for(let _0x2d40ec=_0x5b0ae9;_0x2d40ec<_0x1abd2e;_0x2d40ec++)this['_touched']['set'](_0x2d40ec,{'userId':_0x407c5b});_0x2bbab6['_insertChild'](_0x322256['offset'],_0x1abccd);}['_handleMoveOperation'](_0x3ca2da){(_0x3ca2da=this['_cloneOperation'](_0x3ca2da,this['_idsRoots']))['_execute']();const _0x217419=null===_0x3ca2da['_authorId']?null:_0x3ca2da['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x3bcc39=_0x3ca2da['getMovedRangeStart'](),_0x1ed8ca=_0x3bcc39['parent'],_0x27d991=_0x3bcc39['offset'];!function _0x4ce0f4(_0x541adc,_0x120e30,_0x49e4f6,_0x11a14d){for(let _0x80469c=_0x49e4f6;_0x80469c<_0x11a14d;_0x80469c++){const _0x4d3ccc=_0x120e30['getChild'](_0x80469c);_0x4d3ccc['is']('element','$text')?_0x541adc['set'](_0x4d3ccc['getAttribute']('vid'),{'userId':_0x217419}):(_0x541adc['set'](_0x4d3ccc['getAttribute']('vid_start'),{'userId':_0x217419}),_0x4ce0f4(_0x541adc,_0x4d3ccc,0x0,_0x4d3ccc['childCount']),_0x541adc['set'](_0x4d3ccc['getAttribute']('vid_end'),{'userId':_0x217419}));}}(this['_touched'],_0x1ed8ca,_0x27d991,_0x27d991+_0x3ca2da['howMany']);}['_handleMergeOperation'](_0x186c59){const _0x3351ad=null===(_0x186c59=this['_cloneOperation'](_0x186c59,this['_idsRoots']))['_authorId']?null:_0x186c59['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x220f55=_0x186c59['targetPosition']['parent'],_0x102d3d=_0x186c59['sourcePosition']['parent'],_0x774019=_0x220f55['getAttribute']('vid_end'),_0x3dab56=_0x102d3d['getAttribute']('vid_start');_0x220f55['_setAttribute']('vid_end',_0x102d3d['getAttribute']('vid_end')),_0x102d3d['_setAttribute']('vid_end',_0x774019),this['_touched']['set'](_0x3dab56,{'userId':_0x3351ad}),this['_touched']['set'](_0x774019,{'userId':_0x3351ad}),_0x186c59['_execute']();}['_handleSplitOperation'](_0x3b17a6){const _0x284ce3=null===(_0x3b17a6=this['_cloneOperation'](_0x3b17a6,this['_idsRoots']))['_authorId']?null:_0x3b17a6['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x5bd68d=_0x3b17a6['graveyardPosition'],_0x429f04=_0x3b17a6['splitPosition']['parent'];_0x3b17a6['_execute']();const _0x36242d=_0x429f04['getAttribute']('vid_end'),_0x4d7ec4=_0x3b17a6['insertionPosition']['nodeAfter'];if(_0x5bd68d){const _0x5784a6=_0x4d7ec4['getAttribute']('vid_end'),_0x36377b=_0x429f04['getAttribute']('vid_end');_0x429f04['_setAttribute']('vid_end',_0x5784a6),_0x4d7ec4['_setAttribute']('vid_end',_0x36377b),this['_touched']['set'](_0x429f04['getAttribute']('vid_end'),{'userId':_0x284ce3}),this['_touched']['set'](_0x4d7ec4['getAttribute']('vid_start'),{'userId':_0x284ce3});}else{const _0x4ea1cf=this['_revisionId']++,_0x26f18=this['_revisionId']++;_0x429f04['_setAttribute']('vid_end',_0x4ea1cf),_0x4d7ec4['_setAttribute']('vid_start',_0x26f18),_0x4d7ec4['_setAttribute']('vid_end',_0x36242d),this['_touched']['set'](_0x4ea1cf,{'userId':_0x284ce3}),this['_touched']['set'](_0x26f18,{'userId':_0x284ce3});}}['_handleMarkerOperation'](_0x53f456){if(!_0x53f456['affectsData'])return;const _0x55d50f=(_0x53f456=this['_cloneOperation'](_0x53f456,this['_diffRoots']))['oldRange']?_0x53f456['oldRange']['root']:null,_0x12877a=_0x53f456['newRange']?_0x53f456['newRange']['root']:null;_0x55d50f&&this['_markers']['delete'](_0x53f456['name']),_0x12877a&&this['_markers']['set'](_0x53f456['name'],_0x53f456['newRange']['clone']());const _0x291c2a=null===_0x53f456['_authorId']?null:_0x53f456['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x5507fc=_0x53f456['name'];if(!this['_touchedMarkers']['has'](_0x5507fc))return void this['_touchedMarkers']['set'](_0x5507fc,{'range':_0x53f456['oldRange'],'userId':_0x291c2a});const _0x4848e3=this['_touchedMarkers']['get'](_0x5507fc),_0x3958a1=_0x4848e3['range'],_0x2a2c20=_0x53f456['newRange'];null==_0x3958a1&&null==_0x2a2c20||_0x3958a1&&_0x2a2c20&&_0x3958a1['isEqual'](_0x2a2c20)?this['_touchedMarkers']['delete'](_0x53f456['name']):_0x4848e3['userId']=_0x291c2a;}['_handleRootOperation'](_0x417b8b,_0x17d13a){this['_diffRoots']['has'](_0x417b8b['rootName'])?this['_diffRoots']['get'](_0x417b8b['rootName'])['_isAttached']=_0x417b8b['isAdd']:(this['_diffRoots']['set'](_0x417b8b['rootName'],P(_0x417b8b['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x417b8b['rootName'],{}),_0x17d13a&&this['_idsRoots']['set'](_0x417b8b['rootName'],P(_0x417b8b['rootName'],!0x0)));const _0x64f540=null===_0x417b8b['_authorId']?null:_0x417b8b['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x4ecc70=this['_touchedRoots']['get'](_0x417b8b['rootName']);_0x4ecc70&&_0x4ecc70['userId']===_0x64f540?this['_touchedRoots']['delete'](_0x417b8b['rootName']):this['_touchedRoots']['set'](_0x417b8b['rootName'],{'userId':_0x64f540,'isAttached':_0x417b8b['isAdd']});}['_handleRootAttributeOperation'](_0xc96653){const _0x55e981=this['_diffRootsAttributes']['get'](_0xc96653['root']['rootName']);null===_0xc96653['newValue']?delete _0x55e981[_0xc96653['key']]:_0x55e981[_0xc96653['key']]=_0xc96653['newValue'];}}function N(_0x1d3294){const _0x2e0ef4=P(_0x1d3294['rootName'],_0x1d3294['isAttached']());for(const _0x1d30d0 of _0x1d3294['getChildren']()){const _0x798d0a=_0x1d30d0['_clone'](!0x0);_0x2e0ef4['_appendChild'](_0x798d0a);}return _0x2e0ef4;}function P(_0x10a460,_0x9d48ca=!0x0){const _0x8f8e66=new gt();return _0x8f8e66['rootName']=_0x10a460,_0x8f8e66['_isAttached']=_0x9d48ca,_0x8f8e66['isAttached']=()=>_0x8f8e66['_isAttached'],_0x8f8e66;}function F(_0x13fe72,_0x5091c7,_0x3f3915){const _0x278e19='elementEnd'==_0x13fe72['type']?_0x3f3915['createPositionAt'](_0x13fe72['item'],'end'):_0x3f3915['createPositionBefore'](_0x13fe72['item']);return _0x3f3915['createPositionFromPath'](_0x5091c7,_0x278e19['path'],_0x278e19['stickiness']);}function B(_0x5c17a6,_0x50929e,_0x39e966){const _0xe9d4e2='elementStart'==_0x5c17a6['type']?_0x39e966['createPositionAt'](_0x5c17a6['item'],0x0):_0x39e966['createPositionAfter'](_0x5c17a6['item']);return _0x39e966['createPositionFromPath'](_0x50929e,_0xe9d4e2['path'],_0xe9d4e2['stickiness']);}class os extends _0x328aa1{['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x5dd03f,_0x4426b6){super(_0x5dd03f),this['focusTracker']=new _0x2cbbc2(),this['keystrokes']=new _0x498725(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x4426b6),this['setTemplate']({'tag':'form','attributes':{'class':['ck','ck-revision-history-save-revision-form','ck-responsive-form'],'tabindex':'-1'},'children':[this['revisionNameInputView']]}),ts(this);}['render'](){super['render'](),_0x48d35c({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0xc8db94=_0x2c2a2d=>_0x2c2a2d['stopPropagation']();this['keystrokes']['set']('arrowright',_0xc8db94),this['keystrokes']['set']('arrowleft',_0xc8db94),this['keystrokes']['set']('arrowup',_0xc8db94),this['keystrokes']['set']('arrowdown',_0xc8db94);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0xe2d23a){this['revisionNameInputView']['fieldView']['element']['value']=_0xe2d23a['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x215ee5){const _0x391a8d=new nt(this['locale'],ti),_0x29e865=_0x391a8d['fieldView'];_0x29e865['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x42967a=g(this['locale'],'Name\x20of\x20the\x20revision');return!_0x215ee5&&(_0x42967a+='\x20('+g(this['locale'],'optional')+')'),(_0x391a8d['label']=_0x42967a,_0x29e865['on']('input',()=>{this['revisionNameInputValue']=_0x29e865['element']['value']['trim']();}),_0x391a8d);}}class f extends _0x310a6b{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u];}['_saveRevisionFormView'];['init'](){const _0x59b7b3=this['editor'],_0xceee62=_0x59b7b3['plugins']['get']('RevisionTracker');_0x59b7b3['ui']['componentFactory']['add']('revisionHistory',_0x4eda7d=>{const _0x3a0716=_0x49a6db(_0x4eda7d),_0x253e49=_0x3a0716['panelView']['children'],_0x2b7c71=new _0x40d04c(_0x4eda7d),_0x103f99=new te(_0x4eda7d),_0x297a1d=new _0x4e381a(_0x4eda7d),_0x30756a=new te(_0x4eda7d),_0x486e68=new _0x4e381a(_0x4eda7d);return _0x3a0716['bind']('isEnabled')['to'](_0xceee62,'isReady',_0xceee62,'isEnabled',_0x59b7b3,'isReadOnly',(_0x183a5d,_0xe89d26,_0x1cd61c)=>_0x183a5d&&_0xe89d26&&!_0x1cd61c),_0x3a0716['buttonView']['set']({'icon':_0x4e40f2,'label':g(_0x4eda7d,'Revision\x20history'),'tooltip':!0x0}),_0x297a1d['set']({'label':g(_0x4eda7d,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x297a1d['bind']('isEnabled')['to'](_0xceee62,'isReady',_0xceee62,'isEnabled',_0x59b7b3,'isReadOnly',(_0x185aa6,_0x1cdb86,_0x5253b8)=>_0x185aa6&&_0x1cdb86&&!_0x5253b8),_0x297a1d['on']('execute',()=>this['_showDialog']()),_0x486e68['set']({'label':g(_0x4eda7d,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x486e68['bind']('isEnabled')['to'](_0xceee62,'isReady',_0x59b7b3,'isReadOnly',(_0x1958b5,_0x414dee)=>_0x1958b5&&!_0x414dee),_0x486e68['on']('execute',()=>{_0x59b7b3['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x3a0716['isOpen']=!0x1,_0x59b7b3['editing']['view']['focus']();}),_0x103f99['children']['add'](_0x297a1d),_0x30756a['children']['add'](_0x486e68),_0x2b7c71['role']='menu',_0x2b7c71['items']['addMany']([_0x103f99,_0x30756a]),_0x253e49['add'](_0x2b7c71),_0x3a0716;}),_0x59b7b3['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x5ceaa1=this['editor'],_0x5878c0=_0x5ceaa1['locale'],_0x26a733=new _0x3b7261(_0x5878c0),_0x3a80fe=new _0x237439(_0x5878c0);_0x26a733['buttonView']['set']({'icon':_0x4e40f2,'label':g(_0x5878c0,'Revision\x20history')});const _0x323810=new _0x31da87(_0x5878c0,_0x26a733),_0x374eb5=new _0x2a56a1(_0x5878c0);_0x374eb5['set']({'label':g(_0x5878c0,'Save\x20current\x20revision')}),_0x374eb5['delegate']('execute')['to'](_0x26a733),_0x374eb5['on']('execute',()=>{this['_showDialog']();}),_0x323810['children']['add'](_0x374eb5),_0x3a80fe['items']['add'](_0x323810);const _0x5e15cf=new _0x31da87(_0x5878c0,_0x26a733),_0x143345=new _0x2a56a1(_0x5878c0);return _0x143345['set']({'label':g(_0x5878c0,'Open\x20revision\x20history')}),_0x143345['delegate']('execute')['to'](_0x26a733),_0x143345['on']('execute',()=>{_0x5ceaa1['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x5e15cf['children']['add'](_0x143345),_0x3a80fe['items']['add'](_0x5e15cf),_0x26a733['panelView']['children']['add'](_0x3a80fe),_0x26a733;}['_showDialog'](){const _0x465b7d=this['editor'],_0x1a706b=_0x465b7d['locale'],_0x17303a=_0x465b7d['plugins']['get']('Dialog'),_0x31c9c0=_0x465b7d['plugins']['get']('RevisionTracker');function _0x5b01be(_0xcdad59){_0x465b7d['config']['get']('revisionHistory.requireRevisionName')&&''===_0xcdad59['revisionName']?_0xcdad59['revisionNameInputView']['errorText']=g(_0x1a706b,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x465b7d['plugins']['get'](u)['saveRevision']({'name':_0xcdad59['revisionName']}),_0x17303a['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x5b01be(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x17303a['show']({'id':'revisionSave','title':g(_0x1a706b,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':g(_0x465b7d['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x17303a['hide']()},{'label':g(_0x465b7d['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x445716){_0x445716['bind']('isEnabled')['to'](_0x31c9c0,'isReady',_0x31c9c0,'isEnabled',_0x465b7d,'isReadOnly',(_0x2493e5,_0x17bd44,_0x243f7d)=>_0x2493e5&&_0x17bd44&&!_0x243f7d);},'onExecute':()=>_0x5b01be(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0xafc187=this['editor'],_0x456288=_0xafc187['locale'];this['_saveRevisionFormView']=new os(_0x456288,_0xafc187['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class Q extends _0x328aa1{['changeId'];['_model'];constructor(_0x18ecd7,_0x4cd157){super(_0x18ecd7),this['_model']=_0x4cd157,this['changeId']=_0x4cd157['id'];const _0x5d202b=this['bindTemplate'],_0x19f429=g(_0x18ecd7,_0x4cd157['data']['isSuggestion']?'Suggested\x20by':'add'==_0x4cd157['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x4cd157['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x5d202b['to']('type',_0x1fe745=>'ck-revision-change__'+_0x1fe745)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x19f429}]},{'text':'\x20'+_0x4cd157['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class r extends/* #__PURE__ -- @preserve */
25
+ _0x59fa04(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x11102b){super(),this['id']=_0x11102b['id']||_0x46489c(),this['author']=_0x11102b['author'],this['type']=_0x11102b['type'],this['data']=_0x11102b['data']||{},this['rootName']=_0x11102b['rootName'],this['set']('createdAt',_0x11102b['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(_0x380e0e,_0x234b54){this['newRevisionId']=_0x380e0e,this['oldRevisionId']=_0x234b54,this['changes']=new _0x204bd9();}['_setChanges'](_0x1117e2){for(const _0x2a852f of _0x1117e2)this['changes']['add'](_0x2a852f);}}class m extends _0x310a6b{['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[_0x49a6e3,_0x37c732,I,V];}constructor(_0x211cb8){super(_0x211cb8),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',(_0x10b06c,_0x2cbe6c,_0x4d48a5)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x57a08c=>{for(const _0x329af2 of this['editor']['editing']['view']['document']['roots'])_0x4d48a5?_0x57a08c['removeClass']('ck-editor__editable__overlay',_0x329af2):_0x57a08c['addClass']('ck-editor__editable__overlay',_0x329af2);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x1330fe=>null!==_0x1330fe),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x4d525b,_0x5efb5a,_0x1165e6)=>_0x4d525b&&_0x1165e6?_0x5efb5a['changes']['getIndex'](_0x1165e6):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x5c3d25,_0x182865)=>_0x5c3d25?_0x182865['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0x37c732);}['init'](){const _0x2cbc33=this['editor'],_0x11d72e=new pt(_0x2cbc33,{'direction':'backward'}),_0x5969f9=new pt(_0x2cbc33,{'direction':'forward'});(_0x2cbc33['commands']['add']('showPreviousChange',_0x11d72e),_0x2cbc33['commands']['add']('showNextChange',_0x5969f9),_0x2cbc33['commands']['add']('restoreRevision',new wt(_0x2cbc33)),this['on']('change:numberOfChanges',()=>{_0x11d72e['refresh'](),_0x5969f9['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x2cbc33['enableReadOnlyMode']('revision-viewer'),_0x2cbc33['plugins']['has']('WidgetToolbarRepository'))&&_0x2cbc33['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x53d176){return await this['_utils']['loadRevisionData'](_0x53d176,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x53d176);}async['getRevisionRootsAttributes'](_0xd152a9){return await this['_utils']['loadRevisionData'](_0xd152a9,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0xd152a9);}async['compare'](_0x4869f6,_0x12246c,_0xce2b92=!0x1){if(!this['isEnabled'])return;const _0x4d17c3=this['diff'],_0x25198d=this['repository'],_0x4af4e8='string'==typeof _0x4869f6?_0x25198d['getRevision'](_0x4869f6):_0x4869f6,_0x5c234c='string'==typeof _0x12246c?_0x25198d['getRevision'](_0x12246c):_0x12246c,_0x4b829b=_0x4af4e8['id'],_0x25bb6a=_0x5c234c?_0x5c234c['id']:null;if(!_0xce2b92&&this['diff']&&this['diff']['newRevisionId']===_0x4b829b&&this['diff']['oldRevisionId']===_0x25bb6a)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new c(_0x4b829b,_0x25bb6a);const _0x575a7d=this['_getRevisionsRange'](_0x4af4e8,_0x5c234c,!0x0)['map'](_0x47e385=>this['_utils']['loadRevisionData'](_0x47e385,this['adapter']));return _0x575a7d['push'](new Promise(_0x473ce5=>{setTimeout(_0x473ce5,0x14);})),Promise['all'](_0x575a7d)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x3c7b24=this['_getDiff'](_0x4b829b,_0x25bb6a);for(const _0x326d7d of _0x3c7b24['changes'])this['_changeIdToChange']['set'](_0x326d7d['id'],_0x326d7d);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x2626ce=>{for(const _0x4d343e of this['editor']['model']['document']['getRootNames']())_0x2626ce['detachRoot'](_0x4d343e);for(const _0x5e6fbe of Object['keys'](_0x3c7b24['model'])){const _0x36e8a9=_0x2626ce['addRoot'](_0x5e6fbe);for(const _0x26e33a of Object['keys'](_0x3c7b24['attributes'][_0x5e6fbe]))_0x2626ce['setAttribute'](_0x26e33a,_0x3c7b24['attributes'][_0x5e6fbe][_0x26e33a],_0x36e8a9);_0x2626ce['insert'](_0x3c7b24['model'][_0x5e6fbe],_0x36e8a9,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x3c7b24['changes'])),this['isReady']=!0x0;})['catch'](_0x62f5b1=>{console['error'](_0x62f5b1),this['_cleanUp'](),_0x4d17c3&&(this['diff']=_0x4d17c3),this['isReady']=!0x0;});}['addRevisionData'](_0x13cf06,_0xc0e4c7){const _0x4b5a06=this['repository']['createRevision'](_0x13cf06);return _0x4b5a06['on']('_update',(_0x4ccb1a,_0xdde6cb,_0x33cbd3)=>_0xc0e4c7(_0xdde6cb,_0x33cbd3,_0x4b5a06)),this['repository']['addRevision'](_0x4b5a06),_0x4b5a06;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x1905a8=>{for(const _0x28d4b3 of this['editor']['model']['document']['getRootNames']())_0x1905a8['detachRoot'](_0x28d4b3);});}['_sortAndFilterDiffChanges'](_0x4bad02){const _0x5c95ca=[],_0x222a74=new Map();for(const _0x3ecb55 of this['editor']['model']['document']['getRootNames']()){const _0x313a22=this['editor']['editing']['view']['getDomRoot'](_0x3ecb55);if(!_0x313a22)continue;const _0x3bfe96=_0x313a22['getClientRects']()['item'](0x0);_0x3bfe96&&(_0x5c95ca['push'](_0x3ecb55),_0x222a74['set'](_0x3ecb55,_0x3bfe96));}return _0x5c95ca['sort']((_0xeedc89,_0x1a2291)=>{const _0x30d02d=_0x222a74['get'](_0xeedc89),_0x19989b=_0x222a74['get'](_0x1a2291);return _0x30d02d['y']-_0x19989b['y']||_0x30d02d['x']-_0x19989b['x'];}),(_0x4bad02=_0x4bad02['filter'](_0x1147d9=>_0x5c95ca['includes'](_0x1147d9['rootName'])))['sort']((_0x7a55c8,_0x45d572)=>_0x5c95ca['indexOf'](_0x7a55c8['rootName'])-_0x5c95ca['indexOf'](_0x45d572['rootName'])),_0x4bad02;}['_makeTape'](_0x4186c9){const _0x5623c5=Array['from'](_0x4186c9['markers'])['filter'](([_0x1a4f35,_0x234178])=>_0x1a4f35['startsWith']('revision:')&&!_0x234178['isCollapsed']),_0xdb2dda=Array['from'](this['editor']['model']['createRangeIn'](_0x4186c9)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x5623c5['length'])for(const _0x115c19 of _0xdb2dda){const [_0x2750f5,_0x9845cd]=_0x5623c5[0x0],[,_0x204b49,_0x298645]=_0x2750f5['split'](':');if(_0x9845cd['end']['isEqual'](_0x115c19['nextPosition'])&&_0x5623c5['shift'](),(_0x115c19['previousPosition']['isEqual'](_0x9845cd['start'])||_0x115c19['previousPosition']['isAfter'](_0x9845cd['start']))&&('insertion'==_0x204b49?_0x115c19['isAdded']={'userId':_0x298645}:'deletion'==_0x204b49&&(_0x115c19['isRemoved']={'userId':_0x298645})),0x0==_0x5623c5['length'])break;}return _0xdb2dda;}['_refreshStartEndIndex'](_0x5d34d7){const _0x42f46f=new Map();for(let _0x3c3c78=0x0;_0x3c3c78<_0x5d34d7['length'];_0x3c3c78++)'text'===_0x5d34d7[_0x3c3c78]['type']?(_0x5d34d7[_0x3c3c78]['item']['startIndex']=_0x3c3c78,_0x5d34d7[_0x3c3c78]['item']['endIndex']=_0x3c3c78):('elementStart'===_0x5d34d7[_0x3c3c78]['type']?_0x5d34d7[_0x3c3c78]['item']['startIndex']=_0x3c3c78:'elementEnd'===_0x5d34d7[_0x3c3c78]['type']&&(_0x5d34d7[_0x3c3c78]['item']['endIndex']=_0x3c3c78),_0x42f46f['set'](_0x5d34d7[_0x3c3c78]['id'],_0x3c3c78));for(const _0x1b08b4 of _0x42f46f['values']())'elementStart'===_0x5d34d7[_0x1b08b4]['type']?_0x5d34d7[_0x1b08b4]['item']['endIndex']=_0x42f46f['get'](_0x5d34d7[_0x1b08b4]['pairId']):'elementEnd'===_0x5d34d7[_0x1b08b4]['type']&&(_0x5d34d7[_0x1b08b4]['item']['startIndex']=_0x42f46f['get'](_0x5d34d7[_0x1b08b4]['pairId']));}['_processTape'](_0x1ce938){for(let _0x185c77=0x0;_0x185c77<_0x1ce938['length'];_0x185c77++){if('elementStart'===_0x1ce938[_0x185c77]['type'])_0x1ce938[_0x185c77]['item']['startIndex']=_0x185c77;else{if('elementEnd'===_0x1ce938[_0x185c77]['type']){_0x1ce938[_0x185c77]['item']['endIndex']=_0x185c77;const _0x308acd=_0x1ce938[_0x185c77]['item']['startIndex'];_0x1ce938[_0x308acd]['pairId']=_0x1ce938[_0x185c77]['id'],_0x1ce938[_0x185c77]['pairId']=_0x1ce938[_0x308acd]['id'];}else _0x1ce938[_0x185c77]['item']['startIndex']=_0x185c77,_0x1ce938[_0x185c77]['item']['endIndex']=_0x185c77,_0x1ce938[_0x185c77]['pairId']=null;}_0x1ce938[_0x185c77]['markersStart']||(_0x1ce938[_0x185c77]['markersStart']=[],_0x1ce938[_0x185c77]['markersEnd']=[]);}}['_markInsertions'](_0x2c1206,_0x4ac493){const _0x352969=_0x2c1206['filter'](_0x2ed486=>!_0x2ed486['isAdded']);for(let _0x4e52e8=0x0;_0x4e52e8<_0x4ac493['length'];_0x4e52e8++)_0x4ac493[_0x4e52e8]['isAdded']&&(_0x352969[_0x4e52e8]['isAdded']=_0x4ac493[_0x4e52e8]['isAdded']);}['_getDiff'](_0x2b5ca3,_0x23a0c5=null){const _0x176681=this['repository']['getRevision'](_0x2b5ca3),_0x4e0cb8=_0x23a0c5?this['repository']['getRevision'](_0x23a0c5):null,_0x5b84d3=this['_getRevisionsRange'](_0x176681,_0x4e0cb8),_0x2c335d=_0x5b84d3[_0x5b84d3['length']-0x1],_0x4f035c=new Map(),_0x57d837={'model':{},'attributes':{},'changes':[]},_0x238074=new Set(),_0x22cec2=new Map();for(let _0x112ec2=_0x5b84d3['length']-0x1;_0x112ec2>=0x0;_0x112ec2--){const _0x5b53ea=_0x5b84d3[_0x112ec2];for(const _0x47b2da of Object['keys'](_0x5b53ea['diffData']))if(_0x5b53ea['diffData'][_0x47b2da]['attachChange']){const _0x59aa76=_0x5b53ea['diffData'][_0x47b2da]['attachChange'];_0x59aa76['isAttached']?(_0x238074['add'](_0x47b2da),_0x22cec2['has'](_0x47b2da)&&_0x22cec2['get'](_0x47b2da)['userId']==_0x59aa76['userId']?_0x22cec2['delete'](_0x47b2da):_0x22cec2['set'](_0x47b2da,_0x59aa76)):_0x22cec2['has'](_0x47b2da)?(_0x238074['delete'](_0x47b2da),_0x22cec2['delete'](_0x47b2da)):(_0x238074['add'](_0x47b2da),_0x22cec2['set'](_0x47b2da,_0x59aa76));}else _0x238074['add'](_0x47b2da);}for(const _0x2e93aa of _0x238074){const _0x5d8c14=_0x22cec2['has'](_0x2e93aa)&&!_0x22cec2['get'](_0x2e93aa)['isAttached'];let _0x452cac=_0x5d8c14?_0x5b84d3['length']-0x1:0x0;const _0xc167af=_0x5d8c14?-0x1:0x1;for(;_0x5b84d3[_0x452cac];){const _0x233a3b=_0x5b84d3[_0x452cac];if(_0x233a3b['diffData'][_0x2e93aa]){const _0x4c923b=_0x5d8c14?_0x233a3b['diffData'][_0x2e93aa]['attributesBefore']:_0x233a3b['diffData'][_0x2e93aa]['attributesAfter'];_0x57d837['attributes'][_0x2e93aa]=_0x4c923b?_0x503a70(_0x4c923b):{};break;}_0x452cac+=_0xc167af;}}for(const _0xcbfa4b of _0x5b84d3){_0xcbfa4b['model']={};for(const _0x10c18c of _0xcbfa4b['authors'])_0x4f035c['set'](_0x10c18c['id'],_0x10c18c);for(const _0x1f1e5b of _0x238074){const _0x1843cf=_0xcbfa4b['diffData'][_0x1f1e5b]?_0xcbfa4b['diffData'][_0x1f1e5b]['insertions']:'[]',_0xcc1eea=_0xcbfa4b['diffData'][_0x1f1e5b]?_0xcbfa4b['diffData'][_0x1f1e5b]['deletions']:'[]';_0xcbfa4b['model'][_0x1f1e5b]={'insertions':this['_utils']['_makeModelFromViewString'](_0x1843cf),'deletions':this['_utils']['_makeModelFromViewString'](_0xcc1eea)};}}for(const _0x132267 of _0x238074){let _0x162362=null,_0x16c5aa=0x0;const _0x293d78=new Map(Array['from'](_0x176681['model'][_0x132267]['insertions']['markers'])['filter'](([_0x212dc7])=>!_0x212dc7['startsWith']('revision:')));let _0x1c3daa=0x0;for(const _0x52b208 of _0x5b84d3){const _0x43584d=this['_makeTape'](_0x52b208['model'][_0x132267]['insertions']);_0x52b208==_0x176681?(_0x162362=_0x43584d,_0x16c5aa=_0x162362['length'],_0x162362['forEach'](_0x57678b=>{_0x57678b['id']=_0x1c3daa++;}),this['_processTape'](_0x162362)):this['_markInsertions'](_0x162362,_0x43584d);const _0x2dad9d=_0x162362['filter'](_0x50bce3=>!_0x50bce3['isAdded'])['map'](_0x3a1217=>_0x3a1217['id']);let _0x7fa5e0=0x0;const _0x1af72a=this['_makeTape'](_0x52b208['model'][_0x132267]['deletions']);_0x1af72a['forEach'](_0x2427d7=>{_0x2427d7['isRemoved']?_0x2427d7['id']=_0x16c5aa++:_0x2427d7['id']=_0x2dad9d[_0x7fa5e0++];}),this['_processTape'](_0x1af72a),this['_setDistance'](_0x162362,'isAdded'),this['_setDistance'](_0x1af72a,'isRemoved'),_0x52b208==_0x176681&&this['_markMarkers'](_0x162362,_0x293d78),_0x162362=this['_joinTapes'](_0x162362,_0x1af72a),this['_refreshStartEndIndex'](_0x162362),this['_setDistance'](_0x162362,'isRemoved');}_0x162362=_0x162362['filter'](_0x3db106=>!(_0x3db106['isAdded']&&_0x3db106['isRemoved']));const _0x20f14d=new Map(_0x2c335d['model'][_0x132267]['deletions']['markers']),_0x1dd4cc=new Set(_0x293d78['keys']());for(const _0x3926cd of _0x20f14d['keys']())_0x1dd4cc['delete'](_0x3926cd);this['_markSuggestions'](_0x162362,_0x1dd4cc),this['_fixObsoleteTags'](_0x162362),_0x162362=this['_removeMissingPairs'](_0x162362),_0x162362=this['_markMismatchedRemovedTags'](_0x162362),_0x162362=this['_removeUnsupportedChanges'](_0x162362);const {root:_0x2b4243,changes:_0x2605d4}=this['_makeModelFromTape'](_0x162362,_0x4f035c,_0x132267);_0x57d837['model'][_0x132267]=_0x2b4243;const _0x21338e=_0x22cec2['get'](_0x132267);if(_0x21338e){const _0x199808=_0x4f035c['get'](_0x21338e['userId']),_0xe010d8=new r({'author':_0x199808,'type':_0x21338e['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x132267});_0x2605d4['unshift'](_0xe010d8),_0x57d837['attributes'][_0x132267]['revisionHistoryAttachChange']=_0xe010d8['id'];}_0x57d837['changes']=_0x57d837['changes']['concat'](_0x2605d4);}return _0x57d837;}['_markMarkers'](_0x39c0b3,_0x1be65e){for(let _0x343173=0x0;_0x343173<_0x39c0b3['length'];_0x343173++)for(const [_0x360067,_0x4004a8]of _0x1be65e)!_0x4004a8['isCollapsed']&&_0x4004a8['start']['isEqual'](_0x39c0b3[_0x343173]['previousPosition'])&&_0x39c0b3[_0x343173]['markersStart']['push'](_0x360067),_0x4004a8['end']['isEqual'](_0x39c0b3[_0x343173]['nextPosition'])&&_0x39c0b3[_0x343173]['markersEnd']['push'](_0x360067);}['_joinTapes'](_0x5b99aa,_0x23c2da){let _0x55e346=[],_0x3fca5b=0x0,_0x3b774b=0x0;for(;_0x3fca5b<_0x5b99aa['length']||_0x3b774b<_0x23c2da['length'];){const _0x1930e4=_0x5b99aa[_0x3fca5b]||{},_0x1998c2=_0x23c2da[_0x3b774b]||{};if(_0x1930e4['id']==_0x1998c2['id'])_0x3fca5b++,_0x3b774b++,_0x55e346['push'](_0x1930e4);else{if(_0x1998c2['isRemoved']&&_0x1930e4['isAdded']){const {commonTape:_0x5e7ad0,iEnd:_0x51cc69,jEnd:_0x271b28}=this['_threeWayMerge'](_0x5b99aa,_0x3fca5b,_0x23c2da,_0x3b774b);_0x55e346=_0x55e346['concat'](_0x5e7ad0),_0x3fca5b=_0x51cc69,_0x3b774b=_0x271b28;}else _0x1998c2['isRemoved']?(_0x3b774b++,_0x55e346['push'](_0x1998c2)):(_0x3fca5b++,_0x55e346['push'](_0x1930e4));}}return _0x55e346;}['_markSuggestions'](_0x236547,_0x51f7b3){const _0x51b3a3=[];for(let _0x490a21=0x0;_0x490a21<_0x236547['length'];_0x490a21++){for(let _0x5ad259=0x0;_0x5ad259<_0x236547[_0x490a21]['markersStart']['length'];_0x5ad259++){const _0x2efa7b=_0x236547[_0x490a21]['markersStart'][_0x5ad259];if(!_0x51f7b3['has'](_0x2efa7b))continue;const {group:_0xe43e68,type:_0x5b454b,authorId:_0x4c3403}=_0x14e3ef(_0x2efa7b);'revision-suggestion'!=_0xe43e68||'insertion'!=_0x5b454b&&'deletion'!=_0x5b454b||(_0x51b3a3['unshift']({'type':_0x5b454b,'name':_0x2efa7b,'userId':_0x4c3403}),_0x236547[_0x490a21]['markersStart']['splice'](_0x5ad259,0x1),_0x5ad259--);}_0x39d36b(_0x236547[_0x490a21]);for(let _0x3c654a=0x0;_0x3c654a<_0x236547[_0x490a21]['markersEnd']['length'];_0x3c654a++){const _0x4993ea=_0x236547[_0x490a21]['markersEnd'][_0x3c654a];if(!_0x51f7b3['has'](_0x4993ea))continue;const {group:_0x4c2623,type:_0x6d5e91}=_0x14e3ef(_0x4993ea);if('revision-suggestion'!=_0x4c2623||'insertion'!=_0x6d5e91&&'deletion'!=_0x6d5e91)continue;_0x236547[_0x490a21]['markersEnd']['splice'](_0x3c654a,0x1),_0x3c654a--;const _0x85ca5e=_0x51b3a3['findIndex'](_0x1612e9=>_0x1612e9['name']==_0x4993ea);_0x85ca5e>-0x1&&_0x51b3a3['splice'](_0x85ca5e,0x1);}}function _0x14e3ef(_0x5dc8d7){const _0xffc9cf=_0x5dc8d7['split'](':');return{'group':_0xffc9cf[0x0],'type':_0xffc9cf[0x1],'subType':_0xffc9cf['length']>=0x5?_0xffc9cf[0x2]:null,'id':_0xffc9cf['length']<0x5?_0xffc9cf[0x2]:_0xffc9cf[0x3],'authorId':_0xffc9cf['length']<0x5?_0xffc9cf[0x3]:_0xffc9cf[0x4],'markerCount':0x6==_0xffc9cf['length']?_0xffc9cf[0x5]:null};}function _0x39d36b(_0x5394a8){for(let _0x4f9329=0x0;_0x4f9329<_0x51b3a3['length'];_0x4f9329++){if(_0x5394a8['isAdded']&&'insertion'==_0x51b3a3[_0x4f9329]['type'])return _0x5394a8['isAddSuggestion']=_0x51b3a3[_0x4f9329],void delete _0x5394a8['isAdded'];if(!_0x5394a8['isAdded']&&!_0x5394a8['isRemoved']&&'deletion'==_0x51b3a3[_0x4f9329]['type'])return void(_0x5394a8['isRemoveSuggestion']=_0x51b3a3[_0x4f9329]);}}}['_setDistance'](_0x4d7d45,_0x24a9bd){let _0x2e8588=0x0,_0x18e8f1=!0x1;const _0xc2925c=new Map();for(const _0x153be8 of _0x4d7d45)_0x153be8[_0x24a9bd]?_0x18e8f1&&(_0x2e8588++,_0x18e8f1=!0x1):(_0x2e8588++,_0x18e8f1=!0x0),_0xc2925c['set'](_0x153be8['id'],_0x2e8588);for(let _0x4a9e0e=0x0;_0x4a9e0e<_0x4d7d45['length'];_0x4a9e0e++){if('isRemoved'==_0x24a9bd&&_0x4d7d45[_0x4a9e0e]['isAdded']||'isAdded'==_0x24a9bd&&_0x4d7d45[_0x4a9e0e]['isRemoved'])continue;if('text'==_0x4d7d45[_0x4a9e0e]['type']){_0x4d7d45[_0x4a9e0e]['distance']=0x0;continue;}const _0x37ac67=_0xc2925c['get'](_0x4d7d45[_0x4a9e0e]['pairId']),_0x8fd2b0=_0xc2925c['get'](_0x4d7d45[_0x4a9e0e]['id']);_0x4d7d45[_0x4a9e0e]['distance']=_0x37ac67-_0x8fd2b0;}}['_getRevisionsRange'](_0x126e09,_0x123dbb,_0x1ceaa6=!0x1){const _0x25bf2c=[];let _0x14c77=this['repository']['getIndex'](_0x126e09),_0x467e7d=this['repository']['getIndex'](_0x123dbb);for(-0x1==_0x467e7d&&(_0x467e7d=this['repository']['_revisions']['length'],_0x1ceaa6=!0x1);_0x14c77<_0x467e7d;)_0x25bf2c['push'](this['repository']['getRevision'](_0x14c77)),_0x14c77++;return _0x1ceaa6&&_0x25bf2c['push'](this['repository']['getRevision'](_0x14c77)),_0x25bf2c;}['_threeWayMerge'](_0x57245c,_0x43b945,_0x358e5f,_0x106f05){const _0x5dc582=this['editor']['model']['schema'];let _0x2dbc76=_0x43b945;for(;_0x57245c[_0x2dbc76]&&_0x57245c[_0x2dbc76]['isAdded'];)_0x2dbc76++;let _0x45e9f1=_0x106f05;for(;_0x358e5f[_0x45e9f1]&&_0x358e5f[_0x45e9f1]['isRemoved'];)_0x45e9f1++;_0x27be27(_0x57245c,_0x43b945,_0x2dbc76),_0x27be27(_0x358e5f,_0x106f05,_0x45e9f1);const _0x4eb804=_0x358e5f['slice'](_0x106f05,_0x45e9f1)['concat'](_0x57245c['slice'](_0x43b945,_0x2dbc76));return _0x4eb804['sort']((_0x272bf6,_0x15db98)=>_0x272bf6['side']!=_0x15db98['side']?_0x272bf6['side']-_0x15db98['side']:_0x272bf6['level']!=_0x15db98['level']?_0x272bf6['level']-_0x15db98['level']:_0x272bf6['distance']!=_0x15db98['distance']?_0x15db98['distance']-_0x272bf6['distance']:!!_0x272bf6['isAdded']!=!!_0x15db98['isAdded']?-0x1==_0x272bf6['side']||0x0==_0x272bf6['side']?_0x272bf6['isAdded']?-0x1:0x1:_0x272bf6['isAdded']?0x1:-0x1:_0x272bf6['index']-_0x15db98['index']),{'commonTape':_0x4eb804,'iEnd':_0x2dbc76,'jEnd':_0x45e9f1};function _0x27be27(_0x4471ac,_0x3caba5,_0xd25edc){let _0x475050=-0x1,_0x199220=Number['POSITIVE_INFINITY'],_0xcdaade=!0x0;for(let _0x232422=_0x3caba5;_0x232422<_0xd25edc;_0x232422++)if(_0x5dc582['isInline'](_0x4471ac[_0x232422]['item'])||(_0xcdaade=!0x1),_0x4471ac[_0x232422]['item']['startIndex']<_0x3caba5&&(_0x475050=_0x232422),_0x4471ac[_0x232422]['item']['endIndex']>=_0xd25edc){_0x199220=_0x232422;break;}_0xcdaade&&(_0x475050=_0xd25edc-0x1);for(let _0x13f78d=_0x3caba5;_0x13f78d<_0xd25edc;_0x13f78d++)_0x4471ac[_0x13f78d]['side']=_0x13f78d<=_0x475050?-0x1:_0x13f78d<_0x199220?0x0:0x1,_0x4471ac[_0x13f78d]['index']=_0x13f78d;let _0x42aad9=0x0;for(let _0x353822=_0x3caba5;_0x353822<=_0x475050;_0x353822++)0x0==_0x4471ac[_0x353822]['distance']?_0x4471ac[_0x353822]['level']=_0x42aad9:(_0x42aad9++,_0x4471ac[_0x353822]['level']=_0x42aad9,_0x42aad9++);for(let _0x4ce9d5=_0x3caba5;_0x4ce9d5<_0xd25edc;_0x4ce9d5++)0x0==_0x4471ac[_0x4ce9d5]['side']&&(_0x4471ac[_0x4ce9d5]['level']=_0x42aad9);_0x42aad9=0x0;for(let _0x5ef2b1=_0xd25edc-0x1;_0x5ef2b1>=_0x199220;_0x5ef2b1--)0x0==_0x4471ac[_0x5ef2b1]['distance']?_0x4471ac[_0x5ef2b1]['level']=_0x42aad9:(_0x42aad9--,_0x4471ac[_0x5ef2b1]['level']=_0x42aad9,_0x42aad9--);}}['_fixObsoleteTags'](_0x1deaca){const _0x3e0b5d=new Map(),_0x51494b=this['editor']['model']['schema'];for(let _0x45e320=0x1;_0x45e320<_0x1deaca['length'];_0x45e320++){let _0x2b1d9e,_0x2bde57,_0x2eee88;const _0x3af83d=_0x1deaca[_0x45e320],_0x3dbf94=_0x1deaca[_0x45e320-0x1];if('text'==_0x3af83d['type'])continue;if(_0x3af83d['type']!=_0x3dbf94['type'])continue;if(!_0x51494b['isBlock'](_0x3dbf94['item'])||_0x51494b['isLimit'](_0x3dbf94['item']))continue;if(!_0x51494b['isBlock'](_0x3af83d['item'])||_0x51494b['isLimit'](_0x3af83d['item']))continue;if((_0x1deaca[_0x45e320]['isAdded']||_0x1deaca[_0x45e320]['isAddSuggestion'])&&_0x1deaca[_0x45e320-0x1]['isRemoved'])_0x2b1d9e=_0x1deaca[_0x45e320],_0x2bde57=_0x1deaca[_0x45e320-0x1],_0x2eee88=_0x45e320-0x1;else{if(!_0x1deaca[_0x45e320]['isRemoved']||!_0x1deaca[_0x45e320-0x1]['isAdded']&&!_0x1deaca[_0x45e320-0x1]['isAddSuggestion'])continue;_0x2b1d9e=_0x1deaca[_0x45e320-0x1],_0x2bde57=_0x1deaca[_0x45e320],_0x2eee88=_0x45e320;}const _0x2ec881=_0x2b1d9e['level']==_0x2bde57['level'],_0x2acb8a=Math['abs'](_0x2b1d9e['level'])<Math['abs'](_0x2bde57['level'])&&0x0==_0x2bde57['distance'];(_0x2ec881||_0x2acb8a)&&(_0x3e0b5d['set'](_0x2bde57['id'],_0x2b1d9e['id']),_0x1deaca['splice'](_0x2eee88,0x1),_0x45e320--,_0x2b1d9e['isAdded']=!0x1);}for(let _0x1bc07d=0x0;_0x1bc07d<_0x1deaca['length'];_0x1bc07d++)_0x3e0b5d['has'](_0x1deaca[_0x1bc07d]['pairId'])&&(_0x1deaca[_0x1bc07d]['pairId']=_0x3e0b5d['get'](_0x1deaca[_0x1bc07d]['pairId']));}['_removeMissingPairs'](_0x59abbd){const _0x32dfe6=new Set(_0x59abbd['map'](_0x387ac2=>_0x387ac2['id']));for(let _0x17b7ff=0x0;_0x17b7ff<_0x59abbd['length'];_0x17b7ff++)_0x32dfe6['has'](_0x59abbd[_0x17b7ff]['pairId'])||0x0==_0x59abbd[_0x17b7ff]['distance']||(_0x59abbd[_0x17b7ff]['isIncorrect']=!0x0);return _0x59abbd['filter'](_0x1b28a3=>!_0x1b28a3['isIncorrect']);}['_markMismatchedRemovedTags'](_0x155753){const _0x4f5850=new Set();for(let _0x2926ca=0x0;_0x2926ca<_0x155753['length'];_0x2926ca++){if(_0x4f5850['has'](_0x155753[_0x2926ca]['id'])&&_0x155753[_0x2926ca]['isRemoved']&&(_0x155753[_0x2926ca]['isIncorrect']=!0x0),_0x155753[_0x2926ca]['isIncorrect'])continue;if(0x0==_0x155753[_0x2926ca]['distance'])continue;if('elementStart'!=_0x155753[_0x2926ca]['type'])continue;if(null==_0x155753[_0x2926ca]['pairId'])continue;let _0x4914d9=_0x2926ca+0x1,_0x1b07c9=0x0;for(;_0x155753[_0x4914d9]['id']!=_0x155753[_0x2926ca]['pairId'];)'elementStart'==_0x155753[_0x4914d9]['type']?_0x1b07c9++:'elementEnd'==_0x155753[_0x4914d9]['type']&&_0x1b07c9--,_0x4914d9++;if(0x0!=_0x1b07c9){if(_0x155753[_0x2926ca]['isRemoved'])_0x155753[_0x2926ca]['isIncorrect']=!0x0;else{for(;_0x4914d9!=_0x2926ca;)_0x155753[_0x4914d9]['isRemoved']&&0x0!=_0x155753[_0x4914d9]['distance']&&(_0x155753[_0x4914d9]['isIncorrect']=!0x0,_0x4f5850['add'](_0x155753[_0x4914d9]['pairId'])),_0x4914d9--;}}}return _0x155753['filter'](_0x58140d=>!_0x58140d['isIncorrect']);}['_removeUnsupportedChanges'](_0x4b12e9){const _0x21612f=this['editor']['model']['schema'];for(let _0x5eab82=0x0;_0x5eab82<_0x4b12e9['length'];_0x5eab82++){if(!(_0x4b12e9[_0x5eab82]['isAdded']||_0x4b12e9[_0x5eab82]['isAddSuggestion']||_0x4b12e9[_0x5eab82]['isRemoved']||_0x4b12e9[_0x5eab82]['isRemoveSuggestion']))continue;if(0x0==_0x4b12e9[_0x5eab82]['distance'])continue;const _0x5f2f04=_0x4b12e9[_0x5eab82]['item'];_0x21612f['isBlock'](_0x5f2f04)||_0x21612f['isLimit'](_0x5f2f04)||(_0x4b12e9[_0x5eab82]['isAdded']&&delete _0x4b12e9[_0x5eab82]['isAdded'],_0x4b12e9[_0x5eab82]['isAddSuggestion']&&delete _0x4b12e9[_0x5eab82]['isAddSuggestion'],_0x4b12e9[_0x5eab82]['isRemoveSuggestion']&&delete _0x4b12e9[_0x5eab82]['isRemoveSuggestion'],_0x4b12e9[_0x5eab82]['isRemoved']&&(_0x4b12e9[_0x5eab82]['isIncorrect']=!0x0));}return _0x4b12e9['filter'](_0x9c8ad1=>!_0x9c8ad1['isIncorrect']);}['_makeModelFromTape'](_0x5e23c3,_0x49c5d8,_0x407d79){const _0x181fda=new gt(),_0x312eaa=[],_0x3d655c=new Map(),_0x56585b=this['editor']['model'],_0x1ba938=_0x56585b['schema'],_0x4e9b7b=[_0x181fda],_0x16d8af={},_0x47e3df={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x33c9c6=null;const _0x297b78=[0x0];for(let _0x40c717=0x0;_0x40c717<_0x5e23c3['length'];_0x40c717++)if('elementStart'===_0x5e23c3[_0x40c717]['type']){_0x5e23c3[_0x40c717]['previousPosition']=_0x56585b['createPositionFromPath'](_0x181fda,_0x297b78);const _0x7b4884=new ut(_0x5e23c3[_0x40c717]['item']['name'],_0x5e23c3[_0x40c717]['item']['getAttributes']());_0x4e9b7b[0x0]['_appendChild'](_0x7b4884),_0x297b78['push'](0x0),_0x4e9b7b['unshift'](_0x7b4884),_0x5e23c3[_0x40c717]['nextPosition']=_0x56585b['createPositionFromPath'](_0x181fda,_0x297b78);}else'elementEnd'===_0x5e23c3[_0x40c717]['type']?(_0x4e9b7b['shift'](),_0x5e23c3[_0x40c717]['previousPosition']=_0x56585b['createPositionFromPath'](_0x181fda,_0x297b78),_0x297b78['pop'](),_0x297b78[_0x297b78['length']-0x1]++,_0x5e23c3[_0x40c717]['nextPosition']=_0x56585b['createPositionFromPath'](_0x181fda,_0x297b78)):(_0x5e23c3[_0x40c717]['previousPosition']=_0x56585b['createPositionFromPath'](_0x181fda,_0x297b78),_0x33c9c6?_0x33c9c6['_data']+=_0x5e23c3[_0x40c717]['item']['data']:_0x33c9c6=new mt(_0x5e23c3[_0x40c717]['item']['data'],_0x5e23c3[_0x40c717]['item']['getAttributes']()),_0x5e23c3[_0x40c717+0x1]&&'text'===_0x5e23c3[_0x40c717+0x1]['type']&&_0xd4313b(_0x33c9c6,_0x5e23c3[_0x40c717+0x1]['item'])||(_0x4e9b7b[0x0]['_appendChild'](_0x33c9c6),_0x33c9c6=null),_0x297b78[_0x297b78['length']-0x1]+=_0x5e23c3[_0x40c717]['item']['offsetSize'],_0x5e23c3[_0x40c717]['nextPosition']=_0x56585b['createPositionFromPath'](_0x181fda,_0x297b78));for(let _0x166349=0x0;_0x166349<_0x5e23c3['length'];_0x166349++){const _0x6e8ec2=_0x5e23c3[_0x166349]['previousPosition'],_0x5a99f0=_0x5e23c3[_0x166349]['nextPosition'];for(const _0x4acc4e of _0x5e23c3[_0x166349]['markersStart'])_0x3d655c['set'](_0x4acc4e,{'start':_0x6e8ec2,'end':null});_0x1a122a('isRemoveSuggestion',_0x166349,_0x6e8ec2,_0x5a99f0),_0x1a122a('isAddSuggestion',_0x166349,_0x6e8ec2,_0x5a99f0),_0x1a122a('isRemoved',_0x166349,_0x6e8ec2,_0x5a99f0),_0x1a122a('isAdded',_0x166349,_0x6e8ec2,_0x5a99f0);for(const _0x4e02ad of _0x5e23c3[_0x166349]['markersEnd']){const _0x47b4a0=_0x3d655c['get'](_0x4e02ad);_0x47b4a0?_0x47b4a0['end']=_0x5a99f0:_0x3d655c['set'](_0x4e02ad,{'start':_0x5a99f0,'end':_0x5a99f0});}}for(const [_0x3894cf,_0x2886f9]of _0x3d655c){const _0x52832e=this['editor']['model']['createRange'](_0x2886f9['start'],_0x2886f9['end']);_0x181fda['markers']['set'](_0x3894cf,_0x52832e);}return _0x312eaa['sort']((_0x162f58,_0x48d6a0)=>{const _0x9dce93=_0x181fda['markers']['get']('revision:'+_0x162f58['id']),_0x55e332=_0x181fda['markers']['get']('revision:'+_0x48d6a0['id']);return _0x9dce93['start']['isBefore'](_0x55e332['start'])?-0x1:_0x9dce93['start']['isAfter'](_0x55e332['start'])?0x1:_0x9dce93['end']['isBefore'](_0x55e332['end'])?-0x1:_0x9dce93['end']['isAfter'](_0x55e332['end'])?0x1:'add'===_0x162f58['type']?-0x1:0x1;}),{'root':_0x181fda,'changes':_0x312eaa};function _0x1a122a(_0x20761f,_0x54a8ba,_0x1c7c0f,_0x2c54e3){const _0x1580e1=!!_0x5e23c3[_0x54a8ba][_0x20761f],_0x194756=_0x1580e1?_0x5e23c3[_0x54a8ba][_0x20761f]['userId']:null,_0x42de33=_0x54a8ba===_0x5e23c3['length']-0x1,_0x172d89=_0x47e3df[_0x20761f][0x0],_0x37cd03=_0x1ba938['isObject'](_0x5e23c3[_0x54a8ba]['item']);!_0x16d8af[_0x20761f]&&_0x1580e1?_0x16d8af[_0x20761f]={'start':_0x1c7c0f,'tapeItem':_0x5e23c3[_0x54a8ba],'userId':_0x194756,'type':_0x20761f}:_0x16d8af[_0x20761f]&&!_0x1580e1?(_0x16d8af[_0x20761f]['end']=_0x1c7c0f,_0x147089(_0x16d8af[_0x20761f]),_0x16d8af[_0x20761f]=null):_0x16d8af[_0x20761f]&&_0x1580e1&&_0x16d8af[_0x20761f]['userId']!==_0x194756&&(_0x16d8af[_0x20761f]['end']=_0x1c7c0f,_0x172d89&&_0x172d89['userId']===_0x16d8af[_0x20761f]['userId']||_0x147089(_0x16d8af[_0x20761f]),_0x16d8af[_0x20761f]={'start':_0x1c7c0f,'tapeItem':_0x5e23c3[_0x54a8ba],'userId':_0x194756,'type':_0x20761f}),_0x16d8af[_0x20761f]&&_0x37cd03&&('elementStart'!==_0x5e23c3[_0x54a8ba]['type']||_0x172d89&&_0x172d89['userId']===_0x194756||_0x47e3df[_0x20761f]['unshift']({'userId':_0x194756,'object':_0x5e23c3[_0x54a8ba]['item'],'change':_0x16d8af[_0x20761f]}),'elementEnd'===_0x5e23c3[_0x54a8ba]['type']&&_0x172d89&&_0x172d89['object']===_0x5e23c3[_0x54a8ba]['item']&&(_0x47e3df[_0x20761f]['shift'](),_0x16d8af[_0x20761f]=_0x172d89['change'])),_0x16d8af[_0x20761f]&&_0x42de33&&(_0x16d8af[_0x20761f]['end']=_0x2c54e3,_0x147089(_0x16d8af[_0x20761f]),_0x16d8af[_0x20761f]=null);}function _0x147089({start:_0xf293d4,end:_0x47e607,tapeItem:_0xd84084,userId:_0x304fce,type:_0xa44c02}){const _0x22a641=_0xd84084['item'],_0x4b6ebe=_0x56585b['schema']['isBlock'](_0x22a641)&&!_0x56585b['schema']['isLimit'](_0x22a641),_0x574d0f=_0xf293d4['nodeAfter']==_0x47e607['parent']&&_0x47e607['isAtStart'];if(_0x4b6ebe&&_0x574d0f)return;const _0x5bf0ea=_0x56585b['createRange'](_0xf293d4,_0x47e607),_0x58b5b0=_0x49c5d8['get'](_0x304fce),_0x5e0da4=new r({'author':_0x58b5b0,'type':'isAdded'==_0xa44c02||'isAddSuggestion'==_0xa44c02?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0xa44c02||'isRemoveSuggestion'==_0xa44c02},'createdAt':new Date(),'rootName':_0x407d79});_0x312eaa['push'](_0x5e0da4),_0x181fda['markers']['set']('revision:'+_0x5e0da4['id'],_0x5bf0ea);}function _0xd4313b(_0xf91285,_0x12d281){const _0x7785a5=_0xf91285['getAttributes'](),_0x3e0195=_0x12d281['getAttributes']();for(const _0x5174e8 of _0x7785a5){if(_0x5174e8[0x1]!==_0x12d281['getAttribute'](_0x5174e8[0x0]))return!0x1;_0x3e0195['next']();}return _0x3e0195['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x33ad8e=>{const _0x1745be=_0x33ad8e['markerName']['split'](':')[0x1],_0x32d97a=this['_getChangeFromId'](_0x1745be);if(!_0x32d97a)return null;const _0x4a8662='add'==_0x32d97a['type']?'insertion':'deletion',_0x2db8bd=['ck-suggestion-marker','ck-suggestion-marker-'+_0x4a8662];return _0x32d97a['data']['isSuggestion']&&_0x2db8bd['push']('ck-suggestion-marker-'+_0x4a8662+'-new'),this['activeChange']==_0x32d97a&&_0x2db8bd['push']('ck-suggestion-marker--active'),{'classes':_0x2db8bd,'attributes':{'data-change-id':_0x1745be}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x46e5a7=>{_0x46e5a7['on']('element:pre',(_0x2ef00e,_0x158786,_0xbd0977)=>{const _0x16b612=_0x158786['viewItem']['getChild'](0x0);if(!_0x16b612||!_0x16b612['is']('element','code'))return;if(!_0xbd0977['consumable']['consume'](_0x16b612,{'attributes':['vid_start','vid_end']}))return;const _0x3cbe5f=_0x158786['modelRange']['start']['nodeAfter'];_0xbd0977['writer']['setAttribute']('vid_start',_0x16b612['getAttribute']('vid_start'),_0x3cbe5f),_0xbd0977['writer']['setAttribute']('vid_end',_0x16b612['getAttribute']('vid_end'),_0x3cbe5f);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x510899=>{_0x510899['on']('element',(_0x417534,_0x5970c3,_0x1e81a2)=>{if(!_0x1e81a2['consumable']['consume'](_0x5970c3['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x5970c3['modelRange']['isCollapsed'])return;const _0x55987b=_0x5970c3['modelRange']['start']['nodeAfter'];_0x55987b['hasAttribute']('vid_start')||_0x55987b['hasAttribute']('vid')||(_0x1e81a2['writer']['setAttribute']('vid_start',_0x5970c3['viewItem']['getAttribute']('vid_start'),_0x55987b),_0x1e81a2['writer']['setAttribute']('vid_end',_0x5970c3['viewItem']['getAttribute']('vid_end'),_0x55987b));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x2e376f=>_0x2e376f['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x25880d,[,_0x2f6fde])=>{['vid_start','vid_end','vid']['includes'](_0x2f6fde)&&(_0x25880d['return']=!0x0,_0x25880d['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x5b1638=>{_0x5b1638['on']('attribute:vid',(_0x2f8439,_0x12db15,_0x5bad1f)=>{if('\x20'!=_0x12db15['item']['data']||_0x12db15['item']['parent']['maxOffset']>0x1)return;if(!_0x5bad1f['consumable']['consume'](_0x12db15['item'],_0x2f8439['name']))return;const _0x595263=_0x5bad1f['writer'],_0x47eb01=_0x5bad1f['mapper']['toViewRange'](_0x12db15['range']);_0x595263['wrap'](_0x47eb01,_0x595263['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x277848){const _0x617bf0=_0x277848['plugins']['get']('RevisionViewer');return(_0x3ab7c0,_0x597471,_0x2539cf)=>{const _0x1000b2=_0x597471['markerName']['split'](':')[0x1],_0x56110c=_0x617bf0['_getChangeFromId'](_0x1000b2);if(!_0x56110c)return null;const _0x31032a='add'==_0x56110c['type']?'split':'merge';if(!_0x2539cf['consumable']['test'](_0x597471['markerRange'],_0x3ab7c0['name']))return;const _0x1c1f1f=_0x597471['markerRange']['getWalker'](),_0x428d4c=_0x597471['markerRange']['start'],_0x3d9be1=_0x277848['model']['schema'];let _0x4d7e5a=null,_0x342283=null,_0x3a9a46=!0x1,_0x5cbaa6=!0x1;for(const _0x5d5e4c of _0x1c1f1f){const _0x3d449c=_0x5d5e4c['item'];_0x3a9a46=_0x3a9a46||_0x3d9be1['isContent'](_0x3d449c);const _0x1bfd0b=_0x2539cf['mapper']['toViewElement'](_0x3d449c);if(_0x1bfd0b&&_0x1bfd0b['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x5d5e4c['type']&&(_0x3d9be1['isBlock'](_0x3d449c)&&!_0x3d9be1['isLimit'](_0x3d449c)&&(_0x3d449c['nextSibling']||_0x428d4c['isAtEnd']?_0x4d7e5a&&_0x4d7e5a['parent']==_0x3d449c||(_0x4d7e5a=_0x3d449c,_0xc0a37c(_0x5d5e4c['previousPosition']),_0x5cbaa6=!0x0):_0x342283=_0x342283||_0x5d5e4c['previousPosition']));}function _0xc0a37c(_0xeb5310){const _0x55ff62=_0x2539cf['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x31032a}),_0x2eee58=_0x2539cf['mapper']['toViewPosition'](_0xeb5310);_0x56110c['data']['isSuggestion']&&_0x2539cf['writer']['addClass']('ck-suggestion-marker-'+_0x31032a+'-new',_0x55ff62),_0x617bf0['activeChange']==_0x56110c&&_0x2539cf['writer']['addClass']('ck-suggestion-marker--active',_0x55ff62),_0x2539cf['writer']['insert'](_0x2eee58,_0x55ff62),_0x2539cf['mapper']['bindElementToMarker'](_0x55ff62,_0x597471['markerName']);}_0x3a9a46||_0x5cbaa6||!_0x342283||_0xc0a37c(_0x342283);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x2138ee,_0x4929af,_0x2e966f)=>{const _0x3434c4=_0x2e966f['mapper']['markerNameToElements'](_0x4929af['markerName']);if(_0x3434c4){for(const _0x49b95f of _0x3434c4)(_0x49b95f['hasClass']('ck-suggestion-marker-split')||_0x49b95f['hasClass']('ck-suggestion-marker-merge'))&&(_0x2e966f['mapper']['unbindElementFromMarkerName'](_0x49b95f,_0x4929af['markerName']),_0x2e966f['writer']['remove'](_0x49b95f));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x4b4638,_0x35c2c9,_0x4e0c89)=>{const _0x3dba69=_0x35c2c9['markerName']['split'](':')[0x1],_0x480108=this['_getChangeFromId'](_0x3dba69);if(!_0x480108)return null;const _0x573c44='add'==_0x480108['type']?'split':'merge';if(_0x4e0c89['consumable']['test'](_0x35c2c9['markerRange'],_0x4b4638['name']))for(const _0x9ae8d3 of _0x35c2c9['markerRange']['getItems']()){if(!_0x9ae8d3['is']('element','softBreak'))continue;const _0x4b0f15=_0x4e0c89['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x573c44}),_0x394578=_0x4e0c89['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x9ae8d3));_0x480108['data']['isSuggestion']&&_0x4e0c89['writer']['addClass']('ck-suggestion-marker-'+_0x573c44+'-new',_0x4b0f15),this['activeChange']==_0x480108&&_0x4e0c89['writer']['addClass']('ck-suggestion-marker--active',_0x4b0f15),_0x4e0c89['writer']['insert'](_0x394578,_0x4b0f15),_0x4e0c89['mapper']['bindElementToMarker'](_0x4b0f15,_0x35c2c9['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x36ca21=>{for(const _0xf2ca06 of this['editor']['model']['document']['getRootNames']()){const _0x2a51d6=this['editor']['model']['document']['getRoot'](_0xf2ca06),_0x46b268=this['editor']['editing']['view']['document']['getRoot'](_0xf2ca06);if(_0x46b268){const _0x3f6563=_0x2a51d6['getAttribute']('revisionHistoryAttachChange');if(_0x36ca21['removeAttribute']('data-change-id',_0x46b268),_0x36ca21['removeClass']('ck-revision-history-root-add',_0x46b268),_0x36ca21['removeClass']('ck-revision-history-root-remove',_0x46b268),_0x36ca21['removeClass']('ck-revision-history-root--active',_0x46b268),_0x3f6563){const _0x137844=this['_getChangeFromId'](_0x3f6563);if(!_0x137844)return null;_0x36ca21['setAttribute']('data-change-id',_0x3f6563,_0x46b268),_0x36ca21['addClass']('ck-revision-history-root-'+_0x137844['type'],_0x46b268),this['activeChange']==_0x137844&&_0x36ca21['addClass']('ck-revision-history-root--active',_0x46b268);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x365a28=>'revision-comment:'+_0x365a28,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x2ff54e=>'revision-suggestion:'+_0x2ff54e,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x2f3d2b=>({'name':'suggestion:'+_0x2f3d2b,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x2c0e3f=>{const _0x30af69=_0x2c0e3f['markerName']['split'](':')[0x1];return'insertion'!=_0x30af69&&'deletion'!=_0x30af69?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x30af69]};}}),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',(_0x1ccbf9,_0x5ee668,_0x2dd271)=>{const _0x1a52bc=_0x2dd271['mapper']['markerNameToElements'](_0x5ee668['markerName']);if(_0x1a52bc){for(const _0x149fe5 of _0x1a52bc)_0x149fe5['is']('uiElement')&&(_0x2dd271['mapper']['unbindElementFromMarkerName'](_0x149fe5,_0x5ee668['markerName']),_0x2dd271['writer']['remove'](_0x149fe5));}},{'priority':'high'});}['_getChangeFromId'](_0x36d3ab){return this['_changeIdToChange']['get'](_0x36d3ab);}['_getViewForChange'](_0xf43688){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new Q(this['editor']['locale'],_0xf43688),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x35891f,_0x5953af,_0x5dd3d5,_0x36fa26)=>{_0x36fa26&&this['_balloon']['remove'](_0x36fa26),_0x5dd3d5&&(this['_balloon']['add']({'view':_0x5dd3d5,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x24fabc=this['editor']['editing'],_0x5a21f7=this['_getChangeFromId'](_0x5dd3d5['changeId']);let _0x165d05;if(_0x5a21f7['data']['isOnRoot']){const _0x133fc9=_0x24fabc['view']['getDomRoot'](_0x5a21f7['rootName']);_0x165d05=Array['from'](_0x133fc9['getClientRects']());}else{const _0xecf639=this['editor']['model']['markers']['get']('revision:'+_0x5dd3d5['changeId']);_0x165d05=Array['from'](_0x24fabc['mapper']['markerNameToElements'](_0xecf639['name']))['map'](_0x11eceb=>_0x24fabc['view']['domConverter']['mapViewToDom'](_0x11eceb))['map'](_0x5a4995=>Array['from'](_0x5a4995['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x165d05[0x0];return _0x165d05['find'](_0x352210=>_0x352210['top']-0x3<=this['_activeViewTarget']['y']&&_0x352210['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x352210['left']-0x3<=this['_activeViewTarget']['x']&&_0x352210['right']+0x3>=this['_activeViewTarget']['x'])||_0x165d05[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x1f047c,_0x5460fc,_0xe06061,_0x5b1ddf)=>{this['activeView']=_0xe06061?this['_getViewForChange'](_0xe06061):null,this['editor']['model']['change'](()=>{const _0x5af53b=this['editor']['editing'];_0x5b1ddf&&(_0x5b1ddf['data']['isOnRoot']?_0x5af53b['view']['change'](_0x525b25=>{_0x525b25['removeClass']('ck-revision-history-root--active',_0x5af53b['view']['document']['getRoot'](_0x5b1ddf['rootName']));}):_0x5af53b['reconvertMarker']('revision:'+_0x5b1ddf['id'])),_0xe06061&&(_0xe06061['data']['isOnRoot']?_0x5af53b['view']['change'](_0x411b2e=>{_0x411b2e['addClass']('ck-revision-history-root--active',_0x5af53b['view']['document']['getRoot'](_0xe06061['rootName']));}):_0x5af53b['reconvertMarker']('revision:'+_0xe06061['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x3058f3,_0x5ddd12)=>{if(this['activeChange'])return;const _0x226845=this['_findChangeIdFromDomTarget'](_0x5ddd12['target']),_0x227730=this['_changeIdToChange']['get'](_0x226845);_0x227730?(this['_activeViewTarget']={'x':_0x5ddd12['domEvent']['x'],'y':_0x5ddd12['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x227730)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x288b81,_0x4c1cc1)=>{const _0x32b5e9=this['_findChangeIdFromDomTarget'](_0x4c1cc1['target']),_0x3eaede=this['_changeIdToChange']['get'](_0x32b5e9);_0x3eaede?(this['_activeViewTarget']={'x':_0x4c1cc1['domEvent']['x'],'y':_0x4c1cc1['domEvent']['y']},_0x3eaede===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x3eaede):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x1f8082){do{const _0x43be30=_0x1f8082['getAttribute']('data-change-id');if(_0x43be30)return _0x43be30;_0x1f8082=_0x1f8082['parent'];}while(_0x1f8082);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x301b01=>{for(const _0x4faebb of this['editor']['model']['markers'])_0x301b01['removeMarker'](_0x4faebb);});}}function X(_0xd3fd62,_0x28261c){return(_0xe22dbc,_0x5cf1ff,_0x342216)=>{if(!_0x342216['consumable']['test'](_0x5cf1ff['markerRange'],_0xe22dbc['name']))return;const _0x3668d7=_0x5cf1ff['markerRange']['getWalker'](),_0x4f3bd1=_0x5cf1ff['markerRange']['start'],_0x55faf0=_0xd3fd62['model']['schema'];let _0x5e4a89=null,_0x5ea5f2=null,_0x17d903=!0x1,_0xdaa806=!0x1;for(const _0x1c7849 of _0x3668d7){const _0x5cefcc=_0x1c7849['item'];_0x17d903=_0x17d903||_0x55faf0['isContent'](_0x5cefcc);const _0x11e18e=_0x342216['mapper']['toViewElement'](_0x5cefcc);if(_0x11e18e&&_0x11e18e['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x1c7849['type']&&(_0x55faf0['isBlock'](_0x5cefcc)&&!_0x55faf0['isLimit'](_0x5cefcc)&&(_0x5cefcc['nextSibling']||_0x4f3bd1['isAtEnd']?_0x5e4a89&&_0x5e4a89['parent']==_0x5cefcc||(_0x5e4a89=_0x5cefcc,_0x4870da(_0x1c7849['previousPosition']),_0xdaa806=!0x0):_0x5ea5f2=_0x5ea5f2||_0x1c7849['previousPosition']));}function _0x4870da(_0x18e76d){const _0x124e8e=_0x342216['mapper']['toViewPosition'](_0x18e76d),_0x57458b=_0x342216['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x28261c});_0x342216['writer']['insert'](_0x124e8e,_0x57458b),_0x342216['mapper']['bindElementToMarker'](_0x57458b,_0x5cf1ff['markerName']);}_0x17d903||_0xdaa806||!_0x5ea5f2||_0x4870da(_0x5ea5f2);};}class wt extends _0x300e49{constructor(_0x59c8e6){super(_0x59c8e6);const _0x5e1755=_0x59c8e6['plugins']['get'](m);this['affectsData']=!0x1,this['listenTo'](_0x5e1755,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x5e1755,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x2f9097=this['editor'],_0x5dab92=_0x2f9097['plugins']['get'](m),_0x30cbeb=_0x5dab92['isReady']?_0x5dab92['diff']['newRevisionId']:null;_0x2f9097['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x30cbeb);}['refresh'](){const {isReady:_0x5569bf,isEnabled:_0x223f58,repository:_0x3966dd,diff:_0x5d14f5}=this['editor']['plugins']['get'](m),_0x3c59c6=_0x5d14f5&&_0x3966dd['getLaterVisibleRevision'](_0x5d14f5['newRevisionId']);this['isEnabled']=_0x5569bf&&_0x223f58&&Boolean(_0x3c59c6);}}class pt extends _0x300e49{['_step'];constructor(_0x5215a4,{direction:_0x43c1ab}){super(_0x5215a4);const _0x36b3dd=_0x5215a4['plugins']['get'](m);this['affectsData']=!0x1,this['_step']='forward'===_0x43c1ab?0x1:-0x1,this['listenTo'](_0x36b3dd,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x36b3dd,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x36b3dd,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x260f66=this['editor'],_0x572ed1=_0x260f66['plugins']['get'](m),{isNavigationMode:_0x231520,currentChangeNumber:_0x2981ac}=_0x572ed1;let _0x4a8261;if(_0x572ed1['activeChange']=_0x231520?_0x572ed1['diff']['changes']['get'](_0x2981ac+this['_step']):_0x572ed1['diff']['changes']['first'],_0x572ed1['activeChange']['data']['isOnRoot'])_0x4a8261=_0x260f66['editing']['view']['getDomRoot'](_0x572ed1['activeChange']['rootName']);else{const _0x152fff=_0x260f66['model']['markers']['get']('revision:'+_0x572ed1['activeChange']['id']);_0x4a8261=_0x587168(_0x260f66['editing'],_0x152fff);}_0x549517({'target':_0x4a8261,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x1024ff,currentChangeNumber:_0x2b768d,numberOfChanges:_0x4467ab,isReady:_0x576194,isEnabled:_0x458128}=this['editor']['plugins']['get'](m);this['isEnabled']=!!(_0x458128&&_0x576194&&_0x4467ab)&&(!_0x1024ff||(0x1===this['_step']?_0x2b768d<_0x4467ab-0x1:_0x2b768d>0x0));}}class _i extends _0x328aa1{constructor(_0x5d3e47){super(_0x5d3e47);const _0x19b1e6=this['bindTemplate'],_0x4165f=new _0x4e381a(_0x5d3e47),_0x537f38=new _0x4e381a(_0x5d3e47);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',(_0x1fb130,_0x350a8b)=>_0x1fb130&&_0x350a8b>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x382ba6,_0xb3300e,_0x31d38a,_0xec45b4)=>{if(!_0x382ba6)return g(_0x5d3e47,'Loading...');if(!_0x31d38a)return g(_0x5d3e47,'No\x20changes');const _0x3982bb=g(_0x5d3e47,'NUMBER_OF_CHANGES',_0x31d38a);return _0xec45b4?g(_0x5d3e47,'X_OF_Y_CHANGES',[_0xb3300e+0x1,_0x31d38a]):_0x3982bb;}),_0x4165f['set']({'label':g(_0x5d3e47,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x51bc46}),_0x537f38['set']({'label':g(_0x5d3e47,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x4ffe2c}),_0x4165f['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x537f38['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x4165f['on']('execute',()=>this['fire']('execute','backward')),_0x537f38['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',_0x19b1e6['if']('_isStatusLabelVisible','ck-hidden',_0x5d7c37=>!_0x5d7c37)]},'children':[{'text':_0x19b1e6['to']('isNavigationMode',_0x4b9586=>_0x4b9586?g(_0x5d3e47,'EDIT_X_OF_Y_REVISIONS')+':\x20':g(_0x5d3e47,'Total')+':\x20')}]},{'text':_0x19b1e6['to']('_statusText')}]},new _0x586274(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x4165f,_0x537f38]}]});}}const ce='ck-editor__editable__loading-overlay';class le extends _0x310a6b{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x1ef94b=this['editor']['editing']['view'];_0x1ef94b['change'](_0x34c97b=>{for(const _0x269b12 of _0x1ef94b['document']['roots'])_0x34c97b['addClass'](ce,_0x269b12);});}['hide'](){const _0x2a20f3=this['editor']['editing']['view'];_0x2a20f3['change'](_0xf9ed5c=>{for(const _0x2a2166 of _0x2a20f3['document']['roots'])_0xf9ed5c['removeClass'](ce,_0x2a2166);});}}class R extends _0x310a6b{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[m,le];}['init'](){const _0x3d3d21=this['editor'],_0x5028fd=_0x3d3d21['plugins']['get'](m),_0x3e77f9=_0x3d3d21['plugins']['get'](le);_0x3d3d21['ui']['componentFactory']['add']('exitToEditing',_0x3941c1=>{const _0x841164=new _0x4e381a(_0x3941c1);return _0x841164['set']({'label':g(_0x3941c1,'Back\x20to\x20editing'),'icon':_0x2ff47d,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x841164,'execute',()=>{_0x3d3d21['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x841164;}),_0x3d3d21['ui']['componentFactory']['add']('restoreRevision',_0x4b2e9e=>{const _0x23d677=new _0x4e381a(_0x4b2e9e);return _0x23d677['set']({'label':g(_0x4b2e9e,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x23d677['bind']('isEnabled')['to'](_0x3d3d21['commands']['get']('restoreRevision')),this['listenTo'](_0x23d677,'execute',()=>_0x3d3d21['execute']('restoreRevision')),_0x23d677;}),_0x3d3d21['ui']['componentFactory']['add']('changesNavigation',_0x3ced64=>{const _0xd22ee9=new _i(_0x3ced64),_0x162464=_0x3d3d21['commands']['get']('showPreviousChange'),_0x1fbe6a=_0x3d3d21['commands']['get']('showNextChange');return _0xd22ee9['bind']('isBackwardNavigationEnabled')['to'](_0x162464,'isEnabled'),_0xd22ee9['bind']('isForwardNavigationEnabled')['to'](_0x1fbe6a,'isEnabled'),_0xd22ee9['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x5028fd),this['listenTo'](_0xd22ee9,'execute',(_0x2e6642,_0x568f1f)=>{_0x3d3d21['execute']('forward'===_0x568f1f?'showNextChange':'showPreviousChange');}),_0xd22ee9;}),_0x3e77f9['show'](),_0x5028fd['on']('change:isReady',(_0x27cb1e,_0x4180c1,_0x15d662)=>{_0x15d662?_0x3e77f9['hide']():_0x3e77f9['show']();});}}class lt extends nt{['_resizeObserver']=null;constructor(_0x52b0ca,_0x116371){super(_0x52b0ca,_0x116371);const _0x23c244=this['bindTemplate'];this['set']({'label':g(_0x52b0ca,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=g(_0x52b0ca,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x23c244['to']('_tooltipString'),'data-cke-tooltip-position':'s','data-cke-tooltip-class':'ck-tooltip_multi-line'}});}['render'](){super['render'](),this['_resizeObserver']=new at(this['fieldView']['element'],()=>this['_updateTooltipText']()),this['listenTo'](this['fieldView'],'input',()=>this['_updateTooltipText']());}['destroy'](){super['destroy'](),this['_resizeObserver']&&this['_resizeObserver']['destroy']();}['_updateTooltipText'](){const _0x1d6f13=this['fieldView']['element'];this['_tooltipString']=_0x1d6f13['scrollWidth']>_0x1d6f13['clientWidth']&&_0x1d6f13['value']||'';}}class oi extends _0x328aa1{constructor(_0x5c2dfa,_0x46221b,_0x36b908){super(_0x5c2dfa);const _0x33ef4a=new _0x458840();_0x33ef4a['set']({'content':_0x568aa7,'viewBox':'0\x200\x2011\x2010'});const _0x3f1f45=['ck','ck-revision-history-sidebar__revision-author'];_0x36b908&&_0x3f1f45['push']('ck-revision-history-sidebar__revision-author_creator');const _0x2b8149=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':g(_0x5c2dfa,_0x36b908?'Revision\x20creator':'Revision\x20author')},'children':[_0x33ef4a,_0x46221b['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x3f1f45},'children':_0x2b8149});}}function ni(_0x494ce7,_0xcdd62e){const _0x40a1a3=_0x494ce7['bindTemplate'],_0x2de5b9=_0x494ce7['locale'],_0x18f249=_0x49a6db(_0x2de5b9);_0x18f249['panelPosition']='sw';const _0x3b6138=function(_0x3fc20d,_0x16a2fe){const _0x230ee5=function(_0x32ef97,_0xbb416){const _0x38f681=_0x32ef97['locale'],_0xfc50f0={'Compare\x20against\x20selected':g(_0x38f681,'Compare\x20against\x20selected'),'Name\x20this\x20revision':g(_0x38f681,'Name\x20this\x20revision'),'Restore\x20this\x20revision':g(_0x38f681,'Restore\x20this\x20revision')};return _0xbb416['map'](_0xe02391=>{const _0x1d8e59=_0xfc50f0[_0xe02391['name']];return _0x1d8e59&&_0x1d8e59!==_0xe02391['name']&&(_0xe02391['name']=_0x1d8e59),_0xe02391;});}(_0x3fc20d,_0x16a2fe),_0x227e3a=new _0x204bd9();for(const _0x474d0d of _0x230ee5){const _0x12c2ff={'type':'button','model':new to({'label':_0x474d0d['name'],'class':_0x474d0d['class'],'withText':!0x0,'role':'menuitem','_action':_0x474d0d['action']})};_0x12c2ff['model']['bind']('isEnabled')['to'](_0x3fc20d,'isActionsDropdownOpen',_0x38cfda=>'function'!=typeof _0x474d0d['isEnabled']||(!_0x38cfda||_0x474d0d['isEnabled'](_0x3fc20d))),_0x227e3a['add'](_0x12c2ff);}return _0x227e3a;}(_0x494ce7,_0xcdd62e);return _0x494ce7['bind']('isActionsDropdownOpen')['to'](_0x18f249,'isOpen'),_0x18f249['buttonView']['set']({'label':g(_0x2de5b9,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x35640b}),_0x18f249['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x40a1a3['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x40a1a3['to'](_0x89c57b=>_0x89c57b['stopPropagation']())}}),_0x18f249['on']('execute',_0x314c56=>{_0x494ce7['isReady']&&'function'==typeof _0x314c56['source']['_action']&&_0x314c56['source']['_action'](_0x494ce7);}),_0x250f1a(_0x18f249,_0x3b6138,{'role':'menu'}),_0x18f249['listenTo'](_0x494ce7,'change:isActionsDropdownOpen',(_0x3f93a0,_0x91a6a3,_0x118fbe)=>{if(_0x118fbe)for(const _0x494b5a of _0x18f249['listView']['items']){const _0x442567=_0x494b5a['children']['first'],_0x15e52e=_0xcdd62e['find'](_0x37cf44=>_0x37cf44['action']===_0x442567['_action'])['isVisible'];_0x494b5a['isVisible']=void 0x0===_0x15e52e||_0x15e52e(_0x494ce7);}}),_0x18f249;}class ai extends/* #__PURE__ -- @preserve */
26
+ _0x3011d5(_0x328aa1){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x53830e,_0x2ae355,_0x29a108,_0x45def5){super(_0x53830e);const _0x4923a5=this['bindTemplate'],_0x569fd1=function(_0x42e8fb,_0x525bb8){const _0x2a7ba8=Array['from'](_0x525bb8['authors'])['filter'](_0x5e5e96=>_0x5e5e96!=_0x525bb8['creator']);return _0x525bb8['creator']&&_0x2a7ba8['unshift'](_0x525bb8['creator']),_0x2a7ba8['map'](_0x5c0b22=>new oi(_0x42e8fb,_0x5c0b22,_0x5c0b22==_0x525bb8['creator']));}(_0x53830e,_0x2ae355);this['id']=_0x2ae355['id'],this['_revision']=_0x2ae355,this['_requireRevisionName']=_0x45def5,this['bind']('name','createdAt')['to'](_0x2ae355),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x3459b9=>{return _0x2c98d1=_0x53830e['uiLanguage'],(_0x133e52=_0x3459b9)['toLocaleDateString'](_0x2c98d1,{'month':'long','day':'numeric'})+',\x20'+_0x133e52['toLocaleTimeString'](_0x2c98d1,{'hour':'numeric','minute':'numeric'});var _0x2c98d1,_0x133e52;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new lt(_0x53830e,ti),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x26e1a6=>_0x26e1a6||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x3d9e44,_0x588c2d)=>_0x3d9e44&&_0x588c2d),this['revisionActionsView']=_0x29a108&&_0x29a108['length']?ni(this,_0x29a108):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x4923a5['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x4923a5['if']('isEnabled','ck-disabled',_0x49cc71=>!_0x49cc71),_0x4923a5['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x4923a5['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x4923a5['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':_0x4923a5['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':_0x569fd1}]},this['revisionActionsView']],'on':{'click':_0x4923a5['to'](_0xc4fc1d=>{_0xc4fc1d['srcElement']['closest']('.ck-thread__remove-confirm')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x371785=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x371785,'change',()=>{this['_requireRevisionName']&&!_0x371785['value']||this['fire']('setName',{'id':this['id'],'name':_0x371785['value']}),_0x371785['value']||(_0x371785['value']=this['name']?this['name']:this['_createdAtFormatted']);});}['select'](){this['isSelected']=!0x0;}['deselect'](){this['isSelected']=!0x1;}['highlight'](){this['isHighlighted']=!0x0;}['unhighlight'](){this['isHighlighted']=!0x1;}}function vi(_0x4e2072,_0x35561a){const _0x4c9195=_0x2123bd['fromJSDate'](_0x4e2072)['setLocale'](_0x35561a),_0x444c84=_0x2123bd['local'](),_0x6caac0=_0x444c84['minus']({'days':0x1})['startOf']('day');let _0x15131e,_0x4005f1;return _0x4c9195['hasSame'](_0x444c84,'day')?(_0x15131e=_0x4c9195['startOf']('day')['toJSDate'](),_0x4005f1=_0x4c9195['toRelativeCalendar']()):_0x4c9195['hasSame'](_0x6caac0,'day')?(_0x15131e=_0x6caac0['toJSDate'](),_0x4005f1=_0x4c9195['toRelativeCalendar']()):_0x4c9195['hasSame'](_0x444c84,'week')?(_0x15131e=_0x4c9195['startOf']('week')['toJSDate'](),_0x4005f1=_0x4c9195['weekdayLong']||''):_0x4c9195['hasSame'](_0x444c84,'year')?(_0x15131e=_0x4c9195['startOf']('month')['toJSDate'](),_0x4005f1=_0x4c9195['monthLong']||''):(_0x15131e=_0x4c9195['startOf']('year')['toJSDate'](),_0x4005f1=String(_0x4c9195['year'])),{'startDate':_0x15131e,'localizedPeriodName':_0x4005f1};}class mi extends _0x328aa1{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x5d755a,_0x57e1aa,_0x3b50f3,_0x68418c){super(_0x5d755a);const _0xc45cd7=vi(_0x57e1aa,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x57e1aa,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x3b50f3,this['_requireRevisionName']=_0x68418c,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':_0xc45cd7}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x15c7f2){const _0x5bdc94=new ai(this['locale'],_0x15c7f2,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x5bdc94);}['removeRevision'](_0x158104){const _0x4e5f82=this['revisionViews']['find'](_0x3d51c6=>_0x3d51c6['id']===_0x158104['id']);this['revisionViews']['remove'](_0x4e5f82);}}class as extends _0x328aa1{constructor(_0x1fa638){super(_0x1fa638);const _0x205c65=new _0x458840();_0x205c65['content']=_0x4e40f2,this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x205c65,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[g(_0x1fa638,'Revision\x20history')]}]});}}class di extends _0x328aa1{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x22afd2,_0x55ae9a,_0x34672d,_0x14e8b3){super(_0x22afd2);const _0x5180ea=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x55ae9a,this['_revisionActions']=_0x34672d,this['_requireRevisionName']=_0x14e8b3,this['on']('select',(_0x55df53,_0x4dd3b3)=>{this['fire']('revisionSelected',_0x4dd3b3);}),this['on']('setName',(_0x44925c,_0x459b09)=>{this['fire']('revisionSetName',_0x459b09);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new as(_0x22afd2),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x5180ea['if']('isEnabled','ck-disabled',_0x45723a=>!_0x45723a)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x499ca8 of this['_revisions'])this['_addRevision'](_0x499ca8);this['_revisions']['on']('add',(_0x7f580a,_0x1b234e)=>{this['_addRevision'](_0x1b234e);}),this['_revisions']['on']('remove',(_0x50bbb3,_0x16e217)=>{this['_removeRevision'](_0x16e217);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x4845d2=>_0x4845d2['revisionViews']['map'](_0x36985f=>_0x36985f))['flat']();}['selectRevision'](_0x253369){for(const _0x1e17f7 of this['revisionViews'])_0x253369&&_0x253369['id']===_0x1e17f7['id']?_0x1e17f7['select']():_0x1e17f7['deselect']();}['highlightRevisions'](_0x9f5a6f){for(const _0x51cc38 of this['revisionViews'])_0x9f5a6f['some'](({id:_0x481ad8})=>_0x481ad8===_0x51cc38['id'])?_0x51cc38['highlight']():_0x51cc38['unhighlight']();}['_addRevision'](_0x253db8){const _0x352a03=vi(_0x253db8['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x3435aa=this['timePeriodViews']['get'](0x0);_0x3435aa&&_0x3435aa['startDate']['getTime']()===_0x352a03['getTime']()||(_0x3435aa=new mi(this['locale'],_0x352a03,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x3435aa)),_0x3435aa['addRevision'](_0x253db8);}['_removeRevision'](_0x432bcd){const _0x44e237=vi(_0x432bcd['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x44e237)['removeRevision'](_0x432bcd);}['_getTimePeriodViewByStartDate'](_0x16aa12){return this['timePeriodViews']['find'](_0x23b683=>_0x23b683['startDate']['getTime']()===_0x16aa12['getTime']());}}class d extends _0x310a6b{['_revisionViewer'];['_revisionsRepository'];['_sidebarView'];static ['defaultRevisionActions']=/* #__PURE__ -- @preserve */
27
27
  ((()=>['compareAgainstSelected','restoreRevision','nameRevision'])());static ['availableRevisionActions']=/* #__PURE__ -- @preserve */
28
- _t();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[m];}constructor(_0x4df4f8){super(_0x4df4f8),this['_revisionViewer']=_0x4df4f8['plugins']['get'](m),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x4471d6=this['_revisionsRepository']['_revisions'],_0x506068=this['_createRevisionActions'](),_0x306a2a=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new di(this['editor']['locale'],_0x4471d6,_0x506068,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',(_0x39cb1e,_0x296ccf)=>{_0x296ccf['revisionViews']['on']('add',(_0x10ae78,_0x137215)=>{_0x137215['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)),_0x306a2a['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x51b08e=this['_revisionsRepository']['getRevision'](0x0);if(_0x51b08e){const _0x2f47bc=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x51b08e['id']);this['_revisionViewer']['compare'](_0x51b08e,_0x2f47bc);}}['_handleRevisionSelected'](_0x41719f,_0x378ac2){const _0x46e420=this['_revisionsRepository']['getRevision'](_0x378ac2['id']),_0x32963f=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x46e420['id']);this['_revisionViewer']['compare'](_0x46e420,_0x32963f);}['_handleRevisionSetName'](_0x331dbc,_0x388904){this['_revisionsRepository']['getRevision'](_0x388904['id'])['setName'](_0x388904['name']);}['_handleDiffChange'](_0x488318,_0x226eca,_0x2ac3b8){const _0x1372a2=this['_revisionsRepository']['getRevisionsInDiff'](_0x2ac3b8);_0x1372a2['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x1372a2),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x1372a2[0x0]));}['_createRevisionActions'](){const _0x47871a=this['editor'],_0x401da5=d['availableRevisionActions'],_0xe8e62f=_0x47871a['config']['get']('revisionHistory.revisionActions')||d['defaultRevisionActions'];if(_0xe8e62f['length'])return _0xe8e62f['map'](_0x651cc0=>{const _0x70ac61='string'==typeof _0x651cc0?Object['assign']({},_0x401da5[_0x651cc0]):_0x651cc0;return _0x70ac61['action']=_0x70ac61['action']['bind'](this,_0x47871a),_0x70ac61['isVisible']&&(_0x70ac61['isVisible']=_0x70ac61['isVisible']['bind'](this,_0x47871a)),_0x70ac61;});}}function _t(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x47ef4c},_0x4fbd2d)=>{const _0x2f5cad=_0x47ef4c['get'](m),_0x3c948c=_0x2f5cad['repository'];let _0x1124bb=_0x2f5cad['diff']['newRevisionId'],_0x4b11b0=_0x4fbd2d['id'];_0x3c948c['getIndex'](_0x1124bb)>_0x3c948c['getIndex'](_0x4b11b0)&&([_0x1124bb,_0x4b11b0]=[_0x4b11b0,_0x1124bb]),_0x2f5cad['compare'](_0x1124bb,_0x4b11b0);},'isVisible':({plugins:_0x1a6388},_0x3db414)=>{const _0x4dde8d=_0x1a6388['get'](m);return!(_0x4dde8d['repository']['getRevisionsInDiff'](_0x4dde8d['diff'])['length']>0x2)&&!_0x3db414['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x255990,{id:_0x392390})=>{_0x255990['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x392390);},'isVisible':({plugins:_0x382d37},_0x4bfe82)=>!!_0x382d37['get'](m)['repository']['getLaterVisibleRevision'](_0x4bfe82['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x1556a4},{id:_0x3142b0,revisionNameView:_0x50a7a7})=>{const _0x28ced6=_0x1556a4['get'](m),_0x309c93=_0x28ced6['repository']['getEarlierVisibleRevision'](_0x3142b0);_0x28ced6['compare'](_0x3142b0,_0x309c93),_0x50a7a7['focus'](),_0x50a7a7['fieldView']['select']();}}};}class tt extends st{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x1126d3,_0x241db4){super(_0x1126d3),this['_view']=_0x241db4,this['_toolbarConfig']=et(_0x1126d3['config']['get']('toolbar')),this['_elementReplacer']=new ot();}get['element'](){return this['view']['element'];}['init'](_0x329ce6){const _0x3fc2bf=this['editor'],_0x35875d=this['view'],_0x2734cf=_0x3fc2bf['editing']['view'],_0x1916aa=_0x35875d['editable'],_0x2fb1f9=_0x2734cf['document']['getRoot']();_0x1916aa['name']=_0x2fb1f9['rootName'],_0x35875d['render']();const _0x1db82f=_0x1916aa['element'];this['setEditableElement'](_0x1916aa['name'],_0x1db82f),_0x35875d['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x2734cf['attachDomRoot'](_0x1db82f),this['_elementReplacer']['replace'](_0x329ce6,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x2deb6b=this['view'],_0x452cac=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x452cac['detachDomRoot'](_0x2deb6b['editable']['name']),_0x2deb6b['destroy']();}['_initToolbar'](){const _0x15df25=this['view'];_0x15df25['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x15df25['stickyPanel']['limiterElement']=_0x15df25['element'],_0x15df25['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x1dc3ba})=>_0x1dc3ba),_0x15df25['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x15df25['toolbar']);}}class it extends rt{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x50e29a,_0x2a736c,_0x59b6e0={}){super(_0x50e29a),this['stickyPanel']=new ht(_0x50e29a),this['toolbar']=new dt(_0x50e29a,{'shouldGroupWhenFull':_0x59b6e0['shouldToolbarGroupWhenFull']}),this['_editable']=new ct(_0x50e29a,_0x2a736c);}['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
- _0x2d2992(_0x6db5f7){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x487a3b,_0x36b30c){super(_0x36b30c),this['sourceElement']=_0x487a3b,this['model']['document']['createRoot']();const _0x2c7965=new it(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new tt(this,_0x2c7965);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x5b1a34,_0x333b8a){const _0xdd14ba=new this(_0x5b1a34,_0x333b8a);return await _0xdd14ba['initPlugins'](),await _0xdd14ba['ui']['init'](_0x5b1a34),await _0xdd14ba['data']['init'](_0xdd14ba['config']['get']('initialData')||''),_0xdd14ba['fire']('ready'),_0xdd14ba;}}const p=['RevisionHistoryUI','RestrictedEditingMode'];class yt extends _0x2a1981{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x204254){function _0xc27bb2(_0x32045e){return _0x32045e['map'](_0x261d46=>String['fromCharCode'](_0x261d46))['join']('');}super(_0x204254),this['result']='end',_0x204254[_0xc27bb2([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0xc27bb2([0x76,0x69,0x65,0x77])][_0xc27bb2([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0xc27bb2([0x61,0x75,0x74,0x6f]),_0x204254[_0xc27bb2([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0xc27bb2([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0xc27bb2([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0xc27bb2([0x73,0x74,0x61,0x74,0x75,0x73])]:_0xc27bb2([0x6f,0x6b])});}}class k extends _0x2a1981{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u,f];}constructor(_0x37b281){if(super(_0x37b281),!this['editor']['config']['get']('revisionHistory'))throw new _0x253854('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x17079f=>this['_showRevisionViewer']({..._0x17079f,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x39ce83=>this['_closeRevisionViewer'](_0x39ce83)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x1b4f9d=>this['_restoreRevision'](_0x1b4f9d)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x4b05c8){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x4b05c8;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x48f58e){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x48f58e);}['getRevision'](_0x3f4380){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x3f4380);}['getRevisions'](_0x9fe4d){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x9fe4d||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x47d94a=this['editor'],_0x5b77d4=_0x57ea3d(_0x47d94a,p),_0x4054d4=_0x47d94a['plugins']['get']('RevisionTracker'),_0x302ceb=_0x47d94a['plugins']['get']('Users')['users'];return _0x5b77d4['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x5b77d4['lazyRoots'],(_0x5b77d4['plugins']['push'](yt,m,R,class extends _0x2a1981{static get['requires'](){return[m,'Users'];}['init'](){const _0x3747c8=this['editor']['plugins']['get']('Users');for(const _0x4e1c24 of _0x302ceb)_0x4e1c24['isAnonymous']||_0x3747c8['getUser'](_0x4e1c24['id'])||_0x3747c8['addUser'](_0x4e1c24);const _0x3a5bc9=_0x4054d4['repository']['getRevisions']();let _0x43281c=null;const _0x30248f=this['editor']['plugins']['get']('RevisionViewer');_0x30248f['adapter']=_0x4054d4['adapter'],_0x30248f['bind']('isEnabled')['to'](_0x4054d4),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x47d94a,'isReadOnly',_0x26bf35=>!_0x26bf35);for(const _0x241106 of _0x3a5bc9){const _0x464a4f=null===_0x241106['creator'];if(_0x464a4f&&_0x241106['toVersion']===_0x241106['fromVersion'])continue;const _0x3a36d1=_0x241106['toJSON']();_0x30248f['addRevisionData'](_0x3a36d1,(_0x4d353f,_0xdc029d,_0xe252a)=>{if(_0x464a4f){if(_0x43281c)_0x43281c['_update'](_0x4d353f,_0xdc029d);else{if(!_0xdc029d){const _0x2c2d1a=_0xe252a['toJSON']();_0x2c2d1a['id']=_0x5c32ae(),_0x4054d4['saveRevision'](_0x2c2d1a,_0xe252a['toVersion'])['then'](_0x10e349=>{_0x43281c=_0x10e349;});}}}else _0x241106['_update'](_0x4d353f,_0xdc029d);});}}},d),_0x5b77d4);}['_enhanceShowRevisionViewerCallback'](){const _0x31218d=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x42804d=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x26ff9d=this['editor']['plugins']['get']('Autosave');await _0x26ff9d['save']();}else await _0x42804d['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x1437b5=this['editor']['plugins']['get']('Dialog');_0x1437b5['isOpen']&&_0x1437b5['hide']();}const _0x287e65=this['_getRevisionViewerEditorConfig']();return _0x31218d(_0x287e65)['then'](_0x236e42=>{return(this['_viewerEditor']=_0x236e42,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'),_0x236e42);})['catch'](_0x531a44=>(console['error'](_0x531a44),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x5d6e23=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'](),_0x5d6e23(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x5b9550=this['editor']['plugins']['get']('Annotations');_0x5b9550['refreshVisibility'](),_0x5b9550['refreshPositioning']();}})));}['_showRevisionViewer'](_0x5bb5e7){const _0x27b65a=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x28e3d7=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x120e2f=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return w['create'](_0x120e2f,_0x5bb5e7)['then'](_0x4ee2de=>(_0x28e3d7['style']['display']='block',_0x27b65a['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x4ee2de));}['_closeRevisionViewer'](_0x22425b){const _0x435afb=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x435afb['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x22425b['destroy']();}async['_restoreRevision'](_0xe7317c){const _0x287b55=this['editor'],_0x5a537e=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0xfe1599=_0x287b55['plugins']['get']('RevisionTracker'),_0x5ef4c2=_0x287b55['plugins']['get']('RevisionHistoryUtils'),_0x11ba33=_0x5a537e['repository']['getRevision'](_0xe7317c);let _0x2b7c98,_0x4ff738,_0x3ce136;try{await _0x5ef4c2['loadRevisionData'](_0x11ba33,this['adapter']),_0x2b7c98=_0x5ef4c2['getRevisionDocumentData'](_0x11ba33),_0x4ff738=_0x5ef4c2['getRevisionRootsAttributes'](_0x11ba33);}catch(_0xac1c8c){return void console['error'](_0xac1c8c);}_0x287b55['model']['change'](_0x2c145f=>{for(const _0x1d9d84 of Array['from'](_0x287b55['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x2c145f['removeMarker'](_0x1d9d84);}),_0x5a537e['isReady']=!0x1,_0x287b55['model']['enqueueChange'](_0x301eb7=>{_0x301eb7['setSelection'](null),_0x301eb7['removeSelectionAttribute'](_0x287b55['model']['document']['selection']['getAttributeKeys']());const _0x2ae3a4=Object['keys'](_0x2b7c98);for(const _0x1dd997 of _0x287b55['model']['document']['roots'])'$graveyard'!=_0x1dd997['rootName']&&_0x1dd997['isAttached']()&&!_0x2ae3a4['includes'](_0x1dd997['rootName'])&&_0x301eb7['detachRoot'](_0x1dd997);for(const _0x591cd3 of _0x2ae3a4){let _0x161eee=_0x287b55['model']['document']['getRoot'](_0x591cd3);_0x161eee&&_0x161eee['isAttached']()||(_0x161eee=_0x301eb7['addRoot'](_0x591cd3));const _0x3b84a4=_0x4ff738[_0x591cd3],_0x41ca40=Object['keys'](_0x3b84a4),_0x1dd83e=_0x2b7c98[_0x591cd3];for(const _0x59fc57 of _0x161eee['getAttributeKeys']())_0x41ca40['includes'](_0x59fc57)||_0x301eb7['removeAttribute'](_0x59fc57,_0x161eee);for(const _0x559075 of _0x41ca40)_0x301eb7['setAttribute'](_0x559075,_0x4ff738[_0x591cd3][_0x559075],_0x161eee);_0x301eb7['remove'](_0x301eb7['createRangeIn'](_0x161eee)),_0x301eb7['insert'](_0x287b55['data']['parse'](_0x1dd83e,_0x161eee),_0x161eee,0x0);}});const _0x10f740=g(_0x287b55['locale'],'Restored');if(_0x11ba33['name'])_0x3ce136=-0x1==_0x11ba33['name']['indexOf'](_0x10f740)?_0x10f740+':\x20'+_0x11ba33['name']:_0x11ba33['name'];else _0x3ce136=_0x10f740+':\x20'+(_0x11ba33['createdAt']['toLocaleDateString'](_0x287b55['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x11ba33['createdAt']['toLocaleTimeString'](_0x287b55['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0xfe1599['saveRevision']({'name':_0x3ce136}),_0x5a537e['isReady']=!0x0,_0x287b55['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,le as RevisionViewerLoadingOverlay,R as RevisionViewerUI,I as RevisionsRepository,d as RevisionsSidebar};
28
+ _t();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[m];}constructor(_0x1c5657){super(_0x1c5657),this['_revisionViewer']=_0x1c5657['plugins']['get'](m),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x811759=this['_revisionsRepository']['_revisions'],_0x5ca611=this['_createRevisionActions'](),_0x221044=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new di(this['editor']['locale'],_0x811759,_0x5ca611,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',(_0x574dc4,_0xdafada)=>{_0xdafada['revisionViews']['on']('add',(_0x3acee7,_0x1ecb9d)=>{_0x1ecb9d['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)),_0x221044['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x3b5052=this['_revisionsRepository']['getRevision'](0x0);if(_0x3b5052){const _0x2b78b0=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x3b5052['id']);this['_revisionViewer']['compare'](_0x3b5052,_0x2b78b0);}}['_handleRevisionSelected'](_0x4e4f7b,_0x1df1b2){const _0x5347ca=this['_revisionsRepository']['getRevision'](_0x1df1b2['id']),_0x13beec=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x5347ca['id']);this['_revisionViewer']['compare'](_0x5347ca,_0x13beec);}['_handleRevisionSetName'](_0x5bd7dd,_0x2f4ed0){this['_revisionsRepository']['getRevision'](_0x2f4ed0['id'])['setName'](_0x2f4ed0['name']);}['_handleDiffChange'](_0x374220,_0x55bf7a,_0x9b4ba3){const _0x54791b=this['_revisionsRepository']['getRevisionsInDiff'](_0x9b4ba3);_0x54791b['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x54791b),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x54791b[0x0]));}['_createRevisionActions'](){const _0x3b1ffd=this['editor'],_0x52712a=d['availableRevisionActions'],_0x12cf94=_0x3b1ffd['config']['get']('revisionHistory.revisionActions')||d['defaultRevisionActions'];if(_0x12cf94['length'])return _0x12cf94['map'](_0x1a234c=>{const _0x351e65='string'==typeof _0x1a234c?Object['assign']({},_0x52712a[_0x1a234c]):_0x1a234c;return _0x351e65['action']=_0x351e65['action']['bind'](this,_0x3b1ffd),_0x351e65['isVisible']&&(_0x351e65['isVisible']=_0x351e65['isVisible']['bind'](this,_0x3b1ffd)),_0x351e65;});}}function _t(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x46f3f4},_0x3277ed)=>{const _0x471685=_0x46f3f4['get'](m),_0x1ae744=_0x471685['repository'];let _0x5cf4e1=_0x471685['diff']['newRevisionId'],_0x947cd8=_0x3277ed['id'];_0x1ae744['getIndex'](_0x5cf4e1)>_0x1ae744['getIndex'](_0x947cd8)&&([_0x5cf4e1,_0x947cd8]=[_0x947cd8,_0x5cf4e1]),_0x471685['compare'](_0x5cf4e1,_0x947cd8);},'isVisible':({plugins:_0x1bdd00},_0x3e2f3e)=>{const _0x5c6903=_0x1bdd00['get'](m);return!(_0x5c6903['repository']['getRevisionsInDiff'](_0x5c6903['diff'])['length']>0x2)&&!_0x3e2f3e['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x2f1c1f,{id:_0x1aca76})=>{_0x2f1c1f['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x1aca76);},'isVisible':({plugins:_0xfb6013},_0x362228)=>!!_0xfb6013['get'](m)['repository']['getLaterVisibleRevision'](_0x362228['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x398aa1},{id:_0x19b94f,revisionNameView:_0x4ae47f})=>{const _0x114f34=_0x398aa1['get'](m),_0x4e0ce8=_0x114f34['repository']['getEarlierVisibleRevision'](_0x19b94f);_0x114f34['compare'](_0x19b94f,_0x4e0ce8),_0x4ae47f['focus'](),_0x4ae47f['fieldView']['select']();}}};}class tt extends st{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x56ad42,_0x520e15){super(_0x56ad42),this['_view']=_0x520e15,this['_toolbarConfig']=et(_0x56ad42['config']['get']('toolbar')),this['_elementReplacer']=new ot();}get['element'](){return this['view']['element'];}['init'](_0x52a39f){const _0xc96b8b=this['editor'],_0x52c910=this['view'],_0x4805f4=_0xc96b8b['editing']['view'],_0x5c9ba6=_0x52c910['editable'],_0x1f495e=_0x4805f4['document']['getRoot']();_0x5c9ba6['name']=_0x1f495e['rootName'],_0x52c910['render']();const _0x35f744=_0x5c9ba6['element'];this['setEditableElement'](_0x5c9ba6['name'],_0x35f744),_0x52c910['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x4805f4['attachDomRoot'](_0x35f744),this['_elementReplacer']['replace'](_0x52a39f,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x3bcebe=this['view'],_0xe9953f=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0xe9953f['detachDomRoot'](_0x3bcebe['editable']['name']),_0x3bcebe['destroy']();}['_initToolbar'](){const _0x529da8=this['view'];_0x529da8['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x529da8['stickyPanel']['limiterElement']=_0x529da8['element'],_0x529da8['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x27c8d2})=>_0x27c8d2),_0x529da8['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x529da8['toolbar']);}}class it extends rt{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x4600dc,_0x327e7c,_0x37250f={}){super(_0x4600dc),this['stickyPanel']=new ht(_0x4600dc),this['toolbar']=new dt(_0x4600dc,{'shouldGroupWhenFull':_0x37250f['shouldToolbarGroupWhenFull']}),this['_editable']=new ct(_0x4600dc,_0x327e7c);}['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
+ _0x5cd351(_0x4da541){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x180297,_0x14ca23){super(_0x14ca23),this['sourceElement']=_0x180297,this['model']['document']['createRoot']();const _0x2d3cde=new it(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new tt(this,_0x2d3cde);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x40da3d,_0x16392e){const _0x4f1ace=new this(_0x40da3d,_0x16392e);return await _0x4f1ace['initPlugins'](),await _0x4f1ace['ui']['init'](_0x40da3d),await _0x4f1ace['data']['init'](_0x4f1ace['config']['get']('initialData')||''),_0x4f1ace['fire']('ready'),_0x4f1ace;}}const p=['RevisionHistoryUI','RestrictedEditingMode'];class yt extends _0x310a6b{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0xd917c8){function _0x3fbed1(_0x25196c){return _0x25196c['map'](_0x10b54f=>String['fromCharCode'](_0x10b54f))['join']('');}super(_0xd917c8),this['result']='end',_0xd917c8[_0x3fbed1([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x3fbed1([0x76,0x69,0x65,0x77])][_0x3fbed1([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x3fbed1([0x61,0x75,0x74,0x6f]),_0xd917c8[_0x3fbed1([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x3fbed1([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x3fbed1([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x3fbed1([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x3fbed1([0x6f,0x6b])});}}class k extends _0x310a6b{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u,f];}constructor(_0x2bc906){if(super(_0x2bc906),!this['editor']['config']['get']('revisionHistory'))throw new _0x5e4045('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x4674c0=>this['_showRevisionViewer']({..._0x4674c0,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x1f5e56=>this['_closeRevisionViewer'](_0x1f5e56)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x502dca=>this['_restoreRevision'](_0x502dca)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x169f9b){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x169f9b;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x483355){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x483355);}['getRevision'](_0x155cc9){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x155cc9);}['getRevisions'](_0x335365){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x335365||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x4e3106=this['editor'],_0x2ba298=_0x56ae90(_0x4e3106,p),_0x45a7fa=_0x4e3106['plugins']['get']('RevisionTracker'),_0x59de50=_0x4e3106['plugins']['get']('Users')['users'];return _0x2ba298['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x2ba298['lazyRoots'],(_0x2ba298['plugins']['push'](yt,m,R,class extends _0x310a6b{static get['requires'](){return[m,'Users'];}['init'](){const _0x294697=this['editor']['plugins']['get']('Users');for(const _0x2a5468 of _0x59de50)_0x2a5468['isAnonymous']||_0x294697['getUser'](_0x2a5468['id'])||_0x294697['addUser'](_0x2a5468);const _0x2825d9=_0x45a7fa['repository']['getRevisions']();let _0x150e29=null;const _0x5b62b5=this['editor']['plugins']['get']('RevisionViewer');_0x5b62b5['adapter']=_0x45a7fa['adapter'],_0x5b62b5['bind']('isEnabled')['to'](_0x45a7fa),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x4e3106,'isReadOnly',_0x88762c=>!_0x88762c);for(const _0x3c1074 of _0x2825d9){const _0x142d7f=null===_0x3c1074['creator'];if(_0x142d7f&&_0x3c1074['toVersion']===_0x3c1074['fromVersion'])continue;const _0x45b9e1=_0x3c1074['toJSON']();_0x5b62b5['addRevisionData'](_0x45b9e1,(_0x505699,_0x3844e6,_0x398e9a)=>{if(_0x142d7f){if(_0x150e29)_0x150e29['_update'](_0x505699,_0x3844e6);else{if(!_0x3844e6){const _0x24d221=_0x398e9a['toJSON']();_0x24d221['id']=_0x46489c(),_0x45a7fa['saveRevision'](_0x24d221,_0x398e9a['toVersion'])['then'](_0x14e890=>{_0x150e29=_0x14e890;});}}}else _0x3c1074['_update'](_0x505699,_0x3844e6);});}}},d),_0x2ba298);}['_enhanceShowRevisionViewerCallback'](){const _0x2e47d3=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x135ce7=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x433df7=this['editor']['plugins']['get']('Autosave');await _0x433df7['save']();}else await _0x135ce7['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x320639=this['editor']['plugins']['get']('Dialog');_0x320639['isOpen']&&_0x320639['hide']();}const _0x48613e=this['_getRevisionViewerEditorConfig']();return _0x2e47d3(_0x48613e)['then'](_0x226f40=>{return(this['_viewerEditor']=_0x226f40,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'),_0x226f40);})['catch'](_0x233e4e=>(console['error'](_0x233e4e),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x12184d=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'](),_0x12184d(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x4b5f93=this['editor']['plugins']['get']('Annotations');_0x4b5f93['refreshVisibility'](),_0x4b5f93['refreshPositioning']();}})));}['_showRevisionViewer'](_0x31bc09){const _0xc707d=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x364842=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x3ffa6a=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return w['create'](_0x3ffa6a,_0x31bc09)['then'](_0xf467f3=>(_0x364842['style']['display']='block',_0xc707d['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0xf467f3));}['_closeRevisionViewer'](_0xd74746){const _0x59ccfc=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x59ccfc['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0xd74746['destroy']();}async['_restoreRevision'](_0x27327f){const _0x819f02=this['editor'],_0x427181=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x27861b=_0x819f02['plugins']['get']('RevisionTracker'),_0x487eae=_0x819f02['plugins']['get']('RevisionHistoryUtils'),_0x10df5b=_0x427181['repository']['getRevision'](_0x27327f);let _0xcdafbc,_0x3c234e,_0xadecb2;try{await _0x487eae['loadRevisionData'](_0x10df5b,this['adapter']),_0xcdafbc=_0x487eae['getRevisionDocumentData'](_0x10df5b),_0x3c234e=_0x487eae['getRevisionRootsAttributes'](_0x10df5b);}catch(_0x36bd60){return void console['error'](_0x36bd60);}_0x819f02['model']['change'](_0x377ed2=>{for(const _0xbea755 of Array['from'](_0x819f02['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x377ed2['removeMarker'](_0xbea755);}),_0x427181['isReady']=!0x1,_0x819f02['model']['enqueueChange'](_0x188940=>{_0x188940['setSelection'](null),_0x188940['removeSelectionAttribute'](_0x819f02['model']['document']['selection']['getAttributeKeys']());const _0x3369b2=Object['keys'](_0xcdafbc);for(const _0x55a2e5 of _0x819f02['model']['document']['roots'])'$graveyard'!=_0x55a2e5['rootName']&&_0x55a2e5['isAttached']()&&!_0x3369b2['includes'](_0x55a2e5['rootName'])&&_0x188940['detachRoot'](_0x55a2e5);for(const _0x5ef9b8 of _0x3369b2){let _0xd01157=_0x819f02['model']['document']['getRoot'](_0x5ef9b8);_0xd01157&&_0xd01157['isAttached']()||(_0xd01157=_0x188940['addRoot'](_0x5ef9b8));const _0x2feb1d=_0x3c234e[_0x5ef9b8],_0x297cac=Object['keys'](_0x2feb1d),_0x4a0410=_0xcdafbc[_0x5ef9b8];for(const _0x3b6eb1 of _0xd01157['getAttributeKeys']())_0x297cac['includes'](_0x3b6eb1)||_0x188940['removeAttribute'](_0x3b6eb1,_0xd01157);for(const _0x2fc6eb of _0x297cac)_0x188940['setAttribute'](_0x2fc6eb,_0x3c234e[_0x5ef9b8][_0x2fc6eb],_0xd01157);_0x188940['remove'](_0x188940['createRangeIn'](_0xd01157)),_0x188940['insert'](_0x819f02['data']['parse'](_0x4a0410,_0xd01157),_0xd01157,0x0);}});const _0x5ca21d=g(_0x819f02['locale'],'Restored');if(_0x10df5b['name'])_0xadecb2=-0x1==_0x10df5b['name']['indexOf'](_0x5ca21d)?_0x5ca21d+':\x20'+_0x10df5b['name']:_0x10df5b['name'];else _0xadecb2=_0x5ca21d+':\x20'+(_0x10df5b['createdAt']['toLocaleDateString'](_0x819f02['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x10df5b['createdAt']['toLocaleTimeString'](_0x819f02['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x27861b['saveRevision']({'name':_0xadecb2}),_0x427181['isReady']=!0x0,_0x819f02['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,le as RevisionViewerLoadingOverlay,R as RevisionViewerUI,I as RevisionsRepository,d as RevisionsSidebar};