@ckeditor/ckeditor5-revision-history 46.0.1-alpha.9 → 46.0.2-alpha.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (180) hide show
  1. package/build/revision-history.js +1 -1
  2. package/dist/index.js +7 -7
  3. package/dist/translations/af.js +1 -1
  4. package/dist/translations/af.umd.js +1 -1
  5. package/dist/translations/ar.js +1 -1
  6. package/dist/translations/ar.umd.js +1 -1
  7. package/dist/translations/ast.js +1 -1
  8. package/dist/translations/ast.umd.js +1 -1
  9. package/dist/translations/az.js +1 -1
  10. package/dist/translations/az.umd.js +1 -1
  11. package/dist/translations/be.js +1 -1
  12. package/dist/translations/be.umd.js +1 -1
  13. package/dist/translations/bg.js +1 -1
  14. package/dist/translations/bg.umd.js +1 -1
  15. package/dist/translations/bn.js +1 -1
  16. package/dist/translations/bn.umd.js +1 -1
  17. package/dist/translations/bs.js +1 -1
  18. package/dist/translations/bs.umd.js +1 -1
  19. package/dist/translations/ca.js +1 -1
  20. package/dist/translations/ca.umd.js +1 -1
  21. package/dist/translations/cs.js +1 -1
  22. package/dist/translations/cs.umd.js +1 -1
  23. package/dist/translations/da.js +1 -1
  24. package/dist/translations/da.umd.js +1 -1
  25. package/dist/translations/de-ch.js +1 -1
  26. package/dist/translations/de-ch.umd.js +1 -1
  27. package/dist/translations/de.js +1 -1
  28. package/dist/translations/de.umd.js +1 -1
  29. package/dist/translations/el.js +1 -1
  30. package/dist/translations/el.umd.js +1 -1
  31. package/dist/translations/en-au.js +1 -1
  32. package/dist/translations/en-au.umd.js +1 -1
  33. package/dist/translations/en-gb.js +1 -1
  34. package/dist/translations/en-gb.umd.js +1 -1
  35. package/dist/translations/en.js +1 -1
  36. package/dist/translations/en.umd.js +1 -1
  37. package/dist/translations/eo.js +1 -1
  38. package/dist/translations/eo.umd.js +1 -1
  39. package/dist/translations/es-co.js +1 -1
  40. package/dist/translations/es-co.umd.js +1 -1
  41. package/dist/translations/es.js +1 -1
  42. package/dist/translations/es.umd.js +1 -1
  43. package/dist/translations/et.js +1 -1
  44. package/dist/translations/et.umd.js +1 -1
  45. package/dist/translations/eu.js +1 -1
  46. package/dist/translations/eu.umd.js +1 -1
  47. package/dist/translations/fa.js +1 -1
  48. package/dist/translations/fa.umd.js +1 -1
  49. package/dist/translations/fi.js +1 -1
  50. package/dist/translations/fi.umd.js +1 -1
  51. package/dist/translations/fr.js +1 -1
  52. package/dist/translations/fr.umd.js +1 -1
  53. package/dist/translations/gl.js +1 -1
  54. package/dist/translations/gl.umd.js +1 -1
  55. package/dist/translations/gu.js +1 -1
  56. package/dist/translations/gu.umd.js +1 -1
  57. package/dist/translations/he.js +1 -1
  58. package/dist/translations/he.umd.js +1 -1
  59. package/dist/translations/hi.js +1 -1
  60. package/dist/translations/hi.umd.js +1 -1
  61. package/dist/translations/hr.js +1 -1
  62. package/dist/translations/hr.umd.js +1 -1
  63. package/dist/translations/hu.js +1 -1
  64. package/dist/translations/hu.umd.js +1 -1
  65. package/dist/translations/hy.js +1 -1
  66. package/dist/translations/hy.umd.js +1 -1
  67. package/dist/translations/id.js +1 -1
  68. package/dist/translations/id.umd.js +1 -1
  69. package/dist/translations/it.js +1 -1
  70. package/dist/translations/it.umd.js +1 -1
  71. package/dist/translations/ja.js +1 -1
  72. package/dist/translations/ja.umd.js +1 -1
  73. package/dist/translations/jv.js +1 -1
  74. package/dist/translations/jv.umd.js +1 -1
  75. package/dist/translations/kk.js +1 -1
  76. package/dist/translations/kk.umd.js +1 -1
  77. package/dist/translations/km.js +1 -1
  78. package/dist/translations/km.umd.js +1 -1
  79. package/dist/translations/kn.js +1 -1
  80. package/dist/translations/kn.umd.js +1 -1
  81. package/dist/translations/ko.js +1 -1
  82. package/dist/translations/ko.umd.js +1 -1
  83. package/dist/translations/ku.js +1 -1
  84. package/dist/translations/ku.umd.js +1 -1
  85. package/dist/translations/lt.js +1 -1
  86. package/dist/translations/lt.umd.js +1 -1
  87. package/dist/translations/lv.js +1 -1
  88. package/dist/translations/lv.umd.js +1 -1
  89. package/dist/translations/ms.js +1 -1
  90. package/dist/translations/ms.umd.js +1 -1
  91. package/dist/translations/nb.js +1 -1
  92. package/dist/translations/nb.umd.js +1 -1
  93. package/dist/translations/ne.js +1 -1
  94. package/dist/translations/ne.umd.js +1 -1
  95. package/dist/translations/nl.js +1 -1
  96. package/dist/translations/nl.umd.js +1 -1
  97. package/dist/translations/no.js +1 -1
  98. package/dist/translations/no.umd.js +1 -1
  99. package/dist/translations/oc.js +1 -1
  100. package/dist/translations/oc.umd.js +1 -1
  101. package/dist/translations/pl.js +1 -1
  102. package/dist/translations/pl.umd.js +1 -1
  103. package/dist/translations/pt-br.js +1 -1
  104. package/dist/translations/pt-br.umd.js +1 -1
  105. package/dist/translations/pt.js +1 -1
  106. package/dist/translations/pt.umd.js +1 -1
  107. package/dist/translations/ro.js +1 -1
  108. package/dist/translations/ro.umd.js +1 -1
  109. package/dist/translations/ru.js +1 -1
  110. package/dist/translations/ru.umd.js +1 -1
  111. package/dist/translations/si.js +1 -1
  112. package/dist/translations/si.umd.js +1 -1
  113. package/dist/translations/sk.js +1 -1
  114. package/dist/translations/sk.umd.js +1 -1
  115. package/dist/translations/sl.js +1 -1
  116. package/dist/translations/sl.umd.js +1 -1
  117. package/dist/translations/sq.js +1 -1
  118. package/dist/translations/sq.umd.js +1 -1
  119. package/dist/translations/sr-latn.js +1 -1
  120. package/dist/translations/sr-latn.umd.js +1 -1
  121. package/dist/translations/sr.js +1 -1
  122. package/dist/translations/sr.umd.js +1 -1
  123. package/dist/translations/sv.js +1 -1
  124. package/dist/translations/sv.umd.js +1 -1
  125. package/dist/translations/th.js +1 -1
  126. package/dist/translations/th.umd.js +1 -1
  127. package/dist/translations/ti.js +1 -1
  128. package/dist/translations/ti.umd.js +1 -1
  129. package/dist/translations/tk.js +1 -1
  130. package/dist/translations/tk.umd.js +1 -1
  131. package/dist/translations/tr.js +1 -1
  132. package/dist/translations/tr.umd.js +1 -1
  133. package/dist/translations/tt.js +1 -1
  134. package/dist/translations/tt.umd.js +1 -1
  135. package/dist/translations/ug.js +1 -1
  136. package/dist/translations/ug.umd.js +1 -1
  137. package/dist/translations/uk.js +1 -1
  138. package/dist/translations/uk.umd.js +1 -1
  139. package/dist/translations/ur.js +1 -1
  140. package/dist/translations/ur.umd.js +1 -1
  141. package/dist/translations/uz.js +1 -1
  142. package/dist/translations/uz.umd.js +1 -1
  143. package/dist/translations/vi.js +1 -1
  144. package/dist/translations/vi.umd.js +1 -1
  145. package/dist/translations/zh-cn.js +1 -1
  146. package/dist/translations/zh-cn.umd.js +1 -1
  147. package/dist/translations/zh.js +1 -1
  148. package/dist/translations/zh.umd.js +1 -1
  149. package/package.json +11 -11
  150. package/src/changeitem.js +2 -2
  151. package/src/editor/revisionviewereditor.js +2 -2
  152. package/src/editor/revisionviewereditorui.js +1 -1
  153. package/src/editor/revisionviewereditoruiview.js +1 -1
  154. package/src/index.js +1 -1
  155. package/src/revision.js +2 -2
  156. package/src/revisiondiff.js +1 -1
  157. package/src/revisionhistory.js +1 -1
  158. package/src/revisionhistoryutils.js +1 -1
  159. package/src/revisionsrepository.js +1 -1
  160. package/src/revisiontracker.js +1 -1
  161. package/src/revisionviewer.js +1 -1
  162. package/src/ui/revision/createrevisionactionsdropdown.js +1 -1
  163. package/src/ui/revision/revisionauthorview.js +1 -1
  164. package/src/ui/revision/revisionnameview.js +1 -1
  165. package/src/ui/revision/revisionview.js +2 -2
  166. package/src/ui/revision/subrevisioncollapserview.js +1 -1
  167. package/src/ui/revision/subrevisionview.js +1 -1
  168. package/src/ui/revision/utils.js +1 -1
  169. package/src/ui/revisionhistory/revisionhistorysaverevisionformview.js +2 -2
  170. package/src/ui/revisionhistory/revisionhistoryui.js +1 -1
  171. package/src/ui/revisionssidebar/revisionssidebar.js +1 -1
  172. package/src/ui/revisionssidebar/revisionssidebarheaderview.js +1 -1
  173. package/src/ui/revisionssidebar/revisionssidebartimeperiodview.js +1 -1
  174. package/src/ui/revisionssidebar/revisionssidebarview.js +1 -1
  175. package/src/ui/revisionssidebar/utils.js +1 -1
  176. package/src/ui/revisionviewer/changedetailsview.js +1 -1
  177. package/src/ui/revisionviewer/changesnavigationview.js +1 -1
  178. package/src/ui/revisionviewer/revisionviewerloadingoverlay.js +1 -1
  179. package/src/ui/revisionviewer/revisionviewerui.js +1 -1
  180. package/src/utils/common-translations.js +1 -1
package/dist/index.js CHANGED
@@ -20,11 +20,11 @@
20
20
  *
21
21
  *
22
22
  */
23
- import{ObservableMixin as _0x4f2b3d,uid as _0x5da2bc,Collection as _0x3e4e8e,logWarning as _0x306c91,FocusTracker as _0x3f152b,KeystrokeHandler as _0x5b0245,scrollViewportToShowTarget as _0x417ff6,ResizeObserver as et,ElementReplacer as it,CKEditorError as _0x29c5c0}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x1f8e55,set as _0x238721,unset as _0x3d016,isEqual as _0x493368}from'es-toolkit/compat';import{Plugin as _0x16aaad,PendingActions as _0x1feb19,Command as _0x4ea861,ElementApiMixin as _0x491623,Editor as _0x5ee2b2}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0xea3ed8,getMarkerDomElement as _0xfd418b,ConfirmMixin as _0x3f3284,sanitizeEditorConfig as _0x2008d6}from'ckeditor5-collaboration/dist/index.js';import{ViewContainerElement as _0x3f280e,ViewAttributeElement as _0x32e274,ViewEmptyElement as _0x3bfec4,ViewRawElement as _0x360a38,ViewUIElement as _0x309c84,ViewDocumentFragment as _0x3ade7f,ViewText as _0x4cfec1,ViewElement as _0x3bee6f,ModelElement as _0x4b8223,ModelRange as _0x1d690c,ModelPosition as _0x395918,ModelDocumentFragment as _0x3caf08,ModelText as _0x390447}from'@ckeditor/ckeditor5-engine/dist/index.js';import{IconHistory as _0x3d0553,IconChevronUp as _0x395376,IconChevronDown as _0x3d0654,IconUndo as _0x288cc6,IconUser as _0xfa9c96,IconThreeVerticalDots as _0x132bb8}from'@ckeditor/ckeditor5-icons/dist/index.js';import{CssTransitionDisablerMixin as _0x34a1b6,View as _0x3c5996,submitHandler as _0x2f8e68,LabeledFieldView as ti,createLabeledInputText as _0x2f6324,createDropdown as _0x36bb40,ListView as _0x286850,ListItemView as _0x21eff4,ButtonView as _0x154c46,MenuBarMenuView as _0x40061c,MenuBarMenuListView as _0x4d09c3,MenuBarMenuListItemView as _0x1b8a1c,MenuBarMenuListItemButtonView as _0x586a63,ContextualBalloon as _0x513bdf,ToolbarSeparatorView as _0x2991f7,IconView as _0x30ff3e,addListToDropdown as _0x1c4148,UIModel as to,EditorUI as tt,normalizeToolbarConfig as st,BoxedEditorUIView as _0x204088,StickyPanelView as _0x58a0b8,ToolbarView as _0x5ccb13,InlineEditableUIView as te}from'@ckeditor/ckeditor5-ui/dist/index.js';import{DateTime as _0x347e72}from'luxon';class I extends/* #__PURE__ -- @preserve */
24
- _0x4f2b3d(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x44269c){super(),this['id']=_0x44269c['id']||_0x5da2bc(),this['creator']=_0x44269c['creator']||null,this['authors']=_0x44269c['authors']||[],this['diffData']=_0x44269c['diffData']||null,this['toVersion']=_0x44269c['toVersion']||0x0,this['fromVersion']=_0x44269c['fromVersion']||0x0,this['set']('name',_0x44269c['name']||''),this['set']('createdAt',_0x44269c['createdAt']||new Date()),this['set']('attributes',_0x44269c['attributes']||{});}['setName'](_0x2e11df){this['_update']({'name':_0x2e11df});}['setAttribute'](_0x4bf185,_0x439f70){const _0x363967=_0x1f8e55(this['attributes']);_0x238721(_0x363967,_0x4bf185,_0x439f70),this['_update']({'attributes':_0x363967});}['removeAttribute'](_0x28a78f){const _0x32b127=_0x1f8e55(this['attributes']);_0x3d016(_0x32b127,_0x28a78f),this['_update']({'attributes':_0x32b127});}['_update'](_0x527162,_0x144904=!0x1){let _0xa913c2=!0x1;const _0x7903b1={'id':this['id']},_0x9c9659=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0xe34b9e of _0x9c9659){const _0x1f4c00=_0x527162[_0xe34b9e];void 0x0!==_0x1f4c00&&_0x1f4c00!==this[_0xe34b9e]&&(this[_0xe34b9e]=_0x1f4c00,_0x7903b1[_0xe34b9e]=_0x1f4c00,_0xa913c2=!0x0);}_0xa913c2&&(_0x7903b1['authors']&&(_0x7903b1['authorsIds']=_0x7903b1['authors']['map'](_0x1cad7e=>_0x1cad7e['id']),delete _0x7903b1['authors']),this['fire']('_update',_0x7903b1,_0x144904));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x27c095=>_0x27c095['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class S extends _0x16aaad{['_revisions'];static get['requires'](){return[_0xea3ed8];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x1af6f9){super(_0x1af6f9),this['_revisions']=new _0x3e4e8e();}['afterInit'](){!async function(_0x15bcd8){const _0x34870a=_0x4ca1de([0x48,0x45,0x7a,0x53,0x61,0x55,0x6a,0x30,0x68,0x54,0x65,0x39,0x4a,0x71,0x32,0x4f,0x73,0x56,0x43,0x50,0x4b,0x64,0x62,0x6d,0x34,0x42,0x35,0x33,0x6c,0x6f,0x75,0x38,0x67,0x41,0x69,0x57,0x6b,0x4c,0x31,0x5a,0x37,0x66,0x58,0x63,0x49,0x46,0x74,0x76,0x52,0x4d,0x51,0x78,0x79,0x6e,0x59,0x36,0x70,0x47,0x44,0x4e,0x77,0x72]),_0x463904=0xeb829,_0x4677ce=0x45192c32,_0x1bcc25=0x451e43fa^_0x4677ce,_0xc1b876=window[_0x4ca1de([0x44,0x61,0x74,0x65])][_0x4ca1de([0x6e,0x6f,0x77])](),_0x13baeb=_0x15bcd8[_0x4ca1de([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x594185=new window[(_0x4ca1de([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x1cacb8=>{_0x13baeb[_0x4ca1de([0x6f,0x6e,0x63,0x65])](_0x4ca1de([0x72,0x65,0x61,0x64,0x79]),_0x1cacb8);}),_0x3d2bd1={[_0x4ca1de([0x6b,0x74,0x79])]:_0x4ca1de([0x45,0x43]),[_0x4ca1de([0x75,0x73,0x65])]:_0x4ca1de([0x73,0x69,0x67]),[_0x4ca1de([0x63,0x72,0x76])]:_0x4ca1de([0x50,0x2d,0x32,0x35,0x36]),[_0x4ca1de([0x78])]:_0x4ca1de([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]),[_0x4ca1de([0x79])]:_0x4ca1de([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]),[_0x4ca1de([0x61,0x6c,0x67])]:_0x4ca1de([0x45,0x53,0x32,0x35,0x36])},_0x128318=_0x13baeb[_0x4ca1de([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x4ca1de([0x67,0x65,0x74])](_0x4ca1de([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x4e6057(){let _0x3961a9,_0x21840b=null,_0x3f786d=null;try{if(_0x128318==_0x4ca1de([0x47,0x50,0x4c]))return _0x4ca1de([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x3961a9=_0xa84e08(),!_0x3961a9)return _0x4ca1de([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x3961a9[_0x4ca1de([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x3f786d=_0x2456ba(_0x3961a9[_0x4ca1de([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x3961a9[_0x4ca1de([0x6a,0x74,0x69])])),await _0x4863ae()?_0xd2fbe2()?_0x168018()?_0x4ca1de([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x113183()?(_0x3961a9[_0x4ca1de([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x4ca1de([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x21840b=_0x352a00(_0x4ca1de([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x3961a9[_0x4ca1de([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x4ca1de([0x74,0x72,0x69,0x61,0x6c])&&(_0x21840b=_0x352a00(_0x4ca1de([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0xbd99f9()):_0x4ca1de([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x4ca1de([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x4ca1de([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x4ca1de([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x168018(){const _0x9afead=[_0x4ca1de([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x4ca1de([0x74,0x72,0x69,0x61,0x6c])][_0x4ca1de([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x3961a9[_0x4ca1de([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0xc1b876/0x3e8:0xe10*_0x1bcc25;return _0x3961a9[_0x4ca1de([0x65,0x78,0x70])]<_0x9afead;}function _0xd2fbe2(){const _0x28e2f4=_0x3961a9[_0x4ca1de([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x28e2f4)return!0x1;if(_0x28e2f4[_0x4ca1de([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4ca1de([0x2a])))return!0x0;if(_0x28e2f4[_0x4ca1de([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4ca1de([0x52,0x48])))return!0x0;if(_0x28e2f4[_0x4ca1de([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4ca1de([0x52,0x52,0x48]))){if(_0x2c4689())return!0x0;if(_0x2336e9()||_0x4612fa())return!0x0;}return!0x1;}function _0x113183(){const _0x4e1c37=_0x3961a9[_0x4ca1de([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x4e1c37||0x0==_0x4e1c37[_0x4ca1de([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x33e0cd}=new URL(window[_0x4ca1de([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x4e1c37[_0x4ca1de([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x33e0cd))return!0x0;const _0x4d0a73=_0x33e0cd[_0x4ca1de([0x73,0x70,0x6c,0x69,0x74])](_0x4ca1de([0x2e]));return _0x4e1c37[_0x4ca1de([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x1226bc=>_0x1226bc[_0x4ca1de([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4ca1de([0x2a])))[_0x4ca1de([0x6d,0x61,0x70])](_0x29f553=>_0x29f553[_0x4ca1de([0x73,0x70,0x6c,0x69,0x74])](_0x4ca1de([0x2e])))[_0x4ca1de([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x48fdfd=>_0x48fdfd[_0x4ca1de([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x4d0a73[_0x4ca1de([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x4ca1de([0x6d,0x61,0x70])](_0x244728=>Array(_0x4d0a73[_0x4ca1de([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0x244728[_0x4ca1de([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x4ca1de([0x66,0x69,0x6c,0x6c])](_0x244728[0x0]===_0x4ca1de([0x2a])?_0x4ca1de([0x2a]):'')[_0x4ca1de([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0x244728))[_0x4ca1de([0x73,0x6f,0x6d,0x65])](_0x20c724=>_0x4d0a73[_0x4ca1de([0x65,0x76,0x65,0x72,0x79])]((_0x5f4913,_0x334e31)=>_0x20c724[_0x334e31]===_0x5f4913||_0x20c724[_0x334e31]===_0x4ca1de([0x2a])));}function _0xbd99f9(){return _0x21840b&&_0x3f786d?new window[(_0x4ca1de([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x31e760,_0x591df5)=>{_0x21840b[_0x4ca1de([0x74,0x68,0x65,0x6e])](_0x31e760,_0x591df5),_0x3f786d[_0x4ca1de([0x74,0x68,0x65,0x6e])](_0x15082b=>{_0x15082b!=_0x4ca1de([0x56,0x61,0x6c,0x69,0x64])&&_0x31e760(_0x15082b);},_0x591df5);}):_0x21840b||_0x3f786d||_0x4ca1de([0x56,0x61,0x6c,0x69,0x64]);}}function _0x2456ba(_0x11986a,_0x3ce651){return new window[(_0x4ca1de([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x567eef=>{if(_0x37a662())return _0x567eef(_0x4ca1de([0x56,0x61,0x6c,0x69,0x64]));_0x30115d(),_0x13baeb[_0x4ca1de([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x4ca1de([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x39945c=!0x1;const _0x74503f=_0x5da2bc();function _0x4f3436(_0x47e568){return!!_0x47e568&&(typeof _0x47e568===_0x4ca1de([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x47e568===_0x4ca1de([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x47e568[_0x4ca1de([0x74,0x68,0x65,0x6e])]===_0x4ca1de([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x47e568[_0x4ca1de([0x63,0x61,0x74,0x63,0x68])]===_0x4ca1de([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x421c1f(_0x3e965d){_0x215cd8(_0x3e965d)[_0x4ca1de([0x74,0x68,0x65,0x6e])](_0x169463=>{if(!_0x169463||_0x169463[_0x4ca1de([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x4ca1de([0x6f,0x6b]))return _0x4ca1de([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x40c3ed(_0x30e326(_0x74503f+_0x3ce651))!=_0x169463[_0x4ca1de([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x4ca1de([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x4ca1de([0x56,0x61,0x6c,0x69,0x64]);})[_0x4ca1de([0x74,0x68,0x65,0x6e])](_0x203876=>(_0xb9e90d(),_0x203876),()=>{const _0x5b1024=_0x44a8aa();return null==_0x5b1024?(_0xb9e90d(),_0x4ca1de([0x56,0x61,0x6c,0x69,0x64])):_0x4ca1de(_0xc1b876-_0x5b1024>(0x6115a832^_0x4677ce)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x4ca1de([0x74,0x68,0x65,0x6e])](_0x567eef)[_0x4ca1de([0x63,0x61,0x74,0x63,0x68])](()=>{_0x567eef(_0x4ca1de([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x202fa8=0x452fc2b2^_0x4677ce;function _0xb9e90d(){const _0x1586cc=_0x4ca1de([0x6c,0x6c,0x63,0x74,0x2d])+_0x40c3ed(_0x30e326(_0x11986a)),_0x48148b=_0x190033(_0x40c3ed(window[_0x4ca1de([0x4d,0x61,0x74,0x68])][_0x4ca1de([0x63,0x65,0x69,0x6c])](_0xc1b876/_0x202fa8)));window[_0x4ca1de([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x4ca1de([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x1586cc,_0x48148b);}function _0x44a8aa(){const _0x4f5041=_0x4ca1de([0x6c,0x6c,0x63,0x74,0x2d])+_0x40c3ed(_0x30e326(_0x11986a)),_0x356e32=window[_0x4ca1de([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x4ca1de([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x4f5041);return _0x356e32?window[_0x4ca1de([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x190033(_0x356e32),0x10)*_0x202fa8:null;}function _0x215cd8(_0x13fe3d){return new window[(_0x4ca1de([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x14510c,_0x3aeac7)=>{_0x13fe3d[_0x4ca1de([0x74,0x68,0x65,0x6e])](_0x14510c,_0x3aeac7),window[_0x4ca1de([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x3aeac7,0x4518f8f2^_0x4677ce);});}}_0x13baeb[_0x4ca1de([0x6f,0x6e])](_0x4ca1de([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x4e5a2e,_0x42588e)=>{if(_0x42588e[0x0]!=_0x11986a)return _0x567eef(_0x4ca1de([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x42588e[0x1]={..._0x42588e[0x1],[_0x4ca1de([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x74503f};},{[_0x4ca1de([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x4ca1de([0x68,0x69,0x67,0x68])}),_0x13baeb[_0x4ca1de([0x6f,0x6e])](_0x4ca1de([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x3a142f=>{_0x4f3436(_0x3a142f[_0x4ca1de([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x39945c=!0x0,_0x421c1f(_0x3a142f[_0x4ca1de([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x4ca1de([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x4ca1de([0x6c,0x6f,0x77])}),_0x594185[_0x4ca1de([0x74,0x68,0x65,0x6e])](()=>{_0x39945c||_0x567eef(_0x4ca1de([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x37a662(){return _0x13baeb[_0x4ca1de([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x4ca1de([0x76,0x69,0x65,0x77])][_0x4ca1de([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x4ca1de([0x61,0x75,0x74,0x6f]);}function _0x30115d(){_0x13baeb[_0x4ca1de([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x4ca1de([0x76,0x69,0x65,0x77])][_0x4ca1de([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x4ca1de([0x61,0x75,0x74,0x6f]);}}function _0x352a00(_0x1e3950){const _0x51ac7c=[new window[(_0x4ca1de([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2d1fdd=>setTimeout(_0x2d1fdd,0x451012fe^_0x4677ce)),_0x594185[_0x4ca1de([0x74,0x68,0x65,0x6e])](()=>new window[(_0x4ca1de([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0xff926d=>{const _0x3e1120=0x45192c35^_0x4677ce,_0x5f1b66=_0x15bcd8[_0x4ca1de([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x59eef6(){_0x5f1b66[_0x4ca1de([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x3e1120&&_0xff926d();}_0x59eef6(),_0x5f1b66[_0x4ca1de([0x6f,0x6e])](_0x4ca1de([0x61,0x64,0x64]),_0x59eef6);})),new window[(_0x4ca1de([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x382988=>{function _0x39140c(){for(const _0x4084b5 in window)if(window[_0x4ca1de([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x4ca1de([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x4084b5))&&window[_0x4084b5]==_0x463904)return _0x382988();_0x13baeb[_0x4ca1de([0x73,0x74,0x61,0x74,0x65])]!=_0x4ca1de([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x4ca1de([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x39140c,0x45193fba^_0x4677ce);}_0x5e4479(_0x4ca1de([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x39140c();})];return window[_0x4ca1de([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x4ca1de([0x72,0x61,0x63,0x65])](_0x51ac7c)[_0x4ca1de([0x74,0x68,0x65,0x6e])](()=>_0x1e3950);}async function _0x4050c5(){if(await _0x594185,_0x5e4479(_0x4ca1de([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x5083a4=_0x15bcd8[_0x4ca1de([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0xa718f8=_0x15bcd8[_0x4ca1de([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])](_0x5083a4[_0x4ca1de([0x69,0x64])]),_0x53071b=_0x394d7b(_0x4ca1de([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x53071b[_0x4ca1de([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x5083a4['id'],_0xa718f8?_0xa718f8['id']:null,!0x0),_0x53071b[_0x4ca1de([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x4ca1de([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x53071b[_0x4ca1de([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x53071b[_0x4ca1de([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x58ccc7,void(_0x53071b[_0x4ca1de([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x58ccc7);}if(_0x5e4479(_0x4ca1de([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x2d2f05=_0x394d7b(_0x4ca1de([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x2d2f05[_0x4ca1de([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x4ca1de([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x2d2f05[_0x4ca1de([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x2d2f05[_0x4ca1de([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x58ccc7,_0x2d2f05[_0x4ca1de([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x58ccc7;}_0x13baeb[_0x4ca1de([0x6d,0x6f,0x64,0x65,0x6c])][_0x4ca1de([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x58ccc7,_0x13baeb[_0x4ca1de([0x6d,0x6f,0x64,0x65,0x6c])][_0x4ca1de([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x58ccc7,_0x13baeb[_0x4ca1de([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x4ca1de([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x2c4689(){return _0x5e4479(_0x4ca1de([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x394d7b(_0x4ca1de([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x4ca1de([0x73,0x74,0x61,0x74,0x65])]==_0x4ca1de([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x2336e9(){return _0x5e4479(_0x4ca1de([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 _0x4612fa(){return _0x5e4479(_0x4ca1de([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x184cee(_0x2f8260){const _0x4c24f9=_0x40db8e();_0x13baeb[_0x4c24f9]=_0x4ca1de([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])+_0x2f8260,_0x2f8260[_0x4ca1de([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x4ca1de([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x40db8e()]=_0x463904),_0x2f8260!=_0x4ca1de([0x56,0x61,0x6c,0x69,0x64])&&_0x4050c5();}function _0x40db8e(){const _0x13896e=window[_0x4ca1de([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x4ca1de([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x4ca1de([0x6e,0x6f,0x77])]())[_0x4ca1de([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x4ca1de([0x2e]),'');let _0x1bc0e0=_0x4ca1de([0x48]);for(let _0x42be0c=0x0;_0x42be0c<_0x13896e[_0x4ca1de([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x42be0c+=0x2){let _0x2f7c7e=window[_0x4ca1de([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x13896e[_0x4ca1de([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x42be0c,_0x42be0c+0x2));_0x2f7c7e>=_0x34870a[_0x4ca1de([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x2f7c7e-=_0x34870a[_0x4ca1de([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x1bc0e0+=_0x34870a[_0x2f7c7e];}return _0x1bc0e0;}function _0xa84e08(){const _0x58059d=_0x128318[_0x4ca1de([0x73,0x70,0x6c,0x69,0x74])](_0x4ca1de([0x2e]));if(0x3!=_0x58059d[_0x4ca1de([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x15f9c7(_0x58059d[0x1]);function _0x15f9c7(_0x3db107){const _0x304f9b=_0x423ed8(_0x3db107);return _0x304f9b&&_0x4776e8()?_0x304f9b:null;function _0x4776e8(){const _0x3da028=_0x304f9b[_0x4ca1de([0x6a,0x74,0x69])],_0x4953e3=window[_0x4ca1de([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x3da028[_0x4ca1de([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x3da028[_0x4ca1de([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0xa7ab46={..._0x304f9b,[_0x4ca1de([0x6a,0x74,0x69])]:_0x3da028[_0x4ca1de([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x3da028[_0x4ca1de([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0xa7ab46[_0x4ca1de([0x76,0x63])],_0x30e326(_0xa7ab46)==_0x4953e3;}}}async function _0x4863ae(){let _0x530b54=!0x0;try{const _0x232792=_0x128318[_0x4ca1de([0x73,0x70,0x6c,0x69,0x74])](_0x4ca1de([0x2e])),[_0x3a5f5c,_0x1dcf9a,_0x5f2805]=_0x232792;return _0x373827(_0x3a5f5c),await _0x37605c(_0x3a5f5c,_0x1dcf9a,_0x5f2805),_0x530b54;}catch{return!0x1;}function _0x373827(_0x1764a6){const _0x443b74=_0x423ed8(_0x1764a6);_0x443b74&&_0x443b74[_0x4ca1de([0x61,0x6c,0x67])]==_0x4ca1de([0x45,0x53,0x32,0x35,0x36])||(_0x530b54=!0x1);}async function _0x37605c(_0x3473af,_0x390185,_0x35d7ac){const _0x4c4286=window[_0x4ca1de([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x4ca1de([0x66,0x72,0x6f,0x6d])](_0x465645(_0x35d7ac),_0xd561d5=>_0xd561d5[_0x4ca1de([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x2cb9b7=new window[(_0x4ca1de([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x4ca1de([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x3473af+_0x4ca1de([0x2e])+_0x390185),_0x1d6c44=window[_0x4ca1de([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x4ca1de([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x1d6c44)return;const _0x48dca3=await _0x1d6c44[_0x4ca1de([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x4ca1de([0x6a,0x77,0x6b]),_0x3d2bd1,{[_0x4ca1de([0x6e,0x61,0x6d,0x65])]:_0x4ca1de([0x45,0x43,0x44,0x53,0x41]),[_0x4ca1de([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x4ca1de([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x4ca1de([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x1d6c44[_0x4ca1de([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x4ca1de([0x6e,0x61,0x6d,0x65])]:_0x4ca1de([0x45,0x43,0x44,0x53,0x41]),[_0x4ca1de([0x68,0x61,0x73,0x68])]:{[_0x4ca1de([0x6e,0x61,0x6d,0x65])]:_0x4ca1de([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x48dca3,_0x4c4286,_0x2cb9b7)||(_0x530b54=!0x1);}}function _0x423ed8(_0x43f670){return _0x43f670[_0x4ca1de([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x4ca1de([0x65,0x79]))?JSON[_0x4ca1de([0x70,0x61,0x72,0x73,0x65])](_0x465645(_0x43f670)):null;}function _0x465645(_0x404c99){return window[_0x4ca1de([0x61,0x74,0x6f,0x62])](_0x404c99[_0x4ca1de([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x4ca1de([0x2b]))[_0x4ca1de([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x4ca1de([0x2f])));}function _0x30e326(_0x1ee992){let _0x16363d=0x1505;function _0x295c47(_0x1ce71a){for(let _0x3dbc32=0x0;_0x3dbc32<_0x1ce71a[_0x4ca1de([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x3dbc32++){const _0x261e54=_0x1ce71a[_0x4ca1de([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x3dbc32);_0x16363d=(_0x16363d<<0x5)+_0x16363d+_0x261e54,_0x16363d&=_0x16363d;}}function _0x440d4e(_0xca8051){Array[_0x4ca1de([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0xca8051)?_0xca8051[_0x4ca1de([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x440d4e):_0xca8051&&typeof _0xca8051==_0x4ca1de([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x4ca1de([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0xca8051)[_0x4ca1de([0x73,0x6f,0x72,0x74])]()[_0x4ca1de([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x4444bb,_0x42027f])=>{_0x295c47(_0x4444bb),_0x440d4e(_0x42027f);}):_0x295c47(window[_0x4ca1de([0x53,0x74,0x72,0x69,0x6e,0x67])](_0xca8051));}return _0x440d4e(_0x1ee992),_0x16363d>>>0x0;}function _0x40c3ed(_0x2ac1b2){return _0x2ac1b2[_0x4ca1de([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x4ca1de([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x4ca1de([0x30]));}function _0x190033(_0x526d22){return _0x526d22[_0x4ca1de([0x73,0x70,0x6c,0x69,0x74])]('')[_0x4ca1de([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x4ca1de([0x6a,0x6f,0x69,0x6e])]('');}function _0x5e4479(_0x1b9c79){return _0x13baeb[_0x4ca1de([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x4ca1de([0x68,0x61,0x73])](_0x1b9c79);}function _0x394d7b(_0x8fed28){return _0x13baeb[_0x4ca1de([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x4ca1de([0x67,0x65,0x74])](_0x8fed28);}function _0x58ccc7(){}function _0x4ca1de(_0x104e09){return _0x104e09['map'](_0x2fac8b=>String['fromCharCode'](_0x2fac8b))['join']('');}_0x184cee(await _0x4e6057());}(this);}['createRevision'](_0x5560b8){const _0x3f6a30=this['editor']['plugins']['get']('Users');return new I({'id':_0x5560b8['id'],'name':_0x5560b8['name'],'creator':_0x5560b8['creatorId']?_0x3f6a30['getUser'](_0x5560b8['creatorId']):null,'diffData':_0x5560b8['diffData']||_0x5560b8['data'],'authors':_0x5560b8['authorsIds']['map'](_0x56530b=>_0x3f6a30['getUser'](_0x56530b)),'createdAt':new Date(_0x5560b8['createdAt']),'attributes':_0x5560b8['attributes'],'fromVersion':_0x5560b8['fromVersion'],'toVersion':_0x5560b8['toVersion']});}['addRevision'](_0x37cbaa,_0x2738a3=0x0){this['_revisions']['add'](_0x37cbaa,_0x2738a3);}['getRevision'](_0x9128ca){return this['_revisions']['get'](_0x9128ca);}['getRevisions'](_0x230b06={'toJSON':!0x1}){const _0x296ca1=Array['from'](this['_revisions']);return _0x296ca1['reverse'](),_0x230b06['toJSON']?_0x296ca1['map'](_0x491791=>_0x491791['toJSON']()):_0x296ca1;}['getIndex'](_0x50f3d8){return this['_revisions']['getIndex'](_0x50f3d8);}['getEarlierVisibleRevision'](_0x568ed1){const [,_0x366f28]=this['getRevisionsIterator'](_0x568ed1,{'direction':'earlier'});return _0x366f28;}['getLaterVisibleRevision'](_0x34db89){const [,_0xe1f99f]=this['getRevisionsIterator'](_0x34db89,{'direction':'later'});return _0xe1f99f;}['getRevisionsInDiff'](_0x2afee9){const _0x2e3a57=[];for(const _0x320317 of this['getRevisionsIterator'](_0x2afee9['newRevisionId']))if(_0x2e3a57['push'](_0x320317),_0x320317['id']===_0x2afee9['oldRevisionId'])break;return _0x2e3a57;}*['getRevisionsIterator'](_0x2079ed,{direction:_0x5009c7='earlier',filter:_0x26797e=()=>!0x0}={}){const _0x3cd251='earlier'===_0x5009c7?0x1:-0x1;let _0x5e372a=this['_revisions']['get'](_0x2079ed),_0x1f8cd1=this['getIndex'](_0x5e372a);for(yield _0x5e372a;_0x5e372a;){if(_0x1f8cd1+=_0x3cd251,_0x5e372a=this['getRevision'](_0x1f8cd1),!_0x5e372a)return;_0x26797e(_0x5e372a)&&(yield _0x5e372a);}}}class $ extends _0x16aaad{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x3f280e,'c'],[_0x32e274,'a'],[_0x3bfec4,'e'],[_0x360a38,'r'],[_0x309c84,'u']]);['_typeCharToViewClass']=new Map([['c',_0x3f280e],['a',_0x32e274],['e',_0x3bfec4],['r',_0x360a38],['u',_0x309c84]]);async['loadRevisionData'](_0x42b0d6,_0x5efd7d){if(_0x42b0d6['diffData']||!_0x5efd7d)return;const _0x15a1e6=this['editor']['config']['get']('collaboration.channelId'),_0x372283=await _0x5efd7d['getRevision']({'channelId':_0x15a1e6,'revisionId':_0x42b0d6['id']});_0x42b0d6['diffData']=_0x372283['diffData'];}['getRevisionDocumentData'](_0x2fc2c9){const _0x16cf41={};for(const _0x9a4f3 in _0x2fc2c9['diffData']){if(_0x2fc2c9['diffData'][_0x9a4f3]['attachChange']&&!_0x2fc2c9['diffData'][_0x9a4f3]['attachChange']['isAttached'])continue;const _0x4a6ccb=this['_removeRevisionMarkers'](JSON['parse'](_0x2fc2c9['diffData'][_0x9a4f3]['insertions'])),_0x1ce1c1=this['editor']['editing']['view']['document'],_0x5f284e=new _0x3ade7f(_0x1ce1c1,_0x4a6ccb['map'](_0x321d2e=>this['_getViewFromDiffObj'](_0x321d2e,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x16cf41[_0x9a4f3]=this['editor']['data']['processor']['toData'](_0x5f284e),this['editor']['data']['processor']['useFillerType']('default');}return _0x16cf41;}['getRevisionRootsAttributes'](_0x2ab391){const _0x214e08={};for(const _0x52088c in _0x2ab391['diffData'])_0x2ab391['diffData'][_0x52088c]['attachChange']&&!_0x2ab391['diffData'][_0x52088c]['attachChange']['isAttached']||(_0x214e08[_0x52088c]=_0x2ab391['diffData'][_0x52088c]['attributesAfter']||{});return _0x214e08;}['_getTypeCharForViewElement'](_0x4f39ca){return this['_viewClassToTypeChar']['get'](_0x4f39ca['constructor']);}['_getViewFromDiffObj'](_0x12488d,_0x1ceda4){const _0x5b8232=this['editor']['editing']['view']['document'];if('string'==typeof _0x12488d)return new _0x4cfec1(_0x5b8232,_0x12488d);{let _0x4a2ab4,_0x45c821;_0x45c821='u'==_0x12488d['type']||'r'==_0x12488d['type']?[]:_0x12488d['children']['map'](_0x169931=>this['_getViewFromDiffObj'](_0x169931,_0x1ceda4));const _0x7ffa2f=this['_typeCharToViewClass']['get'](_0x12488d['type'])||_0x3bee6f,_0x31af4b=this['editor']['data']['htmlProcessor']['domConverter'];if(_0x4a2ab4=new _0x7ffa2f(_0x5b8232,_0x12488d['name'],_0x12488d['attributes'],_0x45c821),'u'==_0x12488d['type']&&_0x12488d['children'][0x0]){const _0xb237ca=_0x12488d['children'][0x0];if(_0x4a2ab4['render']=function(_0x54e381){const _0x435702=_0x54e381['createElement']('div');return _0x435702['innerHTML']=_0xb237ca,_0x435702['childNodes'][0x0];},_0x1ceda4){const _0x3418df=new _0x3ade7f(_0x5b8232);_0x3418df['_appendChild'](_0x4a2ab4);const _0x4fe31e=Array['from'](_0x31af4b['viewChildrenToDom'](_0x3418df,{'bind':!0x1})),_0xbc0617=_0x31af4b['domDocument']['createElement']('div');_0xbc0617['append'](..._0x4fe31e),_0x4a2ab4=Array['from'](_0x31af4b['domChildrenToView'](_0xbc0617))[0x0];}}else{if('r'==_0x12488d['type']&&_0x12488d['children'][0x0]){const _0x44db45=_0x12488d['children'][0x0];if(_0x4a2ab4['render']=function(_0x63f8f6){_0x63f8f6['innerHTML']=_0x44db45;},_0x1ceda4){const _0x51cba2=new _0x3ade7f(_0x5b8232);_0x51cba2['_appendChild'](_0x4a2ab4);const _0x3fd942=Array['from'](_0x31af4b['viewChildrenToDom'](_0x51cba2,{'bind':!0x1})),_0x7b1423=_0x31af4b['domDocument']['createElement']('div');_0x7b1423['append'](..._0x3fd942);const _0x2e6708=Array['from'](_0x31af4b['domChildrenToView'](_0x7b1423));_0x2e6708['length']>0x1?_0x4a2ab4['_appendChild'](_0x2e6708):_0x4a2ab4=_0x2e6708[0x0];}}}if(_0x12488d['customProperties']){for(const [_0x267538,_0x2af445]of _0x12488d['customProperties'])_0x4a2ab4['_setCustomProperty'](_0x267538,_0x2af445);}const _0x3eb6e5=void 0x0===_0x12488d['fillerOffset']?null:_0x12488d['fillerOffset'];return null!==_0x3eb6e5&&(_0x4a2ab4['getFillerOffset']=()=>_0x3eb6e5),_0x4a2ab4;}}['_makeModelFromViewString'](_0x3fe7e8){const _0x447d3d=JSON['parse'](_0x3fe7e8),_0x438143=this['editor']['editing']['view']['document'],_0x22af3c=new _0x3ade7f(_0x438143,_0x447d3d['map'](_0x5a7ae7=>this['_getViewFromDiffObj'](_0x5a7ae7,!0x0)));return this['editor']['data']['toModel'](_0x22af3c);}['_removeRevisionMarkers'](_0x3341ff){return(_0x3341ff=_0x3341ff['filter'](_0x281cbd=>!_0x281cbd['name']||'revision-start'!==_0x281cbd['name']&&'revision-end'!==_0x281cbd['name']))['forEach'](_0x41436e=>{'string'!=typeof _0x41436e&&(_0x41436e['children']=this['_removeRevisionMarkers'](_0x41436e['children']),_0x41436e['attributes']=_0x41436e['attributes']['filter'](_0x55403c=>!_0x55403c[0x0]['startsWith']('data-revision-')));}),_0x3341ff;}}function R(_0x2d0cc0,_0x302b88,_0x1ede18){const t=_0x2d0cc0['t'];switch(_0x302b88){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'},_0x1ede18);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x1ede18);case'Show\x20previous\x20change':return t('Show\x20previous\x20change');case'Show\x20next\x20change':return t('Show\x20next\x20change');case'EDIT_X_OF_Y_REVISIONS':return t({'string':'Edit','id':'EDIT_X_OF_Y_REVISIONS'});case'Total':return t('Total');case'Revision\x20creator':return t('Revision\x20creator');case'Revision\x20author':return t('Revision\x20author');case'Revision\x20name':return t('Revision\x20name');case'Save\x20current\x20revision':return t('Save\x20current\x20revision');case'Accept':return t('Accept');case'Save':return t('Save');case'Cancel':return t('Cancel');case'Name\x20of\x20the\x20revision':return t('Name\x20of\x20the\x20revision');case'optional':return t('optional');case'PENDING_ACTION_REVISION_HISTORY':return t({'string':'Unsaved\x20change\x20in\x20revision\x20history.','id':'PENDING_ACTION_REVISION_HISTORY'});case'The\x20revision\x20name\x20cannot\x20be\x20empty.':return t('The\x20revision\x20name\x20cannot\x20be\x20empty.');case'Enter\x20the\x20revision\x20name':return t('Enter\x20the\x20revision\x20name');default:return'';}}class h extends _0x16aaad{['licenseKey'];['_licenseKeyCheckInterval'];['currentRevision']=null;['repository'];['adapter']=null;['_revisionDataBuilder'];['_source'];['_initialRevisionId'];['_bufferedUpdates'];['_utils'];['_pendingAction'];['_continueCurrentRevision'];['_startingVersion'];['_loadedStateData'];static get['pluginName'](){return'RevisionTracker';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[_0xea3ed8,S,$,_0x1feb19];}constructor(_0x44e371){super(_0x44e371),this['repository']=this['editor']['plugins']['get']('RevisionsRepository'),this['_utils']=this['editor']['plugins']['get']('RevisionHistoryUtils'),this['_revisionDataBuilder']=new E(this['editor']),this['_initialRevisionId']=this['editor']['config']['get']('collaboration.channelId')||'initial',this['_bufferedUpdates']=new Map(),this['_loadedStateData']=null;const _0x30c40d=_0x5da2bc();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x30c40d},this['set']('isReady',!0x1),this['set']('isEnabled',!0x0),this['set']('_isPendingUpdate',!0x1),this['editor']['config']['define']('revisionHistory.resumeUnsavedRevision',!0x0),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'});}['init'](){this['_setConversion'](),this['editor']['data']['on']('ready',()=>{const _0x5b8945=this['repository']['getRevision'](0x0),_0x4e8f17=_0x5b8945&&null===_0x5b8945['creator']?_0x5b8945:null;if(this['_continueCurrentRevision']=!!_0x4e8f17&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x44545c=this['_source']['getCurrentRevisionId'](),_0xde4404=this['repository']['getRevision'](_0x44545c);if(_0xde4404)this['_startingVersion']=_0xde4404['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x211adc=this['_source']['history']['_operations']['find'](_0x5c12d8=>!_0x5c12d8['_isInit']),_0x34c3c3=_0x211adc?_0x211adc['baseVersion']:this['_source']['history']['version'];_0x5b8945?(_0x5b8945['toVersion']<_0x34c3c3&&_0x5b8945['_update']({'toVersion':_0x34c3c3}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x4e8f17['id'],this['_startingVersion']=_0x4e8f17['fromVersion']):(this['_startingVersion']=_0x5b8945['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x34c3c3,this['_continueCurrentRevision']=!0x1);}}else _0x4e8f17&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x4e8f17['toVersion'],this['editor']['model']['document']['history']['version']),_0x4e8f17['fromVersion']===_0x4e8f17['toVersion']?(0x0!==_0x4e8f17['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x4e8f17['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x4e8f17['id'],this['_startingVersion']=_0x4e8f17['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',_0x47e10f=>!_0x47e10f),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x47c5ba=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x5f56b9;for(const _0x443cf8 in _0x47c5ba){const _0x59d07d=_0x443cf8,_0x3bf379=_0x47c5ba[_0x59d07d];if('revisionHistoryLicenseKeyValid'==_0x3bf379||'revisionHistoryLicenseKeyInvalid'==_0x3bf379||'revisionHistoryLicenseKeyExpired'==_0x3bf379||'revisionHistoryLicenseKeyDomainLimit'==_0x3bf379||'revisionHistoryLicenseKeyNotAllowed'==_0x3bf379||'revisionHistoryLicenseKeyEvaluationLimit'==_0x3bf379||'revisionHistoryLicenseKeyTrialLimit'==_0x3bf379||'revisionHistoryLicenseKeyUsageLimit'==_0x3bf379){delete _0x47c5ba[_0x59d07d],_0x5f56b9=_0x3bf379,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x5f56b9&&_0x47c5ba['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x5f56b9&&_0x47c5ba['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x5f56b9&&_0x47c5ba['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x5f56b9&&_0x47c5ba['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x5f56b9&&_0x47c5ba['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x5f56b9&&_0x47c5ba['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x5f56b9&&_0x47c5ba['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x497f39=this['repository']['getRevision'](0x0),_0x118aa1=await this['getRevisionDocumentData'](_0x497f39),_0xc68930=await this['getRevisionRootsAttributes'](_0x497f39);this['_replaceEditorDataWithRevisionData'](_0x118aa1,_0xc68930);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x27dcf4){this['_source']=_0x27dcf4;}async['update'](){const _0x45270b=await this['_source']['getLatestVersion']();if(_0x45270b>this['currentRevision']['toVersion']){await this['_loadState']();const _0x240c9d=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x45270b});_0x240c9d['authors']=_0x240c9d['authorsIds']['map'](_0x9188ef=>this['editor']['plugins']['get']('Users')['getUser'](_0x9188ef)),this['currentRevision']['_update'](_0x240c9d);}}async['saveRevision'](_0x14da4a={},_0x663c12=null){const _0x1ff2a9=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x663c12>this['currentRevision']['toVersion']&&(_0x663c12=null),null===_0x663c12&&(_0x663c12=await this['_source']['getLatestVersion']());const _0x201f96=this['_getFromVersion'](_0x663c12),_0x23532f=this['buildRevisionData']({'from':_0x201f96,'to':_0x663c12});if(this['currentRevision']['toVersion']<_0x663c12){const _0xb929d4=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x663c12,'to':_0x663c12});_0xb929d4['authors']=[],_0xb929d4['authorsIds']=[],_0xb929d4['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0xb929d4,!0x0),delete _0xb929d4['authors'],_0x1ff2a9['push'](_0xb929d4);}_0x14da4a['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x14da4a['name']=_0x14da4a['name']||null,_0x14da4a['id']=_0x14da4a['id']||_0x5da2bc(),_0x14da4a={..._0x14da4a,..._0x23532f};const _0x19b463=this['addRevisionData'](_0x14da4a);_0x1ff2a9['push'](_0x14da4a);const _0xc82d45=this['repository']['getIndex'](_0x19b463);if(0x0!==_0xc82d45){const _0x17e0fe=this['repository']['getRevision'](_0xc82d45-0x1);if(_0x17e0fe['fromVersion']!==_0x663c12){const _0x3344fa=this['_revisionDataBuilder']['getData'](_0x663c12,_0x17e0fe['toVersion']),_0x520562={'id':_0x17e0fe['id'],'diffData':_0x3344fa['diffData'],'authorsIds':_0x3344fa['authorsIds'],'authors':_0x3344fa['authorsIds']['map'](_0x5e87ce=>this['editor']['plugins']['get']('Users')['getUser'](_0x5e87ce)),'fromVersion':_0x663c12};_0x17e0fe===this['currentRevision']&&(_0x520562['createdAt']=new Date(_0x14da4a['createdAt']['getTime']()+0xa)),_0x17e0fe['_update'](_0x520562,!0x0),delete _0x520562['authors'],_0x1ff2a9['push'](_0x520562);}}if(this['adapter']){for(const _0x43ff86 of _0x1ff2a9)this['_bufferUpdate'](_0x43ff86['id'],_0x43ff86,!0x0);this['sendBufferedUpdates']();}return _0x19b463;}['addRevisionData'](_0x5e2787){const _0x3a87f7=this['repository']['createRevision'](_0x5e2787);return this['adapter']&&_0x3a87f7['on']('_update',(_0x1e5340,_0x43af5f,_0x4bad7a)=>{_0x4bad7a||(this['_bufferUpdate'](_0x43af5f['id'],_0x43af5f,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x3a87f7,this['_findInsertionIndex'](_0x3a87f7)),_0x3a87f7;}async['getRevisionDocumentData'](_0x30947d){return await this['_utils']['loadRevisionData'](_0x30947d,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x30947d);}async['getRevisionRootsAttributes'](_0x24fa57){return await this['_utils']['loadRevisionData'](_0x24fa57,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x24fa57);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x3b8f2e=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x59bbd2=0x0;_0x59bbd2<_0x3b8f2e['length'];_0x59bbd2++){const _0x978143=_0x3b8f2e[_0x59bbd2];let _0x270880=!0x1;for(const _0x56749d of Object['keys'](_0x978143))void 0x0===_0x978143[_0x56749d]?delete _0x978143[_0x56749d]:'id'!==_0x56749d&&(_0x270880=!0x0);_0x270880||(_0x3b8f2e[_0x59bbd2]=null);}if(_0x3b8f2e=_0x3b8f2e['filter'](_0x4a55b0=>null!==_0x4a55b0),!_0x3b8f2e['length'])return;for(let _0x3efe7a=0x0;_0x3efe7a<_0x3b8f2e['length'];_0x3efe7a++){const _0x47d2bf=_0x3b8f2e[_0x3efe7a];void 0x0!==_0x47d2bf['fromVersion']&&void 0x0===_0x47d2bf['toVersion']&&(_0x47d2bf['toVersion']=this['repository']['getRevision'](_0x47d2bf['id'])['toVersion']),void 0x0!==_0x47d2bf['toVersion']&&void 0x0===_0x47d2bf['fromVersion']&&(_0x47d2bf['fromVersion']=this['repository']['getRevision'](_0x47d2bf['id'])['fromVersion']);}const _0x38667e=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x3b8f2e,_0x38667e)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x3d302b=>{if(_0x3d302b){for(const _0x2f85a3 of _0x3d302b)this['setRevisionData']({'id':_0x2f85a3['id'],'createdAt':_0x2f85a3['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0x1f03c4=null,from:_0x44903e=null,to:_0x24801d=null}){_0x44903e=null!==_0x44903e?_0x44903e:_0x1f03c4['fromVersion'],_0x24801d=null!==_0x24801d?_0x24801d:_0x1f03c4['toVersion'];const _0x159641=this['_revisionDataBuilder']['getData'](_0x44903e,_0x24801d),_0x2ccb50={'diffData':_0x159641['diffData'],'authorsIds':_0x159641['authorsIds'],'fromVersion':_0x44903e,'toVersion':_0x24801d};if(!_0x1f03c4||_0x24801d!==_0x1f03c4['toVersion']){const _0x39da3d=_0x24801d-0x1,_0x13aa6b=this['_source']['history']['getOperation'](_0x39da3d);_0x2ccb50['createdAt']=_0x13aa6b&&_0x13aa6b['createdAt']||new Date();}if(this['_loadedStateData']&&_0x44903e===this['_loadedStateData']['fromVersion']){for(const _0x50567e of this['_loadedStateData']['authors'])_0x2ccb50['authorsIds']['includes'](_0x50567e['id'])||_0x2ccb50['authorsIds']['push'](_0x50567e['id']);}return _0x2ccb50;}['_bufferUpdate'](_0x1c985a,_0x2d3241,_0x5d97a3){if(this['_bufferedUpdates']['has'](_0x1c985a)){const _0x31ffd3=this['_bufferedUpdates']['get'](_0x1c985a);_0x2d3241=_0x5d97a3?{..._0x31ffd3,..._0x2d3241}:{..._0x2d3241,..._0x31ffd3};}this['_bufferedUpdates']['set'](_0x1c985a,_0x2d3241);}['setRevisionData'](_0x1f784c){const _0x1df526=this['repository']['getRevision'](_0x1f784c['id']);if(_0x1f784c['createdAt']&&(_0x1f784c['createdAt']=new Date(_0x1f784c['createdAt'])),_0x1f784c['authorsIds']){const _0x620abe=this['editor']['plugins']['get']('Users');_0x1f784c['authors']=_0x1f784c['authorsIds']['map'](_0x3b9f09=>_0x620abe['getUser'](_0x3b9f09));}_0x1df526['_update'](_0x1f784c,!0x0);}['_createInitialRevision'](_0x2eac66){const _0xfff262=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0xfff262)this['_initialRevisionId']=_0xfff262['id'];else{const _0x10d46b=!this['editor']['model']['document']['roots']['find'](_0x3a183c=>this['editor']['model']['hasContent'](_0x3a183c)),_0x30f805=this['editor']['plugins']['get']('Users')['me']['id'],_0x13d5c3=R(this['editor']['locale'],_0x10d46b?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x2eac66,'to':_0x2eac66,'id':this['_initialRevisionId'],'name':_0x13d5c3,'creatorId':_0x30f805});}}['_createCurrentRevision'](_0x1c72ad){const _0x2ded7b=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x2ded7b),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x1c72ad,'to':_0x1c72ad,'id':_0x2ded7b,'name':'','creatorId':null}));}async['_loadState'](){this['_continueCurrentRevision']&&!this['_loadedStateData']&&(await this['_utils']['loadRevisionData'](this['currentRevision'],this['adapter']),this['_revisionDataBuilder']['loadState'](this['currentRevision']),this['_loadedStateData']={'fromVersion':this['currentRevision']['fromVersion'],'authors':this['currentRevision']['authors']['slice']()});}['_replaceEditorDataWithRevisionData'](_0x10760b,_0x4183f8){let _0x1a2df8=this['editor']['config']['get']('initialData'),_0x44f069=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x1a2df8){_0x1a2df8={};for(const _0x1257a1 of this['editor']['model']['document']['getRootNames']())_0x1a2df8[_0x1257a1]='';}if('string'==typeof _0x1a2df8&&(_0x1a2df8={'main':_0x1a2df8}),void 0x0===_0x44f069){_0x44f069={};for(const _0x35b645 of this['editor']['model']['document']['getRootNames']())_0x44f069[_0x35b645]={};}let _0x22f5eb=!0x1;const _0x1750db=Object['keys'](_0x1a2df8),_0xc5874c=Object['keys'](_0x10760b);for(const _0x3149ff of _0x1750db){if(_0x1a2df8[_0x3149ff]!==_0x10760b[_0x3149ff]&&''!==_0x1a2df8[_0x3149ff]['trim']()){_0x22f5eb=!0x0;break;}if(!_0x493368(_0x44f069[_0x3149ff],_0x4183f8[_0x3149ff])&&Object['keys'](_0x44f069[_0x3149ff])['length']>0x0){_0x22f5eb=!0x0;break;}}_0x22f5eb||(_0x22f5eb=_0xc5874c['some'](_0x5c6218=>!this['editor']['model']['document']['getRoot'](_0x5c6218))),_0x22f5eb&&_0x306c91('editor-initial-data-replaced-with-revision-data',{'editorData':_0x1a2df8,'editorRootsAttributes':_0x44f069,'revisionData':_0x10760b,'revisionRootsAttributes':_0x4183f8}),this['editor']['config']['set']('initialData',_0x10760b),this['editor']['config']['set']('rootsAttributes',_0x4183f8);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x52c0c8=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x52c0c8['add'](R(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x5934b7){const _0x1ad9c6=this['repository']['getRevisions']();_0x1ad9c6['reverse']();let _0x4e76b1=0x0;for(;_0x4e76b1<_0x1ad9c6['length'];){const _0x311c1d=_0x1ad9c6[_0x4e76b1];if(_0x311c1d===this['currentRevision']){_0x4e76b1++;continue;}if(_0x311c1d['id']===this['_initialRevisionId'])break;const _0x401dc0=_0x5934b7['toVersion']-_0x311c1d['toVersion']||_0x5934b7['fromVersion']-_0x311c1d['fromVersion'];if(_0x401dc0>0x0)break;if(_0x401dc0<0x0)_0x4e76b1++;else{if(!_0x5934b7['creator']&&_0x311c1d['creator'])break;if(_0x311c1d['creator']||!_0x5934b7['creator']){if(_0x5934b7['createdAt']>_0x311c1d['createdAt'])break;_0x4e76b1++;}else _0x4e76b1++;}}return _0x4e76b1;}['_getFromVersion'](_0x12a7d3){const _0x4e26b3=this['repository']['getRevisions']();_0x4e26b3['reverse'](),_0x4e26b3['shift']();const _0x5e0896=_0x4e26b3['find'](_0x35b3b5=>_0x35b3b5['toVersion']<=_0x12a7d3)['toVersion'];return _0x5e0896<this['_startingVersion']?this['_startingVersion']:_0x5e0896;}['_makeRevision']({name:_0x4dce8f,from:_0x21b139,to:_0x1581f5,creatorId:_0x2c9bba,id:_0x4adea4}){const _0x38e361=this['buildRevisionData']({'from':_0x21b139,'to':_0x1581f5});_0x38e361['name']=_0x4dce8f,_0x38e361['creatorId']=_0x2c9bba,_0x38e361['id']=_0x4adea4;const _0x30092f=this['addRevisionData'](_0x38e361);return this['adapter']&&this['_bufferUpdate'](_0x38e361['id'],_0x38e361,!0x0),_0x30092f;}['_setConversion'](){this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'});}}class E{['editor'];['source'];['_savedMetaData'];['_lastFrom'];['_lastTo'];['_markers'];['_diffRoots'];['_diffRootsAttributes'];['_baseRoots'];['_baseRootsAttributes'];['_idsRoots'];['_baseIdsRoots'];['_touched'];['_touchedMarkers'];['_touchedRoots'];['_revisionId'];['_startingRevisionId'];constructor(_0x496bf3){this['editor']=_0x496bf3,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'](_0x18ec5d){this['source']=_0x18ec5d;const _0x279149=new Map(),_0x223425=new Map(),_0x29f8ad=this['editor']['model']['document']['roots']['map'](_0x48c6b6=>_0x48c6b6['rootName']);for(const _0x362df8 of _0x29f8ad){const _0x472e60=this['editor']['model']['document']['getRoot'](_0x362df8),_0x26a9f2=x(_0x472e60);_0x279149['set'](_0x362df8,_0x26a9f2),_0x223425['set'](_0x362df8,Object['fromEntries'](_0x472e60['getAttributes']()));}const _0x4875db=Array['from'](this['editor']['model']['markers'])['map'](_0x2eebad=>[_0x2eebad['name'],_0x2eebad['getRange']()]),_0x1cfe0b=this['source']['version'];this['_saveMetaData'](_0x1cfe0b,_0x279149,_0x4875db,_0x223425),this['_startingRevisionId']=this['_revisionId'];const _0x27d6c0=new Map(),_0x1f7156=new Map();for(const _0xe13835 of _0x29f8ad){const _0x52fce0=N(_0xe13835);_0x27d6c0['set'](_0xe13835,_0x52fce0),_0x1f7156['set'](_0xe13835,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x27d6c0,[],_0x1f7156);}['getData'](_0xa0bc1d,_0x323283){if(this['_lastFrom']===_0xa0bc1d&&this['_lastTo']<=_0x323283)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x323283,!0x0);else{if(!this['_savedMetaData']['has'](_0xa0bc1d)){const _0x1a1bdc=this['_getPreviousFrom'](_0xa0bc1d);this['_calculateMetaData'](_0x1a1bdc,_0xa0bc1d,!0x1);}this['_calculateMetaData'](_0xa0bc1d,_0x323283,!0x0);}return this['_lastFrom']=_0xa0bc1d,this['_lastTo']=_0x323283,this['_getState']();}['loadState'](_0x3d7e54){const _0x1b024c=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x3d7e54['fromVersion'],this['_lastTo']=_0x3d7e54['toVersion'];for(const _0x558912 in _0x3d7e54['diffData']){const _0x4ac9e6=_0x3d7e54['diffData'][_0x558912]['attachChange'],_0x44f05e=_0x1f8e55(_0x3d7e54['diffData'][_0x558912]['attributesBefore'])||{},_0x3d0eaa=_0x1b024c['_makeModelFromViewString'](_0x3d7e54['diffData'][_0x558912]['deletions']);_0x3d0eaa['rootName']=_0x558912,_0x3d0eaa['_isAttached']=!_0x4ac9e6||!_0x4ac9e6['isAttached'],_0x3d0eaa['isAttached']=()=>_0x3d0eaa['_isAttached'],this['_baseRoots']['set'](_0x558912,_0x3d0eaa),this['_baseRootsAttributes']['set'](_0x558912,_0x44f05e),_0x4ac9e6&&this['_touchedRoots']['set'](_0x558912,_0x4ac9e6);const _0x2a9252=this['_makeIdsRoot'](_0x3d0eaa);this['_baseIdsRoots']['set'](_0x558912,_0x2a9252);for(const [_0x4a65ff,_0x56f33a]of _0x3d0eaa['markers']){if(!_0x4a65ff['startsWith']('revision:'))continue;const _0x17f7a1=_0x4a65ff['split'](':')[0x2];for(const _0x466d71 of _0x56f33a['getWalker']({'singleCharacters':!0x0})){const _0x4ec0a5=this['_getVidAttributeName'](_0x466d71),_0x337b0b='elementEnd'==_0x466d71['type']?_0x466d71['previousPosition']['path']['slice'](0x0,-0x1):_0x466d71['previousPosition']['path'],_0x193b2d=_0x2a9252['getNodeByPath'](_0x337b0b)['getAttribute'](_0x4ec0a5);this['_touched']['set'](_0x193b2d,{'userId':_0x17f7a1});}}}this['_startingRevisionId']=this['_revisionId'];const _0x2d349d=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x51858f=>!this['_touched']['has'](_0x51858f));let _0x15c48a=0x0;const _0x40e235=new Map();for(const _0x27ac92 in _0x3d7e54['diffData']){const _0x207105=_0x3d7e54['diffData'][_0x27ac92]['attachChange'],_0x2511a2=_0x1f8e55(_0x3d7e54['diffData'][_0x27ac92]['attributesAfter'])||{},_0x16b9d3=_0x1b024c['_makeModelFromViewString'](_0x3d7e54['diffData'][_0x27ac92]['insertions']);_0x16b9d3['rootName']=_0x27ac92,_0x16b9d3['_isAttached']=!_0x207105||_0x207105['isAttached'],_0x16b9d3['isAttached']=()=>_0x16b9d3['_isAttached'],this['_diffRoots']['set'](_0x27ac92,_0x16b9d3),this['_diffRootsAttributes']['set'](_0x27ac92,_0x2511a2);const _0xff4582=this['_makeIdsRoot'](_0x16b9d3,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x27ac92,_0xff4582),_0x40e235['set'](_0x27ac92,_0x16b9d3['isAttached']()?_0x2511a2:{});for(const [_0x4bf032,_0x27db9f]of _0x16b9d3['markers']){if(!_0x4bf032['startsWith']('revision:'))continue;const _0x534522=_0x4bf032['split'](':')[0x2];for(const _0x2bc0af of _0x27db9f['getWalker']({'singleCharacters':!0x0})){const _0x4cb2bd=this['_getVidAttributeName'](_0x2bc0af),_0x5c2607=this['_revisionId']++,_0x361145='elementEnd'==_0x2bc0af['type']?_0x2bc0af['previousPosition']['path']['slice'](0x0,-0x1):_0x2bc0af['previousPosition']['path'];_0xff4582['getNodeByPath'](_0x361145)['_setAttribute'](_0x4cb2bd,_0x5c2607),this['_touched']['set'](_0x5c2607,{'userId':_0x534522});}}for(const _0x3ee5c0 of this['editor']['model']['createRangeIn'](_0x16b9d3)['getWalker']({'singleCharacters':!0x0})){const _0x1b58a8=this['_getVidAttributeName'](_0x3ee5c0),_0x4d943d='elementEnd'==_0x3ee5c0['type']?_0x3ee5c0['previousPosition']['path']['slice'](0x0,-0x1):_0x3ee5c0['previousPosition']['path'],_0x1932b7=_0xff4582['getNodeByPath'](_0x4d943d);_0x1932b7['getAttribute'](_0x1b58a8)>0x0||_0x1932b7['_setAttribute'](_0x1b58a8,_0x2d349d[_0x15c48a++]);}for(const [_0x577104,_0x31fec2]of _0x16b9d3['markers'])_0x577104['startsWith']('revision:')||this['_markers']['set'](_0x577104,_0x31fec2);}const _0x51d398=N('$graveyard');this['_baseRoots']['set']('$graveyard',_0x51d398),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x51d398,0x1));const _0x31845f=N('$graveyard');this['_diffRoots']['set']('$graveyard',_0x31845f),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x31845f,0x1));const _0xdfa84f=Array['from'](this['_diffRoots'])['map'](([_0x3471b7,_0x23190e])=>[_0x3471b7,x(_0x23190e)]);this['_saveMetaData'](this['_lastTo'],_0xdfa84f,this['_markers'],_0x40e235);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0xa7cde4,_0x3095d9,_0x450d59,_0x4f662d){const _0x196420=new Map(_0x3095d9),_0x3b44aa=new Map(_0x1f8e55(_0x4f662d)),_0x59ae22=new Map();for(const [_0x4f945d,_0x1d44d3]of _0x450d59)_0x59ae22['set'](_0x4f945d,{'start':_0x1d44d3['start']['clone'](),'end':_0x1d44d3['end']['clone'](),'rootName':_0x1d44d3['root']['rootName']});this['_savedMetaData']['set'](_0xa7cde4,{'roots':_0x196420,'markers':_0x59ae22,'rootsAttributes':_0x3b44aa});}['_removeMetaData'](_0x568a51){this['_savedMetaData']['delete'](_0x568a51);}['_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'](_0x4e5eca,_0x26be13=null){let _0x863300=null;_0x4e5eca['is']('documentFragment')||(_0x863300=new _0x4b8223(_0x4e5eca['name'],{'vid_start':null===_0x26be13?this['_revisionId']++:_0x26be13++}));const _0xd42e1d=[];for(const _0x1a25f8 of _0x4e5eca['getChildren']())if(_0x1a25f8['is']('element')){_0xd42e1d['push'](this['_makeIdsRoot'](_0x1a25f8,_0x26be13));const _0x4cd2d4=_0xd42e1d[_0xd42e1d['length']-0x1];null!==_0x26be13&&(_0x26be13=_0x4cd2d4['is']('element','$text')?_0x4cd2d4['getAttribute']('vid')+0x1:_0x4cd2d4['getAttribute']('vid_end')+0x1);}else{for(let _0x5d0dfb=0x0;_0x5d0dfb<_0x1a25f8['offsetSize'];_0x5d0dfb++)_0xd42e1d['push'](new _0x4b8223('$text',{'vid':null===_0x26be13?this['_revisionId']++:_0x26be13++}));}if(_0x4e5eca['is']('documentFragment')){const _0x5851e9=N(_0x4e5eca['rootName']);return _0x5851e9['_insertChild'](0x0,_0xd42e1d),_0x5851e9;}return _0x863300['_setAttribute']('vid_end',null===_0x26be13?this['_revisionId']++:_0x26be13++),_0x863300['_insertChild'](0x0,_0xd42e1d),_0x863300;}['_calculateMetaData'](_0xc22f43,_0x3d8b15,_0xa4d243){this['_reset']();const {roots:_0x5158eb,markers:_0x26c099,rootsAttributes:_0x2d0184}=this['_savedMetaData']['get'](_0xc22f43);this['_baseRoots']=new Map(_0x5158eb),this['_baseRootsAttributes']=new Map(_0x1f8e55(_0x2d0184));for(const [_0x3bd1da,_0x339f3f]of this['_baseRoots'])if('$graveyard'!==_0x3bd1da&&(this['_diffRoots']['set'](_0x3bd1da,x(_0x339f3f)),this['_diffRootsAttributes']=new Map(_0x1f8e55(_0x2d0184)),_0xa4d243)){const _0x2ff38e=this['_revisionId'];this['_idsRoots']['set'](_0x3bd1da,this['_makeIdsRoot'](_0x339f3f)),this['_baseIdsRoots']['set'](_0x3bd1da,this['_makeIdsRoot'](_0x339f3f,_0x2ff38e));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',x(this['_baseRoots']['get']('$graveyard'))),_0xa4d243&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x4e84f5,_0xc0a18b]of _0x26c099){const _0x1b96ef=this['_baseRoots']['get'](_0xc0a18b['rootName']),_0x3124a5=this['_diffRoots']['get'](_0xc0a18b['rootName']),_0x5a8fd8=new _0x1d690c(this['_fixPosition'](_0xc0a18b['start'],_0x1b96ef),this['_fixPosition'](_0xc0a18b['end'],_0x1b96ef)),_0x2e4ae1=this['_fixRange'](_0x5a8fd8,_0x3124a5);_0x1b96ef['markers']['set'](_0x4e84f5,_0x5a8fd8),this['_markers']['set'](_0x4e84f5,_0x2e4ae1);}this['_applyOperations'](_0xc22f43,_0x3d8b15,_0xa4d243);}['_applyOperations'](_0x508513,_0x48b3e5,_0x38c945){for(const _0x29b6ed of this['source']['getOperations'](_0x508513,_0x48b3e5))this['_handleOperation'](_0x29b6ed,_0x38c945);for(const _0x25069d of this['_diffRoots']['values']())_0x25069d['markers']['clear']();for(const [_0x4c5722,_0x473ea9]of this['_markers']){this['_diffRoots']['get'](_0x473ea9['root']['rootName'])['markers']['set'](_0x4c5722,_0x473ea9['clone']());}const _0x26c5d1=new Map(),_0x5354d8=new Map();for(const [_0x314870,_0x3f0bc0]of this['_diffRoots'])_0x26c5d1['set'](_0x314870,x(_0x3f0bc0)),_0x5354d8['set'](_0x314870,this['_diffRootsAttributes']['get'](_0x314870));this['_saveMetaData'](_0x48b3e5,_0x26c5d1,this['_markers'],_0x5354d8);}['_getPreviousFrom'](_0x5b38a1){const _0x14321e=Array['from'](this['_savedMetaData']['keys']());_0x14321e['sort']((_0x13087e,_0x5d1d96)=>_0x13087e-_0x5d1d96),_0x14321e['reverse']();for(const _0x2610ba of _0x14321e)if(_0x2610ba<_0x5b38a1)return _0x2610ba;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x2811e4,_0x3e4846){const _0x491e3f=Array['from'](_0x3e4846['markers'])['map'](([_0x46f3d8,_0x59c3bd])=>[_0x46f3d8,this['_fixRange'](_0x59c3bd,_0x2811e4)]);_0x2811e4['markers']=new Map(_0x491e3f);}['_transformMarkers'](_0x22432d){for(const _0x5cf655 of this['_markers']['values']()){const _0x2f38c9=_0x5cf655['getTransformedByOperation'](_0x22432d),_0x48a2d9=_0x1d690c['_createFromRanges'](_0x2f38c9);_0x5cf655['start']=_0x48a2d9['start'],_0x5cf655['end']=_0x48a2d9['end'];}}['_handleOperation'](_0x15f9f6,_0x28ea94){if('addRoot'!=_0x15f9f6['type']&&'detachRoot'!=_0x15f9f6['type']){if('insert'==_0x15f9f6['type']){const _0x38494a=_0x15f9f6['position']['root']['rootName'];this['_diffRoots']['has'](_0x38494a)||(this['_diffRoots']['set'](_0x38494a,N(_0x38494a,!0x0)),this['_diffRootsAttributes']['set'](_0x38494a,{}),_0x28ea94&&this['_idsRoots']['set'](_0x38494a,N(_0x38494a,!0x0)));}else{if('addRootAttribute'==_0x15f9f6['type']||'removeRootAttribute'==_0x15f9f6['type']||'changeRootAttribute'==_0x15f9f6['type'])return void this['_handleRootAttributeOperation'](_0x15f9f6);'marker'==_0x15f9f6['type']&&this['_handleMarkerOperation'](_0x15f9f6);}if('marker'!==_0x15f9f6['type']){const _0x57d351=this['_cloneOperation'](_0x15f9f6,this['_diffRoots']);_0x57d351['_execute'](),this['_transformMarkers'](_0x57d351);}if(_0x28ea94)switch(_0x15f9f6['type']){case'insert':this['_handleInsertOperation'](_0x15f9f6);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x15f9f6);break;case'merge':this['_handleMergeOperation'](_0x15f9f6);break;case'split':this['_handleSplitOperation'](_0x15f9f6);}}else this['_handleRootOperation'](_0x15f9f6,_0x28ea94);}['_cloneOperation'](_0x33a4c4,_0x3c1597){const _0x76ff41=_0x33a4c4['clone']();return _0x76ff41['_authorId']=_0x33a4c4['_authorId'],this['_fixOperation'](_0x76ff41,_0x3c1597),_0x76ff41;}['_getBaseVids'](_0x35ea8c){return _0x35ea8c['map'](_0x10b648=>{const _0x5d33c6=this['_getVidAttributeName'](_0x10b648);return Number(_0x10b648['item']['getAttribute'](_0x5d33c6));});}['_generateTape'](_0x3e55e2,_0x3cb937){if(_0x3e55e2['is']('element','$text'))_0x3cb937['push']({'item':_0x3e55e2,'type':'text'});else{_0x3e55e2['is']('element')&&_0x3cb937['push']({'item':_0x3e55e2,'type':'elementStart'});for(const _0x3bdf48 of _0x3e55e2['getChildren']())this['_generateTape'](_0x3bdf48,_0x3cb937);_0x3e55e2['is']('element')&&_0x3cb937['push']({'item':_0x3e55e2,'type':'elementEnd'});}return _0x3cb937;}['_getState'](){const _0x2ff74d=new Map(this['_touched']),_0x1166ab=new Map(_0x2ff74d),_0x24d0fe=new Map(),_0x123ea2={'insertions':{},'deletions':{}},_0x85ed6={'insertions':{},'deletions':{}},_0xb837f0=new Map(),_0x49ff99=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x49ff99['delete']('$graveyard');for(const _0x92984f of _0x49ff99){const _0x5ec09a=this['_diffRoots']['get'](_0x92984f)||N(_0x92984f,!0x1),_0x15f5ce=this['_baseRoots']['get'](_0x92984f)||N(_0x92984f,!0x1);_0x5ec09a['isAttached']()||_0x15f5ce['isAttached']()?(_0x123ea2['insertions'][_0x92984f]=x(_0x5ec09a),_0x123ea2['deletions'][_0x92984f]=x(_0x15f5ce),this['_copyMarkers'](_0x123ea2['deletions'][_0x92984f],_0x15f5ce),this['_copyMarkers'](_0x123ea2['insertions'][_0x92984f],_0x5ec09a),_0x85ed6['insertions'][_0x92984f]=this['_generateTape'](this['_idsRoots']['get'](_0x92984f),[]),_0x85ed6['deletions'][_0x92984f]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x92984f)||N(_0x92984f,!0x1),[])):_0x49ff99['delete'](_0x92984f);}for(const _0x1db28b of _0x49ff99){const _0x5df9bf=_0x85ed6['insertions'][_0x1db28b];for(const _0x53dad3 of _0x5df9bf){const _0x4e7a82=this['_getVidAttributeName'](_0x53dad3),_0x582219=_0x53dad3['item']['getAttribute'](_0x4e7a82);_0x1166ab['delete'](_0x582219),_0x582219>=this['_startingRevisionId']&&_0x24d0fe['set'](_0x582219,_0x2ff74d['get'](_0x582219));}}for(const _0x481541 of _0x49ff99){const _0x4fe064=_0x85ed6['insertions'][_0x481541],_0x41606e=this['_getBaseVids'](_0x85ed6['deletions'][_0x481541]);let _0x1eb41d=0x0;for(const _0xf497e3 of _0x4fe064){const _0x85c797=this['_getVidAttributeName'](_0xf497e3),_0x3476e9=_0xf497e3['item']['getAttribute'](_0x85c797);if(!_0x24d0fe['has'](_0x3476e9)&&!_0xb837f0['has'](_0x3476e9)){if(_0x1166ab['has'](_0x3476e9))_0x1eb41d++;else{if(_0x3476e9!=_0x41606e[_0x1eb41d]){const _0x26ecdd=_0x2ff74d['get'](_0x3476e9)||_0x2ff74d['get'](_0x41606e[_0x1eb41d]);for(;_0x3476e9!=_0x41606e[_0x1eb41d];)_0x1166ab['has'](_0x41606e[_0x1eb41d])||(_0xb837f0['set'](_0x41606e[_0x1eb41d],_0x26ecdd),_0x2ff74d['set'](_0x41606e[_0x1eb41d],_0x26ecdd)),_0x1eb41d++;}_0x1eb41d++;}}}}for(const _0x1e6d54 of _0x49ff99){const _0x49fc3a=_0x85ed6['insertions'][_0x1e6d54];for(const _0x2018dd of _0x49fc3a){const _0x3ebad8=this['_getVidAttributeName'](_0x2018dd),_0x130d9d=_0x2018dd['item']['getAttribute'](_0x3ebad8);if(_0xb837f0['has'](_0x130d9d)){const _0x1f686f=_0xb837f0['get'](_0x130d9d);_0x1166ab['has'](_0x130d9d)||_0x1166ab['set'](_0x130d9d,{..._0x1f686f}),_0x24d0fe['set'](_0x130d9d,{..._0x1f686f});}}}for(const _0x27a1e2 of _0x1166ab['keys']())_0x27a1e2>=this['_startingRevisionId']&&_0x1166ab['delete'](_0x27a1e2);const _0x1af717=new Map();for(const _0x3d0868 of _0x49ff99){let _0x37b972=_0x85ed6['insertions'][_0x3d0868];for(const _0x2dc03f of _0x37b972)if(_0x2dc03f['item']['is']('element','tableCell')){const _0x3a4ded=this['_getVidAttributeName'](_0x2dc03f),_0x14453c=_0x2dc03f['item']['getAttribute'](_0x3a4ded);if(_0x24d0fe['has'](_0x14453c)){const _0x8051f0=_0x2dc03f['item']['parent']['parent']['getAttribute']('vid_start'),_0x16db86=_0x1af717['get'](_0x8051f0)||new Set();_0x16db86['add'](_0x24d0fe['get'](_0x14453c)['userId']),_0x1af717['set'](_0x8051f0,_0x16db86);}}_0x37b972=_0x85ed6['deletions'][_0x3d0868];for(const _0x5b26e3 of _0x37b972)if(_0x5b26e3['item']['is']('element','tableCell')){const _0x4d9152=this['_getVidAttributeName'](_0x5b26e3),_0x50f778=_0x5b26e3['item']['getAttribute'](_0x4d9152);if(_0x1166ab['has'](_0x50f778)){const _0x3f8742=_0x5b26e3['item']['parent']['parent']['getAttribute']('vid_start'),_0x10d4ba=_0x1af717['get'](_0x3f8742)||new Set();_0x10d4ba['add'](_0x1166ab['get'](_0x50f778)['userId']),_0x1af717['set'](_0x3f8742,_0x10d4ba);}}for(const _0x348ce6 of _0x1af717['keys']())(_0x24d0fe['has'](_0x348ce6)||_0x1166ab['has'](_0x348ce6))&&_0x1af717['delete'](_0x348ce6);}for(const _0x284b58 of _0x49ff99){const _0x2ef009=_0x85ed6['insertions'][_0x284b58];let _0x5577d8=null,_0x49179f=null;for(const _0x42898a of _0x2ef009){const _0x36d161=this['_getVidAttributeName'](_0x42898a),_0x115363=_0x42898a['item']['getAttribute'](_0x36d161),_0x2a037d=_0x1af717['get'](_0x115363);_0x2a037d&&'elementStart'==_0x42898a['type']&&(_0x5577d8=Array['from'](_0x2a037d)[0x0],_0x49179f=_0x42898a['item']['getAttribute']('vid_end')),_0x5577d8&&(_0x1166ab['set'](_0x115363,{'userId':_0x5577d8}),_0x24d0fe['set'](_0x115363,{'userId':_0x5577d8})),_0x115363==_0x49179f&&(_0x5577d8=null,_0x49179f=null);}}const _0x15c30b={},_0x29e46c=new Set();for(const _0x16a02b of _0x49ff99){const _0x3dca93=_0x123ea2['deletions'][_0x16a02b],_0x206536=_0x123ea2['insertions'][_0x16a02b];for(const {userId:_0x54566e}of this['_touchedMarkers']['values']())null!==_0x54566e&&_0x29e46c['add'](_0x54566e);for(const {userId:_0x33c8ac}of this['_touchedRoots']['values']())null!==_0x33c8ac&&_0x29e46c['add'](_0x33c8ac);this['_markChanges'](_0x206536,_0x85ed6['insertions'][_0x16a02b],_0x24d0fe,'insertion',_0x29e46c),this['_markChanges'](_0x3dca93,_0x85ed6['deletions'][_0x16a02b],_0x1166ab,'deletion',_0x29e46c),_0x15c30b[_0x16a02b]={'insertions':this['_prepareViewToSave'](_0x206536),'deletions':this['_prepareViewToSave'](_0x3dca93),'attachChange':this['_touchedRoots']['get'](_0x16a02b)||null,'attributesBefore':_0x1f8e55(this['_baseRootsAttributes']['get'](_0x16a02b))||{},'attributesAfter':_0x1f8e55(this['_diffRootsAttributes']['get'](_0x16a02b))};}return{'diffData':_0x15c30b,'authorsIds':Array['from'](_0x29e46c)};}['_processRootBeforeSave'](_0x5f6d91){for(const [,_0x37f490]of _0x5f6d91['markers']){const _0xe77904=_0x37f490['start']['getAncestors']()['filter'](_0x1a6421=>'tableCell'==_0x1a6421['name']);for(const _0x48b317 of _0xe77904)0x1==_0x48b317['childCount']&&_0x48b317['getChild'](0x0)['is']('element','paragraph')&&_0x48b317['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x55602c){this['_processRootBeforeSave'](_0x55602c);const _0x52b7ba=this['editor']['data']['toView'](_0x55602c,{}),_0x4c965c=Array['from'](_0x52b7ba['getChildren']())['map'](_0x5058dc=>this['_getViewJson'](_0x5058dc));return JSON['stringify'](_0x4c965c);}['_getViewJson'](_0x12b697){if(_0x12b697['is']('$text'))return _0x12b697['data'];{const _0x5bcf3c=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0x106cc8=_0x12b697,_0x2ba3b9=this['editor']['data']['htmlProcessor']['domConverter'],_0x4833ef={'type':_0x5bcf3c['_getTypeCharForViewElement'](_0x106cc8),'name':_0x106cc8['name'],'attributes':Array['from'](_0x106cc8['getAttributes']()),'children':Array['from'](_0x106cc8['getChildren']())['map'](_0x2fb272=>this['_getViewJson'](_0x2fb272))};if(_0x12b697['is']('uiElement')&&'$comment'!=_0x12b697['name']){const _0x29cb81=_0x12b697['render'](_0x2ba3b9['domDocument'],_0x2ba3b9);_0x4833ef['children']['push'](_0x29cb81['outerHTML']);}else{if(_0x12b697['is']('rawElement')){const _0x20a97d=_0x2ba3b9['domDocument']['createElement'](_0x106cc8['name']);_0x12b697['render'](_0x20a97d,_0x2ba3b9),_0x4833ef['children']['push'](_0x20a97d['innerHTML']);}}const _0x388770=Array['from'](_0x106cc8['getCustomProperties']());_0x388770['length']>0x0&&(_0x4833ef['customProperties']=_0x388770);const _0x178647=_0x106cc8['getFillerOffset']();return null!==_0x178647&&(_0x4833ef['fillerOffset']=_0x178647),_0x4833ef;}}['_markChanges'](_0x3fa596,_0x60546d,_0x49459a,_0x89922a,_0x90eeb0){let _0x2eda73=null,_0x1208cd=null,_0x71b356=0x0;const _0x196ee6=this['editor']['model'];for(let _0x5cb202=0x0;_0x5cb202<_0x60546d['length'];_0x5cb202++){const _0x390288=this['_getVidAttributeName'](_0x60546d[_0x5cb202]),_0x2eb0d0=_0x60546d[_0x5cb202]['item']['getAttribute'](_0x390288),_0xd51f3f=_0x49459a['get'](_0x2eb0d0),_0x567724=_0x5cb202==_0x60546d['length']-0x1;(!_0x2eda73&&_0xd51f3f&&(_0x2eda73=_0xd51f3f,_0x1208cd=_0x60546d[_0x5cb202]),_0x2eda73&&(!_0xd51f3f||_0xd51f3f['userId']!=_0x2eda73['userId']))&&(_0x4fd2bd(_0xd51f3f,P(_0x1208cd,_0x3fa596,_0x196ee6),P(_0x60546d[_0x5cb202],_0x3fa596,_0x196ee6)),_0x2eda73=_0xd51f3f||null,_0x1208cd=_0xd51f3f?_0x60546d[_0x5cb202]:null),_0x2eda73&&_0x567724&&_0x4fd2bd(_0xd51f3f,P(_0x1208cd,_0x3fa596,_0x196ee6),V(_0x60546d[_0x5cb202],_0x3fa596,_0x196ee6));}function _0x4fd2bd(_0x445dd,_0x46cbe9,_0x231a92){const _0x31e471=_0x2eda73['userId'],_0x3d938f='revision:'+_0x89922a+':'+_0x31e471+':'+_0x71b356++,_0x3d8d59=_0x196ee6['createRange'](_0x46cbe9,_0x231a92);_0x3fa596['markers']['set'](_0x3d938f,_0x3d8d59),null!==_0x31e471&&_0x90eeb0['add'](_0x31e471);}}['_getVidAttributeName'](_0x1a10d5){switch(_0x1a10d5['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x50c542,_0x2e5b21){_0x50c542['baseVersion']=null;for(const _0xb9a8ae in _0x50c542){const _0x2d6769=_0x50c542[_0xb9a8ae];if(_0x2d6769 instanceof _0x395918){const _0x3e8011=_0x2e5b21['get'](_0x2d6769['root']['rootName']);_0x50c542[_0xb9a8ae]=this['_fixPosition'](_0x2d6769,_0x3e8011);}if(_0x2d6769 instanceof _0x1d690c){const _0x46de70=_0x2e5b21['get'](_0x2d6769['root']['rootName']);_0x50c542[_0xb9a8ae]=this['_fixRange'](_0x2d6769,_0x46de70);}'root'===_0xb9a8ae&&(_0x50c542['root']=_0x2e5b21['get'](_0x50c542['root']['rootName']));}}['_fixRange'](_0x73358e,_0x58b257){return this['editor']['model']['createRange'](this['_fixPosition'](_0x73358e['start'],_0x58b257),this['_fixPosition'](_0x73358e['end'],_0x58b257));}['_fixPosition'](_0x45f64a,_0x195d4d){return this['editor']['model']['createPositionFromPath'](_0x195d4d,_0x45f64a['path'],_0x45f64a['stickiness']);}['_handleInsertOperation'](_0x591347){const _0xdadf8c=this['_idsRoots']['get'](_0x591347['position']['root']['rootName']),_0x472089=this['_fixPosition'](_0x591347['position'],_0xdadf8c),_0x3bb501=null===_0x591347['_authorId']?null:_0x591347['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x1ff7c7=_0x472089['parent'],_0x1a249c=this['_revisionId'],_0x2b94c3=[];for(const _0x367122 of _0x591347['nodes'])if(_0x367122['is']('element'))_0x2b94c3['push'](this['_makeIdsRoot'](_0x367122));else{for(let _0x4952ea=0x0;_0x4952ea<_0x367122['offsetSize'];_0x4952ea++)_0x2b94c3['push'](new _0x4b8223('$text',{'vid':this['_revisionId']++}));}const _0x1ab3f3=this['_revisionId'];for(let _0x1215a8=_0x1a249c;_0x1215a8<_0x1ab3f3;_0x1215a8++)this['_touched']['set'](_0x1215a8,{'userId':_0x3bb501});_0x1ff7c7['_insertChild'](_0x472089['offset'],_0x2b94c3);}['_handleMoveOperation'](_0x542ffe){(_0x542ffe=this['_cloneOperation'](_0x542ffe,this['_idsRoots']))['_execute']();const _0x713a64=null===_0x542ffe['_authorId']?null:_0x542ffe['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0xe8077a=_0x542ffe['getMovedRangeStart'](),_0x3eba17=_0xe8077a['parent'],_0x30031d=_0xe8077a['offset'];!function _0x5050ec(_0x156aa1,_0x72eb2c,_0x17895c,_0x40aa7d){for(let _0x5a0d8f=_0x17895c;_0x5a0d8f<_0x40aa7d;_0x5a0d8f++){const _0x9da4b7=_0x72eb2c['getChild'](_0x5a0d8f);_0x9da4b7['is']('element','$text')?_0x156aa1['set'](_0x9da4b7['getAttribute']('vid'),{'userId':_0x713a64}):(_0x156aa1['set'](_0x9da4b7['getAttribute']('vid_start'),{'userId':_0x713a64}),_0x5050ec(_0x156aa1,_0x9da4b7,0x0,_0x9da4b7['childCount']),_0x156aa1['set'](_0x9da4b7['getAttribute']('vid_end'),{'userId':_0x713a64}));}}(this['_touched'],_0x3eba17,_0x30031d,_0x30031d+_0x542ffe['howMany']);}['_handleMergeOperation'](_0x5644d2){const _0x494715=null===(_0x5644d2=this['_cloneOperation'](_0x5644d2,this['_idsRoots']))['_authorId']?null:_0x5644d2['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x3fd5c6=_0x5644d2['targetPosition']['parent'],_0x25ef80=_0x5644d2['sourcePosition']['parent'],_0x259b84=_0x3fd5c6['getAttribute']('vid_end'),_0x22943d=_0x25ef80['getAttribute']('vid_start');_0x3fd5c6['_setAttribute']('vid_end',_0x25ef80['getAttribute']('vid_end')),_0x25ef80['_setAttribute']('vid_end',_0x259b84),this['_touched']['set'](_0x22943d,{'userId':_0x494715}),this['_touched']['set'](_0x259b84,{'userId':_0x494715}),_0x5644d2['_execute']();}['_handleSplitOperation'](_0x44e6ac){const _0x18cf4b=null===(_0x44e6ac=this['_cloneOperation'](_0x44e6ac,this['_idsRoots']))['_authorId']?null:_0x44e6ac['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x402e09=_0x44e6ac['graveyardPosition'],_0x3826df=_0x44e6ac['splitPosition']['parent'];_0x44e6ac['_execute']();const _0x384bb2=_0x3826df['getAttribute']('vid_end'),_0x5b28cd=_0x44e6ac['insertionPosition']['nodeAfter'];if(_0x402e09){const _0x241bd1=_0x5b28cd['getAttribute']('vid_end'),_0x56ebc6=_0x3826df['getAttribute']('vid_end');_0x3826df['_setAttribute']('vid_end',_0x241bd1),_0x5b28cd['_setAttribute']('vid_end',_0x56ebc6),this['_touched']['set'](_0x3826df['getAttribute']('vid_end'),{'userId':_0x18cf4b}),this['_touched']['set'](_0x5b28cd['getAttribute']('vid_start'),{'userId':_0x18cf4b});}else{const _0x1b8536=this['_revisionId']++,_0x32eb3a=this['_revisionId']++;_0x3826df['_setAttribute']('vid_end',_0x1b8536),_0x5b28cd['_setAttribute']('vid_start',_0x32eb3a),_0x5b28cd['_setAttribute']('vid_end',_0x384bb2),this['_touched']['set'](_0x1b8536,{'userId':_0x18cf4b}),this['_touched']['set'](_0x32eb3a,{'userId':_0x18cf4b});}}['_handleMarkerOperation'](_0x534553){if(!_0x534553['affectsData'])return;const _0x5f52a8=(_0x534553=this['_cloneOperation'](_0x534553,this['_diffRoots']))['oldRange']?_0x534553['oldRange']['root']:null,_0x10a3c9=_0x534553['newRange']?_0x534553['newRange']['root']:null;_0x5f52a8&&this['_markers']['delete'](_0x534553['name']),_0x10a3c9&&this['_markers']['set'](_0x534553['name'],_0x534553['newRange']['clone']());const _0x51bd37=null===_0x534553['_authorId']?null:_0x534553['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x197bc3=_0x534553['name'];if(!this['_touchedMarkers']['has'](_0x197bc3))return void this['_touchedMarkers']['set'](_0x197bc3,{'range':_0x534553['oldRange'],'userId':_0x51bd37});const _0x236564=this['_touchedMarkers']['get'](_0x197bc3),_0x222c45=_0x236564['range'],_0x473e08=_0x534553['newRange'];null==_0x222c45&&null==_0x473e08||_0x222c45&&_0x473e08&&_0x222c45['isEqual'](_0x473e08)?this['_touchedMarkers']['delete'](_0x534553['name']):_0x236564['userId']=_0x51bd37;}['_handleRootOperation'](_0x18488c,_0x365fb8){this['_diffRoots']['has'](_0x18488c['rootName'])?this['_diffRoots']['get'](_0x18488c['rootName'])['_isAttached']=_0x18488c['isAdd']:(this['_diffRoots']['set'](_0x18488c['rootName'],N(_0x18488c['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x18488c['rootName'],{}),_0x365fb8&&this['_idsRoots']['set'](_0x18488c['rootName'],N(_0x18488c['rootName'],!0x0)));const _0x5d56f8=null===_0x18488c['_authorId']?null:_0x18488c['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x301cdf=this['_touchedRoots']['get'](_0x18488c['rootName']);_0x301cdf&&_0x301cdf['userId']===_0x5d56f8?this['_touchedRoots']['delete'](_0x18488c['rootName']):this['_touchedRoots']['set'](_0x18488c['rootName'],{'userId':_0x5d56f8,'isAttached':_0x18488c['isAdd']});}['_handleRootAttributeOperation'](_0x2422c7){const _0xf9f08=this['_diffRootsAttributes']['get'](_0x2422c7['root']['rootName']);null===_0x2422c7['newValue']?delete _0xf9f08[_0x2422c7['key']]:_0xf9f08[_0x2422c7['key']]=_0x2422c7['newValue'];}}function x(_0x20b493){const _0x41fb48=N(_0x20b493['rootName'],_0x20b493['isAttached']());for(const _0x3992e0 of _0x20b493['getChildren']()){const _0x1c11c0=_0x3992e0['_clone'](!0x0);_0x41fb48['_appendChild'](_0x1c11c0);}return _0x41fb48;}function N(_0x2fcec2,_0xd0c5fe=!0x0){const _0x4264af=new _0x3caf08();return _0x4264af['rootName']=_0x2fcec2,_0x4264af['_isAttached']=_0xd0c5fe,_0x4264af['isAttached']=()=>_0x4264af['_isAttached'],_0x4264af;}function P(_0x1b41b0,_0x361242,_0x3b9df6){const _0x5c783d='elementEnd'==_0x1b41b0['type']?_0x3b9df6['createPositionAt'](_0x1b41b0['item'],'end'):_0x3b9df6['createPositionBefore'](_0x1b41b0['item']);return _0x3b9df6['createPositionFromPath'](_0x361242,_0x5c783d['path'],_0x5c783d['stickiness']);}function V(_0x2db1bd,_0x57dd6b,_0x51d2c6){const _0x26c4fd='elementStart'==_0x2db1bd['type']?_0x51d2c6['createPositionAt'](_0x2db1bd['item'],0x0):_0x51d2c6['createPositionAfter'](_0x2db1bd['item']);return _0x51d2c6['createPositionFromPath'](_0x57dd6b,_0x26c4fd['path'],_0x26c4fd['stickiness']);}class he extends/* #__PURE__ -- @preserve */
25
- _0x34a1b6(_0x3c5996){['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x369d44,_0xf2a476){super(_0x369d44),this['focusTracker']=new _0x3f152b(),this['keystrokes']=new _0x5b0245(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0xf2a476),this['setTemplate']({'tag':'form','attributes':{'class':['ck','ck-revision-history-save-revision-form','ck-responsive-form'],'tabindex':'-1'},'children':[this['revisionNameInputView']]}),this['initializeCssTransitionDisablerMixin']();}['render'](){super['render'](),_0x2f8e68({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x4f6490=_0x4a6d84=>_0x4a6d84['stopPropagation']();this['keystrokes']['set']('arrowright',_0x4f6490),this['keystrokes']['set']('arrowleft',_0x4f6490),this['keystrokes']['set']('arrowup',_0x4f6490),this['keystrokes']['set']('arrowdown',_0x4f6490);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x16e97a){this['revisionNameInputView']['fieldView']['element']['value']=_0x16e97a['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x3874d7){const _0x1f6be1=new ti(this['locale'],_0x2f6324),_0x193d42=_0x1f6be1['fieldView'];_0x193d42['extendTemplate']({'attributes':{'maxlength':'220'}});let _0xc12752=R(this['locale'],'Name\x20of\x20the\x20revision');return!_0x3874d7&&(_0xc12752+='\x20('+R(this['locale'],'optional')+')'),(_0x1f6be1['label']=_0xc12752,_0x193d42['on']('input',()=>{this['revisionNameInputValue']=_0x193d42['element']['value']['trim']();}),_0x1f6be1);}}class v extends _0x16aaad{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h];}['_saveRevisionFormView'];['init'](){const _0x312f48=this['editor'],_0x8a03db=_0x312f48['plugins']['get']('RevisionTracker');_0x312f48['ui']['componentFactory']['add']('revisionHistory',_0x679d56=>{const _0xea480a=_0x36bb40(_0x679d56),_0x130d7d=_0xea480a['panelView']['children'],_0x1ad30d=new _0x286850(_0x679d56),_0x30fb24=new _0x21eff4(_0x679d56),_0x3ec2a9=new _0x154c46(_0x679d56),_0x3a816=new _0x21eff4(_0x679d56),_0x26b6af=new _0x154c46(_0x679d56);return _0xea480a['bind']('isEnabled')['to'](_0x8a03db,'isReady',_0x8a03db,'isEnabled',_0x312f48,'isReadOnly',(_0x37e6dc,_0x1ff1b5,_0x2e8334)=>_0x37e6dc&&_0x1ff1b5&&!_0x2e8334),_0xea480a['buttonView']['set']({'icon':_0x3d0553,'label':R(_0x679d56,'Revision\x20history'),'tooltip':!0x0}),_0x3ec2a9['set']({'label':R(_0x679d56,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x3ec2a9['bind']('isEnabled')['to'](_0x8a03db,'isReady',_0x8a03db,'isEnabled',_0x312f48,'isReadOnly',(_0x32c2d6,_0x5ca52a,_0x37d506)=>_0x32c2d6&&_0x5ca52a&&!_0x37d506),_0x3ec2a9['on']('execute',()=>this['_showDialog']()),_0x26b6af['set']({'label':R(_0x679d56,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x26b6af['bind']('isEnabled')['to'](_0x8a03db,'isReady',_0x312f48,'isReadOnly',(_0x31ac03,_0x43bc94)=>_0x31ac03&&!_0x43bc94),_0x26b6af['on']('execute',()=>{_0x312f48['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0xea480a['isOpen']=!0x1,_0x312f48['editing']['view']['focus']();}),_0x30fb24['children']['add'](_0x3ec2a9),_0x3a816['children']['add'](_0x26b6af),_0x1ad30d['role']='menu',_0x1ad30d['items']['addMany']([_0x30fb24,_0x3a816]),_0x130d7d['add'](_0x1ad30d),_0xea480a;}),_0x312f48['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x11939e=this['editor'],_0x1cf10e=_0x11939e['locale'],_0x1a3cc6=new _0x40061c(_0x1cf10e),_0x1d54de=new _0x4d09c3(_0x1cf10e);_0x1a3cc6['buttonView']['set']({'icon':_0x3d0553,'label':R(_0x1cf10e,'Revision\x20history')});const _0x13907e=new _0x1b8a1c(_0x1cf10e,_0x1a3cc6),_0x15481a=new _0x586a63(_0x1cf10e);_0x15481a['set']({'label':R(_0x1cf10e,'Save\x20current\x20revision')}),_0x15481a['delegate']('execute')['to'](_0x1a3cc6),_0x15481a['on']('execute',()=>{this['_showDialog']();}),_0x13907e['children']['add'](_0x15481a),_0x1d54de['items']['add'](_0x13907e);const _0x3391ce=new _0x1b8a1c(_0x1cf10e,_0x1a3cc6),_0x14f99f=new _0x586a63(_0x1cf10e);return _0x14f99f['set']({'label':R(_0x1cf10e,'Open\x20revision\x20history')}),_0x14f99f['delegate']('execute')['to'](_0x1a3cc6),_0x14f99f['on']('execute',()=>{_0x11939e['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x3391ce['children']['add'](_0x14f99f),_0x1d54de['items']['add'](_0x3391ce),_0x1a3cc6['panelView']['children']['add'](_0x1d54de),_0x1a3cc6;}['_showDialog'](){const _0x5b5abf=this['editor'],_0x4a828c=_0x5b5abf['locale'],_0xd6a274=_0x5b5abf['plugins']['get']('Dialog'),_0x509eb4=_0x5b5abf['plugins']['get']('RevisionTracker');function _0x7f0c78(_0x1da00b){_0x5b5abf['config']['get']('revisionHistory.requireRevisionName')&&''===_0x1da00b['revisionName']?_0x1da00b['revisionNameInputView']['errorText']=R(_0x4a828c,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x5b5abf['plugins']['get'](h)['saveRevision']({'name':_0x1da00b['revisionName']}),_0xd6a274['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x7f0c78(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0xd6a274['show']({'id':'revisionSave','title':R(_0x4a828c,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':R(_0x5b5abf['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0xd6a274['hide']()},{'label':R(_0x5b5abf['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x27a0c2){_0x27a0c2['bind']('isEnabled')['to'](_0x509eb4,'isReady',_0x509eb4,'isEnabled',_0x5b5abf,'isReadOnly',(_0x4e52bd,_0x556cd8,_0x4c9417)=>_0x4e52bd&&_0x556cd8&&!_0x4c9417);},'onExecute':()=>_0x7f0c78(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x3a40ca=this['editor'],_0x5cd2c8=_0x3a40ca['locale'];this['_saveRevisionFormView']=new he(_0x5cd2c8,_0x3a40ca['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class z extends _0x3c5996{['changeId'];['_model'];constructor(_0x17bfdf,_0x555928){super(_0x17bfdf),this['_model']=_0x555928,this['changeId']=_0x555928['id'];const _0x279db2=this['bindTemplate'],_0x3c72f8=R(_0x17bfdf,_0x555928['data']['isSuggestion']?'Suggested\x20by':'add'==_0x555928['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x555928['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x279db2['to']('type',_0x2e94b5=>'ck-revision-change__'+_0x2e94b5)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x3c72f8}]},{'text':'\x20'+_0x555928['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class G extends/* #__PURE__ -- @preserve */
26
- _0x4f2b3d(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0xc3e68f){super(),this['id']=_0xc3e68f['id']||_0x5da2bc(),this['author']=_0xc3e68f['author'],this['type']=_0xc3e68f['type'],this['data']=_0xc3e68f['data']||{},this['rootName']=_0xc3e68f['rootName'],this['set']('createdAt',_0xc3e68f['createdAt']);}['toJSON'](){return{'id':this['id'],'authorId':this['author']['id'],'type':this['type'],'data':this['data'],'createdAt':this['createdAt']};}}class J{['newRevisionId'];['oldRevisionId'];['changes'];constructor(_0x1ad993,_0x82d7d0){this['newRevisionId']=_0x1ad993,this['oldRevisionId']=_0x82d7d0,this['changes']=new _0x3e4e8e();}['_setChanges'](_0x59d96d){for(const _0x1126ed of _0x59d96d)this['changes']['add'](_0x1126ed);}}class l extends _0x16aaad{['repository'];['adapter']=null;['_utils'];['_activeViewTarget'];['_changeView'];['_changeIdToChange'];['_balloon'];static get['pluginName'](){return'RevisionViewer';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[_0xea3ed8,_0x513bdf,S,$];}constructor(_0x252382){super(_0x252382),this['repository']=this['editor']['plugins']['get']('RevisionsRepository'),this['_utils']=this['editor']['plugins']['get']('RevisionHistoryUtils'),this['set']('activeChange',null),this['set']('activeView',null),this['_activeViewTarget']=null,this['set']('diff',null),this['set']('isReady',!0x1),this['set']('isEnabled',!0x0),this['on']('change:isEnabled',(_0x1b2cae,_0xe93de7,_0x968575)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x3f2c2e=>{for(const _0x36768d of this['editor']['editing']['view']['document']['roots'])_0x968575?_0x3f2c2e['removeClass']('ck-editor__editable__overlay',_0x36768d):_0x3f2c2e['addClass']('ck-editor__editable__overlay',_0x36768d);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x12ff15=>null!==_0x12ff15),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0xf94829,_0x21d046,_0x552716)=>_0xf94829&&_0x552716?_0x21d046['changes']['getIndex'](_0x552716):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x51cb83,_0x404725)=>_0x51cb83?_0x404725['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0x513bdf);}['init'](){const _0x377a63=this['editor'],_0x18ad59=new ot(_0x377a63,{'direction':'backward'}),_0x11344e=new ot(_0x377a63,{'direction':'forward'});(_0x377a63['commands']['add']('showPreviousChange',_0x18ad59),_0x377a63['commands']['add']('showNextChange',_0x11344e),_0x377a63['commands']['add']('restoreRevision',new nt(_0x377a63)),this['on']('change:numberOfChanges',()=>{_0x18ad59['refresh'](),_0x11344e['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x377a63['enableReadOnlyMode']('revision-viewer'),_0x377a63['plugins']['has']('WidgetToolbarRepository'))&&_0x377a63['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x36ee04){return await this['_utils']['loadRevisionData'](_0x36ee04,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x36ee04);}async['getRevisionRootsAttributes'](_0x7a7270){return await this['_utils']['loadRevisionData'](_0x7a7270,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x7a7270);}async['compare'](_0x2d5b5f,_0x515b1d,_0x2805ad=!0x1){if(!this['isEnabled'])return;const _0x2c3db7=this['diff'],_0x2420ec=this['repository'],_0x4d0f09='string'==typeof _0x2d5b5f?_0x2420ec['getRevision'](_0x2d5b5f):_0x2d5b5f,_0x4da288='string'==typeof _0x515b1d?_0x2420ec['getRevision'](_0x515b1d):_0x515b1d,_0x5b400d=_0x4d0f09['id'],_0x2fe7bc=_0x4da288?_0x4da288['id']:null;if(!_0x2805ad&&this['diff']&&this['diff']['newRevisionId']===_0x5b400d&&this['diff']['oldRevisionId']===_0x2fe7bc)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new J(_0x5b400d,_0x2fe7bc);const _0x55281f=this['_getRevisionsRange'](_0x4d0f09,_0x4da288,!0x0)['map'](_0x34dab0=>this['_utils']['loadRevisionData'](_0x34dab0,this['adapter']));return _0x55281f['push'](new Promise(_0x4e8c39=>{setTimeout(_0x4e8c39,0x14);})),Promise['all'](_0x55281f)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x35db90=this['_getDiff'](_0x5b400d,_0x2fe7bc);for(const _0x4ad88b of _0x35db90['changes'])this['_changeIdToChange']['set'](_0x4ad88b['id'],_0x4ad88b);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x5eab10=>{for(const _0x68eac2 of this['editor']['model']['document']['getRootNames']())_0x5eab10['detachRoot'](_0x68eac2);for(const _0x158836 of Object['keys'](_0x35db90['model'])){const _0x491417=_0x5eab10['addRoot'](_0x158836);for(const _0x15648a of Object['keys'](_0x35db90['attributes'][_0x158836]))_0x5eab10['setAttribute'](_0x15648a,_0x35db90['attributes'][_0x158836][_0x15648a],_0x491417);_0x5eab10['insert'](_0x35db90['model'][_0x158836],_0x491417,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x35db90['changes'])),this['isReady']=!0x0;})['catch'](_0x586295=>{console['error'](_0x586295),this['_cleanUp'](),_0x2c3db7&&(this['diff']=_0x2c3db7),this['isReady']=!0x0;});}['addRevisionData'](_0x5aab31,_0x311508){const _0x8624ca=this['repository']['createRevision'](_0x5aab31);return _0x8624ca['on']('_update',(_0xf58507,_0x5756e0,_0x536b10)=>_0x311508(_0x5756e0,_0x536b10,_0x8624ca)),this['repository']['addRevision'](_0x8624ca),_0x8624ca;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x31d8e9=>{for(const _0x516670 of this['editor']['model']['document']['getRootNames']())_0x31d8e9['detachRoot'](_0x516670);});}['_sortAndFilterDiffChanges'](_0x154069){const _0x169bee=[],_0x1e7136=new Map();for(const _0x527d2a of this['editor']['model']['document']['getRootNames']()){const _0x32d2a7=this['editor']['editing']['view']['getDomRoot'](_0x527d2a);if(!_0x32d2a7)continue;const _0xf99fa8=_0x32d2a7['getClientRects']()['item'](0x0);_0xf99fa8&&(_0x169bee['push'](_0x527d2a),_0x1e7136['set'](_0x527d2a,_0xf99fa8));}return _0x169bee['sort']((_0x36e650,_0x39fa61)=>{const _0x4ec414=_0x1e7136['get'](_0x36e650),_0x2715e0=_0x1e7136['get'](_0x39fa61);return _0x4ec414['y']-_0x2715e0['y']||_0x4ec414['x']-_0x2715e0['x'];}),(_0x154069=_0x154069['filter'](_0x25b8d2=>_0x169bee['includes'](_0x25b8d2['rootName'])))['sort']((_0x20904b,_0x1db9b5)=>_0x169bee['indexOf'](_0x20904b['rootName'])-_0x169bee['indexOf'](_0x1db9b5['rootName'])),_0x154069;}['_makeTape'](_0x251b1e){const _0x3d28bc=Array['from'](_0x251b1e['markers'])['filter'](([_0x2d4de5,_0x445330])=>_0x2d4de5['startsWith']('revision:')&&!_0x445330['isCollapsed']),_0x18ec2d=Array['from'](this['editor']['model']['createRangeIn'](_0x251b1e)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x3d28bc['length'])for(const _0x1b3012 of _0x18ec2d){const [_0x94011e,_0x2f405f]=_0x3d28bc[0x0],[,_0x28d35d,_0x3ef31b]=_0x94011e['split'](':');if(_0x2f405f['end']['isEqual'](_0x1b3012['nextPosition'])&&_0x3d28bc['shift'](),(_0x1b3012['previousPosition']['isEqual'](_0x2f405f['start'])||_0x1b3012['previousPosition']['isAfter'](_0x2f405f['start']))&&('insertion'==_0x28d35d?_0x1b3012['isAdded']={'userId':_0x3ef31b}:'deletion'==_0x28d35d&&(_0x1b3012['isRemoved']={'userId':_0x3ef31b})),0x0==_0x3d28bc['length'])break;}return _0x18ec2d;}['_refreshStartEndIndex'](_0xe05fc9){const _0x2eb0af=new Map();for(let _0x294ca8=0x0;_0x294ca8<_0xe05fc9['length'];_0x294ca8++)'text'===_0xe05fc9[_0x294ca8]['type']?(_0xe05fc9[_0x294ca8]['item']['startIndex']=_0x294ca8,_0xe05fc9[_0x294ca8]['item']['endIndex']=_0x294ca8):('elementStart'===_0xe05fc9[_0x294ca8]['type']?_0xe05fc9[_0x294ca8]['item']['startIndex']=_0x294ca8:'elementEnd'===_0xe05fc9[_0x294ca8]['type']&&(_0xe05fc9[_0x294ca8]['item']['endIndex']=_0x294ca8),_0x2eb0af['set'](_0xe05fc9[_0x294ca8]['id'],_0x294ca8));for(const _0x13eb13 of _0x2eb0af['values']())'elementStart'===_0xe05fc9[_0x13eb13]['type']?_0xe05fc9[_0x13eb13]['item']['endIndex']=_0x2eb0af['get'](_0xe05fc9[_0x13eb13]['pairId']):'elementEnd'===_0xe05fc9[_0x13eb13]['type']&&(_0xe05fc9[_0x13eb13]['item']['startIndex']=_0x2eb0af['get'](_0xe05fc9[_0x13eb13]['pairId']));}['_processTape'](_0x4d72ad){for(let _0x2a6e97=0x0;_0x2a6e97<_0x4d72ad['length'];_0x2a6e97++){if('elementStart'===_0x4d72ad[_0x2a6e97]['type'])_0x4d72ad[_0x2a6e97]['item']['startIndex']=_0x2a6e97;else{if('elementEnd'===_0x4d72ad[_0x2a6e97]['type']){_0x4d72ad[_0x2a6e97]['item']['endIndex']=_0x2a6e97;const _0x30bc0a=_0x4d72ad[_0x2a6e97]['item']['startIndex'];_0x4d72ad[_0x30bc0a]['pairId']=_0x4d72ad[_0x2a6e97]['id'],_0x4d72ad[_0x2a6e97]['pairId']=_0x4d72ad[_0x30bc0a]['id'];}else _0x4d72ad[_0x2a6e97]['item']['startIndex']=_0x2a6e97,_0x4d72ad[_0x2a6e97]['item']['endIndex']=_0x2a6e97,_0x4d72ad[_0x2a6e97]['pairId']=null;}_0x4d72ad[_0x2a6e97]['markersStart']||(_0x4d72ad[_0x2a6e97]['markersStart']=[],_0x4d72ad[_0x2a6e97]['markersEnd']=[]);}}['_markInsertions'](_0x5bc937,_0x433cf4){const _0x1ed50b=_0x5bc937['filter'](_0x3a6606=>!_0x3a6606['isAdded']);for(let _0x2187d8=0x0;_0x2187d8<_0x433cf4['length'];_0x2187d8++)_0x433cf4[_0x2187d8]['isAdded']&&(_0x1ed50b[_0x2187d8]['isAdded']=_0x433cf4[_0x2187d8]['isAdded']);}['_getDiff'](_0x188909,_0x54d681=null){const _0xc4e4b5=this['repository']['getRevision'](_0x188909),_0x2d5899=_0x54d681?this['repository']['getRevision'](_0x54d681):null,_0x44849d=this['_getRevisionsRange'](_0xc4e4b5,_0x2d5899),_0x8481fd=_0x44849d[_0x44849d['length']-0x1],_0x29ace5=new Map(),_0x40a993={'model':{},'attributes':{},'changes':[]},_0x59d945=new Set(),_0x24180a=new Map();for(let _0x3d9a8c=_0x44849d['length']-0x1;_0x3d9a8c>=0x0;_0x3d9a8c--){const _0x2ab9f0=_0x44849d[_0x3d9a8c];for(const _0x2592eb of Object['keys'](_0x2ab9f0['diffData']))if(_0x2ab9f0['diffData'][_0x2592eb]['attachChange']){const _0x58758f=_0x2ab9f0['diffData'][_0x2592eb]['attachChange'];_0x58758f['isAttached']?(_0x59d945['add'](_0x2592eb),_0x24180a['has'](_0x2592eb)&&_0x24180a['get'](_0x2592eb)['userId']==_0x58758f['userId']?_0x24180a['delete'](_0x2592eb):_0x24180a['set'](_0x2592eb,_0x58758f)):_0x24180a['has'](_0x2592eb)?(_0x59d945['delete'](_0x2592eb),_0x24180a['delete'](_0x2592eb)):(_0x59d945['add'](_0x2592eb),_0x24180a['set'](_0x2592eb,_0x58758f));}else _0x59d945['add'](_0x2592eb);}for(const _0xedd14b of _0x59d945){const _0x559153=_0x24180a['has'](_0xedd14b)&&!_0x24180a['get'](_0xedd14b)['isAttached'];let _0xba4b17=_0x559153?_0x44849d['length']-0x1:0x0;const _0x4b662f=_0x559153?-0x1:0x1;for(;_0x44849d[_0xba4b17];){const _0x414a83=_0x44849d[_0xba4b17];if(_0x414a83['diffData'][_0xedd14b]){const _0x39cea7=_0x559153?_0x414a83['diffData'][_0xedd14b]['attributesBefore']:_0x414a83['diffData'][_0xedd14b]['attributesAfter'];_0x40a993['attributes'][_0xedd14b]=_0x39cea7?_0x1f8e55(_0x39cea7):{};break;}_0xba4b17+=_0x4b662f;}}for(const _0x58c0a1 of _0x44849d){_0x58c0a1['model']={};for(const _0x1371fa of _0x58c0a1['authors'])_0x29ace5['set'](_0x1371fa['id'],_0x1371fa);for(const _0xe0271 of _0x59d945){const _0x1a824d=_0x58c0a1['diffData'][_0xe0271]?_0x58c0a1['diffData'][_0xe0271]['insertions']:'[]',_0x23302a=_0x58c0a1['diffData'][_0xe0271]?_0x58c0a1['diffData'][_0xe0271]['deletions']:'[]';_0x58c0a1['model'][_0xe0271]={'insertions':this['_utils']['_makeModelFromViewString'](_0x1a824d),'deletions':this['_utils']['_makeModelFromViewString'](_0x23302a)};}}for(const _0x57094a of _0x59d945){let _0x213abe=null,_0x24ebeb=0x0;const _0x18fd72=new Map(Array['from'](_0xc4e4b5['model'][_0x57094a]['insertions']['markers'])['filter'](([_0x26697c])=>!_0x26697c['startsWith']('revision:')));let _0x2f559d=0x0;for(const _0x51ac60 of _0x44849d){const _0x47102b=this['_makeTape'](_0x51ac60['model'][_0x57094a]['insertions']);_0x51ac60==_0xc4e4b5?(_0x213abe=_0x47102b,_0x24ebeb=_0x213abe['length'],_0x213abe['forEach'](_0x532aec=>{_0x532aec['id']=_0x2f559d++;}),this['_processTape'](_0x213abe)):this['_markInsertions'](_0x213abe,_0x47102b);const _0x5c427b=_0x213abe['filter'](_0x4cd345=>!_0x4cd345['isAdded'])['map'](_0x18a15c=>_0x18a15c['id']);let _0x875917=0x0;const _0x35212c=this['_makeTape'](_0x51ac60['model'][_0x57094a]['deletions']);_0x35212c['forEach'](_0x49c570=>{_0x49c570['isRemoved']?_0x49c570['id']=_0x24ebeb++:_0x49c570['id']=_0x5c427b[_0x875917++];}),this['_processTape'](_0x35212c),this['_setDistance'](_0x213abe,'isAdded'),this['_setDistance'](_0x35212c,'isRemoved'),_0x51ac60==_0xc4e4b5&&this['_markMarkers'](_0x213abe,_0x18fd72),_0x213abe=this['_joinTapes'](_0x213abe,_0x35212c),this['_refreshStartEndIndex'](_0x213abe),this['_setDistance'](_0x213abe,'isRemoved');}_0x213abe=_0x213abe['filter'](_0xee964b=>!(_0xee964b['isAdded']&&_0xee964b['isRemoved']));const _0xadc28=new Map(_0x8481fd['model'][_0x57094a]['deletions']['markers']),_0x57401d=new Set(_0x18fd72['keys']());for(const _0x1c6101 of _0xadc28['keys']())_0x57401d['delete'](_0x1c6101);this['_markSuggestions'](_0x213abe,_0x57401d),this['_fixObsoleteTags'](_0x213abe),_0x213abe=this['_removeMissingPairs'](_0x213abe),_0x213abe=this['_markMismatchedRemovedTags'](_0x213abe),_0x213abe=this['_removeUnsupportedChanges'](_0x213abe);const {root:_0x51178b,changes:_0x15d2fb}=this['_makeModelFromTape'](_0x213abe,_0x29ace5,_0x57094a);_0x40a993['model'][_0x57094a]=_0x51178b;const _0x4011ec=_0x24180a['get'](_0x57094a);if(_0x4011ec){const _0x5c4443=_0x29ace5['get'](_0x4011ec['userId']),_0x57d63b=new G({'author':_0x5c4443,'type':_0x4011ec['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x57094a});_0x15d2fb['unshift'](_0x57d63b),_0x40a993['attributes'][_0x57094a]['revisionHistoryAttachChange']=_0x57d63b['id'];}_0x40a993['changes']=_0x40a993['changes']['concat'](_0x15d2fb);}return _0x40a993;}['_markMarkers'](_0x528454,_0x2609c8){for(let _0x2e6083=0x0;_0x2e6083<_0x528454['length'];_0x2e6083++)for(const [_0x44b40d,_0x1597a4]of _0x2609c8)!_0x1597a4['isCollapsed']&&_0x1597a4['start']['isEqual'](_0x528454[_0x2e6083]['previousPosition'])&&_0x528454[_0x2e6083]['markersStart']['push'](_0x44b40d),_0x1597a4['end']['isEqual'](_0x528454[_0x2e6083]['nextPosition'])&&_0x528454[_0x2e6083]['markersEnd']['push'](_0x44b40d);}['_joinTapes'](_0x151ed1,_0x257d0a){let _0x37fed8=[],_0xfa19e7=0x0,_0xb5096=0x0;for(;_0xfa19e7<_0x151ed1['length']||_0xb5096<_0x257d0a['length'];){const _0x53ee73=_0x151ed1[_0xfa19e7]||{},_0x516bfd=_0x257d0a[_0xb5096]||{};if(_0x53ee73['id']==_0x516bfd['id'])_0xfa19e7++,_0xb5096++,_0x37fed8['push'](_0x53ee73);else{if(_0x516bfd['isRemoved']&&_0x53ee73['isAdded']){const {commonTape:_0x43e5b0,iEnd:_0x18b25e,jEnd:_0x44cdc6}=this['_threeWayMerge'](_0x151ed1,_0xfa19e7,_0x257d0a,_0xb5096);_0x37fed8=_0x37fed8['concat'](_0x43e5b0),_0xfa19e7=_0x18b25e,_0xb5096=_0x44cdc6;}else _0x516bfd['isRemoved']?(_0xb5096++,_0x37fed8['push'](_0x516bfd)):(_0xfa19e7++,_0x37fed8['push'](_0x53ee73));}}return _0x37fed8;}['_markSuggestions'](_0xd00a4c,_0xb50610){const _0x377a42=[];for(let _0x3f47c6=0x0;_0x3f47c6<_0xd00a4c['length'];_0x3f47c6++){for(let _0x1af6c0=0x0;_0x1af6c0<_0xd00a4c[_0x3f47c6]['markersStart']['length'];_0x1af6c0++){const _0x544c9a=_0xd00a4c[_0x3f47c6]['markersStart'][_0x1af6c0];if(!_0xb50610['has'](_0x544c9a))continue;const {group:_0x371f5b,type:_0xe289fc,authorId:_0x4040dd}=_0xbe9772(_0x544c9a);'revision-suggestion'!=_0x371f5b||'insertion'!=_0xe289fc&&'deletion'!=_0xe289fc||(_0x377a42['unshift']({'type':_0xe289fc,'name':_0x544c9a,'userId':_0x4040dd}),_0xd00a4c[_0x3f47c6]['markersStart']['splice'](_0x1af6c0,0x1),_0x1af6c0--);}_0x2edfa1(_0xd00a4c[_0x3f47c6]);for(let _0x396a5f=0x0;_0x396a5f<_0xd00a4c[_0x3f47c6]['markersEnd']['length'];_0x396a5f++){const _0x4d813a=_0xd00a4c[_0x3f47c6]['markersEnd'][_0x396a5f];if(!_0xb50610['has'](_0x4d813a))continue;const {group:_0x934a48,type:_0x4c22ec}=_0xbe9772(_0x4d813a);if('revision-suggestion'!=_0x934a48||'insertion'!=_0x4c22ec&&'deletion'!=_0x4c22ec)continue;_0xd00a4c[_0x3f47c6]['markersEnd']['splice'](_0x396a5f,0x1),_0x396a5f--;const _0x5e17f1=_0x377a42['findIndex'](_0x31a289=>_0x31a289['name']==_0x4d813a);_0x5e17f1>-0x1&&_0x377a42['splice'](_0x5e17f1,0x1);}}function _0xbe9772(_0x498117){const _0x53ffcf=_0x498117['split'](':');return{'group':_0x53ffcf[0x0],'type':_0x53ffcf[0x1],'subType':_0x53ffcf['length']>=0x5?_0x53ffcf[0x2]:null,'id':_0x53ffcf['length']<0x5?_0x53ffcf[0x2]:_0x53ffcf[0x3],'authorId':_0x53ffcf['length']<0x5?_0x53ffcf[0x3]:_0x53ffcf[0x4],'markerCount':0x6==_0x53ffcf['length']?_0x53ffcf[0x5]:null};}function _0x2edfa1(_0x26d409){for(let _0x328db3=0x0;_0x328db3<_0x377a42['length'];_0x328db3++){if(_0x26d409['isAdded']&&'insertion'==_0x377a42[_0x328db3]['type']&&_0x26d409['isAdded']['userId']==_0x377a42[_0x328db3]['userId'])return _0x26d409['isAddSuggestion']=_0x377a42[_0x328db3],void delete _0x26d409['isAdded'];if(!_0x26d409['isAdded']&&!_0x26d409['isRemoved']&&'deletion'==_0x377a42[_0x328db3]['type'])return void(_0x26d409['isRemoveSuggestion']=_0x377a42[_0x328db3]);}}}['_setDistance'](_0x392f6c,_0x7f2969){let _0x2635d4=0x0,_0x29d288=!0x1;const _0x1b5a46=new Map();for(const _0x267873 of _0x392f6c)_0x267873[_0x7f2969]?_0x29d288&&(_0x2635d4++,_0x29d288=!0x1):(_0x2635d4++,_0x29d288=!0x0),_0x1b5a46['set'](_0x267873['id'],_0x2635d4);for(let _0x541611=0x0;_0x541611<_0x392f6c['length'];_0x541611++){if('isRemoved'==_0x7f2969&&_0x392f6c[_0x541611]['isAdded']||'isAdded'==_0x7f2969&&_0x392f6c[_0x541611]['isRemoved'])continue;if('text'==_0x392f6c[_0x541611]['type']){_0x392f6c[_0x541611]['distance']=0x0;continue;}const _0x4c567b=_0x1b5a46['get'](_0x392f6c[_0x541611]['pairId']),_0x2c902b=_0x1b5a46['get'](_0x392f6c[_0x541611]['id']);_0x392f6c[_0x541611]['distance']=_0x4c567b-_0x2c902b;}}['_getRevisionsRange'](_0x145f38,_0x194413,_0x38d049=!0x1){const _0x35b82d=[];let _0x41cf41=this['repository']['getIndex'](_0x145f38),_0x50cca8=this['repository']['getIndex'](_0x194413);for(-0x1==_0x50cca8&&(_0x50cca8=this['repository']['_revisions']['length'],_0x38d049=!0x1);_0x41cf41<_0x50cca8;)_0x35b82d['push'](this['repository']['getRevision'](_0x41cf41)),_0x41cf41++;return _0x38d049&&_0x35b82d['push'](this['repository']['getRevision'](_0x41cf41)),_0x35b82d;}['_threeWayMerge'](_0xab196a,_0x392190,_0x51c31f,_0x19f7a1){const _0x13c7b2=this['editor']['model']['schema'];let _0x5ca47d=_0x392190;for(;_0xab196a[_0x5ca47d]&&_0xab196a[_0x5ca47d]['isAdded'];)_0x5ca47d++;let _0x3e302b=_0x19f7a1;for(;_0x51c31f[_0x3e302b]&&_0x51c31f[_0x3e302b]['isRemoved'];)_0x3e302b++;_0x520fd3(_0xab196a,_0x392190,_0x5ca47d),_0x520fd3(_0x51c31f,_0x19f7a1,_0x3e302b);const _0x5157eb=_0x51c31f['slice'](_0x19f7a1,_0x3e302b)['concat'](_0xab196a['slice'](_0x392190,_0x5ca47d));return _0x5157eb['sort']((_0x49ae3b,_0x3e1d6c)=>_0x49ae3b['side']!=_0x3e1d6c['side']?_0x49ae3b['side']-_0x3e1d6c['side']:_0x49ae3b['level']!=_0x3e1d6c['level']?_0x49ae3b['level']-_0x3e1d6c['level']:_0x49ae3b['distance']!=_0x3e1d6c['distance']?_0x3e1d6c['distance']-_0x49ae3b['distance']:!!_0x49ae3b['isAdded']!=!!_0x3e1d6c['isAdded']?-0x1==_0x49ae3b['side']||0x0==_0x49ae3b['side']?_0x49ae3b['isAdded']?-0x1:0x1:_0x49ae3b['isAdded']?0x1:-0x1:_0x49ae3b['index']-_0x3e1d6c['index']),{'commonTape':_0x5157eb,'iEnd':_0x5ca47d,'jEnd':_0x3e302b};function _0x520fd3(_0x51e06b,_0x3c252d,_0x24e34d){let _0x24d237=-0x1,_0x2014e7=Number['POSITIVE_INFINITY'],_0x407b9d=!0x0;for(let _0x2f54bb=_0x3c252d;_0x2f54bb<_0x24e34d;_0x2f54bb++)if(_0x13c7b2['isInline'](_0x51e06b[_0x2f54bb]['item'])||(_0x407b9d=!0x1),_0x51e06b[_0x2f54bb]['item']['startIndex']<_0x3c252d&&(_0x24d237=_0x2f54bb),_0x51e06b[_0x2f54bb]['item']['endIndex']>=_0x24e34d){_0x2014e7=_0x2f54bb;break;}_0x407b9d&&(_0x24d237=_0x24e34d-0x1);for(let _0x133075=_0x3c252d;_0x133075<_0x24e34d;_0x133075++)_0x51e06b[_0x133075]['side']=_0x133075<=_0x24d237?-0x1:_0x133075<_0x2014e7?0x0:0x1,_0x51e06b[_0x133075]['index']=_0x133075;let _0x3203a8=0x0;for(let _0x2db516=_0x3c252d;_0x2db516<=_0x24d237;_0x2db516++)0x0==_0x51e06b[_0x2db516]['distance']?_0x51e06b[_0x2db516]['level']=_0x3203a8:(_0x3203a8++,_0x51e06b[_0x2db516]['level']=_0x3203a8,_0x3203a8++);for(let _0x5ce900=_0x3c252d;_0x5ce900<_0x24e34d;_0x5ce900++)0x0==_0x51e06b[_0x5ce900]['side']&&(_0x51e06b[_0x5ce900]['level']=_0x3203a8);_0x3203a8=0x0;for(let _0x6cb9b7=_0x24e34d-0x1;_0x6cb9b7>=_0x2014e7;_0x6cb9b7--)0x0==_0x51e06b[_0x6cb9b7]['distance']?_0x51e06b[_0x6cb9b7]['level']=_0x3203a8:(_0x3203a8--,_0x51e06b[_0x6cb9b7]['level']=_0x3203a8,_0x3203a8--);}}['_fixObsoleteTags'](_0x34e7d2){const _0x4f10fc=new Map(),_0x5b019d=this['editor']['model']['schema'];for(let _0x9f8e97=0x1;_0x9f8e97<_0x34e7d2['length'];_0x9f8e97++){let _0x260b43,_0x4a57d2,_0x13df6f;const _0x4d5d25=_0x34e7d2[_0x9f8e97],_0x38698f=_0x34e7d2[_0x9f8e97-0x1];if('text'==_0x4d5d25['type'])continue;if(_0x4d5d25['type']!=_0x38698f['type'])continue;if(!_0x5b019d['isBlock'](_0x38698f['item'])||_0x5b019d['isLimit'](_0x38698f['item']))continue;if(!_0x5b019d['isBlock'](_0x4d5d25['item'])||_0x5b019d['isLimit'](_0x4d5d25['item']))continue;if((_0x34e7d2[_0x9f8e97]['isAdded']||_0x34e7d2[_0x9f8e97]['isAddSuggestion'])&&_0x34e7d2[_0x9f8e97-0x1]['isRemoved'])_0x260b43=_0x34e7d2[_0x9f8e97],_0x4a57d2=_0x34e7d2[_0x9f8e97-0x1],_0x13df6f=_0x9f8e97-0x1;else{if(!_0x34e7d2[_0x9f8e97]['isRemoved']||!_0x34e7d2[_0x9f8e97-0x1]['isAdded']&&!_0x34e7d2[_0x9f8e97-0x1]['isAddSuggestion'])continue;_0x260b43=_0x34e7d2[_0x9f8e97-0x1],_0x4a57d2=_0x34e7d2[_0x9f8e97],_0x13df6f=_0x9f8e97;}const _0x39ac63=_0x260b43['level']==_0x4a57d2['level'],_0x48b6e2=Math['abs'](_0x260b43['level'])<Math['abs'](_0x4a57d2['level'])&&0x0==_0x4a57d2['distance'];(_0x39ac63||_0x48b6e2)&&(_0x4f10fc['set'](_0x4a57d2['id'],_0x260b43['id']),_0x34e7d2['splice'](_0x13df6f,0x1),_0x9f8e97--,_0x260b43['isAdded']=!0x1);}for(let _0x311b63=0x0;_0x311b63<_0x34e7d2['length'];_0x311b63++)_0x4f10fc['has'](_0x34e7d2[_0x311b63]['pairId'])&&(_0x34e7d2[_0x311b63]['pairId']=_0x4f10fc['get'](_0x34e7d2[_0x311b63]['pairId']));}['_removeMissingPairs'](_0x5bb86d){const _0x439c50=new Set(_0x5bb86d['map'](_0x20234a=>_0x20234a['id']));for(let _0x3ce10b=0x0;_0x3ce10b<_0x5bb86d['length'];_0x3ce10b++)_0x439c50['has'](_0x5bb86d[_0x3ce10b]['pairId'])||0x0==_0x5bb86d[_0x3ce10b]['distance']||(_0x5bb86d[_0x3ce10b]['isIncorrect']=!0x0);return _0x5bb86d['filter'](_0x236af3=>!_0x236af3['isIncorrect']);}['_markMismatchedRemovedTags'](_0x263020){const _0x300e37=new Set();for(let _0x10f801=0x0;_0x10f801<_0x263020['length'];_0x10f801++){if(_0x300e37['has'](_0x263020[_0x10f801]['id'])&&_0x263020[_0x10f801]['isRemoved']&&(_0x263020[_0x10f801]['isIncorrect']=!0x0),_0x263020[_0x10f801]['isIncorrect'])continue;if(0x0==_0x263020[_0x10f801]['distance'])continue;if('elementStart'!=_0x263020[_0x10f801]['type'])continue;if(null==_0x263020[_0x10f801]['pairId'])continue;let _0x2fc3c7=_0x10f801+0x1,_0x558983=0x0;for(;_0x263020[_0x2fc3c7]['id']!=_0x263020[_0x10f801]['pairId'];)'elementStart'==_0x263020[_0x2fc3c7]['type']?_0x558983++:'elementEnd'==_0x263020[_0x2fc3c7]['type']&&_0x558983--,_0x2fc3c7++;if(0x0!=_0x558983){if(_0x263020[_0x10f801]['isRemoved'])_0x263020[_0x10f801]['isIncorrect']=!0x0;else{for(;_0x2fc3c7!=_0x10f801;)_0x263020[_0x2fc3c7]['isRemoved']&&0x0!=_0x263020[_0x2fc3c7]['distance']&&(_0x263020[_0x2fc3c7]['isIncorrect']=!0x0,_0x300e37['add'](_0x263020[_0x2fc3c7]['pairId'])),_0x2fc3c7--;}}}return _0x263020['filter'](_0x5a37b6=>!_0x5a37b6['isIncorrect']);}['_removeUnsupportedChanges'](_0x3800d9){const _0xba78c1=this['editor']['model']['schema'];for(let _0x11844e=0x0;_0x11844e<_0x3800d9['length'];_0x11844e++){if(!(_0x3800d9[_0x11844e]['isAdded']||_0x3800d9[_0x11844e]['isAddSuggestion']||_0x3800d9[_0x11844e]['isRemoved']||_0x3800d9[_0x11844e]['isRemoveSuggestion']))continue;if(0x0==_0x3800d9[_0x11844e]['distance'])continue;const _0x267575=_0x3800d9[_0x11844e]['item'];_0xba78c1['isBlock'](_0x267575)||_0xba78c1['isLimit'](_0x267575)||(_0x3800d9[_0x11844e]['isAdded']&&delete _0x3800d9[_0x11844e]['isAdded'],_0x3800d9[_0x11844e]['isAddSuggestion']&&delete _0x3800d9[_0x11844e]['isAddSuggestion'],_0x3800d9[_0x11844e]['isRemoveSuggestion']&&delete _0x3800d9[_0x11844e]['isRemoveSuggestion'],_0x3800d9[_0x11844e]['isRemoved']&&(_0x3800d9[_0x11844e]['isIncorrect']=!0x0));}return _0x3800d9['filter'](_0x4b6a40=>!_0x4b6a40['isIncorrect']);}['_makeModelFromTape'](_0x2612cf,_0x4c56f5,_0xc5b44c){const _0x4642c2=new _0x3caf08(),_0x909289=[],_0x51dd43=new Map(),_0x139677=this['editor']['model'],_0x2dcc0f=_0x139677['schema'],_0x2982f7=[_0x4642c2],_0x4b9487={},_0x53f499={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x3bbe78=null;const _0x42ed8a=[0x0];for(let _0x4b2742=0x0;_0x4b2742<_0x2612cf['length'];_0x4b2742++)if('elementStart'===_0x2612cf[_0x4b2742]['type']){_0x2612cf[_0x4b2742]['previousPosition']=_0x139677['createPositionFromPath'](_0x4642c2,_0x42ed8a);const _0x51b641=new _0x4b8223(_0x2612cf[_0x4b2742]['item']['name'],_0x2612cf[_0x4b2742]['item']['getAttributes']());_0x2982f7[0x0]['_appendChild'](_0x51b641),_0x42ed8a['push'](0x0),_0x2982f7['unshift'](_0x51b641),_0x2612cf[_0x4b2742]['nextPosition']=_0x139677['createPositionFromPath'](_0x4642c2,_0x42ed8a);}else'elementEnd'===_0x2612cf[_0x4b2742]['type']?(_0x2982f7['shift'](),_0x2612cf[_0x4b2742]['previousPosition']=_0x139677['createPositionFromPath'](_0x4642c2,_0x42ed8a),_0x42ed8a['pop'](),_0x42ed8a[_0x42ed8a['length']-0x1]++,_0x2612cf[_0x4b2742]['nextPosition']=_0x139677['createPositionFromPath'](_0x4642c2,_0x42ed8a)):(_0x2612cf[_0x4b2742]['previousPosition']=_0x139677['createPositionFromPath'](_0x4642c2,_0x42ed8a),_0x3bbe78?_0x3bbe78['_data']+=_0x2612cf[_0x4b2742]['item']['data']:_0x3bbe78=new _0x390447(_0x2612cf[_0x4b2742]['item']['data'],_0x2612cf[_0x4b2742]['item']['getAttributes']()),_0x2612cf[_0x4b2742+0x1]&&'text'===_0x2612cf[_0x4b2742+0x1]['type']&&_0x24e2fd(_0x3bbe78,_0x2612cf[_0x4b2742+0x1]['item'])||(_0x2982f7[0x0]['_appendChild'](_0x3bbe78),_0x3bbe78=null),_0x42ed8a[_0x42ed8a['length']-0x1]+=_0x2612cf[_0x4b2742]['item']['offsetSize'],_0x2612cf[_0x4b2742]['nextPosition']=_0x139677['createPositionFromPath'](_0x4642c2,_0x42ed8a));for(let _0x31dbc8=0x0;_0x31dbc8<_0x2612cf['length'];_0x31dbc8++){const _0x5c2c36=_0x2612cf[_0x31dbc8]['previousPosition'],_0x60cf14=_0x2612cf[_0x31dbc8]['nextPosition'];for(const _0xbbfbd0 of _0x2612cf[_0x31dbc8]['markersStart'])_0x51dd43['set'](_0xbbfbd0,{'start':_0x5c2c36,'end':null});_0x1b2714('isRemoveSuggestion',_0x31dbc8,_0x5c2c36,_0x60cf14),_0x1b2714('isAddSuggestion',_0x31dbc8,_0x5c2c36,_0x60cf14),_0x1b2714('isRemoved',_0x31dbc8,_0x5c2c36,_0x60cf14),_0x1b2714('isAdded',_0x31dbc8,_0x5c2c36,_0x60cf14);for(const _0x19f8bc of _0x2612cf[_0x31dbc8]['markersEnd']){const _0x22052e=_0x51dd43['get'](_0x19f8bc);_0x22052e?_0x22052e['end']=_0x60cf14:_0x51dd43['set'](_0x19f8bc,{'start':_0x60cf14,'end':_0x60cf14});}}for(const [_0x3a9495,_0x29b246]of _0x51dd43){const _0x282137=this['editor']['model']['createRange'](_0x29b246['start'],_0x29b246['end']);_0x4642c2['markers']['set'](_0x3a9495,_0x282137);}return _0x909289['sort']((_0x33998f,_0x5a9a95)=>{const _0x2fb628=_0x4642c2['markers']['get']('revision:'+_0x33998f['id']),_0x4955d5=_0x4642c2['markers']['get']('revision:'+_0x5a9a95['id']);return _0x2fb628['start']['isBefore'](_0x4955d5['start'])?-0x1:_0x2fb628['start']['isAfter'](_0x4955d5['start'])?0x1:_0x2fb628['end']['isBefore'](_0x4955d5['end'])?-0x1:_0x2fb628['end']['isAfter'](_0x4955d5['end'])?0x1:'add'===_0x33998f['type']?-0x1:0x1;}),{'root':_0x4642c2,'changes':_0x909289};function _0x1b2714(_0x437f09,_0x52016f,_0x3a04ea,_0x39e7a0){const _0x468927=!!_0x2612cf[_0x52016f][_0x437f09],_0x3667fb=_0x468927?_0x2612cf[_0x52016f][_0x437f09]['userId']:null,_0x1cb06e=_0x52016f===_0x2612cf['length']-0x1,_0x3ef97f=_0x53f499[_0x437f09][0x0],_0x13048c=_0x2dcc0f['isObject'](_0x2612cf[_0x52016f]['item']);!_0x4b9487[_0x437f09]&&_0x468927?_0x4b9487[_0x437f09]={'start':_0x3a04ea,'tapeItem':_0x2612cf[_0x52016f],'userId':_0x3667fb,'type':_0x437f09}:_0x4b9487[_0x437f09]&&!_0x468927?(_0x4b9487[_0x437f09]['end']=_0x3a04ea,_0x31fe21(_0x4b9487[_0x437f09]),_0x4b9487[_0x437f09]=null):_0x4b9487[_0x437f09]&&_0x468927&&_0x4b9487[_0x437f09]['userId']!==_0x3667fb&&(_0x4b9487[_0x437f09]['end']=_0x3a04ea,_0x3ef97f&&_0x3ef97f['userId']===_0x4b9487[_0x437f09]['userId']||_0x31fe21(_0x4b9487[_0x437f09]),_0x4b9487[_0x437f09]={'start':_0x3a04ea,'tapeItem':_0x2612cf[_0x52016f],'userId':_0x3667fb,'type':_0x437f09}),_0x4b9487[_0x437f09]&&_0x13048c&&('elementStart'!==_0x2612cf[_0x52016f]['type']||_0x3ef97f&&_0x3ef97f['userId']===_0x3667fb||_0x53f499[_0x437f09]['unshift']({'userId':_0x3667fb,'object':_0x2612cf[_0x52016f]['item'],'change':_0x4b9487[_0x437f09]}),'elementEnd'===_0x2612cf[_0x52016f]['type']&&_0x3ef97f&&_0x3ef97f['object']===_0x2612cf[_0x52016f]['item']&&(_0x53f499[_0x437f09]['shift'](),_0x4b9487[_0x437f09]=_0x3ef97f['change'])),_0x4b9487[_0x437f09]&&_0x1cb06e&&(_0x4b9487[_0x437f09]['end']=_0x39e7a0,_0x31fe21(_0x4b9487[_0x437f09]),_0x4b9487[_0x437f09]=null);}function _0x31fe21({start:_0x15f6d8,end:_0x517e46,tapeItem:_0x2e27fd,userId:_0xbaa1f1,type:_0x273c56}){const _0x4e5a28=_0x2e27fd['item'],_0x2f1a49=_0x139677['schema']['isBlock'](_0x4e5a28)&&!_0x139677['schema']['isLimit'](_0x4e5a28),_0x23630a=_0x15f6d8['nodeAfter']==_0x517e46['parent']&&_0x517e46['isAtStart'];if(_0x2f1a49&&_0x23630a)return;const _0x183de2=_0x139677['createRange'](_0x15f6d8,_0x517e46),_0x1a27eb=_0x4c56f5['get'](_0xbaa1f1),_0x5c4864=new G({'author':_0x1a27eb,'type':'isAdded'==_0x273c56||'isAddSuggestion'==_0x273c56?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x273c56||'isRemoveSuggestion'==_0x273c56},'createdAt':new Date(),'rootName':_0xc5b44c});_0x909289['push'](_0x5c4864),_0x4642c2['markers']['set']('revision:'+_0x5c4864['id'],_0x183de2);}function _0x24e2fd(_0x497f57,_0x9a7a53){const _0x5c4a9c=_0x497f57['getAttributes'](),_0x56afde=_0x9a7a53['getAttributes']();for(const _0x293af7 of _0x5c4a9c){if(_0x293af7[0x1]!==_0x9a7a53['getAttribute'](_0x293af7[0x0]))return!0x1;_0x56afde['next']();}return _0x56afde['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x9abfce=>{const _0x5a098f=_0x9abfce['markerName']['split'](':')[0x1],_0x31de19=this['_getChangeFromId'](_0x5a098f);if(!_0x31de19)return null;const _0x54fff0='add'==_0x31de19['type']?'insertion':'deletion',_0x445c9a=['ck-suggestion-marker','ck-suggestion-marker-'+_0x54fff0];return _0x31de19['data']['isSuggestion']&&_0x445c9a['push']('ck-suggestion-marker-'+_0x54fff0+'-new'),this['activeChange']==_0x31de19&&_0x445c9a['push']('ck-suggestion-marker--active'),{'classes':_0x445c9a,'attributes':{'data-change-id':_0x5a098f}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x3db2f9=>{_0x3db2f9['on']('element:pre',(_0x32aca6,_0x47d634,_0x24ffeb)=>{const _0x12d79a=_0x47d634['viewItem']['getChild'](0x0);if(!_0x12d79a||!_0x12d79a['is']('element','code'))return;if(!_0x24ffeb['consumable']['consume'](_0x12d79a,{'attributes':['vid_start','vid_end']}))return;const _0x4e99d8=_0x47d634['modelRange']['start']['nodeAfter'];_0x24ffeb['writer']['setAttribute']('vid_start',_0x12d79a['getAttribute']('vid_start'),_0x4e99d8),_0x24ffeb['writer']['setAttribute']('vid_end',_0x12d79a['getAttribute']('vid_end'),_0x4e99d8);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x173532=>{_0x173532['on']('element',(_0x16b0ca,_0x376bf0,_0x485ba7)=>{if(!_0x485ba7['consumable']['consume'](_0x376bf0['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x376bf0['modelRange']['isCollapsed'])return;const _0x30445f=_0x376bf0['modelRange']['start']['nodeAfter'];_0x30445f['hasAttribute']('vid_start')||_0x30445f['hasAttribute']('vid')||(_0x485ba7['writer']['setAttribute']('vid_start',_0x376bf0['viewItem']['getAttribute']('vid_start'),_0x30445f),_0x485ba7['writer']['setAttribute']('vid_end',_0x376bf0['viewItem']['getAttribute']('vid_end'),_0x30445f));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x2a201a=>_0x2a201a['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x471453,[,_0x10340b])=>{['vid_start','vid_end','vid']['includes'](_0x10340b)&&(_0x471453['return']=!0x0,_0x471453['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x25997b=>{_0x25997b['on']('attribute:vid',(_0x51cc99,_0x3057db,_0x1585e5)=>{if('\x20'!=_0x3057db['item']['data']||_0x3057db['item']['parent']['maxOffset']>0x1)return;if(!_0x1585e5['consumable']['consume'](_0x3057db['item'],_0x51cc99['name']))return;const _0x34b8ad=_0x1585e5['writer'],_0x18c65f=_0x1585e5['mapper']['toViewRange'](_0x3057db['range']);_0x34b8ad['wrap'](_0x18c65f,_0x34b8ad['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0xf94cb7){const _0x45962f=_0xf94cb7['plugins']['get']('RevisionViewer');return(_0x522029,_0x8d012,_0x522692)=>{const _0x307eac=_0x8d012['markerName']['split'](':')[0x1],_0xefe13b=_0x45962f['_getChangeFromId'](_0x307eac);if(!_0xefe13b)return null;const _0x5bc0d9='add'==_0xefe13b['type']?'split':'merge';if(!_0x522692['consumable']['test'](_0x8d012['markerRange'],_0x522029['name']))return;const _0x3759ba=_0x8d012['markerRange']['getWalker'](),_0x1522da=_0x8d012['markerRange']['start'],_0x1554fb=_0xf94cb7['model']['schema'];let _0x273f18=null,_0x1c7783=null,_0x29f0ad=!0x1,_0x2e69ac=!0x1;for(const _0x538152 of _0x3759ba){const _0x306ff9=_0x538152['item'];_0x29f0ad=_0x29f0ad||_0x1554fb['isContent'](_0x306ff9);const _0x51c68a=_0x522692['mapper']['toViewElement'](_0x306ff9);if(_0x51c68a&&_0x51c68a['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x538152['type']&&(_0x1554fb['isBlock'](_0x306ff9)&&!_0x1554fb['isLimit'](_0x306ff9)&&(_0x306ff9['nextSibling']||_0x1522da['isAtEnd']?_0x273f18&&_0x273f18['parent']==_0x306ff9||(_0x273f18=_0x306ff9,_0x4f00b9(_0x538152['previousPosition']),_0x2e69ac=!0x0):_0x1c7783=_0x1c7783||_0x538152['previousPosition']));}function _0x4f00b9(_0x1bad9a){const _0x13f5bf=_0x522692['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x5bc0d9}),_0x3f02f6=_0x522692['mapper']['toViewPosition'](_0x1bad9a);_0xefe13b['data']['isSuggestion']&&_0x522692['writer']['addClass']('ck-suggestion-marker-'+_0x5bc0d9+'-new',_0x13f5bf),_0x45962f['activeChange']==_0xefe13b&&_0x522692['writer']['addClass']('ck-suggestion-marker--active',_0x13f5bf),_0x522692['writer']['insert'](_0x3f02f6,_0x13f5bf),_0x522692['mapper']['bindElementToMarker'](_0x13f5bf,_0x8d012['markerName']);}_0x29f0ad||_0x2e69ac||!_0x1c7783||_0x4f00b9(_0x1c7783);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x4de4ff,_0x50626e,_0x5f242d)=>{const _0x1a93e9=_0x5f242d['mapper']['markerNameToElements'](_0x50626e['markerName']);if(_0x1a93e9){for(const _0x4c17ed of _0x1a93e9)(_0x4c17ed['hasClass']('ck-suggestion-marker-split')||_0x4c17ed['hasClass']('ck-suggestion-marker-merge'))&&(_0x5f242d['mapper']['unbindElementFromMarkerName'](_0x4c17ed,_0x50626e['markerName']),_0x5f242d['writer']['remove'](_0x4c17ed));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x30c17a,_0x27bc27,_0x98c8d3)=>{const _0x5231e5=_0x27bc27['markerName']['split'](':')[0x1],_0x26e06f=this['_getChangeFromId'](_0x5231e5);if(!_0x26e06f)return null;const _0x212094='add'==_0x26e06f['type']?'split':'merge';if(_0x98c8d3['consumable']['test'](_0x27bc27['markerRange'],_0x30c17a['name']))for(const _0x2acaa7 of _0x27bc27['markerRange']['getItems']()){if(!_0x2acaa7['is']('element','softBreak'))continue;const _0x1c120f=_0x98c8d3['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x212094}),_0x5164e8=_0x98c8d3['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x2acaa7));_0x26e06f['data']['isSuggestion']&&_0x98c8d3['writer']['addClass']('ck-suggestion-marker-'+_0x212094+'-new',_0x1c120f),this['activeChange']==_0x26e06f&&_0x98c8d3['writer']['addClass']('ck-suggestion-marker--active',_0x1c120f),_0x98c8d3['writer']['insert'](_0x5164e8,_0x1c120f),_0x98c8d3['mapper']['bindElementToMarker'](_0x1c120f,_0x27bc27['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x2844e6=>{for(const _0x6df605 of this['editor']['model']['document']['getRootNames']()){const _0x49ae55=this['editor']['model']['document']['getRoot'](_0x6df605),_0x4473bd=this['editor']['editing']['view']['document']['getRoot'](_0x6df605);if(_0x4473bd){const _0x1e68b4=_0x49ae55['getAttribute']('revisionHistoryAttachChange');if(_0x2844e6['removeAttribute']('data-change-id',_0x4473bd),_0x2844e6['removeClass']('ck-revision-history-root-add',_0x4473bd),_0x2844e6['removeClass']('ck-revision-history-root-remove',_0x4473bd),_0x2844e6['removeClass']('ck-revision-history-root--active',_0x4473bd),_0x1e68b4){const _0x1aaa53=this['_getChangeFromId'](_0x1e68b4);if(!_0x1aaa53)return null;_0x2844e6['setAttribute']('data-change-id',_0x1e68b4,_0x4473bd),_0x2844e6['addClass']('ck-revision-history-root-'+_0x1aaa53['type'],_0x4473bd),this['activeChange']==_0x1aaa53&&_0x2844e6['addClass']('ck-revision-history-root--active',_0x4473bd);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x140dc=>'revision-comment:'+_0x140dc,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x594af4=>'revision-suggestion:'+_0x594af4,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x3df64f=>({'name':'suggestion:'+_0x3df64f,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x2327f7=>{const _0x5d1f07=_0x2327f7['markerName']['split'](':')[0x1];return'insertion'!=_0x5d1f07&&'deletion'!=_0x5d1f07?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x5d1f07]};}}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:deletion',Q(this['editor'],'merge'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:insertion',Q(this['editor'],'split'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision-suggestion',(_0x3d3807,_0x3c9b9b,_0x171873)=>{const _0x25dbb0=_0x171873['mapper']['markerNameToElements'](_0x3c9b9b['markerName']);if(_0x25dbb0){for(const _0x126816 of _0x25dbb0)_0x126816['is']('uiElement')&&(_0x171873['mapper']['unbindElementFromMarkerName'](_0x126816,_0x3c9b9b['markerName']),_0x171873['writer']['remove'](_0x126816));}},{'priority':'high'});}['_getChangeFromId'](_0x1b489c){return this['_changeIdToChange']['get'](_0x1b489c);}['_getViewForChange'](_0x52a834){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new z(this['editor']['locale'],_0x52a834),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x10e724,_0x1e3268,_0x27ccbe,_0x2bc7a5)=>{_0x2bc7a5&&this['_balloon']['remove'](_0x2bc7a5),_0x27ccbe&&(this['_balloon']['add']({'view':_0x27ccbe,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x31d143=this['editor']['editing'],_0x17c0ed=this['_getChangeFromId'](_0x27ccbe['changeId']);let _0x4c630d;if(_0x17c0ed['data']['isOnRoot']){const _0x3789fc=_0x31d143['view']['getDomRoot'](_0x17c0ed['rootName']);_0x4c630d=Array['from'](_0x3789fc['getClientRects']());}else{const _0x262410=this['editor']['model']['markers']['get']('revision:'+_0x27ccbe['changeId']);_0x4c630d=Array['from'](_0x31d143['mapper']['markerNameToElements'](_0x262410['name']))['map'](_0x487540=>_0x31d143['view']['domConverter']['mapViewToDom'](_0x487540))['map'](_0x9fa624=>Array['from'](_0x9fa624['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x4c630d[0x0];return _0x4c630d['find'](_0x272ed8=>_0x272ed8['top']-0x3<=this['_activeViewTarget']['y']&&_0x272ed8['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x272ed8['left']-0x3<=this['_activeViewTarget']['x']&&_0x272ed8['right']+0x3>=this['_activeViewTarget']['x'])||_0x4c630d[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x562579,_0x257edc,_0x5bfd81,_0x40a591)=>{this['activeView']=_0x5bfd81?this['_getViewForChange'](_0x5bfd81):null,this['editor']['model']['change'](()=>{const _0x54c996=this['editor']['editing'];_0x40a591&&(_0x40a591['data']['isOnRoot']?_0x54c996['view']['change'](_0xde3672=>{_0xde3672['removeClass']('ck-revision-history-root--active',_0x54c996['view']['document']['getRoot'](_0x40a591['rootName']));}):_0x54c996['reconvertMarker']('revision:'+_0x40a591['id'])),_0x5bfd81&&(_0x5bfd81['data']['isOnRoot']?_0x54c996['view']['change'](_0x213394=>{_0x213394['addClass']('ck-revision-history-root--active',_0x54c996['view']['document']['getRoot'](_0x5bfd81['rootName']));}):_0x54c996['reconvertMarker']('revision:'+_0x5bfd81['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x70a5d2,_0x35d027)=>{if(this['activeChange'])return;const _0x35ec54=this['_findChangeIdFromDomTarget'](_0x35d027['target']),_0x24dd8e=this['_changeIdToChange']['get'](_0x35ec54);_0x24dd8e?(this['_activeViewTarget']={'x':_0x35d027['domEvent']['x'],'y':_0x35d027['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x24dd8e)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x2678d3,_0xff8008)=>{const _0x4d54ef=this['_findChangeIdFromDomTarget'](_0xff8008['target']),_0x331628=this['_changeIdToChange']['get'](_0x4d54ef);_0x331628?(this['_activeViewTarget']={'x':_0xff8008['domEvent']['x'],'y':_0xff8008['domEvent']['y']},_0x331628===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x331628):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x58826f){do{const _0x2340f0=_0x58826f['getAttribute']('data-change-id');if(_0x2340f0)return _0x2340f0;_0x58826f=_0x58826f['parent'];}while(_0x58826f);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x27a496=>{for(const _0x18f4b0 of this['editor']['model']['markers'])_0x27a496['removeMarker'](_0x18f4b0);});}}function Q(_0x1d19f9,_0x345707){return(_0x3cdf22,_0x1baeca,_0xecc2a3)=>{if(!_0xecc2a3['consumable']['test'](_0x1baeca['markerRange'],_0x3cdf22['name']))return;const _0x23e6c6=_0x1baeca['markerRange']['getWalker'](),_0x1e3561=_0x1baeca['markerRange']['start'],_0x49a049=_0x1d19f9['model']['schema'];let _0x5124bd=null,_0x23744e=null,_0x1b8afe=!0x1,_0x4883f9=!0x1;for(const _0x4b1819 of _0x23e6c6){const _0x128a01=_0x4b1819['item'];_0x1b8afe=_0x1b8afe||_0x49a049['isContent'](_0x128a01);const _0x9383fa=_0xecc2a3['mapper']['toViewElement'](_0x128a01);if(_0x9383fa&&_0x9383fa['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x4b1819['type']&&(_0x49a049['isBlock'](_0x128a01)&&!_0x49a049['isLimit'](_0x128a01)&&(_0x128a01['nextSibling']||_0x1e3561['isAtEnd']?_0x5124bd&&_0x5124bd['parent']==_0x128a01||(_0x5124bd=_0x128a01,_0x2e3e7c(_0x4b1819['previousPosition']),_0x4883f9=!0x0):_0x23744e=_0x23744e||_0x4b1819['previousPosition']));}function _0x2e3e7c(_0x1482b2){const _0x258623=_0xecc2a3['mapper']['toViewPosition'](_0x1482b2),_0x11e348=_0xecc2a3['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x345707});_0xecc2a3['writer']['insert'](_0x258623,_0x11e348),_0xecc2a3['mapper']['bindElementToMarker'](_0x11e348,_0x1baeca['markerName']);}_0x1b8afe||_0x4883f9||!_0x23744e||_0x2e3e7c(_0x23744e);};}class nt extends _0x4ea861{constructor(_0x5a9832){super(_0x5a9832);const _0x445067=_0x5a9832['plugins']['get'](l);this['affectsData']=!0x1,this['listenTo'](_0x445067,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x445067,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x90c3b6=this['editor'],_0x2d326e=_0x90c3b6['plugins']['get'](l),_0x50bdef=_0x2d326e['isReady']?_0x2d326e['diff']['newRevisionId']:null;_0x90c3b6['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x50bdef);}['refresh'](){const {isReady:_0x156190,isEnabled:_0x55deba,repository:_0x2a6f2c,diff:_0x245422}=this['editor']['plugins']['get'](l),_0x438075=_0x245422&&_0x2a6f2c['getLaterVisibleRevision'](_0x245422['newRevisionId']);this['isEnabled']=_0x156190&&_0x55deba&&Boolean(_0x438075);}}class ot extends _0x4ea861{['_step'];constructor(_0x20ebe2,{direction:_0x46abd9}){super(_0x20ebe2);const _0x4f0cc2=_0x20ebe2['plugins']['get'](l);this['affectsData']=!0x1,this['_step']='forward'===_0x46abd9?0x1:-0x1,this['listenTo'](_0x4f0cc2,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x4f0cc2,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x4f0cc2,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x1275a1=this['editor'],_0x275d91=_0x1275a1['plugins']['get'](l),{isNavigationMode:_0x55220d,currentChangeNumber:_0x287955}=_0x275d91;let _0x5a9f62;if(_0x275d91['activeChange']=_0x55220d?_0x275d91['diff']['changes']['get'](_0x287955+this['_step']):_0x275d91['diff']['changes']['first'],_0x275d91['activeChange']['data']['isOnRoot'])_0x5a9f62=_0x1275a1['editing']['view']['getDomRoot'](_0x275d91['activeChange']['rootName']);else{const _0x3b8bba=_0x1275a1['model']['markers']['get']('revision:'+_0x275d91['activeChange']['id']);_0x5a9f62=_0xfd418b(_0x1275a1['editing'],_0x3b8bba);}_0x417ff6({'target':_0x5a9f62,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x4d1c55,currentChangeNumber:_0x1ab928,numberOfChanges:_0x4de301,isReady:_0x4e1e31,isEnabled:_0x23dbba}=this['editor']['plugins']['get'](l);this['isEnabled']=!!(_0x23dbba&&_0x4e1e31&&_0x4de301)&&(!_0x4d1c55||(0x1===this['_step']?_0x1ab928<_0x4de301-0x1:_0x1ab928>0x0));}}class pi extends _0x3c5996{constructor(_0x4af7e4){super(_0x4af7e4);const _0x265146=this['bindTemplate'],_0xd41199=new _0x154c46(_0x4af7e4),_0x318fdc=new _0x154c46(_0x4af7e4);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',(_0x441407,_0x42fa7e)=>_0x441407&&_0x42fa7e>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x400a4b,_0x1b5d41,_0x9c0ff8,_0x13a9fd)=>{if(!_0x400a4b)return R(_0x4af7e4,'Loading...');if(!_0x9c0ff8)return R(_0x4af7e4,'No\x20changes');const _0x47f361=R(_0x4af7e4,'NUMBER_OF_CHANGES',_0x9c0ff8);return _0x13a9fd?R(_0x4af7e4,'X_OF_Y_CHANGES',[_0x1b5d41+0x1,_0x9c0ff8]):_0x47f361;}),_0xd41199['set']({'label':R(_0x4af7e4,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x395376}),_0x318fdc['set']({'label':R(_0x4af7e4,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x3d0654}),_0xd41199['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x318fdc['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0xd41199['on']('execute',()=>this['fire']('execute','backward')),_0x318fdc['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',_0x265146['if']('_isStatusLabelVisible','ck-hidden',_0x1a2dc1=>!_0x1a2dc1)]},'children':[{'text':_0x265146['to']('isNavigationMode',_0x4ba6d4=>_0x4ba6d4?R(_0x4af7e4,'EDIT_X_OF_Y_REVISIONS')+':\x20':R(_0x4af7e4,'Total')+':\x20')}]},{'text':_0x265146['to']('_statusText')}]},new _0x2991f7(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0xd41199,_0x318fdc]}]});}}const ge='ck-editor__editable__loading-overlay';class fi extends _0x16aaad{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x1db611=this['editor']['editing']['view'];_0x1db611['change'](_0x19e0f1=>{for(const _0x303961 of _0x1db611['document']['roots'])_0x19e0f1['addClass'](ge,_0x303961);});}['hide'](){const _0x3c4b53=this['editor']['editing']['view'];_0x3c4b53['change'](_0x19193d=>{for(const _0x1de61b of _0x3c4b53['document']['roots'])_0x19193d['removeClass'](ge,_0x1de61b);});}}class u extends _0x16aaad{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l,fi];}['init'](){const _0x27106e=this['editor'],_0x35b7f3=_0x27106e['plugins']['get'](l),_0x376d93=_0x27106e['plugins']['get'](fi);_0x27106e['ui']['componentFactory']['add']('exitToEditing',_0x16639d=>{const _0x1468d5=new _0x154c46(_0x16639d);return _0x1468d5['set']({'label':R(_0x16639d,'Back\x20to\x20editing'),'icon':_0x288cc6,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x1468d5,'execute',()=>{_0x27106e['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x1468d5;}),_0x27106e['ui']['componentFactory']['add']('restoreRevision',_0x5bf1c2=>{const _0x2f67f2=new _0x154c46(_0x5bf1c2);return _0x2f67f2['set']({'label':R(_0x5bf1c2,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x2f67f2['bind']('isEnabled')['to'](_0x27106e['commands']['get']('restoreRevision')),this['listenTo'](_0x2f67f2,'execute',()=>_0x27106e['execute']('restoreRevision')),_0x2f67f2;}),_0x27106e['ui']['componentFactory']['add']('changesNavigation',_0x4eac6f=>{const _0x3af996=new pi(_0x4eac6f),_0x585b38=_0x27106e['commands']['get']('showPreviousChange'),_0x1de097=_0x27106e['commands']['get']('showNextChange');return _0x3af996['bind']('isBackwardNavigationEnabled')['to'](_0x585b38,'isEnabled'),_0x3af996['bind']('isForwardNavigationEnabled')['to'](_0x1de097,'isEnabled'),_0x3af996['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x35b7f3),this['listenTo'](_0x3af996,'execute',(_0x35e84a,_0x5cbe3d)=>{_0x27106e['execute']('forward'===_0x5cbe3d?'showNextChange':'showPreviousChange');}),_0x3af996;}),_0x376d93['show'](),_0x35b7f3['on']('change:isReady',(_0x5797a8,_0x8c3d65,_0x1a8117)=>{_0x1a8117?_0x376d93['hide']():_0x376d93['show']();});}}class li extends ti{['_resizeObserver']=null;constructor(_0x39cd67,_0x52df38){super(_0x39cd67,_0x52df38);const _0x4d44b1=this['bindTemplate'];this['set']({'label':R(_0x39cd67,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=R(_0x39cd67,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x4d44b1['to']('_tooltipString'),'data-cke-tooltip-position':'s','data-cke-tooltip-class':'ck-tooltip_multi-line'}});}['render'](){super['render'](),this['_resizeObserver']=new et(this['fieldView']['element'],()=>this['_updateTooltipText']()),this['listenTo'](this['fieldView'],'input',()=>this['_updateTooltipText']());}['destroy'](){super['destroy'](),this['_resizeObserver']&&this['_resizeObserver']['destroy']();}['_updateTooltipText'](){const _0x59dfaa=this['fieldView']['element'];this['_tooltipString']=_0x59dfaa['scrollWidth']>_0x59dfaa['clientWidth']&&_0x59dfaa['value']||'';}}class vi extends _0x3c5996{constructor(_0xa1dd34,_0x235a6a,_0x1d2f74){super(_0xa1dd34);const _0x12a7f7=new _0x30ff3e();_0x12a7f7['set']({'content':_0xfa9c96,'viewBox':'0\x200\x2011\x2010'});const _0x255321=['ck','ck-revision-history-sidebar__revision-author'];_0x1d2f74&&_0x255321['push']('ck-revision-history-sidebar__revision-author_creator');const _0x11dd2a=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':R(_0xa1dd34,_0x1d2f74?'Revision\x20creator':'Revision\x20author')},'children':[_0x12a7f7,_0x235a6a['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x255321},'children':_0x11dd2a});}}function mi(_0x34017e,_0x503f5b){const _0x55aeff=_0x34017e['bindTemplate'],_0x15a059=_0x34017e['locale'],_0x1af141=_0x36bb40(_0x15a059);_0x1af141['panelPosition']='sw';const _0x3c2e95=function(_0x5f3608,_0x20e542){const _0x5210c6=function(_0x2a7c4a,_0x3c6dd8){const _0x44aace=_0x2a7c4a['locale'],_0x40db0d={'Compare\x20against\x20selected':R(_0x44aace,'Compare\x20against\x20selected'),'Name\x20this\x20revision':R(_0x44aace,'Name\x20this\x20revision'),'Restore\x20this\x20revision':R(_0x44aace,'Restore\x20this\x20revision')};return _0x3c6dd8['map'](_0x1bff76=>{const _0x26a9da=_0x40db0d[_0x1bff76['name']];return _0x26a9da&&_0x26a9da!==_0x1bff76['name']&&(_0x1bff76['name']=_0x26a9da),_0x1bff76;});}(_0x5f3608,_0x20e542),_0x19dab7=new _0x3e4e8e();for(const _0x36a84b of _0x5210c6){const _0x2c6592={'type':'button','model':new to({'label':_0x36a84b['name'],'class':_0x36a84b['class'],'withText':!0x0,'role':'menuitem','_action':_0x36a84b['action']})};_0x2c6592['model']['bind']('isEnabled')['to'](_0x5f3608,'isActionsDropdownOpen',_0x127637=>'function'!=typeof _0x36a84b['isEnabled']||(!_0x127637||_0x36a84b['isEnabled'](_0x5f3608))),_0x19dab7['add'](_0x2c6592);}return _0x19dab7;}(_0x34017e,_0x503f5b);return _0x34017e['bind']('isActionsDropdownOpen')['to'](_0x1af141,'isOpen'),_0x1af141['buttonView']['set']({'label':R(_0x15a059,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x132bb8}),_0x1af141['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x55aeff['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x55aeff['to'](_0x433b8a=>_0x433b8a['stopPropagation']())}}),_0x1af141['on']('execute',_0x4333eb=>{_0x34017e['isReady']&&'function'==typeof _0x4333eb['source']['_action']&&_0x4333eb['source']['_action'](_0x34017e);}),_0x1c4148(_0x1af141,_0x3c2e95,{'role':'menu'}),_0x1af141['listenTo'](_0x34017e,'change:isActionsDropdownOpen',(_0x5e55dd,_0x2c1d2e,_0x560d5a)=>{if(_0x560d5a)for(const _0x15690e of _0x1af141['listView']['items']){const _0x19d695=_0x15690e['children']['first'],_0x417613=_0x503f5b['find'](_0x2e8598=>_0x2e8598['action']===_0x19d695['_action'])['isVisible'];_0x15690e['isVisible']=void 0x0===_0x417613||_0x417613(_0x34017e);}}),_0x1af141;}class ki extends/* #__PURE__ -- @preserve */
27
- _0x3f3284(_0x3c5996){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x1e4c81,_0x3344ea,_0x963fd1,_0x14672b){super(_0x1e4c81);const _0x21d773=this['bindTemplate'],_0x24536b=function(_0x1b8563,_0x5ef3d1){const _0x1c1511=Array['from'](_0x5ef3d1['authors'])['filter'](_0xe278a5=>_0xe278a5!=_0x5ef3d1['creator']);return _0x5ef3d1['creator']&&_0x1c1511['unshift'](_0x5ef3d1['creator']),_0x1c1511['map'](_0x2ac317=>new vi(_0x1b8563,_0x2ac317,_0x2ac317==_0x5ef3d1['creator']));}(_0x1e4c81,_0x3344ea);this['id']=_0x3344ea['id'],this['_revision']=_0x3344ea,this['_requireRevisionName']=_0x14672b,this['bind']('name','createdAt')['to'](_0x3344ea),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x531994=>{return _0x44d71c=_0x1e4c81['uiLanguage'],(_0x14863c=_0x531994)['toLocaleDateString'](_0x44d71c,{'month':'long','day':'numeric'})+',\x20'+_0x14863c['toLocaleTimeString'](_0x44d71c,{'hour':'numeric','minute':'numeric'});var _0x44d71c,_0x14863c;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new li(_0x1e4c81,_0x2f6324),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x41f5d7=>_0x41f5d7||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x1530a0,_0x20b9d5)=>_0x1530a0&&_0x20b9d5),this['revisionActionsView']=_0x963fd1&&_0x963fd1['length']?mi(this,_0x963fd1):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x21d773['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x21d773['if']('isEnabled','ck-disabled',_0x40f10c=>!_0x40f10c),_0x21d773['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x21d773['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x21d773['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':_0x21d773['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':_0x24536b}]},this['revisionActionsView']],'on':{'click':_0x21d773['to'](_0x202daf=>{_0x202daf['srcElement']['closest']('.ck-thread__remove-confirm')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x5d24ad=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x5d24ad,'change',()=>{this['_requireRevisionName']&&!_0x5d24ad['value']||this['fire']('setName',{'id':this['id'],'name':_0x5d24ad['value']}),_0x5d24ad['value']||(_0x5d24ad['value']=this['name']?this['name']:this['_createdAtFormatted']);});}['select'](){this['isSelected']=!0x0;}['deselect'](){this['isSelected']=!0x1;}['highlight'](){this['isHighlighted']=!0x0;}['unhighlight'](){this['isHighlighted']=!0x1;}}function ji(_0x4ee8c2,_0x244230){const _0x479902=_0x347e72['fromJSDate'](_0x4ee8c2)['setLocale'](_0x244230),_0x54a3f7=_0x347e72['local'](),_0x185085=_0x54a3f7['minus']({'days':0x1})['startOf']('day');let _0x386ea2,_0x15871e;return _0x479902['hasSame'](_0x54a3f7,'day')?(_0x386ea2=_0x479902['startOf']('day')['toJSDate'](),_0x15871e=_0x479902['toRelativeCalendar']()):_0x479902['hasSame'](_0x185085,'day')?(_0x386ea2=_0x185085['toJSDate'](),_0x15871e=_0x479902['toRelativeCalendar']()):_0x479902['hasSame'](_0x54a3f7,'week')?(_0x386ea2=_0x479902['startOf']('week')['toJSDate'](),_0x15871e=_0x479902['weekdayLong']||''):_0x479902['hasSame'](_0x54a3f7,'year')?(_0x386ea2=_0x479902['startOf']('month')['toJSDate'](),_0x15871e=_0x479902['monthLong']||''):(_0x386ea2=_0x479902['startOf']('year')['toJSDate'](),_0x15871e=String(_0x479902['year'])),{'startDate':_0x386ea2,'localizedPeriodName':_0x15871e};}class Ni extends _0x3c5996{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0xc19843,_0x34cd6a,_0x560fd3,_0x566f11){super(_0xc19843);const _0x3d3a19=ji(_0x34cd6a,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x34cd6a,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x560fd3,this['_requireRevisionName']=_0x566f11,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':_0x3d3a19}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x5a9d7b){const _0x17bf5e=new ki(this['locale'],_0x5a9d7b,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x17bf5e);}['removeRevision'](_0x1c3a04){const _0x16d44f=this['revisionViews']['find'](_0x615016=>_0x615016['id']===_0x1c3a04['id']);this['revisionViews']['remove'](_0x16d44f);}}class Si extends _0x3c5996{constructor(_0x17d000){super(_0x17d000);const _0x24fff1=new _0x30ff3e();_0x24fff1['content']=_0x3d0553,this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x24fff1,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[R(_0x17d000,'Revision\x20history')]}]});}}class Ri extends _0x3c5996{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x33c27b,_0x53198d,_0x33481a,_0x15e77d){super(_0x33c27b);const _0x20d300=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x53198d,this['_revisionActions']=_0x33481a,this['_requireRevisionName']=_0x15e77d,this['on']('select',(_0x2734d0,_0x10248e)=>{this['fire']('revisionSelected',_0x10248e);}),this['on']('setName',(_0x54d8e6,_0x581a70)=>{this['fire']('revisionSetName',_0x581a70);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new Si(_0x33c27b),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x20d300['if']('isEnabled','ck-disabled',_0x19dc0e=>!_0x19dc0e)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x172289 of this['_revisions'])this['_addRevision'](_0x172289);this['_revisions']['on']('add',(_0x4b73d9,_0x35c775)=>{this['_addRevision'](_0x35c775);}),this['_revisions']['on']('remove',(_0x55df72,_0x10fc85)=>{this['_removeRevision'](_0x10fc85);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x173116=>_0x173116['revisionViews']['map'](_0x5e2577=>_0x5e2577))['flat']();}['selectRevision'](_0x444565){for(const _0x3bab5e of this['revisionViews'])_0x444565&&_0x444565['id']===_0x3bab5e['id']?_0x3bab5e['select']():_0x3bab5e['deselect']();}['highlightRevisions'](_0x3160cc){for(const _0xd2c91a of this['revisionViews'])_0x3160cc['some'](({id:_0x390962})=>_0x390962===_0xd2c91a['id'])?_0xd2c91a['highlight']():_0xd2c91a['unhighlight']();}['_addRevision'](_0x3e350b){const _0x64f324=ji(_0x3e350b['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x2cb094=this['timePeriodViews']['get'](0x0);_0x2cb094&&_0x2cb094['startDate']['getTime']()===_0x64f324['getTime']()||(_0x2cb094=new Ni(this['locale'],_0x64f324,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x2cb094)),_0x2cb094['addRevision'](_0x3e350b);}['_removeRevision'](_0x4413e4){const _0x1ef06c=ji(_0x4413e4['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x1ef06c)['removeRevision'](_0x4413e4);}['_getTimePeriodViewByStartDate'](_0x37470f){return this['timePeriodViews']['find'](_0x119e32=>_0x119e32['startDate']['getTime']()===_0x37470f['getTime']());}}class f extends _0x16aaad{['_revisionViewer'];['_revisionsRepository'];['_sidebarView'];static ['defaultRevisionActions']=/* #__PURE__ -- @preserve */
23
+ import{ObservableMixin as _0x220e5e,uid as _0x58edc7,Collection as _0xbf5b7e,logWarning as _0x3c4dda,FocusTracker as _0x51224f,KeystrokeHandler as _0x5ba12a,scrollViewportToShowTarget as _0x278709,ResizeObserver as ot,ElementReplacer as it,CKEditorError as _0x27bd41}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x570b2f,set as _0x3d4dc9,unset as _0x30c73b,isEqual as _0x158881}from'es-toolkit/compat';import{Plugin as _0x40d69e,PendingActions as _0x371990,Command as _0x17f1c5,ElementApiMixin as _0x396607,Editor as _0x39e5da}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x31b528,getMarkerDomElement as _0x5ea7c3,ConfirmMixin as _0x310213,sanitizeEditorConfig as _0xe8ae6a}from'ckeditor5-collaboration/dist/index.js';import{ViewContainerElement as _0x2ccec7,ViewAttributeElement as _0x3707a2,ViewEmptyElement as _0x78a4a0,ViewRawElement as _0x4740c3,ViewUIElement as _0x74385,ViewDocumentFragment as _0x103c9a,ViewText as _0x1ccf06,ViewElement as _0x530198,ModelElement as _0x149c78,ModelRange as _0x16968a,ModelPosition as _0x424c40,ModelDocumentFragment as _0x1017e4,ModelText as _0xfc39de}from'@ckeditor/ckeditor5-engine/dist/index.js';import{IconHistory as _0x5a259c,IconChevronUp as _0x561579,IconChevronDown as _0x41c34d,IconUndo as _0x2ee9fb,IconUser as _0x4023b9,IconThreeVerticalDots as _0x2717e7}from'@ckeditor/ckeditor5-icons/dist/index.js';import{CssTransitionDisablerMixin as _0x4930e8,View as _0x5372f9,submitHandler as _0x9dd0f8,LabeledFieldView as et,createLabeledInputText as ti,createDropdown as _0x5bfde6,ListView as _0x41ec92,ListItemView as _0x22c231,ButtonView as _0x4c294d,MenuBarMenuView as _0x518481,MenuBarMenuListView as _0x1ec7f2,MenuBarMenuListItemView as _0x3e0b15,MenuBarMenuListItemButtonView as _0x398d58,ContextualBalloon as _0x59aed6,ToolbarSeparatorView as _0x268ae1,IconView as _0x2e6b9e,addListToDropdown as _0x57d04a,UIModel as to,EditorUI as tt,normalizeToolbarConfig as st,BoxedEditorUIView as _0x3400fc,StickyPanelView as _0x11665a,ToolbarView as _0x375565,InlineEditableUIView as te}from'@ckeditor/ckeditor5-ui/dist/index.js';import{DateTime as _0x29909a}from'luxon';class I extends/* #__PURE__ -- @preserve */
24
+ _0x220e5e(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x3dc839){super(),this['id']=_0x3dc839['id']||_0x58edc7(),this['creator']=_0x3dc839['creator']||null,this['authors']=_0x3dc839['authors']||[],this['diffData']=_0x3dc839['diffData']||null,this['toVersion']=_0x3dc839['toVersion']||0x0,this['fromVersion']=_0x3dc839['fromVersion']||0x0,this['set']('name',_0x3dc839['name']||''),this['set']('createdAt',_0x3dc839['createdAt']||new Date()),this['set']('attributes',_0x3dc839['attributes']||{});}['setName'](_0x1b073a){this['_update']({'name':_0x1b073a});}['setAttribute'](_0x2186b9,_0x4a512e){const _0x497fb0=_0x570b2f(this['attributes']);_0x3d4dc9(_0x497fb0,_0x2186b9,_0x4a512e),this['_update']({'attributes':_0x497fb0});}['removeAttribute'](_0x5e80f2){const _0x2770c9=_0x570b2f(this['attributes']);_0x30c73b(_0x2770c9,_0x5e80f2),this['_update']({'attributes':_0x2770c9});}['_update'](_0xd281ba,_0x14187f=!0x1){let _0x1fa2e8=!0x1;const _0x3608da={'id':this['id']},_0x314f88=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x849b24 of _0x314f88){const _0x5bb891=_0xd281ba[_0x849b24];void 0x0!==_0x5bb891&&_0x5bb891!==this[_0x849b24]&&(this[_0x849b24]=_0x5bb891,_0x3608da[_0x849b24]=_0x5bb891,_0x1fa2e8=!0x0);}_0x1fa2e8&&(_0x3608da['authors']&&(_0x3608da['authorsIds']=_0x3608da['authors']['map'](_0x250f39=>_0x250f39['id']),delete _0x3608da['authors']),this['fire']('_update',_0x3608da,_0x14187f));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x165fd8=>_0x165fd8['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class S extends _0x40d69e{['_revisions'];static get['requires'](){return[_0x31b528];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x17961d){super(_0x17961d),this['_revisions']=new _0xbf5b7e();}['afterInit'](){!async function(_0x1c5bf9){const _0x55426d=_0x9a0efa([0x74,0x63,0x49,0x6a,0x4f,0x78,0x34,0x58,0x4b,0x54,0x62,0x41,0x5a,0x4e,0x59,0x65,0x51,0x66,0x32,0x69,0x4a,0x39,0x53,0x33,0x35,0x57,0x47,0x4c,0x6c,0x7a,0x43,0x64,0x72,0x31,0x30,0x67,0x75,0x37,0x36,0x79,0x6d,0x68,0x52,0x45,0x4d,0x56,0x70,0x38,0x46,0x76,0x77,0x55,0x6f,0x42,0x61,0x50,0x6e,0x71,0x44,0x48,0x73,0x6b]),_0x245ace=0xeb829,_0x24df09=0x72b9e60,_0x226e0e=0x72ceeb0^_0x24df09,_0xed50f9=window[_0x9a0efa([0x44,0x61,0x74,0x65])][_0x9a0efa([0x6e,0x6f,0x77])](),_0x5af653=_0x1c5bf9[_0x9a0efa([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x2e38d8=new window[(_0x9a0efa([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2ca5bb=>{_0x5af653[_0x9a0efa([0x6f,0x6e,0x63,0x65])](_0x9a0efa([0x72,0x65,0x61,0x64,0x79]),_0x2ca5bb);}),_0x5ea9ba={[_0x9a0efa([0x6b,0x74,0x79])]:_0x9a0efa([0x45,0x43]),[_0x9a0efa([0x75,0x73,0x65])]:_0x9a0efa([0x73,0x69,0x67]),[_0x9a0efa([0x63,0x72,0x76])]:_0x9a0efa([0x50,0x2d,0x32,0x35,0x36]),[_0x9a0efa([0x78])]:_0x9a0efa([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]),[_0x9a0efa([0x79])]:_0x9a0efa([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]),[_0x9a0efa([0x61,0x6c,0x67])]:_0x9a0efa([0x45,0x53,0x32,0x35,0x36])},_0x3ded8b=_0x5af653[_0x9a0efa([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x9a0efa([0x67,0x65,0x74])](_0x9a0efa([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x6ae52e(){let _0x650506,_0x111d6b=null,_0x2b59bc=null;try{if(_0x3ded8b==_0x9a0efa([0x47,0x50,0x4c]))return _0x9a0efa([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x650506=_0xa3662c(),!_0x650506)return _0x9a0efa([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x650506[_0x9a0efa([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x2b59bc=_0x1bdc47(_0x650506[_0x9a0efa([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x650506[_0x9a0efa([0x6a,0x74,0x69])])),await _0x54ba66()?_0x2017aa()?_0xd94edc()?_0x9a0efa([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x399e99()?(_0x650506[_0x9a0efa([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x9a0efa([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x111d6b=_0x491a6a(_0x9a0efa([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x650506[_0x9a0efa([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x9a0efa([0x74,0x72,0x69,0x61,0x6c])&&(_0x111d6b=_0x491a6a(_0x9a0efa([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0xab3a71()):_0x9a0efa([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x9a0efa([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x9a0efa([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x9a0efa([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0xd94edc(){const _0x489595=[_0x9a0efa([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x9a0efa([0x74,0x72,0x69,0x61,0x6c])][_0x9a0efa([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x650506[_0x9a0efa([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0xed50f9/0x3e8:0xe10*_0x226e0e;return _0x650506[_0x9a0efa([0x65,0x78,0x70])]<_0x489595;}function _0x2017aa(){const _0x26c250=_0x650506[_0x9a0efa([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x26c250)return!0x1;if(_0x26c250[_0x9a0efa([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x9a0efa([0x2a])))return!0x0;if(_0x26c250[_0x9a0efa([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x9a0efa([0x52,0x48])))return!0x0;if(_0x26c250[_0x9a0efa([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x9a0efa([0x52,0x52,0x48]))){if(_0x46e2a())return!0x0;if(_0x45cdff()||_0x256f41())return!0x0;}return!0x1;}function _0x399e99(){const _0x1bbab3=_0x650506[_0x9a0efa([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x1bbab3||0x0==_0x1bbab3[_0x9a0efa([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x3f0b91}=new URL(window[_0x9a0efa([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x1bbab3[_0x9a0efa([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x3f0b91))return!0x0;const _0x5ded8e=_0x3f0b91[_0x9a0efa([0x73,0x70,0x6c,0x69,0x74])](_0x9a0efa([0x2e]));return _0x1bbab3[_0x9a0efa([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x27bc92=>_0x27bc92[_0x9a0efa([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x9a0efa([0x2a])))[_0x9a0efa([0x6d,0x61,0x70])](_0x2c765b=>_0x2c765b[_0x9a0efa([0x73,0x70,0x6c,0x69,0x74])](_0x9a0efa([0x2e])))[_0x9a0efa([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x1c335d=>_0x1c335d[_0x9a0efa([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x5ded8e[_0x9a0efa([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x9a0efa([0x6d,0x61,0x70])](_0x22a8d3=>Array(_0x5ded8e[_0x9a0efa([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0x22a8d3[_0x9a0efa([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x9a0efa([0x66,0x69,0x6c,0x6c])](_0x22a8d3[0x0]===_0x9a0efa([0x2a])?_0x9a0efa([0x2a]):'')[_0x9a0efa([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0x22a8d3))[_0x9a0efa([0x73,0x6f,0x6d,0x65])](_0x1c7ae0=>_0x5ded8e[_0x9a0efa([0x65,0x76,0x65,0x72,0x79])]((_0x3bc30,_0x5a64d5)=>_0x1c7ae0[_0x5a64d5]===_0x3bc30||_0x1c7ae0[_0x5a64d5]===_0x9a0efa([0x2a])));}function _0xab3a71(){return _0x111d6b&&_0x2b59bc?new window[(_0x9a0efa([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x127be2,_0x3e3e85)=>{_0x111d6b[_0x9a0efa([0x74,0x68,0x65,0x6e])](_0x127be2,_0x3e3e85),_0x2b59bc[_0x9a0efa([0x74,0x68,0x65,0x6e])](_0x52e5eb=>{_0x52e5eb!=_0x9a0efa([0x56,0x61,0x6c,0x69,0x64])&&_0x127be2(_0x52e5eb);},_0x3e3e85);}):_0x111d6b||_0x2b59bc||_0x9a0efa([0x56,0x61,0x6c,0x69,0x64]);}}function _0x1bdc47(_0xef7e71,_0x227b6a){return new window[(_0x9a0efa([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x45b9b2=>{if(_0x1d5f40())return _0x45b9b2(_0x9a0efa([0x56,0x61,0x6c,0x69,0x64]));_0xc4ee1a(),_0x5af653[_0x9a0efa([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x9a0efa([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x4dfec2=!0x1;const _0x56ece3=_0x58edc7();function _0x1e97a8(_0x3af331){return!!_0x3af331&&(typeof _0x3af331===_0x9a0efa([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x3af331===_0x9a0efa([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x3af331[_0x9a0efa([0x74,0x68,0x65,0x6e])]===_0x9a0efa([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x3af331[_0x9a0efa([0x63,0x61,0x74,0x63,0x68])]===_0x9a0efa([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x524d95(_0x26bcc4){_0x517664(_0x26bcc4)[_0x9a0efa([0x74,0x68,0x65,0x6e])](_0x29f80c=>{if(!_0x29f80c||_0x29f80c[_0x9a0efa([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x9a0efa([0x6f,0x6b]))return _0x9a0efa([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x1bb309(_0x3c9170(_0x56ece3+_0x227b6a))!=_0x29f80c[_0x9a0efa([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x9a0efa([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x9a0efa([0x56,0x61,0x6c,0x69,0x64]);})[_0x9a0efa([0x74,0x68,0x65,0x6e])](_0x486119=>(_0x469d17(),_0x486119),()=>{const _0x2fbd41=_0x69bafc();return null==_0x2fbd41?(_0x469d17(),_0x9a0efa([0x56,0x61,0x6c,0x69,0x64])):_0x9a0efa(_0xed50f9-_0x2fbd41>(0x23271a60^_0x24df09)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x9a0efa([0x74,0x68,0x65,0x6e])](_0x45b9b2)[_0x9a0efa([0x63,0x61,0x74,0x63,0x68])](()=>{_0x45b9b2(_0x9a0efa([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x379e56=0x71d70e0^_0x24df09;function _0x469d17(){const _0x6c777f=_0x9a0efa([0x6c,0x6c,0x63,0x74,0x2d])+_0x1bb309(_0x3c9170(_0xef7e71)),_0x45148e=_0x53f9ef(_0x1bb309(window[_0x9a0efa([0x4d,0x61,0x74,0x68])][_0x9a0efa([0x63,0x65,0x69,0x6c])](_0xed50f9/_0x379e56)));window[_0x9a0efa([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x9a0efa([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x6c777f,_0x45148e);}function _0x69bafc(){const _0xe7e7d3=_0x9a0efa([0x6c,0x6c,0x63,0x74,0x2d])+_0x1bb309(_0x3c9170(_0xef7e71)),_0x537e60=window[_0x9a0efa([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x9a0efa([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0xe7e7d3);return _0x537e60?window[_0x9a0efa([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x53f9ef(_0x537e60),0x10)*_0x379e56:null;}function _0x517664(_0x11180f){return new window[(_0x9a0efa([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x5be784,_0x140c60)=>{_0x11180f[_0x9a0efa([0x74,0x68,0x65,0x6e])](_0x5be784,_0x140c60),window[_0x9a0efa([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x140c60,0x72a4aa0^_0x24df09);});}}_0x5af653[_0x9a0efa([0x6f,0x6e])](_0x9a0efa([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x3accfc,_0x3caa27)=>{if(_0x3caa27[0x0]!=_0xef7e71)return _0x45b9b2(_0x9a0efa([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x3caa27[0x1]={..._0x3caa27[0x1],[_0x9a0efa([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x56ece3};},{[_0x9a0efa([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x9a0efa([0x68,0x69,0x67,0x68])}),_0x5af653[_0x9a0efa([0x6f,0x6e])](_0x9a0efa([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x50822d=>{_0x1e97a8(_0x50822d[_0x9a0efa([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x4dfec2=!0x0,_0x524d95(_0x50822d[_0x9a0efa([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x9a0efa([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x9a0efa([0x6c,0x6f,0x77])}),_0x2e38d8[_0x9a0efa([0x74,0x68,0x65,0x6e])](()=>{_0x4dfec2||_0x45b9b2(_0x9a0efa([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x1d5f40(){return _0x5af653[_0x9a0efa([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x9a0efa([0x76,0x69,0x65,0x77])][_0x9a0efa([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x9a0efa([0x61,0x75,0x74,0x6f]);}function _0xc4ee1a(){_0x5af653[_0x9a0efa([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x9a0efa([0x76,0x69,0x65,0x77])][_0x9a0efa([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x9a0efa([0x61,0x75,0x74,0x6f]);}}function _0x491a6a(_0x216409){const _0x3bbdee=[new window[(_0x9a0efa([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x5c1a06=>setTimeout(_0x5c1a06,0x722a0ac^_0x24df09)),_0x2e38d8[_0x9a0efa([0x74,0x68,0x65,0x6e])](()=>new window[(_0x9a0efa([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x3b7156=>{const _0x252b94=0x72b9e67^_0x24df09,_0x4222e6=_0x1c5bf9[_0x9a0efa([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x175278(){_0x4222e6[_0x9a0efa([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x252b94&&_0x3b7156();}_0x175278(),_0x4222e6[_0x9a0efa([0x6f,0x6e])](_0x9a0efa([0x61,0x64,0x64]),_0x175278);})),new window[(_0x9a0efa([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x20bafa=>{function _0x4bdf9e(){for(const _0xc704b0 in window)if(window[_0x9a0efa([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x9a0efa([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0xc704b0))&&window[_0xc704b0]==_0x245ace)return _0x20bafa();_0x5af653[_0x9a0efa([0x73,0x74,0x61,0x74,0x65])]!=_0x9a0efa([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x9a0efa([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x4bdf9e,0x72b8de8^_0x24df09);}_0x80defc(_0x9a0efa([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x4bdf9e();})];return window[_0x9a0efa([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x9a0efa([0x72,0x61,0x63,0x65])](_0x3bbdee)[_0x9a0efa([0x74,0x68,0x65,0x6e])](()=>_0x216409);}async function _0x1bc8a5(){if(await _0x2e38d8,_0x80defc(_0x9a0efa([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x5acb1b=_0x1c5bf9[_0x9a0efa([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x4fd297=_0x1c5bf9[_0x9a0efa([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])](_0x5acb1b[_0x9a0efa([0x69,0x64])]),_0x2f1f0d=_0x4db482(_0x9a0efa([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x2f1f0d[_0x9a0efa([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x5acb1b['id'],_0x4fd297?_0x4fd297['id']:null,!0x0),_0x2f1f0d[_0x9a0efa([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x9a0efa([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x2f1f0d[_0x9a0efa([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x2f1f0d[_0x9a0efa([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x49f779,void(_0x2f1f0d[_0x9a0efa([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x49f779);}if(_0x80defc(_0x9a0efa([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x1326d7=_0x4db482(_0x9a0efa([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x1326d7[_0x9a0efa([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x9a0efa([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x1326d7[_0x9a0efa([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x1326d7[_0x9a0efa([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x49f779,_0x1326d7[_0x9a0efa([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x49f779;}_0x5af653[_0x9a0efa([0x6d,0x6f,0x64,0x65,0x6c])][_0x9a0efa([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x49f779,_0x5af653[_0x9a0efa([0x6d,0x6f,0x64,0x65,0x6c])][_0x9a0efa([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x49f779,_0x5af653[_0x9a0efa([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x9a0efa([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x46e2a(){return _0x80defc(_0x9a0efa([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x4db482(_0x9a0efa([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x9a0efa([0x73,0x74,0x61,0x74,0x65])]==_0x9a0efa([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x45cdff(){return _0x80defc(_0x9a0efa([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 _0x256f41(){return _0x80defc(_0x9a0efa([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x386bb3(_0x5b39e1){const _0x325326=_0x218be1();_0x5af653[_0x325326]=_0x9a0efa([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])+_0x5b39e1,_0x5b39e1[_0x9a0efa([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x9a0efa([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x218be1()]=_0x245ace),_0x5b39e1!=_0x9a0efa([0x56,0x61,0x6c,0x69,0x64])&&_0x1bc8a5();}function _0x218be1(){const _0x1ca05d=window[_0x9a0efa([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x9a0efa([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x9a0efa([0x6e,0x6f,0x77])]())[_0x9a0efa([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x9a0efa([0x2e]),'');let _0x2a97a2=_0x9a0efa([0x74]);for(let _0x282d97=0x0;_0x282d97<_0x1ca05d[_0x9a0efa([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x282d97+=0x2){let _0x36f3a3=window[_0x9a0efa([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x1ca05d[_0x9a0efa([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x282d97,_0x282d97+0x2));_0x36f3a3>=_0x55426d[_0x9a0efa([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x36f3a3-=_0x55426d[_0x9a0efa([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x2a97a2+=_0x55426d[_0x36f3a3];}return _0x2a97a2;}function _0xa3662c(){const _0x17dd32=_0x3ded8b[_0x9a0efa([0x73,0x70,0x6c,0x69,0x74])](_0x9a0efa([0x2e]));if(0x3!=_0x17dd32[_0x9a0efa([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x468a81(_0x17dd32[0x1]);function _0x468a81(_0x5adf75){const _0x18b0fc=_0x170503(_0x5adf75);return _0x18b0fc&&_0x2658bd()?_0x18b0fc:null;function _0x2658bd(){const _0x139ed1=_0x18b0fc[_0x9a0efa([0x6a,0x74,0x69])],_0x24837e=window[_0x9a0efa([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x139ed1[_0x9a0efa([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x139ed1[_0x9a0efa([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x9c78f7={..._0x18b0fc,[_0x9a0efa([0x6a,0x74,0x69])]:_0x139ed1[_0x9a0efa([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x139ed1[_0x9a0efa([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x9c78f7[_0x9a0efa([0x76,0x63])],_0x3c9170(_0x9c78f7)==_0x24837e;}}}async function _0x54ba66(){let _0x140d4c=!0x0;try{const _0x4e1ae9=_0x3ded8b[_0x9a0efa([0x73,0x70,0x6c,0x69,0x74])](_0x9a0efa([0x2e])),[_0x3e2990,_0x22f3c6,_0x226e27]=_0x4e1ae9;return _0x14c277(_0x3e2990),await _0x351bbc(_0x3e2990,_0x22f3c6,_0x226e27),_0x140d4c;}catch{return!0x1;}function _0x14c277(_0x4537a0){const _0x41f906=_0x170503(_0x4537a0);_0x41f906&&_0x41f906[_0x9a0efa([0x61,0x6c,0x67])]==_0x9a0efa([0x45,0x53,0x32,0x35,0x36])||(_0x140d4c=!0x1);}async function _0x351bbc(_0x901bbd,_0x2b3307,_0x2b91ca){const _0xe763ae=window[_0x9a0efa([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x9a0efa([0x66,0x72,0x6f,0x6d])](_0x533f9d(_0x2b91ca),_0x115a42=>_0x115a42[_0x9a0efa([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x4beeef=new window[(_0x9a0efa([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x9a0efa([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x901bbd+_0x9a0efa([0x2e])+_0x2b3307),_0x1a85b2=window[_0x9a0efa([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x9a0efa([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x1a85b2)return;const _0x381cae=await _0x1a85b2[_0x9a0efa([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x9a0efa([0x6a,0x77,0x6b]),_0x5ea9ba,{[_0x9a0efa([0x6e,0x61,0x6d,0x65])]:_0x9a0efa([0x45,0x43,0x44,0x53,0x41]),[_0x9a0efa([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x9a0efa([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x9a0efa([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x1a85b2[_0x9a0efa([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x9a0efa([0x6e,0x61,0x6d,0x65])]:_0x9a0efa([0x45,0x43,0x44,0x53,0x41]),[_0x9a0efa([0x68,0x61,0x73,0x68])]:{[_0x9a0efa([0x6e,0x61,0x6d,0x65])]:_0x9a0efa([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x381cae,_0xe763ae,_0x4beeef)||(_0x140d4c=!0x1);}}function _0x170503(_0x31011c){return _0x31011c[_0x9a0efa([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x9a0efa([0x65,0x79]))?JSON[_0x9a0efa([0x70,0x61,0x72,0x73,0x65])](_0x533f9d(_0x31011c)):null;}function _0x533f9d(_0x5c1ac8){return window[_0x9a0efa([0x61,0x74,0x6f,0x62])](_0x5c1ac8[_0x9a0efa([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x9a0efa([0x2b]))[_0x9a0efa([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x9a0efa([0x2f])));}function _0x3c9170(_0x5578ed){let _0x469d76=0x1505;function _0xd5238(_0x34ce14){for(let _0x43dcf1=0x0;_0x43dcf1<_0x34ce14[_0x9a0efa([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x43dcf1++){const _0x29d5eb=_0x34ce14[_0x9a0efa([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x43dcf1);_0x469d76=(_0x469d76<<0x5)+_0x469d76+_0x29d5eb,_0x469d76&=_0x469d76;}}function _0x395174(_0x49bde2){Array[_0x9a0efa([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x49bde2)?_0x49bde2[_0x9a0efa([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x395174):_0x49bde2&&typeof _0x49bde2==_0x9a0efa([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x9a0efa([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x49bde2)[_0x9a0efa([0x73,0x6f,0x72,0x74])]()[_0x9a0efa([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x142d95,_0x16e526])=>{_0xd5238(_0x142d95),_0x395174(_0x16e526);}):_0xd5238(window[_0x9a0efa([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x49bde2));}return _0x395174(_0x5578ed),_0x469d76>>>0x0;}function _0x1bb309(_0x4b2ec7){return _0x4b2ec7[_0x9a0efa([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x9a0efa([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x9a0efa([0x30]));}function _0x53f9ef(_0xbced7b){return _0xbced7b[_0x9a0efa([0x73,0x70,0x6c,0x69,0x74])]('')[_0x9a0efa([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x9a0efa([0x6a,0x6f,0x69,0x6e])]('');}function _0x80defc(_0x14d71a){return _0x5af653[_0x9a0efa([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x9a0efa([0x68,0x61,0x73])](_0x14d71a);}function _0x4db482(_0x391e0b){return _0x5af653[_0x9a0efa([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x9a0efa([0x67,0x65,0x74])](_0x391e0b);}function _0x49f779(){}function _0x9a0efa(_0x341269){return _0x341269['map'](_0x4f6bc5=>String['fromCharCode'](_0x4f6bc5))['join']('');}_0x386bb3(await _0x6ae52e());}(this);}['createRevision'](_0x14fcce){const _0x374152=this['editor']['plugins']['get']('Users');return new I({'id':_0x14fcce['id'],'name':_0x14fcce['name'],'creator':_0x14fcce['creatorId']?_0x374152['getUser'](_0x14fcce['creatorId']):null,'diffData':_0x14fcce['diffData']||_0x14fcce['data'],'authors':_0x14fcce['authorsIds']['map'](_0x3e4f54=>_0x374152['getUser'](_0x3e4f54)),'createdAt':new Date(_0x14fcce['createdAt']),'attributes':_0x14fcce['attributes'],'fromVersion':_0x14fcce['fromVersion'],'toVersion':_0x14fcce['toVersion']});}['addRevision'](_0x5014ff,_0x197a6c=0x0){this['_revisions']['add'](_0x5014ff,_0x197a6c);}['getRevision'](_0x211bcd){return this['_revisions']['get'](_0x211bcd);}['getRevisions'](_0xfb5fa7={'toJSON':!0x1}){const _0x5871f8=Array['from'](this['_revisions']);return _0x5871f8['reverse'](),_0xfb5fa7['toJSON']?_0x5871f8['map'](_0xb948f7=>_0xb948f7['toJSON']()):_0x5871f8;}['getIndex'](_0x3078ad){return this['_revisions']['getIndex'](_0x3078ad);}['getEarlierVisibleRevision'](_0x4ae1fa){const [,_0x51a978]=this['getRevisionsIterator'](_0x4ae1fa,{'direction':'earlier'});return _0x51a978;}['getLaterVisibleRevision'](_0x43ebea){const [,_0x176bdb]=this['getRevisionsIterator'](_0x43ebea,{'direction':'later'});return _0x176bdb;}['getRevisionsInDiff'](_0x4929af){const _0x37f709=[];for(const _0x59a786 of this['getRevisionsIterator'](_0x4929af['newRevisionId']))if(_0x37f709['push'](_0x59a786),_0x59a786['id']===_0x4929af['oldRevisionId'])break;return _0x37f709;}*['getRevisionsIterator'](_0x33ac70,{direction:_0x3c353c='earlier',filter:_0x22258f=()=>!0x0}={}){const _0x546d6f='earlier'===_0x3c353c?0x1:-0x1;let _0x340e59=this['_revisions']['get'](_0x33ac70),_0x28339e=this['getIndex'](_0x340e59);for(yield _0x340e59;_0x340e59;){if(_0x28339e+=_0x546d6f,_0x340e59=this['getRevision'](_0x28339e),!_0x340e59)return;_0x22258f(_0x340e59)&&(yield _0x340e59);}}}class $ extends _0x40d69e{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x2ccec7,'c'],[_0x3707a2,'a'],[_0x78a4a0,'e'],[_0x4740c3,'r'],[_0x74385,'u']]);['_typeCharToViewClass']=new Map([['c',_0x2ccec7],['a',_0x3707a2],['e',_0x78a4a0],['r',_0x4740c3],['u',_0x74385]]);async['loadRevisionData'](_0x263699,_0x5e9e33){if(_0x263699['diffData']||!_0x5e9e33)return;const _0x53d8a9=this['editor']['config']['get']('collaboration.channelId'),_0x22af67=await _0x5e9e33['getRevision']({'channelId':_0x53d8a9,'revisionId':_0x263699['id']});_0x263699['diffData']=_0x22af67['diffData'];}['getRevisionDocumentData'](_0x5a8d1e){const _0x5571b7={};for(const _0x4e6150 in _0x5a8d1e['diffData']){if(_0x5a8d1e['diffData'][_0x4e6150]['attachChange']&&!_0x5a8d1e['diffData'][_0x4e6150]['attachChange']['isAttached'])continue;const _0x282c66=this['_removeRevisionMarkers'](JSON['parse'](_0x5a8d1e['diffData'][_0x4e6150]['insertions'])),_0x51f82c=this['editor']['editing']['view']['document'],_0x493e0e=new _0x103c9a(_0x51f82c,_0x282c66['map'](_0x391a0a=>this['_getViewFromDiffObj'](_0x391a0a,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x5571b7[_0x4e6150]=this['editor']['data']['processor']['toData'](_0x493e0e),this['editor']['data']['processor']['useFillerType']('default');}return _0x5571b7;}['getRevisionRootsAttributes'](_0xa82cb3){const _0x4e2961={};for(const _0x48846f in _0xa82cb3['diffData'])_0xa82cb3['diffData'][_0x48846f]['attachChange']&&!_0xa82cb3['diffData'][_0x48846f]['attachChange']['isAttached']||(_0x4e2961[_0x48846f]=_0xa82cb3['diffData'][_0x48846f]['attributesAfter']||{});return _0x4e2961;}['_getTypeCharForViewElement'](_0x3ed979){return this['_viewClassToTypeChar']['get'](_0x3ed979['constructor']);}['_getViewFromDiffObj'](_0x2cf743,_0x4b5b07){const _0x54c5bd=this['editor']['editing']['view']['document'];if('string'==typeof _0x2cf743)return new _0x1ccf06(_0x54c5bd,_0x2cf743);{let _0x58b7cc,_0x501797;_0x501797='u'==_0x2cf743['type']||'r'==_0x2cf743['type']?[]:_0x2cf743['children']['map'](_0x1b9243=>this['_getViewFromDiffObj'](_0x1b9243,_0x4b5b07));const _0x43a1c7=this['_typeCharToViewClass']['get'](_0x2cf743['type'])||_0x530198,_0x294677=this['editor']['data']['htmlProcessor']['domConverter'];if(_0x58b7cc=new _0x43a1c7(_0x54c5bd,_0x2cf743['name'],_0x2cf743['attributes'],_0x501797),'u'==_0x2cf743['type']&&_0x2cf743['children'][0x0]){const _0x5323c0=_0x2cf743['children'][0x0];if(_0x58b7cc['render']=function(_0xb652f0){const _0x173edd=_0xb652f0['createElement']('div');return _0x173edd['innerHTML']=_0x5323c0,_0x173edd['childNodes'][0x0];},_0x4b5b07){const _0x9468ab=new _0x103c9a(_0x54c5bd);_0x9468ab['_appendChild'](_0x58b7cc);const _0x9bac4b=Array['from'](_0x294677['viewChildrenToDom'](_0x9468ab,{'bind':!0x1})),_0x6d74d=_0x294677['domDocument']['createElement']('div');_0x6d74d['append'](..._0x9bac4b),_0x58b7cc=Array['from'](_0x294677['domChildrenToView'](_0x6d74d))[0x0];}}else{if('r'==_0x2cf743['type']&&_0x2cf743['children'][0x0]){const _0x5a1703=_0x2cf743['children'][0x0];if(_0x58b7cc['render']=function(_0x360afb){_0x360afb['innerHTML']=_0x5a1703;},_0x4b5b07){const _0xc69f0d=new _0x103c9a(_0x54c5bd);_0xc69f0d['_appendChild'](_0x58b7cc);const _0x57e79e=Array['from'](_0x294677['viewChildrenToDom'](_0xc69f0d,{'bind':!0x1})),_0x1d8f4b=_0x294677['domDocument']['createElement']('div');_0x1d8f4b['append'](..._0x57e79e);const _0xa27eb5=Array['from'](_0x294677['domChildrenToView'](_0x1d8f4b));_0xa27eb5['length']>0x1?_0x58b7cc['_appendChild'](_0xa27eb5):_0x58b7cc=_0xa27eb5[0x0];}}}if(_0x2cf743['customProperties']){for(const [_0x57bd28,_0x3984fd]of _0x2cf743['customProperties'])_0x58b7cc['_setCustomProperty'](_0x57bd28,_0x3984fd);}const _0x29a7a8=void 0x0===_0x2cf743['fillerOffset']?null:_0x2cf743['fillerOffset'];return null!==_0x29a7a8&&(_0x58b7cc['getFillerOffset']=()=>_0x29a7a8),_0x58b7cc;}}['_makeModelFromViewString'](_0x373a12){const _0xd448a2=JSON['parse'](_0x373a12),_0x11ba96=this['editor']['editing']['view']['document'],_0x19be18=new _0x103c9a(_0x11ba96,_0xd448a2['map'](_0x288103=>this['_getViewFromDiffObj'](_0x288103,!0x0)));return this['editor']['data']['toModel'](_0x19be18);}['_removeRevisionMarkers'](_0x350838){return(_0x350838=_0x350838['filter'](_0x5e7ec9=>!_0x5e7ec9['name']||'revision-start'!==_0x5e7ec9['name']&&'revision-end'!==_0x5e7ec9['name']))['forEach'](_0x106651=>{'string'!=typeof _0x106651&&(_0x106651['children']=this['_removeRevisionMarkers'](_0x106651['children']),_0x106651['attributes']=_0x106651['attributes']['filter'](_0x1b755f=>!_0x1b755f[0x0]['startsWith']('data-revision-')));}),_0x350838;}}function R(_0x4cc3f7,_0xe9da72,_0xeb9a2c){const t=_0x4cc3f7['t'];switch(_0xe9da72){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'},_0xeb9a2c);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0xeb9a2c);case'Show\x20previous\x20change':return t('Show\x20previous\x20change');case'Show\x20next\x20change':return t('Show\x20next\x20change');case'EDIT_X_OF_Y_REVISIONS':return t({'string':'Edit','id':'EDIT_X_OF_Y_REVISIONS'});case'Total':return t('Total');case'Revision\x20creator':return t('Revision\x20creator');case'Revision\x20author':return t('Revision\x20author');case'Revision\x20name':return t('Revision\x20name');case'Save\x20current\x20revision':return t('Save\x20current\x20revision');case'Accept':return t('Accept');case'Save':return t('Save');case'Cancel':return t('Cancel');case'Name\x20of\x20the\x20revision':return t('Name\x20of\x20the\x20revision');case'optional':return t('optional');case'PENDING_ACTION_REVISION_HISTORY':return t({'string':'Unsaved\x20change\x20in\x20revision\x20history.','id':'PENDING_ACTION_REVISION_HISTORY'});case'The\x20revision\x20name\x20cannot\x20be\x20empty.':return t('The\x20revision\x20name\x20cannot\x20be\x20empty.');case'Enter\x20the\x20revision\x20name':return t('Enter\x20the\x20revision\x20name');default:return'';}}class h extends _0x40d69e{['licenseKey'];['_licenseKeyCheckInterval'];['currentRevision']=null;['repository'];['adapter']=null;['_revisionDataBuilder'];['_source'];['_initialRevisionId'];['_bufferedUpdates'];['_utils'];['_pendingAction'];['_continueCurrentRevision'];['_startingVersion'];['_loadedStateData'];static get['pluginName'](){return'RevisionTracker';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[_0x31b528,S,$,_0x371990];}constructor(_0x106af3){super(_0x106af3),this['repository']=this['editor']['plugins']['get']('RevisionsRepository'),this['_utils']=this['editor']['plugins']['get']('RevisionHistoryUtils'),this['_revisionDataBuilder']=new E(this['editor']),this['_initialRevisionId']=this['editor']['config']['get']('collaboration.channelId')||'initial',this['_bufferedUpdates']=new Map(),this['_loadedStateData']=null;const _0x1ef2bf=_0x58edc7();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x1ef2bf},this['set']('isReady',!0x1),this['set']('isEnabled',!0x0),this['set']('_isPendingUpdate',!0x1),this['editor']['config']['define']('revisionHistory.resumeUnsavedRevision',!0x0),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'});}['init'](){this['_setConversion'](),this['editor']['data']['on']('ready',()=>{const _0x5f35ba=this['repository']['getRevision'](0x0),_0x4cbc3f=_0x5f35ba&&null===_0x5f35ba['creator']?_0x5f35ba:null;if(this['_continueCurrentRevision']=!!_0x4cbc3f&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x261e16=this['_source']['getCurrentRevisionId'](),_0x199248=this['repository']['getRevision'](_0x261e16);if(_0x199248)this['_startingVersion']=_0x199248['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x5e8dc4=this['_source']['history']['_operations']['find'](_0x3ecef5=>!_0x3ecef5['_isInit']),_0x1a551d=_0x5e8dc4?_0x5e8dc4['baseVersion']:this['_source']['history']['version'];_0x5f35ba?(_0x5f35ba['toVersion']<_0x1a551d&&_0x5f35ba['_update']({'toVersion':_0x1a551d}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x4cbc3f['id'],this['_startingVersion']=_0x4cbc3f['fromVersion']):(this['_startingVersion']=_0x5f35ba['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x1a551d,this['_continueCurrentRevision']=!0x1);}}else _0x4cbc3f&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x4cbc3f['toVersion'],this['editor']['model']['document']['history']['version']),_0x4cbc3f['fromVersion']===_0x4cbc3f['toVersion']?(0x0!==_0x4cbc3f['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x4cbc3f['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x4cbc3f['id'],this['_startingVersion']=_0x4cbc3f['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',_0x3f4419=>!_0x3f4419),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x30e5d6=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x2473b7;for(const _0x1e8df5 in _0x30e5d6){const _0x15c341=_0x1e8df5,_0x3db3a1=_0x30e5d6[_0x15c341];if('revisionHistoryLicenseKeyValid'==_0x3db3a1||'revisionHistoryLicenseKeyInvalid'==_0x3db3a1||'revisionHistoryLicenseKeyExpired'==_0x3db3a1||'revisionHistoryLicenseKeyDomainLimit'==_0x3db3a1||'revisionHistoryLicenseKeyNotAllowed'==_0x3db3a1||'revisionHistoryLicenseKeyEvaluationLimit'==_0x3db3a1||'revisionHistoryLicenseKeyTrialLimit'==_0x3db3a1||'revisionHistoryLicenseKeyUsageLimit'==_0x3db3a1){delete _0x30e5d6[_0x15c341],_0x2473b7=_0x3db3a1,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x2473b7&&_0x30e5d6['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x2473b7&&_0x30e5d6['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x2473b7&&_0x30e5d6['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x2473b7&&_0x30e5d6['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x2473b7&&_0x30e5d6['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x2473b7&&_0x30e5d6['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x2473b7&&_0x30e5d6['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x420a5a=this['repository']['getRevision'](0x0),_0xd6ed85=await this['getRevisionDocumentData'](_0x420a5a),_0x3a1850=await this['getRevisionRootsAttributes'](_0x420a5a);this['_replaceEditorDataWithRevisionData'](_0xd6ed85,_0x3a1850);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x5e3d9d){this['_source']=_0x5e3d9d;}async['update'](){const _0x25eda7=await this['_source']['getLatestVersion']();if(_0x25eda7>this['currentRevision']['toVersion']){await this['_loadState']();const _0x290e84=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x25eda7});_0x290e84['authors']=_0x290e84['authorsIds']['map'](_0x38a097=>this['editor']['plugins']['get']('Users')['getUser'](_0x38a097)),this['currentRevision']['_update'](_0x290e84);}}async['saveRevision'](_0x2e2e42={},_0x4979b4=null){const _0x51c644=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x4979b4>this['currentRevision']['toVersion']&&(_0x4979b4=null),null===_0x4979b4&&(_0x4979b4=await this['_source']['getLatestVersion']());const _0x46df2a=this['_getFromVersion'](_0x4979b4),_0x485963=this['buildRevisionData']({'from':_0x46df2a,'to':_0x4979b4});if(this['currentRevision']['toVersion']<_0x4979b4){const _0x1b8493=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x4979b4,'to':_0x4979b4});_0x1b8493['authors']=[],_0x1b8493['authorsIds']=[],_0x1b8493['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x1b8493,!0x0),delete _0x1b8493['authors'],_0x51c644['push'](_0x1b8493);}_0x2e2e42['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x2e2e42['name']=_0x2e2e42['name']||null,_0x2e2e42['id']=_0x2e2e42['id']||_0x58edc7(),_0x2e2e42={..._0x2e2e42,..._0x485963};const _0x11ddef=this['addRevisionData'](_0x2e2e42);_0x51c644['push'](_0x2e2e42);const _0x4ade19=this['repository']['getIndex'](_0x11ddef);if(0x0!==_0x4ade19){const _0x2b30f7=this['repository']['getRevision'](_0x4ade19-0x1);if(_0x2b30f7['fromVersion']!==_0x4979b4){const _0x257a00=this['_revisionDataBuilder']['getData'](_0x4979b4,_0x2b30f7['toVersion']),_0x5626c7={'id':_0x2b30f7['id'],'diffData':_0x257a00['diffData'],'authorsIds':_0x257a00['authorsIds'],'authors':_0x257a00['authorsIds']['map'](_0x90e49=>this['editor']['plugins']['get']('Users')['getUser'](_0x90e49)),'fromVersion':_0x4979b4};_0x2b30f7===this['currentRevision']&&(_0x5626c7['createdAt']=new Date(_0x2e2e42['createdAt']['getTime']()+0xa)),_0x2b30f7['_update'](_0x5626c7,!0x0),delete _0x5626c7['authors'],_0x51c644['push'](_0x5626c7);}}if(this['adapter']){for(const _0x4f5045 of _0x51c644)this['_bufferUpdate'](_0x4f5045['id'],_0x4f5045,!0x0);this['sendBufferedUpdates']();}return _0x11ddef;}['addRevisionData'](_0x939e3d){const _0x184a81=this['repository']['createRevision'](_0x939e3d);return this['adapter']&&_0x184a81['on']('_update',(_0x35f91a,_0x21ca4a,_0xc75411)=>{_0xc75411||(this['_bufferUpdate'](_0x21ca4a['id'],_0x21ca4a,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x184a81,this['_findInsertionIndex'](_0x184a81)),_0x184a81;}async['getRevisionDocumentData'](_0x2ccc32){return await this['_utils']['loadRevisionData'](_0x2ccc32,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x2ccc32);}async['getRevisionRootsAttributes'](_0x544b57){return await this['_utils']['loadRevisionData'](_0x544b57,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x544b57);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x48e455=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0xb0ed1=0x0;_0xb0ed1<_0x48e455['length'];_0xb0ed1++){const _0x143bad=_0x48e455[_0xb0ed1];let _0xff412c=!0x1;for(const _0x5635ec of Object['keys'](_0x143bad))void 0x0===_0x143bad[_0x5635ec]?delete _0x143bad[_0x5635ec]:'id'!==_0x5635ec&&(_0xff412c=!0x0);_0xff412c||(_0x48e455[_0xb0ed1]=null);}if(_0x48e455=_0x48e455['filter'](_0xa53a5a=>null!==_0xa53a5a),!_0x48e455['length'])return;for(let _0x1911d8=0x0;_0x1911d8<_0x48e455['length'];_0x1911d8++){const _0x56e136=_0x48e455[_0x1911d8];void 0x0!==_0x56e136['fromVersion']&&void 0x0===_0x56e136['toVersion']&&(_0x56e136['toVersion']=this['repository']['getRevision'](_0x56e136['id'])['toVersion']),void 0x0!==_0x56e136['toVersion']&&void 0x0===_0x56e136['fromVersion']&&(_0x56e136['fromVersion']=this['repository']['getRevision'](_0x56e136['id'])['fromVersion']);}const _0x1d3cf3=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x48e455,_0x1d3cf3)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x53f56c=>{if(_0x53f56c){for(const _0x316d20 of _0x53f56c)this['setRevisionData']({'id':_0x316d20['id'],'createdAt':_0x316d20['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0x15cb1f=null,from:_0x4e8ee1=null,to:_0x4a4a12=null}){_0x4e8ee1=null!==_0x4e8ee1?_0x4e8ee1:_0x15cb1f['fromVersion'],_0x4a4a12=null!==_0x4a4a12?_0x4a4a12:_0x15cb1f['toVersion'];const _0x518ae8=this['_revisionDataBuilder']['getData'](_0x4e8ee1,_0x4a4a12),_0x56edac={'diffData':_0x518ae8['diffData'],'authorsIds':_0x518ae8['authorsIds'],'fromVersion':_0x4e8ee1,'toVersion':_0x4a4a12};if(!_0x15cb1f||_0x4a4a12!==_0x15cb1f['toVersion']){const _0x2421f0=_0x4a4a12-0x1,_0x515085=this['_source']['history']['getOperation'](_0x2421f0);_0x56edac['createdAt']=_0x515085&&_0x515085['createdAt']||new Date();}if(this['_loadedStateData']&&_0x4e8ee1===this['_loadedStateData']['fromVersion']){for(const _0x4acab0 of this['_loadedStateData']['authors'])_0x56edac['authorsIds']['includes'](_0x4acab0['id'])||_0x56edac['authorsIds']['push'](_0x4acab0['id']);}return _0x56edac;}['_bufferUpdate'](_0x1b4dcc,_0x34809c,_0x5bde25){if(this['_bufferedUpdates']['has'](_0x1b4dcc)){const _0x7a3e55=this['_bufferedUpdates']['get'](_0x1b4dcc);_0x34809c=_0x5bde25?{..._0x7a3e55,..._0x34809c}:{..._0x34809c,..._0x7a3e55};}this['_bufferedUpdates']['set'](_0x1b4dcc,_0x34809c);}['setRevisionData'](_0x2bb20b){const _0x9ef52f=this['repository']['getRevision'](_0x2bb20b['id']);if(_0x2bb20b['createdAt']&&(_0x2bb20b['createdAt']=new Date(_0x2bb20b['createdAt'])),_0x2bb20b['authorsIds']){const _0x1844e4=this['editor']['plugins']['get']('Users');_0x2bb20b['authors']=_0x2bb20b['authorsIds']['map'](_0x1503c3=>_0x1844e4['getUser'](_0x1503c3));}_0x9ef52f['_update'](_0x2bb20b,!0x0);}['_createInitialRevision'](_0x69e4b2){const _0x130365=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x130365)this['_initialRevisionId']=_0x130365['id'];else{const _0x260444=!this['editor']['model']['document']['roots']['find'](_0x3255d9=>this['editor']['model']['hasContent'](_0x3255d9)),_0x4776bf=this['editor']['plugins']['get']('Users')['me']['id'],_0x30624f=R(this['editor']['locale'],_0x260444?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x69e4b2,'to':_0x69e4b2,'id':this['_initialRevisionId'],'name':_0x30624f,'creatorId':_0x4776bf});}}['_createCurrentRevision'](_0x1e9062){const _0x14a71f=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x14a71f),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x1e9062,'to':_0x1e9062,'id':_0x14a71f,'name':'','creatorId':null}));}async['_loadState'](){this['_continueCurrentRevision']&&!this['_loadedStateData']&&(await this['_utils']['loadRevisionData'](this['currentRevision'],this['adapter']),this['_revisionDataBuilder']['loadState'](this['currentRevision']),this['_loadedStateData']={'fromVersion':this['currentRevision']['fromVersion'],'authors':this['currentRevision']['authors']['slice']()});}['_replaceEditorDataWithRevisionData'](_0x160924,_0x3d57ab){let _0x36bb35=this['editor']['config']['get']('initialData'),_0x4f5e36=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x36bb35){_0x36bb35={};for(const _0x5ea0cf of this['editor']['model']['document']['getRootNames']())_0x36bb35[_0x5ea0cf]='';}if('string'==typeof _0x36bb35&&(_0x36bb35={'main':_0x36bb35}),void 0x0===_0x4f5e36){_0x4f5e36={};for(const _0x5b9477 of this['editor']['model']['document']['getRootNames']())_0x4f5e36[_0x5b9477]={};}let _0x3f0787=!0x1;const _0x54a4be=Object['keys'](_0x36bb35),_0x4a6945=Object['keys'](_0x160924);for(const _0x175928 of _0x54a4be){if(_0x36bb35[_0x175928]!==_0x160924[_0x175928]&&''!==_0x36bb35[_0x175928]['trim']()){_0x3f0787=!0x0;break;}if(!_0x158881(_0x4f5e36[_0x175928],_0x3d57ab[_0x175928])&&Object['keys'](_0x4f5e36[_0x175928])['length']>0x0){_0x3f0787=!0x0;break;}}_0x3f0787||(_0x3f0787=_0x4a6945['some'](_0x615800=>!this['editor']['model']['document']['getRoot'](_0x615800))),_0x3f0787&&_0x3c4dda('editor-initial-data-replaced-with-revision-data',{'editorData':_0x36bb35,'editorRootsAttributes':_0x4f5e36,'revisionData':_0x160924,'revisionRootsAttributes':_0x3d57ab}),this['editor']['config']['set']('initialData',_0x160924),this['editor']['config']['set']('rootsAttributes',_0x3d57ab);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x11a261=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x11a261['add'](R(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x350a4b){const _0x1d19c3=this['repository']['getRevisions']();_0x1d19c3['reverse']();let _0x583971=0x0;for(;_0x583971<_0x1d19c3['length'];){const _0x1e01d0=_0x1d19c3[_0x583971];if(_0x1e01d0===this['currentRevision']){_0x583971++;continue;}if(_0x1e01d0['id']===this['_initialRevisionId'])break;const _0x35226e=_0x350a4b['toVersion']-_0x1e01d0['toVersion']||_0x350a4b['fromVersion']-_0x1e01d0['fromVersion'];if(_0x35226e>0x0)break;if(_0x35226e<0x0)_0x583971++;else{if(!_0x350a4b['creator']&&_0x1e01d0['creator'])break;if(_0x1e01d0['creator']||!_0x350a4b['creator']){if(_0x350a4b['createdAt']>_0x1e01d0['createdAt'])break;_0x583971++;}else _0x583971++;}}return _0x583971;}['_getFromVersion'](_0x140ab1){const _0x3fd6c2=this['repository']['getRevisions']();_0x3fd6c2['reverse'](),_0x3fd6c2['shift']();const _0x58b225=_0x3fd6c2['find'](_0xdb1c5e=>_0xdb1c5e['toVersion']<=_0x140ab1)['toVersion'];return _0x58b225<this['_startingVersion']?this['_startingVersion']:_0x58b225;}['_makeRevision']({name:_0x3b7bca,from:_0x3f8343,to:_0x1f69dc,creatorId:_0x423b14,id:_0x24bfd7}){const _0x33c033=this['buildRevisionData']({'from':_0x3f8343,'to':_0x1f69dc});_0x33c033['name']=_0x3b7bca,_0x33c033['creatorId']=_0x423b14,_0x33c033['id']=_0x24bfd7;const _0x27190a=this['addRevisionData'](_0x33c033);return this['adapter']&&this['_bufferUpdate'](_0x33c033['id'],_0x33c033,!0x0),_0x27190a;}['_setConversion'](){this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'});}}class E{['editor'];['source'];['_savedMetaData'];['_lastFrom'];['_lastTo'];['_markers'];['_diffRoots'];['_diffRootsAttributes'];['_baseRoots'];['_baseRootsAttributes'];['_idsRoots'];['_baseIdsRoots'];['_touched'];['_touchedMarkers'];['_touchedRoots'];['_revisionId'];['_startingRevisionId'];constructor(_0x2e8879){this['editor']=_0x2e8879,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'](_0x1e6058){this['source']=_0x1e6058;const _0x1e62c5=new Map(),_0x15c5e6=new Map(),_0x4b6388=this['editor']['model']['document']['roots']['map'](_0x3704fd=>_0x3704fd['rootName']);for(const _0x3db005 of _0x4b6388){const _0x365041=this['editor']['model']['document']['getRoot'](_0x3db005),_0x18aa21=x(_0x365041);_0x1e62c5['set'](_0x3db005,_0x18aa21),_0x15c5e6['set'](_0x3db005,Object['fromEntries'](_0x365041['getAttributes']()));}const _0x134e47=Array['from'](this['editor']['model']['markers'])['map'](_0x166381=>[_0x166381['name'],_0x166381['getRange']()]),_0x33fc99=this['source']['version'];this['_saveMetaData'](_0x33fc99,_0x1e62c5,_0x134e47,_0x15c5e6),this['_startingRevisionId']=this['_revisionId'];const _0x1b0d18=new Map(),_0x487eb2=new Map();for(const _0x5e42ee of _0x4b6388){const _0x536a84=N(_0x5e42ee);_0x1b0d18['set'](_0x5e42ee,_0x536a84),_0x487eb2['set'](_0x5e42ee,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x1b0d18,[],_0x487eb2);}['getData'](_0x18fced,_0x8c879c){if(this['_lastFrom']===_0x18fced&&this['_lastTo']<=_0x8c879c)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x8c879c,!0x0);else{if(!this['_savedMetaData']['has'](_0x18fced)){const _0x12d47b=this['_getPreviousFrom'](_0x18fced);this['_calculateMetaData'](_0x12d47b,_0x18fced,!0x1);}this['_calculateMetaData'](_0x18fced,_0x8c879c,!0x0);}return this['_lastFrom']=_0x18fced,this['_lastTo']=_0x8c879c,this['_getState']();}['loadState'](_0x277e21){const _0x27951d=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x277e21['fromVersion'],this['_lastTo']=_0x277e21['toVersion'];for(const _0x2cf676 in _0x277e21['diffData']){const _0x27915b=_0x277e21['diffData'][_0x2cf676]['attachChange'],_0x5a0396=_0x570b2f(_0x277e21['diffData'][_0x2cf676]['attributesBefore'])||{},_0x252d19=_0x27951d['_makeModelFromViewString'](_0x277e21['diffData'][_0x2cf676]['deletions']);_0x252d19['rootName']=_0x2cf676,_0x252d19['_isAttached']=!_0x27915b||!_0x27915b['isAttached'],_0x252d19['isAttached']=()=>_0x252d19['_isAttached'],this['_baseRoots']['set'](_0x2cf676,_0x252d19),this['_baseRootsAttributes']['set'](_0x2cf676,_0x5a0396),_0x27915b&&this['_touchedRoots']['set'](_0x2cf676,_0x27915b);const _0x161627=this['_makeIdsRoot'](_0x252d19);this['_baseIdsRoots']['set'](_0x2cf676,_0x161627);for(const [_0x27978f,_0x401b70]of _0x252d19['markers']){if(!_0x27978f['startsWith']('revision:'))continue;const _0x2085e5=_0x27978f['split'](':')[0x2];for(const _0x33e0c2 of _0x401b70['getWalker']({'singleCharacters':!0x0})){const _0x25145e=this['_getVidAttributeName'](_0x33e0c2),_0x16a291='elementEnd'==_0x33e0c2['type']?_0x33e0c2['previousPosition']['path']['slice'](0x0,-0x1):_0x33e0c2['previousPosition']['path'],_0x112529=_0x161627['getNodeByPath'](_0x16a291)['getAttribute'](_0x25145e);this['_touched']['set'](_0x112529,{'userId':_0x2085e5});}}}this['_startingRevisionId']=this['_revisionId'];const _0x20a533=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x18d3e2=>!this['_touched']['has'](_0x18d3e2));let _0xec8143=0x0;const _0x19d16c=new Map();for(const _0x54c5ba in _0x277e21['diffData']){const _0x188aec=_0x277e21['diffData'][_0x54c5ba]['attachChange'],_0x9f6552=_0x570b2f(_0x277e21['diffData'][_0x54c5ba]['attributesAfter'])||{},_0xd33806=_0x27951d['_makeModelFromViewString'](_0x277e21['diffData'][_0x54c5ba]['insertions']);_0xd33806['rootName']=_0x54c5ba,_0xd33806['_isAttached']=!_0x188aec||_0x188aec['isAttached'],_0xd33806['isAttached']=()=>_0xd33806['_isAttached'],this['_diffRoots']['set'](_0x54c5ba,_0xd33806),this['_diffRootsAttributes']['set'](_0x54c5ba,_0x9f6552);const _0x3d2c9d=this['_makeIdsRoot'](_0xd33806,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x54c5ba,_0x3d2c9d),_0x19d16c['set'](_0x54c5ba,_0xd33806['isAttached']()?_0x9f6552:{});for(const [_0x2c8997,_0x58647c]of _0xd33806['markers']){if(!_0x2c8997['startsWith']('revision:'))continue;const _0x259d44=_0x2c8997['split'](':')[0x2];for(const _0x45779c of _0x58647c['getWalker']({'singleCharacters':!0x0})){const _0x415abf=this['_getVidAttributeName'](_0x45779c),_0x4c63c2=this['_revisionId']++,_0xda1369='elementEnd'==_0x45779c['type']?_0x45779c['previousPosition']['path']['slice'](0x0,-0x1):_0x45779c['previousPosition']['path'];_0x3d2c9d['getNodeByPath'](_0xda1369)['_setAttribute'](_0x415abf,_0x4c63c2),this['_touched']['set'](_0x4c63c2,{'userId':_0x259d44});}}for(const _0x1eba96 of this['editor']['model']['createRangeIn'](_0xd33806)['getWalker']({'singleCharacters':!0x0})){const _0x57d613=this['_getVidAttributeName'](_0x1eba96),_0x10e48f='elementEnd'==_0x1eba96['type']?_0x1eba96['previousPosition']['path']['slice'](0x0,-0x1):_0x1eba96['previousPosition']['path'],_0x2b497d=_0x3d2c9d['getNodeByPath'](_0x10e48f);_0x2b497d['getAttribute'](_0x57d613)>0x0||_0x2b497d['_setAttribute'](_0x57d613,_0x20a533[_0xec8143++]);}for(const [_0x273d54,_0x4a466e]of _0xd33806['markers'])_0x273d54['startsWith']('revision:')||this['_markers']['set'](_0x273d54,_0x4a466e);}const _0x3b049a=N('$graveyard');this['_baseRoots']['set']('$graveyard',_0x3b049a),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x3b049a,0x1));const _0x3a842a=N('$graveyard');this['_diffRoots']['set']('$graveyard',_0x3a842a),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x3a842a,0x1));const _0x50bba2=Array['from'](this['_diffRoots'])['map'](([_0x38c71d,_0x1b18ef])=>[_0x38c71d,x(_0x1b18ef)]);this['_saveMetaData'](this['_lastTo'],_0x50bba2,this['_markers'],_0x19d16c);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0x4c25db,_0x62ffdb,_0x37caef,_0x4b68e9){const _0x14a036=new Map(_0x62ffdb),_0x5519d0=new Map(_0x570b2f(_0x4b68e9)),_0x4ae15f=new Map();for(const [_0x30cf99,_0x462299]of _0x37caef)_0x4ae15f['set'](_0x30cf99,{'start':_0x462299['start']['clone'](),'end':_0x462299['end']['clone'](),'rootName':_0x462299['root']['rootName']});this['_savedMetaData']['set'](_0x4c25db,{'roots':_0x14a036,'markers':_0x4ae15f,'rootsAttributes':_0x5519d0});}['_removeMetaData'](_0x2f637f){this['_savedMetaData']['delete'](_0x2f637f);}['_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'](_0x36d88b,_0x2e7154=null){let _0xed8ec0=null;_0x36d88b['is']('documentFragment')||(_0xed8ec0=new _0x149c78(_0x36d88b['name'],{'vid_start':null===_0x2e7154?this['_revisionId']++:_0x2e7154++}));const _0x125d29=[];for(const _0x307aae of _0x36d88b['getChildren']())if(_0x307aae['is']('element')){_0x125d29['push'](this['_makeIdsRoot'](_0x307aae,_0x2e7154));const _0x2017ff=_0x125d29[_0x125d29['length']-0x1];null!==_0x2e7154&&(_0x2e7154=_0x2017ff['is']('element','$text')?_0x2017ff['getAttribute']('vid')+0x1:_0x2017ff['getAttribute']('vid_end')+0x1);}else{for(let _0xfde36b=0x0;_0xfde36b<_0x307aae['offsetSize'];_0xfde36b++)_0x125d29['push'](new _0x149c78('$text',{'vid':null===_0x2e7154?this['_revisionId']++:_0x2e7154++}));}if(_0x36d88b['is']('documentFragment')){const _0x44d3e5=N(_0x36d88b['rootName']);return _0x44d3e5['_insertChild'](0x0,_0x125d29),_0x44d3e5;}return _0xed8ec0['_setAttribute']('vid_end',null===_0x2e7154?this['_revisionId']++:_0x2e7154++),_0xed8ec0['_insertChild'](0x0,_0x125d29),_0xed8ec0;}['_calculateMetaData'](_0x35b349,_0x535ced,_0x4fb822){this['_reset']();const {roots:_0x273fdd,markers:_0x4e07ff,rootsAttributes:_0x2fda2e}=this['_savedMetaData']['get'](_0x35b349);this['_baseRoots']=new Map(_0x273fdd),this['_baseRootsAttributes']=new Map(_0x570b2f(_0x2fda2e));for(const [_0xa87e3,_0x374a2a]of this['_baseRoots'])if('$graveyard'!==_0xa87e3&&(this['_diffRoots']['set'](_0xa87e3,x(_0x374a2a)),this['_diffRootsAttributes']=new Map(_0x570b2f(_0x2fda2e)),_0x4fb822)){const _0x368f1f=this['_revisionId'];this['_idsRoots']['set'](_0xa87e3,this['_makeIdsRoot'](_0x374a2a)),this['_baseIdsRoots']['set'](_0xa87e3,this['_makeIdsRoot'](_0x374a2a,_0x368f1f));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',x(this['_baseRoots']['get']('$graveyard'))),_0x4fb822&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x49f7c5,_0x51df03]of _0x4e07ff){const _0x345665=this['_baseRoots']['get'](_0x51df03['rootName']),_0x3f28e6=this['_diffRoots']['get'](_0x51df03['rootName']),_0x2f08dc=new _0x16968a(this['_fixPosition'](_0x51df03['start'],_0x345665),this['_fixPosition'](_0x51df03['end'],_0x345665)),_0x5bcf7e=this['_fixRange'](_0x2f08dc,_0x3f28e6);_0x345665['markers']['set'](_0x49f7c5,_0x2f08dc),this['_markers']['set'](_0x49f7c5,_0x5bcf7e);}this['_applyOperations'](_0x35b349,_0x535ced,_0x4fb822);}['_applyOperations'](_0x7b6188,_0x1421eb,_0x4416f0){for(const _0x39464e of this['source']['getOperations'](_0x7b6188,_0x1421eb))this['_handleOperation'](_0x39464e,_0x4416f0);for(const _0x4bbbdb of this['_diffRoots']['values']())_0x4bbbdb['markers']['clear']();for(const [_0x3efa6f,_0xce3163]of this['_markers']){this['_diffRoots']['get'](_0xce3163['root']['rootName'])['markers']['set'](_0x3efa6f,_0xce3163['clone']());}const _0x5be5b5=new Map(),_0x58deff=new Map();for(const [_0x3ec5ad,_0x301d51]of this['_diffRoots'])_0x5be5b5['set'](_0x3ec5ad,x(_0x301d51)),_0x58deff['set'](_0x3ec5ad,this['_diffRootsAttributes']['get'](_0x3ec5ad));this['_saveMetaData'](_0x1421eb,_0x5be5b5,this['_markers'],_0x58deff);}['_getPreviousFrom'](_0x1f84fd){const _0x279c06=Array['from'](this['_savedMetaData']['keys']());_0x279c06['sort']((_0x3d8bb2,_0x4c3606)=>_0x3d8bb2-_0x4c3606),_0x279c06['reverse']();for(const _0x365959 of _0x279c06)if(_0x365959<_0x1f84fd)return _0x365959;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x4599b8,_0x53add2){const _0x2d32d0=Array['from'](_0x53add2['markers'])['map'](([_0x428c02,_0x190ad7])=>[_0x428c02,this['_fixRange'](_0x190ad7,_0x4599b8)]);_0x4599b8['markers']=new Map(_0x2d32d0);}['_transformMarkers'](_0x4a85f1){for(const _0x2fd12f of this['_markers']['values']()){const _0x28ee7c=_0x2fd12f['getTransformedByOperation'](_0x4a85f1),_0x32ebaf=_0x16968a['_createFromRanges'](_0x28ee7c);_0x2fd12f['start']=_0x32ebaf['start'],_0x2fd12f['end']=_0x32ebaf['end'];}}['_handleOperation'](_0x228ff3,_0x1e7b17){if('addRoot'!=_0x228ff3['type']&&'detachRoot'!=_0x228ff3['type']){if('insert'==_0x228ff3['type']){const _0x2614be=_0x228ff3['position']['root']['rootName'];this['_diffRoots']['has'](_0x2614be)||(this['_diffRoots']['set'](_0x2614be,N(_0x2614be,!0x0)),this['_diffRootsAttributes']['set'](_0x2614be,{}),_0x1e7b17&&this['_idsRoots']['set'](_0x2614be,N(_0x2614be,!0x0)));}else{if('addRootAttribute'==_0x228ff3['type']||'removeRootAttribute'==_0x228ff3['type']||'changeRootAttribute'==_0x228ff3['type'])return void this['_handleRootAttributeOperation'](_0x228ff3);'marker'==_0x228ff3['type']&&this['_handleMarkerOperation'](_0x228ff3);}if('marker'!==_0x228ff3['type']){const _0x2eb9e1=this['_cloneOperation'](_0x228ff3,this['_diffRoots']);_0x2eb9e1['_execute'](),this['_transformMarkers'](_0x2eb9e1);}if(_0x1e7b17)switch(_0x228ff3['type']){case'insert':this['_handleInsertOperation'](_0x228ff3);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x228ff3);break;case'merge':this['_handleMergeOperation'](_0x228ff3);break;case'split':this['_handleSplitOperation'](_0x228ff3);}}else this['_handleRootOperation'](_0x228ff3,_0x1e7b17);}['_cloneOperation'](_0x2e41e4,_0x89e70b){const _0x3c03e0=_0x2e41e4['clone']();return _0x3c03e0['_authorId']=_0x2e41e4['_authorId'],this['_fixOperation'](_0x3c03e0,_0x89e70b),_0x3c03e0;}['_getBaseVids'](_0x250b4d){return _0x250b4d['map'](_0x51c371=>{const _0x2534d3=this['_getVidAttributeName'](_0x51c371);return Number(_0x51c371['item']['getAttribute'](_0x2534d3));});}['_generateTape'](_0x20f891,_0x6f3adf){if(_0x20f891['is']('element','$text'))_0x6f3adf['push']({'item':_0x20f891,'type':'text'});else{_0x20f891['is']('element')&&_0x6f3adf['push']({'item':_0x20f891,'type':'elementStart'});for(const _0x4477a1 of _0x20f891['getChildren']())this['_generateTape'](_0x4477a1,_0x6f3adf);_0x20f891['is']('element')&&_0x6f3adf['push']({'item':_0x20f891,'type':'elementEnd'});}return _0x6f3adf;}['_getState'](){const _0x5e9500=new Map(this['_touched']),_0x4ed646=new Map(_0x5e9500),_0x7eeeca=new Map(),_0x513bb3={'insertions':{},'deletions':{}},_0x25a591={'insertions':{},'deletions':{}},_0x43d991=new Map(),_0x17712b=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x17712b['delete']('$graveyard');for(const _0x3b4854 of _0x17712b){const _0x113175=this['_diffRoots']['get'](_0x3b4854)||N(_0x3b4854,!0x1),_0x5d111b=this['_baseRoots']['get'](_0x3b4854)||N(_0x3b4854,!0x1);_0x113175['isAttached']()||_0x5d111b['isAttached']()?(_0x513bb3['insertions'][_0x3b4854]=x(_0x113175),_0x513bb3['deletions'][_0x3b4854]=x(_0x5d111b),this['_copyMarkers'](_0x513bb3['deletions'][_0x3b4854],_0x5d111b),this['_copyMarkers'](_0x513bb3['insertions'][_0x3b4854],_0x113175),_0x25a591['insertions'][_0x3b4854]=this['_generateTape'](this['_idsRoots']['get'](_0x3b4854),[]),_0x25a591['deletions'][_0x3b4854]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x3b4854)||N(_0x3b4854,!0x1),[])):_0x17712b['delete'](_0x3b4854);}for(const _0x104e06 of _0x17712b){const _0xb9fade=_0x25a591['insertions'][_0x104e06];for(const _0x221fc5 of _0xb9fade){const _0x19244a=this['_getVidAttributeName'](_0x221fc5),_0x5102b8=_0x221fc5['item']['getAttribute'](_0x19244a);_0x4ed646['delete'](_0x5102b8),_0x5102b8>=this['_startingRevisionId']&&_0x7eeeca['set'](_0x5102b8,_0x5e9500['get'](_0x5102b8));}}for(const _0x1de46c of _0x17712b){const _0x248a8a=_0x25a591['insertions'][_0x1de46c],_0x571d36=this['_getBaseVids'](_0x25a591['deletions'][_0x1de46c]);let _0x1d04f3=0x0;for(const _0x116a60 of _0x248a8a){const _0x546ae7=this['_getVidAttributeName'](_0x116a60),_0x238f60=_0x116a60['item']['getAttribute'](_0x546ae7);if(!_0x7eeeca['has'](_0x238f60)&&!_0x43d991['has'](_0x238f60)){if(_0x4ed646['has'](_0x238f60))_0x1d04f3++;else{if(_0x238f60!=_0x571d36[_0x1d04f3]){const _0x3087fd=_0x5e9500['get'](_0x238f60)||_0x5e9500['get'](_0x571d36[_0x1d04f3]);for(;_0x238f60!=_0x571d36[_0x1d04f3];)_0x4ed646['has'](_0x571d36[_0x1d04f3])||(_0x43d991['set'](_0x571d36[_0x1d04f3],_0x3087fd),_0x5e9500['set'](_0x571d36[_0x1d04f3],_0x3087fd)),_0x1d04f3++;}_0x1d04f3++;}}}}for(const _0x517c2c of _0x17712b){const _0x34fd42=_0x25a591['insertions'][_0x517c2c];for(const _0x186947 of _0x34fd42){const _0x5297fa=this['_getVidAttributeName'](_0x186947),_0x2ebba6=_0x186947['item']['getAttribute'](_0x5297fa);if(_0x43d991['has'](_0x2ebba6)){const _0x2d43f9=_0x43d991['get'](_0x2ebba6);_0x4ed646['has'](_0x2ebba6)||_0x4ed646['set'](_0x2ebba6,{..._0x2d43f9}),_0x7eeeca['set'](_0x2ebba6,{..._0x2d43f9});}}}for(const _0x121938 of _0x4ed646['keys']())_0x121938>=this['_startingRevisionId']&&_0x4ed646['delete'](_0x121938);const _0x1391bc=new Map();for(const _0x55fdc0 of _0x17712b){let _0x10d900=_0x25a591['insertions'][_0x55fdc0];for(const _0x16b29d of _0x10d900)if(_0x16b29d['item']['is']('element','tableCell')){const _0x4f6285=this['_getVidAttributeName'](_0x16b29d),_0xc9bf21=_0x16b29d['item']['getAttribute'](_0x4f6285);if(_0x7eeeca['has'](_0xc9bf21)){const _0x3d0b40=_0x16b29d['item']['parent']['parent']['getAttribute']('vid_start'),_0x3a842f=_0x1391bc['get'](_0x3d0b40)||new Set();_0x3a842f['add'](_0x7eeeca['get'](_0xc9bf21)['userId']),_0x1391bc['set'](_0x3d0b40,_0x3a842f);}}_0x10d900=_0x25a591['deletions'][_0x55fdc0];for(const _0x5f52ce of _0x10d900)if(_0x5f52ce['item']['is']('element','tableCell')){const _0x70f123=this['_getVidAttributeName'](_0x5f52ce),_0x4f891e=_0x5f52ce['item']['getAttribute'](_0x70f123);if(_0x4ed646['has'](_0x4f891e)){const _0x240548=_0x5f52ce['item']['parent']['parent']['getAttribute']('vid_start'),_0xa5f54c=_0x1391bc['get'](_0x240548)||new Set();_0xa5f54c['add'](_0x4ed646['get'](_0x4f891e)['userId']),_0x1391bc['set'](_0x240548,_0xa5f54c);}}for(const _0x59b2a8 of _0x1391bc['keys']())(_0x7eeeca['has'](_0x59b2a8)||_0x4ed646['has'](_0x59b2a8))&&_0x1391bc['delete'](_0x59b2a8);}for(const _0x704826 of _0x17712b){const _0x1778d1=_0x25a591['insertions'][_0x704826];let _0x27729a=null,_0x34b412=null;for(const _0x45a213 of _0x1778d1){const _0x4620d1=this['_getVidAttributeName'](_0x45a213),_0x4141c2=_0x45a213['item']['getAttribute'](_0x4620d1),_0x444a7f=_0x1391bc['get'](_0x4141c2);_0x444a7f&&'elementStart'==_0x45a213['type']&&(_0x27729a=Array['from'](_0x444a7f)[0x0],_0x34b412=_0x45a213['item']['getAttribute']('vid_end')),_0x27729a&&(_0x4ed646['set'](_0x4141c2,{'userId':_0x27729a}),_0x7eeeca['set'](_0x4141c2,{'userId':_0x27729a})),_0x4141c2==_0x34b412&&(_0x27729a=null,_0x34b412=null);}}const _0x29113d={},_0x3ce64a=new Set();for(const _0x7f60de of _0x17712b){const _0x47d888=_0x513bb3['deletions'][_0x7f60de],_0x3d4a67=_0x513bb3['insertions'][_0x7f60de];for(const {userId:_0x527cc4}of this['_touchedMarkers']['values']())null!==_0x527cc4&&_0x3ce64a['add'](_0x527cc4);for(const {userId:_0x4f6990}of this['_touchedRoots']['values']())null!==_0x4f6990&&_0x3ce64a['add'](_0x4f6990);this['_markChanges'](_0x3d4a67,_0x25a591['insertions'][_0x7f60de],_0x7eeeca,'insertion',_0x3ce64a),this['_markChanges'](_0x47d888,_0x25a591['deletions'][_0x7f60de],_0x4ed646,'deletion',_0x3ce64a),_0x29113d[_0x7f60de]={'insertions':this['_prepareViewToSave'](_0x3d4a67),'deletions':this['_prepareViewToSave'](_0x47d888),'attachChange':this['_touchedRoots']['get'](_0x7f60de)||null,'attributesBefore':_0x570b2f(this['_baseRootsAttributes']['get'](_0x7f60de))||{},'attributesAfter':_0x570b2f(this['_diffRootsAttributes']['get'](_0x7f60de))};}return{'diffData':_0x29113d,'authorsIds':Array['from'](_0x3ce64a)};}['_processRootBeforeSave'](_0x582519){for(const [,_0x4e6fb1]of _0x582519['markers']){const _0x26ff2e=_0x4e6fb1['start']['getAncestors']()['filter'](_0x32878b=>'tableCell'==_0x32878b['name']);for(const _0x58d814 of _0x26ff2e)0x1==_0x58d814['childCount']&&_0x58d814['getChild'](0x0)['is']('element','paragraph')&&_0x58d814['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x3f8b96){this['_processRootBeforeSave'](_0x3f8b96);const _0x38d74f=this['editor']['data']['toView'](_0x3f8b96,{}),_0x272605=Array['from'](_0x38d74f['getChildren']())['map'](_0x18167a=>this['_getViewJson'](_0x18167a));return JSON['stringify'](_0x272605);}['_getViewJson'](_0x9dc480){if(_0x9dc480['is']('$text'))return _0x9dc480['data'];{const _0x22a281=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0x3c9a7f=_0x9dc480,_0x152a36=this['editor']['data']['htmlProcessor']['domConverter'],_0x153e2d={'type':_0x22a281['_getTypeCharForViewElement'](_0x3c9a7f),'name':_0x3c9a7f['name'],'attributes':Array['from'](_0x3c9a7f['getAttributes']()),'children':Array['from'](_0x3c9a7f['getChildren']())['map'](_0x11a963=>this['_getViewJson'](_0x11a963))};if(_0x9dc480['is']('uiElement')&&'$comment'!=_0x9dc480['name']){const _0xbe5695=_0x9dc480['render'](_0x152a36['domDocument'],_0x152a36);_0x153e2d['children']['push'](_0xbe5695['outerHTML']);}else{if(_0x9dc480['is']('rawElement')){const _0x50d410=_0x152a36['domDocument']['createElement'](_0x3c9a7f['name']);_0x9dc480['render'](_0x50d410,_0x152a36),_0x153e2d['children']['push'](_0x50d410['innerHTML']);}}const _0x3bda76=Array['from'](_0x3c9a7f['getCustomProperties']());_0x3bda76['length']>0x0&&(_0x153e2d['customProperties']=_0x3bda76);const _0x23f1c9=_0x3c9a7f['getFillerOffset']();return null!==_0x23f1c9&&(_0x153e2d['fillerOffset']=_0x23f1c9),_0x153e2d;}}['_markChanges'](_0x5e3b7a,_0x5e58d5,_0x3bd89e,_0x39bcb5,_0x5e9032){let _0x486e82=null,_0x163029=null,_0x418bec=0x0;const _0x53e8e0=this['editor']['model'];for(let _0x5e579b=0x0;_0x5e579b<_0x5e58d5['length'];_0x5e579b++){const _0x1959f3=this['_getVidAttributeName'](_0x5e58d5[_0x5e579b]),_0xd303e5=_0x5e58d5[_0x5e579b]['item']['getAttribute'](_0x1959f3),_0x15ea8a=_0x3bd89e['get'](_0xd303e5),_0xee2a3a=_0x5e579b==_0x5e58d5['length']-0x1;(!_0x486e82&&_0x15ea8a&&(_0x486e82=_0x15ea8a,_0x163029=_0x5e58d5[_0x5e579b]),_0x486e82&&(!_0x15ea8a||_0x15ea8a['userId']!=_0x486e82['userId']))&&(_0x39c1a6(_0x15ea8a,P(_0x163029,_0x5e3b7a,_0x53e8e0),P(_0x5e58d5[_0x5e579b],_0x5e3b7a,_0x53e8e0)),_0x486e82=_0x15ea8a||null,_0x163029=_0x15ea8a?_0x5e58d5[_0x5e579b]:null),_0x486e82&&_0xee2a3a&&_0x39c1a6(_0x15ea8a,P(_0x163029,_0x5e3b7a,_0x53e8e0),V(_0x5e58d5[_0x5e579b],_0x5e3b7a,_0x53e8e0));}function _0x39c1a6(_0x4c7455,_0x21c19c,_0xe7f6ad){const _0x5d4e31=_0x486e82['userId'],_0x2b6551='revision:'+_0x39bcb5+':'+_0x5d4e31+':'+_0x418bec++,_0x264c8f=_0x53e8e0['createRange'](_0x21c19c,_0xe7f6ad);_0x5e3b7a['markers']['set'](_0x2b6551,_0x264c8f),null!==_0x5d4e31&&_0x5e9032['add'](_0x5d4e31);}}['_getVidAttributeName'](_0x317a32){switch(_0x317a32['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0xb65c6e,_0x9cd09d){_0xb65c6e['baseVersion']=null;for(const _0x48ddc6 in _0xb65c6e){const _0x1f2c7a=_0xb65c6e[_0x48ddc6];if(_0x1f2c7a instanceof _0x424c40){const _0x12c3a7=_0x9cd09d['get'](_0x1f2c7a['root']['rootName']);_0xb65c6e[_0x48ddc6]=this['_fixPosition'](_0x1f2c7a,_0x12c3a7);}if(_0x1f2c7a instanceof _0x16968a){const _0x383280=_0x9cd09d['get'](_0x1f2c7a['root']['rootName']);_0xb65c6e[_0x48ddc6]=this['_fixRange'](_0x1f2c7a,_0x383280);}'root'===_0x48ddc6&&(_0xb65c6e['root']=_0x9cd09d['get'](_0xb65c6e['root']['rootName']));}}['_fixRange'](_0x4710e8,_0x3ee51c){return this['editor']['model']['createRange'](this['_fixPosition'](_0x4710e8['start'],_0x3ee51c),this['_fixPosition'](_0x4710e8['end'],_0x3ee51c));}['_fixPosition'](_0xf49c46,_0x1fc219){return this['editor']['model']['createPositionFromPath'](_0x1fc219,_0xf49c46['path'],_0xf49c46['stickiness']);}['_handleInsertOperation'](_0x226a90){const _0x14c0f8=this['_idsRoots']['get'](_0x226a90['position']['root']['rootName']),_0x24cfba=this['_fixPosition'](_0x226a90['position'],_0x14c0f8),_0x2cdca8=null===_0x226a90['_authorId']?null:_0x226a90['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0xb3d501=_0x24cfba['parent'],_0x276994=this['_revisionId'],_0x1072ea=[];for(const _0x52b56c of _0x226a90['nodes'])if(_0x52b56c['is']('element'))_0x1072ea['push'](this['_makeIdsRoot'](_0x52b56c));else{for(let _0x380b44=0x0;_0x380b44<_0x52b56c['offsetSize'];_0x380b44++)_0x1072ea['push'](new _0x149c78('$text',{'vid':this['_revisionId']++}));}const _0x1de12d=this['_revisionId'];for(let _0x331e87=_0x276994;_0x331e87<_0x1de12d;_0x331e87++)this['_touched']['set'](_0x331e87,{'userId':_0x2cdca8});_0xb3d501['_insertChild'](_0x24cfba['offset'],_0x1072ea);}['_handleMoveOperation'](_0x5d7fb7){(_0x5d7fb7=this['_cloneOperation'](_0x5d7fb7,this['_idsRoots']))['_execute']();const _0x549a9b=null===_0x5d7fb7['_authorId']?null:_0x5d7fb7['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x2d05c4=_0x5d7fb7['getMovedRangeStart'](),_0x41f004=_0x2d05c4['parent'],_0x30d294=_0x2d05c4['offset'];!function _0x2a354e(_0x8be612,_0x350575,_0x758be,_0x55b0f2){for(let _0x40c556=_0x758be;_0x40c556<_0x55b0f2;_0x40c556++){const _0x1b6c92=_0x350575['getChild'](_0x40c556);_0x1b6c92['is']('element','$text')?_0x8be612['set'](_0x1b6c92['getAttribute']('vid'),{'userId':_0x549a9b}):(_0x8be612['set'](_0x1b6c92['getAttribute']('vid_start'),{'userId':_0x549a9b}),_0x2a354e(_0x8be612,_0x1b6c92,0x0,_0x1b6c92['childCount']),_0x8be612['set'](_0x1b6c92['getAttribute']('vid_end'),{'userId':_0x549a9b}));}}(this['_touched'],_0x41f004,_0x30d294,_0x30d294+_0x5d7fb7['howMany']);}['_handleMergeOperation'](_0x254d76){const _0xa75d57=null===(_0x254d76=this['_cloneOperation'](_0x254d76,this['_idsRoots']))['_authorId']?null:_0x254d76['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x5758ac=_0x254d76['targetPosition']['parent'],_0x48a879=_0x254d76['sourcePosition']['parent'],_0x4dcf2b=_0x5758ac['getAttribute']('vid_end'),_0x5275fa=_0x48a879['getAttribute']('vid_start');_0x5758ac['_setAttribute']('vid_end',_0x48a879['getAttribute']('vid_end')),_0x48a879['_setAttribute']('vid_end',_0x4dcf2b),this['_touched']['set'](_0x5275fa,{'userId':_0xa75d57}),this['_touched']['set'](_0x4dcf2b,{'userId':_0xa75d57}),_0x254d76['_execute']();}['_handleSplitOperation'](_0x103b37){const _0x5c3b32=null===(_0x103b37=this['_cloneOperation'](_0x103b37,this['_idsRoots']))['_authorId']?null:_0x103b37['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x4a5144=_0x103b37['graveyardPosition'],_0x50f4bb=_0x103b37['splitPosition']['parent'];_0x103b37['_execute']();const _0x2f060d=_0x50f4bb['getAttribute']('vid_end'),_0x5b4271=_0x103b37['insertionPosition']['nodeAfter'];if(_0x4a5144){const _0x3d2bbe=_0x5b4271['getAttribute']('vid_end'),_0x1f1872=_0x50f4bb['getAttribute']('vid_end');_0x50f4bb['_setAttribute']('vid_end',_0x3d2bbe),_0x5b4271['_setAttribute']('vid_end',_0x1f1872),this['_touched']['set'](_0x50f4bb['getAttribute']('vid_end'),{'userId':_0x5c3b32}),this['_touched']['set'](_0x5b4271['getAttribute']('vid_start'),{'userId':_0x5c3b32});}else{const _0x1eef73=this['_revisionId']++,_0x9b2d1c=this['_revisionId']++;_0x50f4bb['_setAttribute']('vid_end',_0x1eef73),_0x5b4271['_setAttribute']('vid_start',_0x9b2d1c),_0x5b4271['_setAttribute']('vid_end',_0x2f060d),this['_touched']['set'](_0x1eef73,{'userId':_0x5c3b32}),this['_touched']['set'](_0x9b2d1c,{'userId':_0x5c3b32});}}['_handleMarkerOperation'](_0xd61c78){if(!_0xd61c78['affectsData'])return;const _0x51d871=(_0xd61c78=this['_cloneOperation'](_0xd61c78,this['_diffRoots']))['oldRange']?_0xd61c78['oldRange']['root']:null,_0x462fe1=_0xd61c78['newRange']?_0xd61c78['newRange']['root']:null;_0x51d871&&this['_markers']['delete'](_0xd61c78['name']),_0x462fe1&&this['_markers']['set'](_0xd61c78['name'],_0xd61c78['newRange']['clone']());const _0x2a54cd=null===_0xd61c78['_authorId']?null:_0xd61c78['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x183af3=_0xd61c78['name'];if(!this['_touchedMarkers']['has'](_0x183af3))return void this['_touchedMarkers']['set'](_0x183af3,{'range':_0xd61c78['oldRange'],'userId':_0x2a54cd});const _0x4b9d8b=this['_touchedMarkers']['get'](_0x183af3),_0xbf032d=_0x4b9d8b['range'],_0x5009de=_0xd61c78['newRange'];null==_0xbf032d&&null==_0x5009de||_0xbf032d&&_0x5009de&&_0xbf032d['isEqual'](_0x5009de)?this['_touchedMarkers']['delete'](_0xd61c78['name']):_0x4b9d8b['userId']=_0x2a54cd;}['_handleRootOperation'](_0x1d3780,_0x46390e){this['_diffRoots']['has'](_0x1d3780['rootName'])?this['_diffRoots']['get'](_0x1d3780['rootName'])['_isAttached']=_0x1d3780['isAdd']:(this['_diffRoots']['set'](_0x1d3780['rootName'],N(_0x1d3780['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x1d3780['rootName'],{}),_0x46390e&&this['_idsRoots']['set'](_0x1d3780['rootName'],N(_0x1d3780['rootName'],!0x0)));const _0x2d514f=null===_0x1d3780['_authorId']?null:_0x1d3780['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x11b53e=this['_touchedRoots']['get'](_0x1d3780['rootName']);_0x11b53e&&_0x11b53e['userId']===_0x2d514f?this['_touchedRoots']['delete'](_0x1d3780['rootName']):this['_touchedRoots']['set'](_0x1d3780['rootName'],{'userId':_0x2d514f,'isAttached':_0x1d3780['isAdd']});}['_handleRootAttributeOperation'](_0x152729){const _0x867d63=this['_diffRootsAttributes']['get'](_0x152729['root']['rootName']);null===_0x152729['newValue']?delete _0x867d63[_0x152729['key']]:_0x867d63[_0x152729['key']]=_0x152729['newValue'];}}function x(_0x4637f8){const _0x3c06a4=N(_0x4637f8['rootName'],_0x4637f8['isAttached']());for(const _0x4f0799 of _0x4637f8['getChildren']()){const _0x320186=_0x4f0799['_clone'](!0x0);_0x3c06a4['_appendChild'](_0x320186);}return _0x3c06a4;}function N(_0x25890c,_0x4fe45f=!0x0){const _0x51bca7=new _0x1017e4();return _0x51bca7['rootName']=_0x25890c,_0x51bca7['_isAttached']=_0x4fe45f,_0x51bca7['isAttached']=()=>_0x51bca7['_isAttached'],_0x51bca7;}function P(_0x3b4da4,_0xd3acd,_0x426a53){const _0x23c43a='elementEnd'==_0x3b4da4['type']?_0x426a53['createPositionAt'](_0x3b4da4['item'],'end'):_0x426a53['createPositionBefore'](_0x3b4da4['item']);return _0x426a53['createPositionFromPath'](_0xd3acd,_0x23c43a['path'],_0x23c43a['stickiness']);}function V(_0x1c839e,_0x2b59c1,_0x513762){const _0x3c096='elementStart'==_0x1c839e['type']?_0x513762['createPositionAt'](_0x1c839e['item'],0x0):_0x513762['createPositionAfter'](_0x1c839e['item']);return _0x513762['createPositionFromPath'](_0x2b59c1,_0x3c096['path'],_0x3c096['stickiness']);}class me extends/* #__PURE__ -- @preserve */
25
+ _0x4930e8(_0x5372f9){['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x598ce3,_0x296857){super(_0x598ce3),this['focusTracker']=new _0x51224f(),this['keystrokes']=new _0x5ba12a(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x296857),this['setTemplate']({'tag':'form','attributes':{'class':['ck','ck-revision-history-save-revision-form','ck-responsive-form'],'tabindex':'-1'},'children':[this['revisionNameInputView']]}),this['initializeCssTransitionDisablerMixin']();}['render'](){super['render'](),_0x9dd0f8({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x161c48=_0x536625=>_0x536625['stopPropagation']();this['keystrokes']['set']('arrowright',_0x161c48),this['keystrokes']['set']('arrowleft',_0x161c48),this['keystrokes']['set']('arrowup',_0x161c48),this['keystrokes']['set']('arrowdown',_0x161c48);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x57278b){this['revisionNameInputView']['fieldView']['element']['value']=_0x57278b['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x7ce1ef){const _0x4120bd=new et(this['locale'],ti),_0x5efa53=_0x4120bd['fieldView'];_0x5efa53['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x342b91=R(this['locale'],'Name\x20of\x20the\x20revision');return!_0x7ce1ef&&(_0x342b91+='\x20('+R(this['locale'],'optional')+')'),(_0x4120bd['label']=_0x342b91,_0x5efa53['on']('input',()=>{this['revisionNameInputValue']=_0x5efa53['element']['value']['trim']();}),_0x4120bd);}}class v extends _0x40d69e{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h];}['_saveRevisionFormView'];['init'](){const _0x2b821f=this['editor'],_0x1d9569=_0x2b821f['plugins']['get']('RevisionTracker');_0x2b821f['ui']['componentFactory']['add']('revisionHistory',_0x285a46=>{const _0x3d9baa=_0x5bfde6(_0x285a46),_0x8e7077=_0x3d9baa['panelView']['children'],_0x41f0bc=new _0x41ec92(_0x285a46),_0x28ded3=new _0x22c231(_0x285a46),_0x51814a=new _0x4c294d(_0x285a46),_0x2dc229=new _0x22c231(_0x285a46),_0x1e5090=new _0x4c294d(_0x285a46);return _0x3d9baa['bind']('isEnabled')['to'](_0x1d9569,'isReady',_0x1d9569,'isEnabled',_0x2b821f,'isReadOnly',(_0x25dd6f,_0x3271d8,_0x554d02)=>_0x25dd6f&&_0x3271d8&&!_0x554d02),_0x3d9baa['buttonView']['set']({'icon':_0x5a259c,'label':R(_0x285a46,'Revision\x20history'),'tooltip':!0x0}),_0x51814a['set']({'label':R(_0x285a46,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x51814a['bind']('isEnabled')['to'](_0x1d9569,'isReady',_0x1d9569,'isEnabled',_0x2b821f,'isReadOnly',(_0x2239a7,_0x327015,_0x482960)=>_0x2239a7&&_0x327015&&!_0x482960),_0x51814a['on']('execute',()=>this['_showDialog']()),_0x1e5090['set']({'label':R(_0x285a46,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x1e5090['bind']('isEnabled')['to'](_0x1d9569,'isReady',_0x2b821f,'isReadOnly',(_0x3ff1d2,_0x5a98b0)=>_0x3ff1d2&&!_0x5a98b0),_0x1e5090['on']('execute',()=>{_0x2b821f['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x3d9baa['isOpen']=!0x1,_0x2b821f['editing']['view']['focus']();}),_0x28ded3['children']['add'](_0x51814a),_0x2dc229['children']['add'](_0x1e5090),_0x41f0bc['role']='menu',_0x41f0bc['items']['addMany']([_0x28ded3,_0x2dc229]),_0x8e7077['add'](_0x41f0bc),_0x3d9baa;}),_0x2b821f['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x48578a=this['editor'],_0x461126=_0x48578a['locale'],_0x98b8d2=new _0x518481(_0x461126),_0x4ea201=new _0x1ec7f2(_0x461126);_0x98b8d2['buttonView']['set']({'icon':_0x5a259c,'label':R(_0x461126,'Revision\x20history')});const _0x1b6fc1=new _0x3e0b15(_0x461126,_0x98b8d2),_0x220860=new _0x398d58(_0x461126);_0x220860['set']({'label':R(_0x461126,'Save\x20current\x20revision')}),_0x220860['delegate']('execute')['to'](_0x98b8d2),_0x220860['on']('execute',()=>{this['_showDialog']();}),_0x1b6fc1['children']['add'](_0x220860),_0x4ea201['items']['add'](_0x1b6fc1);const _0x1c0326=new _0x3e0b15(_0x461126,_0x98b8d2),_0x1d56b8=new _0x398d58(_0x461126);return _0x1d56b8['set']({'label':R(_0x461126,'Open\x20revision\x20history')}),_0x1d56b8['delegate']('execute')['to'](_0x98b8d2),_0x1d56b8['on']('execute',()=>{_0x48578a['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x1c0326['children']['add'](_0x1d56b8),_0x4ea201['items']['add'](_0x1c0326),_0x98b8d2['panelView']['children']['add'](_0x4ea201),_0x98b8d2;}['_showDialog'](){const _0x2e5931=this['editor'],_0x31d6c3=_0x2e5931['locale'],_0x4e9501=_0x2e5931['plugins']['get']('Dialog'),_0x5dc3c6=_0x2e5931['plugins']['get']('RevisionTracker');function _0x4c9f92(_0x7b0a01){_0x2e5931['config']['get']('revisionHistory.requireRevisionName')&&''===_0x7b0a01['revisionName']?_0x7b0a01['revisionNameInputView']['errorText']=R(_0x31d6c3,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x2e5931['plugins']['get'](h)['saveRevision']({'name':_0x7b0a01['revisionName']}),_0x4e9501['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x4c9f92(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x4e9501['show']({'id':'revisionSave','title':R(_0x31d6c3,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':R(_0x2e5931['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x4e9501['hide']()},{'label':R(_0x2e5931['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x14ab7f){_0x14ab7f['bind']('isEnabled')['to'](_0x5dc3c6,'isReady',_0x5dc3c6,'isEnabled',_0x2e5931,'isReadOnly',(_0x240ed,_0x5b63c5,_0xb6a11e)=>_0x240ed&&_0x5b63c5&&!_0xb6a11e);},'onExecute':()=>_0x4c9f92(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x269312=this['editor'],_0x22f407=_0x269312['locale'];this['_saveRevisionFormView']=new me(_0x22f407,_0x269312['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class z extends _0x5372f9{['changeId'];['_model'];constructor(_0x1dbf64,_0x19e269){super(_0x1dbf64),this['_model']=_0x19e269,this['changeId']=_0x19e269['id'];const _0x3baa70=this['bindTemplate'],_0x3a0f90=R(_0x1dbf64,_0x19e269['data']['isSuggestion']?'Suggested\x20by':'add'==_0x19e269['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x19e269['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x3baa70['to']('type',_0x5ec650=>'ck-revision-change__'+_0x5ec650)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x3a0f90}]},{'text':'\x20'+_0x19e269['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class G extends/* #__PURE__ -- @preserve */
26
+ _0x220e5e(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x1127bf){super(),this['id']=_0x1127bf['id']||_0x58edc7(),this['author']=_0x1127bf['author'],this['type']=_0x1127bf['type'],this['data']=_0x1127bf['data']||{},this['rootName']=_0x1127bf['rootName'],this['set']('createdAt',_0x1127bf['createdAt']);}['toJSON'](){return{'id':this['id'],'authorId':this['author']['id'],'type':this['type'],'data':this['data'],'createdAt':this['createdAt']};}}class J{['newRevisionId'];['oldRevisionId'];['changes'];constructor(_0x468761,_0x33e416){this['newRevisionId']=_0x468761,this['oldRevisionId']=_0x33e416,this['changes']=new _0xbf5b7e();}['_setChanges'](_0x53135a){for(const _0x387a0f of _0x53135a)this['changes']['add'](_0x387a0f);}}class l extends _0x40d69e{['repository'];['adapter']=null;['_utils'];['_activeViewTarget'];['_changeView'];['_changeIdToChange'];['_balloon'];static get['pluginName'](){return'RevisionViewer';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[_0x31b528,_0x59aed6,S,$];}constructor(_0x3ac1a1){super(_0x3ac1a1),this['repository']=this['editor']['plugins']['get']('RevisionsRepository'),this['_utils']=this['editor']['plugins']['get']('RevisionHistoryUtils'),this['set']('activeChange',null),this['set']('activeView',null),this['_activeViewTarget']=null,this['set']('diff',null),this['set']('isReady',!0x1),this['set']('isEnabled',!0x0),this['on']('change:isEnabled',(_0x36bbc7,_0x36ee89,_0x297e5c)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0xb97cd=>{for(const _0x40f990 of this['editor']['editing']['view']['document']['roots'])_0x297e5c?_0xb97cd['removeClass']('ck-editor__editable__overlay',_0x40f990):_0xb97cd['addClass']('ck-editor__editable__overlay',_0x40f990);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x5a85e3=>null!==_0x5a85e3),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x20b5c3,_0x483e13,_0x71f366)=>_0x20b5c3&&_0x71f366?_0x483e13['changes']['getIndex'](_0x71f366):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x27f2f3,_0x1b1330)=>_0x27f2f3?_0x1b1330['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0x59aed6);}['init'](){const _0x166da8=this['editor'],_0x389ab0=new rt(_0x166da8,{'direction':'backward'}),_0x1e7b45=new rt(_0x166da8,{'direction':'forward'});(_0x166da8['commands']['add']('showPreviousChange',_0x389ab0),_0x166da8['commands']['add']('showNextChange',_0x1e7b45),_0x166da8['commands']['add']('restoreRevision',new nt(_0x166da8)),this['on']('change:numberOfChanges',()=>{_0x389ab0['refresh'](),_0x1e7b45['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x166da8['enableReadOnlyMode']('revision-viewer'),_0x166da8['plugins']['has']('WidgetToolbarRepository'))&&_0x166da8['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x3eb461){return await this['_utils']['loadRevisionData'](_0x3eb461,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x3eb461);}async['getRevisionRootsAttributes'](_0x4e50ad){return await this['_utils']['loadRevisionData'](_0x4e50ad,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x4e50ad);}async['compare'](_0x1cd41f,_0x3211ac,_0x5a7476=!0x1){if(!this['isEnabled'])return;const _0x1b8a9e=this['diff'],_0xc2e6e3=this['repository'],_0x5080fb='string'==typeof _0x1cd41f?_0xc2e6e3['getRevision'](_0x1cd41f):_0x1cd41f,_0x20f889='string'==typeof _0x3211ac?_0xc2e6e3['getRevision'](_0x3211ac):_0x3211ac,_0x263340=_0x5080fb['id'],_0x526a7a=_0x20f889?_0x20f889['id']:null;if(!_0x5a7476&&this['diff']&&this['diff']['newRevisionId']===_0x263340&&this['diff']['oldRevisionId']===_0x526a7a)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new J(_0x263340,_0x526a7a);const _0x5cb0d8=this['_getRevisionsRange'](_0x5080fb,_0x20f889,!0x0)['map'](_0x5ec572=>this['_utils']['loadRevisionData'](_0x5ec572,this['adapter']));return _0x5cb0d8['push'](new Promise(_0x1a8dec=>{setTimeout(_0x1a8dec,0x14);})),Promise['all'](_0x5cb0d8)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x5755fe=this['_getDiff'](_0x263340,_0x526a7a);for(const _0x570c37 of _0x5755fe['changes'])this['_changeIdToChange']['set'](_0x570c37['id'],_0x570c37);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0xefd549=>{for(const _0x5874a8 of this['editor']['model']['document']['getRootNames']())_0xefd549['detachRoot'](_0x5874a8);for(const _0x50d1a4 of Object['keys'](_0x5755fe['model'])){const _0x1cce80=_0xefd549['addRoot'](_0x50d1a4);for(const _0x59727e of Object['keys'](_0x5755fe['attributes'][_0x50d1a4]))_0xefd549['setAttribute'](_0x59727e,_0x5755fe['attributes'][_0x50d1a4][_0x59727e],_0x1cce80);_0xefd549['insert'](_0x5755fe['model'][_0x50d1a4],_0x1cce80,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x5755fe['changes'])),this['isReady']=!0x0;})['catch'](_0xf88c2b=>{console['error'](_0xf88c2b),this['_cleanUp'](),_0x1b8a9e&&(this['diff']=_0x1b8a9e),this['isReady']=!0x0;});}['addRevisionData'](_0x33f836,_0x13e1b9){const _0x188e0d=this['repository']['createRevision'](_0x33f836);return _0x188e0d['on']('_update',(_0x13620b,_0x2de32f,_0x451bbb)=>_0x13e1b9(_0x2de32f,_0x451bbb,_0x188e0d)),this['repository']['addRevision'](_0x188e0d),_0x188e0d;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x285e47=>{for(const _0x2872aa of this['editor']['model']['document']['getRootNames']())_0x285e47['detachRoot'](_0x2872aa);});}['_sortAndFilterDiffChanges'](_0x286fc2){const _0x4d0741=[],_0x276679=new Map();for(const _0x5b7a34 of this['editor']['model']['document']['getRootNames']()){const _0x3c55e5=this['editor']['editing']['view']['getDomRoot'](_0x5b7a34);if(!_0x3c55e5)continue;const _0x3cbe10=_0x3c55e5['getClientRects']()['item'](0x0);_0x3cbe10&&(_0x4d0741['push'](_0x5b7a34),_0x276679['set'](_0x5b7a34,_0x3cbe10));}return _0x4d0741['sort']((_0x2dc65f,_0x507d84)=>{const _0x2e75dd=_0x276679['get'](_0x2dc65f),_0x2b9bf1=_0x276679['get'](_0x507d84);return _0x2e75dd['y']-_0x2b9bf1['y']||_0x2e75dd['x']-_0x2b9bf1['x'];}),(_0x286fc2=_0x286fc2['filter'](_0x4a6895=>_0x4d0741['includes'](_0x4a6895['rootName'])))['sort']((_0x4efa69,_0x577a61)=>_0x4d0741['indexOf'](_0x4efa69['rootName'])-_0x4d0741['indexOf'](_0x577a61['rootName'])),_0x286fc2;}['_makeTape'](_0x40a1d3){const _0x2ca36c=Array['from'](_0x40a1d3['markers'])['filter'](([_0x5bc186,_0x56b842])=>_0x5bc186['startsWith']('revision:')&&!_0x56b842['isCollapsed']),_0x1769f7=Array['from'](this['editor']['model']['createRangeIn'](_0x40a1d3)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x2ca36c['length'])for(const _0x4d9179 of _0x1769f7){const [_0x2cc2cf,_0x1e5139]=_0x2ca36c[0x0],[,_0x2a13ae,_0x38f9b8]=_0x2cc2cf['split'](':');if(_0x1e5139['end']['isEqual'](_0x4d9179['nextPosition'])&&_0x2ca36c['shift'](),(_0x4d9179['previousPosition']['isEqual'](_0x1e5139['start'])||_0x4d9179['previousPosition']['isAfter'](_0x1e5139['start']))&&('insertion'==_0x2a13ae?_0x4d9179['isAdded']={'userId':_0x38f9b8}:'deletion'==_0x2a13ae&&(_0x4d9179['isRemoved']={'userId':_0x38f9b8})),0x0==_0x2ca36c['length'])break;}return _0x1769f7;}['_refreshStartEndIndex'](_0x60ad5d){const _0x3555d2=new Map();for(let _0x4bcf00=0x0;_0x4bcf00<_0x60ad5d['length'];_0x4bcf00++)'text'===_0x60ad5d[_0x4bcf00]['type']?(_0x60ad5d[_0x4bcf00]['item']['startIndex']=_0x4bcf00,_0x60ad5d[_0x4bcf00]['item']['endIndex']=_0x4bcf00):('elementStart'===_0x60ad5d[_0x4bcf00]['type']?_0x60ad5d[_0x4bcf00]['item']['startIndex']=_0x4bcf00:'elementEnd'===_0x60ad5d[_0x4bcf00]['type']&&(_0x60ad5d[_0x4bcf00]['item']['endIndex']=_0x4bcf00),_0x3555d2['set'](_0x60ad5d[_0x4bcf00]['id'],_0x4bcf00));for(const _0x2d3c4c of _0x3555d2['values']())'elementStart'===_0x60ad5d[_0x2d3c4c]['type']?_0x60ad5d[_0x2d3c4c]['item']['endIndex']=_0x3555d2['get'](_0x60ad5d[_0x2d3c4c]['pairId']):'elementEnd'===_0x60ad5d[_0x2d3c4c]['type']&&(_0x60ad5d[_0x2d3c4c]['item']['startIndex']=_0x3555d2['get'](_0x60ad5d[_0x2d3c4c]['pairId']));}['_processTape'](_0x4bf293){for(let _0x24a94f=0x0;_0x24a94f<_0x4bf293['length'];_0x24a94f++){if('elementStart'===_0x4bf293[_0x24a94f]['type'])_0x4bf293[_0x24a94f]['item']['startIndex']=_0x24a94f;else{if('elementEnd'===_0x4bf293[_0x24a94f]['type']){_0x4bf293[_0x24a94f]['item']['endIndex']=_0x24a94f;const _0x1fdf96=_0x4bf293[_0x24a94f]['item']['startIndex'];_0x4bf293[_0x1fdf96]['pairId']=_0x4bf293[_0x24a94f]['id'],_0x4bf293[_0x24a94f]['pairId']=_0x4bf293[_0x1fdf96]['id'];}else _0x4bf293[_0x24a94f]['item']['startIndex']=_0x24a94f,_0x4bf293[_0x24a94f]['item']['endIndex']=_0x24a94f,_0x4bf293[_0x24a94f]['pairId']=null;}_0x4bf293[_0x24a94f]['markersStart']||(_0x4bf293[_0x24a94f]['markersStart']=[],_0x4bf293[_0x24a94f]['markersEnd']=[]);}}['_markInsertions'](_0x399bf8,_0x30737a){const _0x244a8d=_0x399bf8['filter'](_0x29087f=>!_0x29087f['isAdded']);for(let _0x365ffc=0x0;_0x365ffc<_0x30737a['length'];_0x365ffc++)_0x30737a[_0x365ffc]['isAdded']&&(_0x244a8d[_0x365ffc]['isAdded']=_0x30737a[_0x365ffc]['isAdded']);}['_getDiff'](_0x20e1d8,_0x288694=null){const _0x5306fe=this['repository']['getRevision'](_0x20e1d8),_0x187d35=_0x288694?this['repository']['getRevision'](_0x288694):null,_0x45f04b=this['_getRevisionsRange'](_0x5306fe,_0x187d35),_0x5e275c=_0x45f04b[_0x45f04b['length']-0x1],_0x25a9e0=new Map(),_0x1eac78={'model':{},'attributes':{},'changes':[]},_0xc261ff=new Set(),_0x8bafff=new Map();for(let _0x5aaf58=_0x45f04b['length']-0x1;_0x5aaf58>=0x0;_0x5aaf58--){const _0x6c171c=_0x45f04b[_0x5aaf58];for(const _0x203354 of Object['keys'](_0x6c171c['diffData']))if(_0x6c171c['diffData'][_0x203354]['attachChange']){const _0x3a5c07=_0x6c171c['diffData'][_0x203354]['attachChange'];_0x3a5c07['isAttached']?(_0xc261ff['add'](_0x203354),_0x8bafff['has'](_0x203354)&&_0x8bafff['get'](_0x203354)['userId']==_0x3a5c07['userId']?_0x8bafff['delete'](_0x203354):_0x8bafff['set'](_0x203354,_0x3a5c07)):_0x8bafff['has'](_0x203354)?(_0xc261ff['delete'](_0x203354),_0x8bafff['delete'](_0x203354)):(_0xc261ff['add'](_0x203354),_0x8bafff['set'](_0x203354,_0x3a5c07));}else _0xc261ff['add'](_0x203354);}for(const _0xcf8775 of _0xc261ff){const _0x55843e=_0x8bafff['has'](_0xcf8775)&&!_0x8bafff['get'](_0xcf8775)['isAttached'];let _0x3e417c=_0x55843e?_0x45f04b['length']-0x1:0x0;const _0x3bdf8d=_0x55843e?-0x1:0x1;for(;_0x45f04b[_0x3e417c];){const _0x260dc0=_0x45f04b[_0x3e417c];if(_0x260dc0['diffData'][_0xcf8775]){const _0x28aacc=_0x55843e?_0x260dc0['diffData'][_0xcf8775]['attributesBefore']:_0x260dc0['diffData'][_0xcf8775]['attributesAfter'];_0x1eac78['attributes'][_0xcf8775]=_0x28aacc?_0x570b2f(_0x28aacc):{};break;}_0x3e417c+=_0x3bdf8d;}}for(const _0x2affc6 of _0x45f04b){_0x2affc6['model']={};for(const _0x4e6eb8 of _0x2affc6['authors'])_0x25a9e0['set'](_0x4e6eb8['id'],_0x4e6eb8);for(const _0x2e21a1 of _0xc261ff){const _0xf0e9f=_0x2affc6['diffData'][_0x2e21a1]?_0x2affc6['diffData'][_0x2e21a1]['insertions']:'[]',_0x5b408e=_0x2affc6['diffData'][_0x2e21a1]?_0x2affc6['diffData'][_0x2e21a1]['deletions']:'[]';_0x2affc6['model'][_0x2e21a1]={'insertions':this['_utils']['_makeModelFromViewString'](_0xf0e9f),'deletions':this['_utils']['_makeModelFromViewString'](_0x5b408e)};}}for(const _0x2e7111 of _0xc261ff){let _0x437725=null,_0x27a3c6=0x0;const _0x1f1b97=new Map(Array['from'](_0x5306fe['model'][_0x2e7111]['insertions']['markers'])['filter'](([_0x551a40])=>!_0x551a40['startsWith']('revision:')));let _0x222920=0x0;for(const _0x299b1e of _0x45f04b){const _0x16b463=this['_makeTape'](_0x299b1e['model'][_0x2e7111]['insertions']);_0x299b1e==_0x5306fe?(_0x437725=_0x16b463,_0x27a3c6=_0x437725['length'],_0x437725['forEach'](_0x462acc=>{_0x462acc['id']=_0x222920++;}),this['_processTape'](_0x437725)):this['_markInsertions'](_0x437725,_0x16b463);const _0x50d3bc=_0x437725['filter'](_0x3595a0=>!_0x3595a0['isAdded'])['map'](_0xeaf72a=>_0xeaf72a['id']);let _0x5a7912=0x0;const _0x566a92=this['_makeTape'](_0x299b1e['model'][_0x2e7111]['deletions']);_0x566a92['forEach'](_0x308e3b=>{_0x308e3b['isRemoved']?_0x308e3b['id']=_0x27a3c6++:_0x308e3b['id']=_0x50d3bc[_0x5a7912++];}),this['_processTape'](_0x566a92),this['_setDistance'](_0x437725,'isAdded'),this['_setDistance'](_0x566a92,'isRemoved'),_0x299b1e==_0x5306fe&&this['_markMarkers'](_0x437725,_0x1f1b97),_0x437725=this['_joinTapes'](_0x437725,_0x566a92),this['_refreshStartEndIndex'](_0x437725),this['_setDistance'](_0x437725,'isRemoved');}_0x437725=_0x437725['filter'](_0x35b30d=>!(_0x35b30d['isAdded']&&_0x35b30d['isRemoved']));const _0x53557b=new Map(_0x5e275c['model'][_0x2e7111]['deletions']['markers']),_0x4cdf95=new Set(_0x1f1b97['keys']());for(const _0x1ce28f of _0x53557b['keys']())_0x4cdf95['delete'](_0x1ce28f);this['_markSuggestions'](_0x437725,_0x4cdf95),this['_fixObsoleteTags'](_0x437725),_0x437725=this['_removeMissingPairs'](_0x437725),_0x437725=this['_markMismatchedRemovedTags'](_0x437725),_0x437725=this['_removeUnsupportedChanges'](_0x437725);const {root:_0x468721,changes:_0x70f9ad}=this['_makeModelFromTape'](_0x437725,_0x25a9e0,_0x2e7111);_0x1eac78['model'][_0x2e7111]=_0x468721;const _0x5725d2=_0x8bafff['get'](_0x2e7111);if(_0x5725d2){const _0x29db4f=_0x25a9e0['get'](_0x5725d2['userId']),_0x310f07=new G({'author':_0x29db4f,'type':_0x5725d2['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x2e7111});_0x70f9ad['unshift'](_0x310f07),_0x1eac78['attributes'][_0x2e7111]['revisionHistoryAttachChange']=_0x310f07['id'];}_0x1eac78['changes']=_0x1eac78['changes']['concat'](_0x70f9ad);}return _0x1eac78;}['_markMarkers'](_0x2e5ecb,_0x2d5366){for(let _0x31849b=0x0;_0x31849b<_0x2e5ecb['length'];_0x31849b++)for(const [_0x10ba70,_0x4060d9]of _0x2d5366)!_0x4060d9['isCollapsed']&&_0x4060d9['start']['isEqual'](_0x2e5ecb[_0x31849b]['previousPosition'])&&_0x2e5ecb[_0x31849b]['markersStart']['push'](_0x10ba70),_0x4060d9['end']['isEqual'](_0x2e5ecb[_0x31849b]['nextPosition'])&&_0x2e5ecb[_0x31849b]['markersEnd']['push'](_0x10ba70);}['_joinTapes'](_0x13c589,_0x4d830a){let _0x242b91=[],_0x4203bd=0x0,_0x3b0e85=0x0;for(;_0x4203bd<_0x13c589['length']||_0x3b0e85<_0x4d830a['length'];){const _0x584ca8=_0x13c589[_0x4203bd]||{},_0x835fee=_0x4d830a[_0x3b0e85]||{};if(_0x584ca8['id']==_0x835fee['id'])_0x4203bd++,_0x3b0e85++,_0x242b91['push'](_0x584ca8);else{if(_0x835fee['isRemoved']&&_0x584ca8['isAdded']){const {commonTape:_0x499d38,iEnd:_0x2dcae4,jEnd:_0x304010}=this['_threeWayMerge'](_0x13c589,_0x4203bd,_0x4d830a,_0x3b0e85);_0x242b91=_0x242b91['concat'](_0x499d38),_0x4203bd=_0x2dcae4,_0x3b0e85=_0x304010;}else _0x835fee['isRemoved']?(_0x3b0e85++,_0x242b91['push'](_0x835fee)):(_0x4203bd++,_0x242b91['push'](_0x584ca8));}}return _0x242b91;}['_markSuggestions'](_0x5be4e5,_0x4975d4){const _0x3fcc35=[];for(let _0x1dbcaa=0x0;_0x1dbcaa<_0x5be4e5['length'];_0x1dbcaa++){for(let _0x1bed65=0x0;_0x1bed65<_0x5be4e5[_0x1dbcaa]['markersStart']['length'];_0x1bed65++){const _0x52a43c=_0x5be4e5[_0x1dbcaa]['markersStart'][_0x1bed65];if(!_0x4975d4['has'](_0x52a43c))continue;const {group:_0x277925,type:_0x5e5508,authorId:_0x463433}=_0x168966(_0x52a43c);'revision-suggestion'!=_0x277925||'insertion'!=_0x5e5508&&'deletion'!=_0x5e5508||(_0x3fcc35['unshift']({'type':_0x5e5508,'name':_0x52a43c,'userId':_0x463433}),_0x5be4e5[_0x1dbcaa]['markersStart']['splice'](_0x1bed65,0x1),_0x1bed65--);}_0xef28b4(_0x5be4e5[_0x1dbcaa]);for(let _0x32f088=0x0;_0x32f088<_0x5be4e5[_0x1dbcaa]['markersEnd']['length'];_0x32f088++){const _0x1e406b=_0x5be4e5[_0x1dbcaa]['markersEnd'][_0x32f088];if(!_0x4975d4['has'](_0x1e406b))continue;const {group:_0x4ddc98,type:_0x2db2d8}=_0x168966(_0x1e406b);if('revision-suggestion'!=_0x4ddc98||'insertion'!=_0x2db2d8&&'deletion'!=_0x2db2d8)continue;_0x5be4e5[_0x1dbcaa]['markersEnd']['splice'](_0x32f088,0x1),_0x32f088--;const _0x1cb954=_0x3fcc35['findIndex'](_0x25f3e4=>_0x25f3e4['name']==_0x1e406b);_0x1cb954>-0x1&&_0x3fcc35['splice'](_0x1cb954,0x1);}}function _0x168966(_0x585cfc){const _0x21501d=_0x585cfc['split'](':');return{'group':_0x21501d[0x0],'type':_0x21501d[0x1],'subType':_0x21501d['length']>=0x5?_0x21501d[0x2]:null,'id':_0x21501d['length']<0x5?_0x21501d[0x2]:_0x21501d[0x3],'authorId':_0x21501d['length']<0x5?_0x21501d[0x3]:_0x21501d[0x4],'markerCount':0x6==_0x21501d['length']?_0x21501d[0x5]:null};}function _0xef28b4(_0x3b76d8){for(let _0x4e5334=0x0;_0x4e5334<_0x3fcc35['length'];_0x4e5334++){if(_0x3b76d8['isAdded']&&'insertion'==_0x3fcc35[_0x4e5334]['type']&&_0x3b76d8['isAdded']['userId']==_0x3fcc35[_0x4e5334]['userId'])return _0x3b76d8['isAddSuggestion']=_0x3fcc35[_0x4e5334],void delete _0x3b76d8['isAdded'];if(!_0x3b76d8['isAdded']&&!_0x3b76d8['isRemoved']&&'deletion'==_0x3fcc35[_0x4e5334]['type'])return void(_0x3b76d8['isRemoveSuggestion']=_0x3fcc35[_0x4e5334]);}}}['_setDistance'](_0x260842,_0x4105e6){let _0x4a2a2a=0x0,_0x10eb5f=!0x1;const _0x942084=new Map();for(const _0x5ed210 of _0x260842)_0x5ed210[_0x4105e6]?_0x10eb5f&&(_0x4a2a2a++,_0x10eb5f=!0x1):(_0x4a2a2a++,_0x10eb5f=!0x0),_0x942084['set'](_0x5ed210['id'],_0x4a2a2a);for(let _0x1ea5f7=0x0;_0x1ea5f7<_0x260842['length'];_0x1ea5f7++){if('isRemoved'==_0x4105e6&&_0x260842[_0x1ea5f7]['isAdded']||'isAdded'==_0x4105e6&&_0x260842[_0x1ea5f7]['isRemoved'])continue;if('text'==_0x260842[_0x1ea5f7]['type']){_0x260842[_0x1ea5f7]['distance']=0x0;continue;}const _0x208656=_0x942084['get'](_0x260842[_0x1ea5f7]['pairId']),_0x5232ae=_0x942084['get'](_0x260842[_0x1ea5f7]['id']);_0x260842[_0x1ea5f7]['distance']=_0x208656-_0x5232ae;}}['_getRevisionsRange'](_0x136651,_0x562ef8,_0xfbf697=!0x1){const _0x43a889=[];let _0x4b4f6c=this['repository']['getIndex'](_0x136651),_0x26683a=this['repository']['getIndex'](_0x562ef8);for(-0x1==_0x26683a&&(_0x26683a=this['repository']['_revisions']['length'],_0xfbf697=!0x1);_0x4b4f6c<_0x26683a;)_0x43a889['push'](this['repository']['getRevision'](_0x4b4f6c)),_0x4b4f6c++;return _0xfbf697&&_0x43a889['push'](this['repository']['getRevision'](_0x4b4f6c)),_0x43a889;}['_threeWayMerge'](_0x1c6b86,_0x44b8af,_0x1cad40,_0x1b193b){const _0x40b57c=this['editor']['model']['schema'];let _0x3765db=_0x44b8af;for(;_0x1c6b86[_0x3765db]&&_0x1c6b86[_0x3765db]['isAdded'];)_0x3765db++;let _0xddd89e=_0x1b193b;for(;_0x1cad40[_0xddd89e]&&_0x1cad40[_0xddd89e]['isRemoved'];)_0xddd89e++;_0x379fcc(_0x1c6b86,_0x44b8af,_0x3765db),_0x379fcc(_0x1cad40,_0x1b193b,_0xddd89e);const _0xddcd30=_0x1cad40['slice'](_0x1b193b,_0xddd89e)['concat'](_0x1c6b86['slice'](_0x44b8af,_0x3765db));return _0xddcd30['sort']((_0x598038,_0x3c12a5)=>_0x598038['side']!=_0x3c12a5['side']?_0x598038['side']-_0x3c12a5['side']:_0x598038['level']!=_0x3c12a5['level']?_0x598038['level']-_0x3c12a5['level']:_0x598038['distance']!=_0x3c12a5['distance']?_0x3c12a5['distance']-_0x598038['distance']:!!_0x598038['isAdded']!=!!_0x3c12a5['isAdded']?-0x1==_0x598038['side']||0x0==_0x598038['side']?_0x598038['isAdded']?-0x1:0x1:_0x598038['isAdded']?0x1:-0x1:_0x598038['index']-_0x3c12a5['index']),{'commonTape':_0xddcd30,'iEnd':_0x3765db,'jEnd':_0xddd89e};function _0x379fcc(_0x482e8d,_0x497441,_0x42e281){let _0x53ca68=-0x1,_0x3fb738=Number['POSITIVE_INFINITY'],_0x4f6825=!0x0;for(let _0x5b688f=_0x497441;_0x5b688f<_0x42e281;_0x5b688f++)if(_0x40b57c['isInline'](_0x482e8d[_0x5b688f]['item'])||(_0x4f6825=!0x1),_0x482e8d[_0x5b688f]['item']['startIndex']<_0x497441&&(_0x53ca68=_0x5b688f),_0x482e8d[_0x5b688f]['item']['endIndex']>=_0x42e281){_0x3fb738=_0x5b688f;break;}_0x4f6825&&(_0x53ca68=_0x42e281-0x1);for(let _0x7b62fa=_0x497441;_0x7b62fa<_0x42e281;_0x7b62fa++)_0x482e8d[_0x7b62fa]['side']=_0x7b62fa<=_0x53ca68?-0x1:_0x7b62fa<_0x3fb738?0x0:0x1,_0x482e8d[_0x7b62fa]['index']=_0x7b62fa;let _0x4d996c=0x0;for(let _0x342b6c=_0x497441;_0x342b6c<=_0x53ca68;_0x342b6c++)0x0==_0x482e8d[_0x342b6c]['distance']?_0x482e8d[_0x342b6c]['level']=_0x4d996c:(_0x4d996c++,_0x482e8d[_0x342b6c]['level']=_0x4d996c,_0x4d996c++);for(let _0x2c6f3b=_0x497441;_0x2c6f3b<_0x42e281;_0x2c6f3b++)0x0==_0x482e8d[_0x2c6f3b]['side']&&(_0x482e8d[_0x2c6f3b]['level']=_0x4d996c);_0x4d996c=0x0;for(let _0x3ebaec=_0x42e281-0x1;_0x3ebaec>=_0x3fb738;_0x3ebaec--)0x0==_0x482e8d[_0x3ebaec]['distance']?_0x482e8d[_0x3ebaec]['level']=_0x4d996c:(_0x4d996c--,_0x482e8d[_0x3ebaec]['level']=_0x4d996c,_0x4d996c--);}}['_fixObsoleteTags'](_0x3f6ef6){const _0x1398fd=new Map(),_0x33412f=this['editor']['model']['schema'];for(let _0x58e27f=0x1;_0x58e27f<_0x3f6ef6['length'];_0x58e27f++){let _0x262313,_0x19ca8c,_0x269fd6;const _0x72dbef=_0x3f6ef6[_0x58e27f],_0x58ef48=_0x3f6ef6[_0x58e27f-0x1];if('text'==_0x72dbef['type'])continue;if(_0x72dbef['type']!=_0x58ef48['type'])continue;if(!_0x33412f['isBlock'](_0x58ef48['item'])||_0x33412f['isLimit'](_0x58ef48['item']))continue;if(!_0x33412f['isBlock'](_0x72dbef['item'])||_0x33412f['isLimit'](_0x72dbef['item']))continue;if((_0x3f6ef6[_0x58e27f]['isAdded']||_0x3f6ef6[_0x58e27f]['isAddSuggestion'])&&_0x3f6ef6[_0x58e27f-0x1]['isRemoved'])_0x262313=_0x3f6ef6[_0x58e27f],_0x19ca8c=_0x3f6ef6[_0x58e27f-0x1],_0x269fd6=_0x58e27f-0x1;else{if(!_0x3f6ef6[_0x58e27f]['isRemoved']||!_0x3f6ef6[_0x58e27f-0x1]['isAdded']&&!_0x3f6ef6[_0x58e27f-0x1]['isAddSuggestion'])continue;_0x262313=_0x3f6ef6[_0x58e27f-0x1],_0x19ca8c=_0x3f6ef6[_0x58e27f],_0x269fd6=_0x58e27f;}const _0x30f530=_0x262313['level']==_0x19ca8c['level'],_0x47dc5d=Math['abs'](_0x262313['level'])<Math['abs'](_0x19ca8c['level'])&&0x0==_0x19ca8c['distance'];(_0x30f530||_0x47dc5d)&&(_0x1398fd['set'](_0x19ca8c['id'],_0x262313['id']),_0x3f6ef6['splice'](_0x269fd6,0x1),_0x58e27f--,_0x262313['isAdded']=!0x1);}for(let _0x5ebf59=0x0;_0x5ebf59<_0x3f6ef6['length'];_0x5ebf59++)_0x1398fd['has'](_0x3f6ef6[_0x5ebf59]['pairId'])&&(_0x3f6ef6[_0x5ebf59]['pairId']=_0x1398fd['get'](_0x3f6ef6[_0x5ebf59]['pairId']));}['_removeMissingPairs'](_0x4c50e5){const _0x440c16=new Set(_0x4c50e5['map'](_0x1afb01=>_0x1afb01['id']));for(let _0x12c73c=0x0;_0x12c73c<_0x4c50e5['length'];_0x12c73c++)_0x440c16['has'](_0x4c50e5[_0x12c73c]['pairId'])||0x0==_0x4c50e5[_0x12c73c]['distance']||(_0x4c50e5[_0x12c73c]['isIncorrect']=!0x0);return _0x4c50e5['filter'](_0x1779df=>!_0x1779df['isIncorrect']);}['_markMismatchedRemovedTags'](_0x586172){const _0x51fc22=new Set();for(let _0x19ee99=0x0;_0x19ee99<_0x586172['length'];_0x19ee99++){if(_0x51fc22['has'](_0x586172[_0x19ee99]['id'])&&_0x586172[_0x19ee99]['isRemoved']&&(_0x586172[_0x19ee99]['isIncorrect']=!0x0),_0x586172[_0x19ee99]['isIncorrect'])continue;if(0x0==_0x586172[_0x19ee99]['distance'])continue;if('elementStart'!=_0x586172[_0x19ee99]['type'])continue;if(null==_0x586172[_0x19ee99]['pairId'])continue;let _0x2977f5=_0x19ee99+0x1,_0x3c0de8=0x0;for(;_0x586172[_0x2977f5]['id']!=_0x586172[_0x19ee99]['pairId'];)'elementStart'==_0x586172[_0x2977f5]['type']?_0x3c0de8++:'elementEnd'==_0x586172[_0x2977f5]['type']&&_0x3c0de8--,_0x2977f5++;if(0x0!=_0x3c0de8){if(_0x586172[_0x19ee99]['isRemoved'])_0x586172[_0x19ee99]['isIncorrect']=!0x0;else{for(;_0x2977f5!=_0x19ee99;)_0x586172[_0x2977f5]['isRemoved']&&0x0!=_0x586172[_0x2977f5]['distance']&&(_0x586172[_0x2977f5]['isIncorrect']=!0x0,_0x51fc22['add'](_0x586172[_0x2977f5]['pairId'])),_0x2977f5--;}}}return _0x586172['filter'](_0x1cff32=>!_0x1cff32['isIncorrect']);}['_removeUnsupportedChanges'](_0x362926){const _0x5201b4=this['editor']['model']['schema'];for(let _0x3da337=0x0;_0x3da337<_0x362926['length'];_0x3da337++){if(!(_0x362926[_0x3da337]['isAdded']||_0x362926[_0x3da337]['isAddSuggestion']||_0x362926[_0x3da337]['isRemoved']||_0x362926[_0x3da337]['isRemoveSuggestion']))continue;if(0x0==_0x362926[_0x3da337]['distance'])continue;const _0x418c74=_0x362926[_0x3da337]['item'];_0x5201b4['isBlock'](_0x418c74)||_0x5201b4['isLimit'](_0x418c74)||(_0x362926[_0x3da337]['isAdded']&&delete _0x362926[_0x3da337]['isAdded'],_0x362926[_0x3da337]['isAddSuggestion']&&delete _0x362926[_0x3da337]['isAddSuggestion'],_0x362926[_0x3da337]['isRemoveSuggestion']&&delete _0x362926[_0x3da337]['isRemoveSuggestion'],_0x362926[_0x3da337]['isRemoved']&&(_0x362926[_0x3da337]['isIncorrect']=!0x0));}return _0x362926['filter'](_0x19afc3=>!_0x19afc3['isIncorrect']);}['_makeModelFromTape'](_0x593f67,_0x42dba8,_0x811d2a){const _0x43f570=new _0x1017e4(),_0x362d72=[],_0x564114=new Map(),_0x467411=this['editor']['model'],_0x5084b5=_0x467411['schema'],_0x33d430=[_0x43f570],_0x46a4fa={},_0x14208e={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x81162a=null;const _0x1fd6bb=[0x0];for(let _0x49bddd=0x0;_0x49bddd<_0x593f67['length'];_0x49bddd++)if('elementStart'===_0x593f67[_0x49bddd]['type']){_0x593f67[_0x49bddd]['previousPosition']=_0x467411['createPositionFromPath'](_0x43f570,_0x1fd6bb);const _0x3d9375=new _0x149c78(_0x593f67[_0x49bddd]['item']['name'],_0x593f67[_0x49bddd]['item']['getAttributes']());_0x33d430[0x0]['_appendChild'](_0x3d9375),_0x1fd6bb['push'](0x0),_0x33d430['unshift'](_0x3d9375),_0x593f67[_0x49bddd]['nextPosition']=_0x467411['createPositionFromPath'](_0x43f570,_0x1fd6bb);}else'elementEnd'===_0x593f67[_0x49bddd]['type']?(_0x33d430['shift'](),_0x593f67[_0x49bddd]['previousPosition']=_0x467411['createPositionFromPath'](_0x43f570,_0x1fd6bb),_0x1fd6bb['pop'](),_0x1fd6bb[_0x1fd6bb['length']-0x1]++,_0x593f67[_0x49bddd]['nextPosition']=_0x467411['createPositionFromPath'](_0x43f570,_0x1fd6bb)):(_0x593f67[_0x49bddd]['previousPosition']=_0x467411['createPositionFromPath'](_0x43f570,_0x1fd6bb),_0x81162a?_0x81162a['_data']+=_0x593f67[_0x49bddd]['item']['data']:_0x81162a=new _0xfc39de(_0x593f67[_0x49bddd]['item']['data'],_0x593f67[_0x49bddd]['item']['getAttributes']()),_0x593f67[_0x49bddd+0x1]&&'text'===_0x593f67[_0x49bddd+0x1]['type']&&_0x15e957(_0x81162a,_0x593f67[_0x49bddd+0x1]['item'])||(_0x33d430[0x0]['_appendChild'](_0x81162a),_0x81162a=null),_0x1fd6bb[_0x1fd6bb['length']-0x1]+=_0x593f67[_0x49bddd]['item']['offsetSize'],_0x593f67[_0x49bddd]['nextPosition']=_0x467411['createPositionFromPath'](_0x43f570,_0x1fd6bb));for(let _0x2093b8=0x0;_0x2093b8<_0x593f67['length'];_0x2093b8++){const _0x54004a=_0x593f67[_0x2093b8]['previousPosition'],_0x2c1aac=_0x593f67[_0x2093b8]['nextPosition'];for(const _0xcd8a70 of _0x593f67[_0x2093b8]['markersStart'])_0x564114['set'](_0xcd8a70,{'start':_0x54004a,'end':null});_0x6ec5e6('isRemoveSuggestion',_0x2093b8,_0x54004a,_0x2c1aac),_0x6ec5e6('isAddSuggestion',_0x2093b8,_0x54004a,_0x2c1aac),_0x6ec5e6('isRemoved',_0x2093b8,_0x54004a,_0x2c1aac),_0x6ec5e6('isAdded',_0x2093b8,_0x54004a,_0x2c1aac);for(const _0x4be0bc of _0x593f67[_0x2093b8]['markersEnd']){const _0x4bdb5e=_0x564114['get'](_0x4be0bc);_0x4bdb5e?_0x4bdb5e['end']=_0x2c1aac:_0x564114['set'](_0x4be0bc,{'start':_0x2c1aac,'end':_0x2c1aac});}}for(const [_0x5b8212,_0x2b1d78]of _0x564114){const _0x169b78=this['editor']['model']['createRange'](_0x2b1d78['start'],_0x2b1d78['end']);_0x43f570['markers']['set'](_0x5b8212,_0x169b78);}return _0x362d72['sort']((_0xc3ded1,_0x52d5bc)=>{const _0x175e46=_0x43f570['markers']['get']('revision:'+_0xc3ded1['id']),_0x5e81f2=_0x43f570['markers']['get']('revision:'+_0x52d5bc['id']);return _0x175e46['start']['isBefore'](_0x5e81f2['start'])?-0x1:_0x175e46['start']['isAfter'](_0x5e81f2['start'])?0x1:_0x175e46['end']['isBefore'](_0x5e81f2['end'])?-0x1:_0x175e46['end']['isAfter'](_0x5e81f2['end'])?0x1:'add'===_0xc3ded1['type']?-0x1:0x1;}),{'root':_0x43f570,'changes':_0x362d72};function _0x6ec5e6(_0x2ba88a,_0x13f3a6,_0x485002,_0x41d654){const _0x3af572=!!_0x593f67[_0x13f3a6][_0x2ba88a],_0x6fdc3f=_0x3af572?_0x593f67[_0x13f3a6][_0x2ba88a]['userId']:null,_0x152161=_0x13f3a6===_0x593f67['length']-0x1,_0x3f682d=_0x14208e[_0x2ba88a][0x0],_0x3bf967=_0x5084b5['isObject'](_0x593f67[_0x13f3a6]['item']);!_0x46a4fa[_0x2ba88a]&&_0x3af572?_0x46a4fa[_0x2ba88a]={'start':_0x485002,'tapeItem':_0x593f67[_0x13f3a6],'userId':_0x6fdc3f,'type':_0x2ba88a}:_0x46a4fa[_0x2ba88a]&&!_0x3af572?(_0x46a4fa[_0x2ba88a]['end']=_0x485002,_0x338799(_0x46a4fa[_0x2ba88a]),_0x46a4fa[_0x2ba88a]=null):_0x46a4fa[_0x2ba88a]&&_0x3af572&&_0x46a4fa[_0x2ba88a]['userId']!==_0x6fdc3f&&(_0x46a4fa[_0x2ba88a]['end']=_0x485002,_0x3f682d&&_0x3f682d['userId']===_0x46a4fa[_0x2ba88a]['userId']||_0x338799(_0x46a4fa[_0x2ba88a]),_0x46a4fa[_0x2ba88a]={'start':_0x485002,'tapeItem':_0x593f67[_0x13f3a6],'userId':_0x6fdc3f,'type':_0x2ba88a}),_0x46a4fa[_0x2ba88a]&&_0x3bf967&&('elementStart'!==_0x593f67[_0x13f3a6]['type']||_0x3f682d&&_0x3f682d['userId']===_0x6fdc3f||_0x14208e[_0x2ba88a]['unshift']({'userId':_0x6fdc3f,'object':_0x593f67[_0x13f3a6]['item'],'change':_0x46a4fa[_0x2ba88a]}),'elementEnd'===_0x593f67[_0x13f3a6]['type']&&_0x3f682d&&_0x3f682d['object']===_0x593f67[_0x13f3a6]['item']&&(_0x14208e[_0x2ba88a]['shift'](),_0x46a4fa[_0x2ba88a]=_0x3f682d['change'])),_0x46a4fa[_0x2ba88a]&&_0x152161&&(_0x46a4fa[_0x2ba88a]['end']=_0x41d654,_0x338799(_0x46a4fa[_0x2ba88a]),_0x46a4fa[_0x2ba88a]=null);}function _0x338799({start:_0x1c4b0b,end:_0x518bba,tapeItem:_0x235e03,userId:_0x3b790c,type:_0x556388}){const _0x12ccb0=_0x235e03['item'],_0x51db59=_0x467411['schema']['isBlock'](_0x12ccb0)&&!_0x467411['schema']['isLimit'](_0x12ccb0),_0x4a8b1f=_0x1c4b0b['nodeAfter']==_0x518bba['parent']&&_0x518bba['isAtStart'];if(_0x51db59&&_0x4a8b1f)return;const _0x74c009=_0x467411['createRange'](_0x1c4b0b,_0x518bba),_0x27b617=_0x42dba8['get'](_0x3b790c),_0x4fb2ca=new G({'author':_0x27b617,'type':'isAdded'==_0x556388||'isAddSuggestion'==_0x556388?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x556388||'isRemoveSuggestion'==_0x556388},'createdAt':new Date(),'rootName':_0x811d2a});_0x362d72['push'](_0x4fb2ca),_0x43f570['markers']['set']('revision:'+_0x4fb2ca['id'],_0x74c009);}function _0x15e957(_0x568734,_0x3e43c9){const _0x31ea40=_0x568734['getAttributes'](),_0x55d58a=_0x3e43c9['getAttributes']();for(const _0x13f4ac of _0x31ea40){if(_0x13f4ac[0x1]!==_0x3e43c9['getAttribute'](_0x13f4ac[0x0]))return!0x1;_0x55d58a['next']();}return _0x55d58a['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x31849f=>{const _0x2c29e4=_0x31849f['markerName']['split'](':')[0x1],_0x59b8d0=this['_getChangeFromId'](_0x2c29e4);if(!_0x59b8d0)return null;const _0x2e9fc2='add'==_0x59b8d0['type']?'insertion':'deletion',_0x229273=['ck-suggestion-marker','ck-suggestion-marker-'+_0x2e9fc2];return _0x59b8d0['data']['isSuggestion']&&_0x229273['push']('ck-suggestion-marker-'+_0x2e9fc2+'-new'),this['activeChange']==_0x59b8d0&&_0x229273['push']('ck-suggestion-marker--active'),{'classes':_0x229273,'attributes':{'data-change-id':_0x2c29e4}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x390fc2=>{_0x390fc2['on']('element:pre',(_0x820632,_0x8f9445,_0x429fb6)=>{const _0x542a49=_0x8f9445['viewItem']['getChild'](0x0);if(!_0x542a49||!_0x542a49['is']('element','code'))return;if(!_0x429fb6['consumable']['consume'](_0x542a49,{'attributes':['vid_start','vid_end']}))return;const _0x37c9eb=_0x8f9445['modelRange']['start']['nodeAfter'];_0x429fb6['writer']['setAttribute']('vid_start',_0x542a49['getAttribute']('vid_start'),_0x37c9eb),_0x429fb6['writer']['setAttribute']('vid_end',_0x542a49['getAttribute']('vid_end'),_0x37c9eb);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0xcae4e1=>{_0xcae4e1['on']('element',(_0x5a2863,_0x2b033f,_0x377010)=>{if(!_0x377010['consumable']['consume'](_0x2b033f['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x2b033f['modelRange']['isCollapsed'])return;const _0x224546=_0x2b033f['modelRange']['start']['nodeAfter'];_0x224546['hasAttribute']('vid_start')||_0x224546['hasAttribute']('vid')||(_0x377010['writer']['setAttribute']('vid_start',_0x2b033f['viewItem']['getAttribute']('vid_start'),_0x224546),_0x377010['writer']['setAttribute']('vid_end',_0x2b033f['viewItem']['getAttribute']('vid_end'),_0x224546));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x22dbb4=>_0x22dbb4['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x39d7e8,[,_0x3e9776])=>{['vid_start','vid_end','vid']['includes'](_0x3e9776)&&(_0x39d7e8['return']=!0x0,_0x39d7e8['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x446d18=>{_0x446d18['on']('attribute:vid',(_0x4f976c,_0x5a62b9,_0x1a5e4d)=>{if('\x20'!=_0x5a62b9['item']['data']||_0x5a62b9['item']['parent']['maxOffset']>0x1)return;if(!_0x1a5e4d['consumable']['consume'](_0x5a62b9['item'],_0x4f976c['name']))return;const _0x35e0ec=_0x1a5e4d['writer'],_0x52909c=_0x1a5e4d['mapper']['toViewRange'](_0x5a62b9['range']);_0x35e0ec['wrap'](_0x52909c,_0x35e0ec['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x175a31){const _0x525100=_0x175a31['plugins']['get']('RevisionViewer');return(_0x259e0b,_0x129ae4,_0x31b884)=>{const _0x249adc=_0x129ae4['markerName']['split'](':')[0x1],_0xc1965c=_0x525100['_getChangeFromId'](_0x249adc);if(!_0xc1965c)return null;const _0x5db56e='add'==_0xc1965c['type']?'split':'merge';if(!_0x31b884['consumable']['test'](_0x129ae4['markerRange'],_0x259e0b['name']))return;const _0x223459=_0x129ae4['markerRange']['getWalker'](),_0x3a1c0a=_0x129ae4['markerRange']['start'],_0x572ba1=_0x175a31['model']['schema'];let _0x5036db=null,_0x3765ab=null,_0x214c9f=!0x1,_0x49fdf2=!0x1;for(const _0x43dc69 of _0x223459){const _0x1a2b7d=_0x43dc69['item'];_0x214c9f=_0x214c9f||_0x572ba1['isContent'](_0x1a2b7d);const _0x290866=_0x31b884['mapper']['toViewElement'](_0x1a2b7d);if(_0x290866&&_0x290866['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x43dc69['type']&&(_0x572ba1['isBlock'](_0x1a2b7d)&&!_0x572ba1['isLimit'](_0x1a2b7d)&&(_0x1a2b7d['nextSibling']||_0x3a1c0a['isAtEnd']?_0x5036db&&_0x5036db['parent']==_0x1a2b7d||(_0x5036db=_0x1a2b7d,_0x5a619a(_0x43dc69['previousPosition']),_0x49fdf2=!0x0):_0x3765ab=_0x3765ab||_0x43dc69['previousPosition']));}function _0x5a619a(_0x366942){const _0x298978=_0x31b884['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x5db56e}),_0x49f9a8=_0x31b884['mapper']['toViewPosition'](_0x366942);_0xc1965c['data']['isSuggestion']&&_0x31b884['writer']['addClass']('ck-suggestion-marker-'+_0x5db56e+'-new',_0x298978),_0x525100['activeChange']==_0xc1965c&&_0x31b884['writer']['addClass']('ck-suggestion-marker--active',_0x298978),_0x31b884['writer']['insert'](_0x49f9a8,_0x298978),_0x31b884['mapper']['bindElementToMarker'](_0x298978,_0x129ae4['markerName']);}_0x214c9f||_0x49fdf2||!_0x3765ab||_0x5a619a(_0x3765ab);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x43f77a,_0x398991,_0x861f16)=>{const _0xfa226=_0x861f16['mapper']['markerNameToElements'](_0x398991['markerName']);if(_0xfa226){for(const _0x54cc7c of _0xfa226)(_0x54cc7c['hasClass']('ck-suggestion-marker-split')||_0x54cc7c['hasClass']('ck-suggestion-marker-merge'))&&(_0x861f16['mapper']['unbindElementFromMarkerName'](_0x54cc7c,_0x398991['markerName']),_0x861f16['writer']['remove'](_0x54cc7c));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x26d410,_0x23c80b,_0x57dc32)=>{const _0x319e38=_0x23c80b['markerName']['split'](':')[0x1],_0x8ba4fb=this['_getChangeFromId'](_0x319e38);if(!_0x8ba4fb)return null;const _0x56a0c4='add'==_0x8ba4fb['type']?'split':'merge';if(_0x57dc32['consumable']['test'](_0x23c80b['markerRange'],_0x26d410['name']))for(const _0x2e3669 of _0x23c80b['markerRange']['getItems']()){if(!_0x2e3669['is']('element','softBreak'))continue;const _0x3d1409=_0x57dc32['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x56a0c4}),_0x5372bd=_0x57dc32['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x2e3669));_0x8ba4fb['data']['isSuggestion']&&_0x57dc32['writer']['addClass']('ck-suggestion-marker-'+_0x56a0c4+'-new',_0x3d1409),this['activeChange']==_0x8ba4fb&&_0x57dc32['writer']['addClass']('ck-suggestion-marker--active',_0x3d1409),_0x57dc32['writer']['insert'](_0x5372bd,_0x3d1409),_0x57dc32['mapper']['bindElementToMarker'](_0x3d1409,_0x23c80b['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x5bb0f5=>{for(const _0x280c2e of this['editor']['model']['document']['getRootNames']()){const _0x44d37e=this['editor']['model']['document']['getRoot'](_0x280c2e),_0x2ddc25=this['editor']['editing']['view']['document']['getRoot'](_0x280c2e);if(_0x2ddc25){const _0x4bf2b3=_0x44d37e['getAttribute']('revisionHistoryAttachChange');if(_0x5bb0f5['removeAttribute']('data-change-id',_0x2ddc25),_0x5bb0f5['removeClass']('ck-revision-history-root-add',_0x2ddc25),_0x5bb0f5['removeClass']('ck-revision-history-root-remove',_0x2ddc25),_0x5bb0f5['removeClass']('ck-revision-history-root--active',_0x2ddc25),_0x4bf2b3){const _0x4669a8=this['_getChangeFromId'](_0x4bf2b3);if(!_0x4669a8)return null;_0x5bb0f5['setAttribute']('data-change-id',_0x4bf2b3,_0x2ddc25),_0x5bb0f5['addClass']('ck-revision-history-root-'+_0x4669a8['type'],_0x2ddc25),this['activeChange']==_0x4669a8&&_0x5bb0f5['addClass']('ck-revision-history-root--active',_0x2ddc25);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x39c392=>'revision-comment:'+_0x39c392,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x3d53b5=>'revision-suggestion:'+_0x3d53b5,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x57393d=>({'name':'suggestion:'+_0x57393d,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x506f24=>{const _0x2753c3=_0x506f24['markerName']['split'](':')[0x1];return'insertion'!=_0x2753c3&&'deletion'!=_0x2753c3?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x2753c3]};}}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:deletion',Q(this['editor'],'merge'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:insertion',Q(this['editor'],'split'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision-suggestion',(_0x13a809,_0x3c6acf,_0x211fa3)=>{const _0x4bf985=_0x211fa3['mapper']['markerNameToElements'](_0x3c6acf['markerName']);if(_0x4bf985){for(const _0xc8d888 of _0x4bf985)_0xc8d888['is']('uiElement')&&(_0x211fa3['mapper']['unbindElementFromMarkerName'](_0xc8d888,_0x3c6acf['markerName']),_0x211fa3['writer']['remove'](_0xc8d888));}},{'priority':'high'});}['_getChangeFromId'](_0xb0b473){return this['_changeIdToChange']['get'](_0xb0b473);}['_getViewForChange'](_0x350ab6){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new z(this['editor']['locale'],_0x350ab6),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x271259,_0x581916,_0x55aabb,_0x581b91)=>{_0x581b91&&this['_balloon']['remove'](_0x581b91),_0x55aabb&&(this['_balloon']['add']({'view':_0x55aabb,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x4f2480=this['editor']['editing'],_0x332043=this['_getChangeFromId'](_0x55aabb['changeId']);let _0x4a27ef;if(_0x332043['data']['isOnRoot']){const _0x4422f8=_0x4f2480['view']['getDomRoot'](_0x332043['rootName']);_0x4a27ef=Array['from'](_0x4422f8['getClientRects']());}else{const _0x5c9f30=this['editor']['model']['markers']['get']('revision:'+_0x55aabb['changeId']);_0x4a27ef=Array['from'](_0x4f2480['mapper']['markerNameToElements'](_0x5c9f30['name']))['map'](_0x45090e=>_0x4f2480['view']['domConverter']['mapViewToDom'](_0x45090e))['map'](_0x295dda=>Array['from'](_0x295dda['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x4a27ef[0x0];return _0x4a27ef['find'](_0x585fca=>_0x585fca['top']-0x3<=this['_activeViewTarget']['y']&&_0x585fca['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x585fca['left']-0x3<=this['_activeViewTarget']['x']&&_0x585fca['right']+0x3>=this['_activeViewTarget']['x'])||_0x4a27ef[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x1c51ca,_0x376bf5,_0x385e82,_0x86e14e)=>{this['activeView']=_0x385e82?this['_getViewForChange'](_0x385e82):null,this['editor']['model']['change'](()=>{const _0x83a60f=this['editor']['editing'];_0x86e14e&&(_0x86e14e['data']['isOnRoot']?_0x83a60f['view']['change'](_0x28d6db=>{_0x28d6db['removeClass']('ck-revision-history-root--active',_0x83a60f['view']['document']['getRoot'](_0x86e14e['rootName']));}):_0x83a60f['reconvertMarker']('revision:'+_0x86e14e['id'])),_0x385e82&&(_0x385e82['data']['isOnRoot']?_0x83a60f['view']['change'](_0x116cbb=>{_0x116cbb['addClass']('ck-revision-history-root--active',_0x83a60f['view']['document']['getRoot'](_0x385e82['rootName']));}):_0x83a60f['reconvertMarker']('revision:'+_0x385e82['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x11576c,_0x450684)=>{if(this['activeChange'])return;const _0x4398e5=this['_findChangeIdFromDomTarget'](_0x450684['target']),_0x57528c=this['_changeIdToChange']['get'](_0x4398e5);_0x57528c?(this['_activeViewTarget']={'x':_0x450684['domEvent']['x'],'y':_0x450684['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x57528c)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x35056b,_0x36ae2b)=>{const _0x1426cd=this['_findChangeIdFromDomTarget'](_0x36ae2b['target']),_0x41e3d7=this['_changeIdToChange']['get'](_0x1426cd);_0x41e3d7?(this['_activeViewTarget']={'x':_0x36ae2b['domEvent']['x'],'y':_0x36ae2b['domEvent']['y']},_0x41e3d7===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x41e3d7):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x4c6d52){do{const _0x31c4d9=_0x4c6d52['getAttribute']('data-change-id');if(_0x31c4d9)return _0x31c4d9;_0x4c6d52=_0x4c6d52['parent'];}while(_0x4c6d52);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x3269fd=>{for(const _0x138911 of this['editor']['model']['markers'])_0x3269fd['removeMarker'](_0x138911);});}}function Q(_0x5cd8e8,_0x422353){return(_0x1e4964,_0x2fb666,_0x42bde8)=>{if(!_0x42bde8['consumable']['test'](_0x2fb666['markerRange'],_0x1e4964['name']))return;const _0x6e86a4=_0x2fb666['markerRange']['getWalker'](),_0x4e643b=_0x2fb666['markerRange']['start'],_0x78224e=_0x5cd8e8['model']['schema'];let _0x166a2d=null,_0x1f256e=null,_0xfb04bd=!0x1,_0x5a0e7c=!0x1;for(const _0x4da050 of _0x6e86a4){const _0x2b9d17=_0x4da050['item'];_0xfb04bd=_0xfb04bd||_0x78224e['isContent'](_0x2b9d17);const _0x2005ed=_0x42bde8['mapper']['toViewElement'](_0x2b9d17);if(_0x2005ed&&_0x2005ed['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x4da050['type']&&(_0x78224e['isBlock'](_0x2b9d17)&&!_0x78224e['isLimit'](_0x2b9d17)&&(_0x2b9d17['nextSibling']||_0x4e643b['isAtEnd']?_0x166a2d&&_0x166a2d['parent']==_0x2b9d17||(_0x166a2d=_0x2b9d17,_0x336cd4(_0x4da050['previousPosition']),_0x5a0e7c=!0x0):_0x1f256e=_0x1f256e||_0x4da050['previousPosition']));}function _0x336cd4(_0x27fe0c){const _0x701cde=_0x42bde8['mapper']['toViewPosition'](_0x27fe0c),_0x4f6948=_0x42bde8['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x422353});_0x42bde8['writer']['insert'](_0x701cde,_0x4f6948),_0x42bde8['mapper']['bindElementToMarker'](_0x4f6948,_0x2fb666['markerName']);}_0xfb04bd||_0x5a0e7c||!_0x1f256e||_0x336cd4(_0x1f256e);};}class nt extends _0x17f1c5{constructor(_0x4e8a6c){super(_0x4e8a6c);const _0x4a1fad=_0x4e8a6c['plugins']['get'](l);this['affectsData']=!0x1,this['listenTo'](_0x4a1fad,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x4a1fad,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0xf66660=this['editor'],_0x4bfbe0=_0xf66660['plugins']['get'](l),_0x4076bb=_0x4bfbe0['isReady']?_0x4bfbe0['diff']['newRevisionId']:null;_0xf66660['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x4076bb);}['refresh'](){const {isReady:_0x4a301a,isEnabled:_0x1f610b,repository:_0x2d8f3f,diff:_0x1ba88f}=this['editor']['plugins']['get'](l),_0x18a74e=_0x1ba88f&&_0x2d8f3f['getLaterVisibleRevision'](_0x1ba88f['newRevisionId']);this['isEnabled']=_0x4a301a&&_0x1f610b&&Boolean(_0x18a74e);}}class rt extends _0x17f1c5{['_step'];constructor(_0x3abfa7,{direction:_0x408d42}){super(_0x3abfa7);const _0x360038=_0x3abfa7['plugins']['get'](l);this['affectsData']=!0x1,this['_step']='forward'===_0x408d42?0x1:-0x1,this['listenTo'](_0x360038,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x360038,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x360038,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x2ae124=this['editor'],_0x2cf73a=_0x2ae124['plugins']['get'](l),{isNavigationMode:_0x5ef789,currentChangeNumber:_0x43cf21}=_0x2cf73a;let _0x2341a4;if(_0x2cf73a['activeChange']=_0x5ef789?_0x2cf73a['diff']['changes']['get'](_0x43cf21+this['_step']):_0x2cf73a['diff']['changes']['first'],_0x2cf73a['activeChange']['data']['isOnRoot'])_0x2341a4=_0x2ae124['editing']['view']['getDomRoot'](_0x2cf73a['activeChange']['rootName']);else{const _0x25109e=_0x2ae124['model']['markers']['get']('revision:'+_0x2cf73a['activeChange']['id']);_0x2341a4=_0x5ea7c3(_0x2ae124['editing'],_0x25109e);}_0x278709({'target':_0x2341a4,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x5002d3,currentChangeNumber:_0x3c8fdb,numberOfChanges:_0xfde6bc,isReady:_0x458633,isEnabled:_0x28b8ae}=this['editor']['plugins']['get'](l);this['isEnabled']=!!(_0x28b8ae&&_0x458633&&_0xfde6bc)&&(!_0x5002d3||(0x1===this['_step']?_0x3c8fdb<_0xfde6bc-0x1:_0x3c8fdb>0x0));}}class vi extends _0x5372f9{constructor(_0x23711b){super(_0x23711b);const _0x39a5cb=this['bindTemplate'],_0x522922=new _0x4c294d(_0x23711b),_0x49f4a1=new _0x4c294d(_0x23711b);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',(_0x15415f,_0x515127)=>_0x15415f&&_0x515127>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x4b23a9,_0x1d10d8,_0x2808ba,_0x9a328e)=>{if(!_0x4b23a9)return R(_0x23711b,'Loading...');if(!_0x2808ba)return R(_0x23711b,'No\x20changes');const _0x3092a5=R(_0x23711b,'NUMBER_OF_CHANGES',_0x2808ba);return _0x9a328e?R(_0x23711b,'X_OF_Y_CHANGES',[_0x1d10d8+0x1,_0x2808ba]):_0x3092a5;}),_0x522922['set']({'label':R(_0x23711b,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x561579}),_0x49f4a1['set']({'label':R(_0x23711b,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x41c34d}),_0x522922['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x49f4a1['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x522922['on']('execute',()=>this['fire']('execute','backward')),_0x49f4a1['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',_0x39a5cb['if']('_isStatusLabelVisible','ck-hidden',_0x5c23bd=>!_0x5c23bd)]},'children':[{'text':_0x39a5cb['to']('isNavigationMode',_0x232dce=>_0x232dce?R(_0x23711b,'EDIT_X_OF_Y_REVISIONS')+':\x20':R(_0x23711b,'Total')+':\x20')}]},{'text':_0x39a5cb['to']('_statusText')}]},new _0x268ae1(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x522922,_0x49f4a1]}]});}}const oe='ck-editor__editable__loading-overlay';class wi extends _0x40d69e{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x911044=this['editor']['editing']['view'];_0x911044['change'](_0x2d3759=>{for(const _0x593f2c of _0x911044['document']['roots'])_0x2d3759['addClass'](oe,_0x593f2c);});}['hide'](){const _0x1889a8=this['editor']['editing']['view'];_0x1889a8['change'](_0x40d980=>{for(const _0x28bdde of _0x1889a8['document']['roots'])_0x40d980['removeClass'](oe,_0x28bdde);});}}class u extends _0x40d69e{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l,wi];}['init'](){const _0x1b4622=this['editor'],_0x1114d9=_0x1b4622['plugins']['get'](l),_0x488229=_0x1b4622['plugins']['get'](wi);_0x1b4622['ui']['componentFactory']['add']('exitToEditing',_0x4a31c5=>{const _0x3be821=new _0x4c294d(_0x4a31c5);return _0x3be821['set']({'label':R(_0x4a31c5,'Back\x20to\x20editing'),'icon':_0x2ee9fb,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x3be821,'execute',()=>{_0x1b4622['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x3be821;}),_0x1b4622['ui']['componentFactory']['add']('restoreRevision',_0x544b21=>{const _0xde0dfb=new _0x4c294d(_0x544b21);return _0xde0dfb['set']({'label':R(_0x544b21,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0xde0dfb['bind']('isEnabled')['to'](_0x1b4622['commands']['get']('restoreRevision')),this['listenTo'](_0xde0dfb,'execute',()=>_0x1b4622['execute']('restoreRevision')),_0xde0dfb;}),_0x1b4622['ui']['componentFactory']['add']('changesNavigation',_0x4ce24e=>{const _0x35aade=new vi(_0x4ce24e),_0x437e07=_0x1b4622['commands']['get']('showPreviousChange'),_0x5a71e0=_0x1b4622['commands']['get']('showNextChange');return _0x35aade['bind']('isBackwardNavigationEnabled')['to'](_0x437e07,'isEnabled'),_0x35aade['bind']('isForwardNavigationEnabled')['to'](_0x5a71e0,'isEnabled'),_0x35aade['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x1114d9),this['listenTo'](_0x35aade,'execute',(_0x13f1fe,_0x3ab782)=>{_0x1b4622['execute']('forward'===_0x3ab782?'showNextChange':'showPreviousChange');}),_0x35aade;}),_0x488229['show'](),_0x1114d9['on']('change:isReady',(_0x324d1c,_0x1c9639,_0x33217d)=>{_0x33217d?_0x488229['hide']():_0x488229['show']();});}}class hi extends et{['_resizeObserver']=null;constructor(_0x5b23b6,_0x5d9089){super(_0x5b23b6,_0x5d9089);const _0x3575c5=this['bindTemplate'];this['set']({'label':R(_0x5b23b6,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=R(_0x5b23b6,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x3575c5['to']('_tooltipString'),'data-cke-tooltip-position':'s','data-cke-tooltip-class':'ck-tooltip_multi-line'}});}['render'](){super['render'](),this['_resizeObserver']=new ot(this['fieldView']['element'],()=>this['_updateTooltipText']()),this['listenTo'](this['fieldView'],'input',()=>this['_updateTooltipText']());}['destroy'](){super['destroy'](),this['_resizeObserver']&&this['_resizeObserver']['destroy']();}['_updateTooltipText'](){const _0x40447e=this['fieldView']['element'];this['_tooltipString']=_0x40447e['scrollWidth']>_0x40447e['clientWidth']&&_0x40447e['value']||'';}}class ni extends _0x5372f9{constructor(_0x434764,_0x92ab74,_0x5c2856){super(_0x434764);const _0x354f3e=new _0x2e6b9e();_0x354f3e['set']({'content':_0x4023b9,'viewBox':'0\x200\x2011\x2010'});const _0x195993=['ck','ck-revision-history-sidebar__revision-author'];_0x5c2856&&_0x195993['push']('ck-revision-history-sidebar__revision-author_creator');const _0x589b85=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':R(_0x434764,_0x5c2856?'Revision\x20creator':'Revision\x20author')},'children':[_0x354f3e,_0x92ab74['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x195993},'children':_0x589b85});}}function ci(_0x199b65,_0x15a688){const _0x416db4=_0x199b65['bindTemplate'],_0x455175=_0x199b65['locale'],_0x15a00a=_0x5bfde6(_0x455175);_0x15a00a['panelPosition']='sw';const _0x1452d8=function(_0xbb67e5,_0x21a110){const _0x523d98=function(_0x1ba6a6,_0x2e4279){const _0x13c57a=_0x1ba6a6['locale'],_0x5283e3={'Compare\x20against\x20selected':R(_0x13c57a,'Compare\x20against\x20selected'),'Name\x20this\x20revision':R(_0x13c57a,'Name\x20this\x20revision'),'Restore\x20this\x20revision':R(_0x13c57a,'Restore\x20this\x20revision')};return _0x2e4279['map'](_0xc3e847=>{const _0x4d6bca=_0x5283e3[_0xc3e847['name']];return _0x4d6bca&&_0x4d6bca!==_0xc3e847['name']&&(_0xc3e847['name']=_0x4d6bca),_0xc3e847;});}(_0xbb67e5,_0x21a110),_0x1022e8=new _0xbf5b7e();for(const _0x4b0fc7 of _0x523d98){const _0x17ebd0={'type':'button','model':new to({'label':_0x4b0fc7['name'],'class':_0x4b0fc7['class'],'withText':!0x0,'role':'menuitem','_action':_0x4b0fc7['action']})};_0x17ebd0['model']['bind']('isEnabled')['to'](_0xbb67e5,'isActionsDropdownOpen',_0x18993f=>'function'!=typeof _0x4b0fc7['isEnabled']||(!_0x18993f||_0x4b0fc7['isEnabled'](_0xbb67e5))),_0x1022e8['add'](_0x17ebd0);}return _0x1022e8;}(_0x199b65,_0x15a688);return _0x199b65['bind']('isActionsDropdownOpen')['to'](_0x15a00a,'isOpen'),_0x15a00a['buttonView']['set']({'label':R(_0x455175,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x2717e7}),_0x15a00a['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x416db4['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x416db4['to'](_0x2573f3=>_0x2573f3['stopPropagation']())}}),_0x15a00a['on']('execute',_0x4bee4a=>{_0x199b65['isReady']&&'function'==typeof _0x4bee4a['source']['_action']&&_0x4bee4a['source']['_action'](_0x199b65);}),_0x57d04a(_0x15a00a,_0x1452d8,{'role':'menu'}),_0x15a00a['listenTo'](_0x199b65,'change:isActionsDropdownOpen',(_0x314b5d,_0x1aa691,_0xe6ba6d)=>{if(_0xe6ba6d)for(const _0x521969 of _0x15a00a['listView']['items']){const _0xfbbe77=_0x521969['children']['first'],_0x1edf12=_0x15a688['find'](_0x199d30=>_0x199d30['action']===_0xfbbe77['_action'])['isVisible'];_0x521969['isVisible']=void 0x0===_0x1edf12||_0x1edf12(_0x199b65);}}),_0x15a00a;}class _i extends/* #__PURE__ -- @preserve */
27
+ _0x310213(_0x5372f9){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x4b09fc,_0x107669,_0x4c4a87,_0x5b6a02){super(_0x4b09fc);const _0x456c4d=this['bindTemplate'],_0x717410=function(_0x19cf33,_0x20524e){const _0x34be25=Array['from'](_0x20524e['authors'])['filter'](_0x41a4ff=>_0x41a4ff!=_0x20524e['creator']);return _0x20524e['creator']&&_0x34be25['unshift'](_0x20524e['creator']),_0x34be25['map'](_0x45a671=>new ni(_0x19cf33,_0x45a671,_0x45a671==_0x20524e['creator']));}(_0x4b09fc,_0x107669);this['id']=_0x107669['id'],this['_revision']=_0x107669,this['_requireRevisionName']=_0x5b6a02,this['bind']('name','createdAt')['to'](_0x107669),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x3fa67b=>{return _0x29530a=_0x4b09fc['uiLanguage'],(_0x7e8534=_0x3fa67b)['toLocaleDateString'](_0x29530a,{'month':'long','day':'numeric'})+',\x20'+_0x7e8534['toLocaleTimeString'](_0x29530a,{'hour':'numeric','minute':'numeric'});var _0x29530a,_0x7e8534;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new hi(_0x4b09fc,ti),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x43af77=>_0x43af77||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x381fc3,_0x17a1d2)=>_0x381fc3&&_0x17a1d2),this['revisionActionsView']=_0x4c4a87&&_0x4c4a87['length']?ci(this,_0x4c4a87):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x456c4d['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x456c4d['if']('isEnabled','ck-disabled',_0x2299c0=>!_0x2299c0),_0x456c4d['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x456c4d['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x456c4d['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':_0x456c4d['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':_0x717410}]},this['revisionActionsView']],'on':{'click':_0x456c4d['to'](_0x3555a2=>{_0x3555a2['srcElement']['closest']('.ck-thread__remove-confirm')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x5c0010=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x5c0010,'change',()=>{this['_requireRevisionName']&&!_0x5c0010['value']||this['fire']('setName',{'id':this['id'],'name':_0x5c0010['value']}),_0x5c0010['value']||(_0x5c0010['value']=this['name']?this['name']:this['_createdAtFormatted']);});}['select'](){this['isSelected']=!0x0;}['deselect'](){this['isSelected']=!0x1;}['highlight'](){this['isHighlighted']=!0x0;}['unhighlight'](){this['isHighlighted']=!0x1;}}function bi(_0x43c352,_0xa3e704){const _0x44786e=_0x29909a['fromJSDate'](_0x43c352)['setLocale'](_0xa3e704),_0xe95107=_0x29909a['local'](),_0x33e4f5=_0xe95107['minus']({'days':0x1})['startOf']('day');let _0x3c4dc7,_0xad2c6c;return _0x44786e['hasSame'](_0xe95107,'day')?(_0x3c4dc7=_0x44786e['startOf']('day')['toJSDate'](),_0xad2c6c=_0x44786e['toRelativeCalendar']()):_0x44786e['hasSame'](_0x33e4f5,'day')?(_0x3c4dc7=_0x33e4f5['toJSDate'](),_0xad2c6c=_0x44786e['toRelativeCalendar']()):_0x44786e['hasSame'](_0xe95107,'week')?(_0x3c4dc7=_0x44786e['startOf']('week')['toJSDate'](),_0xad2c6c=_0x44786e['weekdayLong']||''):_0x44786e['hasSame'](_0xe95107,'year')?(_0x3c4dc7=_0x44786e['startOf']('month')['toJSDate'](),_0xad2c6c=_0x44786e['monthLong']||''):(_0x3c4dc7=_0x44786e['startOf']('year')['toJSDate'](),_0xad2c6c=String(_0x44786e['year'])),{'startDate':_0x3c4dc7,'localizedPeriodName':_0xad2c6c};}class fi extends _0x5372f9{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x3f970c,_0x1fda00,_0x49578d,_0xb35321){super(_0x3f970c);const _0x53a299=bi(_0x1fda00,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x1fda00,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x49578d,this['_requireRevisionName']=_0xb35321,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':_0x53a299}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x2bf4aa){const _0x3196aa=new _i(this['locale'],_0x2bf4aa,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x3196aa);}['removeRevision'](_0x9687de){const _0x2d686a=this['revisionViews']['find'](_0x35857f=>_0x35857f['id']===_0x9687de['id']);this['revisionViews']['remove'](_0x2d686a);}}class ki extends _0x5372f9{constructor(_0x2309f4){super(_0x2309f4);const _0x33da87=new _0x2e6b9e();_0x33da87['content']=_0x5a259c,this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x33da87,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[R(_0x2309f4,'Revision\x20history')]}]});}}class pi extends _0x5372f9{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x132b1f,_0x21af25,_0x2e10a9,_0x260808){super(_0x132b1f);const _0x7e936b=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x21af25,this['_revisionActions']=_0x2e10a9,this['_requireRevisionName']=_0x260808,this['on']('select',(_0x4c51c2,_0x35b9d7)=>{this['fire']('revisionSelected',_0x35b9d7);}),this['on']('setName',(_0x544e48,_0x5244a0)=>{this['fire']('revisionSetName',_0x5244a0);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new ki(_0x132b1f),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x7e936b['if']('isEnabled','ck-disabled',_0x4db8cf=>!_0x4db8cf)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x51d20f of this['_revisions'])this['_addRevision'](_0x51d20f);this['_revisions']['on']('add',(_0xce0678,_0x1203fe)=>{this['_addRevision'](_0x1203fe);}),this['_revisions']['on']('remove',(_0x30ed7f,_0xef8d7b)=>{this['_removeRevision'](_0xef8d7b);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x463dd1=>_0x463dd1['revisionViews']['map'](_0x230a51=>_0x230a51))['flat']();}['selectRevision'](_0x1119aa){for(const _0xe1046d of this['revisionViews'])_0x1119aa&&_0x1119aa['id']===_0xe1046d['id']?_0xe1046d['select']():_0xe1046d['deselect']();}['highlightRevisions'](_0x3aee02){for(const _0x295948 of this['revisionViews'])_0x3aee02['some'](({id:_0x16ab6b})=>_0x16ab6b===_0x295948['id'])?_0x295948['highlight']():_0x295948['unhighlight']();}['_addRevision'](_0x1c50c6){const _0x28fb54=bi(_0x1c50c6['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x227159=this['timePeriodViews']['get'](0x0);_0x227159&&_0x227159['startDate']['getTime']()===_0x28fb54['getTime']()||(_0x227159=new fi(this['locale'],_0x28fb54,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x227159)),_0x227159['addRevision'](_0x1c50c6);}['_removeRevision'](_0x5128e9){const _0x111892=bi(_0x5128e9['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x111892)['removeRevision'](_0x5128e9);}['_getTimePeriodViewByStartDate'](_0x2ae0b6){return this['timePeriodViews']['find'](_0x5408da=>_0x5408da['startDate']['getTime']()===_0x2ae0b6['getTime']());}}class f extends _0x40d69e{['_revisionViewer'];['_revisionsRepository'];['_sidebarView'];static ['defaultRevisionActions']=/* #__PURE__ -- @preserve */
28
28
  ((()=>['compareAgainstSelected','restoreRevision','nameRevision'])());static ['availableRevisionActions']=/* #__PURE__ -- @preserve */
29
- rt();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l];}constructor(_0x421ec4){super(_0x421ec4),this['_revisionViewer']=_0x421ec4['plugins']['get'](l),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x583cc3=this['_revisionsRepository']['_revisions'],_0x1318c3=this['_createRevisionActions'](),_0x5e8ace=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new Ri(this['editor']['locale'],_0x583cc3,_0x1318c3,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',(_0x19b091,_0x50b16a)=>{_0x50b16a['revisionViews']['on']('add',(_0x106830,_0x325684)=>{_0x325684['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)),_0x5e8ace['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x18de71=this['_revisionsRepository']['getRevision'](0x0);if(_0x18de71){const _0x495685=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x18de71['id']);this['_revisionViewer']['compare'](_0x18de71,_0x495685);}}['_handleRevisionSelected'](_0x515922,_0x5ad56b){const _0x242cc5=this['_revisionsRepository']['getRevision'](_0x5ad56b['id']),_0x32a11e=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x242cc5['id']);this['_revisionViewer']['compare'](_0x242cc5,_0x32a11e);}['_handleRevisionSetName'](_0x2d14e8,_0xe6cf1f){this['_revisionsRepository']['getRevision'](_0xe6cf1f['id'])['setName'](_0xe6cf1f['name']);}['_handleDiffChange'](_0x69382f,_0x5a88cb,_0x550791){const _0x36021b=this['_revisionsRepository']['getRevisionsInDiff'](_0x550791);_0x36021b['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x36021b),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x36021b[0x0]));}['_createRevisionActions'](){const _0x1618c2=this['editor'],_0x242f79=f['availableRevisionActions'],_0x1bd52f=_0x1618c2['config']['get']('revisionHistory.revisionActions')||f['defaultRevisionActions'];if(_0x1bd52f['length'])return _0x1bd52f['map'](_0x518e79=>{const _0x4e1590='string'==typeof _0x518e79?Object['assign']({},_0x242f79[_0x518e79]):_0x518e79;return _0x4e1590['action']=_0x4e1590['action']['bind'](this,_0x1618c2),_0x4e1590['isVisible']&&(_0x4e1590['isVisible']=_0x4e1590['isVisible']['bind'](this,_0x1618c2)),_0x4e1590;});}}function rt(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x19be42},_0x49039e)=>{const _0xf782d7=_0x19be42['get'](l),_0x155b4f=_0xf782d7['repository'];let _0x49fece=_0xf782d7['diff']['newRevisionId'],_0x1b6304=_0x49039e['id'];_0x155b4f['getIndex'](_0x49fece)>_0x155b4f['getIndex'](_0x1b6304)&&([_0x49fece,_0x1b6304]=[_0x1b6304,_0x49fece]),_0xf782d7['compare'](_0x49fece,_0x1b6304);},'isVisible':({plugins:_0x2adae6},_0x80cba8)=>{const _0x404a21=_0x2adae6['get'](l);return!(_0x404a21['repository']['getRevisionsInDiff'](_0x404a21['diff'])['length']>0x2)&&!_0x80cba8['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x12e701,{id:_0x528e00})=>{_0x12e701['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x528e00);},'isVisible':({plugins:_0x59bdc1},_0x2bcb0d)=>!!_0x59bdc1['get'](l)['repository']['getLaterVisibleRevision'](_0x2bcb0d['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x40dfb9},{id:_0x59d960,revisionNameView:_0x4a031a})=>{const _0x3dddf5=_0x40dfb9['get'](l),_0x5a141e=_0x3dddf5['repository']['getEarlierVisibleRevision'](_0x59d960);_0x3dddf5['compare'](_0x59d960,_0x5a141e),_0x4a031a['focus'](),_0x4a031a['fieldView']['select']();}}};}class Z extends tt{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x4bfc73,_0x4bd44a){super(_0x4bfc73),this['_view']=_0x4bd44a,this['_toolbarConfig']=st(_0x4bfc73['config']['get']('toolbar')),this['_elementReplacer']=new it();}get['element'](){return this['view']['element'];}['init'](_0x9080ff){const _0x3a735a=this['editor'],_0x31d5b0=this['view'],_0x38dae5=_0x3a735a['editing']['view'],_0x17039f=_0x31d5b0['editable'],_0x132b0e=_0x38dae5['document']['getRoot']();_0x17039f['name']=_0x132b0e['rootName'],_0x31d5b0['render']();const _0x16c155=_0x17039f['element'];this['setEditableElement'](_0x17039f['name'],_0x16c155),_0x31d5b0['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x38dae5['attachDomRoot'](_0x16c155),this['_elementReplacer']['replace'](_0x9080ff,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x309101=this['view'],_0x17e601=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x17e601['detachDomRoot'](_0x309101['editable']['name']),_0x309101['destroy']();}['_initToolbar'](){const _0x4464e0=this['view'];_0x4464e0['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x4464e0['stickyPanel']['limiterElement']=_0x4464e0['element'],_0x4464e0['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x357621})=>_0x357621),_0x4464e0['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x4464e0['toolbar']);}}class ii extends _0x204088{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x51530c,_0x50cd99,_0x344621={}){super(_0x51530c),this['stickyPanel']=new _0x58a0b8(_0x51530c),this['toolbar']=new _0x5ccb13(_0x51530c,{'shouldGroupWhenFull':_0x344621['shouldToolbarGroupWhenFull']}),this['_editable']=new te(_0x51530c,_0x50cd99);}['render'](){super['render'](),this['stickyPanel']['content']['add'](this['toolbar']),this['top']['add'](this['stickyPanel']),this['main']['add'](this['editable']);}}class m extends/* #__PURE__ -- @preserve */
30
- _0x491623(_0x5ee2b2){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x4dfb31,_0x42dbab){super(_0x42dbab),this['sourceElement']=_0x4dfb31,this['model']['document']['createRoot']();const _0x450508=new ii(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new Z(this,_0x450508);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x258c28,_0x13c88c){const _0x3ca639=new this(_0x258c28,_0x13c88c);return await _0x3ca639['initPlugins'](),await _0x3ca639['ui']['init'](_0x258c28),await _0x3ca639['data']['init'](_0x3ca639['config']['get']('initialData')||''),_0x3ca639['fire']('ready'),_0x3ca639;}}const d=['RevisionHistoryUI','RestrictedEditingMode'];class at extends _0x16aaad{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x2d4636){function _0x4d06d2(_0x4a2b4a){return _0x4a2b4a['map'](_0x151f2f=>String['fromCharCode'](_0x151f2f))['join']('');}super(_0x2d4636),this['result']='end',_0x2d4636[_0x4d06d2([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x4d06d2([0x76,0x69,0x65,0x77])][_0x4d06d2([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x4d06d2([0x61,0x75,0x74,0x6f]),_0x2d4636[_0x4d06d2([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x4d06d2([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x4d06d2([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x4d06d2([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x4d06d2([0x6f,0x6b])});}}class ht extends _0x16aaad{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h,v];}constructor(_0x1acd19){if(super(_0x1acd19),!this['editor']['config']['get']('revisionHistory'))throw new _0x29c5c0('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x1f35c5=>this['_showRevisionViewer']({..._0x1f35c5,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x25cfa3=>this['_closeRevisionViewer'](_0x25cfa3)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x4d1d79=>this['_restoreRevision'](_0x4d1d79)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x1be6af){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x1be6af;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x3d57ea){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x3d57ea);}['getRevision'](_0x479461){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x479461);}['getRevisions'](_0x147758){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x147758||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x5182a1=this['editor'],_0x16837c=_0x2008d6(_0x5182a1,d),_0x1db062=_0x5182a1['plugins']['get']('RevisionTracker'),_0x45de48=_0x5182a1['plugins']['get']('Users')['users'];return _0x16837c['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x16837c['lazyRoots'],(_0x16837c['plugins']['push'](at,l,u,class extends _0x16aaad{static get['requires'](){return[l,'Users'];}['init'](){const _0x276215=this['editor']['plugins']['get']('Users');for(const _0x5ae1b3 of _0x45de48)_0x5ae1b3['isAnonymous']||_0x276215['getUser'](_0x5ae1b3['id'])||_0x276215['addUser'](_0x5ae1b3);const _0x23fdab=_0x1db062['repository']['getRevisions']();let _0x5bd860=null;const _0x131579=this['editor']['plugins']['get']('RevisionViewer');_0x131579['adapter']=_0x1db062['adapter'],_0x131579['bind']('isEnabled')['to'](_0x1db062),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x5182a1,'isReadOnly',_0x5e1bc6=>!_0x5e1bc6);for(const _0xeb456b of _0x23fdab){const _0x4fa72b=null===_0xeb456b['creator'];if(_0x4fa72b&&_0xeb456b['toVersion']===_0xeb456b['fromVersion'])continue;const _0x148b61=_0xeb456b['toJSON']();_0x131579['addRevisionData'](_0x148b61,(_0x1865dd,_0x4e2609,_0x178f0d)=>{if(_0x4fa72b){if(_0x5bd860)_0x5bd860['_update'](_0x1865dd,_0x4e2609);else{if(!_0x4e2609){const _0x51cb59=_0x178f0d['toJSON']();_0x51cb59['id']=_0x5da2bc(),_0x1db062['saveRevision'](_0x51cb59,_0x178f0d['toVersion'])['then'](_0x41d329=>{_0x5bd860=_0x41d329;});}}}else _0xeb456b['_update'](_0x1865dd,_0x4e2609);});}}},f),_0x16837c);}['_enhanceShowRevisionViewerCallback'](){const _0x56e474=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x4f1c20=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x4162c9=this['editor']['plugins']['get']('Autosave');await _0x4162c9['save']();}else await _0x4f1c20['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x395998=this['editor']['plugins']['get']('Dialog');_0x395998['isOpen']&&_0x395998['hide']();}const _0x18f5ec=this['_getRevisionViewerEditorConfig']();return _0x56e474(_0x18f5ec)['then'](_0x369a38=>{return(this['_viewerEditor']=_0x369a38,this['editor']['plugins']['has']('Annotations'))&&this['editor']['plugins']['get']('Annotations')['refreshVisibility'](),(this['editor']['plugins']['has']('DocumentOutline')&&(this['editor']['plugins']['get']('DocumentOutlineUI')['view']['element']['style']['display']='none'),_0x369a38);})['catch'](_0x76a7bb=>(console['error'](_0x76a7bb),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x2a4085=this['editor']['config']['get']('revisionHistory')['closeRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.closeRevisionViewerCallback',()=>(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('DocumentOutline')&&(this['editor']['plugins']['get']('DocumentOutlineUI')['view']['element']['style']['display']=''),this['_viewerEditor']['plugins']['get']('RevisionViewer')['_cleanUp'](),_0x2a4085(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x31e0dd=this['editor']['plugins']['get']('Annotations');_0x31e0dd['refreshVisibility'](),_0x31e0dd['refreshPositioning']();}})));}['_showRevisionViewer'](_0x19cee5){const _0x3c0383=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x4f85d3=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x46366f=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return m['create'](_0x46366f,_0x19cee5)['then'](_0x24f5b4=>(_0x4f85d3['style']['display']='block',_0x3c0383['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x24f5b4));}['_closeRevisionViewer'](_0x389208){const _0xf8efdf=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0xf8efdf['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x389208['destroy']();}async['_restoreRevision'](_0x37c3e1){const _0x323fe7=this['editor'],_0x3f4579=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x43909c=_0x323fe7['plugins']['get']('RevisionTracker'),_0x21f2c2=_0x323fe7['plugins']['get']('RevisionHistoryUtils'),_0x237c93=_0x3f4579['repository']['getRevision'](_0x37c3e1);let _0x1a3877,_0x511a30,_0x5e1e55;try{await _0x21f2c2['loadRevisionData'](_0x237c93,this['adapter']),_0x1a3877=_0x21f2c2['getRevisionDocumentData'](_0x237c93),_0x511a30=_0x21f2c2['getRevisionRootsAttributes'](_0x237c93);}catch(_0xdf4106){return void console['error'](_0xdf4106);}_0x323fe7['model']['change'](_0x13c594=>{for(const _0x1b9967 of Array['from'](_0x323fe7['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x13c594['removeMarker'](_0x1b9967);}),_0x3f4579['isReady']=!0x1,_0x323fe7['model']['enqueueChange'](_0x3d3991=>{_0x3d3991['setSelection'](null),_0x3d3991['removeSelectionAttribute'](_0x323fe7['model']['document']['selection']['getAttributeKeys']());const _0x33276d=Object['keys'](_0x1a3877);for(const _0x1f4e86 of _0x323fe7['model']['document']['roots'])'$graveyard'!=_0x1f4e86['rootName']&&_0x1f4e86['isAttached']()&&!_0x33276d['includes'](_0x1f4e86['rootName'])&&_0x3d3991['detachRoot'](_0x1f4e86);for(const _0x5b94a0 of _0x33276d){let _0x2723d7=_0x323fe7['model']['document']['getRoot'](_0x5b94a0);_0x2723d7&&_0x2723d7['isAttached']()||(_0x2723d7=_0x3d3991['addRoot'](_0x5b94a0));const _0x27733b=_0x511a30[_0x5b94a0],_0x298d65=Object['keys'](_0x27733b),_0x3bc709=_0x1a3877[_0x5b94a0];for(const _0xceff99 of _0x2723d7['getAttributeKeys']())_0x298d65['includes'](_0xceff99)||_0x3d3991['removeAttribute'](_0xceff99,_0x2723d7);for(const _0x1b777c of _0x298d65)_0x3d3991['setAttribute'](_0x1b777c,_0x511a30[_0x5b94a0][_0x1b777c],_0x2723d7);_0x3d3991['remove'](_0x3d3991['createRangeIn'](_0x2723d7)),_0x3d3991['insert'](_0x323fe7['data']['parse'](_0x3bc709,_0x2723d7),_0x2723d7,0x0);}});const _0x5cfddb=R(_0x323fe7['locale'],'Restored');if(_0x237c93['name'])_0x5e1e55=-0x1==_0x237c93['name']['indexOf'](_0x5cfddb)?_0x5cfddb+':\x20'+_0x237c93['name']:_0x237c93['name'];else _0x5e1e55=_0x5cfddb+':\x20'+(_0x237c93['createdAt']['toLocaleDateString'](_0x323fe7['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x237c93['createdAt']['toLocaleTimeString'](_0x323fe7['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x43909c['saveRevision']({'name':_0x5e1e55}),_0x3f4579['isReady']=!0x0,_0x323fe7['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{nt as RestoreRevisionCommand,I as Revision,ht as RevisionHistory,v as RevisionHistoryUI,$ as RevisionHistoryUtils,h as RevisionTracker,l as RevisionViewer,m as RevisionViewerEditor,at as RevisionViewerIntegration,fi as RevisionViewerLoadingOverlay,u as RevisionViewerUI,S as RevisionsRepository,f as RevisionsSidebar,ot as ShowChangeCommand};
29
+ at();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l];}constructor(_0x1040d0){super(_0x1040d0),this['_revisionViewer']=_0x1040d0['plugins']['get'](l),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x2d7c9d=this['_revisionsRepository']['_revisions'],_0x4f7a09=this['_createRevisionActions'](),_0x4fcde2=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new pi(this['editor']['locale'],_0x2d7c9d,_0x4f7a09,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',(_0x5d71ab,_0x32c3cf)=>{_0x32c3cf['revisionViews']['on']('add',(_0x444de1,_0x4b953d)=>{_0x4b953d['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)),_0x4fcde2['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x18683c=this['_revisionsRepository']['getRevision'](0x0);if(_0x18683c){const _0x3bf4d1=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x18683c['id']);this['_revisionViewer']['compare'](_0x18683c,_0x3bf4d1);}}['_handleRevisionSelected'](_0x5b2358,_0x233c0e){const _0xa51147=this['_revisionsRepository']['getRevision'](_0x233c0e['id']),_0x27ceaf=this['_revisionsRepository']['getEarlierVisibleRevision'](_0xa51147['id']);this['_revisionViewer']['compare'](_0xa51147,_0x27ceaf);}['_handleRevisionSetName'](_0x35043b,_0x16afec){this['_revisionsRepository']['getRevision'](_0x16afec['id'])['setName'](_0x16afec['name']);}['_handleDiffChange'](_0x5094d5,_0x230e24,_0x237a7b){const _0x1b9f27=this['_revisionsRepository']['getRevisionsInDiff'](_0x237a7b);_0x1b9f27['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x1b9f27),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x1b9f27[0x0]));}['_createRevisionActions'](){const _0x1204c1=this['editor'],_0xc339b5=f['availableRevisionActions'],_0x5cf464=_0x1204c1['config']['get']('revisionHistory.revisionActions')||f['defaultRevisionActions'];if(_0x5cf464['length'])return _0x5cf464['map'](_0x3f830e=>{const _0x2875f4='string'==typeof _0x3f830e?Object['assign']({},_0xc339b5[_0x3f830e]):_0x3f830e;return _0x2875f4['action']=_0x2875f4['action']['bind'](this,_0x1204c1),_0x2875f4['isVisible']&&(_0x2875f4['isVisible']=_0x2875f4['isVisible']['bind'](this,_0x1204c1)),_0x2875f4;});}}function at(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x592888},_0x474f49)=>{const _0x3d44e6=_0x592888['get'](l),_0x346834=_0x3d44e6['repository'];let _0x281bb4=_0x3d44e6['diff']['newRevisionId'],_0x5618c4=_0x474f49['id'];_0x346834['getIndex'](_0x281bb4)>_0x346834['getIndex'](_0x5618c4)&&([_0x281bb4,_0x5618c4]=[_0x5618c4,_0x281bb4]),_0x3d44e6['compare'](_0x281bb4,_0x5618c4);},'isVisible':({plugins:_0x5c988c},_0x10490a)=>{const _0x4d003b=_0x5c988c['get'](l);return!(_0x4d003b['repository']['getRevisionsInDiff'](_0x4d003b['diff'])['length']>0x2)&&!_0x10490a['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x4752d5,{id:_0x4afe83})=>{_0x4752d5['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x4afe83);},'isVisible':({plugins:_0x34e84c},_0x90424b)=>!!_0x34e84c['get'](l)['repository']['getLaterVisibleRevision'](_0x90424b['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x27a79a},{id:_0x19b42f,revisionNameView:_0x2350ac})=>{const _0x2e7a5f=_0x27a79a['get'](l),_0x5dd4f0=_0x2e7a5f['repository']['getEarlierVisibleRevision'](_0x19b42f);_0x2e7a5f['compare'](_0x19b42f,_0x5dd4f0),_0x2350ac['focus'](),_0x2350ac['fieldView']['select']();}}};}class Z extends tt{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x365752,_0x3365b0){super(_0x365752),this['_view']=_0x3365b0,this['_toolbarConfig']=st(_0x365752['config']['get']('toolbar')),this['_elementReplacer']=new it();}get['element'](){return this['view']['element'];}['init'](_0x4648a3){const _0x3c48d6=this['editor'],_0x58696b=this['view'],_0x5d75bd=_0x3c48d6['editing']['view'],_0x57fd47=_0x58696b['editable'],_0x13882a=_0x5d75bd['document']['getRoot']();_0x57fd47['name']=_0x13882a['rootName'],_0x58696b['render']();const _0x3d3d2e=_0x57fd47['element'];this['setEditableElement'](_0x57fd47['name'],_0x3d3d2e),_0x58696b['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x5d75bd['attachDomRoot'](_0x3d3d2e),this['_elementReplacer']['replace'](_0x4648a3,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x28b4c2=this['view'],_0x36f6fa=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x36f6fa['detachDomRoot'](_0x28b4c2['editable']['name']),_0x28b4c2['destroy']();}['_initToolbar'](){const _0x3bddc0=this['view'];_0x3bddc0['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x3bddc0['stickyPanel']['limiterElement']=_0x3bddc0['element'],_0x3bddc0['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x4ff8c0})=>_0x4ff8c0),_0x3bddc0['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x3bddc0['toolbar']);}}class ii extends _0x3400fc{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x39cbbc,_0x33b001,_0x4f457d={}){super(_0x39cbbc),this['stickyPanel']=new _0x11665a(_0x39cbbc),this['toolbar']=new _0x375565(_0x39cbbc,{'shouldGroupWhenFull':_0x4f457d['shouldToolbarGroupWhenFull']}),this['_editable']=new te(_0x39cbbc,_0x33b001);}['render'](){super['render'](),this['stickyPanel']['content']['add'](this['toolbar']),this['top']['add'](this['stickyPanel']),this['main']['add'](this['editable']);}}class m extends/* #__PURE__ -- @preserve */
30
+ _0x396607(_0x39e5da){['_ui'];get['ui'](){return this['_ui'];}constructor(_0xd58209,_0xce90ea){super(_0xce90ea),this['sourceElement']=_0xd58209,this['model']['document']['createRoot']();const _0x4b49a3=new ii(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new Z(this,_0x4b49a3);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x53d127,_0x1d8c5f){const _0x4f26bb=new this(_0x53d127,_0x1d8c5f);return await _0x4f26bb['initPlugins'](),await _0x4f26bb['ui']['init'](_0x53d127),await _0x4f26bb['data']['init'](_0x4f26bb['config']['get']('initialData')||''),_0x4f26bb['fire']('ready'),_0x4f26bb;}}const d=['RevisionHistoryUI','RestrictedEditingMode'];class ht extends _0x40d69e{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x19964b){function _0x15e96d(_0x3e0e3a){return _0x3e0e3a['map'](_0xea1a02=>String['fromCharCode'](_0xea1a02))['join']('');}super(_0x19964b),this['result']='end',_0x19964b[_0x15e96d([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x15e96d([0x76,0x69,0x65,0x77])][_0x15e96d([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x15e96d([0x61,0x75,0x74,0x6f]),_0x19964b[_0x15e96d([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x15e96d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x15e96d([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x15e96d([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x15e96d([0x6f,0x6b])});}}class ct extends _0x40d69e{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h,v];}constructor(_0x2eca3d){if(super(_0x2eca3d),!this['editor']['config']['get']('revisionHistory'))throw new _0x27bd41('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x455a31=>this['_showRevisionViewer']({..._0x455a31,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0xee11ab=>this['_closeRevisionViewer'](_0xee11ab)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x510a4a=>this['_restoreRevision'](_0x510a4a)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x1f9c5e){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x1f9c5e;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x1dd018){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x1dd018);}['getRevision'](_0x49a341){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x49a341);}['getRevisions'](_0x180b42){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x180b42||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x1ca8bf=this['editor'],_0x2e24f2=_0xe8ae6a(_0x1ca8bf,d),_0x38d314=_0x1ca8bf['plugins']['get']('RevisionTracker'),_0x7c775=_0x1ca8bf['plugins']['get']('Users')['users'];return _0x2e24f2['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x2e24f2['lazyRoots'],(_0x2e24f2['plugins']['push'](ht,l,u,class extends _0x40d69e{static get['requires'](){return[l,'Users'];}['init'](){const _0x14fcc1=this['editor']['plugins']['get']('Users');for(const _0x2c34fd of _0x7c775)_0x2c34fd['isAnonymous']||_0x14fcc1['getUser'](_0x2c34fd['id'])||_0x14fcc1['addUser'](_0x2c34fd);const _0xd4b272=_0x38d314['repository']['getRevisions']();let _0xb0a333=null;const _0x17c46f=this['editor']['plugins']['get']('RevisionViewer');_0x17c46f['adapter']=_0x38d314['adapter'],_0x17c46f['bind']('isEnabled')['to'](_0x38d314),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x1ca8bf,'isReadOnly',_0x576b46=>!_0x576b46);for(const _0x5e04cc of _0xd4b272){const _0xfa6201=null===_0x5e04cc['creator'];if(_0xfa6201&&_0x5e04cc['toVersion']===_0x5e04cc['fromVersion'])continue;const _0x112c0c=_0x5e04cc['toJSON']();_0x17c46f['addRevisionData'](_0x112c0c,(_0x524ee6,_0x9a4b03,_0x42358)=>{if(_0xfa6201){if(_0xb0a333)_0xb0a333['_update'](_0x524ee6,_0x9a4b03);else{if(!_0x9a4b03){const _0x1e85a3=_0x42358['toJSON']();_0x1e85a3['id']=_0x58edc7(),_0x38d314['saveRevision'](_0x1e85a3,_0x42358['toVersion'])['then'](_0x26802e=>{_0xb0a333=_0x26802e;});}}}else _0x5e04cc['_update'](_0x524ee6,_0x9a4b03);});}}},f),_0x2e24f2);}['_enhanceShowRevisionViewerCallback'](){const _0x435f37=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x3d2ac4=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x443863=this['editor']['plugins']['get']('Autosave');await _0x443863['save']();}else await _0x3d2ac4['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x537d43=this['editor']['plugins']['get']('Dialog');_0x537d43['isOpen']&&_0x537d43['hide']();}const _0x483b5a=this['_getRevisionViewerEditorConfig']();return _0x435f37(_0x483b5a)['then'](_0x24835f=>{return(this['_viewerEditor']=_0x24835f,this['editor']['plugins']['has']('Annotations'))&&this['editor']['plugins']['get']('Annotations')['refreshVisibility'](),(this['editor']['plugins']['has']('DocumentOutline')&&(this['editor']['plugins']['get']('DocumentOutlineUI')['view']['element']['style']['display']='none'),_0x24835f);})['catch'](_0x354a6f=>(console['error'](_0x354a6f),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x50074f=this['editor']['config']['get']('revisionHistory')['closeRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.closeRevisionViewerCallback',()=>(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('DocumentOutline')&&(this['editor']['plugins']['get']('DocumentOutlineUI')['view']['element']['style']['display']=''),this['_viewerEditor']['plugins']['get']('RevisionViewer')['_cleanUp'](),_0x50074f(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x336754=this['editor']['plugins']['get']('Annotations');_0x336754['refreshVisibility'](),_0x336754['refreshPositioning']();}})));}['_showRevisionViewer'](_0x10600e){const _0x32e307=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x279b14=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x21fd48=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return m['create'](_0x21fd48,_0x10600e)['then'](_0x59276c=>(_0x279b14['style']['display']='block',_0x32e307['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x59276c));}['_closeRevisionViewer'](_0x579611){const _0x3b90fe=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x3b90fe['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x579611['destroy']();}async['_restoreRevision'](_0x2ce237){const _0x31a6fc=this['editor'],_0x2603ff=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x4adaa9=_0x31a6fc['plugins']['get']('RevisionTracker'),_0x482546=_0x31a6fc['plugins']['get']('RevisionHistoryUtils'),_0x2d99fa=_0x2603ff['repository']['getRevision'](_0x2ce237);let _0x1e75e5,_0xe3b0,_0x1c1b70;try{await _0x482546['loadRevisionData'](_0x2d99fa,this['adapter']),_0x1e75e5=_0x482546['getRevisionDocumentData'](_0x2d99fa),_0xe3b0=_0x482546['getRevisionRootsAttributes'](_0x2d99fa);}catch(_0x58e9c0){return void console['error'](_0x58e9c0);}_0x31a6fc['model']['change'](_0x4ae802=>{for(const _0x111755 of Array['from'](_0x31a6fc['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x4ae802['removeMarker'](_0x111755);}),_0x2603ff['isReady']=!0x1,_0x31a6fc['model']['enqueueChange'](_0x538e88=>{_0x538e88['setSelection'](null),_0x538e88['removeSelectionAttribute'](_0x31a6fc['model']['document']['selection']['getAttributeKeys']());const _0x4e5b89=Object['keys'](_0x1e75e5);for(const _0xf4c51d of _0x31a6fc['model']['document']['roots'])'$graveyard'!=_0xf4c51d['rootName']&&_0xf4c51d['isAttached']()&&!_0x4e5b89['includes'](_0xf4c51d['rootName'])&&_0x538e88['detachRoot'](_0xf4c51d);for(const _0x1d14ca of _0x4e5b89){let _0x1a4f8f=_0x31a6fc['model']['document']['getRoot'](_0x1d14ca);_0x1a4f8f&&_0x1a4f8f['isAttached']()||(_0x1a4f8f=_0x538e88['addRoot'](_0x1d14ca));const _0x127a5a=_0xe3b0[_0x1d14ca],_0x42f4b6=Object['keys'](_0x127a5a),_0x53b6cb=_0x1e75e5[_0x1d14ca];for(const _0x1c1fd2 of _0x1a4f8f['getAttributeKeys']())_0x42f4b6['includes'](_0x1c1fd2)||_0x538e88['removeAttribute'](_0x1c1fd2,_0x1a4f8f);for(const _0x3b56c3 of _0x42f4b6)_0x538e88['setAttribute'](_0x3b56c3,_0xe3b0[_0x1d14ca][_0x3b56c3],_0x1a4f8f);_0x538e88['remove'](_0x538e88['createRangeIn'](_0x1a4f8f)),_0x538e88['insert'](_0x31a6fc['data']['parse'](_0x53b6cb,_0x1a4f8f),_0x1a4f8f,0x0);}});const _0x417d3f=R(_0x31a6fc['locale'],'Restored');if(_0x2d99fa['name'])_0x1c1b70=-0x1==_0x2d99fa['name']['indexOf'](_0x417d3f)?_0x417d3f+':\x20'+_0x2d99fa['name']:_0x2d99fa['name'];else _0x1c1b70=_0x417d3f+':\x20'+(_0x2d99fa['createdAt']['toLocaleDateString'](_0x31a6fc['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x2d99fa['createdAt']['toLocaleTimeString'](_0x31a6fc['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x4adaa9['saveRevision']({'name':_0x1c1b70}),_0x2603ff['isReady']=!0x0,_0x31a6fc['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{nt as RestoreRevisionCommand,I as Revision,ct as RevisionHistory,v as RevisionHistoryUI,$ as RevisionHistoryUtils,h as RevisionTracker,l as RevisionViewer,m as RevisionViewerEditor,ht as RevisionViewerIntegration,wi as RevisionViewerLoadingOverlay,u as RevisionViewerUI,S as RevisionsRepository,f as RevisionsSidebar,rt as ShowChangeCommand};