@ckeditor/ckeditor5-revision-history 45.0.0-alpha.1 → 45.0.0-alpha.11

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 _0x1af5d3,uid as _0x4339db,Collection as _0xe2334c,logWarning as _0x2c9793,FocusTracker as _0x1b3856,KeystrokeHandler as _0xeb5fa6,scrollViewportToShowTarget as _0x2da720,ResizeObserver as at,ElementReplacer as ot,CKEditorError as _0x49f01a}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x5dbaa0,set as _0xb13fb2,unset as _0x36ccf3,isEqual as _0xe19125}from'es-toolkit/compat';import{Plugin as _0x47ebf6,PendingActions as _0x5a98bd,Command as _0x5eb553,ElementApiMixin as _0xb0c17c,Editor as _0x344b4b}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x181a91,getMarkerDomElement as _0x7a3ec1,ConfirmMixin as _0x247912,sanitizeEditorConfig as _0x22939f}from'ckeditor5-collaboration/dist/index.js';import{ViewContainerElement as _0x5cb939,ViewAttributeElement as _0x1e96d3,ViewEmptyElement as _0xb2d956,ViewRawElement as _0x4bacf8,ViewUIElement as _0x457f5e,ViewDocumentFragment as _0x4915e2,ViewText as _0x3184b0,ViewElement as _0x33a722,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 _0x3c6f9c,IconChevronUp as _0x3aaf5a,IconChevronDown as _0x503175,IconUndo as _0x14d522,IconUser as _0x4e437e,IconThreeVerticalDots as _0x7b9774}from'@ckeditor/ckeditor5-icons/dist/index.js';import{View as _0x225fc7,injectCssTransitionDisabler as ts,submitHandler as _0x5a7c23,LabeledFieldView as nt,createLabeledInputText as ti,createDropdown as _0xc59451,ListView as _0x20bfa9,ListItemView as te,ButtonView as _0x5bb06b,MenuBarMenuView as _0x4e87b1,MenuBarMenuListView as _0xcb41ea,MenuBarMenuListItemView as _0x43d7d9,MenuBarMenuListItemButtonView as _0x53a40c,ContextualBalloon as _0x1020ef,ToolbarSeparatorView as _0x51c520,IconView as _0x2cc422,addListToDropdown as _0x569ebe,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 _0x724367}from'luxon';class h extends/* #__PURE__ -- @preserve */
24
- _0x1af5d3(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x504e98){super(),this['id']=_0x504e98['id']||_0x4339db(),this['creator']=_0x504e98['creator']||null,this['authors']=_0x504e98['authors']||[],this['diffData']=_0x504e98['diffData']||null,this['toVersion']=_0x504e98['toVersion']||0x0,this['fromVersion']=_0x504e98['fromVersion']||0x0,this['set']('name',_0x504e98['name']||''),this['set']('createdAt',_0x504e98['createdAt']||new Date()),this['set']('attributes',_0x504e98['attributes']||{});}['setName'](_0x330fd5){this['_update']({'name':_0x330fd5});}['setAttribute'](_0x2c900a,_0x4f1153){const _0x573a26=_0x5dbaa0(this['attributes']);_0xb13fb2(_0x573a26,_0x2c900a,_0x4f1153),this['_update']({'attributes':_0x573a26});}['removeAttribute'](_0x2a56cf){const _0x8f1ebe=_0x5dbaa0(this['attributes']);_0x36ccf3(_0x8f1ebe,_0x2a56cf),this['_update']({'attributes':_0x8f1ebe});}['_update'](_0x54df82,_0x4da34f=!0x1){let _0x4574a3=!0x1;const _0x3c03ba={'id':this['id']},_0x4f3de4=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0xfe8f95 of _0x4f3de4){const _0x5f74bb=_0x54df82[_0xfe8f95];void 0x0!==_0x5f74bb&&_0x5f74bb!==this[_0xfe8f95]&&(this[_0xfe8f95]=_0x5f74bb,_0x3c03ba[_0xfe8f95]=_0x5f74bb,_0x4574a3=!0x0);}_0x4574a3&&(_0x3c03ba['authors']&&(_0x3c03ba['authorsIds']=_0x3c03ba['authors']['map'](_0x3527ac=>_0x3527ac['id']),delete _0x3c03ba['authors']),this['fire']('_update',_0x3c03ba,_0x4da34f));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x4a6086=>_0x4a6086['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class I extends _0x47ebf6{['_revisions'];static get['requires'](){return[_0x181a91];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0xc5b4ac){super(_0xc5b4ac),this['_revisions']=new _0xe2334c();}['afterInit'](){!async function(_0x3593c3){const _0xe85ed3=_0x150e76([0x48,0x4e,0x4f,0x46,0x45,0x7a,0x34,0x33,0x61,0x68,0x67,0x74,0x6a,0x49,0x53,0x30,0x71,0x47,0x75,0x77,0x56,0x4d,0x63,0x31,0x69,0x6e,0x70,0x44,0x72,0x41,0x62,0x73,0x51,0x42,0x76,0x55,0x58,0x54,0x4c,0x66,0x4a,0x59,0x6f,0x6d,0x52,0x5a,0x79,0x65,0x36,0x64,0x4b,0x37,0x32,0x50,0x35,0x57,0x38,0x39,0x78,0x6b,0x6c,0x43]),_0x3ee1b2=0xeb829,_0x3ca11e=0x57ff0a18,_0x43a575=0x57f86948^_0x3ca11e,_0x7d4b0e=window[_0x150e76([0x44,0x61,0x74,0x65])][_0x150e76([0x6e,0x6f,0x77])](),_0x29506b=_0x3593c3[_0x150e76([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x346143=new window[(_0x150e76([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x3b3efb=>{_0x29506b[_0x150e76([0x6f,0x6e,0x63,0x65])](_0x150e76([0x72,0x65,0x61,0x64,0x79]),_0x3b3efb);}),_0x9b1e09={[_0x150e76([0x6b,0x74,0x79])]:_0x150e76([0x45,0x43]),[_0x150e76([0x75,0x73,0x65])]:_0x150e76([0x73,0x69,0x67]),[_0x150e76([0x63,0x72,0x76])]:_0x150e76([0x50,0x2d,0x32,0x35,0x36]),[_0x150e76([0x78])]:_0x150e76([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]),[_0x150e76([0x79])]:_0x150e76([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]),[_0x150e76([0x61,0x6c,0x67])]:_0x150e76([0x45,0x53,0x32,0x35,0x36])},_0x3a8fd9=_0x29506b[_0x150e76([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x150e76([0x67,0x65,0x74])](_0x150e76([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x31a924(){let _0x1e7afc,_0x17b314=null,_0xf2913e=null;try{if(_0x3a8fd9==_0x150e76([0x47,0x50,0x4c]))return _0x150e76([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x1e7afc=_0x4f637d(),!_0x1e7afc)return _0x150e76([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x1e7afc[_0x150e76([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0xf2913e=_0xadd64(_0x1e7afc[_0x150e76([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x1e7afc[_0x150e76([0x6a,0x74,0x69])])),await _0x3a4a64()?_0x12f2ff()?_0x3640c4()?_0x150e76([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x3c91aa()?(_0x1e7afc[_0x150e76([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x150e76([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x17b314=_0x91214e(_0x150e76([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x1e7afc[_0x150e76([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x150e76([0x74,0x72,0x69,0x61,0x6c])&&(_0x17b314=_0x91214e(_0x150e76([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x1dc355()):_0x150e76([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x150e76([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x150e76([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch(_0x55f6a7){return _0x150e76([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x3640c4(){const _0x441ea6=[_0x150e76([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x150e76([0x74,0x72,0x69,0x61,0x6c])][_0x150e76([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x1e7afc[_0x150e76([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x7d4b0e/0x3e8:0xe10*_0x43a575;return _0x1e7afc[_0x150e76([0x65,0x78,0x70])]<_0x441ea6;}function _0x12f2ff(){const _0x2f320a=_0x1e7afc[_0x150e76([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x2f320a)return!0x1;if(_0x2f320a[_0x150e76([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x150e76([0x2a])))return!0x0;if(_0x2f320a[_0x150e76([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x150e76([0x52,0x48])))return!0x0;if(_0x2f320a[_0x150e76([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x150e76([0x52,0x52,0x48]))){if(_0x1993fb())return!0x0;if(_0x287c6b()||_0x124584())return!0x0;}return!0x1;}function _0x3c91aa(){const _0x1bafcf=_0x1e7afc[_0x150e76([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x1bafcf||0x0==_0x1bafcf[_0x150e76([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x24d8a1}=new URL(window[_0x150e76([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x1bafcf[_0x150e76([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x24d8a1))return!0x0;const _0x490f3c=_0x24d8a1[_0x150e76([0x73,0x70,0x6c,0x69,0x74])](_0x150e76([0x2e]));return _0x1bafcf[_0x150e76([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x49ef87=>_0x49ef87[_0x150e76([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x150e76([0x2a])))[_0x150e76([0x6d,0x61,0x70])](_0xbdb2ff=>_0xbdb2ff[_0x150e76([0x73,0x70,0x6c,0x69,0x74])](_0x150e76([0x2e])))[_0x150e76([0x73,0x6f,0x6d,0x65])](_0xd5298c=>_0x490f3c[_0x150e76([0x65,0x76,0x65,0x72,0x79])]((_0x3974f8,_0x1e0065)=>_0xd5298c[_0x1e0065]===_0x3974f8||_0xd5298c[_0x1e0065]===_0x150e76([0x2a])));}function _0x1dc355(){return _0x17b314&&_0xf2913e?new window[(_0x150e76([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x2f71ad,_0x218e4c)=>{_0x17b314[_0x150e76([0x74,0x68,0x65,0x6e])](_0x2f71ad,_0x218e4c),_0xf2913e[_0x150e76([0x74,0x68,0x65,0x6e])](_0x3ba16c=>{_0x3ba16c!=_0x150e76([0x56,0x61,0x6c,0x69,0x64])&&_0x2f71ad(_0x3ba16c);},_0x218e4c);}):_0x17b314||_0xf2913e||_0x150e76([0x56,0x61,0x6c,0x69,0x64]);}}function _0xadd64(_0x93480f,_0x3ef2c6){return new window[(_0x150e76([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0xde6cf3=>{if(_0x385e10())return _0xde6cf3(_0x150e76([0x56,0x61,0x6c,0x69,0x64]));_0x57adf6(),_0x29506b[_0x150e76([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x150e76([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x41ded1=!0x1;const _0x54a4e6=_0x4339db();function _0x1af293(_0x3c5cf4){return!!_0x3c5cf4&&(typeof _0x3c5cf4===_0x150e76([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x3c5cf4===_0x150e76([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x3c5cf4[_0x150e76([0x74,0x68,0x65,0x6e])]===_0x150e76([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x3c5cf4[_0x150e76([0x63,0x61,0x74,0x63,0x68])]===_0x150e76([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x54f5de(_0x4e91ad){_0x21b43c(_0x4e91ad)[_0x150e76([0x74,0x68,0x65,0x6e])](_0x245b02=>{if(!_0x245b02||_0x245b02[_0x150e76([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x150e76([0x6f,0x6b]))return _0x150e76([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x2ef557(_0x5b3af1(_0x54a4e6+_0x3ef2c6))!=_0x245b02[_0x150e76([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x150e76([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x150e76([0x56,0x61,0x6c,0x69,0x64]);})[_0x150e76([0x74,0x68,0x65,0x6e])](_0x44d04a=>(_0x2ed3b5(),_0x44d04a),()=>{const _0x445eaf=_0xc23afa();return null==_0x445eaf?(_0x2ed3b5(),_0x150e76([0x56,0x61,0x6c,0x69,0x64])):_0x150e76(_0x7d4b0e-_0x445eaf>(0x73f38e18^_0x3ca11e)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x150e76([0x74,0x68,0x65,0x6e])](_0xde6cf3)[_0x150e76([0x63,0x61,0x74,0x63,0x68])](()=>{_0xde6cf3(_0x150e76([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x3cf46f=0x57c9e498^_0x3ca11e;function _0x2ed3b5(){const _0x2eb515=_0x150e76([0x6c,0x6c,0x63,0x74,0x2d])+_0x2ef557(_0x5b3af1(_0x93480f)),_0x2d4142=_0x1e960b(_0x2ef557(window[_0x150e76([0x4d,0x61,0x74,0x68])][_0x150e76([0x63,0x65,0x69,0x6c])](_0x7d4b0e/_0x3cf46f)));window[_0x150e76([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x150e76([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x2eb515,_0x2d4142);}function _0xc23afa(){const _0x2578a7=_0x150e76([0x6c,0x6c,0x63,0x74,0x2d])+_0x2ef557(_0x5b3af1(_0x93480f)),_0x25abc4=window[_0x150e76([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x150e76([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x2578a7);return _0x25abc4?window[_0x150e76([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x1e960b(_0x25abc4),0x10)*_0x3cf46f:null;}function _0x21b43c(_0x4ada66){return new window[(_0x150e76([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x23aca9,_0x324538)=>{_0x4ada66[_0x150e76([0x74,0x68,0x65,0x6e])](_0x23aca9,_0x324538),window[_0x150e76([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x324538,0x57feded8^_0x3ca11e);});}}_0x29506b[_0x150e76([0x6f,0x6e])](_0x150e76([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x12ea52,_0x35e561)=>{if(_0x35e561[0x0]!=_0x93480f)return _0xde6cf3(_0x150e76([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x35e561[0x1]={..._0x35e561[0x1],[_0x150e76([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x54a4e6};},{[_0x150e76([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x150e76([0x68,0x69,0x67,0x68])}),_0x29506b[_0x150e76([0x6f,0x6e])](_0x150e76([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x4962c5=>{_0x1af293(_0x4962c5[_0x150e76([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x41ded1=!0x0,_0x54f5de(_0x4962c5[_0x150e76([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x150e76([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x150e76([0x6c,0x6f,0x77])}),_0x346143[_0x150e76([0x74,0x68,0x65,0x6e])](()=>{_0x41ded1||_0xde6cf3(_0x150e76([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x385e10(){return _0x29506b[_0x150e76([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x150e76([0x76,0x69,0x65,0x77])][_0x150e76([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x150e76([0x61,0x75,0x74,0x6f]);}function _0x57adf6(){_0x29506b[_0x150e76([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x150e76([0x76,0x69,0x65,0x77])][_0x150e76([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x150e76([0x61,0x75,0x74,0x6f]);}}function _0x91214e(_0x566226){const _0x3e40f1=[new window[(_0x150e76([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x41c432=>setTimeout(_0x41c432,0x57f634d4^_0x3ca11e)),_0x346143[_0x150e76([0x74,0x68,0x65,0x6e])](()=>new window[(_0x150e76([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x38fb6b=>{const _0x4facdd=0x57ff0a1f^_0x3ca11e,_0x4e0613=_0x3593c3[_0x150e76([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x25c78e(){_0x4e0613[_0x150e76([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x4facdd&&_0x38fb6b();}_0x25c78e(),_0x4e0613[_0x150e76([0x6f,0x6e])](_0x150e76([0x61,0x64,0x64]),_0x25c78e);})),new window[(_0x150e76([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x1baca6=>{function _0x1b25fa(){for(const _0x2d0d49 in window)if(window[_0x150e76([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x150e76([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x2d0d49))&&window[_0x2d0d49]==_0x3ee1b2)return _0x1baca6();_0x29506b[_0x150e76([0x73,0x74,0x61,0x74,0x65])]!=_0x150e76([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x150e76([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x1b25fa,0x57ff1990^_0x3ca11e);}_0xf2ddf9(_0x150e76([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x1b25fa();})];return window[_0x150e76([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x150e76([0x72,0x61,0x63,0x65])](_0x3e40f1)[_0x150e76([0x74,0x68,0x65,0x6e])](()=>_0x566226);}async function _0x550a7c(){if(await _0x346143,_0xf2ddf9(_0x150e76([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x19104e=_0x3593c3[_0x150e76([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x529bc7=_0x3593c3[_0x150e76([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])](_0x19104e[_0x150e76([0x69,0x64])]),_0x1cb50e=_0x9a8dfb(_0x150e76([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x1cb50e[_0x150e76([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x19104e['id'],_0x529bc7?_0x529bc7['id']:null,!0x0),_0x1cb50e[_0x150e76([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x150e76([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x1cb50e[_0x150e76([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x1cb50e[_0x150e76([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x46dfba,void(_0x1cb50e[_0x150e76([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x46dfba);}if(_0xf2ddf9(_0x150e76([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x17f894=_0x9a8dfb(_0x150e76([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x17f894[_0x150e76([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x150e76([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x17f894[_0x150e76([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x17f894[_0x150e76([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x46dfba,_0x17f894[_0x150e76([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x46dfba;}_0x29506b[_0x150e76([0x6d,0x6f,0x64,0x65,0x6c])][_0x150e76([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x46dfba,_0x29506b[_0x150e76([0x6d,0x6f,0x64,0x65,0x6c])][_0x150e76([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x46dfba,_0x29506b[_0x150e76([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x150e76([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x1993fb(){return _0xf2ddf9(_0x150e76([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x9a8dfb(_0x150e76([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x150e76([0x73,0x74,0x61,0x74,0x65])]==_0x150e76([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x287c6b(){return _0xf2ddf9(_0x150e76([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 _0x124584(){return _0xf2ddf9(_0x150e76([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x17870b(_0xf8130b){const _0x282def=_0x31c28d();_0x29506b[_0x282def]=_0x150e76([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])+_0xf8130b,_0xf8130b[_0x150e76([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x150e76([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x31c28d()]=_0x3ee1b2),_0xf8130b!=_0x150e76([0x56,0x61,0x6c,0x69,0x64])&&_0x550a7c();}function _0x31c28d(){const _0x5255e1=window[_0x150e76([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x150e76([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x150e76([0x6e,0x6f,0x77])]())[_0x150e76([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x150e76([0x2e]),'');let _0x5d8fa2=_0x150e76([0x48]);for(let _0x467e53=0x0;_0x467e53<_0x5255e1[_0x150e76([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x467e53+=0x2){let _0x368db5=window[_0x150e76([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x5255e1[_0x150e76([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x467e53,_0x467e53+0x2));_0x368db5>=_0xe85ed3[_0x150e76([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x368db5-=_0xe85ed3[_0x150e76([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x5d8fa2+=_0xe85ed3[_0x368db5];}return _0x5d8fa2;}function _0x4f637d(){const _0x2709f9=_0x3a8fd9[_0x150e76([0x73,0x70,0x6c,0x69,0x74])](_0x150e76([0x2e]));if(0x3!=_0x2709f9[_0x150e76([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x1dcf79(_0x2709f9[0x1]);function _0x1dcf79(_0x2e9c17){const _0x14e73f=_0x4c6e97(_0x2e9c17);return _0x14e73f&&_0x357733()?_0x14e73f:null;function _0x357733(){const _0x3ae5c1=_0x14e73f[_0x150e76([0x6a,0x74,0x69])],_0x2e3e89=window[_0x150e76([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x3ae5c1[_0x150e76([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x3ae5c1[_0x150e76([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x5753f9={..._0x14e73f,[_0x150e76([0x6a,0x74,0x69])]:_0x3ae5c1[_0x150e76([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x3ae5c1[_0x150e76([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x5753f9[_0x150e76([0x76,0x63])],_0x5b3af1(_0x5753f9)==_0x2e3e89;}}}async function _0x3a4a64(){let _0x7d9910=!0x0;try{const _0x3978fb=_0x3a8fd9[_0x150e76([0x73,0x70,0x6c,0x69,0x74])](_0x150e76([0x2e])),[_0x250b83,_0x2eeae5,_0xd79b8]=_0x3978fb;return _0x93f3b3(_0x250b83),await _0x145da6(_0x250b83,_0x2eeae5,_0xd79b8),_0x7d9910;}catch(_0x35d4d8){return!0x1;}function _0x93f3b3(_0x29fd6d){const _0x15a4a2=_0x4c6e97(_0x29fd6d);_0x15a4a2&&_0x15a4a2[_0x150e76([0x61,0x6c,0x67])]==_0x150e76([0x45,0x53,0x32,0x35,0x36])||(_0x7d9910=!0x1);}async function _0x145da6(_0x54725c,_0x40a770,_0x1868fc){const _0x3569d4=window[_0x150e76([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x150e76([0x66,0x72,0x6f,0x6d])](_0x2a17ff(_0x1868fc),_0x3e83f4=>_0x3e83f4[_0x150e76([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x5a3b96=new window[(_0x150e76([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x150e76([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x54725c+_0x150e76([0x2e])+_0x40a770),_0x4665e0=window[_0x150e76([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x150e76([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x4665e0)return;const _0x221719=await _0x4665e0[_0x150e76([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x150e76([0x6a,0x77,0x6b]),_0x9b1e09,{[_0x150e76([0x6e,0x61,0x6d,0x65])]:_0x150e76([0x45,0x43,0x44,0x53,0x41]),[_0x150e76([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x150e76([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x150e76([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x4665e0[_0x150e76([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x150e76([0x6e,0x61,0x6d,0x65])]:_0x150e76([0x45,0x43,0x44,0x53,0x41]),[_0x150e76([0x68,0x61,0x73,0x68])]:{[_0x150e76([0x6e,0x61,0x6d,0x65])]:_0x150e76([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x221719,_0x3569d4,_0x5a3b96)||(_0x7d9910=!0x1);}}function _0x4c6e97(_0x34ef72){return _0x34ef72[_0x150e76([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x150e76([0x65,0x79]))?JSON[_0x150e76([0x70,0x61,0x72,0x73,0x65])](_0x2a17ff(_0x34ef72)):null;}function _0x2a17ff(_0x386848){return window[_0x150e76([0x61,0x74,0x6f,0x62])](_0x386848[_0x150e76([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x150e76([0x2b]))[_0x150e76([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x150e76([0x2f])));}function _0x5b3af1(_0xedb4f3){let _0x6d2ac6=0x1505;function _0x1892ce(_0x3824a7){for(let _0x1003eb=0x0;_0x1003eb<_0x3824a7[_0x150e76([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x1003eb++){const _0x128da=_0x3824a7[_0x150e76([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x1003eb);_0x6d2ac6=(_0x6d2ac6<<0x5)+_0x6d2ac6+_0x128da,_0x6d2ac6&=_0x6d2ac6;}}function _0x3dd55e(_0x3a8a02){Array[_0x150e76([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x3a8a02)?_0x3a8a02[_0x150e76([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x3dd55e):_0x3a8a02&&typeof _0x3a8a02==_0x150e76([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x150e76([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x3a8a02)[_0x150e76([0x73,0x6f,0x72,0x74])]()[_0x150e76([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x2c3643,_0x40d2ad])=>{_0x1892ce(_0x2c3643),_0x3dd55e(_0x40d2ad);}):_0x1892ce(window[_0x150e76([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x3a8a02));}return _0x3dd55e(_0xedb4f3),_0x6d2ac6>>>0x0;}function _0x2ef557(_0x51841e){return _0x51841e[_0x150e76([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x150e76([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x150e76([0x30]));}function _0x1e960b(_0x2d287e){return _0x2d287e[_0x150e76([0x73,0x70,0x6c,0x69,0x74])]('')[_0x150e76([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x150e76([0x6a,0x6f,0x69,0x6e])]('');}function _0xf2ddf9(_0x538e0f){return _0x29506b[_0x150e76([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x150e76([0x68,0x61,0x73])](_0x538e0f);}function _0x9a8dfb(_0x9029da){return _0x29506b[_0x150e76([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x150e76([0x67,0x65,0x74])](_0x9029da);}function _0x46dfba(){}function _0x150e76(_0x1fb3cb){return _0x1fb3cb['map'](_0x295d0e=>String['fromCharCode'](_0x295d0e))['join']('');}_0x17870b(await _0x31a924());}(this);}['createRevision'](_0x4a5883){const _0x3233e4=this['editor']['plugins']['get']('Users');return new h({'id':_0x4a5883['id'],'name':_0x4a5883['name'],'creator':_0x4a5883['creatorId']?_0x3233e4['getUser'](_0x4a5883['creatorId']):null,'diffData':_0x4a5883['diffData']||_0x4a5883['data'],'authors':_0x4a5883['authorsIds']['map'](_0x34c791=>_0x3233e4['getUser'](_0x34c791)),'createdAt':new Date(_0x4a5883['createdAt']),'attributes':_0x4a5883['attributes'],'fromVersion':_0x4a5883['fromVersion'],'toVersion':_0x4a5883['toVersion']});}['addRevision'](_0x67f873,_0x541c52=0x0){this['_revisions']['add'](_0x67f873,_0x541c52);}['getRevision'](_0x518ff0){return this['_revisions']['get'](_0x518ff0);}['getRevisions'](_0x28307f={'toJSON':!0x1}){const _0x460240=Array['from'](this['_revisions']);return _0x460240['reverse'](),_0x28307f['toJSON']?_0x460240['map'](_0x1398b7=>_0x1398b7['toJSON']()):_0x460240;}['getIndex'](_0xc94654){return this['_revisions']['getIndex'](_0xc94654);}['getEarlierVisibleRevision'](_0x45869d){const [,_0x94cabe]=this['getRevisionsIterator'](_0x45869d,{'direction':'earlier'});return _0x94cabe;}['getLaterVisibleRevision'](_0x4f8219){const [,_0x2664ca]=this['getRevisionsIterator'](_0x4f8219,{'direction':'later'});return _0x2664ca;}['getRevisionsInDiff'](_0x3ea62a){const _0x54966e=[];for(const _0x2b2916 of this['getRevisionsIterator'](_0x3ea62a['newRevisionId']))if(_0x54966e['push'](_0x2b2916),_0x2b2916['id']===_0x3ea62a['oldRevisionId'])break;return _0x54966e;}*['getRevisionsIterator'](_0xb0f20a,{direction:_0x5b93ec='earlier',filter:_0x3f8f20=()=>!0x0}={}){const _0x286634='earlier'===_0x5b93ec?0x1:-0x1;let _0x4b4436=this['_revisions']['get'](_0xb0f20a),_0x166281=this['getIndex'](_0x4b4436);for(yield _0x4b4436;_0x4b4436;){if(_0x166281+=_0x286634,_0x4b4436=this['getRevision'](_0x166281),!_0x4b4436)return;_0x3f8f20(_0x4b4436)&&(yield _0x4b4436);}}}class V extends _0x47ebf6{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x5cb939,'c'],[_0x1e96d3,'a'],[_0xb2d956,'e'],[_0x4bacf8,'r'],[_0x457f5e,'u']]);['_typeCharToViewClass']=new Map([['c',_0x5cb939],['a',_0x1e96d3],['e',_0xb2d956],['r',_0x4bacf8],['u',_0x457f5e]]);async['loadRevisionData'](_0x1030b0,_0x591318){if(_0x1030b0['diffData']||!_0x591318)return;const _0x6cde46=this['editor']['config']['get']('collaboration.channelId'),_0x15b253=await _0x591318['getRevision']({'channelId':_0x6cde46,'revisionId':_0x1030b0['id']});_0x1030b0['diffData']=_0x15b253['diffData'];}['getRevisionDocumentData'](_0x3c4efa){const _0x391740={};for(const _0x21b2d8 in _0x3c4efa['diffData']){if(_0x3c4efa['diffData'][_0x21b2d8]['attachChange']&&!_0x3c4efa['diffData'][_0x21b2d8]['attachChange']['isAttached'])continue;const _0xe512d7=this['_removeRevisionMarkers'](JSON['parse'](_0x3c4efa['diffData'][_0x21b2d8]['insertions'])),_0x42c456=this['editor']['editing']['view']['document'],_0x22abe5=new _0x4915e2(_0x42c456,_0xe512d7['map'](_0x4ae673=>this['_getViewFromDiffObj'](_0x4ae673,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x391740[_0x21b2d8]=this['editor']['data']['processor']['toData'](_0x22abe5),this['editor']['data']['processor']['useFillerType']('default');}return _0x391740;}['getRevisionRootsAttributes'](_0x2df786){const _0x4b1852={};for(const _0x2eb5f8 in _0x2df786['diffData'])_0x2df786['diffData'][_0x2eb5f8]['attachChange']&&!_0x2df786['diffData'][_0x2eb5f8]['attachChange']['isAttached']||(_0x4b1852[_0x2eb5f8]=_0x2df786['diffData'][_0x2eb5f8]['attributesAfter']||{});return _0x4b1852;}['_getTypeCharForViewElement'](_0x119366){return this['_viewClassToTypeChar']['get'](_0x119366['constructor']);}['_getViewFromDiffObj'](_0x48aaad,_0x2e13e3){const _0x5a5eaa=this['editor']['editing']['view']['document'];if('string'==typeof _0x48aaad)return new _0x3184b0(_0x5a5eaa,_0x48aaad);{let _0x4fe9ce,_0x1784dd;_0x1784dd='u'==_0x48aaad['type']||'r'==_0x48aaad['type']?[]:_0x48aaad['children']['map'](_0xa1a1f3=>this['_getViewFromDiffObj'](_0xa1a1f3,_0x2e13e3));const _0x25a75f=this['_typeCharToViewClass']['get'](_0x48aaad['type'])||_0x33a722,_0x5166d2=this['editor']['data']['htmlProcessor']['domConverter'];if(_0x4fe9ce=new _0x25a75f(_0x5a5eaa,_0x48aaad['name'],_0x48aaad['attributes'],_0x1784dd),'u'==_0x48aaad['type']){const _0x1c9c7c=_0x48aaad['children'][0x0];if(_0x4fe9ce['render']=function(_0x5c85e6){const _0x54bde5=_0x5c85e6['createElement']('div');return _0x54bde5['innerHTML']=_0x1c9c7c,_0x54bde5['childNodes'][0x0];},_0x2e13e3){const _0x118e72=new _0x4915e2(_0x5a5eaa);_0x118e72['_appendChild'](_0x4fe9ce);const _0x575eff=Array['from'](_0x5166d2['viewChildrenToDom'](_0x118e72,{'bind':!0x1})),_0xa37553=_0x5166d2['domDocument']['createElement']('div');_0xa37553['append'](..._0x575eff),_0x4fe9ce=Array['from'](_0x5166d2['domChildrenToView'](_0xa37553))[0x0];}}else{if('r'==_0x48aaad['type']){const _0x212809=_0x48aaad['children'][0x0];if(_0x4fe9ce['render']=function(_0x2da914){_0x2da914['innerHTML']=_0x212809;},_0x2e13e3){const _0x13a93d=new _0x4915e2(_0x5a5eaa);_0x13a93d['_appendChild'](_0x4fe9ce);const _0x33fb7e=Array['from'](_0x5166d2['viewChildrenToDom'](_0x13a93d,{'bind':!0x1})),_0x410a78=_0x5166d2['domDocument']['createElement']('div');_0x410a78['append'](..._0x33fb7e);const _0x51b6d0=Array['from'](_0x5166d2['domChildrenToView'](_0x410a78));_0x51b6d0['length']>0x1?_0x4fe9ce['_appendChild'](_0x51b6d0):_0x4fe9ce=_0x51b6d0[0x0];}}}if(_0x48aaad['customProperties']){for(const [_0x36be6e,_0xffc816]of _0x48aaad['customProperties'])_0x4fe9ce['_setCustomProperty'](_0x36be6e,_0xffc816);}const _0x184f67=_0x48aaad['fillerOffset']||null;return _0x4fe9ce['getFillerOffset']=()=>_0x184f67,_0x4fe9ce;}}['_makeModelFromViewString'](_0x544743){const _0x5a30e1=JSON['parse'](_0x544743),_0x51b57d=this['editor']['editing']['view']['document'],_0x3caf83=new _0x4915e2(_0x51b57d,_0x5a30e1['map'](_0x558727=>this['_getViewFromDiffObj'](_0x558727,!0x0)));return this['editor']['data']['toModel'](_0x3caf83);}['_removeRevisionMarkers'](_0x1096d5){return(_0x1096d5=_0x1096d5['filter'](_0x1d3b51=>!_0x1d3b51['name']||'revision-start'!==_0x1d3b51['name']&&'revision-end'!==_0x1d3b51['name']))['forEach'](_0x40023a=>{'string'!=typeof _0x40023a&&(_0x40023a['children']=this['_removeRevisionMarkers'](_0x40023a['children']),_0x40023a['attributes']=_0x40023a['attributes']['filter'](_0x5f4cda=>!_0x5f4cda[0x0]['startsWith']('data-revision-')));}),_0x1096d5;}}function g(_0x26f839,_0x16e6e8,_0x35661e){const t=_0x26f839['t'];switch(_0x16e6e8){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'},_0x35661e);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x35661e);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 _0x47ebf6{['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[_0x181a91,I,V,_0x5a98bd];}constructor(_0x477d53){super(_0x477d53),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 _0x3ed42f=_0x4339db();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x3ed42f},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 _0x4309c7=this['repository']['getRevision'](0x0),_0x3fece0=_0x4309c7&&null===_0x4309c7['creator']?_0x4309c7:null;if(this['_continueCurrentRevision']=!!_0x3fece0&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x984671=this['_source']['getCurrentRevisionId'](),_0x5c5222=this['repository']['getRevision'](_0x984671);if(_0x5c5222)this['_startingVersion']=_0x5c5222['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x69d069=this['_source']['history']['_operations']['find'](_0x44d89a=>!_0x44d89a['_isInit']),_0x8d0145=_0x69d069?_0x69d069['baseVersion']:this['_source']['history']['version'];_0x4309c7?(_0x4309c7['toVersion']<_0x8d0145&&_0x4309c7['_update']({'toVersion':_0x8d0145}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x3fece0['id'],this['_startingVersion']=_0x3fece0['fromVersion']):(this['_startingVersion']=_0x4309c7['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x8d0145,this['_continueCurrentRevision']=!0x1);}}else _0x3fece0&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x3fece0['toVersion'],this['editor']['model']['document']['history']['version']),_0x3fece0['fromVersion']===_0x3fece0['toVersion']?(0x0!==_0x3fece0['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x3fece0['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x3fece0['id'],this['_startingVersion']=_0x3fece0['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',_0x513a96=>!_0x513a96),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x42a3e8=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x4538d9;for(const _0x4f9e69 in _0x42a3e8){const _0x161883=_0x4f9e69,_0x5a5cb3=_0x42a3e8[_0x161883];if('revisionHistoryLicenseKeyValid'==_0x5a5cb3||'revisionHistoryLicenseKeyInvalid'==_0x5a5cb3||'revisionHistoryLicenseKeyExpired'==_0x5a5cb3||'revisionHistoryLicenseKeyDomainLimit'==_0x5a5cb3||'revisionHistoryLicenseKeyNotAllowed'==_0x5a5cb3||'revisionHistoryLicenseKeyEvaluationLimit'==_0x5a5cb3||'revisionHistoryLicenseKeyTrialLimit'==_0x5a5cb3||'revisionHistoryLicenseKeyUsageLimit'==_0x5a5cb3){delete _0x42a3e8[_0x161883],_0x4538d9=_0x5a5cb3,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x4538d9&&_0x42a3e8['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x4538d9&&_0x42a3e8['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x4538d9&&_0x42a3e8['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x4538d9&&_0x42a3e8['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x4538d9&&_0x42a3e8['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x4538d9&&_0x42a3e8['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x4538d9&&_0x42a3e8['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x1e1830=this['repository']['getRevision'](0x0),_0x26e98e=await this['getRevisionDocumentData'](_0x1e1830),_0x45f8d8=await this['getRevisionRootsAttributes'](_0x1e1830);this['_replaceEditorDataWithRevisionData'](_0x26e98e,_0x45f8d8);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x24b492){this['_source']=_0x24b492;}async['update'](){const _0x2c97d0=await this['_source']['getLatestVersion']();if(_0x2c97d0>this['currentRevision']['toVersion']){await this['_loadState']();const _0x591f82=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x2c97d0});_0x591f82['authors']=_0x591f82['authorsIds']['map'](_0x510393=>this['editor']['plugins']['get']('Users')['getUser'](_0x510393)),this['currentRevision']['_update'](_0x591f82);}}async['saveRevision'](_0x5eeab2={},_0x32afec=null){const _0x4f43b6=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x32afec>this['currentRevision']['toVersion']&&(_0x32afec=null),null===_0x32afec&&(_0x32afec=await this['_source']['getLatestVersion']());const _0x399282=this['_getFromVersion'](_0x32afec),_0x459198=this['buildRevisionData']({'from':_0x399282,'to':_0x32afec});if(this['currentRevision']['toVersion']<_0x32afec){const _0x1bb993=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x32afec,'to':_0x32afec});_0x1bb993['authors']=[],_0x1bb993['authorsIds']=[],_0x1bb993['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x1bb993,!0x0),delete _0x1bb993['authors'],_0x4f43b6['push'](_0x1bb993);}_0x5eeab2['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x5eeab2['name']=_0x5eeab2['name']||null,_0x5eeab2['id']=_0x5eeab2['id']||_0x4339db(),_0x5eeab2={..._0x5eeab2,..._0x459198};const _0x4954cf=this['addRevisionData'](_0x5eeab2);_0x4f43b6['push'](_0x5eeab2);const _0x196455=this['repository']['getIndex'](_0x4954cf);if(0x0!==_0x196455){const _0x12246d=this['repository']['getRevision'](_0x196455-0x1);if(_0x12246d['fromVersion']!==_0x32afec){const _0x274ed5=this['_revisionDataBuilder']['getData'](_0x32afec,_0x12246d['toVersion']),_0xaea6d1={'id':_0x12246d['id'],'diffData':_0x274ed5['diffData'],'authorsIds':_0x274ed5['authorsIds'],'authors':_0x274ed5['authorsIds']['map'](_0xe200de=>this['editor']['plugins']['get']('Users')['getUser'](_0xe200de)),'fromVersion':_0x32afec};_0x12246d===this['currentRevision']&&(_0xaea6d1['createdAt']=new Date(_0x5eeab2['createdAt']['getTime']()+0xa)),_0x12246d['_update'](_0xaea6d1,!0x0),delete _0xaea6d1['authors'],_0x4f43b6['push'](_0xaea6d1);}}if(this['adapter']){for(const _0x5aa62c of _0x4f43b6)this['_bufferUpdate'](_0x5aa62c['id'],_0x5aa62c,!0x0);this['sendBufferedUpdates']();}return _0x4954cf;}['addRevisionData'](_0x4a9673){const _0x560fd2=this['repository']['createRevision'](_0x4a9673);return this['adapter']&&_0x560fd2['on']('_update',(_0x4cc883,_0x4c0376,_0x40c8cc)=>{_0x40c8cc||(this['_bufferUpdate'](_0x4c0376['id'],_0x4c0376,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x560fd2,this['_findInsertionIndex'](_0x560fd2)),_0x560fd2;}async['getRevisionDocumentData'](_0x1591a8){return await this['_utils']['loadRevisionData'](_0x1591a8,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x1591a8);}async['getRevisionRootsAttributes'](_0x505373){return await this['_utils']['loadRevisionData'](_0x505373,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x505373);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x260b16=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x24e622=0x0;_0x24e622<_0x260b16['length'];_0x24e622++){const _0x168010=_0x260b16[_0x24e622];let _0x3551f6=!0x1;for(const _0x1bcc5d of Object['keys'](_0x168010))void 0x0===_0x168010[_0x1bcc5d]?delete _0x168010[_0x1bcc5d]:'id'!==_0x1bcc5d&&(_0x3551f6=!0x0);_0x3551f6||(_0x260b16[_0x24e622]=null);}if(_0x260b16=_0x260b16['filter'](_0x38c01b=>null!==_0x38c01b),!_0x260b16['length'])return;for(let _0x5bc4b6=0x0;_0x5bc4b6<_0x260b16['length'];_0x5bc4b6++){const _0x2d52ef=_0x260b16[_0x5bc4b6];void 0x0!==_0x2d52ef['fromVersion']&&void 0x0===_0x2d52ef['toVersion']&&(_0x2d52ef['toVersion']=this['repository']['getRevision'](_0x2d52ef['id'])['toVersion']),void 0x0!==_0x2d52ef['toVersion']&&void 0x0===_0x2d52ef['fromVersion']&&(_0x2d52ef['fromVersion']=this['repository']['getRevision'](_0x2d52ef['id'])['fromVersion']);}const _0x2c4b89=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x260b16,_0x2c4b89)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x2e653c=>{if(_0x2e653c){for(const _0x4cd917 of _0x2e653c)this['setRevisionData']({'id':_0x4cd917['id'],'createdAt':_0x4cd917['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0x3448b1=null,from:_0x280bec=null,to:_0x1927a5=null}){_0x280bec=null!==_0x280bec?_0x280bec:_0x3448b1['fromVersion'],_0x1927a5=null!==_0x1927a5?_0x1927a5:_0x3448b1['toVersion'];const _0x3763da=this['_revisionDataBuilder']['getData'](_0x280bec,_0x1927a5),_0x2a1337={'diffData':_0x3763da['diffData'],'authorsIds':_0x3763da['authorsIds'],'fromVersion':_0x280bec,'toVersion':_0x1927a5};if(!_0x3448b1||_0x1927a5!==_0x3448b1['toVersion']){const _0x26002d=_0x1927a5-0x1,_0x331c8a=this['_source']['history']['getOperation'](_0x26002d);_0x2a1337['createdAt']=_0x331c8a&&_0x331c8a['createdAt']||new Date();}if(this['_loadedStateData']&&_0x280bec===this['_loadedStateData']['fromVersion']){for(const _0xedae57 of this['_loadedStateData']['authors'])_0x2a1337['authorsIds']['includes'](_0xedae57['id'])||_0x2a1337['authorsIds']['push'](_0xedae57['id']);}return _0x2a1337;}['_bufferUpdate'](_0xb4d80b,_0x3de8c6,_0xfdf1bf){if(this['_bufferedUpdates']['has'](_0xb4d80b)){const _0x1a7b86=this['_bufferedUpdates']['get'](_0xb4d80b);_0x3de8c6=_0xfdf1bf?{..._0x1a7b86,..._0x3de8c6}:{..._0x3de8c6,..._0x1a7b86};}this['_bufferedUpdates']['set'](_0xb4d80b,_0x3de8c6);}['setRevisionData'](_0x20d7ba){const _0x19be7e=this['repository']['getRevision'](_0x20d7ba['id']);if(_0x20d7ba['createdAt']&&(_0x20d7ba['createdAt']=new Date(_0x20d7ba['createdAt'])),_0x20d7ba['authorsIds']){const _0x503760=this['editor']['plugins']['get']('Users');_0x20d7ba['authors']=_0x20d7ba['authorsIds']['map'](_0x29f026=>_0x503760['getUser'](_0x29f026));}_0x19be7e['_update'](_0x20d7ba,!0x0);}['_createInitialRevision'](_0x3408b9){const _0x42ea18=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x42ea18)this['_initialRevisionId']=_0x42ea18['id'];else{const _0x5c2334=!this['editor']['model']['document']['roots']['find'](_0x1f72fa=>this['editor']['model']['hasContent'](_0x1f72fa)),_0x466d20=this['editor']['plugins']['get']('Users')['me']['id'],_0x5b0e8a=g(this['editor']['locale'],_0x5c2334?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x3408b9,'to':_0x3408b9,'id':this['_initialRevisionId'],'name':_0x5b0e8a,'creatorId':_0x466d20});}}['_createCurrentRevision'](_0x53c344){const _0x1c1000=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x1c1000),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x53c344,'to':_0x53c344,'id':_0x1c1000,'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'](_0x127da2,_0x53ef63){let _0x4c7ec1=this['editor']['config']['get']('initialData'),_0x2d2a46=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x4c7ec1){_0x4c7ec1={};for(const _0x29c681 of this['editor']['model']['document']['getRootNames']())_0x4c7ec1[_0x29c681]='';}if('string'==typeof _0x4c7ec1&&(_0x4c7ec1={'main':_0x4c7ec1}),void 0x0===_0x2d2a46){_0x2d2a46={};for(const _0x4b51c8 of this['editor']['model']['document']['getRootNames']())_0x2d2a46[_0x4b51c8]={};}let _0xc01ece=!0x1;const _0x29b31a=Object['keys'](_0x4c7ec1),_0x58f37c=Object['keys'](_0x127da2);for(const _0x2b3a48 of _0x29b31a){if(_0x4c7ec1[_0x2b3a48]!==_0x127da2[_0x2b3a48]&&''!==_0x4c7ec1[_0x2b3a48]['trim']()){_0xc01ece=!0x0;break;}if(!_0xe19125(_0x2d2a46[_0x2b3a48],_0x53ef63[_0x2b3a48])&&Object['keys'](_0x2d2a46[_0x2b3a48])['length']>0x0){_0xc01ece=!0x0;break;}}_0xc01ece||(_0xc01ece=_0x58f37c['some'](_0x24231a=>!this['editor']['model']['document']['getRoot'](_0x24231a))),_0xc01ece&&_0x2c9793('editor-initial-data-replaced-with-revision-data',{'editorData':_0x4c7ec1,'editorRootsAttributes':_0x2d2a46,'revisionData':_0x127da2,'revisionRootsAttributes':_0x53ef63}),this['editor']['config']['set']('initialData',_0x127da2),this['editor']['config']['set']('rootsAttributes',_0x53ef63);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x1061b8=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x1061b8['add'](g(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x4bc774){const _0x1123c=this['repository']['getRevisions']();_0x1123c['reverse']();let _0x222e52=0x0;for(;_0x222e52<_0x1123c['length'];){const _0x21c8a9=_0x1123c[_0x222e52];if(_0x21c8a9===this['currentRevision']){_0x222e52++;continue;}if(_0x21c8a9['id']===this['_initialRevisionId'])break;const _0x1d55bf=_0x4bc774['toVersion']-_0x21c8a9['toVersion']||_0x4bc774['fromVersion']-_0x21c8a9['fromVersion'];if(_0x1d55bf>0x0)break;if(_0x1d55bf<0x0)_0x222e52++;else{if(!_0x4bc774['creator']&&_0x21c8a9['creator'])break;if(_0x21c8a9['creator']||!_0x4bc774['creator']){if(_0x4bc774['createdAt']>_0x21c8a9['createdAt'])break;_0x222e52++;}else _0x222e52++;}}return _0x222e52;}['_getFromVersion'](_0x4accfb){const _0x5419e9=this['repository']['getRevisions']();_0x5419e9['reverse'](),_0x5419e9['shift']();const _0x3ec1bc=_0x5419e9['find'](_0x292c8a=>_0x292c8a['toVersion']<=_0x4accfb)['toVersion'];return _0x3ec1bc<this['_startingVersion']?this['_startingVersion']:_0x3ec1bc;}['_makeRevision']({name:_0x55265d,from:_0x3f03fb,to:_0x2c151e,creatorId:_0x8ee008,id:_0x30a210}){const _0x31eb71=this['buildRevisionData']({'from':_0x3f03fb,'to':_0x2c151e});_0x31eb71['name']=_0x55265d,_0x31eb71['creatorId']=_0x8ee008,_0x31eb71['id']=_0x30a210;const _0x448a8f=this['addRevisionData'](_0x31eb71);return this['adapter']&&this['_bufferUpdate'](_0x31eb71['id'],_0x31eb71,!0x0),_0x448a8f;}['_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(_0x26110f){this['editor']=_0x26110f,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'](_0x6da20c){this['source']=_0x6da20c;const _0x635891=new Map(),_0x3cbf46=new Map(),_0x194cb3=this['editor']['model']['document']['roots']['map'](_0x1aad52=>_0x1aad52['rootName']);for(const _0x426239 of _0x194cb3){const _0x3d0f98=this['editor']['model']['document']['getRoot'](_0x426239),_0xdeb1e6=N(_0x3d0f98);_0x635891['set'](_0x426239,_0xdeb1e6),_0x3cbf46['set'](_0x426239,Object['fromEntries'](_0x3d0f98['getAttributes']()));}const _0x18cdef=Array['from'](this['editor']['model']['markers'])['map'](_0x57e5c6=>[_0x57e5c6['name'],_0x57e5c6['getRange']()]),_0x458b59=this['source']['version'];this['_saveMetaData'](_0x458b59,_0x635891,_0x18cdef,_0x3cbf46),this['_startingRevisionId']=this['_revisionId'];const _0x29b84e=new Map(),_0x4d52eb=new Map();for(const _0xc0315a of _0x194cb3){const _0x230ad5=P(_0xc0315a);_0x29b84e['set'](_0xc0315a,_0x230ad5),_0x4d52eb['set'](_0xc0315a,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x29b84e,[],_0x4d52eb);}['getData'](_0x25adfd,_0x4e8b4a){if(this['_lastFrom']===_0x25adfd&&this['_lastTo']<=_0x4e8b4a)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x4e8b4a,!0x0);else{if(!this['_savedMetaData']['has'](_0x25adfd)){const _0x413131=this['_getPreviousFrom'](_0x25adfd);this['_calculateMetaData'](_0x413131,_0x25adfd,!0x1);}this['_calculateMetaData'](_0x25adfd,_0x4e8b4a,!0x0);}return this['_lastFrom']=_0x25adfd,this['_lastTo']=_0x4e8b4a,this['_getState']();}['loadState'](_0xf6ef69){const _0x1d56d9=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0xf6ef69['fromVersion'],this['_lastTo']=_0xf6ef69['toVersion'];for(const _0xf88203 in _0xf6ef69['diffData']){const _0x5a9c09=_0xf6ef69['diffData'][_0xf88203]['attachChange'],_0x22b9e7=_0x5dbaa0(_0xf6ef69['diffData'][_0xf88203]['attributesBefore'])||{},_0x125ec4=_0x1d56d9['_makeModelFromViewString'](_0xf6ef69['diffData'][_0xf88203]['deletions']);_0x125ec4['rootName']=_0xf88203,_0x125ec4['_isAttached']=!_0x5a9c09||!_0x5a9c09['isAttached'],_0x125ec4['isAttached']=()=>_0x125ec4['_isAttached'],this['_baseRoots']['set'](_0xf88203,_0x125ec4),this['_baseRootsAttributes']['set'](_0xf88203,_0x22b9e7),_0x5a9c09&&this['_touchedRoots']['set'](_0xf88203,_0x5a9c09);const _0xb83c3c=this['_makeIdsRoot'](_0x125ec4);this['_baseIdsRoots']['set'](_0xf88203,_0xb83c3c);for(const [_0x3baafd,_0x4a935d]of _0x125ec4['markers']){if(!_0x3baafd['startsWith']('revision:'))continue;const _0x2bb4c9=_0x3baafd['split'](':')[0x2];for(const _0x14f94e of _0x4a935d['getWalker']({'singleCharacters':!0x0})){const _0x27dde8=this['_getVidAttributeName'](_0x14f94e),_0x1f5af7='elementEnd'==_0x14f94e['type']?_0x14f94e['previousPosition']['path']['slice'](0x0,-0x1):_0x14f94e['previousPosition']['path'],_0xd5a786=_0xb83c3c['getNodeByPath'](_0x1f5af7)['getAttribute'](_0x27dde8);this['_touched']['set'](_0xd5a786,{'userId':_0x2bb4c9});}}}this['_startingRevisionId']=this['_revisionId'];const _0x509959=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0xa4599=>!this['_touched']['has'](_0xa4599));let _0xb82caa=0x0;const _0x15bc3d=new Map();for(const _0x5462d6 in _0xf6ef69['diffData']){const _0x48de94=_0xf6ef69['diffData'][_0x5462d6]['attachChange'],_0x2dc17d=_0x5dbaa0(_0xf6ef69['diffData'][_0x5462d6]['attributesAfter'])||{},_0x3ca1da=_0x1d56d9['_makeModelFromViewString'](_0xf6ef69['diffData'][_0x5462d6]['insertions']);_0x3ca1da['rootName']=_0x5462d6,_0x3ca1da['_isAttached']=!_0x48de94||_0x48de94['isAttached'],_0x3ca1da['isAttached']=()=>_0x3ca1da['_isAttached'],this['_diffRoots']['set'](_0x5462d6,_0x3ca1da),this['_diffRootsAttributes']['set'](_0x5462d6,_0x2dc17d);const _0x71677f=this['_makeIdsRoot'](_0x3ca1da,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x5462d6,_0x71677f),_0x15bc3d['set'](_0x5462d6,_0x3ca1da['isAttached']()?_0x2dc17d:{});for(const [_0x255d0c,_0x9f1f50]of _0x3ca1da['markers']){if(!_0x255d0c['startsWith']('revision:'))continue;const _0x2e7f2e=_0x255d0c['split'](':')[0x2];for(const _0x5cdd97 of _0x9f1f50['getWalker']({'singleCharacters':!0x0})){const _0x5b50a9=this['_getVidAttributeName'](_0x5cdd97),_0x100173=this['_revisionId']++,_0x2747b4='elementEnd'==_0x5cdd97['type']?_0x5cdd97['previousPosition']['path']['slice'](0x0,-0x1):_0x5cdd97['previousPosition']['path'];_0x71677f['getNodeByPath'](_0x2747b4)['_setAttribute'](_0x5b50a9,_0x100173),this['_touched']['set'](_0x100173,{'userId':_0x2e7f2e});}}for(const _0x1bd007 of this['editor']['model']['createRangeIn'](_0x3ca1da)['getWalker']({'singleCharacters':!0x0})){const _0x5239bb=this['_getVidAttributeName'](_0x1bd007),_0x4d211b='elementEnd'==_0x1bd007['type']?_0x1bd007['previousPosition']['path']['slice'](0x0,-0x1):_0x1bd007['previousPosition']['path'],_0x3a0745=_0x71677f['getNodeByPath'](_0x4d211b);_0x3a0745['getAttribute'](_0x5239bb)>0x0||_0x3a0745['_setAttribute'](_0x5239bb,_0x509959[_0xb82caa++]);}for(const [_0xe96f10,_0x1fe3d]of _0x3ca1da['markers'])_0xe96f10['startsWith']('revision:')||this['_markers']['set'](_0xe96f10,_0x1fe3d);}const _0x439660=P('$graveyard');this['_baseRoots']['set']('$graveyard',_0x439660),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x439660,0x1));const _0x3374f5=P('$graveyard');this['_diffRoots']['set']('$graveyard',_0x3374f5),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x3374f5,0x1));const _0x5dcfdf=Array['from'](this['_diffRoots'])['map'](([_0x48db0d,_0x44b046])=>[_0x48db0d,N(_0x44b046)]);this['_saveMetaData'](this['_lastTo'],_0x5dcfdf,this['_markers'],_0x15bc3d);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0x5db557,_0x5b7bf3,_0x51b71f,_0x163929){const _0x2279db=new Map(_0x5b7bf3),_0x27b6c2=new Map(_0x5dbaa0(_0x163929)),_0x44e89=new Map();for(const [_0x48f00c,_0xa7a0c1]of _0x51b71f)_0x44e89['set'](_0x48f00c,{'start':_0xa7a0c1['start']['clone'](),'end':_0xa7a0c1['end']['clone'](),'rootName':_0xa7a0c1['root']['rootName']});this['_savedMetaData']['set'](_0x5db557,{'roots':_0x2279db,'markers':_0x44e89,'rootsAttributes':_0x27b6c2});}['_removeMetaData'](_0x294054){this['_savedMetaData']['delete'](_0x294054);}['_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'](_0x10653d,_0x50ad52=null){let _0x1dc8e5=null;_0x10653d['is']('documentFragment')||(_0x1dc8e5=new ut(_0x10653d['name'],{'vid_start':null===_0x50ad52?this['_revisionId']++:_0x50ad52++}));const _0x178882=[];for(const _0x7580a4 of _0x10653d['getChildren']())if(_0x7580a4['is']('element')){_0x178882['push'](this['_makeIdsRoot'](_0x7580a4,_0x50ad52));const _0x1b0ab4=_0x178882[_0x178882['length']-0x1];null!==_0x50ad52&&(_0x50ad52=_0x1b0ab4['is']('element','$text')?_0x1b0ab4['getAttribute']('vid')+0x1:_0x1b0ab4['getAttribute']('vid_end')+0x1);}else{for(let _0x262388=0x0;_0x262388<_0x7580a4['offsetSize'];_0x262388++)_0x178882['push'](new ut('$text',{'vid':null===_0x50ad52?this['_revisionId']++:_0x50ad52++}));}if(_0x10653d['is']('documentFragment')){const _0x562541=P(_0x10653d['rootName']);return _0x562541['_insertChild'](0x0,_0x178882),_0x562541;}return _0x1dc8e5['_setAttribute']('vid_end',null===_0x50ad52?this['_revisionId']++:_0x50ad52++),_0x1dc8e5['_insertChild'](0x0,_0x178882),_0x1dc8e5;}['_calculateMetaData'](_0x2487d9,_0x5351b6,_0x2fd2e9){this['_reset']();const {roots:_0x169359,markers:_0x462ba7,rootsAttributes:_0x59837d}=this['_savedMetaData']['get'](_0x2487d9);this['_baseRoots']=new Map(_0x169359),this['_baseRootsAttributes']=new Map(_0x5dbaa0(_0x59837d));for(const [_0x201782,_0x1da2b0]of this['_baseRoots'])if('$graveyard'!==_0x201782&&(this['_diffRoots']['set'](_0x201782,N(_0x1da2b0)),this['_diffRootsAttributes']=new Map(_0x5dbaa0(_0x59837d)),_0x2fd2e9)){const _0x12a280=this['_revisionId'];this['_idsRoots']['set'](_0x201782,this['_makeIdsRoot'](_0x1da2b0)),this['_baseIdsRoots']['set'](_0x201782,this['_makeIdsRoot'](_0x1da2b0,_0x12a280));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',N(this['_baseRoots']['get']('$graveyard'))),_0x2fd2e9&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x229cd3,_0x1c5c93]of _0x462ba7){const _0x1f07f8=this['_baseRoots']['get'](_0x1c5c93['rootName']),_0x4bb69b=this['_diffRoots']['get'](_0x1c5c93['rootName']),_0x5d6682=new ft(this['_fixPosition'](_0x1c5c93['start'],_0x1f07f8),this['_fixPosition'](_0x1c5c93['end'],_0x1f07f8)),_0x4c57d1=this['_fixRange'](_0x5d6682,_0x4bb69b);_0x1f07f8['markers']['set'](_0x229cd3,_0x5d6682),this['_markers']['set'](_0x229cd3,_0x4c57d1);}this['_applyOperations'](_0x2487d9,_0x5351b6,_0x2fd2e9);}['_applyOperations'](_0x235fcd,_0x34c34b,_0x2557ef){for(const _0x1b9538 of this['source']['getOperations'](_0x235fcd,_0x34c34b))this['_handleOperation'](_0x1b9538,_0x2557ef);for(const _0x530308 of this['_diffRoots']['values']())_0x530308['markers']['clear']();for(const [_0x2b3f2e,_0x37f40b]of this['_markers']){this['_diffRoots']['get'](_0x37f40b['root']['rootName'])['markers']['set'](_0x2b3f2e,_0x37f40b['clone']());}const _0x5735e5=new Map(),_0x43241a=new Map();for(const [_0x42bb26,_0x533820]of this['_diffRoots'])_0x5735e5['set'](_0x42bb26,N(_0x533820)),_0x43241a['set'](_0x42bb26,this['_diffRootsAttributes']['get'](_0x42bb26));this['_saveMetaData'](_0x34c34b,_0x5735e5,this['_markers'],_0x43241a);}['_getPreviousFrom'](_0x44b7d1){const _0x261502=Array['from'](this['_savedMetaData']['keys']());_0x261502['sort']((_0x3b298f,_0x3a32c8)=>_0x3b298f-_0x3a32c8),_0x261502['reverse']();for(const _0x38a386 of _0x261502)if(_0x38a386<_0x44b7d1)return _0x38a386;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x583e7e,_0x3b2772){const _0x27bc25=Array['from'](_0x3b2772['markers'])['map'](([_0x2a0e0d,_0x4338ff])=>[_0x2a0e0d,this['_fixRange'](_0x4338ff,_0x583e7e)]);_0x583e7e['markers']=new Map(_0x27bc25);}['_transformMarkers'](_0x362595){for(const _0x489602 of this['_markers']['values']()){const _0x55de0c=_0x489602['getTransformedByOperation'](_0x362595),_0x4b5d2d=ft['_createFromRanges'](_0x55de0c);_0x489602['start']=_0x4b5d2d['start'],_0x489602['end']=_0x4b5d2d['end'];}}['_handleOperation'](_0x2e558a,_0xde5024){if('addRoot'!=_0x2e558a['type']&&'detachRoot'!=_0x2e558a['type']){if('insert'==_0x2e558a['type']){const _0x20df01=_0x2e558a['position']['root']['rootName'];this['_diffRoots']['has'](_0x20df01)||(this['_diffRoots']['set'](_0x20df01,P(_0x20df01,!0x0)),this['_diffRootsAttributes']['set'](_0x20df01,{}),_0xde5024&&this['_idsRoots']['set'](_0x20df01,P(_0x20df01,!0x0)));}else{if('addRootAttribute'==_0x2e558a['type']||'removeRootAttribute'==_0x2e558a['type']||'changeRootAttribute'==_0x2e558a['type'])return void this['_handleRootAttributeOperation'](_0x2e558a);'marker'==_0x2e558a['type']&&this['_handleMarkerOperation'](_0x2e558a);}if('marker'!==_0x2e558a['type']){const _0x222acd=this['_cloneOperation'](_0x2e558a,this['_diffRoots']);_0x222acd['_execute'](),this['_transformMarkers'](_0x222acd);}if(_0xde5024)switch(_0x2e558a['type']){case'insert':this['_handleInsertOperation'](_0x2e558a);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x2e558a);break;case'merge':this['_handleMergeOperation'](_0x2e558a);break;case'split':this['_handleSplitOperation'](_0x2e558a);}}else this['_handleRootOperation'](_0x2e558a,_0xde5024);}['_cloneOperation'](_0x588bd0,_0x57b387){const _0x47f212=_0x588bd0['clone']();return _0x47f212['_authorId']=_0x588bd0['_authorId'],this['_fixOperation'](_0x47f212,_0x57b387),_0x47f212;}['_getBaseVids'](_0x46aff2){return _0x46aff2['map'](_0x2830db=>{const _0x329696=this['_getVidAttributeName'](_0x2830db);return Number(_0x2830db['item']['getAttribute'](_0x329696));});}['_generateTape'](_0xe381ed,_0x3e9397){if(_0xe381ed['is']('element','$text'))_0x3e9397['push']({'item':_0xe381ed,'type':'text'});else{_0xe381ed['is']('element')&&_0x3e9397['push']({'item':_0xe381ed,'type':'elementStart'});for(const _0x13fd17 of _0xe381ed['getChildren']())this['_generateTape'](_0x13fd17,_0x3e9397);_0xe381ed['is']('element')&&_0x3e9397['push']({'item':_0xe381ed,'type':'elementEnd'});}return _0x3e9397;}['_getState'](){const _0xde9cd5=new Map(this['_touched']),_0x1ab7b3=new Map(_0xde9cd5),_0x1e832a=new Map(),_0x44c2d8={'insertions':{},'deletions':{}},_0x3605ee={'insertions':{},'deletions':{}},_0x86d14e=new Map(),_0x38c4f5=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x38c4f5['delete']('$graveyard');for(const _0x2355b5 of _0x38c4f5){const _0x1534a4=this['_diffRoots']['get'](_0x2355b5)||P(_0x2355b5,!0x1),_0x37484d=this['_baseRoots']['get'](_0x2355b5)||P(_0x2355b5,!0x1);_0x1534a4['isAttached']()||_0x37484d['isAttached']()?(_0x44c2d8['insertions'][_0x2355b5]=N(_0x1534a4),_0x44c2d8['deletions'][_0x2355b5]=N(_0x37484d),this['_copyMarkers'](_0x44c2d8['deletions'][_0x2355b5],_0x37484d),this['_copyMarkers'](_0x44c2d8['insertions'][_0x2355b5],_0x1534a4),_0x3605ee['insertions'][_0x2355b5]=this['_generateTape'](this['_idsRoots']['get'](_0x2355b5),[]),_0x3605ee['deletions'][_0x2355b5]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x2355b5)||P(_0x2355b5,!0x1),[])):_0x38c4f5['delete'](_0x2355b5);}for(const _0x3ed896 of _0x38c4f5){const _0x3673a3=_0x3605ee['insertions'][_0x3ed896];for(const _0x50bb7c of _0x3673a3){const _0xc3684b=this['_getVidAttributeName'](_0x50bb7c),_0x46412b=_0x50bb7c['item']['getAttribute'](_0xc3684b);_0x1ab7b3['delete'](_0x46412b),_0x46412b>=this['_startingRevisionId']&&_0x1e832a['set'](_0x46412b,_0xde9cd5['get'](_0x46412b));}}for(const _0x174619 of _0x38c4f5){const _0x4368b6=_0x3605ee['insertions'][_0x174619],_0x19bd4c=this['_getBaseVids'](_0x3605ee['deletions'][_0x174619]);let _0x3b44a7=0x0;for(const _0x5570da of _0x4368b6){const _0x525762=this['_getVidAttributeName'](_0x5570da),_0x5b369e=_0x5570da['item']['getAttribute'](_0x525762);if(!_0x1e832a['has'](_0x5b369e)&&!_0x86d14e['has'](_0x5b369e)){if(_0x1ab7b3['has'](_0x5b369e))_0x3b44a7++;else{if(_0x5b369e!=_0x19bd4c[_0x3b44a7]){const _0x55623f=_0xde9cd5['get'](_0x5b369e)||_0xde9cd5['get'](_0x19bd4c[_0x3b44a7]);for(;_0x5b369e!=_0x19bd4c[_0x3b44a7];)_0x1ab7b3['has'](_0x19bd4c[_0x3b44a7])||(_0x86d14e['set'](_0x19bd4c[_0x3b44a7],_0x55623f),_0xde9cd5['set'](_0x19bd4c[_0x3b44a7],_0x55623f)),_0x3b44a7++;}_0x3b44a7++;}}}}for(const _0x23e6c6 of _0x38c4f5){const _0xb9e413=_0x3605ee['insertions'][_0x23e6c6];for(const _0x40b127 of _0xb9e413){const _0x530991=this['_getVidAttributeName'](_0x40b127),_0x5752b6=_0x40b127['item']['getAttribute'](_0x530991);if(_0x86d14e['has'](_0x5752b6)){const _0x1f2d11=_0x86d14e['get'](_0x5752b6);_0x1ab7b3['has'](_0x5752b6)||_0x1ab7b3['set'](_0x5752b6,{..._0x1f2d11}),_0x1e832a['set'](_0x5752b6,{..._0x1f2d11});}}}for(const _0x1a18bb of _0x1ab7b3['keys']())_0x1a18bb>=this['_startingRevisionId']&&_0x1ab7b3['delete'](_0x1a18bb);const _0x1ad12b=new Map();for(const _0xa16117 of _0x38c4f5){let _0x3a94c2=_0x3605ee['insertions'][_0xa16117];for(const _0x4e5071 of _0x3a94c2)if(_0x4e5071['item']['is']('element','tableCell')){const _0x30a3f4=this['_getVidAttributeName'](_0x4e5071),_0x186561=_0x4e5071['item']['getAttribute'](_0x30a3f4);if(_0x1e832a['has'](_0x186561)){const _0x2da764=_0x4e5071['item']['parent']['parent']['getAttribute']('vid_start'),_0xc3594f=_0x1ad12b['get'](_0x2da764)||new Set();_0xc3594f['add'](_0x1e832a['get'](_0x186561)['userId']),_0x1ad12b['set'](_0x2da764,_0xc3594f);}}_0x3a94c2=_0x3605ee['deletions'][_0xa16117];for(const _0x428c76 of _0x3a94c2)if(_0x428c76['item']['is']('element','tableCell')){const _0x205d28=this['_getVidAttributeName'](_0x428c76),_0x1f81dc=_0x428c76['item']['getAttribute'](_0x205d28);if(_0x1ab7b3['has'](_0x1f81dc)){const _0x34feb2=_0x428c76['item']['parent']['parent']['getAttribute']('vid_start'),_0x3203e2=_0x1ad12b['get'](_0x34feb2)||new Set();_0x3203e2['add'](_0x1ab7b3['get'](_0x1f81dc)['userId']),_0x1ad12b['set'](_0x34feb2,_0x3203e2);}}for(const _0x29a571 of _0x1ad12b['keys']())(_0x1e832a['has'](_0x29a571)||_0x1ab7b3['has'](_0x29a571))&&_0x1ad12b['delete'](_0x29a571);}for(const _0x1b980a of _0x38c4f5){const _0x392f3f=_0x3605ee['insertions'][_0x1b980a];let _0x5c5df8=null,_0x5f44bb=null;for(const _0x52a083 of _0x392f3f){const _0x34727a=this['_getVidAttributeName'](_0x52a083),_0x1935e6=_0x52a083['item']['getAttribute'](_0x34727a),_0x4deec7=_0x1ad12b['get'](_0x1935e6);_0x4deec7&&'elementStart'==_0x52a083['type']&&(_0x5c5df8=Array['from'](_0x4deec7)[0x0],_0x5f44bb=_0x52a083['item']['getAttribute']('vid_end')),_0x5c5df8&&(_0x1ab7b3['set'](_0x1935e6,{'userId':_0x5c5df8}),_0x1e832a['set'](_0x1935e6,{'userId':_0x5c5df8})),_0x1935e6==_0x5f44bb&&(_0x5c5df8=null,_0x5f44bb=null);}}const _0x4f9a26={},_0x214570=new Set();for(const _0x275681 of _0x38c4f5){const _0x3fe24a=_0x44c2d8['deletions'][_0x275681],_0x11f921=_0x44c2d8['insertions'][_0x275681];for(const {userId:_0x430461}of this['_touchedMarkers']['values']())null!==_0x430461&&_0x214570['add'](_0x430461);for(const {userId:_0x38e0e9}of this['_touchedRoots']['values']())null!==_0x38e0e9&&_0x214570['add'](_0x38e0e9);this['_markChanges'](_0x11f921,_0x3605ee['insertions'][_0x275681],_0x1e832a,'insertion',_0x214570),this['_markChanges'](_0x3fe24a,_0x3605ee['deletions'][_0x275681],_0x1ab7b3,'deletion',_0x214570),_0x4f9a26[_0x275681]={'insertions':this['_prepareViewToSave'](_0x11f921),'deletions':this['_prepareViewToSave'](_0x3fe24a),'attachChange':this['_touchedRoots']['get'](_0x275681)||null,'attributesBefore':_0x5dbaa0(this['_baseRootsAttributes']['get'](_0x275681))||{},'attributesAfter':_0x5dbaa0(this['_diffRootsAttributes']['get'](_0x275681))};}return{'diffData':_0x4f9a26,'authorsIds':Array['from'](_0x214570)};}['_processRootBeforeSave'](_0x1d380f){for(const [,_0xeb2c46]of _0x1d380f['markers']){const _0xcd9689=_0xeb2c46['start']['getAncestors']()['filter'](_0x1e19ad=>'tableCell'==_0x1e19ad['name']);for(const _0x40111a of _0xcd9689)0x1==_0x40111a['childCount']&&_0x40111a['getChild'](0x0)['is']('element','paragraph')&&_0x40111a['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x1849e6){this['_processRootBeforeSave'](_0x1849e6);const _0xace33=this['editor']['data']['toView'](_0x1849e6,{}),_0x3646e6=Array['from'](_0xace33['getChildren']())['map'](_0x548329=>this['_getViewJson'](_0x548329));return JSON['stringify'](_0x3646e6);}['_getViewJson'](_0x2cdb09){if(_0x2cdb09['is']('$text'))return _0x2cdb09['data'];{const _0x46a8f7=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0x592f34=_0x2cdb09,_0x125ae3=this['editor']['data']['htmlProcessor']['domConverter'],_0x271361={'type':_0x46a8f7['_getTypeCharForViewElement'](_0x592f34),'name':_0x592f34['name'],'attributes':Array['from'](_0x592f34['getAttributes']()),'children':Array['from'](_0x592f34['getChildren']())['map'](_0x24000a=>this['_getViewJson'](_0x24000a))};if(_0x2cdb09['is']('uiElement')&&'$comment'!=_0x2cdb09['name']){const _0x5ca559=_0x2cdb09['render'](_0x125ae3['domDocument'],_0x125ae3);_0x271361['children']['push'](_0x5ca559['outerHTML']);}else{if(_0x2cdb09['is']('rawElement')){const _0x513dca=_0x125ae3['domDocument']['createElement'](_0x592f34['name']);_0x2cdb09['render'](_0x513dca,_0x125ae3),_0x271361['children']['push'](_0x513dca['innerHTML']);}}const _0x9fdbae=Array['from'](_0x592f34['getCustomProperties']());_0x9fdbae['length']>0x0&&(_0x271361['customProperties']=_0x9fdbae);const _0x15912f=_0x592f34['getFillerOffset']();return null!==_0x15912f&&(_0x271361['fillerOffset']=_0x15912f),_0x271361;}}['_markChanges'](_0x537db7,_0x306e37,_0x43ae65,_0x13d030,_0x1e8f24){let _0x5b484e=null,_0x2e8345=null,_0xdb065a=0x0;const _0x4b7f0d=this['editor']['model'];for(let _0x53238e=0x0;_0x53238e<_0x306e37['length'];_0x53238e++){const _0x2f7f51=this['_getVidAttributeName'](_0x306e37[_0x53238e]),_0x51d0b1=_0x306e37[_0x53238e]['item']['getAttribute'](_0x2f7f51),_0x26b855=_0x43ae65['get'](_0x51d0b1),_0x55846e=_0x53238e==_0x306e37['length']-0x1;(!_0x5b484e&&_0x26b855&&(_0x5b484e=_0x26b855,_0x2e8345=_0x306e37[_0x53238e]),_0x5b484e&&(!_0x26b855||_0x26b855['userId']!=_0x5b484e['userId']))&&(_0x3845e2(_0x26b855,F(_0x2e8345,_0x537db7,_0x4b7f0d),F(_0x306e37[_0x53238e],_0x537db7,_0x4b7f0d)),_0x5b484e=_0x26b855||null,_0x2e8345=_0x26b855?_0x306e37[_0x53238e]:null),_0x5b484e&&_0x55846e&&_0x3845e2(_0x26b855,F(_0x2e8345,_0x537db7,_0x4b7f0d),B(_0x306e37[_0x53238e],_0x537db7,_0x4b7f0d));}function _0x3845e2(_0x1c54e1,_0xfcb66f,_0x41504e){const _0x19a027=_0x5b484e['userId'],_0x546e3a='revision:'+_0x13d030+':'+_0x19a027+':'+_0xdb065a++,_0x3d5ac2=_0x4b7f0d['createRange'](_0xfcb66f,_0x41504e);_0x537db7['markers']['set'](_0x546e3a,_0x3d5ac2),null!==_0x19a027&&_0x1e8f24['add'](_0x19a027);}}['_getVidAttributeName'](_0x15d24e){switch(_0x15d24e['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x3aeb08,_0x5a2c09){_0x3aeb08['baseVersion']=null;for(const _0x310af5 in _0x3aeb08){const _0x993bf4=_0x3aeb08[_0x310af5];if(_0x993bf4 instanceof vt){const _0x5e12ea=_0x5a2c09['get'](_0x993bf4['root']['rootName']);_0x3aeb08[_0x310af5]=this['_fixPosition'](_0x993bf4,_0x5e12ea);}if(_0x993bf4 instanceof ft){const _0x3265e7=_0x5a2c09['get'](_0x993bf4['root']['rootName']);_0x3aeb08[_0x310af5]=this['_fixRange'](_0x993bf4,_0x3265e7);}'root'===_0x310af5&&(_0x3aeb08['root']=_0x5a2c09['get'](_0x3aeb08['root']['rootName']));}}['_fixRange'](_0x39b366,_0x198eda){return this['editor']['model']['createRange'](this['_fixPosition'](_0x39b366['start'],_0x198eda),this['_fixPosition'](_0x39b366['end'],_0x198eda));}['_fixPosition'](_0x4b7926,_0x5b7e0b){return this['editor']['model']['createPositionFromPath'](_0x5b7e0b,_0x4b7926['path'],_0x4b7926['stickiness']);}['_handleInsertOperation'](_0x5b7786){const _0x4e5117=this['_idsRoots']['get'](_0x5b7786['position']['root']['rootName']),_0x1fcc4f=this['_fixPosition'](_0x5b7786['position'],_0x4e5117),_0x30028f=null===_0x5b7786['_authorId']?null:_0x5b7786['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x144433=_0x1fcc4f['parent'],_0x4cf472=this['_revisionId'],_0x43ccf8=[];for(const _0x5be506 of _0x5b7786['nodes'])if(_0x5be506['is']('element'))_0x43ccf8['push'](this['_makeIdsRoot'](_0x5be506));else{for(let _0x73e43c=0x0;_0x73e43c<_0x5be506['offsetSize'];_0x73e43c++)_0x43ccf8['push'](new ut('$text',{'vid':this['_revisionId']++}));}const _0x3966d0=this['_revisionId'];for(let _0x5483f5=_0x4cf472;_0x5483f5<_0x3966d0;_0x5483f5++)this['_touched']['set'](_0x5483f5,{'userId':_0x30028f});_0x144433['_insertChild'](_0x1fcc4f['offset'],_0x43ccf8);}['_handleMoveOperation'](_0x305aec){(_0x305aec=this['_cloneOperation'](_0x305aec,this['_idsRoots']))['_execute']();const _0x11bf7d=null===_0x305aec['_authorId']?null:_0x305aec['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x545fd6=_0x305aec['getMovedRangeStart'](),_0x352215=_0x545fd6['parent'],_0x514d7b=_0x545fd6['offset'];!function _0x27c189(_0xa9e0e5,_0x1cb779,_0x392216,_0xfd4881){for(let _0x642552=_0x392216;_0x642552<_0xfd4881;_0x642552++){const _0x17f0f7=_0x1cb779['getChild'](_0x642552);_0x17f0f7['is']('element','$text')?_0xa9e0e5['set'](_0x17f0f7['getAttribute']('vid'),{'userId':_0x11bf7d}):(_0xa9e0e5['set'](_0x17f0f7['getAttribute']('vid_start'),{'userId':_0x11bf7d}),_0x27c189(_0xa9e0e5,_0x17f0f7,0x0,_0x17f0f7['childCount']),_0xa9e0e5['set'](_0x17f0f7['getAttribute']('vid_end'),{'userId':_0x11bf7d}));}}(this['_touched'],_0x352215,_0x514d7b,_0x514d7b+_0x305aec['howMany']);}['_handleMergeOperation'](_0x3c4962){const _0x43179c=null===(_0x3c4962=this['_cloneOperation'](_0x3c4962,this['_idsRoots']))['_authorId']?null:_0x3c4962['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x474eb5=_0x3c4962['targetPosition']['parent'],_0x4019ac=_0x3c4962['sourcePosition']['parent'],_0x10fc07=_0x474eb5['getAttribute']('vid_end'),_0x3ee9bc=_0x4019ac['getAttribute']('vid_start');_0x474eb5['_setAttribute']('vid_end',_0x4019ac['getAttribute']('vid_end')),_0x4019ac['_setAttribute']('vid_end',_0x10fc07),this['_touched']['set'](_0x3ee9bc,{'userId':_0x43179c}),this['_touched']['set'](_0x10fc07,{'userId':_0x43179c}),_0x3c4962['_execute']();}['_handleSplitOperation'](_0x2ad623){const _0x44af91=null===(_0x2ad623=this['_cloneOperation'](_0x2ad623,this['_idsRoots']))['_authorId']?null:_0x2ad623['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x24f602=_0x2ad623['graveyardPosition'],_0xc9757d=_0x2ad623['splitPosition']['parent'];_0x2ad623['_execute']();const _0x5ac1f1=_0xc9757d['getAttribute']('vid_end'),_0x1d77be=_0x2ad623['insertionPosition']['nodeAfter'];if(_0x24f602){const _0x4e081a=_0x1d77be['getAttribute']('vid_end'),_0x35a9b4=_0xc9757d['getAttribute']('vid_end');_0xc9757d['_setAttribute']('vid_end',_0x4e081a),_0x1d77be['_setAttribute']('vid_end',_0x35a9b4),this['_touched']['set'](_0xc9757d['getAttribute']('vid_end'),{'userId':_0x44af91}),this['_touched']['set'](_0x1d77be['getAttribute']('vid_start'),{'userId':_0x44af91});}else{const _0x18be95=this['_revisionId']++,_0x58b9ee=this['_revisionId']++;_0xc9757d['_setAttribute']('vid_end',_0x18be95),_0x1d77be['_setAttribute']('vid_start',_0x58b9ee),_0x1d77be['_setAttribute']('vid_end',_0x5ac1f1),this['_touched']['set'](_0x18be95,{'userId':_0x44af91}),this['_touched']['set'](_0x58b9ee,{'userId':_0x44af91});}}['_handleMarkerOperation'](_0x1eb4c){if(!_0x1eb4c['affectsData'])return;const _0x48c25d=(_0x1eb4c=this['_cloneOperation'](_0x1eb4c,this['_diffRoots']))['oldRange']?_0x1eb4c['oldRange']['root']:null,_0x2583f9=_0x1eb4c['newRange']?_0x1eb4c['newRange']['root']:null;_0x48c25d&&this['_markers']['delete'](_0x1eb4c['name']),_0x2583f9&&this['_markers']['set'](_0x1eb4c['name'],_0x1eb4c['newRange']['clone']());const _0x4cf840=null===_0x1eb4c['_authorId']?null:_0x1eb4c['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x24e307=_0x1eb4c['name'];if(!this['_touchedMarkers']['has'](_0x24e307))return void this['_touchedMarkers']['set'](_0x24e307,{'range':_0x1eb4c['oldRange'],'userId':_0x4cf840});const _0xdcae21=this['_touchedMarkers']['get'](_0x24e307),_0x27f5a8=_0xdcae21['range'],_0x255b28=_0x1eb4c['newRange'];null==_0x27f5a8&&null==_0x255b28||_0x27f5a8&&_0x255b28&&_0x27f5a8['isEqual'](_0x255b28)?this['_touchedMarkers']['delete'](_0x1eb4c['name']):_0xdcae21['userId']=_0x4cf840;}['_handleRootOperation'](_0x14f310,_0x1ba79c){this['_diffRoots']['has'](_0x14f310['rootName'])?this['_diffRoots']['get'](_0x14f310['rootName'])['_isAttached']=_0x14f310['isAdd']:(this['_diffRoots']['set'](_0x14f310['rootName'],P(_0x14f310['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x14f310['rootName'],{}),_0x1ba79c&&this['_idsRoots']['set'](_0x14f310['rootName'],P(_0x14f310['rootName'],!0x0)));const _0xf03f51=null===_0x14f310['_authorId']?null:_0x14f310['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0xc0dd86=this['_touchedRoots']['get'](_0x14f310['rootName']);_0xc0dd86&&_0xc0dd86['userId']===_0xf03f51?this['_touchedRoots']['delete'](_0x14f310['rootName']):this['_touchedRoots']['set'](_0x14f310['rootName'],{'userId':_0xf03f51,'isAttached':_0x14f310['isAdd']});}['_handleRootAttributeOperation'](_0x4f1f8a){const _0x16e909=this['_diffRootsAttributes']['get'](_0x4f1f8a['root']['rootName']);null===_0x4f1f8a['newValue']?delete _0x16e909[_0x4f1f8a['key']]:_0x16e909[_0x4f1f8a['key']]=_0x4f1f8a['newValue'];}}function N(_0x546289){const _0x3ef93a=P(_0x546289['rootName'],_0x546289['isAttached']());for(const _0x3484d7 of _0x546289['getChildren']()){const _0x57e1a7=_0x3484d7['_clone'](!0x0);_0x3ef93a['_appendChild'](_0x57e1a7);}return _0x3ef93a;}function P(_0x16d218,_0x2d6261=!0x0){const _0x4431fb=new gt();return _0x4431fb['rootName']=_0x16d218,_0x4431fb['_isAttached']=_0x2d6261,_0x4431fb['isAttached']=()=>_0x4431fb['_isAttached'],_0x4431fb;}function F(_0x380560,_0x51042f,_0xee4894){const _0x565209='elementEnd'==_0x380560['type']?_0xee4894['createPositionAt'](_0x380560['item'],'end'):_0xee4894['createPositionBefore'](_0x380560['item']);return _0xee4894['createPositionFromPath'](_0x51042f,_0x565209['path'],_0x565209['stickiness']);}function B(_0x317ff7,_0x4f7242,_0x26b937){const _0xd1d326='elementStart'==_0x317ff7['type']?_0x26b937['createPositionAt'](_0x317ff7['item'],0x0):_0x26b937['createPositionAfter'](_0x317ff7['item']);return _0x26b937['createPositionFromPath'](_0x4f7242,_0xd1d326['path'],_0xd1d326['stickiness']);}class os extends _0x225fc7{['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x2ac7a9,_0x103710){super(_0x2ac7a9),this['focusTracker']=new _0x1b3856(),this['keystrokes']=new _0xeb5fa6(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x103710),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'](),_0x5a7c23({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x4cebc1=_0x3b1622=>_0x3b1622['stopPropagation']();this['keystrokes']['set']('arrowright',_0x4cebc1),this['keystrokes']['set']('arrowleft',_0x4cebc1),this['keystrokes']['set']('arrowup',_0x4cebc1),this['keystrokes']['set']('arrowdown',_0x4cebc1);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x165881){this['revisionNameInputView']['fieldView']['element']['value']=_0x165881['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x5afebf){const _0xe18d75=new nt(this['locale'],ti),_0xbce031=_0xe18d75['fieldView'];_0xbce031['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x2d4cf3=g(this['locale'],'Name\x20of\x20the\x20revision');return!_0x5afebf&&(_0x2d4cf3+='\x20('+g(this['locale'],'optional')+')'),(_0xe18d75['label']=_0x2d4cf3,_0xbce031['on']('input',()=>{this['revisionNameInputValue']=_0xbce031['element']['value']['trim']();}),_0xe18d75);}}class f extends _0x47ebf6{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u];}['_saveRevisionFormView'];['init'](){const _0x4ba154=this['editor'],_0x4494ed=_0x4ba154['plugins']['get']('RevisionTracker');_0x4ba154['ui']['componentFactory']['add']('revisionHistory',_0xfb0f73=>{const _0x123871=_0xc59451(_0xfb0f73),_0x59fbb8=_0x123871['panelView']['children'],_0x441ffa=new _0x20bfa9(_0xfb0f73),_0x24a56a=new te(_0xfb0f73),_0x420f1d=new _0x5bb06b(_0xfb0f73),_0x44495a=new te(_0xfb0f73),_0x10f30=new _0x5bb06b(_0xfb0f73);return _0x123871['bind']('isEnabled')['to'](_0x4494ed,'isReady',_0x4494ed,'isEnabled',_0x4ba154,'isReadOnly',(_0x4d0ae7,_0x413838,_0x22055c)=>_0x4d0ae7&&_0x413838&&!_0x22055c),_0x123871['buttonView']['set']({'icon':_0x3c6f9c,'label':g(_0xfb0f73,'Revision\x20history'),'tooltip':!0x0}),_0x420f1d['set']({'label':g(_0xfb0f73,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x420f1d['bind']('isEnabled')['to'](_0x4494ed,'isReady',_0x4494ed,'isEnabled',_0x4ba154,'isReadOnly',(_0x2f8b51,_0x593987,_0x41f49e)=>_0x2f8b51&&_0x593987&&!_0x41f49e),_0x420f1d['on']('execute',()=>this['_showDialog']()),_0x10f30['set']({'label':g(_0xfb0f73,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x10f30['bind']('isEnabled')['to'](_0x4494ed,'isReady',_0x4ba154,'isReadOnly',(_0x22f41f,_0x2c157d)=>_0x22f41f&&!_0x2c157d),_0x10f30['on']('execute',()=>{_0x4ba154['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x123871['isOpen']=!0x1,_0x4ba154['editing']['view']['focus']();}),_0x24a56a['children']['add'](_0x420f1d),_0x44495a['children']['add'](_0x10f30),_0x441ffa['role']='menu',_0x441ffa['items']['addMany']([_0x24a56a,_0x44495a]),_0x59fbb8['add'](_0x441ffa),_0x123871;}),_0x4ba154['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x1f1c5f=this['editor'],_0x35b386=_0x1f1c5f['locale'],_0x368e58=new _0x4e87b1(_0x35b386),_0x44a91f=new _0xcb41ea(_0x35b386);_0x368e58['buttonView']['set']({'icon':_0x3c6f9c,'label':g(_0x35b386,'Revision\x20history')});const _0x450190=new _0x43d7d9(_0x35b386,_0x368e58),_0x5c4c5c=new _0x53a40c(_0x35b386);_0x5c4c5c['set']({'label':g(_0x35b386,'Save\x20current\x20revision')}),_0x5c4c5c['delegate']('execute')['to'](_0x368e58),_0x5c4c5c['on']('execute',()=>{this['_showDialog']();}),_0x450190['children']['add'](_0x5c4c5c),_0x44a91f['items']['add'](_0x450190);const _0x135393=new _0x43d7d9(_0x35b386,_0x368e58),_0x15fd9e=new _0x53a40c(_0x35b386);return _0x15fd9e['set']({'label':g(_0x35b386,'Open\x20revision\x20history')}),_0x15fd9e['delegate']('execute')['to'](_0x368e58),_0x15fd9e['on']('execute',()=>{_0x1f1c5f['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x135393['children']['add'](_0x15fd9e),_0x44a91f['items']['add'](_0x135393),_0x368e58['panelView']['children']['add'](_0x44a91f),_0x368e58;}['_showDialog'](){const _0x351923=this['editor'],_0x35fce8=_0x351923['locale'],_0x252de3=_0x351923['plugins']['get']('Dialog'),_0x12a411=_0x351923['plugins']['get']('RevisionTracker');function _0x302a27(_0x614fe5){_0x351923['config']['get']('revisionHistory.requireRevisionName')&&''===_0x614fe5['revisionName']?_0x614fe5['revisionNameInputView']['errorText']=g(_0x35fce8,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x351923['plugins']['get'](u)['saveRevision']({'name':_0x614fe5['revisionName']}),_0x252de3['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x302a27(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x252de3['show']({'id':'revisionSave','title':g(_0x35fce8,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':g(_0x351923['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x252de3['hide']()},{'label':g(_0x351923['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x10516a){_0x10516a['bind']('isEnabled')['to'](_0x12a411,'isReady',_0x12a411,'isEnabled',_0x351923,'isReadOnly',(_0x1bb856,_0x5f25a6,_0xf8deb0)=>_0x1bb856&&_0x5f25a6&&!_0xf8deb0);},'onExecute':()=>_0x302a27(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x44b568=this['editor'],_0x36e510=_0x44b568['locale'];this['_saveRevisionFormView']=new os(_0x36e510,_0x44b568['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class Q extends _0x225fc7{['changeId'];['_model'];constructor(_0x32a11d,_0x55e34d){super(_0x32a11d),this['_model']=_0x55e34d,this['changeId']=_0x55e34d['id'];const _0x12ee0d=this['bindTemplate'],_0x4b20b7=g(_0x32a11d,_0x55e34d['data']['isSuggestion']?'Suggested\x20by':'add'==_0x55e34d['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x55e34d['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x12ee0d['to']('type',_0x57ce7a=>'ck-revision-change__'+_0x57ce7a)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x4b20b7}]},{'text':'\x20'+_0x55e34d['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class r extends/* #__PURE__ -- @preserve */
25
- _0x1af5d3(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x2a32d5){super(),this['id']=_0x2a32d5['id']||_0x4339db(),this['author']=_0x2a32d5['author'],this['type']=_0x2a32d5['type'],this['data']=_0x2a32d5['data']||{},this['rootName']=_0x2a32d5['rootName'],this['set']('createdAt',_0x2a32d5['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(_0x232888,_0x1fb49d){this['newRevisionId']=_0x232888,this['oldRevisionId']=_0x1fb49d,this['changes']=new _0xe2334c();}['_setChanges'](_0x10f3f2){for(const _0x5281a1 of _0x10f3f2)this['changes']['add'](_0x5281a1);}}class m extends _0x47ebf6{['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[_0x181a91,_0x1020ef,I,V];}constructor(_0x1d3b11){super(_0x1d3b11),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',(_0x22fb9a,_0x3f9c3c,_0x51cc7d)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x3b4399=>{for(const _0x20b000 of this['editor']['editing']['view']['document']['roots'])_0x51cc7d?_0x3b4399['removeClass']('ck-editor__editable__overlay',_0x20b000):_0x3b4399['addClass']('ck-editor__editable__overlay',_0x20b000);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x26e0ca=>null!==_0x26e0ca),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x455618,_0x4d2de5,_0x19647e)=>_0x455618&&_0x19647e?_0x4d2de5['changes']['getIndex'](_0x19647e):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x33df26,_0x46a83b)=>_0x33df26?_0x46a83b['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0x1020ef);}['init'](){const _0x42d3a0=this['editor'],_0x1d1284=new pt(_0x42d3a0,{'direction':'backward'}),_0x661639=new pt(_0x42d3a0,{'direction':'forward'});(_0x42d3a0['commands']['add']('showPreviousChange',_0x1d1284),_0x42d3a0['commands']['add']('showNextChange',_0x661639),_0x42d3a0['commands']['add']('restoreRevision',new wt(_0x42d3a0)),this['on']('change:numberOfChanges',()=>{_0x1d1284['refresh'](),_0x661639['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x42d3a0['enableReadOnlyMode']('revision-viewer'),_0x42d3a0['plugins']['has']('WidgetToolbarRepository'))&&_0x42d3a0['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x85a223){return await this['_utils']['loadRevisionData'](_0x85a223,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x85a223);}async['getRevisionRootsAttributes'](_0x587dbd){return await this['_utils']['loadRevisionData'](_0x587dbd,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x587dbd);}async['compare'](_0x19869b,_0x38de95,_0x278c10=!0x1){if(!this['isEnabled'])return;const _0x1a3872=this['diff'],_0x6d66ae=this['repository'],_0x17b388='string'==typeof _0x19869b?_0x6d66ae['getRevision'](_0x19869b):_0x19869b,_0x2a7399='string'==typeof _0x38de95?_0x6d66ae['getRevision'](_0x38de95):_0x38de95,_0xbdf69f=_0x17b388['id'],_0x2baf32=_0x2a7399?_0x2a7399['id']:null;if(!_0x278c10&&this['diff']&&this['diff']['newRevisionId']===_0xbdf69f&&this['diff']['oldRevisionId']===_0x2baf32)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new c(_0xbdf69f,_0x2baf32);const _0x2d9519=this['_getRevisionsRange'](_0x17b388,_0x2a7399,!0x0)['map'](_0x5551dd=>this['_utils']['loadRevisionData'](_0x5551dd,this['adapter']));return _0x2d9519['push'](new Promise(_0x1dcd5d=>{setTimeout(_0x1dcd5d,0x14);})),Promise['all'](_0x2d9519)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x1f6c78=this['_getDiff'](_0xbdf69f,_0x2baf32);for(const _0xc0c226 of _0x1f6c78['changes'])this['_changeIdToChange']['set'](_0xc0c226['id'],_0xc0c226);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x2e9b18=>{for(const _0x141e36 of this['editor']['model']['document']['getRootNames']())_0x2e9b18['detachRoot'](_0x141e36);for(const _0x21c2c1 of Object['keys'](_0x1f6c78['model'])){const _0x598a57=_0x2e9b18['addRoot'](_0x21c2c1);for(const _0x447b40 of Object['keys'](_0x1f6c78['attributes'][_0x21c2c1]))_0x2e9b18['setAttribute'](_0x447b40,_0x1f6c78['attributes'][_0x21c2c1][_0x447b40],_0x598a57);_0x2e9b18['insert'](_0x1f6c78['model'][_0x21c2c1],_0x598a57,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x1f6c78['changes'])),this['isReady']=!0x0;})['catch'](_0x4f79fe=>{console['error'](_0x4f79fe),this['_cleanUp'](),_0x1a3872&&(this['diff']=_0x1a3872),this['isReady']=!0x0;});}['addRevisionData'](_0x4c6f78,_0x720a17){const _0x4b32f1=this['repository']['createRevision'](_0x4c6f78);return _0x4b32f1['on']('_update',(_0x33d713,_0x22f64,_0x1330d6)=>_0x720a17(_0x22f64,_0x1330d6,_0x4b32f1)),this['repository']['addRevision'](_0x4b32f1),_0x4b32f1;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x5ede26=>{for(const _0x22c571 of this['editor']['model']['document']['getRootNames']())_0x5ede26['detachRoot'](_0x22c571);});}['_sortAndFilterDiffChanges'](_0x12f17f){const _0x85e0d3=[],_0x346019=new Map();for(const _0x678215 of this['editor']['model']['document']['getRootNames']()){const _0x25becc=this['editor']['editing']['view']['getDomRoot'](_0x678215);if(!_0x25becc)continue;const _0x2cf96f=_0x25becc['getClientRects']()['item'](0x0);_0x2cf96f&&(_0x85e0d3['push'](_0x678215),_0x346019['set'](_0x678215,_0x2cf96f));}return _0x85e0d3['sort']((_0x40f24f,_0x17e90c)=>{const _0x783a0c=_0x346019['get'](_0x40f24f),_0x3859ba=_0x346019['get'](_0x17e90c);return _0x783a0c['y']-_0x3859ba['y']||_0x783a0c['x']-_0x3859ba['x'];}),(_0x12f17f=_0x12f17f['filter'](_0x2c1ccc=>_0x85e0d3['includes'](_0x2c1ccc['rootName'])))['sort']((_0x573417,_0x356bfd)=>_0x85e0d3['indexOf'](_0x573417['rootName'])-_0x85e0d3['indexOf'](_0x356bfd['rootName'])),_0x12f17f;}['_makeTape'](_0x3856fa){const _0x1d312c=Array['from'](_0x3856fa['markers'])['filter'](([_0x14814e,_0x217d0f])=>_0x14814e['startsWith']('revision:')&&!_0x217d0f['isCollapsed']),_0x1c3cc7=Array['from'](this['editor']['model']['createRangeIn'](_0x3856fa)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x1d312c['length'])for(const _0x691ae9 of _0x1c3cc7){const [_0x5e1236,_0x22a28d]=_0x1d312c[0x0],[,_0x3d548d,_0x46b035]=_0x5e1236['split'](':');if(_0x22a28d['end']['isEqual'](_0x691ae9['nextPosition'])&&_0x1d312c['shift'](),(_0x691ae9['previousPosition']['isEqual'](_0x22a28d['start'])||_0x691ae9['previousPosition']['isAfter'](_0x22a28d['start']))&&('insertion'==_0x3d548d?_0x691ae9['isAdded']={'userId':_0x46b035}:'deletion'==_0x3d548d&&(_0x691ae9['isRemoved']={'userId':_0x46b035})),0x0==_0x1d312c['length'])break;}return _0x1c3cc7;}['_refreshStartEndIndex'](_0x3b53ec){const _0x294d29=new Map();for(let _0x5e88bb=0x0;_0x5e88bb<_0x3b53ec['length'];_0x5e88bb++)'text'===_0x3b53ec[_0x5e88bb]['type']?(_0x3b53ec[_0x5e88bb]['item']['startIndex']=_0x5e88bb,_0x3b53ec[_0x5e88bb]['item']['endIndex']=_0x5e88bb):('elementStart'===_0x3b53ec[_0x5e88bb]['type']?_0x3b53ec[_0x5e88bb]['item']['startIndex']=_0x5e88bb:'elementEnd'===_0x3b53ec[_0x5e88bb]['type']&&(_0x3b53ec[_0x5e88bb]['item']['endIndex']=_0x5e88bb),_0x294d29['set'](_0x3b53ec[_0x5e88bb]['id'],_0x5e88bb));for(const _0x519fcb of _0x294d29['values']())'elementStart'===_0x3b53ec[_0x519fcb]['type']?_0x3b53ec[_0x519fcb]['item']['endIndex']=_0x294d29['get'](_0x3b53ec[_0x519fcb]['pairId']):'elementEnd'===_0x3b53ec[_0x519fcb]['type']&&(_0x3b53ec[_0x519fcb]['item']['startIndex']=_0x294d29['get'](_0x3b53ec[_0x519fcb]['pairId']));}['_processTape'](_0x39e3ed){for(let _0x101bc4=0x0;_0x101bc4<_0x39e3ed['length'];_0x101bc4++){if('elementStart'===_0x39e3ed[_0x101bc4]['type'])_0x39e3ed[_0x101bc4]['item']['startIndex']=_0x101bc4;else{if('elementEnd'===_0x39e3ed[_0x101bc4]['type']){_0x39e3ed[_0x101bc4]['item']['endIndex']=_0x101bc4;const _0x5a6555=_0x39e3ed[_0x101bc4]['item']['startIndex'];_0x39e3ed[_0x5a6555]['pairId']=_0x39e3ed[_0x101bc4]['id'],_0x39e3ed[_0x101bc4]['pairId']=_0x39e3ed[_0x5a6555]['id'];}else _0x39e3ed[_0x101bc4]['item']['startIndex']=_0x101bc4,_0x39e3ed[_0x101bc4]['item']['endIndex']=_0x101bc4,_0x39e3ed[_0x101bc4]['pairId']=null;}_0x39e3ed[_0x101bc4]['markersStart']||(_0x39e3ed[_0x101bc4]['markersStart']=[],_0x39e3ed[_0x101bc4]['markersEnd']=[]);}}['_markInsertions'](_0x5d0167,_0x465985){const _0x8e6dee=_0x5d0167['filter'](_0x352a58=>!_0x352a58['isAdded']);for(let _0xd93f34=0x0;_0xd93f34<_0x465985['length'];_0xd93f34++)_0x465985[_0xd93f34]['isAdded']&&(_0x8e6dee[_0xd93f34]['isAdded']=_0x465985[_0xd93f34]['isAdded']);}['_getDiff'](_0x35c8de,_0x562bdd=null){const _0x38f53a=this['repository']['getRevision'](_0x35c8de),_0x459e61=_0x562bdd?this['repository']['getRevision'](_0x562bdd):null,_0xe12f9a=this['_getRevisionsRange'](_0x38f53a,_0x459e61),_0x35c53e=_0xe12f9a[_0xe12f9a['length']-0x1],_0x29161c=new Map(),_0x3dd71c={'model':{},'attributes':{},'changes':[]},_0x5ef10a=new Set(),_0xd540db=new Map();for(let _0x3be951=_0xe12f9a['length']-0x1;_0x3be951>=0x0;_0x3be951--){const _0x1f9957=_0xe12f9a[_0x3be951];for(const _0x4a22c8 of Object['keys'](_0x1f9957['diffData']))if(_0x1f9957['diffData'][_0x4a22c8]['attachChange']){const _0x14f5c6=_0x1f9957['diffData'][_0x4a22c8]['attachChange'];_0x14f5c6['isAttached']?(_0x5ef10a['add'](_0x4a22c8),_0xd540db['has'](_0x4a22c8)&&_0xd540db['get'](_0x4a22c8)['userId']==_0x14f5c6['userId']?_0xd540db['delete'](_0x4a22c8):_0xd540db['set'](_0x4a22c8,_0x14f5c6)):_0xd540db['has'](_0x4a22c8)?(_0x5ef10a['delete'](_0x4a22c8),_0xd540db['delete'](_0x4a22c8)):(_0x5ef10a['add'](_0x4a22c8),_0xd540db['set'](_0x4a22c8,_0x14f5c6));}else _0x5ef10a['add'](_0x4a22c8);}for(const _0x4e8aa6 of _0x5ef10a){const _0x895405=_0xd540db['has'](_0x4e8aa6)&&!_0xd540db['get'](_0x4e8aa6)['isAttached'];let _0x593be0=_0x895405?_0xe12f9a['length']-0x1:0x0;const _0x2aa888=_0x895405?-0x1:0x1;for(;_0xe12f9a[_0x593be0];){const _0xf6699a=_0xe12f9a[_0x593be0];if(_0xf6699a['diffData'][_0x4e8aa6]){const _0x2836d7=_0x895405?_0xf6699a['diffData'][_0x4e8aa6]['attributesBefore']:_0xf6699a['diffData'][_0x4e8aa6]['attributesAfter'];_0x3dd71c['attributes'][_0x4e8aa6]=_0x2836d7?_0x5dbaa0(_0x2836d7):{};break;}_0x593be0+=_0x2aa888;}}for(const _0x1df5d2 of _0xe12f9a){_0x1df5d2['model']={};for(const _0x11db78 of _0x1df5d2['authors'])_0x29161c['set'](_0x11db78['id'],_0x11db78);for(const _0x33b3ca of _0x5ef10a){const _0x58e32c=_0x1df5d2['diffData'][_0x33b3ca]?_0x1df5d2['diffData'][_0x33b3ca]['insertions']:'[]',_0x2cd4f0=_0x1df5d2['diffData'][_0x33b3ca]?_0x1df5d2['diffData'][_0x33b3ca]['deletions']:'[]';_0x1df5d2['model'][_0x33b3ca]={'insertions':this['_utils']['_makeModelFromViewString'](_0x58e32c),'deletions':this['_utils']['_makeModelFromViewString'](_0x2cd4f0)};}}for(const _0x2507ee of _0x5ef10a){let _0x654f06=null,_0xf43e00=0x0;const _0x443c44=new Map(Array['from'](_0x38f53a['model'][_0x2507ee]['insertions']['markers'])['filter'](([_0x579906])=>!_0x579906['startsWith']('revision:')));let _0x4bde09=0x0;for(const _0x3b50a7 of _0xe12f9a){const _0xdffa37=this['_makeTape'](_0x3b50a7['model'][_0x2507ee]['insertions']);_0x3b50a7==_0x38f53a?(_0x654f06=_0xdffa37,_0xf43e00=_0x654f06['length'],_0x654f06['forEach'](_0x21662c=>{_0x21662c['id']=_0x4bde09++;}),this['_processTape'](_0x654f06)):this['_markInsertions'](_0x654f06,_0xdffa37);const _0x38b14a=_0x654f06['filter'](_0x472c70=>!_0x472c70['isAdded'])['map'](_0x56143d=>_0x56143d['id']);let _0x30e669=0x0;const _0x4e2fd7=this['_makeTape'](_0x3b50a7['model'][_0x2507ee]['deletions']);_0x4e2fd7['forEach'](_0x326c1a=>{_0x326c1a['isRemoved']?_0x326c1a['id']=_0xf43e00++:_0x326c1a['id']=_0x38b14a[_0x30e669++];}),this['_processTape'](_0x4e2fd7),this['_setDistance'](_0x654f06,'isAdded'),this['_setDistance'](_0x4e2fd7,'isRemoved'),_0x3b50a7==_0x38f53a&&this['_markMarkers'](_0x654f06,_0x443c44),_0x654f06=this['_joinTapes'](_0x654f06,_0x4e2fd7),this['_refreshStartEndIndex'](_0x654f06),this['_setDistance'](_0x654f06,'isRemoved');}_0x654f06=_0x654f06['filter'](_0x1e5d6b=>!(_0x1e5d6b['isAdded']&&_0x1e5d6b['isRemoved']));const _0x2a2f13=new Map(_0x35c53e['model'][_0x2507ee]['deletions']['markers']),_0x679321=new Set(_0x443c44['keys']());for(const _0x499916 of _0x2a2f13['keys']())_0x679321['delete'](_0x499916);this['_markSuggestions'](_0x654f06,_0x679321),this['_fixObsoleteTags'](_0x654f06),_0x654f06=this['_removeMissingPairs'](_0x654f06),_0x654f06=this['_markMismatchedRemovedTags'](_0x654f06),_0x654f06=this['_removeUnsupportedChanges'](_0x654f06);const {root:_0x2b97cf,changes:_0x1ae508}=this['_makeModelFromTape'](_0x654f06,_0x29161c,_0x2507ee);_0x3dd71c['model'][_0x2507ee]=_0x2b97cf;const _0x46ba85=_0xd540db['get'](_0x2507ee);if(_0x46ba85){const _0x14da0e=_0x29161c['get'](_0x46ba85['userId']),_0x46e5ab=new r({'author':_0x14da0e,'type':_0x46ba85['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x2507ee});_0x1ae508['unshift'](_0x46e5ab),_0x3dd71c['attributes'][_0x2507ee]['revisionHistoryAttachChange']=_0x46e5ab['id'];}_0x3dd71c['changes']=_0x3dd71c['changes']['concat'](_0x1ae508);}return _0x3dd71c;}['_markMarkers'](_0xf202b8,_0x1f48a7){for(let _0x24df8e=0x0;_0x24df8e<_0xf202b8['length'];_0x24df8e++)for(const [_0x13d0a7,_0x32e264]of _0x1f48a7)!_0x32e264['isCollapsed']&&_0x32e264['start']['isEqual'](_0xf202b8[_0x24df8e]['previousPosition'])&&_0xf202b8[_0x24df8e]['markersStart']['push'](_0x13d0a7),_0x32e264['end']['isEqual'](_0xf202b8[_0x24df8e]['nextPosition'])&&_0xf202b8[_0x24df8e]['markersEnd']['push'](_0x13d0a7);}['_joinTapes'](_0x39e77a,_0x4e2791){let _0xafc46e=[],_0x52024b=0x0,_0x5c03e6=0x0;for(;_0x52024b<_0x39e77a['length']||_0x5c03e6<_0x4e2791['length'];){const _0x4563a9=_0x39e77a[_0x52024b]||{},_0x296de6=_0x4e2791[_0x5c03e6]||{};if(_0x4563a9['id']==_0x296de6['id'])_0x52024b++,_0x5c03e6++,_0xafc46e['push'](_0x4563a9);else{if(_0x296de6['isRemoved']&&_0x4563a9['isAdded']){const {commonTape:_0x33d8e4,iEnd:_0x281fb2,jEnd:_0x1af130}=this['_threeWayMerge'](_0x39e77a,_0x52024b,_0x4e2791,_0x5c03e6);_0xafc46e=_0xafc46e['concat'](_0x33d8e4),_0x52024b=_0x281fb2,_0x5c03e6=_0x1af130;}else _0x296de6['isRemoved']?(_0x5c03e6++,_0xafc46e['push'](_0x296de6)):(_0x52024b++,_0xafc46e['push'](_0x4563a9));}}return _0xafc46e;}['_markSuggestions'](_0x265eb8,_0x1afbff){const _0x3914e5=[];for(let _0x449d91=0x0;_0x449d91<_0x265eb8['length'];_0x449d91++){for(let _0x129c0e=0x0;_0x129c0e<_0x265eb8[_0x449d91]['markersStart']['length'];_0x129c0e++){const _0x1bc88f=_0x265eb8[_0x449d91]['markersStart'][_0x129c0e];if(!_0x1afbff['has'](_0x1bc88f))continue;const {group:_0x5a8f9a,type:_0x127694,authorId:_0x1b7d21}=_0xf45ac(_0x1bc88f);'revision-suggestion'!=_0x5a8f9a||'insertion'!=_0x127694&&'deletion'!=_0x127694||(_0x3914e5['unshift']({'type':_0x127694,'name':_0x1bc88f,'userId':_0x1b7d21}),_0x265eb8[_0x449d91]['markersStart']['splice'](_0x129c0e,0x1),_0x129c0e--);}_0x196f37(_0x265eb8[_0x449d91]);for(let _0x302296=0x0;_0x302296<_0x265eb8[_0x449d91]['markersEnd']['length'];_0x302296++){const _0xde07e7=_0x265eb8[_0x449d91]['markersEnd'][_0x302296];if(!_0x1afbff['has'](_0xde07e7))continue;const {group:_0x16bf14,type:_0x22ef0e}=_0xf45ac(_0xde07e7);if('revision-suggestion'!=_0x16bf14||'insertion'!=_0x22ef0e&&'deletion'!=_0x22ef0e)continue;_0x265eb8[_0x449d91]['markersEnd']['splice'](_0x302296,0x1),_0x302296--;const _0x23a280=_0x3914e5['findIndex'](_0xa3b106=>_0xa3b106['name']==_0xde07e7);_0x23a280>-0x1&&_0x3914e5['splice'](_0x23a280,0x1);}}function _0xf45ac(_0x807a58){const _0x386ede=_0x807a58['split'](':');return{'group':_0x386ede[0x0],'type':_0x386ede[0x1],'subType':_0x386ede['length']>=0x5?_0x386ede[0x2]:null,'id':_0x386ede['length']<0x5?_0x386ede[0x2]:_0x386ede[0x3],'authorId':_0x386ede['length']<0x5?_0x386ede[0x3]:_0x386ede[0x4],'markerCount':0x6==_0x386ede['length']?_0x386ede[0x5]:null};}function _0x196f37(_0x2ea023){for(let _0x4a8c13=0x0;_0x4a8c13<_0x3914e5['length'];_0x4a8c13++){if(_0x2ea023['isAdded']&&'insertion'==_0x3914e5[_0x4a8c13]['type'])return _0x2ea023['isAddSuggestion']=_0x3914e5[_0x4a8c13],void delete _0x2ea023['isAdded'];if(!_0x2ea023['isAdded']&&!_0x2ea023['isRemoved']&&'deletion'==_0x3914e5[_0x4a8c13]['type'])return void(_0x2ea023['isRemoveSuggestion']=_0x3914e5[_0x4a8c13]);}}}['_setDistance'](_0x1e3176,_0x51c856){let _0x4d3392=0x0,_0x111e27=!0x1;const _0x481412=new Map();for(const _0xd19d3f of _0x1e3176)_0xd19d3f[_0x51c856]?_0x111e27&&(_0x4d3392++,_0x111e27=!0x1):(_0x4d3392++,_0x111e27=!0x0),_0x481412['set'](_0xd19d3f['id'],_0x4d3392);for(let _0x34131d=0x0;_0x34131d<_0x1e3176['length'];_0x34131d++){if('isRemoved'==_0x51c856&&_0x1e3176[_0x34131d]['isAdded']||'isAdded'==_0x51c856&&_0x1e3176[_0x34131d]['isRemoved'])continue;if('text'==_0x1e3176[_0x34131d]['type']){_0x1e3176[_0x34131d]['distance']=0x0;continue;}const _0x8a9da2=_0x481412['get'](_0x1e3176[_0x34131d]['pairId']),_0x3dc475=_0x481412['get'](_0x1e3176[_0x34131d]['id']);_0x1e3176[_0x34131d]['distance']=_0x8a9da2-_0x3dc475;}}['_getRevisionsRange'](_0x5c3cd8,_0xed9d20,_0x181395=!0x1){const _0x157b1a=[];let _0x158bcc=this['repository']['getIndex'](_0x5c3cd8),_0x42d957=this['repository']['getIndex'](_0xed9d20);for(-0x1==_0x42d957&&(_0x42d957=this['repository']['_revisions']['length'],_0x181395=!0x1);_0x158bcc<_0x42d957;)_0x157b1a['push'](this['repository']['getRevision'](_0x158bcc)),_0x158bcc++;return _0x181395&&_0x157b1a['push'](this['repository']['getRevision'](_0x158bcc)),_0x157b1a;}['_threeWayMerge'](_0x189fee,_0x427537,_0x2c19fb,_0x2cfa6f){const _0x1c77bf=this['editor']['model']['schema'];let _0x11effc=_0x427537;for(;_0x189fee[_0x11effc]&&_0x189fee[_0x11effc]['isAdded'];)_0x11effc++;let _0x17c39e=_0x2cfa6f;for(;_0x2c19fb[_0x17c39e]&&_0x2c19fb[_0x17c39e]['isRemoved'];)_0x17c39e++;_0x514bd5(_0x189fee,_0x427537,_0x11effc),_0x514bd5(_0x2c19fb,_0x2cfa6f,_0x17c39e);const _0x193970=_0x2c19fb['slice'](_0x2cfa6f,_0x17c39e)['concat'](_0x189fee['slice'](_0x427537,_0x11effc));return _0x193970['sort']((_0x43812d,_0x10ee95)=>_0x43812d['side']!=_0x10ee95['side']?_0x43812d['side']-_0x10ee95['side']:_0x43812d['level']!=_0x10ee95['level']?_0x43812d['level']-_0x10ee95['level']:_0x43812d['distance']!=_0x10ee95['distance']?_0x10ee95['distance']-_0x43812d['distance']:!!_0x43812d['isAdded']!=!!_0x10ee95['isAdded']?-0x1==_0x43812d['side']||0x0==_0x43812d['side']?_0x43812d['isAdded']?-0x1:0x1:_0x43812d['isAdded']?0x1:-0x1:_0x43812d['index']-_0x10ee95['index']),{'commonTape':_0x193970,'iEnd':_0x11effc,'jEnd':_0x17c39e};function _0x514bd5(_0x554917,_0x38ed6d,_0x15d532){let _0x4c0be6=-0x1,_0xb3fb64=Number['POSITIVE_INFINITY'],_0x2c5233=!0x0;for(let _0x4fffb9=_0x38ed6d;_0x4fffb9<_0x15d532;_0x4fffb9++)if(_0x1c77bf['isInline'](_0x554917[_0x4fffb9]['item'])||(_0x2c5233=!0x1),_0x554917[_0x4fffb9]['item']['startIndex']<_0x38ed6d&&(_0x4c0be6=_0x4fffb9),_0x554917[_0x4fffb9]['item']['endIndex']>=_0x15d532){_0xb3fb64=_0x4fffb9;break;}_0x2c5233&&(_0x4c0be6=_0x15d532-0x1);for(let _0x993d3f=_0x38ed6d;_0x993d3f<_0x15d532;_0x993d3f++)_0x554917[_0x993d3f]['side']=_0x993d3f<=_0x4c0be6?-0x1:_0x993d3f<_0xb3fb64?0x0:0x1,_0x554917[_0x993d3f]['index']=_0x993d3f;let _0x594352=0x0;for(let _0x2c29ea=_0x38ed6d;_0x2c29ea<=_0x4c0be6;_0x2c29ea++)0x0==_0x554917[_0x2c29ea]['distance']?_0x554917[_0x2c29ea]['level']=_0x594352:(_0x594352++,_0x554917[_0x2c29ea]['level']=_0x594352,_0x594352++);for(let _0x327081=_0x38ed6d;_0x327081<_0x15d532;_0x327081++)0x0==_0x554917[_0x327081]['side']&&(_0x554917[_0x327081]['level']=_0x594352);_0x594352=0x0;for(let _0x3bc6f1=_0x15d532-0x1;_0x3bc6f1>=_0xb3fb64;_0x3bc6f1--)0x0==_0x554917[_0x3bc6f1]['distance']?_0x554917[_0x3bc6f1]['level']=_0x594352:(_0x594352--,_0x554917[_0x3bc6f1]['level']=_0x594352,_0x594352--);}}['_fixObsoleteTags'](_0x2f948c){const _0x59b044=new Map(),_0x3a6237=this['editor']['model']['schema'];for(let _0x51c54f=0x1;_0x51c54f<_0x2f948c['length'];_0x51c54f++){let _0x13ddec,_0xef260,_0x904c64;const _0x4e19b2=_0x2f948c[_0x51c54f],_0x4bca31=_0x2f948c[_0x51c54f-0x1];if('text'==_0x4e19b2['type'])continue;if(_0x4e19b2['type']!=_0x4bca31['type'])continue;if(!_0x3a6237['isBlock'](_0x4bca31['item'])||_0x3a6237['isLimit'](_0x4bca31['item']))continue;if(!_0x3a6237['isBlock'](_0x4e19b2['item'])||_0x3a6237['isLimit'](_0x4e19b2['item']))continue;if((_0x2f948c[_0x51c54f]['isAdded']||_0x2f948c[_0x51c54f]['isAddSuggestion'])&&_0x2f948c[_0x51c54f-0x1]['isRemoved'])_0x13ddec=_0x2f948c[_0x51c54f],_0xef260=_0x2f948c[_0x51c54f-0x1],_0x904c64=_0x51c54f-0x1;else{if(!_0x2f948c[_0x51c54f]['isRemoved']||!_0x2f948c[_0x51c54f-0x1]['isAdded']&&!_0x2f948c[_0x51c54f-0x1]['isAddSuggestion'])continue;_0x13ddec=_0x2f948c[_0x51c54f-0x1],_0xef260=_0x2f948c[_0x51c54f],_0x904c64=_0x51c54f;}const _0xce99d0=_0x13ddec['level']==_0xef260['level'],_0x3f8e18=Math['abs'](_0x13ddec['level'])<Math['abs'](_0xef260['level'])&&0x0==_0xef260['distance'];(_0xce99d0||_0x3f8e18)&&(_0x59b044['set'](_0xef260['id'],_0x13ddec['id']),_0x2f948c['splice'](_0x904c64,0x1),_0x51c54f--,_0x13ddec['isAdded']=!0x1);}for(let _0xc30243=0x0;_0xc30243<_0x2f948c['length'];_0xc30243++)_0x59b044['has'](_0x2f948c[_0xc30243]['pairId'])&&(_0x2f948c[_0xc30243]['pairId']=_0x59b044['get'](_0x2f948c[_0xc30243]['pairId']));}['_removeMissingPairs'](_0x597c13){const _0x1bd1df=new Set(_0x597c13['map'](_0x4ed20a=>_0x4ed20a['id']));for(let _0xc0c09c=0x0;_0xc0c09c<_0x597c13['length'];_0xc0c09c++)_0x1bd1df['has'](_0x597c13[_0xc0c09c]['pairId'])||0x0==_0x597c13[_0xc0c09c]['distance']||(_0x597c13[_0xc0c09c]['isIncorrect']=!0x0);return _0x597c13['filter'](_0x1b535a=>!_0x1b535a['isIncorrect']);}['_markMismatchedRemovedTags'](_0x33479e){const _0xb7096e=new Set();for(let _0x547489=0x0;_0x547489<_0x33479e['length'];_0x547489++){if(_0xb7096e['has'](_0x33479e[_0x547489]['id'])&&_0x33479e[_0x547489]['isRemoved']&&(_0x33479e[_0x547489]['isIncorrect']=!0x0),_0x33479e[_0x547489]['isIncorrect'])continue;if(0x0==_0x33479e[_0x547489]['distance'])continue;if('elementStart'!=_0x33479e[_0x547489]['type'])continue;if(null==_0x33479e[_0x547489]['pairId'])continue;let _0x5bad69=_0x547489+0x1,_0x3f581c=0x0;for(;_0x33479e[_0x5bad69]['id']!=_0x33479e[_0x547489]['pairId'];)'elementStart'==_0x33479e[_0x5bad69]['type']?_0x3f581c++:'elementEnd'==_0x33479e[_0x5bad69]['type']&&_0x3f581c--,_0x5bad69++;if(0x0!=_0x3f581c){if(_0x33479e[_0x547489]['isRemoved'])_0x33479e[_0x547489]['isIncorrect']=!0x0;else{for(;_0x5bad69!=_0x547489;)_0x33479e[_0x5bad69]['isRemoved']&&0x0!=_0x33479e[_0x5bad69]['distance']&&(_0x33479e[_0x5bad69]['isIncorrect']=!0x0,_0xb7096e['add'](_0x33479e[_0x5bad69]['pairId'])),_0x5bad69--;}}}return _0x33479e['filter'](_0x329673=>!_0x329673['isIncorrect']);}['_removeUnsupportedChanges'](_0x619245){const _0x8d3cb4=this['editor']['model']['schema'];for(let _0x2cb338=0x0;_0x2cb338<_0x619245['length'];_0x2cb338++){if(!(_0x619245[_0x2cb338]['isAdded']||_0x619245[_0x2cb338]['isAddSuggestion']||_0x619245[_0x2cb338]['isRemoved']||_0x619245[_0x2cb338]['isRemoveSuggestion']))continue;if(0x0==_0x619245[_0x2cb338]['distance'])continue;const _0x1ae4df=_0x619245[_0x2cb338]['item'];_0x8d3cb4['isBlock'](_0x1ae4df)||_0x8d3cb4['isLimit'](_0x1ae4df)||(_0x619245[_0x2cb338]['isAdded']&&delete _0x619245[_0x2cb338]['isAdded'],_0x619245[_0x2cb338]['isAddSuggestion']&&delete _0x619245[_0x2cb338]['isAddSuggestion'],_0x619245[_0x2cb338]['isRemoveSuggestion']&&delete _0x619245[_0x2cb338]['isRemoveSuggestion'],_0x619245[_0x2cb338]['isRemoved']&&(_0x619245[_0x2cb338]['isIncorrect']=!0x0));}return _0x619245['filter'](_0x216d0b=>!_0x216d0b['isIncorrect']);}['_makeModelFromTape'](_0x534c92,_0x175fa1,_0x4b75f6){const _0x53a3f8=new gt(),_0x3a8da7=[],_0xcb4bc6=new Map(),_0x15028b=this['editor']['model'],_0x5b991a=_0x15028b['schema'],_0x2e4e76=[_0x53a3f8],_0x1a3436={},_0x7189c9={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x168c84=null;const _0x21acec=[0x0];for(let _0x380c6a=0x0;_0x380c6a<_0x534c92['length'];_0x380c6a++)if('elementStart'===_0x534c92[_0x380c6a]['type']){_0x534c92[_0x380c6a]['previousPosition']=_0x15028b['createPositionFromPath'](_0x53a3f8,_0x21acec);const _0xa2fa0d=new ut(_0x534c92[_0x380c6a]['item']['name'],_0x534c92[_0x380c6a]['item']['getAttributes']());_0x2e4e76[0x0]['_appendChild'](_0xa2fa0d),_0x21acec['push'](0x0),_0x2e4e76['unshift'](_0xa2fa0d),_0x534c92[_0x380c6a]['nextPosition']=_0x15028b['createPositionFromPath'](_0x53a3f8,_0x21acec);}else'elementEnd'===_0x534c92[_0x380c6a]['type']?(_0x2e4e76['shift'](),_0x534c92[_0x380c6a]['previousPosition']=_0x15028b['createPositionFromPath'](_0x53a3f8,_0x21acec),_0x21acec['pop'](),_0x21acec[_0x21acec['length']-0x1]++,_0x534c92[_0x380c6a]['nextPosition']=_0x15028b['createPositionFromPath'](_0x53a3f8,_0x21acec)):(_0x534c92[_0x380c6a]['previousPosition']=_0x15028b['createPositionFromPath'](_0x53a3f8,_0x21acec),_0x168c84?_0x168c84['_data']+=_0x534c92[_0x380c6a]['item']['data']:_0x168c84=new mt(_0x534c92[_0x380c6a]['item']['data'],_0x534c92[_0x380c6a]['item']['getAttributes']()),_0x534c92[_0x380c6a+0x1]&&'text'===_0x534c92[_0x380c6a+0x1]['type']&&_0x1eee55(_0x168c84,_0x534c92[_0x380c6a+0x1]['item'])||(_0x2e4e76[0x0]['_appendChild'](_0x168c84),_0x168c84=null),_0x21acec[_0x21acec['length']-0x1]+=_0x534c92[_0x380c6a]['item']['offsetSize'],_0x534c92[_0x380c6a]['nextPosition']=_0x15028b['createPositionFromPath'](_0x53a3f8,_0x21acec));for(let _0x38356d=0x0;_0x38356d<_0x534c92['length'];_0x38356d++){const _0x13d5f9=_0x534c92[_0x38356d]['previousPosition'],_0x3d4ac2=_0x534c92[_0x38356d]['nextPosition'];for(const _0x3f2f57 of _0x534c92[_0x38356d]['markersStart'])_0xcb4bc6['set'](_0x3f2f57,{'start':_0x13d5f9,'end':null});_0x44b4c7('isRemoveSuggestion',_0x38356d,_0x13d5f9,_0x3d4ac2),_0x44b4c7('isAddSuggestion',_0x38356d,_0x13d5f9,_0x3d4ac2),_0x44b4c7('isRemoved',_0x38356d,_0x13d5f9,_0x3d4ac2),_0x44b4c7('isAdded',_0x38356d,_0x13d5f9,_0x3d4ac2);for(const _0x2ea6ea of _0x534c92[_0x38356d]['markersEnd']){const _0x32307d=_0xcb4bc6['get'](_0x2ea6ea);_0x32307d?_0x32307d['end']=_0x3d4ac2:_0xcb4bc6['set'](_0x2ea6ea,{'start':_0x3d4ac2,'end':_0x3d4ac2});}}for(const [_0x2826a9,_0x37fa25]of _0xcb4bc6){const _0x4dd1aa=this['editor']['model']['createRange'](_0x37fa25['start'],_0x37fa25['end']);_0x53a3f8['markers']['set'](_0x2826a9,_0x4dd1aa);}return _0x3a8da7['sort']((_0x349ece,_0x29ce4e)=>{const _0x472e47=_0x53a3f8['markers']['get']('revision:'+_0x349ece['id']),_0x39e821=_0x53a3f8['markers']['get']('revision:'+_0x29ce4e['id']);return _0x472e47['start']['isBefore'](_0x39e821['start'])?-0x1:_0x472e47['start']['isAfter'](_0x39e821['start'])?0x1:_0x472e47['end']['isBefore'](_0x39e821['end'])?-0x1:_0x472e47['end']['isAfter'](_0x39e821['end'])?0x1:'add'===_0x349ece['type']?-0x1:0x1;}),{'root':_0x53a3f8,'changes':_0x3a8da7};function _0x44b4c7(_0x16043d,_0x3cb8d2,_0x2c7d05,_0x5787cb){const _0x14ef11=!!_0x534c92[_0x3cb8d2][_0x16043d],_0x10ec0c=_0x14ef11?_0x534c92[_0x3cb8d2][_0x16043d]['userId']:null,_0x8bfc68=_0x3cb8d2===_0x534c92['length']-0x1,_0x364a8d=_0x7189c9[_0x16043d][0x0],_0x359c2b=_0x5b991a['isObject'](_0x534c92[_0x3cb8d2]['item']);!_0x1a3436[_0x16043d]&&_0x14ef11?_0x1a3436[_0x16043d]={'start':_0x2c7d05,'tapeItem':_0x534c92[_0x3cb8d2],'userId':_0x10ec0c,'type':_0x16043d}:_0x1a3436[_0x16043d]&&!_0x14ef11?(_0x1a3436[_0x16043d]['end']=_0x2c7d05,_0x44d276(_0x1a3436[_0x16043d]),_0x1a3436[_0x16043d]=null):_0x1a3436[_0x16043d]&&_0x14ef11&&_0x1a3436[_0x16043d]['userId']!==_0x10ec0c&&(_0x1a3436[_0x16043d]['end']=_0x2c7d05,_0x364a8d&&_0x364a8d['userId']===_0x1a3436[_0x16043d]['userId']||_0x44d276(_0x1a3436[_0x16043d]),_0x1a3436[_0x16043d]={'start':_0x2c7d05,'tapeItem':_0x534c92[_0x3cb8d2],'userId':_0x10ec0c,'type':_0x16043d}),_0x1a3436[_0x16043d]&&_0x359c2b&&('elementStart'!==_0x534c92[_0x3cb8d2]['type']||_0x364a8d&&_0x364a8d['userId']===_0x10ec0c||_0x7189c9[_0x16043d]['unshift']({'userId':_0x10ec0c,'object':_0x534c92[_0x3cb8d2]['item'],'change':_0x1a3436[_0x16043d]}),'elementEnd'===_0x534c92[_0x3cb8d2]['type']&&_0x364a8d&&_0x364a8d['object']===_0x534c92[_0x3cb8d2]['item']&&(_0x7189c9[_0x16043d]['shift'](),_0x1a3436[_0x16043d]=_0x364a8d['change'])),_0x1a3436[_0x16043d]&&_0x8bfc68&&(_0x1a3436[_0x16043d]['end']=_0x5787cb,_0x44d276(_0x1a3436[_0x16043d]),_0x1a3436[_0x16043d]=null);}function _0x44d276({start:_0x494307,end:_0x50c3ac,tapeItem:_0x209cd7,userId:_0x1150f7,type:_0x512dce}){const _0x3bea6c=_0x209cd7['item'],_0x24f69b=_0x15028b['schema']['isBlock'](_0x3bea6c)&&!_0x15028b['schema']['isLimit'](_0x3bea6c),_0x2cce6c=_0x494307['nodeAfter']==_0x50c3ac['parent']&&_0x50c3ac['isAtStart'];if(_0x24f69b&&_0x2cce6c)return;const _0x4573c7=_0x15028b['createRange'](_0x494307,_0x50c3ac),_0xc63f3d=_0x175fa1['get'](_0x1150f7),_0x25c123=new r({'author':_0xc63f3d,'type':'isAdded'==_0x512dce||'isAddSuggestion'==_0x512dce?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x512dce||'isRemoveSuggestion'==_0x512dce},'createdAt':new Date(),'rootName':_0x4b75f6});_0x3a8da7['push'](_0x25c123),_0x53a3f8['markers']['set']('revision:'+_0x25c123['id'],_0x4573c7);}function _0x1eee55(_0x26df8e,_0x6d71ff){const _0x49212b=_0x26df8e['getAttributes'](),_0x2bba99=_0x6d71ff['getAttributes']();for(const _0x3e0c60 of _0x49212b){if(_0x3e0c60[0x1]!==_0x6d71ff['getAttribute'](_0x3e0c60[0x0]))return!0x1;_0x2bba99['next']();}return _0x2bba99['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x190ae0=>{const _0x469c3c=_0x190ae0['markerName']['split'](':')[0x1],_0x2ebe52=this['_getChangeFromId'](_0x469c3c);if(!_0x2ebe52)return null;const _0x11624d='add'==_0x2ebe52['type']?'insertion':'deletion',_0x4ad25a=['ck-suggestion-marker','ck-suggestion-marker-'+_0x11624d];return _0x2ebe52['data']['isSuggestion']&&_0x4ad25a['push']('ck-suggestion-marker-'+_0x11624d+'-new'),this['activeChange']==_0x2ebe52&&_0x4ad25a['push']('ck-suggestion-marker--active'),{'classes':_0x4ad25a,'attributes':{'data-change-id':_0x469c3c}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x4d239d=>{_0x4d239d['on']('element:pre',(_0x54fb27,_0x36f157,_0x3664c6)=>{const _0xef4324=_0x36f157['viewItem']['getChild'](0x0);if(!_0xef4324||!_0xef4324['is']('element','code'))return;if(!_0x3664c6['consumable']['consume'](_0xef4324,{'attributes':['vid_start','vid_end']}))return;const _0x434089=_0x36f157['modelRange']['start']['nodeAfter'];_0x3664c6['writer']['setAttribute']('vid_start',_0xef4324['getAttribute']('vid_start'),_0x434089),_0x3664c6['writer']['setAttribute']('vid_end',_0xef4324['getAttribute']('vid_end'),_0x434089);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0xce958f=>{_0xce958f['on']('element',(_0x2c8f96,_0x220513,_0x3c100c)=>{if(!_0x3c100c['consumable']['consume'](_0x220513['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x220513['modelRange']['isCollapsed'])return;const _0x39dc81=_0x220513['modelRange']['start']['nodeAfter'];_0x39dc81['hasAttribute']('vid_start')||_0x39dc81['hasAttribute']('vid')||(_0x3c100c['writer']['setAttribute']('vid_start',_0x220513['viewItem']['getAttribute']('vid_start'),_0x39dc81),_0x3c100c['writer']['setAttribute']('vid_end',_0x220513['viewItem']['getAttribute']('vid_end'),_0x39dc81));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x4e225f=>_0x4e225f['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x5152dc,[,_0x81a159])=>{['vid_start','vid_end','vid']['includes'](_0x81a159)&&(_0x5152dc['return']=!0x0,_0x5152dc['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x52c2f9=>{_0x52c2f9['on']('attribute:vid',(_0x3f2b90,_0x2aea03,_0x46814b)=>{if('\x20'!=_0x2aea03['item']['data']||_0x2aea03['item']['parent']['maxOffset']>0x1)return;if(!_0x46814b['consumable']['consume'](_0x2aea03['item'],_0x3f2b90['name']))return;const _0xe4a8a5=_0x46814b['writer'],_0x63d92f=_0x46814b['mapper']['toViewRange'](_0x2aea03['range']);_0xe4a8a5['wrap'](_0x63d92f,_0xe4a8a5['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x44f657){const _0x42476b=_0x44f657['plugins']['get']('RevisionViewer');return(_0x593582,_0x32ea8f,_0x12a334)=>{const _0x10c9d2=_0x32ea8f['markerName']['split'](':')[0x1],_0x29820f=_0x42476b['_getChangeFromId'](_0x10c9d2);if(!_0x29820f)return null;const _0x40183e='add'==_0x29820f['type']?'split':'merge';if(!_0x12a334['consumable']['test'](_0x32ea8f['markerRange'],_0x593582['name']))return;const _0x33c58b=_0x32ea8f['markerRange']['getWalker'](),_0x1bf3ac=_0x32ea8f['markerRange']['start'],_0x19b5ac=_0x44f657['model']['schema'];let _0x5ebbdb=null,_0x1ee2f2=null,_0x280251=!0x1,_0x4949a5=!0x1;for(const _0xddcd24 of _0x33c58b){const _0x46b4c4=_0xddcd24['item'];_0x280251=_0x280251||_0x19b5ac['isContent'](_0x46b4c4);const _0x45f830=_0x12a334['mapper']['toViewElement'](_0x46b4c4);if(_0x45f830&&_0x45f830['getCustomProperty']('addHighlight'))return;'elementEnd'==_0xddcd24['type']&&(_0x19b5ac['isBlock'](_0x46b4c4)&&!_0x19b5ac['isLimit'](_0x46b4c4)&&(_0x46b4c4['nextSibling']||_0x1bf3ac['isAtEnd']?_0x5ebbdb&&_0x5ebbdb['parent']==_0x46b4c4||(_0x5ebbdb=_0x46b4c4,_0x49e7de(_0xddcd24['previousPosition']),_0x4949a5=!0x0):_0x1ee2f2=_0x1ee2f2||_0xddcd24['previousPosition']));}function _0x49e7de(_0x35b55){const _0x5c9ecf=_0x12a334['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x40183e}),_0x3cdb38=_0x12a334['mapper']['toViewPosition'](_0x35b55);_0x29820f['data']['isSuggestion']&&_0x12a334['writer']['addClass']('ck-suggestion-marker-'+_0x40183e+'-new',_0x5c9ecf),_0x42476b['activeChange']==_0x29820f&&_0x12a334['writer']['addClass']('ck-suggestion-marker--active',_0x5c9ecf),_0x12a334['writer']['insert'](_0x3cdb38,_0x5c9ecf),_0x12a334['mapper']['bindElementToMarker'](_0x5c9ecf,_0x32ea8f['markerName']);}_0x280251||_0x4949a5||!_0x1ee2f2||_0x49e7de(_0x1ee2f2);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x21e811,_0x263af5,_0x559847)=>{const _0x2b6868=_0x559847['mapper']['markerNameToElements'](_0x263af5['markerName']);if(_0x2b6868){for(const _0x559446 of _0x2b6868)(_0x559446['hasClass']('ck-suggestion-marker-split')||_0x559446['hasClass']('ck-suggestion-marker-merge'))&&(_0x559847['mapper']['unbindElementFromMarkerName'](_0x559446,_0x263af5['markerName']),_0x559847['writer']['remove'](_0x559446));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x3198fc,_0x10e493,_0x1e9aa3)=>{const _0x5d0fbd=_0x10e493['markerName']['split'](':')[0x1],_0x21b2ff=this['_getChangeFromId'](_0x5d0fbd);if(!_0x21b2ff)return null;const _0x588bcd='add'==_0x21b2ff['type']?'split':'merge';if(_0x1e9aa3['consumable']['test'](_0x10e493['markerRange'],_0x3198fc['name']))for(const _0x350d3b of _0x10e493['markerRange']['getItems']()){if(!_0x350d3b['is']('element','softBreak'))continue;const _0x18cfe4=_0x1e9aa3['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x588bcd}),_0x1fff80=_0x1e9aa3['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x350d3b));_0x21b2ff['data']['isSuggestion']&&_0x1e9aa3['writer']['addClass']('ck-suggestion-marker-'+_0x588bcd+'-new',_0x18cfe4),this['activeChange']==_0x21b2ff&&_0x1e9aa3['writer']['addClass']('ck-suggestion-marker--active',_0x18cfe4),_0x1e9aa3['writer']['insert'](_0x1fff80,_0x18cfe4),_0x1e9aa3['mapper']['bindElementToMarker'](_0x18cfe4,_0x10e493['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x4215f5=>{for(const _0x2758d2 of this['editor']['model']['document']['getRootNames']()){const _0x2a4fcd=this['editor']['model']['document']['getRoot'](_0x2758d2),_0x477c2e=this['editor']['editing']['view']['document']['getRoot'](_0x2758d2);if(_0x477c2e){const _0x244db0=_0x2a4fcd['getAttribute']('revisionHistoryAttachChange');if(_0x4215f5['removeAttribute']('data-change-id',_0x477c2e),_0x4215f5['removeClass']('ck-revision-history-root-add',_0x477c2e),_0x4215f5['removeClass']('ck-revision-history-root-remove',_0x477c2e),_0x4215f5['removeClass']('ck-revision-history-root--active',_0x477c2e),_0x244db0){const _0x5d3ac3=this['_getChangeFromId'](_0x244db0);if(!_0x5d3ac3)return null;_0x4215f5['setAttribute']('data-change-id',_0x244db0,_0x477c2e),_0x4215f5['addClass']('ck-revision-history-root-'+_0x5d3ac3['type'],_0x477c2e),this['activeChange']==_0x5d3ac3&&_0x4215f5['addClass']('ck-revision-history-root--active',_0x477c2e);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x242d20=>'revision-comment:'+_0x242d20,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x885aa8=>'revision-suggestion:'+_0x885aa8,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x9664dd=>({'name':'suggestion:'+_0x9664dd,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x4e1535=>{const _0x50ed14=_0x4e1535['markerName']['split'](':')[0x1];return'insertion'!=_0x50ed14&&'deletion'!=_0x50ed14?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x50ed14]};}}),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',(_0x4ae243,_0x59261e,_0x4c8e5d)=>{const _0x4bcffa=_0x4c8e5d['mapper']['markerNameToElements'](_0x59261e['markerName']);if(_0x4bcffa){for(const _0x8f786 of _0x4bcffa)_0x8f786['is']('uiElement')&&(_0x4c8e5d['mapper']['unbindElementFromMarkerName'](_0x8f786,_0x59261e['markerName']),_0x4c8e5d['writer']['remove'](_0x8f786));}},{'priority':'high'});}['_getChangeFromId'](_0x276d26){return this['_changeIdToChange']['get'](_0x276d26);}['_getViewForChange'](_0x174055){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new Q(this['editor']['locale'],_0x174055),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x347637,_0x55aae6,_0x27d971,_0x262006)=>{_0x262006&&this['_balloon']['remove'](_0x262006),_0x27d971&&(this['_balloon']['add']({'view':_0x27d971,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x18849d=this['editor']['editing'],_0x5232e8=this['_getChangeFromId'](_0x27d971['changeId']);let _0xd8c0b3;if(_0x5232e8['data']['isOnRoot']){const _0x1a72d6=_0x18849d['view']['getDomRoot'](_0x5232e8['rootName']);_0xd8c0b3=Array['from'](_0x1a72d6['getClientRects']());}else{const _0x48a133=this['editor']['model']['markers']['get']('revision:'+_0x27d971['changeId']);_0xd8c0b3=Array['from'](_0x18849d['mapper']['markerNameToElements'](_0x48a133['name']))['map'](_0x33fce2=>_0x18849d['view']['domConverter']['mapViewToDom'](_0x33fce2))['map'](_0x584a2b=>Array['from'](_0x584a2b['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0xd8c0b3[0x0];return _0xd8c0b3['find'](_0x8b8eb5=>_0x8b8eb5['top']-0x3<=this['_activeViewTarget']['y']&&_0x8b8eb5['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x8b8eb5['left']-0x3<=this['_activeViewTarget']['x']&&_0x8b8eb5['right']+0x3>=this['_activeViewTarget']['x'])||_0xd8c0b3[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x16e2be,_0x802efe,_0x4dc8d2,_0x3fe739)=>{this['activeView']=_0x4dc8d2?this['_getViewForChange'](_0x4dc8d2):null,this['editor']['model']['change'](()=>{const _0xd25dc1=this['editor']['editing'];_0x3fe739&&(_0x3fe739['data']['isOnRoot']?_0xd25dc1['view']['change'](_0x4be6ae=>{_0x4be6ae['removeClass']('ck-revision-history-root--active',_0xd25dc1['view']['document']['getRoot'](_0x3fe739['rootName']));}):_0xd25dc1['reconvertMarker']('revision:'+_0x3fe739['id'])),_0x4dc8d2&&(_0x4dc8d2['data']['isOnRoot']?_0xd25dc1['view']['change'](_0x3611dd=>{_0x3611dd['addClass']('ck-revision-history-root--active',_0xd25dc1['view']['document']['getRoot'](_0x4dc8d2['rootName']));}):_0xd25dc1['reconvertMarker']('revision:'+_0x4dc8d2['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x410306,_0x109e1a)=>{if(this['activeChange'])return;const _0x29a9d0=this['_findChangeIdFromDomTarget'](_0x109e1a['target']),_0x117e8c=this['_changeIdToChange']['get'](_0x29a9d0);_0x117e8c?(this['_activeViewTarget']={'x':_0x109e1a['domEvent']['x'],'y':_0x109e1a['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x117e8c)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x4437e9,_0x46faa0)=>{const _0xff6a8c=this['_findChangeIdFromDomTarget'](_0x46faa0['target']),_0x4496c1=this['_changeIdToChange']['get'](_0xff6a8c);_0x4496c1?(this['_activeViewTarget']={'x':_0x46faa0['domEvent']['x'],'y':_0x46faa0['domEvent']['y']},_0x4496c1===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x4496c1):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x1da828){do{const _0x266e7e=_0x1da828['getAttribute']('data-change-id');if(_0x266e7e)return _0x266e7e;_0x1da828=_0x1da828['parent'];}while(_0x1da828);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0xdc5f39=>{for(const _0x490479 of this['editor']['model']['markers'])_0xdc5f39['removeMarker'](_0x490479);});}}function X(_0x16a850,_0x3762ba){return(_0x327b86,_0x332472,_0x35c1b8)=>{if(!_0x35c1b8['consumable']['test'](_0x332472['markerRange'],_0x327b86['name']))return;const _0x585ee2=_0x332472['markerRange']['getWalker'](),_0x429aea=_0x332472['markerRange']['start'],_0x21c6c6=_0x16a850['model']['schema'];let _0x50cde4=null,_0x13f5e1=null,_0x593d47=!0x1,_0xe79058=!0x1;for(const _0x3d6ad5 of _0x585ee2){const _0x5c29b3=_0x3d6ad5['item'];_0x593d47=_0x593d47||_0x21c6c6['isContent'](_0x5c29b3);const _0x4902e6=_0x35c1b8['mapper']['toViewElement'](_0x5c29b3);if(_0x4902e6&&_0x4902e6['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x3d6ad5['type']&&(_0x21c6c6['isBlock'](_0x5c29b3)&&!_0x21c6c6['isLimit'](_0x5c29b3)&&(_0x5c29b3['nextSibling']||_0x429aea['isAtEnd']?_0x50cde4&&_0x50cde4['parent']==_0x5c29b3||(_0x50cde4=_0x5c29b3,_0x5b1217(_0x3d6ad5['previousPosition']),_0xe79058=!0x0):_0x13f5e1=_0x13f5e1||_0x3d6ad5['previousPosition']));}function _0x5b1217(_0x58b1e4){const _0x2f8b05=_0x35c1b8['mapper']['toViewPosition'](_0x58b1e4),_0x156629=_0x35c1b8['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x3762ba});_0x35c1b8['writer']['insert'](_0x2f8b05,_0x156629),_0x35c1b8['mapper']['bindElementToMarker'](_0x156629,_0x332472['markerName']);}_0x593d47||_0xe79058||!_0x13f5e1||_0x5b1217(_0x13f5e1);};}class wt extends _0x5eb553{constructor(_0x3d1cb2){super(_0x3d1cb2);const _0x2fe4fe=_0x3d1cb2['plugins']['get'](m);this['affectsData']=!0x1,this['listenTo'](_0x2fe4fe,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x2fe4fe,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x5c8446=this['editor'],_0x4dddf0=_0x5c8446['plugins']['get'](m),_0x39470e=_0x4dddf0['isReady']?_0x4dddf0['diff']['newRevisionId']:null;_0x5c8446['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x39470e);}['refresh'](){const {isReady:_0x5275dc,isEnabled:_0x207edf,repository:_0x2fa19f,diff:_0x357b53}=this['editor']['plugins']['get'](m),_0x3dff3b=_0x357b53&&_0x2fa19f['getLaterVisibleRevision'](_0x357b53['newRevisionId']);this['isEnabled']=_0x5275dc&&_0x207edf&&Boolean(_0x3dff3b);}}class pt extends _0x5eb553{['_step'];constructor(_0x309fc6,{direction:_0x3cb99c}){super(_0x309fc6);const _0x2729af=_0x309fc6['plugins']['get'](m);this['affectsData']=!0x1,this['_step']='forward'===_0x3cb99c?0x1:-0x1,this['listenTo'](_0x2729af,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x2729af,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x2729af,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x5e1001=this['editor'],_0x29983c=_0x5e1001['plugins']['get'](m),{isNavigationMode:_0x16d99e,currentChangeNumber:_0x3dd555}=_0x29983c;let _0x10bcb6;if(_0x29983c['activeChange']=_0x16d99e?_0x29983c['diff']['changes']['get'](_0x3dd555+this['_step']):_0x29983c['diff']['changes']['first'],_0x29983c['activeChange']['data']['isOnRoot'])_0x10bcb6=_0x5e1001['editing']['view']['getDomRoot'](_0x29983c['activeChange']['rootName']);else{const _0x2d40ee=_0x5e1001['model']['markers']['get']('revision:'+_0x29983c['activeChange']['id']);_0x10bcb6=_0x7a3ec1(_0x5e1001['editing'],_0x2d40ee);}_0x2da720({'target':_0x10bcb6,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x3c7b1f,currentChangeNumber:_0x2c85d3,numberOfChanges:_0x2ba8a8,isReady:_0x23469a,isEnabled:_0x4fe82f}=this['editor']['plugins']['get'](m);this['isEnabled']=!!(_0x4fe82f&&_0x23469a&&_0x2ba8a8)&&(!_0x3c7b1f||(0x1===this['_step']?_0x2c85d3<_0x2ba8a8-0x1:_0x2c85d3>0x0));}}class _i extends _0x225fc7{constructor(_0x332dca){super(_0x332dca);const _0x4b90b1=this['bindTemplate'],_0x5855ec=new _0x5bb06b(_0x332dca),_0x2b0890=new _0x5bb06b(_0x332dca);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',(_0x241cdc,_0xe138c9)=>_0x241cdc&&_0xe138c9>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x9dadbb,_0x38d5fc,_0x5b6727,_0x27c138)=>{if(!_0x9dadbb)return g(_0x332dca,'Loading...');if(!_0x5b6727)return g(_0x332dca,'No\x20changes');const _0x3ddf31=g(_0x332dca,'NUMBER_OF_CHANGES',_0x5b6727);return _0x27c138?g(_0x332dca,'X_OF_Y_CHANGES',[_0x38d5fc+0x1,_0x5b6727]):_0x3ddf31;}),_0x5855ec['set']({'label':g(_0x332dca,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x3aaf5a}),_0x2b0890['set']({'label':g(_0x332dca,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x503175}),_0x5855ec['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x2b0890['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x5855ec['on']('execute',()=>this['fire']('execute','backward')),_0x2b0890['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',_0x4b90b1['if']('_isStatusLabelVisible','ck-hidden',_0x785057=>!_0x785057)]},'children':[{'text':_0x4b90b1['to']('isNavigationMode',_0x6751a0=>_0x6751a0?g(_0x332dca,'EDIT_X_OF_Y_REVISIONS')+':\x20':g(_0x332dca,'Total')+':\x20')}]},{'text':_0x4b90b1['to']('_statusText')}]},new _0x51c520(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x5855ec,_0x2b0890]}]});}}const ce='ck-editor__editable__loading-overlay';class le extends _0x47ebf6{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0xa8e363=this['editor']['editing']['view'];_0xa8e363['change'](_0x4a08d7=>{for(const _0x42653d of _0xa8e363['document']['roots'])_0x4a08d7['addClass'](ce,_0x42653d);});}['hide'](){const _0x1574d3=this['editor']['editing']['view'];_0x1574d3['change'](_0x5934e1=>{for(const _0x4b5257 of _0x1574d3['document']['roots'])_0x5934e1['removeClass'](ce,_0x4b5257);});}}class R extends _0x47ebf6{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[m,le];}['init'](){const _0x5bfa59=this['editor'],_0x3d7c49=_0x5bfa59['plugins']['get'](m),_0xe4d29d=_0x5bfa59['plugins']['get'](le);_0x5bfa59['ui']['componentFactory']['add']('exitToEditing',_0x12f519=>{const _0x137391=new _0x5bb06b(_0x12f519);return _0x137391['set']({'label':g(_0x12f519,'Back\x20to\x20editing'),'icon':_0x14d522,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x137391,'execute',()=>{_0x5bfa59['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x137391;}),_0x5bfa59['ui']['componentFactory']['add']('restoreRevision',_0x4cfed8=>{const _0x392366=new _0x5bb06b(_0x4cfed8);return _0x392366['set']({'label':g(_0x4cfed8,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x392366['bind']('isEnabled')['to'](_0x5bfa59['commands']['get']('restoreRevision')),this['listenTo'](_0x392366,'execute',()=>_0x5bfa59['execute']('restoreRevision')),_0x392366;}),_0x5bfa59['ui']['componentFactory']['add']('changesNavigation',_0x28195e=>{const _0x4821a0=new _i(_0x28195e),_0x403151=_0x5bfa59['commands']['get']('showPreviousChange'),_0x2cff46=_0x5bfa59['commands']['get']('showNextChange');return _0x4821a0['bind']('isBackwardNavigationEnabled')['to'](_0x403151,'isEnabled'),_0x4821a0['bind']('isForwardNavigationEnabled')['to'](_0x2cff46,'isEnabled'),_0x4821a0['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x3d7c49),this['listenTo'](_0x4821a0,'execute',(_0x166a76,_0x498bea)=>{_0x5bfa59['execute']('forward'===_0x498bea?'showNextChange':'showPreviousChange');}),_0x4821a0;}),_0xe4d29d['show'](),_0x3d7c49['on']('change:isReady',(_0x4f405f,_0x5aa2af,_0x1ab3fa)=>{_0x1ab3fa?_0xe4d29d['hide']():_0xe4d29d['show']();});}}class lt extends nt{['_resizeObserver']=null;constructor(_0x491c12,_0x10254c){super(_0x491c12,_0x10254c);const _0x5e5bbc=this['bindTemplate'];this['set']({'label':g(_0x491c12,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=g(_0x491c12,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x5e5bbc['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 _0x56e2c5=this['fieldView']['element'];this['_tooltipString']=_0x56e2c5['scrollWidth']>_0x56e2c5['clientWidth']&&_0x56e2c5['value']||'';}}class oi extends _0x225fc7{constructor(_0x59f6b9,_0x55184b,_0x4932f4){super(_0x59f6b9);const _0x30f2e4=new _0x2cc422();_0x30f2e4['set']({'content':_0x4e437e,'viewBox':'0\x200\x2011\x2010'});const _0x2436ca=['ck','ck-revision-history-sidebar__revision-author'];_0x4932f4&&_0x2436ca['push']('ck-revision-history-sidebar__revision-author_creator');const _0x2a01f9=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':g(_0x59f6b9,_0x4932f4?'Revision\x20creator':'Revision\x20author')},'children':[_0x30f2e4,_0x55184b['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x2436ca},'children':_0x2a01f9});}}function ni(_0x2497d6,_0x569e79){const _0x4437c6=_0x2497d6['bindTemplate'],_0x499f7b=_0x2497d6['locale'],_0x34b67f=_0xc59451(_0x499f7b);_0x34b67f['panelPosition']='sw';const _0x715d6=function(_0xb847a2,_0xf06287){const _0x547767=function(_0x1a18d3,_0x933b9c){const _0x17c857=_0x1a18d3['locale'],_0x32532e={'Compare\x20against\x20selected':g(_0x17c857,'Compare\x20against\x20selected'),'Name\x20this\x20revision':g(_0x17c857,'Name\x20this\x20revision'),'Restore\x20this\x20revision':g(_0x17c857,'Restore\x20this\x20revision')};return _0x933b9c['map'](_0x2673e5=>{const _0x15e068=_0x32532e[_0x2673e5['name']];return _0x15e068&&_0x15e068!==_0x2673e5['name']&&(_0x2673e5['name']=_0x15e068),_0x2673e5;});}(_0xb847a2,_0xf06287),_0xc818a1=new _0xe2334c();for(const _0x1580c5 of _0x547767){const _0x1c4802={'type':'button','model':new to({'label':_0x1580c5['name'],'class':_0x1580c5['class'],'withText':!0x0,'role':'menuitem','_action':_0x1580c5['action']})};_0x1c4802['model']['bind']('isEnabled')['to'](_0xb847a2,'isActionsDropdownOpen',_0x205b2b=>'function'!=typeof _0x1580c5['isEnabled']||(!_0x205b2b||_0x1580c5['isEnabled'](_0xb847a2))),_0xc818a1['add'](_0x1c4802);}return _0xc818a1;}(_0x2497d6,_0x569e79);return _0x2497d6['bind']('isActionsDropdownOpen')['to'](_0x34b67f,'isOpen'),_0x34b67f['buttonView']['set']({'label':g(_0x499f7b,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x7b9774}),_0x34b67f['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x4437c6['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x4437c6['to'](_0x4f9a29=>_0x4f9a29['stopPropagation']())}}),_0x34b67f['on']('execute',_0x584add=>{_0x2497d6['isReady']&&'function'==typeof _0x584add['source']['_action']&&_0x584add['source']['_action'](_0x2497d6);}),_0x569ebe(_0x34b67f,_0x715d6,{'role':'menu'}),_0x34b67f['listenTo'](_0x2497d6,'change:isActionsDropdownOpen',(_0x76978e,_0x5062c6,_0x64fa8a)=>{if(_0x64fa8a)for(const _0x189a3d of _0x34b67f['listView']['items']){const _0x36f6f5=_0x189a3d['children']['first'],_0x5d4545=_0x569e79['find'](_0x1202b3=>_0x1202b3['action']===_0x36f6f5['_action'])['isVisible'];_0x189a3d['isVisible']=void 0x0===_0x5d4545||_0x5d4545(_0x2497d6);}}),_0x34b67f;}class ai extends/* #__PURE__ -- @preserve */
26
- _0x247912(_0x225fc7){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x194895,_0x6b5b9d,_0x422e09,_0x160a45){super(_0x194895);const _0x39d56c=this['bindTemplate'],_0x3dd6ec=function(_0x451639,_0x273ac9){const _0x215a8a=Array['from'](_0x273ac9['authors'])['filter'](_0x34cbed=>_0x34cbed!=_0x273ac9['creator']);return _0x273ac9['creator']&&_0x215a8a['unshift'](_0x273ac9['creator']),_0x215a8a['map'](_0x1c664c=>new oi(_0x451639,_0x1c664c,_0x1c664c==_0x273ac9['creator']));}(_0x194895,_0x6b5b9d);this['id']=_0x6b5b9d['id'],this['_revision']=_0x6b5b9d,this['_requireRevisionName']=_0x160a45,this['bind']('name','createdAt')['to'](_0x6b5b9d),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x9d67f8=>{return _0x8b9fe8=_0x194895['uiLanguage'],(_0x44a959=_0x9d67f8)['toLocaleDateString'](_0x8b9fe8,{'month':'long','day':'numeric'})+',\x20'+_0x44a959['toLocaleTimeString'](_0x8b9fe8,{'hour':'numeric','minute':'numeric'});var _0x8b9fe8,_0x44a959;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new lt(_0x194895,ti),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x2a57ba=>_0x2a57ba||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x6bc88,_0x44230d)=>_0x6bc88&&_0x44230d),this['revisionActionsView']=_0x422e09&&_0x422e09['length']?ni(this,_0x422e09):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x39d56c['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x39d56c['if']('isEnabled','ck-disabled',_0x473a05=>!_0x473a05),_0x39d56c['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x39d56c['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x39d56c['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':_0x39d56c['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':_0x3dd6ec}]},this['revisionActionsView']],'on':{'click':_0x39d56c['to'](_0x7e898f=>{_0x7e898f['srcElement']['closest']('.ck-thread__remove-confirm')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x35bddb=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x35bddb,'change',()=>{this['_requireRevisionName']&&!_0x35bddb['value']||this['fire']('setName',{'id':this['id'],'name':_0x35bddb['value']}),_0x35bddb['value']||(_0x35bddb['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(_0x4e7494,_0x5d5c10){const _0x3b438c=_0x724367['fromJSDate'](_0x4e7494)['setLocale'](_0x5d5c10),_0x5aa080=_0x724367['local'](),_0x179b3c=_0x5aa080['minus']({'days':0x1})['startOf']('day');let _0x136cc7,_0x51b7f5;return _0x3b438c['hasSame'](_0x5aa080,'day')?(_0x136cc7=_0x3b438c['startOf']('day')['toJSDate'](),_0x51b7f5=_0x3b438c['toRelativeCalendar']()):_0x3b438c['hasSame'](_0x179b3c,'day')?(_0x136cc7=_0x179b3c['toJSDate'](),_0x51b7f5=_0x3b438c['toRelativeCalendar']()):_0x3b438c['hasSame'](_0x5aa080,'week')?(_0x136cc7=_0x3b438c['startOf']('week')['toJSDate'](),_0x51b7f5=_0x3b438c['weekdayLong']||''):_0x3b438c['hasSame'](_0x5aa080,'year')?(_0x136cc7=_0x3b438c['startOf']('month')['toJSDate'](),_0x51b7f5=_0x3b438c['monthLong']||''):(_0x136cc7=_0x3b438c['startOf']('year')['toJSDate'](),_0x51b7f5=String(_0x3b438c['year'])),{'startDate':_0x136cc7,'localizedPeriodName':_0x51b7f5};}class mi extends _0x225fc7{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x592316,_0x1dc775,_0x56a076,_0x370af3){super(_0x592316);const _0x572f82=vi(_0x1dc775,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x1dc775,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x56a076,this['_requireRevisionName']=_0x370af3,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':_0x572f82}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0xd2e005){const _0x88e80e=new ai(this['locale'],_0xd2e005,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x88e80e);}['removeRevision'](_0x5e2761){const _0x3f31e8=this['revisionViews']['find'](_0x122152=>_0x122152['id']===_0x5e2761['id']);this['revisionViews']['remove'](_0x3f31e8);}}class as extends _0x225fc7{constructor(_0x57f2ac){super(_0x57f2ac);const _0x72547e=new _0x2cc422();_0x72547e['content']=_0x3c6f9c,this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x72547e,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[g(_0x57f2ac,'Revision\x20history')]}]});}}class di extends _0x225fc7{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x294a86,_0x5a42f5,_0x5bb572,_0x4b39c5){super(_0x294a86);const _0x5248cf=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x5a42f5,this['_revisionActions']=_0x5bb572,this['_requireRevisionName']=_0x4b39c5,this['on']('select',(_0x308220,_0x5882e9)=>{this['fire']('revisionSelected',_0x5882e9);}),this['on']('setName',(_0x26c059,_0x4489e8)=>{this['fire']('revisionSetName',_0x4489e8);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new as(_0x294a86),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x5248cf['if']('isEnabled','ck-disabled',_0x5dd4e9=>!_0x5dd4e9)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x1a8784 of this['_revisions'])this['_addRevision'](_0x1a8784);this['_revisions']['on']('add',(_0x3780bd,_0x17f7e0)=>{this['_addRevision'](_0x17f7e0);}),this['_revisions']['on']('remove',(_0xaf8d91,_0x453c4b)=>{this['_removeRevision'](_0x453c4b);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x220ea9=>_0x220ea9['revisionViews']['map'](_0x467e4b=>_0x467e4b))['flat']();}['selectRevision'](_0x115649){for(const _0x201123 of this['revisionViews'])_0x115649&&_0x115649['id']===_0x201123['id']?_0x201123['select']():_0x201123['deselect']();}['highlightRevisions'](_0x4077e9){for(const _0x4fc117 of this['revisionViews'])_0x4077e9['some'](({id:_0x43536c})=>_0x43536c===_0x4fc117['id'])?_0x4fc117['highlight']():_0x4fc117['unhighlight']();}['_addRevision'](_0x289f38){const _0x5d63a9=vi(_0x289f38['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x31b712=this['timePeriodViews']['get'](0x0);_0x31b712&&_0x31b712['startDate']['getTime']()===_0x5d63a9['getTime']()||(_0x31b712=new mi(this['locale'],_0x5d63a9,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x31b712)),_0x31b712['addRevision'](_0x289f38);}['_removeRevision'](_0x27236c){const _0x1dc4e4=vi(_0x27236c['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x1dc4e4)['removeRevision'](_0x27236c);}['_getTimePeriodViewByStartDate'](_0x15407a){return this['timePeriodViews']['find'](_0x3aca4c=>_0x3aca4c['startDate']['getTime']()===_0x15407a['getTime']());}}class d extends _0x47ebf6{['_revisionViewer'];['_revisionsRepository'];['_sidebarView'];static ['defaultRevisionActions']=/* #__PURE__ -- @preserve */
23
+ import{ObservableMixin as _0x3196fa,uid as _0x3fbd15,Collection as _0x5f0faf,logWarning as _0x1ce756,FocusTracker as _0x12b377,KeystrokeHandler as _0x10ecca,scrollViewportToShowTarget as _0x5c8233,ResizeObserver as nt,ElementReplacer as ot,CKEditorError as _0xae2ed9}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x4dbdf7,set as _0x3c9090,unset as _0x501d64,isEqual as _0x34eb88}from'es-toolkit/compat';import{Plugin as _0x1aaf30,PendingActions as _0x3cbd42,Command as _0x4e2556,ElementApiMixin as _0x59ee7c,Editor as _0x4d07a6}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x25ff19,getMarkerDomElement as _0x56d34c,ConfirmMixin as ti,sanitizeEditorConfig as _0x1a3df8}from'ckeditor5-collaboration/dist/index.js';import{ViewContainerElement as _0x1586d5,ViewAttributeElement as _0x4a6f92,ViewEmptyElement as _0x35f70c,ViewRawElement as _0x34d858,ViewUIElement as _0x5e89db,ViewDocumentFragment as _0x12361a,ViewText as _0x3f0c02,ViewElement as _0x360a86,Element as ut,Range as lt,Position as ft,DocumentFragment as vt,Text as gt}from'@ckeditor/ckeditor5-engine/dist/index.js';import{IconHistory as _0x2aae82,IconChevronUp as _0x1dd0dd,IconChevronDown as _0x2464b9,IconUndo as _0x5c9b99,IconUser as _0x3c4811,IconThreeVerticalDots as _0x45dd43}from'@ckeditor/ckeditor5-icons/dist/index.js';import{View as ts,injectCssTransitionDisabler as _0x47db8c,submitHandler as _0x3b4acf,LabeledFieldView as _0x21d0c2,createLabeledInputText as _0x1a6c7a,createDropdown as _0x3baa9b,ListView as _0xaeeef7,ListItemView as _0x250e3b,ButtonView as te,MenuBarMenuView as _0x471360,MenuBarMenuListView as _0x118393,MenuBarMenuListItemView as _0x47d63b,MenuBarMenuListItemButtonView as _0x53ffb1,ContextualBalloon as _0x52db93,ToolbarSeparatorView as _0x32da21,IconView as _0x5c83c3,addListToDropdown as _0x11596f,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 _0x3c368c}from'luxon';class h extends/* #__PURE__ -- @preserve */
24
+ _0x3196fa(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x4f2892){super(),this['id']=_0x4f2892['id']||_0x3fbd15(),this['creator']=_0x4f2892['creator']||null,this['authors']=_0x4f2892['authors']||[],this['diffData']=_0x4f2892['diffData']||null,this['toVersion']=_0x4f2892['toVersion']||0x0,this['fromVersion']=_0x4f2892['fromVersion']||0x0,this['set']('name',_0x4f2892['name']||''),this['set']('createdAt',_0x4f2892['createdAt']||new Date()),this['set']('attributes',_0x4f2892['attributes']||{});}['setName'](_0x54d8c9){this['_update']({'name':_0x54d8c9});}['setAttribute'](_0x4aed2c,_0x453abe){const _0x2078cc=_0x4dbdf7(this['attributes']);_0x3c9090(_0x2078cc,_0x4aed2c,_0x453abe),this['_update']({'attributes':_0x2078cc});}['removeAttribute'](_0x557add){const _0x3b2c0f=_0x4dbdf7(this['attributes']);_0x501d64(_0x3b2c0f,_0x557add),this['_update']({'attributes':_0x3b2c0f});}['_update'](_0x4de87c,_0x2e9749=!0x1){let _0xd9f18d=!0x1;const _0x34f53e={'id':this['id']},_0x4e41af=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x5a29d6 of _0x4e41af){const _0x42c293=_0x4de87c[_0x5a29d6];void 0x0!==_0x42c293&&_0x42c293!==this[_0x5a29d6]&&(this[_0x5a29d6]=_0x42c293,_0x34f53e[_0x5a29d6]=_0x42c293,_0xd9f18d=!0x0);}_0xd9f18d&&(_0x34f53e['authors']&&(_0x34f53e['authorsIds']=_0x34f53e['authors']['map'](_0x597caf=>_0x597caf['id']),delete _0x34f53e['authors']),this['fire']('_update',_0x34f53e,_0x2e9749));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x3b1ec3=>_0x3b1ec3['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class I extends _0x1aaf30{['_revisions'];static get['requires'](){return[_0x25ff19];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x5d1658){super(_0x5d1658),this['_revisions']=new _0x5f0faf();}['afterInit'](){!async function(_0x4ef661){const _0x5df1b6=_0x51f2b1([0x73,0x39,0x4e,0x64,0x55,0x79,0x38,0x68,0x32,0x4a,0x75,0x78,0x50,0x7a,0x6a,0x34,0x69,0x59,0x63,0x76,0x62,0x57,0x4c,0x30,0x36,0x35,0x65,0x71,0x70,0x51,0x74,0x61,0x4d,0x48,0x43,0x5a,0x45,0x6b,0x4b,0x31,0x37,0x47,0x41,0x67,0x44,0x72,0x56,0x6f,0x49,0x33,0x42,0x54,0x53,0x58,0x6e,0x6c,0x52,0x46,0x6d,0x4f,0x77,0x66]),_0x5b391a=0xeb829,_0x45c19a=0x7365c09a,_0x5002da=0x7362a4da^_0x45c19a,_0x654cda=window[_0x51f2b1([0x44,0x61,0x74,0x65])][_0x51f2b1([0x6e,0x6f,0x77])](),_0x1b2a07=_0x4ef661[_0x51f2b1([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x39bbdc=new window[(_0x51f2b1([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2e2fa8=>{_0x1b2a07[_0x51f2b1([0x6f,0x6e,0x63,0x65])](_0x51f2b1([0x72,0x65,0x61,0x64,0x79]),_0x2e2fa8);}),_0x502c7b={[_0x51f2b1([0x6b,0x74,0x79])]:_0x51f2b1([0x45,0x43]),[_0x51f2b1([0x75,0x73,0x65])]:_0x51f2b1([0x73,0x69,0x67]),[_0x51f2b1([0x63,0x72,0x76])]:_0x51f2b1([0x50,0x2d,0x32,0x35,0x36]),[_0x51f2b1([0x78])]:_0x51f2b1([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]),[_0x51f2b1([0x79])]:_0x51f2b1([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]),[_0x51f2b1([0x61,0x6c,0x67])]:_0x51f2b1([0x45,0x53,0x32,0x35,0x36])},_0x2498ad=_0x1b2a07[_0x51f2b1([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x51f2b1([0x67,0x65,0x74])](_0x51f2b1([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x551e46(){let _0x38e37c,_0x8ec9f4=null,_0x20a63f=null;try{if(_0x2498ad==_0x51f2b1([0x47,0x50,0x4c]))return _0x51f2b1([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x38e37c=_0x4cf363(),!_0x38e37c)return _0x51f2b1([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x38e37c[_0x51f2b1([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x20a63f=_0x40bf1a(_0x38e37c[_0x51f2b1([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x38e37c[_0x51f2b1([0x6a,0x74,0x69])])),await _0x417e79()?_0x1a8ed7()?_0x4d3bed()?_0x51f2b1([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x39e1f6()?(_0x38e37c[_0x51f2b1([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x51f2b1([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x8ec9f4=_0x286104(_0x51f2b1([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x38e37c[_0x51f2b1([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x51f2b1([0x74,0x72,0x69,0x61,0x6c])&&(_0x8ec9f4=_0x286104(_0x51f2b1([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x349c0d()):_0x51f2b1([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x51f2b1([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x51f2b1([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch(_0x98006d){return _0x51f2b1([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x4d3bed(){const _0x3dc265=[_0x51f2b1([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x51f2b1([0x74,0x72,0x69,0x61,0x6c])][_0x51f2b1([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x38e37c[_0x51f2b1([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x654cda/0x3e8:0xe10*_0x5002da;return _0x38e37c[_0x51f2b1([0x65,0x78,0x70])]<_0x3dc265;}function _0x1a8ed7(){const _0x532cc3=_0x38e37c[_0x51f2b1([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x532cc3)return!0x1;if(_0x532cc3[_0x51f2b1([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x51f2b1([0x2a])))return!0x0;if(_0x532cc3[_0x51f2b1([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x51f2b1([0x52,0x48])))return!0x0;if(_0x532cc3[_0x51f2b1([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x51f2b1([0x52,0x52,0x48]))){if(_0x5bd01f())return!0x0;if(_0x3b1f16()||_0x2aaeb4())return!0x0;}return!0x1;}function _0x39e1f6(){const _0x47ef96=_0x38e37c[_0x51f2b1([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x47ef96||0x0==_0x47ef96[_0x51f2b1([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x1e9cbf}=new URL(window[_0x51f2b1([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x47ef96[_0x51f2b1([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x1e9cbf))return!0x0;const _0x183486=_0x1e9cbf[_0x51f2b1([0x73,0x70,0x6c,0x69,0x74])](_0x51f2b1([0x2e]));return _0x47ef96[_0x51f2b1([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x506d7c=>_0x506d7c[_0x51f2b1([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x51f2b1([0x2a])))[_0x51f2b1([0x6d,0x61,0x70])](_0x38d7c2=>_0x38d7c2[_0x51f2b1([0x73,0x70,0x6c,0x69,0x74])](_0x51f2b1([0x2e])))[_0x51f2b1([0x73,0x6f,0x6d,0x65])](_0x519dfc=>_0x183486[_0x51f2b1([0x65,0x76,0x65,0x72,0x79])]((_0x46577f,_0x31656d)=>_0x519dfc[_0x31656d]===_0x46577f||_0x519dfc[_0x31656d]===_0x51f2b1([0x2a])));}function _0x349c0d(){return _0x8ec9f4&&_0x20a63f?new window[(_0x51f2b1([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x52983b,_0x5c7a4f)=>{_0x8ec9f4[_0x51f2b1([0x74,0x68,0x65,0x6e])](_0x52983b,_0x5c7a4f),_0x20a63f[_0x51f2b1([0x74,0x68,0x65,0x6e])](_0x382154=>{_0x382154!=_0x51f2b1([0x56,0x61,0x6c,0x69,0x64])&&_0x52983b(_0x382154);},_0x5c7a4f);}):_0x8ec9f4||_0x20a63f||_0x51f2b1([0x56,0x61,0x6c,0x69,0x64]);}}function _0x40bf1a(_0x445a76,_0x24101b){return new window[(_0x51f2b1([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0xb29525=>{if(_0x5cbbdf())return _0xb29525(_0x51f2b1([0x56,0x61,0x6c,0x69,0x64]));_0x1caa1c(),_0x1b2a07[_0x51f2b1([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x51f2b1([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x3c991c=!0x1;const _0x1d6829=_0x3fbd15();function _0x46dabe(_0x388aba){return!!_0x388aba&&(typeof _0x388aba===_0x51f2b1([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x388aba===_0x51f2b1([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x388aba[_0x51f2b1([0x74,0x68,0x65,0x6e])]===_0x51f2b1([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x388aba[_0x51f2b1([0x63,0x61,0x74,0x63,0x68])]===_0x51f2b1([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x1b2871(_0x446a90){_0xe30ff8(_0x446a90)[_0x51f2b1([0x74,0x68,0x65,0x6e])](_0x226e4a=>{if(!_0x226e4a||_0x226e4a[_0x51f2b1([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x51f2b1([0x6f,0x6b]))return _0x51f2b1([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x3ff437(_0x4bbb5b(_0x1d6829+_0x24101b))!=_0x226e4a[_0x51f2b1([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x51f2b1([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x51f2b1([0x56,0x61,0x6c,0x69,0x64]);})[_0x51f2b1([0x74,0x68,0x65,0x6e])](_0x3845e7=>(_0x5d6cd7(),_0x3845e7),()=>{const _0xa3fea5=_0x1b05ae();return null==_0xa3fea5?(_0x5d6cd7(),_0x51f2b1([0x56,0x61,0x6c,0x69,0x64])):_0x51f2b1(_0x654cda-_0xa3fea5>(0x5769449a^_0x45c19a)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x51f2b1([0x74,0x68,0x65,0x6e])](_0xb29525)[_0x51f2b1([0x63,0x61,0x74,0x63,0x68])](()=>{_0xb29525(_0x51f2b1([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x504484=0x73532e1a^_0x45c19a;function _0x5d6cd7(){const _0xf9c249=_0x51f2b1([0x6c,0x6c,0x63,0x74,0x2d])+_0x3ff437(_0x4bbb5b(_0x445a76)),_0x5ecc95=_0x5d3e08(_0x3ff437(window[_0x51f2b1([0x4d,0x61,0x74,0x68])][_0x51f2b1([0x63,0x65,0x69,0x6c])](_0x654cda/_0x504484)));window[_0x51f2b1([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x51f2b1([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0xf9c249,_0x5ecc95);}function _0x1b05ae(){const _0x5df0fe=_0x51f2b1([0x6c,0x6c,0x63,0x74,0x2d])+_0x3ff437(_0x4bbb5b(_0x445a76)),_0x2f32b3=window[_0x51f2b1([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x51f2b1([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x5df0fe);return _0x2f32b3?window[_0x51f2b1([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x5d3e08(_0x2f32b3),0x10)*_0x504484:null;}function _0xe30ff8(_0x54656f){return new window[(_0x51f2b1([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x1a1315,_0x57541f)=>{_0x54656f[_0x51f2b1([0x74,0x68,0x65,0x6e])](_0x1a1315,_0x57541f),window[_0x51f2b1([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x57541f,0x7364145a^_0x45c19a);});}}_0x1b2a07[_0x51f2b1([0x6f,0x6e])](_0x51f2b1([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x24bb5a,_0xc66c77)=>{if(_0xc66c77[0x0]!=_0x445a76)return _0xb29525(_0x51f2b1([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0xc66c77[0x1]={..._0xc66c77[0x1],[_0x51f2b1([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x1d6829};},{[_0x51f2b1([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x51f2b1([0x68,0x69,0x67,0x68])}),_0x1b2a07[_0x51f2b1([0x6f,0x6e])](_0x51f2b1([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x238491=>{_0x46dabe(_0x238491[_0x51f2b1([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x3c991c=!0x0,_0x1b2871(_0x238491[_0x51f2b1([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x51f2b1([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x51f2b1([0x6c,0x6f,0x77])}),_0x39bbdc[_0x51f2b1([0x74,0x68,0x65,0x6e])](()=>{_0x3c991c||_0xb29525(_0x51f2b1([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x5cbbdf(){return _0x1b2a07[_0x51f2b1([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x51f2b1([0x76,0x69,0x65,0x77])][_0x51f2b1([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x51f2b1([0x61,0x75,0x74,0x6f]);}function _0x1caa1c(){_0x1b2a07[_0x51f2b1([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x51f2b1([0x76,0x69,0x65,0x77])][_0x51f2b1([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x51f2b1([0x61,0x75,0x74,0x6f]);}}function _0x286104(_0x2aad67){const _0x25254f=[new window[(_0x51f2b1([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x551a04=>setTimeout(_0x551a04,0x736cfe56^_0x45c19a)),_0x39bbdc[_0x51f2b1([0x74,0x68,0x65,0x6e])](()=>new window[(_0x51f2b1([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x360da6=>{const _0x221d90=0x7365c09d^_0x45c19a,_0x136ee0=_0x4ef661[_0x51f2b1([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x2262c8(){_0x136ee0[_0x51f2b1([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x221d90&&_0x360da6();}_0x2262c8(),_0x136ee0[_0x51f2b1([0x6f,0x6e])](_0x51f2b1([0x61,0x64,0x64]),_0x2262c8);})),new window[(_0x51f2b1([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x5438a8=>{function _0x570f42(){for(const _0x58530a in window)if(window[_0x51f2b1([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x51f2b1([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x58530a))&&window[_0x58530a]==_0x5b391a)return _0x5438a8();_0x1b2a07[_0x51f2b1([0x73,0x74,0x61,0x74,0x65])]!=_0x51f2b1([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x51f2b1([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x570f42,0x7365d312^_0x45c19a);}_0x293ffe(_0x51f2b1([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x570f42();})];return window[_0x51f2b1([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x51f2b1([0x72,0x61,0x63,0x65])](_0x25254f)[_0x51f2b1([0x74,0x68,0x65,0x6e])](()=>_0x2aad67);}async function _0x2a7b68(){if(await _0x39bbdc,_0x293ffe(_0x51f2b1([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x13de35=_0x4ef661[_0x51f2b1([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x328cfa=_0x4ef661[_0x51f2b1([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])](_0x13de35[_0x51f2b1([0x69,0x64])]),_0x38b9fc=_0x482090(_0x51f2b1([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x38b9fc[_0x51f2b1([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x13de35['id'],_0x328cfa?_0x328cfa['id']:null,!0x0),_0x38b9fc[_0x51f2b1([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x51f2b1([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x38b9fc[_0x51f2b1([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x38b9fc[_0x51f2b1([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x41f2bd,void(_0x38b9fc[_0x51f2b1([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x41f2bd);}if(_0x293ffe(_0x51f2b1([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x325afe=_0x482090(_0x51f2b1([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x325afe[_0x51f2b1([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x51f2b1([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x325afe[_0x51f2b1([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x325afe[_0x51f2b1([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x41f2bd,_0x325afe[_0x51f2b1([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x41f2bd;}_0x1b2a07[_0x51f2b1([0x6d,0x6f,0x64,0x65,0x6c])][_0x51f2b1([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x41f2bd,_0x1b2a07[_0x51f2b1([0x6d,0x6f,0x64,0x65,0x6c])][_0x51f2b1([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x41f2bd,_0x1b2a07[_0x51f2b1([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x51f2b1([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x5bd01f(){return _0x293ffe(_0x51f2b1([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x482090(_0x51f2b1([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x51f2b1([0x73,0x74,0x61,0x74,0x65])]==_0x51f2b1([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x3b1f16(){return _0x293ffe(_0x51f2b1([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 _0x2aaeb4(){return _0x293ffe(_0x51f2b1([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0xd3cce5(_0x280566){const _0x7f8db5=_0x5489ae();_0x1b2a07[_0x7f8db5]=_0x51f2b1([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])+_0x280566,_0x280566[_0x51f2b1([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x51f2b1([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x5489ae()]=_0x5b391a),_0x280566!=_0x51f2b1([0x56,0x61,0x6c,0x69,0x64])&&_0x2a7b68();}function _0x5489ae(){const _0xd158aa=window[_0x51f2b1([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x51f2b1([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x51f2b1([0x6e,0x6f,0x77])]())[_0x51f2b1([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x51f2b1([0x2e]),'');let _0x41c972=_0x51f2b1([0x73]);for(let _0x66d05d=0x0;_0x66d05d<_0xd158aa[_0x51f2b1([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x66d05d+=0x2){let _0x10dbfe=window[_0x51f2b1([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0xd158aa[_0x51f2b1([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x66d05d,_0x66d05d+0x2));_0x10dbfe>=_0x5df1b6[_0x51f2b1([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x10dbfe-=_0x5df1b6[_0x51f2b1([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x41c972+=_0x5df1b6[_0x10dbfe];}return _0x41c972;}function _0x4cf363(){const _0x3d2af9=_0x2498ad[_0x51f2b1([0x73,0x70,0x6c,0x69,0x74])](_0x51f2b1([0x2e]));if(0x3!=_0x3d2af9[_0x51f2b1([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x3536c6(_0x3d2af9[0x1]);function _0x3536c6(_0x361062){const _0x2175d2=_0x137c66(_0x361062);return _0x2175d2&&_0x28db53()?_0x2175d2:null;function _0x28db53(){const _0x1542a0=_0x2175d2[_0x51f2b1([0x6a,0x74,0x69])],_0x2504ab=window[_0x51f2b1([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x1542a0[_0x51f2b1([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x1542a0[_0x51f2b1([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x3499ee={..._0x2175d2,[_0x51f2b1([0x6a,0x74,0x69])]:_0x1542a0[_0x51f2b1([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x1542a0[_0x51f2b1([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x3499ee[_0x51f2b1([0x76,0x63])],_0x4bbb5b(_0x3499ee)==_0x2504ab;}}}async function _0x417e79(){let _0x411351=!0x0;try{const _0x5669a9=_0x2498ad[_0x51f2b1([0x73,0x70,0x6c,0x69,0x74])](_0x51f2b1([0x2e])),[_0xda09d0,_0x4ad727,_0xd08719]=_0x5669a9;return _0x2c571f(_0xda09d0),await _0x236d9c(_0xda09d0,_0x4ad727,_0xd08719),_0x411351;}catch(_0x2bd910){return!0x1;}function _0x2c571f(_0x111b96){const _0x4d8686=_0x137c66(_0x111b96);_0x4d8686&&_0x4d8686[_0x51f2b1([0x61,0x6c,0x67])]==_0x51f2b1([0x45,0x53,0x32,0x35,0x36])||(_0x411351=!0x1);}async function _0x236d9c(_0x30247b,_0x2b0839,_0x11d473){const _0x558031=window[_0x51f2b1([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x51f2b1([0x66,0x72,0x6f,0x6d])](_0x56f392(_0x11d473),_0x54f835=>_0x54f835[_0x51f2b1([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x49d25a=new window[(_0x51f2b1([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x51f2b1([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x30247b+_0x51f2b1([0x2e])+_0x2b0839),_0x82d333=window[_0x51f2b1([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x51f2b1([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x82d333)return;const _0x2b4eb8=await _0x82d333[_0x51f2b1([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x51f2b1([0x6a,0x77,0x6b]),_0x502c7b,{[_0x51f2b1([0x6e,0x61,0x6d,0x65])]:_0x51f2b1([0x45,0x43,0x44,0x53,0x41]),[_0x51f2b1([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x51f2b1([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x51f2b1([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x82d333[_0x51f2b1([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x51f2b1([0x6e,0x61,0x6d,0x65])]:_0x51f2b1([0x45,0x43,0x44,0x53,0x41]),[_0x51f2b1([0x68,0x61,0x73,0x68])]:{[_0x51f2b1([0x6e,0x61,0x6d,0x65])]:_0x51f2b1([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x2b4eb8,_0x558031,_0x49d25a)||(_0x411351=!0x1);}}function _0x137c66(_0x2a121d){return _0x2a121d[_0x51f2b1([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x51f2b1([0x65,0x79]))?JSON[_0x51f2b1([0x70,0x61,0x72,0x73,0x65])](_0x56f392(_0x2a121d)):null;}function _0x56f392(_0x1a4bc0){return window[_0x51f2b1([0x61,0x74,0x6f,0x62])](_0x1a4bc0[_0x51f2b1([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x51f2b1([0x2b]))[_0x51f2b1([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x51f2b1([0x2f])));}function _0x4bbb5b(_0x376dfa){let _0x384c4b=0x1505;function _0x2c435d(_0x449629){for(let _0xd15ab8=0x0;_0xd15ab8<_0x449629[_0x51f2b1([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0xd15ab8++){const _0x1bae11=_0x449629[_0x51f2b1([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0xd15ab8);_0x384c4b=(_0x384c4b<<0x5)+_0x384c4b+_0x1bae11,_0x384c4b&=_0x384c4b;}}function _0x58aa85(_0x1b168f){Array[_0x51f2b1([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x1b168f)?_0x1b168f[_0x51f2b1([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x58aa85):_0x1b168f&&typeof _0x1b168f==_0x51f2b1([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x51f2b1([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x1b168f)[_0x51f2b1([0x73,0x6f,0x72,0x74])]()[_0x51f2b1([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x1e429e,_0x35c472])=>{_0x2c435d(_0x1e429e),_0x58aa85(_0x35c472);}):_0x2c435d(window[_0x51f2b1([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x1b168f));}return _0x58aa85(_0x376dfa),_0x384c4b>>>0x0;}function _0x3ff437(_0x271735){return _0x271735[_0x51f2b1([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x51f2b1([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x51f2b1([0x30]));}function _0x5d3e08(_0x4269b7){return _0x4269b7[_0x51f2b1([0x73,0x70,0x6c,0x69,0x74])]('')[_0x51f2b1([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x51f2b1([0x6a,0x6f,0x69,0x6e])]('');}function _0x293ffe(_0xe522d5){return _0x1b2a07[_0x51f2b1([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x51f2b1([0x68,0x61,0x73])](_0xe522d5);}function _0x482090(_0x27b884){return _0x1b2a07[_0x51f2b1([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x51f2b1([0x67,0x65,0x74])](_0x27b884);}function _0x41f2bd(){}function _0x51f2b1(_0x1f662d){return _0x1f662d['map'](_0x50d46c=>String['fromCharCode'](_0x50d46c))['join']('');}_0xd3cce5(await _0x551e46());}(this);}['createRevision'](_0x14267c){const _0x251aff=this['editor']['plugins']['get']('Users');return new h({'id':_0x14267c['id'],'name':_0x14267c['name'],'creator':_0x14267c['creatorId']?_0x251aff['getUser'](_0x14267c['creatorId']):null,'diffData':_0x14267c['diffData']||_0x14267c['data'],'authors':_0x14267c['authorsIds']['map'](_0x13665c=>_0x251aff['getUser'](_0x13665c)),'createdAt':new Date(_0x14267c['createdAt']),'attributes':_0x14267c['attributes'],'fromVersion':_0x14267c['fromVersion'],'toVersion':_0x14267c['toVersion']});}['addRevision'](_0x39327d,_0x5c7f98=0x0){this['_revisions']['add'](_0x39327d,_0x5c7f98);}['getRevision'](_0x3b6f4e){return this['_revisions']['get'](_0x3b6f4e);}['getRevisions'](_0x3590e0={'toJSON':!0x1}){const _0x9e879c=Array['from'](this['_revisions']);return _0x9e879c['reverse'](),_0x3590e0['toJSON']?_0x9e879c['map'](_0x107706=>_0x107706['toJSON']()):_0x9e879c;}['getIndex'](_0x31c40a){return this['_revisions']['getIndex'](_0x31c40a);}['getEarlierVisibleRevision'](_0x9ef759){const [,_0x20f054]=this['getRevisionsIterator'](_0x9ef759,{'direction':'earlier'});return _0x20f054;}['getLaterVisibleRevision'](_0x1b0fd8){const [,_0x211040]=this['getRevisionsIterator'](_0x1b0fd8,{'direction':'later'});return _0x211040;}['getRevisionsInDiff'](_0x552f58){const _0x5459f8=[];for(const _0x26b3a6 of this['getRevisionsIterator'](_0x552f58['newRevisionId']))if(_0x5459f8['push'](_0x26b3a6),_0x26b3a6['id']===_0x552f58['oldRevisionId'])break;return _0x5459f8;}*['getRevisionsIterator'](_0x28eee1,{direction:_0x2bf7bb='earlier',filter:_0x4fbdb2=()=>!0x0}={}){const _0x54e0a8='earlier'===_0x2bf7bb?0x1:-0x1;let _0x535a7f=this['_revisions']['get'](_0x28eee1),_0x20ceaa=this['getIndex'](_0x535a7f);for(yield _0x535a7f;_0x535a7f;){if(_0x20ceaa+=_0x54e0a8,_0x535a7f=this['getRevision'](_0x20ceaa),!_0x535a7f)return;_0x4fbdb2(_0x535a7f)&&(yield _0x535a7f);}}}class V extends _0x1aaf30{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x1586d5,'c'],[_0x4a6f92,'a'],[_0x35f70c,'e'],[_0x34d858,'r'],[_0x5e89db,'u']]);['_typeCharToViewClass']=new Map([['c',_0x1586d5],['a',_0x4a6f92],['e',_0x35f70c],['r',_0x34d858],['u',_0x5e89db]]);async['loadRevisionData'](_0xbf547e,_0x5b8d31){if(_0xbf547e['diffData']||!_0x5b8d31)return;const _0x73e5e2=this['editor']['config']['get']('collaboration.channelId'),_0x5e3e32=await _0x5b8d31['getRevision']({'channelId':_0x73e5e2,'revisionId':_0xbf547e['id']});_0xbf547e['diffData']=_0x5e3e32['diffData'];}['getRevisionDocumentData'](_0x2a00e0){const _0x17019e={};for(const _0x45c5e3 in _0x2a00e0['diffData']){if(_0x2a00e0['diffData'][_0x45c5e3]['attachChange']&&!_0x2a00e0['diffData'][_0x45c5e3]['attachChange']['isAttached'])continue;const _0x139e91=this['_removeRevisionMarkers'](JSON['parse'](_0x2a00e0['diffData'][_0x45c5e3]['insertions'])),_0x1e0493=this['editor']['editing']['view']['document'],_0x1f92db=new _0x12361a(_0x1e0493,_0x139e91['map'](_0x584d6c=>this['_getViewFromDiffObj'](_0x584d6c,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x17019e[_0x45c5e3]=this['editor']['data']['processor']['toData'](_0x1f92db),this['editor']['data']['processor']['useFillerType']('default');}return _0x17019e;}['getRevisionRootsAttributes'](_0x328120){const _0x3c7015={};for(const _0x32948d in _0x328120['diffData'])_0x328120['diffData'][_0x32948d]['attachChange']&&!_0x328120['diffData'][_0x32948d]['attachChange']['isAttached']||(_0x3c7015[_0x32948d]=_0x328120['diffData'][_0x32948d]['attributesAfter']||{});return _0x3c7015;}['_getTypeCharForViewElement'](_0x114257){return this['_viewClassToTypeChar']['get'](_0x114257['constructor']);}['_getViewFromDiffObj'](_0x1c75a7,_0x343c61){const _0xbc7487=this['editor']['editing']['view']['document'];if('string'==typeof _0x1c75a7)return new _0x3f0c02(_0xbc7487,_0x1c75a7);{let _0x6e7ddc,_0x6341ee;_0x6341ee='u'==_0x1c75a7['type']||'r'==_0x1c75a7['type']?[]:_0x1c75a7['children']['map'](_0x55e0eb=>this['_getViewFromDiffObj'](_0x55e0eb,_0x343c61));const _0x5bf317=this['_typeCharToViewClass']['get'](_0x1c75a7['type'])||_0x360a86,_0x1ca152=this['editor']['data']['htmlProcessor']['domConverter'];if(_0x6e7ddc=new _0x5bf317(_0xbc7487,_0x1c75a7['name'],_0x1c75a7['attributes'],_0x6341ee),'u'==_0x1c75a7['type']&&_0x1c75a7['children'][0x0]){const _0x2333b7=_0x1c75a7['children'][0x0];if(_0x6e7ddc['render']=function(_0x2be9ad){const _0xe1c7c0=_0x2be9ad['createElement']('div');return _0xe1c7c0['innerHTML']=_0x2333b7,_0xe1c7c0['childNodes'][0x0];},_0x343c61){const _0xf308fb=new _0x12361a(_0xbc7487);_0xf308fb['_appendChild'](_0x6e7ddc);const _0x39357d=Array['from'](_0x1ca152['viewChildrenToDom'](_0xf308fb,{'bind':!0x1})),_0x417d33=_0x1ca152['domDocument']['createElement']('div');_0x417d33['append'](..._0x39357d),_0x6e7ddc=Array['from'](_0x1ca152['domChildrenToView'](_0x417d33))[0x0];}}else{if('r'==_0x1c75a7['type']&&_0x1c75a7['children'][0x0]){const _0x5c0074=_0x1c75a7['children'][0x0];if(_0x6e7ddc['render']=function(_0x201e61){_0x201e61['innerHTML']=_0x5c0074;},_0x343c61){const _0x619a76=new _0x12361a(_0xbc7487);_0x619a76['_appendChild'](_0x6e7ddc);const _0x52a3=Array['from'](_0x1ca152['viewChildrenToDom'](_0x619a76,{'bind':!0x1})),_0x14ad5a=_0x1ca152['domDocument']['createElement']('div');_0x14ad5a['append'](..._0x52a3);const _0x58cbc2=Array['from'](_0x1ca152['domChildrenToView'](_0x14ad5a));_0x58cbc2['length']>0x1?_0x6e7ddc['_appendChild'](_0x58cbc2):_0x6e7ddc=_0x58cbc2[0x0];}}}if(_0x1c75a7['customProperties']){for(const [_0x38b630,_0x453e46]of _0x1c75a7['customProperties'])_0x6e7ddc['_setCustomProperty'](_0x38b630,_0x453e46);}const _0x1375d4=void 0x0===_0x1c75a7['fillerOffset']?null:_0x1c75a7['fillerOffset'];return null!==_0x1375d4&&(_0x6e7ddc['getFillerOffset']=()=>_0x1375d4),_0x6e7ddc;}}['_makeModelFromViewString'](_0x531313){const _0x4a4102=JSON['parse'](_0x531313),_0x246d7c=this['editor']['editing']['view']['document'],_0x48f2d4=new _0x12361a(_0x246d7c,_0x4a4102['map'](_0x4605b6=>this['_getViewFromDiffObj'](_0x4605b6,!0x0)));return this['editor']['data']['toModel'](_0x48f2d4);}['_removeRevisionMarkers'](_0x470195){return(_0x470195=_0x470195['filter'](_0x1b9d3b=>!_0x1b9d3b['name']||'revision-start'!==_0x1b9d3b['name']&&'revision-end'!==_0x1b9d3b['name']))['forEach'](_0x40b808=>{'string'!=typeof _0x40b808&&(_0x40b808['children']=this['_removeRevisionMarkers'](_0x40b808['children']),_0x40b808['attributes']=_0x40b808['attributes']['filter'](_0x16189d=>!_0x16189d[0x0]['startsWith']('data-revision-')));}),_0x470195;}}function g(_0x463d59,_0x16ea78,_0x1597ab){const t=_0x463d59['t'];switch(_0x16ea78){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'},_0x1597ab);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x1597ab);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 _0x1aaf30{['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[_0x25ff19,I,V,_0x3cbd42];}constructor(_0x45e93d){super(_0x45e93d),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 _0x1a67d1=_0x3fbd15();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x1a67d1},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 _0xd1bf6e=this['repository']['getRevision'](0x0),_0x13b6b9=_0xd1bf6e&&null===_0xd1bf6e['creator']?_0xd1bf6e:null;if(this['_continueCurrentRevision']=!!_0x13b6b9&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x741d98=this['_source']['getCurrentRevisionId'](),_0x28a65a=this['repository']['getRevision'](_0x741d98);if(_0x28a65a)this['_startingVersion']=_0x28a65a['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x18cfcc=this['_source']['history']['_operations']['find'](_0x271bbe=>!_0x271bbe['_isInit']),_0x1cda93=_0x18cfcc?_0x18cfcc['baseVersion']:this['_source']['history']['version'];_0xd1bf6e?(_0xd1bf6e['toVersion']<_0x1cda93&&_0xd1bf6e['_update']({'toVersion':_0x1cda93}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x13b6b9['id'],this['_startingVersion']=_0x13b6b9['fromVersion']):(this['_startingVersion']=_0xd1bf6e['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x1cda93,this['_continueCurrentRevision']=!0x1);}}else _0x13b6b9&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x13b6b9['toVersion'],this['editor']['model']['document']['history']['version']),_0x13b6b9['fromVersion']===_0x13b6b9['toVersion']?(0x0!==_0x13b6b9['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x13b6b9['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x13b6b9['id'],this['_startingVersion']=_0x13b6b9['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',_0x5da19c=>!_0x5da19c),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0xa38073=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x1e2ea8;for(const _0x244deb in _0xa38073){const _0xce2f92=_0x244deb,_0x51ab2c=_0xa38073[_0xce2f92];if('revisionHistoryLicenseKeyValid'==_0x51ab2c||'revisionHistoryLicenseKeyInvalid'==_0x51ab2c||'revisionHistoryLicenseKeyExpired'==_0x51ab2c||'revisionHistoryLicenseKeyDomainLimit'==_0x51ab2c||'revisionHistoryLicenseKeyNotAllowed'==_0x51ab2c||'revisionHistoryLicenseKeyEvaluationLimit'==_0x51ab2c||'revisionHistoryLicenseKeyTrialLimit'==_0x51ab2c||'revisionHistoryLicenseKeyUsageLimit'==_0x51ab2c){delete _0xa38073[_0xce2f92],_0x1e2ea8=_0x51ab2c,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x1e2ea8&&_0xa38073['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x1e2ea8&&_0xa38073['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x1e2ea8&&_0xa38073['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x1e2ea8&&_0xa38073['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x1e2ea8&&_0xa38073['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x1e2ea8&&_0xa38073['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x1e2ea8&&_0xa38073['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x20d99e=this['repository']['getRevision'](0x0),_0x5a4cbb=await this['getRevisionDocumentData'](_0x20d99e),_0x13c9a8=await this['getRevisionRootsAttributes'](_0x20d99e);this['_replaceEditorDataWithRevisionData'](_0x5a4cbb,_0x13c9a8);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x4af9a9){this['_source']=_0x4af9a9;}async['update'](){const _0x4c2a68=await this['_source']['getLatestVersion']();if(_0x4c2a68>this['currentRevision']['toVersion']){await this['_loadState']();const _0x214270=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x4c2a68});_0x214270['authors']=_0x214270['authorsIds']['map'](_0x1fba76=>this['editor']['plugins']['get']('Users')['getUser'](_0x1fba76)),this['currentRevision']['_update'](_0x214270);}}async['saveRevision'](_0x5d42a6={},_0x5487ee=null){const _0x5a90fc=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x5487ee>this['currentRevision']['toVersion']&&(_0x5487ee=null),null===_0x5487ee&&(_0x5487ee=await this['_source']['getLatestVersion']());const _0x474607=this['_getFromVersion'](_0x5487ee),_0x1e4b14=this['buildRevisionData']({'from':_0x474607,'to':_0x5487ee});if(this['currentRevision']['toVersion']<_0x5487ee){const _0x470aa2=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x5487ee,'to':_0x5487ee});_0x470aa2['authors']=[],_0x470aa2['authorsIds']=[],_0x470aa2['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x470aa2,!0x0),delete _0x470aa2['authors'],_0x5a90fc['push'](_0x470aa2);}_0x5d42a6['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x5d42a6['name']=_0x5d42a6['name']||null,_0x5d42a6['id']=_0x5d42a6['id']||_0x3fbd15(),_0x5d42a6={..._0x5d42a6,..._0x1e4b14};const _0x49f692=this['addRevisionData'](_0x5d42a6);_0x5a90fc['push'](_0x5d42a6);const _0x5161e0=this['repository']['getIndex'](_0x49f692);if(0x0!==_0x5161e0){const _0x19fac2=this['repository']['getRevision'](_0x5161e0-0x1);if(_0x19fac2['fromVersion']!==_0x5487ee){const _0x336ecf=this['_revisionDataBuilder']['getData'](_0x5487ee,_0x19fac2['toVersion']),_0x1a943f={'id':_0x19fac2['id'],'diffData':_0x336ecf['diffData'],'authorsIds':_0x336ecf['authorsIds'],'authors':_0x336ecf['authorsIds']['map'](_0x1c35e5=>this['editor']['plugins']['get']('Users')['getUser'](_0x1c35e5)),'fromVersion':_0x5487ee};_0x19fac2===this['currentRevision']&&(_0x1a943f['createdAt']=new Date(_0x5d42a6['createdAt']['getTime']()+0xa)),_0x19fac2['_update'](_0x1a943f,!0x0),delete _0x1a943f['authors'],_0x5a90fc['push'](_0x1a943f);}}if(this['adapter']){for(const _0x4a071b of _0x5a90fc)this['_bufferUpdate'](_0x4a071b['id'],_0x4a071b,!0x0);this['sendBufferedUpdates']();}return _0x49f692;}['addRevisionData'](_0xba6b6e){const _0x244e29=this['repository']['createRevision'](_0xba6b6e);return this['adapter']&&_0x244e29['on']('_update',(_0x79d116,_0x3940af,_0x34666b)=>{_0x34666b||(this['_bufferUpdate'](_0x3940af['id'],_0x3940af,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x244e29,this['_findInsertionIndex'](_0x244e29)),_0x244e29;}async['getRevisionDocumentData'](_0x3f1b39){return await this['_utils']['loadRevisionData'](_0x3f1b39,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x3f1b39);}async['getRevisionRootsAttributes'](_0x19c7da){return await this['_utils']['loadRevisionData'](_0x19c7da,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x19c7da);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x571e33=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x161a9b=0x0;_0x161a9b<_0x571e33['length'];_0x161a9b++){const _0x1c1856=_0x571e33[_0x161a9b];let _0x472181=!0x1;for(const _0xfbcfda of Object['keys'](_0x1c1856))void 0x0===_0x1c1856[_0xfbcfda]?delete _0x1c1856[_0xfbcfda]:'id'!==_0xfbcfda&&(_0x472181=!0x0);_0x472181||(_0x571e33[_0x161a9b]=null);}if(_0x571e33=_0x571e33['filter'](_0x3ab2c8=>null!==_0x3ab2c8),!_0x571e33['length'])return;for(let _0xc6020f=0x0;_0xc6020f<_0x571e33['length'];_0xc6020f++){const _0x4de886=_0x571e33[_0xc6020f];void 0x0!==_0x4de886['fromVersion']&&void 0x0===_0x4de886['toVersion']&&(_0x4de886['toVersion']=this['repository']['getRevision'](_0x4de886['id'])['toVersion']),void 0x0!==_0x4de886['toVersion']&&void 0x0===_0x4de886['fromVersion']&&(_0x4de886['fromVersion']=this['repository']['getRevision'](_0x4de886['id'])['fromVersion']);}const _0x238efc=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x571e33,_0x238efc)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0xbff607=>{if(_0xbff607){for(const _0x21bee0 of _0xbff607)this['setRevisionData']({'id':_0x21bee0['id'],'createdAt':_0x21bee0['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0x1a9a73=null,from:_0xe2ff77=null,to:_0x3b86e4=null}){_0xe2ff77=null!==_0xe2ff77?_0xe2ff77:_0x1a9a73['fromVersion'],_0x3b86e4=null!==_0x3b86e4?_0x3b86e4:_0x1a9a73['toVersion'];const _0x2b09d3=this['_revisionDataBuilder']['getData'](_0xe2ff77,_0x3b86e4),_0x2e304e={'diffData':_0x2b09d3['diffData'],'authorsIds':_0x2b09d3['authorsIds'],'fromVersion':_0xe2ff77,'toVersion':_0x3b86e4};if(!_0x1a9a73||_0x3b86e4!==_0x1a9a73['toVersion']){const _0x253127=_0x3b86e4-0x1,_0x297e2c=this['_source']['history']['getOperation'](_0x253127);_0x2e304e['createdAt']=_0x297e2c&&_0x297e2c['createdAt']||new Date();}if(this['_loadedStateData']&&_0xe2ff77===this['_loadedStateData']['fromVersion']){for(const _0x58c49f of this['_loadedStateData']['authors'])_0x2e304e['authorsIds']['includes'](_0x58c49f['id'])||_0x2e304e['authorsIds']['push'](_0x58c49f['id']);}return _0x2e304e;}['_bufferUpdate'](_0x4cb3ab,_0x131bbf,_0x2e9dc1){if(this['_bufferedUpdates']['has'](_0x4cb3ab)){const _0x552285=this['_bufferedUpdates']['get'](_0x4cb3ab);_0x131bbf=_0x2e9dc1?{..._0x552285,..._0x131bbf}:{..._0x131bbf,..._0x552285};}this['_bufferedUpdates']['set'](_0x4cb3ab,_0x131bbf);}['setRevisionData'](_0x43c940){const _0x526061=this['repository']['getRevision'](_0x43c940['id']);if(_0x43c940['createdAt']&&(_0x43c940['createdAt']=new Date(_0x43c940['createdAt'])),_0x43c940['authorsIds']){const _0x14872c=this['editor']['plugins']['get']('Users');_0x43c940['authors']=_0x43c940['authorsIds']['map'](_0x7f39eb=>_0x14872c['getUser'](_0x7f39eb));}_0x526061['_update'](_0x43c940,!0x0);}['_createInitialRevision'](_0x2b5824){const _0x5a4763=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x5a4763)this['_initialRevisionId']=_0x5a4763['id'];else{const _0x1ac279=!this['editor']['model']['document']['roots']['find'](_0xc0f9df=>this['editor']['model']['hasContent'](_0xc0f9df)),_0x1ab466=this['editor']['plugins']['get']('Users')['me']['id'],_0x45bc78=g(this['editor']['locale'],_0x1ac279?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x2b5824,'to':_0x2b5824,'id':this['_initialRevisionId'],'name':_0x45bc78,'creatorId':_0x1ab466});}}['_createCurrentRevision'](_0x12c3b0){const _0x609fbd=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x609fbd),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x12c3b0,'to':_0x12c3b0,'id':_0x609fbd,'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'](_0x1a05b6,_0xd90382){let _0x224bc4=this['editor']['config']['get']('initialData'),_0x4fd0cb=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x224bc4){_0x224bc4={};for(const _0x7d4b3d of this['editor']['model']['document']['getRootNames']())_0x224bc4[_0x7d4b3d]='';}if('string'==typeof _0x224bc4&&(_0x224bc4={'main':_0x224bc4}),void 0x0===_0x4fd0cb){_0x4fd0cb={};for(const _0x5623d8 of this['editor']['model']['document']['getRootNames']())_0x4fd0cb[_0x5623d8]={};}let _0x5eb3d7=!0x1;const _0x5e9a16=Object['keys'](_0x224bc4),_0x363b4d=Object['keys'](_0x1a05b6);for(const _0x5a9814 of _0x5e9a16){if(_0x224bc4[_0x5a9814]!==_0x1a05b6[_0x5a9814]&&''!==_0x224bc4[_0x5a9814]['trim']()){_0x5eb3d7=!0x0;break;}if(!_0x34eb88(_0x4fd0cb[_0x5a9814],_0xd90382[_0x5a9814])&&Object['keys'](_0x4fd0cb[_0x5a9814])['length']>0x0){_0x5eb3d7=!0x0;break;}}_0x5eb3d7||(_0x5eb3d7=_0x363b4d['some'](_0x3f51db=>!this['editor']['model']['document']['getRoot'](_0x3f51db))),_0x5eb3d7&&_0x1ce756('editor-initial-data-replaced-with-revision-data',{'editorData':_0x224bc4,'editorRootsAttributes':_0x4fd0cb,'revisionData':_0x1a05b6,'revisionRootsAttributes':_0xd90382}),this['editor']['config']['set']('initialData',_0x1a05b6),this['editor']['config']['set']('rootsAttributes',_0xd90382);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x4a4b02=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x4a4b02['add'](g(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x2e5fd0){const _0x47098f=this['repository']['getRevisions']();_0x47098f['reverse']();let _0xcb3461=0x0;for(;_0xcb3461<_0x47098f['length'];){const _0x3bdca4=_0x47098f[_0xcb3461];if(_0x3bdca4===this['currentRevision']){_0xcb3461++;continue;}if(_0x3bdca4['id']===this['_initialRevisionId'])break;const _0xaa1677=_0x2e5fd0['toVersion']-_0x3bdca4['toVersion']||_0x2e5fd0['fromVersion']-_0x3bdca4['fromVersion'];if(_0xaa1677>0x0)break;if(_0xaa1677<0x0)_0xcb3461++;else{if(!_0x2e5fd0['creator']&&_0x3bdca4['creator'])break;if(_0x3bdca4['creator']||!_0x2e5fd0['creator']){if(_0x2e5fd0['createdAt']>_0x3bdca4['createdAt'])break;_0xcb3461++;}else _0xcb3461++;}}return _0xcb3461;}['_getFromVersion'](_0x2729e1){const _0x56fc26=this['repository']['getRevisions']();_0x56fc26['reverse'](),_0x56fc26['shift']();const _0x54511c=_0x56fc26['find'](_0x1a94e9=>_0x1a94e9['toVersion']<=_0x2729e1)['toVersion'];return _0x54511c<this['_startingVersion']?this['_startingVersion']:_0x54511c;}['_makeRevision']({name:_0x46865d,from:_0x54763e,to:_0x34e5d0,creatorId:_0x32b559,id:_0x82cc8a}){const _0x2aca0c=this['buildRevisionData']({'from':_0x54763e,'to':_0x34e5d0});_0x2aca0c['name']=_0x46865d,_0x2aca0c['creatorId']=_0x32b559,_0x2aca0c['id']=_0x82cc8a;const _0x33f7f0=this['addRevisionData'](_0x2aca0c);return this['adapter']&&this['_bufferUpdate'](_0x2aca0c['id'],_0x2aca0c,!0x0),_0x33f7f0;}['_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(_0x5653a8){this['editor']=_0x5653a8,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'](_0x26a4cf){this['source']=_0x26a4cf;const _0x4c13f9=new Map(),_0x403336=new Map(),_0x4538ae=this['editor']['model']['document']['roots']['map'](_0x4f9567=>_0x4f9567['rootName']);for(const _0x40f121 of _0x4538ae){const _0x1f358a=this['editor']['model']['document']['getRoot'](_0x40f121),_0x54cd8e=N(_0x1f358a);_0x4c13f9['set'](_0x40f121,_0x54cd8e),_0x403336['set'](_0x40f121,Object['fromEntries'](_0x1f358a['getAttributes']()));}const _0x4ce532=Array['from'](this['editor']['model']['markers'])['map'](_0x51e012=>[_0x51e012['name'],_0x51e012['getRange']()]),_0x263b27=this['source']['version'];this['_saveMetaData'](_0x263b27,_0x4c13f9,_0x4ce532,_0x403336),this['_startingRevisionId']=this['_revisionId'];const _0x66c03b=new Map(),_0x44c44b=new Map();for(const _0x1ca751 of _0x4538ae){const _0x5e0914=P(_0x1ca751);_0x66c03b['set'](_0x1ca751,_0x5e0914),_0x44c44b['set'](_0x1ca751,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x66c03b,[],_0x44c44b);}['getData'](_0x38cbe0,_0x4bfbab){if(this['_lastFrom']===_0x38cbe0&&this['_lastTo']<=_0x4bfbab)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x4bfbab,!0x0);else{if(!this['_savedMetaData']['has'](_0x38cbe0)){const _0x489cda=this['_getPreviousFrom'](_0x38cbe0);this['_calculateMetaData'](_0x489cda,_0x38cbe0,!0x1);}this['_calculateMetaData'](_0x38cbe0,_0x4bfbab,!0x0);}return this['_lastFrom']=_0x38cbe0,this['_lastTo']=_0x4bfbab,this['_getState']();}['loadState'](_0x2d10a4){const _0x44ecc3=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x2d10a4['fromVersion'],this['_lastTo']=_0x2d10a4['toVersion'];for(const _0x6bd34 in _0x2d10a4['diffData']){const _0x1557bf=_0x2d10a4['diffData'][_0x6bd34]['attachChange'],_0x140515=_0x4dbdf7(_0x2d10a4['diffData'][_0x6bd34]['attributesBefore'])||{},_0x49dcba=_0x44ecc3['_makeModelFromViewString'](_0x2d10a4['diffData'][_0x6bd34]['deletions']);_0x49dcba['rootName']=_0x6bd34,_0x49dcba['_isAttached']=!_0x1557bf||!_0x1557bf['isAttached'],_0x49dcba['isAttached']=()=>_0x49dcba['_isAttached'],this['_baseRoots']['set'](_0x6bd34,_0x49dcba),this['_baseRootsAttributes']['set'](_0x6bd34,_0x140515),_0x1557bf&&this['_touchedRoots']['set'](_0x6bd34,_0x1557bf);const _0x983b5d=this['_makeIdsRoot'](_0x49dcba);this['_baseIdsRoots']['set'](_0x6bd34,_0x983b5d);for(const [_0x432e34,_0x254c05]of _0x49dcba['markers']){if(!_0x432e34['startsWith']('revision:'))continue;const _0x53a16a=_0x432e34['split'](':')[0x2];for(const _0x8174d9 of _0x254c05['getWalker']({'singleCharacters':!0x0})){const _0xa7a620=this['_getVidAttributeName'](_0x8174d9),_0x52cdf9='elementEnd'==_0x8174d9['type']?_0x8174d9['previousPosition']['path']['slice'](0x0,-0x1):_0x8174d9['previousPosition']['path'],_0x4acc31=_0x983b5d['getNodeByPath'](_0x52cdf9)['getAttribute'](_0xa7a620);this['_touched']['set'](_0x4acc31,{'userId':_0x53a16a});}}}this['_startingRevisionId']=this['_revisionId'];const _0x21f180=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x4c1a6c=>!this['_touched']['has'](_0x4c1a6c));let _0x1038fe=0x0;const _0xddfab6=new Map();for(const _0x111429 in _0x2d10a4['diffData']){const _0x26b3f6=_0x2d10a4['diffData'][_0x111429]['attachChange'],_0x2bc310=_0x4dbdf7(_0x2d10a4['diffData'][_0x111429]['attributesAfter'])||{},_0x1bb1ad=_0x44ecc3['_makeModelFromViewString'](_0x2d10a4['diffData'][_0x111429]['insertions']);_0x1bb1ad['rootName']=_0x111429,_0x1bb1ad['_isAttached']=!_0x26b3f6||_0x26b3f6['isAttached'],_0x1bb1ad['isAttached']=()=>_0x1bb1ad['_isAttached'],this['_diffRoots']['set'](_0x111429,_0x1bb1ad),this['_diffRootsAttributes']['set'](_0x111429,_0x2bc310);const _0x5117bb=this['_makeIdsRoot'](_0x1bb1ad,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x111429,_0x5117bb),_0xddfab6['set'](_0x111429,_0x1bb1ad['isAttached']()?_0x2bc310:{});for(const [_0x2a3488,_0x5e8dbd]of _0x1bb1ad['markers']){if(!_0x2a3488['startsWith']('revision:'))continue;const _0x4c418d=_0x2a3488['split'](':')[0x2];for(const _0x2dd61c of _0x5e8dbd['getWalker']({'singleCharacters':!0x0})){const _0x52038b=this['_getVidAttributeName'](_0x2dd61c),_0xe34fae=this['_revisionId']++,_0x472bfc='elementEnd'==_0x2dd61c['type']?_0x2dd61c['previousPosition']['path']['slice'](0x0,-0x1):_0x2dd61c['previousPosition']['path'];_0x5117bb['getNodeByPath'](_0x472bfc)['_setAttribute'](_0x52038b,_0xe34fae),this['_touched']['set'](_0xe34fae,{'userId':_0x4c418d});}}for(const _0x5624e9 of this['editor']['model']['createRangeIn'](_0x1bb1ad)['getWalker']({'singleCharacters':!0x0})){const _0x8589ec=this['_getVidAttributeName'](_0x5624e9),_0x5c1211='elementEnd'==_0x5624e9['type']?_0x5624e9['previousPosition']['path']['slice'](0x0,-0x1):_0x5624e9['previousPosition']['path'],_0x8d12b2=_0x5117bb['getNodeByPath'](_0x5c1211);_0x8d12b2['getAttribute'](_0x8589ec)>0x0||_0x8d12b2['_setAttribute'](_0x8589ec,_0x21f180[_0x1038fe++]);}for(const [_0x2e89ec,_0x5e1920]of _0x1bb1ad['markers'])_0x2e89ec['startsWith']('revision:')||this['_markers']['set'](_0x2e89ec,_0x5e1920);}const _0x27984b=P('$graveyard');this['_baseRoots']['set']('$graveyard',_0x27984b),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x27984b,0x1));const _0x9a01a3=P('$graveyard');this['_diffRoots']['set']('$graveyard',_0x9a01a3),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x9a01a3,0x1));const _0x390f43=Array['from'](this['_diffRoots'])['map'](([_0x4efa44,_0x180a3f])=>[_0x4efa44,N(_0x180a3f)]);this['_saveMetaData'](this['_lastTo'],_0x390f43,this['_markers'],_0xddfab6);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0x2c4b7a,_0x2c7757,_0x4b44f3,_0x2bbf1e){const _0x5a8113=new Map(_0x2c7757),_0x5a6c4a=new Map(_0x4dbdf7(_0x2bbf1e)),_0x450dd5=new Map();for(const [_0x2da8b0,_0xa0fad1]of _0x4b44f3)_0x450dd5['set'](_0x2da8b0,{'start':_0xa0fad1['start']['clone'](),'end':_0xa0fad1['end']['clone'](),'rootName':_0xa0fad1['root']['rootName']});this['_savedMetaData']['set'](_0x2c4b7a,{'roots':_0x5a8113,'markers':_0x450dd5,'rootsAttributes':_0x5a6c4a});}['_removeMetaData'](_0x5a4b8e){this['_savedMetaData']['delete'](_0x5a4b8e);}['_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'](_0x69388d,_0x14bf0b=null){let _0x2390cc=null;_0x69388d['is']('documentFragment')||(_0x2390cc=new ut(_0x69388d['name'],{'vid_start':null===_0x14bf0b?this['_revisionId']++:_0x14bf0b++}));const _0x26d4ee=[];for(const _0x442fa9 of _0x69388d['getChildren']())if(_0x442fa9['is']('element')){_0x26d4ee['push'](this['_makeIdsRoot'](_0x442fa9,_0x14bf0b));const _0x25d590=_0x26d4ee[_0x26d4ee['length']-0x1];null!==_0x14bf0b&&(_0x14bf0b=_0x25d590['is']('element','$text')?_0x25d590['getAttribute']('vid')+0x1:_0x25d590['getAttribute']('vid_end')+0x1);}else{for(let _0x1a71f8=0x0;_0x1a71f8<_0x442fa9['offsetSize'];_0x1a71f8++)_0x26d4ee['push'](new ut('$text',{'vid':null===_0x14bf0b?this['_revisionId']++:_0x14bf0b++}));}if(_0x69388d['is']('documentFragment')){const _0x50571c=P(_0x69388d['rootName']);return _0x50571c['_insertChild'](0x0,_0x26d4ee),_0x50571c;}return _0x2390cc['_setAttribute']('vid_end',null===_0x14bf0b?this['_revisionId']++:_0x14bf0b++),_0x2390cc['_insertChild'](0x0,_0x26d4ee),_0x2390cc;}['_calculateMetaData'](_0x1e1d6d,_0x102dec,_0x1c8daf){this['_reset']();const {roots:_0x439cf8,markers:_0x42d876,rootsAttributes:_0x374978}=this['_savedMetaData']['get'](_0x1e1d6d);this['_baseRoots']=new Map(_0x439cf8),this['_baseRootsAttributes']=new Map(_0x4dbdf7(_0x374978));for(const [_0x2a89fa,_0x193981]of this['_baseRoots'])if('$graveyard'!==_0x2a89fa&&(this['_diffRoots']['set'](_0x2a89fa,N(_0x193981)),this['_diffRootsAttributes']=new Map(_0x4dbdf7(_0x374978)),_0x1c8daf)){const _0x4a59f4=this['_revisionId'];this['_idsRoots']['set'](_0x2a89fa,this['_makeIdsRoot'](_0x193981)),this['_baseIdsRoots']['set'](_0x2a89fa,this['_makeIdsRoot'](_0x193981,_0x4a59f4));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',N(this['_baseRoots']['get']('$graveyard'))),_0x1c8daf&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x4523f8,_0x3c7d6f]of _0x42d876){const _0x533080=this['_baseRoots']['get'](_0x3c7d6f['rootName']),_0x4a7f2f=this['_diffRoots']['get'](_0x3c7d6f['rootName']),_0x2d14c5=new lt(this['_fixPosition'](_0x3c7d6f['start'],_0x533080),this['_fixPosition'](_0x3c7d6f['end'],_0x533080)),_0x33122d=this['_fixRange'](_0x2d14c5,_0x4a7f2f);_0x533080['markers']['set'](_0x4523f8,_0x2d14c5),this['_markers']['set'](_0x4523f8,_0x33122d);}this['_applyOperations'](_0x1e1d6d,_0x102dec,_0x1c8daf);}['_applyOperations'](_0xe4dd24,_0x2d2927,_0x370f58){for(const _0x15d6bb of this['source']['getOperations'](_0xe4dd24,_0x2d2927))this['_handleOperation'](_0x15d6bb,_0x370f58);for(const _0x1c2a1c of this['_diffRoots']['values']())_0x1c2a1c['markers']['clear']();for(const [_0x583075,_0x179398]of this['_markers']){this['_diffRoots']['get'](_0x179398['root']['rootName'])['markers']['set'](_0x583075,_0x179398['clone']());}const _0x3ab8f9=new Map(),_0xa18032=new Map();for(const [_0x4e7f73,_0x3e585e]of this['_diffRoots'])_0x3ab8f9['set'](_0x4e7f73,N(_0x3e585e)),_0xa18032['set'](_0x4e7f73,this['_diffRootsAttributes']['get'](_0x4e7f73));this['_saveMetaData'](_0x2d2927,_0x3ab8f9,this['_markers'],_0xa18032);}['_getPreviousFrom'](_0x223d61){const _0x14469e=Array['from'](this['_savedMetaData']['keys']());_0x14469e['sort']((_0x1924ab,_0x3a2e3e)=>_0x1924ab-_0x3a2e3e),_0x14469e['reverse']();for(const _0x3de411 of _0x14469e)if(_0x3de411<_0x223d61)return _0x3de411;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x3c8405,_0x1a5be2){const _0x3d17a8=Array['from'](_0x1a5be2['markers'])['map'](([_0x5bb5c1,_0x4cefc5])=>[_0x5bb5c1,this['_fixRange'](_0x4cefc5,_0x3c8405)]);_0x3c8405['markers']=new Map(_0x3d17a8);}['_transformMarkers'](_0x242078){for(const _0x1eff58 of this['_markers']['values']()){const _0x16b752=_0x1eff58['getTransformedByOperation'](_0x242078),_0x46b588=lt['_createFromRanges'](_0x16b752);_0x1eff58['start']=_0x46b588['start'],_0x1eff58['end']=_0x46b588['end'];}}['_handleOperation'](_0x2e4d59,_0xf396fc){if('addRoot'!=_0x2e4d59['type']&&'detachRoot'!=_0x2e4d59['type']){if('insert'==_0x2e4d59['type']){const _0x1e9ff8=_0x2e4d59['position']['root']['rootName'];this['_diffRoots']['has'](_0x1e9ff8)||(this['_diffRoots']['set'](_0x1e9ff8,P(_0x1e9ff8,!0x0)),this['_diffRootsAttributes']['set'](_0x1e9ff8,{}),_0xf396fc&&this['_idsRoots']['set'](_0x1e9ff8,P(_0x1e9ff8,!0x0)));}else{if('addRootAttribute'==_0x2e4d59['type']||'removeRootAttribute'==_0x2e4d59['type']||'changeRootAttribute'==_0x2e4d59['type'])return void this['_handleRootAttributeOperation'](_0x2e4d59);'marker'==_0x2e4d59['type']&&this['_handleMarkerOperation'](_0x2e4d59);}if('marker'!==_0x2e4d59['type']){const _0x2ca857=this['_cloneOperation'](_0x2e4d59,this['_diffRoots']);_0x2ca857['_execute'](),this['_transformMarkers'](_0x2ca857);}if(_0xf396fc)switch(_0x2e4d59['type']){case'insert':this['_handleInsertOperation'](_0x2e4d59);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x2e4d59);break;case'merge':this['_handleMergeOperation'](_0x2e4d59);break;case'split':this['_handleSplitOperation'](_0x2e4d59);}}else this['_handleRootOperation'](_0x2e4d59,_0xf396fc);}['_cloneOperation'](_0x2c2758,_0x30105c){const _0x4d40a0=_0x2c2758['clone']();return _0x4d40a0['_authorId']=_0x2c2758['_authorId'],this['_fixOperation'](_0x4d40a0,_0x30105c),_0x4d40a0;}['_getBaseVids'](_0x3c1275){return _0x3c1275['map'](_0x58f6d2=>{const _0x5be85f=this['_getVidAttributeName'](_0x58f6d2);return Number(_0x58f6d2['item']['getAttribute'](_0x5be85f));});}['_generateTape'](_0x1b1d88,_0x51a594){if(_0x1b1d88['is']('element','$text'))_0x51a594['push']({'item':_0x1b1d88,'type':'text'});else{_0x1b1d88['is']('element')&&_0x51a594['push']({'item':_0x1b1d88,'type':'elementStart'});for(const _0x4163d9 of _0x1b1d88['getChildren']())this['_generateTape'](_0x4163d9,_0x51a594);_0x1b1d88['is']('element')&&_0x51a594['push']({'item':_0x1b1d88,'type':'elementEnd'});}return _0x51a594;}['_getState'](){const _0xddfe9=new Map(this['_touched']),_0x4afb99=new Map(_0xddfe9),_0x23d4d3=new Map(),_0x5dedc6={'insertions':{},'deletions':{}},_0xa70b4d={'insertions':{},'deletions':{}},_0x3ff9ca=new Map(),_0x215f41=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x215f41['delete']('$graveyard');for(const _0x4b188b of _0x215f41){const _0x44b4cd=this['_diffRoots']['get'](_0x4b188b)||P(_0x4b188b,!0x1),_0x114c6f=this['_baseRoots']['get'](_0x4b188b)||P(_0x4b188b,!0x1);_0x44b4cd['isAttached']()||_0x114c6f['isAttached']()?(_0x5dedc6['insertions'][_0x4b188b]=N(_0x44b4cd),_0x5dedc6['deletions'][_0x4b188b]=N(_0x114c6f),this['_copyMarkers'](_0x5dedc6['deletions'][_0x4b188b],_0x114c6f),this['_copyMarkers'](_0x5dedc6['insertions'][_0x4b188b],_0x44b4cd),_0xa70b4d['insertions'][_0x4b188b]=this['_generateTape'](this['_idsRoots']['get'](_0x4b188b),[]),_0xa70b4d['deletions'][_0x4b188b]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x4b188b)||P(_0x4b188b,!0x1),[])):_0x215f41['delete'](_0x4b188b);}for(const _0x5beb83 of _0x215f41){const _0x39972d=_0xa70b4d['insertions'][_0x5beb83];for(const _0x5e83eb of _0x39972d){const _0x37e245=this['_getVidAttributeName'](_0x5e83eb),_0x173415=_0x5e83eb['item']['getAttribute'](_0x37e245);_0x4afb99['delete'](_0x173415),_0x173415>=this['_startingRevisionId']&&_0x23d4d3['set'](_0x173415,_0xddfe9['get'](_0x173415));}}for(const _0x21c92b of _0x215f41){const _0x5d5889=_0xa70b4d['insertions'][_0x21c92b],_0x24d100=this['_getBaseVids'](_0xa70b4d['deletions'][_0x21c92b]);let _0x5c2a37=0x0;for(const _0xde9da3 of _0x5d5889){const _0x5f4517=this['_getVidAttributeName'](_0xde9da3),_0x1cc644=_0xde9da3['item']['getAttribute'](_0x5f4517);if(!_0x23d4d3['has'](_0x1cc644)&&!_0x3ff9ca['has'](_0x1cc644)){if(_0x4afb99['has'](_0x1cc644))_0x5c2a37++;else{if(_0x1cc644!=_0x24d100[_0x5c2a37]){const _0x3bff7e=_0xddfe9['get'](_0x1cc644)||_0xddfe9['get'](_0x24d100[_0x5c2a37]);for(;_0x1cc644!=_0x24d100[_0x5c2a37];)_0x4afb99['has'](_0x24d100[_0x5c2a37])||(_0x3ff9ca['set'](_0x24d100[_0x5c2a37],_0x3bff7e),_0xddfe9['set'](_0x24d100[_0x5c2a37],_0x3bff7e)),_0x5c2a37++;}_0x5c2a37++;}}}}for(const _0x5100e9 of _0x215f41){const _0x185b67=_0xa70b4d['insertions'][_0x5100e9];for(const _0x496efc of _0x185b67){const _0x4111cc=this['_getVidAttributeName'](_0x496efc),_0x17e009=_0x496efc['item']['getAttribute'](_0x4111cc);if(_0x3ff9ca['has'](_0x17e009)){const _0x33afed=_0x3ff9ca['get'](_0x17e009);_0x4afb99['has'](_0x17e009)||_0x4afb99['set'](_0x17e009,{..._0x33afed}),_0x23d4d3['set'](_0x17e009,{..._0x33afed});}}}for(const _0x9e12a7 of _0x4afb99['keys']())_0x9e12a7>=this['_startingRevisionId']&&_0x4afb99['delete'](_0x9e12a7);const _0xd5d1b9=new Map();for(const _0x458fb4 of _0x215f41){let _0x2c977d=_0xa70b4d['insertions'][_0x458fb4];for(const _0x10a18d of _0x2c977d)if(_0x10a18d['item']['is']('element','tableCell')){const _0x54acbe=this['_getVidAttributeName'](_0x10a18d),_0x1a7642=_0x10a18d['item']['getAttribute'](_0x54acbe);if(_0x23d4d3['has'](_0x1a7642)){const _0x107e44=_0x10a18d['item']['parent']['parent']['getAttribute']('vid_start'),_0x10b21b=_0xd5d1b9['get'](_0x107e44)||new Set();_0x10b21b['add'](_0x23d4d3['get'](_0x1a7642)['userId']),_0xd5d1b9['set'](_0x107e44,_0x10b21b);}}_0x2c977d=_0xa70b4d['deletions'][_0x458fb4];for(const _0x2213d3 of _0x2c977d)if(_0x2213d3['item']['is']('element','tableCell')){const _0xf3ad91=this['_getVidAttributeName'](_0x2213d3),_0x4a8861=_0x2213d3['item']['getAttribute'](_0xf3ad91);if(_0x4afb99['has'](_0x4a8861)){const _0x56aaab=_0x2213d3['item']['parent']['parent']['getAttribute']('vid_start'),_0x1e2f48=_0xd5d1b9['get'](_0x56aaab)||new Set();_0x1e2f48['add'](_0x4afb99['get'](_0x4a8861)['userId']),_0xd5d1b9['set'](_0x56aaab,_0x1e2f48);}}for(const _0x1c2e1f of _0xd5d1b9['keys']())(_0x23d4d3['has'](_0x1c2e1f)||_0x4afb99['has'](_0x1c2e1f))&&_0xd5d1b9['delete'](_0x1c2e1f);}for(const _0xdadc1e of _0x215f41){const _0x3fe539=_0xa70b4d['insertions'][_0xdadc1e];let _0x5a5901=null,_0x20b3b2=null;for(const _0xe9440e of _0x3fe539){const _0x86d234=this['_getVidAttributeName'](_0xe9440e),_0x29ae11=_0xe9440e['item']['getAttribute'](_0x86d234),_0x40dda2=_0xd5d1b9['get'](_0x29ae11);_0x40dda2&&'elementStart'==_0xe9440e['type']&&(_0x5a5901=Array['from'](_0x40dda2)[0x0],_0x20b3b2=_0xe9440e['item']['getAttribute']('vid_end')),_0x5a5901&&(_0x4afb99['set'](_0x29ae11,{'userId':_0x5a5901}),_0x23d4d3['set'](_0x29ae11,{'userId':_0x5a5901})),_0x29ae11==_0x20b3b2&&(_0x5a5901=null,_0x20b3b2=null);}}const _0x182f60={},_0x4bab10=new Set();for(const _0x551f2a of _0x215f41){const _0x51fe5a=_0x5dedc6['deletions'][_0x551f2a],_0x3eb17e=_0x5dedc6['insertions'][_0x551f2a];for(const {userId:_0x43e839}of this['_touchedMarkers']['values']())null!==_0x43e839&&_0x4bab10['add'](_0x43e839);for(const {userId:_0x557537}of this['_touchedRoots']['values']())null!==_0x557537&&_0x4bab10['add'](_0x557537);this['_markChanges'](_0x3eb17e,_0xa70b4d['insertions'][_0x551f2a],_0x23d4d3,'insertion',_0x4bab10),this['_markChanges'](_0x51fe5a,_0xa70b4d['deletions'][_0x551f2a],_0x4afb99,'deletion',_0x4bab10),_0x182f60[_0x551f2a]={'insertions':this['_prepareViewToSave'](_0x3eb17e),'deletions':this['_prepareViewToSave'](_0x51fe5a),'attachChange':this['_touchedRoots']['get'](_0x551f2a)||null,'attributesBefore':_0x4dbdf7(this['_baseRootsAttributes']['get'](_0x551f2a))||{},'attributesAfter':_0x4dbdf7(this['_diffRootsAttributes']['get'](_0x551f2a))};}return{'diffData':_0x182f60,'authorsIds':Array['from'](_0x4bab10)};}['_processRootBeforeSave'](_0x17eafc){for(const [,_0x29eb1e]of _0x17eafc['markers']){const _0x4029ed=_0x29eb1e['start']['getAncestors']()['filter'](_0x5b68cf=>'tableCell'==_0x5b68cf['name']);for(const _0x3d5302 of _0x4029ed)0x1==_0x3d5302['childCount']&&_0x3d5302['getChild'](0x0)['is']('element','paragraph')&&_0x3d5302['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x15dfe3){this['_processRootBeforeSave'](_0x15dfe3);const _0x26136e=this['editor']['data']['toView'](_0x15dfe3,{}),_0x201954=Array['from'](_0x26136e['getChildren']())['map'](_0x3d7b77=>this['_getViewJson'](_0x3d7b77));return JSON['stringify'](_0x201954);}['_getViewJson'](_0x8c7317){if(_0x8c7317['is']('$text'))return _0x8c7317['data'];{const _0x50c592=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0xcac413=_0x8c7317,_0x120db5=this['editor']['data']['htmlProcessor']['domConverter'],_0x3788b3={'type':_0x50c592['_getTypeCharForViewElement'](_0xcac413),'name':_0xcac413['name'],'attributes':Array['from'](_0xcac413['getAttributes']()),'children':Array['from'](_0xcac413['getChildren']())['map'](_0x4500d6=>this['_getViewJson'](_0x4500d6))};if(_0x8c7317['is']('uiElement')&&'$comment'!=_0x8c7317['name']){const _0x1ca64c=_0x8c7317['render'](_0x120db5['domDocument'],_0x120db5);_0x3788b3['children']['push'](_0x1ca64c['outerHTML']);}else{if(_0x8c7317['is']('rawElement')){const _0x355bb2=_0x120db5['domDocument']['createElement'](_0xcac413['name']);_0x8c7317['render'](_0x355bb2,_0x120db5),_0x3788b3['children']['push'](_0x355bb2['innerHTML']);}}const _0x3c6a76=Array['from'](_0xcac413['getCustomProperties']());_0x3c6a76['length']>0x0&&(_0x3788b3['customProperties']=_0x3c6a76);const _0x1cd290=_0xcac413['getFillerOffset']();return null!==_0x1cd290&&(_0x3788b3['fillerOffset']=_0x1cd290),_0x3788b3;}}['_markChanges'](_0xc4e8f0,_0x559001,_0x34a88c,_0x4a4ff9,_0x2dd39d){let _0x1870e2=null,_0x128f28=null,_0x311156=0x0;const _0xe81e7c=this['editor']['model'];for(let _0x5c02b3=0x0;_0x5c02b3<_0x559001['length'];_0x5c02b3++){const _0x1e929c=this['_getVidAttributeName'](_0x559001[_0x5c02b3]),_0x13edc7=_0x559001[_0x5c02b3]['item']['getAttribute'](_0x1e929c),_0x5157dd=_0x34a88c['get'](_0x13edc7),_0x4c429a=_0x5c02b3==_0x559001['length']-0x1;(!_0x1870e2&&_0x5157dd&&(_0x1870e2=_0x5157dd,_0x128f28=_0x559001[_0x5c02b3]),_0x1870e2&&(!_0x5157dd||_0x5157dd['userId']!=_0x1870e2['userId']))&&(_0x3f48ec(_0x5157dd,F(_0x128f28,_0xc4e8f0,_0xe81e7c),F(_0x559001[_0x5c02b3],_0xc4e8f0,_0xe81e7c)),_0x1870e2=_0x5157dd||null,_0x128f28=_0x5157dd?_0x559001[_0x5c02b3]:null),_0x1870e2&&_0x4c429a&&_0x3f48ec(_0x5157dd,F(_0x128f28,_0xc4e8f0,_0xe81e7c),B(_0x559001[_0x5c02b3],_0xc4e8f0,_0xe81e7c));}function _0x3f48ec(_0x20b5f6,_0x2ab743,_0x4ff7f3){const _0x38a745=_0x1870e2['userId'],_0x474711='revision:'+_0x4a4ff9+':'+_0x38a745+':'+_0x311156++,_0x34f149=_0xe81e7c['createRange'](_0x2ab743,_0x4ff7f3);_0xc4e8f0['markers']['set'](_0x474711,_0x34f149),null!==_0x38a745&&_0x2dd39d['add'](_0x38a745);}}['_getVidAttributeName'](_0x517dff){switch(_0x517dff['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x5b7a0d,_0x14025c){_0x5b7a0d['baseVersion']=null;for(const _0x4e8f7e in _0x5b7a0d){const _0x5dfd50=_0x5b7a0d[_0x4e8f7e];if(_0x5dfd50 instanceof ft){const _0x5b7fa3=_0x14025c['get'](_0x5dfd50['root']['rootName']);_0x5b7a0d[_0x4e8f7e]=this['_fixPosition'](_0x5dfd50,_0x5b7fa3);}if(_0x5dfd50 instanceof lt){const _0xc8b292=_0x14025c['get'](_0x5dfd50['root']['rootName']);_0x5b7a0d[_0x4e8f7e]=this['_fixRange'](_0x5dfd50,_0xc8b292);}'root'===_0x4e8f7e&&(_0x5b7a0d['root']=_0x14025c['get'](_0x5b7a0d['root']['rootName']));}}['_fixRange'](_0x231f71,_0x3e3490){return this['editor']['model']['createRange'](this['_fixPosition'](_0x231f71['start'],_0x3e3490),this['_fixPosition'](_0x231f71['end'],_0x3e3490));}['_fixPosition'](_0xfe1bbf,_0x596575){return this['editor']['model']['createPositionFromPath'](_0x596575,_0xfe1bbf['path'],_0xfe1bbf['stickiness']);}['_handleInsertOperation'](_0x1539a6){const _0x3005e4=this['_idsRoots']['get'](_0x1539a6['position']['root']['rootName']),_0x5219c3=this['_fixPosition'](_0x1539a6['position'],_0x3005e4),_0x156c92=null===_0x1539a6['_authorId']?null:_0x1539a6['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x278425=_0x5219c3['parent'],_0x1b6410=this['_revisionId'],_0x1e16fe=[];for(const _0x5561f8 of _0x1539a6['nodes'])if(_0x5561f8['is']('element'))_0x1e16fe['push'](this['_makeIdsRoot'](_0x5561f8));else{for(let _0x4fa79d=0x0;_0x4fa79d<_0x5561f8['offsetSize'];_0x4fa79d++)_0x1e16fe['push'](new ut('$text',{'vid':this['_revisionId']++}));}const _0x1b55a7=this['_revisionId'];for(let _0x3be454=_0x1b6410;_0x3be454<_0x1b55a7;_0x3be454++)this['_touched']['set'](_0x3be454,{'userId':_0x156c92});_0x278425['_insertChild'](_0x5219c3['offset'],_0x1e16fe);}['_handleMoveOperation'](_0x976d5){(_0x976d5=this['_cloneOperation'](_0x976d5,this['_idsRoots']))['_execute']();const _0x3e1049=null===_0x976d5['_authorId']?null:_0x976d5['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x26940e=_0x976d5['getMovedRangeStart'](),_0x4e726a=_0x26940e['parent'],_0x100af6=_0x26940e['offset'];!function _0x5978a2(_0x199335,_0x5573bd,_0xd72624,_0x1e210f){for(let _0x252ee5=_0xd72624;_0x252ee5<_0x1e210f;_0x252ee5++){const _0x3f240e=_0x5573bd['getChild'](_0x252ee5);_0x3f240e['is']('element','$text')?_0x199335['set'](_0x3f240e['getAttribute']('vid'),{'userId':_0x3e1049}):(_0x199335['set'](_0x3f240e['getAttribute']('vid_start'),{'userId':_0x3e1049}),_0x5978a2(_0x199335,_0x3f240e,0x0,_0x3f240e['childCount']),_0x199335['set'](_0x3f240e['getAttribute']('vid_end'),{'userId':_0x3e1049}));}}(this['_touched'],_0x4e726a,_0x100af6,_0x100af6+_0x976d5['howMany']);}['_handleMergeOperation'](_0x1f7638){const _0x84cae=null===(_0x1f7638=this['_cloneOperation'](_0x1f7638,this['_idsRoots']))['_authorId']?null:_0x1f7638['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x5868e8=_0x1f7638['targetPosition']['parent'],_0x105bb2=_0x1f7638['sourcePosition']['parent'],_0x57723d=_0x5868e8['getAttribute']('vid_end'),_0x3e5a4d=_0x105bb2['getAttribute']('vid_start');_0x5868e8['_setAttribute']('vid_end',_0x105bb2['getAttribute']('vid_end')),_0x105bb2['_setAttribute']('vid_end',_0x57723d),this['_touched']['set'](_0x3e5a4d,{'userId':_0x84cae}),this['_touched']['set'](_0x57723d,{'userId':_0x84cae}),_0x1f7638['_execute']();}['_handleSplitOperation'](_0xb10788){const _0x55b329=null===(_0xb10788=this['_cloneOperation'](_0xb10788,this['_idsRoots']))['_authorId']?null:_0xb10788['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x3e15c4=_0xb10788['graveyardPosition'],_0x14b54b=_0xb10788['splitPosition']['parent'];_0xb10788['_execute']();const _0x184f1e=_0x14b54b['getAttribute']('vid_end'),_0x3173db=_0xb10788['insertionPosition']['nodeAfter'];if(_0x3e15c4){const _0x46f064=_0x3173db['getAttribute']('vid_end'),_0x18a8f7=_0x14b54b['getAttribute']('vid_end');_0x14b54b['_setAttribute']('vid_end',_0x46f064),_0x3173db['_setAttribute']('vid_end',_0x18a8f7),this['_touched']['set'](_0x14b54b['getAttribute']('vid_end'),{'userId':_0x55b329}),this['_touched']['set'](_0x3173db['getAttribute']('vid_start'),{'userId':_0x55b329});}else{const _0x45806d=this['_revisionId']++,_0x1c2b73=this['_revisionId']++;_0x14b54b['_setAttribute']('vid_end',_0x45806d),_0x3173db['_setAttribute']('vid_start',_0x1c2b73),_0x3173db['_setAttribute']('vid_end',_0x184f1e),this['_touched']['set'](_0x45806d,{'userId':_0x55b329}),this['_touched']['set'](_0x1c2b73,{'userId':_0x55b329});}}['_handleMarkerOperation'](_0x5f3e7c){if(!_0x5f3e7c['affectsData'])return;const _0x27f898=(_0x5f3e7c=this['_cloneOperation'](_0x5f3e7c,this['_diffRoots']))['oldRange']?_0x5f3e7c['oldRange']['root']:null,_0x571032=_0x5f3e7c['newRange']?_0x5f3e7c['newRange']['root']:null;_0x27f898&&this['_markers']['delete'](_0x5f3e7c['name']),_0x571032&&this['_markers']['set'](_0x5f3e7c['name'],_0x5f3e7c['newRange']['clone']());const _0x580246=null===_0x5f3e7c['_authorId']?null:_0x5f3e7c['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x3d14fb=_0x5f3e7c['name'];if(!this['_touchedMarkers']['has'](_0x3d14fb))return void this['_touchedMarkers']['set'](_0x3d14fb,{'range':_0x5f3e7c['oldRange'],'userId':_0x580246});const _0x1a71d3=this['_touchedMarkers']['get'](_0x3d14fb),_0x330886=_0x1a71d3['range'],_0x41174a=_0x5f3e7c['newRange'];null==_0x330886&&null==_0x41174a||_0x330886&&_0x41174a&&_0x330886['isEqual'](_0x41174a)?this['_touchedMarkers']['delete'](_0x5f3e7c['name']):_0x1a71d3['userId']=_0x580246;}['_handleRootOperation'](_0x3ce6e7,_0x22dc84){this['_diffRoots']['has'](_0x3ce6e7['rootName'])?this['_diffRoots']['get'](_0x3ce6e7['rootName'])['_isAttached']=_0x3ce6e7['isAdd']:(this['_diffRoots']['set'](_0x3ce6e7['rootName'],P(_0x3ce6e7['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x3ce6e7['rootName'],{}),_0x22dc84&&this['_idsRoots']['set'](_0x3ce6e7['rootName'],P(_0x3ce6e7['rootName'],!0x0)));const _0x308527=null===_0x3ce6e7['_authorId']?null:_0x3ce6e7['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x33e8cd=this['_touchedRoots']['get'](_0x3ce6e7['rootName']);_0x33e8cd&&_0x33e8cd['userId']===_0x308527?this['_touchedRoots']['delete'](_0x3ce6e7['rootName']):this['_touchedRoots']['set'](_0x3ce6e7['rootName'],{'userId':_0x308527,'isAttached':_0x3ce6e7['isAdd']});}['_handleRootAttributeOperation'](_0x2d3a28){const _0x448f4a=this['_diffRootsAttributes']['get'](_0x2d3a28['root']['rootName']);null===_0x2d3a28['newValue']?delete _0x448f4a[_0x2d3a28['key']]:_0x448f4a[_0x2d3a28['key']]=_0x2d3a28['newValue'];}}function N(_0x1a8492){const _0x2bc094=P(_0x1a8492['rootName'],_0x1a8492['isAttached']());for(const _0x180443 of _0x1a8492['getChildren']()){const _0x3012a6=_0x180443['_clone'](!0x0);_0x2bc094['_appendChild'](_0x3012a6);}return _0x2bc094;}function P(_0x541280,_0x437151=!0x0){const _0x18e972=new vt();return _0x18e972['rootName']=_0x541280,_0x18e972['_isAttached']=_0x437151,_0x18e972['isAttached']=()=>_0x18e972['_isAttached'],_0x18e972;}function F(_0x51d27e,_0x5182ef,_0x3fb1a3){const _0x3595c4='elementEnd'==_0x51d27e['type']?_0x3fb1a3['createPositionAt'](_0x51d27e['item'],'end'):_0x3fb1a3['createPositionBefore'](_0x51d27e['item']);return _0x3fb1a3['createPositionFromPath'](_0x5182ef,_0x3595c4['path'],_0x3595c4['stickiness']);}function B(_0x5a22dd,_0xceae7d,_0x1b9d28){const _0x4db432='elementStart'==_0x5a22dd['type']?_0x1b9d28['createPositionAt'](_0x5a22dd['item'],0x0):_0x1b9d28['createPositionAfter'](_0x5a22dd['item']);return _0x1b9d28['createPositionFromPath'](_0xceae7d,_0x4db432['path'],_0x4db432['stickiness']);}class hs extends ts{['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x17fd52,_0x47829f){super(_0x17fd52),this['focusTracker']=new _0x12b377(),this['keystrokes']=new _0x10ecca(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x47829f),this['setTemplate']({'tag':'form','attributes':{'class':['ck','ck-revision-history-save-revision-form','ck-responsive-form'],'tabindex':'-1'},'children':[this['revisionNameInputView']]}),_0x47db8c(this);}['render'](){super['render'](),_0x3b4acf({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0xacd8e=_0x631862=>_0x631862['stopPropagation']();this['keystrokes']['set']('arrowright',_0xacd8e),this['keystrokes']['set']('arrowleft',_0xacd8e),this['keystrokes']['set']('arrowup',_0xacd8e),this['keystrokes']['set']('arrowdown',_0xacd8e);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x43eeb3){this['revisionNameInputView']['fieldView']['element']['value']=_0x43eeb3['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x14a17c){const _0x48941e=new _0x21d0c2(this['locale'],_0x1a6c7a),_0x51bd60=_0x48941e['fieldView'];_0x51bd60['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x32b13f=g(this['locale'],'Name\x20of\x20the\x20revision');return!_0x14a17c&&(_0x32b13f+='\x20('+g(this['locale'],'optional')+')'),(_0x48941e['label']=_0x32b13f,_0x51bd60['on']('input',()=>{this['revisionNameInputValue']=_0x51bd60['element']['value']['trim']();}),_0x48941e);}}class f extends _0x1aaf30{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u];}['_saveRevisionFormView'];['init'](){const _0x39936e=this['editor'],_0x4846e8=_0x39936e['plugins']['get']('RevisionTracker');_0x39936e['ui']['componentFactory']['add']('revisionHistory',_0xdb2876=>{const _0x3d7b0f=_0x3baa9b(_0xdb2876),_0x4381cd=_0x3d7b0f['panelView']['children'],_0x703d16=new _0xaeeef7(_0xdb2876),_0x4cfaa5=new _0x250e3b(_0xdb2876),_0x168c6d=new te(_0xdb2876),_0x4d90a4=new _0x250e3b(_0xdb2876),_0x508894=new te(_0xdb2876);return _0x3d7b0f['bind']('isEnabled')['to'](_0x4846e8,'isReady',_0x4846e8,'isEnabled',_0x39936e,'isReadOnly',(_0x56e041,_0x5e9d37,_0x41de19)=>_0x56e041&&_0x5e9d37&&!_0x41de19),_0x3d7b0f['buttonView']['set']({'icon':_0x2aae82,'label':g(_0xdb2876,'Revision\x20history'),'tooltip':!0x0}),_0x168c6d['set']({'label':g(_0xdb2876,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x168c6d['bind']('isEnabled')['to'](_0x4846e8,'isReady',_0x4846e8,'isEnabled',_0x39936e,'isReadOnly',(_0x3ccf8f,_0x136925,_0x5f4154)=>_0x3ccf8f&&_0x136925&&!_0x5f4154),_0x168c6d['on']('execute',()=>this['_showDialog']()),_0x508894['set']({'label':g(_0xdb2876,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x508894['bind']('isEnabled')['to'](_0x4846e8,'isReady',_0x39936e,'isReadOnly',(_0xb14346,_0x5d0379)=>_0xb14346&&!_0x5d0379),_0x508894['on']('execute',()=>{_0x39936e['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x3d7b0f['isOpen']=!0x1,_0x39936e['editing']['view']['focus']();}),_0x4cfaa5['children']['add'](_0x168c6d),_0x4d90a4['children']['add'](_0x508894),_0x703d16['role']='menu',_0x703d16['items']['addMany']([_0x4cfaa5,_0x4d90a4]),_0x4381cd['add'](_0x703d16),_0x3d7b0f;}),_0x39936e['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x57ef31=this['editor'],_0x20e8b2=_0x57ef31['locale'],_0x156bec=new _0x471360(_0x20e8b2),_0x2cad10=new _0x118393(_0x20e8b2);_0x156bec['buttonView']['set']({'icon':_0x2aae82,'label':g(_0x20e8b2,'Revision\x20history')});const _0x25933d=new _0x47d63b(_0x20e8b2,_0x156bec),_0x15c6b3=new _0x53ffb1(_0x20e8b2);_0x15c6b3['set']({'label':g(_0x20e8b2,'Save\x20current\x20revision')}),_0x15c6b3['delegate']('execute')['to'](_0x156bec),_0x15c6b3['on']('execute',()=>{this['_showDialog']();}),_0x25933d['children']['add'](_0x15c6b3),_0x2cad10['items']['add'](_0x25933d);const _0xdd2470=new _0x47d63b(_0x20e8b2,_0x156bec),_0x4bce90=new _0x53ffb1(_0x20e8b2);return _0x4bce90['set']({'label':g(_0x20e8b2,'Open\x20revision\x20history')}),_0x4bce90['delegate']('execute')['to'](_0x156bec),_0x4bce90['on']('execute',()=>{_0x57ef31['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0xdd2470['children']['add'](_0x4bce90),_0x2cad10['items']['add'](_0xdd2470),_0x156bec['panelView']['children']['add'](_0x2cad10),_0x156bec;}['_showDialog'](){const _0x2c688d=this['editor'],_0x505b7b=_0x2c688d['locale'],_0x3222bc=_0x2c688d['plugins']['get']('Dialog'),_0x54a382=_0x2c688d['plugins']['get']('RevisionTracker');function _0x9354ef(_0x3e8354){_0x2c688d['config']['get']('revisionHistory.requireRevisionName')&&''===_0x3e8354['revisionName']?_0x3e8354['revisionNameInputView']['errorText']=g(_0x505b7b,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x2c688d['plugins']['get'](u)['saveRevision']({'name':_0x3e8354['revisionName']}),_0x3222bc['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x9354ef(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x3222bc['show']({'id':'revisionSave','title':g(_0x505b7b,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':g(_0x2c688d['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x3222bc['hide']()},{'label':g(_0x2c688d['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x3743d3){_0x3743d3['bind']('isEnabled')['to'](_0x54a382,'isReady',_0x54a382,'isEnabled',_0x2c688d,'isReadOnly',(_0x263cf6,_0x29f129,_0x1beb9c)=>_0x263cf6&&_0x29f129&&!_0x1beb9c);},'onExecute':()=>_0x9354ef(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x161527=this['editor'],_0x309f14=_0x161527['locale'];this['_saveRevisionFormView']=new hs(_0x309f14,_0x161527['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class Q extends ts{['changeId'];['_model'];constructor(_0x46478f,_0x270f6d){super(_0x46478f),this['_model']=_0x270f6d,this['changeId']=_0x270f6d['id'];const _0x29deaf=this['bindTemplate'],_0x52eeb3=g(_0x46478f,_0x270f6d['data']['isSuggestion']?'Suggested\x20by':'add'==_0x270f6d['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x270f6d['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x29deaf['to']('type',_0x4ec083=>'ck-revision-change__'+_0x4ec083)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x52eeb3}]},{'text':'\x20'+_0x270f6d['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class r extends/* #__PURE__ -- @preserve */
25
+ _0x3196fa(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x52cf61){super(),this['id']=_0x52cf61['id']||_0x3fbd15(),this['author']=_0x52cf61['author'],this['type']=_0x52cf61['type'],this['data']=_0x52cf61['data']||{},this['rootName']=_0x52cf61['rootName'],this['set']('createdAt',_0x52cf61['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(_0x517c73,_0x434bc4){this['newRevisionId']=_0x517c73,this['oldRevisionId']=_0x434bc4,this['changes']=new _0x5f0faf();}['_setChanges'](_0xa44daa){for(const _0x31d15c of _0xa44daa)this['changes']['add'](_0x31d15c);}}class m extends _0x1aaf30{['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[_0x25ff19,_0x52db93,I,V];}constructor(_0xc8007){super(_0xc8007),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',(_0x155fb1,_0x461bd1,_0x542a87)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x143f3a=>{for(const _0x3ed68f of this['editor']['editing']['view']['document']['roots'])_0x542a87?_0x143f3a['removeClass']('ck-editor__editable__overlay',_0x3ed68f):_0x143f3a['addClass']('ck-editor__editable__overlay',_0x3ed68f);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x1c266f=>null!==_0x1c266f),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x4b795e,_0x4a8e12,_0xa71252)=>_0x4b795e&&_0xa71252?_0x4a8e12['changes']['getIndex'](_0xa71252):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x513ee2,_0x23e199)=>_0x513ee2?_0x23e199['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0x52db93);}['init'](){const _0x2678e6=this['editor'],_0x472825=new wt(_0x2678e6,{'direction':'backward'}),_0x1b40bd=new wt(_0x2678e6,{'direction':'forward'});(_0x2678e6['commands']['add']('showPreviousChange',_0x472825),_0x2678e6['commands']['add']('showNextChange',_0x1b40bd),_0x2678e6['commands']['add']('restoreRevision',new mt(_0x2678e6)),this['on']('change:numberOfChanges',()=>{_0x472825['refresh'](),_0x1b40bd['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x2678e6['enableReadOnlyMode']('revision-viewer'),_0x2678e6['plugins']['has']('WidgetToolbarRepository'))&&_0x2678e6['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x12ddc0){return await this['_utils']['loadRevisionData'](_0x12ddc0,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x12ddc0);}async['getRevisionRootsAttributes'](_0x4fb5a1){return await this['_utils']['loadRevisionData'](_0x4fb5a1,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x4fb5a1);}async['compare'](_0x3ab766,_0x458a54,_0x45f6dc=!0x1){if(!this['isEnabled'])return;const _0x55bef2=this['diff'],_0x151d04=this['repository'],_0x23106e='string'==typeof _0x3ab766?_0x151d04['getRevision'](_0x3ab766):_0x3ab766,_0x463c13='string'==typeof _0x458a54?_0x151d04['getRevision'](_0x458a54):_0x458a54,_0x3fba0f=_0x23106e['id'],_0x17b3ef=_0x463c13?_0x463c13['id']:null;if(!_0x45f6dc&&this['diff']&&this['diff']['newRevisionId']===_0x3fba0f&&this['diff']['oldRevisionId']===_0x17b3ef)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new c(_0x3fba0f,_0x17b3ef);const _0x4165ee=this['_getRevisionsRange'](_0x23106e,_0x463c13,!0x0)['map'](_0x2f4504=>this['_utils']['loadRevisionData'](_0x2f4504,this['adapter']));return _0x4165ee['push'](new Promise(_0x30a92e=>{setTimeout(_0x30a92e,0x14);})),Promise['all'](_0x4165ee)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0xe90cac=this['_getDiff'](_0x3fba0f,_0x17b3ef);for(const _0x3711d2 of _0xe90cac['changes'])this['_changeIdToChange']['set'](_0x3711d2['id'],_0x3711d2);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x379996=>{for(const _0x33a480 of this['editor']['model']['document']['getRootNames']())_0x379996['detachRoot'](_0x33a480);for(const _0x4097b6 of Object['keys'](_0xe90cac['model'])){const _0x9cc671=_0x379996['addRoot'](_0x4097b6);for(const _0x8cc04e of Object['keys'](_0xe90cac['attributes'][_0x4097b6]))_0x379996['setAttribute'](_0x8cc04e,_0xe90cac['attributes'][_0x4097b6][_0x8cc04e],_0x9cc671);_0x379996['insert'](_0xe90cac['model'][_0x4097b6],_0x9cc671,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0xe90cac['changes'])),this['isReady']=!0x0;})['catch'](_0xaa5842=>{console['error'](_0xaa5842),this['_cleanUp'](),_0x55bef2&&(this['diff']=_0x55bef2),this['isReady']=!0x0;});}['addRevisionData'](_0x197688,_0x15196a){const _0x5e3470=this['repository']['createRevision'](_0x197688);return _0x5e3470['on']('_update',(_0x5c1ab9,_0x5927cb,_0x7a1e63)=>_0x15196a(_0x5927cb,_0x7a1e63,_0x5e3470)),this['repository']['addRevision'](_0x5e3470),_0x5e3470;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x4761aa=>{for(const _0x6e8091 of this['editor']['model']['document']['getRootNames']())_0x4761aa['detachRoot'](_0x6e8091);});}['_sortAndFilterDiffChanges'](_0x4471c9){const _0x3145c8=[],_0x5a8633=new Map();for(const _0x551bb8 of this['editor']['model']['document']['getRootNames']()){const _0xa3612e=this['editor']['editing']['view']['getDomRoot'](_0x551bb8);if(!_0xa3612e)continue;const _0x2b84eb=_0xa3612e['getClientRects']()['item'](0x0);_0x2b84eb&&(_0x3145c8['push'](_0x551bb8),_0x5a8633['set'](_0x551bb8,_0x2b84eb));}return _0x3145c8['sort']((_0xb7f2ae,_0x6f0d55)=>{const _0x5045de=_0x5a8633['get'](_0xb7f2ae),_0x3153a8=_0x5a8633['get'](_0x6f0d55);return _0x5045de['y']-_0x3153a8['y']||_0x5045de['x']-_0x3153a8['x'];}),(_0x4471c9=_0x4471c9['filter'](_0x3c4d81=>_0x3145c8['includes'](_0x3c4d81['rootName'])))['sort']((_0x2159e2,_0x58a901)=>_0x3145c8['indexOf'](_0x2159e2['rootName'])-_0x3145c8['indexOf'](_0x58a901['rootName'])),_0x4471c9;}['_makeTape'](_0xecc0a){const _0x309bd1=Array['from'](_0xecc0a['markers'])['filter'](([_0x53a14a,_0x198839])=>_0x53a14a['startsWith']('revision:')&&!_0x198839['isCollapsed']),_0x2b4383=Array['from'](this['editor']['model']['createRangeIn'](_0xecc0a)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x309bd1['length'])for(const _0x4680de of _0x2b4383){const [_0x30c58c,_0x5cf893]=_0x309bd1[0x0],[,_0x274777,_0x4f96f9]=_0x30c58c['split'](':');if(_0x5cf893['end']['isEqual'](_0x4680de['nextPosition'])&&_0x309bd1['shift'](),(_0x4680de['previousPosition']['isEqual'](_0x5cf893['start'])||_0x4680de['previousPosition']['isAfter'](_0x5cf893['start']))&&('insertion'==_0x274777?_0x4680de['isAdded']={'userId':_0x4f96f9}:'deletion'==_0x274777&&(_0x4680de['isRemoved']={'userId':_0x4f96f9})),0x0==_0x309bd1['length'])break;}return _0x2b4383;}['_refreshStartEndIndex'](_0x5d2696){const _0x20e318=new Map();for(let _0x4de539=0x0;_0x4de539<_0x5d2696['length'];_0x4de539++)'text'===_0x5d2696[_0x4de539]['type']?(_0x5d2696[_0x4de539]['item']['startIndex']=_0x4de539,_0x5d2696[_0x4de539]['item']['endIndex']=_0x4de539):('elementStart'===_0x5d2696[_0x4de539]['type']?_0x5d2696[_0x4de539]['item']['startIndex']=_0x4de539:'elementEnd'===_0x5d2696[_0x4de539]['type']&&(_0x5d2696[_0x4de539]['item']['endIndex']=_0x4de539),_0x20e318['set'](_0x5d2696[_0x4de539]['id'],_0x4de539));for(const _0x4a5113 of _0x20e318['values']())'elementStart'===_0x5d2696[_0x4a5113]['type']?_0x5d2696[_0x4a5113]['item']['endIndex']=_0x20e318['get'](_0x5d2696[_0x4a5113]['pairId']):'elementEnd'===_0x5d2696[_0x4a5113]['type']&&(_0x5d2696[_0x4a5113]['item']['startIndex']=_0x20e318['get'](_0x5d2696[_0x4a5113]['pairId']));}['_processTape'](_0x509bfe){for(let _0x1cdec2=0x0;_0x1cdec2<_0x509bfe['length'];_0x1cdec2++){if('elementStart'===_0x509bfe[_0x1cdec2]['type'])_0x509bfe[_0x1cdec2]['item']['startIndex']=_0x1cdec2;else{if('elementEnd'===_0x509bfe[_0x1cdec2]['type']){_0x509bfe[_0x1cdec2]['item']['endIndex']=_0x1cdec2;const _0x196339=_0x509bfe[_0x1cdec2]['item']['startIndex'];_0x509bfe[_0x196339]['pairId']=_0x509bfe[_0x1cdec2]['id'],_0x509bfe[_0x1cdec2]['pairId']=_0x509bfe[_0x196339]['id'];}else _0x509bfe[_0x1cdec2]['item']['startIndex']=_0x1cdec2,_0x509bfe[_0x1cdec2]['item']['endIndex']=_0x1cdec2,_0x509bfe[_0x1cdec2]['pairId']=null;}_0x509bfe[_0x1cdec2]['markersStart']||(_0x509bfe[_0x1cdec2]['markersStart']=[],_0x509bfe[_0x1cdec2]['markersEnd']=[]);}}['_markInsertions'](_0x44f4c4,_0x35fff0){const _0x4598c0=_0x44f4c4['filter'](_0x3790f5=>!_0x3790f5['isAdded']);for(let _0x5be7ad=0x0;_0x5be7ad<_0x35fff0['length'];_0x5be7ad++)_0x35fff0[_0x5be7ad]['isAdded']&&(_0x4598c0[_0x5be7ad]['isAdded']=_0x35fff0[_0x5be7ad]['isAdded']);}['_getDiff'](_0x3f0c68,_0x550ad8=null){const _0x3df6f0=this['repository']['getRevision'](_0x3f0c68),_0x4214cc=_0x550ad8?this['repository']['getRevision'](_0x550ad8):null,_0x4f55d2=this['_getRevisionsRange'](_0x3df6f0,_0x4214cc),_0x466893=_0x4f55d2[_0x4f55d2['length']-0x1],_0x54889f=new Map(),_0x36947e={'model':{},'attributes':{},'changes':[]},_0x32f163=new Set(),_0x4bf9db=new Map();for(let _0xbde911=_0x4f55d2['length']-0x1;_0xbde911>=0x0;_0xbde911--){const _0x50e64b=_0x4f55d2[_0xbde911];for(const _0x362ba5 of Object['keys'](_0x50e64b['diffData']))if(_0x50e64b['diffData'][_0x362ba5]['attachChange']){const _0x22d94b=_0x50e64b['diffData'][_0x362ba5]['attachChange'];_0x22d94b['isAttached']?(_0x32f163['add'](_0x362ba5),_0x4bf9db['has'](_0x362ba5)&&_0x4bf9db['get'](_0x362ba5)['userId']==_0x22d94b['userId']?_0x4bf9db['delete'](_0x362ba5):_0x4bf9db['set'](_0x362ba5,_0x22d94b)):_0x4bf9db['has'](_0x362ba5)?(_0x32f163['delete'](_0x362ba5),_0x4bf9db['delete'](_0x362ba5)):(_0x32f163['add'](_0x362ba5),_0x4bf9db['set'](_0x362ba5,_0x22d94b));}else _0x32f163['add'](_0x362ba5);}for(const _0x2c1d71 of _0x32f163){const _0x2eeba0=_0x4bf9db['has'](_0x2c1d71)&&!_0x4bf9db['get'](_0x2c1d71)['isAttached'];let _0x13bc0b=_0x2eeba0?_0x4f55d2['length']-0x1:0x0;const _0x9425bb=_0x2eeba0?-0x1:0x1;for(;_0x4f55d2[_0x13bc0b];){const _0x3c0249=_0x4f55d2[_0x13bc0b];if(_0x3c0249['diffData'][_0x2c1d71]){const _0x33d04d=_0x2eeba0?_0x3c0249['diffData'][_0x2c1d71]['attributesBefore']:_0x3c0249['diffData'][_0x2c1d71]['attributesAfter'];_0x36947e['attributes'][_0x2c1d71]=_0x33d04d?_0x4dbdf7(_0x33d04d):{};break;}_0x13bc0b+=_0x9425bb;}}for(const _0x3dbc8a of _0x4f55d2){_0x3dbc8a['model']={};for(const _0x5c0213 of _0x3dbc8a['authors'])_0x54889f['set'](_0x5c0213['id'],_0x5c0213);for(const _0xe9dec6 of _0x32f163){const _0x4104e9=_0x3dbc8a['diffData'][_0xe9dec6]?_0x3dbc8a['diffData'][_0xe9dec6]['insertions']:'[]',_0x1722ac=_0x3dbc8a['diffData'][_0xe9dec6]?_0x3dbc8a['diffData'][_0xe9dec6]['deletions']:'[]';_0x3dbc8a['model'][_0xe9dec6]={'insertions':this['_utils']['_makeModelFromViewString'](_0x4104e9),'deletions':this['_utils']['_makeModelFromViewString'](_0x1722ac)};}}for(const _0x2961bd of _0x32f163){let _0x5e6d15=null,_0x2cadd5=0x0;const _0x20dec9=new Map(Array['from'](_0x3df6f0['model'][_0x2961bd]['insertions']['markers'])['filter'](([_0x5ecd79])=>!_0x5ecd79['startsWith']('revision:')));let _0x585d03=0x0;for(const _0x12cd1d of _0x4f55d2){const _0x25dcb8=this['_makeTape'](_0x12cd1d['model'][_0x2961bd]['insertions']);_0x12cd1d==_0x3df6f0?(_0x5e6d15=_0x25dcb8,_0x2cadd5=_0x5e6d15['length'],_0x5e6d15['forEach'](_0x45822a=>{_0x45822a['id']=_0x585d03++;}),this['_processTape'](_0x5e6d15)):this['_markInsertions'](_0x5e6d15,_0x25dcb8);const _0x1bb6b9=_0x5e6d15['filter'](_0x4a674d=>!_0x4a674d['isAdded'])['map'](_0x436a51=>_0x436a51['id']);let _0x54a8fd=0x0;const _0x5d75d2=this['_makeTape'](_0x12cd1d['model'][_0x2961bd]['deletions']);_0x5d75d2['forEach'](_0x2b4240=>{_0x2b4240['isRemoved']?_0x2b4240['id']=_0x2cadd5++:_0x2b4240['id']=_0x1bb6b9[_0x54a8fd++];}),this['_processTape'](_0x5d75d2),this['_setDistance'](_0x5e6d15,'isAdded'),this['_setDistance'](_0x5d75d2,'isRemoved'),_0x12cd1d==_0x3df6f0&&this['_markMarkers'](_0x5e6d15,_0x20dec9),_0x5e6d15=this['_joinTapes'](_0x5e6d15,_0x5d75d2),this['_refreshStartEndIndex'](_0x5e6d15),this['_setDistance'](_0x5e6d15,'isRemoved');}_0x5e6d15=_0x5e6d15['filter'](_0x403a73=>!(_0x403a73['isAdded']&&_0x403a73['isRemoved']));const _0xde03be=new Map(_0x466893['model'][_0x2961bd]['deletions']['markers']),_0x1a75e8=new Set(_0x20dec9['keys']());for(const _0x2f9eef of _0xde03be['keys']())_0x1a75e8['delete'](_0x2f9eef);this['_markSuggestions'](_0x5e6d15,_0x1a75e8),this['_fixObsoleteTags'](_0x5e6d15),_0x5e6d15=this['_removeMissingPairs'](_0x5e6d15),_0x5e6d15=this['_markMismatchedRemovedTags'](_0x5e6d15),_0x5e6d15=this['_removeUnsupportedChanges'](_0x5e6d15);const {root:_0x37f56e,changes:_0x24dec8}=this['_makeModelFromTape'](_0x5e6d15,_0x54889f,_0x2961bd);_0x36947e['model'][_0x2961bd]=_0x37f56e;const _0x408337=_0x4bf9db['get'](_0x2961bd);if(_0x408337){const _0x11000f=_0x54889f['get'](_0x408337['userId']),_0xd16f78=new r({'author':_0x11000f,'type':_0x408337['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x2961bd});_0x24dec8['unshift'](_0xd16f78),_0x36947e['attributes'][_0x2961bd]['revisionHistoryAttachChange']=_0xd16f78['id'];}_0x36947e['changes']=_0x36947e['changes']['concat'](_0x24dec8);}return _0x36947e;}['_markMarkers'](_0x5bfdb1,_0x4f0a47){for(let _0x3e54b5=0x0;_0x3e54b5<_0x5bfdb1['length'];_0x3e54b5++)for(const [_0x2de637,_0xd6fc36]of _0x4f0a47)!_0xd6fc36['isCollapsed']&&_0xd6fc36['start']['isEqual'](_0x5bfdb1[_0x3e54b5]['previousPosition'])&&_0x5bfdb1[_0x3e54b5]['markersStart']['push'](_0x2de637),_0xd6fc36['end']['isEqual'](_0x5bfdb1[_0x3e54b5]['nextPosition'])&&_0x5bfdb1[_0x3e54b5]['markersEnd']['push'](_0x2de637);}['_joinTapes'](_0x132c93,_0x3f3050){let _0x802f0b=[],_0x371c8f=0x0,_0x32ad58=0x0;for(;_0x371c8f<_0x132c93['length']||_0x32ad58<_0x3f3050['length'];){const _0x19f72f=_0x132c93[_0x371c8f]||{},_0x46d2c4=_0x3f3050[_0x32ad58]||{};if(_0x19f72f['id']==_0x46d2c4['id'])_0x371c8f++,_0x32ad58++,_0x802f0b['push'](_0x19f72f);else{if(_0x46d2c4['isRemoved']&&_0x19f72f['isAdded']){const {commonTape:_0x2c326a,iEnd:_0x9be006,jEnd:_0x1685df}=this['_threeWayMerge'](_0x132c93,_0x371c8f,_0x3f3050,_0x32ad58);_0x802f0b=_0x802f0b['concat'](_0x2c326a),_0x371c8f=_0x9be006,_0x32ad58=_0x1685df;}else _0x46d2c4['isRemoved']?(_0x32ad58++,_0x802f0b['push'](_0x46d2c4)):(_0x371c8f++,_0x802f0b['push'](_0x19f72f));}}return _0x802f0b;}['_markSuggestions'](_0x3752b2,_0x3a0afd){const _0x39ab18=[];for(let _0x437f59=0x0;_0x437f59<_0x3752b2['length'];_0x437f59++){for(let _0x2b233e=0x0;_0x2b233e<_0x3752b2[_0x437f59]['markersStart']['length'];_0x2b233e++){const _0x23d767=_0x3752b2[_0x437f59]['markersStart'][_0x2b233e];if(!_0x3a0afd['has'](_0x23d767))continue;const {group:_0x5f2ac8,type:_0x146f2a,authorId:_0x492d81}=_0x3f0928(_0x23d767);'revision-suggestion'!=_0x5f2ac8||'insertion'!=_0x146f2a&&'deletion'!=_0x146f2a||(_0x39ab18['unshift']({'type':_0x146f2a,'name':_0x23d767,'userId':_0x492d81}),_0x3752b2[_0x437f59]['markersStart']['splice'](_0x2b233e,0x1),_0x2b233e--);}_0x158947(_0x3752b2[_0x437f59]);for(let _0x56b005=0x0;_0x56b005<_0x3752b2[_0x437f59]['markersEnd']['length'];_0x56b005++){const _0x24111e=_0x3752b2[_0x437f59]['markersEnd'][_0x56b005];if(!_0x3a0afd['has'](_0x24111e))continue;const {group:_0x138c10,type:_0x38116e}=_0x3f0928(_0x24111e);if('revision-suggestion'!=_0x138c10||'insertion'!=_0x38116e&&'deletion'!=_0x38116e)continue;_0x3752b2[_0x437f59]['markersEnd']['splice'](_0x56b005,0x1),_0x56b005--;const _0x8ac08a=_0x39ab18['findIndex'](_0x586a3a=>_0x586a3a['name']==_0x24111e);_0x8ac08a>-0x1&&_0x39ab18['splice'](_0x8ac08a,0x1);}}function _0x3f0928(_0x3e2400){const _0x5d7acd=_0x3e2400['split'](':');return{'group':_0x5d7acd[0x0],'type':_0x5d7acd[0x1],'subType':_0x5d7acd['length']>=0x5?_0x5d7acd[0x2]:null,'id':_0x5d7acd['length']<0x5?_0x5d7acd[0x2]:_0x5d7acd[0x3],'authorId':_0x5d7acd['length']<0x5?_0x5d7acd[0x3]:_0x5d7acd[0x4],'markerCount':0x6==_0x5d7acd['length']?_0x5d7acd[0x5]:null};}function _0x158947(_0x1cd483){for(let _0x450176=0x0;_0x450176<_0x39ab18['length'];_0x450176++){if(_0x1cd483['isAdded']&&'insertion'==_0x39ab18[_0x450176]['type'])return _0x1cd483['isAddSuggestion']=_0x39ab18[_0x450176],void delete _0x1cd483['isAdded'];if(!_0x1cd483['isAdded']&&!_0x1cd483['isRemoved']&&'deletion'==_0x39ab18[_0x450176]['type'])return void(_0x1cd483['isRemoveSuggestion']=_0x39ab18[_0x450176]);}}}['_setDistance'](_0x413a05,_0x42d055){let _0x17e6cd=0x0,_0x1eac30=!0x1;const _0xe6d70c=new Map();for(const _0x582cdb of _0x413a05)_0x582cdb[_0x42d055]?_0x1eac30&&(_0x17e6cd++,_0x1eac30=!0x1):(_0x17e6cd++,_0x1eac30=!0x0),_0xe6d70c['set'](_0x582cdb['id'],_0x17e6cd);for(let _0x2e8673=0x0;_0x2e8673<_0x413a05['length'];_0x2e8673++){if('isRemoved'==_0x42d055&&_0x413a05[_0x2e8673]['isAdded']||'isAdded'==_0x42d055&&_0x413a05[_0x2e8673]['isRemoved'])continue;if('text'==_0x413a05[_0x2e8673]['type']){_0x413a05[_0x2e8673]['distance']=0x0;continue;}const _0x279ff6=_0xe6d70c['get'](_0x413a05[_0x2e8673]['pairId']),_0x2201a5=_0xe6d70c['get'](_0x413a05[_0x2e8673]['id']);_0x413a05[_0x2e8673]['distance']=_0x279ff6-_0x2201a5;}}['_getRevisionsRange'](_0x3ebe62,_0x290d66,_0x43beec=!0x1){const _0x23dd8f=[];let _0x4f7772=this['repository']['getIndex'](_0x3ebe62),_0x23432b=this['repository']['getIndex'](_0x290d66);for(-0x1==_0x23432b&&(_0x23432b=this['repository']['_revisions']['length'],_0x43beec=!0x1);_0x4f7772<_0x23432b;)_0x23dd8f['push'](this['repository']['getRevision'](_0x4f7772)),_0x4f7772++;return _0x43beec&&_0x23dd8f['push'](this['repository']['getRevision'](_0x4f7772)),_0x23dd8f;}['_threeWayMerge'](_0x426f45,_0x17b346,_0x43aa02,_0x24ff01){const _0xa85513=this['editor']['model']['schema'];let _0x3de9ff=_0x17b346;for(;_0x426f45[_0x3de9ff]&&_0x426f45[_0x3de9ff]['isAdded'];)_0x3de9ff++;let _0x52b0c7=_0x24ff01;for(;_0x43aa02[_0x52b0c7]&&_0x43aa02[_0x52b0c7]['isRemoved'];)_0x52b0c7++;_0x4520a9(_0x426f45,_0x17b346,_0x3de9ff),_0x4520a9(_0x43aa02,_0x24ff01,_0x52b0c7);const _0x344d00=_0x43aa02['slice'](_0x24ff01,_0x52b0c7)['concat'](_0x426f45['slice'](_0x17b346,_0x3de9ff));return _0x344d00['sort']((_0x3cc78a,_0x6a573b)=>_0x3cc78a['side']!=_0x6a573b['side']?_0x3cc78a['side']-_0x6a573b['side']:_0x3cc78a['level']!=_0x6a573b['level']?_0x3cc78a['level']-_0x6a573b['level']:_0x3cc78a['distance']!=_0x6a573b['distance']?_0x6a573b['distance']-_0x3cc78a['distance']:!!_0x3cc78a['isAdded']!=!!_0x6a573b['isAdded']?-0x1==_0x3cc78a['side']||0x0==_0x3cc78a['side']?_0x3cc78a['isAdded']?-0x1:0x1:_0x3cc78a['isAdded']?0x1:-0x1:_0x3cc78a['index']-_0x6a573b['index']),{'commonTape':_0x344d00,'iEnd':_0x3de9ff,'jEnd':_0x52b0c7};function _0x4520a9(_0x365ce9,_0x21a41a,_0x20f3c5){let _0x1cfab0=-0x1,_0x447de4=Number['POSITIVE_INFINITY'],_0x3dd51a=!0x0;for(let _0x5823ff=_0x21a41a;_0x5823ff<_0x20f3c5;_0x5823ff++)if(_0xa85513['isInline'](_0x365ce9[_0x5823ff]['item'])||(_0x3dd51a=!0x1),_0x365ce9[_0x5823ff]['item']['startIndex']<_0x21a41a&&(_0x1cfab0=_0x5823ff),_0x365ce9[_0x5823ff]['item']['endIndex']>=_0x20f3c5){_0x447de4=_0x5823ff;break;}_0x3dd51a&&(_0x1cfab0=_0x20f3c5-0x1);for(let _0xe3977e=_0x21a41a;_0xe3977e<_0x20f3c5;_0xe3977e++)_0x365ce9[_0xe3977e]['side']=_0xe3977e<=_0x1cfab0?-0x1:_0xe3977e<_0x447de4?0x0:0x1,_0x365ce9[_0xe3977e]['index']=_0xe3977e;let _0x5bd23e=0x0;for(let _0x15c58e=_0x21a41a;_0x15c58e<=_0x1cfab0;_0x15c58e++)0x0==_0x365ce9[_0x15c58e]['distance']?_0x365ce9[_0x15c58e]['level']=_0x5bd23e:(_0x5bd23e++,_0x365ce9[_0x15c58e]['level']=_0x5bd23e,_0x5bd23e++);for(let _0xd90076=_0x21a41a;_0xd90076<_0x20f3c5;_0xd90076++)0x0==_0x365ce9[_0xd90076]['side']&&(_0x365ce9[_0xd90076]['level']=_0x5bd23e);_0x5bd23e=0x0;for(let _0x46cfde=_0x20f3c5-0x1;_0x46cfde>=_0x447de4;_0x46cfde--)0x0==_0x365ce9[_0x46cfde]['distance']?_0x365ce9[_0x46cfde]['level']=_0x5bd23e:(_0x5bd23e--,_0x365ce9[_0x46cfde]['level']=_0x5bd23e,_0x5bd23e--);}}['_fixObsoleteTags'](_0x5d9653){const _0x3133c5=new Map(),_0x228705=this['editor']['model']['schema'];for(let _0xcd14e4=0x1;_0xcd14e4<_0x5d9653['length'];_0xcd14e4++){let _0x3f35a6,_0x4e1ab6,_0x20b8b1;const _0xdd2993=_0x5d9653[_0xcd14e4],_0x57a2cc=_0x5d9653[_0xcd14e4-0x1];if('text'==_0xdd2993['type'])continue;if(_0xdd2993['type']!=_0x57a2cc['type'])continue;if(!_0x228705['isBlock'](_0x57a2cc['item'])||_0x228705['isLimit'](_0x57a2cc['item']))continue;if(!_0x228705['isBlock'](_0xdd2993['item'])||_0x228705['isLimit'](_0xdd2993['item']))continue;if((_0x5d9653[_0xcd14e4]['isAdded']||_0x5d9653[_0xcd14e4]['isAddSuggestion'])&&_0x5d9653[_0xcd14e4-0x1]['isRemoved'])_0x3f35a6=_0x5d9653[_0xcd14e4],_0x4e1ab6=_0x5d9653[_0xcd14e4-0x1],_0x20b8b1=_0xcd14e4-0x1;else{if(!_0x5d9653[_0xcd14e4]['isRemoved']||!_0x5d9653[_0xcd14e4-0x1]['isAdded']&&!_0x5d9653[_0xcd14e4-0x1]['isAddSuggestion'])continue;_0x3f35a6=_0x5d9653[_0xcd14e4-0x1],_0x4e1ab6=_0x5d9653[_0xcd14e4],_0x20b8b1=_0xcd14e4;}const _0x1c8f1f=_0x3f35a6['level']==_0x4e1ab6['level'],_0x1c54ef=Math['abs'](_0x3f35a6['level'])<Math['abs'](_0x4e1ab6['level'])&&0x0==_0x4e1ab6['distance'];(_0x1c8f1f||_0x1c54ef)&&(_0x3133c5['set'](_0x4e1ab6['id'],_0x3f35a6['id']),_0x5d9653['splice'](_0x20b8b1,0x1),_0xcd14e4--,_0x3f35a6['isAdded']=!0x1);}for(let _0x3df9f1=0x0;_0x3df9f1<_0x5d9653['length'];_0x3df9f1++)_0x3133c5['has'](_0x5d9653[_0x3df9f1]['pairId'])&&(_0x5d9653[_0x3df9f1]['pairId']=_0x3133c5['get'](_0x5d9653[_0x3df9f1]['pairId']));}['_removeMissingPairs'](_0xdd4b78){const _0x1ec90e=new Set(_0xdd4b78['map'](_0x5ee1a2=>_0x5ee1a2['id']));for(let _0x158061=0x0;_0x158061<_0xdd4b78['length'];_0x158061++)_0x1ec90e['has'](_0xdd4b78[_0x158061]['pairId'])||0x0==_0xdd4b78[_0x158061]['distance']||(_0xdd4b78[_0x158061]['isIncorrect']=!0x0);return _0xdd4b78['filter'](_0x296c1c=>!_0x296c1c['isIncorrect']);}['_markMismatchedRemovedTags'](_0x50739d){const _0x5f5cee=new Set();for(let _0x1ef216=0x0;_0x1ef216<_0x50739d['length'];_0x1ef216++){if(_0x5f5cee['has'](_0x50739d[_0x1ef216]['id'])&&_0x50739d[_0x1ef216]['isRemoved']&&(_0x50739d[_0x1ef216]['isIncorrect']=!0x0),_0x50739d[_0x1ef216]['isIncorrect'])continue;if(0x0==_0x50739d[_0x1ef216]['distance'])continue;if('elementStart'!=_0x50739d[_0x1ef216]['type'])continue;if(null==_0x50739d[_0x1ef216]['pairId'])continue;let _0x5c5f3b=_0x1ef216+0x1,_0x68c595=0x0;for(;_0x50739d[_0x5c5f3b]['id']!=_0x50739d[_0x1ef216]['pairId'];)'elementStart'==_0x50739d[_0x5c5f3b]['type']?_0x68c595++:'elementEnd'==_0x50739d[_0x5c5f3b]['type']&&_0x68c595--,_0x5c5f3b++;if(0x0!=_0x68c595){if(_0x50739d[_0x1ef216]['isRemoved'])_0x50739d[_0x1ef216]['isIncorrect']=!0x0;else{for(;_0x5c5f3b!=_0x1ef216;)_0x50739d[_0x5c5f3b]['isRemoved']&&0x0!=_0x50739d[_0x5c5f3b]['distance']&&(_0x50739d[_0x5c5f3b]['isIncorrect']=!0x0,_0x5f5cee['add'](_0x50739d[_0x5c5f3b]['pairId'])),_0x5c5f3b--;}}}return _0x50739d['filter'](_0xe62c13=>!_0xe62c13['isIncorrect']);}['_removeUnsupportedChanges'](_0x3fa082){const _0x43f748=this['editor']['model']['schema'];for(let _0x1f17f8=0x0;_0x1f17f8<_0x3fa082['length'];_0x1f17f8++){if(!(_0x3fa082[_0x1f17f8]['isAdded']||_0x3fa082[_0x1f17f8]['isAddSuggestion']||_0x3fa082[_0x1f17f8]['isRemoved']||_0x3fa082[_0x1f17f8]['isRemoveSuggestion']))continue;if(0x0==_0x3fa082[_0x1f17f8]['distance'])continue;const _0x482602=_0x3fa082[_0x1f17f8]['item'];_0x43f748['isBlock'](_0x482602)||_0x43f748['isLimit'](_0x482602)||(_0x3fa082[_0x1f17f8]['isAdded']&&delete _0x3fa082[_0x1f17f8]['isAdded'],_0x3fa082[_0x1f17f8]['isAddSuggestion']&&delete _0x3fa082[_0x1f17f8]['isAddSuggestion'],_0x3fa082[_0x1f17f8]['isRemoveSuggestion']&&delete _0x3fa082[_0x1f17f8]['isRemoveSuggestion'],_0x3fa082[_0x1f17f8]['isRemoved']&&(_0x3fa082[_0x1f17f8]['isIncorrect']=!0x0));}return _0x3fa082['filter'](_0x597625=>!_0x597625['isIncorrect']);}['_makeModelFromTape'](_0x2bd10b,_0x2f3838,_0x78bb86){const _0x6d89ea=new vt(),_0x1c2ed4=[],_0x1df030=new Map(),_0x43138c=this['editor']['model'],_0x35d489=_0x43138c['schema'],_0xa19a53=[_0x6d89ea],_0x51f3ae={},_0x2f8845={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x4dc062=null;const _0x31d934=[0x0];for(let _0x2a66a4=0x0;_0x2a66a4<_0x2bd10b['length'];_0x2a66a4++)if('elementStart'===_0x2bd10b[_0x2a66a4]['type']){_0x2bd10b[_0x2a66a4]['previousPosition']=_0x43138c['createPositionFromPath'](_0x6d89ea,_0x31d934);const _0x3e01c9=new ut(_0x2bd10b[_0x2a66a4]['item']['name'],_0x2bd10b[_0x2a66a4]['item']['getAttributes']());_0xa19a53[0x0]['_appendChild'](_0x3e01c9),_0x31d934['push'](0x0),_0xa19a53['unshift'](_0x3e01c9),_0x2bd10b[_0x2a66a4]['nextPosition']=_0x43138c['createPositionFromPath'](_0x6d89ea,_0x31d934);}else'elementEnd'===_0x2bd10b[_0x2a66a4]['type']?(_0xa19a53['shift'](),_0x2bd10b[_0x2a66a4]['previousPosition']=_0x43138c['createPositionFromPath'](_0x6d89ea,_0x31d934),_0x31d934['pop'](),_0x31d934[_0x31d934['length']-0x1]++,_0x2bd10b[_0x2a66a4]['nextPosition']=_0x43138c['createPositionFromPath'](_0x6d89ea,_0x31d934)):(_0x2bd10b[_0x2a66a4]['previousPosition']=_0x43138c['createPositionFromPath'](_0x6d89ea,_0x31d934),_0x4dc062?_0x4dc062['_data']+=_0x2bd10b[_0x2a66a4]['item']['data']:_0x4dc062=new gt(_0x2bd10b[_0x2a66a4]['item']['data'],_0x2bd10b[_0x2a66a4]['item']['getAttributes']()),_0x2bd10b[_0x2a66a4+0x1]&&'text'===_0x2bd10b[_0x2a66a4+0x1]['type']&&_0xdd137b(_0x4dc062,_0x2bd10b[_0x2a66a4+0x1]['item'])||(_0xa19a53[0x0]['_appendChild'](_0x4dc062),_0x4dc062=null),_0x31d934[_0x31d934['length']-0x1]+=_0x2bd10b[_0x2a66a4]['item']['offsetSize'],_0x2bd10b[_0x2a66a4]['nextPosition']=_0x43138c['createPositionFromPath'](_0x6d89ea,_0x31d934));for(let _0x34bbc4=0x0;_0x34bbc4<_0x2bd10b['length'];_0x34bbc4++){const _0x536592=_0x2bd10b[_0x34bbc4]['previousPosition'],_0x3d9dea=_0x2bd10b[_0x34bbc4]['nextPosition'];for(const _0x32221f of _0x2bd10b[_0x34bbc4]['markersStart'])_0x1df030['set'](_0x32221f,{'start':_0x536592,'end':null});_0x30fe40('isRemoveSuggestion',_0x34bbc4,_0x536592,_0x3d9dea),_0x30fe40('isAddSuggestion',_0x34bbc4,_0x536592,_0x3d9dea),_0x30fe40('isRemoved',_0x34bbc4,_0x536592,_0x3d9dea),_0x30fe40('isAdded',_0x34bbc4,_0x536592,_0x3d9dea);for(const _0x192c80 of _0x2bd10b[_0x34bbc4]['markersEnd']){const _0x262532=_0x1df030['get'](_0x192c80);_0x262532?_0x262532['end']=_0x3d9dea:_0x1df030['set'](_0x192c80,{'start':_0x3d9dea,'end':_0x3d9dea});}}for(const [_0x43a334,_0x455fbd]of _0x1df030){const _0x80ba22=this['editor']['model']['createRange'](_0x455fbd['start'],_0x455fbd['end']);_0x6d89ea['markers']['set'](_0x43a334,_0x80ba22);}return _0x1c2ed4['sort']((_0x505a16,_0x411a0e)=>{const _0x5a5af6=_0x6d89ea['markers']['get']('revision:'+_0x505a16['id']),_0x5bee43=_0x6d89ea['markers']['get']('revision:'+_0x411a0e['id']);return _0x5a5af6['start']['isBefore'](_0x5bee43['start'])?-0x1:_0x5a5af6['start']['isAfter'](_0x5bee43['start'])?0x1:_0x5a5af6['end']['isBefore'](_0x5bee43['end'])?-0x1:_0x5a5af6['end']['isAfter'](_0x5bee43['end'])?0x1:'add'===_0x505a16['type']?-0x1:0x1;}),{'root':_0x6d89ea,'changes':_0x1c2ed4};function _0x30fe40(_0x1f3a62,_0x548718,_0x572d8e,_0x1b8455){const _0x284fe9=!!_0x2bd10b[_0x548718][_0x1f3a62],_0x116618=_0x284fe9?_0x2bd10b[_0x548718][_0x1f3a62]['userId']:null,_0x5cdaaf=_0x548718===_0x2bd10b['length']-0x1,_0x16f321=_0x2f8845[_0x1f3a62][0x0],_0x1798ea=_0x35d489['isObject'](_0x2bd10b[_0x548718]['item']);!_0x51f3ae[_0x1f3a62]&&_0x284fe9?_0x51f3ae[_0x1f3a62]={'start':_0x572d8e,'tapeItem':_0x2bd10b[_0x548718],'userId':_0x116618,'type':_0x1f3a62}:_0x51f3ae[_0x1f3a62]&&!_0x284fe9?(_0x51f3ae[_0x1f3a62]['end']=_0x572d8e,_0x13c6ed(_0x51f3ae[_0x1f3a62]),_0x51f3ae[_0x1f3a62]=null):_0x51f3ae[_0x1f3a62]&&_0x284fe9&&_0x51f3ae[_0x1f3a62]['userId']!==_0x116618&&(_0x51f3ae[_0x1f3a62]['end']=_0x572d8e,_0x16f321&&_0x16f321['userId']===_0x51f3ae[_0x1f3a62]['userId']||_0x13c6ed(_0x51f3ae[_0x1f3a62]),_0x51f3ae[_0x1f3a62]={'start':_0x572d8e,'tapeItem':_0x2bd10b[_0x548718],'userId':_0x116618,'type':_0x1f3a62}),_0x51f3ae[_0x1f3a62]&&_0x1798ea&&('elementStart'!==_0x2bd10b[_0x548718]['type']||_0x16f321&&_0x16f321['userId']===_0x116618||_0x2f8845[_0x1f3a62]['unshift']({'userId':_0x116618,'object':_0x2bd10b[_0x548718]['item'],'change':_0x51f3ae[_0x1f3a62]}),'elementEnd'===_0x2bd10b[_0x548718]['type']&&_0x16f321&&_0x16f321['object']===_0x2bd10b[_0x548718]['item']&&(_0x2f8845[_0x1f3a62]['shift'](),_0x51f3ae[_0x1f3a62]=_0x16f321['change'])),_0x51f3ae[_0x1f3a62]&&_0x5cdaaf&&(_0x51f3ae[_0x1f3a62]['end']=_0x1b8455,_0x13c6ed(_0x51f3ae[_0x1f3a62]),_0x51f3ae[_0x1f3a62]=null);}function _0x13c6ed({start:_0x1d5a90,end:_0x31d7be,tapeItem:_0x13b560,userId:_0x482b24,type:_0x2481ce}){const _0xc63c60=_0x13b560['item'],_0x17bf9c=_0x43138c['schema']['isBlock'](_0xc63c60)&&!_0x43138c['schema']['isLimit'](_0xc63c60),_0xf6a720=_0x1d5a90['nodeAfter']==_0x31d7be['parent']&&_0x31d7be['isAtStart'];if(_0x17bf9c&&_0xf6a720)return;const _0xa605ed=_0x43138c['createRange'](_0x1d5a90,_0x31d7be),_0x55fb3c=_0x2f3838['get'](_0x482b24),_0x1ed7f5=new r({'author':_0x55fb3c,'type':'isAdded'==_0x2481ce||'isAddSuggestion'==_0x2481ce?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x2481ce||'isRemoveSuggestion'==_0x2481ce},'createdAt':new Date(),'rootName':_0x78bb86});_0x1c2ed4['push'](_0x1ed7f5),_0x6d89ea['markers']['set']('revision:'+_0x1ed7f5['id'],_0xa605ed);}function _0xdd137b(_0x196330,_0x16a414){const _0x374fb9=_0x196330['getAttributes'](),_0x2d3d64=_0x16a414['getAttributes']();for(const _0x3cb3dc of _0x374fb9){if(_0x3cb3dc[0x1]!==_0x16a414['getAttribute'](_0x3cb3dc[0x0]))return!0x1;_0x2d3d64['next']();}return _0x2d3d64['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x59970e=>{const _0x52bddb=_0x59970e['markerName']['split'](':')[0x1],_0x5e13f7=this['_getChangeFromId'](_0x52bddb);if(!_0x5e13f7)return null;const _0x5debda='add'==_0x5e13f7['type']?'insertion':'deletion',_0x3a579c=['ck-suggestion-marker','ck-suggestion-marker-'+_0x5debda];return _0x5e13f7['data']['isSuggestion']&&_0x3a579c['push']('ck-suggestion-marker-'+_0x5debda+'-new'),this['activeChange']==_0x5e13f7&&_0x3a579c['push']('ck-suggestion-marker--active'),{'classes':_0x3a579c,'attributes':{'data-change-id':_0x52bddb}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x140284=>{_0x140284['on']('element:pre',(_0x4bc49b,_0x468352,_0x37d10b)=>{const _0x118dd7=_0x468352['viewItem']['getChild'](0x0);if(!_0x118dd7||!_0x118dd7['is']('element','code'))return;if(!_0x37d10b['consumable']['consume'](_0x118dd7,{'attributes':['vid_start','vid_end']}))return;const _0x1beba2=_0x468352['modelRange']['start']['nodeAfter'];_0x37d10b['writer']['setAttribute']('vid_start',_0x118dd7['getAttribute']('vid_start'),_0x1beba2),_0x37d10b['writer']['setAttribute']('vid_end',_0x118dd7['getAttribute']('vid_end'),_0x1beba2);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x8df8a2=>{_0x8df8a2['on']('element',(_0x5658f3,_0x390762,_0x5a2d77)=>{if(!_0x5a2d77['consumable']['consume'](_0x390762['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x390762['modelRange']['isCollapsed'])return;const _0x4c936a=_0x390762['modelRange']['start']['nodeAfter'];_0x4c936a['hasAttribute']('vid_start')||_0x4c936a['hasAttribute']('vid')||(_0x5a2d77['writer']['setAttribute']('vid_start',_0x390762['viewItem']['getAttribute']('vid_start'),_0x4c936a),_0x5a2d77['writer']['setAttribute']('vid_end',_0x390762['viewItem']['getAttribute']('vid_end'),_0x4c936a));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x2fc5a4=>_0x2fc5a4['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x5e34fb,[,_0x4e91cf])=>{['vid_start','vid_end','vid']['includes'](_0x4e91cf)&&(_0x5e34fb['return']=!0x0,_0x5e34fb['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x25eded=>{_0x25eded['on']('attribute:vid',(_0x50cfac,_0x3b401f,_0x52df49)=>{if('\x20'!=_0x3b401f['item']['data']||_0x3b401f['item']['parent']['maxOffset']>0x1)return;if(!_0x52df49['consumable']['consume'](_0x3b401f['item'],_0x50cfac['name']))return;const _0x21aa52=_0x52df49['writer'],_0x4ad819=_0x52df49['mapper']['toViewRange'](_0x3b401f['range']);_0x21aa52['wrap'](_0x4ad819,_0x21aa52['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x2d222c){const _0x5b840b=_0x2d222c['plugins']['get']('RevisionViewer');return(_0x245854,_0x4bbc99,_0x385245)=>{const _0x50bb87=_0x4bbc99['markerName']['split'](':')[0x1],_0x208359=_0x5b840b['_getChangeFromId'](_0x50bb87);if(!_0x208359)return null;const _0x5ec730='add'==_0x208359['type']?'split':'merge';if(!_0x385245['consumable']['test'](_0x4bbc99['markerRange'],_0x245854['name']))return;const _0xc3dd22=_0x4bbc99['markerRange']['getWalker'](),_0x18b513=_0x4bbc99['markerRange']['start'],_0x4bbe0e=_0x2d222c['model']['schema'];let _0x57ccf3=null,_0x2e50ee=null,_0x2cebc2=!0x1,_0x1ca540=!0x1;for(const _0x48ee2d of _0xc3dd22){const _0x1cc25e=_0x48ee2d['item'];_0x2cebc2=_0x2cebc2||_0x4bbe0e['isContent'](_0x1cc25e);const _0x5d370d=_0x385245['mapper']['toViewElement'](_0x1cc25e);if(_0x5d370d&&_0x5d370d['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x48ee2d['type']&&(_0x4bbe0e['isBlock'](_0x1cc25e)&&!_0x4bbe0e['isLimit'](_0x1cc25e)&&(_0x1cc25e['nextSibling']||_0x18b513['isAtEnd']?_0x57ccf3&&_0x57ccf3['parent']==_0x1cc25e||(_0x57ccf3=_0x1cc25e,_0xdbcbf1(_0x48ee2d['previousPosition']),_0x1ca540=!0x0):_0x2e50ee=_0x2e50ee||_0x48ee2d['previousPosition']));}function _0xdbcbf1(_0x2c3c92){const _0x5c2836=_0x385245['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x5ec730}),_0x4bac0c=_0x385245['mapper']['toViewPosition'](_0x2c3c92);_0x208359['data']['isSuggestion']&&_0x385245['writer']['addClass']('ck-suggestion-marker-'+_0x5ec730+'-new',_0x5c2836),_0x5b840b['activeChange']==_0x208359&&_0x385245['writer']['addClass']('ck-suggestion-marker--active',_0x5c2836),_0x385245['writer']['insert'](_0x4bac0c,_0x5c2836),_0x385245['mapper']['bindElementToMarker'](_0x5c2836,_0x4bbc99['markerName']);}_0x2cebc2||_0x1ca540||!_0x2e50ee||_0xdbcbf1(_0x2e50ee);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x2432f9,_0x2d80e9,_0x570706)=>{const _0x1ea61a=_0x570706['mapper']['markerNameToElements'](_0x2d80e9['markerName']);if(_0x1ea61a){for(const _0x1d2755 of _0x1ea61a)(_0x1d2755['hasClass']('ck-suggestion-marker-split')||_0x1d2755['hasClass']('ck-suggestion-marker-merge'))&&(_0x570706['mapper']['unbindElementFromMarkerName'](_0x1d2755,_0x2d80e9['markerName']),_0x570706['writer']['remove'](_0x1d2755));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x38f0a1,_0x4f5050,_0x5c8c14)=>{const _0x5cd0fa=_0x4f5050['markerName']['split'](':')[0x1],_0x20b5c9=this['_getChangeFromId'](_0x5cd0fa);if(!_0x20b5c9)return null;const _0x5c93b2='add'==_0x20b5c9['type']?'split':'merge';if(_0x5c8c14['consumable']['test'](_0x4f5050['markerRange'],_0x38f0a1['name']))for(const _0x17e6a0 of _0x4f5050['markerRange']['getItems']()){if(!_0x17e6a0['is']('element','softBreak'))continue;const _0x2db7dc=_0x5c8c14['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x5c93b2}),_0x14cfed=_0x5c8c14['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x17e6a0));_0x20b5c9['data']['isSuggestion']&&_0x5c8c14['writer']['addClass']('ck-suggestion-marker-'+_0x5c93b2+'-new',_0x2db7dc),this['activeChange']==_0x20b5c9&&_0x5c8c14['writer']['addClass']('ck-suggestion-marker--active',_0x2db7dc),_0x5c8c14['writer']['insert'](_0x14cfed,_0x2db7dc),_0x5c8c14['mapper']['bindElementToMarker'](_0x2db7dc,_0x4f5050['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0xca10cd=>{for(const _0x1405b9 of this['editor']['model']['document']['getRootNames']()){const _0x334fc1=this['editor']['model']['document']['getRoot'](_0x1405b9),_0x35d365=this['editor']['editing']['view']['document']['getRoot'](_0x1405b9);if(_0x35d365){const _0x56a540=_0x334fc1['getAttribute']('revisionHistoryAttachChange');if(_0xca10cd['removeAttribute']('data-change-id',_0x35d365),_0xca10cd['removeClass']('ck-revision-history-root-add',_0x35d365),_0xca10cd['removeClass']('ck-revision-history-root-remove',_0x35d365),_0xca10cd['removeClass']('ck-revision-history-root--active',_0x35d365),_0x56a540){const _0x2d185a=this['_getChangeFromId'](_0x56a540);if(!_0x2d185a)return null;_0xca10cd['setAttribute']('data-change-id',_0x56a540,_0x35d365),_0xca10cd['addClass']('ck-revision-history-root-'+_0x2d185a['type'],_0x35d365),this['activeChange']==_0x2d185a&&_0xca10cd['addClass']('ck-revision-history-root--active',_0x35d365);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x3fce4f=>'revision-comment:'+_0x3fce4f,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x1784d7=>'revision-suggestion:'+_0x1784d7,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x2623f4=>({'name':'suggestion:'+_0x2623f4,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0xec1e48=>{const _0xc1c023=_0xec1e48['markerName']['split'](':')[0x1];return'insertion'!=_0xc1c023&&'deletion'!=_0xc1c023?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0xc1c023]};}}),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',(_0x27ae72,_0x4592aa,_0xa15a9d)=>{const _0x34bca4=_0xa15a9d['mapper']['markerNameToElements'](_0x4592aa['markerName']);if(_0x34bca4){for(const _0x488b0a of _0x34bca4)_0x488b0a['is']('uiElement')&&(_0xa15a9d['mapper']['unbindElementFromMarkerName'](_0x488b0a,_0x4592aa['markerName']),_0xa15a9d['writer']['remove'](_0x488b0a));}},{'priority':'high'});}['_getChangeFromId'](_0x5e140d){return this['_changeIdToChange']['get'](_0x5e140d);}['_getViewForChange'](_0x8af1bd){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new Q(this['editor']['locale'],_0x8af1bd),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0xb90226,_0x41c28f,_0x2dccbf,_0x4165d6)=>{_0x4165d6&&this['_balloon']['remove'](_0x4165d6),_0x2dccbf&&(this['_balloon']['add']({'view':_0x2dccbf,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x3994a4=this['editor']['editing'],_0x488a9a=this['_getChangeFromId'](_0x2dccbf['changeId']);let _0x571d99;if(_0x488a9a['data']['isOnRoot']){const _0x16a78f=_0x3994a4['view']['getDomRoot'](_0x488a9a['rootName']);_0x571d99=Array['from'](_0x16a78f['getClientRects']());}else{const _0x2864c9=this['editor']['model']['markers']['get']('revision:'+_0x2dccbf['changeId']);_0x571d99=Array['from'](_0x3994a4['mapper']['markerNameToElements'](_0x2864c9['name']))['map'](_0x225703=>_0x3994a4['view']['domConverter']['mapViewToDom'](_0x225703))['map'](_0x5bb6f0=>Array['from'](_0x5bb6f0['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x571d99[0x0];return _0x571d99['find'](_0xbd912a=>_0xbd912a['top']-0x3<=this['_activeViewTarget']['y']&&_0xbd912a['bottom']+0x3>=this['_activeViewTarget']['y']&&_0xbd912a['left']-0x3<=this['_activeViewTarget']['x']&&_0xbd912a['right']+0x3>=this['_activeViewTarget']['x'])||_0x571d99[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x36840f,_0x41fa11,_0x4e66ce,_0x2beb9e)=>{this['activeView']=_0x4e66ce?this['_getViewForChange'](_0x4e66ce):null,this['editor']['model']['change'](()=>{const _0xf88a8=this['editor']['editing'];_0x2beb9e&&(_0x2beb9e['data']['isOnRoot']?_0xf88a8['view']['change'](_0x510100=>{_0x510100['removeClass']('ck-revision-history-root--active',_0xf88a8['view']['document']['getRoot'](_0x2beb9e['rootName']));}):_0xf88a8['reconvertMarker']('revision:'+_0x2beb9e['id'])),_0x4e66ce&&(_0x4e66ce['data']['isOnRoot']?_0xf88a8['view']['change'](_0x2f2fca=>{_0x2f2fca['addClass']('ck-revision-history-root--active',_0xf88a8['view']['document']['getRoot'](_0x4e66ce['rootName']));}):_0xf88a8['reconvertMarker']('revision:'+_0x4e66ce['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x2a8606,_0x179e3a)=>{if(this['activeChange'])return;const _0x211de1=this['_findChangeIdFromDomTarget'](_0x179e3a['target']),_0xd52585=this['_changeIdToChange']['get'](_0x211de1);_0xd52585?(this['_activeViewTarget']={'x':_0x179e3a['domEvent']['x'],'y':_0x179e3a['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0xd52585)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x4eb5c7,_0x1bb5fb)=>{const _0x31419e=this['_findChangeIdFromDomTarget'](_0x1bb5fb['target']),_0x4a13b9=this['_changeIdToChange']['get'](_0x31419e);_0x4a13b9?(this['_activeViewTarget']={'x':_0x1bb5fb['domEvent']['x'],'y':_0x1bb5fb['domEvent']['y']},_0x4a13b9===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x4a13b9):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x5ab0ab){do{const _0x2bbe65=_0x5ab0ab['getAttribute']('data-change-id');if(_0x2bbe65)return _0x2bbe65;_0x5ab0ab=_0x5ab0ab['parent'];}while(_0x5ab0ab);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x43e5a9=>{for(const _0x1abfbb of this['editor']['model']['markers'])_0x43e5a9['removeMarker'](_0x1abfbb);});}}function X(_0x23527e,_0x29bb6e){return(_0x1da8f7,_0x112a3e,_0x335126)=>{if(!_0x335126['consumable']['test'](_0x112a3e['markerRange'],_0x1da8f7['name']))return;const _0x26c633=_0x112a3e['markerRange']['getWalker'](),_0x28a2e9=_0x112a3e['markerRange']['start'],_0x51352f=_0x23527e['model']['schema'];let _0x2b40cb=null,_0x4ffaff=null,_0x490a45=!0x1,_0x1db828=!0x1;for(const _0x530201 of _0x26c633){const _0x482501=_0x530201['item'];_0x490a45=_0x490a45||_0x51352f['isContent'](_0x482501);const _0x489606=_0x335126['mapper']['toViewElement'](_0x482501);if(_0x489606&&_0x489606['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x530201['type']&&(_0x51352f['isBlock'](_0x482501)&&!_0x51352f['isLimit'](_0x482501)&&(_0x482501['nextSibling']||_0x28a2e9['isAtEnd']?_0x2b40cb&&_0x2b40cb['parent']==_0x482501||(_0x2b40cb=_0x482501,_0x117e71(_0x530201['previousPosition']),_0x1db828=!0x0):_0x4ffaff=_0x4ffaff||_0x530201['previousPosition']));}function _0x117e71(_0x5a3e5c){const _0x46dada=_0x335126['mapper']['toViewPosition'](_0x5a3e5c),_0xf947da=_0x335126['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x29bb6e});_0x335126['writer']['insert'](_0x46dada,_0xf947da),_0x335126['mapper']['bindElementToMarker'](_0xf947da,_0x112a3e['markerName']);}_0x490a45||_0x1db828||!_0x4ffaff||_0x117e71(_0x4ffaff);};}class mt extends _0x4e2556{constructor(_0x2cf3b6){super(_0x2cf3b6);const _0x3e9158=_0x2cf3b6['plugins']['get'](m);this['affectsData']=!0x1,this['listenTo'](_0x3e9158,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x3e9158,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x4b93b3=this['editor'],_0x3880d4=_0x4b93b3['plugins']['get'](m),_0x380fba=_0x3880d4['isReady']?_0x3880d4['diff']['newRevisionId']:null;_0x4b93b3['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x380fba);}['refresh'](){const {isReady:_0x5c0806,isEnabled:_0x8df273,repository:_0x28ac1f,diff:_0x4f07e6}=this['editor']['plugins']['get'](m),_0x59c0fa=_0x4f07e6&&_0x28ac1f['getLaterVisibleRevision'](_0x4f07e6['newRevisionId']);this['isEnabled']=_0x5c0806&&_0x8df273&&Boolean(_0x59c0fa);}}class wt extends _0x4e2556{['_step'];constructor(_0x3e8252,{direction:_0xe4957b}){super(_0x3e8252);const _0x15f0b0=_0x3e8252['plugins']['get'](m);this['affectsData']=!0x1,this['_step']='forward'===_0xe4957b?0x1:-0x1,this['listenTo'](_0x15f0b0,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x15f0b0,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x15f0b0,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x507a8f=this['editor'],_0x231b01=_0x507a8f['plugins']['get'](m),{isNavigationMode:_0x8e4c6a,currentChangeNumber:_0x441864}=_0x231b01;let _0x3da299;if(_0x231b01['activeChange']=_0x8e4c6a?_0x231b01['diff']['changes']['get'](_0x441864+this['_step']):_0x231b01['diff']['changes']['first'],_0x231b01['activeChange']['data']['isOnRoot'])_0x3da299=_0x507a8f['editing']['view']['getDomRoot'](_0x231b01['activeChange']['rootName']);else{const _0x2c4bde=_0x507a8f['model']['markers']['get']('revision:'+_0x231b01['activeChange']['id']);_0x3da299=_0x56d34c(_0x507a8f['editing'],_0x2c4bde);}_0x5c8233({'target':_0x3da299,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x48f58a,currentChangeNumber:_0x387bc5,numberOfChanges:_0xda8e19,isReady:_0x185f7b,isEnabled:_0x5a26b1}=this['editor']['plugins']['get'](m);this['isEnabled']=!!(_0x5a26b1&&_0x185f7b&&_0xda8e19)&&(!_0x48f58a||(0x1===this['_step']?_0x387bc5<_0xda8e19-0x1:_0x387bc5>0x0));}}class _i extends ts{constructor(_0x185c0e){super(_0x185c0e);const _0x36d848=this['bindTemplate'],_0x165414=new te(_0x185c0e),_0x2e3234=new te(_0x185c0e);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',(_0x1ab3c7,_0x5bd718)=>_0x1ab3c7&&_0x5bd718>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x30cd6e,_0xdb5d1a,_0x8a873b,_0x59caa4)=>{if(!_0x30cd6e)return g(_0x185c0e,'Loading...');if(!_0x8a873b)return g(_0x185c0e,'No\x20changes');const _0x4e0ada=g(_0x185c0e,'NUMBER_OF_CHANGES',_0x8a873b);return _0x59caa4?g(_0x185c0e,'X_OF_Y_CHANGES',[_0xdb5d1a+0x1,_0x8a873b]):_0x4e0ada;}),_0x165414['set']({'label':g(_0x185c0e,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x1dd0dd}),_0x2e3234['set']({'label':g(_0x185c0e,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x2464b9}),_0x165414['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x2e3234['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x165414['on']('execute',()=>this['fire']('execute','backward')),_0x2e3234['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',_0x36d848['if']('_isStatusLabelVisible','ck-hidden',_0xb94ab9=>!_0xb94ab9)]},'children':[{'text':_0x36d848['to']('isNavigationMode',_0x4d807a=>_0x4d807a?g(_0x185c0e,'EDIT_X_OF_Y_REVISIONS')+':\x20':g(_0x185c0e,'Total')+':\x20')}]},{'text':_0x36d848['to']('_statusText')}]},new _0x32da21(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x165414,_0x2e3234]}]});}}const le='ck-editor__editable__loading-overlay';class ge extends _0x1aaf30{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x2a79ee=this['editor']['editing']['view'];_0x2a79ee['change'](_0x4801bc=>{for(const _0x460236 of _0x2a79ee['document']['roots'])_0x4801bc['addClass'](le,_0x460236);});}['hide'](){const _0x3968d4=this['editor']['editing']['view'];_0x3968d4['change'](_0x1c0e0c=>{for(const _0x196b8a of _0x3968d4['document']['roots'])_0x1c0e0c['removeClass'](le,_0x196b8a);});}}class R extends _0x1aaf30{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[m,ge];}['init'](){const _0x4a77ef=this['editor'],_0x5ef176=_0x4a77ef['plugins']['get'](m),_0x4606da=_0x4a77ef['plugins']['get'](ge);_0x4a77ef['ui']['componentFactory']['add']('exitToEditing',_0x55ef76=>{const _0x3c7fd0=new te(_0x55ef76);return _0x3c7fd0['set']({'label':g(_0x55ef76,'Back\x20to\x20editing'),'icon':_0x5c9b99,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x3c7fd0,'execute',()=>{_0x4a77ef['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x3c7fd0;}),_0x4a77ef['ui']['componentFactory']['add']('restoreRevision',_0x473232=>{const _0x4356bd=new te(_0x473232);return _0x4356bd['set']({'label':g(_0x473232,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x4356bd['bind']('isEnabled')['to'](_0x4a77ef['commands']['get']('restoreRevision')),this['listenTo'](_0x4356bd,'execute',()=>_0x4a77ef['execute']('restoreRevision')),_0x4356bd;}),_0x4a77ef['ui']['componentFactory']['add']('changesNavigation',_0x2d6c44=>{const _0x2e645c=new _i(_0x2d6c44),_0x54dafa=_0x4a77ef['commands']['get']('showPreviousChange'),_0x198d2f=_0x4a77ef['commands']['get']('showNextChange');return _0x2e645c['bind']('isBackwardNavigationEnabled')['to'](_0x54dafa,'isEnabled'),_0x2e645c['bind']('isForwardNavigationEnabled')['to'](_0x198d2f,'isEnabled'),_0x2e645c['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x5ef176),this['listenTo'](_0x2e645c,'execute',(_0x2caa70,_0x569c45)=>{_0x4a77ef['execute']('forward'===_0x569c45?'showNextChange':'showPreviousChange');}),_0x2e645c;}),_0x4606da['show'](),_0x5ef176['on']('change:isReady',(_0x505125,_0x4f8666,_0x5166f0)=>{_0x5166f0?_0x4606da['hide']():_0x4606da['show']();});}}class at extends _0x21d0c2{['_resizeObserver']=null;constructor(_0x5e112f,_0x5c29ce){super(_0x5e112f,_0x5c29ce);const _0x1dc56a=this['bindTemplate'];this['set']({'label':g(_0x5e112f,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=g(_0x5e112f,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x1dc56a['to']('_tooltipString'),'data-cke-tooltip-position':'s','data-cke-tooltip-class':'ck-tooltip_multi-line'}});}['render'](){super['render'](),this['_resizeObserver']=new nt(this['fieldView']['element'],()=>this['_updateTooltipText']()),this['listenTo'](this['fieldView'],'input',()=>this['_updateTooltipText']());}['destroy'](){super['destroy'](),this['_resizeObserver']&&this['_resizeObserver']['destroy']();}['_updateTooltipText'](){const _0xb98629=this['fieldView']['element'];this['_tooltipString']=_0xb98629['scrollWidth']>_0xb98629['clientWidth']&&_0xb98629['value']||'';}}class si extends ts{constructor(_0x3e9072,_0x57e0a3,_0x6c7c89){super(_0x3e9072);const _0x4c84e8=new _0x5c83c3();_0x4c84e8['set']({'content':_0x3c4811,'viewBox':'0\x200\x2011\x2010'});const _0x5a5c5c=['ck','ck-revision-history-sidebar__revision-author'];_0x6c7c89&&_0x5a5c5c['push']('ck-revision-history-sidebar__revision-author_creator');const _0x5d1050=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':g(_0x3e9072,_0x6c7c89?'Revision\x20creator':'Revision\x20author')},'children':[_0x4c84e8,_0x57e0a3['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x5a5c5c},'children':_0x5d1050});}}function oi(_0x516a20,_0x5b7c37){const _0x171103=_0x516a20['bindTemplate'],_0x2b1fda=_0x516a20['locale'],_0x1b7a26=_0x3baa9b(_0x2b1fda);_0x1b7a26['panelPosition']='sw';const _0x445a72=function(_0x228694,_0x1b07d1){const _0x1d79ba=function(_0x488611,_0x139e63){const _0x1834aa=_0x488611['locale'],_0x54aa9c={'Compare\x20against\x20selected':g(_0x1834aa,'Compare\x20against\x20selected'),'Name\x20this\x20revision':g(_0x1834aa,'Name\x20this\x20revision'),'Restore\x20this\x20revision':g(_0x1834aa,'Restore\x20this\x20revision')};return _0x139e63['map'](_0x4b89e5=>{const _0x5bd130=_0x54aa9c[_0x4b89e5['name']];return _0x5bd130&&_0x5bd130!==_0x4b89e5['name']&&(_0x4b89e5['name']=_0x5bd130),_0x4b89e5;});}(_0x228694,_0x1b07d1),_0x3d1524=new _0x5f0faf();for(const _0x49fe37 of _0x1d79ba){const _0x5f52ea={'type':'button','model':new to({'label':_0x49fe37['name'],'class':_0x49fe37['class'],'withText':!0x0,'role':'menuitem','_action':_0x49fe37['action']})};_0x5f52ea['model']['bind']('isEnabled')['to'](_0x228694,'isActionsDropdownOpen',_0x55e741=>'function'!=typeof _0x49fe37['isEnabled']||(!_0x55e741||_0x49fe37['isEnabled'](_0x228694))),_0x3d1524['add'](_0x5f52ea);}return _0x3d1524;}(_0x516a20,_0x5b7c37);return _0x516a20['bind']('isActionsDropdownOpen')['to'](_0x1b7a26,'isOpen'),_0x1b7a26['buttonView']['set']({'label':g(_0x2b1fda,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x45dd43}),_0x1b7a26['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x171103['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x171103['to'](_0x1cf960=>_0x1cf960['stopPropagation']())}}),_0x1b7a26['on']('execute',_0x257435=>{_0x516a20['isReady']&&'function'==typeof _0x257435['source']['_action']&&_0x257435['source']['_action'](_0x516a20);}),_0x11596f(_0x1b7a26,_0x445a72,{'role':'menu'}),_0x1b7a26['listenTo'](_0x516a20,'change:isActionsDropdownOpen',(_0x583077,_0x3ea725,_0xedd763)=>{if(_0xedd763)for(const _0x2649c0 of _0x1b7a26['listView']['items']){const _0x143dad=_0x2649c0['children']['first'],_0x44d063=_0x5b7c37['find'](_0x5c0cf6=>_0x5c0cf6['action']===_0x143dad['_action'])['isVisible'];_0x2649c0['isVisible']=void 0x0===_0x44d063||_0x44d063(_0x516a20);}}),_0x1b7a26;}class hi extends/* #__PURE__ -- @preserve */
26
+ ti(ts){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x5914f0,_0x46d5fa,_0x4c1777,_0x56b60f){super(_0x5914f0);const _0x1202de=this['bindTemplate'],_0x156d53=function(_0x74da23,_0x3855e4){const _0x516a15=Array['from'](_0x3855e4['authors'])['filter'](_0x38e63e=>_0x38e63e!=_0x3855e4['creator']);return _0x3855e4['creator']&&_0x516a15['unshift'](_0x3855e4['creator']),_0x516a15['map'](_0x445e93=>new si(_0x74da23,_0x445e93,_0x445e93==_0x3855e4['creator']));}(_0x5914f0,_0x46d5fa);this['id']=_0x46d5fa['id'],this['_revision']=_0x46d5fa,this['_requireRevisionName']=_0x56b60f,this['bind']('name','createdAt')['to'](_0x46d5fa),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x41e878=>{return _0x23f422=_0x5914f0['uiLanguage'],(_0x595cc9=_0x41e878)['toLocaleDateString'](_0x23f422,{'month':'long','day':'numeric'})+',\x20'+_0x595cc9['toLocaleTimeString'](_0x23f422,{'hour':'numeric','minute':'numeric'});var _0x23f422,_0x595cc9;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new at(_0x5914f0,_0x1a6c7a),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x4555f2=>_0x4555f2||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x5f431f,_0xf35c9d)=>_0x5f431f&&_0xf35c9d),this['revisionActionsView']=_0x4c1777&&_0x4c1777['length']?oi(this,_0x4c1777):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x1202de['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x1202de['if']('isEnabled','ck-disabled',_0x44b436=>!_0x44b436),_0x1202de['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x1202de['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x1202de['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':_0x1202de['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':_0x156d53}]},this['revisionActionsView']],'on':{'click':_0x1202de['to'](_0x195aa7=>{_0x195aa7['srcElement']['closest']('.ck-thread__remove-confirm')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x46b222=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x46b222,'change',()=>{this['_requireRevisionName']&&!_0x46b222['value']||this['fire']('setName',{'id':this['id'],'name':_0x46b222['value']}),_0x46b222['value']||(_0x46b222['value']=this['name']?this['name']:this['_createdAtFormatted']);});}['select'](){this['isSelected']=!0x0;}['deselect'](){this['isSelected']=!0x1;}['highlight'](){this['isHighlighted']=!0x0;}['unhighlight'](){this['isHighlighted']=!0x1;}}function ai(_0x362a4b,_0x18f798){const _0x1619ab=_0x3c368c['fromJSDate'](_0x362a4b)['setLocale'](_0x18f798),_0x18580a=_0x3c368c['local'](),_0x9c024f=_0x18580a['minus']({'days':0x1})['startOf']('day');let _0x5b7d3b,_0x1c51f0;return _0x1619ab['hasSame'](_0x18580a,'day')?(_0x5b7d3b=_0x1619ab['startOf']('day')['toJSDate'](),_0x1c51f0=_0x1619ab['toRelativeCalendar']()):_0x1619ab['hasSame'](_0x9c024f,'day')?(_0x5b7d3b=_0x9c024f['toJSDate'](),_0x1c51f0=_0x1619ab['toRelativeCalendar']()):_0x1619ab['hasSame'](_0x18580a,'week')?(_0x5b7d3b=_0x1619ab['startOf']('week')['toJSDate'](),_0x1c51f0=_0x1619ab['weekdayLong']||''):_0x1619ab['hasSame'](_0x18580a,'year')?(_0x5b7d3b=_0x1619ab['startOf']('month')['toJSDate'](),_0x1c51f0=_0x1619ab['monthLong']||''):(_0x5b7d3b=_0x1619ab['startOf']('year')['toJSDate'](),_0x1c51f0=String(_0x1619ab['year'])),{'startDate':_0x5b7d3b,'localizedPeriodName':_0x1c51f0};}class di extends ts{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x41bf9b,_0x94d0fa,_0x24d661,_0x5efbc0){super(_0x41bf9b);const _0x335e41=ai(_0x94d0fa,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x94d0fa,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x24d661,this['_requireRevisionName']=_0x5efbc0,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':_0x335e41}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x433110){const _0x54f131=new hi(this['locale'],_0x433110,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x54f131);}['removeRevision'](_0x2cd2ee){const _0x4c8acd=this['revisionViews']['find'](_0x2a164b=>_0x2a164b['id']===_0x2cd2ee['id']);this['revisionViews']['remove'](_0x4c8acd);}}class as extends ts{constructor(_0x53a4bf){super(_0x53a4bf);const _0x2b3827=new _0x5c83c3();_0x2b3827['content']=_0x2aae82,this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x2b3827,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[g(_0x53a4bf,'Revision\x20history')]}]});}}class ni extends ts{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x4f9c20,_0x5e9747,_0x8c5b8b,_0x282f9b){super(_0x4f9c20);const _0x517cd2=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x5e9747,this['_revisionActions']=_0x8c5b8b,this['_requireRevisionName']=_0x282f9b,this['on']('select',(_0x597762,_0x11be36)=>{this['fire']('revisionSelected',_0x11be36);}),this['on']('setName',(_0x22f856,_0x274d9d)=>{this['fire']('revisionSetName',_0x274d9d);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new as(_0x4f9c20),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x517cd2['if']('isEnabled','ck-disabled',_0x1f2fb0=>!_0x1f2fb0)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x4904c7 of this['_revisions'])this['_addRevision'](_0x4904c7);this['_revisions']['on']('add',(_0x4eb560,_0x5354b5)=>{this['_addRevision'](_0x5354b5);}),this['_revisions']['on']('remove',(_0x4c082a,_0x43d8b6)=>{this['_removeRevision'](_0x43d8b6);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x4f08a7=>_0x4f08a7['revisionViews']['map'](_0x598382=>_0x598382))['flat']();}['selectRevision'](_0x4b7580){for(const _0x486dcd of this['revisionViews'])_0x4b7580&&_0x4b7580['id']===_0x486dcd['id']?_0x486dcd['select']():_0x486dcd['deselect']();}['highlightRevisions'](_0x45f93a){for(const _0x3bb45f of this['revisionViews'])_0x45f93a['some'](({id:_0x45ca67})=>_0x45ca67===_0x3bb45f['id'])?_0x3bb45f['highlight']():_0x3bb45f['unhighlight']();}['_addRevision'](_0xeb9bf4){const _0x32323e=ai(_0xeb9bf4['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x1d0937=this['timePeriodViews']['get'](0x0);_0x1d0937&&_0x1d0937['startDate']['getTime']()===_0x32323e['getTime']()||(_0x1d0937=new di(this['locale'],_0x32323e,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x1d0937)),_0x1d0937['addRevision'](_0xeb9bf4);}['_removeRevision'](_0x25e8f2){const _0x10b90c=ai(_0x25e8f2['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x10b90c)['removeRevision'](_0x25e8f2);}['_getTimePeriodViewByStartDate'](_0x68bfcb){return this['timePeriodViews']['find'](_0x15f26f=>_0x15f26f['startDate']['getTime']()===_0x68bfcb['getTime']());}}class d extends _0x1aaf30{['_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(_0x398c48){super(_0x398c48),this['_revisionViewer']=_0x398c48['plugins']['get'](m),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x2eee59=this['_revisionsRepository']['_revisions'],_0x4552b4=this['_createRevisionActions'](),_0x103ff2=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new di(this['editor']['locale'],_0x2eee59,_0x4552b4,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',(_0x507d6b,_0x4f559b)=>{_0x4f559b['revisionViews']['on']('add',(_0x2aeea6,_0x9b27fe)=>{_0x9b27fe['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)),_0x103ff2['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x2a6eb4=this['_revisionsRepository']['getRevision'](0x0);if(_0x2a6eb4){const _0x411be4=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x2a6eb4['id']);this['_revisionViewer']['compare'](_0x2a6eb4,_0x411be4);}}['_handleRevisionSelected'](_0x467250,_0x5141f4){const _0x18e099=this['_revisionsRepository']['getRevision'](_0x5141f4['id']),_0x1cfbc9=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x18e099['id']);this['_revisionViewer']['compare'](_0x18e099,_0x1cfbc9);}['_handleRevisionSetName'](_0x56b867,_0x449ad1){this['_revisionsRepository']['getRevision'](_0x449ad1['id'])['setName'](_0x449ad1['name']);}['_handleDiffChange'](_0x11309f,_0xd3160c,_0x20e24c){const _0x1d20de=this['_revisionsRepository']['getRevisionsInDiff'](_0x20e24c);_0x1d20de['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x1d20de),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x1d20de[0x0]));}['_createRevisionActions'](){const _0x4278d5=this['editor'],_0x3c7332=d['availableRevisionActions'],_0x36b9f4=_0x4278d5['config']['get']('revisionHistory.revisionActions')||d['defaultRevisionActions'];if(_0x36b9f4['length'])return _0x36b9f4['map'](_0x25a89e=>{const _0x57fc27='string'==typeof _0x25a89e?Object['assign']({},_0x3c7332[_0x25a89e]):_0x25a89e;return _0x57fc27['action']=_0x57fc27['action']['bind'](this,_0x4278d5),_0x57fc27['isVisible']&&(_0x57fc27['isVisible']=_0x57fc27['isVisible']['bind'](this,_0x4278d5)),_0x57fc27;});}}function _t(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x5a0a76},_0x420333)=>{const _0x4c0173=_0x5a0a76['get'](m),_0x3845c4=_0x4c0173['repository'];let _0x588831=_0x4c0173['diff']['newRevisionId'],_0x9f8b58=_0x420333['id'];_0x3845c4['getIndex'](_0x588831)>_0x3845c4['getIndex'](_0x9f8b58)&&([_0x588831,_0x9f8b58]=[_0x9f8b58,_0x588831]),_0x4c0173['compare'](_0x588831,_0x9f8b58);},'isVisible':({plugins:_0x3b4a1d},_0x3382c8)=>{const _0x2116dc=_0x3b4a1d['get'](m);return!(_0x2116dc['repository']['getRevisionsInDiff'](_0x2116dc['diff'])['length']>0x2)&&!_0x3382c8['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x483153,{id:_0xaf2fb0})=>{_0x483153['config']['get']('revisionHistory')['restoreRevisionCallback'](_0xaf2fb0);},'isVisible':({plugins:_0x4190c6},_0x3de30e)=>!!_0x4190c6['get'](m)['repository']['getLaterVisibleRevision'](_0x3de30e['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x279955},{id:_0x120ff0,revisionNameView:_0x1ffe98})=>{const _0x484af0=_0x279955['get'](m),_0x1e02f0=_0x484af0['repository']['getEarlierVisibleRevision'](_0x120ff0);_0x484af0['compare'](_0x120ff0,_0x1e02f0),_0x1ffe98['focus'](),_0x1ffe98['fieldView']['select']();}}};}class tt extends st{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x31c9b1,_0x5ad157){super(_0x31c9b1),this['_view']=_0x5ad157,this['_toolbarConfig']=et(_0x31c9b1['config']['get']('toolbar')),this['_elementReplacer']=new ot();}get['element'](){return this['view']['element'];}['init'](_0x235fea){const _0x2943b2=this['editor'],_0x2520a7=this['view'],_0x1db35c=_0x2943b2['editing']['view'],_0x54cf6d=_0x2520a7['editable'],_0x211a9d=_0x1db35c['document']['getRoot']();_0x54cf6d['name']=_0x211a9d['rootName'],_0x2520a7['render']();const _0x24cc8f=_0x54cf6d['element'];this['setEditableElement'](_0x54cf6d['name'],_0x24cc8f),_0x2520a7['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x1db35c['attachDomRoot'](_0x24cc8f),this['_elementReplacer']['replace'](_0x235fea,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x2d6972=this['view'],_0xe6c6ca=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0xe6c6ca['detachDomRoot'](_0x2d6972['editable']['name']),_0x2d6972['destroy']();}['_initToolbar'](){const _0x2bb23e=this['view'];_0x2bb23e['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x2bb23e['stickyPanel']['limiterElement']=_0x2bb23e['element'],_0x2bb23e['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x42c247})=>_0x42c247),_0x2bb23e['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x2bb23e['toolbar']);}}class it extends rt{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x406d85,_0x2a1fa3,_0x172c66={}){super(_0x406d85),this['stickyPanel']=new ht(_0x406d85),this['toolbar']=new dt(_0x406d85,{'shouldGroupWhenFull':_0x172c66['shouldToolbarGroupWhenFull']}),this['_editable']=new ct(_0x406d85,_0x2a1fa3);}['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
- _0xb0c17c(_0x344b4b){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x1de7b6,_0x5b1ded){super(_0x5b1ded),this['sourceElement']=_0x1de7b6,this['model']['document']['createRoot']();const _0x215861=new it(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new tt(this,_0x215861);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x359dc3,_0x1220bb){const _0x19eb75=new this(_0x359dc3,_0x1220bb);return await _0x19eb75['initPlugins'](),await _0x19eb75['ui']['init'](_0x359dc3),await _0x19eb75['data']['init'](_0x19eb75['config']['get']('initialData')||''),_0x19eb75['fire']('ready'),_0x19eb75;}}const p=['RevisionHistoryUI','RestrictedEditingMode'];class yt extends _0x47ebf6{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x2a23b2){function _0x16e1fc(_0x51d1ce){return _0x51d1ce['map'](_0x14aac8=>String['fromCharCode'](_0x14aac8))['join']('');}super(_0x2a23b2),this['result']='end',_0x2a23b2[_0x16e1fc([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x16e1fc([0x76,0x69,0x65,0x77])][_0x16e1fc([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x16e1fc([0x61,0x75,0x74,0x6f]),_0x2a23b2[_0x16e1fc([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x16e1fc([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x16e1fc([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x16e1fc([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x16e1fc([0x6f,0x6b])});}}class k extends _0x47ebf6{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u,f];}constructor(_0x35cfdc){if(super(_0x35cfdc),!this['editor']['config']['get']('revisionHistory'))throw new _0x49f01a('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x1edb26=>this['_showRevisionViewer']({..._0x1edb26,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x14d32e=>this['_closeRevisionViewer'](_0x14d32e)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x60ef40=>this['_restoreRevision'](_0x60ef40)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x4bb550){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x4bb550;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x38bb5){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x38bb5);}['getRevision'](_0x14e897){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x14e897);}['getRevisions'](_0x5b4647){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x5b4647||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x27f734=this['editor'],_0x593b87=_0x22939f(_0x27f734,p),_0x5ceb49=_0x27f734['plugins']['get']('RevisionTracker'),_0x33bf09=_0x27f734['plugins']['get']('Users')['users'];return _0x593b87['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x593b87['lazyRoots'],(_0x593b87['plugins']['push'](yt,m,R,class extends _0x47ebf6{static get['requires'](){return[m,'Users'];}['init'](){const _0x283d87=this['editor']['plugins']['get']('Users');for(const _0x1e7653 of _0x33bf09)_0x1e7653['isAnonymous']||_0x283d87['getUser'](_0x1e7653['id'])||_0x283d87['addUser'](_0x1e7653);const _0x4f0df4=_0x5ceb49['repository']['getRevisions']();let _0x17e174=null;const _0x3d8fd3=this['editor']['plugins']['get']('RevisionViewer');_0x3d8fd3['adapter']=_0x5ceb49['adapter'],_0x3d8fd3['bind']('isEnabled')['to'](_0x5ceb49),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x27f734,'isReadOnly',_0x1a3978=>!_0x1a3978);for(const _0x21e31d of _0x4f0df4){const _0x2e0612=null===_0x21e31d['creator'];if(_0x2e0612&&_0x21e31d['toVersion']===_0x21e31d['fromVersion'])continue;const _0xbf1997=_0x21e31d['toJSON']();_0x3d8fd3['addRevisionData'](_0xbf1997,(_0x410214,_0x5d2740,_0x2cd431)=>{if(_0x2e0612){if(_0x17e174)_0x17e174['_update'](_0x410214,_0x5d2740);else{if(!_0x5d2740){const _0x210f96=_0x2cd431['toJSON']();_0x210f96['id']=_0x4339db(),_0x5ceb49['saveRevision'](_0x210f96,_0x2cd431['toVersion'])['then'](_0x10309f=>{_0x17e174=_0x10309f;});}}}else _0x21e31d['_update'](_0x410214,_0x5d2740);});}}},d),_0x593b87);}['_enhanceShowRevisionViewerCallback'](){const _0x3a3e0e=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x198c35=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x2d3fdf=this['editor']['plugins']['get']('Autosave');await _0x2d3fdf['save']();}else await _0x198c35['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x3f2d53=this['editor']['plugins']['get']('Dialog');_0x3f2d53['isOpen']&&_0x3f2d53['hide']();}const _0x17f042=this['_getRevisionViewerEditorConfig']();return _0x3a3e0e(_0x17f042)['then'](_0x1be6b0=>{return(this['_viewerEditor']=_0x1be6b0,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'),_0x1be6b0);})['catch'](_0x144c16=>(console['error'](_0x144c16),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x5602f8=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'](),_0x5602f8(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x192c72=this['editor']['plugins']['get']('Annotations');_0x192c72['refreshVisibility'](),_0x192c72['refreshPositioning']();}})));}['_showRevisionViewer'](_0x3567be){const _0x529ecf=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x27c84c=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x34c9b6=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return w['create'](_0x34c9b6,_0x3567be)['then'](_0x506f35=>(_0x27c84c['style']['display']='block',_0x529ecf['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x506f35));}['_closeRevisionViewer'](_0x4bc46d){const _0x4721fe=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x4721fe['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x4bc46d['destroy']();}async['_restoreRevision'](_0x240274){const _0x33e272=this['editor'],_0x2a1cf6=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x489c84=_0x33e272['plugins']['get']('RevisionTracker'),_0x57efe1=_0x33e272['plugins']['get']('RevisionHistoryUtils'),_0x4225fa=_0x2a1cf6['repository']['getRevision'](_0x240274);let _0x59661d,_0xd56d13,_0x527f5f;try{await _0x57efe1['loadRevisionData'](_0x4225fa,this['adapter']),_0x59661d=_0x57efe1['getRevisionDocumentData'](_0x4225fa),_0xd56d13=_0x57efe1['getRevisionRootsAttributes'](_0x4225fa);}catch(_0x50edb7){return void console['error'](_0x50edb7);}_0x33e272['model']['change'](_0x24759f=>{for(const _0x584d9a of Array['from'](_0x33e272['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x24759f['removeMarker'](_0x584d9a);}),_0x2a1cf6['isReady']=!0x1,_0x33e272['model']['enqueueChange'](_0x1ee65c=>{_0x1ee65c['setSelection'](null),_0x1ee65c['removeSelectionAttribute'](_0x33e272['model']['document']['selection']['getAttributeKeys']());const _0x39cf6c=Object['keys'](_0x59661d);for(const _0x440ca2 of _0x33e272['model']['document']['roots'])'$graveyard'!=_0x440ca2['rootName']&&_0x440ca2['isAttached']()&&!_0x39cf6c['includes'](_0x440ca2['rootName'])&&_0x1ee65c['detachRoot'](_0x440ca2);for(const _0x5d95e4 of _0x39cf6c){let _0x45e4f7=_0x33e272['model']['document']['getRoot'](_0x5d95e4);_0x45e4f7&&_0x45e4f7['isAttached']()||(_0x45e4f7=_0x1ee65c['addRoot'](_0x5d95e4));const _0x3bce07=_0xd56d13[_0x5d95e4],_0x3d9926=Object['keys'](_0x3bce07),_0x5408b6=_0x59661d[_0x5d95e4];for(const _0x351afb of _0x45e4f7['getAttributeKeys']())_0x3d9926['includes'](_0x351afb)||_0x1ee65c['removeAttribute'](_0x351afb,_0x45e4f7);for(const _0x47aedd of _0x3d9926)_0x1ee65c['setAttribute'](_0x47aedd,_0xd56d13[_0x5d95e4][_0x47aedd],_0x45e4f7);_0x1ee65c['remove'](_0x1ee65c['createRangeIn'](_0x45e4f7)),_0x1ee65c['insert'](_0x33e272['data']['parse'](_0x5408b6,_0x45e4f7),_0x45e4f7,0x0);}});const _0xfa7302=g(_0x33e272['locale'],'Restored');if(_0x4225fa['name'])_0x527f5f=-0x1==_0x4225fa['name']['indexOf'](_0xfa7302)?_0xfa7302+':\x20'+_0x4225fa['name']:_0x4225fa['name'];else _0x527f5f=_0xfa7302+':\x20'+(_0x4225fa['createdAt']['toLocaleDateString'](_0x33e272['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x4225fa['createdAt']['toLocaleTimeString'](_0x33e272['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x489c84['saveRevision']({'name':_0x527f5f}),_0x2a1cf6['isReady']=!0x0,_0x33e272['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
+ pt();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[m];}constructor(_0xabefbb){super(_0xabefbb),this['_revisionViewer']=_0xabefbb['plugins']['get'](m),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x236004=this['_revisionsRepository']['_revisions'],_0x59f4d4=this['_createRevisionActions'](),_0x3a7396=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new ni(this['editor']['locale'],_0x236004,_0x59f4d4,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',(_0x2f388e,_0x2064a2)=>{_0x2064a2['revisionViews']['on']('add',(_0x5688c5,_0x2c500d)=>{_0x2c500d['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)),_0x3a7396['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x1a3e02=this['_revisionsRepository']['getRevision'](0x0);if(_0x1a3e02){const _0x48d440=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x1a3e02['id']);this['_revisionViewer']['compare'](_0x1a3e02,_0x48d440);}}['_handleRevisionSelected'](_0x51352e,_0x1380fc){const _0x39ec26=this['_revisionsRepository']['getRevision'](_0x1380fc['id']),_0x57f315=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x39ec26['id']);this['_revisionViewer']['compare'](_0x39ec26,_0x57f315);}['_handleRevisionSetName'](_0x5e2768,_0x12b5d4){this['_revisionsRepository']['getRevision'](_0x12b5d4['id'])['setName'](_0x12b5d4['name']);}['_handleDiffChange'](_0x57acb8,_0x34d426,_0x810393){const _0x245dc9=this['_revisionsRepository']['getRevisionsInDiff'](_0x810393);_0x245dc9['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x245dc9),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x245dc9[0x0]));}['_createRevisionActions'](){const _0x2f03af=this['editor'],_0x1d3947=d['availableRevisionActions'],_0x3b8d6c=_0x2f03af['config']['get']('revisionHistory.revisionActions')||d['defaultRevisionActions'];if(_0x3b8d6c['length'])return _0x3b8d6c['map'](_0x45ed3c=>{const _0xeaca4='string'==typeof _0x45ed3c?Object['assign']({},_0x1d3947[_0x45ed3c]):_0x45ed3c;return _0xeaca4['action']=_0xeaca4['action']['bind'](this,_0x2f03af),_0xeaca4['isVisible']&&(_0xeaca4['isVisible']=_0xeaca4['isVisible']['bind'](this,_0x2f03af)),_0xeaca4;});}}function pt(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x1062c7},_0x10af43)=>{const _0x29cf78=_0x1062c7['get'](m),_0x5e5706=_0x29cf78['repository'];let _0x2ad85e=_0x29cf78['diff']['newRevisionId'],_0x233207=_0x10af43['id'];_0x5e5706['getIndex'](_0x2ad85e)>_0x5e5706['getIndex'](_0x233207)&&([_0x2ad85e,_0x233207]=[_0x233207,_0x2ad85e]),_0x29cf78['compare'](_0x2ad85e,_0x233207);},'isVisible':({plugins:_0x5df2d0},_0x257607)=>{const _0x36b917=_0x5df2d0['get'](m);return!(_0x36b917['repository']['getRevisionsInDiff'](_0x36b917['diff'])['length']>0x2)&&!_0x257607['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x14fafc,{id:_0x542110})=>{_0x14fafc['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x542110);},'isVisible':({plugins:_0x1d9f65},_0x327d84)=>!!_0x1d9f65['get'](m)['repository']['getLaterVisibleRevision'](_0x327d84['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x352c2c},{id:_0xb359d6,revisionNameView:_0x140850})=>{const _0x291e74=_0x352c2c['get'](m),_0x43b2c2=_0x291e74['repository']['getEarlierVisibleRevision'](_0xb359d6);_0x291e74['compare'](_0xb359d6,_0x43b2c2),_0x140850['focus'](),_0x140850['fieldView']['select']();}}};}class tt extends st{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0xc3f22b,_0x36eee1){super(_0xc3f22b),this['_view']=_0x36eee1,this['_toolbarConfig']=et(_0xc3f22b['config']['get']('toolbar')),this['_elementReplacer']=new ot();}get['element'](){return this['view']['element'];}['init'](_0x91efdb){const _0x17cb19=this['editor'],_0x3b6b08=this['view'],_0x596665=_0x17cb19['editing']['view'],_0x5b0aa5=_0x3b6b08['editable'],_0x52e62b=_0x596665['document']['getRoot']();_0x5b0aa5['name']=_0x52e62b['rootName'],_0x3b6b08['render']();const _0x37c190=_0x5b0aa5['element'];this['setEditableElement'](_0x5b0aa5['name'],_0x37c190),_0x3b6b08['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x596665['attachDomRoot'](_0x37c190),this['_elementReplacer']['replace'](_0x91efdb,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x2cb75e=this['view'],_0x21041f=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x21041f['detachDomRoot'](_0x2cb75e['editable']['name']),_0x2cb75e['destroy']();}['_initToolbar'](){const _0xbf78ea=this['view'];_0xbf78ea['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0xbf78ea['stickyPanel']['limiterElement']=_0xbf78ea['element'],_0xbf78ea['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x22553e})=>_0x22553e),_0xbf78ea['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0xbf78ea['toolbar']);}}class it extends rt{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x307cb3,_0x14da58,_0x17934d={}){super(_0x307cb3),this['stickyPanel']=new ht(_0x307cb3),this['toolbar']=new dt(_0x307cb3,{'shouldGroupWhenFull':_0x17934d['shouldToolbarGroupWhenFull']}),this['_editable']=new ct(_0x307cb3,_0x14da58);}['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
+ _0x59ee7c(_0x4d07a6){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x2b6457,_0x5b06c2){super(_0x5b06c2),this['sourceElement']=_0x2b6457,this['model']['document']['createRoot']();const _0x494026=new it(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new tt(this,_0x494026);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x2aec87,_0x113d29){const _0x744d05=new this(_0x2aec87,_0x113d29);return await _0x744d05['initPlugins'](),await _0x744d05['ui']['init'](_0x2aec87),await _0x744d05['data']['init'](_0x744d05['config']['get']('initialData')||''),_0x744d05['fire']('ready'),_0x744d05;}}const p=['RevisionHistoryUI','RestrictedEditingMode'];class _t extends _0x1aaf30{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x3d41a5){function _0x1410d2(_0x4bca6b){return _0x4bca6b['map'](_0x3f8755=>String['fromCharCode'](_0x3f8755))['join']('');}super(_0x3d41a5),this['result']='end',_0x3d41a5[_0x1410d2([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x1410d2([0x76,0x69,0x65,0x77])][_0x1410d2([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x1410d2([0x61,0x75,0x74,0x6f]),_0x3d41a5[_0x1410d2([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x1410d2([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x1410d2([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x1410d2([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x1410d2([0x6f,0x6b])});}}class k extends _0x1aaf30{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u,f];}constructor(_0x38d3c3){if(super(_0x38d3c3),!this['editor']['config']['get']('revisionHistory'))throw new _0xae2ed9('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x2dee4b=>this['_showRevisionViewer']({..._0x2dee4b,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x4ee88e=>this['_closeRevisionViewer'](_0x4ee88e)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x4b0203=>this['_restoreRevision'](_0x4b0203)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x27c44d){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x27c44d;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x4c175e){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x4c175e);}['getRevision'](_0x36743f){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x36743f);}['getRevisions'](_0x24df06){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x24df06||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x55f90c=this['editor'],_0x14eb21=_0x1a3df8(_0x55f90c,p),_0x291f29=_0x55f90c['plugins']['get']('RevisionTracker'),_0x171e4a=_0x55f90c['plugins']['get']('Users')['users'];return _0x14eb21['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x14eb21['lazyRoots'],(_0x14eb21['plugins']['push'](_t,m,R,class extends _0x1aaf30{static get['requires'](){return[m,'Users'];}['init'](){const _0x4186ea=this['editor']['plugins']['get']('Users');for(const _0x547a3a of _0x171e4a)_0x547a3a['isAnonymous']||_0x4186ea['getUser'](_0x547a3a['id'])||_0x4186ea['addUser'](_0x547a3a);const _0x1ca21c=_0x291f29['repository']['getRevisions']();let _0x4c7f14=null;const _0x2604de=this['editor']['plugins']['get']('RevisionViewer');_0x2604de['adapter']=_0x291f29['adapter'],_0x2604de['bind']('isEnabled')['to'](_0x291f29),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x55f90c,'isReadOnly',_0x2a7e73=>!_0x2a7e73);for(const _0xf049e6 of _0x1ca21c){const _0x546116=null===_0xf049e6['creator'];if(_0x546116&&_0xf049e6['toVersion']===_0xf049e6['fromVersion'])continue;const _0x3b7b00=_0xf049e6['toJSON']();_0x2604de['addRevisionData'](_0x3b7b00,(_0x26fe5a,_0x12ba1f,_0x1966a1)=>{if(_0x546116){if(_0x4c7f14)_0x4c7f14['_update'](_0x26fe5a,_0x12ba1f);else{if(!_0x12ba1f){const _0x2c127e=_0x1966a1['toJSON']();_0x2c127e['id']=_0x3fbd15(),_0x291f29['saveRevision'](_0x2c127e,_0x1966a1['toVersion'])['then'](_0xfaf9f8=>{_0x4c7f14=_0xfaf9f8;});}}}else _0xf049e6['_update'](_0x26fe5a,_0x12ba1f);});}}},d),_0x14eb21);}['_enhanceShowRevisionViewerCallback'](){const _0xfd2ea0=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x439ed8=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0xa23ba8=this['editor']['plugins']['get']('Autosave');await _0xa23ba8['save']();}else await _0x439ed8['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x1f2822=this['editor']['plugins']['get']('Dialog');_0x1f2822['isOpen']&&_0x1f2822['hide']();}const _0x3694b5=this['_getRevisionViewerEditorConfig']();return _0xfd2ea0(_0x3694b5)['then'](_0x573569=>{return(this['_viewerEditor']=_0x573569,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'),_0x573569);})['catch'](_0x17da8a=>(console['error'](_0x17da8a),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x28e8f5=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'](),_0x28e8f5(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x40093d=this['editor']['plugins']['get']('Annotations');_0x40093d['refreshVisibility'](),_0x40093d['refreshPositioning']();}})));}['_showRevisionViewer'](_0x5ec48f){const _0x361f4a=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x531910=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x5b3db5=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return w['create'](_0x5b3db5,_0x5ec48f)['then'](_0x349e9c=>(_0x531910['style']['display']='block',_0x361f4a['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x349e9c));}['_closeRevisionViewer'](_0x328c30){const _0x2c3c23=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x2c3c23['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x328c30['destroy']();}async['_restoreRevision'](_0x51075b){const _0x4d7c9f=this['editor'],_0x1c4e51=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x12b085=_0x4d7c9f['plugins']['get']('RevisionTracker'),_0x161fe1=_0x4d7c9f['plugins']['get']('RevisionHistoryUtils'),_0xc328a9=_0x1c4e51['repository']['getRevision'](_0x51075b);let _0x5c5700,_0x1d9eba,_0x3d135d;try{await _0x161fe1['loadRevisionData'](_0xc328a9,this['adapter']),_0x5c5700=_0x161fe1['getRevisionDocumentData'](_0xc328a9),_0x1d9eba=_0x161fe1['getRevisionRootsAttributes'](_0xc328a9);}catch(_0x10640a){return void console['error'](_0x10640a);}_0x4d7c9f['model']['change'](_0xc97bc9=>{for(const _0x41a47a of Array['from'](_0x4d7c9f['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0xc97bc9['removeMarker'](_0x41a47a);}),_0x1c4e51['isReady']=!0x1,_0x4d7c9f['model']['enqueueChange'](_0x245ffa=>{_0x245ffa['setSelection'](null),_0x245ffa['removeSelectionAttribute'](_0x4d7c9f['model']['document']['selection']['getAttributeKeys']());const _0x211775=Object['keys'](_0x5c5700);for(const _0x1582a9 of _0x4d7c9f['model']['document']['roots'])'$graveyard'!=_0x1582a9['rootName']&&_0x1582a9['isAttached']()&&!_0x211775['includes'](_0x1582a9['rootName'])&&_0x245ffa['detachRoot'](_0x1582a9);for(const _0x404d2c of _0x211775){let _0x405ae6=_0x4d7c9f['model']['document']['getRoot'](_0x404d2c);_0x405ae6&&_0x405ae6['isAttached']()||(_0x405ae6=_0x245ffa['addRoot'](_0x404d2c));const _0x27694d=_0x1d9eba[_0x404d2c],_0x2a3a61=Object['keys'](_0x27694d),_0x3590d0=_0x5c5700[_0x404d2c];for(const _0x19506d of _0x405ae6['getAttributeKeys']())_0x2a3a61['includes'](_0x19506d)||_0x245ffa['removeAttribute'](_0x19506d,_0x405ae6);for(const _0x3b4b0d of _0x2a3a61)_0x245ffa['setAttribute'](_0x3b4b0d,_0x1d9eba[_0x404d2c][_0x3b4b0d],_0x405ae6);_0x245ffa['remove'](_0x245ffa['createRangeIn'](_0x405ae6)),_0x245ffa['insert'](_0x4d7c9f['data']['parse'](_0x3590d0,_0x405ae6),_0x405ae6,0x0);}});const _0x4a5f65=g(_0x4d7c9f['locale'],'Restored');if(_0xc328a9['name'])_0x3d135d=-0x1==_0xc328a9['name']['indexOf'](_0x4a5f65)?_0x4a5f65+':\x20'+_0xc328a9['name']:_0xc328a9['name'];else _0x3d135d=_0x4a5f65+':\x20'+(_0xc328a9['createdAt']['toLocaleDateString'](_0x4d7c9f['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0xc328a9['createdAt']['toLocaleTimeString'](_0x4d7c9f['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x12b085['saveRevision']({'name':_0x3d135d}),_0x1c4e51['isReady']=!0x0,_0x4d7c9f['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{h as Revision,k as RevisionHistory,f as RevisionHistoryUI,V as RevisionHistoryUtils,u as RevisionTracker,m as RevisionViewer,w as RevisionViewerEditor,ge as RevisionViewerLoadingOverlay,R as RevisionViewerUI,I as RevisionsRepository,d as RevisionsSidebar};