@ckeditor/ckeditor5-revision-history 44.1.0-alpha.1 → 44.1.0-alpha.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (177) 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/bg.js +1 -1
  12. package/dist/translations/bg.umd.js +1 -1
  13. package/dist/translations/bn.js +1 -1
  14. package/dist/translations/bn.umd.js +1 -1
  15. package/dist/translations/bs.js +1 -1
  16. package/dist/translations/bs.umd.js +1 -1
  17. package/dist/translations/ca.js +1 -1
  18. package/dist/translations/ca.umd.js +1 -1
  19. package/dist/translations/cs.js +1 -1
  20. package/dist/translations/cs.umd.js +1 -1
  21. package/dist/translations/da.js +1 -1
  22. package/dist/translations/da.umd.js +1 -1
  23. package/dist/translations/de-ch.js +1 -1
  24. package/dist/translations/de-ch.umd.js +1 -1
  25. package/dist/translations/de.js +1 -1
  26. package/dist/translations/de.umd.js +1 -1
  27. package/dist/translations/el.js +1 -1
  28. package/dist/translations/el.umd.js +1 -1
  29. package/dist/translations/en-au.js +1 -1
  30. package/dist/translations/en-au.umd.js +1 -1
  31. package/dist/translations/en-gb.js +1 -1
  32. package/dist/translations/en-gb.umd.js +1 -1
  33. package/dist/translations/en.js +1 -1
  34. package/dist/translations/en.umd.js +1 -1
  35. package/dist/translations/eo.js +1 -1
  36. package/dist/translations/eo.umd.js +1 -1
  37. package/dist/translations/es-co.js +1 -1
  38. package/dist/translations/es-co.umd.js +1 -1
  39. package/dist/translations/es.js +1 -1
  40. package/dist/translations/es.umd.js +1 -1
  41. package/dist/translations/et.js +1 -1
  42. package/dist/translations/et.umd.js +1 -1
  43. package/dist/translations/eu.js +1 -1
  44. package/dist/translations/eu.umd.js +1 -1
  45. package/dist/translations/fa.js +1 -1
  46. package/dist/translations/fa.umd.js +1 -1
  47. package/dist/translations/fi.js +1 -1
  48. package/dist/translations/fi.umd.js +1 -1
  49. package/dist/translations/fr.js +1 -1
  50. package/dist/translations/fr.umd.js +1 -1
  51. package/dist/translations/gl.js +1 -1
  52. package/dist/translations/gl.umd.js +1 -1
  53. package/dist/translations/gu.js +1 -1
  54. package/dist/translations/gu.umd.js +1 -1
  55. package/dist/translations/he.js +1 -1
  56. package/dist/translations/he.umd.js +1 -1
  57. package/dist/translations/hi.js +1 -1
  58. package/dist/translations/hi.umd.js +1 -1
  59. package/dist/translations/hr.js +1 -1
  60. package/dist/translations/hr.umd.js +1 -1
  61. package/dist/translations/hu.js +1 -1
  62. package/dist/translations/hu.umd.js +1 -1
  63. package/dist/translations/hy.js +1 -1
  64. package/dist/translations/hy.umd.js +1 -1
  65. package/dist/translations/id.js +1 -1
  66. package/dist/translations/id.umd.js +1 -1
  67. package/dist/translations/it.js +1 -1
  68. package/dist/translations/it.umd.js +1 -1
  69. package/dist/translations/ja.js +1 -1
  70. package/dist/translations/ja.umd.js +1 -1
  71. package/dist/translations/jv.js +1 -1
  72. package/dist/translations/jv.umd.js +1 -1
  73. package/dist/translations/kk.js +1 -1
  74. package/dist/translations/kk.umd.js +1 -1
  75. package/dist/translations/km.js +1 -1
  76. package/dist/translations/km.umd.js +1 -1
  77. package/dist/translations/kn.js +1 -1
  78. package/dist/translations/kn.umd.js +1 -1
  79. package/dist/translations/ko.js +1 -1
  80. package/dist/translations/ko.umd.js +1 -1
  81. package/dist/translations/ku.js +1 -1
  82. package/dist/translations/ku.umd.js +1 -1
  83. package/dist/translations/lt.js +1 -1
  84. package/dist/translations/lt.umd.js +1 -1
  85. package/dist/translations/lv.js +1 -1
  86. package/dist/translations/lv.umd.js +1 -1
  87. package/dist/translations/ms.js +1 -1
  88. package/dist/translations/ms.umd.js +1 -1
  89. package/dist/translations/nb.js +1 -1
  90. package/dist/translations/nb.umd.js +1 -1
  91. package/dist/translations/ne.js +1 -1
  92. package/dist/translations/ne.umd.js +1 -1
  93. package/dist/translations/nl.js +1 -1
  94. package/dist/translations/nl.umd.js +1 -1
  95. package/dist/translations/no.js +1 -1
  96. package/dist/translations/no.umd.js +1 -1
  97. package/dist/translations/oc.js +1 -1
  98. package/dist/translations/oc.umd.js +1 -1
  99. package/dist/translations/pl.js +1 -1
  100. package/dist/translations/pl.umd.js +1 -1
  101. package/dist/translations/pt-br.js +1 -1
  102. package/dist/translations/pt-br.umd.js +1 -1
  103. package/dist/translations/pt.js +1 -1
  104. package/dist/translations/pt.umd.js +1 -1
  105. package/dist/translations/ro.js +1 -1
  106. package/dist/translations/ro.umd.js +1 -1
  107. package/dist/translations/ru.js +1 -1
  108. package/dist/translations/ru.umd.js +1 -1
  109. package/dist/translations/si.js +1 -1
  110. package/dist/translations/si.umd.js +1 -1
  111. package/dist/translations/sk.js +1 -1
  112. package/dist/translations/sk.umd.js +1 -1
  113. package/dist/translations/sl.js +1 -1
  114. package/dist/translations/sl.umd.js +1 -1
  115. package/dist/translations/sq.js +1 -1
  116. package/dist/translations/sq.umd.js +1 -1
  117. package/dist/translations/sr-latn.js +1 -1
  118. package/dist/translations/sr-latn.umd.js +1 -1
  119. package/dist/translations/sr.js +1 -1
  120. package/dist/translations/sr.umd.js +1 -1
  121. package/dist/translations/sv.js +1 -1
  122. package/dist/translations/sv.umd.js +1 -1
  123. package/dist/translations/th.js +1 -1
  124. package/dist/translations/th.umd.js +1 -1
  125. package/dist/translations/ti.js +1 -1
  126. package/dist/translations/ti.umd.js +1 -1
  127. package/dist/translations/tk.js +1 -1
  128. package/dist/translations/tk.umd.js +1 -1
  129. package/dist/translations/tr.js +1 -1
  130. package/dist/translations/tr.umd.js +1 -1
  131. package/dist/translations/tt.js +1 -1
  132. package/dist/translations/tt.umd.js +1 -1
  133. package/dist/translations/ug.js +1 -1
  134. package/dist/translations/ug.umd.js +1 -1
  135. package/dist/translations/uk.js +1 -1
  136. package/dist/translations/uk.umd.js +1 -1
  137. package/dist/translations/ur.js +1 -1
  138. package/dist/translations/ur.umd.js +1 -1
  139. package/dist/translations/uz.js +1 -1
  140. package/dist/translations/uz.umd.js +1 -1
  141. package/dist/translations/vi.js +1 -1
  142. package/dist/translations/vi.umd.js +1 -1
  143. package/dist/translations/zh-cn.js +1 -1
  144. package/dist/translations/zh-cn.umd.js +1 -1
  145. package/dist/translations/zh.js +1 -1
  146. package/dist/translations/zh.umd.js +1 -1
  147. package/package.json +8 -8
  148. package/src/changeitem.js +2 -2
  149. package/src/editor/revisionviewereditor.js +2 -2
  150. package/src/editor/revisionviewereditorui.js +1 -1
  151. package/src/editor/revisionviewereditoruiview.js +1 -1
  152. package/src/index.js +1 -1
  153. package/src/revision.js +2 -2
  154. package/src/revisiondiff.js +1 -1
  155. package/src/revisionhistory.js +1 -1
  156. package/src/revisionsrepository.js +1 -1
  157. package/src/revisiontracker.js +1 -1
  158. package/src/revisionviewer.js +1 -1
  159. package/src/ui/revision/createrevisionactionsdropdown.js +1 -1
  160. package/src/ui/revision/revisionauthorview.js +1 -1
  161. package/src/ui/revision/revisionnameview.js +1 -1
  162. package/src/ui/revision/revisionview.js +2 -2
  163. package/src/ui/revision/subrevisioncollapserview.js +1 -1
  164. package/src/ui/revision/subrevisionview.js +1 -1
  165. package/src/ui/revision/utils.js +1 -1
  166. package/src/ui/revisionhistory/revisionhistorysaverevisionformview.js +1 -1
  167. package/src/ui/revisionhistory/revisionhistoryui.js +1 -1
  168. package/src/ui/revisionssidebar/revisionssidebar.js +1 -1
  169. package/src/ui/revisionssidebar/revisionssidebarheaderview.js +1 -1
  170. package/src/ui/revisionssidebar/revisionssidebartimeperiodview.js +1 -1
  171. package/src/ui/revisionssidebar/revisionssidebarview.js +1 -1
  172. package/src/ui/revisionssidebar/utils.js +1 -1
  173. package/src/ui/revisionviewer/changedetailsview.js +1 -1
  174. package/src/ui/revisionviewer/changesnavigationview.js +1 -1
  175. package/src/ui/revisionviewer/revisionviewerloadingoverlay.js +1 -1
  176. package/src/ui/revisionviewer/revisionviewerui.js +1 -1
  177. 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 _0xa03473,uid as _0x27b216,Collection as _0x2987a6,logWarning as _0x1f7d34,FocusTracker as _0x2d7a0c,KeystrokeHandler as _0x10c3da,scrollViewportToShowTarget as _0x2beaa4,ResizeObserver as at,ElementReplacer as ct,CKEditorError as _0xa442d4}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x3f361f,set as _0x57bcb5,unset as _0x30d47d,isEqual as _0x1b45fa}from'lodash-es';import{Plugin as _0x27f686,PendingActions as _0x56e4b7,icons as _0x57211a,Command as _0x347c79,ElementApiMixin as rt,Editor as it}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x17470c,getMarkerDomElement as _0x2a2631,ConfirmMixin as _0x5d9caa,sanitizeEditorConfig as _0x25e631}from'ckeditor5-collaboration/dist/index.js';import{ViewDocumentFragment as _0x48dd3c,ViewText as _0xb834d4,ViewElement as _0x3d7190,Element as ft,Range as vt,Position as gt,DocumentFragment as mt,ViewContainerElement as _0x5a71b7,ViewAttributeElement as _0x5c54c2,ViewEmptyElement as _0xc8c1e6,ViewRawElement as _0x5e32f8,ViewUIElement as _0x255215,Text as wt}from'@ckeditor/ckeditor5-engine/dist/index.js';import{View as ts,injectCssTransitionDisabler as _0x449c03,submitHandler as _0x5577d8,LabeledFieldView as _0x1ea983,createLabeledInputText as _0x57df33,createDropdown as _0x47635c,ListView as _0x253ba0,ListItemView as _0x950cf2,ButtonView as te,MenuBarMenuView as _0x1f15bb,MenuBarMenuListView as _0x5723a7,MenuBarMenuListItemView as _0x185366,MenuBarMenuListItemButtonView as _0x1bff1f,ContextualBalloon as _0x16945d,ToolbarSeparatorView as _0x43f5d3,IconView as _0x3e2bc7,addListToDropdown as to,ViewModel as _0x573354,EditorUI as ot,normalizeToolbarConfig as ht,BoxedEditorUIView as dt,StickyPanelView as lt,ToolbarView as nt,InlineEditableUIView as ut}from'@ckeditor/ckeditor5-ui/dist/index.js';import{DateTime as _0x30e612}from'luxon';class a extends/* #__PURE__ -- @preserve */
24
- _0xa03473(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x9cde84){super(),this['id']=_0x9cde84['id']||_0x27b216(),this['creator']=_0x9cde84['creator']||null,this['authors']=_0x9cde84['authors']||[],this['diffData']=_0x9cde84['diffData']||null,this['toVersion']=_0x9cde84['toVersion']||0x0,this['fromVersion']=_0x9cde84['fromVersion']||0x0,this['set']('name',_0x9cde84['name']||''),this['set']('createdAt',_0x9cde84['createdAt']||new Date()),this['set']('attributes',_0x9cde84['attributes']||{});}['setName'](_0x45a27f){this['_update']({'name':_0x45a27f});}['setAttribute'](_0x1daf5d,_0x4536ca){const _0x15e9c1=_0x3f361f(this['attributes']);_0x57bcb5(_0x15e9c1,_0x1daf5d,_0x4536ca),this['_update']({'attributes':_0x15e9c1});}['removeAttribute'](_0x453395){const _0x5c71ad=_0x3f361f(this['attributes']);_0x30d47d(_0x5c71ad,_0x453395),this['_update']({'attributes':_0x5c71ad});}['_update'](_0x2c30f6,_0x418a8a=!0x1){let _0x35dfa9=!0x1;const _0x571053={'id':this['id']},_0x266943=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x196ceb of _0x266943){const _0x364fbd=_0x2c30f6[_0x196ceb];void 0x0!==_0x364fbd&&_0x364fbd!==this[_0x196ceb]&&(this[_0x196ceb]=_0x364fbd,_0x571053[_0x196ceb]=_0x364fbd,_0x35dfa9=!0x0);}_0x35dfa9&&(_0x571053['authors']&&(_0x571053['authorsIds']=_0x571053['authors']['map'](_0x2b9a49=>_0x2b9a49['id']),delete _0x571053['authors']),this['fire']('_update',_0x571053,_0x418a8a));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x1183a4=>_0x1183a4['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class j extends _0x27f686{['_revisions'];static get['requires'](){return[_0x17470c];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x25a117){super(_0x25a117),this['_revisions']=new _0x2987a6();}['afterInit'](){!async function(_0x2330ee){const _0x2981c0=_0x42c4f6([0x49,0x76,0x68,0x67,0x34,0x4c,0x75,0x48,0x6d,0x52,0x30,0x6b,0x69,0x4a,0x46,0x66,0x6c,0x39,0x73,0x44,0x65,0x77,0x32,0x64,0x62,0x51,0x36,0x6f,0x54,0x58,0x55,0x33,0x53,0x72,0x79,0x41,0x31,0x47,0x59,0x70,0x71,0x7a,0x50,0x37,0x56,0x35,0x57,0x4d,0x5a,0x78,0x74,0x42,0x45,0x4e,0x61,0x4f,0x4b,0x43,0x6a,0x6e,0x63,0x38]),_0x1d566c=0xeb829,_0x5dc91b=0x58250a0d,_0x48206a=0x58225375^_0x5dc91b,_0x25dcfc=window[_0x42c4f6([0x44,0x61,0x74,0x65])][_0x42c4f6([0x6e,0x6f,0x77])](),_0x361d47=_0x2330ee[_0x42c4f6([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x55acc3=new window[(_0x42c4f6([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x37aad8=>{_0x361d47[_0x42c4f6([0x6f,0x6e,0x63,0x65])](_0x42c4f6([0x72,0x65,0x61,0x64,0x79]),_0x37aad8);}),_0x40e0b9={[_0x42c4f6([0x6b,0x74,0x79])]:_0x42c4f6([0x45,0x43]),[_0x42c4f6([0x75,0x73,0x65])]:_0x42c4f6([0x73,0x69,0x67]),[_0x42c4f6([0x63,0x72,0x76])]:_0x42c4f6([0x50,0x2d,0x32,0x35,0x36]),[_0x42c4f6([0x78])]:_0x42c4f6([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]),[_0x42c4f6([0x79])]:_0x42c4f6([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]),[_0x42c4f6([0x61,0x6c,0x67])]:_0x42c4f6([0x45,0x53,0x32,0x35,0x36])},_0x19a9ef=_0x361d47[_0x42c4f6([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x42c4f6([0x67,0x65,0x74])](_0x42c4f6([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x56bcb0(){let _0x19e680,_0x51c847=null,_0x153fad=null;try{if(_0x19a9ef==_0x42c4f6([0x47,0x50,0x4c]))return _0x42c4f6([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x19e680=_0x83e59a(),!_0x19e680)return _0x42c4f6([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x19e680[_0x42c4f6([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x153fad=_0x281fee(_0x19e680[_0x42c4f6([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x19e680[_0x42c4f6([0x6a,0x74,0x69])])),await _0x4a9c28()?_0x399169()?_0x57ea80()?_0x42c4f6([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x4bea57()?(_0x19e680[_0x42c4f6([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x42c4f6([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x51c847=_0x2c72ac(_0x42c4f6([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x19e680[_0x42c4f6([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x42c4f6([0x74,0x72,0x69,0x61,0x6c])&&(_0x51c847=_0x2c72ac(_0x42c4f6([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),_0x19e680[_0x42c4f6([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x42c4f6([0x64,0x65,0x76,0x65,0x6c,0x6f,0x70,0x6d,0x65,0x6e,0x74])&&(_0x51c847=_0x2c72ac(_0x42c4f6([0x44,0x65,0x76,0x65,0x6c,0x6f,0x70,0x6d,0x65,0x6e,0x74,0x4c,0x69,0x6d,0x69,0x74]))),await _0x2b8ebc()):_0x42c4f6([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x42c4f6([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x42c4f6([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch(_0x5cac94){return _0x42c4f6([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x57ea80(){const _0x2c5d06=[_0x42c4f6([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x42c4f6([0x74,0x72,0x69,0x61,0x6c])][_0x42c4f6([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x19e680[_0x42c4f6([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x25dcfc/0x3e8:0xe10*_0x48206a;return _0x19e680[_0x42c4f6([0x65,0x78,0x70])]<_0x2c5d06;}function _0x399169(){const _0x41ef52=_0x19e680[_0x42c4f6([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x41ef52)return!0x1;if(_0x41ef52[_0x42c4f6([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x42c4f6([0x2a])))return!0x0;if(_0x41ef52[_0x42c4f6([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x42c4f6([0x52,0x48])))return!0x0;if(_0x41ef52[_0x42c4f6([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x42c4f6([0x52,0x52,0x48]))){if(_0x9ef89a())return!0x0;if(_0x5741cb()||_0x430e69())return!0x0;}return!0x1;}function _0x4bea57(){const _0x392a2c=_0x19e680[_0x42c4f6([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x392a2c||0x0==_0x392a2c[_0x42c4f6([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x1cc0f5}=new URL(window[_0x42c4f6([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x392a2c[_0x42c4f6([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x1cc0f5))return!0x0;const _0xe8a958=_0x1cc0f5[_0x42c4f6([0x73,0x70,0x6c,0x69,0x74])](_0x42c4f6([0x2e]));return _0x392a2c[_0x42c4f6([0x66,0x69,0x6c,0x74,0x65,0x72])](_0xd9b7a2=>_0xd9b7a2[_0x42c4f6([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x42c4f6([0x2a])))[_0x42c4f6([0x6d,0x61,0x70])](_0x5afc57=>_0x5afc57[_0x42c4f6([0x73,0x70,0x6c,0x69,0x74])](_0x42c4f6([0x2e])))[_0x42c4f6([0x73,0x6f,0x6d,0x65])](_0x3eb722=>_0xe8a958[_0x42c4f6([0x65,0x76,0x65,0x72,0x79])]((_0x8347be,_0x5cfbfb)=>_0x3eb722[_0x5cfbfb]===_0x8347be||_0x3eb722[_0x5cfbfb]===_0x42c4f6([0x2a])));}function _0x2b8ebc(){return _0x51c847&&_0x153fad?new window[(_0x42c4f6([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x5313cc,_0x93788b)=>{_0x51c847[_0x42c4f6([0x74,0x68,0x65,0x6e])](_0x5313cc,_0x93788b),_0x153fad[_0x42c4f6([0x74,0x68,0x65,0x6e])](_0x3c9796=>{_0x3c9796!=_0x42c4f6([0x56,0x61,0x6c,0x69,0x64])&&_0x5313cc(_0x3c9796);},_0x93788b);}):_0x51c847||_0x153fad||_0x42c4f6([0x56,0x61,0x6c,0x69,0x64]);}}function _0x281fee(_0x23fa63,_0xad0276){return new window[(_0x42c4f6([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x1baf47=>{if(_0x3fd344())return _0x1baf47(_0x42c4f6([0x56,0x61,0x6c,0x69,0x64]));_0x2a27b2(),_0x361d47[_0x42c4f6([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x42c4f6([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x4a5724=!0x1;const _0x34c3e6=_0x27b216();function _0x5ec68b(_0x573b23){return!!_0x573b23&&(typeof _0x573b23===_0x42c4f6([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x573b23===_0x42c4f6([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x573b23[_0x42c4f6([0x74,0x68,0x65,0x6e])]===_0x42c4f6([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x573b23[_0x42c4f6([0x63,0x61,0x74,0x63,0x68])]===_0x42c4f6([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x4e2b72(_0x462d3f){_0x552a80(_0x462d3f)[_0x42c4f6([0x74,0x68,0x65,0x6e])](_0x118475=>{if(!_0x118475||_0x118475[_0x42c4f6([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x42c4f6([0x6f,0x6b]))return _0x42c4f6([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x4ce462(_0x4e56ab(_0x34c3e6+_0xad0276))!=_0x118475[_0x42c4f6([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x42c4f6([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x42c4f6([0x56,0x61,0x6c,0x69,0x64]);})[_0x42c4f6([0x74,0x68,0x65,0x6e])](_0x23c49a=>(_0x52e527(),_0x23c49a),()=>{const _0x545711=_0x24ce80();return null==_0x545711?(_0x52e527(),_0x42c4f6([0x56,0x61,0x6c,0x69,0x64])):_0x42c4f6(_0x25dcfc-_0x545711>(0x7c298e0d^_0x5dc91b)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x42c4f6([0x74,0x68,0x65,0x6e])](_0x1baf47)[_0x42c4f6([0x63,0x61,0x74,0x63,0x68])](()=>{_0x1baf47(_0x42c4f6([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x4e6b94=0x5813e48d^_0x5dc91b;function _0x52e527(){const _0x455bc2=_0x42c4f6([0x6c,0x6c,0x63,0x74,0x2d])+_0x4ce462(_0x4e56ab(_0x23fa63)),_0xf07366=_0x3d4de6(_0x4ce462(window[_0x42c4f6([0x4d,0x61,0x74,0x68])][_0x42c4f6([0x63,0x65,0x69,0x6c])](_0x25dcfc/_0x4e6b94)));window[_0x42c4f6([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x42c4f6([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x455bc2,_0xf07366);}function _0x24ce80(){const _0xbc70c6=_0x42c4f6([0x6c,0x6c,0x63,0x74,0x2d])+_0x4ce462(_0x4e56ab(_0x23fa63)),_0x483c25=window[_0x42c4f6([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x42c4f6([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0xbc70c6);return _0x483c25?window[_0x42c4f6([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x3d4de6(_0x483c25),0x10)*_0x4e6b94:null;}function _0x552a80(_0x406d0d){return new window[(_0x42c4f6([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x56e535,_0x353470)=>{_0x406d0d[_0x42c4f6([0x74,0x68,0x65,0x6e])](_0x56e535,_0x353470),window[_0x42c4f6([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x353470,0x5824decd^_0x5dc91b);});}}_0x361d47[_0x42c4f6([0x6f,0x6e])](_0x42c4f6([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x2ecad2,_0x53e3f1)=>{if(_0x53e3f1[0x0]!=_0x23fa63)return _0x1baf47(_0x42c4f6([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x53e3f1[0x1]={..._0x53e3f1[0x1],[_0x42c4f6([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x34c3e6};},{[_0x42c4f6([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x42c4f6([0x68,0x69,0x67,0x68])}),_0x361d47[_0x42c4f6([0x6f,0x6e])](_0x42c4f6([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x1fadbc=>{_0x5ec68b(_0x1fadbc[_0x42c4f6([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x4a5724=!0x0,_0x4e2b72(_0x1fadbc[_0x42c4f6([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x42c4f6([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x42c4f6([0x6c,0x6f,0x77])}),_0x55acc3[_0x42c4f6([0x74,0x68,0x65,0x6e])](()=>{_0x4a5724||_0x1baf47(_0x42c4f6([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x3fd344(){return _0x361d47[_0x42c4f6([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x42c4f6([0x76,0x69,0x65,0x77])][_0x42c4f6([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x42c4f6([0x61,0x75,0x74,0x6f]);}function _0x2a27b2(){_0x361d47[_0x42c4f6([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x42c4f6([0x76,0x69,0x65,0x77])][_0x42c4f6([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x42c4f6([0x61,0x75,0x74,0x6f]);}}function _0x2c72ac(_0x2f4874){const _0x92ffcc=[new window[(_0x42c4f6([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x55a31e=>setTimeout(_0x55a31e,0x582c34c1^_0x5dc91b)),_0x55acc3[_0x42c4f6([0x74,0x68,0x65,0x6e])](()=>new window[(_0x42c4f6([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x4ccaa7=>{const _0x327c88=0x58250a0a^_0x5dc91b,_0x4d6b78=_0x2330ee[_0x42c4f6([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x583c35(){_0x4d6b78[_0x42c4f6([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x327c88&&_0x4ccaa7();}_0x583c35(),_0x4d6b78[_0x42c4f6([0x6f,0x6e])](_0x42c4f6([0x61,0x64,0x64]),_0x583c35);})),new window[(_0x42c4f6([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x21607c=>{function _0x5c5496(){for(const _0x42f493 in window)if(window[_0x42c4f6([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x42c4f6([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x42f493))&&window[_0x42f493]==_0x1d566c)return _0x21607c();_0x361d47[_0x42c4f6([0x73,0x74,0x61,0x74,0x65])]!=_0x42c4f6([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x42c4f6([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x5c5496,0x58251985^_0x5dc91b);}_0x3f27cf(_0x42c4f6([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x5c5496();})];return window[_0x42c4f6([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x42c4f6([0x72,0x61,0x63,0x65])](_0x92ffcc)[_0x42c4f6([0x74,0x68,0x65,0x6e])](()=>_0x2f4874);}async function _0x15e222(){if(await _0x55acc3,_0x3f27cf(_0x42c4f6([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x521bf0=_0x2330ee[_0x42c4f6([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x242c8f=_0x2330ee[_0x42c4f6([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])](_0x521bf0[_0x42c4f6([0x69,0x64])]),_0x2f0d39=_0x451027(_0x42c4f6([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x2f0d39[_0x42c4f6([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x521bf0['id'],_0x242c8f?_0x242c8f['id']:null,!0x0),_0x2f0d39[_0x42c4f6([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x42c4f6([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x2f0d39[_0x42c4f6([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x2f0d39[_0x42c4f6([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x4d6201,void(_0x2f0d39[_0x42c4f6([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x4d6201);}if(_0x3f27cf(_0x42c4f6([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x472dd5=_0x451027(_0x42c4f6([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x472dd5[_0x42c4f6([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x42c4f6([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x472dd5[_0x42c4f6([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x472dd5[_0x42c4f6([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x4d6201,_0x472dd5[_0x42c4f6([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x4d6201;}_0x361d47[_0x42c4f6([0x6d,0x6f,0x64,0x65,0x6c])][_0x42c4f6([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x4d6201,_0x361d47[_0x42c4f6([0x6d,0x6f,0x64,0x65,0x6c])][_0x42c4f6([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x4d6201,_0x361d47[_0x42c4f6([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x42c4f6([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x9ef89a(){return _0x3f27cf(_0x42c4f6([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x451027(_0x42c4f6([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x42c4f6([0x73,0x74,0x61,0x74,0x65])]==_0x42c4f6([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x5741cb(){return _0x3f27cf(_0x42c4f6([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 _0x430e69(){return _0x3f27cf(_0x42c4f6([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0xaacd93(_0x21617f){const _0x1a6071=_0x3b280e();_0x361d47[_0x1a6071]=_0x42c4f6([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])+_0x21617f,_0x21617f[_0x42c4f6([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x42c4f6([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x3b280e()]=_0x1d566c),_0x21617f!=_0x42c4f6([0x56,0x61,0x6c,0x69,0x64])&&_0x15e222();}function _0x3b280e(){const _0x1f426b=window[_0x42c4f6([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x42c4f6([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x42c4f6([0x6e,0x6f,0x77])]())[_0x42c4f6([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x42c4f6([0x2e]),'');let _0x56c0d=_0x42c4f6([0x49]);for(let _0x40e9b0=0x0;_0x40e9b0<_0x1f426b[_0x42c4f6([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x40e9b0+=0x2){let _0x1ae561=window[_0x42c4f6([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x1f426b[_0x42c4f6([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x40e9b0,_0x40e9b0+0x2));_0x1ae561>=_0x2981c0[_0x42c4f6([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x1ae561-=_0x2981c0[_0x42c4f6([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x56c0d+=_0x2981c0[_0x1ae561];}return _0x56c0d;}function _0x83e59a(){const _0x586157=_0x19a9ef[_0x42c4f6([0x73,0x70,0x6c,0x69,0x74])](_0x42c4f6([0x2e]));if(0x3!=_0x586157[_0x42c4f6([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x1b44c3(_0x586157[0x1]);function _0x1b44c3(_0x273f5b){const _0x5a0217=_0x277733(_0x273f5b);return _0x5a0217&&_0x11584f()?_0x5a0217:null;function _0x11584f(){const _0x4aca51=_0x5a0217[_0x42c4f6([0x6a,0x74,0x69])],_0x38e398=window[_0x42c4f6([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x4aca51[_0x42c4f6([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x4aca51[_0x42c4f6([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x6cc02a={..._0x5a0217,[_0x42c4f6([0x6a,0x74,0x69])]:_0x4aca51[_0x42c4f6([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x4aca51[_0x42c4f6([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x6cc02a[_0x42c4f6([0x76,0x63])],_0x4e56ab(_0x6cc02a)==_0x38e398;}}}async function _0x4a9c28(){let _0x554dab=!0x0;try{const _0x10798d=_0x19a9ef[_0x42c4f6([0x73,0x70,0x6c,0x69,0x74])](_0x42c4f6([0x2e])),[_0x59b714,_0x955098,_0x1b8e41]=_0x10798d;return _0x20bf33(_0x59b714),await _0x121abb(_0x59b714,_0x955098,_0x1b8e41),_0x554dab;}catch(_0x254cb8){return!0x1;}function _0x20bf33(_0x43d659){const _0x2c7160=_0x277733(_0x43d659);_0x2c7160&&_0x2c7160[_0x42c4f6([0x61,0x6c,0x67])]==_0x42c4f6([0x45,0x53,0x32,0x35,0x36])||(_0x554dab=!0x1);}async function _0x121abb(_0x197aed,_0x2022c3,_0x2c7042){const _0x10adf5=window[_0x42c4f6([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x42c4f6([0x66,0x72,0x6f,0x6d])](_0x349721(_0x2c7042),_0x2d5efa=>_0x2d5efa[_0x42c4f6([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x10e3fb=new window[(_0x42c4f6([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x42c4f6([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x197aed+_0x42c4f6([0x2e])+_0x2022c3),_0x165f7a=window[_0x42c4f6([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x42c4f6([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x165f7a)return;const _0x2de2cf=await _0x165f7a[_0x42c4f6([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x42c4f6([0x6a,0x77,0x6b]),_0x40e0b9,{[_0x42c4f6([0x6e,0x61,0x6d,0x65])]:_0x42c4f6([0x45,0x43,0x44,0x53,0x41]),[_0x42c4f6([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x42c4f6([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x42c4f6([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x165f7a[_0x42c4f6([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x42c4f6([0x6e,0x61,0x6d,0x65])]:_0x42c4f6([0x45,0x43,0x44,0x53,0x41]),[_0x42c4f6([0x68,0x61,0x73,0x68])]:{[_0x42c4f6([0x6e,0x61,0x6d,0x65])]:_0x42c4f6([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x2de2cf,_0x10adf5,_0x10e3fb)||(_0x554dab=!0x1);}}function _0x277733(_0x39188b){return _0x39188b[_0x42c4f6([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x42c4f6([0x65,0x79]))?JSON[_0x42c4f6([0x70,0x61,0x72,0x73,0x65])](_0x349721(_0x39188b)):null;}function _0x349721(_0x24bd90){return window[_0x42c4f6([0x61,0x74,0x6f,0x62])](_0x24bd90[_0x42c4f6([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x42c4f6([0x2b]))[_0x42c4f6([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x42c4f6([0x2f])));}function _0x4e56ab(_0x2bc957){let _0x460151=0x1505;function _0x1c78f1(_0x47cd00){for(let _0x3da8b6=0x0;_0x3da8b6<_0x47cd00[_0x42c4f6([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x3da8b6++){const _0x3481a6=_0x47cd00[_0x42c4f6([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x3da8b6);_0x460151=(_0x460151<<0x5)+_0x460151+_0x3481a6,_0x460151&=_0x460151;}}function _0x3a8f03(_0x5702f3){Array[_0x42c4f6([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x5702f3)?_0x5702f3[_0x42c4f6([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x3a8f03):_0x5702f3&&typeof _0x5702f3==_0x42c4f6([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x42c4f6([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x5702f3)[_0x42c4f6([0x73,0x6f,0x72,0x74])]()[_0x42c4f6([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x54a32c,_0x12a34a])=>{_0x1c78f1(_0x54a32c),_0x3a8f03(_0x12a34a);}):_0x1c78f1(window[_0x42c4f6([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x5702f3));}return _0x3a8f03(_0x2bc957),_0x460151>>>0x0;}function _0x4ce462(_0x341b63){return _0x341b63[_0x42c4f6([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x42c4f6([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x42c4f6([0x30]));}function _0x3d4de6(_0x9f8c99){return _0x9f8c99[_0x42c4f6([0x73,0x70,0x6c,0x69,0x74])]('')[_0x42c4f6([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x42c4f6([0x6a,0x6f,0x69,0x6e])]('');}function _0x3f27cf(_0x240cd4){return _0x361d47[_0x42c4f6([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x42c4f6([0x68,0x61,0x73])](_0x240cd4);}function _0x451027(_0x46b585){return _0x361d47[_0x42c4f6([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x42c4f6([0x67,0x65,0x74])](_0x46b585);}function _0x4d6201(){}function _0x42c4f6(_0x1f598e){return _0x1f598e['map'](_0x785e02=>String['fromCharCode'](_0x785e02))['join']('');}_0xaacd93(await _0x56bcb0());}(this);}['createRevision'](_0x232443){const _0x5c07a4=this['editor']['plugins']['get']('Users');return new a({'id':_0x232443['id'],'name':_0x232443['name'],'creator':_0x232443['creatorId']?_0x5c07a4['getUser'](_0x232443['creatorId']):null,'diffData':_0x232443['diffData']||_0x232443['data'],'authors':_0x232443['authorsIds']['map'](_0x375273=>_0x5c07a4['getUser'](_0x375273)),'createdAt':new Date(_0x232443['createdAt']),'attributes':_0x232443['attributes'],'fromVersion':_0x232443['fromVersion'],'toVersion':_0x232443['toVersion']});}['addRevision'](_0x1fdf49,_0x34b083=0x0){this['_revisions']['add'](_0x1fdf49,_0x34b083);}['getRevision'](_0x45ec84){return this['_revisions']['get'](_0x45ec84);}['getRevisions'](_0x16d4f5={'toJSON':!0x1}){const _0x5892e4=Array['from'](this['_revisions']);return _0x5892e4['reverse'](),_0x16d4f5['toJSON']?_0x5892e4['map'](_0x41abd6=>_0x41abd6['toJSON']()):_0x5892e4;}['getIndex'](_0x4b4953){return this['_revisions']['getIndex'](_0x4b4953);}['getEarlierVisibleRevision'](_0xd6b312){const [,_0x108ced]=this['getRevisionsIterator'](_0xd6b312,{'direction':'earlier'});return _0x108ced;}['getLaterVisibleRevision'](_0x46e760){const [,_0x10a1b2]=this['getRevisionsIterator'](_0x46e760,{'direction':'later'});return _0x10a1b2;}['getRevisionsInDiff'](_0x35e1cb){const _0x4944a3=[];for(const _0x562eb0 of this['getRevisionsIterator'](_0x35e1cb['newRevisionId']))if(_0x4944a3['push'](_0x562eb0),_0x562eb0['id']===_0x35e1cb['oldRevisionId'])break;return _0x4944a3;}*['getRevisionsIterator'](_0x54a745,{direction:_0x715f7e='earlier',filter:_0x321fad=()=>!0x0}={}){const _0x18e457='earlier'===_0x715f7e?0x1:-0x1;let _0x328d2f=this['_revisions']['get'](_0x54a745),_0xa417a2=this['getIndex'](_0x328d2f);for(yield _0x328d2f;_0x328d2f;){if(_0xa417a2+=_0x18e457,_0x328d2f=this['getRevision'](_0xa417a2),!_0x328d2f)return;_0x321fad(_0x328d2f)&&(yield _0x328d2f);}}}function R(_0x44f862,_0x464e86,_0x37eecc){const t=_0x44f862['t'];switch(_0x464e86){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'},_0x37eecc);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x37eecc);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'';}}const C={'c':_0x5a71b7,'a':_0x5c54c2,'e':_0xc8c1e6,'r':_0x5e32f8,'u':_0x255215};class l extends _0x27f686{['licenseKey'];['_licenseKeyCheckInterval'];['adapter'];['currentRevision'];['repository'];['_revisionDataBuilder'];['_source'];['_initialRevisionId'];['_bufferedUpdates'];['_pendingAction'];['_continueCurrentRevision'];['_startingVersion'];['_loadedStateData'];static get['pluginName'](){return'RevisionTracker';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[_0x17470c,j,_0x56e4b7];}constructor(_0x484cc0){super(_0x484cc0),this['adapter']=null,this['currentRevision']=null,this['_revisionDataBuilder']=new T(this['editor']),this['_initialRevisionId']=this['editor']['config']['get']('collaboration.channelId')||'initial',this['_bufferedUpdates']=new Map(),this['_loadedStateData']=null;const _0x2b6e79=_0x27b216();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x2b6e79},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['repository']=this['editor']['plugins']['get']('RevisionsRepository'),this['_setConversion'](),this['editor']['data']['on']('ready',()=>{const _0x349b63=this['repository']['getRevision'](0x0),_0x5c785d=_0x349b63&&null===_0x349b63['creator']?_0x349b63:null;if(this['_continueCurrentRevision']=!!_0x5c785d&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x46e323=this['_source']['getCurrentRevisionId'](),_0x411b30=this['repository']['getRevision'](_0x46e323);if(_0x411b30)this['_startingVersion']=_0x411b30['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x145ac6=this['_source']['history']['_operations']['find'](_0x5e94a6=>!_0x5e94a6['_isInit']),_0x317a2c=_0x145ac6?_0x145ac6['baseVersion']:this['_source']['history']['version'];_0x349b63?(_0x349b63['toVersion']<_0x317a2c&&_0x349b63['_update']({'toVersion':_0x317a2c}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x5c785d['id'],this['_startingVersion']=_0x5c785d['fromVersion']):(this['_startingVersion']=_0x349b63['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x317a2c,this['_continueCurrentRevision']=!0x1);}}else _0x5c785d&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x5c785d['toVersion'],this['editor']['model']['document']['history']['version']),_0x5c785d['fromVersion']===_0x5c785d['toVersion']?(0x0!==_0x5c785d['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x5c785d['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x5c785d['id'],this['_startingVersion']=_0x5c785d['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',_0x4653c2=>!_0x4653c2),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x48f990=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x55c5f2;for(const _0x142aef in _0x48f990){const _0x3b0ed6=_0x142aef,_0x2516f0=_0x48f990[_0x3b0ed6];if('revisionHistoryLicenseKeyValid'==_0x2516f0||'revisionHistoryLicenseKeyInvalid'==_0x2516f0||'revisionHistoryLicenseKeyExpired'==_0x2516f0||'revisionHistoryLicenseKeyDomainLimit'==_0x2516f0||'revisionHistoryLicenseKeyNotAllowed'==_0x2516f0||'revisionHistoryLicenseKeyEvaluationLimit'==_0x2516f0||'revisionHistoryLicenseKeyTrialLimit'==_0x2516f0||'revisionHistoryLicenseKeyDevelopmentLimit'==_0x2516f0||'revisionHistoryLicenseKeyUsageLimit'==_0x2516f0){delete _0x48f990[_0x3b0ed6],_0x55c5f2=_0x2516f0,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x55c5f2&&_0x48f990['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x55c5f2&&_0x48f990['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x55c5f2&&_0x48f990['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x55c5f2&&_0x48f990['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x55c5f2&&_0x48f990['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x55c5f2&&_0x48f990['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyDevelopmentLimit'==_0x55c5f2&&_0x48f990['_showLicenseError']('developmentLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x55c5f2&&_0x48f990['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x494964=this['repository']['getRevision'](0x0),_0x4a4dd=await this['getRevisionDocumentData'](_0x494964),_0x1360c8=await this['getRevisionRootsAttributes'](_0x494964);this['_replaceEditorDataWithRevisionData'](_0x4a4dd,_0x1360c8);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x44d2f8){this['_source']=_0x44d2f8;}async['update'](){const _0x2be973=await this['_source']['getLatestVersion']();if(_0x2be973>this['currentRevision']['toVersion']){await this['_loadState']();const _0x16b061=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x2be973});_0x16b061['authors']=_0x16b061['authorsIds']['map'](_0x4b0352=>this['editor']['plugins']['get']('Users')['getUser'](_0x4b0352)),this['currentRevision']['_update'](_0x16b061);}}async['_loadState'](){this['_continueCurrentRevision']&&!this['_loadedStateData']&&(await this['_loadRevisionData'](this['currentRevision']),this['_revisionDataBuilder']['loadState'](this['currentRevision']),this['_loadedStateData']={'fromVersion':this['currentRevision']['fromVersion'],'authors':this['currentRevision']['authors']['slice']()});}async['saveRevision'](_0x249256={},_0x4d7a78=null){const _0x4fb2e4=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x4d7a78>this['currentRevision']['toVersion']&&(_0x4d7a78=null),null===_0x4d7a78&&(_0x4d7a78=await this['_source']['getLatestVersion']());const _0x224422=this['_getFromVersion'](_0x4d7a78),_0x4922b0=this['buildRevisionData']({'from':_0x224422,'to':_0x4d7a78});if(this['currentRevision']['toVersion']<_0x4d7a78){const _0x2baa80=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x4d7a78,'to':_0x4d7a78});_0x2baa80['authors']=[],_0x2baa80['authorsIds']=[],_0x2baa80['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x2baa80,!0x0),delete _0x2baa80['authors'],_0x4fb2e4['push'](_0x2baa80);}_0x249256['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x249256['name']=_0x249256['name']||null,_0x249256['id']=_0x249256['id']||_0x27b216(),_0x249256={..._0x249256,..._0x4922b0};const _0x19c214=this['addRevisionData'](_0x249256);_0x4fb2e4['push'](_0x249256);const _0x5e6182=this['repository']['getIndex'](_0x19c214);if(0x0!==_0x5e6182){const _0x32bb33=this['repository']['getRevision'](_0x5e6182-0x1);if(_0x32bb33['fromVersion']!==_0x4d7a78){const _0x34e58b=this['_revisionDataBuilder']['getData'](_0x4d7a78,_0x32bb33['toVersion']),_0xba429c={'id':_0x32bb33['id'],'diffData':_0x34e58b['diffData'],'authorsIds':_0x34e58b['authorsIds'],'authors':_0x34e58b['authorsIds']['map'](_0x4d19c1=>this['editor']['plugins']['get']('Users')['getUser'](_0x4d19c1)),'fromVersion':_0x4d7a78};_0x32bb33===this['currentRevision']&&(_0xba429c['createdAt']=new Date(_0x249256['createdAt']['getTime']()+0xa)),_0x32bb33['_update'](_0xba429c,!0x0),delete _0xba429c['authors'],_0x4fb2e4['push'](_0xba429c);}}if(this['adapter']){for(const _0x4c64c6 of _0x4fb2e4)this['_bufferUpdate'](_0x4c64c6['id'],_0x4c64c6,!0x0);this['sendBufferedUpdates']();}return _0x19c214;}['addRevisionData'](_0x93e97a){const _0x4b97fa=this['repository']['createRevision'](_0x93e97a);return this['adapter']&&_0x4b97fa['on']('_update',(_0x91a4f0,_0x1be853,_0x2ab6fc)=>{_0x2ab6fc||(this['_bufferUpdate'](_0x1be853['id'],_0x1be853,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x4b97fa,this['_findInsertionIndex'](_0x4b97fa)),_0x4b97fa;}async['getRevisionDocumentData'](_0x2eb600){await this['_loadRevisionData'](_0x2eb600);const _0x4f0898={};for(const _0x1281fb in _0x2eb600['diffData']){if(_0x2eb600['diffData'][_0x1281fb]['attachChange']&&!_0x2eb600['diffData'][_0x1281fb]['attachChange']['isAttached'])continue;const _0x28e393=this['_removeRevisionMarkers'](JSON['parse'](_0x2eb600['diffData'][_0x1281fb]['insertions'])),_0x2232da=this['editor']['editing']['view']['document'],_0xf67c11=new _0x48dd3c(_0x2232da,_0x28e393['map'](_0xb3b5=>V(_0xb3b5,this['editor'])));this['editor']['data']['processor']['useFillerType']('marked'),_0x4f0898[_0x1281fb]=this['editor']['data']['processor']['toData'](_0xf67c11),this['editor']['data']['processor']['useFillerType']('default');}return _0x4f0898;}async['getRevisionRootsAttributes'](_0x54149b){await this['_loadRevisionData'](_0x54149b);const _0x4e88a6={};for(const _0x412e6f in _0x54149b['diffData'])_0x54149b['diffData'][_0x412e6f]['attachChange']&&!_0x54149b['diffData'][_0x412e6f]['attachChange']['isAttached']||(_0x4e88a6[_0x412e6f]=_0x54149b['diffData'][_0x412e6f]['attributesAfter']||{});return _0x4e88a6;}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x55858e=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x32ac3a=0x0;_0x32ac3a<_0x55858e['length'];_0x32ac3a++){const _0x3e41bc=_0x55858e[_0x32ac3a];let _0x352c81=!0x1;for(const _0x27bbaf of Object['keys'](_0x3e41bc))void 0x0===_0x3e41bc[_0x27bbaf]?delete _0x3e41bc[_0x27bbaf]:'id'!==_0x27bbaf&&(_0x352c81=!0x0);_0x352c81||(_0x55858e[_0x32ac3a]=null);}if(_0x55858e=_0x55858e['filter'](_0x401314=>null!==_0x401314),!_0x55858e['length'])return;for(let _0x57f7e6=0x0;_0x57f7e6<_0x55858e['length'];_0x57f7e6++){const _0x36240f=_0x55858e[_0x57f7e6];void 0x0!==_0x36240f['fromVersion']&&void 0x0===_0x36240f['toVersion']&&(_0x36240f['toVersion']=this['repository']['getRevision'](_0x36240f['id'])['toVersion']),void 0x0!==_0x36240f['toVersion']&&void 0x0===_0x36240f['fromVersion']&&(_0x36240f['fromVersion']=this['repository']['getRevision'](_0x36240f['id'])['fromVersion']);}const _0x575146=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x55858e,_0x575146)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x4b70d6=>{if(_0x4b70d6){for(const _0x152e42 of _0x4b70d6)this['setRevisionData']({'id':_0x152e42['id'],'createdAt':_0x152e42['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['_replaceEditorDataWithRevisionData'](_0x26d47f,_0x3f9c84){let _0x1cc8e0=this['editor']['config']['get']('initialData'),_0x5e0451=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x1cc8e0){_0x1cc8e0={};for(const _0x431d14 of this['editor']['model']['document']['getRootNames']())_0x1cc8e0[_0x431d14]='';}if('string'==typeof _0x1cc8e0&&(_0x1cc8e0={'main':_0x1cc8e0}),void 0x0===_0x5e0451){_0x5e0451={};for(const _0x2f6ee8 of this['editor']['model']['document']['getRootNames']())_0x5e0451[_0x2f6ee8]={};}let _0x52a7a8=!0x1;const _0x5cc42a=Object['keys'](_0x1cc8e0),_0x43e2e6=Object['keys'](_0x26d47f);for(const _0x59ada7 of _0x5cc42a){if(_0x1cc8e0[_0x59ada7]!==_0x26d47f[_0x59ada7]&&''!==_0x1cc8e0[_0x59ada7]['trim']()){_0x52a7a8=!0x0;break;}if(!_0x1b45fa(_0x5e0451[_0x59ada7],_0x3f9c84[_0x59ada7])&&Object['keys'](_0x5e0451[_0x59ada7])['length']>0x0){_0x52a7a8=!0x0;break;}}_0x52a7a8||(_0x52a7a8=_0x43e2e6['some'](_0x327bb2=>!this['editor']['model']['document']['getRoot'](_0x327bb2))),_0x52a7a8&&_0x1f7d34('editor-initial-data-replaced-with-revision-data',{'editorData':_0x1cc8e0,'editorRootsAttributes':_0x5e0451,'revisionData':_0x26d47f,'revisionRootsAttributes':_0x3f9c84}),this['editor']['config']['set']('initialData',_0x26d47f),this['editor']['config']['set']('rootsAttributes',_0x3f9c84);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x255df6=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x255df6['add'](R(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0xbf8ec1){const _0xe211d8=this['repository']['getRevisions']();_0xe211d8['reverse']();let _0x44e7aa=0x0;for(;_0x44e7aa<_0xe211d8['length'];){const _0x2df4b6=_0xe211d8[_0x44e7aa];if(_0x2df4b6===this['currentRevision']){_0x44e7aa++;continue;}if(_0x2df4b6['id']===this['_initialRevisionId'])break;const _0x37cc7b=_0xbf8ec1['toVersion']-_0x2df4b6['toVersion']||_0xbf8ec1['fromVersion']-_0x2df4b6['fromVersion'];if(_0x37cc7b>0x0)break;if(_0x37cc7b<0x0)_0x44e7aa++;else{if(!_0xbf8ec1['creator']&&_0x2df4b6['creator'])break;if(_0x2df4b6['creator']||!_0xbf8ec1['creator']){if(_0xbf8ec1['createdAt']>_0x2df4b6['createdAt'])break;_0x44e7aa++;}else _0x44e7aa++;}}return _0x44e7aa;}['setRevisionData'](_0x5055c7){const _0x68b409=this['repository']['getRevision'](_0x5055c7['id']);if(_0x5055c7['createdAt']&&(_0x5055c7['createdAt']=new Date(_0x5055c7['createdAt'])),_0x5055c7['authorsIds']){const _0x3957a2=this['editor']['plugins']['get']('Users');_0x5055c7['authors']=_0x5055c7['authorsIds']['map'](_0x10abdf=>_0x3957a2['getUser'](_0x10abdf));}_0x68b409['_update'](_0x5055c7,!0x0);}['buildRevisionData']({revision:_0x54be03=null,from:_0x454965=null,to:_0x1ca3a9=null}){_0x454965=null!==_0x454965?_0x454965:_0x54be03['fromVersion'],_0x1ca3a9=null!==_0x1ca3a9?_0x1ca3a9:_0x54be03['toVersion'];const _0x56d269=this['_revisionDataBuilder']['getData'](_0x454965,_0x1ca3a9),_0x1fce76={'diffData':_0x56d269['diffData'],'authorsIds':_0x56d269['authorsIds'],'fromVersion':_0x454965,'toVersion':_0x1ca3a9};if(!_0x54be03||_0x1ca3a9!==_0x54be03['toVersion']){const _0x34aeea=_0x1ca3a9-0x1,_0x1df608=this['_source']['history']['getOperation'](_0x34aeea);_0x1fce76['createdAt']=_0x1df608&&_0x1df608['createdAt']||new Date();}if(this['_loadedStateData']&&_0x454965===this['_loadedStateData']['fromVersion']){for(const _0x160158 of this['_loadedStateData']['authors'])_0x1fce76['authorsIds']['includes'](_0x160158['id'])||_0x1fce76['authorsIds']['push'](_0x160158['id']);}return _0x1fce76;}['_loadRevisionData'](_0x1209ff){if(!_0x1209ff||_0x1209ff['diffData'])return Promise['resolve']();{const _0xbe2cef=this['editor']['config']['get']('collaboration.channelId');return this['adapter']['getRevision']({'channelId':_0xbe2cef,'revisionId':_0x1209ff['id']})['then'](_0x43bd18=>{_0x1209ff['diffData']=_0x43bd18['diffData'];});}}['_bufferUpdate'](_0x5ae860,_0x4609f0,_0x3331a8){if(this['_bufferedUpdates']['has'](_0x5ae860)){const _0x42c0f4=this['_bufferedUpdates']['get'](_0x5ae860);_0x4609f0=_0x3331a8?{..._0x42c0f4,..._0x4609f0}:{..._0x4609f0,..._0x42c0f4};}this['_bufferedUpdates']['set'](_0x5ae860,_0x4609f0);}['_getFromVersion'](_0x2023ec){const _0x5d74cf=this['repository']['getRevisions']();_0x5d74cf['reverse'](),_0x5d74cf['shift']();const _0x4a1003=_0x5d74cf['find'](_0x2dfbe4=>_0x2dfbe4['toVersion']<=_0x2023ec)['toVersion'];return _0x4a1003<this['_startingVersion']?this['_startingVersion']:_0x4a1003;}['_createInitialRevision'](_0x3a93c2){const _0x2dcb0c=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x2dcb0c)this['_initialRevisionId']=_0x2dcb0c['id'];else{const _0x51ea34=!this['editor']['model']['document']['roots']['find'](_0xcf5048=>this['editor']['model']['hasContent'](_0xcf5048)),_0x355ce0=this['editor']['plugins']['get']('Users')['me']['id'],_0x19dfd6=R(this['editor']['locale'],_0x51ea34?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x3a93c2,'to':_0x3a93c2,'id':this['_initialRevisionId'],'name':_0x19dfd6,'creatorId':_0x355ce0});}}['_createCurrentRevision'](_0x53512d){const _0x30c84a=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x30c84a),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x53512d,'to':_0x53512d,'id':_0x30c84a,'name':'','creatorId':null}));}['_makeRevision']({name:_0x1a2f6e,from:_0x517a9f,to:_0x2e74b2,creatorId:_0x40a303,id:_0x1bb58b}){const _0x3b8c58=this['buildRevisionData']({'from':_0x517a9f,'to':_0x2e74b2});_0x3b8c58['name']=_0x1a2f6e,_0x3b8c58['creatorId']=_0x40a303,_0x3b8c58['id']=_0x1bb58b;const _0xc2aab8=this['addRevisionData'](_0x3b8c58);return this['adapter']&&this['_bufferUpdate'](_0x3b8c58['id'],_0x3b8c58,!0x0),_0xc2aab8;}['_setConversion'](){this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'});}['_removeRevisionMarkers'](_0x3c822c){return(_0x3c822c=_0x3c822c['filter'](_0x2233df=>!_0x2233df['name']||'revision-start'!==_0x2233df['name']&&'revision-end'!==_0x2233df['name']))['forEach'](_0xc12bf1=>{'string'!=typeof _0xc12bf1&&(_0xc12bf1['children']=this['_removeRevisionMarkers'](_0xc12bf1['children']),_0xc12bf1['attributes']=_0xc12bf1['attributes']['filter'](_0x150260=>!_0x150260[0x0]['startsWith']('data-revision-')));}),_0x3c822c;}}function V(_0x37675a,_0x1996cc){const _0x1d9e35=_0x1996cc['editing']['view']['document'];if('string'==typeof _0x37675a)return new _0xb834d4(_0x1d9e35,_0x37675a);{const _0x49236f=_0x37675a['children']['map'](_0x10572a=>V(_0x10572a,_0x1996cc));return new(C[_0x37675a['type']]||_0x3d7190)(_0x1d9e35,_0x37675a['name'],_0x37675a['attributes'],_0x49236f);}}class T{['editor'];['source'];['_savedMetaData'];['_lastFrom'];['_lastTo'];['_markers'];['_diffRoots'];['_diffRootsAttributes'];['_baseRoots'];['_baseRootsAttributes'];['_idsRoots'];['_baseIdsRoots'];['_touched'];['_touchedMarkers'];['_touchedRoots'];['_revisionId'];['_startingRevisionId'];constructor(_0x4eaf7c){this['editor']=_0x4eaf7c,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'](_0x2e17db){this['source']=_0x2e17db;const _0x30e247=new Map(),_0x534ab5=new Map(),_0x3f0399=this['editor']['model']['document']['roots']['map'](_0x132fb0=>_0x132fb0['rootName']);for(const _0xa63f90 of _0x3f0399){const _0x41fb80=this['editor']['model']['document']['getRoot'](_0xa63f90),_0x40c745=F(_0x41fb80);_0x30e247['set'](_0xa63f90,_0x40c745),_0x534ab5['set'](_0xa63f90,Object['fromEntries'](_0x41fb80['getAttributes']()));}const _0x2a814c=Array['from'](this['editor']['model']['markers'])['map'](_0x36a0f9=>[_0x36a0f9['name'],_0x36a0f9['getRange']()]),_0xbc5acd=this['source']['version'];this['_saveMetaData'](_0xbc5acd,_0x30e247,_0x2a814c,_0x534ab5),this['_startingRevisionId']=this['_revisionId'];const _0x494e18=new Map(),_0x9cbb83=new Map();for(const _0x3b7717 of _0x3f0399){const _0x3d16b6=B(_0x3b7717);_0x494e18['set'](_0x3b7717,_0x3d16b6),_0x9cbb83['set'](_0x3b7717,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x494e18,[],_0x9cbb83);}['getData'](_0x333af5,_0x3e61ec){if(this['_lastFrom']===_0x333af5&&this['_lastTo']<=_0x3e61ec)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x3e61ec,!0x0);else{if(!this['_savedMetaData']['has'](_0x333af5)){const _0x51987e=this['_getPreviousFrom'](_0x333af5);this['_calculateMetaData'](_0x51987e,_0x333af5,!0x1);}this['_calculateMetaData'](_0x333af5,_0x3e61ec,!0x0);}return this['_lastFrom']=_0x333af5,this['_lastTo']=_0x3e61ec,this['_getState']();}['loadState'](_0xb21f9d){this['_reset'](),this['_lastFrom']=_0xb21f9d['fromVersion'],this['_lastTo']=_0xb21f9d['toVersion'];for(const _0x3fc04b in _0xb21f9d['diffData']){const _0x2a7edb=_0xb21f9d['diffData'][_0x3fc04b]['attachChange'],_0x582da2=_0x3f361f(_0xb21f9d['diffData'][_0x3fc04b]['attributesBefore'])||{},_0x76ecf4=this['_makeModelFromViewString'](_0xb21f9d['diffData'][_0x3fc04b]['deletions']);_0x76ecf4['rootName']=_0x3fc04b,_0x76ecf4['_isAttached']=!_0x2a7edb||!_0x2a7edb['isAttached'],_0x76ecf4['isAttached']=()=>_0x76ecf4['_isAttached'],this['_baseRoots']['set'](_0x3fc04b,_0x76ecf4),this['_baseRootsAttributes']['set'](_0x3fc04b,_0x582da2),_0x2a7edb&&this['_touchedRoots']['set'](_0x3fc04b,_0x2a7edb);const _0x5321ec=this['_makeIdsRoot'](_0x76ecf4);this['_baseIdsRoots']['set'](_0x3fc04b,_0x5321ec);for(const [_0x5c672c,_0x4f2c0e]of _0x76ecf4['markers']){if(!_0x5c672c['startsWith']('revision:'))continue;const _0x1d50bc=_0x5c672c['split'](':')[0x2];for(const _0x5a255f of _0x4f2c0e['getWalker']({'singleCharacters':!0x0})){const _0x529a92=this['_getVidAttributeName'](_0x5a255f),_0x15c5f9='elementEnd'==_0x5a255f['type']?_0x5a255f['previousPosition']['path']['slice'](0x0,-0x1):_0x5a255f['previousPosition']['path'],_0x4087c6=_0x5321ec['getNodeByPath'](_0x15c5f9)['getAttribute'](_0x529a92);this['_touched']['set'](_0x4087c6,{'userId':_0x1d50bc});}}}this['_startingRevisionId']=this['_revisionId'];const _0x2636b8=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x23e84a=>!this['_touched']['has'](_0x23e84a));let _0x14c730=0x0;const _0x108387=new Map();for(const _0xf506d7 in _0xb21f9d['diffData']){const _0x1e3d79=_0xb21f9d['diffData'][_0xf506d7]['attachChange'],_0xee8e7f=_0x3f361f(_0xb21f9d['diffData'][_0xf506d7]['attributesAfter'])||{},_0x4c0077=this['_makeModelFromViewString'](_0xb21f9d['diffData'][_0xf506d7]['insertions']);_0x4c0077['rootName']=_0xf506d7,_0x4c0077['_isAttached']=!_0x1e3d79||_0x1e3d79['isAttached'],_0x4c0077['isAttached']=()=>_0x4c0077['_isAttached'],this['_diffRoots']['set'](_0xf506d7,_0x4c0077),this['_diffRootsAttributes']['set'](_0xf506d7,_0xee8e7f);const _0x244ade=this['_makeIdsRoot'](_0x4c0077,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0xf506d7,_0x244ade),_0x108387['set'](_0xf506d7,_0x4c0077['isAttached']()?_0xee8e7f:{});for(const [_0x558caf,_0x55cb32]of _0x4c0077['markers']){if(!_0x558caf['startsWith']('revision:'))continue;const _0x54513e=_0x558caf['split'](':')[0x2];for(const _0x51f6c4 of _0x55cb32['getWalker']({'singleCharacters':!0x0})){const _0xa452fb=this['_getVidAttributeName'](_0x51f6c4),_0x15aac2=this['_revisionId']++,_0x23062c='elementEnd'==_0x51f6c4['type']?_0x51f6c4['previousPosition']['path']['slice'](0x0,-0x1):_0x51f6c4['previousPosition']['path'];_0x244ade['getNodeByPath'](_0x23062c)['_setAttribute'](_0xa452fb,_0x15aac2),this['_touched']['set'](_0x15aac2,{'userId':_0x54513e});}}for(const _0x16e6d2 of this['editor']['model']['createRangeIn'](_0x4c0077)['getWalker']({'singleCharacters':!0x0})){const _0x3b41f6=this['_getVidAttributeName'](_0x16e6d2),_0x482bf1='elementEnd'==_0x16e6d2['type']?_0x16e6d2['previousPosition']['path']['slice'](0x0,-0x1):_0x16e6d2['previousPosition']['path'],_0x14cc35=_0x244ade['getNodeByPath'](_0x482bf1);_0x14cc35['getAttribute'](_0x3b41f6)>0x0||_0x14cc35['_setAttribute'](_0x3b41f6,_0x2636b8[_0x14c730++]);}for(const [_0x44f504,_0x2d3fff]of _0x4c0077['markers'])_0x44f504['startsWith']('revision:')||this['_markers']['set'](_0x44f504,_0x2d3fff);}const _0x24e3e4=B('$graveyard');this['_baseRoots']['set']('$graveyard',_0x24e3e4),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x24e3e4,0x1));const _0x4d2641=B('$graveyard');this['_diffRoots']['set']('$graveyard',_0x4d2641),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x4d2641,0x1));const _0x4867d9=Array['from'](this['_diffRoots'])['map'](([_0x4ea4c2,_0x32aed8])=>[_0x4ea4c2,F(_0x32aed8)]);this['_saveMetaData'](this['_lastTo'],_0x4867d9,this['_markers'],_0x108387);}['_makeModelFromViewString'](_0x410413){const _0x589e62=JSON['parse'](_0x410413),_0x2ebd64=this['editor']['editing']['view']['document'],_0x5d8a04=new _0x48dd3c(_0x2ebd64,_0x589e62['map'](_0xbb5402=>V(_0xbb5402,this['editor'])));return this['editor']['data']['toModel'](_0x5d8a04);}['_saveMetaData'](_0x29e618,_0x2f8f2c,_0x213271,_0x35e2c3){const _0x5ecc73=new Map(_0x2f8f2c),_0x4285f1=new Map(_0x3f361f(_0x35e2c3)),_0x281e40=new Map();for(const [_0x4b0a7e,_0x3206a5]of _0x213271)_0x281e40['set'](_0x4b0a7e,{'start':_0x3206a5['start']['clone'](),'end':_0x3206a5['end']['clone'](),'rootName':_0x3206a5['root']['rootName']});this['_savedMetaData']['set'](_0x29e618,{'roots':_0x5ecc73,'markers':_0x281e40,'rootsAttributes':_0x4285f1});}['_removeMetaData'](_0x1669c4){this['_savedMetaData']['delete'](_0x1669c4);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_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'](_0x36fe86,_0x561f21=null){let _0x3d511e=null;_0x36fe86['is']('documentFragment')||(_0x3d511e=new ft(_0x36fe86['name'],{'vid_start':null===_0x561f21?this['_revisionId']++:_0x561f21++}));const _0x258515=[];for(const _0x34c4a6 of _0x36fe86['getChildren']())if(_0x34c4a6['is']('element')){_0x258515['push'](this['_makeIdsRoot'](_0x34c4a6,_0x561f21));const _0x34835f=_0x258515[_0x258515['length']-0x1];null!==_0x561f21&&(_0x561f21=_0x34835f['is']('element','$text')?_0x34835f['getAttribute']('vid')+0x1:_0x34835f['getAttribute']('vid_end')+0x1);}else{for(let _0x372134=0x0;_0x372134<_0x34c4a6['offsetSize'];_0x372134++)_0x258515['push'](new ft('$text',{'vid':null===_0x561f21?this['_revisionId']++:_0x561f21++}));}if(_0x36fe86['is']('documentFragment')){const _0x5df010=B(_0x36fe86['rootName']);return _0x5df010['_insertChild'](0x0,_0x258515),_0x5df010;}return _0x3d511e['_setAttribute']('vid_end',null===_0x561f21?this['_revisionId']++:_0x561f21++),_0x3d511e['_insertChild'](0x0,_0x258515),_0x3d511e;}['_calculateMetaData'](_0x335f9a,_0x3cd25e,_0x5136fa){this['_reset']();const {roots:_0x3fe590,markers:_0xd3595c,rootsAttributes:_0x52a39a}=this['_savedMetaData']['get'](_0x335f9a);this['_baseRoots']=new Map(_0x3fe590),this['_baseRootsAttributes']=new Map(_0x3f361f(_0x52a39a));for(const [_0x45b113,_0x48d090]of this['_baseRoots'])if('$graveyard'!==_0x45b113&&(this['_diffRoots']['set'](_0x45b113,F(_0x48d090)),this['_diffRootsAttributes']=new Map(_0x3f361f(_0x52a39a)),_0x5136fa)){const _0x6976ef=this['_revisionId'];this['_idsRoots']['set'](_0x45b113,this['_makeIdsRoot'](_0x48d090)),this['_baseIdsRoots']['set'](_0x45b113,this['_makeIdsRoot'](_0x48d090,_0x6976ef));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',F(this['_baseRoots']['get']('$graveyard'))),_0x5136fa&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0xf869c2,_0x318b4d]of _0xd3595c){const _0x1c2c96=this['_baseRoots']['get'](_0x318b4d['rootName']),_0x4c46f7=this['_diffRoots']['get'](_0x318b4d['rootName']),_0x51068b=new vt(this['_fixPosition'](_0x318b4d['start'],_0x1c2c96),this['_fixPosition'](_0x318b4d['end'],_0x1c2c96)),_0x555e40=this['_fixRange'](_0x51068b,_0x4c46f7);_0x1c2c96['markers']['set'](_0xf869c2,_0x51068b),this['_markers']['set'](_0xf869c2,_0x555e40);}this['_applyOperations'](_0x335f9a,_0x3cd25e,_0x5136fa);}['_applyOperations'](_0x3b5448,_0x51439f,_0x211559){for(const _0xd64f13 of this['source']['getOperations'](_0x3b5448,_0x51439f))this['_handleOperation'](_0xd64f13,_0x211559);for(const _0x2cdefd of this['_diffRoots']['values']())_0x2cdefd['markers']['clear']();for(const [_0x509b23,_0x98ff20]of this['_markers']){this['_diffRoots']['get'](_0x98ff20['root']['rootName'])['markers']['set'](_0x509b23,_0x98ff20['clone']());}const _0x26113c=new Map(),_0x56b8ab=new Map();for(const [_0x4533a8,_0x13d56b]of this['_diffRoots'])_0x26113c['set'](_0x4533a8,F(_0x13d56b)),_0x56b8ab['set'](_0x4533a8,this['_diffRootsAttributes']['get'](_0x4533a8));this['_saveMetaData'](_0x51439f,_0x26113c,this['_markers'],_0x56b8ab);}['_getPreviousFrom'](_0x11b386){const _0x36af19=Array['from'](this['_savedMetaData']['keys']());_0x36af19['sort']((_0x2bee31,_0x2813d5)=>_0x2bee31-_0x2813d5),_0x36af19['reverse']();for(const _0x4f7cb9 of _0x36af19)if(_0x4f7cb9<_0x11b386)return _0x4f7cb9;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x21e95b,_0x4e01ab){const _0x5d5b76=Array['from'](_0x4e01ab['markers'])['map'](([_0x5c1d2c,_0x2472bf])=>[_0x5c1d2c,this['_fixRange'](_0x2472bf,_0x21e95b)]);_0x21e95b['markers']=new Map(_0x5d5b76);}['_transformMarkers'](_0x3ba69e){for(const _0x59d556 of this['_markers']['values']()){const _0x3e29e8=_0x59d556['getTransformedByOperation'](_0x3ba69e),_0x413083=vt['_createFromRanges'](_0x3e29e8);_0x59d556['start']=_0x413083['start'],_0x59d556['end']=_0x413083['end'];}}['_handleOperation'](_0x966c48,_0x31b969){if('addRoot'!=_0x966c48['type']&&'detachRoot'!=_0x966c48['type']){if('insert'==_0x966c48['type']){const _0x48b08c=_0x966c48['position']['root']['rootName'];this['_diffRoots']['has'](_0x48b08c)||(this['_diffRoots']['set'](_0x48b08c,B(_0x48b08c,!0x0)),this['_diffRootsAttributes']['set'](_0x48b08c,{}),_0x31b969&&this['_idsRoots']['set'](_0x48b08c,B(_0x48b08c,!0x0)));}else{if('addRootAttribute'==_0x966c48['type']||'removeRootAttribute'==_0x966c48['type']||'changeRootAttribute'==_0x966c48['type'])return void this['_handleRootAttributeOperation'](_0x966c48);'marker'==_0x966c48['type']&&this['_handleMarkerOperation'](_0x966c48);}if('marker'!==_0x966c48['type']){const _0x291f5f=this['_cloneOperation'](_0x966c48,this['_diffRoots']);_0x291f5f['_execute'](),this['_transformMarkers'](_0x291f5f);}if(_0x31b969)switch(_0x966c48['type']){case'insert':this['_handleInsertOperation'](_0x966c48);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x966c48);break;case'merge':this['_handleMergeOperation'](_0x966c48);break;case'split':this['_handleSplitOperation'](_0x966c48);}}else this['_handleRootOperation'](_0x966c48,_0x31b969);}['_cloneOperation'](_0x582fe4,_0x1b6302){const _0x18f0b4=_0x582fe4['clone']();return _0x18f0b4['_authorId']=_0x582fe4['_authorId'],this['_fixOperation'](_0x18f0b4,_0x1b6302),_0x18f0b4;}['_getBaseVids'](_0x35c491){return _0x35c491['map'](_0x2a2728=>{const _0x356741=this['_getVidAttributeName'](_0x2a2728);return Number(_0x2a2728['item']['getAttribute'](_0x356741));});}['_generateTape'](_0x16334e,_0x24860e){if(_0x16334e['is']('element','$text'))_0x24860e['push']({'item':_0x16334e,'type':'text'});else{_0x16334e['is']('element')&&_0x24860e['push']({'item':_0x16334e,'type':'elementStart'});for(const _0x4a1c21 of _0x16334e['getChildren']())this['_generateTape'](_0x4a1c21,_0x24860e);_0x16334e['is']('element')&&_0x24860e['push']({'item':_0x16334e,'type':'elementEnd'});}return _0x24860e;}['_getState'](){const _0x28e768=new Map(this['_touched']),_0x4878d9=new Map(_0x28e768),_0x5a28e8=new Map(),_0x193da9={'insertions':{},'deletions':{}},_0x183372={'insertions':{},'deletions':{}},_0x46fee4=new Map(),_0x4ab4dc=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x4ab4dc['delete']('$graveyard');for(const _0x34d16c of _0x4ab4dc){const _0x312392=this['_diffRoots']['get'](_0x34d16c)||B(_0x34d16c,!0x1),_0x5ed4ca=this['_baseRoots']['get'](_0x34d16c)||B(_0x34d16c,!0x1);_0x312392['isAttached']()||_0x5ed4ca['isAttached']()?(_0x193da9['insertions'][_0x34d16c]=F(_0x312392),_0x193da9['deletions'][_0x34d16c]=F(_0x5ed4ca),this['_copyMarkers'](_0x193da9['deletions'][_0x34d16c],_0x5ed4ca),this['_copyMarkers'](_0x193da9['insertions'][_0x34d16c],_0x312392),_0x183372['insertions'][_0x34d16c]=this['_generateTape'](this['_idsRoots']['get'](_0x34d16c),[]),_0x183372['deletions'][_0x34d16c]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x34d16c)||B(_0x34d16c,!0x1),[])):_0x4ab4dc['delete'](_0x34d16c);}for(const _0x5f5122 of _0x4ab4dc){const _0x1f2a38=_0x183372['insertions'][_0x5f5122];for(const _0x32f706 of _0x1f2a38){const _0x38677e=this['_getVidAttributeName'](_0x32f706),_0xc88f89=_0x32f706['item']['getAttribute'](_0x38677e);_0x4878d9['delete'](_0xc88f89),_0xc88f89>=this['_startingRevisionId']&&_0x5a28e8['set'](_0xc88f89,_0x28e768['get'](_0xc88f89));}}for(const _0x192799 of _0x4ab4dc){const _0xd62ede=_0x183372['insertions'][_0x192799],_0x409e5f=this['_getBaseVids'](_0x183372['deletions'][_0x192799]);let _0x4142ee=0x0;for(const _0x7fbf8b of _0xd62ede){const _0xfe114d=this['_getVidAttributeName'](_0x7fbf8b),_0x1f9845=_0x7fbf8b['item']['getAttribute'](_0xfe114d);if(!_0x5a28e8['has'](_0x1f9845)&&!_0x46fee4['has'](_0x1f9845)){if(_0x4878d9['has'](_0x1f9845))_0x4142ee++;else{if(_0x1f9845!=_0x409e5f[_0x4142ee]){const _0x283a0e=_0x28e768['get'](_0x1f9845)||_0x28e768['get'](_0x409e5f[_0x4142ee]);for(;_0x1f9845!=_0x409e5f[_0x4142ee];)_0x4878d9['has'](_0x409e5f[_0x4142ee])||(_0x46fee4['set'](_0x409e5f[_0x4142ee],_0x283a0e),_0x28e768['set'](_0x409e5f[_0x4142ee],_0x283a0e)),_0x4142ee++;}_0x4142ee++;}}}}for(const _0x4b0d36 of _0x4ab4dc){const _0x4bca8d=_0x183372['insertions'][_0x4b0d36];for(const _0x6f9e4e of _0x4bca8d){const _0x5af2fa=this['_getVidAttributeName'](_0x6f9e4e),_0x584de9=_0x6f9e4e['item']['getAttribute'](_0x5af2fa);if(_0x46fee4['has'](_0x584de9)){const _0x45e1fa=_0x46fee4['get'](_0x584de9);_0x4878d9['has'](_0x584de9)||_0x4878d9['set'](_0x584de9,{..._0x45e1fa}),_0x5a28e8['set'](_0x584de9,{..._0x45e1fa});}}}for(const _0x2de161 of _0x4878d9['keys']())_0x2de161>=this['_startingRevisionId']&&_0x4878d9['delete'](_0x2de161);const _0x313825=new Map();for(const _0x3bc607 of _0x4ab4dc){let _0x15d0f4=_0x183372['insertions'][_0x3bc607];for(const _0x189fb5 of _0x15d0f4)if(_0x189fb5['item']['is']('element','tableCell')){const _0x2ef24f=this['_getVidAttributeName'](_0x189fb5),_0x1f4bc8=_0x189fb5['item']['getAttribute'](_0x2ef24f);if(_0x5a28e8['has'](_0x1f4bc8)){const _0xfadd22=_0x189fb5['item']['parent']['parent']['getAttribute']('vid_start'),_0x468752=_0x313825['get'](_0xfadd22)||new Set();_0x468752['add'](_0x5a28e8['get'](_0x1f4bc8)['userId']),_0x313825['set'](_0xfadd22,_0x468752);}}_0x15d0f4=_0x183372['deletions'][_0x3bc607];for(const _0x2dfddf of _0x15d0f4)if(_0x2dfddf['item']['is']('element','tableCell')){const _0x4314e7=this['_getVidAttributeName'](_0x2dfddf),_0x179c2f=_0x2dfddf['item']['getAttribute'](_0x4314e7);if(_0x4878d9['has'](_0x179c2f)){const _0x313f5a=_0x2dfddf['item']['parent']['parent']['getAttribute']('vid_start'),_0x1a096d=_0x313825['get'](_0x313f5a)||new Set();_0x1a096d['add'](_0x4878d9['get'](_0x179c2f)['userId']),_0x313825['set'](_0x313f5a,_0x1a096d);}}for(const _0x58f095 of _0x313825['keys']())(_0x5a28e8['has'](_0x58f095)||_0x4878d9['has'](_0x58f095))&&_0x313825['delete'](_0x58f095);}for(const _0x171fd6 of _0x4ab4dc){const _0x5313fa=_0x183372['insertions'][_0x171fd6];let _0x5a8f58=null,_0x52a2ca=null;for(const _0x2039a5 of _0x5313fa){const _0x26277b=this['_getVidAttributeName'](_0x2039a5),_0x3e01f7=_0x2039a5['item']['getAttribute'](_0x26277b),_0x4a7698=_0x313825['get'](_0x3e01f7);_0x4a7698&&'elementStart'==_0x2039a5['type']&&(_0x5a8f58=Array['from'](_0x4a7698)[0x0],_0x52a2ca=_0x2039a5['item']['getAttribute']('vid_end')),_0x5a8f58&&(_0x4878d9['set'](_0x3e01f7,{'userId':_0x5a8f58}),_0x5a28e8['set'](_0x3e01f7,{'userId':_0x5a8f58})),_0x3e01f7==_0x52a2ca&&(_0x5a8f58=null,_0x52a2ca=null);}}const _0x3b41bc={},_0x40ad92=new Set();for(const _0x5e974b of _0x4ab4dc){const _0x20f11a=_0x193da9['deletions'][_0x5e974b],_0x712133=_0x193da9['insertions'][_0x5e974b];for(const {userId:_0x4a8f75}of this['_touchedMarkers']['values']())null!==_0x4a8f75&&_0x40ad92['add'](_0x4a8f75);for(const {userId:_0x29b647}of this['_touchedRoots']['values']())null!==_0x29b647&&_0x40ad92['add'](_0x29b647);this['_markChanges'](_0x712133,_0x183372['insertions'][_0x5e974b],_0x5a28e8,'insertion',_0x40ad92),this['_markChanges'](_0x20f11a,_0x183372['deletions'][_0x5e974b],_0x4878d9,'deletion',_0x40ad92),_0x3b41bc[_0x5e974b]={'insertions':this['_prepareViewToSave'](_0x712133),'deletions':this['_prepareViewToSave'](_0x20f11a),'attachChange':this['_touchedRoots']['get'](_0x5e974b)||null,'attributesBefore':_0x3f361f(this['_baseRootsAttributes']['get'](_0x5e974b))||{},'attributesAfter':_0x3f361f(this['_diffRootsAttributes']['get'](_0x5e974b))};}return{'diffData':_0x3b41bc,'authorsIds':Array['from'](_0x40ad92)};}['_processRootBeforeSave'](_0x540ed1){for(const [,_0x10a4b8]of _0x540ed1['markers']){const _0x4869e=_0x10a4b8['start']['getAncestors']()['filter'](_0x55a0b7=>'tableCell'==_0x55a0b7['name']);for(const _0x50b6fa of _0x4869e)0x1==_0x50b6fa['childCount']&&_0x50b6fa['getChild'](0x0)['is']('element','paragraph')&&_0x50b6fa['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x5d28eb){this['_processRootBeforeSave'](_0x5d28eb);const _0x4e15e5=this['editor']['data']['toView'](_0x5d28eb,{}),_0x2c0acb=Array['from'](_0x4e15e5['getChildren']())['map'](_0x4c5925=>this['_getViewJson'](_0x4c5925));return JSON['stringify'](_0x2c0acb);}['_getViewJson'](_0xd542a0){if(_0xd542a0['is']('$text'))return _0xd542a0['data'];{const _0x23edb8=_0xd542a0;return{'type':Object['keys'](C)['find'](_0x703be7=>_0xd542a0 instanceof C[_0x703be7]),'name':_0x23edb8['name'],'attributes':Array['from'](_0x23edb8['getAttributes']()),'children':Array['from'](_0x23edb8['getChildren']())['map'](_0x238455=>this['_getViewJson'](_0x238455))};}}['_markChanges'](_0x3ac352,_0x217db8,_0x5d0118,_0x36dc25,_0x1e40e2){let _0x32322c=null,_0x348820=null,_0xc5b35e=0x0;const _0x3f5e81=this['editor']['model'];for(let _0x183f02=0x0;_0x183f02<_0x217db8['length'];_0x183f02++){const _0x1c403c=this['_getVidAttributeName'](_0x217db8[_0x183f02]),_0x815ae7=_0x217db8[_0x183f02]['item']['getAttribute'](_0x1c403c),_0x2eb8c5=_0x5d0118['get'](_0x815ae7),_0x42231b=_0x183f02==_0x217db8['length']-0x1;(!_0x32322c&&_0x2eb8c5&&(_0x32322c=_0x2eb8c5,_0x348820=_0x217db8[_0x183f02]),_0x32322c&&(!_0x2eb8c5||_0x2eb8c5['userId']!=_0x32322c['userId']))&&(_0x188f8b(_0x2eb8c5,J(_0x348820,_0x3ac352,_0x3f5e81),J(_0x217db8[_0x183f02],_0x3ac352,_0x3f5e81)),_0x32322c=_0x2eb8c5||null,_0x348820=_0x2eb8c5?_0x217db8[_0x183f02]:null),_0x32322c&&_0x42231b&&_0x188f8b(_0x2eb8c5,J(_0x348820,_0x3ac352,_0x3f5e81),q(_0x217db8[_0x183f02],_0x3ac352,_0x3f5e81));}function _0x188f8b(_0x2fde26,_0x209c07,_0x1f4597){const _0x24d876=_0x32322c['userId'],_0x4b8f00='revision:'+_0x36dc25+':'+_0x24d876+':'+_0xc5b35e++,_0x208859=_0x3f5e81['createRange'](_0x209c07,_0x1f4597);_0x3ac352['markers']['set'](_0x4b8f00,_0x208859),null!==_0x24d876&&_0x1e40e2['add'](_0x24d876);}}['_getVidAttributeName'](_0x1e41e1){switch(_0x1e41e1['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x22a4b3,_0x20d8d2){_0x22a4b3['baseVersion']=null;for(const _0x4a7e52 in _0x22a4b3){const _0x1f73dc=_0x22a4b3[_0x4a7e52];if(_0x1f73dc instanceof gt){const _0xc7891a=_0x20d8d2['get'](_0x1f73dc['root']['rootName']);_0x22a4b3[_0x4a7e52]=this['_fixPosition'](_0x1f73dc,_0xc7891a);}if(_0x1f73dc instanceof vt){const _0xf1d553=_0x20d8d2['get'](_0x1f73dc['root']['rootName']);_0x22a4b3[_0x4a7e52]=this['_fixRange'](_0x1f73dc,_0xf1d553);}'root'===_0x4a7e52&&(_0x22a4b3['root']=_0x20d8d2['get'](_0x22a4b3['root']['rootName']));}}['_fixRange'](_0x23b9c3,_0x24ea4e){return this['editor']['model']['createRange'](this['_fixPosition'](_0x23b9c3['start'],_0x24ea4e),this['_fixPosition'](_0x23b9c3['end'],_0x24ea4e));}['_fixPosition'](_0x12a93e,_0x205b3f){return this['editor']['model']['createPositionFromPath'](_0x205b3f,_0x12a93e['path'],_0x12a93e['stickiness']);}['_handleInsertOperation'](_0x274b0d){const _0x35b6cb=this['_idsRoots']['get'](_0x274b0d['position']['root']['rootName']),_0x644dd9=this['_fixPosition'](_0x274b0d['position'],_0x35b6cb),_0x58585a=null===_0x274b0d['_authorId']?null:_0x274b0d['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x247620=_0x644dd9['parent'],_0x4eff9d=this['_revisionId'],_0x31e2bf=[];for(const _0x4439b1 of _0x274b0d['nodes'])if(_0x4439b1['is']('element'))_0x31e2bf['push'](this['_makeIdsRoot'](_0x4439b1));else{for(let _0x20785d=0x0;_0x20785d<_0x4439b1['offsetSize'];_0x20785d++)_0x31e2bf['push'](new ft('$text',{'vid':this['_revisionId']++}));}const _0x318fda=this['_revisionId'];for(let _0x9c9e00=_0x4eff9d;_0x9c9e00<_0x318fda;_0x9c9e00++)this['_touched']['set'](_0x9c9e00,{'userId':_0x58585a});_0x247620['_insertChild'](_0x644dd9['offset'],_0x31e2bf);}['_handleMoveOperation'](_0x374e5d){(_0x374e5d=this['_cloneOperation'](_0x374e5d,this['_idsRoots']))['_execute']();const _0x124657=null===_0x374e5d['_authorId']?null:_0x374e5d['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x425272=_0x374e5d['getMovedRangeStart'](),_0x49c02d=_0x425272['parent'],_0x9e5792=_0x425272['offset'];!function _0x32919e(_0x313397,_0xc129aa,_0x45f8e1,_0x2d86ad){for(let _0x840359=_0x45f8e1;_0x840359<_0x2d86ad;_0x840359++){const _0x5d84b1=_0xc129aa['getChild'](_0x840359);_0x5d84b1['is']('element','$text')?_0x313397['set'](_0x5d84b1['getAttribute']('vid'),{'userId':_0x124657}):(_0x313397['set'](_0x5d84b1['getAttribute']('vid_start'),{'userId':_0x124657}),_0x32919e(_0x313397,_0x5d84b1,0x0,_0x5d84b1['childCount']),_0x313397['set'](_0x5d84b1['getAttribute']('vid_end'),{'userId':_0x124657}));}}(this['_touched'],_0x49c02d,_0x9e5792,_0x9e5792+_0x374e5d['howMany']);}['_handleMergeOperation'](_0x2a2400){const _0x4a548c=null===(_0x2a2400=this['_cloneOperation'](_0x2a2400,this['_idsRoots']))['_authorId']?null:_0x2a2400['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x3150de=_0x2a2400['targetPosition']['parent'],_0x15f66e=_0x2a2400['sourcePosition']['parent'],_0x389dd6=_0x3150de['getAttribute']('vid_end'),_0x13ff25=_0x15f66e['getAttribute']('vid_start');_0x3150de['_setAttribute']('vid_end',_0x15f66e['getAttribute']('vid_end')),_0x15f66e['_setAttribute']('vid_end',_0x389dd6),this['_touched']['set'](_0x13ff25,{'userId':_0x4a548c}),this['_touched']['set'](_0x389dd6,{'userId':_0x4a548c}),_0x2a2400['_execute']();}['_handleSplitOperation'](_0x19ab66){const _0x5f1108=null===(_0x19ab66=this['_cloneOperation'](_0x19ab66,this['_idsRoots']))['_authorId']?null:_0x19ab66['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x436899=_0x19ab66['graveyardPosition'],_0x4b9a18=_0x19ab66['splitPosition']['parent'];_0x19ab66['_execute']();const _0x757432=_0x4b9a18['getAttribute']('vid_end'),_0x10114a=_0x19ab66['insertionPosition']['nodeAfter'];if(_0x436899){const _0x427a47=_0x10114a['getAttribute']('vid_end'),_0x4cf170=_0x4b9a18['getAttribute']('vid_end');_0x4b9a18['_setAttribute']('vid_end',_0x427a47),_0x10114a['_setAttribute']('vid_end',_0x4cf170),this['_touched']['set'](_0x4b9a18['getAttribute']('vid_end'),{'userId':_0x5f1108}),this['_touched']['set'](_0x10114a['getAttribute']('vid_start'),{'userId':_0x5f1108});}else{const _0x33942c=this['_revisionId']++,_0x2f589e=this['_revisionId']++;_0x4b9a18['_setAttribute']('vid_end',_0x33942c),_0x10114a['_setAttribute']('vid_start',_0x2f589e),_0x10114a['_setAttribute']('vid_end',_0x757432),this['_touched']['set'](_0x33942c,{'userId':_0x5f1108}),this['_touched']['set'](_0x2f589e,{'userId':_0x5f1108});}}['_handleMarkerOperation'](_0x15d109){if(!_0x15d109['affectsData'])return;const _0x387878=(_0x15d109=this['_cloneOperation'](_0x15d109,this['_diffRoots']))['oldRange']?_0x15d109['oldRange']['root']:null,_0x5ab9c5=_0x15d109['newRange']?_0x15d109['newRange']['root']:null;_0x387878&&this['_markers']['delete'](_0x15d109['name']),_0x5ab9c5&&this['_markers']['set'](_0x15d109['name'],_0x15d109['newRange']['clone']());const _0xb6dacf=null===_0x15d109['_authorId']?null:_0x15d109['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x5a355a=_0x15d109['name'];if(!this['_touchedMarkers']['has'](_0x5a355a))return void this['_touchedMarkers']['set'](_0x5a355a,{'range':_0x15d109['oldRange'],'userId':_0xb6dacf});const _0x21da90=this['_touchedMarkers']['get'](_0x5a355a),_0x196611=_0x21da90['range'],_0x3af207=_0x15d109['newRange'];null==_0x196611&&null==_0x3af207||_0x196611&&_0x3af207&&_0x196611['isEqual'](_0x3af207)?this['_touchedMarkers']['delete'](_0x15d109['name']):_0x21da90['userId']=_0xb6dacf;}['_handleRootOperation'](_0x39bb9c,_0xebb344){this['_diffRoots']['has'](_0x39bb9c['rootName'])?this['_diffRoots']['get'](_0x39bb9c['rootName'])['_isAttached']=_0x39bb9c['isAdd']:(this['_diffRoots']['set'](_0x39bb9c['rootName'],B(_0x39bb9c['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x39bb9c['rootName'],{}),_0xebb344&&this['_idsRoots']['set'](_0x39bb9c['rootName'],B(_0x39bb9c['rootName'],!0x0)));const _0x550837=null===_0x39bb9c['_authorId']?null:_0x39bb9c['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0xe78066=this['_touchedRoots']['get'](_0x39bb9c['rootName']);_0xe78066&&_0xe78066['userId']===_0x550837?this['_touchedRoots']['delete'](_0x39bb9c['rootName']):this['_touchedRoots']['set'](_0x39bb9c['rootName'],{'userId':_0x550837,'isAttached':_0x39bb9c['isAdd']});}['_handleRootAttributeOperation'](_0x387c5b){const _0x1015c1=this['_diffRootsAttributes']['get'](_0x387c5b['root']['rootName']);null===_0x387c5b['newValue']?delete _0x1015c1[_0x387c5b['key']]:_0x1015c1[_0x387c5b['key']]=_0x387c5b['newValue'];}}function F(_0x340328){const _0x3d6d2f=B(_0x340328['rootName'],_0x340328['isAttached']());for(const _0x4c5d86 of _0x340328['getChildren']()){const _0x40b5be=_0x4c5d86['_clone'](!0x0);_0x3d6d2f['_appendChild'](_0x40b5be);}return _0x3d6d2f;}function B(_0x4ae781,_0x4900b6=!0x0){const _0x4052f8=new mt();return _0x4052f8['rootName']=_0x4ae781,_0x4052f8['_isAttached']=_0x4900b6,_0x4052f8['isAttached']=()=>_0x4052f8['_isAttached'],_0x4052f8;}function J(_0x350c65,_0x12525c,_0x28e807){const _0x100ebc='elementEnd'==_0x350c65['type']?_0x28e807['createPositionAt'](_0x350c65['item'],'end'):_0x28e807['createPositionBefore'](_0x350c65['item']);return _0x28e807['createPositionFromPath'](_0x12525c,_0x100ebc['path'],_0x100ebc['stickiness']);}function q(_0x492c05,_0x2e9b98,_0x3b9290){const _0x595a8c='elementStart'==_0x492c05['type']?_0x3b9290['createPositionAt'](_0x492c05['item'],0x0):_0x3b9290['createPositionAfter'](_0x492c05['item']);return _0x3b9290['createPositionFromPath'](_0x2e9b98,_0x595a8c['path'],_0x595a8c['stickiness']);}class hs extends ts{['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x1f83ad,_0x42eadd){super(_0x1f83ad),this['focusTracker']=new _0x2d7a0c(),this['keystrokes']=new _0x10c3da(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x42eadd),this['setTemplate']({'tag':'form','attributes':{'class':['ck','ck-revision-history-save-revision-form','ck-responsive-form'],'tabindex':'-1'},'children':[this['revisionNameInputView']]}),_0x449c03(this);}['render'](){super['render'](),_0x5577d8({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x50fb5b=_0x2d0244=>_0x2d0244['stopPropagation']();this['keystrokes']['set']('arrowright',_0x50fb5b),this['keystrokes']['set']('arrowleft',_0x50fb5b),this['keystrokes']['set']('arrowup',_0x50fb5b),this['keystrokes']['set']('arrowdown',_0x50fb5b);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x410554){this['revisionNameInputView']['fieldView']['element']['value']=_0x410554['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x167c5f){const _0x813b82=new _0x1ea983(this['locale'],_0x57df33),_0x372709=_0x813b82['fieldView'];_0x372709['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x8fe7ba=R(this['locale'],'Name\x20of\x20the\x20revision');return!_0x167c5f&&(_0x8fe7ba+='\x20('+R(this['locale'],'optional')+')'),(_0x813b82['label']=_0x8fe7ba,_0x372709['on']('input',()=>{this['revisionNameInputValue']=_0x372709['element']['value']['trim']();}),_0x813b82);}}class u extends _0x27f686{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l];}['_saveRevisionFormView'];['init'](){const _0x376437=this['editor'],_0x11e934=_0x376437['plugins']['get']('RevisionTracker');_0x376437['ui']['componentFactory']['add']('revisionHistory',_0x5f5138=>{const _0x2085bb=_0x47635c(_0x5f5138),_0x46b6f3=_0x2085bb['panelView']['children'],_0x45e9de=new _0x253ba0(_0x5f5138),_0x3f9811=new _0x950cf2(_0x5f5138),_0x45adf9=new te(_0x5f5138),_0x2e43eb=new _0x950cf2(_0x5f5138),_0x1850ec=new te(_0x5f5138);return _0x2085bb['bind']('isEnabled')['to'](_0x11e934,'isReady',_0x11e934,'isEnabled',_0x376437,'isReadOnly',(_0x1e8237,_0x3b3c2c,_0x2ae4f2)=>_0x1e8237&&_0x3b3c2c&&!_0x2ae4f2),_0x2085bb['buttonView']['set']({'icon':_0x57211a['history'],'label':R(_0x5f5138,'Revision\x20history'),'tooltip':!0x0}),_0x45adf9['set']({'label':R(_0x5f5138,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x45adf9['bind']('isEnabled')['to'](_0x11e934,'isReady',_0x11e934,'isEnabled',_0x376437,'isReadOnly',(_0x1977cf,_0x433413,_0xf9af6a)=>_0x1977cf&&_0x433413&&!_0xf9af6a),_0x45adf9['on']('execute',()=>this['_showDialog']()),_0x1850ec['set']({'label':R(_0x5f5138,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x1850ec['bind']('isEnabled')['to'](_0x11e934,'isReady',_0x376437,'isReadOnly',(_0x6e1bf8,_0x48a7a0)=>_0x6e1bf8&&!_0x48a7a0),_0x1850ec['on']('execute',()=>{_0x376437['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x2085bb['isOpen']=!0x1,_0x376437['editing']['view']['focus']();}),_0x3f9811['children']['add'](_0x45adf9),_0x2e43eb['children']['add'](_0x1850ec),_0x45e9de['role']='menu',_0x45e9de['items']['addMany']([_0x3f9811,_0x2e43eb]),_0x46b6f3['add'](_0x45e9de),_0x2085bb;}),_0x376437['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x199cdd=this['editor'],_0x33e6d4=_0x199cdd['locale'],_0x3fd7da=new _0x1f15bb(_0x33e6d4),_0x2c4387=new _0x5723a7(_0x33e6d4);_0x3fd7da['buttonView']['set']({'icon':_0x57211a['history'],'label':R(_0x33e6d4,'Revision\x20history')});const _0x378315=new _0x185366(_0x33e6d4,_0x3fd7da),_0x3799e2=new _0x1bff1f(_0x33e6d4);_0x3799e2['set']({'label':R(_0x33e6d4,'Save\x20current\x20revision')}),_0x3799e2['delegate']('execute')['to'](_0x3fd7da),_0x3799e2['on']('execute',()=>{this['_showDialog']();}),_0x378315['children']['add'](_0x3799e2),_0x2c4387['items']['add'](_0x378315);const _0x2f71c9=new _0x185366(_0x33e6d4,_0x3fd7da),_0x305a46=new _0x1bff1f(_0x33e6d4);return _0x305a46['set']({'label':R(_0x33e6d4,'Open\x20revision\x20history')}),_0x305a46['delegate']('execute')['to'](_0x3fd7da),_0x305a46['on']('execute',()=>{_0x199cdd['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x2f71c9['children']['add'](_0x305a46),_0x2c4387['items']['add'](_0x2f71c9),_0x3fd7da['panelView']['children']['add'](_0x2c4387),_0x3fd7da;}['_showDialog'](){const _0x39ee06=this['editor'],_0x19fe69=_0x39ee06['locale'],_0x437b59=_0x39ee06['plugins']['get']('Dialog'),_0x1ead51=_0x39ee06['plugins']['get']('RevisionTracker');function _0x5ea3b3(_0x41896f){_0x39ee06['config']['get']('revisionHistory.requireRevisionName')&&''===_0x41896f['revisionName']?_0x41896f['revisionNameInputView']['errorText']=R(_0x19fe69,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x39ee06['plugins']['get'](l)['saveRevision']({'name':_0x41896f['revisionName']}),_0x437b59['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x5ea3b3(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x437b59['show']({'id':'revisionSave','title':R(_0x19fe69,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':R(_0x39ee06['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x437b59['hide']()},{'label':R(_0x39ee06['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x11166c){_0x11166c['bind']('isEnabled')['to'](_0x1ead51,'isReady',_0x1ead51,'isEnabled',_0x39ee06,'isReadOnly',(_0x3e0743,_0x35bb87,_0x503b33)=>_0x3e0743&&_0x35bb87&&!_0x503b33);},'onExecute':()=>_0x5ea3b3(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x1997a5=this['editor'],_0x3b0605=_0x1997a5['locale'];this['_saveRevisionFormView']=new hs(_0x3b0605,_0x1997a5['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class Y extends ts{['changeId'];['_model'];constructor(_0x1b1ef7,_0x25c461){super(_0x1b1ef7),this['_model']=_0x25c461,this['changeId']=_0x25c461['id'];const _0x37d240=this['bindTemplate'],_0x48db3c=R(_0x1b1ef7,_0x25c461['data']['isSuggestion']?'Suggested\x20by':'add'==_0x25c461['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x25c461['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x37d240['to']('type',_0x2c9955=>'ck-revision-change__'+_0x2c9955)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x48db3c}]},{'text':'\x20'+_0x25c461['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class r extends/* #__PURE__ -- @preserve */
25
- _0xa03473(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x212a69){super(),this['id']=_0x212a69['id']||_0x27b216(),this['author']=_0x212a69['author'],this['type']=_0x212a69['type'],this['data']=_0x212a69['data']||{},this['rootName']=_0x212a69['rootName'],this['set']('createdAt',_0x212a69['createdAt']);}['toJSON'](){return{'id':this['id'],'authorId':this['author']['id'],'type':this['type'],'data':this['data'],'createdAt':this['createdAt']};}}class f{['newRevisionId'];['oldRevisionId'];['changes'];constructor(_0x425a9c,_0x21633f){this['newRevisionId']=_0x425a9c,this['oldRevisionId']=_0x21633f,this['changes']=new _0x2987a6();}['_setChanges'](_0x4d1a4b){for(const _0x305a23 of _0x4d1a4b)this['changes']['add'](_0x305a23);}}const Z={'c':_0x5a71b7,'a':_0x5c54c2,'e':_0xc8c1e6,'r':_0x5e32f8,'u':_0x255215};class d extends _0x27f686{['repository'];['adapter'];['_activeViewTarget'];['_changeView'];['_changeIdToChange'];['_balloon'];static get['pluginName'](){return'RevisionViewer';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[_0x17470c,_0x16945d,j];}constructor(_0x394b61){super(_0x394b61),this['repository']=this['editor']['plugins']['get']('RevisionsRepository'),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',(_0x335c41,_0x18d3a6,_0x119726)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x1e43f9=>{for(const _0x518771 of this['editor']['editing']['view']['document']['roots'])_0x119726?_0x1e43f9['removeClass']('ck-editor__editable__overlay',_0x518771):_0x1e43f9['addClass']('ck-editor__editable__overlay',_0x518771);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x5efb2d=>null!==_0x5efb2d),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x11fa76,_0x55db4d,_0x1d32ba)=>_0x11fa76&&_0x1d32ba?_0x55db4d['changes']['getIndex'](_0x1d32ba):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x404487,_0x949d5c)=>_0x404487?_0x949d5c['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['adapter']=null,this['_balloon']=this['editor']['plugins']['get'](_0x16945d);}['init'](){const _0x59b5be=this['editor'],_0xe16394=new yt(_0x59b5be,{'direction':'backward'}),_0x5bfca1=new yt(_0x59b5be,{'direction':'forward'});(_0x59b5be['commands']['add']('showPreviousChange',_0xe16394),_0x59b5be['commands']['add']('showNextChange',_0x5bfca1),_0x59b5be['commands']['add']('restoreRevision',new _t(_0x59b5be)),this['on']('change:numberOfChanges',()=>{_0xe16394['refresh'](),_0x5bfca1['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x59b5be['enableReadOnlyMode']('revision-viewer'),_0x59b5be['plugins']['has']('WidgetToolbarRepository'))&&_0x59b5be['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionData'](_0x5e1cb9){await this['loadRevisionData'](_0x5e1cb9);const _0x226aba={};for(const _0x41b242 in _0x5e1cb9['diffData']){if(_0x5e1cb9['diffData'][_0x41b242]['attachChange']&&!_0x5e1cb9['diffData'][_0x41b242]['attachChange']['isAttached'])continue;const _0xbc04a2=this['_removeRevisionMarkers'](JSON['parse'](_0x5e1cb9['diffData'][_0x41b242]['insertions'])),_0x369dc4=this['editor']['editing']['view']['document'],_0xfa0c95=new _0x48dd3c(_0x369dc4,_0xbc04a2['map'](_0x26607f=>this['_getViewObj'](_0x26607f)));this['editor']['data']['processor']['useFillerType']('marked'),_0x226aba[_0x41b242]=this['editor']['data']['processor']['toData'](_0xfa0c95),this['editor']['data']['processor']['useFillerType']('default');}return _0x226aba;}async['getRevisionRootsAttributes'](_0x5ac804){await this['loadRevisionData'](_0x5ac804);const _0x1ef843={};for(const _0x30fef9 in _0x5ac804['diffData'])_0x5ac804['diffData'][_0x30fef9]['attachChange']&&!_0x5ac804['diffData'][_0x30fef9]['attachChange']['isAttached']||(_0x1ef843[_0x30fef9]=_0x5ac804['diffData'][_0x30fef9]['attributesAfter']||{});return _0x1ef843;}['_removeRevisionMarkers'](_0x1b3de3){return(_0x1b3de3=_0x1b3de3['filter'](_0x5128a8=>!_0x5128a8['name']||'revision-start'!==_0x5128a8['name']&&'revision-end'!==_0x5128a8['name']))['forEach'](_0x52c164=>{'string'!=typeof _0x52c164&&(_0x52c164['children']=this['_removeRevisionMarkers'](_0x52c164['children']),_0x52c164['attributes']=_0x52c164['attributes']['filter'](_0x121268=>!_0x121268[0x0]['startsWith']('data-revision-')));}),_0x1b3de3;}async['compare'](_0x37b3d5,_0xab1e3d,_0x170561=!0x1){if(!this['isEnabled'])return;const _0x264c40=this['diff'],_0x12dc49=this['repository'],_0x2e692d='string'==typeof _0x37b3d5?_0x12dc49['getRevision'](_0x37b3d5):_0x37b3d5,_0x21d086='string'==typeof _0xab1e3d?_0x12dc49['getRevision'](_0xab1e3d):_0xab1e3d,_0x34b5fb=_0x2e692d['id'],_0x113eab=_0x21d086?_0x21d086['id']:null;if(!_0x170561&&this['diff']&&this['diff']['newRevisionId']===_0x34b5fb&&this['diff']['oldRevisionId']===_0x113eab)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new f(_0x34b5fb,_0x113eab);const _0x5d31de=this['_getRevisionsRange'](_0x2e692d,_0x21d086,!0x0)['map'](_0x5a1041=>this['loadRevisionData'](_0x5a1041));return _0x5d31de['push'](new Promise(_0xcb2247=>{setTimeout(_0xcb2247,0x14);})),Promise['all'](_0x5d31de)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x42f42d=this['_getDiff'](_0x34b5fb,_0x113eab);for(const _0x419d98 of _0x42f42d['changes'])this['_changeIdToChange']['set'](_0x419d98['id'],_0x419d98);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x588d7f=>{for(const _0x30aa2f of this['editor']['model']['document']['getRootNames']())_0x588d7f['detachRoot'](_0x30aa2f);for(const _0x19e556 of Object['keys'](_0x42f42d['model'])){const _0x5398df=_0x588d7f['addRoot'](_0x19e556);for(const _0x2c9e62 of Object['keys'](_0x42f42d['attributes'][_0x19e556]))_0x588d7f['setAttribute'](_0x2c9e62,_0x42f42d['attributes'][_0x19e556][_0x2c9e62],_0x5398df);_0x588d7f['insert'](_0x42f42d['model'][_0x19e556],_0x5398df,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x42f42d['changes'])),this['isReady']=!0x0;})['catch'](_0x189064=>{console['error'](_0x189064),this['_cleanUp'](),_0x264c40&&(this['diff']=_0x264c40),this['isReady']=!0x0;});}['addRevisionData'](_0x3ca6c7,_0x50fb0e){const _0x47f876=this['repository']['createRevision'](_0x3ca6c7);return _0x47f876['on']('_update',(_0x46b08f,_0x1ae3ef,_0x16649e)=>_0x50fb0e(_0x1ae3ef,_0x16649e,_0x47f876)),this['repository']['addRevision'](_0x47f876),_0x47f876;}['loadRevisionData'](_0x4988d6){if(!_0x4988d6||_0x4988d6['diffData'])return Promise['resolve']();{const _0x3355ea=this['editor']['config']['get']('collaboration.channelId');return this['adapter']['getRevision']({'channelId':_0x3355ea,'revisionId':_0x4988d6['id']})['then'](_0x62662a=>{_0x4988d6['_update']({'diffData':_0x62662a['diffData']},!0x0);});}}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x121fb2=>{for(const _0x2dc164 of this['editor']['model']['document']['getRootNames']())_0x121fb2['detachRoot'](_0x2dc164);});}['_sortAndFilterDiffChanges'](_0xc6be78){const _0x54ae59=[],_0x3ad22a=new Map();for(const _0x41edf2 of this['editor']['model']['document']['getRootNames']()){const _0x52d944=this['editor']['editing']['view']['getDomRoot'](_0x41edf2);if(!_0x52d944)continue;const _0x1398da=_0x52d944['getClientRects']()['item'](0x0);_0x1398da&&(_0x54ae59['push'](_0x41edf2),_0x3ad22a['set'](_0x41edf2,_0x1398da));}return _0x54ae59['sort']((_0x13b3ba,_0x333373)=>{const _0x414ce4=_0x3ad22a['get'](_0x13b3ba),_0x59d536=_0x3ad22a['get'](_0x333373);return _0x414ce4['y']-_0x59d536['y']||_0x414ce4['x']-_0x59d536['x'];}),(_0xc6be78=_0xc6be78['filter'](_0x5c8b5c=>_0x54ae59['includes'](_0x5c8b5c['rootName'])))['sort']((_0x4ba938,_0x3637ef)=>_0x54ae59['indexOf'](_0x4ba938['rootName'])-_0x54ae59['indexOf'](_0x3637ef['rootName'])),_0xc6be78;}['_makeTape'](_0x50e12a){const _0x18b01d=Array['from'](_0x50e12a['markers'])['filter'](([_0x55ec91,_0x3d2fd4])=>_0x55ec91['startsWith']('revision:')&&!_0x3d2fd4['isCollapsed']),_0x42ee0c=Array['from'](this['editor']['model']['createRangeIn'](_0x50e12a)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x18b01d['length'])for(const _0x57afb5 of _0x42ee0c){const [_0x170fe0,_0x5f21b1]=_0x18b01d[0x0],[,_0x324810,_0x35b0fc]=_0x170fe0['split'](':');if(_0x5f21b1['end']['isEqual'](_0x57afb5['nextPosition'])&&_0x18b01d['shift'](),(_0x57afb5['previousPosition']['isEqual'](_0x5f21b1['start'])||_0x57afb5['previousPosition']['isAfter'](_0x5f21b1['start']))&&('insertion'==_0x324810?_0x57afb5['isAdded']={'userId':_0x35b0fc}:'deletion'==_0x324810&&(_0x57afb5['isRemoved']={'userId':_0x35b0fc})),0x0==_0x18b01d['length'])break;}return _0x42ee0c;}['_refreshStartEndIndex'](_0x2c0237){const _0x1dfed5=new Map();for(let _0x35bf0e=0x0;_0x35bf0e<_0x2c0237['length'];_0x35bf0e++)'text'===_0x2c0237[_0x35bf0e]['type']?(_0x2c0237[_0x35bf0e]['item']['startIndex']=_0x35bf0e,_0x2c0237[_0x35bf0e]['item']['endIndex']=_0x35bf0e):('elementStart'===_0x2c0237[_0x35bf0e]['type']?_0x2c0237[_0x35bf0e]['item']['startIndex']=_0x35bf0e:'elementEnd'===_0x2c0237[_0x35bf0e]['type']&&(_0x2c0237[_0x35bf0e]['item']['endIndex']=_0x35bf0e),_0x1dfed5['set'](_0x2c0237[_0x35bf0e]['id'],_0x35bf0e));for(const _0x499849 of _0x1dfed5['values']())'elementStart'===_0x2c0237[_0x499849]['type']?_0x2c0237[_0x499849]['item']['endIndex']=_0x1dfed5['get'](_0x2c0237[_0x499849]['pairId']):'elementEnd'===_0x2c0237[_0x499849]['type']&&(_0x2c0237[_0x499849]['item']['startIndex']=_0x1dfed5['get'](_0x2c0237[_0x499849]['pairId']));}['_processTape'](_0x3a886f){for(let _0x24861f=0x0;_0x24861f<_0x3a886f['length'];_0x24861f++){if('elementStart'===_0x3a886f[_0x24861f]['type'])_0x3a886f[_0x24861f]['item']['startIndex']=_0x24861f;else{if('elementEnd'===_0x3a886f[_0x24861f]['type']){_0x3a886f[_0x24861f]['item']['endIndex']=_0x24861f;const _0x587826=_0x3a886f[_0x24861f]['item']['startIndex'];_0x3a886f[_0x587826]['pairId']=_0x3a886f[_0x24861f]['id'],_0x3a886f[_0x24861f]['pairId']=_0x3a886f[_0x587826]['id'];}else _0x3a886f[_0x24861f]['item']['startIndex']=_0x24861f,_0x3a886f[_0x24861f]['item']['endIndex']=_0x24861f,_0x3a886f[_0x24861f]['pairId']=null;}_0x3a886f[_0x24861f]['markersStart']||(_0x3a886f[_0x24861f]['markersStart']=[],_0x3a886f[_0x24861f]['markersEnd']=[]);}}['_markInsertions'](_0x2c3b41,_0x106452){const _0x5ef7d1=_0x2c3b41['filter'](_0x4dacec=>!_0x4dacec['isAdded']);for(let _0x2f3483=0x0;_0x2f3483<_0x106452['length'];_0x2f3483++)_0x106452[_0x2f3483]['isAdded']&&(_0x5ef7d1[_0x2f3483]['isAdded']=_0x106452[_0x2f3483]['isAdded']);}['_makeModelFromViewString'](_0x437053){const _0x3ad015=JSON['parse'](_0x437053),_0x23393b=this['editor']['editing']['view']['document'],_0x1efe41=new _0x48dd3c(_0x23393b,_0x3ad015['map'](_0x2ded6b=>this['_getViewObj'](_0x2ded6b)));return this['editor']['data']['toModel'](_0x1efe41);}['_getViewObj'](_0x259c13){const _0x40df4e=this['editor']['editing']['view']['document'];if('string'==typeof _0x259c13)return new _0xb834d4(_0x40df4e,_0x259c13);{const _0x32e362=_0x259c13['children']['map'](_0x1cb7b1=>this['_getViewObj'](_0x1cb7b1));return new(Z[_0x259c13['type']]||_0x3d7190)(_0x40df4e,_0x259c13['name'],_0x259c13['attributes'],_0x32e362);}}['_getDiff'](_0x14109a,_0x3e4178=null){const _0x3d3af5=this['repository']['getRevision'](_0x14109a),_0x1d9c96=_0x3e4178?this['repository']['getRevision'](_0x3e4178):null,_0x299c70=this['_getRevisionsRange'](_0x3d3af5,_0x1d9c96),_0x10ef73=_0x299c70[_0x299c70['length']-0x1],_0x27c75d=new Map(),_0x2e4a3b={'model':{},'attributes':{},'changes':[]},_0x5205ef=new Set(),_0x3f241a=new Map();for(let _0x59bb90=_0x299c70['length']-0x1;_0x59bb90>=0x0;_0x59bb90--){const _0x5b91b8=_0x299c70[_0x59bb90];for(const _0x4c577f of Object['keys'](_0x5b91b8['diffData']))if(_0x5b91b8['diffData'][_0x4c577f]['attachChange']){const _0x4ea38e=_0x5b91b8['diffData'][_0x4c577f]['attachChange'];_0x4ea38e['isAttached']?(_0x5205ef['add'](_0x4c577f),_0x3f241a['has'](_0x4c577f)&&_0x3f241a['get'](_0x4c577f)['userId']==_0x4ea38e['userId']?_0x3f241a['delete'](_0x4c577f):_0x3f241a['set'](_0x4c577f,_0x4ea38e)):_0x3f241a['has'](_0x4c577f)?(_0x5205ef['delete'](_0x4c577f),_0x3f241a['delete'](_0x4c577f)):(_0x5205ef['add'](_0x4c577f),_0x3f241a['set'](_0x4c577f,_0x4ea38e));}else _0x5205ef['add'](_0x4c577f);}for(const _0x3aae8b of _0x5205ef){const _0x456963=_0x3f241a['has'](_0x3aae8b)&&!_0x3f241a['get'](_0x3aae8b)['isAttached'];let _0x1e4e60=_0x456963?_0x299c70['length']-0x1:0x0;const _0x5a16e8=_0x456963?-0x1:0x1;for(;_0x299c70[_0x1e4e60];){const _0x93461c=_0x299c70[_0x1e4e60];if(_0x93461c['diffData'][_0x3aae8b]){const _0x1a719f=_0x456963?_0x93461c['diffData'][_0x3aae8b]['attributesBefore']:_0x93461c['diffData'][_0x3aae8b]['attributesAfter'];_0x2e4a3b['attributes'][_0x3aae8b]=_0x1a719f?_0x3f361f(_0x1a719f):{};break;}_0x1e4e60+=_0x5a16e8;}}for(const _0x4b186e of _0x299c70){_0x4b186e['model']={};for(const _0x3c23ce of _0x4b186e['authors'])_0x27c75d['set'](_0x3c23ce['id'],_0x3c23ce);for(const _0x288faa of _0x5205ef){const _0x3f41b2=_0x4b186e['diffData'][_0x288faa]?_0x4b186e['diffData'][_0x288faa]['insertions']:'[]',_0x712dfa=_0x4b186e['diffData'][_0x288faa]?_0x4b186e['diffData'][_0x288faa]['deletions']:'[]';_0x4b186e['model'][_0x288faa]={'insertions':this['_makeModelFromViewString'](_0x3f41b2),'deletions':this['_makeModelFromViewString'](_0x712dfa)};}}for(const _0x23c764 of _0x5205ef){let _0xf01f85=null,_0x1607ac=0x0;const _0x302e8a=new Map(Array['from'](_0x3d3af5['model'][_0x23c764]['insertions']['markers'])['filter'](([_0x1f9967])=>!_0x1f9967['startsWith']('revision:')));let _0x338249=0x0;for(const _0x416c53 of _0x299c70){const _0x372985=this['_makeTape'](_0x416c53['model'][_0x23c764]['insertions']);_0x416c53==_0x3d3af5?(_0xf01f85=_0x372985,_0x1607ac=_0xf01f85['length'],_0xf01f85['forEach'](_0x18c220=>{_0x18c220['id']=_0x338249++;}),this['_processTape'](_0xf01f85)):this['_markInsertions'](_0xf01f85,_0x372985);const _0x2fcc06=_0xf01f85['filter'](_0x7da6e7=>!_0x7da6e7['isAdded'])['map'](_0x5888ab=>_0x5888ab['id']);let _0x127ed3=0x0;const _0x352058=this['_makeTape'](_0x416c53['model'][_0x23c764]['deletions']);_0x352058['forEach'](_0x126219=>{_0x126219['isRemoved']?_0x126219['id']=_0x1607ac++:_0x126219['id']=_0x2fcc06[_0x127ed3++];}),this['_processTape'](_0x352058),this['_setDistance'](_0xf01f85,'isAdded'),this['_setDistance'](_0x352058,'isRemoved'),_0x416c53==_0x3d3af5&&this['_markMarkers'](_0xf01f85,_0x302e8a),_0xf01f85=this['_joinTapes'](_0xf01f85,_0x352058),this['_refreshStartEndIndex'](_0xf01f85),this['_setDistance'](_0xf01f85,'isRemoved');}_0xf01f85=_0xf01f85['filter'](_0x1603dd=>!(_0x1603dd['isAdded']&&_0x1603dd['isRemoved']));const _0x5166e6=new Map(_0x10ef73['model'][_0x23c764]['deletions']['markers']),_0x556e26=new Set(_0x302e8a['keys']());for(const _0x47b2be of _0x5166e6['keys']())_0x556e26['delete'](_0x47b2be);this['_markSuggestions'](_0xf01f85,_0x556e26),this['_fixObsoleteTags'](_0xf01f85),_0xf01f85=this['_removeMissingPairs'](_0xf01f85),_0xf01f85=this['_markMismatchedRemovedTags'](_0xf01f85),_0xf01f85=this['_removeUnsupportedChanges'](_0xf01f85);const {root:_0xd5a1ee,changes:_0x42237d}=this['_makeModelFromTape'](_0xf01f85,_0x27c75d,_0x23c764);_0x2e4a3b['model'][_0x23c764]=_0xd5a1ee;const _0x346c93=_0x3f241a['get'](_0x23c764);if(_0x346c93){const _0x3d8a97=_0x27c75d['get'](_0x346c93['userId']),_0x143c81=new r({'author':_0x3d8a97,'type':_0x346c93['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x23c764});_0x42237d['unshift'](_0x143c81),_0x2e4a3b['attributes'][_0x23c764]['revisionHistoryAttachChange']=_0x143c81['id'];}_0x2e4a3b['changes']=_0x2e4a3b['changes']['concat'](_0x42237d);}return _0x2e4a3b;}['_markMarkers'](_0x367045,_0xec5a94){for(let _0x19444f=0x0;_0x19444f<_0x367045['length'];_0x19444f++)for(const [_0x56ac49,_0x1374e7]of _0xec5a94)_0x1374e7['start']['isEqual'](_0x367045[_0x19444f]['previousPosition'])&&_0x367045[_0x19444f]['markersStart']['push'](_0x56ac49),_0x1374e7['end']['isEqual'](_0x367045[_0x19444f]['nextPosition'])&&_0x367045[_0x19444f]['markersEnd']['push'](_0x56ac49);}['_joinTapes'](_0x2e3e68,_0x5ae85b){let _0x421622=[],_0x1aff46=0x0,_0x231e31=0x0;for(;_0x1aff46<_0x2e3e68['length']||_0x231e31<_0x5ae85b['length'];){const _0x4de97b=_0x2e3e68[_0x1aff46]||{},_0x1f808d=_0x5ae85b[_0x231e31]||{};if(_0x4de97b['id']==_0x1f808d['id'])_0x1aff46++,_0x231e31++,_0x421622['push'](_0x4de97b);else{if(_0x1f808d['isRemoved']&&_0x4de97b['isAdded']){const {commonTape:_0x4b69a3,iEnd:_0xc35dfc,jEnd:_0x55e2c2}=this['_threeWayMerge'](_0x2e3e68,_0x1aff46,_0x5ae85b,_0x231e31);_0x421622=_0x421622['concat'](_0x4b69a3),_0x1aff46=_0xc35dfc,_0x231e31=_0x55e2c2;}else _0x1f808d['isRemoved']?(_0x231e31++,_0x421622['push'](_0x1f808d)):(_0x1aff46++,_0x421622['push'](_0x4de97b));}}return _0x421622;}['_markSuggestions'](_0x308979,_0x34df9f){const _0x50df08=[];for(let _0x178487=0x0;_0x178487<_0x308979['length'];_0x178487++){for(let _0x4970eb=0x0;_0x4970eb<_0x308979[_0x178487]['markersStart']['length'];_0x4970eb++){const _0x44867d=_0x308979[_0x178487]['markersStart'][_0x4970eb];if(!_0x34df9f['has'](_0x44867d))continue;const {group:_0x472a4b,type:_0x236267,authorId:_0xea700e}=_0x2cf6e6(_0x44867d);'revision-suggestion'!=_0x472a4b||'insertion'!=_0x236267&&'deletion'!=_0x236267||(_0x50df08['unshift']({'type':_0x236267,'name':_0x44867d,'userId':_0xea700e}),_0x308979[_0x178487]['markersStart']['splice'](_0x4970eb,0x1),_0x4970eb--);}_0x25b608(_0x308979[_0x178487]);for(let _0x3ce26f=0x0;_0x3ce26f<_0x308979[_0x178487]['markersEnd']['length'];_0x3ce26f++){const _0xa55019=_0x308979[_0x178487]['markersEnd'][_0x3ce26f];if(!_0x34df9f['has'](_0xa55019))continue;const {group:_0x44266b,type:_0x102576}=_0x2cf6e6(_0xa55019);if('revision-suggestion'!=_0x44266b||'insertion'!=_0x102576&&'deletion'!=_0x102576)continue;_0x308979[_0x178487]['markersEnd']['splice'](_0x3ce26f,0x1),_0x3ce26f--;const _0x47c903=_0x50df08['findIndex'](_0x1a4ff2=>_0x1a4ff2['name']==_0xa55019);_0x47c903>-0x1&&_0x50df08['splice'](_0x47c903,0x1);}}function _0x2cf6e6(_0x36c303){const _0x217226=_0x36c303['split'](':');return{'group':_0x217226[0x0],'type':_0x217226[0x1],'subType':_0x217226['length']>=0x5?_0x217226[0x2]:null,'id':_0x217226['length']<0x5?_0x217226[0x2]:_0x217226[0x3],'authorId':_0x217226['length']<0x5?_0x217226[0x3]:_0x217226[0x4],'markerCount':0x6==_0x217226['length']?_0x217226[0x5]:null};}function _0x25b608(_0x210a40){for(let _0x34a480=0x0;_0x34a480<_0x50df08['length'];_0x34a480++){if(_0x210a40['isAdded']&&'insertion'==_0x50df08[_0x34a480]['type'])return _0x210a40['isAddSuggestion']=_0x50df08[_0x34a480],void delete _0x210a40['isAdded'];if(!_0x210a40['isAdded']&&!_0x210a40['isRemoved']&&'deletion'==_0x50df08[_0x34a480]['type'])return void(_0x210a40['isRemoveSuggestion']=_0x50df08[_0x34a480]);}}}['_setDistance'](_0x2708e4,_0x18c3ad){let _0x29e7c9=0x0,_0x25098c=!0x1;const _0x16ee93=new Map();for(const _0x54b4a1 of _0x2708e4)_0x54b4a1[_0x18c3ad]?_0x25098c&&(_0x29e7c9++,_0x25098c=!0x1):(_0x29e7c9++,_0x25098c=!0x0),_0x16ee93['set'](_0x54b4a1['id'],_0x29e7c9);for(let _0x566b2a=0x0;_0x566b2a<_0x2708e4['length'];_0x566b2a++){if('isRemoved'==_0x18c3ad&&_0x2708e4[_0x566b2a]['isAdded']||'isAdded'==_0x18c3ad&&_0x2708e4[_0x566b2a]['isRemoved'])continue;if('text'==_0x2708e4[_0x566b2a]['type']){_0x2708e4[_0x566b2a]['distance']=0x0;continue;}const _0x1b2fc6=_0x16ee93['get'](_0x2708e4[_0x566b2a]['pairId']),_0x5a8d81=_0x16ee93['get'](_0x2708e4[_0x566b2a]['id']);_0x2708e4[_0x566b2a]['distance']=_0x1b2fc6-_0x5a8d81;}}['_getRevisionsRange'](_0x17876a,_0x375583,_0x4973bf=!0x1){const _0x13ed2d=[];let _0xde80d9=this['repository']['getIndex'](_0x17876a),_0x2ea8e3=this['repository']['getIndex'](_0x375583);for(-0x1==_0x2ea8e3&&(_0x2ea8e3=this['repository']['_revisions']['length'],_0x4973bf=!0x1);_0xde80d9<_0x2ea8e3;)_0x13ed2d['push'](this['repository']['getRevision'](_0xde80d9)),_0xde80d9++;return _0x4973bf&&_0x13ed2d['push'](this['repository']['getRevision'](_0xde80d9)),_0x13ed2d;}['_threeWayMerge'](_0x5ef31e,_0x29b862,_0x27da3e,_0x4c0490){const _0x10924e=this['editor']['model']['schema'];let _0x5b9c0f=_0x29b862;for(;_0x5ef31e[_0x5b9c0f]&&_0x5ef31e[_0x5b9c0f]['isAdded'];)_0x5b9c0f++;let _0xe7a174=_0x4c0490;for(;_0x27da3e[_0xe7a174]&&_0x27da3e[_0xe7a174]['isRemoved'];)_0xe7a174++;_0x4f6c83(_0x5ef31e,_0x29b862,_0x5b9c0f),_0x4f6c83(_0x27da3e,_0x4c0490,_0xe7a174);const _0x1a96f1=_0x27da3e['slice'](_0x4c0490,_0xe7a174)['concat'](_0x5ef31e['slice'](_0x29b862,_0x5b9c0f));return _0x1a96f1['sort']((_0x2d3f8a,_0x13dfac)=>_0x2d3f8a['side']!=_0x13dfac['side']?_0x2d3f8a['side']-_0x13dfac['side']:_0x2d3f8a['level']!=_0x13dfac['level']?_0x2d3f8a['level']-_0x13dfac['level']:_0x2d3f8a['distance']!=_0x13dfac['distance']?_0x13dfac['distance']-_0x2d3f8a['distance']:!!_0x2d3f8a['isAdded']!=!!_0x13dfac['isAdded']?-0x1==_0x2d3f8a['side']||0x0==_0x2d3f8a['side']?_0x2d3f8a['isAdded']?-0x1:0x1:_0x2d3f8a['isAdded']?0x1:-0x1:_0x2d3f8a['index']-_0x13dfac['index']),{'commonTape':_0x1a96f1,'iEnd':_0x5b9c0f,'jEnd':_0xe7a174};function _0x4f6c83(_0x241922,_0x2a768d,_0x19a2e5){let _0x2314bf=-0x1,_0x2513c2=Number['POSITIVE_INFINITY'],_0x37f6fa=!0x0;for(let _0x4607fe=_0x2a768d;_0x4607fe<_0x19a2e5;_0x4607fe++)if(_0x10924e['isInline'](_0x241922[_0x4607fe]['item'])||(_0x37f6fa=!0x1),_0x241922[_0x4607fe]['item']['startIndex']<_0x2a768d&&(_0x2314bf=_0x4607fe),_0x241922[_0x4607fe]['item']['endIndex']>=_0x19a2e5){_0x2513c2=_0x4607fe;break;}_0x37f6fa&&(_0x2314bf=_0x19a2e5-0x1);for(let _0x11e8cd=_0x2a768d;_0x11e8cd<_0x19a2e5;_0x11e8cd++)_0x241922[_0x11e8cd]['side']=_0x11e8cd<=_0x2314bf?-0x1:_0x11e8cd<_0x2513c2?0x0:0x1,_0x241922[_0x11e8cd]['index']=_0x11e8cd;let _0x339006=0x0;for(let _0x5b566f=_0x2a768d;_0x5b566f<=_0x2314bf;_0x5b566f++)0x0==_0x241922[_0x5b566f]['distance']?_0x241922[_0x5b566f]['level']=_0x339006:(_0x339006++,_0x241922[_0x5b566f]['level']=_0x339006,_0x339006++);for(let _0x2a897c=_0x2a768d;_0x2a897c<_0x19a2e5;_0x2a897c++)0x0==_0x241922[_0x2a897c]['side']&&(_0x241922[_0x2a897c]['level']=_0x339006);_0x339006=0x0;for(let _0x441c6d=_0x19a2e5-0x1;_0x441c6d>=_0x2513c2;_0x441c6d--)0x0==_0x241922[_0x441c6d]['distance']?_0x241922[_0x441c6d]['level']=_0x339006:(_0x339006--,_0x241922[_0x441c6d]['level']=_0x339006,_0x339006--);}}['_fixObsoleteTags'](_0x1b9ac9){const _0x64f3ef=new Map(),_0x4bbecb=this['editor']['model']['schema'];for(let _0x2f2996=0x1;_0x2f2996<_0x1b9ac9['length'];_0x2f2996++){let _0x1842d2,_0x58926a,_0x28c3d1;const _0x3f3993=_0x1b9ac9[_0x2f2996],_0x2668b3=_0x1b9ac9[_0x2f2996-0x1];if('text'==_0x3f3993['type'])continue;if(_0x3f3993['type']!=_0x2668b3['type'])continue;if(!_0x4bbecb['isBlock'](_0x2668b3['item'])||_0x4bbecb['isLimit'](_0x2668b3['item']))continue;if(!_0x4bbecb['isBlock'](_0x3f3993['item'])||_0x4bbecb['isLimit'](_0x3f3993['item']))continue;if((_0x1b9ac9[_0x2f2996]['isAdded']||_0x1b9ac9[_0x2f2996]['isAddSuggestion'])&&_0x1b9ac9[_0x2f2996-0x1]['isRemoved'])_0x1842d2=_0x1b9ac9[_0x2f2996],_0x58926a=_0x1b9ac9[_0x2f2996-0x1],_0x28c3d1=_0x2f2996-0x1;else{if(!_0x1b9ac9[_0x2f2996]['isRemoved']||!_0x1b9ac9[_0x2f2996-0x1]['isAdded']&&!_0x1b9ac9[_0x2f2996-0x1]['isAddSuggestion'])continue;_0x1842d2=_0x1b9ac9[_0x2f2996-0x1],_0x58926a=_0x1b9ac9[_0x2f2996],_0x28c3d1=_0x2f2996;}const _0x29c838=_0x1842d2['level']==_0x58926a['level'],_0x5ddea2=Math['abs'](_0x1842d2['level'])<Math['abs'](_0x58926a['level'])&&0x0==_0x58926a['distance'];(_0x29c838||_0x5ddea2)&&(_0x64f3ef['set'](_0x58926a['id'],_0x1842d2['id']),_0x1b9ac9['splice'](_0x28c3d1,0x1),_0x2f2996--,_0x1842d2['isAdded']=!0x1);}for(let _0x33aaed=0x0;_0x33aaed<_0x1b9ac9['length'];_0x33aaed++)_0x64f3ef['has'](_0x1b9ac9[_0x33aaed]['pairId'])&&(_0x1b9ac9[_0x33aaed]['pairId']=_0x64f3ef['get'](_0x1b9ac9[_0x33aaed]['pairId']));}['_removeMissingPairs'](_0x50eb7d){const _0x5e18a6=new Set(_0x50eb7d['map'](_0x177c5a=>_0x177c5a['id']));for(let _0x4c014b=0x0;_0x4c014b<_0x50eb7d['length'];_0x4c014b++)_0x5e18a6['has'](_0x50eb7d[_0x4c014b]['pairId'])||0x0==_0x50eb7d[_0x4c014b]['distance']||(_0x50eb7d[_0x4c014b]['isIncorrect']=!0x0);return _0x50eb7d['filter'](_0x4cb34a=>!_0x4cb34a['isIncorrect']);}['_markMismatchedRemovedTags'](_0x33020f){const _0x2458a6=new Set();for(let _0xa65f2a=0x0;_0xa65f2a<_0x33020f['length'];_0xa65f2a++){if(_0x2458a6['has'](_0x33020f[_0xa65f2a]['id'])&&_0x33020f[_0xa65f2a]['isRemoved']&&(_0x33020f[_0xa65f2a]['isIncorrect']=!0x0),_0x33020f[_0xa65f2a]['isIncorrect'])continue;if(0x0==_0x33020f[_0xa65f2a]['distance'])continue;if('elementStart'!=_0x33020f[_0xa65f2a]['type'])continue;if(null==_0x33020f[_0xa65f2a]['pairId'])continue;let _0x2b2081=_0xa65f2a+0x1,_0x347c08=0x0;for(;_0x33020f[_0x2b2081]['id']!=_0x33020f[_0xa65f2a]['pairId'];)'elementStart'==_0x33020f[_0x2b2081]['type']?_0x347c08++:'elementEnd'==_0x33020f[_0x2b2081]['type']&&_0x347c08--,_0x2b2081++;if(0x0!=_0x347c08){if(_0x33020f[_0xa65f2a]['isRemoved'])_0x33020f[_0xa65f2a]['isIncorrect']=!0x0;else{for(;_0x2b2081!=_0xa65f2a;)_0x33020f[_0x2b2081]['isRemoved']&&0x0!=_0x33020f[_0x2b2081]['distance']&&(_0x33020f[_0x2b2081]['isIncorrect']=!0x0,_0x2458a6['add'](_0x33020f[_0x2b2081]['pairId'])),_0x2b2081--;}}}return _0x33020f['filter'](_0x2a6ffb=>!_0x2a6ffb['isIncorrect']);}['_removeUnsupportedChanges'](_0x250601){const _0x5d954d=this['editor']['model']['schema'];for(let _0x17679e=0x0;_0x17679e<_0x250601['length'];_0x17679e++){if(!(_0x250601[_0x17679e]['isAdded']||_0x250601[_0x17679e]['isAddSuggestion']||_0x250601[_0x17679e]['isRemoved']||_0x250601[_0x17679e]['isRemoveSuggestion']))continue;if(0x0==_0x250601[_0x17679e]['distance'])continue;const _0xc4d50f=_0x250601[_0x17679e]['item'];_0x5d954d['isBlock'](_0xc4d50f)||_0x5d954d['isLimit'](_0xc4d50f)||(_0x250601[_0x17679e]['isAdded']&&delete _0x250601[_0x17679e]['isAdded'],_0x250601[_0x17679e]['isAddSuggestion']&&delete _0x250601[_0x17679e]['isAddSuggestion'],_0x250601[_0x17679e]['isRemoveSuggestion']&&delete _0x250601[_0x17679e]['isRemoveSuggestion'],_0x250601[_0x17679e]['isRemoved']&&(_0x250601[_0x17679e]['isIncorrect']=!0x0));}return _0x250601['filter'](_0x191156=>!_0x191156['isIncorrect']);}['_makeModelFromTape'](_0xdd85b1,_0x3e292d,_0x9e9ac0){const _0x24c994=new mt(),_0x5014c4=[],_0x10a4cf=new Map(),_0x124fb6=this['editor']['model'],_0x44d2b9=_0x124fb6['schema'],_0x300aaf=[_0x24c994],_0x154d59={},_0x78fadc={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x1154a4=null;const _0x4e1a04=[0x0];for(let _0x363f6e=0x0;_0x363f6e<_0xdd85b1['length'];_0x363f6e++)if('elementStart'===_0xdd85b1[_0x363f6e]['type']){_0xdd85b1[_0x363f6e]['previousPosition']=_0x124fb6['createPositionFromPath'](_0x24c994,_0x4e1a04);const _0x31657e=new ft(_0xdd85b1[_0x363f6e]['item']['name'],_0xdd85b1[_0x363f6e]['item']['getAttributes']());_0x300aaf[0x0]['_appendChild'](_0x31657e),_0x4e1a04['push'](0x0),_0x300aaf['unshift'](_0x31657e),_0xdd85b1[_0x363f6e]['nextPosition']=_0x124fb6['createPositionFromPath'](_0x24c994,_0x4e1a04);}else'elementEnd'===_0xdd85b1[_0x363f6e]['type']?(_0x300aaf['shift'](),_0xdd85b1[_0x363f6e]['previousPosition']=_0x124fb6['createPositionFromPath'](_0x24c994,_0x4e1a04),_0x4e1a04['pop'](),_0x4e1a04[_0x4e1a04['length']-0x1]++,_0xdd85b1[_0x363f6e]['nextPosition']=_0x124fb6['createPositionFromPath'](_0x24c994,_0x4e1a04)):(_0xdd85b1[_0x363f6e]['previousPosition']=_0x124fb6['createPositionFromPath'](_0x24c994,_0x4e1a04),_0x1154a4?_0x1154a4['_data']+=_0xdd85b1[_0x363f6e]['item']['data']:_0x1154a4=new wt(_0xdd85b1[_0x363f6e]['item']['data'],_0xdd85b1[_0x363f6e]['item']['getAttributes']()),_0xdd85b1[_0x363f6e+0x1]&&'text'===_0xdd85b1[_0x363f6e+0x1]['type']&&_0x583237(_0x1154a4,_0xdd85b1[_0x363f6e+0x1]['item'])||(_0x300aaf[0x0]['_appendChild'](_0x1154a4),_0x1154a4=null),_0x4e1a04[_0x4e1a04['length']-0x1]+=_0xdd85b1[_0x363f6e]['item']['offsetSize'],_0xdd85b1[_0x363f6e]['nextPosition']=_0x124fb6['createPositionFromPath'](_0x24c994,_0x4e1a04));for(let _0x51d655=0x0;_0x51d655<_0xdd85b1['length'];_0x51d655++){const _0x49d69d=_0xdd85b1[_0x51d655]['previousPosition'],_0x800287=_0xdd85b1[_0x51d655]['nextPosition'];for(const _0x4740d2 of _0xdd85b1[_0x51d655]['markersStart'])_0x10a4cf['set'](_0x4740d2,{'start':_0x49d69d,'end':null});_0x598116('isRemoveSuggestion',_0x51d655,_0x49d69d,_0x800287),_0x598116('isAddSuggestion',_0x51d655,_0x49d69d,_0x800287),_0x598116('isRemoved',_0x51d655,_0x49d69d,_0x800287),_0x598116('isAdded',_0x51d655,_0x49d69d,_0x800287);for(const _0x2e5f90 of _0xdd85b1[_0x51d655]['markersEnd']){_0x10a4cf['get'](_0x2e5f90)['end']=_0x800287;}}for(const [_0x2415ab,_0xa6a1aa]of _0x10a4cf){const _0x1ffcec=this['editor']['model']['createRange'](_0xa6a1aa['start'],_0xa6a1aa['end']);_0x24c994['markers']['set'](_0x2415ab,_0x1ffcec);}return _0x5014c4['sort']((_0x15f355,_0x5078e7)=>{const _0x17d059=_0x24c994['markers']['get']('revision:'+_0x15f355['id']),_0x420e4d=_0x24c994['markers']['get']('revision:'+_0x5078e7['id']);return _0x17d059['start']['isBefore'](_0x420e4d['start'])?-0x1:_0x17d059['start']['isAfter'](_0x420e4d['start'])?0x1:_0x17d059['end']['isBefore'](_0x420e4d['end'])?-0x1:_0x17d059['end']['isAfter'](_0x420e4d['end'])?0x1:'add'===_0x15f355['type']?-0x1:0x1;}),{'root':_0x24c994,'changes':_0x5014c4};function _0x598116(_0xc3f6f9,_0x221fa9,_0x1e5c60,_0x3e90c8){const _0x3a4306=!!_0xdd85b1[_0x221fa9][_0xc3f6f9],_0x320d33=_0x3a4306?_0xdd85b1[_0x221fa9][_0xc3f6f9]['userId']:null,_0x53117e=_0x221fa9===_0xdd85b1['length']-0x1,_0x4a4386=_0x78fadc[_0xc3f6f9][0x0],_0x4bb905=_0x44d2b9['isObject'](_0xdd85b1[_0x221fa9]['item']);!_0x154d59[_0xc3f6f9]&&_0x3a4306?_0x154d59[_0xc3f6f9]={'start':_0x1e5c60,'tapeItem':_0xdd85b1[_0x221fa9],'userId':_0x320d33,'type':_0xc3f6f9}:_0x154d59[_0xc3f6f9]&&!_0x3a4306?(_0x154d59[_0xc3f6f9]['end']=_0x1e5c60,_0xea064f(_0x154d59[_0xc3f6f9]),_0x154d59[_0xc3f6f9]=null):_0x154d59[_0xc3f6f9]&&_0x3a4306&&_0x154d59[_0xc3f6f9]['userId']!==_0x320d33&&(_0x154d59[_0xc3f6f9]['end']=_0x1e5c60,_0x4a4386&&_0x4a4386['userId']===_0x154d59[_0xc3f6f9]['userId']||_0xea064f(_0x154d59[_0xc3f6f9]),_0x154d59[_0xc3f6f9]={'start':_0x1e5c60,'tapeItem':_0xdd85b1[_0x221fa9],'userId':_0x320d33,'type':_0xc3f6f9}),_0x154d59[_0xc3f6f9]&&_0x4bb905&&('elementStart'!==_0xdd85b1[_0x221fa9]['type']||_0x4a4386&&_0x4a4386['userId']===_0x320d33||_0x78fadc[_0xc3f6f9]['unshift']({'userId':_0x320d33,'object':_0xdd85b1[_0x221fa9]['item'],'change':_0x154d59[_0xc3f6f9]}),'elementEnd'===_0xdd85b1[_0x221fa9]['type']&&_0x4a4386&&_0x4a4386['object']===_0xdd85b1[_0x221fa9]['item']&&(_0x78fadc[_0xc3f6f9]['shift'](),_0x154d59[_0xc3f6f9]=_0x4a4386['change'])),_0x154d59[_0xc3f6f9]&&_0x53117e&&(_0x154d59[_0xc3f6f9]['end']=_0x3e90c8,_0xea064f(_0x154d59[_0xc3f6f9]),_0x154d59[_0xc3f6f9]=null);}function _0xea064f({start:_0x41a8c3,end:_0xb53423,tapeItem:_0x589d38,userId:_0x4b0b6b,type:_0x51a7e2}){const _0x2ccaed=_0x589d38['item'],_0x53340d=_0x124fb6['schema']['isBlock'](_0x2ccaed)&&!_0x124fb6['schema']['isLimit'](_0x2ccaed),_0x596d95=_0x41a8c3['nodeAfter']==_0xb53423['parent']&&_0xb53423['isAtStart'];if(_0x53340d&&_0x596d95)return;const _0x59fd7f=_0x124fb6['createRange'](_0x41a8c3,_0xb53423),_0x553cf2=_0x3e292d['get'](_0x4b0b6b),_0x20ea45=new r({'author':_0x553cf2,'type':'isAdded'==_0x51a7e2||'isAddSuggestion'==_0x51a7e2?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x51a7e2||'isRemoveSuggestion'==_0x51a7e2},'createdAt':new Date(),'rootName':_0x9e9ac0});_0x5014c4['push'](_0x20ea45),_0x24c994['markers']['set']('revision:'+_0x20ea45['id'],_0x59fd7f);}function _0x583237(_0x2e991c,_0x2b054b){const _0x1771fc=_0x2e991c['getAttributes'](),_0x162abb=_0x2b054b['getAttributes']();for(const _0xe14272 of _0x1771fc){if(_0xe14272[0x1]!==_0x2b054b['getAttribute'](_0xe14272[0x0]))return!0x1;_0x162abb['next']();}return _0x162abb['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x48b685=>{const _0x3733e2=_0x48b685['markerName']['split'](':')[0x1],_0x3121fe=this['_getChangeFromId'](_0x3733e2);if(!_0x3121fe)return null;const _0x60e492='add'==_0x3121fe['type']?'insertion':'deletion',_0xc7f77c=['ck-suggestion-marker','ck-suggestion-marker-'+_0x60e492];return _0x3121fe['data']['isSuggestion']&&_0xc7f77c['push']('ck-suggestion-marker-'+_0x60e492+'-new'),this['activeChange']==_0x3121fe&&_0xc7f77c['push']('ck-suggestion-marker--active'),{'classes':_0xc7f77c,'attributes':{'data-change-id':_0x3733e2}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x586341=>{_0x586341['on']('element:pre',(_0x8de676,_0x4f60e3,_0x5c3606)=>{const _0x1a9b57=_0x4f60e3['viewItem']['getChild'](0x0);if(!_0x1a9b57||!_0x1a9b57['is']('element','code'))return;if(!_0x5c3606['consumable']['consume'](_0x1a9b57,{'attributes':['vid_start','vid_end']}))return;const _0x3a49b9=_0x4f60e3['modelRange']['start']['nodeAfter'];_0x5c3606['writer']['setAttribute']('vid_start',_0x1a9b57['getAttribute']('vid_start'),_0x3a49b9),_0x5c3606['writer']['setAttribute']('vid_end',_0x1a9b57['getAttribute']('vid_end'),_0x3a49b9);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x244c33=>{_0x244c33['on']('element',(_0x3f8906,_0x7743af,_0x2c7217)=>{if(!_0x2c7217['consumable']['consume'](_0x7743af['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x7743af['modelRange']['isCollapsed'])return;const _0x16a3b3=_0x7743af['modelRange']['start']['nodeAfter'];_0x16a3b3['hasAttribute']('vid_start')||_0x16a3b3['hasAttribute']('vid')||(_0x2c7217['writer']['setAttribute']('vid_start',_0x7743af['viewItem']['getAttribute']('vid_start'),_0x16a3b3),_0x2c7217['writer']['setAttribute']('vid_end',_0x7743af['viewItem']['getAttribute']('vid_end'),_0x16a3b3));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x21d2e6=>_0x21d2e6['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x2bd401,[,_0x52d092])=>{['vid_start','vid_end','vid']['includes'](_0x52d092)&&(_0x2bd401['return']=!0x0,_0x2bd401['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x5ad961=>{_0x5ad961['on']('attribute:vid',(_0xc8d204,_0x3136ac,_0x3efb9b)=>{if('\x20'!=_0x3136ac['item']['data']||_0x3136ac['item']['parent']['maxOffset']>0x1)return;if(!_0x3efb9b['consumable']['consume'](_0x3136ac['item'],_0xc8d204['name']))return;const _0x4473f1=_0x3efb9b['writer'],_0x1ebe8f=_0x3efb9b['mapper']['toViewRange'](_0x3136ac['range']);_0x4473f1['wrap'](_0x1ebe8f,_0x4473f1['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x45efda){const _0x289826=_0x45efda['plugins']['get']('RevisionViewer');return(_0x2614d7,_0x2bf84c,_0x342c33)=>{const _0x10e074=_0x2bf84c['markerName']['split'](':')[0x1],_0xd0051f=_0x289826['_getChangeFromId'](_0x10e074);if(!_0xd0051f)return null;const _0x547003='add'==_0xd0051f['type']?'split':'merge';if(!_0x342c33['consumable']['test'](_0x2bf84c['markerRange'],_0x2614d7['name']))return;const _0x2d206f=_0x2bf84c['markerRange']['getWalker'](),_0x4a5df8=_0x2bf84c['markerRange']['start'],_0x4ad8ac=_0x45efda['model']['schema'];let _0xf1f814=null,_0x335f92=null,_0x4a8484=!0x1,_0x282069=!0x1;for(const _0x92eb7d of _0x2d206f){const _0x10fa90=_0x92eb7d['item'];_0x4a8484=_0x4a8484||_0x4ad8ac['isContent'](_0x10fa90);const _0x643b19=_0x342c33['mapper']['toViewElement'](_0x10fa90);if(_0x643b19&&_0x643b19['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x92eb7d['type']&&(_0x4ad8ac['isBlock'](_0x10fa90)&&!_0x4ad8ac['isLimit'](_0x10fa90)&&(_0x10fa90['nextSibling']||_0x4a5df8['isAtEnd']?_0xf1f814&&_0xf1f814['parent']==_0x10fa90||(_0xf1f814=_0x10fa90,_0x4997fc(_0x92eb7d['previousPosition']),_0x282069=!0x0):_0x335f92=_0x335f92||_0x92eb7d['previousPosition']));}function _0x4997fc(_0xe8c612){const _0x18d786=_0x342c33['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x547003}),_0x134d4e=_0x342c33['mapper']['toViewPosition'](_0xe8c612);_0xd0051f['data']['isSuggestion']&&_0x342c33['writer']['addClass']('ck-suggestion-marker-'+_0x547003+'-new',_0x18d786),_0x289826['activeChange']==_0xd0051f&&_0x342c33['writer']['addClass']('ck-suggestion-marker--active',_0x18d786),_0x342c33['writer']['insert'](_0x134d4e,_0x18d786),_0x342c33['mapper']['bindElementToMarker'](_0x18d786,_0x2bf84c['markerName']);}_0x4a8484||_0x282069||!_0x335f92||_0x4997fc(_0x335f92);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x4b73b4,_0x19a4eb,_0x34bbe6)=>{const _0x22e9fe=_0x34bbe6['mapper']['markerNameToElements'](_0x19a4eb['markerName']);if(_0x22e9fe){for(const _0x335812 of _0x22e9fe)(_0x335812['hasClass']('ck-suggestion-marker-split')||_0x335812['hasClass']('ck-suggestion-marker-merge'))&&(_0x34bbe6['mapper']['unbindElementFromMarkerName'](_0x335812,_0x19a4eb['markerName']),_0x34bbe6['writer']['remove'](_0x335812));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x210bf8,_0x40b22b,_0x5947ee)=>{const _0x38ac18=_0x40b22b['markerName']['split'](':')[0x1],_0x3f071c=this['_getChangeFromId'](_0x38ac18);if(!_0x3f071c)return null;const _0x49e401='add'==_0x3f071c['type']?'split':'merge';if(_0x5947ee['consumable']['test'](_0x40b22b['markerRange'],_0x210bf8['name']))for(const _0x299597 of _0x40b22b['markerRange']['getItems']()){if(!_0x299597['is']('element','softBreak'))continue;const _0x3d723d=_0x5947ee['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x49e401}),_0x2a0dc6=_0x5947ee['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x299597));_0x3f071c['data']['isSuggestion']&&_0x5947ee['writer']['addClass']('ck-suggestion-marker-'+_0x49e401+'-new',_0x3d723d),this['activeChange']==_0x3f071c&&_0x5947ee['writer']['addClass']('ck-suggestion-marker--active',_0x3d723d),_0x5947ee['writer']['insert'](_0x2a0dc6,_0x3d723d),_0x5947ee['mapper']['bindElementToMarker'](_0x3d723d,_0x40b22b['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x3bb00b=>{for(const _0x2952d6 of this['editor']['model']['document']['getRootNames']()){const _0x25ea70=this['editor']['model']['document']['getRoot'](_0x2952d6),_0x30ce5c=this['editor']['editing']['view']['document']['getRoot'](_0x2952d6);if(_0x30ce5c){const _0x45098d=_0x25ea70['getAttribute']('revisionHistoryAttachChange');if(_0x3bb00b['removeAttribute']('data-change-id',_0x30ce5c),_0x3bb00b['removeClass']('ck-revision-history-root-add',_0x30ce5c),_0x3bb00b['removeClass']('ck-revision-history-root-remove',_0x30ce5c),_0x3bb00b['removeClass']('ck-revision-history-root--active',_0x30ce5c),_0x45098d){const _0x311889=this['_getChangeFromId'](_0x45098d);if(!_0x311889)return null;_0x3bb00b['setAttribute']('data-change-id',_0x45098d,_0x30ce5c),_0x3bb00b['addClass']('ck-revision-history-root-'+_0x311889['type'],_0x30ce5c),this['activeChange']==_0x311889&&_0x3bb00b['addClass']('ck-revision-history-root--active',_0x30ce5c);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0xaadf9d=>'revision-comment:'+_0xaadf9d,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x4e1713=>'revision-suggestion:'+_0x4e1713,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x50592e=>({'name':'suggestion:'+_0x50592e,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x59c674=>{const _0x27f48a=_0x59c674['markerName']['split'](':')[0x1];return'insertion'!=_0x27f48a&&'deletion'!=_0x27f48a?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x27f48a]};}}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:deletion',tt(this['editor'],'merge'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:insertion',tt(this['editor'],'split'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision-suggestion',(_0x20b094,_0x3c917a,_0x478292)=>{const _0x17099a=_0x478292['mapper']['markerNameToElements'](_0x3c917a['markerName']);if(_0x17099a){for(const _0x191329 of _0x17099a)_0x191329['is']('uiElement')&&(_0x478292['mapper']['unbindElementFromMarkerName'](_0x191329,_0x3c917a['markerName']),_0x478292['writer']['remove'](_0x191329));}},{'priority':'high'});}['_getChangeFromId'](_0x47cbc6){return this['_changeIdToChange']['get'](_0x47cbc6);}['_getViewForChange'](_0x242b9e){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new Y(this['editor']['locale'],_0x242b9e),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x322dd0,_0x719ba,_0x58014a,_0x5c8052)=>{_0x5c8052&&this['_balloon']['remove'](_0x5c8052),_0x58014a&&(this['_balloon']['add']({'view':_0x58014a,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x57b623=this['editor']['editing'],_0x29125d=this['_getChangeFromId'](_0x58014a['changeId']);let _0x32ff87;if(_0x29125d['data']['isOnRoot']){const _0x38442=_0x57b623['view']['getDomRoot'](_0x29125d['rootName']);_0x32ff87=Array['from'](_0x38442['getClientRects']());}else{const _0x371b52=this['editor']['model']['markers']['get']('revision:'+_0x58014a['changeId']);_0x32ff87=Array['from'](_0x57b623['mapper']['markerNameToElements'](_0x371b52['name']))['map'](_0x564799=>_0x57b623['view']['domConverter']['mapViewToDom'](_0x564799))['map'](_0x1d3a75=>Array['from'](_0x1d3a75['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x32ff87[0x0];return _0x32ff87['find'](_0x25b185=>_0x25b185['top']-0x3<=this['_activeViewTarget']['y']&&_0x25b185['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x25b185['left']-0x3<=this['_activeViewTarget']['x']&&_0x25b185['right']+0x3>=this['_activeViewTarget']['x'])||_0x32ff87[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x481bf4,_0x2197c6,_0x1a729c,_0x3d2633)=>{this['activeView']=_0x1a729c?this['_getViewForChange'](_0x1a729c):null,this['editor']['model']['change'](()=>{const _0x4a5813=this['editor']['editing'];_0x3d2633&&(_0x3d2633['data']['isOnRoot']?_0x4a5813['view']['change'](_0x2c289c=>{_0x2c289c['removeClass']('ck-revision-history-root--active',_0x4a5813['view']['document']['getRoot'](_0x3d2633['rootName']));}):_0x4a5813['reconvertMarker']('revision:'+_0x3d2633['id'])),_0x1a729c&&(_0x1a729c['data']['isOnRoot']?_0x4a5813['view']['change'](_0x117f98=>{_0x117f98['addClass']('ck-revision-history-root--active',_0x4a5813['view']['document']['getRoot'](_0x1a729c['rootName']));}):_0x4a5813['reconvertMarker']('revision:'+_0x1a729c['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x372594,_0xf11ead)=>{if(this['activeChange'])return;const _0xa9515b=this['_findChangeIdFromDomTarget'](_0xf11ead['target']),_0x3b647c=this['_changeIdToChange']['get'](_0xa9515b);_0x3b647c?(this['_activeViewTarget']={'x':_0xf11ead['domEvent']['x'],'y':_0xf11ead['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x3b647c)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x1f4e46,_0x3ea297)=>{const _0xddd977=this['_findChangeIdFromDomTarget'](_0x3ea297['target']),_0x22fdae=this['_changeIdToChange']['get'](_0xddd977);_0x22fdae?(this['_activeViewTarget']={'x':_0x3ea297['domEvent']['x'],'y':_0x3ea297['domEvent']['y']},_0x22fdae===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x22fdae):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x4b4ed6){do{const _0x1b175d=_0x4b4ed6['getAttribute']('data-change-id');if(_0x1b175d)return _0x1b175d;_0x4b4ed6=_0x4b4ed6['parent'];}while(_0x4b4ed6);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x422628=>{for(const _0xee6dc2 of this['editor']['model']['markers'])_0x422628['removeMarker'](_0xee6dc2);});}}function tt(_0x2f3ff4,_0x5768d3){return(_0x21e501,_0x274401,_0x282696)=>{if(!_0x282696['consumable']['test'](_0x274401['markerRange'],_0x21e501['name']))return;const _0x4b186c=_0x274401['markerRange']['getWalker'](),_0x37636e=_0x274401['markerRange']['start'],_0x41ebb1=_0x2f3ff4['model']['schema'];let _0x388639=null,_0x875389=null,_0x2a065b=!0x1,_0x1662b0=!0x1;for(const _0x5769e4 of _0x4b186c){const _0x687163=_0x5769e4['item'];_0x2a065b=_0x2a065b||_0x41ebb1['isContent'](_0x687163);const _0x3df7c4=_0x282696['mapper']['toViewElement'](_0x687163);if(_0x3df7c4&&_0x3df7c4['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x5769e4['type']&&(_0x41ebb1['isBlock'](_0x687163)&&!_0x41ebb1['isLimit'](_0x687163)&&(_0x687163['nextSibling']||_0x37636e['isAtEnd']?_0x388639&&_0x388639['parent']==_0x687163||(_0x388639=_0x687163,_0x2dbb8b(_0x5769e4['previousPosition']),_0x1662b0=!0x0):_0x875389=_0x875389||_0x5769e4['previousPosition']));}function _0x2dbb8b(_0x111e0b){const _0x5dc1ae=_0x282696['mapper']['toViewPosition'](_0x111e0b),_0x540cbb=_0x282696['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x5768d3});_0x282696['writer']['insert'](_0x5dc1ae,_0x540cbb),_0x282696['mapper']['bindElementToMarker'](_0x540cbb,_0x274401['markerName']);}_0x2a065b||_0x1662b0||!_0x875389||_0x2dbb8b(_0x875389);};}class _t extends _0x347c79{constructor(_0x424ba3){super(_0x424ba3);const _0xb2456e=_0x424ba3['plugins']['get'](d);this['affectsData']=!0x1,this['listenTo'](_0xb2456e,'change:isReady',()=>this['refresh']()),this['listenTo'](_0xb2456e,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x5f48fe=this['editor'],_0x376532=_0x5f48fe['plugins']['get'](d),_0x23a1c4=_0x376532['isReady']?_0x376532['diff']['newRevisionId']:null;_0x5f48fe['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x23a1c4);}['refresh'](){const {isReady:_0x53eee7,isEnabled:_0x531271,repository:_0x50276b,diff:_0x15e5ef}=this['editor']['plugins']['get'](d),_0x40e0c3=_0x15e5ef&&_0x50276b['getLaterVisibleRevision'](_0x15e5ef['newRevisionId']);this['isEnabled']=_0x53eee7&&_0x531271&&Boolean(_0x40e0c3);}}class yt extends _0x347c79{['_step'];constructor(_0x558ae0,{direction:_0x30c119}){super(_0x558ae0);const _0x4b4bae=_0x558ae0['plugins']['get'](d);this['affectsData']=!0x1,this['_step']='forward'===_0x30c119?0x1:-0x1,this['listenTo'](_0x4b4bae,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x4b4bae,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x4b4bae,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x452953=this['editor'],_0x30b146=_0x452953['plugins']['get'](d),{isNavigationMode:_0x17fbb9,currentChangeNumber:_0x4f4981}=_0x30b146;let _0x43e3b6;if(_0x30b146['activeChange']=_0x17fbb9?_0x30b146['diff']['changes']['get'](_0x4f4981+this['_step']):_0x30b146['diff']['changes']['first'],_0x30b146['activeChange']['data']['isOnRoot'])_0x43e3b6=_0x452953['editing']['view']['getDomRoot'](_0x30b146['activeChange']['rootName']);else{const _0x342514=_0x452953['model']['markers']['get']('revision:'+_0x30b146['activeChange']['id']);_0x43e3b6=_0x2a2631(_0x452953['editing'],_0x342514);}_0x2beaa4({'target':_0x43e3b6,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x28b799,currentChangeNumber:_0x40c2ed,numberOfChanges:_0x26896d,isReady:_0x5ccda9,isEnabled:_0x4e6e46}=this['editor']['plugins']['get'](d);this['isEnabled']=!!(_0x4e6e46&&_0x5ccda9&&_0x26896d)&&(!_0x28b799||(0x1===this['_step']?_0x40c2ed<_0x26896d-0x1:_0x40c2ed>0x0));}}class di extends ts{constructor(_0xb4f375){super(_0xb4f375);const _0x1749de=this['bindTemplate'],_0x544aba=new te(_0xb4f375),_0xb1e45e=new te(_0xb4f375);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',(_0x770d89,_0x26c82a)=>_0x770d89&&_0x26c82a>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0xd55e4e,_0x2c3b04,_0x21c542,_0x47b93b)=>{if(!_0xd55e4e)return R(_0xb4f375,'Loading...');if(!_0x21c542)return R(_0xb4f375,'No\x20changes');const _0x194f3d=R(_0xb4f375,'NUMBER_OF_CHANGES',_0x21c542);return _0x47b93b?R(_0xb4f375,'X_OF_Y_CHANGES',[_0x2c3b04+0x1,_0x21c542]):_0x194f3d;}),_0x544aba['set']({'label':R(_0xb4f375,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':'<svg\x20viewBox=\x220\x200\x2020\x2020\x22\x20xmlns=\x22http://www.w3.org/2000/svg\x22><path\x20d=\x22M16.435\x2014.494a.75.75\x200\x200\x200\x201.197-.899l-.067-.089-6.992-8a.75.75\x200\x200\x200-1.05-.078l-.079.078-7.008\x208a.75.75\x200\x200\x200\x201.049\x201.066l.08-.078\x206.442-7.354\x206.428\x207.354z\x22/></svg>\x0a'}),_0xb1e45e['set']({'label':R(_0xb4f375,'Show\x20next\x20change'),'tooltip':!0x0,'icon':'<svg\x20viewBox=\x220\x200\x2020\x2020\x22\x20xmlns=\x22http://www.w3.org/2000/svg\x22><path\x20d=\x22M16.435\x205.506a.75.75\x200\x200\x201\x201.197.899l-.067.089-6.992\x208a.75.75\x200\x200\x201-1.05.078l-.079-.078-7.008-8a.75.75\x200\x200\x201\x201.049-1.066l.08.078\x206.442\x207.354\x206.428-7.354z\x22/></svg>\x0a'}),_0x544aba['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0xb1e45e['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x544aba['on']('execute',()=>this['fire']('execute','backward')),_0xb1e45e['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',_0x1749de['if']('_isStatusLabelVisible','ck-hidden',_0x523d98=>!_0x523d98)]},'children':[{'text':_0x1749de['to']('isNavigationMode',_0x361efe=>_0x361efe?R(_0xb4f375,'EDIT_X_OF_Y_REVISIONS')+':\x20':R(_0xb4f375,'Total')+':\x20')}]},{'text':_0x1749de['to']('_statusText')}]},new _0x43f5d3(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x544aba,_0xb1e45e]}]});}}const le='ck-editor__editable__loading-overlay';class ge extends _0x27f686{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x1469be=this['editor']['editing']['view'];_0x1469be['change'](_0x2f0674=>{for(const _0x1013b3 of _0x1469be['document']['roots'])_0x2f0674['addClass'](le,_0x1013b3);});}['hide'](){const _0xd11ca9=this['editor']['editing']['view'];_0xd11ca9['change'](_0x53e477=>{for(const _0xeb6cee of _0xd11ca9['document']['roots'])_0x53e477['removeClass'](le,_0xeb6cee);});}}class m extends _0x27f686{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[d,ge];}['init'](){const _0x1e7cfa=this['editor'],_0x331b2e=_0x1e7cfa['plugins']['get'](d),_0x28ca2a=_0x1e7cfa['plugins']['get'](ge);_0x1e7cfa['ui']['componentFactory']['add']('exitToEditing',_0x50d334=>{const _0x158758=new te(_0x50d334);return _0x158758['set']({'label':R(_0x50d334,'Back\x20to\x20editing'),'icon':_0x57211a['undo'],'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x158758,'execute',()=>{_0x1e7cfa['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x158758;}),_0x1e7cfa['ui']['componentFactory']['add']('restoreRevision',_0x391f29=>{const _0xaf7467=new te(_0x391f29);return _0xaf7467['set']({'label':R(_0x391f29,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0xaf7467['bind']('isEnabled')['to'](_0x1e7cfa['commands']['get']('restoreRevision')),this['listenTo'](_0xaf7467,'execute',()=>_0x1e7cfa['execute']('restoreRevision')),_0xaf7467;}),_0x1e7cfa['ui']['componentFactory']['add']('changesNavigation',_0xc28ffe=>{const _0x104d29=new di(_0xc28ffe),_0x14e1f1=_0x1e7cfa['commands']['get']('showPreviousChange'),_0x5b5b6a=_0x1e7cfa['commands']['get']('showNextChange');return _0x104d29['bind']('isBackwardNavigationEnabled')['to'](_0x14e1f1,'isEnabled'),_0x104d29['bind']('isForwardNavigationEnabled')['to'](_0x5b5b6a,'isEnabled'),_0x104d29['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x331b2e),this['listenTo'](_0x104d29,'execute',(_0xd1797c,_0x4daf09)=>{_0x1e7cfa['execute']('forward'===_0x4daf09?'showNextChange':'showPreviousChange');}),_0x104d29;}),_0x28ca2a['show'](),_0x331b2e['on']('change:isReady',(_0x4f4713,_0x5cfb78,_0x4e5496)=>{_0x4e5496?_0x28ca2a['hide']():_0x28ca2a['show']();});}}class pt extends _0x1ea983{['_resizeObserver']=null;constructor(_0x2e4b35,_0x3ad3cd){super(_0x2e4b35,_0x3ad3cd);const _0x593e7e=this['bindTemplate'];this['set']({'label':R(_0x2e4b35,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=R(_0x2e4b35,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x593e7e['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 _0x5e49ae=this['fieldView']['element'];this['_tooltipString']=_0x5e49ae['scrollWidth']>_0x5e49ae['clientWidth']&&_0x5e49ae['value']||'';}}class oi extends ts{constructor(_0x297864,_0x21b5ee,_0x20448f){super(_0x297864);const _0x354c4b=new _0x3e2bc7();_0x354c4b['set']({'content':'<svg\x20viewBox=\x220\x200\x2011\x2010\x22\x20xmlns=\x22http://www.w3.org/2000/svg\x22\x20xmlns:xlink=\x22http://www.w3.org/1999/xlink\x22><path\x20d=\x22M5.5\x205C8.538\x205\x2011\x207.015\x2011\x209.5c0\x20.17-.011.336-.034.5H.034A3.732\x203.732\x200\x200\x201\x200\x209.5C0\x207.015\x202.462\x205\x205.5\x205zm0-5a2.5\x202.5\x200\x201\x201\x200\x205\x202.5\x202.5\x200\x200\x201\x200-5z\x22\x20/></svg>\x0a','viewBox':'0\x200\x2011\x2010'});const _0x1539a1=['ck','ck-revision-history-sidebar__revision-author'];_0x20448f&&_0x1539a1['push']('ck-revision-history-sidebar__revision-author_creator');const _0x32d49f=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':R(_0x297864,_0x20448f?'Revision\x20creator':'Revision\x20author')},'children':[_0x354c4b,_0x21b5ee['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x1539a1},'children':_0x32d49f});}}function ai(_0x4aaae4,_0x3fcb2c){const _0x404a72=_0x4aaae4['bindTemplate'],_0x272f47=_0x4aaae4['locale'],_0x197eb4=_0x47635c(_0x272f47);_0x197eb4['panelPosition']='sw';const _0x20add2=function(_0x26d6b6,_0x2c9787){const _0x135625=function(_0x43e3f3,_0x1c7c48){const _0x43673e=_0x43e3f3['locale'],_0x4fbdf={'Compare\x20against\x20selected':R(_0x43673e,'Compare\x20against\x20selected'),'Name\x20this\x20revision':R(_0x43673e,'Name\x20this\x20revision'),'Restore\x20this\x20revision':R(_0x43673e,'Restore\x20this\x20revision')};return _0x1c7c48['map'](_0x1cfb9c=>{const _0x553ea6=_0x4fbdf[_0x1cfb9c['name']];return _0x553ea6&&_0x553ea6!==_0x1cfb9c['name']&&(_0x1cfb9c['name']=_0x553ea6),_0x1cfb9c;});}(_0x26d6b6,_0x2c9787),_0x280dab=new _0x2987a6();for(const _0x20a27c of _0x135625){const _0x23c5f2={'type':'button','model':new _0x573354({'label':_0x20a27c['name'],'class':_0x20a27c['class'],'withText':!0x0,'role':'menuitem','_action':_0x20a27c['action']})};_0x23c5f2['model']['bind']('isEnabled')['to'](_0x26d6b6,'isActionsDropdownOpen',_0x33a428=>'function'!=typeof _0x20a27c['isEnabled']||(!_0x33a428||_0x20a27c['isEnabled'](_0x26d6b6))),_0x280dab['add'](_0x23c5f2);}return _0x280dab;}(_0x4aaae4,_0x3fcb2c);return _0x4aaae4['bind']('isActionsDropdownOpen')['to'](_0x197eb4,'isOpen'),_0x197eb4['buttonView']['set']({'label':R(_0x272f47,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x57211a['threeVerticalDots']}),_0x197eb4['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x404a72['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x404a72['to'](_0x521ded=>_0x521ded['stopPropagation']())}}),_0x197eb4['on']('execute',_0x386fda=>{_0x4aaae4['isReady']&&'function'==typeof _0x386fda['source']['_action']&&_0x386fda['source']['_action'](_0x4aaae4);}),to(_0x197eb4,_0x20add2,{'role':'menu'}),_0x197eb4['listenTo'](_0x4aaae4,'change:isActionsDropdownOpen',(_0x31b23b,_0x37d27f,_0x4583c5)=>{if(_0x4583c5)for(const _0x5c1d9a of _0x197eb4['listView']['items']){const _0x1946ff=_0x5c1d9a['children']['first'],_0x4452c6=_0x3fcb2c['find'](_0x5b99f3=>_0x5b99f3['action']===_0x1946ff['_action'])['isVisible'];_0x5c1d9a['isVisible']=void 0x0===_0x4452c6||_0x4452c6(_0x4aaae4);}}),_0x197eb4;}class si extends/* #__PURE__ -- @preserve */
26
- _0x5d9caa(ts){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x5ef8be,_0x2f55c9,_0x57e044,_0x316573){super(_0x5ef8be);const _0x46aa30=this['bindTemplate'],_0x27a080=function(_0x2c154b,_0x976d26){const _0x2dbf91=Array['from'](_0x976d26['authors'])['filter'](_0x22bf1b=>_0x22bf1b!=_0x976d26['creator']);return _0x976d26['creator']&&_0x2dbf91['unshift'](_0x976d26['creator']),_0x2dbf91['map'](_0x31d106=>new oi(_0x2c154b,_0x31d106,_0x31d106==_0x976d26['creator']));}(_0x5ef8be,_0x2f55c9);this['id']=_0x2f55c9['id'],this['_revision']=_0x2f55c9,this['_requireRevisionName']=_0x316573,this['bind']('name','createdAt')['to'](_0x2f55c9),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x2010ab=>{return _0xf5942d=_0x5ef8be['uiLanguage'],(_0x43302d=_0x2010ab)['toLocaleDateString'](_0xf5942d,{'month':'long','day':'numeric'})+',\x20'+_0x43302d['toLocaleTimeString'](_0xf5942d,{'hour':'numeric','minute':'numeric'});var _0xf5942d,_0x43302d;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new pt(_0x5ef8be,_0x57df33),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x3ef8ba=>_0x3ef8ba||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x2052ea,_0x4a7d38)=>_0x2052ea&&_0x4a7d38),this['revisionActionsView']=_0x57e044&&_0x57e044['length']?ai(this,_0x57e044):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x46aa30['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x46aa30['if']('isEnabled','ck-disabled',_0x5ee337=>!_0x5ee337),_0x46aa30['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x46aa30['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x46aa30['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':_0x46aa30['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':_0x27a080}]},this['revisionActionsView']],'on':{'click':_0x46aa30['to'](_0x1db3c8=>{_0x1db3c8['srcElement']['closest']('.ck-thread__remove-confirm')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x2e5657=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x2e5657,'change',()=>{this['_requireRevisionName']&&!_0x2e5657['value']||this['fire']('setName',{'id':this['id'],'name':_0x2e5657['value']}),_0x2e5657['value']||(_0x2e5657['value']=this['name']?this['name']:this['_createdAtFormatted']);});}['select'](){this['isSelected']=!0x0;}['deselect'](){this['isSelected']=!0x1;}['highlight'](){this['isHighlighted']=!0x0;}['unhighlight'](){this['isHighlighted']=!0x1;}}function ti(_0x719952,_0x4a3676){const _0x16ae22=_0x30e612['fromJSDate'](_0x719952)['setLocale'](_0x4a3676),_0x428eb1=_0x30e612['local'](),_0x3eea9e=_0x428eb1['minus']({'days':0x1})['startOf']('day');let _0x1f8092,_0x5861f1;return _0x16ae22['hasSame'](_0x428eb1,'day')?(_0x1f8092=_0x16ae22['startOf']('day')['toJSDate'](),_0x5861f1=_0x16ae22['toRelativeCalendar']()):_0x16ae22['hasSame'](_0x3eea9e,'day')?(_0x1f8092=_0x3eea9e['toJSDate'](),_0x5861f1=_0x16ae22['toRelativeCalendar']()):_0x16ae22['hasSame'](_0x428eb1,'week')?(_0x1f8092=_0x16ae22['startOf']('week')['toJSDate'](),_0x5861f1=_0x16ae22['weekdayLong']||''):_0x16ae22['hasSame'](_0x428eb1,'year')?(_0x1f8092=_0x16ae22['startOf']('month')['toJSDate'](),_0x5861f1=_0x16ae22['monthLong']||''):(_0x1f8092=_0x16ae22['startOf']('year')['toJSDate'](),_0x5861f1=String(_0x16ae22['year'])),{'startDate':_0x1f8092,'localizedPeriodName':_0x5861f1};}class ei extends ts{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x20a8f7,_0x5598f4,_0x7c2910,_0x15547c){super(_0x20a8f7);const _0x29c49c=ti(_0x5598f4,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x5598f4,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x7c2910,this['_requireRevisionName']=_0x15547c,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':_0x29c49c}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x528ca5){const _0x5d9444=new si(this['locale'],_0x528ca5,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x5d9444);}['removeRevision'](_0x3e037b){const _0x355df6=this['revisionViews']['find'](_0x2a8f85=>_0x2a8f85['id']===_0x3e037b['id']);this['revisionViews']['remove'](_0x355df6);}}class cs extends ts{constructor(_0x93f1d9){super(_0x93f1d9);const _0x392b69=new _0x3e2bc7();_0x392b69['content']=_0x57211a['history'],this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x392b69,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[R(_0x93f1d9,'Revision\x20history')]}]});}}class ii extends ts{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x3fd3a2,_0x17aa81,_0x5b0a69,_0x233b91){super(_0x3fd3a2);const _0x1c09a6=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x17aa81,this['_revisionActions']=_0x5b0a69,this['_requireRevisionName']=_0x233b91,this['on']('select',(_0x2423f3,_0x200df2)=>{this['fire']('revisionSelected',_0x200df2);}),this['on']('setName',(_0x503b35,_0x2a5a72)=>{this['fire']('revisionSetName',_0x2a5a72);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new cs(_0x3fd3a2),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x1c09a6['if']('isEnabled','ck-disabled',_0x26df16=>!_0x26df16)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0xc93aa8 of this['_revisions'])this['_addRevision'](_0xc93aa8);this['_revisions']['on']('add',(_0x34e207,_0xeda6db)=>{this['_addRevision'](_0xeda6db);}),this['_revisions']['on']('remove',(_0x17478e,_0x1d58b1)=>{this['_removeRevision'](_0x1d58b1);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x1e52b7=>_0x1e52b7['revisionViews']['map'](_0x1358ee=>_0x1358ee))['flat']();}['selectRevision'](_0x8a9c10){for(const _0xc5a755 of this['revisionViews'])_0x8a9c10&&_0x8a9c10['id']===_0xc5a755['id']?_0xc5a755['select']():_0xc5a755['deselect']();}['highlightRevisions'](_0x389e20){for(const _0x25303b of this['revisionViews'])_0x389e20['some'](({id:_0x3fc8e2})=>_0x3fc8e2===_0x25303b['id'])?_0x25303b['highlight']():_0x25303b['unhighlight']();}['_addRevision'](_0x5d21cd){const _0x2c537f=ti(_0x5d21cd['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x2c4f6d=this['timePeriodViews']['get'](0x0);_0x2c4f6d&&_0x2c4f6d['startDate']['getTime']()===_0x2c537f['getTime']()||(_0x2c4f6d=new ei(this['locale'],_0x2c537f,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x2c4f6d)),_0x2c4f6d['addRevision'](_0x5d21cd);}['_removeRevision'](_0x103b6e){const _0x389758=ti(_0x103b6e['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x389758)['removeRevision'](_0x103b6e);}['_getTimePeriodViewByStartDate'](_0x571c0f){return this['timePeriodViews']['find'](_0x246170=>_0x246170['startDate']['getTime']()===_0x571c0f['getTime']());}}class g extends _0x27f686{['_revisionViewer'];['_revisionsRepository'];['_sidebarView'];static ['defaultRevisionActions']=/* #__PURE__ -- @preserve */
23
+ import{ObservableMixin as _0x66ca88,uid as _0xb3cc0b,Collection as _0x199961,logWarning as _0x52977e,FocusTracker as _0x452fb4,KeystrokeHandler as _0x4535b7,scrollViewportToShowTarget as _0x511da0,ResizeObserver as pt,ElementReplacer as ct,CKEditorError as _0x41ec69}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x3c49e8,set as _0x42474c,unset as _0x5baac4,isEqual as _0x59f093}from'lodash-es';import{Plugin as _0x2ebc56,PendingActions as _0x364901,icons as _0xaa90df,Command as _0x255895,ElementApiMixin as rt,Editor as it}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x305d7f,getMarkerDomElement as _0x569c81,ConfirmMixin as _0x20e829,sanitizeEditorConfig as _0x4ae533}from'ckeditor5-collaboration/dist/index.js';import{ViewDocumentFragment as _0x471757,ViewText as _0x7c92df,ViewElement as _0x3b6ead,Element as ft,Range as vt,Position as gt,DocumentFragment as wt,ViewContainerElement as _0x26af22,ViewAttributeElement as _0x505635,ViewEmptyElement as _0x3ff6a6,ViewRawElement as _0x4abad2,ViewUIElement as _0x29510a,Text as _t}from'@ckeditor/ckeditor5-engine/dist/index.js';import{View as _0x4be5f7,injectCssTransitionDisabler as ts,submitHandler as _0x1aed20,LabeledFieldView as at,createLabeledInputText as _0xbf0be,createDropdown as _0x30f9aa,ListView as te,ListItemView as _0x5a8f54,ButtonView as _0x5ae3a4,MenuBarMenuView as _0x249393,MenuBarMenuListView as _0x59a9bd,MenuBarMenuListItemView as _0x4d54e9,MenuBarMenuListItemButtonView as _0x1548c1,ContextualBalloon as _0xfee5aa,ToolbarSeparatorView as _0x1bf43e,IconView as _0xb87865,addListToDropdown as _0x28484e,ViewModel as to,EditorUI as ot,normalizeToolbarConfig as ht,BoxedEditorUIView as dt,StickyPanelView as lt,ToolbarView as nt,InlineEditableUIView as ut}from'@ckeditor/ckeditor5-ui/dist/index.js';import{DateTime as _0x5b91d0}from'luxon';class a extends/* #__PURE__ -- @preserve */
24
+ _0x66ca88(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x4d9b3e){super(),this['id']=_0x4d9b3e['id']||_0xb3cc0b(),this['creator']=_0x4d9b3e['creator']||null,this['authors']=_0x4d9b3e['authors']||[],this['diffData']=_0x4d9b3e['diffData']||null,this['toVersion']=_0x4d9b3e['toVersion']||0x0,this['fromVersion']=_0x4d9b3e['fromVersion']||0x0,this['set']('name',_0x4d9b3e['name']||''),this['set']('createdAt',_0x4d9b3e['createdAt']||new Date()),this['set']('attributes',_0x4d9b3e['attributes']||{});}['setName'](_0x454313){this['_update']({'name':_0x454313});}['setAttribute'](_0x126786,_0x226093){const _0x505797=_0x3c49e8(this['attributes']);_0x42474c(_0x505797,_0x126786,_0x226093),this['_update']({'attributes':_0x505797});}['removeAttribute'](_0x553a6c){const _0x867594=_0x3c49e8(this['attributes']);_0x5baac4(_0x867594,_0x553a6c),this['_update']({'attributes':_0x867594});}['_update'](_0x4e152d,_0x5916f2=!0x1){let _0x17d570=!0x1;const _0x304a12={'id':this['id']},_0x46f103=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x1072b1 of _0x46f103){const _0x54e277=_0x4e152d[_0x1072b1];void 0x0!==_0x54e277&&_0x54e277!==this[_0x1072b1]&&(this[_0x1072b1]=_0x54e277,_0x304a12[_0x1072b1]=_0x54e277,_0x17d570=!0x0);}_0x17d570&&(_0x304a12['authors']&&(_0x304a12['authorsIds']=_0x304a12['authors']['map'](_0xcfa73c=>_0xcfa73c['id']),delete _0x304a12['authors']),this['fire']('_update',_0x304a12,_0x5916f2));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x51c5f3=>_0x51c5f3['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class j extends _0x2ebc56{['_revisions'];static get['requires'](){return[_0x305d7f];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x3a9d60){super(_0x3a9d60),this['_revisions']=new _0x199961();}['afterInit'](){!async function(_0x317649){const _0x57eeb0=_0x9f0913([0x74,0x4f,0x45,0x71,0x5a,0x37,0x38,0x53,0x33,0x50,0x57,0x59,0x78,0x4b,0x4a,0x6b,0x4e,0x6e,0x75,0x42,0x4c,0x36,0x6c,0x35,0x7a,0x54,0x62,0x41,0x55,0x63,0x56,0x49,0x79,0x64,0x65,0x58,0x47,0x73,0x77,0x68,0x39,0x72,0x51,0x67,0x44,0x6a,0x76,0x32,0x61,0x48,0x46,0x43,0x66,0x6f,0x52,0x34,0x6d,0x70,0x31,0x4d,0x30,0x69]),_0x320bd1=0xeb829,_0xace388=0x5e324e4a,_0x310cbb=0x5e3517e2^_0xace388,_0x23e624=window[_0x9f0913([0x44,0x61,0x74,0x65])][_0x9f0913([0x6e,0x6f,0x77])](),_0xa10223=_0x317649[_0x9f0913([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x3ca702=new window[(_0x9f0913([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x4fa73d=>{_0xa10223[_0x9f0913([0x6f,0x6e,0x63,0x65])](_0x9f0913([0x72,0x65,0x61,0x64,0x79]),_0x4fa73d);}),_0x484a0a={[_0x9f0913([0x6b,0x74,0x79])]:_0x9f0913([0x45,0x43]),[_0x9f0913([0x75,0x73,0x65])]:_0x9f0913([0x73,0x69,0x67]),[_0x9f0913([0x63,0x72,0x76])]:_0x9f0913([0x50,0x2d,0x32,0x35,0x36]),[_0x9f0913([0x78])]:_0x9f0913([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]),[_0x9f0913([0x79])]:_0x9f0913([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]),[_0x9f0913([0x61,0x6c,0x67])]:_0x9f0913([0x45,0x53,0x32,0x35,0x36])},_0x369ecd=_0xa10223[_0x9f0913([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x9f0913([0x67,0x65,0x74])](_0x9f0913([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x507b85(){let _0x437e17,_0x30e93a=null,_0x5c5426=null;try{if(_0x369ecd==_0x9f0913([0x47,0x50,0x4c]))return _0x9f0913([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x437e17=_0x6f4103(),!_0x437e17)return _0x9f0913([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x437e17[_0x9f0913([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x5c5426=_0x250653(_0x437e17[_0x9f0913([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x437e17[_0x9f0913([0x6a,0x74,0x69])])),await _0x1d1035()?_0x4cb021()?_0x180c72()?_0x9f0913([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x39d439()?(_0x437e17[_0x9f0913([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x9f0913([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x30e93a=_0x5ce5cb(_0x9f0913([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x437e17[_0x9f0913([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x9f0913([0x74,0x72,0x69,0x61,0x6c])&&(_0x30e93a=_0x5ce5cb(_0x9f0913([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),_0x437e17[_0x9f0913([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x9f0913([0x64,0x65,0x76,0x65,0x6c,0x6f,0x70,0x6d,0x65,0x6e,0x74])&&(_0x30e93a=_0x5ce5cb(_0x9f0913([0x44,0x65,0x76,0x65,0x6c,0x6f,0x70,0x6d,0x65,0x6e,0x74,0x4c,0x69,0x6d,0x69,0x74]))),await _0xf8c12d()):_0x9f0913([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x9f0913([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x9f0913([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch(_0x497072){return _0x9f0913([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x180c72(){const _0x27e050=[_0x9f0913([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x9f0913([0x74,0x72,0x69,0x61,0x6c])][_0x9f0913([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x437e17[_0x9f0913([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x23e624/0x3e8:0xe10*_0x310cbb;return _0x437e17[_0x9f0913([0x65,0x78,0x70])]<_0x27e050;}function _0x4cb021(){const _0x3839ce=_0x437e17[_0x9f0913([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x3839ce)return!0x1;if(_0x3839ce[_0x9f0913([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x9f0913([0x2a])))return!0x0;if(_0x3839ce[_0x9f0913([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x9f0913([0x52,0x48])))return!0x0;if(_0x3839ce[_0x9f0913([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x9f0913([0x52,0x52,0x48]))){if(_0x1f6795())return!0x0;if(_0xa5e92b()||_0x2e37c0())return!0x0;}return!0x1;}function _0x39d439(){const _0x197015=_0x437e17[_0x9f0913([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x197015||0x0==_0x197015[_0x9f0913([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x2d142f}=new URL(window[_0x9f0913([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x197015[_0x9f0913([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x2d142f))return!0x0;const _0x1ac386=_0x2d142f[_0x9f0913([0x73,0x70,0x6c,0x69,0x74])](_0x9f0913([0x2e]));return _0x197015[_0x9f0913([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x321125=>_0x321125[_0x9f0913([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x9f0913([0x2a])))[_0x9f0913([0x6d,0x61,0x70])](_0x55ac20=>_0x55ac20[_0x9f0913([0x73,0x70,0x6c,0x69,0x74])](_0x9f0913([0x2e])))[_0x9f0913([0x73,0x6f,0x6d,0x65])](_0x152a74=>_0x1ac386[_0x9f0913([0x65,0x76,0x65,0x72,0x79])]((_0x58acb1,_0x10ca40)=>_0x152a74[_0x10ca40]===_0x58acb1||_0x152a74[_0x10ca40]===_0x9f0913([0x2a])));}function _0xf8c12d(){return _0x30e93a&&_0x5c5426?new window[(_0x9f0913([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x4e4a8a,_0x5e0718)=>{_0x30e93a[_0x9f0913([0x74,0x68,0x65,0x6e])](_0x4e4a8a,_0x5e0718),_0x5c5426[_0x9f0913([0x74,0x68,0x65,0x6e])](_0x4577bd=>{_0x4577bd!=_0x9f0913([0x56,0x61,0x6c,0x69,0x64])&&_0x4e4a8a(_0x4577bd);},_0x5e0718);}):_0x30e93a||_0x5c5426||_0x9f0913([0x56,0x61,0x6c,0x69,0x64]);}}function _0x250653(_0x38f559,_0x528aab){return new window[(_0x9f0913([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x18e6c2=>{if(_0x1dbd95())return _0x18e6c2(_0x9f0913([0x56,0x61,0x6c,0x69,0x64]));_0x515f89(),_0xa10223[_0x9f0913([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x9f0913([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x337871=!0x1;const _0x1aadbb=_0xb3cc0b();function _0xa6ea3c(_0x3ba9b7){return!!_0x3ba9b7&&(typeof _0x3ba9b7===_0x9f0913([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x3ba9b7===_0x9f0913([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x3ba9b7[_0x9f0913([0x74,0x68,0x65,0x6e])]===_0x9f0913([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x3ba9b7[_0x9f0913([0x63,0x61,0x74,0x63,0x68])]===_0x9f0913([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x2a48b6(_0x2091a1){_0x396e36(_0x2091a1)[_0x9f0913([0x74,0x68,0x65,0x6e])](_0x26c93c=>{if(!_0x26c93c||_0x26c93c[_0x9f0913([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x9f0913([0x6f,0x6b]))return _0x9f0913([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x561632(_0x418095(_0x1aadbb+_0x528aab))!=_0x26c93c[_0x9f0913([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x9f0913([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x9f0913([0x56,0x61,0x6c,0x69,0x64]);})[_0x9f0913([0x74,0x68,0x65,0x6e])](_0x4e4bc1=>(_0x500f91(),_0x4e4bc1),()=>{const _0x2da9ad=_0x1a0d21();return null==_0x2da9ad?(_0x500f91(),_0x9f0913([0x56,0x61,0x6c,0x69,0x64])):_0x9f0913(_0x23e624-_0x2da9ad>(0x7a3eca4a^_0xace388)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x9f0913([0x74,0x68,0x65,0x6e])](_0x18e6c2)[_0x9f0913([0x63,0x61,0x74,0x63,0x68])](()=>{_0x18e6c2(_0x9f0913([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x1974c7=0x5e04a0ca^_0xace388;function _0x500f91(){const _0x126c0b=_0x9f0913([0x6c,0x6c,0x63,0x74,0x2d])+_0x561632(_0x418095(_0x38f559)),_0x2dab3d=_0x3709b1(_0x561632(window[_0x9f0913([0x4d,0x61,0x74,0x68])][_0x9f0913([0x63,0x65,0x69,0x6c])](_0x23e624/_0x1974c7)));window[_0x9f0913([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x9f0913([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x126c0b,_0x2dab3d);}function _0x1a0d21(){const _0xd8a51a=_0x9f0913([0x6c,0x6c,0x63,0x74,0x2d])+_0x561632(_0x418095(_0x38f559)),_0x3f3a82=window[_0x9f0913([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x9f0913([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0xd8a51a);return _0x3f3a82?window[_0x9f0913([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x3709b1(_0x3f3a82),0x10)*_0x1974c7:null;}function _0x396e36(_0x5d45ad){return new window[(_0x9f0913([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x2eb35f,_0x29c658)=>{_0x5d45ad[_0x9f0913([0x74,0x68,0x65,0x6e])](_0x2eb35f,_0x29c658),window[_0x9f0913([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x29c658,0x5e339a8a^_0xace388);});}}_0xa10223[_0x9f0913([0x6f,0x6e])](_0x9f0913([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0xf261a3,_0x43d7b0)=>{if(_0x43d7b0[0x0]!=_0x38f559)return _0x18e6c2(_0x9f0913([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x43d7b0[0x1]={..._0x43d7b0[0x1],[_0x9f0913([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x1aadbb};},{[_0x9f0913([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x9f0913([0x68,0x69,0x67,0x68])}),_0xa10223[_0x9f0913([0x6f,0x6e])](_0x9f0913([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x35fc6f=>{_0xa6ea3c(_0x35fc6f[_0x9f0913([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x337871=!0x0,_0x2a48b6(_0x35fc6f[_0x9f0913([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x9f0913([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x9f0913([0x6c,0x6f,0x77])}),_0x3ca702[_0x9f0913([0x74,0x68,0x65,0x6e])](()=>{_0x337871||_0x18e6c2(_0x9f0913([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x1dbd95(){return _0xa10223[_0x9f0913([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x9f0913([0x76,0x69,0x65,0x77])][_0x9f0913([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x9f0913([0x61,0x75,0x74,0x6f]);}function _0x515f89(){_0xa10223[_0x9f0913([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x9f0913([0x76,0x69,0x65,0x77])][_0x9f0913([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x9f0913([0x61,0x75,0x74,0x6f]);}}function _0x5ce5cb(_0x4e28a8){const _0x962d80=[new window[(_0x9f0913([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x50bfc5=>setTimeout(_0x50bfc5,0x5e3b7086^_0xace388)),_0x3ca702[_0x9f0913([0x74,0x68,0x65,0x6e])](()=>new window[(_0x9f0913([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x17e6e7=>{const _0x1e6bd0=0x5e324e4d^_0xace388,_0x487e29=_0x317649[_0x9f0913([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x27b73c(){_0x487e29[_0x9f0913([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x1e6bd0&&_0x17e6e7();}_0x27b73c(),_0x487e29[_0x9f0913([0x6f,0x6e])](_0x9f0913([0x61,0x64,0x64]),_0x27b73c);})),new window[(_0x9f0913([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x59b584=>{function _0x4c54e1(){for(const _0x4e8553 in window)if(window[_0x9f0913([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x9f0913([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x4e8553))&&window[_0x4e8553]==_0x320bd1)return _0x59b584();_0xa10223[_0x9f0913([0x73,0x74,0x61,0x74,0x65])]!=_0x9f0913([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x9f0913([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x4c54e1,0x5e325dc2^_0xace388);}_0x1ad169(_0x9f0913([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x4c54e1();})];return window[_0x9f0913([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x9f0913([0x72,0x61,0x63,0x65])](_0x962d80)[_0x9f0913([0x74,0x68,0x65,0x6e])](()=>_0x4e28a8);}async function _0x4ffb50(){if(await _0x3ca702,_0x1ad169(_0x9f0913([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x3941f9=_0x317649[_0x9f0913([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x471431=_0x317649[_0x9f0913([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])](_0x3941f9[_0x9f0913([0x69,0x64])]),_0x3f2987=_0x3b4df6(_0x9f0913([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x3f2987[_0x9f0913([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x3941f9['id'],_0x471431?_0x471431['id']:null,!0x0),_0x3f2987[_0x9f0913([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x9f0913([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x3f2987[_0x9f0913([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x3f2987[_0x9f0913([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x2b53ed,void(_0x3f2987[_0x9f0913([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x2b53ed);}if(_0x1ad169(_0x9f0913([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x3228e5=_0x3b4df6(_0x9f0913([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x3228e5[_0x9f0913([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x9f0913([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x3228e5[_0x9f0913([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x3228e5[_0x9f0913([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x2b53ed,_0x3228e5[_0x9f0913([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x2b53ed;}_0xa10223[_0x9f0913([0x6d,0x6f,0x64,0x65,0x6c])][_0x9f0913([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x2b53ed,_0xa10223[_0x9f0913([0x6d,0x6f,0x64,0x65,0x6c])][_0x9f0913([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x2b53ed,_0xa10223[_0x9f0913([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x9f0913([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x1f6795(){return _0x1ad169(_0x9f0913([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x3b4df6(_0x9f0913([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x9f0913([0x73,0x74,0x61,0x74,0x65])]==_0x9f0913([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0xa5e92b(){return _0x1ad169(_0x9f0913([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 _0x2e37c0(){return _0x1ad169(_0x9f0913([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x18a084(_0x5d3298){const _0x273533=_0x46a40b();_0xa10223[_0x273533]=_0x9f0913([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])+_0x5d3298,_0x5d3298[_0x9f0913([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x9f0913([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x46a40b()]=_0x320bd1),_0x5d3298!=_0x9f0913([0x56,0x61,0x6c,0x69,0x64])&&_0x4ffb50();}function _0x46a40b(){const _0x560f5b=window[_0x9f0913([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x9f0913([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x9f0913([0x6e,0x6f,0x77])]())[_0x9f0913([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x9f0913([0x2e]),'');let _0x2c5b4e=_0x9f0913([0x74]);for(let _0x2d022e=0x0;_0x2d022e<_0x560f5b[_0x9f0913([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x2d022e+=0x2){let _0x59e00a=window[_0x9f0913([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x560f5b[_0x9f0913([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x2d022e,_0x2d022e+0x2));_0x59e00a>=_0x57eeb0[_0x9f0913([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x59e00a-=_0x57eeb0[_0x9f0913([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x2c5b4e+=_0x57eeb0[_0x59e00a];}return _0x2c5b4e;}function _0x6f4103(){const _0x32565a=_0x369ecd[_0x9f0913([0x73,0x70,0x6c,0x69,0x74])](_0x9f0913([0x2e]));if(0x3!=_0x32565a[_0x9f0913([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x2fdbd4(_0x32565a[0x1]);function _0x2fdbd4(_0x1a3ea1){const _0x5a892d=_0x327b4a(_0x1a3ea1);return _0x5a892d&&_0x2fe15a()?_0x5a892d:null;function _0x2fe15a(){const _0x55acc8=_0x5a892d[_0x9f0913([0x6a,0x74,0x69])],_0x2b57dc=window[_0x9f0913([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x55acc8[_0x9f0913([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x55acc8[_0x9f0913([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x1b9a5f={..._0x5a892d,[_0x9f0913([0x6a,0x74,0x69])]:_0x55acc8[_0x9f0913([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x55acc8[_0x9f0913([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x1b9a5f[_0x9f0913([0x76,0x63])],_0x418095(_0x1b9a5f)==_0x2b57dc;}}}async function _0x1d1035(){let _0x50ef09=!0x0;try{const _0x53d3ad=_0x369ecd[_0x9f0913([0x73,0x70,0x6c,0x69,0x74])](_0x9f0913([0x2e])),[_0x1a93f9,_0x4b21f1,_0x103aa8]=_0x53d3ad;return _0x4c21ef(_0x1a93f9),await _0x5b1a33(_0x1a93f9,_0x4b21f1,_0x103aa8),_0x50ef09;}catch(_0x250dee){return!0x1;}function _0x4c21ef(_0x4dcef5){const _0x204d78=_0x327b4a(_0x4dcef5);_0x204d78&&_0x204d78[_0x9f0913([0x61,0x6c,0x67])]==_0x9f0913([0x45,0x53,0x32,0x35,0x36])||(_0x50ef09=!0x1);}async function _0x5b1a33(_0x5a20d2,_0x5c3a66,_0x318441){const _0x3a399d=window[_0x9f0913([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x9f0913([0x66,0x72,0x6f,0x6d])](_0x3595bb(_0x318441),_0x1af48f=>_0x1af48f[_0x9f0913([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x17530b=new window[(_0x9f0913([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x9f0913([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x5a20d2+_0x9f0913([0x2e])+_0x5c3a66),_0x377bac=window[_0x9f0913([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x9f0913([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x377bac)return;const _0x584f6b=await _0x377bac[_0x9f0913([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x9f0913([0x6a,0x77,0x6b]),_0x484a0a,{[_0x9f0913([0x6e,0x61,0x6d,0x65])]:_0x9f0913([0x45,0x43,0x44,0x53,0x41]),[_0x9f0913([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x9f0913([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x9f0913([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x377bac[_0x9f0913([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x9f0913([0x6e,0x61,0x6d,0x65])]:_0x9f0913([0x45,0x43,0x44,0x53,0x41]),[_0x9f0913([0x68,0x61,0x73,0x68])]:{[_0x9f0913([0x6e,0x61,0x6d,0x65])]:_0x9f0913([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x584f6b,_0x3a399d,_0x17530b)||(_0x50ef09=!0x1);}}function _0x327b4a(_0x266a84){return _0x266a84[_0x9f0913([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x9f0913([0x65,0x79]))?JSON[_0x9f0913([0x70,0x61,0x72,0x73,0x65])](_0x3595bb(_0x266a84)):null;}function _0x3595bb(_0x5dc445){return window[_0x9f0913([0x61,0x74,0x6f,0x62])](_0x5dc445[_0x9f0913([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x9f0913([0x2b]))[_0x9f0913([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x9f0913([0x2f])));}function _0x418095(_0x40baaa){let _0x41acda=0x1505;function _0x565741(_0x1d94c8){for(let _0x2cb2a1=0x0;_0x2cb2a1<_0x1d94c8[_0x9f0913([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x2cb2a1++){const _0x586c73=_0x1d94c8[_0x9f0913([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x2cb2a1);_0x41acda=(_0x41acda<<0x5)+_0x41acda+_0x586c73,_0x41acda&=_0x41acda;}}function _0x4fad7e(_0x238349){Array[_0x9f0913([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x238349)?_0x238349[_0x9f0913([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x4fad7e):_0x238349&&typeof _0x238349==_0x9f0913([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x9f0913([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x238349)[_0x9f0913([0x73,0x6f,0x72,0x74])]()[_0x9f0913([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0xbe21cc,_0x2e3dd4])=>{_0x565741(_0xbe21cc),_0x4fad7e(_0x2e3dd4);}):_0x565741(window[_0x9f0913([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x238349));}return _0x4fad7e(_0x40baaa),_0x41acda>>>0x0;}function _0x561632(_0x41b0ff){return _0x41b0ff[_0x9f0913([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x9f0913([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x9f0913([0x30]));}function _0x3709b1(_0x29c854){return _0x29c854[_0x9f0913([0x73,0x70,0x6c,0x69,0x74])]('')[_0x9f0913([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x9f0913([0x6a,0x6f,0x69,0x6e])]('');}function _0x1ad169(_0x13804e){return _0xa10223[_0x9f0913([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x9f0913([0x68,0x61,0x73])](_0x13804e);}function _0x3b4df6(_0x2ab91a){return _0xa10223[_0x9f0913([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x9f0913([0x67,0x65,0x74])](_0x2ab91a);}function _0x2b53ed(){}function _0x9f0913(_0x34c50d){return _0x34c50d['map'](_0xa308d7=>String['fromCharCode'](_0xa308d7))['join']('');}_0x18a084(await _0x507b85());}(this);}['createRevision'](_0xa363a8){const _0x554b55=this['editor']['plugins']['get']('Users');return new a({'id':_0xa363a8['id'],'name':_0xa363a8['name'],'creator':_0xa363a8['creatorId']?_0x554b55['getUser'](_0xa363a8['creatorId']):null,'diffData':_0xa363a8['diffData']||_0xa363a8['data'],'authors':_0xa363a8['authorsIds']['map'](_0x4f92b9=>_0x554b55['getUser'](_0x4f92b9)),'createdAt':new Date(_0xa363a8['createdAt']),'attributes':_0xa363a8['attributes'],'fromVersion':_0xa363a8['fromVersion'],'toVersion':_0xa363a8['toVersion']});}['addRevision'](_0x4e0200,_0x10b12f=0x0){this['_revisions']['add'](_0x4e0200,_0x10b12f);}['getRevision'](_0x27b52d){return this['_revisions']['get'](_0x27b52d);}['getRevisions'](_0x415d72={'toJSON':!0x1}){const _0x8ce33b=Array['from'](this['_revisions']);return _0x8ce33b['reverse'](),_0x415d72['toJSON']?_0x8ce33b['map'](_0x44dae8=>_0x44dae8['toJSON']()):_0x8ce33b;}['getIndex'](_0x2973f3){return this['_revisions']['getIndex'](_0x2973f3);}['getEarlierVisibleRevision'](_0x2dcdb3){const [,_0x39cae8]=this['getRevisionsIterator'](_0x2dcdb3,{'direction':'earlier'});return _0x39cae8;}['getLaterVisibleRevision'](_0x24be5d){const [,_0x33b324]=this['getRevisionsIterator'](_0x24be5d,{'direction':'later'});return _0x33b324;}['getRevisionsInDiff'](_0xc40973){const _0x11b109=[];for(const _0x1416b1 of this['getRevisionsIterator'](_0xc40973['newRevisionId']))if(_0x11b109['push'](_0x1416b1),_0x1416b1['id']===_0xc40973['oldRevisionId'])break;return _0x11b109;}*['getRevisionsIterator'](_0x45ae51,{direction:_0x374f85='earlier',filter:_0x336ad9=()=>!0x0}={}){const _0x21f2fd='earlier'===_0x374f85?0x1:-0x1;let _0x11531d=this['_revisions']['get'](_0x45ae51),_0x5d8f04=this['getIndex'](_0x11531d);for(yield _0x11531d;_0x11531d;){if(_0x5d8f04+=_0x21f2fd,_0x11531d=this['getRevision'](_0x5d8f04),!_0x11531d)return;_0x336ad9(_0x11531d)&&(yield _0x11531d);}}}function R(_0x35cbcf,_0x5b86e8,_0xe9723){const t=_0x35cbcf['t'];switch(_0x5b86e8){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'},_0xe9723);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0xe9723);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'';}}const C={'c':_0x26af22,'a':_0x505635,'e':_0x3ff6a6,'r':_0x4abad2,'u':_0x29510a};class l extends _0x2ebc56{['licenseKey'];['_licenseKeyCheckInterval'];['adapter'];['currentRevision'];['repository'];['_revisionDataBuilder'];['_source'];['_initialRevisionId'];['_bufferedUpdates'];['_pendingAction'];['_continueCurrentRevision'];['_startingVersion'];['_loadedStateData'];static get['pluginName'](){return'RevisionTracker';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[_0x305d7f,j,_0x364901];}constructor(_0x1494a){super(_0x1494a),this['adapter']=null,this['currentRevision']=null,this['_revisionDataBuilder']=new T(this['editor']),this['_initialRevisionId']=this['editor']['config']['get']('collaboration.channelId')||'initial',this['_bufferedUpdates']=new Map(),this['_loadedStateData']=null;const _0x1bec91=_0xb3cc0b();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x1bec91},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['repository']=this['editor']['plugins']['get']('RevisionsRepository'),this['_setConversion'](),this['editor']['data']['on']('ready',()=>{const _0x1fa98a=this['repository']['getRevision'](0x0),_0x479a24=_0x1fa98a&&null===_0x1fa98a['creator']?_0x1fa98a:null;if(this['_continueCurrentRevision']=!!_0x479a24&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x375231=this['_source']['getCurrentRevisionId'](),_0xb33bb0=this['repository']['getRevision'](_0x375231);if(_0xb33bb0)this['_startingVersion']=_0xb33bb0['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x3e5818=this['_source']['history']['_operations']['find'](_0x5c7728=>!_0x5c7728['_isInit']),_0x59a1df=_0x3e5818?_0x3e5818['baseVersion']:this['_source']['history']['version'];_0x1fa98a?(_0x1fa98a['toVersion']<_0x59a1df&&_0x1fa98a['_update']({'toVersion':_0x59a1df}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x479a24['id'],this['_startingVersion']=_0x479a24['fromVersion']):(this['_startingVersion']=_0x1fa98a['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x59a1df,this['_continueCurrentRevision']=!0x1);}}else _0x479a24&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x479a24['toVersion'],this['editor']['model']['document']['history']['version']),_0x479a24['fromVersion']===_0x479a24['toVersion']?(0x0!==_0x479a24['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x479a24['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x479a24['id'],this['_startingVersion']=_0x479a24['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',_0x1af9cb=>!_0x1af9cb),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x429644=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x450343;for(const _0x31e208 in _0x429644){const _0x2e5019=_0x31e208,_0x10320a=_0x429644[_0x2e5019];if('revisionHistoryLicenseKeyValid'==_0x10320a||'revisionHistoryLicenseKeyInvalid'==_0x10320a||'revisionHistoryLicenseKeyExpired'==_0x10320a||'revisionHistoryLicenseKeyDomainLimit'==_0x10320a||'revisionHistoryLicenseKeyNotAllowed'==_0x10320a||'revisionHistoryLicenseKeyEvaluationLimit'==_0x10320a||'revisionHistoryLicenseKeyTrialLimit'==_0x10320a||'revisionHistoryLicenseKeyDevelopmentLimit'==_0x10320a||'revisionHistoryLicenseKeyUsageLimit'==_0x10320a){delete _0x429644[_0x2e5019],_0x450343=_0x10320a,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x450343&&_0x429644['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x450343&&_0x429644['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x450343&&_0x429644['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x450343&&_0x429644['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x450343&&_0x429644['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x450343&&_0x429644['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyDevelopmentLimit'==_0x450343&&_0x429644['_showLicenseError']('developmentLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x450343&&_0x429644['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x4fe9fc=this['repository']['getRevision'](0x0),_0x4099f5=await this['getRevisionDocumentData'](_0x4fe9fc),_0x5c3680=await this['getRevisionRootsAttributes'](_0x4fe9fc);this['_replaceEditorDataWithRevisionData'](_0x4099f5,_0x5c3680);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x4d646c){this['_source']=_0x4d646c;}async['update'](){const _0x41ab2f=await this['_source']['getLatestVersion']();if(_0x41ab2f>this['currentRevision']['toVersion']){await this['_loadState']();const _0x565552=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x41ab2f});_0x565552['authors']=_0x565552['authorsIds']['map'](_0xe744d0=>this['editor']['plugins']['get']('Users')['getUser'](_0xe744d0)),this['currentRevision']['_update'](_0x565552);}}async['_loadState'](){this['_continueCurrentRevision']&&!this['_loadedStateData']&&(await this['_loadRevisionData'](this['currentRevision']),this['_revisionDataBuilder']['loadState'](this['currentRevision']),this['_loadedStateData']={'fromVersion':this['currentRevision']['fromVersion'],'authors':this['currentRevision']['authors']['slice']()});}async['saveRevision'](_0x38afc5={},_0x569ef6=null){const _0x5ed53f=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x569ef6>this['currentRevision']['toVersion']&&(_0x569ef6=null),null===_0x569ef6&&(_0x569ef6=await this['_source']['getLatestVersion']());const _0x1cc85e=this['_getFromVersion'](_0x569ef6),_0x2ddeed=this['buildRevisionData']({'from':_0x1cc85e,'to':_0x569ef6});if(this['currentRevision']['toVersion']<_0x569ef6){const _0x514502=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x569ef6,'to':_0x569ef6});_0x514502['authors']=[],_0x514502['authorsIds']=[],_0x514502['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x514502,!0x0),delete _0x514502['authors'],_0x5ed53f['push'](_0x514502);}_0x38afc5['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x38afc5['name']=_0x38afc5['name']||null,_0x38afc5['id']=_0x38afc5['id']||_0xb3cc0b(),_0x38afc5={..._0x38afc5,..._0x2ddeed};const _0x5a894a=this['addRevisionData'](_0x38afc5);_0x5ed53f['push'](_0x38afc5);const _0x329398=this['repository']['getIndex'](_0x5a894a);if(0x0!==_0x329398){const _0x5dec2a=this['repository']['getRevision'](_0x329398-0x1);if(_0x5dec2a['fromVersion']!==_0x569ef6){const _0x381ac4=this['_revisionDataBuilder']['getData'](_0x569ef6,_0x5dec2a['toVersion']),_0x18d954={'id':_0x5dec2a['id'],'diffData':_0x381ac4['diffData'],'authorsIds':_0x381ac4['authorsIds'],'authors':_0x381ac4['authorsIds']['map'](_0x399547=>this['editor']['plugins']['get']('Users')['getUser'](_0x399547)),'fromVersion':_0x569ef6};_0x5dec2a===this['currentRevision']&&(_0x18d954['createdAt']=new Date(_0x38afc5['createdAt']['getTime']()+0xa)),_0x5dec2a['_update'](_0x18d954,!0x0),delete _0x18d954['authors'],_0x5ed53f['push'](_0x18d954);}}if(this['adapter']){for(const _0x43ad4f of _0x5ed53f)this['_bufferUpdate'](_0x43ad4f['id'],_0x43ad4f,!0x0);this['sendBufferedUpdates']();}return _0x5a894a;}['addRevisionData'](_0x1717d7){const _0x1d9536=this['repository']['createRevision'](_0x1717d7);return this['adapter']&&_0x1d9536['on']('_update',(_0x197203,_0x4d821c,_0x58d449)=>{_0x58d449||(this['_bufferUpdate'](_0x4d821c['id'],_0x4d821c,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x1d9536,this['_findInsertionIndex'](_0x1d9536)),_0x1d9536;}async['getRevisionDocumentData'](_0x570bb0){await this['_loadRevisionData'](_0x570bb0);const _0x9b5fe0={};for(const _0x36fa45 in _0x570bb0['diffData']){if(_0x570bb0['diffData'][_0x36fa45]['attachChange']&&!_0x570bb0['diffData'][_0x36fa45]['attachChange']['isAttached'])continue;const _0x39c8ba=this['_removeRevisionMarkers'](JSON['parse'](_0x570bb0['diffData'][_0x36fa45]['insertions'])),_0x2694b6=this['editor']['editing']['view']['document'],_0x134032=new _0x471757(_0x2694b6,_0x39c8ba['map'](_0x3f27df=>V(_0x3f27df,this['editor'])));this['editor']['data']['processor']['useFillerType']('marked'),_0x9b5fe0[_0x36fa45]=this['editor']['data']['processor']['toData'](_0x134032),this['editor']['data']['processor']['useFillerType']('default');}return _0x9b5fe0;}async['getRevisionRootsAttributes'](_0x2b4e31){await this['_loadRevisionData'](_0x2b4e31);const _0x58948d={};for(const _0x318ba3 in _0x2b4e31['diffData'])_0x2b4e31['diffData'][_0x318ba3]['attachChange']&&!_0x2b4e31['diffData'][_0x318ba3]['attachChange']['isAttached']||(_0x58948d[_0x318ba3]=_0x2b4e31['diffData'][_0x318ba3]['attributesAfter']||{});return _0x58948d;}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x79dd0d=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x3a2c12=0x0;_0x3a2c12<_0x79dd0d['length'];_0x3a2c12++){const _0x590f62=_0x79dd0d[_0x3a2c12];let _0x51c701=!0x1;for(const _0x53b7c5 of Object['keys'](_0x590f62))void 0x0===_0x590f62[_0x53b7c5]?delete _0x590f62[_0x53b7c5]:'id'!==_0x53b7c5&&(_0x51c701=!0x0);_0x51c701||(_0x79dd0d[_0x3a2c12]=null);}if(_0x79dd0d=_0x79dd0d['filter'](_0x4f968a=>null!==_0x4f968a),!_0x79dd0d['length'])return;for(let _0x40f873=0x0;_0x40f873<_0x79dd0d['length'];_0x40f873++){const _0x5e05f9=_0x79dd0d[_0x40f873];void 0x0!==_0x5e05f9['fromVersion']&&void 0x0===_0x5e05f9['toVersion']&&(_0x5e05f9['toVersion']=this['repository']['getRevision'](_0x5e05f9['id'])['toVersion']),void 0x0!==_0x5e05f9['toVersion']&&void 0x0===_0x5e05f9['fromVersion']&&(_0x5e05f9['fromVersion']=this['repository']['getRevision'](_0x5e05f9['id'])['fromVersion']);}const _0x267991=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x79dd0d,_0x267991)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x4499ac=>{if(_0x4499ac){for(const _0x12c20b of _0x4499ac)this['setRevisionData']({'id':_0x12c20b['id'],'createdAt':_0x12c20b['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['_replaceEditorDataWithRevisionData'](_0x20f2f6,_0x540667){let _0x9cf4a8=this['editor']['config']['get']('initialData'),_0x1f5b03=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x9cf4a8){_0x9cf4a8={};for(const _0x37c794 of this['editor']['model']['document']['getRootNames']())_0x9cf4a8[_0x37c794]='';}if('string'==typeof _0x9cf4a8&&(_0x9cf4a8={'main':_0x9cf4a8}),void 0x0===_0x1f5b03){_0x1f5b03={};for(const _0x41cebf of this['editor']['model']['document']['getRootNames']())_0x1f5b03[_0x41cebf]={};}let _0x271bf8=!0x1;const _0x5c0442=Object['keys'](_0x9cf4a8),_0x76d3aa=Object['keys'](_0x20f2f6);for(const _0x140f5a of _0x5c0442){if(_0x9cf4a8[_0x140f5a]!==_0x20f2f6[_0x140f5a]&&''!==_0x9cf4a8[_0x140f5a]['trim']()){_0x271bf8=!0x0;break;}if(!_0x59f093(_0x1f5b03[_0x140f5a],_0x540667[_0x140f5a])&&Object['keys'](_0x1f5b03[_0x140f5a])['length']>0x0){_0x271bf8=!0x0;break;}}_0x271bf8||(_0x271bf8=_0x76d3aa['some'](_0x1e184c=>!this['editor']['model']['document']['getRoot'](_0x1e184c))),_0x271bf8&&_0x52977e('editor-initial-data-replaced-with-revision-data',{'editorData':_0x9cf4a8,'editorRootsAttributes':_0x1f5b03,'revisionData':_0x20f2f6,'revisionRootsAttributes':_0x540667}),this['editor']['config']['set']('initialData',_0x20f2f6),this['editor']['config']['set']('rootsAttributes',_0x540667);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x176d44=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x176d44['add'](R(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x34b998){const _0x4ba7db=this['repository']['getRevisions']();_0x4ba7db['reverse']();let _0x58bffb=0x0;for(;_0x58bffb<_0x4ba7db['length'];){const _0x27d93b=_0x4ba7db[_0x58bffb];if(_0x27d93b===this['currentRevision']){_0x58bffb++;continue;}if(_0x27d93b['id']===this['_initialRevisionId'])break;const _0x2155f2=_0x34b998['toVersion']-_0x27d93b['toVersion']||_0x34b998['fromVersion']-_0x27d93b['fromVersion'];if(_0x2155f2>0x0)break;if(_0x2155f2<0x0)_0x58bffb++;else{if(!_0x34b998['creator']&&_0x27d93b['creator'])break;if(_0x27d93b['creator']||!_0x34b998['creator']){if(_0x34b998['createdAt']>_0x27d93b['createdAt'])break;_0x58bffb++;}else _0x58bffb++;}}return _0x58bffb;}['setRevisionData'](_0x33a670){const _0x1a94c7=this['repository']['getRevision'](_0x33a670['id']);if(_0x33a670['createdAt']&&(_0x33a670['createdAt']=new Date(_0x33a670['createdAt'])),_0x33a670['authorsIds']){const _0x28eb4=this['editor']['plugins']['get']('Users');_0x33a670['authors']=_0x33a670['authorsIds']['map'](_0x5eaad7=>_0x28eb4['getUser'](_0x5eaad7));}_0x1a94c7['_update'](_0x33a670,!0x0);}['buildRevisionData']({revision:_0x50ec7d=null,from:_0x2843a2=null,to:_0x489915=null}){_0x2843a2=null!==_0x2843a2?_0x2843a2:_0x50ec7d['fromVersion'],_0x489915=null!==_0x489915?_0x489915:_0x50ec7d['toVersion'];const _0x585832=this['_revisionDataBuilder']['getData'](_0x2843a2,_0x489915),_0x2903c2={'diffData':_0x585832['diffData'],'authorsIds':_0x585832['authorsIds'],'fromVersion':_0x2843a2,'toVersion':_0x489915};if(!_0x50ec7d||_0x489915!==_0x50ec7d['toVersion']){const _0x456464=_0x489915-0x1,_0x429f12=this['_source']['history']['getOperation'](_0x456464);_0x2903c2['createdAt']=_0x429f12&&_0x429f12['createdAt']||new Date();}if(this['_loadedStateData']&&_0x2843a2===this['_loadedStateData']['fromVersion']){for(const _0xd420cc of this['_loadedStateData']['authors'])_0x2903c2['authorsIds']['includes'](_0xd420cc['id'])||_0x2903c2['authorsIds']['push'](_0xd420cc['id']);}return _0x2903c2;}['_loadRevisionData'](_0x2d194e){if(!_0x2d194e||_0x2d194e['diffData'])return Promise['resolve']();{const _0x552f01=this['editor']['config']['get']('collaboration.channelId');return this['adapter']['getRevision']({'channelId':_0x552f01,'revisionId':_0x2d194e['id']})['then'](_0x3dfc39=>{_0x2d194e['diffData']=_0x3dfc39['diffData'];});}}['_bufferUpdate'](_0x4afc00,_0x5a00c2,_0x2deb6a){if(this['_bufferedUpdates']['has'](_0x4afc00)){const _0x5826e8=this['_bufferedUpdates']['get'](_0x4afc00);_0x5a00c2=_0x2deb6a?{..._0x5826e8,..._0x5a00c2}:{..._0x5a00c2,..._0x5826e8};}this['_bufferedUpdates']['set'](_0x4afc00,_0x5a00c2);}['_getFromVersion'](_0x26724b){const _0x178d37=this['repository']['getRevisions']();_0x178d37['reverse'](),_0x178d37['shift']();const _0xee697a=_0x178d37['find'](_0x21f6de=>_0x21f6de['toVersion']<=_0x26724b)['toVersion'];return _0xee697a<this['_startingVersion']?this['_startingVersion']:_0xee697a;}['_createInitialRevision'](_0x355231){const _0x454984=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x454984)this['_initialRevisionId']=_0x454984['id'];else{const _0x4e2dd1=!this['editor']['model']['document']['roots']['find'](_0x4c6dcd=>this['editor']['model']['hasContent'](_0x4c6dcd)),_0x135bb4=this['editor']['plugins']['get']('Users')['me']['id'],_0x3d70cf=R(this['editor']['locale'],_0x4e2dd1?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x355231,'to':_0x355231,'id':this['_initialRevisionId'],'name':_0x3d70cf,'creatorId':_0x135bb4});}}['_createCurrentRevision'](_0x3f4f6f){const _0x455fe2=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x455fe2),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x3f4f6f,'to':_0x3f4f6f,'id':_0x455fe2,'name':'','creatorId':null}));}['_makeRevision']({name:_0x5cfddc,from:_0x47bcab,to:_0x302733,creatorId:_0x45dbe9,id:_0x5f1051}){const _0x3e18fb=this['buildRevisionData']({'from':_0x47bcab,'to':_0x302733});_0x3e18fb['name']=_0x5cfddc,_0x3e18fb['creatorId']=_0x45dbe9,_0x3e18fb['id']=_0x5f1051;const _0x4e226b=this['addRevisionData'](_0x3e18fb);return this['adapter']&&this['_bufferUpdate'](_0x3e18fb['id'],_0x3e18fb,!0x0),_0x4e226b;}['_setConversion'](){this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'});}['_removeRevisionMarkers'](_0x3c48a8){return(_0x3c48a8=_0x3c48a8['filter'](_0x3086e2=>!_0x3086e2['name']||'revision-start'!==_0x3086e2['name']&&'revision-end'!==_0x3086e2['name']))['forEach'](_0x5d44c2=>{'string'!=typeof _0x5d44c2&&(_0x5d44c2['children']=this['_removeRevisionMarkers'](_0x5d44c2['children']),_0x5d44c2['attributes']=_0x5d44c2['attributes']['filter'](_0x2577b5=>!_0x2577b5[0x0]['startsWith']('data-revision-')));}),_0x3c48a8;}}function V(_0x41cae5,_0x5e8fa5){const _0x49cb84=_0x5e8fa5['editing']['view']['document'];if('string'==typeof _0x41cae5)return new _0x7c92df(_0x49cb84,_0x41cae5);{const _0x3d06fe=_0x41cae5['children']['map'](_0xec1911=>V(_0xec1911,_0x5e8fa5));return new(C[_0x41cae5['type']]||_0x3b6ead)(_0x49cb84,_0x41cae5['name'],_0x41cae5['attributes'],_0x3d06fe);}}class T{['editor'];['source'];['_savedMetaData'];['_lastFrom'];['_lastTo'];['_markers'];['_diffRoots'];['_diffRootsAttributes'];['_baseRoots'];['_baseRootsAttributes'];['_idsRoots'];['_baseIdsRoots'];['_touched'];['_touchedMarkers'];['_touchedRoots'];['_revisionId'];['_startingRevisionId'];constructor(_0x599f0b){this['editor']=_0x599f0b,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'](_0x227050){this['source']=_0x227050;const _0x154cad=new Map(),_0x4eab91=new Map(),_0x1eb027=this['editor']['model']['document']['roots']['map'](_0xe1d529=>_0xe1d529['rootName']);for(const _0x183861 of _0x1eb027){const _0x431df7=this['editor']['model']['document']['getRoot'](_0x183861),_0x3f46a2=F(_0x431df7);_0x154cad['set'](_0x183861,_0x3f46a2),_0x4eab91['set'](_0x183861,Object['fromEntries'](_0x431df7['getAttributes']()));}const _0x36c535=Array['from'](this['editor']['model']['markers'])['map'](_0x3d9ba9=>[_0x3d9ba9['name'],_0x3d9ba9['getRange']()]),_0x4ff4c8=this['source']['version'];this['_saveMetaData'](_0x4ff4c8,_0x154cad,_0x36c535,_0x4eab91),this['_startingRevisionId']=this['_revisionId'];const _0x166777=new Map(),_0x36a835=new Map();for(const _0x124d59 of _0x1eb027){const _0x59d19a=B(_0x124d59);_0x166777['set'](_0x124d59,_0x59d19a),_0x36a835['set'](_0x124d59,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x166777,[],_0x36a835);}['getData'](_0x497e73,_0x27d756){if(this['_lastFrom']===_0x497e73&&this['_lastTo']<=_0x27d756)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x27d756,!0x0);else{if(!this['_savedMetaData']['has'](_0x497e73)){const _0x39f319=this['_getPreviousFrom'](_0x497e73);this['_calculateMetaData'](_0x39f319,_0x497e73,!0x1);}this['_calculateMetaData'](_0x497e73,_0x27d756,!0x0);}return this['_lastFrom']=_0x497e73,this['_lastTo']=_0x27d756,this['_getState']();}['loadState'](_0x3b81d4){this['_reset'](),this['_lastFrom']=_0x3b81d4['fromVersion'],this['_lastTo']=_0x3b81d4['toVersion'];for(const _0x347bfa in _0x3b81d4['diffData']){const _0x31166f=_0x3b81d4['diffData'][_0x347bfa]['attachChange'],_0x561004=_0x3c49e8(_0x3b81d4['diffData'][_0x347bfa]['attributesBefore'])||{},_0x2b0d0b=this['_makeModelFromViewString'](_0x3b81d4['diffData'][_0x347bfa]['deletions']);_0x2b0d0b['rootName']=_0x347bfa,_0x2b0d0b['_isAttached']=!_0x31166f||!_0x31166f['isAttached'],_0x2b0d0b['isAttached']=()=>_0x2b0d0b['_isAttached'],this['_baseRoots']['set'](_0x347bfa,_0x2b0d0b),this['_baseRootsAttributes']['set'](_0x347bfa,_0x561004),_0x31166f&&this['_touchedRoots']['set'](_0x347bfa,_0x31166f);const _0x51e1cf=this['_makeIdsRoot'](_0x2b0d0b);this['_baseIdsRoots']['set'](_0x347bfa,_0x51e1cf);for(const [_0xcaf39d,_0xc2f429]of _0x2b0d0b['markers']){if(!_0xcaf39d['startsWith']('revision:'))continue;const _0x3ff76c=_0xcaf39d['split'](':')[0x2];for(const _0x5deb74 of _0xc2f429['getWalker']({'singleCharacters':!0x0})){const _0x25077e=this['_getVidAttributeName'](_0x5deb74),_0x16f189='elementEnd'==_0x5deb74['type']?_0x5deb74['previousPosition']['path']['slice'](0x0,-0x1):_0x5deb74['previousPosition']['path'],_0x25c5df=_0x51e1cf['getNodeByPath'](_0x16f189)['getAttribute'](_0x25077e);this['_touched']['set'](_0x25c5df,{'userId':_0x3ff76c});}}}this['_startingRevisionId']=this['_revisionId'];const _0x118515=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x569baf=>!this['_touched']['has'](_0x569baf));let _0x1b3c51=0x0;const _0x5aba10=new Map();for(const _0x35ebf6 in _0x3b81d4['diffData']){const _0x3f3dde=_0x3b81d4['diffData'][_0x35ebf6]['attachChange'],_0x55cae1=_0x3c49e8(_0x3b81d4['diffData'][_0x35ebf6]['attributesAfter'])||{},_0x5b250a=this['_makeModelFromViewString'](_0x3b81d4['diffData'][_0x35ebf6]['insertions']);_0x5b250a['rootName']=_0x35ebf6,_0x5b250a['_isAttached']=!_0x3f3dde||_0x3f3dde['isAttached'],_0x5b250a['isAttached']=()=>_0x5b250a['_isAttached'],this['_diffRoots']['set'](_0x35ebf6,_0x5b250a),this['_diffRootsAttributes']['set'](_0x35ebf6,_0x55cae1);const _0x46709e=this['_makeIdsRoot'](_0x5b250a,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x35ebf6,_0x46709e),_0x5aba10['set'](_0x35ebf6,_0x5b250a['isAttached']()?_0x55cae1:{});for(const [_0x2effaf,_0x4ba8dd]of _0x5b250a['markers']){if(!_0x2effaf['startsWith']('revision:'))continue;const _0x9abce4=_0x2effaf['split'](':')[0x2];for(const _0x57489b of _0x4ba8dd['getWalker']({'singleCharacters':!0x0})){const _0x565c59=this['_getVidAttributeName'](_0x57489b),_0x3d325e=this['_revisionId']++,_0x563381='elementEnd'==_0x57489b['type']?_0x57489b['previousPosition']['path']['slice'](0x0,-0x1):_0x57489b['previousPosition']['path'];_0x46709e['getNodeByPath'](_0x563381)['_setAttribute'](_0x565c59,_0x3d325e),this['_touched']['set'](_0x3d325e,{'userId':_0x9abce4});}}for(const _0x20aa41 of this['editor']['model']['createRangeIn'](_0x5b250a)['getWalker']({'singleCharacters':!0x0})){const _0x3ad0f0=this['_getVidAttributeName'](_0x20aa41),_0x37c24a='elementEnd'==_0x20aa41['type']?_0x20aa41['previousPosition']['path']['slice'](0x0,-0x1):_0x20aa41['previousPosition']['path'],_0x48be19=_0x46709e['getNodeByPath'](_0x37c24a);_0x48be19['getAttribute'](_0x3ad0f0)>0x0||_0x48be19['_setAttribute'](_0x3ad0f0,_0x118515[_0x1b3c51++]);}for(const [_0x578f94,_0x58021d]of _0x5b250a['markers'])_0x578f94['startsWith']('revision:')||this['_markers']['set'](_0x578f94,_0x58021d);}const _0x27acd1=B('$graveyard');this['_baseRoots']['set']('$graveyard',_0x27acd1),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x27acd1,0x1));const _0x2b7061=B('$graveyard');this['_diffRoots']['set']('$graveyard',_0x2b7061),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x2b7061,0x1));const _0x5da614=Array['from'](this['_diffRoots'])['map'](([_0x4475b2,_0x277ec6])=>[_0x4475b2,F(_0x277ec6)]);this['_saveMetaData'](this['_lastTo'],_0x5da614,this['_markers'],_0x5aba10);}['_makeModelFromViewString'](_0x40f850){const _0xf0fa3=JSON['parse'](_0x40f850),_0x52dbbe=this['editor']['editing']['view']['document'],_0x3e6775=new _0x471757(_0x52dbbe,_0xf0fa3['map'](_0x53631f=>V(_0x53631f,this['editor'])));return this['editor']['data']['toModel'](_0x3e6775);}['_saveMetaData'](_0x1c2fa5,_0x1b29ef,_0x538663,_0x598c4d){const _0x2daa46=new Map(_0x1b29ef),_0x3f8614=new Map(_0x3c49e8(_0x598c4d)),_0x47695c=new Map();for(const [_0x4be1df,_0x53fd7e]of _0x538663)_0x47695c['set'](_0x4be1df,{'start':_0x53fd7e['start']['clone'](),'end':_0x53fd7e['end']['clone'](),'rootName':_0x53fd7e['root']['rootName']});this['_savedMetaData']['set'](_0x1c2fa5,{'roots':_0x2daa46,'markers':_0x47695c,'rootsAttributes':_0x3f8614});}['_removeMetaData'](_0x33e846){this['_savedMetaData']['delete'](_0x33e846);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_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'](_0x55be01,_0x30a252=null){let _0x4bea53=null;_0x55be01['is']('documentFragment')||(_0x4bea53=new ft(_0x55be01['name'],{'vid_start':null===_0x30a252?this['_revisionId']++:_0x30a252++}));const _0x31922e=[];for(const _0x37f350 of _0x55be01['getChildren']())if(_0x37f350['is']('element')){_0x31922e['push'](this['_makeIdsRoot'](_0x37f350,_0x30a252));const _0x1f8dba=_0x31922e[_0x31922e['length']-0x1];null!==_0x30a252&&(_0x30a252=_0x1f8dba['is']('element','$text')?_0x1f8dba['getAttribute']('vid')+0x1:_0x1f8dba['getAttribute']('vid_end')+0x1);}else{for(let _0xe5c635=0x0;_0xe5c635<_0x37f350['offsetSize'];_0xe5c635++)_0x31922e['push'](new ft('$text',{'vid':null===_0x30a252?this['_revisionId']++:_0x30a252++}));}if(_0x55be01['is']('documentFragment')){const _0x20bcef=B(_0x55be01['rootName']);return _0x20bcef['_insertChild'](0x0,_0x31922e),_0x20bcef;}return _0x4bea53['_setAttribute']('vid_end',null===_0x30a252?this['_revisionId']++:_0x30a252++),_0x4bea53['_insertChild'](0x0,_0x31922e),_0x4bea53;}['_calculateMetaData'](_0x224d41,_0x10fc0f,_0x17c957){this['_reset']();const {roots:_0x4c801e,markers:_0x1b8999,rootsAttributes:_0x1a4e54}=this['_savedMetaData']['get'](_0x224d41);this['_baseRoots']=new Map(_0x4c801e),this['_baseRootsAttributes']=new Map(_0x3c49e8(_0x1a4e54));for(const [_0x1f0522,_0x17c207]of this['_baseRoots'])if('$graveyard'!==_0x1f0522&&(this['_diffRoots']['set'](_0x1f0522,F(_0x17c207)),this['_diffRootsAttributes']=new Map(_0x3c49e8(_0x1a4e54)),_0x17c957)){const _0x7194bf=this['_revisionId'];this['_idsRoots']['set'](_0x1f0522,this['_makeIdsRoot'](_0x17c207)),this['_baseIdsRoots']['set'](_0x1f0522,this['_makeIdsRoot'](_0x17c207,_0x7194bf));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',F(this['_baseRoots']['get']('$graveyard'))),_0x17c957&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x5ecec0,_0x5e3b90]of _0x1b8999){const _0x3ce60a=this['_baseRoots']['get'](_0x5e3b90['rootName']),_0x2f64cc=this['_diffRoots']['get'](_0x5e3b90['rootName']),_0x57039c=new vt(this['_fixPosition'](_0x5e3b90['start'],_0x3ce60a),this['_fixPosition'](_0x5e3b90['end'],_0x3ce60a)),_0x7100d6=this['_fixRange'](_0x57039c,_0x2f64cc);_0x3ce60a['markers']['set'](_0x5ecec0,_0x57039c),this['_markers']['set'](_0x5ecec0,_0x7100d6);}this['_applyOperations'](_0x224d41,_0x10fc0f,_0x17c957);}['_applyOperations'](_0x1d34c9,_0x20b023,_0x51b361){for(const _0x3116bb of this['source']['getOperations'](_0x1d34c9,_0x20b023))this['_handleOperation'](_0x3116bb,_0x51b361);for(const _0xb7b74f of this['_diffRoots']['values']())_0xb7b74f['markers']['clear']();for(const [_0x4b0158,_0x4a81f0]of this['_markers']){this['_diffRoots']['get'](_0x4a81f0['root']['rootName'])['markers']['set'](_0x4b0158,_0x4a81f0['clone']());}const _0x1b0728=new Map(),_0x2852cc=new Map();for(const [_0x2a6120,_0x5bce29]of this['_diffRoots'])_0x1b0728['set'](_0x2a6120,F(_0x5bce29)),_0x2852cc['set'](_0x2a6120,this['_diffRootsAttributes']['get'](_0x2a6120));this['_saveMetaData'](_0x20b023,_0x1b0728,this['_markers'],_0x2852cc);}['_getPreviousFrom'](_0x3bfba8){const _0x441afd=Array['from'](this['_savedMetaData']['keys']());_0x441afd['sort']((_0x65d3b3,_0x3f2db0)=>_0x65d3b3-_0x3f2db0),_0x441afd['reverse']();for(const _0x51e13a of _0x441afd)if(_0x51e13a<_0x3bfba8)return _0x51e13a;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x1564d9,_0x19e287){const _0x4c114a=Array['from'](_0x19e287['markers'])['map'](([_0x4b325b,_0x1e6c13])=>[_0x4b325b,this['_fixRange'](_0x1e6c13,_0x1564d9)]);_0x1564d9['markers']=new Map(_0x4c114a);}['_transformMarkers'](_0x34ebda){for(const _0x5b923f of this['_markers']['values']()){const _0x2c5b72=_0x5b923f['getTransformedByOperation'](_0x34ebda),_0x164fdf=vt['_createFromRanges'](_0x2c5b72);_0x5b923f['start']=_0x164fdf['start'],_0x5b923f['end']=_0x164fdf['end'];}}['_handleOperation'](_0xf9f5b7,_0x33ea0e){if('addRoot'!=_0xf9f5b7['type']&&'detachRoot'!=_0xf9f5b7['type']){if('insert'==_0xf9f5b7['type']){const _0x4c2c87=_0xf9f5b7['position']['root']['rootName'];this['_diffRoots']['has'](_0x4c2c87)||(this['_diffRoots']['set'](_0x4c2c87,B(_0x4c2c87,!0x0)),this['_diffRootsAttributes']['set'](_0x4c2c87,{}),_0x33ea0e&&this['_idsRoots']['set'](_0x4c2c87,B(_0x4c2c87,!0x0)));}else{if('addRootAttribute'==_0xf9f5b7['type']||'removeRootAttribute'==_0xf9f5b7['type']||'changeRootAttribute'==_0xf9f5b7['type'])return void this['_handleRootAttributeOperation'](_0xf9f5b7);'marker'==_0xf9f5b7['type']&&this['_handleMarkerOperation'](_0xf9f5b7);}if('marker'!==_0xf9f5b7['type']){const _0x33bd13=this['_cloneOperation'](_0xf9f5b7,this['_diffRoots']);_0x33bd13['_execute'](),this['_transformMarkers'](_0x33bd13);}if(_0x33ea0e)switch(_0xf9f5b7['type']){case'insert':this['_handleInsertOperation'](_0xf9f5b7);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0xf9f5b7);break;case'merge':this['_handleMergeOperation'](_0xf9f5b7);break;case'split':this['_handleSplitOperation'](_0xf9f5b7);}}else this['_handleRootOperation'](_0xf9f5b7,_0x33ea0e);}['_cloneOperation'](_0x367621,_0x563f06){const _0x115e20=_0x367621['clone']();return _0x115e20['_authorId']=_0x367621['_authorId'],this['_fixOperation'](_0x115e20,_0x563f06),_0x115e20;}['_getBaseVids'](_0x8f619){return _0x8f619['map'](_0x36ccc5=>{const _0x47ba25=this['_getVidAttributeName'](_0x36ccc5);return Number(_0x36ccc5['item']['getAttribute'](_0x47ba25));});}['_generateTape'](_0x44bbe5,_0x1f3284){if(_0x44bbe5['is']('element','$text'))_0x1f3284['push']({'item':_0x44bbe5,'type':'text'});else{_0x44bbe5['is']('element')&&_0x1f3284['push']({'item':_0x44bbe5,'type':'elementStart'});for(const _0x5170b5 of _0x44bbe5['getChildren']())this['_generateTape'](_0x5170b5,_0x1f3284);_0x44bbe5['is']('element')&&_0x1f3284['push']({'item':_0x44bbe5,'type':'elementEnd'});}return _0x1f3284;}['_getState'](){const _0x1223d6=new Map(this['_touched']),_0x485bed=new Map(_0x1223d6),_0x1718b9=new Map(),_0x52ae65={'insertions':{},'deletions':{}},_0x3a00b0={'insertions':{},'deletions':{}},_0x158793=new Map(),_0x29775c=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x29775c['delete']('$graveyard');for(const _0x215b0b of _0x29775c){const _0x3e22bf=this['_diffRoots']['get'](_0x215b0b)||B(_0x215b0b,!0x1),_0x4907d7=this['_baseRoots']['get'](_0x215b0b)||B(_0x215b0b,!0x1);_0x3e22bf['isAttached']()||_0x4907d7['isAttached']()?(_0x52ae65['insertions'][_0x215b0b]=F(_0x3e22bf),_0x52ae65['deletions'][_0x215b0b]=F(_0x4907d7),this['_copyMarkers'](_0x52ae65['deletions'][_0x215b0b],_0x4907d7),this['_copyMarkers'](_0x52ae65['insertions'][_0x215b0b],_0x3e22bf),_0x3a00b0['insertions'][_0x215b0b]=this['_generateTape'](this['_idsRoots']['get'](_0x215b0b),[]),_0x3a00b0['deletions'][_0x215b0b]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x215b0b)||B(_0x215b0b,!0x1),[])):_0x29775c['delete'](_0x215b0b);}for(const _0x2b05e4 of _0x29775c){const _0x38e2d2=_0x3a00b0['insertions'][_0x2b05e4];for(const _0x3689db of _0x38e2d2){const _0x1b3c6a=this['_getVidAttributeName'](_0x3689db),_0x2e3773=_0x3689db['item']['getAttribute'](_0x1b3c6a);_0x485bed['delete'](_0x2e3773),_0x2e3773>=this['_startingRevisionId']&&_0x1718b9['set'](_0x2e3773,_0x1223d6['get'](_0x2e3773));}}for(const _0x3d88d0 of _0x29775c){const _0x5ec876=_0x3a00b0['insertions'][_0x3d88d0],_0x5c9084=this['_getBaseVids'](_0x3a00b0['deletions'][_0x3d88d0]);let _0x2d20f7=0x0;for(const _0x2b0c55 of _0x5ec876){const _0xc9a955=this['_getVidAttributeName'](_0x2b0c55),_0x1d1817=_0x2b0c55['item']['getAttribute'](_0xc9a955);if(!_0x1718b9['has'](_0x1d1817)&&!_0x158793['has'](_0x1d1817)){if(_0x485bed['has'](_0x1d1817))_0x2d20f7++;else{if(_0x1d1817!=_0x5c9084[_0x2d20f7]){const _0x400f37=_0x1223d6['get'](_0x1d1817)||_0x1223d6['get'](_0x5c9084[_0x2d20f7]);for(;_0x1d1817!=_0x5c9084[_0x2d20f7];)_0x485bed['has'](_0x5c9084[_0x2d20f7])||(_0x158793['set'](_0x5c9084[_0x2d20f7],_0x400f37),_0x1223d6['set'](_0x5c9084[_0x2d20f7],_0x400f37)),_0x2d20f7++;}_0x2d20f7++;}}}}for(const _0xd398c5 of _0x29775c){const _0x2d0993=_0x3a00b0['insertions'][_0xd398c5];for(const _0x4dc580 of _0x2d0993){const _0xd14049=this['_getVidAttributeName'](_0x4dc580),_0x4fac07=_0x4dc580['item']['getAttribute'](_0xd14049);if(_0x158793['has'](_0x4fac07)){const _0x563606=_0x158793['get'](_0x4fac07);_0x485bed['has'](_0x4fac07)||_0x485bed['set'](_0x4fac07,{..._0x563606}),_0x1718b9['set'](_0x4fac07,{..._0x563606});}}}for(const _0x6a1ca0 of _0x485bed['keys']())_0x6a1ca0>=this['_startingRevisionId']&&_0x485bed['delete'](_0x6a1ca0);const _0x2188ba=new Map();for(const _0x403a5a of _0x29775c){let _0x5e0af5=_0x3a00b0['insertions'][_0x403a5a];for(const _0x16e4b7 of _0x5e0af5)if(_0x16e4b7['item']['is']('element','tableCell')){const _0x5965d2=this['_getVidAttributeName'](_0x16e4b7),_0x3af3b0=_0x16e4b7['item']['getAttribute'](_0x5965d2);if(_0x1718b9['has'](_0x3af3b0)){const _0x138389=_0x16e4b7['item']['parent']['parent']['getAttribute']('vid_start'),_0x26b582=_0x2188ba['get'](_0x138389)||new Set();_0x26b582['add'](_0x1718b9['get'](_0x3af3b0)['userId']),_0x2188ba['set'](_0x138389,_0x26b582);}}_0x5e0af5=_0x3a00b0['deletions'][_0x403a5a];for(const _0x4ae266 of _0x5e0af5)if(_0x4ae266['item']['is']('element','tableCell')){const _0x24f2bb=this['_getVidAttributeName'](_0x4ae266),_0x109c5f=_0x4ae266['item']['getAttribute'](_0x24f2bb);if(_0x485bed['has'](_0x109c5f)){const _0x1bea04=_0x4ae266['item']['parent']['parent']['getAttribute']('vid_start'),_0x4b4374=_0x2188ba['get'](_0x1bea04)||new Set();_0x4b4374['add'](_0x485bed['get'](_0x109c5f)['userId']),_0x2188ba['set'](_0x1bea04,_0x4b4374);}}for(const _0x1b0fc9 of _0x2188ba['keys']())(_0x1718b9['has'](_0x1b0fc9)||_0x485bed['has'](_0x1b0fc9))&&_0x2188ba['delete'](_0x1b0fc9);}for(const _0xf6a5a7 of _0x29775c){const _0x41f4f6=_0x3a00b0['insertions'][_0xf6a5a7];let _0x221c66=null,_0x12f0d7=null;for(const _0x5d1a39 of _0x41f4f6){const _0x3034fd=this['_getVidAttributeName'](_0x5d1a39),_0x514adf=_0x5d1a39['item']['getAttribute'](_0x3034fd),_0x536eef=_0x2188ba['get'](_0x514adf);_0x536eef&&'elementStart'==_0x5d1a39['type']&&(_0x221c66=Array['from'](_0x536eef)[0x0],_0x12f0d7=_0x5d1a39['item']['getAttribute']('vid_end')),_0x221c66&&(_0x485bed['set'](_0x514adf,{'userId':_0x221c66}),_0x1718b9['set'](_0x514adf,{'userId':_0x221c66})),_0x514adf==_0x12f0d7&&(_0x221c66=null,_0x12f0d7=null);}}const _0x51ada8={},_0x5ccd49=new Set();for(const _0x5f7fbb of _0x29775c){const _0x16c630=_0x52ae65['deletions'][_0x5f7fbb],_0x5f4853=_0x52ae65['insertions'][_0x5f7fbb];for(const {userId:_0x27cdb5}of this['_touchedMarkers']['values']())null!==_0x27cdb5&&_0x5ccd49['add'](_0x27cdb5);for(const {userId:_0x4900b2}of this['_touchedRoots']['values']())null!==_0x4900b2&&_0x5ccd49['add'](_0x4900b2);this['_markChanges'](_0x5f4853,_0x3a00b0['insertions'][_0x5f7fbb],_0x1718b9,'insertion',_0x5ccd49),this['_markChanges'](_0x16c630,_0x3a00b0['deletions'][_0x5f7fbb],_0x485bed,'deletion',_0x5ccd49),_0x51ada8[_0x5f7fbb]={'insertions':this['_prepareViewToSave'](_0x5f4853),'deletions':this['_prepareViewToSave'](_0x16c630),'attachChange':this['_touchedRoots']['get'](_0x5f7fbb)||null,'attributesBefore':_0x3c49e8(this['_baseRootsAttributes']['get'](_0x5f7fbb))||{},'attributesAfter':_0x3c49e8(this['_diffRootsAttributes']['get'](_0x5f7fbb))};}return{'diffData':_0x51ada8,'authorsIds':Array['from'](_0x5ccd49)};}['_processRootBeforeSave'](_0x23b01d){for(const [,_0x3fda5b]of _0x23b01d['markers']){const _0x3ff602=_0x3fda5b['start']['getAncestors']()['filter'](_0xe2c4ba=>'tableCell'==_0xe2c4ba['name']);for(const _0x36cffc of _0x3ff602)0x1==_0x36cffc['childCount']&&_0x36cffc['getChild'](0x0)['is']('element','paragraph')&&_0x36cffc['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x3288d2){this['_processRootBeforeSave'](_0x3288d2);const _0x68bea0=this['editor']['data']['toView'](_0x3288d2,{}),_0x5bdfed=Array['from'](_0x68bea0['getChildren']())['map'](_0x262a2b=>this['_getViewJson'](_0x262a2b));return JSON['stringify'](_0x5bdfed);}['_getViewJson'](_0x270266){if(_0x270266['is']('$text'))return _0x270266['data'];{const _0x232282=_0x270266;return{'type':Object['keys'](C)['find'](_0x244082=>_0x270266 instanceof C[_0x244082]),'name':_0x232282['name'],'attributes':Array['from'](_0x232282['getAttributes']()),'children':Array['from'](_0x232282['getChildren']())['map'](_0xb7b97e=>this['_getViewJson'](_0xb7b97e))};}}['_markChanges'](_0xbe4cbc,_0x5cb971,_0x4b53d1,_0x50e6bb,_0x4e05bd){let _0x42e339=null,_0x3bcf9c=null,_0x49442b=0x0;const _0x2baa4f=this['editor']['model'];for(let _0x3c4ee7=0x0;_0x3c4ee7<_0x5cb971['length'];_0x3c4ee7++){const _0x48a602=this['_getVidAttributeName'](_0x5cb971[_0x3c4ee7]),_0x463937=_0x5cb971[_0x3c4ee7]['item']['getAttribute'](_0x48a602),_0x46245c=_0x4b53d1['get'](_0x463937),_0x1925eb=_0x3c4ee7==_0x5cb971['length']-0x1;(!_0x42e339&&_0x46245c&&(_0x42e339=_0x46245c,_0x3bcf9c=_0x5cb971[_0x3c4ee7]),_0x42e339&&(!_0x46245c||_0x46245c['userId']!=_0x42e339['userId']))&&(_0x288444(_0x46245c,J(_0x3bcf9c,_0xbe4cbc,_0x2baa4f),J(_0x5cb971[_0x3c4ee7],_0xbe4cbc,_0x2baa4f)),_0x42e339=_0x46245c||null,_0x3bcf9c=_0x46245c?_0x5cb971[_0x3c4ee7]:null),_0x42e339&&_0x1925eb&&_0x288444(_0x46245c,J(_0x3bcf9c,_0xbe4cbc,_0x2baa4f),q(_0x5cb971[_0x3c4ee7],_0xbe4cbc,_0x2baa4f));}function _0x288444(_0x1a3a7e,_0x7191e,_0xd98aa3){const _0x23aaa3=_0x42e339['userId'],_0x3c7716='revision:'+_0x50e6bb+':'+_0x23aaa3+':'+_0x49442b++,_0x2eac6f=_0x2baa4f['createRange'](_0x7191e,_0xd98aa3);_0xbe4cbc['markers']['set'](_0x3c7716,_0x2eac6f),null!==_0x23aaa3&&_0x4e05bd['add'](_0x23aaa3);}}['_getVidAttributeName'](_0x4c4f04){switch(_0x4c4f04['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x244748,_0x234042){_0x244748['baseVersion']=null;for(const _0x119d5e in _0x244748){const _0x3499f7=_0x244748[_0x119d5e];if(_0x3499f7 instanceof gt){const _0x19740a=_0x234042['get'](_0x3499f7['root']['rootName']);_0x244748[_0x119d5e]=this['_fixPosition'](_0x3499f7,_0x19740a);}if(_0x3499f7 instanceof vt){const _0x2f4ef4=_0x234042['get'](_0x3499f7['root']['rootName']);_0x244748[_0x119d5e]=this['_fixRange'](_0x3499f7,_0x2f4ef4);}'root'===_0x119d5e&&(_0x244748['root']=_0x234042['get'](_0x244748['root']['rootName']));}}['_fixRange'](_0x2b915b,_0x3a67ea){return this['editor']['model']['createRange'](this['_fixPosition'](_0x2b915b['start'],_0x3a67ea),this['_fixPosition'](_0x2b915b['end'],_0x3a67ea));}['_fixPosition'](_0x58bc90,_0xec1c8e){return this['editor']['model']['createPositionFromPath'](_0xec1c8e,_0x58bc90['path'],_0x58bc90['stickiness']);}['_handleInsertOperation'](_0x1d7280){const _0x10a4f6=this['_idsRoots']['get'](_0x1d7280['position']['root']['rootName']),_0x3df063=this['_fixPosition'](_0x1d7280['position'],_0x10a4f6),_0x20429b=null===_0x1d7280['_authorId']?null:_0x1d7280['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x6ea76b=_0x3df063['parent'],_0x1b6e6d=this['_revisionId'],_0x5f5177=[];for(const _0x4e71fe of _0x1d7280['nodes'])if(_0x4e71fe['is']('element'))_0x5f5177['push'](this['_makeIdsRoot'](_0x4e71fe));else{for(let _0x8ea113=0x0;_0x8ea113<_0x4e71fe['offsetSize'];_0x8ea113++)_0x5f5177['push'](new ft('$text',{'vid':this['_revisionId']++}));}const _0x233d08=this['_revisionId'];for(let _0x553888=_0x1b6e6d;_0x553888<_0x233d08;_0x553888++)this['_touched']['set'](_0x553888,{'userId':_0x20429b});_0x6ea76b['_insertChild'](_0x3df063['offset'],_0x5f5177);}['_handleMoveOperation'](_0x3b651c){(_0x3b651c=this['_cloneOperation'](_0x3b651c,this['_idsRoots']))['_execute']();const _0x3b7a35=null===_0x3b651c['_authorId']?null:_0x3b651c['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x2cd14d=_0x3b651c['getMovedRangeStart'](),_0xb83730=_0x2cd14d['parent'],_0x5b62de=_0x2cd14d['offset'];!function _0x34a57f(_0x52b481,_0x49de91,_0x5be8a8,_0x3f951b){for(let _0x5df75d=_0x5be8a8;_0x5df75d<_0x3f951b;_0x5df75d++){const _0x4dca39=_0x49de91['getChild'](_0x5df75d);_0x4dca39['is']('element','$text')?_0x52b481['set'](_0x4dca39['getAttribute']('vid'),{'userId':_0x3b7a35}):(_0x52b481['set'](_0x4dca39['getAttribute']('vid_start'),{'userId':_0x3b7a35}),_0x34a57f(_0x52b481,_0x4dca39,0x0,_0x4dca39['childCount']),_0x52b481['set'](_0x4dca39['getAttribute']('vid_end'),{'userId':_0x3b7a35}));}}(this['_touched'],_0xb83730,_0x5b62de,_0x5b62de+_0x3b651c['howMany']);}['_handleMergeOperation'](_0x31e5d3){const _0x5b03db=null===(_0x31e5d3=this['_cloneOperation'](_0x31e5d3,this['_idsRoots']))['_authorId']?null:_0x31e5d3['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x4b052b=_0x31e5d3['targetPosition']['parent'],_0x12a266=_0x31e5d3['sourcePosition']['parent'],_0x154d40=_0x4b052b['getAttribute']('vid_end'),_0xb710fa=_0x12a266['getAttribute']('vid_start');_0x4b052b['_setAttribute']('vid_end',_0x12a266['getAttribute']('vid_end')),_0x12a266['_setAttribute']('vid_end',_0x154d40),this['_touched']['set'](_0xb710fa,{'userId':_0x5b03db}),this['_touched']['set'](_0x154d40,{'userId':_0x5b03db}),_0x31e5d3['_execute']();}['_handleSplitOperation'](_0x375650){const _0x484abb=null===(_0x375650=this['_cloneOperation'](_0x375650,this['_idsRoots']))['_authorId']?null:_0x375650['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x47a428=_0x375650['graveyardPosition'],_0x2bdfed=_0x375650['splitPosition']['parent'];_0x375650['_execute']();const _0x80e1ff=_0x2bdfed['getAttribute']('vid_end'),_0x3e2d28=_0x375650['insertionPosition']['nodeAfter'];if(_0x47a428){const _0x2659ce=_0x3e2d28['getAttribute']('vid_end'),_0x3817eb=_0x2bdfed['getAttribute']('vid_end');_0x2bdfed['_setAttribute']('vid_end',_0x2659ce),_0x3e2d28['_setAttribute']('vid_end',_0x3817eb),this['_touched']['set'](_0x2bdfed['getAttribute']('vid_end'),{'userId':_0x484abb}),this['_touched']['set'](_0x3e2d28['getAttribute']('vid_start'),{'userId':_0x484abb});}else{const _0x4b62ad=this['_revisionId']++,_0x19ff98=this['_revisionId']++;_0x2bdfed['_setAttribute']('vid_end',_0x4b62ad),_0x3e2d28['_setAttribute']('vid_start',_0x19ff98),_0x3e2d28['_setAttribute']('vid_end',_0x80e1ff),this['_touched']['set'](_0x4b62ad,{'userId':_0x484abb}),this['_touched']['set'](_0x19ff98,{'userId':_0x484abb});}}['_handleMarkerOperation'](_0x1de9a){if(!_0x1de9a['affectsData'])return;const _0x1e6921=(_0x1de9a=this['_cloneOperation'](_0x1de9a,this['_diffRoots']))['oldRange']?_0x1de9a['oldRange']['root']:null,_0x2802a5=_0x1de9a['newRange']?_0x1de9a['newRange']['root']:null;_0x1e6921&&this['_markers']['delete'](_0x1de9a['name']),_0x2802a5&&this['_markers']['set'](_0x1de9a['name'],_0x1de9a['newRange']['clone']());const _0x3eb096=null===_0x1de9a['_authorId']?null:_0x1de9a['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x103930=_0x1de9a['name'];if(!this['_touchedMarkers']['has'](_0x103930))return void this['_touchedMarkers']['set'](_0x103930,{'range':_0x1de9a['oldRange'],'userId':_0x3eb096});const _0x13ee3e=this['_touchedMarkers']['get'](_0x103930),_0x3f9f90=_0x13ee3e['range'],_0x2a58fe=_0x1de9a['newRange'];null==_0x3f9f90&&null==_0x2a58fe||_0x3f9f90&&_0x2a58fe&&_0x3f9f90['isEqual'](_0x2a58fe)?this['_touchedMarkers']['delete'](_0x1de9a['name']):_0x13ee3e['userId']=_0x3eb096;}['_handleRootOperation'](_0x303c67,_0xac0f5f){this['_diffRoots']['has'](_0x303c67['rootName'])?this['_diffRoots']['get'](_0x303c67['rootName'])['_isAttached']=_0x303c67['isAdd']:(this['_diffRoots']['set'](_0x303c67['rootName'],B(_0x303c67['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x303c67['rootName'],{}),_0xac0f5f&&this['_idsRoots']['set'](_0x303c67['rootName'],B(_0x303c67['rootName'],!0x0)));const _0x5b1511=null===_0x303c67['_authorId']?null:_0x303c67['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x14b9de=this['_touchedRoots']['get'](_0x303c67['rootName']);_0x14b9de&&_0x14b9de['userId']===_0x5b1511?this['_touchedRoots']['delete'](_0x303c67['rootName']):this['_touchedRoots']['set'](_0x303c67['rootName'],{'userId':_0x5b1511,'isAttached':_0x303c67['isAdd']});}['_handleRootAttributeOperation'](_0xe074cb){const _0x2b8239=this['_diffRootsAttributes']['get'](_0xe074cb['root']['rootName']);null===_0xe074cb['newValue']?delete _0x2b8239[_0xe074cb['key']]:_0x2b8239[_0xe074cb['key']]=_0xe074cb['newValue'];}}function F(_0x261202){const _0x1ef347=B(_0x261202['rootName'],_0x261202['isAttached']());for(const _0x38a6a1 of _0x261202['getChildren']()){const _0x236c64=_0x38a6a1['_clone'](!0x0);_0x1ef347['_appendChild'](_0x236c64);}return _0x1ef347;}function B(_0xbdd29d,_0x25648d=!0x0){const _0x3f27c3=new wt();return _0x3f27c3['rootName']=_0xbdd29d,_0x3f27c3['_isAttached']=_0x25648d,_0x3f27c3['isAttached']=()=>_0x3f27c3['_isAttached'],_0x3f27c3;}function J(_0x260c76,_0x1af86c,_0x2b7ec9){const _0xcfe286='elementEnd'==_0x260c76['type']?_0x2b7ec9['createPositionAt'](_0x260c76['item'],'end'):_0x2b7ec9['createPositionBefore'](_0x260c76['item']);return _0x2b7ec9['createPositionFromPath'](_0x1af86c,_0xcfe286['path'],_0xcfe286['stickiness']);}function q(_0x1d0799,_0x14b4a0,_0x32e0f1){const _0x28e6d0='elementStart'==_0x1d0799['type']?_0x32e0f1['createPositionAt'](_0x1d0799['item'],0x0):_0x32e0f1['createPositionAfter'](_0x1d0799['item']);return _0x32e0f1['createPositionFromPath'](_0x14b4a0,_0x28e6d0['path'],_0x28e6d0['stickiness']);}class ns extends _0x4be5f7{['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x9f59f1,_0xb1c02f){super(_0x9f59f1),this['focusTracker']=new _0x452fb4(),this['keystrokes']=new _0x4535b7(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0xb1c02f),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'](),_0x1aed20({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x21a623=_0x2c70ce=>_0x2c70ce['stopPropagation']();this['keystrokes']['set']('arrowright',_0x21a623),this['keystrokes']['set']('arrowleft',_0x21a623),this['keystrokes']['set']('arrowup',_0x21a623),this['keystrokes']['set']('arrowdown',_0x21a623);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x229e1f){this['revisionNameInputView']['fieldView']['element']['value']=_0x229e1f['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x58e704){const _0x26bff7=new at(this['locale'],_0xbf0be),_0x3ed156=_0x26bff7['fieldView'];_0x3ed156['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x20e6c5=R(this['locale'],'Name\x20of\x20the\x20revision');return!_0x58e704&&(_0x20e6c5+='\x20('+R(this['locale'],'optional')+')'),(_0x26bff7['label']=_0x20e6c5,_0x3ed156['on']('input',()=>{this['revisionNameInputValue']=_0x3ed156['element']['value']['trim']();}),_0x26bff7);}}class u extends _0x2ebc56{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l];}['_saveRevisionFormView'];['init'](){const _0x52b2cd=this['editor'],_0xdb6ac9=_0x52b2cd['plugins']['get']('RevisionTracker');_0x52b2cd['ui']['componentFactory']['add']('revisionHistory',_0x5643dc=>{const _0x54b211=_0x30f9aa(_0x5643dc),_0x3dccb0=_0x54b211['panelView']['children'],_0x51ee9e=new te(_0x5643dc),_0x39844e=new _0x5a8f54(_0x5643dc),_0x39bfaf=new _0x5ae3a4(_0x5643dc),_0x4c116d=new _0x5a8f54(_0x5643dc),_0x8e29d5=new _0x5ae3a4(_0x5643dc);return _0x54b211['bind']('isEnabled')['to'](_0xdb6ac9,'isReady',_0xdb6ac9,'isEnabled',_0x52b2cd,'isReadOnly',(_0x4d8a5f,_0x51a1e9,_0x24fd2e)=>_0x4d8a5f&&_0x51a1e9&&!_0x24fd2e),_0x54b211['buttonView']['set']({'icon':_0xaa90df['history'],'label':R(_0x5643dc,'Revision\x20history'),'tooltip':!0x0}),_0x39bfaf['set']({'label':R(_0x5643dc,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x39bfaf['bind']('isEnabled')['to'](_0xdb6ac9,'isReady',_0xdb6ac9,'isEnabled',_0x52b2cd,'isReadOnly',(_0x3f1a9c,_0x103e93,_0x2760b0)=>_0x3f1a9c&&_0x103e93&&!_0x2760b0),_0x39bfaf['on']('execute',()=>this['_showDialog']()),_0x8e29d5['set']({'label':R(_0x5643dc,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x8e29d5['bind']('isEnabled')['to'](_0xdb6ac9,'isReady',_0x52b2cd,'isReadOnly',(_0x31fe82,_0x3921bb)=>_0x31fe82&&!_0x3921bb),_0x8e29d5['on']('execute',()=>{_0x52b2cd['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x54b211['isOpen']=!0x1,_0x52b2cd['editing']['view']['focus']();}),_0x39844e['children']['add'](_0x39bfaf),_0x4c116d['children']['add'](_0x8e29d5),_0x51ee9e['role']='menu',_0x51ee9e['items']['addMany']([_0x39844e,_0x4c116d]),_0x3dccb0['add'](_0x51ee9e),_0x54b211;}),_0x52b2cd['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x1aabdd=this['editor'],_0x1ad063=_0x1aabdd['locale'],_0x1679b8=new _0x249393(_0x1ad063),_0x362bb4=new _0x59a9bd(_0x1ad063);_0x1679b8['buttonView']['set']({'icon':_0xaa90df['history'],'label':R(_0x1ad063,'Revision\x20history')});const _0x560d7a=new _0x4d54e9(_0x1ad063,_0x1679b8),_0x450ed2=new _0x1548c1(_0x1ad063);_0x450ed2['set']({'label':R(_0x1ad063,'Save\x20current\x20revision')}),_0x450ed2['delegate']('execute')['to'](_0x1679b8),_0x450ed2['on']('execute',()=>{this['_showDialog']();}),_0x560d7a['children']['add'](_0x450ed2),_0x362bb4['items']['add'](_0x560d7a);const _0x33ab7d=new _0x4d54e9(_0x1ad063,_0x1679b8),_0x31a2e4=new _0x1548c1(_0x1ad063);return _0x31a2e4['set']({'label':R(_0x1ad063,'Open\x20revision\x20history')}),_0x31a2e4['delegate']('execute')['to'](_0x1679b8),_0x31a2e4['on']('execute',()=>{_0x1aabdd['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x33ab7d['children']['add'](_0x31a2e4),_0x362bb4['items']['add'](_0x33ab7d),_0x1679b8['panelView']['children']['add'](_0x362bb4),_0x1679b8;}['_showDialog'](){const _0x4cc6ac=this['editor'],_0x47688a=_0x4cc6ac['locale'],_0x1ec053=_0x4cc6ac['plugins']['get']('Dialog'),_0x5c135e=_0x4cc6ac['plugins']['get']('RevisionTracker');function _0x26bb9a(_0x1bc317){_0x4cc6ac['config']['get']('revisionHistory.requireRevisionName')&&''===_0x1bc317['revisionName']?_0x1bc317['revisionNameInputView']['errorText']=R(_0x47688a,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x4cc6ac['plugins']['get'](l)['saveRevision']({'name':_0x1bc317['revisionName']}),_0x1ec053['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x26bb9a(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x1ec053['show']({'id':'revisionSave','title':R(_0x47688a,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':R(_0x4cc6ac['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x1ec053['hide']()},{'label':R(_0x4cc6ac['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x2b97e0){_0x2b97e0['bind']('isEnabled')['to'](_0x5c135e,'isReady',_0x5c135e,'isEnabled',_0x4cc6ac,'isReadOnly',(_0x180378,_0x57cb71,_0x1acba0)=>_0x180378&&_0x57cb71&&!_0x1acba0);},'onExecute':()=>_0x26bb9a(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x51e07b=this['editor'],_0x6675b6=_0x51e07b['locale'];this['_saveRevisionFormView']=new ns(_0x6675b6,_0x51e07b['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class Y extends _0x4be5f7{['changeId'];['_model'];constructor(_0x350ca8,_0x543244){super(_0x350ca8),this['_model']=_0x543244,this['changeId']=_0x543244['id'];const _0x34c128=this['bindTemplate'],_0x13adc7=R(_0x350ca8,_0x543244['data']['isSuggestion']?'Suggested\x20by':'add'==_0x543244['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x543244['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x34c128['to']('type',_0x3c16f6=>'ck-revision-change__'+_0x3c16f6)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x13adc7}]},{'text':'\x20'+_0x543244['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class r extends/* #__PURE__ -- @preserve */
25
+ _0x66ca88(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x23ad11){super(),this['id']=_0x23ad11['id']||_0xb3cc0b(),this['author']=_0x23ad11['author'],this['type']=_0x23ad11['type'],this['data']=_0x23ad11['data']||{},this['rootName']=_0x23ad11['rootName'],this['set']('createdAt',_0x23ad11['createdAt']);}['toJSON'](){return{'id':this['id'],'authorId':this['author']['id'],'type':this['type'],'data':this['data'],'createdAt':this['createdAt']};}}class f{['newRevisionId'];['oldRevisionId'];['changes'];constructor(_0x1eb7f6,_0x6c7cb5){this['newRevisionId']=_0x1eb7f6,this['oldRevisionId']=_0x6c7cb5,this['changes']=new _0x199961();}['_setChanges'](_0x539791){for(const _0x3137e2 of _0x539791)this['changes']['add'](_0x3137e2);}}const Z={'c':_0x26af22,'a':_0x505635,'e':_0x3ff6a6,'r':_0x4abad2,'u':_0x29510a};class d extends _0x2ebc56{['repository'];['adapter'];['_activeViewTarget'];['_changeView'];['_changeIdToChange'];['_balloon'];static get['pluginName'](){return'RevisionViewer';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[_0x305d7f,_0xfee5aa,j];}constructor(_0x1f36bf){super(_0x1f36bf),this['repository']=this['editor']['plugins']['get']('RevisionsRepository'),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',(_0x135542,_0x499a2c,_0xd459d0)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x1addd3=>{for(const _0x346e12 of this['editor']['editing']['view']['document']['roots'])_0xd459d0?_0x1addd3['removeClass']('ck-editor__editable__overlay',_0x346e12):_0x1addd3['addClass']('ck-editor__editable__overlay',_0x346e12);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x32b9ad=>null!==_0x32b9ad),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x7b5a01,_0x3c90a7,_0xbe6c98)=>_0x7b5a01&&_0xbe6c98?_0x3c90a7['changes']['getIndex'](_0xbe6c98):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x5dae3f,_0x8fe0e2)=>_0x5dae3f?_0x8fe0e2['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['adapter']=null,this['_balloon']=this['editor']['plugins']['get'](_0xfee5aa);}['init'](){const _0x2b5450=this['editor'],_0x352697=new bt(_0x2b5450,{'direction':'backward'}),_0x2cb34d=new bt(_0x2b5450,{'direction':'forward'});(_0x2b5450['commands']['add']('showPreviousChange',_0x352697),_0x2b5450['commands']['add']('showNextChange',_0x2cb34d),_0x2b5450['commands']['add']('restoreRevision',new yt(_0x2b5450)),this['on']('change:numberOfChanges',()=>{_0x352697['refresh'](),_0x2cb34d['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x2b5450['enableReadOnlyMode']('revision-viewer'),_0x2b5450['plugins']['has']('WidgetToolbarRepository'))&&_0x2b5450['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionData'](_0x6bf27){await this['loadRevisionData'](_0x6bf27);const _0x42d765={};for(const _0x2c23c0 in _0x6bf27['diffData']){if(_0x6bf27['diffData'][_0x2c23c0]['attachChange']&&!_0x6bf27['diffData'][_0x2c23c0]['attachChange']['isAttached'])continue;const _0x563885=this['_removeRevisionMarkers'](JSON['parse'](_0x6bf27['diffData'][_0x2c23c0]['insertions'])),_0x49c091=this['editor']['editing']['view']['document'],_0x546d89=new _0x471757(_0x49c091,_0x563885['map'](_0xd0045b=>this['_getViewObj'](_0xd0045b)));this['editor']['data']['processor']['useFillerType']('marked'),_0x42d765[_0x2c23c0]=this['editor']['data']['processor']['toData'](_0x546d89),this['editor']['data']['processor']['useFillerType']('default');}return _0x42d765;}async['getRevisionRootsAttributes'](_0x10c1ab){await this['loadRevisionData'](_0x10c1ab);const _0x316b7a={};for(const _0x8a29f4 in _0x10c1ab['diffData'])_0x10c1ab['diffData'][_0x8a29f4]['attachChange']&&!_0x10c1ab['diffData'][_0x8a29f4]['attachChange']['isAttached']||(_0x316b7a[_0x8a29f4]=_0x10c1ab['diffData'][_0x8a29f4]['attributesAfter']||{});return _0x316b7a;}['_removeRevisionMarkers'](_0x317e65){return(_0x317e65=_0x317e65['filter'](_0x2f594c=>!_0x2f594c['name']||'revision-start'!==_0x2f594c['name']&&'revision-end'!==_0x2f594c['name']))['forEach'](_0x1ac753=>{'string'!=typeof _0x1ac753&&(_0x1ac753['children']=this['_removeRevisionMarkers'](_0x1ac753['children']),_0x1ac753['attributes']=_0x1ac753['attributes']['filter'](_0x8b14c=>!_0x8b14c[0x0]['startsWith']('data-revision-')));}),_0x317e65;}async['compare'](_0x5b8b68,_0x3cbbd7,_0x34c06c=!0x1){if(!this['isEnabled'])return;const _0x2f1dcb=this['diff'],_0x43f2ef=this['repository'],_0x491888='string'==typeof _0x5b8b68?_0x43f2ef['getRevision'](_0x5b8b68):_0x5b8b68,_0x3f9f8f='string'==typeof _0x3cbbd7?_0x43f2ef['getRevision'](_0x3cbbd7):_0x3cbbd7,_0x335bd4=_0x491888['id'],_0x3197c3=_0x3f9f8f?_0x3f9f8f['id']:null;if(!_0x34c06c&&this['diff']&&this['diff']['newRevisionId']===_0x335bd4&&this['diff']['oldRevisionId']===_0x3197c3)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new f(_0x335bd4,_0x3197c3);const _0x43b207=this['_getRevisionsRange'](_0x491888,_0x3f9f8f,!0x0)['map'](_0x19a50f=>this['loadRevisionData'](_0x19a50f));return _0x43b207['push'](new Promise(_0x3976da=>{setTimeout(_0x3976da,0x14);})),Promise['all'](_0x43b207)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x20fd36=this['_getDiff'](_0x335bd4,_0x3197c3);for(const _0x13193f of _0x20fd36['changes'])this['_changeIdToChange']['set'](_0x13193f['id'],_0x13193f);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x460161=>{for(const _0x44a815 of this['editor']['model']['document']['getRootNames']())_0x460161['detachRoot'](_0x44a815);for(const _0x5088d7 of Object['keys'](_0x20fd36['model'])){const _0x554329=_0x460161['addRoot'](_0x5088d7);for(const _0x4cfe34 of Object['keys'](_0x20fd36['attributes'][_0x5088d7]))_0x460161['setAttribute'](_0x4cfe34,_0x20fd36['attributes'][_0x5088d7][_0x4cfe34],_0x554329);_0x460161['insert'](_0x20fd36['model'][_0x5088d7],_0x554329,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x20fd36['changes'])),this['isReady']=!0x0;})['catch'](_0x4a8919=>{console['error'](_0x4a8919),this['_cleanUp'](),_0x2f1dcb&&(this['diff']=_0x2f1dcb),this['isReady']=!0x0;});}['addRevisionData'](_0x568c25,_0x588b18){const _0x4d103e=this['repository']['createRevision'](_0x568c25);return _0x4d103e['on']('_update',(_0x817d12,_0x235d41,_0x54310f)=>_0x588b18(_0x235d41,_0x54310f,_0x4d103e)),this['repository']['addRevision'](_0x4d103e),_0x4d103e;}['loadRevisionData'](_0x2c71ee){if(!_0x2c71ee||_0x2c71ee['diffData'])return Promise['resolve']();{const _0x51cf1e=this['editor']['config']['get']('collaboration.channelId');return this['adapter']['getRevision']({'channelId':_0x51cf1e,'revisionId':_0x2c71ee['id']})['then'](_0x5ab3df=>{_0x2c71ee['_update']({'diffData':_0x5ab3df['diffData']},!0x0);});}}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x45616b=>{for(const _0x4384ac of this['editor']['model']['document']['getRootNames']())_0x45616b['detachRoot'](_0x4384ac);});}['_sortAndFilterDiffChanges'](_0x2cfdcb){const _0x1fa09e=[],_0x411343=new Map();for(const _0x372801 of this['editor']['model']['document']['getRootNames']()){const _0x2ddbab=this['editor']['editing']['view']['getDomRoot'](_0x372801);if(!_0x2ddbab)continue;const _0x4bd446=_0x2ddbab['getClientRects']()['item'](0x0);_0x4bd446&&(_0x1fa09e['push'](_0x372801),_0x411343['set'](_0x372801,_0x4bd446));}return _0x1fa09e['sort']((_0x39eff8,_0x4205f8)=>{const _0x398307=_0x411343['get'](_0x39eff8),_0x36fbf8=_0x411343['get'](_0x4205f8);return _0x398307['y']-_0x36fbf8['y']||_0x398307['x']-_0x36fbf8['x'];}),(_0x2cfdcb=_0x2cfdcb['filter'](_0x536a7d=>_0x1fa09e['includes'](_0x536a7d['rootName'])))['sort']((_0x3d668e,_0x22f747)=>_0x1fa09e['indexOf'](_0x3d668e['rootName'])-_0x1fa09e['indexOf'](_0x22f747['rootName'])),_0x2cfdcb;}['_makeTape'](_0x593eb5){const _0x151ed2=Array['from'](_0x593eb5['markers'])['filter'](([_0xc462a6,_0x2aaebc])=>_0xc462a6['startsWith']('revision:')&&!_0x2aaebc['isCollapsed']),_0x32f8fa=Array['from'](this['editor']['model']['createRangeIn'](_0x593eb5)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x151ed2['length'])for(const _0x3172ed of _0x32f8fa){const [_0x8c0805,_0x58024b]=_0x151ed2[0x0],[,_0x26c956,_0x1f853a]=_0x8c0805['split'](':');if(_0x58024b['end']['isEqual'](_0x3172ed['nextPosition'])&&_0x151ed2['shift'](),(_0x3172ed['previousPosition']['isEqual'](_0x58024b['start'])||_0x3172ed['previousPosition']['isAfter'](_0x58024b['start']))&&('insertion'==_0x26c956?_0x3172ed['isAdded']={'userId':_0x1f853a}:'deletion'==_0x26c956&&(_0x3172ed['isRemoved']={'userId':_0x1f853a})),0x0==_0x151ed2['length'])break;}return _0x32f8fa;}['_refreshStartEndIndex'](_0x4ab988){const _0x2e0d93=new Map();for(let _0x10ba0f=0x0;_0x10ba0f<_0x4ab988['length'];_0x10ba0f++)'text'===_0x4ab988[_0x10ba0f]['type']?(_0x4ab988[_0x10ba0f]['item']['startIndex']=_0x10ba0f,_0x4ab988[_0x10ba0f]['item']['endIndex']=_0x10ba0f):('elementStart'===_0x4ab988[_0x10ba0f]['type']?_0x4ab988[_0x10ba0f]['item']['startIndex']=_0x10ba0f:'elementEnd'===_0x4ab988[_0x10ba0f]['type']&&(_0x4ab988[_0x10ba0f]['item']['endIndex']=_0x10ba0f),_0x2e0d93['set'](_0x4ab988[_0x10ba0f]['id'],_0x10ba0f));for(const _0x5a9732 of _0x2e0d93['values']())'elementStart'===_0x4ab988[_0x5a9732]['type']?_0x4ab988[_0x5a9732]['item']['endIndex']=_0x2e0d93['get'](_0x4ab988[_0x5a9732]['pairId']):'elementEnd'===_0x4ab988[_0x5a9732]['type']&&(_0x4ab988[_0x5a9732]['item']['startIndex']=_0x2e0d93['get'](_0x4ab988[_0x5a9732]['pairId']));}['_processTape'](_0x2c5b9a){for(let _0x31622d=0x0;_0x31622d<_0x2c5b9a['length'];_0x31622d++){if('elementStart'===_0x2c5b9a[_0x31622d]['type'])_0x2c5b9a[_0x31622d]['item']['startIndex']=_0x31622d;else{if('elementEnd'===_0x2c5b9a[_0x31622d]['type']){_0x2c5b9a[_0x31622d]['item']['endIndex']=_0x31622d;const _0x29d989=_0x2c5b9a[_0x31622d]['item']['startIndex'];_0x2c5b9a[_0x29d989]['pairId']=_0x2c5b9a[_0x31622d]['id'],_0x2c5b9a[_0x31622d]['pairId']=_0x2c5b9a[_0x29d989]['id'];}else _0x2c5b9a[_0x31622d]['item']['startIndex']=_0x31622d,_0x2c5b9a[_0x31622d]['item']['endIndex']=_0x31622d,_0x2c5b9a[_0x31622d]['pairId']=null;}_0x2c5b9a[_0x31622d]['markersStart']||(_0x2c5b9a[_0x31622d]['markersStart']=[],_0x2c5b9a[_0x31622d]['markersEnd']=[]);}}['_markInsertions'](_0x1f6957,_0x45d81d){const _0x3444b9=_0x1f6957['filter'](_0xea50c2=>!_0xea50c2['isAdded']);for(let _0x37c1da=0x0;_0x37c1da<_0x45d81d['length'];_0x37c1da++)_0x45d81d[_0x37c1da]['isAdded']&&(_0x3444b9[_0x37c1da]['isAdded']=_0x45d81d[_0x37c1da]['isAdded']);}['_makeModelFromViewString'](_0xfb3206){const _0x24b7f3=JSON['parse'](_0xfb3206),_0x18b4f1=this['editor']['editing']['view']['document'],_0x4828c5=new _0x471757(_0x18b4f1,_0x24b7f3['map'](_0x787371=>this['_getViewObj'](_0x787371)));return this['editor']['data']['toModel'](_0x4828c5);}['_getViewObj'](_0x18122e){const _0x5c0aad=this['editor']['editing']['view']['document'];if('string'==typeof _0x18122e)return new _0x7c92df(_0x5c0aad,_0x18122e);{const _0x3cf192=_0x18122e['children']['map'](_0x4b3182=>this['_getViewObj'](_0x4b3182));return new(Z[_0x18122e['type']]||_0x3b6ead)(_0x5c0aad,_0x18122e['name'],_0x18122e['attributes'],_0x3cf192);}}['_getDiff'](_0x28967b,_0x2d8e43=null){const _0x3e220f=this['repository']['getRevision'](_0x28967b),_0x4d51f3=_0x2d8e43?this['repository']['getRevision'](_0x2d8e43):null,_0x34f56c=this['_getRevisionsRange'](_0x3e220f,_0x4d51f3),_0x34f3e0=_0x34f56c[_0x34f56c['length']-0x1],_0x549eba=new Map(),_0xb0c0af={'model':{},'attributes':{},'changes':[]},_0x20ac42=new Set(),_0x47700c=new Map();for(let _0x9e3314=_0x34f56c['length']-0x1;_0x9e3314>=0x0;_0x9e3314--){const _0x23df2e=_0x34f56c[_0x9e3314];for(const _0x408b28 of Object['keys'](_0x23df2e['diffData']))if(_0x23df2e['diffData'][_0x408b28]['attachChange']){const _0x507eb2=_0x23df2e['diffData'][_0x408b28]['attachChange'];_0x507eb2['isAttached']?(_0x20ac42['add'](_0x408b28),_0x47700c['has'](_0x408b28)&&_0x47700c['get'](_0x408b28)['userId']==_0x507eb2['userId']?_0x47700c['delete'](_0x408b28):_0x47700c['set'](_0x408b28,_0x507eb2)):_0x47700c['has'](_0x408b28)?(_0x20ac42['delete'](_0x408b28),_0x47700c['delete'](_0x408b28)):(_0x20ac42['add'](_0x408b28),_0x47700c['set'](_0x408b28,_0x507eb2));}else _0x20ac42['add'](_0x408b28);}for(const _0x176af3 of _0x20ac42){const _0x4f0d55=_0x47700c['has'](_0x176af3)&&!_0x47700c['get'](_0x176af3)['isAttached'];let _0x34d8d2=_0x4f0d55?_0x34f56c['length']-0x1:0x0;const _0x3b9a3b=_0x4f0d55?-0x1:0x1;for(;_0x34f56c[_0x34d8d2];){const _0x170532=_0x34f56c[_0x34d8d2];if(_0x170532['diffData'][_0x176af3]){const _0x51244f=_0x4f0d55?_0x170532['diffData'][_0x176af3]['attributesBefore']:_0x170532['diffData'][_0x176af3]['attributesAfter'];_0xb0c0af['attributes'][_0x176af3]=_0x51244f?_0x3c49e8(_0x51244f):{};break;}_0x34d8d2+=_0x3b9a3b;}}for(const _0x1a38e1 of _0x34f56c){_0x1a38e1['model']={};for(const _0x5bb3bd of _0x1a38e1['authors'])_0x549eba['set'](_0x5bb3bd['id'],_0x5bb3bd);for(const _0x539d36 of _0x20ac42){const _0x499bfb=_0x1a38e1['diffData'][_0x539d36]?_0x1a38e1['diffData'][_0x539d36]['insertions']:'[]',_0x189fc4=_0x1a38e1['diffData'][_0x539d36]?_0x1a38e1['diffData'][_0x539d36]['deletions']:'[]';_0x1a38e1['model'][_0x539d36]={'insertions':this['_makeModelFromViewString'](_0x499bfb),'deletions':this['_makeModelFromViewString'](_0x189fc4)};}}for(const _0x4354cd of _0x20ac42){let _0x4431ae=null,_0x27e9de=0x0;const _0x4b3cc2=new Map(Array['from'](_0x3e220f['model'][_0x4354cd]['insertions']['markers'])['filter'](([_0x4dd37b])=>!_0x4dd37b['startsWith']('revision:')));let _0x40da63=0x0;for(const _0x8fd540 of _0x34f56c){const _0x410788=this['_makeTape'](_0x8fd540['model'][_0x4354cd]['insertions']);_0x8fd540==_0x3e220f?(_0x4431ae=_0x410788,_0x27e9de=_0x4431ae['length'],_0x4431ae['forEach'](_0x3d6a8e=>{_0x3d6a8e['id']=_0x40da63++;}),this['_processTape'](_0x4431ae)):this['_markInsertions'](_0x4431ae,_0x410788);const _0x219008=_0x4431ae['filter'](_0x487677=>!_0x487677['isAdded'])['map'](_0x2646eb=>_0x2646eb['id']);let _0x54dcc2=0x0;const _0x5385c4=this['_makeTape'](_0x8fd540['model'][_0x4354cd]['deletions']);_0x5385c4['forEach'](_0x5e3a04=>{_0x5e3a04['isRemoved']?_0x5e3a04['id']=_0x27e9de++:_0x5e3a04['id']=_0x219008[_0x54dcc2++];}),this['_processTape'](_0x5385c4),this['_setDistance'](_0x4431ae,'isAdded'),this['_setDistance'](_0x5385c4,'isRemoved'),_0x8fd540==_0x3e220f&&this['_markMarkers'](_0x4431ae,_0x4b3cc2),_0x4431ae=this['_joinTapes'](_0x4431ae,_0x5385c4),this['_refreshStartEndIndex'](_0x4431ae),this['_setDistance'](_0x4431ae,'isRemoved');}_0x4431ae=_0x4431ae['filter'](_0x218531=>!(_0x218531['isAdded']&&_0x218531['isRemoved']));const _0x4d4943=new Map(_0x34f3e0['model'][_0x4354cd]['deletions']['markers']),_0x22ea45=new Set(_0x4b3cc2['keys']());for(const _0x387655 of _0x4d4943['keys']())_0x22ea45['delete'](_0x387655);this['_markSuggestions'](_0x4431ae,_0x22ea45),this['_fixObsoleteTags'](_0x4431ae),_0x4431ae=this['_removeMissingPairs'](_0x4431ae),_0x4431ae=this['_markMismatchedRemovedTags'](_0x4431ae),_0x4431ae=this['_removeUnsupportedChanges'](_0x4431ae);const {root:_0x43c865,changes:_0x54d7e7}=this['_makeModelFromTape'](_0x4431ae,_0x549eba,_0x4354cd);_0xb0c0af['model'][_0x4354cd]=_0x43c865;const _0xa92eaf=_0x47700c['get'](_0x4354cd);if(_0xa92eaf){const _0x5d51f2=_0x549eba['get'](_0xa92eaf['userId']),_0x4211b5=new r({'author':_0x5d51f2,'type':_0xa92eaf['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x4354cd});_0x54d7e7['unshift'](_0x4211b5),_0xb0c0af['attributes'][_0x4354cd]['revisionHistoryAttachChange']=_0x4211b5['id'];}_0xb0c0af['changes']=_0xb0c0af['changes']['concat'](_0x54d7e7);}return _0xb0c0af;}['_markMarkers'](_0x5d3d57,_0x44d165){for(let _0x4a24bb=0x0;_0x4a24bb<_0x5d3d57['length'];_0x4a24bb++)for(const [_0x24ae9e,_0x47caf9]of _0x44d165)_0x47caf9['start']['isEqual'](_0x5d3d57[_0x4a24bb]['previousPosition'])&&_0x5d3d57[_0x4a24bb]['markersStart']['push'](_0x24ae9e),_0x47caf9['end']['isEqual'](_0x5d3d57[_0x4a24bb]['nextPosition'])&&_0x5d3d57[_0x4a24bb]['markersEnd']['push'](_0x24ae9e);}['_joinTapes'](_0x593074,_0x5f2031){let _0x5a85f1=[],_0x4ab3f0=0x0,_0x349689=0x0;for(;_0x4ab3f0<_0x593074['length']||_0x349689<_0x5f2031['length'];){const _0x55cc36=_0x593074[_0x4ab3f0]||{},_0x40ae1c=_0x5f2031[_0x349689]||{};if(_0x55cc36['id']==_0x40ae1c['id'])_0x4ab3f0++,_0x349689++,_0x5a85f1['push'](_0x55cc36);else{if(_0x40ae1c['isRemoved']&&_0x55cc36['isAdded']){const {commonTape:_0x5f95af,iEnd:_0x13d8ee,jEnd:_0x20f4f2}=this['_threeWayMerge'](_0x593074,_0x4ab3f0,_0x5f2031,_0x349689);_0x5a85f1=_0x5a85f1['concat'](_0x5f95af),_0x4ab3f0=_0x13d8ee,_0x349689=_0x20f4f2;}else _0x40ae1c['isRemoved']?(_0x349689++,_0x5a85f1['push'](_0x40ae1c)):(_0x4ab3f0++,_0x5a85f1['push'](_0x55cc36));}}return _0x5a85f1;}['_markSuggestions'](_0x2d2489,_0x55ab8f){const _0x386168=[];for(let _0x510ca4=0x0;_0x510ca4<_0x2d2489['length'];_0x510ca4++){for(let _0x36708b=0x0;_0x36708b<_0x2d2489[_0x510ca4]['markersStart']['length'];_0x36708b++){const _0x28813c=_0x2d2489[_0x510ca4]['markersStart'][_0x36708b];if(!_0x55ab8f['has'](_0x28813c))continue;const {group:_0x1b8e3d,type:_0x5b99fd,authorId:_0x284884}=_0x2be2f0(_0x28813c);'revision-suggestion'!=_0x1b8e3d||'insertion'!=_0x5b99fd&&'deletion'!=_0x5b99fd||(_0x386168['unshift']({'type':_0x5b99fd,'name':_0x28813c,'userId':_0x284884}),_0x2d2489[_0x510ca4]['markersStart']['splice'](_0x36708b,0x1),_0x36708b--);}_0x5dcff4(_0x2d2489[_0x510ca4]);for(let _0x10ad90=0x0;_0x10ad90<_0x2d2489[_0x510ca4]['markersEnd']['length'];_0x10ad90++){const _0x475fb6=_0x2d2489[_0x510ca4]['markersEnd'][_0x10ad90];if(!_0x55ab8f['has'](_0x475fb6))continue;const {group:_0x3a3189,type:_0x50aa3b}=_0x2be2f0(_0x475fb6);if('revision-suggestion'!=_0x3a3189||'insertion'!=_0x50aa3b&&'deletion'!=_0x50aa3b)continue;_0x2d2489[_0x510ca4]['markersEnd']['splice'](_0x10ad90,0x1),_0x10ad90--;const _0x222185=_0x386168['findIndex'](_0x40b504=>_0x40b504['name']==_0x475fb6);_0x222185>-0x1&&_0x386168['splice'](_0x222185,0x1);}}function _0x2be2f0(_0x5f5b14){const _0x42cbcb=_0x5f5b14['split'](':');return{'group':_0x42cbcb[0x0],'type':_0x42cbcb[0x1],'subType':_0x42cbcb['length']>=0x5?_0x42cbcb[0x2]:null,'id':_0x42cbcb['length']<0x5?_0x42cbcb[0x2]:_0x42cbcb[0x3],'authorId':_0x42cbcb['length']<0x5?_0x42cbcb[0x3]:_0x42cbcb[0x4],'markerCount':0x6==_0x42cbcb['length']?_0x42cbcb[0x5]:null};}function _0x5dcff4(_0x2b16be){for(let _0x33c691=0x0;_0x33c691<_0x386168['length'];_0x33c691++){if(_0x2b16be['isAdded']&&'insertion'==_0x386168[_0x33c691]['type'])return _0x2b16be['isAddSuggestion']=_0x386168[_0x33c691],void delete _0x2b16be['isAdded'];if(!_0x2b16be['isAdded']&&!_0x2b16be['isRemoved']&&'deletion'==_0x386168[_0x33c691]['type'])return void(_0x2b16be['isRemoveSuggestion']=_0x386168[_0x33c691]);}}}['_setDistance'](_0x348e82,_0x305d78){let _0x31d2fd=0x0,_0xa09f30=!0x1;const _0x554073=new Map();for(const _0x432de9 of _0x348e82)_0x432de9[_0x305d78]?_0xa09f30&&(_0x31d2fd++,_0xa09f30=!0x1):(_0x31d2fd++,_0xa09f30=!0x0),_0x554073['set'](_0x432de9['id'],_0x31d2fd);for(let _0x4ca7cf=0x0;_0x4ca7cf<_0x348e82['length'];_0x4ca7cf++){if('isRemoved'==_0x305d78&&_0x348e82[_0x4ca7cf]['isAdded']||'isAdded'==_0x305d78&&_0x348e82[_0x4ca7cf]['isRemoved'])continue;if('text'==_0x348e82[_0x4ca7cf]['type']){_0x348e82[_0x4ca7cf]['distance']=0x0;continue;}const _0x358014=_0x554073['get'](_0x348e82[_0x4ca7cf]['pairId']),_0x5d06b8=_0x554073['get'](_0x348e82[_0x4ca7cf]['id']);_0x348e82[_0x4ca7cf]['distance']=_0x358014-_0x5d06b8;}}['_getRevisionsRange'](_0x47b35c,_0x563905,_0x5a57ab=!0x1){const _0x4f2701=[];let _0x1406dc=this['repository']['getIndex'](_0x47b35c),_0x8bc7bc=this['repository']['getIndex'](_0x563905);for(-0x1==_0x8bc7bc&&(_0x8bc7bc=this['repository']['_revisions']['length'],_0x5a57ab=!0x1);_0x1406dc<_0x8bc7bc;)_0x4f2701['push'](this['repository']['getRevision'](_0x1406dc)),_0x1406dc++;return _0x5a57ab&&_0x4f2701['push'](this['repository']['getRevision'](_0x1406dc)),_0x4f2701;}['_threeWayMerge'](_0xe92035,_0x3473e8,_0x26d933,_0x4e4f63){const _0x476aaf=this['editor']['model']['schema'];let _0x15b568=_0x3473e8;for(;_0xe92035[_0x15b568]&&_0xe92035[_0x15b568]['isAdded'];)_0x15b568++;let _0x4747bd=_0x4e4f63;for(;_0x26d933[_0x4747bd]&&_0x26d933[_0x4747bd]['isRemoved'];)_0x4747bd++;_0x56b982(_0xe92035,_0x3473e8,_0x15b568),_0x56b982(_0x26d933,_0x4e4f63,_0x4747bd);const _0x4acf16=_0x26d933['slice'](_0x4e4f63,_0x4747bd)['concat'](_0xe92035['slice'](_0x3473e8,_0x15b568));return _0x4acf16['sort']((_0x51a83b,_0x59fccf)=>_0x51a83b['side']!=_0x59fccf['side']?_0x51a83b['side']-_0x59fccf['side']:_0x51a83b['level']!=_0x59fccf['level']?_0x51a83b['level']-_0x59fccf['level']:_0x51a83b['distance']!=_0x59fccf['distance']?_0x59fccf['distance']-_0x51a83b['distance']:!!_0x51a83b['isAdded']!=!!_0x59fccf['isAdded']?-0x1==_0x51a83b['side']||0x0==_0x51a83b['side']?_0x51a83b['isAdded']?-0x1:0x1:_0x51a83b['isAdded']?0x1:-0x1:_0x51a83b['index']-_0x59fccf['index']),{'commonTape':_0x4acf16,'iEnd':_0x15b568,'jEnd':_0x4747bd};function _0x56b982(_0x44c585,_0x1dce12,_0x4acf3e){let _0x4cfb49=-0x1,_0x504653=Number['POSITIVE_INFINITY'],_0x488310=!0x0;for(let _0x546ea4=_0x1dce12;_0x546ea4<_0x4acf3e;_0x546ea4++)if(_0x476aaf['isInline'](_0x44c585[_0x546ea4]['item'])||(_0x488310=!0x1),_0x44c585[_0x546ea4]['item']['startIndex']<_0x1dce12&&(_0x4cfb49=_0x546ea4),_0x44c585[_0x546ea4]['item']['endIndex']>=_0x4acf3e){_0x504653=_0x546ea4;break;}_0x488310&&(_0x4cfb49=_0x4acf3e-0x1);for(let _0x461627=_0x1dce12;_0x461627<_0x4acf3e;_0x461627++)_0x44c585[_0x461627]['side']=_0x461627<=_0x4cfb49?-0x1:_0x461627<_0x504653?0x0:0x1,_0x44c585[_0x461627]['index']=_0x461627;let _0x3e449c=0x0;for(let _0x11258e=_0x1dce12;_0x11258e<=_0x4cfb49;_0x11258e++)0x0==_0x44c585[_0x11258e]['distance']?_0x44c585[_0x11258e]['level']=_0x3e449c:(_0x3e449c++,_0x44c585[_0x11258e]['level']=_0x3e449c,_0x3e449c++);for(let _0x29c844=_0x1dce12;_0x29c844<_0x4acf3e;_0x29c844++)0x0==_0x44c585[_0x29c844]['side']&&(_0x44c585[_0x29c844]['level']=_0x3e449c);_0x3e449c=0x0;for(let _0x54e85a=_0x4acf3e-0x1;_0x54e85a>=_0x504653;_0x54e85a--)0x0==_0x44c585[_0x54e85a]['distance']?_0x44c585[_0x54e85a]['level']=_0x3e449c:(_0x3e449c--,_0x44c585[_0x54e85a]['level']=_0x3e449c,_0x3e449c--);}}['_fixObsoleteTags'](_0x5cbe1c){const _0x13832f=new Map(),_0x26a2fd=this['editor']['model']['schema'];for(let _0x1b9d44=0x1;_0x1b9d44<_0x5cbe1c['length'];_0x1b9d44++){let _0x367053,_0x42f9af,_0x5e6e46;const _0x31b3b9=_0x5cbe1c[_0x1b9d44],_0x205283=_0x5cbe1c[_0x1b9d44-0x1];if('text'==_0x31b3b9['type'])continue;if(_0x31b3b9['type']!=_0x205283['type'])continue;if(!_0x26a2fd['isBlock'](_0x205283['item'])||_0x26a2fd['isLimit'](_0x205283['item']))continue;if(!_0x26a2fd['isBlock'](_0x31b3b9['item'])||_0x26a2fd['isLimit'](_0x31b3b9['item']))continue;if((_0x5cbe1c[_0x1b9d44]['isAdded']||_0x5cbe1c[_0x1b9d44]['isAddSuggestion'])&&_0x5cbe1c[_0x1b9d44-0x1]['isRemoved'])_0x367053=_0x5cbe1c[_0x1b9d44],_0x42f9af=_0x5cbe1c[_0x1b9d44-0x1],_0x5e6e46=_0x1b9d44-0x1;else{if(!_0x5cbe1c[_0x1b9d44]['isRemoved']||!_0x5cbe1c[_0x1b9d44-0x1]['isAdded']&&!_0x5cbe1c[_0x1b9d44-0x1]['isAddSuggestion'])continue;_0x367053=_0x5cbe1c[_0x1b9d44-0x1],_0x42f9af=_0x5cbe1c[_0x1b9d44],_0x5e6e46=_0x1b9d44;}const _0x57ac48=_0x367053['level']==_0x42f9af['level'],_0x80710b=Math['abs'](_0x367053['level'])<Math['abs'](_0x42f9af['level'])&&0x0==_0x42f9af['distance'];(_0x57ac48||_0x80710b)&&(_0x13832f['set'](_0x42f9af['id'],_0x367053['id']),_0x5cbe1c['splice'](_0x5e6e46,0x1),_0x1b9d44--,_0x367053['isAdded']=!0x1);}for(let _0x4d7243=0x0;_0x4d7243<_0x5cbe1c['length'];_0x4d7243++)_0x13832f['has'](_0x5cbe1c[_0x4d7243]['pairId'])&&(_0x5cbe1c[_0x4d7243]['pairId']=_0x13832f['get'](_0x5cbe1c[_0x4d7243]['pairId']));}['_removeMissingPairs'](_0x5c5185){const _0x3b31d7=new Set(_0x5c5185['map'](_0x43ba8f=>_0x43ba8f['id']));for(let _0x552011=0x0;_0x552011<_0x5c5185['length'];_0x552011++)_0x3b31d7['has'](_0x5c5185[_0x552011]['pairId'])||0x0==_0x5c5185[_0x552011]['distance']||(_0x5c5185[_0x552011]['isIncorrect']=!0x0);return _0x5c5185['filter'](_0x1a660a=>!_0x1a660a['isIncorrect']);}['_markMismatchedRemovedTags'](_0x335e31){const _0x5eccf1=new Set();for(let _0x234e46=0x0;_0x234e46<_0x335e31['length'];_0x234e46++){if(_0x5eccf1['has'](_0x335e31[_0x234e46]['id'])&&_0x335e31[_0x234e46]['isRemoved']&&(_0x335e31[_0x234e46]['isIncorrect']=!0x0),_0x335e31[_0x234e46]['isIncorrect'])continue;if(0x0==_0x335e31[_0x234e46]['distance'])continue;if('elementStart'!=_0x335e31[_0x234e46]['type'])continue;if(null==_0x335e31[_0x234e46]['pairId'])continue;let _0x38961c=_0x234e46+0x1,_0x166c45=0x0;for(;_0x335e31[_0x38961c]['id']!=_0x335e31[_0x234e46]['pairId'];)'elementStart'==_0x335e31[_0x38961c]['type']?_0x166c45++:'elementEnd'==_0x335e31[_0x38961c]['type']&&_0x166c45--,_0x38961c++;if(0x0!=_0x166c45){if(_0x335e31[_0x234e46]['isRemoved'])_0x335e31[_0x234e46]['isIncorrect']=!0x0;else{for(;_0x38961c!=_0x234e46;)_0x335e31[_0x38961c]['isRemoved']&&0x0!=_0x335e31[_0x38961c]['distance']&&(_0x335e31[_0x38961c]['isIncorrect']=!0x0,_0x5eccf1['add'](_0x335e31[_0x38961c]['pairId'])),_0x38961c--;}}}return _0x335e31['filter'](_0x44bb85=>!_0x44bb85['isIncorrect']);}['_removeUnsupportedChanges'](_0x16c6b9){const _0x2e47c6=this['editor']['model']['schema'];for(let _0x5aea93=0x0;_0x5aea93<_0x16c6b9['length'];_0x5aea93++){if(!(_0x16c6b9[_0x5aea93]['isAdded']||_0x16c6b9[_0x5aea93]['isAddSuggestion']||_0x16c6b9[_0x5aea93]['isRemoved']||_0x16c6b9[_0x5aea93]['isRemoveSuggestion']))continue;if(0x0==_0x16c6b9[_0x5aea93]['distance'])continue;const _0x36d0b7=_0x16c6b9[_0x5aea93]['item'];_0x2e47c6['isBlock'](_0x36d0b7)||_0x2e47c6['isLimit'](_0x36d0b7)||(_0x16c6b9[_0x5aea93]['isAdded']&&delete _0x16c6b9[_0x5aea93]['isAdded'],_0x16c6b9[_0x5aea93]['isAddSuggestion']&&delete _0x16c6b9[_0x5aea93]['isAddSuggestion'],_0x16c6b9[_0x5aea93]['isRemoveSuggestion']&&delete _0x16c6b9[_0x5aea93]['isRemoveSuggestion'],_0x16c6b9[_0x5aea93]['isRemoved']&&(_0x16c6b9[_0x5aea93]['isIncorrect']=!0x0));}return _0x16c6b9['filter'](_0xdeb262=>!_0xdeb262['isIncorrect']);}['_makeModelFromTape'](_0x2e704a,_0x3bb6d7,_0x53c3a6){const _0x2a41c5=new wt(),_0x390f19=[],_0x495a45=new Map(),_0x19f0dd=this['editor']['model'],_0x5e4136=_0x19f0dd['schema'],_0x40d167=[_0x2a41c5],_0xa95118={},_0x4d592b={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x38ddf7=null;const _0x2c839a=[0x0];for(let _0x585350=0x0;_0x585350<_0x2e704a['length'];_0x585350++)if('elementStart'===_0x2e704a[_0x585350]['type']){_0x2e704a[_0x585350]['previousPosition']=_0x19f0dd['createPositionFromPath'](_0x2a41c5,_0x2c839a);const _0x3fb901=new ft(_0x2e704a[_0x585350]['item']['name'],_0x2e704a[_0x585350]['item']['getAttributes']());_0x40d167[0x0]['_appendChild'](_0x3fb901),_0x2c839a['push'](0x0),_0x40d167['unshift'](_0x3fb901),_0x2e704a[_0x585350]['nextPosition']=_0x19f0dd['createPositionFromPath'](_0x2a41c5,_0x2c839a);}else'elementEnd'===_0x2e704a[_0x585350]['type']?(_0x40d167['shift'](),_0x2e704a[_0x585350]['previousPosition']=_0x19f0dd['createPositionFromPath'](_0x2a41c5,_0x2c839a),_0x2c839a['pop'](),_0x2c839a[_0x2c839a['length']-0x1]++,_0x2e704a[_0x585350]['nextPosition']=_0x19f0dd['createPositionFromPath'](_0x2a41c5,_0x2c839a)):(_0x2e704a[_0x585350]['previousPosition']=_0x19f0dd['createPositionFromPath'](_0x2a41c5,_0x2c839a),_0x38ddf7?_0x38ddf7['_data']+=_0x2e704a[_0x585350]['item']['data']:_0x38ddf7=new _t(_0x2e704a[_0x585350]['item']['data'],_0x2e704a[_0x585350]['item']['getAttributes']()),_0x2e704a[_0x585350+0x1]&&'text'===_0x2e704a[_0x585350+0x1]['type']&&_0x4852e3(_0x38ddf7,_0x2e704a[_0x585350+0x1]['item'])||(_0x40d167[0x0]['_appendChild'](_0x38ddf7),_0x38ddf7=null),_0x2c839a[_0x2c839a['length']-0x1]+=_0x2e704a[_0x585350]['item']['offsetSize'],_0x2e704a[_0x585350]['nextPosition']=_0x19f0dd['createPositionFromPath'](_0x2a41c5,_0x2c839a));for(let _0x1efc74=0x0;_0x1efc74<_0x2e704a['length'];_0x1efc74++){const _0x27e12a=_0x2e704a[_0x1efc74]['previousPosition'],_0x289ffe=_0x2e704a[_0x1efc74]['nextPosition'];for(const _0x439a1c of _0x2e704a[_0x1efc74]['markersStart'])_0x495a45['set'](_0x439a1c,{'start':_0x27e12a,'end':null});_0x119bad('isRemoveSuggestion',_0x1efc74,_0x27e12a,_0x289ffe),_0x119bad('isAddSuggestion',_0x1efc74,_0x27e12a,_0x289ffe),_0x119bad('isRemoved',_0x1efc74,_0x27e12a,_0x289ffe),_0x119bad('isAdded',_0x1efc74,_0x27e12a,_0x289ffe);for(const _0xd46b65 of _0x2e704a[_0x1efc74]['markersEnd']){_0x495a45['get'](_0xd46b65)['end']=_0x289ffe;}}for(const [_0x5a5118,_0x25a40f]of _0x495a45){const _0x3f5553=this['editor']['model']['createRange'](_0x25a40f['start'],_0x25a40f['end']);_0x2a41c5['markers']['set'](_0x5a5118,_0x3f5553);}return _0x390f19['sort']((_0x5669df,_0x4833a2)=>{const _0x211059=_0x2a41c5['markers']['get']('revision:'+_0x5669df['id']),_0x381e6f=_0x2a41c5['markers']['get']('revision:'+_0x4833a2['id']);return _0x211059['start']['isBefore'](_0x381e6f['start'])?-0x1:_0x211059['start']['isAfter'](_0x381e6f['start'])?0x1:_0x211059['end']['isBefore'](_0x381e6f['end'])?-0x1:_0x211059['end']['isAfter'](_0x381e6f['end'])?0x1:'add'===_0x5669df['type']?-0x1:0x1;}),{'root':_0x2a41c5,'changes':_0x390f19};function _0x119bad(_0xdf0d11,_0x10215d,_0x504a7a,_0x46cf5f){const _0x5622b1=!!_0x2e704a[_0x10215d][_0xdf0d11],_0x3648bc=_0x5622b1?_0x2e704a[_0x10215d][_0xdf0d11]['userId']:null,_0x48cfd=_0x10215d===_0x2e704a['length']-0x1,_0x19637d=_0x4d592b[_0xdf0d11][0x0],_0x514fbe=_0x5e4136['isObject'](_0x2e704a[_0x10215d]['item']);!_0xa95118[_0xdf0d11]&&_0x5622b1?_0xa95118[_0xdf0d11]={'start':_0x504a7a,'tapeItem':_0x2e704a[_0x10215d],'userId':_0x3648bc,'type':_0xdf0d11}:_0xa95118[_0xdf0d11]&&!_0x5622b1?(_0xa95118[_0xdf0d11]['end']=_0x504a7a,_0x52387f(_0xa95118[_0xdf0d11]),_0xa95118[_0xdf0d11]=null):_0xa95118[_0xdf0d11]&&_0x5622b1&&_0xa95118[_0xdf0d11]['userId']!==_0x3648bc&&(_0xa95118[_0xdf0d11]['end']=_0x504a7a,_0x19637d&&_0x19637d['userId']===_0xa95118[_0xdf0d11]['userId']||_0x52387f(_0xa95118[_0xdf0d11]),_0xa95118[_0xdf0d11]={'start':_0x504a7a,'tapeItem':_0x2e704a[_0x10215d],'userId':_0x3648bc,'type':_0xdf0d11}),_0xa95118[_0xdf0d11]&&_0x514fbe&&('elementStart'!==_0x2e704a[_0x10215d]['type']||_0x19637d&&_0x19637d['userId']===_0x3648bc||_0x4d592b[_0xdf0d11]['unshift']({'userId':_0x3648bc,'object':_0x2e704a[_0x10215d]['item'],'change':_0xa95118[_0xdf0d11]}),'elementEnd'===_0x2e704a[_0x10215d]['type']&&_0x19637d&&_0x19637d['object']===_0x2e704a[_0x10215d]['item']&&(_0x4d592b[_0xdf0d11]['shift'](),_0xa95118[_0xdf0d11]=_0x19637d['change'])),_0xa95118[_0xdf0d11]&&_0x48cfd&&(_0xa95118[_0xdf0d11]['end']=_0x46cf5f,_0x52387f(_0xa95118[_0xdf0d11]),_0xa95118[_0xdf0d11]=null);}function _0x52387f({start:_0x1cd0bc,end:_0x47e381,tapeItem:_0x5dbfec,userId:_0x17f955,type:_0x454e56}){const _0x1257a8=_0x5dbfec['item'],_0x50468b=_0x19f0dd['schema']['isBlock'](_0x1257a8)&&!_0x19f0dd['schema']['isLimit'](_0x1257a8),_0x41c607=_0x1cd0bc['nodeAfter']==_0x47e381['parent']&&_0x47e381['isAtStart'];if(_0x50468b&&_0x41c607)return;const _0x2e15ae=_0x19f0dd['createRange'](_0x1cd0bc,_0x47e381),_0x2747f4=_0x3bb6d7['get'](_0x17f955),_0x56fb42=new r({'author':_0x2747f4,'type':'isAdded'==_0x454e56||'isAddSuggestion'==_0x454e56?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x454e56||'isRemoveSuggestion'==_0x454e56},'createdAt':new Date(),'rootName':_0x53c3a6});_0x390f19['push'](_0x56fb42),_0x2a41c5['markers']['set']('revision:'+_0x56fb42['id'],_0x2e15ae);}function _0x4852e3(_0x12603e,_0x5dc795){const _0x3c1c0b=_0x12603e['getAttributes'](),_0x2f47ff=_0x5dc795['getAttributes']();for(const _0x39c65e of _0x3c1c0b){if(_0x39c65e[0x1]!==_0x5dc795['getAttribute'](_0x39c65e[0x0]))return!0x1;_0x2f47ff['next']();}return _0x2f47ff['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x5b027b=>{const _0x2b4fe7=_0x5b027b['markerName']['split'](':')[0x1],_0x23d58f=this['_getChangeFromId'](_0x2b4fe7);if(!_0x23d58f)return null;const _0x1c0f20='add'==_0x23d58f['type']?'insertion':'deletion',_0x4076a6=['ck-suggestion-marker','ck-suggestion-marker-'+_0x1c0f20];return _0x23d58f['data']['isSuggestion']&&_0x4076a6['push']('ck-suggestion-marker-'+_0x1c0f20+'-new'),this['activeChange']==_0x23d58f&&_0x4076a6['push']('ck-suggestion-marker--active'),{'classes':_0x4076a6,'attributes':{'data-change-id':_0x2b4fe7}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x4a6035=>{_0x4a6035['on']('element:pre',(_0xac7a83,_0x595e50,_0x29d2fe)=>{const _0x222cf4=_0x595e50['viewItem']['getChild'](0x0);if(!_0x222cf4||!_0x222cf4['is']('element','code'))return;if(!_0x29d2fe['consumable']['consume'](_0x222cf4,{'attributes':['vid_start','vid_end']}))return;const _0x41f690=_0x595e50['modelRange']['start']['nodeAfter'];_0x29d2fe['writer']['setAttribute']('vid_start',_0x222cf4['getAttribute']('vid_start'),_0x41f690),_0x29d2fe['writer']['setAttribute']('vid_end',_0x222cf4['getAttribute']('vid_end'),_0x41f690);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x5c3b72=>{_0x5c3b72['on']('element',(_0x5a400e,_0x1aa5a7,_0x3a153e)=>{if(!_0x3a153e['consumable']['consume'](_0x1aa5a7['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x1aa5a7['modelRange']['isCollapsed'])return;const _0x50b904=_0x1aa5a7['modelRange']['start']['nodeAfter'];_0x50b904['hasAttribute']('vid_start')||_0x50b904['hasAttribute']('vid')||(_0x3a153e['writer']['setAttribute']('vid_start',_0x1aa5a7['viewItem']['getAttribute']('vid_start'),_0x50b904),_0x3a153e['writer']['setAttribute']('vid_end',_0x1aa5a7['viewItem']['getAttribute']('vid_end'),_0x50b904));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x5e29e5=>_0x5e29e5['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x230bfc,[,_0x5175ee])=>{['vid_start','vid_end','vid']['includes'](_0x5175ee)&&(_0x230bfc['return']=!0x0,_0x230bfc['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x4a5233=>{_0x4a5233['on']('attribute:vid',(_0x2a94ef,_0x473f8f,_0x426a64)=>{if('\x20'!=_0x473f8f['item']['data']||_0x473f8f['item']['parent']['maxOffset']>0x1)return;if(!_0x426a64['consumable']['consume'](_0x473f8f['item'],_0x2a94ef['name']))return;const _0x421d20=_0x426a64['writer'],_0x1cc43a=_0x426a64['mapper']['toViewRange'](_0x473f8f['range']);_0x421d20['wrap'](_0x1cc43a,_0x421d20['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x5d9608){const _0x44d3ee=_0x5d9608['plugins']['get']('RevisionViewer');return(_0x578697,_0x22f99a,_0x4f1c31)=>{const _0x6d1d48=_0x22f99a['markerName']['split'](':')[0x1],_0x40e217=_0x44d3ee['_getChangeFromId'](_0x6d1d48);if(!_0x40e217)return null;const _0x1108bb='add'==_0x40e217['type']?'split':'merge';if(!_0x4f1c31['consumable']['test'](_0x22f99a['markerRange'],_0x578697['name']))return;const _0x1aa0b4=_0x22f99a['markerRange']['getWalker'](),_0x313b0f=_0x22f99a['markerRange']['start'],_0x4cc3f0=_0x5d9608['model']['schema'];let _0x164160=null,_0x4040c0=null,_0x4a1b9e=!0x1,_0x38a1f7=!0x1;for(const _0x35584f of _0x1aa0b4){const _0xfdc684=_0x35584f['item'];_0x4a1b9e=_0x4a1b9e||_0x4cc3f0['isContent'](_0xfdc684);const _0xdad1ab=_0x4f1c31['mapper']['toViewElement'](_0xfdc684);if(_0xdad1ab&&_0xdad1ab['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x35584f['type']&&(_0x4cc3f0['isBlock'](_0xfdc684)&&!_0x4cc3f0['isLimit'](_0xfdc684)&&(_0xfdc684['nextSibling']||_0x313b0f['isAtEnd']?_0x164160&&_0x164160['parent']==_0xfdc684||(_0x164160=_0xfdc684,_0x24acc8(_0x35584f['previousPosition']),_0x38a1f7=!0x0):_0x4040c0=_0x4040c0||_0x35584f['previousPosition']));}function _0x24acc8(_0x2b49fe){const _0x93e53c=_0x4f1c31['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x1108bb}),_0x36ccd0=_0x4f1c31['mapper']['toViewPosition'](_0x2b49fe);_0x40e217['data']['isSuggestion']&&_0x4f1c31['writer']['addClass']('ck-suggestion-marker-'+_0x1108bb+'-new',_0x93e53c),_0x44d3ee['activeChange']==_0x40e217&&_0x4f1c31['writer']['addClass']('ck-suggestion-marker--active',_0x93e53c),_0x4f1c31['writer']['insert'](_0x36ccd0,_0x93e53c),_0x4f1c31['mapper']['bindElementToMarker'](_0x93e53c,_0x22f99a['markerName']);}_0x4a1b9e||_0x38a1f7||!_0x4040c0||_0x24acc8(_0x4040c0);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x50273c,_0x33744a,_0x2af188)=>{const _0x3d9fc1=_0x2af188['mapper']['markerNameToElements'](_0x33744a['markerName']);if(_0x3d9fc1){for(const _0x22e0cd of _0x3d9fc1)(_0x22e0cd['hasClass']('ck-suggestion-marker-split')||_0x22e0cd['hasClass']('ck-suggestion-marker-merge'))&&(_0x2af188['mapper']['unbindElementFromMarkerName'](_0x22e0cd,_0x33744a['markerName']),_0x2af188['writer']['remove'](_0x22e0cd));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x4fb5c3,_0x5b12a9,_0x41bac7)=>{const _0x38ba60=_0x5b12a9['markerName']['split'](':')[0x1],_0x4d44f5=this['_getChangeFromId'](_0x38ba60);if(!_0x4d44f5)return null;const _0x5f5556='add'==_0x4d44f5['type']?'split':'merge';if(_0x41bac7['consumable']['test'](_0x5b12a9['markerRange'],_0x4fb5c3['name']))for(const _0x5a8cd4 of _0x5b12a9['markerRange']['getItems']()){if(!_0x5a8cd4['is']('element','softBreak'))continue;const _0x50c3b5=_0x41bac7['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x5f5556}),_0x9e82b0=_0x41bac7['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x5a8cd4));_0x4d44f5['data']['isSuggestion']&&_0x41bac7['writer']['addClass']('ck-suggestion-marker-'+_0x5f5556+'-new',_0x50c3b5),this['activeChange']==_0x4d44f5&&_0x41bac7['writer']['addClass']('ck-suggestion-marker--active',_0x50c3b5),_0x41bac7['writer']['insert'](_0x9e82b0,_0x50c3b5),_0x41bac7['mapper']['bindElementToMarker'](_0x50c3b5,_0x5b12a9['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x288df3=>{for(const _0x40cab1 of this['editor']['model']['document']['getRootNames']()){const _0x30616b=this['editor']['model']['document']['getRoot'](_0x40cab1),_0xf9a02d=this['editor']['editing']['view']['document']['getRoot'](_0x40cab1);if(_0xf9a02d){const _0x3d490a=_0x30616b['getAttribute']('revisionHistoryAttachChange');if(_0x288df3['removeAttribute']('data-change-id',_0xf9a02d),_0x288df3['removeClass']('ck-revision-history-root-add',_0xf9a02d),_0x288df3['removeClass']('ck-revision-history-root-remove',_0xf9a02d),_0x288df3['removeClass']('ck-revision-history-root--active',_0xf9a02d),_0x3d490a){const _0x5cc3af=this['_getChangeFromId'](_0x3d490a);if(!_0x5cc3af)return null;_0x288df3['setAttribute']('data-change-id',_0x3d490a,_0xf9a02d),_0x288df3['addClass']('ck-revision-history-root-'+_0x5cc3af['type'],_0xf9a02d),this['activeChange']==_0x5cc3af&&_0x288df3['addClass']('ck-revision-history-root--active',_0xf9a02d);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x448747=>'revision-comment:'+_0x448747,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x4a7b61=>'revision-suggestion:'+_0x4a7b61,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x509796=>({'name':'suggestion:'+_0x509796,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x4ab7ea=>{const _0x300c4b=_0x4ab7ea['markerName']['split'](':')[0x1];return'insertion'!=_0x300c4b&&'deletion'!=_0x300c4b?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x300c4b]};}}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:deletion',tt(this['editor'],'merge'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:insertion',tt(this['editor'],'split'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision-suggestion',(_0x3b97a0,_0x1eafb8,_0x4f46b1)=>{const _0x56c533=_0x4f46b1['mapper']['markerNameToElements'](_0x1eafb8['markerName']);if(_0x56c533){for(const _0x3c8fee of _0x56c533)_0x3c8fee['is']('uiElement')&&(_0x4f46b1['mapper']['unbindElementFromMarkerName'](_0x3c8fee,_0x1eafb8['markerName']),_0x4f46b1['writer']['remove'](_0x3c8fee));}},{'priority':'high'});}['_getChangeFromId'](_0x442adc){return this['_changeIdToChange']['get'](_0x442adc);}['_getViewForChange'](_0xab806c){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new Y(this['editor']['locale'],_0xab806c),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x375698,_0x57fd95,_0x32ddf9,_0x270b87)=>{_0x270b87&&this['_balloon']['remove'](_0x270b87),_0x32ddf9&&(this['_balloon']['add']({'view':_0x32ddf9,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x134a05=this['editor']['editing'],_0xc08673=this['_getChangeFromId'](_0x32ddf9['changeId']);let _0x513d3d;if(_0xc08673['data']['isOnRoot']){const _0x5e6d81=_0x134a05['view']['getDomRoot'](_0xc08673['rootName']);_0x513d3d=Array['from'](_0x5e6d81['getClientRects']());}else{const _0xa4774e=this['editor']['model']['markers']['get']('revision:'+_0x32ddf9['changeId']);_0x513d3d=Array['from'](_0x134a05['mapper']['markerNameToElements'](_0xa4774e['name']))['map'](_0x482f5f=>_0x134a05['view']['domConverter']['mapViewToDom'](_0x482f5f))['map'](_0x19c100=>Array['from'](_0x19c100['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x513d3d[0x0];return _0x513d3d['find'](_0x3c55b4=>_0x3c55b4['top']-0x3<=this['_activeViewTarget']['y']&&_0x3c55b4['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x3c55b4['left']-0x3<=this['_activeViewTarget']['x']&&_0x3c55b4['right']+0x3>=this['_activeViewTarget']['x'])||_0x513d3d[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x5efd62,_0x4ece5e,_0x1623af,_0x368ed7)=>{this['activeView']=_0x1623af?this['_getViewForChange'](_0x1623af):null,this['editor']['model']['change'](()=>{const _0x1643ec=this['editor']['editing'];_0x368ed7&&(_0x368ed7['data']['isOnRoot']?_0x1643ec['view']['change'](_0x1d1efb=>{_0x1d1efb['removeClass']('ck-revision-history-root--active',_0x1643ec['view']['document']['getRoot'](_0x368ed7['rootName']));}):_0x1643ec['reconvertMarker']('revision:'+_0x368ed7['id'])),_0x1623af&&(_0x1623af['data']['isOnRoot']?_0x1643ec['view']['change'](_0xd389d8=>{_0xd389d8['addClass']('ck-revision-history-root--active',_0x1643ec['view']['document']['getRoot'](_0x1623af['rootName']));}):_0x1643ec['reconvertMarker']('revision:'+_0x1623af['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x2c054f,_0x514dff)=>{if(this['activeChange'])return;const _0x564d56=this['_findChangeIdFromDomTarget'](_0x514dff['target']),_0x38738a=this['_changeIdToChange']['get'](_0x564d56);_0x38738a?(this['_activeViewTarget']={'x':_0x514dff['domEvent']['x'],'y':_0x514dff['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x38738a)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x863321,_0x275d1a)=>{const _0x171473=this['_findChangeIdFromDomTarget'](_0x275d1a['target']),_0x2d6659=this['_changeIdToChange']['get'](_0x171473);_0x2d6659?(this['_activeViewTarget']={'x':_0x275d1a['domEvent']['x'],'y':_0x275d1a['domEvent']['y']},_0x2d6659===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x2d6659):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x167abe){do{const _0x4fbdfe=_0x167abe['getAttribute']('data-change-id');if(_0x4fbdfe)return _0x4fbdfe;_0x167abe=_0x167abe['parent'];}while(_0x167abe);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x592371=>{for(const _0x344474 of this['editor']['model']['markers'])_0x592371['removeMarker'](_0x344474);});}}function tt(_0x383b5b,_0x8acedb){return(_0x199469,_0x56c7c7,_0xf2d931)=>{if(!_0xf2d931['consumable']['test'](_0x56c7c7['markerRange'],_0x199469['name']))return;const _0x397019=_0x56c7c7['markerRange']['getWalker'](),_0x5bcb10=_0x56c7c7['markerRange']['start'],_0x33cd86=_0x383b5b['model']['schema'];let _0xc69f8c=null,_0x402881=null,_0x3519aa=!0x1,_0x27c2d4=!0x1;for(const _0x12a3d7 of _0x397019){const _0x356c9d=_0x12a3d7['item'];_0x3519aa=_0x3519aa||_0x33cd86['isContent'](_0x356c9d);const _0x431a6a=_0xf2d931['mapper']['toViewElement'](_0x356c9d);if(_0x431a6a&&_0x431a6a['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x12a3d7['type']&&(_0x33cd86['isBlock'](_0x356c9d)&&!_0x33cd86['isLimit'](_0x356c9d)&&(_0x356c9d['nextSibling']||_0x5bcb10['isAtEnd']?_0xc69f8c&&_0xc69f8c['parent']==_0x356c9d||(_0xc69f8c=_0x356c9d,_0x547e29(_0x12a3d7['previousPosition']),_0x27c2d4=!0x0):_0x402881=_0x402881||_0x12a3d7['previousPosition']));}function _0x547e29(_0x5c0932){const _0x343bab=_0xf2d931['mapper']['toViewPosition'](_0x5c0932),_0xdb4ad4=_0xf2d931['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x8acedb});_0xf2d931['writer']['insert'](_0x343bab,_0xdb4ad4),_0xf2d931['mapper']['bindElementToMarker'](_0xdb4ad4,_0x56c7c7['markerName']);}_0x3519aa||_0x27c2d4||!_0x402881||_0x547e29(_0x402881);};}class yt extends _0x255895{constructor(_0x3e1975){super(_0x3e1975);const _0x37e8b4=_0x3e1975['plugins']['get'](d);this['affectsData']=!0x1,this['listenTo'](_0x37e8b4,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x37e8b4,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x1b5ec4=this['editor'],_0x5557de=_0x1b5ec4['plugins']['get'](d),_0x5b2a7e=_0x5557de['isReady']?_0x5557de['diff']['newRevisionId']:null;_0x1b5ec4['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x5b2a7e);}['refresh'](){const {isReady:_0x30627e,isEnabled:_0x21d30a,repository:_0x2fd936,diff:_0x52407d}=this['editor']['plugins']['get'](d),_0x987f41=_0x52407d&&_0x2fd936['getLaterVisibleRevision'](_0x52407d['newRevisionId']);this['isEnabled']=_0x30627e&&_0x21d30a&&Boolean(_0x987f41);}}class bt extends _0x255895{['_step'];constructor(_0x20a33a,{direction:_0x3e8381}){super(_0x20a33a);const _0x1aa496=_0x20a33a['plugins']['get'](d);this['affectsData']=!0x1,this['_step']='forward'===_0x3e8381?0x1:-0x1,this['listenTo'](_0x1aa496,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x1aa496,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x1aa496,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x3f6dd0=this['editor'],_0x21561c=_0x3f6dd0['plugins']['get'](d),{isNavigationMode:_0x52bc6e,currentChangeNumber:_0x501676}=_0x21561c;let _0x3c0298;if(_0x21561c['activeChange']=_0x52bc6e?_0x21561c['diff']['changes']['get'](_0x501676+this['_step']):_0x21561c['diff']['changes']['first'],_0x21561c['activeChange']['data']['isOnRoot'])_0x3c0298=_0x3f6dd0['editing']['view']['getDomRoot'](_0x21561c['activeChange']['rootName']);else{const _0x5e9f88=_0x3f6dd0['model']['markers']['get']('revision:'+_0x21561c['activeChange']['id']);_0x3c0298=_0x569c81(_0x3f6dd0['editing'],_0x5e9f88);}_0x511da0({'target':_0x3c0298,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x434b9d,currentChangeNumber:_0x562975,numberOfChanges:_0x42dfff,isReady:_0x598cd9,isEnabled:_0x17700c}=this['editor']['plugins']['get'](d);this['isEnabled']=!!(_0x17700c&&_0x598cd9&&_0x42dfff)&&(!_0x434b9d||(0x1===this['_step']?_0x562975<_0x42dfff-0x1:_0x562975>0x0));}}class di extends _0x4be5f7{constructor(_0x5a309b){super(_0x5a309b);const _0x411815=this['bindTemplate'],_0x2ebe84=new _0x5ae3a4(_0x5a309b),_0x2f4da7=new _0x5ae3a4(_0x5a309b);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',(_0x44cdda,_0x379bd8)=>_0x44cdda&&_0x379bd8>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x478ba0,_0x5c1973,_0x10fd59,_0x57bc43)=>{if(!_0x478ba0)return R(_0x5a309b,'Loading...');if(!_0x10fd59)return R(_0x5a309b,'No\x20changes');const _0x398e1e=R(_0x5a309b,'NUMBER_OF_CHANGES',_0x10fd59);return _0x57bc43?R(_0x5a309b,'X_OF_Y_CHANGES',[_0x5c1973+0x1,_0x10fd59]):_0x398e1e;}),_0x2ebe84['set']({'label':R(_0x5a309b,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':'<svg\x20viewBox=\x220\x200\x2020\x2020\x22\x20xmlns=\x22http://www.w3.org/2000/svg\x22><path\x20d=\x22M16.435\x2014.494a.75.75\x200\x200\x200\x201.197-.899l-.067-.089-6.992-8a.75.75\x200\x200\x200-1.05-.078l-.079.078-7.008\x208a.75.75\x200\x200\x200\x201.049\x201.066l.08-.078\x206.442-7.354\x206.428\x207.354z\x22/></svg>\x0a'}),_0x2f4da7['set']({'label':R(_0x5a309b,'Show\x20next\x20change'),'tooltip':!0x0,'icon':'<svg\x20viewBox=\x220\x200\x2020\x2020\x22\x20xmlns=\x22http://www.w3.org/2000/svg\x22><path\x20d=\x22M16.435\x205.506a.75.75\x200\x200\x201\x201.197.899l-.067.089-6.992\x208a.75.75\x200\x200\x201-1.05.078l-.079-.078-7.008-8a.75.75\x200\x200\x201\x201.049-1.066l.08.078\x206.442\x207.354\x206.428-7.354z\x22/></svg>\x0a'}),_0x2ebe84['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x2f4da7['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x2ebe84['on']('execute',()=>this['fire']('execute','backward')),_0x2f4da7['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',_0x411815['if']('_isStatusLabelVisible','ck-hidden',_0x34dc7d=>!_0x34dc7d)]},'children':[{'text':_0x411815['to']('isNavigationMode',_0x24dc8b=>_0x24dc8b?R(_0x5a309b,'EDIT_X_OF_Y_REVISIONS')+':\x20':R(_0x5a309b,'Total')+':\x20')}]},{'text':_0x411815['to']('_statusText')}]},new _0x1bf43e(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x2ebe84,_0x2f4da7]}]});}}const ce='ck-editor__editable__loading-overlay';class ae extends _0x2ebc56{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x1f595e=this['editor']['editing']['view'];_0x1f595e['change'](_0x4d4d08=>{for(const _0x10b03a of _0x1f595e['document']['roots'])_0x4d4d08['addClass'](ce,_0x10b03a);});}['hide'](){const _0x22cb8e=this['editor']['editing']['view'];_0x22cb8e['change'](_0x27efb1=>{for(const _0x423c54 of _0x22cb8e['document']['roots'])_0x27efb1['removeClass'](ce,_0x423c54);});}}class m extends _0x2ebc56{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[d,ae];}['init'](){const _0x5b8d0f=this['editor'],_0x4479e2=_0x5b8d0f['plugins']['get'](d),_0x2e2cb5=_0x5b8d0f['plugins']['get'](ae);_0x5b8d0f['ui']['componentFactory']['add']('exitToEditing',_0x54a4eb=>{const _0x2798df=new _0x5ae3a4(_0x54a4eb);return _0x2798df['set']({'label':R(_0x54a4eb,'Back\x20to\x20editing'),'icon':_0xaa90df['undo'],'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x2798df,'execute',()=>{_0x5b8d0f['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x2798df;}),_0x5b8d0f['ui']['componentFactory']['add']('restoreRevision',_0x27b282=>{const _0x1ce81b=new _0x5ae3a4(_0x27b282);return _0x1ce81b['set']({'label':R(_0x27b282,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x1ce81b['bind']('isEnabled')['to'](_0x5b8d0f['commands']['get']('restoreRevision')),this['listenTo'](_0x1ce81b,'execute',()=>_0x5b8d0f['execute']('restoreRevision')),_0x1ce81b;}),_0x5b8d0f['ui']['componentFactory']['add']('changesNavigation',_0x290ed9=>{const _0x2edca1=new di(_0x290ed9),_0x1c7266=_0x5b8d0f['commands']['get']('showPreviousChange'),_0x15c298=_0x5b8d0f['commands']['get']('showNextChange');return _0x2edca1['bind']('isBackwardNavigationEnabled')['to'](_0x1c7266,'isEnabled'),_0x2edca1['bind']('isForwardNavigationEnabled')['to'](_0x15c298,'isEnabled'),_0x2edca1['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x4479e2),this['listenTo'](_0x2edca1,'execute',(_0x4eb922,_0x371d03)=>{_0x5b8d0f['execute']('forward'===_0x371d03?'showNextChange':'showPreviousChange');}),_0x2edca1;}),_0x2e2cb5['show'](),_0x4479e2['on']('change:isReady',(_0x832275,_0x23633d,_0x5c78b0)=>{_0x5c78b0?_0x2e2cb5['hide']():_0x2e2cb5['show']();});}}class mt extends at{['_resizeObserver']=null;constructor(_0x443672,_0x5b0b57){super(_0x443672,_0x5b0b57);const _0x583627=this['bindTemplate'];this['set']({'label':R(_0x443672,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=R(_0x443672,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x583627['to']('_tooltipString'),'data-cke-tooltip-position':'s','data-cke-tooltip-class':'ck-tooltip_multi-line'}});}['render'](){super['render'](),this['_resizeObserver']=new pt(this['fieldView']['element'],()=>this['_updateTooltipText']()),this['listenTo'](this['fieldView'],'input',()=>this['_updateTooltipText']());}['destroy'](){super['destroy'](),this['_resizeObserver']&&this['_resizeObserver']['destroy']();}['_updateTooltipText'](){const _0x430f9b=this['fieldView']['element'];this['_tooltipString']=_0x430f9b['scrollWidth']>_0x430f9b['clientWidth']&&_0x430f9b['value']||'';}}class ti extends _0x4be5f7{constructor(_0x1ca7ff,_0x4cbbba,_0x586592){super(_0x1ca7ff);const _0x294083=new _0xb87865();_0x294083['set']({'content':'<svg\x20viewBox=\x220\x200\x2011\x2010\x22\x20xmlns=\x22http://www.w3.org/2000/svg\x22\x20xmlns:xlink=\x22http://www.w3.org/1999/xlink\x22><path\x20d=\x22M5.5\x205C8.538\x205\x2011\x207.015\x2011\x209.5c0\x20.17-.011.336-.034.5H.034A3.732\x203.732\x200\x200\x201\x200\x209.5C0\x207.015\x202.462\x205\x205.5\x205zm0-5a2.5\x202.5\x200\x201\x201\x200\x205\x202.5\x202.5\x200\x200\x201\x200-5z\x22\x20/></svg>\x0a','viewBox':'0\x200\x2011\x2010'});const _0x37c96a=['ck','ck-revision-history-sidebar__revision-author'];_0x586592&&_0x37c96a['push']('ck-revision-history-sidebar__revision-author_creator');const _0x38e97b=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':R(_0x1ca7ff,_0x586592?'Revision\x20creator':'Revision\x20author')},'children':[_0x294083,_0x4cbbba['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x37c96a},'children':_0x38e97b});}}function ni(_0x30360b,_0x425b3b){const _0x4004a3=_0x30360b['bindTemplate'],_0x588e8b=_0x30360b['locale'],_0x343be0=_0x30f9aa(_0x588e8b);_0x343be0['panelPosition']='sw';const _0xf3287b=function(_0x3a9acd,_0x3c598f){const _0x212f1f=function(_0x47d41d,_0x2cde90){const _0x16bb0d=_0x47d41d['locale'],_0x2cb0df={'Compare\x20against\x20selected':R(_0x16bb0d,'Compare\x20against\x20selected'),'Name\x20this\x20revision':R(_0x16bb0d,'Name\x20this\x20revision'),'Restore\x20this\x20revision':R(_0x16bb0d,'Restore\x20this\x20revision')};return _0x2cde90['map'](_0x443293=>{const _0x3b48a7=_0x2cb0df[_0x443293['name']];return _0x3b48a7&&_0x3b48a7!==_0x443293['name']&&(_0x443293['name']=_0x3b48a7),_0x443293;});}(_0x3a9acd,_0x3c598f),_0x208b70=new _0x199961();for(const _0x3395bb of _0x212f1f){const _0x39cbd7={'type':'button','model':new to({'label':_0x3395bb['name'],'class':_0x3395bb['class'],'withText':!0x0,'role':'menuitem','_action':_0x3395bb['action']})};_0x39cbd7['model']['bind']('isEnabled')['to'](_0x3a9acd,'isActionsDropdownOpen',_0x1a7807=>'function'!=typeof _0x3395bb['isEnabled']||(!_0x1a7807||_0x3395bb['isEnabled'](_0x3a9acd))),_0x208b70['add'](_0x39cbd7);}return _0x208b70;}(_0x30360b,_0x425b3b);return _0x30360b['bind']('isActionsDropdownOpen')['to'](_0x343be0,'isOpen'),_0x343be0['buttonView']['set']({'label':R(_0x588e8b,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0xaa90df['threeVerticalDots']}),_0x343be0['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x4004a3['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x4004a3['to'](_0x5d6869=>_0x5d6869['stopPropagation']())}}),_0x343be0['on']('execute',_0x6ee475=>{_0x30360b['isReady']&&'function'==typeof _0x6ee475['source']['_action']&&_0x6ee475['source']['_action'](_0x30360b);}),_0x28484e(_0x343be0,_0xf3287b,{'role':'menu'}),_0x343be0['listenTo'](_0x30360b,'change:isActionsDropdownOpen',(_0xe98399,_0x574e72,_0x14f12d)=>{if(_0x14f12d)for(const _0x28dea6 of _0x343be0['listView']['items']){const _0x29c364=_0x28dea6['children']['first'],_0x2496c3=_0x425b3b['find'](_0x515e95=>_0x515e95['action']===_0x29c364['_action'])['isVisible'];_0x28dea6['isVisible']=void 0x0===_0x2496c3||_0x2496c3(_0x30360b);}}),_0x343be0;}class ai extends/* #__PURE__ -- @preserve */
26
+ _0x20e829(_0x4be5f7){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x688465,_0x583ff9,_0x514eb2,_0x1d8fe7){super(_0x688465);const _0x54612e=this['bindTemplate'],_0x2df15f=function(_0x592e04,_0x330c3d){const _0x141d99=Array['from'](_0x330c3d['authors'])['filter'](_0x40d343=>_0x40d343!=_0x330c3d['creator']);return _0x330c3d['creator']&&_0x141d99['unshift'](_0x330c3d['creator']),_0x141d99['map'](_0x1ff12e=>new ti(_0x592e04,_0x1ff12e,_0x1ff12e==_0x330c3d['creator']));}(_0x688465,_0x583ff9);this['id']=_0x583ff9['id'],this['_revision']=_0x583ff9,this['_requireRevisionName']=_0x1d8fe7,this['bind']('name','createdAt')['to'](_0x583ff9),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x3e64be=>{return _0x186e24=_0x688465['uiLanguage'],(_0x5310e5=_0x3e64be)['toLocaleDateString'](_0x186e24,{'month':'long','day':'numeric'})+',\x20'+_0x5310e5['toLocaleTimeString'](_0x186e24,{'hour':'numeric','minute':'numeric'});var _0x186e24,_0x5310e5;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new mt(_0x688465,_0xbf0be),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x48b117=>_0x48b117||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x48013e,_0x1d49a4)=>_0x48013e&&_0x1d49a4),this['revisionActionsView']=_0x514eb2&&_0x514eb2['length']?ni(this,_0x514eb2):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x54612e['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x54612e['if']('isEnabled','ck-disabled',_0x44dcbb=>!_0x44dcbb),_0x54612e['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x54612e['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x54612e['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':_0x54612e['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':_0x2df15f}]},this['revisionActionsView']],'on':{'click':_0x54612e['to'](_0x5e69e6=>{_0x5e69e6['srcElement']['closest']('.ck-thread__remove-confirm')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x419954=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x419954,'change',()=>{this['_requireRevisionName']&&!_0x419954['value']||this['fire']('setName',{'id':this['id'],'name':_0x419954['value']}),_0x419954['value']||(_0x419954['value']=this['name']?this['name']:this['_createdAtFormatted']);});}['select'](){this['isSelected']=!0x0;}['deselect'](){this['isSelected']=!0x1;}['highlight'](){this['isHighlighted']=!0x0;}['unhighlight'](){this['isHighlighted']=!0x1;}}function mi(_0x78a060,_0x5277b2){const _0x434637=_0x5b91d0['fromJSDate'](_0x78a060)['setLocale'](_0x5277b2),_0x5611cb=_0x5b91d0['local'](),_0x9c6758=_0x5611cb['minus']({'days':0x1})['startOf']('day');let _0x9f92f3,_0x3eb9bc;return _0x434637['hasSame'](_0x5611cb,'day')?(_0x9f92f3=_0x434637['startOf']('day')['toJSDate'](),_0x3eb9bc=_0x434637['toRelativeCalendar']()):_0x434637['hasSame'](_0x9c6758,'day')?(_0x9f92f3=_0x9c6758['toJSDate'](),_0x3eb9bc=_0x434637['toRelativeCalendar']()):_0x434637['hasSame'](_0x5611cb,'week')?(_0x9f92f3=_0x434637['startOf']('week')['toJSDate'](),_0x3eb9bc=_0x434637['weekdayLong']||''):_0x434637['hasSame'](_0x5611cb,'year')?(_0x9f92f3=_0x434637['startOf']('month')['toJSDate'](),_0x3eb9bc=_0x434637['monthLong']||''):(_0x9f92f3=_0x434637['startOf']('year')['toJSDate'](),_0x3eb9bc=String(_0x434637['year'])),{'startDate':_0x9f92f3,'localizedPeriodName':_0x3eb9bc};}class vi extends _0x4be5f7{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x5ad71b,_0x1ac3a6,_0x3fb477,_0x16eca2){super(_0x5ad71b);const _0x333a3a=mi(_0x1ac3a6,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x1ac3a6,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x3fb477,this['_requireRevisionName']=_0x16eca2,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':_0x333a3a}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x30acb6){const _0x3b9356=new ai(this['locale'],_0x30acb6,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x3b9356);}['removeRevision'](_0x294df0){const _0x381ada=this['revisionViews']['find'](_0x4194db=>_0x4194db['id']===_0x294df0['id']);this['revisionViews']['remove'](_0x381ada);}}class as extends _0x4be5f7{constructor(_0x13b367){super(_0x13b367);const _0x1389a0=new _0xb87865();_0x1389a0['content']=_0xaa90df['history'],this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x1389a0,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[R(_0x13b367,'Revision\x20history')]}]});}}class li extends _0x4be5f7{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x34ae3a,_0x58a36b,_0x801b5,_0x38efc1){super(_0x34ae3a);const _0x4cf1ad=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x58a36b,this['_revisionActions']=_0x801b5,this['_requireRevisionName']=_0x38efc1,this['on']('select',(_0x165110,_0x162c22)=>{this['fire']('revisionSelected',_0x162c22);}),this['on']('setName',(_0x368914,_0x56d5a4)=>{this['fire']('revisionSetName',_0x56d5a4);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new as(_0x34ae3a),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x4cf1ad['if']('isEnabled','ck-disabled',_0x3e94a3=>!_0x3e94a3)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x5db2b7 of this['_revisions'])this['_addRevision'](_0x5db2b7);this['_revisions']['on']('add',(_0x4987ce,_0xb72744)=>{this['_addRevision'](_0xb72744);}),this['_revisions']['on']('remove',(_0x39277c,_0x2b80fe)=>{this['_removeRevision'](_0x2b80fe);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x493ef0=>_0x493ef0['revisionViews']['map'](_0xb6d491=>_0xb6d491))['flat']();}['selectRevision'](_0xcc0a75){for(const _0x4e88ae of this['revisionViews'])_0xcc0a75&&_0xcc0a75['id']===_0x4e88ae['id']?_0x4e88ae['select']():_0x4e88ae['deselect']();}['highlightRevisions'](_0x53aabc){for(const _0x5b33d1 of this['revisionViews'])_0x53aabc['some'](({id:_0x42e0b3})=>_0x42e0b3===_0x5b33d1['id'])?_0x5b33d1['highlight']():_0x5b33d1['unhighlight']();}['_addRevision'](_0xe37d52){const _0x4a5997=mi(_0xe37d52['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x59c80c=this['timePeriodViews']['get'](0x0);_0x59c80c&&_0x59c80c['startDate']['getTime']()===_0x4a5997['getTime']()||(_0x59c80c=new vi(this['locale'],_0x4a5997,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x59c80c)),_0x59c80c['addRevision'](_0xe37d52);}['_removeRevision'](_0x56c8f0){const _0x4a9d0c=mi(_0x56c8f0['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x4a9d0c)['removeRevision'](_0x56c8f0);}['_getTimePeriodViewByStartDate'](_0x1d4341){return this['timePeriodViews']['find'](_0x209229=>_0x209229['startDate']['getTime']()===_0x1d4341['getTime']());}}class g extends _0x2ebc56{['_revisionViewer'];['_revisionsRepository'];['_sidebarView'];static ['defaultRevisionActions']=/* #__PURE__ -- @preserve */
27
27
  ((()=>['compareAgainstSelected','restoreRevision','nameRevision'])());static ['availableRevisionActions']=/* #__PURE__ -- @preserve */
28
- bt();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[d];}constructor(_0x1f00c9){super(_0x1f00c9),this['_revisionViewer']=_0x1f00c9['plugins']['get'](d),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x460f7c=this['_revisionsRepository']['_revisions'],_0x4df4e9=this['_createRevisionActions'](),_0x4c0d5e=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new ii(this['editor']['locale'],_0x460f7c,_0x4df4e9,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',(_0x187221,_0x4e4172)=>{_0x4e4172['revisionViews']['on']('add',(_0x1e4e3f,_0x111d3f)=>{_0x111d3f['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)),_0x4c0d5e['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x25119a=this['_revisionsRepository']['getRevision'](0x0);if(_0x25119a){const _0x219adb=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x25119a['id']);this['_revisionViewer']['compare'](_0x25119a,_0x219adb);}}['_handleRevisionSelected'](_0x47690f,_0x4fb6a3){const _0x6f63c6=this['_revisionsRepository']['getRevision'](_0x4fb6a3['id']),_0x2f688d=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x6f63c6['id']);this['_revisionViewer']['compare'](_0x6f63c6,_0x2f688d);}['_handleRevisionSetName'](_0x5703bb,_0x3c65fd){this['_revisionsRepository']['getRevision'](_0x3c65fd['id'])['setName'](_0x3c65fd['name']);}['_handleDiffChange'](_0x37d1cb,_0x5a2760,_0x32fa7c){const _0x318b3d=this['_revisionsRepository']['getRevisionsInDiff'](_0x32fa7c);_0x318b3d['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x318b3d),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x318b3d[0x0]));}['_createRevisionActions'](){const _0x3d61f3=this['editor'],_0x2c659b=g['availableRevisionActions'],_0x1be28e=_0x3d61f3['config']['get']('revisionHistory.revisionActions')||g['defaultRevisionActions'];if(_0x1be28e['length'])return _0x1be28e['map'](_0x150706=>{const _0xfe178='string'==typeof _0x150706?Object['assign']({},_0x2c659b[_0x150706]):_0x150706;return _0xfe178['action']=_0xfe178['action']['bind'](this,_0x3d61f3),_0xfe178['isVisible']&&(_0xfe178['isVisible']=_0xfe178['isVisible']['bind'](this,_0x3d61f3)),_0xfe178;});}}function bt(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x31a2a8},_0x574569)=>{const _0xc48cfe=_0x31a2a8['get'](d),_0x572549=_0xc48cfe['repository'];let _0x3864f6=_0xc48cfe['diff']['newRevisionId'],_0x2665a0=_0x574569['id'];_0x572549['getIndex'](_0x3864f6)>_0x572549['getIndex'](_0x2665a0)&&([_0x3864f6,_0x2665a0]=[_0x2665a0,_0x3864f6]),_0xc48cfe['compare'](_0x3864f6,_0x2665a0);},'isVisible':({plugins:_0x28708d},_0x36894e)=>{const _0x543819=_0x28708d['get'](d);return!(_0x543819['repository']['getRevisionsInDiff'](_0x543819['diff'])['length']>0x2)&&!_0x36894e['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x46f248,{id:_0x1b56b2})=>{_0x46f248['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x1b56b2);},'isVisible':({plugins:_0x3d4aee},_0x214b2d)=>!!_0x3d4aee['get'](d)['repository']['getLaterVisibleRevision'](_0x214b2d['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x3f619a},{id:_0x7c5b30,revisionNameView:_0x40e2c5})=>{const _0x414a55=_0x3f619a['get'](d),_0x3c4ac6=_0x414a55['repository']['getEarlierVisibleRevision'](_0x7c5b30);_0x414a55['compare'](_0x7c5b30,_0x3c4ac6),_0x40e2c5['focus'](),_0x40e2c5['fieldView']['select']();}}};}class et extends ot{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0xb31d0e,_0xb4a35a){super(_0xb31d0e),this['_view']=_0xb4a35a,this['_toolbarConfig']=ht(_0xb31d0e['config']['get']('toolbar')),this['_elementReplacer']=new ct();}get['element'](){return this['view']['element'];}['init'](_0x275a26){const _0x1fafbd=this['editor'],_0x4c8edd=this['view'],_0x45dd2f=_0x1fafbd['editing']['view'],_0x2abed4=_0x4c8edd['editable'],_0x5d8d62=_0x45dd2f['document']['getRoot']();_0x2abed4['name']=_0x5d8d62['rootName'],_0x4c8edd['render']();const _0xb0c587=_0x2abed4['element'];this['setEditableElement'](_0x2abed4['name'],_0xb0c587),_0x4c8edd['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x45dd2f['attachDomRoot'](_0xb0c587),this['_elementReplacer']['replace'](_0x275a26,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x43e013=this['view'],_0xc1b300=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0xc1b300['detachDomRoot'](_0x43e013['editable']['name']),_0x43e013['destroy']();}['_initToolbar'](){const _0x5277a9=this['view'];_0x5277a9['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x5277a9['stickyPanel']['limiterElement']=_0x5277a9['element'],_0x5277a9['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x52ed5a})=>_0x52ed5a),_0x5277a9['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x5277a9['toolbar']);}}class st extends dt{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x34c344,_0x49df4f,_0x249b24={}){super(_0x34c344),this['stickyPanel']=new lt(_0x34c344),this['toolbar']=new nt(_0x34c344,{'shouldGroupWhenFull':_0x249b24['shouldToolbarGroupWhenFull']}),this['_editable']=new ut(_0x34c344,_0x49df4f);}['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
- rt(it){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x4ac6fc,_0x1e56e9){super(_0x1e56e9),this['sourceElement']=_0x4ac6fc,this['model']['document']['createRoot']();const _0x41ab8e=new st(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new et(this,_0x41ab8e);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x4e08cc,_0x213993){const _0x2e3441=new this(_0x4e08cc,_0x213993);return await _0x2e3441['initPlugins'](),await _0x2e3441['ui']['init'](_0x4e08cc),await _0x2e3441['data']['init'](_0x2e3441['config']['get']('initialData')||''),_0x2e3441['fire']('ready'),_0x2e3441;}}const p=['RevisionHistoryUI','RestrictedEditingMode'];class k extends _0x27f686{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x5392fd){function _0x19d93d(_0x18bf98){return _0x18bf98['map'](_0x144e15=>String['fromCharCode'](_0x144e15))['join']('');}super(_0x5392fd),this['result']='end',_0x5392fd[_0x19d93d([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x19d93d([0x76,0x69,0x65,0x77])][_0x19d93d([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x19d93d([0x61,0x75,0x74,0x6f]),_0x5392fd[_0x19d93d([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x19d93d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x19d93d([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x19d93d([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x19d93d([0x6f,0x6b])});}}class H extends _0x27f686{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l,u];}constructor(_0x474e5e){if(super(_0x474e5e),!this['editor']['config']['get']('revisionHistory'))throw new _0xa442d4('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x2286ff=>this['_showRevisionViewer']({..._0x2286ff,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x21530c=>this['_closeRevisionViewer'](_0x21530c)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x5901a5=>this['_restoreRevision'](_0x5901a5)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x17f5a3){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x17f5a3;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x168bc4){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x168bc4);}['getRevision'](_0x247bae){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x247bae);}['getRevisions'](_0x578624){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x578624||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x2d057c=this['editor'],_0x171956=_0x25e631(_0x2d057c,p),_0xb0a30d=_0x2d057c['plugins']['get']('RevisionTracker'),_0x3573a0=_0x2d057c['plugins']['get']('Users')['users'];return _0x171956['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x171956['lazyRoots'],(_0x171956['plugins']['push'](k,d,m,class extends _0x27f686{static get['requires'](){return[d,'Users'];}['init'](){const _0x510da8=this['editor']['plugins']['get']('Users');for(const _0x32d731 of _0x3573a0)_0x32d731['isAnonymous']||_0x510da8['getUser'](_0x32d731['id'])||_0x510da8['addUser'](_0x32d731);const _0x2e4cf0=_0xb0a30d['repository']['getRevisions']();let _0x393b6a=null;const _0x41c330=this['editor']['plugins']['get']('RevisionViewer');_0x41c330['adapter']=_0xb0a30d['adapter'],_0x41c330['bind']('isEnabled')['to'](_0xb0a30d),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x2d057c,'isReadOnly',_0x1307d1=>!_0x1307d1);for(const _0x1d5577 of _0x2e4cf0){const _0x4bd387=null===_0x1d5577['creator'];if(_0x4bd387&&_0x1d5577['toVersion']===_0x1d5577['fromVersion'])continue;const _0x1574e3=_0x1d5577['toJSON']();_0x41c330['addRevisionData'](_0x1574e3,(_0x531c53,_0x167b7c,_0x33923c)=>{if(_0x4bd387){if(_0x393b6a)_0x393b6a['_update'](_0x531c53,_0x167b7c);else{if(!_0x167b7c){const _0x3bf1e6=_0x33923c['toJSON']();_0x3bf1e6['id']=_0x27b216(),_0xb0a30d['saveRevision'](_0x3bf1e6,_0x33923c['toVersion'])['then'](_0x84b91=>{_0x393b6a=_0x84b91;});}}}else _0x1d5577['_update'](_0x531c53,_0x167b7c);});}}},g),_0x171956);}['_enhanceShowRevisionViewerCallback'](){const _0x5910d3=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x155983=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x4c5988=this['editor']['plugins']['get']('Autosave');await _0x4c5988['save']();}else await _0x155983['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x5e4bf4=this['editor']['plugins']['get']('Dialog');_0x5e4bf4['isOpen']&&_0x5e4bf4['hide']();}const _0x357527=this['_getRevisionViewerEditorConfig']();return _0x5910d3(_0x357527)['then'](_0x34d263=>{return(this['_viewerEditor']=_0x34d263,this['editor']['plugins']['has']('Annotations'))&&this['editor']['plugins']['get']('Annotations')['refreshVisibility'](),_0x34d263;})['catch'](_0x4e531c=>(console['error'](_0x4e531c),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x3ba5cd=this['editor']['config']['get']('revisionHistory')['closeRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.closeRevisionViewerCallback',()=>(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['_viewerEditor']['plugins']['get']('RevisionViewer')['_cleanUp'](),_0x3ba5cd(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x3a8313=this['editor']['plugins']['get']('Annotations');_0x3a8313['refreshVisibility'](),_0x3a8313['refreshPositioning']();}})));}['_showRevisionViewer'](_0x42a9aa){const _0x3bbb9a=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x6daf4c=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x526f1d=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return w['create'](_0x526f1d,_0x42a9aa)['then'](_0x27c4c8=>(_0x6daf4c['style']['display']='block',_0x3bbb9a['style']['display']='none',_0x27c4c8));}['_closeRevisionViewer'](_0x1ca7d6){const _0x24039f=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x24039f['style']['display']='',_0x1ca7d6['destroy']();}async['_restoreRevision'](_0x30d63e){const _0x350cff=this['editor'],_0x43a7f3=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x1764aa=_0x350cff['plugins']['get']('RevisionTracker'),_0x560ec5=_0x43a7f3['repository']['getRevision'](_0x30d63e);let _0x2ad032,_0x94cb32,_0x1341cb;try{_0x2ad032=await _0x43a7f3['getRevisionData'](_0x560ec5),_0x94cb32=await _0x43a7f3['getRevisionRootsAttributes'](_0x560ec5);}catch(_0x5f4995){return void console['error'](_0x5f4995);}_0x350cff['model']['change'](_0x537cc5=>{for(const _0x576d71 of Array['from'](_0x350cff['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x537cc5['removeMarker'](_0x576d71);}),_0x43a7f3['isReady']=!0x1,_0x350cff['model']['enqueueChange'](_0x370153=>{_0x370153['setSelection'](null),_0x370153['removeSelectionAttribute'](_0x350cff['model']['document']['selection']['getAttributeKeys']());const _0x2e5880=Object['keys'](_0x2ad032);for(const _0x47017c of _0x350cff['model']['document']['roots'])'$graveyard'!=_0x47017c['rootName']&&_0x47017c['isAttached']()&&!_0x2e5880['includes'](_0x47017c['rootName'])&&_0x370153['detachRoot'](_0x47017c);for(const _0x174291 of _0x2e5880){let _0x4efaef=_0x350cff['model']['document']['getRoot'](_0x174291);_0x4efaef&&_0x4efaef['isAttached']()||(_0x4efaef=_0x370153['addRoot'](_0x174291));const _0x41817f=_0x94cb32[_0x174291],_0x5bf2be=Object['keys'](_0x41817f),_0x5a02e3=_0x2ad032[_0x174291];for(const _0x245c35 of _0x4efaef['getAttributeKeys']())_0x5bf2be['includes'](_0x245c35)||_0x370153['removeAttribute'](_0x245c35,_0x4efaef);for(const _0x7bd368 of _0x5bf2be)_0x370153['setAttribute'](_0x7bd368,_0x94cb32[_0x174291][_0x7bd368],_0x4efaef);_0x370153['remove'](_0x370153['createRangeIn'](_0x4efaef)),_0x370153['insert'](_0x350cff['data']['parse'](_0x5a02e3,_0x4efaef),_0x4efaef,0x0);}});const _0x266fcc=R(_0x350cff['locale'],'Restored');if(_0x560ec5['name'])_0x1341cb=-0x1==_0x560ec5['name']['indexOf'](_0x266fcc)?_0x266fcc+':\x20'+_0x560ec5['name']:_0x560ec5['name'];else _0x1341cb=_0x266fcc+':\x20'+(_0x560ec5['createdAt']['toLocaleDateString'](_0x350cff['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x560ec5['createdAt']['toLocaleTimeString'](_0x350cff['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x1764aa['saveRevision']({'name':_0x1341cb}),_0x43a7f3['isReady']=!0x0,_0x350cff['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{a as Revision,H as RevisionHistory,u as RevisionHistoryUI,l as RevisionTracker,d as RevisionViewer,ge as RevisionViewerLoadingOverlay,m as RevisionViewerUI,j as RevisionsRepository,g as RevisionsSidebar};
28
+ Rt();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[d];}constructor(_0xb82938){super(_0xb82938),this['_revisionViewer']=_0xb82938['plugins']['get'](d),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x220afc=this['_revisionsRepository']['_revisions'],_0x23cce6=this['_createRevisionActions'](),_0x50e89f=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new li(this['editor']['locale'],_0x220afc,_0x23cce6,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',(_0xced8ae,_0x134c8e)=>{_0x134c8e['revisionViews']['on']('add',(_0x4ee647,_0x38b69d)=>{_0x38b69d['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)),_0x50e89f['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0xe0646f=this['_revisionsRepository']['getRevision'](0x0);if(_0xe0646f){const _0x5904c2=this['_revisionsRepository']['getEarlierVisibleRevision'](_0xe0646f['id']);this['_revisionViewer']['compare'](_0xe0646f,_0x5904c2);}}['_handleRevisionSelected'](_0x2f3a76,_0x881926){const _0x5ca343=this['_revisionsRepository']['getRevision'](_0x881926['id']),_0x3198f9=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x5ca343['id']);this['_revisionViewer']['compare'](_0x5ca343,_0x3198f9);}['_handleRevisionSetName'](_0x1f8e99,_0x4bda3c){this['_revisionsRepository']['getRevision'](_0x4bda3c['id'])['setName'](_0x4bda3c['name']);}['_handleDiffChange'](_0x1d36e7,_0xe2f070,_0x5f5435){const _0x5075ac=this['_revisionsRepository']['getRevisionsInDiff'](_0x5f5435);_0x5075ac['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x5075ac),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x5075ac[0x0]));}['_createRevisionActions'](){const _0x8abe1=this['editor'],_0x291a20=g['availableRevisionActions'],_0x26e6a4=_0x8abe1['config']['get']('revisionHistory.revisionActions')||g['defaultRevisionActions'];if(_0x26e6a4['length'])return _0x26e6a4['map'](_0x1cef0d=>{const _0xacfeca='string'==typeof _0x1cef0d?Object['assign']({},_0x291a20[_0x1cef0d]):_0x1cef0d;return _0xacfeca['action']=_0xacfeca['action']['bind'](this,_0x8abe1),_0xacfeca['isVisible']&&(_0xacfeca['isVisible']=_0xacfeca['isVisible']['bind'](this,_0x8abe1)),_0xacfeca;});}}function Rt(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x25b849},_0x1f43d5)=>{const _0x5831b2=_0x25b849['get'](d),_0x48eb53=_0x5831b2['repository'];let _0xb00625=_0x5831b2['diff']['newRevisionId'],_0x5e09fa=_0x1f43d5['id'];_0x48eb53['getIndex'](_0xb00625)>_0x48eb53['getIndex'](_0x5e09fa)&&([_0xb00625,_0x5e09fa]=[_0x5e09fa,_0xb00625]),_0x5831b2['compare'](_0xb00625,_0x5e09fa);},'isVisible':({plugins:_0x3837b8},_0x3f4d78)=>{const _0x4cb7b1=_0x3837b8['get'](d);return!(_0x4cb7b1['repository']['getRevisionsInDiff'](_0x4cb7b1['diff'])['length']>0x2)&&!_0x3f4d78['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x1ffcae,{id:_0x1a027b})=>{_0x1ffcae['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x1a027b);},'isVisible':({plugins:_0x1b601f},_0x27103f)=>!!_0x1b601f['get'](d)['repository']['getLaterVisibleRevision'](_0x27103f['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x2e1a75},{id:_0x52b3c9,revisionNameView:_0x470518})=>{const _0x4ae37b=_0x2e1a75['get'](d),_0x174b57=_0x4ae37b['repository']['getEarlierVisibleRevision'](_0x52b3c9);_0x4ae37b['compare'](_0x52b3c9,_0x174b57),_0x470518['focus'](),_0x470518['fieldView']['select']();}}};}class et extends ot{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x3f3afc,_0xcc63a3){super(_0x3f3afc),this['_view']=_0xcc63a3,this['_toolbarConfig']=ht(_0x3f3afc['config']['get']('toolbar')),this['_elementReplacer']=new ct();}get['element'](){return this['view']['element'];}['init'](_0x23d094){const _0x37581c=this['editor'],_0x2bbb35=this['view'],_0x734c19=_0x37581c['editing']['view'],_0x10307d=_0x2bbb35['editable'],_0x1e89fb=_0x734c19['document']['getRoot']();_0x10307d['name']=_0x1e89fb['rootName'],_0x2bbb35['render']();const _0x45596f=_0x10307d['element'];this['setEditableElement'](_0x10307d['name'],_0x45596f),_0x2bbb35['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x734c19['attachDomRoot'](_0x45596f),this['_elementReplacer']['replace'](_0x23d094,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0xe73ffe=this['view'],_0x51cb6c=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x51cb6c['detachDomRoot'](_0xe73ffe['editable']['name']),_0xe73ffe['destroy']();}['_initToolbar'](){const _0x1b6049=this['view'];_0x1b6049['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x1b6049['stickyPanel']['limiterElement']=_0x1b6049['element'],_0x1b6049['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x32c9db})=>_0x32c9db),_0x1b6049['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x1b6049['toolbar']);}}class st extends dt{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x42e42b,_0x11c9de,_0x4241b8={}){super(_0x42e42b),this['stickyPanel']=new lt(_0x42e42b),this['toolbar']=new nt(_0x42e42b,{'shouldGroupWhenFull':_0x4241b8['shouldToolbarGroupWhenFull']}),this['_editable']=new ut(_0x42e42b,_0x11c9de);}['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
+ rt(it){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x59a639,_0x3634f5){super(_0x3634f5),this['sourceElement']=_0x59a639,this['model']['document']['createRoot']();const _0x1d333a=new st(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new et(this,_0x1d333a);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0xdbd095,_0x53736a){const _0x17d761=new this(_0xdbd095,_0x53736a);return await _0x17d761['initPlugins'](),await _0x17d761['ui']['init'](_0xdbd095),await _0x17d761['data']['init'](_0x17d761['config']['get']('initialData')||''),_0x17d761['fire']('ready'),_0x17d761;}}const p=['RevisionHistoryUI','RestrictedEditingMode'];class k extends _0x2ebc56{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x176a79){function _0x5154cd(_0x264614){return _0x264614['map'](_0x41406d=>String['fromCharCode'](_0x41406d))['join']('');}super(_0x176a79),this['result']='end',_0x176a79[_0x5154cd([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x5154cd([0x76,0x69,0x65,0x77])][_0x5154cd([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x5154cd([0x61,0x75,0x74,0x6f]),_0x176a79[_0x5154cd([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x5154cd([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x5154cd([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x5154cd([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x5154cd([0x6f,0x6b])});}}class H extends _0x2ebc56{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l,u];}constructor(_0x1af358){if(super(_0x1af358),!this['editor']['config']['get']('revisionHistory'))throw new _0x41ec69('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x22aca8=>this['_showRevisionViewer']({..._0x22aca8,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x3febd8=>this['_closeRevisionViewer'](_0x3febd8)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x2d403d=>this['_restoreRevision'](_0x2d403d)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x143e2b){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x143e2b;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0xfa5bf3){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0xfa5bf3);}['getRevision'](_0xf22f98){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0xf22f98);}['getRevisions'](_0x575782){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x575782||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x33ce01=this['editor'],_0x4fa156=_0x4ae533(_0x33ce01,p),_0x185faa=_0x33ce01['plugins']['get']('RevisionTracker'),_0x5be85d=_0x33ce01['plugins']['get']('Users')['users'];return _0x4fa156['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x4fa156['lazyRoots'],(_0x4fa156['plugins']['push'](k,d,m,class extends _0x2ebc56{static get['requires'](){return[d,'Users'];}['init'](){const _0x36a225=this['editor']['plugins']['get']('Users');for(const _0x3aee3f of _0x5be85d)_0x3aee3f['isAnonymous']||_0x36a225['getUser'](_0x3aee3f['id'])||_0x36a225['addUser'](_0x3aee3f);const _0x3c3465=_0x185faa['repository']['getRevisions']();let _0x37fde8=null;const _0x1f064a=this['editor']['plugins']['get']('RevisionViewer');_0x1f064a['adapter']=_0x185faa['adapter'],_0x1f064a['bind']('isEnabled')['to'](_0x185faa),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x33ce01,'isReadOnly',_0x28ebd2=>!_0x28ebd2);for(const _0x5d1d7c of _0x3c3465){const _0x3867fd=null===_0x5d1d7c['creator'];if(_0x3867fd&&_0x5d1d7c['toVersion']===_0x5d1d7c['fromVersion'])continue;const _0x2ddb7e=_0x5d1d7c['toJSON']();_0x1f064a['addRevisionData'](_0x2ddb7e,(_0x2eb78e,_0x3d9f8f,_0x122d14)=>{if(_0x3867fd){if(_0x37fde8)_0x37fde8['_update'](_0x2eb78e,_0x3d9f8f);else{if(!_0x3d9f8f){const _0x18d4a3=_0x122d14['toJSON']();_0x18d4a3['id']=_0xb3cc0b(),_0x185faa['saveRevision'](_0x18d4a3,_0x122d14['toVersion'])['then'](_0x395d66=>{_0x37fde8=_0x395d66;});}}}else _0x5d1d7c['_update'](_0x2eb78e,_0x3d9f8f);});}}},g),_0x4fa156);}['_enhanceShowRevisionViewerCallback'](){const _0x1b2fcc=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0xc3f1ed=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x127575=this['editor']['plugins']['get']('Autosave');await _0x127575['save']();}else await _0xc3f1ed['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x47c350=this['editor']['plugins']['get']('Dialog');_0x47c350['isOpen']&&_0x47c350['hide']();}const _0x50246e=this['_getRevisionViewerEditorConfig']();return _0x1b2fcc(_0x50246e)['then'](_0xe45b70=>{return(this['_viewerEditor']=_0xe45b70,this['editor']['plugins']['has']('Annotations'))&&this['editor']['plugins']['get']('Annotations')['refreshVisibility'](),_0xe45b70;})['catch'](_0x10a260=>(console['error'](_0x10a260),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x41869d=this['editor']['config']['get']('revisionHistory')['closeRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.closeRevisionViewerCallback',()=>(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['_viewerEditor']['plugins']['get']('RevisionViewer')['_cleanUp'](),_0x41869d(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x36415b=this['editor']['plugins']['get']('Annotations');_0x36415b['refreshVisibility'](),_0x36415b['refreshPositioning']();}})));}['_showRevisionViewer'](_0x155962){const _0x47a417=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x301f07=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x54031c=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return w['create'](_0x54031c,_0x155962)['then'](_0x3c5b95=>(_0x301f07['style']['display']='block',_0x47a417['style']['display']='none',_0x3c5b95));}['_closeRevisionViewer'](_0x31bc9e){const _0x1b87ab=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x1b87ab['style']['display']='',_0x31bc9e['destroy']();}async['_restoreRevision'](_0x440e53){const _0x747b6e=this['editor'],_0x6eefa8=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x45a1dd=_0x747b6e['plugins']['get']('RevisionTracker'),_0x58f2a0=_0x6eefa8['repository']['getRevision'](_0x440e53);let _0x30d135,_0x7617b9,_0x42512f;try{_0x30d135=await _0x6eefa8['getRevisionData'](_0x58f2a0),_0x7617b9=await _0x6eefa8['getRevisionRootsAttributes'](_0x58f2a0);}catch(_0x512b84){return void console['error'](_0x512b84);}_0x747b6e['model']['change'](_0x25b607=>{for(const _0x398eac of Array['from'](_0x747b6e['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x25b607['removeMarker'](_0x398eac);}),_0x6eefa8['isReady']=!0x1,_0x747b6e['model']['enqueueChange'](_0x1b8242=>{_0x1b8242['setSelection'](null),_0x1b8242['removeSelectionAttribute'](_0x747b6e['model']['document']['selection']['getAttributeKeys']());const _0x20d5bf=Object['keys'](_0x30d135);for(const _0x3f496b of _0x747b6e['model']['document']['roots'])'$graveyard'!=_0x3f496b['rootName']&&_0x3f496b['isAttached']()&&!_0x20d5bf['includes'](_0x3f496b['rootName'])&&_0x1b8242['detachRoot'](_0x3f496b);for(const _0x2de0f3 of _0x20d5bf){let _0x2bb866=_0x747b6e['model']['document']['getRoot'](_0x2de0f3);_0x2bb866&&_0x2bb866['isAttached']()||(_0x2bb866=_0x1b8242['addRoot'](_0x2de0f3));const _0x364fc5=_0x7617b9[_0x2de0f3],_0x1d19bd=Object['keys'](_0x364fc5),_0x3a0aa6=_0x30d135[_0x2de0f3];for(const _0x3c46b4 of _0x2bb866['getAttributeKeys']())_0x1d19bd['includes'](_0x3c46b4)||_0x1b8242['removeAttribute'](_0x3c46b4,_0x2bb866);for(const _0xb4ab58 of _0x1d19bd)_0x1b8242['setAttribute'](_0xb4ab58,_0x7617b9[_0x2de0f3][_0xb4ab58],_0x2bb866);_0x1b8242['remove'](_0x1b8242['createRangeIn'](_0x2bb866)),_0x1b8242['insert'](_0x747b6e['data']['parse'](_0x3a0aa6,_0x2bb866),_0x2bb866,0x0);}});const _0x572724=R(_0x747b6e['locale'],'Restored');if(_0x58f2a0['name'])_0x42512f=-0x1==_0x58f2a0['name']['indexOf'](_0x572724)?_0x572724+':\x20'+_0x58f2a0['name']:_0x58f2a0['name'];else _0x42512f=_0x572724+':\x20'+(_0x58f2a0['createdAt']['toLocaleDateString'](_0x747b6e['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x58f2a0['createdAt']['toLocaleTimeString'](_0x747b6e['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x45a1dd['saveRevision']({'name':_0x42512f}),_0x6eefa8['isReady']=!0x0,_0x747b6e['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{a as Revision,H as RevisionHistory,u as RevisionHistoryUI,l as RevisionTracker,d as RevisionViewer,ae as RevisionViewerLoadingOverlay,m as RevisionViewerUI,j as RevisionsRepository,g as RevisionsSidebar};