@ckeditor/ckeditor5-revision-history 47.2.0-alpha.0 → 47.2.0-alpha.2

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 _0x1b6ed6,uid as _0x3191d3,Collection as _0x1dcfeb,logWarning as _0x1d296d,FocusTracker as _0x3feea3,KeystrokeHandler as _0x5ec85b,scrollViewportToShowTarget as _0x341d84,ResizeObserver as ot,ElementReplacer as it,CKEditorError as _0x4f08e9}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x204d12,set as _0x57a772,unset as _0x2b8b0a,isEqual as _0x5e1a1d}from'es-toolkit/compat';import{Plugin as _0x23b9b4,PendingActions as _0x412783,Command as _0x15cc66,ElementApiMixin as _0x1ad7d6,Editor as _0x21409b}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x1f5a70,getMarkerDomElement as _0x542bc9,ConfirmMixin as _0x58ed8b,sanitizeEditorConfig as _0xb086e5}from'ckeditor5-collaboration/dist/index.js';import{ViewContainerElement as _0x368cf1,ViewAttributeElement as _0x368f98,ViewEmptyElement as _0x29ed98,ViewRawElement as _0x521445,ViewUIElement as _0x5e6ce1,ViewDocumentFragment as _0x1d37c0,ViewText as _0x5d9919,ViewElement as _0x222be2,ModelElement as _0x5acc5d,ModelRange as _0x207b33,ModelPosition as _0x3bc5f2,ModelDocumentFragment as _0x3fb9bd,ModelText as _0x558b43}from'@ckeditor/ckeditor5-engine/dist/index.js';import{IconHistory as _0x433702,IconChevronUp as _0x583de3,IconChevronDown as _0x163c7b,IconUndo as _0x432dbf,IconUser as _0x568042,IconThreeVerticalDots as _0x3057b1}from'@ckeditor/ckeditor5-icons/dist/index.js';import{CssTransitionDisablerMixin as _0x1f19c2,View as _0x524cb0,submitHandler as _0x40d9b0,LabeledFieldView as et,createLabeledInputText as ti,createDropdown as _0x10fce4,ListView as _0x569f00,ListItemView as _0x10db92,ButtonView as _0x4e77f1,MenuBarMenuView as _0x5e691f,MenuBarMenuListView as _0x5b33bc,MenuBarMenuListItemView as _0x1b911a,MenuBarMenuListItemButtonView as _0x42bcb6,ContextualBalloon as _0x46c628,ToolbarSeparatorView as _0x5c4716,IconView as _0x1dcc7a,addListToDropdown as _0x348a03,UIModel as to,EditorUI as tt,normalizeToolbarConfig as st,BoxedEditorUIView as _0x7ffce6,StickyPanelView as _0x46ff0e,ToolbarView as _0x24896f,InlineEditableUIView as te}from'@ckeditor/ckeditor5-ui/dist/index.js';import{DateTime as _0x35d12b}from'luxon';class I extends/* #__PURE__ -- @preserve */
24
- _0x1b6ed6(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x230e16){super(),this['id']=_0x230e16['id']||_0x3191d3(),this['creator']=_0x230e16['creator']||null,this['authors']=_0x230e16['authors']||[],this['diffData']=_0x230e16['diffData']||null,this['toVersion']=_0x230e16['toVersion']||0x0,this['fromVersion']=_0x230e16['fromVersion']||0x0,this['set']('name',_0x230e16['name']||''),this['set']('createdAt',_0x230e16['createdAt']||new Date()),this['set']('attributes',_0x230e16['attributes']||{});}['setName'](_0xb90389){this['_update']({'name':_0xb90389});}['setAttribute'](_0x162f68,_0x29b33a){const _0x4459f6=_0x204d12(this['attributes']);_0x57a772(_0x4459f6,_0x162f68,_0x29b33a),this['_update']({'attributes':_0x4459f6});}['removeAttribute'](_0xdf78f9){const _0x28606d=_0x204d12(this['attributes']);_0x2b8b0a(_0x28606d,_0xdf78f9),this['_update']({'attributes':_0x28606d});}['_update'](_0x4ad7d5,_0x54fa59=!0x1){let _0x2d9af7=!0x1;const _0x4bb441={'id':this['id']},_0x80d4d0=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x31804b of _0x80d4d0){const _0x4245cc=_0x4ad7d5[_0x31804b];void 0x0!==_0x4245cc&&_0x4245cc!==this[_0x31804b]&&(this[_0x31804b]=_0x4245cc,_0x4bb441[_0x31804b]=_0x4245cc,_0x2d9af7=!0x0);}_0x2d9af7&&(_0x4bb441['authors']&&(_0x4bb441['authorsIds']=_0x4bb441['authors']['map'](_0x1bedbd=>_0x1bedbd['id']),delete _0x4bb441['authors']),this['fire']('_update',_0x4bb441,_0x54fa59));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x418c27=>_0x418c27['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class S extends _0x23b9b4{['_revisions'];static get['requires'](){return[_0x1f5a70];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x406d1c){super(_0x406d1c),this['_revisions']=new _0x1dcfeb();}['afterInit'](){!async function(_0x58d36b){const _0x5dfea9=_0x32081d([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]),_0x3996d1=0xeb829,_0xadf290=0x359e09b0,_0x13d83c=0x35997e20^_0xadf290,_0x4d7a07=window[_0x32081d([0x44,0x61,0x74,0x65])][_0x32081d([0x6e,0x6f,0x77])](),_0x5a1a12=_0x58d36b[_0x32081d([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x11087b=new window[(_0x32081d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x320abb=>{_0x5a1a12[_0x32081d([0x6f,0x6e,0x63,0x65])](_0x32081d([0x72,0x65,0x61,0x64,0x79]),_0x320abb);}),_0x478f21={[_0x32081d([0x6b,0x74,0x79])]:_0x32081d([0x45,0x43]),[_0x32081d([0x75,0x73,0x65])]:_0x32081d([0x73,0x69,0x67]),[_0x32081d([0x63,0x72,0x76])]:_0x32081d([0x50,0x2d,0x32,0x35,0x36]),[_0x32081d([0x78])]:_0x32081d([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]),[_0x32081d([0x79])]:_0x32081d([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]),[_0x32081d([0x61,0x6c,0x67])]:_0x32081d([0x45,0x53,0x32,0x35,0x36])},_0x127bb3=_0x5a1a12[_0x32081d([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x32081d([0x67,0x65,0x74])](_0x32081d([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x22f5e5(){let _0x52e433,_0x343f24=null,_0x1475fa=null;try{if(_0x127bb3==_0x32081d([0x47,0x50,0x4c]))return _0x32081d([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x52e433=_0xef7ce8(),!_0x52e433)return _0x32081d([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x52e433[_0x32081d([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x1475fa=_0xaa8902(_0x52e433[_0x32081d([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x52e433[_0x32081d([0x6a,0x74,0x69])])),await _0x2c6aaa()?_0x287009()?_0x15897c()?_0x32081d([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x10cd4d()?(_0x52e433[_0x32081d([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x32081d([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x343f24=_0x466dfc(_0x32081d([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x52e433[_0x32081d([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x32081d([0x74,0x72,0x69,0x61,0x6c])&&(_0x343f24=_0x466dfc(_0x32081d([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x5b76da()):_0x32081d([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x32081d([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x32081d([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x32081d([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x15897c(){const _0x14aa07=[_0x32081d([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x32081d([0x74,0x72,0x69,0x61,0x6c])][_0x32081d([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x52e433[_0x32081d([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x4d7a07/0x3e8:0xe10*_0x13d83c;return _0x52e433[_0x32081d([0x65,0x78,0x70])]<_0x14aa07;}function _0x287009(){const _0x68d453=_0x52e433[_0x32081d([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x68d453)return!0x1;if(_0x68d453[_0x32081d([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x32081d([0x2a])))return!0x0;if(_0x68d453[_0x32081d([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x32081d([0x52,0x48])))return!0x0;if(_0x68d453[_0x32081d([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x32081d([0x52,0x52,0x48]))){if(_0xde23d5())return!0x0;if(_0x479b1c()||_0x424d4c())return!0x0;}return!0x1;}function _0x10cd4d(){const _0x28c276=_0x52e433[_0x32081d([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x28c276||0x0==_0x28c276[_0x32081d([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x51ec26}=new URL(window[_0x32081d([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x28c276[_0x32081d([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x51ec26))return!0x0;const _0x591309=_0x51ec26[_0x32081d([0x73,0x70,0x6c,0x69,0x74])](_0x32081d([0x2e]));return _0x28c276[_0x32081d([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x23a476=>_0x23a476[_0x32081d([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x32081d([0x2a])))[_0x32081d([0x6d,0x61,0x70])](_0x2eadba=>_0x2eadba[_0x32081d([0x73,0x70,0x6c,0x69,0x74])](_0x32081d([0x2e])))[_0x32081d([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x5a0832=>_0x5a0832[_0x32081d([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x591309[_0x32081d([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x32081d([0x6d,0x61,0x70])](_0x631dd1=>Array(_0x591309[_0x32081d([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0x631dd1[_0x32081d([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x32081d([0x66,0x69,0x6c,0x6c])](_0x631dd1[0x0]===_0x32081d([0x2a])?_0x32081d([0x2a]):'')[_0x32081d([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0x631dd1))[_0x32081d([0x73,0x6f,0x6d,0x65])](_0x41d707=>_0x591309[_0x32081d([0x65,0x76,0x65,0x72,0x79])]((_0x1d7c25,_0x388217)=>_0x41d707[_0x388217]===_0x1d7c25||_0x41d707[_0x388217]===_0x32081d([0x2a])));}function _0x5b76da(){return _0x343f24&&_0x1475fa?new window[(_0x32081d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x397052,_0x12b9ff)=>{_0x343f24[_0x32081d([0x74,0x68,0x65,0x6e])](_0x397052,_0x12b9ff),_0x1475fa[_0x32081d([0x74,0x68,0x65,0x6e])](_0x54f974=>{_0x54f974!=_0x32081d([0x56,0x61,0x6c,0x69,0x64])&&_0x397052(_0x54f974);},_0x12b9ff);}):_0x343f24||_0x1475fa||_0x32081d([0x56,0x61,0x6c,0x69,0x64]);}}function _0xaa8902(_0x2f3c3a,_0x1c7efa){return new window[(_0x32081d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x333010=>{if(_0x1c913f())return _0x333010(_0x32081d([0x56,0x61,0x6c,0x69,0x64]));_0x5e3cec(),_0x5a1a12[_0x32081d([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x32081d([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x56133b=!0x1;const _0x45ab5f=_0x3191d3();function _0x4cdb77(_0x3e974c){return!!_0x3e974c&&(typeof _0x3e974c===_0x32081d([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x3e974c===_0x32081d([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x3e974c[_0x32081d([0x74,0x68,0x65,0x6e])]===_0x32081d([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x3e974c[_0x32081d([0x63,0x61,0x74,0x63,0x68])]===_0x32081d([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x3ac88f(_0x1baf50){_0x249cda(_0x1baf50)[_0x32081d([0x74,0x68,0x65,0x6e])](_0x3e638a=>{if(!_0x3e638a||_0x3e638a[_0x32081d([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x32081d([0x6f,0x6b]))return _0x32081d([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x2107cc(_0x3ff9a1(_0x45ab5f+_0x1c7efa))!=_0x3e638a[_0x32081d([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x32081d([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x32081d([0x56,0x61,0x6c,0x69,0x64]);})[_0x32081d([0x74,0x68,0x65,0x6e])](_0x540e58=>(_0x593840(),_0x540e58),()=>{const _0x3e3f59=_0x12f2c2();return null==_0x3e3f59?(_0x593840(),_0x32081d([0x56,0x61,0x6c,0x69,0x64])):_0x32081d(_0x4d7a07-_0x3e3f59>(0x11928db0^_0xadf290)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x32081d([0x74,0x68,0x65,0x6e])](_0x333010)[_0x32081d([0x63,0x61,0x74,0x63,0x68])](()=>{_0x333010(_0x32081d([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x53474a=0x35a8e730^_0xadf290;function _0x593840(){const _0x5bffc7=_0x32081d([0x6c,0x6c,0x63,0x74,0x2d])+_0x2107cc(_0x3ff9a1(_0x2f3c3a)),_0x20021f=_0x4cabcb(_0x2107cc(window[_0x32081d([0x4d,0x61,0x74,0x68])][_0x32081d([0x63,0x65,0x69,0x6c])](_0x4d7a07/_0x53474a)));window[_0x32081d([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x32081d([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x5bffc7,_0x20021f);}function _0x12f2c2(){const _0x2e7ea0=_0x32081d([0x6c,0x6c,0x63,0x74,0x2d])+_0x2107cc(_0x3ff9a1(_0x2f3c3a)),_0x364027=window[_0x32081d([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x32081d([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x2e7ea0);return _0x364027?window[_0x32081d([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x4cabcb(_0x364027),0x10)*_0x53474a:null;}function _0x249cda(_0x93b77c){return new window[(_0x32081d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x43a97c,_0x3eeb9b)=>{_0x93b77c[_0x32081d([0x74,0x68,0x65,0x6e])](_0x43a97c,_0x3eeb9b),window[_0x32081d([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x3eeb9b,0x359fdd70^_0xadf290);});}}_0x5a1a12[_0x32081d([0x6f,0x6e])](_0x32081d([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x1a88ae,_0x31d78c)=>{if(_0x31d78c[0x0]!=_0x2f3c3a)return _0x333010(_0x32081d([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x31d78c[0x1]={..._0x31d78c[0x1],[_0x32081d([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x45ab5f};},{[_0x32081d([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x32081d([0x68,0x69,0x67,0x68])}),_0x5a1a12[_0x32081d([0x6f,0x6e])](_0x32081d([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x2d4595=>{_0x4cdb77(_0x2d4595[_0x32081d([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x56133b=!0x0,_0x3ac88f(_0x2d4595[_0x32081d([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x32081d([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x32081d([0x6c,0x6f,0x77])}),_0x11087b[_0x32081d([0x74,0x68,0x65,0x6e])](()=>{_0x56133b||_0x333010(_0x32081d([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x1c913f(){return _0x5a1a12[_0x32081d([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x32081d([0x76,0x69,0x65,0x77])][_0x32081d([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x32081d([0x61,0x75,0x74,0x6f]);}function _0x5e3cec(){_0x5a1a12[_0x32081d([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x32081d([0x76,0x69,0x65,0x77])][_0x32081d([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x32081d([0x61,0x75,0x74,0x6f]);}}function _0x466dfc(_0x7df7b0){const _0x140a22=[new window[(_0x32081d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0xcebe55=>setTimeout(_0xcebe55,0x3597377c^_0xadf290)),_0x11087b[_0x32081d([0x74,0x68,0x65,0x6e])](()=>new window[(_0x32081d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2c6ace=>{const _0x36a5b9=0x359e09b7^_0xadf290,_0x5d2ba=_0x58d36b[_0x32081d([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x14b221(){_0x5d2ba[_0x32081d([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x36a5b9&&_0x2c6ace();}_0x14b221(),_0x5d2ba[_0x32081d([0x6f,0x6e])](_0x32081d([0x61,0x64,0x64]),_0x14b221);})),new window[(_0x32081d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x344db6=>{function _0x339649(){for(const _0xfe88cb in window)if(window[_0x32081d([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x32081d([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0xfe88cb))&&window[_0xfe88cb]==_0x3996d1)return _0x344db6();_0x5a1a12[_0x32081d([0x73,0x74,0x61,0x74,0x65])]!=_0x32081d([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x32081d([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x339649,0x359e1a38^_0xadf290);}_0x59f91e(_0x32081d([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x339649();})];return window[_0x32081d([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x32081d([0x72,0x61,0x63,0x65])](_0x140a22)[_0x32081d([0x74,0x68,0x65,0x6e])](()=>_0x7df7b0);}async function _0x3be338(){if(await _0x11087b,_0x59f91e(_0x32081d([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x24981f=_0x58d36b[_0x32081d([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x1ea3d1=_0x58d36b[_0x32081d([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])](_0x24981f[_0x32081d([0x69,0x64])]),_0x3a5c09=_0x2cb204(_0x32081d([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x3a5c09[_0x32081d([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x24981f['id'],_0x1ea3d1?_0x1ea3d1['id']:null,!0x0),_0x3a5c09[_0x32081d([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x32081d([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x3a5c09[_0x32081d([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x3a5c09[_0x32081d([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x57134e,void(_0x3a5c09[_0x32081d([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x57134e);}if(_0x59f91e(_0x32081d([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x4dae0e=_0x2cb204(_0x32081d([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x4dae0e[_0x32081d([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x32081d([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x4dae0e[_0x32081d([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x4dae0e[_0x32081d([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x57134e,_0x4dae0e[_0x32081d([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x57134e;}_0x5a1a12[_0x32081d([0x6d,0x6f,0x64,0x65,0x6c])][_0x32081d([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x57134e,_0x5a1a12[_0x32081d([0x6d,0x6f,0x64,0x65,0x6c])][_0x32081d([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x57134e,_0x5a1a12[_0x32081d([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x32081d([0x6d,0x6f,0x64,0x65,0x6c]));}function _0xde23d5(){return _0x59f91e(_0x32081d([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x2cb204(_0x32081d([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x32081d([0x73,0x74,0x61,0x74,0x65])]==_0x32081d([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x479b1c(){return _0x59f91e(_0x32081d([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 _0x424d4c(){return _0x59f91e(_0x32081d([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x3b1783(_0x438d17){const _0x95e4ce=_0x34c7c4();_0x5a1a12[_0x95e4ce]=_0x32081d([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])+_0x438d17,_0x438d17[_0x32081d([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x32081d([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x34c7c4()]=_0x3996d1),_0x438d17!=_0x32081d([0x56,0x61,0x6c,0x69,0x64])&&_0x3be338();}function _0x34c7c4(){const _0x2e7c67=window[_0x32081d([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x32081d([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x32081d([0x6e,0x6f,0x77])]())[_0x32081d([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x32081d([0x2e]),'');let _0x3b3c2c=_0x32081d([0x76]);for(let _0x220c28=0x0;_0x220c28<_0x2e7c67[_0x32081d([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x220c28+=0x2){let _0x14263c=window[_0x32081d([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x2e7c67[_0x32081d([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x220c28,_0x220c28+0x2));_0x14263c>=_0x5dfea9[_0x32081d([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x14263c-=_0x5dfea9[_0x32081d([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x3b3c2c+=_0x5dfea9[_0x14263c];}return _0x3b3c2c;}function _0xef7ce8(){const _0x141e24=_0x127bb3[_0x32081d([0x73,0x70,0x6c,0x69,0x74])](_0x32081d([0x2e]));if(0x3!=_0x141e24[_0x32081d([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x46ed4e(_0x141e24[0x1]);function _0x46ed4e(_0x9c260c){const _0x243b0d=_0x1398fa(_0x9c260c);return _0x243b0d&&_0x5c54ac()?_0x243b0d:null;function _0x5c54ac(){const _0x15ee9e=_0x243b0d[_0x32081d([0x6a,0x74,0x69])],_0x219671=window[_0x32081d([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x15ee9e[_0x32081d([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x15ee9e[_0x32081d([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x53844a={..._0x243b0d,[_0x32081d([0x6a,0x74,0x69])]:_0x15ee9e[_0x32081d([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x15ee9e[_0x32081d([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x53844a[_0x32081d([0x76,0x63])],_0x3ff9a1(_0x53844a)==_0x219671;}}}async function _0x2c6aaa(){let _0x3e34dc=!0x0;try{const _0x385998=_0x127bb3[_0x32081d([0x73,0x70,0x6c,0x69,0x74])](_0x32081d([0x2e])),[_0x18ba73,_0x4d2d4c,_0x4dc9d4]=_0x385998;return _0x2e5210(_0x18ba73),await _0x38fd03(_0x18ba73,_0x4d2d4c,_0x4dc9d4),_0x3e34dc;}catch{return!0x1;}function _0x2e5210(_0x2ad0fa){const _0x5c1b7f=_0x1398fa(_0x2ad0fa);_0x5c1b7f&&_0x5c1b7f[_0x32081d([0x61,0x6c,0x67])]==_0x32081d([0x45,0x53,0x32,0x35,0x36])||(_0x3e34dc=!0x1);}async function _0x38fd03(_0x2eacd1,_0x5b75b0,_0x14ebf5){const _0x1647e9=window[_0x32081d([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x32081d([0x66,0x72,0x6f,0x6d])](_0x8d482c(_0x14ebf5),_0x187535=>_0x187535[_0x32081d([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x30debf=new window[(_0x32081d([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x32081d([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x2eacd1+_0x32081d([0x2e])+_0x5b75b0),_0x37e468=window[_0x32081d([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x32081d([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x37e468)return;const _0x7e957e=await _0x37e468[_0x32081d([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x32081d([0x6a,0x77,0x6b]),_0x478f21,{[_0x32081d([0x6e,0x61,0x6d,0x65])]:_0x32081d([0x45,0x43,0x44,0x53,0x41]),[_0x32081d([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x32081d([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x32081d([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x37e468[_0x32081d([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x32081d([0x6e,0x61,0x6d,0x65])]:_0x32081d([0x45,0x43,0x44,0x53,0x41]),[_0x32081d([0x68,0x61,0x73,0x68])]:{[_0x32081d([0x6e,0x61,0x6d,0x65])]:_0x32081d([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x7e957e,_0x1647e9,_0x30debf)||(_0x3e34dc=!0x1);}}function _0x1398fa(_0x1cfde9){return _0x1cfde9[_0x32081d([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x32081d([0x65,0x79]))?JSON[_0x32081d([0x70,0x61,0x72,0x73,0x65])](_0x8d482c(_0x1cfde9)):null;}function _0x8d482c(_0x20bf65){return window[_0x32081d([0x61,0x74,0x6f,0x62])](_0x20bf65[_0x32081d([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x32081d([0x2b]))[_0x32081d([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x32081d([0x2f])));}function _0x3ff9a1(_0x2a505e){let _0x36fc8d=0x1505;function _0x235827(_0x36d5ab){for(let _0x4218ad=0x0;_0x4218ad<_0x36d5ab[_0x32081d([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x4218ad++){const _0x8e5bdb=_0x36d5ab[_0x32081d([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x4218ad);_0x36fc8d=(_0x36fc8d<<0x5)+_0x36fc8d+_0x8e5bdb,_0x36fc8d&=_0x36fc8d;}}function _0x195db4(_0x545e47){Array[_0x32081d([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x545e47)?_0x545e47[_0x32081d([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x195db4):_0x545e47&&typeof _0x545e47==_0x32081d([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x32081d([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x545e47)[_0x32081d([0x73,0x6f,0x72,0x74])]()[_0x32081d([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0xed64ce,_0x1ba4d3])=>{_0x235827(_0xed64ce),_0x195db4(_0x1ba4d3);}):_0x235827(window[_0x32081d([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x545e47));}return _0x195db4(_0x2a505e),_0x36fc8d>>>0x0;}function _0x2107cc(_0x4051f0){return _0x4051f0[_0x32081d([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x32081d([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x32081d([0x30]));}function _0x4cabcb(_0x23aee1){return _0x23aee1[_0x32081d([0x73,0x70,0x6c,0x69,0x74])]('')[_0x32081d([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x32081d([0x6a,0x6f,0x69,0x6e])]('');}function _0x59f91e(_0x4a1f0b){return _0x5a1a12[_0x32081d([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x32081d([0x68,0x61,0x73])](_0x4a1f0b);}function _0x2cb204(_0x2b8522){return _0x5a1a12[_0x32081d([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x32081d([0x67,0x65,0x74])](_0x2b8522);}function _0x57134e(){}function _0x32081d(_0x2e4c18){return _0x2e4c18['map'](_0x5522be=>String['fromCharCode'](_0x5522be))['join']('');}_0x3b1783(await _0x22f5e5());}(this);}['createRevision'](_0x582759){const _0x5957cf=this['editor']['plugins']['get']('Users');return new I({'id':_0x582759['id'],'name':_0x582759['name'],'creator':_0x582759['creatorId']?_0x5957cf['getUser'](_0x582759['creatorId']):null,'diffData':_0x582759['diffData']||_0x582759['data'],'authors':_0x582759['authorsIds']['map'](_0x52fbb6=>_0x5957cf['getUser'](_0x52fbb6)),'createdAt':new Date(_0x582759['createdAt']),'attributes':_0x582759['attributes'],'fromVersion':_0x582759['fromVersion'],'toVersion':_0x582759['toVersion']});}['addRevision'](_0x5bd850,_0x4e89c1=0x0){this['_revisions']['add'](_0x5bd850,_0x4e89c1);}['getRevision'](_0x4e3b09){return this['_revisions']['get'](_0x4e3b09);}['getRevisions'](_0x1ed213={'toJSON':!0x1}){const _0x4d92db=Array['from'](this['_revisions']);return _0x4d92db['reverse'](),_0x1ed213['toJSON']?_0x4d92db['map'](_0x559d6e=>_0x559d6e['toJSON']()):_0x4d92db;}['getIndex'](_0x573af2){return this['_revisions']['getIndex'](_0x573af2);}['getEarlierVisibleRevision'](_0x47a16e){const [,_0xc7c658]=this['getRevisionsIterator'](_0x47a16e,{'direction':'earlier'});return _0xc7c658;}['getLaterVisibleRevision'](_0x1afb75){const [,_0x1d73c1]=this['getRevisionsIterator'](_0x1afb75,{'direction':'later'});return _0x1d73c1;}['getRevisionsInDiff'](_0x377346){const _0x58d9f6=[];for(const _0x4e4a74 of this['getRevisionsIterator'](_0x377346['newRevisionId']))if(_0x58d9f6['push'](_0x4e4a74),_0x4e4a74['id']===_0x377346['oldRevisionId'])break;return _0x58d9f6;}*['getRevisionsIterator'](_0xe9dc98,{direction:_0x50857c='earlier',filter:_0x4cb205=()=>!0x0}={}){const _0x432e51='earlier'===_0x50857c?0x1:-0x1;let _0x474cd8=this['_revisions']['get'](_0xe9dc98),_0x27a288=this['getIndex'](_0x474cd8);for(yield _0x474cd8;_0x474cd8;){if(_0x27a288+=_0x432e51,_0x474cd8=this['getRevision'](_0x27a288),!_0x474cd8)return;_0x4cb205(_0x474cd8)&&(yield _0x474cd8);}}}class $ extends _0x23b9b4{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x368cf1,'c'],[_0x368f98,'a'],[_0x29ed98,'e'],[_0x521445,'r'],[_0x5e6ce1,'u']]);['_typeCharToViewClass']=new Map([['c',_0x368cf1],['a',_0x368f98],['e',_0x29ed98],['r',_0x521445],['u',_0x5e6ce1]]);async['loadRevisionData'](_0x2c8f26,_0x3e5bdb){if(_0x2c8f26['diffData']||!_0x3e5bdb)return;const _0x3f7e7e=this['editor']['config']['get']('collaboration.channelId'),_0x58bf99=await _0x3e5bdb['getRevision']({'channelId':_0x3f7e7e,'revisionId':_0x2c8f26['id']});_0x2c8f26['diffData']=_0x58bf99['diffData'];}['getRevisionDocumentData'](_0xcfd399){const _0x5875ef={};for(const _0x570064 in _0xcfd399['diffData']){if(_0xcfd399['diffData'][_0x570064]['attachChange']&&!_0xcfd399['diffData'][_0x570064]['attachChange']['isAttached'])continue;const _0x3d2888=this['_removeRevisionMarkers'](JSON['parse'](_0xcfd399['diffData'][_0x570064]['insertions'])),_0x1dd19a=this['editor']['editing']['view']['document'],_0x386600=new _0x1d37c0(_0x1dd19a,_0x3d2888['map'](_0x46737f=>this['_getViewFromDiffObj'](_0x46737f,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x5875ef[_0x570064]=this['editor']['data']['processor']['toData'](_0x386600),this['editor']['data']['processor']['useFillerType']('default');}return _0x5875ef;}['getRevisionRootsAttributes'](_0x22ad7d){const _0xdf2636={};for(const _0x516413 in _0x22ad7d['diffData'])_0x22ad7d['diffData'][_0x516413]['attachChange']&&!_0x22ad7d['diffData'][_0x516413]['attachChange']['isAttached']||(_0xdf2636[_0x516413]=_0x22ad7d['diffData'][_0x516413]['attributesAfter']||{});return _0xdf2636;}['_getTypeCharForViewElement'](_0x2dfe11){return this['_viewClassToTypeChar']['get'](_0x2dfe11['constructor']);}['_getViewFromDiffObj'](_0x2aabc6,_0x3ec96b){const _0x51b25a=this['editor']['editing']['view']['document'];if('string'==typeof _0x2aabc6)return new _0x5d9919(_0x51b25a,_0x2aabc6);{let _0x5f4eed,_0xdd6033;_0xdd6033='u'==_0x2aabc6['type']||'r'==_0x2aabc6['type']?[]:_0x2aabc6['children']['map'](_0x10f0d0=>this['_getViewFromDiffObj'](_0x10f0d0,_0x3ec96b));const _0x29ba4a=this['_typeCharToViewClass']['get'](_0x2aabc6['type'])||_0x222be2,_0xef7e6a=this['editor']['data']['htmlProcessor']['domConverter'];if(_0x5f4eed=new _0x29ba4a(_0x51b25a,_0x2aabc6['name'],_0x2aabc6['attributes'],_0xdd6033),'u'==_0x2aabc6['type']&&_0x2aabc6['children'][0x0]){const _0x28f229=_0x2aabc6['children'][0x0];if(_0x5f4eed['render']=function(_0x2b091e){const _0x89b7a1=_0x2b091e['createElement']('div');return _0x89b7a1['innerHTML']=_0x28f229,_0x89b7a1['childNodes'][0x0];},_0x3ec96b){const _0x905b51=new _0x1d37c0(_0x51b25a);_0x905b51['_appendChild'](_0x5f4eed);const _0x1e4347=Array['from'](_0xef7e6a['viewChildrenToDom'](_0x905b51,{'bind':!0x1})),_0x2023a3=_0xef7e6a['domDocument']['createElement']('div');_0x2023a3['append'](..._0x1e4347),_0x5f4eed=Array['from'](_0xef7e6a['domChildrenToView'](_0x2023a3))[0x0];}}else{if('r'==_0x2aabc6['type']&&_0x2aabc6['children'][0x0]){const _0x5a8c17=_0x2aabc6['children'][0x0];if(_0x5f4eed['render']=function(_0x4a76cb){_0x4a76cb['innerHTML']=_0x5a8c17;},_0x3ec96b){const _0x5b006a=new _0x1d37c0(_0x51b25a);_0x5b006a['_appendChild'](_0x5f4eed);const _0x12298e=Array['from'](_0xef7e6a['viewChildrenToDom'](_0x5b006a,{'bind':!0x1})),_0x35c776=_0xef7e6a['domDocument']['createElement']('div');_0x35c776['append'](..._0x12298e);const _0x227a04=Array['from'](_0xef7e6a['domChildrenToView'](_0x35c776));_0x227a04['length']>0x1?_0x5f4eed['_appendChild'](_0x227a04):_0x5f4eed=_0x227a04[0x0];}}}if(_0x2aabc6['customProperties']){for(const [_0x1c90e1,_0x4a97be]of _0x2aabc6['customProperties'])_0x5f4eed['_setCustomProperty'](_0x1c90e1,_0x4a97be);}const _0x2374e5=void 0x0===_0x2aabc6['fillerOffset']?null:_0x2aabc6['fillerOffset'];return null!==_0x2374e5&&(_0x5f4eed['getFillerOffset']=()=>_0x2374e5),_0x5f4eed;}}['_makeModelFromViewString'](_0x7b9757){const _0x37f8ae=JSON['parse'](_0x7b9757),_0x1294c3=this['editor']['editing']['view']['document'],_0x1fe15d=new _0x1d37c0(_0x1294c3,_0x37f8ae['map'](_0x23875d=>this['_getViewFromDiffObj'](_0x23875d,!0x0)));return this['editor']['data']['toModel'](_0x1fe15d);}['_removeRevisionMarkers'](_0x3f5ea4){return(_0x3f5ea4=_0x3f5ea4['filter'](_0xaa9557=>!_0xaa9557['name']||'revision-start'!==_0xaa9557['name']&&'revision-end'!==_0xaa9557['name']))['forEach'](_0x54aafd=>{'string'!=typeof _0x54aafd&&(_0x54aafd['children']=this['_removeRevisionMarkers'](_0x54aafd['children']),_0x54aafd['attributes']=_0x54aafd['attributes']['filter'](_0x306cae=>!_0x306cae[0x0]['startsWith']('data-revision-')));}),_0x3f5ea4;}}function m(_0x5211a5,_0xd2ded2,_0x2a80ab){const t=_0x5211a5['t'];switch(_0xd2ded2){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'},_0x2a80ab);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x2a80ab);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 _0x23b9b4{['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[_0x1f5a70,S,$,_0x412783];}constructor(_0x30de5c){super(_0x30de5c),this['repository']=this['editor']['plugins']['get']('RevisionsRepository'),this['_utils']=this['editor']['plugins']['get']('RevisionHistoryUtils'),this['_revisionDataBuilder']=new E(this['editor']),this['_initialRevisionId']=this['editor']['config']['get']('collaboration.channelId')||'initial',this['_bufferedUpdates']=new Map(),this['_loadedStateData']=null;const _0x1e06c4=_0x3191d3();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x1e06c4},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 _0x1d60a7=this['repository']['getRevision'](0x0),_0x46a1de=_0x1d60a7&&null===_0x1d60a7['creator']?_0x1d60a7:null;if(this['_continueCurrentRevision']=!!_0x46a1de&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x50a1aa=this['_source']['getCurrentRevisionId'](),_0x223c83=this['repository']['getRevision'](_0x50a1aa);if(_0x223c83)this['_startingVersion']=_0x223c83['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x2b9fdd=this['_source']['history']['_operations']['find'](_0x3c8d33=>!_0x3c8d33['_isInit']),_0x16b1e6=_0x2b9fdd?_0x2b9fdd['baseVersion']:this['_source']['history']['version'];_0x1d60a7?(_0x1d60a7['toVersion']<_0x16b1e6&&_0x1d60a7['_update']({'toVersion':_0x16b1e6}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x46a1de['id'],this['_startingVersion']=_0x46a1de['fromVersion']):(this['_startingVersion']=_0x1d60a7['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x16b1e6,this['_continueCurrentRevision']=!0x1);}}else _0x46a1de&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x46a1de['toVersion'],this['editor']['model']['document']['history']['version']),_0x46a1de['fromVersion']===_0x46a1de['toVersion']?(0x0!==_0x46a1de['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x46a1de['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x46a1de['id'],this['_startingVersion']=_0x46a1de['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',_0x18c202=>!_0x18c202),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x21befb=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x408693;for(const _0x1bd8e8 in _0x21befb){const _0x533280=_0x1bd8e8,_0x4a7989=_0x21befb[_0x533280];if('revisionHistoryLicenseKeyValid'==_0x4a7989||'revisionHistoryLicenseKeyInvalid'==_0x4a7989||'revisionHistoryLicenseKeyExpired'==_0x4a7989||'revisionHistoryLicenseKeyDomainLimit'==_0x4a7989||'revisionHistoryLicenseKeyNotAllowed'==_0x4a7989||'revisionHistoryLicenseKeyEvaluationLimit'==_0x4a7989||'revisionHistoryLicenseKeyTrialLimit'==_0x4a7989||'revisionHistoryLicenseKeyUsageLimit'==_0x4a7989){delete _0x21befb[_0x533280],_0x408693=_0x4a7989,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x408693&&_0x21befb['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x408693&&_0x21befb['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x408693&&_0x21befb['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x408693&&_0x21befb['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x408693&&_0x21befb['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x408693&&_0x21befb['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x408693&&_0x21befb['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x591896=this['repository']['getRevision'](0x0),_0x5ee3ac=await this['getRevisionDocumentData'](_0x591896),_0x18895b=await this['getRevisionRootsAttributes'](_0x591896);this['_replaceEditorDataWithRevisionData'](_0x5ee3ac,_0x18895b);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0xc9481c){this['_source']=_0xc9481c;}async['update'](){const _0x37a7b3=await this['_source']['getLatestVersion']();if(_0x37a7b3>this['currentRevision']['toVersion']){await this['_loadState']();const _0x44a55f=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x37a7b3});_0x44a55f['authors']=_0x44a55f['authorsIds']['map'](_0x127191=>this['editor']['plugins']['get']('Users')['getUser'](_0x127191)),this['currentRevision']['_update'](_0x44a55f);}}async['saveRevision'](_0x571da8={},_0x495546=null){const _0x3a4af9=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x495546>this['currentRevision']['toVersion']&&(_0x495546=null),null===_0x495546&&(_0x495546=await this['_source']['getLatestVersion']());const _0xd92051=this['_getFromVersion'](_0x495546),_0x44e8e0=this['buildRevisionData']({'from':_0xd92051,'to':_0x495546});if(this['currentRevision']['toVersion']<_0x495546){const _0x9ccdac=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x495546,'to':_0x495546});_0x9ccdac['authors']=[],_0x9ccdac['authorsIds']=[],_0x9ccdac['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x9ccdac,!0x0),delete _0x9ccdac['authors'],_0x3a4af9['push'](_0x9ccdac);}_0x571da8['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x571da8['name']=_0x571da8['name']||null,_0x571da8['id']=_0x571da8['id']||_0x3191d3(),_0x571da8={..._0x571da8,..._0x44e8e0};const _0x5a9ca4=this['addRevisionData'](_0x571da8);_0x3a4af9['push'](_0x571da8);const _0x12e079=this['repository']['getIndex'](_0x5a9ca4);if(0x0!==_0x12e079){const _0x573d84=this['repository']['getRevision'](_0x12e079-0x1);if(_0x573d84['fromVersion']!==_0x495546){const _0x3ab73b=this['_revisionDataBuilder']['getData'](_0x495546,_0x573d84['toVersion']),_0x2b98e7={'id':_0x573d84['id'],'diffData':_0x3ab73b['diffData'],'authorsIds':_0x3ab73b['authorsIds'],'authors':_0x3ab73b['authorsIds']['map'](_0x10892c=>this['editor']['plugins']['get']('Users')['getUser'](_0x10892c)),'fromVersion':_0x495546};_0x573d84===this['currentRevision']&&(_0x2b98e7['createdAt']=new Date(_0x571da8['createdAt']['getTime']()+0xa)),_0x573d84['_update'](_0x2b98e7,!0x0),delete _0x2b98e7['authors'],_0x3a4af9['push'](_0x2b98e7);}}if(this['adapter']){for(const _0x1b8e39 of _0x3a4af9)this['_bufferUpdate'](_0x1b8e39['id'],_0x1b8e39,!0x0);this['sendBufferedUpdates']();}return _0x5a9ca4;}['addRevisionData'](_0x4d0c80){const _0x2c9420=this['repository']['createRevision'](_0x4d0c80);return this['adapter']&&_0x2c9420['on']('_update',(_0x1b8e66,_0x45350a,_0x2a7b72)=>{_0x2a7b72||(this['_bufferUpdate'](_0x45350a['id'],_0x45350a,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x2c9420,this['_findInsertionIndex'](_0x2c9420)),_0x2c9420;}async['getRevisionDocumentData'](_0x493094){return await this['_utils']['loadRevisionData'](_0x493094,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x493094);}async['getRevisionRootsAttributes'](_0x2b99a0){return await this['_utils']['loadRevisionData'](_0x2b99a0,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x2b99a0);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x208462=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x4d01d4=0x0;_0x4d01d4<_0x208462['length'];_0x4d01d4++){const _0x36a1dc=_0x208462[_0x4d01d4];let _0xf17e9d=!0x1;for(const _0x24f033 of Object['keys'](_0x36a1dc))void 0x0===_0x36a1dc[_0x24f033]?delete _0x36a1dc[_0x24f033]:'id'!==_0x24f033&&(_0xf17e9d=!0x0);_0xf17e9d||(_0x208462[_0x4d01d4]=null);}if(_0x208462=_0x208462['filter'](_0x522fe5=>null!==_0x522fe5),!_0x208462['length'])return;for(let _0x2ffef1=0x0;_0x2ffef1<_0x208462['length'];_0x2ffef1++){const _0x2bda86=_0x208462[_0x2ffef1];void 0x0!==_0x2bda86['fromVersion']&&void 0x0===_0x2bda86['toVersion']&&(_0x2bda86['toVersion']=this['repository']['getRevision'](_0x2bda86['id'])['toVersion']),void 0x0!==_0x2bda86['toVersion']&&void 0x0===_0x2bda86['fromVersion']&&(_0x2bda86['fromVersion']=this['repository']['getRevision'](_0x2bda86['id'])['fromVersion']);}const _0x12e6fe=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x208462,_0x12e6fe)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x2ffa5c=>{if(_0x2ffa5c){for(const _0x2b78dc of _0x2ffa5c)this['setRevisionData']({'id':_0x2b78dc['id'],'createdAt':_0x2b78dc['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0x14752e=null,from:_0x1f5c38=null,to:_0x3bbbb1=null}){_0x1f5c38=null!==_0x1f5c38?_0x1f5c38:_0x14752e['fromVersion'],_0x3bbbb1=null!==_0x3bbbb1?_0x3bbbb1:_0x14752e['toVersion'];const _0xb837e3=this['_revisionDataBuilder']['getData'](_0x1f5c38,_0x3bbbb1),_0x6a3c64={'diffData':_0xb837e3['diffData'],'authorsIds':_0xb837e3['authorsIds'],'fromVersion':_0x1f5c38,'toVersion':_0x3bbbb1};if(!_0x14752e||_0x3bbbb1!==_0x14752e['toVersion']){const _0x544969=_0x3bbbb1-0x1,_0x3b4956=this['_source']['history']['getOperation'](_0x544969);_0x6a3c64['createdAt']=_0x3b4956&&_0x3b4956['createdAt']||new Date();}if(this['_loadedStateData']&&_0x1f5c38===this['_loadedStateData']['fromVersion']){for(const _0xa17d74 of this['_loadedStateData']['authors'])_0x6a3c64['authorsIds']['includes'](_0xa17d74['id'])||_0x6a3c64['authorsIds']['push'](_0xa17d74['id']);}return _0x6a3c64;}['_bufferUpdate'](_0x528c30,_0x560d1d,_0x53cb2f){if(this['_bufferedUpdates']['has'](_0x528c30)){const _0x22dd3d=this['_bufferedUpdates']['get'](_0x528c30);_0x560d1d=_0x53cb2f?{..._0x22dd3d,..._0x560d1d}:{..._0x560d1d,..._0x22dd3d};}this['_bufferedUpdates']['set'](_0x528c30,_0x560d1d);}['setRevisionData'](_0x148303){const _0x38cf17=this['repository']['getRevision'](_0x148303['id']);if(_0x148303['createdAt']&&(_0x148303['createdAt']=new Date(_0x148303['createdAt'])),_0x148303['authorsIds']){const _0x386767=this['editor']['plugins']['get']('Users');_0x148303['authors']=_0x148303['authorsIds']['map'](_0x4120b4=>_0x386767['getUser'](_0x4120b4));}_0x38cf17['_update'](_0x148303,!0x0);}['_createInitialRevision'](_0x5e7cef){const _0x3fc935=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x3fc935)this['_initialRevisionId']=_0x3fc935['id'];else{const _0x37c432=!this['editor']['model']['document']['roots']['find'](_0xca085f=>this['editor']['model']['hasContent'](_0xca085f)),_0x10bba4=this['editor']['plugins']['get']('Users')['me']['id'],_0x47522e=m(this['editor']['locale'],_0x37c432?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x5e7cef,'to':_0x5e7cef,'id':this['_initialRevisionId'],'name':_0x47522e,'creatorId':_0x10bba4});}}['_createCurrentRevision'](_0x219fb0){const _0x3886af=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x3886af),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x219fb0,'to':_0x219fb0,'id':_0x3886af,'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'](_0xb6824b,_0x4ae69e){let _0x452d18=this['editor']['config']['get']('initialData'),_0x179b58=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x452d18){_0x452d18={};for(const _0x2c2e60 of this['editor']['model']['document']['getRootNames']())_0x452d18[_0x2c2e60]='';}if('string'==typeof _0x452d18&&(_0x452d18={'main':_0x452d18}),void 0x0===_0x179b58){_0x179b58={};for(const _0x3f25b9 of this['editor']['model']['document']['getRootNames']())_0x179b58[_0x3f25b9]={};}let _0x5388df=!0x1;const _0x1755f6=Object['keys'](_0x452d18),_0x5411d8=Object['keys'](_0xb6824b);for(const _0x147e66 of _0x1755f6){if(_0x452d18[_0x147e66]!==_0xb6824b[_0x147e66]&&''!==_0x452d18[_0x147e66]['trim']()){_0x5388df=!0x0;break;}if(!_0x5e1a1d(_0x179b58[_0x147e66],_0x4ae69e[_0x147e66])&&Object['keys'](_0x179b58[_0x147e66])['length']>0x0){_0x5388df=!0x0;break;}}_0x5388df||(_0x5388df=_0x5411d8['some'](_0x5aa260=>!this['editor']['model']['document']['getRoot'](_0x5aa260))),_0x5388df&&_0x1d296d('editor-initial-data-replaced-with-revision-data',{'editorData':_0x452d18,'editorRootsAttributes':_0x179b58,'revisionData':_0xb6824b,'revisionRootsAttributes':_0x4ae69e}),this['editor']['config']['set']('initialData',_0xb6824b),this['editor']['config']['set']('rootsAttributes',_0x4ae69e);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x586be0=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x586be0['add'](m(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x220429){const _0x51f95c=this['repository']['getRevisions']();_0x51f95c['reverse']();let _0x3f9f8a=0x0;for(;_0x3f9f8a<_0x51f95c['length'];){const _0x177e6f=_0x51f95c[_0x3f9f8a];if(_0x177e6f===this['currentRevision']){_0x3f9f8a++;continue;}if(_0x177e6f['id']===this['_initialRevisionId'])break;const _0x35a62a=_0x220429['toVersion']-_0x177e6f['toVersion']||_0x220429['fromVersion']-_0x177e6f['fromVersion'];if(_0x35a62a>0x0)break;if(_0x35a62a<0x0)_0x3f9f8a++;else{if(!_0x220429['creator']&&_0x177e6f['creator'])break;if(_0x177e6f['creator']||!_0x220429['creator']){if(_0x220429['createdAt']>_0x177e6f['createdAt'])break;_0x3f9f8a++;}else _0x3f9f8a++;}}return _0x3f9f8a;}['_getFromVersion'](_0x5704f9){const _0x4187bc=this['repository']['getRevisions']();_0x4187bc['reverse'](),_0x4187bc['shift']();const _0xf82107=_0x4187bc['find'](_0x209f3f=>_0x209f3f['toVersion']<=_0x5704f9)['toVersion'];return _0xf82107<this['_startingVersion']?this['_startingVersion']:_0xf82107;}['_makeRevision']({name:_0x5cadb3,from:_0xfa8a4f,to:_0x425a4e,creatorId:_0x3b7ae5,id:_0x4536c7}){const _0x184235=this['buildRevisionData']({'from':_0xfa8a4f,'to':_0x425a4e});_0x184235['name']=_0x5cadb3,_0x184235['creatorId']=_0x3b7ae5,_0x184235['id']=_0x4536c7;const _0x28a85c=this['addRevisionData'](_0x184235);return this['adapter']&&this['_bufferUpdate'](_0x184235['id'],_0x184235,!0x0),_0x28a85c;}['_setConversion'](){this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'});}}class E{['editor'];['source'];['_savedMetaData'];['_lastFrom'];['_lastTo'];['_markers'];['_diffRoots'];['_diffRootsAttributes'];['_baseRoots'];['_baseRootsAttributes'];['_idsRoots'];['_baseIdsRoots'];['_touched'];['_touchedMarkers'];['_touchedRoots'];['_revisionId'];['_startingRevisionId'];constructor(_0x4f1a4e){this['editor']=_0x4f1a4e,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'](_0x567c4a){this['source']=_0x567c4a;const _0x131be5=new Map(),_0x16c811=new Map(),_0x3ac71d=this['editor']['model']['document']['roots']['map'](_0x1fca4c=>_0x1fca4c['rootName']);for(const _0x221a5d of _0x3ac71d){const _0x3446ae=this['editor']['model']['document']['getRoot'](_0x221a5d),_0x507c78=x(_0x3446ae);_0x131be5['set'](_0x221a5d,_0x507c78),_0x16c811['set'](_0x221a5d,Object['fromEntries'](_0x3446ae['getAttributes']()));}const _0x122a8f=Array['from'](this['editor']['model']['markers'])['map'](_0x40b70f=>[_0x40b70f['name'],_0x40b70f['getRange']()]),_0x715278=this['source']['version'];this['_saveMetaData'](_0x715278,_0x131be5,_0x122a8f,_0x16c811),this['_startingRevisionId']=this['_revisionId'];const _0x2b8923=new Map(),_0x460801=new Map();for(const _0x3175e6 of _0x3ac71d){const _0x1afbad=N(_0x3175e6);_0x2b8923['set'](_0x3175e6,_0x1afbad),_0x460801['set'](_0x3175e6,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x2b8923,[],_0x460801);}['getData'](_0x219584,_0x5a72c0){if(this['_lastFrom']===_0x219584&&this['_lastTo']<=_0x5a72c0)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x5a72c0,!0x0);else{if(!this['_savedMetaData']['has'](_0x219584)){const _0x2765e9=this['_getPreviousFrom'](_0x219584);this['_calculateMetaData'](_0x2765e9,_0x219584,!0x1);}this['_calculateMetaData'](_0x219584,_0x5a72c0,!0x0);}return this['_lastFrom']=_0x219584,this['_lastTo']=_0x5a72c0,this['_getState']();}['loadState'](_0x5b0f85){if(!this['_savedMetaData']['has'](_0x5b0f85['fromVersion'])){const _0x5200d2=this['_getPreviousFrom'](_0x5b0f85['fromVersion']);this['_calculateMetaData'](_0x5200d2,_0x5b0f85['fromVersion'],!0x1);}this['_calculateMetaData'](_0x5b0f85['fromVersion'],_0x5b0f85['toVersion'],!0x1);const _0x41e666=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x5b0f85['fromVersion'],this['_lastTo']=_0x5b0f85['toVersion'];for(const _0x5cca30 in _0x5b0f85['diffData']){const _0x21d5fa=_0x5b0f85['diffData'][_0x5cca30]['attachChange'],_0x534eec=_0x204d12(_0x5b0f85['diffData'][_0x5cca30]['attributesBefore'])||{},_0x272393=_0x41e666['_makeModelFromViewString'](_0x5b0f85['diffData'][_0x5cca30]['deletions']);_0x272393['rootName']=_0x5cca30,_0x272393['_isAttached']=!_0x21d5fa||!_0x21d5fa['isAttached'],_0x272393['isAttached']=()=>_0x272393['_isAttached'],this['_baseRoots']['set'](_0x5cca30,_0x272393),this['_baseRootsAttributes']['set'](_0x5cca30,_0x534eec),_0x21d5fa&&this['_touchedRoots']['set'](_0x5cca30,_0x21d5fa);const _0x177d3e=this['_makeIdsRoot'](_0x272393);this['_baseIdsRoots']['set'](_0x5cca30,_0x177d3e);for(const [_0x4a012c,_0x365352]of _0x272393['markers']){if(!_0x4a012c['startsWith']('revision:'))continue;const _0x2c53db=_0x4a012c['split'](':')[0x2];for(const _0x2736c1 of _0x365352['getWalker']({'singleCharacters':!0x0})){const _0xd22180=this['_getVidAttributeName'](_0x2736c1),_0x28a808='elementEnd'==_0x2736c1['type']?_0x2736c1['previousPosition']['path']['slice'](0x0,-0x1):_0x2736c1['previousPosition']['path'],_0x4da9c5=_0x177d3e['getNodeByPath'](_0x28a808)['getAttribute'](_0xd22180);this['_touched']['set'](_0x4da9c5,{'userId':_0x2c53db});}_0x272393['markers']['delete'](_0x4a012c);}}this['_startingRevisionId']=this['_revisionId'];const _0x58dde2=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0xcbfe9d=>!this['_touched']['has'](_0xcbfe9d));let _0x1ec986=0x0;const _0x2d9d09=new Map();for(const _0x463814 in _0x5b0f85['diffData']){const _0x5baf81=_0x5b0f85['diffData'][_0x463814]['attachChange'],_0x1707fe=_0x204d12(_0x5b0f85['diffData'][_0x463814]['attributesAfter'])||{},_0x4d41c2=_0x41e666['_makeModelFromViewString'](_0x5b0f85['diffData'][_0x463814]['insertions']);_0x4d41c2['rootName']=_0x463814,_0x4d41c2['_isAttached']=!_0x5baf81||_0x5baf81['isAttached'],_0x4d41c2['isAttached']=()=>_0x4d41c2['_isAttached'],this['_diffRoots']['set'](_0x463814,_0x4d41c2),this['_diffRootsAttributes']['set'](_0x463814,_0x1707fe);const _0x49c813=this['_makeIdsRoot'](_0x4d41c2,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x463814,_0x49c813),_0x2d9d09['set'](_0x463814,_0x4d41c2['isAttached']()?_0x1707fe:{});for(const [_0x146128,_0x335c04]of _0x4d41c2['markers']){if(!_0x146128['startsWith']('revision:'))continue;const _0x2c67de=_0x146128['split'](':')[0x2];for(const _0x416884 of _0x335c04['getWalker']({'singleCharacters':!0x0})){const _0x1df29b=this['_getVidAttributeName'](_0x416884),_0x75a2b6=this['_revisionId']++,_0x5d67f2='elementEnd'==_0x416884['type']?_0x416884['previousPosition']['path']['slice'](0x0,-0x1):_0x416884['previousPosition']['path'];_0x49c813['getNodeByPath'](_0x5d67f2)['_setAttribute'](_0x1df29b,_0x75a2b6),this['_touched']['set'](_0x75a2b6,{'userId':_0x2c67de});}_0x4d41c2['markers']['delete'](_0x146128);}for(const _0x3cb532 of this['editor']['model']['createRangeIn'](_0x4d41c2)['getWalker']({'singleCharacters':!0x0})){const _0x22b2da=this['_getVidAttributeName'](_0x3cb532),_0x15ae23='elementEnd'==_0x3cb532['type']?_0x3cb532['previousPosition']['path']['slice'](0x0,-0x1):_0x3cb532['previousPosition']['path'],_0x518df0=_0x49c813['getNodeByPath'](_0x15ae23);_0x518df0['getAttribute'](_0x22b2da)>0x0||_0x518df0['_setAttribute'](_0x22b2da,_0x58dde2[_0x1ec986++]);}for(const [_0x34fa62,_0x50a9b8]of _0x4d41c2['markers'])_0x34fa62['startsWith']('revision:')||this['_markers']['set'](_0x34fa62,_0x50a9b8);}const {roots:_0x13347a}=this['_savedMetaData']['get'](_0x5b0f85['fromVersion']),{roots:_0x3cc028}=this['_savedMetaData']['get'](_0x5b0f85['toVersion']),_0x22c465=x(_0x13347a['get']('$graveyard'));this['_baseRoots']['set']('$graveyard',_0x22c465),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x22c465,Number['NEGATIVE_INFINITY']));const _0x284bee=x(_0x3cc028['get']('$graveyard'));this['_diffRoots']['set']('$graveyard',_0x284bee),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x284bee));const _0x9b8da6=Array['from'](this['_diffRoots'])['map'](([_0x6c395e,_0x19cf2f])=>[_0x6c395e,x(_0x19cf2f)]);this['_saveMetaData'](this['_lastTo'],_0x9b8da6,this['_markers'],_0x2d9d09);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0x419c51,_0x490c9b,_0x1e66ee,_0x4d8217){const _0xb44dfa=new Map(_0x490c9b),_0x30a361=new Map(_0x204d12(_0x4d8217)),_0x47806c=new Map();for(const [_0xbb1860,_0x4a706e]of _0x1e66ee)_0x47806c['set'](_0xbb1860,{'start':_0x4a706e['start']['clone'](),'end':_0x4a706e['end']['clone'](),'rootName':_0x4a706e['root']['rootName']});this['_savedMetaData']['set'](_0x419c51,{'roots':_0xb44dfa,'markers':_0x47806c,'rootsAttributes':_0x30a361});}['_removeMetaData'](_0x53b4d6){this['_savedMetaData']['delete'](_0x53b4d6);}['_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'](_0x3ba43c,_0x572878=null){let _0x125369=null;_0x3ba43c['is']('documentFragment')||(_0x125369=new _0x5acc5d(_0x3ba43c['name'],{'vid_start':null===_0x572878?this['_revisionId']++:_0x572878++}));const _0x2d6647=[];for(const _0xbbb18 of _0x3ba43c['getChildren']())if(_0xbbb18['is']('element')){_0x2d6647['push'](this['_makeIdsRoot'](_0xbbb18,_0x572878));const _0x20cc7a=_0x2d6647[_0x2d6647['length']-0x1];null!==_0x572878&&(_0x572878=_0x20cc7a['is']('element','$text')?_0x20cc7a['getAttribute']('vid')+0x1:_0x20cc7a['getAttribute']('vid_end')+0x1);}else{for(let _0x375770=0x0;_0x375770<_0xbbb18['offsetSize'];_0x375770++)_0x2d6647['push'](new _0x5acc5d('$text',{'vid':null===_0x572878?this['_revisionId']++:_0x572878++}));}if(_0x3ba43c['is']('documentFragment')){const _0x4bac14=N(_0x3ba43c['rootName']);return _0x4bac14['_insertChild'](0x0,_0x2d6647),_0x4bac14;}return _0x125369['_setAttribute']('vid_end',null===_0x572878?this['_revisionId']++:_0x572878++),_0x125369['_insertChild'](0x0,_0x2d6647),_0x125369;}['_calculateMetaData'](_0x4aa33f,_0x1970d8,_0x566603){this['_reset']();const {roots:_0x387f0a,markers:_0x404bed,rootsAttributes:_0x4467bd}=this['_savedMetaData']['get'](_0x4aa33f);this['_baseRoots']=new Map(_0x387f0a),this['_baseRootsAttributes']=new Map(_0x204d12(_0x4467bd));for(const [_0xf5096a,_0x1c6d1e]of this['_baseRoots'])if('$graveyard'!==_0xf5096a&&(this['_diffRoots']['set'](_0xf5096a,x(_0x1c6d1e)),this['_diffRootsAttributes']=new Map(_0x204d12(_0x4467bd)),_0x566603)){const _0x5a6b4d=this['_revisionId'];this['_idsRoots']['set'](_0xf5096a,this['_makeIdsRoot'](_0x1c6d1e)),this['_baseIdsRoots']['set'](_0xf5096a,this['_makeIdsRoot'](_0x1c6d1e,_0x5a6b4d));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',x(this['_baseRoots']['get']('$graveyard'))),_0x566603&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0xc52e33,_0x379b05]of _0x404bed){const _0x5db028=this['_baseRoots']['get'](_0x379b05['rootName']),_0x2df6b2=this['_diffRoots']['get'](_0x379b05['rootName']),_0x9a1aba=new _0x207b33(this['_fixPosition'](_0x379b05['start'],_0x5db028),this['_fixPosition'](_0x379b05['end'],_0x5db028)),_0x5bb330=this['_fixRange'](_0x9a1aba,_0x2df6b2);_0x5db028['markers']['set'](_0xc52e33,_0x9a1aba),this['_markers']['set'](_0xc52e33,_0x5bb330);}this['_applyOperations'](_0x4aa33f,_0x1970d8,_0x566603);}['_applyOperations'](_0x2ec391,_0x1bc554,_0xcb63bd){for(const _0x2ccf93 of this['source']['getOperations'](_0x2ec391,_0x1bc554))this['_handleOperation'](_0x2ccf93,_0xcb63bd);for(const _0x4948bc of this['_diffRoots']['values']())_0x4948bc['markers']['clear']();for(const [_0x423561,_0x62c382]of this['_markers']){this['_diffRoots']['get'](_0x62c382['root']['rootName'])['markers']['set'](_0x423561,_0x62c382['clone']());}const _0x28631f=new Map(),_0x577346=new Map();for(const [_0x3cf686,_0x25707a]of this['_diffRoots'])_0x28631f['set'](_0x3cf686,x(_0x25707a)),_0x577346['set'](_0x3cf686,this['_diffRootsAttributes']['get'](_0x3cf686));this['_saveMetaData'](_0x1bc554,_0x28631f,this['_markers'],_0x577346);}['_getPreviousFrom'](_0x33fec8){const _0x38ea97=Array['from'](this['_savedMetaData']['keys']());_0x38ea97['sort']((_0x4ed09c,_0x102d5c)=>_0x4ed09c-_0x102d5c),_0x38ea97['reverse']();for(const _0xb278f of _0x38ea97)if(_0xb278f<_0x33fec8)return _0xb278f;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x9b936b,_0x5f7466){const _0x284626=Array['from'](_0x5f7466['markers'])['map'](([_0x4dd7c1,_0x13d487])=>[_0x4dd7c1,this['_fixRange'](_0x13d487,_0x9b936b)]);_0x9b936b['markers']=new Map(_0x284626);}['_transformMarkers'](_0x36a257){for(const _0x39da0a of this['_markers']['values']()){const _0x5ae819=_0x39da0a['getTransformedByOperation'](_0x36a257),_0x5db55f=_0x207b33['_createFromRanges'](_0x5ae819);_0x39da0a['start']=_0x5db55f['start'],_0x39da0a['end']=_0x5db55f['end'];}}['_handleOperation'](_0x173d3c,_0xb26662){if('addRoot'!=_0x173d3c['type']&&'detachRoot'!=_0x173d3c['type']){if('insert'==_0x173d3c['type']){const _0xf35ba6=_0x173d3c['position']['root']['rootName'];this['_diffRoots']['has'](_0xf35ba6)||(this['_diffRoots']['set'](_0xf35ba6,N(_0xf35ba6,!0x0)),this['_diffRootsAttributes']['set'](_0xf35ba6,{}),_0xb26662&&this['_idsRoots']['set'](_0xf35ba6,N(_0xf35ba6,!0x0)));}else{if('addRootAttribute'==_0x173d3c['type']||'removeRootAttribute'==_0x173d3c['type']||'changeRootAttribute'==_0x173d3c['type'])return void this['_handleRootAttributeOperation'](_0x173d3c);'marker'==_0x173d3c['type']&&this['_handleMarkerOperation'](_0x173d3c);}if('marker'!==_0x173d3c['type']){const _0x21d6a7=this['_cloneOperation'](_0x173d3c,this['_diffRoots']);_0x21d6a7['_execute'](),this['_transformMarkers'](_0x21d6a7);}if(_0xb26662)switch(_0x173d3c['type']){case'insert':this['_handleInsertOperation'](_0x173d3c);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x173d3c);break;case'merge':this['_handleMergeOperation'](_0x173d3c);break;case'split':this['_handleSplitOperation'](_0x173d3c);}}else this['_handleRootOperation'](_0x173d3c,_0xb26662);}['_cloneOperation'](_0x51c47b,_0x29887c){const _0x45dfa4=_0x51c47b['clone']();return _0x45dfa4['_authorId']=_0x51c47b['_authorId'],this['_fixOperation'](_0x45dfa4,_0x29887c),_0x45dfa4;}['_getBaseVids'](_0x232fed){return _0x232fed['map'](_0x3be71f=>{const _0x345082=this['_getVidAttributeName'](_0x3be71f);return Number(_0x3be71f['item']['getAttribute'](_0x345082));});}['_generateTape'](_0x3b3841,_0x37c3cc){if(_0x3b3841['is']('element','$text'))_0x37c3cc['push']({'item':_0x3b3841,'type':'text'});else{_0x3b3841['is']('element')&&_0x37c3cc['push']({'item':_0x3b3841,'type':'elementStart'});for(const _0x6572a6 of _0x3b3841['getChildren']())this['_generateTape'](_0x6572a6,_0x37c3cc);_0x3b3841['is']('element')&&_0x37c3cc['push']({'item':_0x3b3841,'type':'elementEnd'});}return _0x37c3cc;}['_getState'](){const _0x42940c=new Map(this['_touched']),_0x1b39f2=new Map(_0x42940c),_0x5a3107=new Map(),_0x4c0b04={'insertions':{},'deletions':{}},_0x41a97b={'insertions':{},'deletions':{}},_0x237df0=new Map(),_0x3c4391=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x3c4391['delete']('$graveyard');for(const _0x48c482 of _0x3c4391){const _0x2217dc=this['_diffRoots']['get'](_0x48c482)||N(_0x48c482,!0x1),_0x1aa144=this['_baseRoots']['get'](_0x48c482)||N(_0x48c482,!0x1);_0x2217dc['isAttached']()||_0x1aa144['isAttached']()?(_0x4c0b04['insertions'][_0x48c482]=x(_0x2217dc),_0x4c0b04['deletions'][_0x48c482]=x(_0x1aa144),this['_copyMarkers'](_0x4c0b04['deletions'][_0x48c482],_0x1aa144),this['_copyMarkers'](_0x4c0b04['insertions'][_0x48c482],_0x2217dc),_0x41a97b['insertions'][_0x48c482]=this['_generateTape'](this['_idsRoots']['get'](_0x48c482),[]),_0x41a97b['deletions'][_0x48c482]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x48c482)||N(_0x48c482,!0x1),[])):_0x3c4391['delete'](_0x48c482);}for(const _0x175dfe of _0x3c4391){const _0x381d18=_0x41a97b['insertions'][_0x175dfe];for(const _0x4b6046 of _0x381d18){const _0x8a750b=this['_getVidAttributeName'](_0x4b6046),_0x47294d=_0x4b6046['item']['getAttribute'](_0x8a750b);_0x1b39f2['delete'](_0x47294d),_0x47294d>=this['_startingRevisionId']&&_0x5a3107['set'](_0x47294d,_0x42940c['get'](_0x47294d));}}for(const _0x1ec628 of _0x3c4391){const _0x27461e=_0x41a97b['insertions'][_0x1ec628],_0x512e34=this['_getBaseVids'](_0x41a97b['deletions'][_0x1ec628]);let _0x7e2132=0x0;for(const _0x164d83 of _0x27461e){const _0x5a7b4c=this['_getVidAttributeName'](_0x164d83),_0x9c502e=_0x164d83['item']['getAttribute'](_0x5a7b4c);if(!_0x5a3107['has'](_0x9c502e)&&!_0x237df0['has'](_0x9c502e)){if(_0x1b39f2['has'](_0x9c502e))_0x7e2132++;else{if(_0x9c502e!=_0x512e34[_0x7e2132]){const _0x53d918=_0x42940c['get'](_0x9c502e)||_0x42940c['get'](_0x512e34[_0x7e2132]);for(;_0x9c502e!=_0x512e34[_0x7e2132];)_0x1b39f2['has'](_0x512e34[_0x7e2132])||(_0x237df0['set'](_0x512e34[_0x7e2132],_0x53d918),_0x42940c['set'](_0x512e34[_0x7e2132],_0x53d918)),_0x7e2132++;}_0x7e2132++;}}}}for(const _0x2218f7 of _0x3c4391){const _0x661449=_0x41a97b['insertions'][_0x2218f7];for(const _0x3c538b of _0x661449){const _0x5365c5=this['_getVidAttributeName'](_0x3c538b),_0x158d52=_0x3c538b['item']['getAttribute'](_0x5365c5);if(_0x237df0['has'](_0x158d52)){const _0x2d9bd5=_0x237df0['get'](_0x158d52);_0x1b39f2['has'](_0x158d52)||_0x1b39f2['set'](_0x158d52,{..._0x2d9bd5}),_0x5a3107['set'](_0x158d52,{..._0x2d9bd5});}}}for(const _0x370220 of _0x1b39f2['keys']())_0x370220>=this['_startingRevisionId']&&_0x1b39f2['delete'](_0x370220);const _0x57e9e0=new Map();for(const _0x375eba of _0x3c4391){let _0x52ed4a=_0x41a97b['insertions'][_0x375eba];for(const _0x32d9fc of _0x52ed4a)if(_0x32d9fc['item']['is']('element','tableCell')){const _0x4b767d=this['_getVidAttributeName'](_0x32d9fc),_0xee3342=_0x32d9fc['item']['getAttribute'](_0x4b767d);if(_0x5a3107['has'](_0xee3342)){const _0x321256=_0x32d9fc['item']['parent']['parent']['getAttribute']('vid_start'),_0x522779=_0x57e9e0['get'](_0x321256)||new Set();_0x522779['add'](_0x5a3107['get'](_0xee3342)['userId']),_0x57e9e0['set'](_0x321256,_0x522779);}}_0x52ed4a=_0x41a97b['deletions'][_0x375eba];for(const _0x4e42cc of _0x52ed4a)if(_0x4e42cc['item']['is']('element','tableCell')){const _0x532f04=this['_getVidAttributeName'](_0x4e42cc),_0x2a0093=_0x4e42cc['item']['getAttribute'](_0x532f04);if(_0x1b39f2['has'](_0x2a0093)){const _0x57b705=_0x4e42cc['item']['parent']['parent']['getAttribute']('vid_start'),_0x166a0f=_0x57e9e0['get'](_0x57b705)||new Set();_0x166a0f['add'](_0x1b39f2['get'](_0x2a0093)['userId']),_0x57e9e0['set'](_0x57b705,_0x166a0f);}}for(const _0x2a0806 of _0x57e9e0['keys']())(_0x5a3107['has'](_0x2a0806)||_0x1b39f2['has'](_0x2a0806))&&_0x57e9e0['delete'](_0x2a0806);}for(const _0x9d39d3 of _0x3c4391){const _0x3827a7=_0x41a97b['insertions'][_0x9d39d3];let _0x58e0db=null,_0x4ab05e=null;for(const _0x208d26 of _0x3827a7){const _0x4a9e29=this['_getVidAttributeName'](_0x208d26),_0x819d30=_0x208d26['item']['getAttribute'](_0x4a9e29),_0x406ba1=_0x57e9e0['get'](_0x819d30);_0x406ba1&&'elementStart'==_0x208d26['type']&&(_0x58e0db=Array['from'](_0x406ba1)[0x0],_0x4ab05e=_0x208d26['item']['getAttribute']('vid_end')),_0x58e0db&&(_0x1b39f2['set'](_0x819d30,{'userId':_0x58e0db}),_0x5a3107['set'](_0x819d30,{'userId':_0x58e0db})),_0x819d30==_0x4ab05e&&(_0x58e0db=null,_0x4ab05e=null);}}const _0x29de86={},_0x3c05f6=new Set();for(const _0x64de33 of _0x3c4391){const _0x1ea662=_0x4c0b04['deletions'][_0x64de33],_0x3f9d06=_0x4c0b04['insertions'][_0x64de33];for(const {userId:_0x47de8f}of this['_touchedMarkers']['values']())null!==_0x47de8f&&_0x3c05f6['add'](_0x47de8f);for(const {userId:_0x3e0183}of this['_touchedRoots']['values']())null!==_0x3e0183&&_0x3c05f6['add'](_0x3e0183);this['_markChanges'](_0x3f9d06,_0x41a97b['insertions'][_0x64de33],_0x5a3107,'insertion',_0x3c05f6),this['_markChanges'](_0x1ea662,_0x41a97b['deletions'][_0x64de33],_0x1b39f2,'deletion',_0x3c05f6),_0x29de86[_0x64de33]={'insertions':this['_prepareViewToSave'](_0x3f9d06),'deletions':this['_prepareViewToSave'](_0x1ea662),'attachChange':this['_touchedRoots']['get'](_0x64de33)||null,'attributesBefore':_0x204d12(this['_baseRootsAttributes']['get'](_0x64de33))||{},'attributesAfter':_0x204d12(this['_diffRootsAttributes']['get'](_0x64de33))};}return{'diffData':_0x29de86,'authorsIds':Array['from'](_0x3c05f6)};}['_processRootBeforeSave'](_0xd92042){for(const [,_0x9e1a44]of _0xd92042['markers']){const _0x2a26fa=_0x9e1a44['start']['getAncestors']()['filter'](_0x270724=>'tableCell'==_0x270724['name']);for(const _0x291264 of _0x2a26fa)0x1==_0x291264['childCount']&&_0x291264['getChild'](0x0)['is']('element','paragraph')&&_0x291264['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x47cfbe){this['_processRootBeforeSave'](_0x47cfbe);const _0x1b2639=this['editor']['data']['toView'](_0x47cfbe,{}),_0x585cc3=Array['from'](_0x1b2639['getChildren']())['map'](_0x3c2831=>this['_getViewJson'](_0x3c2831));return JSON['stringify'](_0x585cc3);}['_getViewJson'](_0x1eeefa){if(_0x1eeefa['is']('$text'))return _0x1eeefa['data'];{const _0x53643d=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0x20c6c0=_0x1eeefa,_0x33c2a2=this['editor']['data']['htmlProcessor']['domConverter'],_0x414da6={'type':_0x53643d['_getTypeCharForViewElement'](_0x20c6c0),'name':_0x20c6c0['name'],'attributes':Array['from'](_0x20c6c0['getAttributes']()),'children':Array['from'](_0x20c6c0['getChildren']())['map'](_0x48daa2=>this['_getViewJson'](_0x48daa2))};if(_0x1eeefa['is']('uiElement')&&'$comment'!=_0x1eeefa['name']){const _0x3e472f=_0x1eeefa['render'](_0x33c2a2['domDocument'],_0x33c2a2);_0x414da6['children']['push'](_0x3e472f['outerHTML']);}else{if(_0x1eeefa['is']('rawElement')){const _0x1c3635=_0x33c2a2['domDocument']['createElement'](_0x20c6c0['name']);_0x1eeefa['render'](_0x1c3635,_0x33c2a2),_0x414da6['children']['push'](_0x1c3635['innerHTML']);}}const _0x10f448=Array['from'](_0x20c6c0['getCustomProperties']());_0x10f448['length']>0x0&&(_0x414da6['customProperties']=_0x10f448);const _0x397c75=_0x20c6c0['getFillerOffset']();return null!==_0x397c75&&(_0x414da6['fillerOffset']=_0x397c75),_0x414da6;}}['_markChanges'](_0x3128c7,_0x294a9c,_0x23cb1c,_0xd264da,_0x12971e){let _0x4d3f19=null,_0x4b533b=null,_0x51ccdc=0x0;const _0x2808af=this['editor']['model'];for(let _0x53afa7=0x0;_0x53afa7<_0x294a9c['length'];_0x53afa7++){const _0x3d710c=this['_getVidAttributeName'](_0x294a9c[_0x53afa7]),_0x53c163=_0x294a9c[_0x53afa7]['item']['getAttribute'](_0x3d710c),_0x1f1586=_0x23cb1c['get'](_0x53c163),_0x4eb638=_0x53afa7==_0x294a9c['length']-0x1;(!_0x4d3f19&&_0x1f1586&&(_0x4d3f19=_0x1f1586,_0x4b533b=_0x294a9c[_0x53afa7]),_0x4d3f19&&(!_0x1f1586||_0x1f1586['userId']!=_0x4d3f19['userId']))&&(_0x27c9b2(_0x1f1586,P(_0x4b533b,_0x3128c7,_0x2808af),P(_0x294a9c[_0x53afa7],_0x3128c7,_0x2808af)),_0x4d3f19=_0x1f1586||null,_0x4b533b=_0x1f1586?_0x294a9c[_0x53afa7]:null),_0x4d3f19&&_0x4eb638&&_0x27c9b2(_0x1f1586,P(_0x4b533b,_0x3128c7,_0x2808af),V(_0x294a9c[_0x53afa7],_0x3128c7,_0x2808af));}function _0x27c9b2(_0x3ebc00,_0x230e9f,_0x2a83e9){const _0x1043f9=_0x4d3f19['userId'],_0x101b22='revision:'+_0xd264da+':'+_0x1043f9+':'+_0x51ccdc++,_0xc68ad9=_0x2808af['createRange'](_0x230e9f,_0x2a83e9);_0x3128c7['markers']['set'](_0x101b22,_0xc68ad9),null!==_0x1043f9&&_0x12971e['add'](_0x1043f9);}}['_getVidAttributeName'](_0x1b6460){switch(_0x1b6460['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x51ada9,_0x4c27f7){_0x51ada9['baseVersion']=null;for(const _0x1eb91a in _0x51ada9){const _0x5b6af8=_0x51ada9[_0x1eb91a];if(_0x5b6af8 instanceof _0x3bc5f2){const _0x4bd097=_0x4c27f7['get'](_0x5b6af8['root']['rootName']);_0x51ada9[_0x1eb91a]=this['_fixPosition'](_0x5b6af8,_0x4bd097);}if(_0x5b6af8 instanceof _0x207b33){const _0x4774c2=_0x4c27f7['get'](_0x5b6af8['root']['rootName']);_0x51ada9[_0x1eb91a]=this['_fixRange'](_0x5b6af8,_0x4774c2);}'root'===_0x1eb91a&&(_0x51ada9['root']=_0x4c27f7['get'](_0x51ada9['root']['rootName']));}}['_fixRange'](_0x4b11e1,_0x19fd33){return this['editor']['model']['createRange'](this['_fixPosition'](_0x4b11e1['start'],_0x19fd33),this['_fixPosition'](_0x4b11e1['end'],_0x19fd33));}['_fixPosition'](_0x135036,_0x3d3b3b){return this['editor']['model']['createPositionFromPath'](_0x3d3b3b,_0x135036['path'],_0x135036['stickiness']);}['_handleInsertOperation'](_0x171fa8){const _0x239f77=this['_idsRoots']['get'](_0x171fa8['position']['root']['rootName']),_0x1266d1=this['_fixPosition'](_0x171fa8['position'],_0x239f77),_0x33c841=null===_0x171fa8['_authorId']?null:_0x171fa8['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0xbc3049=_0x1266d1['parent'],_0x2a76ba=this['_revisionId'],_0x19475e=[];for(const _0x17ff44 of _0x171fa8['nodes'])if(_0x17ff44['is']('element'))_0x19475e['push'](this['_makeIdsRoot'](_0x17ff44));else{for(let _0x321b46=0x0;_0x321b46<_0x17ff44['offsetSize'];_0x321b46++)_0x19475e['push'](new _0x5acc5d('$text',{'vid':this['_revisionId']++}));}const _0x340e9b=this['_revisionId'];for(let _0x4b41df=_0x2a76ba;_0x4b41df<_0x340e9b;_0x4b41df++)this['_touched']['set'](_0x4b41df,{'userId':_0x33c841});_0xbc3049['_insertChild'](_0x1266d1['offset'],_0x19475e);}['_handleMoveOperation'](_0x2ab849){(_0x2ab849=this['_cloneOperation'](_0x2ab849,this['_idsRoots']))['_execute']();const _0x381fbe=null===_0x2ab849['_authorId']?null:_0x2ab849['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x51e5e5=_0x2ab849['getMovedRangeStart'](),_0x4ff74a=_0x51e5e5['parent'],_0x1322aa=_0x51e5e5['offset'];!function _0x5e70d4(_0x561735,_0x1caf4,_0x28ee61,_0xf562){for(let _0x39c0e9=_0x28ee61;_0x39c0e9<_0xf562;_0x39c0e9++){const _0x54f888=_0x1caf4['getChild'](_0x39c0e9);_0x54f888['is']('element','$text')?_0x561735['set'](_0x54f888['getAttribute']('vid'),{'userId':_0x381fbe}):(_0x561735['set'](_0x54f888['getAttribute']('vid_start'),{'userId':_0x381fbe}),_0x5e70d4(_0x561735,_0x54f888,0x0,_0x54f888['childCount']),_0x561735['set'](_0x54f888['getAttribute']('vid_end'),{'userId':_0x381fbe}));}}(this['_touched'],_0x4ff74a,_0x1322aa,_0x1322aa+_0x2ab849['howMany']);}['_handleMergeOperation'](_0x575815){const _0x10f56a=null===(_0x575815=this['_cloneOperation'](_0x575815,this['_idsRoots']))['_authorId']?null:_0x575815['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x4301f5=_0x575815['targetPosition']['parent'],_0x40ac24=_0x575815['sourcePosition']['parent'],_0x199419=_0x4301f5['getAttribute']('vid_end'),_0x4f10ce=_0x40ac24['getAttribute']('vid_start');_0x4301f5['_setAttribute']('vid_end',_0x40ac24['getAttribute']('vid_end')),_0x40ac24['_setAttribute']('vid_end',_0x199419),this['_touched']['set'](_0x4f10ce,{'userId':_0x10f56a}),this['_touched']['set'](_0x199419,{'userId':_0x10f56a}),_0x575815['_execute']();}['_handleSplitOperation'](_0x55e8fa){const _0x28bcab=null===(_0x55e8fa=this['_cloneOperation'](_0x55e8fa,this['_idsRoots']))['_authorId']?null:_0x55e8fa['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x47849b=_0x55e8fa['graveyardPosition'],_0x547928=_0x55e8fa['splitPosition']['parent'];_0x55e8fa['_execute']();const _0xeb5d6c=_0x547928['getAttribute']('vid_end'),_0x41e8f1=_0x55e8fa['insertionPosition']['nodeAfter'];if(_0x47849b){const _0x2e2b4e=_0x41e8f1['getAttribute']('vid_end'),_0x436406=_0x547928['getAttribute']('vid_end');_0x547928['_setAttribute']('vid_end',_0x2e2b4e),_0x41e8f1['_setAttribute']('vid_end',_0x436406),this['_touched']['set'](_0x547928['getAttribute']('vid_end'),{'userId':_0x28bcab}),this['_touched']['set'](_0x41e8f1['getAttribute']('vid_start'),{'userId':_0x28bcab});}else{const _0x3f3a6c=this['_revisionId']++,_0x87a0aa=this['_revisionId']++;_0x547928['_setAttribute']('vid_end',_0x3f3a6c),_0x41e8f1['_setAttribute']('vid_start',_0x87a0aa),_0x41e8f1['_setAttribute']('vid_end',_0xeb5d6c),this['_touched']['set'](_0x3f3a6c,{'userId':_0x28bcab}),this['_touched']['set'](_0x87a0aa,{'userId':_0x28bcab});}}['_handleMarkerOperation'](_0x2813c1){if(!_0x2813c1['affectsData'])return;const _0x212b24=(_0x2813c1=this['_cloneOperation'](_0x2813c1,this['_diffRoots']))['oldRange']?_0x2813c1['oldRange']['root']:null,_0x57d453=_0x2813c1['newRange']?_0x2813c1['newRange']['root']:null;_0x212b24&&this['_markers']['delete'](_0x2813c1['name']),_0x57d453&&this['_markers']['set'](_0x2813c1['name'],_0x2813c1['newRange']['clone']());const _0xec6fb1=null===_0x2813c1['_authorId']?null:_0x2813c1['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0xb6b765=_0x2813c1['name'];if(!this['_touchedMarkers']['has'](_0xb6b765))return void this['_touchedMarkers']['set'](_0xb6b765,{'range':_0x2813c1['oldRange'],'userId':_0xec6fb1});const _0x3444d9=this['_touchedMarkers']['get'](_0xb6b765),_0x525db7=_0x3444d9['range'],_0x28fee7=_0x2813c1['newRange'];null==_0x525db7&&null==_0x28fee7||_0x525db7&&_0x28fee7&&_0x525db7['isEqual'](_0x28fee7)?this['_touchedMarkers']['delete'](_0x2813c1['name']):_0x3444d9['userId']=_0xec6fb1;}['_handleRootOperation'](_0x145073,_0x5563a0){this['_diffRoots']['has'](_0x145073['rootName'])?this['_diffRoots']['get'](_0x145073['rootName'])['_isAttached']=_0x145073['isAdd']:(this['_diffRoots']['set'](_0x145073['rootName'],N(_0x145073['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x145073['rootName'],{}),_0x5563a0&&this['_idsRoots']['set'](_0x145073['rootName'],N(_0x145073['rootName'],!0x0)));const _0x4480ea=null===_0x145073['_authorId']?null:_0x145073['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x441d20=this['_touchedRoots']['get'](_0x145073['rootName']);_0x441d20&&_0x441d20['userId']===_0x4480ea?this['_touchedRoots']['delete'](_0x145073['rootName']):this['_touchedRoots']['set'](_0x145073['rootName'],{'userId':_0x4480ea,'isAttached':_0x145073['isAdd']});}['_handleRootAttributeOperation'](_0x407d04){const _0x1c1844=this['_diffRootsAttributes']['get'](_0x407d04['root']['rootName']);null===_0x407d04['newValue']?delete _0x1c1844[_0x407d04['key']]:_0x1c1844[_0x407d04['key']]=_0x407d04['newValue'];}}function x(_0x3f2fed){const _0x1bd6b2=N(_0x3f2fed['rootName'],_0x3f2fed['isAttached']());for(const _0xf42660 of _0x3f2fed['getChildren']()){const _0x5dac12=_0xf42660['_clone'](!0x0);_0x1bd6b2['_appendChild'](_0x5dac12);}return _0x1bd6b2;}function N(_0x6ab659,_0x2e24c4=!0x0){const _0x1dbfb4=new _0x3fb9bd();return _0x1dbfb4['rootName']=_0x6ab659,_0x1dbfb4['_isAttached']=_0x2e24c4,_0x1dbfb4['isAttached']=()=>_0x1dbfb4['_isAttached'],_0x1dbfb4;}function P(_0x46d259,_0x599655,_0x337442){const _0x38dfbf='elementEnd'==_0x46d259['type']?_0x337442['createPositionAt'](_0x46d259['item'],'end'):_0x337442['createPositionBefore'](_0x46d259['item']);return _0x337442['createPositionFromPath'](_0x599655,_0x38dfbf['path'],_0x38dfbf['stickiness']);}function V(_0x30d735,_0x3d6748,_0x37e0b6){const _0x9f03ff='elementStart'==_0x30d735['type']?_0x37e0b6['createPositionAt'](_0x30d735['item'],0x0):_0x37e0b6['createPositionAfter'](_0x30d735['item']);return _0x37e0b6['createPositionFromPath'](_0x3d6748,_0x9f03ff['path'],_0x9f03ff['stickiness']);}class me extends/* #__PURE__ -- @preserve */
25
- _0x1f19c2(_0x524cb0){['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x48f1dc,_0x1e595b){super(_0x48f1dc),this['focusTracker']=new _0x3feea3(),this['keystrokes']=new _0x5ec85b(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x1e595b),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'](),_0x40d9b0({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x1c9540=_0x38de3b=>_0x38de3b['stopPropagation']();this['keystrokes']['set']('arrowright',_0x1c9540),this['keystrokes']['set']('arrowleft',_0x1c9540),this['keystrokes']['set']('arrowup',_0x1c9540),this['keystrokes']['set']('arrowdown',_0x1c9540);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x4e4d39){this['revisionNameInputView']['fieldView']['element']['value']=_0x4e4d39['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x32d588){const _0x3ae503=new et(this['locale'],ti),_0x219024=_0x3ae503['fieldView'];_0x219024['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x37037e=m(this['locale'],'Name\x20of\x20the\x20revision');return!_0x32d588&&(_0x37037e+='\x20('+m(this['locale'],'optional')+')'),(_0x3ae503['label']=_0x37037e,_0x219024['on']('input',()=>{this['revisionNameInputValue']=_0x219024['element']['value']['trim']();}),_0x3ae503);}}class l extends _0x23b9b4{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h];}['_saveRevisionFormView'];['init'](){const _0x5337fd=this['editor'],_0x1f7b43=_0x5337fd['plugins']['get']('RevisionTracker');_0x5337fd['ui']['componentFactory']['add']('revisionHistory',_0x115936=>{const _0x460194=_0x10fce4(_0x115936),_0x536941=_0x460194['panelView']['children'],_0x1efa49=new _0x569f00(_0x115936),_0x17b5c2=new _0x10db92(_0x115936),_0x36d29b=new _0x4e77f1(_0x115936),_0x2ea6d3=new _0x10db92(_0x115936),_0x18e300=new _0x4e77f1(_0x115936);return _0x460194['bind']('isEnabled')['to'](_0x1f7b43,'isReady',_0x1f7b43,'isEnabled',_0x5337fd,'isReadOnly',(_0x2251ae,_0x4e9211,_0x5712cf)=>_0x2251ae&&_0x4e9211&&!_0x5712cf),_0x460194['buttonView']['set']({'icon':_0x433702,'label':m(_0x115936,'Revision\x20history'),'tooltip':!0x0}),_0x36d29b['set']({'label':m(_0x115936,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x36d29b['bind']('isEnabled')['to'](_0x1f7b43,'isReady',_0x1f7b43,'isEnabled',_0x5337fd,'isReadOnly',(_0x5af5d0,_0x526ef4,_0x2712e7)=>_0x5af5d0&&_0x526ef4&&!_0x2712e7),_0x36d29b['on']('execute',()=>this['_showDialog']()),_0x18e300['set']({'label':m(_0x115936,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x18e300['bind']('isEnabled')['to'](_0x1f7b43,'isReady',_0x5337fd,'isReadOnly',(_0x203a5c,_0x32e935)=>_0x203a5c&&!_0x32e935),_0x18e300['on']('execute',()=>{_0x5337fd['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x460194['isOpen']=!0x1,_0x5337fd['editing']['view']['focus']();}),_0x17b5c2['children']['add'](_0x36d29b),_0x2ea6d3['children']['add'](_0x18e300),_0x1efa49['role']='menu',_0x1efa49['items']['addMany']([_0x17b5c2,_0x2ea6d3]),_0x536941['add'](_0x1efa49),_0x460194;}),_0x5337fd['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x3bbb13=this['editor'],_0x19c182=_0x3bbb13['locale'],_0x2bb5ed=new _0x5e691f(_0x19c182),_0x9b5d15=new _0x5b33bc(_0x19c182);_0x2bb5ed['buttonView']['set']({'icon':_0x433702,'label':m(_0x19c182,'Revision\x20history')});const _0x52f04a=new _0x1b911a(_0x19c182,_0x2bb5ed),_0x17870c=new _0x42bcb6(_0x19c182);_0x17870c['set']({'label':m(_0x19c182,'Save\x20current\x20revision')}),_0x17870c['delegate']('execute')['to'](_0x2bb5ed),_0x17870c['on']('execute',()=>{this['_showDialog']();}),_0x52f04a['children']['add'](_0x17870c),_0x9b5d15['items']['add'](_0x52f04a);const _0xd394d1=new _0x1b911a(_0x19c182,_0x2bb5ed),_0x14e129=new _0x42bcb6(_0x19c182);return _0x14e129['set']({'label':m(_0x19c182,'Open\x20revision\x20history')}),_0x14e129['delegate']('execute')['to'](_0x2bb5ed),_0x14e129['on']('execute',()=>{_0x3bbb13['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0xd394d1['children']['add'](_0x14e129),_0x9b5d15['items']['add'](_0xd394d1),_0x2bb5ed['panelView']['children']['add'](_0x9b5d15),_0x2bb5ed;}['_showDialog'](){const _0x94f95b=this['editor'],_0x376551=_0x94f95b['locale'],_0x29ff2c=_0x94f95b['plugins']['get']('Dialog'),_0x3378e6=_0x94f95b['plugins']['get']('RevisionTracker');function _0x1f3620(_0x3d509e){_0x94f95b['config']['get']('revisionHistory.requireRevisionName')&&''===_0x3d509e['revisionName']?_0x3d509e['revisionNameInputView']['errorText']=m(_0x376551,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x94f95b['plugins']['get'](h)['saveRevision']({'name':_0x3d509e['revisionName']}),_0x29ff2c['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x1f3620(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x29ff2c['show']({'id':'revisionSave','title':m(_0x376551,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':m(_0x94f95b['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x29ff2c['hide']()},{'label':m(_0x94f95b['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x167aa4){_0x167aa4['bind']('isEnabled')['to'](_0x3378e6,'isReady',_0x3378e6,'isEnabled',_0x94f95b,'isReadOnly',(_0x229262,_0x563807,_0x2e4300)=>_0x229262&&_0x563807&&!_0x2e4300);},'onExecute':()=>_0x1f3620(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x94026=this['editor'],_0x10ce7f=_0x94026['locale'];this['_saveRevisionFormView']=new me(_0x10ce7f,_0x94026['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class z extends _0x524cb0{['changeId'];['_model'];constructor(_0x3869bc,_0x1b1c45){super(_0x3869bc),this['_model']=_0x1b1c45,this['changeId']=_0x1b1c45['id'];const _0x5b3bc4=this['bindTemplate'],_0x2b9891=m(_0x3869bc,_0x1b1c45['data']['isSuggestion']?'Suggested\x20by':'add'==_0x1b1c45['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x1b1c45['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x5b3bc4['to']('type',_0x5abd6b=>'ck-revision-change__'+_0x5abd6b)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x2b9891}]},{'text':'\x20'+_0x1b1c45['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class G extends/* #__PURE__ -- @preserve */
26
- _0x1b6ed6(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x215e87){super(),this['id']=_0x215e87['id']||_0x3191d3(),this['author']=_0x215e87['author'],this['type']=_0x215e87['type'],this['data']=_0x215e87['data']||{},this['rootName']=_0x215e87['rootName'],this['set']('createdAt',_0x215e87['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(_0x2135bc,_0x4055f8){this['newRevisionId']=_0x2135bc,this['oldRevisionId']=_0x4055f8,this['changes']=new _0x1dcfeb();}['_setChanges'](_0x5acd24){for(const _0x89da0a of _0x5acd24)this['changes']['add'](_0x89da0a);}}class u extends _0x23b9b4{['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[_0x1f5a70,_0x46c628,S,$];}constructor(_0x661005){super(_0x661005),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',(_0x5e03b1,_0xaf179d,_0x1e9254)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x428b80=>{for(const _0x2fa999 of this['editor']['editing']['view']['document']['roots'])_0x1e9254?_0x428b80['removeClass']('ck-editor__editable__overlay',_0x2fa999):_0x428b80['addClass']('ck-editor__editable__overlay',_0x2fa999);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x546902=>null!==_0x546902),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x52cb08,_0x50d1c0,_0x543002)=>_0x52cb08&&_0x543002?_0x50d1c0['changes']['getIndex'](_0x543002):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x3c89a5,_0x59dee6)=>_0x3c89a5?_0x59dee6['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0x46c628);}['init'](){const _0x2a6931=this['editor'],_0x686b33=new rt(_0x2a6931,{'direction':'backward'}),_0x7eb418=new rt(_0x2a6931,{'direction':'forward'});(_0x2a6931['commands']['add']('showPreviousChange',_0x686b33),_0x2a6931['commands']['add']('showNextChange',_0x7eb418),_0x2a6931['commands']['add']('restoreRevision',new nt(_0x2a6931)),this['on']('change:numberOfChanges',()=>{_0x686b33['refresh'](),_0x7eb418['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x2a6931['enableReadOnlyMode']('revision-viewer'),_0x2a6931['plugins']['has']('WidgetToolbarRepository'))&&_0x2a6931['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x1fc361){return await this['_utils']['loadRevisionData'](_0x1fc361,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x1fc361);}async['getRevisionRootsAttributes'](_0xac4179){return await this['_utils']['loadRevisionData'](_0xac4179,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0xac4179);}async['compare'](_0xffe663,_0xf4135d,_0x4a6c92=!0x1){if(!this['isEnabled'])return;const _0x215f99=this['diff'],_0x3e599f=this['repository'],_0x1f4c75='string'==typeof _0xffe663?_0x3e599f['getRevision'](_0xffe663):_0xffe663,_0x4919b8='string'==typeof _0xf4135d?_0x3e599f['getRevision'](_0xf4135d):_0xf4135d,_0x9dcb23=_0x1f4c75['id'],_0x22bccf=_0x4919b8?_0x4919b8['id']:null;if(!_0x4a6c92&&this['diff']&&this['diff']['newRevisionId']===_0x9dcb23&&this['diff']['oldRevisionId']===_0x22bccf)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new J(_0x9dcb23,_0x22bccf);const _0x50c8b1=this['_getRevisionsRange'](_0x1f4c75,_0x4919b8,!0x0)['map'](_0x318126=>this['_utils']['loadRevisionData'](_0x318126,this['adapter']));return _0x50c8b1['push'](new Promise(_0x234ae4=>{setTimeout(_0x234ae4,0x14);})),Promise['all'](_0x50c8b1)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x48e6bb=this['_getDiff'](_0x9dcb23,_0x22bccf);for(const _0x4123ab of _0x48e6bb['changes'])this['_changeIdToChange']['set'](_0x4123ab['id'],_0x4123ab);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x1442ab=>{for(const _0x567edd of this['editor']['model']['document']['getRootNames']())_0x1442ab['detachRoot'](_0x567edd);for(const _0x2a5e13 of Object['keys'](_0x48e6bb['model'])){const _0x37fd60=_0x1442ab['addRoot'](_0x2a5e13);for(const _0x495870 of Object['keys'](_0x48e6bb['attributes'][_0x2a5e13]))_0x1442ab['setAttribute'](_0x495870,_0x48e6bb['attributes'][_0x2a5e13][_0x495870],_0x37fd60);_0x1442ab['insert'](_0x48e6bb['model'][_0x2a5e13],_0x37fd60,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x48e6bb['changes'])),this['isReady']=!0x0;})['catch'](_0x5ee5c0=>{console['error'](_0x5ee5c0),this['_cleanUp'](),_0x215f99&&(this['diff']=_0x215f99),this['isReady']=!0x0;});}['addRevisionData'](_0x1a1c69,_0x5cfa58){const _0x1aaad8=this['repository']['createRevision'](_0x1a1c69);return _0x1aaad8['on']('_update',(_0x3dce96,_0x5ba8f3,_0x4c0d35)=>_0x5cfa58(_0x5ba8f3,_0x4c0d35,_0x1aaad8)),this['repository']['addRevision'](_0x1aaad8),_0x1aaad8;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x5845ec=>{for(const _0x318015 of this['editor']['model']['document']['getRootNames']())_0x5845ec['detachRoot'](_0x318015);});}['_sortAndFilterDiffChanges'](_0x5715e0){const _0x427ad9=[],_0x509a0e=new Map();for(const _0xeb4f33 of this['editor']['model']['document']['getRootNames']()){const _0x3f9636=this['editor']['editing']['view']['getDomRoot'](_0xeb4f33);if(!_0x3f9636)continue;const _0x2566e6=_0x3f9636['getClientRects']()['item'](0x0);_0x2566e6&&(_0x427ad9['push'](_0xeb4f33),_0x509a0e['set'](_0xeb4f33,_0x2566e6));}return _0x427ad9['sort']((_0x214d05,_0x57fd7c)=>{const _0x2c1e3b=_0x509a0e['get'](_0x214d05),_0x4a6c7c=_0x509a0e['get'](_0x57fd7c);return _0x2c1e3b['y']-_0x4a6c7c['y']||_0x2c1e3b['x']-_0x4a6c7c['x'];}),(_0x5715e0=_0x5715e0['filter'](_0x82804c=>_0x427ad9['includes'](_0x82804c['rootName'])))['sort']((_0x174fd1,_0x4260ca)=>_0x427ad9['indexOf'](_0x174fd1['rootName'])-_0x427ad9['indexOf'](_0x4260ca['rootName'])),_0x5715e0;}['_makeTape'](_0x4c45b9){const _0x6a585b=Array['from'](_0x4c45b9['markers'])['filter'](([_0x48141f,_0x4407cf])=>_0x48141f['startsWith']('revision:')&&!_0x4407cf['isCollapsed']),_0x284d12=Array['from'](this['editor']['model']['createRangeIn'](_0x4c45b9)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x6a585b['length'])for(const _0x236036 of _0x284d12){const [_0x46af32,_0x106c1c]=_0x6a585b[0x0],[,_0x43912c,_0x28c36e]=_0x46af32['split'](':');if(_0x106c1c['end']['isEqual'](_0x236036['nextPosition'])&&_0x6a585b['shift'](),(_0x236036['previousPosition']['isEqual'](_0x106c1c['start'])||_0x236036['previousPosition']['isAfter'](_0x106c1c['start']))&&('insertion'==_0x43912c?_0x236036['isAdded']={'userId':_0x28c36e}:'deletion'==_0x43912c&&(_0x236036['isRemoved']={'userId':_0x28c36e})),0x0==_0x6a585b['length'])break;}return _0x284d12;}['_refreshStartEndIndex'](_0xf72f09){const _0x4a0838=new Map();for(let _0x5940e3=0x0;_0x5940e3<_0xf72f09['length'];_0x5940e3++)'text'===_0xf72f09[_0x5940e3]['type']?(_0xf72f09[_0x5940e3]['item']['startIndex']=_0x5940e3,_0xf72f09[_0x5940e3]['item']['endIndex']=_0x5940e3):('elementStart'===_0xf72f09[_0x5940e3]['type']?_0xf72f09[_0x5940e3]['item']['startIndex']=_0x5940e3:'elementEnd'===_0xf72f09[_0x5940e3]['type']&&(_0xf72f09[_0x5940e3]['item']['endIndex']=_0x5940e3),_0x4a0838['set'](_0xf72f09[_0x5940e3]['id'],_0x5940e3));for(const _0x4a3ae4 of _0x4a0838['values']())'elementStart'===_0xf72f09[_0x4a3ae4]['type']?_0xf72f09[_0x4a3ae4]['item']['endIndex']=_0x4a0838['get'](_0xf72f09[_0x4a3ae4]['pairId']):'elementEnd'===_0xf72f09[_0x4a3ae4]['type']&&(_0xf72f09[_0x4a3ae4]['item']['startIndex']=_0x4a0838['get'](_0xf72f09[_0x4a3ae4]['pairId']));}['_processTape'](_0x30f16f){for(let _0x502610=0x0;_0x502610<_0x30f16f['length'];_0x502610++){if('elementStart'===_0x30f16f[_0x502610]['type'])_0x30f16f[_0x502610]['item']['startIndex']=_0x502610;else{if('elementEnd'===_0x30f16f[_0x502610]['type']){_0x30f16f[_0x502610]['item']['endIndex']=_0x502610;const _0x38df4c=_0x30f16f[_0x502610]['item']['startIndex'];_0x30f16f[_0x38df4c]['pairId']=_0x30f16f[_0x502610]['id'],_0x30f16f[_0x502610]['pairId']=_0x30f16f[_0x38df4c]['id'];}else _0x30f16f[_0x502610]['item']['startIndex']=_0x502610,_0x30f16f[_0x502610]['item']['endIndex']=_0x502610,_0x30f16f[_0x502610]['pairId']=null;}_0x30f16f[_0x502610]['markersStart']||(_0x30f16f[_0x502610]['markersStart']=[],_0x30f16f[_0x502610]['markersEnd']=[]);}}['_markInsertions'](_0x830314,_0x160bea){const _0x4115cf=_0x830314['filter'](_0x583563=>!_0x583563['isAdded']);for(let _0x432e7d=0x0;_0x432e7d<_0x160bea['length'];_0x432e7d++)_0x160bea[_0x432e7d]['isAdded']&&(_0x4115cf[_0x432e7d]['isAdded']=_0x160bea[_0x432e7d]['isAdded']);}['_getDiff'](_0x5e148d,_0x4d80cc=null){const _0x550280=this['repository']['getRevision'](_0x5e148d),_0x19a827=_0x4d80cc?this['repository']['getRevision'](_0x4d80cc):null,_0xb63321=this['_getRevisionsRange'](_0x550280,_0x19a827),_0x5b20a0=_0xb63321[_0xb63321['length']-0x1],_0x5d7ca3=new Map(),_0x22275c={'model':{},'attributes':{},'changes':[]},_0x44ebc0=new Set(),_0x38bef8=new Map();for(let _0x4656a6=_0xb63321['length']-0x1;_0x4656a6>=0x0;_0x4656a6--){const _0x2c2707=_0xb63321[_0x4656a6];for(const _0x413c0d of Object['keys'](_0x2c2707['diffData']))if(_0x2c2707['diffData'][_0x413c0d]['attachChange']){const _0x36cfca=_0x2c2707['diffData'][_0x413c0d]['attachChange'];_0x36cfca['isAttached']?(_0x44ebc0['add'](_0x413c0d),_0x38bef8['has'](_0x413c0d)&&_0x38bef8['get'](_0x413c0d)['userId']==_0x36cfca['userId']?_0x38bef8['delete'](_0x413c0d):_0x38bef8['set'](_0x413c0d,_0x36cfca)):_0x38bef8['has'](_0x413c0d)?(_0x44ebc0['delete'](_0x413c0d),_0x38bef8['delete'](_0x413c0d)):(_0x44ebc0['add'](_0x413c0d),_0x38bef8['set'](_0x413c0d,_0x36cfca));}else _0x44ebc0['add'](_0x413c0d);}for(const _0x534c34 of _0x44ebc0){const _0x51edf8=_0x38bef8['has'](_0x534c34)&&!_0x38bef8['get'](_0x534c34)['isAttached'];let _0x3c717b=_0x51edf8?_0xb63321['length']-0x1:0x0;const _0x53ae5f=_0x51edf8?-0x1:0x1;for(;_0xb63321[_0x3c717b];){const _0x1d08e4=_0xb63321[_0x3c717b];if(_0x1d08e4['diffData'][_0x534c34]){const _0x1ff1c9=_0x51edf8?_0x1d08e4['diffData'][_0x534c34]['attributesBefore']:_0x1d08e4['diffData'][_0x534c34]['attributesAfter'];_0x22275c['attributes'][_0x534c34]=_0x1ff1c9?_0x204d12(_0x1ff1c9):{};break;}_0x3c717b+=_0x53ae5f;}}for(const _0x5438e4 of _0xb63321){_0x5438e4['model']={};for(const _0x522fda of _0x5438e4['authors'])_0x5d7ca3['set'](_0x522fda['id'],_0x522fda);for(const _0x110e07 of _0x44ebc0){const _0x729c4c=_0x5438e4['diffData'][_0x110e07]?_0x5438e4['diffData'][_0x110e07]['insertions']:'[]',_0xf27406=_0x5438e4['diffData'][_0x110e07]?_0x5438e4['diffData'][_0x110e07]['deletions']:'[]';_0x5438e4['model'][_0x110e07]={'insertions':this['_utils']['_makeModelFromViewString'](_0x729c4c),'deletions':this['_utils']['_makeModelFromViewString'](_0xf27406)};}}for(const _0x5b981f of _0x44ebc0){let _0x248d08=null,_0x88d3aa=0x0;const _0x1b5b10=new Map(Array['from'](_0x550280['model'][_0x5b981f]['insertions']['markers'])['filter'](([_0x52864a])=>!_0x52864a['startsWith']('revision:')));let _0x297222=0x0;for(const _0x1f2bff of _0xb63321){const _0x270f5f=this['_makeTape'](_0x1f2bff['model'][_0x5b981f]['insertions']);_0x1f2bff==_0x550280?(_0x248d08=_0x270f5f,_0x88d3aa=_0x248d08['length'],_0x248d08['forEach'](_0x280608=>{_0x280608['id']=_0x297222++;}),this['_processTape'](_0x248d08)):this['_markInsertions'](_0x248d08,_0x270f5f);const _0x536144=_0x248d08['filter'](_0x5f1955=>!_0x5f1955['isAdded'])['map'](_0x511662=>_0x511662['id']);let _0x34a252=0x0;const _0xc4f40c=this['_makeTape'](_0x1f2bff['model'][_0x5b981f]['deletions']);_0xc4f40c['forEach'](_0x32cc36=>{_0x32cc36['isRemoved']?_0x32cc36['id']=_0x88d3aa++:_0x32cc36['id']=_0x536144[_0x34a252++];}),this['_processTape'](_0xc4f40c),this['_setDistance'](_0x248d08,'isAdded'),this['_setDistance'](_0xc4f40c,'isRemoved'),_0x1f2bff==_0x550280&&this['_markMarkers'](_0x248d08,_0x1b5b10),_0x248d08=this['_joinTapes'](_0x248d08,_0xc4f40c),this['_refreshStartEndIndex'](_0x248d08),this['_setDistance'](_0x248d08,'isRemoved');}_0x248d08=_0x248d08['filter'](_0x36d4e9=>!(_0x36d4e9['isAdded']&&_0x36d4e9['isRemoved']));const _0x3c12d3=new Map(_0x5b20a0['model'][_0x5b981f]['deletions']['markers']),_0x55e191=new Set(_0x1b5b10['keys']());for(const _0x4f2762 of _0x3c12d3['keys']())_0x55e191['delete'](_0x4f2762);this['_markSuggestions'](_0x248d08,_0x55e191),this['_fixObsoleteTags'](_0x248d08),_0x248d08=this['_removeMissingPairs'](_0x248d08),_0x248d08=this['_markMismatchedRemovedTags'](_0x248d08),_0x248d08=this['_removeUnsupportedChanges'](_0x248d08);const {root:_0x44438e,changes:_0x203a5b}=this['_makeModelFromTape'](_0x248d08,_0x5d7ca3,_0x5b981f);_0x22275c['model'][_0x5b981f]=_0x44438e;const _0x5d0a7b=_0x38bef8['get'](_0x5b981f);if(_0x5d0a7b){const _0x3d1d04=_0x5d7ca3['get'](_0x5d0a7b['userId']),_0x131839=new G({'author':_0x3d1d04,'type':_0x5d0a7b['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x5b981f});_0x203a5b['unshift'](_0x131839),_0x22275c['attributes'][_0x5b981f]['revisionHistoryAttachChange']=_0x131839['id'];}_0x22275c['changes']=_0x22275c['changes']['concat'](_0x203a5b);}return _0x22275c;}['_markMarkers'](_0x191051,_0x3b5ec3){for(let _0x3808bd=0x0;_0x3808bd<_0x191051['length'];_0x3808bd++)for(const [_0x68ae7f,_0x16da5d]of _0x3b5ec3)!_0x16da5d['isCollapsed']&&_0x16da5d['start']['isEqual'](_0x191051[_0x3808bd]['previousPosition'])&&_0x191051[_0x3808bd]['markersStart']['push'](_0x68ae7f),_0x16da5d['end']['isEqual'](_0x191051[_0x3808bd]['nextPosition'])&&_0x191051[_0x3808bd]['markersEnd']['push'](_0x68ae7f);}['_joinTapes'](_0x3cdaaa,_0x53c221){let _0x182e9d=[],_0x5af2bd=0x0,_0x1e007a=0x0;for(;_0x5af2bd<_0x3cdaaa['length']||_0x1e007a<_0x53c221['length'];){const _0x12f031=_0x3cdaaa[_0x5af2bd]||{},_0x5ad78d=_0x53c221[_0x1e007a]||{};if(_0x12f031['id']==_0x5ad78d['id'])_0x5af2bd++,_0x1e007a++,_0x182e9d['push'](_0x12f031);else{if(_0x5ad78d['isRemoved']&&_0x12f031['isAdded']){const {commonTape:_0x1a4a45,iEnd:_0x38ee46,jEnd:_0x12a815}=this['_threeWayMerge'](_0x3cdaaa,_0x5af2bd,_0x53c221,_0x1e007a);_0x182e9d=_0x182e9d['concat'](_0x1a4a45),_0x5af2bd=_0x38ee46,_0x1e007a=_0x12a815;}else _0x5ad78d['isRemoved']?(_0x1e007a++,_0x182e9d['push'](_0x5ad78d)):(_0x5af2bd++,_0x182e9d['push'](_0x12f031));}}return _0x182e9d;}['_markSuggestions'](_0x4f8cc5,_0xa5bd19){const _0x2c600b=[];for(let _0xa806f1=0x0;_0xa806f1<_0x4f8cc5['length'];_0xa806f1++){for(let _0x282084=0x0;_0x282084<_0x4f8cc5[_0xa806f1]['markersStart']['length'];_0x282084++){const _0x28ad5c=_0x4f8cc5[_0xa806f1]['markersStart'][_0x282084];if(!_0xa5bd19['has'](_0x28ad5c))continue;const {group:_0x35cd91,type:_0x4fc07b,authorId:_0x1960d3}=_0x225650(_0x28ad5c);'revision-suggestion'!=_0x35cd91||'insertion'!=_0x4fc07b&&'deletion'!=_0x4fc07b||(_0x2c600b['unshift']({'type':_0x4fc07b,'name':_0x28ad5c,'userId':_0x1960d3}),_0x4f8cc5[_0xa806f1]['markersStart']['splice'](_0x282084,0x1),_0x282084--);}_0x4374ce(_0x4f8cc5[_0xa806f1]);for(let _0x343b53=0x0;_0x343b53<_0x4f8cc5[_0xa806f1]['markersEnd']['length'];_0x343b53++){const _0x52f73c=_0x4f8cc5[_0xa806f1]['markersEnd'][_0x343b53];if(!_0xa5bd19['has'](_0x52f73c))continue;const {group:_0x217c0c,type:_0xef0e38}=_0x225650(_0x52f73c);if('revision-suggestion'!=_0x217c0c||'insertion'!=_0xef0e38&&'deletion'!=_0xef0e38)continue;_0x4f8cc5[_0xa806f1]['markersEnd']['splice'](_0x343b53,0x1),_0x343b53--;const _0x596a61=_0x2c600b['findIndex'](_0x3fd288=>_0x3fd288['name']==_0x52f73c);_0x596a61>-0x1&&_0x2c600b['splice'](_0x596a61,0x1);}}function _0x225650(_0x5709e6){const _0x12ad99=_0x5709e6['split'](':');return{'group':_0x12ad99[0x0],'type':_0x12ad99[0x1],'subType':_0x12ad99['length']>=0x5?_0x12ad99[0x2]:null,'id':_0x12ad99['length']<0x5?_0x12ad99[0x2]:_0x12ad99[0x3],'authorId':_0x12ad99['length']<0x5?_0x12ad99[0x3]:_0x12ad99[0x4],'markerCount':0x6==_0x12ad99['length']?_0x12ad99[0x5]:null};}function _0x4374ce(_0xdb6620){for(let _0x148c0a=0x0;_0x148c0a<_0x2c600b['length'];_0x148c0a++){if(_0xdb6620['isAdded']&&'insertion'==_0x2c600b[_0x148c0a]['type']&&_0xdb6620['isAdded']['userId']==_0x2c600b[_0x148c0a]['userId'])return _0xdb6620['isAddSuggestion']=_0x2c600b[_0x148c0a],void delete _0xdb6620['isAdded'];if(!_0xdb6620['isAdded']&&!_0xdb6620['isRemoved']&&'deletion'==_0x2c600b[_0x148c0a]['type'])return void(_0xdb6620['isRemoveSuggestion']=_0x2c600b[_0x148c0a]);}}}['_setDistance'](_0x4f7387,_0x412724){let _0x4354ac=0x0,_0x57b629=!0x1;const _0x435ed2=new Map();for(const _0x4b572b of _0x4f7387)_0x4b572b[_0x412724]?_0x57b629&&(_0x4354ac++,_0x57b629=!0x1):(_0x4354ac++,_0x57b629=!0x0),_0x435ed2['set'](_0x4b572b['id'],_0x4354ac);for(let _0x46de09=0x0;_0x46de09<_0x4f7387['length'];_0x46de09++){if('isRemoved'==_0x412724&&_0x4f7387[_0x46de09]['isAdded']||'isAdded'==_0x412724&&_0x4f7387[_0x46de09]['isRemoved'])continue;if('text'==_0x4f7387[_0x46de09]['type']){_0x4f7387[_0x46de09]['distance']=0x0;continue;}const _0x24d26c=_0x435ed2['get'](_0x4f7387[_0x46de09]['pairId']),_0x3469f6=_0x435ed2['get'](_0x4f7387[_0x46de09]['id']);_0x4f7387[_0x46de09]['distance']=_0x24d26c-_0x3469f6;}}['_getRevisionsRange'](_0x2bbe37,_0x2d8ce0,_0x41ae48=!0x1){const _0x33b1e4=[];let _0x18c88f=this['repository']['getIndex'](_0x2bbe37),_0x4080de=this['repository']['getIndex'](_0x2d8ce0);for(-0x1==_0x4080de&&(_0x4080de=this['repository']['_revisions']['length'],_0x41ae48=!0x1);_0x18c88f<_0x4080de;)_0x33b1e4['push'](this['repository']['getRevision'](_0x18c88f)),_0x18c88f++;return _0x41ae48&&_0x33b1e4['push'](this['repository']['getRevision'](_0x18c88f)),_0x33b1e4;}['_threeWayMerge'](_0x3f0cea,_0x229463,_0x119e7b,_0x5a1794){const _0x45f9d1=this['editor']['model']['schema'];let _0x5f56c8=_0x229463;for(;_0x3f0cea[_0x5f56c8]&&_0x3f0cea[_0x5f56c8]['isAdded'];)_0x5f56c8++;let _0x44516c=_0x5a1794;for(;_0x119e7b[_0x44516c]&&_0x119e7b[_0x44516c]['isRemoved'];)_0x44516c++;_0x4bd8e5(_0x3f0cea,_0x229463,_0x5f56c8),_0x4bd8e5(_0x119e7b,_0x5a1794,_0x44516c);const _0x4533da=_0x119e7b['slice'](_0x5a1794,_0x44516c)['concat'](_0x3f0cea['slice'](_0x229463,_0x5f56c8));return _0x4533da['sort']((_0x39cb2b,_0x98bf25)=>_0x39cb2b['side']!=_0x98bf25['side']?_0x39cb2b['side']-_0x98bf25['side']:_0x39cb2b['level']!=_0x98bf25['level']?_0x39cb2b['level']-_0x98bf25['level']:_0x39cb2b['distance']!=_0x98bf25['distance']?_0x98bf25['distance']-_0x39cb2b['distance']:!!_0x39cb2b['isAdded']!=!!_0x98bf25['isAdded']?-0x1==_0x39cb2b['side']||0x0==_0x39cb2b['side']?_0x39cb2b['isAdded']?-0x1:0x1:_0x39cb2b['isAdded']?0x1:-0x1:_0x39cb2b['index']-_0x98bf25['index']),{'commonTape':_0x4533da,'iEnd':_0x5f56c8,'jEnd':_0x44516c};function _0x4bd8e5(_0x246b86,_0x1cd1f4,_0x358bde){let _0x39196c=-0x1,_0x107e89=Number['POSITIVE_INFINITY'],_0x37ea85=!0x0;for(let _0x6ed4cd=_0x1cd1f4;_0x6ed4cd<_0x358bde;_0x6ed4cd++)if(_0x45f9d1['isInline'](_0x246b86[_0x6ed4cd]['item'])||(_0x37ea85=!0x1),_0x246b86[_0x6ed4cd]['item']['startIndex']<_0x1cd1f4&&(_0x39196c=_0x6ed4cd),_0x246b86[_0x6ed4cd]['item']['endIndex']>=_0x358bde){_0x107e89=_0x6ed4cd;break;}_0x37ea85&&(_0x39196c=_0x358bde-0x1);for(let _0x4d2947=_0x1cd1f4;_0x4d2947<_0x358bde;_0x4d2947++)_0x246b86[_0x4d2947]['side']=_0x4d2947<=_0x39196c?-0x1:_0x4d2947<_0x107e89?0x0:0x1,_0x246b86[_0x4d2947]['index']=_0x4d2947;let _0x3c66c6=0x0;for(let _0x39bda1=_0x1cd1f4;_0x39bda1<=_0x39196c;_0x39bda1++)0x0==_0x246b86[_0x39bda1]['distance']?_0x246b86[_0x39bda1]['level']=_0x3c66c6:(_0x3c66c6++,_0x246b86[_0x39bda1]['level']=_0x3c66c6,_0x3c66c6++);for(let _0x5e017e=_0x1cd1f4;_0x5e017e<_0x358bde;_0x5e017e++)0x0==_0x246b86[_0x5e017e]['side']&&(_0x246b86[_0x5e017e]['level']=_0x3c66c6);_0x3c66c6=0x0;for(let _0x2bc143=_0x358bde-0x1;_0x2bc143>=_0x107e89;_0x2bc143--)0x0==_0x246b86[_0x2bc143]['distance']?_0x246b86[_0x2bc143]['level']=_0x3c66c6:(_0x3c66c6--,_0x246b86[_0x2bc143]['level']=_0x3c66c6,_0x3c66c6--);}}['_fixObsoleteTags'](_0x5376e0){const _0x124863=new Map(),_0x2731af=this['editor']['model']['schema'];for(let _0x1134e5=0x1;_0x1134e5<_0x5376e0['length'];_0x1134e5++){let _0x124765,_0x3f62ce,_0x4475c3;const _0x53a55e=_0x5376e0[_0x1134e5],_0x77e730=_0x5376e0[_0x1134e5-0x1];if('text'==_0x53a55e['type'])continue;if(_0x53a55e['type']!=_0x77e730['type'])continue;if(!_0x2731af['isBlock'](_0x77e730['item'])||_0x2731af['isLimit'](_0x77e730['item']))continue;if(!_0x2731af['isBlock'](_0x53a55e['item'])||_0x2731af['isLimit'](_0x53a55e['item']))continue;if((_0x5376e0[_0x1134e5]['isAdded']||_0x5376e0[_0x1134e5]['isAddSuggestion'])&&_0x5376e0[_0x1134e5-0x1]['isRemoved'])_0x124765=_0x5376e0[_0x1134e5],_0x3f62ce=_0x5376e0[_0x1134e5-0x1],_0x4475c3=_0x1134e5-0x1;else{if(!_0x5376e0[_0x1134e5]['isRemoved']||!_0x5376e0[_0x1134e5-0x1]['isAdded']&&!_0x5376e0[_0x1134e5-0x1]['isAddSuggestion'])continue;_0x124765=_0x5376e0[_0x1134e5-0x1],_0x3f62ce=_0x5376e0[_0x1134e5],_0x4475c3=_0x1134e5;}const _0x529a1c=_0x124765['level']==_0x3f62ce['level'],_0x2c6a7f=Math['abs'](_0x124765['level'])<Math['abs'](_0x3f62ce['level'])&&0x0==_0x3f62ce['distance'];(_0x529a1c||_0x2c6a7f)&&(_0x124863['set'](_0x3f62ce['id'],_0x124765['id']),_0x5376e0['splice'](_0x4475c3,0x1),_0x1134e5--,_0x124765['isAdded']=!0x1);}for(let _0x4ca0ee=0x0;_0x4ca0ee<_0x5376e0['length'];_0x4ca0ee++)_0x124863['has'](_0x5376e0[_0x4ca0ee]['pairId'])&&(_0x5376e0[_0x4ca0ee]['pairId']=_0x124863['get'](_0x5376e0[_0x4ca0ee]['pairId']));}['_removeMissingPairs'](_0x37389f){const _0x99496a=new Set(_0x37389f['map'](_0x40fd0b=>_0x40fd0b['id']));for(let _0x42b940=0x0;_0x42b940<_0x37389f['length'];_0x42b940++)_0x99496a['has'](_0x37389f[_0x42b940]['pairId'])||0x0==_0x37389f[_0x42b940]['distance']||(_0x37389f[_0x42b940]['isIncorrect']=!0x0);return _0x37389f['filter'](_0xd86d85=>!_0xd86d85['isIncorrect']);}['_markMismatchedRemovedTags'](_0x6a7c86){const _0x56029e=new Set();for(let _0x1212ba=0x0;_0x1212ba<_0x6a7c86['length'];_0x1212ba++){if(_0x56029e['has'](_0x6a7c86[_0x1212ba]['id'])&&_0x6a7c86[_0x1212ba]['isRemoved']&&(_0x6a7c86[_0x1212ba]['isIncorrect']=!0x0),_0x6a7c86[_0x1212ba]['isIncorrect'])continue;if(0x0==_0x6a7c86[_0x1212ba]['distance'])continue;if('elementStart'!=_0x6a7c86[_0x1212ba]['type'])continue;if(null==_0x6a7c86[_0x1212ba]['pairId'])continue;let _0x1953e3=_0x1212ba+0x1,_0x47c4eb=0x0;for(;_0x6a7c86[_0x1953e3]['id']!=_0x6a7c86[_0x1212ba]['pairId'];)'elementStart'==_0x6a7c86[_0x1953e3]['type']?_0x47c4eb++:'elementEnd'==_0x6a7c86[_0x1953e3]['type']&&_0x47c4eb--,_0x1953e3++;if(0x0!=_0x47c4eb){if(_0x6a7c86[_0x1212ba]['isRemoved'])_0x6a7c86[_0x1212ba]['isIncorrect']=!0x0;else{for(;_0x1953e3!=_0x1212ba;)_0x6a7c86[_0x1953e3]['isRemoved']&&0x0!=_0x6a7c86[_0x1953e3]['distance']&&(_0x6a7c86[_0x1953e3]['isIncorrect']=!0x0,_0x56029e['add'](_0x6a7c86[_0x1953e3]['pairId'])),_0x1953e3--;}}}return _0x6a7c86['filter'](_0xd4c495=>!_0xd4c495['isIncorrect']);}['_removeUnsupportedChanges'](_0x33a35d){const _0x4f0580=this['editor']['model']['schema'];for(let _0x2709f4=0x0;_0x2709f4<_0x33a35d['length'];_0x2709f4++){if(!(_0x33a35d[_0x2709f4]['isAdded']||_0x33a35d[_0x2709f4]['isAddSuggestion']||_0x33a35d[_0x2709f4]['isRemoved']||_0x33a35d[_0x2709f4]['isRemoveSuggestion']))continue;if(0x0==_0x33a35d[_0x2709f4]['distance'])continue;const _0x364f4f=_0x33a35d[_0x2709f4]['item'];_0x4f0580['isBlock'](_0x364f4f)||_0x4f0580['isLimit'](_0x364f4f)||(_0x33a35d[_0x2709f4]['isAdded']&&delete _0x33a35d[_0x2709f4]['isAdded'],_0x33a35d[_0x2709f4]['isAddSuggestion']&&delete _0x33a35d[_0x2709f4]['isAddSuggestion'],_0x33a35d[_0x2709f4]['isRemoveSuggestion']&&delete _0x33a35d[_0x2709f4]['isRemoveSuggestion'],_0x33a35d[_0x2709f4]['isRemoved']&&(_0x33a35d[_0x2709f4]['isIncorrect']=!0x0));}return _0x33a35d['filter'](_0x10efc5=>!_0x10efc5['isIncorrect']);}['_makeModelFromTape'](_0xc7f521,_0x21db16,_0x8902bc){const _0x50e28a=new _0x3fb9bd(),_0x34d570=[],_0x46cec8=new Map(),_0x18f9f5=this['editor']['model'],_0x5a4001=_0x18f9f5['schema'],_0x57012d=[_0x50e28a],_0x5a2f9a={},_0x3b90e9={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x3b8022=null;const _0x28c360=[0x0];for(let _0x1f3420=0x0;_0x1f3420<_0xc7f521['length'];_0x1f3420++)if('elementStart'===_0xc7f521[_0x1f3420]['type']){_0xc7f521[_0x1f3420]['previousPosition']=_0x18f9f5['createPositionFromPath'](_0x50e28a,_0x28c360);const _0x148d00=new _0x5acc5d(_0xc7f521[_0x1f3420]['item']['name'],_0xc7f521[_0x1f3420]['item']['getAttributes']());_0x57012d[0x0]['_appendChild'](_0x148d00),_0x28c360['push'](0x0),_0x57012d['unshift'](_0x148d00),_0xc7f521[_0x1f3420]['nextPosition']=_0x18f9f5['createPositionFromPath'](_0x50e28a,_0x28c360);}else'elementEnd'===_0xc7f521[_0x1f3420]['type']?(_0x57012d['shift'](),_0xc7f521[_0x1f3420]['previousPosition']=_0x18f9f5['createPositionFromPath'](_0x50e28a,_0x28c360),_0x28c360['pop'](),_0x28c360[_0x28c360['length']-0x1]++,_0xc7f521[_0x1f3420]['nextPosition']=_0x18f9f5['createPositionFromPath'](_0x50e28a,_0x28c360)):(_0xc7f521[_0x1f3420]['previousPosition']=_0x18f9f5['createPositionFromPath'](_0x50e28a,_0x28c360),_0x3b8022?_0x3b8022['_data']+=_0xc7f521[_0x1f3420]['item']['data']:_0x3b8022=new _0x558b43(_0xc7f521[_0x1f3420]['item']['data'],_0xc7f521[_0x1f3420]['item']['getAttributes']()),_0xc7f521[_0x1f3420+0x1]&&'text'===_0xc7f521[_0x1f3420+0x1]['type']&&_0x5942db(_0x3b8022,_0xc7f521[_0x1f3420+0x1]['item'])||(_0x57012d[0x0]['_appendChild'](_0x3b8022),_0x3b8022=null),_0x28c360[_0x28c360['length']-0x1]+=_0xc7f521[_0x1f3420]['item']['offsetSize'],_0xc7f521[_0x1f3420]['nextPosition']=_0x18f9f5['createPositionFromPath'](_0x50e28a,_0x28c360));for(let _0x1e699f=0x0;_0x1e699f<_0xc7f521['length'];_0x1e699f++){const _0x5d7b2b=_0xc7f521[_0x1e699f]['previousPosition'],_0x57d597=_0xc7f521[_0x1e699f]['nextPosition'];for(const _0x11cb41 of _0xc7f521[_0x1e699f]['markersStart'])_0x46cec8['set'](_0x11cb41,{'start':_0x5d7b2b,'end':null});_0xf2a674('isRemoveSuggestion',_0x1e699f,_0x5d7b2b,_0x57d597),_0xf2a674('isAddSuggestion',_0x1e699f,_0x5d7b2b,_0x57d597),_0xf2a674('isRemoved',_0x1e699f,_0x5d7b2b,_0x57d597),_0xf2a674('isAdded',_0x1e699f,_0x5d7b2b,_0x57d597);for(const _0xbfe554 of _0xc7f521[_0x1e699f]['markersEnd']){const _0x2f1813=_0x46cec8['get'](_0xbfe554);_0x2f1813?_0x2f1813['end']=_0x57d597:_0x46cec8['set'](_0xbfe554,{'start':_0x57d597,'end':_0x57d597});}}for(const [_0xe5e1f6,_0x3fd6eb]of _0x46cec8){const _0x2791bf=this['editor']['model']['createRange'](_0x3fd6eb['start'],_0x3fd6eb['end']);_0x50e28a['markers']['set'](_0xe5e1f6,_0x2791bf);}return _0x34d570['sort']((_0x48b8f5,_0x49ce39)=>{const _0x540b2a=_0x50e28a['markers']['get']('revision:'+_0x48b8f5['id']),_0x142add=_0x50e28a['markers']['get']('revision:'+_0x49ce39['id']);return _0x540b2a['start']['isBefore'](_0x142add['start'])?-0x1:_0x540b2a['start']['isAfter'](_0x142add['start'])?0x1:_0x540b2a['end']['isBefore'](_0x142add['end'])?-0x1:_0x540b2a['end']['isAfter'](_0x142add['end'])?0x1:'add'===_0x48b8f5['type']?-0x1:0x1;}),{'root':_0x50e28a,'changes':_0x34d570};function _0xf2a674(_0x269e6b,_0x21c6a6,_0x282c10,_0x5cfcdf){const _0x4bfb37=!!_0xc7f521[_0x21c6a6][_0x269e6b],_0x44c3ed=_0x4bfb37?_0xc7f521[_0x21c6a6][_0x269e6b]['userId']:null,_0x2b30c7=_0x21c6a6===_0xc7f521['length']-0x1,_0x5cc0e4=_0x3b90e9[_0x269e6b][0x0],_0x17b1d7=_0x5a4001['isObject'](_0xc7f521[_0x21c6a6]['item']);!_0x5a2f9a[_0x269e6b]&&_0x4bfb37?_0x5a2f9a[_0x269e6b]={'start':_0x282c10,'tapeItem':_0xc7f521[_0x21c6a6],'userId':_0x44c3ed,'type':_0x269e6b}:_0x5a2f9a[_0x269e6b]&&!_0x4bfb37?(_0x5a2f9a[_0x269e6b]['end']=_0x282c10,_0x151873(_0x5a2f9a[_0x269e6b]),_0x5a2f9a[_0x269e6b]=null):_0x5a2f9a[_0x269e6b]&&_0x4bfb37&&_0x5a2f9a[_0x269e6b]['userId']!==_0x44c3ed&&(_0x5a2f9a[_0x269e6b]['end']=_0x282c10,_0x5cc0e4&&_0x5cc0e4['userId']===_0x5a2f9a[_0x269e6b]['userId']||_0x151873(_0x5a2f9a[_0x269e6b]),_0x5a2f9a[_0x269e6b]={'start':_0x282c10,'tapeItem':_0xc7f521[_0x21c6a6],'userId':_0x44c3ed,'type':_0x269e6b}),_0x5a2f9a[_0x269e6b]&&_0x17b1d7&&('elementStart'!==_0xc7f521[_0x21c6a6]['type']||_0x5cc0e4&&_0x5cc0e4['userId']===_0x44c3ed||_0x3b90e9[_0x269e6b]['unshift']({'userId':_0x44c3ed,'object':_0xc7f521[_0x21c6a6]['item'],'change':_0x5a2f9a[_0x269e6b]}),'elementEnd'===_0xc7f521[_0x21c6a6]['type']&&_0x5cc0e4&&_0x5cc0e4['object']===_0xc7f521[_0x21c6a6]['item']&&(_0x3b90e9[_0x269e6b]['shift'](),_0x5a2f9a[_0x269e6b]=_0x5cc0e4['change'])),_0x5a2f9a[_0x269e6b]&&_0x2b30c7&&(_0x5a2f9a[_0x269e6b]['end']=_0x5cfcdf,_0x151873(_0x5a2f9a[_0x269e6b]),_0x5a2f9a[_0x269e6b]=null);}function _0x151873({start:_0x4856f3,end:_0x3e02af,tapeItem:_0x218abe,userId:_0x1dd655,type:_0x264d02}){const _0x4d48b6=_0x218abe['item'],_0x10ba24=_0x18f9f5['schema']['isBlock'](_0x4d48b6)&&!_0x18f9f5['schema']['isLimit'](_0x4d48b6),_0x3854aa=_0x4856f3['nodeAfter']==_0x3e02af['parent']&&_0x3e02af['isAtStart'];if(_0x10ba24&&_0x3854aa)return;const _0x252eab=_0x18f9f5['createRange'](_0x4856f3,_0x3e02af),_0x2ffc6a=_0x21db16['get'](_0x1dd655),_0x5130e4=new G({'author':_0x2ffc6a,'type':'isAdded'==_0x264d02||'isAddSuggestion'==_0x264d02?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x264d02||'isRemoveSuggestion'==_0x264d02},'createdAt':new Date(),'rootName':_0x8902bc});_0x34d570['push'](_0x5130e4),_0x50e28a['markers']['set']('revision:'+_0x5130e4['id'],_0x252eab);}function _0x5942db(_0x146364,_0x3ffa33){const _0x341c12=_0x146364['getAttributes'](),_0x296617=_0x3ffa33['getAttributes']();for(const _0x290847 of _0x341c12){if(_0x290847[0x1]!==_0x3ffa33['getAttribute'](_0x290847[0x0]))return!0x1;_0x296617['next']();}return _0x296617['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x36a3ef=>{const _0x1349d2=_0x36a3ef['markerName']['split'](':')[0x1],_0x2f4710=this['_getChangeFromId'](_0x1349d2);if(!_0x2f4710)return null;const _0x12d9b5='add'==_0x2f4710['type']?'insertion':'deletion',_0x26d391=['ck-suggestion-marker','ck-suggestion-marker-'+_0x12d9b5];return _0x2f4710['data']['isSuggestion']&&_0x26d391['push']('ck-suggestion-marker-'+_0x12d9b5+'-new'),this['activeChange']==_0x2f4710&&_0x26d391['push']('ck-suggestion-marker--active'),{'classes':_0x26d391,'attributes':{'data-change-id':_0x1349d2}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x399630=>{_0x399630['on']('element:pre',(_0x119291,_0x9e057b,_0xd510f0)=>{const _0x7c993=_0x9e057b['viewItem']['getChild'](0x0);if(!_0x7c993||!_0x7c993['is']('element','code'))return;if(!_0xd510f0['consumable']['consume'](_0x7c993,{'attributes':['vid_start','vid_end']}))return;const _0x4ffed9=_0x9e057b['modelRange']['start']['nodeAfter'];_0xd510f0['writer']['setAttribute']('vid_start',_0x7c993['getAttribute']('vid_start'),_0x4ffed9),_0xd510f0['writer']['setAttribute']('vid_end',_0x7c993['getAttribute']('vid_end'),_0x4ffed9);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x34a5fb=>{_0x34a5fb['on']('element',(_0x34ebbf,_0x4e8dbb,_0x13d86a)=>{if(!_0x13d86a['consumable']['consume'](_0x4e8dbb['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x4e8dbb['modelRange']['isCollapsed'])return;const _0x27f6de=_0x4e8dbb['modelRange']['start']['nodeAfter'];_0x27f6de['hasAttribute']('vid_start')||_0x27f6de['hasAttribute']('vid')||(_0x13d86a['writer']['setAttribute']('vid_start',_0x4e8dbb['viewItem']['getAttribute']('vid_start'),_0x27f6de),_0x13d86a['writer']['setAttribute']('vid_end',_0x4e8dbb['viewItem']['getAttribute']('vid_end'),_0x27f6de));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x49cad6=>_0x49cad6['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x2c71fd,[,_0x3ff153])=>{['vid_start','vid_end','vid']['includes'](_0x3ff153)&&(_0x2c71fd['return']=!0x0,_0x2c71fd['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x1309c7=>{_0x1309c7['on']('attribute:vid',(_0x299683,_0x269c5a,_0x3cb394)=>{if('\x20'!=_0x269c5a['item']['data']||_0x269c5a['item']['parent']['maxOffset']>0x1)return;if(!_0x3cb394['consumable']['consume'](_0x269c5a['item'],_0x299683['name']))return;const _0x4bafdd=_0x3cb394['writer'],_0xa9a12f=_0x3cb394['mapper']['toViewRange'](_0x269c5a['range']);_0x4bafdd['wrap'](_0xa9a12f,_0x4bafdd['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x1a49f4){const _0x511ad2=_0x1a49f4['plugins']['get']('RevisionViewer');return(_0x37b8c0,_0x1069e6,_0x236c2d)=>{const _0x436726=_0x1069e6['markerName']['split'](':')[0x1],_0x164025=_0x511ad2['_getChangeFromId'](_0x436726);if(!_0x164025)return null;const _0x397f1e='add'==_0x164025['type']?'split':'merge';if(!_0x236c2d['consumable']['test'](_0x1069e6['markerRange'],_0x37b8c0['name']))return;const _0x47484f=_0x1069e6['markerRange']['getWalker'](),_0x2d3804=_0x1069e6['markerRange']['start'],_0x474e91=_0x1a49f4['model']['schema'];let _0x5e1d6c=null,_0x311e77=null,_0x19a527=!0x1,_0x533d29=!0x1;for(const _0x17b223 of _0x47484f){const _0x115430=_0x17b223['item'];_0x19a527=_0x19a527||_0x474e91['isContent'](_0x115430);const _0x389835=_0x236c2d['mapper']['toViewElement'](_0x115430);if(_0x389835&&_0x389835['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x17b223['type']&&(_0x474e91['isBlock'](_0x115430)&&!_0x474e91['isLimit'](_0x115430)&&(_0x115430['nextSibling']||_0x2d3804['isAtEnd']?_0x5e1d6c&&_0x5e1d6c['parent']==_0x115430||(_0x5e1d6c=_0x115430,_0x132b3e(_0x17b223['previousPosition']),_0x533d29=!0x0):_0x311e77=_0x311e77||_0x17b223['previousPosition']));}function _0x132b3e(_0x284e1e){const _0xac4b2f=_0x236c2d['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x397f1e}),_0x445582=_0x236c2d['mapper']['toViewPosition'](_0x284e1e);_0x164025['data']['isSuggestion']&&_0x236c2d['writer']['addClass']('ck-suggestion-marker-'+_0x397f1e+'-new',_0xac4b2f),_0x511ad2['activeChange']==_0x164025&&_0x236c2d['writer']['addClass']('ck-suggestion-marker--active',_0xac4b2f),_0x236c2d['writer']['insert'](_0x445582,_0xac4b2f),_0x236c2d['mapper']['bindElementToMarker'](_0xac4b2f,_0x1069e6['markerName']);}_0x19a527||_0x533d29||!_0x311e77||_0x132b3e(_0x311e77);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x1d439c,_0x294dc2,_0x25b083)=>{const _0x38d542=_0x25b083['mapper']['markerNameToElements'](_0x294dc2['markerName']);if(_0x38d542){for(const _0x1b08bf of _0x38d542)(_0x1b08bf['hasClass']('ck-suggestion-marker-split')||_0x1b08bf['hasClass']('ck-suggestion-marker-merge'))&&(_0x25b083['mapper']['unbindElementFromMarkerName'](_0x1b08bf,_0x294dc2['markerName']),_0x25b083['writer']['remove'](_0x1b08bf));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x308b13,_0x5a69d6,_0x19f5e5)=>{const _0x3072f8=_0x5a69d6['markerName']['split'](':')[0x1],_0x44600e=this['_getChangeFromId'](_0x3072f8);if(!_0x44600e)return null;const _0x53769d='add'==_0x44600e['type']?'split':'merge';if(_0x19f5e5['consumable']['test'](_0x5a69d6['markerRange'],_0x308b13['name']))for(const _0x15003d of _0x5a69d6['markerRange']['getItems']()){if(!_0x15003d['is']('element','softBreak'))continue;const _0x4cb8b9=_0x19f5e5['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x53769d}),_0x2f3a24=_0x19f5e5['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x15003d));_0x44600e['data']['isSuggestion']&&_0x19f5e5['writer']['addClass']('ck-suggestion-marker-'+_0x53769d+'-new',_0x4cb8b9),this['activeChange']==_0x44600e&&_0x19f5e5['writer']['addClass']('ck-suggestion-marker--active',_0x4cb8b9),_0x19f5e5['writer']['insert'](_0x2f3a24,_0x4cb8b9),_0x19f5e5['mapper']['bindElementToMarker'](_0x4cb8b9,_0x5a69d6['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x2ebab6=>{for(const _0x7c0700 of this['editor']['model']['document']['getRootNames']()){const _0x4b0dd8=this['editor']['model']['document']['getRoot'](_0x7c0700),_0x1db08c=this['editor']['editing']['view']['document']['getRoot'](_0x7c0700);if(_0x1db08c){const _0x18a975=_0x4b0dd8['getAttribute']('revisionHistoryAttachChange');if(_0x2ebab6['removeAttribute']('data-change-id',_0x1db08c),_0x2ebab6['removeClass']('ck-revision-history-root-add',_0x1db08c),_0x2ebab6['removeClass']('ck-revision-history-root-remove',_0x1db08c),_0x2ebab6['removeClass']('ck-revision-history-root--active',_0x1db08c),_0x18a975){const _0xf9be08=this['_getChangeFromId'](_0x18a975);if(!_0xf9be08)return null;_0x2ebab6['setAttribute']('data-change-id',_0x18a975,_0x1db08c),_0x2ebab6['addClass']('ck-revision-history-root-'+_0xf9be08['type'],_0x1db08c),this['activeChange']==_0xf9be08&&_0x2ebab6['addClass']('ck-revision-history-root--active',_0x1db08c);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x25bbf8=>'revision-comment:'+_0x25bbf8,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x12c34d=>'revision-suggestion:'+_0x12c34d,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x2cf720=>({'name':'suggestion:'+_0x2cf720,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x11d5ea=>{const _0x4c67bc=_0x11d5ea['markerName']['split'](':')[0x1];return'insertion'!=_0x4c67bc&&'deletion'!=_0x4c67bc?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x4c67bc]};}}),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',(_0x165e0e,_0x5e7810,_0x53757d)=>{const _0x1a487b=_0x53757d['mapper']['markerNameToElements'](_0x5e7810['markerName']);if(_0x1a487b){for(const _0x58bcf2 of _0x1a487b)_0x58bcf2['is']('uiElement')&&(_0x53757d['mapper']['unbindElementFromMarkerName'](_0x58bcf2,_0x5e7810['markerName']),_0x53757d['writer']['remove'](_0x58bcf2));}},{'priority':'high'});}['_getChangeFromId'](_0x1b7264){return this['_changeIdToChange']['get'](_0x1b7264);}['_getViewForChange'](_0x5f3199){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new z(this['editor']['locale'],_0x5f3199),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x112ab1,_0x1e9d3c,_0x23a581,_0x293629)=>{_0x293629&&this['_balloon']['remove'](_0x293629),_0x23a581&&(this['_balloon']['add']({'view':_0x23a581,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x3f8176=this['editor']['editing'],_0x4fc3f6=this['_getChangeFromId'](_0x23a581['changeId']);let _0xf193c8;if(_0x4fc3f6['data']['isOnRoot']){const _0x54fa8f=_0x3f8176['view']['getDomRoot'](_0x4fc3f6['rootName']);_0xf193c8=Array['from'](_0x54fa8f['getClientRects']());}else{const _0xb52024=this['editor']['model']['markers']['get']('revision:'+_0x23a581['changeId']);_0xf193c8=Array['from'](_0x3f8176['mapper']['markerNameToElements'](_0xb52024['name']))['map'](_0x50855e=>_0x3f8176['view']['domConverter']['mapViewToDom'](_0x50855e))['map'](_0x2cfe9a=>Array['from'](_0x2cfe9a['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0xf193c8[0x0];return _0xf193c8['find'](_0x446555=>_0x446555['top']-0x3<=this['_activeViewTarget']['y']&&_0x446555['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x446555['left']-0x3<=this['_activeViewTarget']['x']&&_0x446555['right']+0x3>=this['_activeViewTarget']['x'])||_0xf193c8[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x181b6c,_0x237c93,_0x4c4321,_0x278e6f)=>{this['activeView']=_0x4c4321?this['_getViewForChange'](_0x4c4321):null,this['editor']['model']['change'](()=>{const _0x594836=this['editor']['editing'];_0x278e6f&&(_0x278e6f['data']['isOnRoot']?_0x594836['view']['change'](_0x30c942=>{_0x30c942['removeClass']('ck-revision-history-root--active',_0x594836['view']['document']['getRoot'](_0x278e6f['rootName']));}):_0x594836['reconvertMarker']('revision:'+_0x278e6f['id'])),_0x4c4321&&(_0x4c4321['data']['isOnRoot']?_0x594836['view']['change'](_0x26a2c9=>{_0x26a2c9['addClass']('ck-revision-history-root--active',_0x594836['view']['document']['getRoot'](_0x4c4321['rootName']));}):_0x594836['reconvertMarker']('revision:'+_0x4c4321['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x3f9909,_0x501cd3)=>{if(this['activeChange'])return;const _0x1369c8=this['_findChangeIdFromDomTarget'](_0x501cd3['target']),_0x129a3e=this['_changeIdToChange']['get'](_0x1369c8);_0x129a3e?(this['_activeViewTarget']={'x':_0x501cd3['domEvent']['x'],'y':_0x501cd3['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x129a3e)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x4a3b43,_0xf96b79)=>{const _0x4b93d9=this['_findChangeIdFromDomTarget'](_0xf96b79['target']),_0x4e0317=this['_changeIdToChange']['get'](_0x4b93d9);_0x4e0317?(this['_activeViewTarget']={'x':_0xf96b79['domEvent']['x'],'y':_0xf96b79['domEvent']['y']},_0x4e0317===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x4e0317):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x1f0ab0){do{const _0x5b28e2=_0x1f0ab0['getAttribute']('data-change-id');if(_0x5b28e2)return _0x5b28e2;_0x1f0ab0=_0x1f0ab0['parent'];}while(_0x1f0ab0);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x177628=>{for(const _0x5a0f73 of this['editor']['model']['markers'])_0x177628['removeMarker'](_0x5a0f73);});}}function Q(_0x26cb62,_0x11512c){return(_0x252d60,_0x5bc536,_0x18eb69)=>{if(!_0x18eb69['consumable']['test'](_0x5bc536['markerRange'],_0x252d60['name']))return;const _0x165d8f=_0x5bc536['markerRange']['getWalker'](),_0x139532=_0x5bc536['markerRange']['start'],_0x559b5a=_0x26cb62['model']['schema'];let _0x1a28b4=null,_0x114240=null,_0x3d3e08=!0x1,_0x3ddcf1=!0x1;for(const _0x5c8030 of _0x165d8f){const _0x2154fc=_0x5c8030['item'];_0x3d3e08=_0x3d3e08||_0x559b5a['isContent'](_0x2154fc);const _0x3f9089=_0x18eb69['mapper']['toViewElement'](_0x2154fc);if(_0x3f9089&&_0x3f9089['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x5c8030['type']&&(_0x559b5a['isBlock'](_0x2154fc)&&!_0x559b5a['isLimit'](_0x2154fc)&&(_0x2154fc['nextSibling']||_0x139532['isAtEnd']?_0x1a28b4&&_0x1a28b4['parent']==_0x2154fc||(_0x1a28b4=_0x2154fc,_0x4e8dfe(_0x5c8030['previousPosition']),_0x3ddcf1=!0x0):_0x114240=_0x114240||_0x5c8030['previousPosition']));}function _0x4e8dfe(_0x26501f){const _0x40fb2d=_0x18eb69['mapper']['toViewPosition'](_0x26501f),_0x1397dd=_0x18eb69['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x11512c});_0x18eb69['writer']['insert'](_0x40fb2d,_0x1397dd),_0x18eb69['mapper']['bindElementToMarker'](_0x1397dd,_0x5bc536['markerName']);}_0x3d3e08||_0x3ddcf1||!_0x114240||_0x4e8dfe(_0x114240);};}class nt extends _0x15cc66{constructor(_0x2ef20a){super(_0x2ef20a);const _0x3d77ac=_0x2ef20a['plugins']['get'](u);this['affectsData']=!0x1,this['listenTo'](_0x3d77ac,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x3d77ac,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x27d03b=this['editor'],_0x533273=_0x27d03b['plugins']['get'](u),_0x18e0ea=_0x533273['isReady']?_0x533273['diff']['newRevisionId']:null;_0x27d03b['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x18e0ea);}['refresh'](){const {isReady:_0x1f3fe5,isEnabled:_0x22b583,repository:_0x2ed1b1,diff:_0x112742}=this['editor']['plugins']['get'](u),_0x17c560=_0x112742&&_0x2ed1b1['getLaterVisibleRevision'](_0x112742['newRevisionId']);this['isEnabled']=_0x1f3fe5&&_0x22b583&&Boolean(_0x17c560);}}class rt extends _0x15cc66{['_step'];constructor(_0x309220,{direction:_0x276719}){super(_0x309220);const _0x28ce52=_0x309220['plugins']['get'](u);this['affectsData']=!0x1,this['_step']='forward'===_0x276719?0x1:-0x1,this['listenTo'](_0x28ce52,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x28ce52,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x28ce52,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x3d50ae=this['editor'],_0x913eac=_0x3d50ae['plugins']['get'](u),{isNavigationMode:_0x17c6ee,currentChangeNumber:_0x3aef16}=_0x913eac;let _0x12db03;if(_0x913eac['activeChange']=_0x17c6ee?_0x913eac['diff']['changes']['get'](_0x3aef16+this['_step']):_0x913eac['diff']['changes']['first'],_0x913eac['activeChange']['data']['isOnRoot'])_0x12db03=_0x3d50ae['editing']['view']['getDomRoot'](_0x913eac['activeChange']['rootName']);else{const _0xa4a75d=_0x3d50ae['model']['markers']['get']('revision:'+_0x913eac['activeChange']['id']);_0x12db03=_0x542bc9(_0x3d50ae['editing'],_0xa4a75d);}_0x341d84({'target':_0x12db03,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x1615f2,currentChangeNumber:_0x55b597,numberOfChanges:_0xf4c155,isReady:_0x2c2a51,isEnabled:_0xd45857}=this['editor']['plugins']['get'](u);this['isEnabled']=!!(_0xd45857&&_0x2c2a51&&_0xf4c155)&&(!_0x1615f2||(0x1===this['_step']?_0x55b597<_0xf4c155-0x1:_0x55b597>0x0));}}class Ri extends _0x524cb0{constructor(_0x32d66d){super(_0x32d66d);const _0x5e3f2a=this['bindTemplate'],_0x3a6d08=new _0x4e77f1(_0x32d66d),_0xef1949=new _0x4e77f1(_0x32d66d);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',(_0x511800,_0x35807a)=>_0x511800&&_0x35807a>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x187e28,_0x42c097,_0x32d2cf,_0x325d31)=>{if(!_0x187e28)return m(_0x32d66d,'Loading...');if(!_0x32d2cf)return m(_0x32d66d,'No\x20changes');const _0x5e290c=m(_0x32d66d,'NUMBER_OF_CHANGES',_0x32d2cf);return _0x325d31?m(_0x32d66d,'X_OF_Y_CHANGES',[_0x42c097+0x1,_0x32d2cf]):_0x5e290c;}),_0x3a6d08['set']({'label':m(_0x32d66d,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x583de3}),_0xef1949['set']({'label':m(_0x32d66d,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x163c7b}),_0x3a6d08['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0xef1949['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x3a6d08['on']('execute',()=>this['fire']('execute','backward')),_0xef1949['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',_0x5e3f2a['if']('_isStatusLabelVisible','ck-hidden',_0x578c54=>!_0x578c54)]},'children':[{'text':_0x5e3f2a['to']('isNavigationMode',_0x5389f6=>_0x5389f6?m(_0x32d66d,'EDIT_X_OF_Y_REVISIONS')+':\x20':m(_0x32d66d,'Total')+':\x20')}]},{'text':_0x5e3f2a['to']('_statusText')}]},new _0x5c4716(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x3a6d08,_0xef1949]}]});}}const ge='ck-editor__editable__loading-overlay';class ji extends _0x23b9b4{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x2cbea8=this['editor']['editing']['view'];_0x2cbea8['change'](_0x3e265a=>{for(const _0x39e043 of _0x2cbea8['document']['roots'])_0x3e265a['addClass'](ge,_0x39e043);});}['hide'](){const _0x1aa966=this['editor']['editing']['view'];_0x1aa966['change'](_0x5236ab=>{for(const _0x534994 of _0x1aa966['document']['roots'])_0x5236ab['removeClass'](ge,_0x534994);});}}class v extends _0x23b9b4{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u,ji];}['init'](){const _0x2d39a9=this['editor'],_0x18164d=_0x2d39a9['plugins']['get'](u),_0x5d96dc=_0x2d39a9['plugins']['get'](ji);_0x2d39a9['ui']['componentFactory']['add']('exitToEditing',_0x5390f9=>{const _0x7ad82c=new _0x4e77f1(_0x5390f9);return _0x7ad82c['set']({'label':m(_0x5390f9,'Back\x20to\x20editing'),'icon':_0x432dbf,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x7ad82c,'execute',()=>{_0x2d39a9['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x7ad82c;}),_0x2d39a9['ui']['componentFactory']['add']('restoreRevision',_0x1dbdfe=>{const _0x3df59e=new _0x4e77f1(_0x1dbdfe);return _0x3df59e['set']({'label':m(_0x1dbdfe,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x3df59e['bind']('isEnabled')['to'](_0x2d39a9['commands']['get']('restoreRevision')),this['listenTo'](_0x3df59e,'execute',()=>_0x2d39a9['execute']('restoreRevision')),_0x3df59e;}),_0x2d39a9['ui']['componentFactory']['add']('changesNavigation',_0x43b488=>{const _0x61f782=new Ri(_0x43b488),_0x5cab35=_0x2d39a9['commands']['get']('showPreviousChange'),_0x54e2fb=_0x2d39a9['commands']['get']('showNextChange');return _0x61f782['bind']('isBackwardNavigationEnabled')['to'](_0x5cab35,'isEnabled'),_0x61f782['bind']('isForwardNavigationEnabled')['to'](_0x54e2fb,'isEnabled'),_0x61f782['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x18164d),this['listenTo'](_0x61f782,'execute',(_0x171f8e,_0x471498)=>{_0x2d39a9['execute']('forward'===_0x471498?'showNextChange':'showPreviousChange');}),_0x61f782;}),_0x5d96dc['show'](),_0x18164d['on']('change:isReady',(_0x3f8062,_0x44e29f,_0x2caa3a)=>{_0x2caa3a?_0x5d96dc['hide']():_0x5d96dc['show']();});}}class hi extends et{['_resizeObserver']=null;constructor(_0x4f2b4b,_0x275b93){super(_0x4f2b4b,_0x275b93);const _0x4eaedc=this['bindTemplate'];this['set']({'label':m(_0x4f2b4b,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=m(_0x4f2b4b,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x4eaedc['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 _0x364d8d=this['fieldView']['element'];this['_tooltipString']=_0x364d8d['scrollWidth']>_0x364d8d['clientWidth']&&_0x364d8d['value']||'';}}class ni extends _0x524cb0{constructor(_0xdce598,_0x407162,_0x2d8ba5){super(_0xdce598);const _0x2a6313=new _0x1dcc7a();_0x2a6313['set']({'content':_0x568042,'viewBox':'0\x200\x2011\x2010'});const _0x20edcf=['ck','ck-revision-history-sidebar__revision-author'];_0x2d8ba5&&_0x20edcf['push']('ck-revision-history-sidebar__revision-author_creator');const _0x31b848=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':m(_0xdce598,_0x2d8ba5?'Revision\x20creator':'Revision\x20author')},'children':[_0x2a6313,_0x407162['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x20edcf},'children':_0x31b848});}}function ai(_0x12c1f8,_0x53a155){const _0x36d4e4=_0x12c1f8['bindTemplate'],_0x1617d5=_0x12c1f8['locale'],_0x125a9c=_0x10fce4(_0x1617d5);_0x125a9c['panelPosition']='sw';const _0x474f37=function(_0x1aa08e,_0x17e017){const _0x6668f3=function(_0x5238e1,_0x31af65){const _0x2dc8e4=_0x5238e1['locale'],_0x52185f={'Compare\x20against\x20selected':m(_0x2dc8e4,'Compare\x20against\x20selected'),'Name\x20this\x20revision':m(_0x2dc8e4,'Name\x20this\x20revision'),'Restore\x20this\x20revision':m(_0x2dc8e4,'Restore\x20this\x20revision')};return _0x31af65['map'](_0x159312=>{const _0x430cf8=_0x52185f[_0x159312['name']];return _0x430cf8&&_0x430cf8!==_0x159312['name']&&(_0x159312['name']=_0x430cf8),_0x159312;});}(_0x1aa08e,_0x17e017),_0x46a03f=new _0x1dcfeb();for(const _0x1c060f of _0x6668f3){const _0x295a6a={'type':'button','model':new to({'label':_0x1c060f['name'],'class':_0x1c060f['class'],'withText':!0x0,'role':'menuitem','_action':_0x1c060f['action']})};_0x295a6a['model']['bind']('isEnabled')['to'](_0x1aa08e,'isActionsDropdownOpen',_0x6a9e4a=>'function'!=typeof _0x1c060f['isEnabled']||(!_0x6a9e4a||_0x1c060f['isEnabled'](_0x1aa08e))),_0x46a03f['add'](_0x295a6a);}return _0x46a03f;}(_0x12c1f8,_0x53a155);return _0x12c1f8['bind']('isActionsDropdownOpen')['to'](_0x125a9c,'isOpen'),_0x125a9c['buttonView']['set']({'label':m(_0x1617d5,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x3057b1}),_0x125a9c['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x36d4e4['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x36d4e4['to'](_0x147a0b=>_0x147a0b['stopPropagation']())}}),_0x125a9c['on']('execute',_0x196465=>{_0x12c1f8['isReady']&&'function'==typeof _0x196465['source']['_action']&&_0x196465['source']['_action'](_0x12c1f8);}),_0x348a03(_0x125a9c,_0x474f37,{'role':'menu'}),_0x125a9c['listenTo'](_0x12c1f8,'change:isActionsDropdownOpen',(_0xb4b925,_0x58bd1f,_0x5e7306)=>{if(_0x5e7306)for(const _0x4bd214 of _0x125a9c['listView']['items']){const _0x5a6372=_0x4bd214['children']['first'],_0x33ee78=_0x53a155['find'](_0x43f505=>_0x43f505['action']===_0x5a6372['_action'])['isVisible'];_0x4bd214['isVisible']=void 0x0===_0x33ee78||_0x33ee78(_0x12c1f8);}}),_0x125a9c;}class _i extends/* #__PURE__ -- @preserve */
27
- _0x58ed8b(_0x524cb0){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0xd257e3,_0x5c2d87,_0x1d484b,_0x42b0e1){super(_0xd257e3);const _0x34ac58=this['bindTemplate'],_0x39dd63=function(_0x4f26b9,_0x487bf0){const _0x530f93=Array['from'](_0x487bf0['authors'])['filter'](_0x3f64fb=>_0x3f64fb!=_0x487bf0['creator']);return _0x487bf0['creator']&&_0x530f93['unshift'](_0x487bf0['creator']),_0x530f93['map'](_0xd1d4cd=>new ni(_0x4f26b9,_0xd1d4cd,_0xd1d4cd==_0x487bf0['creator']));}(_0xd257e3,_0x5c2d87);this['id']=_0x5c2d87['id'],this['_revision']=_0x5c2d87,this['_requireRevisionName']=_0x42b0e1,this['bind']('name','createdAt')['to'](_0x5c2d87),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x47e1fb=>{return _0x13fc88=_0xd257e3['uiLanguage'],(_0x25eadc=_0x47e1fb)['toLocaleDateString'](_0x13fc88,{'month':'long','day':'numeric'})+',\x20'+_0x25eadc['toLocaleTimeString'](_0x13fc88,{'hour':'numeric','minute':'numeric'});var _0x13fc88,_0x25eadc;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new hi(_0xd257e3,ti),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x17a2e8=>_0x17a2e8||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x52a9d4,_0x1518f1)=>_0x52a9d4&&_0x1518f1),this['revisionActionsView']=_0x1d484b&&_0x1d484b['length']?ai(this,_0x1d484b):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x34ac58['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x34ac58['if']('isEnabled','ck-disabled',_0x559985=>!_0x559985),_0x34ac58['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x34ac58['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x34ac58['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':_0x34ac58['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':_0x39dd63}]},this['revisionActionsView']],'on':{'click':_0x34ac58['to'](_0xeb535e=>{_0xeb535e['srcElement']['closest']('.ck-confirm-view')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x5bdcc7=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x5bdcc7,'change',()=>{this['_requireRevisionName']&&!_0x5bdcc7['value']||this['fire']('setName',{'id':this['id'],'name':_0x5bdcc7['value']}),_0x5bdcc7['value']||(_0x5bdcc7['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(_0x4403c9,_0x1c3aa7){const _0x3c2909=_0x35d12b['fromJSDate'](_0x4403c9)['setLocale'](_0x1c3aa7),_0x257afa=_0x35d12b['local'](),_0x55e7b7=_0x257afa['minus']({'days':0x1})['startOf']('day');let _0x268fc0,_0xd22fb5;return _0x3c2909['hasSame'](_0x257afa,'day')?(_0x268fc0=_0x3c2909['startOf']('day')['toJSDate'](),_0xd22fb5=_0x3c2909['toRelativeCalendar']()):_0x3c2909['hasSame'](_0x55e7b7,'day')?(_0x268fc0=_0x55e7b7['toJSDate'](),_0xd22fb5=_0x3c2909['toRelativeCalendar']()):_0x3c2909['hasSame'](_0x257afa,'week')?(_0x268fc0=_0x3c2909['startOf']('week')['toJSDate'](),_0xd22fb5=_0x3c2909['weekdayLong']||''):_0x3c2909['hasSame'](_0x257afa,'year')?(_0x268fc0=_0x3c2909['startOf']('month')['toJSDate'](),_0xd22fb5=_0x3c2909['monthLong']||''):(_0x268fc0=_0x3c2909['startOf']('year')['toJSDate'](),_0xd22fb5=String(_0x3c2909['year'])),{'startDate':_0x268fc0,'localizedPeriodName':_0xd22fb5};}class bi extends _0x524cb0{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x33ecc1,_0xa8347c,_0x4c95b6,_0x30bf1a){super(_0x33ecc1);const _0x154492=li(_0xa8347c,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0xa8347c,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x4c95b6,this['_requireRevisionName']=_0x30bf1a,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':_0x154492}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x13e9ca){const _0xb3ab43=new _i(this['locale'],_0x13e9ca,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0xb3ab43);}['removeRevision'](_0x4ba8ad){const _0x4fbc16=this['revisionViews']['find'](_0x56e4cf=>_0x56e4cf['id']===_0x4ba8ad['id']);this['revisionViews']['remove'](_0x4fbc16);}}class fi extends _0x524cb0{constructor(_0x566fee){super(_0x566fee);const _0x1abe97=new _0x1dcc7a();_0x1abe97['content']=_0x433702,this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x1abe97,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[m(_0x566fee,'Revision\x20history')]}]});}}class di extends _0x524cb0{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x24bb35,_0x4943b7,_0x4b1552,_0x360575){super(_0x24bb35);const _0x54da70=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x4943b7,this['_revisionActions']=_0x4b1552,this['_requireRevisionName']=_0x360575,this['on']('select',(_0x3ed559,_0x1ed330)=>{this['fire']('revisionSelected',_0x1ed330);}),this['on']('setName',(_0xb7e455,_0x3478f7)=>{this['fire']('revisionSetName',_0x3478f7);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new fi(_0x24bb35),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x54da70['if']('isEnabled','ck-disabled',_0x36045d=>!_0x36045d)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x28b119 of this['_revisions'])this['_addRevision'](_0x28b119);this['_revisions']['on']('add',(_0x36987d,_0x19c36d)=>{this['_addRevision'](_0x19c36d);}),this['_revisions']['on']('remove',(_0x17c842,_0x3b025a)=>{this['_removeRevision'](_0x3b025a);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x30e904=>_0x30e904['revisionViews']['map'](_0x1fb2f3=>_0x1fb2f3))['flat']();}['selectRevision'](_0x4b3c61){for(const _0x4c9690 of this['revisionViews'])_0x4b3c61&&_0x4b3c61['id']===_0x4c9690['id']?_0x4c9690['select']():_0x4c9690['deselect']();}['highlightRevisions'](_0x537ad2){for(const _0x25ec50 of this['revisionViews'])_0x537ad2['some'](({id:_0x2eb87b})=>_0x2eb87b===_0x25ec50['id'])?_0x25ec50['highlight']():_0x25ec50['unhighlight']();}['_addRevision'](_0x5d041d){const _0x46af40=li(_0x5d041d['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0xc392cc=this['timePeriodViews']['get'](0x0);_0xc392cc&&_0xc392cc['startDate']['getTime']()===_0x46af40['getTime']()||(_0xc392cc=new bi(this['locale'],_0x46af40,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0xc392cc)),_0xc392cc['addRevision'](_0x5d041d);}['_removeRevision'](_0x44e41b){const _0xe54dea=li(_0x44e41b['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0xe54dea)['removeRevision'](_0x44e41b);}['_getTimePeriodViewByStartDate'](_0x38c34d){return this['timePeriodViews']['find'](_0x11cf30=>_0x11cf30['startDate']['getTime']()===_0x38c34d['getTime']());}}class d extends _0x23b9b4{['_revisionViewer'];['_revisionsRepository'];['_sidebarView'];static ['defaultRevisionActions']=/* #__PURE__ -- @preserve */
23
+ import{ObservableMixin as _0x319fd0,uid as _0x14dab8,Collection as _0x2fb560,logWarning as _0x5e46d4,FocusTracker as _0x45b684,KeystrokeHandler as _0x5f358f,scrollViewportToShowTarget as _0x544f13,ResizeObserver as ot,ElementReplacer as it,CKEditorError as _0x3e1231}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x1a7e1c,set as _0x10fab4,unset as _0x4e14a7,isEqual as _0x4e026b}from'es-toolkit/compat';import{Plugin as _0x1cbf02,PendingActions as _0x59b108,Command as _0x171f77,ElementApiMixin as _0x172418,Editor as _0x2e5e70}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x24be1d,getMarkerDomElement as _0x40fef2,ConfirmMixin as _0x27a638,sanitizeEditorConfig as _0x3aa6a7}from'ckeditor5-collaboration/dist/index.js';import{ViewContainerElement as _0x1a4464,ViewAttributeElement as _0x39dbdd,ViewEmptyElement as _0x4201d4,ViewRawElement as _0x164601,ViewUIElement as _0x24e598,ViewDocumentFragment as _0x47c7a8,ViewText as _0x48e22d,ViewElement as _0x482130,ModelElement as _0x391ba1,ModelRange as _0x4650bf,ModelPosition as _0x49e5e1,ModelDocumentFragment as _0x1f769d,ModelText as _0xf5d3d}from'@ckeditor/ckeditor5-engine/dist/index.js';import{IconHistory as _0x5409bc,IconChevronUp as _0x25fac3,IconChevronDown as _0x565f7d,IconUndo as _0x3db167,IconUser as _0x42b1f1,IconThreeVerticalDots as _0x4f013c}from'@ckeditor/ckeditor5-icons/dist/index.js';import{CssTransitionDisablerMixin as _0x15c189,View as _0x344163,submitHandler as _0x2dad37,LabeledFieldView as et,createLabeledInputText as ti,createDropdown as _0x3feb57,ListView as _0x18b63c,ListItemView as _0x10cbe5,ButtonView as _0x111a4e,MenuBarMenuView as _0x479957,MenuBarMenuListView as _0x3f235d,MenuBarMenuListItemView as _0x45caa7,MenuBarMenuListItemButtonView as _0x139b8e,ContextualBalloon as _0x458504,ToolbarSeparatorView as _0xff048f,IconView as _0x119c42,addListToDropdown as _0xdf116,UIModel as to,EditorUI as tt,normalizeToolbarConfig as st,BoxedEditorUIView as _0xe309dd,StickyPanelView as _0x431794,ToolbarView as _0x3ab602,InlineEditableUIView as te}from'@ckeditor/ckeditor5-ui/dist/index.js';import{DateTime as _0x24f230}from'luxon';class I extends/* #__PURE__ -- @preserve */
24
+ _0x319fd0(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0xcbaad2){super(),this['id']=_0xcbaad2['id']||_0x14dab8(),this['creator']=_0xcbaad2['creator']||null,this['authors']=_0xcbaad2['authors']||[],this['diffData']=_0xcbaad2['diffData']||null,this['toVersion']=_0xcbaad2['toVersion']||0x0,this['fromVersion']=_0xcbaad2['fromVersion']||0x0,this['set']('name',_0xcbaad2['name']||''),this['set']('createdAt',_0xcbaad2['createdAt']||new Date()),this['set']('attributes',_0xcbaad2['attributes']||{});}['setName'](_0x3f163f){this['_update']({'name':_0x3f163f});}['setAttribute'](_0xb114f9,_0x5e14e3){const _0x607d4a=_0x1a7e1c(this['attributes']);_0x10fab4(_0x607d4a,_0xb114f9,_0x5e14e3),this['_update']({'attributes':_0x607d4a});}['removeAttribute'](_0x3206eb){const _0x95ae57=_0x1a7e1c(this['attributes']);_0x4e14a7(_0x95ae57,_0x3206eb),this['_update']({'attributes':_0x95ae57});}['_update'](_0x1e98b1,_0x42d9d3=!0x1){let _0x13463a=!0x1;const _0x39573e={'id':this['id']},_0x537f49=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x38ce36 of _0x537f49){const _0x4144e4=_0x1e98b1[_0x38ce36];void 0x0!==_0x4144e4&&_0x4144e4!==this[_0x38ce36]&&(this[_0x38ce36]=_0x4144e4,_0x39573e[_0x38ce36]=_0x4144e4,_0x13463a=!0x0);}_0x13463a&&(_0x39573e['authors']&&(_0x39573e['authorsIds']=_0x39573e['authors']['map'](_0x33fbd4=>_0x33fbd4['id']),delete _0x39573e['authors']),this['fire']('_update',_0x39573e,_0x42d9d3));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x22466c=>_0x22466c['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class S extends _0x1cbf02{['_revisions'];static get['requires'](){return[_0x24be1d];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x5384d6){super(_0x5384d6),this['_revisions']=new _0x2fb560();}['afterInit'](){!async function(_0x4ade6d){const _0x399cd9=_0x3bc133([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]),_0x16c94e=0xeb829,_0x1cf9b3=0x359e09b0,_0x461e10=0x35997e70^_0x1cf9b3,_0x264451=window[_0x3bc133([0x44,0x61,0x74,0x65])][_0x3bc133([0x6e,0x6f,0x77])](),_0x5bea84=_0x4ade6d[_0x3bc133([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x194c80=new window[(_0x3bc133([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x145ca0=>{_0x5bea84[_0x3bc133([0x6f,0x6e,0x63,0x65])](_0x3bc133([0x72,0x65,0x61,0x64,0x79]),_0x145ca0);}),_0x1d5975={[_0x3bc133([0x6b,0x74,0x79])]:_0x3bc133([0x45,0x43]),[_0x3bc133([0x75,0x73,0x65])]:_0x3bc133([0x73,0x69,0x67]),[_0x3bc133([0x63,0x72,0x76])]:_0x3bc133([0x50,0x2d,0x32,0x35,0x36]),[_0x3bc133([0x78])]:_0x3bc133([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]),[_0x3bc133([0x79])]:_0x3bc133([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]),[_0x3bc133([0x61,0x6c,0x67])]:_0x3bc133([0x45,0x53,0x32,0x35,0x36])},_0x427c89=_0x5bea84[_0x3bc133([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x3bc133([0x67,0x65,0x74])](_0x3bc133([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x1fa696(){let _0x7ab0b7,_0x3e34c8=null,_0xc85e9c=null;try{if(_0x427c89==_0x3bc133([0x47,0x50,0x4c]))return _0x3bc133([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x7ab0b7=_0x1511b6(),!_0x7ab0b7)return _0x3bc133([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x7ab0b7[_0x3bc133([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0xc85e9c=_0x5008c4(_0x7ab0b7[_0x3bc133([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x7ab0b7[_0x3bc133([0x6a,0x74,0x69])])),await _0x4d92c7()?_0x3eda08()?_0x247e06()?_0x3bc133([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0xa6bdb3()?(_0x7ab0b7[_0x3bc133([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x3bc133([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x3e34c8=_0x3e1a30(_0x3bc133([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x7ab0b7[_0x3bc133([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x3bc133([0x74,0x72,0x69,0x61,0x6c])&&(_0x3e34c8=_0x3e1a30(_0x3bc133([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x446f63()):_0x3bc133([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x3bc133([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x3bc133([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x3bc133([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x247e06(){const _0x3f8c31=[_0x3bc133([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x3bc133([0x74,0x72,0x69,0x61,0x6c])][_0x3bc133([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x7ab0b7[_0x3bc133([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x264451/0x3e8:0xe10*_0x461e10;return _0x7ab0b7[_0x3bc133([0x65,0x78,0x70])]<_0x3f8c31;}function _0x3eda08(){const _0x470daa=_0x7ab0b7[_0x3bc133([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x470daa)return!0x1;if(_0x470daa[_0x3bc133([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x3bc133([0x2a])))return!0x0;if(_0x470daa[_0x3bc133([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x3bc133([0x52,0x48])))return!0x0;if(_0x470daa[_0x3bc133([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x3bc133([0x52,0x52,0x48]))){if(_0x97cdef())return!0x0;if(_0x445f72()||_0xeebc63())return!0x0;}return!0x1;}function _0xa6bdb3(){const _0xc384f1=_0x7ab0b7[_0x3bc133([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0xc384f1||0x0==_0xc384f1[_0x3bc133([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x148d06}=new URL(window[_0x3bc133([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0xc384f1[_0x3bc133([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x148d06))return!0x0;const _0x57ff0f=_0x148d06[_0x3bc133([0x73,0x70,0x6c,0x69,0x74])](_0x3bc133([0x2e]));return _0xc384f1[_0x3bc133([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x4f9791=>_0x4f9791[_0x3bc133([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x3bc133([0x2a])))[_0x3bc133([0x6d,0x61,0x70])](_0x5ea715=>_0x5ea715[_0x3bc133([0x73,0x70,0x6c,0x69,0x74])](_0x3bc133([0x2e])))[_0x3bc133([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x243bed=>_0x243bed[_0x3bc133([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x57ff0f[_0x3bc133([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x3bc133([0x6d,0x61,0x70])](_0x204ae0=>Array(_0x57ff0f[_0x3bc133([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0x204ae0[_0x3bc133([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x3bc133([0x66,0x69,0x6c,0x6c])](_0x204ae0[0x0]===_0x3bc133([0x2a])?_0x3bc133([0x2a]):'')[_0x3bc133([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0x204ae0))[_0x3bc133([0x73,0x6f,0x6d,0x65])](_0x570ea2=>_0x57ff0f[_0x3bc133([0x65,0x76,0x65,0x72,0x79])]((_0x442e91,_0x1364e1)=>_0x570ea2[_0x1364e1]===_0x442e91||_0x570ea2[_0x1364e1]===_0x3bc133([0x2a])));}function _0x446f63(){return _0x3e34c8&&_0xc85e9c?new window[(_0x3bc133([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x9ea410,_0x239b56)=>{_0x3e34c8[_0x3bc133([0x74,0x68,0x65,0x6e])](_0x9ea410,_0x239b56),_0xc85e9c[_0x3bc133([0x74,0x68,0x65,0x6e])](_0x23dd1c=>{_0x23dd1c!=_0x3bc133([0x56,0x61,0x6c,0x69,0x64])&&_0x9ea410(_0x23dd1c);},_0x239b56);}):_0x3e34c8||_0xc85e9c||_0x3bc133([0x56,0x61,0x6c,0x69,0x64]);}}function _0x5008c4(_0x4a865b,_0xb5b3a2){return new window[(_0x3bc133([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2e88a1=>{if(_0x695e8c())return _0x2e88a1(_0x3bc133([0x56,0x61,0x6c,0x69,0x64]));_0x251bc9(),_0x5bea84[_0x3bc133([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x3bc133([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x470bf6=!0x1;const _0x4562b0=_0x14dab8();function _0x2fc212(_0x55a331){return!!_0x55a331&&(typeof _0x55a331===_0x3bc133([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x55a331===_0x3bc133([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x55a331[_0x3bc133([0x74,0x68,0x65,0x6e])]===_0x3bc133([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x55a331[_0x3bc133([0x63,0x61,0x74,0x63,0x68])]===_0x3bc133([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x1b1b4c(_0x4e5bdf){_0x21828b(_0x4e5bdf)[_0x3bc133([0x74,0x68,0x65,0x6e])](_0x3c870a=>{if(!_0x3c870a||_0x3c870a[_0x3bc133([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x3bc133([0x6f,0x6b]))return _0x3bc133([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x528199(_0x4dd864(_0x4562b0+_0xb5b3a2))!=_0x3c870a[_0x3bc133([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x3bc133([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x3bc133([0x56,0x61,0x6c,0x69,0x64]);})[_0x3bc133([0x74,0x68,0x65,0x6e])](_0x8438dc=>(_0x3f494d(),_0x8438dc),()=>{const _0x418eb3=_0x588a9a();return null==_0x418eb3?(_0x3f494d(),_0x3bc133([0x56,0x61,0x6c,0x69,0x64])):_0x3bc133(_0x264451-_0x418eb3>(0x11928db0^_0x1cf9b3)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x3bc133([0x74,0x68,0x65,0x6e])](_0x2e88a1)[_0x3bc133([0x63,0x61,0x74,0x63,0x68])](()=>{_0x2e88a1(_0x3bc133([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x37e09a=0x35a8e730^_0x1cf9b3;function _0x3f494d(){const _0x2e813a=_0x3bc133([0x6c,0x6c,0x63,0x74,0x2d])+_0x528199(_0x4dd864(_0x4a865b)),_0x380672=_0x53eca2(_0x528199(window[_0x3bc133([0x4d,0x61,0x74,0x68])][_0x3bc133([0x63,0x65,0x69,0x6c])](_0x264451/_0x37e09a)));window[_0x3bc133([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x3bc133([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x2e813a,_0x380672);}function _0x588a9a(){const _0x57f977=_0x3bc133([0x6c,0x6c,0x63,0x74,0x2d])+_0x528199(_0x4dd864(_0x4a865b)),_0x3a51c4=window[_0x3bc133([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x3bc133([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x57f977);return _0x3a51c4?window[_0x3bc133([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x53eca2(_0x3a51c4),0x10)*_0x37e09a:null;}function _0x21828b(_0x307d68){return new window[(_0x3bc133([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x1da840,_0x124868)=>{_0x307d68[_0x3bc133([0x74,0x68,0x65,0x6e])](_0x1da840,_0x124868),window[_0x3bc133([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x124868,0x359fdd70^_0x1cf9b3);});}}_0x5bea84[_0x3bc133([0x6f,0x6e])](_0x3bc133([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x2b857d,_0x1dcbe5)=>{if(_0x1dcbe5[0x0]!=_0x4a865b)return _0x2e88a1(_0x3bc133([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x1dcbe5[0x1]={..._0x1dcbe5[0x1],[_0x3bc133([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x4562b0};},{[_0x3bc133([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x3bc133([0x68,0x69,0x67,0x68])}),_0x5bea84[_0x3bc133([0x6f,0x6e])](_0x3bc133([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x23f2ef=>{_0x2fc212(_0x23f2ef[_0x3bc133([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x470bf6=!0x0,_0x1b1b4c(_0x23f2ef[_0x3bc133([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x3bc133([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x3bc133([0x6c,0x6f,0x77])}),_0x194c80[_0x3bc133([0x74,0x68,0x65,0x6e])](()=>{_0x470bf6||_0x2e88a1(_0x3bc133([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x695e8c(){return _0x5bea84[_0x3bc133([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x3bc133([0x76,0x69,0x65,0x77])][_0x3bc133([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x3bc133([0x61,0x75,0x74,0x6f]);}function _0x251bc9(){_0x5bea84[_0x3bc133([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x3bc133([0x76,0x69,0x65,0x77])][_0x3bc133([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x3bc133([0x61,0x75,0x74,0x6f]);}}function _0x3e1a30(_0x2448c2){const _0x59d35c=[new window[(_0x3bc133([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x20b50a=>setTimeout(_0x20b50a,0x3597377c^_0x1cf9b3)),_0x194c80[_0x3bc133([0x74,0x68,0x65,0x6e])](()=>new window[(_0x3bc133([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x5bc8fd=>{const _0x14c3c9=0x359e09b7^_0x1cf9b3,_0x169474=_0x4ade6d[_0x3bc133([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x593721(){_0x169474[_0x3bc133([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x14c3c9&&_0x5bc8fd();}_0x593721(),_0x169474[_0x3bc133([0x6f,0x6e])](_0x3bc133([0x61,0x64,0x64]),_0x593721);})),new window[(_0x3bc133([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2b58e3=>{function _0x12662b(){for(const _0x19b6b9 in window)if(window[_0x3bc133([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x3bc133([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x19b6b9))&&window[_0x19b6b9]==_0x16c94e)return _0x2b58e3();_0x5bea84[_0x3bc133([0x73,0x74,0x61,0x74,0x65])]!=_0x3bc133([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x3bc133([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x12662b,0x359e1a38^_0x1cf9b3);}_0x30b4d6(_0x3bc133([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x12662b();})];return window[_0x3bc133([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x3bc133([0x72,0x61,0x63,0x65])](_0x59d35c)[_0x3bc133([0x74,0x68,0x65,0x6e])](()=>_0x2448c2);}async function _0x1e7f4c(){if(await _0x194c80,_0x30b4d6(_0x3bc133([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x416714=_0x4ade6d[_0x3bc133([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x443497=_0x4ade6d[_0x3bc133([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])](_0x416714[_0x3bc133([0x69,0x64])]),_0x24b8fa=_0x2d78f0(_0x3bc133([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x24b8fa[_0x3bc133([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x416714['id'],_0x443497?_0x443497['id']:null,!0x0),_0x24b8fa[_0x3bc133([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x3bc133([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x24b8fa[_0x3bc133([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x24b8fa[_0x3bc133([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x1031a8,void(_0x24b8fa[_0x3bc133([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x1031a8);}if(_0x30b4d6(_0x3bc133([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x48bf5f=_0x2d78f0(_0x3bc133([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x48bf5f[_0x3bc133([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x3bc133([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x48bf5f[_0x3bc133([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x48bf5f[_0x3bc133([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x1031a8,_0x48bf5f[_0x3bc133([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x1031a8;}_0x5bea84[_0x3bc133([0x6d,0x6f,0x64,0x65,0x6c])][_0x3bc133([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x1031a8,_0x5bea84[_0x3bc133([0x6d,0x6f,0x64,0x65,0x6c])][_0x3bc133([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x1031a8,_0x5bea84[_0x3bc133([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x3bc133([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x97cdef(){return _0x30b4d6(_0x3bc133([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x2d78f0(_0x3bc133([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x3bc133([0x73,0x74,0x61,0x74,0x65])]==_0x3bc133([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x445f72(){return _0x30b4d6(_0x3bc133([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 _0xeebc63(){return _0x30b4d6(_0x3bc133([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x3a9e79(_0x35effd){const _0x343e45=_0x59872b();_0x5bea84[_0x343e45]=_0x3bc133([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])+_0x35effd,_0x35effd[_0x3bc133([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x3bc133([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x59872b()]=_0x16c94e),_0x35effd!=_0x3bc133([0x56,0x61,0x6c,0x69,0x64])&&_0x1e7f4c();}function _0x59872b(){const _0x1e9a32=window[_0x3bc133([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x3bc133([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x3bc133([0x6e,0x6f,0x77])]())[_0x3bc133([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x3bc133([0x2e]),'');let _0xdb3bb0=_0x3bc133([0x76]);for(let _0x3fa336=0x0;_0x3fa336<_0x1e9a32[_0x3bc133([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x3fa336+=0x2){let _0x10f208=window[_0x3bc133([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x1e9a32[_0x3bc133([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x3fa336,_0x3fa336+0x2));_0x10f208>=_0x399cd9[_0x3bc133([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x10f208-=_0x399cd9[_0x3bc133([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0xdb3bb0+=_0x399cd9[_0x10f208];}return _0xdb3bb0;}function _0x1511b6(){const _0x1c93b6=_0x427c89[_0x3bc133([0x73,0x70,0x6c,0x69,0x74])](_0x3bc133([0x2e]));if(0x3!=_0x1c93b6[_0x3bc133([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x2780fa(_0x1c93b6[0x1]);function _0x2780fa(_0x1b000f){const _0x48b532=_0x7080af(_0x1b000f);return _0x48b532&&_0x3e4b8d()?_0x48b532:null;function _0x3e4b8d(){const _0x18a913=_0x48b532[_0x3bc133([0x6a,0x74,0x69])],_0x21dd78=window[_0x3bc133([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x18a913[_0x3bc133([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x18a913[_0x3bc133([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0xb4ed86={..._0x48b532,[_0x3bc133([0x6a,0x74,0x69])]:_0x18a913[_0x3bc133([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x18a913[_0x3bc133([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0xb4ed86[_0x3bc133([0x76,0x63])],_0x4dd864(_0xb4ed86)==_0x21dd78;}}}async function _0x4d92c7(){let _0x21f116=!0x0;try{const _0x594b62=_0x427c89[_0x3bc133([0x73,0x70,0x6c,0x69,0x74])](_0x3bc133([0x2e])),[_0x401187,_0x1ab5ce,_0x2138ed]=_0x594b62;return _0x3e7f50(_0x401187),await _0xff0daf(_0x401187,_0x1ab5ce,_0x2138ed),_0x21f116;}catch{return!0x1;}function _0x3e7f50(_0x46ac8f){const _0x5c1df4=_0x7080af(_0x46ac8f);_0x5c1df4&&_0x5c1df4[_0x3bc133([0x61,0x6c,0x67])]==_0x3bc133([0x45,0x53,0x32,0x35,0x36])||(_0x21f116=!0x1);}async function _0xff0daf(_0x7c258f,_0x3220be,_0x4d9d0){const _0x49d8da=window[_0x3bc133([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x3bc133([0x66,0x72,0x6f,0x6d])](_0x1f415e(_0x4d9d0),_0x19dc5d=>_0x19dc5d[_0x3bc133([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0xe70904=new window[(_0x3bc133([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x3bc133([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x7c258f+_0x3bc133([0x2e])+_0x3220be),_0x315389=window[_0x3bc133([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x3bc133([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x315389)return;const _0x2cadcd=await _0x315389[_0x3bc133([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x3bc133([0x6a,0x77,0x6b]),_0x1d5975,{[_0x3bc133([0x6e,0x61,0x6d,0x65])]:_0x3bc133([0x45,0x43,0x44,0x53,0x41]),[_0x3bc133([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x3bc133([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x3bc133([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x315389[_0x3bc133([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x3bc133([0x6e,0x61,0x6d,0x65])]:_0x3bc133([0x45,0x43,0x44,0x53,0x41]),[_0x3bc133([0x68,0x61,0x73,0x68])]:{[_0x3bc133([0x6e,0x61,0x6d,0x65])]:_0x3bc133([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x2cadcd,_0x49d8da,_0xe70904)||(_0x21f116=!0x1);}}function _0x7080af(_0x2c22ae){return _0x2c22ae[_0x3bc133([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x3bc133([0x65,0x79]))?JSON[_0x3bc133([0x70,0x61,0x72,0x73,0x65])](_0x1f415e(_0x2c22ae)):null;}function _0x1f415e(_0x199194){return window[_0x3bc133([0x61,0x74,0x6f,0x62])](_0x199194[_0x3bc133([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x3bc133([0x2b]))[_0x3bc133([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x3bc133([0x2f])));}function _0x4dd864(_0x347990){let _0x56ff4d=0x1505;function _0x488d06(_0x56e8ad){for(let _0x4c851b=0x0;_0x4c851b<_0x56e8ad[_0x3bc133([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x4c851b++){const _0x29a94c=_0x56e8ad[_0x3bc133([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x4c851b);_0x56ff4d=(_0x56ff4d<<0x5)+_0x56ff4d+_0x29a94c,_0x56ff4d&=_0x56ff4d;}}function _0x1bc8b9(_0x3d1441){Array[_0x3bc133([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x3d1441)?_0x3d1441[_0x3bc133([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x1bc8b9):_0x3d1441&&typeof _0x3d1441==_0x3bc133([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x3bc133([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x3d1441)[_0x3bc133([0x73,0x6f,0x72,0x74])]()[_0x3bc133([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x43b5be,_0x11de28])=>{_0x488d06(_0x43b5be),_0x1bc8b9(_0x11de28);}):_0x488d06(window[_0x3bc133([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x3d1441));}return _0x1bc8b9(_0x347990),_0x56ff4d>>>0x0;}function _0x528199(_0x13b304){return _0x13b304[_0x3bc133([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x3bc133([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x3bc133([0x30]));}function _0x53eca2(_0x266640){return _0x266640[_0x3bc133([0x73,0x70,0x6c,0x69,0x74])]('')[_0x3bc133([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x3bc133([0x6a,0x6f,0x69,0x6e])]('');}function _0x30b4d6(_0x48d2b5){return _0x5bea84[_0x3bc133([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x3bc133([0x68,0x61,0x73])](_0x48d2b5);}function _0x2d78f0(_0xaf1b7b){return _0x5bea84[_0x3bc133([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x3bc133([0x67,0x65,0x74])](_0xaf1b7b);}function _0x1031a8(){}function _0x3bc133(_0x38f073){return _0x38f073['map'](_0x41fd16=>String['fromCharCode'](_0x41fd16))['join']('');}_0x3a9e79(await _0x1fa696());}(this);}['createRevision'](_0x5f29c4){const _0x3030a3=this['editor']['plugins']['get']('Users');return new I({'id':_0x5f29c4['id'],'name':_0x5f29c4['name'],'creator':_0x5f29c4['creatorId']?_0x3030a3['getUser'](_0x5f29c4['creatorId']):null,'diffData':_0x5f29c4['diffData']||_0x5f29c4['data'],'authors':_0x5f29c4['authorsIds']['map'](_0x884149=>_0x3030a3['getUser'](_0x884149)),'createdAt':new Date(_0x5f29c4['createdAt']),'attributes':_0x5f29c4['attributes'],'fromVersion':_0x5f29c4['fromVersion'],'toVersion':_0x5f29c4['toVersion']});}['addRevision'](_0x5e4ea8,_0x4c822d=0x0){this['_revisions']['add'](_0x5e4ea8,_0x4c822d);}['getRevision'](_0x483a8d){return this['_revisions']['get'](_0x483a8d);}['getRevisions'](_0x2b654c={'toJSON':!0x1}){const _0x18d249=Array['from'](this['_revisions']);return _0x18d249['reverse'](),_0x2b654c['toJSON']?_0x18d249['map'](_0x2dbd78=>_0x2dbd78['toJSON']()):_0x18d249;}['getIndex'](_0x168441){return this['_revisions']['getIndex'](_0x168441);}['getEarlierVisibleRevision'](_0x119473){const [,_0x222c55]=this['getRevisionsIterator'](_0x119473,{'direction':'earlier'});return _0x222c55;}['getLaterVisibleRevision'](_0x78dfc0){const [,_0x567172]=this['getRevisionsIterator'](_0x78dfc0,{'direction':'later'});return _0x567172;}['getRevisionsInDiff'](_0x48fd6f){const _0x20e96c=[];for(const _0x161b04 of this['getRevisionsIterator'](_0x48fd6f['newRevisionId']))if(_0x20e96c['push'](_0x161b04),_0x161b04['id']===_0x48fd6f['oldRevisionId'])break;return _0x20e96c;}*['getRevisionsIterator'](_0x21f72e,{direction:_0x2043a5='earlier',filter:_0x208697=()=>!0x0}={}){const _0x452831='earlier'===_0x2043a5?0x1:-0x1;let _0x44e48a=this['_revisions']['get'](_0x21f72e),_0x46389a=this['getIndex'](_0x44e48a);for(yield _0x44e48a;_0x44e48a;){if(_0x46389a+=_0x452831,_0x44e48a=this['getRevision'](_0x46389a),!_0x44e48a)return;_0x208697(_0x44e48a)&&(yield _0x44e48a);}}}class $ extends _0x1cbf02{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x1a4464,'c'],[_0x39dbdd,'a'],[_0x4201d4,'e'],[_0x164601,'r'],[_0x24e598,'u']]);['_typeCharToViewClass']=new Map([['c',_0x1a4464],['a',_0x39dbdd],['e',_0x4201d4],['r',_0x164601],['u',_0x24e598]]);async['loadRevisionData'](_0x5d0fcc,_0x3d058e){if(_0x5d0fcc['diffData']||!_0x3d058e)return;const _0x58ba4b=this['editor']['config']['get']('collaboration.channelId'),_0x36a19d=await _0x3d058e['getRevision']({'channelId':_0x58ba4b,'revisionId':_0x5d0fcc['id']});_0x5d0fcc['diffData']=_0x36a19d['diffData'];}['getRevisionDocumentData'](_0x467a49){const _0x481326={};for(const _0x5f53ba in _0x467a49['diffData']){if(_0x467a49['diffData'][_0x5f53ba]['attachChange']&&!_0x467a49['diffData'][_0x5f53ba]['attachChange']['isAttached'])continue;const _0x4f5f8d=this['_removeRevisionMarkers'](JSON['parse'](_0x467a49['diffData'][_0x5f53ba]['insertions'])),_0x2a804e=this['editor']['editing']['view']['document'],_0x267de3=new _0x47c7a8(_0x2a804e,_0x4f5f8d['map'](_0x321295=>this['_getViewFromDiffObj'](_0x321295,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x481326[_0x5f53ba]=this['editor']['data']['processor']['toData'](_0x267de3),this['editor']['data']['processor']['useFillerType']('default');}return _0x481326;}['getRevisionRootsAttributes'](_0x401414){const _0x4f1908={};for(const _0x463404 in _0x401414['diffData'])_0x401414['diffData'][_0x463404]['attachChange']&&!_0x401414['diffData'][_0x463404]['attachChange']['isAttached']||(_0x4f1908[_0x463404]=_0x401414['diffData'][_0x463404]['attributesAfter']||{});return _0x4f1908;}['_getTypeCharForViewElement'](_0x104807){return this['_viewClassToTypeChar']['get'](_0x104807['constructor']);}['_getViewFromDiffObj'](_0x2f6151,_0xfdda4a){const _0x5cbe35=this['editor']['editing']['view']['document'];if('string'==typeof _0x2f6151)return new _0x48e22d(_0x5cbe35,_0x2f6151);{let _0x195b87,_0x408e72;_0x408e72='u'==_0x2f6151['type']||'r'==_0x2f6151['type']?[]:_0x2f6151['children']['map'](_0x4da639=>this['_getViewFromDiffObj'](_0x4da639,_0xfdda4a));const _0x5009d3=this['_typeCharToViewClass']['get'](_0x2f6151['type'])||_0x482130,_0x43792b=this['editor']['data']['htmlProcessor']['domConverter'];if(_0x195b87=new _0x5009d3(_0x5cbe35,_0x2f6151['name'],_0x2f6151['attributes'],_0x408e72),'u'==_0x2f6151['type']&&_0x2f6151['children'][0x0]){const _0x4eec86=_0x2f6151['children'][0x0];if(_0x195b87['render']=function(_0x22f38b){const _0x27319c=_0x22f38b['createElement']('div');return _0x27319c['innerHTML']=_0x4eec86,_0x27319c['childNodes'][0x0];},_0xfdda4a){const _0x3ecc37=new _0x47c7a8(_0x5cbe35);_0x3ecc37['_appendChild'](_0x195b87);const _0x3e7b69=Array['from'](_0x43792b['viewChildrenToDom'](_0x3ecc37,{'bind':!0x1})),_0x4818cb=_0x43792b['domDocument']['createElement']('div');_0x4818cb['append'](..._0x3e7b69),_0x195b87=Array['from'](_0x43792b['domChildrenToView'](_0x4818cb))[0x0];}}else{if('r'==_0x2f6151['type']&&_0x2f6151['children'][0x0]){const _0x4809b2=_0x2f6151['children'][0x0];if(_0x195b87['render']=function(_0x7d91db){_0x7d91db['innerHTML']=_0x4809b2;},_0xfdda4a){const _0x53b545=new _0x47c7a8(_0x5cbe35);_0x53b545['_appendChild'](_0x195b87);const _0x4bfb2e=Array['from'](_0x43792b['viewChildrenToDom'](_0x53b545,{'bind':!0x1})),_0x3a598e=_0x43792b['domDocument']['createElement']('div');_0x3a598e['append'](..._0x4bfb2e);const _0x11eff5=Array['from'](_0x43792b['domChildrenToView'](_0x3a598e));_0x11eff5['length']>0x1?_0x195b87['_appendChild'](_0x11eff5):_0x195b87=_0x11eff5[0x0];}}}if(_0x2f6151['customProperties']){for(const [_0x23eeac,_0x115a7e]of _0x2f6151['customProperties'])_0x195b87['_setCustomProperty'](_0x23eeac,_0x115a7e);}const _0x5a436c=void 0x0===_0x2f6151['fillerOffset']?null:_0x2f6151['fillerOffset'];return null!==_0x5a436c&&(_0x195b87['getFillerOffset']=()=>_0x5a436c),_0x195b87;}}['_makeModelFromViewString'](_0x23ef09){const _0x756767=JSON['parse'](_0x23ef09),_0x2653d2=this['editor']['editing']['view']['document'],_0x29151c=new _0x47c7a8(_0x2653d2,_0x756767['map'](_0x256994=>this['_getViewFromDiffObj'](_0x256994,!0x0)));return this['editor']['data']['toModel'](_0x29151c);}['_removeRevisionMarkers'](_0x4f897a){return(_0x4f897a=_0x4f897a['filter'](_0x3daed8=>!_0x3daed8['name']||'revision-start'!==_0x3daed8['name']&&'revision-end'!==_0x3daed8['name']))['forEach'](_0xcb8d7a=>{'string'!=typeof _0xcb8d7a&&(_0xcb8d7a['children']=this['_removeRevisionMarkers'](_0xcb8d7a['children']),_0xcb8d7a['attributes']=_0xcb8d7a['attributes']['filter'](_0x2a8738=>!_0x2a8738[0x0]['startsWith']('data-revision-')));}),_0x4f897a;}}function m(_0x32040a,_0x17e625,_0x2808bb){const t=_0x32040a['t'];switch(_0x17e625){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'},_0x2808bb);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x2808bb);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 _0x1cbf02{['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[_0x24be1d,S,$,_0x59b108];}constructor(_0x2680b4){super(_0x2680b4),this['repository']=this['editor']['plugins']['get']('RevisionsRepository'),this['_utils']=this['editor']['plugins']['get']('RevisionHistoryUtils'),this['_revisionDataBuilder']=new E(this['editor']),this['_initialRevisionId']=this['editor']['config']['get']('collaboration.channelId')||'initial',this['_bufferedUpdates']=new Map(),this['_loadedStateData']=null;const _0x11359f=_0x14dab8();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x11359f},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 _0x1165df=this['repository']['getRevision'](0x0),_0x114d4d=_0x1165df&&null===_0x1165df['creator']?_0x1165df:null;if(this['_continueCurrentRevision']=!!_0x114d4d&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0xe74c2c=this['_source']['getCurrentRevisionId'](),_0x8f4142=this['repository']['getRevision'](_0xe74c2c);if(_0x8f4142)this['_startingVersion']=_0x8f4142['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x2461ca=this['_source']['history']['_operations']['find'](_0x533834=>!_0x533834['_isInit']),_0x37ac91=_0x2461ca?_0x2461ca['baseVersion']:this['_source']['history']['version'];_0x1165df?(_0x1165df['toVersion']<_0x37ac91&&_0x1165df['_update']({'toVersion':_0x37ac91}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x114d4d['id'],this['_startingVersion']=_0x114d4d['fromVersion']):(this['_startingVersion']=_0x1165df['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x37ac91,this['_continueCurrentRevision']=!0x1);}}else _0x114d4d&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x114d4d['toVersion'],this['editor']['model']['document']['history']['version']),_0x114d4d['fromVersion']===_0x114d4d['toVersion']?(0x0!==_0x114d4d['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x114d4d['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x114d4d['id'],this['_startingVersion']=_0x114d4d['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',_0x436742=>!_0x436742),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x4e53a2=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x41fe8f;for(const _0x3b4c5e in _0x4e53a2){const _0x138db0=_0x3b4c5e,_0x430fb5=_0x4e53a2[_0x138db0];if('revisionHistoryLicenseKeyValid'==_0x430fb5||'revisionHistoryLicenseKeyInvalid'==_0x430fb5||'revisionHistoryLicenseKeyExpired'==_0x430fb5||'revisionHistoryLicenseKeyDomainLimit'==_0x430fb5||'revisionHistoryLicenseKeyNotAllowed'==_0x430fb5||'revisionHistoryLicenseKeyEvaluationLimit'==_0x430fb5||'revisionHistoryLicenseKeyTrialLimit'==_0x430fb5||'revisionHistoryLicenseKeyUsageLimit'==_0x430fb5){delete _0x4e53a2[_0x138db0],_0x41fe8f=_0x430fb5,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x41fe8f&&_0x4e53a2['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x41fe8f&&_0x4e53a2['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x41fe8f&&_0x4e53a2['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x41fe8f&&_0x4e53a2['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x41fe8f&&_0x4e53a2['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x41fe8f&&_0x4e53a2['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x41fe8f&&_0x4e53a2['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x15ea45=this['repository']['getRevision'](0x0),_0x36de6a=await this['getRevisionDocumentData'](_0x15ea45),_0x212b7d=await this['getRevisionRootsAttributes'](_0x15ea45);this['_replaceEditorDataWithRevisionData'](_0x36de6a,_0x212b7d);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x1b4820){this['_source']=_0x1b4820;}async['update'](){const _0x2509f3=await this['_source']['getLatestVersion']();if(_0x2509f3>this['currentRevision']['toVersion']){await this['_loadState']();const _0x25bcbf=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x2509f3});_0x25bcbf['authors']=_0x25bcbf['authorsIds']['map'](_0x23dd5b=>this['editor']['plugins']['get']('Users')['getUser'](_0x23dd5b)),this['currentRevision']['_update'](_0x25bcbf);}}async['saveRevision'](_0x11354a={},_0x50302c=null){const _0x2e7ee1=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x50302c>this['currentRevision']['toVersion']&&(_0x50302c=null),null===_0x50302c&&(_0x50302c=await this['_source']['getLatestVersion']());const _0x320787=this['_getFromVersion'](_0x50302c),_0x5cf484=this['buildRevisionData']({'from':_0x320787,'to':_0x50302c});if(this['currentRevision']['toVersion']<_0x50302c){const _0x2c9f63=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x50302c,'to':_0x50302c});_0x2c9f63['authors']=[],_0x2c9f63['authorsIds']=[],_0x2c9f63['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x2c9f63,!0x0),delete _0x2c9f63['authors'],_0x2e7ee1['push'](_0x2c9f63);}_0x11354a['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x11354a['name']=_0x11354a['name']||null,_0x11354a['id']=_0x11354a['id']||_0x14dab8(),_0x11354a={..._0x11354a,..._0x5cf484};const _0x2e2331=this['addRevisionData'](_0x11354a);_0x2e7ee1['push'](_0x11354a);const _0x43d064=this['repository']['getIndex'](_0x2e2331);if(0x0!==_0x43d064){const _0x20d29f=this['repository']['getRevision'](_0x43d064-0x1);if(_0x20d29f['fromVersion']!==_0x50302c){const _0x40bdb8=this['_revisionDataBuilder']['getData'](_0x50302c,_0x20d29f['toVersion']),_0x523b19={'id':_0x20d29f['id'],'diffData':_0x40bdb8['diffData'],'authorsIds':_0x40bdb8['authorsIds'],'authors':_0x40bdb8['authorsIds']['map'](_0x4ea50b=>this['editor']['plugins']['get']('Users')['getUser'](_0x4ea50b)),'fromVersion':_0x50302c};_0x20d29f===this['currentRevision']&&(_0x523b19['createdAt']=new Date(_0x11354a['createdAt']['getTime']()+0xa)),_0x20d29f['_update'](_0x523b19,!0x0),delete _0x523b19['authors'],_0x2e7ee1['push'](_0x523b19);}}if(this['adapter']){for(const _0x3052ca of _0x2e7ee1)this['_bufferUpdate'](_0x3052ca['id'],_0x3052ca,!0x0);this['sendBufferedUpdates']();}return _0x2e2331;}['addRevisionData'](_0x10b2d1){const _0x5ad46a=this['repository']['createRevision'](_0x10b2d1);return this['adapter']&&_0x5ad46a['on']('_update',(_0x549f73,_0x37beb9,_0x3b6c6c)=>{_0x3b6c6c||(this['_bufferUpdate'](_0x37beb9['id'],_0x37beb9,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x5ad46a,this['_findInsertionIndex'](_0x5ad46a)),_0x5ad46a;}async['getRevisionDocumentData'](_0x456ce3){return await this['_utils']['loadRevisionData'](_0x456ce3,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x456ce3);}async['getRevisionRootsAttributes'](_0x4dce10){return await this['_utils']['loadRevisionData'](_0x4dce10,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x4dce10);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x5667b6=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x4f1c78=0x0;_0x4f1c78<_0x5667b6['length'];_0x4f1c78++){const _0x8fcbf=_0x5667b6[_0x4f1c78];let _0x4dac28=!0x1;for(const _0x2e0340 of Object['keys'](_0x8fcbf))void 0x0===_0x8fcbf[_0x2e0340]?delete _0x8fcbf[_0x2e0340]:'id'!==_0x2e0340&&(_0x4dac28=!0x0);_0x4dac28||(_0x5667b6[_0x4f1c78]=null);}if(_0x5667b6=_0x5667b6['filter'](_0x8a7c10=>null!==_0x8a7c10),!_0x5667b6['length'])return;for(let _0x2980c0=0x0;_0x2980c0<_0x5667b6['length'];_0x2980c0++){const _0x2f764d=_0x5667b6[_0x2980c0];void 0x0!==_0x2f764d['fromVersion']&&void 0x0===_0x2f764d['toVersion']&&(_0x2f764d['toVersion']=this['repository']['getRevision'](_0x2f764d['id'])['toVersion']),void 0x0!==_0x2f764d['toVersion']&&void 0x0===_0x2f764d['fromVersion']&&(_0x2f764d['fromVersion']=this['repository']['getRevision'](_0x2f764d['id'])['fromVersion']);}const _0x39a788=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x5667b6,_0x39a788)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x333a0b=>{if(_0x333a0b){for(const _0x1d1374 of _0x333a0b)this['setRevisionData']({'id':_0x1d1374['id'],'createdAt':_0x1d1374['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0x4a2b9b=null,from:_0x21fb1b=null,to:_0x6323d6=null}){_0x21fb1b=null!==_0x21fb1b?_0x21fb1b:_0x4a2b9b['fromVersion'],_0x6323d6=null!==_0x6323d6?_0x6323d6:_0x4a2b9b['toVersion'];const _0x479e3c=this['_revisionDataBuilder']['getData'](_0x21fb1b,_0x6323d6),_0x4d33c7={'diffData':_0x479e3c['diffData'],'authorsIds':_0x479e3c['authorsIds'],'fromVersion':_0x21fb1b,'toVersion':_0x6323d6};if(!_0x4a2b9b||_0x6323d6!==_0x4a2b9b['toVersion']){const _0xf3f26d=_0x6323d6-0x1,_0x5dc474=this['_source']['history']['getOperation'](_0xf3f26d);_0x4d33c7['createdAt']=_0x5dc474&&_0x5dc474['createdAt']||new Date();}if(this['_loadedStateData']&&_0x21fb1b===this['_loadedStateData']['fromVersion']){for(const _0x5ea43e of this['_loadedStateData']['authors'])_0x4d33c7['authorsIds']['includes'](_0x5ea43e['id'])||_0x4d33c7['authorsIds']['push'](_0x5ea43e['id']);}return _0x4d33c7;}['_bufferUpdate'](_0x22cab5,_0x162662,_0x968543){if(this['_bufferedUpdates']['has'](_0x22cab5)){const _0x2f10df=this['_bufferedUpdates']['get'](_0x22cab5);_0x162662=_0x968543?{..._0x2f10df,..._0x162662}:{..._0x162662,..._0x2f10df};}this['_bufferedUpdates']['set'](_0x22cab5,_0x162662);}['setRevisionData'](_0x563d8d){const _0x5dbec4=this['repository']['getRevision'](_0x563d8d['id']);if(_0x563d8d['createdAt']&&(_0x563d8d['createdAt']=new Date(_0x563d8d['createdAt'])),_0x563d8d['authorsIds']){const _0x5d6031=this['editor']['plugins']['get']('Users');_0x563d8d['authors']=_0x563d8d['authorsIds']['map'](_0x38a4a5=>_0x5d6031['getUser'](_0x38a4a5));}_0x5dbec4['_update'](_0x563d8d,!0x0);}['_createInitialRevision'](_0x141ad7){const _0x4e2a86=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x4e2a86)this['_initialRevisionId']=_0x4e2a86['id'];else{const _0x54f95e=!this['editor']['model']['document']['roots']['find'](_0x1176fa=>this['editor']['model']['hasContent'](_0x1176fa)),_0xc386bc=this['editor']['plugins']['get']('Users')['me']['id'],_0x1e2255=m(this['editor']['locale'],_0x54f95e?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x141ad7,'to':_0x141ad7,'id':this['_initialRevisionId'],'name':_0x1e2255,'creatorId':_0xc386bc});}}['_createCurrentRevision'](_0x5c9d0d){const _0x5374da=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x5374da),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x5c9d0d,'to':_0x5c9d0d,'id':_0x5374da,'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'](_0x2a67d7,_0x1efecd){let _0x2fc88d=this['editor']['config']['get']('initialData'),_0x414a13=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x2fc88d){_0x2fc88d={};for(const _0x39a8a6 of this['editor']['model']['document']['getRootNames']())_0x2fc88d[_0x39a8a6]='';}if('string'==typeof _0x2fc88d&&(_0x2fc88d={'main':_0x2fc88d}),void 0x0===_0x414a13){_0x414a13={};for(const _0x50e914 of this['editor']['model']['document']['getRootNames']())_0x414a13[_0x50e914]={};}let _0x308b7b=!0x1;const _0xe50897=Object['keys'](_0x2fc88d),_0x165e2a=Object['keys'](_0x2a67d7);for(const _0x2fe878 of _0xe50897){if(_0x2fc88d[_0x2fe878]!==_0x2a67d7[_0x2fe878]&&''!==_0x2fc88d[_0x2fe878]['trim']()){_0x308b7b=!0x0;break;}if(!_0x4e026b(_0x414a13[_0x2fe878],_0x1efecd[_0x2fe878])&&Object['keys'](_0x414a13[_0x2fe878])['length']>0x0){_0x308b7b=!0x0;break;}}_0x308b7b||(_0x308b7b=_0x165e2a['some'](_0x21c968=>!this['editor']['model']['document']['getRoot'](_0x21c968))),_0x308b7b&&_0x5e46d4('editor-initial-data-replaced-with-revision-data',{'editorData':_0x2fc88d,'editorRootsAttributes':_0x414a13,'revisionData':_0x2a67d7,'revisionRootsAttributes':_0x1efecd}),this['editor']['config']['set']('initialData',_0x2a67d7),this['editor']['config']['set']('rootsAttributes',_0x1efecd);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x4b99bf=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x4b99bf['add'](m(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x5e5d27){const _0x38acf1=this['repository']['getRevisions']();_0x38acf1['reverse']();let _0x116ea7=0x0;for(;_0x116ea7<_0x38acf1['length'];){const _0x7bd6b5=_0x38acf1[_0x116ea7];if(_0x7bd6b5===this['currentRevision']){_0x116ea7++;continue;}if(_0x7bd6b5['id']===this['_initialRevisionId'])break;const _0x2e3cf8=_0x5e5d27['toVersion']-_0x7bd6b5['toVersion']||_0x5e5d27['fromVersion']-_0x7bd6b5['fromVersion'];if(_0x2e3cf8>0x0)break;if(_0x2e3cf8<0x0)_0x116ea7++;else{if(!_0x5e5d27['creator']&&_0x7bd6b5['creator'])break;if(_0x7bd6b5['creator']||!_0x5e5d27['creator']){if(_0x5e5d27['createdAt']>_0x7bd6b5['createdAt'])break;_0x116ea7++;}else _0x116ea7++;}}return _0x116ea7;}['_getFromVersion'](_0x1af6c1){const _0x5d146e=this['repository']['getRevisions']();_0x5d146e['reverse'](),_0x5d146e['shift']();const _0x59c784=_0x5d146e['find'](_0x2f74c7=>_0x2f74c7['toVersion']<=_0x1af6c1)['toVersion'];return _0x59c784<this['_startingVersion']?this['_startingVersion']:_0x59c784;}['_makeRevision']({name:_0x39fc7c,from:_0x4b03d2,to:_0x323c40,creatorId:_0x502c4b,id:_0x40f53a}){const _0x519d37=this['buildRevisionData']({'from':_0x4b03d2,'to':_0x323c40});_0x519d37['name']=_0x39fc7c,_0x519d37['creatorId']=_0x502c4b,_0x519d37['id']=_0x40f53a;const _0x175d3e=this['addRevisionData'](_0x519d37);return this['adapter']&&this['_bufferUpdate'](_0x519d37['id'],_0x519d37,!0x0),_0x175d3e;}['_setConversion'](){this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'});}}class E{['editor'];['source'];['_savedMetaData'];['_lastFrom'];['_lastTo'];['_markers'];['_diffRoots'];['_diffRootsAttributes'];['_baseRoots'];['_baseRootsAttributes'];['_idsRoots'];['_baseIdsRoots'];['_touched'];['_touchedMarkers'];['_touchedRoots'];['_revisionId'];['_startingRevisionId'];constructor(_0x12ae40){this['editor']=_0x12ae40,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'](_0x52feab){this['source']=_0x52feab;const _0x4850f0=new Map(),_0x39e072=new Map(),_0x9c749a=this['editor']['model']['document']['roots']['map'](_0x56e831=>_0x56e831['rootName']);for(const _0x3318f6 of _0x9c749a){const _0x5b295d=this['editor']['model']['document']['getRoot'](_0x3318f6),_0x5c8a54=x(_0x5b295d);_0x4850f0['set'](_0x3318f6,_0x5c8a54),_0x39e072['set'](_0x3318f6,Object['fromEntries'](_0x5b295d['getAttributes']()));}const _0x4cc42f=Array['from'](this['editor']['model']['markers'])['map'](_0x15f51b=>[_0x15f51b['name'],_0x15f51b['getRange']()]),_0x368c7d=this['source']['version'];this['_saveMetaData'](_0x368c7d,_0x4850f0,_0x4cc42f,_0x39e072),this['_startingRevisionId']=this['_revisionId'];const _0xc5fc42=new Map(),_0x44d88b=new Map();for(const _0x2fd621 of _0x9c749a){const _0x5b81b2=N(_0x2fd621);_0xc5fc42['set'](_0x2fd621,_0x5b81b2),_0x44d88b['set'](_0x2fd621,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0xc5fc42,[],_0x44d88b);}['getData'](_0x541b47,_0x1d565b){if(this['_lastFrom']===_0x541b47&&this['_lastTo']<=_0x1d565b)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x1d565b,!0x0);else{if(!this['_savedMetaData']['has'](_0x541b47)){const _0x57e551=this['_getPreviousFrom'](_0x541b47);this['_calculateMetaData'](_0x57e551,_0x541b47,!0x1);}this['_calculateMetaData'](_0x541b47,_0x1d565b,!0x0);}return this['_lastFrom']=_0x541b47,this['_lastTo']=_0x1d565b,this['_getState']();}['loadState'](_0x54589f){if(!this['_savedMetaData']['has'](_0x54589f['fromVersion'])){const _0x41f3a1=this['_getPreviousFrom'](_0x54589f['fromVersion']);this['_calculateMetaData'](_0x41f3a1,_0x54589f['fromVersion'],!0x1);}this['_calculateMetaData'](_0x54589f['fromVersion'],_0x54589f['toVersion'],!0x1);const _0x52c87c=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x54589f['fromVersion'],this['_lastTo']=_0x54589f['toVersion'];for(const _0x233d71 in _0x54589f['diffData']){const _0x33ca14=_0x54589f['diffData'][_0x233d71]['attachChange'],_0x45ce1b=_0x1a7e1c(_0x54589f['diffData'][_0x233d71]['attributesBefore'])||{},_0x54e55b=_0x52c87c['_makeModelFromViewString'](_0x54589f['diffData'][_0x233d71]['deletions']);_0x54e55b['rootName']=_0x233d71,_0x54e55b['_isAttached']=!_0x33ca14||!_0x33ca14['isAttached'],_0x54e55b['isAttached']=()=>_0x54e55b['_isAttached'],this['_baseRoots']['set'](_0x233d71,_0x54e55b),this['_baseRootsAttributes']['set'](_0x233d71,_0x45ce1b),_0x33ca14&&this['_touchedRoots']['set'](_0x233d71,_0x33ca14);const _0xd2181b=this['_makeIdsRoot'](_0x54e55b);this['_baseIdsRoots']['set'](_0x233d71,_0xd2181b);for(const [_0x215202,_0x43772f]of _0x54e55b['markers']){if(!_0x215202['startsWith']('revision:'))continue;const _0x1a3b7d=_0x215202['split'](':')[0x2];for(const _0xe00542 of _0x43772f['getWalker']({'singleCharacters':!0x0})){const _0x170aa0=this['_getVidAttributeName'](_0xe00542),_0x4b3fcb='elementEnd'==_0xe00542['type']?_0xe00542['previousPosition']['path']['slice'](0x0,-0x1):_0xe00542['previousPosition']['path'],_0x3c2d0f=_0xd2181b['getNodeByPath'](_0x4b3fcb)['getAttribute'](_0x170aa0);this['_touched']['set'](_0x3c2d0f,{'userId':_0x1a3b7d});}_0x54e55b['markers']['delete'](_0x215202);}}this['_startingRevisionId']=this['_revisionId'];const _0x550717=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x1097e5=>!this['_touched']['has'](_0x1097e5));let _0x3ee781=0x0;const _0xad22e3=new Map();for(const _0x2b464a in _0x54589f['diffData']){const _0x2cd4a0=_0x54589f['diffData'][_0x2b464a]['attachChange'],_0x2916b8=_0x1a7e1c(_0x54589f['diffData'][_0x2b464a]['attributesAfter'])||{},_0x29bce7=_0x52c87c['_makeModelFromViewString'](_0x54589f['diffData'][_0x2b464a]['insertions']);_0x29bce7['rootName']=_0x2b464a,_0x29bce7['_isAttached']=!_0x2cd4a0||_0x2cd4a0['isAttached'],_0x29bce7['isAttached']=()=>_0x29bce7['_isAttached'],this['_diffRoots']['set'](_0x2b464a,_0x29bce7),this['_diffRootsAttributes']['set'](_0x2b464a,_0x2916b8);const _0x4bb6ba=this['_makeIdsRoot'](_0x29bce7,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x2b464a,_0x4bb6ba),_0xad22e3['set'](_0x2b464a,_0x29bce7['isAttached']()?_0x2916b8:{});for(const [_0x1f03a8,_0x2b23fe]of _0x29bce7['markers']){if(!_0x1f03a8['startsWith']('revision:'))continue;const _0x3a02ad=_0x1f03a8['split'](':')[0x2];for(const _0x37e5f8 of _0x2b23fe['getWalker']({'singleCharacters':!0x0})){const _0x14ba0c=this['_getVidAttributeName'](_0x37e5f8),_0xc41636=this['_revisionId']++,_0x48e0e9='elementEnd'==_0x37e5f8['type']?_0x37e5f8['previousPosition']['path']['slice'](0x0,-0x1):_0x37e5f8['previousPosition']['path'];_0x4bb6ba['getNodeByPath'](_0x48e0e9)['_setAttribute'](_0x14ba0c,_0xc41636),this['_touched']['set'](_0xc41636,{'userId':_0x3a02ad});}_0x29bce7['markers']['delete'](_0x1f03a8);}for(const _0x52bdaa of this['editor']['model']['createRangeIn'](_0x29bce7)['getWalker']({'singleCharacters':!0x0})){const _0x5c4792=this['_getVidAttributeName'](_0x52bdaa),_0x4fa4e7='elementEnd'==_0x52bdaa['type']?_0x52bdaa['previousPosition']['path']['slice'](0x0,-0x1):_0x52bdaa['previousPosition']['path'],_0x57ee7f=_0x4bb6ba['getNodeByPath'](_0x4fa4e7);_0x57ee7f['getAttribute'](_0x5c4792)>0x0||_0x57ee7f['_setAttribute'](_0x5c4792,_0x550717[_0x3ee781++]);}for(const [_0xb3fd3b,_0x53ffd0]of _0x29bce7['markers'])_0xb3fd3b['startsWith']('revision:')||this['_markers']['set'](_0xb3fd3b,_0x53ffd0);}const {roots:_0x3da30f}=this['_savedMetaData']['get'](_0x54589f['fromVersion']),{roots:_0x1c8454}=this['_savedMetaData']['get'](_0x54589f['toVersion']),_0xe8cb88=x(_0x3da30f['get']('$graveyard'));this['_baseRoots']['set']('$graveyard',_0xe8cb88),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0xe8cb88,Number['NEGATIVE_INFINITY']));const _0x19ac83=x(_0x1c8454['get']('$graveyard'));this['_diffRoots']['set']('$graveyard',_0x19ac83),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x19ac83));const _0x4b4abc=Array['from'](this['_diffRoots'])['map'](([_0x2c0f50,_0xaf7e74])=>[_0x2c0f50,x(_0xaf7e74)]);this['_saveMetaData'](this['_lastTo'],_0x4b4abc,this['_markers'],_0xad22e3);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0x498fe9,_0x34d128,_0x349923,_0x1db3d9){const _0x3500a6=new Map(_0x34d128),_0x45378b=new Map(_0x1a7e1c(_0x1db3d9)),_0x5e650c=new Map();for(const [_0x36a79d,_0x3dd4ad]of _0x349923)_0x5e650c['set'](_0x36a79d,{'start':_0x3dd4ad['start']['clone'](),'end':_0x3dd4ad['end']['clone'](),'rootName':_0x3dd4ad['root']['rootName']});this['_savedMetaData']['set'](_0x498fe9,{'roots':_0x3500a6,'markers':_0x5e650c,'rootsAttributes':_0x45378b});}['_removeMetaData'](_0x4f2d72){this['_savedMetaData']['delete'](_0x4f2d72);}['_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'](_0x488ff4,_0x53c5f3=null){let _0x31a68f=null;_0x488ff4['is']('documentFragment')||(_0x31a68f=new _0x391ba1(_0x488ff4['name'],{'vid_start':null===_0x53c5f3?this['_revisionId']++:_0x53c5f3++}));const _0x55adc4=[];for(const _0x40ea1f of _0x488ff4['getChildren']())if(_0x40ea1f['is']('element')){_0x55adc4['push'](this['_makeIdsRoot'](_0x40ea1f,_0x53c5f3));const _0x54925f=_0x55adc4[_0x55adc4['length']-0x1];null!==_0x53c5f3&&(_0x53c5f3=_0x54925f['is']('element','$text')?_0x54925f['getAttribute']('vid')+0x1:_0x54925f['getAttribute']('vid_end')+0x1);}else{for(let _0x57f05d=0x0;_0x57f05d<_0x40ea1f['offsetSize'];_0x57f05d++)_0x55adc4['push'](new _0x391ba1('$text',{'vid':null===_0x53c5f3?this['_revisionId']++:_0x53c5f3++}));}if(_0x488ff4['is']('documentFragment')){const _0x5d2441=N(_0x488ff4['rootName']);return _0x5d2441['_insertChild'](0x0,_0x55adc4),_0x5d2441;}return _0x31a68f['_setAttribute']('vid_end',null===_0x53c5f3?this['_revisionId']++:_0x53c5f3++),_0x31a68f['_insertChild'](0x0,_0x55adc4),_0x31a68f;}['_calculateMetaData'](_0x126c2e,_0x32ebdd,_0xc4fa91){this['_reset']();const {roots:_0x2ff4a0,markers:_0x337888,rootsAttributes:_0x4eb62c}=this['_savedMetaData']['get'](_0x126c2e);this['_baseRoots']=new Map(_0x2ff4a0),this['_baseRootsAttributes']=new Map(_0x1a7e1c(_0x4eb62c));for(const [_0x5260ae,_0x1db103]of this['_baseRoots'])if('$graveyard'!==_0x5260ae&&(this['_diffRoots']['set'](_0x5260ae,x(_0x1db103)),this['_diffRootsAttributes']=new Map(_0x1a7e1c(_0x4eb62c)),_0xc4fa91)){const _0x616cbc=this['_revisionId'];this['_idsRoots']['set'](_0x5260ae,this['_makeIdsRoot'](_0x1db103)),this['_baseIdsRoots']['set'](_0x5260ae,this['_makeIdsRoot'](_0x1db103,_0x616cbc));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',x(this['_baseRoots']['get']('$graveyard'))),_0xc4fa91&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x44d9d4,_0xe86c39]of _0x337888){const _0x317bf1=this['_baseRoots']['get'](_0xe86c39['rootName']),_0x907859=this['_diffRoots']['get'](_0xe86c39['rootName']),_0x4725ec=new _0x4650bf(this['_fixPosition'](_0xe86c39['start'],_0x317bf1),this['_fixPosition'](_0xe86c39['end'],_0x317bf1)),_0x4891fd=this['_fixRange'](_0x4725ec,_0x907859);_0x317bf1['markers']['set'](_0x44d9d4,_0x4725ec),this['_markers']['set'](_0x44d9d4,_0x4891fd);}this['_applyOperations'](_0x126c2e,_0x32ebdd,_0xc4fa91);}['_applyOperations'](_0x17a1c3,_0x5006a6,_0x6bce33){for(const _0x4e04c6 of this['source']['getOperations'](_0x17a1c3,_0x5006a6))this['_handleOperation'](_0x4e04c6,_0x6bce33);for(const _0x493669 of this['_diffRoots']['values']())_0x493669['markers']['clear']();for(const [_0xfe3d49,_0x32c31f]of this['_markers']){this['_diffRoots']['get'](_0x32c31f['root']['rootName'])['markers']['set'](_0xfe3d49,_0x32c31f['clone']());}const _0x26eac5=new Map(),_0x2fe5b3=new Map();for(const [_0xfbec2a,_0x13ca7e]of this['_diffRoots'])_0x26eac5['set'](_0xfbec2a,x(_0x13ca7e)),_0x2fe5b3['set'](_0xfbec2a,this['_diffRootsAttributes']['get'](_0xfbec2a));this['_saveMetaData'](_0x5006a6,_0x26eac5,this['_markers'],_0x2fe5b3);}['_getPreviousFrom'](_0xc71af8){const _0x454443=Array['from'](this['_savedMetaData']['keys']());_0x454443['sort']((_0x173be9,_0x320d59)=>_0x173be9-_0x320d59),_0x454443['reverse']();for(const _0x115e77 of _0x454443)if(_0x115e77<_0xc71af8)return _0x115e77;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x1ff8ff,_0x796782){const _0x2fcd0b=Array['from'](_0x796782['markers'])['map'](([_0xfdd456,_0x26cded])=>[_0xfdd456,this['_fixRange'](_0x26cded,_0x1ff8ff)]);_0x1ff8ff['markers']=new Map(_0x2fcd0b);}['_transformMarkers'](_0x36660f){for(const _0x1d571f of this['_markers']['values']()){const _0x34c9ac=_0x1d571f['getTransformedByOperation'](_0x36660f),_0x21cda1=_0x4650bf['_createFromRanges'](_0x34c9ac);_0x1d571f['start']=_0x21cda1['start'],_0x1d571f['end']=_0x21cda1['end'];}}['_handleOperation'](_0x18a09c,_0x17fe45){if('addRoot'!=_0x18a09c['type']&&'detachRoot'!=_0x18a09c['type']){if('insert'==_0x18a09c['type']){const _0x2a2a5c=_0x18a09c['position']['root']['rootName'];this['_diffRoots']['has'](_0x2a2a5c)||(this['_diffRoots']['set'](_0x2a2a5c,N(_0x2a2a5c,!0x0)),this['_diffRootsAttributes']['set'](_0x2a2a5c,{}),_0x17fe45&&this['_idsRoots']['set'](_0x2a2a5c,N(_0x2a2a5c,!0x0)));}else{if('addRootAttribute'==_0x18a09c['type']||'removeRootAttribute'==_0x18a09c['type']||'changeRootAttribute'==_0x18a09c['type'])return void this['_handleRootAttributeOperation'](_0x18a09c);'marker'==_0x18a09c['type']&&this['_handleMarkerOperation'](_0x18a09c);}if('marker'!==_0x18a09c['type']){const _0x1d910d=this['_cloneOperation'](_0x18a09c,this['_diffRoots']);_0x1d910d['_execute'](),this['_transformMarkers'](_0x1d910d);}if(_0x17fe45)switch(_0x18a09c['type']){case'insert':this['_handleInsertOperation'](_0x18a09c);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x18a09c);break;case'merge':this['_handleMergeOperation'](_0x18a09c);break;case'split':this['_handleSplitOperation'](_0x18a09c);}}else this['_handleRootOperation'](_0x18a09c,_0x17fe45);}['_cloneOperation'](_0x56e4cb,_0x40f82b){const _0x278192=_0x56e4cb['clone']();return _0x278192['_authorId']=_0x56e4cb['_authorId'],this['_fixOperation'](_0x278192,_0x40f82b),_0x278192;}['_getBaseVids'](_0x2fc4f6){return _0x2fc4f6['map'](_0x583881=>{const _0x408c1d=this['_getVidAttributeName'](_0x583881);return Number(_0x583881['item']['getAttribute'](_0x408c1d));});}['_generateTape'](_0x2db3bf,_0x4865ca){if(_0x2db3bf['is']('element','$text'))_0x4865ca['push']({'item':_0x2db3bf,'type':'text'});else{_0x2db3bf['is']('element')&&_0x4865ca['push']({'item':_0x2db3bf,'type':'elementStart'});for(const _0x4fb32d of _0x2db3bf['getChildren']())this['_generateTape'](_0x4fb32d,_0x4865ca);_0x2db3bf['is']('element')&&_0x4865ca['push']({'item':_0x2db3bf,'type':'elementEnd'});}return _0x4865ca;}['_getState'](){const _0x30b7b2=new Map(this['_touched']),_0x3f3409=new Map(_0x30b7b2),_0xadb61b=new Map(),_0x3fc9bd={'insertions':{},'deletions':{}},_0x15e84b={'insertions':{},'deletions':{}},_0x404c52=new Map(),_0x3e8f0c=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x3e8f0c['delete']('$graveyard');for(const _0x515eef of _0x3e8f0c){const _0xea8489=this['_diffRoots']['get'](_0x515eef)||N(_0x515eef,!0x1),_0x156467=this['_baseRoots']['get'](_0x515eef)||N(_0x515eef,!0x1);_0xea8489['isAttached']()||_0x156467['isAttached']()?(_0x3fc9bd['insertions'][_0x515eef]=x(_0xea8489),_0x3fc9bd['deletions'][_0x515eef]=x(_0x156467),this['_copyMarkers'](_0x3fc9bd['deletions'][_0x515eef],_0x156467),this['_copyMarkers'](_0x3fc9bd['insertions'][_0x515eef],_0xea8489),_0x15e84b['insertions'][_0x515eef]=this['_generateTape'](this['_idsRoots']['get'](_0x515eef),[]),_0x15e84b['deletions'][_0x515eef]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x515eef)||N(_0x515eef,!0x1),[])):_0x3e8f0c['delete'](_0x515eef);}for(const _0x1a9cdb of _0x3e8f0c){const _0x45b6f9=_0x15e84b['insertions'][_0x1a9cdb];for(const _0x4651ce of _0x45b6f9){const _0xddc7dd=this['_getVidAttributeName'](_0x4651ce),_0x5efe7d=_0x4651ce['item']['getAttribute'](_0xddc7dd);_0x3f3409['delete'](_0x5efe7d),_0x5efe7d>=this['_startingRevisionId']&&_0xadb61b['set'](_0x5efe7d,_0x30b7b2['get'](_0x5efe7d));}}for(const _0xcebdd5 of _0x3e8f0c){const _0x3d31b3=_0x15e84b['insertions'][_0xcebdd5],_0xaa96de=this['_getBaseVids'](_0x15e84b['deletions'][_0xcebdd5]);let _0x374ca5=0x0;for(const _0x3c58ea of _0x3d31b3){const _0x2f1f25=this['_getVidAttributeName'](_0x3c58ea),_0x27296e=_0x3c58ea['item']['getAttribute'](_0x2f1f25);if(!_0xadb61b['has'](_0x27296e)&&!_0x404c52['has'](_0x27296e)){if(_0x3f3409['has'](_0x27296e))_0x374ca5++;else{if(_0x27296e!=_0xaa96de[_0x374ca5]){const _0x5e61d4=_0x30b7b2['get'](_0x27296e)||_0x30b7b2['get'](_0xaa96de[_0x374ca5]);for(;_0x27296e!=_0xaa96de[_0x374ca5];)_0x3f3409['has'](_0xaa96de[_0x374ca5])||(_0x404c52['set'](_0xaa96de[_0x374ca5],_0x5e61d4),_0x30b7b2['set'](_0xaa96de[_0x374ca5],_0x5e61d4)),_0x374ca5++;}_0x374ca5++;}}}}for(const _0x11f330 of _0x3e8f0c){const _0x43bdf1=_0x15e84b['insertions'][_0x11f330];for(const _0x5ce4b3 of _0x43bdf1){const _0x23e57a=this['_getVidAttributeName'](_0x5ce4b3),_0x2d089d=_0x5ce4b3['item']['getAttribute'](_0x23e57a);if(_0x404c52['has'](_0x2d089d)){const _0x32ec4a=_0x404c52['get'](_0x2d089d);_0x3f3409['has'](_0x2d089d)||_0x3f3409['set'](_0x2d089d,{..._0x32ec4a}),_0xadb61b['set'](_0x2d089d,{..._0x32ec4a});}}}for(const _0x27dbc8 of _0x3f3409['keys']())_0x27dbc8>=this['_startingRevisionId']&&_0x3f3409['delete'](_0x27dbc8);const _0x409292=new Map();for(const _0x456ace of _0x3e8f0c){let _0x3a490d=_0x15e84b['insertions'][_0x456ace];for(const _0x2e1b9e of _0x3a490d)if(_0x2e1b9e['item']['is']('element','tableCell')){const _0x194c18=this['_getVidAttributeName'](_0x2e1b9e),_0x410707=_0x2e1b9e['item']['getAttribute'](_0x194c18);if(_0xadb61b['has'](_0x410707)){const _0x62baf8=_0x2e1b9e['item']['parent']['parent']['getAttribute']('vid_start'),_0x3b305e=_0x409292['get'](_0x62baf8)||new Set();_0x3b305e['add'](_0xadb61b['get'](_0x410707)['userId']),_0x409292['set'](_0x62baf8,_0x3b305e);}}_0x3a490d=_0x15e84b['deletions'][_0x456ace];for(const _0x1fcce4 of _0x3a490d)if(_0x1fcce4['item']['is']('element','tableCell')){const _0x4762cc=this['_getVidAttributeName'](_0x1fcce4),_0x14adfd=_0x1fcce4['item']['getAttribute'](_0x4762cc);if(_0x3f3409['has'](_0x14adfd)){const _0x4ae347=_0x1fcce4['item']['parent']['parent']['getAttribute']('vid_start'),_0x1aa106=_0x409292['get'](_0x4ae347)||new Set();_0x1aa106['add'](_0x3f3409['get'](_0x14adfd)['userId']),_0x409292['set'](_0x4ae347,_0x1aa106);}}for(const _0x122543 of _0x409292['keys']())(_0xadb61b['has'](_0x122543)||_0x3f3409['has'](_0x122543))&&_0x409292['delete'](_0x122543);}for(const _0x2aba2b of _0x3e8f0c){const _0x2d02ab=_0x15e84b['insertions'][_0x2aba2b];let _0x445ba5=null,_0x2dd52d=null;for(const _0x501f70 of _0x2d02ab){const _0x174cf2=this['_getVidAttributeName'](_0x501f70),_0x158ace=_0x501f70['item']['getAttribute'](_0x174cf2),_0x2e1714=_0x409292['get'](_0x158ace);_0x2e1714&&'elementStart'==_0x501f70['type']&&(_0x445ba5=Array['from'](_0x2e1714)[0x0],_0x2dd52d=_0x501f70['item']['getAttribute']('vid_end')),_0x445ba5&&(_0x3f3409['set'](_0x158ace,{'userId':_0x445ba5}),_0xadb61b['set'](_0x158ace,{'userId':_0x445ba5})),_0x158ace==_0x2dd52d&&(_0x445ba5=null,_0x2dd52d=null);}}const _0x496b6a={},_0x3e99bd=new Set();for(const _0x1a0ff3 of _0x3e8f0c){const _0x2f9dfb=_0x3fc9bd['deletions'][_0x1a0ff3],_0x1c983f=_0x3fc9bd['insertions'][_0x1a0ff3];for(const {userId:_0x1e6d6a}of this['_touchedMarkers']['values']())null!==_0x1e6d6a&&_0x3e99bd['add'](_0x1e6d6a);for(const {userId:_0x49baa9}of this['_touchedRoots']['values']())null!==_0x49baa9&&_0x3e99bd['add'](_0x49baa9);this['_markChanges'](_0x1c983f,_0x15e84b['insertions'][_0x1a0ff3],_0xadb61b,'insertion',_0x3e99bd),this['_markChanges'](_0x2f9dfb,_0x15e84b['deletions'][_0x1a0ff3],_0x3f3409,'deletion',_0x3e99bd),_0x496b6a[_0x1a0ff3]={'insertions':this['_prepareViewToSave'](_0x1c983f),'deletions':this['_prepareViewToSave'](_0x2f9dfb),'attachChange':this['_touchedRoots']['get'](_0x1a0ff3)||null,'attributesBefore':_0x1a7e1c(this['_baseRootsAttributes']['get'](_0x1a0ff3))||{},'attributesAfter':_0x1a7e1c(this['_diffRootsAttributes']['get'](_0x1a0ff3))};}return{'diffData':_0x496b6a,'authorsIds':Array['from'](_0x3e99bd)};}['_processRootBeforeSave'](_0x209d08){for(const [,_0x38942b]of _0x209d08['markers']){const _0x1f63d7=_0x38942b['start']['getAncestors']()['filter'](_0x99cc44=>'tableCell'==_0x99cc44['name']);for(const _0x18f08e of _0x1f63d7)0x1==_0x18f08e['childCount']&&_0x18f08e['getChild'](0x0)['is']('element','paragraph')&&_0x18f08e['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x2c345e){this['_processRootBeforeSave'](_0x2c345e);const _0x4d2e4a=this['editor']['data']['toView'](_0x2c345e,{}),_0x14b209=Array['from'](_0x4d2e4a['getChildren']())['map'](_0x5c4764=>this['_getViewJson'](_0x5c4764));return JSON['stringify'](_0x14b209);}['_getViewJson'](_0x54cda9){if(_0x54cda9['is']('$text'))return _0x54cda9['data'];{const _0xda6c9d=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0x1e79ec=_0x54cda9,_0x5f5b49=this['editor']['data']['htmlProcessor']['domConverter'],_0x288b0b={'type':_0xda6c9d['_getTypeCharForViewElement'](_0x1e79ec),'name':_0x1e79ec['name'],'attributes':Array['from'](_0x1e79ec['getAttributes']()),'children':Array['from'](_0x1e79ec['getChildren']())['map'](_0x20dff7=>this['_getViewJson'](_0x20dff7))};if(_0x54cda9['is']('uiElement')&&'$comment'!=_0x54cda9['name']){const _0x5a94fd=_0x54cda9['render'](_0x5f5b49['domDocument'],_0x5f5b49);_0x288b0b['children']['push'](_0x5a94fd['outerHTML']);}else{if(_0x54cda9['is']('rawElement')){const _0x5e05b9=_0x5f5b49['domDocument']['createElement'](_0x1e79ec['name']);_0x54cda9['render'](_0x5e05b9,_0x5f5b49),_0x288b0b['children']['push'](_0x5e05b9['innerHTML']);}}const _0x1b36b1=Array['from'](_0x1e79ec['getCustomProperties']());_0x1b36b1['length']>0x0&&(_0x288b0b['customProperties']=_0x1b36b1);const _0x301689=_0x1e79ec['getFillerOffset']();return null!==_0x301689&&(_0x288b0b['fillerOffset']=_0x301689),_0x288b0b;}}['_markChanges'](_0x59fa97,_0x47500c,_0x335d54,_0x548b90,_0x4388c5){let _0x199138=null,_0x461210=null,_0x851d0b=0x0;const _0x27cbf2=this['editor']['model'];for(let _0x9ed361=0x0;_0x9ed361<_0x47500c['length'];_0x9ed361++){const _0x39a400=this['_getVidAttributeName'](_0x47500c[_0x9ed361]),_0x475f1d=_0x47500c[_0x9ed361]['item']['getAttribute'](_0x39a400),_0x2276fc=_0x335d54['get'](_0x475f1d),_0x1d85dc=_0x9ed361==_0x47500c['length']-0x1;(!_0x199138&&_0x2276fc&&(_0x199138=_0x2276fc,_0x461210=_0x47500c[_0x9ed361]),_0x199138&&(!_0x2276fc||_0x2276fc['userId']!=_0x199138['userId']))&&(_0x232d45(_0x2276fc,P(_0x461210,_0x59fa97,_0x27cbf2),P(_0x47500c[_0x9ed361],_0x59fa97,_0x27cbf2)),_0x199138=_0x2276fc||null,_0x461210=_0x2276fc?_0x47500c[_0x9ed361]:null),_0x199138&&_0x1d85dc&&_0x232d45(_0x2276fc,P(_0x461210,_0x59fa97,_0x27cbf2),V(_0x47500c[_0x9ed361],_0x59fa97,_0x27cbf2));}function _0x232d45(_0x1ac0ce,_0x5bf3a9,_0x57c109){const _0x497682=_0x199138['userId'],_0x5a9b7d='revision:'+_0x548b90+':'+_0x497682+':'+_0x851d0b++,_0x44001a=_0x27cbf2['createRange'](_0x5bf3a9,_0x57c109);_0x59fa97['markers']['set'](_0x5a9b7d,_0x44001a),null!==_0x497682&&_0x4388c5['add'](_0x497682);}}['_getVidAttributeName'](_0x2c2c3c){switch(_0x2c2c3c['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x16555e,_0x49eda4){_0x16555e['baseVersion']=null;for(const _0x8a156c in _0x16555e){const _0x49f732=_0x16555e[_0x8a156c];if(_0x49f732 instanceof _0x49e5e1){const _0x406421=_0x49eda4['get'](_0x49f732['root']['rootName']);_0x16555e[_0x8a156c]=this['_fixPosition'](_0x49f732,_0x406421);}if(_0x49f732 instanceof _0x4650bf){const _0x3e05d8=_0x49eda4['get'](_0x49f732['root']['rootName']);_0x16555e[_0x8a156c]=this['_fixRange'](_0x49f732,_0x3e05d8);}'root'===_0x8a156c&&(_0x16555e['root']=_0x49eda4['get'](_0x16555e['root']['rootName']));}}['_fixRange'](_0x57643d,_0xcaf477){return this['editor']['model']['createRange'](this['_fixPosition'](_0x57643d['start'],_0xcaf477),this['_fixPosition'](_0x57643d['end'],_0xcaf477));}['_fixPosition'](_0x400061,_0x4deac1){return this['editor']['model']['createPositionFromPath'](_0x4deac1,_0x400061['path'],_0x400061['stickiness']);}['_handleInsertOperation'](_0x10d090){const _0x1c3515=this['_idsRoots']['get'](_0x10d090['position']['root']['rootName']),_0x3e8204=this['_fixPosition'](_0x10d090['position'],_0x1c3515),_0xa8089f=null===_0x10d090['_authorId']?null:_0x10d090['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x288d05=_0x3e8204['parent'],_0x3d02e6=this['_revisionId'],_0x3897e8=[];for(const _0x284035 of _0x10d090['nodes'])if(_0x284035['is']('element'))_0x3897e8['push'](this['_makeIdsRoot'](_0x284035));else{for(let _0x5c88cb=0x0;_0x5c88cb<_0x284035['offsetSize'];_0x5c88cb++)_0x3897e8['push'](new _0x391ba1('$text',{'vid':this['_revisionId']++}));}const _0x23fdde=this['_revisionId'];for(let _0x439dc3=_0x3d02e6;_0x439dc3<_0x23fdde;_0x439dc3++)this['_touched']['set'](_0x439dc3,{'userId':_0xa8089f});_0x288d05['_insertChild'](_0x3e8204['offset'],_0x3897e8);}['_handleMoveOperation'](_0x1f681b){(_0x1f681b=this['_cloneOperation'](_0x1f681b,this['_idsRoots']))['_execute']();const _0x4b2b8e=null===_0x1f681b['_authorId']?null:_0x1f681b['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x1ad785=_0x1f681b['getMovedRangeStart'](),_0x4af80a=_0x1ad785['parent'],_0x3c1bc4=_0x1ad785['offset'];!function _0x2d984d(_0x3596d1,_0x38f158,_0x213369,_0x5e36d6){for(let _0x2cf7ac=_0x213369;_0x2cf7ac<_0x5e36d6;_0x2cf7ac++){const _0x4a6c55=_0x38f158['getChild'](_0x2cf7ac);_0x4a6c55['is']('element','$text')?_0x3596d1['set'](_0x4a6c55['getAttribute']('vid'),{'userId':_0x4b2b8e}):(_0x3596d1['set'](_0x4a6c55['getAttribute']('vid_start'),{'userId':_0x4b2b8e}),_0x2d984d(_0x3596d1,_0x4a6c55,0x0,_0x4a6c55['childCount']),_0x3596d1['set'](_0x4a6c55['getAttribute']('vid_end'),{'userId':_0x4b2b8e}));}}(this['_touched'],_0x4af80a,_0x3c1bc4,_0x3c1bc4+_0x1f681b['howMany']);}['_handleMergeOperation'](_0x3da479){const _0x187896=null===(_0x3da479=this['_cloneOperation'](_0x3da479,this['_idsRoots']))['_authorId']?null:_0x3da479['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x12e597=_0x3da479['targetPosition']['parent'],_0x4ba381=_0x3da479['sourcePosition']['parent'],_0x14c238=_0x12e597['getAttribute']('vid_end'),_0x58e069=_0x4ba381['getAttribute']('vid_start');_0x12e597['_setAttribute']('vid_end',_0x4ba381['getAttribute']('vid_end')),_0x4ba381['_setAttribute']('vid_end',_0x14c238),this['_touched']['set'](_0x58e069,{'userId':_0x187896}),this['_touched']['set'](_0x14c238,{'userId':_0x187896}),_0x3da479['_execute']();}['_handleSplitOperation'](_0x22100d){const _0x5232ac=null===(_0x22100d=this['_cloneOperation'](_0x22100d,this['_idsRoots']))['_authorId']?null:_0x22100d['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x4b5406=_0x22100d['graveyardPosition'],_0xe71931=_0x22100d['splitPosition']['parent'];_0x22100d['_execute']();const _0x2b1296=_0xe71931['getAttribute']('vid_end'),_0x11f31d=_0x22100d['insertionPosition']['nodeAfter'];if(_0x4b5406){const _0x4290aa=_0x11f31d['getAttribute']('vid_end'),_0x5794f4=_0xe71931['getAttribute']('vid_end');_0xe71931['_setAttribute']('vid_end',_0x4290aa),_0x11f31d['_setAttribute']('vid_end',_0x5794f4),this['_touched']['set'](_0xe71931['getAttribute']('vid_end'),{'userId':_0x5232ac}),this['_touched']['set'](_0x11f31d['getAttribute']('vid_start'),{'userId':_0x5232ac});}else{const _0x43866d=this['_revisionId']++,_0x47eddd=this['_revisionId']++;_0xe71931['_setAttribute']('vid_end',_0x43866d),_0x11f31d['_setAttribute']('vid_start',_0x47eddd),_0x11f31d['_setAttribute']('vid_end',_0x2b1296),this['_touched']['set'](_0x43866d,{'userId':_0x5232ac}),this['_touched']['set'](_0x47eddd,{'userId':_0x5232ac});}}['_handleMarkerOperation'](_0x58daa9){if(!_0x58daa9['affectsData'])return;const _0x4fc2f0=(_0x58daa9=this['_cloneOperation'](_0x58daa9,this['_diffRoots']))['oldRange']?_0x58daa9['oldRange']['root']:null,_0x249621=_0x58daa9['newRange']?_0x58daa9['newRange']['root']:null;_0x4fc2f0&&this['_markers']['delete'](_0x58daa9['name']),_0x249621&&this['_markers']['set'](_0x58daa9['name'],_0x58daa9['newRange']['clone']());const _0x53c2aa=null===_0x58daa9['_authorId']?null:_0x58daa9['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x10f9a9=_0x58daa9['name'];if(!this['_touchedMarkers']['has'](_0x10f9a9))return void this['_touchedMarkers']['set'](_0x10f9a9,{'range':_0x58daa9['oldRange'],'userId':_0x53c2aa});const _0x4185f4=this['_touchedMarkers']['get'](_0x10f9a9),_0xbf6efb=_0x4185f4['range'],_0x345c44=_0x58daa9['newRange'];null==_0xbf6efb&&null==_0x345c44||_0xbf6efb&&_0x345c44&&_0xbf6efb['isEqual'](_0x345c44)?this['_touchedMarkers']['delete'](_0x58daa9['name']):_0x4185f4['userId']=_0x53c2aa;}['_handleRootOperation'](_0x22dec0,_0x335f4e){this['_diffRoots']['has'](_0x22dec0['rootName'])?this['_diffRoots']['get'](_0x22dec0['rootName'])['_isAttached']=_0x22dec0['isAdd']:(this['_diffRoots']['set'](_0x22dec0['rootName'],N(_0x22dec0['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x22dec0['rootName'],{}),_0x335f4e&&this['_idsRoots']['set'](_0x22dec0['rootName'],N(_0x22dec0['rootName'],!0x0)));const _0xdf602d=null===_0x22dec0['_authorId']?null:_0x22dec0['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x42d93d=this['_touchedRoots']['get'](_0x22dec0['rootName']);_0x42d93d&&_0x42d93d['userId']===_0xdf602d?this['_touchedRoots']['delete'](_0x22dec0['rootName']):this['_touchedRoots']['set'](_0x22dec0['rootName'],{'userId':_0xdf602d,'isAttached':_0x22dec0['isAdd']});}['_handleRootAttributeOperation'](_0x48fafa){const _0x5b1031=this['_diffRootsAttributes']['get'](_0x48fafa['root']['rootName']);null===_0x48fafa['newValue']?delete _0x5b1031[_0x48fafa['key']]:_0x5b1031[_0x48fafa['key']]=_0x48fafa['newValue'];}}function x(_0x52bb1e){const _0x187979=N(_0x52bb1e['rootName'],_0x52bb1e['isAttached']());for(const _0x567775 of _0x52bb1e['getChildren']()){const _0x418eaf=_0x567775['_clone'](!0x0);_0x187979['_appendChild'](_0x418eaf);}return _0x187979;}function N(_0x1d9e4a,_0x2967af=!0x0){const _0x494ca2=new _0x1f769d();return _0x494ca2['rootName']=_0x1d9e4a,_0x494ca2['_isAttached']=_0x2967af,_0x494ca2['isAttached']=()=>_0x494ca2['_isAttached'],_0x494ca2;}function P(_0x573ff1,_0x53aca8,_0x366973){const _0xc2b42c='elementEnd'==_0x573ff1['type']?_0x366973['createPositionAt'](_0x573ff1['item'],'end'):_0x366973['createPositionBefore'](_0x573ff1['item']);return _0x366973['createPositionFromPath'](_0x53aca8,_0xc2b42c['path'],_0xc2b42c['stickiness']);}function V(_0x4ea6ee,_0x50bbb3,_0x2c7c33){const _0x17a27f='elementStart'==_0x4ea6ee['type']?_0x2c7c33['createPositionAt'](_0x4ea6ee['item'],0x0):_0x2c7c33['createPositionAfter'](_0x4ea6ee['item']);return _0x2c7c33['createPositionFromPath'](_0x50bbb3,_0x17a27f['path'],_0x17a27f['stickiness']);}class me extends/* #__PURE__ -- @preserve */
25
+ _0x15c189(_0x344163){['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x4479d9,_0x650d57){super(_0x4479d9),this['focusTracker']=new _0x45b684(),this['keystrokes']=new _0x5f358f(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x650d57),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'](),_0x2dad37({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x3903e9=_0x6effe6=>_0x6effe6['stopPropagation']();this['keystrokes']['set']('arrowright',_0x3903e9),this['keystrokes']['set']('arrowleft',_0x3903e9),this['keystrokes']['set']('arrowup',_0x3903e9),this['keystrokes']['set']('arrowdown',_0x3903e9);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x147e67){this['revisionNameInputView']['fieldView']['element']['value']=_0x147e67['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0xb13584){const _0x22a129=new et(this['locale'],ti),_0x2cf569=_0x22a129['fieldView'];_0x2cf569['extendTemplate']({'attributes':{'maxlength':'220'}});let _0xcaeb62=m(this['locale'],'Name\x20of\x20the\x20revision');return!_0xb13584&&(_0xcaeb62+='\x20('+m(this['locale'],'optional')+')'),(_0x22a129['label']=_0xcaeb62,_0x2cf569['on']('input',()=>{this['revisionNameInputValue']=_0x2cf569['element']['value']['trim']();}),_0x22a129);}}class l extends _0x1cbf02{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h];}['_saveRevisionFormView'];['init'](){const _0x56d3db=this['editor'],_0x416389=_0x56d3db['plugins']['get']('RevisionTracker');_0x56d3db['ui']['componentFactory']['add']('revisionHistory',_0x63329f=>{const _0x2bedf4=_0x3feb57(_0x63329f),_0x43258d=_0x2bedf4['panelView']['children'],_0x317a06=new _0x18b63c(_0x63329f),_0x4cb9fa=new _0x10cbe5(_0x63329f),_0x59a8e9=new _0x111a4e(_0x63329f),_0x4bfb34=new _0x10cbe5(_0x63329f),_0x1b96dc=new _0x111a4e(_0x63329f);return _0x2bedf4['bind']('isEnabled')['to'](_0x416389,'isReady',_0x416389,'isEnabled',_0x56d3db,'isReadOnly',(_0x40c683,_0x30859a,_0xb3393c)=>_0x40c683&&_0x30859a&&!_0xb3393c),_0x2bedf4['buttonView']['set']({'icon':_0x5409bc,'label':m(_0x63329f,'Revision\x20history'),'tooltip':!0x0}),_0x59a8e9['set']({'label':m(_0x63329f,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x59a8e9['bind']('isEnabled')['to'](_0x416389,'isReady',_0x416389,'isEnabled',_0x56d3db,'isReadOnly',(_0x28a945,_0x3bb4b3,_0x540e0f)=>_0x28a945&&_0x3bb4b3&&!_0x540e0f),_0x59a8e9['on']('execute',()=>this['_showDialog']()),_0x1b96dc['set']({'label':m(_0x63329f,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x1b96dc['bind']('isEnabled')['to'](_0x416389,'isReady',_0x56d3db,'isReadOnly',(_0x479db7,_0x872108)=>_0x479db7&&!_0x872108),_0x1b96dc['on']('execute',()=>{_0x56d3db['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x2bedf4['isOpen']=!0x1,_0x56d3db['editing']['view']['focus']();}),_0x4cb9fa['children']['add'](_0x59a8e9),_0x4bfb34['children']['add'](_0x1b96dc),_0x317a06['role']='menu',_0x317a06['items']['addMany']([_0x4cb9fa,_0x4bfb34]),_0x43258d['add'](_0x317a06),_0x2bedf4;}),_0x56d3db['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x29a8c2=this['editor'],_0x11c4bf=_0x29a8c2['locale'],_0x451939=new _0x479957(_0x11c4bf),_0xaab084=new _0x3f235d(_0x11c4bf);_0x451939['buttonView']['set']({'icon':_0x5409bc,'label':m(_0x11c4bf,'Revision\x20history')});const _0x329cbe=new _0x45caa7(_0x11c4bf,_0x451939),_0x1e0f9b=new _0x139b8e(_0x11c4bf);_0x1e0f9b['set']({'label':m(_0x11c4bf,'Save\x20current\x20revision')}),_0x1e0f9b['delegate']('execute')['to'](_0x451939),_0x1e0f9b['on']('execute',()=>{this['_showDialog']();}),_0x329cbe['children']['add'](_0x1e0f9b),_0xaab084['items']['add'](_0x329cbe);const _0x135fce=new _0x45caa7(_0x11c4bf,_0x451939),_0x122434=new _0x139b8e(_0x11c4bf);return _0x122434['set']({'label':m(_0x11c4bf,'Open\x20revision\x20history')}),_0x122434['delegate']('execute')['to'](_0x451939),_0x122434['on']('execute',()=>{_0x29a8c2['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x135fce['children']['add'](_0x122434),_0xaab084['items']['add'](_0x135fce),_0x451939['panelView']['children']['add'](_0xaab084),_0x451939;}['_showDialog'](){const _0xd2a46a=this['editor'],_0xda074d=_0xd2a46a['locale'],_0x36acf5=_0xd2a46a['plugins']['get']('Dialog'),_0x21e9cd=_0xd2a46a['plugins']['get']('RevisionTracker');function _0x104985(_0xcea39b){_0xd2a46a['config']['get']('revisionHistory.requireRevisionName')&&''===_0xcea39b['revisionName']?_0xcea39b['revisionNameInputView']['errorText']=m(_0xda074d,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0xd2a46a['plugins']['get'](h)['saveRevision']({'name':_0xcea39b['revisionName']}),_0x36acf5['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x104985(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x36acf5['show']({'id':'revisionSave','title':m(_0xda074d,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':m(_0xd2a46a['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x36acf5['hide']()},{'label':m(_0xd2a46a['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x2abf9e){_0x2abf9e['bind']('isEnabled')['to'](_0x21e9cd,'isReady',_0x21e9cd,'isEnabled',_0xd2a46a,'isReadOnly',(_0x1a186e,_0x23b91d,_0x3300a2)=>_0x1a186e&&_0x23b91d&&!_0x3300a2);},'onExecute':()=>_0x104985(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x594d3f=this['editor'],_0x23779e=_0x594d3f['locale'];this['_saveRevisionFormView']=new me(_0x23779e,_0x594d3f['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class z extends _0x344163{['changeId'];['_model'];constructor(_0x5b0b2b,_0x1bfd49){super(_0x5b0b2b),this['_model']=_0x1bfd49,this['changeId']=_0x1bfd49['id'];const _0x117df3=this['bindTemplate'],_0x22854d=m(_0x5b0b2b,_0x1bfd49['data']['isSuggestion']?'Suggested\x20by':'add'==_0x1bfd49['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x1bfd49['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x117df3['to']('type',_0x8e573=>'ck-revision-change__'+_0x8e573)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x22854d}]},{'text':'\x20'+_0x1bfd49['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class G extends/* #__PURE__ -- @preserve */
26
+ _0x319fd0(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0xa0945e){super(),this['id']=_0xa0945e['id']||_0x14dab8(),this['author']=_0xa0945e['author'],this['type']=_0xa0945e['type'],this['data']=_0xa0945e['data']||{},this['rootName']=_0xa0945e['rootName'],this['set']('createdAt',_0xa0945e['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(_0x2d3a4e,_0x2e3f3a){this['newRevisionId']=_0x2d3a4e,this['oldRevisionId']=_0x2e3f3a,this['changes']=new _0x2fb560();}['_setChanges'](_0x2f5a91){for(const _0x1c81e3 of _0x2f5a91)this['changes']['add'](_0x1c81e3);}}class u extends _0x1cbf02{['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[_0x24be1d,_0x458504,S,$];}constructor(_0x4539c4){super(_0x4539c4),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',(_0x11a682,_0x12f8fd,_0x40c11e)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x20e470=>{for(const _0x2b2e90 of this['editor']['editing']['view']['document']['roots'])_0x40c11e?_0x20e470['removeClass']('ck-editor__editable__overlay',_0x2b2e90):_0x20e470['addClass']('ck-editor__editable__overlay',_0x2b2e90);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x3c891d=>null!==_0x3c891d),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x2db040,_0x1c20b6,_0xfb574f)=>_0x2db040&&_0xfb574f?_0x1c20b6['changes']['getIndex'](_0xfb574f):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x275003,_0x33578c)=>_0x275003?_0x33578c['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0x458504);}['init'](){const _0x131229=this['editor'],_0x154a00=new rt(_0x131229,{'direction':'backward'}),_0x195ef4=new rt(_0x131229,{'direction':'forward'});(_0x131229['commands']['add']('showPreviousChange',_0x154a00),_0x131229['commands']['add']('showNextChange',_0x195ef4),_0x131229['commands']['add']('restoreRevision',new nt(_0x131229)),this['on']('change:numberOfChanges',()=>{_0x154a00['refresh'](),_0x195ef4['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x131229['enableReadOnlyMode']('revision-viewer'),_0x131229['plugins']['has']('WidgetToolbarRepository'))&&_0x131229['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x3eb928){return await this['_utils']['loadRevisionData'](_0x3eb928,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x3eb928);}async['getRevisionRootsAttributes'](_0x1e9af5){return await this['_utils']['loadRevisionData'](_0x1e9af5,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x1e9af5);}async['compare'](_0x4b00ea,_0x291b4f,_0x2795e5=!0x1){if(!this['isEnabled'])return;const _0x48f437=this['diff'],_0xcf36a4=this['repository'],_0x4ba701='string'==typeof _0x4b00ea?_0xcf36a4['getRevision'](_0x4b00ea):_0x4b00ea,_0xe0cd8f='string'==typeof _0x291b4f?_0xcf36a4['getRevision'](_0x291b4f):_0x291b4f,_0x7bb70f=_0x4ba701['id'],_0x42c481=_0xe0cd8f?_0xe0cd8f['id']:null;if(!_0x2795e5&&this['diff']&&this['diff']['newRevisionId']===_0x7bb70f&&this['diff']['oldRevisionId']===_0x42c481)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new J(_0x7bb70f,_0x42c481);const _0x12d875=this['_getRevisionsRange'](_0x4ba701,_0xe0cd8f,!0x0)['map'](_0x23258a=>this['_utils']['loadRevisionData'](_0x23258a,this['adapter']));return _0x12d875['push'](new Promise(_0x535c98=>{setTimeout(_0x535c98,0x14);})),Promise['all'](_0x12d875)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x700a21=this['_getDiff'](_0x7bb70f,_0x42c481);for(const _0x5ddd87 of _0x700a21['changes'])this['_changeIdToChange']['set'](_0x5ddd87['id'],_0x5ddd87);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x4dd07e=>{for(const _0x3a9031 of this['editor']['model']['document']['getRootNames']())_0x4dd07e['detachRoot'](_0x3a9031);for(const _0x1a050f of Object['keys'](_0x700a21['model'])){const _0x188d85=_0x4dd07e['addRoot'](_0x1a050f);for(const _0x29c548 of Object['keys'](_0x700a21['attributes'][_0x1a050f]))_0x4dd07e['setAttribute'](_0x29c548,_0x700a21['attributes'][_0x1a050f][_0x29c548],_0x188d85);_0x4dd07e['insert'](_0x700a21['model'][_0x1a050f],_0x188d85,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x700a21['changes'])),this['isReady']=!0x0;})['catch'](_0x44be3a=>{console['error'](_0x44be3a),this['_cleanUp'](),_0x48f437&&(this['diff']=_0x48f437),this['isReady']=!0x0;});}['addRevisionData'](_0x108eb6,_0xaa59c5){const _0x2312f1=this['repository']['createRevision'](_0x108eb6);return _0x2312f1['on']('_update',(_0x414cd0,_0x41ea69,_0x118b50)=>_0xaa59c5(_0x41ea69,_0x118b50,_0x2312f1)),this['repository']['addRevision'](_0x2312f1),_0x2312f1;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x1b8095=>{for(const _0x1d0aac of this['editor']['model']['document']['getRootNames']())_0x1b8095['detachRoot'](_0x1d0aac);});}['_sortAndFilterDiffChanges'](_0x106991){const _0x598842=[],_0x4a5ad0=new Map();for(const _0x3e3d4e of this['editor']['model']['document']['getRootNames']()){const _0x26a605=this['editor']['editing']['view']['getDomRoot'](_0x3e3d4e);if(!_0x26a605)continue;const _0x4891aa=_0x26a605['getClientRects']()['item'](0x0);_0x4891aa&&(_0x598842['push'](_0x3e3d4e),_0x4a5ad0['set'](_0x3e3d4e,_0x4891aa));}return _0x598842['sort']((_0x3d05de,_0x4bb831)=>{const _0x7e2d3b=_0x4a5ad0['get'](_0x3d05de),_0x328e77=_0x4a5ad0['get'](_0x4bb831);return _0x7e2d3b['y']-_0x328e77['y']||_0x7e2d3b['x']-_0x328e77['x'];}),(_0x106991=_0x106991['filter'](_0x492d2c=>_0x598842['includes'](_0x492d2c['rootName'])))['sort']((_0x5c2367,_0x4943c4)=>_0x598842['indexOf'](_0x5c2367['rootName'])-_0x598842['indexOf'](_0x4943c4['rootName'])),_0x106991;}['_makeTape'](_0x5ce5f3){const _0x439043=Array['from'](_0x5ce5f3['markers'])['filter'](([_0x27b124,_0x5af9be])=>_0x27b124['startsWith']('revision:')&&!_0x5af9be['isCollapsed']),_0x1b0da3=Array['from'](this['editor']['model']['createRangeIn'](_0x5ce5f3)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x439043['length'])for(const _0x6a9588 of _0x1b0da3){const [_0x54910d,_0x262408]=_0x439043[0x0],[,_0x376ce1,_0x3b984a]=_0x54910d['split'](':');if(_0x262408['end']['isEqual'](_0x6a9588['nextPosition'])&&_0x439043['shift'](),(_0x6a9588['previousPosition']['isEqual'](_0x262408['start'])||_0x6a9588['previousPosition']['isAfter'](_0x262408['start']))&&('insertion'==_0x376ce1?_0x6a9588['isAdded']={'userId':_0x3b984a}:'deletion'==_0x376ce1&&(_0x6a9588['isRemoved']={'userId':_0x3b984a})),0x0==_0x439043['length'])break;}return _0x1b0da3;}['_refreshStartEndIndex'](_0x1f1e6f){const _0x5ede5f=new Map();for(let _0x5ce0c9=0x0;_0x5ce0c9<_0x1f1e6f['length'];_0x5ce0c9++)'text'===_0x1f1e6f[_0x5ce0c9]['type']?(_0x1f1e6f[_0x5ce0c9]['item']['startIndex']=_0x5ce0c9,_0x1f1e6f[_0x5ce0c9]['item']['endIndex']=_0x5ce0c9):('elementStart'===_0x1f1e6f[_0x5ce0c9]['type']?_0x1f1e6f[_0x5ce0c9]['item']['startIndex']=_0x5ce0c9:'elementEnd'===_0x1f1e6f[_0x5ce0c9]['type']&&(_0x1f1e6f[_0x5ce0c9]['item']['endIndex']=_0x5ce0c9),_0x5ede5f['set'](_0x1f1e6f[_0x5ce0c9]['id'],_0x5ce0c9));for(const _0x1542ef of _0x5ede5f['values']())'elementStart'===_0x1f1e6f[_0x1542ef]['type']?_0x1f1e6f[_0x1542ef]['item']['endIndex']=_0x5ede5f['get'](_0x1f1e6f[_0x1542ef]['pairId']):'elementEnd'===_0x1f1e6f[_0x1542ef]['type']&&(_0x1f1e6f[_0x1542ef]['item']['startIndex']=_0x5ede5f['get'](_0x1f1e6f[_0x1542ef]['pairId']));}['_processTape'](_0x1d3c25){for(let _0x51c85c=0x0;_0x51c85c<_0x1d3c25['length'];_0x51c85c++){if('elementStart'===_0x1d3c25[_0x51c85c]['type'])_0x1d3c25[_0x51c85c]['item']['startIndex']=_0x51c85c;else{if('elementEnd'===_0x1d3c25[_0x51c85c]['type']){_0x1d3c25[_0x51c85c]['item']['endIndex']=_0x51c85c;const _0xd09d0c=_0x1d3c25[_0x51c85c]['item']['startIndex'];_0x1d3c25[_0xd09d0c]['pairId']=_0x1d3c25[_0x51c85c]['id'],_0x1d3c25[_0x51c85c]['pairId']=_0x1d3c25[_0xd09d0c]['id'];}else _0x1d3c25[_0x51c85c]['item']['startIndex']=_0x51c85c,_0x1d3c25[_0x51c85c]['item']['endIndex']=_0x51c85c,_0x1d3c25[_0x51c85c]['pairId']=null;}_0x1d3c25[_0x51c85c]['markersStart']||(_0x1d3c25[_0x51c85c]['markersStart']=[],_0x1d3c25[_0x51c85c]['markersEnd']=[]);}}['_markInsertions'](_0x3a9e35,_0x569d14){const _0x453263=_0x3a9e35['filter'](_0x34e080=>!_0x34e080['isAdded']);for(let _0x1b9ab4=0x0;_0x1b9ab4<_0x569d14['length'];_0x1b9ab4++)_0x569d14[_0x1b9ab4]['isAdded']&&(_0x453263[_0x1b9ab4]['isAdded']=_0x569d14[_0x1b9ab4]['isAdded']);}['_getDiff'](_0x585123,_0x250723=null){const _0x163533=this['repository']['getRevision'](_0x585123),_0xaacd2e=_0x250723?this['repository']['getRevision'](_0x250723):null,_0x550912=this['_getRevisionsRange'](_0x163533,_0xaacd2e),_0x1da78e=_0x550912[_0x550912['length']-0x1],_0x4b9506=new Map(),_0x5c756c={'model':{},'attributes':{},'changes':[]},_0x318d05=new Set(),_0x2afba3=new Map();for(let _0x56db30=_0x550912['length']-0x1;_0x56db30>=0x0;_0x56db30--){const _0x27c6ee=_0x550912[_0x56db30];for(const _0x58bd3e of Object['keys'](_0x27c6ee['diffData']))if(_0x27c6ee['diffData'][_0x58bd3e]['attachChange']){const _0x5192a8=_0x27c6ee['diffData'][_0x58bd3e]['attachChange'];_0x5192a8['isAttached']?(_0x318d05['add'](_0x58bd3e),_0x2afba3['has'](_0x58bd3e)&&_0x2afba3['get'](_0x58bd3e)['userId']==_0x5192a8['userId']?_0x2afba3['delete'](_0x58bd3e):_0x2afba3['set'](_0x58bd3e,_0x5192a8)):_0x2afba3['has'](_0x58bd3e)?(_0x318d05['delete'](_0x58bd3e),_0x2afba3['delete'](_0x58bd3e)):(_0x318d05['add'](_0x58bd3e),_0x2afba3['set'](_0x58bd3e,_0x5192a8));}else _0x318d05['add'](_0x58bd3e);}for(const _0x4dec9f of _0x318d05){const _0x448a68=_0x2afba3['has'](_0x4dec9f)&&!_0x2afba3['get'](_0x4dec9f)['isAttached'];let _0x3f09fd=_0x448a68?_0x550912['length']-0x1:0x0;const _0x33d1e4=_0x448a68?-0x1:0x1;for(;_0x550912[_0x3f09fd];){const _0xdccfbc=_0x550912[_0x3f09fd];if(_0xdccfbc['diffData'][_0x4dec9f]){const _0x13a7b8=_0x448a68?_0xdccfbc['diffData'][_0x4dec9f]['attributesBefore']:_0xdccfbc['diffData'][_0x4dec9f]['attributesAfter'];_0x5c756c['attributes'][_0x4dec9f]=_0x13a7b8?_0x1a7e1c(_0x13a7b8):{};break;}_0x3f09fd+=_0x33d1e4;}}for(const _0x130e95 of _0x550912){_0x130e95['model']={};for(const _0x261549 of _0x130e95['authors'])_0x4b9506['set'](_0x261549['id'],_0x261549);for(const _0x32f1e8 of _0x318d05){const _0x3ea375=_0x130e95['diffData'][_0x32f1e8]?_0x130e95['diffData'][_0x32f1e8]['insertions']:'[]',_0x17b9b3=_0x130e95['diffData'][_0x32f1e8]?_0x130e95['diffData'][_0x32f1e8]['deletions']:'[]';_0x130e95['model'][_0x32f1e8]={'insertions':this['_utils']['_makeModelFromViewString'](_0x3ea375),'deletions':this['_utils']['_makeModelFromViewString'](_0x17b9b3)};}}for(const _0x4ab713 of _0x318d05){let _0x4c131c=null,_0x5c2162=0x0;const _0x26f4ca=new Map(Array['from'](_0x163533['model'][_0x4ab713]['insertions']['markers'])['filter'](([_0x1d547c])=>!_0x1d547c['startsWith']('revision:')));let _0x321a49=0x0;for(const _0x409dcd of _0x550912){const _0x132a38=this['_makeTape'](_0x409dcd['model'][_0x4ab713]['insertions']);_0x409dcd==_0x163533?(_0x4c131c=_0x132a38,_0x5c2162=_0x4c131c['length'],_0x4c131c['forEach'](_0x59096f=>{_0x59096f['id']=_0x321a49++;}),this['_processTape'](_0x4c131c)):this['_markInsertions'](_0x4c131c,_0x132a38);const _0x43c942=_0x4c131c['filter'](_0x1388b3=>!_0x1388b3['isAdded'])['map'](_0x349556=>_0x349556['id']);let _0x2d577b=0x0;const _0x1f0b92=this['_makeTape'](_0x409dcd['model'][_0x4ab713]['deletions']);_0x1f0b92['forEach'](_0x8d45b9=>{_0x8d45b9['isRemoved']?_0x8d45b9['id']=_0x5c2162++:_0x8d45b9['id']=_0x43c942[_0x2d577b++];}),this['_processTape'](_0x1f0b92),this['_setDistance'](_0x4c131c,'isAdded'),this['_setDistance'](_0x1f0b92,'isRemoved'),_0x409dcd==_0x163533&&this['_markMarkers'](_0x4c131c,_0x26f4ca),_0x4c131c=this['_joinTapes'](_0x4c131c,_0x1f0b92),this['_refreshStartEndIndex'](_0x4c131c),this['_setDistance'](_0x4c131c,'isRemoved');}_0x4c131c=_0x4c131c['filter'](_0x54b0d9=>!(_0x54b0d9['isAdded']&&_0x54b0d9['isRemoved']));const _0x3f895b=new Map(_0x1da78e['model'][_0x4ab713]['deletions']['markers']),_0x4fec07=new Set(_0x26f4ca['keys']());for(const _0x38e0f6 of _0x3f895b['keys']())_0x4fec07['delete'](_0x38e0f6);this['_markSuggestions'](_0x4c131c,_0x4fec07),this['_fixObsoleteTags'](_0x4c131c),_0x4c131c=this['_removeMissingPairs'](_0x4c131c),_0x4c131c=this['_markMismatchedRemovedTags'](_0x4c131c),_0x4c131c=this['_removeUnsupportedChanges'](_0x4c131c);const {root:_0x43bd8d,changes:_0x4c0a1e}=this['_makeModelFromTape'](_0x4c131c,_0x4b9506,_0x4ab713);_0x5c756c['model'][_0x4ab713]=_0x43bd8d;const _0x1c25a1=_0x2afba3['get'](_0x4ab713);if(_0x1c25a1){const _0x33c980=_0x4b9506['get'](_0x1c25a1['userId']),_0x24fe30=new G({'author':_0x33c980,'type':_0x1c25a1['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x4ab713});_0x4c0a1e['unshift'](_0x24fe30),_0x5c756c['attributes'][_0x4ab713]['revisionHistoryAttachChange']=_0x24fe30['id'];}_0x5c756c['changes']=_0x5c756c['changes']['concat'](_0x4c0a1e);}return _0x5c756c;}['_markMarkers'](_0xee3aa0,_0x19429b){for(let _0x4f0ed3=0x0;_0x4f0ed3<_0xee3aa0['length'];_0x4f0ed3++)for(const [_0x1e7446,_0x52789e]of _0x19429b)!_0x52789e['isCollapsed']&&_0x52789e['start']['isEqual'](_0xee3aa0[_0x4f0ed3]['previousPosition'])&&_0xee3aa0[_0x4f0ed3]['markersStart']['push'](_0x1e7446),_0x52789e['end']['isEqual'](_0xee3aa0[_0x4f0ed3]['nextPosition'])&&_0xee3aa0[_0x4f0ed3]['markersEnd']['push'](_0x1e7446);}['_joinTapes'](_0x3d5b53,_0x93ee68){let _0x191a45=[],_0x2debcf=0x0,_0x17a341=0x0;for(;_0x2debcf<_0x3d5b53['length']||_0x17a341<_0x93ee68['length'];){const _0x4e1177=_0x3d5b53[_0x2debcf]||{},_0x3c295b=_0x93ee68[_0x17a341]||{};if(_0x4e1177['id']==_0x3c295b['id'])_0x2debcf++,_0x17a341++,_0x191a45['push'](_0x4e1177);else{if(_0x3c295b['isRemoved']&&_0x4e1177['isAdded']){const {commonTape:_0xb72583,iEnd:_0x42305f,jEnd:_0x5d3dad}=this['_threeWayMerge'](_0x3d5b53,_0x2debcf,_0x93ee68,_0x17a341);_0x191a45=_0x191a45['concat'](_0xb72583),_0x2debcf=_0x42305f,_0x17a341=_0x5d3dad;}else _0x3c295b['isRemoved']?(_0x17a341++,_0x191a45['push'](_0x3c295b)):(_0x2debcf++,_0x191a45['push'](_0x4e1177));}}return _0x191a45;}['_markSuggestions'](_0x4670b0,_0x1483f1){const _0x2d857b=[];for(let _0x4fc018=0x0;_0x4fc018<_0x4670b0['length'];_0x4fc018++){for(let _0x206789=0x0;_0x206789<_0x4670b0[_0x4fc018]['markersStart']['length'];_0x206789++){const _0x62399=_0x4670b0[_0x4fc018]['markersStart'][_0x206789];if(!_0x1483f1['has'](_0x62399))continue;const {group:_0x216bb2,type:_0x397039,authorId:_0x2da3e6}=_0x45f72d(_0x62399);'revision-suggestion'!=_0x216bb2||'insertion'!=_0x397039&&'deletion'!=_0x397039||(_0x2d857b['unshift']({'type':_0x397039,'name':_0x62399,'userId':_0x2da3e6}),_0x4670b0[_0x4fc018]['markersStart']['splice'](_0x206789,0x1),_0x206789--);}_0x2f345f(_0x4670b0[_0x4fc018]);for(let _0x168056=0x0;_0x168056<_0x4670b0[_0x4fc018]['markersEnd']['length'];_0x168056++){const _0x378924=_0x4670b0[_0x4fc018]['markersEnd'][_0x168056];if(!_0x1483f1['has'](_0x378924))continue;const {group:_0x524c32,type:_0x306c60}=_0x45f72d(_0x378924);if('revision-suggestion'!=_0x524c32||'insertion'!=_0x306c60&&'deletion'!=_0x306c60)continue;_0x4670b0[_0x4fc018]['markersEnd']['splice'](_0x168056,0x1),_0x168056--;const _0x357d72=_0x2d857b['findIndex'](_0x7ca09c=>_0x7ca09c['name']==_0x378924);_0x357d72>-0x1&&_0x2d857b['splice'](_0x357d72,0x1);}}function _0x45f72d(_0x5d7e86){const _0x148a77=_0x5d7e86['split'](':');return{'group':_0x148a77[0x0],'type':_0x148a77[0x1],'subType':_0x148a77['length']>=0x5?_0x148a77[0x2]:null,'id':_0x148a77['length']<0x5?_0x148a77[0x2]:_0x148a77[0x3],'authorId':_0x148a77['length']<0x5?_0x148a77[0x3]:_0x148a77[0x4],'markerCount':0x6==_0x148a77['length']?_0x148a77[0x5]:null};}function _0x2f345f(_0x2647d5){for(let _0x2075ce=0x0;_0x2075ce<_0x2d857b['length'];_0x2075ce++){if(_0x2647d5['isAdded']&&'insertion'==_0x2d857b[_0x2075ce]['type']&&_0x2647d5['isAdded']['userId']==_0x2d857b[_0x2075ce]['userId'])return _0x2647d5['isAddSuggestion']=_0x2d857b[_0x2075ce],void delete _0x2647d5['isAdded'];if(!_0x2647d5['isAdded']&&!_0x2647d5['isRemoved']&&'deletion'==_0x2d857b[_0x2075ce]['type'])return void(_0x2647d5['isRemoveSuggestion']=_0x2d857b[_0x2075ce]);}}}['_setDistance'](_0x4fee26,_0x46e7e6){let _0x23699a=0x0,_0x1d1b59=!0x1;const _0x5bf6ba=new Map();for(const _0x953f12 of _0x4fee26)_0x953f12[_0x46e7e6]?_0x1d1b59&&(_0x23699a++,_0x1d1b59=!0x1):(_0x23699a++,_0x1d1b59=!0x0),_0x5bf6ba['set'](_0x953f12['id'],_0x23699a);for(let _0x7c925c=0x0;_0x7c925c<_0x4fee26['length'];_0x7c925c++){if('isRemoved'==_0x46e7e6&&_0x4fee26[_0x7c925c]['isAdded']||'isAdded'==_0x46e7e6&&_0x4fee26[_0x7c925c]['isRemoved'])continue;if('text'==_0x4fee26[_0x7c925c]['type']){_0x4fee26[_0x7c925c]['distance']=0x0;continue;}const _0x5c6e14=_0x5bf6ba['get'](_0x4fee26[_0x7c925c]['pairId']),_0x2b9fde=_0x5bf6ba['get'](_0x4fee26[_0x7c925c]['id']);_0x4fee26[_0x7c925c]['distance']=_0x5c6e14-_0x2b9fde;}}['_getRevisionsRange'](_0x19e19b,_0x162de4,_0x258023=!0x1){const _0x4d1f81=[];let _0x3a4d51=this['repository']['getIndex'](_0x19e19b),_0x44ccb4=this['repository']['getIndex'](_0x162de4);for(-0x1==_0x44ccb4&&(_0x44ccb4=this['repository']['_revisions']['length'],_0x258023=!0x1);_0x3a4d51<_0x44ccb4;)_0x4d1f81['push'](this['repository']['getRevision'](_0x3a4d51)),_0x3a4d51++;return _0x258023&&_0x4d1f81['push'](this['repository']['getRevision'](_0x3a4d51)),_0x4d1f81;}['_threeWayMerge'](_0x32f498,_0x41b804,_0x448ed4,_0x25bf30){const _0x571cab=this['editor']['model']['schema'];let _0xdc5dd0=_0x41b804;for(;_0x32f498[_0xdc5dd0]&&_0x32f498[_0xdc5dd0]['isAdded'];)_0xdc5dd0++;let _0x93054c=_0x25bf30;for(;_0x448ed4[_0x93054c]&&_0x448ed4[_0x93054c]['isRemoved'];)_0x93054c++;_0x492d6a(_0x32f498,_0x41b804,_0xdc5dd0),_0x492d6a(_0x448ed4,_0x25bf30,_0x93054c);const _0x595a30=_0x448ed4['slice'](_0x25bf30,_0x93054c)['concat'](_0x32f498['slice'](_0x41b804,_0xdc5dd0));return _0x595a30['sort']((_0xa4490a,_0x2f358e)=>_0xa4490a['side']!=_0x2f358e['side']?_0xa4490a['side']-_0x2f358e['side']:_0xa4490a['level']!=_0x2f358e['level']?_0xa4490a['level']-_0x2f358e['level']:_0xa4490a['distance']!=_0x2f358e['distance']?_0x2f358e['distance']-_0xa4490a['distance']:!!_0xa4490a['isAdded']!=!!_0x2f358e['isAdded']?-0x1==_0xa4490a['side']||0x0==_0xa4490a['side']?_0xa4490a['isAdded']?-0x1:0x1:_0xa4490a['isAdded']?0x1:-0x1:_0xa4490a['index']-_0x2f358e['index']),{'commonTape':_0x595a30,'iEnd':_0xdc5dd0,'jEnd':_0x93054c};function _0x492d6a(_0x3c5c5c,_0x425550,_0x4f6bb0){let _0x10af22=-0x1,_0x39d1ea=Number['POSITIVE_INFINITY'],_0x308d5e=!0x0;for(let _0x2fddca=_0x425550;_0x2fddca<_0x4f6bb0;_0x2fddca++)if(_0x571cab['isInline'](_0x3c5c5c[_0x2fddca]['item'])||(_0x308d5e=!0x1),_0x3c5c5c[_0x2fddca]['item']['startIndex']<_0x425550&&(_0x10af22=_0x2fddca),_0x3c5c5c[_0x2fddca]['item']['endIndex']>=_0x4f6bb0){_0x39d1ea=_0x2fddca;break;}_0x308d5e&&(_0x10af22=_0x4f6bb0-0x1);for(let _0x5e42de=_0x425550;_0x5e42de<_0x4f6bb0;_0x5e42de++)_0x3c5c5c[_0x5e42de]['side']=_0x5e42de<=_0x10af22?-0x1:_0x5e42de<_0x39d1ea?0x0:0x1,_0x3c5c5c[_0x5e42de]['index']=_0x5e42de;let _0xa35298=0x0;for(let _0x293262=_0x425550;_0x293262<=_0x10af22;_0x293262++)0x0==_0x3c5c5c[_0x293262]['distance']?_0x3c5c5c[_0x293262]['level']=_0xa35298:(_0xa35298++,_0x3c5c5c[_0x293262]['level']=_0xa35298,_0xa35298++);for(let _0x4cde09=_0x425550;_0x4cde09<_0x4f6bb0;_0x4cde09++)0x0==_0x3c5c5c[_0x4cde09]['side']&&(_0x3c5c5c[_0x4cde09]['level']=_0xa35298);_0xa35298=0x0;for(let _0x3d1cab=_0x4f6bb0-0x1;_0x3d1cab>=_0x39d1ea;_0x3d1cab--)0x0==_0x3c5c5c[_0x3d1cab]['distance']?_0x3c5c5c[_0x3d1cab]['level']=_0xa35298:(_0xa35298--,_0x3c5c5c[_0x3d1cab]['level']=_0xa35298,_0xa35298--);}}['_fixObsoleteTags'](_0x24ea47){const _0x46f6e1=new Map(),_0x18343e=this['editor']['model']['schema'];for(let _0x4c546f=0x1;_0x4c546f<_0x24ea47['length'];_0x4c546f++){let _0x1bd6d4,_0x2f8326,_0xddb2c8;const _0x574cb8=_0x24ea47[_0x4c546f],_0x5ed4c6=_0x24ea47[_0x4c546f-0x1];if('text'==_0x574cb8['type'])continue;if(_0x574cb8['type']!=_0x5ed4c6['type'])continue;if(!_0x18343e['isBlock'](_0x5ed4c6['item'])||_0x18343e['isLimit'](_0x5ed4c6['item']))continue;if(!_0x18343e['isBlock'](_0x574cb8['item'])||_0x18343e['isLimit'](_0x574cb8['item']))continue;if((_0x24ea47[_0x4c546f]['isAdded']||_0x24ea47[_0x4c546f]['isAddSuggestion'])&&_0x24ea47[_0x4c546f-0x1]['isRemoved'])_0x1bd6d4=_0x24ea47[_0x4c546f],_0x2f8326=_0x24ea47[_0x4c546f-0x1],_0xddb2c8=_0x4c546f-0x1;else{if(!_0x24ea47[_0x4c546f]['isRemoved']||!_0x24ea47[_0x4c546f-0x1]['isAdded']&&!_0x24ea47[_0x4c546f-0x1]['isAddSuggestion'])continue;_0x1bd6d4=_0x24ea47[_0x4c546f-0x1],_0x2f8326=_0x24ea47[_0x4c546f],_0xddb2c8=_0x4c546f;}const _0x4cbf28=_0x1bd6d4['level']==_0x2f8326['level'],_0x113d7d=Math['abs'](_0x1bd6d4['level'])<Math['abs'](_0x2f8326['level'])&&0x0==_0x2f8326['distance'];(_0x4cbf28||_0x113d7d)&&(_0x46f6e1['set'](_0x2f8326['id'],_0x1bd6d4['id']),_0x24ea47['splice'](_0xddb2c8,0x1),_0x4c546f--,_0x1bd6d4['isAdded']=!0x1);}for(let _0x381163=0x0;_0x381163<_0x24ea47['length'];_0x381163++)_0x46f6e1['has'](_0x24ea47[_0x381163]['pairId'])&&(_0x24ea47[_0x381163]['pairId']=_0x46f6e1['get'](_0x24ea47[_0x381163]['pairId']));}['_removeMissingPairs'](_0x54eb92){const _0x52a6e6=new Set(_0x54eb92['map'](_0x2cad63=>_0x2cad63['id']));for(let _0x5c5786=0x0;_0x5c5786<_0x54eb92['length'];_0x5c5786++)_0x52a6e6['has'](_0x54eb92[_0x5c5786]['pairId'])||0x0==_0x54eb92[_0x5c5786]['distance']||(_0x54eb92[_0x5c5786]['isIncorrect']=!0x0);return _0x54eb92['filter'](_0x89fda7=>!_0x89fda7['isIncorrect']);}['_markMismatchedRemovedTags'](_0x32295d){const _0x144ea4=new Set();for(let _0x49401d=0x0;_0x49401d<_0x32295d['length'];_0x49401d++){if(_0x144ea4['has'](_0x32295d[_0x49401d]['id'])&&_0x32295d[_0x49401d]['isRemoved']&&(_0x32295d[_0x49401d]['isIncorrect']=!0x0),_0x32295d[_0x49401d]['isIncorrect'])continue;if(0x0==_0x32295d[_0x49401d]['distance'])continue;if('elementStart'!=_0x32295d[_0x49401d]['type'])continue;if(null==_0x32295d[_0x49401d]['pairId'])continue;let _0x5995b0=_0x49401d+0x1,_0x5d189e=0x0;for(;_0x32295d[_0x5995b0]['id']!=_0x32295d[_0x49401d]['pairId'];)'elementStart'==_0x32295d[_0x5995b0]['type']?_0x5d189e++:'elementEnd'==_0x32295d[_0x5995b0]['type']&&_0x5d189e--,_0x5995b0++;if(0x0!=_0x5d189e){if(_0x32295d[_0x49401d]['isRemoved'])_0x32295d[_0x49401d]['isIncorrect']=!0x0;else{for(;_0x5995b0!=_0x49401d;)_0x32295d[_0x5995b0]['isRemoved']&&0x0!=_0x32295d[_0x5995b0]['distance']&&(_0x32295d[_0x5995b0]['isIncorrect']=!0x0,_0x144ea4['add'](_0x32295d[_0x5995b0]['pairId'])),_0x5995b0--;}}}return _0x32295d['filter'](_0x309578=>!_0x309578['isIncorrect']);}['_removeUnsupportedChanges'](_0x1dc444){const _0x28677f=this['editor']['model']['schema'];for(let _0x5c8d66=0x0;_0x5c8d66<_0x1dc444['length'];_0x5c8d66++){if(!(_0x1dc444[_0x5c8d66]['isAdded']||_0x1dc444[_0x5c8d66]['isAddSuggestion']||_0x1dc444[_0x5c8d66]['isRemoved']||_0x1dc444[_0x5c8d66]['isRemoveSuggestion']))continue;if(0x0==_0x1dc444[_0x5c8d66]['distance'])continue;const _0x5c3190=_0x1dc444[_0x5c8d66]['item'];_0x28677f['isBlock'](_0x5c3190)||_0x28677f['isLimit'](_0x5c3190)||(_0x1dc444[_0x5c8d66]['isAdded']&&delete _0x1dc444[_0x5c8d66]['isAdded'],_0x1dc444[_0x5c8d66]['isAddSuggestion']&&delete _0x1dc444[_0x5c8d66]['isAddSuggestion'],_0x1dc444[_0x5c8d66]['isRemoveSuggestion']&&delete _0x1dc444[_0x5c8d66]['isRemoveSuggestion'],_0x1dc444[_0x5c8d66]['isRemoved']&&(_0x1dc444[_0x5c8d66]['isIncorrect']=!0x0));}return _0x1dc444['filter'](_0x2daf52=>!_0x2daf52['isIncorrect']);}['_makeModelFromTape'](_0x271c63,_0x5aa199,_0x323b3d){const _0x23ea16=new _0x1f769d(),_0x5dba14=[],_0x44f32d=new Map(),_0x1d0d27=this['editor']['model'],_0x2fa915=_0x1d0d27['schema'],_0x4a1181=[_0x23ea16],_0x15b76d={},_0x1bb091={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x242e69=null;const _0x5b7877=[0x0];for(let _0x2f85b7=0x0;_0x2f85b7<_0x271c63['length'];_0x2f85b7++)if('elementStart'===_0x271c63[_0x2f85b7]['type']){_0x271c63[_0x2f85b7]['previousPosition']=_0x1d0d27['createPositionFromPath'](_0x23ea16,_0x5b7877);const _0x324e67=new _0x391ba1(_0x271c63[_0x2f85b7]['item']['name'],_0x271c63[_0x2f85b7]['item']['getAttributes']());_0x4a1181[0x0]['_appendChild'](_0x324e67),_0x5b7877['push'](0x0),_0x4a1181['unshift'](_0x324e67),_0x271c63[_0x2f85b7]['nextPosition']=_0x1d0d27['createPositionFromPath'](_0x23ea16,_0x5b7877);}else'elementEnd'===_0x271c63[_0x2f85b7]['type']?(_0x4a1181['shift'](),_0x271c63[_0x2f85b7]['previousPosition']=_0x1d0d27['createPositionFromPath'](_0x23ea16,_0x5b7877),_0x5b7877['pop'](),_0x5b7877[_0x5b7877['length']-0x1]++,_0x271c63[_0x2f85b7]['nextPosition']=_0x1d0d27['createPositionFromPath'](_0x23ea16,_0x5b7877)):(_0x271c63[_0x2f85b7]['previousPosition']=_0x1d0d27['createPositionFromPath'](_0x23ea16,_0x5b7877),_0x242e69?_0x242e69['_data']+=_0x271c63[_0x2f85b7]['item']['data']:_0x242e69=new _0xf5d3d(_0x271c63[_0x2f85b7]['item']['data'],_0x271c63[_0x2f85b7]['item']['getAttributes']()),_0x271c63[_0x2f85b7+0x1]&&'text'===_0x271c63[_0x2f85b7+0x1]['type']&&_0x1835b9(_0x242e69,_0x271c63[_0x2f85b7+0x1]['item'])||(_0x4a1181[0x0]['_appendChild'](_0x242e69),_0x242e69=null),_0x5b7877[_0x5b7877['length']-0x1]+=_0x271c63[_0x2f85b7]['item']['offsetSize'],_0x271c63[_0x2f85b7]['nextPosition']=_0x1d0d27['createPositionFromPath'](_0x23ea16,_0x5b7877));for(let _0x5906ab=0x0;_0x5906ab<_0x271c63['length'];_0x5906ab++){const _0x31e829=_0x271c63[_0x5906ab]['previousPosition'],_0xa15134=_0x271c63[_0x5906ab]['nextPosition'];for(const _0x2a9101 of _0x271c63[_0x5906ab]['markersStart'])_0x44f32d['set'](_0x2a9101,{'start':_0x31e829,'end':null});_0x18282c('isRemoveSuggestion',_0x5906ab,_0x31e829,_0xa15134),_0x18282c('isAddSuggestion',_0x5906ab,_0x31e829,_0xa15134),_0x18282c('isRemoved',_0x5906ab,_0x31e829,_0xa15134),_0x18282c('isAdded',_0x5906ab,_0x31e829,_0xa15134);for(const _0x330d3c of _0x271c63[_0x5906ab]['markersEnd']){const _0x5a7d17=_0x44f32d['get'](_0x330d3c);_0x5a7d17?_0x5a7d17['end']=_0xa15134:_0x44f32d['set'](_0x330d3c,{'start':_0xa15134,'end':_0xa15134});}}for(const [_0x24f1d6,_0x2c6398]of _0x44f32d){const _0x325c51=this['editor']['model']['createRange'](_0x2c6398['start'],_0x2c6398['end']);_0x23ea16['markers']['set'](_0x24f1d6,_0x325c51);}return _0x5dba14['sort']((_0x1f40d4,_0x326614)=>{const _0x2e8d83=_0x23ea16['markers']['get']('revision:'+_0x1f40d4['id']),_0x115a12=_0x23ea16['markers']['get']('revision:'+_0x326614['id']);return _0x2e8d83['start']['isBefore'](_0x115a12['start'])?-0x1:_0x2e8d83['start']['isAfter'](_0x115a12['start'])?0x1:_0x2e8d83['end']['isBefore'](_0x115a12['end'])?-0x1:_0x2e8d83['end']['isAfter'](_0x115a12['end'])?0x1:'add'===_0x1f40d4['type']?-0x1:0x1;}),{'root':_0x23ea16,'changes':_0x5dba14};function _0x18282c(_0x21aa26,_0x3f22cc,_0x31fdda,_0x1acbc5){const _0x18015c=!!_0x271c63[_0x3f22cc][_0x21aa26],_0x33c596=_0x18015c?_0x271c63[_0x3f22cc][_0x21aa26]['userId']:null,_0x3d92cf=_0x3f22cc===_0x271c63['length']-0x1,_0x19d0da=_0x1bb091[_0x21aa26][0x0],_0x2cbdd5=_0x2fa915['isObject'](_0x271c63[_0x3f22cc]['item']);!_0x15b76d[_0x21aa26]&&_0x18015c?_0x15b76d[_0x21aa26]={'start':_0x31fdda,'tapeItem':_0x271c63[_0x3f22cc],'userId':_0x33c596,'type':_0x21aa26}:_0x15b76d[_0x21aa26]&&!_0x18015c?(_0x15b76d[_0x21aa26]['end']=_0x31fdda,_0x274543(_0x15b76d[_0x21aa26]),_0x15b76d[_0x21aa26]=null):_0x15b76d[_0x21aa26]&&_0x18015c&&_0x15b76d[_0x21aa26]['userId']!==_0x33c596&&(_0x15b76d[_0x21aa26]['end']=_0x31fdda,_0x19d0da&&_0x19d0da['userId']===_0x15b76d[_0x21aa26]['userId']||_0x274543(_0x15b76d[_0x21aa26]),_0x15b76d[_0x21aa26]={'start':_0x31fdda,'tapeItem':_0x271c63[_0x3f22cc],'userId':_0x33c596,'type':_0x21aa26}),_0x15b76d[_0x21aa26]&&_0x2cbdd5&&('elementStart'!==_0x271c63[_0x3f22cc]['type']||_0x19d0da&&_0x19d0da['userId']===_0x33c596||_0x1bb091[_0x21aa26]['unshift']({'userId':_0x33c596,'object':_0x271c63[_0x3f22cc]['item'],'change':_0x15b76d[_0x21aa26]}),'elementEnd'===_0x271c63[_0x3f22cc]['type']&&_0x19d0da&&_0x19d0da['object']===_0x271c63[_0x3f22cc]['item']&&(_0x1bb091[_0x21aa26]['shift'](),_0x15b76d[_0x21aa26]=_0x19d0da['change'])),_0x15b76d[_0x21aa26]&&_0x3d92cf&&(_0x15b76d[_0x21aa26]['end']=_0x1acbc5,_0x274543(_0x15b76d[_0x21aa26]),_0x15b76d[_0x21aa26]=null);}function _0x274543({start:_0x53a47a,end:_0x30754f,tapeItem:_0x141774,userId:_0x1f50b2,type:_0x3e2049}){const _0x35bb03=_0x141774['item'],_0x1c141d=_0x1d0d27['schema']['isBlock'](_0x35bb03)&&!_0x1d0d27['schema']['isLimit'](_0x35bb03),_0x22fde4=_0x53a47a['nodeAfter']==_0x30754f['parent']&&_0x30754f['isAtStart'];if(_0x1c141d&&_0x22fde4)return;const _0x3e524a=_0x1d0d27['createRange'](_0x53a47a,_0x30754f),_0x41cbfe=_0x5aa199['get'](_0x1f50b2),_0x114c6f=new G({'author':_0x41cbfe,'type':'isAdded'==_0x3e2049||'isAddSuggestion'==_0x3e2049?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x3e2049||'isRemoveSuggestion'==_0x3e2049},'createdAt':new Date(),'rootName':_0x323b3d});_0x5dba14['push'](_0x114c6f),_0x23ea16['markers']['set']('revision:'+_0x114c6f['id'],_0x3e524a);}function _0x1835b9(_0x8435b9,_0x3ccaab){const _0x113b21=_0x8435b9['getAttributes'](),_0x1f759d=_0x3ccaab['getAttributes']();for(const _0x2f5f4e of _0x113b21){if(_0x2f5f4e[0x1]!==_0x3ccaab['getAttribute'](_0x2f5f4e[0x0]))return!0x1;_0x1f759d['next']();}return _0x1f759d['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x13a4ac=>{const _0x3fca82=_0x13a4ac['markerName']['split'](':')[0x1],_0x5b1ee5=this['_getChangeFromId'](_0x3fca82);if(!_0x5b1ee5)return null;const _0x1dc870='add'==_0x5b1ee5['type']?'insertion':'deletion',_0x4ef44b=['ck-suggestion-marker','ck-suggestion-marker-'+_0x1dc870];return _0x5b1ee5['data']['isSuggestion']&&_0x4ef44b['push']('ck-suggestion-marker-'+_0x1dc870+'-new'),this['activeChange']==_0x5b1ee5&&_0x4ef44b['push']('ck-suggestion-marker--active'),{'classes':_0x4ef44b,'attributes':{'data-change-id':_0x3fca82}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x387152=>{_0x387152['on']('element:pre',(_0x56b3a7,_0x7f85df,_0x2b9a91)=>{const _0x2382ac=_0x7f85df['viewItem']['getChild'](0x0);if(!_0x2382ac||!_0x2382ac['is']('element','code'))return;if(!_0x2b9a91['consumable']['consume'](_0x2382ac,{'attributes':['vid_start','vid_end']}))return;const _0x273f00=_0x7f85df['modelRange']['start']['nodeAfter'];_0x2b9a91['writer']['setAttribute']('vid_start',_0x2382ac['getAttribute']('vid_start'),_0x273f00),_0x2b9a91['writer']['setAttribute']('vid_end',_0x2382ac['getAttribute']('vid_end'),_0x273f00);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x430d42=>{_0x430d42['on']('element',(_0xdb68a2,_0x5a74a7,_0x48e333)=>{if(!_0x48e333['consumable']['consume'](_0x5a74a7['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x5a74a7['modelRange']['isCollapsed'])return;const _0x5bd2e2=_0x5a74a7['modelRange']['start']['nodeAfter'];_0x5bd2e2['hasAttribute']('vid_start')||_0x5bd2e2['hasAttribute']('vid')||(_0x48e333['writer']['setAttribute']('vid_start',_0x5a74a7['viewItem']['getAttribute']('vid_start'),_0x5bd2e2),_0x48e333['writer']['setAttribute']('vid_end',_0x5a74a7['viewItem']['getAttribute']('vid_end'),_0x5bd2e2));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x32c90d=>_0x32c90d['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x4c1ac8,[,_0x2b635d])=>{['vid_start','vid_end','vid']['includes'](_0x2b635d)&&(_0x4c1ac8['return']=!0x0,_0x4c1ac8['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x1b07cc=>{_0x1b07cc['on']('attribute:vid',(_0x2bb0c1,_0x3d5f3b,_0x48331c)=>{if('\x20'!=_0x3d5f3b['item']['data']||_0x3d5f3b['item']['parent']['maxOffset']>0x1)return;if(!_0x48331c['consumable']['consume'](_0x3d5f3b['item'],_0x2bb0c1['name']))return;const _0x4b1a01=_0x48331c['writer'],_0x491575=_0x48331c['mapper']['toViewRange'](_0x3d5f3b['range']);_0x4b1a01['wrap'](_0x491575,_0x4b1a01['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x15b54c){const _0x16a279=_0x15b54c['plugins']['get']('RevisionViewer');return(_0x1a997c,_0x4286a2,_0x2a88cc)=>{const _0x23a64e=_0x4286a2['markerName']['split'](':')[0x1],_0x5c1e8b=_0x16a279['_getChangeFromId'](_0x23a64e);if(!_0x5c1e8b)return null;const _0x291afa='add'==_0x5c1e8b['type']?'split':'merge';if(!_0x2a88cc['consumable']['test'](_0x4286a2['markerRange'],_0x1a997c['name']))return;const _0x4be5ce=_0x4286a2['markerRange']['getWalker'](),_0x37ac15=_0x4286a2['markerRange']['start'],_0x267142=_0x15b54c['model']['schema'];let _0x35a974=null,_0x34a851=null,_0x3138c8=!0x1,_0x504523=!0x1;for(const _0x128aef of _0x4be5ce){const _0x3ed614=_0x128aef['item'];_0x3138c8=_0x3138c8||_0x267142['isContent'](_0x3ed614);const _0xc69e90=_0x2a88cc['mapper']['toViewElement'](_0x3ed614);if(_0xc69e90&&_0xc69e90['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x128aef['type']&&(_0x267142['isBlock'](_0x3ed614)&&!_0x267142['isLimit'](_0x3ed614)&&(_0x3ed614['nextSibling']||_0x37ac15['isAtEnd']?_0x35a974&&_0x35a974['parent']==_0x3ed614||(_0x35a974=_0x3ed614,_0x45ddf1(_0x128aef['previousPosition']),_0x504523=!0x0):_0x34a851=_0x34a851||_0x128aef['previousPosition']));}function _0x45ddf1(_0x6f9164){const _0x29c67d=_0x2a88cc['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x291afa}),_0x1a5b84=_0x2a88cc['mapper']['toViewPosition'](_0x6f9164);_0x5c1e8b['data']['isSuggestion']&&_0x2a88cc['writer']['addClass']('ck-suggestion-marker-'+_0x291afa+'-new',_0x29c67d),_0x16a279['activeChange']==_0x5c1e8b&&_0x2a88cc['writer']['addClass']('ck-suggestion-marker--active',_0x29c67d),_0x2a88cc['writer']['insert'](_0x1a5b84,_0x29c67d),_0x2a88cc['mapper']['bindElementToMarker'](_0x29c67d,_0x4286a2['markerName']);}_0x3138c8||_0x504523||!_0x34a851||_0x45ddf1(_0x34a851);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x3c57e0,_0x131d6e,_0x11bc8d)=>{const _0x92dd1=_0x11bc8d['mapper']['markerNameToElements'](_0x131d6e['markerName']);if(_0x92dd1){for(const _0x1d5162 of _0x92dd1)(_0x1d5162['hasClass']('ck-suggestion-marker-split')||_0x1d5162['hasClass']('ck-suggestion-marker-merge'))&&(_0x11bc8d['mapper']['unbindElementFromMarkerName'](_0x1d5162,_0x131d6e['markerName']),_0x11bc8d['writer']['remove'](_0x1d5162));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x27817f,_0xb4b65e,_0x8e7348)=>{const _0x567b9a=_0xb4b65e['markerName']['split'](':')[0x1],_0x29cfe7=this['_getChangeFromId'](_0x567b9a);if(!_0x29cfe7)return null;const _0x33fabd='add'==_0x29cfe7['type']?'split':'merge';if(_0x8e7348['consumable']['test'](_0xb4b65e['markerRange'],_0x27817f['name']))for(const _0x1ab272 of _0xb4b65e['markerRange']['getItems']()){if(!_0x1ab272['is']('element','softBreak'))continue;const _0x5bde1f=_0x8e7348['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x33fabd}),_0x352580=_0x8e7348['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x1ab272));_0x29cfe7['data']['isSuggestion']&&_0x8e7348['writer']['addClass']('ck-suggestion-marker-'+_0x33fabd+'-new',_0x5bde1f),this['activeChange']==_0x29cfe7&&_0x8e7348['writer']['addClass']('ck-suggestion-marker--active',_0x5bde1f),_0x8e7348['writer']['insert'](_0x352580,_0x5bde1f),_0x8e7348['mapper']['bindElementToMarker'](_0x5bde1f,_0xb4b65e['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x43fe1b=>{for(const _0x235f0d of this['editor']['model']['document']['getRootNames']()){const _0x5d4ea6=this['editor']['model']['document']['getRoot'](_0x235f0d),_0x5bb5ab=this['editor']['editing']['view']['document']['getRoot'](_0x235f0d);if(_0x5bb5ab){const _0x4c58b4=_0x5d4ea6['getAttribute']('revisionHistoryAttachChange');if(_0x43fe1b['removeAttribute']('data-change-id',_0x5bb5ab),_0x43fe1b['removeClass']('ck-revision-history-root-add',_0x5bb5ab),_0x43fe1b['removeClass']('ck-revision-history-root-remove',_0x5bb5ab),_0x43fe1b['removeClass']('ck-revision-history-root--active',_0x5bb5ab),_0x4c58b4){const _0x558d64=this['_getChangeFromId'](_0x4c58b4);if(!_0x558d64)return null;_0x43fe1b['setAttribute']('data-change-id',_0x4c58b4,_0x5bb5ab),_0x43fe1b['addClass']('ck-revision-history-root-'+_0x558d64['type'],_0x5bb5ab),this['activeChange']==_0x558d64&&_0x43fe1b['addClass']('ck-revision-history-root--active',_0x5bb5ab);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x11f374=>'revision-comment:'+_0x11f374,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x31d26e=>'revision-suggestion:'+_0x31d26e,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x111dcc=>({'name':'suggestion:'+_0x111dcc,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x1eeb18=>{const _0x31ff07=_0x1eeb18['markerName']['split'](':')[0x1];return'insertion'!=_0x31ff07&&'deletion'!=_0x31ff07?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x31ff07]};}}),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',(_0x5d5922,_0x3c4c18,_0x5b288d)=>{const _0x21bd23=_0x5b288d['mapper']['markerNameToElements'](_0x3c4c18['markerName']);if(_0x21bd23){for(const _0x29cfe2 of _0x21bd23)_0x29cfe2['is']('uiElement')&&(_0x5b288d['mapper']['unbindElementFromMarkerName'](_0x29cfe2,_0x3c4c18['markerName']),_0x5b288d['writer']['remove'](_0x29cfe2));}},{'priority':'high'});}['_getChangeFromId'](_0x15111a){return this['_changeIdToChange']['get'](_0x15111a);}['_getViewForChange'](_0x5a05c8){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new z(this['editor']['locale'],_0x5a05c8),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x5302dd,_0xa330e6,_0x15c695,_0x5c6c36)=>{_0x5c6c36&&this['_balloon']['remove'](_0x5c6c36),_0x15c695&&(this['_balloon']['add']({'view':_0x15c695,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x4b97c5=this['editor']['editing'],_0x37e3c6=this['_getChangeFromId'](_0x15c695['changeId']);let _0x1983f1;if(_0x37e3c6['data']['isOnRoot']){const _0x167263=_0x4b97c5['view']['getDomRoot'](_0x37e3c6['rootName']);_0x1983f1=Array['from'](_0x167263['getClientRects']());}else{const _0x5ee908=this['editor']['model']['markers']['get']('revision:'+_0x15c695['changeId']);_0x1983f1=Array['from'](_0x4b97c5['mapper']['markerNameToElements'](_0x5ee908['name']))['map'](_0x43639d=>_0x4b97c5['view']['domConverter']['mapViewToDom'](_0x43639d))['map'](_0x57964f=>Array['from'](_0x57964f['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x1983f1[0x0];return _0x1983f1['find'](_0x4e570b=>_0x4e570b['top']-0x3<=this['_activeViewTarget']['y']&&_0x4e570b['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x4e570b['left']-0x3<=this['_activeViewTarget']['x']&&_0x4e570b['right']+0x3>=this['_activeViewTarget']['x'])||_0x1983f1[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x1b3246,_0xb7b053,_0x3ddd44,_0x5df2d8)=>{this['activeView']=_0x3ddd44?this['_getViewForChange'](_0x3ddd44):null,this['editor']['model']['change'](()=>{const _0x104458=this['editor']['editing'];_0x5df2d8&&(_0x5df2d8['data']['isOnRoot']?_0x104458['view']['change'](_0x82aa0a=>{_0x82aa0a['removeClass']('ck-revision-history-root--active',_0x104458['view']['document']['getRoot'](_0x5df2d8['rootName']));}):_0x104458['reconvertMarker']('revision:'+_0x5df2d8['id'])),_0x3ddd44&&(_0x3ddd44['data']['isOnRoot']?_0x104458['view']['change'](_0x280afb=>{_0x280afb['addClass']('ck-revision-history-root--active',_0x104458['view']['document']['getRoot'](_0x3ddd44['rootName']));}):_0x104458['reconvertMarker']('revision:'+_0x3ddd44['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x5ab1c4,_0x4219ef)=>{if(this['activeChange'])return;const _0x21dedf=this['_findChangeIdFromDomTarget'](_0x4219ef['target']),_0x5c3e2c=this['_changeIdToChange']['get'](_0x21dedf);_0x5c3e2c?(this['_activeViewTarget']={'x':_0x4219ef['domEvent']['x'],'y':_0x4219ef['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x5c3e2c)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x2c3692,_0x429d29)=>{const _0x25c4d7=this['_findChangeIdFromDomTarget'](_0x429d29['target']),_0x305218=this['_changeIdToChange']['get'](_0x25c4d7);_0x305218?(this['_activeViewTarget']={'x':_0x429d29['domEvent']['x'],'y':_0x429d29['domEvent']['y']},_0x305218===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x305218):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x515275){do{const _0x5d8f4c=_0x515275['getAttribute']('data-change-id');if(_0x5d8f4c)return _0x5d8f4c;_0x515275=_0x515275['parent'];}while(_0x515275);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x57feb5=>{for(const _0x192f21 of this['editor']['model']['markers'])_0x57feb5['removeMarker'](_0x192f21);});}}function Q(_0x27496c,_0x4cc58f){return(_0x5854df,_0x59a904,_0x4715ae)=>{if(!_0x4715ae['consumable']['test'](_0x59a904['markerRange'],_0x5854df['name']))return;const _0x1bf713=_0x59a904['markerRange']['getWalker'](),_0x469d87=_0x59a904['markerRange']['start'],_0x450492=_0x27496c['model']['schema'];let _0x593ace=null,_0x1a1039=null,_0x4dcd39=!0x1,_0x3fb556=!0x1;for(const _0x322dbe of _0x1bf713){const _0x35e11c=_0x322dbe['item'];_0x4dcd39=_0x4dcd39||_0x450492['isContent'](_0x35e11c);const _0x27916d=_0x4715ae['mapper']['toViewElement'](_0x35e11c);if(_0x27916d&&_0x27916d['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x322dbe['type']&&(_0x450492['isBlock'](_0x35e11c)&&!_0x450492['isLimit'](_0x35e11c)&&(_0x35e11c['nextSibling']||_0x469d87['isAtEnd']?_0x593ace&&_0x593ace['parent']==_0x35e11c||(_0x593ace=_0x35e11c,_0xfd7bc6(_0x322dbe['previousPosition']),_0x3fb556=!0x0):_0x1a1039=_0x1a1039||_0x322dbe['previousPosition']));}function _0xfd7bc6(_0x214e80){const _0x15ca0c=_0x4715ae['mapper']['toViewPosition'](_0x214e80),_0x3c75ef=_0x4715ae['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x4cc58f});_0x4715ae['writer']['insert'](_0x15ca0c,_0x3c75ef),_0x4715ae['mapper']['bindElementToMarker'](_0x3c75ef,_0x59a904['markerName']);}_0x4dcd39||_0x3fb556||!_0x1a1039||_0xfd7bc6(_0x1a1039);};}class nt extends _0x171f77{constructor(_0x5cd487){super(_0x5cd487);const _0x5300f7=_0x5cd487['plugins']['get'](u);this['affectsData']=!0x1,this['listenTo'](_0x5300f7,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x5300f7,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0xe14bae=this['editor'],_0x375164=_0xe14bae['plugins']['get'](u),_0x340d89=_0x375164['isReady']?_0x375164['diff']['newRevisionId']:null;_0xe14bae['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x340d89);}['refresh'](){const {isReady:_0x5115c4,isEnabled:_0xc61faf,repository:_0x2ef827,diff:_0x43cbab}=this['editor']['plugins']['get'](u),_0x1a1725=_0x43cbab&&_0x2ef827['getLaterVisibleRevision'](_0x43cbab['newRevisionId']);this['isEnabled']=_0x5115c4&&_0xc61faf&&Boolean(_0x1a1725);}}class rt extends _0x171f77{['_step'];constructor(_0x1fc4a0,{direction:_0x56661c}){super(_0x1fc4a0);const _0x28ec12=_0x1fc4a0['plugins']['get'](u);this['affectsData']=!0x1,this['_step']='forward'===_0x56661c?0x1:-0x1,this['listenTo'](_0x28ec12,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x28ec12,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x28ec12,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x56297d=this['editor'],_0x1839c5=_0x56297d['plugins']['get'](u),{isNavigationMode:_0x1b5ba2,currentChangeNumber:_0x71de6d}=_0x1839c5;let _0x41830e;if(_0x1839c5['activeChange']=_0x1b5ba2?_0x1839c5['diff']['changes']['get'](_0x71de6d+this['_step']):_0x1839c5['diff']['changes']['first'],_0x1839c5['activeChange']['data']['isOnRoot'])_0x41830e=_0x56297d['editing']['view']['getDomRoot'](_0x1839c5['activeChange']['rootName']);else{const _0x10b80c=_0x56297d['model']['markers']['get']('revision:'+_0x1839c5['activeChange']['id']);_0x41830e=_0x40fef2(_0x56297d['editing'],_0x10b80c);}_0x544f13({'target':_0x41830e,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x38234c,currentChangeNumber:_0xf3e67b,numberOfChanges:_0x2d946b,isReady:_0x346435,isEnabled:_0x51cc3b}=this['editor']['plugins']['get'](u);this['isEnabled']=!!(_0x51cc3b&&_0x346435&&_0x2d946b)&&(!_0x38234c||(0x1===this['_step']?_0xf3e67b<_0x2d946b-0x1:_0xf3e67b>0x0));}}class Ri extends _0x344163{constructor(_0x2724b6){super(_0x2724b6);const _0x236bb8=this['bindTemplate'],_0x422fec=new _0x111a4e(_0x2724b6),_0x3f3dfc=new _0x111a4e(_0x2724b6);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',(_0xf501c3,_0x2c671d)=>_0xf501c3&&_0x2c671d>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x4e554f,_0x377fed,_0x10da8e,_0x5ba80f)=>{if(!_0x4e554f)return m(_0x2724b6,'Loading...');if(!_0x10da8e)return m(_0x2724b6,'No\x20changes');const _0x2cb4da=m(_0x2724b6,'NUMBER_OF_CHANGES',_0x10da8e);return _0x5ba80f?m(_0x2724b6,'X_OF_Y_CHANGES',[_0x377fed+0x1,_0x10da8e]):_0x2cb4da;}),_0x422fec['set']({'label':m(_0x2724b6,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x25fac3}),_0x3f3dfc['set']({'label':m(_0x2724b6,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x565f7d}),_0x422fec['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x3f3dfc['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x422fec['on']('execute',()=>this['fire']('execute','backward')),_0x3f3dfc['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',_0x236bb8['if']('_isStatusLabelVisible','ck-hidden',_0x2e678c=>!_0x2e678c)]},'children':[{'text':_0x236bb8['to']('isNavigationMode',_0x5b5e5a=>_0x5b5e5a?m(_0x2724b6,'EDIT_X_OF_Y_REVISIONS')+':\x20':m(_0x2724b6,'Total')+':\x20')}]},{'text':_0x236bb8['to']('_statusText')}]},new _0xff048f(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x422fec,_0x3f3dfc]}]});}}const ge='ck-editor__editable__loading-overlay';class ji extends _0x1cbf02{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x5f2117=this['editor']['editing']['view'];_0x5f2117['change'](_0x311098=>{for(const _0x551ba3 of _0x5f2117['document']['roots'])_0x311098['addClass'](ge,_0x551ba3);});}['hide'](){const _0xfc9d05=this['editor']['editing']['view'];_0xfc9d05['change'](_0x89904e=>{for(const _0x4a5aba of _0xfc9d05['document']['roots'])_0x89904e['removeClass'](ge,_0x4a5aba);});}}class v extends _0x1cbf02{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u,ji];}['init'](){const _0x25f55f=this['editor'],_0x1a25d2=_0x25f55f['plugins']['get'](u),_0x4b0f12=_0x25f55f['plugins']['get'](ji);_0x25f55f['ui']['componentFactory']['add']('exitToEditing',_0x4de0bf=>{const _0x39a753=new _0x111a4e(_0x4de0bf);return _0x39a753['set']({'label':m(_0x4de0bf,'Back\x20to\x20editing'),'icon':_0x3db167,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x39a753,'execute',()=>{_0x25f55f['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x39a753;}),_0x25f55f['ui']['componentFactory']['add']('restoreRevision',_0x1f2acd=>{const _0x35b6af=new _0x111a4e(_0x1f2acd);return _0x35b6af['set']({'label':m(_0x1f2acd,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x35b6af['bind']('isEnabled')['to'](_0x25f55f['commands']['get']('restoreRevision')),this['listenTo'](_0x35b6af,'execute',()=>_0x25f55f['execute']('restoreRevision')),_0x35b6af;}),_0x25f55f['ui']['componentFactory']['add']('changesNavigation',_0x5e6515=>{const _0x53976c=new Ri(_0x5e6515),_0x14f6fd=_0x25f55f['commands']['get']('showPreviousChange'),_0x10fe83=_0x25f55f['commands']['get']('showNextChange');return _0x53976c['bind']('isBackwardNavigationEnabled')['to'](_0x14f6fd,'isEnabled'),_0x53976c['bind']('isForwardNavigationEnabled')['to'](_0x10fe83,'isEnabled'),_0x53976c['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x1a25d2),this['listenTo'](_0x53976c,'execute',(_0x172a30,_0x4ff9b9)=>{_0x25f55f['execute']('forward'===_0x4ff9b9?'showNextChange':'showPreviousChange');}),_0x53976c;}),_0x4b0f12['show'](),_0x1a25d2['on']('change:isReady',(_0x5d5dd4,_0x3ec03b,_0xfccc5e)=>{_0xfccc5e?_0x4b0f12['hide']():_0x4b0f12['show']();});}}class hi extends et{['_resizeObserver']=null;constructor(_0x205644,_0x458146){super(_0x205644,_0x458146);const _0x1cd35f=this['bindTemplate'];this['set']({'label':m(_0x205644,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=m(_0x205644,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x1cd35f['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 _0xe84620=this['fieldView']['element'];this['_tooltipString']=_0xe84620['scrollWidth']>_0xe84620['clientWidth']&&_0xe84620['value']||'';}}class ni extends _0x344163{constructor(_0x22fd87,_0x53e244,_0x462a80){super(_0x22fd87);const _0x154370=new _0x119c42();_0x154370['set']({'content':_0x42b1f1,'viewBox':'0\x200\x2011\x2010'});const _0x4d5daa=['ck','ck-revision-history-sidebar__revision-author'];_0x462a80&&_0x4d5daa['push']('ck-revision-history-sidebar__revision-author_creator');const _0xfc18e7=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':m(_0x22fd87,_0x462a80?'Revision\x20creator':'Revision\x20author')},'children':[_0x154370,_0x53e244['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x4d5daa},'children':_0xfc18e7});}}function ai(_0x3d7f1f,_0x551e78){const _0x3a3ad7=_0x3d7f1f['bindTemplate'],_0x380254=_0x3d7f1f['locale'],_0x4ba150=_0x3feb57(_0x380254);_0x4ba150['panelPosition']='sw';const _0x10e9ed=function(_0x15f5a4,_0x308771){const _0x3edde9=function(_0x5dc938,_0x30cac9){const _0xb8978b=_0x5dc938['locale'],_0x1954d5={'Compare\x20against\x20selected':m(_0xb8978b,'Compare\x20against\x20selected'),'Name\x20this\x20revision':m(_0xb8978b,'Name\x20this\x20revision'),'Restore\x20this\x20revision':m(_0xb8978b,'Restore\x20this\x20revision')};return _0x30cac9['map'](_0x256c2a=>{const _0xbcf856=_0x1954d5[_0x256c2a['name']];return _0xbcf856&&_0xbcf856!==_0x256c2a['name']&&(_0x256c2a['name']=_0xbcf856),_0x256c2a;});}(_0x15f5a4,_0x308771),_0x41cfea=new _0x2fb560();for(const _0x277431 of _0x3edde9){const _0x2783b8={'type':'button','model':new to({'label':_0x277431['name'],'class':_0x277431['class'],'withText':!0x0,'role':'menuitem','_action':_0x277431['action']})};_0x2783b8['model']['bind']('isEnabled')['to'](_0x15f5a4,'isActionsDropdownOpen',_0x343f2d=>'function'!=typeof _0x277431['isEnabled']||(!_0x343f2d||_0x277431['isEnabled'](_0x15f5a4))),_0x41cfea['add'](_0x2783b8);}return _0x41cfea;}(_0x3d7f1f,_0x551e78);return _0x3d7f1f['bind']('isActionsDropdownOpen')['to'](_0x4ba150,'isOpen'),_0x4ba150['buttonView']['set']({'label':m(_0x380254,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x4f013c}),_0x4ba150['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x3a3ad7['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x3a3ad7['to'](_0x1486f7=>_0x1486f7['stopPropagation']())}}),_0x4ba150['on']('execute',_0x4118f7=>{_0x3d7f1f['isReady']&&'function'==typeof _0x4118f7['source']['_action']&&_0x4118f7['source']['_action'](_0x3d7f1f);}),_0xdf116(_0x4ba150,_0x10e9ed,{'role':'menu'}),_0x4ba150['listenTo'](_0x3d7f1f,'change:isActionsDropdownOpen',(_0x126bbf,_0x565b4c,_0x1ed2ba)=>{if(_0x1ed2ba)for(const _0x352f8b of _0x4ba150['listView']['items']){const _0x247687=_0x352f8b['children']['first'],_0x4e78e1=_0x551e78['find'](_0x3c4298=>_0x3c4298['action']===_0x247687['_action'])['isVisible'];_0x352f8b['isVisible']=void 0x0===_0x4e78e1||_0x4e78e1(_0x3d7f1f);}}),_0x4ba150;}class _i extends/* #__PURE__ -- @preserve */
27
+ _0x27a638(_0x344163){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x3e463d,_0xc4a70c,_0x53f386,_0x163495){super(_0x3e463d);const _0x11e2ba=this['bindTemplate'],_0xf06b41=function(_0x152278,_0x22a7ad){const _0x3c4ddb=Array['from'](_0x22a7ad['authors'])['filter'](_0x1cce4c=>_0x1cce4c!=_0x22a7ad['creator']);return _0x22a7ad['creator']&&_0x3c4ddb['unshift'](_0x22a7ad['creator']),_0x3c4ddb['map'](_0x4dd74d=>new ni(_0x152278,_0x4dd74d,_0x4dd74d==_0x22a7ad['creator']));}(_0x3e463d,_0xc4a70c);this['id']=_0xc4a70c['id'],this['_revision']=_0xc4a70c,this['_requireRevisionName']=_0x163495,this['bind']('name','createdAt')['to'](_0xc4a70c),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x3918c0=>{return _0x23d44a=_0x3e463d['uiLanguage'],(_0x4971db=_0x3918c0)['toLocaleDateString'](_0x23d44a,{'month':'long','day':'numeric'})+',\x20'+_0x4971db['toLocaleTimeString'](_0x23d44a,{'hour':'numeric','minute':'numeric'});var _0x23d44a,_0x4971db;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new hi(_0x3e463d,ti),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x3f6afc=>_0x3f6afc||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x44eb12,_0x247be5)=>_0x44eb12&&_0x247be5),this['revisionActionsView']=_0x53f386&&_0x53f386['length']?ai(this,_0x53f386):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x11e2ba['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x11e2ba['if']('isEnabled','ck-disabled',_0x5e6939=>!_0x5e6939),_0x11e2ba['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x11e2ba['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x11e2ba['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':_0x11e2ba['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':_0xf06b41}]},this['revisionActionsView']],'on':{'click':_0x11e2ba['to'](_0x1b939e=>{_0x1b939e['srcElement']['closest']('.ck-confirm-view')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x59b0e8=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x59b0e8,'change',()=>{this['_requireRevisionName']&&!_0x59b0e8['value']||this['fire']('setName',{'id':this['id'],'name':_0x59b0e8['value']}),_0x59b0e8['value']||(_0x59b0e8['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(_0x550c64,_0x5e046b){const _0x625450=_0x24f230['fromJSDate'](_0x550c64)['setLocale'](_0x5e046b),_0x5735dc=_0x24f230['local'](),_0x407329=_0x5735dc['minus']({'days':0x1})['startOf']('day');let _0x23d86f,_0x56e7b7;return _0x625450['hasSame'](_0x5735dc,'day')?(_0x23d86f=_0x625450['startOf']('day')['toJSDate'](),_0x56e7b7=_0x625450['toRelativeCalendar']()):_0x625450['hasSame'](_0x407329,'day')?(_0x23d86f=_0x407329['toJSDate'](),_0x56e7b7=_0x625450['toRelativeCalendar']()):_0x625450['hasSame'](_0x5735dc,'week')?(_0x23d86f=_0x625450['startOf']('week')['toJSDate'](),_0x56e7b7=_0x625450['weekdayLong']||''):_0x625450['hasSame'](_0x5735dc,'year')?(_0x23d86f=_0x625450['startOf']('month')['toJSDate'](),_0x56e7b7=_0x625450['monthLong']||''):(_0x23d86f=_0x625450['startOf']('year')['toJSDate'](),_0x56e7b7=String(_0x625450['year'])),{'startDate':_0x23d86f,'localizedPeriodName':_0x56e7b7};}class bi extends _0x344163{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x4e9929,_0x1c2ecb,_0x11067d,_0x15aea0){super(_0x4e9929);const _0xf40223=li(_0x1c2ecb,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x1c2ecb,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x11067d,this['_requireRevisionName']=_0x15aea0,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':_0xf40223}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x37a49a){const _0x3a8107=new _i(this['locale'],_0x37a49a,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x3a8107);}['removeRevision'](_0x560172){const _0x763b24=this['revisionViews']['find'](_0x440cb5=>_0x440cb5['id']===_0x560172['id']);this['revisionViews']['remove'](_0x763b24);}}class fi extends _0x344163{constructor(_0x4d545d){super(_0x4d545d);const _0x50c4d3=new _0x119c42();_0x50c4d3['content']=_0x5409bc,this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x50c4d3,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[m(_0x4d545d,'Revision\x20history')]}]});}}class di extends _0x344163{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x5de053,_0x24cf94,_0x204de1,_0x3db3e1){super(_0x5de053);const _0x3b9ae9=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x24cf94,this['_revisionActions']=_0x204de1,this['_requireRevisionName']=_0x3db3e1,this['on']('select',(_0x5818c9,_0x401618)=>{this['fire']('revisionSelected',_0x401618);}),this['on']('setName',(_0x49dcc2,_0x5f3397)=>{this['fire']('revisionSetName',_0x5f3397);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new fi(_0x5de053),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x3b9ae9['if']('isEnabled','ck-disabled',_0x3fce49=>!_0x3fce49)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x26bddf of this['_revisions'])this['_addRevision'](_0x26bddf);this['_revisions']['on']('add',(_0x2e9668,_0x2110ad)=>{this['_addRevision'](_0x2110ad);}),this['_revisions']['on']('remove',(_0x3cd5ea,_0x9c16ed)=>{this['_removeRevision'](_0x9c16ed);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x554ad3=>_0x554ad3['revisionViews']['map'](_0x2198e1=>_0x2198e1))['flat']();}['selectRevision'](_0x215494){for(const _0x319510 of this['revisionViews'])_0x215494&&_0x215494['id']===_0x319510['id']?_0x319510['select']():_0x319510['deselect']();}['highlightRevisions'](_0x21e8f3){for(const _0x5b2e41 of this['revisionViews'])_0x21e8f3['some'](({id:_0x451450})=>_0x451450===_0x5b2e41['id'])?_0x5b2e41['highlight']():_0x5b2e41['unhighlight']();}['_addRevision'](_0x330a77){const _0x3c6fee=li(_0x330a77['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x35995d=this['timePeriodViews']['get'](0x0);_0x35995d&&_0x35995d['startDate']['getTime']()===_0x3c6fee['getTime']()||(_0x35995d=new bi(this['locale'],_0x3c6fee,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x35995d)),_0x35995d['addRevision'](_0x330a77);}['_removeRevision'](_0x2916de){const _0xa57a1e=li(_0x2916de['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0xa57a1e)['removeRevision'](_0x2916de);}['_getTimePeriodViewByStartDate'](_0x32de25){return this['timePeriodViews']['find'](_0x5d0a29=>_0x5d0a29['startDate']['getTime']()===_0x32de25['getTime']());}}class d extends _0x1cbf02{['_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(_0x3626e7){super(_0x3626e7),this['_revisionViewer']=_0x3626e7['plugins']['get'](u),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x4e3fda=this['_revisionsRepository']['_revisions'],_0x3fa10e=this['_createRevisionActions'](),_0x4dd583=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new di(this['editor']['locale'],_0x4e3fda,_0x3fa10e,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',(_0x5dd10d,_0x397f63)=>{_0x397f63['revisionViews']['on']('add',(_0x1d4857,_0x26b6df)=>{_0x26b6df['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)),_0x4dd583['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0xbddc8e=this['_revisionsRepository']['getRevision'](0x0);if(_0xbddc8e){const _0x42e590=this['_revisionsRepository']['getEarlierVisibleRevision'](_0xbddc8e['id']);this['_revisionViewer']['compare'](_0xbddc8e,_0x42e590);}}['_handleRevisionSelected'](_0x553ee8,_0x4d393a){const _0x5dac2f=this['_revisionsRepository']['getRevision'](_0x4d393a['id']),_0x56f333=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x5dac2f['id']);this['_revisionViewer']['compare'](_0x5dac2f,_0x56f333);}['_handleRevisionSetName'](_0x741e2c,_0x374f93){this['_revisionsRepository']['getRevision'](_0x374f93['id'])['setName'](_0x374f93['name']);}['_handleDiffChange'](_0x79ae17,_0x7041bb,_0x17a706){const _0x2d3831=this['_revisionsRepository']['getRevisionsInDiff'](_0x17a706);_0x2d3831['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x2d3831),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x2d3831[0x0]));}['_createRevisionActions'](){const _0x31e6db=this['editor'],_0x1bf9b5=d['availableRevisionActions'],_0x17c3b3=_0x31e6db['config']['get']('revisionHistory.revisionActions')||d['defaultRevisionActions'];if(_0x17c3b3['length'])return _0x17c3b3['map'](_0x5244da=>{const _0x58ab80='string'==typeof _0x5244da?Object['assign']({},_0x1bf9b5[_0x5244da]):_0x5244da;return _0x58ab80['action']=_0x58ab80['action']['bind'](this,_0x31e6db),_0x58ab80['isVisible']&&(_0x58ab80['isVisible']=_0x58ab80['isVisible']['bind'](this,_0x31e6db)),_0x58ab80;});}}function at(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x302445},_0x294a2e)=>{const _0x1efd04=_0x302445['get'](u),_0x2efb8f=_0x1efd04['repository'];let _0x486d3c=_0x1efd04['diff']['newRevisionId'],_0x4204c8=_0x294a2e['id'];_0x2efb8f['getIndex'](_0x486d3c)>_0x2efb8f['getIndex'](_0x4204c8)&&([_0x486d3c,_0x4204c8]=[_0x4204c8,_0x486d3c]),_0x1efd04['compare'](_0x486d3c,_0x4204c8);},'isVisible':({plugins:_0x1c37a7},_0x3aed2d)=>{const _0x283bc6=_0x1c37a7['get'](u);return!(_0x283bc6['repository']['getRevisionsInDiff'](_0x283bc6['diff'])['length']>0x2)&&!_0x3aed2d['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x54c93b,{id:_0x241ea5})=>{_0x54c93b['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x241ea5);},'isVisible':({plugins:_0x3c6cb1},_0x5d4482)=>!!_0x3c6cb1['get'](u)['repository']['getLaterVisibleRevision'](_0x5d4482['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x476faf},{id:_0x4ac6ab,revisionNameView:_0x4fadf5})=>{const _0x58e94e=_0x476faf['get'](u),_0x51260c=_0x58e94e['repository']['getEarlierVisibleRevision'](_0x4ac6ab);_0x58e94e['compare'](_0x4ac6ab,_0x51260c),_0x4fadf5['focus'](),_0x4fadf5['fieldView']['select']();}}};}class Z extends tt{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x37f633,_0x53d0c5){super(_0x37f633),this['_view']=_0x53d0c5,this['_toolbarConfig']=st(_0x37f633['config']['get']('toolbar')),this['_elementReplacer']=new it();}get['element'](){return this['view']['element'];}['init'](_0x4e903e){const _0x27219c=this['editor'],_0x1afa0c=this['view'],_0x2abc57=_0x27219c['editing']['view'],_0x3bc0d0=_0x1afa0c['editable'],_0xde62b9=_0x2abc57['document']['getRoot']();_0x3bc0d0['name']=_0xde62b9['rootName'],_0x1afa0c['render']();const _0x5c3c4c=_0x3bc0d0['element'];this['setEditableElement'](_0x3bc0d0['name'],_0x5c3c4c),_0x1afa0c['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x2abc57['attachDomRoot'](_0x5c3c4c),this['_elementReplacer']['replace'](_0x4e903e,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x5a32ea=this['view'],_0x5a4264=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x5a4264['detachDomRoot'](_0x5a32ea['editable']['name']),_0x5a32ea['destroy']();}['_initToolbar'](){const _0x445f20=this['view'];_0x445f20['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x445f20['stickyPanel']['limiterElement']=_0x445f20['element'],_0x445f20['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0xe79d74})=>_0xe79d74),_0x445f20['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x445f20['toolbar']);}}class ii extends _0x7ffce6{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x107d5d,_0x2f60dd,_0x522216={}){super(_0x107d5d),this['stickyPanel']=new _0x46ff0e(_0x107d5d),this['toolbar']=new _0x24896f(_0x107d5d,{'shouldGroupWhenFull':_0x522216['shouldToolbarGroupWhenFull']}),this['_editable']=new te(_0x107d5d,_0x2f60dd);}['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
- _0x1ad7d6(_0x21409b){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x5a41b4,_0x39b76c){super(_0x39b76c),this['sourceElement']=_0x5a41b4,this['model']['document']['createRoot']();const _0x276a5c=new ii(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new Z(this,_0x276a5c);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x225655,_0x42c7ad){const _0x4cd0b5=new this(_0x225655,_0x42c7ad);return await _0x4cd0b5['initPlugins'](),await _0x4cd0b5['ui']['init'](_0x225655),await _0x4cd0b5['data']['init'](_0x4cd0b5['config']['get']('initialData')||''),_0x4cd0b5['fire']('ready'),_0x4cd0b5;}}const p=['RevisionHistoryUI','RestrictedEditingMode','AIChat','AIReviewMode','AIBalloon','AIQuickActions','AIActions'];class ht extends _0x23b9b4{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x17f452){function _0x20c36e(_0x4681ad){return _0x4681ad['map'](_0x1a1ff8=>String['fromCharCode'](_0x1a1ff8))['join']('');}super(_0x17f452),this['result']='end',_0x17f452[_0x20c36e([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x20c36e([0x76,0x69,0x65,0x77])][_0x20c36e([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x20c36e([0x61,0x75,0x74,0x6f]),_0x17f452[_0x20c36e([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x20c36e([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x20c36e([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x20c36e([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x20c36e([0x6f,0x6b])});}}class ct extends _0x23b9b4{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h,l];}constructor(_0x29baf0){if(super(_0x29baf0),!this['editor']['config']['get']('revisionHistory'))throw new _0x4f08e9('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x503398=>this['_showRevisionViewer']({..._0x503398,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x21c12a=>this['_closeRevisionViewer'](_0x21c12a)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x40be0=>this['_restoreRevision'](_0x40be0)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x3b569b){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x3b569b;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0xfaca26){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0xfaca26);}['getRevision'](_0x8be8f0){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x8be8f0);}['getRevisions'](_0x4dd847){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x4dd847||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x439302=this['editor'],_0x3c8436=_0xb086e5(_0x439302,p),_0x516345=_0x439302['plugins']['get']('RevisionTracker'),_0x19d76d=_0x439302['plugins']['get']('Users')['users'];return _0x3c8436['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x3c8436['lazyRoots'],(_0x3c8436['plugins']['push'](ht,u,v,class extends _0x23b9b4{static get['requires'](){return[u,'Users'];}['init'](){const _0x5b72c3=this['editor']['plugins']['get']('Users');for(const _0x1f69a2 of _0x19d76d)_0x1f69a2['isAnonymous']||_0x5b72c3['getUser'](_0x1f69a2['id'])||_0x5b72c3['addUser'](_0x1f69a2);const _0x51f61d=_0x516345['repository']['getRevisions']();let _0x306e61=null;const _0xb08674=this['editor']['plugins']['get']('RevisionViewer');_0xb08674['adapter']=_0x516345['adapter'],_0xb08674['bind']('isEnabled')['to'](_0x516345),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x439302,'isReadOnly',_0x1cbf77=>!_0x1cbf77);for(const _0x48f038 of _0x51f61d){const _0x59be4b=null===_0x48f038['creator'];if(_0x59be4b&&_0x48f038['toVersion']===_0x48f038['fromVersion'])continue;const _0x2b2f4e=_0x48f038['toJSON']();_0xb08674['addRevisionData'](_0x2b2f4e,(_0x51da4d,_0x61d344,_0x4e5e52)=>{if(_0x59be4b){if(_0x306e61)_0x306e61['_update'](_0x51da4d,_0x61d344);else{if(!_0x61d344){const _0x1d5349=_0x4e5e52['toJSON']();_0x1d5349['id']=_0x3191d3(),_0x516345['saveRevision'](_0x1d5349,_0x4e5e52['toVersion'])['then'](_0x46baa2=>{_0x306e61=_0x46baa2;});}}}else _0x48f038['_update'](_0x51da4d,_0x61d344);});}}},d),_0x3c8436);}['_enhanceShowRevisionViewerCallback'](){const _0x1dc1ed=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x2a0813=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x2c7092=this['editor']['plugins']['get']('Autosave');await _0x2c7092['save']();}else await _0x2a0813['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x14739f=this['editor']['plugins']['get']('Dialog');_0x14739f['isOpen']&&_0x14739f['hide']();}if(this['editor']['plugins']['has']('AITabs')){const _0x113f0c=this['editor']['plugins']['get']('AITabs')['view']['panelViews'];for(const _0x4e808c of _0x113f0c)_0x4e808c['class']=_0x4e808c['class']?_0x4e808c['class']+'\x20ck-tab-panel_disabled':'ck-tab-panel_disabled';if(this['editor']['plugins']['has']('AIChat')){const _0x3825c0=document['querySelector']('.ck-ai-chat__prompt-input\x20.ck-textarea');_0x3825c0&&_0x3825c0['setAttribute']('tabindex','-1');}if(this['editor']['plugins']['has']('AIChatHistory')){const _0x3fd76d=document['querySelector']('.ck-ai-chat-history\x20.ck-input');_0x3fd76d&&_0x3fd76d['setAttribute']('tabindex','-1');}}const _0x98d23e=this['_getRevisionViewerEditorConfig']();return _0x1dc1ed(_0x98d23e)['then'](_0x3f5404=>{return(this['_viewerEditor']=_0x3f5404,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'),_0x3f5404);})['catch'](_0x1e25ec=>(console['error'](_0x1e25ec),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x4345c4=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 _0x548f3f=this['editor']['plugins']['get']('AITabs')['view']['panelViews'];for(const _0x140984 of _0x548f3f)_0x140984['class']='ck-tab-panel_disabled'===_0x140984['class']?'':_0x140984['class']['replace']('\x20ck-tab-panel_disabled','');if(this['editor']['plugins']['has']('AIChat')){const _0x397a6e=document['querySelector']('.ck-ai-chat__prompt-input\x20.ck-textarea');_0x397a6e&&_0x397a6e['removeAttribute']('tabindex');}if(this['editor']['plugins']['has']('AIChatHistory')){const _0x55abd8=document['querySelector']('.ck-ai-chat-history\x20.ck-input');_0x55abd8&&_0x55abd8['removeAttribute']('tabindex');}}return this['_viewerEditor']['plugins']['get']('RevisionViewer')['_cleanUp'](),_0x4345c4(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x42c0cb=this['editor']['plugins']['get']('Annotations');_0x42c0cb['refreshVisibility'](),_0x42c0cb['refreshPositioning']();}});});}['_showRevisionViewer'](_0x534bca){const _0x1c3dff=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x3f42c6=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x1c0229=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return f['create'](_0x1c0229,_0x534bca)['then'](_0x246dd2=>(_0x3f42c6['style']['display']='block',_0x1c3dff['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x246dd2));}['_closeRevisionViewer'](_0x1b4302){const _0xb0f3e4=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0xb0f3e4['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x1b4302['destroy']();}async['_restoreRevision'](_0x5abe31){const _0x185085=this['editor'],_0x4cf0e8=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x10d60f=_0x185085['plugins']['get']('RevisionTracker'),_0x54f6f5=_0x185085['plugins']['get']('RevisionHistoryUtils'),_0x126f8f=_0x4cf0e8['repository']['getRevision'](_0x5abe31);let _0x266118,_0x4e74cc,_0x53c9f3;try{await _0x54f6f5['loadRevisionData'](_0x126f8f,this['adapter']),_0x266118=_0x54f6f5['getRevisionDocumentData'](_0x126f8f),_0x4e74cc=_0x54f6f5['getRevisionRootsAttributes'](_0x126f8f);}catch(_0x66aeda){return void console['error'](_0x66aeda);}_0x185085['model']['change'](_0x1bd726=>{for(const _0x315ab2 of Array['from'](_0x185085['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x1bd726['removeMarker'](_0x315ab2);}),_0x4cf0e8['isReady']=!0x1,_0x185085['model']['enqueueChange'](_0x41c098=>{_0x41c098['setSelection'](null),_0x41c098['removeSelectionAttribute'](_0x185085['model']['document']['selection']['getAttributeKeys']());const _0x5bd95d=Object['keys'](_0x266118);for(const _0x333be7 of _0x185085['model']['document']['roots'])'$graveyard'!=_0x333be7['rootName']&&_0x333be7['isAttached']()&&!_0x5bd95d['includes'](_0x333be7['rootName'])&&_0x41c098['detachRoot'](_0x333be7);for(const _0x1a2c91 of _0x5bd95d){let _0xd46c23=_0x185085['model']['document']['getRoot'](_0x1a2c91);_0xd46c23&&_0xd46c23['isAttached']()||(_0xd46c23=_0x41c098['addRoot'](_0x1a2c91));const _0x429755=_0x4e74cc[_0x1a2c91],_0xdf5025=Object['keys'](_0x429755),_0x18650c=_0x266118[_0x1a2c91];for(const _0xb788bc of _0xd46c23['getAttributeKeys']())_0xdf5025['includes'](_0xb788bc)||_0x41c098['removeAttribute'](_0xb788bc,_0xd46c23);for(const _0x18b98d of _0xdf5025)_0x41c098['setAttribute'](_0x18b98d,_0x4e74cc[_0x1a2c91][_0x18b98d],_0xd46c23);_0x41c098['remove'](_0x41c098['createRangeIn'](_0xd46c23)),_0x41c098['insert'](_0x185085['data']['parse'](_0x18650c,_0xd46c23),_0xd46c23,0x0);}});const _0x194316=m(_0x185085['locale'],'Restored');if(_0x126f8f['name'])_0x53c9f3=-0x1==_0x126f8f['name']['indexOf'](_0x194316)?_0x194316+':\x20'+_0x126f8f['name']:_0x126f8f['name'];else _0x53c9f3=_0x194316+':\x20'+(_0x126f8f['createdAt']['toLocaleDateString'](_0x185085['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x126f8f['createdAt']['toLocaleTimeString'](_0x185085['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x10d60f['saveRevision']({'name':_0x53c9f3}),_0x4cf0e8['isReady']=!0x0,_0x185085['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(_0x37bbb8){super(_0x37bbb8),this['_revisionViewer']=_0x37bbb8['plugins']['get'](u),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x1292a6=this['_revisionsRepository']['_revisions'],_0x4751cf=this['_createRevisionActions'](),_0xdf5963=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new di(this['editor']['locale'],_0x1292a6,_0x4751cf,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',(_0x144571,_0x47efb1)=>{_0x47efb1['revisionViews']['on']('add',(_0x28bb88,_0x688a20)=>{_0x688a20['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)),_0xdf5963['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x594ff2=this['_revisionsRepository']['getRevision'](0x0);if(_0x594ff2){const _0x4a6baa=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x594ff2['id']);this['_revisionViewer']['compare'](_0x594ff2,_0x4a6baa);}}['_handleRevisionSelected'](_0x18111a,_0xeafb07){const _0x2c55df=this['_revisionsRepository']['getRevision'](_0xeafb07['id']),_0x5a2aeb=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x2c55df['id']);this['_revisionViewer']['compare'](_0x2c55df,_0x5a2aeb);}['_handleRevisionSetName'](_0x135269,_0x452b0f){this['_revisionsRepository']['getRevision'](_0x452b0f['id'])['setName'](_0x452b0f['name']);}['_handleDiffChange'](_0x1b9d08,_0x423bd4,_0x36b495){const _0x49c38f=this['_revisionsRepository']['getRevisionsInDiff'](_0x36b495);_0x49c38f['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x49c38f),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x49c38f[0x0]));}['_createRevisionActions'](){const _0x43f2f3=this['editor'],_0x619fa9=d['availableRevisionActions'],_0x71763a=_0x43f2f3['config']['get']('revisionHistory.revisionActions')||d['defaultRevisionActions'];if(_0x71763a['length'])return _0x71763a['map'](_0x4033d5=>{const _0x4f9857='string'==typeof _0x4033d5?Object['assign']({},_0x619fa9[_0x4033d5]):_0x4033d5;return _0x4f9857['action']=_0x4f9857['action']['bind'](this,_0x43f2f3),_0x4f9857['isVisible']&&(_0x4f9857['isVisible']=_0x4f9857['isVisible']['bind'](this,_0x43f2f3)),_0x4f9857;});}}function at(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x4a5eac},_0x3c6b76)=>{const _0x15f489=_0x4a5eac['get'](u),_0x1669ba=_0x15f489['repository'];let _0x5df038=_0x15f489['diff']['newRevisionId'],_0x383af5=_0x3c6b76['id'];_0x1669ba['getIndex'](_0x5df038)>_0x1669ba['getIndex'](_0x383af5)&&([_0x5df038,_0x383af5]=[_0x383af5,_0x5df038]),_0x15f489['compare'](_0x5df038,_0x383af5);},'isVisible':({plugins:_0x598257},_0x35d4b0)=>{const _0x6c25e7=_0x598257['get'](u);return!(_0x6c25e7['repository']['getRevisionsInDiff'](_0x6c25e7['diff'])['length']>0x2)&&!_0x35d4b0['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x29574e,{id:_0x5d62e2})=>{_0x29574e['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x5d62e2);},'isVisible':({plugins:_0x557718},_0x48dcfd)=>!!_0x557718['get'](u)['repository']['getLaterVisibleRevision'](_0x48dcfd['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x239bbd},{id:_0x14e271,revisionNameView:_0x297ce6})=>{const _0x47760c=_0x239bbd['get'](u),_0x27a1c3=_0x47760c['repository']['getEarlierVisibleRevision'](_0x14e271);_0x47760c['compare'](_0x14e271,_0x27a1c3),_0x297ce6['focus'](),_0x297ce6['fieldView']['select']();}}};}class Z extends tt{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0xbda29c,_0x21f8a6){super(_0xbda29c),this['_view']=_0x21f8a6,this['_toolbarConfig']=st(_0xbda29c['config']['get']('toolbar')),this['_elementReplacer']=new it();}get['element'](){return this['view']['element'];}['init'](_0x4dc3ce){const _0x2b70e6=this['editor'],_0xa1af23=this['view'],_0x24c5b2=_0x2b70e6['editing']['view'],_0x31696f=_0xa1af23['editable'],_0x50cb68=_0x24c5b2['document']['getRoot']();_0x31696f['name']=_0x50cb68['rootName'],_0xa1af23['render']();const _0x30e089=_0x31696f['element'];this['setEditableElement'](_0x31696f['name'],_0x30e089),_0xa1af23['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x24c5b2['attachDomRoot'](_0x30e089),this['_elementReplacer']['replace'](_0x4dc3ce,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x41fd86=this['view'],_0x2e7e55=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x2e7e55['detachDomRoot'](_0x41fd86['editable']['name']),_0x41fd86['destroy']();}['_initToolbar'](){const _0x5ee8b7=this['view'];_0x5ee8b7['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x5ee8b7['stickyPanel']['limiterElement']=_0x5ee8b7['element'],_0x5ee8b7['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x7e009})=>_0x7e009),_0x5ee8b7['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x5ee8b7['toolbar']);}}class ii extends _0xe309dd{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x56259f,_0x4f1965,_0x3da027={}){super(_0x56259f),this['stickyPanel']=new _0x431794(_0x56259f),this['toolbar']=new _0x3ab602(_0x56259f,{'shouldGroupWhenFull':_0x3da027['shouldToolbarGroupWhenFull']}),this['_editable']=new te(_0x56259f,_0x4f1965);}['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
+ _0x172418(_0x2e5e70){['_ui'];get['ui'](){return this['_ui'];}constructor(_0xcae7cd,_0x750302){super(_0x750302),this['sourceElement']=_0xcae7cd,this['model']['document']['createRoot']();const _0x56c577=new ii(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new Z(this,_0x56c577);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x4b8e4f,_0x4b2080){const _0x116b4a=new this(_0x4b8e4f,_0x4b2080);return await _0x116b4a['initPlugins'](),await _0x116b4a['ui']['init'](_0x4b8e4f),await _0x116b4a['data']['init'](_0x116b4a['config']['get']('initialData')||''),_0x116b4a['fire']('ready'),_0x116b4a;}}const p=['RevisionHistoryUI','RestrictedEditingMode','AIChat','AIReviewMode','AIBalloon','AIQuickActions','AIActions'];class ht extends _0x1cbf02{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0xd466f7){function _0x23ee85(_0x1d5581){return _0x1d5581['map'](_0x446c1a=>String['fromCharCode'](_0x446c1a))['join']('');}super(_0xd466f7),this['result']='end',_0xd466f7[_0x23ee85([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x23ee85([0x76,0x69,0x65,0x77])][_0x23ee85([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x23ee85([0x61,0x75,0x74,0x6f]),_0xd466f7[_0x23ee85([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x23ee85([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x23ee85([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x23ee85([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x23ee85([0x6f,0x6b])});}}class ct extends _0x1cbf02{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h,l];}constructor(_0x23da41){if(super(_0x23da41),!this['editor']['config']['get']('revisionHistory'))throw new _0x3e1231('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x30b334=>this['_showRevisionViewer']({..._0x30b334,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x1a7012=>this['_closeRevisionViewer'](_0x1a7012)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x5c1bee=>this['_restoreRevision'](_0x5c1bee)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x34a4ed){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x34a4ed;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x3739e2){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x3739e2);}['getRevision'](_0x47a121){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x47a121);}['getRevisions'](_0x49361c){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x49361c||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x4e6bb1=this['editor'],_0x15a322=_0x3aa6a7(_0x4e6bb1,p),_0x5974d4=_0x4e6bb1['plugins']['get']('RevisionTracker'),_0x4f5aba=_0x4e6bb1['plugins']['get']('Users')['users'];return _0x15a322['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x15a322['lazyRoots'],(_0x15a322['plugins']['push'](ht,u,v,class extends _0x1cbf02{static get['requires'](){return[u,'Users'];}['init'](){const _0x2a9c79=this['editor']['plugins']['get']('Users');for(const _0xb5eb02 of _0x4f5aba)_0xb5eb02['isAnonymous']||_0x2a9c79['getUser'](_0xb5eb02['id'])||_0x2a9c79['addUser'](_0xb5eb02);const _0x200e7f=_0x5974d4['repository']['getRevisions']();let _0x452e26=null;const _0x22466a=this['editor']['plugins']['get']('RevisionViewer');_0x22466a['adapter']=_0x5974d4['adapter'],_0x22466a['bind']('isEnabled')['to'](_0x5974d4),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x4e6bb1,'isReadOnly',_0x3f9a60=>!_0x3f9a60);for(const _0xce9e8d of _0x200e7f){const _0x230a3e=null===_0xce9e8d['creator'];if(_0x230a3e&&_0xce9e8d['toVersion']===_0xce9e8d['fromVersion'])continue;const _0x520ce5=_0xce9e8d['toJSON']();_0x22466a['addRevisionData'](_0x520ce5,(_0x2e8d20,_0x878731,_0x5d9f18)=>{if(_0x230a3e){if(_0x452e26)_0x452e26['_update'](_0x2e8d20,_0x878731);else{if(!_0x878731){const _0x1832b4=_0x5d9f18['toJSON']();_0x1832b4['id']=_0x14dab8(),_0x5974d4['saveRevision'](_0x1832b4,_0x5d9f18['toVersion'])['then'](_0x41d749=>{_0x452e26=_0x41d749;});}}}else _0xce9e8d['_update'](_0x2e8d20,_0x878731);});}}},d),_0x15a322);}['_enhanceShowRevisionViewerCallback'](){const _0x53006b=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x191b8b=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x47a63b=this['editor']['plugins']['get']('Autosave');await _0x47a63b['save']();}else await _0x191b8b['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0xe90689=this['editor']['plugins']['get']('Dialog');_0xe90689['isOpen']&&_0xe90689['hide']();}if(this['editor']['plugins']['has']('AITabs')){const _0x288ab4=this['editor']['plugins']['get']('AITabs')['view']['panelViews'];for(const _0x379d90 of _0x288ab4)_0x379d90['class']=_0x379d90['class']?_0x379d90['class']+'\x20ck-tab-panel_disabled':'ck-tab-panel_disabled';if(this['editor']['plugins']['has']('AIChat')){const _0x39006c=document['querySelector']('.ck-ai-chat__prompt-input\x20.ck-textarea');_0x39006c&&_0x39006c['setAttribute']('tabindex','-1');}if(this['editor']['plugins']['has']('AIChatHistory')){const _0x5f3eb9=document['querySelector']('.ck-ai-chat-history\x20.ck-input');_0x5f3eb9&&_0x5f3eb9['setAttribute']('tabindex','-1');}}const _0x35e12b=this['_getRevisionViewerEditorConfig']();return _0x53006b(_0x35e12b)['then'](_0x9f594a=>{return(this['_viewerEditor']=_0x9f594a,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'),_0x9f594a);})['catch'](_0x319aca=>(console['error'](_0x319aca),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x4783a6=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 _0x3f6790=this['editor']['plugins']['get']('AITabs')['view']['panelViews'];for(const _0x45eb53 of _0x3f6790)_0x45eb53['class']='ck-tab-panel_disabled'===_0x45eb53['class']?'':_0x45eb53['class']['replace']('\x20ck-tab-panel_disabled','');if(this['editor']['plugins']['has']('AIChat')){const _0x137776=document['querySelector']('.ck-ai-chat__prompt-input\x20.ck-textarea');_0x137776&&_0x137776['removeAttribute']('tabindex');}if(this['editor']['plugins']['has']('AIChatHistory')){const _0x5694c8=document['querySelector']('.ck-ai-chat-history\x20.ck-input');_0x5694c8&&_0x5694c8['removeAttribute']('tabindex');}}return this['_viewerEditor']['plugins']['get']('RevisionViewer')['_cleanUp'](),_0x4783a6(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x1520d0=this['editor']['plugins']['get']('Annotations');_0x1520d0['refreshVisibility'](),_0x1520d0['refreshPositioning']();}});});}['_showRevisionViewer'](_0x32ed80){const _0xdee7c=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x37ae0c=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x50a77b=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return f['create'](_0x50a77b,_0x32ed80)['then'](_0x2fcc44=>(_0x37ae0c['style']['display']='block',_0xdee7c['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x2fcc44));}['_closeRevisionViewer'](_0x427490){const _0x1d6dcd=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x1d6dcd['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x427490['destroy']();}async['_restoreRevision'](_0xc7a2ba){const _0x526199=this['editor'],_0x319528=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x572bcb=_0x526199['plugins']['get']('RevisionTracker'),_0x2e6f15=_0x526199['plugins']['get']('RevisionHistoryUtils'),_0x4fe9fa=_0x319528['repository']['getRevision'](_0xc7a2ba);let _0x4d14db,_0x5058ee,_0xd6b107;try{await _0x2e6f15['loadRevisionData'](_0x4fe9fa,this['adapter']),_0x4d14db=_0x2e6f15['getRevisionDocumentData'](_0x4fe9fa),_0x5058ee=_0x2e6f15['getRevisionRootsAttributes'](_0x4fe9fa);}catch(_0x53a568){return void console['error'](_0x53a568);}_0x526199['model']['change'](_0x40a9b7=>{for(const _0x253595 of Array['from'](_0x526199['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x40a9b7['removeMarker'](_0x253595);}),_0x319528['isReady']=!0x1,_0x526199['model']['enqueueChange'](_0xe7323f=>{_0xe7323f['setSelection'](null),_0xe7323f['removeSelectionAttribute'](_0x526199['model']['document']['selection']['getAttributeKeys']());const _0x531943=Object['keys'](_0x4d14db);for(const _0x256ad8 of _0x526199['model']['document']['roots'])'$graveyard'!=_0x256ad8['rootName']&&_0x256ad8['isAttached']()&&!_0x531943['includes'](_0x256ad8['rootName'])&&_0xe7323f['detachRoot'](_0x256ad8);for(const _0x1816b8 of _0x531943){let _0x28168c=_0x526199['model']['document']['getRoot'](_0x1816b8);_0x28168c&&_0x28168c['isAttached']()||(_0x28168c=_0xe7323f['addRoot'](_0x1816b8));const _0x15d2ed=_0x5058ee[_0x1816b8],_0x1313ec=Object['keys'](_0x15d2ed),_0x551ed6=_0x4d14db[_0x1816b8];for(const _0x3f7106 of _0x28168c['getAttributeKeys']())_0x1313ec['includes'](_0x3f7106)||_0xe7323f['removeAttribute'](_0x3f7106,_0x28168c);for(const _0x7ae3a6 of _0x1313ec)_0xe7323f['setAttribute'](_0x7ae3a6,_0x5058ee[_0x1816b8][_0x7ae3a6],_0x28168c);_0xe7323f['remove'](_0xe7323f['createRangeIn'](_0x28168c)),_0xe7323f['insert'](_0x526199['data']['parse'](_0x551ed6,_0x28168c),_0x28168c,0x0);}});const _0x3f795a=m(_0x526199['locale'],'Restored');if(_0x4fe9fa['name'])_0xd6b107=-0x1==_0x4fe9fa['name']['indexOf'](_0x3f795a)?_0x3f795a+':\x20'+_0x4fe9fa['name']:_0x4fe9fa['name'];else _0xd6b107=_0x3f795a+':\x20'+(_0x4fe9fa['createdAt']['toLocaleDateString'](_0x526199['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x4fe9fa['createdAt']['toLocaleTimeString'](_0x526199['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x572bcb['saveRevision']({'name':_0xd6b107}),_0x319528['isReady']=!0x0,_0x526199['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};