@ckeditor/ckeditor5-revision-history 0.0.0-nightly-20250131.0 → 0.0.0-nightly-20250202.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (177) hide show
  1. package/build/revision-history.js +1 -1
  2. package/dist/index.js +6 -6
  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/bg.js +1 -1
  12. package/dist/translations/bg.umd.js +1 -1
  13. package/dist/translations/bn.js +1 -1
  14. package/dist/translations/bn.umd.js +1 -1
  15. package/dist/translations/bs.js +1 -1
  16. package/dist/translations/bs.umd.js +1 -1
  17. package/dist/translations/ca.js +1 -1
  18. package/dist/translations/ca.umd.js +1 -1
  19. package/dist/translations/cs.js +1 -1
  20. package/dist/translations/cs.umd.js +1 -1
  21. package/dist/translations/da.js +1 -1
  22. package/dist/translations/da.umd.js +1 -1
  23. package/dist/translations/de-ch.js +1 -1
  24. package/dist/translations/de-ch.umd.js +1 -1
  25. package/dist/translations/de.js +1 -1
  26. package/dist/translations/de.umd.js +1 -1
  27. package/dist/translations/el.js +1 -1
  28. package/dist/translations/el.umd.js +1 -1
  29. package/dist/translations/en-au.js +1 -1
  30. package/dist/translations/en-au.umd.js +1 -1
  31. package/dist/translations/en-gb.js +1 -1
  32. package/dist/translations/en-gb.umd.js +1 -1
  33. package/dist/translations/en.js +1 -1
  34. package/dist/translations/en.umd.js +1 -1
  35. package/dist/translations/eo.js +1 -1
  36. package/dist/translations/eo.umd.js +1 -1
  37. package/dist/translations/es-co.js +1 -1
  38. package/dist/translations/es-co.umd.js +1 -1
  39. package/dist/translations/es.js +1 -1
  40. package/dist/translations/es.umd.js +1 -1
  41. package/dist/translations/et.js +1 -1
  42. package/dist/translations/et.umd.js +1 -1
  43. package/dist/translations/eu.js +1 -1
  44. package/dist/translations/eu.umd.js +1 -1
  45. package/dist/translations/fa.js +1 -1
  46. package/dist/translations/fa.umd.js +1 -1
  47. package/dist/translations/fi.js +1 -1
  48. package/dist/translations/fi.umd.js +1 -1
  49. package/dist/translations/fr.js +1 -1
  50. package/dist/translations/fr.umd.js +1 -1
  51. package/dist/translations/gl.js +1 -1
  52. package/dist/translations/gl.umd.js +1 -1
  53. package/dist/translations/gu.js +1 -1
  54. package/dist/translations/gu.umd.js +1 -1
  55. package/dist/translations/he.js +1 -1
  56. package/dist/translations/he.umd.js +1 -1
  57. package/dist/translations/hi.js +1 -1
  58. package/dist/translations/hi.umd.js +1 -1
  59. package/dist/translations/hr.js +1 -1
  60. package/dist/translations/hr.umd.js +1 -1
  61. package/dist/translations/hu.js +1 -1
  62. package/dist/translations/hu.umd.js +1 -1
  63. package/dist/translations/hy.js +1 -1
  64. package/dist/translations/hy.umd.js +1 -1
  65. package/dist/translations/id.js +1 -1
  66. package/dist/translations/id.umd.js +1 -1
  67. package/dist/translations/it.js +1 -1
  68. package/dist/translations/it.umd.js +1 -1
  69. package/dist/translations/ja.js +1 -1
  70. package/dist/translations/ja.umd.js +1 -1
  71. package/dist/translations/jv.js +1 -1
  72. package/dist/translations/jv.umd.js +1 -1
  73. package/dist/translations/kk.js +1 -1
  74. package/dist/translations/kk.umd.js +1 -1
  75. package/dist/translations/km.js +1 -1
  76. package/dist/translations/km.umd.js +1 -1
  77. package/dist/translations/kn.js +1 -1
  78. package/dist/translations/kn.umd.js +1 -1
  79. package/dist/translations/ko.js +1 -1
  80. package/dist/translations/ko.umd.js +1 -1
  81. package/dist/translations/ku.js +1 -1
  82. package/dist/translations/ku.umd.js +1 -1
  83. package/dist/translations/lt.js +1 -1
  84. package/dist/translations/lt.umd.js +1 -1
  85. package/dist/translations/lv.js +1 -1
  86. package/dist/translations/lv.umd.js +1 -1
  87. package/dist/translations/ms.js +1 -1
  88. package/dist/translations/ms.umd.js +1 -1
  89. package/dist/translations/nb.js +1 -1
  90. package/dist/translations/nb.umd.js +1 -1
  91. package/dist/translations/ne.js +1 -1
  92. package/dist/translations/ne.umd.js +1 -1
  93. package/dist/translations/nl.js +1 -1
  94. package/dist/translations/nl.umd.js +1 -1
  95. package/dist/translations/no.js +1 -1
  96. package/dist/translations/no.umd.js +1 -1
  97. package/dist/translations/oc.js +1 -1
  98. package/dist/translations/oc.umd.js +1 -1
  99. package/dist/translations/pl.js +1 -1
  100. package/dist/translations/pl.umd.js +1 -1
  101. package/dist/translations/pt-br.js +1 -1
  102. package/dist/translations/pt-br.umd.js +1 -1
  103. package/dist/translations/pt.js +1 -1
  104. package/dist/translations/pt.umd.js +1 -1
  105. package/dist/translations/ro.js +1 -1
  106. package/dist/translations/ro.umd.js +1 -1
  107. package/dist/translations/ru.js +1 -1
  108. package/dist/translations/ru.umd.js +1 -1
  109. package/dist/translations/si.js +1 -1
  110. package/dist/translations/si.umd.js +1 -1
  111. package/dist/translations/sk.js +1 -1
  112. package/dist/translations/sk.umd.js +1 -1
  113. package/dist/translations/sl.js +1 -1
  114. package/dist/translations/sl.umd.js +1 -1
  115. package/dist/translations/sq.js +1 -1
  116. package/dist/translations/sq.umd.js +1 -1
  117. package/dist/translations/sr-latn.js +1 -1
  118. package/dist/translations/sr-latn.umd.js +1 -1
  119. package/dist/translations/sr.js +1 -1
  120. package/dist/translations/sr.umd.js +1 -1
  121. package/dist/translations/sv.js +1 -1
  122. package/dist/translations/sv.umd.js +1 -1
  123. package/dist/translations/th.js +1 -1
  124. package/dist/translations/th.umd.js +1 -1
  125. package/dist/translations/ti.js +1 -1
  126. package/dist/translations/ti.umd.js +1 -1
  127. package/dist/translations/tk.js +1 -1
  128. package/dist/translations/tk.umd.js +1 -1
  129. package/dist/translations/tr.js +1 -1
  130. package/dist/translations/tr.umd.js +1 -1
  131. package/dist/translations/tt.js +1 -1
  132. package/dist/translations/tt.umd.js +1 -1
  133. package/dist/translations/ug.js +1 -1
  134. package/dist/translations/ug.umd.js +1 -1
  135. package/dist/translations/uk.js +1 -1
  136. package/dist/translations/uk.umd.js +1 -1
  137. package/dist/translations/ur.js +1 -1
  138. package/dist/translations/ur.umd.js +1 -1
  139. package/dist/translations/uz.js +1 -1
  140. package/dist/translations/uz.umd.js +1 -1
  141. package/dist/translations/vi.js +1 -1
  142. package/dist/translations/vi.umd.js +1 -1
  143. package/dist/translations/zh-cn.js +1 -1
  144. package/dist/translations/zh-cn.umd.js +1 -1
  145. package/dist/translations/zh.js +1 -1
  146. package/dist/translations/zh.umd.js +1 -1
  147. package/package.json +10 -10
  148. package/src/changeitem.js +2 -2
  149. package/src/editor/revisionviewereditor.js +2 -2
  150. package/src/editor/revisionviewereditorui.js +1 -1
  151. package/src/editor/revisionviewereditoruiview.js +1 -1
  152. package/src/index.js +1 -1
  153. package/src/revision.js +2 -2
  154. package/src/revisiondiff.js +1 -1
  155. package/src/revisionhistory.js +1 -1
  156. package/src/revisionsrepository.js +1 -1
  157. package/src/revisiontracker.js +1 -1
  158. package/src/revisionviewer.js +1 -1
  159. package/src/ui/revision/createrevisionactionsdropdown.js +1 -1
  160. package/src/ui/revision/revisionauthorview.js +1 -1
  161. package/src/ui/revision/revisionnameview.js +1 -1
  162. package/src/ui/revision/revisionview.js +2 -2
  163. package/src/ui/revision/subrevisioncollapserview.js +1 -1
  164. package/src/ui/revision/subrevisionview.js +1 -1
  165. package/src/ui/revision/utils.js +1 -1
  166. package/src/ui/revisionhistory/revisionhistorysaverevisionformview.js +1 -1
  167. package/src/ui/revisionhistory/revisionhistoryui.js +1 -1
  168. package/src/ui/revisionssidebar/revisionssidebar.js +1 -1
  169. package/src/ui/revisionssidebar/revisionssidebarheaderview.js +1 -1
  170. package/src/ui/revisionssidebar/revisionssidebartimeperiodview.js +1 -1
  171. package/src/ui/revisionssidebar/revisionssidebarview.js +1 -1
  172. package/src/ui/revisionssidebar/utils.js +1 -1
  173. package/src/ui/revisionviewer/changedetailsview.js +1 -1
  174. package/src/ui/revisionviewer/changesnavigationview.js +1 -1
  175. package/src/ui/revisionviewer/revisionviewerloadingoverlay.js +1 -1
  176. package/src/ui/revisionviewer/revisionviewerui.js +1 -1
  177. package/src/utils/common-translations.js +1 -1
package/dist/index.js CHANGED
@@ -20,10 +20,10 @@
20
20
  *
21
21
  *
22
22
  */
23
- import{ObservableMixin as _0x3deca7,uid as _0x346491,Collection as _0x47adf8,logWarning as _0x146469,FocusTracker as _0x941cc7,KeystrokeHandler as _0x284cce,scrollViewportToShowTarget as _0x3f35be,ResizeObserver as at,ElementReplacer as ht,CKEditorError as _0x338b2b}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x5c1065,set as _0x37790d,unset as _0x37f659,isEqual as _0x2814fe}from'lodash-es';import{Plugin as _0x1448f8,PendingActions as _0x1c54bd,icons as _0x2c63e9,Command as _0x3e7e3e,ElementApiMixin as it,Editor as tt}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x3f20df,getMarkerDomElement as _0x1a0754,ConfirmMixin as _0x3f483e,sanitizeEditorConfig as _0x3e8257}from'ckeditor5-collaboration/dist/index.js';import{ViewDocumentFragment as _0x12388,ViewText as _0x5d408e,ViewElement as _0x5e8a92,Element as ft,Range as vt,Position as gt,DocumentFragment as mt,ViewContainerElement as _0x46a47d,ViewAttributeElement as _0x10a2a7,ViewEmptyElement as _0x5c2fc2,ViewRawElement as _0x2fa9bb,ViewUIElement as _0x32b256,Text as wt}from'@ckeditor/ckeditor5-engine/dist/index.js';import{View as _0xc8540d,injectCssTransitionDisabler as ts,submitHandler as _0x21b862,LabeledFieldView as nt,createLabeledInputText as _0xca8177,createDropdown as _0x534184,ListView as te,ListItemView as _0x5c5a58,ButtonView as _0x1a0086,MenuBarMenuView as _0x294fd1,MenuBarMenuListView as _0x54b82c,MenuBarMenuListItemView as _0x45b040,MenuBarMenuListItemButtonView as _0x36bdcc,ContextualBalloon as _0x38f2a5,ToolbarSeparatorView as _0x3a7535,IconView as _0x14e8d9,addListToDropdown as _0x59996c,ViewModel as to,EditorUI as st,normalizeToolbarConfig as ot,BoxedEditorUIView as ct,StickyPanelView as ut,ToolbarView as lt,InlineEditableUIView as dt}from'@ckeditor/ckeditor5-ui/dist/index.js';import{DateTime as _0x3a4a5a}from'luxon';class a extends/* #__PURE__ -- @preserve */
24
- _0x3deca7(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x342f5c){super(),this['id']=_0x342f5c['id']||_0x346491(),this['creator']=_0x342f5c['creator']||null,this['authors']=_0x342f5c['authors']||[],this['diffData']=_0x342f5c['diffData']||null,this['toVersion']=_0x342f5c['toVersion']||0x0,this['fromVersion']=_0x342f5c['fromVersion']||0x0,this['set']('name',_0x342f5c['name']||''),this['set']('createdAt',_0x342f5c['createdAt']||new Date()),this['set']('attributes',_0x342f5c['attributes']||{});}['setName'](_0x279abf){this['_update']({'name':_0x279abf});}['setAttribute'](_0x352310,_0x4118eb){const _0x57f5d7=_0x5c1065(this['attributes']);_0x37790d(_0x57f5d7,_0x352310,_0x4118eb),this['_update']({'attributes':_0x57f5d7});}['removeAttribute'](_0x1a1653){const _0x4ce745=_0x5c1065(this['attributes']);_0x37f659(_0x4ce745,_0x1a1653),this['_update']({'attributes':_0x4ce745});}['_update'](_0x112376,_0x54c81e=!0x1){let _0x50e6e8=!0x1;const _0x2eaeac={'id':this['id']},_0x48ad76=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x53f8f6 of _0x48ad76){const _0xef11a9=_0x112376[_0x53f8f6];void 0x0!==_0xef11a9&&_0xef11a9!==this[_0x53f8f6]&&(this[_0x53f8f6]=_0xef11a9,_0x2eaeac[_0x53f8f6]=_0xef11a9,_0x50e6e8=!0x0);}_0x50e6e8&&(_0x2eaeac['authors']&&(_0x2eaeac['authorsIds']=_0x2eaeac['authors']['map'](_0x17596c=>_0x17596c['id']),delete _0x2eaeac['authors']),this['fire']('_update',_0x2eaeac,_0x54c81e));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x2dc155=>_0x2dc155['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class j extends _0x1448f8{['_revisions'];static get['requires'](){return[_0x3f20df];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x24a27b){super(_0x24a27b),this['_revisions']=new _0x47adf8();}['afterInit'](){!async function(_0x2b8231){const _0x341faa=_0x50e883([0x61,0x57,0x52,0x31,0x37,0x79,0x63,0x36,0x48,0x30,0x4e,0x6a,0x32,0x76,0x6c,0x71,0x34,0x6b,0x77,0x74,0x4d,0x55,0x44,0x65,0x68,0x73,0x41,0x4b,0x54,0x45,0x53,0x64,0x56,0x78,0x38,0x58,0x62,0x50,0x6d,0x51,0x59,0x42,0x49,0x47,0x4f,0x35,0x6f,0x70,0x39,0x46,0x4a,0x43,0x4c,0x33,0x75,0x72,0x66,0x6e,0x5a,0x7a,0x67,0x69]),_0x4ad1b1=0xeb829,_0x1005be=0x2b25f9a3,_0x338fbb=0x2b22a78b^_0x1005be,_0x678d20=window[_0x50e883([0x44,0x61,0x74,0x65])][_0x50e883([0x6e,0x6f,0x77])](),_0x20bb9b=_0x2b8231[_0x50e883([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x48b1db=new window[(_0x50e883([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x319623=>{_0x20bb9b[_0x50e883([0x6f,0x6e,0x63,0x65])](_0x50e883([0x72,0x65,0x61,0x64,0x79]),_0x319623);}),_0x33fc91={[_0x50e883([0x6b,0x74,0x79])]:_0x50e883([0x45,0x43]),[_0x50e883([0x75,0x73,0x65])]:_0x50e883([0x73,0x69,0x67]),[_0x50e883([0x63,0x72,0x76])]:_0x50e883([0x50,0x2d,0x32,0x35,0x36]),[_0x50e883([0x78])]:_0x50e883([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]),[_0x50e883([0x79])]:_0x50e883([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]),[_0x50e883([0x61,0x6c,0x67])]:_0x50e883([0x45,0x53,0x32,0x35,0x36])},_0xdf6a39=_0x20bb9b[_0x50e883([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x50e883([0x67,0x65,0x74])](_0x50e883([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x3a63ee(){let _0x25f865,_0x27c140=null,_0x48a4a0=null;try{if(_0xdf6a39==_0x50e883([0x47,0x50,0x4c]))return _0x50e883([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x25f865=_0x2121d0(),!_0x25f865)return _0x50e883([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x25f865[_0x50e883([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x48a4a0=_0x196d90(_0x25f865[_0x50e883([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x25f865[_0x50e883([0x6a,0x74,0x69])])),await _0x3ad376()?_0xb68a27()?_0x442f82()?_0x50e883([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x494654()?(_0x25f865[_0x50e883([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x50e883([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x27c140=_0x1a3171(_0x50e883([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x25f865[_0x50e883([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x50e883([0x74,0x72,0x69,0x61,0x6c])&&(_0x27c140=_0x1a3171(_0x50e883([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x31f114()):_0x50e883([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x50e883([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x50e883([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch(_0x3452a7){return _0x50e883([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x442f82(){const _0x39860f=[_0x50e883([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x50e883([0x74,0x72,0x69,0x61,0x6c])][_0x50e883([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x25f865[_0x50e883([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x678d20/0x3e8:0xe10*_0x338fbb;return _0x25f865[_0x50e883([0x65,0x78,0x70])]<_0x39860f;}function _0xb68a27(){const _0x36c29b=_0x25f865[_0x50e883([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x36c29b)return!0x1;if(_0x36c29b[_0x50e883([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x50e883([0x2a])))return!0x0;if(_0x36c29b[_0x50e883([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x50e883([0x52,0x48])))return!0x0;if(_0x36c29b[_0x50e883([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x50e883([0x52,0x52,0x48]))){if(_0x1ac4fa())return!0x0;if(_0x43acce()||_0x23698())return!0x0;}return!0x1;}function _0x494654(){const _0x3092b3=_0x25f865[_0x50e883([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x3092b3||0x0==_0x3092b3[_0x50e883([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x3f029d}=new URL(window[_0x50e883([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x3092b3[_0x50e883([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x3f029d))return!0x0;const _0x3fb852=_0x3f029d[_0x50e883([0x73,0x70,0x6c,0x69,0x74])](_0x50e883([0x2e]));return _0x3092b3[_0x50e883([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x529114=>_0x529114[_0x50e883([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x50e883([0x2a])))[_0x50e883([0x6d,0x61,0x70])](_0x5cfec8=>_0x5cfec8[_0x50e883([0x73,0x70,0x6c,0x69,0x74])](_0x50e883([0x2e])))[_0x50e883([0x73,0x6f,0x6d,0x65])](_0x368d6a=>_0x3fb852[_0x50e883([0x65,0x76,0x65,0x72,0x79])]((_0x3efaf1,_0x5eb9ee)=>_0x368d6a[_0x5eb9ee]===_0x3efaf1||_0x368d6a[_0x5eb9ee]===_0x50e883([0x2a])));}function _0x31f114(){return _0x27c140&&_0x48a4a0?new window[(_0x50e883([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x5b764e,_0x27503b)=>{_0x27c140[_0x50e883([0x74,0x68,0x65,0x6e])](_0x5b764e,_0x27503b),_0x48a4a0[_0x50e883([0x74,0x68,0x65,0x6e])](_0x5a44fe=>{_0x5a44fe!=_0x50e883([0x56,0x61,0x6c,0x69,0x64])&&_0x5b764e(_0x5a44fe);},_0x27503b);}):_0x27c140||_0x48a4a0||_0x50e883([0x56,0x61,0x6c,0x69,0x64]);}}function _0x196d90(_0x39ad60,_0x3195ee){return new window[(_0x50e883([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2ad1f1=>{if(_0x22019b())return _0x2ad1f1(_0x50e883([0x56,0x61,0x6c,0x69,0x64]));_0x357dad(),_0x20bb9b[_0x50e883([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x50e883([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x5ecd3e=!0x1;const _0x51cf23=_0x346491();function _0x1afab9(_0x92b3d8){return!!_0x92b3d8&&(typeof _0x92b3d8===_0x50e883([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x92b3d8===_0x50e883([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x92b3d8[_0x50e883([0x74,0x68,0x65,0x6e])]===_0x50e883([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x92b3d8[_0x50e883([0x63,0x61,0x74,0x63,0x68])]===_0x50e883([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x3aa187(_0x3580d0){_0x2be176(_0x3580d0)[_0x50e883([0x74,0x68,0x65,0x6e])](_0x4ab8f2=>{if(!_0x4ab8f2||_0x4ab8f2[_0x50e883([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x50e883([0x6f,0x6b]))return _0x50e883([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x2d02f8(_0x4bb246(_0x51cf23+_0x3195ee))!=_0x4ab8f2[_0x50e883([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x50e883([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x50e883([0x56,0x61,0x6c,0x69,0x64]);})[_0x50e883([0x74,0x68,0x65,0x6e])](_0x90e780=>(_0xf34afa(),_0x90e780),()=>{const _0x2aef7f=_0x1ee345();return null==_0x2aef7f?(_0xf34afa(),_0x50e883([0x56,0x61,0x6c,0x69,0x64])):_0x50e883(_0x678d20-_0x2aef7f>(0xf297da3^_0x1005be)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x50e883([0x74,0x68,0x65,0x6e])](_0x2ad1f1)[_0x50e883([0x63,0x61,0x74,0x63,0x68])](()=>{_0x2ad1f1(_0x50e883([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x99da51=0x2b131723^_0x1005be;function _0xf34afa(){const _0x521b30=_0x50e883([0x6c,0x6c,0x63,0x74,0x2d])+_0x2d02f8(_0x4bb246(_0x39ad60)),_0x26c004=_0x31c9ca(_0x2d02f8(window[_0x50e883([0x4d,0x61,0x74,0x68])][_0x50e883([0x63,0x65,0x69,0x6c])](_0x678d20/_0x99da51)));window[_0x50e883([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x50e883([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x521b30,_0x26c004);}function _0x1ee345(){const _0x69f990=_0x50e883([0x6c,0x6c,0x63,0x74,0x2d])+_0x2d02f8(_0x4bb246(_0x39ad60)),_0x5bbb70=window[_0x50e883([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x50e883([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x69f990);return _0x5bbb70?window[_0x50e883([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x31c9ca(_0x5bbb70),0x10)*_0x99da51:null;}function _0x2be176(_0x3fab93){return new window[(_0x50e883([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x563176,_0x58e34a)=>{_0x3fab93[_0x50e883([0x74,0x68,0x65,0x6e])](_0x563176,_0x58e34a),window[_0x50e883([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x58e34a,0x2b242d63^_0x1005be);});}}_0x20bb9b[_0x50e883([0x6f,0x6e])](_0x50e883([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x108140,_0x50293d)=>{if(_0x50293d[0x0]!=_0x39ad60)return _0x2ad1f1(_0x50e883([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x50293d[0x1]={..._0x50293d[0x1],[_0x50e883([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x51cf23};},{[_0x50e883([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x50e883([0x68,0x69,0x67,0x68])}),_0x20bb9b[_0x50e883([0x6f,0x6e])](_0x50e883([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0xd1c310=>{_0x1afab9(_0xd1c310[_0x50e883([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x5ecd3e=!0x0,_0x3aa187(_0xd1c310[_0x50e883([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x50e883([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x50e883([0x6c,0x6f,0x77])}),_0x48b1db[_0x50e883([0x74,0x68,0x65,0x6e])](()=>{_0x5ecd3e||_0x2ad1f1(_0x50e883([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x22019b(){return _0x20bb9b[_0x50e883([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x50e883([0x76,0x69,0x65,0x77])][_0x50e883([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x50e883([0x61,0x75,0x74,0x6f]);}function _0x357dad(){_0x20bb9b[_0x50e883([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x50e883([0x76,0x69,0x65,0x77])][_0x50e883([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x50e883([0x61,0x75,0x74,0x6f]);}}function _0x1a3171(_0x4771c9){const _0x458e52=[new window[(_0x50e883([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x3668f2=>setTimeout(_0x3668f2,0x2b2cc76f^_0x1005be)),_0x48b1db[_0x50e883([0x74,0x68,0x65,0x6e])](()=>new window[(_0x50e883([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x22d94e=>{const _0x105483=0x2b25f9a4^_0x1005be,_0x597372=_0x2b8231[_0x50e883([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x564343(){_0x597372[_0x50e883([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x105483&&_0x22d94e();}_0x564343(),_0x597372[_0x50e883([0x6f,0x6e])](_0x50e883([0x61,0x64,0x64]),_0x564343);})),new window[(_0x50e883([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x1cc754=>{function _0x197aef(){for(const _0x369a53 in window)if(window[_0x50e883([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x50e883([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x369a53))&&window[_0x369a53]==_0x4ad1b1)return _0x1cc754();_0x20bb9b[_0x50e883([0x73,0x74,0x61,0x74,0x65])]!=_0x50e883([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x50e883([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x197aef,0x2b25ea2b^_0x1005be);}_0x46e44d(_0x50e883([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x197aef();})];return window[_0x50e883([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x50e883([0x72,0x61,0x63,0x65])](_0x458e52)[_0x50e883([0x74,0x68,0x65,0x6e])](()=>_0x4771c9);}async function _0x4961a4(){if(await _0x48b1db,_0x46e44d(_0x50e883([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x35417a=_0x2b8231[_0x50e883([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x4b126a=_0x2b8231[_0x50e883([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])](_0x35417a[_0x50e883([0x69,0x64])]),_0x29fd11=_0x978f01(_0x50e883([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x29fd11[_0x50e883([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x35417a['id'],_0x4b126a?_0x4b126a['id']:null,!0x0),_0x29fd11[_0x50e883([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x50e883([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x29fd11[_0x50e883([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x29fd11[_0x50e883([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x15ab1a,void(_0x29fd11[_0x50e883([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x15ab1a);}if(_0x46e44d(_0x50e883([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x24f4d1=_0x978f01(_0x50e883([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x24f4d1[_0x50e883([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x50e883([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x24f4d1[_0x50e883([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x24f4d1[_0x50e883([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x15ab1a,_0x24f4d1[_0x50e883([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x15ab1a;}_0x20bb9b[_0x50e883([0x6d,0x6f,0x64,0x65,0x6c])][_0x50e883([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x15ab1a,_0x20bb9b[_0x50e883([0x6d,0x6f,0x64,0x65,0x6c])][_0x50e883([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x15ab1a,_0x20bb9b[_0x50e883([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x50e883([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x1ac4fa(){return _0x46e44d(_0x50e883([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x978f01(_0x50e883([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x50e883([0x73,0x74,0x61,0x74,0x65])]==_0x50e883([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x43acce(){return _0x46e44d(_0x50e883([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 _0x23698(){return _0x46e44d(_0x50e883([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x48e880(_0x4d2f2f){const _0x3b8b7d=_0xf53425();_0x20bb9b[_0x3b8b7d]=_0x50e883([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])+_0x4d2f2f,_0x4d2f2f[_0x50e883([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x50e883([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0xf53425()]=_0x4ad1b1),_0x4d2f2f!=_0x50e883([0x56,0x61,0x6c,0x69,0x64])&&_0x4961a4();}function _0xf53425(){const _0x53c798=window[_0x50e883([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x50e883([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x50e883([0x6e,0x6f,0x77])]())[_0x50e883([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x50e883([0x2e]),'');let _0x46d238=_0x50e883([0x61]);for(let _0x4470a7=0x0;_0x4470a7<_0x53c798[_0x50e883([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x4470a7+=0x2){let _0x1952dc=window[_0x50e883([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x53c798[_0x50e883([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x4470a7,_0x4470a7+0x2));_0x1952dc>=_0x341faa[_0x50e883([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x1952dc-=_0x341faa[_0x50e883([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x46d238+=_0x341faa[_0x1952dc];}return _0x46d238;}function _0x2121d0(){const _0x5812da=_0xdf6a39[_0x50e883([0x73,0x70,0x6c,0x69,0x74])](_0x50e883([0x2e]));if(0x3!=_0x5812da[_0x50e883([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x2ac7fa(_0x5812da[0x1]);function _0x2ac7fa(_0x45e59e){const _0x330be1=_0x375032(_0x45e59e);return _0x330be1&&_0x2720d6()?_0x330be1:null;function _0x2720d6(){const _0x394fd2=_0x330be1[_0x50e883([0x6a,0x74,0x69])],_0x44479d=window[_0x50e883([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x394fd2[_0x50e883([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x394fd2[_0x50e883([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x5046c0={..._0x330be1,[_0x50e883([0x6a,0x74,0x69])]:_0x394fd2[_0x50e883([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x394fd2[_0x50e883([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x5046c0[_0x50e883([0x76,0x63])],_0x4bb246(_0x5046c0)==_0x44479d;}}}async function _0x3ad376(){let _0x26f35d=!0x0;try{const _0xec9366=_0xdf6a39[_0x50e883([0x73,0x70,0x6c,0x69,0x74])](_0x50e883([0x2e])),[_0x56662f,_0x4fc125,_0x5343f7]=_0xec9366;return _0x59b87f(_0x56662f),await _0x23c535(_0x56662f,_0x4fc125,_0x5343f7),_0x26f35d;}catch(_0x448a17){return!0x1;}function _0x59b87f(_0x48e7f5){const _0x490211=_0x375032(_0x48e7f5);_0x490211&&_0x490211[_0x50e883([0x61,0x6c,0x67])]==_0x50e883([0x45,0x53,0x32,0x35,0x36])||(_0x26f35d=!0x1);}async function _0x23c535(_0x5ce639,_0x175a1e,_0x4fa66a){const _0x31e484=window[_0x50e883([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x50e883([0x66,0x72,0x6f,0x6d])](_0x13f5b3(_0x4fa66a),_0x38aebf=>_0x38aebf[_0x50e883([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x291879=new window[(_0x50e883([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x50e883([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x5ce639+_0x50e883([0x2e])+_0x175a1e),_0x5ae0d0=window[_0x50e883([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x50e883([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x5ae0d0)return;const _0x5cdf2b=await _0x5ae0d0[_0x50e883([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x50e883([0x6a,0x77,0x6b]),_0x33fc91,{[_0x50e883([0x6e,0x61,0x6d,0x65])]:_0x50e883([0x45,0x43,0x44,0x53,0x41]),[_0x50e883([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x50e883([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x50e883([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x5ae0d0[_0x50e883([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x50e883([0x6e,0x61,0x6d,0x65])]:_0x50e883([0x45,0x43,0x44,0x53,0x41]),[_0x50e883([0x68,0x61,0x73,0x68])]:{[_0x50e883([0x6e,0x61,0x6d,0x65])]:_0x50e883([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x5cdf2b,_0x31e484,_0x291879)||(_0x26f35d=!0x1);}}function _0x375032(_0x44ee4b){return _0x44ee4b[_0x50e883([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x50e883([0x65,0x79]))?JSON[_0x50e883([0x70,0x61,0x72,0x73,0x65])](_0x13f5b3(_0x44ee4b)):null;}function _0x13f5b3(_0xf78be3){return window[_0x50e883([0x61,0x74,0x6f,0x62])](_0xf78be3[_0x50e883([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x50e883([0x2b]))[_0x50e883([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x50e883([0x2f])));}function _0x4bb246(_0x2efd58){let _0x195b8c=0x1505;function _0x255c2b(_0x25bbc5){for(let _0x2f5155=0x0;_0x2f5155<_0x25bbc5[_0x50e883([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x2f5155++){const _0x509f89=_0x25bbc5[_0x50e883([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x2f5155);_0x195b8c=(_0x195b8c<<0x5)+_0x195b8c+_0x509f89,_0x195b8c&=_0x195b8c;}}function _0x55a2a9(_0x481d47){Array[_0x50e883([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x481d47)?_0x481d47[_0x50e883([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x55a2a9):_0x481d47&&typeof _0x481d47==_0x50e883([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x50e883([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x481d47)[_0x50e883([0x73,0x6f,0x72,0x74])]()[_0x50e883([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x39e671,_0x170708])=>{_0x255c2b(_0x39e671),_0x55a2a9(_0x170708);}):_0x255c2b(window[_0x50e883([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x481d47));}return _0x55a2a9(_0x2efd58),_0x195b8c>>>0x0;}function _0x2d02f8(_0xf75aa3){return _0xf75aa3[_0x50e883([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x50e883([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x50e883([0x30]));}function _0x31c9ca(_0x3ced3e){return _0x3ced3e[_0x50e883([0x73,0x70,0x6c,0x69,0x74])]('')[_0x50e883([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x50e883([0x6a,0x6f,0x69,0x6e])]('');}function _0x46e44d(_0x470f71){return _0x20bb9b[_0x50e883([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x50e883([0x68,0x61,0x73])](_0x470f71);}function _0x978f01(_0x3cc260){return _0x20bb9b[_0x50e883([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x50e883([0x67,0x65,0x74])](_0x3cc260);}function _0x15ab1a(){}function _0x50e883(_0x220795){return _0x220795['map'](_0x49a093=>String['fromCharCode'](_0x49a093))['join']('');}_0x48e880(await _0x3a63ee());}(this);}['createRevision'](_0x25e6ce){const _0xff1045=this['editor']['plugins']['get']('Users');return new a({'id':_0x25e6ce['id'],'name':_0x25e6ce['name'],'creator':_0x25e6ce['creatorId']?_0xff1045['getUser'](_0x25e6ce['creatorId']):null,'diffData':_0x25e6ce['diffData']||_0x25e6ce['data'],'authors':_0x25e6ce['authorsIds']['map'](_0x12d5b4=>_0xff1045['getUser'](_0x12d5b4)),'createdAt':new Date(_0x25e6ce['createdAt']),'attributes':_0x25e6ce['attributes'],'fromVersion':_0x25e6ce['fromVersion'],'toVersion':_0x25e6ce['toVersion']});}['addRevision'](_0x22c7a5,_0x1d7da5=0x0){this['_revisions']['add'](_0x22c7a5,_0x1d7da5);}['getRevision'](_0x4bd7ea){return this['_revisions']['get'](_0x4bd7ea);}['getRevisions'](_0x2975af={'toJSON':!0x1}){const _0x3613fe=Array['from'](this['_revisions']);return _0x3613fe['reverse'](),_0x2975af['toJSON']?_0x3613fe['map'](_0x214a05=>_0x214a05['toJSON']()):_0x3613fe;}['getIndex'](_0x3e20b8){return this['_revisions']['getIndex'](_0x3e20b8);}['getEarlierVisibleRevision'](_0x6b11ac){const [,_0x2b78d2]=this['getRevisionsIterator'](_0x6b11ac,{'direction':'earlier'});return _0x2b78d2;}['getLaterVisibleRevision'](_0x310fa2){const [,_0xe3dca4]=this['getRevisionsIterator'](_0x310fa2,{'direction':'later'});return _0xe3dca4;}['getRevisionsInDiff'](_0x10eb67){const _0x37df29=[];for(const _0x1e468b of this['getRevisionsIterator'](_0x10eb67['newRevisionId']))if(_0x37df29['push'](_0x1e468b),_0x1e468b['id']===_0x10eb67['oldRevisionId'])break;return _0x37df29;}*['getRevisionsIterator'](_0x5e71ca,{direction:_0x37ce6c='earlier',filter:_0x11d716=()=>!0x0}={}){const _0xf6b3fa='earlier'===_0x37ce6c?0x1:-0x1;let _0x58670e=this['_revisions']['get'](_0x5e71ca),_0x1c5b2c=this['getIndex'](_0x58670e);for(yield _0x58670e;_0x58670e;){if(_0x1c5b2c+=_0xf6b3fa,_0x58670e=this['getRevision'](_0x1c5b2c),!_0x58670e)return;_0x11d716(_0x58670e)&&(yield _0x58670e);}}}function m(_0x5c21e1,_0x5dfef7,_0x2b760d){const t=_0x5c21e1['t'];switch(_0x5dfef7){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'},_0x2b760d);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x2b760d);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'';}}const P={'c':_0x46a47d,'a':_0x10a2a7,'e':_0x5c2fc2,'r':_0x2fa9bb,'u':_0x32b256};class l extends _0x1448f8{['licenseKey'];['_licenseKeyCheckInterval'];['adapter'];['currentRevision'];['repository'];['_revisionDataBuilder'];['_source'];['_initialRevisionId'];['_bufferedUpdates'];['_pendingAction'];['_continueCurrentRevision'];['_startingVersion'];['_loadedStateData'];static get['pluginName'](){return'RevisionTracker';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[_0x3f20df,j,_0x1c54bd];}constructor(_0x79a64d){super(_0x79a64d),this['adapter']=null,this['currentRevision']=null,this['_revisionDataBuilder']=new V(this['editor']),this['_initialRevisionId']=this['editor']['config']['get']('collaboration.channelId')||'initial',this['_bufferedUpdates']=new Map(),this['_loadedStateData']=null;const _0x7a56ee=_0x346491();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x7a56ee},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['repository']=this['editor']['plugins']['get']('RevisionsRepository'),this['_setConversion'](),this['editor']['data']['on']('ready',()=>{const _0x5a14b6=this['repository']['getRevision'](0x0),_0x1bbe19=_0x5a14b6&&null===_0x5a14b6['creator']?_0x5a14b6:null;if(this['_continueCurrentRevision']=!!_0x1bbe19&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x8075dc=this['_source']['getCurrentRevisionId'](),_0xd8d95b=this['repository']['getRevision'](_0x8075dc);if(_0xd8d95b)this['_startingVersion']=_0xd8d95b['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x1419b6=this['_source']['history']['_operations']['find'](_0x35fbe2=>!_0x35fbe2['_isInit']),_0x31fb7b=_0x1419b6?_0x1419b6['baseVersion']:this['_source']['history']['version'];_0x5a14b6?(_0x5a14b6['toVersion']<_0x31fb7b&&_0x5a14b6['_update']({'toVersion':_0x31fb7b}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x1bbe19['id'],this['_startingVersion']=_0x1bbe19['fromVersion']):(this['_startingVersion']=_0x5a14b6['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x31fb7b,this['_continueCurrentRevision']=!0x1);}}else _0x1bbe19&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x1bbe19['toVersion'],this['editor']['model']['document']['history']['version']),_0x1bbe19['fromVersion']===_0x1bbe19['toVersion']?(0x0!==_0x1bbe19['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x1bbe19['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x1bbe19['id'],this['_startingVersion']=_0x1bbe19['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',_0x398d8a=>!_0x398d8a),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x3be23c=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x1b1a3f;for(const _0x594fbf in _0x3be23c){const _0x47e7db=_0x594fbf,_0xea9f14=_0x3be23c[_0x47e7db];if('revisionHistoryLicenseKeyValid'==_0xea9f14||'revisionHistoryLicenseKeyInvalid'==_0xea9f14||'revisionHistoryLicenseKeyExpired'==_0xea9f14||'revisionHistoryLicenseKeyDomainLimit'==_0xea9f14||'revisionHistoryLicenseKeyNotAllowed'==_0xea9f14||'revisionHistoryLicenseKeyEvaluationLimit'==_0xea9f14||'revisionHistoryLicenseKeyTrialLimit'==_0xea9f14||'revisionHistoryLicenseKeyUsageLimit'==_0xea9f14){delete _0x3be23c[_0x47e7db],_0x1b1a3f=_0xea9f14,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x1b1a3f&&_0x3be23c['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x1b1a3f&&_0x3be23c['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x1b1a3f&&_0x3be23c['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x1b1a3f&&_0x3be23c['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x1b1a3f&&_0x3be23c['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x1b1a3f&&_0x3be23c['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x1b1a3f&&_0x3be23c['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x1cff5a=this['repository']['getRevision'](0x0),_0x16445d=await this['getRevisionDocumentData'](_0x1cff5a),_0x53b114=await this['getRevisionRootsAttributes'](_0x1cff5a);this['_replaceEditorDataWithRevisionData'](_0x16445d,_0x53b114);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x4fa109){this['_source']=_0x4fa109;}async['update'](){const _0x291d08=await this['_source']['getLatestVersion']();if(_0x291d08>this['currentRevision']['toVersion']){await this['_loadState']();const _0xedbc9f=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x291d08});_0xedbc9f['authors']=_0xedbc9f['authorsIds']['map'](_0x1271ed=>this['editor']['plugins']['get']('Users')['getUser'](_0x1271ed)),this['currentRevision']['_update'](_0xedbc9f);}}async['_loadState'](){this['_continueCurrentRevision']&&!this['_loadedStateData']&&(await this['_loadRevisionData'](this['currentRevision']),this['_revisionDataBuilder']['loadState'](this['currentRevision']),this['_loadedStateData']={'fromVersion':this['currentRevision']['fromVersion'],'authors':this['currentRevision']['authors']['slice']()});}async['saveRevision'](_0x4b31ba={},_0x55f6d4=null){const _0x4b3e21=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x55f6d4>this['currentRevision']['toVersion']&&(_0x55f6d4=null),null===_0x55f6d4&&(_0x55f6d4=await this['_source']['getLatestVersion']());const _0x4f122d=this['_getFromVersion'](_0x55f6d4),_0x3df964=this['buildRevisionData']({'from':_0x4f122d,'to':_0x55f6d4});if(this['currentRevision']['toVersion']<_0x55f6d4){const _0x281222=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x55f6d4,'to':_0x55f6d4});_0x281222['authors']=[],_0x281222['authorsIds']=[],_0x281222['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x281222,!0x0),delete _0x281222['authors'],_0x4b3e21['push'](_0x281222);}_0x4b31ba['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x4b31ba['name']=_0x4b31ba['name']||null,_0x4b31ba['id']=_0x4b31ba['id']||_0x346491(),_0x4b31ba={..._0x4b31ba,..._0x3df964};const _0x104dc7=this['addRevisionData'](_0x4b31ba);_0x4b3e21['push'](_0x4b31ba);const _0x19a12=this['repository']['getIndex'](_0x104dc7);if(0x0!==_0x19a12){const _0x1104eb=this['repository']['getRevision'](_0x19a12-0x1);if(_0x1104eb['fromVersion']!==_0x55f6d4){const _0xcd9fdf=this['_revisionDataBuilder']['getData'](_0x55f6d4,_0x1104eb['toVersion']),_0x6d033f={'id':_0x1104eb['id'],'diffData':_0xcd9fdf['diffData'],'authorsIds':_0xcd9fdf['authorsIds'],'authors':_0xcd9fdf['authorsIds']['map'](_0x3e616f=>this['editor']['plugins']['get']('Users')['getUser'](_0x3e616f)),'fromVersion':_0x55f6d4};_0x1104eb===this['currentRevision']&&(_0x6d033f['createdAt']=new Date(_0x4b31ba['createdAt']['getTime']()+0xa)),_0x1104eb['_update'](_0x6d033f,!0x0),delete _0x6d033f['authors'],_0x4b3e21['push'](_0x6d033f);}}if(this['adapter']){for(const _0x7958ba of _0x4b3e21)this['_bufferUpdate'](_0x7958ba['id'],_0x7958ba,!0x0);this['sendBufferedUpdates']();}return _0x104dc7;}['addRevisionData'](_0x3fb92a){const _0x12a811=this['repository']['createRevision'](_0x3fb92a);return this['adapter']&&_0x12a811['on']('_update',(_0x44c85d,_0x47dac5,_0x44cc5a)=>{_0x44cc5a||(this['_bufferUpdate'](_0x47dac5['id'],_0x47dac5,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x12a811,this['_findInsertionIndex'](_0x12a811)),_0x12a811;}async['getRevisionDocumentData'](_0x24c2e7){await this['_loadRevisionData'](_0x24c2e7);const _0x3b7443={};for(const _0x4e8525 in _0x24c2e7['diffData']){if(_0x24c2e7['diffData'][_0x4e8525]['attachChange']&&!_0x24c2e7['diffData'][_0x4e8525]['attachChange']['isAttached'])continue;const _0x3de870=this['_removeRevisionMarkers'](JSON['parse'](_0x24c2e7['diffData'][_0x4e8525]['insertions'])),_0x32a9d2=this['editor']['editing']['view']['document'],_0x4f64c2=new _0x12388(_0x32a9d2,_0x3de870['map'](_0x5d2e85=>C(_0x5d2e85,this['editor'])));this['editor']['data']['processor']['useFillerType']('marked'),_0x3b7443[_0x4e8525]=this['editor']['data']['processor']['toData'](_0x4f64c2),this['editor']['data']['processor']['useFillerType']('default');}return _0x3b7443;}async['getRevisionRootsAttributes'](_0x810164){await this['_loadRevisionData'](_0x810164);const _0x513977={};for(const _0x463bf2 in _0x810164['diffData'])_0x810164['diffData'][_0x463bf2]['attachChange']&&!_0x810164['diffData'][_0x463bf2]['attachChange']['isAttached']||(_0x513977[_0x463bf2]=_0x810164['diffData'][_0x463bf2]['attributesAfter']||{});return _0x513977;}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x4722f2=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x5971d8=0x0;_0x5971d8<_0x4722f2['length'];_0x5971d8++){const _0x93f878=_0x4722f2[_0x5971d8];let _0x4580df=!0x1;for(const _0x348701 of Object['keys'](_0x93f878))void 0x0===_0x93f878[_0x348701]?delete _0x93f878[_0x348701]:'id'!==_0x348701&&(_0x4580df=!0x0);_0x4580df||(_0x4722f2[_0x5971d8]=null);}if(_0x4722f2=_0x4722f2['filter'](_0x12a9e5=>null!==_0x12a9e5),!_0x4722f2['length'])return;for(let _0xa7c8aa=0x0;_0xa7c8aa<_0x4722f2['length'];_0xa7c8aa++){const _0x54bc32=_0x4722f2[_0xa7c8aa];void 0x0!==_0x54bc32['fromVersion']&&void 0x0===_0x54bc32['toVersion']&&(_0x54bc32['toVersion']=this['repository']['getRevision'](_0x54bc32['id'])['toVersion']),void 0x0!==_0x54bc32['toVersion']&&void 0x0===_0x54bc32['fromVersion']&&(_0x54bc32['fromVersion']=this['repository']['getRevision'](_0x54bc32['id'])['fromVersion']);}const _0xe1b005=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x4722f2,_0xe1b005)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x3b6ad3=>{if(_0x3b6ad3){for(const _0x560609 of _0x3b6ad3)this['setRevisionData']({'id':_0x560609['id'],'createdAt':_0x560609['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['_replaceEditorDataWithRevisionData'](_0x390f36,_0x514b82){let _0x3b0ee5=this['editor']['config']['get']('initialData'),_0x2ff1c3=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x3b0ee5){_0x3b0ee5={};for(const _0x2b1aaf of this['editor']['model']['document']['getRootNames']())_0x3b0ee5[_0x2b1aaf]='';}if('string'==typeof _0x3b0ee5&&(_0x3b0ee5={'main':_0x3b0ee5}),void 0x0===_0x2ff1c3){_0x2ff1c3={};for(const _0x415ac2 of this['editor']['model']['document']['getRootNames']())_0x2ff1c3[_0x415ac2]={};}let _0x5e9666=!0x1;const _0x484460=Object['keys'](_0x3b0ee5),_0x211431=Object['keys'](_0x390f36);for(const _0x45772f of _0x484460){if(_0x3b0ee5[_0x45772f]!==_0x390f36[_0x45772f]&&''!==_0x3b0ee5[_0x45772f]['trim']()){_0x5e9666=!0x0;break;}if(!_0x2814fe(_0x2ff1c3[_0x45772f],_0x514b82[_0x45772f])&&Object['keys'](_0x2ff1c3[_0x45772f])['length']>0x0){_0x5e9666=!0x0;break;}}_0x5e9666||(_0x5e9666=_0x211431['some'](_0x1d71ef=>!this['editor']['model']['document']['getRoot'](_0x1d71ef))),_0x5e9666&&_0x146469('editor-initial-data-replaced-with-revision-data',{'editorData':_0x3b0ee5,'editorRootsAttributes':_0x2ff1c3,'revisionData':_0x390f36,'revisionRootsAttributes':_0x514b82}),this['editor']['config']['set']('initialData',_0x390f36),this['editor']['config']['set']('rootsAttributes',_0x514b82);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x17c08d=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x17c08d['add'](m(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x115ab4){const _0x17f928=this['repository']['getRevisions']();_0x17f928['reverse']();let _0x2b9151=0x0;for(;_0x2b9151<_0x17f928['length'];){const _0x41183e=_0x17f928[_0x2b9151];if(_0x41183e===this['currentRevision']){_0x2b9151++;continue;}if(_0x41183e['id']===this['_initialRevisionId'])break;const _0x57ad18=_0x115ab4['toVersion']-_0x41183e['toVersion']||_0x115ab4['fromVersion']-_0x41183e['fromVersion'];if(_0x57ad18>0x0)break;if(_0x57ad18<0x0)_0x2b9151++;else{if(!_0x115ab4['creator']&&_0x41183e['creator'])break;if(_0x41183e['creator']||!_0x115ab4['creator']){if(_0x115ab4['createdAt']>_0x41183e['createdAt'])break;_0x2b9151++;}else _0x2b9151++;}}return _0x2b9151;}['setRevisionData'](_0xc80874){const _0x5777b3=this['repository']['getRevision'](_0xc80874['id']);if(_0xc80874['createdAt']&&(_0xc80874['createdAt']=new Date(_0xc80874['createdAt'])),_0xc80874['authorsIds']){const _0xcdd067=this['editor']['plugins']['get']('Users');_0xc80874['authors']=_0xc80874['authorsIds']['map'](_0x3372cf=>_0xcdd067['getUser'](_0x3372cf));}_0x5777b3['_update'](_0xc80874,!0x0);}['buildRevisionData']({revision:_0x50730e=null,from:_0x313db7=null,to:_0x550a5e=null}){_0x313db7=null!==_0x313db7?_0x313db7:_0x50730e['fromVersion'],_0x550a5e=null!==_0x550a5e?_0x550a5e:_0x50730e['toVersion'];const _0x170cd0=this['_revisionDataBuilder']['getData'](_0x313db7,_0x550a5e),_0x327e8d={'diffData':_0x170cd0['diffData'],'authorsIds':_0x170cd0['authorsIds'],'fromVersion':_0x313db7,'toVersion':_0x550a5e};if(!_0x50730e||_0x550a5e!==_0x50730e['toVersion']){const _0x1d44de=_0x550a5e-0x1,_0x59fb26=this['_source']['history']['getOperation'](_0x1d44de);_0x327e8d['createdAt']=_0x59fb26&&_0x59fb26['createdAt']||new Date();}if(this['_loadedStateData']&&_0x313db7===this['_loadedStateData']['fromVersion']){for(const _0x30f4bf of this['_loadedStateData']['authors'])_0x327e8d['authorsIds']['includes'](_0x30f4bf['id'])||_0x327e8d['authorsIds']['push'](_0x30f4bf['id']);}return _0x327e8d;}['_loadRevisionData'](_0x58426c){if(!_0x58426c||_0x58426c['diffData'])return Promise['resolve']();{const _0x34df28=this['editor']['config']['get']('collaboration.channelId');return this['adapter']['getRevision']({'channelId':_0x34df28,'revisionId':_0x58426c['id']})['then'](_0x3f22e1=>{_0x58426c['diffData']=_0x3f22e1['diffData'];});}}['_bufferUpdate'](_0x1a0ddf,_0x1fc429,_0x3c7c09){if(this['_bufferedUpdates']['has'](_0x1a0ddf)){const _0x265127=this['_bufferedUpdates']['get'](_0x1a0ddf);_0x1fc429=_0x3c7c09?{..._0x265127,..._0x1fc429}:{..._0x1fc429,..._0x265127};}this['_bufferedUpdates']['set'](_0x1a0ddf,_0x1fc429);}['_getFromVersion'](_0x4b7bb0){const _0x4984ab=this['repository']['getRevisions']();_0x4984ab['reverse'](),_0x4984ab['shift']();const _0x16296a=_0x4984ab['find'](_0x10c2c1=>_0x10c2c1['toVersion']<=_0x4b7bb0)['toVersion'];return _0x16296a<this['_startingVersion']?this['_startingVersion']:_0x16296a;}['_createInitialRevision'](_0x212f6d){const _0x4824f3=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x4824f3)this['_initialRevisionId']=_0x4824f3['id'];else{const _0x5f3f0e=!this['editor']['model']['document']['roots']['find'](_0x1ed442=>this['editor']['model']['hasContent'](_0x1ed442)),_0x63e035=this['editor']['plugins']['get']('Users')['me']['id'],_0x5c08a4=m(this['editor']['locale'],_0x5f3f0e?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x212f6d,'to':_0x212f6d,'id':this['_initialRevisionId'],'name':_0x5c08a4,'creatorId':_0x63e035});}}['_createCurrentRevision'](_0x4e57b6){const _0xdb0d8f=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0xdb0d8f),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x4e57b6,'to':_0x4e57b6,'id':_0xdb0d8f,'name':'','creatorId':null}));}['_makeRevision']({name:_0x231b2e,from:_0x489f02,to:_0x4acc08,creatorId:_0x4408ef,id:_0x1bea48}){const _0x1732fa=this['buildRevisionData']({'from':_0x489f02,'to':_0x4acc08});_0x1732fa['name']=_0x231b2e,_0x1732fa['creatorId']=_0x4408ef,_0x1732fa['id']=_0x1bea48;const _0x34dbb2=this['addRevisionData'](_0x1732fa);return this['adapter']&&this['_bufferUpdate'](_0x1732fa['id'],_0x1732fa,!0x0),_0x34dbb2;}['_setConversion'](){this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'});}['_removeRevisionMarkers'](_0x27c646){return(_0x27c646=_0x27c646['filter'](_0x301714=>!_0x301714['name']||'revision-start'!==_0x301714['name']&&'revision-end'!==_0x301714['name']))['forEach'](_0xdd39d7=>{'string'!=typeof _0xdd39d7&&(_0xdd39d7['children']=this['_removeRevisionMarkers'](_0xdd39d7['children']),_0xdd39d7['attributes']=_0xdd39d7['attributes']['filter'](_0x37be65=>!_0x37be65[0x0]['startsWith']('data-revision-')));}),_0x27c646;}}function C(_0x43e038,_0x51a6fb){const _0x375e02=_0x51a6fb['editing']['view']['document'];if('string'==typeof _0x43e038)return new _0x5d408e(_0x375e02,_0x43e038);{const _0x1525f2=_0x43e038['children']['map'](_0xa071d9=>C(_0xa071d9,_0x51a6fb));return new(P[_0x43e038['type']]||_0x5e8a92)(_0x375e02,_0x43e038['name'],_0x43e038['attributes'],_0x1525f2);}}class V{['editor'];['source'];['_savedMetaData'];['_lastFrom'];['_lastTo'];['_markers'];['_diffRoots'];['_diffRootsAttributes'];['_baseRoots'];['_baseRootsAttributes'];['_idsRoots'];['_baseIdsRoots'];['_touched'];['_touchedMarkers'];['_touchedRoots'];['_revisionId'];['_startingRevisionId'];constructor(_0x2849a8){this['editor']=_0x2849a8,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'](_0x479b6d){this['source']=_0x479b6d;const _0x48ca6a=new Map(),_0x103846=new Map(),_0x454bfb=this['editor']['model']['document']['roots']['map'](_0x3a73eb=>_0x3a73eb['rootName']);for(const _0x2cf1a5 of _0x454bfb){const _0x30d404=this['editor']['model']['document']['getRoot'](_0x2cf1a5),_0x2d5ac2=T(_0x30d404);_0x48ca6a['set'](_0x2cf1a5,_0x2d5ac2),_0x103846['set'](_0x2cf1a5,Object['fromEntries'](_0x30d404['getAttributes']()));}const _0x59e0d3=Array['from'](this['editor']['model']['markers'])['map'](_0x2e6a0c=>[_0x2e6a0c['name'],_0x2e6a0c['getRange']()]),_0xe47146=this['source']['version'];this['_saveMetaData'](_0xe47146,_0x48ca6a,_0x59e0d3,_0x103846),this['_startingRevisionId']=this['_revisionId'];const _0x303e39=new Map(),_0x450f1c=new Map();for(const _0x409e9a of _0x454bfb){const _0x273dad=F(_0x409e9a);_0x303e39['set'](_0x409e9a,_0x273dad),_0x450f1c['set'](_0x409e9a,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x303e39,[],_0x450f1c);}['getData'](_0x548a37,_0x236864){if(this['_lastFrom']===_0x548a37&&this['_lastTo']<=_0x236864)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x236864,!0x0);else{if(!this['_savedMetaData']['has'](_0x548a37)){const _0x387998=this['_getPreviousFrom'](_0x548a37);this['_calculateMetaData'](_0x387998,_0x548a37,!0x1);}this['_calculateMetaData'](_0x548a37,_0x236864,!0x0);}return this['_lastFrom']=_0x548a37,this['_lastTo']=_0x236864,this['_getState']();}['loadState'](_0x16b86e){this['_reset'](),this['_lastFrom']=_0x16b86e['fromVersion'],this['_lastTo']=_0x16b86e['toVersion'];for(const _0x2de55d in _0x16b86e['diffData']){const _0x2390e1=_0x16b86e['diffData'][_0x2de55d]['attachChange'],_0x18e35a=_0x5c1065(_0x16b86e['diffData'][_0x2de55d]['attributesBefore'])||{},_0x39c4b5=this['_makeModelFromViewString'](_0x16b86e['diffData'][_0x2de55d]['deletions']);_0x39c4b5['rootName']=_0x2de55d,_0x39c4b5['_isAttached']=!_0x2390e1||!_0x2390e1['isAttached'],_0x39c4b5['isAttached']=()=>_0x39c4b5['_isAttached'],this['_baseRoots']['set'](_0x2de55d,_0x39c4b5),this['_baseRootsAttributes']['set'](_0x2de55d,_0x18e35a),_0x2390e1&&this['_touchedRoots']['set'](_0x2de55d,_0x2390e1);const _0x3a6700=this['_makeIdsRoot'](_0x39c4b5);this['_baseIdsRoots']['set'](_0x2de55d,_0x3a6700);for(const [_0x1cdf6c,_0x24b100]of _0x39c4b5['markers']){if(!_0x1cdf6c['startsWith']('revision:'))continue;const _0x2f5497=_0x1cdf6c['split'](':')[0x2];for(const _0x2e87f0 of _0x24b100['getWalker']({'singleCharacters':!0x0})){const _0x7930ce=this['_getVidAttributeName'](_0x2e87f0),_0xe63c1f='elementEnd'==_0x2e87f0['type']?_0x2e87f0['previousPosition']['path']['slice'](0x0,-0x1):_0x2e87f0['previousPosition']['path'],_0x40e055=_0x3a6700['getNodeByPath'](_0xe63c1f)['getAttribute'](_0x7930ce);this['_touched']['set'](_0x40e055,{'userId':_0x2f5497});}}}this['_startingRevisionId']=this['_revisionId'];const _0x2d3c83=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x10924f=>!this['_touched']['has'](_0x10924f));let _0x58f4d6=0x0;const _0x12538b=new Map();for(const _0x588595 in _0x16b86e['diffData']){const _0x5983cf=_0x16b86e['diffData'][_0x588595]['attachChange'],_0x17578f=_0x5c1065(_0x16b86e['diffData'][_0x588595]['attributesAfter'])||{},_0x5dd18a=this['_makeModelFromViewString'](_0x16b86e['diffData'][_0x588595]['insertions']);_0x5dd18a['rootName']=_0x588595,_0x5dd18a['_isAttached']=!_0x5983cf||_0x5983cf['isAttached'],_0x5dd18a['isAttached']=()=>_0x5dd18a['_isAttached'],this['_diffRoots']['set'](_0x588595,_0x5dd18a),this['_diffRootsAttributes']['set'](_0x588595,_0x17578f);const _0x510542=this['_makeIdsRoot'](_0x5dd18a,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x588595,_0x510542),_0x12538b['set'](_0x588595,_0x5dd18a['isAttached']()?_0x17578f:{});for(const [_0x508fe5,_0x1e2a72]of _0x5dd18a['markers']){if(!_0x508fe5['startsWith']('revision:'))continue;const _0x4b70b1=_0x508fe5['split'](':')[0x2];for(const _0x3a142e of _0x1e2a72['getWalker']({'singleCharacters':!0x0})){const _0x362216=this['_getVidAttributeName'](_0x3a142e),_0x52b6b6=this['_revisionId']++,_0x170cb5='elementEnd'==_0x3a142e['type']?_0x3a142e['previousPosition']['path']['slice'](0x0,-0x1):_0x3a142e['previousPosition']['path'];_0x510542['getNodeByPath'](_0x170cb5)['_setAttribute'](_0x362216,_0x52b6b6),this['_touched']['set'](_0x52b6b6,{'userId':_0x4b70b1});}}for(const _0x497ff5 of this['editor']['model']['createRangeIn'](_0x5dd18a)['getWalker']({'singleCharacters':!0x0})){const _0xafb1bc=this['_getVidAttributeName'](_0x497ff5),_0x1f6c88='elementEnd'==_0x497ff5['type']?_0x497ff5['previousPosition']['path']['slice'](0x0,-0x1):_0x497ff5['previousPosition']['path'],_0x4b24c7=_0x510542['getNodeByPath'](_0x1f6c88);_0x4b24c7['getAttribute'](_0xafb1bc)>0x0||_0x4b24c7['_setAttribute'](_0xafb1bc,_0x2d3c83[_0x58f4d6++]);}for(const [_0x555e58,_0x2099a1]of _0x5dd18a['markers'])_0x555e58['startsWith']('revision:')||this['_markers']['set'](_0x555e58,_0x2099a1);}const _0x16122b=F('$graveyard');this['_baseRoots']['set']('$graveyard',_0x16122b),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x16122b,0x1));const _0x2afd58=F('$graveyard');this['_diffRoots']['set']('$graveyard',_0x2afd58),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x2afd58,0x1));const _0x1d4f1e=Array['from'](this['_diffRoots'])['map'](([_0x133dbd,_0x1490a9])=>[_0x133dbd,T(_0x1490a9)]);this['_saveMetaData'](this['_lastTo'],_0x1d4f1e,this['_markers'],_0x12538b);}['_makeModelFromViewString'](_0x896de2){const _0x5d5682=JSON['parse'](_0x896de2),_0x34e8e3=this['editor']['editing']['view']['document'],_0x2cd6b4=new _0x12388(_0x34e8e3,_0x5d5682['map'](_0x4e7822=>C(_0x4e7822,this['editor'])));return this['editor']['data']['toModel'](_0x2cd6b4);}['_saveMetaData'](_0x56279c,_0x368073,_0x968419,_0x175235){const _0x4f3749=new Map(_0x368073),_0x4d7db9=new Map(_0x5c1065(_0x175235)),_0x527204=new Map();for(const [_0x3b4a14,_0x1110e3]of _0x968419)_0x527204['set'](_0x3b4a14,{'start':_0x1110e3['start']['clone'](),'end':_0x1110e3['end']['clone'](),'rootName':_0x1110e3['root']['rootName']});this['_savedMetaData']['set'](_0x56279c,{'roots':_0x4f3749,'markers':_0x527204,'rootsAttributes':_0x4d7db9});}['_removeMetaData'](_0x168d8a){this['_savedMetaData']['delete'](_0x168d8a);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_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'](_0x4d2689,_0x17d4be=null){let _0x4fa094=null;_0x4d2689['is']('documentFragment')||(_0x4fa094=new ft(_0x4d2689['name'],{'vid_start':null===_0x17d4be?this['_revisionId']++:_0x17d4be++}));const _0x15a01d=[];for(const _0x1a0935 of _0x4d2689['getChildren']())if(_0x1a0935['is']('element')){_0x15a01d['push'](this['_makeIdsRoot'](_0x1a0935,_0x17d4be));const _0x2a18cb=_0x15a01d[_0x15a01d['length']-0x1];null!==_0x17d4be&&(_0x17d4be=_0x2a18cb['is']('element','$text')?_0x2a18cb['getAttribute']('vid')+0x1:_0x2a18cb['getAttribute']('vid_end')+0x1);}else{for(let _0x12de16=0x0;_0x12de16<_0x1a0935['offsetSize'];_0x12de16++)_0x15a01d['push'](new ft('$text',{'vid':null===_0x17d4be?this['_revisionId']++:_0x17d4be++}));}if(_0x4d2689['is']('documentFragment')){const _0x54fcad=F(_0x4d2689['rootName']);return _0x54fcad['_insertChild'](0x0,_0x15a01d),_0x54fcad;}return _0x4fa094['_setAttribute']('vid_end',null===_0x17d4be?this['_revisionId']++:_0x17d4be++),_0x4fa094['_insertChild'](0x0,_0x15a01d),_0x4fa094;}['_calculateMetaData'](_0x87667e,_0x6a87da,_0x2801d5){this['_reset']();const {roots:_0xe78440,markers:_0x4ef36b,rootsAttributes:_0x2af241}=this['_savedMetaData']['get'](_0x87667e);this['_baseRoots']=new Map(_0xe78440),this['_baseRootsAttributes']=new Map(_0x5c1065(_0x2af241));for(const [_0x3197c1,_0x23e677]of this['_baseRoots'])if('$graveyard'!==_0x3197c1&&(this['_diffRoots']['set'](_0x3197c1,T(_0x23e677)),this['_diffRootsAttributes']=new Map(_0x5c1065(_0x2af241)),_0x2801d5)){const _0x4c8b28=this['_revisionId'];this['_idsRoots']['set'](_0x3197c1,this['_makeIdsRoot'](_0x23e677)),this['_baseIdsRoots']['set'](_0x3197c1,this['_makeIdsRoot'](_0x23e677,_0x4c8b28));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',T(this['_baseRoots']['get']('$graveyard'))),_0x2801d5&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0xba6bb3,_0x24106e]of _0x4ef36b){const _0x1116f2=this['_baseRoots']['get'](_0x24106e['rootName']),_0x234bbf=this['_diffRoots']['get'](_0x24106e['rootName']),_0x1c8fcc=new vt(this['_fixPosition'](_0x24106e['start'],_0x1116f2),this['_fixPosition'](_0x24106e['end'],_0x1116f2)),_0x55d0dd=this['_fixRange'](_0x1c8fcc,_0x234bbf);_0x1116f2['markers']['set'](_0xba6bb3,_0x1c8fcc),this['_markers']['set'](_0xba6bb3,_0x55d0dd);}this['_applyOperations'](_0x87667e,_0x6a87da,_0x2801d5);}['_applyOperations'](_0x24f1cf,_0x25856c,_0x19bbe5){for(const _0x3feece of this['source']['getOperations'](_0x24f1cf,_0x25856c))this['_handleOperation'](_0x3feece,_0x19bbe5);for(const _0x222c07 of this['_diffRoots']['values']())_0x222c07['markers']['clear']();for(const [_0x3745e4,_0x25ecea]of this['_markers']){this['_diffRoots']['get'](_0x25ecea['root']['rootName'])['markers']['set'](_0x3745e4,_0x25ecea['clone']());}const _0x2ab003=new Map(),_0x5da727=new Map();for(const [_0x8a3bf0,_0x5986b5]of this['_diffRoots'])_0x2ab003['set'](_0x8a3bf0,T(_0x5986b5)),_0x5da727['set'](_0x8a3bf0,this['_diffRootsAttributes']['get'](_0x8a3bf0));this['_saveMetaData'](_0x25856c,_0x2ab003,this['_markers'],_0x5da727);}['_getPreviousFrom'](_0x5d87a8){const _0x2d0712=Array['from'](this['_savedMetaData']['keys']());_0x2d0712['sort']((_0x208b5d,_0x1b3592)=>_0x208b5d-_0x1b3592),_0x2d0712['reverse']();for(const _0x4d7938 of _0x2d0712)if(_0x4d7938<_0x5d87a8)return _0x4d7938;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x4449a2,_0x2ebe66){const _0x4c1c4c=Array['from'](_0x2ebe66['markers'])['map'](([_0x763783,_0x352122])=>[_0x763783,this['_fixRange'](_0x352122,_0x4449a2)]);_0x4449a2['markers']=new Map(_0x4c1c4c);}['_transformMarkers'](_0x2a7a90){for(const _0x438876 of this['_markers']['values']()){const _0x34e8f7=_0x438876['getTransformedByOperation'](_0x2a7a90),_0x33bea6=vt['_createFromRanges'](_0x34e8f7);_0x438876['start']=_0x33bea6['start'],_0x438876['end']=_0x33bea6['end'];}}['_handleOperation'](_0x4aea0,_0x1dad2f){if('addRoot'!=_0x4aea0['type']&&'detachRoot'!=_0x4aea0['type']){if('insert'==_0x4aea0['type']){const _0x6c1bf1=_0x4aea0['position']['root']['rootName'];this['_diffRoots']['has'](_0x6c1bf1)||(this['_diffRoots']['set'](_0x6c1bf1,F(_0x6c1bf1,!0x0)),this['_diffRootsAttributes']['set'](_0x6c1bf1,{}),_0x1dad2f&&this['_idsRoots']['set'](_0x6c1bf1,F(_0x6c1bf1,!0x0)));}else{if('addRootAttribute'==_0x4aea0['type']||'removeRootAttribute'==_0x4aea0['type']||'changeRootAttribute'==_0x4aea0['type'])return void this['_handleRootAttributeOperation'](_0x4aea0);'marker'==_0x4aea0['type']&&this['_handleMarkerOperation'](_0x4aea0);}if('marker'!==_0x4aea0['type']){const _0xe5ab0f=this['_cloneOperation'](_0x4aea0,this['_diffRoots']);_0xe5ab0f['_execute'](),this['_transformMarkers'](_0xe5ab0f);}if(_0x1dad2f)switch(_0x4aea0['type']){case'insert':this['_handleInsertOperation'](_0x4aea0);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x4aea0);break;case'merge':this['_handleMergeOperation'](_0x4aea0);break;case'split':this['_handleSplitOperation'](_0x4aea0);}}else this['_handleRootOperation'](_0x4aea0,_0x1dad2f);}['_cloneOperation'](_0x3e3f73,_0x1ae4a5){const _0x3eee5b=_0x3e3f73['clone']();return _0x3eee5b['_authorId']=_0x3e3f73['_authorId'],this['_fixOperation'](_0x3eee5b,_0x1ae4a5),_0x3eee5b;}['_getBaseVids'](_0x23c3ac){return _0x23c3ac['map'](_0xdbb3b0=>{const _0x5290e0=this['_getVidAttributeName'](_0xdbb3b0);return Number(_0xdbb3b0['item']['getAttribute'](_0x5290e0));});}['_generateTape'](_0x2fe2f7,_0x27bf28){if(_0x2fe2f7['is']('element','$text'))_0x27bf28['push']({'item':_0x2fe2f7,'type':'text'});else{_0x2fe2f7['is']('element')&&_0x27bf28['push']({'item':_0x2fe2f7,'type':'elementStart'});for(const _0x366fd2 of _0x2fe2f7['getChildren']())this['_generateTape'](_0x366fd2,_0x27bf28);_0x2fe2f7['is']('element')&&_0x27bf28['push']({'item':_0x2fe2f7,'type':'elementEnd'});}return _0x27bf28;}['_getState'](){const _0x3146f8=new Map(this['_touched']),_0x243919=new Map(_0x3146f8),_0x42786c=new Map(),_0xdd4a3={'insertions':{},'deletions':{}},_0x22aef0={'insertions':{},'deletions':{}},_0x596b59=new Map(),_0x532287=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x532287['delete']('$graveyard');for(const _0xe30ec9 of _0x532287){const _0x457ed4=this['_diffRoots']['get'](_0xe30ec9)||F(_0xe30ec9,!0x1),_0x57d251=this['_baseRoots']['get'](_0xe30ec9)||F(_0xe30ec9,!0x1);_0x457ed4['isAttached']()||_0x57d251['isAttached']()?(_0xdd4a3['insertions'][_0xe30ec9]=T(_0x457ed4),_0xdd4a3['deletions'][_0xe30ec9]=T(_0x57d251),this['_copyMarkers'](_0xdd4a3['deletions'][_0xe30ec9],_0x57d251),this['_copyMarkers'](_0xdd4a3['insertions'][_0xe30ec9],_0x457ed4),_0x22aef0['insertions'][_0xe30ec9]=this['_generateTape'](this['_idsRoots']['get'](_0xe30ec9),[]),_0x22aef0['deletions'][_0xe30ec9]=this['_generateTape'](this['_baseIdsRoots']['get'](_0xe30ec9)||F(_0xe30ec9,!0x1),[])):_0x532287['delete'](_0xe30ec9);}for(const _0x175996 of _0x532287){const _0x57d8e7=_0x22aef0['insertions'][_0x175996];for(const _0x5eea44 of _0x57d8e7){const _0x31b9bd=this['_getVidAttributeName'](_0x5eea44),_0x27a3ff=_0x5eea44['item']['getAttribute'](_0x31b9bd);_0x243919['delete'](_0x27a3ff),_0x27a3ff>=this['_startingRevisionId']&&_0x42786c['set'](_0x27a3ff,_0x3146f8['get'](_0x27a3ff));}}for(const _0x49dede of _0x532287){const _0x245ac9=_0x22aef0['insertions'][_0x49dede],_0x1b1226=this['_getBaseVids'](_0x22aef0['deletions'][_0x49dede]);let _0x13581f=0x0;for(const _0x4f7a3b of _0x245ac9){const _0x30d47d=this['_getVidAttributeName'](_0x4f7a3b),_0x4da49e=_0x4f7a3b['item']['getAttribute'](_0x30d47d);if(!_0x42786c['has'](_0x4da49e)&&!_0x596b59['has'](_0x4da49e)){if(_0x243919['has'](_0x4da49e))_0x13581f++;else{if(_0x4da49e!=_0x1b1226[_0x13581f]){const _0x31df24=_0x3146f8['get'](_0x4da49e)||_0x3146f8['get'](_0x1b1226[_0x13581f]);for(;_0x4da49e!=_0x1b1226[_0x13581f];)_0x243919['has'](_0x1b1226[_0x13581f])||(_0x596b59['set'](_0x1b1226[_0x13581f],_0x31df24),_0x3146f8['set'](_0x1b1226[_0x13581f],_0x31df24)),_0x13581f++;}_0x13581f++;}}}}for(const _0x9df804 of _0x532287){const _0xf42d11=_0x22aef0['insertions'][_0x9df804];for(const _0x66bbeb of _0xf42d11){const _0x223b95=this['_getVidAttributeName'](_0x66bbeb),_0x5c49c8=_0x66bbeb['item']['getAttribute'](_0x223b95);if(_0x596b59['has'](_0x5c49c8)){const _0x3fe999=_0x596b59['get'](_0x5c49c8);_0x243919['has'](_0x5c49c8)||_0x243919['set'](_0x5c49c8,{..._0x3fe999}),_0x42786c['set'](_0x5c49c8,{..._0x3fe999});}}}for(const _0x43956e of _0x243919['keys']())_0x43956e>=this['_startingRevisionId']&&_0x243919['delete'](_0x43956e);const _0xe921a7=new Map();for(const _0x28050a of _0x532287){let _0x3966c1=_0x22aef0['insertions'][_0x28050a];for(const _0x1983ae of _0x3966c1)if(_0x1983ae['item']['is']('element','tableCell')){const _0x1c00c6=this['_getVidAttributeName'](_0x1983ae),_0x27ee3f=_0x1983ae['item']['getAttribute'](_0x1c00c6);if(_0x42786c['has'](_0x27ee3f)){const _0xa8d7d3=_0x1983ae['item']['parent']['parent']['getAttribute']('vid_start'),_0x1db5b9=_0xe921a7['get'](_0xa8d7d3)||new Set();_0x1db5b9['add'](_0x42786c['get'](_0x27ee3f)['userId']),_0xe921a7['set'](_0xa8d7d3,_0x1db5b9);}}_0x3966c1=_0x22aef0['deletions'][_0x28050a];for(const _0x4be004 of _0x3966c1)if(_0x4be004['item']['is']('element','tableCell')){const _0x2c9350=this['_getVidAttributeName'](_0x4be004),_0x538e1e=_0x4be004['item']['getAttribute'](_0x2c9350);if(_0x243919['has'](_0x538e1e)){const _0x29a8d9=_0x4be004['item']['parent']['parent']['getAttribute']('vid_start'),_0x88c6ba=_0xe921a7['get'](_0x29a8d9)||new Set();_0x88c6ba['add'](_0x243919['get'](_0x538e1e)['userId']),_0xe921a7['set'](_0x29a8d9,_0x88c6ba);}}for(const _0x3f3e29 of _0xe921a7['keys']())(_0x42786c['has'](_0x3f3e29)||_0x243919['has'](_0x3f3e29))&&_0xe921a7['delete'](_0x3f3e29);}for(const _0x4c1269 of _0x532287){const _0x15bd0a=_0x22aef0['insertions'][_0x4c1269];let _0x51c91a=null,_0x1a6376=null;for(const _0x4e71fd of _0x15bd0a){const _0xeed159=this['_getVidAttributeName'](_0x4e71fd),_0x2dfade=_0x4e71fd['item']['getAttribute'](_0xeed159),_0x53f02d=_0xe921a7['get'](_0x2dfade);_0x53f02d&&'elementStart'==_0x4e71fd['type']&&(_0x51c91a=Array['from'](_0x53f02d)[0x0],_0x1a6376=_0x4e71fd['item']['getAttribute']('vid_end')),_0x51c91a&&(_0x243919['set'](_0x2dfade,{'userId':_0x51c91a}),_0x42786c['set'](_0x2dfade,{'userId':_0x51c91a})),_0x2dfade==_0x1a6376&&(_0x51c91a=null,_0x1a6376=null);}}const _0x41e0c7={},_0x26c3cf=new Set();for(const _0x1fb989 of _0x532287){const _0x1184b2=_0xdd4a3['deletions'][_0x1fb989],_0x279eba=_0xdd4a3['insertions'][_0x1fb989];for(const {userId:_0xd16b47}of this['_touchedMarkers']['values']())null!==_0xd16b47&&_0x26c3cf['add'](_0xd16b47);for(const {userId:_0x34c09f}of this['_touchedRoots']['values']())null!==_0x34c09f&&_0x26c3cf['add'](_0x34c09f);this['_markChanges'](_0x279eba,_0x22aef0['insertions'][_0x1fb989],_0x42786c,'insertion',_0x26c3cf),this['_markChanges'](_0x1184b2,_0x22aef0['deletions'][_0x1fb989],_0x243919,'deletion',_0x26c3cf),_0x41e0c7[_0x1fb989]={'insertions':this['_prepareViewToSave'](_0x279eba),'deletions':this['_prepareViewToSave'](_0x1184b2),'attachChange':this['_touchedRoots']['get'](_0x1fb989)||null,'attributesBefore':_0x5c1065(this['_baseRootsAttributes']['get'](_0x1fb989))||{},'attributesAfter':_0x5c1065(this['_diffRootsAttributes']['get'](_0x1fb989))};}return{'diffData':_0x41e0c7,'authorsIds':Array['from'](_0x26c3cf)};}['_processRootBeforeSave'](_0x40d4d4){for(const [,_0x1e7989]of _0x40d4d4['markers']){const _0x370729=_0x1e7989['start']['getAncestors']()['filter'](_0x3c48cc=>'tableCell'==_0x3c48cc['name']);for(const _0x4a7280 of _0x370729)0x1==_0x4a7280['childCount']&&_0x4a7280['getChild'](0x0)['is']('element','paragraph')&&_0x4a7280['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x4ba9d7){this['_processRootBeforeSave'](_0x4ba9d7);const _0x2dc475=this['editor']['data']['toView'](_0x4ba9d7,{}),_0x321cee=Array['from'](_0x2dc475['getChildren']())['map'](_0x5bcca6=>this['_getViewJson'](_0x5bcca6));return JSON['stringify'](_0x321cee);}['_getViewJson'](_0x5109b3){if(_0x5109b3['is']('$text'))return _0x5109b3['data'];{const _0x1bfe8e=_0x5109b3;return{'type':Object['keys'](P)['find'](_0x13dec3=>_0x5109b3 instanceof P[_0x13dec3]),'name':_0x1bfe8e['name'],'attributes':Array['from'](_0x1bfe8e['getAttributes']()),'children':Array['from'](_0x1bfe8e['getChildren']())['map'](_0x1e633f=>this['_getViewJson'](_0x1e633f))};}}['_markChanges'](_0x1174c3,_0x5374a1,_0x2c88ef,_0x263588,_0x6e9b4b){let _0x52e76e=null,_0x5a5538=null,_0x33fdb7=0x0;const _0x5aa8c2=this['editor']['model'];for(let _0x1733dc=0x0;_0x1733dc<_0x5374a1['length'];_0x1733dc++){const _0x4868f0=this['_getVidAttributeName'](_0x5374a1[_0x1733dc]),_0x3ce78a=_0x5374a1[_0x1733dc]['item']['getAttribute'](_0x4868f0),_0x142776=_0x2c88ef['get'](_0x3ce78a),_0x248333=_0x1733dc==_0x5374a1['length']-0x1;(!_0x52e76e&&_0x142776&&(_0x52e76e=_0x142776,_0x5a5538=_0x5374a1[_0x1733dc]),_0x52e76e&&(!_0x142776||_0x142776['userId']!=_0x52e76e['userId']))&&(_0x31dd37(_0x142776,B(_0x5a5538,_0x1174c3,_0x5aa8c2),B(_0x5374a1[_0x1733dc],_0x1174c3,_0x5aa8c2)),_0x52e76e=_0x142776||null,_0x5a5538=_0x142776?_0x5374a1[_0x1733dc]:null),_0x52e76e&&_0x248333&&_0x31dd37(_0x142776,B(_0x5a5538,_0x1174c3,_0x5aa8c2),J(_0x5374a1[_0x1733dc],_0x1174c3,_0x5aa8c2));}function _0x31dd37(_0x555c9f,_0x3e80bd,_0x1ad36d){const _0x1df00d=_0x52e76e['userId'],_0x579b38='revision:'+_0x263588+':'+_0x1df00d+':'+_0x33fdb7++,_0x231da3=_0x5aa8c2['createRange'](_0x3e80bd,_0x1ad36d);_0x1174c3['markers']['set'](_0x579b38,_0x231da3),null!==_0x1df00d&&_0x6e9b4b['add'](_0x1df00d);}}['_getVidAttributeName'](_0x4f0a4d){switch(_0x4f0a4d['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x963ce2,_0x58c50e){_0x963ce2['baseVersion']=null;for(const _0x48acde in _0x963ce2){const _0x3baa20=_0x963ce2[_0x48acde];if(_0x3baa20 instanceof gt){const _0x46ea15=_0x58c50e['get'](_0x3baa20['root']['rootName']);_0x963ce2[_0x48acde]=this['_fixPosition'](_0x3baa20,_0x46ea15);}if(_0x3baa20 instanceof vt){const _0x205a59=_0x58c50e['get'](_0x3baa20['root']['rootName']);_0x963ce2[_0x48acde]=this['_fixRange'](_0x3baa20,_0x205a59);}'root'===_0x48acde&&(_0x963ce2['root']=_0x58c50e['get'](_0x963ce2['root']['rootName']));}}['_fixRange'](_0x3b1b38,_0x5b7c12){return this['editor']['model']['createRange'](this['_fixPosition'](_0x3b1b38['start'],_0x5b7c12),this['_fixPosition'](_0x3b1b38['end'],_0x5b7c12));}['_fixPosition'](_0x3d3b89,_0xa7394b){return this['editor']['model']['createPositionFromPath'](_0xa7394b,_0x3d3b89['path'],_0x3d3b89['stickiness']);}['_handleInsertOperation'](_0x172f0c){const _0x47f1a4=this['_idsRoots']['get'](_0x172f0c['position']['root']['rootName']),_0x33ae64=this['_fixPosition'](_0x172f0c['position'],_0x47f1a4),_0x479e0a=null===_0x172f0c['_authorId']?null:_0x172f0c['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x1b27dd=_0x33ae64['parent'],_0x2198b0=this['_revisionId'],_0x919718=[];for(const _0x3d56cb of _0x172f0c['nodes'])if(_0x3d56cb['is']('element'))_0x919718['push'](this['_makeIdsRoot'](_0x3d56cb));else{for(let _0x5b8b5b=0x0;_0x5b8b5b<_0x3d56cb['offsetSize'];_0x5b8b5b++)_0x919718['push'](new ft('$text',{'vid':this['_revisionId']++}));}const _0x110cbe=this['_revisionId'];for(let _0x5906d2=_0x2198b0;_0x5906d2<_0x110cbe;_0x5906d2++)this['_touched']['set'](_0x5906d2,{'userId':_0x479e0a});_0x1b27dd['_insertChild'](_0x33ae64['offset'],_0x919718);}['_handleMoveOperation'](_0x1a0c1c){(_0x1a0c1c=this['_cloneOperation'](_0x1a0c1c,this['_idsRoots']))['_execute']();const _0x6dbb70=null===_0x1a0c1c['_authorId']?null:_0x1a0c1c['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x43c266=_0x1a0c1c['getMovedRangeStart'](),_0x54a7bd=_0x43c266['parent'],_0xd6c69=_0x43c266['offset'];!function _0x28c66a(_0x4c0344,_0x6cb87,_0x4cb5ce,_0x356851){for(let _0x48693a=_0x4cb5ce;_0x48693a<_0x356851;_0x48693a++){const _0x35d82f=_0x6cb87['getChild'](_0x48693a);_0x35d82f['is']('element','$text')?_0x4c0344['set'](_0x35d82f['getAttribute']('vid'),{'userId':_0x6dbb70}):(_0x4c0344['set'](_0x35d82f['getAttribute']('vid_start'),{'userId':_0x6dbb70}),_0x28c66a(_0x4c0344,_0x35d82f,0x0,_0x35d82f['childCount']),_0x4c0344['set'](_0x35d82f['getAttribute']('vid_end'),{'userId':_0x6dbb70}));}}(this['_touched'],_0x54a7bd,_0xd6c69,_0xd6c69+_0x1a0c1c['howMany']);}['_handleMergeOperation'](_0x224f4b){const _0x28f8cd=null===(_0x224f4b=this['_cloneOperation'](_0x224f4b,this['_idsRoots']))['_authorId']?null:_0x224f4b['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x151a61=_0x224f4b['targetPosition']['parent'],_0x4bab0e=_0x224f4b['sourcePosition']['parent'],_0x5a9eea=_0x151a61['getAttribute']('vid_end'),_0x4b21f5=_0x4bab0e['getAttribute']('vid_start');_0x151a61['_setAttribute']('vid_end',_0x4bab0e['getAttribute']('vid_end')),_0x4bab0e['_setAttribute']('vid_end',_0x5a9eea),this['_touched']['set'](_0x4b21f5,{'userId':_0x28f8cd}),this['_touched']['set'](_0x5a9eea,{'userId':_0x28f8cd}),_0x224f4b['_execute']();}['_handleSplitOperation'](_0x2408aa){const _0x53b423=null===(_0x2408aa=this['_cloneOperation'](_0x2408aa,this['_idsRoots']))['_authorId']?null:_0x2408aa['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x5975c9=_0x2408aa['graveyardPosition'],_0x8eb59b=_0x2408aa['splitPosition']['parent'];_0x2408aa['_execute']();const _0x37a0e4=_0x8eb59b['getAttribute']('vid_end'),_0x31dec0=_0x2408aa['insertionPosition']['nodeAfter'];if(_0x5975c9){const _0x2c8649=_0x31dec0['getAttribute']('vid_end'),_0x59a343=_0x8eb59b['getAttribute']('vid_end');_0x8eb59b['_setAttribute']('vid_end',_0x2c8649),_0x31dec0['_setAttribute']('vid_end',_0x59a343),this['_touched']['set'](_0x8eb59b['getAttribute']('vid_end'),{'userId':_0x53b423}),this['_touched']['set'](_0x31dec0['getAttribute']('vid_start'),{'userId':_0x53b423});}else{const _0x125352=this['_revisionId']++,_0x35d46f=this['_revisionId']++;_0x8eb59b['_setAttribute']('vid_end',_0x125352),_0x31dec0['_setAttribute']('vid_start',_0x35d46f),_0x31dec0['_setAttribute']('vid_end',_0x37a0e4),this['_touched']['set'](_0x125352,{'userId':_0x53b423}),this['_touched']['set'](_0x35d46f,{'userId':_0x53b423});}}['_handleMarkerOperation'](_0x2c6992){if(!_0x2c6992['affectsData'])return;const _0x1e906d=(_0x2c6992=this['_cloneOperation'](_0x2c6992,this['_diffRoots']))['oldRange']?_0x2c6992['oldRange']['root']:null,_0x15d6dd=_0x2c6992['newRange']?_0x2c6992['newRange']['root']:null;_0x1e906d&&this['_markers']['delete'](_0x2c6992['name']),_0x15d6dd&&this['_markers']['set'](_0x2c6992['name'],_0x2c6992['newRange']['clone']());const _0x1d43a8=null===_0x2c6992['_authorId']?null:_0x2c6992['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x66d2db=_0x2c6992['name'];if(!this['_touchedMarkers']['has'](_0x66d2db))return void this['_touchedMarkers']['set'](_0x66d2db,{'range':_0x2c6992['oldRange'],'userId':_0x1d43a8});const _0x112ec4=this['_touchedMarkers']['get'](_0x66d2db),_0x178234=_0x112ec4['range'],_0x38a7b0=_0x2c6992['newRange'];null==_0x178234&&null==_0x38a7b0||_0x178234&&_0x38a7b0&&_0x178234['isEqual'](_0x38a7b0)?this['_touchedMarkers']['delete'](_0x2c6992['name']):_0x112ec4['userId']=_0x1d43a8;}['_handleRootOperation'](_0xae831f,_0x12e175){this['_diffRoots']['has'](_0xae831f['rootName'])?this['_diffRoots']['get'](_0xae831f['rootName'])['_isAttached']=_0xae831f['isAdd']:(this['_diffRoots']['set'](_0xae831f['rootName'],F(_0xae831f['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0xae831f['rootName'],{}),_0x12e175&&this['_idsRoots']['set'](_0xae831f['rootName'],F(_0xae831f['rootName'],!0x0)));const _0x12cc42=null===_0xae831f['_authorId']?null:_0xae831f['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x57944e=this['_touchedRoots']['get'](_0xae831f['rootName']);_0x57944e&&_0x57944e['userId']===_0x12cc42?this['_touchedRoots']['delete'](_0xae831f['rootName']):this['_touchedRoots']['set'](_0xae831f['rootName'],{'userId':_0x12cc42,'isAttached':_0xae831f['isAdd']});}['_handleRootAttributeOperation'](_0x2547ee){const _0x530176=this['_diffRootsAttributes']['get'](_0x2547ee['root']['rootName']);null===_0x2547ee['newValue']?delete _0x530176[_0x2547ee['key']]:_0x530176[_0x2547ee['key']]=_0x2547ee['newValue'];}}function T(_0x4ea488){const _0x56d498=F(_0x4ea488['rootName'],_0x4ea488['isAttached']());for(const _0x5e29a9 of _0x4ea488['getChildren']()){const _0xce407d=_0x5e29a9['_clone'](!0x0);_0x56d498['_appendChild'](_0xce407d);}return _0x56d498;}function F(_0x635923,_0x325d11=!0x0){const _0x508112=new mt();return _0x508112['rootName']=_0x635923,_0x508112['_isAttached']=_0x325d11,_0x508112['isAttached']=()=>_0x508112['_isAttached'],_0x508112;}function B(_0x45126e,_0x4d89b8,_0x3da1c8){const _0x274897='elementEnd'==_0x45126e['type']?_0x3da1c8['createPositionAt'](_0x45126e['item'],'end'):_0x3da1c8['createPositionBefore'](_0x45126e['item']);return _0x3da1c8['createPositionFromPath'](_0x4d89b8,_0x274897['path'],_0x274897['stickiness']);}function J(_0x1e7900,_0x1ab950,_0x3371e0){const _0x50de12='elementStart'==_0x1e7900['type']?_0x3371e0['createPositionAt'](_0x1e7900['item'],0x0):_0x3371e0['createPositionAfter'](_0x1e7900['item']);return _0x3371e0['createPositionFromPath'](_0x1ab950,_0x50de12['path'],_0x50de12['stickiness']);}class ns extends _0xc8540d{['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0xcccc7d,_0x5d81d6){super(_0xcccc7d),this['focusTracker']=new _0x941cc7(),this['keystrokes']=new _0x284cce(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x5d81d6),this['setTemplate']({'tag':'form','attributes':{'class':['ck','ck-revision-history-save-revision-form','ck-responsive-form'],'tabindex':'-1'},'children':[this['revisionNameInputView']]}),ts(this);}['render'](){super['render'](),_0x21b862({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0xd7807=_0x532014=>_0x532014['stopPropagation']();this['keystrokes']['set']('arrowright',_0xd7807),this['keystrokes']['set']('arrowleft',_0xd7807),this['keystrokes']['set']('arrowup',_0xd7807),this['keystrokes']['set']('arrowdown',_0xd7807);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x487686){this['revisionNameInputView']['fieldView']['element']['value']=_0x487686['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x4d3ad1){const _0x492cb5=new nt(this['locale'],_0xca8177),_0x27a50f=_0x492cb5['fieldView'];_0x27a50f['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x390ed0=m(this['locale'],'Name\x20of\x20the\x20revision');return!_0x4d3ad1&&(_0x390ed0+='\x20('+m(this['locale'],'optional')+')'),(_0x492cb5['label']=_0x390ed0,_0x27a50f['on']('input',()=>{this['revisionNameInputValue']=_0x27a50f['element']['value']['trim']();}),_0x492cb5);}}class u extends _0x1448f8{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l];}['_saveRevisionFormView'];['init'](){const _0x5e38fe=this['editor'],_0x147bc7=_0x5e38fe['plugins']['get']('RevisionTracker');_0x5e38fe['ui']['componentFactory']['add']('revisionHistory',_0xa6c57d=>{const _0x10f754=_0x534184(_0xa6c57d),_0x42d47c=_0x10f754['panelView']['children'],_0x490eb1=new te(_0xa6c57d),_0x55a9fe=new _0x5c5a58(_0xa6c57d),_0xb86007=new _0x1a0086(_0xa6c57d),_0xc4b10e=new _0x5c5a58(_0xa6c57d),_0x3366a6=new _0x1a0086(_0xa6c57d);return _0x10f754['bind']('isEnabled')['to'](_0x147bc7,'isReady',_0x147bc7,'isEnabled',_0x5e38fe,'isReadOnly',(_0x4edeff,_0x49043c,_0x3272b2)=>_0x4edeff&&_0x49043c&&!_0x3272b2),_0x10f754['buttonView']['set']({'icon':_0x2c63e9['history'],'label':m(_0xa6c57d,'Revision\x20history'),'tooltip':!0x0}),_0xb86007['set']({'label':m(_0xa6c57d,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0xb86007['bind']('isEnabled')['to'](_0x147bc7,'isReady',_0x147bc7,'isEnabled',_0x5e38fe,'isReadOnly',(_0x3b65d9,_0x1c7e3b,_0x79b4b2)=>_0x3b65d9&&_0x1c7e3b&&!_0x79b4b2),_0xb86007['on']('execute',()=>this['_showDialog']()),_0x3366a6['set']({'label':m(_0xa6c57d,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x3366a6['bind']('isEnabled')['to'](_0x147bc7,'isReady',_0x5e38fe,'isReadOnly',(_0x25340e,_0xc05dbb)=>_0x25340e&&!_0xc05dbb),_0x3366a6['on']('execute',()=>{_0x5e38fe['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x10f754['isOpen']=!0x1,_0x5e38fe['editing']['view']['focus']();}),_0x55a9fe['children']['add'](_0xb86007),_0xc4b10e['children']['add'](_0x3366a6),_0x490eb1['role']='menu',_0x490eb1['items']['addMany']([_0x55a9fe,_0xc4b10e]),_0x42d47c['add'](_0x490eb1),_0x10f754;}),_0x5e38fe['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x34b558=this['editor'],_0x4d7797=_0x34b558['locale'],_0x3168a5=new _0x294fd1(_0x4d7797),_0xd23ee3=new _0x54b82c(_0x4d7797);_0x3168a5['buttonView']['set']({'icon':_0x2c63e9['history'],'label':m(_0x4d7797,'Revision\x20history')});const _0x33ddd3=new _0x45b040(_0x4d7797,_0x3168a5),_0x2fb65b=new _0x36bdcc(_0x4d7797);_0x2fb65b['set']({'label':m(_0x4d7797,'Save\x20current\x20revision')}),_0x2fb65b['delegate']('execute')['to'](_0x3168a5),_0x2fb65b['on']('execute',()=>{this['_showDialog']();}),_0x33ddd3['children']['add'](_0x2fb65b),_0xd23ee3['items']['add'](_0x33ddd3);const _0x297deb=new _0x45b040(_0x4d7797,_0x3168a5),_0xe2576e=new _0x36bdcc(_0x4d7797);return _0xe2576e['set']({'label':m(_0x4d7797,'Open\x20revision\x20history')}),_0xe2576e['delegate']('execute')['to'](_0x3168a5),_0xe2576e['on']('execute',()=>{_0x34b558['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x297deb['children']['add'](_0xe2576e),_0xd23ee3['items']['add'](_0x297deb),_0x3168a5['panelView']['children']['add'](_0xd23ee3),_0x3168a5;}['_showDialog'](){const _0x20d792=this['editor'],_0x4e47a3=_0x20d792['locale'],_0x362ca5=_0x20d792['plugins']['get']('Dialog'),_0x368b25=_0x20d792['plugins']['get']('RevisionTracker');function _0x36cdea(_0x1fac7a){_0x20d792['config']['get']('revisionHistory.requireRevisionName')&&''===_0x1fac7a['revisionName']?_0x1fac7a['revisionNameInputView']['errorText']=m(_0x4e47a3,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x20d792['plugins']['get'](l)['saveRevision']({'name':_0x1fac7a['revisionName']}),_0x362ca5['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x36cdea(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x362ca5['show']({'id':'revisionSave','title':m(_0x4e47a3,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':m(_0x20d792['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x362ca5['hide']()},{'label':m(_0x20d792['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x365cb7){_0x365cb7['bind']('isEnabled')['to'](_0x368b25,'isReady',_0x368b25,'isEnabled',_0x20d792,'isReadOnly',(_0x29ad0a,_0x481169,_0x27985c)=>_0x29ad0a&&_0x481169&&!_0x27985c);},'onExecute':()=>_0x36cdea(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0xb523c6=this['editor'],_0x361725=_0xb523c6['locale'];this['_saveRevisionFormView']=new ns(_0x361725,_0xb523c6['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class X extends _0xc8540d{['changeId'];['_model'];constructor(_0x44240e,_0x1db822){super(_0x44240e),this['_model']=_0x1db822,this['changeId']=_0x1db822['id'];const _0x3779ef=this['bindTemplate'],_0x3d73e1=m(_0x44240e,_0x1db822['data']['isSuggestion']?'Suggested\x20by':'add'==_0x1db822['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x1db822['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x3779ef['to']('type',_0x121fae=>'ck-revision-change__'+_0x121fae)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x3d73e1}]},{'text':'\x20'+_0x1db822['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class r extends/* #__PURE__ -- @preserve */
25
- _0x3deca7(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x5a1c53){super(),this['id']=_0x5a1c53['id']||_0x346491(),this['author']=_0x5a1c53['author'],this['type']=_0x5a1c53['type'],this['data']=_0x5a1c53['data']||{},this['rootName']=_0x5a1c53['rootName'],this['set']('createdAt',_0x5a1c53['createdAt']);}['toJSON'](){return{'id':this['id'],'authorId':this['author']['id'],'type':this['type'],'data':this['data'],'createdAt':this['createdAt']};}}class f{['newRevisionId'];['oldRevisionId'];['changes'];constructor(_0x4445ab,_0xd595df){this['newRevisionId']=_0x4445ab,this['oldRevisionId']=_0xd595df,this['changes']=new _0x47adf8();}['_setChanges'](_0x2c742c){for(const _0x238b6d of _0x2c742c)this['changes']['add'](_0x238b6d);}}const Y={'c':_0x46a47d,'a':_0x10a2a7,'e':_0x5c2fc2,'r':_0x2fa9bb,'u':_0x32b256};class d extends _0x1448f8{['repository'];['adapter'];['_activeViewTarget'];['_changeView'];['_changeIdToChange'];['_balloon'];static get['pluginName'](){return'RevisionViewer';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[_0x3f20df,_0x38f2a5,j];}constructor(_0x40e761){super(_0x40e761),this['repository']=this['editor']['plugins']['get']('RevisionsRepository'),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',(_0x3f6651,_0x4a470e,_0x3e5d9a)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x1cf85c=>{for(const _0x31d897 of this['editor']['editing']['view']['document']['roots'])_0x3e5d9a?_0x1cf85c['removeClass']('ck-editor__editable__overlay',_0x31d897):_0x1cf85c['addClass']('ck-editor__editable__overlay',_0x31d897);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x46129a=>null!==_0x46129a),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x5e4d2d,_0x2c7452,_0x11d33c)=>_0x5e4d2d&&_0x11d33c?_0x2c7452['changes']['getIndex'](_0x11d33c):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x343809,_0x280a89)=>_0x343809?_0x280a89['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['adapter']=null,this['_balloon']=this['editor']['plugins']['get'](_0x38f2a5);}['init'](){const _0x17554d=this['editor'],_0x138907=new yt(_0x17554d,{'direction':'backward'}),_0x502902=new yt(_0x17554d,{'direction':'forward'});(_0x17554d['commands']['add']('showPreviousChange',_0x138907),_0x17554d['commands']['add']('showNextChange',_0x502902),_0x17554d['commands']['add']('restoreRevision',new _t(_0x17554d)),this['on']('change:numberOfChanges',()=>{_0x138907['refresh'](),_0x502902['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x17554d['enableReadOnlyMode']('revision-viewer'),_0x17554d['plugins']['has']('WidgetToolbarRepository'))&&_0x17554d['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionData'](_0x2ef019){await this['loadRevisionData'](_0x2ef019);const _0x518679={};for(const _0x5b4184 in _0x2ef019['diffData']){if(_0x2ef019['diffData'][_0x5b4184]['attachChange']&&!_0x2ef019['diffData'][_0x5b4184]['attachChange']['isAttached'])continue;const _0x4a1769=this['_removeRevisionMarkers'](JSON['parse'](_0x2ef019['diffData'][_0x5b4184]['insertions'])),_0x1bdce1=this['editor']['editing']['view']['document'],_0x3d058a=new _0x12388(_0x1bdce1,_0x4a1769['map'](_0x2841cb=>this['_getViewObj'](_0x2841cb)));this['editor']['data']['processor']['useFillerType']('marked'),_0x518679[_0x5b4184]=this['editor']['data']['processor']['toData'](_0x3d058a),this['editor']['data']['processor']['useFillerType']('default');}return _0x518679;}async['getRevisionRootsAttributes'](_0x44a293){await this['loadRevisionData'](_0x44a293);const _0xaac224={};for(const _0x13950e in _0x44a293['diffData'])_0x44a293['diffData'][_0x13950e]['attachChange']&&!_0x44a293['diffData'][_0x13950e]['attachChange']['isAttached']||(_0xaac224[_0x13950e]=_0x44a293['diffData'][_0x13950e]['attributesAfter']||{});return _0xaac224;}['_removeRevisionMarkers'](_0x11aae3){return(_0x11aae3=_0x11aae3['filter'](_0x5b46e2=>!_0x5b46e2['name']||'revision-start'!==_0x5b46e2['name']&&'revision-end'!==_0x5b46e2['name']))['forEach'](_0x586e39=>{'string'!=typeof _0x586e39&&(_0x586e39['children']=this['_removeRevisionMarkers'](_0x586e39['children']),_0x586e39['attributes']=_0x586e39['attributes']['filter'](_0x184813=>!_0x184813[0x0]['startsWith']('data-revision-')));}),_0x11aae3;}async['compare'](_0x4b412c,_0x5a68fd,_0x10fcd7=!0x1){if(!this['isEnabled'])return;const _0x56ec6f=this['diff'],_0x5ac02e=this['repository'],_0x248e0a='string'==typeof _0x4b412c?_0x5ac02e['getRevision'](_0x4b412c):_0x4b412c,_0xc6c79='string'==typeof _0x5a68fd?_0x5ac02e['getRevision'](_0x5a68fd):_0x5a68fd,_0x4a740b=_0x248e0a['id'],_0x4adc4e=_0xc6c79?_0xc6c79['id']:null;if(!_0x10fcd7&&this['diff']&&this['diff']['newRevisionId']===_0x4a740b&&this['diff']['oldRevisionId']===_0x4adc4e)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new f(_0x4a740b,_0x4adc4e);const _0x1c032a=this['_getRevisionsRange'](_0x248e0a,_0xc6c79,!0x0)['map'](_0x5d34fc=>this['loadRevisionData'](_0x5d34fc));return _0x1c032a['push'](new Promise(_0x31ec72=>{setTimeout(_0x31ec72,0x14);})),Promise['all'](_0x1c032a)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x585a6f=this['_getDiff'](_0x4a740b,_0x4adc4e);for(const _0x2a035a of _0x585a6f['changes'])this['_changeIdToChange']['set'](_0x2a035a['id'],_0x2a035a);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x3a3d7a=>{for(const _0x51b91b of this['editor']['model']['document']['getRootNames']())_0x3a3d7a['detachRoot'](_0x51b91b);for(const _0x51a1ce of Object['keys'](_0x585a6f['model'])){const _0xba74c5=_0x3a3d7a['addRoot'](_0x51a1ce);for(const _0x2370c9 of Object['keys'](_0x585a6f['attributes'][_0x51a1ce]))_0x3a3d7a['setAttribute'](_0x2370c9,_0x585a6f['attributes'][_0x51a1ce][_0x2370c9],_0xba74c5);_0x3a3d7a['insert'](_0x585a6f['model'][_0x51a1ce],_0xba74c5,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x585a6f['changes'])),this['isReady']=!0x0;})['catch'](_0x3baa53=>{console['error'](_0x3baa53),this['_cleanUp'](),_0x56ec6f&&(this['diff']=_0x56ec6f),this['isReady']=!0x0;});}['addRevisionData'](_0x4f5a90,_0x3989ff){const _0x43c14e=this['repository']['createRevision'](_0x4f5a90);return _0x43c14e['on']('_update',(_0x3548a5,_0x21bee0,_0x5529b1)=>_0x3989ff(_0x21bee0,_0x5529b1,_0x43c14e)),this['repository']['addRevision'](_0x43c14e),_0x43c14e;}['loadRevisionData'](_0x47b26a){if(!_0x47b26a||_0x47b26a['diffData'])return Promise['resolve']();{const _0x1bb669=this['editor']['config']['get']('collaboration.channelId');return this['adapter']['getRevision']({'channelId':_0x1bb669,'revisionId':_0x47b26a['id']})['then'](_0x186a71=>{_0x47b26a['_update']({'diffData':_0x186a71['diffData']},!0x0);});}}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x2e2a61=>{for(const _0x218cf6 of this['editor']['model']['document']['getRootNames']())_0x2e2a61['detachRoot'](_0x218cf6);});}['_sortAndFilterDiffChanges'](_0x5b58a5){const _0x170b8f=[],_0x4760ff=new Map();for(const _0x3b6b56 of this['editor']['model']['document']['getRootNames']()){const _0x58f49b=this['editor']['editing']['view']['getDomRoot'](_0x3b6b56);if(!_0x58f49b)continue;const _0x5c0e17=_0x58f49b['getClientRects']()['item'](0x0);_0x5c0e17&&(_0x170b8f['push'](_0x3b6b56),_0x4760ff['set'](_0x3b6b56,_0x5c0e17));}return _0x170b8f['sort']((_0x75d1f9,_0x26eb61)=>{const _0x9c5f5=_0x4760ff['get'](_0x75d1f9),_0x55e399=_0x4760ff['get'](_0x26eb61);return _0x9c5f5['y']-_0x55e399['y']||_0x9c5f5['x']-_0x55e399['x'];}),(_0x5b58a5=_0x5b58a5['filter'](_0x361f85=>_0x170b8f['includes'](_0x361f85['rootName'])))['sort']((_0x170754,_0x29a264)=>_0x170b8f['indexOf'](_0x170754['rootName'])-_0x170b8f['indexOf'](_0x29a264['rootName'])),_0x5b58a5;}['_makeTape'](_0x10b488){const _0x147808=Array['from'](_0x10b488['markers'])['filter'](([_0x175613,_0x1de2ac])=>_0x175613['startsWith']('revision:')&&!_0x1de2ac['isCollapsed']),_0x37f549=Array['from'](this['editor']['model']['createRangeIn'](_0x10b488)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x147808['length'])for(const _0x3259a9 of _0x37f549){const [_0xfa8f3a,_0x2eec3a]=_0x147808[0x0],[,_0x125d3e,_0x4c7950]=_0xfa8f3a['split'](':');if(_0x2eec3a['end']['isEqual'](_0x3259a9['nextPosition'])&&_0x147808['shift'](),(_0x3259a9['previousPosition']['isEqual'](_0x2eec3a['start'])||_0x3259a9['previousPosition']['isAfter'](_0x2eec3a['start']))&&('insertion'==_0x125d3e?_0x3259a9['isAdded']={'userId':_0x4c7950}:'deletion'==_0x125d3e&&(_0x3259a9['isRemoved']={'userId':_0x4c7950})),0x0==_0x147808['length'])break;}return _0x37f549;}['_refreshStartEndIndex'](_0x408e9d){const _0x4c7917=new Map();for(let _0xdf8808=0x0;_0xdf8808<_0x408e9d['length'];_0xdf8808++)'text'===_0x408e9d[_0xdf8808]['type']?(_0x408e9d[_0xdf8808]['item']['startIndex']=_0xdf8808,_0x408e9d[_0xdf8808]['item']['endIndex']=_0xdf8808):('elementStart'===_0x408e9d[_0xdf8808]['type']?_0x408e9d[_0xdf8808]['item']['startIndex']=_0xdf8808:'elementEnd'===_0x408e9d[_0xdf8808]['type']&&(_0x408e9d[_0xdf8808]['item']['endIndex']=_0xdf8808),_0x4c7917['set'](_0x408e9d[_0xdf8808]['id'],_0xdf8808));for(const _0x379601 of _0x4c7917['values']())'elementStart'===_0x408e9d[_0x379601]['type']?_0x408e9d[_0x379601]['item']['endIndex']=_0x4c7917['get'](_0x408e9d[_0x379601]['pairId']):'elementEnd'===_0x408e9d[_0x379601]['type']&&(_0x408e9d[_0x379601]['item']['startIndex']=_0x4c7917['get'](_0x408e9d[_0x379601]['pairId']));}['_processTape'](_0x253c2b){for(let _0x3d7d6=0x0;_0x3d7d6<_0x253c2b['length'];_0x3d7d6++){if('elementStart'===_0x253c2b[_0x3d7d6]['type'])_0x253c2b[_0x3d7d6]['item']['startIndex']=_0x3d7d6;else{if('elementEnd'===_0x253c2b[_0x3d7d6]['type']){_0x253c2b[_0x3d7d6]['item']['endIndex']=_0x3d7d6;const _0x4adac7=_0x253c2b[_0x3d7d6]['item']['startIndex'];_0x253c2b[_0x4adac7]['pairId']=_0x253c2b[_0x3d7d6]['id'],_0x253c2b[_0x3d7d6]['pairId']=_0x253c2b[_0x4adac7]['id'];}else _0x253c2b[_0x3d7d6]['item']['startIndex']=_0x3d7d6,_0x253c2b[_0x3d7d6]['item']['endIndex']=_0x3d7d6,_0x253c2b[_0x3d7d6]['pairId']=null;}_0x253c2b[_0x3d7d6]['markersStart']||(_0x253c2b[_0x3d7d6]['markersStart']=[],_0x253c2b[_0x3d7d6]['markersEnd']=[]);}}['_markInsertions'](_0x2ef46c,_0x5b3166){const _0x3fde9e=_0x2ef46c['filter'](_0x33e164=>!_0x33e164['isAdded']);for(let _0x2fa3e3=0x0;_0x2fa3e3<_0x5b3166['length'];_0x2fa3e3++)_0x5b3166[_0x2fa3e3]['isAdded']&&(_0x3fde9e[_0x2fa3e3]['isAdded']=_0x5b3166[_0x2fa3e3]['isAdded']);}['_makeModelFromViewString'](_0x2f58ca){const _0x41b237=JSON['parse'](_0x2f58ca),_0x21d8bf=this['editor']['editing']['view']['document'],_0x4d3f17=new _0x12388(_0x21d8bf,_0x41b237['map'](_0x35bacb=>this['_getViewObj'](_0x35bacb)));return this['editor']['data']['toModel'](_0x4d3f17);}['_getViewObj'](_0x5edf5b){const _0x14e748=this['editor']['editing']['view']['document'];if('string'==typeof _0x5edf5b)return new _0x5d408e(_0x14e748,_0x5edf5b);{const _0x14807a=_0x5edf5b['children']['map'](_0x189ca6=>this['_getViewObj'](_0x189ca6));return new(Y[_0x5edf5b['type']]||_0x5e8a92)(_0x14e748,_0x5edf5b['name'],_0x5edf5b['attributes'],_0x14807a);}}['_getDiff'](_0x1c7650,_0x566733=null){const _0x5cc69f=this['repository']['getRevision'](_0x1c7650),_0x37cde4=_0x566733?this['repository']['getRevision'](_0x566733):null,_0x2f7be2=this['_getRevisionsRange'](_0x5cc69f,_0x37cde4),_0x552e7c=_0x2f7be2[_0x2f7be2['length']-0x1],_0x4fadde=new Map(),_0xf174dc={'model':{},'attributes':{},'changes':[]},_0x3e9189=new Set(),_0x145bfd=new Map();for(let _0x4272f2=_0x2f7be2['length']-0x1;_0x4272f2>=0x0;_0x4272f2--){const _0x3052b8=_0x2f7be2[_0x4272f2];for(const _0x186e2f of Object['keys'](_0x3052b8['diffData']))if(_0x3052b8['diffData'][_0x186e2f]['attachChange']){const _0x528217=_0x3052b8['diffData'][_0x186e2f]['attachChange'];_0x528217['isAttached']?(_0x3e9189['add'](_0x186e2f),_0x145bfd['has'](_0x186e2f)&&_0x145bfd['get'](_0x186e2f)['userId']==_0x528217['userId']?_0x145bfd['delete'](_0x186e2f):_0x145bfd['set'](_0x186e2f,_0x528217)):_0x145bfd['has'](_0x186e2f)?(_0x3e9189['delete'](_0x186e2f),_0x145bfd['delete'](_0x186e2f)):(_0x3e9189['add'](_0x186e2f),_0x145bfd['set'](_0x186e2f,_0x528217));}else _0x3e9189['add'](_0x186e2f);}for(const _0xf968b7 of _0x3e9189){const _0x451f76=_0x145bfd['has'](_0xf968b7)&&!_0x145bfd['get'](_0xf968b7)['isAttached'];let _0x441235=_0x451f76?_0x2f7be2['length']-0x1:0x0;const _0x2e7183=_0x451f76?-0x1:0x1;for(;_0x2f7be2[_0x441235];){const _0x2695e4=_0x2f7be2[_0x441235];if(_0x2695e4['diffData'][_0xf968b7]){const _0x58b9a6=_0x451f76?_0x2695e4['diffData'][_0xf968b7]['attributesBefore']:_0x2695e4['diffData'][_0xf968b7]['attributesAfter'];_0xf174dc['attributes'][_0xf968b7]=_0x58b9a6?_0x5c1065(_0x58b9a6):{};break;}_0x441235+=_0x2e7183;}}for(const _0x5f0f53 of _0x2f7be2){_0x5f0f53['model']={};for(const _0x31779a of _0x5f0f53['authors'])_0x4fadde['set'](_0x31779a['id'],_0x31779a);for(const _0x2dae64 of _0x3e9189){const _0x48b8bd=_0x5f0f53['diffData'][_0x2dae64]?_0x5f0f53['diffData'][_0x2dae64]['insertions']:'[]',_0x590167=_0x5f0f53['diffData'][_0x2dae64]?_0x5f0f53['diffData'][_0x2dae64]['deletions']:'[]';_0x5f0f53['model'][_0x2dae64]={'insertions':this['_makeModelFromViewString'](_0x48b8bd),'deletions':this['_makeModelFromViewString'](_0x590167)};}}for(const _0x1b9519 of _0x3e9189){let _0x59bd85=null,_0x16dc7b=0x0;const _0x3cc239=new Map(Array['from'](_0x5cc69f['model'][_0x1b9519]['insertions']['markers'])['filter'](([_0x1b48d5])=>!_0x1b48d5['startsWith']('revision:')));let _0xb1bcd=0x0;for(const _0x4b83f4 of _0x2f7be2){const _0x24475e=this['_makeTape'](_0x4b83f4['model'][_0x1b9519]['insertions']);_0x4b83f4==_0x5cc69f?(_0x59bd85=_0x24475e,_0x16dc7b=_0x59bd85['length'],_0x59bd85['forEach'](_0x17f1b9=>{_0x17f1b9['id']=_0xb1bcd++;}),this['_processTape'](_0x59bd85)):this['_markInsertions'](_0x59bd85,_0x24475e);const _0x56b30b=_0x59bd85['filter'](_0x25491e=>!_0x25491e['isAdded'])['map'](_0x5b0fe1=>_0x5b0fe1['id']);let _0x101069=0x0;const _0x1b25fb=this['_makeTape'](_0x4b83f4['model'][_0x1b9519]['deletions']);_0x1b25fb['forEach'](_0x49f057=>{_0x49f057['isRemoved']?_0x49f057['id']=_0x16dc7b++:_0x49f057['id']=_0x56b30b[_0x101069++];}),this['_processTape'](_0x1b25fb),this['_setDistance'](_0x59bd85,'isAdded'),this['_setDistance'](_0x1b25fb,'isRemoved'),_0x4b83f4==_0x5cc69f&&this['_markMarkers'](_0x59bd85,_0x3cc239),_0x59bd85=this['_joinTapes'](_0x59bd85,_0x1b25fb),this['_refreshStartEndIndex'](_0x59bd85),this['_setDistance'](_0x59bd85,'isRemoved');}_0x59bd85=_0x59bd85['filter'](_0x2d0516=>!(_0x2d0516['isAdded']&&_0x2d0516['isRemoved']));const _0x1d7b56=new Map(_0x552e7c['model'][_0x1b9519]['deletions']['markers']),_0x8c97c3=new Set(_0x3cc239['keys']());for(const _0x1a4312 of _0x1d7b56['keys']())_0x8c97c3['delete'](_0x1a4312);this['_markSuggestions'](_0x59bd85,_0x8c97c3),this['_fixObsoleteTags'](_0x59bd85),_0x59bd85=this['_removeMissingPairs'](_0x59bd85),_0x59bd85=this['_markMismatchedRemovedTags'](_0x59bd85),_0x59bd85=this['_removeUnsupportedChanges'](_0x59bd85);const {root:_0x167c03,changes:_0x538f32}=this['_makeModelFromTape'](_0x59bd85,_0x4fadde,_0x1b9519);_0xf174dc['model'][_0x1b9519]=_0x167c03;const _0x231f57=_0x145bfd['get'](_0x1b9519);if(_0x231f57){const _0x35eaa0=_0x4fadde['get'](_0x231f57['userId']),_0xcd785f=new r({'author':_0x35eaa0,'type':_0x231f57['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x1b9519});_0x538f32['unshift'](_0xcd785f),_0xf174dc['attributes'][_0x1b9519]['revisionHistoryAttachChange']=_0xcd785f['id'];}_0xf174dc['changes']=_0xf174dc['changes']['concat'](_0x538f32);}return _0xf174dc;}['_markMarkers'](_0x1dca78,_0x5f2e8f){for(let _0x278a46=0x0;_0x278a46<_0x1dca78['length'];_0x278a46++)for(const [_0xac720f,_0x4677c3]of _0x5f2e8f)_0x4677c3['start']['isEqual'](_0x1dca78[_0x278a46]['previousPosition'])&&_0x1dca78[_0x278a46]['markersStart']['push'](_0xac720f),_0x4677c3['end']['isEqual'](_0x1dca78[_0x278a46]['nextPosition'])&&_0x1dca78[_0x278a46]['markersEnd']['push'](_0xac720f);}['_joinTapes'](_0x968eb0,_0x5c865d){let _0x170277=[],_0x4af58c=0x0,_0x3aa1b4=0x0;for(;_0x4af58c<_0x968eb0['length']||_0x3aa1b4<_0x5c865d['length'];){const _0x4e3fa4=_0x968eb0[_0x4af58c]||{},_0x4d359f=_0x5c865d[_0x3aa1b4]||{};if(_0x4e3fa4['id']==_0x4d359f['id'])_0x4af58c++,_0x3aa1b4++,_0x170277['push'](_0x4e3fa4);else{if(_0x4d359f['isRemoved']&&_0x4e3fa4['isAdded']){const {commonTape:_0x4535c0,iEnd:_0x54c03e,jEnd:_0x547c64}=this['_threeWayMerge'](_0x968eb0,_0x4af58c,_0x5c865d,_0x3aa1b4);_0x170277=_0x170277['concat'](_0x4535c0),_0x4af58c=_0x54c03e,_0x3aa1b4=_0x547c64;}else _0x4d359f['isRemoved']?(_0x3aa1b4++,_0x170277['push'](_0x4d359f)):(_0x4af58c++,_0x170277['push'](_0x4e3fa4));}}return _0x170277;}['_markSuggestions'](_0x36d9c9,_0x46bd91){const _0x1d3ef9=[];for(let _0x3807d3=0x0;_0x3807d3<_0x36d9c9['length'];_0x3807d3++){for(let _0xb98f63=0x0;_0xb98f63<_0x36d9c9[_0x3807d3]['markersStart']['length'];_0xb98f63++){const _0x512980=_0x36d9c9[_0x3807d3]['markersStart'][_0xb98f63];if(!_0x46bd91['has'](_0x512980))continue;const {group:_0x1379ad,type:_0x23aae5,authorId:_0x2f8c20}=_0x417ecd(_0x512980);'revision-suggestion'!=_0x1379ad||'insertion'!=_0x23aae5&&'deletion'!=_0x23aae5||(_0x1d3ef9['unshift']({'type':_0x23aae5,'name':_0x512980,'userId':_0x2f8c20}),_0x36d9c9[_0x3807d3]['markersStart']['splice'](_0xb98f63,0x1),_0xb98f63--);}_0x3e1d40(_0x36d9c9[_0x3807d3]);for(let _0x21b67f=0x0;_0x21b67f<_0x36d9c9[_0x3807d3]['markersEnd']['length'];_0x21b67f++){const _0xfe7bad=_0x36d9c9[_0x3807d3]['markersEnd'][_0x21b67f];if(!_0x46bd91['has'](_0xfe7bad))continue;const {group:_0x4a1bd7,type:_0x1fb365}=_0x417ecd(_0xfe7bad);if('revision-suggestion'!=_0x4a1bd7||'insertion'!=_0x1fb365&&'deletion'!=_0x1fb365)continue;_0x36d9c9[_0x3807d3]['markersEnd']['splice'](_0x21b67f,0x1),_0x21b67f--;const _0x4b950c=_0x1d3ef9['findIndex'](_0x489c1a=>_0x489c1a['name']==_0xfe7bad);_0x4b950c>-0x1&&_0x1d3ef9['splice'](_0x4b950c,0x1);}}function _0x417ecd(_0x1d294c){const _0x4d1117=_0x1d294c['split'](':');return{'group':_0x4d1117[0x0],'type':_0x4d1117[0x1],'subType':_0x4d1117['length']>=0x5?_0x4d1117[0x2]:null,'id':_0x4d1117['length']<0x5?_0x4d1117[0x2]:_0x4d1117[0x3],'authorId':_0x4d1117['length']<0x5?_0x4d1117[0x3]:_0x4d1117[0x4],'markerCount':0x6==_0x4d1117['length']?_0x4d1117[0x5]:null};}function _0x3e1d40(_0x5e39ed){for(let _0x2503f8=0x0;_0x2503f8<_0x1d3ef9['length'];_0x2503f8++){if(_0x5e39ed['isAdded']&&'insertion'==_0x1d3ef9[_0x2503f8]['type'])return _0x5e39ed['isAddSuggestion']=_0x1d3ef9[_0x2503f8],void delete _0x5e39ed['isAdded'];if(!_0x5e39ed['isAdded']&&!_0x5e39ed['isRemoved']&&'deletion'==_0x1d3ef9[_0x2503f8]['type'])return void(_0x5e39ed['isRemoveSuggestion']=_0x1d3ef9[_0x2503f8]);}}}['_setDistance'](_0x22bca3,_0x2eb763){let _0x4a4167=0x0,_0x4b3a27=!0x1;const _0x5b8c54=new Map();for(const _0x2eacdc of _0x22bca3)_0x2eacdc[_0x2eb763]?_0x4b3a27&&(_0x4a4167++,_0x4b3a27=!0x1):(_0x4a4167++,_0x4b3a27=!0x0),_0x5b8c54['set'](_0x2eacdc['id'],_0x4a4167);for(let _0x3ec7e2=0x0;_0x3ec7e2<_0x22bca3['length'];_0x3ec7e2++){if('isRemoved'==_0x2eb763&&_0x22bca3[_0x3ec7e2]['isAdded']||'isAdded'==_0x2eb763&&_0x22bca3[_0x3ec7e2]['isRemoved'])continue;if('text'==_0x22bca3[_0x3ec7e2]['type']){_0x22bca3[_0x3ec7e2]['distance']=0x0;continue;}const _0x19340c=_0x5b8c54['get'](_0x22bca3[_0x3ec7e2]['pairId']),_0x1909af=_0x5b8c54['get'](_0x22bca3[_0x3ec7e2]['id']);_0x22bca3[_0x3ec7e2]['distance']=_0x19340c-_0x1909af;}}['_getRevisionsRange'](_0x36a5be,_0xee017e,_0x2952b9=!0x1){const _0x4a8dfe=[];let _0x36be51=this['repository']['getIndex'](_0x36a5be),_0x570e4c=this['repository']['getIndex'](_0xee017e);for(-0x1==_0x570e4c&&(_0x570e4c=this['repository']['_revisions']['length'],_0x2952b9=!0x1);_0x36be51<_0x570e4c;)_0x4a8dfe['push'](this['repository']['getRevision'](_0x36be51)),_0x36be51++;return _0x2952b9&&_0x4a8dfe['push'](this['repository']['getRevision'](_0x36be51)),_0x4a8dfe;}['_threeWayMerge'](_0xcb5338,_0x5cc250,_0x11ec38,_0x3dd615){const _0x1b14b8=this['editor']['model']['schema'];let _0x61672b=_0x5cc250;for(;_0xcb5338[_0x61672b]&&_0xcb5338[_0x61672b]['isAdded'];)_0x61672b++;let _0x55ac58=_0x3dd615;for(;_0x11ec38[_0x55ac58]&&_0x11ec38[_0x55ac58]['isRemoved'];)_0x55ac58++;_0x7c3ca1(_0xcb5338,_0x5cc250,_0x61672b),_0x7c3ca1(_0x11ec38,_0x3dd615,_0x55ac58);const _0x57ec1b=_0x11ec38['slice'](_0x3dd615,_0x55ac58)['concat'](_0xcb5338['slice'](_0x5cc250,_0x61672b));return _0x57ec1b['sort']((_0x2d8891,_0x2ba054)=>_0x2d8891['side']!=_0x2ba054['side']?_0x2d8891['side']-_0x2ba054['side']:_0x2d8891['level']!=_0x2ba054['level']?_0x2d8891['level']-_0x2ba054['level']:_0x2d8891['distance']!=_0x2ba054['distance']?_0x2ba054['distance']-_0x2d8891['distance']:!!_0x2d8891['isAdded']!=!!_0x2ba054['isAdded']?-0x1==_0x2d8891['side']||0x0==_0x2d8891['side']?_0x2d8891['isAdded']?-0x1:0x1:_0x2d8891['isAdded']?0x1:-0x1:_0x2d8891['index']-_0x2ba054['index']),{'commonTape':_0x57ec1b,'iEnd':_0x61672b,'jEnd':_0x55ac58};function _0x7c3ca1(_0x436360,_0x4d44b4,_0x462e74){let _0x3cda9f=-0x1,_0x530901=Number['POSITIVE_INFINITY'],_0x3aa980=!0x0;for(let _0x5451b2=_0x4d44b4;_0x5451b2<_0x462e74;_0x5451b2++)if(_0x1b14b8['isInline'](_0x436360[_0x5451b2]['item'])||(_0x3aa980=!0x1),_0x436360[_0x5451b2]['item']['startIndex']<_0x4d44b4&&(_0x3cda9f=_0x5451b2),_0x436360[_0x5451b2]['item']['endIndex']>=_0x462e74){_0x530901=_0x5451b2;break;}_0x3aa980&&(_0x3cda9f=_0x462e74-0x1);for(let _0x493516=_0x4d44b4;_0x493516<_0x462e74;_0x493516++)_0x436360[_0x493516]['side']=_0x493516<=_0x3cda9f?-0x1:_0x493516<_0x530901?0x0:0x1,_0x436360[_0x493516]['index']=_0x493516;let _0x2c94ac=0x0;for(let _0x3edf84=_0x4d44b4;_0x3edf84<=_0x3cda9f;_0x3edf84++)0x0==_0x436360[_0x3edf84]['distance']?_0x436360[_0x3edf84]['level']=_0x2c94ac:(_0x2c94ac++,_0x436360[_0x3edf84]['level']=_0x2c94ac,_0x2c94ac++);for(let _0x3e8362=_0x4d44b4;_0x3e8362<_0x462e74;_0x3e8362++)0x0==_0x436360[_0x3e8362]['side']&&(_0x436360[_0x3e8362]['level']=_0x2c94ac);_0x2c94ac=0x0;for(let _0xf7b0f4=_0x462e74-0x1;_0xf7b0f4>=_0x530901;_0xf7b0f4--)0x0==_0x436360[_0xf7b0f4]['distance']?_0x436360[_0xf7b0f4]['level']=_0x2c94ac:(_0x2c94ac--,_0x436360[_0xf7b0f4]['level']=_0x2c94ac,_0x2c94ac--);}}['_fixObsoleteTags'](_0x3a2f4c){const _0x23993e=new Map(),_0xbdd64f=this['editor']['model']['schema'];for(let _0x5dacfc=0x1;_0x5dacfc<_0x3a2f4c['length'];_0x5dacfc++){let _0x4dea50,_0x45f132,_0x3f703e;const _0x3dd335=_0x3a2f4c[_0x5dacfc],_0x4ddd50=_0x3a2f4c[_0x5dacfc-0x1];if('text'==_0x3dd335['type'])continue;if(_0x3dd335['type']!=_0x4ddd50['type'])continue;if(!_0xbdd64f['isBlock'](_0x4ddd50['item'])||_0xbdd64f['isLimit'](_0x4ddd50['item']))continue;if(!_0xbdd64f['isBlock'](_0x3dd335['item'])||_0xbdd64f['isLimit'](_0x3dd335['item']))continue;if((_0x3a2f4c[_0x5dacfc]['isAdded']||_0x3a2f4c[_0x5dacfc]['isAddSuggestion'])&&_0x3a2f4c[_0x5dacfc-0x1]['isRemoved'])_0x4dea50=_0x3a2f4c[_0x5dacfc],_0x45f132=_0x3a2f4c[_0x5dacfc-0x1],_0x3f703e=_0x5dacfc-0x1;else{if(!_0x3a2f4c[_0x5dacfc]['isRemoved']||!_0x3a2f4c[_0x5dacfc-0x1]['isAdded']&&!_0x3a2f4c[_0x5dacfc-0x1]['isAddSuggestion'])continue;_0x4dea50=_0x3a2f4c[_0x5dacfc-0x1],_0x45f132=_0x3a2f4c[_0x5dacfc],_0x3f703e=_0x5dacfc;}const _0x4f844a=_0x4dea50['level']==_0x45f132['level'],_0x3be9dd=Math['abs'](_0x4dea50['level'])<Math['abs'](_0x45f132['level'])&&0x0==_0x45f132['distance'];(_0x4f844a||_0x3be9dd)&&(_0x23993e['set'](_0x45f132['id'],_0x4dea50['id']),_0x3a2f4c['splice'](_0x3f703e,0x1),_0x5dacfc--,_0x4dea50['isAdded']=!0x1);}for(let _0x1b4d1b=0x0;_0x1b4d1b<_0x3a2f4c['length'];_0x1b4d1b++)_0x23993e['has'](_0x3a2f4c[_0x1b4d1b]['pairId'])&&(_0x3a2f4c[_0x1b4d1b]['pairId']=_0x23993e['get'](_0x3a2f4c[_0x1b4d1b]['pairId']));}['_removeMissingPairs'](_0x29c966){const _0x5e1b7f=new Set(_0x29c966['map'](_0x3ea374=>_0x3ea374['id']));for(let _0x181ca7=0x0;_0x181ca7<_0x29c966['length'];_0x181ca7++)_0x5e1b7f['has'](_0x29c966[_0x181ca7]['pairId'])||0x0==_0x29c966[_0x181ca7]['distance']||(_0x29c966[_0x181ca7]['isIncorrect']=!0x0);return _0x29c966['filter'](_0x18cd4b=>!_0x18cd4b['isIncorrect']);}['_markMismatchedRemovedTags'](_0x3108f0){const _0x7a4da6=new Set();for(let _0x21bf43=0x0;_0x21bf43<_0x3108f0['length'];_0x21bf43++){if(_0x7a4da6['has'](_0x3108f0[_0x21bf43]['id'])&&_0x3108f0[_0x21bf43]['isRemoved']&&(_0x3108f0[_0x21bf43]['isIncorrect']=!0x0),_0x3108f0[_0x21bf43]['isIncorrect'])continue;if(0x0==_0x3108f0[_0x21bf43]['distance'])continue;if('elementStart'!=_0x3108f0[_0x21bf43]['type'])continue;if(null==_0x3108f0[_0x21bf43]['pairId'])continue;let _0x38429d=_0x21bf43+0x1,_0x1b505c=0x0;for(;_0x3108f0[_0x38429d]['id']!=_0x3108f0[_0x21bf43]['pairId'];)'elementStart'==_0x3108f0[_0x38429d]['type']?_0x1b505c++:'elementEnd'==_0x3108f0[_0x38429d]['type']&&_0x1b505c--,_0x38429d++;if(0x0!=_0x1b505c){if(_0x3108f0[_0x21bf43]['isRemoved'])_0x3108f0[_0x21bf43]['isIncorrect']=!0x0;else{for(;_0x38429d!=_0x21bf43;)_0x3108f0[_0x38429d]['isRemoved']&&0x0!=_0x3108f0[_0x38429d]['distance']&&(_0x3108f0[_0x38429d]['isIncorrect']=!0x0,_0x7a4da6['add'](_0x3108f0[_0x38429d]['pairId'])),_0x38429d--;}}}return _0x3108f0['filter'](_0x489ca9=>!_0x489ca9['isIncorrect']);}['_removeUnsupportedChanges'](_0x45cebc){const _0x7defe8=this['editor']['model']['schema'];for(let _0x4a4206=0x0;_0x4a4206<_0x45cebc['length'];_0x4a4206++){if(!(_0x45cebc[_0x4a4206]['isAdded']||_0x45cebc[_0x4a4206]['isAddSuggestion']||_0x45cebc[_0x4a4206]['isRemoved']||_0x45cebc[_0x4a4206]['isRemoveSuggestion']))continue;if(0x0==_0x45cebc[_0x4a4206]['distance'])continue;const _0x47cc05=_0x45cebc[_0x4a4206]['item'];_0x7defe8['isBlock'](_0x47cc05)||_0x7defe8['isLimit'](_0x47cc05)||(_0x45cebc[_0x4a4206]['isAdded']&&delete _0x45cebc[_0x4a4206]['isAdded'],_0x45cebc[_0x4a4206]['isAddSuggestion']&&delete _0x45cebc[_0x4a4206]['isAddSuggestion'],_0x45cebc[_0x4a4206]['isRemoveSuggestion']&&delete _0x45cebc[_0x4a4206]['isRemoveSuggestion'],_0x45cebc[_0x4a4206]['isRemoved']&&(_0x45cebc[_0x4a4206]['isIncorrect']=!0x0));}return _0x45cebc['filter'](_0x1c8a9f=>!_0x1c8a9f['isIncorrect']);}['_makeModelFromTape'](_0x577ced,_0xd83286,_0x5f05bc){const _0x345196=new mt(),_0xc499a=[],_0x35ca09=new Map(),_0x55a888=this['editor']['model'],_0x24b691=_0x55a888['schema'],_0x3b14ad=[_0x345196],_0x567161={},_0x5dae4a={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x5a45a7=null;const _0x72e4d2=[0x0];for(let _0x362928=0x0;_0x362928<_0x577ced['length'];_0x362928++)if('elementStart'===_0x577ced[_0x362928]['type']){_0x577ced[_0x362928]['previousPosition']=_0x55a888['createPositionFromPath'](_0x345196,_0x72e4d2);const _0x14456c=new ft(_0x577ced[_0x362928]['item']['name'],_0x577ced[_0x362928]['item']['getAttributes']());_0x3b14ad[0x0]['_appendChild'](_0x14456c),_0x72e4d2['push'](0x0),_0x3b14ad['unshift'](_0x14456c),_0x577ced[_0x362928]['nextPosition']=_0x55a888['createPositionFromPath'](_0x345196,_0x72e4d2);}else'elementEnd'===_0x577ced[_0x362928]['type']?(_0x3b14ad['shift'](),_0x577ced[_0x362928]['previousPosition']=_0x55a888['createPositionFromPath'](_0x345196,_0x72e4d2),_0x72e4d2['pop'](),_0x72e4d2[_0x72e4d2['length']-0x1]++,_0x577ced[_0x362928]['nextPosition']=_0x55a888['createPositionFromPath'](_0x345196,_0x72e4d2)):(_0x577ced[_0x362928]['previousPosition']=_0x55a888['createPositionFromPath'](_0x345196,_0x72e4d2),_0x5a45a7?_0x5a45a7['_data']+=_0x577ced[_0x362928]['item']['data']:_0x5a45a7=new wt(_0x577ced[_0x362928]['item']['data'],_0x577ced[_0x362928]['item']['getAttributes']()),_0x577ced[_0x362928+0x1]&&'text'===_0x577ced[_0x362928+0x1]['type']&&_0x2524fd(_0x5a45a7,_0x577ced[_0x362928+0x1]['item'])||(_0x3b14ad[0x0]['_appendChild'](_0x5a45a7),_0x5a45a7=null),_0x72e4d2[_0x72e4d2['length']-0x1]+=_0x577ced[_0x362928]['item']['offsetSize'],_0x577ced[_0x362928]['nextPosition']=_0x55a888['createPositionFromPath'](_0x345196,_0x72e4d2));for(let _0x24a9c3=0x0;_0x24a9c3<_0x577ced['length'];_0x24a9c3++){const _0x35219c=_0x577ced[_0x24a9c3]['previousPosition'],_0xcb2d71=_0x577ced[_0x24a9c3]['nextPosition'];for(const _0x2b559b of _0x577ced[_0x24a9c3]['markersStart'])_0x35ca09['set'](_0x2b559b,{'start':_0x35219c,'end':null});_0x28891e('isRemoveSuggestion',_0x24a9c3,_0x35219c,_0xcb2d71),_0x28891e('isAddSuggestion',_0x24a9c3,_0x35219c,_0xcb2d71),_0x28891e('isRemoved',_0x24a9c3,_0x35219c,_0xcb2d71),_0x28891e('isAdded',_0x24a9c3,_0x35219c,_0xcb2d71);for(const _0x357ca7 of _0x577ced[_0x24a9c3]['markersEnd']){_0x35ca09['get'](_0x357ca7)['end']=_0xcb2d71;}}for(const [_0x5bb74c,_0x5e5740]of _0x35ca09){const _0x28cc1d=this['editor']['model']['createRange'](_0x5e5740['start'],_0x5e5740['end']);_0x345196['markers']['set'](_0x5bb74c,_0x28cc1d);}return _0xc499a['sort']((_0x4e2ddc,_0x1bb600)=>{const _0x52db2e=_0x345196['markers']['get']('revision:'+_0x4e2ddc['id']),_0x365bbb=_0x345196['markers']['get']('revision:'+_0x1bb600['id']);return _0x52db2e['start']['isBefore'](_0x365bbb['start'])?-0x1:_0x52db2e['start']['isAfter'](_0x365bbb['start'])?0x1:_0x52db2e['end']['isBefore'](_0x365bbb['end'])?-0x1:_0x52db2e['end']['isAfter'](_0x365bbb['end'])?0x1:'add'===_0x4e2ddc['type']?-0x1:0x1;}),{'root':_0x345196,'changes':_0xc499a};function _0x28891e(_0x3e211b,_0x299357,_0x29a9cc,_0x2fa9b0){const _0x24af8d=!!_0x577ced[_0x299357][_0x3e211b],_0x5e377e=_0x24af8d?_0x577ced[_0x299357][_0x3e211b]['userId']:null,_0x3726ec=_0x299357===_0x577ced['length']-0x1,_0x2e34ed=_0x5dae4a[_0x3e211b][0x0],_0x57502a=_0x24b691['isObject'](_0x577ced[_0x299357]['item']);!_0x567161[_0x3e211b]&&_0x24af8d?_0x567161[_0x3e211b]={'start':_0x29a9cc,'tapeItem':_0x577ced[_0x299357],'userId':_0x5e377e,'type':_0x3e211b}:_0x567161[_0x3e211b]&&!_0x24af8d?(_0x567161[_0x3e211b]['end']=_0x29a9cc,_0x36c138(_0x567161[_0x3e211b]),_0x567161[_0x3e211b]=null):_0x567161[_0x3e211b]&&_0x24af8d&&_0x567161[_0x3e211b]['userId']!==_0x5e377e&&(_0x567161[_0x3e211b]['end']=_0x29a9cc,_0x2e34ed&&_0x2e34ed['userId']===_0x567161[_0x3e211b]['userId']||_0x36c138(_0x567161[_0x3e211b]),_0x567161[_0x3e211b]={'start':_0x29a9cc,'tapeItem':_0x577ced[_0x299357],'userId':_0x5e377e,'type':_0x3e211b}),_0x567161[_0x3e211b]&&_0x57502a&&('elementStart'!==_0x577ced[_0x299357]['type']||_0x2e34ed&&_0x2e34ed['userId']===_0x5e377e||_0x5dae4a[_0x3e211b]['unshift']({'userId':_0x5e377e,'object':_0x577ced[_0x299357]['item'],'change':_0x567161[_0x3e211b]}),'elementEnd'===_0x577ced[_0x299357]['type']&&_0x2e34ed&&_0x2e34ed['object']===_0x577ced[_0x299357]['item']&&(_0x5dae4a[_0x3e211b]['shift'](),_0x567161[_0x3e211b]=_0x2e34ed['change'])),_0x567161[_0x3e211b]&&_0x3726ec&&(_0x567161[_0x3e211b]['end']=_0x2fa9b0,_0x36c138(_0x567161[_0x3e211b]),_0x567161[_0x3e211b]=null);}function _0x36c138({start:_0x14ea88,end:_0x2ae0d8,tapeItem:_0xdf7634,userId:_0x5949d9,type:_0x50bfd7}){const _0x1439e4=_0xdf7634['item'],_0x4c9cd0=_0x55a888['schema']['isBlock'](_0x1439e4)&&!_0x55a888['schema']['isLimit'](_0x1439e4),_0x575033=_0x14ea88['nodeAfter']==_0x2ae0d8['parent']&&_0x2ae0d8['isAtStart'];if(_0x4c9cd0&&_0x575033)return;const _0x548d08=_0x55a888['createRange'](_0x14ea88,_0x2ae0d8),_0x4408b2=_0xd83286['get'](_0x5949d9),_0x45f043=new r({'author':_0x4408b2,'type':'isAdded'==_0x50bfd7||'isAddSuggestion'==_0x50bfd7?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x50bfd7||'isRemoveSuggestion'==_0x50bfd7},'createdAt':new Date(),'rootName':_0x5f05bc});_0xc499a['push'](_0x45f043),_0x345196['markers']['set']('revision:'+_0x45f043['id'],_0x548d08);}function _0x2524fd(_0x549950,_0x26f0ad){const _0x4408be=_0x549950['getAttributes'](),_0x270bb2=_0x26f0ad['getAttributes']();for(const _0xc90832 of _0x4408be){if(_0xc90832[0x1]!==_0x26f0ad['getAttribute'](_0xc90832[0x0]))return!0x1;_0x270bb2['next']();}return _0x270bb2['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x523fc2=>{const _0x16b47e=_0x523fc2['markerName']['split'](':')[0x1],_0xa6800d=this['_getChangeFromId'](_0x16b47e);if(!_0xa6800d)return null;const _0x2ddbc4='add'==_0xa6800d['type']?'insertion':'deletion',_0x3f5a1a=['ck-suggestion-marker','ck-suggestion-marker-'+_0x2ddbc4];return _0xa6800d['data']['isSuggestion']&&_0x3f5a1a['push']('ck-suggestion-marker-'+_0x2ddbc4+'-new'),this['activeChange']==_0xa6800d&&_0x3f5a1a['push']('ck-suggestion-marker--active'),{'classes':_0x3f5a1a,'attributes':{'data-change-id':_0x16b47e}};}}),this['editor']['conversion']['for']('upcast')['add'](_0xdcff91=>{_0xdcff91['on']('element:pre',(_0x4958dd,_0x6598f,_0x1d4ff8)=>{const _0x16457b=_0x6598f['viewItem']['getChild'](0x0);if(!_0x16457b||!_0x16457b['is']('element','code'))return;if(!_0x1d4ff8['consumable']['consume'](_0x16457b,{'attributes':['vid_start','vid_end']}))return;const _0x448f87=_0x6598f['modelRange']['start']['nodeAfter'];_0x1d4ff8['writer']['setAttribute']('vid_start',_0x16457b['getAttribute']('vid_start'),_0x448f87),_0x1d4ff8['writer']['setAttribute']('vid_end',_0x16457b['getAttribute']('vid_end'),_0x448f87);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x2152ec=>{_0x2152ec['on']('element',(_0x3bad75,_0x5d4721,_0x3851a2)=>{if(!_0x3851a2['consumable']['consume'](_0x5d4721['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x5d4721['modelRange']['isCollapsed'])return;const _0x85069d=_0x5d4721['modelRange']['start']['nodeAfter'];_0x85069d['hasAttribute']('vid_start')||_0x85069d['hasAttribute']('vid')||(_0x3851a2['writer']['setAttribute']('vid_start',_0x5d4721['viewItem']['getAttribute']('vid_start'),_0x85069d),_0x3851a2['writer']['setAttribute']('vid_end',_0x5d4721['viewItem']['getAttribute']('vid_end'),_0x85069d));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x8af2c=>_0x8af2c['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0xbdedd6,[,_0x34168f])=>{['vid_start','vid_end','vid']['includes'](_0x34168f)&&(_0xbdedd6['return']=!0x0,_0xbdedd6['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x39a509=>{_0x39a509['on']('attribute:vid',(_0x1f0f48,_0x4c8915,_0x8ec413)=>{if('\x20'!=_0x4c8915['item']['data']||_0x4c8915['item']['parent']['maxOffset']>0x1)return;if(!_0x8ec413['consumable']['consume'](_0x4c8915['item'],_0x1f0f48['name']))return;const _0xa5b2ce=_0x8ec413['writer'],_0x312a20=_0x8ec413['mapper']['toViewRange'](_0x4c8915['range']);_0xa5b2ce['wrap'](_0x312a20,_0xa5b2ce['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x2969c7){const _0x546d9a=_0x2969c7['plugins']['get']('RevisionViewer');return(_0x5aa556,_0x24db3d,_0x1adf33)=>{const _0x919632=_0x24db3d['markerName']['split'](':')[0x1],_0x5806d1=_0x546d9a['_getChangeFromId'](_0x919632);if(!_0x5806d1)return null;const _0x429957='add'==_0x5806d1['type']?'split':'merge';if(!_0x1adf33['consumable']['test'](_0x24db3d['markerRange'],_0x5aa556['name']))return;const _0x1019c6=_0x24db3d['markerRange']['getWalker'](),_0x491081=_0x24db3d['markerRange']['start'],_0x563d8c=_0x2969c7['model']['schema'];let _0x1d3203=null,_0x725f83=null,_0x1235c1=!0x1,_0x3354bb=!0x1;for(const _0x27e7c5 of _0x1019c6){const _0x1a53f0=_0x27e7c5['item'];_0x1235c1=_0x1235c1||_0x563d8c['isContent'](_0x1a53f0);const _0x477c11=_0x1adf33['mapper']['toViewElement'](_0x1a53f0);if(_0x477c11&&_0x477c11['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x27e7c5['type']&&(_0x563d8c['isBlock'](_0x1a53f0)&&!_0x563d8c['isLimit'](_0x1a53f0)&&(_0x1a53f0['nextSibling']||_0x491081['isAtEnd']?_0x1d3203&&_0x1d3203['parent']==_0x1a53f0||(_0x1d3203=_0x1a53f0,_0x55b38e(_0x27e7c5['previousPosition']),_0x3354bb=!0x0):_0x725f83=_0x725f83||_0x27e7c5['previousPosition']));}function _0x55b38e(_0x301b6e){const _0x4c8177=_0x1adf33['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x429957}),_0x413ac0=_0x1adf33['mapper']['toViewPosition'](_0x301b6e);_0x5806d1['data']['isSuggestion']&&_0x1adf33['writer']['addClass']('ck-suggestion-marker-'+_0x429957+'-new',_0x4c8177),_0x546d9a['activeChange']==_0x5806d1&&_0x1adf33['writer']['addClass']('ck-suggestion-marker--active',_0x4c8177),_0x1adf33['writer']['insert'](_0x413ac0,_0x4c8177),_0x1adf33['mapper']['bindElementToMarker'](_0x4c8177,_0x24db3d['markerName']);}_0x1235c1||_0x3354bb||!_0x725f83||_0x55b38e(_0x725f83);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x507a08,_0x58ff0c,_0x278510)=>{const _0x55c7e0=_0x278510['mapper']['markerNameToElements'](_0x58ff0c['markerName']);if(_0x55c7e0){for(const _0x3d90a8 of _0x55c7e0)(_0x3d90a8['hasClass']('ck-suggestion-marker-split')||_0x3d90a8['hasClass']('ck-suggestion-marker-merge'))&&(_0x278510['mapper']['unbindElementFromMarkerName'](_0x3d90a8,_0x58ff0c['markerName']),_0x278510['writer']['remove'](_0x3d90a8));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x3461b9,_0x535eb3,_0x1f8f35)=>{const _0x5aefdf=_0x535eb3['markerName']['split'](':')[0x1],_0xac928a=this['_getChangeFromId'](_0x5aefdf);if(!_0xac928a)return null;const _0xffc21='add'==_0xac928a['type']?'split':'merge';if(_0x1f8f35['consumable']['test'](_0x535eb3['markerRange'],_0x3461b9['name']))for(const _0x4e7dfc of _0x535eb3['markerRange']['getItems']()){if(!_0x4e7dfc['is']('element','softBreak'))continue;const _0xcd2d5e=_0x1f8f35['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0xffc21}),_0x59ebc3=_0x1f8f35['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x4e7dfc));_0xac928a['data']['isSuggestion']&&_0x1f8f35['writer']['addClass']('ck-suggestion-marker-'+_0xffc21+'-new',_0xcd2d5e),this['activeChange']==_0xac928a&&_0x1f8f35['writer']['addClass']('ck-suggestion-marker--active',_0xcd2d5e),_0x1f8f35['writer']['insert'](_0x59ebc3,_0xcd2d5e),_0x1f8f35['mapper']['bindElementToMarker'](_0xcd2d5e,_0x535eb3['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x9a85eb=>{for(const _0x38b450 of this['editor']['model']['document']['getRootNames']()){const _0x29e228=this['editor']['model']['document']['getRoot'](_0x38b450),_0x42cb92=this['editor']['editing']['view']['document']['getRoot'](_0x38b450);if(_0x42cb92){const _0x281f8a=_0x29e228['getAttribute']('revisionHistoryAttachChange');if(_0x9a85eb['removeAttribute']('data-change-id',_0x42cb92),_0x9a85eb['removeClass']('ck-revision-history-root-add',_0x42cb92),_0x9a85eb['removeClass']('ck-revision-history-root-remove',_0x42cb92),_0x9a85eb['removeClass']('ck-revision-history-root--active',_0x42cb92),_0x281f8a){const _0x57ad35=this['_getChangeFromId'](_0x281f8a);if(!_0x57ad35)return null;_0x9a85eb['setAttribute']('data-change-id',_0x281f8a,_0x42cb92),_0x9a85eb['addClass']('ck-revision-history-root-'+_0x57ad35['type'],_0x42cb92),this['activeChange']==_0x57ad35&&_0x9a85eb['addClass']('ck-revision-history-root--active',_0x42cb92);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x5ab49d=>'revision-comment:'+_0x5ab49d,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x3ee180=>'revision-suggestion:'+_0x3ee180,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x49d6cf=>({'name':'suggestion:'+_0x49d6cf,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x43d66b=>{const _0x28f4a2=_0x43d66b['markerName']['split'](':')[0x1];return'insertion'!=_0x28f4a2&&'deletion'!=_0x28f4a2?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x28f4a2]};}}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:deletion',Z(this['editor'],'merge'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:insertion',Z(this['editor'],'split'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision-suggestion',(_0x28ae2c,_0x5c4a6a,_0x13a0ca)=>{const _0x21aa53=_0x13a0ca['mapper']['markerNameToElements'](_0x5c4a6a['markerName']);if(_0x21aa53){for(const _0xfba2ef of _0x21aa53)_0xfba2ef['is']('uiElement')&&(_0x13a0ca['mapper']['unbindElementFromMarkerName'](_0xfba2ef,_0x5c4a6a['markerName']),_0x13a0ca['writer']['remove'](_0xfba2ef));}},{'priority':'high'});}['_getChangeFromId'](_0x54b2e9){return this['_changeIdToChange']['get'](_0x54b2e9);}['_getViewForChange'](_0x85ea23){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new X(this['editor']['locale'],_0x85ea23),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x2dee03,_0x2ecb3f,_0xdc312,_0x41f53f)=>{_0x41f53f&&this['_balloon']['remove'](_0x41f53f),_0xdc312&&(this['_balloon']['add']({'view':_0xdc312,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x19876b=this['editor']['editing'],_0xaf81ac=this['_getChangeFromId'](_0xdc312['changeId']);let _0x32ff4d;if(_0xaf81ac['data']['isOnRoot']){const _0x4a0751=_0x19876b['view']['getDomRoot'](_0xaf81ac['rootName']);_0x32ff4d=Array['from'](_0x4a0751['getClientRects']());}else{const _0x3de605=this['editor']['model']['markers']['get']('revision:'+_0xdc312['changeId']);_0x32ff4d=Array['from'](_0x19876b['mapper']['markerNameToElements'](_0x3de605['name']))['map'](_0x51b963=>_0x19876b['view']['domConverter']['mapViewToDom'](_0x51b963))['map'](_0x1cfa7e=>Array['from'](_0x1cfa7e['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x32ff4d[0x0];return _0x32ff4d['find'](_0x5d0a23=>_0x5d0a23['top']-0x3<=this['_activeViewTarget']['y']&&_0x5d0a23['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x5d0a23['left']-0x3<=this['_activeViewTarget']['x']&&_0x5d0a23['right']+0x3>=this['_activeViewTarget']['x'])||_0x32ff4d[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x21a276,_0x3ee941,_0x24d2d3,_0x4135d9)=>{this['activeView']=_0x24d2d3?this['_getViewForChange'](_0x24d2d3):null,this['editor']['model']['change'](()=>{const _0x940aaa=this['editor']['editing'];_0x4135d9&&(_0x4135d9['data']['isOnRoot']?_0x940aaa['view']['change'](_0x367763=>{_0x367763['removeClass']('ck-revision-history-root--active',_0x940aaa['view']['document']['getRoot'](_0x4135d9['rootName']));}):_0x940aaa['reconvertMarker']('revision:'+_0x4135d9['id'])),_0x24d2d3&&(_0x24d2d3['data']['isOnRoot']?_0x940aaa['view']['change'](_0x5b00dc=>{_0x5b00dc['addClass']('ck-revision-history-root--active',_0x940aaa['view']['document']['getRoot'](_0x24d2d3['rootName']));}):_0x940aaa['reconvertMarker']('revision:'+_0x24d2d3['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0xb5a984,_0x3eb72f)=>{if(this['activeChange'])return;const _0x52b4cd=this['_findChangeIdFromDomTarget'](_0x3eb72f['target']),_0x468838=this['_changeIdToChange']['get'](_0x52b4cd);_0x468838?(this['_activeViewTarget']={'x':_0x3eb72f['domEvent']['x'],'y':_0x3eb72f['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x468838)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x8d80db,_0x51d857)=>{const _0x432acc=this['_findChangeIdFromDomTarget'](_0x51d857['target']),_0x3d0fce=this['_changeIdToChange']['get'](_0x432acc);_0x3d0fce?(this['_activeViewTarget']={'x':_0x51d857['domEvent']['x'],'y':_0x51d857['domEvent']['y']},_0x3d0fce===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x3d0fce):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x5a76d3){do{const _0x1147fd=_0x5a76d3['getAttribute']('data-change-id');if(_0x1147fd)return _0x1147fd;_0x5a76d3=_0x5a76d3['parent'];}while(_0x5a76d3);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x14ca56=>{for(const _0x375dd6 of this['editor']['model']['markers'])_0x14ca56['removeMarker'](_0x375dd6);});}}function Z(_0x2f8444,_0x172abd){return(_0x2d0770,_0x325dfe,_0x5803d1)=>{if(!_0x5803d1['consumable']['test'](_0x325dfe['markerRange'],_0x2d0770['name']))return;const _0x18d55d=_0x325dfe['markerRange']['getWalker'](),_0x3fa05f=_0x325dfe['markerRange']['start'],_0x323e5f=_0x2f8444['model']['schema'];let _0x2c38ee=null,_0x55a6da=null,_0x40c78a=!0x1,_0x53512c=!0x1;for(const _0x19cd90 of _0x18d55d){const _0x46077c=_0x19cd90['item'];_0x40c78a=_0x40c78a||_0x323e5f['isContent'](_0x46077c);const _0x21294c=_0x5803d1['mapper']['toViewElement'](_0x46077c);if(_0x21294c&&_0x21294c['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x19cd90['type']&&(_0x323e5f['isBlock'](_0x46077c)&&!_0x323e5f['isLimit'](_0x46077c)&&(_0x46077c['nextSibling']||_0x3fa05f['isAtEnd']?_0x2c38ee&&_0x2c38ee['parent']==_0x46077c||(_0x2c38ee=_0x46077c,_0x155a38(_0x19cd90['previousPosition']),_0x53512c=!0x0):_0x55a6da=_0x55a6da||_0x19cd90['previousPosition']));}function _0x155a38(_0x343355){const _0xad19c9=_0x5803d1['mapper']['toViewPosition'](_0x343355),_0x1c8719=_0x5803d1['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x172abd});_0x5803d1['writer']['insert'](_0xad19c9,_0x1c8719),_0x5803d1['mapper']['bindElementToMarker'](_0x1c8719,_0x325dfe['markerName']);}_0x40c78a||_0x53512c||!_0x55a6da||_0x155a38(_0x55a6da);};}class _t extends _0x3e7e3e{constructor(_0x312d8f){super(_0x312d8f);const _0x1d1a88=_0x312d8f['plugins']['get'](d);this['affectsData']=!0x1,this['listenTo'](_0x1d1a88,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x1d1a88,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x569887=this['editor'],_0x476f47=_0x569887['plugins']['get'](d),_0x1a2f83=_0x476f47['isReady']?_0x476f47['diff']['newRevisionId']:null;_0x569887['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x1a2f83);}['refresh'](){const {isReady:_0x1319a7,isEnabled:_0x2a9c6d,repository:_0x20d5e5,diff:_0x45b7b3}=this['editor']['plugins']['get'](d),_0x939606=_0x45b7b3&&_0x20d5e5['getLaterVisibleRevision'](_0x45b7b3['newRevisionId']);this['isEnabled']=_0x1319a7&&_0x2a9c6d&&Boolean(_0x939606);}}class yt extends _0x3e7e3e{['_step'];constructor(_0x32b1a2,{direction:_0x272e07}){super(_0x32b1a2);const _0x43eab0=_0x32b1a2['plugins']['get'](d);this['affectsData']=!0x1,this['_step']='forward'===_0x272e07?0x1:-0x1,this['listenTo'](_0x43eab0,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x43eab0,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x43eab0,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x15bca3=this['editor'],_0x31da52=_0x15bca3['plugins']['get'](d),{isNavigationMode:_0x141bc5,currentChangeNumber:_0x52313d}=_0x31da52;let _0x40e4d2;if(_0x31da52['activeChange']=_0x141bc5?_0x31da52['diff']['changes']['get'](_0x52313d+this['_step']):_0x31da52['diff']['changes']['first'],_0x31da52['activeChange']['data']['isOnRoot'])_0x40e4d2=_0x15bca3['editing']['view']['getDomRoot'](_0x31da52['activeChange']['rootName']);else{const _0x31b803=_0x15bca3['model']['markers']['get']('revision:'+_0x31da52['activeChange']['id']);_0x40e4d2=_0x1a0754(_0x15bca3['editing'],_0x31b803);}_0x3f35be({'target':_0x40e4d2,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x374fa1,currentChangeNumber:_0x3d0e06,numberOfChanges:_0x2be2a7,isReady:_0x5cedda,isEnabled:_0x4de2b1}=this['editor']['plugins']['get'](d);this['isEnabled']=!!(_0x4de2b1&&_0x5cedda&&_0x2be2a7)&&(!_0x374fa1||(0x1===this['_step']?_0x3d0e06<_0x2be2a7-0x1:_0x3d0e06>0x0));}}class di extends _0xc8540d{constructor(_0x132133){super(_0x132133);const _0x516d17=this['bindTemplate'],_0x3fc613=new _0x1a0086(_0x132133),_0x83a52b=new _0x1a0086(_0x132133);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',(_0xa43fbc,_0x14b32b)=>_0xa43fbc&&_0x14b32b>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x262ddb,_0x1bed5e,_0x4c4d8b,_0x8047b8)=>{if(!_0x262ddb)return m(_0x132133,'Loading...');if(!_0x4c4d8b)return m(_0x132133,'No\x20changes');const _0x11fe40=m(_0x132133,'NUMBER_OF_CHANGES',_0x4c4d8b);return _0x8047b8?m(_0x132133,'X_OF_Y_CHANGES',[_0x1bed5e+0x1,_0x4c4d8b]):_0x11fe40;}),_0x3fc613['set']({'label':m(_0x132133,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':'<svg\x20viewBox=\x220\x200\x2020\x2020\x22\x20xmlns=\x22http://www.w3.org/2000/svg\x22><path\x20d=\x22M16.435\x2014.494a.75.75\x200\x200\x200\x201.197-.899l-.067-.089-6.992-8a.75.75\x200\x200\x200-1.05-.078l-.079.078-7.008\x208a.75.75\x200\x200\x200\x201.049\x201.066l.08-.078\x206.442-7.354\x206.428\x207.354z\x22/></svg>\x0a'}),_0x83a52b['set']({'label':m(_0x132133,'Show\x20next\x20change'),'tooltip':!0x0,'icon':'<svg\x20viewBox=\x220\x200\x2020\x2020\x22\x20xmlns=\x22http://www.w3.org/2000/svg\x22><path\x20d=\x22M16.435\x205.506a.75.75\x200\x200\x201\x201.197.899l-.067.089-6.992\x208a.75.75\x200\x200\x201-1.05.078l-.079-.078-7.008-8a.75.75\x200\x200\x201\x201.049-1.066l.08.078\x206.442\x207.354\x206.428-7.354z\x22/></svg>\x0a'}),_0x3fc613['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x83a52b['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x3fc613['on']('execute',()=>this['fire']('execute','backward')),_0x83a52b['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',_0x516d17['if']('_isStatusLabelVisible','ck-hidden',_0x2fa881=>!_0x2fa881)]},'children':[{'text':_0x516d17['to']('isNavigationMode',_0x285521=>_0x285521?m(_0x132133,'EDIT_X_OF_Y_REVISIONS')+':\x20':m(_0x132133,'Total')+':\x20')}]},{'text':_0x516d17['to']('_statusText')}]},new _0x3a7535(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x3fc613,_0x83a52b]}]});}}const ce='ck-editor__editable__loading-overlay';class ae extends _0x1448f8{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x501e59=this['editor']['editing']['view'];_0x501e59['change'](_0x5ac132=>{for(const _0x3d6e3c of _0x501e59['document']['roots'])_0x5ac132['addClass'](ce,_0x3d6e3c);});}['hide'](){const _0x4ec0af=this['editor']['editing']['view'];_0x4ec0af['change'](_0x3e7231=>{for(const _0x220a2e of _0x4ec0af['document']['roots'])_0x3e7231['removeClass'](ce,_0x220a2e);});}}class g extends _0x1448f8{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[d,ae];}['init'](){const _0x54ced1=this['editor'],_0x5b539b=_0x54ced1['plugins']['get'](d),_0x5ab255=_0x54ced1['plugins']['get'](ae);_0x54ced1['ui']['componentFactory']['add']('exitToEditing',_0x242792=>{const _0x1a457c=new _0x1a0086(_0x242792);return _0x1a457c['set']({'label':m(_0x242792,'Back\x20to\x20editing'),'icon':_0x2c63e9['undo'],'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x1a457c,'execute',()=>{_0x54ced1['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x1a457c;}),_0x54ced1['ui']['componentFactory']['add']('restoreRevision',_0xaedb81=>{const _0x15e16b=new _0x1a0086(_0xaedb81);return _0x15e16b['set']({'label':m(_0xaedb81,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x15e16b['bind']('isEnabled')['to'](_0x54ced1['commands']['get']('restoreRevision')),this['listenTo'](_0x15e16b,'execute',()=>_0x54ced1['execute']('restoreRevision')),_0x15e16b;}),_0x54ced1['ui']['componentFactory']['add']('changesNavigation',_0x1ba72a=>{const _0x16f165=new di(_0x1ba72a),_0x5e13a8=_0x54ced1['commands']['get']('showPreviousChange'),_0x1c82a1=_0x54ced1['commands']['get']('showNextChange');return _0x16f165['bind']('isBackwardNavigationEnabled')['to'](_0x5e13a8,'isEnabled'),_0x16f165['bind']('isForwardNavigationEnabled')['to'](_0x1c82a1,'isEnabled'),_0x16f165['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x5b539b),this['listenTo'](_0x16f165,'execute',(_0x390ec1,_0x4c077b)=>{_0x54ced1['execute']('forward'===_0x4c077b?'showNextChange':'showPreviousChange');}),_0x16f165;}),_0x5ab255['show'](),_0x5b539b['on']('change:isReady',(_0x3c3267,_0xb2bf61,_0x1bbd29)=>{_0x1bbd29?_0x5ab255['hide']():_0x5ab255['show']();});}}class pt extends nt{['_resizeObserver']=null;constructor(_0x14c98a,_0x55e088){super(_0x14c98a,_0x55e088);const _0x6f8e9e=this['bindTemplate'];this['set']({'label':m(_0x14c98a,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=m(_0x14c98a,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x6f8e9e['to']('_tooltipString'),'data-cke-tooltip-position':'s','data-cke-tooltip-class':'ck-tooltip_multi-line'}});}['render'](){super['render'](),this['_resizeObserver']=new at(this['fieldView']['element'],()=>this['_updateTooltipText']()),this['listenTo'](this['fieldView'],'input',()=>this['_updateTooltipText']());}['destroy'](){super['destroy'](),this['_resizeObserver']&&this['_resizeObserver']['destroy']();}['_updateTooltipText'](){const _0x3a8f6f=this['fieldView']['element'];this['_tooltipString']=_0x3a8f6f['scrollWidth']>_0x3a8f6f['clientWidth']&&_0x3a8f6f['value']||'';}}class ti extends _0xc8540d{constructor(_0x152431,_0x532507,_0x5377bf){super(_0x152431);const _0x4663b0=new _0x14e8d9();_0x4663b0['set']({'content':'<svg\x20viewBox=\x220\x200\x2011\x2010\x22\x20xmlns=\x22http://www.w3.org/2000/svg\x22\x20xmlns:xlink=\x22http://www.w3.org/1999/xlink\x22><path\x20d=\x22M5.5\x205C8.538\x205\x2011\x207.015\x2011\x209.5c0\x20.17-.011.336-.034.5H.034A3.732\x203.732\x200\x200\x201\x200\x209.5C0\x207.015\x202.462\x205\x205.5\x205zm0-5a2.5\x202.5\x200\x201\x201\x200\x205\x202.5\x202.5\x200\x200\x201\x200-5z\x22\x20/></svg>\x0a','viewBox':'0\x200\x2011\x2010'});const _0x7d3216=['ck','ck-revision-history-sidebar__revision-author'];_0x5377bf&&_0x7d3216['push']('ck-revision-history-sidebar__revision-author_creator');const _0x58e6fd=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':m(_0x152431,_0x5377bf?'Revision\x20creator':'Revision\x20author')},'children':[_0x4663b0,_0x532507['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x7d3216},'children':_0x58e6fd});}}function ni(_0x1549da,_0x2774fa){const _0x4dbee2=_0x1549da['bindTemplate'],_0x52ad01=_0x1549da['locale'],_0x4ffba6=_0x534184(_0x52ad01);_0x4ffba6['panelPosition']='sw';const _0x14b8f6=function(_0xb69f08,_0x4dccea){const _0x317769=function(_0x46b1f1,_0xb2099d){const _0x105d99=_0x46b1f1['locale'],_0x4e1bad={'Compare\x20against\x20selected':m(_0x105d99,'Compare\x20against\x20selected'),'Name\x20this\x20revision':m(_0x105d99,'Name\x20this\x20revision'),'Restore\x20this\x20revision':m(_0x105d99,'Restore\x20this\x20revision')};return _0xb2099d['map'](_0x2150c3=>{const _0x4d784c=_0x4e1bad[_0x2150c3['name']];return _0x4d784c&&_0x4d784c!==_0x2150c3['name']&&(_0x2150c3['name']=_0x4d784c),_0x2150c3;});}(_0xb69f08,_0x4dccea),_0x16e8c6=new _0x47adf8();for(const _0x2c1d58 of _0x317769){const _0x4fdd2b={'type':'button','model':new to({'label':_0x2c1d58['name'],'class':_0x2c1d58['class'],'withText':!0x0,'role':'menuitem','_action':_0x2c1d58['action']})};_0x4fdd2b['model']['bind']('isEnabled')['to'](_0xb69f08,'isActionsDropdownOpen',_0x4dbc1a=>'function'!=typeof _0x2c1d58['isEnabled']||(!_0x4dbc1a||_0x2c1d58['isEnabled'](_0xb69f08))),_0x16e8c6['add'](_0x4fdd2b);}return _0x16e8c6;}(_0x1549da,_0x2774fa);return _0x1549da['bind']('isActionsDropdownOpen')['to'](_0x4ffba6,'isOpen'),_0x4ffba6['buttonView']['set']({'label':m(_0x52ad01,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x2c63e9['threeVerticalDots']}),_0x4ffba6['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x4dbee2['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x4dbee2['to'](_0x546d45=>_0x546d45['stopPropagation']())}}),_0x4ffba6['on']('execute',_0x4ef0c2=>{_0x1549da['isReady']&&'function'==typeof _0x4ef0c2['source']['_action']&&_0x4ef0c2['source']['_action'](_0x1549da);}),_0x59996c(_0x4ffba6,_0x14b8f6,{'role':'menu'}),_0x4ffba6['listenTo'](_0x1549da,'change:isActionsDropdownOpen',(_0x38edc2,_0x4660fa,_0x36f1bc)=>{if(_0x36f1bc)for(const _0x5cdf76 of _0x4ffba6['listView']['items']){const _0x52eb9d=_0x5cdf76['children']['first'],_0x199589=_0x2774fa['find'](_0x443eee=>_0x443eee['action']===_0x52eb9d['_action'])['isVisible'];_0x5cdf76['isVisible']=void 0x0===_0x199589||_0x199589(_0x1549da);}}),_0x4ffba6;}class ai extends/* #__PURE__ -- @preserve */
26
- _0x3f483e(_0xc8540d){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x1f4790,_0x18c660,_0x92314a,_0x513fcb){super(_0x1f4790);const _0x5ee7c5=this['bindTemplate'],_0x121a2c=function(_0x533457,_0x19409c){const _0x30d777=Array['from'](_0x19409c['authors'])['filter'](_0x398cb9=>_0x398cb9!=_0x19409c['creator']);return _0x19409c['creator']&&_0x30d777['unshift'](_0x19409c['creator']),_0x30d777['map'](_0x2c0e20=>new ti(_0x533457,_0x2c0e20,_0x2c0e20==_0x19409c['creator']));}(_0x1f4790,_0x18c660);this['id']=_0x18c660['id'],this['_revision']=_0x18c660,this['_requireRevisionName']=_0x513fcb,this['bind']('name','createdAt')['to'](_0x18c660),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x9a8116=>{return _0x3fce9d=_0x1f4790['uiLanguage'],(_0x4806f5=_0x9a8116)['toLocaleDateString'](_0x3fce9d,{'month':'long','day':'numeric'})+',\x20'+_0x4806f5['toLocaleTimeString'](_0x3fce9d,{'hour':'numeric','minute':'numeric'});var _0x3fce9d,_0x4806f5;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new pt(_0x1f4790,_0xca8177),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x1efcbf=>_0x1efcbf||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x41a063,_0x4e1df9)=>_0x41a063&&_0x4e1df9),this['revisionActionsView']=_0x92314a&&_0x92314a['length']?ni(this,_0x92314a):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x5ee7c5['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x5ee7c5['if']('isEnabled','ck-disabled',_0x36715e=>!_0x36715e),_0x5ee7c5['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x5ee7c5['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x5ee7c5['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':_0x5ee7c5['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':_0x121a2c}]},this['revisionActionsView']],'on':{'click':_0x5ee7c5['to'](_0x92ee98=>{_0x92ee98['srcElement']['closest']('.ck-thread__remove-confirm')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0xc7a6a0=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0xc7a6a0,'change',()=>{this['_requireRevisionName']&&!_0xc7a6a0['value']||this['fire']('setName',{'id':this['id'],'name':_0xc7a6a0['value']}),_0xc7a6a0['value']||(_0xc7a6a0['value']=this['name']?this['name']:this['_createdAtFormatted']);});}['select'](){this['isSelected']=!0x0;}['deselect'](){this['isSelected']=!0x1;}['highlight'](){this['isHighlighted']=!0x0;}['unhighlight'](){this['isHighlighted']=!0x1;}}function mi(_0x5c513d,_0x333d11){const _0x23ff5e=_0x3a4a5a['fromJSDate'](_0x5c513d)['setLocale'](_0x333d11),_0x18237a=_0x3a4a5a['local'](),_0x4cabbf=_0x18237a['minus']({'days':0x1})['startOf']('day');let _0xee4eff,_0x47ee91;return _0x23ff5e['hasSame'](_0x18237a,'day')?(_0xee4eff=_0x23ff5e['startOf']('day')['toJSDate'](),_0x47ee91=_0x23ff5e['toRelativeCalendar']()):_0x23ff5e['hasSame'](_0x4cabbf,'day')?(_0xee4eff=_0x4cabbf['toJSDate'](),_0x47ee91=_0x23ff5e['toRelativeCalendar']()):_0x23ff5e['hasSame'](_0x18237a,'week')?(_0xee4eff=_0x23ff5e['startOf']('week')['toJSDate'](),_0x47ee91=_0x23ff5e['weekdayLong']||''):_0x23ff5e['hasSame'](_0x18237a,'year')?(_0xee4eff=_0x23ff5e['startOf']('month')['toJSDate'](),_0x47ee91=_0x23ff5e['monthLong']||''):(_0xee4eff=_0x23ff5e['startOf']('year')['toJSDate'](),_0x47ee91=String(_0x23ff5e['year'])),{'startDate':_0xee4eff,'localizedPeriodName':_0x47ee91};}class vi extends _0xc8540d{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0xbba2b,_0x3d6e2f,_0x3e0cff,_0x5c0373){super(_0xbba2b);const _0x9c099=mi(_0x3d6e2f,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x3d6e2f,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x3e0cff,this['_requireRevisionName']=_0x5c0373,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':_0x9c099}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x32d5df){const _0x383fc5=new ai(this['locale'],_0x32d5df,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x383fc5);}['removeRevision'](_0x3c6c13){const _0x409a51=this['revisionViews']['find'](_0x558cb6=>_0x558cb6['id']===_0x3c6c13['id']);this['revisionViews']['remove'](_0x409a51);}}class as extends _0xc8540d{constructor(_0x4ec406){super(_0x4ec406);const _0x2aa109=new _0x14e8d9();_0x2aa109['content']=_0x2c63e9['history'],this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x2aa109,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[m(_0x4ec406,'Revision\x20history')]}]});}}class li extends _0xc8540d{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x1d5c64,_0x4ddf30,_0x220652,_0x4424d3){super(_0x1d5c64);const _0x740885=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x4ddf30,this['_revisionActions']=_0x220652,this['_requireRevisionName']=_0x4424d3,this['on']('select',(_0x2f1832,_0x4ed4e3)=>{this['fire']('revisionSelected',_0x4ed4e3);}),this['on']('setName',(_0x144a2e,_0xcb0a4e)=>{this['fire']('revisionSetName',_0xcb0a4e);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new as(_0x1d5c64),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x740885['if']('isEnabled','ck-disabled',_0x20d975=>!_0x20d975)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x278e5a of this['_revisions'])this['_addRevision'](_0x278e5a);this['_revisions']['on']('add',(_0xda843a,_0x98cfd9)=>{this['_addRevision'](_0x98cfd9);}),this['_revisions']['on']('remove',(_0x47bc42,_0x129e3f)=>{this['_removeRevision'](_0x129e3f);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x3ef8d4=>_0x3ef8d4['revisionViews']['map'](_0x17e707=>_0x17e707))['flat']();}['selectRevision'](_0x57d590){for(const _0x1fd05b of this['revisionViews'])_0x57d590&&_0x57d590['id']===_0x1fd05b['id']?_0x1fd05b['select']():_0x1fd05b['deselect']();}['highlightRevisions'](_0x5982bb){for(const _0x200a5d of this['revisionViews'])_0x5982bb['some'](({id:_0x14cfd7})=>_0x14cfd7===_0x200a5d['id'])?_0x200a5d['highlight']():_0x200a5d['unhighlight']();}['_addRevision'](_0x3ce9c0){const _0x586c98=mi(_0x3ce9c0['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x489df8=this['timePeriodViews']['get'](0x0);_0x489df8&&_0x489df8['startDate']['getTime']()===_0x586c98['getTime']()||(_0x489df8=new vi(this['locale'],_0x586c98,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x489df8)),_0x489df8['addRevision'](_0x3ce9c0);}['_removeRevision'](_0x55ac97){const _0x5901d0=mi(_0x55ac97['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x5901d0)['removeRevision'](_0x55ac97);}['_getTimePeriodViewByStartDate'](_0x276cce){return this['timePeriodViews']['find'](_0x2236e4=>_0x2236e4['startDate']['getTime']()===_0x276cce['getTime']());}}class w extends _0x1448f8{['_revisionViewer'];['_revisionsRepository'];['_sidebarView'];static ['defaultRevisionActions']=/* #__PURE__ -- @preserve */
23
+ import{ObservableMixin as _0x12c76e,uid as _0x1fa053,Collection as _0xccc836,logWarning as _0x1324f1,FocusTracker as _0x1b3465,KeystrokeHandler as _0x220579,scrollViewportToShowTarget as _0x1f4042,ResizeObserver as at,ElementReplacer as ht,CKEditorError as _0x38454d}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x3ec8e3,set as _0x1ab114,unset as _0x5c1ec0,isEqual as _0xba09d3}from'lodash-es';import{Plugin as _0x50f6d6,PendingActions as _0x56e351,icons as _0x5f52da,Command as _0x468141,ElementApiMixin as it,Editor as tt}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x191bf9,getMarkerDomElement as _0x263dcc,ConfirmMixin as _0x2bf354,sanitizeEditorConfig as _0x174262}from'ckeditor5-collaboration/dist/index.js';import{ViewDocumentFragment as _0x4c4bb9,Element as ft,Range as vt,ViewUIElement as _0x927dea,ViewRawElement as _0x23e731,ViewEmptyElement as _0x30b150,ViewAttributeElement as _0x47add3,ViewContainerElement as _0x290b4f,Position as gt,ViewText as _0x601889,ViewElement as _0x38a4ac,DocumentFragment as mt,Text as wt}from'@ckeditor/ckeditor5-engine/dist/index.js';import{View as _0x3e310e,injectCssTransitionDisabler as ts,submitHandler as _0x4f23d5,LabeledFieldView as nt,createLabeledInputText as _0x4aa70e,createDropdown as _0x1ffeb1,ListView as te,ListItemView as _0xd41698,ButtonView as _0x5baaae,MenuBarMenuView as _0x8b235b,MenuBarMenuListView as _0x239d23,MenuBarMenuListItemView as _0x3a50f7,MenuBarMenuListItemButtonView as _0x32f567,ContextualBalloon as _0x570100,ToolbarSeparatorView as _0xa8182f,IconView as _0x47f78e,addListToDropdown as _0x57676b,ViewModel as to,EditorUI as st,normalizeToolbarConfig as ot,BoxedEditorUIView as ct,StickyPanelView as ut,ToolbarView as lt,InlineEditableUIView as dt}from'@ckeditor/ckeditor5-ui/dist/index.js';import{DateTime as _0x586337}from'luxon';class a extends/* #__PURE__ -- @preserve */
24
+ _0x12c76e(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x8086e){super(),this['id']=_0x8086e['id']||_0x1fa053(),this['creator']=_0x8086e['creator']||null,this['authors']=_0x8086e['authors']||[],this['diffData']=_0x8086e['diffData']||null,this['toVersion']=_0x8086e['toVersion']||0x0,this['fromVersion']=_0x8086e['fromVersion']||0x0,this['set']('name',_0x8086e['name']||''),this['set']('createdAt',_0x8086e['createdAt']||new Date()),this['set']('attributes',_0x8086e['attributes']||{});}['setName'](_0x429c9a){this['_update']({'name':_0x429c9a});}['setAttribute'](_0x140680,_0x445b14){const _0x3a44de=_0x3ec8e3(this['attributes']);_0x1ab114(_0x3a44de,_0x140680,_0x445b14),this['_update']({'attributes':_0x3a44de});}['removeAttribute'](_0x33e6e2){const _0x4df9b1=_0x3ec8e3(this['attributes']);_0x5c1ec0(_0x4df9b1,_0x33e6e2),this['_update']({'attributes':_0x4df9b1});}['_update'](_0x4892a2,_0x2c8323=!0x1){let _0xe0668=!0x1;const _0x5e37cb={'id':this['id']},_0x20a595=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x3a33c5 of _0x20a595){const _0x13d59b=_0x4892a2[_0x3a33c5];void 0x0!==_0x13d59b&&_0x13d59b!==this[_0x3a33c5]&&(this[_0x3a33c5]=_0x13d59b,_0x5e37cb[_0x3a33c5]=_0x13d59b,_0xe0668=!0x0);}_0xe0668&&(_0x5e37cb['authors']&&(_0x5e37cb['authorsIds']=_0x5e37cb['authors']['map'](_0x37dccb=>_0x37dccb['id']),delete _0x5e37cb['authors']),this['fire']('_update',_0x5e37cb,_0x2c8323));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x18dc6d=>_0x18dc6d['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class j extends _0x50f6d6{['_revisions'];static get['requires'](){return[_0x191bf9];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x53dc69){super(_0x53dc69),this['_revisions']=new _0xccc836();}['afterInit'](){!async function(_0xc0b19){const _0x54221e=_0x2cc4d3([0x43,0x68,0x34,0x48,0x6f,0x64,0x4f,0x51,0x4a,0x4c,0x7a,0x38,0x63,0x37,0x46,0x66,0x39,0x72,0x6a,0x76,0x75,0x52,0x47,0x71,0x4d,0x31,0x41,0x6b,0x45,0x69,0x5a,0x55,0x54,0x35,0x67,0x6d,0x4e,0x59,0x6c,0x30,0x42,0x79,0x70,0x49,0x4b,0x44,0x57,0x73,0x36,0x6e,0x77,0x74,0x78,0x33,0x50,0x62,0x61,0x56,0x32,0x58,0x53,0x65]),_0x332c52=0xeb829,_0x2d8902=0x1f8ae2c5,_0x1384cc=0x1f8dbc9d^_0x2d8902,_0x9b5f0c=window[_0x2cc4d3([0x44,0x61,0x74,0x65])][_0x2cc4d3([0x6e,0x6f,0x77])](),_0x5a307c=_0xc0b19[_0x2cc4d3([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x481dcb=new window[(_0x2cc4d3([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x54cce8=>{_0x5a307c[_0x2cc4d3([0x6f,0x6e,0x63,0x65])](_0x2cc4d3([0x72,0x65,0x61,0x64,0x79]),_0x54cce8);}),_0x5593a6={[_0x2cc4d3([0x6b,0x74,0x79])]:_0x2cc4d3([0x45,0x43]),[_0x2cc4d3([0x75,0x73,0x65])]:_0x2cc4d3([0x73,0x69,0x67]),[_0x2cc4d3([0x63,0x72,0x76])]:_0x2cc4d3([0x50,0x2d,0x32,0x35,0x36]),[_0x2cc4d3([0x78])]:_0x2cc4d3([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]),[_0x2cc4d3([0x79])]:_0x2cc4d3([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]),[_0x2cc4d3([0x61,0x6c,0x67])]:_0x2cc4d3([0x45,0x53,0x32,0x35,0x36])},_0x4e5950=_0x5a307c[_0x2cc4d3([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x2cc4d3([0x67,0x65,0x74])](_0x2cc4d3([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x31ead6(){let _0x24c22a,_0x2e58e3=null,_0x2776d3=null;try{if(_0x4e5950==_0x2cc4d3([0x47,0x50,0x4c]))return _0x2cc4d3([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x24c22a=_0xfaf91b(),!_0x24c22a)return _0x2cc4d3([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x24c22a[_0x2cc4d3([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x2776d3=_0x520f4c(_0x24c22a[_0x2cc4d3([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x24c22a[_0x2cc4d3([0x6a,0x74,0x69])])),await _0x125424()?_0x42ad5a()?_0xfe24ba()?_0x2cc4d3([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x27f226()?(_0x24c22a[_0x2cc4d3([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x2cc4d3([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x2e58e3=_0x5201b6(_0x2cc4d3([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x24c22a[_0x2cc4d3([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x2cc4d3([0x74,0x72,0x69,0x61,0x6c])&&(_0x2e58e3=_0x5201b6(_0x2cc4d3([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x232b1a()):_0x2cc4d3([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x2cc4d3([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x2cc4d3([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch(_0x53f25f){return _0x2cc4d3([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0xfe24ba(){const _0x16d073=[_0x2cc4d3([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x2cc4d3([0x74,0x72,0x69,0x61,0x6c])][_0x2cc4d3([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x24c22a[_0x2cc4d3([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x9b5f0c/0x3e8:0xe10*_0x1384cc;return _0x24c22a[_0x2cc4d3([0x65,0x78,0x70])]<_0x16d073;}function _0x42ad5a(){const _0x4136a3=_0x24c22a[_0x2cc4d3([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x4136a3)return!0x1;if(_0x4136a3[_0x2cc4d3([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x2cc4d3([0x2a])))return!0x0;if(_0x4136a3[_0x2cc4d3([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x2cc4d3([0x52,0x48])))return!0x0;if(_0x4136a3[_0x2cc4d3([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x2cc4d3([0x52,0x52,0x48]))){if(_0x284955())return!0x0;if(_0x2bd92b()||_0x359e01())return!0x0;}return!0x1;}function _0x27f226(){const _0x2d5a4a=_0x24c22a[_0x2cc4d3([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x2d5a4a||0x0==_0x2d5a4a[_0x2cc4d3([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x470118}=new URL(window[_0x2cc4d3([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x2d5a4a[_0x2cc4d3([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x470118))return!0x0;const _0x1a8578=_0x470118[_0x2cc4d3([0x73,0x70,0x6c,0x69,0x74])](_0x2cc4d3([0x2e]));return _0x2d5a4a[_0x2cc4d3([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x3eaee0=>_0x3eaee0[_0x2cc4d3([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x2cc4d3([0x2a])))[_0x2cc4d3([0x6d,0x61,0x70])](_0x387277=>_0x387277[_0x2cc4d3([0x73,0x70,0x6c,0x69,0x74])](_0x2cc4d3([0x2e])))[_0x2cc4d3([0x73,0x6f,0x6d,0x65])](_0x57be0e=>_0x1a8578[_0x2cc4d3([0x65,0x76,0x65,0x72,0x79])]((_0x56138d,_0x554a31)=>_0x57be0e[_0x554a31]===_0x56138d||_0x57be0e[_0x554a31]===_0x2cc4d3([0x2a])));}function _0x232b1a(){return _0x2e58e3&&_0x2776d3?new window[(_0x2cc4d3([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x30fced,_0x4af064)=>{_0x2e58e3[_0x2cc4d3([0x74,0x68,0x65,0x6e])](_0x30fced,_0x4af064),_0x2776d3[_0x2cc4d3([0x74,0x68,0x65,0x6e])](_0x2c54f1=>{_0x2c54f1!=_0x2cc4d3([0x56,0x61,0x6c,0x69,0x64])&&_0x30fced(_0x2c54f1);},_0x4af064);}):_0x2e58e3||_0x2776d3||_0x2cc4d3([0x56,0x61,0x6c,0x69,0x64]);}}function _0x520f4c(_0x141db8,_0x13c16b){return new window[(_0x2cc4d3([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x4da747=>{if(_0x460fc5())return _0x4da747(_0x2cc4d3([0x56,0x61,0x6c,0x69,0x64]));_0x2932ba(),_0x5a307c[_0x2cc4d3([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x2cc4d3([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x3ae24c=!0x1;const _0x40d0e6=_0x1fa053();function _0x9bffe3(_0x320103){return!!_0x320103&&(typeof _0x320103===_0x2cc4d3([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x320103===_0x2cc4d3([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x320103[_0x2cc4d3([0x74,0x68,0x65,0x6e])]===_0x2cc4d3([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x320103[_0x2cc4d3([0x63,0x61,0x74,0x63,0x68])]===_0x2cc4d3([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x5885be(_0x5cc115){_0x815e57(_0x5cc115)[_0x2cc4d3([0x74,0x68,0x65,0x6e])](_0x521986=>{if(!_0x521986||_0x521986[_0x2cc4d3([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x2cc4d3([0x6f,0x6b]))return _0x2cc4d3([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x49070a(_0x4858d5(_0x40d0e6+_0x13c16b))!=_0x521986[_0x2cc4d3([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x2cc4d3([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x2cc4d3([0x56,0x61,0x6c,0x69,0x64]);})[_0x2cc4d3([0x74,0x68,0x65,0x6e])](_0xc4f898=>(_0x572f94(),_0xc4f898),()=>{const _0x3fc6cd=_0xa61d60();return null==_0x3fc6cd?(_0x572f94(),_0x2cc4d3([0x56,0x61,0x6c,0x69,0x64])):_0x2cc4d3(_0x9b5f0c-_0x3fc6cd>(0x3b8666c5^_0x2d8902)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x2cc4d3([0x74,0x68,0x65,0x6e])](_0x4da747)[_0x2cc4d3([0x63,0x61,0x74,0x63,0x68])](()=>{_0x4da747(_0x2cc4d3([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x3d8e6f=0x1fbc0c45^_0x2d8902;function _0x572f94(){const _0xa04a4a=_0x2cc4d3([0x6c,0x6c,0x63,0x74,0x2d])+_0x49070a(_0x4858d5(_0x141db8)),_0xe05680=_0x420b3f(_0x49070a(window[_0x2cc4d3([0x4d,0x61,0x74,0x68])][_0x2cc4d3([0x63,0x65,0x69,0x6c])](_0x9b5f0c/_0x3d8e6f)));window[_0x2cc4d3([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x2cc4d3([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0xa04a4a,_0xe05680);}function _0xa61d60(){const _0x47c57d=_0x2cc4d3([0x6c,0x6c,0x63,0x74,0x2d])+_0x49070a(_0x4858d5(_0x141db8)),_0x515d34=window[_0x2cc4d3([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x2cc4d3([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x47c57d);return _0x515d34?window[_0x2cc4d3([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x420b3f(_0x515d34),0x10)*_0x3d8e6f:null;}function _0x815e57(_0x28f5f4){return new window[(_0x2cc4d3([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0xebf089,_0x21d1b9)=>{_0x28f5f4[_0x2cc4d3([0x74,0x68,0x65,0x6e])](_0xebf089,_0x21d1b9),window[_0x2cc4d3([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x21d1b9,0x1f8b3605^_0x2d8902);});}}_0x5a307c[_0x2cc4d3([0x6f,0x6e])](_0x2cc4d3([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x2d93c9,_0x292947)=>{if(_0x292947[0x0]!=_0x141db8)return _0x4da747(_0x2cc4d3([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x292947[0x1]={..._0x292947[0x1],[_0x2cc4d3([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x40d0e6};},{[_0x2cc4d3([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x2cc4d3([0x68,0x69,0x67,0x68])}),_0x5a307c[_0x2cc4d3([0x6f,0x6e])](_0x2cc4d3([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x4eaa07=>{_0x9bffe3(_0x4eaa07[_0x2cc4d3([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x3ae24c=!0x0,_0x5885be(_0x4eaa07[_0x2cc4d3([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x2cc4d3([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x2cc4d3([0x6c,0x6f,0x77])}),_0x481dcb[_0x2cc4d3([0x74,0x68,0x65,0x6e])](()=>{_0x3ae24c||_0x4da747(_0x2cc4d3([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x460fc5(){return _0x5a307c[_0x2cc4d3([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x2cc4d3([0x76,0x69,0x65,0x77])][_0x2cc4d3([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x2cc4d3([0x61,0x75,0x74,0x6f]);}function _0x2932ba(){_0x5a307c[_0x2cc4d3([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x2cc4d3([0x76,0x69,0x65,0x77])][_0x2cc4d3([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x2cc4d3([0x61,0x75,0x74,0x6f]);}}function _0x5201b6(_0x43bff1){const _0x59d264=[new window[(_0x2cc4d3([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x4636e8=>setTimeout(_0x4636e8,0x1f83dc09^_0x2d8902)),_0x481dcb[_0x2cc4d3([0x74,0x68,0x65,0x6e])](()=>new window[(_0x2cc4d3([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x5143fc=>{const _0x4e24c0=0x1f8ae2c2^_0x2d8902,_0x287a1b=_0xc0b19[_0x2cc4d3([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x3700d6(){_0x287a1b[_0x2cc4d3([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x4e24c0&&_0x5143fc();}_0x3700d6(),_0x287a1b[_0x2cc4d3([0x6f,0x6e])](_0x2cc4d3([0x61,0x64,0x64]),_0x3700d6);})),new window[(_0x2cc4d3([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x4cef87=>{function _0x2772c1(){for(const _0x2fc0a7 in window)if(window[_0x2cc4d3([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x2cc4d3([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x2fc0a7))&&window[_0x2fc0a7]==_0x332c52)return _0x4cef87();_0x5a307c[_0x2cc4d3([0x73,0x74,0x61,0x74,0x65])]!=_0x2cc4d3([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x2cc4d3([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x2772c1,0x1f8af14d^_0x2d8902);}_0x3e7ff8(_0x2cc4d3([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x2772c1();})];return window[_0x2cc4d3([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x2cc4d3([0x72,0x61,0x63,0x65])](_0x59d264)[_0x2cc4d3([0x74,0x68,0x65,0x6e])](()=>_0x43bff1);}async function _0x594aa3(){if(await _0x481dcb,_0x3e7ff8(_0x2cc4d3([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x1e3f61=_0xc0b19[_0x2cc4d3([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x27218a=_0xc0b19[_0x2cc4d3([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])](_0x1e3f61[_0x2cc4d3([0x69,0x64])]),_0x1e0bcc=_0x3fadf9(_0x2cc4d3([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x1e0bcc[_0x2cc4d3([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x1e3f61['id'],_0x27218a?_0x27218a['id']:null,!0x0),_0x1e0bcc[_0x2cc4d3([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x2cc4d3([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x1e0bcc[_0x2cc4d3([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x1e0bcc[_0x2cc4d3([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x49840f,void(_0x1e0bcc[_0x2cc4d3([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x49840f);}if(_0x3e7ff8(_0x2cc4d3([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x3ebcf9=_0x3fadf9(_0x2cc4d3([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x3ebcf9[_0x2cc4d3([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x2cc4d3([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x3ebcf9[_0x2cc4d3([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x3ebcf9[_0x2cc4d3([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x49840f,_0x3ebcf9[_0x2cc4d3([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x49840f;}_0x5a307c[_0x2cc4d3([0x6d,0x6f,0x64,0x65,0x6c])][_0x2cc4d3([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x49840f,_0x5a307c[_0x2cc4d3([0x6d,0x6f,0x64,0x65,0x6c])][_0x2cc4d3([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x49840f,_0x5a307c[_0x2cc4d3([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x2cc4d3([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x284955(){return _0x3e7ff8(_0x2cc4d3([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x3fadf9(_0x2cc4d3([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x2cc4d3([0x73,0x74,0x61,0x74,0x65])]==_0x2cc4d3([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x2bd92b(){return _0x3e7ff8(_0x2cc4d3([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 _0x359e01(){return _0x3e7ff8(_0x2cc4d3([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0xc0fa20(_0x47fb2a){const _0x12e1ca=_0x3966c5();_0x5a307c[_0x12e1ca]=_0x2cc4d3([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])+_0x47fb2a,_0x47fb2a[_0x2cc4d3([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x2cc4d3([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x3966c5()]=_0x332c52),_0x47fb2a!=_0x2cc4d3([0x56,0x61,0x6c,0x69,0x64])&&_0x594aa3();}function _0x3966c5(){const _0x563151=window[_0x2cc4d3([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x2cc4d3([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x2cc4d3([0x6e,0x6f,0x77])]())[_0x2cc4d3([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x2cc4d3([0x2e]),'');let _0x592e80=_0x2cc4d3([0x43]);for(let _0x22e736=0x0;_0x22e736<_0x563151[_0x2cc4d3([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x22e736+=0x2){let _0x1efc4c=window[_0x2cc4d3([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x563151[_0x2cc4d3([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x22e736,_0x22e736+0x2));_0x1efc4c>=_0x54221e[_0x2cc4d3([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x1efc4c-=_0x54221e[_0x2cc4d3([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x592e80+=_0x54221e[_0x1efc4c];}return _0x592e80;}function _0xfaf91b(){const _0x3a1281=_0x4e5950[_0x2cc4d3([0x73,0x70,0x6c,0x69,0x74])](_0x2cc4d3([0x2e]));if(0x3!=_0x3a1281[_0x2cc4d3([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x50f94d(_0x3a1281[0x1]);function _0x50f94d(_0x2e1d5a){const _0x56dfcc=_0x4297ac(_0x2e1d5a);return _0x56dfcc&&_0x32720c()?_0x56dfcc:null;function _0x32720c(){const _0x219b8f=_0x56dfcc[_0x2cc4d3([0x6a,0x74,0x69])],_0x1ae3f5=window[_0x2cc4d3([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x219b8f[_0x2cc4d3([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x219b8f[_0x2cc4d3([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0xd11c31={..._0x56dfcc,[_0x2cc4d3([0x6a,0x74,0x69])]:_0x219b8f[_0x2cc4d3([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x219b8f[_0x2cc4d3([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0xd11c31[_0x2cc4d3([0x76,0x63])],_0x4858d5(_0xd11c31)==_0x1ae3f5;}}}async function _0x125424(){let _0x57b803=!0x0;try{const _0x466e88=_0x4e5950[_0x2cc4d3([0x73,0x70,0x6c,0x69,0x74])](_0x2cc4d3([0x2e])),[_0x508518,_0xffa3cc,_0xdcf88e]=_0x466e88;return _0xa6e47a(_0x508518),await _0x2b7ecf(_0x508518,_0xffa3cc,_0xdcf88e),_0x57b803;}catch(_0x1435d2){return!0x1;}function _0xa6e47a(_0x34fcf8){const _0x1c1cb2=_0x4297ac(_0x34fcf8);_0x1c1cb2&&_0x1c1cb2[_0x2cc4d3([0x61,0x6c,0x67])]==_0x2cc4d3([0x45,0x53,0x32,0x35,0x36])||(_0x57b803=!0x1);}async function _0x2b7ecf(_0x50ca71,_0xa86364,_0x5cb0b1){const _0x48fc0b=window[_0x2cc4d3([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x2cc4d3([0x66,0x72,0x6f,0x6d])](_0x52a934(_0x5cb0b1),_0x327ad5=>_0x327ad5[_0x2cc4d3([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x4ecf11=new window[(_0x2cc4d3([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x2cc4d3([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x50ca71+_0x2cc4d3([0x2e])+_0xa86364),_0x4b3d8d=window[_0x2cc4d3([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x2cc4d3([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x4b3d8d)return;const _0x558f71=await _0x4b3d8d[_0x2cc4d3([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x2cc4d3([0x6a,0x77,0x6b]),_0x5593a6,{[_0x2cc4d3([0x6e,0x61,0x6d,0x65])]:_0x2cc4d3([0x45,0x43,0x44,0x53,0x41]),[_0x2cc4d3([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x2cc4d3([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x2cc4d3([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x4b3d8d[_0x2cc4d3([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x2cc4d3([0x6e,0x61,0x6d,0x65])]:_0x2cc4d3([0x45,0x43,0x44,0x53,0x41]),[_0x2cc4d3([0x68,0x61,0x73,0x68])]:{[_0x2cc4d3([0x6e,0x61,0x6d,0x65])]:_0x2cc4d3([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x558f71,_0x48fc0b,_0x4ecf11)||(_0x57b803=!0x1);}}function _0x4297ac(_0x3a47a5){return _0x3a47a5[_0x2cc4d3([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x2cc4d3([0x65,0x79]))?JSON[_0x2cc4d3([0x70,0x61,0x72,0x73,0x65])](_0x52a934(_0x3a47a5)):null;}function _0x52a934(_0x215c32){return window[_0x2cc4d3([0x61,0x74,0x6f,0x62])](_0x215c32[_0x2cc4d3([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x2cc4d3([0x2b]))[_0x2cc4d3([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x2cc4d3([0x2f])));}function _0x4858d5(_0x17152b){let _0x531305=0x1505;function _0x4c7398(_0x7dc454){for(let _0x57d260=0x0;_0x57d260<_0x7dc454[_0x2cc4d3([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x57d260++){const _0x25dd07=_0x7dc454[_0x2cc4d3([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x57d260);_0x531305=(_0x531305<<0x5)+_0x531305+_0x25dd07,_0x531305&=_0x531305;}}function _0x52de1f(_0x1f9c56){Array[_0x2cc4d3([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x1f9c56)?_0x1f9c56[_0x2cc4d3([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x52de1f):_0x1f9c56&&typeof _0x1f9c56==_0x2cc4d3([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x2cc4d3([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x1f9c56)[_0x2cc4d3([0x73,0x6f,0x72,0x74])]()[_0x2cc4d3([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x134812,_0x36cbbf])=>{_0x4c7398(_0x134812),_0x52de1f(_0x36cbbf);}):_0x4c7398(window[_0x2cc4d3([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x1f9c56));}return _0x52de1f(_0x17152b),_0x531305>>>0x0;}function _0x49070a(_0x5a31ce){return _0x5a31ce[_0x2cc4d3([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x2cc4d3([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x2cc4d3([0x30]));}function _0x420b3f(_0x34dec8){return _0x34dec8[_0x2cc4d3([0x73,0x70,0x6c,0x69,0x74])]('')[_0x2cc4d3([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x2cc4d3([0x6a,0x6f,0x69,0x6e])]('');}function _0x3e7ff8(_0xde0e54){return _0x5a307c[_0x2cc4d3([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x2cc4d3([0x68,0x61,0x73])](_0xde0e54);}function _0x3fadf9(_0x32188f){return _0x5a307c[_0x2cc4d3([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x2cc4d3([0x67,0x65,0x74])](_0x32188f);}function _0x49840f(){}function _0x2cc4d3(_0x5501f9){return _0x5501f9['map'](_0x260062=>String['fromCharCode'](_0x260062))['join']('');}_0xc0fa20(await _0x31ead6());}(this);}['createRevision'](_0x1b4ec9){const _0x361760=this['editor']['plugins']['get']('Users');return new a({'id':_0x1b4ec9['id'],'name':_0x1b4ec9['name'],'creator':_0x1b4ec9['creatorId']?_0x361760['getUser'](_0x1b4ec9['creatorId']):null,'diffData':_0x1b4ec9['diffData']||_0x1b4ec9['data'],'authors':_0x1b4ec9['authorsIds']['map'](_0x3487db=>_0x361760['getUser'](_0x3487db)),'createdAt':new Date(_0x1b4ec9['createdAt']),'attributes':_0x1b4ec9['attributes'],'fromVersion':_0x1b4ec9['fromVersion'],'toVersion':_0x1b4ec9['toVersion']});}['addRevision'](_0x5bcbd6,_0x3a7a75=0x0){this['_revisions']['add'](_0x5bcbd6,_0x3a7a75);}['getRevision'](_0x3ba530){return this['_revisions']['get'](_0x3ba530);}['getRevisions'](_0x27e497={'toJSON':!0x1}){const _0x3ee8ed=Array['from'](this['_revisions']);return _0x3ee8ed['reverse'](),_0x27e497['toJSON']?_0x3ee8ed['map'](_0x31281a=>_0x31281a['toJSON']()):_0x3ee8ed;}['getIndex'](_0x15e1fe){return this['_revisions']['getIndex'](_0x15e1fe);}['getEarlierVisibleRevision'](_0x3f1e19){const [,_0x2a8540]=this['getRevisionsIterator'](_0x3f1e19,{'direction':'earlier'});return _0x2a8540;}['getLaterVisibleRevision'](_0x70f5b8){const [,_0x188173]=this['getRevisionsIterator'](_0x70f5b8,{'direction':'later'});return _0x188173;}['getRevisionsInDiff'](_0x88cdd9){const _0x246ad2=[];for(const _0x55cd9b of this['getRevisionsIterator'](_0x88cdd9['newRevisionId']))if(_0x246ad2['push'](_0x55cd9b),_0x55cd9b['id']===_0x88cdd9['oldRevisionId'])break;return _0x246ad2;}*['getRevisionsIterator'](_0x3fd464,{direction:_0x36a02f='earlier',filter:_0xa77df0=()=>!0x0}={}){const _0x257fcd='earlier'===_0x36a02f?0x1:-0x1;let _0x5055d7=this['_revisions']['get'](_0x3fd464),_0x29930a=this['getIndex'](_0x5055d7);for(yield _0x5055d7;_0x5055d7;){if(_0x29930a+=_0x257fcd,_0x5055d7=this['getRevision'](_0x29930a),!_0x5055d7)return;_0xa77df0(_0x5055d7)&&(yield _0x5055d7);}}}function m(_0x5a6c37,_0x99793c,_0x1af93c){const t=_0x5a6c37['t'];switch(_0x99793c){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'},_0x1af93c);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x1af93c);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'';}}const P={'c':_0x290b4f,'a':_0x47add3,'e':_0x30b150,'r':_0x23e731,'u':_0x927dea};class l extends _0x50f6d6{['licenseKey'];['_licenseKeyCheckInterval'];['adapter'];['currentRevision'];['repository'];['_revisionDataBuilder'];['_source'];['_initialRevisionId'];['_bufferedUpdates'];['_pendingAction'];['_continueCurrentRevision'];['_startingVersion'];['_loadedStateData'];static get['pluginName'](){return'RevisionTracker';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[_0x191bf9,j,_0x56e351];}constructor(_0x4a354c){super(_0x4a354c),this['adapter']=null,this['currentRevision']=null,this['_revisionDataBuilder']=new V(this['editor']),this['_initialRevisionId']=this['editor']['config']['get']('collaboration.channelId')||'initial',this['_bufferedUpdates']=new Map(),this['_loadedStateData']=null;const _0x5cc5bf=_0x1fa053();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x5cc5bf},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['repository']=this['editor']['plugins']['get']('RevisionsRepository'),this['_setConversion'](),this['editor']['data']['on']('ready',()=>{const _0x5b12cf=this['repository']['getRevision'](0x0),_0x7a69a7=_0x5b12cf&&null===_0x5b12cf['creator']?_0x5b12cf:null;if(this['_continueCurrentRevision']=!!_0x7a69a7&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x5ad2cc=this['_source']['getCurrentRevisionId'](),_0x5b7b91=this['repository']['getRevision'](_0x5ad2cc);if(_0x5b7b91)this['_startingVersion']=_0x5b7b91['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0xaffdeb=this['_source']['history']['_operations']['find'](_0x397565=>!_0x397565['_isInit']),_0x449c9c=_0xaffdeb?_0xaffdeb['baseVersion']:this['_source']['history']['version'];_0x5b12cf?(_0x5b12cf['toVersion']<_0x449c9c&&_0x5b12cf['_update']({'toVersion':_0x449c9c}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x7a69a7['id'],this['_startingVersion']=_0x7a69a7['fromVersion']):(this['_startingVersion']=_0x5b12cf['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x449c9c,this['_continueCurrentRevision']=!0x1);}}else _0x7a69a7&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x7a69a7['toVersion'],this['editor']['model']['document']['history']['version']),_0x7a69a7['fromVersion']===_0x7a69a7['toVersion']?(0x0!==_0x7a69a7['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x7a69a7['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x7a69a7['id'],this['_startingVersion']=_0x7a69a7['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',_0x4c2e17=>!_0x4c2e17),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x419474=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x435ccb;for(const _0x8a45f4 in _0x419474){const _0x50c82d=_0x8a45f4,_0x2fcc5f=_0x419474[_0x50c82d];if('revisionHistoryLicenseKeyValid'==_0x2fcc5f||'revisionHistoryLicenseKeyInvalid'==_0x2fcc5f||'revisionHistoryLicenseKeyExpired'==_0x2fcc5f||'revisionHistoryLicenseKeyDomainLimit'==_0x2fcc5f||'revisionHistoryLicenseKeyNotAllowed'==_0x2fcc5f||'revisionHistoryLicenseKeyEvaluationLimit'==_0x2fcc5f||'revisionHistoryLicenseKeyTrialLimit'==_0x2fcc5f||'revisionHistoryLicenseKeyUsageLimit'==_0x2fcc5f){delete _0x419474[_0x50c82d],_0x435ccb=_0x2fcc5f,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x435ccb&&_0x419474['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x435ccb&&_0x419474['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x435ccb&&_0x419474['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x435ccb&&_0x419474['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x435ccb&&_0x419474['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x435ccb&&_0x419474['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x435ccb&&_0x419474['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x1b57d7=this['repository']['getRevision'](0x0),_0x4df12c=await this['getRevisionDocumentData'](_0x1b57d7),_0x896772=await this['getRevisionRootsAttributes'](_0x1b57d7);this['_replaceEditorDataWithRevisionData'](_0x4df12c,_0x896772);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x146fee){this['_source']=_0x146fee;}async['update'](){const _0x18015f=await this['_source']['getLatestVersion']();if(_0x18015f>this['currentRevision']['toVersion']){await this['_loadState']();const _0xd33ff7=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x18015f});_0xd33ff7['authors']=_0xd33ff7['authorsIds']['map'](_0x2277e6=>this['editor']['plugins']['get']('Users')['getUser'](_0x2277e6)),this['currentRevision']['_update'](_0xd33ff7);}}async['_loadState'](){this['_continueCurrentRevision']&&!this['_loadedStateData']&&(await this['_loadRevisionData'](this['currentRevision']),this['_revisionDataBuilder']['loadState'](this['currentRevision']),this['_loadedStateData']={'fromVersion':this['currentRevision']['fromVersion'],'authors':this['currentRevision']['authors']['slice']()});}async['saveRevision'](_0x4c1926={},_0x514af7=null){const _0x5da6ce=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x514af7>this['currentRevision']['toVersion']&&(_0x514af7=null),null===_0x514af7&&(_0x514af7=await this['_source']['getLatestVersion']());const _0x325a29=this['_getFromVersion'](_0x514af7),_0x5d25d7=this['buildRevisionData']({'from':_0x325a29,'to':_0x514af7});if(this['currentRevision']['toVersion']<_0x514af7){const _0xeb3366=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x514af7,'to':_0x514af7});_0xeb3366['authors']=[],_0xeb3366['authorsIds']=[],_0xeb3366['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0xeb3366,!0x0),delete _0xeb3366['authors'],_0x5da6ce['push'](_0xeb3366);}_0x4c1926['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x4c1926['name']=_0x4c1926['name']||null,_0x4c1926['id']=_0x4c1926['id']||_0x1fa053(),_0x4c1926={..._0x4c1926,..._0x5d25d7};const _0x3f9148=this['addRevisionData'](_0x4c1926);_0x5da6ce['push'](_0x4c1926);const _0x450908=this['repository']['getIndex'](_0x3f9148);if(0x0!==_0x450908){const _0x688c0b=this['repository']['getRevision'](_0x450908-0x1);if(_0x688c0b['fromVersion']!==_0x514af7){const _0x6cf9bd=this['_revisionDataBuilder']['getData'](_0x514af7,_0x688c0b['toVersion']),_0x4aa09f={'id':_0x688c0b['id'],'diffData':_0x6cf9bd['diffData'],'authorsIds':_0x6cf9bd['authorsIds'],'authors':_0x6cf9bd['authorsIds']['map'](_0x3d12c7=>this['editor']['plugins']['get']('Users')['getUser'](_0x3d12c7)),'fromVersion':_0x514af7};_0x688c0b===this['currentRevision']&&(_0x4aa09f['createdAt']=new Date(_0x4c1926['createdAt']['getTime']()+0xa)),_0x688c0b['_update'](_0x4aa09f,!0x0),delete _0x4aa09f['authors'],_0x5da6ce['push'](_0x4aa09f);}}if(this['adapter']){for(const _0x4fc633 of _0x5da6ce)this['_bufferUpdate'](_0x4fc633['id'],_0x4fc633,!0x0);this['sendBufferedUpdates']();}return _0x3f9148;}['addRevisionData'](_0x14c7e4){const _0x255a82=this['repository']['createRevision'](_0x14c7e4);return this['adapter']&&_0x255a82['on']('_update',(_0x3c15a6,_0x329c17,_0x1872e1)=>{_0x1872e1||(this['_bufferUpdate'](_0x329c17['id'],_0x329c17,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x255a82,this['_findInsertionIndex'](_0x255a82)),_0x255a82;}async['getRevisionDocumentData'](_0x2c8f1c){await this['_loadRevisionData'](_0x2c8f1c);const _0x5eab6a={};for(const _0x301b0e in _0x2c8f1c['diffData']){if(_0x2c8f1c['diffData'][_0x301b0e]['attachChange']&&!_0x2c8f1c['diffData'][_0x301b0e]['attachChange']['isAttached'])continue;const _0x162771=this['_removeRevisionMarkers'](JSON['parse'](_0x2c8f1c['diffData'][_0x301b0e]['insertions'])),_0x3044eb=this['editor']['editing']['view']['document'],_0x50deef=new _0x4c4bb9(_0x3044eb,_0x162771['map'](_0x41a667=>C(_0x41a667,this['editor'])));this['editor']['data']['processor']['useFillerType']('marked'),_0x5eab6a[_0x301b0e]=this['editor']['data']['processor']['toData'](_0x50deef),this['editor']['data']['processor']['useFillerType']('default');}return _0x5eab6a;}async['getRevisionRootsAttributes'](_0x23a555){await this['_loadRevisionData'](_0x23a555);const _0x38e5d4={};for(const _0x43fbc9 in _0x23a555['diffData'])_0x23a555['diffData'][_0x43fbc9]['attachChange']&&!_0x23a555['diffData'][_0x43fbc9]['attachChange']['isAttached']||(_0x38e5d4[_0x43fbc9]=_0x23a555['diffData'][_0x43fbc9]['attributesAfter']||{});return _0x38e5d4;}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x37f90d=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x29390c=0x0;_0x29390c<_0x37f90d['length'];_0x29390c++){const _0x174c35=_0x37f90d[_0x29390c];let _0x34ac17=!0x1;for(const _0x5d1b64 of Object['keys'](_0x174c35))void 0x0===_0x174c35[_0x5d1b64]?delete _0x174c35[_0x5d1b64]:'id'!==_0x5d1b64&&(_0x34ac17=!0x0);_0x34ac17||(_0x37f90d[_0x29390c]=null);}if(_0x37f90d=_0x37f90d['filter'](_0x11f3eb=>null!==_0x11f3eb),!_0x37f90d['length'])return;for(let _0x3b01e5=0x0;_0x3b01e5<_0x37f90d['length'];_0x3b01e5++){const _0x244916=_0x37f90d[_0x3b01e5];void 0x0!==_0x244916['fromVersion']&&void 0x0===_0x244916['toVersion']&&(_0x244916['toVersion']=this['repository']['getRevision'](_0x244916['id'])['toVersion']),void 0x0!==_0x244916['toVersion']&&void 0x0===_0x244916['fromVersion']&&(_0x244916['fromVersion']=this['repository']['getRevision'](_0x244916['id'])['fromVersion']);}const _0x2333f4=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x37f90d,_0x2333f4)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x2646c9=>{if(_0x2646c9){for(const _0x4c8f85 of _0x2646c9)this['setRevisionData']({'id':_0x4c8f85['id'],'createdAt':_0x4c8f85['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['_replaceEditorDataWithRevisionData'](_0x36e27e,_0x1638de){let _0x1f2de3=this['editor']['config']['get']('initialData'),_0x233ea8=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x1f2de3){_0x1f2de3={};for(const _0x1e7b52 of this['editor']['model']['document']['getRootNames']())_0x1f2de3[_0x1e7b52]='';}if('string'==typeof _0x1f2de3&&(_0x1f2de3={'main':_0x1f2de3}),void 0x0===_0x233ea8){_0x233ea8={};for(const _0x114173 of this['editor']['model']['document']['getRootNames']())_0x233ea8[_0x114173]={};}let _0x37255c=!0x1;const _0x333fca=Object['keys'](_0x1f2de3),_0x169dcd=Object['keys'](_0x36e27e);for(const _0x360760 of _0x333fca){if(_0x1f2de3[_0x360760]!==_0x36e27e[_0x360760]&&''!==_0x1f2de3[_0x360760]['trim']()){_0x37255c=!0x0;break;}if(!_0xba09d3(_0x233ea8[_0x360760],_0x1638de[_0x360760])&&Object['keys'](_0x233ea8[_0x360760])['length']>0x0){_0x37255c=!0x0;break;}}_0x37255c||(_0x37255c=_0x169dcd['some'](_0x1fe84b=>!this['editor']['model']['document']['getRoot'](_0x1fe84b))),_0x37255c&&_0x1324f1('editor-initial-data-replaced-with-revision-data',{'editorData':_0x1f2de3,'editorRootsAttributes':_0x233ea8,'revisionData':_0x36e27e,'revisionRootsAttributes':_0x1638de}),this['editor']['config']['set']('initialData',_0x36e27e),this['editor']['config']['set']('rootsAttributes',_0x1638de);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x152a71=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x152a71['add'](m(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x3878aa){const _0x524418=this['repository']['getRevisions']();_0x524418['reverse']();let _0x59e360=0x0;for(;_0x59e360<_0x524418['length'];){const _0x51d65c=_0x524418[_0x59e360];if(_0x51d65c===this['currentRevision']){_0x59e360++;continue;}if(_0x51d65c['id']===this['_initialRevisionId'])break;const _0x130808=_0x3878aa['toVersion']-_0x51d65c['toVersion']||_0x3878aa['fromVersion']-_0x51d65c['fromVersion'];if(_0x130808>0x0)break;if(_0x130808<0x0)_0x59e360++;else{if(!_0x3878aa['creator']&&_0x51d65c['creator'])break;if(_0x51d65c['creator']||!_0x3878aa['creator']){if(_0x3878aa['createdAt']>_0x51d65c['createdAt'])break;_0x59e360++;}else _0x59e360++;}}return _0x59e360;}['setRevisionData'](_0x33c7fa){const _0x17c1fd=this['repository']['getRevision'](_0x33c7fa['id']);if(_0x33c7fa['createdAt']&&(_0x33c7fa['createdAt']=new Date(_0x33c7fa['createdAt'])),_0x33c7fa['authorsIds']){const _0x3c7910=this['editor']['plugins']['get']('Users');_0x33c7fa['authors']=_0x33c7fa['authorsIds']['map'](_0x4409a6=>_0x3c7910['getUser'](_0x4409a6));}_0x17c1fd['_update'](_0x33c7fa,!0x0);}['buildRevisionData']({revision:_0x54adc1=null,from:_0xc2bb7d=null,to:_0x504fa0=null}){_0xc2bb7d=null!==_0xc2bb7d?_0xc2bb7d:_0x54adc1['fromVersion'],_0x504fa0=null!==_0x504fa0?_0x504fa0:_0x54adc1['toVersion'];const _0x288e08=this['_revisionDataBuilder']['getData'](_0xc2bb7d,_0x504fa0),_0x19acf2={'diffData':_0x288e08['diffData'],'authorsIds':_0x288e08['authorsIds'],'fromVersion':_0xc2bb7d,'toVersion':_0x504fa0};if(!_0x54adc1||_0x504fa0!==_0x54adc1['toVersion']){const _0x3935e4=_0x504fa0-0x1,_0x1aba0a=this['_source']['history']['getOperation'](_0x3935e4);_0x19acf2['createdAt']=_0x1aba0a&&_0x1aba0a['createdAt']||new Date();}if(this['_loadedStateData']&&_0xc2bb7d===this['_loadedStateData']['fromVersion']){for(const _0x5c06b4 of this['_loadedStateData']['authors'])_0x19acf2['authorsIds']['includes'](_0x5c06b4['id'])||_0x19acf2['authorsIds']['push'](_0x5c06b4['id']);}return _0x19acf2;}['_loadRevisionData'](_0x1753fd){if(!_0x1753fd||_0x1753fd['diffData'])return Promise['resolve']();{const _0x54d8dd=this['editor']['config']['get']('collaboration.channelId');return this['adapter']['getRevision']({'channelId':_0x54d8dd,'revisionId':_0x1753fd['id']})['then'](_0x462bdc=>{_0x1753fd['diffData']=_0x462bdc['diffData'];});}}['_bufferUpdate'](_0xd55b6c,_0x114750,_0x27f65c){if(this['_bufferedUpdates']['has'](_0xd55b6c)){const _0xfaba59=this['_bufferedUpdates']['get'](_0xd55b6c);_0x114750=_0x27f65c?{..._0xfaba59,..._0x114750}:{..._0x114750,..._0xfaba59};}this['_bufferedUpdates']['set'](_0xd55b6c,_0x114750);}['_getFromVersion'](_0x52882c){const _0x4a475c=this['repository']['getRevisions']();_0x4a475c['reverse'](),_0x4a475c['shift']();const _0x86dfe4=_0x4a475c['find'](_0x57f258=>_0x57f258['toVersion']<=_0x52882c)['toVersion'];return _0x86dfe4<this['_startingVersion']?this['_startingVersion']:_0x86dfe4;}['_createInitialRevision'](_0x173f8a){const _0x1fe986=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x1fe986)this['_initialRevisionId']=_0x1fe986['id'];else{const _0x845008=!this['editor']['model']['document']['roots']['find'](_0x327d5e=>this['editor']['model']['hasContent'](_0x327d5e)),_0x693a29=this['editor']['plugins']['get']('Users')['me']['id'],_0x5a0d59=m(this['editor']['locale'],_0x845008?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x173f8a,'to':_0x173f8a,'id':this['_initialRevisionId'],'name':_0x5a0d59,'creatorId':_0x693a29});}}['_createCurrentRevision'](_0x3ba368){const _0x21b5ff=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x21b5ff),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x3ba368,'to':_0x3ba368,'id':_0x21b5ff,'name':'','creatorId':null}));}['_makeRevision']({name:_0x3f43f1,from:_0x258bff,to:_0x303c53,creatorId:_0x31cd3f,id:_0x2300a3}){const _0xea394=this['buildRevisionData']({'from':_0x258bff,'to':_0x303c53});_0xea394['name']=_0x3f43f1,_0xea394['creatorId']=_0x31cd3f,_0xea394['id']=_0x2300a3;const _0x1a1089=this['addRevisionData'](_0xea394);return this['adapter']&&this['_bufferUpdate'](_0xea394['id'],_0xea394,!0x0),_0x1a1089;}['_setConversion'](){this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'});}['_removeRevisionMarkers'](_0x81aeaf){return(_0x81aeaf=_0x81aeaf['filter'](_0x588cd2=>!_0x588cd2['name']||'revision-start'!==_0x588cd2['name']&&'revision-end'!==_0x588cd2['name']))['forEach'](_0x3eeefe=>{'string'!=typeof _0x3eeefe&&(_0x3eeefe['children']=this['_removeRevisionMarkers'](_0x3eeefe['children']),_0x3eeefe['attributes']=_0x3eeefe['attributes']['filter'](_0x54189d=>!_0x54189d[0x0]['startsWith']('data-revision-')));}),_0x81aeaf;}}function C(_0x5a4a66,_0xe14ea7){const _0x68bc99=_0xe14ea7['editing']['view']['document'];if('string'==typeof _0x5a4a66)return new _0x601889(_0x68bc99,_0x5a4a66);{const _0x10fb8a=_0x5a4a66['children']['map'](_0x4a9a01=>C(_0x4a9a01,_0xe14ea7));return new(P[_0x5a4a66['type']]||_0x38a4ac)(_0x68bc99,_0x5a4a66['name'],_0x5a4a66['attributes'],_0x10fb8a);}}class V{['editor'];['source'];['_savedMetaData'];['_lastFrom'];['_lastTo'];['_markers'];['_diffRoots'];['_diffRootsAttributes'];['_baseRoots'];['_baseRootsAttributes'];['_idsRoots'];['_baseIdsRoots'];['_touched'];['_touchedMarkers'];['_touchedRoots'];['_revisionId'];['_startingRevisionId'];constructor(_0x4ddb84){this['editor']=_0x4ddb84,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'](_0x324668){this['source']=_0x324668;const _0x5235f1=new Map(),_0x5800f0=new Map(),_0x534336=this['editor']['model']['document']['roots']['map'](_0x130ed8=>_0x130ed8['rootName']);for(const _0x2dfb15 of _0x534336){const _0x4d6d52=this['editor']['model']['document']['getRoot'](_0x2dfb15),_0x35fcfe=T(_0x4d6d52);_0x5235f1['set'](_0x2dfb15,_0x35fcfe),_0x5800f0['set'](_0x2dfb15,Object['fromEntries'](_0x4d6d52['getAttributes']()));}const _0x30c0cd=Array['from'](this['editor']['model']['markers'])['map'](_0x56bceb=>[_0x56bceb['name'],_0x56bceb['getRange']()]),_0x202f03=this['source']['version'];this['_saveMetaData'](_0x202f03,_0x5235f1,_0x30c0cd,_0x5800f0),this['_startingRevisionId']=this['_revisionId'];const _0xdb8340=new Map(),_0x5cff43=new Map();for(const _0x15a003 of _0x534336){const _0x569543=F(_0x15a003);_0xdb8340['set'](_0x15a003,_0x569543),_0x5cff43['set'](_0x15a003,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0xdb8340,[],_0x5cff43);}['getData'](_0x4d8bdf,_0x2c9faa){if(this['_lastFrom']===_0x4d8bdf&&this['_lastTo']<=_0x2c9faa)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x2c9faa,!0x0);else{if(!this['_savedMetaData']['has'](_0x4d8bdf)){const _0x44b1cc=this['_getPreviousFrom'](_0x4d8bdf);this['_calculateMetaData'](_0x44b1cc,_0x4d8bdf,!0x1);}this['_calculateMetaData'](_0x4d8bdf,_0x2c9faa,!0x0);}return this['_lastFrom']=_0x4d8bdf,this['_lastTo']=_0x2c9faa,this['_getState']();}['loadState'](_0x2745d0){this['_reset'](),this['_lastFrom']=_0x2745d0['fromVersion'],this['_lastTo']=_0x2745d0['toVersion'];for(const _0x5b642e in _0x2745d0['diffData']){const _0x5ca7b6=_0x2745d0['diffData'][_0x5b642e]['attachChange'],_0x2d6439=_0x3ec8e3(_0x2745d0['diffData'][_0x5b642e]['attributesBefore'])||{},_0x5c3e94=this['_makeModelFromViewString'](_0x2745d0['diffData'][_0x5b642e]['deletions']);_0x5c3e94['rootName']=_0x5b642e,_0x5c3e94['_isAttached']=!_0x5ca7b6||!_0x5ca7b6['isAttached'],_0x5c3e94['isAttached']=()=>_0x5c3e94['_isAttached'],this['_baseRoots']['set'](_0x5b642e,_0x5c3e94),this['_baseRootsAttributes']['set'](_0x5b642e,_0x2d6439),_0x5ca7b6&&this['_touchedRoots']['set'](_0x5b642e,_0x5ca7b6);const _0x30ccdb=this['_makeIdsRoot'](_0x5c3e94);this['_baseIdsRoots']['set'](_0x5b642e,_0x30ccdb);for(const [_0x4e6d82,_0x4a584d]of _0x5c3e94['markers']){if(!_0x4e6d82['startsWith']('revision:'))continue;const _0x3b2f22=_0x4e6d82['split'](':')[0x2];for(const _0x1d9012 of _0x4a584d['getWalker']({'singleCharacters':!0x0})){const _0x21a59e=this['_getVidAttributeName'](_0x1d9012),_0x673c04='elementEnd'==_0x1d9012['type']?_0x1d9012['previousPosition']['path']['slice'](0x0,-0x1):_0x1d9012['previousPosition']['path'],_0xd2b36=_0x30ccdb['getNodeByPath'](_0x673c04)['getAttribute'](_0x21a59e);this['_touched']['set'](_0xd2b36,{'userId':_0x3b2f22});}}}this['_startingRevisionId']=this['_revisionId'];const _0x5a746a=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x2a90a8=>!this['_touched']['has'](_0x2a90a8));let _0x4135ca=0x0;const _0xd8748d=new Map();for(const _0x196d5c in _0x2745d0['diffData']){const _0xee8c49=_0x2745d0['diffData'][_0x196d5c]['attachChange'],_0x526b81=_0x3ec8e3(_0x2745d0['diffData'][_0x196d5c]['attributesAfter'])||{},_0x29a5fe=this['_makeModelFromViewString'](_0x2745d0['diffData'][_0x196d5c]['insertions']);_0x29a5fe['rootName']=_0x196d5c,_0x29a5fe['_isAttached']=!_0xee8c49||_0xee8c49['isAttached'],_0x29a5fe['isAttached']=()=>_0x29a5fe['_isAttached'],this['_diffRoots']['set'](_0x196d5c,_0x29a5fe),this['_diffRootsAttributes']['set'](_0x196d5c,_0x526b81);const _0x15dc66=this['_makeIdsRoot'](_0x29a5fe,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x196d5c,_0x15dc66),_0xd8748d['set'](_0x196d5c,_0x29a5fe['isAttached']()?_0x526b81:{});for(const [_0x2fc849,_0x50dc19]of _0x29a5fe['markers']){if(!_0x2fc849['startsWith']('revision:'))continue;const _0x550cc8=_0x2fc849['split'](':')[0x2];for(const _0xb63cb of _0x50dc19['getWalker']({'singleCharacters':!0x0})){const _0x459065=this['_getVidAttributeName'](_0xb63cb),_0x2c66e9=this['_revisionId']++,_0x1f7194='elementEnd'==_0xb63cb['type']?_0xb63cb['previousPosition']['path']['slice'](0x0,-0x1):_0xb63cb['previousPosition']['path'];_0x15dc66['getNodeByPath'](_0x1f7194)['_setAttribute'](_0x459065,_0x2c66e9),this['_touched']['set'](_0x2c66e9,{'userId':_0x550cc8});}}for(const _0x4ef875 of this['editor']['model']['createRangeIn'](_0x29a5fe)['getWalker']({'singleCharacters':!0x0})){const _0x280b8e=this['_getVidAttributeName'](_0x4ef875),_0x46ecf7='elementEnd'==_0x4ef875['type']?_0x4ef875['previousPosition']['path']['slice'](0x0,-0x1):_0x4ef875['previousPosition']['path'],_0x1f2d14=_0x15dc66['getNodeByPath'](_0x46ecf7);_0x1f2d14['getAttribute'](_0x280b8e)>0x0||_0x1f2d14['_setAttribute'](_0x280b8e,_0x5a746a[_0x4135ca++]);}for(const [_0x16889e,_0x2b4c27]of _0x29a5fe['markers'])_0x16889e['startsWith']('revision:')||this['_markers']['set'](_0x16889e,_0x2b4c27);}const _0x4b3db0=F('$graveyard');this['_baseRoots']['set']('$graveyard',_0x4b3db0),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x4b3db0,0x1));const _0x5a24d0=F('$graveyard');this['_diffRoots']['set']('$graveyard',_0x5a24d0),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x5a24d0,0x1));const _0x54e087=Array['from'](this['_diffRoots'])['map'](([_0x1df56f,_0x162c82])=>[_0x1df56f,T(_0x162c82)]);this['_saveMetaData'](this['_lastTo'],_0x54e087,this['_markers'],_0xd8748d);}['_makeModelFromViewString'](_0xeaa718){const _0x16b6be=JSON['parse'](_0xeaa718),_0x46cb7d=this['editor']['editing']['view']['document'],_0x5a4506=new _0x4c4bb9(_0x46cb7d,_0x16b6be['map'](_0x501a3d=>C(_0x501a3d,this['editor'])));return this['editor']['data']['toModel'](_0x5a4506);}['_saveMetaData'](_0x57f1e1,_0x47c198,_0x208064,_0x124976){const _0xe37cc0=new Map(_0x47c198),_0x5a6769=new Map(_0x3ec8e3(_0x124976)),_0x54fc8f=new Map();for(const [_0xc56dd8,_0x29fdeb]of _0x208064)_0x54fc8f['set'](_0xc56dd8,{'start':_0x29fdeb['start']['clone'](),'end':_0x29fdeb['end']['clone'](),'rootName':_0x29fdeb['root']['rootName']});this['_savedMetaData']['set'](_0x57f1e1,{'roots':_0xe37cc0,'markers':_0x54fc8f,'rootsAttributes':_0x5a6769});}['_removeMetaData'](_0x391a59){this['_savedMetaData']['delete'](_0x391a59);}['reInit'](){this['_reset'](),this['_lastFrom']=-0x1,this['_lastTo']=-0x1,this['_savedMetaData']['clear'](),this['init'](this['source']);}['_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'](_0x508b66,_0x46a612=null){let _0x53f3da=null;_0x508b66['is']('documentFragment')||(_0x53f3da=new ft(_0x508b66['name'],{'vid_start':null===_0x46a612?this['_revisionId']++:_0x46a612++}));const _0x3ee797=[];for(const _0x460c32 of _0x508b66['getChildren']())if(_0x460c32['is']('element')){_0x3ee797['push'](this['_makeIdsRoot'](_0x460c32,_0x46a612));const _0x2c6161=_0x3ee797[_0x3ee797['length']-0x1];null!==_0x46a612&&(_0x46a612=_0x2c6161['is']('element','$text')?_0x2c6161['getAttribute']('vid')+0x1:_0x2c6161['getAttribute']('vid_end')+0x1);}else{for(let _0x4cb746=0x0;_0x4cb746<_0x460c32['offsetSize'];_0x4cb746++)_0x3ee797['push'](new ft('$text',{'vid':null===_0x46a612?this['_revisionId']++:_0x46a612++}));}if(_0x508b66['is']('documentFragment')){const _0x37cfdf=F(_0x508b66['rootName']);return _0x37cfdf['_insertChild'](0x0,_0x3ee797),_0x37cfdf;}return _0x53f3da['_setAttribute']('vid_end',null===_0x46a612?this['_revisionId']++:_0x46a612++),_0x53f3da['_insertChild'](0x0,_0x3ee797),_0x53f3da;}['_calculateMetaData'](_0x31350a,_0x3195e4,_0x345fcc){this['_reset']();const {roots:_0x3168a0,markers:_0x32fa92,rootsAttributes:_0x4bd4f4}=this['_savedMetaData']['get'](_0x31350a);this['_baseRoots']=new Map(_0x3168a0),this['_baseRootsAttributes']=new Map(_0x3ec8e3(_0x4bd4f4));for(const [_0x2a3503,_0x19c8ba]of this['_baseRoots'])if('$graveyard'!==_0x2a3503&&(this['_diffRoots']['set'](_0x2a3503,T(_0x19c8ba)),this['_diffRootsAttributes']=new Map(_0x3ec8e3(_0x4bd4f4)),_0x345fcc)){const _0x2788a7=this['_revisionId'];this['_idsRoots']['set'](_0x2a3503,this['_makeIdsRoot'](_0x19c8ba)),this['_baseIdsRoots']['set'](_0x2a3503,this['_makeIdsRoot'](_0x19c8ba,_0x2788a7));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',T(this['_baseRoots']['get']('$graveyard'))),_0x345fcc&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x19f754,_0x4dc109]of _0x32fa92){const _0x52bc0f=this['_baseRoots']['get'](_0x4dc109['rootName']),_0x50aaff=this['_diffRoots']['get'](_0x4dc109['rootName']),_0x1f7aa9=new vt(this['_fixPosition'](_0x4dc109['start'],_0x52bc0f),this['_fixPosition'](_0x4dc109['end'],_0x52bc0f)),_0x436348=this['_fixRange'](_0x1f7aa9,_0x50aaff);_0x52bc0f['markers']['set'](_0x19f754,_0x1f7aa9),this['_markers']['set'](_0x19f754,_0x436348);}this['_applyOperations'](_0x31350a,_0x3195e4,_0x345fcc);}['_applyOperations'](_0x213a77,_0x360b53,_0x426d61){for(const _0x48e061 of this['source']['getOperations'](_0x213a77,_0x360b53))this['_handleOperation'](_0x48e061,_0x426d61);for(const _0x2e1ab3 of this['_diffRoots']['values']())_0x2e1ab3['markers']['clear']();for(const [_0x1a4a8c,_0x616d7f]of this['_markers']){this['_diffRoots']['get'](_0x616d7f['root']['rootName'])['markers']['set'](_0x1a4a8c,_0x616d7f['clone']());}const _0x42ed9a=new Map(),_0x46160e=new Map();for(const [_0x346f04,_0x39bc1b]of this['_diffRoots'])_0x42ed9a['set'](_0x346f04,T(_0x39bc1b)),_0x46160e['set'](_0x346f04,this['_diffRootsAttributes']['get'](_0x346f04));this['_saveMetaData'](_0x360b53,_0x42ed9a,this['_markers'],_0x46160e);}['_getPreviousFrom'](_0x364d38){const _0x2869b3=Array['from'](this['_savedMetaData']['keys']());_0x2869b3['sort']((_0x231c7c,_0x38bde8)=>_0x231c7c-_0x38bde8),_0x2869b3['reverse']();for(const _0x56e8cb of _0x2869b3)if(_0x56e8cb<_0x364d38)return _0x56e8cb;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x1f56e8,_0x32f1de){const _0x6e68e1=Array['from'](_0x32f1de['markers'])['map'](([_0x58611a,_0x6b8fed])=>[_0x58611a,this['_fixRange'](_0x6b8fed,_0x1f56e8)]);_0x1f56e8['markers']=new Map(_0x6e68e1);}['_transformMarkers'](_0xff0fdc){for(const _0x70c01f of this['_markers']['values']()){const _0x1aa500=_0x70c01f['getTransformedByOperation'](_0xff0fdc),_0x4e111a=vt['_createFromRanges'](_0x1aa500);_0x70c01f['start']=_0x4e111a['start'],_0x70c01f['end']=_0x4e111a['end'];}}['_handleOperation'](_0xc3f5e9,_0x3e1544){if('addRoot'!=_0xc3f5e9['type']&&'detachRoot'!=_0xc3f5e9['type']){if('insert'==_0xc3f5e9['type']){const _0x181279=_0xc3f5e9['position']['root']['rootName'];this['_diffRoots']['has'](_0x181279)||(this['_diffRoots']['set'](_0x181279,F(_0x181279,!0x0)),this['_diffRootsAttributes']['set'](_0x181279,{}),_0x3e1544&&this['_idsRoots']['set'](_0x181279,F(_0x181279,!0x0)));}else{if('addRootAttribute'==_0xc3f5e9['type']||'removeRootAttribute'==_0xc3f5e9['type']||'changeRootAttribute'==_0xc3f5e9['type'])return void this['_handleRootAttributeOperation'](_0xc3f5e9);'marker'==_0xc3f5e9['type']&&this['_handleMarkerOperation'](_0xc3f5e9);}if('marker'!==_0xc3f5e9['type']){const _0x265c15=this['_cloneOperation'](_0xc3f5e9,this['_diffRoots']);_0x265c15['_execute'](),this['_transformMarkers'](_0x265c15);}if(_0x3e1544)switch(_0xc3f5e9['type']){case'insert':this['_handleInsertOperation'](_0xc3f5e9);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0xc3f5e9);break;case'merge':this['_handleMergeOperation'](_0xc3f5e9);break;case'split':this['_handleSplitOperation'](_0xc3f5e9);}}else this['_handleRootOperation'](_0xc3f5e9,_0x3e1544);}['_cloneOperation'](_0x1c98db,_0x915c0d){const _0x10fda7=_0x1c98db['clone']();return _0x10fda7['_authorId']=_0x1c98db['_authorId'],this['_fixOperation'](_0x10fda7,_0x915c0d),_0x10fda7;}['_getBaseVids'](_0x541bd2){return _0x541bd2['map'](_0x5ac3ed=>{const _0x3474ce=this['_getVidAttributeName'](_0x5ac3ed);return Number(_0x5ac3ed['item']['getAttribute'](_0x3474ce));});}['_generateTape'](_0x16dcf0,_0x20704d){if(_0x16dcf0['is']('element','$text'))_0x20704d['push']({'item':_0x16dcf0,'type':'text'});else{_0x16dcf0['is']('element')&&_0x20704d['push']({'item':_0x16dcf0,'type':'elementStart'});for(const _0x1f0ca1 of _0x16dcf0['getChildren']())this['_generateTape'](_0x1f0ca1,_0x20704d);_0x16dcf0['is']('element')&&_0x20704d['push']({'item':_0x16dcf0,'type':'elementEnd'});}return _0x20704d;}['_getState'](){const _0x179da0=new Map(this['_touched']),_0x568400=new Map(_0x179da0),_0x5d452d=new Map(),_0xed1b54={'insertions':{},'deletions':{}},_0x51d2d0={'insertions':{},'deletions':{}},_0x2b58f0=new Map(),_0x3591ff=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x3591ff['delete']('$graveyard');for(const _0x39a716 of _0x3591ff){const _0x37341b=this['_diffRoots']['get'](_0x39a716)||F(_0x39a716,!0x1),_0x1971d0=this['_baseRoots']['get'](_0x39a716)||F(_0x39a716,!0x1);_0x37341b['isAttached']()||_0x1971d0['isAttached']()?(_0xed1b54['insertions'][_0x39a716]=T(_0x37341b),_0xed1b54['deletions'][_0x39a716]=T(_0x1971d0),this['_copyMarkers'](_0xed1b54['deletions'][_0x39a716],_0x1971d0),this['_copyMarkers'](_0xed1b54['insertions'][_0x39a716],_0x37341b),_0x51d2d0['insertions'][_0x39a716]=this['_generateTape'](this['_idsRoots']['get'](_0x39a716),[]),_0x51d2d0['deletions'][_0x39a716]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x39a716)||F(_0x39a716,!0x1),[])):_0x3591ff['delete'](_0x39a716);}for(const _0x582788 of _0x3591ff){const _0x5db6d8=_0x51d2d0['insertions'][_0x582788];for(const _0x529b25 of _0x5db6d8){const _0x2ca60e=this['_getVidAttributeName'](_0x529b25),_0x2b2f93=_0x529b25['item']['getAttribute'](_0x2ca60e);_0x568400['delete'](_0x2b2f93),_0x2b2f93>=this['_startingRevisionId']&&_0x5d452d['set'](_0x2b2f93,_0x179da0['get'](_0x2b2f93));}}for(const _0x32222a of _0x3591ff){const _0x19fd28=_0x51d2d0['insertions'][_0x32222a],_0x55bbf0=this['_getBaseVids'](_0x51d2d0['deletions'][_0x32222a]);let _0x1096e6=0x0;for(const _0x25e5ad of _0x19fd28){const _0x174f26=this['_getVidAttributeName'](_0x25e5ad),_0x15b9df=_0x25e5ad['item']['getAttribute'](_0x174f26);if(!_0x5d452d['has'](_0x15b9df)&&!_0x2b58f0['has'](_0x15b9df)){if(_0x568400['has'](_0x15b9df))_0x1096e6++;else{if(_0x15b9df!=_0x55bbf0[_0x1096e6]){const _0x4dceba=_0x179da0['get'](_0x15b9df)||_0x179da0['get'](_0x55bbf0[_0x1096e6]);for(;_0x15b9df!=_0x55bbf0[_0x1096e6];)_0x568400['has'](_0x55bbf0[_0x1096e6])||(_0x2b58f0['set'](_0x55bbf0[_0x1096e6],_0x4dceba),_0x179da0['set'](_0x55bbf0[_0x1096e6],_0x4dceba)),_0x1096e6++;}_0x1096e6++;}}}}for(const _0x4b4af6 of _0x3591ff){const _0x1f2da8=_0x51d2d0['insertions'][_0x4b4af6];for(const _0x3d4a0f of _0x1f2da8){const _0x17499d=this['_getVidAttributeName'](_0x3d4a0f),_0xe6da24=_0x3d4a0f['item']['getAttribute'](_0x17499d);if(_0x2b58f0['has'](_0xe6da24)){const _0x18b079=_0x2b58f0['get'](_0xe6da24);_0x568400['has'](_0xe6da24)||_0x568400['set'](_0xe6da24,{..._0x18b079}),_0x5d452d['set'](_0xe6da24,{..._0x18b079});}}}for(const _0x103dc9 of _0x568400['keys']())_0x103dc9>=this['_startingRevisionId']&&_0x568400['delete'](_0x103dc9);const _0x54a11e=new Map();for(const _0x5d5db6 of _0x3591ff){let _0x358cad=_0x51d2d0['insertions'][_0x5d5db6];for(const _0x339bc4 of _0x358cad)if(_0x339bc4['item']['is']('element','tableCell')){const _0x1e3b6e=this['_getVidAttributeName'](_0x339bc4),_0x2ef5fa=_0x339bc4['item']['getAttribute'](_0x1e3b6e);if(_0x5d452d['has'](_0x2ef5fa)){const _0x520ff0=_0x339bc4['item']['parent']['parent']['getAttribute']('vid_start'),_0x1ed212=_0x54a11e['get'](_0x520ff0)||new Set();_0x1ed212['add'](_0x5d452d['get'](_0x2ef5fa)['userId']),_0x54a11e['set'](_0x520ff0,_0x1ed212);}}_0x358cad=_0x51d2d0['deletions'][_0x5d5db6];for(const _0x55113b of _0x358cad)if(_0x55113b['item']['is']('element','tableCell')){const _0xcf065=this['_getVidAttributeName'](_0x55113b),_0x45cdba=_0x55113b['item']['getAttribute'](_0xcf065);if(_0x568400['has'](_0x45cdba)){const _0x30e720=_0x55113b['item']['parent']['parent']['getAttribute']('vid_start'),_0x54cd8b=_0x54a11e['get'](_0x30e720)||new Set();_0x54cd8b['add'](_0x568400['get'](_0x45cdba)['userId']),_0x54a11e['set'](_0x30e720,_0x54cd8b);}}for(const _0x260635 of _0x54a11e['keys']())(_0x5d452d['has'](_0x260635)||_0x568400['has'](_0x260635))&&_0x54a11e['delete'](_0x260635);}for(const _0x15c885 of _0x3591ff){const _0x492d26=_0x51d2d0['insertions'][_0x15c885];let _0x1c7870=null,_0x30c6d8=null;for(const _0x448d0b of _0x492d26){const _0x2ff34b=this['_getVidAttributeName'](_0x448d0b),_0x59c600=_0x448d0b['item']['getAttribute'](_0x2ff34b),_0x58fdb2=_0x54a11e['get'](_0x59c600);_0x58fdb2&&'elementStart'==_0x448d0b['type']&&(_0x1c7870=Array['from'](_0x58fdb2)[0x0],_0x30c6d8=_0x448d0b['item']['getAttribute']('vid_end')),_0x1c7870&&(_0x568400['set'](_0x59c600,{'userId':_0x1c7870}),_0x5d452d['set'](_0x59c600,{'userId':_0x1c7870})),_0x59c600==_0x30c6d8&&(_0x1c7870=null,_0x30c6d8=null);}}const _0x843b6e={},_0x12f15e=new Set();for(const _0x43ea2a of _0x3591ff){const _0x2d84f2=_0xed1b54['deletions'][_0x43ea2a],_0x5a82cb=_0xed1b54['insertions'][_0x43ea2a];for(const {userId:_0x72527f}of this['_touchedMarkers']['values']())null!==_0x72527f&&_0x12f15e['add'](_0x72527f);for(const {userId:_0x256de6}of this['_touchedRoots']['values']())null!==_0x256de6&&_0x12f15e['add'](_0x256de6);this['_markChanges'](_0x5a82cb,_0x51d2d0['insertions'][_0x43ea2a],_0x5d452d,'insertion',_0x12f15e),this['_markChanges'](_0x2d84f2,_0x51d2d0['deletions'][_0x43ea2a],_0x568400,'deletion',_0x12f15e),_0x843b6e[_0x43ea2a]={'insertions':this['_prepareViewToSave'](_0x5a82cb),'deletions':this['_prepareViewToSave'](_0x2d84f2),'attachChange':this['_touchedRoots']['get'](_0x43ea2a)||null,'attributesBefore':_0x3ec8e3(this['_baseRootsAttributes']['get'](_0x43ea2a))||{},'attributesAfter':_0x3ec8e3(this['_diffRootsAttributes']['get'](_0x43ea2a))};}return{'diffData':_0x843b6e,'authorsIds':Array['from'](_0x12f15e)};}['_processRootBeforeSave'](_0x1f859c){for(const [,_0x42d984]of _0x1f859c['markers']){const _0x1f4a82=_0x42d984['start']['getAncestors']()['filter'](_0x7c8d38=>'tableCell'==_0x7c8d38['name']);for(const _0x495fcc of _0x1f4a82)0x1==_0x495fcc['childCount']&&_0x495fcc['getChild'](0x0)['is']('element','paragraph')&&_0x495fcc['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x12d95d){this['_processRootBeforeSave'](_0x12d95d);const _0x3e1dfb=this['editor']['data']['toView'](_0x12d95d,{}),_0x275abd=Array['from'](_0x3e1dfb['getChildren']())['map'](_0x6411d5=>this['_getViewJson'](_0x6411d5));return JSON['stringify'](_0x275abd);}['_getViewJson'](_0x578010){if(_0x578010['is']('$text'))return _0x578010['data'];{const _0x1651bd=_0x578010;return{'type':Object['keys'](P)['find'](_0x264933=>_0x578010 instanceof P[_0x264933]),'name':_0x1651bd['name'],'attributes':Array['from'](_0x1651bd['getAttributes']()),'children':Array['from'](_0x1651bd['getChildren']())['map'](_0x4ea74a=>this['_getViewJson'](_0x4ea74a))};}}['_markChanges'](_0x40919a,_0x22c314,_0x12451a,_0x73943,_0x2988c0){let _0x2e6302=null,_0x2b767d=null,_0x4254f1=0x0;const _0x558830=this['editor']['model'];for(let _0x296e3b=0x0;_0x296e3b<_0x22c314['length'];_0x296e3b++){const _0x351374=this['_getVidAttributeName'](_0x22c314[_0x296e3b]),_0x3e6512=_0x22c314[_0x296e3b]['item']['getAttribute'](_0x351374),_0x356cd5=_0x12451a['get'](_0x3e6512),_0x3b1774=_0x296e3b==_0x22c314['length']-0x1;(!_0x2e6302&&_0x356cd5&&(_0x2e6302=_0x356cd5,_0x2b767d=_0x22c314[_0x296e3b]),_0x2e6302&&(!_0x356cd5||_0x356cd5['userId']!=_0x2e6302['userId']))&&(_0x2a9a71(_0x356cd5,B(_0x2b767d,_0x40919a,_0x558830),B(_0x22c314[_0x296e3b],_0x40919a,_0x558830)),_0x2e6302=_0x356cd5||null,_0x2b767d=_0x356cd5?_0x22c314[_0x296e3b]:null),_0x2e6302&&_0x3b1774&&_0x2a9a71(_0x356cd5,B(_0x2b767d,_0x40919a,_0x558830),J(_0x22c314[_0x296e3b],_0x40919a,_0x558830));}function _0x2a9a71(_0x7fc388,_0x27fea7,_0x3b1f7b){const _0x47f96f=_0x2e6302['userId'],_0x2369fc='revision:'+_0x73943+':'+_0x47f96f+':'+_0x4254f1++,_0x262867=_0x558830['createRange'](_0x27fea7,_0x3b1f7b);_0x40919a['markers']['set'](_0x2369fc,_0x262867),null!==_0x47f96f&&_0x2988c0['add'](_0x47f96f);}}['_getVidAttributeName'](_0xee216c){switch(_0xee216c['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x292efb,_0x3727d7){_0x292efb['baseVersion']=null;for(const _0x8f1e05 in _0x292efb){const _0x369618=_0x292efb[_0x8f1e05];if(_0x369618 instanceof gt){const _0x58e397=_0x3727d7['get'](_0x369618['root']['rootName']);_0x292efb[_0x8f1e05]=this['_fixPosition'](_0x369618,_0x58e397);}if(_0x369618 instanceof vt){const _0x5dbd2b=_0x3727d7['get'](_0x369618['root']['rootName']);_0x292efb[_0x8f1e05]=this['_fixRange'](_0x369618,_0x5dbd2b);}'root'===_0x8f1e05&&(_0x292efb['root']=_0x3727d7['get'](_0x292efb['root']['rootName']));}}['_fixRange'](_0x3400b0,_0x11658e){return this['editor']['model']['createRange'](this['_fixPosition'](_0x3400b0['start'],_0x11658e),this['_fixPosition'](_0x3400b0['end'],_0x11658e));}['_fixPosition'](_0x57f7e0,_0x2d37f2){return this['editor']['model']['createPositionFromPath'](_0x2d37f2,_0x57f7e0['path'],_0x57f7e0['stickiness']);}['_handleInsertOperation'](_0x5b3fca){const _0x46f2ce=this['_idsRoots']['get'](_0x5b3fca['position']['root']['rootName']),_0x20aeb2=this['_fixPosition'](_0x5b3fca['position'],_0x46f2ce),_0xb10a5b=null===_0x5b3fca['_authorId']?null:_0x5b3fca['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x3f4773=_0x20aeb2['parent'],_0x7061e=this['_revisionId'],_0x56d496=[];for(const _0x55432b of _0x5b3fca['nodes'])if(_0x55432b['is']('element'))_0x56d496['push'](this['_makeIdsRoot'](_0x55432b));else{for(let _0x24aae8=0x0;_0x24aae8<_0x55432b['offsetSize'];_0x24aae8++)_0x56d496['push'](new ft('$text',{'vid':this['_revisionId']++}));}const _0x6a86d8=this['_revisionId'];for(let _0x3c801f=_0x7061e;_0x3c801f<_0x6a86d8;_0x3c801f++)this['_touched']['set'](_0x3c801f,{'userId':_0xb10a5b});_0x3f4773['_insertChild'](_0x20aeb2['offset'],_0x56d496);}['_handleMoveOperation'](_0x56121a){(_0x56121a=this['_cloneOperation'](_0x56121a,this['_idsRoots']))['_execute']();const _0x2b31f2=null===_0x56121a['_authorId']?null:_0x56121a['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x37169b=_0x56121a['getMovedRangeStart'](),_0x456d0a=_0x37169b['parent'],_0xc041c6=_0x37169b['offset'];!function _0x378593(_0x449f90,_0x835c59,_0x865e13,_0x5572c0){for(let _0x34d173=_0x865e13;_0x34d173<_0x5572c0;_0x34d173++){const _0xac1a24=_0x835c59['getChild'](_0x34d173);_0xac1a24['is']('element','$text')?_0x449f90['set'](_0xac1a24['getAttribute']('vid'),{'userId':_0x2b31f2}):(_0x449f90['set'](_0xac1a24['getAttribute']('vid_start'),{'userId':_0x2b31f2}),_0x378593(_0x449f90,_0xac1a24,0x0,_0xac1a24['childCount']),_0x449f90['set'](_0xac1a24['getAttribute']('vid_end'),{'userId':_0x2b31f2}));}}(this['_touched'],_0x456d0a,_0xc041c6,_0xc041c6+_0x56121a['howMany']);}['_handleMergeOperation'](_0x4227c6){const _0x1d6882=null===(_0x4227c6=this['_cloneOperation'](_0x4227c6,this['_idsRoots']))['_authorId']?null:_0x4227c6['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x1df45e=_0x4227c6['targetPosition']['parent'],_0x415b46=_0x4227c6['sourcePosition']['parent'],_0x505fa3=_0x1df45e['getAttribute']('vid_end'),_0x3f5e8c=_0x415b46['getAttribute']('vid_start');_0x1df45e['_setAttribute']('vid_end',_0x415b46['getAttribute']('vid_end')),_0x415b46['_setAttribute']('vid_end',_0x505fa3),this['_touched']['set'](_0x3f5e8c,{'userId':_0x1d6882}),this['_touched']['set'](_0x505fa3,{'userId':_0x1d6882}),_0x4227c6['_execute']();}['_handleSplitOperation'](_0xb32deb){const _0x366c84=null===(_0xb32deb=this['_cloneOperation'](_0xb32deb,this['_idsRoots']))['_authorId']?null:_0xb32deb['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x955316=_0xb32deb['graveyardPosition'],_0x55098f=_0xb32deb['splitPosition']['parent'];_0xb32deb['_execute']();const _0x41b4ec=_0x55098f['getAttribute']('vid_end'),_0x3014b0=_0xb32deb['insertionPosition']['nodeAfter'];if(_0x955316){const _0x1ab803=_0x3014b0['getAttribute']('vid_end'),_0x4e0334=_0x55098f['getAttribute']('vid_end');_0x55098f['_setAttribute']('vid_end',_0x1ab803),_0x3014b0['_setAttribute']('vid_end',_0x4e0334),this['_touched']['set'](_0x55098f['getAttribute']('vid_end'),{'userId':_0x366c84}),this['_touched']['set'](_0x3014b0['getAttribute']('vid_start'),{'userId':_0x366c84});}else{const _0x6de0c3=this['_revisionId']++,_0x2ce3f0=this['_revisionId']++;_0x55098f['_setAttribute']('vid_end',_0x6de0c3),_0x3014b0['_setAttribute']('vid_start',_0x2ce3f0),_0x3014b0['_setAttribute']('vid_end',_0x41b4ec),this['_touched']['set'](_0x6de0c3,{'userId':_0x366c84}),this['_touched']['set'](_0x2ce3f0,{'userId':_0x366c84});}}['_handleMarkerOperation'](_0x693d55){if(!_0x693d55['affectsData'])return;const _0x8f07f4=(_0x693d55=this['_cloneOperation'](_0x693d55,this['_diffRoots']))['oldRange']?_0x693d55['oldRange']['root']:null,_0x36e774=_0x693d55['newRange']?_0x693d55['newRange']['root']:null;_0x8f07f4&&this['_markers']['delete'](_0x693d55['name']),_0x36e774&&this['_markers']['set'](_0x693d55['name'],_0x693d55['newRange']['clone']());const _0x5e52d5=null===_0x693d55['_authorId']?null:_0x693d55['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x347efe=_0x693d55['name'];if(!this['_touchedMarkers']['has'](_0x347efe))return void this['_touchedMarkers']['set'](_0x347efe,{'range':_0x693d55['oldRange'],'userId':_0x5e52d5});const _0x490587=this['_touchedMarkers']['get'](_0x347efe),_0x314afb=_0x490587['range'],_0x2a9e0f=_0x693d55['newRange'];null==_0x314afb&&null==_0x2a9e0f||_0x314afb&&_0x2a9e0f&&_0x314afb['isEqual'](_0x2a9e0f)?this['_touchedMarkers']['delete'](_0x693d55['name']):_0x490587['userId']=_0x5e52d5;}['_handleRootOperation'](_0x57c125,_0x5abd9b){this['_diffRoots']['has'](_0x57c125['rootName'])?this['_diffRoots']['get'](_0x57c125['rootName'])['_isAttached']=_0x57c125['isAdd']:(this['_diffRoots']['set'](_0x57c125['rootName'],F(_0x57c125['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x57c125['rootName'],{}),_0x5abd9b&&this['_idsRoots']['set'](_0x57c125['rootName'],F(_0x57c125['rootName'],!0x0)));const _0x509201=null===_0x57c125['_authorId']?null:_0x57c125['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x96574a=this['_touchedRoots']['get'](_0x57c125['rootName']);_0x96574a&&_0x96574a['userId']===_0x509201?this['_touchedRoots']['delete'](_0x57c125['rootName']):this['_touchedRoots']['set'](_0x57c125['rootName'],{'userId':_0x509201,'isAttached':_0x57c125['isAdd']});}['_handleRootAttributeOperation'](_0x4c8a97){const _0x417fbf=this['_diffRootsAttributes']['get'](_0x4c8a97['root']['rootName']);null===_0x4c8a97['newValue']?delete _0x417fbf[_0x4c8a97['key']]:_0x417fbf[_0x4c8a97['key']]=_0x4c8a97['newValue'];}}function T(_0x5a5014){const _0x4d4a49=F(_0x5a5014['rootName'],_0x5a5014['isAttached']());for(const _0x82f82f of _0x5a5014['getChildren']()){const _0xc993ba=_0x82f82f['_clone'](!0x0);_0x4d4a49['_appendChild'](_0xc993ba);}return _0x4d4a49;}function F(_0x3550af,_0x15f8fa=!0x0){const _0x239d75=new mt();return _0x239d75['rootName']=_0x3550af,_0x239d75['_isAttached']=_0x15f8fa,_0x239d75['isAttached']=()=>_0x239d75['_isAttached'],_0x239d75;}function B(_0x1e5796,_0x39c575,_0x43b627){const _0x241f3a='elementEnd'==_0x1e5796['type']?_0x43b627['createPositionAt'](_0x1e5796['item'],'end'):_0x43b627['createPositionBefore'](_0x1e5796['item']);return _0x43b627['createPositionFromPath'](_0x39c575,_0x241f3a['path'],_0x241f3a['stickiness']);}function J(_0xffe04a,_0x4e6270,_0x547bdf){const _0x579807='elementStart'==_0xffe04a['type']?_0x547bdf['createPositionAt'](_0xffe04a['item'],0x0):_0x547bdf['createPositionAfter'](_0xffe04a['item']);return _0x547bdf['createPositionFromPath'](_0x4e6270,_0x579807['path'],_0x579807['stickiness']);}class ns extends _0x3e310e{['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x4daf62,_0x70ebe3){super(_0x4daf62),this['focusTracker']=new _0x1b3465(),this['keystrokes']=new _0x220579(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x70ebe3),this['setTemplate']({'tag':'form','attributes':{'class':['ck','ck-revision-history-save-revision-form','ck-responsive-form'],'tabindex':'-1'},'children':[this['revisionNameInputView']]}),ts(this);}['render'](){super['render'](),_0x4f23d5({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x1529c7=_0x150222=>_0x150222['stopPropagation']();this['keystrokes']['set']('arrowright',_0x1529c7),this['keystrokes']['set']('arrowleft',_0x1529c7),this['keystrokes']['set']('arrowup',_0x1529c7),this['keystrokes']['set']('arrowdown',_0x1529c7);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x124f21){this['revisionNameInputView']['fieldView']['element']['value']=_0x124f21['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x23d434){const _0x53092a=new nt(this['locale'],_0x4aa70e),_0x242b93=_0x53092a['fieldView'];_0x242b93['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x4404a4=m(this['locale'],'Name\x20of\x20the\x20revision');return!_0x23d434&&(_0x4404a4+='\x20('+m(this['locale'],'optional')+')'),(_0x53092a['label']=_0x4404a4,_0x242b93['on']('input',()=>{this['revisionNameInputValue']=_0x242b93['element']['value']['trim']();}),_0x53092a);}}class u extends _0x50f6d6{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l];}['_saveRevisionFormView'];['init'](){const _0x14cdac=this['editor'],_0x297620=_0x14cdac['plugins']['get']('RevisionTracker');_0x14cdac['ui']['componentFactory']['add']('revisionHistory',_0x286a3f=>{const _0x2b5b7b=_0x1ffeb1(_0x286a3f),_0x1c3439=_0x2b5b7b['panelView']['children'],_0xe3458b=new te(_0x286a3f),_0x5e49f7=new _0xd41698(_0x286a3f),_0x10cf32=new _0x5baaae(_0x286a3f),_0x4e899e=new _0xd41698(_0x286a3f),_0x108963=new _0x5baaae(_0x286a3f);return _0x2b5b7b['bind']('isEnabled')['to'](_0x297620,'isReady',_0x297620,'isEnabled',_0x14cdac,'isReadOnly',(_0x59eeb9,_0x536777,_0x1fd23e)=>_0x59eeb9&&_0x536777&&!_0x1fd23e),_0x2b5b7b['buttonView']['set']({'icon':_0x5f52da['history'],'label':m(_0x286a3f,'Revision\x20history'),'tooltip':!0x0}),_0x10cf32['set']({'label':m(_0x286a3f,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x10cf32['bind']('isEnabled')['to'](_0x297620,'isReady',_0x297620,'isEnabled',_0x14cdac,'isReadOnly',(_0x3ff53a,_0x46bd0c,_0x354974)=>_0x3ff53a&&_0x46bd0c&&!_0x354974),_0x10cf32['on']('execute',()=>this['_showDialog']()),_0x108963['set']({'label':m(_0x286a3f,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x108963['bind']('isEnabled')['to'](_0x297620,'isReady',_0x14cdac,'isReadOnly',(_0x5aa347,_0x1215aa)=>_0x5aa347&&!_0x1215aa),_0x108963['on']('execute',()=>{_0x14cdac['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x2b5b7b['isOpen']=!0x1,_0x14cdac['editing']['view']['focus']();}),_0x5e49f7['children']['add'](_0x10cf32),_0x4e899e['children']['add'](_0x108963),_0xe3458b['role']='menu',_0xe3458b['items']['addMany']([_0x5e49f7,_0x4e899e]),_0x1c3439['add'](_0xe3458b),_0x2b5b7b;}),_0x14cdac['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x42f587=this['editor'],_0xdc4d8c=_0x42f587['locale'],_0x5f48d3=new _0x8b235b(_0xdc4d8c),_0x20ad82=new _0x239d23(_0xdc4d8c);_0x5f48d3['buttonView']['set']({'icon':_0x5f52da['history'],'label':m(_0xdc4d8c,'Revision\x20history')});const _0x36e118=new _0x3a50f7(_0xdc4d8c,_0x5f48d3),_0xc3ac5a=new _0x32f567(_0xdc4d8c);_0xc3ac5a['set']({'label':m(_0xdc4d8c,'Save\x20current\x20revision')}),_0xc3ac5a['delegate']('execute')['to'](_0x5f48d3),_0xc3ac5a['on']('execute',()=>{this['_showDialog']();}),_0x36e118['children']['add'](_0xc3ac5a),_0x20ad82['items']['add'](_0x36e118);const _0x4327a4=new _0x3a50f7(_0xdc4d8c,_0x5f48d3),_0x1559ba=new _0x32f567(_0xdc4d8c);return _0x1559ba['set']({'label':m(_0xdc4d8c,'Open\x20revision\x20history')}),_0x1559ba['delegate']('execute')['to'](_0x5f48d3),_0x1559ba['on']('execute',()=>{_0x42f587['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x4327a4['children']['add'](_0x1559ba),_0x20ad82['items']['add'](_0x4327a4),_0x5f48d3['panelView']['children']['add'](_0x20ad82),_0x5f48d3;}['_showDialog'](){const _0x4e9817=this['editor'],_0x2459eb=_0x4e9817['locale'],_0x2ec7d6=_0x4e9817['plugins']['get']('Dialog'),_0xc8af3c=_0x4e9817['plugins']['get']('RevisionTracker');function _0x298029(_0x2b54ca){_0x4e9817['config']['get']('revisionHistory.requireRevisionName')&&''===_0x2b54ca['revisionName']?_0x2b54ca['revisionNameInputView']['errorText']=m(_0x2459eb,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x4e9817['plugins']['get'](l)['saveRevision']({'name':_0x2b54ca['revisionName']}),_0x2ec7d6['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x298029(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x2ec7d6['show']({'id':'revisionSave','title':m(_0x2459eb,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':m(_0x4e9817['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x2ec7d6['hide']()},{'label':m(_0x4e9817['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x18ac62){_0x18ac62['bind']('isEnabled')['to'](_0xc8af3c,'isReady',_0xc8af3c,'isEnabled',_0x4e9817,'isReadOnly',(_0x566c35,_0x313ce2,_0x1b535f)=>_0x566c35&&_0x313ce2&&!_0x1b535f);},'onExecute':()=>_0x298029(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x27fcee=this['editor'],_0x333260=_0x27fcee['locale'];this['_saveRevisionFormView']=new ns(_0x333260,_0x27fcee['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class X extends _0x3e310e{['changeId'];['_model'];constructor(_0x9a6467,_0x2593de){super(_0x9a6467),this['_model']=_0x2593de,this['changeId']=_0x2593de['id'];const _0x39c7c7=this['bindTemplate'],_0x3e0327=m(_0x9a6467,_0x2593de['data']['isSuggestion']?'Suggested\x20by':'add'==_0x2593de['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x2593de['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x39c7c7['to']('type',_0x50e907=>'ck-revision-change__'+_0x50e907)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x3e0327}]},{'text':'\x20'+_0x2593de['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class r extends/* #__PURE__ -- @preserve */
25
+ _0x12c76e(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x191a2b){super(),this['id']=_0x191a2b['id']||_0x1fa053(),this['author']=_0x191a2b['author'],this['type']=_0x191a2b['type'],this['data']=_0x191a2b['data']||{},this['rootName']=_0x191a2b['rootName'],this['set']('createdAt',_0x191a2b['createdAt']);}['toJSON'](){return{'id':this['id'],'authorId':this['author']['id'],'type':this['type'],'data':this['data'],'createdAt':this['createdAt']};}}class f{['newRevisionId'];['oldRevisionId'];['changes'];constructor(_0x1368d9,_0x390b04){this['newRevisionId']=_0x1368d9,this['oldRevisionId']=_0x390b04,this['changes']=new _0xccc836();}['_setChanges'](_0x2a40bc){for(const _0x4972dc of _0x2a40bc)this['changes']['add'](_0x4972dc);}}const Y={'c':_0x290b4f,'a':_0x47add3,'e':_0x30b150,'r':_0x23e731,'u':_0x927dea};class d extends _0x50f6d6{['repository'];['adapter'];['_activeViewTarget'];['_changeView'];['_changeIdToChange'];['_balloon'];static get['pluginName'](){return'RevisionViewer';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[_0x191bf9,_0x570100,j];}constructor(_0x53cfd1){super(_0x53cfd1),this['repository']=this['editor']['plugins']['get']('RevisionsRepository'),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',(_0x4608bf,_0x469cec,_0x3d5090)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x568ae9=>{for(const _0x850839 of this['editor']['editing']['view']['document']['roots'])_0x3d5090?_0x568ae9['removeClass']('ck-editor__editable__overlay',_0x850839):_0x568ae9['addClass']('ck-editor__editable__overlay',_0x850839);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x20c0fa=>null!==_0x20c0fa),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x273fcd,_0x6cac0,_0x16b10f)=>_0x273fcd&&_0x16b10f?_0x6cac0['changes']['getIndex'](_0x16b10f):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x3c5045,_0x2e7425)=>_0x3c5045?_0x2e7425['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['adapter']=null,this['_balloon']=this['editor']['plugins']['get'](_0x570100);}['init'](){const _0x4139b8=this['editor'],_0x5c901c=new yt(_0x4139b8,{'direction':'backward'}),_0x195dd9=new yt(_0x4139b8,{'direction':'forward'});(_0x4139b8['commands']['add']('showPreviousChange',_0x5c901c),_0x4139b8['commands']['add']('showNextChange',_0x195dd9),_0x4139b8['commands']['add']('restoreRevision',new _t(_0x4139b8)),this['on']('change:numberOfChanges',()=>{_0x5c901c['refresh'](),_0x195dd9['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x4139b8['enableReadOnlyMode']('revision-viewer'),_0x4139b8['plugins']['has']('WidgetToolbarRepository'))&&_0x4139b8['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionData'](_0x1f9dab){await this['loadRevisionData'](_0x1f9dab);const _0x4249ec={};for(const _0x125131 in _0x1f9dab['diffData']){if(_0x1f9dab['diffData'][_0x125131]['attachChange']&&!_0x1f9dab['diffData'][_0x125131]['attachChange']['isAttached'])continue;const _0x15e9ea=this['_removeRevisionMarkers'](JSON['parse'](_0x1f9dab['diffData'][_0x125131]['insertions'])),_0x3716bb=this['editor']['editing']['view']['document'],_0x45738d=new _0x4c4bb9(_0x3716bb,_0x15e9ea['map'](_0x187eca=>this['_getViewObj'](_0x187eca)));this['editor']['data']['processor']['useFillerType']('marked'),_0x4249ec[_0x125131]=this['editor']['data']['processor']['toData'](_0x45738d),this['editor']['data']['processor']['useFillerType']('default');}return _0x4249ec;}async['getRevisionRootsAttributes'](_0x8c2aaf){await this['loadRevisionData'](_0x8c2aaf);const _0x38e3f0={};for(const _0x3a31fc in _0x8c2aaf['diffData'])_0x8c2aaf['diffData'][_0x3a31fc]['attachChange']&&!_0x8c2aaf['diffData'][_0x3a31fc]['attachChange']['isAttached']||(_0x38e3f0[_0x3a31fc]=_0x8c2aaf['diffData'][_0x3a31fc]['attributesAfter']||{});return _0x38e3f0;}['_removeRevisionMarkers'](_0x1f3274){return(_0x1f3274=_0x1f3274['filter'](_0x309753=>!_0x309753['name']||'revision-start'!==_0x309753['name']&&'revision-end'!==_0x309753['name']))['forEach'](_0xbccee1=>{'string'!=typeof _0xbccee1&&(_0xbccee1['children']=this['_removeRevisionMarkers'](_0xbccee1['children']),_0xbccee1['attributes']=_0xbccee1['attributes']['filter'](_0x47f9ab=>!_0x47f9ab[0x0]['startsWith']('data-revision-')));}),_0x1f3274;}async['compare'](_0x2e20c4,_0x407d21,_0x1910b9=!0x1){if(!this['isEnabled'])return;const _0x42b207=this['diff'],_0x1538d1=this['repository'],_0x50fcc9='string'==typeof _0x2e20c4?_0x1538d1['getRevision'](_0x2e20c4):_0x2e20c4,_0x5c194a='string'==typeof _0x407d21?_0x1538d1['getRevision'](_0x407d21):_0x407d21,_0x4d2a68=_0x50fcc9['id'],_0x25cd74=_0x5c194a?_0x5c194a['id']:null;if(!_0x1910b9&&this['diff']&&this['diff']['newRevisionId']===_0x4d2a68&&this['diff']['oldRevisionId']===_0x25cd74)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new f(_0x4d2a68,_0x25cd74);const _0x5adbd4=this['_getRevisionsRange'](_0x50fcc9,_0x5c194a,!0x0)['map'](_0x2848dc=>this['loadRevisionData'](_0x2848dc));return _0x5adbd4['push'](new Promise(_0x1f2f43=>{setTimeout(_0x1f2f43,0x14);})),Promise['all'](_0x5adbd4)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x1d3366=this['_getDiff'](_0x4d2a68,_0x25cd74);for(const _0x20bb02 of _0x1d3366['changes'])this['_changeIdToChange']['set'](_0x20bb02['id'],_0x20bb02);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x56c649=>{for(const _0x41c49a of this['editor']['model']['document']['getRootNames']())_0x56c649['detachRoot'](_0x41c49a);for(const _0x300774 of Object['keys'](_0x1d3366['model'])){const _0x48b8ca=_0x56c649['addRoot'](_0x300774);for(const _0x57dd8d of Object['keys'](_0x1d3366['attributes'][_0x300774]))_0x56c649['setAttribute'](_0x57dd8d,_0x1d3366['attributes'][_0x300774][_0x57dd8d],_0x48b8ca);_0x56c649['insert'](_0x1d3366['model'][_0x300774],_0x48b8ca,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x1d3366['changes'])),this['isReady']=!0x0;})['catch'](_0x2d23b2=>{console['error'](_0x2d23b2),this['_cleanUp'](),_0x42b207&&(this['diff']=_0x42b207),this['isReady']=!0x0;});}['addRevisionData'](_0x39aaba,_0x4087a0){const _0x48cce2=this['repository']['createRevision'](_0x39aaba);return _0x48cce2['on']('_update',(_0x1def43,_0x5c7d4d,_0x4fe1ea)=>_0x4087a0(_0x5c7d4d,_0x4fe1ea,_0x48cce2)),this['repository']['addRevision'](_0x48cce2),_0x48cce2;}['loadRevisionData'](_0x2ad242){if(!_0x2ad242||_0x2ad242['diffData'])return Promise['resolve']();{const _0x201cbd=this['editor']['config']['get']('collaboration.channelId');return this['adapter']['getRevision']({'channelId':_0x201cbd,'revisionId':_0x2ad242['id']})['then'](_0x3ff93d=>{_0x2ad242['_update']({'diffData':_0x3ff93d['diffData']},!0x0);});}}['_cleanUp'](){this['activeChange']=null,this['_cleanMarkers'](),this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=null,this['_changeIdToChange']['clear'](),this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x50ddf6=>{for(const _0x54d5b9 of this['editor']['model']['document']['getRootNames']())_0x50ddf6['detachRoot'](_0x54d5b9);});}['_sortAndFilterDiffChanges'](_0x4f9506){const _0xf00741=[],_0x2d17e3=new Map();for(const _0x10287b of this['editor']['model']['document']['getRootNames']()){const _0x3c2611=this['editor']['editing']['view']['getDomRoot'](_0x10287b);if(!_0x3c2611)continue;const _0x417825=_0x3c2611['getClientRects']()['item'](0x0);_0x417825&&(_0xf00741['push'](_0x10287b),_0x2d17e3['set'](_0x10287b,_0x417825));}return _0xf00741['sort']((_0xcad583,_0x17da45)=>{const _0x16f8f3=_0x2d17e3['get'](_0xcad583),_0x31b1c1=_0x2d17e3['get'](_0x17da45);return _0x16f8f3['y']-_0x31b1c1['y']||_0x16f8f3['x']-_0x31b1c1['x'];}),(_0x4f9506=_0x4f9506['filter'](_0x55895a=>_0xf00741['includes'](_0x55895a['rootName'])))['sort']((_0xeb926f,_0x1d9384)=>_0xf00741['indexOf'](_0xeb926f['rootName'])-_0xf00741['indexOf'](_0x1d9384['rootName'])),_0x4f9506;}['_makeTape'](_0x5a2827){const _0x513634=Array['from'](_0x5a2827['markers'])['filter'](([_0x8053f5,_0x4ce322])=>_0x8053f5['startsWith']('revision:')&&!_0x4ce322['isCollapsed']),_0x138eb1=Array['from'](this['editor']['model']['createRangeIn'](_0x5a2827)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x513634['length'])for(const _0xe14882 of _0x138eb1){const [_0x27ac9d,_0x19e8f7]=_0x513634[0x0],[,_0x17524b,_0x1e3ba8]=_0x27ac9d['split'](':');if(_0x19e8f7['end']['isEqual'](_0xe14882['nextPosition'])&&_0x513634['shift'](),(_0xe14882['previousPosition']['isEqual'](_0x19e8f7['start'])||_0xe14882['previousPosition']['isAfter'](_0x19e8f7['start']))&&('insertion'==_0x17524b?_0xe14882['isAdded']={'userId':_0x1e3ba8}:'deletion'==_0x17524b&&(_0xe14882['isRemoved']={'userId':_0x1e3ba8})),0x0==_0x513634['length'])break;}return _0x138eb1;}['_refreshStartEndIndex'](_0x1b07d8){const _0x351784=new Map();for(let _0xb519e=0x0;_0xb519e<_0x1b07d8['length'];_0xb519e++)'text'===_0x1b07d8[_0xb519e]['type']?(_0x1b07d8[_0xb519e]['item']['startIndex']=_0xb519e,_0x1b07d8[_0xb519e]['item']['endIndex']=_0xb519e):('elementStart'===_0x1b07d8[_0xb519e]['type']?_0x1b07d8[_0xb519e]['item']['startIndex']=_0xb519e:'elementEnd'===_0x1b07d8[_0xb519e]['type']&&(_0x1b07d8[_0xb519e]['item']['endIndex']=_0xb519e),_0x351784['set'](_0x1b07d8[_0xb519e]['id'],_0xb519e));for(const _0x48b4 of _0x351784['values']())'elementStart'===_0x1b07d8[_0x48b4]['type']?_0x1b07d8[_0x48b4]['item']['endIndex']=_0x351784['get'](_0x1b07d8[_0x48b4]['pairId']):'elementEnd'===_0x1b07d8[_0x48b4]['type']&&(_0x1b07d8[_0x48b4]['item']['startIndex']=_0x351784['get'](_0x1b07d8[_0x48b4]['pairId']));}['_processTape'](_0x1160f1){for(let _0x25d448=0x0;_0x25d448<_0x1160f1['length'];_0x25d448++){if('elementStart'===_0x1160f1[_0x25d448]['type'])_0x1160f1[_0x25d448]['item']['startIndex']=_0x25d448;else{if('elementEnd'===_0x1160f1[_0x25d448]['type']){_0x1160f1[_0x25d448]['item']['endIndex']=_0x25d448;const _0x306c43=_0x1160f1[_0x25d448]['item']['startIndex'];_0x1160f1[_0x306c43]['pairId']=_0x1160f1[_0x25d448]['id'],_0x1160f1[_0x25d448]['pairId']=_0x1160f1[_0x306c43]['id'];}else _0x1160f1[_0x25d448]['item']['startIndex']=_0x25d448,_0x1160f1[_0x25d448]['item']['endIndex']=_0x25d448,_0x1160f1[_0x25d448]['pairId']=null;}_0x1160f1[_0x25d448]['markersStart']||(_0x1160f1[_0x25d448]['markersStart']=[],_0x1160f1[_0x25d448]['markersEnd']=[]);}}['_markInsertions'](_0x1ed618,_0xaa37b3){const _0x5af395=_0x1ed618['filter'](_0x109ee9=>!_0x109ee9['isAdded']);for(let _0x12609a=0x0;_0x12609a<_0xaa37b3['length'];_0x12609a++)_0xaa37b3[_0x12609a]['isAdded']&&(_0x5af395[_0x12609a]['isAdded']=_0xaa37b3[_0x12609a]['isAdded']);}['_makeModelFromViewString'](_0x3cde19){const _0x2f667e=JSON['parse'](_0x3cde19),_0x4db162=this['editor']['editing']['view']['document'],_0x2c4f09=new _0x4c4bb9(_0x4db162,_0x2f667e['map'](_0x28dcaf=>this['_getViewObj'](_0x28dcaf)));return this['editor']['data']['toModel'](_0x2c4f09);}['_getViewObj'](_0x2a7b8d){const _0x4913ea=this['editor']['editing']['view']['document'];if('string'==typeof _0x2a7b8d)return new _0x601889(_0x4913ea,_0x2a7b8d);{const _0x2fde0f=_0x2a7b8d['children']['map'](_0x3ebe43=>this['_getViewObj'](_0x3ebe43));return new(Y[_0x2a7b8d['type']]||_0x38a4ac)(_0x4913ea,_0x2a7b8d['name'],_0x2a7b8d['attributes'],_0x2fde0f);}}['_getDiff'](_0xefd2d3,_0x231986=null){const _0x1bf922=this['repository']['getRevision'](_0xefd2d3),_0x222f12=_0x231986?this['repository']['getRevision'](_0x231986):null,_0x56ebeb=this['_getRevisionsRange'](_0x1bf922,_0x222f12),_0x21b8e9=_0x56ebeb[_0x56ebeb['length']-0x1],_0x79b134=new Map(),_0x1093c0={'model':{},'attributes':{},'changes':[]},_0x3dffc4=new Set(),_0x1031b1=new Map();for(let _0x1ae163=_0x56ebeb['length']-0x1;_0x1ae163>=0x0;_0x1ae163--){const _0x5352f6=_0x56ebeb[_0x1ae163];for(const _0x3f6034 of Object['keys'](_0x5352f6['diffData']))if(_0x5352f6['diffData'][_0x3f6034]['attachChange']){const _0x32195d=_0x5352f6['diffData'][_0x3f6034]['attachChange'];_0x32195d['isAttached']?(_0x3dffc4['add'](_0x3f6034),_0x1031b1['has'](_0x3f6034)&&_0x1031b1['get'](_0x3f6034)['userId']==_0x32195d['userId']?_0x1031b1['delete'](_0x3f6034):_0x1031b1['set'](_0x3f6034,_0x32195d)):_0x1031b1['has'](_0x3f6034)?(_0x3dffc4['delete'](_0x3f6034),_0x1031b1['delete'](_0x3f6034)):(_0x3dffc4['add'](_0x3f6034),_0x1031b1['set'](_0x3f6034,_0x32195d));}else _0x3dffc4['add'](_0x3f6034);}for(const _0x3d16c5 of _0x3dffc4){const _0x1bdde3=_0x1031b1['has'](_0x3d16c5)&&!_0x1031b1['get'](_0x3d16c5)['isAttached'];let _0x174e5e=_0x1bdde3?_0x56ebeb['length']-0x1:0x0;const _0x219334=_0x1bdde3?-0x1:0x1;for(;_0x56ebeb[_0x174e5e];){const _0x4c2f6a=_0x56ebeb[_0x174e5e];if(_0x4c2f6a['diffData'][_0x3d16c5]){const _0x58c1a9=_0x1bdde3?_0x4c2f6a['diffData'][_0x3d16c5]['attributesBefore']:_0x4c2f6a['diffData'][_0x3d16c5]['attributesAfter'];_0x1093c0['attributes'][_0x3d16c5]=_0x58c1a9?_0x3ec8e3(_0x58c1a9):{};break;}_0x174e5e+=_0x219334;}}for(const _0x1680a0 of _0x56ebeb){_0x1680a0['model']={};for(const _0xe2b932 of _0x1680a0['authors'])_0x79b134['set'](_0xe2b932['id'],_0xe2b932);for(const _0x4cfd19 of _0x3dffc4){const _0x3def04=_0x1680a0['diffData'][_0x4cfd19]?_0x1680a0['diffData'][_0x4cfd19]['insertions']:'[]',_0x4b6786=_0x1680a0['diffData'][_0x4cfd19]?_0x1680a0['diffData'][_0x4cfd19]['deletions']:'[]';_0x1680a0['model'][_0x4cfd19]={'insertions':this['_makeModelFromViewString'](_0x3def04),'deletions':this['_makeModelFromViewString'](_0x4b6786)};}}for(const _0x7c0655 of _0x3dffc4){let _0x1cef38=null,_0x59ab4a=0x0;const _0x5ebef7=new Map(Array['from'](_0x1bf922['model'][_0x7c0655]['insertions']['markers'])['filter'](([_0x3f3338])=>!_0x3f3338['startsWith']('revision:')));let _0x4ea192=0x0;for(const _0x36e69a of _0x56ebeb){const _0x1877ad=this['_makeTape'](_0x36e69a['model'][_0x7c0655]['insertions']);_0x36e69a==_0x1bf922?(_0x1cef38=_0x1877ad,_0x59ab4a=_0x1cef38['length'],_0x1cef38['forEach'](_0x31d1e3=>{_0x31d1e3['id']=_0x4ea192++;}),this['_processTape'](_0x1cef38)):this['_markInsertions'](_0x1cef38,_0x1877ad);const _0x2dd9ff=_0x1cef38['filter'](_0x5a634c=>!_0x5a634c['isAdded'])['map'](_0x489716=>_0x489716['id']);let _0x45fef0=0x0;const _0x1d6c3f=this['_makeTape'](_0x36e69a['model'][_0x7c0655]['deletions']);_0x1d6c3f['forEach'](_0x18abd6=>{_0x18abd6['isRemoved']?_0x18abd6['id']=_0x59ab4a++:_0x18abd6['id']=_0x2dd9ff[_0x45fef0++];}),this['_processTape'](_0x1d6c3f),this['_setDistance'](_0x1cef38,'isAdded'),this['_setDistance'](_0x1d6c3f,'isRemoved'),_0x36e69a==_0x1bf922&&this['_markMarkers'](_0x1cef38,_0x5ebef7),_0x1cef38=this['_joinTapes'](_0x1cef38,_0x1d6c3f),this['_refreshStartEndIndex'](_0x1cef38),this['_setDistance'](_0x1cef38,'isRemoved');}_0x1cef38=_0x1cef38['filter'](_0x7cf583=>!(_0x7cf583['isAdded']&&_0x7cf583['isRemoved']));const _0x2485a9=new Map(_0x21b8e9['model'][_0x7c0655]['deletions']['markers']),_0x57e223=new Set(_0x5ebef7['keys']());for(const _0x47d47e of _0x2485a9['keys']())_0x57e223['delete'](_0x47d47e);this['_markSuggestions'](_0x1cef38,_0x57e223),this['_fixObsoleteTags'](_0x1cef38),_0x1cef38=this['_removeMissingPairs'](_0x1cef38),_0x1cef38=this['_markMismatchedRemovedTags'](_0x1cef38),_0x1cef38=this['_removeUnsupportedChanges'](_0x1cef38);const {root:_0x2107d7,changes:_0x309424}=this['_makeModelFromTape'](_0x1cef38,_0x79b134,_0x7c0655);_0x1093c0['model'][_0x7c0655]=_0x2107d7;const _0x37f74f=_0x1031b1['get'](_0x7c0655);if(_0x37f74f){const _0x4e6253=_0x79b134['get'](_0x37f74f['userId']),_0x2a0915=new r({'author':_0x4e6253,'type':_0x37f74f['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x7c0655});_0x309424['unshift'](_0x2a0915),_0x1093c0['attributes'][_0x7c0655]['revisionHistoryAttachChange']=_0x2a0915['id'];}_0x1093c0['changes']=_0x1093c0['changes']['concat'](_0x309424);}return _0x1093c0;}['_markMarkers'](_0xf1a601,_0x2d9705){for(let _0x496547=0x0;_0x496547<_0xf1a601['length'];_0x496547++)for(const [_0x4acdc9,_0x2be6b1]of _0x2d9705)_0x2be6b1['start']['isEqual'](_0xf1a601[_0x496547]['previousPosition'])&&_0xf1a601[_0x496547]['markersStart']['push'](_0x4acdc9),_0x2be6b1['end']['isEqual'](_0xf1a601[_0x496547]['nextPosition'])&&_0xf1a601[_0x496547]['markersEnd']['push'](_0x4acdc9);}['_joinTapes'](_0x5a39f9,_0x564573){let _0x28055f=[],_0x1479b9=0x0,_0xc61dc0=0x0;for(;_0x1479b9<_0x5a39f9['length']||_0xc61dc0<_0x564573['length'];){const _0x21fd4f=_0x5a39f9[_0x1479b9]||{},_0x4496cd=_0x564573[_0xc61dc0]||{};if(_0x21fd4f['id']==_0x4496cd['id'])_0x1479b9++,_0xc61dc0++,_0x28055f['push'](_0x21fd4f);else{if(_0x4496cd['isRemoved']&&_0x21fd4f['isAdded']){const {commonTape:_0x549822,iEnd:_0x393bad,jEnd:_0x3c8800}=this['_threeWayMerge'](_0x5a39f9,_0x1479b9,_0x564573,_0xc61dc0);_0x28055f=_0x28055f['concat'](_0x549822),_0x1479b9=_0x393bad,_0xc61dc0=_0x3c8800;}else _0x4496cd['isRemoved']?(_0xc61dc0++,_0x28055f['push'](_0x4496cd)):(_0x1479b9++,_0x28055f['push'](_0x21fd4f));}}return _0x28055f;}['_markSuggestions'](_0x32e3c6,_0x4ed981){const _0x14d9a5=[];for(let _0x1997d1=0x0;_0x1997d1<_0x32e3c6['length'];_0x1997d1++){for(let _0x183e7f=0x0;_0x183e7f<_0x32e3c6[_0x1997d1]['markersStart']['length'];_0x183e7f++){const _0xc84a6d=_0x32e3c6[_0x1997d1]['markersStart'][_0x183e7f];if(!_0x4ed981['has'](_0xc84a6d))continue;const {group:_0x20f4c9,type:_0x24cdf5,authorId:_0x40781d}=_0x3dc83c(_0xc84a6d);'revision-suggestion'!=_0x20f4c9||'insertion'!=_0x24cdf5&&'deletion'!=_0x24cdf5||(_0x14d9a5['unshift']({'type':_0x24cdf5,'name':_0xc84a6d,'userId':_0x40781d}),_0x32e3c6[_0x1997d1]['markersStart']['splice'](_0x183e7f,0x1),_0x183e7f--);}_0x20c1fe(_0x32e3c6[_0x1997d1]);for(let _0x34d6d0=0x0;_0x34d6d0<_0x32e3c6[_0x1997d1]['markersEnd']['length'];_0x34d6d0++){const _0x4da40b=_0x32e3c6[_0x1997d1]['markersEnd'][_0x34d6d0];if(!_0x4ed981['has'](_0x4da40b))continue;const {group:_0x576a76,type:_0x76e874}=_0x3dc83c(_0x4da40b);if('revision-suggestion'!=_0x576a76||'insertion'!=_0x76e874&&'deletion'!=_0x76e874)continue;_0x32e3c6[_0x1997d1]['markersEnd']['splice'](_0x34d6d0,0x1),_0x34d6d0--;const _0x52fb10=_0x14d9a5['findIndex'](_0x119bd8=>_0x119bd8['name']==_0x4da40b);_0x52fb10>-0x1&&_0x14d9a5['splice'](_0x52fb10,0x1);}}function _0x3dc83c(_0x800847){const _0x4946a0=_0x800847['split'](':');return{'group':_0x4946a0[0x0],'type':_0x4946a0[0x1],'subType':_0x4946a0['length']>=0x5?_0x4946a0[0x2]:null,'id':_0x4946a0['length']<0x5?_0x4946a0[0x2]:_0x4946a0[0x3],'authorId':_0x4946a0['length']<0x5?_0x4946a0[0x3]:_0x4946a0[0x4],'markerCount':0x6==_0x4946a0['length']?_0x4946a0[0x5]:null};}function _0x20c1fe(_0x4065d2){for(let _0xb7381b=0x0;_0xb7381b<_0x14d9a5['length'];_0xb7381b++){if(_0x4065d2['isAdded']&&'insertion'==_0x14d9a5[_0xb7381b]['type'])return _0x4065d2['isAddSuggestion']=_0x14d9a5[_0xb7381b],void delete _0x4065d2['isAdded'];if(!_0x4065d2['isAdded']&&!_0x4065d2['isRemoved']&&'deletion'==_0x14d9a5[_0xb7381b]['type'])return void(_0x4065d2['isRemoveSuggestion']=_0x14d9a5[_0xb7381b]);}}}['_setDistance'](_0x17b184,_0x2d7bca){let _0x448e55=0x0,_0x48e06e=!0x1;const _0x46f13b=new Map();for(const _0x2dabc3 of _0x17b184)_0x2dabc3[_0x2d7bca]?_0x48e06e&&(_0x448e55++,_0x48e06e=!0x1):(_0x448e55++,_0x48e06e=!0x0),_0x46f13b['set'](_0x2dabc3['id'],_0x448e55);for(let _0x5be46b=0x0;_0x5be46b<_0x17b184['length'];_0x5be46b++){if('isRemoved'==_0x2d7bca&&_0x17b184[_0x5be46b]['isAdded']||'isAdded'==_0x2d7bca&&_0x17b184[_0x5be46b]['isRemoved'])continue;if('text'==_0x17b184[_0x5be46b]['type']){_0x17b184[_0x5be46b]['distance']=0x0;continue;}const _0x4654ac=_0x46f13b['get'](_0x17b184[_0x5be46b]['pairId']),_0x1a7780=_0x46f13b['get'](_0x17b184[_0x5be46b]['id']);_0x17b184[_0x5be46b]['distance']=_0x4654ac-_0x1a7780;}}['_getRevisionsRange'](_0x1d5adf,_0x498500,_0x1b23a2=!0x1){const _0x3d741e=[];let _0x4daa3d=this['repository']['getIndex'](_0x1d5adf),_0x336a46=this['repository']['getIndex'](_0x498500);for(-0x1==_0x336a46&&(_0x336a46=this['repository']['_revisions']['length'],_0x1b23a2=!0x1);_0x4daa3d<_0x336a46;)_0x3d741e['push'](this['repository']['getRevision'](_0x4daa3d)),_0x4daa3d++;return _0x1b23a2&&_0x3d741e['push'](this['repository']['getRevision'](_0x4daa3d)),_0x3d741e;}['_threeWayMerge'](_0x524af1,_0x5ccbc7,_0x3039b1,_0x42160b){const _0x8d5f4b=this['editor']['model']['schema'];let _0x460821=_0x5ccbc7;for(;_0x524af1[_0x460821]&&_0x524af1[_0x460821]['isAdded'];)_0x460821++;let _0x4d9834=_0x42160b;for(;_0x3039b1[_0x4d9834]&&_0x3039b1[_0x4d9834]['isRemoved'];)_0x4d9834++;_0x2ace58(_0x524af1,_0x5ccbc7,_0x460821),_0x2ace58(_0x3039b1,_0x42160b,_0x4d9834);const _0x31b526=_0x3039b1['slice'](_0x42160b,_0x4d9834)['concat'](_0x524af1['slice'](_0x5ccbc7,_0x460821));return _0x31b526['sort']((_0x226c2d,_0x2c2086)=>_0x226c2d['side']!=_0x2c2086['side']?_0x226c2d['side']-_0x2c2086['side']:_0x226c2d['level']!=_0x2c2086['level']?_0x226c2d['level']-_0x2c2086['level']:_0x226c2d['distance']!=_0x2c2086['distance']?_0x2c2086['distance']-_0x226c2d['distance']:!!_0x226c2d['isAdded']!=!!_0x2c2086['isAdded']?-0x1==_0x226c2d['side']||0x0==_0x226c2d['side']?_0x226c2d['isAdded']?-0x1:0x1:_0x226c2d['isAdded']?0x1:-0x1:_0x226c2d['index']-_0x2c2086['index']),{'commonTape':_0x31b526,'iEnd':_0x460821,'jEnd':_0x4d9834};function _0x2ace58(_0x594a6b,_0x356618,_0xa2207a){let _0x476b35=-0x1,_0x852f15=Number['POSITIVE_INFINITY'],_0x12447a=!0x0;for(let _0x52ae23=_0x356618;_0x52ae23<_0xa2207a;_0x52ae23++)if(_0x8d5f4b['isInline'](_0x594a6b[_0x52ae23]['item'])||(_0x12447a=!0x1),_0x594a6b[_0x52ae23]['item']['startIndex']<_0x356618&&(_0x476b35=_0x52ae23),_0x594a6b[_0x52ae23]['item']['endIndex']>=_0xa2207a){_0x852f15=_0x52ae23;break;}_0x12447a&&(_0x476b35=_0xa2207a-0x1);for(let _0x54c347=_0x356618;_0x54c347<_0xa2207a;_0x54c347++)_0x594a6b[_0x54c347]['side']=_0x54c347<=_0x476b35?-0x1:_0x54c347<_0x852f15?0x0:0x1,_0x594a6b[_0x54c347]['index']=_0x54c347;let _0x136cf5=0x0;for(let _0x101f45=_0x356618;_0x101f45<=_0x476b35;_0x101f45++)0x0==_0x594a6b[_0x101f45]['distance']?_0x594a6b[_0x101f45]['level']=_0x136cf5:(_0x136cf5++,_0x594a6b[_0x101f45]['level']=_0x136cf5,_0x136cf5++);for(let _0x36991a=_0x356618;_0x36991a<_0xa2207a;_0x36991a++)0x0==_0x594a6b[_0x36991a]['side']&&(_0x594a6b[_0x36991a]['level']=_0x136cf5);_0x136cf5=0x0;for(let _0x4b9595=_0xa2207a-0x1;_0x4b9595>=_0x852f15;_0x4b9595--)0x0==_0x594a6b[_0x4b9595]['distance']?_0x594a6b[_0x4b9595]['level']=_0x136cf5:(_0x136cf5--,_0x594a6b[_0x4b9595]['level']=_0x136cf5,_0x136cf5--);}}['_fixObsoleteTags'](_0x4807ed){const _0x4c6d27=new Map(),_0x2cdf45=this['editor']['model']['schema'];for(let _0x194114=0x1;_0x194114<_0x4807ed['length'];_0x194114++){let _0x12fe3f,_0x5a124e,_0x44fc57;const _0x1d0646=_0x4807ed[_0x194114],_0x36b1fc=_0x4807ed[_0x194114-0x1];if('text'==_0x1d0646['type'])continue;if(_0x1d0646['type']!=_0x36b1fc['type'])continue;if(!_0x2cdf45['isBlock'](_0x36b1fc['item'])||_0x2cdf45['isLimit'](_0x36b1fc['item']))continue;if(!_0x2cdf45['isBlock'](_0x1d0646['item'])||_0x2cdf45['isLimit'](_0x1d0646['item']))continue;if((_0x4807ed[_0x194114]['isAdded']||_0x4807ed[_0x194114]['isAddSuggestion'])&&_0x4807ed[_0x194114-0x1]['isRemoved'])_0x12fe3f=_0x4807ed[_0x194114],_0x5a124e=_0x4807ed[_0x194114-0x1],_0x44fc57=_0x194114-0x1;else{if(!_0x4807ed[_0x194114]['isRemoved']||!_0x4807ed[_0x194114-0x1]['isAdded']&&!_0x4807ed[_0x194114-0x1]['isAddSuggestion'])continue;_0x12fe3f=_0x4807ed[_0x194114-0x1],_0x5a124e=_0x4807ed[_0x194114],_0x44fc57=_0x194114;}const _0x593ca7=_0x12fe3f['level']==_0x5a124e['level'],_0x2e026e=Math['abs'](_0x12fe3f['level'])<Math['abs'](_0x5a124e['level'])&&0x0==_0x5a124e['distance'];(_0x593ca7||_0x2e026e)&&(_0x4c6d27['set'](_0x5a124e['id'],_0x12fe3f['id']),_0x4807ed['splice'](_0x44fc57,0x1),_0x194114--,_0x12fe3f['isAdded']=!0x1);}for(let _0x5d1257=0x0;_0x5d1257<_0x4807ed['length'];_0x5d1257++)_0x4c6d27['has'](_0x4807ed[_0x5d1257]['pairId'])&&(_0x4807ed[_0x5d1257]['pairId']=_0x4c6d27['get'](_0x4807ed[_0x5d1257]['pairId']));}['_removeMissingPairs'](_0x2698a4){const _0x18d30e=new Set(_0x2698a4['map'](_0x25e462=>_0x25e462['id']));for(let _0x371d2c=0x0;_0x371d2c<_0x2698a4['length'];_0x371d2c++)_0x18d30e['has'](_0x2698a4[_0x371d2c]['pairId'])||0x0==_0x2698a4[_0x371d2c]['distance']||(_0x2698a4[_0x371d2c]['isIncorrect']=!0x0);return _0x2698a4['filter'](_0x170ca3=>!_0x170ca3['isIncorrect']);}['_markMismatchedRemovedTags'](_0x3565c2){const _0x358130=new Set();for(let _0x578ece=0x0;_0x578ece<_0x3565c2['length'];_0x578ece++){if(_0x358130['has'](_0x3565c2[_0x578ece]['id'])&&_0x3565c2[_0x578ece]['isRemoved']&&(_0x3565c2[_0x578ece]['isIncorrect']=!0x0),_0x3565c2[_0x578ece]['isIncorrect'])continue;if(0x0==_0x3565c2[_0x578ece]['distance'])continue;if('elementStart'!=_0x3565c2[_0x578ece]['type'])continue;if(null==_0x3565c2[_0x578ece]['pairId'])continue;let _0x350981=_0x578ece+0x1,_0x20fe07=0x0;for(;_0x3565c2[_0x350981]['id']!=_0x3565c2[_0x578ece]['pairId'];)'elementStart'==_0x3565c2[_0x350981]['type']?_0x20fe07++:'elementEnd'==_0x3565c2[_0x350981]['type']&&_0x20fe07--,_0x350981++;if(0x0!=_0x20fe07){if(_0x3565c2[_0x578ece]['isRemoved'])_0x3565c2[_0x578ece]['isIncorrect']=!0x0;else{for(;_0x350981!=_0x578ece;)_0x3565c2[_0x350981]['isRemoved']&&0x0!=_0x3565c2[_0x350981]['distance']&&(_0x3565c2[_0x350981]['isIncorrect']=!0x0,_0x358130['add'](_0x3565c2[_0x350981]['pairId'])),_0x350981--;}}}return _0x3565c2['filter'](_0x1eea71=>!_0x1eea71['isIncorrect']);}['_removeUnsupportedChanges'](_0x1813d2){const _0x18ec64=this['editor']['model']['schema'];for(let _0x34f993=0x0;_0x34f993<_0x1813d2['length'];_0x34f993++){if(!(_0x1813d2[_0x34f993]['isAdded']||_0x1813d2[_0x34f993]['isAddSuggestion']||_0x1813d2[_0x34f993]['isRemoved']||_0x1813d2[_0x34f993]['isRemoveSuggestion']))continue;if(0x0==_0x1813d2[_0x34f993]['distance'])continue;const _0x259cfb=_0x1813d2[_0x34f993]['item'];_0x18ec64['isBlock'](_0x259cfb)||_0x18ec64['isLimit'](_0x259cfb)||(_0x1813d2[_0x34f993]['isAdded']&&delete _0x1813d2[_0x34f993]['isAdded'],_0x1813d2[_0x34f993]['isAddSuggestion']&&delete _0x1813d2[_0x34f993]['isAddSuggestion'],_0x1813d2[_0x34f993]['isRemoveSuggestion']&&delete _0x1813d2[_0x34f993]['isRemoveSuggestion'],_0x1813d2[_0x34f993]['isRemoved']&&(_0x1813d2[_0x34f993]['isIncorrect']=!0x0));}return _0x1813d2['filter'](_0x3966dd=>!_0x3966dd['isIncorrect']);}['_makeModelFromTape'](_0x5334c4,_0x2314ea,_0x150dc8){const _0x3964f7=new mt(),_0x543a50=[],_0x2dea82=new Map(),_0x23cb0a=this['editor']['model'],_0x562c3b=_0x23cb0a['schema'],_0x2a5d0e=[_0x3964f7],_0x3babfe={},_0x16afbe={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x1d2141=null;const _0x2e0aa1=[0x0];for(let _0x184f91=0x0;_0x184f91<_0x5334c4['length'];_0x184f91++)if('elementStart'===_0x5334c4[_0x184f91]['type']){_0x5334c4[_0x184f91]['previousPosition']=_0x23cb0a['createPositionFromPath'](_0x3964f7,_0x2e0aa1);const _0x53d660=new ft(_0x5334c4[_0x184f91]['item']['name'],_0x5334c4[_0x184f91]['item']['getAttributes']());_0x2a5d0e[0x0]['_appendChild'](_0x53d660),_0x2e0aa1['push'](0x0),_0x2a5d0e['unshift'](_0x53d660),_0x5334c4[_0x184f91]['nextPosition']=_0x23cb0a['createPositionFromPath'](_0x3964f7,_0x2e0aa1);}else'elementEnd'===_0x5334c4[_0x184f91]['type']?(_0x2a5d0e['shift'](),_0x5334c4[_0x184f91]['previousPosition']=_0x23cb0a['createPositionFromPath'](_0x3964f7,_0x2e0aa1),_0x2e0aa1['pop'](),_0x2e0aa1[_0x2e0aa1['length']-0x1]++,_0x5334c4[_0x184f91]['nextPosition']=_0x23cb0a['createPositionFromPath'](_0x3964f7,_0x2e0aa1)):(_0x5334c4[_0x184f91]['previousPosition']=_0x23cb0a['createPositionFromPath'](_0x3964f7,_0x2e0aa1),_0x1d2141?_0x1d2141['_data']+=_0x5334c4[_0x184f91]['item']['data']:_0x1d2141=new wt(_0x5334c4[_0x184f91]['item']['data'],_0x5334c4[_0x184f91]['item']['getAttributes']()),_0x5334c4[_0x184f91+0x1]&&'text'===_0x5334c4[_0x184f91+0x1]['type']&&_0x5ec3ab(_0x1d2141,_0x5334c4[_0x184f91+0x1]['item'])||(_0x2a5d0e[0x0]['_appendChild'](_0x1d2141),_0x1d2141=null),_0x2e0aa1[_0x2e0aa1['length']-0x1]+=_0x5334c4[_0x184f91]['item']['offsetSize'],_0x5334c4[_0x184f91]['nextPosition']=_0x23cb0a['createPositionFromPath'](_0x3964f7,_0x2e0aa1));for(let _0x2de70a=0x0;_0x2de70a<_0x5334c4['length'];_0x2de70a++){const _0x3708ec=_0x5334c4[_0x2de70a]['previousPosition'],_0x439343=_0x5334c4[_0x2de70a]['nextPosition'];for(const _0x4fc166 of _0x5334c4[_0x2de70a]['markersStart'])_0x2dea82['set'](_0x4fc166,{'start':_0x3708ec,'end':null});_0x1e7f49('isRemoveSuggestion',_0x2de70a,_0x3708ec,_0x439343),_0x1e7f49('isAddSuggestion',_0x2de70a,_0x3708ec,_0x439343),_0x1e7f49('isRemoved',_0x2de70a,_0x3708ec,_0x439343),_0x1e7f49('isAdded',_0x2de70a,_0x3708ec,_0x439343);for(const _0x4dd27d of _0x5334c4[_0x2de70a]['markersEnd']){_0x2dea82['get'](_0x4dd27d)['end']=_0x439343;}}for(const [_0x3c8708,_0x4a887f]of _0x2dea82){const _0xfb5567=this['editor']['model']['createRange'](_0x4a887f['start'],_0x4a887f['end']);_0x3964f7['markers']['set'](_0x3c8708,_0xfb5567);}return _0x543a50['sort']((_0x4ca1b2,_0x4a9e5d)=>{const _0x5e76b3=_0x3964f7['markers']['get']('revision:'+_0x4ca1b2['id']),_0x38cd75=_0x3964f7['markers']['get']('revision:'+_0x4a9e5d['id']);return _0x5e76b3['start']['isBefore'](_0x38cd75['start'])?-0x1:_0x5e76b3['start']['isAfter'](_0x38cd75['start'])?0x1:_0x5e76b3['end']['isBefore'](_0x38cd75['end'])?-0x1:_0x5e76b3['end']['isAfter'](_0x38cd75['end'])?0x1:'add'===_0x4ca1b2['type']?-0x1:0x1;}),{'root':_0x3964f7,'changes':_0x543a50};function _0x1e7f49(_0x3c30d6,_0x33aebe,_0x5b2b91,_0x538c2d){const _0x1a078d=!!_0x5334c4[_0x33aebe][_0x3c30d6],_0xc9f10=_0x1a078d?_0x5334c4[_0x33aebe][_0x3c30d6]['userId']:null,_0x4af925=_0x33aebe===_0x5334c4['length']-0x1,_0x3036f2=_0x16afbe[_0x3c30d6][0x0],_0x363d41=_0x562c3b['isObject'](_0x5334c4[_0x33aebe]['item']);!_0x3babfe[_0x3c30d6]&&_0x1a078d?_0x3babfe[_0x3c30d6]={'start':_0x5b2b91,'tapeItem':_0x5334c4[_0x33aebe],'userId':_0xc9f10,'type':_0x3c30d6}:_0x3babfe[_0x3c30d6]&&!_0x1a078d?(_0x3babfe[_0x3c30d6]['end']=_0x5b2b91,_0x518246(_0x3babfe[_0x3c30d6]),_0x3babfe[_0x3c30d6]=null):_0x3babfe[_0x3c30d6]&&_0x1a078d&&_0x3babfe[_0x3c30d6]['userId']!==_0xc9f10&&(_0x3babfe[_0x3c30d6]['end']=_0x5b2b91,_0x3036f2&&_0x3036f2['userId']===_0x3babfe[_0x3c30d6]['userId']||_0x518246(_0x3babfe[_0x3c30d6]),_0x3babfe[_0x3c30d6]={'start':_0x5b2b91,'tapeItem':_0x5334c4[_0x33aebe],'userId':_0xc9f10,'type':_0x3c30d6}),_0x3babfe[_0x3c30d6]&&_0x363d41&&('elementStart'!==_0x5334c4[_0x33aebe]['type']||_0x3036f2&&_0x3036f2['userId']===_0xc9f10||_0x16afbe[_0x3c30d6]['unshift']({'userId':_0xc9f10,'object':_0x5334c4[_0x33aebe]['item'],'change':_0x3babfe[_0x3c30d6]}),'elementEnd'===_0x5334c4[_0x33aebe]['type']&&_0x3036f2&&_0x3036f2['object']===_0x5334c4[_0x33aebe]['item']&&(_0x16afbe[_0x3c30d6]['shift'](),_0x3babfe[_0x3c30d6]=_0x3036f2['change'])),_0x3babfe[_0x3c30d6]&&_0x4af925&&(_0x3babfe[_0x3c30d6]['end']=_0x538c2d,_0x518246(_0x3babfe[_0x3c30d6]),_0x3babfe[_0x3c30d6]=null);}function _0x518246({start:_0x51e2bc,end:_0x4c6baf,tapeItem:_0x145050,userId:_0x3d3b33,type:_0xfc57a4}){const _0x433dea=_0x145050['item'],_0x56370d=_0x23cb0a['schema']['isBlock'](_0x433dea)&&!_0x23cb0a['schema']['isLimit'](_0x433dea),_0xdfbb83=_0x51e2bc['nodeAfter']==_0x4c6baf['parent']&&_0x4c6baf['isAtStart'];if(_0x56370d&&_0xdfbb83)return;const _0x2606a1=_0x23cb0a['createRange'](_0x51e2bc,_0x4c6baf),_0x2e16b5=_0x2314ea['get'](_0x3d3b33),_0x580eaf=new r({'author':_0x2e16b5,'type':'isAdded'==_0xfc57a4||'isAddSuggestion'==_0xfc57a4?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0xfc57a4||'isRemoveSuggestion'==_0xfc57a4},'createdAt':new Date(),'rootName':_0x150dc8});_0x543a50['push'](_0x580eaf),_0x3964f7['markers']['set']('revision:'+_0x580eaf['id'],_0x2606a1);}function _0x5ec3ab(_0x3a3174,_0xb17f19){const _0x39527d=_0x3a3174['getAttributes'](),_0x46bd56=_0xb17f19['getAttributes']();for(const _0x17dcee of _0x39527d){if(_0x17dcee[0x1]!==_0xb17f19['getAttribute'](_0x17dcee[0x0]))return!0x1;_0x46bd56['next']();}return _0x46bd56['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x462233=>{const _0x2d070b=_0x462233['markerName']['split'](':')[0x1],_0x3c8a17=this['_getChangeFromId'](_0x2d070b);if(!_0x3c8a17)return null;const _0x1ce916='add'==_0x3c8a17['type']?'insertion':'deletion',_0x3e31a8=['ck-suggestion-marker','ck-suggestion-marker-'+_0x1ce916];return _0x3c8a17['data']['isSuggestion']&&_0x3e31a8['push']('ck-suggestion-marker-'+_0x1ce916+'-new'),this['activeChange']==_0x3c8a17&&_0x3e31a8['push']('ck-suggestion-marker--active'),{'classes':_0x3e31a8,'attributes':{'data-change-id':_0x2d070b}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x30aa9f=>{_0x30aa9f['on']('element:pre',(_0x360b80,_0x492c37,_0x3f0344)=>{const _0x53c7af=_0x492c37['viewItem']['getChild'](0x0);if(!_0x53c7af||!_0x53c7af['is']('element','code'))return;if(!_0x3f0344['consumable']['consume'](_0x53c7af,{'attributes':['vid_start','vid_end']}))return;const _0x51ce81=_0x492c37['modelRange']['start']['nodeAfter'];_0x3f0344['writer']['setAttribute']('vid_start',_0x53c7af['getAttribute']('vid_start'),_0x51ce81),_0x3f0344['writer']['setAttribute']('vid_end',_0x53c7af['getAttribute']('vid_end'),_0x51ce81);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0xec2dd4=>{_0xec2dd4['on']('element',(_0x4f3407,_0x1aab1c,_0x20a1b0)=>{if(!_0x20a1b0['consumable']['consume'](_0x1aab1c['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x1aab1c['modelRange']['isCollapsed'])return;const _0x4b71eb=_0x1aab1c['modelRange']['start']['nodeAfter'];_0x4b71eb['hasAttribute']('vid_start')||_0x4b71eb['hasAttribute']('vid')||(_0x20a1b0['writer']['setAttribute']('vid_start',_0x1aab1c['viewItem']['getAttribute']('vid_start'),_0x4b71eb),_0x20a1b0['writer']['setAttribute']('vid_end',_0x1aab1c['viewItem']['getAttribute']('vid_end'),_0x4b71eb));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x13b613=>_0x13b613['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x457ff6,[,_0x425ec8])=>{['vid_start','vid_end','vid']['includes'](_0x425ec8)&&(_0x457ff6['return']=!0x0,_0x457ff6['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x130752=>{_0x130752['on']('attribute:vid',(_0x2d141d,_0x377691,_0x5d2ebb)=>{if('\x20'!=_0x377691['item']['data']||_0x377691['item']['parent']['maxOffset']>0x1)return;if(!_0x5d2ebb['consumable']['consume'](_0x377691['item'],_0x2d141d['name']))return;const _0x5a9d2e=_0x5d2ebb['writer'],_0x309350=_0x5d2ebb['mapper']['toViewRange'](_0x377691['range']);_0x5a9d2e['wrap'](_0x309350,_0x5a9d2e['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x56e7bd){const _0xbb422f=_0x56e7bd['plugins']['get']('RevisionViewer');return(_0x36e739,_0x379f95,_0x587f71)=>{const _0x1a94c2=_0x379f95['markerName']['split'](':')[0x1],_0x228921=_0xbb422f['_getChangeFromId'](_0x1a94c2);if(!_0x228921)return null;const _0x26d553='add'==_0x228921['type']?'split':'merge';if(!_0x587f71['consumable']['test'](_0x379f95['markerRange'],_0x36e739['name']))return;const _0x48313b=_0x379f95['markerRange']['getWalker'](),_0x556cf7=_0x379f95['markerRange']['start'],_0x22743d=_0x56e7bd['model']['schema'];let _0xbb28b6=null,_0x1e26dc=null,_0x5c1027=!0x1,_0x48b091=!0x1;for(const _0xe39b03 of _0x48313b){const _0x9be586=_0xe39b03['item'];_0x5c1027=_0x5c1027||_0x22743d['isContent'](_0x9be586);const _0x94f23=_0x587f71['mapper']['toViewElement'](_0x9be586);if(_0x94f23&&_0x94f23['getCustomProperty']('addHighlight'))return;'elementEnd'==_0xe39b03['type']&&(_0x22743d['isBlock'](_0x9be586)&&!_0x22743d['isLimit'](_0x9be586)&&(_0x9be586['nextSibling']||_0x556cf7['isAtEnd']?_0xbb28b6&&_0xbb28b6['parent']==_0x9be586||(_0xbb28b6=_0x9be586,_0x2725e1(_0xe39b03['previousPosition']),_0x48b091=!0x0):_0x1e26dc=_0x1e26dc||_0xe39b03['previousPosition']));}function _0x2725e1(_0x237b26){const _0x4d8f6a=_0x587f71['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x26d553}),_0x4f21de=_0x587f71['mapper']['toViewPosition'](_0x237b26);_0x228921['data']['isSuggestion']&&_0x587f71['writer']['addClass']('ck-suggestion-marker-'+_0x26d553+'-new',_0x4d8f6a),_0xbb422f['activeChange']==_0x228921&&_0x587f71['writer']['addClass']('ck-suggestion-marker--active',_0x4d8f6a),_0x587f71['writer']['insert'](_0x4f21de,_0x4d8f6a),_0x587f71['mapper']['bindElementToMarker'](_0x4d8f6a,_0x379f95['markerName']);}_0x5c1027||_0x48b091||!_0x1e26dc||_0x2725e1(_0x1e26dc);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x31d646,_0x3dd608,_0x77d670)=>{const _0x49131e=_0x77d670['mapper']['markerNameToElements'](_0x3dd608['markerName']);if(_0x49131e){for(const _0x24c17e of _0x49131e)(_0x24c17e['hasClass']('ck-suggestion-marker-split')||_0x24c17e['hasClass']('ck-suggestion-marker-merge'))&&(_0x77d670['mapper']['unbindElementFromMarkerName'](_0x24c17e,_0x3dd608['markerName']),_0x77d670['writer']['remove'](_0x24c17e));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x30fa02,_0xf126f,_0x1a669e)=>{const _0x15c699=_0xf126f['markerName']['split'](':')[0x1],_0x4a4f2a=this['_getChangeFromId'](_0x15c699);if(!_0x4a4f2a)return null;const _0x1bd27a='add'==_0x4a4f2a['type']?'split':'merge';if(_0x1a669e['consumable']['test'](_0xf126f['markerRange'],_0x30fa02['name']))for(const _0x56d9ac of _0xf126f['markerRange']['getItems']()){if(!_0x56d9ac['is']('element','softBreak'))continue;const _0x24cb2e=_0x1a669e['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x1bd27a}),_0x48c26a=_0x1a669e['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x56d9ac));_0x4a4f2a['data']['isSuggestion']&&_0x1a669e['writer']['addClass']('ck-suggestion-marker-'+_0x1bd27a+'-new',_0x24cb2e),this['activeChange']==_0x4a4f2a&&_0x1a669e['writer']['addClass']('ck-suggestion-marker--active',_0x24cb2e),_0x1a669e['writer']['insert'](_0x48c26a,_0x24cb2e),_0x1a669e['mapper']['bindElementToMarker'](_0x24cb2e,_0xf126f['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x44ab75=>{for(const _0x5e9f3d of this['editor']['model']['document']['getRootNames']()){const _0x43ae03=this['editor']['model']['document']['getRoot'](_0x5e9f3d),_0x2be83c=this['editor']['editing']['view']['document']['getRoot'](_0x5e9f3d);if(_0x2be83c){const _0x279765=_0x43ae03['getAttribute']('revisionHistoryAttachChange');if(_0x44ab75['removeAttribute']('data-change-id',_0x2be83c),_0x44ab75['removeClass']('ck-revision-history-root-add',_0x2be83c),_0x44ab75['removeClass']('ck-revision-history-root-remove',_0x2be83c),_0x44ab75['removeClass']('ck-revision-history-root--active',_0x2be83c),_0x279765){const _0x60695e=this['_getChangeFromId'](_0x279765);if(!_0x60695e)return null;_0x44ab75['setAttribute']('data-change-id',_0x279765,_0x2be83c),_0x44ab75['addClass']('ck-revision-history-root-'+_0x60695e['type'],_0x2be83c),this['activeChange']==_0x60695e&&_0x44ab75['addClass']('ck-revision-history-root--active',_0x2be83c);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x10eed4=>'revision-comment:'+_0x10eed4,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x2a59ae=>'revision-suggestion:'+_0x2a59ae,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x30ea11=>({'name':'suggestion:'+_0x30ea11,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0xa803=>{const _0x370d52=_0xa803['markerName']['split'](':')[0x1];return'insertion'!=_0x370d52&&'deletion'!=_0x370d52?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x370d52]};}}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:deletion',Z(this['editor'],'merge'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision-suggestion:insertion',Z(this['editor'],'split'),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision-suggestion',(_0x1b3fc8,_0x3ed3be,_0x2237dd)=>{const _0x58d2dd=_0x2237dd['mapper']['markerNameToElements'](_0x3ed3be['markerName']);if(_0x58d2dd){for(const _0x2180ed of _0x58d2dd)_0x2180ed['is']('uiElement')&&(_0x2237dd['mapper']['unbindElementFromMarkerName'](_0x2180ed,_0x3ed3be['markerName']),_0x2237dd['writer']['remove'](_0x2180ed));}},{'priority':'high'});}['_getChangeFromId'](_0x5a9384){return this['_changeIdToChange']['get'](_0x5a9384);}['_getViewForChange'](_0x36d80){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new X(this['editor']['locale'],_0x36d80),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x31bbc3,_0x39dcd7,_0x31fe0a,_0x222a4d)=>{_0x222a4d&&this['_balloon']['remove'](_0x222a4d),_0x31fe0a&&(this['_balloon']['add']({'view':_0x31fe0a,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x1aa85e=this['editor']['editing'],_0x1fadab=this['_getChangeFromId'](_0x31fe0a['changeId']);let _0x368621;if(_0x1fadab['data']['isOnRoot']){const _0x31eab1=_0x1aa85e['view']['getDomRoot'](_0x1fadab['rootName']);_0x368621=Array['from'](_0x31eab1['getClientRects']());}else{const _0x3f4e9e=this['editor']['model']['markers']['get']('revision:'+_0x31fe0a['changeId']);_0x368621=Array['from'](_0x1aa85e['mapper']['markerNameToElements'](_0x3f4e9e['name']))['map'](_0xb05c4c=>_0x1aa85e['view']['domConverter']['mapViewToDom'](_0xb05c4c))['map'](_0x224dc3=>Array['from'](_0x224dc3['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x368621[0x0];return _0x368621['find'](_0x30a9a6=>_0x30a9a6['top']-0x3<=this['_activeViewTarget']['y']&&_0x30a9a6['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x30a9a6['left']-0x3<=this['_activeViewTarget']['x']&&_0x30a9a6['right']+0x3>=this['_activeViewTarget']['x'])||_0x368621[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x284a63,_0x3bf825,_0x5ae75e,_0x20c96e)=>{this['activeView']=_0x5ae75e?this['_getViewForChange'](_0x5ae75e):null,this['editor']['model']['change'](()=>{const _0x37c5=this['editor']['editing'];_0x20c96e&&(_0x20c96e['data']['isOnRoot']?_0x37c5['view']['change'](_0x27fa7b=>{_0x27fa7b['removeClass']('ck-revision-history-root--active',_0x37c5['view']['document']['getRoot'](_0x20c96e['rootName']));}):_0x37c5['reconvertMarker']('revision:'+_0x20c96e['id'])),_0x5ae75e&&(_0x5ae75e['data']['isOnRoot']?_0x37c5['view']['change'](_0x861d45=>{_0x861d45['addClass']('ck-revision-history-root--active',_0x37c5['view']['document']['getRoot'](_0x5ae75e['rootName']));}):_0x37c5['reconvertMarker']('revision:'+_0x5ae75e['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x1f2b43,_0x1bbd99)=>{if(this['activeChange'])return;const _0x556c07=this['_findChangeIdFromDomTarget'](_0x1bbd99['target']),_0x2da4b7=this['_changeIdToChange']['get'](_0x556c07);_0x2da4b7?(this['_activeViewTarget']={'x':_0x1bbd99['domEvent']['x'],'y':_0x1bbd99['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x2da4b7)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x54c660,_0x11ea9a)=>{const _0x57963a=this['_findChangeIdFromDomTarget'](_0x11ea9a['target']),_0x1ac347=this['_changeIdToChange']['get'](_0x57963a);_0x1ac347?(this['_activeViewTarget']={'x':_0x11ea9a['domEvent']['x'],'y':_0x11ea9a['domEvent']['y']},_0x1ac347===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x1ac347):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x3caa26){do{const _0x5842ee=_0x3caa26['getAttribute']('data-change-id');if(_0x5842ee)return _0x5842ee;_0x3caa26=_0x3caa26['parent'];}while(_0x3caa26);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x6e6e9a=>{for(const _0x4160b6 of this['editor']['model']['markers'])_0x6e6e9a['removeMarker'](_0x4160b6);});}}function Z(_0x17ced5,_0x3e0233){return(_0x3e3fa1,_0x547430,_0x17e223)=>{if(!_0x17e223['consumable']['test'](_0x547430['markerRange'],_0x3e3fa1['name']))return;const _0x13d150=_0x547430['markerRange']['getWalker'](),_0x1de114=_0x547430['markerRange']['start'],_0x25b366=_0x17ced5['model']['schema'];let _0x357b6a=null,_0x101686=null,_0x314366=!0x1,_0x2d1062=!0x1;for(const _0x56df0a of _0x13d150){const _0x37dced=_0x56df0a['item'];_0x314366=_0x314366||_0x25b366['isContent'](_0x37dced);const _0x3d2c57=_0x17e223['mapper']['toViewElement'](_0x37dced);if(_0x3d2c57&&_0x3d2c57['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x56df0a['type']&&(_0x25b366['isBlock'](_0x37dced)&&!_0x25b366['isLimit'](_0x37dced)&&(_0x37dced['nextSibling']||_0x1de114['isAtEnd']?_0x357b6a&&_0x357b6a['parent']==_0x37dced||(_0x357b6a=_0x37dced,_0x3d7ed3(_0x56df0a['previousPosition']),_0x2d1062=!0x0):_0x101686=_0x101686||_0x56df0a['previousPosition']));}function _0x3d7ed3(_0x10ccc9){const _0x2dadce=_0x17e223['mapper']['toViewPosition'](_0x10ccc9),_0x25589f=_0x17e223['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x3e0233});_0x17e223['writer']['insert'](_0x2dadce,_0x25589f),_0x17e223['mapper']['bindElementToMarker'](_0x25589f,_0x547430['markerName']);}_0x314366||_0x2d1062||!_0x101686||_0x3d7ed3(_0x101686);};}class _t extends _0x468141{constructor(_0xcfe6e7){super(_0xcfe6e7);const _0x532873=_0xcfe6e7['plugins']['get'](d);this['affectsData']=!0x1,this['listenTo'](_0x532873,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x532873,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x3c2a2f=this['editor'],_0x225a0f=_0x3c2a2f['plugins']['get'](d),_0x54a498=_0x225a0f['isReady']?_0x225a0f['diff']['newRevisionId']:null;_0x3c2a2f['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x54a498);}['refresh'](){const {isReady:_0x106e3f,isEnabled:_0x1b8c2e,repository:_0x231d53,diff:_0x226310}=this['editor']['plugins']['get'](d),_0x190822=_0x226310&&_0x231d53['getLaterVisibleRevision'](_0x226310['newRevisionId']);this['isEnabled']=_0x106e3f&&_0x1b8c2e&&Boolean(_0x190822);}}class yt extends _0x468141{['_step'];constructor(_0x35776b,{direction:_0x533f28}){super(_0x35776b);const _0x1b4473=_0x35776b['plugins']['get'](d);this['affectsData']=!0x1,this['_step']='forward'===_0x533f28?0x1:-0x1,this['listenTo'](_0x1b4473,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x1b4473,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x1b4473,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x5bbfed=this['editor'],_0x4e7913=_0x5bbfed['plugins']['get'](d),{isNavigationMode:_0x584373,currentChangeNumber:_0x514364}=_0x4e7913;let _0x2d3ddd;if(_0x4e7913['activeChange']=_0x584373?_0x4e7913['diff']['changes']['get'](_0x514364+this['_step']):_0x4e7913['diff']['changes']['first'],_0x4e7913['activeChange']['data']['isOnRoot'])_0x2d3ddd=_0x5bbfed['editing']['view']['getDomRoot'](_0x4e7913['activeChange']['rootName']);else{const _0x5ce016=_0x5bbfed['model']['markers']['get']('revision:'+_0x4e7913['activeChange']['id']);_0x2d3ddd=_0x263dcc(_0x5bbfed['editing'],_0x5ce016);}_0x1f4042({'target':_0x2d3ddd,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x46fece,currentChangeNumber:_0x401b08,numberOfChanges:_0x552b1a,isReady:_0x2dd3a2,isEnabled:_0x27a5ba}=this['editor']['plugins']['get'](d);this['isEnabled']=!!(_0x27a5ba&&_0x2dd3a2&&_0x552b1a)&&(!_0x46fece||(0x1===this['_step']?_0x401b08<_0x552b1a-0x1:_0x401b08>0x0));}}class di extends _0x3e310e{constructor(_0x47e212){super(_0x47e212);const _0x4f0158=this['bindTemplate'],_0x4ff163=new _0x5baaae(_0x47e212),_0x5072b3=new _0x5baaae(_0x47e212);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',(_0x5c5684,_0x197ba1)=>_0x5c5684&&_0x197ba1>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0xc4324,_0x3c7460,_0x4bf8b2,_0x404784)=>{if(!_0xc4324)return m(_0x47e212,'Loading...');if(!_0x4bf8b2)return m(_0x47e212,'No\x20changes');const _0x345517=m(_0x47e212,'NUMBER_OF_CHANGES',_0x4bf8b2);return _0x404784?m(_0x47e212,'X_OF_Y_CHANGES',[_0x3c7460+0x1,_0x4bf8b2]):_0x345517;}),_0x4ff163['set']({'label':m(_0x47e212,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':'<svg\x20viewBox=\x220\x200\x2020\x2020\x22\x20xmlns=\x22http://www.w3.org/2000/svg\x22><path\x20d=\x22M16.435\x2014.494a.75.75\x200\x200\x200\x201.197-.899l-.067-.089-6.992-8a.75.75\x200\x200\x200-1.05-.078l-.079.078-7.008\x208a.75.75\x200\x200\x200\x201.049\x201.066l.08-.078\x206.442-7.354\x206.428\x207.354z\x22/></svg>\x0a'}),_0x5072b3['set']({'label':m(_0x47e212,'Show\x20next\x20change'),'tooltip':!0x0,'icon':'<svg\x20viewBox=\x220\x200\x2020\x2020\x22\x20xmlns=\x22http://www.w3.org/2000/svg\x22><path\x20d=\x22M16.435\x205.506a.75.75\x200\x200\x201\x201.197.899l-.067.089-6.992\x208a.75.75\x200\x200\x201-1.05.078l-.079-.078-7.008-8a.75.75\x200\x200\x201\x201.049-1.066l.08.078\x206.442\x207.354\x206.428-7.354z\x22/></svg>\x0a'}),_0x4ff163['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x5072b3['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x4ff163['on']('execute',()=>this['fire']('execute','backward')),_0x5072b3['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',_0x4f0158['if']('_isStatusLabelVisible','ck-hidden',_0x483739=>!_0x483739)]},'children':[{'text':_0x4f0158['to']('isNavigationMode',_0x320725=>_0x320725?m(_0x47e212,'EDIT_X_OF_Y_REVISIONS')+':\x20':m(_0x47e212,'Total')+':\x20')}]},{'text':_0x4f0158['to']('_statusText')}]},new _0xa8182f(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x4ff163,_0x5072b3]}]});}}const ce='ck-editor__editable__loading-overlay';class ae extends _0x50f6d6{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x4ae2d5=this['editor']['editing']['view'];_0x4ae2d5['change'](_0x3c6dc2=>{for(const _0x5959a5 of _0x4ae2d5['document']['roots'])_0x3c6dc2['addClass'](ce,_0x5959a5);});}['hide'](){const _0x490ec0=this['editor']['editing']['view'];_0x490ec0['change'](_0x2b47c7=>{for(const _0x15df3e of _0x490ec0['document']['roots'])_0x2b47c7['removeClass'](ce,_0x15df3e);});}}class g extends _0x50f6d6{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[d,ae];}['init'](){const _0x72bf03=this['editor'],_0x2334b5=_0x72bf03['plugins']['get'](d),_0x1d6906=_0x72bf03['plugins']['get'](ae);_0x72bf03['ui']['componentFactory']['add']('exitToEditing',_0x341fe9=>{const _0x232194=new _0x5baaae(_0x341fe9);return _0x232194['set']({'label':m(_0x341fe9,'Back\x20to\x20editing'),'icon':_0x5f52da['undo'],'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x232194,'execute',()=>{_0x72bf03['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x232194;}),_0x72bf03['ui']['componentFactory']['add']('restoreRevision',_0x3a6340=>{const _0x6e3539=new _0x5baaae(_0x3a6340);return _0x6e3539['set']({'label':m(_0x3a6340,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x6e3539['bind']('isEnabled')['to'](_0x72bf03['commands']['get']('restoreRevision')),this['listenTo'](_0x6e3539,'execute',()=>_0x72bf03['execute']('restoreRevision')),_0x6e3539;}),_0x72bf03['ui']['componentFactory']['add']('changesNavigation',_0x1fec6a=>{const _0x4469b1=new di(_0x1fec6a),_0x2bd070=_0x72bf03['commands']['get']('showPreviousChange'),_0x46941d=_0x72bf03['commands']['get']('showNextChange');return _0x4469b1['bind']('isBackwardNavigationEnabled')['to'](_0x2bd070,'isEnabled'),_0x4469b1['bind']('isForwardNavigationEnabled')['to'](_0x46941d,'isEnabled'),_0x4469b1['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x2334b5),this['listenTo'](_0x4469b1,'execute',(_0x5bd9f2,_0x4f1889)=>{_0x72bf03['execute']('forward'===_0x4f1889?'showNextChange':'showPreviousChange');}),_0x4469b1;}),_0x1d6906['show'](),_0x2334b5['on']('change:isReady',(_0x52ea30,_0x2f7c73,_0x29e1e3)=>{_0x29e1e3?_0x1d6906['hide']():_0x1d6906['show']();});}}class pt extends nt{['_resizeObserver']=null;constructor(_0x426320,_0x301206){super(_0x426320,_0x301206);const _0x532401=this['bindTemplate'];this['set']({'label':m(_0x426320,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=m(_0x426320,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x532401['to']('_tooltipString'),'data-cke-tooltip-position':'s','data-cke-tooltip-class':'ck-tooltip_multi-line'}});}['render'](){super['render'](),this['_resizeObserver']=new at(this['fieldView']['element'],()=>this['_updateTooltipText']()),this['listenTo'](this['fieldView'],'input',()=>this['_updateTooltipText']());}['destroy'](){super['destroy'](),this['_resizeObserver']&&this['_resizeObserver']['destroy']();}['_updateTooltipText'](){const _0x5743be=this['fieldView']['element'];this['_tooltipString']=_0x5743be['scrollWidth']>_0x5743be['clientWidth']&&_0x5743be['value']||'';}}class ti extends _0x3e310e{constructor(_0x5f56d2,_0x16f7b1,_0x46aa5b){super(_0x5f56d2);const _0xb1ceee=new _0x47f78e();_0xb1ceee['set']({'content':'<svg\x20viewBox=\x220\x200\x2011\x2010\x22\x20xmlns=\x22http://www.w3.org/2000/svg\x22\x20xmlns:xlink=\x22http://www.w3.org/1999/xlink\x22><path\x20d=\x22M5.5\x205C8.538\x205\x2011\x207.015\x2011\x209.5c0\x20.17-.011.336-.034.5H.034A3.732\x203.732\x200\x200\x201\x200\x209.5C0\x207.015\x202.462\x205\x205.5\x205zm0-5a2.5\x202.5\x200\x201\x201\x200\x205\x202.5\x202.5\x200\x200\x201\x200-5z\x22\x20/></svg>\x0a','viewBox':'0\x200\x2011\x2010'});const _0x5434db=['ck','ck-revision-history-sidebar__revision-author'];_0x46aa5b&&_0x5434db['push']('ck-revision-history-sidebar__revision-author_creator');const _0x18b56c=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':m(_0x5f56d2,_0x46aa5b?'Revision\x20creator':'Revision\x20author')},'children':[_0xb1ceee,_0x16f7b1['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x5434db},'children':_0x18b56c});}}function ni(_0x305578,_0x155a83){const _0x56da2c=_0x305578['bindTemplate'],_0x50bfb0=_0x305578['locale'],_0x5b7404=_0x1ffeb1(_0x50bfb0);_0x5b7404['panelPosition']='sw';const _0x2b1a99=function(_0x209051,_0xb3c4f){const _0x5cb4fc=function(_0x4f8414,_0x57159a){const _0x145121=_0x4f8414['locale'],_0x277856={'Compare\x20against\x20selected':m(_0x145121,'Compare\x20against\x20selected'),'Name\x20this\x20revision':m(_0x145121,'Name\x20this\x20revision'),'Restore\x20this\x20revision':m(_0x145121,'Restore\x20this\x20revision')};return _0x57159a['map'](_0x2ceb26=>{const _0x1411a0=_0x277856[_0x2ceb26['name']];return _0x1411a0&&_0x1411a0!==_0x2ceb26['name']&&(_0x2ceb26['name']=_0x1411a0),_0x2ceb26;});}(_0x209051,_0xb3c4f),_0x44baa8=new _0xccc836();for(const _0x555739 of _0x5cb4fc){const _0x42e750={'type':'button','model':new to({'label':_0x555739['name'],'class':_0x555739['class'],'withText':!0x0,'role':'menuitem','_action':_0x555739['action']})};_0x42e750['model']['bind']('isEnabled')['to'](_0x209051,'isActionsDropdownOpen',_0x1d7e5b=>'function'!=typeof _0x555739['isEnabled']||(!_0x1d7e5b||_0x555739['isEnabled'](_0x209051))),_0x44baa8['add'](_0x42e750);}return _0x44baa8;}(_0x305578,_0x155a83);return _0x305578['bind']('isActionsDropdownOpen')['to'](_0x5b7404,'isOpen'),_0x5b7404['buttonView']['set']({'label':m(_0x50bfb0,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x5f52da['threeVerticalDots']}),_0x5b7404['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x56da2c['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x56da2c['to'](_0x5353fa=>_0x5353fa['stopPropagation']())}}),_0x5b7404['on']('execute',_0x20c1fa=>{_0x305578['isReady']&&'function'==typeof _0x20c1fa['source']['_action']&&_0x20c1fa['source']['_action'](_0x305578);}),_0x57676b(_0x5b7404,_0x2b1a99,{'role':'menu'}),_0x5b7404['listenTo'](_0x305578,'change:isActionsDropdownOpen',(_0x4244fa,_0x1f4b57,_0x282501)=>{if(_0x282501)for(const _0x4c41a3 of _0x5b7404['listView']['items']){const _0x2cef2f=_0x4c41a3['children']['first'],_0x49badc=_0x155a83['find'](_0x163c21=>_0x163c21['action']===_0x2cef2f['_action'])['isVisible'];_0x4c41a3['isVisible']=void 0x0===_0x49badc||_0x49badc(_0x305578);}}),_0x5b7404;}class ai extends/* #__PURE__ -- @preserve */
26
+ _0x2bf354(_0x3e310e){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x5d061c,_0x1209ee,_0x4a4efc,_0x12ff0a){super(_0x5d061c);const _0x251a5e=this['bindTemplate'],_0xebeb2b=function(_0xcedc2d,_0x44382b){const _0x4f5f4d=Array['from'](_0x44382b['authors'])['filter'](_0x5a35b2=>_0x5a35b2!=_0x44382b['creator']);return _0x44382b['creator']&&_0x4f5f4d['unshift'](_0x44382b['creator']),_0x4f5f4d['map'](_0x5da6c1=>new ti(_0xcedc2d,_0x5da6c1,_0x5da6c1==_0x44382b['creator']));}(_0x5d061c,_0x1209ee);this['id']=_0x1209ee['id'],this['_revision']=_0x1209ee,this['_requireRevisionName']=_0x12ff0a,this['bind']('name','createdAt')['to'](_0x1209ee),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x5025e5=>{return _0x206f7a=_0x5d061c['uiLanguage'],(_0x46f84f=_0x5025e5)['toLocaleDateString'](_0x206f7a,{'month':'long','day':'numeric'})+',\x20'+_0x46f84f['toLocaleTimeString'](_0x206f7a,{'hour':'numeric','minute':'numeric'});var _0x206f7a,_0x46f84f;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new pt(_0x5d061c,_0x4aa70e),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x27265d=>_0x27265d||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x2b44f3,_0xe0c72c)=>_0x2b44f3&&_0xe0c72c),this['revisionActionsView']=_0x4a4efc&&_0x4a4efc['length']?ni(this,_0x4a4efc):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x251a5e['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x251a5e['if']('isEnabled','ck-disabled',_0x2617cf=>!_0x2617cf),_0x251a5e['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x251a5e['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x251a5e['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':_0x251a5e['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':_0xebeb2b}]},this['revisionActionsView']],'on':{'click':_0x251a5e['to'](_0x10e0a8=>{_0x10e0a8['srcElement']['closest']('.ck-thread__remove-confirm')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x2e1b16=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x2e1b16,'change',()=>{this['_requireRevisionName']&&!_0x2e1b16['value']||this['fire']('setName',{'id':this['id'],'name':_0x2e1b16['value']}),_0x2e1b16['value']||(_0x2e1b16['value']=this['name']?this['name']:this['_createdAtFormatted']);});}['select'](){this['isSelected']=!0x0;}['deselect'](){this['isSelected']=!0x1;}['highlight'](){this['isHighlighted']=!0x0;}['unhighlight'](){this['isHighlighted']=!0x1;}}function mi(_0x45b6eb,_0x2217dd){const _0x173a26=_0x586337['fromJSDate'](_0x45b6eb)['setLocale'](_0x2217dd),_0x38b156=_0x586337['local'](),_0x27f653=_0x38b156['minus']({'days':0x1})['startOf']('day');let _0x2b39f9,_0x2ba10c;return _0x173a26['hasSame'](_0x38b156,'day')?(_0x2b39f9=_0x173a26['startOf']('day')['toJSDate'](),_0x2ba10c=_0x173a26['toRelativeCalendar']()):_0x173a26['hasSame'](_0x27f653,'day')?(_0x2b39f9=_0x27f653['toJSDate'](),_0x2ba10c=_0x173a26['toRelativeCalendar']()):_0x173a26['hasSame'](_0x38b156,'week')?(_0x2b39f9=_0x173a26['startOf']('week')['toJSDate'](),_0x2ba10c=_0x173a26['weekdayLong']||''):_0x173a26['hasSame'](_0x38b156,'year')?(_0x2b39f9=_0x173a26['startOf']('month')['toJSDate'](),_0x2ba10c=_0x173a26['monthLong']||''):(_0x2b39f9=_0x173a26['startOf']('year')['toJSDate'](),_0x2ba10c=String(_0x173a26['year'])),{'startDate':_0x2b39f9,'localizedPeriodName':_0x2ba10c};}class vi extends _0x3e310e{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x2fe6b6,_0x3aaac9,_0x27d620,_0x4f1525){super(_0x2fe6b6);const _0x126a84=mi(_0x3aaac9,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x3aaac9,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x27d620,this['_requireRevisionName']=_0x4f1525,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':_0x126a84}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0xbecd7e){const _0x22741b=new ai(this['locale'],_0xbecd7e,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x22741b);}['removeRevision'](_0x3dd0ce){const _0x6e82b6=this['revisionViews']['find'](_0x229ddd=>_0x229ddd['id']===_0x3dd0ce['id']);this['revisionViews']['remove'](_0x6e82b6);}}class as extends _0x3e310e{constructor(_0x3a8880){super(_0x3a8880);const _0x1d5d5f=new _0x47f78e();_0x1d5d5f['content']=_0x5f52da['history'],this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x1d5d5f,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[m(_0x3a8880,'Revision\x20history')]}]});}}class li extends _0x3e310e{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x206e05,_0x4b146e,_0x4b6648,_0x1bb419){super(_0x206e05);const _0x296ffb=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x4b146e,this['_revisionActions']=_0x4b6648,this['_requireRevisionName']=_0x1bb419,this['on']('select',(_0x254408,_0x581f54)=>{this['fire']('revisionSelected',_0x581f54);}),this['on']('setName',(_0x11277a,_0x34142d)=>{this['fire']('revisionSetName',_0x34142d);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new as(_0x206e05),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x296ffb['if']('isEnabled','ck-disabled',_0x414b96=>!_0x414b96)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x484ddc of this['_revisions'])this['_addRevision'](_0x484ddc);this['_revisions']['on']('add',(_0x29c2a7,_0x2b3267)=>{this['_addRevision'](_0x2b3267);}),this['_revisions']['on']('remove',(_0x257b52,_0x39d6f7)=>{this['_removeRevision'](_0x39d6f7);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x23b5f8=>_0x23b5f8['revisionViews']['map'](_0x379a4d=>_0x379a4d))['flat']();}['selectRevision'](_0x54bbbf){for(const _0x26e1e8 of this['revisionViews'])_0x54bbbf&&_0x54bbbf['id']===_0x26e1e8['id']?_0x26e1e8['select']():_0x26e1e8['deselect']();}['highlightRevisions'](_0x3f34c9){for(const _0x151383 of this['revisionViews'])_0x3f34c9['some'](({id:_0x267d28})=>_0x267d28===_0x151383['id'])?_0x151383['highlight']():_0x151383['unhighlight']();}['_addRevision'](_0x4fb70a){const _0x1ebe8d=mi(_0x4fb70a['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x1758ad=this['timePeriodViews']['get'](0x0);_0x1758ad&&_0x1758ad['startDate']['getTime']()===_0x1ebe8d['getTime']()||(_0x1758ad=new vi(this['locale'],_0x1ebe8d,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x1758ad)),_0x1758ad['addRevision'](_0x4fb70a);}['_removeRevision'](_0x1ad781){const _0x2f3575=mi(_0x1ad781['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x2f3575)['removeRevision'](_0x1ad781);}['_getTimePeriodViewByStartDate'](_0x86ff61){return this['timePeriodViews']['find'](_0x51bd16=>_0x51bd16['startDate']['getTime']()===_0x86ff61['getTime']());}}class w extends _0x50f6d6{['_revisionViewer'];['_revisionsRepository'];['_sidebarView'];static ['defaultRevisionActions']=/* #__PURE__ -- @preserve */
27
27
  ((()=>['compareAgainstSelected','restoreRevision','nameRevision'])());static ['availableRevisionActions']=/* #__PURE__ -- @preserve */
28
- bt();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[d];}constructor(_0x15e87e){super(_0x15e87e),this['_revisionViewer']=_0x15e87e['plugins']['get'](d),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x47dd62=this['_revisionsRepository']['_revisions'],_0x484cab=this['_createRevisionActions'](),_0x52153d=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new li(this['editor']['locale'],_0x47dd62,_0x484cab,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',(_0x466b8f,_0x3d09d0)=>{_0x3d09d0['revisionViews']['on']('add',(_0x9c34a9,_0x2545fb)=>{_0x2545fb['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)),_0x52153d['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x1d4a2c=this['_revisionsRepository']['getRevision'](0x0);if(_0x1d4a2c){const _0xe28d03=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x1d4a2c['id']);this['_revisionViewer']['compare'](_0x1d4a2c,_0xe28d03);}}['_handleRevisionSelected'](_0x561a3c,_0x1a4e23){const _0x27fa0e=this['_revisionsRepository']['getRevision'](_0x1a4e23['id']),_0x59c077=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x27fa0e['id']);this['_revisionViewer']['compare'](_0x27fa0e,_0x59c077);}['_handleRevisionSetName'](_0x220827,_0x279275){this['_revisionsRepository']['getRevision'](_0x279275['id'])['setName'](_0x279275['name']);}['_handleDiffChange'](_0x471188,_0x5cebdd,_0x16b2df){const _0x5b2a40=this['_revisionsRepository']['getRevisionsInDiff'](_0x16b2df);_0x5b2a40['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x5b2a40),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x5b2a40[0x0]));}['_createRevisionActions'](){const _0x4bf15c=this['editor'],_0x1909c9=w['availableRevisionActions'],_0x140b39=_0x4bf15c['config']['get']('revisionHistory.revisionActions')||w['defaultRevisionActions'];if(_0x140b39['length'])return _0x140b39['map'](_0x59b10d=>{const _0x361ebb='string'==typeof _0x59b10d?Object['assign']({},_0x1909c9[_0x59b10d]):_0x59b10d;return _0x361ebb['action']=_0x361ebb['action']['bind'](this,_0x4bf15c),_0x361ebb['isVisible']&&(_0x361ebb['isVisible']=_0x361ebb['isVisible']['bind'](this,_0x4bf15c)),_0x361ebb;});}}function bt(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x3ee9d4},_0x3b7aae)=>{const _0x40e9f8=_0x3ee9d4['get'](d),_0x2c0a1b=_0x40e9f8['repository'];let _0x539ab7=_0x40e9f8['diff']['newRevisionId'],_0x45d4ec=_0x3b7aae['id'];_0x2c0a1b['getIndex'](_0x539ab7)>_0x2c0a1b['getIndex'](_0x45d4ec)&&([_0x539ab7,_0x45d4ec]=[_0x45d4ec,_0x539ab7]),_0x40e9f8['compare'](_0x539ab7,_0x45d4ec);},'isVisible':({plugins:_0x515ba},_0x2329cc)=>{const _0x1b1c9e=_0x515ba['get'](d);return!(_0x1b1c9e['repository']['getRevisionsInDiff'](_0x1b1c9e['diff'])['length']>0x2)&&!_0x2329cc['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x14f96b,{id:_0x4b39b7})=>{_0x14f96b['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x4b39b7);},'isVisible':({plugins:_0x4883e0},_0x14a1f1)=>!!_0x4883e0['get'](d)['repository']['getLaterVisibleRevision'](_0x14a1f1['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x4c9ad3},{id:_0x5b4bd1,revisionNameView:_0x55c445})=>{const _0xbf38d=_0x4c9ad3['get'](d),_0x4c5803=_0xbf38d['repository']['getEarlierVisibleRevision'](_0x5b4bd1);_0xbf38d['compare'](_0x5b4bd1,_0x4c5803),_0x55c445['focus'](),_0x55c445['fieldView']['select']();}}};}class rt extends st{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x29314e,_0x4130f6){super(_0x29314e),this['_view']=_0x4130f6,this['_toolbarConfig']=ot(_0x29314e['config']['get']('toolbar')),this['_elementReplacer']=new ht();}get['element'](){return this['view']['element'];}['init'](_0x35c617){const _0x209881=this['editor'],_0x4342a3=this['view'],_0x469314=_0x209881['editing']['view'],_0x4cbe64=_0x4342a3['editable'],_0x2b1120=_0x469314['document']['getRoot']();_0x4cbe64['name']=_0x2b1120['rootName'],_0x4342a3['render']();const _0xcd7cd3=_0x4cbe64['element'];this['setEditableElement'](_0x4cbe64['name'],_0xcd7cd3),_0x4342a3['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x469314['attachDomRoot'](_0xcd7cd3),this['_elementReplacer']['replace'](_0x35c617,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x541ebe=this['view'],_0x3a2c90=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x3a2c90['detachDomRoot'](_0x541ebe['editable']['name']),_0x541ebe['destroy']();}['_initToolbar'](){const _0x3208dd=this['view'];_0x3208dd['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x3208dd['stickyPanel']['limiterElement']=_0x3208dd['element'],_0x3208dd['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x3f529b})=>_0x3f529b),_0x3208dd['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x3208dd['toolbar']);}}class et extends ct{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x4a109e,_0x2123ff,_0x5b4a05={}){super(_0x4a109e),this['stickyPanel']=new ut(_0x4a109e),this['toolbar']=new lt(_0x4a109e,{'shouldGroupWhenFull':_0x5b4a05['shouldToolbarGroupWhenFull']}),this['_editable']=new dt(_0x4a109e,_0x2123ff);}['render'](){super['render'](),this['stickyPanel']['content']['add'](this['toolbar']),this['top']['add'](this['stickyPanel']),this['main']['add'](this['editable']);}}class R extends/* #__PURE__ -- @preserve */
29
- it(tt){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x1d55cb,_0x364253){super(_0x364253),this['sourceElement']=_0x1d55cb,this['model']['document']['createRoot']();const _0x160a0f=new et(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new rt(this,_0x160a0f);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x47306e,_0x41e474){const _0x4f0cfb=new this(_0x47306e,_0x41e474);return await _0x4f0cfb['initPlugins'](),await _0x4f0cfb['ui']['init'](_0x47306e),await _0x4f0cfb['data']['init'](_0x4f0cfb['config']['get']('initialData')||''),_0x4f0cfb['fire']('ready'),_0x4f0cfb;}}const p=['RevisionHistoryUI','RestrictedEditingMode'];class Rt extends _0x1448f8{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x1acd05){function _0x5b6458(_0x537220){return _0x537220['map'](_0x240579=>String['fromCharCode'](_0x240579))['join']('');}super(_0x1acd05),this['result']='end',_0x1acd05[_0x5b6458([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x5b6458([0x76,0x69,0x65,0x77])][_0x5b6458([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x5b6458([0x61,0x75,0x74,0x6f]),_0x1acd05[_0x5b6458([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x5b6458([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x5b6458([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x5b6458([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x5b6458([0x6f,0x6b])});}}class k extends _0x1448f8{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l,u];}constructor(_0x312663){if(super(_0x312663),!this['editor']['config']['get']('revisionHistory'))throw new _0x338b2b('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x337da7=>this['_showRevisionViewer']({..._0x337da7,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x1a95e0=>this['_closeRevisionViewer'](_0x1a95e0)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0x320320=>this['_restoreRevision'](_0x320320)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x636603){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x636603;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x90b535){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x90b535);}['getRevision'](_0x493ba4){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x493ba4);}['getRevisions'](_0x1a17d5){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x1a17d5||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x36fd37=this['editor'],_0x56f14c=_0x3e8257(_0x36fd37,p),_0x314d61=_0x36fd37['plugins']['get']('RevisionTracker'),_0x333de7=_0x36fd37['plugins']['get']('Users')['users'];return _0x56f14c['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x56f14c['lazyRoots'],(_0x56f14c['plugins']['push'](Rt,d,g,class extends _0x1448f8{static get['requires'](){return[d,'Users'];}['init'](){const _0x1a4c02=this['editor']['plugins']['get']('Users');for(const _0x15d0ca of _0x333de7)_0x15d0ca['isAnonymous']||_0x1a4c02['getUser'](_0x15d0ca['id'])||_0x1a4c02['addUser'](_0x15d0ca);const _0x2ba42f=_0x314d61['repository']['getRevisions']();let _0x47c433=null;const _0x48c298=this['editor']['plugins']['get']('RevisionViewer');_0x48c298['adapter']=_0x314d61['adapter'],_0x48c298['bind']('isEnabled')['to'](_0x314d61),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x36fd37,'isReadOnly',_0xa05caa=>!_0xa05caa);for(const _0x327d88 of _0x2ba42f){const _0x482905=null===_0x327d88['creator'];if(_0x482905&&_0x327d88['toVersion']===_0x327d88['fromVersion'])continue;const _0x51be81=_0x327d88['toJSON']();_0x48c298['addRevisionData'](_0x51be81,(_0x42366,_0x1ee25c,_0x5530e2)=>{if(_0x482905){if(_0x47c433)_0x47c433['_update'](_0x42366,_0x1ee25c);else{if(!_0x1ee25c){const _0x3883ff=_0x5530e2['toJSON']();_0x3883ff['id']=_0x346491(),_0x314d61['saveRevision'](_0x3883ff,_0x5530e2['toVersion'])['then'](_0xad7532=>{_0x47c433=_0xad7532;});}}}else _0x327d88['_update'](_0x42366,_0x1ee25c);});}}},w),_0x56f14c);}['_enhanceShowRevisionViewerCallback'](){const _0x2a1e92=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x351e26=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x4820b9=this['editor']['plugins']['get']('Autosave');await _0x4820b9['save']();}else await _0x351e26['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x34628a=this['editor']['plugins']['get']('Dialog');_0x34628a['isOpen']&&_0x34628a['hide']();}const _0xbfe814=this['_getRevisionViewerEditorConfig']();return _0x2a1e92(_0xbfe814)['then'](_0x24ca27=>{return(this['_viewerEditor']=_0x24ca27,this['editor']['plugins']['has']('Annotations'))&&this['editor']['plugins']['get']('Annotations')['refreshVisibility'](),_0x24ca27;})['catch'](_0x96461f=>(console['error'](_0x96461f),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x10ab4e=this['editor']['config']['get']('revisionHistory')['closeRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.closeRevisionViewerCallback',()=>(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['_viewerEditor']['plugins']['get']('RevisionViewer')['_cleanUp'](),_0x10ab4e(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0xc7547=this['editor']['plugins']['get']('Annotations');_0xc7547['refreshVisibility'](),_0xc7547['refreshPositioning']();}})));}['_showRevisionViewer'](_0x3d7229){const _0x4f7c49=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x2c43b4=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x132d5c=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return R['create'](_0x132d5c,_0x3d7229)['then'](_0x359a1e=>(_0x2c43b4['style']['display']='block',_0x4f7c49['style']['display']='none',_0x359a1e));}['_closeRevisionViewer'](_0x4061c3){const _0x4969f9=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x4969f9['style']['display']='',_0x4061c3['destroy']();}async['_restoreRevision'](_0x5b0956){const _0x122bb0=this['editor'],_0x33d61c=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x464b67=_0x122bb0['plugins']['get']('RevisionTracker'),_0x342ca7=_0x33d61c['repository']['getRevision'](_0x5b0956);let _0x3f43a4,_0x2de7cf,_0x4eb104;try{_0x3f43a4=await _0x33d61c['getRevisionData'](_0x342ca7),_0x2de7cf=await _0x33d61c['getRevisionRootsAttributes'](_0x342ca7);}catch(_0x6e9c1e){return void console['error'](_0x6e9c1e);}_0x122bb0['model']['change'](_0x56198a=>{for(const _0x2cc7c4 of Array['from'](_0x122bb0['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x56198a['removeMarker'](_0x2cc7c4);}),_0x33d61c['isReady']=!0x1,_0x122bb0['model']['enqueueChange'](_0x2ccd57=>{_0x2ccd57['setSelection'](null),_0x2ccd57['removeSelectionAttribute'](_0x122bb0['model']['document']['selection']['getAttributeKeys']());const _0x52ceca=Object['keys'](_0x3f43a4);for(const _0x4656ec of _0x122bb0['model']['document']['roots'])'$graveyard'!=_0x4656ec['rootName']&&_0x4656ec['isAttached']()&&!_0x52ceca['includes'](_0x4656ec['rootName'])&&_0x2ccd57['detachRoot'](_0x4656ec);for(const _0x53d34e of _0x52ceca){let _0x146e2d=_0x122bb0['model']['document']['getRoot'](_0x53d34e);_0x146e2d&&_0x146e2d['isAttached']()||(_0x146e2d=_0x2ccd57['addRoot'](_0x53d34e));const _0x10abb8=_0x2de7cf[_0x53d34e],_0x73482=Object['keys'](_0x10abb8),_0x42b39d=_0x3f43a4[_0x53d34e];for(const _0x26087a of _0x146e2d['getAttributeKeys']())_0x73482['includes'](_0x26087a)||_0x2ccd57['removeAttribute'](_0x26087a,_0x146e2d);for(const _0x46b75b of _0x73482)_0x2ccd57['setAttribute'](_0x46b75b,_0x2de7cf[_0x53d34e][_0x46b75b],_0x146e2d);_0x2ccd57['remove'](_0x2ccd57['createRangeIn'](_0x146e2d)),_0x2ccd57['insert'](_0x122bb0['data']['parse'](_0x42b39d,_0x146e2d),_0x146e2d,0x0);}});const _0x44ee6f=m(_0x122bb0['locale'],'Restored');if(_0x342ca7['name'])_0x4eb104=-0x1==_0x342ca7['name']['indexOf'](_0x44ee6f)?_0x44ee6f+':\x20'+_0x342ca7['name']:_0x342ca7['name'];else _0x4eb104=_0x44ee6f+':\x20'+(_0x342ca7['createdAt']['toLocaleDateString'](_0x122bb0['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x342ca7['createdAt']['toLocaleTimeString'](_0x122bb0['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x464b67['saveRevision']({'name':_0x4eb104}),_0x33d61c['isReady']=!0x0,_0x122bb0['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{a as Revision,k as RevisionHistory,u as RevisionHistoryUI,l as RevisionTracker,d as RevisionViewer,ae as RevisionViewerLoadingOverlay,g as RevisionViewerUI,j as RevisionsRepository,w as RevisionsSidebar};
28
+ bt();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[d];}constructor(_0x5b2d15){super(_0x5b2d15),this['_revisionViewer']=_0x5b2d15['plugins']['get'](d),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x4a344f=this['_revisionsRepository']['_revisions'],_0x497c6f=this['_createRevisionActions'](),_0x568c1d=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new li(this['editor']['locale'],_0x4a344f,_0x497c6f,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',(_0x57b532,_0x3ad903)=>{_0x3ad903['revisionViews']['on']('add',(_0x11032f,_0x5f0b01)=>{_0x5f0b01['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)),_0x568c1d['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x282db7=this['_revisionsRepository']['getRevision'](0x0);if(_0x282db7){const _0x2bbb9a=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x282db7['id']);this['_revisionViewer']['compare'](_0x282db7,_0x2bbb9a);}}['_handleRevisionSelected'](_0x344849,_0x4d473a){const _0xb8b811=this['_revisionsRepository']['getRevision'](_0x4d473a['id']),_0x1aeffe=this['_revisionsRepository']['getEarlierVisibleRevision'](_0xb8b811['id']);this['_revisionViewer']['compare'](_0xb8b811,_0x1aeffe);}['_handleRevisionSetName'](_0x1fa8b5,_0x32ce95){this['_revisionsRepository']['getRevision'](_0x32ce95['id'])['setName'](_0x32ce95['name']);}['_handleDiffChange'](_0x5afa19,_0x58eee3,_0x350578){const _0x17f975=this['_revisionsRepository']['getRevisionsInDiff'](_0x350578);_0x17f975['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x17f975),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x17f975[0x0]));}['_createRevisionActions'](){const _0x2c99d3=this['editor'],_0x37475e=w['availableRevisionActions'],_0x3a2cfb=_0x2c99d3['config']['get']('revisionHistory.revisionActions')||w['defaultRevisionActions'];if(_0x3a2cfb['length'])return _0x3a2cfb['map'](_0x160053=>{const _0x2c5dda='string'==typeof _0x160053?Object['assign']({},_0x37475e[_0x160053]):_0x160053;return _0x2c5dda['action']=_0x2c5dda['action']['bind'](this,_0x2c99d3),_0x2c5dda['isVisible']&&(_0x2c5dda['isVisible']=_0x2c5dda['isVisible']['bind'](this,_0x2c99d3)),_0x2c5dda;});}}function bt(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x20174a},_0x210359)=>{const _0x2526f6=_0x20174a['get'](d),_0x30ca42=_0x2526f6['repository'];let _0x927977=_0x2526f6['diff']['newRevisionId'],_0x321757=_0x210359['id'];_0x30ca42['getIndex'](_0x927977)>_0x30ca42['getIndex'](_0x321757)&&([_0x927977,_0x321757]=[_0x321757,_0x927977]),_0x2526f6['compare'](_0x927977,_0x321757);},'isVisible':({plugins:_0x7fc4ca},_0x41cf5e)=>{const _0x1ee59a=_0x7fc4ca['get'](d);return!(_0x1ee59a['repository']['getRevisionsInDiff'](_0x1ee59a['diff'])['length']>0x2)&&!_0x41cf5e['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x3348d4,{id:_0x13b86c})=>{_0x3348d4['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x13b86c);},'isVisible':({plugins:_0x4fa39a},_0xcfcb21)=>!!_0x4fa39a['get'](d)['repository']['getLaterVisibleRevision'](_0xcfcb21['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x3249d2},{id:_0x59f058,revisionNameView:_0x27940d})=>{const _0x2e5d4b=_0x3249d2['get'](d),_0x44a4ee=_0x2e5d4b['repository']['getEarlierVisibleRevision'](_0x59f058);_0x2e5d4b['compare'](_0x59f058,_0x44a4ee),_0x27940d['focus'](),_0x27940d['fieldView']['select']();}}};}class rt extends st{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x75e3e2,_0x10945e){super(_0x75e3e2),this['_view']=_0x10945e,this['_toolbarConfig']=ot(_0x75e3e2['config']['get']('toolbar')),this['_elementReplacer']=new ht();}get['element'](){return this['view']['element'];}['init'](_0x3c7229){const _0x1238b4=this['editor'],_0x4ea9f6=this['view'],_0x369bda=_0x1238b4['editing']['view'],_0xc775c3=_0x4ea9f6['editable'],_0x23a852=_0x369bda['document']['getRoot']();_0xc775c3['name']=_0x23a852['rootName'],_0x4ea9f6['render']();const _0x9ecf11=_0xc775c3['element'];this['setEditableElement'](_0xc775c3['name'],_0x9ecf11),_0x4ea9f6['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x369bda['attachDomRoot'](_0x9ecf11),this['_elementReplacer']['replace'](_0x3c7229,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x366efd=this['view'],_0x35cbac=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x35cbac['detachDomRoot'](_0x366efd['editable']['name']),_0x366efd['destroy']();}['_initToolbar'](){const _0x20e1ad=this['view'];_0x20e1ad['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x20e1ad['stickyPanel']['limiterElement']=_0x20e1ad['element'],_0x20e1ad['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x4dd40f})=>_0x4dd40f),_0x20e1ad['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x20e1ad['toolbar']);}}class et extends ct{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x1a408f,_0x19f83a,_0x2be172={}){super(_0x1a408f),this['stickyPanel']=new ut(_0x1a408f),this['toolbar']=new lt(_0x1a408f,{'shouldGroupWhenFull':_0x2be172['shouldToolbarGroupWhenFull']}),this['_editable']=new dt(_0x1a408f,_0x19f83a);}['render'](){super['render'](),this['stickyPanel']['content']['add'](this['toolbar']),this['top']['add'](this['stickyPanel']),this['main']['add'](this['editable']);}}class R extends/* #__PURE__ -- @preserve */
29
+ it(tt){['_ui'];get['ui'](){return this['_ui'];}constructor(_0x537846,_0xd3e528){super(_0xd3e528),this['sourceElement']=_0x537846,this['model']['document']['createRoot']();const _0x5d77ac=new et(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new rt(this,_0x5d77ac);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x19b7e3,_0x45d541){const _0x74fb5e=new this(_0x19b7e3,_0x45d541);return await _0x74fb5e['initPlugins'](),await _0x74fb5e['ui']['init'](_0x19b7e3),await _0x74fb5e['data']['init'](_0x74fb5e['config']['get']('initialData')||''),_0x74fb5e['fire']('ready'),_0x74fb5e;}}const p=['RevisionHistoryUI','RestrictedEditingMode'];class Rt extends _0x50f6d6{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x3c5ff7){function _0x3ee5ff(_0x3dd35a){return _0x3dd35a['map'](_0x2cebe6=>String['fromCharCode'](_0x2cebe6))['join']('');}super(_0x3c5ff7),this['result']='end',_0x3c5ff7[_0x3ee5ff([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x3ee5ff([0x76,0x69,0x65,0x77])][_0x3ee5ff([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x3ee5ff([0x61,0x75,0x74,0x6f]),_0x3c5ff7[_0x3ee5ff([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x3ee5ff([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x3ee5ff([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x3ee5ff([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x3ee5ff([0x6f,0x6b])});}}class k extends _0x50f6d6{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l,u];}constructor(_0x4eecd6){if(super(_0x4eecd6),!this['editor']['config']['get']('revisionHistory'))throw new _0x38454d('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x5b5ff9=>this['_showRevisionViewer']({..._0x5b5ff9,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x3457e6=>this['_closeRevisionViewer'](_0x3457e6)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0xffa543=>this['_restoreRevision'](_0xffa543)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x3422d6){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x3422d6;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x14e514){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x14e514);}['getRevision'](_0x484a3e){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x484a3e);}['getRevisions'](_0x26d215){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x26d215||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0xbcff0a=this['editor'],_0x123adb=_0x174262(_0xbcff0a,p),_0x5af0d1=_0xbcff0a['plugins']['get']('RevisionTracker'),_0x3bbec6=_0xbcff0a['plugins']['get']('Users')['users'];return _0x123adb['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x123adb['lazyRoots'],(_0x123adb['plugins']['push'](Rt,d,g,class extends _0x50f6d6{static get['requires'](){return[d,'Users'];}['init'](){const _0x1735b1=this['editor']['plugins']['get']('Users');for(const _0x375ed5 of _0x3bbec6)_0x375ed5['isAnonymous']||_0x1735b1['getUser'](_0x375ed5['id'])||_0x1735b1['addUser'](_0x375ed5);const _0x3070b0=_0x5af0d1['repository']['getRevisions']();let _0x2c9866=null;const _0x2af6b1=this['editor']['plugins']['get']('RevisionViewer');_0x2af6b1['adapter']=_0x5af0d1['adapter'],_0x2af6b1['bind']('isEnabled')['to'](_0x5af0d1),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0xbcff0a,'isReadOnly',_0x1c73b0=>!_0x1c73b0);for(const _0x3ffa0e of _0x3070b0){const _0x171881=null===_0x3ffa0e['creator'];if(_0x171881&&_0x3ffa0e['toVersion']===_0x3ffa0e['fromVersion'])continue;const _0x5ea060=_0x3ffa0e['toJSON']();_0x2af6b1['addRevisionData'](_0x5ea060,(_0x44153e,_0x34ee67,_0x31e2bf)=>{if(_0x171881){if(_0x2c9866)_0x2c9866['_update'](_0x44153e,_0x34ee67);else{if(!_0x34ee67){const _0x3ea2f8=_0x31e2bf['toJSON']();_0x3ea2f8['id']=_0x1fa053(),_0x5af0d1['saveRevision'](_0x3ea2f8,_0x31e2bf['toVersion'])['then'](_0x188635=>{_0x2c9866=_0x188635;});}}}else _0x3ffa0e['_update'](_0x44153e,_0x34ee67);});}}},w),_0x123adb);}['_enhanceShowRevisionViewerCallback'](){const _0x31fdd3=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x31a655=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x42ab2d=this['editor']['plugins']['get']('Autosave');await _0x42ab2d['save']();}else await _0x31a655['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x375cf6=this['editor']['plugins']['get']('Dialog');_0x375cf6['isOpen']&&_0x375cf6['hide']();}const _0x10d2b1=this['_getRevisionViewerEditorConfig']();return _0x31fdd3(_0x10d2b1)['then'](_0x5edc0a=>{return(this['_viewerEditor']=_0x5edc0a,this['editor']['plugins']['has']('Annotations'))&&this['editor']['plugins']['get']('Annotations')['refreshVisibility'](),_0x5edc0a;})['catch'](_0x5acfd3=>(console['error'](_0x5acfd3),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x48e0f9=this['editor']['config']['get']('revisionHistory')['closeRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.closeRevisionViewerCallback',()=>(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['_viewerEditor']['plugins']['get']('RevisionViewer')['_cleanUp'](),_0x48e0f9(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x46ad49=this['editor']['plugins']['get']('Annotations');_0x46ad49['refreshVisibility'](),_0x46ad49['refreshPositioning']();}})));}['_showRevisionViewer'](_0x3e2f3e){const _0x5e6278=this['editor']['config']['get']('revisionHistory.editorContainer'),_0xb7063e=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x35dcf9=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return R['create'](_0x35dcf9,_0x3e2f3e)['then'](_0x8097a=>(_0xb7063e['style']['display']='block',_0x5e6278['style']['display']='none',_0x8097a));}['_closeRevisionViewer'](_0x2e7fd8){const _0x2ea13a=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x2ea13a['style']['display']='',_0x2e7fd8['destroy']();}async['_restoreRevision'](_0xcdac58){const _0x2e96ed=this['editor'],_0x5a6bf4=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x5a44c0=_0x2e96ed['plugins']['get']('RevisionTracker'),_0x319645=_0x5a6bf4['repository']['getRevision'](_0xcdac58);let _0xffa89e,_0x3c03d5,_0x26f4a7;try{_0xffa89e=await _0x5a6bf4['getRevisionData'](_0x319645),_0x3c03d5=await _0x5a6bf4['getRevisionRootsAttributes'](_0x319645);}catch(_0x430172){return void console['error'](_0x430172);}_0x2e96ed['model']['change'](_0x1721b7=>{for(const _0x575b70 of Array['from'](_0x2e96ed['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x1721b7['removeMarker'](_0x575b70);}),_0x5a6bf4['isReady']=!0x1,_0x2e96ed['model']['enqueueChange'](_0x744212=>{_0x744212['setSelection'](null),_0x744212['removeSelectionAttribute'](_0x2e96ed['model']['document']['selection']['getAttributeKeys']());const _0x39c3d8=Object['keys'](_0xffa89e);for(const _0x3d74c4 of _0x2e96ed['model']['document']['roots'])'$graveyard'!=_0x3d74c4['rootName']&&_0x3d74c4['isAttached']()&&!_0x39c3d8['includes'](_0x3d74c4['rootName'])&&_0x744212['detachRoot'](_0x3d74c4);for(const _0x30a050 of _0x39c3d8){let _0x11bd9e=_0x2e96ed['model']['document']['getRoot'](_0x30a050);_0x11bd9e&&_0x11bd9e['isAttached']()||(_0x11bd9e=_0x744212['addRoot'](_0x30a050));const _0x59ac13=_0x3c03d5[_0x30a050],_0x22a23c=Object['keys'](_0x59ac13),_0x3bc51d=_0xffa89e[_0x30a050];for(const _0x32ce36 of _0x11bd9e['getAttributeKeys']())_0x22a23c['includes'](_0x32ce36)||_0x744212['removeAttribute'](_0x32ce36,_0x11bd9e);for(const _0x1c4f3a of _0x22a23c)_0x744212['setAttribute'](_0x1c4f3a,_0x3c03d5[_0x30a050][_0x1c4f3a],_0x11bd9e);_0x744212['remove'](_0x744212['createRangeIn'](_0x11bd9e)),_0x744212['insert'](_0x2e96ed['data']['parse'](_0x3bc51d,_0x11bd9e),_0x11bd9e,0x0);}});const _0xdaa7fb=m(_0x2e96ed['locale'],'Restored');if(_0x319645['name'])_0x26f4a7=-0x1==_0x319645['name']['indexOf'](_0xdaa7fb)?_0xdaa7fb+':\x20'+_0x319645['name']:_0x319645['name'];else _0x26f4a7=_0xdaa7fb+':\x20'+(_0x319645['createdAt']['toLocaleDateString'](_0x2e96ed['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x319645['createdAt']['toLocaleTimeString'](_0x2e96ed['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x5a44c0['saveRevision']({'name':_0x26f4a7}),_0x5a6bf4['isReady']=!0x0,_0x2e96ed['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{a as Revision,k as RevisionHistory,u as RevisionHistoryUI,l as RevisionTracker,d as RevisionViewer,ae as RevisionViewerLoadingOverlay,g as RevisionViewerUI,j as RevisionsRepository,w as RevisionsSidebar};