@ckeditor/ckeditor5-revision-history 47.3.0-alpha.6 → 47.3.0-alpha.7

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 _0x55ca03,uid as _0x118ae2,Collection as _0x4658e5,logWarning as _0x88625c,FocusTracker as _0x396f50,KeystrokeHandler as _0x2e51cc,scrollViewportToShowTarget as _0xd0b7de,ResizeObserver as ot,ElementReplacer as it,CKEditorError as _0x2520ea}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x3f9059,set as _0x5785c6,unset as _0x13eafe,isEqual as _0xb75ec2}from'es-toolkit/compat';import{Plugin as _0x4b71e4,PendingActions as _0xbbae3a,Command as _0x518bfa,ElementApiMixin as _0x57ec93,Editor as _0x18abd4}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x3ecf8d,getMarkerDomElement as _0x4ba0e4,ConfirmMixin as _0x5eb75f,sanitizeEditorConfig as _0x1498a0}from'ckeditor5-collaboration/dist/index.js';import{ViewContainerElement as _0x5c53e0,ViewAttributeElement as _0x29027f,ViewEmptyElement as _0xb86252,ViewRawElement as _0x4fb903,ViewUIElement as _0x553147,ViewDocumentFragment as _0x28c8b2,ViewText as _0x39d77d,ViewElement as _0x4578d7,ModelElement as _0x10b403,ModelRange as _0x10fc72,ModelPosition as _0x11d7f2,ModelDocumentFragment as _0x3b75f6,ModelText as _0x5eda90}from'@ckeditor/ckeditor5-engine/dist/index.js';import{IconHistory as _0x31711b,IconChevronUp as _0x54e670,IconChevronDown as _0x1fe749,IconUndo as _0x90f4af,IconUser as _0x2d4ff3,IconThreeVerticalDots as _0x170036}from'@ckeditor/ckeditor5-icons/dist/index.js';import{CssTransitionDisablerMixin as _0x31d8fc,View as _0x3ee578,submitHandler as _0x4b40dc,LabeledFieldView as et,createLabeledInputText as ti,createDropdown as _0x5925fb,ListView as _0x3a0269,ListItemView as _0x574af4,ButtonView as _0x235a06,MenuBarMenuView as _0x59831c,MenuBarMenuListView as _0x496b67,MenuBarMenuListItemView as _0x1465f4,MenuBarMenuListItemButtonView as _0x59c301,ContextualBalloon as _0x3c59fb,ToolbarSeparatorView as _0x5652f5,IconView as _0x468b2c,addListToDropdown as _0x2c6bad,UIModel as to,EditorUI as tt,normalizeToolbarConfig as st,BoxedEditorUIView as _0x10dfd8,StickyPanelView as _0x474490,ToolbarView as _0x2f00f8,InlineEditableUIView as te}from'@ckeditor/ckeditor5-ui/dist/index.js';import{DateTime as _0x1fdea2}from'luxon';class I extends/* #__PURE__ -- @preserve */
24
- _0x55ca03(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x584af9){super(),this['id']=_0x584af9['id']||_0x118ae2(),this['creator']=_0x584af9['creator']||null,this['authors']=_0x584af9['authors']||[],this['diffData']=_0x584af9['diffData']||null,this['toVersion']=_0x584af9['toVersion']||0x0,this['fromVersion']=_0x584af9['fromVersion']||0x0,this['set']('name',_0x584af9['name']||''),this['set']('createdAt',_0x584af9['createdAt']||new Date()),this['set']('attributes',_0x584af9['attributes']||{});}['setName'](_0x539c66){this['_update']({'name':_0x539c66});}['setAttribute'](_0x1d86ea,_0x9c0d45){const _0x59087d=_0x3f9059(this['attributes']);_0x5785c6(_0x59087d,_0x1d86ea,_0x9c0d45),this['_update']({'attributes':_0x59087d});}['removeAttribute'](_0x25c48b){const _0x4b8b12=_0x3f9059(this['attributes']);_0x13eafe(_0x4b8b12,_0x25c48b),this['_update']({'attributes':_0x4b8b12});}['_update'](_0x333748,_0x1d3115=!0x1){let _0x16ab5f=!0x1;const _0x50678c={'id':this['id']},_0x20520f=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x516ef6 of _0x20520f){const _0x162799=_0x333748[_0x516ef6];void 0x0!==_0x162799&&_0x162799!==this[_0x516ef6]&&(this[_0x516ef6]=_0x162799,_0x50678c[_0x516ef6]=_0x162799,_0x16ab5f=!0x0);}_0x16ab5f&&(_0x50678c['authors']&&(_0x50678c['authorsIds']=_0x50678c['authors']['map'](_0x301aad=>_0x301aad['id']),delete _0x50678c['authors']),this['fire']('_update',_0x50678c,_0x1d3115));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x1b3d54=>_0x1b3d54['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class S extends _0x4b71e4{['_revisions'];static get['requires'](){return[_0x3ecf8d];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x366af6){super(_0x366af6),this['_revisions']=new _0x4658e5();}['afterInit'](){!async function(_0x327a83){const _0x1c32de=_0x14147c([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]),_0x5aaca4=0xeb829,_0x221d3e=0x359e09b0,_0xe8aa10=0x35997370^_0x221d3e,_0x387539=window[_0x14147c([0x44,0x61,0x74,0x65])][_0x14147c([0x6e,0x6f,0x77])](),_0x50386e=_0x327a83[_0x14147c([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x26e2c2=new window[(_0x14147c([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x3fac8d=>{_0x50386e[_0x14147c([0x6f,0x6e,0x63,0x65])](_0x14147c([0x72,0x65,0x61,0x64,0x79]),_0x3fac8d);}),_0x3370f9={[_0x14147c([0x6b,0x74,0x79])]:_0x14147c([0x45,0x43]),[_0x14147c([0x75,0x73,0x65])]:_0x14147c([0x73,0x69,0x67]),[_0x14147c([0x63,0x72,0x76])]:_0x14147c([0x50,0x2d,0x32,0x35,0x36]),[_0x14147c([0x78])]:_0x14147c([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]),[_0x14147c([0x79])]:_0x14147c([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]),[_0x14147c([0x61,0x6c,0x67])]:_0x14147c([0x45,0x53,0x32,0x35,0x36])},_0x2ba8a9=_0x50386e[_0x14147c([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x14147c([0x67,0x65,0x74])](_0x14147c([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x3fa10a(){let _0x375a93,_0x249fa9=null,_0x47fddf=null;try{if(_0x2ba8a9==_0x14147c([0x47,0x50,0x4c]))return _0x14147c([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x375a93=_0xdabd6f(),!_0x375a93)return _0x14147c([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x375a93[_0x14147c([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x47fddf=_0x1d8ad5(_0x375a93[_0x14147c([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x375a93[_0x14147c([0x6a,0x74,0x69])])),await _0x21fa77()?_0x59b0ad()?_0x1e8271()?_0x14147c([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x41a4df()?(_0x375a93[_0x14147c([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x14147c([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x249fa9=_0x2f38d0(_0x14147c([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x375a93[_0x14147c([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x14147c([0x74,0x72,0x69,0x61,0x6c])&&(_0x249fa9=_0x2f38d0(_0x14147c([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x2e1fa1()):_0x14147c([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x14147c([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x14147c([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x14147c([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x1e8271(){const _0x2e1fc4=[_0x14147c([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x14147c([0x74,0x72,0x69,0x61,0x6c])][_0x14147c([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x375a93[_0x14147c([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x387539/0x3e8:0xe10*_0xe8aa10;return _0x375a93[_0x14147c([0x65,0x78,0x70])]<_0x2e1fc4;}function _0x59b0ad(){const _0x1cb421=_0x375a93[_0x14147c([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x1cb421)return!0x1;if(_0x1cb421[_0x14147c([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x14147c([0x2a])))return!0x0;if(_0x1cb421[_0x14147c([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x14147c([0x52,0x48])))return!0x0;if(_0x1cb421[_0x14147c([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x14147c([0x52,0x52,0x48]))){if(_0xd4cb5d())return!0x0;if(_0x3e1fed()||_0x443812())return!0x0;}return!0x1;}function _0x41a4df(){const _0x5364f8=_0x375a93[_0x14147c([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x5364f8||0x0==_0x5364f8[_0x14147c([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x487eab}=new URL(window[_0x14147c([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x5364f8[_0x14147c([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x487eab))return!0x0;const _0x14819c=_0x487eab[_0x14147c([0x73,0x70,0x6c,0x69,0x74])](_0x14147c([0x2e]));return _0x5364f8[_0x14147c([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x5eae72=>_0x5eae72[_0x14147c([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x14147c([0x2a])))[_0x14147c([0x6d,0x61,0x70])](_0x17e24c=>_0x17e24c[_0x14147c([0x73,0x70,0x6c,0x69,0x74])](_0x14147c([0x2e])))[_0x14147c([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x12d91d=>_0x12d91d[_0x14147c([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x14819c[_0x14147c([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x14147c([0x6d,0x61,0x70])](_0xe1db01=>Array(_0x14819c[_0x14147c([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0xe1db01[_0x14147c([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x14147c([0x66,0x69,0x6c,0x6c])](_0xe1db01[0x0]===_0x14147c([0x2a])?_0x14147c([0x2a]):'')[_0x14147c([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0xe1db01))[_0x14147c([0x73,0x6f,0x6d,0x65])](_0x15900d=>_0x14819c[_0x14147c([0x65,0x76,0x65,0x72,0x79])]((_0x44ff6d,_0x45b0de)=>_0x15900d[_0x45b0de]===_0x44ff6d||_0x15900d[_0x45b0de]===_0x14147c([0x2a])));}function _0x2e1fa1(){return _0x249fa9&&_0x47fddf?new window[(_0x14147c([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x4fe191,_0x4ec613)=>{_0x249fa9[_0x14147c([0x74,0x68,0x65,0x6e])](_0x4fe191,_0x4ec613),_0x47fddf[_0x14147c([0x74,0x68,0x65,0x6e])](_0x11a2af=>{_0x11a2af!=_0x14147c([0x56,0x61,0x6c,0x69,0x64])&&_0x4fe191(_0x11a2af);},_0x4ec613);}):_0x249fa9||_0x47fddf||_0x14147c([0x56,0x61,0x6c,0x69,0x64]);}}function _0x1d8ad5(_0x4292e5,_0x3bc118){return new window[(_0x14147c([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0xa36ab4=>{if(_0x1194c6())return _0xa36ab4(_0x14147c([0x56,0x61,0x6c,0x69,0x64]));_0x5a3df6(),_0x50386e[_0x14147c([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x14147c([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x2ee061=!0x1;const _0x4b0adc=_0x118ae2();function _0x39a931(_0x30b312){return!!_0x30b312&&(typeof _0x30b312===_0x14147c([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x30b312===_0x14147c([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x30b312[_0x14147c([0x74,0x68,0x65,0x6e])]===_0x14147c([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x30b312[_0x14147c([0x63,0x61,0x74,0x63,0x68])]===_0x14147c([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x4edf5d(_0x2c13a7){_0x235b7a(_0x2c13a7)[_0x14147c([0x74,0x68,0x65,0x6e])](_0x307e36=>{if(!_0x307e36||_0x307e36[_0x14147c([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x14147c([0x6f,0x6b]))return _0x14147c([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x2a677c(_0x36f1ca(_0x4b0adc+_0x3bc118))!=_0x307e36[_0x14147c([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x14147c([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x14147c([0x56,0x61,0x6c,0x69,0x64]);})[_0x14147c([0x74,0x68,0x65,0x6e])](_0x8cffe6=>(_0x4e1f1a(),_0x8cffe6),()=>{const _0x84634c=_0x552b15();return null==_0x84634c?(_0x4e1f1a(),_0x14147c([0x56,0x61,0x6c,0x69,0x64])):_0x14147c(_0x387539-_0x84634c>(0x11928db0^_0x221d3e)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x14147c([0x74,0x68,0x65,0x6e])](_0xa36ab4)[_0x14147c([0x63,0x61,0x74,0x63,0x68])](()=>{_0xa36ab4(_0x14147c([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x160d25=0x35a8e730^_0x221d3e;function _0x4e1f1a(){const _0x2a2fe3=_0x14147c([0x6c,0x6c,0x63,0x74,0x2d])+_0x2a677c(_0x36f1ca(_0x4292e5)),_0x5a2cd2=_0x5c1e93(_0x2a677c(window[_0x14147c([0x4d,0x61,0x74,0x68])][_0x14147c([0x63,0x65,0x69,0x6c])](_0x387539/_0x160d25)));window[_0x14147c([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x14147c([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x2a2fe3,_0x5a2cd2);}function _0x552b15(){const _0x19ae33=_0x14147c([0x6c,0x6c,0x63,0x74,0x2d])+_0x2a677c(_0x36f1ca(_0x4292e5)),_0x5e8df0=window[_0x14147c([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x14147c([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x19ae33);return _0x5e8df0?window[_0x14147c([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x5c1e93(_0x5e8df0),0x10)*_0x160d25:null;}function _0x235b7a(_0x293494){return new window[(_0x14147c([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x14b6cd,_0x51c384)=>{_0x293494[_0x14147c([0x74,0x68,0x65,0x6e])](_0x14b6cd,_0x51c384),window[_0x14147c([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x51c384,0x359fdd70^_0x221d3e);});}}_0x50386e[_0x14147c([0x6f,0x6e])](_0x14147c([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x5a494e,_0xbb31a4)=>{if(_0xbb31a4[0x0]!=_0x4292e5)return _0xa36ab4(_0x14147c([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0xbb31a4[0x1]={..._0xbb31a4[0x1],[_0x14147c([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x4b0adc};},{[_0x14147c([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x14147c([0x68,0x69,0x67,0x68])}),_0x50386e[_0x14147c([0x6f,0x6e])](_0x14147c([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x451e49=>{_0x39a931(_0x451e49[_0x14147c([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x2ee061=!0x0,_0x4edf5d(_0x451e49[_0x14147c([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x14147c([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x14147c([0x6c,0x6f,0x77])}),_0x26e2c2[_0x14147c([0x74,0x68,0x65,0x6e])](()=>{_0x2ee061||_0xa36ab4(_0x14147c([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x1194c6(){return _0x50386e[_0x14147c([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x14147c([0x76,0x69,0x65,0x77])][_0x14147c([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x14147c([0x61,0x75,0x74,0x6f]);}function _0x5a3df6(){_0x50386e[_0x14147c([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x14147c([0x76,0x69,0x65,0x77])][_0x14147c([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x14147c([0x61,0x75,0x74,0x6f]);}}function _0x2f38d0(_0x11f75e){const _0x1d9210=[new window[(_0x14147c([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2eedf6=>setTimeout(_0x2eedf6,0x3597377c^_0x221d3e)),_0x26e2c2[_0x14147c([0x74,0x68,0x65,0x6e])](()=>new window[(_0x14147c([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x3315a2=>{const _0x5ae9df=0x359e09b7^_0x221d3e,_0x2995af=_0x327a83[_0x14147c([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x317d3b(){_0x2995af[_0x14147c([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x5ae9df&&_0x3315a2();}_0x317d3b(),_0x2995af[_0x14147c([0x6f,0x6e])](_0x14147c([0x61,0x64,0x64]),_0x317d3b);})),new window[(_0x14147c([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x75914a=>{function _0xf153bb(){for(const _0x13ce31 in window)if(window[_0x14147c([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x14147c([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x13ce31))&&window[_0x13ce31]==_0x5aaca4)return _0x75914a();_0x50386e[_0x14147c([0x73,0x74,0x61,0x74,0x65])]!=_0x14147c([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x14147c([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0xf153bb,0x359e1a38^_0x221d3e);}_0x1231b5(_0x14147c([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0xf153bb();})];return window[_0x14147c([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x14147c([0x72,0x61,0x63,0x65])](_0x1d9210)[_0x14147c([0x74,0x68,0x65,0x6e])](()=>_0x11f75e);}async function _0x20be3f(){if(await _0x26e2c2,_0x1231b5(_0x14147c([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x44234a=_0x327a83[_0x14147c([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x532aa9=_0x327a83[_0x14147c([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])](_0x44234a[_0x14147c([0x69,0x64])]),_0x5d5c4e=_0x2e2a27(_0x14147c([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x5d5c4e[_0x14147c([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x44234a['id'],_0x532aa9?_0x532aa9['id']:null,!0x0),_0x5d5c4e[_0x14147c([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x14147c([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x5d5c4e[_0x14147c([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x5d5c4e[_0x14147c([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x1149a6,void(_0x5d5c4e[_0x14147c([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x1149a6);}if(_0x1231b5(_0x14147c([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x19e94c=_0x2e2a27(_0x14147c([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x19e94c[_0x14147c([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x14147c([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x19e94c[_0x14147c([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x19e94c[_0x14147c([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x1149a6,_0x19e94c[_0x14147c([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x1149a6;}_0x50386e[_0x14147c([0x6d,0x6f,0x64,0x65,0x6c])][_0x14147c([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x1149a6,_0x50386e[_0x14147c([0x6d,0x6f,0x64,0x65,0x6c])][_0x14147c([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x1149a6,_0x50386e[_0x14147c([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x14147c([0x6d,0x6f,0x64,0x65,0x6c]));}function _0xd4cb5d(){return _0x1231b5(_0x14147c([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x2e2a27(_0x14147c([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x14147c([0x73,0x74,0x61,0x74,0x65])]==_0x14147c([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x3e1fed(){return _0x1231b5(_0x14147c([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 _0x443812(){return _0x1231b5(_0x14147c([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x301f5b(_0x5145e1){const _0x4d166b=_0x3caa95();_0x50386e[_0x4d166b]=_0x14147c([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])+_0x5145e1,_0x5145e1[_0x14147c([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x14147c([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x3caa95()]=_0x5aaca4),_0x5145e1!=_0x14147c([0x56,0x61,0x6c,0x69,0x64])&&_0x20be3f();}function _0x3caa95(){const _0x3dbf44=window[_0x14147c([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x14147c([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x14147c([0x6e,0x6f,0x77])]())[_0x14147c([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x14147c([0x2e]),'');let _0xe5b5b7=_0x14147c([0x76]);for(let _0x3b7719=0x0;_0x3b7719<_0x3dbf44[_0x14147c([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x3b7719+=0x2){let _0x2b6b76=window[_0x14147c([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x3dbf44[_0x14147c([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x3b7719,_0x3b7719+0x2));_0x2b6b76>=_0x1c32de[_0x14147c([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x2b6b76-=_0x1c32de[_0x14147c([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0xe5b5b7+=_0x1c32de[_0x2b6b76];}return _0xe5b5b7;}function _0xdabd6f(){const _0x115382=_0x2ba8a9[_0x14147c([0x73,0x70,0x6c,0x69,0x74])](_0x14147c([0x2e]));if(0x3!=_0x115382[_0x14147c([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x77eaaf(_0x115382[0x1]);function _0x77eaaf(_0x2d5d1e){const _0x4e264e=_0x34ca50(_0x2d5d1e);return _0x4e264e&&_0x355a2b()?_0x4e264e:null;function _0x355a2b(){const _0xf7466a=_0x4e264e[_0x14147c([0x6a,0x74,0x69])],_0x4ba0ff=window[_0x14147c([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0xf7466a[_0x14147c([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0xf7466a[_0x14147c([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x2c32fa={..._0x4e264e,[_0x14147c([0x6a,0x74,0x69])]:_0xf7466a[_0x14147c([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0xf7466a[_0x14147c([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x2c32fa[_0x14147c([0x76,0x63])],_0x36f1ca(_0x2c32fa)==_0x4ba0ff;}}}async function _0x21fa77(){let _0x3f1a4c=!0x0;try{const _0x4b20fd=_0x2ba8a9[_0x14147c([0x73,0x70,0x6c,0x69,0x74])](_0x14147c([0x2e])),[_0x54e4eb,_0x5464cb,_0x3383ff]=_0x4b20fd;return _0x2b2bd1(_0x54e4eb),await _0x25d18f(_0x54e4eb,_0x5464cb,_0x3383ff),_0x3f1a4c;}catch{return!0x1;}function _0x2b2bd1(_0x21fc8d){const _0x55e154=_0x34ca50(_0x21fc8d);_0x55e154&&_0x55e154[_0x14147c([0x61,0x6c,0x67])]==_0x14147c([0x45,0x53,0x32,0x35,0x36])||(_0x3f1a4c=!0x1);}async function _0x25d18f(_0x176a76,_0x31c5d5,_0x3ccfb9){const _0x5d4680=window[_0x14147c([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x14147c([0x66,0x72,0x6f,0x6d])](_0x4e39c2(_0x3ccfb9),_0x32b3f0=>_0x32b3f0[_0x14147c([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x4284c7=new window[(_0x14147c([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x14147c([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x176a76+_0x14147c([0x2e])+_0x31c5d5),_0x3c5e8c=window[_0x14147c([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x14147c([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x3c5e8c)return;const _0x4ccbd8=await _0x3c5e8c[_0x14147c([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x14147c([0x6a,0x77,0x6b]),_0x3370f9,{[_0x14147c([0x6e,0x61,0x6d,0x65])]:_0x14147c([0x45,0x43,0x44,0x53,0x41]),[_0x14147c([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x14147c([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x14147c([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x3c5e8c[_0x14147c([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x14147c([0x6e,0x61,0x6d,0x65])]:_0x14147c([0x45,0x43,0x44,0x53,0x41]),[_0x14147c([0x68,0x61,0x73,0x68])]:{[_0x14147c([0x6e,0x61,0x6d,0x65])]:_0x14147c([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x4ccbd8,_0x5d4680,_0x4284c7)||(_0x3f1a4c=!0x1);}}function _0x34ca50(_0x4623d4){return _0x4623d4[_0x14147c([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x14147c([0x65,0x79]))?JSON[_0x14147c([0x70,0x61,0x72,0x73,0x65])](_0x4e39c2(_0x4623d4)):null;}function _0x4e39c2(_0x25ce81){return window[_0x14147c([0x61,0x74,0x6f,0x62])](_0x25ce81[_0x14147c([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x14147c([0x2b]))[_0x14147c([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x14147c([0x2f])));}function _0x36f1ca(_0x69fb03){let _0x1741c6=0x1505;function _0xb8fe46(_0x12ca2b){for(let _0x963fbe=0x0;_0x963fbe<_0x12ca2b[_0x14147c([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x963fbe++){const _0x298b4c=_0x12ca2b[_0x14147c([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x963fbe);_0x1741c6=(_0x1741c6<<0x5)+_0x1741c6+_0x298b4c,_0x1741c6&=_0x1741c6;}}function _0xa2d351(_0x5a938c){Array[_0x14147c([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x5a938c)?_0x5a938c[_0x14147c([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0xa2d351):_0x5a938c&&typeof _0x5a938c==_0x14147c([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x14147c([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x5a938c)[_0x14147c([0x73,0x6f,0x72,0x74])]()[_0x14147c([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x19ac00,_0x45d95c])=>{_0xb8fe46(_0x19ac00),_0xa2d351(_0x45d95c);}):_0xb8fe46(window[_0x14147c([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x5a938c));}return _0xa2d351(_0x69fb03),_0x1741c6>>>0x0;}function _0x2a677c(_0x1c667d){return _0x1c667d[_0x14147c([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x14147c([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x14147c([0x30]));}function _0x5c1e93(_0x3c256a){return _0x3c256a[_0x14147c([0x73,0x70,0x6c,0x69,0x74])]('')[_0x14147c([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x14147c([0x6a,0x6f,0x69,0x6e])]('');}function _0x1231b5(_0x3d6535){return _0x50386e[_0x14147c([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x14147c([0x68,0x61,0x73])](_0x3d6535);}function _0x2e2a27(_0x5a26c7){return _0x50386e[_0x14147c([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x14147c([0x67,0x65,0x74])](_0x5a26c7);}function _0x1149a6(){}function _0x14147c(_0x1ef970){return _0x1ef970['map'](_0x441353=>String['fromCharCode'](_0x441353))['join']('');}_0x301f5b(await _0x3fa10a());}(this);}['createRevision'](_0x49013e){const _0x17e112=this['editor']['plugins']['get']('Users');return new I({'id':_0x49013e['id'],'name':_0x49013e['name'],'creator':_0x49013e['creatorId']?_0x17e112['getUser'](_0x49013e['creatorId']):null,'diffData':_0x49013e['diffData']||_0x49013e['data'],'authors':_0x49013e['authorsIds']['map'](_0x2fa6bc=>_0x17e112['getUser'](_0x2fa6bc)),'createdAt':new Date(_0x49013e['createdAt']),'attributes':_0x49013e['attributes'],'fromVersion':_0x49013e['fromVersion'],'toVersion':_0x49013e['toVersion']});}['addRevision'](_0x5658cf,_0x2959d0=0x0){this['_revisions']['add'](_0x5658cf,_0x2959d0);}['getRevision'](_0x6ed856){return this['_revisions']['get'](_0x6ed856);}['getRevisions'](_0x59eb19={'toJSON':!0x1}){const _0x44c457=Array['from'](this['_revisions']);return _0x44c457['reverse'](),_0x59eb19['toJSON']?_0x44c457['map'](_0x527c6f=>_0x527c6f['toJSON']()):_0x44c457;}['getIndex'](_0x1f50f2){return this['_revisions']['getIndex'](_0x1f50f2);}['getEarlierVisibleRevision'](_0x1dbc83){const [,_0xfaec11]=this['getRevisionsIterator'](_0x1dbc83,{'direction':'earlier'});return _0xfaec11;}['getLaterVisibleRevision'](_0x19c320){const [,_0x2d339f]=this['getRevisionsIterator'](_0x19c320,{'direction':'later'});return _0x2d339f;}['getRevisionsInDiff'](_0x5355fd){const _0x116d10=[];for(const _0x54739d of this['getRevisionsIterator'](_0x5355fd['newRevisionId']))if(_0x116d10['push'](_0x54739d),_0x54739d['id']===_0x5355fd['oldRevisionId'])break;return _0x116d10;}*['getRevisionsIterator'](_0x29447d,{direction:_0x296867='earlier',filter:_0xcddfc4=()=>!0x0}={}){const _0x3598c4='earlier'===_0x296867?0x1:-0x1;let _0x403e27=this['_revisions']['get'](_0x29447d),_0x468c7c=this['getIndex'](_0x403e27);for(yield _0x403e27;_0x403e27;){if(_0x468c7c+=_0x3598c4,_0x403e27=this['getRevision'](_0x468c7c),!_0x403e27)return;_0xcddfc4(_0x403e27)&&(yield _0x403e27);}}}class $ extends _0x4b71e4{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x5c53e0,'c'],[_0x29027f,'a'],[_0xb86252,'e'],[_0x4fb903,'r'],[_0x553147,'u']]);['_typeCharToViewClass']=new Map([['c',_0x5c53e0],['a',_0x29027f],['e',_0xb86252],['r',_0x4fb903],['u',_0x553147]]);async['loadRevisionData'](_0x291025,_0x52f375){if(_0x291025['diffData']||!_0x52f375)return;const _0x2f3056=this['editor']['config']['get']('collaboration.channelId'),_0x128a3f=await _0x52f375['getRevision']({'channelId':_0x2f3056,'revisionId':_0x291025['id']});_0x291025['diffData']=_0x128a3f['diffData'];}['getRevisionDocumentData'](_0x45a276){const _0x3dcc4a={};for(const _0x4d05e5 in _0x45a276['diffData']){if(_0x45a276['diffData'][_0x4d05e5]['attachChange']&&!_0x45a276['diffData'][_0x4d05e5]['attachChange']['isAttached'])continue;const _0x4628fc=this['_removeRevisionMarkers'](JSON['parse'](_0x45a276['diffData'][_0x4d05e5]['insertions'])),_0xd826ee=this['editor']['editing']['view']['document'],_0x185c55=new _0x28c8b2(_0xd826ee,_0x4628fc['map'](_0x5d08f7=>this['_getViewFromDiffObj'](_0x5d08f7,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x3dcc4a[_0x4d05e5]=this['editor']['data']['processor']['toData'](_0x185c55),this['editor']['data']['processor']['useFillerType']('default');}return _0x3dcc4a;}['getRevisionRootsAttributes'](_0x335d6a){const _0x4e9a21={};for(const _0x459579 in _0x335d6a['diffData'])_0x335d6a['diffData'][_0x459579]['attachChange']&&!_0x335d6a['diffData'][_0x459579]['attachChange']['isAttached']||(_0x4e9a21[_0x459579]=_0x335d6a['diffData'][_0x459579]['attributesAfter']||{});return _0x4e9a21;}['_getTypeCharForViewElement'](_0x244ba5){return this['_viewClassToTypeChar']['get'](_0x244ba5['constructor']);}['_getViewFromDiffObj'](_0x3a0a8e,_0x3c45b4){const _0x15fbed=this['editor']['editing']['view']['document'];if('string'==typeof _0x3a0a8e)return new _0x39d77d(_0x15fbed,_0x3a0a8e);{let _0x3e9411,_0x427201;_0x427201='u'==_0x3a0a8e['type']||'r'==_0x3a0a8e['type']?[]:_0x3a0a8e['children']['map'](_0x8d3a0d=>this['_getViewFromDiffObj'](_0x8d3a0d,_0x3c45b4));const _0x663e0a=this['_typeCharToViewClass']['get'](_0x3a0a8e['type'])||_0x4578d7,_0x29adaf=this['editor']['data']['htmlProcessor']['domConverter'];if(_0x3e9411=new _0x663e0a(_0x15fbed,_0x3a0a8e['name'],_0x3a0a8e['attributes'],_0x427201),'u'==_0x3a0a8e['type']&&_0x3a0a8e['children'][0x0]){const _0x3d0dfc=_0x3a0a8e['children'][0x0];if(_0x3e9411['render']=function(_0x47b692){const _0x34019c=_0x47b692['createElement']('div');return _0x34019c['innerHTML']=_0x3d0dfc,_0x34019c['childNodes'][0x0];},_0x3c45b4){const _0xa7d6d7=new _0x28c8b2(_0x15fbed);_0xa7d6d7['_appendChild'](_0x3e9411);const _0x3d803f=Array['from'](_0x29adaf['viewChildrenToDom'](_0xa7d6d7,{'bind':!0x1})),_0x465fb0=_0x29adaf['domDocument']['createElement']('div');_0x465fb0['append'](..._0x3d803f),_0x3e9411=Array['from'](_0x29adaf['domChildrenToView'](_0x465fb0))[0x0];}}else{if('r'==_0x3a0a8e['type']&&_0x3a0a8e['children'][0x0]){const _0xe51d4c=_0x3a0a8e['children'][0x0];if(_0x3e9411['render']=function(_0x280d1f){_0x280d1f['innerHTML']=_0xe51d4c;},_0x3c45b4){const _0x99b630=new _0x28c8b2(_0x15fbed);_0x99b630['_appendChild'](_0x3e9411);const _0x132c55=Array['from'](_0x29adaf['viewChildrenToDom'](_0x99b630,{'bind':!0x1})),_0x2a53bb=_0x29adaf['domDocument']['createElement']('div');_0x2a53bb['append'](..._0x132c55);const _0x2e5a8a=Array['from'](_0x29adaf['domChildrenToView'](_0x2a53bb));_0x2e5a8a['length']>0x1?_0x3e9411['_appendChild'](_0x2e5a8a):_0x3e9411=_0x2e5a8a[0x0];}}}if(_0x3a0a8e['customProperties']){for(const [_0x178ea0,_0x14bdd6]of _0x3a0a8e['customProperties'])_0x3e9411['_setCustomProperty'](_0x178ea0,_0x14bdd6);}const _0x26b707=void 0x0===_0x3a0a8e['fillerOffset']?null:_0x3a0a8e['fillerOffset'];return null!==_0x26b707&&(_0x3e9411['getFillerOffset']=()=>_0x26b707),_0x3e9411;}}['_makeModelFromViewString'](_0xe35997){const _0x4600c5=JSON['parse'](_0xe35997),_0x5a5e13=this['editor']['editing']['view']['document'],_0x5cf0d7=new _0x28c8b2(_0x5a5e13,_0x4600c5['map'](_0x1f26ba=>this['_getViewFromDiffObj'](_0x1f26ba,!0x0)));return this['editor']['data']['toModel'](_0x5cf0d7);}['_removeRevisionMarkers'](_0x205686){return(_0x205686=_0x205686['filter'](_0x4afe60=>!_0x4afe60['name']||'revision-start'!==_0x4afe60['name']&&'revision-end'!==_0x4afe60['name']))['forEach'](_0x1a4836=>{'string'!=typeof _0x1a4836&&(_0x1a4836['children']=this['_removeRevisionMarkers'](_0x1a4836['children']),_0x1a4836['attributes']=_0x1a4836['attributes']['filter'](_0x4f875d=>!_0x4f875d[0x0]['startsWith']('data-revision-')));}),_0x205686;}}function m(_0x325dfc,_0x4870f7,_0x380c49){const t=_0x325dfc['t'];switch(_0x4870f7){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'},_0x380c49);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x380c49);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 _0x4b71e4{['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[_0x3ecf8d,S,$,_0xbbae3a];}constructor(_0x40e399){super(_0x40e399),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 _0x7d43d4=_0x118ae2();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x7d43d4},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 _0x16b58a=this['repository']['getRevision'](0x0),_0x4ff36b=_0x16b58a&&null===_0x16b58a['creator']?_0x16b58a:null;if(this['_continueCurrentRevision']=!!_0x4ff36b&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x2792bd=this['_source']['getCurrentRevisionId'](),_0x378af5=this['repository']['getRevision'](_0x2792bd);if(_0x378af5)this['_startingVersion']=_0x378af5['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x4b1ec7=this['_source']['history']['_operations']['find'](_0x4dae99=>!_0x4dae99['_isInit']),_0xcfbb56=_0x4b1ec7?_0x4b1ec7['baseVersion']:this['_source']['history']['version'];_0x16b58a?(_0x16b58a['toVersion']<_0xcfbb56&&_0x16b58a['_update']({'toVersion':_0xcfbb56}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x4ff36b['id'],this['_startingVersion']=_0x4ff36b['fromVersion']):(this['_startingVersion']=_0x16b58a['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0xcfbb56,this['_continueCurrentRevision']=!0x1);}}else _0x4ff36b&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x4ff36b['toVersion'],this['editor']['model']['document']['history']['version']),_0x4ff36b['fromVersion']===_0x4ff36b['toVersion']?(0x0!==_0x4ff36b['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x4ff36b['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x4ff36b['id'],this['_startingVersion']=_0x4ff36b['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',_0x5e8980=>!_0x5e8980),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x5cc7ca=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x6ade58;for(const _0x4e3ae4 in _0x5cc7ca){const _0x5832eb=_0x4e3ae4,_0x3d8309=_0x5cc7ca[_0x5832eb];if('revisionHistoryLicenseKeyValid'==_0x3d8309||'revisionHistoryLicenseKeyInvalid'==_0x3d8309||'revisionHistoryLicenseKeyExpired'==_0x3d8309||'revisionHistoryLicenseKeyDomainLimit'==_0x3d8309||'revisionHistoryLicenseKeyNotAllowed'==_0x3d8309||'revisionHistoryLicenseKeyEvaluationLimit'==_0x3d8309||'revisionHistoryLicenseKeyTrialLimit'==_0x3d8309||'revisionHistoryLicenseKeyUsageLimit'==_0x3d8309){delete _0x5cc7ca[_0x5832eb],_0x6ade58=_0x3d8309,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x6ade58&&_0x5cc7ca['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x6ade58&&_0x5cc7ca['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x6ade58&&_0x5cc7ca['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x6ade58&&_0x5cc7ca['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x6ade58&&_0x5cc7ca['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x6ade58&&_0x5cc7ca['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x6ade58&&_0x5cc7ca['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x21eff5=this['repository']['getRevision'](0x0),_0x3bae3e=await this['getRevisionDocumentData'](_0x21eff5),_0x118a25=await this['getRevisionRootsAttributes'](_0x21eff5);this['_replaceEditorDataWithRevisionData'](_0x3bae3e,_0x118a25);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x3edbb6){this['_source']=_0x3edbb6;}async['update'](){const _0x482870=await this['_source']['getLatestVersion']();if(_0x482870>this['currentRevision']['toVersion']){await this['_loadState']();const _0xce427a=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x482870});_0xce427a['authors']=_0xce427a['authorsIds']['map'](_0x4c2523=>this['editor']['plugins']['get']('Users')['getUser'](_0x4c2523)),this['currentRevision']['_update'](_0xce427a);}}async['saveRevision'](_0x3757ce={},_0x1e58bf=null){const _0x277276=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x1e58bf>this['currentRevision']['toVersion']&&(_0x1e58bf=null),null===_0x1e58bf&&(_0x1e58bf=await this['_source']['getLatestVersion']());const _0x1acdf8=this['_getFromVersion'](_0x1e58bf),_0x251ed4=this['buildRevisionData']({'from':_0x1acdf8,'to':_0x1e58bf});if(this['currentRevision']['toVersion']<_0x1e58bf){const _0x208c43=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x1e58bf,'to':_0x1e58bf});_0x208c43['authors']=[],_0x208c43['authorsIds']=[],_0x208c43['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x208c43,!0x0),delete _0x208c43['authors'],_0x277276['push'](_0x208c43);}_0x3757ce['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x3757ce['name']=_0x3757ce['name']||null,_0x3757ce['id']=_0x3757ce['id']||_0x118ae2(),_0x3757ce={..._0x3757ce,..._0x251ed4};const _0xbb30f=this['addRevisionData'](_0x3757ce);_0x277276['push'](_0x3757ce);const _0x11fbc3=this['repository']['getIndex'](_0xbb30f);if(0x0!==_0x11fbc3){const _0x161fb8=this['repository']['getRevision'](_0x11fbc3-0x1);if(_0x161fb8['fromVersion']!==_0x1e58bf){const _0x31b2aa=this['_revisionDataBuilder']['getData'](_0x1e58bf,_0x161fb8['toVersion']),_0x1281fb={'id':_0x161fb8['id'],'diffData':_0x31b2aa['diffData'],'authorsIds':_0x31b2aa['authorsIds'],'authors':_0x31b2aa['authorsIds']['map'](_0x4044a5=>this['editor']['plugins']['get']('Users')['getUser'](_0x4044a5)),'fromVersion':_0x1e58bf};_0x161fb8===this['currentRevision']&&(_0x1281fb['createdAt']=new Date(_0x3757ce['createdAt']['getTime']()+0xa)),_0x161fb8['_update'](_0x1281fb,!0x0),delete _0x1281fb['authors'],_0x277276['push'](_0x1281fb);}}if(this['adapter']){for(const _0x2c0f73 of _0x277276)this['_bufferUpdate'](_0x2c0f73['id'],_0x2c0f73,!0x0);this['sendBufferedUpdates']();}return _0xbb30f;}['addRevisionData'](_0x40dd44){const _0xe379f7=this['repository']['createRevision'](_0x40dd44);return this['adapter']&&_0xe379f7['on']('_update',(_0x287ff1,_0x48d550,_0x2de12b)=>{_0x2de12b||(this['_bufferUpdate'](_0x48d550['id'],_0x48d550,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0xe379f7,this['_findInsertionIndex'](_0xe379f7)),_0xe379f7;}async['getRevisionDocumentData'](_0x5e8339){return await this['_utils']['loadRevisionData'](_0x5e8339,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x5e8339);}async['getRevisionRootsAttributes'](_0x2d4c81){return await this['_utils']['loadRevisionData'](_0x2d4c81,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x2d4c81);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x11fee7=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x41dfd6=0x0;_0x41dfd6<_0x11fee7['length'];_0x41dfd6++){const _0x3d0778=_0x11fee7[_0x41dfd6];let _0xbfa6e8=!0x1;for(const _0x588287 of Object['keys'](_0x3d0778))void 0x0===_0x3d0778[_0x588287]?delete _0x3d0778[_0x588287]:'id'!==_0x588287&&(_0xbfa6e8=!0x0);_0xbfa6e8||(_0x11fee7[_0x41dfd6]=null);}if(_0x11fee7=_0x11fee7['filter'](_0x4a89c9=>null!==_0x4a89c9),!_0x11fee7['length'])return;for(let _0x14db40=0x0;_0x14db40<_0x11fee7['length'];_0x14db40++){const _0x41e1e5=_0x11fee7[_0x14db40];void 0x0!==_0x41e1e5['fromVersion']&&void 0x0===_0x41e1e5['toVersion']&&(_0x41e1e5['toVersion']=this['repository']['getRevision'](_0x41e1e5['id'])['toVersion']),void 0x0!==_0x41e1e5['toVersion']&&void 0x0===_0x41e1e5['fromVersion']&&(_0x41e1e5['fromVersion']=this['repository']['getRevision'](_0x41e1e5['id'])['fromVersion']);}const _0x242df4=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x11fee7,_0x242df4)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x1ff642=>{if(_0x1ff642){for(const _0x1dfe5b of _0x1ff642)this['setRevisionData']({'id':_0x1dfe5b['id'],'createdAt':_0x1dfe5b['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0x423960=null,from:_0x4c01a4=null,to:_0x3ef707=null}){_0x4c01a4=null!==_0x4c01a4?_0x4c01a4:_0x423960['fromVersion'],_0x3ef707=null!==_0x3ef707?_0x3ef707:_0x423960['toVersion'];const _0x19f658=this['_revisionDataBuilder']['getData'](_0x4c01a4,_0x3ef707),_0x393bc5={'diffData':_0x19f658['diffData'],'authorsIds':_0x19f658['authorsIds'],'fromVersion':_0x4c01a4,'toVersion':_0x3ef707};if(!_0x423960||_0x3ef707!==_0x423960['toVersion']){const _0x8005bc=_0x3ef707-0x1,_0x24c92a=this['_source']['history']['getOperation'](_0x8005bc);_0x393bc5['createdAt']=_0x24c92a&&_0x24c92a['createdAt']||new Date();}if(this['_loadedStateData']&&_0x4c01a4===this['_loadedStateData']['fromVersion']){for(const _0x274556 of this['_loadedStateData']['authors'])_0x393bc5['authorsIds']['includes'](_0x274556['id'])||_0x393bc5['authorsIds']['push'](_0x274556['id']);}return _0x393bc5;}['_bufferUpdate'](_0xb2d6fa,_0x14a4f1,_0x423a5f){if(this['_bufferedUpdates']['has'](_0xb2d6fa)){const _0x5b9314=this['_bufferedUpdates']['get'](_0xb2d6fa);_0x14a4f1=_0x423a5f?{..._0x5b9314,..._0x14a4f1}:{..._0x14a4f1,..._0x5b9314};}this['_bufferedUpdates']['set'](_0xb2d6fa,_0x14a4f1);}['setRevisionData'](_0x3cf7de){const _0x10002f=this['repository']['getRevision'](_0x3cf7de['id']);if(_0x3cf7de['createdAt']&&(_0x3cf7de['createdAt']=new Date(_0x3cf7de['createdAt'])),_0x3cf7de['authorsIds']){const _0xc55f14=this['editor']['plugins']['get']('Users');_0x3cf7de['authors']=_0x3cf7de['authorsIds']['map'](_0x59acb5=>_0xc55f14['getUser'](_0x59acb5));}_0x10002f['_update'](_0x3cf7de,!0x0);}['_createInitialRevision'](_0x3df239){const _0x43ba3b=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x43ba3b)this['_initialRevisionId']=_0x43ba3b['id'];else{const _0x56b069=!this['editor']['model']['document']['roots']['find'](_0x18ad6b=>this['editor']['model']['hasContent'](_0x18ad6b)),_0x1ce4a7=this['editor']['plugins']['get']('Users')['me']['id'],_0x352a59=m(this['editor']['locale'],_0x56b069?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x3df239,'to':_0x3df239,'id':this['_initialRevisionId'],'name':_0x352a59,'creatorId':_0x1ce4a7});}}['_createCurrentRevision'](_0x1bd65e){const _0x55f961=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x55f961),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x1bd65e,'to':_0x1bd65e,'id':_0x55f961,'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'](_0x5bdbfb,_0x19e0af){let _0x48fd8d=this['editor']['config']['get']('initialData'),_0xf82e02=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x48fd8d){_0x48fd8d={};for(const _0x918f7c of this['editor']['model']['document']['getRootNames']())_0x48fd8d[_0x918f7c]='';}if('string'==typeof _0x48fd8d&&(_0x48fd8d={'main':_0x48fd8d}),void 0x0===_0xf82e02){_0xf82e02={};for(const _0x28be77 of this['editor']['model']['document']['getRootNames']())_0xf82e02[_0x28be77]={};}let _0x41922d=!0x1;const _0x29972c=Object['keys'](_0x48fd8d),_0x21a7cd=Object['keys'](_0x5bdbfb);for(const _0x52db2c of _0x29972c){if(_0x48fd8d[_0x52db2c]!==_0x5bdbfb[_0x52db2c]&&''!==_0x48fd8d[_0x52db2c]['trim']()){_0x41922d=!0x0;break;}if(!_0xb75ec2(_0xf82e02[_0x52db2c],_0x19e0af[_0x52db2c])&&Object['keys'](_0xf82e02[_0x52db2c])['length']>0x0){_0x41922d=!0x0;break;}}_0x41922d||(_0x41922d=_0x21a7cd['some'](_0x225a57=>!this['editor']['model']['document']['getRoot'](_0x225a57))),_0x41922d&&_0x88625c('editor-initial-data-replaced-with-revision-data',{'editorData':_0x48fd8d,'editorRootsAttributes':_0xf82e02,'revisionData':_0x5bdbfb,'revisionRootsAttributes':_0x19e0af}),this['editor']['config']['set']('initialData',_0x5bdbfb),this['editor']['config']['set']('rootsAttributes',_0x19e0af);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x160ac3=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x160ac3['add'](m(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0xece95){const _0x3e3055=this['repository']['getRevisions']();_0x3e3055['reverse']();let _0x33ca83=0x0;for(;_0x33ca83<_0x3e3055['length'];){const _0x44b032=_0x3e3055[_0x33ca83];if(_0x44b032===this['currentRevision']){_0x33ca83++;continue;}if(_0x44b032['id']===this['_initialRevisionId'])break;const _0x5e8139=_0xece95['toVersion']-_0x44b032['toVersion']||_0xece95['fromVersion']-_0x44b032['fromVersion'];if(_0x5e8139>0x0)break;if(_0x5e8139<0x0)_0x33ca83++;else{if(!_0xece95['creator']&&_0x44b032['creator'])break;if(_0x44b032['creator']||!_0xece95['creator']){if(_0xece95['createdAt']>_0x44b032['createdAt'])break;_0x33ca83++;}else _0x33ca83++;}}return _0x33ca83;}['_getFromVersion'](_0x493f65){const _0x5b8b0b=this['repository']['getRevisions']();_0x5b8b0b['reverse'](),_0x5b8b0b['shift']();const _0x2b23da=_0x5b8b0b['find'](_0x3a0f21=>_0x3a0f21['toVersion']<=_0x493f65)['toVersion'];return _0x2b23da<this['_startingVersion']?this['_startingVersion']:_0x2b23da;}['_makeRevision']({name:_0x1afc69,from:_0x58c22f,to:_0x14308a,creatorId:_0x40d81a,id:_0x1d05cb}){const _0x51a17f=this['buildRevisionData']({'from':_0x58c22f,'to':_0x14308a});_0x51a17f['name']=_0x1afc69,_0x51a17f['creatorId']=_0x40d81a,_0x51a17f['id']=_0x1d05cb;const _0x475a08=this['addRevisionData'](_0x51a17f);return this['adapter']&&this['_bufferUpdate'](_0x51a17f['id'],_0x51a17f,!0x0),_0x475a08;}['_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(_0x71e852){this['editor']=_0x71e852,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'](_0x4f3d54){this['source']=_0x4f3d54;const _0x5e83d0=new Map(),_0x52a2f1=new Map(),_0x1ac6be=this['editor']['model']['document']['roots']['map'](_0x36766f=>_0x36766f['rootName']);for(const _0x320342 of _0x1ac6be){const _0x37ce06=this['editor']['model']['document']['getRoot'](_0x320342),_0x25a1ca=x(_0x37ce06);_0x5e83d0['set'](_0x320342,_0x25a1ca),_0x52a2f1['set'](_0x320342,Object['fromEntries'](_0x37ce06['getAttributes']()));}const _0x574f70=Array['from'](this['editor']['model']['markers'])['map'](_0x28fb6b=>[_0x28fb6b['name'],_0x28fb6b['getRange']()]),_0x1ddb16=this['source']['version'];this['_saveMetaData'](_0x1ddb16,_0x5e83d0,_0x574f70,_0x52a2f1),this['_startingRevisionId']=this['_revisionId'];const _0xb045c4=new Map(),_0x1b5f88=new Map();for(const _0x3d50b1 of _0x1ac6be){const _0x3d1679=N(_0x3d50b1);_0xb045c4['set'](_0x3d50b1,_0x3d1679),_0x1b5f88['set'](_0x3d50b1,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0xb045c4,[],_0x1b5f88);}['getData'](_0x21cf4a,_0x1706ec){if(this['_lastFrom']===_0x21cf4a&&this['_lastTo']<=_0x1706ec)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x1706ec,!0x0);else{if(!this['_savedMetaData']['has'](_0x21cf4a)){const _0x5d3a59=this['_getPreviousFrom'](_0x21cf4a);this['_calculateMetaData'](_0x5d3a59,_0x21cf4a,!0x1);}this['_calculateMetaData'](_0x21cf4a,_0x1706ec,!0x0);}return this['_lastFrom']=_0x21cf4a,this['_lastTo']=_0x1706ec,this['_getState']();}['loadState'](_0x207491){if(!this['_savedMetaData']['has'](_0x207491['fromVersion'])){const _0x32c1d=this['_getPreviousFrom'](_0x207491['fromVersion']);this['_calculateMetaData'](_0x32c1d,_0x207491['fromVersion'],!0x1);}this['_calculateMetaData'](_0x207491['fromVersion'],_0x207491['toVersion'],!0x1);const _0xd13c0a=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x207491['fromVersion'],this['_lastTo']=_0x207491['toVersion'];for(const _0x282907 in _0x207491['diffData']){const _0x11b6cf=_0x207491['diffData'][_0x282907]['attachChange'],_0x477a86=_0x3f9059(_0x207491['diffData'][_0x282907]['attributesBefore'])||{},_0x3a9c18=_0xd13c0a['_makeModelFromViewString'](_0x207491['diffData'][_0x282907]['deletions']);_0x3a9c18['rootName']=_0x282907,_0x3a9c18['_isAttached']=!_0x11b6cf||!_0x11b6cf['isAttached'],_0x3a9c18['isAttached']=()=>_0x3a9c18['_isAttached'],this['_baseRoots']['set'](_0x282907,_0x3a9c18),this['_baseRootsAttributes']['set'](_0x282907,_0x477a86),_0x11b6cf&&this['_touchedRoots']['set'](_0x282907,_0x11b6cf);const _0x4bec46=this['_makeIdsRoot'](_0x3a9c18);this['_baseIdsRoots']['set'](_0x282907,_0x4bec46);for(const [_0x3a837a,_0x31d2e1]of _0x3a9c18['markers']){if(!_0x3a837a['startsWith']('revision:'))continue;const _0x42fee3=_0x3a837a['split'](':')[0x2];for(const _0x3136fb of _0x31d2e1['getWalker']({'singleCharacters':!0x0})){const _0x21b413=this['_getVidAttributeName'](_0x3136fb),_0x1019ec='elementEnd'==_0x3136fb['type']?_0x3136fb['previousPosition']['path']['slice'](0x0,-0x1):_0x3136fb['previousPosition']['path'],_0x5300f9=_0x4bec46['getNodeByPath'](_0x1019ec)['getAttribute'](_0x21b413);this['_touched']['set'](_0x5300f9,{'userId':_0x42fee3});}_0x3a9c18['markers']['delete'](_0x3a837a);}}this['_startingRevisionId']=this['_revisionId'];const _0x232f9f=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x5adb11=>!this['_touched']['has'](_0x5adb11));let _0x236a25=0x0;const _0x111306=new Map();for(const _0x36dfa7 in _0x207491['diffData']){const _0x5c8e6b=_0x207491['diffData'][_0x36dfa7]['attachChange'],_0x35ecc1=_0x3f9059(_0x207491['diffData'][_0x36dfa7]['attributesAfter'])||{},_0x255d8e=_0xd13c0a['_makeModelFromViewString'](_0x207491['diffData'][_0x36dfa7]['insertions']);_0x255d8e['rootName']=_0x36dfa7,_0x255d8e['_isAttached']=!_0x5c8e6b||_0x5c8e6b['isAttached'],_0x255d8e['isAttached']=()=>_0x255d8e['_isAttached'],this['_diffRoots']['set'](_0x36dfa7,_0x255d8e),this['_diffRootsAttributes']['set'](_0x36dfa7,_0x35ecc1);const _0x209d05=this['_makeIdsRoot'](_0x255d8e,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x36dfa7,_0x209d05),_0x111306['set'](_0x36dfa7,_0x255d8e['isAttached']()?_0x35ecc1:{});for(const [_0x3c6908,_0x232592]of _0x255d8e['markers']){if(!_0x3c6908['startsWith']('revision:'))continue;const _0x43f833=_0x3c6908['split'](':')[0x2];for(const _0x47aad5 of _0x232592['getWalker']({'singleCharacters':!0x0})){const _0x163453=this['_getVidAttributeName'](_0x47aad5),_0x190d67=this['_revisionId']++,_0x408199='elementEnd'==_0x47aad5['type']?_0x47aad5['previousPosition']['path']['slice'](0x0,-0x1):_0x47aad5['previousPosition']['path'];_0x209d05['getNodeByPath'](_0x408199)['_setAttribute'](_0x163453,_0x190d67),this['_touched']['set'](_0x190d67,{'userId':_0x43f833});}_0x255d8e['markers']['delete'](_0x3c6908);}for(const _0x3f0189 of this['editor']['model']['createRangeIn'](_0x255d8e)['getWalker']({'singleCharacters':!0x0})){const _0x4f9115=this['_getVidAttributeName'](_0x3f0189),_0x48d170='elementEnd'==_0x3f0189['type']?_0x3f0189['previousPosition']['path']['slice'](0x0,-0x1):_0x3f0189['previousPosition']['path'],_0x34ecc8=_0x209d05['getNodeByPath'](_0x48d170);_0x34ecc8['getAttribute'](_0x4f9115)>0x0||_0x34ecc8['_setAttribute'](_0x4f9115,_0x232f9f[_0x236a25++]);}for(const [_0x4c206d,_0x5548ea]of _0x255d8e['markers'])_0x4c206d['startsWith']('revision:')||this['_markers']['set'](_0x4c206d,_0x5548ea);}const {roots:_0x513ea0}=this['_savedMetaData']['get'](_0x207491['fromVersion']),{roots:_0x371d60}=this['_savedMetaData']['get'](_0x207491['toVersion']),_0x4de3c9=x(_0x513ea0['get']('$graveyard'));this['_baseRoots']['set']('$graveyard',_0x4de3c9),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x4de3c9,Number['NEGATIVE_INFINITY']));const _0x549c9f=x(_0x371d60['get']('$graveyard'));this['_diffRoots']['set']('$graveyard',_0x549c9f),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x549c9f));const _0x3d7d69=Array['from'](this['_diffRoots'])['map'](([_0x1eaa1e,_0x4c1df3])=>[_0x1eaa1e,x(_0x4c1df3)]);this['_saveMetaData'](this['_lastTo'],_0x3d7d69,this['_markers'],_0x111306);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0x2137ac,_0x3c52ff,_0xb51153,_0x533c91){const _0x55c643=new Map(_0x3c52ff),_0x145a79=new Map(_0x3f9059(_0x533c91)),_0x594dd2=new Map();for(const [_0x572671,_0x120cd7]of _0xb51153)_0x594dd2['set'](_0x572671,{'start':_0x120cd7['start']['clone'](),'end':_0x120cd7['end']['clone'](),'rootName':_0x120cd7['root']['rootName']});this['_savedMetaData']['set'](_0x2137ac,{'roots':_0x55c643,'markers':_0x594dd2,'rootsAttributes':_0x145a79});}['_removeMetaData'](_0x29f183){this['_savedMetaData']['delete'](_0x29f183);}['_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'](_0x665acb,_0x1a7e44=null){let _0x249d63=null;_0x665acb['is']('documentFragment')||(_0x249d63=new _0x10b403(_0x665acb['name'],{'vid_start':null===_0x1a7e44?this['_revisionId']++:_0x1a7e44++}));const _0xb32b8e=[];for(const _0x3b3575 of _0x665acb['getChildren']())if(_0x3b3575['is']('element')){_0xb32b8e['push'](this['_makeIdsRoot'](_0x3b3575,_0x1a7e44));const _0x5eee7b=_0xb32b8e[_0xb32b8e['length']-0x1];null!==_0x1a7e44&&(_0x1a7e44=_0x5eee7b['is']('element','$text')?_0x5eee7b['getAttribute']('vid')+0x1:_0x5eee7b['getAttribute']('vid_end')+0x1);}else{for(let _0x2d8918=0x0;_0x2d8918<_0x3b3575['offsetSize'];_0x2d8918++)_0xb32b8e['push'](new _0x10b403('$text',{'vid':null===_0x1a7e44?this['_revisionId']++:_0x1a7e44++}));}if(_0x665acb['is']('documentFragment')){const _0x184104=N(_0x665acb['rootName']);return _0x184104['_insertChild'](0x0,_0xb32b8e),_0x184104;}return _0x249d63['_setAttribute']('vid_end',null===_0x1a7e44?this['_revisionId']++:_0x1a7e44++),_0x249d63['_insertChild'](0x0,_0xb32b8e),_0x249d63;}['_calculateMetaData'](_0x17908f,_0x57fd91,_0x34585e){this['_reset']();const {roots:_0x246c9b,markers:_0x5578ef,rootsAttributes:_0x56ed0c}=this['_savedMetaData']['get'](_0x17908f);this['_baseRoots']=new Map(_0x246c9b),this['_baseRootsAttributes']=new Map(_0x3f9059(_0x56ed0c));for(const [_0x1f5f38,_0x3a7cb4]of this['_baseRoots'])if('$graveyard'!==_0x1f5f38&&(this['_diffRoots']['set'](_0x1f5f38,x(_0x3a7cb4)),this['_diffRootsAttributes']=new Map(_0x3f9059(_0x56ed0c)),_0x34585e)){const _0x19f3e7=this['_revisionId'];this['_idsRoots']['set'](_0x1f5f38,this['_makeIdsRoot'](_0x3a7cb4)),this['_baseIdsRoots']['set'](_0x1f5f38,this['_makeIdsRoot'](_0x3a7cb4,_0x19f3e7));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',x(this['_baseRoots']['get']('$graveyard'))),_0x34585e&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x3f2570,_0x390f2c]of _0x5578ef){const _0x4c0bd0=this['_baseRoots']['get'](_0x390f2c['rootName']),_0x3c57f4=this['_diffRoots']['get'](_0x390f2c['rootName']),_0x1f02ca=new _0x10fc72(this['_fixPosition'](_0x390f2c['start'],_0x4c0bd0),this['_fixPosition'](_0x390f2c['end'],_0x4c0bd0)),_0x1136ae=this['_fixRange'](_0x1f02ca,_0x3c57f4);_0x4c0bd0['markers']['set'](_0x3f2570,_0x1f02ca),this['_markers']['set'](_0x3f2570,_0x1136ae);}this['_applyOperations'](_0x17908f,_0x57fd91,_0x34585e);}['_applyOperations'](_0x5c5a80,_0x4773bf,_0x5b6fe7){for(const _0x5d3b9f of this['source']['getOperations'](_0x5c5a80,_0x4773bf))this['_handleOperation'](_0x5d3b9f,_0x5b6fe7);for(const _0x63d9db of this['_diffRoots']['values']())_0x63d9db['markers']['clear']();for(const [_0x24711,_0x31515e]of this['_markers']){this['_diffRoots']['get'](_0x31515e['root']['rootName'])['markers']['set'](_0x24711,_0x31515e['clone']());}const _0x1eb41f=new Map(),_0x4d1ca7=new Map();for(const [_0x1e0294,_0x374772]of this['_diffRoots'])_0x1eb41f['set'](_0x1e0294,x(_0x374772)),_0x4d1ca7['set'](_0x1e0294,this['_diffRootsAttributes']['get'](_0x1e0294));this['_saveMetaData'](_0x4773bf,_0x1eb41f,this['_markers'],_0x4d1ca7);}['_getPreviousFrom'](_0x48d4ab){const _0x3cf356=Array['from'](this['_savedMetaData']['keys']());_0x3cf356['sort']((_0xd00ce6,_0x19dee1)=>_0xd00ce6-_0x19dee1),_0x3cf356['reverse']();for(const _0x40647a of _0x3cf356)if(_0x40647a<_0x48d4ab)return _0x40647a;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x5a9e06,_0x1b3627){const _0x4903e8=Array['from'](_0x1b3627['markers'])['map'](([_0x5e0e03,_0x4630f8])=>[_0x5e0e03,this['_fixRange'](_0x4630f8,_0x5a9e06)]);_0x5a9e06['markers']=new Map(_0x4903e8);}['_transformMarkers'](_0x138d68){for(const _0x28e5f2 of this['_markers']['values']()){const _0x6f8751=_0x28e5f2['getTransformedByOperation'](_0x138d68),_0x4c39cf=_0x10fc72['_createFromRanges'](_0x6f8751);_0x28e5f2['start']=_0x4c39cf['start'],_0x28e5f2['end']=_0x4c39cf['end'];}}['_handleOperation'](_0x26228b,_0x214dd4){if('addRoot'!=_0x26228b['type']&&'detachRoot'!=_0x26228b['type']){if('insert'==_0x26228b['type']){const _0x1c7043=_0x26228b['position']['root']['rootName'];this['_diffRoots']['has'](_0x1c7043)||(this['_diffRoots']['set'](_0x1c7043,N(_0x1c7043,!0x0)),this['_diffRootsAttributes']['set'](_0x1c7043,{}),_0x214dd4&&this['_idsRoots']['set'](_0x1c7043,N(_0x1c7043,!0x0)));}else{if('addRootAttribute'==_0x26228b['type']||'removeRootAttribute'==_0x26228b['type']||'changeRootAttribute'==_0x26228b['type'])return void this['_handleRootAttributeOperation'](_0x26228b);'marker'==_0x26228b['type']&&this['_handleMarkerOperation'](_0x26228b);}if('marker'!==_0x26228b['type']){const _0x35991c=this['_cloneOperation'](_0x26228b,this['_diffRoots']);_0x35991c['_execute'](),this['_transformMarkers'](_0x35991c);}if(_0x214dd4)switch(_0x26228b['type']){case'insert':this['_handleInsertOperation'](_0x26228b);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x26228b);break;case'merge':this['_handleMergeOperation'](_0x26228b);break;case'split':this['_handleSplitOperation'](_0x26228b);}}else this['_handleRootOperation'](_0x26228b,_0x214dd4);}['_cloneOperation'](_0x4305fa,_0x5e08fb){const _0x280295=_0x4305fa['clone']();return _0x280295['_authorId']=_0x4305fa['_authorId'],this['_fixOperation'](_0x280295,_0x5e08fb),_0x280295;}['_getBaseVids'](_0x5b1083){return _0x5b1083['map'](_0x2d3704=>{const _0x50f248=this['_getVidAttributeName'](_0x2d3704);return Number(_0x2d3704['item']['getAttribute'](_0x50f248));});}['_generateTape'](_0x4ebf4b,_0x34fc48){if(_0x4ebf4b['is']('element','$text'))_0x34fc48['push']({'item':_0x4ebf4b,'type':'text'});else{_0x4ebf4b['is']('element')&&_0x34fc48['push']({'item':_0x4ebf4b,'type':'elementStart'});for(const _0x404de4 of _0x4ebf4b['getChildren']())this['_generateTape'](_0x404de4,_0x34fc48);_0x4ebf4b['is']('element')&&_0x34fc48['push']({'item':_0x4ebf4b,'type':'elementEnd'});}return _0x34fc48;}['_getState'](){const _0xc0a8fd=new Map(this['_touched']),_0x1e7135=new Map(_0xc0a8fd),_0x5f0ab3=new Map(),_0x53e654={'insertions':{},'deletions':{}},_0x466de6={'insertions':{},'deletions':{}},_0x3749ee=new Map(),_0x2fe7de=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x2fe7de['delete']('$graveyard');for(const _0x48e929 of _0x2fe7de){const _0x4af4a9=this['_diffRoots']['get'](_0x48e929)||N(_0x48e929,!0x1),_0x56f17d=this['_baseRoots']['get'](_0x48e929)||N(_0x48e929,!0x1);_0x4af4a9['isAttached']()||_0x56f17d['isAttached']()?(_0x53e654['insertions'][_0x48e929]=x(_0x4af4a9),_0x53e654['deletions'][_0x48e929]=x(_0x56f17d),this['_copyMarkers'](_0x53e654['deletions'][_0x48e929],_0x56f17d),this['_copyMarkers'](_0x53e654['insertions'][_0x48e929],_0x4af4a9),_0x466de6['insertions'][_0x48e929]=this['_generateTape'](this['_idsRoots']['get'](_0x48e929),[]),_0x466de6['deletions'][_0x48e929]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x48e929)||N(_0x48e929,!0x1),[])):_0x2fe7de['delete'](_0x48e929);}for(const _0x301630 of _0x2fe7de){const _0x4ba2b1=_0x466de6['insertions'][_0x301630];for(const _0x31def2 of _0x4ba2b1){const _0x208c4c=this['_getVidAttributeName'](_0x31def2),_0x479273=_0x31def2['item']['getAttribute'](_0x208c4c);_0x1e7135['delete'](_0x479273),_0x479273>=this['_startingRevisionId']&&_0x5f0ab3['set'](_0x479273,_0xc0a8fd['get'](_0x479273));}}for(const _0x40ecb5 of _0x2fe7de){const _0x1624ed=_0x466de6['insertions'][_0x40ecb5],_0x1dda15=this['_getBaseVids'](_0x466de6['deletions'][_0x40ecb5]);let _0x501fbd=0x0;for(const _0x3f84c5 of _0x1624ed){const _0x2c33c9=this['_getVidAttributeName'](_0x3f84c5),_0x2377d8=_0x3f84c5['item']['getAttribute'](_0x2c33c9);if(!_0x5f0ab3['has'](_0x2377d8)&&!_0x3749ee['has'](_0x2377d8)){if(_0x1e7135['has'](_0x2377d8))_0x501fbd++;else{if(_0x2377d8!=_0x1dda15[_0x501fbd]){const _0x5bf071=_0xc0a8fd['get'](_0x2377d8)||_0xc0a8fd['get'](_0x1dda15[_0x501fbd]);for(;_0x2377d8!=_0x1dda15[_0x501fbd];)_0x1e7135['has'](_0x1dda15[_0x501fbd])||(_0x3749ee['set'](_0x1dda15[_0x501fbd],_0x5bf071),_0xc0a8fd['set'](_0x1dda15[_0x501fbd],_0x5bf071)),_0x501fbd++;}_0x501fbd++;}}}}for(const _0x3bae32 of _0x2fe7de){const _0x1a314f=_0x466de6['insertions'][_0x3bae32];for(const _0x5fcc2d of _0x1a314f){const _0x470488=this['_getVidAttributeName'](_0x5fcc2d),_0x3e4240=_0x5fcc2d['item']['getAttribute'](_0x470488);if(_0x3749ee['has'](_0x3e4240)){const _0x2dc179=_0x3749ee['get'](_0x3e4240);_0x1e7135['has'](_0x3e4240)||_0x1e7135['set'](_0x3e4240,{..._0x2dc179}),_0x5f0ab3['set'](_0x3e4240,{..._0x2dc179});}}}for(const _0x16654c of _0x1e7135['keys']())_0x16654c>=this['_startingRevisionId']&&_0x1e7135['delete'](_0x16654c);const _0x500ab5=new Map();for(const _0x4bd3af of _0x2fe7de){let _0x4c0279=_0x466de6['insertions'][_0x4bd3af];for(const _0x2510ab of _0x4c0279)if(_0x2510ab['item']['is']('element','tableCell')){const _0x5a740d=this['_getVidAttributeName'](_0x2510ab),_0x2b2a50=_0x2510ab['item']['getAttribute'](_0x5a740d);if(_0x5f0ab3['has'](_0x2b2a50)){const _0x2e3df8=_0x2510ab['item']['parent']['parent']['getAttribute']('vid_start'),_0x57248f=_0x500ab5['get'](_0x2e3df8)||new Set();_0x57248f['add'](_0x5f0ab3['get'](_0x2b2a50)['userId']),_0x500ab5['set'](_0x2e3df8,_0x57248f);}}_0x4c0279=_0x466de6['deletions'][_0x4bd3af];for(const _0x5897b1 of _0x4c0279)if(_0x5897b1['item']['is']('element','tableCell')){const _0x47a0cd=this['_getVidAttributeName'](_0x5897b1),_0x16fb0c=_0x5897b1['item']['getAttribute'](_0x47a0cd);if(_0x1e7135['has'](_0x16fb0c)){const _0xbf0419=_0x5897b1['item']['parent']['parent']['getAttribute']('vid_start'),_0x548b2c=_0x500ab5['get'](_0xbf0419)||new Set();_0x548b2c['add'](_0x1e7135['get'](_0x16fb0c)['userId']),_0x500ab5['set'](_0xbf0419,_0x548b2c);}}for(const _0x3e3a03 of _0x500ab5['keys']())(_0x5f0ab3['has'](_0x3e3a03)||_0x1e7135['has'](_0x3e3a03))&&_0x500ab5['delete'](_0x3e3a03);}for(const _0xa1b853 of _0x2fe7de){const _0x211c66=_0x466de6['insertions'][_0xa1b853];let _0x14bee4=null,_0x1d6447=null;for(const _0x35b2d1 of _0x211c66){const _0x221bb8=this['_getVidAttributeName'](_0x35b2d1),_0x368c82=_0x35b2d1['item']['getAttribute'](_0x221bb8),_0x50bca3=_0x500ab5['get'](_0x368c82);_0x50bca3&&'elementStart'==_0x35b2d1['type']&&(_0x14bee4=Array['from'](_0x50bca3)[0x0],_0x1d6447=_0x35b2d1['item']['getAttribute']('vid_end')),_0x14bee4&&(_0x1e7135['set'](_0x368c82,{'userId':_0x14bee4}),_0x5f0ab3['set'](_0x368c82,{'userId':_0x14bee4})),_0x368c82==_0x1d6447&&(_0x14bee4=null,_0x1d6447=null);}}const _0xf8308f={},_0x5a127c=new Set();for(const _0x11e8fb of _0x2fe7de){const _0x4f499c=_0x53e654['deletions'][_0x11e8fb],_0x34a70a=_0x53e654['insertions'][_0x11e8fb];for(const {userId:_0x2d5f71}of this['_touchedMarkers']['values']())null!==_0x2d5f71&&_0x5a127c['add'](_0x2d5f71);for(const {userId:_0xaa9361}of this['_touchedRoots']['values']())null!==_0xaa9361&&_0x5a127c['add'](_0xaa9361);this['_markChanges'](_0x34a70a,_0x466de6['insertions'][_0x11e8fb],_0x5f0ab3,'insertion',_0x5a127c),this['_markChanges'](_0x4f499c,_0x466de6['deletions'][_0x11e8fb],_0x1e7135,'deletion',_0x5a127c),_0xf8308f[_0x11e8fb]={'insertions':this['_prepareViewToSave'](_0x34a70a),'deletions':this['_prepareViewToSave'](_0x4f499c),'attachChange':this['_touchedRoots']['get'](_0x11e8fb)||null,'attributesBefore':_0x3f9059(this['_baseRootsAttributes']['get'](_0x11e8fb))||{},'attributesAfter':_0x3f9059(this['_diffRootsAttributes']['get'](_0x11e8fb))};}return{'diffData':_0xf8308f,'authorsIds':Array['from'](_0x5a127c)};}['_processRootBeforeSave'](_0xa9b71e){for(const [,_0x54b75c]of _0xa9b71e['markers']){const _0x34d5c5=_0x54b75c['start']['getAncestors']()['filter'](_0x517177=>'tableCell'==_0x517177['name']);for(const _0x51149b of _0x34d5c5)0x1==_0x51149b['childCount']&&_0x51149b['getChild'](0x0)['is']('element','paragraph')&&_0x51149b['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x5b2015){this['_processRootBeforeSave'](_0x5b2015);const _0x52dfd8=this['editor']['data']['toView'](_0x5b2015,{}),_0x50a3c6=Array['from'](_0x52dfd8['getChildren']())['map'](_0x2edc46=>this['_getViewJson'](_0x2edc46));return JSON['stringify'](_0x50a3c6);}['_getViewJson'](_0x245528){if(_0x245528['is']('$text'))return _0x245528['data'];{const _0x3ffca0=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0x16e7d8=_0x245528,_0x172439=this['editor']['data']['htmlProcessor']['domConverter'],_0x6ec4b8={'type':_0x3ffca0['_getTypeCharForViewElement'](_0x16e7d8),'name':_0x16e7d8['name'],'attributes':Array['from'](_0x16e7d8['getAttributes']()),'children':Array['from'](_0x16e7d8['getChildren']())['map'](_0x3088ed=>this['_getViewJson'](_0x3088ed))};if(_0x245528['is']('uiElement')&&'$comment'!=_0x245528['name']){const _0x175a10=_0x245528['render'](_0x172439['domDocument'],_0x172439);_0x6ec4b8['children']['push'](_0x175a10['outerHTML']);}else{if(_0x245528['is']('rawElement')){const _0x3e503a=_0x172439['domDocument']['createElement'](_0x16e7d8['name']);_0x245528['render'](_0x3e503a,_0x172439),_0x6ec4b8['children']['push'](_0x3e503a['innerHTML']);}}const _0x3be95f=Array['from'](_0x16e7d8['getCustomProperties']());_0x3be95f['length']>0x0&&(_0x6ec4b8['customProperties']=_0x3be95f);const _0x275605=_0x16e7d8['getFillerOffset']();return null!==_0x275605&&(_0x6ec4b8['fillerOffset']=_0x275605),_0x6ec4b8;}}['_markChanges'](_0x403ab1,_0x45b043,_0x57c3ee,_0x5f72e,_0x3016ec){let _0x503647=null,_0x58a3e0=null,_0x770343=0x0;const _0x353606=this['editor']['model'];for(let _0x246a77=0x0;_0x246a77<_0x45b043['length'];_0x246a77++){const _0x308669=this['_getVidAttributeName'](_0x45b043[_0x246a77]),_0x12339b=_0x45b043[_0x246a77]['item']['getAttribute'](_0x308669),_0x38c8ee=_0x57c3ee['get'](_0x12339b),_0x57a662=_0x246a77==_0x45b043['length']-0x1;(!_0x503647&&_0x38c8ee&&(_0x503647=_0x38c8ee,_0x58a3e0=_0x45b043[_0x246a77]),_0x503647&&(!_0x38c8ee||_0x38c8ee['userId']!=_0x503647['userId']))&&(_0x378c5e(_0x38c8ee,P(_0x58a3e0,_0x403ab1,_0x353606),P(_0x45b043[_0x246a77],_0x403ab1,_0x353606)),_0x503647=_0x38c8ee||null,_0x58a3e0=_0x38c8ee?_0x45b043[_0x246a77]:null),_0x503647&&_0x57a662&&_0x378c5e(_0x38c8ee,P(_0x58a3e0,_0x403ab1,_0x353606),V(_0x45b043[_0x246a77],_0x403ab1,_0x353606));}function _0x378c5e(_0x2fc0cd,_0x2610c5,_0x404eb7){const _0x5f1081=_0x503647['userId'],_0x480960='revision:'+_0x5f72e+':'+_0x5f1081+':'+_0x770343++,_0x4e6b38=_0x353606['createRange'](_0x2610c5,_0x404eb7);_0x403ab1['markers']['set'](_0x480960,_0x4e6b38),null!==_0x5f1081&&_0x3016ec['add'](_0x5f1081);}}['_getVidAttributeName'](_0x4315ee){switch(_0x4315ee['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x44655c,_0x32bd00){_0x44655c['baseVersion']=null;for(const _0x42895e in _0x44655c){const _0x3c140c=_0x44655c[_0x42895e];if(_0x3c140c instanceof _0x11d7f2){const _0x1914e5=_0x32bd00['get'](_0x3c140c['root']['rootName']);_0x44655c[_0x42895e]=this['_fixPosition'](_0x3c140c,_0x1914e5);}if(_0x3c140c instanceof _0x10fc72){const _0x1541a6=_0x32bd00['get'](_0x3c140c['root']['rootName']);_0x44655c[_0x42895e]=this['_fixRange'](_0x3c140c,_0x1541a6);}'root'===_0x42895e&&(_0x44655c['root']=_0x32bd00['get'](_0x44655c['root']['rootName']));}}['_fixRange'](_0x228f34,_0x56d8db){return this['editor']['model']['createRange'](this['_fixPosition'](_0x228f34['start'],_0x56d8db),this['_fixPosition'](_0x228f34['end'],_0x56d8db));}['_fixPosition'](_0x48b37f,_0x136b1f){return this['editor']['model']['createPositionFromPath'](_0x136b1f,_0x48b37f['path'],_0x48b37f['stickiness']);}['_handleInsertOperation'](_0x4846eb){const _0x2f27bd=this['_idsRoots']['get'](_0x4846eb['position']['root']['rootName']),_0x29b741=this['_fixPosition'](_0x4846eb['position'],_0x2f27bd),_0x574244=null===_0x4846eb['_authorId']?null:_0x4846eb['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x4b4e2f=_0x29b741['parent'],_0x19e224=this['_revisionId'],_0x45ccee=[];for(const _0x32cc53 of _0x4846eb['nodes'])if(_0x32cc53['is']('element'))_0x45ccee['push'](this['_makeIdsRoot'](_0x32cc53));else{for(let _0x276d11=0x0;_0x276d11<_0x32cc53['offsetSize'];_0x276d11++)_0x45ccee['push'](new _0x10b403('$text',{'vid':this['_revisionId']++}));}const _0x381a26=this['_revisionId'];for(let _0x516903=_0x19e224;_0x516903<_0x381a26;_0x516903++)this['_touched']['set'](_0x516903,{'userId':_0x574244});_0x4b4e2f['_insertChild'](_0x29b741['offset'],_0x45ccee);}['_handleMoveOperation'](_0x32ae0d){(_0x32ae0d=this['_cloneOperation'](_0x32ae0d,this['_idsRoots']))['_execute']();const _0x474da9=null===_0x32ae0d['_authorId']?null:_0x32ae0d['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x387a2e=_0x32ae0d['getMovedRangeStart'](),_0x90af3=_0x387a2e['parent'],_0x15abc5=_0x387a2e['offset'];!function _0x3d58fe(_0x18b4f2,_0x464439,_0x616ae9,_0x40d1a2){for(let _0x5571d4=_0x616ae9;_0x5571d4<_0x40d1a2;_0x5571d4++){const _0x29353f=_0x464439['getChild'](_0x5571d4);_0x29353f['is']('element','$text')?_0x18b4f2['set'](_0x29353f['getAttribute']('vid'),{'userId':_0x474da9}):(_0x18b4f2['set'](_0x29353f['getAttribute']('vid_start'),{'userId':_0x474da9}),_0x3d58fe(_0x18b4f2,_0x29353f,0x0,_0x29353f['childCount']),_0x18b4f2['set'](_0x29353f['getAttribute']('vid_end'),{'userId':_0x474da9}));}}(this['_touched'],_0x90af3,_0x15abc5,_0x15abc5+_0x32ae0d['howMany']);}['_handleMergeOperation'](_0x401938){const _0x2c27bc=null===(_0x401938=this['_cloneOperation'](_0x401938,this['_idsRoots']))['_authorId']?null:_0x401938['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x167184=_0x401938['targetPosition']['parent'],_0x6dd499=_0x401938['sourcePosition']['parent'],_0x51d8e6=_0x167184['getAttribute']('vid_end'),_0x3a15b5=_0x6dd499['getAttribute']('vid_start');_0x167184['_setAttribute']('vid_end',_0x6dd499['getAttribute']('vid_end')),_0x6dd499['_setAttribute']('vid_end',_0x51d8e6),this['_touched']['set'](_0x3a15b5,{'userId':_0x2c27bc}),this['_touched']['set'](_0x51d8e6,{'userId':_0x2c27bc}),_0x401938['_execute']();}['_handleSplitOperation'](_0x5f2b03){const _0x1a90c9=null===(_0x5f2b03=this['_cloneOperation'](_0x5f2b03,this['_idsRoots']))['_authorId']?null:_0x5f2b03['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x1f259b=_0x5f2b03['graveyardPosition'],_0xe303df=_0x5f2b03['splitPosition']['parent'];_0x5f2b03['_execute']();const _0x283145=_0xe303df['getAttribute']('vid_end'),_0x2965c1=_0x5f2b03['insertionPosition']['nodeAfter'];if(_0x1f259b){const _0x45c319=_0x2965c1['getAttribute']('vid_end'),_0x5dfcf9=_0xe303df['getAttribute']('vid_end');_0xe303df['_setAttribute']('vid_end',_0x45c319),_0x2965c1['_setAttribute']('vid_end',_0x5dfcf9),this['_touched']['set'](_0xe303df['getAttribute']('vid_end'),{'userId':_0x1a90c9}),this['_touched']['set'](_0x2965c1['getAttribute']('vid_start'),{'userId':_0x1a90c9});}else{const _0x4e376d=this['_revisionId']++,_0x1f2f19=this['_revisionId']++;_0xe303df['_setAttribute']('vid_end',_0x4e376d),_0x2965c1['_setAttribute']('vid_start',_0x1f2f19),_0x2965c1['_setAttribute']('vid_end',_0x283145),this['_touched']['set'](_0x4e376d,{'userId':_0x1a90c9}),this['_touched']['set'](_0x1f2f19,{'userId':_0x1a90c9});}}['_handleMarkerOperation'](_0x2a4516){if(!_0x2a4516['affectsData'])return;const _0x371846=(_0x2a4516=this['_cloneOperation'](_0x2a4516,this['_diffRoots']))['oldRange']?_0x2a4516['oldRange']['root']:null,_0x1e299e=_0x2a4516['newRange']?_0x2a4516['newRange']['root']:null;_0x371846&&this['_markers']['delete'](_0x2a4516['name']),_0x1e299e&&this['_markers']['set'](_0x2a4516['name'],_0x2a4516['newRange']['clone']());const _0x54ff87=null===_0x2a4516['_authorId']?null:_0x2a4516['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x39a4c0=_0x2a4516['name'];if(!this['_touchedMarkers']['has'](_0x39a4c0))return void this['_touchedMarkers']['set'](_0x39a4c0,{'range':_0x2a4516['oldRange'],'userId':_0x54ff87});const _0x2b710e=this['_touchedMarkers']['get'](_0x39a4c0),_0x350a3d=_0x2b710e['range'],_0x194d19=_0x2a4516['newRange'];null==_0x350a3d&&null==_0x194d19||_0x350a3d&&_0x194d19&&_0x350a3d['isEqual'](_0x194d19)?this['_touchedMarkers']['delete'](_0x2a4516['name']):_0x2b710e['userId']=_0x54ff87;}['_handleRootOperation'](_0x4cb46e,_0x51a08a){this['_diffRoots']['has'](_0x4cb46e['rootName'])?this['_diffRoots']['get'](_0x4cb46e['rootName'])['_isAttached']=_0x4cb46e['isAdd']:(this['_diffRoots']['set'](_0x4cb46e['rootName'],N(_0x4cb46e['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x4cb46e['rootName'],{}),_0x51a08a&&this['_idsRoots']['set'](_0x4cb46e['rootName'],N(_0x4cb46e['rootName'],!0x0)));const _0x59b7eb=null===_0x4cb46e['_authorId']?null:_0x4cb46e['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x40e2f0=this['_touchedRoots']['get'](_0x4cb46e['rootName']);_0x40e2f0&&_0x40e2f0['userId']===_0x59b7eb?this['_touchedRoots']['delete'](_0x4cb46e['rootName']):this['_touchedRoots']['set'](_0x4cb46e['rootName'],{'userId':_0x59b7eb,'isAttached':_0x4cb46e['isAdd']});}['_handleRootAttributeOperation'](_0x511cd3){const _0x4f47a6=this['_diffRootsAttributes']['get'](_0x511cd3['root']['rootName']);null===_0x511cd3['newValue']?delete _0x4f47a6[_0x511cd3['key']]:_0x4f47a6[_0x511cd3['key']]=_0x511cd3['newValue'];}}function x(_0x2a6bf8){const _0xb7724d=N(_0x2a6bf8['rootName'],_0x2a6bf8['isAttached']());for(const _0x54f97f of _0x2a6bf8['getChildren']()){const _0x178c8b=_0x54f97f['_clone'](!0x0);_0xb7724d['_appendChild'](_0x178c8b);}return _0xb7724d;}function N(_0x1927b1,_0x4630dc=!0x0){const _0x129f23=new _0x3b75f6();return _0x129f23['rootName']=_0x1927b1,_0x129f23['_isAttached']=_0x4630dc,_0x129f23['isAttached']=()=>_0x129f23['_isAttached'],_0x129f23;}function P(_0x34b82b,_0xd631c9,_0x58465a){const _0x3dce85='elementEnd'==_0x34b82b['type']?_0x58465a['createPositionAt'](_0x34b82b['item'],'end'):_0x58465a['createPositionBefore'](_0x34b82b['item']);return _0x58465a['createPositionFromPath'](_0xd631c9,_0x3dce85['path'],_0x3dce85['stickiness']);}function V(_0x43446a,_0x45dec4,_0x37d9ac){const _0x365390='elementStart'==_0x43446a['type']?_0x37d9ac['createPositionAt'](_0x43446a['item'],0x0):_0x37d9ac['createPositionAfter'](_0x43446a['item']);return _0x37d9ac['createPositionFromPath'](_0x45dec4,_0x365390['path'],_0x365390['stickiness']);}class he extends/* #__PURE__ -- @preserve */
25
- _0x31d8fc(_0x3ee578){['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x3e9141,_0x2013e9){super(_0x3e9141),this['focusTracker']=new _0x396f50(),this['keystrokes']=new _0x2e51cc(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x2013e9),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'](),_0x4b40dc({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x1e3ea2=_0x771803=>_0x771803['stopPropagation']();this['keystrokes']['set']('arrowright',_0x1e3ea2),this['keystrokes']['set']('arrowleft',_0x1e3ea2),this['keystrokes']['set']('arrowup',_0x1e3ea2),this['keystrokes']['set']('arrowdown',_0x1e3ea2);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x229256){this['revisionNameInputView']['fieldView']['element']['value']=_0x229256['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x4cb004){const _0x135aa4=new et(this['locale'],ti),_0x5d3c75=_0x135aa4['fieldView'];_0x5d3c75['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x35ec93=m(this['locale'],'Name\x20of\x20the\x20revision');return!_0x4cb004&&(_0x35ec93+='\x20('+m(this['locale'],'optional')+')'),(_0x135aa4['label']=_0x35ec93,_0x5d3c75['on']('input',()=>{this['revisionNameInputValue']=_0x5d3c75['element']['value']['trim']();}),_0x135aa4);}}class l extends _0x4b71e4{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h];}['_saveRevisionFormView'];['init'](){const _0x25643c=this['editor'],_0x10b3d8=_0x25643c['plugins']['get']('RevisionTracker');_0x25643c['ui']['componentFactory']['add']('revisionHistory',_0x388072=>{const _0x21360f=_0x5925fb(_0x388072),_0x2a7ee3=_0x21360f['panelView']['children'],_0x551f0c=new _0x3a0269(_0x388072),_0xd8ddeb=new _0x574af4(_0x388072),_0xc8940d=this['_createSaveRevisionButton'](_0x235a06),_0xa200f1=new _0x574af4(_0x388072),_0x573d72=this['_createOpenRevisionButton'](_0x235a06);return _0x21360f['bind']('isEnabled')['to'](_0x10b3d8,'isReady',_0x10b3d8,'isEnabled',_0x25643c,'isReadOnly',(_0x110517,_0x225ce5,_0xf91f14)=>_0x110517&&_0x225ce5&&!_0xf91f14),_0x21360f['buttonView']['set']({'icon':_0x31711b,'label':m(_0x388072,'Revision\x20history'),'tooltip':!0x0}),_0xc8940d['set']({'withText':!0x0,'role':'menuitem'}),_0x573d72['set']({'withText':!0x0,'role':'menuitem'}),this['listenTo'](_0x573d72,'execute',()=>{_0x21360f['isOpen']=!0x1,_0x25643c['editing']['view']['focus']();},{'priority':'low'}),_0xd8ddeb['children']['add'](_0xc8940d),_0xa200f1['children']['add'](_0x573d72),_0x551f0c['role']='menu',_0x551f0c['items']['addMany']([_0xd8ddeb,_0xa200f1]),_0x2a7ee3['add'](_0x551f0c),_0x21360f;}),_0x25643c['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x2a04df=this['editor'],_0xa2d8ea=_0x2a04df['locale'],_0xe0a5d6=_0x2a04df['plugins']['get']('RevisionTracker'),_0x1c6997=new _0x59831c(_0xa2d8ea),_0x3dfafb=new _0x496b67(_0xa2d8ea);_0x1c6997['bind']('isEnabled')['to'](_0xe0a5d6,'isReady',_0xe0a5d6,'isEnabled',_0x2a04df,'isReadOnly',(_0x5f103d,_0x40d801,_0xcd6e6d)=>_0x5f103d&&_0x40d801&&!_0xcd6e6d),_0x1c6997['buttonView']['set']({'icon':_0x31711b,'label':m(_0xa2d8ea,'Revision\x20history')});const _0x413dff=new _0x1465f4(_0xa2d8ea,_0x1c6997),_0x5eef6c=this['_createSaveRevisionButton'](_0x59c301);_0x5eef6c['delegate']('execute')['to'](_0x1c6997),_0x413dff['children']['add'](_0x5eef6c),_0x3dfafb['items']['add'](_0x413dff);const _0x546c74=new _0x1465f4(_0xa2d8ea,_0x1c6997),_0x33a695=this['_createOpenRevisionButton'](_0x59c301);return _0x33a695['delegate']('execute')['to'](_0x1c6997),_0x546c74['children']['add'](_0x33a695),_0x3dfafb['items']['add'](_0x546c74),_0x1c6997['panelView']['children']['add'](_0x3dfafb),_0x1c6997;}['_createSaveRevisionButton'](_0x4cf793){const _0x5bb317=this['editor'],_0xf5da6a=_0x5bb317['plugins']['get']('RevisionTracker'),_0x5e8be5=new _0x4cf793(_0x5bb317['locale']);return _0x5e8be5['set']({'label':m(_0x5bb317['locale'],'Save\x20current\x20revision')}),_0x5e8be5['bind']('isEnabled')['to'](_0xf5da6a,'isReady',_0xf5da6a,'isEnabled',_0x5bb317,'isReadOnly',(_0x274cf1,_0x4647a0,_0x525369)=>_0x274cf1&&_0x4647a0&&!_0x525369),this['listenTo'](_0x5e8be5,'execute',()=>{this['_showDialog']();}),_0x5e8be5;}['_createOpenRevisionButton'](_0x3705f8){const _0x22e25c=this['editor'],_0x272962=_0x22e25c['plugins']['get']('RevisionTracker'),_0x51b9a8=new _0x3705f8(_0x22e25c['locale']);return _0x51b9a8['set']({'label':m(_0x22e25c['locale'],'Open\x20revision\x20history')}),_0x51b9a8['bind']('isEnabled')['to'](_0x272962,'isReady',_0x22e25c,'isReadOnly',(_0x2c57dc,_0x37db65)=>_0x2c57dc&&!_0x37db65),this['listenTo'](_0x51b9a8,'execute',()=>{_0x22e25c['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x51b9a8;}['_showDialog'](){const _0x16012b=this['editor'],_0x41516d=_0x16012b['locale'],_0xdfeaac=_0x16012b['plugins']['get']('Dialog'),_0x2d2475=_0x16012b['plugins']['get']('RevisionTracker');function _0x1e0d57(_0x421c6a){_0x16012b['config']['get']('revisionHistory.requireRevisionName')&&''===_0x421c6a['revisionName']?_0x421c6a['revisionNameInputView']['errorText']=m(_0x41516d,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x16012b['plugins']['get'](h)['saveRevision']({'name':_0x421c6a['revisionName']}),_0xdfeaac['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x1e0d57(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0xdfeaac['show']({'id':'revisionSave','title':m(_0x41516d,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':m(_0x16012b['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0xdfeaac['hide']()},{'label':m(_0x16012b['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x44c2f1){_0x44c2f1['bind']('isEnabled')['to'](_0x2d2475,'isReady',_0x2d2475,'isEnabled',_0x16012b,'isReadOnly',(_0x314033,_0x45bb32,_0x7fd947)=>_0x314033&&_0x45bb32&&!_0x7fd947);},'onExecute':()=>_0x1e0d57(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x5bbf42=this['editor'],_0x52b885=_0x5bbf42['locale'];this['_saveRevisionFormView']=new he(_0x52b885,_0x5bbf42['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class z extends _0x3ee578{['changeId'];['_model'];constructor(_0x16e3b0,_0x4f4a3b){super(_0x16e3b0),this['_model']=_0x4f4a3b,this['changeId']=_0x4f4a3b['id'];const _0x4755aa=this['bindTemplate'],_0x400d5b=m(_0x16e3b0,_0x4f4a3b['data']['isSuggestion']?'Suggested\x20by':'add'==_0x4f4a3b['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x4f4a3b['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x4755aa['to']('type',_0x1464d3=>'ck-revision-change__'+_0x1464d3)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x400d5b}]},{'text':'\x20'+_0x4f4a3b['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class G extends/* #__PURE__ -- @preserve */
26
- _0x55ca03(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x460cde){super(),this['id']=_0x460cde['id']||_0x118ae2(),this['author']=_0x460cde['author'],this['type']=_0x460cde['type'],this['data']=_0x460cde['data']||{},this['rootName']=_0x460cde['rootName'],this['set']('createdAt',_0x460cde['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(_0xdec2ee,_0x23b9ed){this['newRevisionId']=_0xdec2ee,this['oldRevisionId']=_0x23b9ed,this['changes']=new _0x4658e5();}['_setChanges'](_0xdc76d6){for(const _0x356595 of _0xdc76d6)this['changes']['add'](_0x356595);}}class u extends _0x4b71e4{['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[_0x3ecf8d,_0x3c59fb,S,$];}constructor(_0x4e84f7){super(_0x4e84f7),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',(_0x38eeee,_0x4ba487,_0x4555bb)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x3c1f4b=>{for(const _0x27c0df of this['editor']['editing']['view']['document']['roots'])_0x4555bb?_0x3c1f4b['removeClass']('ck-editor__editable__overlay',_0x27c0df):_0x3c1f4b['addClass']('ck-editor__editable__overlay',_0x27c0df);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x3627cf=>null!==_0x3627cf),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x3be9bc,_0x21b139,_0x459a9a)=>_0x3be9bc&&_0x459a9a?_0x21b139['changes']['getIndex'](_0x459a9a):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x5ad3e5,_0x47e07c)=>_0x5ad3e5?_0x47e07c['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0x3c59fb);}['init'](){const _0x4ed7a4=this['editor'],_0x2fecd1=new rt(_0x4ed7a4,{'direction':'backward'}),_0x48c036=new rt(_0x4ed7a4,{'direction':'forward'});(_0x4ed7a4['commands']['add']('showPreviousChange',_0x2fecd1),_0x4ed7a4['commands']['add']('showNextChange',_0x48c036),_0x4ed7a4['commands']['add']('restoreRevision',new nt(_0x4ed7a4)),this['on']('change:numberOfChanges',()=>{_0x2fecd1['refresh'](),_0x48c036['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x4ed7a4['enableReadOnlyMode']('revision-viewer'),_0x4ed7a4['plugins']['has']('WidgetToolbarRepository'))&&_0x4ed7a4['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0x3b4f1f){return await this['_utils']['loadRevisionData'](_0x3b4f1f,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x3b4f1f);}async['getRevisionRootsAttributes'](_0x29c856){return await this['_utils']['loadRevisionData'](_0x29c856,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x29c856);}async['compare'](_0x46dc6a,_0x50f813,_0x4eae03=!0x1){if(!this['isEnabled'])return;const _0x5f3408=this['diff'],_0x2861f8=this['repository'],_0x57ef45='string'==typeof _0x46dc6a?_0x2861f8['getRevision'](_0x46dc6a):_0x46dc6a,_0xd49ae5='string'==typeof _0x50f813?_0x2861f8['getRevision'](_0x50f813):_0x50f813,_0x40b791=_0x57ef45['id'],_0x37cead=_0xd49ae5?_0xd49ae5['id']:null;if(!_0x4eae03&&this['diff']&&this['diff']['newRevisionId']===_0x40b791&&this['diff']['oldRevisionId']===_0x37cead)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new J(_0x40b791,_0x37cead);const _0x5b1d68=this['_getRevisionsRange'](_0x57ef45,_0xd49ae5,!0x0)['map'](_0x2dc8d9=>this['_utils']['loadRevisionData'](_0x2dc8d9,this['adapter']));return _0x5b1d68['push'](new Promise(_0x28dfc1=>{setTimeout(_0x28dfc1,0x14);})),Promise['all'](_0x5b1d68)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x487ee9=this['_getDiff'](_0x40b791,_0x37cead);for(const _0x1e63c5 of _0x487ee9['changes'])this['_changeIdToChange']['set'](_0x1e63c5['id'],_0x1e63c5);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x42e596=>{for(const _0x531559 of this['editor']['model']['document']['getRootNames']())_0x42e596['detachRoot'](_0x531559);for(const _0x574902 of Object['keys'](_0x487ee9['model'])){const _0xdd84a2=_0x42e596['addRoot'](_0x574902);for(const _0x407242 of Object['keys'](_0x487ee9['attributes'][_0x574902]))_0x42e596['setAttribute'](_0x407242,_0x487ee9['attributes'][_0x574902][_0x407242],_0xdd84a2);_0x42e596['insert'](_0x487ee9['model'][_0x574902],_0xdd84a2,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x487ee9['changes'])),this['isReady']=!0x0;})['catch'](_0x4538a0=>{console['error'](_0x4538a0),this['_cleanUp'](),_0x5f3408&&(this['diff']=_0x5f3408),this['isReady']=!0x0;});}['addRevisionData'](_0xb05111,_0x18ef03){const _0x4a6400=this['repository']['createRevision'](_0xb05111);return _0x4a6400['on']('_update',(_0x1ac876,_0x7de02d,_0x31aa47)=>_0x18ef03(_0x7de02d,_0x31aa47,_0x4a6400)),this['repository']['addRevision'](_0x4a6400),_0x4a6400;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x3218fb=>{for(const _0x2f0e43 of this['editor']['model']['document']['getRootNames']())_0x3218fb['detachRoot'](_0x2f0e43);});}['_sortAndFilterDiffChanges'](_0x350720){const _0x1219f2=[],_0x59d26e=new Map();for(const _0x512ed5 of this['editor']['model']['document']['getRootNames']()){const _0x4370ff=this['editor']['editing']['view']['getDomRoot'](_0x512ed5);if(!_0x4370ff)continue;const _0x2c9f56=_0x4370ff['getClientRects']()['item'](0x0);_0x2c9f56&&(_0x1219f2['push'](_0x512ed5),_0x59d26e['set'](_0x512ed5,_0x2c9f56));}return _0x1219f2['sort']((_0x242a9e,_0x59f94d)=>{const _0x269c79=_0x59d26e['get'](_0x242a9e),_0x1fc895=_0x59d26e['get'](_0x59f94d);return _0x269c79['y']-_0x1fc895['y']||_0x269c79['x']-_0x1fc895['x'];}),(_0x350720=_0x350720['filter'](_0x30ee81=>_0x1219f2['includes'](_0x30ee81['rootName'])))['sort']((_0x4d9555,_0x3ecbbb)=>_0x1219f2['indexOf'](_0x4d9555['rootName'])-_0x1219f2['indexOf'](_0x3ecbbb['rootName'])),_0x350720;}['_makeTape'](_0x5f35a4){const _0x965b5c=Array['from'](_0x5f35a4['markers'])['filter'](([_0x5e26ed,_0x56b7ad])=>_0x5e26ed['startsWith']('revision:')&&!_0x56b7ad['isCollapsed']),_0x547065=Array['from'](this['editor']['model']['createRangeIn'](_0x5f35a4)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x965b5c['length'])for(const _0x16afa3 of _0x547065){const [_0x295aea,_0x4c6179]=_0x965b5c[0x0],[,_0x5d2b35,_0x357d8a]=_0x295aea['split'](':');if(_0x4c6179['end']['isEqual'](_0x16afa3['nextPosition'])&&_0x965b5c['shift'](),(_0x16afa3['previousPosition']['isEqual'](_0x4c6179['start'])||_0x16afa3['previousPosition']['isAfter'](_0x4c6179['start']))&&('insertion'==_0x5d2b35?_0x16afa3['isAdded']={'userId':_0x357d8a}:'deletion'==_0x5d2b35&&(_0x16afa3['isRemoved']={'userId':_0x357d8a})),0x0==_0x965b5c['length'])break;}return _0x547065;}['_refreshStartEndIndex'](_0x4a6137){const _0xbcbe29=new Map();for(let _0x3ee31b=0x0;_0x3ee31b<_0x4a6137['length'];_0x3ee31b++)'text'===_0x4a6137[_0x3ee31b]['type']?(_0x4a6137[_0x3ee31b]['item']['startIndex']=_0x3ee31b,_0x4a6137[_0x3ee31b]['item']['endIndex']=_0x3ee31b):('elementStart'===_0x4a6137[_0x3ee31b]['type']?_0x4a6137[_0x3ee31b]['item']['startIndex']=_0x3ee31b:'elementEnd'===_0x4a6137[_0x3ee31b]['type']&&(_0x4a6137[_0x3ee31b]['item']['endIndex']=_0x3ee31b),_0xbcbe29['set'](_0x4a6137[_0x3ee31b]['id'],_0x3ee31b));for(const _0x88e550 of _0xbcbe29['values']())'elementStart'===_0x4a6137[_0x88e550]['type']?_0x4a6137[_0x88e550]['item']['endIndex']=_0xbcbe29['get'](_0x4a6137[_0x88e550]['pairId']):'elementEnd'===_0x4a6137[_0x88e550]['type']&&(_0x4a6137[_0x88e550]['item']['startIndex']=_0xbcbe29['get'](_0x4a6137[_0x88e550]['pairId']));}['_processTape'](_0x44415f){for(let _0xfc2b99=0x0;_0xfc2b99<_0x44415f['length'];_0xfc2b99++){if('elementStart'===_0x44415f[_0xfc2b99]['type'])_0x44415f[_0xfc2b99]['item']['startIndex']=_0xfc2b99;else{if('elementEnd'===_0x44415f[_0xfc2b99]['type']){_0x44415f[_0xfc2b99]['item']['endIndex']=_0xfc2b99;const _0x442f90=_0x44415f[_0xfc2b99]['item']['startIndex'];_0x44415f[_0x442f90]['pairId']=_0x44415f[_0xfc2b99]['id'],_0x44415f[_0xfc2b99]['pairId']=_0x44415f[_0x442f90]['id'];}else _0x44415f[_0xfc2b99]['item']['startIndex']=_0xfc2b99,_0x44415f[_0xfc2b99]['item']['endIndex']=_0xfc2b99,_0x44415f[_0xfc2b99]['pairId']=null;}_0x44415f[_0xfc2b99]['markersStart']||(_0x44415f[_0xfc2b99]['markersStart']=[],_0x44415f[_0xfc2b99]['markersEnd']=[]);}}['_markInsertions'](_0x205e27,_0x2e3fc5){const _0xc80768=_0x205e27['filter'](_0x1beed0=>!_0x1beed0['isAdded']);for(let _0x54b594=0x0;_0x54b594<_0x2e3fc5['length'];_0x54b594++)_0x2e3fc5[_0x54b594]['isAdded']&&(_0xc80768[_0x54b594]['isAdded']=_0x2e3fc5[_0x54b594]['isAdded']);}['_getDiff'](_0x163b6b,_0x30a07f=null){const _0x9fe3f7=this['repository']['getRevision'](_0x163b6b),_0x23e144=_0x30a07f?this['repository']['getRevision'](_0x30a07f):null,_0x20569a=this['_getRevisionsRange'](_0x9fe3f7,_0x23e144),_0x3e744c=_0x20569a[_0x20569a['length']-0x1],_0x196c51=new Map(),_0x52e2b4={'model':{},'attributes':{},'changes':[]},_0x1c05ef=new Set(),_0x5e5ba1=new Map();for(let _0x27e957=_0x20569a['length']-0x1;_0x27e957>=0x0;_0x27e957--){const _0x31f82a=_0x20569a[_0x27e957];for(const _0x5f002d of Object['keys'](_0x31f82a['diffData']))if(_0x31f82a['diffData'][_0x5f002d]['attachChange']){const _0x306fc4=_0x31f82a['diffData'][_0x5f002d]['attachChange'];_0x306fc4['isAttached']?(_0x1c05ef['add'](_0x5f002d),_0x5e5ba1['has'](_0x5f002d)&&_0x5e5ba1['get'](_0x5f002d)['userId']==_0x306fc4['userId']?_0x5e5ba1['delete'](_0x5f002d):_0x5e5ba1['set'](_0x5f002d,_0x306fc4)):_0x5e5ba1['has'](_0x5f002d)?(_0x1c05ef['delete'](_0x5f002d),_0x5e5ba1['delete'](_0x5f002d)):(_0x1c05ef['add'](_0x5f002d),_0x5e5ba1['set'](_0x5f002d,_0x306fc4));}else _0x1c05ef['add'](_0x5f002d);}for(const _0x180ae1 of _0x1c05ef){const _0x581c91=_0x5e5ba1['has'](_0x180ae1)&&!_0x5e5ba1['get'](_0x180ae1)['isAttached'];let _0x5b1a93=_0x581c91?_0x20569a['length']-0x1:0x0;const _0x1434a0=_0x581c91?-0x1:0x1;for(;_0x20569a[_0x5b1a93];){const _0x19213c=_0x20569a[_0x5b1a93];if(_0x19213c['diffData'][_0x180ae1]){const _0x2cfa5e=_0x581c91?_0x19213c['diffData'][_0x180ae1]['attributesBefore']:_0x19213c['diffData'][_0x180ae1]['attributesAfter'];_0x52e2b4['attributes'][_0x180ae1]=_0x2cfa5e?_0x3f9059(_0x2cfa5e):{};break;}_0x5b1a93+=_0x1434a0;}}for(const _0x407845 of _0x20569a){_0x407845['model']={};for(const _0x485b58 of _0x407845['authors'])_0x196c51['set'](_0x485b58['id'],_0x485b58);for(const _0x1ce350 of _0x1c05ef){const _0x2f1aac=_0x407845['diffData'][_0x1ce350]?_0x407845['diffData'][_0x1ce350]['insertions']:'[]',_0x3df191=_0x407845['diffData'][_0x1ce350]?_0x407845['diffData'][_0x1ce350]['deletions']:'[]';_0x407845['model'][_0x1ce350]={'insertions':this['_utils']['_makeModelFromViewString'](_0x2f1aac),'deletions':this['_utils']['_makeModelFromViewString'](_0x3df191)};}}for(const _0x44ea0e of _0x1c05ef){let _0x246919=null,_0x3f9f89=0x0;const _0x38e106=new Map(Array['from'](_0x9fe3f7['model'][_0x44ea0e]['insertions']['markers'])['filter'](([_0x3a2c2c])=>!_0x3a2c2c['startsWith']('revision:')));let _0x2c9b87=0x0;for(const _0x5863d4 of _0x20569a){const _0x49b218=this['_makeTape'](_0x5863d4['model'][_0x44ea0e]['insertions']);_0x5863d4==_0x9fe3f7?(_0x246919=_0x49b218,_0x3f9f89=_0x246919['length'],_0x246919['forEach'](_0x2ba3cf=>{_0x2ba3cf['id']=_0x2c9b87++;}),this['_processTape'](_0x246919)):this['_markInsertions'](_0x246919,_0x49b218);const _0x10ac76=_0x246919['filter'](_0x9ca0d6=>!_0x9ca0d6['isAdded'])['map'](_0x4bc1a6=>_0x4bc1a6['id']);let _0x295fb1=0x0;const _0x3b4fa3=this['_makeTape'](_0x5863d4['model'][_0x44ea0e]['deletions']);_0x3b4fa3['forEach'](_0x13a43c=>{_0x13a43c['isRemoved']?_0x13a43c['id']=_0x3f9f89++:_0x13a43c['id']=_0x10ac76[_0x295fb1++];}),this['_processTape'](_0x3b4fa3),this['_setDistance'](_0x246919,'isAdded'),this['_setDistance'](_0x3b4fa3,'isRemoved'),_0x5863d4==_0x9fe3f7&&this['_markMarkers'](_0x246919,_0x38e106),_0x246919=this['_joinTapes'](_0x246919,_0x3b4fa3),this['_refreshStartEndIndex'](_0x246919),this['_setDistance'](_0x246919,'isRemoved');}_0x246919=_0x246919['filter'](_0x3e9184=>!(_0x3e9184['isAdded']&&_0x3e9184['isRemoved']));const _0x4e1ce2=new Map(_0x3e744c['model'][_0x44ea0e]['deletions']['markers']),_0x3cd2b2=new Set(_0x38e106['keys']());for(const _0x2d4554 of _0x4e1ce2['keys']())_0x3cd2b2['delete'](_0x2d4554);this['_markSuggestions'](_0x246919,_0x3cd2b2),this['_fixObsoleteTags'](_0x246919),_0x246919=this['_removeMissingPairs'](_0x246919),_0x246919=this['_markMismatchedRemovedTags'](_0x246919),_0x246919=this['_removeUnsupportedChanges'](_0x246919);const {root:_0x53232a,changes:_0x12604c}=this['_makeModelFromTape'](_0x246919,_0x196c51,_0x44ea0e);_0x52e2b4['model'][_0x44ea0e]=_0x53232a;const _0xce7f50=_0x5e5ba1['get'](_0x44ea0e);if(_0xce7f50){const _0x10a20f=_0x196c51['get'](_0xce7f50['userId']),_0x30ccd2=new G({'author':_0x10a20f,'type':_0xce7f50['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x44ea0e});_0x12604c['unshift'](_0x30ccd2),_0x52e2b4['attributes'][_0x44ea0e]['revisionHistoryAttachChange']=_0x30ccd2['id'];}_0x52e2b4['changes']=_0x52e2b4['changes']['concat'](_0x12604c);}return _0x52e2b4;}['_markMarkers'](_0x408b1b,_0x296686){for(let _0x2a4394=0x0;_0x2a4394<_0x408b1b['length'];_0x2a4394++)for(const [_0x124bd5,_0x4733ca]of _0x296686)!_0x4733ca['isCollapsed']&&_0x4733ca['start']['isEqual'](_0x408b1b[_0x2a4394]['previousPosition'])&&_0x408b1b[_0x2a4394]['markersStart']['push'](_0x124bd5),_0x4733ca['end']['isEqual'](_0x408b1b[_0x2a4394]['nextPosition'])&&_0x408b1b[_0x2a4394]['markersEnd']['push'](_0x124bd5);}['_joinTapes'](_0x17cc5f,_0x1f7e88){let _0x354bf1=[],_0x1f5f6c=0x0,_0x3b9568=0x0;for(;_0x1f5f6c<_0x17cc5f['length']||_0x3b9568<_0x1f7e88['length'];){const _0xeb4c4d=_0x17cc5f[_0x1f5f6c]||{},_0xc1dbb2=_0x1f7e88[_0x3b9568]||{};if(_0xeb4c4d['id']==_0xc1dbb2['id'])_0x1f5f6c++,_0x3b9568++,_0x354bf1['push'](_0xeb4c4d);else{if(_0xc1dbb2['isRemoved']&&_0xeb4c4d['isAdded']){const {commonTape:_0x561b7b,iEnd:_0x5dfeb8,jEnd:_0x470f9a}=this['_threeWayMerge'](_0x17cc5f,_0x1f5f6c,_0x1f7e88,_0x3b9568);_0x354bf1=_0x354bf1['concat'](_0x561b7b),_0x1f5f6c=_0x5dfeb8,_0x3b9568=_0x470f9a;}else _0xc1dbb2['isRemoved']?(_0x3b9568++,_0x354bf1['push'](_0xc1dbb2)):(_0x1f5f6c++,_0x354bf1['push'](_0xeb4c4d));}}return _0x354bf1;}['_markSuggestions'](_0x2db00a,_0x374f70){const _0x2994cb=[];for(let _0xfdc6c1=0x0;_0xfdc6c1<_0x2db00a['length'];_0xfdc6c1++){for(let _0x3a63bb=0x0;_0x3a63bb<_0x2db00a[_0xfdc6c1]['markersStart']['length'];_0x3a63bb++){const _0x286c58=_0x2db00a[_0xfdc6c1]['markersStart'][_0x3a63bb];if(!_0x374f70['has'](_0x286c58))continue;const {group:_0x342148,type:_0x503913,authorId:_0xa0b451}=_0x36d2c1(_0x286c58);'revision-suggestion'!=_0x342148||'insertion'!=_0x503913&&'deletion'!=_0x503913||(_0x2994cb['unshift']({'type':_0x503913,'name':_0x286c58,'userId':_0xa0b451}),_0x2db00a[_0xfdc6c1]['markersStart']['splice'](_0x3a63bb,0x1),_0x3a63bb--);}_0x5bd564(_0x2db00a[_0xfdc6c1]);for(let _0x11a13c=0x0;_0x11a13c<_0x2db00a[_0xfdc6c1]['markersEnd']['length'];_0x11a13c++){const _0x2b66fb=_0x2db00a[_0xfdc6c1]['markersEnd'][_0x11a13c];if(!_0x374f70['has'](_0x2b66fb))continue;const {group:_0x107dc7,type:_0x3d1d8c}=_0x36d2c1(_0x2b66fb);if('revision-suggestion'!=_0x107dc7||'insertion'!=_0x3d1d8c&&'deletion'!=_0x3d1d8c)continue;_0x2db00a[_0xfdc6c1]['markersEnd']['splice'](_0x11a13c,0x1),_0x11a13c--;const _0x79bac5=_0x2994cb['findIndex'](_0x4d17ff=>_0x4d17ff['name']==_0x2b66fb);_0x79bac5>-0x1&&_0x2994cb['splice'](_0x79bac5,0x1);}}function _0x36d2c1(_0x5aea27){const _0x111595=_0x5aea27['split'](':');return{'group':_0x111595[0x0],'type':_0x111595[0x1],'subType':_0x111595['length']>=0x5?_0x111595[0x2]:null,'id':_0x111595['length']<0x5?_0x111595[0x2]:_0x111595[0x3],'authorId':_0x111595['length']<0x5?_0x111595[0x3]:_0x111595[0x4],'markerCount':0x6==_0x111595['length']?_0x111595[0x5]:null};}function _0x5bd564(_0x4d06af){for(let _0x5bbcf3=0x0;_0x5bbcf3<_0x2994cb['length'];_0x5bbcf3++){if(_0x4d06af['isAdded']&&'insertion'==_0x2994cb[_0x5bbcf3]['type']&&_0x4d06af['isAdded']['userId']==_0x2994cb[_0x5bbcf3]['userId'])return _0x4d06af['isAddSuggestion']=_0x2994cb[_0x5bbcf3],void delete _0x4d06af['isAdded'];if(!_0x4d06af['isAdded']&&!_0x4d06af['isRemoved']&&'deletion'==_0x2994cb[_0x5bbcf3]['type'])return void(_0x4d06af['isRemoveSuggestion']=_0x2994cb[_0x5bbcf3]);}}}['_setDistance'](_0xa27f10,_0x1f3b7c){let _0x253998=0x0,_0x463965=!0x1;const _0x222828=new Map();for(const _0x39bf81 of _0xa27f10)_0x39bf81[_0x1f3b7c]?_0x463965&&(_0x253998++,_0x463965=!0x1):(_0x253998++,_0x463965=!0x0),_0x222828['set'](_0x39bf81['id'],_0x253998);for(let _0x1e9dbc=0x0;_0x1e9dbc<_0xa27f10['length'];_0x1e9dbc++){if('isRemoved'==_0x1f3b7c&&_0xa27f10[_0x1e9dbc]['isAdded']||'isAdded'==_0x1f3b7c&&_0xa27f10[_0x1e9dbc]['isRemoved'])continue;if('text'==_0xa27f10[_0x1e9dbc]['type']){_0xa27f10[_0x1e9dbc]['distance']=0x0;continue;}const _0x32cba4=_0x222828['get'](_0xa27f10[_0x1e9dbc]['pairId']),_0x22cc57=_0x222828['get'](_0xa27f10[_0x1e9dbc]['id']);_0xa27f10[_0x1e9dbc]['distance']=_0x32cba4-_0x22cc57;}}['_getRevisionsRange'](_0x5dc7cd,_0x35a747,_0x55e018=!0x1){const _0x5dfde5=[];let _0x593c0c=this['repository']['getIndex'](_0x5dc7cd),_0x57340e=this['repository']['getIndex'](_0x35a747);for(-0x1==_0x57340e&&(_0x57340e=this['repository']['_revisions']['length'],_0x55e018=!0x1);_0x593c0c<_0x57340e;)_0x5dfde5['push'](this['repository']['getRevision'](_0x593c0c)),_0x593c0c++;return _0x55e018&&_0x5dfde5['push'](this['repository']['getRevision'](_0x593c0c)),_0x5dfde5;}['_threeWayMerge'](_0x553307,_0xf01910,_0x37c298,_0x17fbd4){const _0x4839c0=this['editor']['model']['schema'];let _0x46a728=_0xf01910;for(;_0x553307[_0x46a728]&&_0x553307[_0x46a728]['isAdded'];)_0x46a728++;let _0x39914b=_0x17fbd4;for(;_0x37c298[_0x39914b]&&_0x37c298[_0x39914b]['isRemoved'];)_0x39914b++;_0x5ae8e3(_0x553307,_0xf01910,_0x46a728),_0x5ae8e3(_0x37c298,_0x17fbd4,_0x39914b);const _0x25dae6=_0x37c298['slice'](_0x17fbd4,_0x39914b)['concat'](_0x553307['slice'](_0xf01910,_0x46a728));return _0x25dae6['sort']((_0x4a0e61,_0x3342f4)=>_0x4a0e61['side']!=_0x3342f4['side']?_0x4a0e61['side']-_0x3342f4['side']:_0x4a0e61['level']!=_0x3342f4['level']?_0x4a0e61['level']-_0x3342f4['level']:_0x4a0e61['distance']!=_0x3342f4['distance']?_0x3342f4['distance']-_0x4a0e61['distance']:!!_0x4a0e61['isAdded']!=!!_0x3342f4['isAdded']?-0x1==_0x4a0e61['side']||0x0==_0x4a0e61['side']?_0x4a0e61['isAdded']?-0x1:0x1:_0x4a0e61['isAdded']?0x1:-0x1:_0x4a0e61['index']-_0x3342f4['index']),{'commonTape':_0x25dae6,'iEnd':_0x46a728,'jEnd':_0x39914b};function _0x5ae8e3(_0x315db0,_0x3cc417,_0x500bcd){let _0x5a22d0=-0x1,_0x41ea51=Number['POSITIVE_INFINITY'],_0x3fe1b2=!0x0;for(let _0x1eb5a0=_0x3cc417;_0x1eb5a0<_0x500bcd;_0x1eb5a0++)if(_0x4839c0['isInline'](_0x315db0[_0x1eb5a0]['item'])||(_0x3fe1b2=!0x1),_0x315db0[_0x1eb5a0]['item']['startIndex']<_0x3cc417&&(_0x5a22d0=_0x1eb5a0),_0x315db0[_0x1eb5a0]['item']['endIndex']>=_0x500bcd){_0x41ea51=_0x1eb5a0;break;}_0x3fe1b2&&(_0x5a22d0=_0x500bcd-0x1);for(let _0x413717=_0x3cc417;_0x413717<_0x500bcd;_0x413717++)_0x315db0[_0x413717]['side']=_0x413717<=_0x5a22d0?-0x1:_0x413717<_0x41ea51?0x0:0x1,_0x315db0[_0x413717]['index']=_0x413717;let _0x2de248=0x0;for(let _0x4324a7=_0x3cc417;_0x4324a7<=_0x5a22d0;_0x4324a7++)0x0==_0x315db0[_0x4324a7]['distance']?_0x315db0[_0x4324a7]['level']=_0x2de248:(_0x2de248++,_0x315db0[_0x4324a7]['level']=_0x2de248,_0x2de248++);for(let _0x29803d=_0x3cc417;_0x29803d<_0x500bcd;_0x29803d++)0x0==_0x315db0[_0x29803d]['side']&&(_0x315db0[_0x29803d]['level']=_0x2de248);_0x2de248=0x0;for(let _0x41fd1b=_0x500bcd-0x1;_0x41fd1b>=_0x41ea51;_0x41fd1b--)0x0==_0x315db0[_0x41fd1b]['distance']?_0x315db0[_0x41fd1b]['level']=_0x2de248:(_0x2de248--,_0x315db0[_0x41fd1b]['level']=_0x2de248,_0x2de248--);}}['_fixObsoleteTags'](_0x2262a1){const _0x5e5bc3=new Map(),_0x3e5704=this['editor']['model']['schema'];for(let _0x221ecc=0x1;_0x221ecc<_0x2262a1['length'];_0x221ecc++){let _0x4a14a6,_0x55e091,_0x23e3ab;const _0xdd290b=_0x2262a1[_0x221ecc],_0x33f4ab=_0x2262a1[_0x221ecc-0x1];if('text'==_0xdd290b['type'])continue;if(_0xdd290b['type']!=_0x33f4ab['type'])continue;if(!_0x3e5704['isBlock'](_0x33f4ab['item'])||_0x3e5704['isLimit'](_0x33f4ab['item']))continue;if(!_0x3e5704['isBlock'](_0xdd290b['item'])||_0x3e5704['isLimit'](_0xdd290b['item']))continue;if((_0x2262a1[_0x221ecc]['isAdded']||_0x2262a1[_0x221ecc]['isAddSuggestion'])&&_0x2262a1[_0x221ecc-0x1]['isRemoved'])_0x4a14a6=_0x2262a1[_0x221ecc],_0x55e091=_0x2262a1[_0x221ecc-0x1],_0x23e3ab=_0x221ecc-0x1;else{if(!_0x2262a1[_0x221ecc]['isRemoved']||!_0x2262a1[_0x221ecc-0x1]['isAdded']&&!_0x2262a1[_0x221ecc-0x1]['isAddSuggestion'])continue;_0x4a14a6=_0x2262a1[_0x221ecc-0x1],_0x55e091=_0x2262a1[_0x221ecc],_0x23e3ab=_0x221ecc;}const _0x27d14d=_0x4a14a6['level']==_0x55e091['level'],_0xf2a99e=Math['abs'](_0x4a14a6['level'])<Math['abs'](_0x55e091['level'])&&0x0==_0x55e091['distance'];(_0x27d14d||_0xf2a99e)&&(_0x5e5bc3['set'](_0x55e091['id'],_0x4a14a6['id']),_0x2262a1['splice'](_0x23e3ab,0x1),_0x221ecc--,_0x4a14a6['isAdded']=!0x1);}for(let _0x4f1db6=0x0;_0x4f1db6<_0x2262a1['length'];_0x4f1db6++)_0x5e5bc3['has'](_0x2262a1[_0x4f1db6]['pairId'])&&(_0x2262a1[_0x4f1db6]['pairId']=_0x5e5bc3['get'](_0x2262a1[_0x4f1db6]['pairId']));}['_removeMissingPairs'](_0x3a1e00){const _0x2e2612=new Set(_0x3a1e00['map'](_0x3f62fd=>_0x3f62fd['id']));for(let _0x240463=0x0;_0x240463<_0x3a1e00['length'];_0x240463++)_0x2e2612['has'](_0x3a1e00[_0x240463]['pairId'])||0x0==_0x3a1e00[_0x240463]['distance']||(_0x3a1e00[_0x240463]['isIncorrect']=!0x0);return _0x3a1e00['filter'](_0x380d0b=>!_0x380d0b['isIncorrect']);}['_markMismatchedRemovedTags'](_0x2d00ff){const _0x214800=new Set();for(let _0x539ec6=0x0;_0x539ec6<_0x2d00ff['length'];_0x539ec6++){if(_0x214800['has'](_0x2d00ff[_0x539ec6]['id'])&&_0x2d00ff[_0x539ec6]['isRemoved']&&(_0x2d00ff[_0x539ec6]['isIncorrect']=!0x0),_0x2d00ff[_0x539ec6]['isIncorrect'])continue;if(0x0==_0x2d00ff[_0x539ec6]['distance'])continue;if('elementStart'!=_0x2d00ff[_0x539ec6]['type'])continue;if(null==_0x2d00ff[_0x539ec6]['pairId'])continue;let _0x2f0e4a=_0x539ec6+0x1,_0x369486=0x0;for(;_0x2d00ff[_0x2f0e4a]['id']!=_0x2d00ff[_0x539ec6]['pairId'];)'elementStart'==_0x2d00ff[_0x2f0e4a]['type']?_0x369486++:'elementEnd'==_0x2d00ff[_0x2f0e4a]['type']&&_0x369486--,_0x2f0e4a++;if(0x0!=_0x369486){if(_0x2d00ff[_0x539ec6]['isRemoved'])_0x2d00ff[_0x539ec6]['isIncorrect']=!0x0;else{for(;_0x2f0e4a!=_0x539ec6;)_0x2d00ff[_0x2f0e4a]['isRemoved']&&0x0!=_0x2d00ff[_0x2f0e4a]['distance']&&(_0x2d00ff[_0x2f0e4a]['isIncorrect']=!0x0,_0x214800['add'](_0x2d00ff[_0x2f0e4a]['pairId'])),_0x2f0e4a--;}}}return _0x2d00ff['filter'](_0x4916b3=>!_0x4916b3['isIncorrect']);}['_removeUnsupportedChanges'](_0x327313){const _0x3ab173=this['editor']['model']['schema'];for(let _0x2b167f=0x0;_0x2b167f<_0x327313['length'];_0x2b167f++){if(!(_0x327313[_0x2b167f]['isAdded']||_0x327313[_0x2b167f]['isAddSuggestion']||_0x327313[_0x2b167f]['isRemoved']||_0x327313[_0x2b167f]['isRemoveSuggestion']))continue;if(0x0==_0x327313[_0x2b167f]['distance'])continue;const _0x1505d5=_0x327313[_0x2b167f]['item'];_0x3ab173['isBlock'](_0x1505d5)||_0x3ab173['isLimit'](_0x1505d5)||(_0x327313[_0x2b167f]['isAdded']&&delete _0x327313[_0x2b167f]['isAdded'],_0x327313[_0x2b167f]['isAddSuggestion']&&delete _0x327313[_0x2b167f]['isAddSuggestion'],_0x327313[_0x2b167f]['isRemoveSuggestion']&&delete _0x327313[_0x2b167f]['isRemoveSuggestion'],_0x327313[_0x2b167f]['isRemoved']&&(_0x327313[_0x2b167f]['isIncorrect']=!0x0));}return _0x327313['filter'](_0x2295f0=>!_0x2295f0['isIncorrect']);}['_makeModelFromTape'](_0xda4198,_0x5674cf,_0x527bd9){const _0x3e306f=new _0x3b75f6(),_0x52594b=[],_0x5e4729=new Map(),_0x35c7fc=this['editor']['model'],_0x410605=_0x35c7fc['schema'],_0x122dd5=[_0x3e306f],_0x1c005d={},_0x3d2ed7={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x1cf03c=null;const _0x1f2c6d=[0x0];for(let _0x59827b=0x0;_0x59827b<_0xda4198['length'];_0x59827b++)if('elementStart'===_0xda4198[_0x59827b]['type']){_0xda4198[_0x59827b]['previousPosition']=_0x35c7fc['createPositionFromPath'](_0x3e306f,_0x1f2c6d);const _0x3526dd=new _0x10b403(_0xda4198[_0x59827b]['item']['name'],_0xda4198[_0x59827b]['item']['getAttributes']());_0x122dd5[0x0]['_appendChild'](_0x3526dd),_0x1f2c6d['push'](0x0),_0x122dd5['unshift'](_0x3526dd),_0xda4198[_0x59827b]['nextPosition']=_0x35c7fc['createPositionFromPath'](_0x3e306f,_0x1f2c6d);}else'elementEnd'===_0xda4198[_0x59827b]['type']?(_0x122dd5['shift'](),_0xda4198[_0x59827b]['previousPosition']=_0x35c7fc['createPositionFromPath'](_0x3e306f,_0x1f2c6d),_0x1f2c6d['pop'](),_0x1f2c6d[_0x1f2c6d['length']-0x1]++,_0xda4198[_0x59827b]['nextPosition']=_0x35c7fc['createPositionFromPath'](_0x3e306f,_0x1f2c6d)):(_0xda4198[_0x59827b]['previousPosition']=_0x35c7fc['createPositionFromPath'](_0x3e306f,_0x1f2c6d),_0x1cf03c?_0x1cf03c['_data']+=_0xda4198[_0x59827b]['item']['data']:_0x1cf03c=new _0x5eda90(_0xda4198[_0x59827b]['item']['data'],_0xda4198[_0x59827b]['item']['getAttributes']()),_0xda4198[_0x59827b+0x1]&&'text'===_0xda4198[_0x59827b+0x1]['type']&&_0x56c64d(_0x1cf03c,_0xda4198[_0x59827b+0x1]['item'])||(_0x122dd5[0x0]['_appendChild'](_0x1cf03c),_0x1cf03c=null),_0x1f2c6d[_0x1f2c6d['length']-0x1]+=_0xda4198[_0x59827b]['item']['offsetSize'],_0xda4198[_0x59827b]['nextPosition']=_0x35c7fc['createPositionFromPath'](_0x3e306f,_0x1f2c6d));for(let _0x58d6ef=0x0;_0x58d6ef<_0xda4198['length'];_0x58d6ef++){const _0x1276ae=_0xda4198[_0x58d6ef]['previousPosition'],_0x8c5a27=_0xda4198[_0x58d6ef]['nextPosition'];for(const _0x1a63e6 of _0xda4198[_0x58d6ef]['markersStart'])_0x5e4729['set'](_0x1a63e6,{'start':_0x1276ae,'end':null});_0x2a7f80('isRemoveSuggestion',_0x58d6ef,_0x1276ae,_0x8c5a27),_0x2a7f80('isAddSuggestion',_0x58d6ef,_0x1276ae,_0x8c5a27),_0x2a7f80('isRemoved',_0x58d6ef,_0x1276ae,_0x8c5a27),_0x2a7f80('isAdded',_0x58d6ef,_0x1276ae,_0x8c5a27);for(const _0x3424d3 of _0xda4198[_0x58d6ef]['markersEnd']){const _0x277f54=_0x5e4729['get'](_0x3424d3);_0x277f54?_0x277f54['end']=_0x8c5a27:_0x5e4729['set'](_0x3424d3,{'start':_0x8c5a27,'end':_0x8c5a27});}}for(const [_0xc19eec,_0x244042]of _0x5e4729){const _0x375271=this['editor']['model']['createRange'](_0x244042['start'],_0x244042['end']);_0x3e306f['markers']['set'](_0xc19eec,_0x375271);}return _0x52594b['sort']((_0x57b24a,_0x24bf74)=>{const _0xa3b0d1=_0x3e306f['markers']['get']('revision:'+_0x57b24a['id']),_0x3da44c=_0x3e306f['markers']['get']('revision:'+_0x24bf74['id']);return _0xa3b0d1['start']['isBefore'](_0x3da44c['start'])?-0x1:_0xa3b0d1['start']['isAfter'](_0x3da44c['start'])?0x1:_0xa3b0d1['end']['isBefore'](_0x3da44c['end'])?-0x1:_0xa3b0d1['end']['isAfter'](_0x3da44c['end'])?0x1:'add'===_0x57b24a['type']?-0x1:0x1;}),{'root':_0x3e306f,'changes':_0x52594b};function _0x2a7f80(_0x318b74,_0x512016,_0x3d4344,_0x147584){const _0x1bac69=!!_0xda4198[_0x512016][_0x318b74],_0x4711c9=_0x1bac69?_0xda4198[_0x512016][_0x318b74]['userId']:null,_0x719cfc=_0x512016===_0xda4198['length']-0x1,_0x121288=_0x3d2ed7[_0x318b74][0x0],_0x4e810b=_0x410605['isObject'](_0xda4198[_0x512016]['item']);!_0x1c005d[_0x318b74]&&_0x1bac69?_0x1c005d[_0x318b74]={'start':_0x3d4344,'tapeItem':_0xda4198[_0x512016],'userId':_0x4711c9,'type':_0x318b74}:_0x1c005d[_0x318b74]&&!_0x1bac69?(_0x1c005d[_0x318b74]['end']=_0x3d4344,_0x2a64cd(_0x1c005d[_0x318b74]),_0x1c005d[_0x318b74]=null):_0x1c005d[_0x318b74]&&_0x1bac69&&_0x1c005d[_0x318b74]['userId']!==_0x4711c9&&(_0x1c005d[_0x318b74]['end']=_0x3d4344,_0x121288&&_0x121288['userId']===_0x1c005d[_0x318b74]['userId']||_0x2a64cd(_0x1c005d[_0x318b74]),_0x1c005d[_0x318b74]={'start':_0x3d4344,'tapeItem':_0xda4198[_0x512016],'userId':_0x4711c9,'type':_0x318b74}),_0x1c005d[_0x318b74]&&_0x4e810b&&('elementStart'!==_0xda4198[_0x512016]['type']||_0x121288&&_0x121288['userId']===_0x4711c9||_0x3d2ed7[_0x318b74]['unshift']({'userId':_0x4711c9,'object':_0xda4198[_0x512016]['item'],'change':_0x1c005d[_0x318b74]}),'elementEnd'===_0xda4198[_0x512016]['type']&&_0x121288&&_0x121288['object']===_0xda4198[_0x512016]['item']&&(_0x3d2ed7[_0x318b74]['shift'](),_0x1c005d[_0x318b74]=_0x121288['change'])),_0x1c005d[_0x318b74]&&_0x719cfc&&(_0x1c005d[_0x318b74]['end']=_0x147584,_0x2a64cd(_0x1c005d[_0x318b74]),_0x1c005d[_0x318b74]=null);}function _0x2a64cd({start:_0x5f3120,end:_0x26e420,tapeItem:_0x570d4b,userId:_0x3715b5,type:_0x50cac0}){const _0x4558ab=_0x570d4b['item'],_0x82825d=_0x35c7fc['schema']['isBlock'](_0x4558ab)&&!_0x35c7fc['schema']['isLimit'](_0x4558ab),_0x29d4eb=_0x5f3120['nodeAfter']==_0x26e420['parent']&&_0x26e420['isAtStart'];if(_0x82825d&&_0x29d4eb)return;const _0x194b76=_0x35c7fc['createRange'](_0x5f3120,_0x26e420),_0x8803d=_0x5674cf['get'](_0x3715b5),_0x3d795e=new G({'author':_0x8803d,'type':'isAdded'==_0x50cac0||'isAddSuggestion'==_0x50cac0?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x50cac0||'isRemoveSuggestion'==_0x50cac0},'createdAt':new Date(),'rootName':_0x527bd9});_0x52594b['push'](_0x3d795e),_0x3e306f['markers']['set']('revision:'+_0x3d795e['id'],_0x194b76);}function _0x56c64d(_0x320968,_0x49840e){const _0x35e493=_0x320968['getAttributes'](),_0x4070ea=_0x49840e['getAttributes']();for(const _0x267286 of _0x35e493){if(_0x267286[0x1]!==_0x49840e['getAttribute'](_0x267286[0x0]))return!0x1;_0x4070ea['next']();}return _0x4070ea['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x349d84=>{const _0x2b26a3=_0x349d84['markerName']['split'](':')[0x1],_0x158ae5=this['_getChangeFromId'](_0x2b26a3);if(!_0x158ae5)return null;const _0x2fe797='add'==_0x158ae5['type']?'insertion':'deletion',_0x534f3d=['ck-suggestion-marker','ck-suggestion-marker-'+_0x2fe797];return _0x158ae5['data']['isSuggestion']&&_0x534f3d['push']('ck-suggestion-marker-'+_0x2fe797+'-new'),this['activeChange']==_0x158ae5&&_0x534f3d['push']('ck-suggestion-marker--active'),{'classes':_0x534f3d,'attributes':{'data-change-id':_0x2b26a3}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x456919=>{_0x456919['on']('element:pre',(_0x35bced,_0x578443,_0x17e402)=>{const _0x335176=_0x578443['viewItem']['getChild'](0x0);if(!_0x335176||!_0x335176['is']('element','code'))return;if(!_0x17e402['consumable']['consume'](_0x335176,{'attributes':['vid_start','vid_end']}))return;const _0x5829dd=_0x578443['modelRange']['start']['nodeAfter'];_0x17e402['writer']['setAttribute']('vid_start',_0x335176['getAttribute']('vid_start'),_0x5829dd),_0x17e402['writer']['setAttribute']('vid_end',_0x335176['getAttribute']('vid_end'),_0x5829dd);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0xa5d28c=>{_0xa5d28c['on']('element',(_0x506be4,_0x91292b,_0xbdfb9a)=>{if(!_0xbdfb9a['consumable']['consume'](_0x91292b['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x91292b['modelRange']['isCollapsed'])return;const _0x47f903=_0x91292b['modelRange']['start']['nodeAfter'];_0x47f903['hasAttribute']('vid_start')||_0x47f903['hasAttribute']('vid')||(_0xbdfb9a['writer']['setAttribute']('vid_start',_0x91292b['viewItem']['getAttribute']('vid_start'),_0x47f903),_0xbdfb9a['writer']['setAttribute']('vid_end',_0x91292b['viewItem']['getAttribute']('vid_end'),_0x47f903));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x1f5b50=>_0x1f5b50['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x1e726a,[,_0x1dd57b])=>{['vid_start','vid_end','vid']['includes'](_0x1dd57b)&&(_0x1e726a['return']=!0x0,_0x1e726a['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x1b6210=>{_0x1b6210['on']('attribute:vid',(_0x4a6539,_0x378529,_0x5eeedb)=>{if('\x20'!=_0x378529['item']['data']||_0x378529['item']['parent']['maxOffset']>0x1)return;if(!_0x5eeedb['consumable']['consume'](_0x378529['item'],_0x4a6539['name']))return;const _0x338790=_0x5eeedb['writer'],_0x4fa9bb=_0x5eeedb['mapper']['toViewRange'](_0x378529['range']);_0x338790['wrap'](_0x4fa9bb,_0x338790['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x5e86a2){const _0x5f62fa=_0x5e86a2['plugins']['get']('RevisionViewer');return(_0x3f8a45,_0x28560b,_0x2e71ad)=>{const _0x3e3cc5=_0x28560b['markerName']['split'](':')[0x1],_0x345680=_0x5f62fa['_getChangeFromId'](_0x3e3cc5);if(!_0x345680)return null;const _0x55c9fd='add'==_0x345680['type']?'split':'merge';if(!_0x2e71ad['consumable']['test'](_0x28560b['markerRange'],_0x3f8a45['name']))return;const _0x2d88ad=_0x28560b['markerRange']['getWalker'](),_0xcf638=_0x28560b['markerRange']['start'],_0x539572=_0x5e86a2['model']['schema'];let _0x3e05de=null,_0x33be4c=null,_0x4b5913=!0x1,_0x7945d7=!0x1;for(const _0x1054bf of _0x2d88ad){const _0x3b600c=_0x1054bf['item'];_0x4b5913=_0x4b5913||_0x539572['isContent'](_0x3b600c);const _0x2262d7=_0x2e71ad['mapper']['toViewElement'](_0x3b600c);if(_0x2262d7&&_0x2262d7['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x1054bf['type']&&(_0x539572['isBlock'](_0x3b600c)&&!_0x539572['isLimit'](_0x3b600c)&&(_0x3b600c['nextSibling']||_0xcf638['isAtEnd']?_0x3e05de&&_0x3e05de['parent']==_0x3b600c||(_0x3e05de=_0x3b600c,_0x53d890(_0x1054bf['previousPosition']),_0x7945d7=!0x0):_0x33be4c=_0x33be4c||_0x1054bf['previousPosition']));}function _0x53d890(_0xdfe485){const _0x4f9e3f=_0x2e71ad['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x55c9fd}),_0x33f8f8=_0x2e71ad['mapper']['toViewPosition'](_0xdfe485);_0x345680['data']['isSuggestion']&&_0x2e71ad['writer']['addClass']('ck-suggestion-marker-'+_0x55c9fd+'-new',_0x4f9e3f),_0x5f62fa['activeChange']==_0x345680&&_0x2e71ad['writer']['addClass']('ck-suggestion-marker--active',_0x4f9e3f),_0x2e71ad['writer']['insert'](_0x33f8f8,_0x4f9e3f),_0x2e71ad['mapper']['bindElementToMarker'](_0x4f9e3f,_0x28560b['markerName']);}_0x4b5913||_0x7945d7||!_0x33be4c||_0x53d890(_0x33be4c);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x20a859,_0x30632b,_0x107d61)=>{const _0x3fe3d3=_0x107d61['mapper']['markerNameToElements'](_0x30632b['markerName']);if(_0x3fe3d3){for(const _0x12729f of _0x3fe3d3)(_0x12729f['hasClass']('ck-suggestion-marker-split')||_0x12729f['hasClass']('ck-suggestion-marker-merge'))&&(_0x107d61['mapper']['unbindElementFromMarkerName'](_0x12729f,_0x30632b['markerName']),_0x107d61['writer']['remove'](_0x12729f));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x5d3fa5,_0x447ef0,_0x5f2ac1)=>{const _0x26528c=_0x447ef0['markerName']['split'](':')[0x1],_0x290b33=this['_getChangeFromId'](_0x26528c);if(!_0x290b33)return null;const _0x1725a5='add'==_0x290b33['type']?'split':'merge';if(_0x5f2ac1['consumable']['test'](_0x447ef0['markerRange'],_0x5d3fa5['name']))for(const _0x4923fa of _0x447ef0['markerRange']['getItems']()){if(!_0x4923fa['is']('element','softBreak'))continue;const _0x109fd8=_0x5f2ac1['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x1725a5}),_0x1d8c14=_0x5f2ac1['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x4923fa));_0x290b33['data']['isSuggestion']&&_0x5f2ac1['writer']['addClass']('ck-suggestion-marker-'+_0x1725a5+'-new',_0x109fd8),this['activeChange']==_0x290b33&&_0x5f2ac1['writer']['addClass']('ck-suggestion-marker--active',_0x109fd8),_0x5f2ac1['writer']['insert'](_0x1d8c14,_0x109fd8),_0x5f2ac1['mapper']['bindElementToMarker'](_0x109fd8,_0x447ef0['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x319816=>{for(const _0xf49f1b of this['editor']['model']['document']['getRootNames']()){const _0x449cbf=this['editor']['model']['document']['getRoot'](_0xf49f1b),_0x1583c8=this['editor']['editing']['view']['document']['getRoot'](_0xf49f1b);if(_0x1583c8){const _0x149768=_0x449cbf['getAttribute']('revisionHistoryAttachChange');if(_0x319816['removeAttribute']('data-change-id',_0x1583c8),_0x319816['removeClass']('ck-revision-history-root-add',_0x1583c8),_0x319816['removeClass']('ck-revision-history-root-remove',_0x1583c8),_0x319816['removeClass']('ck-revision-history-root--active',_0x1583c8),_0x149768){const _0x212477=this['_getChangeFromId'](_0x149768);if(!_0x212477)return null;_0x319816['setAttribute']('data-change-id',_0x149768,_0x1583c8),_0x319816['addClass']('ck-revision-history-root-'+_0x212477['type'],_0x1583c8),this['activeChange']==_0x212477&&_0x319816['addClass']('ck-revision-history-root--active',_0x1583c8);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x8737fc=>'revision-comment:'+_0x8737fc,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x5c4bef=>'revision-suggestion:'+_0x5c4bef,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x50db22=>({'name':'suggestion:'+_0x50db22,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x2ebbf4=>{const _0x2ec87e=_0x2ebbf4['markerName']['split'](':')[0x1];return'insertion'!=_0x2ec87e&&'deletion'!=_0x2ec87e?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x2ec87e]};}}),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',(_0x8af211,_0x5954f0,_0x320512)=>{const _0x1dbe1b=_0x320512['mapper']['markerNameToElements'](_0x5954f0['markerName']);if(_0x1dbe1b){for(const _0x43e3b3 of _0x1dbe1b)_0x43e3b3['is']('uiElement')&&(_0x320512['mapper']['unbindElementFromMarkerName'](_0x43e3b3,_0x5954f0['markerName']),_0x320512['writer']['remove'](_0x43e3b3));}},{'priority':'high'});}['_getChangeFromId'](_0x320b82){return this['_changeIdToChange']['get'](_0x320b82);}['_getViewForChange'](_0x38f19c){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new z(this['editor']['locale'],_0x38f19c),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x25ce69,_0x34da19,_0x10f89b,_0xb7a755)=>{_0xb7a755&&this['_balloon']['remove'](_0xb7a755),_0x10f89b&&(this['_balloon']['add']({'view':_0x10f89b,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x425925=this['editor']['editing'],_0x183ca2=this['_getChangeFromId'](_0x10f89b['changeId']);let _0x343757;if(_0x183ca2['data']['isOnRoot']){const _0x24f3b7=_0x425925['view']['getDomRoot'](_0x183ca2['rootName']);_0x343757=Array['from'](_0x24f3b7['getClientRects']());}else{const _0x30993c=this['editor']['model']['markers']['get']('revision:'+_0x10f89b['changeId']);_0x343757=Array['from'](_0x425925['mapper']['markerNameToElements'](_0x30993c['name']))['map'](_0x23f28b=>_0x425925['view']['domConverter']['mapViewToDom'](_0x23f28b))['map'](_0x5f4e95=>Array['from'](_0x5f4e95['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x343757[0x0];return _0x343757['find'](_0x4c64db=>_0x4c64db['top']-0x3<=this['_activeViewTarget']['y']&&_0x4c64db['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x4c64db['left']-0x3<=this['_activeViewTarget']['x']&&_0x4c64db['right']+0x3>=this['_activeViewTarget']['x'])||_0x343757[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x2071ca,_0x3306f2,_0x2dcc4d,_0x3e01ca)=>{this['activeView']=_0x2dcc4d?this['_getViewForChange'](_0x2dcc4d):null,this['editor']['model']['change'](()=>{const _0x16da57=this['editor']['editing'];_0x3e01ca&&(_0x3e01ca['data']['isOnRoot']?_0x16da57['view']['change'](_0x49256a=>{_0x49256a['removeClass']('ck-revision-history-root--active',_0x16da57['view']['document']['getRoot'](_0x3e01ca['rootName']));}):_0x16da57['reconvertMarker']('revision:'+_0x3e01ca['id'])),_0x2dcc4d&&(_0x2dcc4d['data']['isOnRoot']?_0x16da57['view']['change'](_0x57ce80=>{_0x57ce80['addClass']('ck-revision-history-root--active',_0x16da57['view']['document']['getRoot'](_0x2dcc4d['rootName']));}):_0x16da57['reconvertMarker']('revision:'+_0x2dcc4d['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x2b2491,_0x16c503)=>{if(this['activeChange'])return;const _0x741190=this['_findChangeIdFromDomTarget'](_0x16c503['target']),_0x5e271d=this['_changeIdToChange']['get'](_0x741190);_0x5e271d?(this['_activeViewTarget']={'x':_0x16c503['domEvent']['x'],'y':_0x16c503['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x5e271d)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x524b8f,_0x956f14)=>{const _0x440d92=this['_findChangeIdFromDomTarget'](_0x956f14['target']),_0x56d2cc=this['_changeIdToChange']['get'](_0x440d92);_0x56d2cc?(this['_activeViewTarget']={'x':_0x956f14['domEvent']['x'],'y':_0x956f14['domEvent']['y']},_0x56d2cc===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x56d2cc):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x5977bb){do{const _0x8ac38a=_0x5977bb['getAttribute']('data-change-id');if(_0x8ac38a)return _0x8ac38a;_0x5977bb=_0x5977bb['parent'];}while(_0x5977bb);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x4303cf=>{for(const _0xdc5057 of this['editor']['model']['markers'])_0x4303cf['removeMarker'](_0xdc5057);});}}function Q(_0x74f221,_0x52c2a9){return(_0x11e2ce,_0x24bf9f,_0x3a1aa3)=>{if(!_0x3a1aa3['consumable']['test'](_0x24bf9f['markerRange'],_0x11e2ce['name']))return;const _0x47644b=_0x24bf9f['markerRange']['getWalker'](),_0x298d0d=_0x24bf9f['markerRange']['start'],_0x5cd925=_0x74f221['model']['schema'];let _0xffa708=null,_0x5d78b4=null,_0x169fa2=!0x1,_0x56217e=!0x1;for(const _0x4a3d0c of _0x47644b){const _0x1e6913=_0x4a3d0c['item'];_0x169fa2=_0x169fa2||_0x5cd925['isContent'](_0x1e6913);const _0x4e25c1=_0x3a1aa3['mapper']['toViewElement'](_0x1e6913);if(_0x4e25c1&&_0x4e25c1['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x4a3d0c['type']&&(_0x5cd925['isBlock'](_0x1e6913)&&!_0x5cd925['isLimit'](_0x1e6913)&&(_0x1e6913['nextSibling']||_0x298d0d['isAtEnd']?_0xffa708&&_0xffa708['parent']==_0x1e6913||(_0xffa708=_0x1e6913,_0x42dff9(_0x4a3d0c['previousPosition']),_0x56217e=!0x0):_0x5d78b4=_0x5d78b4||_0x4a3d0c['previousPosition']));}function _0x42dff9(_0x27d23c){const _0x309788=_0x3a1aa3['mapper']['toViewPosition'](_0x27d23c),_0x571ace=_0x3a1aa3['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x52c2a9});_0x3a1aa3['writer']['insert'](_0x309788,_0x571ace),_0x3a1aa3['mapper']['bindElementToMarker'](_0x571ace,_0x24bf9f['markerName']);}_0x169fa2||_0x56217e||!_0x5d78b4||_0x42dff9(_0x5d78b4);};}class nt extends _0x518bfa{constructor(_0x5928ab){super(_0x5928ab);const _0x2a0f0a=_0x5928ab['plugins']['get'](u);this['affectsData']=!0x1,this['listenTo'](_0x2a0f0a,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x2a0f0a,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x144894=this['editor'],_0x3f312d=_0x144894['plugins']['get'](u),_0x26f2e4=_0x3f312d['isReady']?_0x3f312d['diff']['newRevisionId']:null;_0x144894['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x26f2e4);}['refresh'](){const {isReady:_0x53f6ca,isEnabled:_0x3dd3ea,repository:_0x5dd3d1,diff:_0x53883f}=this['editor']['plugins']['get'](u),_0x4c4ae1=_0x53883f&&_0x5dd3d1['getLaterVisibleRevision'](_0x53883f['newRevisionId']);this['isEnabled']=_0x53f6ca&&_0x3dd3ea&&Boolean(_0x4c4ae1);}}class rt extends _0x518bfa{['_step'];constructor(_0x5e53aa,{direction:_0x1df5b9}){super(_0x5e53aa);const _0x5bf7e3=_0x5e53aa['plugins']['get'](u);this['affectsData']=!0x1,this['_step']='forward'===_0x1df5b9?0x1:-0x1,this['listenTo'](_0x5bf7e3,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x5bf7e3,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x5bf7e3,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x9fabe0=this['editor'],_0x3aa3e6=_0x9fabe0['plugins']['get'](u),{isNavigationMode:_0x3b7935,currentChangeNumber:_0xa65cb8}=_0x3aa3e6;let _0x4b4dc7;if(_0x3aa3e6['activeChange']=_0x3b7935?_0x3aa3e6['diff']['changes']['get'](_0xa65cb8+this['_step']):_0x3aa3e6['diff']['changes']['first'],_0x3aa3e6['activeChange']['data']['isOnRoot'])_0x4b4dc7=_0x9fabe0['editing']['view']['getDomRoot'](_0x3aa3e6['activeChange']['rootName']);else{const _0x20bb2c=_0x9fabe0['model']['markers']['get']('revision:'+_0x3aa3e6['activeChange']['id']);_0x4b4dc7=_0x4ba0e4(_0x9fabe0['editing'],_0x20bb2c);}_0xd0b7de({'target':_0x4b4dc7,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x4cd392,currentChangeNumber:_0x53ad63,numberOfChanges:_0x2a19c4,isReady:_0x41f5b6,isEnabled:_0x13b04e}=this['editor']['plugins']['get'](u);this['isEnabled']=!!(_0x13b04e&&_0x41f5b6&&_0x2a19c4)&&(!_0x4cd392||(0x1===this['_step']?_0x53ad63<_0x2a19c4-0x1:_0x53ad63>0x0));}}class Ri extends _0x3ee578{constructor(_0x4ca33a){super(_0x4ca33a);const _0x5d89ce=this['bindTemplate'],_0x33c5ac=new _0x235a06(_0x4ca33a),_0x5937ab=new _0x235a06(_0x4ca33a);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',(_0x45408c,_0xa1aa3c)=>_0x45408c&&_0xa1aa3c>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x9e8a40,_0x1eab2a,_0x240e06,_0x4a4e17)=>{if(!_0x9e8a40)return m(_0x4ca33a,'Loading...');if(!_0x240e06)return m(_0x4ca33a,'No\x20changes');const _0x4c4d70=m(_0x4ca33a,'NUMBER_OF_CHANGES',_0x240e06);return _0x4a4e17?m(_0x4ca33a,'X_OF_Y_CHANGES',[_0x1eab2a+0x1,_0x240e06]):_0x4c4d70;}),_0x33c5ac['set']({'label':m(_0x4ca33a,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x54e670}),_0x5937ab['set']({'label':m(_0x4ca33a,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x1fe749}),_0x33c5ac['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x5937ab['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x33c5ac['on']('execute',()=>this['fire']('execute','backward')),_0x5937ab['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',_0x5d89ce['if']('_isStatusLabelVisible','ck-hidden',_0x4d8644=>!_0x4d8644)]},'children':[{'text':_0x5d89ce['to']('isNavigationMode',_0x45d7fc=>_0x45d7fc?m(_0x4ca33a,'EDIT_X_OF_Y_REVISIONS')+':\x20':m(_0x4ca33a,'Total')+':\x20')}]},{'text':_0x5d89ce['to']('_statusText')}]},new _0x5652f5(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x33c5ac,_0x5937ab]}]});}}const ge='ck-editor__editable__loading-overlay';class ji extends _0x4b71e4{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x246a2c=this['editor']['editing']['view'];_0x246a2c['change'](_0xd8596f=>{for(const _0xc44441 of _0x246a2c['document']['roots'])_0xd8596f['addClass'](ge,_0xc44441);});}['hide'](){const _0x663880=this['editor']['editing']['view'];_0x663880['change'](_0x3eaaa1=>{for(const _0x92c01b of _0x663880['document']['roots'])_0x3eaaa1['removeClass'](ge,_0x92c01b);});}}class v extends _0x4b71e4{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u,ji];}['init'](){const _0x14e739=this['editor'],_0x5da3b2=_0x14e739['plugins']['get'](u),_0x24193a=_0x14e739['plugins']['get'](ji);_0x14e739['ui']['componentFactory']['add']('exitToEditing',_0x2bef4d=>{const _0x2896f6=new _0x235a06(_0x2bef4d);return _0x2896f6['set']({'label':m(_0x2bef4d,'Back\x20to\x20editing'),'icon':_0x90f4af,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x2896f6,'execute',()=>{_0x14e739['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x2896f6;}),_0x14e739['ui']['componentFactory']['add']('restoreRevision',_0x2228fa=>{const _0x162641=new _0x235a06(_0x2228fa);return _0x162641['set']({'label':m(_0x2228fa,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x162641['bind']('isEnabled')['to'](_0x14e739['commands']['get']('restoreRevision')),this['listenTo'](_0x162641,'execute',()=>_0x14e739['execute']('restoreRevision')),_0x162641;}),_0x14e739['ui']['componentFactory']['add']('changesNavigation',_0x10fc49=>{const _0x5350c2=new Ri(_0x10fc49),_0x34971e=_0x14e739['commands']['get']('showPreviousChange'),_0x37eaca=_0x14e739['commands']['get']('showNextChange');return _0x5350c2['bind']('isBackwardNavigationEnabled')['to'](_0x34971e,'isEnabled'),_0x5350c2['bind']('isForwardNavigationEnabled')['to'](_0x37eaca,'isEnabled'),_0x5350c2['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x5da3b2),this['listenTo'](_0x5350c2,'execute',(_0x1f9532,_0x5a8849)=>{_0x14e739['execute']('forward'===_0x5a8849?'showNextChange':'showPreviousChange');}),_0x5350c2;}),_0x24193a['show'](),_0x5da3b2['on']('change:isReady',(_0x4c6c55,_0x5b7963,_0x3e7545)=>{_0x3e7545?_0x24193a['hide']():_0x24193a['show']();});}}class hi extends et{['_resizeObserver']=null;constructor(_0x3b6662,_0x4855ff){super(_0x3b6662,_0x4855ff);const _0x2b0756=this['bindTemplate'];this['set']({'label':m(_0x3b6662,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=m(_0x3b6662,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x2b0756['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 _0x4e6f4b=this['fieldView']['element'];this['_tooltipString']=_0x4e6f4b['scrollWidth']>_0x4e6f4b['clientWidth']&&_0x4e6f4b['value']||'';}}class ni extends _0x3ee578{constructor(_0x3447a1,_0x15a9eb,_0x27c65a){super(_0x3447a1);const _0x2f8dda=new _0x468b2c();_0x2f8dda['set']({'content':_0x2d4ff3,'viewBox':'0\x200\x2011\x2010'});const _0x450534=['ck','ck-revision-history-sidebar__revision-author'];_0x27c65a&&_0x450534['push']('ck-revision-history-sidebar__revision-author_creator');const _0x1c2407=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':m(_0x3447a1,_0x27c65a?'Revision\x20creator':'Revision\x20author')},'children':[_0x2f8dda,_0x15a9eb['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x450534},'children':_0x1c2407});}}function ai(_0x5212c6,_0x37fe46){const _0x3e3990=_0x5212c6['bindTemplate'],_0x68f4d9=_0x5212c6['locale'],_0x278bd0=_0x5925fb(_0x68f4d9);_0x278bd0['panelPosition']='sw';const _0x27de38=function(_0x16215a,_0x16bcf0){const _0x3ddf88=function(_0x134a16,_0x4466c5){const _0x5913aa=_0x134a16['locale'],_0x3ae580={'Compare\x20against\x20selected':m(_0x5913aa,'Compare\x20against\x20selected'),'Name\x20this\x20revision':m(_0x5913aa,'Name\x20this\x20revision'),'Restore\x20this\x20revision':m(_0x5913aa,'Restore\x20this\x20revision')};return _0x4466c5['map'](_0x57f2c8=>{const _0x1eca90=_0x3ae580[_0x57f2c8['name']];return _0x1eca90&&_0x1eca90!==_0x57f2c8['name']&&(_0x57f2c8['name']=_0x1eca90),_0x57f2c8;});}(_0x16215a,_0x16bcf0),_0x375861=new _0x4658e5();for(const _0x47124f of _0x3ddf88){const _0x2adc00={'type':'button','model':new to({'label':_0x47124f['name'],'class':_0x47124f['class'],'withText':!0x0,'role':'menuitem','_action':_0x47124f['action']})};_0x2adc00['model']['bind']('isEnabled')['to'](_0x16215a,'isActionsDropdownOpen',_0x5df732=>'function'!=typeof _0x47124f['isEnabled']||(!_0x5df732||_0x47124f['isEnabled'](_0x16215a))),_0x375861['add'](_0x2adc00);}return _0x375861;}(_0x5212c6,_0x37fe46);return _0x5212c6['bind']('isActionsDropdownOpen')['to'](_0x278bd0,'isOpen'),_0x278bd0['buttonView']['set']({'label':m(_0x68f4d9,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x170036}),_0x278bd0['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x3e3990['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x3e3990['to'](_0x715094=>_0x715094['stopPropagation']())}}),_0x278bd0['on']('execute',_0x20e9c5=>{_0x5212c6['isReady']&&'function'==typeof _0x20e9c5['source']['_action']&&_0x20e9c5['source']['_action'](_0x5212c6);}),_0x2c6bad(_0x278bd0,_0x27de38,{'role':'menu'}),_0x278bd0['listenTo'](_0x5212c6,'change:isActionsDropdownOpen',(_0x297447,_0x5db434,_0x58ad7a)=>{if(_0x58ad7a)for(const _0x6cb7c5 of _0x278bd0['listView']['items']){const _0x2d688c=_0x6cb7c5['children']['first'],_0x517fd4=_0x37fe46['find'](_0x84de01=>_0x84de01['action']===_0x2d688c['_action'])['isVisible'];_0x6cb7c5['isVisible']=void 0x0===_0x517fd4||_0x517fd4(_0x5212c6);}}),_0x278bd0;}class _i extends/* #__PURE__ -- @preserve */
27
- _0x5eb75f(_0x3ee578){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x136ed9,_0x253f33,_0x3b672a,_0x155215){super(_0x136ed9);const _0x52dfbb=this['bindTemplate'],_0xe3c2bc=function(_0x4bc162,_0x396301){const _0x597dec=Array['from'](_0x396301['authors'])['filter'](_0x44366f=>_0x44366f!=_0x396301['creator']);return _0x396301['creator']&&_0x597dec['unshift'](_0x396301['creator']),_0x597dec['map'](_0x5f583b=>new ni(_0x4bc162,_0x5f583b,_0x5f583b==_0x396301['creator']));}(_0x136ed9,_0x253f33);this['id']=_0x253f33['id'],this['_revision']=_0x253f33,this['_requireRevisionName']=_0x155215,this['bind']('name','createdAt')['to'](_0x253f33),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x3fa582=>{return _0x22cf70=_0x136ed9['uiLanguage'],(_0x51f1e1=_0x3fa582)['toLocaleDateString'](_0x22cf70,{'month':'long','day':'numeric'})+',\x20'+_0x51f1e1['toLocaleTimeString'](_0x22cf70,{'hour':'numeric','minute':'numeric'});var _0x22cf70,_0x51f1e1;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new hi(_0x136ed9,ti),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x213dc0=>_0x213dc0||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x4232f2,_0x3d2b65)=>_0x4232f2&&_0x3d2b65),this['revisionActionsView']=_0x3b672a&&_0x3b672a['length']?ai(this,_0x3b672a):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x52dfbb['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x52dfbb['if']('isEnabled','ck-disabled',_0x34ab54=>!_0x34ab54),_0x52dfbb['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x52dfbb['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x52dfbb['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':_0x52dfbb['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':_0xe3c2bc}]},this['revisionActionsView']],'on':{'click':_0x52dfbb['to'](_0x111bf5=>{_0x111bf5['srcElement']['closest']('.ck-confirm-view')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x2327b8=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x2327b8,'change',()=>{this['_requireRevisionName']&&!_0x2327b8['value']||this['fire']('setName',{'id':this['id'],'name':_0x2327b8['value']}),_0x2327b8['value']||(_0x2327b8['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(_0x5cb413,_0x2907f7){const _0xf6d313=_0x1fdea2['fromJSDate'](_0x5cb413)['setLocale'](_0x2907f7),_0x159ee4=_0x1fdea2['local'](),_0x247baa=_0x159ee4['minus']({'days':0x1})['startOf']('day');let _0x33115c,_0x21375;return _0xf6d313['hasSame'](_0x159ee4,'day')?(_0x33115c=_0xf6d313['startOf']('day')['toJSDate'](),_0x21375=_0xf6d313['toRelativeCalendar']()):_0xf6d313['hasSame'](_0x247baa,'day')?(_0x33115c=_0x247baa['toJSDate'](),_0x21375=_0xf6d313['toRelativeCalendar']()):_0xf6d313['hasSame'](_0x159ee4,'week')?(_0x33115c=_0xf6d313['startOf']('week')['toJSDate'](),_0x21375=_0xf6d313['weekdayLong']||''):_0xf6d313['hasSame'](_0x159ee4,'year')?(_0x33115c=_0xf6d313['startOf']('month')['toJSDate'](),_0x21375=_0xf6d313['monthLong']||''):(_0x33115c=_0xf6d313['startOf']('year')['toJSDate'](),_0x21375=String(_0xf6d313['year'])),{'startDate':_0x33115c,'localizedPeriodName':_0x21375};}class bi extends _0x3ee578{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x2cc61f,_0x7daaea,_0x21c2eb,_0x14029c){super(_0x2cc61f);const _0x16570b=li(_0x7daaea,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x7daaea,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x21c2eb,this['_requireRevisionName']=_0x14029c,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':_0x16570b}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0xc98e6c){const _0x4536d7=new _i(this['locale'],_0xc98e6c,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x4536d7);}['removeRevision'](_0x24c6dd){const _0xb12e0e=this['revisionViews']['find'](_0x31216e=>_0x31216e['id']===_0x24c6dd['id']);this['revisionViews']['remove'](_0xb12e0e);}}class fi extends _0x3ee578{constructor(_0x20060e){super(_0x20060e);const _0x47287e=new _0x468b2c();_0x47287e['content']=_0x31711b,this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x47287e,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[m(_0x20060e,'Revision\x20history')]}]});}}class di extends _0x3ee578{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x18552f,_0x3a830f,_0x2ad2ce,_0x539954){super(_0x18552f);const _0x1f544b=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x3a830f,this['_revisionActions']=_0x2ad2ce,this['_requireRevisionName']=_0x539954,this['on']('select',(_0x7fc78c,_0x34438e)=>{this['fire']('revisionSelected',_0x34438e);}),this['on']('setName',(_0xf71b9e,_0x11fd58)=>{this['fire']('revisionSetName',_0x11fd58);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new fi(_0x18552f),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x1f544b['if']('isEnabled','ck-disabled',_0x22d3e0=>!_0x22d3e0)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x59cbec of this['_revisions'])this['_addRevision'](_0x59cbec);this['_revisions']['on']('add',(_0x3cc025,_0xb7d523)=>{this['_addRevision'](_0xb7d523);}),this['_revisions']['on']('remove',(_0x1f320f,_0x5a5f96)=>{this['_removeRevision'](_0x5a5f96);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x36b234=>_0x36b234['revisionViews']['map'](_0x4a7875=>_0x4a7875))['flat']();}['selectRevision'](_0x202404){for(const _0xd3e3eb of this['revisionViews'])_0x202404&&_0x202404['id']===_0xd3e3eb['id']?_0xd3e3eb['select']():_0xd3e3eb['deselect']();}['highlightRevisions'](_0x4e86cd){for(const _0x39608a of this['revisionViews'])_0x4e86cd['some'](({id:_0x1a00fd})=>_0x1a00fd===_0x39608a['id'])?_0x39608a['highlight']():_0x39608a['unhighlight']();}['_addRevision'](_0x3dcad7){const _0x2699da=li(_0x3dcad7['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x50230c=this['timePeriodViews']['get'](0x0);_0x50230c&&_0x50230c['startDate']['getTime']()===_0x2699da['getTime']()||(_0x50230c=new bi(this['locale'],_0x2699da,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x50230c)),_0x50230c['addRevision'](_0x3dcad7);}['_removeRevision'](_0x42839d){const _0x55eaf8=li(_0x42839d['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x55eaf8)['removeRevision'](_0x42839d);}['_getTimePeriodViewByStartDate'](_0x20808f){return this['timePeriodViews']['find'](_0x3acd91=>_0x3acd91['startDate']['getTime']()===_0x20808f['getTime']());}}class d extends _0x4b71e4{['_revisionViewer'];['_revisionsRepository'];['_sidebarView'];static ['defaultRevisionActions']=/* #__PURE__ -- @preserve */
23
+ import{ObservableMixin as _0x56e76d,uid as _0x9068c,Collection as _0x17dfa9,logWarning as _0x117f74,FocusTracker as _0x231da2,KeystrokeHandler as _0x3f1f83,scrollViewportToShowTarget as _0x3813c7,ResizeObserver as et,ElementReplacer as it,CKEditorError as _0x155f4d}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x42245c,set as _0x415fb3,unset as _0x1c5616,isEqual as _0x11b9c0}from'es-toolkit/compat';import{Plugin as _0x237363,PendingActions as _0x5ece84,Command as _0x15d826,ElementApiMixin as _0x37662a,Editor as _0x455307}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x2e9ed3,getMarkerDomElement as _0x189758,ConfirmMixin as _0x588598,sanitizeEditorConfig as _0x2f465f}from'ckeditor5-collaboration/dist/index.js';import{ViewContainerElement as _0x1d472d,ViewAttributeElement as _0x18f5d8,ViewEmptyElement as _0x440e68,ViewRawElement as _0x503403,ViewUIElement as _0xe4ed6a,ViewDocumentFragment as _0x173d28,ViewText as _0x20857e,ViewElement as _0x247927,ModelElement as _0x5600a1,ModelRange as _0x5d4c4b,ModelPosition as _0x4f0201,ModelDocumentFragment as _0x15cae0,ModelText as _0x260b60}from'@ckeditor/ckeditor5-engine/dist/index.js';import{IconHistory as _0x509fac,IconChevronUp as _0x2d2d82,IconChevronDown as _0xc8bb2a,IconUndo as _0x2c316f,IconUser as _0x37f372,IconThreeVerticalDots as _0x59d1ed}from'@ckeditor/ckeditor5-icons/dist/index.js';import{CssTransitionDisablerMixin as _0x5e02d5,View as _0x3cfa23,submitHandler as _0x34d885,LabeledFieldView as ti,createLabeledInputText as _0x5802d2,createDropdown as _0x408b44,ListView as _0x2b1a30,ListItemView as _0x5a71fd,ButtonView as _0x58da02,MenuBarMenuView as _0x4d1d93,MenuBarMenuListView as _0x51a300,MenuBarMenuListItemView as _0x39d5f5,MenuBarMenuListItemButtonView as _0xda620,ContextualBalloon as _0x28c0b9,ToolbarSeparatorView as _0x27d032,IconView as _0x44d27e,addListToDropdown as _0x4d8904,UIModel as to,EditorUI as tt,normalizeToolbarConfig as st,BoxedEditorUIView as _0x2c763f,StickyPanelView as _0x543ebe,ToolbarView as _0x8f2e9b,InlineEditableUIView as te}from'@ckeditor/ckeditor5-ui/dist/index.js';import{DateTime as _0x320207}from'luxon';class I extends/* #__PURE__ -- @preserve */
24
+ _0x56e76d(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x4b7fd0){super(),this['id']=_0x4b7fd0['id']||_0x9068c(),this['creator']=_0x4b7fd0['creator']||null,this['authors']=_0x4b7fd0['authors']||[],this['diffData']=_0x4b7fd0['diffData']||null,this['toVersion']=_0x4b7fd0['toVersion']||0x0,this['fromVersion']=_0x4b7fd0['fromVersion']||0x0,this['set']('name',_0x4b7fd0['name']||''),this['set']('createdAt',_0x4b7fd0['createdAt']||new Date()),this['set']('attributes',_0x4b7fd0['attributes']||{});}['setName'](_0xb688ba){this['_update']({'name':_0xb688ba});}['setAttribute'](_0x510b6f,_0x4a70d8){const _0x313566=_0x42245c(this['attributes']);_0x415fb3(_0x313566,_0x510b6f,_0x4a70d8),this['_update']({'attributes':_0x313566});}['removeAttribute'](_0x5f174e){const _0x46392c=_0x42245c(this['attributes']);_0x1c5616(_0x46392c,_0x5f174e),this['_update']({'attributes':_0x46392c});}['_update'](_0x14c572,_0x6d61c8=!0x1){let _0x1bb7ca=!0x1;const _0xd3fbf4={'id':this['id']},_0x5cf9da=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x217717 of _0x5cf9da){const _0x1876c8=_0x14c572[_0x217717];void 0x0!==_0x1876c8&&_0x1876c8!==this[_0x217717]&&(this[_0x217717]=_0x1876c8,_0xd3fbf4[_0x217717]=_0x1876c8,_0x1bb7ca=!0x0);}_0x1bb7ca&&(_0xd3fbf4['authors']&&(_0xd3fbf4['authorsIds']=_0xd3fbf4['authors']['map'](_0x290299=>_0x290299['id']),delete _0xd3fbf4['authors']),this['fire']('_update',_0xd3fbf4,_0x6d61c8));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x33981d=>_0x33981d['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class S extends _0x237363{['_revisions'];static get['requires'](){return[_0x2e9ed3];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x589b79){super(_0x589b79),this['_revisions']=new _0x17dfa9();}['afterInit'](){!async function(_0x50cf74){const _0x35692d=_0x2e3825([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]),_0x4c7b0a=0xeb829,_0xa9a30a=0x359e09b0,_0x2daed9=0x35997368^_0xa9a30a,_0x11f516=window[_0x2e3825([0x44,0x61,0x74,0x65])][_0x2e3825([0x6e,0x6f,0x77])](),_0x2c405b=_0x50cf74[_0x2e3825([0x65,0x64,0x69,0x74,0x6f,0x72])],_0xcb375f=new window[(_0x2e3825([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x23c067=>{_0x2c405b[_0x2e3825([0x6f,0x6e,0x63,0x65])](_0x2e3825([0x72,0x65,0x61,0x64,0x79]),_0x23c067);}),_0xceb8a6={[_0x2e3825([0x6b,0x74,0x79])]:_0x2e3825([0x45,0x43]),[_0x2e3825([0x75,0x73,0x65])]:_0x2e3825([0x73,0x69,0x67]),[_0x2e3825([0x63,0x72,0x76])]:_0x2e3825([0x50,0x2d,0x32,0x35,0x36]),[_0x2e3825([0x78])]:_0x2e3825([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]),[_0x2e3825([0x79])]:_0x2e3825([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]),[_0x2e3825([0x61,0x6c,0x67])]:_0x2e3825([0x45,0x53,0x32,0x35,0x36])},_0x22d939=_0x2c405b[_0x2e3825([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x2e3825([0x67,0x65,0x74])](_0x2e3825([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x48512e(){let _0xc21744,_0x179766=null,_0x14275d=null;try{if(_0x22d939==_0x2e3825([0x47,0x50,0x4c]))return _0x2e3825([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0xc21744=_0x1c6f65(),!_0xc21744)return _0x2e3825([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0xc21744[_0x2e3825([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x14275d=_0x265df9(_0xc21744[_0x2e3825([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0xc21744[_0x2e3825([0x6a,0x74,0x69])])),await _0x3af018()?_0x179791()?_0x433f2b()?_0x2e3825([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x52d5c2()?(_0xc21744[_0x2e3825([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x2e3825([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x179766=_0x4961cf(_0x2e3825([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0xc21744[_0x2e3825([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x2e3825([0x74,0x72,0x69,0x61,0x6c])&&(_0x179766=_0x4961cf(_0x2e3825([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x2008d9()):_0x2e3825([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x2e3825([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x2e3825([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch{return _0x2e3825([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x433f2b(){const _0x5c5d9d=[_0x2e3825([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x2e3825([0x74,0x72,0x69,0x61,0x6c])][_0x2e3825([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0xc21744[_0x2e3825([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x11f516/0x3e8:0xe10*_0x2daed9;return _0xc21744[_0x2e3825([0x65,0x78,0x70])]<_0x5c5d9d;}function _0x179791(){const _0x7b8df4=_0xc21744[_0x2e3825([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x7b8df4)return!0x1;if(_0x7b8df4[_0x2e3825([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x2e3825([0x2a])))return!0x0;if(_0x7b8df4[_0x2e3825([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x2e3825([0x52,0x48])))return!0x0;if(_0x7b8df4[_0x2e3825([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x2e3825([0x52,0x52,0x48]))){if(_0x1e5548())return!0x0;if(_0x49a5c4()||_0x517c51())return!0x0;}return!0x1;}function _0x52d5c2(){const _0xe1fa80=_0xc21744[_0x2e3825([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0xe1fa80||0x0==_0xe1fa80[_0x2e3825([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x21916c}=new URL(window[_0x2e3825([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0xe1fa80[_0x2e3825([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x21916c))return!0x0;const _0x3e7ab8=_0x21916c[_0x2e3825([0x73,0x70,0x6c,0x69,0x74])](_0x2e3825([0x2e]));return _0xe1fa80[_0x2e3825([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x458619=>_0x458619[_0x2e3825([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x2e3825([0x2a])))[_0x2e3825([0x6d,0x61,0x70])](_0x1b37d3=>_0x1b37d3[_0x2e3825([0x73,0x70,0x6c,0x69,0x74])](_0x2e3825([0x2e])))[_0x2e3825([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x269486=>_0x269486[_0x2e3825([0x6c,0x65,0x6e,0x67,0x74,0x68])]<=_0x3e7ab8[_0x2e3825([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x2e3825([0x6d,0x61,0x70])](_0x6e602b=>Array(_0x3e7ab8[_0x2e3825([0x6c,0x65,0x6e,0x67,0x74,0x68])]-_0x6e602b[_0x2e3825([0x6c,0x65,0x6e,0x67,0x74,0x68])])[_0x2e3825([0x66,0x69,0x6c,0x6c])](_0x6e602b[0x0]===_0x2e3825([0x2a])?_0x2e3825([0x2a]):'')[_0x2e3825([0x63,0x6f,0x6e,0x63,0x61,0x74])](_0x6e602b))[_0x2e3825([0x73,0x6f,0x6d,0x65])](_0x51171f=>_0x3e7ab8[_0x2e3825([0x65,0x76,0x65,0x72,0x79])]((_0x55f93f,_0x4d5cd7)=>_0x51171f[_0x4d5cd7]===_0x55f93f||_0x51171f[_0x4d5cd7]===_0x2e3825([0x2a])));}function _0x2008d9(){return _0x179766&&_0x14275d?new window[(_0x2e3825([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x563df2,_0x429fbe)=>{_0x179766[_0x2e3825([0x74,0x68,0x65,0x6e])](_0x563df2,_0x429fbe),_0x14275d[_0x2e3825([0x74,0x68,0x65,0x6e])](_0x18d0f3=>{_0x18d0f3!=_0x2e3825([0x56,0x61,0x6c,0x69,0x64])&&_0x563df2(_0x18d0f3);},_0x429fbe);}):_0x179766||_0x14275d||_0x2e3825([0x56,0x61,0x6c,0x69,0x64]);}}function _0x265df9(_0xcee401,_0x33dc3e){return new window[(_0x2e3825([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x354669=>{if(_0x11f875())return _0x354669(_0x2e3825([0x56,0x61,0x6c,0x69,0x64]));_0x509a2d(),_0x2c405b[_0x2e3825([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x2e3825([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x3a84ac=!0x1;const _0x15c975=_0x9068c();function _0x325531(_0xcc68b){return!!_0xcc68b&&(typeof _0xcc68b===_0x2e3825([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0xcc68b===_0x2e3825([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0xcc68b[_0x2e3825([0x74,0x68,0x65,0x6e])]===_0x2e3825([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0xcc68b[_0x2e3825([0x63,0x61,0x74,0x63,0x68])]===_0x2e3825([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x1333a1(_0x465624){_0x1fefd1(_0x465624)[_0x2e3825([0x74,0x68,0x65,0x6e])](_0x35384e=>{if(!_0x35384e||_0x35384e[_0x2e3825([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x2e3825([0x6f,0x6b]))return _0x2e3825([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x594d7c(_0x537e7e(_0x15c975+_0x33dc3e))!=_0x35384e[_0x2e3825([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x2e3825([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x2e3825([0x56,0x61,0x6c,0x69,0x64]);})[_0x2e3825([0x74,0x68,0x65,0x6e])](_0x2c9b56=>(_0x3c157b(),_0x2c9b56),()=>{const _0x375b02=_0x3de6a1();return null==_0x375b02?(_0x3c157b(),_0x2e3825([0x56,0x61,0x6c,0x69,0x64])):_0x2e3825(_0x11f516-_0x375b02>(0x11928db0^_0xa9a30a)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x2e3825([0x74,0x68,0x65,0x6e])](_0x354669)[_0x2e3825([0x63,0x61,0x74,0x63,0x68])](()=>{_0x354669(_0x2e3825([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x5b4953=0x35a8e730^_0xa9a30a;function _0x3c157b(){const _0x2167a1=_0x2e3825([0x6c,0x6c,0x63,0x74,0x2d])+_0x594d7c(_0x537e7e(_0xcee401)),_0x20906e=_0x2d1b79(_0x594d7c(window[_0x2e3825([0x4d,0x61,0x74,0x68])][_0x2e3825([0x63,0x65,0x69,0x6c])](_0x11f516/_0x5b4953)));window[_0x2e3825([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x2e3825([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x2167a1,_0x20906e);}function _0x3de6a1(){const _0x1c27c5=_0x2e3825([0x6c,0x6c,0x63,0x74,0x2d])+_0x594d7c(_0x537e7e(_0xcee401)),_0x28b449=window[_0x2e3825([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x2e3825([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x1c27c5);return _0x28b449?window[_0x2e3825([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x2d1b79(_0x28b449),0x10)*_0x5b4953:null;}function _0x1fefd1(_0xc8024e){return new window[(_0x2e3825([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x3f93b3,_0x37246f)=>{_0xc8024e[_0x2e3825([0x74,0x68,0x65,0x6e])](_0x3f93b3,_0x37246f),window[_0x2e3825([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x37246f,0x359fdd70^_0xa9a30a);});}}_0x2c405b[_0x2e3825([0x6f,0x6e])](_0x2e3825([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0xfc2a8c,_0x499ced)=>{if(_0x499ced[0x0]!=_0xcee401)return _0x354669(_0x2e3825([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x499ced[0x1]={..._0x499ced[0x1],[_0x2e3825([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x15c975};},{[_0x2e3825([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x2e3825([0x68,0x69,0x67,0x68])}),_0x2c405b[_0x2e3825([0x6f,0x6e])](_0x2e3825([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x17b8f1=>{_0x325531(_0x17b8f1[_0x2e3825([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x3a84ac=!0x0,_0x1333a1(_0x17b8f1[_0x2e3825([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x2e3825([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x2e3825([0x6c,0x6f,0x77])}),_0xcb375f[_0x2e3825([0x74,0x68,0x65,0x6e])](()=>{_0x3a84ac||_0x354669(_0x2e3825([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x11f875(){return _0x2c405b[_0x2e3825([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x2e3825([0x76,0x69,0x65,0x77])][_0x2e3825([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x2e3825([0x61,0x75,0x74,0x6f]);}function _0x509a2d(){_0x2c405b[_0x2e3825([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x2e3825([0x76,0x69,0x65,0x77])][_0x2e3825([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x2e3825([0x61,0x75,0x74,0x6f]);}}function _0x4961cf(_0x452954){const _0xa5e48a=[new window[(_0x2e3825([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0xe683f5=>setTimeout(_0xe683f5,0x3597377c^_0xa9a30a)),_0xcb375f[_0x2e3825([0x74,0x68,0x65,0x6e])](()=>new window[(_0x2e3825([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x6dab7a=>{const _0x397a6f=0x359e09b7^_0xa9a30a,_0x72f22a=_0x50cf74[_0x2e3825([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x435803(){_0x72f22a[_0x2e3825([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x397a6f&&_0x6dab7a();}_0x435803(),_0x72f22a[_0x2e3825([0x6f,0x6e])](_0x2e3825([0x61,0x64,0x64]),_0x435803);})),new window[(_0x2e3825([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x35ed8c=>{function _0x438b89(){for(const _0x536577 in window)if(window[_0x2e3825([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x2e3825([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x536577))&&window[_0x536577]==_0x4c7b0a)return _0x35ed8c();_0x2c405b[_0x2e3825([0x73,0x74,0x61,0x74,0x65])]!=_0x2e3825([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x2e3825([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x438b89,0x359e1a38^_0xa9a30a);}_0xa0bed4(_0x2e3825([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x438b89();})];return window[_0x2e3825([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x2e3825([0x72,0x61,0x63,0x65])](_0xa5e48a)[_0x2e3825([0x74,0x68,0x65,0x6e])](()=>_0x452954);}async function _0x575309(){if(await _0xcb375f,_0xa0bed4(_0x2e3825([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x302b5e=_0x50cf74[_0x2e3825([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x1d8e77=_0x50cf74[_0x2e3825([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])](_0x302b5e[_0x2e3825([0x69,0x64])]),_0x10f5c7=_0x261b5c(_0x2e3825([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x10f5c7[_0x2e3825([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x302b5e['id'],_0x1d8e77?_0x1d8e77['id']:null,!0x0),_0x10f5c7[_0x2e3825([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x2e3825([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x10f5c7[_0x2e3825([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x10f5c7[_0x2e3825([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x1f8584,void(_0x10f5c7[_0x2e3825([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x1f8584);}if(_0xa0bed4(_0x2e3825([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x33f983=_0x261b5c(_0x2e3825([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x33f983[_0x2e3825([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x2e3825([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x33f983[_0x2e3825([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x33f983[_0x2e3825([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x1f8584,_0x33f983[_0x2e3825([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x1f8584;}_0x2c405b[_0x2e3825([0x6d,0x6f,0x64,0x65,0x6c])][_0x2e3825([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x1f8584,_0x2c405b[_0x2e3825([0x6d,0x6f,0x64,0x65,0x6c])][_0x2e3825([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x1f8584,_0x2c405b[_0x2e3825([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x2e3825([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x1e5548(){return _0xa0bed4(_0x2e3825([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x261b5c(_0x2e3825([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x2e3825([0x73,0x74,0x61,0x74,0x65])]==_0x2e3825([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x49a5c4(){return _0xa0bed4(_0x2e3825([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 _0x517c51(){return _0xa0bed4(_0x2e3825([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x38ab67(_0x2e764f){const _0x3572c8=_0x47a0f1();_0x2c405b[_0x3572c8]=_0x2e3825([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])+_0x2e764f,_0x2e764f[_0x2e3825([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x2e3825([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x47a0f1()]=_0x4c7b0a),_0x2e764f!=_0x2e3825([0x56,0x61,0x6c,0x69,0x64])&&_0x575309();}function _0x47a0f1(){const _0x4e73fb=window[_0x2e3825([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x2e3825([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x2e3825([0x6e,0x6f,0x77])]())[_0x2e3825([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x2e3825([0x2e]),'');let _0x3bfabe=_0x2e3825([0x76]);for(let _0x1ae22e=0x0;_0x1ae22e<_0x4e73fb[_0x2e3825([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x1ae22e+=0x2){let _0x106434=window[_0x2e3825([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x4e73fb[_0x2e3825([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x1ae22e,_0x1ae22e+0x2));_0x106434>=_0x35692d[_0x2e3825([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x106434-=_0x35692d[_0x2e3825([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x3bfabe+=_0x35692d[_0x106434];}return _0x3bfabe;}function _0x1c6f65(){const _0x341cd4=_0x22d939[_0x2e3825([0x73,0x70,0x6c,0x69,0x74])](_0x2e3825([0x2e]));if(0x3!=_0x341cd4[_0x2e3825([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x17f320(_0x341cd4[0x1]);function _0x17f320(_0x6361c){const _0x43c620=_0x5c3e10(_0x6361c);return _0x43c620&&_0x1504a7()?_0x43c620:null;function _0x1504a7(){const _0x19a553=_0x43c620[_0x2e3825([0x6a,0x74,0x69])],_0x3310c8=window[_0x2e3825([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x19a553[_0x2e3825([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x19a553[_0x2e3825([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x5dfa01={..._0x43c620,[_0x2e3825([0x6a,0x74,0x69])]:_0x19a553[_0x2e3825([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x19a553[_0x2e3825([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x5dfa01[_0x2e3825([0x76,0x63])],_0x537e7e(_0x5dfa01)==_0x3310c8;}}}async function _0x3af018(){let _0x16ae16=!0x0;try{const _0x21f5a6=_0x22d939[_0x2e3825([0x73,0x70,0x6c,0x69,0x74])](_0x2e3825([0x2e])),[_0x2352c7,_0x5264b8,_0x275c73]=_0x21f5a6;return _0xa3df9b(_0x2352c7),await _0x54f76f(_0x2352c7,_0x5264b8,_0x275c73),_0x16ae16;}catch{return!0x1;}function _0xa3df9b(_0x4768fa){const _0x57953b=_0x5c3e10(_0x4768fa);_0x57953b&&_0x57953b[_0x2e3825([0x61,0x6c,0x67])]==_0x2e3825([0x45,0x53,0x32,0x35,0x36])||(_0x16ae16=!0x1);}async function _0x54f76f(_0xeebe0,_0x46ea62,_0x505f3b){const _0x292438=window[_0x2e3825([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x2e3825([0x66,0x72,0x6f,0x6d])](_0x35ffc7(_0x505f3b),_0x535cec=>_0x535cec[_0x2e3825([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x147149=new window[(_0x2e3825([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x2e3825([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0xeebe0+_0x2e3825([0x2e])+_0x46ea62),_0x551f8e=window[_0x2e3825([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x2e3825([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x551f8e)return;const _0x2bb2fa=await _0x551f8e[_0x2e3825([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x2e3825([0x6a,0x77,0x6b]),_0xceb8a6,{[_0x2e3825([0x6e,0x61,0x6d,0x65])]:_0x2e3825([0x45,0x43,0x44,0x53,0x41]),[_0x2e3825([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x2e3825([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x2e3825([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x551f8e[_0x2e3825([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x2e3825([0x6e,0x61,0x6d,0x65])]:_0x2e3825([0x45,0x43,0x44,0x53,0x41]),[_0x2e3825([0x68,0x61,0x73,0x68])]:{[_0x2e3825([0x6e,0x61,0x6d,0x65])]:_0x2e3825([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x2bb2fa,_0x292438,_0x147149)||(_0x16ae16=!0x1);}}function _0x5c3e10(_0x26e541){return _0x26e541[_0x2e3825([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x2e3825([0x65,0x79]))?JSON[_0x2e3825([0x70,0x61,0x72,0x73,0x65])](_0x35ffc7(_0x26e541)):null;}function _0x35ffc7(_0x3b8327){return window[_0x2e3825([0x61,0x74,0x6f,0x62])](_0x3b8327[_0x2e3825([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x2e3825([0x2b]))[_0x2e3825([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x2e3825([0x2f])));}function _0x537e7e(_0x57634b){let _0x580452=0x1505;function _0x534e3e(_0x541909){for(let _0x3d2b21=0x0;_0x3d2b21<_0x541909[_0x2e3825([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x3d2b21++){const _0x29a53d=_0x541909[_0x2e3825([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x3d2b21);_0x580452=(_0x580452<<0x5)+_0x580452+_0x29a53d,_0x580452&=_0x580452;}}function _0x19ff84(_0x1498f7){Array[_0x2e3825([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x1498f7)?_0x1498f7[_0x2e3825([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x19ff84):_0x1498f7&&typeof _0x1498f7==_0x2e3825([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x2e3825([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x1498f7)[_0x2e3825([0x73,0x6f,0x72,0x74])]()[_0x2e3825([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x1ecd68,_0x166947])=>{_0x534e3e(_0x1ecd68),_0x19ff84(_0x166947);}):_0x534e3e(window[_0x2e3825([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x1498f7));}return _0x19ff84(_0x57634b),_0x580452>>>0x0;}function _0x594d7c(_0x3647f4){return _0x3647f4[_0x2e3825([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x2e3825([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x2e3825([0x30]));}function _0x2d1b79(_0x2c3239){return _0x2c3239[_0x2e3825([0x73,0x70,0x6c,0x69,0x74])]('')[_0x2e3825([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x2e3825([0x6a,0x6f,0x69,0x6e])]('');}function _0xa0bed4(_0x21101b){return _0x2c405b[_0x2e3825([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x2e3825([0x68,0x61,0x73])](_0x21101b);}function _0x261b5c(_0x3437e5){return _0x2c405b[_0x2e3825([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x2e3825([0x67,0x65,0x74])](_0x3437e5);}function _0x1f8584(){}function _0x2e3825(_0xc59d0d){return _0xc59d0d['map'](_0x457a4a=>String['fromCharCode'](_0x457a4a))['join']('');}_0x38ab67(await _0x48512e());}(this);}['createRevision'](_0x2e89a2){const _0x39148e=this['editor']['plugins']['get']('Users');return new I({'id':_0x2e89a2['id'],'name':_0x2e89a2['name'],'creator':_0x2e89a2['creatorId']?_0x39148e['getUser'](_0x2e89a2['creatorId']):null,'diffData':_0x2e89a2['diffData']||_0x2e89a2['data'],'authors':_0x2e89a2['authorsIds']['map'](_0x3a1075=>_0x39148e['getUser'](_0x3a1075)),'createdAt':new Date(_0x2e89a2['createdAt']),'attributes':_0x2e89a2['attributes'],'fromVersion':_0x2e89a2['fromVersion'],'toVersion':_0x2e89a2['toVersion']});}['addRevision'](_0x361559,_0x1c12e4=0x0){this['_revisions']['add'](_0x361559,_0x1c12e4);}['getRevision'](_0x279d82){return this['_revisions']['get'](_0x279d82);}['getRevisions'](_0x58f159={'toJSON':!0x1}){const _0x397502=Array['from'](this['_revisions']);return _0x397502['reverse'](),_0x58f159['toJSON']?_0x397502['map'](_0x41df11=>_0x41df11['toJSON']()):_0x397502;}['getIndex'](_0x52a302){return this['_revisions']['getIndex'](_0x52a302);}['getEarlierVisibleRevision'](_0x5a94ae){const [,_0x540700]=this['getRevisionsIterator'](_0x5a94ae,{'direction':'earlier'});return _0x540700;}['getLaterVisibleRevision'](_0xc3b0a5){const [,_0x2fe356]=this['getRevisionsIterator'](_0xc3b0a5,{'direction':'later'});return _0x2fe356;}['getRevisionsInDiff'](_0x186e61){const _0x1e5bc2=[];for(const _0x19d6bb of this['getRevisionsIterator'](_0x186e61['newRevisionId']))if(_0x1e5bc2['push'](_0x19d6bb),_0x19d6bb['id']===_0x186e61['oldRevisionId'])break;return _0x1e5bc2;}*['getRevisionsIterator'](_0x14bc74,{direction:_0x12e61c='earlier',filter:_0x30c2f3=()=>!0x0}={}){const _0x2ca36c='earlier'===_0x12e61c?0x1:-0x1;let _0x5df986=this['_revisions']['get'](_0x14bc74),_0x4e3cb6=this['getIndex'](_0x5df986);for(yield _0x5df986;_0x5df986;){if(_0x4e3cb6+=_0x2ca36c,_0x5df986=this['getRevision'](_0x4e3cb6),!_0x5df986)return;_0x30c2f3(_0x5df986)&&(yield _0x5df986);}}}class $ extends _0x237363{static get['pluginName'](){return'RevisionHistoryUtils';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['_viewClassToTypeChar']=new Map([[_0x1d472d,'c'],[_0x18f5d8,'a'],[_0x440e68,'e'],[_0x503403,'r'],[_0xe4ed6a,'u']]);['_typeCharToViewClass']=new Map([['c',_0x1d472d],['a',_0x18f5d8],['e',_0x440e68],['r',_0x503403],['u',_0xe4ed6a]]);async['loadRevisionData'](_0x4e7e70,_0x41ea31){if(_0x4e7e70['diffData']||!_0x41ea31)return;const _0x276cc1=this['editor']['config']['get']('collaboration.channelId'),_0x1ba478=await _0x41ea31['getRevision']({'channelId':_0x276cc1,'revisionId':_0x4e7e70['id']});_0x4e7e70['diffData']=_0x1ba478['diffData'];}['getRevisionDocumentData'](_0x3a37b5){const _0x4c64af={};for(const _0x5474ca in _0x3a37b5['diffData']){if(_0x3a37b5['diffData'][_0x5474ca]['attachChange']&&!_0x3a37b5['diffData'][_0x5474ca]['attachChange']['isAttached'])continue;const _0x314dd8=this['_removeRevisionMarkers'](JSON['parse'](_0x3a37b5['diffData'][_0x5474ca]['insertions'])),_0x3fd098=this['editor']['editing']['view']['document'],_0x253af1=new _0x173d28(_0x3fd098,_0x314dd8['map'](_0x3df8fe=>this['_getViewFromDiffObj'](_0x3df8fe,!0x1)));this['editor']['data']['processor']['useFillerType']('marked'),_0x4c64af[_0x5474ca]=this['editor']['data']['processor']['toData'](_0x253af1),this['editor']['data']['processor']['useFillerType']('default');}return _0x4c64af;}['getRevisionRootsAttributes'](_0x4a6d78){const _0x1b8f7b={};for(const _0x1f71d4 in _0x4a6d78['diffData'])_0x4a6d78['diffData'][_0x1f71d4]['attachChange']&&!_0x4a6d78['diffData'][_0x1f71d4]['attachChange']['isAttached']||(_0x1b8f7b[_0x1f71d4]=_0x4a6d78['diffData'][_0x1f71d4]['attributesAfter']||{});return _0x1b8f7b;}['_getTypeCharForViewElement'](_0x3006f4){return this['_viewClassToTypeChar']['get'](_0x3006f4['constructor']);}['_getViewFromDiffObj'](_0x5f5046,_0x5f28ba){const _0x276923=this['editor']['editing']['view']['document'];if('string'==typeof _0x5f5046)return new _0x20857e(_0x276923,_0x5f5046);{let _0x568fcc,_0xec1b42;_0xec1b42='u'==_0x5f5046['type']||'r'==_0x5f5046['type']?[]:_0x5f5046['children']['map'](_0x2be84b=>this['_getViewFromDiffObj'](_0x2be84b,_0x5f28ba));const _0x4617f5=this['_typeCharToViewClass']['get'](_0x5f5046['type'])||_0x247927,_0x89573f=this['editor']['data']['htmlProcessor']['domConverter'];if(_0x568fcc=new _0x4617f5(_0x276923,_0x5f5046['name'],_0x5f5046['attributes'],_0xec1b42),'u'==_0x5f5046['type']&&_0x5f5046['children'][0x0]){const _0x5c164c=_0x5f5046['children'][0x0];if(_0x568fcc['render']=function(_0x7bca7b){const _0x172621=_0x7bca7b['createElement']('div');return _0x172621['innerHTML']=_0x5c164c,_0x172621['childNodes'][0x0];},_0x5f28ba){const _0x10811a=new _0x173d28(_0x276923);_0x10811a['_appendChild'](_0x568fcc);const _0x3626e8=Array['from'](_0x89573f['viewChildrenToDom'](_0x10811a,{'bind':!0x1})),_0x25131c=_0x89573f['domDocument']['createElement']('div');_0x25131c['append'](..._0x3626e8),_0x568fcc=Array['from'](_0x89573f['domChildrenToView'](_0x25131c))[0x0];}}else{if('r'==_0x5f5046['type']&&_0x5f5046['children'][0x0]){const _0x4ac9d3=_0x5f5046['children'][0x0];if(_0x568fcc['render']=function(_0x55b512){_0x55b512['innerHTML']=_0x4ac9d3;},_0x5f28ba){const _0x4b0f4d=new _0x173d28(_0x276923);_0x4b0f4d['_appendChild'](_0x568fcc);const _0x52bb5e=Array['from'](_0x89573f['viewChildrenToDom'](_0x4b0f4d,{'bind':!0x1})),_0x2b4c32=_0x89573f['domDocument']['createElement']('div');_0x2b4c32['append'](..._0x52bb5e);const _0x20857d=Array['from'](_0x89573f['domChildrenToView'](_0x2b4c32));_0x20857d['length']>0x1?_0x568fcc['_appendChild'](_0x20857d):_0x568fcc=_0x20857d[0x0];}}}if(_0x5f5046['customProperties']){for(const [_0x46e265,_0x518704]of _0x5f5046['customProperties'])_0x568fcc['_setCustomProperty'](_0x46e265,_0x518704);}const _0x5bf8f6=void 0x0===_0x5f5046['fillerOffset']?null:_0x5f5046['fillerOffset'];return null!==_0x5bf8f6&&(_0x568fcc['getFillerOffset']=()=>_0x5bf8f6),_0x568fcc;}}['_makeModelFromViewString'](_0x1418d4){const _0x275b62=JSON['parse'](_0x1418d4),_0x306009=this['editor']['editing']['view']['document'],_0x247f84=new _0x173d28(_0x306009,_0x275b62['map'](_0x34f4c2=>this['_getViewFromDiffObj'](_0x34f4c2,!0x0)));return this['editor']['data']['toModel'](_0x247f84);}['_removeRevisionMarkers'](_0x4b8418){return(_0x4b8418=_0x4b8418['filter'](_0x5af23a=>!_0x5af23a['name']||'revision-start'!==_0x5af23a['name']&&'revision-end'!==_0x5af23a['name']))['forEach'](_0xec91fe=>{'string'!=typeof _0xec91fe&&(_0xec91fe['children']=this['_removeRevisionMarkers'](_0xec91fe['children']),_0xec91fe['attributes']=_0xec91fe['attributes']['filter'](_0x3605df=>!_0x3605df[0x0]['startsWith']('data-revision-')));}),_0x4b8418;}}function m(_0x11365a,_0x419936,_0x195075){const t=_0x11365a['t'];switch(_0x419936){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'},_0x195075);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x195075);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 _0x237363{['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[_0x2e9ed3,S,$,_0x5ece84];}constructor(_0x1a3f83){super(_0x1a3f83),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 _0x536cdc=_0x9068c();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x536cdc},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 _0x57d494=this['repository']['getRevision'](0x0),_0x512d91=_0x57d494&&null===_0x57d494['creator']?_0x57d494:null;if(this['_continueCurrentRevision']=!!_0x512d91&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x468d04=this['_source']['getCurrentRevisionId'](),_0x4c2616=this['repository']['getRevision'](_0x468d04);if(_0x4c2616)this['_startingVersion']=_0x4c2616['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x1b2c30=this['_source']['history']['_operations']['find'](_0x42eaa0=>!_0x42eaa0['_isInit']),_0x4978c3=_0x1b2c30?_0x1b2c30['baseVersion']:this['_source']['history']['version'];_0x57d494?(_0x57d494['toVersion']<_0x4978c3&&_0x57d494['_update']({'toVersion':_0x4978c3}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x512d91['id'],this['_startingVersion']=_0x512d91['fromVersion']):(this['_startingVersion']=_0x57d494['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x4978c3,this['_continueCurrentRevision']=!0x1);}}else _0x512d91&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x512d91['toVersion'],this['editor']['model']['document']['history']['version']),_0x512d91['fromVersion']===_0x512d91['toVersion']?(0x0!==_0x512d91['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x512d91['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x512d91['id'],this['_startingVersion']=_0x512d91['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',_0x45a26f=>!_0x45a26f),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x53b2e3=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x2aa10c;for(const _0x3b924c in _0x53b2e3){const _0x2f3c29=_0x3b924c,_0x3dbc63=_0x53b2e3[_0x2f3c29];if('revisionHistoryLicenseKeyValid'==_0x3dbc63||'revisionHistoryLicenseKeyInvalid'==_0x3dbc63||'revisionHistoryLicenseKeyExpired'==_0x3dbc63||'revisionHistoryLicenseKeyDomainLimit'==_0x3dbc63||'revisionHistoryLicenseKeyNotAllowed'==_0x3dbc63||'revisionHistoryLicenseKeyEvaluationLimit'==_0x3dbc63||'revisionHistoryLicenseKeyTrialLimit'==_0x3dbc63||'revisionHistoryLicenseKeyUsageLimit'==_0x3dbc63){delete _0x53b2e3[_0x2f3c29],_0x2aa10c=_0x3dbc63,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x2aa10c&&_0x53b2e3['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x2aa10c&&_0x53b2e3['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x2aa10c&&_0x53b2e3['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x2aa10c&&_0x53b2e3['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x2aa10c&&_0x53b2e3['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x2aa10c&&_0x53b2e3['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x2aa10c&&_0x53b2e3['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x472cd5=this['repository']['getRevision'](0x0),_0x25071f=await this['getRevisionDocumentData'](_0x472cd5),_0xa366a5=await this['getRevisionRootsAttributes'](_0x472cd5);this['_replaceEditorDataWithRevisionData'](_0x25071f,_0xa366a5);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x2e9166){this['_source']=_0x2e9166;}async['update'](){const _0x564cba=await this['_source']['getLatestVersion']();if(_0x564cba>this['currentRevision']['toVersion']){await this['_loadState']();const _0x233eb3=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x564cba});_0x233eb3['authors']=_0x233eb3['authorsIds']['map'](_0x2c1f6c=>this['editor']['plugins']['get']('Users')['getUser'](_0x2c1f6c)),this['currentRevision']['_update'](_0x233eb3);}}async['saveRevision'](_0x4afc0d={},_0xb213a=null){const _0x29387b=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0xb213a>this['currentRevision']['toVersion']&&(_0xb213a=null),null===_0xb213a&&(_0xb213a=await this['_source']['getLatestVersion']());const _0x147d09=this['_getFromVersion'](_0xb213a),_0x4b008f=this['buildRevisionData']({'from':_0x147d09,'to':_0xb213a});if(this['currentRevision']['toVersion']<_0xb213a){const _0x3a62e2=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0xb213a,'to':_0xb213a});_0x3a62e2['authors']=[],_0x3a62e2['authorsIds']=[],_0x3a62e2['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x3a62e2,!0x0),delete _0x3a62e2['authors'],_0x29387b['push'](_0x3a62e2);}_0x4afc0d['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x4afc0d['name']=_0x4afc0d['name']||null,_0x4afc0d['id']=_0x4afc0d['id']||_0x9068c(),_0x4afc0d={..._0x4afc0d,..._0x4b008f};const _0x449a0c=this['addRevisionData'](_0x4afc0d);_0x29387b['push'](_0x4afc0d);const _0x5a1af1=this['repository']['getIndex'](_0x449a0c);if(0x0!==_0x5a1af1){const _0x54890d=this['repository']['getRevision'](_0x5a1af1-0x1);if(_0x54890d['fromVersion']!==_0xb213a){const _0x2f0374=this['_revisionDataBuilder']['getData'](_0xb213a,_0x54890d['toVersion']),_0x2dc778={'id':_0x54890d['id'],'diffData':_0x2f0374['diffData'],'authorsIds':_0x2f0374['authorsIds'],'authors':_0x2f0374['authorsIds']['map'](_0x47e0c7=>this['editor']['plugins']['get']('Users')['getUser'](_0x47e0c7)),'fromVersion':_0xb213a};_0x54890d===this['currentRevision']&&(_0x2dc778['createdAt']=new Date(_0x4afc0d['createdAt']['getTime']()+0xa)),_0x54890d['_update'](_0x2dc778,!0x0),delete _0x2dc778['authors'],_0x29387b['push'](_0x2dc778);}}if(this['adapter']){for(const _0x12014b of _0x29387b)this['_bufferUpdate'](_0x12014b['id'],_0x12014b,!0x0);this['sendBufferedUpdates']();}return _0x449a0c;}['addRevisionData'](_0x443572){const _0x3e94a1=this['repository']['createRevision'](_0x443572);return this['adapter']&&_0x3e94a1['on']('_update',(_0x1afe61,_0x6914e5,_0x166626)=>{_0x166626||(this['_bufferUpdate'](_0x6914e5['id'],_0x6914e5,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x3e94a1,this['_findInsertionIndex'](_0x3e94a1)),_0x3e94a1;}async['getRevisionDocumentData'](_0x4a4b29){return await this['_utils']['loadRevisionData'](_0x4a4b29,this['adapter']),this['_utils']['getRevisionDocumentData'](_0x4a4b29);}async['getRevisionRootsAttributes'](_0x5b64c5){return await this['_utils']['loadRevisionData'](_0x5b64c5,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x5b64c5);}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x25e884=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x4a1b5e=0x0;_0x4a1b5e<_0x25e884['length'];_0x4a1b5e++){const _0x58c5b0=_0x25e884[_0x4a1b5e];let _0x2994e3=!0x1;for(const _0x42d823 of Object['keys'](_0x58c5b0))void 0x0===_0x58c5b0[_0x42d823]?delete _0x58c5b0[_0x42d823]:'id'!==_0x42d823&&(_0x2994e3=!0x0);_0x2994e3||(_0x25e884[_0x4a1b5e]=null);}if(_0x25e884=_0x25e884['filter'](_0x5cf41a=>null!==_0x5cf41a),!_0x25e884['length'])return;for(let _0x55d29f=0x0;_0x55d29f<_0x25e884['length'];_0x55d29f++){const _0x1f60a0=_0x25e884[_0x55d29f];void 0x0!==_0x1f60a0['fromVersion']&&void 0x0===_0x1f60a0['toVersion']&&(_0x1f60a0['toVersion']=this['repository']['getRevision'](_0x1f60a0['id'])['toVersion']),void 0x0!==_0x1f60a0['toVersion']&&void 0x0===_0x1f60a0['fromVersion']&&(_0x1f60a0['fromVersion']=this['repository']['getRevision'](_0x1f60a0['id'])['fromVersion']);}const _0x149147=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x25e884,_0x149147)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x140663=>{if(_0x140663){for(const _0x29cbb5 of _0x140663)this['setRevisionData']({'id':_0x29cbb5['id'],'createdAt':_0x29cbb5['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['buildRevisionData']({revision:_0x18f3f5=null,from:_0x1c4826=null,to:_0x12835b=null}){_0x1c4826=null!==_0x1c4826?_0x1c4826:_0x18f3f5['fromVersion'],_0x12835b=null!==_0x12835b?_0x12835b:_0x18f3f5['toVersion'];const _0x465392=this['_revisionDataBuilder']['getData'](_0x1c4826,_0x12835b),_0xdd6000={'diffData':_0x465392['diffData'],'authorsIds':_0x465392['authorsIds'],'fromVersion':_0x1c4826,'toVersion':_0x12835b};if(!_0x18f3f5||_0x12835b!==_0x18f3f5['toVersion']){const _0x1dd96a=_0x12835b-0x1,_0x296b8f=this['_source']['history']['getOperation'](_0x1dd96a);_0xdd6000['createdAt']=_0x296b8f&&_0x296b8f['createdAt']||new Date();}if(this['_loadedStateData']&&_0x1c4826===this['_loadedStateData']['fromVersion']){for(const _0x4844bd of this['_loadedStateData']['authors'])_0xdd6000['authorsIds']['includes'](_0x4844bd['id'])||_0xdd6000['authorsIds']['push'](_0x4844bd['id']);}return _0xdd6000;}['_bufferUpdate'](_0x5d23e3,_0xd4b5da,_0x47d1e7){if(this['_bufferedUpdates']['has'](_0x5d23e3)){const _0x2315ce=this['_bufferedUpdates']['get'](_0x5d23e3);_0xd4b5da=_0x47d1e7?{..._0x2315ce,..._0xd4b5da}:{..._0xd4b5da,..._0x2315ce};}this['_bufferedUpdates']['set'](_0x5d23e3,_0xd4b5da);}['setRevisionData'](_0x365637){const _0x59eb7b=this['repository']['getRevision'](_0x365637['id']);if(_0x365637['createdAt']&&(_0x365637['createdAt']=new Date(_0x365637['createdAt'])),_0x365637['authorsIds']){const _0x363169=this['editor']['plugins']['get']('Users');_0x365637['authors']=_0x365637['authorsIds']['map'](_0x30eaac=>_0x363169['getUser'](_0x30eaac));}_0x59eb7b['_update'](_0x365637,!0x0);}['_createInitialRevision'](_0x4f2006){const _0x38f6f5=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x38f6f5)this['_initialRevisionId']=_0x38f6f5['id'];else{const _0x286063=!this['editor']['model']['document']['roots']['find'](_0x5daedd=>this['editor']['model']['hasContent'](_0x5daedd)),_0x54e483=this['editor']['plugins']['get']('Users')['me']['id'],_0x237818=m(this['editor']['locale'],_0x286063?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x4f2006,'to':_0x4f2006,'id':this['_initialRevisionId'],'name':_0x237818,'creatorId':_0x54e483});}}['_createCurrentRevision'](_0x178454){const _0xd85846=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0xd85846),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x178454,'to':_0x178454,'id':_0xd85846,'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'](_0x1b913a,_0x3a3a1c){let _0x55c7a1=this['editor']['config']['get']('initialData'),_0x5d8574=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x55c7a1){_0x55c7a1={};for(const _0x4b5f1e of this['editor']['model']['document']['getRootNames']())_0x55c7a1[_0x4b5f1e]='';}if('string'==typeof _0x55c7a1&&(_0x55c7a1={'main':_0x55c7a1}),void 0x0===_0x5d8574){_0x5d8574={};for(const _0x5079ad of this['editor']['model']['document']['getRootNames']())_0x5d8574[_0x5079ad]={};}let _0x5765e8=!0x1;const _0x114177=Object['keys'](_0x55c7a1),_0x22a361=Object['keys'](_0x1b913a);for(const _0xca27f7 of _0x114177){if(_0x55c7a1[_0xca27f7]!==_0x1b913a[_0xca27f7]&&''!==_0x55c7a1[_0xca27f7]['trim']()){_0x5765e8=!0x0;break;}if(!_0x11b9c0(_0x5d8574[_0xca27f7],_0x3a3a1c[_0xca27f7])&&Object['keys'](_0x5d8574[_0xca27f7])['length']>0x0){_0x5765e8=!0x0;break;}}_0x5765e8||(_0x5765e8=_0x22a361['some'](_0x32d66c=>!this['editor']['model']['document']['getRoot'](_0x32d66c))),_0x5765e8&&_0x117f74('editor-initial-data-replaced-with-revision-data',{'editorData':_0x55c7a1,'editorRootsAttributes':_0x5d8574,'revisionData':_0x1b913a,'revisionRootsAttributes':_0x3a3a1c}),this['editor']['config']['set']('initialData',_0x1b913a),this['editor']['config']['set']('rootsAttributes',_0x3a3a1c);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x1e3491=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x1e3491['add'](m(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x5bf0d7){const _0x2ea209=this['repository']['getRevisions']();_0x2ea209['reverse']();let _0x239c06=0x0;for(;_0x239c06<_0x2ea209['length'];){const _0x4c7b0b=_0x2ea209[_0x239c06];if(_0x4c7b0b===this['currentRevision']){_0x239c06++;continue;}if(_0x4c7b0b['id']===this['_initialRevisionId'])break;const _0xb8ec78=_0x5bf0d7['toVersion']-_0x4c7b0b['toVersion']||_0x5bf0d7['fromVersion']-_0x4c7b0b['fromVersion'];if(_0xb8ec78>0x0)break;if(_0xb8ec78<0x0)_0x239c06++;else{if(!_0x5bf0d7['creator']&&_0x4c7b0b['creator'])break;if(_0x4c7b0b['creator']||!_0x5bf0d7['creator']){if(_0x5bf0d7['createdAt']>_0x4c7b0b['createdAt'])break;_0x239c06++;}else _0x239c06++;}}return _0x239c06;}['_getFromVersion'](_0x13c2b3){const _0x480643=this['repository']['getRevisions']();_0x480643['reverse'](),_0x480643['shift']();const _0x41b06a=_0x480643['find'](_0xdf214f=>_0xdf214f['toVersion']<=_0x13c2b3)['toVersion'];return _0x41b06a<this['_startingVersion']?this['_startingVersion']:_0x41b06a;}['_makeRevision']({name:_0x385b03,from:_0x2afa13,to:_0x42b28e,creatorId:_0x1a64ca,id:_0x3d0600}){const _0x273bca=this['buildRevisionData']({'from':_0x2afa13,'to':_0x42b28e});_0x273bca['name']=_0x385b03,_0x273bca['creatorId']=_0x1a64ca,_0x273bca['id']=_0x3d0600;const _0x3259bd=this['addRevisionData'](_0x273bca);return this['adapter']&&this['_bufferUpdate'](_0x273bca['id'],_0x273bca,!0x0),_0x3259bd;}['_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(_0x3ccbef){this['editor']=_0x3ccbef,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'](_0x58fb02){this['source']=_0x58fb02;const _0x22fb18=new Map(),_0x336fcc=new Map(),_0x3a1690=this['editor']['model']['document']['roots']['map'](_0x59e63e=>_0x59e63e['rootName']);for(const _0x273072 of _0x3a1690){const _0x2be858=this['editor']['model']['document']['getRoot'](_0x273072),_0x8e959f=x(_0x2be858);_0x22fb18['set'](_0x273072,_0x8e959f),_0x336fcc['set'](_0x273072,Object['fromEntries'](_0x2be858['getAttributes']()));}const _0x20b3b6=Array['from'](this['editor']['model']['markers'])['map'](_0x485e10=>[_0x485e10['name'],_0x485e10['getRange']()]),_0x3f3004=this['source']['version'];this['_saveMetaData'](_0x3f3004,_0x22fb18,_0x20b3b6,_0x336fcc),this['_startingRevisionId']=this['_revisionId'];const _0x1f627a=new Map(),_0x65eae=new Map();for(const _0x532cf2 of _0x3a1690){const _0x2eb5cb=N(_0x532cf2);_0x1f627a['set'](_0x532cf2,_0x2eb5cb),_0x65eae['set'](_0x532cf2,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x1f627a,[],_0x65eae);}['getData'](_0xd78820,_0x2d91a5){if(this['_lastFrom']===_0xd78820&&this['_lastTo']<=_0x2d91a5)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x2d91a5,!0x0);else{if(!this['_savedMetaData']['has'](_0xd78820)){const _0x2e91a5=this['_getPreviousFrom'](_0xd78820);this['_calculateMetaData'](_0x2e91a5,_0xd78820,!0x1);}this['_calculateMetaData'](_0xd78820,_0x2d91a5,!0x0);}return this['_lastFrom']=_0xd78820,this['_lastTo']=_0x2d91a5,this['_getState']();}['loadState'](_0x554dcc){if(!this['_savedMetaData']['has'](_0x554dcc['fromVersion'])){const _0x38e03d=this['_getPreviousFrom'](_0x554dcc['fromVersion']);this['_calculateMetaData'](_0x38e03d,_0x554dcc['fromVersion'],!0x1);}this['_calculateMetaData'](_0x554dcc['fromVersion'],_0x554dcc['toVersion'],!0x1);const _0x582789=this['editor']['plugins']['get']('RevisionHistoryUtils');this['_reset'](),this['_lastFrom']=_0x554dcc['fromVersion'],this['_lastTo']=_0x554dcc['toVersion'];for(const _0x619f2e in _0x554dcc['diffData']){const _0x43567a=_0x554dcc['diffData'][_0x619f2e]['attachChange'],_0x2ebf50=_0x42245c(_0x554dcc['diffData'][_0x619f2e]['attributesBefore'])||{},_0x6a0b8b=_0x582789['_makeModelFromViewString'](_0x554dcc['diffData'][_0x619f2e]['deletions']);_0x6a0b8b['rootName']=_0x619f2e,_0x6a0b8b['_isAttached']=!_0x43567a||!_0x43567a['isAttached'],_0x6a0b8b['isAttached']=()=>_0x6a0b8b['_isAttached'],this['_baseRoots']['set'](_0x619f2e,_0x6a0b8b),this['_baseRootsAttributes']['set'](_0x619f2e,_0x2ebf50),_0x43567a&&this['_touchedRoots']['set'](_0x619f2e,_0x43567a);const _0x578cda=this['_makeIdsRoot'](_0x6a0b8b);this['_baseIdsRoots']['set'](_0x619f2e,_0x578cda);for(const [_0x22d990,_0x20c49a]of _0x6a0b8b['markers']){if(!_0x22d990['startsWith']('revision:'))continue;const _0x56a32a=_0x22d990['split'](':')[0x2];for(const _0x75eba2 of _0x20c49a['getWalker']({'singleCharacters':!0x0})){const _0x496de3=this['_getVidAttributeName'](_0x75eba2),_0x4ffd9c='elementEnd'==_0x75eba2['type']?_0x75eba2['previousPosition']['path']['slice'](0x0,-0x1):_0x75eba2['previousPosition']['path'],_0x5bcb63=_0x578cda['getNodeByPath'](_0x4ffd9c)['getAttribute'](_0x496de3);this['_touched']['set'](_0x5bcb63,{'userId':_0x56a32a});}_0x6a0b8b['markers']['delete'](_0x22d990);}}this['_startingRevisionId']=this['_revisionId'];const _0x5071cc=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x3fe1a5=>!this['_touched']['has'](_0x3fe1a5));let _0x2ecc9e=0x0;const _0x29e8e4=new Map();for(const _0x5bd839 in _0x554dcc['diffData']){const _0x1ce77a=_0x554dcc['diffData'][_0x5bd839]['attachChange'],_0x277025=_0x42245c(_0x554dcc['diffData'][_0x5bd839]['attributesAfter'])||{},_0x2ea66b=_0x582789['_makeModelFromViewString'](_0x554dcc['diffData'][_0x5bd839]['insertions']);_0x2ea66b['rootName']=_0x5bd839,_0x2ea66b['_isAttached']=!_0x1ce77a||_0x1ce77a['isAttached'],_0x2ea66b['isAttached']=()=>_0x2ea66b['_isAttached'],this['_diffRoots']['set'](_0x5bd839,_0x2ea66b),this['_diffRootsAttributes']['set'](_0x5bd839,_0x277025);const _0x1c556a=this['_makeIdsRoot'](_0x2ea66b,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x5bd839,_0x1c556a),_0x29e8e4['set'](_0x5bd839,_0x2ea66b['isAttached']()?_0x277025:{});for(const [_0x56f912,_0x529eb3]of _0x2ea66b['markers']){if(!_0x56f912['startsWith']('revision:'))continue;const _0x44e675=_0x56f912['split'](':')[0x2];for(const _0x30da31 of _0x529eb3['getWalker']({'singleCharacters':!0x0})){const _0x2fabc2=this['_getVidAttributeName'](_0x30da31),_0x4cbfd2=this['_revisionId']++,_0x57654a='elementEnd'==_0x30da31['type']?_0x30da31['previousPosition']['path']['slice'](0x0,-0x1):_0x30da31['previousPosition']['path'];_0x1c556a['getNodeByPath'](_0x57654a)['_setAttribute'](_0x2fabc2,_0x4cbfd2),this['_touched']['set'](_0x4cbfd2,{'userId':_0x44e675});}_0x2ea66b['markers']['delete'](_0x56f912);}for(const _0x57501b of this['editor']['model']['createRangeIn'](_0x2ea66b)['getWalker']({'singleCharacters':!0x0})){const _0x2fc4ee=this['_getVidAttributeName'](_0x57501b),_0x4d0434='elementEnd'==_0x57501b['type']?_0x57501b['previousPosition']['path']['slice'](0x0,-0x1):_0x57501b['previousPosition']['path'],_0x16d917=_0x1c556a['getNodeByPath'](_0x4d0434);_0x16d917['getAttribute'](_0x2fc4ee)>0x0||_0x16d917['_setAttribute'](_0x2fc4ee,_0x5071cc[_0x2ecc9e++]);}for(const [_0xade7f2,_0x59e926]of _0x2ea66b['markers'])_0xade7f2['startsWith']('revision:')||this['_markers']['set'](_0xade7f2,_0x59e926);}const {roots:_0x1a630d}=this['_savedMetaData']['get'](_0x554dcc['fromVersion']),{roots:_0x15afd7}=this['_savedMetaData']['get'](_0x554dcc['toVersion']),_0x2c6f33=x(_0x1a630d['get']('$graveyard'));this['_baseRoots']['set']('$graveyard',_0x2c6f33),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x2c6f33,Number['NEGATIVE_INFINITY']));const _0x1d6d58=x(_0x15afd7['get']('$graveyard'));this['_diffRoots']['set']('$graveyard',_0x1d6d58),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x1d6d58));const _0x3ab804=Array['from'](this['_diffRoots'])['map'](([_0xefee72,_0xa50949])=>[_0xefee72,x(_0xa50949)]);this['_saveMetaData'](this['_lastTo'],_0x3ab804,this['_markers'],_0x29e8e4);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_saveMetaData'](_0x1b22ca,_0xe31349,_0x51dee0,_0x18df0a){const _0x25cb5b=new Map(_0xe31349),_0x45700a=new Map(_0x42245c(_0x18df0a)),_0x3f9b8b=new Map();for(const [_0x1250aa,_0xac4da]of _0x51dee0)_0x3f9b8b['set'](_0x1250aa,{'start':_0xac4da['start']['clone'](),'end':_0xac4da['end']['clone'](),'rootName':_0xac4da['root']['rootName']});this['_savedMetaData']['set'](_0x1b22ca,{'roots':_0x25cb5b,'markers':_0x3f9b8b,'rootsAttributes':_0x45700a});}['_removeMetaData'](_0x22ddfd){this['_savedMetaData']['delete'](_0x22ddfd);}['_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'](_0x190279,_0x1004c5=null){let _0x481b59=null;_0x190279['is']('documentFragment')||(_0x481b59=new _0x5600a1(_0x190279['name'],{'vid_start':null===_0x1004c5?this['_revisionId']++:_0x1004c5++}));const _0x40c247=[];for(const _0x37a506 of _0x190279['getChildren']())if(_0x37a506['is']('element')){_0x40c247['push'](this['_makeIdsRoot'](_0x37a506,_0x1004c5));const _0x35a759=_0x40c247[_0x40c247['length']-0x1];null!==_0x1004c5&&(_0x1004c5=_0x35a759['is']('element','$text')?_0x35a759['getAttribute']('vid')+0x1:_0x35a759['getAttribute']('vid_end')+0x1);}else{for(let _0x40d281=0x0;_0x40d281<_0x37a506['offsetSize'];_0x40d281++)_0x40c247['push'](new _0x5600a1('$text',{'vid':null===_0x1004c5?this['_revisionId']++:_0x1004c5++}));}if(_0x190279['is']('documentFragment')){const _0x14f6aa=N(_0x190279['rootName']);return _0x14f6aa['_insertChild'](0x0,_0x40c247),_0x14f6aa;}return _0x481b59['_setAttribute']('vid_end',null===_0x1004c5?this['_revisionId']++:_0x1004c5++),_0x481b59['_insertChild'](0x0,_0x40c247),_0x481b59;}['_calculateMetaData'](_0x2bb68e,_0x15c460,_0x424630){this['_reset']();const {roots:_0x33c8dd,markers:_0x241027,rootsAttributes:_0xaccbdd}=this['_savedMetaData']['get'](_0x2bb68e);this['_baseRoots']=new Map(_0x33c8dd),this['_baseRootsAttributes']=new Map(_0x42245c(_0xaccbdd));for(const [_0x32e164,_0x3c2ef9]of this['_baseRoots'])if('$graveyard'!==_0x32e164&&(this['_diffRoots']['set'](_0x32e164,x(_0x3c2ef9)),this['_diffRootsAttributes']=new Map(_0x42245c(_0xaccbdd)),_0x424630)){const _0xe8a201=this['_revisionId'];this['_idsRoots']['set'](_0x32e164,this['_makeIdsRoot'](_0x3c2ef9)),this['_baseIdsRoots']['set'](_0x32e164,this['_makeIdsRoot'](_0x3c2ef9,_0xe8a201));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',x(this['_baseRoots']['get']('$graveyard'))),_0x424630&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x53ac3b,_0x4004da]of _0x241027){const _0x2abeb9=this['_baseRoots']['get'](_0x4004da['rootName']),_0x1568fa=this['_diffRoots']['get'](_0x4004da['rootName']),_0x29ff39=new _0x5d4c4b(this['_fixPosition'](_0x4004da['start'],_0x2abeb9),this['_fixPosition'](_0x4004da['end'],_0x2abeb9)),_0x42e0ce=this['_fixRange'](_0x29ff39,_0x1568fa);_0x2abeb9['markers']['set'](_0x53ac3b,_0x29ff39),this['_markers']['set'](_0x53ac3b,_0x42e0ce);}this['_applyOperations'](_0x2bb68e,_0x15c460,_0x424630);}['_applyOperations'](_0x45b5a8,_0xcdb0f6,_0x325638){for(const _0x37d13f of this['source']['getOperations'](_0x45b5a8,_0xcdb0f6))this['_handleOperation'](_0x37d13f,_0x325638);for(const _0xc0aed2 of this['_diffRoots']['values']())_0xc0aed2['markers']['clear']();for(const [_0x400f74,_0x2d10e5]of this['_markers']){this['_diffRoots']['get'](_0x2d10e5['root']['rootName'])['markers']['set'](_0x400f74,_0x2d10e5['clone']());}const _0x293f9b=new Map(),_0x52c940=new Map();for(const [_0x36d0d7,_0x2ca590]of this['_diffRoots'])_0x293f9b['set'](_0x36d0d7,x(_0x2ca590)),_0x52c940['set'](_0x36d0d7,this['_diffRootsAttributes']['get'](_0x36d0d7));this['_saveMetaData'](_0xcdb0f6,_0x293f9b,this['_markers'],_0x52c940);}['_getPreviousFrom'](_0x221df2){const _0x3bc8a7=Array['from'](this['_savedMetaData']['keys']());_0x3bc8a7['sort']((_0x252429,_0x36924b)=>_0x252429-_0x36924b),_0x3bc8a7['reverse']();for(const _0x5aeecb of _0x3bc8a7)if(_0x5aeecb<_0x221df2)return _0x5aeecb;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x2cc720,_0x15d0fc){const _0x2ee1d7=Array['from'](_0x15d0fc['markers'])['map'](([_0x34fe5e,_0x22f07a])=>[_0x34fe5e,this['_fixRange'](_0x22f07a,_0x2cc720)]);_0x2cc720['markers']=new Map(_0x2ee1d7);}['_transformMarkers'](_0x4f7e52){for(const _0x4a28f1 of this['_markers']['values']()){const _0x4cab98=_0x4a28f1['getTransformedByOperation'](_0x4f7e52),_0x11d7c4=_0x5d4c4b['_createFromRanges'](_0x4cab98);_0x4a28f1['start']=_0x11d7c4['start'],_0x4a28f1['end']=_0x11d7c4['end'];}}['_handleOperation'](_0x209a14,_0x58b16c){if('addRoot'!=_0x209a14['type']&&'detachRoot'!=_0x209a14['type']){if('insert'==_0x209a14['type']){const _0x1c17b3=_0x209a14['position']['root']['rootName'];this['_diffRoots']['has'](_0x1c17b3)||(this['_diffRoots']['set'](_0x1c17b3,N(_0x1c17b3,!0x0)),this['_diffRootsAttributes']['set'](_0x1c17b3,{}),_0x58b16c&&this['_idsRoots']['set'](_0x1c17b3,N(_0x1c17b3,!0x0)));}else{if('addRootAttribute'==_0x209a14['type']||'removeRootAttribute'==_0x209a14['type']||'changeRootAttribute'==_0x209a14['type'])return void this['_handleRootAttributeOperation'](_0x209a14);'marker'==_0x209a14['type']&&this['_handleMarkerOperation'](_0x209a14);}if('marker'!==_0x209a14['type']){const _0x534ccf=this['_cloneOperation'](_0x209a14,this['_diffRoots']);_0x534ccf['_execute'](),this['_transformMarkers'](_0x534ccf);}if(_0x58b16c)switch(_0x209a14['type']){case'insert':this['_handleInsertOperation'](_0x209a14);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x209a14);break;case'merge':this['_handleMergeOperation'](_0x209a14);break;case'split':this['_handleSplitOperation'](_0x209a14);}}else this['_handleRootOperation'](_0x209a14,_0x58b16c);}['_cloneOperation'](_0x43fa54,_0x321482){const _0x47d1f3=_0x43fa54['clone']();return _0x47d1f3['_authorId']=_0x43fa54['_authorId'],this['_fixOperation'](_0x47d1f3,_0x321482),_0x47d1f3;}['_getBaseVids'](_0x1bd50b){return _0x1bd50b['map'](_0x598573=>{const _0x96e420=this['_getVidAttributeName'](_0x598573);return Number(_0x598573['item']['getAttribute'](_0x96e420));});}['_generateTape'](_0x482d14,_0x1094f9){if(_0x482d14['is']('element','$text'))_0x1094f9['push']({'item':_0x482d14,'type':'text'});else{_0x482d14['is']('element')&&_0x1094f9['push']({'item':_0x482d14,'type':'elementStart'});for(const _0x40aa3b of _0x482d14['getChildren']())this['_generateTape'](_0x40aa3b,_0x1094f9);_0x482d14['is']('element')&&_0x1094f9['push']({'item':_0x482d14,'type':'elementEnd'});}return _0x1094f9;}['_getState'](){const _0x38d98e=new Map(this['_touched']),_0x2a18ea=new Map(_0x38d98e),_0x4c9845=new Map(),_0x472c9e={'insertions':{},'deletions':{}},_0x317ee8={'insertions':{},'deletions':{}},_0xa502f6=new Map(),_0x2f797d=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x2f797d['delete']('$graveyard');for(const _0x42196d of _0x2f797d){const _0x3eca5a=this['_diffRoots']['get'](_0x42196d)||N(_0x42196d,!0x1),_0x4b1bc7=this['_baseRoots']['get'](_0x42196d)||N(_0x42196d,!0x1);_0x3eca5a['isAttached']()||_0x4b1bc7['isAttached']()?(_0x472c9e['insertions'][_0x42196d]=x(_0x3eca5a),_0x472c9e['deletions'][_0x42196d]=x(_0x4b1bc7),this['_copyMarkers'](_0x472c9e['deletions'][_0x42196d],_0x4b1bc7),this['_copyMarkers'](_0x472c9e['insertions'][_0x42196d],_0x3eca5a),_0x317ee8['insertions'][_0x42196d]=this['_generateTape'](this['_idsRoots']['get'](_0x42196d),[]),_0x317ee8['deletions'][_0x42196d]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x42196d)||N(_0x42196d,!0x1),[])):_0x2f797d['delete'](_0x42196d);}for(const _0x75ac99 of _0x2f797d){const _0x37875c=_0x317ee8['insertions'][_0x75ac99];for(const _0x383aac of _0x37875c){const _0x4c1998=this['_getVidAttributeName'](_0x383aac),_0x2ddcde=_0x383aac['item']['getAttribute'](_0x4c1998);_0x2a18ea['delete'](_0x2ddcde),_0x2ddcde>=this['_startingRevisionId']&&_0x4c9845['set'](_0x2ddcde,_0x38d98e['get'](_0x2ddcde));}}for(const _0x59979e of _0x2f797d){const _0x157a06=_0x317ee8['insertions'][_0x59979e],_0x23ee86=this['_getBaseVids'](_0x317ee8['deletions'][_0x59979e]);let _0x370b4e=0x0;for(const _0x237040 of _0x157a06){const _0x4ba771=this['_getVidAttributeName'](_0x237040),_0x68fb03=_0x237040['item']['getAttribute'](_0x4ba771);if(!_0x4c9845['has'](_0x68fb03)&&!_0xa502f6['has'](_0x68fb03)){if(_0x2a18ea['has'](_0x68fb03))_0x370b4e++;else{if(_0x68fb03!=_0x23ee86[_0x370b4e]){const _0x36237e=_0x38d98e['get'](_0x68fb03)||_0x38d98e['get'](_0x23ee86[_0x370b4e]);for(;_0x68fb03!=_0x23ee86[_0x370b4e];)_0x2a18ea['has'](_0x23ee86[_0x370b4e])||(_0xa502f6['set'](_0x23ee86[_0x370b4e],_0x36237e),_0x38d98e['set'](_0x23ee86[_0x370b4e],_0x36237e)),_0x370b4e++;}_0x370b4e++;}}}}for(const _0x47519e of _0x2f797d){const _0x19e0f6=_0x317ee8['insertions'][_0x47519e];for(const _0x45845d of _0x19e0f6){const _0x571109=this['_getVidAttributeName'](_0x45845d),_0x593758=_0x45845d['item']['getAttribute'](_0x571109);if(_0xa502f6['has'](_0x593758)){const _0x4f8d6e=_0xa502f6['get'](_0x593758);_0x2a18ea['has'](_0x593758)||_0x2a18ea['set'](_0x593758,{..._0x4f8d6e}),_0x4c9845['set'](_0x593758,{..._0x4f8d6e});}}}for(const _0x4b9ab2 of _0x2a18ea['keys']())_0x4b9ab2>=this['_startingRevisionId']&&_0x2a18ea['delete'](_0x4b9ab2);const _0x23469e=new Map();for(const _0x49b25a of _0x2f797d){let _0x38f14e=_0x317ee8['insertions'][_0x49b25a];for(const _0x14d88a of _0x38f14e)if(_0x14d88a['item']['is']('element','tableCell')){const _0x54121d=this['_getVidAttributeName'](_0x14d88a),_0x23e773=_0x14d88a['item']['getAttribute'](_0x54121d);if(_0x4c9845['has'](_0x23e773)){const _0x440fb8=_0x14d88a['item']['parent']['parent']['getAttribute']('vid_start'),_0xf7b694=_0x23469e['get'](_0x440fb8)||new Set();_0xf7b694['add'](_0x4c9845['get'](_0x23e773)['userId']),_0x23469e['set'](_0x440fb8,_0xf7b694);}}_0x38f14e=_0x317ee8['deletions'][_0x49b25a];for(const _0x3b57f7 of _0x38f14e)if(_0x3b57f7['item']['is']('element','tableCell')){const _0x15acfc=this['_getVidAttributeName'](_0x3b57f7),_0x2e1af4=_0x3b57f7['item']['getAttribute'](_0x15acfc);if(_0x2a18ea['has'](_0x2e1af4)){const _0x42f464=_0x3b57f7['item']['parent']['parent']['getAttribute']('vid_start'),_0x413d5e=_0x23469e['get'](_0x42f464)||new Set();_0x413d5e['add'](_0x2a18ea['get'](_0x2e1af4)['userId']),_0x23469e['set'](_0x42f464,_0x413d5e);}}for(const _0x3e35f6 of _0x23469e['keys']())(_0x4c9845['has'](_0x3e35f6)||_0x2a18ea['has'](_0x3e35f6))&&_0x23469e['delete'](_0x3e35f6);}for(const _0x50f418 of _0x2f797d){const _0x8e6b19=_0x317ee8['insertions'][_0x50f418];let _0x5ec796=null,_0x56ff31=null;for(const _0x4c147d of _0x8e6b19){const _0x55f2b2=this['_getVidAttributeName'](_0x4c147d),_0x47be84=_0x4c147d['item']['getAttribute'](_0x55f2b2),_0x5f49bd=_0x23469e['get'](_0x47be84);_0x5f49bd&&'elementStart'==_0x4c147d['type']&&(_0x5ec796=Array['from'](_0x5f49bd)[0x0],_0x56ff31=_0x4c147d['item']['getAttribute']('vid_end')),_0x5ec796&&(_0x2a18ea['set'](_0x47be84,{'userId':_0x5ec796}),_0x4c9845['set'](_0x47be84,{'userId':_0x5ec796})),_0x47be84==_0x56ff31&&(_0x5ec796=null,_0x56ff31=null);}}const _0x304569={},_0x3182ac=new Set();for(const _0xbc7b72 of _0x2f797d){const _0x25cfd0=_0x472c9e['deletions'][_0xbc7b72],_0x2d4fd2=_0x472c9e['insertions'][_0xbc7b72];for(const {userId:_0x238d40}of this['_touchedMarkers']['values']())null!==_0x238d40&&_0x3182ac['add'](_0x238d40);for(const {userId:_0x5b9a77}of this['_touchedRoots']['values']())null!==_0x5b9a77&&_0x3182ac['add'](_0x5b9a77);this['_markChanges'](_0x2d4fd2,_0x317ee8['insertions'][_0xbc7b72],_0x4c9845,'insertion',_0x3182ac),this['_markChanges'](_0x25cfd0,_0x317ee8['deletions'][_0xbc7b72],_0x2a18ea,'deletion',_0x3182ac),_0x304569[_0xbc7b72]={'insertions':this['_prepareViewToSave'](_0x2d4fd2),'deletions':this['_prepareViewToSave'](_0x25cfd0),'attachChange':this['_touchedRoots']['get'](_0xbc7b72)||null,'attributesBefore':_0x42245c(this['_baseRootsAttributes']['get'](_0xbc7b72))||{},'attributesAfter':_0x42245c(this['_diffRootsAttributes']['get'](_0xbc7b72))};}return{'diffData':_0x304569,'authorsIds':Array['from'](_0x3182ac)};}['_processRootBeforeSave'](_0x5b4a2a){for(const [,_0x290b68]of _0x5b4a2a['markers']){const _0x2976b2=_0x290b68['start']['getAncestors']()['filter'](_0x26baa6=>'tableCell'==_0x26baa6['name']);for(const _0x1bb2eb of _0x2976b2)0x1==_0x1bb2eb['childCount']&&_0x1bb2eb['getChild'](0x0)['is']('element','paragraph')&&_0x1bb2eb['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x3e7897){this['_processRootBeforeSave'](_0x3e7897);const _0x5e9b07=this['editor']['data']['toView'](_0x3e7897,{}),_0x28680=Array['from'](_0x5e9b07['getChildren']())['map'](_0x16e23c=>this['_getViewJson'](_0x16e23c));return JSON['stringify'](_0x28680);}['_getViewJson'](_0x9736f6){if(_0x9736f6['is']('$text'))return _0x9736f6['data'];{const _0x1f1732=this['editor']['plugins']['get']('RevisionHistoryUtils'),_0x17bc97=_0x9736f6,_0x18ceeb=this['editor']['data']['htmlProcessor']['domConverter'],_0x575677={'type':_0x1f1732['_getTypeCharForViewElement'](_0x17bc97),'name':_0x17bc97['name'],'attributes':Array['from'](_0x17bc97['getAttributes']()),'children':Array['from'](_0x17bc97['getChildren']())['map'](_0x3cac96=>this['_getViewJson'](_0x3cac96))};if(_0x9736f6['is']('uiElement')&&'$comment'!=_0x9736f6['name']){const _0x7039f0=_0x9736f6['render'](_0x18ceeb['domDocument'],_0x18ceeb);_0x575677['children']['push'](_0x7039f0['outerHTML']);}else{if(_0x9736f6['is']('rawElement')){const _0x3b59db=_0x18ceeb['domDocument']['createElement'](_0x17bc97['name']);_0x9736f6['render'](_0x3b59db,_0x18ceeb),_0x575677['children']['push'](_0x3b59db['innerHTML']);}}const _0x1b5017=Array['from'](_0x17bc97['getCustomProperties']());_0x1b5017['length']>0x0&&(_0x575677['customProperties']=_0x1b5017);const _0x4f8b57=_0x17bc97['getFillerOffset']();return null!==_0x4f8b57&&(_0x575677['fillerOffset']=_0x4f8b57),_0x575677;}}['_markChanges'](_0x4bb29f,_0x5c7889,_0x21fadb,_0x43b0bc,_0x412d2a){let _0x2759fa=null,_0x530157=null,_0xa7bced=0x0;const _0xed6b36=this['editor']['model'];for(let _0x47d766=0x0;_0x47d766<_0x5c7889['length'];_0x47d766++){const _0x1937a3=this['_getVidAttributeName'](_0x5c7889[_0x47d766]),_0x362481=_0x5c7889[_0x47d766]['item']['getAttribute'](_0x1937a3),_0x10d65f=_0x21fadb['get'](_0x362481),_0xd5bd34=_0x47d766==_0x5c7889['length']-0x1;(!_0x2759fa&&_0x10d65f&&(_0x2759fa=_0x10d65f,_0x530157=_0x5c7889[_0x47d766]),_0x2759fa&&(!_0x10d65f||_0x10d65f['userId']!=_0x2759fa['userId']))&&(_0x35c840(_0x10d65f,P(_0x530157,_0x4bb29f,_0xed6b36),P(_0x5c7889[_0x47d766],_0x4bb29f,_0xed6b36)),_0x2759fa=_0x10d65f||null,_0x530157=_0x10d65f?_0x5c7889[_0x47d766]:null),_0x2759fa&&_0xd5bd34&&_0x35c840(_0x10d65f,P(_0x530157,_0x4bb29f,_0xed6b36),V(_0x5c7889[_0x47d766],_0x4bb29f,_0xed6b36));}function _0x35c840(_0x5de976,_0x22de7c,_0x2ed6b4){const _0x474942=_0x2759fa['userId'],_0x339432='revision:'+_0x43b0bc+':'+_0x474942+':'+_0xa7bced++,_0x2720c5=_0xed6b36['createRange'](_0x22de7c,_0x2ed6b4);_0x4bb29f['markers']['set'](_0x339432,_0x2720c5),null!==_0x474942&&_0x412d2a['add'](_0x474942);}}['_getVidAttributeName'](_0x270b33){switch(_0x270b33['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x4ab497,_0x2d8332){_0x4ab497['baseVersion']=null;for(const _0x5ccdd5 in _0x4ab497){const _0x210505=_0x4ab497[_0x5ccdd5];if(_0x210505 instanceof _0x4f0201){const _0x21e351=_0x2d8332['get'](_0x210505['root']['rootName']);_0x4ab497[_0x5ccdd5]=this['_fixPosition'](_0x210505,_0x21e351);}if(_0x210505 instanceof _0x5d4c4b){const _0x1fe192=_0x2d8332['get'](_0x210505['root']['rootName']);_0x4ab497[_0x5ccdd5]=this['_fixRange'](_0x210505,_0x1fe192);}'root'===_0x5ccdd5&&(_0x4ab497['root']=_0x2d8332['get'](_0x4ab497['root']['rootName']));}}['_fixRange'](_0x2f844b,_0x3217e6){return this['editor']['model']['createRange'](this['_fixPosition'](_0x2f844b['start'],_0x3217e6),this['_fixPosition'](_0x2f844b['end'],_0x3217e6));}['_fixPosition'](_0x158339,_0xcc08e0){return this['editor']['model']['createPositionFromPath'](_0xcc08e0,_0x158339['path'],_0x158339['stickiness']);}['_handleInsertOperation'](_0x3156bc){const _0x5e66cc=this['_idsRoots']['get'](_0x3156bc['position']['root']['rootName']),_0x479460=this['_fixPosition'](_0x3156bc['position'],_0x5e66cc),_0x5ad7c3=null===_0x3156bc['_authorId']?null:_0x3156bc['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x50dee3=_0x479460['parent'],_0x42bd1c=this['_revisionId'],_0x13fa01=[];for(const _0x51c20c of _0x3156bc['nodes'])if(_0x51c20c['is']('element'))_0x13fa01['push'](this['_makeIdsRoot'](_0x51c20c));else{for(let _0x454fb1=0x0;_0x454fb1<_0x51c20c['offsetSize'];_0x454fb1++)_0x13fa01['push'](new _0x5600a1('$text',{'vid':this['_revisionId']++}));}const _0xb7344f=this['_revisionId'];for(let _0x2133fd=_0x42bd1c;_0x2133fd<_0xb7344f;_0x2133fd++)this['_touched']['set'](_0x2133fd,{'userId':_0x5ad7c3});_0x50dee3['_insertChild'](_0x479460['offset'],_0x13fa01);}['_handleMoveOperation'](_0x50f66c){(_0x50f66c=this['_cloneOperation'](_0x50f66c,this['_idsRoots']))['_execute']();const _0x26455c=null===_0x50f66c['_authorId']?null:_0x50f66c['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x51370d=_0x50f66c['getMovedRangeStart'](),_0x55f562=_0x51370d['parent'],_0xef3568=_0x51370d['offset'];!function _0x5227f1(_0x58f4c3,_0x164fda,_0x15f526,_0x839e2e){for(let _0x457ff7=_0x15f526;_0x457ff7<_0x839e2e;_0x457ff7++){const _0x25bd45=_0x164fda['getChild'](_0x457ff7);_0x25bd45['is']('element','$text')?_0x58f4c3['set'](_0x25bd45['getAttribute']('vid'),{'userId':_0x26455c}):(_0x58f4c3['set'](_0x25bd45['getAttribute']('vid_start'),{'userId':_0x26455c}),_0x5227f1(_0x58f4c3,_0x25bd45,0x0,_0x25bd45['childCount']),_0x58f4c3['set'](_0x25bd45['getAttribute']('vid_end'),{'userId':_0x26455c}));}}(this['_touched'],_0x55f562,_0xef3568,_0xef3568+_0x50f66c['howMany']);}['_handleMergeOperation'](_0x114762){const _0x2b7240=null===(_0x114762=this['_cloneOperation'](_0x114762,this['_idsRoots']))['_authorId']?null:_0x114762['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x5c2203=_0x114762['targetPosition']['parent'],_0x4dfc41=_0x114762['sourcePosition']['parent'],_0x3d4598=_0x5c2203['getAttribute']('vid_end'),_0x26bc04=_0x4dfc41['getAttribute']('vid_start');_0x5c2203['_setAttribute']('vid_end',_0x4dfc41['getAttribute']('vid_end')),_0x4dfc41['_setAttribute']('vid_end',_0x3d4598),this['_touched']['set'](_0x26bc04,{'userId':_0x2b7240}),this['_touched']['set'](_0x3d4598,{'userId':_0x2b7240}),_0x114762['_execute']();}['_handleSplitOperation'](_0x6c147f){const _0x1e7880=null===(_0x6c147f=this['_cloneOperation'](_0x6c147f,this['_idsRoots']))['_authorId']?null:_0x6c147f['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0xed648=_0x6c147f['graveyardPosition'],_0x42d142=_0x6c147f['splitPosition']['parent'];_0x6c147f['_execute']();const _0x19f8f2=_0x42d142['getAttribute']('vid_end'),_0x13f018=_0x6c147f['insertionPosition']['nodeAfter'];if(_0xed648){const _0x3e165e=_0x13f018['getAttribute']('vid_end'),_0x484a0c=_0x42d142['getAttribute']('vid_end');_0x42d142['_setAttribute']('vid_end',_0x3e165e),_0x13f018['_setAttribute']('vid_end',_0x484a0c),this['_touched']['set'](_0x42d142['getAttribute']('vid_end'),{'userId':_0x1e7880}),this['_touched']['set'](_0x13f018['getAttribute']('vid_start'),{'userId':_0x1e7880});}else{const _0x207f0e=this['_revisionId']++,_0x52e2cf=this['_revisionId']++;_0x42d142['_setAttribute']('vid_end',_0x207f0e),_0x13f018['_setAttribute']('vid_start',_0x52e2cf),_0x13f018['_setAttribute']('vid_end',_0x19f8f2),this['_touched']['set'](_0x207f0e,{'userId':_0x1e7880}),this['_touched']['set'](_0x52e2cf,{'userId':_0x1e7880});}}['_handleMarkerOperation'](_0x25bb6a){if(!_0x25bb6a['affectsData'])return;const _0x59720e=(_0x25bb6a=this['_cloneOperation'](_0x25bb6a,this['_diffRoots']))['oldRange']?_0x25bb6a['oldRange']['root']:null,_0x427b2f=_0x25bb6a['newRange']?_0x25bb6a['newRange']['root']:null;_0x59720e&&this['_markers']['delete'](_0x25bb6a['name']),_0x427b2f&&this['_markers']['set'](_0x25bb6a['name'],_0x25bb6a['newRange']['clone']());const _0x471251=null===_0x25bb6a['_authorId']?null:_0x25bb6a['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x4c6620=_0x25bb6a['name'];if(!this['_touchedMarkers']['has'](_0x4c6620))return void this['_touchedMarkers']['set'](_0x4c6620,{'range':_0x25bb6a['oldRange'],'userId':_0x471251});const _0x67cc8f=this['_touchedMarkers']['get'](_0x4c6620),_0x528c77=_0x67cc8f['range'],_0x14ee75=_0x25bb6a['newRange'];null==_0x528c77&&null==_0x14ee75||_0x528c77&&_0x14ee75&&_0x528c77['isEqual'](_0x14ee75)?this['_touchedMarkers']['delete'](_0x25bb6a['name']):_0x67cc8f['userId']=_0x471251;}['_handleRootOperation'](_0x31f649,_0xf5b4fd){this['_diffRoots']['has'](_0x31f649['rootName'])?this['_diffRoots']['get'](_0x31f649['rootName'])['_isAttached']=_0x31f649['isAdd']:(this['_diffRoots']['set'](_0x31f649['rootName'],N(_0x31f649['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x31f649['rootName'],{}),_0xf5b4fd&&this['_idsRoots']['set'](_0x31f649['rootName'],N(_0x31f649['rootName'],!0x0)));const _0x5a9d88=null===_0x31f649['_authorId']?null:_0x31f649['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x41360c=this['_touchedRoots']['get'](_0x31f649['rootName']);_0x41360c&&_0x41360c['userId']===_0x5a9d88?this['_touchedRoots']['delete'](_0x31f649['rootName']):this['_touchedRoots']['set'](_0x31f649['rootName'],{'userId':_0x5a9d88,'isAttached':_0x31f649['isAdd']});}['_handleRootAttributeOperation'](_0x3a5de4){const _0x33b365=this['_diffRootsAttributes']['get'](_0x3a5de4['root']['rootName']);null===_0x3a5de4['newValue']?delete _0x33b365[_0x3a5de4['key']]:_0x33b365[_0x3a5de4['key']]=_0x3a5de4['newValue'];}}function x(_0x311ecc){const _0x3ecbb0=N(_0x311ecc['rootName'],_0x311ecc['isAttached']());for(const _0x320158 of _0x311ecc['getChildren']()){const _0x13a71b=_0x320158['_clone'](!0x0);_0x3ecbb0['_appendChild'](_0x13a71b);}return _0x3ecbb0;}function N(_0x2ff0dc,_0xc2b142=!0x0){const _0x1e91b8=new _0x15cae0();return _0x1e91b8['rootName']=_0x2ff0dc,_0x1e91b8['_isAttached']=_0xc2b142,_0x1e91b8['isAttached']=()=>_0x1e91b8['_isAttached'],_0x1e91b8;}function P(_0x1e9954,_0x440f81,_0x2f824d){const _0x2b06e8='elementEnd'==_0x1e9954['type']?_0x2f824d['createPositionAt'](_0x1e9954['item'],'end'):_0x2f824d['createPositionBefore'](_0x1e9954['item']);return _0x2f824d['createPositionFromPath'](_0x440f81,_0x2b06e8['path'],_0x2b06e8['stickiness']);}function V(_0x3bf6ea,_0x23f3e4,_0x29ed29){const _0x2ceb4c='elementStart'==_0x3bf6ea['type']?_0x29ed29['createPositionAt'](_0x3bf6ea['item'],0x0):_0x29ed29['createPositionAfter'](_0x3bf6ea['item']);return _0x29ed29['createPositionFromPath'](_0x23f3e4,_0x2ceb4c['path'],_0x2ceb4c['stickiness']);}class me extends/* #__PURE__ -- @preserve */
25
+ _0x5e02d5(_0x3cfa23){['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x3c66e4,_0x4566cd){super(_0x3c66e4),this['focusTracker']=new _0x231da2(),this['keystrokes']=new _0x3f1f83(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x4566cd),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'](),_0x34d885({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x102d4a=_0x58dc1b=>_0x58dc1b['stopPropagation']();this['keystrokes']['set']('arrowright',_0x102d4a),this['keystrokes']['set']('arrowleft',_0x102d4a),this['keystrokes']['set']('arrowup',_0x102d4a),this['keystrokes']['set']('arrowdown',_0x102d4a);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x48e8db){this['revisionNameInputView']['fieldView']['element']['value']=_0x48e8db['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x55e9d9){const _0x213d3f=new ti(this['locale'],_0x5802d2),_0x5639fb=_0x213d3f['fieldView'];_0x5639fb['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x19f00b=m(this['locale'],'Name\x20of\x20the\x20revision');return!_0x55e9d9&&(_0x19f00b+='\x20('+m(this['locale'],'optional')+')'),(_0x213d3f['label']=_0x19f00b,_0x5639fb['on']('input',()=>{this['revisionNameInputValue']=_0x5639fb['element']['value']['trim']();}),_0x213d3f);}}class l extends _0x237363{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h];}['_saveRevisionFormView'];['init'](){const _0x1bdbf2=this['editor'],_0x39a1ca=_0x1bdbf2['plugins']['get']('RevisionTracker');_0x1bdbf2['ui']['componentFactory']['add']('revisionHistory',_0x44ab2b=>{const _0x1ae032=_0x408b44(_0x44ab2b),_0x1f44d3=_0x1ae032['panelView']['children'],_0x34a6aa=new _0x2b1a30(_0x44ab2b),_0x20cbb7=new _0x5a71fd(_0x44ab2b),_0x16758b=this['_createSaveRevisionButton'](_0x58da02),_0x97ed74=new _0x5a71fd(_0x44ab2b),_0x104f8a=this['_createOpenRevisionButton'](_0x58da02);return _0x1ae032['bind']('isEnabled')['to'](_0x39a1ca,'isReady',_0x39a1ca,'isEnabled',_0x1bdbf2,'isReadOnly',(_0x4f49ab,_0x4f125a,_0x5ea518)=>_0x4f49ab&&_0x4f125a&&!_0x5ea518),_0x1ae032['buttonView']['set']({'icon':_0x509fac,'label':m(_0x44ab2b,'Revision\x20history'),'tooltip':!0x0}),_0x16758b['set']({'withText':!0x0,'role':'menuitem'}),_0x104f8a['set']({'withText':!0x0,'role':'menuitem'}),this['listenTo'](_0x104f8a,'execute',()=>{_0x1ae032['isOpen']=!0x1,_0x1bdbf2['editing']['view']['focus']();},{'priority':'low'}),_0x20cbb7['children']['add'](_0x16758b),_0x97ed74['children']['add'](_0x104f8a),_0x34a6aa['role']='menu',_0x34a6aa['items']['addMany']([_0x20cbb7,_0x97ed74]),_0x1f44d3['add'](_0x34a6aa),_0x1ae032;}),_0x1bdbf2['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x452603=this['editor'],_0x5e001a=_0x452603['locale'],_0x3253a2=_0x452603['plugins']['get']('RevisionTracker'),_0x587b79=new _0x4d1d93(_0x5e001a),_0x315d28=new _0x51a300(_0x5e001a);_0x587b79['bind']('isEnabled')['to'](_0x3253a2,'isReady',_0x3253a2,'isEnabled',_0x452603,'isReadOnly',(_0x4e2a0f,_0x82f85a,_0x4e80c8)=>_0x4e2a0f&&_0x82f85a&&!_0x4e80c8),_0x587b79['buttonView']['set']({'icon':_0x509fac,'label':m(_0x5e001a,'Revision\x20history')});const _0x4e549e=new _0x39d5f5(_0x5e001a,_0x587b79),_0x377c72=this['_createSaveRevisionButton'](_0xda620);_0x377c72['delegate']('execute')['to'](_0x587b79),_0x4e549e['children']['add'](_0x377c72),_0x315d28['items']['add'](_0x4e549e);const _0x304405=new _0x39d5f5(_0x5e001a,_0x587b79),_0xa52233=this['_createOpenRevisionButton'](_0xda620);return _0xa52233['delegate']('execute')['to'](_0x587b79),_0x304405['children']['add'](_0xa52233),_0x315d28['items']['add'](_0x304405),_0x587b79['panelView']['children']['add'](_0x315d28),_0x587b79;}['_createSaveRevisionButton'](_0x1241ae){const _0x5d4694=this['editor'],_0x2351f1=_0x5d4694['plugins']['get']('RevisionTracker'),_0x276176=new _0x1241ae(_0x5d4694['locale']);return _0x276176['set']({'label':m(_0x5d4694['locale'],'Save\x20current\x20revision')}),_0x276176['bind']('isEnabled')['to'](_0x2351f1,'isReady',_0x2351f1,'isEnabled',_0x5d4694,'isReadOnly',(_0x57e764,_0x2cf582,_0xb431c4)=>_0x57e764&&_0x2cf582&&!_0xb431c4),this['listenTo'](_0x276176,'execute',()=>{this['_showDialog']();}),_0x276176;}['_createOpenRevisionButton'](_0x357d99){const _0x1a5bdf=this['editor'],_0x8cb9d6=_0x1a5bdf['plugins']['get']('RevisionTracker'),_0x46eb34=new _0x357d99(_0x1a5bdf['locale']);return _0x46eb34['set']({'label':m(_0x1a5bdf['locale'],'Open\x20revision\x20history')}),_0x46eb34['bind']('isEnabled')['to'](_0x8cb9d6,'isReady',_0x1a5bdf,'isReadOnly',(_0x346a88,_0x5d0acf)=>_0x346a88&&!_0x5d0acf),this['listenTo'](_0x46eb34,'execute',()=>{_0x1a5bdf['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x46eb34;}['_showDialog'](){const _0x4733af=this['editor'],_0x5f1db5=_0x4733af['locale'],_0x497c7f=_0x4733af['plugins']['get']('Dialog'),_0x3a01a8=_0x4733af['plugins']['get']('RevisionTracker');function _0x1cb77a(_0x257f49){_0x4733af['config']['get']('revisionHistory.requireRevisionName')&&''===_0x257f49['revisionName']?_0x257f49['revisionNameInputView']['errorText']=m(_0x5f1db5,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x4733af['plugins']['get'](h)['saveRevision']({'name':_0x257f49['revisionName']}),_0x497c7f['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x1cb77a(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x497c7f['show']({'id':'revisionSave','title':m(_0x5f1db5,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':m(_0x4733af['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x497c7f['hide']()},{'label':m(_0x4733af['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x1751a0){_0x1751a0['bind']('isEnabled')['to'](_0x3a01a8,'isReady',_0x3a01a8,'isEnabled',_0x4733af,'isReadOnly',(_0x227ac6,_0x58d9d7,_0x30b032)=>_0x227ac6&&_0x58d9d7&&!_0x30b032);},'onExecute':()=>_0x1cb77a(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0xa410ec=this['editor'],_0x3ba963=_0xa410ec['locale'];this['_saveRevisionFormView']=new me(_0x3ba963,_0xa410ec['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class z extends _0x3cfa23{['changeId'];['_model'];constructor(_0x21a77e,_0x4716fc){super(_0x21a77e),this['_model']=_0x4716fc,this['changeId']=_0x4716fc['id'];const _0x43d0f9=this['bindTemplate'],_0x1627ef=m(_0x21a77e,_0x4716fc['data']['isSuggestion']?'Suggested\x20by':'add'==_0x4716fc['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x4716fc['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x43d0f9['to']('type',_0x40ed0a=>'ck-revision-change__'+_0x40ed0a)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x1627ef}]},{'text':'\x20'+_0x4716fc['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class G extends/* #__PURE__ -- @preserve */
26
+ _0x56e76d(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x2c30c8){super(),this['id']=_0x2c30c8['id']||_0x9068c(),this['author']=_0x2c30c8['author'],this['type']=_0x2c30c8['type'],this['data']=_0x2c30c8['data']||{},this['rootName']=_0x2c30c8['rootName'],this['set']('createdAt',_0x2c30c8['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(_0xbf9d77,_0x3ddac2){this['newRevisionId']=_0xbf9d77,this['oldRevisionId']=_0x3ddac2,this['changes']=new _0x17dfa9();}['_setChanges'](_0x3164eb){for(const _0x1e6028 of _0x3164eb)this['changes']['add'](_0x1e6028);}}class u extends _0x237363{['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[_0x2e9ed3,_0x28c0b9,S,$];}constructor(_0x349ecd){super(_0x349ecd),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',(_0xc907a7,_0x55988e,_0x4bfbac)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x2f8a87=>{for(const _0x13a607 of this['editor']['editing']['view']['document']['roots'])_0x4bfbac?_0x2f8a87['removeClass']('ck-editor__editable__overlay',_0x13a607):_0x2f8a87['addClass']('ck-editor__editable__overlay',_0x13a607);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x199ae5=>null!==_0x199ae5),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x22639b,_0x5e7354,_0x3e7cf7)=>_0x22639b&&_0x3e7cf7?_0x5e7354['changes']['getIndex'](_0x3e7cf7):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x1f8d63,_0x1a86c4)=>_0x1f8d63?_0x1a86c4['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['_balloon']=this['editor']['plugins']['get'](_0x28c0b9);}['init'](){const _0x147d38=this['editor'],_0x1a90c9=new ot(_0x147d38,{'direction':'backward'}),_0x1fcf93=new ot(_0x147d38,{'direction':'forward'});(_0x147d38['commands']['add']('showPreviousChange',_0x1a90c9),_0x147d38['commands']['add']('showNextChange',_0x1fcf93),_0x147d38['commands']['add']('restoreRevision',new nt(_0x147d38)),this['on']('change:numberOfChanges',()=>{_0x1a90c9['refresh'](),_0x1fcf93['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x147d38['enableReadOnlyMode']('revision-viewer'),_0x147d38['plugins']['has']('WidgetToolbarRepository'))&&_0x147d38['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionDocumentData'](_0xf9e116){return await this['_utils']['loadRevisionData'](_0xf9e116,this['adapter']),this['_utils']['getRevisionDocumentData'](_0xf9e116);}async['getRevisionRootsAttributes'](_0x1778fe){return await this['_utils']['loadRevisionData'](_0x1778fe,this['adapter']),this['_utils']['getRevisionRootsAttributes'](_0x1778fe);}async['compare'](_0x3eb717,_0x317949,_0x7421f8=!0x1){if(!this['isEnabled'])return;const _0x3abe08=this['diff'],_0x385653=this['repository'],_0x412bd5='string'==typeof _0x3eb717?_0x385653['getRevision'](_0x3eb717):_0x3eb717,_0x5d6b5e='string'==typeof _0x317949?_0x385653['getRevision'](_0x317949):_0x317949,_0x56c97c=_0x412bd5['id'],_0x2a5589=_0x5d6b5e?_0x5d6b5e['id']:null;if(!_0x7421f8&&this['diff']&&this['diff']['newRevisionId']===_0x56c97c&&this['diff']['oldRevisionId']===_0x2a5589)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new J(_0x56c97c,_0x2a5589);const _0x1e5e70=this['_getRevisionsRange'](_0x412bd5,_0x5d6b5e,!0x0)['map'](_0x5aebb5=>this['_utils']['loadRevisionData'](_0x5aebb5,this['adapter']));return _0x1e5e70['push'](new Promise(_0x5083d3=>{setTimeout(_0x5083d3,0x14);})),Promise['all'](_0x1e5e70)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x507351=this['_getDiff'](_0x56c97c,_0x2a5589);for(const _0x591933 of _0x507351['changes'])this['_changeIdToChange']['set'](_0x591933['id'],_0x591933);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x479c93=>{for(const _0x2e2dc4 of this['editor']['model']['document']['getRootNames']())_0x479c93['detachRoot'](_0x2e2dc4);for(const _0x342a11 of Object['keys'](_0x507351['model'])){const _0xb29649=_0x479c93['addRoot'](_0x342a11);for(const _0x1990b2 of Object['keys'](_0x507351['attributes'][_0x342a11]))_0x479c93['setAttribute'](_0x1990b2,_0x507351['attributes'][_0x342a11][_0x1990b2],_0xb29649);_0x479c93['insert'](_0x507351['model'][_0x342a11],_0xb29649,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x507351['changes'])),this['isReady']=!0x0;})['catch'](_0x4a4d96=>{console['error'](_0x4a4d96),this['_cleanUp'](),_0x3abe08&&(this['diff']=_0x3abe08),this['isReady']=!0x0;});}['addRevisionData'](_0x23cb04,_0x1465a1){const _0x53596e=this['repository']['createRevision'](_0x23cb04);return _0x53596e['on']('_update',(_0x24cbcf,_0x534a87,_0x4326a9)=>_0x1465a1(_0x534a87,_0x4326a9,_0x53596e)),this['repository']['addRevision'](_0x53596e),_0x53596e;}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x26fa88=>{for(const _0x213ddd of this['editor']['model']['document']['getRootNames']())_0x26fa88['detachRoot'](_0x213ddd);});}['_sortAndFilterDiffChanges'](_0x45df6c){const _0x5cf20f=[],_0x4f06e6=new Map();for(const _0x1e228b of this['editor']['model']['document']['getRootNames']()){const _0x573936=this['editor']['editing']['view']['getDomRoot'](_0x1e228b);if(!_0x573936)continue;const _0x3b13bd=_0x573936['getClientRects']()['item'](0x0);_0x3b13bd&&(_0x5cf20f['push'](_0x1e228b),_0x4f06e6['set'](_0x1e228b,_0x3b13bd));}return _0x5cf20f['sort']((_0x5b8f06,_0xd0ae94)=>{const _0x4e1131=_0x4f06e6['get'](_0x5b8f06),_0x1cc20e=_0x4f06e6['get'](_0xd0ae94);return _0x4e1131['y']-_0x1cc20e['y']||_0x4e1131['x']-_0x1cc20e['x'];}),(_0x45df6c=_0x45df6c['filter'](_0xb08bfa=>_0x5cf20f['includes'](_0xb08bfa['rootName'])))['sort']((_0x46728e,_0xde0c06)=>_0x5cf20f['indexOf'](_0x46728e['rootName'])-_0x5cf20f['indexOf'](_0xde0c06['rootName'])),_0x45df6c;}['_makeTape'](_0x10daae){const _0x106507=Array['from'](_0x10daae['markers'])['filter'](([_0x5518e2,_0x27a648])=>_0x5518e2['startsWith']('revision:')&&!_0x27a648['isCollapsed']),_0x291147=Array['from'](this['editor']['model']['createRangeIn'](_0x10daae)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x106507['length'])for(const _0x3b924f of _0x291147){const [_0x481426,_0x461a99]=_0x106507[0x0],[,_0x5c5d89,_0x4fbb5f]=_0x481426['split'](':');if(_0x461a99['end']['isEqual'](_0x3b924f['nextPosition'])&&_0x106507['shift'](),(_0x3b924f['previousPosition']['isEqual'](_0x461a99['start'])||_0x3b924f['previousPosition']['isAfter'](_0x461a99['start']))&&('insertion'==_0x5c5d89?_0x3b924f['isAdded']={'userId':_0x4fbb5f}:'deletion'==_0x5c5d89&&(_0x3b924f['isRemoved']={'userId':_0x4fbb5f})),0x0==_0x106507['length'])break;}return _0x291147;}['_refreshStartEndIndex'](_0x201ebb){const _0x3c8d28=new Map();for(let _0x19e5d6=0x0;_0x19e5d6<_0x201ebb['length'];_0x19e5d6++)'text'===_0x201ebb[_0x19e5d6]['type']?(_0x201ebb[_0x19e5d6]['item']['startIndex']=_0x19e5d6,_0x201ebb[_0x19e5d6]['item']['endIndex']=_0x19e5d6):('elementStart'===_0x201ebb[_0x19e5d6]['type']?_0x201ebb[_0x19e5d6]['item']['startIndex']=_0x19e5d6:'elementEnd'===_0x201ebb[_0x19e5d6]['type']&&(_0x201ebb[_0x19e5d6]['item']['endIndex']=_0x19e5d6),_0x3c8d28['set'](_0x201ebb[_0x19e5d6]['id'],_0x19e5d6));for(const _0x16cd19 of _0x3c8d28['values']())'elementStart'===_0x201ebb[_0x16cd19]['type']?_0x201ebb[_0x16cd19]['item']['endIndex']=_0x3c8d28['get'](_0x201ebb[_0x16cd19]['pairId']):'elementEnd'===_0x201ebb[_0x16cd19]['type']&&(_0x201ebb[_0x16cd19]['item']['startIndex']=_0x3c8d28['get'](_0x201ebb[_0x16cd19]['pairId']));}['_processTape'](_0x193256){for(let _0x536371=0x0;_0x536371<_0x193256['length'];_0x536371++){if('elementStart'===_0x193256[_0x536371]['type'])_0x193256[_0x536371]['item']['startIndex']=_0x536371;else{if('elementEnd'===_0x193256[_0x536371]['type']){_0x193256[_0x536371]['item']['endIndex']=_0x536371;const _0x34eca7=_0x193256[_0x536371]['item']['startIndex'];_0x193256[_0x34eca7]['pairId']=_0x193256[_0x536371]['id'],_0x193256[_0x536371]['pairId']=_0x193256[_0x34eca7]['id'];}else _0x193256[_0x536371]['item']['startIndex']=_0x536371,_0x193256[_0x536371]['item']['endIndex']=_0x536371,_0x193256[_0x536371]['pairId']=null;}_0x193256[_0x536371]['markersStart']||(_0x193256[_0x536371]['markersStart']=[],_0x193256[_0x536371]['markersEnd']=[]);}}['_markInsertions'](_0xee594,_0x3177df){const _0xc88cf0=_0xee594['filter'](_0x323fba=>!_0x323fba['isAdded']);for(let _0x11b913=0x0;_0x11b913<_0x3177df['length'];_0x11b913++)_0x3177df[_0x11b913]['isAdded']&&(_0xc88cf0[_0x11b913]['isAdded']=_0x3177df[_0x11b913]['isAdded']);}['_getDiff'](_0x5ecd39,_0x54b559=null){const _0x32447a=this['repository']['getRevision'](_0x5ecd39),_0xd19be0=_0x54b559?this['repository']['getRevision'](_0x54b559):null,_0x3932d1=this['_getRevisionsRange'](_0x32447a,_0xd19be0),_0x27e18f=_0x3932d1[_0x3932d1['length']-0x1],_0x206d17=new Map(),_0x53e30f={'model':{},'attributes':{},'changes':[]},_0x30ab81=new Set(),_0x205d1e=new Map();for(let _0x2460bc=_0x3932d1['length']-0x1;_0x2460bc>=0x0;_0x2460bc--){const _0x27cfc5=_0x3932d1[_0x2460bc];for(const _0xbad139 of Object['keys'](_0x27cfc5['diffData']))if(_0x27cfc5['diffData'][_0xbad139]['attachChange']){const _0x4f94b8=_0x27cfc5['diffData'][_0xbad139]['attachChange'];_0x4f94b8['isAttached']?(_0x30ab81['add'](_0xbad139),_0x205d1e['has'](_0xbad139)&&_0x205d1e['get'](_0xbad139)['userId']==_0x4f94b8['userId']?_0x205d1e['delete'](_0xbad139):_0x205d1e['set'](_0xbad139,_0x4f94b8)):_0x205d1e['has'](_0xbad139)?(_0x30ab81['delete'](_0xbad139),_0x205d1e['delete'](_0xbad139)):(_0x30ab81['add'](_0xbad139),_0x205d1e['set'](_0xbad139,_0x4f94b8));}else _0x30ab81['add'](_0xbad139);}for(const _0x132285 of _0x30ab81){const _0x2c9a15=_0x205d1e['has'](_0x132285)&&!_0x205d1e['get'](_0x132285)['isAttached'];let _0x2f9062=_0x2c9a15?_0x3932d1['length']-0x1:0x0;const _0x320d38=_0x2c9a15?-0x1:0x1;for(;_0x3932d1[_0x2f9062];){const _0x112f69=_0x3932d1[_0x2f9062];if(_0x112f69['diffData'][_0x132285]){const _0x2e5379=_0x2c9a15?_0x112f69['diffData'][_0x132285]['attributesBefore']:_0x112f69['diffData'][_0x132285]['attributesAfter'];_0x53e30f['attributes'][_0x132285]=_0x2e5379?_0x42245c(_0x2e5379):{};break;}_0x2f9062+=_0x320d38;}}for(const _0xf5f6ca of _0x3932d1){_0xf5f6ca['model']={};for(const _0x18a5a1 of _0xf5f6ca['authors'])_0x206d17['set'](_0x18a5a1['id'],_0x18a5a1);for(const _0x292885 of _0x30ab81){const _0x5c7ffb=_0xf5f6ca['diffData'][_0x292885]?_0xf5f6ca['diffData'][_0x292885]['insertions']:'[]',_0x55ea36=_0xf5f6ca['diffData'][_0x292885]?_0xf5f6ca['diffData'][_0x292885]['deletions']:'[]';_0xf5f6ca['model'][_0x292885]={'insertions':this['_utils']['_makeModelFromViewString'](_0x5c7ffb),'deletions':this['_utils']['_makeModelFromViewString'](_0x55ea36)};}}for(const _0x5332a8 of _0x30ab81){let _0x46cf2d=null,_0x244830=0x0;const _0x5a2933=new Map(Array['from'](_0x32447a['model'][_0x5332a8]['insertions']['markers'])['filter'](([_0x3920be])=>!_0x3920be['startsWith']('revision:')));let _0x2363ee=0x0;for(const _0x5a70d5 of _0x3932d1){const _0xfe4167=this['_makeTape'](_0x5a70d5['model'][_0x5332a8]['insertions']);_0x5a70d5==_0x32447a?(_0x46cf2d=_0xfe4167,_0x244830=_0x46cf2d['length'],_0x46cf2d['forEach'](_0x110527=>{_0x110527['id']=_0x2363ee++;}),this['_processTape'](_0x46cf2d)):this['_markInsertions'](_0x46cf2d,_0xfe4167);const _0x4a7341=_0x46cf2d['filter'](_0x404c2d=>!_0x404c2d['isAdded'])['map'](_0x49b7f3=>_0x49b7f3['id']);let _0x41cb16=0x0;const _0x3b613b=this['_makeTape'](_0x5a70d5['model'][_0x5332a8]['deletions']);_0x3b613b['forEach'](_0x12ef14=>{_0x12ef14['isRemoved']?_0x12ef14['id']=_0x244830++:_0x12ef14['id']=_0x4a7341[_0x41cb16++];}),this['_processTape'](_0x3b613b),this['_setDistance'](_0x46cf2d,'isAdded'),this['_setDistance'](_0x3b613b,'isRemoved'),_0x5a70d5==_0x32447a&&this['_markMarkers'](_0x46cf2d,_0x5a2933),_0x46cf2d=this['_joinTapes'](_0x46cf2d,_0x3b613b),this['_refreshStartEndIndex'](_0x46cf2d),this['_setDistance'](_0x46cf2d,'isRemoved');}_0x46cf2d=_0x46cf2d['filter'](_0x5a6474=>!(_0x5a6474['isAdded']&&_0x5a6474['isRemoved']));const _0x1b99df=new Map(_0x27e18f['model'][_0x5332a8]['deletions']['markers']),_0x2f11c3=new Set(_0x5a2933['keys']());for(const _0x4a4d4b of _0x1b99df['keys']())_0x2f11c3['delete'](_0x4a4d4b);this['_markSuggestions'](_0x46cf2d,_0x2f11c3),this['_fixObsoleteTags'](_0x46cf2d),_0x46cf2d=this['_removeMissingPairs'](_0x46cf2d),_0x46cf2d=this['_markMismatchedRemovedTags'](_0x46cf2d),_0x46cf2d=this['_removeUnsupportedChanges'](_0x46cf2d);const {root:_0x3a7350,changes:_0x50667b}=this['_makeModelFromTape'](_0x46cf2d,_0x206d17,_0x5332a8);_0x53e30f['model'][_0x5332a8]=_0x3a7350;const _0x42d56d=_0x205d1e['get'](_0x5332a8);if(_0x42d56d){const _0x80958a=_0x206d17['get'](_0x42d56d['userId']),_0x22a3d2=new G({'author':_0x80958a,'type':_0x42d56d['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x5332a8});_0x50667b['unshift'](_0x22a3d2),_0x53e30f['attributes'][_0x5332a8]['revisionHistoryAttachChange']=_0x22a3d2['id'];}_0x53e30f['changes']=_0x53e30f['changes']['concat'](_0x50667b);}return _0x53e30f;}['_markMarkers'](_0x4a9cdc,_0x33dcb9){for(let _0x54aa20=0x0;_0x54aa20<_0x4a9cdc['length'];_0x54aa20++)for(const [_0x4eeeaa,_0x17823c]of _0x33dcb9)!_0x17823c['isCollapsed']&&_0x17823c['start']['isEqual'](_0x4a9cdc[_0x54aa20]['previousPosition'])&&_0x4a9cdc[_0x54aa20]['markersStart']['push'](_0x4eeeaa),_0x17823c['end']['isEqual'](_0x4a9cdc[_0x54aa20]['nextPosition'])&&_0x4a9cdc[_0x54aa20]['markersEnd']['push'](_0x4eeeaa);}['_joinTapes'](_0x4d3b6c,_0x2a17a8){let _0x2d27d1=[],_0x3cb922=0x0,_0x220648=0x0;for(;_0x3cb922<_0x4d3b6c['length']||_0x220648<_0x2a17a8['length'];){const _0x1f78f4=_0x4d3b6c[_0x3cb922]||{},_0x10a74b=_0x2a17a8[_0x220648]||{};if(_0x1f78f4['id']==_0x10a74b['id'])_0x3cb922++,_0x220648++,_0x2d27d1['push'](_0x1f78f4);else{if(_0x10a74b['isRemoved']&&_0x1f78f4['isAdded']){const {commonTape:_0x4eb007,iEnd:_0x22f72c,jEnd:_0x25b138}=this['_threeWayMerge'](_0x4d3b6c,_0x3cb922,_0x2a17a8,_0x220648);_0x2d27d1=_0x2d27d1['concat'](_0x4eb007),_0x3cb922=_0x22f72c,_0x220648=_0x25b138;}else _0x10a74b['isRemoved']?(_0x220648++,_0x2d27d1['push'](_0x10a74b)):(_0x3cb922++,_0x2d27d1['push'](_0x1f78f4));}}return _0x2d27d1;}['_markSuggestions'](_0xb0d7f9,_0x357f49){const _0x425434=[];for(let _0x1063ab=0x0;_0x1063ab<_0xb0d7f9['length'];_0x1063ab++){for(let _0x698cc0=0x0;_0x698cc0<_0xb0d7f9[_0x1063ab]['markersStart']['length'];_0x698cc0++){const _0xbe527d=_0xb0d7f9[_0x1063ab]['markersStart'][_0x698cc0];if(!_0x357f49['has'](_0xbe527d))continue;const {group:_0x5d0ecb,type:_0x5290ec,authorId:_0xbe79bb}=_0x19a4e8(_0xbe527d);'revision-suggestion'!=_0x5d0ecb||'insertion'!=_0x5290ec&&'deletion'!=_0x5290ec||(_0x425434['unshift']({'type':_0x5290ec,'name':_0xbe527d,'userId':_0xbe79bb}),_0xb0d7f9[_0x1063ab]['markersStart']['splice'](_0x698cc0,0x1),_0x698cc0--);}_0x5cd799(_0xb0d7f9[_0x1063ab]);for(let _0x1c6e92=0x0;_0x1c6e92<_0xb0d7f9[_0x1063ab]['markersEnd']['length'];_0x1c6e92++){const _0x58f01b=_0xb0d7f9[_0x1063ab]['markersEnd'][_0x1c6e92];if(!_0x357f49['has'](_0x58f01b))continue;const {group:_0x404f21,type:_0x16b083}=_0x19a4e8(_0x58f01b);if('revision-suggestion'!=_0x404f21||'insertion'!=_0x16b083&&'deletion'!=_0x16b083)continue;_0xb0d7f9[_0x1063ab]['markersEnd']['splice'](_0x1c6e92,0x1),_0x1c6e92--;const _0x17a369=_0x425434['findIndex'](_0x48afec=>_0x48afec['name']==_0x58f01b);_0x17a369>-0x1&&_0x425434['splice'](_0x17a369,0x1);}}function _0x19a4e8(_0x51a08a){const _0x435261=_0x51a08a['split'](':');return{'group':_0x435261[0x0],'type':_0x435261[0x1],'subType':_0x435261['length']>=0x5?_0x435261[0x2]:null,'id':_0x435261['length']<0x5?_0x435261[0x2]:_0x435261[0x3],'authorId':_0x435261['length']<0x5?_0x435261[0x3]:_0x435261[0x4],'markerCount':0x6==_0x435261['length']?_0x435261[0x5]:null};}function _0x5cd799(_0x3d9ee8){for(let _0x2eebf4=0x0;_0x2eebf4<_0x425434['length'];_0x2eebf4++){if(_0x3d9ee8['isAdded']&&'insertion'==_0x425434[_0x2eebf4]['type']&&_0x3d9ee8['isAdded']['userId']==_0x425434[_0x2eebf4]['userId'])return _0x3d9ee8['isAddSuggestion']=_0x425434[_0x2eebf4],void delete _0x3d9ee8['isAdded'];if(!_0x3d9ee8['isAdded']&&!_0x3d9ee8['isRemoved']&&'deletion'==_0x425434[_0x2eebf4]['type'])return void(_0x3d9ee8['isRemoveSuggestion']=_0x425434[_0x2eebf4]);}}}['_setDistance'](_0xc9c6b7,_0x5bec81){let _0x322f76=0x0,_0x2722e2=!0x1;const _0x565d9f=new Map();for(const _0x2c1b02 of _0xc9c6b7)_0x2c1b02[_0x5bec81]?_0x2722e2&&(_0x322f76++,_0x2722e2=!0x1):(_0x322f76++,_0x2722e2=!0x0),_0x565d9f['set'](_0x2c1b02['id'],_0x322f76);for(let _0x173ef8=0x0;_0x173ef8<_0xc9c6b7['length'];_0x173ef8++){if('isRemoved'==_0x5bec81&&_0xc9c6b7[_0x173ef8]['isAdded']||'isAdded'==_0x5bec81&&_0xc9c6b7[_0x173ef8]['isRemoved'])continue;if('text'==_0xc9c6b7[_0x173ef8]['type']){_0xc9c6b7[_0x173ef8]['distance']=0x0;continue;}const _0xa8d6e1=_0x565d9f['get'](_0xc9c6b7[_0x173ef8]['pairId']),_0x354d38=_0x565d9f['get'](_0xc9c6b7[_0x173ef8]['id']);_0xc9c6b7[_0x173ef8]['distance']=_0xa8d6e1-_0x354d38;}}['_getRevisionsRange'](_0x61b9b,_0x362ae5,_0x201e21=!0x1){const _0x5baf5=[];let _0x5b80ff=this['repository']['getIndex'](_0x61b9b),_0x85b61=this['repository']['getIndex'](_0x362ae5);for(-0x1==_0x85b61&&(_0x85b61=this['repository']['_revisions']['length'],_0x201e21=!0x1);_0x5b80ff<_0x85b61;)_0x5baf5['push'](this['repository']['getRevision'](_0x5b80ff)),_0x5b80ff++;return _0x201e21&&_0x5baf5['push'](this['repository']['getRevision'](_0x5b80ff)),_0x5baf5;}['_threeWayMerge'](_0x3c9a47,_0x1a0d2d,_0x4436a2,_0x35cd13){const _0x54581b=this['editor']['model']['schema'];let _0x53860e=_0x1a0d2d;for(;_0x3c9a47[_0x53860e]&&_0x3c9a47[_0x53860e]['isAdded'];)_0x53860e++;let _0x40e7d8=_0x35cd13;for(;_0x4436a2[_0x40e7d8]&&_0x4436a2[_0x40e7d8]['isRemoved'];)_0x40e7d8++;_0x2c0444(_0x3c9a47,_0x1a0d2d,_0x53860e),_0x2c0444(_0x4436a2,_0x35cd13,_0x40e7d8);const _0x231ec3=_0x4436a2['slice'](_0x35cd13,_0x40e7d8)['concat'](_0x3c9a47['slice'](_0x1a0d2d,_0x53860e));return _0x231ec3['sort']((_0x294135,_0x5aa8dd)=>_0x294135['side']!=_0x5aa8dd['side']?_0x294135['side']-_0x5aa8dd['side']:_0x294135['level']!=_0x5aa8dd['level']?_0x294135['level']-_0x5aa8dd['level']:_0x294135['distance']!=_0x5aa8dd['distance']?_0x5aa8dd['distance']-_0x294135['distance']:!!_0x294135['isAdded']!=!!_0x5aa8dd['isAdded']?-0x1==_0x294135['side']||0x0==_0x294135['side']?_0x294135['isAdded']?-0x1:0x1:_0x294135['isAdded']?0x1:-0x1:_0x294135['index']-_0x5aa8dd['index']),{'commonTape':_0x231ec3,'iEnd':_0x53860e,'jEnd':_0x40e7d8};function _0x2c0444(_0x2bd10a,_0x1d5d29,_0x5bae8b){let _0x702bc7=-0x1,_0x4290bd=Number['POSITIVE_INFINITY'],_0x553510=!0x0;for(let _0x4f45a2=_0x1d5d29;_0x4f45a2<_0x5bae8b;_0x4f45a2++)if(_0x54581b['isInline'](_0x2bd10a[_0x4f45a2]['item'])||(_0x553510=!0x1),_0x2bd10a[_0x4f45a2]['item']['startIndex']<_0x1d5d29&&(_0x702bc7=_0x4f45a2),_0x2bd10a[_0x4f45a2]['item']['endIndex']>=_0x5bae8b){_0x4290bd=_0x4f45a2;break;}_0x553510&&(_0x702bc7=_0x5bae8b-0x1);for(let _0xcfbbc0=_0x1d5d29;_0xcfbbc0<_0x5bae8b;_0xcfbbc0++)_0x2bd10a[_0xcfbbc0]['side']=_0xcfbbc0<=_0x702bc7?-0x1:_0xcfbbc0<_0x4290bd?0x0:0x1,_0x2bd10a[_0xcfbbc0]['index']=_0xcfbbc0;let _0x363fca=0x0;for(let _0x15f798=_0x1d5d29;_0x15f798<=_0x702bc7;_0x15f798++)0x0==_0x2bd10a[_0x15f798]['distance']?_0x2bd10a[_0x15f798]['level']=_0x363fca:(_0x363fca++,_0x2bd10a[_0x15f798]['level']=_0x363fca,_0x363fca++);for(let _0xc12db8=_0x1d5d29;_0xc12db8<_0x5bae8b;_0xc12db8++)0x0==_0x2bd10a[_0xc12db8]['side']&&(_0x2bd10a[_0xc12db8]['level']=_0x363fca);_0x363fca=0x0;for(let _0x1911ee=_0x5bae8b-0x1;_0x1911ee>=_0x4290bd;_0x1911ee--)0x0==_0x2bd10a[_0x1911ee]['distance']?_0x2bd10a[_0x1911ee]['level']=_0x363fca:(_0x363fca--,_0x2bd10a[_0x1911ee]['level']=_0x363fca,_0x363fca--);}}['_fixObsoleteTags'](_0x170310){const _0x36cd61=new Map(),_0x233d11=this['editor']['model']['schema'];for(let _0x19dad9=0x1;_0x19dad9<_0x170310['length'];_0x19dad9++){let _0x14f6ea,_0x53eb67,_0x1568db;const _0x8c079b=_0x170310[_0x19dad9],_0x5dede7=_0x170310[_0x19dad9-0x1];if('text'==_0x8c079b['type'])continue;if(_0x8c079b['type']!=_0x5dede7['type'])continue;if(!_0x233d11['isBlock'](_0x5dede7['item'])||_0x233d11['isLimit'](_0x5dede7['item']))continue;if(!_0x233d11['isBlock'](_0x8c079b['item'])||_0x233d11['isLimit'](_0x8c079b['item']))continue;if((_0x170310[_0x19dad9]['isAdded']||_0x170310[_0x19dad9]['isAddSuggestion'])&&_0x170310[_0x19dad9-0x1]['isRemoved'])_0x14f6ea=_0x170310[_0x19dad9],_0x53eb67=_0x170310[_0x19dad9-0x1],_0x1568db=_0x19dad9-0x1;else{if(!_0x170310[_0x19dad9]['isRemoved']||!_0x170310[_0x19dad9-0x1]['isAdded']&&!_0x170310[_0x19dad9-0x1]['isAddSuggestion'])continue;_0x14f6ea=_0x170310[_0x19dad9-0x1],_0x53eb67=_0x170310[_0x19dad9],_0x1568db=_0x19dad9;}const _0x4d07e9=_0x14f6ea['level']==_0x53eb67['level'],_0x337325=Math['abs'](_0x14f6ea['level'])<Math['abs'](_0x53eb67['level'])&&0x0==_0x53eb67['distance'];(_0x4d07e9||_0x337325)&&(_0x36cd61['set'](_0x53eb67['id'],_0x14f6ea['id']),_0x170310['splice'](_0x1568db,0x1),_0x19dad9--,_0x14f6ea['isAdded']=!0x1);}for(let _0xd3293=0x0;_0xd3293<_0x170310['length'];_0xd3293++)_0x36cd61['has'](_0x170310[_0xd3293]['pairId'])&&(_0x170310[_0xd3293]['pairId']=_0x36cd61['get'](_0x170310[_0xd3293]['pairId']));}['_removeMissingPairs'](_0x3126ca){const _0x539ddf=new Set(_0x3126ca['map'](_0x447e12=>_0x447e12['id']));for(let _0x53ce6c=0x0;_0x53ce6c<_0x3126ca['length'];_0x53ce6c++)_0x539ddf['has'](_0x3126ca[_0x53ce6c]['pairId'])||0x0==_0x3126ca[_0x53ce6c]['distance']||(_0x3126ca[_0x53ce6c]['isIncorrect']=!0x0);return _0x3126ca['filter'](_0x377d64=>!_0x377d64['isIncorrect']);}['_markMismatchedRemovedTags'](_0xf3ba35){const _0x15fcef=new Set();for(let _0x2a61c1=0x0;_0x2a61c1<_0xf3ba35['length'];_0x2a61c1++){if(_0x15fcef['has'](_0xf3ba35[_0x2a61c1]['id'])&&_0xf3ba35[_0x2a61c1]['isRemoved']&&(_0xf3ba35[_0x2a61c1]['isIncorrect']=!0x0),_0xf3ba35[_0x2a61c1]['isIncorrect'])continue;if(0x0==_0xf3ba35[_0x2a61c1]['distance'])continue;if('elementStart'!=_0xf3ba35[_0x2a61c1]['type'])continue;if(null==_0xf3ba35[_0x2a61c1]['pairId'])continue;let _0x1b02a9=_0x2a61c1+0x1,_0x4977eb=0x0;for(;_0xf3ba35[_0x1b02a9]['id']!=_0xf3ba35[_0x2a61c1]['pairId'];)'elementStart'==_0xf3ba35[_0x1b02a9]['type']?_0x4977eb++:'elementEnd'==_0xf3ba35[_0x1b02a9]['type']&&_0x4977eb--,_0x1b02a9++;if(0x0!=_0x4977eb){if(_0xf3ba35[_0x2a61c1]['isRemoved'])_0xf3ba35[_0x2a61c1]['isIncorrect']=!0x0;else{for(;_0x1b02a9!=_0x2a61c1;)_0xf3ba35[_0x1b02a9]['isRemoved']&&0x0!=_0xf3ba35[_0x1b02a9]['distance']&&(_0xf3ba35[_0x1b02a9]['isIncorrect']=!0x0,_0x15fcef['add'](_0xf3ba35[_0x1b02a9]['pairId'])),_0x1b02a9--;}}}return _0xf3ba35['filter'](_0x3b39fe=>!_0x3b39fe['isIncorrect']);}['_removeUnsupportedChanges'](_0x48901c){const _0x396b37=this['editor']['model']['schema'];for(let _0x3e239c=0x0;_0x3e239c<_0x48901c['length'];_0x3e239c++){if(!(_0x48901c[_0x3e239c]['isAdded']||_0x48901c[_0x3e239c]['isAddSuggestion']||_0x48901c[_0x3e239c]['isRemoved']||_0x48901c[_0x3e239c]['isRemoveSuggestion']))continue;if(0x0==_0x48901c[_0x3e239c]['distance'])continue;const _0x21931e=_0x48901c[_0x3e239c]['item'];_0x396b37['isBlock'](_0x21931e)||_0x396b37['isLimit'](_0x21931e)||(_0x48901c[_0x3e239c]['isAdded']&&delete _0x48901c[_0x3e239c]['isAdded'],_0x48901c[_0x3e239c]['isAddSuggestion']&&delete _0x48901c[_0x3e239c]['isAddSuggestion'],_0x48901c[_0x3e239c]['isRemoveSuggestion']&&delete _0x48901c[_0x3e239c]['isRemoveSuggestion'],_0x48901c[_0x3e239c]['isRemoved']&&(_0x48901c[_0x3e239c]['isIncorrect']=!0x0));}return _0x48901c['filter'](_0x4d91f6=>!_0x4d91f6['isIncorrect']);}['_makeModelFromTape'](_0x240ec5,_0x4f10e4,_0x1fbd27){const _0x482fe5=new _0x15cae0(),_0x146b05=[],_0x555f33=new Map(),_0x3bca73=this['editor']['model'],_0x28eaa1=_0x3bca73['schema'],_0x53f236=[_0x482fe5],_0x3f50fc={},_0x1996b8={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x5dc4bd=null;const _0x568e05=[0x0];for(let _0x18cc49=0x0;_0x18cc49<_0x240ec5['length'];_0x18cc49++)if('elementStart'===_0x240ec5[_0x18cc49]['type']){_0x240ec5[_0x18cc49]['previousPosition']=_0x3bca73['createPositionFromPath'](_0x482fe5,_0x568e05);const _0x52148d=new _0x5600a1(_0x240ec5[_0x18cc49]['item']['name'],_0x240ec5[_0x18cc49]['item']['getAttributes']());_0x53f236[0x0]['_appendChild'](_0x52148d),_0x568e05['push'](0x0),_0x53f236['unshift'](_0x52148d),_0x240ec5[_0x18cc49]['nextPosition']=_0x3bca73['createPositionFromPath'](_0x482fe5,_0x568e05);}else'elementEnd'===_0x240ec5[_0x18cc49]['type']?(_0x53f236['shift'](),_0x240ec5[_0x18cc49]['previousPosition']=_0x3bca73['createPositionFromPath'](_0x482fe5,_0x568e05),_0x568e05['pop'](),_0x568e05[_0x568e05['length']-0x1]++,_0x240ec5[_0x18cc49]['nextPosition']=_0x3bca73['createPositionFromPath'](_0x482fe5,_0x568e05)):(_0x240ec5[_0x18cc49]['previousPosition']=_0x3bca73['createPositionFromPath'](_0x482fe5,_0x568e05),_0x5dc4bd?_0x5dc4bd['_data']+=_0x240ec5[_0x18cc49]['item']['data']:_0x5dc4bd=new _0x260b60(_0x240ec5[_0x18cc49]['item']['data'],_0x240ec5[_0x18cc49]['item']['getAttributes']()),_0x240ec5[_0x18cc49+0x1]&&'text'===_0x240ec5[_0x18cc49+0x1]['type']&&_0x3d6bba(_0x5dc4bd,_0x240ec5[_0x18cc49+0x1]['item'])||(_0x53f236[0x0]['_appendChild'](_0x5dc4bd),_0x5dc4bd=null),_0x568e05[_0x568e05['length']-0x1]+=_0x240ec5[_0x18cc49]['item']['offsetSize'],_0x240ec5[_0x18cc49]['nextPosition']=_0x3bca73['createPositionFromPath'](_0x482fe5,_0x568e05));for(let _0x13bcf9=0x0;_0x13bcf9<_0x240ec5['length'];_0x13bcf9++){const _0x480772=_0x240ec5[_0x13bcf9]['previousPosition'],_0x18edc3=_0x240ec5[_0x13bcf9]['nextPosition'];for(const _0x1be8bb of _0x240ec5[_0x13bcf9]['markersStart'])_0x555f33['set'](_0x1be8bb,{'start':_0x480772,'end':null});_0x366cb1('isRemoveSuggestion',_0x13bcf9,_0x480772,_0x18edc3),_0x366cb1('isAddSuggestion',_0x13bcf9,_0x480772,_0x18edc3),_0x366cb1('isRemoved',_0x13bcf9,_0x480772,_0x18edc3),_0x366cb1('isAdded',_0x13bcf9,_0x480772,_0x18edc3);for(const _0x25f36c of _0x240ec5[_0x13bcf9]['markersEnd']){const _0x24483f=_0x555f33['get'](_0x25f36c);_0x24483f?_0x24483f['end']=_0x18edc3:_0x555f33['set'](_0x25f36c,{'start':_0x18edc3,'end':_0x18edc3});}}for(const [_0x14a2e7,_0x2b838a]of _0x555f33){const _0x1ee846=this['editor']['model']['createRange'](_0x2b838a['start'],_0x2b838a['end']);_0x482fe5['markers']['set'](_0x14a2e7,_0x1ee846);}return _0x146b05['sort']((_0x369583,_0x462048)=>{const _0x48dfb7=_0x482fe5['markers']['get']('revision:'+_0x369583['id']),_0xe8d5ee=_0x482fe5['markers']['get']('revision:'+_0x462048['id']);return _0x48dfb7['start']['isBefore'](_0xe8d5ee['start'])?-0x1:_0x48dfb7['start']['isAfter'](_0xe8d5ee['start'])?0x1:_0x48dfb7['end']['isBefore'](_0xe8d5ee['end'])?-0x1:_0x48dfb7['end']['isAfter'](_0xe8d5ee['end'])?0x1:'add'===_0x369583['type']?-0x1:0x1;}),{'root':_0x482fe5,'changes':_0x146b05};function _0x366cb1(_0xd7a48b,_0x3869a7,_0x261f7d,_0x356ffb){const _0x94eb50=!!_0x240ec5[_0x3869a7][_0xd7a48b],_0x5b045e=_0x94eb50?_0x240ec5[_0x3869a7][_0xd7a48b]['userId']:null,_0x5e8ff8=_0x3869a7===_0x240ec5['length']-0x1,_0x5b43ff=_0x1996b8[_0xd7a48b][0x0],_0x437272=_0x28eaa1['isObject'](_0x240ec5[_0x3869a7]['item']);!_0x3f50fc[_0xd7a48b]&&_0x94eb50?_0x3f50fc[_0xd7a48b]={'start':_0x261f7d,'tapeItem':_0x240ec5[_0x3869a7],'userId':_0x5b045e,'type':_0xd7a48b}:_0x3f50fc[_0xd7a48b]&&!_0x94eb50?(_0x3f50fc[_0xd7a48b]['end']=_0x261f7d,_0x16bd30(_0x3f50fc[_0xd7a48b]),_0x3f50fc[_0xd7a48b]=null):_0x3f50fc[_0xd7a48b]&&_0x94eb50&&_0x3f50fc[_0xd7a48b]['userId']!==_0x5b045e&&(_0x3f50fc[_0xd7a48b]['end']=_0x261f7d,_0x5b43ff&&_0x5b43ff['userId']===_0x3f50fc[_0xd7a48b]['userId']||_0x16bd30(_0x3f50fc[_0xd7a48b]),_0x3f50fc[_0xd7a48b]={'start':_0x261f7d,'tapeItem':_0x240ec5[_0x3869a7],'userId':_0x5b045e,'type':_0xd7a48b}),_0x3f50fc[_0xd7a48b]&&_0x437272&&('elementStart'!==_0x240ec5[_0x3869a7]['type']||_0x5b43ff&&_0x5b43ff['userId']===_0x5b045e||_0x1996b8[_0xd7a48b]['unshift']({'userId':_0x5b045e,'object':_0x240ec5[_0x3869a7]['item'],'change':_0x3f50fc[_0xd7a48b]}),'elementEnd'===_0x240ec5[_0x3869a7]['type']&&_0x5b43ff&&_0x5b43ff['object']===_0x240ec5[_0x3869a7]['item']&&(_0x1996b8[_0xd7a48b]['shift'](),_0x3f50fc[_0xd7a48b]=_0x5b43ff['change'])),_0x3f50fc[_0xd7a48b]&&_0x5e8ff8&&(_0x3f50fc[_0xd7a48b]['end']=_0x356ffb,_0x16bd30(_0x3f50fc[_0xd7a48b]),_0x3f50fc[_0xd7a48b]=null);}function _0x16bd30({start:_0x4acda5,end:_0x300bdc,tapeItem:_0x3a0747,userId:_0x5ec602,type:_0x3c3274}){const _0x144236=_0x3a0747['item'],_0xc6cdd2=_0x3bca73['schema']['isBlock'](_0x144236)&&!_0x3bca73['schema']['isLimit'](_0x144236),_0x4d406b=_0x4acda5['nodeAfter']==_0x300bdc['parent']&&_0x300bdc['isAtStart'];if(_0xc6cdd2&&_0x4d406b)return;const _0x4a4a00=_0x3bca73['createRange'](_0x4acda5,_0x300bdc),_0x44b90a=_0x4f10e4['get'](_0x5ec602),_0xb7c75a=new G({'author':_0x44b90a,'type':'isAdded'==_0x3c3274||'isAddSuggestion'==_0x3c3274?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x3c3274||'isRemoveSuggestion'==_0x3c3274},'createdAt':new Date(),'rootName':_0x1fbd27});_0x146b05['push'](_0xb7c75a),_0x482fe5['markers']['set']('revision:'+_0xb7c75a['id'],_0x4a4a00);}function _0x3d6bba(_0x2c0a23,_0x3f4408){const _0x1d3e13=_0x2c0a23['getAttributes'](),_0x4bc517=_0x3f4408['getAttributes']();for(const _0xc5a014 of _0x1d3e13){if(_0xc5a014[0x1]!==_0x3f4408['getAttribute'](_0xc5a014[0x0]))return!0x1;_0x4bc517['next']();}return _0x4bc517['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x57dc04=>{const _0x481555=_0x57dc04['markerName']['split'](':')[0x1],_0x87cfff=this['_getChangeFromId'](_0x481555);if(!_0x87cfff)return null;const _0x2ec748='add'==_0x87cfff['type']?'insertion':'deletion',_0x15491b=['ck-suggestion-marker','ck-suggestion-marker-'+_0x2ec748];return _0x87cfff['data']['isSuggestion']&&_0x15491b['push']('ck-suggestion-marker-'+_0x2ec748+'-new'),this['activeChange']==_0x87cfff&&_0x15491b['push']('ck-suggestion-marker--active'),{'classes':_0x15491b,'attributes':{'data-change-id':_0x481555}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x3c58bd=>{_0x3c58bd['on']('element:pre',(_0x119775,_0x28be38,_0x109814)=>{const _0x2cfc24=_0x28be38['viewItem']['getChild'](0x0);if(!_0x2cfc24||!_0x2cfc24['is']('element','code'))return;if(!_0x109814['consumable']['consume'](_0x2cfc24,{'attributes':['vid_start','vid_end']}))return;const _0x493f41=_0x28be38['modelRange']['start']['nodeAfter'];_0x109814['writer']['setAttribute']('vid_start',_0x2cfc24['getAttribute']('vid_start'),_0x493f41),_0x109814['writer']['setAttribute']('vid_end',_0x2cfc24['getAttribute']('vid_end'),_0x493f41);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x306aa4=>{_0x306aa4['on']('element',(_0x2d54e3,_0x316e73,_0x399f08)=>{if(!_0x399f08['consumable']['consume'](_0x316e73['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x316e73['modelRange']['isCollapsed'])return;const _0x305d00=_0x316e73['modelRange']['start']['nodeAfter'];_0x305d00['hasAttribute']('vid_start')||_0x305d00['hasAttribute']('vid')||(_0x399f08['writer']['setAttribute']('vid_start',_0x316e73['viewItem']['getAttribute']('vid_start'),_0x305d00),_0x399f08['writer']['setAttribute']('vid_end',_0x316e73['viewItem']['getAttribute']('vid_end'),_0x305d00));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x433ac7=>_0x433ac7['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x32080d,[,_0x26d9ea])=>{['vid_start','vid_end','vid']['includes'](_0x26d9ea)&&(_0x32080d['return']=!0x0,_0x32080d['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x137bfe=>{_0x137bfe['on']('attribute:vid',(_0x49e4db,_0x4e1bb5,_0x3a541c)=>{if('\x20'!=_0x4e1bb5['item']['data']||_0x4e1bb5['item']['parent']['maxOffset']>0x1)return;if(!_0x3a541c['consumable']['consume'](_0x4e1bb5['item'],_0x49e4db['name']))return;const _0x336410=_0x3a541c['writer'],_0x261946=_0x3a541c['mapper']['toViewRange'](_0x4e1bb5['range']);_0x336410['wrap'](_0x261946,_0x336410['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x5102a1){const _0x59a26e=_0x5102a1['plugins']['get']('RevisionViewer');return(_0x13a152,_0x2d8a2f,_0x1b0882)=>{const _0x75ac67=_0x2d8a2f['markerName']['split'](':')[0x1],_0x4400b7=_0x59a26e['_getChangeFromId'](_0x75ac67);if(!_0x4400b7)return null;const _0x23654c='add'==_0x4400b7['type']?'split':'merge';if(!_0x1b0882['consumable']['test'](_0x2d8a2f['markerRange'],_0x13a152['name']))return;const _0x3004ba=_0x2d8a2f['markerRange']['getWalker'](),_0x28c18f=_0x2d8a2f['markerRange']['start'],_0x35051c=_0x5102a1['model']['schema'];let _0xa25acb=null,_0x2012e3=null,_0x13397d=!0x1,_0x3ef06b=!0x1;for(const _0x563f63 of _0x3004ba){const _0x1413a0=_0x563f63['item'];_0x13397d=_0x13397d||_0x35051c['isContent'](_0x1413a0);const _0x188a5a=_0x1b0882['mapper']['toViewElement'](_0x1413a0);if(_0x188a5a&&_0x188a5a['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x563f63['type']&&(_0x35051c['isBlock'](_0x1413a0)&&!_0x35051c['isLimit'](_0x1413a0)&&(_0x1413a0['nextSibling']||_0x28c18f['isAtEnd']?_0xa25acb&&_0xa25acb['parent']==_0x1413a0||(_0xa25acb=_0x1413a0,_0x3e41c1(_0x563f63['previousPosition']),_0x3ef06b=!0x0):_0x2012e3=_0x2012e3||_0x563f63['previousPosition']));}function _0x3e41c1(_0x3358f9){const _0x45b2e0=_0x1b0882['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x23654c}),_0x1195fd=_0x1b0882['mapper']['toViewPosition'](_0x3358f9);_0x4400b7['data']['isSuggestion']&&_0x1b0882['writer']['addClass']('ck-suggestion-marker-'+_0x23654c+'-new',_0x45b2e0),_0x59a26e['activeChange']==_0x4400b7&&_0x1b0882['writer']['addClass']('ck-suggestion-marker--active',_0x45b2e0),_0x1b0882['writer']['insert'](_0x1195fd,_0x45b2e0),_0x1b0882['mapper']['bindElementToMarker'](_0x45b2e0,_0x2d8a2f['markerName']);}_0x13397d||_0x3ef06b||!_0x2012e3||_0x3e41c1(_0x2012e3);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0xdd16d3,_0x1f7dba,_0xc78fdb)=>{const _0x33f97a=_0xc78fdb['mapper']['markerNameToElements'](_0x1f7dba['markerName']);if(_0x33f97a){for(const _0x25b8e4 of _0x33f97a)(_0x25b8e4['hasClass']('ck-suggestion-marker-split')||_0x25b8e4['hasClass']('ck-suggestion-marker-merge'))&&(_0xc78fdb['mapper']['unbindElementFromMarkerName'](_0x25b8e4,_0x1f7dba['markerName']),_0xc78fdb['writer']['remove'](_0x25b8e4));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x59c531,_0x5636a0,_0xa22c9c)=>{const _0x4e11e6=_0x5636a0['markerName']['split'](':')[0x1],_0x4b07a6=this['_getChangeFromId'](_0x4e11e6);if(!_0x4b07a6)return null;const _0x61aab8='add'==_0x4b07a6['type']?'split':'merge';if(_0xa22c9c['consumable']['test'](_0x5636a0['markerRange'],_0x59c531['name']))for(const _0xe7e2f7 of _0x5636a0['markerRange']['getItems']()){if(!_0xe7e2f7['is']('element','softBreak'))continue;const _0x2fa5ec=_0xa22c9c['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x61aab8}),_0x3353b3=_0xa22c9c['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0xe7e2f7));_0x4b07a6['data']['isSuggestion']&&_0xa22c9c['writer']['addClass']('ck-suggestion-marker-'+_0x61aab8+'-new',_0x2fa5ec),this['activeChange']==_0x4b07a6&&_0xa22c9c['writer']['addClass']('ck-suggestion-marker--active',_0x2fa5ec),_0xa22c9c['writer']['insert'](_0x3353b3,_0x2fa5ec),_0xa22c9c['mapper']['bindElementToMarker'](_0x2fa5ec,_0x5636a0['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x59174a=>{for(const _0x1d0cad of this['editor']['model']['document']['getRootNames']()){const _0x295ddc=this['editor']['model']['document']['getRoot'](_0x1d0cad),_0x153c8f=this['editor']['editing']['view']['document']['getRoot'](_0x1d0cad);if(_0x153c8f){const _0x44a712=_0x295ddc['getAttribute']('revisionHistoryAttachChange');if(_0x59174a['removeAttribute']('data-change-id',_0x153c8f),_0x59174a['removeClass']('ck-revision-history-root-add',_0x153c8f),_0x59174a['removeClass']('ck-revision-history-root-remove',_0x153c8f),_0x59174a['removeClass']('ck-revision-history-root--active',_0x153c8f),_0x44a712){const _0x2c8571=this['_getChangeFromId'](_0x44a712);if(!_0x2c8571)return null;_0x59174a['setAttribute']('data-change-id',_0x44a712,_0x153c8f),_0x59174a['addClass']('ck-revision-history-root-'+_0x2c8571['type'],_0x153c8f),this['activeChange']==_0x2c8571&&_0x59174a['addClass']('ck-revision-history-root--active',_0x153c8f);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x533233=>'revision-comment:'+_0x533233,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x476aa4=>'revision-suggestion:'+_0x476aa4,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x238c97=>({'name':'suggestion:'+_0x238c97,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0xc07d94=>{const _0x3def0a=_0xc07d94['markerName']['split'](':')[0x1];return'insertion'!=_0x3def0a&&'deletion'!=_0x3def0a?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x3def0a]};}}),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',(_0x1396e6,_0x3f8787,_0x5aab16)=>{const _0x4123c7=_0x5aab16['mapper']['markerNameToElements'](_0x3f8787['markerName']);if(_0x4123c7){for(const _0x329a75 of _0x4123c7)_0x329a75['is']('uiElement')&&(_0x5aab16['mapper']['unbindElementFromMarkerName'](_0x329a75,_0x3f8787['markerName']),_0x5aab16['writer']['remove'](_0x329a75));}},{'priority':'high'});}['_getChangeFromId'](_0x262c79){return this['_changeIdToChange']['get'](_0x262c79);}['_getViewForChange'](_0x35579d){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new z(this['editor']['locale'],_0x35579d),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x1f1041,_0x349de9,_0x207730,_0x150ebd)=>{_0x150ebd&&this['_balloon']['remove'](_0x150ebd),_0x207730&&(this['_balloon']['add']({'view':_0x207730,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x32cacc=this['editor']['editing'],_0x5881da=this['_getChangeFromId'](_0x207730['changeId']);let _0x18c461;if(_0x5881da['data']['isOnRoot']){const _0x13a65a=_0x32cacc['view']['getDomRoot'](_0x5881da['rootName']);_0x18c461=Array['from'](_0x13a65a['getClientRects']());}else{const _0x3225eb=this['editor']['model']['markers']['get']('revision:'+_0x207730['changeId']);_0x18c461=Array['from'](_0x32cacc['mapper']['markerNameToElements'](_0x3225eb['name']))['map'](_0x5b7adb=>_0x32cacc['view']['domConverter']['mapViewToDom'](_0x5b7adb))['map'](_0x1420c9=>Array['from'](_0x1420c9['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x18c461[0x0];return _0x18c461['find'](_0x22297a=>_0x22297a['top']-0x3<=this['_activeViewTarget']['y']&&_0x22297a['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x22297a['left']-0x3<=this['_activeViewTarget']['x']&&_0x22297a['right']+0x3>=this['_activeViewTarget']['x'])||_0x18c461[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x1f5f3e,_0x22c717,_0x19e68d,_0x46049d)=>{this['activeView']=_0x19e68d?this['_getViewForChange'](_0x19e68d):null,this['editor']['model']['change'](()=>{const _0x110a0e=this['editor']['editing'];_0x46049d&&(_0x46049d['data']['isOnRoot']?_0x110a0e['view']['change'](_0x5b9ff1=>{_0x5b9ff1['removeClass']('ck-revision-history-root--active',_0x110a0e['view']['document']['getRoot'](_0x46049d['rootName']));}):_0x110a0e['reconvertMarker']('revision:'+_0x46049d['id'])),_0x19e68d&&(_0x19e68d['data']['isOnRoot']?_0x110a0e['view']['change'](_0x602e30=>{_0x602e30['addClass']('ck-revision-history-root--active',_0x110a0e['view']['document']['getRoot'](_0x19e68d['rootName']));}):_0x110a0e['reconvertMarker']('revision:'+_0x19e68d['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x26aef1,_0x17c1b7)=>{if(this['activeChange'])return;const _0x599abe=this['_findChangeIdFromDomTarget'](_0x17c1b7['target']),_0x4c1fa2=this['_changeIdToChange']['get'](_0x599abe);_0x4c1fa2?(this['_activeViewTarget']={'x':_0x17c1b7['domEvent']['x'],'y':_0x17c1b7['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x4c1fa2)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x2da82f,_0x134b7f)=>{const _0x552786=this['_findChangeIdFromDomTarget'](_0x134b7f['target']),_0xfe3f7=this['_changeIdToChange']['get'](_0x552786);_0xfe3f7?(this['_activeViewTarget']={'x':_0x134b7f['domEvent']['x'],'y':_0x134b7f['domEvent']['y']},_0xfe3f7===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0xfe3f7):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x284237){do{const _0x467e75=_0x284237['getAttribute']('data-change-id');if(_0x467e75)return _0x467e75;_0x284237=_0x284237['parent'];}while(_0x284237);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x579b3c=>{for(const _0x380aa6 of this['editor']['model']['markers'])_0x579b3c['removeMarker'](_0x380aa6);});}}function Q(_0x47bf57,_0x505529){return(_0x1a5755,_0x4c603a,_0x31b944)=>{if(!_0x31b944['consumable']['test'](_0x4c603a['markerRange'],_0x1a5755['name']))return;const _0x16b4c8=_0x4c603a['markerRange']['getWalker'](),_0x582f25=_0x4c603a['markerRange']['start'],_0x5735b8=_0x47bf57['model']['schema'];let _0x3ab713=null,_0x3b52f6=null,_0x2b4319=!0x1,_0x1643c5=!0x1;for(const _0xfa4264 of _0x16b4c8){const _0x28702b=_0xfa4264['item'];_0x2b4319=_0x2b4319||_0x5735b8['isContent'](_0x28702b);const _0x1d9a61=_0x31b944['mapper']['toViewElement'](_0x28702b);if(_0x1d9a61&&_0x1d9a61['getCustomProperty']('addHighlight'))return;'elementEnd'==_0xfa4264['type']&&(_0x5735b8['isBlock'](_0x28702b)&&!_0x5735b8['isLimit'](_0x28702b)&&(_0x28702b['nextSibling']||_0x582f25['isAtEnd']?_0x3ab713&&_0x3ab713['parent']==_0x28702b||(_0x3ab713=_0x28702b,_0x2e6691(_0xfa4264['previousPosition']),_0x1643c5=!0x0):_0x3b52f6=_0x3b52f6||_0xfa4264['previousPosition']));}function _0x2e6691(_0x4633fc){const _0x32def0=_0x31b944['mapper']['toViewPosition'](_0x4633fc),_0x3ad943=_0x31b944['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x505529});_0x31b944['writer']['insert'](_0x32def0,_0x3ad943),_0x31b944['mapper']['bindElementToMarker'](_0x3ad943,_0x4c603a['markerName']);}_0x2b4319||_0x1643c5||!_0x3b52f6||_0x2e6691(_0x3b52f6);};}class nt extends _0x15d826{constructor(_0x46fa76){super(_0x46fa76);const _0x5e7097=_0x46fa76['plugins']['get'](u);this['affectsData']=!0x1,this['listenTo'](_0x5e7097,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x5e7097,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x3c093c=this['editor'],_0x4a5cf9=_0x3c093c['plugins']['get'](u),_0x545211=_0x4a5cf9['isReady']?_0x4a5cf9['diff']['newRevisionId']:null;_0x3c093c['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x545211);}['refresh'](){const {isReady:_0x346e24,isEnabled:_0x1c30f4,repository:_0x2088f,diff:_0x23fbe2}=this['editor']['plugins']['get'](u),_0x56bb70=_0x23fbe2&&_0x2088f['getLaterVisibleRevision'](_0x23fbe2['newRevisionId']);this['isEnabled']=_0x346e24&&_0x1c30f4&&Boolean(_0x56bb70);}}class ot extends _0x15d826{['_step'];constructor(_0x4c541e,{direction:_0x239823}){super(_0x4c541e);const _0x4093d0=_0x4c541e['plugins']['get'](u);this['affectsData']=!0x1,this['_step']='forward'===_0x239823?0x1:-0x1,this['listenTo'](_0x4093d0,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x4093d0,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x4093d0,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x36c16b=this['editor'],_0x3cd399=_0x36c16b['plugins']['get'](u),{isNavigationMode:_0x275123,currentChangeNumber:_0x29b4db}=_0x3cd399;let _0x4b2f45;if(_0x3cd399['activeChange']=_0x275123?_0x3cd399['diff']['changes']['get'](_0x29b4db+this['_step']):_0x3cd399['diff']['changes']['first'],_0x3cd399['activeChange']['data']['isOnRoot'])_0x4b2f45=_0x36c16b['editing']['view']['getDomRoot'](_0x3cd399['activeChange']['rootName']);else{const _0x71b4b6=_0x36c16b['model']['markers']['get']('revision:'+_0x3cd399['activeChange']['id']);_0x4b2f45=_0x189758(_0x36c16b['editing'],_0x71b4b6);}_0x3813c7({'target':_0x4b2f45,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x21f39d,currentChangeNumber:_0x4f79f7,numberOfChanges:_0x457701,isReady:_0x4d3668,isEnabled:_0x7d84ca}=this['editor']['plugins']['get'](u);this['isEnabled']=!!(_0x7d84ca&&_0x4d3668&&_0x457701)&&(!_0x21f39d||(0x1===this['_step']?_0x4f79f7<_0x457701-0x1:_0x4f79f7>0x0));}}class Ri extends _0x3cfa23{constructor(_0x2272e4){super(_0x2272e4);const _0x4bbb1e=this['bindTemplate'],_0x29ef05=new _0x58da02(_0x2272e4),_0x18411c=new _0x58da02(_0x2272e4);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',(_0x515f64,_0x3ca90b)=>_0x515f64&&_0x3ca90b>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x221fcf,_0x17ea8a,_0x5c68c7,_0x1219c8)=>{if(!_0x221fcf)return m(_0x2272e4,'Loading...');if(!_0x5c68c7)return m(_0x2272e4,'No\x20changes');const _0x27ee60=m(_0x2272e4,'NUMBER_OF_CHANGES',_0x5c68c7);return _0x1219c8?m(_0x2272e4,'X_OF_Y_CHANGES',[_0x17ea8a+0x1,_0x5c68c7]):_0x27ee60;}),_0x29ef05['set']({'label':m(_0x2272e4,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x2d2d82}),_0x18411c['set']({'label':m(_0x2272e4,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0xc8bb2a}),_0x29ef05['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x18411c['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x29ef05['on']('execute',()=>this['fire']('execute','backward')),_0x18411c['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',_0x4bbb1e['if']('_isStatusLabelVisible','ck-hidden',_0x2f97af=>!_0x2f97af)]},'children':[{'text':_0x4bbb1e['to']('isNavigationMode',_0x4cfea7=>_0x4cfea7?m(_0x2272e4,'EDIT_X_OF_Y_REVISIONS')+':\x20':m(_0x2272e4,'Total')+':\x20')}]},{'text':_0x4bbb1e['to']('_statusText')}]},new _0x27d032(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x29ef05,_0x18411c]}]});}}const ge='ck-editor__editable__loading-overlay';class ji extends _0x237363{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x191e49=this['editor']['editing']['view'];_0x191e49['change'](_0x5c8226=>{for(const _0x3116e9 of _0x191e49['document']['roots'])_0x5c8226['addClass'](ge,_0x3116e9);});}['hide'](){const _0x5a9e00=this['editor']['editing']['view'];_0x5a9e00['change'](_0x1146a3=>{for(const _0x179707 of _0x5a9e00['document']['roots'])_0x1146a3['removeClass'](ge,_0x179707);});}}class v extends _0x237363{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u,ji];}['init'](){const _0x3be16d=this['editor'],_0x47da94=_0x3be16d['plugins']['get'](u),_0x2530b3=_0x3be16d['plugins']['get'](ji);_0x3be16d['ui']['componentFactory']['add']('exitToEditing',_0x27f9bd=>{const _0x1a3925=new _0x58da02(_0x27f9bd);return _0x1a3925['set']({'label':m(_0x27f9bd,'Back\x20to\x20editing'),'icon':_0x2c316f,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x1a3925,'execute',()=>{_0x3be16d['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x1a3925;}),_0x3be16d['ui']['componentFactory']['add']('restoreRevision',_0x46a6c0=>{const _0x4bef2b=new _0x58da02(_0x46a6c0);return _0x4bef2b['set']({'label':m(_0x46a6c0,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x4bef2b['bind']('isEnabled')['to'](_0x3be16d['commands']['get']('restoreRevision')),this['listenTo'](_0x4bef2b,'execute',()=>_0x3be16d['execute']('restoreRevision')),_0x4bef2b;}),_0x3be16d['ui']['componentFactory']['add']('changesNavigation',_0x155c2c=>{const _0x4885fa=new Ri(_0x155c2c),_0x2725b6=_0x3be16d['commands']['get']('showPreviousChange'),_0x1ef960=_0x3be16d['commands']['get']('showNextChange');return _0x4885fa['bind']('isBackwardNavigationEnabled')['to'](_0x2725b6,'isEnabled'),_0x4885fa['bind']('isForwardNavigationEnabled')['to'](_0x1ef960,'isEnabled'),_0x4885fa['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x47da94),this['listenTo'](_0x4885fa,'execute',(_0x45e4cf,_0x59b760)=>{_0x3be16d['execute']('forward'===_0x59b760?'showNextChange':'showPreviousChange');}),_0x4885fa;}),_0x2530b3['show'](),_0x47da94['on']('change:isReady',(_0x3a0656,_0x3dd9a7,_0x2332cd)=>{_0x2332cd?_0x2530b3['hide']():_0x2530b3['show']();});}}class li extends ti{['_resizeObserver']=null;constructor(_0xa54896,_0x94b57f){super(_0xa54896,_0x94b57f);const _0x233231=this['bindTemplate'];this['set']({'label':m(_0xa54896,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=m(_0xa54896,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x233231['to']('_tooltipString'),'data-cke-tooltip-position':'s','data-cke-tooltip-class':'ck-tooltip_multi-line'}});}['render'](){super['render'](),this['_resizeObserver']=new et(this['fieldView']['element'],()=>this['_updateTooltipText']()),this['listenTo'](this['fieldView'],'input',()=>this['_updateTooltipText']());}['destroy'](){super['destroy'](),this['_resizeObserver']&&this['_resizeObserver']['destroy']();}['_updateTooltipText'](){const _0x4653e7=this['fieldView']['element'];this['_tooltipString']=_0x4653e7['scrollWidth']>_0x4653e7['clientWidth']&&_0x4653e7['value']||'';}}class vi extends _0x3cfa23{constructor(_0x5651cb,_0x257952,_0xb6a579){super(_0x5651cb);const _0x1cb03f=new _0x44d27e();_0x1cb03f['set']({'content':_0x37f372,'viewBox':'0\x200\x2011\x2010'});const _0x905c3a=['ck','ck-revision-history-sidebar__revision-author'];_0xb6a579&&_0x905c3a['push']('ck-revision-history-sidebar__revision-author_creator');const _0x4766f8=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':m(_0x5651cb,_0xb6a579?'Revision\x20creator':'Revision\x20author')},'children':[_0x1cb03f,_0x257952['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x905c3a},'children':_0x4766f8});}}function mi(_0x158bed,_0x7bca8c){const _0x2cb80e=_0x158bed['bindTemplate'],_0x50a6ec=_0x158bed['locale'],_0x15df77=_0x408b44(_0x50a6ec);_0x15df77['panelPosition']='sw';const _0x1813c4=function(_0x16c368,_0x47f6a7){const _0x3df085=function(_0x289677,_0x395c98){const _0x2ea688=_0x289677['locale'],_0x42ff5d={'Compare\x20against\x20selected':m(_0x2ea688,'Compare\x20against\x20selected'),'Name\x20this\x20revision':m(_0x2ea688,'Name\x20this\x20revision'),'Restore\x20this\x20revision':m(_0x2ea688,'Restore\x20this\x20revision')};return _0x395c98['map'](_0x450a66=>{const _0x592919=_0x42ff5d[_0x450a66['name']];return _0x592919&&_0x592919!==_0x450a66['name']&&(_0x450a66['name']=_0x592919),_0x450a66;});}(_0x16c368,_0x47f6a7),_0x45b71b=new _0x17dfa9();for(const _0x4de72f of _0x3df085){const _0x4f6ef3={'type':'button','model':new to({'label':_0x4de72f['name'],'class':_0x4de72f['class'],'withText':!0x0,'role':'menuitem','_action':_0x4de72f['action']})};_0x4f6ef3['model']['bind']('isEnabled')['to'](_0x16c368,'isActionsDropdownOpen',_0x309f6c=>'function'!=typeof _0x4de72f['isEnabled']||(!_0x309f6c||_0x4de72f['isEnabled'](_0x16c368))),_0x45b71b['add'](_0x4f6ef3);}return _0x45b71b;}(_0x158bed,_0x7bca8c);return _0x158bed['bind']('isActionsDropdownOpen')['to'](_0x15df77,'isOpen'),_0x15df77['buttonView']['set']({'label':m(_0x50a6ec,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x59d1ed}),_0x15df77['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x2cb80e['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x2cb80e['to'](_0x2479ae=>_0x2479ae['stopPropagation']())}}),_0x15df77['on']('execute',_0x424d54=>{_0x158bed['isReady']&&'function'==typeof _0x424d54['source']['_action']&&_0x424d54['source']['_action'](_0x158bed);}),_0x4d8904(_0x15df77,_0x1813c4,{'role':'menu'}),_0x15df77['listenTo'](_0x158bed,'change:isActionsDropdownOpen',(_0x5e9173,_0x3ffc59,_0x1ad025)=>{if(_0x1ad025)for(const _0x1e6d1b of _0x15df77['listView']['items']){const _0x5d9b28=_0x1e6d1b['children']['first'],_0x16fce9=_0x7bca8c['find'](_0x4bf552=>_0x4bf552['action']===_0x5d9b28['_action'])['isVisible'];_0x1e6d1b['isVisible']=void 0x0===_0x16fce9||_0x16fce9(_0x158bed);}}),_0x15df77;}class pi extends/* #__PURE__ -- @preserve */
27
+ _0x588598(_0x3cfa23){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0xaa09cb,_0x1e00b0,_0x5f51d8,_0x199a94){super(_0xaa09cb);const _0x14c512=this['bindTemplate'],_0xc99fb4=function(_0x3e609e,_0x422e12){const _0x2ba50c=Array['from'](_0x422e12['authors'])['filter'](_0x484779=>_0x484779!=_0x422e12['creator']);return _0x422e12['creator']&&_0x2ba50c['unshift'](_0x422e12['creator']),_0x2ba50c['map'](_0x450466=>new vi(_0x3e609e,_0x450466,_0x450466==_0x422e12['creator']));}(_0xaa09cb,_0x1e00b0);this['id']=_0x1e00b0['id'],this['_revision']=_0x1e00b0,this['_requireRevisionName']=_0x199a94,this['bind']('name','createdAt')['to'](_0x1e00b0),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x3139bd=>{return _0x4c8fa8=_0xaa09cb['uiLanguage'],(_0x3904b6=_0x3139bd)['toLocaleDateString'](_0x4c8fa8,{'month':'long','day':'numeric'})+',\x20'+_0x3904b6['toLocaleTimeString'](_0x4c8fa8,{'hour':'numeric','minute':'numeric'});var _0x4c8fa8,_0x3904b6;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new li(_0xaa09cb,_0x5802d2),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x20aba6=>_0x20aba6||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x31cf50,_0x39e07b)=>_0x31cf50&&_0x39e07b),this['revisionActionsView']=_0x5f51d8&&_0x5f51d8['length']?mi(this,_0x5f51d8):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x14c512['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x14c512['if']('isEnabled','ck-disabled',_0x2d7a2e=>!_0x2d7a2e),_0x14c512['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x14c512['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x14c512['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':_0x14c512['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':_0xc99fb4}]},this['revisionActionsView']],'on':{'click':_0x14c512['to'](_0x4a7727=>{_0x4a7727['srcElement']['closest']('.ck-confirm-view')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x407bd1=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x407bd1,'change',()=>{this['_requireRevisionName']&&!_0x407bd1['value']||this['fire']('setName',{'id':this['id'],'name':_0x407bd1['value']}),_0x407bd1['value']||(_0x407bd1['value']=this['name']?this['name']:this['_createdAtFormatted']);});}['select'](){this['isSelected']=!0x0;}['deselect'](){this['isSelected']=!0x1;}['highlight'](){this['isHighlighted']=!0x0;}['unhighlight'](){this['isHighlighted']=!0x1;}}function bi(_0x4b19c1,_0x5b521d){const _0x2523dd=_0x320207['fromJSDate'](_0x4b19c1)['setLocale'](_0x5b521d),_0x5a9af5=_0x320207['local'](),_0x11aa84=_0x5a9af5['minus']({'days':0x1})['startOf']('day');let _0x1a8bd3,_0x1fab74;return _0x2523dd['hasSame'](_0x5a9af5,'day')?(_0x1a8bd3=_0x2523dd['startOf']('day')['toJSDate'](),_0x1fab74=_0x2523dd['toRelativeCalendar']()):_0x2523dd['hasSame'](_0x11aa84,'day')?(_0x1a8bd3=_0x11aa84['toJSDate'](),_0x1fab74=_0x2523dd['toRelativeCalendar']()):_0x2523dd['hasSame'](_0x5a9af5,'week')?(_0x1a8bd3=_0x2523dd['startOf']('week')['toJSDate'](),_0x1fab74=_0x2523dd['weekdayLong']||''):_0x2523dd['hasSame'](_0x5a9af5,'year')?(_0x1a8bd3=_0x2523dd['startOf']('month')['toJSDate'](),_0x1fab74=_0x2523dd['monthLong']||''):(_0x1a8bd3=_0x2523dd['startOf']('year')['toJSDate'](),_0x1fab74=String(_0x2523dd['year'])),{'startDate':_0x1a8bd3,'localizedPeriodName':_0x1fab74};}class fi extends _0x3cfa23{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x482003,_0x875d4e,_0x12adb1,_0x45808b){super(_0x482003);const _0x1e31e4=bi(_0x875d4e,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x875d4e,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x12adb1,this['_requireRevisionName']=_0x45808b,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':_0x1e31e4}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x11807e){const _0x475f0d=new pi(this['locale'],_0x11807e,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x475f0d);}['removeRevision'](_0x547ec6){const _0xb69358=this['revisionViews']['find'](_0x3b47e2=>_0x3b47e2['id']===_0x547ec6['id']);this['revisionViews']['remove'](_0xb69358);}}class ki extends _0x3cfa23{constructor(_0x55d5e7){super(_0x55d5e7);const _0x24c1f2=new _0x44d27e();_0x24c1f2['content']=_0x509fac,this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x24c1f2,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[m(_0x55d5e7,'Revision\x20history')]}]});}}class ui extends _0x3cfa23{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x2de3a6,_0x57f352,_0x767837,_0x8ddf66){super(_0x2de3a6);const _0x383bc4=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x57f352,this['_revisionActions']=_0x767837,this['_requireRevisionName']=_0x8ddf66,this['on']('select',(_0x202058,_0x656999)=>{this['fire']('revisionSelected',_0x656999);}),this['on']('setName',(_0x159c48,_0x10dce0)=>{this['fire']('revisionSetName',_0x10dce0);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new ki(_0x2de3a6),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x383bc4['if']('isEnabled','ck-disabled',_0x33b145=>!_0x33b145)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0xef1e6d of this['_revisions'])this['_addRevision'](_0xef1e6d);this['_revisions']['on']('add',(_0x328ae3,_0x529514)=>{this['_addRevision'](_0x529514);}),this['_revisions']['on']('remove',(_0x208330,_0x29031d)=>{this['_removeRevision'](_0x29031d);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x1fcc5f=>_0x1fcc5f['revisionViews']['map'](_0x56809f=>_0x56809f))['flat']();}['selectRevision'](_0x11f1bd){for(const _0x257113 of this['revisionViews'])_0x11f1bd&&_0x11f1bd['id']===_0x257113['id']?_0x257113['select']():_0x257113['deselect']();}['highlightRevisions'](_0xb3ee0d){for(const _0x5a1f5d of this['revisionViews'])_0xb3ee0d['some'](({id:_0x132f93})=>_0x132f93===_0x5a1f5d['id'])?_0x5a1f5d['highlight']():_0x5a1f5d['unhighlight']();}['_addRevision'](_0x446149){const _0x57e706=bi(_0x446149['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x4e830e=this['timePeriodViews']['get'](0x0);_0x4e830e&&_0x4e830e['startDate']['getTime']()===_0x57e706['getTime']()||(_0x4e830e=new fi(this['locale'],_0x57e706,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x4e830e)),_0x4e830e['addRevision'](_0x446149);}['_removeRevision'](_0x1b89ce){const _0xbd0d6=bi(_0x1b89ce['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0xbd0d6)['removeRevision'](_0x1b89ce);}['_getTimePeriodViewByStartDate'](_0x42ee5c){return this['timePeriodViews']['find'](_0x515df9=>_0x515df9['startDate']['getTime']()===_0x42ee5c['getTime']());}}class d extends _0x237363{['_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(_0x372643){super(_0x372643),this['_revisionViewer']=_0x372643['plugins']['get'](u),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x410ec4=this['_revisionsRepository']['_revisions'],_0xca5cc8=this['_createRevisionActions'](),_0xb2da05=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new di(this['editor']['locale'],_0x410ec4,_0xca5cc8,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',(_0x184efe,_0x4bcf0f)=>{_0x4bcf0f['revisionViews']['on']('add',(_0x2dd409,_0x22bf00)=>{_0x22bf00['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)),_0xb2da05['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x3d51dc=this['_revisionsRepository']['getRevision'](0x0);if(_0x3d51dc){const _0x257f88=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x3d51dc['id']);this['_revisionViewer']['compare'](_0x3d51dc,_0x257f88);}}['_handleRevisionSelected'](_0xb72c9e,_0xe21a22){const _0x5e7e5e=this['_revisionsRepository']['getRevision'](_0xe21a22['id']),_0x44a599=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x5e7e5e['id']);this['_revisionViewer']['compare'](_0x5e7e5e,_0x44a599);}['_handleRevisionSetName'](_0xaf51f3,_0x403c3f){this['_revisionsRepository']['getRevision'](_0x403c3f['id'])['setName'](_0x403c3f['name']);}['_handleDiffChange'](_0x5dd7b,_0x1a4b21,_0x42f639){const _0x13ac3a=this['_revisionsRepository']['getRevisionsInDiff'](_0x42f639);_0x13ac3a['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x13ac3a),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x13ac3a[0x0]));}['_createRevisionActions'](){const _0x2dffa9=this['editor'],_0x2fe4fc=d['availableRevisionActions'],_0x365448=_0x2dffa9['config']['get']('revisionHistory.revisionActions')||d['defaultRevisionActions'];if(_0x365448['length'])return _0x365448['map'](_0x440d1b=>{const _0x3351d1='string'==typeof _0x440d1b?Object['assign']({},_0x2fe4fc[_0x440d1b]):_0x440d1b;return _0x3351d1['action']=_0x3351d1['action']['bind'](this,_0x2dffa9),_0x3351d1['isVisible']&&(_0x3351d1['isVisible']=_0x3351d1['isVisible']['bind'](this,_0x2dffa9)),_0x3351d1;});}}function at(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0xc8c1fc},_0x17b2a0)=>{const _0x5aba86=_0xc8c1fc['get'](u),_0x6afaea=_0x5aba86['repository'];let _0x231f17=_0x5aba86['diff']['newRevisionId'],_0xca5856=_0x17b2a0['id'];_0x6afaea['getIndex'](_0x231f17)>_0x6afaea['getIndex'](_0xca5856)&&([_0x231f17,_0xca5856]=[_0xca5856,_0x231f17]),_0x5aba86['compare'](_0x231f17,_0xca5856);},'isVisible':({plugins:_0x266f37},_0x370f50)=>{const _0x30c930=_0x266f37['get'](u);return!(_0x30c930['repository']['getRevisionsInDiff'](_0x30c930['diff'])['length']>0x2)&&!_0x370f50['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x4c771e,{id:_0x2b0a20})=>{_0x4c771e['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x2b0a20);},'isVisible':({plugins:_0x1172dc},_0x3f6216)=>!!_0x1172dc['get'](u)['repository']['getLaterVisibleRevision'](_0x3f6216['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x5138c3},{id:_0x42c1e2,revisionNameView:_0x919c3f})=>{const _0x38c180=_0x5138c3['get'](u),_0x521710=_0x38c180['repository']['getEarlierVisibleRevision'](_0x42c1e2);_0x38c180['compare'](_0x42c1e2,_0x521710),_0x919c3f['focus'](),_0x919c3f['fieldView']['select']();}}};}class Z extends tt{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x53e0b5,_0x19dc3f){super(_0x53e0b5),this['_view']=_0x19dc3f,this['_toolbarConfig']=st(_0x53e0b5['config']['get']('toolbar')),this['_elementReplacer']=new it();}get['element'](){return this['view']['element'];}['init'](_0x58593a){const _0x2344ac=this['editor'],_0x3630ec=this['view'],_0x519a10=_0x2344ac['editing']['view'],_0x1f6849=_0x3630ec['editable'],_0x55b6c8=_0x519a10['document']['getRoot']();_0x1f6849['name']=_0x55b6c8['rootName'],_0x3630ec['render']();const _0x487788=_0x1f6849['element'];this['setEditableElement'](_0x1f6849['name'],_0x487788),_0x3630ec['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x519a10['attachDomRoot'](_0x487788),this['_elementReplacer']['replace'](_0x58593a,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0xaadb9a=this['view'],_0x5a7f88=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x5a7f88['detachDomRoot'](_0xaadb9a['editable']['name']),_0xaadb9a['destroy']();}['_initToolbar'](){const _0x2cd2e2=this['view'];_0x2cd2e2['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x2cd2e2['stickyPanel']['limiterElement']=_0x2cd2e2['element'],_0x2cd2e2['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x20d7bf})=>_0x20d7bf),_0x2cd2e2['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x2cd2e2['toolbar']);}}class ii extends _0x10dfd8{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x53b8fe,_0x28646f,_0x298453={}){super(_0x53b8fe),this['stickyPanel']=new _0x474490(_0x53b8fe),this['toolbar']=new _0x2f00f8(_0x53b8fe,{'shouldGroupWhenFull':_0x298453['shouldToolbarGroupWhenFull']}),this['_editable']=new te(_0x53b8fe,_0x28646f);}['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
- _0x57ec93(_0x18abd4){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x3fd2f7,_0x27b4a9){super(_0x27b4a9),this['sourceElement']=_0x3fd2f7,this['model']['document']['createRoot']();const _0x569a8c=new ii(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new Z(this,_0x569a8c);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x577861,_0x489649){const _0x19886d=new this(_0x577861,_0x489649);return await _0x19886d['initPlugins'](),await _0x19886d['ui']['init'](_0x577861),await _0x19886d['data']['init'](_0x19886d['config']['get']('initialData')||''),_0x19886d['fire']('ready'),_0x19886d;}}const p=['RevisionHistoryUI','RestrictedEditingMode','AIChat','AIReviewMode','AIBalloon','AIQuickActions','AIActions'];class ht extends _0x4b71e4{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0xc4dc27){function _0xa42d42(_0x565fe4){return _0x565fe4['map'](_0x1d6d51=>String['fromCharCode'](_0x1d6d51))['join']('');}super(_0xc4dc27),this['result']='end',_0xc4dc27[_0xa42d42([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0xa42d42([0x76,0x69,0x65,0x77])][_0xa42d42([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0xa42d42([0x61,0x75,0x74,0x6f]),_0xc4dc27[_0xa42d42([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0xa42d42([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0xa42d42([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0xa42d42([0x73,0x74,0x61,0x74,0x75,0x73])]:_0xa42d42([0x6f,0x6b])});}}class ct extends _0x4b71e4{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h,l];}constructor(_0x5b3cd4){if(super(_0x5b3cd4),!this['editor']['config']['get']('revisionHistory'))throw new _0x2520ea('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x142023=>this['_showRevisionViewer']({..._0x142023,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x322230=>this['_closeRevisionViewer'](_0x322230)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x39e880=>this['_restoreRevision'](_0x39e880)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x4d2491){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x4d2491;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x37bcb6){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x37bcb6);}['getRevision'](_0x46fb3b){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x46fb3b);}['getRevisions'](_0x4a6d1c){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x4a6d1c||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x398f89=this['editor'],_0x5e3678=_0x1498a0(_0x398f89,p),_0x499d97=_0x398f89['plugins']['get']('RevisionTracker'),_0x274b2c=_0x398f89['plugins']['get']('Users')['users'];return _0x5e3678['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x5e3678['lazyRoots'],(_0x5e3678['plugins']['push'](ht,u,v,class extends _0x4b71e4{static get['requires'](){return[u,'Users'];}['init'](){const _0x5b6939=this['editor']['plugins']['get']('Users');for(const _0x31298d of _0x274b2c)_0x31298d['isAnonymous']||_0x5b6939['getUser'](_0x31298d['id'])||_0x5b6939['addUser'](_0x31298d);const _0x12fb07=_0x499d97['repository']['getRevisions']();let _0x35709f=null;const _0x11bfd9=this['editor']['plugins']['get']('RevisionViewer');_0x11bfd9['adapter']=_0x499d97['adapter'],_0x11bfd9['bind']('isEnabled')['to'](_0x499d97),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x398f89,'isReadOnly',_0x48efd5=>!_0x48efd5);for(const _0x120e17 of _0x12fb07){const _0x5e9c68=null===_0x120e17['creator'];if(_0x5e9c68&&_0x120e17['toVersion']===_0x120e17['fromVersion'])continue;const _0x5acb11=_0x120e17['toJSON']();_0x11bfd9['addRevisionData'](_0x5acb11,(_0x3383cb,_0x3f1fc9,_0x17bef9)=>{if(_0x5e9c68){if(_0x35709f)_0x35709f['_update'](_0x3383cb,_0x3f1fc9);else{if(!_0x3f1fc9){const _0x31d2b7=_0x17bef9['toJSON']();_0x31d2b7['id']=_0x118ae2(),_0x499d97['saveRevision'](_0x31d2b7,_0x17bef9['toVersion'])['then'](_0x502360=>{_0x35709f=_0x502360;});}}}else _0x120e17['_update'](_0x3383cb,_0x3f1fc9);});}}},d),_0x5e3678);}['_enhanceShowRevisionViewerCallback'](){const _0x34219a=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x27868a=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x51b31a=this['editor']['plugins']['get']('Autosave');await _0x51b31a['save']();}else await _0x27868a['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x3531e2=this['editor']['plugins']['get']('Dialog');_0x3531e2['isOpen']&&_0x3531e2['hide']();}if(this['editor']['plugins']['has']('AITabs')){const _0x74f720=this['editor']['plugins']['get']('AITabs')['view']['panelViews'];for(const _0x380ff0 of _0x74f720)_0x380ff0['class']=_0x380ff0['class']?_0x380ff0['class']+'\x20ck-tab-panel_disabled':'ck-tab-panel_disabled';if(this['editor']['plugins']['has']('AIChat')){const _0x586906=document['querySelector']('.ck-ai-chat__prompt-input\x20.ck-textarea');_0x586906&&_0x586906['setAttribute']('tabindex','-1');}if(this['editor']['plugins']['has']('AIChatHistory')){const _0x31d4a2=document['querySelector']('.ck-ai-chat-history\x20.ck-input');_0x31d4a2&&_0x31d4a2['setAttribute']('tabindex','-1');}}const _0x3d235a=this['_getRevisionViewerEditorConfig']();return _0x34219a(_0x3d235a)['then'](_0x4f8665=>{return(this['_viewerEditor']=_0x4f8665,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'),_0x4f8665);})['catch'](_0x11f883=>(console['error'](_0x11f883),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x2b8731=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 _0x3c187c=this['editor']['plugins']['get']('AITabs')['view']['panelViews'];for(const _0x18d905 of _0x3c187c)_0x18d905['class']='ck-tab-panel_disabled'===_0x18d905['class']?'':_0x18d905['class']['replace']('\x20ck-tab-panel_disabled','');if(this['editor']['plugins']['has']('AIChat')){const _0x16d6fa=document['querySelector']('.ck-ai-chat__prompt-input\x20.ck-textarea');_0x16d6fa&&_0x16d6fa['removeAttribute']('tabindex');}if(this['editor']['plugins']['has']('AIChatHistory')){const _0x210e12=document['querySelector']('.ck-ai-chat-history\x20.ck-input');_0x210e12&&_0x210e12['removeAttribute']('tabindex');}}return this['_viewerEditor']['plugins']['get']('RevisionViewer')['_cleanUp'](),_0x2b8731(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0xdb1fd4=this['editor']['plugins']['get']('Annotations');_0xdb1fd4['refreshVisibility'](),_0xdb1fd4['refreshPositioning']();}});});}['_showRevisionViewer'](_0x22cc53){const _0xf4f987=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x5edcaf=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x3a68e3=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return f['create'](_0x3a68e3,_0x22cc53)['then'](_0x145d2f=>(_0x5edcaf['style']['display']='block',_0xf4f987['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x145d2f));}['_closeRevisionViewer'](_0x2265e1){const _0x56fb4b=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x56fb4b['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x2265e1['destroy']();}async['_restoreRevision'](_0x2d5c12){const _0x1e527b=this['editor'],_0x22ee1e=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x214ebf=_0x1e527b['plugins']['get']('RevisionTracker'),_0x3115cc=_0x1e527b['plugins']['get']('RevisionHistoryUtils'),_0x57b4c5=_0x22ee1e['repository']['getRevision'](_0x2d5c12);let _0x213d0e,_0x1a2f0c,_0xd7bbd4;try{await _0x3115cc['loadRevisionData'](_0x57b4c5,this['adapter']),_0x213d0e=_0x3115cc['getRevisionDocumentData'](_0x57b4c5),_0x1a2f0c=_0x3115cc['getRevisionRootsAttributes'](_0x57b4c5);}catch(_0x4f935f){return void console['error'](_0x4f935f);}_0x1e527b['model']['change'](_0x1d6848=>{for(const _0x3850d1 of Array['from'](_0x1e527b['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x1d6848['removeMarker'](_0x3850d1);}),_0x22ee1e['isReady']=!0x1,_0x1e527b['model']['enqueueChange'](_0x106b19=>{_0x106b19['setSelection'](null),_0x106b19['removeSelectionAttribute'](_0x1e527b['model']['document']['selection']['getAttributeKeys']());const _0x3b3c86=Object['keys'](_0x213d0e);for(const _0x6162be of _0x1e527b['model']['document']['roots'])'$graveyard'!=_0x6162be['rootName']&&_0x6162be['isAttached']()&&!_0x3b3c86['includes'](_0x6162be['rootName'])&&_0x106b19['detachRoot'](_0x6162be);for(const _0x348dc6 of _0x3b3c86){let _0x259722=_0x1e527b['model']['document']['getRoot'](_0x348dc6);_0x259722&&_0x259722['isAttached']()||(_0x259722=_0x106b19['addRoot'](_0x348dc6));const _0x3e16a4=_0x1a2f0c[_0x348dc6],_0x32a065=Object['keys'](_0x3e16a4),_0x1d8dbf=_0x213d0e[_0x348dc6];for(const _0xca6e9c of _0x259722['getAttributeKeys']())_0x32a065['includes'](_0xca6e9c)||_0x106b19['removeAttribute'](_0xca6e9c,_0x259722);for(const _0x6347a1 of _0x32a065)_0x106b19['setAttribute'](_0x6347a1,_0x1a2f0c[_0x348dc6][_0x6347a1],_0x259722);_0x106b19['remove'](_0x106b19['createRangeIn'](_0x259722)),_0x106b19['insert'](_0x1e527b['data']['parse'](_0x1d8dbf,_0x259722),_0x259722,0x0);}});const _0x137dfc=m(_0x1e527b['locale'],'Restored');if(_0x57b4c5['name'])_0xd7bbd4=-0x1==_0x57b4c5['name']['indexOf'](_0x137dfc)?_0x137dfc+':\x20'+_0x57b4c5['name']:_0x57b4c5['name'];else _0xd7bbd4=_0x137dfc+':\x20'+(_0x57b4c5['createdAt']['toLocaleDateString'](_0x1e527b['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x57b4c5['createdAt']['toLocaleTimeString'](_0x1e527b['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x214ebf['saveRevision']({'name':_0xd7bbd4}),_0x22ee1e['isReady']=!0x0,_0x1e527b['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
+ rt();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u];}constructor(_0x4578e8){super(_0x4578e8),this['_revisionViewer']=_0x4578e8['plugins']['get'](u),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x1df89d=this['_revisionsRepository']['_revisions'],_0x3bb65d=this['_createRevisionActions'](),_0x56e1a2=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new ui(this['editor']['locale'],_0x1df89d,_0x3bb65d,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',(_0x37878b,_0x2ab24e)=>{_0x2ab24e['revisionViews']['on']('add',(_0x3cb26e,_0x5416b5)=>{_0x5416b5['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)),_0x56e1a2['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x400beb=this['_revisionsRepository']['getRevision'](0x0);if(_0x400beb){const _0x57deb0=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x400beb['id']);this['_revisionViewer']['compare'](_0x400beb,_0x57deb0);}}['_handleRevisionSelected'](_0x58f7e6,_0x1783aa){const _0x15d384=this['_revisionsRepository']['getRevision'](_0x1783aa['id']),_0x243dbb=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x15d384['id']);this['_revisionViewer']['compare'](_0x15d384,_0x243dbb);}['_handleRevisionSetName'](_0x284cf2,_0x29e6e9){this['_revisionsRepository']['getRevision'](_0x29e6e9['id'])['setName'](_0x29e6e9['name']);}['_handleDiffChange'](_0x4e6c3b,_0xacff4,_0x442141){const _0x15e22a=this['_revisionsRepository']['getRevisionsInDiff'](_0x442141);_0x15e22a['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x15e22a),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x15e22a[0x0]));}['_createRevisionActions'](){const _0x1186f7=this['editor'],_0x28a98e=d['availableRevisionActions'],_0x4c8284=_0x1186f7['config']['get']('revisionHistory.revisionActions')||d['defaultRevisionActions'];if(_0x4c8284['length'])return _0x4c8284['map'](_0x3e2145=>{const _0x20d93d='string'==typeof _0x3e2145?Object['assign']({},_0x28a98e[_0x3e2145]):_0x3e2145;return _0x20d93d['action']=_0x20d93d['action']['bind'](this,_0x1186f7),_0x20d93d['isVisible']&&(_0x20d93d['isVisible']=_0x20d93d['isVisible']['bind'](this,_0x1186f7)),_0x20d93d;});}}function rt(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x43ebf1},_0x20ce61)=>{const _0x5280f8=_0x43ebf1['get'](u),_0x375c25=_0x5280f8['repository'];let _0x4519a2=_0x5280f8['diff']['newRevisionId'],_0x367d0=_0x20ce61['id'];_0x375c25['getIndex'](_0x4519a2)>_0x375c25['getIndex'](_0x367d0)&&([_0x4519a2,_0x367d0]=[_0x367d0,_0x4519a2]),_0x5280f8['compare'](_0x4519a2,_0x367d0);},'isVisible':({plugins:_0xf5b1c},_0x41f930)=>{const _0x1c2e8e=_0xf5b1c['get'](u);return!(_0x1c2e8e['repository']['getRevisionsInDiff'](_0x1c2e8e['diff'])['length']>0x2)&&!_0x41f930['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x4af63a,{id:_0x3b325c})=>{_0x4af63a['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x3b325c);},'isVisible':({plugins:_0x7b8243},_0x41eb06)=>!!_0x7b8243['get'](u)['repository']['getLaterVisibleRevision'](_0x41eb06['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x436387},{id:_0x15f05e,revisionNameView:_0x22b132})=>{const _0x55da65=_0x436387['get'](u),_0x5e0b59=_0x55da65['repository']['getEarlierVisibleRevision'](_0x15f05e);_0x55da65['compare'](_0x15f05e,_0x5e0b59),_0x22b132['focus'](),_0x22b132['fieldView']['select']();}}};}class Z extends tt{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x59b816,_0x50692f){super(_0x59b816),this['_view']=_0x50692f,this['_toolbarConfig']=st(_0x59b816['config']['get']('toolbar')),this['_elementReplacer']=new it();}get['element'](){return this['view']['element'];}['init'](_0x3f83d9){const _0x53b322=this['editor'],_0x4d214e=this['view'],_0x1ade90=_0x53b322['editing']['view'],_0x450ef1=_0x4d214e['editable'],_0x4b93f8=_0x1ade90['document']['getRoot']();_0x450ef1['name']=_0x4b93f8['rootName'],_0x4d214e['render']();const _0xb5421d=_0x450ef1['element'];this['setEditableElement'](_0x450ef1['name'],_0xb5421d),_0x4d214e['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x1ade90['attachDomRoot'](_0xb5421d),this['_elementReplacer']['replace'](_0x3f83d9,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x48d7dd=this['view'],_0x1e584a=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x1e584a['detachDomRoot'](_0x48d7dd['editable']['name']),_0x48d7dd['destroy']();}['_initToolbar'](){const _0x5c21d2=this['view'];_0x5c21d2['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x5c21d2['stickyPanel']['limiterElement']=_0x5c21d2['element'],_0x5c21d2['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x31eea5})=>_0x31eea5),_0x5c21d2['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x5c21d2['toolbar']);}}class ii extends _0x2c763f{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0xe240c9,_0x5d698f,_0x24f901={}){super(_0xe240c9),this['stickyPanel']=new _0x543ebe(_0xe240c9),this['toolbar']=new _0x8f2e9b(_0xe240c9,{'shouldGroupWhenFull':_0x24f901['shouldToolbarGroupWhenFull']}),this['_editable']=new te(_0xe240c9,_0x5d698f);}['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
+ _0x37662a(_0x455307){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x5a2b54,_0x443b2a){super(_0x443b2a),this['sourceElement']=_0x5a2b54,this['model']['document']['createRoot']();const _0x2f8697=new ii(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new Z(this,_0x2f8697);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x1b21a5,_0x2d0200){const _0x21f417=new this(_0x1b21a5,_0x2d0200);return await _0x21f417['initPlugins'](),await _0x21f417['ui']['init'](_0x1b21a5),await _0x21f417['data']['init'](_0x21f417['config']['get']('initialData')||''),_0x21f417['fire']('ready'),_0x21f417;}}const p=['RevisionHistoryUI','RestrictedEditingMode','AIChat','AIReviewMode','AIBalloon','AIQuickActions','AIActions'];class at extends _0x237363{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x1ea3f2){function _0x377dc5(_0x3716c5){return _0x3716c5['map'](_0x153ad8=>String['fromCharCode'](_0x153ad8))['join']('');}super(_0x1ea3f2),this['result']='end',_0x1ea3f2[_0x377dc5([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x377dc5([0x76,0x69,0x65,0x77])][_0x377dc5([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x377dc5([0x61,0x75,0x74,0x6f]),_0x1ea3f2[_0x377dc5([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x377dc5([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x377dc5([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x377dc5([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x377dc5([0x6f,0x6b])});}}class ht extends _0x237363{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[h,l];}constructor(_0x2ab3bc){if(super(_0x2ab3bc),!this['editor']['config']['get']('revisionHistory'))throw new _0x155f4d('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['set']('isRevisionViewerOpen',!0x1),this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x58c3bf=>this['_showRevisionViewer']({..._0x58c3bf,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x2a4a81=>this['_closeRevisionViewer'](_0x2a4a81)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x490487=>this['_restoreRevision'](_0x490487)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x355b1d){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x355b1d;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x57144f){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x57144f);}['getRevision'](_0x1c8b4c){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x1c8b4c);}['getRevisions'](_0x14ce40){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x14ce40||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x4c1191=this['editor'],_0x295e64=_0x2f465f(_0x4c1191,p),_0x38a466=_0x4c1191['plugins']['get']('RevisionTracker'),_0x377169=_0x4c1191['plugins']['get']('Users')['users'];return _0x295e64['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x295e64['lazyRoots'],(_0x295e64['plugins']['push'](at,u,v,class extends _0x237363{static get['requires'](){return[u,'Users'];}['init'](){const _0x33fe30=this['editor']['plugins']['get']('Users');for(const _0x204ac8 of _0x377169)_0x204ac8['isAnonymous']||_0x33fe30['getUser'](_0x204ac8['id'])||_0x33fe30['addUser'](_0x204ac8);const _0x3f2367=_0x38a466['repository']['getRevisions']();let _0x54706f=null;const _0x23b899=this['editor']['plugins']['get']('RevisionViewer');_0x23b899['adapter']=_0x38a466['adapter'],_0x23b899['bind']('isEnabled')['to'](_0x38a466),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x4c1191,'isReadOnly',_0x3df8bb=>!_0x3df8bb);for(const _0x1ffc60 of _0x3f2367){const _0x1896a5=null===_0x1ffc60['creator'];if(_0x1896a5&&_0x1ffc60['toVersion']===_0x1ffc60['fromVersion'])continue;const _0x232eb6=_0x1ffc60['toJSON']();_0x23b899['addRevisionData'](_0x232eb6,(_0x189160,_0x2241ce,_0x18cdc3)=>{if(_0x1896a5){if(_0x54706f)_0x54706f['_update'](_0x189160,_0x2241ce);else{if(!_0x2241ce){const _0x20ed0c=_0x18cdc3['toJSON']();_0x20ed0c['id']=_0x9068c(),_0x38a466['saveRevision'](_0x20ed0c,_0x18cdc3['toVersion'])['then'](_0x56ec25=>{_0x54706f=_0x56ec25;});}}}else _0x1ffc60['_update'](_0x189160,_0x2241ce);});}}},d),_0x295e64);}['_enhanceShowRevisionViewerCallback'](){const _0x338493=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x14936e=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x20d326=this['editor']['plugins']['get']('Autosave');await _0x20d326['save']();}else await _0x14936e['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0xe4cdf5=this['editor']['plugins']['get']('Dialog');_0xe4cdf5['isOpen']&&_0xe4cdf5['hide']();}if(this['editor']['plugins']['has']('AITabs')){const _0x183720=this['editor']['plugins']['get']('AITabs')['view']['panelViews'];for(const _0x163cc8 of _0x183720)_0x163cc8['class']=_0x163cc8['class']?_0x163cc8['class']+'\x20ck-tab-panel_disabled':'ck-tab-panel_disabled';if(this['editor']['plugins']['has']('AIChat')){const _0x162876=document['querySelector']('.ck-ai-chat__prompt-input\x20.ck-textarea');_0x162876&&_0x162876['setAttribute']('tabindex','-1');}if(this['editor']['plugins']['has']('AIChatHistory')){const _0x2edbd2=document['querySelector']('.ck-ai-chat-history\x20.ck-input');_0x2edbd2&&_0x2edbd2['setAttribute']('tabindex','-1');}}const _0x4ec2d0=this['_getRevisionViewerEditorConfig']();return _0x338493(_0x4ec2d0)['then'](_0x1e2ae0=>{return(this['_viewerEditor']=_0x1e2ae0,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'),_0x1e2ae0);})['catch'](_0x14af4f=>(console['error'](_0x14af4f),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x205cc6=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 _0x17d43d=this['editor']['plugins']['get']('AITabs')['view']['panelViews'];for(const _0x4071f8 of _0x17d43d)_0x4071f8['class']='ck-tab-panel_disabled'===_0x4071f8['class']?'':_0x4071f8['class']['replace']('\x20ck-tab-panel_disabled','');if(this['editor']['plugins']['has']('AIChat')){const _0x36fabe=document['querySelector']('.ck-ai-chat__prompt-input\x20.ck-textarea');_0x36fabe&&_0x36fabe['removeAttribute']('tabindex');}if(this['editor']['plugins']['has']('AIChatHistory')){const _0x174189=document['querySelector']('.ck-ai-chat-history\x20.ck-input');_0x174189&&_0x174189['removeAttribute']('tabindex');}}return this['_viewerEditor']['plugins']['get']('RevisionViewer')['_cleanUp'](),_0x205cc6(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x1d67fe=this['editor']['plugins']['get']('Annotations');_0x1d67fe['refreshVisibility'](),_0x1d67fe['refreshPositioning']();}});});}['_showRevisionViewer'](_0x48515f){const _0x1f64dd=this['editor']['config']['get']('revisionHistory.editorContainer'),_0xfbf850=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x34d37c=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return f['create'](_0x34d37c,_0x48515f)['then'](_0x1f77eb=>(_0xfbf850['style']['display']='block',_0x1f64dd['style']['display']='none',this['isRevisionViewerOpen']=!0x0,_0x1f77eb));}['_closeRevisionViewer'](_0x123a3c){const _0x358bc1=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x358bc1['style']['display']='',this['isRevisionViewerOpen']=!0x1,_0x123a3c['destroy']();}async['_restoreRevision'](_0x16b3a4){const _0x552e78=this['editor'],_0x143d14=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x526faa=_0x552e78['plugins']['get']('RevisionTracker'),_0x431efb=_0x552e78['plugins']['get']('RevisionHistoryUtils'),_0x2a9809=_0x143d14['repository']['getRevision'](_0x16b3a4);let _0x8822ab,_0x4e78df,_0x24deb7;try{await _0x431efb['loadRevisionData'](_0x2a9809,this['adapter']),_0x8822ab=_0x431efb['getRevisionDocumentData'](_0x2a9809),_0x4e78df=_0x431efb['getRevisionRootsAttributes'](_0x2a9809);}catch(_0x3c5c4e){return void console['error'](_0x3c5c4e);}_0x552e78['model']['change'](_0x5c2cc6=>{for(const _0x4bc81c of Array['from'](_0x552e78['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x5c2cc6['removeMarker'](_0x4bc81c);}),_0x143d14['isReady']=!0x1,_0x552e78['model']['enqueueChange'](_0x115c4c=>{_0x115c4c['setSelection'](null),_0x115c4c['removeSelectionAttribute'](_0x552e78['model']['document']['selection']['getAttributeKeys']());const _0x50ac5c=Object['keys'](_0x8822ab);for(const _0x5b5fcf of _0x552e78['model']['document']['roots'])'$graveyard'!=_0x5b5fcf['rootName']&&_0x5b5fcf['isAttached']()&&!_0x50ac5c['includes'](_0x5b5fcf['rootName'])&&_0x115c4c['detachRoot'](_0x5b5fcf);for(const _0x582d7f of _0x50ac5c){let _0x4d6e79=_0x552e78['model']['document']['getRoot'](_0x582d7f);_0x4d6e79&&_0x4d6e79['isAttached']()||(_0x4d6e79=_0x115c4c['addRoot'](_0x582d7f));const _0x46ae83=_0x4e78df[_0x582d7f],_0x4cd4ef=Object['keys'](_0x46ae83),_0x33624a=_0x8822ab[_0x582d7f];for(const _0x43766f of _0x4d6e79['getAttributeKeys']())_0x4cd4ef['includes'](_0x43766f)||_0x115c4c['removeAttribute'](_0x43766f,_0x4d6e79);for(const _0x4bf360 of _0x4cd4ef)_0x115c4c['setAttribute'](_0x4bf360,_0x4e78df[_0x582d7f][_0x4bf360],_0x4d6e79);_0x115c4c['remove'](_0x115c4c['createRangeIn'](_0x4d6e79)),_0x115c4c['insert'](_0x552e78['data']['parse'](_0x33624a,_0x4d6e79),_0x4d6e79,0x0);}});const _0xd798b8=m(_0x552e78['locale'],'Restored');if(_0x2a9809['name'])_0x24deb7=-0x1==_0x2a9809['name']['indexOf'](_0xd798b8)?_0xd798b8+':\x20'+_0x2a9809['name']:_0x2a9809['name'];else _0x24deb7=_0xd798b8+':\x20'+(_0x2a9809['createdAt']['toLocaleDateString'](_0x552e78['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x2a9809['createdAt']['toLocaleTimeString'](_0x552e78['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x526faa['saveRevision']({'name':_0x24deb7}),_0x143d14['isReady']=!0x0,_0x552e78['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{nt as RestoreRevisionCommand,I as Revision,ht as RevisionHistory,l as RevisionHistoryUI,$ as RevisionHistoryUtils,h as RevisionTracker,u as RevisionViewer,f as RevisionViewerEditor,at as RevisionViewerIntegration,ji as RevisionViewerLoadingOverlay,v as RevisionViewerUI,S as RevisionsRepository,d as RevisionsSidebar,ot as ShowChangeCommand};