@ckeditor/ckeditor5-revision-history 46.0.2 → 46.0.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (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 _0x289903,uid as _0x20586a,Collection as _0x59f5e7,logWarning as _0x3c3309,FocusTracker as _0x32e82f,KeystrokeHandler as _0x2ae060,scrollViewportToShowTarget as _0x2169a9,ResizeObserver as ot,ElementReplacer as it,CKEditorError as _0x58ad15}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x16a120,set as _0x5293ee,unset as _0x524457,isEqual as _0x7fe971}from'es-toolkit/compat';import{Plugin as _0x449360,PendingActions as _0x4a1cef,Command as _0x23ffae,ElementApiMixin as _0x4ce360,Editor as _0x3c7537}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x3b5410,getMarkerDomElement as _0x2c7553,ConfirmMixin as _0x273059,sanitizeEditorConfig as _0x2b58ff}from'ckeditor5-collaboration/dist/index.js';import{ViewContainerElement as _0x29b6ab,ViewAttributeElement as _0xcdec33,ViewEmptyElement as _0x11aef2,ViewRawElement as _0x47b735,ViewUIElement as _0x3d7a67,ViewDocumentFragment as _0x1bd535,ViewText as _0x112f9b,ViewElement as _0x3d0f2b,ModelElement as _0x4d1ea2,ModelRange as _0x4be064,ModelPosition as _0x15ef30,ModelDocumentFragment as _0x705efd,ModelText as _0x2f22b4}from'@ckeditor/ckeditor5-engine/dist/index.js';import{IconHistory as _0x507409,IconChevronUp as _0x72b043,IconChevronDown as _0x365fad,IconUndo as _0x46ae4d,IconUser as _0x4ca76a,IconThreeVerticalDots as _0x58a09d}from'@ckeditor/ckeditor5-icons/dist/index.js';import{CssTransitionDisablerMixin as _0x598ba2,View as _0x54ee3c,submitHandler as _0x2738e4,LabeledFieldView as et,createLabeledInputText as ti,createDropdown as _0x3b7ce8,ListView as _0x171f64,ListItemView as _0x5d7c86,ButtonView as _0x29e09a,MenuBarMenuView as _0x51e6c0,MenuBarMenuListView as _0x338638,MenuBarMenuListItemView as _0x517569,MenuBarMenuListItemButtonView as _0xcd3c27,ContextualBalloon as _0x330ba8,ToolbarSeparatorView as _0x27cc40,IconView as _0x5f31d5,addListToDropdown as _0x928c1c,UIModel as to,EditorUI as tt,normalizeToolbarConfig as st,BoxedEditorUIView as _0x3f26bf,StickyPanelView as _0x872989,ToolbarView as _0x1972ec,InlineEditableUIView as te}from'@ckeditor/ckeditor5-ui/dist/index.js';import{DateTime as _0x53eb6e}from'luxon';class I extends/* #__PURE__ -- @preserve */
24
- _0x289903(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0xf6a543){super(),this['id']=_0xf6a543['id']||_0x20586a(),this['creator']=_0xf6a543['creator']||null,this['authors']=_0xf6a543['authors']||[],this['diffData']=_0xf6a543['diffData']||null,this['toVersion']=_0xf6a543['toVersion']||0x0,this['fromVersion']=_0xf6a543['fromVersion']||0x0,this['set']('name',_0xf6a543['name']||''),this['set']('createdAt',_0xf6a543['createdAt']||new Date()),this['set']('attributes',_0xf6a543['attributes']||{});}['setName'](_0x53cb5e){this['_update']({'name':_0x53cb5e});}['setAttribute'](_0x5d9b31,_0x55d40a){const _0x152e1a=_0x16a120(this['attributes']);_0x5293ee(_0x152e1a,_0x5d9b31,_0x55d40a),this['_update']({'attributes':_0x152e1a});}['removeAttribute'](_0x14c66f){const _0x2285cc=_0x16a120(this['attributes']);_0x524457(_0x2285cc,_0x14c66f),this['_update']({'attributes':_0x2285cc});}['_update'](_0x17e9a4,_0x38e97c=!0x1){let _0x3e68e1=!0x1;const _0x5bd3b6={'id':this['id']},_0x825be1=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x5f31d1 of _0x825be1){const _0x23bfdb=_0x17e9a4[_0x5f31d1];void 0x0!==_0x23bfdb&&_0x23bfdb!==this[_0x5f31d1]&&(this[_0x5f31d1]=_0x23bfdb,_0x5bd3b6[_0x5f31d1]=_0x23bfdb,_0x3e68e1=!0x0);}_0x3e68e1&&(_0x5bd3b6['authors']&&(_0x5bd3b6['authorsIds']=_0x5bd3b6['authors']['map'](_0x20f5b1=>_0x20f5b1['id']),delete _0x5bd3b6['authors']),this['fire']('_update',_0x5bd3b6,_0x38e97c));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x4c7817=>_0x4c7817['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class S extends _0x449360{['_revisions'];static get['requires'](){return[_0x3b5410];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x43b68b){super(_0x43b68b),this['_revisions']=new _0x59f5e7();}['afterInit'](){!async function(_0x272fbe){const _0x6a7f68=_0x268536([0x7a,0x33,0x4a,0x55,0x66,0x53,0x61,0x78,0x43,0x71,0x4f,0x41,0x39,0x54,0x69,0x4c,0x49,0x73,0x37,0x63,0x6f,0x34,0x4e,0x6e,0x31,0x64,0x6b,0x36,0x56,0x74,0x35,0x46,0x4d,0x68,0x67,0x52,0x6c,0x38,0x30,0x77,0x75,0x45,0x79,0x59,0x6d,0x42,0x70,0x32,0x48,0x72,0x76,0x47,0x65,0x6a,0x5a,0x50,0x51,0x4b,0x58,0x44,0x57,0x62]),_0x3ce6b7=0xeb829,_0x46d11b=0x70bb0800,_0x189590=0x70bc78e8^_0x46d11b,_0x2275fa=window[_0x268536([0x44,0x61,0x74,0x65])][_0x268536([0x6e,0x6f,0x77])](),_0xbcee5a=_0x272fbe[_0x268536([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x4b3486=new window[(_0x268536([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x13d080=>{_0xbcee5a[_0x268536([0x6f,0x6e,0x63,0x65])](_0x268536([0x72,0x65,0x61,0x64,0x79]),_0x13d080);}),_0x4e9f92={[_0x268536([0x6b,0x74,0x79])]:_0x268536([0x45,0x43]),[_0x268536([0x75,0x73,0x65])]:_0x268536([0x73,0x69,0x67]),[_0x268536([0x63,0x72,0x76])]:_0x268536([0x50,0x2d,0x32,0x35,0x36]),[_0x268536([0x78])]:_0x268536([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]),[_0x268536([0x79])]:_0x268536([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]),[_0x268536([0x61,0x6c,0x67])]:_0x268536([0x45,0x53,0x32,0x35,0x36])},_0x142784=_0xbcee5a[_0x268536([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x268536([0x67,0x65,0x74])](_0x268536([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x533aa7(){let _0x5c7fe9,_0x352d0a=null,_0x337f2f=null;try{if(_0x142784==_0x268536([0x47,0x50,0x4c]))return _0x268536([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x5c7fe9=_0x299491(),!_0x5c7fe9)return _0x268536([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x5c7fe9[_0x268536([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x337f2f=_0x2a07a1(_0x5c7fe9[_0x268536([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x5c7fe9[_0x268536([0x6a,0x74,0x69])])),await _0x48dcb0()?_0x5cfa1b()?_0x1dcdda()?_0x268536([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x1146e9()?(_0x5c7fe9[_0x268536([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x268536([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x352d0a=_0x334c9f(_0x268536([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x5c7fe9[_0x268536([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x268536([0x74,0x72,0x69,0x61,0x6c])&&(_0x352d0a=_0x334c9f(_0x268536([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x57d6bc()):_0x268536([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x268536([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x268536([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x268536([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x1dcdda(){const _0x16e62e=[_0x268536([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x268536([0x74,0x72,0x69,0x61,0x6c])][_0x268536([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x5c7fe9[_0x268536([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x2275fa/0x3e8:0xe10*_0x189590;return _0x5c7fe9[_0x268536([0x65,0x78,0x70])]<_0x16e62e;}function _0x5cfa1b(){const _0x18c2f9=_0x5c7fe9[_0x268536([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x18c2f9)return!0x1;if(_0x18c2f9[_0x268536([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x268536([0x2a])))return!0x0;if(_0x18c2f9[_0x268536([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x268536([0x52,0x48])))return!0x0;if(_0x18c2f9[_0x268536([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x268536([0x52,0x52,0x48]))){if(_0x351e7f())return!0x0;if(_0x55a3c5()||_0x422eb2())return!0x0;}return!0x1;}function _0x1146e9(){const _0x475afe=_0x5c7fe9[_0x268536([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x475afe||0x0==_0x475afe[_0x268536([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x141787}=new URL(window[_0x268536([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x475afe[_0x268536([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x141787))return!0x0;const _0x333ca2=_0x141787[_0x268536([0x73,0x70,0x6c,0x69,0x74])](_0x268536([0x2e]));return _0x475afe[_0x268536([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x5c676f=>_0x5c676f[_0x268536([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x268536([0x2a])))[_0x268536([0x6d,0x61,0x70])](_0x4874fd=>_0x4874fd[_0x268536([0x73,0x70,0x6c,0x69,0x74])](_0x268536([0x2e])))[_0x268536([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x4efe4e=>_0x4efe4e[_0x268536([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x333ca2[_0x268536([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x268536([0x6d,0x61,0x70])](_0xc30b0c=>Array(_0x333ca2[_0x268536([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0xc30b0c[_0x268536([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x268536([0x66,0x69,0x6c,0x6c])](_0xc30b0c[0x0]===_0x268536([0x2a])?_0x268536([0x2a]):'')[_0x268536([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0xc30b0c))[_0x268536([0x73,0x6f,0x6d,0x65])](_0x1259b8=>_0x333ca2[_0x268536([0x65,0x76,0x65,0x72,0x79])]((_0x1f9a5e,_0x49a3d9)=>_0x1259b8[_0x49a3d9]===_0x1f9a5e||_0x1259b8[_0x49a3d9]===_0x268536([0x2a])));}function _0x57d6bc(){return _0x352d0a&&_0x337f2f?new window[(_0x268536([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x392819,_0x5d39ae)=>{_0x352d0a[_0x268536([0x74,0x68,0x65,0x6e])](_0x392819,_0x5d39ae),_0x337f2f[_0x268536([0x74,0x68,0x65,0x6e])](_0x22b33e=>{_0x22b33e!=_0x268536([0x56,0x61,0x6c,0x69,0x64])&&_0x392819(_0x22b33e);},_0x5d39ae);}):_0x352d0a||_0x337f2f||_0x268536([0x56,0x61,0x6c,0x69,0x64]);}}function _0x2a07a1(_0x57f530,_0x490d3f){return new window[(_0x268536([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x4a00a6=>{if(_0x44570b())return _0x4a00a6(_0x268536([0x56,0x61,0x6c,0x69,0x64]));_0x251144(),_0xbcee5a[_0x268536([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x268536([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x32c9ec=!0x1;const _0x35c41d=_0x20586a();function _0x747b26(_0x5abc46){return!!_0x5abc46&&(typeof _0x5abc46===_0x268536([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x5abc46===_0x268536([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x5abc46[_0x268536([0x74,0x68,0x65,0x6e])]===_0x268536([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x5abc46[_0x268536([0x63,0x61,0x74,0x63,0x68])]===_0x268536([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x2c21e3(_0x22ce53){_0x1de68d(_0x22ce53)[_0x268536([0x74,0x68,0x65,0x6e])](_0x50b781=>{if(!_0x50b781||_0x50b781[_0x268536([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x268536([0x6f,0x6b]))return _0x268536([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x4962b4(_0x53fca3(_0x35c41d+_0x490d3f))!=_0x50b781[_0x268536([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x268536([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x268536([0x56,0x61,0x6c,0x69,0x64]);})[_0x268536([0x74,0x68,0x65,0x6e])](_0x1b2180=>(_0x11d362(),_0x1b2180),()=>{const _0x36f89=_0x567cbc();return null==_0x36f89?(_0x11d362(),_0x268536([0x56,0x61,0x6c,0x69,0x64])):_0x268536(_0x2275fa-_0x36f89>(0x54b78c00^_0x46d11b)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x268536([0x74,0x68,0x65,0x6e])](_0x4a00a6)[_0x268536([0x63,0x61,0x74,0x63,0x68])](()=>{_0x4a00a6(_0x268536([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x45d821=0x708de680^_0x46d11b;function _0x11d362(){const _0x55c4ca=_0x268536([0x6c,0x6c,0x63,0x74,0x2d])+_0x4962b4(_0x53fca3(_0x57f530)),_0x11b0ca=_0xcef403(_0x4962b4(window[_0x268536([0x4d,0x61,0x74,0x68])][_0x268536([0x63,0x65,0x69,0x6c])](_0x2275fa/_0x45d821)));window[_0x268536([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x268536([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x55c4ca,_0x11b0ca);}function _0x567cbc(){const _0x30a3f7=_0x268536([0x6c,0x6c,0x63,0x74,0x2d])+_0x4962b4(_0x53fca3(_0x57f530)),_0x18fe40=window[_0x268536([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x268536([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x30a3f7);return _0x18fe40?window[_0x268536([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0xcef403(_0x18fe40),0x10)*_0x45d821:null;}function _0x1de68d(_0x6d0b87){return new window[(_0x268536([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x42fe3e,_0xf698b7)=>{_0x6d0b87[_0x268536([0x74,0x68,0x65,0x6e])](_0x42fe3e,_0xf698b7),window[_0x268536([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0xf698b7,0x70badcc0^_0x46d11b);});}}_0xbcee5a[_0x268536([0x6f,0x6e])](_0x268536([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x4e6b01,_0x5ddc48)=>{if(_0x5ddc48[0x0]!=_0x57f530)return _0x4a00a6(_0x268536([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x5ddc48[0x1]={..._0x5ddc48[0x1],[_0x268536([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x35c41d};},{[_0x268536([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x268536([0x68,0x69,0x67,0x68])}),_0xbcee5a[_0x268536([0x6f,0x6e])](_0x268536([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x1136e6=>{_0x747b26(_0x1136e6[_0x268536([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x32c9ec=!0x0,_0x2c21e3(_0x1136e6[_0x268536([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x268536([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x268536([0x6c,0x6f,0x77])}),_0x4b3486[_0x268536([0x74,0x68,0x65,0x6e])](()=>{_0x32c9ec||_0x4a00a6(_0x268536([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x44570b(){return _0xbcee5a[_0x268536([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x268536([0x76,0x69,0x65,0x77])][_0x268536([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x268536([0x61,0x75,0x74,0x6f]);}function _0x251144(){_0xbcee5a[_0x268536([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x268536([0x76,0x69,0x65,0x77])][_0x268536([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x268536([0x61,0x75,0x74,0x6f]);}}function _0x334c9f(_0x7ab140){const _0x4d5883=[new window[(_0x268536([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x59c14a=>setTimeout(_0x59c14a,0x70b236cc^_0x46d11b)),_0x4b3486[_0x268536([0x74,0x68,0x65,0x6e])](()=>new window[(_0x268536([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x59e9ac=>{const _0x228167=0x70bb0807^_0x46d11b,_0x2a3685=_0x272fbe[_0x268536([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x590d40(){_0x2a3685[_0x268536([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x228167&&_0x59e9ac();}_0x590d40(),_0x2a3685[_0x268536([0x6f,0x6e])](_0x268536([0x61,0x64,0x64]),_0x590d40);})),new window[(_0x268536([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2c0831=>{function _0x39c548(){for(const _0x597688 in window)if(window[_0x268536([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x268536([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x597688))&&window[_0x597688]==_0x3ce6b7)return _0x2c0831();_0xbcee5a[_0x268536([0x73,0x74,0x61,0x74,0x65])]!=_0x268536([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x268536([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x39c548,0x70bb1b88^_0x46d11b);}_0x258bfe(_0x268536([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x39c548();})];return window[_0x268536([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x268536([0x72,0x61,0x63,0x65])](_0x4d5883)[_0x268536([0x74,0x68,0x65,0x6e])](()=>_0x7ab140);}async function _0x59c849(){if(await _0x4b3486,_0x258bfe(_0x268536([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x2b4976=_0x272fbe[_0x268536([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x1d4501=_0x272fbe[_0x268536([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])](_0x2b4976[_0x268536([0x69,0x64])]),_0x426089=_0x1912c9(_0x268536([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x426089[_0x268536([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x2b4976['id'],_0x1d4501?_0x1d4501['id']:null,!0x0),_0x426089[_0x268536([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x268536([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x426089[_0x268536([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x426089[_0x268536([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x218d09,void(_0x426089[_0x268536([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x218d09);}if(_0x258bfe(_0x268536([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x416593=_0x1912c9(_0x268536([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x416593[_0x268536([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x268536([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x416593[_0x268536([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x416593[_0x268536([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x218d09,_0x416593[_0x268536([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x218d09;}_0xbcee5a[_0x268536([0x6d,0x6f,0x64,0x65,0x6c])][_0x268536([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x218d09,_0xbcee5a[_0x268536([0x6d,0x6f,0x64,0x65,0x6c])][_0x268536([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x218d09,_0xbcee5a[_0x268536([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x268536([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x351e7f(){return _0x258bfe(_0x268536([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x1912c9(_0x268536([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x268536([0x73,0x74,0x61,0x74,0x65])]==_0x268536([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x55a3c5(){return _0x258bfe(_0x268536([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 _0x422eb2(){return _0x258bfe(_0x268536([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x27429c(_0x36356b){const _0x3ea988=_0x2f27ea();_0xbcee5a[_0x3ea988]=_0x268536([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])+_0x36356b,_0x36356b[_0x268536([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x268536([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x2f27ea()]=_0x3ce6b7),_0x36356b!=_0x268536([0x56,0x61,0x6c,0x69,0x64])&&_0x59c849();}function _0x2f27ea(){const _0x48d195=window[_0x268536([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x268536([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x268536([0x6e,0x6f,0x77])]())[_0x268536([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x268536([0x2e]),'');let _0x35cde5=_0x268536([0x7a]);for(let _0x501c29=0x0;_0x501c29<_0x48d195[_0x268536([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x501c29+=0x2){let _0x29153f=window[_0x268536([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x48d195[_0x268536([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x501c29,_0x501c29+0x2));_0x29153f>=_0x6a7f68[_0x268536([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x29153f-=_0x6a7f68[_0x268536([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x35cde5+=_0x6a7f68[_0x29153f];}return _0x35cde5;}function _0x299491(){const _0x2c4bd5=_0x142784[_0x268536([0x73,0x70,0x6c,0x69,0x74])](_0x268536([0x2e]));if(0x3!=_0x2c4bd5[_0x268536([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x267ba0(_0x2c4bd5[0x1]);function _0x267ba0(_0x1f93b8){const _0x2cc257=_0x92352e(_0x1f93b8);return _0x2cc257&&_0x59ba0c()?_0x2cc257:null;function _0x59ba0c(){const _0x330ebf=_0x2cc257[_0x268536([0x6a,0x74,0x69])],_0x3c4663=window[_0x268536([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x330ebf[_0x268536([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x330ebf[_0x268536([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x51f200={..._0x2cc257,[_0x268536([0x6a,0x74,0x69])]:_0x330ebf[_0x268536([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x330ebf[_0x268536([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x51f200[_0x268536([0x76,0x63])],_0x53fca3(_0x51f200)==_0x3c4663;}}}async function _0x48dcb0(){let _0x21e875=!0x0;try{const _0x17a18e=_0x142784[_0x268536([0x73,0x70,0x6c,0x69,0x74])](_0x268536([0x2e])),[_0x2b2b9e,_0x193879,_0x5148c2]=_0x17a18e;return _0x18648b(_0x2b2b9e),await _0x4b8e81(_0x2b2b9e,_0x193879,_0x5148c2),_0x21e875;}catch{return!0x1;}function _0x18648b(_0xefcf4e){const _0x1d6828=_0x92352e(_0xefcf4e);_0x1d6828&&_0x1d6828[_0x268536([0x61,0x6c,0x67])]==_0x268536([0x45,0x53,0x32,0x35,0x36])||(_0x21e875=!0x1);}async function _0x4b8e81(_0x14e227,_0xd5eca6,_0xbbad2e){const _0x25e84a=window[_0x268536([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x268536([0x66,0x72,0x6f,0x6d])](_0x71010b(_0xbbad2e),_0x11c0d1=>_0x11c0d1[_0x268536([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x9c2c41=new window[(_0x268536([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x268536([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x14e227+_0x268536([0x2e])+_0xd5eca6),_0x251522=window[_0x268536([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x268536([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x251522)return;const _0x43c0e9=await _0x251522[_0x268536([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x268536([0x6a,0x77,0x6b]),_0x4e9f92,{[_0x268536([0x6e,0x61,0x6d,0x65])]:_0x268536([0x45,0x43,0x44,0x53,0x41]),[_0x268536([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x268536([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x268536([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x251522[_0x268536([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x268536([0x6e,0x61,0x6d,0x65])]:_0x268536([0x45,0x43,0x44,0x53,0x41]),[_0x268536([0x68,0x61,0x73,0x68])]:{[_0x268536([0x6e,0x61,0x6d,0x65])]:_0x268536([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x43c0e9,_0x25e84a,_0x9c2c41)||(_0x21e875=!0x1);}}function _0x92352e(_0x1fca64){return _0x1fca64[_0x268536([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x268536([0x65,0x79]))?JSON[_0x268536([0x70,0x61,0x72,0x73,0x65])](_0x71010b(_0x1fca64)):null;}function _0x71010b(_0x53a0d8){return window[_0x268536([0x61,0x74,0x6f,0x62])](_0x53a0d8[_0x268536([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x268536([0x2b]))[_0x268536([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x268536([0x2f])));}function _0x53fca3(_0x4b0b9f){let _0x4125cc=0x1505;function _0x4c6c1d(_0x53babc){for(let _0x5a181f=0x0;_0x5a181f<_0x53babc[_0x268536([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x5a181f++){const _0x43637a=_0x53babc[_0x268536([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x5a181f);_0x4125cc=(_0x4125cc<<0x5)+_0x4125cc+_0x43637a,_0x4125cc&=_0x4125cc;}}function _0x39779e(_0x4bc6ec){Array[_0x268536([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x4bc6ec)?_0x4bc6ec[_0x268536([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x39779e):_0x4bc6ec&&typeof _0x4bc6ec==_0x268536([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x268536([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x4bc6ec)[_0x268536([0x73,0x6f,0x72,0x74])]()[_0x268536([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x5950fc,_0xe78b3c])=>{_0x4c6c1d(_0x5950fc),_0x39779e(_0xe78b3c);}):_0x4c6c1d(window[_0x268536([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x4bc6ec));}return _0x39779e(_0x4b0b9f),_0x4125cc>>>0x0;}function _0x4962b4(_0xe5133c){return _0xe5133c[_0x268536([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x268536([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x268536([0x30]));}function _0xcef403(_0x1756bd){return _0x1756bd[_0x268536([0x73,0x70,0x6c,0x69,0x74])]('')[_0x268536([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x268536([0x6a,0x6f,0x69,0x6e])]('');}function _0x258bfe(_0x3dd667){return _0xbcee5a[_0x268536([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x268536([0x68,0x61,0x73])](_0x3dd667);}function _0x1912c9(_0x3c7a62){return _0xbcee5a[_0x268536([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x268536([0x67,0x65,0x74])](_0x3c7a62);}function _0x218d09(){}function _0x268536(_0xc13e05){return _0xc13e05['map'](_0x3e0de9=>String['fromCharCode'](_0x3e0de9))['join']('');}_0x27429c(await _0x533aa7());}(this);}['createRevision'](_0x2066c7){const _0x4167df=this['editor']['plugins']['get']('Users');return new I({'id':_0x2066c7['id'],'name':_0x2066c7['name'],'creator':_0x2066c7['creatorId']?_0x4167df['getUser'](_0x2066c7['creatorId']):null,'diffData':_0x2066c7['diffData']||_0x2066c7['data'],'authors':_0x2066c7['authorsIds']['map'](_0x15f19e=>_0x4167df['getUser'](_0x15f19e)),'createdAt':new Date(_0x2066c7['createdAt']),'attributes':_0x2066c7['attributes'],'fromVersion':_0x2066c7['fromVersion'],'toVersion':_0x2066c7['toVersion']});}['addRevision'](_0x1018ef,_0x571930=0x0){this['_revisions']['add'](_0x1018ef,_0x571930);}['getRevision'](_0x215627){return this['_revisions']['get'](_0x215627);}['getRevisions'](_0x203afe={'toJSON':!0x1}){const _0x12a0a0=Array['from'](this['_revisions']);return _0x12a0a0['reverse'](),_0x203afe['toJSON']?_0x12a0a0['map'](_0xb6b8d0=>_0xb6b8d0['toJSON']()):_0x12a0a0;}['getIndex'](_0x423c61){return this['_revisions']['getIndex'](_0x423c61);}['getEarlierVisibleRevision'](_0x4b5f73){const [,_0x55cdf1]=this['getRevisionsIterator'](_0x4b5f73,{'direction':'earlier'});return _0x55cdf1;}['getLaterVisibleRevision'](_0x353732){const [,_0x47b21d]=this['getRevisionsIterator'](_0x353732,{'direction':'later'});return _0x47b21d;}['getRevisionsInDiff'](_0x58e76b){const _0x1d1e07=[];for(const _0x16b2aa of this['getRevisionsIterator'](_0x58e76b['newRevisionId']))if(_0x1d1e07['push'](_0x16b2aa),_0x16b2aa['id']===_0x58e76b['oldRevisionId'])break;return _0x1d1e07;}*['getRevisionsIterator'](_0x20dc14,{direction:_0x581997='earlier',filter:_0x16315f=()=>!0x0}={}){const _0x1d4157='earlier'===_0x581997?0x1:-0x1;let _0x45bc7b=this['_revisions']['get'](_0x20dc14),_0x3674ca=this['getIndex'](_0x45bc7b);for(yield _0x45bc7b;_0x45bc7b;){if(_0x3674ca+=_0x1d4157,_0x45bc7b=this['getRevision'](_0x3674ca),!_0x45bc7b)return;_0x16315f(_0x45bc7b)&&(yield _0x45bc7b);}}}class $ extends _0x449360{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x29b6ab,'c'],[_0xcdec33,'a'],[_0x11aef2,'e'],[_0x47b735,'r'],[_0x3d7a67,'u']]);['_typeCharToViewClass']=new Map([['c',_0x29b6ab],['a',_0xcdec33],['e',_0x11aef2],['r',_0x47b735],['u',_0x3d7a67]]);async['loadRevisionData'](_0x432240,_0x5f2574){if(_0x432240['diffData']||!_0x5f2574)return;const _0x118c13=this['editor']['config']['get']('collaboration.channelId'),_0x4a5534=await _0x5f2574['getRevision']({'channelId':_0x118c13,'revisionId':_0x432240['id']});_0x432240['diffData']=_0x4a5534['diffData'];}['getRevisionDocumentData'](_0x522a9b){const _0x98d720={};for(const _0x1538a5 in _0x522a9b['diffData']){if(_0x522a9b['diffData'][_0x1538a5]['attachChange']&&!_0x522a9b['diffData'][_0x1538a5]['attachChange']['isAttached'])continue;const _0x1de857=this['_removeRevisionMarkers'](JSON['parse'](_0x522a9b['diffData'][_0x1538a5]['insertions'])),_0x4d38a0=this['editor']['editing']['view']['document'],_0x4dbc9d=new _0x1bd535(_0x4d38a0,_0x1de857['map'](_0x2e2fd6=>this['_getViewFromDiffObj'](_0x2e2fd6,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x98d720[_0x1538a5]=this['editor']['data']['processor']['toData'](_0x4dbc9d),this['editor']['data']['processor']['useFillerType']('default');}return _0x98d720;}['getRevisionRootsAttributes'](_0x5a0224){const _0x25ff95={};for(const _0x1296c3 in _0x5a0224['diffData'])_0x5a0224['diffData'][_0x1296c3]['attachChange']&&!_0x5a0224['diffData'][_0x1296c3]['attachChange']['isAttached']||(_0x25ff95[_0x1296c3]=_0x5a0224['diffData'][_0x1296c3]['attributesAfter']||{});return _0x25ff95;}['_getTypeCharForViewElement'](_0x524a2f){return this['_viewClassToTypeChar']['get'](_0x524a2f['constructor']);}['_getViewFromDiffObj'](_0x287730,_0x3767c9){const _0x17df0b=this['editor']['editing']['view']['document'];if('string'==typeof _0x287730)return new _0x112f9b(_0x17df0b,_0x287730);{let _0x147712,_0x73cb51;_0x73cb51='u'==_0x287730['type']||'r'==_0x287730['type']?[]:_0x287730['children']['map'](_0x2d36d0=>this['_getViewFromDiffObj'](_0x2d36d0,_0x3767c9));const _0x12711d=this['_typeCharToViewClass']['get'](_0x287730['type'])||_0x3d0f2b,_0x38813d=this['editor']['data']['htmlProcessor']['domConverter'];if(_0x147712=new _0x12711d(_0x17df0b,_0x287730['name'],_0x287730['attributes'],_0x73cb51),'u'==_0x287730['type']&&_0x287730['children'][0x0]){const _0x3ad07f=_0x287730['children'][0x0];if(_0x147712['render']=function(_0xe459f9){const _0x2b258a=_0xe459f9['createElement']('div');return _0x2b258a['innerHTML']=_0x3ad07f,_0x2b258a['childNodes'][0x0];},_0x3767c9){const _0x3f82c0=new _0x1bd535(_0x17df0b);_0x3f82c0['_appendChild'](_0x147712);const _0x5b261c=Array['from'](_0x38813d['viewChildrenToDom'](_0x3f82c0,{'bind':!0x1})),_0x568413=_0x38813d['domDocument']['createElement']('div');_0x568413['append'](..._0x5b261c),_0x147712=Array['from'](_0x38813d['domChildrenToView'](_0x568413))[0x0];}}else{if('r'==_0x287730['type']&&_0x287730['children'][0x0]){const _0x17c522=_0x287730['children'][0x0];if(_0x147712['render']=function(_0x4c18c0){_0x4c18c0['innerHTML']=_0x17c522;},_0x3767c9){const _0x54e0a7=new _0x1bd535(_0x17df0b);_0x54e0a7['_appendChild'](_0x147712);const _0x20193e=Array['from'](_0x38813d['viewChildrenToDom'](_0x54e0a7,{'bind':!0x1})),_0x2d7097=_0x38813d['domDocument']['createElement']('div');_0x2d7097['append'](..._0x20193e);const _0x280c75=Array['from'](_0x38813d['domChildrenToView'](_0x2d7097));_0x280c75['length']>0x1?_0x147712['_appendChild'](_0x280c75):_0x147712=_0x280c75[0x0];}}}if(_0x287730['customProperties']){for(const [_0x336dfb,_0x3b9d0c]of _0x287730['customProperties'])_0x147712['_setCustomProperty'](_0x336dfb,_0x3b9d0c);}const _0x5cb477=void 0x0===_0x287730['fillerOffset']?null:_0x287730['fillerOffset'];return null!==_0x5cb477&&(_0x147712['getFillerOffset']=()=>_0x5cb477),_0x147712;}}['_makeModelFromViewString'](_0x2f5f87){const _0x368176=JSON['parse'](_0x2f5f87),_0x3414c7=this['editor']['editing']['view']['document'],_0x2499bb=new _0x1bd535(_0x3414c7,_0x368176['map'](_0x1feea4=>this['_getViewFromDiffObj'](_0x1feea4,!0x0)));return this['editor']['data']['toModel'](_0x2499bb);}['_removeRevisionMarkers'](_0x17a507){return(_0x17a507=_0x17a507['filter'](_0x4c399e=>!_0x4c399e['name']||'revision-start'!==_0x4c399e['name']&&'revision-end'!==_0x4c399e['name']))['forEach'](_0xb7085c=>{'string'!=typeof _0xb7085c&&(_0xb7085c['children']=this['_removeRevisionMarkers'](_0xb7085c['children']),_0xb7085c['attributes']=_0xb7085c['attributes']['filter'](_0x2ba431=>!_0x2ba431[0x0]['startsWith']('data-revision-')));}),_0x17a507;}}function R(_0x552d5e,_0xea2663,_0x422815){const t=_0x552d5e['t'];switch(_0xea2663){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'},_0x422815);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x422815);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 _0x449360{['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[_0x3b5410,S,$,_0x4a1cef];}constructor(_0xaf37fe){super(_0xaf37fe),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 _0x50fb44=_0x20586a();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x50fb44},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 _0x1e4230=this['repository']['getRevision'](0x0),_0x122d7c=_0x1e4230&&null===_0x1e4230['creator']?_0x1e4230:null;if(this['_continueCurrentRevision']=!!_0x122d7c&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x4c19bf=this['_source']['getCurrentRevisionId'](),_0x338756=this['repository']['getRevision'](_0x4c19bf);if(_0x338756)this['_startingVersion']=_0x338756['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x33e562=this['_source']['history']['_operations']['find'](_0x983944=>!_0x983944['_isInit']),_0x33bf9e=_0x33e562?_0x33e562['baseVersion']:this['_source']['history']['version'];_0x1e4230?(_0x1e4230['toVersion']<_0x33bf9e&&_0x1e4230['_update']({'toVersion':_0x33bf9e}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x122d7c['id'],this['_startingVersion']=_0x122d7c['fromVersion']):(this['_startingVersion']=_0x1e4230['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x33bf9e,this['_continueCurrentRevision']=!0x1);}}else _0x122d7c&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x122d7c['toVersion'],this['editor']['model']['document']['history']['version']),_0x122d7c['fromVersion']===_0x122d7c['toVersion']?(0x0!==_0x122d7c['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x122d7c['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x122d7c['id'],this['_startingVersion']=_0x122d7c['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',_0x480d3f=>!_0x480d3f),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x2dda83=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0xcdd391;for(const _0x29d601 in _0x2dda83){const _0x5abad2=_0x29d601,_0x311eec=_0x2dda83[_0x5abad2];if('revisionHistoryLicenseKeyValid'==_0x311eec||'revisionHistoryLicenseKeyInvalid'==_0x311eec||'revisionHistoryLicenseKeyExpired'==_0x311eec||'revisionHistoryLicenseKeyDomainLimit'==_0x311eec||'revisionHistoryLicenseKeyNotAllowed'==_0x311eec||'revisionHistoryLicenseKeyEvaluationLimit'==_0x311eec||'revisionHistoryLicenseKeyTrialLimit'==_0x311eec||'revisionHistoryLicenseKeyUsageLimit'==_0x311eec){delete _0x2dda83[_0x5abad2],_0xcdd391=_0x311eec,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0xcdd391&&_0x2dda83['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0xcdd391&&_0x2dda83['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0xcdd391&&_0x2dda83['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0xcdd391&&_0x2dda83['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0xcdd391&&_0x2dda83['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0xcdd391&&_0x2dda83['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0xcdd391&&_0x2dda83['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x22fadb=this['repository']['getRevision'](0x0),_0xb498e6=await this['getRevisionDocumentData'](_0x22fadb),_0x568d3e=await this['getRevisionRootsAttributes'](_0x22fadb);this['_replaceEditorDataWithRevisionData'](_0xb498e6,_0x568d3e);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x230c1d){this['_source']=_0x230c1d;}async['update'](){const _0x39c04c=await this['_source']['getLatestVersion']();if(_0x39c04c>this['currentRevision']['toVersion']){await this['_loadState']();const _0x2d9481=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x39c04c});_0x2d9481['authors']=_0x2d9481['authorsIds']['map'](_0x40aa9d=>this['editor']['plugins']['get']('Users')['getUser'](_0x40aa9d)),this['currentRevision']['_update'](_0x2d9481);}}async['saveRevision'](_0x21dea5={},_0x52833b=null){const _0x6e3b7b=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x52833b>this['currentRevision']['toVersion']&&(_0x52833b=null),null===_0x52833b&&(_0x52833b=await this['_source']['getLatestVersion']());const _0x9e95e4=this['_getFromVersion'](_0x52833b),_0x418f76=this['buildRevisionData']({'from':_0x9e95e4,'to':_0x52833b});if(this['currentRevision']['toVersion']<_0x52833b){const _0x655dad=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x52833b,'to':_0x52833b});_0x655dad['authors']=[],_0x655dad['authorsIds']=[],_0x655dad['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x655dad,!0x0),delete _0x655dad['authors'],_0x6e3b7b['push'](_0x655dad);}_0x21dea5['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x21dea5['name']=_0x21dea5['name']||null,_0x21dea5['id']=_0x21dea5['id']||_0x20586a(),_0x21dea5={..._0x21dea5,..._0x418f76};const _0x26dbe1=this['addRevisionData'](_0x21dea5);_0x6e3b7b['push'](_0x21dea5);const _0x8304f=this['repository']['getIndex'](_0x26dbe1);if(0x0!==_0x8304f){const _0x484e5a=this['repository']['getRevision'](_0x8304f-0x1);if(_0x484e5a['fromVersion']!==_0x52833b){const _0x212247=this['_revisionDataBuilder']['getData'](_0x52833b,_0x484e5a['toVersion']),_0x7a1067={'id':_0x484e5a['id'],'diffData':_0x212247['diffData'],'authorsIds':_0x212247['authorsIds'],'authors':_0x212247['authorsIds']['map'](_0x106e0f=>this['editor']['plugins']['get']('Users')['getUser'](_0x106e0f)),'fromVersion':_0x52833b};_0x484e5a===this['currentRevision']&&(_0x7a1067['createdAt']=new Date(_0x21dea5['createdAt']['getTime']()+0xa)),_0x484e5a['_update'](_0x7a1067,!0x0),delete _0x7a1067['authors'],_0x6e3b7b['push'](_0x7a1067);}}if(this['adapter']){for(const _0x134533 of _0x6e3b7b)this['_bufferUpdate'](_0x134533['id'],_0x134533,!0x0);this['sendBufferedUpdates']();}return _0x26dbe1;}['addRevisionData'](_0x389b45){const _0x2d9544=this['repository']['createRevision'](_0x389b45);return this['adapter']&&_0x2d9544['on']('_update',(_0x5a17de,_0x5e0194,_0x5e5ec3)=>{_0x5e5ec3||(this['_bufferUpdate'](_0x5e0194['id'],_0x5e0194,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x2d9544,this['_findInsertionIndex'](_0x2d9544)),_0x2d9544;}async['getRevisionDocumentData'](_0x491be5){return await this['_utils']['loadRevisionData'](_0x491be5,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x491be5);}async['getRevisionRootsAttributes'](_0x1fe75d){return await this['_utils']['loadRevisionData'](_0x1fe75d,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x1fe75d);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x1e6008=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x334383=0x0;_0x334383<_0x1e6008['length'];_0x334383++){const _0x19c4e9=_0x1e6008[_0x334383];let _0x5d1c11=!0x1;for(const _0x47075b of Object['keys'](_0x19c4e9))void 0x0===_0x19c4e9[_0x47075b]?delete _0x19c4e9[_0x47075b]:'id'!==_0x47075b&&(_0x5d1c11=!0x0);_0x5d1c11||(_0x1e6008[_0x334383]=null);}if(_0x1e6008=_0x1e6008['filter'](_0x2a7167=>null!==_0x2a7167),!_0x1e6008['length'])return;for(let _0x30fa4f=0x0;_0x30fa4f<_0x1e6008['length'];_0x30fa4f++){const _0x10898e=_0x1e6008[_0x30fa4f];void 0x0!==_0x10898e['fromVersion']&&void 0x0===_0x10898e['toVersion']&&(_0x10898e['toVersion']=this['repository']['getRevision'](_0x10898e['id'])['toVersion']),void 0x0!==_0x10898e['toVersion']&&void 0x0===_0x10898e['fromVersion']&&(_0x10898e['fromVersion']=this['repository']['getRevision'](_0x10898e['id'])['fromVersion']);}const _0x17a124=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x1e6008,_0x17a124)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x4b2705=>{if(_0x4b2705){for(const _0x2e2a21 of _0x4b2705)this['setRevisionData']({'id':_0x2e2a21['id'],'createdAt':_0x2e2a21['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0xe66abc=null,from:_0x5cd6c3=null,to:_0x4b70a3=null}){_0x5cd6c3=null!==_0x5cd6c3?_0x5cd6c3:_0xe66abc['fromVersion'],_0x4b70a3=null!==_0x4b70a3?_0x4b70a3:_0xe66abc['toVersion'];const _0x5545aa=this['_revisionDataBuilder']['getData'](_0x5cd6c3,_0x4b70a3),_0x335317={'diffData':_0x5545aa['diffData'],'authorsIds':_0x5545aa['authorsIds'],'fromVersion':_0x5cd6c3,'toVersion':_0x4b70a3};if(!_0xe66abc||_0x4b70a3!==_0xe66abc['toVersion']){const _0x66efe1=_0x4b70a3-0x1,_0x1a289d=this['_source']['history']['getOperation'](_0x66efe1);_0x335317['createdAt']=_0x1a289d&&_0x1a289d['createdAt']||new Date();}if(this['_loadedStateData']&&_0x5cd6c3===this['_loadedStateData']['fromVersion']){for(const _0x509e0c of this['_loadedStateData']['authors'])_0x335317['authorsIds']['includes'](_0x509e0c['id'])||_0x335317['authorsIds']['push'](_0x509e0c['id']);}return _0x335317;}['_bufferUpdate'](_0x17c362,_0x47f3a4,_0x258f16){if(this['_bufferedUpdates']['has'](_0x17c362)){const _0x50151d=this['_bufferedUpdates']['get'](_0x17c362);_0x47f3a4=_0x258f16?{..._0x50151d,..._0x47f3a4}:{..._0x47f3a4,..._0x50151d};}this['_bufferedUpdates']['set'](_0x17c362,_0x47f3a4);}['setRevisionData'](_0x31b814){const _0x371d95=this['repository']['getRevision'](_0x31b814['id']);if(_0x31b814['createdAt']&&(_0x31b814['createdAt']=new Date(_0x31b814['createdAt'])),_0x31b814['authorsIds']){const _0x1e134d=this['editor']['plugins']['get']('Users');_0x31b814['authors']=_0x31b814['authorsIds']['map'](_0x11fe3b=>_0x1e134d['getUser'](_0x11fe3b));}_0x371d95['_update'](_0x31b814,!0x0);}['_createInitialRevision'](_0x54f7a0){const _0x31e4ef=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x31e4ef)this['_initialRevisionId']=_0x31e4ef['id'];else{const _0x37c811=!this['editor']['model']['document']['roots']['find'](_0x3ff4c1=>this['editor']['model']['hasContent'](_0x3ff4c1)),_0x356380=this['editor']['plugins']['get']('Users')['me']['id'],_0x1fad5b=R(this['editor']['locale'],_0x37c811?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x54f7a0,'to':_0x54f7a0,'id':this['_initialRevisionId'],'name':_0x1fad5b,'creatorId':_0x356380});}}['_createCurrentRevision'](_0x1c45c8){const _0x181fdd=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x181fdd),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x1c45c8,'to':_0x1c45c8,'id':_0x181fdd,'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'](_0x2d4863,_0x335120){let _0x443fe7=this['editor']['config']['get']('initialData'),_0x54035b=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x443fe7){_0x443fe7={};for(const _0x326e63 of this['editor']['model']['document']['getRootNames']())_0x443fe7[_0x326e63]='';}if('string'==typeof _0x443fe7&&(_0x443fe7={'main':_0x443fe7}),void 0x0===_0x54035b){_0x54035b={};for(const _0x1f5757 of this['editor']['model']['document']['getRootNames']())_0x54035b[_0x1f5757]={};}let _0x4fd9f8=!0x1;const _0x36b109=Object['keys'](_0x443fe7),_0x1b8ad0=Object['keys'](_0x2d4863);for(const _0x8d617c of _0x36b109){if(_0x443fe7[_0x8d617c]!==_0x2d4863[_0x8d617c]&&''!==_0x443fe7[_0x8d617c]['trim']()){_0x4fd9f8=!0x0;break;}if(!_0x7fe971(_0x54035b[_0x8d617c],_0x335120[_0x8d617c])&&Object['keys'](_0x54035b[_0x8d617c])['length']>0x0){_0x4fd9f8=!0x0;break;}}_0x4fd9f8||(_0x4fd9f8=_0x1b8ad0['some'](_0x166afc=>!this['editor']['model']['document']['getRoot'](_0x166afc))),_0x4fd9f8&&_0x3c3309('editor-initial-data-replaced-with-revision-data',{'editorData':_0x443fe7,'editorRootsAttributes':_0x54035b,'revisionData':_0x2d4863,'revisionRootsAttributes':_0x335120}),this['editor']['config']['set']('initialData',_0x2d4863),this['editor']['config']['set']('rootsAttributes',_0x335120);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x18637f=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x18637f['add'](R(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x5a79cf){const _0x36ff61=this['repository']['getRevisions']();_0x36ff61['reverse']();let _0x3d58f0=0x0;for(;_0x3d58f0<_0x36ff61['length'];){const _0x45bc86=_0x36ff61[_0x3d58f0];if(_0x45bc86===this['currentRevision']){_0x3d58f0++;continue;}if(_0x45bc86['id']===this['_initialRevisionId'])break;const _0x5bde69=_0x5a79cf['toVersion']-_0x45bc86['toVersion']||_0x5a79cf['fromVersion']-_0x45bc86['fromVersion'];if(_0x5bde69>0x0)break;if(_0x5bde69<0x0)_0x3d58f0++;else{if(!_0x5a79cf['creator']&&_0x45bc86['creator'])break;if(_0x45bc86['creator']||!_0x5a79cf['creator']){if(_0x5a79cf['createdAt']>_0x45bc86['createdAt'])break;_0x3d58f0++;}else _0x3d58f0++;}}return _0x3d58f0;}['_getFromVersion'](_0xa9c62f){const _0x200332=this['repository']['getRevisions']();_0x200332['reverse'](),_0x200332['shift']();const _0x523f3c=_0x200332['find'](_0x19fd8e=>_0x19fd8e['toVersion']<=_0xa9c62f)['toVersion'];return _0x523f3c<this['_startingVersion']?this['_startingVersion']:_0x523f3c;}['_makeRevision']({name:_0x6023c6,from:_0x1517a7,to:_0x1b361a,creatorId:_0x22a242,id:_0x24b963}){const _0x38f949=this['buildRevisionData']({'from':_0x1517a7,'to':_0x1b361a});_0x38f949['name']=_0x6023c6,_0x38f949['creatorId']=_0x22a242,_0x38f949['id']=_0x24b963;const _0x3a28ae=this['addRevisionData'](_0x38f949);return this['adapter']&&this['_bufferUpdate'](_0x38f949['id'],_0x38f949,!0x0),_0x3a28ae;}['_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(_0x559f61){this['editor']=_0x559f61,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'](_0x1cdedf){this['source']=_0x1cdedf;const _0x10fddb=new Map(),_0xb94a55=new Map(),_0x2cb5fa=this['editor']['model']['document']['roots']['map'](_0x41cb9c=>_0x41cb9c['rootName']);for(const _0x46cd7f of _0x2cb5fa){const _0x70a16f=this['editor']['model']['document']['getRoot'](_0x46cd7f),_0x10c2cd=x(_0x70a16f);_0x10fddb['set'](_0x46cd7f,_0x10c2cd),_0xb94a55['set'](_0x46cd7f,Object['fromEntries'](_0x70a16f['getAttributes']()));}const _0x35f3d8=Array['from'](this['editor']['model']['markers'])['map'](_0x2ae89d=>[_0x2ae89d['name'],_0x2ae89d['getRange']()]),_0x5381e4=this['source']['version'];this['_saveMetaData'](_0x5381e4,_0x10fddb,_0x35f3d8,_0xb94a55),this['_startingRevisionId']=this['_revisionId'];const _0x5e29ae=new Map(),_0x3aeec0=new Map();for(const _0x12fcee of _0x2cb5fa){const _0x29a7a4=N(_0x12fcee);_0x5e29ae['set'](_0x12fcee,_0x29a7a4),_0x3aeec0['set'](_0x12fcee,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x5e29ae,[],_0x3aeec0);}['getData'](_0x3ad8be,_0x9bb28b){if(this['_lastFrom']===_0x3ad8be&&this['_lastTo']<=_0x9bb28b)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x9bb28b,!0x0);else{if(!this['_savedMetaData']['has'](_0x3ad8be)){const _0x5763d8=this['_getPreviousFrom'](_0x3ad8be);this['_calculateMetaData'](_0x5763d8,_0x3ad8be,!0x1);}this['_calculateMetaData'](_0x3ad8be,_0x9bb28b,!0x0);}return this['_lastFrom']=_0x3ad8be,this['_lastTo']=_0x9bb28b,this['_getState']();}['loadState'](_0x5c40d7){const _0x36387d=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x5c40d7['fromVersion'],this['_lastTo']=_0x5c40d7['toVersion'];for(const _0x9f7636 in _0x5c40d7['diffData']){const _0x4d7d8a=_0x5c40d7['diffData'][_0x9f7636]['attachChange'],_0x1b205b=_0x16a120(_0x5c40d7['diffData'][_0x9f7636]['attributesBefore'])||{},_0x2f777d=_0x36387d['_makeModelFromViewString'](_0x5c40d7['diffData'][_0x9f7636]['deletions']);_0x2f777d['rootName']=_0x9f7636,_0x2f777d['_isAttached']=!_0x4d7d8a||!_0x4d7d8a['isAttached'],_0x2f777d['isAttached']=()=>_0x2f777d['_isAttached'],this['_baseRoots']['set'](_0x9f7636,_0x2f777d),this['_baseRootsAttributes']['set'](_0x9f7636,_0x1b205b),_0x4d7d8a&&this['_touchedRoots']['set'](_0x9f7636,_0x4d7d8a);const _0x3ca333=this['_makeIdsRoot'](_0x2f777d);this['_baseIdsRoots']['set'](_0x9f7636,_0x3ca333);for(const [_0x492a3a,_0x58ba50]of _0x2f777d['markers']){if(!_0x492a3a['startsWith']('revision:'))continue;const _0x5df5e7=_0x492a3a['split'](':')[0x2];for(const _0x12428c of _0x58ba50['getWalker']({'singleCharacters':!0x0})){const _0x48618e=this['_getVidAttributeName'](_0x12428c),_0x4ce734='elementEnd'==_0x12428c['type']?_0x12428c['previousPosition']['path']['slice'](0x0,-0x1):_0x12428c['previousPosition']['path'],_0x13f140=_0x3ca333['getNodeByPath'](_0x4ce734)['getAttribute'](_0x48618e);this['_touched']['set'](_0x13f140,{'userId':_0x5df5e7});}}}this['_startingRevisionId']=this['_revisionId'];const _0x1737dd=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x22d3a1=>!this['_touched']['has'](_0x22d3a1));let _0x5b7521=0x0;const _0x5a28ff=new Map();for(const _0x519dbb in _0x5c40d7['diffData']){const _0x5534ea=_0x5c40d7['diffData'][_0x519dbb]['attachChange'],_0x448e88=_0x16a120(_0x5c40d7['diffData'][_0x519dbb]['attributesAfter'])||{},_0x4a4d43=_0x36387d['_makeModelFromViewString'](_0x5c40d7['diffData'][_0x519dbb]['insertions']);_0x4a4d43['rootName']=_0x519dbb,_0x4a4d43['_isAttached']=!_0x5534ea||_0x5534ea['isAttached'],_0x4a4d43['isAttached']=()=>_0x4a4d43['_isAttached'],this['_diffRoots']['set'](_0x519dbb,_0x4a4d43),this['_diffRootsAttributes']['set'](_0x519dbb,_0x448e88);const _0x3a0005=this['_makeIdsRoot'](_0x4a4d43,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x519dbb,_0x3a0005),_0x5a28ff['set'](_0x519dbb,_0x4a4d43['isAttached']()?_0x448e88:{});for(const [_0xc9ef32,_0x235ec8]of _0x4a4d43['markers']){if(!_0xc9ef32['startsWith']('revision:'))continue;const _0xba6a42=_0xc9ef32['split'](':')[0x2];for(const _0x9400a1 of _0x235ec8['getWalker']({'singleCharacters':!0x0})){const _0x157cb0=this['_getVidAttributeName'](_0x9400a1),_0x5e0718=this['_revisionId']++,_0x441f42='elementEnd'==_0x9400a1['type']?_0x9400a1['previousPosition']['path']['slice'](0x0,-0x1):_0x9400a1['previousPosition']['path'];_0x3a0005['getNodeByPath'](_0x441f42)['_setAttribute'](_0x157cb0,_0x5e0718),this['_touched']['set'](_0x5e0718,{'userId':_0xba6a42});}}for(const _0x3efe20 of this['editor']['model']['createRangeIn'](_0x4a4d43)['getWalker']({'singleCharacters':!0x0})){const _0x1ced50=this['_getVidAttributeName'](_0x3efe20),_0x384d08='elementEnd'==_0x3efe20['type']?_0x3efe20['previousPosition']['path']['slice'](0x0,-0x1):_0x3efe20['previousPosition']['path'],_0x355a4c=_0x3a0005['getNodeByPath'](_0x384d08);_0x355a4c['getAttribute'](_0x1ced50)>0x0||_0x355a4c['_setAttribute'](_0x1ced50,_0x1737dd[_0x5b7521++]);}for(const [_0x5b4de3,_0x14fe72]of _0x4a4d43['markers'])_0x5b4de3['startsWith']('revision:')||this['_markers']['set'](_0x5b4de3,_0x14fe72);}const _0x592633=N('$graveyard');this['_baseRoots']['set']('$graveyard',_0x592633),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x592633,0x1));const _0x5bfd6e=N('$graveyard');this['_diffRoots']['set']('$graveyard',_0x5bfd6e),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x5bfd6e,0x1));const _0x53109d=Array['from'](this['_diffRoots'])['map'](([_0xd9d30f,_0x57724d])=>[_0xd9d30f,x(_0x57724d)]);this['_saveMetaData'](this['_lastTo'],_0x53109d,this['_markers'],_0x5a28ff);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0x31107c,_0x48927e,_0x2da805,_0x4229c7){const _0xc284cc=new Map(_0x48927e),_0x33bff3=new Map(_0x16a120(_0x4229c7)),_0x304ea1=new Map();for(const [_0x11d057,_0x2b05e2]of _0x2da805)_0x304ea1['set'](_0x11d057,{'start':_0x2b05e2['start']['clone'](),'end':_0x2b05e2['end']['clone'](),'rootName':_0x2b05e2['root']['rootName']});this['_savedMetaData']['set'](_0x31107c,{'roots':_0xc284cc,'markers':_0x304ea1,'rootsAttributes':_0x33bff3});}['_removeMetaData'](_0x5acb7e){this['_savedMetaData']['delete'](_0x5acb7e);}['_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'](_0x646e0f,_0x38ba45=null){let _0x15ee63=null;_0x646e0f['is']('documentFragment')||(_0x15ee63=new _0x4d1ea2(_0x646e0f['name'],{'vid_start':null===_0x38ba45?this['_revisionId']++:_0x38ba45++}));const _0x4b8e16=[];for(const _0x514335 of _0x646e0f['getChildren']())if(_0x514335['is']('element')){_0x4b8e16['push'](this['_makeIdsRoot'](_0x514335,_0x38ba45));const _0x4d2c58=_0x4b8e16[_0x4b8e16['length']-0x1];null!==_0x38ba45&&(_0x38ba45=_0x4d2c58['is']('element','$text')?_0x4d2c58['getAttribute']('vid')+0x1:_0x4d2c58['getAttribute']('vid_end')+0x1);}else{for(let _0x26aee4=0x0;_0x26aee4<_0x514335['offsetSize'];_0x26aee4++)_0x4b8e16['push'](new _0x4d1ea2('$text',{'vid':null===_0x38ba45?this['_revisionId']++:_0x38ba45++}));}if(_0x646e0f['is']('documentFragment')){const _0x10dc58=N(_0x646e0f['rootName']);return _0x10dc58['_insertChild'](0x0,_0x4b8e16),_0x10dc58;}return _0x15ee63['_setAttribute']('vid_end',null===_0x38ba45?this['_revisionId']++:_0x38ba45++),_0x15ee63['_insertChild'](0x0,_0x4b8e16),_0x15ee63;}['_calculateMetaData'](_0x4034ce,_0x1f5494,_0x576555){this['_reset']();const {roots:_0x11d01f,markers:_0x1cf197,rootsAttributes:_0x3888b4}=this['_savedMetaData']['get'](_0x4034ce);this['_baseRoots']=new Map(_0x11d01f),this['_baseRootsAttributes']=new Map(_0x16a120(_0x3888b4));for(const [_0x406720,_0x4f2484]of this['_baseRoots'])if('$graveyard'!==_0x406720&&(this['_diffRoots']['set'](_0x406720,x(_0x4f2484)),this['_diffRootsAttributes']=new Map(_0x16a120(_0x3888b4)),_0x576555)){const _0x4a8bfd=this['_revisionId'];this['_idsRoots']['set'](_0x406720,this['_makeIdsRoot'](_0x4f2484)),this['_baseIdsRoots']['set'](_0x406720,this['_makeIdsRoot'](_0x4f2484,_0x4a8bfd));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',x(this['_baseRoots']['get']('$graveyard'))),_0x576555&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x2afe5f,_0x45d949]of _0x1cf197){const _0x2a9005=this['_baseRoots']['get'](_0x45d949['rootName']),_0x51e7c4=this['_diffRoots']['get'](_0x45d949['rootName']),_0x3ab430=new _0x4be064(this['_fixPosition'](_0x45d949['start'],_0x2a9005),this['_fixPosition'](_0x45d949['end'],_0x2a9005)),_0x2854b2=this['_fixRange'](_0x3ab430,_0x51e7c4);_0x2a9005['markers']['set'](_0x2afe5f,_0x3ab430),this['_markers']['set'](_0x2afe5f,_0x2854b2);}this['_applyOperations'](_0x4034ce,_0x1f5494,_0x576555);}['_applyOperations'](_0x411a77,_0x5793b4,_0x368602){for(const _0x1c64f4 of this['source']['getOperations'](_0x411a77,_0x5793b4))this['_handleOperation'](_0x1c64f4,_0x368602);for(const _0x353f9a of this['_diffRoots']['values']())_0x353f9a['markers']['clear']();for(const [_0x2da245,_0x44c0f2]of this['_markers']){this['_diffRoots']['get'](_0x44c0f2['root']['rootName'])['markers']['set'](_0x2da245,_0x44c0f2['clone']());}const _0x15c39e=new Map(),_0x4e0920=new Map();for(const [_0x2e9d2e,_0x13f2fb]of this['_diffRoots'])_0x15c39e['set'](_0x2e9d2e,x(_0x13f2fb)),_0x4e0920['set'](_0x2e9d2e,this['_diffRootsAttributes']['get'](_0x2e9d2e));this['_saveMetaData'](_0x5793b4,_0x15c39e,this['_markers'],_0x4e0920);}['_getPreviousFrom'](_0x5d41eb){const _0x2f898e=Array['from'](this['_savedMetaData']['keys']());_0x2f898e['sort']((_0x4c1eb6,_0x32b582)=>_0x4c1eb6-_0x32b582),_0x2f898e['reverse']();for(const _0x7bb217 of _0x2f898e)if(_0x7bb217<_0x5d41eb)return _0x7bb217;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0xf79b6e,_0x79b961){const _0x29d68b=Array['from'](_0x79b961['markers'])['map'](([_0x4633d9,_0x1c483a])=>[_0x4633d9,this['_fixRange'](_0x1c483a,_0xf79b6e)]);_0xf79b6e['markers']=new Map(_0x29d68b);}['_transformMarkers'](_0x22f3ea){for(const _0x265597 of this['_markers']['values']()){const _0x4d75de=_0x265597['getTransformedByOperation'](_0x22f3ea),_0x1af600=_0x4be064['_createFromRanges'](_0x4d75de);_0x265597['start']=_0x1af600['start'],_0x265597['end']=_0x1af600['end'];}}['_handleOperation'](_0x17ccdf,_0x21901b){if('addRoot'!=_0x17ccdf['type']&&'detachRoot'!=_0x17ccdf['type']){if('insert'==_0x17ccdf['type']){const _0x5878ef=_0x17ccdf['position']['root']['rootName'];this['_diffRoots']['has'](_0x5878ef)||(this['_diffRoots']['set'](_0x5878ef,N(_0x5878ef,!0x0)),this['_diffRootsAttributes']['set'](_0x5878ef,{}),_0x21901b&&this['_idsRoots']['set'](_0x5878ef,N(_0x5878ef,!0x0)));}else{if('addRootAttribute'==_0x17ccdf['type']||'removeRootAttribute'==_0x17ccdf['type']||'changeRootAttribute'==_0x17ccdf['type'])return void this['_handleRootAttributeOperation'](_0x17ccdf);'marker'==_0x17ccdf['type']&&this['_handleMarkerOperation'](_0x17ccdf);}if('marker'!==_0x17ccdf['type']){const _0x4a349e=this['_cloneOperation'](_0x17ccdf,this['_diffRoots']);_0x4a349e['_execute'](),this['_transformMarkers'](_0x4a349e);}if(_0x21901b)switch(_0x17ccdf['type']){case'insert':this['_handleInsertOperation'](_0x17ccdf);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x17ccdf);break;case'merge':this['_handleMergeOperation'](_0x17ccdf);break;case'split':this['_handleSplitOperation'](_0x17ccdf);}}else this['_handleRootOperation'](_0x17ccdf,_0x21901b);}['_cloneOperation'](_0xba6e8a,_0x349d69){const _0x4ec7df=_0xba6e8a['clone']();return _0x4ec7df['_authorId']=_0xba6e8a['_authorId'],this['_fixOperation'](_0x4ec7df,_0x349d69),_0x4ec7df;}['_getBaseVids'](_0x54f613){return _0x54f613['map'](_0x12a98d=>{const _0x22ddb3=this['_getVidAttributeName'](_0x12a98d);return Number(_0x12a98d['item']['getAttribute'](_0x22ddb3));});}['_generateTape'](_0x39e047,_0x639af0){if(_0x39e047['is']('element','$text'))_0x639af0['push']({'item':_0x39e047,'type':'text'});else{_0x39e047['is']('element')&&_0x639af0['push']({'item':_0x39e047,'type':'elementStart'});for(const _0x253e06 of _0x39e047['getChildren']())this['_generateTape'](_0x253e06,_0x639af0);_0x39e047['is']('element')&&_0x639af0['push']({'item':_0x39e047,'type':'elementEnd'});}return _0x639af0;}['_getState'](){const _0x2b3cd1=new Map(this['_touched']),_0x2a2a16=new Map(_0x2b3cd1),_0x1efedd=new Map(),_0x187dcb={'insertions':{},'deletions':{}},_0x58c1b7={'insertions':{},'deletions':{}},_0x58c5b6=new Map(),_0x109ada=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x109ada['delete']('$graveyard');for(const _0x29a915 of _0x109ada){const _0x4e8566=this['_diffRoots']['get'](_0x29a915)||N(_0x29a915,!0x1),_0x1424b8=this['_baseRoots']['get'](_0x29a915)||N(_0x29a915,!0x1);_0x4e8566['isAttached']()||_0x1424b8['isAttached']()?(_0x187dcb['insertions'][_0x29a915]=x(_0x4e8566),_0x187dcb['deletions'][_0x29a915]=x(_0x1424b8),this['_copyMarkers'](_0x187dcb['deletions'][_0x29a915],_0x1424b8),this['_copyMarkers'](_0x187dcb['insertions'][_0x29a915],_0x4e8566),_0x58c1b7['insertions'][_0x29a915]=this['_generateTape'](this['_idsRoots']['get'](_0x29a915),[]),_0x58c1b7['deletions'][_0x29a915]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x29a915)||N(_0x29a915,!0x1),[])):_0x109ada['delete'](_0x29a915);}for(const _0x486021 of _0x109ada){const _0xff4a38=_0x58c1b7['insertions'][_0x486021];for(const _0x5af5ec of _0xff4a38){const _0xa2a038=this['_getVidAttributeName'](_0x5af5ec),_0x3d264d=_0x5af5ec['item']['getAttribute'](_0xa2a038);_0x2a2a16['delete'](_0x3d264d),_0x3d264d>=this['_startingRevisionId']&&_0x1efedd['set'](_0x3d264d,_0x2b3cd1['get'](_0x3d264d));}}for(const _0x3f4602 of _0x109ada){const _0x424d1e=_0x58c1b7['insertions'][_0x3f4602],_0x301043=this['_getBaseVids'](_0x58c1b7['deletions'][_0x3f4602]);let _0x11a92e=0x0;for(const _0x21b56d of _0x424d1e){const _0x455cb2=this['_getVidAttributeName'](_0x21b56d),_0x5bddb3=_0x21b56d['item']['getAttribute'](_0x455cb2);if(!_0x1efedd['has'](_0x5bddb3)&&!_0x58c5b6['has'](_0x5bddb3)){if(_0x2a2a16['has'](_0x5bddb3))_0x11a92e++;else{if(_0x5bddb3!=_0x301043[_0x11a92e]){const _0x7c5be6=_0x2b3cd1['get'](_0x5bddb3)||_0x2b3cd1['get'](_0x301043[_0x11a92e]);for(;_0x5bddb3!=_0x301043[_0x11a92e];)_0x2a2a16['has'](_0x301043[_0x11a92e])||(_0x58c5b6['set'](_0x301043[_0x11a92e],_0x7c5be6),_0x2b3cd1['set'](_0x301043[_0x11a92e],_0x7c5be6)),_0x11a92e++;}_0x11a92e++;}}}}for(const _0x61c280 of _0x109ada){const _0x290883=_0x58c1b7['insertions'][_0x61c280];for(const _0x5106c0 of _0x290883){const _0x3c2e6c=this['_getVidAttributeName'](_0x5106c0),_0x3a2b5d=_0x5106c0['item']['getAttribute'](_0x3c2e6c);if(_0x58c5b6['has'](_0x3a2b5d)){const _0x577e17=_0x58c5b6['get'](_0x3a2b5d);_0x2a2a16['has'](_0x3a2b5d)||_0x2a2a16['set'](_0x3a2b5d,{..._0x577e17}),_0x1efedd['set'](_0x3a2b5d,{..._0x577e17});}}}for(const _0x14c264 of _0x2a2a16['keys']())_0x14c264>=this['_startingRevisionId']&&_0x2a2a16['delete'](_0x14c264);const _0x3e9154=new Map();for(const _0x3c7e80 of _0x109ada){let _0x16af4b=_0x58c1b7['insertions'][_0x3c7e80];for(const _0x7b4a5 of _0x16af4b)if(_0x7b4a5['item']['is']('element','tableCell')){const _0x41af68=this['_getVidAttributeName'](_0x7b4a5),_0x5a6679=_0x7b4a5['item']['getAttribute'](_0x41af68);if(_0x1efedd['has'](_0x5a6679)){const _0x5e0f42=_0x7b4a5['item']['parent']['parent']['getAttribute']('vid_start'),_0x14a8d8=_0x3e9154['get'](_0x5e0f42)||new Set();_0x14a8d8['add'](_0x1efedd['get'](_0x5a6679)['userId']),_0x3e9154['set'](_0x5e0f42,_0x14a8d8);}}_0x16af4b=_0x58c1b7['deletions'][_0x3c7e80];for(const _0x2ba6c5 of _0x16af4b)if(_0x2ba6c5['item']['is']('element','tableCell')){const _0x473c36=this['_getVidAttributeName'](_0x2ba6c5),_0x1e8b56=_0x2ba6c5['item']['getAttribute'](_0x473c36);if(_0x2a2a16['has'](_0x1e8b56)){const _0x493449=_0x2ba6c5['item']['parent']['parent']['getAttribute']('vid_start'),_0x3a4ba9=_0x3e9154['get'](_0x493449)||new Set();_0x3a4ba9['add'](_0x2a2a16['get'](_0x1e8b56)['userId']),_0x3e9154['set'](_0x493449,_0x3a4ba9);}}for(const _0x519017 of _0x3e9154['keys']())(_0x1efedd['has'](_0x519017)||_0x2a2a16['has'](_0x519017))&&_0x3e9154['delete'](_0x519017);}for(const _0x441cae of _0x109ada){const _0x263b2e=_0x58c1b7['insertions'][_0x441cae];let _0x3b7447=null,_0x2fd59e=null;for(const _0x39b575 of _0x263b2e){const _0x41f7ea=this['_getVidAttributeName'](_0x39b575),_0x4824a9=_0x39b575['item']['getAttribute'](_0x41f7ea),_0x38fecb=_0x3e9154['get'](_0x4824a9);_0x38fecb&&'elementStart'==_0x39b575['type']&&(_0x3b7447=Array['from'](_0x38fecb)[0x0],_0x2fd59e=_0x39b575['item']['getAttribute']('vid_end')),_0x3b7447&&(_0x2a2a16['set'](_0x4824a9,{'userId':_0x3b7447}),_0x1efedd['set'](_0x4824a9,{'userId':_0x3b7447})),_0x4824a9==_0x2fd59e&&(_0x3b7447=null,_0x2fd59e=null);}}const _0x14c750={},_0x2e6628=new Set();for(const _0x244b0a of _0x109ada){const _0x1b4a97=_0x187dcb['deletions'][_0x244b0a],_0x200b42=_0x187dcb['insertions'][_0x244b0a];for(const {userId:_0x419485}of this['_touchedMarkers']['values']())null!==_0x419485&&_0x2e6628['add'](_0x419485);for(const {userId:_0x56d683}of this['_touchedRoots']['values']())null!==_0x56d683&&_0x2e6628['add'](_0x56d683);this['_markChanges'](_0x200b42,_0x58c1b7['insertions'][_0x244b0a],_0x1efedd,'insertion',_0x2e6628),this['_markChanges'](_0x1b4a97,_0x58c1b7['deletions'][_0x244b0a],_0x2a2a16,'deletion',_0x2e6628),_0x14c750[_0x244b0a]={'insertions':this['_prepareViewToSave'](_0x200b42),'deletions':this['_prepareViewToSave'](_0x1b4a97),'attachChange':this['_touchedRoots']['get'](_0x244b0a)||null,'attributesBefore':_0x16a120(this['_baseRootsAttributes']['get'](_0x244b0a))||{},'attributesAfter':_0x16a120(this['_diffRootsAttributes']['get'](_0x244b0a))};}return{'diffData':_0x14c750,'authorsIds':Array['from'](_0x2e6628)};}['_processRootBeforeSave'](_0x213086){for(const [,_0x5371e4]of _0x213086['markers']){const _0xe88b63=_0x5371e4['start']['getAncestors']()['filter'](_0x5dc345=>'tableCell'==_0x5dc345['name']);for(const _0x513f4a of _0xe88b63)0x1==_0x513f4a['childCount']&&_0x513f4a['getChild'](0x0)['is']('element','paragraph')&&_0x513f4a['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0xaae815){this['_processRootBeforeSave'](_0xaae815);const _0x3f8d61=this['editor']['data']['toView'](_0xaae815,{}),_0x44b26e=Array['from'](_0x3f8d61['getChildren']())['map'](_0x23e736=>this['_getViewJson'](_0x23e736));return JSON['stringify'](_0x44b26e);}['_getViewJson'](_0x25100c){if(_0x25100c['is']('$text'))return _0x25100c['data'];{const _0x1bdc8e=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0x5e8e4b=_0x25100c,_0x7f2c68=this['editor']['data']['htmlProcessor']['domConverter'],_0x4b1b8b={'type':_0x1bdc8e['_getTypeCharForViewElement'](_0x5e8e4b),'name':_0x5e8e4b['name'],'attributes':Array['from'](_0x5e8e4b['getAttributes']()),'children':Array['from'](_0x5e8e4b['getChildren']())['map'](_0x320da3=>this['_getViewJson'](_0x320da3))};if(_0x25100c['is']('uiElement')&&'$comment'!=_0x25100c['name']){const _0x11b2f6=_0x25100c['render'](_0x7f2c68['domDocument'],_0x7f2c68);_0x4b1b8b['children']['push'](_0x11b2f6['outerHTML']);}else{if(_0x25100c['is']('rawElement')){const _0x44f1ef=_0x7f2c68['domDocument']['createElement'](_0x5e8e4b['name']);_0x25100c['render'](_0x44f1ef,_0x7f2c68),_0x4b1b8b['children']['push'](_0x44f1ef['innerHTML']);}}const _0x3555ff=Array['from'](_0x5e8e4b['getCustomProperties']());_0x3555ff['length']>0x0&&(_0x4b1b8b['customProperties']=_0x3555ff);const _0x10404f=_0x5e8e4b['getFillerOffset']();return null!==_0x10404f&&(_0x4b1b8b['fillerOffset']=_0x10404f),_0x4b1b8b;}}['_markChanges'](_0x5e3515,_0x41c4c8,_0x1be408,_0x546ec4,_0x1316d6){let _0x57f467=null,_0x2ffb71=null,_0x4d12fc=0x0;const _0x15c3e4=this['editor']['model'];for(let _0x272e3b=0x0;_0x272e3b<_0x41c4c8['length'];_0x272e3b++){const _0x24467d=this['_getVidAttributeName'](_0x41c4c8[_0x272e3b]),_0x497338=_0x41c4c8[_0x272e3b]['item']['getAttribute'](_0x24467d),_0x34f578=_0x1be408['get'](_0x497338),_0x5436cb=_0x272e3b==_0x41c4c8['length']-0x1;(!_0x57f467&&_0x34f578&&(_0x57f467=_0x34f578,_0x2ffb71=_0x41c4c8[_0x272e3b]),_0x57f467&&(!_0x34f578||_0x34f578['userId']!=_0x57f467['userId']))&&(_0x51e736(_0x34f578,P(_0x2ffb71,_0x5e3515,_0x15c3e4),P(_0x41c4c8[_0x272e3b],_0x5e3515,_0x15c3e4)),_0x57f467=_0x34f578||null,_0x2ffb71=_0x34f578?_0x41c4c8[_0x272e3b]:null),_0x57f467&&_0x5436cb&&_0x51e736(_0x34f578,P(_0x2ffb71,_0x5e3515,_0x15c3e4),V(_0x41c4c8[_0x272e3b],_0x5e3515,_0x15c3e4));}function _0x51e736(_0x1eee8d,_0x4b6614,_0x574391){const _0x2db864=_0x57f467['userId'],_0x30e2d3='revision:'+_0x546ec4+':'+_0x2db864+':'+_0x4d12fc++,_0x5eb72a=_0x15c3e4['createRange'](_0x4b6614,_0x574391);_0x5e3515['markers']['set'](_0x30e2d3,_0x5eb72a),null!==_0x2db864&&_0x1316d6['add'](_0x2db864);}}['_getVidAttributeName'](_0x3f092f){switch(_0x3f092f['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x145a71,_0x1f974f){_0x145a71['baseVersion']=null;for(const _0x5acf2c in _0x145a71){const _0x2e0abe=_0x145a71[_0x5acf2c];if(_0x2e0abe instanceof _0x15ef30){const _0x23c416=_0x1f974f['get'](_0x2e0abe['root']['rootName']);_0x145a71[_0x5acf2c]=this['_fixPosition'](_0x2e0abe,_0x23c416);}if(_0x2e0abe instanceof _0x4be064){const _0x149008=_0x1f974f['get'](_0x2e0abe['root']['rootName']);_0x145a71[_0x5acf2c]=this['_fixRange'](_0x2e0abe,_0x149008);}'root'===_0x5acf2c&&(_0x145a71['root']=_0x1f974f['get'](_0x145a71['root']['rootName']));}}['_fixRange'](_0x386472,_0x5b4bad){return this['editor']['model']['createRange'](this['_fixPosition'](_0x386472['start'],_0x5b4bad),this['_fixPosition'](_0x386472['end'],_0x5b4bad));}['_fixPosition'](_0x4979da,_0xf5a508){return this['editor']['model']['createPositionFromPath'](_0xf5a508,_0x4979da['path'],_0x4979da['stickiness']);}['_handleInsertOperation'](_0x5c44ed){const _0x55a0aa=this['_idsRoots']['get'](_0x5c44ed['position']['root']['rootName']),_0x415f5a=this['_fixPosition'](_0x5c44ed['position'],_0x55a0aa),_0x46eb16=null===_0x5c44ed['_authorId']?null:_0x5c44ed['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x345573=_0x415f5a['parent'],_0x3baba2=this['_revisionId'],_0x25316e=[];for(const _0x251f82 of _0x5c44ed['nodes'])if(_0x251f82['is']('element'))_0x25316e['push'](this['_makeIdsRoot'](_0x251f82));else{for(let _0x21aa46=0x0;_0x21aa46<_0x251f82['offsetSize'];_0x21aa46++)_0x25316e['push'](new _0x4d1ea2('$text',{'vid':this['_revisionId']++}));}const _0x32cfcc=this['_revisionId'];for(let _0x5550cc=_0x3baba2;_0x5550cc<_0x32cfcc;_0x5550cc++)this['_touched']['set'](_0x5550cc,{'userId':_0x46eb16});_0x345573['_insertChild'](_0x415f5a['offset'],_0x25316e);}['_handleMoveOperation'](_0x44f14e){(_0x44f14e=this['_cloneOperation'](_0x44f14e,this['_idsRoots']))['_execute']();const _0x9d252a=null===_0x44f14e['_authorId']?null:_0x44f14e['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x4aa2c8=_0x44f14e['getMovedRangeStart'](),_0x16532a=_0x4aa2c8['parent'],_0x11f4e7=_0x4aa2c8['offset'];!function _0x1e1a1d(_0x3d4ef2,_0x2a75bf,_0x3ee326,_0x464a27){for(let _0x141651=_0x3ee326;_0x141651<_0x464a27;_0x141651++){const _0x282226=_0x2a75bf['getChild'](_0x141651);_0x282226['is']('element','$text')?_0x3d4ef2['set'](_0x282226['getAttribute']('vid'),{'userId':_0x9d252a}):(_0x3d4ef2['set'](_0x282226['getAttribute']('vid_start'),{'userId':_0x9d252a}),_0x1e1a1d(_0x3d4ef2,_0x282226,0x0,_0x282226['childCount']),_0x3d4ef2['set'](_0x282226['getAttribute']('vid_end'),{'userId':_0x9d252a}));}}(this['_touched'],_0x16532a,_0x11f4e7,_0x11f4e7+_0x44f14e['howMany']);}['_handleMergeOperation'](_0x1d68a3){const _0x428665=null===(_0x1d68a3=this['_cloneOperation'](_0x1d68a3,this['_idsRoots']))['_authorId']?null:_0x1d68a3['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x47864f=_0x1d68a3['targetPosition']['parent'],_0x31e3c6=_0x1d68a3['sourcePosition']['parent'],_0x530319=_0x47864f['getAttribute']('vid_end'),_0x542c6c=_0x31e3c6['getAttribute']('vid_start');_0x47864f['_setAttribute']('vid_end',_0x31e3c6['getAttribute']('vid_end')),_0x31e3c6['_setAttribute']('vid_end',_0x530319),this['_touched']['set'](_0x542c6c,{'userId':_0x428665}),this['_touched']['set'](_0x530319,{'userId':_0x428665}),_0x1d68a3['_execute']();}['_handleSplitOperation'](_0x43bf0d){const _0x290c7c=null===(_0x43bf0d=this['_cloneOperation'](_0x43bf0d,this['_idsRoots']))['_authorId']?null:_0x43bf0d['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x3e25b9=_0x43bf0d['graveyardPosition'],_0x387de5=_0x43bf0d['splitPosition']['parent'];_0x43bf0d['_execute']();const _0x57637d=_0x387de5['getAttribute']('vid_end'),_0x167779=_0x43bf0d['insertionPosition']['nodeAfter'];if(_0x3e25b9){const _0x155f45=_0x167779['getAttribute']('vid_end'),_0xc630fa=_0x387de5['getAttribute']('vid_end');_0x387de5['_setAttribute']('vid_end',_0x155f45),_0x167779['_setAttribute']('vid_end',_0xc630fa),this['_touched']['set'](_0x387de5['getAttribute']('vid_end'),{'userId':_0x290c7c}),this['_touched']['set'](_0x167779['getAttribute']('vid_start'),{'userId':_0x290c7c});}else{const _0x5c6c5d=this['_revisionId']++,_0x411420=this['_revisionId']++;_0x387de5['_setAttribute']('vid_end',_0x5c6c5d),_0x167779['_setAttribute']('vid_start',_0x411420),_0x167779['_setAttribute']('vid_end',_0x57637d),this['_touched']['set'](_0x5c6c5d,{'userId':_0x290c7c}),this['_touched']['set'](_0x411420,{'userId':_0x290c7c});}}['_handleMarkerOperation'](_0x1d3d1){if(!_0x1d3d1['affectsData'])return;const _0x4b695b=(_0x1d3d1=this['_cloneOperation'](_0x1d3d1,this['_diffRoots']))['oldRange']?_0x1d3d1['oldRange']['root']:null,_0x1fb39d=_0x1d3d1['newRange']?_0x1d3d1['newRange']['root']:null;_0x4b695b&&this['_markers']['delete'](_0x1d3d1['name']),_0x1fb39d&&this['_markers']['set'](_0x1d3d1['name'],_0x1d3d1['newRange']['clone']());const _0x5992f3=null===_0x1d3d1['_authorId']?null:_0x1d3d1['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x3cfc47=_0x1d3d1['name'];if(!this['_touchedMarkers']['has'](_0x3cfc47))return void this['_touchedMarkers']['set'](_0x3cfc47,{'range':_0x1d3d1['oldRange'],'userId':_0x5992f3});const _0x56b477=this['_touchedMarkers']['get'](_0x3cfc47),_0x58d573=_0x56b477['range'],_0x368d61=_0x1d3d1['newRange'];null==_0x58d573&&null==_0x368d61||_0x58d573&&_0x368d61&&_0x58d573['isEqual'](_0x368d61)?this['_touchedMarkers']['delete'](_0x1d3d1['name']):_0x56b477['userId']=_0x5992f3;}['_handleRootOperation'](_0x470c9f,_0x49a96f){this['_diffRoots']['has'](_0x470c9f['rootName'])?this['_diffRoots']['get'](_0x470c9f['rootName'])['_isAttached']=_0x470c9f['isAdd']:(this['_diffRoots']['set'](_0x470c9f['rootName'],N(_0x470c9f['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x470c9f['rootName'],{}),_0x49a96f&&this['_idsRoots']['set'](_0x470c9f['rootName'],N(_0x470c9f['rootName'],!0x0)));const _0x17a6de=null===_0x470c9f['_authorId']?null:_0x470c9f['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x281705=this['_touchedRoots']['get'](_0x470c9f['rootName']);_0x281705&&_0x281705['userId']===_0x17a6de?this['_touchedRoots']['delete'](_0x470c9f['rootName']):this['_touchedRoots']['set'](_0x470c9f['rootName'],{'userId':_0x17a6de,'isAttached':_0x470c9f['isAdd']});}['_handleRootAttributeOperation'](_0x1a285e){const _0x462b90=this['_diffRootsAttributes']['get'](_0x1a285e['root']['rootName']);null===_0x1a285e['newValue']?delete _0x462b90[_0x1a285e['key']]:_0x462b90[_0x1a285e['key']]=_0x1a285e['newValue'];}}function x(_0x27565f){const _0x2f5c3c=N(_0x27565f['rootName'],_0x27565f['isAttached']());for(const _0x20e7b6 of _0x27565f['getChildren']()){const _0xa7665f=_0x20e7b6['_clone'](!0x0);_0x2f5c3c['_appendChild'](_0xa7665f);}return _0x2f5c3c;}function N(_0x821bcb,_0x441e26=!0x0){const _0x285fdc=new _0x705efd();return _0x285fdc['rootName']=_0x821bcb,_0x285fdc['_isAttached']=_0x441e26,_0x285fdc['isAttached']=()=>_0x285fdc['_isAttached'],_0x285fdc;}function P(_0x1fbdfe,_0x420d3b,_0x66543e){const _0x80d9f='elementEnd'==_0x1fbdfe['type']?_0x66543e['createPositionAt'](_0x1fbdfe['item'],'end'):_0x66543e['createPositionBefore'](_0x1fbdfe['item']);return _0x66543e['createPositionFromPath'](_0x420d3b,_0x80d9f['path'],_0x80d9f['stickiness']);}function V(_0x139b13,_0x16c67c,_0x28d910){const _0x3dfbf9='elementStart'==_0x139b13['type']?_0x28d910['createPositionAt'](_0x139b13['item'],0x0):_0x28d910['createPositionAfter'](_0x139b13['item']);return _0x28d910['createPositionFromPath'](_0x16c67c,_0x3dfbf9['path'],_0x3dfbf9['stickiness']);}class me extends/* #__PURE__ -- @preserve */
25
- _0x598ba2(_0x54ee3c){['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x1c6287,_0x2a9e57){super(_0x1c6287),this['focusTracker']=new _0x32e82f(),this['keystrokes']=new _0x2ae060(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x2a9e57),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'](),_0x2738e4({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x14c712=_0x3de169=>_0x3de169['stopPropagation']();this['keystrokes']['set']('arrowright',_0x14c712),this['keystrokes']['set']('arrowleft',_0x14c712),this['keystrokes']['set']('arrowup',_0x14c712),this['keystrokes']['set']('arrowdown',_0x14c712);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x17ac13){this['revisionNameInputView']['fieldView']['element']['value']=_0x17ac13['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x21cb88){const _0x155f51=new et(this['locale'],ti),_0x49e077=_0x155f51['fieldView'];_0x49e077['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x41eb60=R(this['locale'],'Name\x20of\x20the\x20revision');return!_0x21cb88&&(_0x41eb60+='\x20('+R(this['locale'],'optional')+')'),(_0x155f51['label']=_0x41eb60,_0x49e077['on']('input',()=>{this['revisionNameInputValue']=_0x49e077['element']['value']['trim']();}),_0x155f51);}}class v extends _0x449360{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h];}['_saveRevisionFormView'];['init'](){const _0x3785c4=this['editor'],_0x2c2af4=_0x3785c4['plugins']['get']('RevisionTracker');_0x3785c4['ui']['componentFactory']['add']('revisionHistory',_0x3300a6=>{const _0x1f64c2=_0x3b7ce8(_0x3300a6),_0x4fe7d4=_0x1f64c2['panelView']['children'],_0x5c86f6=new _0x171f64(_0x3300a6),_0x28bd8d=new _0x5d7c86(_0x3300a6),_0x3ac53f=new _0x29e09a(_0x3300a6),_0x709315=new _0x5d7c86(_0x3300a6),_0xdaf64a=new _0x29e09a(_0x3300a6);return _0x1f64c2['bind']('isEnabled')['to'](_0x2c2af4,'isReady',_0x2c2af4,'isEnabled',_0x3785c4,'isReadOnly',(_0x580e2c,_0x20fb47,_0x222a09)=>_0x580e2c&&_0x20fb47&&!_0x222a09),_0x1f64c2['buttonView']['set']({'icon':_0x507409,'label':R(_0x3300a6,'Revision\x20history'),'tooltip':!0x0}),_0x3ac53f['set']({'label':R(_0x3300a6,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x3ac53f['bind']('isEnabled')['to'](_0x2c2af4,'isReady',_0x2c2af4,'isEnabled',_0x3785c4,'isReadOnly',(_0x3c3278,_0x34b443,_0x582f14)=>_0x3c3278&&_0x34b443&&!_0x582f14),_0x3ac53f['on']('execute',()=>this['_showDialog']()),_0xdaf64a['set']({'label':R(_0x3300a6,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0xdaf64a['bind']('isEnabled')['to'](_0x2c2af4,'isReady',_0x3785c4,'isReadOnly',(_0x481c80,_0x3f653c)=>_0x481c80&&!_0x3f653c),_0xdaf64a['on']('execute',()=>{_0x3785c4['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x1f64c2['isOpen']=!0x1,_0x3785c4['editing']['view']['focus']();}),_0x28bd8d['children']['add'](_0x3ac53f),_0x709315['children']['add'](_0xdaf64a),_0x5c86f6['role']='menu',_0x5c86f6['items']['addMany']([_0x28bd8d,_0x709315]),_0x4fe7d4['add'](_0x5c86f6),_0x1f64c2;}),_0x3785c4['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x3bed65=this['editor'],_0x3bad1c=_0x3bed65['locale'],_0x5968cc=new _0x51e6c0(_0x3bad1c),_0x1dd084=new _0x338638(_0x3bad1c);_0x5968cc['buttonView']['set']({'icon':_0x507409,'label':R(_0x3bad1c,'Revision\x20history')});const _0xf711a0=new _0x517569(_0x3bad1c,_0x5968cc),_0xad6e1=new _0xcd3c27(_0x3bad1c);_0xad6e1['set']({'label':R(_0x3bad1c,'Save\x20current\x20revision')}),_0xad6e1['delegate']('execute')['to'](_0x5968cc),_0xad6e1['on']('execute',()=>{this['_showDialog']();}),_0xf711a0['children']['add'](_0xad6e1),_0x1dd084['items']['add'](_0xf711a0);const _0x59f0a0=new _0x517569(_0x3bad1c,_0x5968cc),_0x5e6221=new _0xcd3c27(_0x3bad1c);return _0x5e6221['set']({'label':R(_0x3bad1c,'Open\x20revision\x20history')}),_0x5e6221['delegate']('execute')['to'](_0x5968cc),_0x5e6221['on']('execute',()=>{_0x3bed65['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x59f0a0['children']['add'](_0x5e6221),_0x1dd084['items']['add'](_0x59f0a0),_0x5968cc['panelView']['children']['add'](_0x1dd084),_0x5968cc;}['_showDialog'](){const _0x1d43de=this['editor'],_0x82199=_0x1d43de['locale'],_0x2d2407=_0x1d43de['plugins']['get']('Dialog'),_0x1e3fff=_0x1d43de['plugins']['get']('RevisionTracker');function _0x4bc563(_0x390485){_0x1d43de['config']['get']('revisionHistory.requireRevisionName')&&''===_0x390485['revisionName']?_0x390485['revisionNameInputView']['errorText']=R(_0x82199,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x1d43de['plugins']['get'](h)['saveRevision']({'name':_0x390485['revisionName']}),_0x2d2407['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x4bc563(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x2d2407['show']({'id':'revisionSave','title':R(_0x82199,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':R(_0x1d43de['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x2d2407['hide']()},{'label':R(_0x1d43de['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x4fd90e){_0x4fd90e['bind']('isEnabled')['to'](_0x1e3fff,'isReady',_0x1e3fff,'isEnabled',_0x1d43de,'isReadOnly',(_0x3fd1cc,_0x14f05d,_0x268f5e)=>_0x3fd1cc&&_0x14f05d&&!_0x268f5e);},'onExecute':()=>_0x4bc563(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x16da49=this['editor'],_0x16d7d8=_0x16da49['locale'];this['_saveRevisionFormView']=new me(_0x16d7d8,_0x16da49['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class z extends _0x54ee3c{['changeId'];['_model'];constructor(_0x278f8e,_0x22c88b){super(_0x278f8e),this['_model']=_0x22c88b,this['changeId']=_0x22c88b['id'];const _0x21b63a=this['bindTemplate'],_0x182041=R(_0x278f8e,_0x22c88b['data']['isSuggestion']?'Suggested\x20by':'add'==_0x22c88b['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x22c88b['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x21b63a['to']('type',_0x2da43c=>'ck-revision-change__'+_0x2da43c)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x182041}]},{'text':'\x20'+_0x22c88b['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class G extends/* #__PURE__ -- @preserve */
26
- _0x289903(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x39c491){super(),this['id']=_0x39c491['id']||_0x20586a(),this['author']=_0x39c491['author'],this['type']=_0x39c491['type'],this['data']=_0x39c491['data']||{},this['rootName']=_0x39c491['rootName'],this['set']('createdAt',_0x39c491['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(_0x299895,_0x4001e4){this['newRevisionId']=_0x299895,this['oldRevisionId']=_0x4001e4,this['changes']=new _0x59f5e7();}['_setChanges'](_0x4e6db1){for(const _0x3dc21c of _0x4e6db1)this['changes']['add'](_0x3dc21c);}}class l extends _0x449360{['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[_0x3b5410,_0x330ba8,S,$];}constructor(_0x595279){super(_0x595279),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',(_0x4535d5,_0x1259a7,_0x4a7670)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x5a6c2d=>{for(const _0x414d9a of this['editor']['editing']['view']['document']['roots'])_0x4a7670?_0x5a6c2d['removeClass']('ck-editor__editable__overlay',_0x414d9a):_0x5a6c2d['addClass']('ck-editor__editable__overlay',_0x414d9a);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x552fa6=>null!==_0x552fa6),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0xda9998,_0x583bf1,_0x59df36)=>_0xda9998&&_0x59df36?_0x583bf1['changes']['getIndex'](_0x59df36):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x4dea43,_0x2c26b9)=>_0x4dea43?_0x2c26b9['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0x330ba8);}['init'](){const _0xd5ce69=this['editor'],_0x4ab9c9=new rt(_0xd5ce69,{'direction':'backward'}),_0x4e374d=new rt(_0xd5ce69,{'direction':'forward'});(_0xd5ce69['commands']['add']('showPreviousChange',_0x4ab9c9),_0xd5ce69['commands']['add']('showNextChange',_0x4e374d),_0xd5ce69['commands']['add']('restoreRevision',new nt(_0xd5ce69)),this['on']('change:numberOfChanges',()=>{_0x4ab9c9['refresh'](),_0x4e374d['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0xd5ce69['enableReadOnlyMode']('revision-viewer'),_0xd5ce69['plugins']['has']('WidgetToolbarRepository'))&&_0xd5ce69['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x46d294){return await this['_utils']['loadRevisionData'](_0x46d294,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x46d294);}async['getRevisionRootsAttributes'](_0x56547d){return await this['_utils']['loadRevisionData'](_0x56547d,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x56547d);}async['compare'](_0x527782,_0x2b8034,_0x3b6886=!0x1){if(!this['isEnabled'])return;const _0xd89e9=this['diff'],_0x46e985=this['repository'],_0x392c71='string'==typeof _0x527782?_0x46e985['getRevision'](_0x527782):_0x527782,_0x37c443='string'==typeof _0x2b8034?_0x46e985['getRevision'](_0x2b8034):_0x2b8034,_0x5f3376=_0x392c71['id'],_0xfb3a9=_0x37c443?_0x37c443['id']:null;if(!_0x3b6886&&this['diff']&&this['diff']['newRevisionId']===_0x5f3376&&this['diff']['oldRevisionId']===_0xfb3a9)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new J(_0x5f3376,_0xfb3a9);const _0x9e92c4=this['_getRevisionsRange'](_0x392c71,_0x37c443,!0x0)['map'](_0x323309=>this['_utils']['loadRevisionData'](_0x323309,this['adapter']));return _0x9e92c4['push'](new Promise(_0x3343c5=>{setTimeout(_0x3343c5,0x14);})),Promise['all'](_0x9e92c4)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0xad3c0b=this['_getDiff'](_0x5f3376,_0xfb3a9);for(const _0x10f190 of _0xad3c0b['changes'])this['_changeIdToChange']['set'](_0x10f190['id'],_0x10f190);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x189206=>{for(const _0x3cbca3 of this['editor']['model']['document']['getRootNames']())_0x189206['detachRoot'](_0x3cbca3);for(const _0x133d6f of Object['keys'](_0xad3c0b['model'])){const _0x3c4ba0=_0x189206['addRoot'](_0x133d6f);for(const _0x2eaa9c of Object['keys'](_0xad3c0b['attributes'][_0x133d6f]))_0x189206['setAttribute'](_0x2eaa9c,_0xad3c0b['attributes'][_0x133d6f][_0x2eaa9c],_0x3c4ba0);_0x189206['insert'](_0xad3c0b['model'][_0x133d6f],_0x3c4ba0,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0xad3c0b['changes'])),this['isReady']=!0x0;})['catch'](_0x550ed7=>{console['error'](_0x550ed7),this['_cleanUp'](),_0xd89e9&&(this['diff']=_0xd89e9),this['isReady']=!0x0;});}['addRevisionData'](_0x3f7674,_0x4ed717){const _0x54dfee=this['repository']['createRevision'](_0x3f7674);return _0x54dfee['on']('_update',(_0x5407a4,_0x378fc0,_0x572a49)=>_0x4ed717(_0x378fc0,_0x572a49,_0x54dfee)),this['repository']['addRevision'](_0x54dfee),_0x54dfee;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x417b2c=>{for(const _0x4e731d of this['editor']['model']['document']['getRootNames']())_0x417b2c['detachRoot'](_0x4e731d);});}['_sortAndFilterDiffChanges'](_0x345634){const _0x4494a5=[],_0x80bd8d=new Map();for(const _0xd7f468 of this['editor']['model']['document']['getRootNames']()){const _0x2ab7da=this['editor']['editing']['view']['getDomRoot'](_0xd7f468);if(!_0x2ab7da)continue;const _0x2fcee4=_0x2ab7da['getClientRects']()['item'](0x0);_0x2fcee4&&(_0x4494a5['push'](_0xd7f468),_0x80bd8d['set'](_0xd7f468,_0x2fcee4));}return _0x4494a5['sort']((_0x333a49,_0x2a22c0)=>{const _0x23d2bb=_0x80bd8d['get'](_0x333a49),_0x4ef9c1=_0x80bd8d['get'](_0x2a22c0);return _0x23d2bb['y']-_0x4ef9c1['y']||_0x23d2bb['x']-_0x4ef9c1['x'];}),(_0x345634=_0x345634['filter'](_0x4c85e4=>_0x4494a5['includes'](_0x4c85e4['rootName'])))['sort']((_0x9ca032,_0x251efc)=>_0x4494a5['indexOf'](_0x9ca032['rootName'])-_0x4494a5['indexOf'](_0x251efc['rootName'])),_0x345634;}['_makeTape'](_0x3460ab){const _0x140658=Array['from'](_0x3460ab['markers'])['filter'](([_0x1ed99a,_0x1906ed])=>_0x1ed99a['startsWith']('revision:')&&!_0x1906ed['isCollapsed']),_0x53a06e=Array['from'](this['editor']['model']['createRangeIn'](_0x3460ab)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x140658['length'])for(const _0x2bb9a0 of _0x53a06e){const [_0x389677,_0x56edd2]=_0x140658[0x0],[,_0x248d70,_0x245866]=_0x389677['split'](':');if(_0x56edd2['end']['isEqual'](_0x2bb9a0['nextPosition'])&&_0x140658['shift'](),(_0x2bb9a0['previousPosition']['isEqual'](_0x56edd2['start'])||_0x2bb9a0['previousPosition']['isAfter'](_0x56edd2['start']))&&('insertion'==_0x248d70?_0x2bb9a0['isAdded']={'userId':_0x245866}:'deletion'==_0x248d70&&(_0x2bb9a0['isRemoved']={'userId':_0x245866})),0x0==_0x140658['length'])break;}return _0x53a06e;}['_refreshStartEndIndex'](_0x857279){const _0x5d687c=new Map();for(let _0x35f72d=0x0;_0x35f72d<_0x857279['length'];_0x35f72d++)'text'===_0x857279[_0x35f72d]['type']?(_0x857279[_0x35f72d]['item']['startIndex']=_0x35f72d,_0x857279[_0x35f72d]['item']['endIndex']=_0x35f72d):('elementStart'===_0x857279[_0x35f72d]['type']?_0x857279[_0x35f72d]['item']['startIndex']=_0x35f72d:'elementEnd'===_0x857279[_0x35f72d]['type']&&(_0x857279[_0x35f72d]['item']['endIndex']=_0x35f72d),_0x5d687c['set'](_0x857279[_0x35f72d]['id'],_0x35f72d));for(const _0x37a2f8 of _0x5d687c['values']())'elementStart'===_0x857279[_0x37a2f8]['type']?_0x857279[_0x37a2f8]['item']['endIndex']=_0x5d687c['get'](_0x857279[_0x37a2f8]['pairId']):'elementEnd'===_0x857279[_0x37a2f8]['type']&&(_0x857279[_0x37a2f8]['item']['startIndex']=_0x5d687c['get'](_0x857279[_0x37a2f8]['pairId']));}['_processTape'](_0x3eb857){for(let _0x3cac25=0x0;_0x3cac25<_0x3eb857['length'];_0x3cac25++){if('elementStart'===_0x3eb857[_0x3cac25]['type'])_0x3eb857[_0x3cac25]['item']['startIndex']=_0x3cac25;else{if('elementEnd'===_0x3eb857[_0x3cac25]['type']){_0x3eb857[_0x3cac25]['item']['endIndex']=_0x3cac25;const _0x3364de=_0x3eb857[_0x3cac25]['item']['startIndex'];_0x3eb857[_0x3364de]['pairId']=_0x3eb857[_0x3cac25]['id'],_0x3eb857[_0x3cac25]['pairId']=_0x3eb857[_0x3364de]['id'];}else _0x3eb857[_0x3cac25]['item']['startIndex']=_0x3cac25,_0x3eb857[_0x3cac25]['item']['endIndex']=_0x3cac25,_0x3eb857[_0x3cac25]['pairId']=null;}_0x3eb857[_0x3cac25]['markersStart']||(_0x3eb857[_0x3cac25]['markersStart']=[],_0x3eb857[_0x3cac25]['markersEnd']=[]);}}['_markInsertions'](_0x45fbd5,_0x70642a){const _0x109a04=_0x45fbd5['filter'](_0x43b5ad=>!_0x43b5ad['isAdded']);for(let _0x32a7d6=0x0;_0x32a7d6<_0x70642a['length'];_0x32a7d6++)_0x70642a[_0x32a7d6]['isAdded']&&(_0x109a04[_0x32a7d6]['isAdded']=_0x70642a[_0x32a7d6]['isAdded']);}['_getDiff'](_0x31f50a,_0x47cfd4=null){const _0x2b2adc=this['repository']['getRevision'](_0x31f50a),_0x2710f0=_0x47cfd4?this['repository']['getRevision'](_0x47cfd4):null,_0x3d7fe6=this['_getRevisionsRange'](_0x2b2adc,_0x2710f0),_0x3ab4d8=_0x3d7fe6[_0x3d7fe6['length']-0x1],_0x5ab07e=new Map(),_0x27bcf4={'model':{},'attributes':{},'changes':[]},_0x41dc4f=new Set(),_0x876c33=new Map();for(let _0xf0eab1=_0x3d7fe6['length']-0x1;_0xf0eab1>=0x0;_0xf0eab1--){const _0x3c6f60=_0x3d7fe6[_0xf0eab1];for(const _0x3405c0 of Object['keys'](_0x3c6f60['diffData']))if(_0x3c6f60['diffData'][_0x3405c0]['attachChange']){const _0x1b7dd5=_0x3c6f60['diffData'][_0x3405c0]['attachChange'];_0x1b7dd5['isAttached']?(_0x41dc4f['add'](_0x3405c0),_0x876c33['has'](_0x3405c0)&&_0x876c33['get'](_0x3405c0)['userId']==_0x1b7dd5['userId']?_0x876c33['delete'](_0x3405c0):_0x876c33['set'](_0x3405c0,_0x1b7dd5)):_0x876c33['has'](_0x3405c0)?(_0x41dc4f['delete'](_0x3405c0),_0x876c33['delete'](_0x3405c0)):(_0x41dc4f['add'](_0x3405c0),_0x876c33['set'](_0x3405c0,_0x1b7dd5));}else _0x41dc4f['add'](_0x3405c0);}for(const _0x419bd4 of _0x41dc4f){const _0x2c9a32=_0x876c33['has'](_0x419bd4)&&!_0x876c33['get'](_0x419bd4)['isAttached'];let _0x584de5=_0x2c9a32?_0x3d7fe6['length']-0x1:0x0;const _0x2d46b6=_0x2c9a32?-0x1:0x1;for(;_0x3d7fe6[_0x584de5];){const _0x23a34a=_0x3d7fe6[_0x584de5];if(_0x23a34a['diffData'][_0x419bd4]){const _0xddde14=_0x2c9a32?_0x23a34a['diffData'][_0x419bd4]['attributesBefore']:_0x23a34a['diffData'][_0x419bd4]['attributesAfter'];_0x27bcf4['attributes'][_0x419bd4]=_0xddde14?_0x16a120(_0xddde14):{};break;}_0x584de5+=_0x2d46b6;}}for(const _0x21812b of _0x3d7fe6){_0x21812b['model']={};for(const _0x336c41 of _0x21812b['authors'])_0x5ab07e['set'](_0x336c41['id'],_0x336c41);for(const _0xea867d of _0x41dc4f){const _0x455354=_0x21812b['diffData'][_0xea867d]?_0x21812b['diffData'][_0xea867d]['insertions']:'[]',_0xc5b32d=_0x21812b['diffData'][_0xea867d]?_0x21812b['diffData'][_0xea867d]['deletions']:'[]';_0x21812b['model'][_0xea867d]={'insertions':this['_utils']['_makeModelFromViewString'](_0x455354),'deletions':this['_utils']['_makeModelFromViewString'](_0xc5b32d)};}}for(const _0x4afe6b of _0x41dc4f){let _0x5c451c=null,_0xe14514=0x0;const _0x59d09e=new Map(Array['from'](_0x2b2adc['model'][_0x4afe6b]['insertions']['markers'])['filter'](([_0x46581f])=>!_0x46581f['startsWith']('revision:')));let _0x43a1e2=0x0;for(const _0x5c05df of _0x3d7fe6){const _0x7bf391=this['_makeTape'](_0x5c05df['model'][_0x4afe6b]['insertions']);_0x5c05df==_0x2b2adc?(_0x5c451c=_0x7bf391,_0xe14514=_0x5c451c['length'],_0x5c451c['forEach'](_0x2fb990=>{_0x2fb990['id']=_0x43a1e2++;}),this['_processTape'](_0x5c451c)):this['_markInsertions'](_0x5c451c,_0x7bf391);const _0xb438ad=_0x5c451c['filter'](_0x47ca5d=>!_0x47ca5d['isAdded'])['map'](_0xad2624=>_0xad2624['id']);let _0x12aa60=0x0;const _0x11a3cd=this['_makeTape'](_0x5c05df['model'][_0x4afe6b]['deletions']);_0x11a3cd['forEach'](_0x498e08=>{_0x498e08['isRemoved']?_0x498e08['id']=_0xe14514++:_0x498e08['id']=_0xb438ad[_0x12aa60++];}),this['_processTape'](_0x11a3cd),this['_setDistance'](_0x5c451c,'isAdded'),this['_setDistance'](_0x11a3cd,'isRemoved'),_0x5c05df==_0x2b2adc&&this['_markMarkers'](_0x5c451c,_0x59d09e),_0x5c451c=this['_joinTapes'](_0x5c451c,_0x11a3cd),this['_refreshStartEndIndex'](_0x5c451c),this['_setDistance'](_0x5c451c,'isRemoved');}_0x5c451c=_0x5c451c['filter'](_0x1bda6c=>!(_0x1bda6c['isAdded']&&_0x1bda6c['isRemoved']));const _0x638b39=new Map(_0x3ab4d8['model'][_0x4afe6b]['deletions']['markers']),_0x2ad6c2=new Set(_0x59d09e['keys']());for(const _0x444a10 of _0x638b39['keys']())_0x2ad6c2['delete'](_0x444a10);this['_markSuggestions'](_0x5c451c,_0x2ad6c2),this['_fixObsoleteTags'](_0x5c451c),_0x5c451c=this['_removeMissingPairs'](_0x5c451c),_0x5c451c=this['_markMismatchedRemovedTags'](_0x5c451c),_0x5c451c=this['_removeUnsupportedChanges'](_0x5c451c);const {root:_0x188902,changes:_0x17f88c}=this['_makeModelFromTape'](_0x5c451c,_0x5ab07e,_0x4afe6b);_0x27bcf4['model'][_0x4afe6b]=_0x188902;const _0x1ebc40=_0x876c33['get'](_0x4afe6b);if(_0x1ebc40){const _0x4d2b99=_0x5ab07e['get'](_0x1ebc40['userId']),_0x1d2aea=new G({'author':_0x4d2b99,'type':_0x1ebc40['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x4afe6b});_0x17f88c['unshift'](_0x1d2aea),_0x27bcf4['attributes'][_0x4afe6b]['revisionHistoryAttachChange']=_0x1d2aea['id'];}_0x27bcf4['changes']=_0x27bcf4['changes']['concat'](_0x17f88c);}return _0x27bcf4;}['_markMarkers'](_0x42177b,_0x447643){for(let _0x160b99=0x0;_0x160b99<_0x42177b['length'];_0x160b99++)for(const [_0x375aad,_0x6285d8]of _0x447643)!_0x6285d8['isCollapsed']&&_0x6285d8['start']['isEqual'](_0x42177b[_0x160b99]['previousPosition'])&&_0x42177b[_0x160b99]['markersStart']['push'](_0x375aad),_0x6285d8['end']['isEqual'](_0x42177b[_0x160b99]['nextPosition'])&&_0x42177b[_0x160b99]['markersEnd']['push'](_0x375aad);}['_joinTapes'](_0x1ea75c,_0xde5a7f){let _0x214bd7=[],_0x4ee342=0x0,_0x50ec9f=0x0;for(;_0x4ee342<_0x1ea75c['length']||_0x50ec9f<_0xde5a7f['length'];){const _0x4d0fdf=_0x1ea75c[_0x4ee342]||{},_0x396e4a=_0xde5a7f[_0x50ec9f]||{};if(_0x4d0fdf['id']==_0x396e4a['id'])_0x4ee342++,_0x50ec9f++,_0x214bd7['push'](_0x4d0fdf);else{if(_0x396e4a['isRemoved']&&_0x4d0fdf['isAdded']){const {commonTape:_0x506223,iEnd:_0xb8f4,jEnd:_0x2b0405}=this['_threeWayMerge'](_0x1ea75c,_0x4ee342,_0xde5a7f,_0x50ec9f);_0x214bd7=_0x214bd7['concat'](_0x506223),_0x4ee342=_0xb8f4,_0x50ec9f=_0x2b0405;}else _0x396e4a['isRemoved']?(_0x50ec9f++,_0x214bd7['push'](_0x396e4a)):(_0x4ee342++,_0x214bd7['push'](_0x4d0fdf));}}return _0x214bd7;}['_markSuggestions'](_0x12bed6,_0x42c213){const _0x311375=[];for(let _0x531e00=0x0;_0x531e00<_0x12bed6['length'];_0x531e00++){for(let _0x1ce4ce=0x0;_0x1ce4ce<_0x12bed6[_0x531e00]['markersStart']['length'];_0x1ce4ce++){const _0x1c87bc=_0x12bed6[_0x531e00]['markersStart'][_0x1ce4ce];if(!_0x42c213['has'](_0x1c87bc))continue;const {group:_0x2829d0,type:_0x1c41f0,authorId:_0xf3f558}=_0x28a9bf(_0x1c87bc);'revision-suggestion'!=_0x2829d0||'insertion'!=_0x1c41f0&&'deletion'!=_0x1c41f0||(_0x311375['unshift']({'type':_0x1c41f0,'name':_0x1c87bc,'userId':_0xf3f558}),_0x12bed6[_0x531e00]['markersStart']['splice'](_0x1ce4ce,0x1),_0x1ce4ce--);}_0x2914ea(_0x12bed6[_0x531e00]);for(let _0x508cff=0x0;_0x508cff<_0x12bed6[_0x531e00]['markersEnd']['length'];_0x508cff++){const _0x1f1c4d=_0x12bed6[_0x531e00]['markersEnd'][_0x508cff];if(!_0x42c213['has'](_0x1f1c4d))continue;const {group:_0x3e09a9,type:_0x152dd3}=_0x28a9bf(_0x1f1c4d);if('revision-suggestion'!=_0x3e09a9||'insertion'!=_0x152dd3&&'deletion'!=_0x152dd3)continue;_0x12bed6[_0x531e00]['markersEnd']['splice'](_0x508cff,0x1),_0x508cff--;const _0x1b0e3f=_0x311375['findIndex'](_0x3d23b7=>_0x3d23b7['name']==_0x1f1c4d);_0x1b0e3f>-0x1&&_0x311375['splice'](_0x1b0e3f,0x1);}}function _0x28a9bf(_0xe72127){const _0xf67830=_0xe72127['split'](':');return{'group':_0xf67830[0x0],'type':_0xf67830[0x1],'subType':_0xf67830['length']>=0x5?_0xf67830[0x2]:null,'id':_0xf67830['length']<0x5?_0xf67830[0x2]:_0xf67830[0x3],'authorId':_0xf67830['length']<0x5?_0xf67830[0x3]:_0xf67830[0x4],'markerCount':0x6==_0xf67830['length']?_0xf67830[0x5]:null};}function _0x2914ea(_0x4cc650){for(let _0x1f4f78=0x0;_0x1f4f78<_0x311375['length'];_0x1f4f78++){if(_0x4cc650['isAdded']&&'insertion'==_0x311375[_0x1f4f78]['type']&&_0x4cc650['isAdded']['userId']==_0x311375[_0x1f4f78]['userId'])return _0x4cc650['isAddSuggestion']=_0x311375[_0x1f4f78],void delete _0x4cc650['isAdded'];if(!_0x4cc650['isAdded']&&!_0x4cc650['isRemoved']&&'deletion'==_0x311375[_0x1f4f78]['type'])return void(_0x4cc650['isRemoveSuggestion']=_0x311375[_0x1f4f78]);}}}['_setDistance'](_0x5865d7,_0x1a904d){let _0x538ac8=0x0,_0xe9b4=!0x1;const _0x356fc0=new Map();for(const _0x29d1a7 of _0x5865d7)_0x29d1a7[_0x1a904d]?_0xe9b4&&(_0x538ac8++,_0xe9b4=!0x1):(_0x538ac8++,_0xe9b4=!0x0),_0x356fc0['set'](_0x29d1a7['id'],_0x538ac8);for(let _0x4f37f8=0x0;_0x4f37f8<_0x5865d7['length'];_0x4f37f8++){if('isRemoved'==_0x1a904d&&_0x5865d7[_0x4f37f8]['isAdded']||'isAdded'==_0x1a904d&&_0x5865d7[_0x4f37f8]['isRemoved'])continue;if('text'==_0x5865d7[_0x4f37f8]['type']){_0x5865d7[_0x4f37f8]['distance']=0x0;continue;}const _0x4ad5cf=_0x356fc0['get'](_0x5865d7[_0x4f37f8]['pairId']),_0x3efc93=_0x356fc0['get'](_0x5865d7[_0x4f37f8]['id']);_0x5865d7[_0x4f37f8]['distance']=_0x4ad5cf-_0x3efc93;}}['_getRevisionsRange'](_0x298e8e,_0x2df6ed,_0x44a110=!0x1){const _0x558750=[];let _0x57afe7=this['repository']['getIndex'](_0x298e8e),_0x4b614d=this['repository']['getIndex'](_0x2df6ed);for(-0x1==_0x4b614d&&(_0x4b614d=this['repository']['_revisions']['length'],_0x44a110=!0x1);_0x57afe7<_0x4b614d;)_0x558750['push'](this['repository']['getRevision'](_0x57afe7)),_0x57afe7++;return _0x44a110&&_0x558750['push'](this['repository']['getRevision'](_0x57afe7)),_0x558750;}['_threeWayMerge'](_0x462426,_0x227cea,_0xb65a47,_0x23c652){const _0x3d25fb=this['editor']['model']['schema'];let _0x39da1d=_0x227cea;for(;_0x462426[_0x39da1d]&&_0x462426[_0x39da1d]['isAdded'];)_0x39da1d++;let _0x5511c9=_0x23c652;for(;_0xb65a47[_0x5511c9]&&_0xb65a47[_0x5511c9]['isRemoved'];)_0x5511c9++;_0x404502(_0x462426,_0x227cea,_0x39da1d),_0x404502(_0xb65a47,_0x23c652,_0x5511c9);const _0x22e777=_0xb65a47['slice'](_0x23c652,_0x5511c9)['concat'](_0x462426['slice'](_0x227cea,_0x39da1d));return _0x22e777['sort']((_0x39c747,_0x4972f0)=>_0x39c747['side']!=_0x4972f0['side']?_0x39c747['side']-_0x4972f0['side']:_0x39c747['level']!=_0x4972f0['level']?_0x39c747['level']-_0x4972f0['level']:_0x39c747['distance']!=_0x4972f0['distance']?_0x4972f0['distance']-_0x39c747['distance']:!!_0x39c747['isAdded']!=!!_0x4972f0['isAdded']?-0x1==_0x39c747['side']||0x0==_0x39c747['side']?_0x39c747['isAdded']?-0x1:0x1:_0x39c747['isAdded']?0x1:-0x1:_0x39c747['index']-_0x4972f0['index']),{'commonTape':_0x22e777,'iEnd':_0x39da1d,'jEnd':_0x5511c9};function _0x404502(_0x1c1a77,_0x225919,_0x38c775){let _0x26cd05=-0x1,_0x449bcb=Number['POSITIVE_INFINITY'],_0x19b6b8=!0x0;for(let _0x4641f8=_0x225919;_0x4641f8<_0x38c775;_0x4641f8++)if(_0x3d25fb['isInline'](_0x1c1a77[_0x4641f8]['item'])||(_0x19b6b8=!0x1),_0x1c1a77[_0x4641f8]['item']['startIndex']<_0x225919&&(_0x26cd05=_0x4641f8),_0x1c1a77[_0x4641f8]['item']['endIndex']>=_0x38c775){_0x449bcb=_0x4641f8;break;}_0x19b6b8&&(_0x26cd05=_0x38c775-0x1);for(let _0x38cfd3=_0x225919;_0x38cfd3<_0x38c775;_0x38cfd3++)_0x1c1a77[_0x38cfd3]['side']=_0x38cfd3<=_0x26cd05?-0x1:_0x38cfd3<_0x449bcb?0x0:0x1,_0x1c1a77[_0x38cfd3]['index']=_0x38cfd3;let _0x5df775=0x0;for(let _0x10469b=_0x225919;_0x10469b<=_0x26cd05;_0x10469b++)0x0==_0x1c1a77[_0x10469b]['distance']?_0x1c1a77[_0x10469b]['level']=_0x5df775:(_0x5df775++,_0x1c1a77[_0x10469b]['level']=_0x5df775,_0x5df775++);for(let _0x2944ac=_0x225919;_0x2944ac<_0x38c775;_0x2944ac++)0x0==_0x1c1a77[_0x2944ac]['side']&&(_0x1c1a77[_0x2944ac]['level']=_0x5df775);_0x5df775=0x0;for(let _0x5eaae9=_0x38c775-0x1;_0x5eaae9>=_0x449bcb;_0x5eaae9--)0x0==_0x1c1a77[_0x5eaae9]['distance']?_0x1c1a77[_0x5eaae9]['level']=_0x5df775:(_0x5df775--,_0x1c1a77[_0x5eaae9]['level']=_0x5df775,_0x5df775--);}}['_fixObsoleteTags'](_0x17a2ed){const _0x909db8=new Map(),_0x4cad9c=this['editor']['model']['schema'];for(let _0x16787e=0x1;_0x16787e<_0x17a2ed['length'];_0x16787e++){let _0x416cd0,_0x30bda3,_0x5cb983;const _0x300144=_0x17a2ed[_0x16787e],_0x31ebfb=_0x17a2ed[_0x16787e-0x1];if('text'==_0x300144['type'])continue;if(_0x300144['type']!=_0x31ebfb['type'])continue;if(!_0x4cad9c['isBlock'](_0x31ebfb['item'])||_0x4cad9c['isLimit'](_0x31ebfb['item']))continue;if(!_0x4cad9c['isBlock'](_0x300144['item'])||_0x4cad9c['isLimit'](_0x300144['item']))continue;if((_0x17a2ed[_0x16787e]['isAdded']||_0x17a2ed[_0x16787e]['isAddSuggestion'])&&_0x17a2ed[_0x16787e-0x1]['isRemoved'])_0x416cd0=_0x17a2ed[_0x16787e],_0x30bda3=_0x17a2ed[_0x16787e-0x1],_0x5cb983=_0x16787e-0x1;else{if(!_0x17a2ed[_0x16787e]['isRemoved']||!_0x17a2ed[_0x16787e-0x1]['isAdded']&&!_0x17a2ed[_0x16787e-0x1]['isAddSuggestion'])continue;_0x416cd0=_0x17a2ed[_0x16787e-0x1],_0x30bda3=_0x17a2ed[_0x16787e],_0x5cb983=_0x16787e;}const _0x2731ec=_0x416cd0['level']==_0x30bda3['level'],_0x1dc43e=Math['abs'](_0x416cd0['level'])<Math['abs'](_0x30bda3['level'])&&0x0==_0x30bda3['distance'];(_0x2731ec||_0x1dc43e)&&(_0x909db8['set'](_0x30bda3['id'],_0x416cd0['id']),_0x17a2ed['splice'](_0x5cb983,0x1),_0x16787e--,_0x416cd0['isAdded']=!0x1);}for(let _0x2b379f=0x0;_0x2b379f<_0x17a2ed['length'];_0x2b379f++)_0x909db8['has'](_0x17a2ed[_0x2b379f]['pairId'])&&(_0x17a2ed[_0x2b379f]['pairId']=_0x909db8['get'](_0x17a2ed[_0x2b379f]['pairId']));}['_removeMissingPairs'](_0x48c23e){const _0x29605c=new Set(_0x48c23e['map'](_0x14f521=>_0x14f521['id']));for(let _0x218488=0x0;_0x218488<_0x48c23e['length'];_0x218488++)_0x29605c['has'](_0x48c23e[_0x218488]['pairId'])||0x0==_0x48c23e[_0x218488]['distance']||(_0x48c23e[_0x218488]['isIncorrect']=!0x0);return _0x48c23e['filter'](_0x571d34=>!_0x571d34['isIncorrect']);}['_markMismatchedRemovedTags'](_0x19eac4){const _0x557257=new Set();for(let _0x57b644=0x0;_0x57b644<_0x19eac4['length'];_0x57b644++){if(_0x557257['has'](_0x19eac4[_0x57b644]['id'])&&_0x19eac4[_0x57b644]['isRemoved']&&(_0x19eac4[_0x57b644]['isIncorrect']=!0x0),_0x19eac4[_0x57b644]['isIncorrect'])continue;if(0x0==_0x19eac4[_0x57b644]['distance'])continue;if('elementStart'!=_0x19eac4[_0x57b644]['type'])continue;if(null==_0x19eac4[_0x57b644]['pairId'])continue;let _0x55b1d6=_0x57b644+0x1,_0xf33b04=0x0;for(;_0x19eac4[_0x55b1d6]['id']!=_0x19eac4[_0x57b644]['pairId'];)'elementStart'==_0x19eac4[_0x55b1d6]['type']?_0xf33b04++:'elementEnd'==_0x19eac4[_0x55b1d6]['type']&&_0xf33b04--,_0x55b1d6++;if(0x0!=_0xf33b04){if(_0x19eac4[_0x57b644]['isRemoved'])_0x19eac4[_0x57b644]['isIncorrect']=!0x0;else{for(;_0x55b1d6!=_0x57b644;)_0x19eac4[_0x55b1d6]['isRemoved']&&0x0!=_0x19eac4[_0x55b1d6]['distance']&&(_0x19eac4[_0x55b1d6]['isIncorrect']=!0x0,_0x557257['add'](_0x19eac4[_0x55b1d6]['pairId'])),_0x55b1d6--;}}}return _0x19eac4['filter'](_0xf5899c=>!_0xf5899c['isIncorrect']);}['_removeUnsupportedChanges'](_0x51d54b){const _0xba62d6=this['editor']['model']['schema'];for(let _0x43c555=0x0;_0x43c555<_0x51d54b['length'];_0x43c555++){if(!(_0x51d54b[_0x43c555]['isAdded']||_0x51d54b[_0x43c555]['isAddSuggestion']||_0x51d54b[_0x43c555]['isRemoved']||_0x51d54b[_0x43c555]['isRemoveSuggestion']))continue;if(0x0==_0x51d54b[_0x43c555]['distance'])continue;const _0x111a9a=_0x51d54b[_0x43c555]['item'];_0xba62d6['isBlock'](_0x111a9a)||_0xba62d6['isLimit'](_0x111a9a)||(_0x51d54b[_0x43c555]['isAdded']&&delete _0x51d54b[_0x43c555]['isAdded'],_0x51d54b[_0x43c555]['isAddSuggestion']&&delete _0x51d54b[_0x43c555]['isAddSuggestion'],_0x51d54b[_0x43c555]['isRemoveSuggestion']&&delete _0x51d54b[_0x43c555]['isRemoveSuggestion'],_0x51d54b[_0x43c555]['isRemoved']&&(_0x51d54b[_0x43c555]['isIncorrect']=!0x0));}return _0x51d54b['filter'](_0x8c5ccd=>!_0x8c5ccd['isIncorrect']);}['_makeModelFromTape'](_0x3ba466,_0x5f41f1,_0x445057){const _0x2775fb=new _0x705efd(),_0x3a3b0b=[],_0x13a26a=new Map(),_0x787fef=this['editor']['model'],_0x3fecf7=_0x787fef['schema'],_0x266fec=[_0x2775fb],_0x11b43c={},_0x553add={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x54888d=null;const _0x655395=[0x0];for(let _0x4c601f=0x0;_0x4c601f<_0x3ba466['length'];_0x4c601f++)if('elementStart'===_0x3ba466[_0x4c601f]['type']){_0x3ba466[_0x4c601f]['previousPosition']=_0x787fef['createPositionFromPath'](_0x2775fb,_0x655395);const _0x5b820d=new _0x4d1ea2(_0x3ba466[_0x4c601f]['item']['name'],_0x3ba466[_0x4c601f]['item']['getAttributes']());_0x266fec[0x0]['_appendChild'](_0x5b820d),_0x655395['push'](0x0),_0x266fec['unshift'](_0x5b820d),_0x3ba466[_0x4c601f]['nextPosition']=_0x787fef['createPositionFromPath'](_0x2775fb,_0x655395);}else'elementEnd'===_0x3ba466[_0x4c601f]['type']?(_0x266fec['shift'](),_0x3ba466[_0x4c601f]['previousPosition']=_0x787fef['createPositionFromPath'](_0x2775fb,_0x655395),_0x655395['pop'](),_0x655395[_0x655395['length']-0x1]++,_0x3ba466[_0x4c601f]['nextPosition']=_0x787fef['createPositionFromPath'](_0x2775fb,_0x655395)):(_0x3ba466[_0x4c601f]['previousPosition']=_0x787fef['createPositionFromPath'](_0x2775fb,_0x655395),_0x54888d?_0x54888d['_data']+=_0x3ba466[_0x4c601f]['item']['data']:_0x54888d=new _0x2f22b4(_0x3ba466[_0x4c601f]['item']['data'],_0x3ba466[_0x4c601f]['item']['getAttributes']()),_0x3ba466[_0x4c601f+0x1]&&'text'===_0x3ba466[_0x4c601f+0x1]['type']&&_0x4178ac(_0x54888d,_0x3ba466[_0x4c601f+0x1]['item'])||(_0x266fec[0x0]['_appendChild'](_0x54888d),_0x54888d=null),_0x655395[_0x655395['length']-0x1]+=_0x3ba466[_0x4c601f]['item']['offsetSize'],_0x3ba466[_0x4c601f]['nextPosition']=_0x787fef['createPositionFromPath'](_0x2775fb,_0x655395));for(let _0x22e902=0x0;_0x22e902<_0x3ba466['length'];_0x22e902++){const _0x1125bc=_0x3ba466[_0x22e902]['previousPosition'],_0x1e09b3=_0x3ba466[_0x22e902]['nextPosition'];for(const _0x473134 of _0x3ba466[_0x22e902]['markersStart'])_0x13a26a['set'](_0x473134,{'start':_0x1125bc,'end':null});_0x5ae63c('isRemoveSuggestion',_0x22e902,_0x1125bc,_0x1e09b3),_0x5ae63c('isAddSuggestion',_0x22e902,_0x1125bc,_0x1e09b3),_0x5ae63c('isRemoved',_0x22e902,_0x1125bc,_0x1e09b3),_0x5ae63c('isAdded',_0x22e902,_0x1125bc,_0x1e09b3);for(const _0x4840df of _0x3ba466[_0x22e902]['markersEnd']){const _0x41b0ad=_0x13a26a['get'](_0x4840df);_0x41b0ad?_0x41b0ad['end']=_0x1e09b3:_0x13a26a['set'](_0x4840df,{'start':_0x1e09b3,'end':_0x1e09b3});}}for(const [_0x195096,_0x541450]of _0x13a26a){const _0x408130=this['editor']['model']['createRange'](_0x541450['start'],_0x541450['end']);_0x2775fb['markers']['set'](_0x195096,_0x408130);}return _0x3a3b0b['sort']((_0x48877d,_0x135680)=>{const _0x449560=_0x2775fb['markers']['get']('revision:'+_0x48877d['id']),_0x2188bb=_0x2775fb['markers']['get']('revision:'+_0x135680['id']);return _0x449560['start']['isBefore'](_0x2188bb['start'])?-0x1:_0x449560['start']['isAfter'](_0x2188bb['start'])?0x1:_0x449560['end']['isBefore'](_0x2188bb['end'])?-0x1:_0x449560['end']['isAfter'](_0x2188bb['end'])?0x1:'add'===_0x48877d['type']?-0x1:0x1;}),{'root':_0x2775fb,'changes':_0x3a3b0b};function _0x5ae63c(_0x4e2ffe,_0x3903fa,_0xcd1370,_0xe54cfc){const _0x1f95bb=!!_0x3ba466[_0x3903fa][_0x4e2ffe],_0x16d460=_0x1f95bb?_0x3ba466[_0x3903fa][_0x4e2ffe]['userId']:null,_0x11428c=_0x3903fa===_0x3ba466['length']-0x1,_0xec7107=_0x553add[_0x4e2ffe][0x0],_0x4a867a=_0x3fecf7['isObject'](_0x3ba466[_0x3903fa]['item']);!_0x11b43c[_0x4e2ffe]&&_0x1f95bb?_0x11b43c[_0x4e2ffe]={'start':_0xcd1370,'tapeItem':_0x3ba466[_0x3903fa],'userId':_0x16d460,'type':_0x4e2ffe}:_0x11b43c[_0x4e2ffe]&&!_0x1f95bb?(_0x11b43c[_0x4e2ffe]['end']=_0xcd1370,_0x247259(_0x11b43c[_0x4e2ffe]),_0x11b43c[_0x4e2ffe]=null):_0x11b43c[_0x4e2ffe]&&_0x1f95bb&&_0x11b43c[_0x4e2ffe]['userId']!==_0x16d460&&(_0x11b43c[_0x4e2ffe]['end']=_0xcd1370,_0xec7107&&_0xec7107['userId']===_0x11b43c[_0x4e2ffe]['userId']||_0x247259(_0x11b43c[_0x4e2ffe]),_0x11b43c[_0x4e2ffe]={'start':_0xcd1370,'tapeItem':_0x3ba466[_0x3903fa],'userId':_0x16d460,'type':_0x4e2ffe}),_0x11b43c[_0x4e2ffe]&&_0x4a867a&&('elementStart'!==_0x3ba466[_0x3903fa]['type']||_0xec7107&&_0xec7107['userId']===_0x16d460||_0x553add[_0x4e2ffe]['unshift']({'userId':_0x16d460,'object':_0x3ba466[_0x3903fa]['item'],'change':_0x11b43c[_0x4e2ffe]}),'elementEnd'===_0x3ba466[_0x3903fa]['type']&&_0xec7107&&_0xec7107['object']===_0x3ba466[_0x3903fa]['item']&&(_0x553add[_0x4e2ffe]['shift'](),_0x11b43c[_0x4e2ffe]=_0xec7107['change'])),_0x11b43c[_0x4e2ffe]&&_0x11428c&&(_0x11b43c[_0x4e2ffe]['end']=_0xe54cfc,_0x247259(_0x11b43c[_0x4e2ffe]),_0x11b43c[_0x4e2ffe]=null);}function _0x247259({start:_0x51205e,end:_0x249153,tapeItem:_0x24cec8,userId:_0x1a47c7,type:_0x438747}){const _0x2d890c=_0x24cec8['item'],_0x491c87=_0x787fef['schema']['isBlock'](_0x2d890c)&&!_0x787fef['schema']['isLimit'](_0x2d890c),_0x1a6c93=_0x51205e['nodeAfter']==_0x249153['parent']&&_0x249153['isAtStart'];if(_0x491c87&&_0x1a6c93)return;const _0x2b0a19=_0x787fef['createRange'](_0x51205e,_0x249153),_0x3fd1e8=_0x5f41f1['get'](_0x1a47c7),_0x471fb9=new G({'author':_0x3fd1e8,'type':'isAdded'==_0x438747||'isAddSuggestion'==_0x438747?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x438747||'isRemoveSuggestion'==_0x438747},'createdAt':new Date(),'rootName':_0x445057});_0x3a3b0b['push'](_0x471fb9),_0x2775fb['markers']['set']('revision:'+_0x471fb9['id'],_0x2b0a19);}function _0x4178ac(_0x4d4761,_0x5c0640){const _0x260fe1=_0x4d4761['getAttributes'](),_0x34ba3c=_0x5c0640['getAttributes']();for(const _0x2dfa36 of _0x260fe1){if(_0x2dfa36[0x1]!==_0x5c0640['getAttribute'](_0x2dfa36[0x0]))return!0x1;_0x34ba3c['next']();}return _0x34ba3c['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x2d952c=>{const _0x21908b=_0x2d952c['markerName']['split'](':')[0x1],_0x1bcb1a=this['_getChangeFromId'](_0x21908b);if(!_0x1bcb1a)return null;const _0x2341ee='add'==_0x1bcb1a['type']?'insertion':'deletion',_0x5bc5ad=['ck-suggestion-marker','ck-suggestion-marker-'+_0x2341ee];return _0x1bcb1a['data']['isSuggestion']&&_0x5bc5ad['push']('ck-suggestion-marker-'+_0x2341ee+'-new'),this['activeChange']==_0x1bcb1a&&_0x5bc5ad['push']('ck-suggestion-marker--active'),{'classes':_0x5bc5ad,'attributes':{'data-change-id':_0x21908b}};}}),this['editor']['conversion']['for']('upcast')['add'](_0xe0bd69=>{_0xe0bd69['on']('element:pre',(_0x26a4d0,_0x2a1e6b,_0x5a39f1)=>{const _0x27c935=_0x2a1e6b['viewItem']['getChild'](0x0);if(!_0x27c935||!_0x27c935['is']('element','code'))return;if(!_0x5a39f1['consumable']['consume'](_0x27c935,{'attributes':['vid_start','vid_end']}))return;const _0x480d4b=_0x2a1e6b['modelRange']['start']['nodeAfter'];_0x5a39f1['writer']['setAttribute']('vid_start',_0x27c935['getAttribute']('vid_start'),_0x480d4b),_0x5a39f1['writer']['setAttribute']('vid_end',_0x27c935['getAttribute']('vid_end'),_0x480d4b);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x2679a6=>{_0x2679a6['on']('element',(_0x359cf8,_0x5b71b8,_0x18efe8)=>{if(!_0x18efe8['consumable']['consume'](_0x5b71b8['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x5b71b8['modelRange']['isCollapsed'])return;const _0x53769c=_0x5b71b8['modelRange']['start']['nodeAfter'];_0x53769c['hasAttribute']('vid_start')||_0x53769c['hasAttribute']('vid')||(_0x18efe8['writer']['setAttribute']('vid_start',_0x5b71b8['viewItem']['getAttribute']('vid_start'),_0x53769c),_0x18efe8['writer']['setAttribute']('vid_end',_0x5b71b8['viewItem']['getAttribute']('vid_end'),_0x53769c));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x518fc5=>_0x518fc5['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x115c67,[,_0x198494])=>{['vid_start','vid_end','vid']['includes'](_0x198494)&&(_0x115c67['return']=!0x0,_0x115c67['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x1aa6bf=>{_0x1aa6bf['on']('attribute:vid',(_0x56979c,_0x5ab996,_0x4d4396)=>{if('\x20'!=_0x5ab996['item']['data']||_0x5ab996['item']['parent']['maxOffset']>0x1)return;if(!_0x4d4396['consumable']['consume'](_0x5ab996['item'],_0x56979c['name']))return;const _0x13cca5=_0x4d4396['writer'],_0x413566=_0x4d4396['mapper']['toViewRange'](_0x5ab996['range']);_0x13cca5['wrap'](_0x413566,_0x13cca5['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x26d5af){const _0x1b3f9a=_0x26d5af['plugins']['get']('RevisionViewer');return(_0x52ba84,_0x2af9eb,_0x194e49)=>{const _0x2c5993=_0x2af9eb['markerName']['split'](':')[0x1],_0x15d1e7=_0x1b3f9a['_getChangeFromId'](_0x2c5993);if(!_0x15d1e7)return null;const _0x416438='add'==_0x15d1e7['type']?'split':'merge';if(!_0x194e49['consumable']['test'](_0x2af9eb['markerRange'],_0x52ba84['name']))return;const _0x46e89d=_0x2af9eb['markerRange']['getWalker'](),_0x48e1bf=_0x2af9eb['markerRange']['start'],_0x172fbe=_0x26d5af['model']['schema'];let _0x2fbddb=null,_0x17ccf1=null,_0x2fbb51=!0x1,_0x35496c=!0x1;for(const _0x47674a of _0x46e89d){const _0x587b29=_0x47674a['item'];_0x2fbb51=_0x2fbb51||_0x172fbe['isContent'](_0x587b29);const _0x1aa194=_0x194e49['mapper']['toViewElement'](_0x587b29);if(_0x1aa194&&_0x1aa194['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x47674a['type']&&(_0x172fbe['isBlock'](_0x587b29)&&!_0x172fbe['isLimit'](_0x587b29)&&(_0x587b29['nextSibling']||_0x48e1bf['isAtEnd']?_0x2fbddb&&_0x2fbddb['parent']==_0x587b29||(_0x2fbddb=_0x587b29,_0x5e0000(_0x47674a['previousPosition']),_0x35496c=!0x0):_0x17ccf1=_0x17ccf1||_0x47674a['previousPosition']));}function _0x5e0000(_0x22769a){const _0x43a94c=_0x194e49['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x416438}),_0x211429=_0x194e49['mapper']['toViewPosition'](_0x22769a);_0x15d1e7['data']['isSuggestion']&&_0x194e49['writer']['addClass']('ck-suggestion-marker-'+_0x416438+'-new',_0x43a94c),_0x1b3f9a['activeChange']==_0x15d1e7&&_0x194e49['writer']['addClass']('ck-suggestion-marker--active',_0x43a94c),_0x194e49['writer']['insert'](_0x211429,_0x43a94c),_0x194e49['mapper']['bindElementToMarker'](_0x43a94c,_0x2af9eb['markerName']);}_0x2fbb51||_0x35496c||!_0x17ccf1||_0x5e0000(_0x17ccf1);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x10769c,_0x328ff0,_0x308130)=>{const _0x4c2be9=_0x308130['mapper']['markerNameToElements'](_0x328ff0['markerName']);if(_0x4c2be9){for(const _0x29ab11 of _0x4c2be9)(_0x29ab11['hasClass']('ck-suggestion-marker-split')||_0x29ab11['hasClass']('ck-suggestion-marker-merge'))&&(_0x308130['mapper']['unbindElementFromMarkerName'](_0x29ab11,_0x328ff0['markerName']),_0x308130['writer']['remove'](_0x29ab11));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x5a8cc4,_0x3c151a,_0x49a3b6)=>{const _0x5ad183=_0x3c151a['markerName']['split'](':')[0x1],_0x17caa1=this['_getChangeFromId'](_0x5ad183);if(!_0x17caa1)return null;const _0x5713f7='add'==_0x17caa1['type']?'split':'merge';if(_0x49a3b6['consumable']['test'](_0x3c151a['markerRange'],_0x5a8cc4['name']))for(const _0x32f20f of _0x3c151a['markerRange']['getItems']()){if(!_0x32f20f['is']('element','softBreak'))continue;const _0x2834dd=_0x49a3b6['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x5713f7}),_0x5e5b4b=_0x49a3b6['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x32f20f));_0x17caa1['data']['isSuggestion']&&_0x49a3b6['writer']['addClass']('ck-suggestion-marker-'+_0x5713f7+'-new',_0x2834dd),this['activeChange']==_0x17caa1&&_0x49a3b6['writer']['addClass']('ck-suggestion-marker--active',_0x2834dd),_0x49a3b6['writer']['insert'](_0x5e5b4b,_0x2834dd),_0x49a3b6['mapper']['bindElementToMarker'](_0x2834dd,_0x3c151a['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x34f701=>{for(const _0x23c05e of this['editor']['model']['document']['getRootNames']()){const _0x436339=this['editor']['model']['document']['getRoot'](_0x23c05e),_0x5481df=this['editor']['editing']['view']['document']['getRoot'](_0x23c05e);if(_0x5481df){const _0x325c13=_0x436339['getAttribute']('revisionHistoryAttachChange');if(_0x34f701['removeAttribute']('data-change-id',_0x5481df),_0x34f701['removeClass']('ck-revision-history-root-add',_0x5481df),_0x34f701['removeClass']('ck-revision-history-root-remove',_0x5481df),_0x34f701['removeClass']('ck-revision-history-root--active',_0x5481df),_0x325c13){const _0x54832d=this['_getChangeFromId'](_0x325c13);if(!_0x54832d)return null;_0x34f701['setAttribute']('data-change-id',_0x325c13,_0x5481df),_0x34f701['addClass']('ck-revision-history-root-'+_0x54832d['type'],_0x5481df),this['activeChange']==_0x54832d&&_0x34f701['addClass']('ck-revision-history-root--active',_0x5481df);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x3a7388=>'revision-comment:'+_0x3a7388,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x11b227=>'revision-suggestion:'+_0x11b227,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x9dc9db=>({'name':'suggestion:'+_0x9dc9db,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x25e262=>{const _0x1514ad=_0x25e262['markerName']['split'](':')[0x1];return'insertion'!=_0x1514ad&&'deletion'!=_0x1514ad?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x1514ad]};}}),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',(_0x44128e,_0x4b8d51,_0x370d4e)=>{const _0x43a269=_0x370d4e['mapper']['markerNameToElements'](_0x4b8d51['markerName']);if(_0x43a269){for(const _0x21bc75 of _0x43a269)_0x21bc75['is']('uiElement')&&(_0x370d4e['mapper']['unbindElementFromMarkerName'](_0x21bc75,_0x4b8d51['markerName']),_0x370d4e['writer']['remove'](_0x21bc75));}},{'priority':'high'});}['_getChangeFromId'](_0x3434c6){return this['_changeIdToChange']['get'](_0x3434c6);}['_getViewForChange'](_0x1d301c){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new z(this['editor']['locale'],_0x1d301c),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x3dff99,_0x25e0ce,_0x98ad2f,_0x4aaba8)=>{_0x4aaba8&&this['_balloon']['remove'](_0x4aaba8),_0x98ad2f&&(this['_balloon']['add']({'view':_0x98ad2f,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x317a83=this['editor']['editing'],_0x278dc5=this['_getChangeFromId'](_0x98ad2f['changeId']);let _0x41e0d9;if(_0x278dc5['data']['isOnRoot']){const _0x1d7da9=_0x317a83['view']['getDomRoot'](_0x278dc5['rootName']);_0x41e0d9=Array['from'](_0x1d7da9['getClientRects']());}else{const _0x41d8d9=this['editor']['model']['markers']['get']('revision:'+_0x98ad2f['changeId']);_0x41e0d9=Array['from'](_0x317a83['mapper']['markerNameToElements'](_0x41d8d9['name']))['map'](_0x1b9436=>_0x317a83['view']['domConverter']['mapViewToDom'](_0x1b9436))['map'](_0x402bc7=>Array['from'](_0x402bc7['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x41e0d9[0x0];return _0x41e0d9['find'](_0x9fb6c5=>_0x9fb6c5['top']-0x3<=this['_activeViewTarget']['y']&&_0x9fb6c5['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x9fb6c5['left']-0x3<=this['_activeViewTarget']['x']&&_0x9fb6c5['right']+0x3>=this['_activeViewTarget']['x'])||_0x41e0d9[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x144578,_0x14e9e9,_0x569872,_0x2584d6)=>{this['activeView']=_0x569872?this['_getViewForChange'](_0x569872):null,this['editor']['model']['change'](()=>{const _0x1bddc4=this['editor']['editing'];_0x2584d6&&(_0x2584d6['data']['isOnRoot']?_0x1bddc4['view']['change'](_0x5317fe=>{_0x5317fe['removeClass']('ck-revision-history-root--active',_0x1bddc4['view']['document']['getRoot'](_0x2584d6['rootName']));}):_0x1bddc4['reconvertMarker']('revision:'+_0x2584d6['id'])),_0x569872&&(_0x569872['data']['isOnRoot']?_0x1bddc4['view']['change'](_0x1d8a21=>{_0x1d8a21['addClass']('ck-revision-history-root--active',_0x1bddc4['view']['document']['getRoot'](_0x569872['rootName']));}):_0x1bddc4['reconvertMarker']('revision:'+_0x569872['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x175009,_0x176c21)=>{if(this['activeChange'])return;const _0x3ec190=this['_findChangeIdFromDomTarget'](_0x176c21['target']),_0x49c4f2=this['_changeIdToChange']['get'](_0x3ec190);_0x49c4f2?(this['_activeViewTarget']={'x':_0x176c21['domEvent']['x'],'y':_0x176c21['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x49c4f2)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x155476,_0xa0877c)=>{const _0x5ca3a2=this['_findChangeIdFromDomTarget'](_0xa0877c['target']),_0x1c3d07=this['_changeIdToChange']['get'](_0x5ca3a2);_0x1c3d07?(this['_activeViewTarget']={'x':_0xa0877c['domEvent']['x'],'y':_0xa0877c['domEvent']['y']},_0x1c3d07===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x1c3d07):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x36bb97){do{const _0x4feec4=_0x36bb97['getAttribute']('data-change-id');if(_0x4feec4)return _0x4feec4;_0x36bb97=_0x36bb97['parent'];}while(_0x36bb97);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x360a1a=>{for(const _0x4fae7e of this['editor']['model']['markers'])_0x360a1a['removeMarker'](_0x4fae7e);});}}function Q(_0x30da57,_0x4a380e){return(_0x142df4,_0xbe9e86,_0x286768)=>{if(!_0x286768['consumable']['test'](_0xbe9e86['markerRange'],_0x142df4['name']))return;const _0x167789=_0xbe9e86['markerRange']['getWalker'](),_0x52975d=_0xbe9e86['markerRange']['start'],_0x290bd0=_0x30da57['model']['schema'];let _0x1bf7d9=null,_0x2f5a51=null,_0x372637=!0x1,_0x3bd32d=!0x1;for(const _0x19b24f of _0x167789){const _0x45e35e=_0x19b24f['item'];_0x372637=_0x372637||_0x290bd0['isContent'](_0x45e35e);const _0x58b7b2=_0x286768['mapper']['toViewElement'](_0x45e35e);if(_0x58b7b2&&_0x58b7b2['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x19b24f['type']&&(_0x290bd0['isBlock'](_0x45e35e)&&!_0x290bd0['isLimit'](_0x45e35e)&&(_0x45e35e['nextSibling']||_0x52975d['isAtEnd']?_0x1bf7d9&&_0x1bf7d9['parent']==_0x45e35e||(_0x1bf7d9=_0x45e35e,_0x1ef4ab(_0x19b24f['previousPosition']),_0x3bd32d=!0x0):_0x2f5a51=_0x2f5a51||_0x19b24f['previousPosition']));}function _0x1ef4ab(_0x23635f){const _0x1cbbe4=_0x286768['mapper']['toViewPosition'](_0x23635f),_0x430af8=_0x286768['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x4a380e});_0x286768['writer']['insert'](_0x1cbbe4,_0x430af8),_0x286768['mapper']['bindElementToMarker'](_0x430af8,_0xbe9e86['markerName']);}_0x372637||_0x3bd32d||!_0x2f5a51||_0x1ef4ab(_0x2f5a51);};}class nt extends _0x23ffae{constructor(_0x27cd62){super(_0x27cd62);const _0x4ce37e=_0x27cd62['plugins']['get'](l);this['affectsData']=!0x1,this['listenTo'](_0x4ce37e,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x4ce37e,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x5f399d=this['editor'],_0x5bf26f=_0x5f399d['plugins']['get'](l),_0x4ed91c=_0x5bf26f['isReady']?_0x5bf26f['diff']['newRevisionId']:null;_0x5f399d['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x4ed91c);}['refresh'](){const {isReady:_0x2504f6,isEnabled:_0x46ce1f,repository:_0xc34405,diff:_0x3b5137}=this['editor']['plugins']['get'](l),_0x5479fa=_0x3b5137&&_0xc34405['getLaterVisibleRevision'](_0x3b5137['newRevisionId']);this['isEnabled']=_0x2504f6&&_0x46ce1f&&Boolean(_0x5479fa);}}class rt extends _0x23ffae{['_step'];constructor(_0x30fea4,{direction:_0x1a9f51}){super(_0x30fea4);const _0x2d3e3b=_0x30fea4['plugins']['get'](l);this['affectsData']=!0x1,this['_step']='forward'===_0x1a9f51?0x1:-0x1,this['listenTo'](_0x2d3e3b,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x2d3e3b,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x2d3e3b,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x34318c=this['editor'],_0x5a350e=_0x34318c['plugins']['get'](l),{isNavigationMode:_0x919155,currentChangeNumber:_0x75b485}=_0x5a350e;let _0x5a54b2;if(_0x5a350e['activeChange']=_0x919155?_0x5a350e['diff']['changes']['get'](_0x75b485+this['_step']):_0x5a350e['diff']['changes']['first'],_0x5a350e['activeChange']['data']['isOnRoot'])_0x5a54b2=_0x34318c['editing']['view']['getDomRoot'](_0x5a350e['activeChange']['rootName']);else{const _0x48cc30=_0x34318c['model']['markers']['get']('revision:'+_0x5a350e['activeChange']['id']);_0x5a54b2=_0x2c7553(_0x34318c['editing'],_0x48cc30);}_0x2169a9({'target':_0x5a54b2,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x2438e3,currentChangeNumber:_0x51ae84,numberOfChanges:_0x2f5d15,isReady:_0x3010ff,isEnabled:_0x6bb69b}=this['editor']['plugins']['get'](l);this['isEnabled']=!!(_0x6bb69b&&_0x3010ff&&_0x2f5d15)&&(!_0x2438e3||(0x1===this['_step']?_0x51ae84<_0x2f5d15-0x1:_0x51ae84>0x0));}}class Ri extends _0x54ee3c{constructor(_0x2487b0){super(_0x2487b0);const _0x5399eb=this['bindTemplate'],_0x506ea1=new _0x29e09a(_0x2487b0),_0x1afee7=new _0x29e09a(_0x2487b0);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',(_0x148d86,_0x4a12c2)=>_0x148d86&&_0x4a12c2>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x3a2393,_0x4e62c0,_0x12f2d7,_0x319916)=>{if(!_0x3a2393)return R(_0x2487b0,'Loading...');if(!_0x12f2d7)return R(_0x2487b0,'No\x20changes');const _0x4cdeb7=R(_0x2487b0,'NUMBER_OF_CHANGES',_0x12f2d7);return _0x319916?R(_0x2487b0,'X_OF_Y_CHANGES',[_0x4e62c0+0x1,_0x12f2d7]):_0x4cdeb7;}),_0x506ea1['set']({'label':R(_0x2487b0,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x72b043}),_0x1afee7['set']({'label':R(_0x2487b0,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x365fad}),_0x506ea1['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x1afee7['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x506ea1['on']('execute',()=>this['fire']('execute','backward')),_0x1afee7['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',_0x5399eb['if']('_isStatusLabelVisible','ck-hidden',_0x46661a=>!_0x46661a)]},'children':[{'text':_0x5399eb['to']('isNavigationMode',_0x2e6ff8=>_0x2e6ff8?R(_0x2487b0,'EDIT_X_OF_Y_REVISIONS')+':\x20':R(_0x2487b0,'Total')+':\x20')}]},{'text':_0x5399eb['to']('_statusText')}]},new _0x27cc40(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x506ea1,_0x1afee7]}]});}}const ge='ck-editor__editable__loading-overlay';class ji extends _0x449360{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x4f6905=this['editor']['editing']['view'];_0x4f6905['change'](_0x57a0fd=>{for(const _0x377d89 of _0x4f6905['document']['roots'])_0x57a0fd['addClass'](ge,_0x377d89);});}['hide'](){const _0x3de517=this['editor']['editing']['view'];_0x3de517['change'](_0x27ca1e=>{for(const _0xa18b8d of _0x3de517['document']['roots'])_0x27ca1e['removeClass'](ge,_0xa18b8d);});}}class u extends _0x449360{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l,ji];}['init'](){const _0x8a8841=this['editor'],_0xc90d26=_0x8a8841['plugins']['get'](l),_0x1e1e0f=_0x8a8841['plugins']['get'](ji);_0x8a8841['ui']['componentFactory']['add']('exitToEditing',_0x276a3c=>{const _0x52720c=new _0x29e09a(_0x276a3c);return _0x52720c['set']({'label':R(_0x276a3c,'Back\x20to\x20editing'),'icon':_0x46ae4d,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x52720c,'execute',()=>{_0x8a8841['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x52720c;}),_0x8a8841['ui']['componentFactory']['add']('restoreRevision',_0x17bf6f=>{const _0x236abe=new _0x29e09a(_0x17bf6f);return _0x236abe['set']({'label':R(_0x17bf6f,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x236abe['bind']('isEnabled')['to'](_0x8a8841['commands']['get']('restoreRevision')),this['listenTo'](_0x236abe,'execute',()=>_0x8a8841['execute']('restoreRevision')),_0x236abe;}),_0x8a8841['ui']['componentFactory']['add']('changesNavigation',_0xb40644=>{const _0x1ede69=new Ri(_0xb40644),_0x1ebf7f=_0x8a8841['commands']['get']('showPreviousChange'),_0x28767d=_0x8a8841['commands']['get']('showNextChange');return _0x1ede69['bind']('isBackwardNavigationEnabled')['to'](_0x1ebf7f,'isEnabled'),_0x1ede69['bind']('isForwardNavigationEnabled')['to'](_0x28767d,'isEnabled'),_0x1ede69['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0xc90d26),this['listenTo'](_0x1ede69,'execute',(_0xe4f343,_0x2d11f1)=>{_0x8a8841['execute']('forward'===_0x2d11f1?'showNextChange':'showPreviousChange');}),_0x1ede69;}),_0x1e1e0f['show'](),_0xc90d26['on']('change:isReady',(_0x3a3b3f,_0x490008,_0x57a57a)=>{_0x57a57a?_0x1e1e0f['hide']():_0x1e1e0f['show']();});}}class hi extends et{['_resizeObserver']=null;constructor(_0x58cf5f,_0x32d047){super(_0x58cf5f,_0x32d047);const _0x3811a3=this['bindTemplate'];this['set']({'label':R(_0x58cf5f,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=R(_0x58cf5f,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x3811a3['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 _0x2b3d3a=this['fieldView']['element'];this['_tooltipString']=_0x2b3d3a['scrollWidth']>_0x2b3d3a['clientWidth']&&_0x2b3d3a['value']||'';}}class ni extends _0x54ee3c{constructor(_0x52d7f4,_0x303c7f,_0x53f811){super(_0x52d7f4);const _0x85491d=new _0x5f31d5();_0x85491d['set']({'content':_0x4ca76a,'viewBox':'0\x200\x2011\x2010'});const _0x5262ce=['ck','ck-revision-history-sidebar__revision-author'];_0x53f811&&_0x5262ce['push']('ck-revision-history-sidebar__revision-author_creator');const _0x2fd227=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':R(_0x52d7f4,_0x53f811?'Revision\x20creator':'Revision\x20author')},'children':[_0x85491d,_0x303c7f['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x5262ce},'children':_0x2fd227});}}function ci(_0x254a8a,_0x2f5c85){const _0x44706d=_0x254a8a['bindTemplate'],_0x7e00c5=_0x254a8a['locale'],_0x7189ca=_0x3b7ce8(_0x7e00c5);_0x7189ca['panelPosition']='sw';const _0x2899ce=function(_0x2102b8,_0x1fa198){const _0x54bc0c=function(_0x2ddc43,_0x360beb){const _0x5d6dd6=_0x2ddc43['locale'],_0x35c23f={'Compare\x20against\x20selected':R(_0x5d6dd6,'Compare\x20against\x20selected'),'Name\x20this\x20revision':R(_0x5d6dd6,'Name\x20this\x20revision'),'Restore\x20this\x20revision':R(_0x5d6dd6,'Restore\x20this\x20revision')};return _0x360beb['map'](_0x3f3897=>{const _0x150fc9=_0x35c23f[_0x3f3897['name']];return _0x150fc9&&_0x150fc9!==_0x3f3897['name']&&(_0x3f3897['name']=_0x150fc9),_0x3f3897;});}(_0x2102b8,_0x1fa198),_0x10ce91=new _0x59f5e7();for(const _0x388d3c of _0x54bc0c){const _0x533e8e={'type':'button','model':new to({'label':_0x388d3c['name'],'class':_0x388d3c['class'],'withText':!0x0,'role':'menuitem','_action':_0x388d3c['action']})};_0x533e8e['model']['bind']('isEnabled')['to'](_0x2102b8,'isActionsDropdownOpen',_0x5a3daf=>'function'!=typeof _0x388d3c['isEnabled']||(!_0x5a3daf||_0x388d3c['isEnabled'](_0x2102b8))),_0x10ce91['add'](_0x533e8e);}return _0x10ce91;}(_0x254a8a,_0x2f5c85);return _0x254a8a['bind']('isActionsDropdownOpen')['to'](_0x7189ca,'isOpen'),_0x7189ca['buttonView']['set']({'label':R(_0x7e00c5,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x58a09d}),_0x7189ca['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x44706d['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x44706d['to'](_0x2311bf=>_0x2311bf['stopPropagation']())}}),_0x7189ca['on']('execute',_0x1a0b8a=>{_0x254a8a['isReady']&&'function'==typeof _0x1a0b8a['source']['_action']&&_0x1a0b8a['source']['_action'](_0x254a8a);}),_0x928c1c(_0x7189ca,_0x2899ce,{'role':'menu'}),_0x7189ca['listenTo'](_0x254a8a,'change:isActionsDropdownOpen',(_0x1e64b4,_0x32e7a8,_0x2da77b)=>{if(_0x2da77b)for(const _0x5f1480 of _0x7189ca['listView']['items']){const _0x4df534=_0x5f1480['children']['first'],_0x2c56d0=_0x2f5c85['find'](_0xba20c4=>_0xba20c4['action']===_0x4df534['_action'])['isVisible'];_0x5f1480['isVisible']=void 0x0===_0x2c56d0||_0x2c56d0(_0x254a8a);}}),_0x7189ca;}class _i extends/* #__PURE__ -- @preserve */
27
- _0x273059(_0x54ee3c){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x438edc,_0x24807e,_0x4976f6,_0x33a49d){super(_0x438edc);const _0x50460f=this['bindTemplate'],_0x4fd322=function(_0x24ec30,_0x396e52){const _0x812806=Array['from'](_0x396e52['authors'])['filter'](_0x4e02ee=>_0x4e02ee!=_0x396e52['creator']);return _0x396e52['creator']&&_0x812806['unshift'](_0x396e52['creator']),_0x812806['map'](_0x4a79be=>new ni(_0x24ec30,_0x4a79be,_0x4a79be==_0x396e52['creator']));}(_0x438edc,_0x24807e);this['id']=_0x24807e['id'],this['_revision']=_0x24807e,this['_requireRevisionName']=_0x33a49d,this['bind']('name','createdAt')['to'](_0x24807e),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x134bd6=>{return _0x59af03=_0x438edc['uiLanguage'],(_0x3a97d6=_0x134bd6)['toLocaleDateString'](_0x59af03,{'month':'long','day':'numeric'})+',\x20'+_0x3a97d6['toLocaleTimeString'](_0x59af03,{'hour':'numeric','minute':'numeric'});var _0x59af03,_0x3a97d6;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new hi(_0x438edc,ti),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x44de35=>_0x44de35||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x6b54e3,_0x9f8787)=>_0x6b54e3&&_0x9f8787),this['revisionActionsView']=_0x4976f6&&_0x4976f6['length']?ci(this,_0x4976f6):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x50460f['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x50460f['if']('isEnabled','ck-disabled',_0x4f1ba1=>!_0x4f1ba1),_0x50460f['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x50460f['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x50460f['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':_0x50460f['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':_0x4fd322}]},this['revisionActionsView']],'on':{'click':_0x50460f['to'](_0xd55e8=>{_0xd55e8['srcElement']['closest']('.ck-thread__remove-confirm')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x451b10=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x451b10,'change',()=>{this['_requireRevisionName']&&!_0x451b10['value']||this['fire']('setName',{'id':this['id'],'name':_0x451b10['value']}),_0x451b10['value']||(_0x451b10['value']=this['name']?this['name']:this['_createdAtFormatted']);});}['select'](){this['isSelected']=!0x0;}['deselect'](){this['isSelected']=!0x1;}['highlight'](){this['isHighlighted']=!0x0;}['unhighlight'](){this['isHighlighted']=!0x1;}}function li(_0x1a9605,_0x5577ce){const _0x457152=_0x53eb6e['fromJSDate'](_0x1a9605)['setLocale'](_0x5577ce),_0x55960e=_0x53eb6e['local'](),_0x22a895=_0x55960e['minus']({'days':0x1})['startOf']('day');let _0x4ab4d8,_0x18f9fd;return _0x457152['hasSame'](_0x55960e,'day')?(_0x4ab4d8=_0x457152['startOf']('day')['toJSDate'](),_0x18f9fd=_0x457152['toRelativeCalendar']()):_0x457152['hasSame'](_0x22a895,'day')?(_0x4ab4d8=_0x22a895['toJSDate'](),_0x18f9fd=_0x457152['toRelativeCalendar']()):_0x457152['hasSame'](_0x55960e,'week')?(_0x4ab4d8=_0x457152['startOf']('week')['toJSDate'](),_0x18f9fd=_0x457152['weekdayLong']||''):_0x457152['hasSame'](_0x55960e,'year')?(_0x4ab4d8=_0x457152['startOf']('month')['toJSDate'](),_0x18f9fd=_0x457152['monthLong']||''):(_0x4ab4d8=_0x457152['startOf']('year')['toJSDate'](),_0x18f9fd=String(_0x457152['year'])),{'startDate':_0x4ab4d8,'localizedPeriodName':_0x18f9fd};}class bi extends _0x54ee3c{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x17e3a8,_0x14e9f6,_0x522b3e,_0x199536){super(_0x17e3a8);const _0x256f58=li(_0x14e9f6,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x14e9f6,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x522b3e,this['_requireRevisionName']=_0x199536,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':_0x256f58}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x52e99a){const _0x44602d=new _i(this['locale'],_0x52e99a,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x44602d);}['removeRevision'](_0x2954f1){const _0xe1850=this['revisionViews']['find'](_0x47e4fd=>_0x47e4fd['id']===_0x2954f1['id']);this['revisionViews']['remove'](_0xe1850);}}class fi extends _0x54ee3c{constructor(_0x2c36fe){super(_0x2c36fe);const _0x222ee4=new _0x5f31d5();_0x222ee4['content']=_0x507409,this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x222ee4,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[R(_0x2c36fe,'Revision\x20history')]}]});}}class di extends _0x54ee3c{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x86dd72,_0x262a9c,_0x2467e4,_0x2fe7c9){super(_0x86dd72);const _0x90e6b3=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x262a9c,this['_revisionActions']=_0x2467e4,this['_requireRevisionName']=_0x2fe7c9,this['on']('select',(_0x356a83,_0x3dfb50)=>{this['fire']('revisionSelected',_0x3dfb50);}),this['on']('setName',(_0x303b1a,_0x22c020)=>{this['fire']('revisionSetName',_0x22c020);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new fi(_0x86dd72),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x90e6b3['if']('isEnabled','ck-disabled',_0x1fe7bc=>!_0x1fe7bc)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x55f17d of this['_revisions'])this['_addRevision'](_0x55f17d);this['_revisions']['on']('add',(_0x162739,_0x1a4574)=>{this['_addRevision'](_0x1a4574);}),this['_revisions']['on']('remove',(_0x4f2aff,_0x412b5a)=>{this['_removeRevision'](_0x412b5a);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x1e4654=>_0x1e4654['revisionViews']['map'](_0xadf4bc=>_0xadf4bc))['flat']();}['selectRevision'](_0x5606cb){for(const _0x598cc4 of this['revisionViews'])_0x5606cb&&_0x5606cb['id']===_0x598cc4['id']?_0x598cc4['select']():_0x598cc4['deselect']();}['highlightRevisions'](_0x43b005){for(const _0x522c57 of this['revisionViews'])_0x43b005['some'](({id:_0x595025})=>_0x595025===_0x522c57['id'])?_0x522c57['highlight']():_0x522c57['unhighlight']();}['_addRevision'](_0x374467){const _0x302b15=li(_0x374467['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x3d0565=this['timePeriodViews']['get'](0x0);_0x3d0565&&_0x3d0565['startDate']['getTime']()===_0x302b15['getTime']()||(_0x3d0565=new bi(this['locale'],_0x302b15,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x3d0565)),_0x3d0565['addRevision'](_0x374467);}['_removeRevision'](_0x4a03a8){const _0x35abf7=li(_0x4a03a8['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x35abf7)['removeRevision'](_0x4a03a8);}['_getTimePeriodViewByStartDate'](_0x1efaa9){return this['timePeriodViews']['find'](_0x5c3556=>_0x5c3556['startDate']['getTime']()===_0x1efaa9['getTime']());}}class f extends _0x449360{['_revisionViewer'];['_revisionsRepository'];['_sidebarView'];static ['defaultRevisionActions']=/* #__PURE__ -- @preserve */
23
+ import{ObservableMixin as _0x5d4f77,uid as _0x5bd0bf,Collection as _0x50c032,logWarning as _0x1e7653,FocusTracker as _0x59744e,KeystrokeHandler as _0x52a663,scrollViewportToShowTarget as _0x1ccc11,ResizeObserver as et,ElementReplacer as it,CKEditorError as _0x31ce40}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x11d795,set as _0x303496,unset as _0x24ab7a,isEqual as _0x43b1a0}from'es-toolkit/compat';import{Plugin as _0x557a5e,PendingActions as _0x3e42dc,Command as _0x58b01,ElementApiMixin as _0x514d34,Editor as _0x2522a6}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x2bd141,getMarkerDomElement as _0x11cd7f,ConfirmMixin as _0x1f6116,sanitizeEditorConfig as _0x3162bb}from'ckeditor5-collaboration/dist/index.js';import{ViewContainerElement as _0x52b12d,ViewAttributeElement as _0x39091d,ViewEmptyElement as _0xebc74f,ViewRawElement as _0x1154bd,ViewUIElement as _0x59e506,ViewDocumentFragment as _0xed7494,ViewText as _0x10d0d7,ViewElement as _0x393af7,ModelElement as _0x599036,ModelRange as _0x573a12,ModelPosition as _0x1d67e9,ModelDocumentFragment as _0x4c0b22,ModelText as _0x58fa86}from'@ckeditor/ckeditor5-engine/dist/index.js';import{IconHistory as _0x205745,IconChevronUp as _0xe92cb0,IconChevronDown as _0x57ae56,IconUndo as _0x3a38c,IconUser as _0x1309a4,IconThreeVerticalDots as _0x46a20b}from'@ckeditor/ckeditor5-icons/dist/index.js';import{CssTransitionDisablerMixin as _0x250264,View as _0x289a06,submitHandler as _0x324c76,LabeledFieldView as ti,createLabeledInputText as _0x104191,createDropdown as _0x10ddda,ListView as _0x1a06ac,ListItemView as _0x45ee3c,ButtonView as _0x42cd9a,MenuBarMenuView as _0x2fbdef,MenuBarMenuListView as _0x55a029,MenuBarMenuListItemView as _0x1da77a,MenuBarMenuListItemButtonView as _0x1eb01a,ContextualBalloon as _0x207472,ToolbarSeparatorView as _0x1c6dd3,IconView as _0x26bf56,addListToDropdown as _0x160d68,UIModel as to,EditorUI as tt,normalizeToolbarConfig as st,BoxedEditorUIView as _0x24ef8d,StickyPanelView as _0x6ddc23,ToolbarView as _0xad3739,InlineEditableUIView as te}from'@ckeditor/ckeditor5-ui/dist/index.js';import{DateTime as _0x2b72ee}from'luxon';class I extends/* #__PURE__ -- @preserve */
24
+ _0x5d4f77(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x24304b){super(),this['id']=_0x24304b['id']||_0x5bd0bf(),this['creator']=_0x24304b['creator']||null,this['authors']=_0x24304b['authors']||[],this['diffData']=_0x24304b['diffData']||null,this['toVersion']=_0x24304b['toVersion']||0x0,this['fromVersion']=_0x24304b['fromVersion']||0x0,this['set']('name',_0x24304b['name']||''),this['set']('createdAt',_0x24304b['createdAt']||new Date()),this['set']('attributes',_0x24304b['attributes']||{});}['setName'](_0x15b527){this['_update']({'name':_0x15b527});}['setAttribute'](_0x34d176,_0x3ceb09){const _0x29edf3=_0x11d795(this['attributes']);_0x303496(_0x29edf3,_0x34d176,_0x3ceb09),this['_update']({'attributes':_0x29edf3});}['removeAttribute'](_0x364e1e){const _0x57a0ca=_0x11d795(this['attributes']);_0x24ab7a(_0x57a0ca,_0x364e1e),this['_update']({'attributes':_0x57a0ca});}['_update'](_0x579bb7,_0x37b28b=!0x1){let _0x290640=!0x1;const _0x358adc={'id':this['id']},_0x210739=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x4f44b6 of _0x210739){const _0x7b9763=_0x579bb7[_0x4f44b6];void 0x0!==_0x7b9763&&_0x7b9763!==this[_0x4f44b6]&&(this[_0x4f44b6]=_0x7b9763,_0x358adc[_0x4f44b6]=_0x7b9763,_0x290640=!0x0);}_0x290640&&(_0x358adc['authors']&&(_0x358adc['authorsIds']=_0x358adc['authors']['map'](_0x469fa9=>_0x469fa9['id']),delete _0x358adc['authors']),this['fire']('_update',_0x358adc,_0x37b28b));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x4a4551=>_0x4a4551['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class S extends _0x557a5e{['_revisions'];static get['requires'](){return[_0x2bd141];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x25d88c){super(_0x25d88c),this['_revisions']=new _0x50c032();}['afterInit'](){!async function(_0x35eb9b){const _0x458497=_0x438540([0x53,0x63,0x69,0x66,0x4f,0x5a,0x54,0x31,0x4a,0x59,0x37,0x79,0x72,0x73,0x61,0x4c,0x47,0x4b,0x56,0x58,0x52,0x43,0x41,0x6f,0x64,0x77,0x7a,0x36,0x70,0x71,0x49,0x75,0x4e,0x46,0x48,0x55,0x65,0x34,0x38,0x62,0x68,0x6c,0x33,0x6e,0x4d,0x78,0x67,0x39,0x30,0x42,0x32,0x76,0x74,0x35,0x6b,0x6a,0x51,0x50,0x44,0x6d,0x45,0x57]),_0x3a1758=0xeb829,_0x25a956=0x71a6d713,_0x11713f=0x71a1a543^_0x25a956,_0x4ea1df=window[_0x438540([0x44,0x61,0x74,0x65])][_0x438540([0x6e,0x6f,0x77])](),_0x21dce9=_0x35eb9b[_0x438540([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x5279b5=new window[(_0x438540([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x388ad0=>{_0x21dce9[_0x438540([0x6f,0x6e,0x63,0x65])](_0x438540([0x72,0x65,0x61,0x64,0x79]),_0x388ad0);}),_0x327eab={[_0x438540([0x6b,0x74,0x79])]:_0x438540([0x45,0x43]),[_0x438540([0x75,0x73,0x65])]:_0x438540([0x73,0x69,0x67]),[_0x438540([0x63,0x72,0x76])]:_0x438540([0x50,0x2d,0x32,0x35,0x36]),[_0x438540([0x78])]:_0x438540([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]),[_0x438540([0x79])]:_0x438540([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]),[_0x438540([0x61,0x6c,0x67])]:_0x438540([0x45,0x53,0x32,0x35,0x36])},_0x17a778=_0x21dce9[_0x438540([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x438540([0x67,0x65,0x74])](_0x438540([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x4fcb7b(){let _0x5308c7,_0x4e244c=null,_0x4b65a3=null;try{if(_0x17a778==_0x438540([0x47,0x50,0x4c]))return _0x438540([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x5308c7=_0x40c149(),!_0x5308c7)return _0x438540([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x5308c7[_0x438540([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x4b65a3=_0xd6335a(_0x5308c7[_0x438540([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x5308c7[_0x438540([0x6a,0x74,0x69])])),await _0x31ffae()?_0x5d03a3()?_0x2609ae()?_0x438540([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x5a301d()?(_0x5308c7[_0x438540([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x438540([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x4e244c=_0x1464b6(_0x438540([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x5308c7[_0x438540([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x438540([0x74,0x72,0x69,0x61,0x6c])&&(_0x4e244c=_0x1464b6(_0x438540([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x417980()):_0x438540([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x438540([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x438540([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x438540([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x2609ae(){const _0x2e3f89=[_0x438540([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x438540([0x74,0x72,0x69,0x61,0x6c])][_0x438540([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x5308c7[_0x438540([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x4ea1df/0x3e8:0xe10*_0x11713f;return _0x5308c7[_0x438540([0x65,0x78,0x70])]<_0x2e3f89;}function _0x5d03a3(){const _0x151d51=_0x5308c7[_0x438540([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x151d51)return!0x1;if(_0x151d51[_0x438540([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x438540([0x2a])))return!0x0;if(_0x151d51[_0x438540([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x438540([0x52,0x48])))return!0x0;if(_0x151d51[_0x438540([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x438540([0x52,0x52,0x48]))){if(_0x32f5a8())return!0x0;if(_0x243c0c()||_0x254fbf())return!0x0;}return!0x1;}function _0x5a301d(){const _0x3c03f4=_0x5308c7[_0x438540([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x3c03f4||0x0==_0x3c03f4[_0x438540([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x1f42bf}=new URL(window[_0x438540([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x3c03f4[_0x438540([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x1f42bf))return!0x0;const _0x532ec0=_0x1f42bf[_0x438540([0x73,0x70,0x6c,0x69,0x74])](_0x438540([0x2e]));return _0x3c03f4[_0x438540([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x253eae=>_0x253eae[_0x438540([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x438540([0x2a])))[_0x438540([0x6d,0x61,0x70])](_0x1214ce=>_0x1214ce[_0x438540([0x73,0x70,0x6c,0x69,0x74])](_0x438540([0x2e])))[_0x438540([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x1d6dc7=>_0x1d6dc7[_0x438540([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x532ec0[_0x438540([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x438540([0x6d,0x61,0x70])](_0x219e50=>Array(_0x532ec0[_0x438540([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0x219e50[_0x438540([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x438540([0x66,0x69,0x6c,0x6c])](_0x219e50[0x0]===_0x438540([0x2a])?_0x438540([0x2a]):'')[_0x438540([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0x219e50))[_0x438540([0x73,0x6f,0x6d,0x65])](_0x3880f9=>_0x532ec0[_0x438540([0x65,0x76,0x65,0x72,0x79])]((_0x3e6b6c,_0x235809)=>_0x3880f9[_0x235809]===_0x3e6b6c||_0x3880f9[_0x235809]===_0x438540([0x2a])));}function _0x417980(){return _0x4e244c&&_0x4b65a3?new window[(_0x438540([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x4d36b7,_0x5b712a)=>{_0x4e244c[_0x438540([0x74,0x68,0x65,0x6e])](_0x4d36b7,_0x5b712a),_0x4b65a3[_0x438540([0x74,0x68,0x65,0x6e])](_0x142cb5=>{_0x142cb5!=_0x438540([0x56,0x61,0x6c,0x69,0x64])&&_0x4d36b7(_0x142cb5);},_0x5b712a);}):_0x4e244c||_0x4b65a3||_0x438540([0x56,0x61,0x6c,0x69,0x64]);}}function _0xd6335a(_0x36a5ca,_0xbe789d){return new window[(_0x438540([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x1d8c25=>{if(_0x370a1d())return _0x1d8c25(_0x438540([0x56,0x61,0x6c,0x69,0x64]));_0x38f450(),_0x21dce9[_0x438540([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x438540([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x2c99dd=!0x1;const _0x194eaa=_0x5bd0bf();function _0x167776(_0x3560b6){return!!_0x3560b6&&(typeof _0x3560b6===_0x438540([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x3560b6===_0x438540([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x3560b6[_0x438540([0x74,0x68,0x65,0x6e])]===_0x438540([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x3560b6[_0x438540([0x63,0x61,0x74,0x63,0x68])]===_0x438540([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x53f09d(_0x147661){_0x3d5540(_0x147661)[_0x438540([0x74,0x68,0x65,0x6e])](_0x2fd315=>{if(!_0x2fd315||_0x2fd315[_0x438540([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x438540([0x6f,0x6b]))return _0x438540([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x5744c9(_0x1667c3(_0x194eaa+_0xbe789d))!=_0x2fd315[_0x438540([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x438540([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x438540([0x56,0x61,0x6c,0x69,0x64]);})[_0x438540([0x74,0x68,0x65,0x6e])](_0x3db8c2=>(_0x403adc(),_0x3db8c2),()=>{const _0x5d850e=_0x289e72();return null==_0x5d850e?(_0x403adc(),_0x438540([0x56,0x61,0x6c,0x69,0x64])):_0x438540(_0x4ea1df-_0x5d850e>(0x55aa5313^_0x25a956)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x438540([0x74,0x68,0x65,0x6e])](_0x1d8c25)[_0x438540([0x63,0x61,0x74,0x63,0x68])](()=>{_0x1d8c25(_0x438540([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x1fc6c3=0x71903993^_0x25a956;function _0x403adc(){const _0x44c964=_0x438540([0x6c,0x6c,0x63,0x74,0x2d])+_0x5744c9(_0x1667c3(_0x36a5ca)),_0x54ba96=_0x1df94d(_0x5744c9(window[_0x438540([0x4d,0x61,0x74,0x68])][_0x438540([0x63,0x65,0x69,0x6c])](_0x4ea1df/_0x1fc6c3)));window[_0x438540([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x438540([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x44c964,_0x54ba96);}function _0x289e72(){const _0x37d5a=_0x438540([0x6c,0x6c,0x63,0x74,0x2d])+_0x5744c9(_0x1667c3(_0x36a5ca)),_0x64f993=window[_0x438540([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x438540([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x37d5a);return _0x64f993?window[_0x438540([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x1df94d(_0x64f993),0x10)*_0x1fc6c3:null;}function _0x3d5540(_0x1e2af5){return new window[(_0x438540([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x594b79,_0x3c9d35)=>{_0x1e2af5[_0x438540([0x74,0x68,0x65,0x6e])](_0x594b79,_0x3c9d35),window[_0x438540([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x3c9d35,0x71a703d3^_0x25a956);});}}_0x21dce9[_0x438540([0x6f,0x6e])](_0x438540([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x14409c,_0xdb5870)=>{if(_0xdb5870[0x0]!=_0x36a5ca)return _0x1d8c25(_0x438540([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0xdb5870[0x1]={..._0xdb5870[0x1],[_0x438540([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x194eaa};},{[_0x438540([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x438540([0x68,0x69,0x67,0x68])}),_0x21dce9[_0x438540([0x6f,0x6e])](_0x438540([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x18d7d2=>{_0x167776(_0x18d7d2[_0x438540([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x2c99dd=!0x0,_0x53f09d(_0x18d7d2[_0x438540([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x438540([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x438540([0x6c,0x6f,0x77])}),_0x5279b5[_0x438540([0x74,0x68,0x65,0x6e])](()=>{_0x2c99dd||_0x1d8c25(_0x438540([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x370a1d(){return _0x21dce9[_0x438540([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x438540([0x76,0x69,0x65,0x77])][_0x438540([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x438540([0x61,0x75,0x74,0x6f]);}function _0x38f450(){_0x21dce9[_0x438540([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x438540([0x76,0x69,0x65,0x77])][_0x438540([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x438540([0x61,0x75,0x74,0x6f]);}}function _0x1464b6(_0x1d62f3){const _0x442c3e=[new window[(_0x438540([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x5542a5=>setTimeout(_0x5542a5,0x71afe9df^_0x25a956)),_0x5279b5[_0x438540([0x74,0x68,0x65,0x6e])](()=>new window[(_0x438540([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x4f4ce8=>{const _0x30d59b=0x71a6d714^_0x25a956,_0xf96906=_0x35eb9b[_0x438540([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x5f5b5f(){_0xf96906[_0x438540([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x30d59b&&_0x4f4ce8();}_0x5f5b5f(),_0xf96906[_0x438540([0x6f,0x6e])](_0x438540([0x61,0x64,0x64]),_0x5f5b5f);})),new window[(_0x438540([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x4ffbb8=>{function _0x5c64d7(){for(const _0x9a2468 in window)if(window[_0x438540([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x438540([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x9a2468))&&window[_0x9a2468]==_0x3a1758)return _0x4ffbb8();_0x21dce9[_0x438540([0x73,0x74,0x61,0x74,0x65])]!=_0x438540([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x438540([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x5c64d7,0x71a6c49b^_0x25a956);}_0x5cfb78(_0x438540([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x5c64d7();})];return window[_0x438540([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x438540([0x72,0x61,0x63,0x65])](_0x442c3e)[_0x438540([0x74,0x68,0x65,0x6e])](()=>_0x1d62f3);}async function _0x4fbd6a(){if(await _0x5279b5,_0x5cfb78(_0x438540([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x5a48af=_0x35eb9b[_0x438540([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x2776df=_0x35eb9b[_0x438540([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])](_0x5a48af[_0x438540([0x69,0x64])]),_0x35daf7=_0x1cf826(_0x438540([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x35daf7[_0x438540([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x5a48af['id'],_0x2776df?_0x2776df['id']:null,!0x0),_0x35daf7[_0x438540([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x438540([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x35daf7[_0x438540([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x35daf7[_0x438540([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x3bacca,void(_0x35daf7[_0x438540([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x3bacca);}if(_0x5cfb78(_0x438540([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x426860=_0x1cf826(_0x438540([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x426860[_0x438540([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x438540([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x426860[_0x438540([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x426860[_0x438540([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x3bacca,_0x426860[_0x438540([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x3bacca;}_0x21dce9[_0x438540([0x6d,0x6f,0x64,0x65,0x6c])][_0x438540([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x3bacca,_0x21dce9[_0x438540([0x6d,0x6f,0x64,0x65,0x6c])][_0x438540([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x3bacca,_0x21dce9[_0x438540([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x438540([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x32f5a8(){return _0x5cfb78(_0x438540([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x1cf826(_0x438540([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x438540([0x73,0x74,0x61,0x74,0x65])]==_0x438540([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x243c0c(){return _0x5cfb78(_0x438540([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 _0x254fbf(){return _0x5cfb78(_0x438540([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x395acb(_0x2b0c5a){const _0x56fe56=_0x165652();_0x21dce9[_0x56fe56]=_0x438540([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])+_0x2b0c5a,_0x2b0c5a[_0x438540([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x438540([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x165652()]=_0x3a1758),_0x2b0c5a!=_0x438540([0x56,0x61,0x6c,0x69,0x64])&&_0x4fbd6a();}function _0x165652(){const _0x1cb7c8=window[_0x438540([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x438540([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x438540([0x6e,0x6f,0x77])]())[_0x438540([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x438540([0x2e]),'');let _0x4816b1=_0x438540([0x53]);for(let _0x516133=0x0;_0x516133<_0x1cb7c8[_0x438540([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x516133+=0x2){let _0x17faba=window[_0x438540([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x1cb7c8[_0x438540([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x516133,_0x516133+0x2));_0x17faba>=_0x458497[_0x438540([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x17faba-=_0x458497[_0x438540([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x4816b1+=_0x458497[_0x17faba];}return _0x4816b1;}function _0x40c149(){const _0x1dd7e6=_0x17a778[_0x438540([0x73,0x70,0x6c,0x69,0x74])](_0x438540([0x2e]));if(0x3!=_0x1dd7e6[_0x438540([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0xfe465d(_0x1dd7e6[0x1]);function _0xfe465d(_0x5cbb6e){const _0x272f48=_0x5d9591(_0x5cbb6e);return _0x272f48&&_0x2d55da()?_0x272f48:null;function _0x2d55da(){const _0x16ef84=_0x272f48[_0x438540([0x6a,0x74,0x69])],_0xa9d9e0=window[_0x438540([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x16ef84[_0x438540([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x16ef84[_0x438540([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x5defd0={..._0x272f48,[_0x438540([0x6a,0x74,0x69])]:_0x16ef84[_0x438540([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x16ef84[_0x438540([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x5defd0[_0x438540([0x76,0x63])],_0x1667c3(_0x5defd0)==_0xa9d9e0;}}}async function _0x31ffae(){let _0x2dd29c=!0x0;try{const _0x5f26a9=_0x17a778[_0x438540([0x73,0x70,0x6c,0x69,0x74])](_0x438540([0x2e])),[_0x1fc46e,_0x300341,_0x49fdec]=_0x5f26a9;return _0xf2420d(_0x1fc46e),await _0x4c8982(_0x1fc46e,_0x300341,_0x49fdec),_0x2dd29c;}catch{return!0x1;}function _0xf2420d(_0x59c646){const _0x33159e=_0x5d9591(_0x59c646);_0x33159e&&_0x33159e[_0x438540([0x61,0x6c,0x67])]==_0x438540([0x45,0x53,0x32,0x35,0x36])||(_0x2dd29c=!0x1);}async function _0x4c8982(_0x27f9a6,_0x345a24,_0x287ad5){const _0x33c835=window[_0x438540([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x438540([0x66,0x72,0x6f,0x6d])](_0x43a9c3(_0x287ad5),_0xe52638=>_0xe52638[_0x438540([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x1a54cc=new window[(_0x438540([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x438540([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x27f9a6+_0x438540([0x2e])+_0x345a24),_0x2e58c7=window[_0x438540([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x438540([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x2e58c7)return;const _0x378c07=await _0x2e58c7[_0x438540([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x438540([0x6a,0x77,0x6b]),_0x327eab,{[_0x438540([0x6e,0x61,0x6d,0x65])]:_0x438540([0x45,0x43,0x44,0x53,0x41]),[_0x438540([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x438540([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x438540([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x2e58c7[_0x438540([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x438540([0x6e,0x61,0x6d,0x65])]:_0x438540([0x45,0x43,0x44,0x53,0x41]),[_0x438540([0x68,0x61,0x73,0x68])]:{[_0x438540([0x6e,0x61,0x6d,0x65])]:_0x438540([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x378c07,_0x33c835,_0x1a54cc)||(_0x2dd29c=!0x1);}}function _0x5d9591(_0x2aaf57){return _0x2aaf57[_0x438540([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x438540([0x65,0x79]))?JSON[_0x438540([0x70,0x61,0x72,0x73,0x65])](_0x43a9c3(_0x2aaf57)):null;}function _0x43a9c3(_0x293029){return window[_0x438540([0x61,0x74,0x6f,0x62])](_0x293029[_0x438540([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x438540([0x2b]))[_0x438540([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x438540([0x2f])));}function _0x1667c3(_0x51a405){let _0x150e74=0x1505;function _0x50fb6a(_0x3966fd){for(let _0xaacea9=0x0;_0xaacea9<_0x3966fd[_0x438540([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0xaacea9++){const _0x5e3288=_0x3966fd[_0x438540([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0xaacea9);_0x150e74=(_0x150e74<<0x5)+_0x150e74+_0x5e3288,_0x150e74&=_0x150e74;}}function _0x2ccad3(_0x2a52b1){Array[_0x438540([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x2a52b1)?_0x2a52b1[_0x438540([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x2ccad3):_0x2a52b1&&typeof _0x2a52b1==_0x438540([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x438540([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x2a52b1)[_0x438540([0x73,0x6f,0x72,0x74])]()[_0x438540([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x5bdc17,_0x46a2e2])=>{_0x50fb6a(_0x5bdc17),_0x2ccad3(_0x46a2e2);}):_0x50fb6a(window[_0x438540([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x2a52b1));}return _0x2ccad3(_0x51a405),_0x150e74>>>0x0;}function _0x5744c9(_0xffd708){return _0xffd708[_0x438540([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x438540([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x438540([0x30]));}function _0x1df94d(_0x18c5ba){return _0x18c5ba[_0x438540([0x73,0x70,0x6c,0x69,0x74])]('')[_0x438540([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x438540([0x6a,0x6f,0x69,0x6e])]('');}function _0x5cfb78(_0x4751fc){return _0x21dce9[_0x438540([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x438540([0x68,0x61,0x73])](_0x4751fc);}function _0x1cf826(_0x2f7de4){return _0x21dce9[_0x438540([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x438540([0x67,0x65,0x74])](_0x2f7de4);}function _0x3bacca(){}function _0x438540(_0x3c47c1){return _0x3c47c1['map'](_0x5874df=>String['fromCharCode'](_0x5874df))['join']('');}_0x395acb(await _0x4fcb7b());}(this);}['createRevision'](_0x140b58){const _0x51cabf=this['editor']['plugins']['get']('Users');return new I({'id':_0x140b58['id'],'name':_0x140b58['name'],'creator':_0x140b58['creatorId']?_0x51cabf['getUser'](_0x140b58['creatorId']):null,'diffData':_0x140b58['diffData']||_0x140b58['data'],'authors':_0x140b58['authorsIds']['map'](_0x1d887f=>_0x51cabf['getUser'](_0x1d887f)),'createdAt':new Date(_0x140b58['createdAt']),'attributes':_0x140b58['attributes'],'fromVersion':_0x140b58['fromVersion'],'toVersion':_0x140b58['toVersion']});}['addRevision'](_0x22b9d8,_0x1d1fa4=0x0){this['_revisions']['add'](_0x22b9d8,_0x1d1fa4);}['getRevision'](_0x31f595){return this['_revisions']['get'](_0x31f595);}['getRevisions'](_0x2ffcb2={'toJSON':!0x1}){const _0x1658ed=Array['from'](this['_revisions']);return _0x1658ed['reverse'](),_0x2ffcb2['toJSON']?_0x1658ed['map'](_0x2febea=>_0x2febea['toJSON']()):_0x1658ed;}['getIndex'](_0x135956){return this['_revisions']['getIndex'](_0x135956);}['getEarlierVisibleRevision'](_0x1aac71){const [,_0x20cb9f]=this['getRevisionsIterator'](_0x1aac71,{'direction':'earlier'});return _0x20cb9f;}['getLaterVisibleRevision'](_0x4be50f){const [,_0x5cbfd1]=this['getRevisionsIterator'](_0x4be50f,{'direction':'later'});return _0x5cbfd1;}['getRevisionsInDiff'](_0x236b4c){const _0x240730=[];for(const _0x4b65f1 of this['getRevisionsIterator'](_0x236b4c['newRevisionId']))if(_0x240730['push'](_0x4b65f1),_0x4b65f1['id']===_0x236b4c['oldRevisionId'])break;return _0x240730;}*['getRevisionsIterator'](_0x257a61,{direction:_0x1ed3c2='earlier',filter:_0x5bbe52=()=>!0x0}={}){const _0x17f5aa='earlier'===_0x1ed3c2?0x1:-0x1;let _0x340062=this['_revisions']['get'](_0x257a61),_0x4b69eb=this['getIndex'](_0x340062);for(yield _0x340062;_0x340062;){if(_0x4b69eb+=_0x17f5aa,_0x340062=this['getRevision'](_0x4b69eb),!_0x340062)return;_0x5bbe52(_0x340062)&&(yield _0x340062);}}}class $ extends _0x557a5e{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x52b12d,'c'],[_0x39091d,'a'],[_0xebc74f,'e'],[_0x1154bd,'r'],[_0x59e506,'u']]);['_typeCharToViewClass']=new Map([['c',_0x52b12d],['a',_0x39091d],['e',_0xebc74f],['r',_0x1154bd],['u',_0x59e506]]);async['loadRevisionData'](_0x653fb5,_0xd8d945){if(_0x653fb5['diffData']||!_0xd8d945)return;const _0x19187e=this['editor']['config']['get']('collaboration.channelId'),_0x486d7d=await _0xd8d945['getRevision']({'channelId':_0x19187e,'revisionId':_0x653fb5['id']});_0x653fb5['diffData']=_0x486d7d['diffData'];}['getRevisionDocumentData'](_0x2c9339){const _0x314a44={};for(const _0x564660 in _0x2c9339['diffData']){if(_0x2c9339['diffData'][_0x564660]['attachChange']&&!_0x2c9339['diffData'][_0x564660]['attachChange']['isAttached'])continue;const _0x2f894a=this['_removeRevisionMarkers'](JSON['parse'](_0x2c9339['diffData'][_0x564660]['insertions'])),_0x496ffb=this['editor']['editing']['view']['document'],_0x4c878e=new _0xed7494(_0x496ffb,_0x2f894a['map'](_0x54d264=>this['_getViewFromDiffObj'](_0x54d264,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x314a44[_0x564660]=this['editor']['data']['processor']['toData'](_0x4c878e),this['editor']['data']['processor']['useFillerType']('default');}return _0x314a44;}['getRevisionRootsAttributes'](_0x1aa816){const _0x2b7d94={};for(const _0x11e1c4 in _0x1aa816['diffData'])_0x1aa816['diffData'][_0x11e1c4]['attachChange']&&!_0x1aa816['diffData'][_0x11e1c4]['attachChange']['isAttached']||(_0x2b7d94[_0x11e1c4]=_0x1aa816['diffData'][_0x11e1c4]['attributesAfter']||{});return _0x2b7d94;}['_getTypeCharForViewElement'](_0x2a7019){return this['_viewClassToTypeChar']['get'](_0x2a7019['constructor']);}['_getViewFromDiffObj'](_0x3cc65f,_0x2764f7){const _0x6cf6f8=this['editor']['editing']['view']['document'];if('string'==typeof _0x3cc65f)return new _0x10d0d7(_0x6cf6f8,_0x3cc65f);{let _0x342fc5,_0x4877c7;_0x4877c7='u'==_0x3cc65f['type']||'r'==_0x3cc65f['type']?[]:_0x3cc65f['children']['map'](_0xb946bb=>this['_getViewFromDiffObj'](_0xb946bb,_0x2764f7));const _0x3270f1=this['_typeCharToViewClass']['get'](_0x3cc65f['type'])||_0x393af7,_0x161a71=this['editor']['data']['htmlProcessor']['domConverter'];if(_0x342fc5=new _0x3270f1(_0x6cf6f8,_0x3cc65f['name'],_0x3cc65f['attributes'],_0x4877c7),'u'==_0x3cc65f['type']&&_0x3cc65f['children'][0x0]){const _0xf3eef9=_0x3cc65f['children'][0x0];if(_0x342fc5['render']=function(_0x4ff645){const _0xf38694=_0x4ff645['createElement']('div');return _0xf38694['innerHTML']=_0xf3eef9,_0xf38694['childNodes'][0x0];},_0x2764f7){const _0x4a8b00=new _0xed7494(_0x6cf6f8);_0x4a8b00['_appendChild'](_0x342fc5);const _0x66479b=Array['from'](_0x161a71['viewChildrenToDom'](_0x4a8b00,{'bind':!0x1})),_0x5614db=_0x161a71['domDocument']['createElement']('div');_0x5614db['append'](..._0x66479b),_0x342fc5=Array['from'](_0x161a71['domChildrenToView'](_0x5614db))[0x0];}}else{if('r'==_0x3cc65f['type']&&_0x3cc65f['children'][0x0]){const _0x403122=_0x3cc65f['children'][0x0];if(_0x342fc5['render']=function(_0x9c9145){_0x9c9145['innerHTML']=_0x403122;},_0x2764f7){const _0xe8f3e5=new _0xed7494(_0x6cf6f8);_0xe8f3e5['_appendChild'](_0x342fc5);const _0x3b5038=Array['from'](_0x161a71['viewChildrenToDom'](_0xe8f3e5,{'bind':!0x1})),_0x32a24a=_0x161a71['domDocument']['createElement']('div');_0x32a24a['append'](..._0x3b5038);const _0x17dd49=Array['from'](_0x161a71['domChildrenToView'](_0x32a24a));_0x17dd49['length']>0x1?_0x342fc5['_appendChild'](_0x17dd49):_0x342fc5=_0x17dd49[0x0];}}}if(_0x3cc65f['customProperties']){for(const [_0x5603e4,_0x1eafc3]of _0x3cc65f['customProperties'])_0x342fc5['_setCustomProperty'](_0x5603e4,_0x1eafc3);}const _0x574102=void 0x0===_0x3cc65f['fillerOffset']?null:_0x3cc65f['fillerOffset'];return null!==_0x574102&&(_0x342fc5['getFillerOffset']=()=>_0x574102),_0x342fc5;}}['_makeModelFromViewString'](_0xe6ef66){const _0x19962f=JSON['parse'](_0xe6ef66),_0x6073aa=this['editor']['editing']['view']['document'],_0xdb83dd=new _0xed7494(_0x6073aa,_0x19962f['map'](_0x222d5d=>this['_getViewFromDiffObj'](_0x222d5d,!0x0)));return this['editor']['data']['toModel'](_0xdb83dd);}['_removeRevisionMarkers'](_0x52e007){return(_0x52e007=_0x52e007['filter'](_0x5f472c=>!_0x5f472c['name']||'revision-start'!==_0x5f472c['name']&&'revision-end'!==_0x5f472c['name']))['forEach'](_0x834d61=>{'string'!=typeof _0x834d61&&(_0x834d61['children']=this['_removeRevisionMarkers'](_0x834d61['children']),_0x834d61['attributes']=_0x834d61['attributes']['filter'](_0x1d8328=>!_0x1d8328[0x0]['startsWith']('data-revision-')));}),_0x52e007;}}function R(_0x37587d,_0x282097,_0x5d059a){const t=_0x37587d['t'];switch(_0x282097){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'},_0x5d059a);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x5d059a);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 _0x557a5e{['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[_0x2bd141,S,$,_0x3e42dc];}constructor(_0x5c8341){super(_0x5c8341),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 _0x4393e8=_0x5bd0bf();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x4393e8},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 _0x3b68c2=this['repository']['getRevision'](0x0),_0x3d842b=_0x3b68c2&&null===_0x3b68c2['creator']?_0x3b68c2:null;if(this['_continueCurrentRevision']=!!_0x3d842b&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x1b2b8a=this['_source']['getCurrentRevisionId'](),_0x5946b8=this['repository']['getRevision'](_0x1b2b8a);if(_0x5946b8)this['_startingVersion']=_0x5946b8['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x4bcc08=this['_source']['history']['_operations']['find'](_0x1ad77d=>!_0x1ad77d['_isInit']),_0x542d56=_0x4bcc08?_0x4bcc08['baseVersion']:this['_source']['history']['version'];_0x3b68c2?(_0x3b68c2['toVersion']<_0x542d56&&_0x3b68c2['_update']({'toVersion':_0x542d56}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x3d842b['id'],this['_startingVersion']=_0x3d842b['fromVersion']):(this['_startingVersion']=_0x3b68c2['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x542d56,this['_continueCurrentRevision']=!0x1);}}else _0x3d842b&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x3d842b['toVersion'],this['editor']['model']['document']['history']['version']),_0x3d842b['fromVersion']===_0x3d842b['toVersion']?(0x0!==_0x3d842b['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x3d842b['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x3d842b['id'],this['_startingVersion']=_0x3d842b['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',_0x410eea=>!_0x410eea),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x3381cd=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0xe5f258;for(const _0x3b7b6a in _0x3381cd){const _0x1e663c=_0x3b7b6a,_0x18107c=_0x3381cd[_0x1e663c];if('revisionHistoryLicenseKeyValid'==_0x18107c||'revisionHistoryLicenseKeyInvalid'==_0x18107c||'revisionHistoryLicenseKeyExpired'==_0x18107c||'revisionHistoryLicenseKeyDomainLimit'==_0x18107c||'revisionHistoryLicenseKeyNotAllowed'==_0x18107c||'revisionHistoryLicenseKeyEvaluationLimit'==_0x18107c||'revisionHistoryLicenseKeyTrialLimit'==_0x18107c||'revisionHistoryLicenseKeyUsageLimit'==_0x18107c){delete _0x3381cd[_0x1e663c],_0xe5f258=_0x18107c,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0xe5f258&&_0x3381cd['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0xe5f258&&_0x3381cd['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0xe5f258&&_0x3381cd['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0xe5f258&&_0x3381cd['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0xe5f258&&_0x3381cd['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0xe5f258&&_0x3381cd['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0xe5f258&&_0x3381cd['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0xc3b938=this['repository']['getRevision'](0x0),_0x554ed1=await this['getRevisionDocumentData'](_0xc3b938),_0x4bec2d=await this['getRevisionRootsAttributes'](_0xc3b938);this['_replaceEditorDataWithRevisionData'](_0x554ed1,_0x4bec2d);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x52ff69){this['_source']=_0x52ff69;}async['update'](){const _0x2e8e3e=await this['_source']['getLatestVersion']();if(_0x2e8e3e>this['currentRevision']['toVersion']){await this['_loadState']();const _0x4e27a5=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x2e8e3e});_0x4e27a5['authors']=_0x4e27a5['authorsIds']['map'](_0x56c11e=>this['editor']['plugins']['get']('Users')['getUser'](_0x56c11e)),this['currentRevision']['_update'](_0x4e27a5);}}async['saveRevision'](_0x28c3c3={},_0x2e445f=null){const _0x4fa975=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x2e445f>this['currentRevision']['toVersion']&&(_0x2e445f=null),null===_0x2e445f&&(_0x2e445f=await this['_source']['getLatestVersion']());const _0x129595=this['_getFromVersion'](_0x2e445f),_0x4f354b=this['buildRevisionData']({'from':_0x129595,'to':_0x2e445f});if(this['currentRevision']['toVersion']<_0x2e445f){const _0x1a0ffc=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x2e445f,'to':_0x2e445f});_0x1a0ffc['authors']=[],_0x1a0ffc['authorsIds']=[],_0x1a0ffc['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x1a0ffc,!0x0),delete _0x1a0ffc['authors'],_0x4fa975['push'](_0x1a0ffc);}_0x28c3c3['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x28c3c3['name']=_0x28c3c3['name']||null,_0x28c3c3['id']=_0x28c3c3['id']||_0x5bd0bf(),_0x28c3c3={..._0x28c3c3,..._0x4f354b};const _0x185e84=this['addRevisionData'](_0x28c3c3);_0x4fa975['push'](_0x28c3c3);const _0x3ac70c=this['repository']['getIndex'](_0x185e84);if(0x0!==_0x3ac70c){const _0x63f69b=this['repository']['getRevision'](_0x3ac70c-0x1);if(_0x63f69b['fromVersion']!==_0x2e445f){const _0x425686=this['_revisionDataBuilder']['getData'](_0x2e445f,_0x63f69b['toVersion']),_0x3fb98a={'id':_0x63f69b['id'],'diffData':_0x425686['diffData'],'authorsIds':_0x425686['authorsIds'],'authors':_0x425686['authorsIds']['map'](_0x41b064=>this['editor']['plugins']['get']('Users')['getUser'](_0x41b064)),'fromVersion':_0x2e445f};_0x63f69b===this['currentRevision']&&(_0x3fb98a['createdAt']=new Date(_0x28c3c3['createdAt']['getTime']()+0xa)),_0x63f69b['_update'](_0x3fb98a,!0x0),delete _0x3fb98a['authors'],_0x4fa975['push'](_0x3fb98a);}}if(this['adapter']){for(const _0x121db3 of _0x4fa975)this['_bufferUpdate'](_0x121db3['id'],_0x121db3,!0x0);this['sendBufferedUpdates']();}return _0x185e84;}['addRevisionData'](_0x32c8ae){const _0x3bbd84=this['repository']['createRevision'](_0x32c8ae);return this['adapter']&&_0x3bbd84['on']('_update',(_0x572ee2,_0x18e4f3,_0x35462c)=>{_0x35462c||(this['_bufferUpdate'](_0x18e4f3['id'],_0x18e4f3,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x3bbd84,this['_findInsertionIndex'](_0x3bbd84)),_0x3bbd84;}async['getRevisionDocumentData'](_0x270234){return await this['_utils']['loadRevisionData'](_0x270234,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x270234);}async['getRevisionRootsAttributes'](_0x5f4eae){return await this['_utils']['loadRevisionData'](_0x5f4eae,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x5f4eae);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x536137=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x426d40=0x0;_0x426d40<_0x536137['length'];_0x426d40++){const _0x5f44a2=_0x536137[_0x426d40];let _0x4c788f=!0x1;for(const _0x1dfa91 of Object['keys'](_0x5f44a2))void 0x0===_0x5f44a2[_0x1dfa91]?delete _0x5f44a2[_0x1dfa91]:'id'!==_0x1dfa91&&(_0x4c788f=!0x0);_0x4c788f||(_0x536137[_0x426d40]=null);}if(_0x536137=_0x536137['filter'](_0x4b1d70=>null!==_0x4b1d70),!_0x536137['length'])return;for(let _0x3fb4c4=0x0;_0x3fb4c4<_0x536137['length'];_0x3fb4c4++){const _0x3526e9=_0x536137[_0x3fb4c4];void 0x0!==_0x3526e9['fromVersion']&&void 0x0===_0x3526e9['toVersion']&&(_0x3526e9['toVersion']=this['repository']['getRevision'](_0x3526e9['id'])['toVersion']),void 0x0!==_0x3526e9['toVersion']&&void 0x0===_0x3526e9['fromVersion']&&(_0x3526e9['fromVersion']=this['repository']['getRevision'](_0x3526e9['id'])['fromVersion']);}const _0x9bd9ec=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x536137,_0x9bd9ec)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x1fa97f=>{if(_0x1fa97f){for(const _0x2c3b86 of _0x1fa97f)this['setRevisionData']({'id':_0x2c3b86['id'],'createdAt':_0x2c3b86['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0x427b43=null,from:_0x1bb546=null,to:_0x3e2dd6=null}){_0x1bb546=null!==_0x1bb546?_0x1bb546:_0x427b43['fromVersion'],_0x3e2dd6=null!==_0x3e2dd6?_0x3e2dd6:_0x427b43['toVersion'];const _0x4166bf=this['_revisionDataBuilder']['getData'](_0x1bb546,_0x3e2dd6),_0x2ba327={'diffData':_0x4166bf['diffData'],'authorsIds':_0x4166bf['authorsIds'],'fromVersion':_0x1bb546,'toVersion':_0x3e2dd6};if(!_0x427b43||_0x3e2dd6!==_0x427b43['toVersion']){const _0x5bd0a4=_0x3e2dd6-0x1,_0x2fa590=this['_source']['history']['getOperation'](_0x5bd0a4);_0x2ba327['createdAt']=_0x2fa590&&_0x2fa590['createdAt']||new Date();}if(this['_loadedStateData']&&_0x1bb546===this['_loadedStateData']['fromVersion']){for(const _0x35cf5c of this['_loadedStateData']['authors'])_0x2ba327['authorsIds']['includes'](_0x35cf5c['id'])||_0x2ba327['authorsIds']['push'](_0x35cf5c['id']);}return _0x2ba327;}['_bufferUpdate'](_0x32a35d,_0x538118,_0x164b3a){if(this['_bufferedUpdates']['has'](_0x32a35d)){const _0x5ad32e=this['_bufferedUpdates']['get'](_0x32a35d);_0x538118=_0x164b3a?{..._0x5ad32e,..._0x538118}:{..._0x538118,..._0x5ad32e};}this['_bufferedUpdates']['set'](_0x32a35d,_0x538118);}['setRevisionData'](_0x41b8db){const _0x292a1d=this['repository']['getRevision'](_0x41b8db['id']);if(_0x41b8db['createdAt']&&(_0x41b8db['createdAt']=new Date(_0x41b8db['createdAt'])),_0x41b8db['authorsIds']){const _0x17829a=this['editor']['plugins']['get']('Users');_0x41b8db['authors']=_0x41b8db['authorsIds']['map'](_0x3ea51d=>_0x17829a['getUser'](_0x3ea51d));}_0x292a1d['_update'](_0x41b8db,!0x0);}['_createInitialRevision'](_0x2cfc98){const _0x5da7f6=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x5da7f6)this['_initialRevisionId']=_0x5da7f6['id'];else{const _0x669b68=!this['editor']['model']['document']['roots']['find'](_0xe9225c=>this['editor']['model']['hasContent'](_0xe9225c)),_0x169339=this['editor']['plugins']['get']('Users')['me']['id'],_0x483122=R(this['editor']['locale'],_0x669b68?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x2cfc98,'to':_0x2cfc98,'id':this['_initialRevisionId'],'name':_0x483122,'creatorId':_0x169339});}}['_createCurrentRevision'](_0xcdc7){const _0x27b36f=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x27b36f),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0xcdc7,'to':_0xcdc7,'id':_0x27b36f,'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'](_0x44b272,_0x16d00a){let _0x4cba19=this['editor']['config']['get']('initialData'),_0x4f2c00=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x4cba19){_0x4cba19={};for(const _0x1ee04f of this['editor']['model']['document']['getRootNames']())_0x4cba19[_0x1ee04f]='';}if('string'==typeof _0x4cba19&&(_0x4cba19={'main':_0x4cba19}),void 0x0===_0x4f2c00){_0x4f2c00={};for(const _0x280be6 of this['editor']['model']['document']['getRootNames']())_0x4f2c00[_0x280be6]={};}let _0x499c99=!0x1;const _0xc6ece4=Object['keys'](_0x4cba19),_0x2e2a46=Object['keys'](_0x44b272);for(const _0x33b4f7 of _0xc6ece4){if(_0x4cba19[_0x33b4f7]!==_0x44b272[_0x33b4f7]&&''!==_0x4cba19[_0x33b4f7]['trim']()){_0x499c99=!0x0;break;}if(!_0x43b1a0(_0x4f2c00[_0x33b4f7],_0x16d00a[_0x33b4f7])&&Object['keys'](_0x4f2c00[_0x33b4f7])['length']>0x0){_0x499c99=!0x0;break;}}_0x499c99||(_0x499c99=_0x2e2a46['some'](_0x1875ba=>!this['editor']['model']['document']['getRoot'](_0x1875ba))),_0x499c99&&_0x1e7653('editor-initial-data-replaced-with-revision-data',{'editorData':_0x4cba19,'editorRootsAttributes':_0x4f2c00,'revisionData':_0x44b272,'revisionRootsAttributes':_0x16d00a}),this['editor']['config']['set']('initialData',_0x44b272),this['editor']['config']['set']('rootsAttributes',_0x16d00a);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x2e9f12=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x2e9f12['add'](R(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x5d41d0){const _0x379e02=this['repository']['getRevisions']();_0x379e02['reverse']();let _0x4be3f6=0x0;for(;_0x4be3f6<_0x379e02['length'];){const _0x338cef=_0x379e02[_0x4be3f6];if(_0x338cef===this['currentRevision']){_0x4be3f6++;continue;}if(_0x338cef['id']===this['_initialRevisionId'])break;const _0x584e71=_0x5d41d0['toVersion']-_0x338cef['toVersion']||_0x5d41d0['fromVersion']-_0x338cef['fromVersion'];if(_0x584e71>0x0)break;if(_0x584e71<0x0)_0x4be3f6++;else{if(!_0x5d41d0['creator']&&_0x338cef['creator'])break;if(_0x338cef['creator']||!_0x5d41d0['creator']){if(_0x5d41d0['createdAt']>_0x338cef['createdAt'])break;_0x4be3f6++;}else _0x4be3f6++;}}return _0x4be3f6;}['_getFromVersion'](_0xbc56f9){const _0x4e02d6=this['repository']['getRevisions']();_0x4e02d6['reverse'](),_0x4e02d6['shift']();const _0xc003a7=_0x4e02d6['find'](_0x40f1dd=>_0x40f1dd['toVersion']<=_0xbc56f9)['toVersion'];return _0xc003a7<this['_startingVersion']?this['_startingVersion']:_0xc003a7;}['_makeRevision']({name:_0x490146,from:_0x371251,to:_0x47dfce,creatorId:_0x2c70a8,id:_0x247911}){const _0x1615f5=this['buildRevisionData']({'from':_0x371251,'to':_0x47dfce});_0x1615f5['name']=_0x490146,_0x1615f5['creatorId']=_0x2c70a8,_0x1615f5['id']=_0x247911;const _0xe74fde=this['addRevisionData'](_0x1615f5);return this['adapter']&&this['_bufferUpdate'](_0x1615f5['id'],_0x1615f5,!0x0),_0xe74fde;}['_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(_0x31e860){this['editor']=_0x31e860,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'](_0xdbab20){this['source']=_0xdbab20;const _0x2076f2=new Map(),_0x563ce5=new Map(),_0xf7f016=this['editor']['model']['document']['roots']['map'](_0x324460=>_0x324460['rootName']);for(const _0x2fc582 of _0xf7f016){const _0x2a959f=this['editor']['model']['document']['getRoot'](_0x2fc582),_0x345546=x(_0x2a959f);_0x2076f2['set'](_0x2fc582,_0x345546),_0x563ce5['set'](_0x2fc582,Object['fromEntries'](_0x2a959f['getAttributes']()));}const _0x50f0f6=Array['from'](this['editor']['model']['markers'])['map'](_0xf151fa=>[_0xf151fa['name'],_0xf151fa['getRange']()]),_0x3a3c29=this['source']['version'];this['_saveMetaData'](_0x3a3c29,_0x2076f2,_0x50f0f6,_0x563ce5),this['_startingRevisionId']=this['_revisionId'];const _0x28a53b=new Map(),_0x570000=new Map();for(const _0x2a6a1b of _0xf7f016){const _0x3799dd=N(_0x2a6a1b);_0x28a53b['set'](_0x2a6a1b,_0x3799dd),_0x570000['set'](_0x2a6a1b,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x28a53b,[],_0x570000);}['getData'](_0x1f175b,_0x51390c){if(this['_lastFrom']===_0x1f175b&&this['_lastTo']<=_0x51390c)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x51390c,!0x0);else{if(!this['_savedMetaData']['has'](_0x1f175b)){const _0x1af0b3=this['_getPreviousFrom'](_0x1f175b);this['_calculateMetaData'](_0x1af0b3,_0x1f175b,!0x1);}this['_calculateMetaData'](_0x1f175b,_0x51390c,!0x0);}return this['_lastFrom']=_0x1f175b,this['_lastTo']=_0x51390c,this['_getState']();}['loadState'](_0x229ad2){const _0x5a538b=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x229ad2['fromVersion'],this['_lastTo']=_0x229ad2['toVersion'];for(const _0x3d802e in _0x229ad2['diffData']){const _0x3e2b8f=_0x229ad2['diffData'][_0x3d802e]['attachChange'],_0xc71e6=_0x11d795(_0x229ad2['diffData'][_0x3d802e]['attributesBefore'])||{},_0x5ec7c7=_0x5a538b['_makeModelFromViewString'](_0x229ad2['diffData'][_0x3d802e]['deletions']);_0x5ec7c7['rootName']=_0x3d802e,_0x5ec7c7['_isAttached']=!_0x3e2b8f||!_0x3e2b8f['isAttached'],_0x5ec7c7['isAttached']=()=>_0x5ec7c7['_isAttached'],this['_baseRoots']['set'](_0x3d802e,_0x5ec7c7),this['_baseRootsAttributes']['set'](_0x3d802e,_0xc71e6),_0x3e2b8f&&this['_touchedRoots']['set'](_0x3d802e,_0x3e2b8f);const _0x366482=this['_makeIdsRoot'](_0x5ec7c7);this['_baseIdsRoots']['set'](_0x3d802e,_0x366482);for(const [_0x13cbd7,_0x29863b]of _0x5ec7c7['markers']){if(!_0x13cbd7['startsWith']('revision:'))continue;const _0x242318=_0x13cbd7['split'](':')[0x2];for(const _0x2c3060 of _0x29863b['getWalker']({'singleCharacters':!0x0})){const _0x4ad11a=this['_getVidAttributeName'](_0x2c3060),_0xe3f495='elementEnd'==_0x2c3060['type']?_0x2c3060['previousPosition']['path']['slice'](0x0,-0x1):_0x2c3060['previousPosition']['path'],_0x3e78f6=_0x366482['getNodeByPath'](_0xe3f495)['getAttribute'](_0x4ad11a);this['_touched']['set'](_0x3e78f6,{'userId':_0x242318});}}}this['_startingRevisionId']=this['_revisionId'];const _0x6f4d9d=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x4bc8c4=>!this['_touched']['has'](_0x4bc8c4));let _0x4f015e=0x0;const _0x76c5d0=new Map();for(const _0x5b493e in _0x229ad2['diffData']){const _0x388937=_0x229ad2['diffData'][_0x5b493e]['attachChange'],_0x59fabc=_0x11d795(_0x229ad2['diffData'][_0x5b493e]['attributesAfter'])||{},_0x59292d=_0x5a538b['_makeModelFromViewString'](_0x229ad2['diffData'][_0x5b493e]['insertions']);_0x59292d['rootName']=_0x5b493e,_0x59292d['_isAttached']=!_0x388937||_0x388937['isAttached'],_0x59292d['isAttached']=()=>_0x59292d['_isAttached'],this['_diffRoots']['set'](_0x5b493e,_0x59292d),this['_diffRootsAttributes']['set'](_0x5b493e,_0x59fabc);const _0x4bf370=this['_makeIdsRoot'](_0x59292d,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x5b493e,_0x4bf370),_0x76c5d0['set'](_0x5b493e,_0x59292d['isAttached']()?_0x59fabc:{});for(const [_0x1eb844,_0x59cb0f]of _0x59292d['markers']){if(!_0x1eb844['startsWith']('revision:'))continue;const _0x509883=_0x1eb844['split'](':')[0x2];for(const _0xa24910 of _0x59cb0f['getWalker']({'singleCharacters':!0x0})){const _0x357be8=this['_getVidAttributeName'](_0xa24910),_0x394faf=this['_revisionId']++,_0x38d2f3='elementEnd'==_0xa24910['type']?_0xa24910['previousPosition']['path']['slice'](0x0,-0x1):_0xa24910['previousPosition']['path'];_0x4bf370['getNodeByPath'](_0x38d2f3)['_setAttribute'](_0x357be8,_0x394faf),this['_touched']['set'](_0x394faf,{'userId':_0x509883});}}for(const _0x3351a9 of this['editor']['model']['createRangeIn'](_0x59292d)['getWalker']({'singleCharacters':!0x0})){const _0x318293=this['_getVidAttributeName'](_0x3351a9),_0x4af798='elementEnd'==_0x3351a9['type']?_0x3351a9['previousPosition']['path']['slice'](0x0,-0x1):_0x3351a9['previousPosition']['path'],_0x5bf23d=_0x4bf370['getNodeByPath'](_0x4af798);_0x5bf23d['getAttribute'](_0x318293)>0x0||_0x5bf23d['_setAttribute'](_0x318293,_0x6f4d9d[_0x4f015e++]);}for(const [_0xf97322,_0x2ce8e7]of _0x59292d['markers'])_0xf97322['startsWith']('revision:')||this['_markers']['set'](_0xf97322,_0x2ce8e7);}const _0x59a6bf=N('$graveyard');this['_baseRoots']['set']('$graveyard',_0x59a6bf),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x59a6bf,0x1));const _0x5d3261=N('$graveyard');this['_diffRoots']['set']('$graveyard',_0x5d3261),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x5d3261,0x1));const _0x3b6791=Array['from'](this['_diffRoots'])['map'](([_0x48856c,_0xd45c76])=>[_0x48856c,x(_0xd45c76)]);this['_saveMetaData'](this['_lastTo'],_0x3b6791,this['_markers'],_0x76c5d0);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0x1bb5b2,_0x10a462,_0xa0ba93,_0x58d173){const _0x5f4b35=new Map(_0x10a462),_0x4e8561=new Map(_0x11d795(_0x58d173)),_0x19ab18=new Map();for(const [_0x5d81a8,_0x4cdf6b]of _0xa0ba93)_0x19ab18['set'](_0x5d81a8,{'start':_0x4cdf6b['start']['clone'](),'end':_0x4cdf6b['end']['clone'](),'rootName':_0x4cdf6b['root']['rootName']});this['_savedMetaData']['set'](_0x1bb5b2,{'roots':_0x5f4b35,'markers':_0x19ab18,'rootsAttributes':_0x4e8561});}['_removeMetaData'](_0x2121d1){this['_savedMetaData']['delete'](_0x2121d1);}['_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'](_0x1e7a88,_0x422cf1=null){let _0x177eef=null;_0x1e7a88['is']('documentFragment')||(_0x177eef=new _0x599036(_0x1e7a88['name'],{'vid_start':null===_0x422cf1?this['_revisionId']++:_0x422cf1++}));const _0xe70239=[];for(const _0x404aa1 of _0x1e7a88['getChildren']())if(_0x404aa1['is']('element')){_0xe70239['push'](this['_makeIdsRoot'](_0x404aa1,_0x422cf1));const _0x1a5839=_0xe70239[_0xe70239['length']-0x1];null!==_0x422cf1&&(_0x422cf1=_0x1a5839['is']('element','$text')?_0x1a5839['getAttribute']('vid')+0x1:_0x1a5839['getAttribute']('vid_end')+0x1);}else{for(let _0x757c5e=0x0;_0x757c5e<_0x404aa1['offsetSize'];_0x757c5e++)_0xe70239['push'](new _0x599036('$text',{'vid':null===_0x422cf1?this['_revisionId']++:_0x422cf1++}));}if(_0x1e7a88['is']('documentFragment')){const _0x1e56f=N(_0x1e7a88['rootName']);return _0x1e56f['_insertChild'](0x0,_0xe70239),_0x1e56f;}return _0x177eef['_setAttribute']('vid_end',null===_0x422cf1?this['_revisionId']++:_0x422cf1++),_0x177eef['_insertChild'](0x0,_0xe70239),_0x177eef;}['_calculateMetaData'](_0x17d8a9,_0x1673f8,_0x3cb71b){this['_reset']();const {roots:_0x560d1e,markers:_0x35859c,rootsAttributes:_0x548a9a}=this['_savedMetaData']['get'](_0x17d8a9);this['_baseRoots']=new Map(_0x560d1e),this['_baseRootsAttributes']=new Map(_0x11d795(_0x548a9a));for(const [_0x3c841b,_0x191a7b]of this['_baseRoots'])if('$graveyard'!==_0x3c841b&&(this['_diffRoots']['set'](_0x3c841b,x(_0x191a7b)),this['_diffRootsAttributes']=new Map(_0x11d795(_0x548a9a)),_0x3cb71b)){const _0x11ffd2=this['_revisionId'];this['_idsRoots']['set'](_0x3c841b,this['_makeIdsRoot'](_0x191a7b)),this['_baseIdsRoots']['set'](_0x3c841b,this['_makeIdsRoot'](_0x191a7b,_0x11ffd2));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',x(this['_baseRoots']['get']('$graveyard'))),_0x3cb71b&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x729a6e,_0x3a97f7]of _0x35859c){const _0x488d71=this['_baseRoots']['get'](_0x3a97f7['rootName']),_0x3fe458=this['_diffRoots']['get'](_0x3a97f7['rootName']),_0x238c4c=new _0x573a12(this['_fixPosition'](_0x3a97f7['start'],_0x488d71),this['_fixPosition'](_0x3a97f7['end'],_0x488d71)),_0x1be794=this['_fixRange'](_0x238c4c,_0x3fe458);_0x488d71['markers']['set'](_0x729a6e,_0x238c4c),this['_markers']['set'](_0x729a6e,_0x1be794);}this['_applyOperations'](_0x17d8a9,_0x1673f8,_0x3cb71b);}['_applyOperations'](_0x4399f7,_0x19a592,_0xf7b71a){for(const _0x412c0c of this['source']['getOperations'](_0x4399f7,_0x19a592))this['_handleOperation'](_0x412c0c,_0xf7b71a);for(const _0x24ea27 of this['_diffRoots']['values']())_0x24ea27['markers']['clear']();for(const [_0x55eb44,_0x558d0c]of this['_markers']){this['_diffRoots']['get'](_0x558d0c['root']['rootName'])['markers']['set'](_0x55eb44,_0x558d0c['clone']());}const _0x20854c=new Map(),_0x1d8ed9=new Map();for(const [_0x24cf15,_0x42e4b1]of this['_diffRoots'])_0x20854c['set'](_0x24cf15,x(_0x42e4b1)),_0x1d8ed9['set'](_0x24cf15,this['_diffRootsAttributes']['get'](_0x24cf15));this['_saveMetaData'](_0x19a592,_0x20854c,this['_markers'],_0x1d8ed9);}['_getPreviousFrom'](_0x12c916){const _0x6c9201=Array['from'](this['_savedMetaData']['keys']());_0x6c9201['sort']((_0x49e72a,_0x24d2cb)=>_0x49e72a-_0x24d2cb),_0x6c9201['reverse']();for(const _0x2c1b52 of _0x6c9201)if(_0x2c1b52<_0x12c916)return _0x2c1b52;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x4d61ee,_0x19828a){const _0x1559b5=Array['from'](_0x19828a['markers'])['map'](([_0x5a121d,_0x183835])=>[_0x5a121d,this['_fixRange'](_0x183835,_0x4d61ee)]);_0x4d61ee['markers']=new Map(_0x1559b5);}['_transformMarkers'](_0x2138b6){for(const _0x5d42b4 of this['_markers']['values']()){const _0x537ed6=_0x5d42b4['getTransformedByOperation'](_0x2138b6),_0x57ea46=_0x573a12['_createFromRanges'](_0x537ed6);_0x5d42b4['start']=_0x57ea46['start'],_0x5d42b4['end']=_0x57ea46['end'];}}['_handleOperation'](_0x3a0d5d,_0x1e7c1e){if('addRoot'!=_0x3a0d5d['type']&&'detachRoot'!=_0x3a0d5d['type']){if('insert'==_0x3a0d5d['type']){const _0x596c72=_0x3a0d5d['position']['root']['rootName'];this['_diffRoots']['has'](_0x596c72)||(this['_diffRoots']['set'](_0x596c72,N(_0x596c72,!0x0)),this['_diffRootsAttributes']['set'](_0x596c72,{}),_0x1e7c1e&&this['_idsRoots']['set'](_0x596c72,N(_0x596c72,!0x0)));}else{if('addRootAttribute'==_0x3a0d5d['type']||'removeRootAttribute'==_0x3a0d5d['type']||'changeRootAttribute'==_0x3a0d5d['type'])return void this['_handleRootAttributeOperation'](_0x3a0d5d);'marker'==_0x3a0d5d['type']&&this['_handleMarkerOperation'](_0x3a0d5d);}if('marker'!==_0x3a0d5d['type']){const _0x33e752=this['_cloneOperation'](_0x3a0d5d,this['_diffRoots']);_0x33e752['_execute'](),this['_transformMarkers'](_0x33e752);}if(_0x1e7c1e)switch(_0x3a0d5d['type']){case'insert':this['_handleInsertOperation'](_0x3a0d5d);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x3a0d5d);break;case'merge':this['_handleMergeOperation'](_0x3a0d5d);break;case'split':this['_handleSplitOperation'](_0x3a0d5d);}}else this['_handleRootOperation'](_0x3a0d5d,_0x1e7c1e);}['_cloneOperation'](_0x290716,_0x53e127){const _0x5e4102=_0x290716['clone']();return _0x5e4102['_authorId']=_0x290716['_authorId'],this['_fixOperation'](_0x5e4102,_0x53e127),_0x5e4102;}['_getBaseVids'](_0x21f17f){return _0x21f17f['map'](_0x1f06ff=>{const _0xb01371=this['_getVidAttributeName'](_0x1f06ff);return Number(_0x1f06ff['item']['getAttribute'](_0xb01371));});}['_generateTape'](_0x1290fb,_0x1f40af){if(_0x1290fb['is']('element','$text'))_0x1f40af['push']({'item':_0x1290fb,'type':'text'});else{_0x1290fb['is']('element')&&_0x1f40af['push']({'item':_0x1290fb,'type':'elementStart'});for(const _0x17ef74 of _0x1290fb['getChildren']())this['_generateTape'](_0x17ef74,_0x1f40af);_0x1290fb['is']('element')&&_0x1f40af['push']({'item':_0x1290fb,'type':'elementEnd'});}return _0x1f40af;}['_getState'](){const _0x24aba0=new Map(this['_touched']),_0x488026=new Map(_0x24aba0),_0x133508=new Map(),_0x4e4f63={'insertions':{},'deletions':{}},_0x4f0dc3={'insertions':{},'deletions':{}},_0x17ddf5=new Map(),_0x595215=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x595215['delete']('$graveyard');for(const _0x2d6cf4 of _0x595215){const _0x4cdff0=this['_diffRoots']['get'](_0x2d6cf4)||N(_0x2d6cf4,!0x1),_0x11fb4d=this['_baseRoots']['get'](_0x2d6cf4)||N(_0x2d6cf4,!0x1);_0x4cdff0['isAttached']()||_0x11fb4d['isAttached']()?(_0x4e4f63['insertions'][_0x2d6cf4]=x(_0x4cdff0),_0x4e4f63['deletions'][_0x2d6cf4]=x(_0x11fb4d),this['_copyMarkers'](_0x4e4f63['deletions'][_0x2d6cf4],_0x11fb4d),this['_copyMarkers'](_0x4e4f63['insertions'][_0x2d6cf4],_0x4cdff0),_0x4f0dc3['insertions'][_0x2d6cf4]=this['_generateTape'](this['_idsRoots']['get'](_0x2d6cf4),[]),_0x4f0dc3['deletions'][_0x2d6cf4]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x2d6cf4)||N(_0x2d6cf4,!0x1),[])):_0x595215['delete'](_0x2d6cf4);}for(const _0x3fc995 of _0x595215){const _0x4a0184=_0x4f0dc3['insertions'][_0x3fc995];for(const _0x3ba28d of _0x4a0184){const _0x2a4809=this['_getVidAttributeName'](_0x3ba28d),_0x38e0be=_0x3ba28d['item']['getAttribute'](_0x2a4809);_0x488026['delete'](_0x38e0be),_0x38e0be>=this['_startingRevisionId']&&_0x133508['set'](_0x38e0be,_0x24aba0['get'](_0x38e0be));}}for(const _0x382f47 of _0x595215){const _0x107a41=_0x4f0dc3['insertions'][_0x382f47],_0x2176f2=this['_getBaseVids'](_0x4f0dc3['deletions'][_0x382f47]);let _0x3a91f4=0x0;for(const _0x104850 of _0x107a41){const _0x527acc=this['_getVidAttributeName'](_0x104850),_0x2df53a=_0x104850['item']['getAttribute'](_0x527acc);if(!_0x133508['has'](_0x2df53a)&&!_0x17ddf5['has'](_0x2df53a)){if(_0x488026['has'](_0x2df53a))_0x3a91f4++;else{if(_0x2df53a!=_0x2176f2[_0x3a91f4]){const _0x592daa=_0x24aba0['get'](_0x2df53a)||_0x24aba0['get'](_0x2176f2[_0x3a91f4]);for(;_0x2df53a!=_0x2176f2[_0x3a91f4];)_0x488026['has'](_0x2176f2[_0x3a91f4])||(_0x17ddf5['set'](_0x2176f2[_0x3a91f4],_0x592daa),_0x24aba0['set'](_0x2176f2[_0x3a91f4],_0x592daa)),_0x3a91f4++;}_0x3a91f4++;}}}}for(const _0x2d63e4 of _0x595215){const _0x3f15d7=_0x4f0dc3['insertions'][_0x2d63e4];for(const _0x3650bf of _0x3f15d7){const _0x3aa400=this['_getVidAttributeName'](_0x3650bf),_0x263770=_0x3650bf['item']['getAttribute'](_0x3aa400);if(_0x17ddf5['has'](_0x263770)){const _0x3a5b68=_0x17ddf5['get'](_0x263770);_0x488026['has'](_0x263770)||_0x488026['set'](_0x263770,{..._0x3a5b68}),_0x133508['set'](_0x263770,{..._0x3a5b68});}}}for(const _0x1f0f9f of _0x488026['keys']())_0x1f0f9f>=this['_startingRevisionId']&&_0x488026['delete'](_0x1f0f9f);const _0x26f2a3=new Map();for(const _0x240dba of _0x595215){let _0x335183=_0x4f0dc3['insertions'][_0x240dba];for(const _0x432879 of _0x335183)if(_0x432879['item']['is']('element','tableCell')){const _0x3f91f8=this['_getVidAttributeName'](_0x432879),_0xdecf80=_0x432879['item']['getAttribute'](_0x3f91f8);if(_0x133508['has'](_0xdecf80)){const _0x1b3e1f=_0x432879['item']['parent']['parent']['getAttribute']('vid_start'),_0x4649bb=_0x26f2a3['get'](_0x1b3e1f)||new Set();_0x4649bb['add'](_0x133508['get'](_0xdecf80)['userId']),_0x26f2a3['set'](_0x1b3e1f,_0x4649bb);}}_0x335183=_0x4f0dc3['deletions'][_0x240dba];for(const _0x5074df of _0x335183)if(_0x5074df['item']['is']('element','tableCell')){const _0x4ea901=this['_getVidAttributeName'](_0x5074df),_0x171c45=_0x5074df['item']['getAttribute'](_0x4ea901);if(_0x488026['has'](_0x171c45)){const _0xae7de5=_0x5074df['item']['parent']['parent']['getAttribute']('vid_start'),_0x331692=_0x26f2a3['get'](_0xae7de5)||new Set();_0x331692['add'](_0x488026['get'](_0x171c45)['userId']),_0x26f2a3['set'](_0xae7de5,_0x331692);}}for(const _0x380156 of _0x26f2a3['keys']())(_0x133508['has'](_0x380156)||_0x488026['has'](_0x380156))&&_0x26f2a3['delete'](_0x380156);}for(const _0x4c204e of _0x595215){const _0x41bfd5=_0x4f0dc3['insertions'][_0x4c204e];let _0x24463d=null,_0x588669=null;for(const _0x3c7124 of _0x41bfd5){const _0x29ecd6=this['_getVidAttributeName'](_0x3c7124),_0x3d935f=_0x3c7124['item']['getAttribute'](_0x29ecd6),_0x218a28=_0x26f2a3['get'](_0x3d935f);_0x218a28&&'elementStart'==_0x3c7124['type']&&(_0x24463d=Array['from'](_0x218a28)[0x0],_0x588669=_0x3c7124['item']['getAttribute']('vid_end')),_0x24463d&&(_0x488026['set'](_0x3d935f,{'userId':_0x24463d}),_0x133508['set'](_0x3d935f,{'userId':_0x24463d})),_0x3d935f==_0x588669&&(_0x24463d=null,_0x588669=null);}}const _0x1e7f05={},_0x2ed90b=new Set();for(const _0x4bd6d2 of _0x595215){const _0x4c8ef9=_0x4e4f63['deletions'][_0x4bd6d2],_0x1a68a9=_0x4e4f63['insertions'][_0x4bd6d2];for(const {userId:_0x5f2162}of this['_touchedMarkers']['values']())null!==_0x5f2162&&_0x2ed90b['add'](_0x5f2162);for(const {userId:_0x2df9b0}of this['_touchedRoots']['values']())null!==_0x2df9b0&&_0x2ed90b['add'](_0x2df9b0);this['_markChanges'](_0x1a68a9,_0x4f0dc3['insertions'][_0x4bd6d2],_0x133508,'insertion',_0x2ed90b),this['_markChanges'](_0x4c8ef9,_0x4f0dc3['deletions'][_0x4bd6d2],_0x488026,'deletion',_0x2ed90b),_0x1e7f05[_0x4bd6d2]={'insertions':this['_prepareViewToSave'](_0x1a68a9),'deletions':this['_prepareViewToSave'](_0x4c8ef9),'attachChange':this['_touchedRoots']['get'](_0x4bd6d2)||null,'attributesBefore':_0x11d795(this['_baseRootsAttributes']['get'](_0x4bd6d2))||{},'attributesAfter':_0x11d795(this['_diffRootsAttributes']['get'](_0x4bd6d2))};}return{'diffData':_0x1e7f05,'authorsIds':Array['from'](_0x2ed90b)};}['_processRootBeforeSave'](_0x4b6da4){for(const [,_0x2f343b]of _0x4b6da4['markers']){const _0x5aa4a9=_0x2f343b['start']['getAncestors']()['filter'](_0x25235a=>'tableCell'==_0x25235a['name']);for(const _0x2ee2bc of _0x5aa4a9)0x1==_0x2ee2bc['childCount']&&_0x2ee2bc['getChild'](0x0)['is']('element','paragraph')&&_0x2ee2bc['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x1b0e64){this['_processRootBeforeSave'](_0x1b0e64);const _0x3bff22=this['editor']['data']['toView'](_0x1b0e64,{}),_0x290b9c=Array['from'](_0x3bff22['getChildren']())['map'](_0x801587=>this['_getViewJson'](_0x801587));return JSON['stringify'](_0x290b9c);}['_getViewJson'](_0x362e45){if(_0x362e45['is']('$text'))return _0x362e45['data'];{const _0x488400=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0x270e93=_0x362e45,_0xb14e4a=this['editor']['data']['htmlProcessor']['domConverter'],_0x130bb2={'type':_0x488400['_getTypeCharForViewElement'](_0x270e93),'name':_0x270e93['name'],'attributes':Array['from'](_0x270e93['getAttributes']()),'children':Array['from'](_0x270e93['getChildren']())['map'](_0x2d149d=>this['_getViewJson'](_0x2d149d))};if(_0x362e45['is']('uiElement')&&'$comment'!=_0x362e45['name']){const _0x38260a=_0x362e45['render'](_0xb14e4a['domDocument'],_0xb14e4a);_0x130bb2['children']['push'](_0x38260a['outerHTML']);}else{if(_0x362e45['is']('rawElement')){const _0x49ad6b=_0xb14e4a['domDocument']['createElement'](_0x270e93['name']);_0x362e45['render'](_0x49ad6b,_0xb14e4a),_0x130bb2['children']['push'](_0x49ad6b['innerHTML']);}}const _0x40def8=Array['from'](_0x270e93['getCustomProperties']());_0x40def8['length']>0x0&&(_0x130bb2['customProperties']=_0x40def8);const _0x354bd6=_0x270e93['getFillerOffset']();return null!==_0x354bd6&&(_0x130bb2['fillerOffset']=_0x354bd6),_0x130bb2;}}['_markChanges'](_0x42f3ef,_0x2547aa,_0x3c3dbd,_0x4dddf4,_0x4730eb){let _0x1d8c53=null,_0x201ae1=null,_0x155966=0x0;const _0xb64bb5=this['editor']['model'];for(let _0x436f8c=0x0;_0x436f8c<_0x2547aa['length'];_0x436f8c++){const _0x2d2822=this['_getVidAttributeName'](_0x2547aa[_0x436f8c]),_0x75abbe=_0x2547aa[_0x436f8c]['item']['getAttribute'](_0x2d2822),_0x3dbd45=_0x3c3dbd['get'](_0x75abbe),_0x19e6de=_0x436f8c==_0x2547aa['length']-0x1;(!_0x1d8c53&&_0x3dbd45&&(_0x1d8c53=_0x3dbd45,_0x201ae1=_0x2547aa[_0x436f8c]),_0x1d8c53&&(!_0x3dbd45||_0x3dbd45['userId']!=_0x1d8c53['userId']))&&(_0x74b484(_0x3dbd45,P(_0x201ae1,_0x42f3ef,_0xb64bb5),P(_0x2547aa[_0x436f8c],_0x42f3ef,_0xb64bb5)),_0x1d8c53=_0x3dbd45||null,_0x201ae1=_0x3dbd45?_0x2547aa[_0x436f8c]:null),_0x1d8c53&&_0x19e6de&&_0x74b484(_0x3dbd45,P(_0x201ae1,_0x42f3ef,_0xb64bb5),V(_0x2547aa[_0x436f8c],_0x42f3ef,_0xb64bb5));}function _0x74b484(_0x44e8b9,_0x3cc9a3,_0x872b4c){const _0x5d9eb4=_0x1d8c53['userId'],_0x58ef60='revision:'+_0x4dddf4+':'+_0x5d9eb4+':'+_0x155966++,_0x2c1c5c=_0xb64bb5['createRange'](_0x3cc9a3,_0x872b4c);_0x42f3ef['markers']['set'](_0x58ef60,_0x2c1c5c),null!==_0x5d9eb4&&_0x4730eb['add'](_0x5d9eb4);}}['_getVidAttributeName'](_0x19477d){switch(_0x19477d['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x5d624f,_0x15c090){_0x5d624f['baseVersion']=null;for(const _0x16e253 in _0x5d624f){const _0x1c22be=_0x5d624f[_0x16e253];if(_0x1c22be instanceof _0x1d67e9){const _0x288b82=_0x15c090['get'](_0x1c22be['root']['rootName']);_0x5d624f[_0x16e253]=this['_fixPosition'](_0x1c22be,_0x288b82);}if(_0x1c22be instanceof _0x573a12){const _0x2faea0=_0x15c090['get'](_0x1c22be['root']['rootName']);_0x5d624f[_0x16e253]=this['_fixRange'](_0x1c22be,_0x2faea0);}'root'===_0x16e253&&(_0x5d624f['root']=_0x15c090['get'](_0x5d624f['root']['rootName']));}}['_fixRange'](_0xe58975,_0x565f44){return this['editor']['model']['createRange'](this['_fixPosition'](_0xe58975['start'],_0x565f44),this['_fixPosition'](_0xe58975['end'],_0x565f44));}['_fixPosition'](_0x2f356a,_0x226d8d){return this['editor']['model']['createPositionFromPath'](_0x226d8d,_0x2f356a['path'],_0x2f356a['stickiness']);}['_handleInsertOperation'](_0x546552){const _0x4c3b01=this['_idsRoots']['get'](_0x546552['position']['root']['rootName']),_0x47e1de=this['_fixPosition'](_0x546552['position'],_0x4c3b01),_0x3ce08e=null===_0x546552['_authorId']?null:_0x546552['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0xc8a5b2=_0x47e1de['parent'],_0xd9573a=this['_revisionId'],_0x5554c8=[];for(const _0xff19ef of _0x546552['nodes'])if(_0xff19ef['is']('element'))_0x5554c8['push'](this['_makeIdsRoot'](_0xff19ef));else{for(let _0x33b92f=0x0;_0x33b92f<_0xff19ef['offsetSize'];_0x33b92f++)_0x5554c8['push'](new _0x599036('$text',{'vid':this['_revisionId']++}));}const _0x169ee0=this['_revisionId'];for(let _0x20ce8b=_0xd9573a;_0x20ce8b<_0x169ee0;_0x20ce8b++)this['_touched']['set'](_0x20ce8b,{'userId':_0x3ce08e});_0xc8a5b2['_insertChild'](_0x47e1de['offset'],_0x5554c8);}['_handleMoveOperation'](_0x4c96e0){(_0x4c96e0=this['_cloneOperation'](_0x4c96e0,this['_idsRoots']))['_execute']();const _0x37aed2=null===_0x4c96e0['_authorId']?null:_0x4c96e0['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x27be67=_0x4c96e0['getMovedRangeStart'](),_0x3bb17d=_0x27be67['parent'],_0x3b0796=_0x27be67['offset'];!function _0x59395e(_0x5697a6,_0xfd4c09,_0x5c101b,_0x4ed72d){for(let _0x337c7b=_0x5c101b;_0x337c7b<_0x4ed72d;_0x337c7b++){const _0x23d54c=_0xfd4c09['getChild'](_0x337c7b);_0x23d54c['is']('element','$text')?_0x5697a6['set'](_0x23d54c['getAttribute']('vid'),{'userId':_0x37aed2}):(_0x5697a6['set'](_0x23d54c['getAttribute']('vid_start'),{'userId':_0x37aed2}),_0x59395e(_0x5697a6,_0x23d54c,0x0,_0x23d54c['childCount']),_0x5697a6['set'](_0x23d54c['getAttribute']('vid_end'),{'userId':_0x37aed2}));}}(this['_touched'],_0x3bb17d,_0x3b0796,_0x3b0796+_0x4c96e0['howMany']);}['_handleMergeOperation'](_0x43fe06){const _0x4cb53e=null===(_0x43fe06=this['_cloneOperation'](_0x43fe06,this['_idsRoots']))['_authorId']?null:_0x43fe06['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x4a09ff=_0x43fe06['targetPosition']['parent'],_0x14a3bf=_0x43fe06['sourcePosition']['parent'],_0x9960e3=_0x4a09ff['getAttribute']('vid_end'),_0x1fcd03=_0x14a3bf['getAttribute']('vid_start');_0x4a09ff['_setAttribute']('vid_end',_0x14a3bf['getAttribute']('vid_end')),_0x14a3bf['_setAttribute']('vid_end',_0x9960e3),this['_touched']['set'](_0x1fcd03,{'userId':_0x4cb53e}),this['_touched']['set'](_0x9960e3,{'userId':_0x4cb53e}),_0x43fe06['_execute']();}['_handleSplitOperation'](_0x3a011c){const _0x5d7e50=null===(_0x3a011c=this['_cloneOperation'](_0x3a011c,this['_idsRoots']))['_authorId']?null:_0x3a011c['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x2e2d72=_0x3a011c['graveyardPosition'],_0x3dca25=_0x3a011c['splitPosition']['parent'];_0x3a011c['_execute']();const _0x204fdc=_0x3dca25['getAttribute']('vid_end'),_0x473b2e=_0x3a011c['insertionPosition']['nodeAfter'];if(_0x2e2d72){const _0x1e3efa=_0x473b2e['getAttribute']('vid_end'),_0xf5081a=_0x3dca25['getAttribute']('vid_end');_0x3dca25['_setAttribute']('vid_end',_0x1e3efa),_0x473b2e['_setAttribute']('vid_end',_0xf5081a),this['_touched']['set'](_0x3dca25['getAttribute']('vid_end'),{'userId':_0x5d7e50}),this['_touched']['set'](_0x473b2e['getAttribute']('vid_start'),{'userId':_0x5d7e50});}else{const _0x327637=this['_revisionId']++,_0xe4463=this['_revisionId']++;_0x3dca25['_setAttribute']('vid_end',_0x327637),_0x473b2e['_setAttribute']('vid_start',_0xe4463),_0x473b2e['_setAttribute']('vid_end',_0x204fdc),this['_touched']['set'](_0x327637,{'userId':_0x5d7e50}),this['_touched']['set'](_0xe4463,{'userId':_0x5d7e50});}}['_handleMarkerOperation'](_0x4211aa){if(!_0x4211aa['affectsData'])return;const _0x5c8d3b=(_0x4211aa=this['_cloneOperation'](_0x4211aa,this['_diffRoots']))['oldRange']?_0x4211aa['oldRange']['root']:null,_0x388c42=_0x4211aa['newRange']?_0x4211aa['newRange']['root']:null;_0x5c8d3b&&this['_markers']['delete'](_0x4211aa['name']),_0x388c42&&this['_markers']['set'](_0x4211aa['name'],_0x4211aa['newRange']['clone']());const _0x233344=null===_0x4211aa['_authorId']?null:_0x4211aa['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x524c93=_0x4211aa['name'];if(!this['_touchedMarkers']['has'](_0x524c93))return void this['_touchedMarkers']['set'](_0x524c93,{'range':_0x4211aa['oldRange'],'userId':_0x233344});const _0x1215e3=this['_touchedMarkers']['get'](_0x524c93),_0x4fd4ed=_0x1215e3['range'],_0x5c3a49=_0x4211aa['newRange'];null==_0x4fd4ed&&null==_0x5c3a49||_0x4fd4ed&&_0x5c3a49&&_0x4fd4ed['isEqual'](_0x5c3a49)?this['_touchedMarkers']['delete'](_0x4211aa['name']):_0x1215e3['userId']=_0x233344;}['_handleRootOperation'](_0x341ea5,_0x8e35b9){this['_diffRoots']['has'](_0x341ea5['rootName'])?this['_diffRoots']['get'](_0x341ea5['rootName'])['_isAttached']=_0x341ea5['isAdd']:(this['_diffRoots']['set'](_0x341ea5['rootName'],N(_0x341ea5['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x341ea5['rootName'],{}),_0x8e35b9&&this['_idsRoots']['set'](_0x341ea5['rootName'],N(_0x341ea5['rootName'],!0x0)));const _0x55f94c=null===_0x341ea5['_authorId']?null:_0x341ea5['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x5a71c6=this['_touchedRoots']['get'](_0x341ea5['rootName']);_0x5a71c6&&_0x5a71c6['userId']===_0x55f94c?this['_touchedRoots']['delete'](_0x341ea5['rootName']):this['_touchedRoots']['set'](_0x341ea5['rootName'],{'userId':_0x55f94c,'isAttached':_0x341ea5['isAdd']});}['_handleRootAttributeOperation'](_0xcce43d){const _0x4bb411=this['_diffRootsAttributes']['get'](_0xcce43d['root']['rootName']);null===_0xcce43d['newValue']?delete _0x4bb411[_0xcce43d['key']]:_0x4bb411[_0xcce43d['key']]=_0xcce43d['newValue'];}}function x(_0x27b760){const _0x2b5a9c=N(_0x27b760['rootName'],_0x27b760['isAttached']());for(const _0x313c57 of _0x27b760['getChildren']()){const _0x3a95fa=_0x313c57['_clone'](!0x0);_0x2b5a9c['_appendChild'](_0x3a95fa);}return _0x2b5a9c;}function N(_0x3502a9,_0x4051b6=!0x0){const _0x3551fa=new _0x4c0b22();return _0x3551fa['rootName']=_0x3502a9,_0x3551fa['_isAttached']=_0x4051b6,_0x3551fa['isAttached']=()=>_0x3551fa['_isAttached'],_0x3551fa;}function P(_0x14cf74,_0x52b469,_0x48542f){const _0x5dd07b='elementEnd'==_0x14cf74['type']?_0x48542f['createPositionAt'](_0x14cf74['item'],'end'):_0x48542f['createPositionBefore'](_0x14cf74['item']);return _0x48542f['createPositionFromPath'](_0x52b469,_0x5dd07b['path'],_0x5dd07b['stickiness']);}function V(_0x5d6db6,_0x16e7d9,_0x904a4){const _0x239c6e='elementStart'==_0x5d6db6['type']?_0x904a4['createPositionAt'](_0x5d6db6['item'],0x0):_0x904a4['createPositionAfter'](_0x5d6db6['item']);return _0x904a4['createPositionFromPath'](_0x16e7d9,_0x239c6e['path'],_0x239c6e['stickiness']);}class he extends/* #__PURE__ -- @preserve */
25
+ _0x250264(_0x289a06){['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x5d37f4,_0x236a05){super(_0x5d37f4),this['focusTracker']=new _0x59744e(),this['keystrokes']=new _0x52a663(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x236a05),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'](),_0x324c76({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x6ea81b=_0x503398=>_0x503398['stopPropagation']();this['keystrokes']['set']('arrowright',_0x6ea81b),this['keystrokes']['set']('arrowleft',_0x6ea81b),this['keystrokes']['set']('arrowup',_0x6ea81b),this['keystrokes']['set']('arrowdown',_0x6ea81b);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x2fd6c7){this['revisionNameInputView']['fieldView']['element']['value']=_0x2fd6c7['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x39b7ad){const _0x364686=new ti(this['locale'],_0x104191),_0x148051=_0x364686['fieldView'];_0x148051['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x39d9f3=R(this['locale'],'Name\x20of\x20the\x20revision');return!_0x39b7ad&&(_0x39d9f3+='\x20('+R(this['locale'],'optional')+')'),(_0x364686['label']=_0x39d9f3,_0x148051['on']('input',()=>{this['revisionNameInputValue']=_0x148051['element']['value']['trim']();}),_0x364686);}}class v extends _0x557a5e{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h];}['_saveRevisionFormView'];['init'](){const _0x4b1fb9=this['editor'],_0x324a7f=_0x4b1fb9['plugins']['get']('RevisionTracker');_0x4b1fb9['ui']['componentFactory']['add']('revisionHistory',_0x58ca88=>{const _0x336791=_0x10ddda(_0x58ca88),_0x317b15=_0x336791['panelView']['children'],_0x39373d=new _0x1a06ac(_0x58ca88),_0x142cff=new _0x45ee3c(_0x58ca88),_0xafafa0=new _0x42cd9a(_0x58ca88),_0x4b8f32=new _0x45ee3c(_0x58ca88),_0x4c41a5=new _0x42cd9a(_0x58ca88);return _0x336791['bind']('isEnabled')['to'](_0x324a7f,'isReady',_0x324a7f,'isEnabled',_0x4b1fb9,'isReadOnly',(_0x183803,_0x2d612b,_0x2ba70c)=>_0x183803&&_0x2d612b&&!_0x2ba70c),_0x336791['buttonView']['set']({'icon':_0x205745,'label':R(_0x58ca88,'Revision\x20history'),'tooltip':!0x0}),_0xafafa0['set']({'label':R(_0x58ca88,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0xafafa0['bind']('isEnabled')['to'](_0x324a7f,'isReady',_0x324a7f,'isEnabled',_0x4b1fb9,'isReadOnly',(_0x2d281f,_0x5462e5,_0x39543c)=>_0x2d281f&&_0x5462e5&&!_0x39543c),_0xafafa0['on']('execute',()=>this['_showDialog']()),_0x4c41a5['set']({'label':R(_0x58ca88,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x4c41a5['bind']('isEnabled')['to'](_0x324a7f,'isReady',_0x4b1fb9,'isReadOnly',(_0x385376,_0x42b111)=>_0x385376&&!_0x42b111),_0x4c41a5['on']('execute',()=>{_0x4b1fb9['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x336791['isOpen']=!0x1,_0x4b1fb9['editing']['view']['focus']();}),_0x142cff['children']['add'](_0xafafa0),_0x4b8f32['children']['add'](_0x4c41a5),_0x39373d['role']='menu',_0x39373d['items']['addMany']([_0x142cff,_0x4b8f32]),_0x317b15['add'](_0x39373d),_0x336791;}),_0x4b1fb9['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0xbc52bc=this['editor'],_0x355944=_0xbc52bc['locale'],_0x44a078=new _0x2fbdef(_0x355944),_0x2e5b3f=new _0x55a029(_0x355944);_0x44a078['buttonView']['set']({'icon':_0x205745,'label':R(_0x355944,'Revision\x20history')});const _0x2c463d=new _0x1da77a(_0x355944,_0x44a078),_0x1d462a=new _0x1eb01a(_0x355944);_0x1d462a['set']({'label':R(_0x355944,'Save\x20current\x20revision')}),_0x1d462a['delegate']('execute')['to'](_0x44a078),_0x1d462a['on']('execute',()=>{this['_showDialog']();}),_0x2c463d['children']['add'](_0x1d462a),_0x2e5b3f['items']['add'](_0x2c463d);const _0x1883e1=new _0x1da77a(_0x355944,_0x44a078),_0x5b551c=new _0x1eb01a(_0x355944);return _0x5b551c['set']({'label':R(_0x355944,'Open\x20revision\x20history')}),_0x5b551c['delegate']('execute')['to'](_0x44a078),_0x5b551c['on']('execute',()=>{_0xbc52bc['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x1883e1['children']['add'](_0x5b551c),_0x2e5b3f['items']['add'](_0x1883e1),_0x44a078['panelView']['children']['add'](_0x2e5b3f),_0x44a078;}['_showDialog'](){const _0x482595=this['editor'],_0x277d9f=_0x482595['locale'],_0x5be814=_0x482595['plugins']['get']('Dialog'),_0x4b1ee6=_0x482595['plugins']['get']('RevisionTracker');function _0x1e4ff0(_0x2c47a0){_0x482595['config']['get']('revisionHistory.requireRevisionName')&&''===_0x2c47a0['revisionName']?_0x2c47a0['revisionNameInputView']['errorText']=R(_0x277d9f,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x482595['plugins']['get'](h)['saveRevision']({'name':_0x2c47a0['revisionName']}),_0x5be814['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x1e4ff0(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x5be814['show']({'id':'revisionSave','title':R(_0x277d9f,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':R(_0x482595['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x5be814['hide']()},{'label':R(_0x482595['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x34c0a3){_0x34c0a3['bind']('isEnabled')['to'](_0x4b1ee6,'isReady',_0x4b1ee6,'isEnabled',_0x482595,'isReadOnly',(_0x16a946,_0x1e8ef2,_0x30911b)=>_0x16a946&&_0x1e8ef2&&!_0x30911b);},'onExecute':()=>_0x1e4ff0(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x36c57d=this['editor'],_0x29f1ac=_0x36c57d['locale'];this['_saveRevisionFormView']=new he(_0x29f1ac,_0x36c57d['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class z extends _0x289a06{['changeId'];['_model'];constructor(_0x300b6b,_0x145ddd){super(_0x300b6b),this['_model']=_0x145ddd,this['changeId']=_0x145ddd['id'];const _0x50cb67=this['bindTemplate'],_0x4ae19c=R(_0x300b6b,_0x145ddd['data']['isSuggestion']?'Suggested\x20by':'add'==_0x145ddd['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x145ddd['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x50cb67['to']('type',_0x588616=>'ck-revision-change__'+_0x588616)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x4ae19c}]},{'text':'\x20'+_0x145ddd['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class G extends/* #__PURE__ -- @preserve */
26
+ _0x5d4f77(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x26fde4){super(),this['id']=_0x26fde4['id']||_0x5bd0bf(),this['author']=_0x26fde4['author'],this['type']=_0x26fde4['type'],this['data']=_0x26fde4['data']||{},this['rootName']=_0x26fde4['rootName'],this['set']('createdAt',_0x26fde4['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(_0x46b438,_0x67d533){this['newRevisionId']=_0x46b438,this['oldRevisionId']=_0x67d533,this['changes']=new _0x50c032();}['_setChanges'](_0x2b3e1e){for(const _0x2edb9e of _0x2b3e1e)this['changes']['add'](_0x2edb9e);}}class l extends _0x557a5e{['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[_0x2bd141,_0x207472,S,$];}constructor(_0x54390b){super(_0x54390b),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',(_0x15fefa,_0x1e8b96,_0x2baf9d)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x92154=>{for(const _0x4510a0 of this['editor']['editing']['view']['document']['roots'])_0x2baf9d?_0x92154['removeClass']('ck-editor__editable__overlay',_0x4510a0):_0x92154['addClass']('ck-editor__editable__overlay',_0x4510a0);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x46bdd1=>null!==_0x46bdd1),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x480f0d,_0x3067f6,_0x5a82c2)=>_0x480f0d&&_0x5a82c2?_0x3067f6['changes']['getIndex'](_0x5a82c2):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x3255e6,_0x182742)=>_0x3255e6?_0x182742['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0x207472);}['init'](){const _0x5d80ef=this['editor'],_0x3881f5=new ot(_0x5d80ef,{'direction':'backward'}),_0x49e0cc=new ot(_0x5d80ef,{'direction':'forward'});(_0x5d80ef['commands']['add']('showPreviousChange',_0x3881f5),_0x5d80ef['commands']['add']('showNextChange',_0x49e0cc),_0x5d80ef['commands']['add']('restoreRevision',new nt(_0x5d80ef)),this['on']('change:numberOfChanges',()=>{_0x3881f5['refresh'](),_0x49e0cc['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x5d80ef['enableReadOnlyMode']('revision-viewer'),_0x5d80ef['plugins']['has']('WidgetToolbarRepository'))&&_0x5d80ef['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x350df6){return await this['_utils']['loadRevisionData'](_0x350df6,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x350df6);}async['getRevisionRootsAttributes'](_0x8793c1){return await this['_utils']['loadRevisionData'](_0x8793c1,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x8793c1);}async['compare'](_0x4874a5,_0x35be97,_0x3b43f6=!0x1){if(!this['isEnabled'])return;const _0x36864d=this['diff'],_0x1bd658=this['repository'],_0x11fdca='string'==typeof _0x4874a5?_0x1bd658['getRevision'](_0x4874a5):_0x4874a5,_0x74211b='string'==typeof _0x35be97?_0x1bd658['getRevision'](_0x35be97):_0x35be97,_0x3e5d65=_0x11fdca['id'],_0x489b10=_0x74211b?_0x74211b['id']:null;if(!_0x3b43f6&&this['diff']&&this['diff']['newRevisionId']===_0x3e5d65&&this['diff']['oldRevisionId']===_0x489b10)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new J(_0x3e5d65,_0x489b10);const _0x161bac=this['_getRevisionsRange'](_0x11fdca,_0x74211b,!0x0)['map'](_0x57e901=>this['_utils']['loadRevisionData'](_0x57e901,this['adapter']));return _0x161bac['push'](new Promise(_0x2d06af=>{setTimeout(_0x2d06af,0x14);})),Promise['all'](_0x161bac)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x3d4e1d=this['_getDiff'](_0x3e5d65,_0x489b10);for(const _0x2fc0bc of _0x3d4e1d['changes'])this['_changeIdToChange']['set'](_0x2fc0bc['id'],_0x2fc0bc);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x5a8628=>{for(const _0x2c8a14 of this['editor']['model']['document']['getRootNames']())_0x5a8628['detachRoot'](_0x2c8a14);for(const _0x547763 of Object['keys'](_0x3d4e1d['model'])){const _0x2c0e3c=_0x5a8628['addRoot'](_0x547763);for(const _0x4bba41 of Object['keys'](_0x3d4e1d['attributes'][_0x547763]))_0x5a8628['setAttribute'](_0x4bba41,_0x3d4e1d['attributes'][_0x547763][_0x4bba41],_0x2c0e3c);_0x5a8628['insert'](_0x3d4e1d['model'][_0x547763],_0x2c0e3c,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x3d4e1d['changes'])),this['isReady']=!0x0;})['catch'](_0x50dcaa=>{console['error'](_0x50dcaa),this['_cleanUp'](),_0x36864d&&(this['diff']=_0x36864d),this['isReady']=!0x0;});}['addRevisionData'](_0x3204dc,_0x4a4bb5){const _0x55efd1=this['repository']['createRevision'](_0x3204dc);return _0x55efd1['on']('_update',(_0x4125da,_0x5092a1,_0x47450f)=>_0x4a4bb5(_0x5092a1,_0x47450f,_0x55efd1)),this['repository']['addRevision'](_0x55efd1),_0x55efd1;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x441234=>{for(const _0x205e0d of this['editor']['model']['document']['getRootNames']())_0x441234['detachRoot'](_0x205e0d);});}['_sortAndFilterDiffChanges'](_0x240235){const _0x2919ff=[],_0x200ba7=new Map();for(const _0x5c7610 of this['editor']['model']['document']['getRootNames']()){const _0x2aa51f=this['editor']['editing']['view']['getDomRoot'](_0x5c7610);if(!_0x2aa51f)continue;const _0x442fb7=_0x2aa51f['getClientRects']()['item'](0x0);_0x442fb7&&(_0x2919ff['push'](_0x5c7610),_0x200ba7['set'](_0x5c7610,_0x442fb7));}return _0x2919ff['sort']((_0x26620a,_0x10e5e6)=>{const _0x300236=_0x200ba7['get'](_0x26620a),_0x322c6e=_0x200ba7['get'](_0x10e5e6);return _0x300236['y']-_0x322c6e['y']||_0x300236['x']-_0x322c6e['x'];}),(_0x240235=_0x240235['filter'](_0x56e4c7=>_0x2919ff['includes'](_0x56e4c7['rootName'])))['sort']((_0x250194,_0x5e8b31)=>_0x2919ff['indexOf'](_0x250194['rootName'])-_0x2919ff['indexOf'](_0x5e8b31['rootName'])),_0x240235;}['_makeTape'](_0x30e78d){const _0x364bda=Array['from'](_0x30e78d['markers'])['filter'](([_0x118c9,_0x134b6b])=>_0x118c9['startsWith']('revision:')&&!_0x134b6b['isCollapsed']),_0x4f80b7=Array['from'](this['editor']['model']['createRangeIn'](_0x30e78d)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x364bda['length'])for(const _0x116db7 of _0x4f80b7){const [_0x2d993a,_0x16d4d0]=_0x364bda[0x0],[,_0x4806c7,_0x1be99e]=_0x2d993a['split'](':');if(_0x16d4d0['end']['isEqual'](_0x116db7['nextPosition'])&&_0x364bda['shift'](),(_0x116db7['previousPosition']['isEqual'](_0x16d4d0['start'])||_0x116db7['previousPosition']['isAfter'](_0x16d4d0['start']))&&('insertion'==_0x4806c7?_0x116db7['isAdded']={'userId':_0x1be99e}:'deletion'==_0x4806c7&&(_0x116db7['isRemoved']={'userId':_0x1be99e})),0x0==_0x364bda['length'])break;}return _0x4f80b7;}['_refreshStartEndIndex'](_0xd9d703){const _0x561f34=new Map();for(let _0x4a83e1=0x0;_0x4a83e1<_0xd9d703['length'];_0x4a83e1++)'text'===_0xd9d703[_0x4a83e1]['type']?(_0xd9d703[_0x4a83e1]['item']['startIndex']=_0x4a83e1,_0xd9d703[_0x4a83e1]['item']['endIndex']=_0x4a83e1):('elementStart'===_0xd9d703[_0x4a83e1]['type']?_0xd9d703[_0x4a83e1]['item']['startIndex']=_0x4a83e1:'elementEnd'===_0xd9d703[_0x4a83e1]['type']&&(_0xd9d703[_0x4a83e1]['item']['endIndex']=_0x4a83e1),_0x561f34['set'](_0xd9d703[_0x4a83e1]['id'],_0x4a83e1));for(const _0x5d93aa of _0x561f34['values']())'elementStart'===_0xd9d703[_0x5d93aa]['type']?_0xd9d703[_0x5d93aa]['item']['endIndex']=_0x561f34['get'](_0xd9d703[_0x5d93aa]['pairId']):'elementEnd'===_0xd9d703[_0x5d93aa]['type']&&(_0xd9d703[_0x5d93aa]['item']['startIndex']=_0x561f34['get'](_0xd9d703[_0x5d93aa]['pairId']));}['_processTape'](_0x124d70){for(let _0x56a46e=0x0;_0x56a46e<_0x124d70['length'];_0x56a46e++){if('elementStart'===_0x124d70[_0x56a46e]['type'])_0x124d70[_0x56a46e]['item']['startIndex']=_0x56a46e;else{if('elementEnd'===_0x124d70[_0x56a46e]['type']){_0x124d70[_0x56a46e]['item']['endIndex']=_0x56a46e;const _0x30baa2=_0x124d70[_0x56a46e]['item']['startIndex'];_0x124d70[_0x30baa2]['pairId']=_0x124d70[_0x56a46e]['id'],_0x124d70[_0x56a46e]['pairId']=_0x124d70[_0x30baa2]['id'];}else _0x124d70[_0x56a46e]['item']['startIndex']=_0x56a46e,_0x124d70[_0x56a46e]['item']['endIndex']=_0x56a46e,_0x124d70[_0x56a46e]['pairId']=null;}_0x124d70[_0x56a46e]['markersStart']||(_0x124d70[_0x56a46e]['markersStart']=[],_0x124d70[_0x56a46e]['markersEnd']=[]);}}['_markInsertions'](_0x2d09a7,_0x846cf5){const _0x74c01=_0x2d09a7['filter'](_0x5becac=>!_0x5becac['isAdded']);for(let _0x144d70=0x0;_0x144d70<_0x846cf5['length'];_0x144d70++)_0x846cf5[_0x144d70]['isAdded']&&(_0x74c01[_0x144d70]['isAdded']=_0x846cf5[_0x144d70]['isAdded']);}['_getDiff'](_0x23f5b6,_0x2f310d=null){const _0x314d90=this['repository']['getRevision'](_0x23f5b6),_0x59ec85=_0x2f310d?this['repository']['getRevision'](_0x2f310d):null,_0x46787a=this['_getRevisionsRange'](_0x314d90,_0x59ec85),_0x5ee12d=_0x46787a[_0x46787a['length']-0x1],_0x15f827=new Map(),_0x595270={'model':{},'attributes':{},'changes':[]},_0x11d1c2=new Set(),_0x1f8849=new Map();for(let _0x3a9655=_0x46787a['length']-0x1;_0x3a9655>=0x0;_0x3a9655--){const _0x3e18a1=_0x46787a[_0x3a9655];for(const _0x2675b1 of Object['keys'](_0x3e18a1['diffData']))if(_0x3e18a1['diffData'][_0x2675b1]['attachChange']){const _0x4f20be=_0x3e18a1['diffData'][_0x2675b1]['attachChange'];_0x4f20be['isAttached']?(_0x11d1c2['add'](_0x2675b1),_0x1f8849['has'](_0x2675b1)&&_0x1f8849['get'](_0x2675b1)['userId']==_0x4f20be['userId']?_0x1f8849['delete'](_0x2675b1):_0x1f8849['set'](_0x2675b1,_0x4f20be)):_0x1f8849['has'](_0x2675b1)?(_0x11d1c2['delete'](_0x2675b1),_0x1f8849['delete'](_0x2675b1)):(_0x11d1c2['add'](_0x2675b1),_0x1f8849['set'](_0x2675b1,_0x4f20be));}else _0x11d1c2['add'](_0x2675b1);}for(const _0x38f384 of _0x11d1c2){const _0x124589=_0x1f8849['has'](_0x38f384)&&!_0x1f8849['get'](_0x38f384)['isAttached'];let _0x377636=_0x124589?_0x46787a['length']-0x1:0x0;const _0x55d235=_0x124589?-0x1:0x1;for(;_0x46787a[_0x377636];){const _0x37654d=_0x46787a[_0x377636];if(_0x37654d['diffData'][_0x38f384]){const _0x955ec9=_0x124589?_0x37654d['diffData'][_0x38f384]['attributesBefore']:_0x37654d['diffData'][_0x38f384]['attributesAfter'];_0x595270['attributes'][_0x38f384]=_0x955ec9?_0x11d795(_0x955ec9):{};break;}_0x377636+=_0x55d235;}}for(const _0x33630d of _0x46787a){_0x33630d['model']={};for(const _0x1f9af5 of _0x33630d['authors'])_0x15f827['set'](_0x1f9af5['id'],_0x1f9af5);for(const _0x4ff991 of _0x11d1c2){const _0x520d04=_0x33630d['diffData'][_0x4ff991]?_0x33630d['diffData'][_0x4ff991]['insertions']:'[]',_0x129932=_0x33630d['diffData'][_0x4ff991]?_0x33630d['diffData'][_0x4ff991]['deletions']:'[]';_0x33630d['model'][_0x4ff991]={'insertions':this['_utils']['_makeModelFromViewString'](_0x520d04),'deletions':this['_utils']['_makeModelFromViewString'](_0x129932)};}}for(const _0x28d17b of _0x11d1c2){let _0x541ea8=null,_0x2847a4=0x0;const _0x4279a8=new Map(Array['from'](_0x314d90['model'][_0x28d17b]['insertions']['markers'])['filter'](([_0x2bb986])=>!_0x2bb986['startsWith']('revision:')));let _0x3e1323=0x0;for(const _0x2dba86 of _0x46787a){const _0x10835c=this['_makeTape'](_0x2dba86['model'][_0x28d17b]['insertions']);_0x2dba86==_0x314d90?(_0x541ea8=_0x10835c,_0x2847a4=_0x541ea8['length'],_0x541ea8['forEach'](_0xc8cef2=>{_0xc8cef2['id']=_0x3e1323++;}),this['_processTape'](_0x541ea8)):this['_markInsertions'](_0x541ea8,_0x10835c);const _0x51a3cc=_0x541ea8['filter'](_0x29c2f8=>!_0x29c2f8['isAdded'])['map'](_0x27b3c4=>_0x27b3c4['id']);let _0x2db14e=0x0;const _0x567ac9=this['_makeTape'](_0x2dba86['model'][_0x28d17b]['deletions']);_0x567ac9['forEach'](_0x3b8004=>{_0x3b8004['isRemoved']?_0x3b8004['id']=_0x2847a4++:_0x3b8004['id']=_0x51a3cc[_0x2db14e++];}),this['_processTape'](_0x567ac9),this['_setDistance'](_0x541ea8,'isAdded'),this['_setDistance'](_0x567ac9,'isRemoved'),_0x2dba86==_0x314d90&&this['_markMarkers'](_0x541ea8,_0x4279a8),_0x541ea8=this['_joinTapes'](_0x541ea8,_0x567ac9),this['_refreshStartEndIndex'](_0x541ea8),this['_setDistance'](_0x541ea8,'isRemoved');}_0x541ea8=_0x541ea8['filter'](_0x5001df=>!(_0x5001df['isAdded']&&_0x5001df['isRemoved']));const _0x17978f=new Map(_0x5ee12d['model'][_0x28d17b]['deletions']['markers']),_0x813a8b=new Set(_0x4279a8['keys']());for(const _0x4cb0d0 of _0x17978f['keys']())_0x813a8b['delete'](_0x4cb0d0);this['_markSuggestions'](_0x541ea8,_0x813a8b),this['_fixObsoleteTags'](_0x541ea8),_0x541ea8=this['_removeMissingPairs'](_0x541ea8),_0x541ea8=this['_markMismatchedRemovedTags'](_0x541ea8),_0x541ea8=this['_removeUnsupportedChanges'](_0x541ea8);const {root:_0x2a8fee,changes:_0x9b5249}=this['_makeModelFromTape'](_0x541ea8,_0x15f827,_0x28d17b);_0x595270['model'][_0x28d17b]=_0x2a8fee;const _0x34aad8=_0x1f8849['get'](_0x28d17b);if(_0x34aad8){const _0x3981db=_0x15f827['get'](_0x34aad8['userId']),_0x1ce0ac=new G({'author':_0x3981db,'type':_0x34aad8['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x28d17b});_0x9b5249['unshift'](_0x1ce0ac),_0x595270['attributes'][_0x28d17b]['revisionHistoryAttachChange']=_0x1ce0ac['id'];}_0x595270['changes']=_0x595270['changes']['concat'](_0x9b5249);}return _0x595270;}['_markMarkers'](_0x55be07,_0x192e20){for(let _0x417981=0x0;_0x417981<_0x55be07['length'];_0x417981++)for(const [_0x359593,_0x5836fd]of _0x192e20)!_0x5836fd['isCollapsed']&&_0x5836fd['start']['isEqual'](_0x55be07[_0x417981]['previousPosition'])&&_0x55be07[_0x417981]['markersStart']['push'](_0x359593),_0x5836fd['end']['isEqual'](_0x55be07[_0x417981]['nextPosition'])&&_0x55be07[_0x417981]['markersEnd']['push'](_0x359593);}['_joinTapes'](_0x4dd43b,_0x34bd4c){let _0x17ec16=[],_0x182cec=0x0,_0x163769=0x0;for(;_0x182cec<_0x4dd43b['length']||_0x163769<_0x34bd4c['length'];){const _0x2dfd1a=_0x4dd43b[_0x182cec]||{},_0x5e0379=_0x34bd4c[_0x163769]||{};if(_0x2dfd1a['id']==_0x5e0379['id'])_0x182cec++,_0x163769++,_0x17ec16['push'](_0x2dfd1a);else{if(_0x5e0379['isRemoved']&&_0x2dfd1a['isAdded']){const {commonTape:_0x3cd945,iEnd:_0x5b3ade,jEnd:_0x5d5e05}=this['_threeWayMerge'](_0x4dd43b,_0x182cec,_0x34bd4c,_0x163769);_0x17ec16=_0x17ec16['concat'](_0x3cd945),_0x182cec=_0x5b3ade,_0x163769=_0x5d5e05;}else _0x5e0379['isRemoved']?(_0x163769++,_0x17ec16['push'](_0x5e0379)):(_0x182cec++,_0x17ec16['push'](_0x2dfd1a));}}return _0x17ec16;}['_markSuggestions'](_0x4b424c,_0x292b37){const _0x392e6c=[];for(let _0x24e6f0=0x0;_0x24e6f0<_0x4b424c['length'];_0x24e6f0++){for(let _0x266a5b=0x0;_0x266a5b<_0x4b424c[_0x24e6f0]['markersStart']['length'];_0x266a5b++){const _0x2f031f=_0x4b424c[_0x24e6f0]['markersStart'][_0x266a5b];if(!_0x292b37['has'](_0x2f031f))continue;const {group:_0x40de38,type:_0x458155,authorId:_0x23606d}=_0x2c6bb5(_0x2f031f);'revision-suggestion'!=_0x40de38||'insertion'!=_0x458155&&'deletion'!=_0x458155||(_0x392e6c['unshift']({'type':_0x458155,'name':_0x2f031f,'userId':_0x23606d}),_0x4b424c[_0x24e6f0]['markersStart']['splice'](_0x266a5b,0x1),_0x266a5b--);}_0x4b666e(_0x4b424c[_0x24e6f0]);for(let _0x17e805=0x0;_0x17e805<_0x4b424c[_0x24e6f0]['markersEnd']['length'];_0x17e805++){const _0x58d961=_0x4b424c[_0x24e6f0]['markersEnd'][_0x17e805];if(!_0x292b37['has'](_0x58d961))continue;const {group:_0x16c188,type:_0x4c3560}=_0x2c6bb5(_0x58d961);if('revision-suggestion'!=_0x16c188||'insertion'!=_0x4c3560&&'deletion'!=_0x4c3560)continue;_0x4b424c[_0x24e6f0]['markersEnd']['splice'](_0x17e805,0x1),_0x17e805--;const _0x19af8d=_0x392e6c['findIndex'](_0x651d7c=>_0x651d7c['name']==_0x58d961);_0x19af8d>-0x1&&_0x392e6c['splice'](_0x19af8d,0x1);}}function _0x2c6bb5(_0x582dc4){const _0x2d3da3=_0x582dc4['split'](':');return{'group':_0x2d3da3[0x0],'type':_0x2d3da3[0x1],'subType':_0x2d3da3['length']>=0x5?_0x2d3da3[0x2]:null,'id':_0x2d3da3['length']<0x5?_0x2d3da3[0x2]:_0x2d3da3[0x3],'authorId':_0x2d3da3['length']<0x5?_0x2d3da3[0x3]:_0x2d3da3[0x4],'markerCount':0x6==_0x2d3da3['length']?_0x2d3da3[0x5]:null};}function _0x4b666e(_0x369bd4){for(let _0x547cc7=0x0;_0x547cc7<_0x392e6c['length'];_0x547cc7++){if(_0x369bd4['isAdded']&&'insertion'==_0x392e6c[_0x547cc7]['type']&&_0x369bd4['isAdded']['userId']==_0x392e6c[_0x547cc7]['userId'])return _0x369bd4['isAddSuggestion']=_0x392e6c[_0x547cc7],void delete _0x369bd4['isAdded'];if(!_0x369bd4['isAdded']&&!_0x369bd4['isRemoved']&&'deletion'==_0x392e6c[_0x547cc7]['type'])return void(_0x369bd4['isRemoveSuggestion']=_0x392e6c[_0x547cc7]);}}}['_setDistance'](_0xb6f8c1,_0x2f7906){let _0x46f0a3=0x0,_0x2964f5=!0x1;const _0x2f8bd6=new Map();for(const _0x2993b4 of _0xb6f8c1)_0x2993b4[_0x2f7906]?_0x2964f5&&(_0x46f0a3++,_0x2964f5=!0x1):(_0x46f0a3++,_0x2964f5=!0x0),_0x2f8bd6['set'](_0x2993b4['id'],_0x46f0a3);for(let _0x5a05aa=0x0;_0x5a05aa<_0xb6f8c1['length'];_0x5a05aa++){if('isRemoved'==_0x2f7906&&_0xb6f8c1[_0x5a05aa]['isAdded']||'isAdded'==_0x2f7906&&_0xb6f8c1[_0x5a05aa]['isRemoved'])continue;if('text'==_0xb6f8c1[_0x5a05aa]['type']){_0xb6f8c1[_0x5a05aa]['distance']=0x0;continue;}const _0x1b6c86=_0x2f8bd6['get'](_0xb6f8c1[_0x5a05aa]['pairId']),_0x5a7b83=_0x2f8bd6['get'](_0xb6f8c1[_0x5a05aa]['id']);_0xb6f8c1[_0x5a05aa]['distance']=_0x1b6c86-_0x5a7b83;}}['_getRevisionsRange'](_0x2a36fb,_0x1d9db4,_0xec3ec6=!0x1){const _0x1f0e62=[];let _0x48eddb=this['repository']['getIndex'](_0x2a36fb),_0x469009=this['repository']['getIndex'](_0x1d9db4);for(-0x1==_0x469009&&(_0x469009=this['repository']['_revisions']['length'],_0xec3ec6=!0x1);_0x48eddb<_0x469009;)_0x1f0e62['push'](this['repository']['getRevision'](_0x48eddb)),_0x48eddb++;return _0xec3ec6&&_0x1f0e62['push'](this['repository']['getRevision'](_0x48eddb)),_0x1f0e62;}['_threeWayMerge'](_0x47bfac,_0x31bc79,_0x78b5db,_0x217218){const _0x57ad0e=this['editor']['model']['schema'];let _0x47713e=_0x31bc79;for(;_0x47bfac[_0x47713e]&&_0x47bfac[_0x47713e]['isAdded'];)_0x47713e++;let _0xb53815=_0x217218;for(;_0x78b5db[_0xb53815]&&_0x78b5db[_0xb53815]['isRemoved'];)_0xb53815++;_0x472484(_0x47bfac,_0x31bc79,_0x47713e),_0x472484(_0x78b5db,_0x217218,_0xb53815);const _0x10f143=_0x78b5db['slice'](_0x217218,_0xb53815)['concat'](_0x47bfac['slice'](_0x31bc79,_0x47713e));return _0x10f143['sort']((_0x330a3f,_0x4f4d97)=>_0x330a3f['side']!=_0x4f4d97['side']?_0x330a3f['side']-_0x4f4d97['side']:_0x330a3f['level']!=_0x4f4d97['level']?_0x330a3f['level']-_0x4f4d97['level']:_0x330a3f['distance']!=_0x4f4d97['distance']?_0x4f4d97['distance']-_0x330a3f['distance']:!!_0x330a3f['isAdded']!=!!_0x4f4d97['isAdded']?-0x1==_0x330a3f['side']||0x0==_0x330a3f['side']?_0x330a3f['isAdded']?-0x1:0x1:_0x330a3f['isAdded']?0x1:-0x1:_0x330a3f['index']-_0x4f4d97['index']),{'commonTape':_0x10f143,'iEnd':_0x47713e,'jEnd':_0xb53815};function _0x472484(_0x2e2abd,_0x5542c3,_0x3115f9){let _0x5d8c88=-0x1,_0x35fd6a=Number['POSITIVE_INFINITY'],_0x38f477=!0x0;for(let _0x54946d=_0x5542c3;_0x54946d<_0x3115f9;_0x54946d++)if(_0x57ad0e['isInline'](_0x2e2abd[_0x54946d]['item'])||(_0x38f477=!0x1),_0x2e2abd[_0x54946d]['item']['startIndex']<_0x5542c3&&(_0x5d8c88=_0x54946d),_0x2e2abd[_0x54946d]['item']['endIndex']>=_0x3115f9){_0x35fd6a=_0x54946d;break;}_0x38f477&&(_0x5d8c88=_0x3115f9-0x1);for(let _0x16683d=_0x5542c3;_0x16683d<_0x3115f9;_0x16683d++)_0x2e2abd[_0x16683d]['side']=_0x16683d<=_0x5d8c88?-0x1:_0x16683d<_0x35fd6a?0x0:0x1,_0x2e2abd[_0x16683d]['index']=_0x16683d;let _0x348a06=0x0;for(let _0x4d6a44=_0x5542c3;_0x4d6a44<=_0x5d8c88;_0x4d6a44++)0x0==_0x2e2abd[_0x4d6a44]['distance']?_0x2e2abd[_0x4d6a44]['level']=_0x348a06:(_0x348a06++,_0x2e2abd[_0x4d6a44]['level']=_0x348a06,_0x348a06++);for(let _0x5adfd5=_0x5542c3;_0x5adfd5<_0x3115f9;_0x5adfd5++)0x0==_0x2e2abd[_0x5adfd5]['side']&&(_0x2e2abd[_0x5adfd5]['level']=_0x348a06);_0x348a06=0x0;for(let _0x1a9d6b=_0x3115f9-0x1;_0x1a9d6b>=_0x35fd6a;_0x1a9d6b--)0x0==_0x2e2abd[_0x1a9d6b]['distance']?_0x2e2abd[_0x1a9d6b]['level']=_0x348a06:(_0x348a06--,_0x2e2abd[_0x1a9d6b]['level']=_0x348a06,_0x348a06--);}}['_fixObsoleteTags'](_0x540573){const _0x5cc938=new Map(),_0x15bb43=this['editor']['model']['schema'];for(let _0x5d2101=0x1;_0x5d2101<_0x540573['length'];_0x5d2101++){let _0x4a7499,_0xbd4f8d,_0x91c1ad;const _0x187300=_0x540573[_0x5d2101],_0x45e6a3=_0x540573[_0x5d2101-0x1];if('text'==_0x187300['type'])continue;if(_0x187300['type']!=_0x45e6a3['type'])continue;if(!_0x15bb43['isBlock'](_0x45e6a3['item'])||_0x15bb43['isLimit'](_0x45e6a3['item']))continue;if(!_0x15bb43['isBlock'](_0x187300['item'])||_0x15bb43['isLimit'](_0x187300['item']))continue;if((_0x540573[_0x5d2101]['isAdded']||_0x540573[_0x5d2101]['isAddSuggestion'])&&_0x540573[_0x5d2101-0x1]['isRemoved'])_0x4a7499=_0x540573[_0x5d2101],_0xbd4f8d=_0x540573[_0x5d2101-0x1],_0x91c1ad=_0x5d2101-0x1;else{if(!_0x540573[_0x5d2101]['isRemoved']||!_0x540573[_0x5d2101-0x1]['isAdded']&&!_0x540573[_0x5d2101-0x1]['isAddSuggestion'])continue;_0x4a7499=_0x540573[_0x5d2101-0x1],_0xbd4f8d=_0x540573[_0x5d2101],_0x91c1ad=_0x5d2101;}const _0x2f131e=_0x4a7499['level']==_0xbd4f8d['level'],_0x1f9a62=Math['abs'](_0x4a7499['level'])<Math['abs'](_0xbd4f8d['level'])&&0x0==_0xbd4f8d['distance'];(_0x2f131e||_0x1f9a62)&&(_0x5cc938['set'](_0xbd4f8d['id'],_0x4a7499['id']),_0x540573['splice'](_0x91c1ad,0x1),_0x5d2101--,_0x4a7499['isAdded']=!0x1);}for(let _0x1d14e4=0x0;_0x1d14e4<_0x540573['length'];_0x1d14e4++)_0x5cc938['has'](_0x540573[_0x1d14e4]['pairId'])&&(_0x540573[_0x1d14e4]['pairId']=_0x5cc938['get'](_0x540573[_0x1d14e4]['pairId']));}['_removeMissingPairs'](_0x56ce53){const _0x58f6d3=new Set(_0x56ce53['map'](_0x390ad3=>_0x390ad3['id']));for(let _0x3d4b66=0x0;_0x3d4b66<_0x56ce53['length'];_0x3d4b66++)_0x58f6d3['has'](_0x56ce53[_0x3d4b66]['pairId'])||0x0==_0x56ce53[_0x3d4b66]['distance']||(_0x56ce53[_0x3d4b66]['isIncorrect']=!0x0);return _0x56ce53['filter'](_0x2aca34=>!_0x2aca34['isIncorrect']);}['_markMismatchedRemovedTags'](_0x428885){const _0x221288=new Set();for(let _0x176ae8=0x0;_0x176ae8<_0x428885['length'];_0x176ae8++){if(_0x221288['has'](_0x428885[_0x176ae8]['id'])&&_0x428885[_0x176ae8]['isRemoved']&&(_0x428885[_0x176ae8]['isIncorrect']=!0x0),_0x428885[_0x176ae8]['isIncorrect'])continue;if(0x0==_0x428885[_0x176ae8]['distance'])continue;if('elementStart'!=_0x428885[_0x176ae8]['type'])continue;if(null==_0x428885[_0x176ae8]['pairId'])continue;let _0x38bd56=_0x176ae8+0x1,_0x20952a=0x0;for(;_0x428885[_0x38bd56]['id']!=_0x428885[_0x176ae8]['pairId'];)'elementStart'==_0x428885[_0x38bd56]['type']?_0x20952a++:'elementEnd'==_0x428885[_0x38bd56]['type']&&_0x20952a--,_0x38bd56++;if(0x0!=_0x20952a){if(_0x428885[_0x176ae8]['isRemoved'])_0x428885[_0x176ae8]['isIncorrect']=!0x0;else{for(;_0x38bd56!=_0x176ae8;)_0x428885[_0x38bd56]['isRemoved']&&0x0!=_0x428885[_0x38bd56]['distance']&&(_0x428885[_0x38bd56]['isIncorrect']=!0x0,_0x221288['add'](_0x428885[_0x38bd56]['pairId'])),_0x38bd56--;}}}return _0x428885['filter'](_0x773394=>!_0x773394['isIncorrect']);}['_removeUnsupportedChanges'](_0x46dd55){const _0xacb018=this['editor']['model']['schema'];for(let _0x75375=0x0;_0x75375<_0x46dd55['length'];_0x75375++){if(!(_0x46dd55[_0x75375]['isAdded']||_0x46dd55[_0x75375]['isAddSuggestion']||_0x46dd55[_0x75375]['isRemoved']||_0x46dd55[_0x75375]['isRemoveSuggestion']))continue;if(0x0==_0x46dd55[_0x75375]['distance'])continue;const _0x4c7a12=_0x46dd55[_0x75375]['item'];_0xacb018['isBlock'](_0x4c7a12)||_0xacb018['isLimit'](_0x4c7a12)||(_0x46dd55[_0x75375]['isAdded']&&delete _0x46dd55[_0x75375]['isAdded'],_0x46dd55[_0x75375]['isAddSuggestion']&&delete _0x46dd55[_0x75375]['isAddSuggestion'],_0x46dd55[_0x75375]['isRemoveSuggestion']&&delete _0x46dd55[_0x75375]['isRemoveSuggestion'],_0x46dd55[_0x75375]['isRemoved']&&(_0x46dd55[_0x75375]['isIncorrect']=!0x0));}return _0x46dd55['filter'](_0x4a0902=>!_0x4a0902['isIncorrect']);}['_makeModelFromTape'](_0x15c6fa,_0x262f5d,_0x4bbbcf){const _0x48c000=new _0x4c0b22(),_0x52ec83=[],_0x2245b=new Map(),_0x211f6b=this['editor']['model'],_0x478aff=_0x211f6b['schema'],_0x403f98=[_0x48c000],_0x141b75={},_0xe8216d={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0xea93f5=null;const _0x348ae1=[0x0];for(let _0x4ccc38=0x0;_0x4ccc38<_0x15c6fa['length'];_0x4ccc38++)if('elementStart'===_0x15c6fa[_0x4ccc38]['type']){_0x15c6fa[_0x4ccc38]['previousPosition']=_0x211f6b['createPositionFromPath'](_0x48c000,_0x348ae1);const _0x2eac7a=new _0x599036(_0x15c6fa[_0x4ccc38]['item']['name'],_0x15c6fa[_0x4ccc38]['item']['getAttributes']());_0x403f98[0x0]['_appendChild'](_0x2eac7a),_0x348ae1['push'](0x0),_0x403f98['unshift'](_0x2eac7a),_0x15c6fa[_0x4ccc38]['nextPosition']=_0x211f6b['createPositionFromPath'](_0x48c000,_0x348ae1);}else'elementEnd'===_0x15c6fa[_0x4ccc38]['type']?(_0x403f98['shift'](),_0x15c6fa[_0x4ccc38]['previousPosition']=_0x211f6b['createPositionFromPath'](_0x48c000,_0x348ae1),_0x348ae1['pop'](),_0x348ae1[_0x348ae1['length']-0x1]++,_0x15c6fa[_0x4ccc38]['nextPosition']=_0x211f6b['createPositionFromPath'](_0x48c000,_0x348ae1)):(_0x15c6fa[_0x4ccc38]['previousPosition']=_0x211f6b['createPositionFromPath'](_0x48c000,_0x348ae1),_0xea93f5?_0xea93f5['_data']+=_0x15c6fa[_0x4ccc38]['item']['data']:_0xea93f5=new _0x58fa86(_0x15c6fa[_0x4ccc38]['item']['data'],_0x15c6fa[_0x4ccc38]['item']['getAttributes']()),_0x15c6fa[_0x4ccc38+0x1]&&'text'===_0x15c6fa[_0x4ccc38+0x1]['type']&&_0x560fcd(_0xea93f5,_0x15c6fa[_0x4ccc38+0x1]['item'])||(_0x403f98[0x0]['_appendChild'](_0xea93f5),_0xea93f5=null),_0x348ae1[_0x348ae1['length']-0x1]+=_0x15c6fa[_0x4ccc38]['item']['offsetSize'],_0x15c6fa[_0x4ccc38]['nextPosition']=_0x211f6b['createPositionFromPath'](_0x48c000,_0x348ae1));for(let _0x967634=0x0;_0x967634<_0x15c6fa['length'];_0x967634++){const _0x50c235=_0x15c6fa[_0x967634]['previousPosition'],_0x13b544=_0x15c6fa[_0x967634]['nextPosition'];for(const _0x7f9a81 of _0x15c6fa[_0x967634]['markersStart'])_0x2245b['set'](_0x7f9a81,{'start':_0x50c235,'end':null});_0x64a5e8('isRemoveSuggestion',_0x967634,_0x50c235,_0x13b544),_0x64a5e8('isAddSuggestion',_0x967634,_0x50c235,_0x13b544),_0x64a5e8('isRemoved',_0x967634,_0x50c235,_0x13b544),_0x64a5e8('isAdded',_0x967634,_0x50c235,_0x13b544);for(const _0x14ff64 of _0x15c6fa[_0x967634]['markersEnd']){const _0x372d55=_0x2245b['get'](_0x14ff64);_0x372d55?_0x372d55['end']=_0x13b544:_0x2245b['set'](_0x14ff64,{'start':_0x13b544,'end':_0x13b544});}}for(const [_0x3486fb,_0x33c098]of _0x2245b){const _0x50db7e=this['editor']['model']['createRange'](_0x33c098['start'],_0x33c098['end']);_0x48c000['markers']['set'](_0x3486fb,_0x50db7e);}return _0x52ec83['sort']((_0x38308c,_0x9f4b7a)=>{const _0x305afe=_0x48c000['markers']['get']('revision:'+_0x38308c['id']),_0x2f1963=_0x48c000['markers']['get']('revision:'+_0x9f4b7a['id']);return _0x305afe['start']['isBefore'](_0x2f1963['start'])?-0x1:_0x305afe['start']['isAfter'](_0x2f1963['start'])?0x1:_0x305afe['end']['isBefore'](_0x2f1963['end'])?-0x1:_0x305afe['end']['isAfter'](_0x2f1963['end'])?0x1:'add'===_0x38308c['type']?-0x1:0x1;}),{'root':_0x48c000,'changes':_0x52ec83};function _0x64a5e8(_0x1a1d73,_0x176e47,_0x37bcc0,_0x46b961){const _0x43756d=!!_0x15c6fa[_0x176e47][_0x1a1d73],_0x2e9792=_0x43756d?_0x15c6fa[_0x176e47][_0x1a1d73]['userId']:null,_0x58e7ac=_0x176e47===_0x15c6fa['length']-0x1,_0x349718=_0xe8216d[_0x1a1d73][0x0],_0x2566c9=_0x478aff['isObject'](_0x15c6fa[_0x176e47]['item']);!_0x141b75[_0x1a1d73]&&_0x43756d?_0x141b75[_0x1a1d73]={'start':_0x37bcc0,'tapeItem':_0x15c6fa[_0x176e47],'userId':_0x2e9792,'type':_0x1a1d73}:_0x141b75[_0x1a1d73]&&!_0x43756d?(_0x141b75[_0x1a1d73]['end']=_0x37bcc0,_0x578dfe(_0x141b75[_0x1a1d73]),_0x141b75[_0x1a1d73]=null):_0x141b75[_0x1a1d73]&&_0x43756d&&_0x141b75[_0x1a1d73]['userId']!==_0x2e9792&&(_0x141b75[_0x1a1d73]['end']=_0x37bcc0,_0x349718&&_0x349718['userId']===_0x141b75[_0x1a1d73]['userId']||_0x578dfe(_0x141b75[_0x1a1d73]),_0x141b75[_0x1a1d73]={'start':_0x37bcc0,'tapeItem':_0x15c6fa[_0x176e47],'userId':_0x2e9792,'type':_0x1a1d73}),_0x141b75[_0x1a1d73]&&_0x2566c9&&('elementStart'!==_0x15c6fa[_0x176e47]['type']||_0x349718&&_0x349718['userId']===_0x2e9792||_0xe8216d[_0x1a1d73]['unshift']({'userId':_0x2e9792,'object':_0x15c6fa[_0x176e47]['item'],'change':_0x141b75[_0x1a1d73]}),'elementEnd'===_0x15c6fa[_0x176e47]['type']&&_0x349718&&_0x349718['object']===_0x15c6fa[_0x176e47]['item']&&(_0xe8216d[_0x1a1d73]['shift'](),_0x141b75[_0x1a1d73]=_0x349718['change'])),_0x141b75[_0x1a1d73]&&_0x58e7ac&&(_0x141b75[_0x1a1d73]['end']=_0x46b961,_0x578dfe(_0x141b75[_0x1a1d73]),_0x141b75[_0x1a1d73]=null);}function _0x578dfe({start:_0x389103,end:_0x57248f,tapeItem:_0x1f5b14,userId:_0x3a0d39,type:_0xddaa82}){const _0x4d5997=_0x1f5b14['item'],_0x4968f5=_0x211f6b['schema']['isBlock'](_0x4d5997)&&!_0x211f6b['schema']['isLimit'](_0x4d5997),_0x7c4e91=_0x389103['nodeAfter']==_0x57248f['parent']&&_0x57248f['isAtStart'];if(_0x4968f5&&_0x7c4e91)return;const _0x558318=_0x211f6b['createRange'](_0x389103,_0x57248f),_0x551eb2=_0x262f5d['get'](_0x3a0d39),_0x1fb665=new G({'author':_0x551eb2,'type':'isAdded'==_0xddaa82||'isAddSuggestion'==_0xddaa82?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0xddaa82||'isRemoveSuggestion'==_0xddaa82},'createdAt':new Date(),'rootName':_0x4bbbcf});_0x52ec83['push'](_0x1fb665),_0x48c000['markers']['set']('revision:'+_0x1fb665['id'],_0x558318);}function _0x560fcd(_0x29f71f,_0x4bc5f5){const _0x558ab2=_0x29f71f['getAttributes'](),_0xde863a=_0x4bc5f5['getAttributes']();for(const _0x3a4024 of _0x558ab2){if(_0x3a4024[0x1]!==_0x4bc5f5['getAttribute'](_0x3a4024[0x0]))return!0x1;_0xde863a['next']();}return _0xde863a['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x3aad6c=>{const _0x44792e=_0x3aad6c['markerName']['split'](':')[0x1],_0x4566a5=this['_getChangeFromId'](_0x44792e);if(!_0x4566a5)return null;const _0x22c2c7='add'==_0x4566a5['type']?'insertion':'deletion',_0xb0f43=['ck-suggestion-marker','ck-suggestion-marker-'+_0x22c2c7];return _0x4566a5['data']['isSuggestion']&&_0xb0f43['push']('ck-suggestion-marker-'+_0x22c2c7+'-new'),this['activeChange']==_0x4566a5&&_0xb0f43['push']('ck-suggestion-marker--active'),{'classes':_0xb0f43,'attributes':{'data-change-id':_0x44792e}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x19ef19=>{_0x19ef19['on']('element:pre',(_0x5afeff,_0x4a9665,_0x59f8ac)=>{const _0x29739a=_0x4a9665['viewItem']['getChild'](0x0);if(!_0x29739a||!_0x29739a['is']('element','code'))return;if(!_0x59f8ac['consumable']['consume'](_0x29739a,{'attributes':['vid_start','vid_end']}))return;const _0x37c3c6=_0x4a9665['modelRange']['start']['nodeAfter'];_0x59f8ac['writer']['setAttribute']('vid_start',_0x29739a['getAttribute']('vid_start'),_0x37c3c6),_0x59f8ac['writer']['setAttribute']('vid_end',_0x29739a['getAttribute']('vid_end'),_0x37c3c6);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x538d46=>{_0x538d46['on']('element',(_0xf57270,_0x1e4b30,_0x33a850)=>{if(!_0x33a850['consumable']['consume'](_0x1e4b30['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x1e4b30['modelRange']['isCollapsed'])return;const _0x3d99c0=_0x1e4b30['modelRange']['start']['nodeAfter'];_0x3d99c0['hasAttribute']('vid_start')||_0x3d99c0['hasAttribute']('vid')||(_0x33a850['writer']['setAttribute']('vid_start',_0x1e4b30['viewItem']['getAttribute']('vid_start'),_0x3d99c0),_0x33a850['writer']['setAttribute']('vid_end',_0x1e4b30['viewItem']['getAttribute']('vid_end'),_0x3d99c0));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x2ea981=>_0x2ea981['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x49643c,[,_0x5077fe])=>{['vid_start','vid_end','vid']['includes'](_0x5077fe)&&(_0x49643c['return']=!0x0,_0x49643c['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x406c84=>{_0x406c84['on']('attribute:vid',(_0x4e3f32,_0x3787e2,_0x46bc12)=>{if('\x20'!=_0x3787e2['item']['data']||_0x3787e2['item']['parent']['maxOffset']>0x1)return;if(!_0x46bc12['consumable']['consume'](_0x3787e2['item'],_0x4e3f32['name']))return;const _0x12a6ae=_0x46bc12['writer'],_0x4b484a=_0x46bc12['mapper']['toViewRange'](_0x3787e2['range']);_0x12a6ae['wrap'](_0x4b484a,_0x12a6ae['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x19c766){const _0x4c6722=_0x19c766['plugins']['get']('RevisionViewer');return(_0x15eeb8,_0x42ad2c,_0x5f3558)=>{const _0x3b6a6e=_0x42ad2c['markerName']['split'](':')[0x1],_0x18561b=_0x4c6722['_getChangeFromId'](_0x3b6a6e);if(!_0x18561b)return null;const _0x203f07='add'==_0x18561b['type']?'split':'merge';if(!_0x5f3558['consumable']['test'](_0x42ad2c['markerRange'],_0x15eeb8['name']))return;const _0x29413b=_0x42ad2c['markerRange']['getWalker'](),_0x192b06=_0x42ad2c['markerRange']['start'],_0x4c5c80=_0x19c766['model']['schema'];let _0x4f86d3=null,_0x31fa9e=null,_0x2b2810=!0x1,_0x3fcc7e=!0x1;for(const _0x5e02a6 of _0x29413b){const _0x235536=_0x5e02a6['item'];_0x2b2810=_0x2b2810||_0x4c5c80['isContent'](_0x235536);const _0x2f2951=_0x5f3558['mapper']['toViewElement'](_0x235536);if(_0x2f2951&&_0x2f2951['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x5e02a6['type']&&(_0x4c5c80['isBlock'](_0x235536)&&!_0x4c5c80['isLimit'](_0x235536)&&(_0x235536['nextSibling']||_0x192b06['isAtEnd']?_0x4f86d3&&_0x4f86d3['parent']==_0x235536||(_0x4f86d3=_0x235536,_0x5a7744(_0x5e02a6['previousPosition']),_0x3fcc7e=!0x0):_0x31fa9e=_0x31fa9e||_0x5e02a6['previousPosition']));}function _0x5a7744(_0x2d6442){const _0x158b63=_0x5f3558['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x203f07}),_0x3a0c3=_0x5f3558['mapper']['toViewPosition'](_0x2d6442);_0x18561b['data']['isSuggestion']&&_0x5f3558['writer']['addClass']('ck-suggestion-marker-'+_0x203f07+'-new',_0x158b63),_0x4c6722['activeChange']==_0x18561b&&_0x5f3558['writer']['addClass']('ck-suggestion-marker--active',_0x158b63),_0x5f3558['writer']['insert'](_0x3a0c3,_0x158b63),_0x5f3558['mapper']['bindElementToMarker'](_0x158b63,_0x42ad2c['markerName']);}_0x2b2810||_0x3fcc7e||!_0x31fa9e||_0x5a7744(_0x31fa9e);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x402b49,_0x4c00e0,_0x3276ce)=>{const _0x31a9e4=_0x3276ce['mapper']['markerNameToElements'](_0x4c00e0['markerName']);if(_0x31a9e4){for(const _0x4d66c4 of _0x31a9e4)(_0x4d66c4['hasClass']('ck-suggestion-marker-split')||_0x4d66c4['hasClass']('ck-suggestion-marker-merge'))&&(_0x3276ce['mapper']['unbindElementFromMarkerName'](_0x4d66c4,_0x4c00e0['markerName']),_0x3276ce['writer']['remove'](_0x4d66c4));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x462b2b,_0x5722c8,_0x1d1569)=>{const _0x2bd6aa=_0x5722c8['markerName']['split'](':')[0x1],_0x3d75a7=this['_getChangeFromId'](_0x2bd6aa);if(!_0x3d75a7)return null;const _0x4542ed='add'==_0x3d75a7['type']?'split':'merge';if(_0x1d1569['consumable']['test'](_0x5722c8['markerRange'],_0x462b2b['name']))for(const _0x6d56b9 of _0x5722c8['markerRange']['getItems']()){if(!_0x6d56b9['is']('element','softBreak'))continue;const _0x4ffc93=_0x1d1569['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x4542ed}),_0x3fc8d2=_0x1d1569['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x6d56b9));_0x3d75a7['data']['isSuggestion']&&_0x1d1569['writer']['addClass']('ck-suggestion-marker-'+_0x4542ed+'-new',_0x4ffc93),this['activeChange']==_0x3d75a7&&_0x1d1569['writer']['addClass']('ck-suggestion-marker--active',_0x4ffc93),_0x1d1569['writer']['insert'](_0x3fc8d2,_0x4ffc93),_0x1d1569['mapper']['bindElementToMarker'](_0x4ffc93,_0x5722c8['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x2b62b2=>{for(const _0x53de38 of this['editor']['model']['document']['getRootNames']()){const _0x431f2c=this['editor']['model']['document']['getRoot'](_0x53de38),_0x3f7c1d=this['editor']['editing']['view']['document']['getRoot'](_0x53de38);if(_0x3f7c1d){const _0x1d903e=_0x431f2c['getAttribute']('revisionHistoryAttachChange');if(_0x2b62b2['removeAttribute']('data-change-id',_0x3f7c1d),_0x2b62b2['removeClass']('ck-revision-history-root-add',_0x3f7c1d),_0x2b62b2['removeClass']('ck-revision-history-root-remove',_0x3f7c1d),_0x2b62b2['removeClass']('ck-revision-history-root--active',_0x3f7c1d),_0x1d903e){const _0xbf5283=this['_getChangeFromId'](_0x1d903e);if(!_0xbf5283)return null;_0x2b62b2['setAttribute']('data-change-id',_0x1d903e,_0x3f7c1d),_0x2b62b2['addClass']('ck-revision-history-root-'+_0xbf5283['type'],_0x3f7c1d),this['activeChange']==_0xbf5283&&_0x2b62b2['addClass']('ck-revision-history-root--active',_0x3f7c1d);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x5db1cd=>'revision-comment:'+_0x5db1cd,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x1605d7=>'revision-suggestion:'+_0x1605d7,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x1d5920=>({'name':'suggestion:'+_0x1d5920,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x30654b=>{const _0xedca6e=_0x30654b['markerName']['split'](':')[0x1];return'insertion'!=_0xedca6e&&'deletion'!=_0xedca6e?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0xedca6e]};}}),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',(_0x58e123,_0x60dc2a,_0x1d1715)=>{const _0x57b6bc=_0x1d1715['mapper']['markerNameToElements'](_0x60dc2a['markerName']);if(_0x57b6bc){for(const _0x54ce6f of _0x57b6bc)_0x54ce6f['is']('uiElement')&&(_0x1d1715['mapper']['unbindElementFromMarkerName'](_0x54ce6f,_0x60dc2a['markerName']),_0x1d1715['writer']['remove'](_0x54ce6f));}},{'priority':'high'});}['_getChangeFromId'](_0x130a2a){return this['_changeIdToChange']['get'](_0x130a2a);}['_getViewForChange'](_0x3944a4){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new z(this['editor']['locale'],_0x3944a4),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x3971f,_0x157612,_0x34fc54,_0x2fcb79)=>{_0x2fcb79&&this['_balloon']['remove'](_0x2fcb79),_0x34fc54&&(this['_balloon']['add']({'view':_0x34fc54,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x5ae55c=this['editor']['editing'],_0x10bebb=this['_getChangeFromId'](_0x34fc54['changeId']);let _0x3c58c6;if(_0x10bebb['data']['isOnRoot']){const _0x4e3468=_0x5ae55c['view']['getDomRoot'](_0x10bebb['rootName']);_0x3c58c6=Array['from'](_0x4e3468['getClientRects']());}else{const _0x5d6c62=this['editor']['model']['markers']['get']('revision:'+_0x34fc54['changeId']);_0x3c58c6=Array['from'](_0x5ae55c['mapper']['markerNameToElements'](_0x5d6c62['name']))['map'](_0x4a2395=>_0x5ae55c['view']['domConverter']['mapViewToDom'](_0x4a2395))['map'](_0x463511=>Array['from'](_0x463511['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x3c58c6[0x0];return _0x3c58c6['find'](_0xe11ebc=>_0xe11ebc['top']-0x3<=this['_activeViewTarget']['y']&&_0xe11ebc['bottom']+0x3>=this['_activeViewTarget']['y']&&_0xe11ebc['left']-0x3<=this['_activeViewTarget']['x']&&_0xe11ebc['right']+0x3>=this['_activeViewTarget']['x'])||_0x3c58c6[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x5a86c0,_0x1b6f1c,_0x3e5195,_0x2f8588)=>{this['activeView']=_0x3e5195?this['_getViewForChange'](_0x3e5195):null,this['editor']['model']['change'](()=>{const _0x5b8404=this['editor']['editing'];_0x2f8588&&(_0x2f8588['data']['isOnRoot']?_0x5b8404['view']['change'](_0x173385=>{_0x173385['removeClass']('ck-revision-history-root--active',_0x5b8404['view']['document']['getRoot'](_0x2f8588['rootName']));}):_0x5b8404['reconvertMarker']('revision:'+_0x2f8588['id'])),_0x3e5195&&(_0x3e5195['data']['isOnRoot']?_0x5b8404['view']['change'](_0x3451af=>{_0x3451af['addClass']('ck-revision-history-root--active',_0x5b8404['view']['document']['getRoot'](_0x3e5195['rootName']));}):_0x5b8404['reconvertMarker']('revision:'+_0x3e5195['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x1c973c,_0x245b37)=>{if(this['activeChange'])return;const _0x497117=this['_findChangeIdFromDomTarget'](_0x245b37['target']),_0x226a7c=this['_changeIdToChange']['get'](_0x497117);_0x226a7c?(this['_activeViewTarget']={'x':_0x245b37['domEvent']['x'],'y':_0x245b37['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x226a7c)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x23ab91,_0x2f65a8)=>{const _0x1fb323=this['_findChangeIdFromDomTarget'](_0x2f65a8['target']),_0x8ee044=this['_changeIdToChange']['get'](_0x1fb323);_0x8ee044?(this['_activeViewTarget']={'x':_0x2f65a8['domEvent']['x'],'y':_0x2f65a8['domEvent']['y']},_0x8ee044===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x8ee044):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x525ac3){do{const _0x3ad18b=_0x525ac3['getAttribute']('data-change-id');if(_0x3ad18b)return _0x3ad18b;_0x525ac3=_0x525ac3['parent'];}while(_0x525ac3);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0xcdc972=>{for(const _0xcc4ecc of this['editor']['model']['markers'])_0xcdc972['removeMarker'](_0xcc4ecc);});}}function Q(_0x4eb63e,_0x4b78cd){return(_0x2244df,_0x3b4b0b,_0x1b4628)=>{if(!_0x1b4628['consumable']['test'](_0x3b4b0b['markerRange'],_0x2244df['name']))return;const _0xd9c8d=_0x3b4b0b['markerRange']['getWalker'](),_0x3e1e1a=_0x3b4b0b['markerRange']['start'],_0x4b9ba6=_0x4eb63e['model']['schema'];let _0x49e890=null,_0x577ef8=null,_0x3ff171=!0x1,_0x48573a=!0x1;for(const _0x1fae28 of _0xd9c8d){const _0xe5df83=_0x1fae28['item'];_0x3ff171=_0x3ff171||_0x4b9ba6['isContent'](_0xe5df83);const _0x503c77=_0x1b4628['mapper']['toViewElement'](_0xe5df83);if(_0x503c77&&_0x503c77['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x1fae28['type']&&(_0x4b9ba6['isBlock'](_0xe5df83)&&!_0x4b9ba6['isLimit'](_0xe5df83)&&(_0xe5df83['nextSibling']||_0x3e1e1a['isAtEnd']?_0x49e890&&_0x49e890['parent']==_0xe5df83||(_0x49e890=_0xe5df83,_0x13c56a(_0x1fae28['previousPosition']),_0x48573a=!0x0):_0x577ef8=_0x577ef8||_0x1fae28['previousPosition']));}function _0x13c56a(_0x45023c){const _0x4fb371=_0x1b4628['mapper']['toViewPosition'](_0x45023c),_0x2eb410=_0x1b4628['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x4b78cd});_0x1b4628['writer']['insert'](_0x4fb371,_0x2eb410),_0x1b4628['mapper']['bindElementToMarker'](_0x2eb410,_0x3b4b0b['markerName']);}_0x3ff171||_0x48573a||!_0x577ef8||_0x13c56a(_0x577ef8);};}class nt extends _0x58b01{constructor(_0x187234){super(_0x187234);const _0x276114=_0x187234['plugins']['get'](l);this['affectsData']=!0x1,this['listenTo'](_0x276114,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x276114,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x4f9306=this['editor'],_0x39de81=_0x4f9306['plugins']['get'](l),_0xba8080=_0x39de81['isReady']?_0x39de81['diff']['newRevisionId']:null;_0x4f9306['config']['get']('revisionHistory')['restoreRevisionCallback'](_0xba8080);}['refresh'](){const {isReady:_0x5d7f4e,isEnabled:_0x199b9c,repository:_0x5f138f,diff:_0x35caa2}=this['editor']['plugins']['get'](l),_0xf2ab40=_0x35caa2&&_0x5f138f['getLaterVisibleRevision'](_0x35caa2['newRevisionId']);this['isEnabled']=_0x5d7f4e&&_0x199b9c&&Boolean(_0xf2ab40);}}class ot extends _0x58b01{['_step'];constructor(_0x572a6c,{direction:_0x49779b}){super(_0x572a6c);const _0x1bcc2e=_0x572a6c['plugins']['get'](l);this['affectsData']=!0x1,this['_step']='forward'===_0x49779b?0x1:-0x1,this['listenTo'](_0x1bcc2e,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x1bcc2e,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x1bcc2e,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x74b34=this['editor'],_0x51da7d=_0x74b34['plugins']['get'](l),{isNavigationMode:_0x509906,currentChangeNumber:_0x4efc5d}=_0x51da7d;let _0x5e2b69;if(_0x51da7d['activeChange']=_0x509906?_0x51da7d['diff']['changes']['get'](_0x4efc5d+this['_step']):_0x51da7d['diff']['changes']['first'],_0x51da7d['activeChange']['data']['isOnRoot'])_0x5e2b69=_0x74b34['editing']['view']['getDomRoot'](_0x51da7d['activeChange']['rootName']);else{const _0x5e97cf=_0x74b34['model']['markers']['get']('revision:'+_0x51da7d['activeChange']['id']);_0x5e2b69=_0x11cd7f(_0x74b34['editing'],_0x5e97cf);}_0x1ccc11({'target':_0x5e2b69,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x6b97b6,currentChangeNumber:_0xf2822b,numberOfChanges:_0x36a047,isReady:_0x439e12,isEnabled:_0x3fc227}=this['editor']['plugins']['get'](l);this['isEnabled']=!!(_0x3fc227&&_0x439e12&&_0x36a047)&&(!_0x6b97b6||(0x1===this['_step']?_0xf2822b<_0x36a047-0x1:_0xf2822b>0x0));}}class Ri extends _0x289a06{constructor(_0x127708){super(_0x127708);const _0x14916a=this['bindTemplate'],_0x2d3dc6=new _0x42cd9a(_0x127708),_0x5dd581=new _0x42cd9a(_0x127708);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',(_0x552670,_0x1055a5)=>_0x552670&&_0x1055a5>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x187890,_0xa16871,_0x162110,_0x527c0a)=>{if(!_0x187890)return R(_0x127708,'Loading...');if(!_0x162110)return R(_0x127708,'No\x20changes');const _0x124aa8=R(_0x127708,'NUMBER_OF_CHANGES',_0x162110);return _0x527c0a?R(_0x127708,'X_OF_Y_CHANGES',[_0xa16871+0x1,_0x162110]):_0x124aa8;}),_0x2d3dc6['set']({'label':R(_0x127708,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0xe92cb0}),_0x5dd581['set']({'label':R(_0x127708,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x57ae56}),_0x2d3dc6['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x5dd581['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x2d3dc6['on']('execute',()=>this['fire']('execute','backward')),_0x5dd581['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',_0x14916a['if']('_isStatusLabelVisible','ck-hidden',_0x40a67f=>!_0x40a67f)]},'children':[{'text':_0x14916a['to']('isNavigationMode',_0x14dc5c=>_0x14dc5c?R(_0x127708,'EDIT_X_OF_Y_REVISIONS')+':\x20':R(_0x127708,'Total')+':\x20')}]},{'text':_0x14916a['to']('_statusText')}]},new _0x1c6dd3(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x2d3dc6,_0x5dd581]}]});}}const ge='ck-editor__editable__loading-overlay';class ji extends _0x557a5e{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x341508=this['editor']['editing']['view'];_0x341508['change'](_0x1e4497=>{for(const _0x3f62fd of _0x341508['document']['roots'])_0x1e4497['addClass'](ge,_0x3f62fd);});}['hide'](){const _0x540d74=this['editor']['editing']['view'];_0x540d74['change'](_0x12a80b=>{for(const _0x3a68b2 of _0x540d74['document']['roots'])_0x12a80b['removeClass'](ge,_0x3a68b2);});}}class u extends _0x557a5e{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l,ji];}['init'](){const _0x2f8d47=this['editor'],_0x26d2d3=_0x2f8d47['plugins']['get'](l),_0x198241=_0x2f8d47['plugins']['get'](ji);_0x2f8d47['ui']['componentFactory']['add']('exitToEditing',_0x25bee6=>{const _0xf1225d=new _0x42cd9a(_0x25bee6);return _0xf1225d['set']({'label':R(_0x25bee6,'Back\x20to\x20editing'),'icon':_0x3a38c,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0xf1225d,'execute',()=>{_0x2f8d47['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0xf1225d;}),_0x2f8d47['ui']['componentFactory']['add']('restoreRevision',_0x3c8ac3=>{const _0x52714d=new _0x42cd9a(_0x3c8ac3);return _0x52714d['set']({'label':R(_0x3c8ac3,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x52714d['bind']('isEnabled')['to'](_0x2f8d47['commands']['get']('restoreRevision')),this['listenTo'](_0x52714d,'execute',()=>_0x2f8d47['execute']('restoreRevision')),_0x52714d;}),_0x2f8d47['ui']['componentFactory']['add']('changesNavigation',_0x7968f0=>{const _0x516892=new Ri(_0x7968f0),_0x307b43=_0x2f8d47['commands']['get']('showPreviousChange'),_0x36ed94=_0x2f8d47['commands']['get']('showNextChange');return _0x516892['bind']('isBackwardNavigationEnabled')['to'](_0x307b43,'isEnabled'),_0x516892['bind']('isForwardNavigationEnabled')['to'](_0x36ed94,'isEnabled'),_0x516892['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x26d2d3),this['listenTo'](_0x516892,'execute',(_0x562e29,_0xa0782d)=>{_0x2f8d47['execute']('forward'===_0xa0782d?'showNextChange':'showPreviousChange');}),_0x516892;}),_0x198241['show'](),_0x26d2d3['on']('change:isReady',(_0xad57f4,_0x4e6e49,_0x4d7943)=>{_0x4d7943?_0x198241['hide']():_0x198241['show']();});}}class li extends ti{['_resizeObserver']=null;constructor(_0x58a5f5,_0x422221){super(_0x58a5f5,_0x422221);const _0xfeec2c=this['bindTemplate'];this['set']({'label':R(_0x58a5f5,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=R(_0x58a5f5,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0xfeec2c['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 _0x54aa1e=this['fieldView']['element'];this['_tooltipString']=_0x54aa1e['scrollWidth']>_0x54aa1e['clientWidth']&&_0x54aa1e['value']||'';}}class vi extends _0x289a06{constructor(_0x44a96f,_0x4aaa40,_0x283ee4){super(_0x44a96f);const _0x862aec=new _0x26bf56();_0x862aec['set']({'content':_0x1309a4,'viewBox':'0\x200\x2011\x2010'});const _0x1bb0d2=['ck','ck-revision-history-sidebar__revision-author'];_0x283ee4&&_0x1bb0d2['push']('ck-revision-history-sidebar__revision-author_creator');const _0x4395d3=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':R(_0x44a96f,_0x283ee4?'Revision\x20creator':'Revision\x20author')},'children':[_0x862aec,_0x4aaa40['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x1bb0d2},'children':_0x4395d3});}}function mi(_0x131e6e,_0x1999e6){const _0x2db48e=_0x131e6e['bindTemplate'],_0x5b88b8=_0x131e6e['locale'],_0x188e0d=_0x10ddda(_0x5b88b8);_0x188e0d['panelPosition']='sw';const _0x1db743=function(_0x5eb087,_0x6164f1){const _0x1ce5e4=function(_0x4d1e68,_0x18639c){const _0x3b81a0=_0x4d1e68['locale'],_0x1c6149={'Compare\x20against\x20selected':R(_0x3b81a0,'Compare\x20against\x20selected'),'Name\x20this\x20revision':R(_0x3b81a0,'Name\x20this\x20revision'),'Restore\x20this\x20revision':R(_0x3b81a0,'Restore\x20this\x20revision')};return _0x18639c['map'](_0x388d5c=>{const _0x5911a8=_0x1c6149[_0x388d5c['name']];return _0x5911a8&&_0x5911a8!==_0x388d5c['name']&&(_0x388d5c['name']=_0x5911a8),_0x388d5c;});}(_0x5eb087,_0x6164f1),_0x57a569=new _0x50c032();for(const _0x3ee4b9 of _0x1ce5e4){const _0x1e2b72={'type':'button','model':new to({'label':_0x3ee4b9['name'],'class':_0x3ee4b9['class'],'withText':!0x0,'role':'menuitem','_action':_0x3ee4b9['action']})};_0x1e2b72['model']['bind']('isEnabled')['to'](_0x5eb087,'isActionsDropdownOpen',_0x1cb45a=>'function'!=typeof _0x3ee4b9['isEnabled']||(!_0x1cb45a||_0x3ee4b9['isEnabled'](_0x5eb087))),_0x57a569['add'](_0x1e2b72);}return _0x57a569;}(_0x131e6e,_0x1999e6);return _0x131e6e['bind']('isActionsDropdownOpen')['to'](_0x188e0d,'isOpen'),_0x188e0d['buttonView']['set']({'label':R(_0x5b88b8,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x46a20b}),_0x188e0d['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x2db48e['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x2db48e['to'](_0xc41a4e=>_0xc41a4e['stopPropagation']())}}),_0x188e0d['on']('execute',_0x3e85bd=>{_0x131e6e['isReady']&&'function'==typeof _0x3e85bd['source']['_action']&&_0x3e85bd['source']['_action'](_0x131e6e);}),_0x160d68(_0x188e0d,_0x1db743,{'role':'menu'}),_0x188e0d['listenTo'](_0x131e6e,'change:isActionsDropdownOpen',(_0x44f1e9,_0xc89fa,_0xa80979)=>{if(_0xa80979)for(const _0x518753 of _0x188e0d['listView']['items']){const _0x11e8a8=_0x518753['children']['first'],_0x4fae32=_0x1999e6['find'](_0x5acd09=>_0x5acd09['action']===_0x11e8a8['_action'])['isVisible'];_0x518753['isVisible']=void 0x0===_0x4fae32||_0x4fae32(_0x131e6e);}}),_0x188e0d;}class pi extends/* #__PURE__ -- @preserve */
27
+ _0x1f6116(_0x289a06){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x59a096,_0x1fad2f,_0x11e989,_0x733f0b){super(_0x59a096);const _0xb27bf=this['bindTemplate'],_0x5b7599=function(_0x3ceab8,_0x1d61c2){const _0x5baf5c=Array['from'](_0x1d61c2['authors'])['filter'](_0x5ef123=>_0x5ef123!=_0x1d61c2['creator']);return _0x1d61c2['creator']&&_0x5baf5c['unshift'](_0x1d61c2['creator']),_0x5baf5c['map'](_0x37850a=>new vi(_0x3ceab8,_0x37850a,_0x37850a==_0x1d61c2['creator']));}(_0x59a096,_0x1fad2f);this['id']=_0x1fad2f['id'],this['_revision']=_0x1fad2f,this['_requireRevisionName']=_0x733f0b,this['bind']('name','createdAt')['to'](_0x1fad2f),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x4c6381=>{return _0x4ec591=_0x59a096['uiLanguage'],(_0x1931de=_0x4c6381)['toLocaleDateString'](_0x4ec591,{'month':'long','day':'numeric'})+',\x20'+_0x1931de['toLocaleTimeString'](_0x4ec591,{'hour':'numeric','minute':'numeric'});var _0x4ec591,_0x1931de;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new li(_0x59a096,_0x104191),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x3ad397=>_0x3ad397||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x159daa,_0x3f8209)=>_0x159daa&&_0x3f8209),this['revisionActionsView']=_0x11e989&&_0x11e989['length']?mi(this,_0x11e989):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0xb27bf['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0xb27bf['if']('isEnabled','ck-disabled',_0x15fe59=>!_0x15fe59),_0xb27bf['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0xb27bf['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0xb27bf['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':_0xb27bf['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':_0x5b7599}]},this['revisionActionsView']],'on':{'click':_0xb27bf['to'](_0x188075=>{_0x188075['srcElement']['closest']('.ck-thread__remove-confirm')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x5bf334=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x5bf334,'change',()=>{this['_requireRevisionName']&&!_0x5bf334['value']||this['fire']('setName',{'id':this['id'],'name':_0x5bf334['value']}),_0x5bf334['value']||(_0x5bf334['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(_0x27abb9,_0x1a76a2){const _0x239cae=_0x2b72ee['fromJSDate'](_0x27abb9)['setLocale'](_0x1a76a2),_0x685856=_0x2b72ee['local'](),_0x3443f1=_0x685856['minus']({'days':0x1})['startOf']('day');let _0x492ac5,_0x2699da;return _0x239cae['hasSame'](_0x685856,'day')?(_0x492ac5=_0x239cae['startOf']('day')['toJSDate'](),_0x2699da=_0x239cae['toRelativeCalendar']()):_0x239cae['hasSame'](_0x3443f1,'day')?(_0x492ac5=_0x3443f1['toJSDate'](),_0x2699da=_0x239cae['toRelativeCalendar']()):_0x239cae['hasSame'](_0x685856,'week')?(_0x492ac5=_0x239cae['startOf']('week')['toJSDate'](),_0x2699da=_0x239cae['weekdayLong']||''):_0x239cae['hasSame'](_0x685856,'year')?(_0x492ac5=_0x239cae['startOf']('month')['toJSDate'](),_0x2699da=_0x239cae['monthLong']||''):(_0x492ac5=_0x239cae['startOf']('year')['toJSDate'](),_0x2699da=String(_0x239cae['year'])),{'startDate':_0x492ac5,'localizedPeriodName':_0x2699da};}class fi extends _0x289a06{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0xf52830,_0xcd99c0,_0x5703fb,_0x33b7c9){super(_0xf52830);const _0x51e314=bi(_0xcd99c0,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0xcd99c0,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x5703fb,this['_requireRevisionName']=_0x33b7c9,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':_0x51e314}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x539da6){const _0x414315=new pi(this['locale'],_0x539da6,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x414315);}['removeRevision'](_0x5a46e5){const _0x1dbfea=this['revisionViews']['find'](_0x36d2f4=>_0x36d2f4['id']===_0x5a46e5['id']);this['revisionViews']['remove'](_0x1dbfea);}}class ki extends _0x289a06{constructor(_0x5e45d0){super(_0x5e45d0);const _0x1da1fc=new _0x26bf56();_0x1da1fc['content']=_0x205745,this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x1da1fc,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[R(_0x5e45d0,'Revision\x20history')]}]});}}class ui extends _0x289a06{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x13d7e9,_0x51c6a4,_0x3477e3,_0x3243c5){super(_0x13d7e9);const _0x394640=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x51c6a4,this['_revisionActions']=_0x3477e3,this['_requireRevisionName']=_0x3243c5,this['on']('select',(_0x51c0ce,_0x3ba8d7)=>{this['fire']('revisionSelected',_0x3ba8d7);}),this['on']('setName',(_0x37fa67,_0x12368e)=>{this['fire']('revisionSetName',_0x12368e);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new ki(_0x13d7e9),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x394640['if']('isEnabled','ck-disabled',_0x5539eb=>!_0x5539eb)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x4fa123 of this['_revisions'])this['_addRevision'](_0x4fa123);this['_revisions']['on']('add',(_0x16b15e,_0x1b531b)=>{this['_addRevision'](_0x1b531b);}),this['_revisions']['on']('remove',(_0x27a611,_0x2fede1)=>{this['_removeRevision'](_0x2fede1);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x19f686=>_0x19f686['revisionViews']['map'](_0x42d879=>_0x42d879))['flat']();}['selectRevision'](_0x1bdc54){for(const _0x1bb0ae of this['revisionViews'])_0x1bdc54&&_0x1bdc54['id']===_0x1bb0ae['id']?_0x1bb0ae['select']():_0x1bb0ae['deselect']();}['highlightRevisions'](_0xa8c332){for(const _0x919ee3 of this['revisionViews'])_0xa8c332['some'](({id:_0x1ecd7d})=>_0x1ecd7d===_0x919ee3['id'])?_0x919ee3['highlight']():_0x919ee3['unhighlight']();}['_addRevision'](_0x2f38a6){const _0xa25227=bi(_0x2f38a6['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x6296f2=this['timePeriodViews']['get'](0x0);_0x6296f2&&_0x6296f2['startDate']['getTime']()===_0xa25227['getTime']()||(_0x6296f2=new fi(this['locale'],_0xa25227,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x6296f2)),_0x6296f2['addRevision'](_0x2f38a6);}['_removeRevision'](_0x306f78){const _0x5cb589=bi(_0x306f78['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x5cb589)['removeRevision'](_0x306f78);}['_getTimePeriodViewByStartDate'](_0x5ed3e3){return this['timePeriodViews']['find'](_0x4623a9=>_0x4623a9['startDate']['getTime']()===_0x5ed3e3['getTime']());}}class f extends _0x557a5e{['_revisionViewer'];['_revisionsRepository'];['_sidebarView'];static ['defaultRevisionActions']=/* #__PURE__ -- @preserve */
28
28
  ((()=>['compareAgainstSelected','restoreRevision','nameRevision'])());static ['availableRevisionActions']=/* #__PURE__ -- @preserve */
29
- at();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l];}constructor(_0x3d9ce7){super(_0x3d9ce7),this['_revisionViewer']=_0x3d9ce7['plugins']['get'](l),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x546ab6=this['_revisionsRepository']['_revisions'],_0x41e24d=this['_createRevisionActions'](),_0x4f6587=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new di(this['editor']['locale'],_0x546ab6,_0x41e24d,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',(_0x5ede98,_0x220d7c)=>{_0x220d7c['revisionViews']['on']('add',(_0x5ef715,_0x57bf3e)=>{_0x57bf3e['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)),_0x4f6587['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x154ccc=this['_revisionsRepository']['getRevision'](0x0);if(_0x154ccc){const _0x35ce23=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x154ccc['id']);this['_revisionViewer']['compare'](_0x154ccc,_0x35ce23);}}['_handleRevisionSelected'](_0x322c63,_0x3c1624){const _0x16ca6c=this['_revisionsRepository']['getRevision'](_0x3c1624['id']),_0x4aafa9=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x16ca6c['id']);this['_revisionViewer']['compare'](_0x16ca6c,_0x4aafa9);}['_handleRevisionSetName'](_0x195724,_0x1029b8){this['_revisionsRepository']['getRevision'](_0x1029b8['id'])['setName'](_0x1029b8['name']);}['_handleDiffChange'](_0x3a0995,_0x466d28,_0x3ef2a5){const _0x235e79=this['_revisionsRepository']['getRevisionsInDiff'](_0x3ef2a5);_0x235e79['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x235e79),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x235e79[0x0]));}['_createRevisionActions'](){const _0x5e260c=this['editor'],_0x31219d=f['availableRevisionActions'],_0x3b2091=_0x5e260c['config']['get']('revisionHistory.revisionActions')||f['defaultRevisionActions'];if(_0x3b2091['length'])return _0x3b2091['map'](_0x2fb319=>{const _0x4e997a='string'==typeof _0x2fb319?Object['assign']({},_0x31219d[_0x2fb319]):_0x2fb319;return _0x4e997a['action']=_0x4e997a['action']['bind'](this,_0x5e260c),_0x4e997a['isVisible']&&(_0x4e997a['isVisible']=_0x4e997a['isVisible']['bind'](this,_0x5e260c)),_0x4e997a;});}}function at(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x1503e4},_0x4cd45d)=>{const _0x426220=_0x1503e4['get'](l),_0x416ea7=_0x426220['repository'];let _0x1e8af3=_0x426220['diff']['newRevisionId'],_0x2646d6=_0x4cd45d['id'];_0x416ea7['getIndex'](_0x1e8af3)>_0x416ea7['getIndex'](_0x2646d6)&&([_0x1e8af3,_0x2646d6]=[_0x2646d6,_0x1e8af3]),_0x426220['compare'](_0x1e8af3,_0x2646d6);},'isVisible':({plugins:_0xf9d8},_0x3efb04)=>{const _0x35375c=_0xf9d8['get'](l);return!(_0x35375c['repository']['getRevisionsInDiff'](_0x35375c['diff'])['length']>0x2)&&!_0x3efb04['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x4fc9b2,{id:_0x181712})=>{_0x4fc9b2['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x181712);},'isVisible':({plugins:_0x2d28ce},_0x553e02)=>!!_0x2d28ce['get'](l)['repository']['getLaterVisibleRevision'](_0x553e02['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x50dd43},{id:_0x493f6e,revisionNameView:_0x5dacf3})=>{const _0x150825=_0x50dd43['get'](l),_0xd10720=_0x150825['repository']['getEarlierVisibleRevision'](_0x493f6e);_0x150825['compare'](_0x493f6e,_0xd10720),_0x5dacf3['focus'](),_0x5dacf3['fieldView']['select']();}}};}class Z extends tt{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x4fe18f,_0x45aa1f){super(_0x4fe18f),this['_view']=_0x45aa1f,this['_toolbarConfig']=st(_0x4fe18f['config']['get']('toolbar')),this['_elementReplacer']=new it();}get['element'](){return this['view']['element'];}['init'](_0x52d14c){const _0x376a78=this['editor'],_0x1a4fef=this['view'],_0x4cd127=_0x376a78['editing']['view'],_0x14f9e6=_0x1a4fef['editable'],_0x554245=_0x4cd127['document']['getRoot']();_0x14f9e6['name']=_0x554245['rootName'],_0x1a4fef['render']();const _0x26f010=_0x14f9e6['element'];this['setEditableElement'](_0x14f9e6['name'],_0x26f010),_0x1a4fef['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x4cd127['attachDomRoot'](_0x26f010),this['_elementReplacer']['replace'](_0x52d14c,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x26f995=this['view'],_0x14f4d9=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x14f4d9['detachDomRoot'](_0x26f995['editable']['name']),_0x26f995['destroy']();}['_initToolbar'](){const _0x54aae2=this['view'];_0x54aae2['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x54aae2['stickyPanel']['limiterElement']=_0x54aae2['element'],_0x54aae2['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x2d8a6a})=>_0x2d8a6a),_0x54aae2['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x54aae2['toolbar']);}}class ii extends _0x3f26bf{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0xeac3e5,_0x12f50a,_0x3f87ec={}){super(_0xeac3e5),this['stickyPanel']=new _0x872989(_0xeac3e5),this['toolbar']=new _0x1972ec(_0xeac3e5,{'shouldGroupWhenFull':_0x3f87ec['shouldToolbarGroupWhenFull']}),this['_editable']=new te(_0xeac3e5,_0x12f50a);}['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
- _0x4ce360(_0x3c7537){['_ui'];get['ui'](){return this['_ui'];}constructor(_0xd71e74,_0x241155){super(_0x241155),this['sourceElement']=_0xd71e74,this['model']['document']['createRoot']();const _0x373203=new ii(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new Z(this,_0x373203);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x1ac949,_0x11266b){const _0xc44cf1=new this(_0x1ac949,_0x11266b);return await _0xc44cf1['initPlugins'](),await _0xc44cf1['ui']['init'](_0x1ac949),await _0xc44cf1['data']['init'](_0xc44cf1['config']['get']('initialData')||''),_0xc44cf1['fire']('ready'),_0xc44cf1;}}const d=['RevisionHistoryUI','RestrictedEditingMode'];class ht extends _0x449360{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x2d4cd3){function _0xd8ebd7(_0x3092ff){return _0x3092ff['map'](_0x44ec6b=>String['fromCharCode'](_0x44ec6b))['join']('');}super(_0x2d4cd3),this['result']='end',_0x2d4cd3[_0xd8ebd7([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0xd8ebd7([0x76,0x69,0x65,0x77])][_0xd8ebd7([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0xd8ebd7([0x61,0x75,0x74,0x6f]),_0x2d4cd3[_0xd8ebd7([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0xd8ebd7([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0xd8ebd7([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0xd8ebd7([0x73,0x74,0x61,0x74,0x75,0x73])]:_0xd8ebd7([0x6f,0x6b])});}}class ct extends _0x449360{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h,v];}constructor(_0x224718){if(super(_0x224718),!this['editor']['config']['get']('revisionHistory'))throw new _0x58ad15('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x9a7fad=>this['_showRevisionViewer']({..._0x9a7fad,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x1f9a01=>this['_closeRevisionViewer'](_0x1f9a01)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x3a4a96=>this['_restoreRevision'](_0x3a4a96)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x4d5819){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x4d5819;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0xbc273a){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0xbc273a);}['getRevision'](_0x313b48){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x313b48);}['getRevisions'](_0x46c019){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x46c019||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x4ef9d6=this['editor'],_0x33a860=_0x2b58ff(_0x4ef9d6,d),_0x36bb6b=_0x4ef9d6['plugins']['get']('RevisionTracker'),_0xff543f=_0x4ef9d6['plugins']['get']('Users')['users'];return _0x33a860['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x33a860['lazyRoots'],(_0x33a860['plugins']['push'](ht,l,u,class extends _0x449360{static get['requires'](){return[l,'Users'];}['init'](){const _0x501a5a=this['editor']['plugins']['get']('Users');for(const _0xab5c70 of _0xff543f)_0xab5c70['isAnonymous']||_0x501a5a['getUser'](_0xab5c70['id'])||_0x501a5a['addUser'](_0xab5c70);const _0x5456f2=_0x36bb6b['repository']['getRevisions']();let _0x55f07a=null;const _0x2b1809=this['editor']['plugins']['get']('RevisionViewer');_0x2b1809['adapter']=_0x36bb6b['adapter'],_0x2b1809['bind']('isEnabled')['to'](_0x36bb6b),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x4ef9d6,'isReadOnly',_0x1b2d61=>!_0x1b2d61);for(const _0x4c0c89 of _0x5456f2){const _0x153159=null===_0x4c0c89['creator'];if(_0x153159&&_0x4c0c89['toVersion']===_0x4c0c89['fromVersion'])continue;const _0x2e833b=_0x4c0c89['toJSON']();_0x2b1809['addRevisionData'](_0x2e833b,(_0xb447d1,_0x399a7e,_0x4a3344)=>{if(_0x153159){if(_0x55f07a)_0x55f07a['_update'](_0xb447d1,_0x399a7e);else{if(!_0x399a7e){const _0xf60a64=_0x4a3344['toJSON']();_0xf60a64['id']=_0x20586a(),_0x36bb6b['saveRevision'](_0xf60a64,_0x4a3344['toVersion'])['then'](_0x587ccf=>{_0x55f07a=_0x587ccf;});}}}else _0x4c0c89['_update'](_0xb447d1,_0x399a7e);});}}},f),_0x33a860);}['_enhanceShowRevisionViewerCallback'](){const _0x4ac55b=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x37e8dd=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0xa77b2d=this['editor']['plugins']['get']('Autosave');await _0xa77b2d['save']();}else await _0x37e8dd['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x208a68=this['editor']['plugins']['get']('Dialog');_0x208a68['isOpen']&&_0x208a68['hide']();}const _0x211220=this['_getRevisionViewerEditorConfig']();return _0x4ac55b(_0x211220)['then'](_0x4cab0f=>{return(this['_viewerEditor']=_0x4cab0f,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'),_0x4cab0f);})['catch'](_0x580487=>(console['error'](_0x580487),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x27b42d=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'](),_0x27b42d(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x54da90=this['editor']['plugins']['get']('Annotations');_0x54da90['refreshVisibility'](),_0x54da90['refreshPositioning']();}})));}['_showRevisionViewer'](_0x329392){const _0x491eb1=this['editor']['config']['get']('revisionHistory.editorContainer'),_0xf976d7=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x1206c2=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return m['create'](_0x1206c2,_0x329392)['then'](_0x383299=>(_0xf976d7['style']['display']='block',_0x491eb1['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x383299));}['_closeRevisionViewer'](_0x41b21c){const _0x102620=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x102620['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x41b21c['destroy']();}async['_restoreRevision'](_0x559d52){const _0x412ebc=this['editor'],_0x3b4305=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x3ca1a6=_0x412ebc['plugins']['get']('RevisionTracker'),_0x2159d9=_0x412ebc['plugins']['get']('RevisionHistoryUtils'),_0x415080=_0x3b4305['repository']['getRevision'](_0x559d52);let _0x35e8bf,_0x2c4b11,_0x22b445;try{await _0x2159d9['loadRevisionData'](_0x415080,this['adapter']),_0x35e8bf=_0x2159d9['getRevisionDocumentData'](_0x415080),_0x2c4b11=_0x2159d9['getRevisionRootsAttributes'](_0x415080);}catch(_0x2b145a){return void console['error'](_0x2b145a);}_0x412ebc['model']['change'](_0x34c39d=>{for(const _0x971424 of Array['from'](_0x412ebc['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x34c39d['removeMarker'](_0x971424);}),_0x3b4305['isReady']=!0x1,_0x412ebc['model']['enqueueChange'](_0x513163=>{_0x513163['setSelection'](null),_0x513163['removeSelectionAttribute'](_0x412ebc['model']['document']['selection']['getAttributeKeys']());const _0x1fe166=Object['keys'](_0x35e8bf);for(const _0x3c58aa of _0x412ebc['model']['document']['roots'])'$graveyard'!=_0x3c58aa['rootName']&&_0x3c58aa['isAttached']()&&!_0x1fe166['includes'](_0x3c58aa['rootName'])&&_0x513163['detachRoot'](_0x3c58aa);for(const _0x41cb53 of _0x1fe166){let _0x3a8d63=_0x412ebc['model']['document']['getRoot'](_0x41cb53);_0x3a8d63&&_0x3a8d63['isAttached']()||(_0x3a8d63=_0x513163['addRoot'](_0x41cb53));const _0x4a9daf=_0x2c4b11[_0x41cb53],_0x238383=Object['keys'](_0x4a9daf),_0xd2b8df=_0x35e8bf[_0x41cb53];for(const _0x41be1d of _0x3a8d63['getAttributeKeys']())_0x238383['includes'](_0x41be1d)||_0x513163['removeAttribute'](_0x41be1d,_0x3a8d63);for(const _0x864b6 of _0x238383)_0x513163['setAttribute'](_0x864b6,_0x2c4b11[_0x41cb53][_0x864b6],_0x3a8d63);_0x513163['remove'](_0x513163['createRangeIn'](_0x3a8d63)),_0x513163['insert'](_0x412ebc['data']['parse'](_0xd2b8df,_0x3a8d63),_0x3a8d63,0x0);}});const _0x38a737=R(_0x412ebc['locale'],'Restored');if(_0x415080['name'])_0x22b445=-0x1==_0x415080['name']['indexOf'](_0x38a737)?_0x38a737+':\x20'+_0x415080['name']:_0x415080['name'];else _0x22b445=_0x38a737+':\x20'+(_0x415080['createdAt']['toLocaleDateString'](_0x412ebc['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x415080['createdAt']['toLocaleTimeString'](_0x412ebc['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x3ca1a6['saveRevision']({'name':_0x22b445}),_0x3b4305['isReady']=!0x0,_0x412ebc['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,ji as RevisionViewerLoadingOverlay,u as RevisionViewerUI,S as RevisionsRepository,f as RevisionsSidebar,rt as ShowChangeCommand};
29
+ rt();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l];}constructor(_0x88fe8b){super(_0x88fe8b),this['_revisionViewer']=_0x88fe8b['plugins']['get'](l),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x5ebf6a=this['_revisionsRepository']['_revisions'],_0x15259c=this['_createRevisionActions'](),_0x5939e6=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new ui(this['editor']['locale'],_0x5ebf6a,_0x15259c,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',(_0x51d5e9,_0x2db3e8)=>{_0x2db3e8['revisionViews']['on']('add',(_0x45dd62,_0x51ddb4)=>{_0x51ddb4['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)),_0x5939e6['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x7ad659=this['_revisionsRepository']['getRevision'](0x0);if(_0x7ad659){const _0x5f20fb=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x7ad659['id']);this['_revisionViewer']['compare'](_0x7ad659,_0x5f20fb);}}['_handleRevisionSelected'](_0x34bc7e,_0x4e0431){const _0x37f99b=this['_revisionsRepository']['getRevision'](_0x4e0431['id']),_0x4d81d1=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x37f99b['id']);this['_revisionViewer']['compare'](_0x37f99b,_0x4d81d1);}['_handleRevisionSetName'](_0x387b74,_0xc76e16){this['_revisionsRepository']['getRevision'](_0xc76e16['id'])['setName'](_0xc76e16['name']);}['_handleDiffChange'](_0x2cb0af,_0xae2c80,_0x5026f9){const _0xc6835=this['_revisionsRepository']['getRevisionsInDiff'](_0x5026f9);_0xc6835['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0xc6835),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0xc6835[0x0]));}['_createRevisionActions'](){const _0x4aba52=this['editor'],_0x3caf0d=f['availableRevisionActions'],_0x19ef32=_0x4aba52['config']['get']('revisionHistory.revisionActions')||f['defaultRevisionActions'];if(_0x19ef32['length'])return _0x19ef32['map'](_0x3f57d3=>{const _0x331a65='string'==typeof _0x3f57d3?Object['assign']({},_0x3caf0d[_0x3f57d3]):_0x3f57d3;return _0x331a65['action']=_0x331a65['action']['bind'](this,_0x4aba52),_0x331a65['isVisible']&&(_0x331a65['isVisible']=_0x331a65['isVisible']['bind'](this,_0x4aba52)),_0x331a65;});}}function rt(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x5c76ae},_0x415e40)=>{const _0x13c687=_0x5c76ae['get'](l),_0x4cf802=_0x13c687['repository'];let _0x6ac2b4=_0x13c687['diff']['newRevisionId'],_0x511dc2=_0x415e40['id'];_0x4cf802['getIndex'](_0x6ac2b4)>_0x4cf802['getIndex'](_0x511dc2)&&([_0x6ac2b4,_0x511dc2]=[_0x511dc2,_0x6ac2b4]),_0x13c687['compare'](_0x6ac2b4,_0x511dc2);},'isVisible':({plugins:_0x1a15f8},_0x50e4b8)=>{const _0x2d8b47=_0x1a15f8['get'](l);return!(_0x2d8b47['repository']['getRevisionsInDiff'](_0x2d8b47['diff'])['length']>0x2)&&!_0x50e4b8['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x5c4135,{id:_0x44e009})=>{_0x5c4135['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x44e009);},'isVisible':({plugins:_0x5bbbe9},_0xae1cf4)=>!!_0x5bbbe9['get'](l)['repository']['getLaterVisibleRevision'](_0xae1cf4['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x4f5420},{id:_0x1056ce,revisionNameView:_0x5179de})=>{const _0x576ceb=_0x4f5420['get'](l),_0x2f7985=_0x576ceb['repository']['getEarlierVisibleRevision'](_0x1056ce);_0x576ceb['compare'](_0x1056ce,_0x2f7985),_0x5179de['focus'](),_0x5179de['fieldView']['select']();}}};}class Z extends tt{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x2519d0,_0x323816){super(_0x2519d0),this['_view']=_0x323816,this['_toolbarConfig']=st(_0x2519d0['config']['get']('toolbar')),this['_elementReplacer']=new it();}get['element'](){return this['view']['element'];}['init'](_0x361afe){const _0x47b63c=this['editor'],_0x19b043=this['view'],_0xdb45de=_0x47b63c['editing']['view'],_0x14d911=_0x19b043['editable'],_0x103fe6=_0xdb45de['document']['getRoot']();_0x14d911['name']=_0x103fe6['rootName'],_0x19b043['render']();const _0x403d0a=_0x14d911['element'];this['setEditableElement'](_0x14d911['name'],_0x403d0a),_0x19b043['editable']['bind']('isFocused')['to'](this['focusTracker']),_0xdb45de['attachDomRoot'](_0x403d0a),this['_elementReplacer']['replace'](_0x361afe,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x6dfec0=this['view'],_0x4abd61=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x4abd61['detachDomRoot'](_0x6dfec0['editable']['name']),_0x6dfec0['destroy']();}['_initToolbar'](){const _0x100375=this['view'];_0x100375['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x100375['stickyPanel']['limiterElement']=_0x100375['element'],_0x100375['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x5607fa})=>_0x5607fa),_0x100375['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x100375['toolbar']);}}class ii extends _0x24ef8d{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x411517,_0x4d8f40,_0x476cf2={}){super(_0x411517),this['stickyPanel']=new _0x6ddc23(_0x411517),this['toolbar']=new _0xad3739(_0x411517,{'shouldGroupWhenFull':_0x476cf2['shouldToolbarGroupWhenFull']}),this['_editable']=new te(_0x411517,_0x4d8f40);}['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
+ _0x514d34(_0x2522a6){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x4ce61f,_0x296977){super(_0x296977),this['sourceElement']=_0x4ce61f,this['model']['document']['createRoot']();const _0x50b349=new ii(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new Z(this,_0x50b349);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x241a31,_0x4797d6){const _0x5d1618=new this(_0x241a31,_0x4797d6);return await _0x5d1618['initPlugins'](),await _0x5d1618['ui']['init'](_0x241a31),await _0x5d1618['data']['init'](_0x5d1618['config']['get']('initialData')||''),_0x5d1618['fire']('ready'),_0x5d1618;}}const d=['RevisionHistoryUI','RestrictedEditingMode'];class at extends _0x557a5e{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x37a095){function _0x1c5d53(_0xa81cef){return _0xa81cef['map'](_0x51feb4=>String['fromCharCode'](_0x51feb4))['join']('');}super(_0x37a095),this['result']='end',_0x37a095[_0x1c5d53([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x1c5d53([0x76,0x69,0x65,0x77])][_0x1c5d53([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x1c5d53([0x61,0x75,0x74,0x6f]),_0x37a095[_0x1c5d53([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x1c5d53([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x1c5d53([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x1c5d53([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x1c5d53([0x6f,0x6b])});}}class ht extends _0x557a5e{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h,v];}constructor(_0x17f0a1){if(super(_0x17f0a1),!this['editor']['config']['get']('revisionHistory'))throw new _0x31ce40('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x4829d8=>this['_showRevisionViewer']({..._0x4829d8,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x11b211=>this['_closeRevisionViewer'](_0x11b211)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x228061=>this['_restoreRevision'](_0x228061)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0xcb651){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0xcb651;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x318c0a){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x318c0a);}['getRevision'](_0x4f2c4f){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x4f2c4f);}['getRevisions'](_0x2d1f59){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x2d1f59||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x4fd20f=this['editor'],_0x4bc60c=_0x3162bb(_0x4fd20f,d),_0x2c738a=_0x4fd20f['plugins']['get']('RevisionTracker'),_0x1a6f9c=_0x4fd20f['plugins']['get']('Users')['users'];return _0x4bc60c['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x4bc60c['lazyRoots'],(_0x4bc60c['plugins']['push'](at,l,u,class extends _0x557a5e{static get['requires'](){return[l,'Users'];}['init'](){const _0x1372d3=this['editor']['plugins']['get']('Users');for(const _0x4f45a9 of _0x1a6f9c)_0x4f45a9['isAnonymous']||_0x1372d3['getUser'](_0x4f45a9['id'])||_0x1372d3['addUser'](_0x4f45a9);const _0x16f13a=_0x2c738a['repository']['getRevisions']();let _0x2b29e0=null;const _0x22338f=this['editor']['plugins']['get']('RevisionViewer');_0x22338f['adapter']=_0x2c738a['adapter'],_0x22338f['bind']('isEnabled')['to'](_0x2c738a),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x4fd20f,'isReadOnly',_0x4144b7=>!_0x4144b7);for(const _0x419cf4 of _0x16f13a){const _0x1d4b1d=null===_0x419cf4['creator'];if(_0x1d4b1d&&_0x419cf4['toVersion']===_0x419cf4['fromVersion'])continue;const _0x467c87=_0x419cf4['toJSON']();_0x22338f['addRevisionData'](_0x467c87,(_0x724c30,_0x14321f,_0x373496)=>{if(_0x1d4b1d){if(_0x2b29e0)_0x2b29e0['_update'](_0x724c30,_0x14321f);else{if(!_0x14321f){const _0x1fc5f5=_0x373496['toJSON']();_0x1fc5f5['id']=_0x5bd0bf(),_0x2c738a['saveRevision'](_0x1fc5f5,_0x373496['toVersion'])['then'](_0x266610=>{_0x2b29e0=_0x266610;});}}}else _0x419cf4['_update'](_0x724c30,_0x14321f);});}}},f),_0x4bc60c);}['_enhanceShowRevisionViewerCallback'](){const _0x19b334=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x47a271=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x5c8484=this['editor']['plugins']['get']('Autosave');await _0x5c8484['save']();}else await _0x47a271['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x71df26=this['editor']['plugins']['get']('Dialog');_0x71df26['isOpen']&&_0x71df26['hide']();}const _0x48f6af=this['_getRevisionViewerEditorConfig']();return _0x19b334(_0x48f6af)['then'](_0x1650dc=>{return(this['_viewerEditor']=_0x1650dc,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'),_0x1650dc);})['catch'](_0x313046=>(console['error'](_0x313046),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x749f39=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'](),_0x749f39(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x49612d=this['editor']['plugins']['get']('Annotations');_0x49612d['refreshVisibility'](),_0x49612d['refreshPositioning']();}})));}['_showRevisionViewer'](_0x46199f){const _0x51aab0=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x228232=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x3c7f1d=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return m['create'](_0x3c7f1d,_0x46199f)['then'](_0x30d5ef=>(_0x228232['style']['display']='block',_0x51aab0['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x30d5ef));}['_closeRevisionViewer'](_0x7ffe){const _0x18ce42=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x18ce42['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x7ffe['destroy']();}async['_restoreRevision'](_0x2b34cb){const _0xd3ee3f=this['editor'],_0x48d33c=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x35a67c=_0xd3ee3f['plugins']['get']('RevisionTracker'),_0x466af3=_0xd3ee3f['plugins']['get']('RevisionHistoryUtils'),_0x3bcd19=_0x48d33c['repository']['getRevision'](_0x2b34cb);let _0x5dd730,_0x1bd1fa,_0x1c7b7e;try{await _0x466af3['loadRevisionData'](_0x3bcd19,this['adapter']),_0x5dd730=_0x466af3['getRevisionDocumentData'](_0x3bcd19),_0x1bd1fa=_0x466af3['getRevisionRootsAttributes'](_0x3bcd19);}catch(_0x551941){return void console['error'](_0x551941);}_0xd3ee3f['model']['change'](_0x146561=>{for(const _0x4ca141 of Array['from'](_0xd3ee3f['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x146561['removeMarker'](_0x4ca141);}),_0x48d33c['isReady']=!0x1,_0xd3ee3f['model']['enqueueChange'](_0xafac5d=>{_0xafac5d['setSelection'](null),_0xafac5d['removeSelectionAttribute'](_0xd3ee3f['model']['document']['selection']['getAttributeKeys']());const _0x3529c5=Object['keys'](_0x5dd730);for(const _0x18405e of _0xd3ee3f['model']['document']['roots'])'$graveyard'!=_0x18405e['rootName']&&_0x18405e['isAttached']()&&!_0x3529c5['includes'](_0x18405e['rootName'])&&_0xafac5d['detachRoot'](_0x18405e);for(const _0x175cd6 of _0x3529c5){let _0x3cb486=_0xd3ee3f['model']['document']['getRoot'](_0x175cd6);_0x3cb486&&_0x3cb486['isAttached']()||(_0x3cb486=_0xafac5d['addRoot'](_0x175cd6));const _0x1bf9fd=_0x1bd1fa[_0x175cd6],_0x31b019=Object['keys'](_0x1bf9fd),_0x395e15=_0x5dd730[_0x175cd6];for(const _0xe4377a of _0x3cb486['getAttributeKeys']())_0x31b019['includes'](_0xe4377a)||_0xafac5d['removeAttribute'](_0xe4377a,_0x3cb486);for(const _0x58eef5 of _0x31b019)_0xafac5d['setAttribute'](_0x58eef5,_0x1bd1fa[_0x175cd6][_0x58eef5],_0x3cb486);_0xafac5d['remove'](_0xafac5d['createRangeIn'](_0x3cb486)),_0xafac5d['insert'](_0xd3ee3f['data']['parse'](_0x395e15,_0x3cb486),_0x3cb486,0x0);}});const _0x5e2467=R(_0xd3ee3f['locale'],'Restored');if(_0x3bcd19['name'])_0x1c7b7e=-0x1==_0x3bcd19['name']['indexOf'](_0x5e2467)?_0x5e2467+':\x20'+_0x3bcd19['name']:_0x3bcd19['name'];else _0x1c7b7e=_0x5e2467+':\x20'+(_0x3bcd19['createdAt']['toLocaleDateString'](_0xd3ee3f['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x3bcd19['createdAt']['toLocaleTimeString'](_0xd3ee3f['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x35a67c['saveRevision']({'name':_0x1c7b7e}),_0x48d33c['isReady']=!0x0,_0xd3ee3f['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,ji as RevisionViewerLoadingOverlay,u as RevisionViewerUI,S as RevisionsRepository,f as RevisionsSidebar,ot as ShowChangeCommand};