@ckeditor/ckeditor5-revision-history 47.4.0-alpha.3 → 47.4.0-alpha.5

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 +12 -12
  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 _0x113f03,uid as _0x532896,Collection as _0x504df2,logWarning as _0x47c187,FocusTracker as _0x30890a,KeystrokeHandler as _0x34a3da,scrollViewportToShowTarget as _0x3a5a7e,ResizeObserver as ot,ElementReplacer as it,CKEditorError as _0x1d6810}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x83ca90,set as _0x4fdd88,unset as _0x48e3b0,isEqual as _0x3c0bf9}from'es-toolkit/compat';import{Plugin as _0xbe21c4,PendingActions as _0x71dee9,Command as _0x4856a5,ElementApiMixin as _0x28570d,Editor as _0x1dbeab}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x416e9c,getMarkerDomElement as _0x1f08bc,ConfirmMixin as _0x43b418,sanitizeEditorConfig as _0x45ed39}from'ckeditor5-collaboration/dist/index.js';import{ViewContainerElement as _0x184b8e,ViewAttributeElement as _0x1205ba,ViewEmptyElement as _0x470df9,ViewRawElement as _0x510a8d,ViewUIElement as _0x4555eb,ViewDocumentFragment as _0x164cef,ViewText as _0x4e7f12,ViewElement as _0x451dcb,ModelElement as _0x36b445,ModelRange as _0xb3cd0f,ModelPosition as _0x517828,ModelDocumentFragment as _0x8c84c8,ModelText as _0x367598}from'@ckeditor/ckeditor5-engine/dist/index.js';import{IconHistory as _0x672cd0,IconChevronUp as _0x4fea33,IconChevronDown as _0xaf50d4,IconUndo as _0x31592a,IconUser as _0x21d8a3,IconThreeVerticalDots as _0x3f675d}from'@ckeditor/ckeditor5-icons/dist/index.js';import{CssTransitionDisablerMixin as _0x5aa04a,View as _0x4eb8a3,submitHandler as _0xccd7c3,LabeledFieldView as et,createLabeledInputText as ti,createDropdown as _0x1e23a0,ListView as _0x4b2173,ListItemView as _0x55af41,ButtonView as _0x41a1a9,MenuBarMenuView as _0x22ce88,MenuBarMenuListView as _0x3b6094,MenuBarMenuListItemView as _0x360a69,MenuBarMenuListItemButtonView as _0x1b7074,ContextualBalloon as _0x3e3e3f,ToolbarSeparatorView as _0x4bb486,IconView as _0x517cab,addListToDropdown as _0x105741,UIModel as to,EditorUI as tt,normalizeToolbarConfig as st,BoxedEditorUIView as _0x20cce1,StickyPanelView as _0x82d6c7,ToolbarView as _0x392eb7,InlineEditableUIView as te}from'@ckeditor/ckeditor5-ui/dist/index.js';import{DateTime as _0x275244}from'luxon';class I extends/* #__PURE__ -- @preserve */
24
- _0x113f03(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x122a79){super(),this['id']=_0x122a79['id']||_0x532896(),this['creator']=_0x122a79['creator']||null,this['authors']=_0x122a79['authors']||[],this['diffData']=_0x122a79['diffData']||null,this['toVersion']=_0x122a79['toVersion']||0x0,this['fromVersion']=_0x122a79['fromVersion']||0x0,this['set']('name',_0x122a79['name']||''),this['set']('createdAt',_0x122a79['createdAt']||new Date()),this['set']('attributes',_0x122a79['attributes']||{});}['setName'](_0xdfe461){this['_update']({'name':_0xdfe461});}['setAttribute'](_0x417e6a,_0x26cb13){const _0x1b5460=_0x83ca90(this['attributes']);_0x4fdd88(_0x1b5460,_0x417e6a,_0x26cb13),this['_update']({'attributes':_0x1b5460});}['removeAttribute'](_0x5c0ec4){const _0x35dc69=_0x83ca90(this['attributes']);_0x48e3b0(_0x35dc69,_0x5c0ec4),this['_update']({'attributes':_0x35dc69});}['_update'](_0x34a76,_0x40aebc=!0x1){let _0x4eb16e=!0x1;const _0x56fa11={'id':this['id']},_0xc15135=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x31f3a5 of _0xc15135){const _0x56b90f=_0x34a76[_0x31f3a5];void 0x0!==_0x56b90f&&_0x56b90f!==this[_0x31f3a5]&&(this[_0x31f3a5]=_0x56b90f,_0x56fa11[_0x31f3a5]=_0x56b90f,_0x4eb16e=!0x0);}_0x4eb16e&&(_0x56fa11['authors']&&(_0x56fa11['authorsIds']=_0x56fa11['authors']['map'](_0x1946de=>_0x1946de['id']),delete _0x56fa11['authors']),this['fire']('_update',_0x56fa11,_0x40aebc));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x32f8b8=>_0x32f8b8['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class S extends _0xbe21c4{['_revisions'];static get['requires'](){return[_0x416e9c];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x167d67){super(_0x167d67),this['_revisions']=new _0x504df2();}['afterInit'](){!async function(_0x1be641){const _0xc6de19=_0x16bffc([0x76,0x73,0x6d,0x4c,0x34,0x54,0x50,0x70,0x75,0x52,0x35,0x33,0x4d,0x6c,0x71,0x53,0x6a,0x32,0x56,0x58,0x77,0x48,0x39,0x6f,0x45,0x41,0x4e,0x38,0x46,0x78,0x4a,0x74,0x47,0x55,0x4f,0x64,0x62,0x44,0x43,0x5a,0x30,0x31,0x69,0x68,0x79,0x66,0x6b,0x42,0x51,0x59,0x36,0x61,0x63,0x67,0x7a,0x37,0x72,0x49,0x65,0x57,0x4b,0x6e]),_0x1d691c=0xeb829,_0x4e350b=0x359e09b0,_0x7ee81c=0x35997730^_0x4e350b,_0x4df571=window[_0x16bffc([0x44,0x61,0x74,0x65])][_0x16bffc([0x6e,0x6f,0x77])](),_0x3df50e=_0x1be641[_0x16bffc([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x4a977f=new window[(_0x16bffc([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0xaee380=>{_0x3df50e[_0x16bffc([0x6f,0x6e,0x63,0x65])](_0x16bffc([0x72,0x65,0x61,0x64,0x79]),_0xaee380);}),_0x27555d={[_0x16bffc([0x6b,0x74,0x79])]:_0x16bffc([0x45,0x43]),[_0x16bffc([0x75,0x73,0x65])]:_0x16bffc([0x73,0x69,0x67]),[_0x16bffc([0x63,0x72,0x76])]:_0x16bffc([0x50,0x2d,0x32,0x35,0x36]),[_0x16bffc([0x78])]:_0x16bffc([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]),[_0x16bffc([0x79])]:_0x16bffc([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]),[_0x16bffc([0x61,0x6c,0x67])]:_0x16bffc([0x45,0x53,0x32,0x35,0x36])},_0x268ad2=_0x3df50e[_0x16bffc([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x16bffc([0x67,0x65,0x74])](_0x16bffc([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x4904d0(){let _0x346122,_0xa02b58=null,_0x2d2f4b=null;try{if(_0x268ad2==_0x16bffc([0x47,0x50,0x4c]))return _0x16bffc([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x346122=_0x2b1b08(),!_0x346122)return _0x16bffc([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x346122[_0x16bffc([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x2d2f4b=_0x44e40a(_0x346122[_0x16bffc([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x346122[_0x16bffc([0x6a,0x74,0x69])])),await _0x10f76d()?_0x56ba78()?_0x239d44()?_0x16bffc([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x313799()?(_0x346122[_0x16bffc([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x16bffc([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0xa02b58=_0x12a5c7(_0x16bffc([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),await _0x293170()):_0x16bffc([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x16bffc([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x16bffc([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x16bffc([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x239d44(){const _0x1d19ee=[_0x16bffc([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x16bffc([0x74,0x72,0x69,0x61,0x6c])][_0x16bffc([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x346122[_0x16bffc([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x4df571/0x3e8:0xe10*_0x7ee81c;return _0x346122[_0x16bffc([0x65,0x78,0x70])]<_0x1d19ee;}function _0x56ba78(){const _0x2718e9=_0x346122[_0x16bffc([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x2718e9)return!0x1;if(_0x2718e9[_0x16bffc([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x16bffc([0x2a])))return!0x0;if(_0x2718e9[_0x16bffc([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x16bffc([0x52,0x48])))return!0x0;if(_0x2718e9[_0x16bffc([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x16bffc([0x52,0x52,0x48]))){if(_0x4da140())return!0x0;if(_0x57cec7()||_0x4a3e4c())return!0x0;}return!0x1;}function _0x313799(){const _0x26209f=_0x346122[_0x16bffc([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x26209f||0x0==_0x26209f[_0x16bffc([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x1a5b33}=new URL(window[_0x16bffc([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x26209f[_0x16bffc([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x1a5b33))return!0x0;const _0x16ee4b=_0x1a5b33[_0x16bffc([0x73,0x70,0x6c,0x69,0x74])](_0x16bffc([0x2e]));return _0x26209f[_0x16bffc([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x49c42b=>_0x49c42b[_0x16bffc([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x16bffc([0x2a])))[_0x16bffc([0x6d,0x61,0x70])](_0x2b60eb=>_0x2b60eb[_0x16bffc([0x73,0x70,0x6c,0x69,0x74])](_0x16bffc([0x2e])))[_0x16bffc([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x8813cd=>_0x8813cd[_0x16bffc([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x16ee4b[_0x16bffc([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x16bffc([0x6d,0x61,0x70])](_0x594487=>Array(_0x16ee4b[_0x16bffc([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0x594487[_0x16bffc([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x16bffc([0x66,0x69,0x6c,0x6c])](_0x594487[0x0]===_0x16bffc([0x2a])?_0x16bffc([0x2a]):'')[_0x16bffc([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0x594487))[_0x16bffc([0x73,0x6f,0x6d,0x65])](_0x231205=>_0x16ee4b[_0x16bffc([0x65,0x76,0x65,0x72,0x79])]((_0x2c2176,_0x5da9fd)=>_0x231205[_0x5da9fd]===_0x2c2176||_0x231205[_0x5da9fd]===_0x16bffc([0x2a])));}function _0x293170(){return _0xa02b58&&_0x2d2f4b?new window[(_0x16bffc([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x4b9324,_0x244662)=>{_0xa02b58[_0x16bffc([0x74,0x68,0x65,0x6e])](_0x4b9324,_0x244662),_0x2d2f4b[_0x16bffc([0x74,0x68,0x65,0x6e])](_0xe338fc=>{_0xe338fc!=_0x16bffc([0x56,0x61,0x6c,0x69,0x64])&&_0x4b9324(_0xe338fc);},_0x244662);}):_0xa02b58||_0x2d2f4b||_0x16bffc([0x56,0x61,0x6c,0x69,0x64]);}}function _0x44e40a(_0x2e8af7,_0x4b8a72){return new window[(_0x16bffc([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x563948=>{if(_0xbb56d8())return _0x563948(_0x16bffc([0x56,0x61,0x6c,0x69,0x64]));_0x263a24(),_0x3df50e[_0x16bffc([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x16bffc([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x5336a6=!0x1;const _0x1b32c0=_0x532896();function _0x3369e1(_0x3dee3a){return!!_0x3dee3a&&(typeof _0x3dee3a===_0x16bffc([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x3dee3a===_0x16bffc([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x3dee3a[_0x16bffc([0x74,0x68,0x65,0x6e])]===_0x16bffc([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x3dee3a[_0x16bffc([0x63,0x61,0x74,0x63,0x68])]===_0x16bffc([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x5ceafd(_0x203889){_0x3c554d(_0x203889)[_0x16bffc([0x74,0x68,0x65,0x6e])](_0x327eae=>{if(!_0x327eae||_0x327eae[_0x16bffc([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x16bffc([0x6f,0x6b]))return _0x16bffc([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x1ea563(_0x54756b(_0x1b32c0+_0x4b8a72))!=_0x327eae[_0x16bffc([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x16bffc([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x16bffc([0x56,0x61,0x6c,0x69,0x64]);})[_0x16bffc([0x74,0x68,0x65,0x6e])](_0x2b87b9=>(_0x50e41d(),_0x2b87b9),()=>{const _0x5c44c0=_0x5a73d8();return null==_0x5c44c0?(_0x50e41d(),_0x16bffc([0x56,0x61,0x6c,0x69,0x64])):_0x16bffc(_0x4df571-_0x5c44c0>(0x11928db0^_0x4e350b)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x16bffc([0x74,0x68,0x65,0x6e])](_0x563948)[_0x16bffc([0x63,0x61,0x74,0x63,0x68])](()=>{_0x563948(_0x16bffc([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x27fa3c=0x35a8e730^_0x4e350b;function _0x50e41d(){const _0xe85ebc=_0x16bffc([0x6c,0x6c,0x63,0x74,0x2d])+_0x1ea563(_0x54756b(_0x2e8af7)),_0x3537f4=_0x269398(_0x1ea563(window[_0x16bffc([0x4d,0x61,0x74,0x68])][_0x16bffc([0x63,0x65,0x69,0x6c])](_0x4df571/_0x27fa3c)));window[_0x16bffc([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x16bffc([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0xe85ebc,_0x3537f4);}function _0x5a73d8(){const _0x3ddbb0=_0x16bffc([0x6c,0x6c,0x63,0x74,0x2d])+_0x1ea563(_0x54756b(_0x2e8af7)),_0x6da89a=window[_0x16bffc([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x16bffc([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x3ddbb0);return _0x6da89a?window[_0x16bffc([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x269398(_0x6da89a),0x10)*_0x27fa3c:null;}function _0x3c554d(_0x583d73){return new window[(_0x16bffc([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x554530,_0x345818)=>{_0x583d73[_0x16bffc([0x74,0x68,0x65,0x6e])](_0x554530,_0x345818),window[_0x16bffc([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x345818,0x359fdd70^_0x4e350b);});}}_0x3df50e[_0x16bffc([0x6f,0x6e])](_0x16bffc([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x205b7f,_0x4b7370)=>{if(_0x4b7370[0x0]!=_0x2e8af7)return _0x563948(_0x16bffc([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x4b7370[0x1]={..._0x4b7370[0x1],[_0x16bffc([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x1b32c0};},{[_0x16bffc([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x16bffc([0x68,0x69,0x67,0x68])}),_0x3df50e[_0x16bffc([0x6f,0x6e])](_0x16bffc([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x2bc05a=>{_0x3369e1(_0x2bc05a[_0x16bffc([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x5336a6=!0x0,_0x5ceafd(_0x2bc05a[_0x16bffc([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x16bffc([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x16bffc([0x6c,0x6f,0x77])}),_0x4a977f[_0x16bffc([0x74,0x68,0x65,0x6e])](()=>{_0x5336a6||_0x563948(_0x16bffc([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0xbb56d8(){return _0x3df50e[_0x16bffc([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x16bffc([0x76,0x69,0x65,0x77])][_0x16bffc([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x16bffc([0x61,0x75,0x74,0x6f]);}function _0x263a24(){_0x3df50e[_0x16bffc([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x16bffc([0x76,0x69,0x65,0x77])][_0x16bffc([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x16bffc([0x61,0x75,0x74,0x6f]);}}function _0x12a5c7(_0x3f3cec){const _0x39b26a=[new window[(_0x16bffc([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x54cdf9=>setTimeout(_0x54cdf9,0x3597377c^_0x4e350b)),_0x4a977f[_0x16bffc([0x74,0x68,0x65,0x6e])](()=>new window[(_0x16bffc([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x423ffc=>{const _0xac76c0=0x359e09b7^_0x4e350b,_0x20f67d=_0x1be641[_0x16bffc([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x5f5e41(){_0x20f67d[_0x16bffc([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0xac76c0&&_0x423ffc();}_0x5f5e41(),_0x20f67d[_0x16bffc([0x6f,0x6e])](_0x16bffc([0x61,0x64,0x64]),_0x5f5e41);})),new window[(_0x16bffc([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0xd3e923=>{function _0x94cbc8(){for(const _0x358ec1 in window)if(window[_0x16bffc([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x16bffc([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x358ec1))&&window[_0x358ec1]==_0x1d691c)return _0xd3e923();_0x3df50e[_0x16bffc([0x73,0x74,0x61,0x74,0x65])]!=_0x16bffc([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x16bffc([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x94cbc8,0x359e1a38^_0x4e350b);}_0x3e5cbd(_0x16bffc([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x94cbc8();})];return window[_0x16bffc([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x16bffc([0x72,0x61,0x63,0x65])](_0x39b26a)[_0x16bffc([0x74,0x68,0x65,0x6e])](()=>_0x3f3cec);}async function _0x40773d(){if(await _0x4a977f,_0x3e5cbd(_0x16bffc([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x38ee98=_0x1be641[_0x16bffc([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x393396=_0x1be641[_0x16bffc([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])](_0x38ee98[_0x16bffc([0x69,0x64])]),_0x3cf109=_0x526d1b(_0x16bffc([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x3cf109[_0x16bffc([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x38ee98['id'],_0x393396?_0x393396['id']:null,!0x0),_0x3cf109[_0x16bffc([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x16bffc([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x3cf109[_0x16bffc([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x3cf109[_0x16bffc([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x2ddc71,void(_0x3cf109[_0x16bffc([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x2ddc71);}if(_0x3e5cbd(_0x16bffc([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x4539a8=_0x526d1b(_0x16bffc([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x4539a8[_0x16bffc([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x16bffc([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x4539a8[_0x16bffc([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x4539a8[_0x16bffc([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x2ddc71,_0x4539a8[_0x16bffc([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x2ddc71;}_0x3df50e[_0x16bffc([0x6d,0x6f,0x64,0x65,0x6c])][_0x16bffc([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x2ddc71,_0x3df50e[_0x16bffc([0x6d,0x6f,0x64,0x65,0x6c])][_0x16bffc([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x2ddc71,_0x3df50e[_0x16bffc([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x16bffc([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x4da140(){return _0x3e5cbd(_0x16bffc([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x526d1b(_0x16bffc([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x16bffc([0x73,0x74,0x61,0x74,0x65])]==_0x16bffc([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x57cec7(){return _0x3e5cbd(_0x16bffc([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 _0x4a3e4c(){return _0x3e5cbd(_0x16bffc([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x2cc5ad(_0x1634c1){const _0x303ee7=_0x357c0a();_0x3df50e[_0x303ee7]=_0x16bffc([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])+_0x1634c1,_0x1634c1[_0x16bffc([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x16bffc([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x357c0a()]=_0x1d691c),_0x1634c1!=_0x16bffc([0x56,0x61,0x6c,0x69,0x64])&&_0x40773d();}function _0x357c0a(){const _0x1e0942=window[_0x16bffc([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x16bffc([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x16bffc([0x6e,0x6f,0x77])]())[_0x16bffc([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x16bffc([0x2e]),'');let _0x457de2=_0x16bffc([0x76]);for(let _0x52be66=0x0;_0x52be66<_0x1e0942[_0x16bffc([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x52be66+=0x2){let _0x3bbb3f=window[_0x16bffc([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x1e0942[_0x16bffc([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x52be66,_0x52be66+0x2));_0x3bbb3f>=_0xc6de19[_0x16bffc([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x3bbb3f-=_0xc6de19[_0x16bffc([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x457de2+=_0xc6de19[_0x3bbb3f];}return _0x457de2;}function _0x2b1b08(){const _0x3b755f=_0x268ad2[_0x16bffc([0x73,0x70,0x6c,0x69,0x74])](_0x16bffc([0x2e]));if(0x3!=_0x3b755f[_0x16bffc([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x5c2210(_0x3b755f[0x1]);function _0x5c2210(_0x44a8c1){const _0x112d5a=_0x5bd43a(_0x44a8c1);return _0x112d5a&&_0x496faa()?_0x112d5a:null;function _0x496faa(){const _0x1d396f=_0x112d5a[_0x16bffc([0x6a,0x74,0x69])],_0x556a68=window[_0x16bffc([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x1d396f[_0x16bffc([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x1d396f[_0x16bffc([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x15d924={..._0x112d5a,[_0x16bffc([0x6a,0x74,0x69])]:_0x1d396f[_0x16bffc([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x1d396f[_0x16bffc([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x15d924[_0x16bffc([0x76,0x63])],_0x54756b(_0x15d924)==_0x556a68;}}}async function _0x10f76d(){let _0x216826=!0x0;try{const _0x2d056f=_0x268ad2[_0x16bffc([0x73,0x70,0x6c,0x69,0x74])](_0x16bffc([0x2e])),[_0x5e5e89,_0x230645,_0x434ccb]=_0x2d056f;return _0x51d052(_0x5e5e89),await _0x54ef66(_0x5e5e89,_0x230645,_0x434ccb),_0x216826;}catch{return!0x1;}function _0x51d052(_0x54226f){const _0x3cbe75=_0x5bd43a(_0x54226f);_0x3cbe75&&_0x3cbe75[_0x16bffc([0x61,0x6c,0x67])]==_0x16bffc([0x45,0x53,0x32,0x35,0x36])||(_0x216826=!0x1);}async function _0x54ef66(_0x475bd6,_0x50590f,_0x5a2724){const _0x520217=window[_0x16bffc([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x16bffc([0x66,0x72,0x6f,0x6d])](_0x3de5a0(_0x5a2724),_0x32fd81=>_0x32fd81[_0x16bffc([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x38a64f=new window[(_0x16bffc([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x16bffc([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x475bd6+_0x16bffc([0x2e])+_0x50590f),_0x145587=window[_0x16bffc([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x16bffc([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x145587)return;const _0x2597f0=await _0x145587[_0x16bffc([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x16bffc([0x6a,0x77,0x6b]),_0x27555d,{[_0x16bffc([0x6e,0x61,0x6d,0x65])]:_0x16bffc([0x45,0x43,0x44,0x53,0x41]),[_0x16bffc([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x16bffc([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x16bffc([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x145587[_0x16bffc([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x16bffc([0x6e,0x61,0x6d,0x65])]:_0x16bffc([0x45,0x43,0x44,0x53,0x41]),[_0x16bffc([0x68,0x61,0x73,0x68])]:{[_0x16bffc([0x6e,0x61,0x6d,0x65])]:_0x16bffc([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x2597f0,_0x520217,_0x38a64f)||(_0x216826=!0x1);}}function _0x5bd43a(_0x104e5a){return _0x104e5a[_0x16bffc([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x16bffc([0x65,0x79]))?JSON[_0x16bffc([0x70,0x61,0x72,0x73,0x65])](_0x3de5a0(_0x104e5a)):null;}function _0x3de5a0(_0x346411){return window[_0x16bffc([0x61,0x74,0x6f,0x62])](_0x346411[_0x16bffc([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x16bffc([0x2b]))[_0x16bffc([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x16bffc([0x2f])));}function _0x54756b(_0x2c07db){let _0x21f488=0x1505;function _0x316a22(_0xdbdae){for(let _0x550cee=0x0;_0x550cee<_0xdbdae[_0x16bffc([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x550cee++){const _0x1d09b7=_0xdbdae[_0x16bffc([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x550cee);_0x21f488=(_0x21f488<<0x5)+_0x21f488+_0x1d09b7,_0x21f488&=_0x21f488;}}function _0x4768e3(_0x18f046){Array[_0x16bffc([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x18f046)?_0x18f046[_0x16bffc([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x4768e3):_0x18f046&&typeof _0x18f046==_0x16bffc([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x16bffc([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x18f046)[_0x16bffc([0x73,0x6f,0x72,0x74])]()[_0x16bffc([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x277389,_0x52b922])=>{_0x316a22(_0x277389),_0x4768e3(_0x52b922);}):_0x316a22(window[_0x16bffc([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x18f046));}return _0x4768e3(_0x2c07db),_0x21f488>>>0x0;}function _0x1ea563(_0x59a14d){return _0x59a14d[_0x16bffc([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x16bffc([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x16bffc([0x30]));}function _0x269398(_0x31b363){return _0x31b363[_0x16bffc([0x73,0x70,0x6c,0x69,0x74])]('')[_0x16bffc([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x16bffc([0x6a,0x6f,0x69,0x6e])]('');}function _0x3e5cbd(_0x194e26){return _0x3df50e[_0x16bffc([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x16bffc([0x68,0x61,0x73])](_0x194e26);}function _0x526d1b(_0x50ae14){return _0x3df50e[_0x16bffc([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x16bffc([0x67,0x65,0x74])](_0x50ae14);}function _0x2ddc71(){}function _0x16bffc(_0x1067d3){return _0x1067d3['map'](_0x126e76=>String['fromCharCode'](_0x126e76))['join']('');}_0x2cc5ad(await _0x4904d0());}(this);}['createRevision'](_0xfd9879){const _0x1d7005=this['editor']['plugins']['get']('Users');return new I({'id':_0xfd9879['id'],'name':_0xfd9879['name'],'creator':_0xfd9879['creatorId']?_0x1d7005['getUser'](_0xfd9879['creatorId']):null,'diffData':_0xfd9879['diffData']||_0xfd9879['data'],'authors':_0xfd9879['authorsIds']['map'](_0x1f1af5=>_0x1d7005['getUser'](_0x1f1af5)),'createdAt':new Date(_0xfd9879['createdAt']),'attributes':_0xfd9879['attributes'],'fromVersion':_0xfd9879['fromVersion'],'toVersion':_0xfd9879['toVersion']});}['addRevision'](_0xc1c8af,_0x577ef0=0x0){this['_revisions']['add'](_0xc1c8af,_0x577ef0);}['getRevision'](_0xa05bcb){return this['_revisions']['get'](_0xa05bcb);}['getRevisions'](_0x37b8cd={'toJSON':!0x1}){const _0x3e72cd=Array['from'](this['_revisions']);return _0x3e72cd['reverse'](),_0x37b8cd['toJSON']?_0x3e72cd['map'](_0x4d0f9b=>_0x4d0f9b['toJSON']()):_0x3e72cd;}['getIndex'](_0x2eb159){return this['_revisions']['getIndex'](_0x2eb159);}['getEarlierVisibleRevision'](_0x141fab){const [,_0x30ca81]=this['getRevisionsIterator'](_0x141fab,{'direction':'earlier'});return _0x30ca81;}['getLaterVisibleRevision'](_0x5c0bdd){const [,_0x1dcd50]=this['getRevisionsIterator'](_0x5c0bdd,{'direction':'later'});return _0x1dcd50;}['getRevisionsInDiff'](_0x860894){const _0x39ffb8=[];for(const _0x162ac7 of this['getRevisionsIterator'](_0x860894['newRevisionId']))if(_0x39ffb8['push'](_0x162ac7),_0x162ac7['id']===_0x860894['oldRevisionId'])break;return _0x39ffb8;}*['getRevisionsIterator'](_0x5ec5ba,{direction:_0x11c4f1='earlier',filter:_0xb9a0f3=()=>!0x0}={}){const _0xd7fe22='earlier'===_0x11c4f1?0x1:-0x1;let _0x4599fb=this['_revisions']['get'](_0x5ec5ba),_0x145a82=this['getIndex'](_0x4599fb);for(yield _0x4599fb;_0x4599fb;){if(_0x145a82+=_0xd7fe22,_0x4599fb=this['getRevision'](_0x145a82),!_0x4599fb)return;_0xb9a0f3(_0x4599fb)&&(yield _0x4599fb);}}}class $ extends _0xbe21c4{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x184b8e,'c'],[_0x1205ba,'a'],[_0x470df9,'e'],[_0x510a8d,'r'],[_0x4555eb,'u']]);['_typeCharToViewClass']=new Map([['c',_0x184b8e],['a',_0x1205ba],['e',_0x470df9],['r',_0x510a8d],['u',_0x4555eb]]);async['loadRevisionData'](_0x120bae,_0x3ff57c){if(_0x120bae['diffData']||!_0x3ff57c)return;const _0x281afb=this['editor']['config']['get']('collaboration.channelId'),_0x3b9f96=await _0x3ff57c['getRevision']({'channelId':_0x281afb,'revisionId':_0x120bae['id']});_0x120bae['diffData']=_0x3b9f96['diffData'];}['getRevisionDocumentData'](_0x1ef2f0){const _0x4e9980={};for(const _0x516468 in _0x1ef2f0['diffData']){if(_0x1ef2f0['diffData'][_0x516468]['attachChange']&&!_0x1ef2f0['diffData'][_0x516468]['attachChange']['isAttached'])continue;const _0x3fe9d0=this['_removeRevisionMarkers'](JSON['parse'](_0x1ef2f0['diffData'][_0x516468]['insertions'])),_0x154c43=this['editor']['editing']['view']['document'],_0x50a4e4=new _0x164cef(_0x154c43,_0x3fe9d0['map'](_0x456637=>this['_getViewFromDiffObj'](_0x456637,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x4e9980[_0x516468]=this['editor']['data']['processor']['toData'](_0x50a4e4),this['editor']['data']['processor']['useFillerType']('default');}return _0x4e9980;}['getRevisionRootsAttributes'](_0x35b480){const _0x29858a={};for(const _0x15566e in _0x35b480['diffData'])_0x35b480['diffData'][_0x15566e]['attachChange']&&!_0x35b480['diffData'][_0x15566e]['attachChange']['isAttached']||(_0x29858a[_0x15566e]=_0x35b480['diffData'][_0x15566e]['attributesAfter']||{});return _0x29858a;}['_getTypeCharForViewElement'](_0x49d350){return this['_viewClassToTypeChar']['get'](_0x49d350['constructor']);}['_getViewFromDiffObj'](_0x4fc9e7,_0x5614b3){const _0x4402d0=this['editor']['editing']['view']['document'];if('string'==typeof _0x4fc9e7)return new _0x4e7f12(_0x4402d0,_0x4fc9e7);{let _0x28e7d7,_0x10896e;_0x10896e='u'==_0x4fc9e7['type']||'r'==_0x4fc9e7['type']?[]:_0x4fc9e7['children']['map'](_0x470ab6=>this['_getViewFromDiffObj'](_0x470ab6,_0x5614b3));const _0x318e8e=this['_typeCharToViewClass']['get'](_0x4fc9e7['type'])||_0x451dcb,_0x2f0508=this['editor']['data']['htmlProcessor']['domConverter'];if(_0x28e7d7=new _0x318e8e(_0x4402d0,_0x4fc9e7['name'],_0x4fc9e7['attributes'],_0x10896e),'u'==_0x4fc9e7['type']&&_0x4fc9e7['children'][0x0]){const _0x621f43=_0x4fc9e7['children'][0x0];if(_0x28e7d7['render']=function(_0x4814ad){const _0x579127=_0x4814ad['createElement']('div');return _0x579127['innerHTML']=_0x621f43,_0x579127['childNodes'][0x0];},_0x5614b3){const _0x3ac14b=new _0x164cef(_0x4402d0);_0x3ac14b['_appendChild'](_0x28e7d7);const _0x320d21=Array['from'](_0x2f0508['viewChildrenToDom'](_0x3ac14b,{'bind':!0x1})),_0x12bc04=_0x2f0508['domDocument']['createElement']('div');_0x12bc04['append'](..._0x320d21),_0x28e7d7=Array['from'](_0x2f0508['domChildrenToView'](_0x12bc04))[0x0];}}else{if('r'==_0x4fc9e7['type']&&_0x4fc9e7['children'][0x0]){const _0x3e4000=_0x4fc9e7['children'][0x0];if(_0x28e7d7['render']=function(_0x429c7c){_0x429c7c['innerHTML']=_0x3e4000;},_0x5614b3){const _0x2107df=new _0x164cef(_0x4402d0);_0x2107df['_appendChild'](_0x28e7d7);const _0x480c56=Array['from'](_0x2f0508['viewChildrenToDom'](_0x2107df,{'bind':!0x1})),_0x5b4e61=_0x2f0508['domDocument']['createElement']('div');_0x5b4e61['append'](..._0x480c56);const _0x2fb648=Array['from'](_0x2f0508['domChildrenToView'](_0x5b4e61));_0x2fb648['length']>0x1?_0x28e7d7['_appendChild'](_0x2fb648):_0x28e7d7=_0x2fb648[0x0];}}}if(_0x4fc9e7['customProperties']){for(const [_0x59ec91,_0x16c1d9]of _0x4fc9e7['customProperties'])_0x28e7d7['_setCustomProperty'](_0x59ec91,_0x16c1d9);}const _0x1f8c28=void 0x0===_0x4fc9e7['fillerOffset']?null:_0x4fc9e7['fillerOffset'];return null!==_0x1f8c28&&(_0x28e7d7['getFillerOffset']=()=>_0x1f8c28),_0x28e7d7;}}['_makeModelFromViewString'](_0xc43205){const _0x52d8b8=JSON['parse'](_0xc43205),_0x4cab25=this['editor']['editing']['view']['document'],_0x5694ca=new _0x164cef(_0x4cab25,_0x52d8b8['map'](_0x425ee4=>this['_getViewFromDiffObj'](_0x425ee4,!0x0)));return this['editor']['data']['toModel'](_0x5694ca);}['_removeRevisionMarkers'](_0x419569){return(_0x419569=_0x419569['filter'](_0x4899ba=>!_0x4899ba['name']||'revision-start'!==_0x4899ba['name']&&'revision-end'!==_0x4899ba['name']))['forEach'](_0x5d908d=>{'string'!=typeof _0x5d908d&&(_0x5d908d['children']=this['_removeRevisionMarkers'](_0x5d908d['children']),_0x5d908d['attributes']=_0x5d908d['attributes']['filter'](_0x5275e=>!_0x5275e[0x0]['startsWith']('data-revision-')));}),_0x419569;}}function m(_0x2ed78e,_0xd6e66e,_0x3f540b){const t=_0x2ed78e['t'];switch(_0xd6e66e){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'},_0x3f540b);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x3f540b);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 _0xbe21c4{['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[_0x416e9c,S,$,_0x71dee9];}constructor(_0x2db966){super(_0x2db966),this['repository']=this['editor']['plugins']['get']('RevisionsRepository'),this['_utils']=this['editor']['plugins']['get']('RevisionHistoryUtils'),this['_revisionDataBuilder']=new x(this['editor']),this['_initialRevisionId']=this['editor']['config']['get']('collaboration.channelId')||'initial',this['_bufferedUpdates']=new Map(),this['_loadedStateData']=null;const _0x18a338=_0x532896();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x18a338},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 _0x4267c8=this['repository']['getRevision'](0x0),_0xe3cc48=_0x4267c8&&null===_0x4267c8['creator']?_0x4267c8:null;if(this['_continueCurrentRevision']=!!_0xe3cc48&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x30594b=this['_source']['getCurrentRevisionId'](),_0x46b8d0=this['repository']['getRevision'](_0x30594b);if(_0x46b8d0)this['_startingVersion']=_0x46b8d0['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x373bd1=this['_source']['history']['_operations']['find'](_0x29ce7a=>!_0x29ce7a['_isInit']),_0x520955=_0x373bd1?_0x373bd1['baseVersion']:this['_source']['history']['version'];_0x4267c8?(_0x4267c8['toVersion']<_0x520955&&_0x4267c8['_update']({'toVersion':_0x520955}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0xe3cc48['id'],this['_startingVersion']=_0xe3cc48['fromVersion']):(this['_startingVersion']=_0x4267c8['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x520955,this['_continueCurrentRevision']=!0x1);}}else _0xe3cc48&&(this['editor']['model']['document']['history']['version']=Math['max'](_0xe3cc48['toVersion'],this['editor']['model']['document']['history']['version']),_0xe3cc48['fromVersion']===_0xe3cc48['toVersion']?(0x0!==_0xe3cc48['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0xe3cc48['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0xe3cc48['id'],this['_startingVersion']=_0xe3cc48['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',_0x8f0c33=>!_0x8f0c33),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x23b94e=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x5377d9;for(const _0x2effed in _0x23b94e){const _0x40ed74=_0x2effed,_0x41a530=_0x23b94e[_0x40ed74];if('revisionHistoryLicenseKeyValid'==_0x41a530||'revisionHistoryLicenseKeyInvalid'==_0x41a530||'revisionHistoryLicenseKeyExpired'==_0x41a530||'revisionHistoryLicenseKeyDomainLimit'==_0x41a530||'revisionHistoryLicenseKeyNotAllowed'==_0x41a530||'revisionHistoryLicenseKeyEvaluationLimit'==_0x41a530||'revisionHistoryLicenseKeyUsageLimit'==_0x41a530){delete _0x23b94e[_0x40ed74],_0x5377d9=_0x41a530,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x5377d9&&_0x23b94e['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x5377d9&&_0x23b94e['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x5377d9&&_0x23b94e['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x5377d9&&_0x23b94e['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x5377d9&&_0x23b94e['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x5377d9&&_0x23b94e['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x3e7bfc=this['repository']['getRevision'](0x0),_0x40414a=await this['getRevisionDocumentData'](_0x3e7bfc),_0x5b293f=await this['getRevisionRootsAttributes'](_0x3e7bfc);this['_replaceEditorDataWithRevisionData'](_0x40414a,_0x5b293f);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x2a9a04){this['_source']=_0x2a9a04;}async['update'](){const _0x5e39b6=await this['_source']['getLatestVersion']();if(_0x5e39b6>this['currentRevision']['toVersion']){await this['_loadState']();const _0x38fe5f=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x5e39b6});_0x38fe5f['authors']=_0x38fe5f['authorsIds']['map'](_0x416864=>this['editor']['plugins']['get']('Users')['getUser'](_0x416864)),this['currentRevision']['_update'](_0x38fe5f);}}async['saveRevision'](_0x5dae2d={},_0x3847fe=null){const _0x3d3bbe=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x3847fe>this['currentRevision']['toVersion']&&(_0x3847fe=null),null===_0x3847fe&&(_0x3847fe=await this['_source']['getLatestVersion']());const _0x42894b=this['_getFromVersion'](_0x3847fe),_0x553eb8=this['buildRevisionData']({'from':_0x42894b,'to':_0x3847fe});if(this['currentRevision']['toVersion']<_0x3847fe){const _0x101f12=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x3847fe,'to':_0x3847fe});_0x101f12['authors']=[],_0x101f12['authorsIds']=[],_0x101f12['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x101f12,!0x0),delete _0x101f12['authors'],_0x3d3bbe['push'](_0x101f12);}_0x5dae2d['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x5dae2d['name']=_0x5dae2d['name']||null,_0x5dae2d['id']=_0x5dae2d['id']||_0x532896(),_0x5dae2d={..._0x5dae2d,..._0x553eb8};const _0x1d5cfa=this['addRevisionData'](_0x5dae2d);_0x3d3bbe['push'](_0x5dae2d);const _0x5771b4=this['repository']['getIndex'](_0x1d5cfa);if(0x0!==_0x5771b4){const _0x8b211f=this['repository']['getRevision'](_0x5771b4-0x1);if(_0x8b211f['fromVersion']!==_0x3847fe){const _0x4c8470=this['_revisionDataBuilder']['getData'](_0x3847fe,_0x8b211f['toVersion']),_0x53ea99={'id':_0x8b211f['id'],'diffData':_0x4c8470['diffData'],'authorsIds':_0x4c8470['authorsIds'],'authors':_0x4c8470['authorsIds']['map'](_0x5d7641=>this['editor']['plugins']['get']('Users')['getUser'](_0x5d7641)),'fromVersion':_0x3847fe};_0x8b211f===this['currentRevision']&&(_0x53ea99['createdAt']=new Date(_0x5dae2d['createdAt']['getTime']()+0xa)),_0x8b211f['_update'](_0x53ea99,!0x0),delete _0x53ea99['authors'],_0x3d3bbe['push'](_0x53ea99);}}if(this['adapter']){for(const _0x551639 of _0x3d3bbe)this['_bufferUpdate'](_0x551639['id'],_0x551639,!0x0);this['sendBufferedUpdates']();}return _0x1d5cfa;}['addRevisionData'](_0x2e80a6){const _0x202d48=this['repository']['createRevision'](_0x2e80a6);return this['adapter']&&_0x202d48['on']('_update',(_0x3688bc,_0xdbd41c,_0x1d7fec)=>{_0x1d7fec||(this['_bufferUpdate'](_0xdbd41c['id'],_0xdbd41c,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x202d48,this['_findInsertionIndex'](_0x202d48)),_0x202d48;}async['getRevisionDocumentData'](_0x350a1d){return await this['_utils']['loadRevisionData'](_0x350a1d,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x350a1d);}async['getRevisionRootsAttributes'](_0x23bd45){return await this['_utils']['loadRevisionData'](_0x23bd45,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x23bd45);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x2702ff=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x540516=0x0;_0x540516<_0x2702ff['length'];_0x540516++){const _0x130b93=_0x2702ff[_0x540516];let _0x52b01c=!0x1;for(const _0x1c33f7 of Object['keys'](_0x130b93))void 0x0===_0x130b93[_0x1c33f7]?delete _0x130b93[_0x1c33f7]:'id'!==_0x1c33f7&&(_0x52b01c=!0x0);_0x52b01c||(_0x2702ff[_0x540516]=null);}if(_0x2702ff=_0x2702ff['filter'](_0x2bfcb7=>null!==_0x2bfcb7),!_0x2702ff['length'])return;for(let _0x4592b2=0x0;_0x4592b2<_0x2702ff['length'];_0x4592b2++){const _0x1748c1=_0x2702ff[_0x4592b2];void 0x0!==_0x1748c1['fromVersion']&&void 0x0===_0x1748c1['toVersion']&&(_0x1748c1['toVersion']=this['repository']['getRevision'](_0x1748c1['id'])['toVersion']),void 0x0!==_0x1748c1['toVersion']&&void 0x0===_0x1748c1['fromVersion']&&(_0x1748c1['fromVersion']=this['repository']['getRevision'](_0x1748c1['id'])['fromVersion']);}const _0x36b8af=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x2702ff,_0x36b8af)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x5d372d=>{if(_0x5d372d){for(const _0x15497f of _0x5d372d)this['setRevisionData']({'id':_0x15497f['id'],'createdAt':_0x15497f['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0x1cdf43=null,from:_0x21385a=null,to:_0x438429=null}){_0x21385a=null!==_0x21385a?_0x21385a:_0x1cdf43['fromVersion'],_0x438429=null!==_0x438429?_0x438429:_0x1cdf43['toVersion'];const _0x2d843c=this['_revisionDataBuilder']['getData'](_0x21385a,_0x438429),_0x28cc6e={'diffData':_0x2d843c['diffData'],'authorsIds':_0x2d843c['authorsIds'],'fromVersion':_0x21385a,'toVersion':_0x438429};if(!_0x1cdf43||_0x438429!==_0x1cdf43['toVersion']){const _0x58ce99=_0x438429-0x1,_0x5e13d7=this['_source']['history']['getOperation'](_0x58ce99);_0x28cc6e['createdAt']=_0x5e13d7&&_0x5e13d7['createdAt']||new Date();}if(this['_loadedStateData']&&_0x21385a===this['_loadedStateData']['fromVersion']){for(const _0x2c6c46 of this['_loadedStateData']['authors'])_0x28cc6e['authorsIds']['includes'](_0x2c6c46['id'])||_0x28cc6e['authorsIds']['push'](_0x2c6c46['id']);}return _0x28cc6e;}['_bufferUpdate'](_0x53f216,_0x1b6827,_0x2b95c6){if(this['_bufferedUpdates']['has'](_0x53f216)){const _0x541a2a=this['_bufferedUpdates']['get'](_0x53f216);_0x1b6827=_0x2b95c6?{..._0x541a2a,..._0x1b6827}:{..._0x1b6827,..._0x541a2a};}this['_bufferedUpdates']['set'](_0x53f216,_0x1b6827);}['setRevisionData'](_0x724595){const _0x503256=this['repository']['getRevision'](_0x724595['id']);if(_0x724595['createdAt']&&(_0x724595['createdAt']=new Date(_0x724595['createdAt'])),_0x724595['authorsIds']){const _0x382d9c=this['editor']['plugins']['get']('Users');_0x724595['authors']=_0x724595['authorsIds']['map'](_0x11cea2=>_0x382d9c['getUser'](_0x11cea2));}_0x503256['_update'](_0x724595,!0x0);}['_createInitialRevision'](_0x5bc260){const _0x4aab5f=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x4aab5f)this['_initialRevisionId']=_0x4aab5f['id'];else{const _0x120adb=!this['editor']['model']['document']['roots']['find'](_0x1aa0e3=>this['editor']['model']['hasContent'](_0x1aa0e3)),_0x5af50c=this['editor']['plugins']['get']('Users')['me']['id'],_0x534fd6=m(this['editor']['locale'],_0x120adb?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x5bc260,'to':_0x5bc260,'id':this['_initialRevisionId'],'name':_0x534fd6,'creatorId':_0x5af50c});}}['_createCurrentRevision'](_0x4b6530){const _0x3eef85=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x3eef85),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x4b6530,'to':_0x4b6530,'id':_0x3eef85,'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'](_0x51c113,_0x291039){let _0x56fdf0=this['editor']['config']['get']('initialData'),_0x57f866=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x56fdf0){_0x56fdf0={};for(const _0x256f15 of this['editor']['model']['document']['getRootNames']())_0x56fdf0[_0x256f15]='';}if('string'==typeof _0x56fdf0&&(_0x56fdf0={'main':_0x56fdf0}),void 0x0===_0x57f866){_0x57f866={};for(const _0x19e0f6 of this['editor']['model']['document']['getRootNames']())_0x57f866[_0x19e0f6]={};}let _0x52e77a=!0x1;const _0x24a0cb=Object['keys'](_0x56fdf0),_0x5182f0=Object['keys'](_0x51c113);for(const _0x3d426e of _0x24a0cb){if(_0x56fdf0[_0x3d426e]!==_0x51c113[_0x3d426e]&&''!==_0x56fdf0[_0x3d426e]['trim']()){_0x52e77a=!0x0;break;}if(!_0x3c0bf9(_0x57f866[_0x3d426e],_0x291039[_0x3d426e])&&Object['keys'](_0x57f866[_0x3d426e])['length']>0x0){_0x52e77a=!0x0;break;}}_0x52e77a||(_0x52e77a=_0x5182f0['some'](_0x2342a2=>!this['editor']['model']['document']['getRoot'](_0x2342a2))),_0x52e77a&&_0x47c187('editor-initial-data-replaced-with-revision-data',{'editorData':_0x56fdf0,'editorRootsAttributes':_0x57f866,'revisionData':_0x51c113,'revisionRootsAttributes':_0x291039}),this['editor']['config']['set']('initialData',_0x51c113),this['editor']['config']['set']('rootsAttributes',_0x291039);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x58ed7e=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x58ed7e['add'](m(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x4ff9a7){const _0x56411c=this['repository']['getRevisions']();_0x56411c['reverse']();let _0x43b13e=0x0;for(;_0x43b13e<_0x56411c['length'];){const _0x574fb9=_0x56411c[_0x43b13e];if(_0x574fb9===this['currentRevision']){_0x43b13e++;continue;}if(_0x574fb9['id']===this['_initialRevisionId'])break;const _0x1644d4=_0x4ff9a7['toVersion']-_0x574fb9['toVersion']||_0x4ff9a7['fromVersion']-_0x574fb9['fromVersion'];if(_0x1644d4>0x0)break;if(_0x1644d4<0x0)_0x43b13e++;else{if(!_0x4ff9a7['creator']&&_0x574fb9['creator'])break;if(_0x574fb9['creator']||!_0x4ff9a7['creator']){if(_0x4ff9a7['createdAt']>_0x574fb9['createdAt'])break;_0x43b13e++;}else _0x43b13e++;}}return _0x43b13e;}['_getFromVersion'](_0x1318ac){const _0x3192c2=this['repository']['getRevisions']();_0x3192c2['reverse'](),_0x3192c2['shift']();const _0x3fffeb=_0x3192c2['find'](_0x389d38=>_0x389d38['toVersion']<=_0x1318ac)['toVersion'];return _0x3fffeb<this['_startingVersion']?this['_startingVersion']:_0x3fffeb;}['_makeRevision']({name:_0x54b5b4,from:_0x32ca53,to:_0x2c619e,creatorId:_0x5b6155,id:_0x791788}){const _0x1b9ce6=this['buildRevisionData']({'from':_0x32ca53,'to':_0x2c619e});_0x1b9ce6['name']=_0x54b5b4,_0x1b9ce6['creatorId']=_0x5b6155,_0x1b9ce6['id']=_0x791788;const _0x5ecb93=this['addRevisionData'](_0x1b9ce6);return this['adapter']&&this['_bufferUpdate'](_0x1b9ce6['id'],_0x1b9ce6,!0x0),_0x5ecb93;}['_setConversion'](){this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'});}}class x{['editor'];['source'];['_savedMetaData'];['_lastFrom'];['_lastTo'];['_markers'];['_diffRoots'];['_diffRootsAttributes'];['_baseRoots'];['_baseRootsAttributes'];['_idsRoots'];['_baseIdsRoots'];['_touched'];['_touchedMarkers'];['_touchedRoots'];['_revisionId'];['_startingRevisionId'];constructor(_0x455bf9){this['editor']=_0x455bf9,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'](_0x23359e){this['source']=_0x23359e;const _0x369ab4=new Map(),_0x5197f2=new Map(),_0x13c9bc=this['editor']['model']['document']['roots']['map'](_0x2dc1d7=>_0x2dc1d7['rootName']);for(const _0x15be98 of _0x13c9bc){const _0x48cca6=this['editor']['model']['document']['getRoot'](_0x15be98),_0x1ee668=K(_0x48cca6);_0x369ab4['set'](_0x15be98,_0x1ee668),_0x5197f2['set'](_0x15be98,Object['fromEntries'](_0x48cca6['getAttributes']()));}const _0x4b1a57=Array['from'](this['editor']['model']['markers'])['map'](_0x5b9ac3=>[_0x5b9ac3['name'],_0x5b9ac3['getRange']()]),_0x2eed4b=this['source']['version'];this['_saveMetaData'](_0x2eed4b,_0x369ab4,_0x4b1a57,_0x5197f2),this['_startingRevisionId']=this['_revisionId'];const _0x14fff3=new Map(),_0x293d4e=new Map();for(const _0x145b88 of _0x13c9bc){const _0x304249=N(_0x145b88);_0x14fff3['set'](_0x145b88,_0x304249),_0x293d4e['set'](_0x145b88,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x14fff3,[],_0x293d4e);}['getData'](_0x2442fd,_0x1678c6){if(this['_lastFrom']===_0x2442fd&&this['_lastTo']<=_0x1678c6)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x1678c6,!0x0);else{if(!this['_savedMetaData']['has'](_0x2442fd)){const _0x2734ff=this['_getPreviousFrom'](_0x2442fd);this['_calculateMetaData'](_0x2734ff,_0x2442fd,!0x1);}this['_calculateMetaData'](_0x2442fd,_0x1678c6,!0x0);}return this['_lastFrom']=_0x2442fd,this['_lastTo']=_0x1678c6,this['_getState']();}['loadState'](_0x3ef080){if(!this['_savedMetaData']['has'](_0x3ef080['fromVersion'])){const _0x265897=this['_getPreviousFrom'](_0x3ef080['fromVersion']);this['_calculateMetaData'](_0x265897,_0x3ef080['fromVersion'],!0x1);}this['_calculateMetaData'](_0x3ef080['fromVersion'],_0x3ef080['toVersion'],!0x1);const _0x225578=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x3ef080['fromVersion'],this['_lastTo']=_0x3ef080['toVersion'];for(const _0x3527dd in _0x3ef080['diffData']){const _0x583e71=_0x3ef080['diffData'][_0x3527dd]['attachChange'],_0x6d5933=_0x83ca90(_0x3ef080['diffData'][_0x3527dd]['attributesBefore'])||{},_0x515379=_0x225578['_makeModelFromViewString'](_0x3ef080['diffData'][_0x3527dd]['deletions']);_0x515379['rootName']=_0x3527dd,_0x515379['_isAttached']=!_0x583e71||!_0x583e71['isAttached'],_0x515379['isAttached']=()=>_0x515379['_isAttached'],this['_baseRoots']['set'](_0x3527dd,_0x515379),this['_baseRootsAttributes']['set'](_0x3527dd,_0x6d5933),_0x583e71&&this['_touchedRoots']['set'](_0x3527dd,_0x583e71);const _0x58e1eb=this['_makeIdsRoot'](_0x515379);this['_baseIdsRoots']['set'](_0x3527dd,_0x58e1eb);for(const [_0x26707d,_0x170f6b]of _0x515379['markers']){if(!_0x26707d['startsWith']('revision:'))continue;const _0xe352e2=_0x26707d['split'](':')[0x2];for(const _0x5c6971 of _0x170f6b['getWalker']({'singleCharacters':!0x0})){const _0x34822a=this['_getVidAttributeName'](_0x5c6971),_0x34add7='elementEnd'==_0x5c6971['type']?_0x5c6971['previousPosition']['path']['slice'](0x0,-0x1):_0x5c6971['previousPosition']['path'],_0xa40361=_0x58e1eb['getNodeByPath'](_0x34add7)['getAttribute'](_0x34822a);this['_touched']['set'](_0xa40361,{'userId':_0xe352e2});}_0x515379['markers']['delete'](_0x26707d);}}this['_startingRevisionId']=this['_revisionId'];const _0x5e3883=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x23e068=>!this['_touched']['has'](_0x23e068));let _0xfa8a6b=0x0;const _0x5b12bb=new Map();for(const _0x4e1b1a in _0x3ef080['diffData']){const _0x537891=_0x3ef080['diffData'][_0x4e1b1a]['attachChange'],_0x384aa5=_0x83ca90(_0x3ef080['diffData'][_0x4e1b1a]['attributesAfter'])||{},_0x563285=_0x225578['_makeModelFromViewString'](_0x3ef080['diffData'][_0x4e1b1a]['insertions']);_0x563285['rootName']=_0x4e1b1a,_0x563285['_isAttached']=!_0x537891||_0x537891['isAttached'],_0x563285['isAttached']=()=>_0x563285['_isAttached'],this['_diffRoots']['set'](_0x4e1b1a,_0x563285),this['_diffRootsAttributes']['set'](_0x4e1b1a,_0x384aa5);const _0x2e93dd=this['_makeIdsRoot'](_0x563285,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x4e1b1a,_0x2e93dd),_0x5b12bb['set'](_0x4e1b1a,_0x563285['isAttached']()?_0x384aa5:{});for(const [_0x3d32df,_0x38c07d]of _0x563285['markers']){if(!_0x3d32df['startsWith']('revision:'))continue;const _0x3dd72f=_0x3d32df['split'](':')[0x2];for(const _0x2f1880 of _0x38c07d['getWalker']({'singleCharacters':!0x0})){const _0x3d131d=this['_getVidAttributeName'](_0x2f1880),_0x476b53=this['_revisionId']++,_0x188fc2='elementEnd'==_0x2f1880['type']?_0x2f1880['previousPosition']['path']['slice'](0x0,-0x1):_0x2f1880['previousPosition']['path'];_0x2e93dd['getNodeByPath'](_0x188fc2)['_setAttribute'](_0x3d131d,_0x476b53),this['_touched']['set'](_0x476b53,{'userId':_0x3dd72f});}_0x563285['markers']['delete'](_0x3d32df);}for(const _0x1d6593 of this['editor']['model']['createRangeIn'](_0x563285)['getWalker']({'singleCharacters':!0x0})){const _0x534ee3=this['_getVidAttributeName'](_0x1d6593),_0x1b4013='elementEnd'==_0x1d6593['type']?_0x1d6593['previousPosition']['path']['slice'](0x0,-0x1):_0x1d6593['previousPosition']['path'],_0x136197=_0x2e93dd['getNodeByPath'](_0x1b4013);_0x136197['getAttribute'](_0x534ee3)>0x0||_0x136197['_setAttribute'](_0x534ee3,_0x5e3883[_0xfa8a6b++]);}for(const [_0x1e9498,_0x182c4f]of _0x563285['markers'])_0x1e9498['startsWith']('revision:')||this['_markers']['set'](_0x1e9498,_0x182c4f);}const {roots:_0x5e87bd}=this['_savedMetaData']['get'](_0x3ef080['fromVersion']),{roots:_0x4ff668}=this['_savedMetaData']['get'](_0x3ef080['toVersion']),_0x4f3ef2=K(_0x5e87bd['get']('$graveyard'));this['_baseRoots']['set']('$graveyard',_0x4f3ef2),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x4f3ef2,Number['NEGATIVE_INFINITY']));const _0x550458=K(_0x4ff668['get']('$graveyard'));this['_diffRoots']['set']('$graveyard',_0x550458),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x550458));const _0x3e171a=Array['from'](this['_diffRoots'])['map'](([_0x4c1a62,_0x1017de])=>[_0x4c1a62,K(_0x1017de)]);this['_saveMetaData'](this['_lastTo'],_0x3e171a,this['_markers'],_0x5b12bb);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0x51437d,_0x225239,_0x3eeff0,_0x59422d){const _0x4621a9=new Map(_0x225239),_0x51a746=new Map(_0x83ca90(_0x59422d)),_0xb7266f=new Map();for(const [_0x13f2a4,_0x1da3da]of _0x3eeff0)_0xb7266f['set'](_0x13f2a4,{'start':_0x1da3da['start']['clone'](),'end':_0x1da3da['end']['clone'](),'rootName':_0x1da3da['root']['rootName']});this['_savedMetaData']['set'](_0x51437d,{'roots':_0x4621a9,'markers':_0xb7266f,'rootsAttributes':_0x51a746});}['_removeMetaData'](_0x254c16){this['_savedMetaData']['delete'](_0x254c16);}['_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'](_0x2869b5,_0xe4cc53=null){let _0x1bf7a3=null;_0x2869b5['is']('documentFragment')||(_0x1bf7a3=new _0x36b445(_0x2869b5['name'],{'vid_start':null===_0xe4cc53?this['_revisionId']++:_0xe4cc53++}));const _0x25e7c7=[];for(const _0x1ab04b of _0x2869b5['getChildren']())if(_0x1ab04b['is']('element')){_0x25e7c7['push'](this['_makeIdsRoot'](_0x1ab04b,_0xe4cc53));const _0x280ffb=_0x25e7c7[_0x25e7c7['length']-0x1];null!==_0xe4cc53&&(_0xe4cc53=_0x280ffb['is']('element','$text')?_0x280ffb['getAttribute']('vid')+0x1:_0x280ffb['getAttribute']('vid_end')+0x1);}else{for(let _0x54a2eb=0x0;_0x54a2eb<_0x1ab04b['offsetSize'];_0x54a2eb++)_0x25e7c7['push'](new _0x36b445('$text',{'vid':null===_0xe4cc53?this['_revisionId']++:_0xe4cc53++}));}if(_0x2869b5['is']('documentFragment')){const _0x59bf46=N(_0x2869b5['rootName']);return _0x59bf46['_insertChild'](0x0,_0x25e7c7),_0x59bf46;}return _0x1bf7a3['_setAttribute']('vid_end',null===_0xe4cc53?this['_revisionId']++:_0xe4cc53++),_0x1bf7a3['_insertChild'](0x0,_0x25e7c7),_0x1bf7a3;}['_calculateMetaData'](_0x2233f2,_0x5b0fdc,_0x18c2a3){this['_reset']();const {roots:_0x151a9e,markers:_0x231aa2,rootsAttributes:_0x2f5d8b}=this['_savedMetaData']['get'](_0x2233f2);this['_baseRoots']=new Map(_0x151a9e),this['_baseRootsAttributes']=new Map(_0x83ca90(_0x2f5d8b));for(const [_0x27ea13,_0x5dc5d2]of this['_baseRoots'])if('$graveyard'!==_0x27ea13&&(this['_diffRoots']['set'](_0x27ea13,K(_0x5dc5d2)),this['_diffRootsAttributes']=new Map(_0x83ca90(_0x2f5d8b)),_0x18c2a3)){const _0x55a298=this['_revisionId'];this['_idsRoots']['set'](_0x27ea13,this['_makeIdsRoot'](_0x5dc5d2)),this['_baseIdsRoots']['set'](_0x27ea13,this['_makeIdsRoot'](_0x5dc5d2,_0x55a298));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',K(this['_baseRoots']['get']('$graveyard'))),_0x18c2a3&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x4f8b0e,_0x1fe864]of _0x231aa2){const _0x369834=this['_baseRoots']['get'](_0x1fe864['rootName']),_0xcb6465=this['_diffRoots']['get'](_0x1fe864['rootName']),_0x54fa77=new _0xb3cd0f(this['_fixPosition'](_0x1fe864['start'],_0x369834),this['_fixPosition'](_0x1fe864['end'],_0x369834)),_0x1e1c95=this['_fixRange'](_0x54fa77,_0xcb6465);_0x369834['markers']['set'](_0x4f8b0e,_0x54fa77),this['_markers']['set'](_0x4f8b0e,_0x1e1c95);}this['_applyOperations'](_0x2233f2,_0x5b0fdc,_0x18c2a3);}['_applyOperations'](_0x254d82,_0x16d251,_0x244468){for(const _0x44d1ba of this['source']['getOperations'](_0x254d82,_0x16d251))this['_handleOperation'](_0x44d1ba,_0x244468);for(const _0x322f96 of this['_diffRoots']['values']())_0x322f96['markers']['clear']();for(const [_0x275bfe,_0x2b5b5d]of this['_markers']){this['_diffRoots']['get'](_0x2b5b5d['root']['rootName'])['markers']['set'](_0x275bfe,_0x2b5b5d['clone']());}const _0x143413=new Map(),_0x36e317=new Map();for(const [_0x177330,_0x1df78e]of this['_diffRoots'])_0x143413['set'](_0x177330,K(_0x1df78e)),_0x36e317['set'](_0x177330,this['_diffRootsAttributes']['get'](_0x177330));this['_saveMetaData'](_0x16d251,_0x143413,this['_markers'],_0x36e317);}['_getPreviousFrom'](_0xf89bb3){const _0x1cc276=Array['from'](this['_savedMetaData']['keys']());_0x1cc276['sort']((_0x7cf7,_0x569cf2)=>_0x7cf7-_0x569cf2),_0x1cc276['reverse']();for(const _0x5027d5 of _0x1cc276)if(_0x5027d5<_0xf89bb3)return _0x5027d5;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x450716,_0x28bb56){const _0x2e89a8=Array['from'](_0x28bb56['markers'])['map'](([_0x233fe8,_0x2a6d36])=>[_0x233fe8,this['_fixRange'](_0x2a6d36,_0x450716)]);_0x450716['markers']=new Map(_0x2e89a8);}['_transformMarkers'](_0x3d69b6){for(const _0xde39d8 of this['_markers']['values']()){const _0x146838=_0xde39d8['getTransformedByOperation'](_0x3d69b6),_0x2d0eb2=_0xb3cd0f['_createFromRanges'](_0x146838);_0xde39d8['start']=_0x2d0eb2['start'],_0xde39d8['end']=_0x2d0eb2['end'];}}['_handleOperation'](_0x11269e,_0x21d0bb){if('addRoot'!=_0x11269e['type']&&'detachRoot'!=_0x11269e['type']){if('insert'==_0x11269e['type']){const _0x2e2502=_0x11269e['position']['root']['rootName'];this['_diffRoots']['has'](_0x2e2502)||(this['_diffRoots']['set'](_0x2e2502,N(_0x2e2502,!0x0)),this['_diffRootsAttributes']['set'](_0x2e2502,{}),_0x21d0bb&&this['_idsRoots']['set'](_0x2e2502,N(_0x2e2502,!0x0)));}else{if('addRootAttribute'==_0x11269e['type']||'removeRootAttribute'==_0x11269e['type']||'changeRootAttribute'==_0x11269e['type'])return void this['_handleRootAttributeOperation'](_0x11269e);'marker'==_0x11269e['type']&&this['_handleMarkerOperation'](_0x11269e);}if('marker'!==_0x11269e['type']){const _0x2269fe=this['_cloneOperation'](_0x11269e,this['_diffRoots']);_0x2269fe['_execute'](),this['_transformMarkers'](_0x2269fe);}if(_0x21d0bb)switch(_0x11269e['type']){case'insert':this['_handleInsertOperation'](_0x11269e);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x11269e);break;case'merge':this['_handleMergeOperation'](_0x11269e);break;case'split':this['_handleSplitOperation'](_0x11269e);}}else this['_handleRootOperation'](_0x11269e,_0x21d0bb);}['_cloneOperation'](_0x1d91bf,_0x217bbf){const _0x5b4b5e=_0x1d91bf['clone']();return _0x5b4b5e['_authorId']=_0x1d91bf['_authorId'],this['_fixOperation'](_0x5b4b5e,_0x217bbf),_0x5b4b5e;}['_getBaseVids'](_0x4d49ad){return _0x4d49ad['map'](_0x1339d1=>{const _0x379be9=this['_getVidAttributeName'](_0x1339d1);return Number(_0x1339d1['item']['getAttribute'](_0x379be9));});}['_generateTape'](_0x13485,_0x2156c2){if(_0x13485['is']('element','$text'))_0x2156c2['push']({'item':_0x13485,'type':'text'});else{_0x13485['is']('element')&&_0x2156c2['push']({'item':_0x13485,'type':'elementStart'});for(const _0x1830d7 of _0x13485['getChildren']())this['_generateTape'](_0x1830d7,_0x2156c2);_0x13485['is']('element')&&_0x2156c2['push']({'item':_0x13485,'type':'elementEnd'});}return _0x2156c2;}['_getState'](){const _0x48c365=new Map(this['_touched']),_0x43767a=new Map(_0x48c365),_0x29cb9a=new Map(),_0x36c9bb={'insertions':{},'deletions':{}},_0x37d1d4={'insertions':{},'deletions':{}},_0x38424f=new Map(),_0x33bab5=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x33bab5['delete']('$graveyard');for(const _0x23630e of _0x33bab5){const _0x45bb33=this['_diffRoots']['get'](_0x23630e)||N(_0x23630e,!0x1),_0x42de8a=this['_baseRoots']['get'](_0x23630e)||N(_0x23630e,!0x1);_0x45bb33['isAttached']()||_0x42de8a['isAttached']()?(_0x36c9bb['insertions'][_0x23630e]=K(_0x45bb33),_0x36c9bb['deletions'][_0x23630e]=K(_0x42de8a),this['_copyMarkers'](_0x36c9bb['deletions'][_0x23630e],_0x42de8a),this['_copyMarkers'](_0x36c9bb['insertions'][_0x23630e],_0x45bb33),_0x37d1d4['insertions'][_0x23630e]=this['_generateTape'](this['_idsRoots']['get'](_0x23630e),[]),_0x37d1d4['deletions'][_0x23630e]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x23630e)||N(_0x23630e,!0x1),[])):_0x33bab5['delete'](_0x23630e);}for(const _0x349884 of _0x33bab5){const _0x53cc23=_0x37d1d4['insertions'][_0x349884];for(const _0x3fa61d of _0x53cc23){const _0x1b103b=this['_getVidAttributeName'](_0x3fa61d),_0xbcb78a=_0x3fa61d['item']['getAttribute'](_0x1b103b);_0x43767a['delete'](_0xbcb78a),_0xbcb78a>=this['_startingRevisionId']&&_0x29cb9a['set'](_0xbcb78a,_0x48c365['get'](_0xbcb78a));}}for(const _0x1757b3 of _0x33bab5){const _0x32db57=_0x37d1d4['insertions'][_0x1757b3],_0x507775=this['_getBaseVids'](_0x37d1d4['deletions'][_0x1757b3]);let _0x4893b0=0x0;for(const _0x2bbd4c of _0x32db57){const _0x3d1886=this['_getVidAttributeName'](_0x2bbd4c),_0xa8a885=_0x2bbd4c['item']['getAttribute'](_0x3d1886);if(!_0x29cb9a['has'](_0xa8a885)&&!_0x38424f['has'](_0xa8a885)){if(_0x43767a['has'](_0xa8a885))_0x4893b0++;else{if(_0xa8a885!=_0x507775[_0x4893b0]){const _0x5b9d03=_0x48c365['get'](_0xa8a885)||_0x48c365['get'](_0x507775[_0x4893b0]);for(;_0xa8a885!=_0x507775[_0x4893b0];)_0x43767a['has'](_0x507775[_0x4893b0])||(_0x38424f['set'](_0x507775[_0x4893b0],_0x5b9d03),_0x48c365['set'](_0x507775[_0x4893b0],_0x5b9d03)),_0x4893b0++;}_0x4893b0++;}}}}for(const _0x37bd66 of _0x33bab5){const _0x26da32=_0x37d1d4['insertions'][_0x37bd66];for(const _0x2b5502 of _0x26da32){const _0xc5c5ef=this['_getVidAttributeName'](_0x2b5502),_0x449b9c=_0x2b5502['item']['getAttribute'](_0xc5c5ef);if(_0x38424f['has'](_0x449b9c)){const _0x320267=_0x38424f['get'](_0x449b9c);_0x43767a['has'](_0x449b9c)||_0x43767a['set'](_0x449b9c,{..._0x320267}),_0x29cb9a['set'](_0x449b9c,{..._0x320267});}}}for(const _0x45f9f6 of _0x43767a['keys']())_0x45f9f6>=this['_startingRevisionId']&&_0x43767a['delete'](_0x45f9f6);const _0x146735=new Map();for(const _0x114d40 of _0x33bab5){let _0x42b8c1=_0x37d1d4['insertions'][_0x114d40];for(const _0xf561b0 of _0x42b8c1)if(_0xf561b0['item']['is']('element','tableCell')){const _0x30a3b0=this['_getVidAttributeName'](_0xf561b0),_0xf11172=_0xf561b0['item']['getAttribute'](_0x30a3b0);if(_0x29cb9a['has'](_0xf11172)){const _0xb2905d=_0xf561b0['item']['parent']['parent']['getAttribute']('vid_start'),_0x203314=_0x146735['get'](_0xb2905d)||new Set();_0x203314['add'](_0x29cb9a['get'](_0xf11172)['userId']),_0x146735['set'](_0xb2905d,_0x203314);}}_0x42b8c1=_0x37d1d4['deletions'][_0x114d40];for(const _0x1dc351 of _0x42b8c1)if(_0x1dc351['item']['is']('element','tableCell')){const _0x239fb7=this['_getVidAttributeName'](_0x1dc351),_0x5410e3=_0x1dc351['item']['getAttribute'](_0x239fb7);if(_0x43767a['has'](_0x5410e3)){const _0x58d5a3=_0x1dc351['item']['parent']['parent']['getAttribute']('vid_start'),_0x333f25=_0x146735['get'](_0x58d5a3)||new Set();_0x333f25['add'](_0x43767a['get'](_0x5410e3)['userId']),_0x146735['set'](_0x58d5a3,_0x333f25);}}for(const _0x24b095 of _0x146735['keys']())(_0x29cb9a['has'](_0x24b095)||_0x43767a['has'](_0x24b095))&&_0x146735['delete'](_0x24b095);}for(const _0xd3c3f6 of _0x33bab5){const _0x3a141c=_0x37d1d4['insertions'][_0xd3c3f6];let _0x2e16c3=null,_0x27723c=null;for(const _0x4327ed of _0x3a141c){const _0x26e106=this['_getVidAttributeName'](_0x4327ed),_0x1824d2=_0x4327ed['item']['getAttribute'](_0x26e106),_0x3e44b8=_0x146735['get'](_0x1824d2);_0x3e44b8&&'elementStart'==_0x4327ed['type']&&(_0x2e16c3=Array['from'](_0x3e44b8)[0x0],_0x27723c=_0x4327ed['item']['getAttribute']('vid_end')),_0x2e16c3&&(_0x43767a['set'](_0x1824d2,{'userId':_0x2e16c3}),_0x29cb9a['set'](_0x1824d2,{'userId':_0x2e16c3})),_0x1824d2==_0x27723c&&(_0x2e16c3=null,_0x27723c=null);}}const _0x567751={},_0x321465=new Set();for(const _0x1dabdb of _0x33bab5){const _0x423266=_0x36c9bb['deletions'][_0x1dabdb],_0x28bea9=_0x36c9bb['insertions'][_0x1dabdb];for(const {userId:_0x1ba1a1}of this['_touchedMarkers']['values']())null!==_0x1ba1a1&&_0x321465['add'](_0x1ba1a1);for(const {userId:_0x215bec}of this['_touchedRoots']['values']())null!==_0x215bec&&_0x321465['add'](_0x215bec);this['_markChanges'](_0x28bea9,_0x37d1d4['insertions'][_0x1dabdb],_0x29cb9a,'insertion',_0x321465),this['_markChanges'](_0x423266,_0x37d1d4['deletions'][_0x1dabdb],_0x43767a,'deletion',_0x321465),_0x567751[_0x1dabdb]={'insertions':this['_prepareViewToSave'](_0x28bea9),'deletions':this['_prepareViewToSave'](_0x423266),'attachChange':this['_touchedRoots']['get'](_0x1dabdb)||null,'attributesBefore':_0x83ca90(this['_baseRootsAttributes']['get'](_0x1dabdb))||{},'attributesAfter':_0x83ca90(this['_diffRootsAttributes']['get'](_0x1dabdb))};}return{'diffData':_0x567751,'authorsIds':Array['from'](_0x321465)};}['_processRootBeforeSave'](_0x14530f){for(const [,_0x431705]of _0x14530f['markers']){const _0x577e83=_0x431705['start']['getAncestors']()['filter'](_0x49f7b1=>'tableCell'==_0x49f7b1['name']);for(const _0x450a98 of _0x577e83)0x1==_0x450a98['childCount']&&_0x450a98['getChild'](0x0)['is']('element','paragraph')&&_0x450a98['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x11c429){this['_processRootBeforeSave'](_0x11c429);const _0x59d0b2=this['editor']['data']['toView'](_0x11c429,{}),_0x226ed6=Array['from'](_0x59d0b2['getChildren']())['map'](_0x5cbef2=>this['_getViewJson'](_0x5cbef2));return JSON['stringify'](_0x226ed6);}['_getViewJson'](_0x519ebc){if(_0x519ebc['is']('$text'))return _0x519ebc['data'];{const _0x544f62=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0x34b89b=_0x519ebc,_0x1d6b90=this['editor']['data']['htmlProcessor']['domConverter'],_0x4eb9ca={'type':_0x544f62['_getTypeCharForViewElement'](_0x34b89b),'name':_0x34b89b['name'],'attributes':Array['from'](_0x34b89b['getAttributes']()),'children':Array['from'](_0x34b89b['getChildren']())['map'](_0x30b9c9=>this['_getViewJson'](_0x30b9c9))};if(_0x519ebc['is']('uiElement')&&'$comment'!=_0x519ebc['name']){const _0x1f6b23=_0x519ebc['render'](_0x1d6b90['domDocument'],_0x1d6b90);_0x4eb9ca['children']['push'](_0x1f6b23['outerHTML']);}else{if(_0x519ebc['is']('rawElement')){const _0x31314a=_0x1d6b90['domDocument']['createElement'](_0x34b89b['name']);_0x519ebc['render'](_0x31314a,_0x1d6b90),_0x4eb9ca['children']['push'](_0x31314a['innerHTML']);}}const _0x4350b3=Array['from'](_0x34b89b['getCustomProperties']());_0x4350b3['length']>0x0&&(_0x4eb9ca['customProperties']=_0x4350b3);const _0x279f30=_0x34b89b['getFillerOffset']();return null!==_0x279f30&&(_0x4eb9ca['fillerOffset']=_0x279f30),_0x4eb9ca;}}['_markChanges'](_0xb9e136,_0x518b55,_0x359d2c,_0x396d10,_0x39705b){let _0x59ce78=null,_0x2bc6f7=null,_0x4b9bae=0x0;const _0x43481a=this['editor']['model'];for(let _0xcfe135=0x0;_0xcfe135<_0x518b55['length'];_0xcfe135++){const _0x4f3648=this['_getVidAttributeName'](_0x518b55[_0xcfe135]),_0x1ecd27=_0x518b55[_0xcfe135]['item']['getAttribute'](_0x4f3648),_0x2541b7=_0x359d2c['get'](_0x1ecd27),_0x1fd5e0=_0xcfe135==_0x518b55['length']-0x1;(!_0x59ce78&&_0x2541b7&&(_0x59ce78=_0x2541b7,_0x2bc6f7=_0x518b55[_0xcfe135]),_0x59ce78&&(!_0x2541b7||_0x2541b7['userId']!=_0x59ce78['userId']))&&(_0x917453(_0x2541b7,P(_0x2bc6f7,_0xb9e136,_0x43481a),P(_0x518b55[_0xcfe135],_0xb9e136,_0x43481a)),_0x59ce78=_0x2541b7||null,_0x2bc6f7=_0x2541b7?_0x518b55[_0xcfe135]:null),_0x59ce78&&_0x1fd5e0&&_0x917453(_0x2541b7,P(_0x2bc6f7,_0xb9e136,_0x43481a),V(_0x518b55[_0xcfe135],_0xb9e136,_0x43481a));}function _0x917453(_0x50c3b5,_0x2adedc,_0x5724db){const _0x448be5=_0x59ce78['userId'],_0x1791c8='revision:'+_0x396d10+':'+_0x448be5+':'+_0x4b9bae++,_0x32f692=_0x43481a['createRange'](_0x2adedc,_0x5724db);_0xb9e136['markers']['set'](_0x1791c8,_0x32f692),null!==_0x448be5&&_0x39705b['add'](_0x448be5);}}['_getVidAttributeName'](_0x59cba4){switch(_0x59cba4['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x487c1f,_0x206f9f){_0x487c1f['baseVersion']=null;for(const _0x46a900 in _0x487c1f){const _0x2dbb13=_0x487c1f[_0x46a900];if(_0x2dbb13 instanceof _0x517828){const _0x4a9100=_0x206f9f['get'](_0x2dbb13['root']['rootName']);_0x487c1f[_0x46a900]=this['_fixPosition'](_0x2dbb13,_0x4a9100);}if(_0x2dbb13 instanceof _0xb3cd0f){const _0xaf12b3=_0x206f9f['get'](_0x2dbb13['root']['rootName']);_0x487c1f[_0x46a900]=this['_fixRange'](_0x2dbb13,_0xaf12b3);}'root'===_0x46a900&&(_0x487c1f['root']=_0x206f9f['get'](_0x487c1f['root']['rootName']));}}['_fixRange'](_0x515121,_0x539921){return this['editor']['model']['createRange'](this['_fixPosition'](_0x515121['start'],_0x539921),this['_fixPosition'](_0x515121['end'],_0x539921));}['_fixPosition'](_0x4254d1,_0x3d717c){return this['editor']['model']['createPositionFromPath'](_0x3d717c,_0x4254d1['path'],_0x4254d1['stickiness']);}['_handleInsertOperation'](_0x3bab9e){const _0x5eaaae=this['_idsRoots']['get'](_0x3bab9e['position']['root']['rootName']),_0x435620=this['_fixPosition'](_0x3bab9e['position'],_0x5eaaae),_0x27ee77=null===_0x3bab9e['_authorId']?null:_0x3bab9e['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x1b53e7=_0x435620['parent'],_0x4b9c92=this['_revisionId'],_0x3639d7=[];for(const _0x2a1655 of _0x3bab9e['nodes'])if(_0x2a1655['is']('element'))_0x3639d7['push'](this['_makeIdsRoot'](_0x2a1655));else{for(let _0x1b6d6e=0x0;_0x1b6d6e<_0x2a1655['offsetSize'];_0x1b6d6e++)_0x3639d7['push'](new _0x36b445('$text',{'vid':this['_revisionId']++}));}const _0x90ff4e=this['_revisionId'];for(let _0x3a08e3=_0x4b9c92;_0x3a08e3<_0x90ff4e;_0x3a08e3++)this['_touched']['set'](_0x3a08e3,{'userId':_0x27ee77});_0x1b53e7['_insertChild'](_0x435620['offset'],_0x3639d7);}['_handleMoveOperation'](_0x2d30c5){(_0x2d30c5=this['_cloneOperation'](_0x2d30c5,this['_idsRoots']))['_execute']();const _0xa1ca57=null===_0x2d30c5['_authorId']?null:_0x2d30c5['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x4e52fd=_0x2d30c5['getMovedRangeStart'](),_0x5dfb93=_0x4e52fd['parent'],_0x3dba44=_0x4e52fd['offset'];!function _0x28aaed(_0x47af67,_0x5206e2,_0x304373,_0x2e7c96){for(let _0x1fe3e2=_0x304373;_0x1fe3e2<_0x2e7c96;_0x1fe3e2++){const _0x251219=_0x5206e2['getChild'](_0x1fe3e2);_0x251219['is']('element','$text')?_0x47af67['set'](_0x251219['getAttribute']('vid'),{'userId':_0xa1ca57}):(_0x47af67['set'](_0x251219['getAttribute']('vid_start'),{'userId':_0xa1ca57}),_0x28aaed(_0x47af67,_0x251219,0x0,_0x251219['childCount']),_0x47af67['set'](_0x251219['getAttribute']('vid_end'),{'userId':_0xa1ca57}));}}(this['_touched'],_0x5dfb93,_0x3dba44,_0x3dba44+_0x2d30c5['howMany']);}['_handleMergeOperation'](_0x5c5d48){const _0x1bca2e=null===(_0x5c5d48=this['_cloneOperation'](_0x5c5d48,this['_idsRoots']))['_authorId']?null:_0x5c5d48['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x169f14=_0x5c5d48['targetPosition']['parent'],_0x5a6381=_0x5c5d48['sourcePosition']['parent'],_0x48c88a=_0x169f14['getAttribute']('vid_end'),_0x415fe3=_0x5a6381['getAttribute']('vid_start');_0x169f14['_setAttribute']('vid_end',_0x5a6381['getAttribute']('vid_end')),_0x5a6381['_setAttribute']('vid_end',_0x48c88a),this['_touched']['set'](_0x415fe3,{'userId':_0x1bca2e}),this['_touched']['set'](_0x48c88a,{'userId':_0x1bca2e}),_0x5c5d48['_execute']();}['_handleSplitOperation'](_0x34f335){const _0x39035f=null===(_0x34f335=this['_cloneOperation'](_0x34f335,this['_idsRoots']))['_authorId']?null:_0x34f335['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x1b5368=_0x34f335['graveyardPosition'],_0xeab941=_0x34f335['splitPosition']['parent'];_0x34f335['_execute']();const _0x13ccac=_0xeab941['getAttribute']('vid_end'),_0x3cd0d4=_0x34f335['insertionPosition']['nodeAfter'];if(_0x1b5368){const _0x137eb3=_0x3cd0d4['getAttribute']('vid_end'),_0x24febe=_0xeab941['getAttribute']('vid_end');_0xeab941['_setAttribute']('vid_end',_0x137eb3),_0x3cd0d4['_setAttribute']('vid_end',_0x24febe),this['_touched']['set'](_0xeab941['getAttribute']('vid_end'),{'userId':_0x39035f}),this['_touched']['set'](_0x3cd0d4['getAttribute']('vid_start'),{'userId':_0x39035f});}else{const _0x384d79=this['_revisionId']++,_0x3d08e0=this['_revisionId']++;_0xeab941['_setAttribute']('vid_end',_0x384d79),_0x3cd0d4['_setAttribute']('vid_start',_0x3d08e0),_0x3cd0d4['_setAttribute']('vid_end',_0x13ccac),this['_touched']['set'](_0x384d79,{'userId':_0x39035f}),this['_touched']['set'](_0x3d08e0,{'userId':_0x39035f});}}['_handleMarkerOperation'](_0x49e574){if(!_0x49e574['affectsData'])return;const _0x4508e0=(_0x49e574=this['_cloneOperation'](_0x49e574,this['_diffRoots']))['oldRange']?_0x49e574['oldRange']['root']:null,_0x4410da=_0x49e574['newRange']?_0x49e574['newRange']['root']:null;_0x4508e0&&this['_markers']['delete'](_0x49e574['name']),_0x4410da&&this['_markers']['set'](_0x49e574['name'],_0x49e574['newRange']['clone']());const _0x305c63=null===_0x49e574['_authorId']?null:_0x49e574['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x44600f=_0x49e574['name'];if(!this['_touchedMarkers']['has'](_0x44600f))return void this['_touchedMarkers']['set'](_0x44600f,{'range':_0x49e574['oldRange'],'userId':_0x305c63});const _0xc1c0a9=this['_touchedMarkers']['get'](_0x44600f),_0x13aa3c=_0xc1c0a9['range'],_0x23a68b=_0x49e574['newRange'];null==_0x13aa3c&&null==_0x23a68b||_0x13aa3c&&_0x23a68b&&_0x13aa3c['isEqual'](_0x23a68b)?this['_touchedMarkers']['delete'](_0x49e574['name']):_0xc1c0a9['userId']=_0x305c63;}['_handleRootOperation'](_0x283731,_0x4c7f7c){this['_diffRoots']['has'](_0x283731['rootName'])?this['_diffRoots']['get'](_0x283731['rootName'])['_isAttached']=_0x283731['isAdd']:(this['_diffRoots']['set'](_0x283731['rootName'],N(_0x283731['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x283731['rootName'],{}),_0x4c7f7c&&this['_idsRoots']['set'](_0x283731['rootName'],N(_0x283731['rootName'],!0x0)));const _0x487d06=null===_0x283731['_authorId']?null:_0x283731['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0xa36e37=this['_touchedRoots']['get'](_0x283731['rootName']);_0xa36e37&&_0xa36e37['userId']===_0x487d06?this['_touchedRoots']['delete'](_0x283731['rootName']):this['_touchedRoots']['set'](_0x283731['rootName'],{'userId':_0x487d06,'isAttached':_0x283731['isAdd']});}['_handleRootAttributeOperation'](_0x37c385){const _0x261190=this['_diffRootsAttributes']['get'](_0x37c385['root']['rootName']);null===_0x37c385['newValue']?delete _0x261190[_0x37c385['key']]:_0x261190[_0x37c385['key']]=_0x37c385['newValue'];}}function K(_0x2b08cd){const _0x5943c6=N(_0x2b08cd['rootName'],_0x2b08cd['isAttached']());for(const _0xdf00bf of _0x2b08cd['getChildren']()){const _0x3024b9=_0xdf00bf['_clone'](!0x0);_0x5943c6['_appendChild'](_0x3024b9);}return _0x5943c6;}function N(_0x5bccbb,_0xc48329=!0x0){const _0x43ac14=new _0x8c84c8();return _0x43ac14['rootName']=_0x5bccbb,_0x43ac14['_isAttached']=_0xc48329,_0x43ac14['isAttached']=()=>_0x43ac14['_isAttached'],_0x43ac14;}function P(_0x78770d,_0x2c5c2f,_0x4214ad){const _0x3b2d4f='elementEnd'==_0x78770d['type']?_0x4214ad['createPositionAt'](_0x78770d['item'],'end'):_0x4214ad['createPositionBefore'](_0x78770d['item']);return _0x4214ad['createPositionFromPath'](_0x2c5c2f,_0x3b2d4f['path'],_0x3b2d4f['stickiness']);}function V(_0xa157f1,_0x2de73b,_0x10407c){const _0x3b4fed='elementStart'==_0xa157f1['type']?_0x10407c['createPositionAt'](_0xa157f1['item'],0x0):_0x10407c['createPositionAfter'](_0xa157f1['item']);return _0x10407c['createPositionFromPath'](_0x2de73b,_0x3b4fed['path'],_0x3b4fed['stickiness']);}class he extends/* #__PURE__ -- @preserve */
25
- _0x5aa04a(_0x4eb8a3){['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x4244cf,_0x1c5f1c){super(_0x4244cf),this['focusTracker']=new _0x30890a(),this['keystrokes']=new _0x34a3da(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x1c5f1c),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'](),_0xccd7c3({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x2c5de2=_0x50a2b5=>_0x50a2b5['stopPropagation']();this['keystrokes']['set']('arrowright',_0x2c5de2),this['keystrokes']['set']('arrowleft',_0x2c5de2),this['keystrokes']['set']('arrowup',_0x2c5de2),this['keystrokes']['set']('arrowdown',_0x2c5de2);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x14abd6){this['revisionNameInputView']['fieldView']['element']['value']=_0x14abd6['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x222267){const _0x2d412b=new et(this['locale'],ti),_0xcbfc1e=_0x2d412b['fieldView'];_0xcbfc1e['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x4b9df7=m(this['locale'],'Name\x20of\x20the\x20revision');return!_0x222267&&(_0x4b9df7+='\x20('+m(this['locale'],'optional')+')'),(_0x2d412b['label']=_0x4b9df7,_0xcbfc1e['on']('input',()=>{this['revisionNameInputValue']=_0xcbfc1e['element']['value']['trim']();}),_0x2d412b);}}class l extends _0xbe21c4{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h];}['_saveRevisionFormView'];['init'](){const _0x2f3c18=this['editor'],_0x23c3d0=_0x2f3c18['plugins']['get']('RevisionTracker');_0x2f3c18['ui']['componentFactory']['add']('revisionHistory',_0x5c8f0e=>{const _0x41e46c=_0x1e23a0(_0x5c8f0e),_0x1b9334=_0x41e46c['panelView']['children'],_0x7ce969=new _0x4b2173(_0x5c8f0e),_0x11d5f0=new _0x55af41(_0x5c8f0e),_0x24eebd=this['_createSaveRevisionButton'](_0x41a1a9),_0x5a60b4=new _0x55af41(_0x5c8f0e),_0x456a66=this['_createOpenRevisionButton'](_0x41a1a9);return _0x41e46c['bind']('isEnabled')['to'](_0x23c3d0,'isReady',_0x23c3d0,'isEnabled',_0x2f3c18,'isReadOnly',(_0x5efc6e,_0x2df569,_0x458ec1)=>_0x5efc6e&&_0x2df569&&!_0x458ec1),_0x41e46c['buttonView']['set']({'icon':_0x672cd0,'label':m(_0x5c8f0e,'Revision\x20history'),'tooltip':!0x0}),_0x24eebd['set']({'withText':!0x0,'role':'menuitem'}),_0x456a66['set']({'withText':!0x0,'role':'menuitem'}),this['listenTo'](_0x456a66,'execute',()=>{_0x41e46c['isOpen']=!0x1,_0x2f3c18['editing']['view']['focus']();},{'priority':'low'}),_0x11d5f0['children']['add'](_0x24eebd),_0x5a60b4['children']['add'](_0x456a66),_0x7ce969['role']='menu',_0x7ce969['items']['addMany']([_0x11d5f0,_0x5a60b4]),_0x1b9334['add'](_0x7ce969),_0x41e46c;}),_0x2f3c18['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0xe7dc57=this['editor'],_0x9f75aa=_0xe7dc57['locale'],_0x587f28=_0xe7dc57['plugins']['get']('RevisionTracker'),_0x55d4fc=new _0x22ce88(_0x9f75aa),_0xee4282=new _0x3b6094(_0x9f75aa);_0x55d4fc['bind']('isEnabled')['to'](_0x587f28,'isReady',_0x587f28,'isEnabled',_0xe7dc57,'isReadOnly',(_0x13875c,_0x498b33,_0x230f7a)=>_0x13875c&&_0x498b33&&!_0x230f7a),_0x55d4fc['buttonView']['set']({'icon':_0x672cd0,'label':m(_0x9f75aa,'Revision\x20history')});const _0x353c1a=new _0x360a69(_0x9f75aa,_0x55d4fc),_0x546900=this['_createSaveRevisionButton'](_0x1b7074);_0x546900['delegate']('execute')['to'](_0x55d4fc),_0x353c1a['children']['add'](_0x546900),_0xee4282['items']['add'](_0x353c1a);const _0x1fe6f2=new _0x360a69(_0x9f75aa,_0x55d4fc),_0x12bb31=this['_createOpenRevisionButton'](_0x1b7074);return _0x12bb31['delegate']('execute')['to'](_0x55d4fc),_0x1fe6f2['children']['add'](_0x12bb31),_0xee4282['items']['add'](_0x1fe6f2),_0x55d4fc['panelView']['children']['add'](_0xee4282),_0x55d4fc;}['_createSaveRevisionButton'](_0x548efa){const _0x418e19=this['editor'],_0xa1f81c=_0x418e19['plugins']['get']('RevisionTracker'),_0x4ec41e=new _0x548efa(_0x418e19['locale']);return _0x4ec41e['set']({'label':m(_0x418e19['locale'],'Save\x20current\x20revision')}),_0x4ec41e['bind']('isEnabled')['to'](_0xa1f81c,'isReady',_0xa1f81c,'isEnabled',_0x418e19,'isReadOnly',(_0x23bcf6,_0x1347ab,_0x466ca2)=>_0x23bcf6&&_0x1347ab&&!_0x466ca2),this['listenTo'](_0x4ec41e,'execute',()=>{this['_showDialog']();}),_0x4ec41e;}['_createOpenRevisionButton'](_0x3e7d97){const _0x4a6b04=this['editor'],_0xc789d9=_0x4a6b04['plugins']['get']('RevisionTracker'),_0x29b565=new _0x3e7d97(_0x4a6b04['locale']);return _0x29b565['set']({'label':m(_0x4a6b04['locale'],'Open\x20revision\x20history')}),_0x29b565['bind']('isEnabled')['to'](_0xc789d9,'isReady',_0x4a6b04,'isReadOnly',(_0x8f3dd3,_0x203346)=>_0x8f3dd3&&!_0x203346),this['listenTo'](_0x29b565,'execute',()=>{_0x4a6b04['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x29b565;}['_showDialog'](){const _0x2035fc=this['editor'],_0x162edc=_0x2035fc['locale'],_0x1b075e=_0x2035fc['plugins']['get']('Dialog'),_0x43bbb9=_0x2035fc['plugins']['get']('RevisionTracker');function _0xf6c3d8(_0x22a39a){_0x2035fc['config']['get']('revisionHistory.requireRevisionName')&&''===_0x22a39a['revisionName']?_0x22a39a['revisionNameInputView']['errorText']=m(_0x162edc,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x2035fc['plugins']['get'](h)['saveRevision']({'name':_0x22a39a['revisionName']}),_0x1b075e['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0xf6c3d8(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x1b075e['show']({'id':'revisionSave','title':m(_0x162edc,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':m(_0x2035fc['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x1b075e['hide']()},{'label':m(_0x2035fc['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x234a24){_0x234a24['bind']('isEnabled')['to'](_0x43bbb9,'isReady',_0x43bbb9,'isEnabled',_0x2035fc,'isReadOnly',(_0x172116,_0xbfc1ba,_0x5d0468)=>_0x172116&&_0xbfc1ba&&!_0x5d0468);},'onExecute':()=>_0xf6c3d8(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x4b9b04=this['editor'],_0x1d5ba5=_0x4b9b04['locale'];this['_saveRevisionFormView']=new he(_0x1d5ba5,_0x4b9b04['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class z extends _0x4eb8a3{['changeId'];['_model'];constructor(_0x1b5a14,_0x35544b){super(_0x1b5a14),this['_model']=_0x35544b,this['changeId']=_0x35544b['id'];const _0x84d038=this['bindTemplate'],_0x14590f=m(_0x1b5a14,_0x35544b['data']['isSuggestion']?'Suggested\x20by':'add'==_0x35544b['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x35544b['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x84d038['to']('type',_0x3bf403=>'ck-revision-change__'+_0x3bf403)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x14590f}]},{'text':'\x20'+_0x35544b['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class G extends/* #__PURE__ -- @preserve */
26
- _0x113f03(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x36dc02){super(),this['id']=_0x36dc02['id']||_0x532896(),this['author']=_0x36dc02['author'],this['type']=_0x36dc02['type'],this['data']=_0x36dc02['data']||{},this['rootName']=_0x36dc02['rootName'],this['set']('createdAt',_0x36dc02['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(_0x38d6e3,_0x1e926e){this['newRevisionId']=_0x38d6e3,this['oldRevisionId']=_0x1e926e,this['changes']=new _0x504df2();}['_setChanges'](_0x50a448){for(const _0x192f61 of _0x50a448)this['changes']['add'](_0x192f61);}}class u extends _0xbe21c4{['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[_0x416e9c,_0x3e3e3f,S,$];}constructor(_0x42dc1b){super(_0x42dc1b),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',(_0x3d4002,_0x4860c0,_0x256624)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x566a16=>{for(const _0x3fbb41 of this['editor']['editing']['view']['document']['roots'])_0x256624?_0x566a16['removeClass']('ck-editor__editable__overlay',_0x3fbb41):_0x566a16['addClass']('ck-editor__editable__overlay',_0x3fbb41);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x5e724f=>null!==_0x5e724f),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x5b2d33,_0x5844de,_0x470c5c)=>_0x5b2d33&&_0x470c5c?_0x5844de['changes']['getIndex'](_0x470c5c):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x56ccfa,_0x547445)=>_0x56ccfa?_0x547445['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0x3e3e3f);}['init'](){const _0xb24340=this['editor'],_0x340fff=new rt(_0xb24340,{'direction':'backward'}),_0xf509f6=new rt(_0xb24340,{'direction':'forward'});(_0xb24340['commands']['add']('showPreviousChange',_0x340fff),_0xb24340['commands']['add']('showNextChange',_0xf509f6),_0xb24340['commands']['add']('restoreRevision',new nt(_0xb24340)),this['on']('change:numberOfChanges',()=>{_0x340fff['refresh'](),_0xf509f6['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0xb24340['enableReadOnlyMode']('revision-viewer'),_0xb24340['plugins']['has']('WidgetToolbarRepository'))&&_0xb24340['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x3e3c02){return await this['_utils']['loadRevisionData'](_0x3e3c02,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x3e3c02);}async['getRevisionRootsAttributes'](_0x3104df){return await this['_utils']['loadRevisionData'](_0x3104df,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x3104df);}async['compare'](_0x447d7a,_0x452dbd,_0x44d824=!0x1){if(!this['isEnabled'])return;const _0x546dec=this['diff'],_0x45a055=this['repository'],_0x10841e='string'==typeof _0x447d7a?_0x45a055['getRevision'](_0x447d7a):_0x447d7a,_0x7967ed='string'==typeof _0x452dbd?_0x45a055['getRevision'](_0x452dbd):_0x452dbd,_0x277450=_0x10841e['id'],_0x358404=_0x7967ed?_0x7967ed['id']:null;if(!_0x44d824&&this['diff']&&this['diff']['newRevisionId']===_0x277450&&this['diff']['oldRevisionId']===_0x358404)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new J(_0x277450,_0x358404);const _0x1d280a=this['_getRevisionsRange'](_0x10841e,_0x7967ed,!0x0)['map'](_0x5b4f82=>this['_utils']['loadRevisionData'](_0x5b4f82,this['adapter']));return _0x1d280a['push'](new Promise(_0x317a70=>{setTimeout(_0x317a70,0x14);})),Promise['all'](_0x1d280a)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x551b65=this['_getDiff'](_0x277450,_0x358404);for(const _0x4f94df of _0x551b65['changes'])this['_changeIdToChange']['set'](_0x4f94df['id'],_0x4f94df);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x3e9ccf=>{for(const _0x5b0982 of this['editor']['model']['document']['getRootNames']())_0x3e9ccf['detachRoot'](_0x5b0982);for(const _0x22f309 of Object['keys'](_0x551b65['model'])){const _0x278d1a=_0x3e9ccf['addRoot'](_0x22f309);for(const _0x4decca of Object['keys'](_0x551b65['attributes'][_0x22f309]))_0x3e9ccf['setAttribute'](_0x4decca,_0x551b65['attributes'][_0x22f309][_0x4decca],_0x278d1a);_0x3e9ccf['insert'](_0x551b65['model'][_0x22f309],_0x278d1a,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x551b65['changes'])),this['isReady']=!0x0;})['catch'](_0x422a0a=>{console['error'](_0x422a0a),this['_cleanUp'](),_0x546dec&&(this['diff']=_0x546dec),this['isReady']=!0x0;});}['addRevisionData'](_0x5e0f84,_0x5b9619){const _0x5ec505=this['repository']['createRevision'](_0x5e0f84);return _0x5ec505['on']('_update',(_0x4a7fe6,_0x1d0517,_0x3ce82c)=>_0x5b9619(_0x1d0517,_0x3ce82c,_0x5ec505)),this['repository']['addRevision'](_0x5ec505),_0x5ec505;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x4b1596=>{for(const _0x5e926f of this['editor']['model']['document']['getRootNames']())_0x4b1596['detachRoot'](_0x5e926f);});}['_sortAndFilterDiffChanges'](_0x2e4e85){const _0x19b937=[],_0x51f1c8=new Map();for(const _0x467291 of this['editor']['model']['document']['getRootNames']()){const _0x1051e1=this['editor']['editing']['view']['getDomRoot'](_0x467291);if(!_0x1051e1)continue;const _0x1f64ec=_0x1051e1['getClientRects']()['item'](0x0);_0x1f64ec&&(_0x19b937['push'](_0x467291),_0x51f1c8['set'](_0x467291,_0x1f64ec));}return _0x19b937['sort']((_0x5a14c9,_0x4b3419)=>{const _0x30a2ce=_0x51f1c8['get'](_0x5a14c9),_0x3b6503=_0x51f1c8['get'](_0x4b3419);return _0x30a2ce['y']-_0x3b6503['y']||_0x30a2ce['x']-_0x3b6503['x'];}),(_0x2e4e85=_0x2e4e85['filter'](_0x4f77fd=>_0x19b937['includes'](_0x4f77fd['rootName'])))['sort']((_0x45bde8,_0x4a3386)=>_0x19b937['indexOf'](_0x45bde8['rootName'])-_0x19b937['indexOf'](_0x4a3386['rootName'])),_0x2e4e85;}['_makeTape'](_0x232772){const _0x40b918=Array['from'](_0x232772['markers'])['filter'](([_0x11c4bf,_0x3a5370])=>_0x11c4bf['startsWith']('revision:')&&!_0x3a5370['isCollapsed']),_0x4435e2=Array['from'](this['editor']['model']['createRangeIn'](_0x232772)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x40b918['length'])for(const _0x2e68ff of _0x4435e2){const [_0x36e547,_0x511590]=_0x40b918[0x0],[,_0x4889f3,_0x41622f]=_0x36e547['split'](':');if(_0x511590['end']['isEqual'](_0x2e68ff['nextPosition'])&&_0x40b918['shift'](),(_0x2e68ff['previousPosition']['isEqual'](_0x511590['start'])||_0x2e68ff['previousPosition']['isAfter'](_0x511590['start']))&&('insertion'==_0x4889f3?_0x2e68ff['isAdded']={'userId':_0x41622f}:'deletion'==_0x4889f3&&(_0x2e68ff['isRemoved']={'userId':_0x41622f})),0x0==_0x40b918['length'])break;}return _0x4435e2;}['_refreshStartEndIndex'](_0x235f84){const _0x1bf2f8=new Map();for(let _0x2d2217=0x0;_0x2d2217<_0x235f84['length'];_0x2d2217++)'text'===_0x235f84[_0x2d2217]['type']?(_0x235f84[_0x2d2217]['item']['startIndex']=_0x2d2217,_0x235f84[_0x2d2217]['item']['endIndex']=_0x2d2217):('elementStart'===_0x235f84[_0x2d2217]['type']?_0x235f84[_0x2d2217]['item']['startIndex']=_0x2d2217:'elementEnd'===_0x235f84[_0x2d2217]['type']&&(_0x235f84[_0x2d2217]['item']['endIndex']=_0x2d2217),_0x1bf2f8['set'](_0x235f84[_0x2d2217]['id'],_0x2d2217));for(const _0x39fc6c of _0x1bf2f8['values']())'elementStart'===_0x235f84[_0x39fc6c]['type']?_0x235f84[_0x39fc6c]['item']['endIndex']=_0x1bf2f8['get'](_0x235f84[_0x39fc6c]['pairId']):'elementEnd'===_0x235f84[_0x39fc6c]['type']&&(_0x235f84[_0x39fc6c]['item']['startIndex']=_0x1bf2f8['get'](_0x235f84[_0x39fc6c]['pairId']));}['_processTape'](_0xea2618){for(let _0x1e618e=0x0;_0x1e618e<_0xea2618['length'];_0x1e618e++){if('elementStart'===_0xea2618[_0x1e618e]['type'])_0xea2618[_0x1e618e]['item']['startIndex']=_0x1e618e;else{if('elementEnd'===_0xea2618[_0x1e618e]['type']){_0xea2618[_0x1e618e]['item']['endIndex']=_0x1e618e;const _0x2451b1=_0xea2618[_0x1e618e]['item']['startIndex'];_0xea2618[_0x2451b1]['pairId']=_0xea2618[_0x1e618e]['id'],_0xea2618[_0x1e618e]['pairId']=_0xea2618[_0x2451b1]['id'];}else _0xea2618[_0x1e618e]['item']['startIndex']=_0x1e618e,_0xea2618[_0x1e618e]['item']['endIndex']=_0x1e618e,_0xea2618[_0x1e618e]['pairId']=null;}_0xea2618[_0x1e618e]['markersStart']||(_0xea2618[_0x1e618e]['markersStart']=[],_0xea2618[_0x1e618e]['markersEnd']=[]);}}['_markInsertions'](_0x1461f7,_0x4a2d2c){const _0x4bc7b7=_0x1461f7['filter'](_0x51f5eb=>!_0x51f5eb['isAdded']);for(let _0x649d0e=0x0;_0x649d0e<_0x4a2d2c['length'];_0x649d0e++)_0x4a2d2c[_0x649d0e]['isAdded']&&(_0x4bc7b7[_0x649d0e]['isAdded']=_0x4a2d2c[_0x649d0e]['isAdded']);}['_getDiff'](_0x48cc3a,_0x4b4d00=null){const _0xaa364c=this['repository']['getRevision'](_0x48cc3a),_0x47f869=_0x4b4d00?this['repository']['getRevision'](_0x4b4d00):null,_0x3e68b2=this['_getRevisionsRange'](_0xaa364c,_0x47f869),_0x19616e=_0x3e68b2[_0x3e68b2['length']-0x1],_0xf21a58=new Map(),_0x5e0650={'model':{},'attributes':{},'changes':[]},_0x209d07=new Set(),_0x52f2b6=new Map();for(let _0x4c4270=_0x3e68b2['length']-0x1;_0x4c4270>=0x0;_0x4c4270--){const _0x15c685=_0x3e68b2[_0x4c4270];for(const _0x268447 of Object['keys'](_0x15c685['diffData']))if(_0x15c685['diffData'][_0x268447]['attachChange']){const _0x271210=_0x15c685['diffData'][_0x268447]['attachChange'];_0x271210['isAttached']?(_0x209d07['add'](_0x268447),_0x52f2b6['has'](_0x268447)&&_0x52f2b6['get'](_0x268447)['userId']==_0x271210['userId']?_0x52f2b6['delete'](_0x268447):_0x52f2b6['set'](_0x268447,_0x271210)):_0x52f2b6['has'](_0x268447)?(_0x209d07['delete'](_0x268447),_0x52f2b6['delete'](_0x268447)):(_0x209d07['add'](_0x268447),_0x52f2b6['set'](_0x268447,_0x271210));}else _0x209d07['add'](_0x268447);}for(const _0x5789d1 of _0x209d07){const _0x16c971=_0x52f2b6['has'](_0x5789d1)&&!_0x52f2b6['get'](_0x5789d1)['isAttached'];let _0x3f497c=_0x16c971?_0x3e68b2['length']-0x1:0x0;const _0x21d77d=_0x16c971?-0x1:0x1;for(;_0x3e68b2[_0x3f497c];){const _0x489e7d=_0x3e68b2[_0x3f497c];if(_0x489e7d['diffData'][_0x5789d1]){const _0x2fc44f=_0x16c971?_0x489e7d['diffData'][_0x5789d1]['attributesBefore']:_0x489e7d['diffData'][_0x5789d1]['attributesAfter'];_0x5e0650['attributes'][_0x5789d1]=_0x2fc44f?_0x83ca90(_0x2fc44f):{};break;}_0x3f497c+=_0x21d77d;}}for(const _0x5ea4bc of _0x3e68b2){_0x5ea4bc['model']={};for(const _0x20f631 of _0x5ea4bc['authors'])_0xf21a58['set'](_0x20f631['id'],_0x20f631);for(const _0x5746c4 of _0x209d07){const _0x37de87=_0x5ea4bc['diffData'][_0x5746c4]?_0x5ea4bc['diffData'][_0x5746c4]['insertions']:'[]',_0x4a150f=_0x5ea4bc['diffData'][_0x5746c4]?_0x5ea4bc['diffData'][_0x5746c4]['deletions']:'[]';_0x5ea4bc['model'][_0x5746c4]={'insertions':this['_utils']['_makeModelFromViewString'](_0x37de87),'deletions':this['_utils']['_makeModelFromViewString'](_0x4a150f)};}}for(const _0x5d3150 of _0x209d07){let _0x5d1042=null,_0x316e87=0x0;const _0xb7bbab=new Map(Array['from'](_0xaa364c['model'][_0x5d3150]['insertions']['markers'])['filter'](([_0x412a57])=>!_0x412a57['startsWith']('revision:')));let _0x2782a3=0x0;for(const _0x190117 of _0x3e68b2){const _0x350cf1=this['_makeTape'](_0x190117['model'][_0x5d3150]['insertions']);_0x190117==_0xaa364c?(_0x5d1042=_0x350cf1,_0x316e87=_0x5d1042['length'],_0x5d1042['forEach'](_0x2cd237=>{_0x2cd237['id']=_0x2782a3++;}),this['_processTape'](_0x5d1042)):this['_markInsertions'](_0x5d1042,_0x350cf1);const _0x2e62e5=_0x5d1042['filter'](_0x1c70be=>!_0x1c70be['isAdded'])['map'](_0xd5d499=>_0xd5d499['id']);let _0x3e5cac=0x0;const _0x464ab1=this['_makeTape'](_0x190117['model'][_0x5d3150]['deletions']);_0x464ab1['forEach'](_0x3afe80=>{_0x3afe80['isRemoved']?_0x3afe80['id']=_0x316e87++:_0x3afe80['id']=_0x2e62e5[_0x3e5cac++];}),this['_processTape'](_0x464ab1),this['_setDistance'](_0x5d1042,'isAdded'),this['_setDistance'](_0x464ab1,'isRemoved'),_0x190117==_0xaa364c&&this['_markMarkers'](_0x5d1042,_0xb7bbab),_0x5d1042=this['_joinTapes'](_0x5d1042,_0x464ab1),this['_refreshStartEndIndex'](_0x5d1042),this['_setDistance'](_0x5d1042,'isRemoved');}_0x5d1042=_0x5d1042['filter'](_0x16efe8=>!(_0x16efe8['isAdded']&&_0x16efe8['isRemoved']));const _0x3ca3c2=new Map(_0x19616e['model'][_0x5d3150]['deletions']['markers']),_0x1163e4=new Set(_0xb7bbab['keys']());for(const _0x3b92f3 of _0x3ca3c2['keys']())_0x1163e4['delete'](_0x3b92f3);this['_markSuggestions'](_0x5d1042,_0x1163e4),this['_fixObsoleteTags'](_0x5d1042),_0x5d1042=this['_removeMissingPairs'](_0x5d1042),_0x5d1042=this['_markMismatchedRemovedTags'](_0x5d1042),_0x5d1042=this['_removeUnsupportedChanges'](_0x5d1042);const {root:_0x5c7105,changes:_0x49a6bd}=this['_makeModelFromTape'](_0x5d1042,_0xf21a58,_0x5d3150);_0x5e0650['model'][_0x5d3150]=_0x5c7105;const _0x1f32d4=_0x52f2b6['get'](_0x5d3150);if(_0x1f32d4){const _0x5698ad=_0xf21a58['get'](_0x1f32d4['userId']),_0x9bb7ff=new G({'author':_0x5698ad,'type':_0x1f32d4['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x5d3150});_0x49a6bd['unshift'](_0x9bb7ff),_0x5e0650['attributes'][_0x5d3150]['revisionHistoryAttachChange']=_0x9bb7ff['id'];}_0x5e0650['changes']=_0x5e0650['changes']['concat'](_0x49a6bd);}return _0x5e0650;}['_markMarkers'](_0x585f5e,_0x461ff3){for(let _0x2fe530=0x0;_0x2fe530<_0x585f5e['length'];_0x2fe530++)for(const [_0x4c4b29,_0x460f58]of _0x461ff3)!_0x460f58['isCollapsed']&&_0x460f58['start']['isEqual'](_0x585f5e[_0x2fe530]['previousPosition'])&&_0x585f5e[_0x2fe530]['markersStart']['push'](_0x4c4b29),_0x460f58['end']['isEqual'](_0x585f5e[_0x2fe530]['nextPosition'])&&_0x585f5e[_0x2fe530]['markersEnd']['push'](_0x4c4b29);}['_joinTapes'](_0x2431ce,_0xfc2934){let _0x50e7b1=[],_0x4db0e7=0x0,_0x3302e2=0x0;for(;_0x4db0e7<_0x2431ce['length']||_0x3302e2<_0xfc2934['length'];){const _0x59a21e=_0x2431ce[_0x4db0e7]||{},_0x2e767d=_0xfc2934[_0x3302e2]||{};if(_0x59a21e['id']==_0x2e767d['id'])_0x4db0e7++,_0x3302e2++,_0x50e7b1['push'](_0x59a21e);else{if(_0x2e767d['isRemoved']&&_0x59a21e['isAdded']){const {commonTape:_0x520cf6,iEnd:_0x21f42f,jEnd:_0xdf697b}=this['_threeWayMerge'](_0x2431ce,_0x4db0e7,_0xfc2934,_0x3302e2);_0x50e7b1=_0x50e7b1['concat'](_0x520cf6),_0x4db0e7=_0x21f42f,_0x3302e2=_0xdf697b;}else _0x2e767d['isRemoved']?(_0x3302e2++,_0x50e7b1['push'](_0x2e767d)):(_0x4db0e7++,_0x50e7b1['push'](_0x59a21e));}}return _0x50e7b1;}['_markSuggestions'](_0x207a93,_0x4e243a){const _0x52e946=[];for(let _0x40cb7c=0x0;_0x40cb7c<_0x207a93['length'];_0x40cb7c++){for(let _0x868842=0x0;_0x868842<_0x207a93[_0x40cb7c]['markersStart']['length'];_0x868842++){const _0x217480=_0x207a93[_0x40cb7c]['markersStart'][_0x868842];if(!_0x4e243a['has'](_0x217480))continue;const {group:_0x4447fa,type:_0x3ac6c7,authorId:_0x44b987}=_0x4fd0e4(_0x217480);'revision-suggestion'!=_0x4447fa||'insertion'!=_0x3ac6c7&&'deletion'!=_0x3ac6c7||(_0x52e946['unshift']({'type':_0x3ac6c7,'name':_0x217480,'userId':_0x44b987}),_0x207a93[_0x40cb7c]['markersStart']['splice'](_0x868842,0x1),_0x868842--);}_0x3b7615(_0x207a93[_0x40cb7c]);for(let _0x419152=0x0;_0x419152<_0x207a93[_0x40cb7c]['markersEnd']['length'];_0x419152++){const _0x1e0f81=_0x207a93[_0x40cb7c]['markersEnd'][_0x419152];if(!_0x4e243a['has'](_0x1e0f81))continue;const {group:_0x2ead52,type:_0x17cdb6}=_0x4fd0e4(_0x1e0f81);if('revision-suggestion'!=_0x2ead52||'insertion'!=_0x17cdb6&&'deletion'!=_0x17cdb6)continue;_0x207a93[_0x40cb7c]['markersEnd']['splice'](_0x419152,0x1),_0x419152--;const _0x3613b6=_0x52e946['findIndex'](_0x27a88b=>_0x27a88b['name']==_0x1e0f81);_0x3613b6>-0x1&&_0x52e946['splice'](_0x3613b6,0x1);}}function _0x4fd0e4(_0x3b419f){const _0x5d0cc4=_0x3b419f['split'](':');return{'group':_0x5d0cc4[0x0],'type':_0x5d0cc4[0x1],'subType':_0x5d0cc4['length']>=0x5?_0x5d0cc4[0x2]:null,'id':_0x5d0cc4['length']<0x5?_0x5d0cc4[0x2]:_0x5d0cc4[0x3],'authorId':_0x5d0cc4['length']<0x5?_0x5d0cc4[0x3]:_0x5d0cc4[0x4],'markerCount':0x6==_0x5d0cc4['length']?_0x5d0cc4[0x5]:null};}function _0x3b7615(_0x2739fc){for(let _0x2beb9e=0x0;_0x2beb9e<_0x52e946['length'];_0x2beb9e++){if(_0x2739fc['isAdded']&&'insertion'==_0x52e946[_0x2beb9e]['type']&&_0x2739fc['isAdded']['userId']==_0x52e946[_0x2beb9e]['userId'])return _0x2739fc['isAddSuggestion']=_0x52e946[_0x2beb9e],void delete _0x2739fc['isAdded'];if(!_0x2739fc['isAdded']&&!_0x2739fc['isRemoved']&&'deletion'==_0x52e946[_0x2beb9e]['type'])return void(_0x2739fc['isRemoveSuggestion']=_0x52e946[_0x2beb9e]);}}}['_setDistance'](_0x53d07c,_0x11fa35){let _0x2ce6ac=0x0,_0x1be4a4=!0x1;const _0x16fcfa=new Map();for(const _0x52f2a3 of _0x53d07c)_0x52f2a3[_0x11fa35]?_0x1be4a4&&(_0x2ce6ac++,_0x1be4a4=!0x1):(_0x2ce6ac++,_0x1be4a4=!0x0),_0x16fcfa['set'](_0x52f2a3['id'],_0x2ce6ac);for(let _0x1e8814=0x0;_0x1e8814<_0x53d07c['length'];_0x1e8814++){if('isRemoved'==_0x11fa35&&_0x53d07c[_0x1e8814]['isAdded']||'isAdded'==_0x11fa35&&_0x53d07c[_0x1e8814]['isRemoved'])continue;if('text'==_0x53d07c[_0x1e8814]['type']){_0x53d07c[_0x1e8814]['distance']=0x0;continue;}const _0x6e4e20=_0x16fcfa['get'](_0x53d07c[_0x1e8814]['pairId']),_0x3c6ec7=_0x16fcfa['get'](_0x53d07c[_0x1e8814]['id']);_0x53d07c[_0x1e8814]['distance']=_0x6e4e20-_0x3c6ec7;}}['_getRevisionsRange'](_0x1e9c99,_0x30d1d7,_0x11dd07=!0x1){const _0x48e332=[];let _0x3d7c95=this['repository']['getIndex'](_0x1e9c99),_0x310e96=this['repository']['getIndex'](_0x30d1d7);for(-0x1==_0x310e96&&(_0x310e96=this['repository']['_revisions']['length'],_0x11dd07=!0x1);_0x3d7c95<_0x310e96;)_0x48e332['push'](this['repository']['getRevision'](_0x3d7c95)),_0x3d7c95++;return _0x11dd07&&_0x48e332['push'](this['repository']['getRevision'](_0x3d7c95)),_0x48e332;}['_threeWayMerge'](_0x71854b,_0x4fc031,_0x1d8416,_0x223a6f){const _0x3b0c30=this['editor']['model']['schema'];let _0x5f1710=_0x4fc031;for(;_0x71854b[_0x5f1710]&&_0x71854b[_0x5f1710]['isAdded'];)_0x5f1710++;let _0x2a6e3a=_0x223a6f;for(;_0x1d8416[_0x2a6e3a]&&_0x1d8416[_0x2a6e3a]['isRemoved'];)_0x2a6e3a++;_0x57a686(_0x71854b,_0x4fc031,_0x5f1710),_0x57a686(_0x1d8416,_0x223a6f,_0x2a6e3a);const _0x38cc87=_0x1d8416['slice'](_0x223a6f,_0x2a6e3a)['concat'](_0x71854b['slice'](_0x4fc031,_0x5f1710));return _0x38cc87['sort']((_0x45d5b3,_0x2659bd)=>_0x45d5b3['side']!=_0x2659bd['side']?_0x45d5b3['side']-_0x2659bd['side']:_0x45d5b3['level']!=_0x2659bd['level']?_0x45d5b3['level']-_0x2659bd['level']:_0x45d5b3['distance']!=_0x2659bd['distance']?_0x2659bd['distance']-_0x45d5b3['distance']:!!_0x45d5b3['isAdded']!=!!_0x2659bd['isAdded']?-0x1==_0x45d5b3['side']||0x0==_0x45d5b3['side']?_0x45d5b3['isAdded']?-0x1:0x1:_0x45d5b3['isAdded']?0x1:-0x1:_0x45d5b3['index']-_0x2659bd['index']),{'commonTape':_0x38cc87,'iEnd':_0x5f1710,'jEnd':_0x2a6e3a};function _0x57a686(_0xcd567e,_0x5badae,_0x3fa5de){let _0x187e8d=-0x1,_0x476670=Number['POSITIVE_INFINITY'],_0x8b2185=!0x0;for(let _0x273f53=_0x5badae;_0x273f53<_0x3fa5de;_0x273f53++)if(_0x3b0c30['isInline'](_0xcd567e[_0x273f53]['item'])||(_0x8b2185=!0x1),_0xcd567e[_0x273f53]['item']['startIndex']<_0x5badae&&(_0x187e8d=_0x273f53),_0xcd567e[_0x273f53]['item']['endIndex']>=_0x3fa5de){_0x476670=_0x273f53;break;}_0x8b2185&&(_0x187e8d=_0x3fa5de-0x1);for(let _0x43d0f7=_0x5badae;_0x43d0f7<_0x3fa5de;_0x43d0f7++)_0xcd567e[_0x43d0f7]['side']=_0x43d0f7<=_0x187e8d?-0x1:_0x43d0f7<_0x476670?0x0:0x1,_0xcd567e[_0x43d0f7]['index']=_0x43d0f7;let _0x5a1d88=0x0;for(let _0x7505c=_0x5badae;_0x7505c<=_0x187e8d;_0x7505c++)0x0==_0xcd567e[_0x7505c]['distance']?_0xcd567e[_0x7505c]['level']=_0x5a1d88:(_0x5a1d88++,_0xcd567e[_0x7505c]['level']=_0x5a1d88,_0x5a1d88++);for(let _0x9f02df=_0x5badae;_0x9f02df<_0x3fa5de;_0x9f02df++)0x0==_0xcd567e[_0x9f02df]['side']&&(_0xcd567e[_0x9f02df]['level']=_0x5a1d88);_0x5a1d88=0x0;for(let _0x257562=_0x3fa5de-0x1;_0x257562>=_0x476670;_0x257562--)0x0==_0xcd567e[_0x257562]['distance']?_0xcd567e[_0x257562]['level']=_0x5a1d88:(_0x5a1d88--,_0xcd567e[_0x257562]['level']=_0x5a1d88,_0x5a1d88--);}}['_fixObsoleteTags'](_0x480dae){const _0x29f12c=new Map(),_0x19b692=this['editor']['model']['schema'];for(let _0x3528d9=0x1;_0x3528d9<_0x480dae['length'];_0x3528d9++){let _0x40303a,_0x3541c2,_0x9d0b21;const _0x17dde3=_0x480dae[_0x3528d9],_0x11fed8=_0x480dae[_0x3528d9-0x1];if('text'==_0x17dde3['type'])continue;if(_0x17dde3['type']!=_0x11fed8['type'])continue;if(!_0x19b692['isBlock'](_0x11fed8['item'])||_0x19b692['isLimit'](_0x11fed8['item']))continue;if(!_0x19b692['isBlock'](_0x17dde3['item'])||_0x19b692['isLimit'](_0x17dde3['item']))continue;if((_0x480dae[_0x3528d9]['isAdded']||_0x480dae[_0x3528d9]['isAddSuggestion'])&&_0x480dae[_0x3528d9-0x1]['isRemoved'])_0x40303a=_0x480dae[_0x3528d9],_0x3541c2=_0x480dae[_0x3528d9-0x1],_0x9d0b21=_0x3528d9-0x1;else{if(!_0x480dae[_0x3528d9]['isRemoved']||!_0x480dae[_0x3528d9-0x1]['isAdded']&&!_0x480dae[_0x3528d9-0x1]['isAddSuggestion'])continue;_0x40303a=_0x480dae[_0x3528d9-0x1],_0x3541c2=_0x480dae[_0x3528d9],_0x9d0b21=_0x3528d9;}const _0x50157e=_0x40303a['level']==_0x3541c2['level'],_0x4433fc=Math['abs'](_0x40303a['level'])<Math['abs'](_0x3541c2['level'])&&0x0==_0x3541c2['distance'];(_0x50157e||_0x4433fc)&&(_0x29f12c['set'](_0x3541c2['id'],_0x40303a['id']),_0x480dae['splice'](_0x9d0b21,0x1),_0x3528d9--,_0x40303a['isAdded']=!0x1);}for(let _0x59d72c=0x0;_0x59d72c<_0x480dae['length'];_0x59d72c++)_0x29f12c['has'](_0x480dae[_0x59d72c]['pairId'])&&(_0x480dae[_0x59d72c]['pairId']=_0x29f12c['get'](_0x480dae[_0x59d72c]['pairId']));}['_removeMissingPairs'](_0x314b93){const _0x3e7624=new Set(_0x314b93['map'](_0x4db8c9=>_0x4db8c9['id']));for(let _0x4ce20c=0x0;_0x4ce20c<_0x314b93['length'];_0x4ce20c++)_0x3e7624['has'](_0x314b93[_0x4ce20c]['pairId'])||0x0==_0x314b93[_0x4ce20c]['distance']||(_0x314b93[_0x4ce20c]['isIncorrect']=!0x0);return _0x314b93['filter'](_0x646294=>!_0x646294['isIncorrect']);}['_markMismatchedRemovedTags'](_0x36827c){const _0x44ba71=new Set();for(let _0x75294b=0x0;_0x75294b<_0x36827c['length'];_0x75294b++){if(_0x44ba71['has'](_0x36827c[_0x75294b]['id'])&&_0x36827c[_0x75294b]['isRemoved']&&(_0x36827c[_0x75294b]['isIncorrect']=!0x0),_0x36827c[_0x75294b]['isIncorrect'])continue;if(0x0==_0x36827c[_0x75294b]['distance'])continue;if('elementStart'!=_0x36827c[_0x75294b]['type'])continue;if(null==_0x36827c[_0x75294b]['pairId'])continue;let _0x5c1208=_0x75294b+0x1,_0x171e3c=0x0;for(;_0x36827c[_0x5c1208]['id']!=_0x36827c[_0x75294b]['pairId'];)'elementStart'==_0x36827c[_0x5c1208]['type']?_0x171e3c++:'elementEnd'==_0x36827c[_0x5c1208]['type']&&_0x171e3c--,_0x5c1208++;if(0x0!=_0x171e3c){if(_0x36827c[_0x75294b]['isRemoved'])_0x36827c[_0x75294b]['isIncorrect']=!0x0;else{for(;_0x5c1208!=_0x75294b;)_0x36827c[_0x5c1208]['isRemoved']&&0x0!=_0x36827c[_0x5c1208]['distance']&&(_0x36827c[_0x5c1208]['isIncorrect']=!0x0,_0x44ba71['add'](_0x36827c[_0x5c1208]['pairId'])),_0x5c1208--;}}}return _0x36827c['filter'](_0x178d6d=>!_0x178d6d['isIncorrect']);}['_removeUnsupportedChanges'](_0x5c96d5){const _0x4225e8=this['editor']['model']['schema'];for(let _0x4d5cf4=0x0;_0x4d5cf4<_0x5c96d5['length'];_0x4d5cf4++){if(!(_0x5c96d5[_0x4d5cf4]['isAdded']||_0x5c96d5[_0x4d5cf4]['isAddSuggestion']||_0x5c96d5[_0x4d5cf4]['isRemoved']||_0x5c96d5[_0x4d5cf4]['isRemoveSuggestion']))continue;if(0x0==_0x5c96d5[_0x4d5cf4]['distance'])continue;const _0x2ef8a7=_0x5c96d5[_0x4d5cf4]['item'];_0x4225e8['isBlock'](_0x2ef8a7)||_0x4225e8['isLimit'](_0x2ef8a7)||(_0x5c96d5[_0x4d5cf4]['isAdded']&&delete _0x5c96d5[_0x4d5cf4]['isAdded'],_0x5c96d5[_0x4d5cf4]['isAddSuggestion']&&delete _0x5c96d5[_0x4d5cf4]['isAddSuggestion'],_0x5c96d5[_0x4d5cf4]['isRemoveSuggestion']&&delete _0x5c96d5[_0x4d5cf4]['isRemoveSuggestion'],_0x5c96d5[_0x4d5cf4]['isRemoved']&&(_0x5c96d5[_0x4d5cf4]['isIncorrect']=!0x0));}return _0x5c96d5['filter'](_0x1efbc0=>!_0x1efbc0['isIncorrect']);}['_makeModelFromTape'](_0x2e8ccb,_0x8d7b0b,_0x5cc86a){const _0x242bca=new _0x8c84c8(),_0x58c932=[],_0x53ea10=new Map(),_0x32694c=this['editor']['model'],_0x5aaa67=_0x32694c['schema'],_0x57c8a8=[_0x242bca],_0x52f2ab={},_0x1782a7={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x58b069=null;const _0x1b408d=[0x0];for(let _0x317674=0x0;_0x317674<_0x2e8ccb['length'];_0x317674++)if('elementStart'===_0x2e8ccb[_0x317674]['type']){_0x2e8ccb[_0x317674]['previousPosition']=_0x32694c['createPositionFromPath'](_0x242bca,_0x1b408d);const _0x4905da=new _0x36b445(_0x2e8ccb[_0x317674]['item']['name'],_0x2e8ccb[_0x317674]['item']['getAttributes']());_0x57c8a8[0x0]['_appendChild'](_0x4905da),_0x1b408d['push'](0x0),_0x57c8a8['unshift'](_0x4905da),_0x2e8ccb[_0x317674]['nextPosition']=_0x32694c['createPositionFromPath'](_0x242bca,_0x1b408d);}else'elementEnd'===_0x2e8ccb[_0x317674]['type']?(_0x57c8a8['shift'](),_0x2e8ccb[_0x317674]['previousPosition']=_0x32694c['createPositionFromPath'](_0x242bca,_0x1b408d),_0x1b408d['pop'](),_0x1b408d[_0x1b408d['length']-0x1]++,_0x2e8ccb[_0x317674]['nextPosition']=_0x32694c['createPositionFromPath'](_0x242bca,_0x1b408d)):(_0x2e8ccb[_0x317674]['previousPosition']=_0x32694c['createPositionFromPath'](_0x242bca,_0x1b408d),_0x58b069?_0x58b069['_data']+=_0x2e8ccb[_0x317674]['item']['data']:_0x58b069=new _0x367598(_0x2e8ccb[_0x317674]['item']['data'],_0x2e8ccb[_0x317674]['item']['getAttributes']()),_0x2e8ccb[_0x317674+0x1]&&'text'===_0x2e8ccb[_0x317674+0x1]['type']&&_0x252208(_0x58b069,_0x2e8ccb[_0x317674+0x1]['item'])||(_0x57c8a8[0x0]['_appendChild'](_0x58b069),_0x58b069=null),_0x1b408d[_0x1b408d['length']-0x1]+=_0x2e8ccb[_0x317674]['item']['offsetSize'],_0x2e8ccb[_0x317674]['nextPosition']=_0x32694c['createPositionFromPath'](_0x242bca,_0x1b408d));for(let _0x5624b6=0x0;_0x5624b6<_0x2e8ccb['length'];_0x5624b6++){const _0x3a23f6=_0x2e8ccb[_0x5624b6]['previousPosition'],_0x1266d2=_0x2e8ccb[_0x5624b6]['nextPosition'];for(const _0x62e343 of _0x2e8ccb[_0x5624b6]['markersStart'])_0x53ea10['set'](_0x62e343,{'start':_0x3a23f6,'end':null});_0x178c3c('isRemoveSuggestion',_0x5624b6,_0x3a23f6,_0x1266d2),_0x178c3c('isAddSuggestion',_0x5624b6,_0x3a23f6,_0x1266d2),_0x178c3c('isRemoved',_0x5624b6,_0x3a23f6,_0x1266d2),_0x178c3c('isAdded',_0x5624b6,_0x3a23f6,_0x1266d2);for(const _0x18ec44 of _0x2e8ccb[_0x5624b6]['markersEnd']){const _0x320da4=_0x53ea10['get'](_0x18ec44);_0x320da4?_0x320da4['end']=_0x1266d2:_0x53ea10['set'](_0x18ec44,{'start':_0x1266d2,'end':_0x1266d2});}}for(const [_0x17730e,_0x2432d1]of _0x53ea10){const _0x790c5f=this['editor']['model']['createRange'](_0x2432d1['start'],_0x2432d1['end']);_0x242bca['markers']['set'](_0x17730e,_0x790c5f);}return _0x58c932['sort']((_0x3fc501,_0x21e4ed)=>{const _0x468630=_0x242bca['markers']['get']('revision:'+_0x3fc501['id']),_0x33221e=_0x242bca['markers']['get']('revision:'+_0x21e4ed['id']);return _0x468630['start']['isBefore'](_0x33221e['start'])?-0x1:_0x468630['start']['isAfter'](_0x33221e['start'])?0x1:_0x468630['end']['isBefore'](_0x33221e['end'])?-0x1:_0x468630['end']['isAfter'](_0x33221e['end'])?0x1:'add'===_0x3fc501['type']?-0x1:0x1;}),{'root':_0x242bca,'changes':_0x58c932};function _0x178c3c(_0x3d81aa,_0x5434c0,_0x2a497c,_0x59d5ca){const _0xb83d97=!!_0x2e8ccb[_0x5434c0][_0x3d81aa],_0x5f6cee=_0xb83d97?_0x2e8ccb[_0x5434c0][_0x3d81aa]['userId']:null,_0x27bfeb=_0x5434c0===_0x2e8ccb['length']-0x1,_0x5678a9=_0x1782a7[_0x3d81aa][0x0],_0x9e1cc=_0x5aaa67['isObject'](_0x2e8ccb[_0x5434c0]['item']);!_0x52f2ab[_0x3d81aa]&&_0xb83d97?_0x52f2ab[_0x3d81aa]={'start':_0x2a497c,'tapeItem':_0x2e8ccb[_0x5434c0],'userId':_0x5f6cee,'type':_0x3d81aa}:_0x52f2ab[_0x3d81aa]&&!_0xb83d97?(_0x52f2ab[_0x3d81aa]['end']=_0x2a497c,_0x438d1c(_0x52f2ab[_0x3d81aa]),_0x52f2ab[_0x3d81aa]=null):_0x52f2ab[_0x3d81aa]&&_0xb83d97&&_0x52f2ab[_0x3d81aa]['userId']!==_0x5f6cee&&(_0x52f2ab[_0x3d81aa]['end']=_0x2a497c,_0x5678a9&&_0x5678a9['userId']===_0x52f2ab[_0x3d81aa]['userId']||_0x438d1c(_0x52f2ab[_0x3d81aa]),_0x52f2ab[_0x3d81aa]={'start':_0x2a497c,'tapeItem':_0x2e8ccb[_0x5434c0],'userId':_0x5f6cee,'type':_0x3d81aa}),_0x52f2ab[_0x3d81aa]&&_0x9e1cc&&('elementStart'!==_0x2e8ccb[_0x5434c0]['type']||_0x5678a9&&_0x5678a9['userId']===_0x5f6cee||_0x1782a7[_0x3d81aa]['unshift']({'userId':_0x5f6cee,'object':_0x2e8ccb[_0x5434c0]['item'],'change':_0x52f2ab[_0x3d81aa]}),'elementEnd'===_0x2e8ccb[_0x5434c0]['type']&&_0x5678a9&&_0x5678a9['object']===_0x2e8ccb[_0x5434c0]['item']&&(_0x1782a7[_0x3d81aa]['shift'](),_0x52f2ab[_0x3d81aa]=_0x5678a9['change'])),_0x52f2ab[_0x3d81aa]&&_0x27bfeb&&(_0x52f2ab[_0x3d81aa]['end']=_0x59d5ca,_0x438d1c(_0x52f2ab[_0x3d81aa]),_0x52f2ab[_0x3d81aa]=null);}function _0x438d1c({start:_0x5b3cfc,end:_0x55475a,tapeItem:_0x1baeee,userId:_0x5e6ba1,type:_0x5c6f1d}){const _0x17076b=_0x1baeee['item'],_0x1d1e95=_0x32694c['schema']['isBlock'](_0x17076b)&&!_0x32694c['schema']['isLimit'](_0x17076b),_0x2c3f84=_0x5b3cfc['nodeAfter']==_0x55475a['parent']&&_0x55475a['isAtStart'];if(_0x1d1e95&&_0x2c3f84)return;const _0xb1ebe5=_0x32694c['createRange'](_0x5b3cfc,_0x55475a),_0x21bbb9=_0x8d7b0b['get'](_0x5e6ba1),_0x4306ec=new G({'author':_0x21bbb9,'type':'isAdded'==_0x5c6f1d||'isAddSuggestion'==_0x5c6f1d?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x5c6f1d||'isRemoveSuggestion'==_0x5c6f1d},'createdAt':new Date(),'rootName':_0x5cc86a});_0x58c932['push'](_0x4306ec),_0x242bca['markers']['set']('revision:'+_0x4306ec['id'],_0xb1ebe5);}function _0x252208(_0x4ad7f4,_0x41aa8f){const _0xadb9e5=_0x4ad7f4['getAttributes'](),_0x43f893=_0x41aa8f['getAttributes']();for(const _0x4decf4 of _0xadb9e5){if(_0x4decf4[0x1]!==_0x41aa8f['getAttribute'](_0x4decf4[0x0]))return!0x1;_0x43f893['next']();}return _0x43f893['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x3ca752=>{const _0x515370=_0x3ca752['markerName']['split'](':')[0x1],_0xf18685=this['_getChangeFromId'](_0x515370);if(!_0xf18685)return null;const _0x3719fc='add'==_0xf18685['type']?'insertion':'deletion',_0x2327b6=['ck-suggestion-marker','ck-suggestion-marker-'+_0x3719fc];return _0xf18685['data']['isSuggestion']&&_0x2327b6['push']('ck-suggestion-marker-'+_0x3719fc+'-new'),this['activeChange']==_0xf18685&&_0x2327b6['push']('ck-suggestion-marker--active'),{'classes':_0x2327b6,'attributes':{'data-change-id':_0x515370}};}}),this['editor']['conversion']['for']('upcast')['add'](_0xb60797=>{_0xb60797['on']('element:pre',(_0x5846ca,_0x1563f1,_0x594613)=>{const _0x1d509b=_0x1563f1['viewItem']['getChild'](0x0);if(!_0x1d509b||!_0x1d509b['is']('element','code'))return;if(!_0x594613['consumable']['consume'](_0x1d509b,{'attributes':['vid_start','vid_end']}))return;const _0x5b3714=_0x1563f1['modelRange']['start']['nodeAfter'];_0x594613['writer']['setAttribute']('vid_start',_0x1d509b['getAttribute']('vid_start'),_0x5b3714),_0x594613['writer']['setAttribute']('vid_end',_0x1d509b['getAttribute']('vid_end'),_0x5b3714);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x19ac0d=>{_0x19ac0d['on']('element',(_0x1bf9e6,_0x1db0d3,_0x154304)=>{if(!_0x154304['consumable']['consume'](_0x1db0d3['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x1db0d3['modelRange']['isCollapsed'])return;const _0x285298=_0x1db0d3['modelRange']['start']['nodeAfter'];_0x285298['hasAttribute']('vid_start')||_0x285298['hasAttribute']('vid')||(_0x154304['writer']['setAttribute']('vid_start',_0x1db0d3['viewItem']['getAttribute']('vid_start'),_0x285298),_0x154304['writer']['setAttribute']('vid_end',_0x1db0d3['viewItem']['getAttribute']('vid_end'),_0x285298));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x323620=>_0x323620['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x3acb4d,[,_0x386ea7])=>{['vid_start','vid_end','vid']['includes'](_0x386ea7)&&(_0x3acb4d['return']=!0x0,_0x3acb4d['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x30b250=>{_0x30b250['on']('attribute:vid',(_0x28e68a,_0x599c91,_0x56eac2)=>{if('\x20'!=_0x599c91['item']['data']||_0x599c91['item']['parent']['maxOffset']>0x1)return;if(!_0x56eac2['consumable']['consume'](_0x599c91['item'],_0x28e68a['name']))return;const _0x4d2df0=_0x56eac2['writer'],_0x574ae3=_0x56eac2['mapper']['toViewRange'](_0x599c91['range']);_0x4d2df0['wrap'](_0x574ae3,_0x4d2df0['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x399ccd){const _0x2d1cc5=_0x399ccd['plugins']['get']('RevisionViewer');return(_0x872862,_0x5143d3,_0x3cb4a9)=>{const _0x15246e=_0x5143d3['markerName']['split'](':')[0x1],_0xe12c9e=_0x2d1cc5['_getChangeFromId'](_0x15246e);if(!_0xe12c9e)return null;const _0x5934a='add'==_0xe12c9e['type']?'split':'merge';if(!_0x3cb4a9['consumable']['test'](_0x5143d3['markerRange'],_0x872862['name']))return;const _0xbdf84a=_0x5143d3['markerRange']['getWalker'](),_0x29e168=_0x5143d3['markerRange']['start'],_0x58fe55=_0x399ccd['model']['schema'];let _0x3fb43a=null,_0x141865=null,_0x2399a0=!0x1,_0x2d1a62=!0x1;for(const _0x5661a2 of _0xbdf84a){const _0xb00293=_0x5661a2['item'];_0x2399a0=_0x2399a0||_0x58fe55['isContent'](_0xb00293);const _0x470e68=_0x3cb4a9['mapper']['toViewElement'](_0xb00293);if(_0x470e68&&_0x470e68['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x5661a2['type']&&(_0x58fe55['isBlock'](_0xb00293)&&!_0x58fe55['isLimit'](_0xb00293)&&(_0xb00293['nextSibling']||_0x29e168['isAtEnd']?_0x3fb43a&&_0x3fb43a['parent']==_0xb00293||(_0x3fb43a=_0xb00293,_0x3eecd5(_0x5661a2['previousPosition']),_0x2d1a62=!0x0):_0x141865=_0x141865||_0x5661a2['previousPosition']));}function _0x3eecd5(_0x5ebfd9){const _0xb022d9=_0x3cb4a9['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x5934a}),_0x4bad47=_0x3cb4a9['mapper']['toViewPosition'](_0x5ebfd9);_0xe12c9e['data']['isSuggestion']&&_0x3cb4a9['writer']['addClass']('ck-suggestion-marker-'+_0x5934a+'-new',_0xb022d9),_0x2d1cc5['activeChange']==_0xe12c9e&&_0x3cb4a9['writer']['addClass']('ck-suggestion-marker--active',_0xb022d9),_0x3cb4a9['writer']['insert'](_0x4bad47,_0xb022d9),_0x3cb4a9['mapper']['bindElementToMarker'](_0xb022d9,_0x5143d3['markerName']);}_0x2399a0||_0x2d1a62||!_0x141865||_0x3eecd5(_0x141865);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x183929,_0x2b990a,_0x4f7066)=>{const _0x547f02=_0x4f7066['mapper']['markerNameToElements'](_0x2b990a['markerName']);if(_0x547f02){for(const _0x207779 of _0x547f02)(_0x207779['hasClass']('ck-suggestion-marker-split')||_0x207779['hasClass']('ck-suggestion-marker-merge'))&&(_0x4f7066['mapper']['unbindElementFromMarkerName'](_0x207779,_0x2b990a['markerName']),_0x4f7066['writer']['remove'](_0x207779));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x185518,_0x548ec4,_0x222d58)=>{const _0x5577a4=_0x548ec4['markerName']['split'](':')[0x1],_0x3c8e0e=this['_getChangeFromId'](_0x5577a4);if(!_0x3c8e0e)return null;const _0x2c8ad5='add'==_0x3c8e0e['type']?'split':'merge';if(_0x222d58['consumable']['test'](_0x548ec4['markerRange'],_0x185518['name']))for(const _0x410e76 of _0x548ec4['markerRange']['getItems']()){if(!_0x410e76['is']('element','softBreak'))continue;const _0x37213b=_0x222d58['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x2c8ad5}),_0x27016b=_0x222d58['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x410e76));_0x3c8e0e['data']['isSuggestion']&&_0x222d58['writer']['addClass']('ck-suggestion-marker-'+_0x2c8ad5+'-new',_0x37213b),this['activeChange']==_0x3c8e0e&&_0x222d58['writer']['addClass']('ck-suggestion-marker--active',_0x37213b),_0x222d58['writer']['insert'](_0x27016b,_0x37213b),_0x222d58['mapper']['bindElementToMarker'](_0x37213b,_0x548ec4['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x1fe74b=>{for(const _0x58301d of this['editor']['model']['document']['getRootNames']()){const _0x5d66f5=this['editor']['model']['document']['getRoot'](_0x58301d),_0x1aa0fc=this['editor']['editing']['view']['document']['getRoot'](_0x58301d);if(_0x1aa0fc){const _0x357bab=_0x5d66f5['getAttribute']('revisionHistoryAttachChange');if(_0x1fe74b['removeAttribute']('data-change-id',_0x1aa0fc),_0x1fe74b['removeClass']('ck-revision-history-root-add',_0x1aa0fc),_0x1fe74b['removeClass']('ck-revision-history-root-remove',_0x1aa0fc),_0x1fe74b['removeClass']('ck-revision-history-root--active',_0x1aa0fc),_0x357bab){const _0x379e1b=this['_getChangeFromId'](_0x357bab);if(!_0x379e1b)return null;_0x1fe74b['setAttribute']('data-change-id',_0x357bab,_0x1aa0fc),_0x1fe74b['addClass']('ck-revision-history-root-'+_0x379e1b['type'],_0x1aa0fc),this['activeChange']==_0x379e1b&&_0x1fe74b['addClass']('ck-revision-history-root--active',_0x1aa0fc);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x2d0112=>'revision-comment:'+_0x2d0112,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x522cf0=>'revision-suggestion:'+_0x522cf0,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x20f2ef=>({'name':'suggestion:'+_0x20f2ef,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x3dffae=>{const _0x5402b6=_0x3dffae['markerName']['split'](':')[0x1];return'insertion'!=_0x5402b6&&'deletion'!=_0x5402b6?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x5402b6]};}}),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',(_0x3a635d,_0x4f6660,_0x515f20)=>{const _0x51b963=_0x515f20['mapper']['markerNameToElements'](_0x4f6660['markerName']);if(_0x51b963){for(const _0xc45d2c of _0x51b963)_0xc45d2c['is']('uiElement')&&(_0x515f20['mapper']['unbindElementFromMarkerName'](_0xc45d2c,_0x4f6660['markerName']),_0x515f20['writer']['remove'](_0xc45d2c));}},{'priority':'high'});}['_getChangeFromId'](_0xe1d884){return this['_changeIdToChange']['get'](_0xe1d884);}['_getViewForChange'](_0x18239d){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new z(this['editor']['locale'],_0x18239d),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x4d78ea,_0xc4c29,_0x179e7a,_0x27805b)=>{_0x27805b&&this['_balloon']['remove'](_0x27805b),_0x179e7a&&(this['_balloon']['add']({'view':_0x179e7a,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x1ccd8c=this['editor']['editing'],_0xbd6ce0=this['_getChangeFromId'](_0x179e7a['changeId']);let _0x38c267;if(_0xbd6ce0['data']['isOnRoot']){const _0x2280b4=_0x1ccd8c['view']['getDomRoot'](_0xbd6ce0['rootName']);_0x38c267=Array['from'](_0x2280b4['getClientRects']());}else{const _0x51b47c=this['editor']['model']['markers']['get']('revision:'+_0x179e7a['changeId']);_0x38c267=Array['from'](_0x1ccd8c['mapper']['markerNameToElements'](_0x51b47c['name']))['map'](_0x37d9a8=>_0x1ccd8c['view']['domConverter']['mapViewToDom'](_0x37d9a8))['map'](_0x31a09d=>Array['from'](_0x31a09d['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x38c267[0x0];return _0x38c267['find'](_0x351c2b=>_0x351c2b['top']-0x3<=this['_activeViewTarget']['y']&&_0x351c2b['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x351c2b['left']-0x3<=this['_activeViewTarget']['x']&&_0x351c2b['right']+0x3>=this['_activeViewTarget']['x'])||_0x38c267[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x54a2b5,_0x29ac9f,_0x405df6,_0x19f4e7)=>{this['activeView']=_0x405df6?this['_getViewForChange'](_0x405df6):null,this['editor']['model']['change'](()=>{const _0x41a091=this['editor']['editing'];_0x19f4e7&&(_0x19f4e7['data']['isOnRoot']?_0x41a091['view']['change'](_0x5a8929=>{_0x5a8929['removeClass']('ck-revision-history-root--active',_0x41a091['view']['document']['getRoot'](_0x19f4e7['rootName']));}):_0x41a091['reconvertMarker']('revision:'+_0x19f4e7['id'])),_0x405df6&&(_0x405df6['data']['isOnRoot']?_0x41a091['view']['change'](_0x4bc1cc=>{_0x4bc1cc['addClass']('ck-revision-history-root--active',_0x41a091['view']['document']['getRoot'](_0x405df6['rootName']));}):_0x41a091['reconvertMarker']('revision:'+_0x405df6['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x3a1c39,_0x3ccd40)=>{if(this['activeChange'])return;const _0x2a2581=this['_findChangeIdFromDomTarget'](_0x3ccd40['target']),_0xc968f0=this['_changeIdToChange']['get'](_0x2a2581);_0xc968f0?(this['_activeViewTarget']={'x':_0x3ccd40['domEvent']['x'],'y':_0x3ccd40['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0xc968f0)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x527deb,_0x1cd368)=>{const _0x25a75b=this['_findChangeIdFromDomTarget'](_0x1cd368['target']),_0x45bf4e=this['_changeIdToChange']['get'](_0x25a75b);_0x45bf4e?(this['_activeViewTarget']={'x':_0x1cd368['domEvent']['x'],'y':_0x1cd368['domEvent']['y']},_0x45bf4e===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x45bf4e):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x10b218){do{const _0x5a8e05=_0x10b218['getAttribute']('data-change-id');if(_0x5a8e05)return _0x5a8e05;_0x10b218=_0x10b218['parent'];}while(_0x10b218);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x453dd6=>{for(const _0x777f07 of this['editor']['model']['markers'])_0x453dd6['removeMarker'](_0x777f07);});}}function Q(_0x52ba96,_0x236b13){return(_0x15d129,_0x3c68b5,_0x5581f5)=>{if(!_0x5581f5['consumable']['test'](_0x3c68b5['markerRange'],_0x15d129['name']))return;const _0x4e2b24=_0x3c68b5['markerRange']['getWalker'](),_0x68fe75=_0x3c68b5['markerRange']['start'],_0x26882a=_0x52ba96['model']['schema'];let _0x50dcde=null,_0xe56afb=null,_0x5e3145=!0x1,_0x18f6f6=!0x1;for(const _0x1ff4d2 of _0x4e2b24){const _0x3b5a15=_0x1ff4d2['item'];_0x5e3145=_0x5e3145||_0x26882a['isContent'](_0x3b5a15);const _0x179d45=_0x5581f5['mapper']['toViewElement'](_0x3b5a15);if(_0x179d45&&_0x179d45['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x1ff4d2['type']&&(_0x26882a['isBlock'](_0x3b5a15)&&!_0x26882a['isLimit'](_0x3b5a15)&&(_0x3b5a15['nextSibling']||_0x68fe75['isAtEnd']?_0x50dcde&&_0x50dcde['parent']==_0x3b5a15||(_0x50dcde=_0x3b5a15,_0x2c999a(_0x1ff4d2['previousPosition']),_0x18f6f6=!0x0):_0xe56afb=_0xe56afb||_0x1ff4d2['previousPosition']));}function _0x2c999a(_0x4e8fd9){const _0x1a88e6=_0x5581f5['mapper']['toViewPosition'](_0x4e8fd9),_0x41f318=_0x5581f5['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x236b13});_0x5581f5['writer']['insert'](_0x1a88e6,_0x41f318),_0x5581f5['mapper']['bindElementToMarker'](_0x41f318,_0x3c68b5['markerName']);}_0x5e3145||_0x18f6f6||!_0xe56afb||_0x2c999a(_0xe56afb);};}class nt extends _0x4856a5{constructor(_0xd479fc){super(_0xd479fc);const _0x1027a2=_0xd479fc['plugins']['get'](u);this['affectsData']=!0x1,this['listenTo'](_0x1027a2,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x1027a2,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x5daa20=this['editor'],_0x2d6715=_0x5daa20['plugins']['get'](u),_0x3f7f50=_0x2d6715['isReady']?_0x2d6715['diff']['newRevisionId']:null;_0x5daa20['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x3f7f50);}['refresh'](){const {isReady:_0x415a69,isEnabled:_0x4da55a,repository:_0x45a023,diff:_0x19bc19}=this['editor']['plugins']['get'](u),_0x1c47da=_0x19bc19&&_0x45a023['getLaterVisibleRevision'](_0x19bc19['newRevisionId']);this['isEnabled']=_0x415a69&&_0x4da55a&&Boolean(_0x1c47da);}}class rt extends _0x4856a5{['_step'];constructor(_0x33233a,{direction:_0x23d726}){super(_0x33233a);const _0x3b9753=_0x33233a['plugins']['get'](u);this['affectsData']=!0x1,this['_step']='forward'===_0x23d726?0x1:-0x1,this['listenTo'](_0x3b9753,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x3b9753,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x3b9753,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x4d2802=this['editor'],_0x4dd573=_0x4d2802['plugins']['get'](u),{isNavigationMode:_0x1dfc10,currentChangeNumber:_0x558584}=_0x4dd573;let _0x4f2fc0;if(_0x4dd573['activeChange']=_0x1dfc10?_0x4dd573['diff']['changes']['get'](_0x558584+this['_step']):_0x4dd573['diff']['changes']['first'],_0x4dd573['activeChange']['data']['isOnRoot'])_0x4f2fc0=_0x4d2802['editing']['view']['getDomRoot'](_0x4dd573['activeChange']['rootName']);else{const _0x5bd95f=_0x4d2802['model']['markers']['get']('revision:'+_0x4dd573['activeChange']['id']);_0x4f2fc0=_0x1f08bc(_0x4d2802['editing'],_0x5bd95f);}_0x3a5a7e({'target':_0x4f2fc0,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x4d73fd,currentChangeNumber:_0xc345de,numberOfChanges:_0x23bd13,isReady:_0xcca12f,isEnabled:_0x2b3934}=this['editor']['plugins']['get'](u);this['isEnabled']=!!(_0x2b3934&&_0xcca12f&&_0x23bd13)&&(!_0x4d73fd||(0x1===this['_step']?_0xc345de<_0x23bd13-0x1:_0xc345de>0x0));}}class Ri extends _0x4eb8a3{constructor(_0x460c68){super(_0x460c68);const _0x515c83=this['bindTemplate'],_0x37329f=new _0x41a1a9(_0x460c68),_0x40a43e=new _0x41a1a9(_0x460c68);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',(_0x49761c,_0x4be9d6)=>_0x49761c&&_0x4be9d6>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x2feee6,_0x67075a,_0x2e25ec,_0x11d09a)=>{if(!_0x2feee6)return m(_0x460c68,'Loading...');if(!_0x2e25ec)return m(_0x460c68,'No\x20changes');const _0x5a272d=m(_0x460c68,'NUMBER_OF_CHANGES',_0x2e25ec);return _0x11d09a?m(_0x460c68,'X_OF_Y_CHANGES',[_0x67075a+0x1,_0x2e25ec]):_0x5a272d;}),_0x37329f['set']({'label':m(_0x460c68,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x4fea33}),_0x40a43e['set']({'label':m(_0x460c68,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0xaf50d4}),_0x37329f['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x40a43e['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x37329f['on']('execute',()=>this['fire']('execute','backward')),_0x40a43e['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',_0x515c83['if']('_isStatusLabelVisible','ck-hidden',_0x5218d2=>!_0x5218d2)]},'children':[{'text':_0x515c83['to']('isNavigationMode',_0x49ef1f=>_0x49ef1f?m(_0x460c68,'EDIT_X_OF_Y_REVISIONS')+':\x20':m(_0x460c68,'Total')+':\x20')}]},{'text':_0x515c83['to']('_statusText')}]},new _0x4bb486(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x37329f,_0x40a43e]}]});}}const ge='ck-editor__editable__loading-overlay';class ji extends _0xbe21c4{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x29c48c=this['editor']['editing']['view'];_0x29c48c['change'](_0x5382f2=>{for(const _0x1e0da5 of _0x29c48c['document']['roots'])_0x5382f2['addClass'](ge,_0x1e0da5);});}['hide'](){const _0x449639=this['editor']['editing']['view'];_0x449639['change'](_0x212952=>{for(const _0x433201 of _0x449639['document']['roots'])_0x212952['removeClass'](ge,_0x433201);});}}class v extends _0xbe21c4{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u,ji];}['init'](){const _0x56a944=this['editor'],_0x2acc35=_0x56a944['plugins']['get'](u),_0x19b829=_0x56a944['plugins']['get'](ji);_0x56a944['ui']['componentFactory']['add']('exitToEditing',_0x45271f=>{const _0x579d13=new _0x41a1a9(_0x45271f);return _0x579d13['set']({'label':m(_0x45271f,'Back\x20to\x20editing'),'icon':_0x31592a,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x579d13,'execute',()=>{_0x56a944['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x579d13;}),_0x56a944['ui']['componentFactory']['add']('restoreRevision',_0x3b269a=>{const _0x332dd8=new _0x41a1a9(_0x3b269a);return _0x332dd8['set']({'label':m(_0x3b269a,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x332dd8['bind']('isEnabled')['to'](_0x56a944['commands']['get']('restoreRevision')),this['listenTo'](_0x332dd8,'execute',()=>_0x56a944['execute']('restoreRevision')),_0x332dd8;}),_0x56a944['ui']['componentFactory']['add']('changesNavigation',_0x39b333=>{const _0x44eebf=new Ri(_0x39b333),_0x174861=_0x56a944['commands']['get']('showPreviousChange'),_0x547a8c=_0x56a944['commands']['get']('showNextChange');return _0x44eebf['bind']('isBackwardNavigationEnabled')['to'](_0x174861,'isEnabled'),_0x44eebf['bind']('isForwardNavigationEnabled')['to'](_0x547a8c,'isEnabled'),_0x44eebf['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x2acc35),this['listenTo'](_0x44eebf,'execute',(_0x141e24,_0x14415c)=>{_0x56a944['execute']('forward'===_0x14415c?'showNextChange':'showPreviousChange');}),_0x44eebf;}),_0x19b829['show'](),_0x2acc35['on']('change:isReady',(_0xf8b8f2,_0x3d69c0,_0x9bb713)=>{_0x9bb713?_0x19b829['hide']():_0x19b829['show']();});}}class hi extends et{['_resizeObserver']=null;constructor(_0x414a77,_0x4d7b57){super(_0x414a77,_0x4d7b57);const _0x29c568=this['bindTemplate'];this['set']({'label':m(_0x414a77,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=m(_0x414a77,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x29c568['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 _0x45d5e2=this['fieldView']['element'];this['_tooltipString']=_0x45d5e2['scrollWidth']>_0x45d5e2['clientWidth']&&_0x45d5e2['value']||'';}}class ni extends _0x4eb8a3{constructor(_0x4bd174,_0xda9fea,_0x3f11ee){super(_0x4bd174);const _0x5f5485=new _0x517cab();_0x5f5485['set']({'content':_0x21d8a3,'viewBox':'0\x200\x2011\x2010'});const _0xe4b36=['ck','ck-revision-history-sidebar__revision-author'];_0x3f11ee&&_0xe4b36['push']('ck-revision-history-sidebar__revision-author_creator');const _0x385da0=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':m(_0x4bd174,_0x3f11ee?'Revision\x20creator':'Revision\x20author')},'children':[_0x5f5485,_0xda9fea['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0xe4b36},'children':_0x385da0});}}function ai(_0x60784d,_0x3d95c5){const _0x1adb1f=_0x60784d['bindTemplate'],_0x35618a=_0x60784d['locale'],_0xe876a5=_0x1e23a0(_0x35618a);_0xe876a5['panelPosition']='sw';const _0x205617=function(_0x3df2cd,_0x5957d4){const _0x5f50f4=function(_0x3294e7,_0x22045c){const _0x5af13e=_0x3294e7['locale'],_0x17e885={'Compare\x20against\x20selected':m(_0x5af13e,'Compare\x20against\x20selected'),'Name\x20this\x20revision':m(_0x5af13e,'Name\x20this\x20revision'),'Restore\x20this\x20revision':m(_0x5af13e,'Restore\x20this\x20revision')};return _0x22045c['map'](_0x426ed8=>{const _0x508b45=_0x17e885[_0x426ed8['name']];return _0x508b45&&_0x508b45!==_0x426ed8['name']&&(_0x426ed8['name']=_0x508b45),_0x426ed8;});}(_0x3df2cd,_0x5957d4),_0x31ba26=new _0x504df2();for(const _0x40fea9 of _0x5f50f4){const _0x3fb40d={'type':'button','model':new to({'label':_0x40fea9['name'],'class':_0x40fea9['class'],'withText':!0x0,'role':'menuitem','_action':_0x40fea9['action']})};_0x3fb40d['model']['bind']('isEnabled')['to'](_0x3df2cd,'isActionsDropdownOpen',_0x1e462e=>'function'!=typeof _0x40fea9['isEnabled']||(!_0x1e462e||_0x40fea9['isEnabled'](_0x3df2cd))),_0x31ba26['add'](_0x3fb40d);}return _0x31ba26;}(_0x60784d,_0x3d95c5);return _0x60784d['bind']('isActionsDropdownOpen')['to'](_0xe876a5,'isOpen'),_0xe876a5['buttonView']['set']({'label':m(_0x35618a,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x3f675d}),_0xe876a5['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x1adb1f['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x1adb1f['to'](_0xa5d333=>_0xa5d333['stopPropagation']())}}),_0xe876a5['on']('execute',_0x4bfb7e=>{_0x60784d['isReady']&&'function'==typeof _0x4bfb7e['source']['_action']&&_0x4bfb7e['source']['_action'](_0x60784d);}),_0x105741(_0xe876a5,_0x205617,{'role':'menu'}),_0xe876a5['listenTo'](_0x60784d,'change:isActionsDropdownOpen',(_0x1b383a,_0x3da273,_0x12bdc7)=>{if(_0x12bdc7)for(const _0x21f683 of _0xe876a5['listView']['items']){const _0x5325a1=_0x21f683['children']['first'],_0xeafb9f=_0x3d95c5['find'](_0x2511a1=>_0x2511a1['action']===_0x5325a1['_action'])['isVisible'];_0x21f683['isVisible']=void 0x0===_0xeafb9f||_0xeafb9f(_0x60784d);}}),_0xe876a5;}class _i extends/* #__PURE__ -- @preserve */
27
- _0x43b418(_0x4eb8a3){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x5738c6,_0x5b97df,_0x4d84a6,_0xc41357){super(_0x5738c6);const _0x1e17f5=this['bindTemplate'],_0x13e4e2=function(_0x3a8e67,_0x56c60e){const _0x1cff2f=Array['from'](_0x56c60e['authors'])['filter'](_0x8d36a7=>_0x8d36a7!=_0x56c60e['creator']);return _0x56c60e['creator']&&_0x1cff2f['unshift'](_0x56c60e['creator']),_0x1cff2f['map'](_0x19f14f=>new ni(_0x3a8e67,_0x19f14f,_0x19f14f==_0x56c60e['creator']));}(_0x5738c6,_0x5b97df);this['id']=_0x5b97df['id'],this['_revision']=_0x5b97df,this['_requireRevisionName']=_0xc41357,this['bind']('name','createdAt')['to'](_0x5b97df),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x12c4c9=>{return _0x7a894a=_0x5738c6['uiLanguage'],(_0x33ccb7=_0x12c4c9)['toLocaleDateString'](_0x7a894a,{'month':'long','day':'numeric'})+',\x20'+_0x33ccb7['toLocaleTimeString'](_0x7a894a,{'hour':'numeric','minute':'numeric'});var _0x7a894a,_0x33ccb7;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new hi(_0x5738c6,ti),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x12b581=>_0x12b581||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x27086c,_0x4633b6)=>_0x27086c&&_0x4633b6),this['revisionActionsView']=_0x4d84a6&&_0x4d84a6['length']?ai(this,_0x4d84a6):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x1e17f5['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x1e17f5['if']('isEnabled','ck-disabled',_0x4b7288=>!_0x4b7288),_0x1e17f5['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x1e17f5['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x1e17f5['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':_0x1e17f5['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':_0x13e4e2}]},this['revisionActionsView']],'on':{'click':_0x1e17f5['to'](_0x28f86e=>{_0x28f86e['srcElement']['closest']('.ck-confirm-view')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x13d4ec=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x13d4ec,'change',()=>{this['_requireRevisionName']&&!_0x13d4ec['value']||this['fire']('setName',{'id':this['id'],'name':_0x13d4ec['value']}),_0x13d4ec['value']||(_0x13d4ec['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(_0x18435a,_0x2b122d){const _0x367910=_0x275244['fromJSDate'](_0x18435a)['setLocale'](_0x2b122d),_0x14f443=_0x275244['local'](),_0x32045f=_0x14f443['minus']({'days':0x1})['startOf']('day');let _0x29eeaa,_0x569009;return _0x367910['hasSame'](_0x14f443,'day')?(_0x29eeaa=_0x367910['startOf']('day')['toJSDate'](),_0x569009=_0x367910['toRelativeCalendar']()):_0x367910['hasSame'](_0x32045f,'day')?(_0x29eeaa=_0x32045f['toJSDate'](),_0x569009=_0x367910['toRelativeCalendar']()):_0x367910['hasSame'](_0x14f443,'week')?(_0x29eeaa=_0x367910['startOf']('week')['toJSDate'](),_0x569009=_0x367910['weekdayLong']||''):_0x367910['hasSame'](_0x14f443,'year')?(_0x29eeaa=_0x367910['startOf']('month')['toJSDate'](),_0x569009=_0x367910['monthLong']||''):(_0x29eeaa=_0x367910['startOf']('year')['toJSDate'](),_0x569009=String(_0x367910['year'])),{'startDate':_0x29eeaa,'localizedPeriodName':_0x569009};}class bi extends _0x4eb8a3{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x3059d7,_0xdeb8f9,_0x304654,_0x4f7d57){super(_0x3059d7);const _0x36f166=li(_0xdeb8f9,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0xdeb8f9,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x304654,this['_requireRevisionName']=_0x4f7d57,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':_0x36f166}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x344626){const _0x5c4019=new _i(this['locale'],_0x344626,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x5c4019);}['removeRevision'](_0x4efe99){const _0x3eae06=this['revisionViews']['find'](_0xaa8716=>_0xaa8716['id']===_0x4efe99['id']);this['revisionViews']['remove'](_0x3eae06);}}class fi extends _0x4eb8a3{constructor(_0x259d88){super(_0x259d88);const _0x3fc5c5=new _0x517cab();_0x3fc5c5['content']=_0x672cd0,this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x3fc5c5,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[m(_0x259d88,'Revision\x20history')]}]});}}class di extends _0x4eb8a3{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x1dc235,_0x55de06,_0x312992,_0x2314cf){super(_0x1dc235);const _0x4ae934=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x55de06,this['_revisionActions']=_0x312992,this['_requireRevisionName']=_0x2314cf,this['on']('select',(_0x1b6688,_0x34db07)=>{this['fire']('revisionSelected',_0x34db07);}),this['on']('setName',(_0x317f7d,_0x45ea94)=>{this['fire']('revisionSetName',_0x45ea94);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new fi(_0x1dc235),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x4ae934['if']('isEnabled','ck-disabled',_0x3e6253=>!_0x3e6253)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x383695 of this['_revisions'])this['_addRevision'](_0x383695);this['_revisions']['on']('add',(_0x89542c,_0x5baa9b)=>{this['_addRevision'](_0x5baa9b);}),this['_revisions']['on']('remove',(_0x2e7fdb,_0x43f4f4)=>{this['_removeRevision'](_0x43f4f4);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x2b8f0d=>_0x2b8f0d['revisionViews']['map'](_0xdcc3f9=>_0xdcc3f9))['flat']();}['selectRevision'](_0x3fea49){for(const _0x37bd0a of this['revisionViews'])_0x3fea49&&_0x3fea49['id']===_0x37bd0a['id']?_0x37bd0a['select']():_0x37bd0a['deselect']();}['highlightRevisions'](_0x1f5965){for(const _0x4266e1 of this['revisionViews'])_0x1f5965['some'](({id:_0x331499})=>_0x331499===_0x4266e1['id'])?_0x4266e1['highlight']():_0x4266e1['unhighlight']();}['_addRevision'](_0x57916a){const _0x8d6df1=li(_0x57916a['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x2cbaff=this['timePeriodViews']['get'](0x0);_0x2cbaff&&_0x2cbaff['startDate']['getTime']()===_0x8d6df1['getTime']()||(_0x2cbaff=new bi(this['locale'],_0x8d6df1,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x2cbaff)),_0x2cbaff['addRevision'](_0x57916a);}['_removeRevision'](_0x2219da){const _0x1b873d=li(_0x2219da['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x1b873d)['removeRevision'](_0x2219da);}['_getTimePeriodViewByStartDate'](_0x1f3f6c){return this['timePeriodViews']['find'](_0x58756f=>_0x58756f['startDate']['getTime']()===_0x1f3f6c['getTime']());}}class d extends _0xbe21c4{['_revisionViewer'];['_revisionsRepository'];['_sidebarView'];static ['defaultRevisionActions']=/* #__PURE__ -- @preserve */
23
+ import{ObservableMixin as _0x182a87,uid as _0x49424b,Collection as _0x145165,logWarning as _0x5cd68a,FocusTracker as _0x338607,KeystrokeHandler as _0x532e86,scrollViewportToShowTarget as _0x48db3b,ResizeObserver as ot,ElementReplacer as it,CKEditorError as _0x3ff139}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x14aaba,set as _0x59806c,unset as _0x5793a7,isEqual as _0x249b5b}from'es-toolkit/compat';import{Plugin as _0x1b7918,PendingActions as _0x45dd93,Command as _0x554035,ElementApiMixin as _0xaa91f4,Editor as _0x245eaf}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x510ab1,getMarkerDomElement as _0x111bd2,ConfirmMixin as _0x1f577a,sanitizeEditorConfig as _0x5b8a19}from'ckeditor5-collaboration/dist/index.js';import{ViewContainerElement as _0x4a3664,ViewAttributeElement as _0x2daa1d,ViewEmptyElement as _0x2ba950,ViewRawElement as _0x108008,ViewUIElement as _0xfc827c,ViewDocumentFragment as _0x53cdaf,ViewText as _0x2e6047,ViewElement as _0x35f99c,ModelElement as _0x3ade8a,ModelRange as _0x145ffd,ModelPosition as _0x116ae8,ModelDocumentFragment as _0x597820,ModelText as _0x545827}from'@ckeditor/ckeditor5-engine/dist/index.js';import{IconHistory as _0x2ce2b3,IconChevronUp as _0x3b92ff,IconChevronDown as _0x309adf,IconUndo as _0x1d2949,IconUser as _0x211003,IconThreeVerticalDots as _0xc39968}from'@ckeditor/ckeditor5-icons/dist/index.js';import{CssTransitionDisablerMixin as _0x2b1f83,View as _0x526abe,submitHandler as _0x23680f,LabeledFieldView as et,createLabeledInputText as ti,createDropdown as _0x103105,ListView as _0x3526a8,ListItemView as _0x36648d,ButtonView as _0x3ff6ba,MenuBarMenuView as _0x279b98,MenuBarMenuListView as _0x2b22ab,MenuBarMenuListItemView as _0x9bf8f3,MenuBarMenuListItemButtonView as _0x2a94f6,ContextualBalloon as _0x3f9961,ToolbarSeparatorView as _0x1c80e1,IconView as _0x40cca7,addListToDropdown as _0x1c4b56,UIModel as to,EditorUI as tt,normalizeToolbarConfig as st,BoxedEditorUIView as _0x37d6bb,StickyPanelView as _0x5c2a56,ToolbarView as _0x12a455,InlineEditableUIView as te}from'@ckeditor/ckeditor5-ui/dist/index.js';import{DateTime as _0x1e540a}from'luxon';class I extends/* #__PURE__ -- @preserve */
24
+ _0x182a87(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x34a600){super(),this['id']=_0x34a600['id']||_0x49424b(),this['creator']=_0x34a600['creator']||null,this['authors']=_0x34a600['authors']||[],this['diffData']=_0x34a600['diffData']||null,this['toVersion']=_0x34a600['toVersion']||0x0,this['fromVersion']=_0x34a600['fromVersion']||0x0,this['set']('name',_0x34a600['name']||''),this['set']('createdAt',_0x34a600['createdAt']||new Date()),this['set']('attributes',_0x34a600['attributes']||{});}['setName'](_0x13303e){this['_update']({'name':_0x13303e});}['setAttribute'](_0x190e98,_0x3f0a13){const _0x33820b=_0x14aaba(this['attributes']);_0x59806c(_0x33820b,_0x190e98,_0x3f0a13),this['_update']({'attributes':_0x33820b});}['removeAttribute'](_0x46f706){const _0x1a7d3c=_0x14aaba(this['attributes']);_0x5793a7(_0x1a7d3c,_0x46f706),this['_update']({'attributes':_0x1a7d3c});}['_update'](_0x3cfc12,_0x1808a9=!0x1){let _0x1c1042=!0x1;const _0x15f627={'id':this['id']},_0x1173b0=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x2b24ba of _0x1173b0){const _0x522931=_0x3cfc12[_0x2b24ba];void 0x0!==_0x522931&&_0x522931!==this[_0x2b24ba]&&(this[_0x2b24ba]=_0x522931,_0x15f627[_0x2b24ba]=_0x522931,_0x1c1042=!0x0);}_0x1c1042&&(_0x15f627['authors']&&(_0x15f627['authorsIds']=_0x15f627['authors']['map'](_0xe460a3=>_0xe460a3['id']),delete _0x15f627['authors']),this['fire']('_update',_0x15f627,_0x1808a9));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0xbe1f74=>_0xbe1f74['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class S extends _0x1b7918{['_revisions'];static get['requires'](){return[_0x510ab1];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x1ee611){super(_0x1ee611),this['_revisions']=new _0x145165();}['afterInit'](){!async function(_0x52de1d){const _0x394c27=_0x4c56e6([0x76,0x73,0x6d,0x4c,0x34,0x54,0x50,0x70,0x75,0x52,0x35,0x33,0x4d,0x6c,0x71,0x53,0x6a,0x32,0x56,0x58,0x77,0x48,0x39,0x6f,0x45,0x41,0x4e,0x38,0x46,0x78,0x4a,0x74,0x47,0x55,0x4f,0x64,0x62,0x44,0x43,0x5a,0x30,0x31,0x69,0x68,0x79,0x66,0x6b,0x42,0x51,0x59,0x36,0x61,0x63,0x67,0x7a,0x37,0x72,0x49,0x65,0x57,0x4b,0x6e]),_0x4a3882=0xeb829,_0x1d4dae=0x359e09b0,_0x2f224d=0x35997700^_0x1d4dae,_0xa0e3b9=window[_0x4c56e6([0x44,0x61,0x74,0x65])][_0x4c56e6([0x6e,0x6f,0x77])](),_0x5660ff=_0x52de1d[_0x4c56e6([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x1626c0=new window[(_0x4c56e6([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x915d06=>{_0x5660ff[_0x4c56e6([0x6f,0x6e,0x63,0x65])](_0x4c56e6([0x72,0x65,0x61,0x64,0x79]),_0x915d06);}),_0x180cc7={[_0x4c56e6([0x6b,0x74,0x79])]:_0x4c56e6([0x45,0x43]),[_0x4c56e6([0x75,0x73,0x65])]:_0x4c56e6([0x73,0x69,0x67]),[_0x4c56e6([0x63,0x72,0x76])]:_0x4c56e6([0x50,0x2d,0x32,0x35,0x36]),[_0x4c56e6([0x78])]:_0x4c56e6([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]),[_0x4c56e6([0x79])]:_0x4c56e6([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]),[_0x4c56e6([0x61,0x6c,0x67])]:_0x4c56e6([0x45,0x53,0x32,0x35,0x36])},_0x26bc80=_0x5660ff[_0x4c56e6([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x4c56e6([0x67,0x65,0x74])](_0x4c56e6([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x58f860(){let _0x475625,_0x588db6=null,_0x87cfe3=null;try{if(_0x26bc80==_0x4c56e6([0x47,0x50,0x4c]))return _0x4c56e6([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x475625=_0x5aed96(),!_0x475625)return _0x4c56e6([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x475625[_0x4c56e6([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x87cfe3=_0x38b999(_0x475625[_0x4c56e6([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x475625[_0x4c56e6([0x6a,0x74,0x69])])),await _0x5c05c3()?_0x303bc9()?_0x1a4189()?_0x4c56e6([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x545d05()?(_0x475625[_0x4c56e6([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x4c56e6([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x588db6=_0x1b935d(_0x4c56e6([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),await _0x297603()):_0x4c56e6([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x4c56e6([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x4c56e6([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x4c56e6([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x1a4189(){const _0x362697=[_0x4c56e6([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x4c56e6([0x74,0x72,0x69,0x61,0x6c])][_0x4c56e6([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x475625[_0x4c56e6([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0xa0e3b9/0x3e8:0xe10*_0x2f224d;return _0x475625[_0x4c56e6([0x65,0x78,0x70])]<_0x362697;}function _0x303bc9(){const _0x180489=_0x475625[_0x4c56e6([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x180489)return!0x1;if(_0x180489[_0x4c56e6([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4c56e6([0x2a])))return!0x0;if(_0x180489[_0x4c56e6([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4c56e6([0x52,0x48])))return!0x0;if(_0x180489[_0x4c56e6([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4c56e6([0x52,0x52,0x48]))){if(_0x4bb97d())return!0x0;if(_0x16905f()||_0x407b23())return!0x0;}return!0x1;}function _0x545d05(){const _0x429284=_0x475625[_0x4c56e6([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x429284||0x0==_0x429284[_0x4c56e6([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x5295e8}=new URL(window[_0x4c56e6([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x429284[_0x4c56e6([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x5295e8))return!0x0;const _0x362c0d=_0x5295e8[_0x4c56e6([0x73,0x70,0x6c,0x69,0x74])](_0x4c56e6([0x2e]));return _0x429284[_0x4c56e6([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x19a7cb=>_0x19a7cb[_0x4c56e6([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x4c56e6([0x2a])))[_0x4c56e6([0x6d,0x61,0x70])](_0x5d3fd6=>_0x5d3fd6[_0x4c56e6([0x73,0x70,0x6c,0x69,0x74])](_0x4c56e6([0x2e])))[_0x4c56e6([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x26f063=>_0x26f063[_0x4c56e6([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x362c0d[_0x4c56e6([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x4c56e6([0x6d,0x61,0x70])](_0x3aff27=>Array(_0x362c0d[_0x4c56e6([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0x3aff27[_0x4c56e6([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x4c56e6([0x66,0x69,0x6c,0x6c])](_0x3aff27[0x0]===_0x4c56e6([0x2a])?_0x4c56e6([0x2a]):'')[_0x4c56e6([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0x3aff27))[_0x4c56e6([0x73,0x6f,0x6d,0x65])](_0x4ff989=>_0x362c0d[_0x4c56e6([0x65,0x76,0x65,0x72,0x79])]((_0x192964,_0x7ce8a)=>_0x4ff989[_0x7ce8a]===_0x192964||_0x4ff989[_0x7ce8a]===_0x4c56e6([0x2a])));}function _0x297603(){return _0x588db6&&_0x87cfe3?new window[(_0x4c56e6([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x2ec0bf,_0xfe3814)=>{_0x588db6[_0x4c56e6([0x74,0x68,0x65,0x6e])](_0x2ec0bf,_0xfe3814),_0x87cfe3[_0x4c56e6([0x74,0x68,0x65,0x6e])](_0x31ce18=>{_0x31ce18!=_0x4c56e6([0x56,0x61,0x6c,0x69,0x64])&&_0x2ec0bf(_0x31ce18);},_0xfe3814);}):_0x588db6||_0x87cfe3||_0x4c56e6([0x56,0x61,0x6c,0x69,0x64]);}}function _0x38b999(_0x5cbdf4,_0x3fadae){return new window[(_0x4c56e6([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x1e73fc=>{if(_0x404310())return _0x1e73fc(_0x4c56e6([0x56,0x61,0x6c,0x69,0x64]));_0x1ca02d(),_0x5660ff[_0x4c56e6([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x4c56e6([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x1843a6=!0x1;const _0x5791f8=_0x49424b();function _0x178c72(_0x56f7e8){return!!_0x56f7e8&&(typeof _0x56f7e8===_0x4c56e6([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x56f7e8===_0x4c56e6([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x56f7e8[_0x4c56e6([0x74,0x68,0x65,0x6e])]===_0x4c56e6([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x56f7e8[_0x4c56e6([0x63,0x61,0x74,0x63,0x68])]===_0x4c56e6([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x1fcf8f(_0x35de4e){_0x3e7319(_0x35de4e)[_0x4c56e6([0x74,0x68,0x65,0x6e])](_0x441924=>{if(!_0x441924||_0x441924[_0x4c56e6([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x4c56e6([0x6f,0x6b]))return _0x4c56e6([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x5c7471(_0x5ea2fa(_0x5791f8+_0x3fadae))!=_0x441924[_0x4c56e6([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x4c56e6([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x4c56e6([0x56,0x61,0x6c,0x69,0x64]);})[_0x4c56e6([0x74,0x68,0x65,0x6e])](_0x3ee6d7=>(_0x331a6b(),_0x3ee6d7),()=>{const _0x54f4ec=_0x442de2();return null==_0x54f4ec?(_0x331a6b(),_0x4c56e6([0x56,0x61,0x6c,0x69,0x64])):_0x4c56e6(_0xa0e3b9-_0x54f4ec>(0x11928db0^_0x1d4dae)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x4c56e6([0x74,0x68,0x65,0x6e])](_0x1e73fc)[_0x4c56e6([0x63,0x61,0x74,0x63,0x68])](()=>{_0x1e73fc(_0x4c56e6([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x211f3b=0x35a8e730^_0x1d4dae;function _0x331a6b(){const _0x3bf77e=_0x4c56e6([0x6c,0x6c,0x63,0x74,0x2d])+_0x5c7471(_0x5ea2fa(_0x5cbdf4)),_0xa44cbf=_0x44cf22(_0x5c7471(window[_0x4c56e6([0x4d,0x61,0x74,0x68])][_0x4c56e6([0x63,0x65,0x69,0x6c])](_0xa0e3b9/_0x211f3b)));window[_0x4c56e6([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x4c56e6([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x3bf77e,_0xa44cbf);}function _0x442de2(){const _0x5dd250=_0x4c56e6([0x6c,0x6c,0x63,0x74,0x2d])+_0x5c7471(_0x5ea2fa(_0x5cbdf4)),_0x460336=window[_0x4c56e6([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x4c56e6([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x5dd250);return _0x460336?window[_0x4c56e6([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x44cf22(_0x460336),0x10)*_0x211f3b:null;}function _0x3e7319(_0x4ff4a0){return new window[(_0x4c56e6([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x12659c,_0x43a572)=>{_0x4ff4a0[_0x4c56e6([0x74,0x68,0x65,0x6e])](_0x12659c,_0x43a572),window[_0x4c56e6([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x43a572,0x359fdd70^_0x1d4dae);});}}_0x5660ff[_0x4c56e6([0x6f,0x6e])](_0x4c56e6([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x10ad0e,_0x3fc175)=>{if(_0x3fc175[0x0]!=_0x5cbdf4)return _0x1e73fc(_0x4c56e6([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x3fc175[0x1]={..._0x3fc175[0x1],[_0x4c56e6([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x5791f8};},{[_0x4c56e6([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x4c56e6([0x68,0x69,0x67,0x68])}),_0x5660ff[_0x4c56e6([0x6f,0x6e])](_0x4c56e6([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x4849b4=>{_0x178c72(_0x4849b4[_0x4c56e6([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x1843a6=!0x0,_0x1fcf8f(_0x4849b4[_0x4c56e6([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x4c56e6([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x4c56e6([0x6c,0x6f,0x77])}),_0x1626c0[_0x4c56e6([0x74,0x68,0x65,0x6e])](()=>{_0x1843a6||_0x1e73fc(_0x4c56e6([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x404310(){return _0x5660ff[_0x4c56e6([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x4c56e6([0x76,0x69,0x65,0x77])][_0x4c56e6([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x4c56e6([0x61,0x75,0x74,0x6f]);}function _0x1ca02d(){_0x5660ff[_0x4c56e6([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x4c56e6([0x76,0x69,0x65,0x77])][_0x4c56e6([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x4c56e6([0x61,0x75,0x74,0x6f]);}}function _0x1b935d(_0x461fa7){const _0x2994d4=[new window[(_0x4c56e6([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x5b3a10=>setTimeout(_0x5b3a10,0x3597377c^_0x1d4dae)),_0x1626c0[_0x4c56e6([0x74,0x68,0x65,0x6e])](()=>new window[(_0x4c56e6([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x4f737a=>{const _0x366797=0x359e09b7^_0x1d4dae,_0x9f8f8b=_0x52de1d[_0x4c56e6([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x12842d(){_0x9f8f8b[_0x4c56e6([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x366797&&_0x4f737a();}_0x12842d(),_0x9f8f8b[_0x4c56e6([0x6f,0x6e])](_0x4c56e6([0x61,0x64,0x64]),_0x12842d);})),new window[(_0x4c56e6([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x5b6edf=>{function _0x5c1cad(){for(const _0x342f91 in window)if(window[_0x4c56e6([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x4c56e6([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x342f91))&&window[_0x342f91]==_0x4a3882)return _0x5b6edf();_0x5660ff[_0x4c56e6([0x73,0x74,0x61,0x74,0x65])]!=_0x4c56e6([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x4c56e6([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x5c1cad,0x359e1a38^_0x1d4dae);}_0x471382(_0x4c56e6([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x5c1cad();})];return window[_0x4c56e6([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x4c56e6([0x72,0x61,0x63,0x65])](_0x2994d4)[_0x4c56e6([0x74,0x68,0x65,0x6e])](()=>_0x461fa7);}async function _0x4673c5(){if(await _0x1626c0,_0x471382(_0x4c56e6([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x2b31d5=_0x52de1d[_0x4c56e6([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x4198c7=_0x52de1d[_0x4c56e6([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])](_0x2b31d5[_0x4c56e6([0x69,0x64])]),_0xe22e64=_0x442c5c(_0x4c56e6([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0xe22e64[_0x4c56e6([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x2b31d5['id'],_0x4198c7?_0x4198c7['id']:null,!0x0),_0xe22e64[_0x4c56e6([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x4c56e6([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0xe22e64[_0x4c56e6([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0xe22e64[_0x4c56e6([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0xa18e63,void(_0xe22e64[_0x4c56e6([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0xa18e63);}if(_0x471382(_0x4c56e6([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x39f3ac=_0x442c5c(_0x4c56e6([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x39f3ac[_0x4c56e6([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x4c56e6([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x39f3ac[_0x4c56e6([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x39f3ac[_0x4c56e6([0x75,0x70,0x64,0x61,0x74,0x65])]=_0xa18e63,_0x39f3ac[_0x4c56e6([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0xa18e63;}_0x5660ff[_0x4c56e6([0x6d,0x6f,0x64,0x65,0x6c])][_0x4c56e6([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0xa18e63,_0x5660ff[_0x4c56e6([0x6d,0x6f,0x64,0x65,0x6c])][_0x4c56e6([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0xa18e63,_0x5660ff[_0x4c56e6([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x4c56e6([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x4bb97d(){return _0x471382(_0x4c56e6([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x442c5c(_0x4c56e6([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x4c56e6([0x73,0x74,0x61,0x74,0x65])]==_0x4c56e6([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x16905f(){return _0x471382(_0x4c56e6([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 _0x407b23(){return _0x471382(_0x4c56e6([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x246d5d(_0x1f34c3){const _0x40e381=_0xa92bda();_0x5660ff[_0x40e381]=_0x4c56e6([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])+_0x1f34c3,_0x1f34c3[_0x4c56e6([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x4c56e6([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0xa92bda()]=_0x4a3882),_0x1f34c3!=_0x4c56e6([0x56,0x61,0x6c,0x69,0x64])&&_0x4673c5();}function _0xa92bda(){const _0x4d0416=window[_0x4c56e6([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x4c56e6([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x4c56e6([0x6e,0x6f,0x77])]())[_0x4c56e6([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x4c56e6([0x2e]),'');let _0x593a78=_0x4c56e6([0x76]);for(let _0x11d050=0x0;_0x11d050<_0x4d0416[_0x4c56e6([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x11d050+=0x2){let _0x3466a9=window[_0x4c56e6([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x4d0416[_0x4c56e6([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x11d050,_0x11d050+0x2));_0x3466a9>=_0x394c27[_0x4c56e6([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x3466a9-=_0x394c27[_0x4c56e6([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x593a78+=_0x394c27[_0x3466a9];}return _0x593a78;}function _0x5aed96(){const _0x3a034b=_0x26bc80[_0x4c56e6([0x73,0x70,0x6c,0x69,0x74])](_0x4c56e6([0x2e]));if(0x3!=_0x3a034b[_0x4c56e6([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x4e01df(_0x3a034b[0x1]);function _0x4e01df(_0x4f3919){const _0x4a87ef=_0x431d10(_0x4f3919);return _0x4a87ef&&_0x23d562()?_0x4a87ef:null;function _0x23d562(){const _0x406a17=_0x4a87ef[_0x4c56e6([0x6a,0x74,0x69])],_0x4516d2=window[_0x4c56e6([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x406a17[_0x4c56e6([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x406a17[_0x4c56e6([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x2e1637={..._0x4a87ef,[_0x4c56e6([0x6a,0x74,0x69])]:_0x406a17[_0x4c56e6([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x406a17[_0x4c56e6([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x2e1637[_0x4c56e6([0x76,0x63])],_0x5ea2fa(_0x2e1637)==_0x4516d2;}}}async function _0x5c05c3(){let _0x3380a6=!0x0;try{const _0x12a137=_0x26bc80[_0x4c56e6([0x73,0x70,0x6c,0x69,0x74])](_0x4c56e6([0x2e])),[_0x4130d0,_0xc45d2c,_0x27862b]=_0x12a137;return _0x4e4ab0(_0x4130d0),await _0x6d07c8(_0x4130d0,_0xc45d2c,_0x27862b),_0x3380a6;}catch{return!0x1;}function _0x4e4ab0(_0x2ae608){const _0x4dcaff=_0x431d10(_0x2ae608);_0x4dcaff&&_0x4dcaff[_0x4c56e6([0x61,0x6c,0x67])]==_0x4c56e6([0x45,0x53,0x32,0x35,0x36])||(_0x3380a6=!0x1);}async function _0x6d07c8(_0x446d5e,_0x75dd0d,_0x41a57b){const _0x4ac8a4=window[_0x4c56e6([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x4c56e6([0x66,0x72,0x6f,0x6d])](_0x11192e(_0x41a57b),_0x434ba1=>_0x434ba1[_0x4c56e6([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x3568f0=new window[(_0x4c56e6([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x4c56e6([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x446d5e+_0x4c56e6([0x2e])+_0x75dd0d),_0x1752d5=window[_0x4c56e6([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x4c56e6([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x1752d5)return;const _0x39426e=await _0x1752d5[_0x4c56e6([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x4c56e6([0x6a,0x77,0x6b]),_0x180cc7,{[_0x4c56e6([0x6e,0x61,0x6d,0x65])]:_0x4c56e6([0x45,0x43,0x44,0x53,0x41]),[_0x4c56e6([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x4c56e6([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x4c56e6([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x1752d5[_0x4c56e6([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x4c56e6([0x6e,0x61,0x6d,0x65])]:_0x4c56e6([0x45,0x43,0x44,0x53,0x41]),[_0x4c56e6([0x68,0x61,0x73,0x68])]:{[_0x4c56e6([0x6e,0x61,0x6d,0x65])]:_0x4c56e6([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x39426e,_0x4ac8a4,_0x3568f0)||(_0x3380a6=!0x1);}}function _0x431d10(_0x45ddf9){return _0x45ddf9[_0x4c56e6([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x4c56e6([0x65,0x79]))?JSON[_0x4c56e6([0x70,0x61,0x72,0x73,0x65])](_0x11192e(_0x45ddf9)):null;}function _0x11192e(_0x3f0206){return window[_0x4c56e6([0x61,0x74,0x6f,0x62])](_0x3f0206[_0x4c56e6([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x4c56e6([0x2b]))[_0x4c56e6([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x4c56e6([0x2f])));}function _0x5ea2fa(_0x514756){let _0x11f9bf=0x1505;function _0x1861a4(_0x6f7033){for(let _0x4eeb44=0x0;_0x4eeb44<_0x6f7033[_0x4c56e6([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x4eeb44++){const _0x2c9020=_0x6f7033[_0x4c56e6([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x4eeb44);_0x11f9bf=(_0x11f9bf<<0x5)+_0x11f9bf+_0x2c9020,_0x11f9bf&=_0x11f9bf;}}function _0x19a39d(_0x4efbfa){Array[_0x4c56e6([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x4efbfa)?_0x4efbfa[_0x4c56e6([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x19a39d):_0x4efbfa&&typeof _0x4efbfa==_0x4c56e6([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x4c56e6([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x4efbfa)[_0x4c56e6([0x73,0x6f,0x72,0x74])]()[_0x4c56e6([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x1c46eb,_0x301cba])=>{_0x1861a4(_0x1c46eb),_0x19a39d(_0x301cba);}):_0x1861a4(window[_0x4c56e6([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x4efbfa));}return _0x19a39d(_0x514756),_0x11f9bf>>>0x0;}function _0x5c7471(_0x4eec40){return _0x4eec40[_0x4c56e6([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x4c56e6([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x4c56e6([0x30]));}function _0x44cf22(_0x570c34){return _0x570c34[_0x4c56e6([0x73,0x70,0x6c,0x69,0x74])]('')[_0x4c56e6([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x4c56e6([0x6a,0x6f,0x69,0x6e])]('');}function _0x471382(_0x134a9e){return _0x5660ff[_0x4c56e6([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x4c56e6([0x68,0x61,0x73])](_0x134a9e);}function _0x442c5c(_0x3b764d){return _0x5660ff[_0x4c56e6([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x4c56e6([0x67,0x65,0x74])](_0x3b764d);}function _0xa18e63(){}function _0x4c56e6(_0xebfb8f){return _0xebfb8f['map'](_0x32bc69=>String['fromCharCode'](_0x32bc69))['join']('');}_0x246d5d(await _0x58f860());}(this);}['createRevision'](_0x4da7a2){const _0x55c41c=this['editor']['plugins']['get']('Users');return new I({'id':_0x4da7a2['id'],'name':_0x4da7a2['name'],'creator':_0x4da7a2['creatorId']?_0x55c41c['getUser'](_0x4da7a2['creatorId']):null,'diffData':_0x4da7a2['diffData']||_0x4da7a2['data'],'authors':_0x4da7a2['authorsIds']['map'](_0x1414c1=>_0x55c41c['getUser'](_0x1414c1)),'createdAt':new Date(_0x4da7a2['createdAt']),'attributes':_0x4da7a2['attributes'],'fromVersion':_0x4da7a2['fromVersion'],'toVersion':_0x4da7a2['toVersion']});}['addRevision'](_0x42d0d1,_0x8c06d4=0x0){this['_revisions']['add'](_0x42d0d1,_0x8c06d4);}['getRevision'](_0x44d517){return this['_revisions']['get'](_0x44d517);}['getRevisions'](_0x1fa1bc={'toJSON':!0x1}){const _0x562619=Array['from'](this['_revisions']);return _0x562619['reverse'](),_0x1fa1bc['toJSON']?_0x562619['map'](_0x4ca252=>_0x4ca252['toJSON']()):_0x562619;}['getIndex'](_0x3e1819){return this['_revisions']['getIndex'](_0x3e1819);}['getEarlierVisibleRevision'](_0x18c269){const [,_0x40fc73]=this['getRevisionsIterator'](_0x18c269,{'direction':'earlier'});return _0x40fc73;}['getLaterVisibleRevision'](_0x156731){const [,_0xef53fe]=this['getRevisionsIterator'](_0x156731,{'direction':'later'});return _0xef53fe;}['getRevisionsInDiff'](_0x3f67fe){const _0x1963eb=[];for(const _0x261d13 of this['getRevisionsIterator'](_0x3f67fe['newRevisionId']))if(_0x1963eb['push'](_0x261d13),_0x261d13['id']===_0x3f67fe['oldRevisionId'])break;return _0x1963eb;}*['getRevisionsIterator'](_0x46cb81,{direction:_0x2b34e5='earlier',filter:_0x21f33d=()=>!0x0}={}){const _0x1f853b='earlier'===_0x2b34e5?0x1:-0x1;let _0x536774=this['_revisions']['get'](_0x46cb81),_0x510dea=this['getIndex'](_0x536774);for(yield _0x536774;_0x536774;){if(_0x510dea+=_0x1f853b,_0x536774=this['getRevision'](_0x510dea),!_0x536774)return;_0x21f33d(_0x536774)&&(yield _0x536774);}}}class $ extends _0x1b7918{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x4a3664,'c'],[_0x2daa1d,'a'],[_0x2ba950,'e'],[_0x108008,'r'],[_0xfc827c,'u']]);['_typeCharToViewClass']=new Map([['c',_0x4a3664],['a',_0x2daa1d],['e',_0x2ba950],['r',_0x108008],['u',_0xfc827c]]);async['loadRevisionData'](_0xba8c7f,_0x5ed767){if(_0xba8c7f['diffData']||!_0x5ed767)return;const _0x1d7177=this['editor']['config']['get']('collaboration.channelId'),_0x2ecf11=await _0x5ed767['getRevision']({'channelId':_0x1d7177,'revisionId':_0xba8c7f['id']});_0xba8c7f['diffData']=_0x2ecf11['diffData'];}['getRevisionDocumentData'](_0x5da423){const _0x2d994e={};for(const _0x15875d in _0x5da423['diffData']){if(_0x5da423['diffData'][_0x15875d]['attachChange']&&!_0x5da423['diffData'][_0x15875d]['attachChange']['isAttached'])continue;const _0xc040a5=this['_removeRevisionMarkers'](JSON['parse'](_0x5da423['diffData'][_0x15875d]['insertions'])),_0x4b8992=this['editor']['editing']['view']['document'],_0x2ff22d=new _0x53cdaf(_0x4b8992,_0xc040a5['map'](_0x33890d=>this['_getViewFromDiffObj'](_0x33890d,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x2d994e[_0x15875d]=this['editor']['data']['processor']['toData'](_0x2ff22d),this['editor']['data']['processor']['useFillerType']('default');}return _0x2d994e;}['getRevisionRootsAttributes'](_0x3d009a){const _0x15e97b={};for(const _0x305528 in _0x3d009a['diffData'])_0x3d009a['diffData'][_0x305528]['attachChange']&&!_0x3d009a['diffData'][_0x305528]['attachChange']['isAttached']||(_0x15e97b[_0x305528]=_0x3d009a['diffData'][_0x305528]['attributesAfter']||{});return _0x15e97b;}['_getTypeCharForViewElement'](_0x2d5277){return this['_viewClassToTypeChar']['get'](_0x2d5277['constructor']);}['_getViewFromDiffObj'](_0x197432,_0x143c03){const _0x296530=this['editor']['editing']['view']['document'];if('string'==typeof _0x197432)return new _0x2e6047(_0x296530,_0x197432);{let _0x235fbd,_0x25356c;_0x25356c='u'==_0x197432['type']||'r'==_0x197432['type']?[]:_0x197432['children']['map'](_0x2eea14=>this['_getViewFromDiffObj'](_0x2eea14,_0x143c03));const _0x3af18e=this['_typeCharToViewClass']['get'](_0x197432['type'])||_0x35f99c,_0x4245eb=this['editor']['data']['htmlProcessor']['domConverter'];if(_0x235fbd=new _0x3af18e(_0x296530,_0x197432['name'],_0x197432['attributes'],_0x25356c),'u'==_0x197432['type']&&_0x197432['children'][0x0]){const _0x132850=_0x197432['children'][0x0];if(_0x235fbd['render']=function(_0x17bd39){const _0x20e893=_0x17bd39['createElement']('div');return _0x20e893['innerHTML']=_0x132850,_0x20e893['childNodes'][0x0];},_0x143c03){const _0x47d60c=new _0x53cdaf(_0x296530);_0x47d60c['_appendChild'](_0x235fbd);const _0x26bb74=Array['from'](_0x4245eb['viewChildrenToDom'](_0x47d60c,{'bind':!0x1})),_0xa76a41=_0x4245eb['domDocument']['createElement']('div');_0xa76a41['append'](..._0x26bb74),_0x235fbd=Array['from'](_0x4245eb['domChildrenToView'](_0xa76a41))[0x0];}}else{if('r'==_0x197432['type']&&_0x197432['children'][0x0]){const _0x32a629=_0x197432['children'][0x0];if(_0x235fbd['render']=function(_0x817c7c){_0x817c7c['innerHTML']=_0x32a629;},_0x143c03){const _0x5cb14c=new _0x53cdaf(_0x296530);_0x5cb14c['_appendChild'](_0x235fbd);const _0x1cfaae=Array['from'](_0x4245eb['viewChildrenToDom'](_0x5cb14c,{'bind':!0x1})),_0x15115d=_0x4245eb['domDocument']['createElement']('div');_0x15115d['append'](..._0x1cfaae);const _0xc0b7e4=Array['from'](_0x4245eb['domChildrenToView'](_0x15115d));_0xc0b7e4['length']>0x1?_0x235fbd['_appendChild'](_0xc0b7e4):_0x235fbd=_0xc0b7e4[0x0];}}}if(_0x197432['customProperties']){for(const [_0x471a72,_0x3d0627]of _0x197432['customProperties'])_0x235fbd['_setCustomProperty'](_0x471a72,_0x3d0627);}const _0x156f44=void 0x0===_0x197432['fillerOffset']?null:_0x197432['fillerOffset'];return null!==_0x156f44&&(_0x235fbd['getFillerOffset']=()=>_0x156f44),_0x235fbd;}}['_makeModelFromViewString'](_0x2e50c8){const _0xa20d9a=JSON['parse'](_0x2e50c8),_0x58f207=this['editor']['editing']['view']['document'],_0x23fe95=new _0x53cdaf(_0x58f207,_0xa20d9a['map'](_0x4e45a7=>this['_getViewFromDiffObj'](_0x4e45a7,!0x0)));return this['editor']['data']['toModel'](_0x23fe95);}['_removeRevisionMarkers'](_0x366850){return(_0x366850=_0x366850['filter'](_0x4cef74=>!_0x4cef74['name']||'revision-start'!==_0x4cef74['name']&&'revision-end'!==_0x4cef74['name']))['forEach'](_0x97ce06=>{'string'!=typeof _0x97ce06&&(_0x97ce06['children']=this['_removeRevisionMarkers'](_0x97ce06['children']),_0x97ce06['attributes']=_0x97ce06['attributes']['filter'](_0x82e285=>!_0x82e285[0x0]['startsWith']('data-revision-')));}),_0x366850;}}function m(_0x1dd8b2,_0x1e19c5,_0xf08b87){const t=_0x1dd8b2['t'];switch(_0x1e19c5){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'},_0xf08b87);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0xf08b87);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 _0x1b7918{['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[_0x510ab1,S,$,_0x45dd93];}constructor(_0x295ae7){super(_0x295ae7),this['repository']=this['editor']['plugins']['get']('RevisionsRepository'),this['_utils']=this['editor']['plugins']['get']('RevisionHistoryUtils'),this['_revisionDataBuilder']=new x(this['editor']),this['_initialRevisionId']=this['editor']['config']['get']('collaboration.channelId')||'initial',this['_bufferedUpdates']=new Map(),this['_loadedStateData']=null;const _0x9e2ff1=_0x49424b();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x9e2ff1},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 _0xfca547=this['repository']['getRevision'](0x0),_0xc89b94=_0xfca547&&null===_0xfca547['creator']?_0xfca547:null;if(this['_continueCurrentRevision']=!!_0xc89b94&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x1c8046=this['_source']['getCurrentRevisionId'](),_0xc1115a=this['repository']['getRevision'](_0x1c8046);if(_0xc1115a)this['_startingVersion']=_0xc1115a['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x50927e=this['_source']['history']['_operations']['find'](_0x4f669f=>!_0x4f669f['_isInit']),_0x503bdb=_0x50927e?_0x50927e['baseVersion']:this['_source']['history']['version'];_0xfca547?(_0xfca547['toVersion']<_0x503bdb&&_0xfca547['_update']({'toVersion':_0x503bdb}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0xc89b94['id'],this['_startingVersion']=_0xc89b94['fromVersion']):(this['_startingVersion']=_0xfca547['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x503bdb,this['_continueCurrentRevision']=!0x1);}}else _0xc89b94&&(this['editor']['model']['document']['history']['version']=Math['max'](_0xc89b94['toVersion'],this['editor']['model']['document']['history']['version']),_0xc89b94['fromVersion']===_0xc89b94['toVersion']?(0x0!==_0xc89b94['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0xc89b94['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0xc89b94['id'],this['_startingVersion']=_0xc89b94['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',_0x355a4d=>!_0x355a4d),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x3b0690=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x49d648;for(const _0x1b0ff8 in _0x3b0690){const _0x5b8dd1=_0x1b0ff8,_0x117432=_0x3b0690[_0x5b8dd1];if('revisionHistoryLicenseKeyValid'==_0x117432||'revisionHistoryLicenseKeyInvalid'==_0x117432||'revisionHistoryLicenseKeyExpired'==_0x117432||'revisionHistoryLicenseKeyDomainLimit'==_0x117432||'revisionHistoryLicenseKeyNotAllowed'==_0x117432||'revisionHistoryLicenseKeyEvaluationLimit'==_0x117432||'revisionHistoryLicenseKeyUsageLimit'==_0x117432){delete _0x3b0690[_0x5b8dd1],_0x49d648=_0x117432,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x49d648&&_0x3b0690['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x49d648&&_0x3b0690['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x49d648&&_0x3b0690['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x49d648&&_0x3b0690['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x49d648&&_0x3b0690['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x49d648&&_0x3b0690['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x17eed1=this['repository']['getRevision'](0x0),_0x1740e3=await this['getRevisionDocumentData'](_0x17eed1),_0x33cf43=await this['getRevisionRootsAttributes'](_0x17eed1);this['_replaceEditorDataWithRevisionData'](_0x1740e3,_0x33cf43);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x465c2b){this['_source']=_0x465c2b;}async['update'](){const _0x2458f1=await this['_source']['getLatestVersion']();if(_0x2458f1>this['currentRevision']['toVersion']){await this['_loadState']();const _0x31e9dc=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x2458f1});_0x31e9dc['authors']=_0x31e9dc['authorsIds']['map'](_0x5684f9=>this['editor']['plugins']['get']('Users')['getUser'](_0x5684f9)),this['currentRevision']['_update'](_0x31e9dc);}}async['saveRevision'](_0xbdd6e7={},_0x47d970=null){const _0x2382ce=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x47d970>this['currentRevision']['toVersion']&&(_0x47d970=null),null===_0x47d970&&(_0x47d970=await this['_source']['getLatestVersion']());const _0x54a2ae=this['_getFromVersion'](_0x47d970),_0x3565f4=this['buildRevisionData']({'from':_0x54a2ae,'to':_0x47d970});if(this['currentRevision']['toVersion']<_0x47d970){const _0x5a3af8=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x47d970,'to':_0x47d970});_0x5a3af8['authors']=[],_0x5a3af8['authorsIds']=[],_0x5a3af8['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x5a3af8,!0x0),delete _0x5a3af8['authors'],_0x2382ce['push'](_0x5a3af8);}_0xbdd6e7['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0xbdd6e7['name']=_0xbdd6e7['name']||null,_0xbdd6e7['id']=_0xbdd6e7['id']||_0x49424b(),_0xbdd6e7={..._0xbdd6e7,..._0x3565f4};const _0x476e59=this['addRevisionData'](_0xbdd6e7);_0x2382ce['push'](_0xbdd6e7);const _0x4b476e=this['repository']['getIndex'](_0x476e59);if(0x0!==_0x4b476e){const _0x4e7016=this['repository']['getRevision'](_0x4b476e-0x1);if(_0x4e7016['fromVersion']!==_0x47d970){const _0x3f4659=this['_revisionDataBuilder']['getData'](_0x47d970,_0x4e7016['toVersion']),_0x27865e={'id':_0x4e7016['id'],'diffData':_0x3f4659['diffData'],'authorsIds':_0x3f4659['authorsIds'],'authors':_0x3f4659['authorsIds']['map'](_0xd447b0=>this['editor']['plugins']['get']('Users')['getUser'](_0xd447b0)),'fromVersion':_0x47d970};_0x4e7016===this['currentRevision']&&(_0x27865e['createdAt']=new Date(_0xbdd6e7['createdAt']['getTime']()+0xa)),_0x4e7016['_update'](_0x27865e,!0x0),delete _0x27865e['authors'],_0x2382ce['push'](_0x27865e);}}if(this['adapter']){for(const _0x55b591 of _0x2382ce)this['_bufferUpdate'](_0x55b591['id'],_0x55b591,!0x0);this['sendBufferedUpdates']();}return _0x476e59;}['addRevisionData'](_0x5a44b7){const _0x4c0542=this['repository']['createRevision'](_0x5a44b7);return this['adapter']&&_0x4c0542['on']('_update',(_0x2a3d82,_0x564e5c,_0x5a41e2)=>{_0x5a41e2||(this['_bufferUpdate'](_0x564e5c['id'],_0x564e5c,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x4c0542,this['_findInsertionIndex'](_0x4c0542)),_0x4c0542;}async['getRevisionDocumentData'](_0xc0cc74){return await this['_utils']['loadRevisionData'](_0xc0cc74,this['adapter']),this['_utils']['getRevisionDocumentData'](_0xc0cc74);}async['getRevisionRootsAttributes'](_0x2f10c0){return await this['_utils']['loadRevisionData'](_0x2f10c0,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x2f10c0);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x3b8228=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x58ad9a=0x0;_0x58ad9a<_0x3b8228['length'];_0x58ad9a++){const _0x185136=_0x3b8228[_0x58ad9a];let _0x53a0d3=!0x1;for(const _0x33e8b7 of Object['keys'](_0x185136))void 0x0===_0x185136[_0x33e8b7]?delete _0x185136[_0x33e8b7]:'id'!==_0x33e8b7&&(_0x53a0d3=!0x0);_0x53a0d3||(_0x3b8228[_0x58ad9a]=null);}if(_0x3b8228=_0x3b8228['filter'](_0x3e61c7=>null!==_0x3e61c7),!_0x3b8228['length'])return;for(let _0x2e68f7=0x0;_0x2e68f7<_0x3b8228['length'];_0x2e68f7++){const _0x2a3f7e=_0x3b8228[_0x2e68f7];void 0x0!==_0x2a3f7e['fromVersion']&&void 0x0===_0x2a3f7e['toVersion']&&(_0x2a3f7e['toVersion']=this['repository']['getRevision'](_0x2a3f7e['id'])['toVersion']),void 0x0!==_0x2a3f7e['toVersion']&&void 0x0===_0x2a3f7e['fromVersion']&&(_0x2a3f7e['fromVersion']=this['repository']['getRevision'](_0x2a3f7e['id'])['fromVersion']);}const _0x455e6f=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x3b8228,_0x455e6f)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x30689c=>{if(_0x30689c){for(const _0x397ba6 of _0x30689c)this['setRevisionData']({'id':_0x397ba6['id'],'createdAt':_0x397ba6['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0x2c57ef=null,from:_0x2d6416=null,to:_0x4d4634=null}){_0x2d6416=null!==_0x2d6416?_0x2d6416:_0x2c57ef['fromVersion'],_0x4d4634=null!==_0x4d4634?_0x4d4634:_0x2c57ef['toVersion'];const _0x1ce416=this['_revisionDataBuilder']['getData'](_0x2d6416,_0x4d4634),_0x3f7a6c={'diffData':_0x1ce416['diffData'],'authorsIds':_0x1ce416['authorsIds'],'fromVersion':_0x2d6416,'toVersion':_0x4d4634};if(!_0x2c57ef||_0x4d4634!==_0x2c57ef['toVersion']){const _0x45f4ba=_0x4d4634-0x1,_0xb12bc7=this['_source']['history']['getOperation'](_0x45f4ba);_0x3f7a6c['createdAt']=_0xb12bc7&&_0xb12bc7['createdAt']||new Date();}if(this['_loadedStateData']&&_0x2d6416===this['_loadedStateData']['fromVersion']){for(const _0x3065e9 of this['_loadedStateData']['authors'])_0x3f7a6c['authorsIds']['includes'](_0x3065e9['id'])||_0x3f7a6c['authorsIds']['push'](_0x3065e9['id']);}return _0x3f7a6c;}['_bufferUpdate'](_0x53c98d,_0x35f0e5,_0x472170){if(this['_bufferedUpdates']['has'](_0x53c98d)){const _0x3dd54d=this['_bufferedUpdates']['get'](_0x53c98d);_0x35f0e5=_0x472170?{..._0x3dd54d,..._0x35f0e5}:{..._0x35f0e5,..._0x3dd54d};}this['_bufferedUpdates']['set'](_0x53c98d,_0x35f0e5);}['setRevisionData'](_0x4c425a){const _0x4a69b9=this['repository']['getRevision'](_0x4c425a['id']);if(_0x4c425a['createdAt']&&(_0x4c425a['createdAt']=new Date(_0x4c425a['createdAt'])),_0x4c425a['authorsIds']){const _0x2e51d8=this['editor']['plugins']['get']('Users');_0x4c425a['authors']=_0x4c425a['authorsIds']['map'](_0x13dffd=>_0x2e51d8['getUser'](_0x13dffd));}_0x4a69b9['_update'](_0x4c425a,!0x0);}['_createInitialRevision'](_0x39d41d){const _0x2c023a=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x2c023a)this['_initialRevisionId']=_0x2c023a['id'];else{const _0x457d3d=!this['editor']['model']['document']['roots']['find'](_0x5978ba=>this['editor']['model']['hasContent'](_0x5978ba)),_0x2219df=this['editor']['plugins']['get']('Users')['me']['id'],_0x13ab33=m(this['editor']['locale'],_0x457d3d?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x39d41d,'to':_0x39d41d,'id':this['_initialRevisionId'],'name':_0x13ab33,'creatorId':_0x2219df});}}['_createCurrentRevision'](_0xf7a389){const _0x2f4552=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x2f4552),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0xf7a389,'to':_0xf7a389,'id':_0x2f4552,'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'](_0x440967,_0x13c4ea){let _0x4775ce=this['editor']['config']['get']('initialData'),_0x4e2e2e=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x4775ce){_0x4775ce={};for(const _0x43a602 of this['editor']['model']['document']['getRootNames']())_0x4775ce[_0x43a602]='';}if('string'==typeof _0x4775ce&&(_0x4775ce={'main':_0x4775ce}),void 0x0===_0x4e2e2e){_0x4e2e2e={};for(const _0xfdee42 of this['editor']['model']['document']['getRootNames']())_0x4e2e2e[_0xfdee42]={};}let _0x3d52a7=!0x1;const _0x244bdf=Object['keys'](_0x4775ce),_0x3b2037=Object['keys'](_0x440967);for(const _0x4c3409 of _0x244bdf){if(_0x4775ce[_0x4c3409]!==_0x440967[_0x4c3409]&&''!==_0x4775ce[_0x4c3409]['trim']()){_0x3d52a7=!0x0;break;}if(!_0x249b5b(_0x4e2e2e[_0x4c3409],_0x13c4ea[_0x4c3409])&&Object['keys'](_0x4e2e2e[_0x4c3409])['length']>0x0){_0x3d52a7=!0x0;break;}}_0x3d52a7||(_0x3d52a7=_0x3b2037['some'](_0x202c15=>!this['editor']['model']['document']['getRoot'](_0x202c15))),_0x3d52a7&&_0x5cd68a('editor-initial-data-replaced-with-revision-data',{'editorData':_0x4775ce,'editorRootsAttributes':_0x4e2e2e,'revisionData':_0x440967,'revisionRootsAttributes':_0x13c4ea}),this['editor']['config']['set']('initialData',_0x440967),this['editor']['config']['set']('rootsAttributes',_0x13c4ea);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x5e052e=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x5e052e['add'](m(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x3a7d2b){const _0x3bf9cb=this['repository']['getRevisions']();_0x3bf9cb['reverse']();let _0xf9c464=0x0;for(;_0xf9c464<_0x3bf9cb['length'];){const _0x5cf371=_0x3bf9cb[_0xf9c464];if(_0x5cf371===this['currentRevision']){_0xf9c464++;continue;}if(_0x5cf371['id']===this['_initialRevisionId'])break;const _0x2e37d6=_0x3a7d2b['toVersion']-_0x5cf371['toVersion']||_0x3a7d2b['fromVersion']-_0x5cf371['fromVersion'];if(_0x2e37d6>0x0)break;if(_0x2e37d6<0x0)_0xf9c464++;else{if(!_0x3a7d2b['creator']&&_0x5cf371['creator'])break;if(_0x5cf371['creator']||!_0x3a7d2b['creator']){if(_0x3a7d2b['createdAt']>_0x5cf371['createdAt'])break;_0xf9c464++;}else _0xf9c464++;}}return _0xf9c464;}['_getFromVersion'](_0x149283){const _0x19cbca=this['repository']['getRevisions']();_0x19cbca['reverse'](),_0x19cbca['shift']();const _0x39fb24=_0x19cbca['find'](_0x6b76bc=>_0x6b76bc['toVersion']<=_0x149283)['toVersion'];return _0x39fb24<this['_startingVersion']?this['_startingVersion']:_0x39fb24;}['_makeRevision']({name:_0x4d0d91,from:_0x238519,to:_0x1fa8dd,creatorId:_0x2bef74,id:_0x152b8d}){const _0x10f734=this['buildRevisionData']({'from':_0x238519,'to':_0x1fa8dd});_0x10f734['name']=_0x4d0d91,_0x10f734['creatorId']=_0x2bef74,_0x10f734['id']=_0x152b8d;const _0x361580=this['addRevisionData'](_0x10f734);return this['adapter']&&this['_bufferUpdate'](_0x10f734['id'],_0x10f734,!0x0),_0x361580;}['_setConversion'](){this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'});}}class x{['editor'];['source'];['_savedMetaData'];['_lastFrom'];['_lastTo'];['_markers'];['_diffRoots'];['_diffRootsAttributes'];['_baseRoots'];['_baseRootsAttributes'];['_idsRoots'];['_baseIdsRoots'];['_touched'];['_touchedMarkers'];['_touchedRoots'];['_revisionId'];['_startingRevisionId'];constructor(_0x244a12){this['editor']=_0x244a12,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'](_0x1b7824){this['source']=_0x1b7824;const _0x439749=new Map(),_0x3b976f=new Map(),_0x2716ea=this['editor']['model']['document']['roots']['map'](_0x2f6e7d=>_0x2f6e7d['rootName']);for(const _0x49290a of _0x2716ea){const _0x4cec34=this['editor']['model']['document']['getRoot'](_0x49290a),_0xfd5681=K(_0x4cec34);_0x439749['set'](_0x49290a,_0xfd5681),_0x3b976f['set'](_0x49290a,Object['fromEntries'](_0x4cec34['getAttributes']()));}const _0x3526e2=Array['from'](this['editor']['model']['markers'])['map'](_0x6e2b57=>[_0x6e2b57['name'],_0x6e2b57['getRange']()]),_0x4a42f4=this['source']['version'];this['_saveMetaData'](_0x4a42f4,_0x439749,_0x3526e2,_0x3b976f),this['_startingRevisionId']=this['_revisionId'];const _0x54c837=new Map(),_0x517918=new Map();for(const _0x36c158 of _0x2716ea){const _0x31bfeb=N(_0x36c158);_0x54c837['set'](_0x36c158,_0x31bfeb),_0x517918['set'](_0x36c158,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x54c837,[],_0x517918);}['getData'](_0x10e2f4,_0x35cf74){if(this['_lastFrom']===_0x10e2f4&&this['_lastTo']<=_0x35cf74)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x35cf74,!0x0);else{if(!this['_savedMetaData']['has'](_0x10e2f4)){const _0x22bc8a=this['_getPreviousFrom'](_0x10e2f4);this['_calculateMetaData'](_0x22bc8a,_0x10e2f4,!0x1);}this['_calculateMetaData'](_0x10e2f4,_0x35cf74,!0x0);}return this['_lastFrom']=_0x10e2f4,this['_lastTo']=_0x35cf74,this['_getState']();}['loadState'](_0x260bae){if(!this['_savedMetaData']['has'](_0x260bae['fromVersion'])){const _0x483297=this['_getPreviousFrom'](_0x260bae['fromVersion']);this['_calculateMetaData'](_0x483297,_0x260bae['fromVersion'],!0x1);}this['_calculateMetaData'](_0x260bae['fromVersion'],_0x260bae['toVersion'],!0x1);const _0x5c8358=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x260bae['fromVersion'],this['_lastTo']=_0x260bae['toVersion'];for(const _0x31ba34 in _0x260bae['diffData']){const _0x1206fa=_0x260bae['diffData'][_0x31ba34]['attachChange'],_0x578f7a=_0x14aaba(_0x260bae['diffData'][_0x31ba34]['attributesBefore'])||{},_0x5298a7=_0x5c8358['_makeModelFromViewString'](_0x260bae['diffData'][_0x31ba34]['deletions']);_0x5298a7['rootName']=_0x31ba34,_0x5298a7['_isAttached']=!_0x1206fa||!_0x1206fa['isAttached'],_0x5298a7['isAttached']=()=>_0x5298a7['_isAttached'],this['_baseRoots']['set'](_0x31ba34,_0x5298a7),this['_baseRootsAttributes']['set'](_0x31ba34,_0x578f7a),_0x1206fa&&this['_touchedRoots']['set'](_0x31ba34,_0x1206fa);const _0x4d7f1a=this['_makeIdsRoot'](_0x5298a7);this['_baseIdsRoots']['set'](_0x31ba34,_0x4d7f1a);for(const [_0x4392db,_0x2f0ee2]of _0x5298a7['markers']){if(!_0x4392db['startsWith']('revision:'))continue;const _0x472d59=_0x4392db['split'](':')[0x2];for(const _0x5c7e0e of _0x2f0ee2['getWalker']({'singleCharacters':!0x0})){const _0x158355=this['_getVidAttributeName'](_0x5c7e0e),_0x3c5883='elementEnd'==_0x5c7e0e['type']?_0x5c7e0e['previousPosition']['path']['slice'](0x0,-0x1):_0x5c7e0e['previousPosition']['path'],_0x39f4ab=_0x4d7f1a['getNodeByPath'](_0x3c5883)['getAttribute'](_0x158355);this['_touched']['set'](_0x39f4ab,{'userId':_0x472d59});}_0x5298a7['markers']['delete'](_0x4392db);}}this['_startingRevisionId']=this['_revisionId'];const _0x57f04d=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x2370be=>!this['_touched']['has'](_0x2370be));let _0x18f016=0x0;const _0xdde882=new Map();for(const _0x4a5f1f in _0x260bae['diffData']){const _0x22db7f=_0x260bae['diffData'][_0x4a5f1f]['attachChange'],_0x1cd0c4=_0x14aaba(_0x260bae['diffData'][_0x4a5f1f]['attributesAfter'])||{},_0x5acc07=_0x5c8358['_makeModelFromViewString'](_0x260bae['diffData'][_0x4a5f1f]['insertions']);_0x5acc07['rootName']=_0x4a5f1f,_0x5acc07['_isAttached']=!_0x22db7f||_0x22db7f['isAttached'],_0x5acc07['isAttached']=()=>_0x5acc07['_isAttached'],this['_diffRoots']['set'](_0x4a5f1f,_0x5acc07),this['_diffRootsAttributes']['set'](_0x4a5f1f,_0x1cd0c4);const _0x394bb8=this['_makeIdsRoot'](_0x5acc07,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x4a5f1f,_0x394bb8),_0xdde882['set'](_0x4a5f1f,_0x5acc07['isAttached']()?_0x1cd0c4:{});for(const [_0x1612b3,_0x34fff1]of _0x5acc07['markers']){if(!_0x1612b3['startsWith']('revision:'))continue;const _0x8d3cb2=_0x1612b3['split'](':')[0x2];for(const _0x1daadc of _0x34fff1['getWalker']({'singleCharacters':!0x0})){const _0x220581=this['_getVidAttributeName'](_0x1daadc),_0x559a49=this['_revisionId']++,_0x5b58bd='elementEnd'==_0x1daadc['type']?_0x1daadc['previousPosition']['path']['slice'](0x0,-0x1):_0x1daadc['previousPosition']['path'];_0x394bb8['getNodeByPath'](_0x5b58bd)['_setAttribute'](_0x220581,_0x559a49),this['_touched']['set'](_0x559a49,{'userId':_0x8d3cb2});}_0x5acc07['markers']['delete'](_0x1612b3);}for(const _0x2b0ea4 of this['editor']['model']['createRangeIn'](_0x5acc07)['getWalker']({'singleCharacters':!0x0})){const _0x2cfbc1=this['_getVidAttributeName'](_0x2b0ea4),_0x50e62f='elementEnd'==_0x2b0ea4['type']?_0x2b0ea4['previousPosition']['path']['slice'](0x0,-0x1):_0x2b0ea4['previousPosition']['path'],_0x5749d5=_0x394bb8['getNodeByPath'](_0x50e62f);_0x5749d5['getAttribute'](_0x2cfbc1)>0x0||_0x5749d5['_setAttribute'](_0x2cfbc1,_0x57f04d[_0x18f016++]);}for(const [_0x2edab6,_0x143a98]of _0x5acc07['markers'])_0x2edab6['startsWith']('revision:')||this['_markers']['set'](_0x2edab6,_0x143a98);}const {roots:_0x457acc}=this['_savedMetaData']['get'](_0x260bae['fromVersion']),{roots:_0x4407a8}=this['_savedMetaData']['get'](_0x260bae['toVersion']),_0x214fd1=K(_0x457acc['get']('$graveyard'));this['_baseRoots']['set']('$graveyard',_0x214fd1),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x214fd1,Number['NEGATIVE_INFINITY']));const _0x21722c=K(_0x4407a8['get']('$graveyard'));this['_diffRoots']['set']('$graveyard',_0x21722c),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x21722c));const _0x1c3779=Array['from'](this['_diffRoots'])['map'](([_0x456d36,_0x4b1e67])=>[_0x456d36,K(_0x4b1e67)]);this['_saveMetaData'](this['_lastTo'],_0x1c3779,this['_markers'],_0xdde882);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0x4cddff,_0x247c2a,_0x4eb721,_0x1a9b11){const _0x1eca39=new Map(_0x247c2a),_0x5de596=new Map(_0x14aaba(_0x1a9b11)),_0x3a3e34=new Map();for(const [_0x5d262a,_0x25dcc1]of _0x4eb721)_0x3a3e34['set'](_0x5d262a,{'start':_0x25dcc1['start']['clone'](),'end':_0x25dcc1['end']['clone'](),'rootName':_0x25dcc1['root']['rootName']});this['_savedMetaData']['set'](_0x4cddff,{'roots':_0x1eca39,'markers':_0x3a3e34,'rootsAttributes':_0x5de596});}['_removeMetaData'](_0x3eb264){this['_savedMetaData']['delete'](_0x3eb264);}['_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'](_0x18317b,_0x5a2558=null){let _0x4d6756=null;_0x18317b['is']('documentFragment')||(_0x4d6756=new _0x3ade8a(_0x18317b['name'],{'vid_start':null===_0x5a2558?this['_revisionId']++:_0x5a2558++}));const _0x5ecc88=[];for(const _0x307739 of _0x18317b['getChildren']())if(_0x307739['is']('element')){_0x5ecc88['push'](this['_makeIdsRoot'](_0x307739,_0x5a2558));const _0x4de29c=_0x5ecc88[_0x5ecc88['length']-0x1];null!==_0x5a2558&&(_0x5a2558=_0x4de29c['is']('element','$text')?_0x4de29c['getAttribute']('vid')+0x1:_0x4de29c['getAttribute']('vid_end')+0x1);}else{for(let _0x3142ed=0x0;_0x3142ed<_0x307739['offsetSize'];_0x3142ed++)_0x5ecc88['push'](new _0x3ade8a('$text',{'vid':null===_0x5a2558?this['_revisionId']++:_0x5a2558++}));}if(_0x18317b['is']('documentFragment')){const _0x146c37=N(_0x18317b['rootName']);return _0x146c37['_insertChild'](0x0,_0x5ecc88),_0x146c37;}return _0x4d6756['_setAttribute']('vid_end',null===_0x5a2558?this['_revisionId']++:_0x5a2558++),_0x4d6756['_insertChild'](0x0,_0x5ecc88),_0x4d6756;}['_calculateMetaData'](_0x3ca302,_0x329656,_0xd7be36){this['_reset']();const {roots:_0x1fd9fc,markers:_0x405513,rootsAttributes:_0x250574}=this['_savedMetaData']['get'](_0x3ca302);this['_baseRoots']=new Map(_0x1fd9fc),this['_baseRootsAttributes']=new Map(_0x14aaba(_0x250574));for(const [_0x4c5e94,_0x42cddf]of this['_baseRoots'])if('$graveyard'!==_0x4c5e94&&(this['_diffRoots']['set'](_0x4c5e94,K(_0x42cddf)),this['_diffRootsAttributes']=new Map(_0x14aaba(_0x250574)),_0xd7be36)){const _0x1cb58e=this['_revisionId'];this['_idsRoots']['set'](_0x4c5e94,this['_makeIdsRoot'](_0x42cddf)),this['_baseIdsRoots']['set'](_0x4c5e94,this['_makeIdsRoot'](_0x42cddf,_0x1cb58e));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',K(this['_baseRoots']['get']('$graveyard'))),_0xd7be36&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x1331d6,_0x128364]of _0x405513){const _0x52bbfe=this['_baseRoots']['get'](_0x128364['rootName']),_0x74f059=this['_diffRoots']['get'](_0x128364['rootName']),_0x4689e5=new _0x145ffd(this['_fixPosition'](_0x128364['start'],_0x52bbfe),this['_fixPosition'](_0x128364['end'],_0x52bbfe)),_0x1d1501=this['_fixRange'](_0x4689e5,_0x74f059);_0x52bbfe['markers']['set'](_0x1331d6,_0x4689e5),this['_markers']['set'](_0x1331d6,_0x1d1501);}this['_applyOperations'](_0x3ca302,_0x329656,_0xd7be36);}['_applyOperations'](_0x465ac3,_0x10489b,_0xfd6924){for(const _0x112703 of this['source']['getOperations'](_0x465ac3,_0x10489b))this['_handleOperation'](_0x112703,_0xfd6924);for(const _0x13c316 of this['_diffRoots']['values']())_0x13c316['markers']['clear']();for(const [_0x104eca,_0x72ba9b]of this['_markers']){this['_diffRoots']['get'](_0x72ba9b['root']['rootName'])['markers']['set'](_0x104eca,_0x72ba9b['clone']());}const _0x2b9404=new Map(),_0xad9ec1=new Map();for(const [_0x4d2c6a,_0x308e06]of this['_diffRoots'])_0x2b9404['set'](_0x4d2c6a,K(_0x308e06)),_0xad9ec1['set'](_0x4d2c6a,this['_diffRootsAttributes']['get'](_0x4d2c6a));this['_saveMetaData'](_0x10489b,_0x2b9404,this['_markers'],_0xad9ec1);}['_getPreviousFrom'](_0x44d195){const _0x5d074a=Array['from'](this['_savedMetaData']['keys']());_0x5d074a['sort']((_0x25be90,_0x530be8)=>_0x25be90-_0x530be8),_0x5d074a['reverse']();for(const _0x4014f1 of _0x5d074a)if(_0x4014f1<_0x44d195)return _0x4014f1;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x1f1578,_0xec5b9e){const _0x32b282=Array['from'](_0xec5b9e['markers'])['map'](([_0x16a6d8,_0x78b239])=>[_0x16a6d8,this['_fixRange'](_0x78b239,_0x1f1578)]);_0x1f1578['markers']=new Map(_0x32b282);}['_transformMarkers'](_0x2bc6c3){for(const _0x2c0325 of this['_markers']['values']()){const _0x2a34c7=_0x2c0325['getTransformedByOperation'](_0x2bc6c3),_0x5b9f79=_0x145ffd['_createFromRanges'](_0x2a34c7);_0x2c0325['start']=_0x5b9f79['start'],_0x2c0325['end']=_0x5b9f79['end'];}}['_handleOperation'](_0x290712,_0x3bdfbf){if('addRoot'!=_0x290712['type']&&'detachRoot'!=_0x290712['type']){if('insert'==_0x290712['type']){const _0x3a0c2e=_0x290712['position']['root']['rootName'];this['_diffRoots']['has'](_0x3a0c2e)||(this['_diffRoots']['set'](_0x3a0c2e,N(_0x3a0c2e,!0x0)),this['_diffRootsAttributes']['set'](_0x3a0c2e,{}),_0x3bdfbf&&this['_idsRoots']['set'](_0x3a0c2e,N(_0x3a0c2e,!0x0)));}else{if('addRootAttribute'==_0x290712['type']||'removeRootAttribute'==_0x290712['type']||'changeRootAttribute'==_0x290712['type'])return void this['_handleRootAttributeOperation'](_0x290712);'marker'==_0x290712['type']&&this['_handleMarkerOperation'](_0x290712);}if('marker'!==_0x290712['type']){const _0xfd5ee3=this['_cloneOperation'](_0x290712,this['_diffRoots']);_0xfd5ee3['_execute'](),this['_transformMarkers'](_0xfd5ee3);}if(_0x3bdfbf)switch(_0x290712['type']){case'insert':this['_handleInsertOperation'](_0x290712);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x290712);break;case'merge':this['_handleMergeOperation'](_0x290712);break;case'split':this['_handleSplitOperation'](_0x290712);}}else this['_handleRootOperation'](_0x290712,_0x3bdfbf);}['_cloneOperation'](_0x2f1dd2,_0xdad5d2){const _0x3cae83=_0x2f1dd2['clone']();return _0x3cae83['_authorId']=_0x2f1dd2['_authorId'],this['_fixOperation'](_0x3cae83,_0xdad5d2),_0x3cae83;}['_getBaseVids'](_0x3bc5dd){return _0x3bc5dd['map'](_0x38fb7e=>{const _0x5f5098=this['_getVidAttributeName'](_0x38fb7e);return Number(_0x38fb7e['item']['getAttribute'](_0x5f5098));});}['_generateTape'](_0x127d45,_0x248022){if(_0x127d45['is']('element','$text'))_0x248022['push']({'item':_0x127d45,'type':'text'});else{_0x127d45['is']('element')&&_0x248022['push']({'item':_0x127d45,'type':'elementStart'});for(const _0x497c0e of _0x127d45['getChildren']())this['_generateTape'](_0x497c0e,_0x248022);_0x127d45['is']('element')&&_0x248022['push']({'item':_0x127d45,'type':'elementEnd'});}return _0x248022;}['_getState'](){const _0x473d90=new Map(this['_touched']),_0x18d35a=new Map(_0x473d90),_0x17fa17=new Map(),_0x2d7e75={'insertions':{},'deletions':{}},_0x1b358f={'insertions':{},'deletions':{}},_0x24d644=new Map(),_0x3cf9e9=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x3cf9e9['delete']('$graveyard');for(const _0x5b9d18 of _0x3cf9e9){const _0x11124a=this['_diffRoots']['get'](_0x5b9d18)||N(_0x5b9d18,!0x1),_0x594456=this['_baseRoots']['get'](_0x5b9d18)||N(_0x5b9d18,!0x1);_0x11124a['isAttached']()||_0x594456['isAttached']()?(_0x2d7e75['insertions'][_0x5b9d18]=K(_0x11124a),_0x2d7e75['deletions'][_0x5b9d18]=K(_0x594456),this['_copyMarkers'](_0x2d7e75['deletions'][_0x5b9d18],_0x594456),this['_copyMarkers'](_0x2d7e75['insertions'][_0x5b9d18],_0x11124a),_0x1b358f['insertions'][_0x5b9d18]=this['_generateTape'](this['_idsRoots']['get'](_0x5b9d18),[]),_0x1b358f['deletions'][_0x5b9d18]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x5b9d18)||N(_0x5b9d18,!0x1),[])):_0x3cf9e9['delete'](_0x5b9d18);}for(const _0x3a6a82 of _0x3cf9e9){const _0x251633=_0x1b358f['insertions'][_0x3a6a82];for(const _0x59df83 of _0x251633){const _0x92d42e=this['_getVidAttributeName'](_0x59df83),_0x54dfe8=_0x59df83['item']['getAttribute'](_0x92d42e);_0x18d35a['delete'](_0x54dfe8),_0x54dfe8>=this['_startingRevisionId']&&_0x17fa17['set'](_0x54dfe8,_0x473d90['get'](_0x54dfe8));}}for(const _0x53908d of _0x3cf9e9){const _0x4c4621=_0x1b358f['insertions'][_0x53908d],_0x2e6650=this['_getBaseVids'](_0x1b358f['deletions'][_0x53908d]);let _0xe8839d=0x0;for(const _0x282637 of _0x4c4621){const _0x306d56=this['_getVidAttributeName'](_0x282637),_0x53c387=_0x282637['item']['getAttribute'](_0x306d56);if(!_0x17fa17['has'](_0x53c387)&&!_0x24d644['has'](_0x53c387)){if(_0x18d35a['has'](_0x53c387))_0xe8839d++;else{if(_0x53c387!=_0x2e6650[_0xe8839d]){const _0x5c38cf=_0x473d90['get'](_0x53c387)||_0x473d90['get'](_0x2e6650[_0xe8839d]);for(;_0x53c387!=_0x2e6650[_0xe8839d];)_0x18d35a['has'](_0x2e6650[_0xe8839d])||(_0x24d644['set'](_0x2e6650[_0xe8839d],_0x5c38cf),_0x473d90['set'](_0x2e6650[_0xe8839d],_0x5c38cf)),_0xe8839d++;}_0xe8839d++;}}}}for(const _0x2a0e87 of _0x3cf9e9){const _0x3b0c4a=_0x1b358f['insertions'][_0x2a0e87];for(const _0x307181 of _0x3b0c4a){const _0xe35a5c=this['_getVidAttributeName'](_0x307181),_0x322af6=_0x307181['item']['getAttribute'](_0xe35a5c);if(_0x24d644['has'](_0x322af6)){const _0x34b73b=_0x24d644['get'](_0x322af6);_0x18d35a['has'](_0x322af6)||_0x18d35a['set'](_0x322af6,{..._0x34b73b}),_0x17fa17['set'](_0x322af6,{..._0x34b73b});}}}for(const _0x449758 of _0x18d35a['keys']())_0x449758>=this['_startingRevisionId']&&_0x18d35a['delete'](_0x449758);const _0x3a3915=new Map();for(const _0x552989 of _0x3cf9e9){let _0x4cf405=_0x1b358f['insertions'][_0x552989];for(const _0x484a15 of _0x4cf405)if(_0x484a15['item']['is']('element','tableCell')){const _0x4feb2f=this['_getVidAttributeName'](_0x484a15),_0x4cafee=_0x484a15['item']['getAttribute'](_0x4feb2f);if(_0x17fa17['has'](_0x4cafee)){const _0x2ea9b8=_0x484a15['item']['parent']['parent']['getAttribute']('vid_start'),_0xf669e4=_0x3a3915['get'](_0x2ea9b8)||new Set();_0xf669e4['add'](_0x17fa17['get'](_0x4cafee)['userId']),_0x3a3915['set'](_0x2ea9b8,_0xf669e4);}}_0x4cf405=_0x1b358f['deletions'][_0x552989];for(const _0x484023 of _0x4cf405)if(_0x484023['item']['is']('element','tableCell')){const _0x25a2a2=this['_getVidAttributeName'](_0x484023),_0x319149=_0x484023['item']['getAttribute'](_0x25a2a2);if(_0x18d35a['has'](_0x319149)){const _0x33979e=_0x484023['item']['parent']['parent']['getAttribute']('vid_start'),_0x15215e=_0x3a3915['get'](_0x33979e)||new Set();_0x15215e['add'](_0x18d35a['get'](_0x319149)['userId']),_0x3a3915['set'](_0x33979e,_0x15215e);}}for(const _0x582e57 of _0x3a3915['keys']())(_0x17fa17['has'](_0x582e57)||_0x18d35a['has'](_0x582e57))&&_0x3a3915['delete'](_0x582e57);}for(const _0x43f9df of _0x3cf9e9){const _0x186af3=_0x1b358f['insertions'][_0x43f9df];let _0x2b1815=null,_0x10d6c9=null;for(const _0x4bfde0 of _0x186af3){const _0x90027b=this['_getVidAttributeName'](_0x4bfde0),_0x35e65f=_0x4bfde0['item']['getAttribute'](_0x90027b),_0xa78852=_0x3a3915['get'](_0x35e65f);_0xa78852&&'elementStart'==_0x4bfde0['type']&&(_0x2b1815=Array['from'](_0xa78852)[0x0],_0x10d6c9=_0x4bfde0['item']['getAttribute']('vid_end')),_0x2b1815&&(_0x18d35a['set'](_0x35e65f,{'userId':_0x2b1815}),_0x17fa17['set'](_0x35e65f,{'userId':_0x2b1815})),_0x35e65f==_0x10d6c9&&(_0x2b1815=null,_0x10d6c9=null);}}const _0x5142b4={},_0x2d9930=new Set();for(const _0x2993bf of _0x3cf9e9){const _0x42a081=_0x2d7e75['deletions'][_0x2993bf],_0x1096aa=_0x2d7e75['insertions'][_0x2993bf];for(const {userId:_0x4a1fda}of this['_touchedMarkers']['values']())null!==_0x4a1fda&&_0x2d9930['add'](_0x4a1fda);for(const {userId:_0x356320}of this['_touchedRoots']['values']())null!==_0x356320&&_0x2d9930['add'](_0x356320);this['_markChanges'](_0x1096aa,_0x1b358f['insertions'][_0x2993bf],_0x17fa17,'insertion',_0x2d9930),this['_markChanges'](_0x42a081,_0x1b358f['deletions'][_0x2993bf],_0x18d35a,'deletion',_0x2d9930),_0x5142b4[_0x2993bf]={'insertions':this['_prepareViewToSave'](_0x1096aa),'deletions':this['_prepareViewToSave'](_0x42a081),'attachChange':this['_touchedRoots']['get'](_0x2993bf)||null,'attributesBefore':_0x14aaba(this['_baseRootsAttributes']['get'](_0x2993bf))||{},'attributesAfter':_0x14aaba(this['_diffRootsAttributes']['get'](_0x2993bf))};}return{'diffData':_0x5142b4,'authorsIds':Array['from'](_0x2d9930)};}['_processRootBeforeSave'](_0x3ed173){for(const [,_0x744822]of _0x3ed173['markers']){const _0x46af41=_0x744822['start']['getAncestors']()['filter'](_0x39b6c4=>'tableCell'==_0x39b6c4['name']);for(const _0x4679b7 of _0x46af41)0x1==_0x4679b7['childCount']&&_0x4679b7['getChild'](0x0)['is']('element','paragraph')&&_0x4679b7['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x2e1c47){this['_processRootBeforeSave'](_0x2e1c47);const _0x1829ca=this['editor']['data']['toView'](_0x2e1c47,{}),_0x3a103e=Array['from'](_0x1829ca['getChildren']())['map'](_0x28184b=>this['_getViewJson'](_0x28184b));return JSON['stringify'](_0x3a103e);}['_getViewJson'](_0x5174cb){if(_0x5174cb['is']('$text'))return _0x5174cb['data'];{const _0x470174=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0x197809=_0x5174cb,_0x139e6c=this['editor']['data']['htmlProcessor']['domConverter'],_0x2c9ea1={'type':_0x470174['_getTypeCharForViewElement'](_0x197809),'name':_0x197809['name'],'attributes':Array['from'](_0x197809['getAttributes']()),'children':Array['from'](_0x197809['getChildren']())['map'](_0x1784fc=>this['_getViewJson'](_0x1784fc))};if(_0x5174cb['is']('uiElement')&&'$comment'!=_0x5174cb['name']){const _0x58240a=_0x5174cb['render'](_0x139e6c['domDocument'],_0x139e6c);_0x2c9ea1['children']['push'](_0x58240a['outerHTML']);}else{if(_0x5174cb['is']('rawElement')){const _0x3f2e98=_0x139e6c['domDocument']['createElement'](_0x197809['name']);_0x5174cb['render'](_0x3f2e98,_0x139e6c),_0x2c9ea1['children']['push'](_0x3f2e98['innerHTML']);}}const _0x3c02d0=Array['from'](_0x197809['getCustomProperties']());_0x3c02d0['length']>0x0&&(_0x2c9ea1['customProperties']=_0x3c02d0);const _0x37bc95=_0x197809['getFillerOffset']();return null!==_0x37bc95&&(_0x2c9ea1['fillerOffset']=_0x37bc95),_0x2c9ea1;}}['_markChanges'](_0x360291,_0x3e3a0f,_0x5476b1,_0x6bcdfa,_0xea24d1){let _0x65f291=null,_0x167409=null,_0x48c1d6=0x0;const _0x4fc9d9=this['editor']['model'];for(let _0x327687=0x0;_0x327687<_0x3e3a0f['length'];_0x327687++){const _0x427a2f=this['_getVidAttributeName'](_0x3e3a0f[_0x327687]),_0x309ffc=_0x3e3a0f[_0x327687]['item']['getAttribute'](_0x427a2f),_0x1caf8b=_0x5476b1['get'](_0x309ffc),_0x3e6754=_0x327687==_0x3e3a0f['length']-0x1;(!_0x65f291&&_0x1caf8b&&(_0x65f291=_0x1caf8b,_0x167409=_0x3e3a0f[_0x327687]),_0x65f291&&(!_0x1caf8b||_0x1caf8b['userId']!=_0x65f291['userId']))&&(_0x2434c9(_0x1caf8b,P(_0x167409,_0x360291,_0x4fc9d9),P(_0x3e3a0f[_0x327687],_0x360291,_0x4fc9d9)),_0x65f291=_0x1caf8b||null,_0x167409=_0x1caf8b?_0x3e3a0f[_0x327687]:null),_0x65f291&&_0x3e6754&&_0x2434c9(_0x1caf8b,P(_0x167409,_0x360291,_0x4fc9d9),V(_0x3e3a0f[_0x327687],_0x360291,_0x4fc9d9));}function _0x2434c9(_0x481da6,_0x3c1214,_0x22bbba){const _0x35bbfd=_0x65f291['userId'],_0x4e982b='revision:'+_0x6bcdfa+':'+_0x35bbfd+':'+_0x48c1d6++,_0x3c98d7=_0x4fc9d9['createRange'](_0x3c1214,_0x22bbba);_0x360291['markers']['set'](_0x4e982b,_0x3c98d7),null!==_0x35bbfd&&_0xea24d1['add'](_0x35bbfd);}}['_getVidAttributeName'](_0x33c816){switch(_0x33c816['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x38b9b9,_0x5e84b8){_0x38b9b9['baseVersion']=null;for(const _0x40831b in _0x38b9b9){const _0x456192=_0x38b9b9[_0x40831b];if(_0x456192 instanceof _0x116ae8){const _0x2d2102=_0x5e84b8['get'](_0x456192['root']['rootName']);_0x38b9b9[_0x40831b]=this['_fixPosition'](_0x456192,_0x2d2102);}if(_0x456192 instanceof _0x145ffd){const _0x4a975d=_0x5e84b8['get'](_0x456192['root']['rootName']);_0x38b9b9[_0x40831b]=this['_fixRange'](_0x456192,_0x4a975d);}'root'===_0x40831b&&(_0x38b9b9['root']=_0x5e84b8['get'](_0x38b9b9['root']['rootName']));}}['_fixRange'](_0x1877b9,_0x4aecbb){return this['editor']['model']['createRange'](this['_fixPosition'](_0x1877b9['start'],_0x4aecbb),this['_fixPosition'](_0x1877b9['end'],_0x4aecbb));}['_fixPosition'](_0x2545a0,_0x5040cd){return this['editor']['model']['createPositionFromPath'](_0x5040cd,_0x2545a0['path'],_0x2545a0['stickiness']);}['_handleInsertOperation'](_0x55dc32){const _0x2c033d=this['_idsRoots']['get'](_0x55dc32['position']['root']['rootName']),_0x50ba9d=this['_fixPosition'](_0x55dc32['position'],_0x2c033d),_0x93dc6e=null===_0x55dc32['_authorId']?null:_0x55dc32['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x5e48c0=_0x50ba9d['parent'],_0x4d6c63=this['_revisionId'],_0x37559c=[];for(const _0x3bf9a6 of _0x55dc32['nodes'])if(_0x3bf9a6['is']('element'))_0x37559c['push'](this['_makeIdsRoot'](_0x3bf9a6));else{for(let _0x10dc83=0x0;_0x10dc83<_0x3bf9a6['offsetSize'];_0x10dc83++)_0x37559c['push'](new _0x3ade8a('$text',{'vid':this['_revisionId']++}));}const _0x4e8a94=this['_revisionId'];for(let _0x4500a0=_0x4d6c63;_0x4500a0<_0x4e8a94;_0x4500a0++)this['_touched']['set'](_0x4500a0,{'userId':_0x93dc6e});_0x5e48c0['_insertChild'](_0x50ba9d['offset'],_0x37559c);}['_handleMoveOperation'](_0x1613db){(_0x1613db=this['_cloneOperation'](_0x1613db,this['_idsRoots']))['_execute']();const _0x3f0210=null===_0x1613db['_authorId']?null:_0x1613db['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x166b72=_0x1613db['getMovedRangeStart'](),_0x4c047f=_0x166b72['parent'],_0x26e263=_0x166b72['offset'];!function _0x1c2858(_0x1d20d0,_0x37650e,_0x2bf1e4,_0x4a52c5){for(let _0x2a9a8f=_0x2bf1e4;_0x2a9a8f<_0x4a52c5;_0x2a9a8f++){const _0x265be9=_0x37650e['getChild'](_0x2a9a8f);_0x265be9['is']('element','$text')?_0x1d20d0['set'](_0x265be9['getAttribute']('vid'),{'userId':_0x3f0210}):(_0x1d20d0['set'](_0x265be9['getAttribute']('vid_start'),{'userId':_0x3f0210}),_0x1c2858(_0x1d20d0,_0x265be9,0x0,_0x265be9['childCount']),_0x1d20d0['set'](_0x265be9['getAttribute']('vid_end'),{'userId':_0x3f0210}));}}(this['_touched'],_0x4c047f,_0x26e263,_0x26e263+_0x1613db['howMany']);}['_handleMergeOperation'](_0x58ca41){const _0x37c7cb=null===(_0x58ca41=this['_cloneOperation'](_0x58ca41,this['_idsRoots']))['_authorId']?null:_0x58ca41['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x3928ba=_0x58ca41['targetPosition']['parent'],_0x5c2640=_0x58ca41['sourcePosition']['parent'],_0x1d7ea1=_0x3928ba['getAttribute']('vid_end'),_0x77688a=_0x5c2640['getAttribute']('vid_start');_0x3928ba['_setAttribute']('vid_end',_0x5c2640['getAttribute']('vid_end')),_0x5c2640['_setAttribute']('vid_end',_0x1d7ea1),this['_touched']['set'](_0x77688a,{'userId':_0x37c7cb}),this['_touched']['set'](_0x1d7ea1,{'userId':_0x37c7cb}),_0x58ca41['_execute']();}['_handleSplitOperation'](_0x5a51a3){const _0x398d91=null===(_0x5a51a3=this['_cloneOperation'](_0x5a51a3,this['_idsRoots']))['_authorId']?null:_0x5a51a3['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x5d2cfd=_0x5a51a3['graveyardPosition'],_0x386aae=_0x5a51a3['splitPosition']['parent'];_0x5a51a3['_execute']();const _0x118e21=_0x386aae['getAttribute']('vid_end'),_0xc05477=_0x5a51a3['insertionPosition']['nodeAfter'];if(_0x5d2cfd){const _0x5e41be=_0xc05477['getAttribute']('vid_end'),_0x37d90a=_0x386aae['getAttribute']('vid_end');_0x386aae['_setAttribute']('vid_end',_0x5e41be),_0xc05477['_setAttribute']('vid_end',_0x37d90a),this['_touched']['set'](_0x386aae['getAttribute']('vid_end'),{'userId':_0x398d91}),this['_touched']['set'](_0xc05477['getAttribute']('vid_start'),{'userId':_0x398d91});}else{const _0x2cded9=this['_revisionId']++,_0x397075=this['_revisionId']++;_0x386aae['_setAttribute']('vid_end',_0x2cded9),_0xc05477['_setAttribute']('vid_start',_0x397075),_0xc05477['_setAttribute']('vid_end',_0x118e21),this['_touched']['set'](_0x2cded9,{'userId':_0x398d91}),this['_touched']['set'](_0x397075,{'userId':_0x398d91});}}['_handleMarkerOperation'](_0x35416a){if(!_0x35416a['affectsData'])return;const _0x4a7441=(_0x35416a=this['_cloneOperation'](_0x35416a,this['_diffRoots']))['oldRange']?_0x35416a['oldRange']['root']:null,_0x12b511=_0x35416a['newRange']?_0x35416a['newRange']['root']:null;_0x4a7441&&this['_markers']['delete'](_0x35416a['name']),_0x12b511&&this['_markers']['set'](_0x35416a['name'],_0x35416a['newRange']['clone']());const _0x2cd9b2=null===_0x35416a['_authorId']?null:_0x35416a['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x1d9158=_0x35416a['name'];if(!this['_touchedMarkers']['has'](_0x1d9158))return void this['_touchedMarkers']['set'](_0x1d9158,{'range':_0x35416a['oldRange'],'userId':_0x2cd9b2});const _0x19eaec=this['_touchedMarkers']['get'](_0x1d9158),_0x10b47b=_0x19eaec['range'],_0x3fae26=_0x35416a['newRange'];null==_0x10b47b&&null==_0x3fae26||_0x10b47b&&_0x3fae26&&_0x10b47b['isEqual'](_0x3fae26)?this['_touchedMarkers']['delete'](_0x35416a['name']):_0x19eaec['userId']=_0x2cd9b2;}['_handleRootOperation'](_0x42e47b,_0x23166a){this['_diffRoots']['has'](_0x42e47b['rootName'])?this['_diffRoots']['get'](_0x42e47b['rootName'])['_isAttached']=_0x42e47b['isAdd']:(this['_diffRoots']['set'](_0x42e47b['rootName'],N(_0x42e47b['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x42e47b['rootName'],{}),_0x23166a&&this['_idsRoots']['set'](_0x42e47b['rootName'],N(_0x42e47b['rootName'],!0x0)));const _0x4549be=null===_0x42e47b['_authorId']?null:_0x42e47b['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x501e6c=this['_touchedRoots']['get'](_0x42e47b['rootName']);_0x501e6c&&_0x501e6c['userId']===_0x4549be?this['_touchedRoots']['delete'](_0x42e47b['rootName']):this['_touchedRoots']['set'](_0x42e47b['rootName'],{'userId':_0x4549be,'isAttached':_0x42e47b['isAdd']});}['_handleRootAttributeOperation'](_0x51fcbf){const _0x5df28c=this['_diffRootsAttributes']['get'](_0x51fcbf['root']['rootName']);null===_0x51fcbf['newValue']?delete _0x5df28c[_0x51fcbf['key']]:_0x5df28c[_0x51fcbf['key']]=_0x51fcbf['newValue'];}}function K(_0x2fe79a){const _0x11d0f2=N(_0x2fe79a['rootName'],_0x2fe79a['isAttached']());for(const _0x1ea253 of _0x2fe79a['getChildren']()){const _0x36ac70=_0x1ea253['_clone'](!0x0);_0x11d0f2['_appendChild'](_0x36ac70);}return _0x11d0f2;}function N(_0x3fbd49,_0x3cf2ff=!0x0){const _0x250ded=new _0x597820();return _0x250ded['rootName']=_0x3fbd49,_0x250ded['_isAttached']=_0x3cf2ff,_0x250ded['isAttached']=()=>_0x250ded['_isAttached'],_0x250ded;}function P(_0x27af22,_0x333a95,_0x3af441){const _0x308847='elementEnd'==_0x27af22['type']?_0x3af441['createPositionAt'](_0x27af22['item'],'end'):_0x3af441['createPositionBefore'](_0x27af22['item']);return _0x3af441['createPositionFromPath'](_0x333a95,_0x308847['path'],_0x308847['stickiness']);}function V(_0x8071be,_0x14554b,_0xb3a3bc){const _0x45329c='elementStart'==_0x8071be['type']?_0xb3a3bc['createPositionAt'](_0x8071be['item'],0x0):_0xb3a3bc['createPositionAfter'](_0x8071be['item']);return _0xb3a3bc['createPositionFromPath'](_0x14554b,_0x45329c['path'],_0x45329c['stickiness']);}class he extends/* #__PURE__ -- @preserve */
25
+ _0x2b1f83(_0x526abe){['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x213823,_0x2101c6){super(_0x213823),this['focusTracker']=new _0x338607(),this['keystrokes']=new _0x532e86(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x2101c6),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'](),_0x23680f({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x2b03bd=_0x3e5646=>_0x3e5646['stopPropagation']();this['keystrokes']['set']('arrowright',_0x2b03bd),this['keystrokes']['set']('arrowleft',_0x2b03bd),this['keystrokes']['set']('arrowup',_0x2b03bd),this['keystrokes']['set']('arrowdown',_0x2b03bd);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x5dda88){this['revisionNameInputView']['fieldView']['element']['value']=_0x5dda88['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x15ea90){const _0x121966=new et(this['locale'],ti),_0x551824=_0x121966['fieldView'];_0x551824['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x4af0f7=m(this['locale'],'Name\x20of\x20the\x20revision');return!_0x15ea90&&(_0x4af0f7+='\x20('+m(this['locale'],'optional')+')'),(_0x121966['label']=_0x4af0f7,_0x551824['on']('input',()=>{this['revisionNameInputValue']=_0x551824['element']['value']['trim']();}),_0x121966);}}class l extends _0x1b7918{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h];}['_saveRevisionFormView'];['init'](){const _0x5d3afd=this['editor'],_0x26b71f=_0x5d3afd['plugins']['get']('RevisionTracker');_0x5d3afd['ui']['componentFactory']['add']('revisionHistory',_0x136407=>{const _0x17fd11=_0x103105(_0x136407),_0x4e6659=_0x17fd11['panelView']['children'],_0x427478=new _0x3526a8(_0x136407),_0x493cf2=new _0x36648d(_0x136407),_0xc156f3=this['_createSaveRevisionButton'](_0x3ff6ba),_0x52ff86=new _0x36648d(_0x136407),_0x439b44=this['_createOpenRevisionButton'](_0x3ff6ba);return _0x17fd11['bind']('isEnabled')['to'](_0x26b71f,'isReady',_0x26b71f,'isEnabled',_0x5d3afd,'isReadOnly',(_0x4d583c,_0x4609ad,_0x4d2800)=>_0x4d583c&&_0x4609ad&&!_0x4d2800),_0x17fd11['buttonView']['set']({'icon':_0x2ce2b3,'label':m(_0x136407,'Revision\x20history'),'tooltip':!0x0}),_0xc156f3['set']({'withText':!0x0,'role':'menuitem'}),_0x439b44['set']({'withText':!0x0,'role':'menuitem'}),this['listenTo'](_0x439b44,'execute',()=>{_0x17fd11['isOpen']=!0x1,_0x5d3afd['editing']['view']['focus']();},{'priority':'low'}),_0x493cf2['children']['add'](_0xc156f3),_0x52ff86['children']['add'](_0x439b44),_0x427478['role']='menu',_0x427478['items']['addMany']([_0x493cf2,_0x52ff86]),_0x4e6659['add'](_0x427478),_0x17fd11;}),_0x5d3afd['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x1bb111=this['editor'],_0x27bb32=_0x1bb111['locale'],_0x5ebd6c=_0x1bb111['plugins']['get']('RevisionTracker'),_0x291e50=new _0x279b98(_0x27bb32),_0x386ae8=new _0x2b22ab(_0x27bb32);_0x291e50['bind']('isEnabled')['to'](_0x5ebd6c,'isReady',_0x5ebd6c,'isEnabled',_0x1bb111,'isReadOnly',(_0x50e5b3,_0x230ade,_0x18378a)=>_0x50e5b3&&_0x230ade&&!_0x18378a),_0x291e50['buttonView']['set']({'icon':_0x2ce2b3,'label':m(_0x27bb32,'Revision\x20history')});const _0x944f62=new _0x9bf8f3(_0x27bb32,_0x291e50),_0x4fc377=this['_createSaveRevisionButton'](_0x2a94f6);_0x4fc377['delegate']('execute')['to'](_0x291e50),_0x944f62['children']['add'](_0x4fc377),_0x386ae8['items']['add'](_0x944f62);const _0xbb2c48=new _0x9bf8f3(_0x27bb32,_0x291e50),_0x26c6a4=this['_createOpenRevisionButton'](_0x2a94f6);return _0x26c6a4['delegate']('execute')['to'](_0x291e50),_0xbb2c48['children']['add'](_0x26c6a4),_0x386ae8['items']['add'](_0xbb2c48),_0x291e50['panelView']['children']['add'](_0x386ae8),_0x291e50;}['_createSaveRevisionButton'](_0x41f2e7){const _0x5158be=this['editor'],_0x3a028a=_0x5158be['plugins']['get']('RevisionTracker'),_0x4b75b7=new _0x41f2e7(_0x5158be['locale']);return _0x4b75b7['set']({'label':m(_0x5158be['locale'],'Save\x20current\x20revision')}),_0x4b75b7['bind']('isEnabled')['to'](_0x3a028a,'isReady',_0x3a028a,'isEnabled',_0x5158be,'isReadOnly',(_0x321c4b,_0x50cd13,_0x349910)=>_0x321c4b&&_0x50cd13&&!_0x349910),this['listenTo'](_0x4b75b7,'execute',()=>{this['_showDialog']();}),_0x4b75b7;}['_createOpenRevisionButton'](_0xaa2da){const _0x596f85=this['editor'],_0x56c041=_0x596f85['plugins']['get']('RevisionTracker'),_0x262b2b=new _0xaa2da(_0x596f85['locale']);return _0x262b2b['set']({'label':m(_0x596f85['locale'],'Open\x20revision\x20history')}),_0x262b2b['bind']('isEnabled')['to'](_0x56c041,'isReady',_0x596f85,'isReadOnly',(_0x26388d,_0x414741)=>_0x26388d&&!_0x414741),this['listenTo'](_0x262b2b,'execute',()=>{_0x596f85['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x262b2b;}['_showDialog'](){const _0x255d0d=this['editor'],_0x174db5=_0x255d0d['locale'],_0x569e84=_0x255d0d['plugins']['get']('Dialog'),_0x169e36=_0x255d0d['plugins']['get']('RevisionTracker');function _0x3e379c(_0x582aba){_0x255d0d['config']['get']('revisionHistory.requireRevisionName')&&''===_0x582aba['revisionName']?_0x582aba['revisionNameInputView']['errorText']=m(_0x174db5,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x255d0d['plugins']['get'](h)['saveRevision']({'name':_0x582aba['revisionName']}),_0x569e84['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x3e379c(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x569e84['show']({'id':'revisionSave','title':m(_0x174db5,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':m(_0x255d0d['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x569e84['hide']()},{'label':m(_0x255d0d['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x3e73ca){_0x3e73ca['bind']('isEnabled')['to'](_0x169e36,'isReady',_0x169e36,'isEnabled',_0x255d0d,'isReadOnly',(_0x3d4d67,_0x3814da,_0x96da03)=>_0x3d4d67&&_0x3814da&&!_0x96da03);},'onExecute':()=>_0x3e379c(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x57318c=this['editor'],_0x3919bf=_0x57318c['locale'];this['_saveRevisionFormView']=new he(_0x3919bf,_0x57318c['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class z extends _0x526abe{['changeId'];['_model'];constructor(_0x28960d,_0x307873){super(_0x28960d),this['_model']=_0x307873,this['changeId']=_0x307873['id'];const _0x42bef4=this['bindTemplate'],_0x3ca238=m(_0x28960d,_0x307873['data']['isSuggestion']?'Suggested\x20by':'add'==_0x307873['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x307873['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x42bef4['to']('type',_0x42aba4=>'ck-revision-change__'+_0x42aba4)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x3ca238}]},{'text':'\x20'+_0x307873['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class G extends/* #__PURE__ -- @preserve */
26
+ _0x182a87(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x14874c){super(),this['id']=_0x14874c['id']||_0x49424b(),this['author']=_0x14874c['author'],this['type']=_0x14874c['type'],this['data']=_0x14874c['data']||{},this['rootName']=_0x14874c['rootName'],this['set']('createdAt',_0x14874c['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(_0x988a56,_0x4f6c49){this['newRevisionId']=_0x988a56,this['oldRevisionId']=_0x4f6c49,this['changes']=new _0x145165();}['_setChanges'](_0x3a3a07){for(const _0x277927 of _0x3a3a07)this['changes']['add'](_0x277927);}}class u extends _0x1b7918{['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[_0x510ab1,_0x3f9961,S,$];}constructor(_0x2b09ae){super(_0x2b09ae),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',(_0xdebecc,_0xd72d19,_0x16b3e2)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x3bc6e5=>{for(const _0x4ff91d of this['editor']['editing']['view']['document']['roots'])_0x16b3e2?_0x3bc6e5['removeClass']('ck-editor__editable__overlay',_0x4ff91d):_0x3bc6e5['addClass']('ck-editor__editable__overlay',_0x4ff91d);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x3716aa=>null!==_0x3716aa),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x41e7b2,_0x500485,_0x521bb8)=>_0x41e7b2&&_0x521bb8?_0x500485['changes']['getIndex'](_0x521bb8):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x3add99,_0x43c878)=>_0x3add99?_0x43c878['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0x3f9961);}['init'](){const _0x80df82=this['editor'],_0x28c8cc=new rt(_0x80df82,{'direction':'backward'}),_0x196e69=new rt(_0x80df82,{'direction':'forward'});(_0x80df82['commands']['add']('showPreviousChange',_0x28c8cc),_0x80df82['commands']['add']('showNextChange',_0x196e69),_0x80df82['commands']['add']('restoreRevision',new nt(_0x80df82)),this['on']('change:numberOfChanges',()=>{_0x28c8cc['refresh'](),_0x196e69['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x80df82['enableReadOnlyMode']('revision-viewer'),_0x80df82['plugins']['has']('WidgetToolbarRepository'))&&_0x80df82['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x608c2d){return await this['_utils']['loadRevisionData'](_0x608c2d,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x608c2d);}async['getRevisionRootsAttributes'](_0x50f40d){return await this['_utils']['loadRevisionData'](_0x50f40d,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x50f40d);}async['compare'](_0x294444,_0x4274df,_0x5f02e7=!0x1){if(!this['isEnabled'])return;const _0x3337b4=this['diff'],_0x5039b7=this['repository'],_0xa71354='string'==typeof _0x294444?_0x5039b7['getRevision'](_0x294444):_0x294444,_0x579faf='string'==typeof _0x4274df?_0x5039b7['getRevision'](_0x4274df):_0x4274df,_0x4771cf=_0xa71354['id'],_0x72c8c3=_0x579faf?_0x579faf['id']:null;if(!_0x5f02e7&&this['diff']&&this['diff']['newRevisionId']===_0x4771cf&&this['diff']['oldRevisionId']===_0x72c8c3)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new J(_0x4771cf,_0x72c8c3);const _0x1c0c3b=this['_getRevisionsRange'](_0xa71354,_0x579faf,!0x0)['map'](_0x37ef59=>this['_utils']['loadRevisionData'](_0x37ef59,this['adapter']));return _0x1c0c3b['push'](new Promise(_0x8c583c=>{setTimeout(_0x8c583c,0x14);})),Promise['all'](_0x1c0c3b)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x59fb3f=this['_getDiff'](_0x4771cf,_0x72c8c3);for(const _0x4061f5 of _0x59fb3f['changes'])this['_changeIdToChange']['set'](_0x4061f5['id'],_0x4061f5);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x2689b5=>{for(const _0x1ef8e5 of this['editor']['model']['document']['getRootNames']())_0x2689b5['detachRoot'](_0x1ef8e5);for(const _0xe7c71e of Object['keys'](_0x59fb3f['model'])){const _0x2581c=_0x2689b5['addRoot'](_0xe7c71e);for(const _0x5bf46f of Object['keys'](_0x59fb3f['attributes'][_0xe7c71e]))_0x2689b5['setAttribute'](_0x5bf46f,_0x59fb3f['attributes'][_0xe7c71e][_0x5bf46f],_0x2581c);_0x2689b5['insert'](_0x59fb3f['model'][_0xe7c71e],_0x2581c,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x59fb3f['changes'])),this['isReady']=!0x0;})['catch'](_0x5972e7=>{console['error'](_0x5972e7),this['_cleanUp'](),_0x3337b4&&(this['diff']=_0x3337b4),this['isReady']=!0x0;});}['addRevisionData'](_0x4600fd,_0x4ee514){const _0x136dc2=this['repository']['createRevision'](_0x4600fd);return _0x136dc2['on']('_update',(_0x1e4b1a,_0x2f2c62,_0x100ced)=>_0x4ee514(_0x2f2c62,_0x100ced,_0x136dc2)),this['repository']['addRevision'](_0x136dc2),_0x136dc2;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x3006eb=>{for(const _0xf76f1c of this['editor']['model']['document']['getRootNames']())_0x3006eb['detachRoot'](_0xf76f1c);});}['_sortAndFilterDiffChanges'](_0x545cf7){const _0x15b435=[],_0x144554=new Map();for(const _0x56eaca of this['editor']['model']['document']['getRootNames']()){const _0x1cfa1c=this['editor']['editing']['view']['getDomRoot'](_0x56eaca);if(!_0x1cfa1c)continue;const _0x278ed7=_0x1cfa1c['getClientRects']()['item'](0x0);_0x278ed7&&(_0x15b435['push'](_0x56eaca),_0x144554['set'](_0x56eaca,_0x278ed7));}return _0x15b435['sort']((_0x346da2,_0x36395c)=>{const _0x49fe67=_0x144554['get'](_0x346da2),_0x13e275=_0x144554['get'](_0x36395c);return _0x49fe67['y']-_0x13e275['y']||_0x49fe67['x']-_0x13e275['x'];}),(_0x545cf7=_0x545cf7['filter'](_0x3b92b4=>_0x15b435['includes'](_0x3b92b4['rootName'])))['sort']((_0x32783c,_0x163a9f)=>_0x15b435['indexOf'](_0x32783c['rootName'])-_0x15b435['indexOf'](_0x163a9f['rootName'])),_0x545cf7;}['_makeTape'](_0x23bfed){const _0x58cf87=Array['from'](_0x23bfed['markers'])['filter'](([_0x17f7d3,_0x3f6fee])=>_0x17f7d3['startsWith']('revision:')&&!_0x3f6fee['isCollapsed']),_0x3e45e7=Array['from'](this['editor']['model']['createRangeIn'](_0x23bfed)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x58cf87['length'])for(const _0x216eb3 of _0x3e45e7){const [_0x147200,_0x56d40a]=_0x58cf87[0x0],[,_0x9df88,_0x5aae26]=_0x147200['split'](':');if(_0x56d40a['end']['isEqual'](_0x216eb3['nextPosition'])&&_0x58cf87['shift'](),(_0x216eb3['previousPosition']['isEqual'](_0x56d40a['start'])||_0x216eb3['previousPosition']['isAfter'](_0x56d40a['start']))&&('insertion'==_0x9df88?_0x216eb3['isAdded']={'userId':_0x5aae26}:'deletion'==_0x9df88&&(_0x216eb3['isRemoved']={'userId':_0x5aae26})),0x0==_0x58cf87['length'])break;}return _0x3e45e7;}['_refreshStartEndIndex'](_0x52edf8){const _0x3b5e23=new Map();for(let _0x341f48=0x0;_0x341f48<_0x52edf8['length'];_0x341f48++)'text'===_0x52edf8[_0x341f48]['type']?(_0x52edf8[_0x341f48]['item']['startIndex']=_0x341f48,_0x52edf8[_0x341f48]['item']['endIndex']=_0x341f48):('elementStart'===_0x52edf8[_0x341f48]['type']?_0x52edf8[_0x341f48]['item']['startIndex']=_0x341f48:'elementEnd'===_0x52edf8[_0x341f48]['type']&&(_0x52edf8[_0x341f48]['item']['endIndex']=_0x341f48),_0x3b5e23['set'](_0x52edf8[_0x341f48]['id'],_0x341f48));for(const _0xa276d4 of _0x3b5e23['values']())'elementStart'===_0x52edf8[_0xa276d4]['type']?_0x52edf8[_0xa276d4]['item']['endIndex']=_0x3b5e23['get'](_0x52edf8[_0xa276d4]['pairId']):'elementEnd'===_0x52edf8[_0xa276d4]['type']&&(_0x52edf8[_0xa276d4]['item']['startIndex']=_0x3b5e23['get'](_0x52edf8[_0xa276d4]['pairId']));}['_processTape'](_0x20efce){for(let _0x176003=0x0;_0x176003<_0x20efce['length'];_0x176003++){if('elementStart'===_0x20efce[_0x176003]['type'])_0x20efce[_0x176003]['item']['startIndex']=_0x176003;else{if('elementEnd'===_0x20efce[_0x176003]['type']){_0x20efce[_0x176003]['item']['endIndex']=_0x176003;const _0x1c1371=_0x20efce[_0x176003]['item']['startIndex'];_0x20efce[_0x1c1371]['pairId']=_0x20efce[_0x176003]['id'],_0x20efce[_0x176003]['pairId']=_0x20efce[_0x1c1371]['id'];}else _0x20efce[_0x176003]['item']['startIndex']=_0x176003,_0x20efce[_0x176003]['item']['endIndex']=_0x176003,_0x20efce[_0x176003]['pairId']=null;}_0x20efce[_0x176003]['markersStart']||(_0x20efce[_0x176003]['markersStart']=[],_0x20efce[_0x176003]['markersEnd']=[]);}}['_markInsertions'](_0x56973f,_0x46259d){const _0x10d823=_0x56973f['filter'](_0x108558=>!_0x108558['isAdded']);for(let _0x467fac=0x0;_0x467fac<_0x46259d['length'];_0x467fac++)_0x46259d[_0x467fac]['isAdded']&&(_0x10d823[_0x467fac]['isAdded']=_0x46259d[_0x467fac]['isAdded']);}['_getDiff'](_0x174ed6,_0x26bbcf=null){const _0x8a62d3=this['repository']['getRevision'](_0x174ed6),_0x27a1be=_0x26bbcf?this['repository']['getRevision'](_0x26bbcf):null,_0x204bc6=this['_getRevisionsRange'](_0x8a62d3,_0x27a1be),_0x49fa9f=_0x204bc6[_0x204bc6['length']-0x1],_0x38af2a=new Map(),_0x3fb5cc={'model':{},'attributes':{},'changes':[]},_0x3180c6=new Set(),_0x3eb375=new Map();for(let _0x2fe21d=_0x204bc6['length']-0x1;_0x2fe21d>=0x0;_0x2fe21d--){const _0x315ab5=_0x204bc6[_0x2fe21d];for(const _0x90f049 of Object['keys'](_0x315ab5['diffData']))if(_0x315ab5['diffData'][_0x90f049]['attachChange']){const _0x3f097a=_0x315ab5['diffData'][_0x90f049]['attachChange'];_0x3f097a['isAttached']?(_0x3180c6['add'](_0x90f049),_0x3eb375['has'](_0x90f049)&&_0x3eb375['get'](_0x90f049)['userId']==_0x3f097a['userId']?_0x3eb375['delete'](_0x90f049):_0x3eb375['set'](_0x90f049,_0x3f097a)):_0x3eb375['has'](_0x90f049)?(_0x3180c6['delete'](_0x90f049),_0x3eb375['delete'](_0x90f049)):(_0x3180c6['add'](_0x90f049),_0x3eb375['set'](_0x90f049,_0x3f097a));}else _0x3180c6['add'](_0x90f049);}for(const _0x5dcd48 of _0x3180c6){const _0x4e2339=_0x3eb375['has'](_0x5dcd48)&&!_0x3eb375['get'](_0x5dcd48)['isAttached'];let _0x4da947=_0x4e2339?_0x204bc6['length']-0x1:0x0;const _0x4ea312=_0x4e2339?-0x1:0x1;for(;_0x204bc6[_0x4da947];){const _0x37a32a=_0x204bc6[_0x4da947];if(_0x37a32a['diffData'][_0x5dcd48]){const _0x4b227b=_0x4e2339?_0x37a32a['diffData'][_0x5dcd48]['attributesBefore']:_0x37a32a['diffData'][_0x5dcd48]['attributesAfter'];_0x3fb5cc['attributes'][_0x5dcd48]=_0x4b227b?_0x14aaba(_0x4b227b):{};break;}_0x4da947+=_0x4ea312;}}for(const _0x144012 of _0x204bc6){_0x144012['model']={};for(const _0x12a08a of _0x144012['authors'])_0x38af2a['set'](_0x12a08a['id'],_0x12a08a);for(const _0x3fb070 of _0x3180c6){const _0x4c7d33=_0x144012['diffData'][_0x3fb070]?_0x144012['diffData'][_0x3fb070]['insertions']:'[]',_0x521a68=_0x144012['diffData'][_0x3fb070]?_0x144012['diffData'][_0x3fb070]['deletions']:'[]';_0x144012['model'][_0x3fb070]={'insertions':this['_utils']['_makeModelFromViewString'](_0x4c7d33),'deletions':this['_utils']['_makeModelFromViewString'](_0x521a68)};}}for(const _0x33f490 of _0x3180c6){let _0x2a3bbb=null,_0x3acd8b=0x0;const _0x4b2522=new Map(Array['from'](_0x8a62d3['model'][_0x33f490]['insertions']['markers'])['filter'](([_0x46edbd])=>!_0x46edbd['startsWith']('revision:')));let _0x51b6f6=0x0;for(const _0x533d21 of _0x204bc6){const _0x2695b4=this['_makeTape'](_0x533d21['model'][_0x33f490]['insertions']);_0x533d21==_0x8a62d3?(_0x2a3bbb=_0x2695b4,_0x3acd8b=_0x2a3bbb['length'],_0x2a3bbb['forEach'](_0x1ff197=>{_0x1ff197['id']=_0x51b6f6++;}),this['_processTape'](_0x2a3bbb)):this['_markInsertions'](_0x2a3bbb,_0x2695b4);const _0x2bc747=_0x2a3bbb['filter'](_0x5d2d06=>!_0x5d2d06['isAdded'])['map'](_0x2cfa9d=>_0x2cfa9d['id']);let _0xe0aed0=0x0;const _0x46aa0b=this['_makeTape'](_0x533d21['model'][_0x33f490]['deletions']);_0x46aa0b['forEach'](_0x17eb14=>{_0x17eb14['isRemoved']?_0x17eb14['id']=_0x3acd8b++:_0x17eb14['id']=_0x2bc747[_0xe0aed0++];}),this['_processTape'](_0x46aa0b),this['_setDistance'](_0x2a3bbb,'isAdded'),this['_setDistance'](_0x46aa0b,'isRemoved'),_0x533d21==_0x8a62d3&&this['_markMarkers'](_0x2a3bbb,_0x4b2522),_0x2a3bbb=this['_joinTapes'](_0x2a3bbb,_0x46aa0b),this['_refreshStartEndIndex'](_0x2a3bbb),this['_setDistance'](_0x2a3bbb,'isRemoved');}_0x2a3bbb=_0x2a3bbb['filter'](_0x52b836=>!(_0x52b836['isAdded']&&_0x52b836['isRemoved']));const _0x23cbaf=new Map(_0x49fa9f['model'][_0x33f490]['deletions']['markers']),_0x17c015=new Set(_0x4b2522['keys']());for(const _0x3130aa of _0x23cbaf['keys']())_0x17c015['delete'](_0x3130aa);this['_markSuggestions'](_0x2a3bbb,_0x17c015),this['_fixObsoleteTags'](_0x2a3bbb),_0x2a3bbb=this['_removeMissingPairs'](_0x2a3bbb),_0x2a3bbb=this['_markMismatchedRemovedTags'](_0x2a3bbb),_0x2a3bbb=this['_removeUnsupportedChanges'](_0x2a3bbb);const {root:_0x56f71a,changes:_0x141254}=this['_makeModelFromTape'](_0x2a3bbb,_0x38af2a,_0x33f490);_0x3fb5cc['model'][_0x33f490]=_0x56f71a;const _0x43f5ae=_0x3eb375['get'](_0x33f490);if(_0x43f5ae){const _0x24bdb6=_0x38af2a['get'](_0x43f5ae['userId']),_0x3a4ce4=new G({'author':_0x24bdb6,'type':_0x43f5ae['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x33f490});_0x141254['unshift'](_0x3a4ce4),_0x3fb5cc['attributes'][_0x33f490]['revisionHistoryAttachChange']=_0x3a4ce4['id'];}_0x3fb5cc['changes']=_0x3fb5cc['changes']['concat'](_0x141254);}return _0x3fb5cc;}['_markMarkers'](_0x313ff4,_0xf02e6d){for(let _0x34aec4=0x0;_0x34aec4<_0x313ff4['length'];_0x34aec4++)for(const [_0x550ce3,_0x22e8ca]of _0xf02e6d)!_0x22e8ca['isCollapsed']&&_0x22e8ca['start']['isEqual'](_0x313ff4[_0x34aec4]['previousPosition'])&&_0x313ff4[_0x34aec4]['markersStart']['push'](_0x550ce3),_0x22e8ca['end']['isEqual'](_0x313ff4[_0x34aec4]['nextPosition'])&&_0x313ff4[_0x34aec4]['markersEnd']['push'](_0x550ce3);}['_joinTapes'](_0x16b746,_0x5c3189){let _0x4ccd49=[],_0x333c1c=0x0,_0x2946b6=0x0;for(;_0x333c1c<_0x16b746['length']||_0x2946b6<_0x5c3189['length'];){const _0x3ca7e4=_0x16b746[_0x333c1c]||{},_0x2f1285=_0x5c3189[_0x2946b6]||{};if(_0x3ca7e4['id']==_0x2f1285['id'])_0x333c1c++,_0x2946b6++,_0x4ccd49['push'](_0x3ca7e4);else{if(_0x2f1285['isRemoved']&&_0x3ca7e4['isAdded']){const {commonTape:_0x7985c1,iEnd:_0x3795ab,jEnd:_0x494aae}=this['_threeWayMerge'](_0x16b746,_0x333c1c,_0x5c3189,_0x2946b6);_0x4ccd49=_0x4ccd49['concat'](_0x7985c1),_0x333c1c=_0x3795ab,_0x2946b6=_0x494aae;}else _0x2f1285['isRemoved']?(_0x2946b6++,_0x4ccd49['push'](_0x2f1285)):(_0x333c1c++,_0x4ccd49['push'](_0x3ca7e4));}}return _0x4ccd49;}['_markSuggestions'](_0x299e27,_0x533e01){const _0x3651ee=[];for(let _0xdc2d2=0x0;_0xdc2d2<_0x299e27['length'];_0xdc2d2++){for(let _0x259a35=0x0;_0x259a35<_0x299e27[_0xdc2d2]['markersStart']['length'];_0x259a35++){const _0x6a462f=_0x299e27[_0xdc2d2]['markersStart'][_0x259a35];if(!_0x533e01['has'](_0x6a462f))continue;const {group:_0x4df889,type:_0x2328c7,authorId:_0x41ba4c}=_0x1117aa(_0x6a462f);'revision-suggestion'!=_0x4df889||'insertion'!=_0x2328c7&&'deletion'!=_0x2328c7||(_0x3651ee['unshift']({'type':_0x2328c7,'name':_0x6a462f,'userId':_0x41ba4c}),_0x299e27[_0xdc2d2]['markersStart']['splice'](_0x259a35,0x1),_0x259a35--);}_0x286942(_0x299e27[_0xdc2d2]);for(let _0x403381=0x0;_0x403381<_0x299e27[_0xdc2d2]['markersEnd']['length'];_0x403381++){const _0x36e73c=_0x299e27[_0xdc2d2]['markersEnd'][_0x403381];if(!_0x533e01['has'](_0x36e73c))continue;const {group:_0x2113c1,type:_0x3370bd}=_0x1117aa(_0x36e73c);if('revision-suggestion'!=_0x2113c1||'insertion'!=_0x3370bd&&'deletion'!=_0x3370bd)continue;_0x299e27[_0xdc2d2]['markersEnd']['splice'](_0x403381,0x1),_0x403381--;const _0x3f6dcb=_0x3651ee['findIndex'](_0x3b6e06=>_0x3b6e06['name']==_0x36e73c);_0x3f6dcb>-0x1&&_0x3651ee['splice'](_0x3f6dcb,0x1);}}function _0x1117aa(_0x30cdcf){const _0x33691c=_0x30cdcf['split'](':');return{'group':_0x33691c[0x0],'type':_0x33691c[0x1],'subType':_0x33691c['length']>=0x5?_0x33691c[0x2]:null,'id':_0x33691c['length']<0x5?_0x33691c[0x2]:_0x33691c[0x3],'authorId':_0x33691c['length']<0x5?_0x33691c[0x3]:_0x33691c[0x4],'markerCount':0x6==_0x33691c['length']?_0x33691c[0x5]:null};}function _0x286942(_0x3f4f1a){for(let _0x290b70=0x0;_0x290b70<_0x3651ee['length'];_0x290b70++){if(_0x3f4f1a['isAdded']&&'insertion'==_0x3651ee[_0x290b70]['type']&&_0x3f4f1a['isAdded']['userId']==_0x3651ee[_0x290b70]['userId'])return _0x3f4f1a['isAddSuggestion']=_0x3651ee[_0x290b70],void delete _0x3f4f1a['isAdded'];if(!_0x3f4f1a['isAdded']&&!_0x3f4f1a['isRemoved']&&'deletion'==_0x3651ee[_0x290b70]['type'])return void(_0x3f4f1a['isRemoveSuggestion']=_0x3651ee[_0x290b70]);}}}['_setDistance'](_0x15ffed,_0x5318e7){let _0x5812df=0x0,_0x319bf2=!0x1;const _0x27eadb=new Map();for(const _0xe2cc47 of _0x15ffed)_0xe2cc47[_0x5318e7]?_0x319bf2&&(_0x5812df++,_0x319bf2=!0x1):(_0x5812df++,_0x319bf2=!0x0),_0x27eadb['set'](_0xe2cc47['id'],_0x5812df);for(let _0x4ddc9e=0x0;_0x4ddc9e<_0x15ffed['length'];_0x4ddc9e++){if('isRemoved'==_0x5318e7&&_0x15ffed[_0x4ddc9e]['isAdded']||'isAdded'==_0x5318e7&&_0x15ffed[_0x4ddc9e]['isRemoved'])continue;if('text'==_0x15ffed[_0x4ddc9e]['type']){_0x15ffed[_0x4ddc9e]['distance']=0x0;continue;}const _0x25ae74=_0x27eadb['get'](_0x15ffed[_0x4ddc9e]['pairId']),_0x1fca60=_0x27eadb['get'](_0x15ffed[_0x4ddc9e]['id']);_0x15ffed[_0x4ddc9e]['distance']=_0x25ae74-_0x1fca60;}}['_getRevisionsRange'](_0x1a8654,_0x13431d,_0xf0e7f0=!0x1){const _0xd38efe=[];let _0x156791=this['repository']['getIndex'](_0x1a8654),_0xc99ca4=this['repository']['getIndex'](_0x13431d);for(-0x1==_0xc99ca4&&(_0xc99ca4=this['repository']['_revisions']['length'],_0xf0e7f0=!0x1);_0x156791<_0xc99ca4;)_0xd38efe['push'](this['repository']['getRevision'](_0x156791)),_0x156791++;return _0xf0e7f0&&_0xd38efe['push'](this['repository']['getRevision'](_0x156791)),_0xd38efe;}['_threeWayMerge'](_0x20eb66,_0x98631,_0x33aac1,_0x4dd302){const _0x40588f=this['editor']['model']['schema'];let _0x572193=_0x98631;for(;_0x20eb66[_0x572193]&&_0x20eb66[_0x572193]['isAdded'];)_0x572193++;let _0x1306ba=_0x4dd302;for(;_0x33aac1[_0x1306ba]&&_0x33aac1[_0x1306ba]['isRemoved'];)_0x1306ba++;_0x479d45(_0x20eb66,_0x98631,_0x572193),_0x479d45(_0x33aac1,_0x4dd302,_0x1306ba);const _0x1490d4=_0x33aac1['slice'](_0x4dd302,_0x1306ba)['concat'](_0x20eb66['slice'](_0x98631,_0x572193));return _0x1490d4['sort']((_0x4a215c,_0x3a5ab1)=>_0x4a215c['side']!=_0x3a5ab1['side']?_0x4a215c['side']-_0x3a5ab1['side']:_0x4a215c['level']!=_0x3a5ab1['level']?_0x4a215c['level']-_0x3a5ab1['level']:_0x4a215c['distance']!=_0x3a5ab1['distance']?_0x3a5ab1['distance']-_0x4a215c['distance']:!!_0x4a215c['isAdded']!=!!_0x3a5ab1['isAdded']?-0x1==_0x4a215c['side']||0x0==_0x4a215c['side']?_0x4a215c['isAdded']?-0x1:0x1:_0x4a215c['isAdded']?0x1:-0x1:_0x4a215c['index']-_0x3a5ab1['index']),{'commonTape':_0x1490d4,'iEnd':_0x572193,'jEnd':_0x1306ba};function _0x479d45(_0x1fc2a8,_0x3c003d,_0x5d581e){let _0x3783d0=-0x1,_0x2661fd=Number['POSITIVE_INFINITY'],_0x12db62=!0x0;for(let _0x554215=_0x3c003d;_0x554215<_0x5d581e;_0x554215++)if(_0x40588f['isInline'](_0x1fc2a8[_0x554215]['item'])||(_0x12db62=!0x1),_0x1fc2a8[_0x554215]['item']['startIndex']<_0x3c003d&&(_0x3783d0=_0x554215),_0x1fc2a8[_0x554215]['item']['endIndex']>=_0x5d581e){_0x2661fd=_0x554215;break;}_0x12db62&&(_0x3783d0=_0x5d581e-0x1);for(let _0x416260=_0x3c003d;_0x416260<_0x5d581e;_0x416260++)_0x1fc2a8[_0x416260]['side']=_0x416260<=_0x3783d0?-0x1:_0x416260<_0x2661fd?0x0:0x1,_0x1fc2a8[_0x416260]['index']=_0x416260;let _0x3cb881=0x0;for(let _0x3212bd=_0x3c003d;_0x3212bd<=_0x3783d0;_0x3212bd++)0x0==_0x1fc2a8[_0x3212bd]['distance']?_0x1fc2a8[_0x3212bd]['level']=_0x3cb881:(_0x3cb881++,_0x1fc2a8[_0x3212bd]['level']=_0x3cb881,_0x3cb881++);for(let _0x20aa10=_0x3c003d;_0x20aa10<_0x5d581e;_0x20aa10++)0x0==_0x1fc2a8[_0x20aa10]['side']&&(_0x1fc2a8[_0x20aa10]['level']=_0x3cb881);_0x3cb881=0x0;for(let _0x107894=_0x5d581e-0x1;_0x107894>=_0x2661fd;_0x107894--)0x0==_0x1fc2a8[_0x107894]['distance']?_0x1fc2a8[_0x107894]['level']=_0x3cb881:(_0x3cb881--,_0x1fc2a8[_0x107894]['level']=_0x3cb881,_0x3cb881--);}}['_fixObsoleteTags'](_0x1c7eef){const _0x14f5c5=new Map(),_0x1235b7=this['editor']['model']['schema'];for(let _0x54c81a=0x1;_0x54c81a<_0x1c7eef['length'];_0x54c81a++){let _0x343fa6,_0x2beb31,_0x9a80e7;const _0x3e7e76=_0x1c7eef[_0x54c81a],_0x3272f3=_0x1c7eef[_0x54c81a-0x1];if('text'==_0x3e7e76['type'])continue;if(_0x3e7e76['type']!=_0x3272f3['type'])continue;if(!_0x1235b7['isBlock'](_0x3272f3['item'])||_0x1235b7['isLimit'](_0x3272f3['item']))continue;if(!_0x1235b7['isBlock'](_0x3e7e76['item'])||_0x1235b7['isLimit'](_0x3e7e76['item']))continue;if((_0x1c7eef[_0x54c81a]['isAdded']||_0x1c7eef[_0x54c81a]['isAddSuggestion'])&&_0x1c7eef[_0x54c81a-0x1]['isRemoved'])_0x343fa6=_0x1c7eef[_0x54c81a],_0x2beb31=_0x1c7eef[_0x54c81a-0x1],_0x9a80e7=_0x54c81a-0x1;else{if(!_0x1c7eef[_0x54c81a]['isRemoved']||!_0x1c7eef[_0x54c81a-0x1]['isAdded']&&!_0x1c7eef[_0x54c81a-0x1]['isAddSuggestion'])continue;_0x343fa6=_0x1c7eef[_0x54c81a-0x1],_0x2beb31=_0x1c7eef[_0x54c81a],_0x9a80e7=_0x54c81a;}const _0x5f5d08=_0x343fa6['level']==_0x2beb31['level'],_0x35b1ba=Math['abs'](_0x343fa6['level'])<Math['abs'](_0x2beb31['level'])&&0x0==_0x2beb31['distance'];(_0x5f5d08||_0x35b1ba)&&(_0x14f5c5['set'](_0x2beb31['id'],_0x343fa6['id']),_0x1c7eef['splice'](_0x9a80e7,0x1),_0x54c81a--,_0x343fa6['isAdded']=!0x1);}for(let _0x4f77d8=0x0;_0x4f77d8<_0x1c7eef['length'];_0x4f77d8++)_0x14f5c5['has'](_0x1c7eef[_0x4f77d8]['pairId'])&&(_0x1c7eef[_0x4f77d8]['pairId']=_0x14f5c5['get'](_0x1c7eef[_0x4f77d8]['pairId']));}['_removeMissingPairs'](_0xea2569){const _0x44c0ea=new Set(_0xea2569['map'](_0x42053c=>_0x42053c['id']));for(let _0x454c5d=0x0;_0x454c5d<_0xea2569['length'];_0x454c5d++)_0x44c0ea['has'](_0xea2569[_0x454c5d]['pairId'])||0x0==_0xea2569[_0x454c5d]['distance']||(_0xea2569[_0x454c5d]['isIncorrect']=!0x0);return _0xea2569['filter'](_0x1f79f7=>!_0x1f79f7['isIncorrect']);}['_markMismatchedRemovedTags'](_0xfa533e){const _0x1b8050=new Set();for(let _0x49a964=0x0;_0x49a964<_0xfa533e['length'];_0x49a964++){if(_0x1b8050['has'](_0xfa533e[_0x49a964]['id'])&&_0xfa533e[_0x49a964]['isRemoved']&&(_0xfa533e[_0x49a964]['isIncorrect']=!0x0),_0xfa533e[_0x49a964]['isIncorrect'])continue;if(0x0==_0xfa533e[_0x49a964]['distance'])continue;if('elementStart'!=_0xfa533e[_0x49a964]['type'])continue;if(null==_0xfa533e[_0x49a964]['pairId'])continue;let _0x33cbb4=_0x49a964+0x1,_0x11c8f2=0x0;for(;_0xfa533e[_0x33cbb4]['id']!=_0xfa533e[_0x49a964]['pairId'];)'elementStart'==_0xfa533e[_0x33cbb4]['type']?_0x11c8f2++:'elementEnd'==_0xfa533e[_0x33cbb4]['type']&&_0x11c8f2--,_0x33cbb4++;if(0x0!=_0x11c8f2){if(_0xfa533e[_0x49a964]['isRemoved'])_0xfa533e[_0x49a964]['isIncorrect']=!0x0;else{for(;_0x33cbb4!=_0x49a964;)_0xfa533e[_0x33cbb4]['isRemoved']&&0x0!=_0xfa533e[_0x33cbb4]['distance']&&(_0xfa533e[_0x33cbb4]['isIncorrect']=!0x0,_0x1b8050['add'](_0xfa533e[_0x33cbb4]['pairId'])),_0x33cbb4--;}}}return _0xfa533e['filter'](_0x18ce0e=>!_0x18ce0e['isIncorrect']);}['_removeUnsupportedChanges'](_0x109a5f){const _0x54917b=this['editor']['model']['schema'];for(let _0x2c066a=0x0;_0x2c066a<_0x109a5f['length'];_0x2c066a++){if(!(_0x109a5f[_0x2c066a]['isAdded']||_0x109a5f[_0x2c066a]['isAddSuggestion']||_0x109a5f[_0x2c066a]['isRemoved']||_0x109a5f[_0x2c066a]['isRemoveSuggestion']))continue;if(0x0==_0x109a5f[_0x2c066a]['distance'])continue;const _0xb48b9=_0x109a5f[_0x2c066a]['item'];_0x54917b['isBlock'](_0xb48b9)||_0x54917b['isLimit'](_0xb48b9)||(_0x109a5f[_0x2c066a]['isAdded']&&delete _0x109a5f[_0x2c066a]['isAdded'],_0x109a5f[_0x2c066a]['isAddSuggestion']&&delete _0x109a5f[_0x2c066a]['isAddSuggestion'],_0x109a5f[_0x2c066a]['isRemoveSuggestion']&&delete _0x109a5f[_0x2c066a]['isRemoveSuggestion'],_0x109a5f[_0x2c066a]['isRemoved']&&(_0x109a5f[_0x2c066a]['isIncorrect']=!0x0));}return _0x109a5f['filter'](_0x3768ee=>!_0x3768ee['isIncorrect']);}['_makeModelFromTape'](_0x3a74f3,_0x39ddcc,_0x4e2995){const _0x3b7641=new _0x597820(),_0x5a0679=[],_0x32e19e=new Map(),_0x41ec13=this['editor']['model'],_0x1a7b2f=_0x41ec13['schema'],_0x43ec14=[_0x3b7641],_0x59fc6d={},_0x14f4a7={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x862be4=null;const _0x463265=[0x0];for(let _0xdca0a0=0x0;_0xdca0a0<_0x3a74f3['length'];_0xdca0a0++)if('elementStart'===_0x3a74f3[_0xdca0a0]['type']){_0x3a74f3[_0xdca0a0]['previousPosition']=_0x41ec13['createPositionFromPath'](_0x3b7641,_0x463265);const _0x299759=new _0x3ade8a(_0x3a74f3[_0xdca0a0]['item']['name'],_0x3a74f3[_0xdca0a0]['item']['getAttributes']());_0x43ec14[0x0]['_appendChild'](_0x299759),_0x463265['push'](0x0),_0x43ec14['unshift'](_0x299759),_0x3a74f3[_0xdca0a0]['nextPosition']=_0x41ec13['createPositionFromPath'](_0x3b7641,_0x463265);}else'elementEnd'===_0x3a74f3[_0xdca0a0]['type']?(_0x43ec14['shift'](),_0x3a74f3[_0xdca0a0]['previousPosition']=_0x41ec13['createPositionFromPath'](_0x3b7641,_0x463265),_0x463265['pop'](),_0x463265[_0x463265['length']-0x1]++,_0x3a74f3[_0xdca0a0]['nextPosition']=_0x41ec13['createPositionFromPath'](_0x3b7641,_0x463265)):(_0x3a74f3[_0xdca0a0]['previousPosition']=_0x41ec13['createPositionFromPath'](_0x3b7641,_0x463265),_0x862be4?_0x862be4['_data']+=_0x3a74f3[_0xdca0a0]['item']['data']:_0x862be4=new _0x545827(_0x3a74f3[_0xdca0a0]['item']['data'],_0x3a74f3[_0xdca0a0]['item']['getAttributes']()),_0x3a74f3[_0xdca0a0+0x1]&&'text'===_0x3a74f3[_0xdca0a0+0x1]['type']&&_0x20b295(_0x862be4,_0x3a74f3[_0xdca0a0+0x1]['item'])||(_0x43ec14[0x0]['_appendChild'](_0x862be4),_0x862be4=null),_0x463265[_0x463265['length']-0x1]+=_0x3a74f3[_0xdca0a0]['item']['offsetSize'],_0x3a74f3[_0xdca0a0]['nextPosition']=_0x41ec13['createPositionFromPath'](_0x3b7641,_0x463265));for(let _0xa0c3cd=0x0;_0xa0c3cd<_0x3a74f3['length'];_0xa0c3cd++){const _0x4dee6f=_0x3a74f3[_0xa0c3cd]['previousPosition'],_0x2f20a0=_0x3a74f3[_0xa0c3cd]['nextPosition'];for(const _0x30efa1 of _0x3a74f3[_0xa0c3cd]['markersStart'])_0x32e19e['set'](_0x30efa1,{'start':_0x4dee6f,'end':null});_0x260ebb('isRemoveSuggestion',_0xa0c3cd,_0x4dee6f,_0x2f20a0),_0x260ebb('isAddSuggestion',_0xa0c3cd,_0x4dee6f,_0x2f20a0),_0x260ebb('isRemoved',_0xa0c3cd,_0x4dee6f,_0x2f20a0),_0x260ebb('isAdded',_0xa0c3cd,_0x4dee6f,_0x2f20a0);for(const _0x5b57bd of _0x3a74f3[_0xa0c3cd]['markersEnd']){const _0x15b801=_0x32e19e['get'](_0x5b57bd);_0x15b801?_0x15b801['end']=_0x2f20a0:_0x32e19e['set'](_0x5b57bd,{'start':_0x2f20a0,'end':_0x2f20a0});}}for(const [_0x5197f5,_0x42f5f4]of _0x32e19e){const _0x366a21=this['editor']['model']['createRange'](_0x42f5f4['start'],_0x42f5f4['end']);_0x3b7641['markers']['set'](_0x5197f5,_0x366a21);}return _0x5a0679['sort']((_0x46bb50,_0x136a46)=>{const _0x3fc458=_0x3b7641['markers']['get']('revision:'+_0x46bb50['id']),_0xec1320=_0x3b7641['markers']['get']('revision:'+_0x136a46['id']);return _0x3fc458['start']['isBefore'](_0xec1320['start'])?-0x1:_0x3fc458['start']['isAfter'](_0xec1320['start'])?0x1:_0x3fc458['end']['isBefore'](_0xec1320['end'])?-0x1:_0x3fc458['end']['isAfter'](_0xec1320['end'])?0x1:'add'===_0x46bb50['type']?-0x1:0x1;}),{'root':_0x3b7641,'changes':_0x5a0679};function _0x260ebb(_0x2446b2,_0x392624,_0x53afac,_0x2577b5){const _0x1896e4=!!_0x3a74f3[_0x392624][_0x2446b2],_0x950e82=_0x1896e4?_0x3a74f3[_0x392624][_0x2446b2]['userId']:null,_0x550e5f=_0x392624===_0x3a74f3['length']-0x1,_0x3cac7e=_0x14f4a7[_0x2446b2][0x0],_0x4711cd=_0x1a7b2f['isObject'](_0x3a74f3[_0x392624]['item']);!_0x59fc6d[_0x2446b2]&&_0x1896e4?_0x59fc6d[_0x2446b2]={'start':_0x53afac,'tapeItem':_0x3a74f3[_0x392624],'userId':_0x950e82,'type':_0x2446b2}:_0x59fc6d[_0x2446b2]&&!_0x1896e4?(_0x59fc6d[_0x2446b2]['end']=_0x53afac,_0x39f587(_0x59fc6d[_0x2446b2]),_0x59fc6d[_0x2446b2]=null):_0x59fc6d[_0x2446b2]&&_0x1896e4&&_0x59fc6d[_0x2446b2]['userId']!==_0x950e82&&(_0x59fc6d[_0x2446b2]['end']=_0x53afac,_0x3cac7e&&_0x3cac7e['userId']===_0x59fc6d[_0x2446b2]['userId']||_0x39f587(_0x59fc6d[_0x2446b2]),_0x59fc6d[_0x2446b2]={'start':_0x53afac,'tapeItem':_0x3a74f3[_0x392624],'userId':_0x950e82,'type':_0x2446b2}),_0x59fc6d[_0x2446b2]&&_0x4711cd&&('elementStart'!==_0x3a74f3[_0x392624]['type']||_0x3cac7e&&_0x3cac7e['userId']===_0x950e82||_0x14f4a7[_0x2446b2]['unshift']({'userId':_0x950e82,'object':_0x3a74f3[_0x392624]['item'],'change':_0x59fc6d[_0x2446b2]}),'elementEnd'===_0x3a74f3[_0x392624]['type']&&_0x3cac7e&&_0x3cac7e['object']===_0x3a74f3[_0x392624]['item']&&(_0x14f4a7[_0x2446b2]['shift'](),_0x59fc6d[_0x2446b2]=_0x3cac7e['change'])),_0x59fc6d[_0x2446b2]&&_0x550e5f&&(_0x59fc6d[_0x2446b2]['end']=_0x2577b5,_0x39f587(_0x59fc6d[_0x2446b2]),_0x59fc6d[_0x2446b2]=null);}function _0x39f587({start:_0x4f49df,end:_0x33d4cc,tapeItem:_0x4b03c0,userId:_0x1726d9,type:_0x44fc32}){const _0x4aaf45=_0x4b03c0['item'],_0x2cf9bf=_0x41ec13['schema']['isBlock'](_0x4aaf45)&&!_0x41ec13['schema']['isLimit'](_0x4aaf45),_0x58b64f=_0x4f49df['nodeAfter']==_0x33d4cc['parent']&&_0x33d4cc['isAtStart'];if(_0x2cf9bf&&_0x58b64f)return;const _0x4cf1f0=_0x41ec13['createRange'](_0x4f49df,_0x33d4cc),_0x509d82=_0x39ddcc['get'](_0x1726d9),_0xcf932b=new G({'author':_0x509d82,'type':'isAdded'==_0x44fc32||'isAddSuggestion'==_0x44fc32?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x44fc32||'isRemoveSuggestion'==_0x44fc32},'createdAt':new Date(),'rootName':_0x4e2995});_0x5a0679['push'](_0xcf932b),_0x3b7641['markers']['set']('revision:'+_0xcf932b['id'],_0x4cf1f0);}function _0x20b295(_0x2de342,_0x8d1b11){const _0x538f66=_0x2de342['getAttributes'](),_0xc56b5c=_0x8d1b11['getAttributes']();for(const _0x3163c5 of _0x538f66){if(_0x3163c5[0x1]!==_0x8d1b11['getAttribute'](_0x3163c5[0x0]))return!0x1;_0xc56b5c['next']();}return _0xc56b5c['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x5757dc=>{const _0x4483c0=_0x5757dc['markerName']['split'](':')[0x1],_0x15a088=this['_getChangeFromId'](_0x4483c0);if(!_0x15a088)return null;const _0xe8cb1='add'==_0x15a088['type']?'insertion':'deletion',_0x2681c3=['ck-suggestion-marker','ck-suggestion-marker-'+_0xe8cb1];return _0x15a088['data']['isSuggestion']&&_0x2681c3['push']('ck-suggestion-marker-'+_0xe8cb1+'-new'),this['activeChange']==_0x15a088&&_0x2681c3['push']('ck-suggestion-marker--active'),{'classes':_0x2681c3,'attributes':{'data-change-id':_0x4483c0}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x26a801=>{_0x26a801['on']('element:pre',(_0x203f94,_0x4ae75c,_0x1efbc1)=>{const _0x5d5a1c=_0x4ae75c['viewItem']['getChild'](0x0);if(!_0x5d5a1c||!_0x5d5a1c['is']('element','code'))return;if(!_0x1efbc1['consumable']['consume'](_0x5d5a1c,{'attributes':['vid_start','vid_end']}))return;const _0x156b30=_0x4ae75c['modelRange']['start']['nodeAfter'];_0x1efbc1['writer']['setAttribute']('vid_start',_0x5d5a1c['getAttribute']('vid_start'),_0x156b30),_0x1efbc1['writer']['setAttribute']('vid_end',_0x5d5a1c['getAttribute']('vid_end'),_0x156b30);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x5c26c2=>{_0x5c26c2['on']('element',(_0x395330,_0x1858f0,_0x538c67)=>{if(!_0x538c67['consumable']['consume'](_0x1858f0['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x1858f0['modelRange']['isCollapsed'])return;const _0x1af460=_0x1858f0['modelRange']['start']['nodeAfter'];_0x1af460['hasAttribute']('vid_start')||_0x1af460['hasAttribute']('vid')||(_0x538c67['writer']['setAttribute']('vid_start',_0x1858f0['viewItem']['getAttribute']('vid_start'),_0x1af460),_0x538c67['writer']['setAttribute']('vid_end',_0x1858f0['viewItem']['getAttribute']('vid_end'),_0x1af460));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x5d207e=>_0x5d207e['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x395a8a,[,_0x21e364])=>{['vid_start','vid_end','vid']['includes'](_0x21e364)&&(_0x395a8a['return']=!0x0,_0x395a8a['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x57b68e=>{_0x57b68e['on']('attribute:vid',(_0x587698,_0x4dd572,_0x3858b2)=>{if('\x20'!=_0x4dd572['item']['data']||_0x4dd572['item']['parent']['maxOffset']>0x1)return;if(!_0x3858b2['consumable']['consume'](_0x4dd572['item'],_0x587698['name']))return;const _0xab5e3b=_0x3858b2['writer'],_0x5b524c=_0x3858b2['mapper']['toViewRange'](_0x4dd572['range']);_0xab5e3b['wrap'](_0x5b524c,_0xab5e3b['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x30ebe1){const _0x37e9ac=_0x30ebe1['plugins']['get']('RevisionViewer');return(_0x15ff19,_0x54e96f,_0x5110bb)=>{const _0x333a5c=_0x54e96f['markerName']['split'](':')[0x1],_0x3e254d=_0x37e9ac['_getChangeFromId'](_0x333a5c);if(!_0x3e254d)return null;const _0x3bb4c5='add'==_0x3e254d['type']?'split':'merge';if(!_0x5110bb['consumable']['test'](_0x54e96f['markerRange'],_0x15ff19['name']))return;const _0x763579=_0x54e96f['markerRange']['getWalker'](),_0x365f03=_0x54e96f['markerRange']['start'],_0x44521d=_0x30ebe1['model']['schema'];let _0x2f7add=null,_0x20b264=null,_0x235e2b=!0x1,_0x291b51=!0x1;for(const _0x39fad6 of _0x763579){const _0x3ffad6=_0x39fad6['item'];_0x235e2b=_0x235e2b||_0x44521d['isContent'](_0x3ffad6);const _0x3a1da6=_0x5110bb['mapper']['toViewElement'](_0x3ffad6);if(_0x3a1da6&&_0x3a1da6['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x39fad6['type']&&(_0x44521d['isBlock'](_0x3ffad6)&&!_0x44521d['isLimit'](_0x3ffad6)&&(_0x3ffad6['nextSibling']||_0x365f03['isAtEnd']?_0x2f7add&&_0x2f7add['parent']==_0x3ffad6||(_0x2f7add=_0x3ffad6,_0x419b4b(_0x39fad6['previousPosition']),_0x291b51=!0x0):_0x20b264=_0x20b264||_0x39fad6['previousPosition']));}function _0x419b4b(_0x26e25b){const _0x369e6e=_0x5110bb['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x3bb4c5}),_0x7039b8=_0x5110bb['mapper']['toViewPosition'](_0x26e25b);_0x3e254d['data']['isSuggestion']&&_0x5110bb['writer']['addClass']('ck-suggestion-marker-'+_0x3bb4c5+'-new',_0x369e6e),_0x37e9ac['activeChange']==_0x3e254d&&_0x5110bb['writer']['addClass']('ck-suggestion-marker--active',_0x369e6e),_0x5110bb['writer']['insert'](_0x7039b8,_0x369e6e),_0x5110bb['mapper']['bindElementToMarker'](_0x369e6e,_0x54e96f['markerName']);}_0x235e2b||_0x291b51||!_0x20b264||_0x419b4b(_0x20b264);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0xb1c347,_0x545495,_0x5c0e4d)=>{const _0x16082c=_0x5c0e4d['mapper']['markerNameToElements'](_0x545495['markerName']);if(_0x16082c){for(const _0x592f71 of _0x16082c)(_0x592f71['hasClass']('ck-suggestion-marker-split')||_0x592f71['hasClass']('ck-suggestion-marker-merge'))&&(_0x5c0e4d['mapper']['unbindElementFromMarkerName'](_0x592f71,_0x545495['markerName']),_0x5c0e4d['writer']['remove'](_0x592f71));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x475222,_0x22c6f6,_0x2bcdd0)=>{const _0x2b8752=_0x22c6f6['markerName']['split'](':')[0x1],_0x5cfd26=this['_getChangeFromId'](_0x2b8752);if(!_0x5cfd26)return null;const _0xf8dbb2='add'==_0x5cfd26['type']?'split':'merge';if(_0x2bcdd0['consumable']['test'](_0x22c6f6['markerRange'],_0x475222['name']))for(const _0x526b4a of _0x22c6f6['markerRange']['getItems']()){if(!_0x526b4a['is']('element','softBreak'))continue;const _0x450297=_0x2bcdd0['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0xf8dbb2}),_0xb35310=_0x2bcdd0['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x526b4a));_0x5cfd26['data']['isSuggestion']&&_0x2bcdd0['writer']['addClass']('ck-suggestion-marker-'+_0xf8dbb2+'-new',_0x450297),this['activeChange']==_0x5cfd26&&_0x2bcdd0['writer']['addClass']('ck-suggestion-marker--active',_0x450297),_0x2bcdd0['writer']['insert'](_0xb35310,_0x450297),_0x2bcdd0['mapper']['bindElementToMarker'](_0x450297,_0x22c6f6['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x1a41b5=>{for(const _0xfab59 of this['editor']['model']['document']['getRootNames']()){const _0x1b2dfc=this['editor']['model']['document']['getRoot'](_0xfab59),_0xf1d6a1=this['editor']['editing']['view']['document']['getRoot'](_0xfab59);if(_0xf1d6a1){const _0x42ce21=_0x1b2dfc['getAttribute']('revisionHistoryAttachChange');if(_0x1a41b5['removeAttribute']('data-change-id',_0xf1d6a1),_0x1a41b5['removeClass']('ck-revision-history-root-add',_0xf1d6a1),_0x1a41b5['removeClass']('ck-revision-history-root-remove',_0xf1d6a1),_0x1a41b5['removeClass']('ck-revision-history-root--active',_0xf1d6a1),_0x42ce21){const _0x188889=this['_getChangeFromId'](_0x42ce21);if(!_0x188889)return null;_0x1a41b5['setAttribute']('data-change-id',_0x42ce21,_0xf1d6a1),_0x1a41b5['addClass']('ck-revision-history-root-'+_0x188889['type'],_0xf1d6a1),this['activeChange']==_0x188889&&_0x1a41b5['addClass']('ck-revision-history-root--active',_0xf1d6a1);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x40229f=>'revision-comment:'+_0x40229f,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x564b14=>'revision-suggestion:'+_0x564b14,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x183556=>({'name':'suggestion:'+_0x183556,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x8d8c14=>{const _0x48b63e=_0x8d8c14['markerName']['split'](':')[0x1];return'insertion'!=_0x48b63e&&'deletion'!=_0x48b63e?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x48b63e]};}}),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',(_0x533a4b,_0x3848a0,_0x3e0557)=>{const _0xf2f312=_0x3e0557['mapper']['markerNameToElements'](_0x3848a0['markerName']);if(_0xf2f312){for(const _0x36683a of _0xf2f312)_0x36683a['is']('uiElement')&&(_0x3e0557['mapper']['unbindElementFromMarkerName'](_0x36683a,_0x3848a0['markerName']),_0x3e0557['writer']['remove'](_0x36683a));}},{'priority':'high'});}['_getChangeFromId'](_0x25f7d5){return this['_changeIdToChange']['get'](_0x25f7d5);}['_getViewForChange'](_0x34d7f4){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new z(this['editor']['locale'],_0x34d7f4),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x575c16,_0x565e09,_0x26a870,_0x432e91)=>{_0x432e91&&this['_balloon']['remove'](_0x432e91),_0x26a870&&(this['_balloon']['add']({'view':_0x26a870,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x5e431a=this['editor']['editing'],_0x1cd233=this['_getChangeFromId'](_0x26a870['changeId']);let _0x582545;if(_0x1cd233['data']['isOnRoot']){const _0x389fd0=_0x5e431a['view']['getDomRoot'](_0x1cd233['rootName']);_0x582545=Array['from'](_0x389fd0['getClientRects']());}else{const _0x269cd0=this['editor']['model']['markers']['get']('revision:'+_0x26a870['changeId']);_0x582545=Array['from'](_0x5e431a['mapper']['markerNameToElements'](_0x269cd0['name']))['map'](_0x282fe7=>_0x5e431a['view']['domConverter']['mapViewToDom'](_0x282fe7))['map'](_0x6a4a98=>Array['from'](_0x6a4a98['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x582545[0x0];return _0x582545['find'](_0x50bb90=>_0x50bb90['top']-0x3<=this['_activeViewTarget']['y']&&_0x50bb90['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x50bb90['left']-0x3<=this['_activeViewTarget']['x']&&_0x50bb90['right']+0x3>=this['_activeViewTarget']['x'])||_0x582545[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x22e9e4,_0x16b7f9,_0x5620d1,_0x33cf45)=>{this['activeView']=_0x5620d1?this['_getViewForChange'](_0x5620d1):null,this['editor']['model']['change'](()=>{const _0x3bfcf9=this['editor']['editing'];_0x33cf45&&(_0x33cf45['data']['isOnRoot']?_0x3bfcf9['view']['change'](_0x1b976a=>{_0x1b976a['removeClass']('ck-revision-history-root--active',_0x3bfcf9['view']['document']['getRoot'](_0x33cf45['rootName']));}):_0x3bfcf9['reconvertMarker']('revision:'+_0x33cf45['id'])),_0x5620d1&&(_0x5620d1['data']['isOnRoot']?_0x3bfcf9['view']['change'](_0x38d7fb=>{_0x38d7fb['addClass']('ck-revision-history-root--active',_0x3bfcf9['view']['document']['getRoot'](_0x5620d1['rootName']));}):_0x3bfcf9['reconvertMarker']('revision:'+_0x5620d1['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x12611e,_0x35d9b7)=>{if(this['activeChange'])return;const _0x9ca967=this['_findChangeIdFromDomTarget'](_0x35d9b7['target']),_0x52abaf=this['_changeIdToChange']['get'](_0x9ca967);_0x52abaf?(this['_activeViewTarget']={'x':_0x35d9b7['domEvent']['x'],'y':_0x35d9b7['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x52abaf)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x175cfc,_0x1ee5a1)=>{const _0xbde770=this['_findChangeIdFromDomTarget'](_0x1ee5a1['target']),_0x10c2c8=this['_changeIdToChange']['get'](_0xbde770);_0x10c2c8?(this['_activeViewTarget']={'x':_0x1ee5a1['domEvent']['x'],'y':_0x1ee5a1['domEvent']['y']},_0x10c2c8===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x10c2c8):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x528d8b){do{const _0x1b6d42=_0x528d8b['getAttribute']('data-change-id');if(_0x1b6d42)return _0x1b6d42;_0x528d8b=_0x528d8b['parent'];}while(_0x528d8b);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x59232b=>{for(const _0x28c556 of this['editor']['model']['markers'])_0x59232b['removeMarker'](_0x28c556);});}}function Q(_0x29c4f5,_0x534f7e){return(_0x3bdb06,_0xdbfdbd,_0x2037c4)=>{if(!_0x2037c4['consumable']['test'](_0xdbfdbd['markerRange'],_0x3bdb06['name']))return;const _0x135e28=_0xdbfdbd['markerRange']['getWalker'](),_0x1e19ba=_0xdbfdbd['markerRange']['start'],_0x1b1c6c=_0x29c4f5['model']['schema'];let _0x3128d6=null,_0x24dbdb=null,_0x36425f=!0x1,_0x1205c8=!0x1;for(const _0x52fdb3 of _0x135e28){const _0x4aa541=_0x52fdb3['item'];_0x36425f=_0x36425f||_0x1b1c6c['isContent'](_0x4aa541);const _0x24dc8f=_0x2037c4['mapper']['toViewElement'](_0x4aa541);if(_0x24dc8f&&_0x24dc8f['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x52fdb3['type']&&(_0x1b1c6c['isBlock'](_0x4aa541)&&!_0x1b1c6c['isLimit'](_0x4aa541)&&(_0x4aa541['nextSibling']||_0x1e19ba['isAtEnd']?_0x3128d6&&_0x3128d6['parent']==_0x4aa541||(_0x3128d6=_0x4aa541,_0x419cc5(_0x52fdb3['previousPosition']),_0x1205c8=!0x0):_0x24dbdb=_0x24dbdb||_0x52fdb3['previousPosition']));}function _0x419cc5(_0x2f8c30){const _0x41cee1=_0x2037c4['mapper']['toViewPosition'](_0x2f8c30),_0x5521f3=_0x2037c4['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x534f7e});_0x2037c4['writer']['insert'](_0x41cee1,_0x5521f3),_0x2037c4['mapper']['bindElementToMarker'](_0x5521f3,_0xdbfdbd['markerName']);}_0x36425f||_0x1205c8||!_0x24dbdb||_0x419cc5(_0x24dbdb);};}class nt extends _0x554035{constructor(_0x3eed24){super(_0x3eed24);const _0x312d54=_0x3eed24['plugins']['get'](u);this['affectsData']=!0x1,this['listenTo'](_0x312d54,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x312d54,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x551603=this['editor'],_0x56f401=_0x551603['plugins']['get'](u),_0x18c466=_0x56f401['isReady']?_0x56f401['diff']['newRevisionId']:null;_0x551603['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x18c466);}['refresh'](){const {isReady:_0x399aab,isEnabled:_0x1001ec,repository:_0x99ac75,diff:_0x40d1f6}=this['editor']['plugins']['get'](u),_0x56e36a=_0x40d1f6&&_0x99ac75['getLaterVisibleRevision'](_0x40d1f6['newRevisionId']);this['isEnabled']=_0x399aab&&_0x1001ec&&Boolean(_0x56e36a);}}class rt extends _0x554035{['_step'];constructor(_0x424f1c,{direction:_0x1fc96c}){super(_0x424f1c);const _0x1abfc4=_0x424f1c['plugins']['get'](u);this['affectsData']=!0x1,this['_step']='forward'===_0x1fc96c?0x1:-0x1,this['listenTo'](_0x1abfc4,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x1abfc4,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x1abfc4,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x5a3a4b=this['editor'],_0x32b2a0=_0x5a3a4b['plugins']['get'](u),{isNavigationMode:_0x4929ba,currentChangeNumber:_0x54a971}=_0x32b2a0;let _0x5862f0;if(_0x32b2a0['activeChange']=_0x4929ba?_0x32b2a0['diff']['changes']['get'](_0x54a971+this['_step']):_0x32b2a0['diff']['changes']['first'],_0x32b2a0['activeChange']['data']['isOnRoot'])_0x5862f0=_0x5a3a4b['editing']['view']['getDomRoot'](_0x32b2a0['activeChange']['rootName']);else{const _0x377885=_0x5a3a4b['model']['markers']['get']('revision:'+_0x32b2a0['activeChange']['id']);_0x5862f0=_0x111bd2(_0x5a3a4b['editing'],_0x377885);}_0x48db3b({'target':_0x5862f0,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x5e5e3f,currentChangeNumber:_0xe2b000,numberOfChanges:_0x159e78,isReady:_0x51c432,isEnabled:_0x2119d7}=this['editor']['plugins']['get'](u);this['isEnabled']=!!(_0x2119d7&&_0x51c432&&_0x159e78)&&(!_0x5e5e3f||(0x1===this['_step']?_0xe2b000<_0x159e78-0x1:_0xe2b000>0x0));}}class Ri extends _0x526abe{constructor(_0x35976d){super(_0x35976d);const _0x3af407=this['bindTemplate'],_0x36c7fa=new _0x3ff6ba(_0x35976d),_0x47551a=new _0x3ff6ba(_0x35976d);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',(_0xf43b26,_0x1104c3)=>_0xf43b26&&_0x1104c3>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x3dac5c,_0x347240,_0xcb427b,_0x3a07ca)=>{if(!_0x3dac5c)return m(_0x35976d,'Loading...');if(!_0xcb427b)return m(_0x35976d,'No\x20changes');const _0xeaa326=m(_0x35976d,'NUMBER_OF_CHANGES',_0xcb427b);return _0x3a07ca?m(_0x35976d,'X_OF_Y_CHANGES',[_0x347240+0x1,_0xcb427b]):_0xeaa326;}),_0x36c7fa['set']({'label':m(_0x35976d,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x3b92ff}),_0x47551a['set']({'label':m(_0x35976d,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x309adf}),_0x36c7fa['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x47551a['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x36c7fa['on']('execute',()=>this['fire']('execute','backward')),_0x47551a['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',_0x3af407['if']('_isStatusLabelVisible','ck-hidden',_0x15b4f0=>!_0x15b4f0)]},'children':[{'text':_0x3af407['to']('isNavigationMode',_0x33ff9d=>_0x33ff9d?m(_0x35976d,'EDIT_X_OF_Y_REVISIONS')+':\x20':m(_0x35976d,'Total')+':\x20')}]},{'text':_0x3af407['to']('_statusText')}]},new _0x1c80e1(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x36c7fa,_0x47551a]}]});}}const ge='ck-editor__editable__loading-overlay';class ji extends _0x1b7918{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x5a1e84=this['editor']['editing']['view'];_0x5a1e84['change'](_0x810c07=>{for(const _0x5bf561 of _0x5a1e84['document']['roots'])_0x810c07['addClass'](ge,_0x5bf561);});}['hide'](){const _0x1499a0=this['editor']['editing']['view'];_0x1499a0['change'](_0x3709fa=>{for(const _0x2c9dc5 of _0x1499a0['document']['roots'])_0x3709fa['removeClass'](ge,_0x2c9dc5);});}}class v extends _0x1b7918{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u,ji];}['init'](){const _0x21a6fb=this['editor'],_0x18738d=_0x21a6fb['plugins']['get'](u),_0x25ead3=_0x21a6fb['plugins']['get'](ji);_0x21a6fb['ui']['componentFactory']['add']('exitToEditing',_0x340474=>{const _0x4fa43d=new _0x3ff6ba(_0x340474);return _0x4fa43d['set']({'label':m(_0x340474,'Back\x20to\x20editing'),'icon':_0x1d2949,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x4fa43d,'execute',()=>{_0x21a6fb['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x4fa43d;}),_0x21a6fb['ui']['componentFactory']['add']('restoreRevision',_0xc74946=>{const _0x4469db=new _0x3ff6ba(_0xc74946);return _0x4469db['set']({'label':m(_0xc74946,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x4469db['bind']('isEnabled')['to'](_0x21a6fb['commands']['get']('restoreRevision')),this['listenTo'](_0x4469db,'execute',()=>_0x21a6fb['execute']('restoreRevision')),_0x4469db;}),_0x21a6fb['ui']['componentFactory']['add']('changesNavigation',_0x2824a7=>{const _0x4ef0ab=new Ri(_0x2824a7),_0x49a7e6=_0x21a6fb['commands']['get']('showPreviousChange'),_0x4496cd=_0x21a6fb['commands']['get']('showNextChange');return _0x4ef0ab['bind']('isBackwardNavigationEnabled')['to'](_0x49a7e6,'isEnabled'),_0x4ef0ab['bind']('isForwardNavigationEnabled')['to'](_0x4496cd,'isEnabled'),_0x4ef0ab['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x18738d),this['listenTo'](_0x4ef0ab,'execute',(_0x29602b,_0x33b33e)=>{_0x21a6fb['execute']('forward'===_0x33b33e?'showNextChange':'showPreviousChange');}),_0x4ef0ab;}),_0x25ead3['show'](),_0x18738d['on']('change:isReady',(_0x420981,_0x1d89c7,_0x1b8f6b)=>{_0x1b8f6b?_0x25ead3['hide']():_0x25ead3['show']();});}}class hi extends et{['_resizeObserver']=null;constructor(_0x1d6b5a,_0x388a22){super(_0x1d6b5a,_0x388a22);const _0x55a253=this['bindTemplate'];this['set']({'label':m(_0x1d6b5a,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=m(_0x1d6b5a,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x55a253['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 _0x344c02=this['fieldView']['element'];this['_tooltipString']=_0x344c02['scrollWidth']>_0x344c02['clientWidth']&&_0x344c02['value']||'';}}class ni extends _0x526abe{constructor(_0x1fe6eb,_0x1bee72,_0x385851){super(_0x1fe6eb);const _0x201ac5=new _0x40cca7();_0x201ac5['set']({'content':_0x211003,'viewBox':'0\x200\x2011\x2010'});const _0x10a424=['ck','ck-revision-history-sidebar__revision-author'];_0x385851&&_0x10a424['push']('ck-revision-history-sidebar__revision-author_creator');const _0x1566e1=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':m(_0x1fe6eb,_0x385851?'Revision\x20creator':'Revision\x20author')},'children':[_0x201ac5,_0x1bee72['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x10a424},'children':_0x1566e1});}}function ai(_0x1a203f,_0x172b27){const _0x2d04fc=_0x1a203f['bindTemplate'],_0x2cd057=_0x1a203f['locale'],_0x1de73e=_0x103105(_0x2cd057);_0x1de73e['panelPosition']='sw';const _0x1c396c=function(_0x200c94,_0x1ea4ae){const _0x12a4ad=function(_0x2b46fe,_0x2334aa){const _0x332d36=_0x2b46fe['locale'],_0x432da6={'Compare\x20against\x20selected':m(_0x332d36,'Compare\x20against\x20selected'),'Name\x20this\x20revision':m(_0x332d36,'Name\x20this\x20revision'),'Restore\x20this\x20revision':m(_0x332d36,'Restore\x20this\x20revision')};return _0x2334aa['map'](_0x680b44=>{const _0x4eb685=_0x432da6[_0x680b44['name']];return _0x4eb685&&_0x4eb685!==_0x680b44['name']&&(_0x680b44['name']=_0x4eb685),_0x680b44;});}(_0x200c94,_0x1ea4ae),_0x5d2ee6=new _0x145165();for(const _0x55c4c0 of _0x12a4ad){const _0x47af1e={'type':'button','model':new to({'label':_0x55c4c0['name'],'class':_0x55c4c0['class'],'withText':!0x0,'role':'menuitem','_action':_0x55c4c0['action']})};_0x47af1e['model']['bind']('isEnabled')['to'](_0x200c94,'isActionsDropdownOpen',_0xc60cba=>'function'!=typeof _0x55c4c0['isEnabled']||(!_0xc60cba||_0x55c4c0['isEnabled'](_0x200c94))),_0x5d2ee6['add'](_0x47af1e);}return _0x5d2ee6;}(_0x1a203f,_0x172b27);return _0x1a203f['bind']('isActionsDropdownOpen')['to'](_0x1de73e,'isOpen'),_0x1de73e['buttonView']['set']({'label':m(_0x2cd057,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0xc39968}),_0x1de73e['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x2d04fc['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x2d04fc['to'](_0x55668f=>_0x55668f['stopPropagation']())}}),_0x1de73e['on']('execute',_0xb61eb0=>{_0x1a203f['isReady']&&'function'==typeof _0xb61eb0['source']['_action']&&_0xb61eb0['source']['_action'](_0x1a203f);}),_0x1c4b56(_0x1de73e,_0x1c396c,{'role':'menu'}),_0x1de73e['listenTo'](_0x1a203f,'change:isActionsDropdownOpen',(_0x156452,_0x3ab52f,_0x1ec57f)=>{if(_0x1ec57f)for(const _0x244ecb of _0x1de73e['listView']['items']){const _0x1cff52=_0x244ecb['children']['first'],_0x33fae7=_0x172b27['find'](_0x563dd9=>_0x563dd9['action']===_0x1cff52['_action'])['isVisible'];_0x244ecb['isVisible']=void 0x0===_0x33fae7||_0x33fae7(_0x1a203f);}}),_0x1de73e;}class _i extends/* #__PURE__ -- @preserve */
27
+ _0x1f577a(_0x526abe){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x221424,_0x2ed4f1,_0x41c5dc,_0x1d1dc2){super(_0x221424);const _0x34b8d9=this['bindTemplate'],_0x4247fa=function(_0x404a30,_0x4fab01){const _0x1fa355=Array['from'](_0x4fab01['authors'])['filter'](_0x2df720=>_0x2df720!=_0x4fab01['creator']);return _0x4fab01['creator']&&_0x1fa355['unshift'](_0x4fab01['creator']),_0x1fa355['map'](_0x347c11=>new ni(_0x404a30,_0x347c11,_0x347c11==_0x4fab01['creator']));}(_0x221424,_0x2ed4f1);this['id']=_0x2ed4f1['id'],this['_revision']=_0x2ed4f1,this['_requireRevisionName']=_0x1d1dc2,this['bind']('name','createdAt')['to'](_0x2ed4f1),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x40fd3c=>{return _0x38ced5=_0x221424['uiLanguage'],(_0x445ac0=_0x40fd3c)['toLocaleDateString'](_0x38ced5,{'month':'long','day':'numeric'})+',\x20'+_0x445ac0['toLocaleTimeString'](_0x38ced5,{'hour':'numeric','minute':'numeric'});var _0x38ced5,_0x445ac0;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new hi(_0x221424,ti),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x2b7c1b=>_0x2b7c1b||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x1183ec,_0x58da6a)=>_0x1183ec&&_0x58da6a),this['revisionActionsView']=_0x41c5dc&&_0x41c5dc['length']?ai(this,_0x41c5dc):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x34b8d9['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x34b8d9['if']('isEnabled','ck-disabled',_0x161800=>!_0x161800),_0x34b8d9['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x34b8d9['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x34b8d9['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':_0x34b8d9['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':_0x4247fa}]},this['revisionActionsView']],'on':{'click':_0x34b8d9['to'](_0x56399a=>{_0x56399a['srcElement']['closest']('.ck-confirm-view')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x3a047f=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x3a047f,'change',()=>{this['_requireRevisionName']&&!_0x3a047f['value']||this['fire']('setName',{'id':this['id'],'name':_0x3a047f['value']}),_0x3a047f['value']||(_0x3a047f['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(_0x2f9d24,_0x53dae8){const _0x1b7295=_0x1e540a['fromJSDate'](_0x2f9d24)['setLocale'](_0x53dae8),_0x4495f6=_0x1e540a['local'](),_0x16a6e7=_0x4495f6['minus']({'days':0x1})['startOf']('day');let _0xce5d34,_0x5c275e;return _0x1b7295['hasSame'](_0x4495f6,'day')?(_0xce5d34=_0x1b7295['startOf']('day')['toJSDate'](),_0x5c275e=_0x1b7295['toRelativeCalendar']()):_0x1b7295['hasSame'](_0x16a6e7,'day')?(_0xce5d34=_0x16a6e7['toJSDate'](),_0x5c275e=_0x1b7295['toRelativeCalendar']()):_0x1b7295['hasSame'](_0x4495f6,'week')?(_0xce5d34=_0x1b7295['startOf']('week')['toJSDate'](),_0x5c275e=_0x1b7295['weekdayLong']||''):_0x1b7295['hasSame'](_0x4495f6,'year')?(_0xce5d34=_0x1b7295['startOf']('month')['toJSDate'](),_0x5c275e=_0x1b7295['monthLong']||''):(_0xce5d34=_0x1b7295['startOf']('year')['toJSDate'](),_0x5c275e=String(_0x1b7295['year'])),{'startDate':_0xce5d34,'localizedPeriodName':_0x5c275e};}class bi extends _0x526abe{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x2f12cc,_0x53b792,_0x5d3c98,_0x4d0678){super(_0x2f12cc);const _0x552f9a=li(_0x53b792,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x53b792,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x5d3c98,this['_requireRevisionName']=_0x4d0678,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':_0x552f9a}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x182859){const _0x43f958=new _i(this['locale'],_0x182859,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x43f958);}['removeRevision'](_0x290d63){const _0x29fda2=this['revisionViews']['find'](_0x2027d8=>_0x2027d8['id']===_0x290d63['id']);this['revisionViews']['remove'](_0x29fda2);}}class fi extends _0x526abe{constructor(_0x39434f){super(_0x39434f);const _0x563b52=new _0x40cca7();_0x563b52['content']=_0x2ce2b3,this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x563b52,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[m(_0x39434f,'Revision\x20history')]}]});}}class di extends _0x526abe{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0xfc68e4,_0x2394b9,_0x1726e9,_0x531931){super(_0xfc68e4);const _0x275a9c=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x2394b9,this['_revisionActions']=_0x1726e9,this['_requireRevisionName']=_0x531931,this['on']('select',(_0x555f13,_0x2a3254)=>{this['fire']('revisionSelected',_0x2a3254);}),this['on']('setName',(_0x1289b5,_0x517f61)=>{this['fire']('revisionSetName',_0x517f61);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new fi(_0xfc68e4),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x275a9c['if']('isEnabled','ck-disabled',_0x45a7e3=>!_0x45a7e3)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x2cce9c of this['_revisions'])this['_addRevision'](_0x2cce9c);this['_revisions']['on']('add',(_0x3a6842,_0x59bc78)=>{this['_addRevision'](_0x59bc78);}),this['_revisions']['on']('remove',(_0x48f4e8,_0x43d3c0)=>{this['_removeRevision'](_0x43d3c0);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x1fa7e2=>_0x1fa7e2['revisionViews']['map'](_0x1dc846=>_0x1dc846))['flat']();}['selectRevision'](_0x34e276){for(const _0x522695 of this['revisionViews'])_0x34e276&&_0x34e276['id']===_0x522695['id']?_0x522695['select']():_0x522695['deselect']();}['highlightRevisions'](_0x3f7f68){for(const _0x13d158 of this['revisionViews'])_0x3f7f68['some'](({id:_0x18fd00})=>_0x18fd00===_0x13d158['id'])?_0x13d158['highlight']():_0x13d158['unhighlight']();}['_addRevision'](_0x2b5f14){const _0x15759c=li(_0x2b5f14['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x133f1e=this['timePeriodViews']['get'](0x0);_0x133f1e&&_0x133f1e['startDate']['getTime']()===_0x15759c['getTime']()||(_0x133f1e=new bi(this['locale'],_0x15759c,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x133f1e)),_0x133f1e['addRevision'](_0x2b5f14);}['_removeRevision'](_0x1e47b2){const _0x222e1c=li(_0x1e47b2['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x222e1c)['removeRevision'](_0x1e47b2);}['_getTimePeriodViewByStartDate'](_0x2d5810){return this['timePeriodViews']['find'](_0x156e45=>_0x156e45['startDate']['getTime']()===_0x2d5810['getTime']());}}class d extends _0x1b7918{['_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[u];}constructor(_0x2267a3){super(_0x2267a3),this['_revisionViewer']=_0x2267a3['plugins']['get'](u),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x168338=this['_revisionsRepository']['_revisions'],_0x542329=this['_createRevisionActions'](),_0x5d4d33=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new di(this['editor']['locale'],_0x168338,_0x542329,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',(_0x7bc7df,_0x1da32e)=>{_0x1da32e['revisionViews']['on']('add',(_0x30c471,_0x1c4069)=>{_0x1c4069['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)),_0x5d4d33['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x1ccf28=this['_revisionsRepository']['getRevision'](0x0);if(_0x1ccf28){const _0x44c85c=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x1ccf28['id']);this['_revisionViewer']['compare'](_0x1ccf28,_0x44c85c);}}['_handleRevisionSelected'](_0x2b6440,_0x109022){const _0x36851d=this['_revisionsRepository']['getRevision'](_0x109022['id']),_0x474575=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x36851d['id']);this['_revisionViewer']['compare'](_0x36851d,_0x474575);}['_handleRevisionSetName'](_0x144eb4,_0x324fa8){this['_revisionsRepository']['getRevision'](_0x324fa8['id'])['setName'](_0x324fa8['name']);}['_handleDiffChange'](_0x3da5b4,_0x12f878,_0x334a98){const _0x12ea71=this['_revisionsRepository']['getRevisionsInDiff'](_0x334a98);_0x12ea71['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x12ea71),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x12ea71[0x0]));}['_createRevisionActions'](){const _0x3e9f5a=this['editor'],_0x423ac3=d['availableRevisionActions'],_0x3ed7f9=_0x3e9f5a['config']['get']('revisionHistory.revisionActions')||d['defaultRevisionActions'];if(_0x3ed7f9['length'])return _0x3ed7f9['map'](_0x3b34cd=>{const _0x26f724='string'==typeof _0x3b34cd?Object['assign']({},_0x423ac3[_0x3b34cd]):_0x3b34cd;return _0x26f724['action']=_0x26f724['action']['bind'](this,_0x3e9f5a),_0x26f724['isVisible']&&(_0x26f724['isVisible']=_0x26f724['isVisible']['bind'](this,_0x3e9f5a)),_0x26f724;});}}function at(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x255071},_0x1ae674)=>{const _0x368d20=_0x255071['get'](u),_0x13fa56=_0x368d20['repository'];let _0x5c9aee=_0x368d20['diff']['newRevisionId'],_0x4c6260=_0x1ae674['id'];_0x13fa56['getIndex'](_0x5c9aee)>_0x13fa56['getIndex'](_0x4c6260)&&([_0x5c9aee,_0x4c6260]=[_0x4c6260,_0x5c9aee]),_0x368d20['compare'](_0x5c9aee,_0x4c6260);},'isVisible':({plugins:_0x4c41ed},_0x15069a)=>{const _0x272c57=_0x4c41ed['get'](u);return!(_0x272c57['repository']['getRevisionsInDiff'](_0x272c57['diff'])['length']>0x2)&&!_0x15069a['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x77e712,{id:_0x48e0e1})=>{_0x77e712['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x48e0e1);},'isVisible':({plugins:_0x529462},_0x45ca07)=>!!_0x529462['get'](u)['repository']['getLaterVisibleRevision'](_0x45ca07['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x4a2888},{id:_0x53f0f4,revisionNameView:_0x1b5a00})=>{const _0x5436b2=_0x4a2888['get'](u),_0x4bc70f=_0x5436b2['repository']['getEarlierVisibleRevision'](_0x53f0f4);_0x5436b2['compare'](_0x53f0f4,_0x4bc70f),_0x1b5a00['focus'](),_0x1b5a00['fieldView']['select']();}}};}class Z extends tt{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x8ecdf2,_0x44732b){super(_0x8ecdf2),this['_view']=_0x44732b,this['_toolbarConfig']=st(_0x8ecdf2['config']['get']('toolbar')),this['_elementReplacer']=new it();}get['element'](){return this['view']['element'];}['init'](_0x40ba78){const _0x5c7713=this['editor'],_0xe396d3=this['view'],_0x5dc76c=_0x5c7713['editing']['view'],_0x299ba9=_0xe396d3['editable'],_0x31599d=_0x5dc76c['document']['getRoot']();_0x299ba9['name']=_0x31599d['rootName'],_0xe396d3['render']();const _0x5df5ae=_0x299ba9['element'];this['setEditableElement'](_0x299ba9['name'],_0x5df5ae),_0xe396d3['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x5dc76c['attachDomRoot'](_0x5df5ae),this['_elementReplacer']['replace'](_0x40ba78,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x1bd4cd=this['view'],_0x31c0d8=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x31c0d8['detachDomRoot'](_0x1bd4cd['editable']['name']),_0x1bd4cd['destroy']();}['_initToolbar'](){const _0xfb7ad0=this['view'];_0xfb7ad0['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0xfb7ad0['stickyPanel']['limiterElement']=_0xfb7ad0['element'],_0xfb7ad0['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x20cf39})=>_0x20cf39),_0xfb7ad0['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0xfb7ad0['toolbar']);}}class ii extends _0x20cce1{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x4fc2e0,_0x4c47eb,_0xcbe9b={}){super(_0x4fc2e0),this['stickyPanel']=new _0x82d6c7(_0x4fc2e0),this['toolbar']=new _0x392eb7(_0x4fc2e0,{'shouldGroupWhenFull':_0xcbe9b['shouldToolbarGroupWhenFull']}),this['_editable']=new te(_0x4fc2e0,_0x4c47eb);}['render'](){super['render'](),this['stickyPanel']['content']['add'](this['toolbar']),this['top']['add'](this['stickyPanel']),this['main']['add'](this['editable']);}}class f extends/* #__PURE__ -- @preserve */
30
- _0x28570d(_0x1dbeab){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x1c2cf6,_0x627cc3){super(_0x627cc3),this['sourceElement']=_0x1c2cf6,this['model']['document']['createRoot']();const _0x562f10=new ii(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new Z(this,_0x562f10);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x5d29c2,_0x241194){const _0x4a8436=new this(_0x5d29c2,_0x241194);return await _0x4a8436['initPlugins'](),await _0x4a8436['ui']['init'](_0x5d29c2),await _0x4a8436['data']['init'](_0x4a8436['config']['get']('initialData')||''),_0x4a8436['fire']('ready'),_0x4a8436;}}const p=['RevisionHistoryUI','RestrictedEditingMode','AIChat','AIReviewMode','AIBalloon','AIQuickActions','AIActions'];class ht extends _0xbe21c4{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x5148ce){function _0x36d76a(_0x50c02f){return _0x50c02f['map'](_0x53b80b=>String['fromCharCode'](_0x53b80b))['join']('');}super(_0x5148ce),this['result']='end',_0x5148ce[_0x36d76a([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x36d76a([0x76,0x69,0x65,0x77])][_0x36d76a([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x36d76a([0x61,0x75,0x74,0x6f]),_0x5148ce[_0x36d76a([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x36d76a([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x36d76a([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x36d76a([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x36d76a([0x6f,0x6b])});}}class ct extends _0xbe21c4{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h,l];}constructor(_0x13869e){if(super(_0x13869e),!this['editor']['config']['get']('revisionHistory'))throw new _0x1d6810('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0xa1b671=>this['_showRevisionViewer']({..._0xa1b671,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x2b8422=>this['_closeRevisionViewer'](_0x2b8422)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x204016=>this['_restoreRevision'](_0x204016)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x52c9a9){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x52c9a9;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x379ad1){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x379ad1);}['getRevision'](_0xa2ebb3){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0xa2ebb3);}['getRevisions'](_0x39eafb){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x39eafb||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x484705=this['editor'],_0x21d22c=_0x45ed39(_0x484705,p),_0x559d7f=_0x484705['plugins']['get']('RevisionTracker'),_0x5f4089=_0x484705['plugins']['get']('Users')['users'];return _0x21d22c['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x21d22c['lazyRoots'],(_0x21d22c['plugins']['push'](ht,u,v,class extends _0xbe21c4{static get['requires'](){return[u,'Users'];}['init'](){const _0x35816d=this['editor']['plugins']['get']('Users');for(const _0xf53218 of _0x5f4089)_0xf53218['isAnonymous']||_0x35816d['getUser'](_0xf53218['id'])||_0x35816d['addUser'](_0xf53218);const _0xc84228=_0x559d7f['repository']['getRevisions']();let _0x46bb10=null;const _0x5ad9f3=this['editor']['plugins']['get']('RevisionViewer');_0x5ad9f3['adapter']=_0x559d7f['adapter'],_0x5ad9f3['bind']('isEnabled')['to'](_0x559d7f),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x484705,'isReadOnly',_0x272815=>!_0x272815);for(const _0x4f97a5 of _0xc84228){const _0x227662=null===_0x4f97a5['creator'];if(_0x227662&&_0x4f97a5['toVersion']===_0x4f97a5['fromVersion'])continue;const _0x589586=_0x4f97a5['toJSON']();_0x5ad9f3['addRevisionData'](_0x589586,(_0x193a44,_0x10f71a,_0x1c637d)=>{if(_0x227662){if(_0x46bb10)_0x46bb10['_update'](_0x193a44,_0x10f71a);else{if(!_0x10f71a){const _0x2aaef3=_0x1c637d['toJSON']();_0x2aaef3['id']=_0x532896(),_0x559d7f['saveRevision'](_0x2aaef3,_0x1c637d['toVersion'])['then'](_0x31a9a2=>{_0x46bb10=_0x31a9a2;});}}}else _0x4f97a5['_update'](_0x193a44,_0x10f71a);});}}},d),_0x21d22c);}['_enhanceShowRevisionViewerCallback'](){const _0x2f6936=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x38da09=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x459461=this['editor']['plugins']['get']('Autosave');await _0x459461['save']();}else await _0x38da09['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x48bcfa=this['editor']['plugins']['get']('Dialog');_0x48bcfa['isOpen']&&_0x48bcfa['hide']();}if(this['editor']['plugins']['has']('AITabs')){const _0x5d2367=this['editor']['plugins']['get']('AITabs')['view']['panelViews'];for(const _0x3dde0e of _0x5d2367)_0x3dde0e['class']=_0x3dde0e['class']?_0x3dde0e['class']+'\x20ck-tab-panel_disabled':'ck-tab-panel_disabled';if(this['editor']['plugins']['has']('AIChat')){const _0x424946=document['querySelector']('.ck-ai-chat__prompt-input\x20.ck-textarea');_0x424946&&_0x424946['setAttribute']('tabindex','-1');}if(this['editor']['plugins']['has']('AIChatHistory')){const _0x3a19ab=document['querySelector']('.ck-ai-chat-history\x20.ck-input');_0x3a19ab&&_0x3a19ab['setAttribute']('tabindex','-1');}}const _0x4a710f=this['_getRevisionViewerEditorConfig']();return _0x2f6936(_0x4a710f)['then'](_0x4d2c7a=>{return(this['_viewerEditor']=_0x4d2c7a,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'),_0x4d2c7a);})['catch'](_0x3c37e8=>(console['error'](_0x3c37e8),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x35a9df=this['editor']['config']['get']('revisionHistory')['closeRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.closeRevisionViewerCallback',()=>{if(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['editor']['plugins']['has']('AITabs')){const _0x1d2171=this['editor']['plugins']['get']('AITabs')['view']['panelViews'];for(const _0x1b22ee of _0x1d2171)_0x1b22ee['class']='ck-tab-panel_disabled'===_0x1b22ee['class']?'':_0x1b22ee['class']['replace']('\x20ck-tab-panel_disabled','');if(this['editor']['plugins']['has']('AIChat')){const _0x90fd37=document['querySelector']('.ck-ai-chat__prompt-input\x20.ck-textarea');_0x90fd37&&_0x90fd37['removeAttribute']('tabindex');}if(this['editor']['plugins']['has']('AIChatHistory')){const _0x22f6ba=document['querySelector']('.ck-ai-chat-history\x20.ck-input');_0x22f6ba&&_0x22f6ba['removeAttribute']('tabindex');}}return this['_viewerEditor']['plugins']['get']('RevisionViewer')['_cleanUp'](),_0x35a9df(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x3cc76d=this['editor']['plugins']['get']('Annotations');_0x3cc76d['refreshVisibility'](),_0x3cc76d['refreshPositioning']();}});});}['_showRevisionViewer'](_0x12dbd7){const _0x1ec0a5=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x23c032=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x1a0798=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return f['create'](_0x1a0798,_0x12dbd7)['then'](_0x3aac38=>(_0x23c032['style']['display']='block',_0x1ec0a5['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x3aac38));}['_closeRevisionViewer'](_0xfd6539){const _0x175ce3=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x175ce3['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0xfd6539['destroy']();}async['_restoreRevision'](_0x2e4545){const _0x237011=this['editor'],_0x3a0657=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x2e460b=_0x237011['plugins']['get']('RevisionTracker'),_0x11fca4=_0x237011['plugins']['get']('RevisionHistoryUtils'),_0x45c50f=_0x3a0657['repository']['getRevision'](_0x2e4545);let _0x58a0b2,_0x624875,_0x5f455a;try{await _0x11fca4['loadRevisionData'](_0x45c50f,this['adapter']),_0x58a0b2=_0x11fca4['getRevisionDocumentData'](_0x45c50f),_0x624875=_0x11fca4['getRevisionRootsAttributes'](_0x45c50f);}catch(_0x3a663){return void console['error'](_0x3a663);}_0x237011['model']['change'](_0x1e8174=>{for(const _0x1d49ea of Array['from'](_0x237011['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x1e8174['removeMarker'](_0x1d49ea);}),_0x3a0657['isReady']=!0x1,_0x237011['model']['enqueueChange'](_0x957351=>{_0x957351['setSelection'](null),_0x957351['removeSelectionAttribute'](_0x237011['model']['document']['selection']['getAttributeKeys']());const _0xeece7c=Object['keys'](_0x58a0b2);for(const _0x1c1c51 of _0x237011['model']['document']['roots'])'$graveyard'!=_0x1c1c51['rootName']&&_0x1c1c51['isAttached']()&&!_0xeece7c['includes'](_0x1c1c51['rootName'])&&_0x957351['detachRoot'](_0x1c1c51);for(const _0x202c96 of _0xeece7c){let _0x20161a=_0x237011['model']['document']['getRoot'](_0x202c96);_0x20161a&&_0x20161a['isAttached']()||(_0x20161a=_0x957351['addRoot'](_0x202c96));const _0x2d1e97=_0x624875[_0x202c96],_0x331296=Object['keys'](_0x2d1e97),_0x3d3300=_0x58a0b2[_0x202c96];for(const _0x443159 of _0x20161a['getAttributeKeys']())_0x331296['includes'](_0x443159)||_0x957351['removeAttribute'](_0x443159,_0x20161a);for(const _0x569b16 of _0x331296)_0x957351['setAttribute'](_0x569b16,_0x624875[_0x202c96][_0x569b16],_0x20161a);_0x957351['remove'](_0x957351['createRangeIn'](_0x20161a)),_0x957351['insert'](_0x237011['data']['parse'](_0x3d3300,_0x20161a),_0x20161a,0x0);}});const _0x3ceeb8=m(_0x237011['locale'],'Restored');if(_0x45c50f['name'])_0x5f455a=-0x1==_0x45c50f['name']['indexOf'](_0x3ceeb8)?_0x3ceeb8+':\x20'+_0x45c50f['name']:_0x45c50f['name'];else _0x5f455a=_0x3ceeb8+':\x20'+(_0x45c50f['createdAt']['toLocaleDateString'](_0x237011['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x45c50f['createdAt']['toLocaleTimeString'](_0x237011['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x2e460b['saveRevision']({'name':_0x5f455a}),_0x3a0657['isReady']=!0x0,_0x237011['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{nt as RestoreRevisionCommand,I as Revision,ct as RevisionHistory,l as RevisionHistoryUI,$ as RevisionHistoryUtils,h as RevisionTracker,u as RevisionViewer,f as RevisionViewerEditor,ht as RevisionViewerIntegration,ji as RevisionViewerLoadingOverlay,v as RevisionViewerUI,S as RevisionsRepository,d as RevisionsSidebar,rt as ShowChangeCommand};
29
+ at();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u];}constructor(_0x58294d){super(_0x58294d),this['_revisionViewer']=_0x58294d['plugins']['get'](u),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0xdcbf3f=this['_revisionsRepository']['_revisions'],_0x3c5fad=this['_createRevisionActions'](),_0x1ec62f=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new di(this['editor']['locale'],_0xdcbf3f,_0x3c5fad,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',(_0xfdb1b5,_0x1f8066)=>{_0x1f8066['revisionViews']['on']('add',(_0x27a23c,_0x1fc1e4)=>{_0x1fc1e4['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)),_0x1ec62f['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x43f9d9=this['_revisionsRepository']['getRevision'](0x0);if(_0x43f9d9){const _0x368eeb=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x43f9d9['id']);this['_revisionViewer']['compare'](_0x43f9d9,_0x368eeb);}}['_handleRevisionSelected'](_0x8bc28b,_0x1d6c35){const _0xa0ace2=this['_revisionsRepository']['getRevision'](_0x1d6c35['id']),_0x55f309=this['_revisionsRepository']['getEarlierVisibleRevision'](_0xa0ace2['id']);this['_revisionViewer']['compare'](_0xa0ace2,_0x55f309);}['_handleRevisionSetName'](_0x39a909,_0x1a7a85){this['_revisionsRepository']['getRevision'](_0x1a7a85['id'])['setName'](_0x1a7a85['name']);}['_handleDiffChange'](_0x52515c,_0x3c001c,_0xd34814){const _0x44f4fc=this['_revisionsRepository']['getRevisionsInDiff'](_0xd34814);_0x44f4fc['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x44f4fc),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x44f4fc[0x0]));}['_createRevisionActions'](){const _0x563e34=this['editor'],_0x435de2=d['availableRevisionActions'],_0x5f53c2=_0x563e34['config']['get']('revisionHistory.revisionActions')||d['defaultRevisionActions'];if(_0x5f53c2['length'])return _0x5f53c2['map'](_0xb09ddd=>{const _0x58b7ff='string'==typeof _0xb09ddd?Object['assign']({},_0x435de2[_0xb09ddd]):_0xb09ddd;return _0x58b7ff['action']=_0x58b7ff['action']['bind'](this,_0x563e34),_0x58b7ff['isVisible']&&(_0x58b7ff['isVisible']=_0x58b7ff['isVisible']['bind'](this,_0x563e34)),_0x58b7ff;});}}function at(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x6a44ae},_0x16ff62)=>{const _0x4dccf5=_0x6a44ae['get'](u),_0x5142ed=_0x4dccf5['repository'];let _0x325813=_0x4dccf5['diff']['newRevisionId'],_0x57dd61=_0x16ff62['id'];_0x5142ed['getIndex'](_0x325813)>_0x5142ed['getIndex'](_0x57dd61)&&([_0x325813,_0x57dd61]=[_0x57dd61,_0x325813]),_0x4dccf5['compare'](_0x325813,_0x57dd61);},'isVisible':({plugins:_0x5e9947},_0x544e98)=>{const _0x54768d=_0x5e9947['get'](u);return!(_0x54768d['repository']['getRevisionsInDiff'](_0x54768d['diff'])['length']>0x2)&&!_0x544e98['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x40b353,{id:_0x58860a})=>{_0x40b353['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x58860a);},'isVisible':({plugins:_0x551d05},_0x248640)=>!!_0x551d05['get'](u)['repository']['getLaterVisibleRevision'](_0x248640['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x48a5fa},{id:_0x3e688e,revisionNameView:_0x1fa001})=>{const _0x3d3cd2=_0x48a5fa['get'](u),_0x1763fb=_0x3d3cd2['repository']['getEarlierVisibleRevision'](_0x3e688e);_0x3d3cd2['compare'](_0x3e688e,_0x1763fb),_0x1fa001['focus'](),_0x1fa001['fieldView']['select']();}}};}class Z extends tt{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0xcde690,_0xb79832){super(_0xcde690),this['_view']=_0xb79832,this['_toolbarConfig']=st(_0xcde690['config']['get']('toolbar')),this['_elementReplacer']=new it();}get['element'](){return this['view']['element'];}['init'](_0x50f07c){const _0x928a16=this['editor'],_0x334f2c=this['view'],_0x363920=_0x928a16['editing']['view'],_0x361fa6=_0x334f2c['editable'],_0x154b5a=_0x363920['document']['getRoot']();_0x361fa6['name']=_0x154b5a['rootName'],_0x334f2c['render']();const _0x35284c=_0x361fa6['element'];this['setEditableElement'](_0x361fa6['name'],_0x35284c),_0x334f2c['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x363920['attachDomRoot'](_0x35284c),this['_elementReplacer']['replace'](_0x50f07c,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x13dc71=this['view'],_0x489469=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x489469['detachDomRoot'](_0x13dc71['editable']['name']),_0x13dc71['destroy']();}['_initToolbar'](){const _0x2487df=this['view'];_0x2487df['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x2487df['stickyPanel']['limiterElement']=_0x2487df['element'],_0x2487df['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x16f1aa})=>_0x16f1aa),_0x2487df['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x2487df['toolbar']);}}class ii extends _0x37d6bb{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x43f18b,_0x17bef8,_0x10cda0={}){super(_0x43f18b),this['stickyPanel']=new _0x5c2a56(_0x43f18b),this['toolbar']=new _0x12a455(_0x43f18b,{'shouldGroupWhenFull':_0x10cda0['shouldToolbarGroupWhenFull']}),this['_editable']=new te(_0x43f18b,_0x17bef8);}['render'](){super['render'](),this['stickyPanel']['content']['add'](this['toolbar']),this['top']['add'](this['stickyPanel']),this['main']['add'](this['editable']);}}class f extends/* #__PURE__ -- @preserve */
30
+ _0xaa91f4(_0x245eaf){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x47489e,_0x21f4a4){super(_0x21f4a4),this['sourceElement']=_0x47489e,this['model']['document']['createRoot']();const _0x3a30a6=new ii(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new Z(this,_0x3a30a6);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x41f7ac,_0x2f2209){const _0x5d8e11=new this(_0x41f7ac,_0x2f2209);return await _0x5d8e11['initPlugins'](),await _0x5d8e11['ui']['init'](_0x41f7ac),await _0x5d8e11['data']['init'](_0x5d8e11['config']['get']('initialData')||''),_0x5d8e11['fire']('ready'),_0x5d8e11;}}const p=['RevisionHistoryUI','RestrictedEditingMode','AIChat','AIReviewMode','AIBalloon','AIQuickActions','AIActions'];class ht extends _0x1b7918{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x194c34){function _0x2e563a(_0x53d82e){return _0x53d82e['map'](_0x5992f9=>String['fromCharCode'](_0x5992f9))['join']('');}super(_0x194c34),this['result']='end',_0x194c34[_0x2e563a([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x2e563a([0x76,0x69,0x65,0x77])][_0x2e563a([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x2e563a([0x61,0x75,0x74,0x6f]),_0x194c34[_0x2e563a([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x2e563a([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x2e563a([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x2e563a([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x2e563a([0x6f,0x6b])});}}class ct extends _0x1b7918{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h,l];}constructor(_0x45c0b0){if(super(_0x45c0b0),!this['editor']['config']['get']('revisionHistory'))throw new _0x3ff139('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x5d1fe9=>this['_showRevisionViewer']({..._0x5d1fe9,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0xe56afb=>this['_closeRevisionViewer'](_0xe56afb)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x39e48e=>this['_restoreRevision'](_0x39e48e)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x5e802d){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x5e802d;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x18a041){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x18a041);}['getRevision'](_0xef8168){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0xef8168);}['getRevisions'](_0x355741){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x355741||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x53b599=this['editor'],_0x2d2a0d=_0x5b8a19(_0x53b599,p),_0x2e9452=_0x53b599['plugins']['get']('RevisionTracker'),_0x202b8f=_0x53b599['plugins']['get']('Users')['users'];return _0x2d2a0d['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x2d2a0d['lazyRoots'],(_0x2d2a0d['plugins']['push'](ht,u,v,class extends _0x1b7918{static get['requires'](){return[u,'Users'];}['init'](){const _0x4252f1=this['editor']['plugins']['get']('Users');for(const _0x4d46fc of _0x202b8f)_0x4d46fc['isAnonymous']||_0x4252f1['getUser'](_0x4d46fc['id'])||_0x4252f1['addUser'](_0x4d46fc);const _0x527576=_0x2e9452['repository']['getRevisions']();let _0x4863f1=null;const _0x540679=this['editor']['plugins']['get']('RevisionViewer');_0x540679['adapter']=_0x2e9452['adapter'],_0x540679['bind']('isEnabled')['to'](_0x2e9452),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x53b599,'isReadOnly',_0x129126=>!_0x129126);for(const _0x115456 of _0x527576){const _0x764097=null===_0x115456['creator'];if(_0x764097&&_0x115456['toVersion']===_0x115456['fromVersion'])continue;const _0x559f4b=_0x115456['toJSON']();_0x540679['addRevisionData'](_0x559f4b,(_0x31e001,_0x435864,_0x459659)=>{if(_0x764097){if(_0x4863f1)_0x4863f1['_update'](_0x31e001,_0x435864);else{if(!_0x435864){const _0x80587e=_0x459659['toJSON']();_0x80587e['id']=_0x49424b(),_0x2e9452['saveRevision'](_0x80587e,_0x459659['toVersion'])['then'](_0x5f1782=>{_0x4863f1=_0x5f1782;});}}}else _0x115456['_update'](_0x31e001,_0x435864);});}}},d),_0x2d2a0d);}['_enhanceShowRevisionViewerCallback'](){const _0x422008=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x4c7ff0=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0xd2ce74=this['editor']['plugins']['get']('Autosave');await _0xd2ce74['save']();}else await _0x4c7ff0['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x66289d=this['editor']['plugins']['get']('Dialog');_0x66289d['isOpen']&&_0x66289d['hide']();}if(this['editor']['plugins']['has']('AITabs')){const _0x1f645b=this['editor']['plugins']['get']('AITabs')['view']['panelViews'];for(const _0x49906d of _0x1f645b)_0x49906d['class']=_0x49906d['class']?_0x49906d['class']+'\x20ck-tab-panel_disabled':'ck-tab-panel_disabled';if(this['editor']['plugins']['has']('AIChat')){const _0x40c9c2=document['querySelector']('.ck-ai-chat__prompt-input\x20.ck-textarea');_0x40c9c2&&_0x40c9c2['setAttribute']('tabindex','-1');}if(this['editor']['plugins']['has']('AIChatHistory')){const _0x49d563=document['querySelector']('.ck-ai-chat-history\x20.ck-input');_0x49d563&&_0x49d563['setAttribute']('tabindex','-1');}}const _0x3605ea=this['_getRevisionViewerEditorConfig']();return _0x422008(_0x3605ea)['then'](_0x1d3fb9=>{return(this['_viewerEditor']=_0x1d3fb9,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'),_0x1d3fb9);})['catch'](_0x439918=>(console['error'](_0x439918),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x79a30c=this['editor']['config']['get']('revisionHistory')['closeRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.closeRevisionViewerCallback',()=>{if(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['editor']['plugins']['has']('AITabs')){const _0x180408=this['editor']['plugins']['get']('AITabs')['view']['panelViews'];for(const _0x329a74 of _0x180408)_0x329a74['class']='ck-tab-panel_disabled'===_0x329a74['class']?'':_0x329a74['class']['replace']('\x20ck-tab-panel_disabled','');if(this['editor']['plugins']['has']('AIChat')){const _0x3481df=document['querySelector']('.ck-ai-chat__prompt-input\x20.ck-textarea');_0x3481df&&_0x3481df['removeAttribute']('tabindex');}if(this['editor']['plugins']['has']('AIChatHistory')){const _0x173f05=document['querySelector']('.ck-ai-chat-history\x20.ck-input');_0x173f05&&_0x173f05['removeAttribute']('tabindex');}}return this['_viewerEditor']['plugins']['get']('RevisionViewer')['_cleanUp'](),_0x79a30c(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x35892d=this['editor']['plugins']['get']('Annotations');_0x35892d['refreshVisibility'](),_0x35892d['refreshPositioning']();}});});}['_showRevisionViewer'](_0x106d70){const _0x4368da=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x64e240=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x38658c=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return f['create'](_0x38658c,_0x106d70)['then'](_0x49b219=>(_0x64e240['style']['display']='block',_0x4368da['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x49b219));}['_closeRevisionViewer'](_0x319651){const _0x4c32f6=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x4c32f6['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x319651['destroy']();}async['_restoreRevision'](_0x33e4f5){const _0x2dffb2=this['editor'],_0x53c488=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x39d99b=_0x2dffb2['plugins']['get']('RevisionTracker'),_0x3b08af=_0x2dffb2['plugins']['get']('RevisionHistoryUtils'),_0x4fe522=_0x53c488['repository']['getRevision'](_0x33e4f5);let _0x33a9f3,_0x22603f,_0x42b817;try{await _0x3b08af['loadRevisionData'](_0x4fe522,this['adapter']),_0x33a9f3=_0x3b08af['getRevisionDocumentData'](_0x4fe522),_0x22603f=_0x3b08af['getRevisionRootsAttributes'](_0x4fe522);}catch(_0x404e22){return void console['error'](_0x404e22);}_0x2dffb2['model']['change'](_0x192ab5=>{for(const _0x574efa of Array['from'](_0x2dffb2['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x192ab5['removeMarker'](_0x574efa);}),_0x53c488['isReady']=!0x1,_0x2dffb2['model']['enqueueChange'](_0x249eed=>{_0x249eed['setSelection'](null),_0x249eed['removeSelectionAttribute'](_0x2dffb2['model']['document']['selection']['getAttributeKeys']());const _0x17b225=Object['keys'](_0x33a9f3);for(const _0x5e75ed of _0x2dffb2['model']['document']['roots'])'$graveyard'!=_0x5e75ed['rootName']&&_0x5e75ed['isAttached']()&&!_0x17b225['includes'](_0x5e75ed['rootName'])&&_0x249eed['detachRoot'](_0x5e75ed);for(const _0x220f4d of _0x17b225){let _0x203f12=_0x2dffb2['model']['document']['getRoot'](_0x220f4d);_0x203f12&&_0x203f12['isAttached']()||(_0x203f12=_0x249eed['addRoot'](_0x220f4d));const _0x14c72d=_0x22603f[_0x220f4d],_0x34576a=Object['keys'](_0x14c72d),_0x3e6fc1=_0x33a9f3[_0x220f4d];for(const _0x1fc04b of _0x203f12['getAttributeKeys']())_0x34576a['includes'](_0x1fc04b)||_0x249eed['removeAttribute'](_0x1fc04b,_0x203f12);for(const _0x1fd083 of _0x34576a)_0x249eed['setAttribute'](_0x1fd083,_0x22603f[_0x220f4d][_0x1fd083],_0x203f12);_0x249eed['remove'](_0x249eed['createRangeIn'](_0x203f12)),_0x249eed['insert'](_0x2dffb2['data']['parse'](_0x3e6fc1,_0x203f12),_0x203f12,0x0);}});const _0x1726f6=m(_0x2dffb2['locale'],'Restored');if(_0x4fe522['name'])_0x42b817=-0x1==_0x4fe522['name']['indexOf'](_0x1726f6)?_0x1726f6+':\x20'+_0x4fe522['name']:_0x4fe522['name'];else _0x42b817=_0x1726f6+':\x20'+(_0x4fe522['createdAt']['toLocaleDateString'](_0x2dffb2['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x4fe522['createdAt']['toLocaleTimeString'](_0x2dffb2['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x39d99b['saveRevision']({'name':_0x42b817}),_0x53c488['isReady']=!0x0,_0x2dffb2['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{nt as RestoreRevisionCommand,I as Revision,ct as RevisionHistory,l as RevisionHistoryUI,$ as RevisionHistoryUtils,h as RevisionTracker,u as RevisionViewer,f as RevisionViewerEditor,ht as RevisionViewerIntegration,ji as RevisionViewerLoadingOverlay,v as RevisionViewerUI,S as RevisionsRepository,d as RevisionsSidebar,rt as ShowChangeCommand};