@ckeditor/ckeditor5-revision-history 0.0.0-nightly-20250302.0 → 0.0.0-nightly-next-20250302.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 (183) hide show
  1. package/LICENSE.md +1 -1
  2. package/build/revision-history.js +1 -1
  3. package/ckeditor5-metadata.json +1 -1
  4. package/dist/index.js +6 -6
  5. package/dist/translations/af.js +1 -1
  6. package/dist/translations/af.umd.js +1 -1
  7. package/dist/translations/ar.js +1 -1
  8. package/dist/translations/ar.umd.js +1 -1
  9. package/dist/translations/ast.js +1 -1
  10. package/dist/translations/ast.umd.js +1 -1
  11. package/dist/translations/az.js +1 -1
  12. package/dist/translations/az.umd.js +1 -1
  13. package/dist/translations/bg.js +1 -1
  14. package/dist/translations/bg.umd.js +1 -1
  15. package/dist/translations/bn.js +1 -1
  16. package/dist/translations/bn.umd.js +1 -1
  17. package/dist/translations/bs.js +1 -1
  18. package/dist/translations/bs.umd.js +1 -1
  19. package/dist/translations/ca.js +1 -1
  20. package/dist/translations/ca.umd.js +1 -1
  21. package/dist/translations/cs.js +1 -1
  22. package/dist/translations/cs.umd.js +1 -1
  23. package/dist/translations/da.js +1 -1
  24. package/dist/translations/da.umd.js +1 -1
  25. package/dist/translations/de-ch.js +1 -1
  26. package/dist/translations/de-ch.umd.js +1 -1
  27. package/dist/translations/de.js +1 -1
  28. package/dist/translations/de.umd.js +1 -1
  29. package/dist/translations/el.js +1 -1
  30. package/dist/translations/el.umd.js +1 -1
  31. package/dist/translations/en-au.js +1 -1
  32. package/dist/translations/en-au.umd.js +1 -1
  33. package/dist/translations/en-gb.js +1 -1
  34. package/dist/translations/en-gb.umd.js +1 -1
  35. package/dist/translations/en.js +1 -1
  36. package/dist/translations/en.umd.js +1 -1
  37. package/dist/translations/eo.js +1 -1
  38. package/dist/translations/eo.umd.js +1 -1
  39. package/dist/translations/es-co.js +1 -1
  40. package/dist/translations/es-co.umd.js +1 -1
  41. package/dist/translations/es.js +1 -1
  42. package/dist/translations/es.umd.js +1 -1
  43. package/dist/translations/et.js +1 -1
  44. package/dist/translations/et.umd.js +1 -1
  45. package/dist/translations/eu.js +1 -1
  46. package/dist/translations/eu.umd.js +1 -1
  47. package/dist/translations/fa.js +1 -1
  48. package/dist/translations/fa.umd.js +1 -1
  49. package/dist/translations/fi.js +1 -1
  50. package/dist/translations/fi.umd.js +1 -1
  51. package/dist/translations/fr.js +1 -1
  52. package/dist/translations/fr.umd.js +1 -1
  53. package/dist/translations/gl.js +1 -1
  54. package/dist/translations/gl.umd.js +1 -1
  55. package/dist/translations/gu.js +1 -1
  56. package/dist/translations/gu.umd.js +1 -1
  57. package/dist/translations/he.js +1 -1
  58. package/dist/translations/he.umd.js +1 -1
  59. package/dist/translations/hi.js +1 -1
  60. package/dist/translations/hi.umd.js +1 -1
  61. package/dist/translations/hr.js +1 -1
  62. package/dist/translations/hr.umd.js +1 -1
  63. package/dist/translations/hu.js +1 -1
  64. package/dist/translations/hu.umd.js +1 -1
  65. package/dist/translations/hy.js +1 -1
  66. package/dist/translations/hy.umd.js +1 -1
  67. package/dist/translations/id.js +1 -1
  68. package/dist/translations/id.umd.js +1 -1
  69. package/dist/translations/it.js +1 -1
  70. package/dist/translations/it.umd.js +1 -1
  71. package/dist/translations/ja.js +1 -1
  72. package/dist/translations/ja.umd.js +1 -1
  73. package/dist/translations/jv.js +1 -1
  74. package/dist/translations/jv.umd.js +1 -1
  75. package/dist/translations/kk.js +1 -1
  76. package/dist/translations/kk.umd.js +1 -1
  77. package/dist/translations/km.js +1 -1
  78. package/dist/translations/km.umd.js +1 -1
  79. package/dist/translations/kn.js +1 -1
  80. package/dist/translations/kn.umd.js +1 -1
  81. package/dist/translations/ko.js +1 -1
  82. package/dist/translations/ko.umd.js +1 -1
  83. package/dist/translations/ku.js +1 -1
  84. package/dist/translations/ku.umd.js +1 -1
  85. package/dist/translations/lt.js +1 -1
  86. package/dist/translations/lt.umd.js +1 -1
  87. package/dist/translations/lv.js +1 -1
  88. package/dist/translations/lv.umd.js +1 -1
  89. package/dist/translations/ms.js +1 -1
  90. package/dist/translations/ms.umd.js +1 -1
  91. package/dist/translations/nb.js +1 -1
  92. package/dist/translations/nb.umd.js +1 -1
  93. package/dist/translations/ne.js +1 -1
  94. package/dist/translations/ne.umd.js +1 -1
  95. package/dist/translations/nl.js +1 -1
  96. package/dist/translations/nl.umd.js +1 -1
  97. package/dist/translations/no.js +1 -1
  98. package/dist/translations/no.umd.js +1 -1
  99. package/dist/translations/oc.js +1 -1
  100. package/dist/translations/oc.umd.js +1 -1
  101. package/dist/translations/pl.js +1 -1
  102. package/dist/translations/pl.umd.js +1 -1
  103. package/dist/translations/pt-br.js +1 -1
  104. package/dist/translations/pt-br.umd.js +1 -1
  105. package/dist/translations/pt.js +1 -1
  106. package/dist/translations/pt.umd.js +1 -1
  107. package/dist/translations/ro.js +1 -1
  108. package/dist/translations/ro.umd.js +1 -1
  109. package/dist/translations/ru.js +1 -1
  110. package/dist/translations/ru.umd.js +1 -1
  111. package/dist/translations/si.js +1 -1
  112. package/dist/translations/si.umd.js +1 -1
  113. package/dist/translations/sk.js +1 -1
  114. package/dist/translations/sk.umd.js +1 -1
  115. package/dist/translations/sl.js +1 -1
  116. package/dist/translations/sl.umd.js +1 -1
  117. package/dist/translations/sq.js +1 -1
  118. package/dist/translations/sq.umd.js +1 -1
  119. package/dist/translations/sr-latn.js +1 -1
  120. package/dist/translations/sr-latn.umd.js +1 -1
  121. package/dist/translations/sr.js +1 -1
  122. package/dist/translations/sr.umd.js +1 -1
  123. package/dist/translations/sv.js +1 -1
  124. package/dist/translations/sv.umd.js +1 -1
  125. package/dist/translations/th.js +1 -1
  126. package/dist/translations/th.umd.js +1 -1
  127. package/dist/translations/ti.js +1 -1
  128. package/dist/translations/ti.umd.js +1 -1
  129. package/dist/translations/tk.js +1 -1
  130. package/dist/translations/tk.umd.js +1 -1
  131. package/dist/translations/tr.js +1 -1
  132. package/dist/translations/tr.umd.js +1 -1
  133. package/dist/translations/tt.js +1 -1
  134. package/dist/translations/tt.umd.js +1 -1
  135. package/dist/translations/ug.js +1 -1
  136. package/dist/translations/ug.umd.js +1 -1
  137. package/dist/translations/uk.js +1 -1
  138. package/dist/translations/uk.umd.js +1 -1
  139. package/dist/translations/ur.js +1 -1
  140. package/dist/translations/ur.umd.js +1 -1
  141. package/dist/translations/uz.js +1 -1
  142. package/dist/translations/uz.umd.js +1 -1
  143. package/dist/translations/vi.js +1 -1
  144. package/dist/translations/vi.umd.js +1 -1
  145. package/dist/translations/zh-cn.js +1 -1
  146. package/dist/translations/zh-cn.umd.js +1 -1
  147. package/dist/translations/zh.js +1 -1
  148. package/dist/translations/zh.umd.js +1 -1
  149. package/package.json +12 -11
  150. package/src/changeitem.js +2 -2
  151. package/src/editor/revisionviewereditor.js +2 -2
  152. package/src/editor/revisionviewereditorui.js +1 -1
  153. package/src/editor/revisionviewereditoruiview.js +1 -1
  154. package/src/index.js +1 -1
  155. package/src/revision.js +2 -2
  156. package/src/revisiondiff.js +1 -1
  157. package/src/revisionhistory.js +1 -1
  158. package/src/revisionsrepository.js +1 -1
  159. package/src/revisiontracker.js +1 -1
  160. package/src/revisionviewer.js +1 -1
  161. package/src/ui/revision/createrevisionactionsdropdown.js +1 -1
  162. package/src/ui/revision/revisionauthorview.js +1 -1
  163. package/src/ui/revision/revisionnameview.js +1 -1
  164. package/src/ui/revision/revisionview.js +2 -2
  165. package/src/ui/revision/subrevisioncollapserview.js +1 -1
  166. package/src/ui/revision/subrevisionview.js +1 -1
  167. package/src/ui/revision/utils.js +1 -1
  168. package/src/ui/revisionhistory/revisionhistorysaverevisionformview.js +1 -1
  169. package/src/ui/revisionhistory/revisionhistoryui.js +1 -1
  170. package/src/ui/revisionssidebar/revisionssidebar.js +1 -1
  171. package/src/ui/revisionssidebar/revisionssidebarheaderview.js +1 -1
  172. package/src/ui/revisionssidebar/revisionssidebartimeperiodview.js +1 -1
  173. package/src/ui/revisionssidebar/revisionssidebarview.js +1 -1
  174. package/src/ui/revisionssidebar/utils.js +1 -1
  175. package/src/ui/revisionviewer/changedetailsview.js +1 -1
  176. package/src/ui/revisionviewer/changesnavigationview.js +1 -1
  177. package/src/ui/revisionviewer/revisionviewerloadingoverlay.js +1 -1
  178. package/src/ui/revisionviewer/revisionviewerui.js +1 -1
  179. package/src/utils/common-translations.js +1 -1
  180. package/theme/icons/arrow-down.svg +0 -1
  181. package/theme/icons/arrow-up.svg +0 -1
  182. package/theme/icons/revision-history.svg +0 -1
  183. package/theme/icons/user.svg +0 -1
package/dist/index.js CHANGED
@@ -20,10 +20,10 @@
20
20
  *
21
21
  *
22
22
  */
23
- import{ObservableMixin as _0x167bf9,uid as _0x41fc2a,Collection as _0x53ab85,logWarning as _0x286457,FocusTracker as _0x1839c5,KeystrokeHandler as _0x1b4f1b,scrollViewportToShowTarget as _0x4a98c9,ResizeObserver as at,ElementReplacer as ht,CKEditorError as _0x479dc4}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x1e8d51,set as _0x295a3b,unset as _0x12cf5a,isEqual as _0x2827e5}from'lodash-es';import{Plugin as _0x15974b,PendingActions as _0x2b30d8,icons as _0x470fce,Command as _0x2c1871,ElementApiMixin as it,Editor as tt}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x569660,getMarkerDomElement as _0x48dfde,ConfirmMixin as _0x29c051,sanitizeEditorConfig as _0x1e0a56}from'ckeditor5-collaboration/dist/index.js';import{ViewDocumentFragment as _0x1a018e,Element as ft,Range as vt,ViewUIElement as _0x3bc906,ViewRawElement as _0x87c2e2,ViewEmptyElement as _0xbfca74,ViewAttributeElement as _0x31818f,ViewContainerElement as _0x281cbc,Position as gt,ViewText as _0xf6e769,ViewElement as _0xf7d26d,DocumentFragment as mt,Text as wt}from'@ckeditor/ckeditor5-engine/dist/index.js';import{View as _0x1d6e15,injectCssTransitionDisabler as ts,submitHandler as _0x1a3f56,LabeledFieldView as nt,createLabeledInputText as _0x5d5d36,createDropdown as _0x3ccc2a,ListView as te,ListItemView as _0x5e7b7c,ButtonView as _0x3cc15e,MenuBarMenuView as _0x461892,MenuBarMenuListView as _0xe5be03,MenuBarMenuListItemView as _0x3139e6,MenuBarMenuListItemButtonView as _0x2df223,ContextualBalloon as _0x2e7606,ToolbarSeparatorView as _0x2cc299,IconView as _0x228ef3,addListToDropdown as _0x22175d,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 _0x343446}from'luxon';class a extends/* #__PURE__ -- @preserve */
24
- _0x167bf9(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x394a80){super(),this['id']=_0x394a80['id']||_0x41fc2a(),this['creator']=_0x394a80['creator']||null,this['authors']=_0x394a80['authors']||[],this['diffData']=_0x394a80['diffData']||null,this['toVersion']=_0x394a80['toVersion']||0x0,this['fromVersion']=_0x394a80['fromVersion']||0x0,this['set']('name',_0x394a80['name']||''),this['set']('createdAt',_0x394a80['createdAt']||new Date()),this['set']('attributes',_0x394a80['attributes']||{});}['setName'](_0x482a8b){this['_update']({'name':_0x482a8b});}['setAttribute'](_0x5dbcb4,_0x41e2a4){const _0x480a83=_0x1e8d51(this['attributes']);_0x295a3b(_0x480a83,_0x5dbcb4,_0x41e2a4),this['_update']({'attributes':_0x480a83});}['removeAttribute'](_0x54bb34){const _0x1d9a9f=_0x1e8d51(this['attributes']);_0x12cf5a(_0x1d9a9f,_0x54bb34),this['_update']({'attributes':_0x1d9a9f});}['_update'](_0x56ebdf,_0x489865=!0x1){let _0x2b0ffe=!0x1;const _0x34b1d0={'id':this['id']},_0x246328=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x59936d of _0x246328){const _0x48385a=_0x56ebdf[_0x59936d];void 0x0!==_0x48385a&&_0x48385a!==this[_0x59936d]&&(this[_0x59936d]=_0x48385a,_0x34b1d0[_0x59936d]=_0x48385a,_0x2b0ffe=!0x0);}_0x2b0ffe&&(_0x34b1d0['authors']&&(_0x34b1d0['authorsIds']=_0x34b1d0['authors']['map'](_0x10aacf=>_0x10aacf['id']),delete _0x34b1d0['authors']),this['fire']('_update',_0x34b1d0,_0x489865));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0xc213c7=>_0xc213c7['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class j extends _0x15974b{['_revisions'];static get['requires'](){return[_0x569660];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x380a9f){super(_0x380a9f),this['_revisions']=new _0x53ab85();}['afterInit'](){!async function(_0x56f8af){const _0x538604=_0x7f7a87([0x50,0x30,0x4a,0x48,0x57,0x75,0x64,0x7a,0x72,0x42,0x34,0x51,0x58,0x31,0x77,0x32,0x56,0x5a,0x43,0x55,0x37,0x4d,0x63,0x4e,0x76,0x6b,0x33,0x45,0x39,0x78,0x73,0x61,0x41,0x71,0x46,0x52,0x70,0x44,0x62,0x79,0x74,0x65,0x68,0x38,0x35,0x54,0x36,0x4f,0x6f,0x4b,0x66,0x59,0x6a,0x49,0x6c,0x6e,0x6d,0x4c,0x47,0x69,0x53,0x67]),_0xf2d84b=0xeb829,_0x511ab2=0x173448d9,_0x5c5dbb=0x17332821^_0x511ab2,_0x472b8d=window[_0x7f7a87([0x44,0x61,0x74,0x65])][_0x7f7a87([0x6e,0x6f,0x77])](),_0x5ebb96=_0x56f8af[_0x7f7a87([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x43ac34=new window[(_0x7f7a87([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x52633e=>{_0x5ebb96[_0x7f7a87([0x6f,0x6e,0x63,0x65])](_0x7f7a87([0x72,0x65,0x61,0x64,0x79]),_0x52633e);}),_0x3f226b={[_0x7f7a87([0x6b,0x74,0x79])]:_0x7f7a87([0x45,0x43]),[_0x7f7a87([0x75,0x73,0x65])]:_0x7f7a87([0x73,0x69,0x67]),[_0x7f7a87([0x63,0x72,0x76])]:_0x7f7a87([0x50,0x2d,0x32,0x35,0x36]),[_0x7f7a87([0x78])]:_0x7f7a87([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]),[_0x7f7a87([0x79])]:_0x7f7a87([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]),[_0x7f7a87([0x61,0x6c,0x67])]:_0x7f7a87([0x45,0x53,0x32,0x35,0x36])},_0x5199f0=_0x5ebb96[_0x7f7a87([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x7f7a87([0x67,0x65,0x74])](_0x7f7a87([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x1c5377(){let _0x3ec5fb,_0x14212d=null,_0x3ad822=null;try{if(_0x5199f0==_0x7f7a87([0x47,0x50,0x4c]))return _0x7f7a87([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x3ec5fb=_0x16862f(),!_0x3ec5fb)return _0x7f7a87([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x3ec5fb[_0x7f7a87([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x3ad822=_0x95ae06(_0x3ec5fb[_0x7f7a87([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x3ec5fb[_0x7f7a87([0x6a,0x74,0x69])])),await _0x50571f()?_0x2f4c54()?_0x48c837()?_0x7f7a87([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x7fd20()?(_0x3ec5fb[_0x7f7a87([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x7f7a87([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x14212d=_0xe6b0ac(_0x7f7a87([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x3ec5fb[_0x7f7a87([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x7f7a87([0x74,0x72,0x69,0x61,0x6c])&&(_0x14212d=_0xe6b0ac(_0x7f7a87([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x349cfa()):_0x7f7a87([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x7f7a87([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x7f7a87([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch(_0x172dfa){return _0x7f7a87([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x48c837(){const _0x4cadf0=[_0x7f7a87([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x7f7a87([0x74,0x72,0x69,0x61,0x6c])][_0x7f7a87([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x3ec5fb[_0x7f7a87([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x472b8d/0x3e8:0xe10*_0x5c5dbb;return _0x3ec5fb[_0x7f7a87([0x65,0x78,0x70])]<_0x4cadf0;}function _0x2f4c54(){const _0x403243=_0x3ec5fb[_0x7f7a87([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x403243)return!0x1;if(_0x403243[_0x7f7a87([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x7f7a87([0x2a])))return!0x0;if(_0x403243[_0x7f7a87([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x7f7a87([0x52,0x48])))return!0x0;if(_0x403243[_0x7f7a87([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x7f7a87([0x52,0x52,0x48]))){if(_0x1bb5a2())return!0x0;if(_0x410393()||_0x5ccf74())return!0x0;}return!0x1;}function _0x7fd20(){const _0x20644e=_0x3ec5fb[_0x7f7a87([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x20644e||0x0==_0x20644e[_0x7f7a87([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x1c0936}=new URL(window[_0x7f7a87([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x20644e[_0x7f7a87([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x1c0936))return!0x0;const _0x590dbf=_0x1c0936[_0x7f7a87([0x73,0x70,0x6c,0x69,0x74])](_0x7f7a87([0x2e]));return _0x20644e[_0x7f7a87([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x374855=>_0x374855[_0x7f7a87([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x7f7a87([0x2a])))[_0x7f7a87([0x6d,0x61,0x70])](_0x18e620=>_0x18e620[_0x7f7a87([0x73,0x70,0x6c,0x69,0x74])](_0x7f7a87([0x2e])))[_0x7f7a87([0x73,0x6f,0x6d,0x65])](_0x51a2d5=>_0x590dbf[_0x7f7a87([0x65,0x76,0x65,0x72,0x79])]((_0x345277,_0x1d571f)=>_0x51a2d5[_0x1d571f]===_0x345277||_0x51a2d5[_0x1d571f]===_0x7f7a87([0x2a])));}function _0x349cfa(){return _0x14212d&&_0x3ad822?new window[(_0x7f7a87([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x160ac2,_0x363138)=>{_0x14212d[_0x7f7a87([0x74,0x68,0x65,0x6e])](_0x160ac2,_0x363138),_0x3ad822[_0x7f7a87([0x74,0x68,0x65,0x6e])](_0x24ec94=>{_0x24ec94!=_0x7f7a87([0x56,0x61,0x6c,0x69,0x64])&&_0x160ac2(_0x24ec94);},_0x363138);}):_0x14212d||_0x3ad822||_0x7f7a87([0x56,0x61,0x6c,0x69,0x64]);}}function _0x95ae06(_0x208928,_0x2a1c07){return new window[(_0x7f7a87([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2916b3=>{if(_0x4732aa())return _0x2916b3(_0x7f7a87([0x56,0x61,0x6c,0x69,0x64]));_0x204863(),_0x5ebb96[_0x7f7a87([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x7f7a87([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x5b3fcc=!0x1;const _0x1a9070=_0x41fc2a();function _0x256602(_0x1216b3){return!!_0x1216b3&&(typeof _0x1216b3===_0x7f7a87([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x1216b3===_0x7f7a87([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x1216b3[_0x7f7a87([0x74,0x68,0x65,0x6e])]===_0x7f7a87([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x1216b3[_0x7f7a87([0x63,0x61,0x74,0x63,0x68])]===_0x7f7a87([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x46cf81(_0x2bf59){_0x3f7419(_0x2bf59)[_0x7f7a87([0x74,0x68,0x65,0x6e])](_0x172b5a=>{if(!_0x172b5a||_0x172b5a[_0x7f7a87([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x7f7a87([0x6f,0x6b]))return _0x7f7a87([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x1a7126(_0x185de4(_0x1a9070+_0x2a1c07))!=_0x172b5a[_0x7f7a87([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x7f7a87([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x7f7a87([0x56,0x61,0x6c,0x69,0x64]);})[_0x7f7a87([0x74,0x68,0x65,0x6e])](_0x2b375f=>(_0x39b874(),_0x2b375f),()=>{const _0x18d75b=_0x5ea983();return null==_0x18d75b?(_0x39b874(),_0x7f7a87([0x56,0x61,0x6c,0x69,0x64])):_0x7f7a87(_0x472b8d-_0x18d75b>(0x3338ccd9^_0x511ab2)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x7f7a87([0x74,0x68,0x65,0x6e])](_0x2916b3)[_0x7f7a87([0x63,0x61,0x74,0x63,0x68])](()=>{_0x2916b3(_0x7f7a87([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x1bf19c=0x1702a659^_0x511ab2;function _0x39b874(){const _0xa92c2e=_0x7f7a87([0x6c,0x6c,0x63,0x74,0x2d])+_0x1a7126(_0x185de4(_0x208928)),_0x2d2fab=_0x8521a2(_0x1a7126(window[_0x7f7a87([0x4d,0x61,0x74,0x68])][_0x7f7a87([0x63,0x65,0x69,0x6c])](_0x472b8d/_0x1bf19c)));window[_0x7f7a87([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x7f7a87([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0xa92c2e,_0x2d2fab);}function _0x5ea983(){const _0x644ee4=_0x7f7a87([0x6c,0x6c,0x63,0x74,0x2d])+_0x1a7126(_0x185de4(_0x208928)),_0x3f31db=window[_0x7f7a87([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x7f7a87([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x644ee4);return _0x3f31db?window[_0x7f7a87([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x8521a2(_0x3f31db),0x10)*_0x1bf19c:null;}function _0x3f7419(_0x28a89c){return new window[(_0x7f7a87([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0xde5ab0,_0x4df026)=>{_0x28a89c[_0x7f7a87([0x74,0x68,0x65,0x6e])](_0xde5ab0,_0x4df026),window[_0x7f7a87([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x4df026,0x17359c19^_0x511ab2);});}}_0x5ebb96[_0x7f7a87([0x6f,0x6e])](_0x7f7a87([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x525be8,_0x5a5b88)=>{if(_0x5a5b88[0x0]!=_0x208928)return _0x2916b3(_0x7f7a87([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x5a5b88[0x1]={..._0x5a5b88[0x1],[_0x7f7a87([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x1a9070};},{[_0x7f7a87([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x7f7a87([0x68,0x69,0x67,0x68])}),_0x5ebb96[_0x7f7a87([0x6f,0x6e])](_0x7f7a87([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x3f697b=>{_0x256602(_0x3f697b[_0x7f7a87([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x5b3fcc=!0x0,_0x46cf81(_0x3f697b[_0x7f7a87([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x7f7a87([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x7f7a87([0x6c,0x6f,0x77])}),_0x43ac34[_0x7f7a87([0x74,0x68,0x65,0x6e])](()=>{_0x5b3fcc||_0x2916b3(_0x7f7a87([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x4732aa(){return _0x5ebb96[_0x7f7a87([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x7f7a87([0x76,0x69,0x65,0x77])][_0x7f7a87([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x7f7a87([0x61,0x75,0x74,0x6f]);}function _0x204863(){_0x5ebb96[_0x7f7a87([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x7f7a87([0x76,0x69,0x65,0x77])][_0x7f7a87([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x7f7a87([0x61,0x75,0x74,0x6f]);}}function _0xe6b0ac(_0x27eb01){const _0x38ee96=[new window[(_0x7f7a87([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x451db5=>setTimeout(_0x451db5,0x173d7615^_0x511ab2)),_0x43ac34[_0x7f7a87([0x74,0x68,0x65,0x6e])](()=>new window[(_0x7f7a87([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x439724=>{const _0x533718=0x173448de^_0x511ab2,_0x223020=_0x56f8af[_0x7f7a87([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x3115cd(){_0x223020[_0x7f7a87([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x533718&&_0x439724();}_0x3115cd(),_0x223020[_0x7f7a87([0x6f,0x6e])](_0x7f7a87([0x61,0x64,0x64]),_0x3115cd);})),new window[(_0x7f7a87([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2eae88=>{function _0x21ce7d(){for(const _0x48b39d in window)if(window[_0x7f7a87([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x7f7a87([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x48b39d))&&window[_0x48b39d]==_0xf2d84b)return _0x2eae88();_0x5ebb96[_0x7f7a87([0x73,0x74,0x61,0x74,0x65])]!=_0x7f7a87([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x7f7a87([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x21ce7d,0x17345b51^_0x511ab2);}_0x35f508(_0x7f7a87([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x21ce7d();})];return window[_0x7f7a87([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x7f7a87([0x72,0x61,0x63,0x65])](_0x38ee96)[_0x7f7a87([0x74,0x68,0x65,0x6e])](()=>_0x27eb01);}async function _0x4abcab(){if(await _0x43ac34,_0x35f508(_0x7f7a87([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x158739=_0x56f8af[_0x7f7a87([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x1f51d6=_0x56f8af[_0x7f7a87([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])](_0x158739[_0x7f7a87([0x69,0x64])]),_0xd129fc=_0x903479(_0x7f7a87([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0xd129fc[_0x7f7a87([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x158739['id'],_0x1f51d6?_0x1f51d6['id']:null,!0x0),_0xd129fc[_0x7f7a87([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x7f7a87([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0xd129fc[_0x7f7a87([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0xd129fc[_0x7f7a87([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x557cf0,void(_0xd129fc[_0x7f7a87([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x557cf0);}if(_0x35f508(_0x7f7a87([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x38a79f=_0x903479(_0x7f7a87([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x38a79f[_0x7f7a87([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x7f7a87([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x38a79f[_0x7f7a87([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x38a79f[_0x7f7a87([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x557cf0,_0x38a79f[_0x7f7a87([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x557cf0;}_0x5ebb96[_0x7f7a87([0x6d,0x6f,0x64,0x65,0x6c])][_0x7f7a87([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x557cf0,_0x5ebb96[_0x7f7a87([0x6d,0x6f,0x64,0x65,0x6c])][_0x7f7a87([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x557cf0,_0x5ebb96[_0x7f7a87([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x7f7a87([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x1bb5a2(){return _0x35f508(_0x7f7a87([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x903479(_0x7f7a87([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x7f7a87([0x73,0x74,0x61,0x74,0x65])]==_0x7f7a87([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x410393(){return _0x35f508(_0x7f7a87([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 _0x5ccf74(){return _0x35f508(_0x7f7a87([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x28f128(_0x35dba7){const _0x52fd9b=_0x299098();_0x5ebb96[_0x52fd9b]=_0x7f7a87([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])+_0x35dba7,_0x35dba7[_0x7f7a87([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x7f7a87([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x299098()]=_0xf2d84b),_0x35dba7!=_0x7f7a87([0x56,0x61,0x6c,0x69,0x64])&&_0x4abcab();}function _0x299098(){const _0xb89b01=window[_0x7f7a87([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x7f7a87([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x7f7a87([0x6e,0x6f,0x77])]())[_0x7f7a87([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x7f7a87([0x2e]),'');let _0x3e4a38=_0x7f7a87([0x50]);for(let _0x2f28ba=0x0;_0x2f28ba<_0xb89b01[_0x7f7a87([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x2f28ba+=0x2){let _0x47e71d=window[_0x7f7a87([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0xb89b01[_0x7f7a87([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x2f28ba,_0x2f28ba+0x2));_0x47e71d>=_0x538604[_0x7f7a87([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x47e71d-=_0x538604[_0x7f7a87([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x3e4a38+=_0x538604[_0x47e71d];}return _0x3e4a38;}function _0x16862f(){const _0x17df55=_0x5199f0[_0x7f7a87([0x73,0x70,0x6c,0x69,0x74])](_0x7f7a87([0x2e]));if(0x3!=_0x17df55[_0x7f7a87([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x3d04bc(_0x17df55[0x1]);function _0x3d04bc(_0x123d60){const _0x14cf8e=_0x3a38eb(_0x123d60);return _0x14cf8e&&_0x229bb4()?_0x14cf8e:null;function _0x229bb4(){const _0x4470e4=_0x14cf8e[_0x7f7a87([0x6a,0x74,0x69])],_0x4ce905=window[_0x7f7a87([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x4470e4[_0x7f7a87([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x4470e4[_0x7f7a87([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0x39d8a4={..._0x14cf8e,[_0x7f7a87([0x6a,0x74,0x69])]:_0x4470e4[_0x7f7a87([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x4470e4[_0x7f7a87([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0x39d8a4[_0x7f7a87([0x76,0x63])],_0x185de4(_0x39d8a4)==_0x4ce905;}}}async function _0x50571f(){let _0x41278f=!0x0;try{const _0x180499=_0x5199f0[_0x7f7a87([0x73,0x70,0x6c,0x69,0x74])](_0x7f7a87([0x2e])),[_0xf48617,_0x196c20,_0x397bd5]=_0x180499;return _0xfa0b17(_0xf48617),await _0x21bd09(_0xf48617,_0x196c20,_0x397bd5),_0x41278f;}catch(_0x144110){return!0x1;}function _0xfa0b17(_0x116587){const _0x5c2b58=_0x3a38eb(_0x116587);_0x5c2b58&&_0x5c2b58[_0x7f7a87([0x61,0x6c,0x67])]==_0x7f7a87([0x45,0x53,0x32,0x35,0x36])||(_0x41278f=!0x1);}async function _0x21bd09(_0x572061,_0x1828c6,_0x470e5e){const _0x35c8fa=window[_0x7f7a87([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x7f7a87([0x66,0x72,0x6f,0x6d])](_0x202688(_0x470e5e),_0x1fbc1c=>_0x1fbc1c[_0x7f7a87([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x2da2ff=new window[(_0x7f7a87([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x7f7a87([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x572061+_0x7f7a87([0x2e])+_0x1828c6),_0x38b579=window[_0x7f7a87([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x7f7a87([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x38b579)return;const _0x46e8b4=await _0x38b579[_0x7f7a87([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x7f7a87([0x6a,0x77,0x6b]),_0x3f226b,{[_0x7f7a87([0x6e,0x61,0x6d,0x65])]:_0x7f7a87([0x45,0x43,0x44,0x53,0x41]),[_0x7f7a87([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x7f7a87([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x7f7a87([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x38b579[_0x7f7a87([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x7f7a87([0x6e,0x61,0x6d,0x65])]:_0x7f7a87([0x45,0x43,0x44,0x53,0x41]),[_0x7f7a87([0x68,0x61,0x73,0x68])]:{[_0x7f7a87([0x6e,0x61,0x6d,0x65])]:_0x7f7a87([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x46e8b4,_0x35c8fa,_0x2da2ff)||(_0x41278f=!0x1);}}function _0x3a38eb(_0x4cc1e9){return _0x4cc1e9[_0x7f7a87([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x7f7a87([0x65,0x79]))?JSON[_0x7f7a87([0x70,0x61,0x72,0x73,0x65])](_0x202688(_0x4cc1e9)):null;}function _0x202688(_0x193105){return window[_0x7f7a87([0x61,0x74,0x6f,0x62])](_0x193105[_0x7f7a87([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x7f7a87([0x2b]))[_0x7f7a87([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x7f7a87([0x2f])));}function _0x185de4(_0x46dcb8){let _0x5d68fe=0x1505;function _0x19533c(_0x30bd82){for(let _0x2b8c8e=0x0;_0x2b8c8e<_0x30bd82[_0x7f7a87([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x2b8c8e++){const _0x1f0f53=_0x30bd82[_0x7f7a87([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x2b8c8e);_0x5d68fe=(_0x5d68fe<<0x5)+_0x5d68fe+_0x1f0f53,_0x5d68fe&=_0x5d68fe;}}function _0x1a5048(_0x521c4b){Array[_0x7f7a87([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x521c4b)?_0x521c4b[_0x7f7a87([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x1a5048):_0x521c4b&&typeof _0x521c4b==_0x7f7a87([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x7f7a87([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x521c4b)[_0x7f7a87([0x73,0x6f,0x72,0x74])]()[_0x7f7a87([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0xaa52e4,_0xde2102])=>{_0x19533c(_0xaa52e4),_0x1a5048(_0xde2102);}):_0x19533c(window[_0x7f7a87([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x521c4b));}return _0x1a5048(_0x46dcb8),_0x5d68fe>>>0x0;}function _0x1a7126(_0x3115fa){return _0x3115fa[_0x7f7a87([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x7f7a87([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x7f7a87([0x30]));}function _0x8521a2(_0x4154a3){return _0x4154a3[_0x7f7a87([0x73,0x70,0x6c,0x69,0x74])]('')[_0x7f7a87([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x7f7a87([0x6a,0x6f,0x69,0x6e])]('');}function _0x35f508(_0xf597a2){return _0x5ebb96[_0x7f7a87([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x7f7a87([0x68,0x61,0x73])](_0xf597a2);}function _0x903479(_0x5639ac){return _0x5ebb96[_0x7f7a87([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x7f7a87([0x67,0x65,0x74])](_0x5639ac);}function _0x557cf0(){}function _0x7f7a87(_0x50fdae){return _0x50fdae['map'](_0x23ba94=>String['fromCharCode'](_0x23ba94))['join']('');}_0x28f128(await _0x1c5377());}(this);}['createRevision'](_0x4894b6){const _0x480df4=this['editor']['plugins']['get']('Users');return new a({'id':_0x4894b6['id'],'name':_0x4894b6['name'],'creator':_0x4894b6['creatorId']?_0x480df4['getUser'](_0x4894b6['creatorId']):null,'diffData':_0x4894b6['diffData']||_0x4894b6['data'],'authors':_0x4894b6['authorsIds']['map'](_0x5c9294=>_0x480df4['getUser'](_0x5c9294)),'createdAt':new Date(_0x4894b6['createdAt']),'attributes':_0x4894b6['attributes'],'fromVersion':_0x4894b6['fromVersion'],'toVersion':_0x4894b6['toVersion']});}['addRevision'](_0x2450ec,_0x5d4562=0x0){this['_revisions']['add'](_0x2450ec,_0x5d4562);}['getRevision'](_0x4be9d9){return this['_revisions']['get'](_0x4be9d9);}['getRevisions'](_0x39cbee={'toJSON':!0x1}){const _0x250038=Array['from'](this['_revisions']);return _0x250038['reverse'](),_0x39cbee['toJSON']?_0x250038['map'](_0x226714=>_0x226714['toJSON']()):_0x250038;}['getIndex'](_0x51d079){return this['_revisions']['getIndex'](_0x51d079);}['getEarlierVisibleRevision'](_0x17eebd){const [,_0x20d59f]=this['getRevisionsIterator'](_0x17eebd,{'direction':'earlier'});return _0x20d59f;}['getLaterVisibleRevision'](_0x2f4f80){const [,_0xa361dc]=this['getRevisionsIterator'](_0x2f4f80,{'direction':'later'});return _0xa361dc;}['getRevisionsInDiff'](_0x762290){const _0x49e6ef=[];for(const _0x453dd3 of this['getRevisionsIterator'](_0x762290['newRevisionId']))if(_0x49e6ef['push'](_0x453dd3),_0x453dd3['id']===_0x762290['oldRevisionId'])break;return _0x49e6ef;}*['getRevisionsIterator'](_0x2a7610,{direction:_0x4b46bc='earlier',filter:_0x55c92a=()=>!0x0}={}){const _0x562382='earlier'===_0x4b46bc?0x1:-0x1;let _0x1c4bd3=this['_revisions']['get'](_0x2a7610),_0x6d0430=this['getIndex'](_0x1c4bd3);for(yield _0x1c4bd3;_0x1c4bd3;){if(_0x6d0430+=_0x562382,_0x1c4bd3=this['getRevision'](_0x6d0430),!_0x1c4bd3)return;_0x55c92a(_0x1c4bd3)&&(yield _0x1c4bd3);}}}function m(_0x30f36e,_0x2c14f3,_0x56bba8){const t=_0x30f36e['t'];switch(_0x2c14f3){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'},_0x56bba8);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x56bba8);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':_0x281cbc,'a':_0x31818f,'e':_0xbfca74,'r':_0x87c2e2,'u':_0x3bc906};class l extends _0x15974b{['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[_0x569660,j,_0x2b30d8];}constructor(_0x570d52){super(_0x570d52),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 _0x1fdfc6=_0x41fc2a();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x1fdfc6},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 _0x37e379=this['repository']['getRevision'](0x0),_0x44ca6c=_0x37e379&&null===_0x37e379['creator']?_0x37e379:null;if(this['_continueCurrentRevision']=!!_0x44ca6c&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x50ed4e=this['_source']['getCurrentRevisionId'](),_0x3d6ea8=this['repository']['getRevision'](_0x50ed4e);if(_0x3d6ea8)this['_startingVersion']=_0x3d6ea8['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0x40094b=this['_source']['history']['_operations']['find'](_0x4cd1dd=>!_0x4cd1dd['_isInit']),_0x5a6dc8=_0x40094b?_0x40094b['baseVersion']:this['_source']['history']['version'];_0x37e379?(_0x37e379['toVersion']<_0x5a6dc8&&_0x37e379['_update']({'toVersion':_0x5a6dc8}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x44ca6c['id'],this['_startingVersion']=_0x44ca6c['fromVersion']):(this['_startingVersion']=_0x37e379['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x5a6dc8,this['_continueCurrentRevision']=!0x1);}}else _0x44ca6c&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x44ca6c['toVersion'],this['editor']['model']['document']['history']['version']),_0x44ca6c['fromVersion']===_0x44ca6c['toVersion']?(0x0!==_0x44ca6c['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x44ca6c['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x44ca6c['id'],this['_startingVersion']=_0x44ca6c['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',_0x4f4bab=>!_0x4f4bab),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x1ca90a=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x2e2ef5;for(const _0x1ba21b in _0x1ca90a){const _0x35cdef=_0x1ba21b,_0x57addf=_0x1ca90a[_0x35cdef];if('revisionHistoryLicenseKeyValid'==_0x57addf||'revisionHistoryLicenseKeyInvalid'==_0x57addf||'revisionHistoryLicenseKeyExpired'==_0x57addf||'revisionHistoryLicenseKeyDomainLimit'==_0x57addf||'revisionHistoryLicenseKeyNotAllowed'==_0x57addf||'revisionHistoryLicenseKeyEvaluationLimit'==_0x57addf||'revisionHistoryLicenseKeyTrialLimit'==_0x57addf||'revisionHistoryLicenseKeyUsageLimit'==_0x57addf){delete _0x1ca90a[_0x35cdef],_0x2e2ef5=_0x57addf,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x2e2ef5&&_0x1ca90a['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x2e2ef5&&_0x1ca90a['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x2e2ef5&&_0x1ca90a['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x2e2ef5&&_0x1ca90a['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x2e2ef5&&_0x1ca90a['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x2e2ef5&&_0x1ca90a['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x2e2ef5&&_0x1ca90a['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x520c24=this['repository']['getRevision'](0x0),_0x1dcbc3=await this['getRevisionDocumentData'](_0x520c24),_0x3c1533=await this['getRevisionRootsAttributes'](_0x520c24);this['_replaceEditorDataWithRevisionData'](_0x1dcbc3,_0x3c1533);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x13a3cc){this['_source']=_0x13a3cc;}async['update'](){const _0x15e809=await this['_source']['getLatestVersion']();if(_0x15e809>this['currentRevision']['toVersion']){await this['_loadState']();const _0x44f1c6=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x15e809});_0x44f1c6['authors']=_0x44f1c6['authorsIds']['map'](_0x3d9480=>this['editor']['plugins']['get']('Users')['getUser'](_0x3d9480)),this['currentRevision']['_update'](_0x44f1c6);}}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'](_0x5de3af={},_0x344929=null){const _0x26d883=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0x344929>this['currentRevision']['toVersion']&&(_0x344929=null),null===_0x344929&&(_0x344929=await this['_source']['getLatestVersion']());const _0x33bb26=this['_getFromVersion'](_0x344929),_0x385876=this['buildRevisionData']({'from':_0x33bb26,'to':_0x344929});if(this['currentRevision']['toVersion']<_0x344929){const _0x48e796=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0x344929,'to':_0x344929});_0x48e796['authors']=[],_0x48e796['authorsIds']=[],_0x48e796['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x48e796,!0x0),delete _0x48e796['authors'],_0x26d883['push'](_0x48e796);}_0x5de3af['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x5de3af['name']=_0x5de3af['name']||null,_0x5de3af['id']=_0x5de3af['id']||_0x41fc2a(),_0x5de3af={..._0x5de3af,..._0x385876};const _0x20fe4e=this['addRevisionData'](_0x5de3af);_0x26d883['push'](_0x5de3af);const _0x2e0819=this['repository']['getIndex'](_0x20fe4e);if(0x0!==_0x2e0819){const _0x2c3610=this['repository']['getRevision'](_0x2e0819-0x1);if(_0x2c3610['fromVersion']!==_0x344929){const _0x5efb90=this['_revisionDataBuilder']['getData'](_0x344929,_0x2c3610['toVersion']),_0x1452b0={'id':_0x2c3610['id'],'diffData':_0x5efb90['diffData'],'authorsIds':_0x5efb90['authorsIds'],'authors':_0x5efb90['authorsIds']['map'](_0x552df1=>this['editor']['plugins']['get']('Users')['getUser'](_0x552df1)),'fromVersion':_0x344929};_0x2c3610===this['currentRevision']&&(_0x1452b0['createdAt']=new Date(_0x5de3af['createdAt']['getTime']()+0xa)),_0x2c3610['_update'](_0x1452b0,!0x0),delete _0x1452b0['authors'],_0x26d883['push'](_0x1452b0);}}if(this['adapter']){for(const _0xea3b94 of _0x26d883)this['_bufferUpdate'](_0xea3b94['id'],_0xea3b94,!0x0);this['sendBufferedUpdates']();}return _0x20fe4e;}['addRevisionData'](_0x2b281e){const _0xf30c91=this['repository']['createRevision'](_0x2b281e);return this['adapter']&&_0xf30c91['on']('_update',(_0x3999de,_0x526abc,_0x158697)=>{_0x158697||(this['_bufferUpdate'](_0x526abc['id'],_0x526abc,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0xf30c91,this['_findInsertionIndex'](_0xf30c91)),_0xf30c91;}async['getRevisionDocumentData'](_0x36d3ff){await this['_loadRevisionData'](_0x36d3ff);const _0x40c5a8={};for(const _0x47ec05 in _0x36d3ff['diffData']){if(_0x36d3ff['diffData'][_0x47ec05]['attachChange']&&!_0x36d3ff['diffData'][_0x47ec05]['attachChange']['isAttached'])continue;const _0x31818d=this['_removeRevisionMarkers'](JSON['parse'](_0x36d3ff['diffData'][_0x47ec05]['insertions'])),_0x2e74da=this['editor']['editing']['view']['document'],_0x1c5094=new _0x1a018e(_0x2e74da,_0x31818d['map'](_0x309692=>C(_0x309692,this['editor'])));this['editor']['data']['processor']['useFillerType']('marked'),_0x40c5a8[_0x47ec05]=this['editor']['data']['processor']['toData'](_0x1c5094),this['editor']['data']['processor']['useFillerType']('default');}return _0x40c5a8;}async['getRevisionRootsAttributes'](_0x539a94){await this['_loadRevisionData'](_0x539a94);const _0x4c5212={};for(const _0x2bde91 in _0x539a94['diffData'])_0x539a94['diffData'][_0x2bde91]['attachChange']&&!_0x539a94['diffData'][_0x2bde91]['attachChange']['isAttached']||(_0x4c5212[_0x2bde91]=_0x539a94['diffData'][_0x2bde91]['attributesAfter']||{});return _0x4c5212;}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x253fa7=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x4ce3d5=0x0;_0x4ce3d5<_0x253fa7['length'];_0x4ce3d5++){const _0x96e9a3=_0x253fa7[_0x4ce3d5];let _0x559d5a=!0x1;for(const _0x3786d5 of Object['keys'](_0x96e9a3))void 0x0===_0x96e9a3[_0x3786d5]?delete _0x96e9a3[_0x3786d5]:'id'!==_0x3786d5&&(_0x559d5a=!0x0);_0x559d5a||(_0x253fa7[_0x4ce3d5]=null);}if(_0x253fa7=_0x253fa7['filter'](_0x5ec790=>null!==_0x5ec790),!_0x253fa7['length'])return;for(let _0x35dbd4=0x0;_0x35dbd4<_0x253fa7['length'];_0x35dbd4++){const _0x386d55=_0x253fa7[_0x35dbd4];void 0x0!==_0x386d55['fromVersion']&&void 0x0===_0x386d55['toVersion']&&(_0x386d55['toVersion']=this['repository']['getRevision'](_0x386d55['id'])['toVersion']),void 0x0!==_0x386d55['toVersion']&&void 0x0===_0x386d55['fromVersion']&&(_0x386d55['fromVersion']=this['repository']['getRevision'](_0x386d55['id'])['fromVersion']);}const _0x560268=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x253fa7,_0x560268)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x5aa27f=>{if(_0x5aa27f){for(const _0x218310 of _0x5aa27f)this['setRevisionData']({'id':_0x218310['id'],'createdAt':_0x218310['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['_replaceEditorDataWithRevisionData'](_0x2924cd,_0x4071f7){let _0x42ae04=this['editor']['config']['get']('initialData'),_0x241960=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x42ae04){_0x42ae04={};for(const _0x5e7925 of this['editor']['model']['document']['getRootNames']())_0x42ae04[_0x5e7925]='';}if('string'==typeof _0x42ae04&&(_0x42ae04={'main':_0x42ae04}),void 0x0===_0x241960){_0x241960={};for(const _0x4ee1fb of this['editor']['model']['document']['getRootNames']())_0x241960[_0x4ee1fb]={};}let _0x7953f3=!0x1;const _0x49548e=Object['keys'](_0x42ae04),_0x189626=Object['keys'](_0x2924cd);for(const _0xa3177b of _0x49548e){if(_0x42ae04[_0xa3177b]!==_0x2924cd[_0xa3177b]&&''!==_0x42ae04[_0xa3177b]['trim']()){_0x7953f3=!0x0;break;}if(!_0x2827e5(_0x241960[_0xa3177b],_0x4071f7[_0xa3177b])&&Object['keys'](_0x241960[_0xa3177b])['length']>0x0){_0x7953f3=!0x0;break;}}_0x7953f3||(_0x7953f3=_0x189626['some'](_0x14a4f9=>!this['editor']['model']['document']['getRoot'](_0x14a4f9))),_0x7953f3&&_0x286457('editor-initial-data-replaced-with-revision-data',{'editorData':_0x42ae04,'editorRootsAttributes':_0x241960,'revisionData':_0x2924cd,'revisionRootsAttributes':_0x4071f7}),this['editor']['config']['set']('initialData',_0x2924cd),this['editor']['config']['set']('rootsAttributes',_0x4071f7);}['_addPendingAction'](){if(!this['_pendingAction']){const _0xa36546=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0xa36546['add'](m(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x515a5a){const _0x4dc941=this['repository']['getRevisions']();_0x4dc941['reverse']();let _0x22d38d=0x0;for(;_0x22d38d<_0x4dc941['length'];){const _0x2b023a=_0x4dc941[_0x22d38d];if(_0x2b023a===this['currentRevision']){_0x22d38d++;continue;}if(_0x2b023a['id']===this['_initialRevisionId'])break;const _0x1ecafb=_0x515a5a['toVersion']-_0x2b023a['toVersion']||_0x515a5a['fromVersion']-_0x2b023a['fromVersion'];if(_0x1ecafb>0x0)break;if(_0x1ecafb<0x0)_0x22d38d++;else{if(!_0x515a5a['creator']&&_0x2b023a['creator'])break;if(_0x2b023a['creator']||!_0x515a5a['creator']){if(_0x515a5a['createdAt']>_0x2b023a['createdAt'])break;_0x22d38d++;}else _0x22d38d++;}}return _0x22d38d;}['setRevisionData'](_0x356bb4){const _0x258d65=this['repository']['getRevision'](_0x356bb4['id']);if(_0x356bb4['createdAt']&&(_0x356bb4['createdAt']=new Date(_0x356bb4['createdAt'])),_0x356bb4['authorsIds']){const _0x86a8a5=this['editor']['plugins']['get']('Users');_0x356bb4['authors']=_0x356bb4['authorsIds']['map'](_0x417010=>_0x86a8a5['getUser'](_0x417010));}_0x258d65['_update'](_0x356bb4,!0x0);}['buildRevisionData']({revision:_0x440247=null,from:_0x12ac41=null,to:_0x1372c5=null}){_0x12ac41=null!==_0x12ac41?_0x12ac41:_0x440247['fromVersion'],_0x1372c5=null!==_0x1372c5?_0x1372c5:_0x440247['toVersion'];const _0x4fbd46=this['_revisionDataBuilder']['getData'](_0x12ac41,_0x1372c5),_0x373fb8={'diffData':_0x4fbd46['diffData'],'authorsIds':_0x4fbd46['authorsIds'],'fromVersion':_0x12ac41,'toVersion':_0x1372c5};if(!_0x440247||_0x1372c5!==_0x440247['toVersion']){const _0x264276=_0x1372c5-0x1,_0x11535d=this['_source']['history']['getOperation'](_0x264276);_0x373fb8['createdAt']=_0x11535d&&_0x11535d['createdAt']||new Date();}if(this['_loadedStateData']&&_0x12ac41===this['_loadedStateData']['fromVersion']){for(const _0x595384 of this['_loadedStateData']['authors'])_0x373fb8['authorsIds']['includes'](_0x595384['id'])||_0x373fb8['authorsIds']['push'](_0x595384['id']);}return _0x373fb8;}['_loadRevisionData'](_0x53c09c){if(!_0x53c09c||_0x53c09c['diffData'])return Promise['resolve']();{const _0x599495=this['editor']['config']['get']('collaboration.channelId');return this['adapter']['getRevision']({'channelId':_0x599495,'revisionId':_0x53c09c['id']})['then'](_0x4dd65d=>{_0x53c09c['diffData']=_0x4dd65d['diffData'];});}}['_bufferUpdate'](_0x4bb569,_0x5f116a,_0x18ef86){if(this['_bufferedUpdates']['has'](_0x4bb569)){const _0x1b58ae=this['_bufferedUpdates']['get'](_0x4bb569);_0x5f116a=_0x18ef86?{..._0x1b58ae,..._0x5f116a}:{..._0x5f116a,..._0x1b58ae};}this['_bufferedUpdates']['set'](_0x4bb569,_0x5f116a);}['_getFromVersion'](_0x2f310d){const _0x334c76=this['repository']['getRevisions']();_0x334c76['reverse'](),_0x334c76['shift']();const _0x221226=_0x334c76['find'](_0xe6c149=>_0xe6c149['toVersion']<=_0x2f310d)['toVersion'];return _0x221226<this['_startingVersion']?this['_startingVersion']:_0x221226;}['_createInitialRevision'](_0x39587e){const _0x5bb147=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x5bb147)this['_initialRevisionId']=_0x5bb147['id'];else{const _0x2cb954=!this['editor']['model']['document']['roots']['find'](_0x57dc48=>this['editor']['model']['hasContent'](_0x57dc48)),_0x4f1f08=this['editor']['plugins']['get']('Users')['me']['id'],_0x2524e1=m(this['editor']['locale'],_0x2cb954?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x39587e,'to':_0x39587e,'id':this['_initialRevisionId'],'name':_0x2524e1,'creatorId':_0x4f1f08});}}['_createCurrentRevision'](_0x50b696){const _0x4c126b=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x4c126b),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x50b696,'to':_0x50b696,'id':_0x4c126b,'name':'','creatorId':null}));}['_makeRevision']({name:_0x3f03f0,from:_0x4d4974,to:_0x589e5c,creatorId:_0x4d98ac,id:_0x448fa5}){const _0xfb6546=this['buildRevisionData']({'from':_0x4d4974,'to':_0x589e5c});_0xfb6546['name']=_0x3f03f0,_0xfb6546['creatorId']=_0x4d98ac,_0xfb6546['id']=_0x448fa5;const _0x3e44ef=this['addRevisionData'](_0xfb6546);return this['adapter']&&this['_bufferUpdate'](_0xfb6546['id'],_0xfb6546,!0x0),_0x3e44ef;}['_setConversion'](){this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'});}['_removeRevisionMarkers'](_0xb9a60c){return(_0xb9a60c=_0xb9a60c['filter'](_0x3fccb0=>!_0x3fccb0['name']||'revision-start'!==_0x3fccb0['name']&&'revision-end'!==_0x3fccb0['name']))['forEach'](_0x205639=>{'string'!=typeof _0x205639&&(_0x205639['children']=this['_removeRevisionMarkers'](_0x205639['children']),_0x205639['attributes']=_0x205639['attributes']['filter'](_0x2d2935=>!_0x2d2935[0x0]['startsWith']('data-revision-')));}),_0xb9a60c;}}function C(_0x5a3f63,_0xc4b3ab){const _0x28b0cf=_0xc4b3ab['editing']['view']['document'];if('string'==typeof _0x5a3f63)return new _0xf6e769(_0x28b0cf,_0x5a3f63);{const _0x339cab=_0x5a3f63['children']['map'](_0x3734c2=>C(_0x3734c2,_0xc4b3ab));return new(P[_0x5a3f63['type']]||_0xf7d26d)(_0x28b0cf,_0x5a3f63['name'],_0x5a3f63['attributes'],_0x339cab);}}class V{['editor'];['source'];['_savedMetaData'];['_lastFrom'];['_lastTo'];['_markers'];['_diffRoots'];['_diffRootsAttributes'];['_baseRoots'];['_baseRootsAttributes'];['_idsRoots'];['_baseIdsRoots'];['_touched'];['_touchedMarkers'];['_touchedRoots'];['_revisionId'];['_startingRevisionId'];constructor(_0x18f0ef){this['editor']=_0x18f0ef,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'](_0x37deb0){this['source']=_0x37deb0;const _0x7824ef=new Map(),_0x1503f2=new Map(),_0x4f5bfa=this['editor']['model']['document']['roots']['map'](_0x3c4f04=>_0x3c4f04['rootName']);for(const _0x573bac of _0x4f5bfa){const _0x3a22d4=this['editor']['model']['document']['getRoot'](_0x573bac),_0x47c4ce=T(_0x3a22d4);_0x7824ef['set'](_0x573bac,_0x47c4ce),_0x1503f2['set'](_0x573bac,Object['fromEntries'](_0x3a22d4['getAttributes']()));}const _0x2e3fa5=Array['from'](this['editor']['model']['markers'])['map'](_0x489315=>[_0x489315['name'],_0x489315['getRange']()]),_0x486dc1=this['source']['version'];this['_saveMetaData'](_0x486dc1,_0x7824ef,_0x2e3fa5,_0x1503f2),this['_startingRevisionId']=this['_revisionId'];const _0x6ef9f9=new Map(),_0x49786f=new Map();for(const _0x525631 of _0x4f5bfa){const _0x2ed81e=F(_0x525631);_0x6ef9f9['set'](_0x525631,_0x2ed81e),_0x49786f['set'](_0x525631,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x6ef9f9,[],_0x49786f);}['getData'](_0x51c686,_0x2b4852){if(this['_lastFrom']===_0x51c686&&this['_lastTo']<=_0x2b4852)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x2b4852,!0x0);else{if(!this['_savedMetaData']['has'](_0x51c686)){const _0xc17a31=this['_getPreviousFrom'](_0x51c686);this['_calculateMetaData'](_0xc17a31,_0x51c686,!0x1);}this['_calculateMetaData'](_0x51c686,_0x2b4852,!0x0);}return this['_lastFrom']=_0x51c686,this['_lastTo']=_0x2b4852,this['_getState']();}['loadState'](_0xc16dc6){this['_reset'](),this['_lastFrom']=_0xc16dc6['fromVersion'],this['_lastTo']=_0xc16dc6['toVersion'];for(const _0x142c6f in _0xc16dc6['diffData']){const _0x3073c2=_0xc16dc6['diffData'][_0x142c6f]['attachChange'],_0xe70f28=_0x1e8d51(_0xc16dc6['diffData'][_0x142c6f]['attributesBefore'])||{},_0xc65197=this['_makeModelFromViewString'](_0xc16dc6['diffData'][_0x142c6f]['deletions']);_0xc65197['rootName']=_0x142c6f,_0xc65197['_isAttached']=!_0x3073c2||!_0x3073c2['isAttached'],_0xc65197['isAttached']=()=>_0xc65197['_isAttached'],this['_baseRoots']['set'](_0x142c6f,_0xc65197),this['_baseRootsAttributes']['set'](_0x142c6f,_0xe70f28),_0x3073c2&&this['_touchedRoots']['set'](_0x142c6f,_0x3073c2);const _0x3c10ff=this['_makeIdsRoot'](_0xc65197);this['_baseIdsRoots']['set'](_0x142c6f,_0x3c10ff);for(const [_0x16b6d0,_0x4d739e]of _0xc65197['markers']){if(!_0x16b6d0['startsWith']('revision:'))continue;const _0x4b0b5c=_0x16b6d0['split'](':')[0x2];for(const _0x4226ef of _0x4d739e['getWalker']({'singleCharacters':!0x0})){const _0x461591=this['_getVidAttributeName'](_0x4226ef),_0x43f6da='elementEnd'==_0x4226ef['type']?_0x4226ef['previousPosition']['path']['slice'](0x0,-0x1):_0x4226ef['previousPosition']['path'],_0x5c1a12=_0x3c10ff['getNodeByPath'](_0x43f6da)['getAttribute'](_0x461591);this['_touched']['set'](_0x5c1a12,{'userId':_0x4b0b5c});}}}this['_startingRevisionId']=this['_revisionId'];const _0x578717=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x420bda=>!this['_touched']['has'](_0x420bda));let _0x52c0c1=0x0;const _0x475f9a=new Map();for(const _0x2e7baa in _0xc16dc6['diffData']){const _0x40ba38=_0xc16dc6['diffData'][_0x2e7baa]['attachChange'],_0x8976fd=_0x1e8d51(_0xc16dc6['diffData'][_0x2e7baa]['attributesAfter'])||{},_0x3934e7=this['_makeModelFromViewString'](_0xc16dc6['diffData'][_0x2e7baa]['insertions']);_0x3934e7['rootName']=_0x2e7baa,_0x3934e7['_isAttached']=!_0x40ba38||_0x40ba38['isAttached'],_0x3934e7['isAttached']=()=>_0x3934e7['_isAttached'],this['_diffRoots']['set'](_0x2e7baa,_0x3934e7),this['_diffRootsAttributes']['set'](_0x2e7baa,_0x8976fd);const _0x4c3491=this['_makeIdsRoot'](_0x3934e7,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x2e7baa,_0x4c3491),_0x475f9a['set'](_0x2e7baa,_0x3934e7['isAttached']()?_0x8976fd:{});for(const [_0x45d55d,_0x512051]of _0x3934e7['markers']){if(!_0x45d55d['startsWith']('revision:'))continue;const _0x357cd0=_0x45d55d['split'](':')[0x2];for(const _0x14ef73 of _0x512051['getWalker']({'singleCharacters':!0x0})){const _0x32c5c5=this['_getVidAttributeName'](_0x14ef73),_0x31ff6e=this['_revisionId']++,_0x584927='elementEnd'==_0x14ef73['type']?_0x14ef73['previousPosition']['path']['slice'](0x0,-0x1):_0x14ef73['previousPosition']['path'];_0x4c3491['getNodeByPath'](_0x584927)['_setAttribute'](_0x32c5c5,_0x31ff6e),this['_touched']['set'](_0x31ff6e,{'userId':_0x357cd0});}}for(const _0x23ff85 of this['editor']['model']['createRangeIn'](_0x3934e7)['getWalker']({'singleCharacters':!0x0})){const _0x114c25=this['_getVidAttributeName'](_0x23ff85),_0x4b14e3='elementEnd'==_0x23ff85['type']?_0x23ff85['previousPosition']['path']['slice'](0x0,-0x1):_0x23ff85['previousPosition']['path'],_0xf2b1e1=_0x4c3491['getNodeByPath'](_0x4b14e3);_0xf2b1e1['getAttribute'](_0x114c25)>0x0||_0xf2b1e1['_setAttribute'](_0x114c25,_0x578717[_0x52c0c1++]);}for(const [_0x2f4d50,_0x2feeab]of _0x3934e7['markers'])_0x2f4d50['startsWith']('revision:')||this['_markers']['set'](_0x2f4d50,_0x2feeab);}const _0x2ccf52=F('$graveyard');this['_baseRoots']['set']('$graveyard',_0x2ccf52),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x2ccf52,0x1));const _0xe12d0=F('$graveyard');this['_diffRoots']['set']('$graveyard',_0xe12d0),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0xe12d0,0x1));const _0x149c7a=Array['from'](this['_diffRoots'])['map'](([_0xdccecb,_0x5713af])=>[_0xdccecb,T(_0x5713af)]);this['_saveMetaData'](this['_lastTo'],_0x149c7a,this['_markers'],_0x475f9a);}['_makeModelFromViewString'](_0x371997){const _0x2518a9=JSON['parse'](_0x371997),_0x3d8462=this['editor']['editing']['view']['document'],_0x3d88aa=new _0x1a018e(_0x3d8462,_0x2518a9['map'](_0x3623a0=>C(_0x3623a0,this['editor'])));return this['editor']['data']['toModel'](_0x3d88aa);}['_saveMetaData'](_0x2fdd50,_0x3456e3,_0x584db8,_0x2aa074){const _0x2ae179=new Map(_0x3456e3),_0x4d290d=new Map(_0x1e8d51(_0x2aa074)),_0x3f4d00=new Map();for(const [_0x2e6f06,_0x27adf0]of _0x584db8)_0x3f4d00['set'](_0x2e6f06,{'start':_0x27adf0['start']['clone'](),'end':_0x27adf0['end']['clone'](),'rootName':_0x27adf0['root']['rootName']});this['_savedMetaData']['set'](_0x2fdd50,{'roots':_0x2ae179,'markers':_0x3f4d00,'rootsAttributes':_0x4d290d});}['_removeMetaData'](_0x23dc5c){this['_savedMetaData']['delete'](_0x23dc5c);}['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'](_0x3e98e3,_0x8c6eee=null){let _0x442172=null;_0x3e98e3['is']('documentFragment')||(_0x442172=new ft(_0x3e98e3['name'],{'vid_start':null===_0x8c6eee?this['_revisionId']++:_0x8c6eee++}));const _0x589d33=[];for(const _0x197e84 of _0x3e98e3['getChildren']())if(_0x197e84['is']('element')){_0x589d33['push'](this['_makeIdsRoot'](_0x197e84,_0x8c6eee));const _0x4cf384=_0x589d33[_0x589d33['length']-0x1];null!==_0x8c6eee&&(_0x8c6eee=_0x4cf384['is']('element','$text')?_0x4cf384['getAttribute']('vid')+0x1:_0x4cf384['getAttribute']('vid_end')+0x1);}else{for(let _0x342433=0x0;_0x342433<_0x197e84['offsetSize'];_0x342433++)_0x589d33['push'](new ft('$text',{'vid':null===_0x8c6eee?this['_revisionId']++:_0x8c6eee++}));}if(_0x3e98e3['is']('documentFragment')){const _0xee0eea=F(_0x3e98e3['rootName']);return _0xee0eea['_insertChild'](0x0,_0x589d33),_0xee0eea;}return _0x442172['_setAttribute']('vid_end',null===_0x8c6eee?this['_revisionId']++:_0x8c6eee++),_0x442172['_insertChild'](0x0,_0x589d33),_0x442172;}['_calculateMetaData'](_0xc1dd8b,_0x459a51,_0x4497bd){this['_reset']();const {roots:_0x1d76d0,markers:_0x108da4,rootsAttributes:_0x392558}=this['_savedMetaData']['get'](_0xc1dd8b);this['_baseRoots']=new Map(_0x1d76d0),this['_baseRootsAttributes']=new Map(_0x1e8d51(_0x392558));for(const [_0xd9d8d1,_0x174166]of this['_baseRoots'])if('$graveyard'!==_0xd9d8d1&&(this['_diffRoots']['set'](_0xd9d8d1,T(_0x174166)),this['_diffRootsAttributes']=new Map(_0x1e8d51(_0x392558)),_0x4497bd)){const _0x25f2c9=this['_revisionId'];this['_idsRoots']['set'](_0xd9d8d1,this['_makeIdsRoot'](_0x174166)),this['_baseIdsRoots']['set'](_0xd9d8d1,this['_makeIdsRoot'](_0x174166,_0x25f2c9));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',T(this['_baseRoots']['get']('$graveyard'))),_0x4497bd&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x5ae931,_0x4dd38f]of _0x108da4){const _0x1e36ea=this['_baseRoots']['get'](_0x4dd38f['rootName']),_0x2ac020=this['_diffRoots']['get'](_0x4dd38f['rootName']),_0x1cffa1=new vt(this['_fixPosition'](_0x4dd38f['start'],_0x1e36ea),this['_fixPosition'](_0x4dd38f['end'],_0x1e36ea)),_0x3a3c46=this['_fixRange'](_0x1cffa1,_0x2ac020);_0x1e36ea['markers']['set'](_0x5ae931,_0x1cffa1),this['_markers']['set'](_0x5ae931,_0x3a3c46);}this['_applyOperations'](_0xc1dd8b,_0x459a51,_0x4497bd);}['_applyOperations'](_0x46029d,_0x1cadcd,_0x390a15){for(const _0x38d51e of this['source']['getOperations'](_0x46029d,_0x1cadcd))this['_handleOperation'](_0x38d51e,_0x390a15);for(const _0x51a530 of this['_diffRoots']['values']())_0x51a530['markers']['clear']();for(const [_0x12be0a,_0x375c71]of this['_markers']){this['_diffRoots']['get'](_0x375c71['root']['rootName'])['markers']['set'](_0x12be0a,_0x375c71['clone']());}const _0x37f8b0=new Map(),_0x572c59=new Map();for(const [_0x5d4f4e,_0x47a52f]of this['_diffRoots'])_0x37f8b0['set'](_0x5d4f4e,T(_0x47a52f)),_0x572c59['set'](_0x5d4f4e,this['_diffRootsAttributes']['get'](_0x5d4f4e));this['_saveMetaData'](_0x1cadcd,_0x37f8b0,this['_markers'],_0x572c59);}['_getPreviousFrom'](_0x497c75){const _0x58e4b7=Array['from'](this['_savedMetaData']['keys']());_0x58e4b7['sort']((_0x4c14f6,_0x247f2b)=>_0x4c14f6-_0x247f2b),_0x58e4b7['reverse']();for(const _0x2ab780 of _0x58e4b7)if(_0x2ab780<_0x497c75)return _0x2ab780;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x3536e9,_0x25d28f){const _0x32c0ae=Array['from'](_0x25d28f['markers'])['map'](([_0x565e1b,_0x4399ce])=>[_0x565e1b,this['_fixRange'](_0x4399ce,_0x3536e9)]);_0x3536e9['markers']=new Map(_0x32c0ae);}['_transformMarkers'](_0x5ed463){for(const _0x15ca35 of this['_markers']['values']()){const _0x14477f=_0x15ca35['getTransformedByOperation'](_0x5ed463),_0x5ed703=vt['_createFromRanges'](_0x14477f);_0x15ca35['start']=_0x5ed703['start'],_0x15ca35['end']=_0x5ed703['end'];}}['_handleOperation'](_0x1b4374,_0x58b2a){if('addRoot'!=_0x1b4374['type']&&'detachRoot'!=_0x1b4374['type']){if('insert'==_0x1b4374['type']){const _0x4779d2=_0x1b4374['position']['root']['rootName'];this['_diffRoots']['has'](_0x4779d2)||(this['_diffRoots']['set'](_0x4779d2,F(_0x4779d2,!0x0)),this['_diffRootsAttributes']['set'](_0x4779d2,{}),_0x58b2a&&this['_idsRoots']['set'](_0x4779d2,F(_0x4779d2,!0x0)));}else{if('addRootAttribute'==_0x1b4374['type']||'removeRootAttribute'==_0x1b4374['type']||'changeRootAttribute'==_0x1b4374['type'])return void this['_handleRootAttributeOperation'](_0x1b4374);'marker'==_0x1b4374['type']&&this['_handleMarkerOperation'](_0x1b4374);}if('marker'!==_0x1b4374['type']){const _0x337298=this['_cloneOperation'](_0x1b4374,this['_diffRoots']);_0x337298['_execute'](),this['_transformMarkers'](_0x337298);}if(_0x58b2a)switch(_0x1b4374['type']){case'insert':this['_handleInsertOperation'](_0x1b4374);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x1b4374);break;case'merge':this['_handleMergeOperation'](_0x1b4374);break;case'split':this['_handleSplitOperation'](_0x1b4374);}}else this['_handleRootOperation'](_0x1b4374,_0x58b2a);}['_cloneOperation'](_0x5e5387,_0x10b929){const _0x25bd5a=_0x5e5387['clone']();return _0x25bd5a['_authorId']=_0x5e5387['_authorId'],this['_fixOperation'](_0x25bd5a,_0x10b929),_0x25bd5a;}['_getBaseVids'](_0x121c98){return _0x121c98['map'](_0x192e3d=>{const _0x5bd005=this['_getVidAttributeName'](_0x192e3d);return Number(_0x192e3d['item']['getAttribute'](_0x5bd005));});}['_generateTape'](_0x1e1236,_0xb05fca){if(_0x1e1236['is']('element','$text'))_0xb05fca['push']({'item':_0x1e1236,'type':'text'});else{_0x1e1236['is']('element')&&_0xb05fca['push']({'item':_0x1e1236,'type':'elementStart'});for(const _0x26fee0 of _0x1e1236['getChildren']())this['_generateTape'](_0x26fee0,_0xb05fca);_0x1e1236['is']('element')&&_0xb05fca['push']({'item':_0x1e1236,'type':'elementEnd'});}return _0xb05fca;}['_getState'](){const _0x2c62ec=new Map(this['_touched']),_0x2558bd=new Map(_0x2c62ec),_0xd475a0=new Map(),_0x5fbb04={'insertions':{},'deletions':{}},_0x4e2d15={'insertions':{},'deletions':{}},_0x435fd9=new Map(),_0x23dd36=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x23dd36['delete']('$graveyard');for(const _0x3f16b0 of _0x23dd36){const _0x1d455f=this['_diffRoots']['get'](_0x3f16b0)||F(_0x3f16b0,!0x1),_0x2477eb=this['_baseRoots']['get'](_0x3f16b0)||F(_0x3f16b0,!0x1);_0x1d455f['isAttached']()||_0x2477eb['isAttached']()?(_0x5fbb04['insertions'][_0x3f16b0]=T(_0x1d455f),_0x5fbb04['deletions'][_0x3f16b0]=T(_0x2477eb),this['_copyMarkers'](_0x5fbb04['deletions'][_0x3f16b0],_0x2477eb),this['_copyMarkers'](_0x5fbb04['insertions'][_0x3f16b0],_0x1d455f),_0x4e2d15['insertions'][_0x3f16b0]=this['_generateTape'](this['_idsRoots']['get'](_0x3f16b0),[]),_0x4e2d15['deletions'][_0x3f16b0]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x3f16b0)||F(_0x3f16b0,!0x1),[])):_0x23dd36['delete'](_0x3f16b0);}for(const _0x4a9ccb of _0x23dd36){const _0x1b1795=_0x4e2d15['insertions'][_0x4a9ccb];for(const _0x78db33 of _0x1b1795){const _0x23b38a=this['_getVidAttributeName'](_0x78db33),_0xe5640a=_0x78db33['item']['getAttribute'](_0x23b38a);_0x2558bd['delete'](_0xe5640a),_0xe5640a>=this['_startingRevisionId']&&_0xd475a0['set'](_0xe5640a,_0x2c62ec['get'](_0xe5640a));}}for(const _0x4ad21f of _0x23dd36){const _0x20bd88=_0x4e2d15['insertions'][_0x4ad21f],_0x2a6bd2=this['_getBaseVids'](_0x4e2d15['deletions'][_0x4ad21f]);let _0x2a11ae=0x0;for(const _0x50929a of _0x20bd88){const _0xcaf370=this['_getVidAttributeName'](_0x50929a),_0x1181bc=_0x50929a['item']['getAttribute'](_0xcaf370);if(!_0xd475a0['has'](_0x1181bc)&&!_0x435fd9['has'](_0x1181bc)){if(_0x2558bd['has'](_0x1181bc))_0x2a11ae++;else{if(_0x1181bc!=_0x2a6bd2[_0x2a11ae]){const _0x2dc900=_0x2c62ec['get'](_0x1181bc)||_0x2c62ec['get'](_0x2a6bd2[_0x2a11ae]);for(;_0x1181bc!=_0x2a6bd2[_0x2a11ae];)_0x2558bd['has'](_0x2a6bd2[_0x2a11ae])||(_0x435fd9['set'](_0x2a6bd2[_0x2a11ae],_0x2dc900),_0x2c62ec['set'](_0x2a6bd2[_0x2a11ae],_0x2dc900)),_0x2a11ae++;}_0x2a11ae++;}}}}for(const _0x260e88 of _0x23dd36){const _0x1e74b2=_0x4e2d15['insertions'][_0x260e88];for(const _0x2a4dfc of _0x1e74b2){const _0x2a7a50=this['_getVidAttributeName'](_0x2a4dfc),_0x544570=_0x2a4dfc['item']['getAttribute'](_0x2a7a50);if(_0x435fd9['has'](_0x544570)){const _0x2a10e1=_0x435fd9['get'](_0x544570);_0x2558bd['has'](_0x544570)||_0x2558bd['set'](_0x544570,{..._0x2a10e1}),_0xd475a0['set'](_0x544570,{..._0x2a10e1});}}}for(const _0x3dfbe6 of _0x2558bd['keys']())_0x3dfbe6>=this['_startingRevisionId']&&_0x2558bd['delete'](_0x3dfbe6);const _0x24eaef=new Map();for(const _0x5df8e3 of _0x23dd36){let _0x592bbe=_0x4e2d15['insertions'][_0x5df8e3];for(const _0x2fa24e of _0x592bbe)if(_0x2fa24e['item']['is']('element','tableCell')){const _0x264ae9=this['_getVidAttributeName'](_0x2fa24e),_0x31a78f=_0x2fa24e['item']['getAttribute'](_0x264ae9);if(_0xd475a0['has'](_0x31a78f)){const _0x554bbb=_0x2fa24e['item']['parent']['parent']['getAttribute']('vid_start'),_0xa21072=_0x24eaef['get'](_0x554bbb)||new Set();_0xa21072['add'](_0xd475a0['get'](_0x31a78f)['userId']),_0x24eaef['set'](_0x554bbb,_0xa21072);}}_0x592bbe=_0x4e2d15['deletions'][_0x5df8e3];for(const _0xb84141 of _0x592bbe)if(_0xb84141['item']['is']('element','tableCell')){const _0x239a33=this['_getVidAttributeName'](_0xb84141),_0x1ba183=_0xb84141['item']['getAttribute'](_0x239a33);if(_0x2558bd['has'](_0x1ba183)){const _0x43a938=_0xb84141['item']['parent']['parent']['getAttribute']('vid_start'),_0x220bc7=_0x24eaef['get'](_0x43a938)||new Set();_0x220bc7['add'](_0x2558bd['get'](_0x1ba183)['userId']),_0x24eaef['set'](_0x43a938,_0x220bc7);}}for(const _0x4c9291 of _0x24eaef['keys']())(_0xd475a0['has'](_0x4c9291)||_0x2558bd['has'](_0x4c9291))&&_0x24eaef['delete'](_0x4c9291);}for(const _0x26d23a of _0x23dd36){const _0x180de7=_0x4e2d15['insertions'][_0x26d23a];let _0xc6a999=null,_0x138226=null;for(const _0x117e7b of _0x180de7){const _0x38ecf1=this['_getVidAttributeName'](_0x117e7b),_0x21e6c0=_0x117e7b['item']['getAttribute'](_0x38ecf1),_0x2084b9=_0x24eaef['get'](_0x21e6c0);_0x2084b9&&'elementStart'==_0x117e7b['type']&&(_0xc6a999=Array['from'](_0x2084b9)[0x0],_0x138226=_0x117e7b['item']['getAttribute']('vid_end')),_0xc6a999&&(_0x2558bd['set'](_0x21e6c0,{'userId':_0xc6a999}),_0xd475a0['set'](_0x21e6c0,{'userId':_0xc6a999})),_0x21e6c0==_0x138226&&(_0xc6a999=null,_0x138226=null);}}const _0x245573={},_0x46c153=new Set();for(const _0x5bdde0 of _0x23dd36){const _0x40c1ac=_0x5fbb04['deletions'][_0x5bdde0],_0x22b068=_0x5fbb04['insertions'][_0x5bdde0];for(const {userId:_0x18ba2b}of this['_touchedMarkers']['values']())null!==_0x18ba2b&&_0x46c153['add'](_0x18ba2b);for(const {userId:_0x3ee5b1}of this['_touchedRoots']['values']())null!==_0x3ee5b1&&_0x46c153['add'](_0x3ee5b1);this['_markChanges'](_0x22b068,_0x4e2d15['insertions'][_0x5bdde0],_0xd475a0,'insertion',_0x46c153),this['_markChanges'](_0x40c1ac,_0x4e2d15['deletions'][_0x5bdde0],_0x2558bd,'deletion',_0x46c153),_0x245573[_0x5bdde0]={'insertions':this['_prepareViewToSave'](_0x22b068),'deletions':this['_prepareViewToSave'](_0x40c1ac),'attachChange':this['_touchedRoots']['get'](_0x5bdde0)||null,'attributesBefore':_0x1e8d51(this['_baseRootsAttributes']['get'](_0x5bdde0))||{},'attributesAfter':_0x1e8d51(this['_diffRootsAttributes']['get'](_0x5bdde0))};}return{'diffData':_0x245573,'authorsIds':Array['from'](_0x46c153)};}['_processRootBeforeSave'](_0xac8d5){for(const [,_0x544a41]of _0xac8d5['markers']){const _0x3a474a=_0x544a41['start']['getAncestors']()['filter'](_0x896a5d=>'tableCell'==_0x896a5d['name']);for(const _0x239f55 of _0x3a474a)0x1==_0x239f55['childCount']&&_0x239f55['getChild'](0x0)['is']('element','paragraph')&&_0x239f55['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x460c57){this['_processRootBeforeSave'](_0x460c57);const _0x28d0da=this['editor']['data']['toView'](_0x460c57,{}),_0x387880=Array['from'](_0x28d0da['getChildren']())['map'](_0x5bfd07=>this['_getViewJson'](_0x5bfd07));return JSON['stringify'](_0x387880);}['_getViewJson'](_0x3ce33b){if(_0x3ce33b['is']('$text'))return _0x3ce33b['data'];{const _0xd3ec87=_0x3ce33b;return{'type':Object['keys'](P)['find'](_0x525ac0=>_0x3ce33b instanceof P[_0x525ac0]),'name':_0xd3ec87['name'],'attributes':Array['from'](_0xd3ec87['getAttributes']()),'children':Array['from'](_0xd3ec87['getChildren']())['map'](_0x3a61f7=>this['_getViewJson'](_0x3a61f7))};}}['_markChanges'](_0x3d4142,_0xf4c54c,_0x224c6e,_0x376d2e,_0x290875){let _0x1c233d=null,_0xa8a022=null,_0xf0e22c=0x0;const _0x5cfdf6=this['editor']['model'];for(let _0x34d864=0x0;_0x34d864<_0xf4c54c['length'];_0x34d864++){const _0x5f19f9=this['_getVidAttributeName'](_0xf4c54c[_0x34d864]),_0x3ed263=_0xf4c54c[_0x34d864]['item']['getAttribute'](_0x5f19f9),_0x3bf171=_0x224c6e['get'](_0x3ed263),_0xcd0719=_0x34d864==_0xf4c54c['length']-0x1;(!_0x1c233d&&_0x3bf171&&(_0x1c233d=_0x3bf171,_0xa8a022=_0xf4c54c[_0x34d864]),_0x1c233d&&(!_0x3bf171||_0x3bf171['userId']!=_0x1c233d['userId']))&&(_0x24675a(_0x3bf171,B(_0xa8a022,_0x3d4142,_0x5cfdf6),B(_0xf4c54c[_0x34d864],_0x3d4142,_0x5cfdf6)),_0x1c233d=_0x3bf171||null,_0xa8a022=_0x3bf171?_0xf4c54c[_0x34d864]:null),_0x1c233d&&_0xcd0719&&_0x24675a(_0x3bf171,B(_0xa8a022,_0x3d4142,_0x5cfdf6),J(_0xf4c54c[_0x34d864],_0x3d4142,_0x5cfdf6));}function _0x24675a(_0x4c4603,_0x1d4e9f,_0x27c99f){const _0x2e8d66=_0x1c233d['userId'],_0x285b9d='revision:'+_0x376d2e+':'+_0x2e8d66+':'+_0xf0e22c++,_0x4ed8ac=_0x5cfdf6['createRange'](_0x1d4e9f,_0x27c99f);_0x3d4142['markers']['set'](_0x285b9d,_0x4ed8ac),null!==_0x2e8d66&&_0x290875['add'](_0x2e8d66);}}['_getVidAttributeName'](_0x1d82e0){switch(_0x1d82e0['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x1283dc,_0x2eb404){_0x1283dc['baseVersion']=null;for(const _0xc3460a in _0x1283dc){const _0x36ae2b=_0x1283dc[_0xc3460a];if(_0x36ae2b instanceof gt){const _0x156a21=_0x2eb404['get'](_0x36ae2b['root']['rootName']);_0x1283dc[_0xc3460a]=this['_fixPosition'](_0x36ae2b,_0x156a21);}if(_0x36ae2b instanceof vt){const _0x2517db=_0x2eb404['get'](_0x36ae2b['root']['rootName']);_0x1283dc[_0xc3460a]=this['_fixRange'](_0x36ae2b,_0x2517db);}'root'===_0xc3460a&&(_0x1283dc['root']=_0x2eb404['get'](_0x1283dc['root']['rootName']));}}['_fixRange'](_0x58a42e,_0x18f120){return this['editor']['model']['createRange'](this['_fixPosition'](_0x58a42e['start'],_0x18f120),this['_fixPosition'](_0x58a42e['end'],_0x18f120));}['_fixPosition'](_0x425f99,_0x2a5a2e){return this['editor']['model']['createPositionFromPath'](_0x2a5a2e,_0x425f99['path'],_0x425f99['stickiness']);}['_handleInsertOperation'](_0x2739bb){const _0x4f4c96=this['_idsRoots']['get'](_0x2739bb['position']['root']['rootName']),_0x49d1bc=this['_fixPosition'](_0x2739bb['position'],_0x4f4c96),_0x4cc22e=null===_0x2739bb['_authorId']?null:_0x2739bb['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x539734=_0x49d1bc['parent'],_0x293a31=this['_revisionId'],_0x54c0fc=[];for(const _0x45a018 of _0x2739bb['nodes'])if(_0x45a018['is']('element'))_0x54c0fc['push'](this['_makeIdsRoot'](_0x45a018));else{for(let _0x50fa85=0x0;_0x50fa85<_0x45a018['offsetSize'];_0x50fa85++)_0x54c0fc['push'](new ft('$text',{'vid':this['_revisionId']++}));}const _0x42cdc4=this['_revisionId'];for(let _0xd98803=_0x293a31;_0xd98803<_0x42cdc4;_0xd98803++)this['_touched']['set'](_0xd98803,{'userId':_0x4cc22e});_0x539734['_insertChild'](_0x49d1bc['offset'],_0x54c0fc);}['_handleMoveOperation'](_0x2b0f84){(_0x2b0f84=this['_cloneOperation'](_0x2b0f84,this['_idsRoots']))['_execute']();const _0x1112f4=null===_0x2b0f84['_authorId']?null:_0x2b0f84['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x90757e=_0x2b0f84['getMovedRangeStart'](),_0x39fb0e=_0x90757e['parent'],_0x30d893=_0x90757e['offset'];!function _0x16bda5(_0x55e72f,_0x24282f,_0x3bde9b,_0xd33026){for(let _0x5ef1df=_0x3bde9b;_0x5ef1df<_0xd33026;_0x5ef1df++){const _0x3a37e6=_0x24282f['getChild'](_0x5ef1df);_0x3a37e6['is']('element','$text')?_0x55e72f['set'](_0x3a37e6['getAttribute']('vid'),{'userId':_0x1112f4}):(_0x55e72f['set'](_0x3a37e6['getAttribute']('vid_start'),{'userId':_0x1112f4}),_0x16bda5(_0x55e72f,_0x3a37e6,0x0,_0x3a37e6['childCount']),_0x55e72f['set'](_0x3a37e6['getAttribute']('vid_end'),{'userId':_0x1112f4}));}}(this['_touched'],_0x39fb0e,_0x30d893,_0x30d893+_0x2b0f84['howMany']);}['_handleMergeOperation'](_0x19129b){const _0x210d7b=null===(_0x19129b=this['_cloneOperation'](_0x19129b,this['_idsRoots']))['_authorId']?null:_0x19129b['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x33a3e1=_0x19129b['targetPosition']['parent'],_0x5c0793=_0x19129b['sourcePosition']['parent'],_0x53ee30=_0x33a3e1['getAttribute']('vid_end'),_0x5e3713=_0x5c0793['getAttribute']('vid_start');_0x33a3e1['_setAttribute']('vid_end',_0x5c0793['getAttribute']('vid_end')),_0x5c0793['_setAttribute']('vid_end',_0x53ee30),this['_touched']['set'](_0x5e3713,{'userId':_0x210d7b}),this['_touched']['set'](_0x53ee30,{'userId':_0x210d7b}),_0x19129b['_execute']();}['_handleSplitOperation'](_0x34bce0){const _0x1bd2a8=null===(_0x34bce0=this['_cloneOperation'](_0x34bce0,this['_idsRoots']))['_authorId']?null:_0x34bce0['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x291d21=_0x34bce0['graveyardPosition'],_0x160e44=_0x34bce0['splitPosition']['parent'];_0x34bce0['_execute']();const _0x916d22=_0x160e44['getAttribute']('vid_end'),_0x3bf3a9=_0x34bce0['insertionPosition']['nodeAfter'];if(_0x291d21){const _0x62d463=_0x3bf3a9['getAttribute']('vid_end'),_0x57053e=_0x160e44['getAttribute']('vid_end');_0x160e44['_setAttribute']('vid_end',_0x62d463),_0x3bf3a9['_setAttribute']('vid_end',_0x57053e),this['_touched']['set'](_0x160e44['getAttribute']('vid_end'),{'userId':_0x1bd2a8}),this['_touched']['set'](_0x3bf3a9['getAttribute']('vid_start'),{'userId':_0x1bd2a8});}else{const _0x4c01b4=this['_revisionId']++,_0x2402ff=this['_revisionId']++;_0x160e44['_setAttribute']('vid_end',_0x4c01b4),_0x3bf3a9['_setAttribute']('vid_start',_0x2402ff),_0x3bf3a9['_setAttribute']('vid_end',_0x916d22),this['_touched']['set'](_0x4c01b4,{'userId':_0x1bd2a8}),this['_touched']['set'](_0x2402ff,{'userId':_0x1bd2a8});}}['_handleMarkerOperation'](_0x5b769b){if(!_0x5b769b['affectsData'])return;const _0x4aa13b=(_0x5b769b=this['_cloneOperation'](_0x5b769b,this['_diffRoots']))['oldRange']?_0x5b769b['oldRange']['root']:null,_0x5c30c4=_0x5b769b['newRange']?_0x5b769b['newRange']['root']:null;_0x4aa13b&&this['_markers']['delete'](_0x5b769b['name']),_0x5c30c4&&this['_markers']['set'](_0x5b769b['name'],_0x5b769b['newRange']['clone']());const _0x40d796=null===_0x5b769b['_authorId']?null:_0x5b769b['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x5cfb36=_0x5b769b['name'];if(!this['_touchedMarkers']['has'](_0x5cfb36))return void this['_touchedMarkers']['set'](_0x5cfb36,{'range':_0x5b769b['oldRange'],'userId':_0x40d796});const _0x1e502d=this['_touchedMarkers']['get'](_0x5cfb36),_0x49ecf5=_0x1e502d['range'],_0x524310=_0x5b769b['newRange'];null==_0x49ecf5&&null==_0x524310||_0x49ecf5&&_0x524310&&_0x49ecf5['isEqual'](_0x524310)?this['_touchedMarkers']['delete'](_0x5b769b['name']):_0x1e502d['userId']=_0x40d796;}['_handleRootOperation'](_0x5f0ee4,_0x2ba550){this['_diffRoots']['has'](_0x5f0ee4['rootName'])?this['_diffRoots']['get'](_0x5f0ee4['rootName'])['_isAttached']=_0x5f0ee4['isAdd']:(this['_diffRoots']['set'](_0x5f0ee4['rootName'],F(_0x5f0ee4['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x5f0ee4['rootName'],{}),_0x2ba550&&this['_idsRoots']['set'](_0x5f0ee4['rootName'],F(_0x5f0ee4['rootName'],!0x0)));const _0x32d288=null===_0x5f0ee4['_authorId']?null:_0x5f0ee4['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x1a5d26=this['_touchedRoots']['get'](_0x5f0ee4['rootName']);_0x1a5d26&&_0x1a5d26['userId']===_0x32d288?this['_touchedRoots']['delete'](_0x5f0ee4['rootName']):this['_touchedRoots']['set'](_0x5f0ee4['rootName'],{'userId':_0x32d288,'isAttached':_0x5f0ee4['isAdd']});}['_handleRootAttributeOperation'](_0x8112e1){const _0x564afb=this['_diffRootsAttributes']['get'](_0x8112e1['root']['rootName']);null===_0x8112e1['newValue']?delete _0x564afb[_0x8112e1['key']]:_0x564afb[_0x8112e1['key']]=_0x8112e1['newValue'];}}function T(_0x593a8d){const _0x220b24=F(_0x593a8d['rootName'],_0x593a8d['isAttached']());for(const _0x32ba1e of _0x593a8d['getChildren']()){const _0x5bc7d9=_0x32ba1e['_clone'](!0x0);_0x220b24['_appendChild'](_0x5bc7d9);}return _0x220b24;}function F(_0x32488b,_0x5132b0=!0x0){const _0x2afb57=new mt();return _0x2afb57['rootName']=_0x32488b,_0x2afb57['_isAttached']=_0x5132b0,_0x2afb57['isAttached']=()=>_0x2afb57['_isAttached'],_0x2afb57;}function B(_0x2a0d9c,_0x115b77,_0x4b2ea1){const _0x449bf8='elementEnd'==_0x2a0d9c['type']?_0x4b2ea1['createPositionAt'](_0x2a0d9c['item'],'end'):_0x4b2ea1['createPositionBefore'](_0x2a0d9c['item']);return _0x4b2ea1['createPositionFromPath'](_0x115b77,_0x449bf8['path'],_0x449bf8['stickiness']);}function J(_0x375028,_0x47f338,_0x718d42){const _0x2cbacc='elementStart'==_0x375028['type']?_0x718d42['createPositionAt'](_0x375028['item'],0x0):_0x718d42['createPositionAfter'](_0x375028['item']);return _0x718d42['createPositionFromPath'](_0x47f338,_0x2cbacc['path'],_0x2cbacc['stickiness']);}class ns extends _0x1d6e15{['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x10f10b,_0x2a3e6e){super(_0x10f10b),this['focusTracker']=new _0x1839c5(),this['keystrokes']=new _0x1b4f1b(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x2a3e6e),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'](),_0x1a3f56({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x4ef295=_0x4bd851=>_0x4bd851['stopPropagation']();this['keystrokes']['set']('arrowright',_0x4ef295),this['keystrokes']['set']('arrowleft',_0x4ef295),this['keystrokes']['set']('arrowup',_0x4ef295),this['keystrokes']['set']('arrowdown',_0x4ef295);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x491f22){this['revisionNameInputView']['fieldView']['element']['value']=_0x491f22['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x50b95e){const _0x41aa7e=new nt(this['locale'],_0x5d5d36),_0x4ea7fe=_0x41aa7e['fieldView'];_0x4ea7fe['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x4ff985=m(this['locale'],'Name\x20of\x20the\x20revision');return!_0x50b95e&&(_0x4ff985+='\x20('+m(this['locale'],'optional')+')'),(_0x41aa7e['label']=_0x4ff985,_0x4ea7fe['on']('input',()=>{this['revisionNameInputValue']=_0x4ea7fe['element']['value']['trim']();}),_0x41aa7e);}}class u extends _0x15974b{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l];}['_saveRevisionFormView'];['init'](){const _0x284fd5=this['editor'],_0x3afdb8=_0x284fd5['plugins']['get']('RevisionTracker');_0x284fd5['ui']['componentFactory']['add']('revisionHistory',_0x2f01d=>{const _0x566218=_0x3ccc2a(_0x2f01d),_0x1ec369=_0x566218['panelView']['children'],_0x450d8c=new te(_0x2f01d),_0x198135=new _0x5e7b7c(_0x2f01d),_0x2e25e3=new _0x3cc15e(_0x2f01d),_0xf686e3=new _0x5e7b7c(_0x2f01d),_0x390505=new _0x3cc15e(_0x2f01d);return _0x566218['bind']('isEnabled')['to'](_0x3afdb8,'isReady',_0x3afdb8,'isEnabled',_0x284fd5,'isReadOnly',(_0x3fbc77,_0x26929f,_0x2ee70f)=>_0x3fbc77&&_0x26929f&&!_0x2ee70f),_0x566218['buttonView']['set']({'icon':_0x470fce['history'],'label':m(_0x2f01d,'Revision\x20history'),'tooltip':!0x0}),_0x2e25e3['set']({'label':m(_0x2f01d,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x2e25e3['bind']('isEnabled')['to'](_0x3afdb8,'isReady',_0x3afdb8,'isEnabled',_0x284fd5,'isReadOnly',(_0x27a8c5,_0x4dd035,_0x2c3275)=>_0x27a8c5&&_0x4dd035&&!_0x2c3275),_0x2e25e3['on']('execute',()=>this['_showDialog']()),_0x390505['set']({'label':m(_0x2f01d,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x390505['bind']('isEnabled')['to'](_0x3afdb8,'isReady',_0x284fd5,'isReadOnly',(_0x55db5b,_0xcfe12)=>_0x55db5b&&!_0xcfe12),_0x390505['on']('execute',()=>{_0x284fd5['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x566218['isOpen']=!0x1,_0x284fd5['editing']['view']['focus']();}),_0x198135['children']['add'](_0x2e25e3),_0xf686e3['children']['add'](_0x390505),_0x450d8c['role']='menu',_0x450d8c['items']['addMany']([_0x198135,_0xf686e3]),_0x1ec369['add'](_0x450d8c),_0x566218;}),_0x284fd5['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x174394=this['editor'],_0x5109dc=_0x174394['locale'],_0x7b86dc=new _0x461892(_0x5109dc),_0x5b249a=new _0xe5be03(_0x5109dc);_0x7b86dc['buttonView']['set']({'icon':_0x470fce['history'],'label':m(_0x5109dc,'Revision\x20history')});const _0x40b42=new _0x3139e6(_0x5109dc,_0x7b86dc),_0x432769=new _0x2df223(_0x5109dc);_0x432769['set']({'label':m(_0x5109dc,'Save\x20current\x20revision')}),_0x432769['delegate']('execute')['to'](_0x7b86dc),_0x432769['on']('execute',()=>{this['_showDialog']();}),_0x40b42['children']['add'](_0x432769),_0x5b249a['items']['add'](_0x40b42);const _0x5ec969=new _0x3139e6(_0x5109dc,_0x7b86dc),_0x96a050=new _0x2df223(_0x5109dc);return _0x96a050['set']({'label':m(_0x5109dc,'Open\x20revision\x20history')}),_0x96a050['delegate']('execute')['to'](_0x7b86dc),_0x96a050['on']('execute',()=>{_0x174394['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x5ec969['children']['add'](_0x96a050),_0x5b249a['items']['add'](_0x5ec969),_0x7b86dc['panelView']['children']['add'](_0x5b249a),_0x7b86dc;}['_showDialog'](){const _0x26aedc=this['editor'],_0x4c9695=_0x26aedc['locale'],_0x3d1c88=_0x26aedc['plugins']['get']('Dialog'),_0x4d381e=_0x26aedc['plugins']['get']('RevisionTracker');function _0x17077d(_0x5eeef7){_0x26aedc['config']['get']('revisionHistory.requireRevisionName')&&''===_0x5eeef7['revisionName']?_0x5eeef7['revisionNameInputView']['errorText']=m(_0x4c9695,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x26aedc['plugins']['get'](l)['saveRevision']({'name':_0x5eeef7['revisionName']}),_0x3d1c88['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x17077d(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x3d1c88['show']({'id':'revisionSave','title':m(_0x4c9695,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':m(_0x26aedc['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x3d1c88['hide']()},{'label':m(_0x26aedc['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x747ab5){_0x747ab5['bind']('isEnabled')['to'](_0x4d381e,'isReady',_0x4d381e,'isEnabled',_0x26aedc,'isReadOnly',(_0x2605bc,_0x218dd2,_0x48852d)=>_0x2605bc&&_0x218dd2&&!_0x48852d);},'onExecute':()=>_0x17077d(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x3d61fd=this['editor'],_0x2d58be=_0x3d61fd['locale'];this['_saveRevisionFormView']=new ns(_0x2d58be,_0x3d61fd['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class X extends _0x1d6e15{['changeId'];['_model'];constructor(_0x1862de,_0x411066){super(_0x1862de),this['_model']=_0x411066,this['changeId']=_0x411066['id'];const _0x295925=this['bindTemplate'],_0x363ce2=m(_0x1862de,_0x411066['data']['isSuggestion']?'Suggested\x20by':'add'==_0x411066['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x411066['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x295925['to']('type',_0x4f172d=>'ck-revision-change__'+_0x4f172d)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x363ce2}]},{'text':'\x20'+_0x411066['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class r extends/* #__PURE__ -- @preserve */
25
- _0x167bf9(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x4899c4){super(),this['id']=_0x4899c4['id']||_0x41fc2a(),this['author']=_0x4899c4['author'],this['type']=_0x4899c4['type'],this['data']=_0x4899c4['data']||{},this['rootName']=_0x4899c4['rootName'],this['set']('createdAt',_0x4899c4['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(_0x51c256,_0x38016b){this['newRevisionId']=_0x51c256,this['oldRevisionId']=_0x38016b,this['changes']=new _0x53ab85();}['_setChanges'](_0x65f422){for(const _0x62f875 of _0x65f422)this['changes']['add'](_0x62f875);}}const Y={'c':_0x281cbc,'a':_0x31818f,'e':_0xbfca74,'r':_0x87c2e2,'u':_0x3bc906};class d extends _0x15974b{['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[_0x569660,_0x2e7606,j];}constructor(_0x5aa8b8){super(_0x5aa8b8),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',(_0x2a809e,_0x19d20d,_0x17d9e4)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x3cf544=>{for(const _0x204a43 of this['editor']['editing']['view']['document']['roots'])_0x17d9e4?_0x3cf544['removeClass']('ck-editor__editable__overlay',_0x204a43):_0x3cf544['addClass']('ck-editor__editable__overlay',_0x204a43);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x3590d3=>null!==_0x3590d3),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x42572d,_0x20ad4f,_0x2cdf86)=>_0x42572d&&_0x2cdf86?_0x20ad4f['changes']['getIndex'](_0x2cdf86):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0xfa9d0a,_0x2307c6)=>_0xfa9d0a?_0x2307c6['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['adapter']=null,this['_balloon']=this['editor']['plugins']['get'](_0x2e7606);}['init'](){const _0x4b7c80=this['editor'],_0x37b511=new yt(_0x4b7c80,{'direction':'backward'}),_0x2363f2=new yt(_0x4b7c80,{'direction':'forward'});(_0x4b7c80['commands']['add']('showPreviousChange',_0x37b511),_0x4b7c80['commands']['add']('showNextChange',_0x2363f2),_0x4b7c80['commands']['add']('restoreRevision',new _t(_0x4b7c80)),this['on']('change:numberOfChanges',()=>{_0x37b511['refresh'](),_0x2363f2['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x4b7c80['enableReadOnlyMode']('revision-viewer'),_0x4b7c80['plugins']['has']('WidgetToolbarRepository'))&&_0x4b7c80['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionData'](_0x1a160f){await this['loadRevisionData'](_0x1a160f);const _0x15a594={};for(const _0x41c76e in _0x1a160f['diffData']){if(_0x1a160f['diffData'][_0x41c76e]['attachChange']&&!_0x1a160f['diffData'][_0x41c76e]['attachChange']['isAttached'])continue;const _0x5110bf=this['_removeRevisionMarkers'](JSON['parse'](_0x1a160f['diffData'][_0x41c76e]['insertions'])),_0x533613=this['editor']['editing']['view']['document'],_0x1fd204=new _0x1a018e(_0x533613,_0x5110bf['map'](_0x4f0db6=>this['_getViewObj'](_0x4f0db6)));this['editor']['data']['processor']['useFillerType']('marked'),_0x15a594[_0x41c76e]=this['editor']['data']['processor']['toData'](_0x1fd204),this['editor']['data']['processor']['useFillerType']('default');}return _0x15a594;}async['getRevisionRootsAttributes'](_0x33ca88){await this['loadRevisionData'](_0x33ca88);const _0x57231c={};for(const _0x55844f in _0x33ca88['diffData'])_0x33ca88['diffData'][_0x55844f]['attachChange']&&!_0x33ca88['diffData'][_0x55844f]['attachChange']['isAttached']||(_0x57231c[_0x55844f]=_0x33ca88['diffData'][_0x55844f]['attributesAfter']||{});return _0x57231c;}['_removeRevisionMarkers'](_0x2ab46d){return(_0x2ab46d=_0x2ab46d['filter'](_0x1b9d71=>!_0x1b9d71['name']||'revision-start'!==_0x1b9d71['name']&&'revision-end'!==_0x1b9d71['name']))['forEach'](_0x3fb9e1=>{'string'!=typeof _0x3fb9e1&&(_0x3fb9e1['children']=this['_removeRevisionMarkers'](_0x3fb9e1['children']),_0x3fb9e1['attributes']=_0x3fb9e1['attributes']['filter'](_0x250a4f=>!_0x250a4f[0x0]['startsWith']('data-revision-')));}),_0x2ab46d;}async['compare'](_0x45cdec,_0x5e0cf6,_0x39ea29=!0x1){if(!this['isEnabled'])return;const _0x5af6f1=this['diff'],_0x1c5435=this['repository'],_0x40e5c2='string'==typeof _0x45cdec?_0x1c5435['getRevision'](_0x45cdec):_0x45cdec,_0x55f710='string'==typeof _0x5e0cf6?_0x1c5435['getRevision'](_0x5e0cf6):_0x5e0cf6,_0x4254a3=_0x40e5c2['id'],_0x36f9fc=_0x55f710?_0x55f710['id']:null;if(!_0x39ea29&&this['diff']&&this['diff']['newRevisionId']===_0x4254a3&&this['diff']['oldRevisionId']===_0x36f9fc)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new f(_0x4254a3,_0x36f9fc);const _0x348a24=this['_getRevisionsRange'](_0x40e5c2,_0x55f710,!0x0)['map'](_0x3d51db=>this['loadRevisionData'](_0x3d51db));return _0x348a24['push'](new Promise(_0x2e13bf=>{setTimeout(_0x2e13bf,0x14);})),Promise['all'](_0x348a24)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x51c52a=this['_getDiff'](_0x4254a3,_0x36f9fc);for(const _0x199fa7 of _0x51c52a['changes'])this['_changeIdToChange']['set'](_0x199fa7['id'],_0x199fa7);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x241317=>{for(const _0x4dddca of this['editor']['model']['document']['getRootNames']())_0x241317['detachRoot'](_0x4dddca);for(const _0x41769f of Object['keys'](_0x51c52a['model'])){const _0x13863d=_0x241317['addRoot'](_0x41769f);for(const _0xd3cc70 of Object['keys'](_0x51c52a['attributes'][_0x41769f]))_0x241317['setAttribute'](_0xd3cc70,_0x51c52a['attributes'][_0x41769f][_0xd3cc70],_0x13863d);_0x241317['insert'](_0x51c52a['model'][_0x41769f],_0x13863d,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x51c52a['changes'])),this['isReady']=!0x0;})['catch'](_0x1f4ee6=>{console['error'](_0x1f4ee6),this['_cleanUp'](),_0x5af6f1&&(this['diff']=_0x5af6f1),this['isReady']=!0x0;});}['addRevisionData'](_0x5f32ea,_0x4a5e01){const _0xe9c4cf=this['repository']['createRevision'](_0x5f32ea);return _0xe9c4cf['on']('_update',(_0xcc7c7f,_0x5dff89,_0x5eab22)=>_0x4a5e01(_0x5dff89,_0x5eab22,_0xe9c4cf)),this['repository']['addRevision'](_0xe9c4cf),_0xe9c4cf;}['loadRevisionData'](_0x45b8f5){if(!_0x45b8f5||_0x45b8f5['diffData'])return Promise['resolve']();{const _0xbfbf29=this['editor']['config']['get']('collaboration.channelId');return this['adapter']['getRevision']({'channelId':_0xbfbf29,'revisionId':_0x45b8f5['id']})['then'](_0x45142e=>{_0x45b8f5['_update']({'diffData':_0x45142e['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},_0x39ec34=>{for(const _0x3181f5 of this['editor']['model']['document']['getRootNames']())_0x39ec34['detachRoot'](_0x3181f5);});}['_sortAndFilterDiffChanges'](_0x24c265){const _0x5aeab2=[],_0x36ac04=new Map();for(const _0x341bd2 of this['editor']['model']['document']['getRootNames']()){const _0x4700ec=this['editor']['editing']['view']['getDomRoot'](_0x341bd2);if(!_0x4700ec)continue;const _0x334197=_0x4700ec['getClientRects']()['item'](0x0);_0x334197&&(_0x5aeab2['push'](_0x341bd2),_0x36ac04['set'](_0x341bd2,_0x334197));}return _0x5aeab2['sort']((_0x56c53b,_0x3730ff)=>{const _0x3be70a=_0x36ac04['get'](_0x56c53b),_0x430cf2=_0x36ac04['get'](_0x3730ff);return _0x3be70a['y']-_0x430cf2['y']||_0x3be70a['x']-_0x430cf2['x'];}),(_0x24c265=_0x24c265['filter'](_0x4c594b=>_0x5aeab2['includes'](_0x4c594b['rootName'])))['sort']((_0x39baa5,_0x4372f7)=>_0x5aeab2['indexOf'](_0x39baa5['rootName'])-_0x5aeab2['indexOf'](_0x4372f7['rootName'])),_0x24c265;}['_makeTape'](_0x1a7e28){const _0x425d19=Array['from'](_0x1a7e28['markers'])['filter'](([_0x9a455d,_0x579098])=>_0x9a455d['startsWith']('revision:')&&!_0x579098['isCollapsed']),_0x13a2ce=Array['from'](this['editor']['model']['createRangeIn'](_0x1a7e28)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x425d19['length'])for(const _0x4dd613 of _0x13a2ce){const [_0x158669,_0xd9a0a9]=_0x425d19[0x0],[,_0x1dc772,_0x4bd866]=_0x158669['split'](':');if(_0xd9a0a9['end']['isEqual'](_0x4dd613['nextPosition'])&&_0x425d19['shift'](),(_0x4dd613['previousPosition']['isEqual'](_0xd9a0a9['start'])||_0x4dd613['previousPosition']['isAfter'](_0xd9a0a9['start']))&&('insertion'==_0x1dc772?_0x4dd613['isAdded']={'userId':_0x4bd866}:'deletion'==_0x1dc772&&(_0x4dd613['isRemoved']={'userId':_0x4bd866})),0x0==_0x425d19['length'])break;}return _0x13a2ce;}['_refreshStartEndIndex'](_0x122e0b){const _0x5674b3=new Map();for(let _0x556f28=0x0;_0x556f28<_0x122e0b['length'];_0x556f28++)'text'===_0x122e0b[_0x556f28]['type']?(_0x122e0b[_0x556f28]['item']['startIndex']=_0x556f28,_0x122e0b[_0x556f28]['item']['endIndex']=_0x556f28):('elementStart'===_0x122e0b[_0x556f28]['type']?_0x122e0b[_0x556f28]['item']['startIndex']=_0x556f28:'elementEnd'===_0x122e0b[_0x556f28]['type']&&(_0x122e0b[_0x556f28]['item']['endIndex']=_0x556f28),_0x5674b3['set'](_0x122e0b[_0x556f28]['id'],_0x556f28));for(const _0x58d1fc of _0x5674b3['values']())'elementStart'===_0x122e0b[_0x58d1fc]['type']?_0x122e0b[_0x58d1fc]['item']['endIndex']=_0x5674b3['get'](_0x122e0b[_0x58d1fc]['pairId']):'elementEnd'===_0x122e0b[_0x58d1fc]['type']&&(_0x122e0b[_0x58d1fc]['item']['startIndex']=_0x5674b3['get'](_0x122e0b[_0x58d1fc]['pairId']));}['_processTape'](_0x59cd17){for(let _0x4cc318=0x0;_0x4cc318<_0x59cd17['length'];_0x4cc318++){if('elementStart'===_0x59cd17[_0x4cc318]['type'])_0x59cd17[_0x4cc318]['item']['startIndex']=_0x4cc318;else{if('elementEnd'===_0x59cd17[_0x4cc318]['type']){_0x59cd17[_0x4cc318]['item']['endIndex']=_0x4cc318;const _0x4d83ab=_0x59cd17[_0x4cc318]['item']['startIndex'];_0x59cd17[_0x4d83ab]['pairId']=_0x59cd17[_0x4cc318]['id'],_0x59cd17[_0x4cc318]['pairId']=_0x59cd17[_0x4d83ab]['id'];}else _0x59cd17[_0x4cc318]['item']['startIndex']=_0x4cc318,_0x59cd17[_0x4cc318]['item']['endIndex']=_0x4cc318,_0x59cd17[_0x4cc318]['pairId']=null;}_0x59cd17[_0x4cc318]['markersStart']||(_0x59cd17[_0x4cc318]['markersStart']=[],_0x59cd17[_0x4cc318]['markersEnd']=[]);}}['_markInsertions'](_0x363b41,_0x1166ab){const _0x420846=_0x363b41['filter'](_0xeec581=>!_0xeec581['isAdded']);for(let _0x18e76c=0x0;_0x18e76c<_0x1166ab['length'];_0x18e76c++)_0x1166ab[_0x18e76c]['isAdded']&&(_0x420846[_0x18e76c]['isAdded']=_0x1166ab[_0x18e76c]['isAdded']);}['_makeModelFromViewString'](_0xa9aba8){const _0x367dc9=JSON['parse'](_0xa9aba8),_0x561ff5=this['editor']['editing']['view']['document'],_0x1b2f51=new _0x1a018e(_0x561ff5,_0x367dc9['map'](_0xe0bc28=>this['_getViewObj'](_0xe0bc28)));return this['editor']['data']['toModel'](_0x1b2f51);}['_getViewObj'](_0x12a4c6){const _0x566cb7=this['editor']['editing']['view']['document'];if('string'==typeof _0x12a4c6)return new _0xf6e769(_0x566cb7,_0x12a4c6);{const _0x1632c1=_0x12a4c6['children']['map'](_0x2ec173=>this['_getViewObj'](_0x2ec173));return new(Y[_0x12a4c6['type']]||_0xf7d26d)(_0x566cb7,_0x12a4c6['name'],_0x12a4c6['attributes'],_0x1632c1);}}['_getDiff'](_0x3c31d4,_0x251f6d=null){const _0xbf29f6=this['repository']['getRevision'](_0x3c31d4),_0xee2c0c=_0x251f6d?this['repository']['getRevision'](_0x251f6d):null,_0x5506c7=this['_getRevisionsRange'](_0xbf29f6,_0xee2c0c),_0x486368=_0x5506c7[_0x5506c7['length']-0x1],_0x19cb4e=new Map(),_0x3c297a={'model':{},'attributes':{},'changes':[]},_0x3f04e0=new Set(),_0xb0299b=new Map();for(let _0x394ac4=_0x5506c7['length']-0x1;_0x394ac4>=0x0;_0x394ac4--){const _0x6b39f4=_0x5506c7[_0x394ac4];for(const _0x2bba0d of Object['keys'](_0x6b39f4['diffData']))if(_0x6b39f4['diffData'][_0x2bba0d]['attachChange']){const _0x59afe9=_0x6b39f4['diffData'][_0x2bba0d]['attachChange'];_0x59afe9['isAttached']?(_0x3f04e0['add'](_0x2bba0d),_0xb0299b['has'](_0x2bba0d)&&_0xb0299b['get'](_0x2bba0d)['userId']==_0x59afe9['userId']?_0xb0299b['delete'](_0x2bba0d):_0xb0299b['set'](_0x2bba0d,_0x59afe9)):_0xb0299b['has'](_0x2bba0d)?(_0x3f04e0['delete'](_0x2bba0d),_0xb0299b['delete'](_0x2bba0d)):(_0x3f04e0['add'](_0x2bba0d),_0xb0299b['set'](_0x2bba0d,_0x59afe9));}else _0x3f04e0['add'](_0x2bba0d);}for(const _0x10c246 of _0x3f04e0){const _0x5d16d2=_0xb0299b['has'](_0x10c246)&&!_0xb0299b['get'](_0x10c246)['isAttached'];let _0x5f0e91=_0x5d16d2?_0x5506c7['length']-0x1:0x0;const _0x2015a4=_0x5d16d2?-0x1:0x1;for(;_0x5506c7[_0x5f0e91];){const _0x2ffdab=_0x5506c7[_0x5f0e91];if(_0x2ffdab['diffData'][_0x10c246]){const _0x407909=_0x5d16d2?_0x2ffdab['diffData'][_0x10c246]['attributesBefore']:_0x2ffdab['diffData'][_0x10c246]['attributesAfter'];_0x3c297a['attributes'][_0x10c246]=_0x407909?_0x1e8d51(_0x407909):{};break;}_0x5f0e91+=_0x2015a4;}}for(const _0x21055d of _0x5506c7){_0x21055d['model']={};for(const _0x5beee9 of _0x21055d['authors'])_0x19cb4e['set'](_0x5beee9['id'],_0x5beee9);for(const _0x25c5a0 of _0x3f04e0){const _0x387f0a=_0x21055d['diffData'][_0x25c5a0]?_0x21055d['diffData'][_0x25c5a0]['insertions']:'[]',_0x1eb9c2=_0x21055d['diffData'][_0x25c5a0]?_0x21055d['diffData'][_0x25c5a0]['deletions']:'[]';_0x21055d['model'][_0x25c5a0]={'insertions':this['_makeModelFromViewString'](_0x387f0a),'deletions':this['_makeModelFromViewString'](_0x1eb9c2)};}}for(const _0x307698 of _0x3f04e0){let _0x589ab7=null,_0x39ad62=0x0;const _0x1be7c3=new Map(Array['from'](_0xbf29f6['model'][_0x307698]['insertions']['markers'])['filter'](([_0x34e88d])=>!_0x34e88d['startsWith']('revision:')));let _0x5f04a9=0x0;for(const _0x16e482 of _0x5506c7){const _0xd0c4bf=this['_makeTape'](_0x16e482['model'][_0x307698]['insertions']);_0x16e482==_0xbf29f6?(_0x589ab7=_0xd0c4bf,_0x39ad62=_0x589ab7['length'],_0x589ab7['forEach'](_0xd3fbe8=>{_0xd3fbe8['id']=_0x5f04a9++;}),this['_processTape'](_0x589ab7)):this['_markInsertions'](_0x589ab7,_0xd0c4bf);const _0x2c94d0=_0x589ab7['filter'](_0x2d13ba=>!_0x2d13ba['isAdded'])['map'](_0x519f84=>_0x519f84['id']);let _0x5cc02c=0x0;const _0x15302c=this['_makeTape'](_0x16e482['model'][_0x307698]['deletions']);_0x15302c['forEach'](_0x18daa7=>{_0x18daa7['isRemoved']?_0x18daa7['id']=_0x39ad62++:_0x18daa7['id']=_0x2c94d0[_0x5cc02c++];}),this['_processTape'](_0x15302c),this['_setDistance'](_0x589ab7,'isAdded'),this['_setDistance'](_0x15302c,'isRemoved'),_0x16e482==_0xbf29f6&&this['_markMarkers'](_0x589ab7,_0x1be7c3),_0x589ab7=this['_joinTapes'](_0x589ab7,_0x15302c),this['_refreshStartEndIndex'](_0x589ab7),this['_setDistance'](_0x589ab7,'isRemoved');}_0x589ab7=_0x589ab7['filter'](_0x30fd21=>!(_0x30fd21['isAdded']&&_0x30fd21['isRemoved']));const _0x3384e6=new Map(_0x486368['model'][_0x307698]['deletions']['markers']),_0x406a8b=new Set(_0x1be7c3['keys']());for(const _0x17b11c of _0x3384e6['keys']())_0x406a8b['delete'](_0x17b11c);this['_markSuggestions'](_0x589ab7,_0x406a8b),this['_fixObsoleteTags'](_0x589ab7),_0x589ab7=this['_removeMissingPairs'](_0x589ab7),_0x589ab7=this['_markMismatchedRemovedTags'](_0x589ab7),_0x589ab7=this['_removeUnsupportedChanges'](_0x589ab7);const {root:_0x50883b,changes:_0x11cba1}=this['_makeModelFromTape'](_0x589ab7,_0x19cb4e,_0x307698);_0x3c297a['model'][_0x307698]=_0x50883b;const _0x8b4faa=_0xb0299b['get'](_0x307698);if(_0x8b4faa){const _0x24662c=_0x19cb4e['get'](_0x8b4faa['userId']),_0x477e49=new r({'author':_0x24662c,'type':_0x8b4faa['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x307698});_0x11cba1['unshift'](_0x477e49),_0x3c297a['attributes'][_0x307698]['revisionHistoryAttachChange']=_0x477e49['id'];}_0x3c297a['changes']=_0x3c297a['changes']['concat'](_0x11cba1);}return _0x3c297a;}['_markMarkers'](_0x5921a6,_0x288adb){for(let _0x39ad7c=0x0;_0x39ad7c<_0x5921a6['length'];_0x39ad7c++)for(const [_0x21f03c,_0x50f66d]of _0x288adb)_0x50f66d['start']['isEqual'](_0x5921a6[_0x39ad7c]['previousPosition'])&&_0x5921a6[_0x39ad7c]['markersStart']['push'](_0x21f03c),_0x50f66d['end']['isEqual'](_0x5921a6[_0x39ad7c]['nextPosition'])&&_0x5921a6[_0x39ad7c]['markersEnd']['push'](_0x21f03c);}['_joinTapes'](_0x5181e6,_0x59ebe1){let _0x539c18=[],_0x16c8dd=0x0,_0x1e6dcc=0x0;for(;_0x16c8dd<_0x5181e6['length']||_0x1e6dcc<_0x59ebe1['length'];){const _0xb272a2=_0x5181e6[_0x16c8dd]||{},_0x28cb70=_0x59ebe1[_0x1e6dcc]||{};if(_0xb272a2['id']==_0x28cb70['id'])_0x16c8dd++,_0x1e6dcc++,_0x539c18['push'](_0xb272a2);else{if(_0x28cb70['isRemoved']&&_0xb272a2['isAdded']){const {commonTape:_0x3737dc,iEnd:_0x2c2b64,jEnd:_0x57bb18}=this['_threeWayMerge'](_0x5181e6,_0x16c8dd,_0x59ebe1,_0x1e6dcc);_0x539c18=_0x539c18['concat'](_0x3737dc),_0x16c8dd=_0x2c2b64,_0x1e6dcc=_0x57bb18;}else _0x28cb70['isRemoved']?(_0x1e6dcc++,_0x539c18['push'](_0x28cb70)):(_0x16c8dd++,_0x539c18['push'](_0xb272a2));}}return _0x539c18;}['_markSuggestions'](_0x547fa8,_0x10c702){const _0x357eaf=[];for(let _0x361d58=0x0;_0x361d58<_0x547fa8['length'];_0x361d58++){for(let _0x2c9f64=0x0;_0x2c9f64<_0x547fa8[_0x361d58]['markersStart']['length'];_0x2c9f64++){const _0x282d7f=_0x547fa8[_0x361d58]['markersStart'][_0x2c9f64];if(!_0x10c702['has'](_0x282d7f))continue;const {group:_0x41fb5c,type:_0x1cabd0,authorId:_0x4b0e8f}=_0x2ec05e(_0x282d7f);'revision-suggestion'!=_0x41fb5c||'insertion'!=_0x1cabd0&&'deletion'!=_0x1cabd0||(_0x357eaf['unshift']({'type':_0x1cabd0,'name':_0x282d7f,'userId':_0x4b0e8f}),_0x547fa8[_0x361d58]['markersStart']['splice'](_0x2c9f64,0x1),_0x2c9f64--);}_0x24e88f(_0x547fa8[_0x361d58]);for(let _0xdeaba6=0x0;_0xdeaba6<_0x547fa8[_0x361d58]['markersEnd']['length'];_0xdeaba6++){const _0x301bae=_0x547fa8[_0x361d58]['markersEnd'][_0xdeaba6];if(!_0x10c702['has'](_0x301bae))continue;const {group:_0xbf290a,type:_0x2ebe9d}=_0x2ec05e(_0x301bae);if('revision-suggestion'!=_0xbf290a||'insertion'!=_0x2ebe9d&&'deletion'!=_0x2ebe9d)continue;_0x547fa8[_0x361d58]['markersEnd']['splice'](_0xdeaba6,0x1),_0xdeaba6--;const _0x3f9211=_0x357eaf['findIndex'](_0xb4946a=>_0xb4946a['name']==_0x301bae);_0x3f9211>-0x1&&_0x357eaf['splice'](_0x3f9211,0x1);}}function _0x2ec05e(_0x10397f){const _0x1f7607=_0x10397f['split'](':');return{'group':_0x1f7607[0x0],'type':_0x1f7607[0x1],'subType':_0x1f7607['length']>=0x5?_0x1f7607[0x2]:null,'id':_0x1f7607['length']<0x5?_0x1f7607[0x2]:_0x1f7607[0x3],'authorId':_0x1f7607['length']<0x5?_0x1f7607[0x3]:_0x1f7607[0x4],'markerCount':0x6==_0x1f7607['length']?_0x1f7607[0x5]:null};}function _0x24e88f(_0x4b19eb){for(let _0x2aca9c=0x0;_0x2aca9c<_0x357eaf['length'];_0x2aca9c++){if(_0x4b19eb['isAdded']&&'insertion'==_0x357eaf[_0x2aca9c]['type'])return _0x4b19eb['isAddSuggestion']=_0x357eaf[_0x2aca9c],void delete _0x4b19eb['isAdded'];if(!_0x4b19eb['isAdded']&&!_0x4b19eb['isRemoved']&&'deletion'==_0x357eaf[_0x2aca9c]['type'])return void(_0x4b19eb['isRemoveSuggestion']=_0x357eaf[_0x2aca9c]);}}}['_setDistance'](_0xd2b08c,_0x5bea88){let _0x3a5258=0x0,_0x55d4f5=!0x1;const _0x58a236=new Map();for(const _0xfa87ad of _0xd2b08c)_0xfa87ad[_0x5bea88]?_0x55d4f5&&(_0x3a5258++,_0x55d4f5=!0x1):(_0x3a5258++,_0x55d4f5=!0x0),_0x58a236['set'](_0xfa87ad['id'],_0x3a5258);for(let _0x4d338d=0x0;_0x4d338d<_0xd2b08c['length'];_0x4d338d++){if('isRemoved'==_0x5bea88&&_0xd2b08c[_0x4d338d]['isAdded']||'isAdded'==_0x5bea88&&_0xd2b08c[_0x4d338d]['isRemoved'])continue;if('text'==_0xd2b08c[_0x4d338d]['type']){_0xd2b08c[_0x4d338d]['distance']=0x0;continue;}const _0x307d54=_0x58a236['get'](_0xd2b08c[_0x4d338d]['pairId']),_0x155c60=_0x58a236['get'](_0xd2b08c[_0x4d338d]['id']);_0xd2b08c[_0x4d338d]['distance']=_0x307d54-_0x155c60;}}['_getRevisionsRange'](_0x4906b8,_0x16431e,_0x5ef862=!0x1){const _0x38123a=[];let _0x57ef98=this['repository']['getIndex'](_0x4906b8),_0x5d1ebd=this['repository']['getIndex'](_0x16431e);for(-0x1==_0x5d1ebd&&(_0x5d1ebd=this['repository']['_revisions']['length'],_0x5ef862=!0x1);_0x57ef98<_0x5d1ebd;)_0x38123a['push'](this['repository']['getRevision'](_0x57ef98)),_0x57ef98++;return _0x5ef862&&_0x38123a['push'](this['repository']['getRevision'](_0x57ef98)),_0x38123a;}['_threeWayMerge'](_0x494a1d,_0x51e92e,_0x54e1e9,_0x11b5cc){const _0x3a674c=this['editor']['model']['schema'];let _0x594ec1=_0x51e92e;for(;_0x494a1d[_0x594ec1]&&_0x494a1d[_0x594ec1]['isAdded'];)_0x594ec1++;let _0x22a3e2=_0x11b5cc;for(;_0x54e1e9[_0x22a3e2]&&_0x54e1e9[_0x22a3e2]['isRemoved'];)_0x22a3e2++;_0x3fdf90(_0x494a1d,_0x51e92e,_0x594ec1),_0x3fdf90(_0x54e1e9,_0x11b5cc,_0x22a3e2);const _0xd3cf44=_0x54e1e9['slice'](_0x11b5cc,_0x22a3e2)['concat'](_0x494a1d['slice'](_0x51e92e,_0x594ec1));return _0xd3cf44['sort']((_0x5dccc2,_0x3b3257)=>_0x5dccc2['side']!=_0x3b3257['side']?_0x5dccc2['side']-_0x3b3257['side']:_0x5dccc2['level']!=_0x3b3257['level']?_0x5dccc2['level']-_0x3b3257['level']:_0x5dccc2['distance']!=_0x3b3257['distance']?_0x3b3257['distance']-_0x5dccc2['distance']:!!_0x5dccc2['isAdded']!=!!_0x3b3257['isAdded']?-0x1==_0x5dccc2['side']||0x0==_0x5dccc2['side']?_0x5dccc2['isAdded']?-0x1:0x1:_0x5dccc2['isAdded']?0x1:-0x1:_0x5dccc2['index']-_0x3b3257['index']),{'commonTape':_0xd3cf44,'iEnd':_0x594ec1,'jEnd':_0x22a3e2};function _0x3fdf90(_0x4b4f02,_0x255093,_0x4adadb){let _0x23a54f=-0x1,_0x4ad5b6=Number['POSITIVE_INFINITY'],_0x26a026=!0x0;for(let _0x41fe74=_0x255093;_0x41fe74<_0x4adadb;_0x41fe74++)if(_0x3a674c['isInline'](_0x4b4f02[_0x41fe74]['item'])||(_0x26a026=!0x1),_0x4b4f02[_0x41fe74]['item']['startIndex']<_0x255093&&(_0x23a54f=_0x41fe74),_0x4b4f02[_0x41fe74]['item']['endIndex']>=_0x4adadb){_0x4ad5b6=_0x41fe74;break;}_0x26a026&&(_0x23a54f=_0x4adadb-0x1);for(let _0x54e523=_0x255093;_0x54e523<_0x4adadb;_0x54e523++)_0x4b4f02[_0x54e523]['side']=_0x54e523<=_0x23a54f?-0x1:_0x54e523<_0x4ad5b6?0x0:0x1,_0x4b4f02[_0x54e523]['index']=_0x54e523;let _0x2816ef=0x0;for(let _0x173254=_0x255093;_0x173254<=_0x23a54f;_0x173254++)0x0==_0x4b4f02[_0x173254]['distance']?_0x4b4f02[_0x173254]['level']=_0x2816ef:(_0x2816ef++,_0x4b4f02[_0x173254]['level']=_0x2816ef,_0x2816ef++);for(let _0x5de0aa=_0x255093;_0x5de0aa<_0x4adadb;_0x5de0aa++)0x0==_0x4b4f02[_0x5de0aa]['side']&&(_0x4b4f02[_0x5de0aa]['level']=_0x2816ef);_0x2816ef=0x0;for(let _0x469b41=_0x4adadb-0x1;_0x469b41>=_0x4ad5b6;_0x469b41--)0x0==_0x4b4f02[_0x469b41]['distance']?_0x4b4f02[_0x469b41]['level']=_0x2816ef:(_0x2816ef--,_0x4b4f02[_0x469b41]['level']=_0x2816ef,_0x2816ef--);}}['_fixObsoleteTags'](_0x685c7f){const _0x2a2b3b=new Map(),_0xb8f777=this['editor']['model']['schema'];for(let _0x4ae50a=0x1;_0x4ae50a<_0x685c7f['length'];_0x4ae50a++){let _0x59d9cd,_0x1ab55e,_0xc33cb4;const _0x4726f9=_0x685c7f[_0x4ae50a],_0xbcb96e=_0x685c7f[_0x4ae50a-0x1];if('text'==_0x4726f9['type'])continue;if(_0x4726f9['type']!=_0xbcb96e['type'])continue;if(!_0xb8f777['isBlock'](_0xbcb96e['item'])||_0xb8f777['isLimit'](_0xbcb96e['item']))continue;if(!_0xb8f777['isBlock'](_0x4726f9['item'])||_0xb8f777['isLimit'](_0x4726f9['item']))continue;if((_0x685c7f[_0x4ae50a]['isAdded']||_0x685c7f[_0x4ae50a]['isAddSuggestion'])&&_0x685c7f[_0x4ae50a-0x1]['isRemoved'])_0x59d9cd=_0x685c7f[_0x4ae50a],_0x1ab55e=_0x685c7f[_0x4ae50a-0x1],_0xc33cb4=_0x4ae50a-0x1;else{if(!_0x685c7f[_0x4ae50a]['isRemoved']||!_0x685c7f[_0x4ae50a-0x1]['isAdded']&&!_0x685c7f[_0x4ae50a-0x1]['isAddSuggestion'])continue;_0x59d9cd=_0x685c7f[_0x4ae50a-0x1],_0x1ab55e=_0x685c7f[_0x4ae50a],_0xc33cb4=_0x4ae50a;}const _0x3c275c=_0x59d9cd['level']==_0x1ab55e['level'],_0x325f02=Math['abs'](_0x59d9cd['level'])<Math['abs'](_0x1ab55e['level'])&&0x0==_0x1ab55e['distance'];(_0x3c275c||_0x325f02)&&(_0x2a2b3b['set'](_0x1ab55e['id'],_0x59d9cd['id']),_0x685c7f['splice'](_0xc33cb4,0x1),_0x4ae50a--,_0x59d9cd['isAdded']=!0x1);}for(let _0x214841=0x0;_0x214841<_0x685c7f['length'];_0x214841++)_0x2a2b3b['has'](_0x685c7f[_0x214841]['pairId'])&&(_0x685c7f[_0x214841]['pairId']=_0x2a2b3b['get'](_0x685c7f[_0x214841]['pairId']));}['_removeMissingPairs'](_0x3d0f3e){const _0x20ecf7=new Set(_0x3d0f3e['map'](_0x5cd065=>_0x5cd065['id']));for(let _0x26fcb3=0x0;_0x26fcb3<_0x3d0f3e['length'];_0x26fcb3++)_0x20ecf7['has'](_0x3d0f3e[_0x26fcb3]['pairId'])||0x0==_0x3d0f3e[_0x26fcb3]['distance']||(_0x3d0f3e[_0x26fcb3]['isIncorrect']=!0x0);return _0x3d0f3e['filter'](_0x31082f=>!_0x31082f['isIncorrect']);}['_markMismatchedRemovedTags'](_0x57c6c2){const _0x1bb0d0=new Set();for(let _0x111846=0x0;_0x111846<_0x57c6c2['length'];_0x111846++){if(_0x1bb0d0['has'](_0x57c6c2[_0x111846]['id'])&&_0x57c6c2[_0x111846]['isRemoved']&&(_0x57c6c2[_0x111846]['isIncorrect']=!0x0),_0x57c6c2[_0x111846]['isIncorrect'])continue;if(0x0==_0x57c6c2[_0x111846]['distance'])continue;if('elementStart'!=_0x57c6c2[_0x111846]['type'])continue;if(null==_0x57c6c2[_0x111846]['pairId'])continue;let _0x523c11=_0x111846+0x1,_0x3992e7=0x0;for(;_0x57c6c2[_0x523c11]['id']!=_0x57c6c2[_0x111846]['pairId'];)'elementStart'==_0x57c6c2[_0x523c11]['type']?_0x3992e7++:'elementEnd'==_0x57c6c2[_0x523c11]['type']&&_0x3992e7--,_0x523c11++;if(0x0!=_0x3992e7){if(_0x57c6c2[_0x111846]['isRemoved'])_0x57c6c2[_0x111846]['isIncorrect']=!0x0;else{for(;_0x523c11!=_0x111846;)_0x57c6c2[_0x523c11]['isRemoved']&&0x0!=_0x57c6c2[_0x523c11]['distance']&&(_0x57c6c2[_0x523c11]['isIncorrect']=!0x0,_0x1bb0d0['add'](_0x57c6c2[_0x523c11]['pairId'])),_0x523c11--;}}}return _0x57c6c2['filter'](_0x42fa40=>!_0x42fa40['isIncorrect']);}['_removeUnsupportedChanges'](_0x923787){const _0x4e72ee=this['editor']['model']['schema'];for(let _0x307bee=0x0;_0x307bee<_0x923787['length'];_0x307bee++){if(!(_0x923787[_0x307bee]['isAdded']||_0x923787[_0x307bee]['isAddSuggestion']||_0x923787[_0x307bee]['isRemoved']||_0x923787[_0x307bee]['isRemoveSuggestion']))continue;if(0x0==_0x923787[_0x307bee]['distance'])continue;const _0x43c9c6=_0x923787[_0x307bee]['item'];_0x4e72ee['isBlock'](_0x43c9c6)||_0x4e72ee['isLimit'](_0x43c9c6)||(_0x923787[_0x307bee]['isAdded']&&delete _0x923787[_0x307bee]['isAdded'],_0x923787[_0x307bee]['isAddSuggestion']&&delete _0x923787[_0x307bee]['isAddSuggestion'],_0x923787[_0x307bee]['isRemoveSuggestion']&&delete _0x923787[_0x307bee]['isRemoveSuggestion'],_0x923787[_0x307bee]['isRemoved']&&(_0x923787[_0x307bee]['isIncorrect']=!0x0));}return _0x923787['filter'](_0x167117=>!_0x167117['isIncorrect']);}['_makeModelFromTape'](_0x3aabf1,_0x38e0bf,_0x59ac65){const _0x13e75f=new mt(),_0x189c83=[],_0x36dafc=new Map(),_0x36fd24=this['editor']['model'],_0x40d3b9=_0x36fd24['schema'],_0x554187=[_0x13e75f],_0x4f3f9d={},_0x474008={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x1acd26=null;const _0x57403e=[0x0];for(let _0x25aeb8=0x0;_0x25aeb8<_0x3aabf1['length'];_0x25aeb8++)if('elementStart'===_0x3aabf1[_0x25aeb8]['type']){_0x3aabf1[_0x25aeb8]['previousPosition']=_0x36fd24['createPositionFromPath'](_0x13e75f,_0x57403e);const _0x85b46a=new ft(_0x3aabf1[_0x25aeb8]['item']['name'],_0x3aabf1[_0x25aeb8]['item']['getAttributes']());_0x554187[0x0]['_appendChild'](_0x85b46a),_0x57403e['push'](0x0),_0x554187['unshift'](_0x85b46a),_0x3aabf1[_0x25aeb8]['nextPosition']=_0x36fd24['createPositionFromPath'](_0x13e75f,_0x57403e);}else'elementEnd'===_0x3aabf1[_0x25aeb8]['type']?(_0x554187['shift'](),_0x3aabf1[_0x25aeb8]['previousPosition']=_0x36fd24['createPositionFromPath'](_0x13e75f,_0x57403e),_0x57403e['pop'](),_0x57403e[_0x57403e['length']-0x1]++,_0x3aabf1[_0x25aeb8]['nextPosition']=_0x36fd24['createPositionFromPath'](_0x13e75f,_0x57403e)):(_0x3aabf1[_0x25aeb8]['previousPosition']=_0x36fd24['createPositionFromPath'](_0x13e75f,_0x57403e),_0x1acd26?_0x1acd26['_data']+=_0x3aabf1[_0x25aeb8]['item']['data']:_0x1acd26=new wt(_0x3aabf1[_0x25aeb8]['item']['data'],_0x3aabf1[_0x25aeb8]['item']['getAttributes']()),_0x3aabf1[_0x25aeb8+0x1]&&'text'===_0x3aabf1[_0x25aeb8+0x1]['type']&&_0x3ea2b5(_0x1acd26,_0x3aabf1[_0x25aeb8+0x1]['item'])||(_0x554187[0x0]['_appendChild'](_0x1acd26),_0x1acd26=null),_0x57403e[_0x57403e['length']-0x1]+=_0x3aabf1[_0x25aeb8]['item']['offsetSize'],_0x3aabf1[_0x25aeb8]['nextPosition']=_0x36fd24['createPositionFromPath'](_0x13e75f,_0x57403e));for(let _0x3a0d17=0x0;_0x3a0d17<_0x3aabf1['length'];_0x3a0d17++){const _0x14ae25=_0x3aabf1[_0x3a0d17]['previousPosition'],_0x3c9350=_0x3aabf1[_0x3a0d17]['nextPosition'];for(const _0x512402 of _0x3aabf1[_0x3a0d17]['markersStart'])_0x36dafc['set'](_0x512402,{'start':_0x14ae25,'end':null});_0x2fad96('isRemoveSuggestion',_0x3a0d17,_0x14ae25,_0x3c9350),_0x2fad96('isAddSuggestion',_0x3a0d17,_0x14ae25,_0x3c9350),_0x2fad96('isRemoved',_0x3a0d17,_0x14ae25,_0x3c9350),_0x2fad96('isAdded',_0x3a0d17,_0x14ae25,_0x3c9350);for(const _0x2ae9ee of _0x3aabf1[_0x3a0d17]['markersEnd']){_0x36dafc['get'](_0x2ae9ee)['end']=_0x3c9350;}}for(const [_0xca33fb,_0x5915e7]of _0x36dafc){const _0x35d42e=this['editor']['model']['createRange'](_0x5915e7['start'],_0x5915e7['end']);_0x13e75f['markers']['set'](_0xca33fb,_0x35d42e);}return _0x189c83['sort']((_0x30bc00,_0xa9f051)=>{const _0x1f6880=_0x13e75f['markers']['get']('revision:'+_0x30bc00['id']),_0x57b09d=_0x13e75f['markers']['get']('revision:'+_0xa9f051['id']);return _0x1f6880['start']['isBefore'](_0x57b09d['start'])?-0x1:_0x1f6880['start']['isAfter'](_0x57b09d['start'])?0x1:_0x1f6880['end']['isBefore'](_0x57b09d['end'])?-0x1:_0x1f6880['end']['isAfter'](_0x57b09d['end'])?0x1:'add'===_0x30bc00['type']?-0x1:0x1;}),{'root':_0x13e75f,'changes':_0x189c83};function _0x2fad96(_0x54b073,_0x1e194c,_0x29bd80,_0x43108e){const _0x194dd6=!!_0x3aabf1[_0x1e194c][_0x54b073],_0x12dc48=_0x194dd6?_0x3aabf1[_0x1e194c][_0x54b073]['userId']:null,_0x46a04e=_0x1e194c===_0x3aabf1['length']-0x1,_0x5f0a12=_0x474008[_0x54b073][0x0],_0x51b780=_0x40d3b9['isObject'](_0x3aabf1[_0x1e194c]['item']);!_0x4f3f9d[_0x54b073]&&_0x194dd6?_0x4f3f9d[_0x54b073]={'start':_0x29bd80,'tapeItem':_0x3aabf1[_0x1e194c],'userId':_0x12dc48,'type':_0x54b073}:_0x4f3f9d[_0x54b073]&&!_0x194dd6?(_0x4f3f9d[_0x54b073]['end']=_0x29bd80,_0x3ca689(_0x4f3f9d[_0x54b073]),_0x4f3f9d[_0x54b073]=null):_0x4f3f9d[_0x54b073]&&_0x194dd6&&_0x4f3f9d[_0x54b073]['userId']!==_0x12dc48&&(_0x4f3f9d[_0x54b073]['end']=_0x29bd80,_0x5f0a12&&_0x5f0a12['userId']===_0x4f3f9d[_0x54b073]['userId']||_0x3ca689(_0x4f3f9d[_0x54b073]),_0x4f3f9d[_0x54b073]={'start':_0x29bd80,'tapeItem':_0x3aabf1[_0x1e194c],'userId':_0x12dc48,'type':_0x54b073}),_0x4f3f9d[_0x54b073]&&_0x51b780&&('elementStart'!==_0x3aabf1[_0x1e194c]['type']||_0x5f0a12&&_0x5f0a12['userId']===_0x12dc48||_0x474008[_0x54b073]['unshift']({'userId':_0x12dc48,'object':_0x3aabf1[_0x1e194c]['item'],'change':_0x4f3f9d[_0x54b073]}),'elementEnd'===_0x3aabf1[_0x1e194c]['type']&&_0x5f0a12&&_0x5f0a12['object']===_0x3aabf1[_0x1e194c]['item']&&(_0x474008[_0x54b073]['shift'](),_0x4f3f9d[_0x54b073]=_0x5f0a12['change'])),_0x4f3f9d[_0x54b073]&&_0x46a04e&&(_0x4f3f9d[_0x54b073]['end']=_0x43108e,_0x3ca689(_0x4f3f9d[_0x54b073]),_0x4f3f9d[_0x54b073]=null);}function _0x3ca689({start:_0x633433,end:_0x19a844,tapeItem:_0x14be99,userId:_0x5270f5,type:_0x162a2a}){const _0x380ece=_0x14be99['item'],_0x54f164=_0x36fd24['schema']['isBlock'](_0x380ece)&&!_0x36fd24['schema']['isLimit'](_0x380ece),_0x50a03f=_0x633433['nodeAfter']==_0x19a844['parent']&&_0x19a844['isAtStart'];if(_0x54f164&&_0x50a03f)return;const _0x179217=_0x36fd24['createRange'](_0x633433,_0x19a844),_0xca47c2=_0x38e0bf['get'](_0x5270f5),_0x3f72c5=new r({'author':_0xca47c2,'type':'isAdded'==_0x162a2a||'isAddSuggestion'==_0x162a2a?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x162a2a||'isRemoveSuggestion'==_0x162a2a},'createdAt':new Date(),'rootName':_0x59ac65});_0x189c83['push'](_0x3f72c5),_0x13e75f['markers']['set']('revision:'+_0x3f72c5['id'],_0x179217);}function _0x3ea2b5(_0x5affbb,_0x399556){const _0x3886ae=_0x5affbb['getAttributes'](),_0x4b1269=_0x399556['getAttributes']();for(const _0x3b0558 of _0x3886ae){if(_0x3b0558[0x1]!==_0x399556['getAttribute'](_0x3b0558[0x0]))return!0x1;_0x4b1269['next']();}return _0x4b1269['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x2eca35=>{const _0x56a92e=_0x2eca35['markerName']['split'](':')[0x1],_0x11ba18=this['_getChangeFromId'](_0x56a92e);if(!_0x11ba18)return null;const _0x110ded='add'==_0x11ba18['type']?'insertion':'deletion',_0x5ad387=['ck-suggestion-marker','ck-suggestion-marker-'+_0x110ded];return _0x11ba18['data']['isSuggestion']&&_0x5ad387['push']('ck-suggestion-marker-'+_0x110ded+'-new'),this['activeChange']==_0x11ba18&&_0x5ad387['push']('ck-suggestion-marker--active'),{'classes':_0x5ad387,'attributes':{'data-change-id':_0x56a92e}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x574edb=>{_0x574edb['on']('element:pre',(_0x3f5afe,_0xc1203d,_0x4e2cf7)=>{const _0x545e02=_0xc1203d['viewItem']['getChild'](0x0);if(!_0x545e02||!_0x545e02['is']('element','code'))return;if(!_0x4e2cf7['consumable']['consume'](_0x545e02,{'attributes':['vid_start','vid_end']}))return;const _0x276cde=_0xc1203d['modelRange']['start']['nodeAfter'];_0x4e2cf7['writer']['setAttribute']('vid_start',_0x545e02['getAttribute']('vid_start'),_0x276cde),_0x4e2cf7['writer']['setAttribute']('vid_end',_0x545e02['getAttribute']('vid_end'),_0x276cde);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x45b431=>{_0x45b431['on']('element',(_0x3e57af,_0x5f5392,_0x3851bb)=>{if(!_0x3851bb['consumable']['consume'](_0x5f5392['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x5f5392['modelRange']['isCollapsed'])return;const _0x4c385f=_0x5f5392['modelRange']['start']['nodeAfter'];_0x4c385f['hasAttribute']('vid_start')||_0x4c385f['hasAttribute']('vid')||(_0x3851bb['writer']['setAttribute']('vid_start',_0x5f5392['viewItem']['getAttribute']('vid_start'),_0x4c385f),_0x3851bb['writer']['setAttribute']('vid_end',_0x5f5392['viewItem']['getAttribute']('vid_end'),_0x4c385f));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x336f44=>_0x336f44['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x5aafd1,[,_0x2a65db])=>{['vid_start','vid_end','vid']['includes'](_0x2a65db)&&(_0x5aafd1['return']=!0x0,_0x5aafd1['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x2ab0ab=>{_0x2ab0ab['on']('attribute:vid',(_0x4ae0dc,_0x564e42,_0x355b30)=>{if('\x20'!=_0x564e42['item']['data']||_0x564e42['item']['parent']['maxOffset']>0x1)return;if(!_0x355b30['consumable']['consume'](_0x564e42['item'],_0x4ae0dc['name']))return;const _0x50497a=_0x355b30['writer'],_0x300c92=_0x355b30['mapper']['toViewRange'](_0x564e42['range']);_0x50497a['wrap'](_0x300c92,_0x50497a['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x16f1bd){const _0x45aa1c=_0x16f1bd['plugins']['get']('RevisionViewer');return(_0x2a97d3,_0x46b29b,_0x5da247)=>{const _0x135b34=_0x46b29b['markerName']['split'](':')[0x1],_0x5da7d9=_0x45aa1c['_getChangeFromId'](_0x135b34);if(!_0x5da7d9)return null;const _0x239092='add'==_0x5da7d9['type']?'split':'merge';if(!_0x5da247['consumable']['test'](_0x46b29b['markerRange'],_0x2a97d3['name']))return;const _0x371449=_0x46b29b['markerRange']['getWalker'](),_0x5dec10=_0x46b29b['markerRange']['start'],_0xef9a4f=_0x16f1bd['model']['schema'];let _0x104bad=null,_0x39efe6=null,_0x237632=!0x1,_0x20ce32=!0x1;for(const _0x2dd193 of _0x371449){const _0x41fcdd=_0x2dd193['item'];_0x237632=_0x237632||_0xef9a4f['isContent'](_0x41fcdd);const _0x3b2889=_0x5da247['mapper']['toViewElement'](_0x41fcdd);if(_0x3b2889&&_0x3b2889['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x2dd193['type']&&(_0xef9a4f['isBlock'](_0x41fcdd)&&!_0xef9a4f['isLimit'](_0x41fcdd)&&(_0x41fcdd['nextSibling']||_0x5dec10['isAtEnd']?_0x104bad&&_0x104bad['parent']==_0x41fcdd||(_0x104bad=_0x41fcdd,_0x6b50e4(_0x2dd193['previousPosition']),_0x20ce32=!0x0):_0x39efe6=_0x39efe6||_0x2dd193['previousPosition']));}function _0x6b50e4(_0x596a62){const _0x16a353=_0x5da247['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x239092}),_0x13e7db=_0x5da247['mapper']['toViewPosition'](_0x596a62);_0x5da7d9['data']['isSuggestion']&&_0x5da247['writer']['addClass']('ck-suggestion-marker-'+_0x239092+'-new',_0x16a353),_0x45aa1c['activeChange']==_0x5da7d9&&_0x5da247['writer']['addClass']('ck-suggestion-marker--active',_0x16a353),_0x5da247['writer']['insert'](_0x13e7db,_0x16a353),_0x5da247['mapper']['bindElementToMarker'](_0x16a353,_0x46b29b['markerName']);}_0x237632||_0x20ce32||!_0x39efe6||_0x6b50e4(_0x39efe6);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0x412357,_0x436ec1,_0x306055)=>{const _0x714dfe=_0x306055['mapper']['markerNameToElements'](_0x436ec1['markerName']);if(_0x714dfe){for(const _0xd7ea9c of _0x714dfe)(_0xd7ea9c['hasClass']('ck-suggestion-marker-split')||_0xd7ea9c['hasClass']('ck-suggestion-marker-merge'))&&(_0x306055['mapper']['unbindElementFromMarkerName'](_0xd7ea9c,_0x436ec1['markerName']),_0x306055['writer']['remove'](_0xd7ea9c));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x1b412b,_0x1eece1,_0x156df1)=>{const _0x2e41fe=_0x1eece1['markerName']['split'](':')[0x1],_0x161648=this['_getChangeFromId'](_0x2e41fe);if(!_0x161648)return null;const _0x39e23f='add'==_0x161648['type']?'split':'merge';if(_0x156df1['consumable']['test'](_0x1eece1['markerRange'],_0x1b412b['name']))for(const _0x4d0dc3 of _0x1eece1['markerRange']['getItems']()){if(!_0x4d0dc3['is']('element','softBreak'))continue;const _0x37cca7=_0x156df1['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x39e23f}),_0x41caee=_0x156df1['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x4d0dc3));_0x161648['data']['isSuggestion']&&_0x156df1['writer']['addClass']('ck-suggestion-marker-'+_0x39e23f+'-new',_0x37cca7),this['activeChange']==_0x161648&&_0x156df1['writer']['addClass']('ck-suggestion-marker--active',_0x37cca7),_0x156df1['writer']['insert'](_0x41caee,_0x37cca7),_0x156df1['mapper']['bindElementToMarker'](_0x37cca7,_0x1eece1['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x28df81=>{for(const _0x5ebc7f of this['editor']['model']['document']['getRootNames']()){const _0x126253=this['editor']['model']['document']['getRoot'](_0x5ebc7f),_0x3e8692=this['editor']['editing']['view']['document']['getRoot'](_0x5ebc7f);if(_0x3e8692){const _0x549e28=_0x126253['getAttribute']('revisionHistoryAttachChange');if(_0x28df81['removeAttribute']('data-change-id',_0x3e8692),_0x28df81['removeClass']('ck-revision-history-root-add',_0x3e8692),_0x28df81['removeClass']('ck-revision-history-root-remove',_0x3e8692),_0x28df81['removeClass']('ck-revision-history-root--active',_0x3e8692),_0x549e28){const _0x4f5afc=this['_getChangeFromId'](_0x549e28);if(!_0x4f5afc)return null;_0x28df81['setAttribute']('data-change-id',_0x549e28,_0x3e8692),_0x28df81['addClass']('ck-revision-history-root-'+_0x4f5afc['type'],_0x3e8692),this['activeChange']==_0x4f5afc&&_0x28df81['addClass']('ck-revision-history-root--active',_0x3e8692);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x4b2f64=>'revision-comment:'+_0x4b2f64,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0x735caa=>'revision-suggestion:'+_0x735caa,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x304c32=>({'name':'suggestion:'+_0x304c32,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x3f497e=>{const _0x32c6b8=_0x3f497e['markerName']['split'](':')[0x1];return'insertion'!=_0x32c6b8&&'deletion'!=_0x32c6b8?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x32c6b8]};}}),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',(_0x491e5b,_0x3cd0c8,_0x207283)=>{const _0x4f60a9=_0x207283['mapper']['markerNameToElements'](_0x3cd0c8['markerName']);if(_0x4f60a9){for(const _0x18f5fb of _0x4f60a9)_0x18f5fb['is']('uiElement')&&(_0x207283['mapper']['unbindElementFromMarkerName'](_0x18f5fb,_0x3cd0c8['markerName']),_0x207283['writer']['remove'](_0x18f5fb));}},{'priority':'high'});}['_getChangeFromId'](_0x31c340){return this['_changeIdToChange']['get'](_0x31c340);}['_getViewForChange'](_0x5696ab){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new X(this['editor']['locale'],_0x5696ab),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x5efd69,_0x463109,_0x4874ee,_0xda4e0b)=>{_0xda4e0b&&this['_balloon']['remove'](_0xda4e0b),_0x4874ee&&(this['_balloon']['add']({'view':_0x4874ee,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x12ae7a=this['editor']['editing'],_0x8b742=this['_getChangeFromId'](_0x4874ee['changeId']);let _0x26ea67;if(_0x8b742['data']['isOnRoot']){const _0x1bd75b=_0x12ae7a['view']['getDomRoot'](_0x8b742['rootName']);_0x26ea67=Array['from'](_0x1bd75b['getClientRects']());}else{const _0x2151c6=this['editor']['model']['markers']['get']('revision:'+_0x4874ee['changeId']);_0x26ea67=Array['from'](_0x12ae7a['mapper']['markerNameToElements'](_0x2151c6['name']))['map'](_0x1f83fe=>_0x12ae7a['view']['domConverter']['mapViewToDom'](_0x1f83fe))['map'](_0xdc065a=>Array['from'](_0xdc065a['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x26ea67[0x0];return _0x26ea67['find'](_0x4ad069=>_0x4ad069['top']-0x3<=this['_activeViewTarget']['y']&&_0x4ad069['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x4ad069['left']-0x3<=this['_activeViewTarget']['x']&&_0x4ad069['right']+0x3>=this['_activeViewTarget']['x'])||_0x26ea67[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x10556c,_0x26a587,_0x556243,_0x5e1eae)=>{this['activeView']=_0x556243?this['_getViewForChange'](_0x556243):null,this['editor']['model']['change'](()=>{const _0x3e601c=this['editor']['editing'];_0x5e1eae&&(_0x5e1eae['data']['isOnRoot']?_0x3e601c['view']['change'](_0xe08e59=>{_0xe08e59['removeClass']('ck-revision-history-root--active',_0x3e601c['view']['document']['getRoot'](_0x5e1eae['rootName']));}):_0x3e601c['reconvertMarker']('revision:'+_0x5e1eae['id'])),_0x556243&&(_0x556243['data']['isOnRoot']?_0x3e601c['view']['change'](_0x4c9e79=>{_0x4c9e79['addClass']('ck-revision-history-root--active',_0x3e601c['view']['document']['getRoot'](_0x556243['rootName']));}):_0x3e601c['reconvertMarker']('revision:'+_0x556243['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x1976bf,_0x16bc14)=>{if(this['activeChange'])return;const _0x2aea0d=this['_findChangeIdFromDomTarget'](_0x16bc14['target']),_0x5c9ca7=this['_changeIdToChange']['get'](_0x2aea0d);_0x5c9ca7?(this['_activeViewTarget']={'x':_0x16bc14['domEvent']['x'],'y':_0x16bc14['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x5c9ca7)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x394bd2,_0x429722)=>{const _0x4ba966=this['_findChangeIdFromDomTarget'](_0x429722['target']),_0x1aa761=this['_changeIdToChange']['get'](_0x4ba966);_0x1aa761?(this['_activeViewTarget']={'x':_0x429722['domEvent']['x'],'y':_0x429722['domEvent']['y']},_0x1aa761===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0x1aa761):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x5555bf){do{const _0x23e9ca=_0x5555bf['getAttribute']('data-change-id');if(_0x23e9ca)return _0x23e9ca;_0x5555bf=_0x5555bf['parent'];}while(_0x5555bf);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x3ca236=>{for(const _0x23c01e of this['editor']['model']['markers'])_0x3ca236['removeMarker'](_0x23c01e);});}}function Z(_0x57248a,_0x572ae8){return(_0x3f77e2,_0x487cb5,_0x995c11)=>{if(!_0x995c11['consumable']['test'](_0x487cb5['markerRange'],_0x3f77e2['name']))return;const _0x293d46=_0x487cb5['markerRange']['getWalker'](),_0x100ee4=_0x487cb5['markerRange']['start'],_0x35056f=_0x57248a['model']['schema'];let _0x37e8c2=null,_0x2104f0=null,_0x28a6a4=!0x1,_0x504c8a=!0x1;for(const _0x4444b7 of _0x293d46){const _0x2eda53=_0x4444b7['item'];_0x28a6a4=_0x28a6a4||_0x35056f['isContent'](_0x2eda53);const _0x3c968c=_0x995c11['mapper']['toViewElement'](_0x2eda53);if(_0x3c968c&&_0x3c968c['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x4444b7['type']&&(_0x35056f['isBlock'](_0x2eda53)&&!_0x35056f['isLimit'](_0x2eda53)&&(_0x2eda53['nextSibling']||_0x100ee4['isAtEnd']?_0x37e8c2&&_0x37e8c2['parent']==_0x2eda53||(_0x37e8c2=_0x2eda53,_0x5bef26(_0x4444b7['previousPosition']),_0x504c8a=!0x0):_0x2104f0=_0x2104f0||_0x4444b7['previousPosition']));}function _0x5bef26(_0xfe2044){const _0x2fdcee=_0x995c11['mapper']['toViewPosition'](_0xfe2044),_0x2dae02=_0x995c11['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x572ae8});_0x995c11['writer']['insert'](_0x2fdcee,_0x2dae02),_0x995c11['mapper']['bindElementToMarker'](_0x2dae02,_0x487cb5['markerName']);}_0x28a6a4||_0x504c8a||!_0x2104f0||_0x5bef26(_0x2104f0);};}class _t extends _0x2c1871{constructor(_0x593077){super(_0x593077);const _0x464799=_0x593077['plugins']['get'](d);this['affectsData']=!0x1,this['listenTo'](_0x464799,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x464799,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x12ac0d=this['editor'],_0x3e96ac=_0x12ac0d['plugins']['get'](d),_0x38c89a=_0x3e96ac['isReady']?_0x3e96ac['diff']['newRevisionId']:null;_0x12ac0d['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x38c89a);}['refresh'](){const {isReady:_0x341331,isEnabled:_0x1a59cb,repository:_0x5b415f,diff:_0x4fd072}=this['editor']['plugins']['get'](d),_0x7ca91c=_0x4fd072&&_0x5b415f['getLaterVisibleRevision'](_0x4fd072['newRevisionId']);this['isEnabled']=_0x341331&&_0x1a59cb&&Boolean(_0x7ca91c);}}class yt extends _0x2c1871{['_step'];constructor(_0x38f2f7,{direction:_0x40972f}){super(_0x38f2f7);const _0xfaaab0=_0x38f2f7['plugins']['get'](d);this['affectsData']=!0x1,this['_step']='forward'===_0x40972f?0x1:-0x1,this['listenTo'](_0xfaaab0,'change:isReady',()=>this['refresh']()),this['listenTo'](_0xfaaab0,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0xfaaab0,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x4bd1a2=this['editor'],_0x437adc=_0x4bd1a2['plugins']['get'](d),{isNavigationMode:_0x30911e,currentChangeNumber:_0xcfc8b1}=_0x437adc;let _0x182141;if(_0x437adc['activeChange']=_0x30911e?_0x437adc['diff']['changes']['get'](_0xcfc8b1+this['_step']):_0x437adc['diff']['changes']['first'],_0x437adc['activeChange']['data']['isOnRoot'])_0x182141=_0x4bd1a2['editing']['view']['getDomRoot'](_0x437adc['activeChange']['rootName']);else{const _0x12c8d5=_0x4bd1a2['model']['markers']['get']('revision:'+_0x437adc['activeChange']['id']);_0x182141=_0x48dfde(_0x4bd1a2['editing'],_0x12c8d5);}_0x4a98c9({'target':_0x182141,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x53f61f,currentChangeNumber:_0x50b572,numberOfChanges:_0x33a213,isReady:_0x476683,isEnabled:_0x1419e1}=this['editor']['plugins']['get'](d);this['isEnabled']=!!(_0x1419e1&&_0x476683&&_0x33a213)&&(!_0x53f61f||(0x1===this['_step']?_0x50b572<_0x33a213-0x1:_0x50b572>0x0));}}class _i extends _0x1d6e15{constructor(_0x21ece6){super(_0x21ece6);const _0x24d2ee=this['bindTemplate'],_0x250508=new _0x3cc15e(_0x21ece6),_0x506b6e=new _0x3cc15e(_0x21ece6);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',(_0x395db8,_0x52a465)=>_0x395db8&&_0x52a465>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x5d6214,_0xb7194,_0x5712f1,_0x635975)=>{if(!_0x5d6214)return m(_0x21ece6,'Loading...');if(!_0x5712f1)return m(_0x21ece6,'No\x20changes');const _0xcf4266=m(_0x21ece6,'NUMBER_OF_CHANGES',_0x5712f1);return _0x635975?m(_0x21ece6,'X_OF_Y_CHANGES',[_0xb7194+0x1,_0x5712f1]):_0xcf4266;}),_0x250508['set']({'label':m(_0x21ece6,'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'}),_0x506b6e['set']({'label':m(_0x21ece6,'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'}),_0x250508['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x506b6e['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x250508['on']('execute',()=>this['fire']('execute','backward')),_0x506b6e['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',_0x24d2ee['if']('_isStatusLabelVisible','ck-hidden',_0xeb28e8=>!_0xeb28e8)]},'children':[{'text':_0x24d2ee['to']('isNavigationMode',_0x13302c=>_0x13302c?m(_0x21ece6,'EDIT_X_OF_Y_REVISIONS')+':\x20':m(_0x21ece6,'Total')+':\x20')}]},{'text':_0x24d2ee['to']('_statusText')}]},new _0x2cc299(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x250508,_0x506b6e]}]});}}const ce='ck-editor__editable__loading-overlay';class le extends _0x15974b{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0x316731=this['editor']['editing']['view'];_0x316731['change'](_0x5dce06=>{for(const _0x5cfc8d of _0x316731['document']['roots'])_0x5dce06['addClass'](ce,_0x5cfc8d);});}['hide'](){const _0x16cc9b=this['editor']['editing']['view'];_0x16cc9b['change'](_0x16c7ae=>{for(const _0x37dbb5 of _0x16cc9b['document']['roots'])_0x16c7ae['removeClass'](ce,_0x37dbb5);});}}class g extends _0x15974b{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[d,le];}['init'](){const _0x175aae=this['editor'],_0x148fce=_0x175aae['plugins']['get'](d),_0x1f54c0=_0x175aae['plugins']['get'](le);_0x175aae['ui']['componentFactory']['add']('exitToEditing',_0x4ab9e1=>{const _0xc439af=new _0x3cc15e(_0x4ab9e1);return _0xc439af['set']({'label':m(_0x4ab9e1,'Back\x20to\x20editing'),'icon':_0x470fce['undo'],'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0xc439af,'execute',()=>{_0x175aae['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0xc439af;}),_0x175aae['ui']['componentFactory']['add']('restoreRevision',_0x58f811=>{const _0xf9a738=new _0x3cc15e(_0x58f811);return _0xf9a738['set']({'label':m(_0x58f811,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0xf9a738['bind']('isEnabled')['to'](_0x175aae['commands']['get']('restoreRevision')),this['listenTo'](_0xf9a738,'execute',()=>_0x175aae['execute']('restoreRevision')),_0xf9a738;}),_0x175aae['ui']['componentFactory']['add']('changesNavigation',_0x1d0b83=>{const _0x588a76=new _i(_0x1d0b83),_0x181e88=_0x175aae['commands']['get']('showPreviousChange'),_0x377871=_0x175aae['commands']['get']('showNextChange');return _0x588a76['bind']('isBackwardNavigationEnabled')['to'](_0x181e88,'isEnabled'),_0x588a76['bind']('isForwardNavigationEnabled')['to'](_0x377871,'isEnabled'),_0x588a76['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x148fce),this['listenTo'](_0x588a76,'execute',(_0x19058b,_0x233cf7)=>{_0x175aae['execute']('forward'===_0x233cf7?'showNextChange':'showPreviousChange');}),_0x588a76;}),_0x1f54c0['show'](),_0x148fce['on']('change:isReady',(_0x33864b,_0x1756f5,_0x2aa7cd)=>{_0x2aa7cd?_0x1f54c0['hide']():_0x1f54c0['show']();});}}class pt extends nt{['_resizeObserver']=null;constructor(_0x43c521,_0x330731){super(_0x43c521,_0x330731);const _0xc5368c=this['bindTemplate'];this['set']({'label':m(_0x43c521,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=m(_0x43c521,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0xc5368c['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 _0x151f51=this['fieldView']['element'];this['_tooltipString']=_0x151f51['scrollWidth']>_0x151f51['clientWidth']&&_0x151f51['value']||'';}}class ti extends _0x1d6e15{constructor(_0x2b5798,_0x368198,_0x12ba72){super(_0x2b5798);const _0x401244=new _0x228ef3();_0x401244['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 _0x2d343a=['ck','ck-revision-history-sidebar__revision-author'];_0x12ba72&&_0x2d343a['push']('ck-revision-history-sidebar__revision-author_creator');const _0x30ac2d=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':m(_0x2b5798,_0x12ba72?'Revision\x20creator':'Revision\x20author')},'children':[_0x401244,_0x368198['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x2d343a},'children':_0x30ac2d});}}function ni(_0x539c2c,_0xb7cdd2){const _0x5e0b5d=_0x539c2c['bindTemplate'],_0x55e27f=_0x539c2c['locale'],_0x1af629=_0x3ccc2a(_0x55e27f);_0x1af629['panelPosition']='sw';const _0x49949e=function(_0x2830fb,_0x57d0fa){const _0x24dbec=function(_0x29ed02,_0x42769c){const _0x182172=_0x29ed02['locale'],_0x1e4859={'Compare\x20against\x20selected':m(_0x182172,'Compare\x20against\x20selected'),'Name\x20this\x20revision':m(_0x182172,'Name\x20this\x20revision'),'Restore\x20this\x20revision':m(_0x182172,'Restore\x20this\x20revision')};return _0x42769c['map'](_0x1ea9b2=>{const _0x225ec3=_0x1e4859[_0x1ea9b2['name']];return _0x225ec3&&_0x225ec3!==_0x1ea9b2['name']&&(_0x1ea9b2['name']=_0x225ec3),_0x1ea9b2;});}(_0x2830fb,_0x57d0fa),_0x14786a=new _0x53ab85();for(const _0xd4de59 of _0x24dbec){const _0x492b97={'type':'button','model':new to({'label':_0xd4de59['name'],'class':_0xd4de59['class'],'withText':!0x0,'role':'menuitem','_action':_0xd4de59['action']})};_0x492b97['model']['bind']('isEnabled')['to'](_0x2830fb,'isActionsDropdownOpen',_0x932d1a=>'function'!=typeof _0xd4de59['isEnabled']||(!_0x932d1a||_0xd4de59['isEnabled'](_0x2830fb))),_0x14786a['add'](_0x492b97);}return _0x14786a;}(_0x539c2c,_0xb7cdd2);return _0x539c2c['bind']('isActionsDropdownOpen')['to'](_0x1af629,'isOpen'),_0x1af629['buttonView']['set']({'label':m(_0x55e27f,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x470fce['threeVerticalDots']}),_0x1af629['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x5e0b5d['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x5e0b5d['to'](_0x2a4c39=>_0x2a4c39['stopPropagation']())}}),_0x1af629['on']('execute',_0x32cf93=>{_0x539c2c['isReady']&&'function'==typeof _0x32cf93['source']['_action']&&_0x32cf93['source']['_action'](_0x539c2c);}),_0x22175d(_0x1af629,_0x49949e,{'role':'menu'}),_0x1af629['listenTo'](_0x539c2c,'change:isActionsDropdownOpen',(_0x4061c8,_0x2c4959,_0x578338)=>{if(_0x578338)for(const _0xabeda1 of _0x1af629['listView']['items']){const _0x35b90b=_0xabeda1['children']['first'],_0x20ce15=_0xb7cdd2['find'](_0x445c10=>_0x445c10['action']===_0x35b90b['_action'])['isVisible'];_0xabeda1['isVisible']=void 0x0===_0x20ce15||_0x20ce15(_0x539c2c);}}),_0x1af629;}class ai extends/* #__PURE__ -- @preserve */
26
- _0x29c051(_0x1d6e15){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x1b8b35,_0x5619c6,_0x1381bf,_0x43c77a){super(_0x1b8b35);const _0x2cdf39=this['bindTemplate'],_0x1ad561=function(_0x4e3297,_0x4784dc){const _0x1eeff0=Array['from'](_0x4784dc['authors'])['filter'](_0x29008d=>_0x29008d!=_0x4784dc['creator']);return _0x4784dc['creator']&&_0x1eeff0['unshift'](_0x4784dc['creator']),_0x1eeff0['map'](_0x6a8cc9=>new ti(_0x4e3297,_0x6a8cc9,_0x6a8cc9==_0x4784dc['creator']));}(_0x1b8b35,_0x5619c6);this['id']=_0x5619c6['id'],this['_revision']=_0x5619c6,this['_requireRevisionName']=_0x43c77a,this['bind']('name','createdAt')['to'](_0x5619c6),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x5dd997=>{return _0x4a25bc=_0x1b8b35['uiLanguage'],(_0x56f05e=_0x5dd997)['toLocaleDateString'](_0x4a25bc,{'month':'long','day':'numeric'})+',\x20'+_0x56f05e['toLocaleTimeString'](_0x4a25bc,{'hour':'numeric','minute':'numeric'});var _0x4a25bc,_0x56f05e;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new pt(_0x1b8b35,_0x5d5d36),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x26f07c=>_0x26f07c||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x471719,_0x5b2837)=>_0x471719&&_0x5b2837),this['revisionActionsView']=_0x1381bf&&_0x1381bf['length']?ni(this,_0x1381bf):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x2cdf39['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x2cdf39['if']('isEnabled','ck-disabled',_0x466a90=>!_0x466a90),_0x2cdf39['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x2cdf39['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x2cdf39['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':_0x2cdf39['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':_0x1ad561}]},this['revisionActionsView']],'on':{'click':_0x2cdf39['to'](_0x729e74=>{_0x729e74['srcElement']['closest']('.ck-thread__remove-confirm')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x5285e9=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x5285e9,'change',()=>{this['_requireRevisionName']&&!_0x5285e9['value']||this['fire']('setName',{'id':this['id'],'name':_0x5285e9['value']}),_0x5285e9['value']||(_0x5285e9['value']=this['name']?this['name']:this['_createdAtFormatted']);});}['select'](){this['isSelected']=!0x0;}['deselect'](){this['isSelected']=!0x1;}['highlight'](){this['isHighlighted']=!0x0;}['unhighlight'](){this['isHighlighted']=!0x1;}}function di(_0xf83481,_0x2769c6){const _0x2158db=_0x343446['fromJSDate'](_0xf83481)['setLocale'](_0x2769c6),_0xb600df=_0x343446['local'](),_0x470423=_0xb600df['minus']({'days':0x1})['startOf']('day');let _0x426424,_0x5dd409;return _0x2158db['hasSame'](_0xb600df,'day')?(_0x426424=_0x2158db['startOf']('day')['toJSDate'](),_0x5dd409=_0x2158db['toRelativeCalendar']()):_0x2158db['hasSame'](_0x470423,'day')?(_0x426424=_0x470423['toJSDate'](),_0x5dd409=_0x2158db['toRelativeCalendar']()):_0x2158db['hasSame'](_0xb600df,'week')?(_0x426424=_0x2158db['startOf']('week')['toJSDate'](),_0x5dd409=_0x2158db['weekdayLong']||''):_0x2158db['hasSame'](_0xb600df,'year')?(_0x426424=_0x2158db['startOf']('month')['toJSDate'](),_0x5dd409=_0x2158db['monthLong']||''):(_0x426424=_0x2158db['startOf']('year')['toJSDate'](),_0x5dd409=String(_0x2158db['year'])),{'startDate':_0x426424,'localizedPeriodName':_0x5dd409};}class mi extends _0x1d6e15{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x12c934,_0x1c9d8c,_0x5c69a5,_0x3343b5){super(_0x12c934);const _0x23d02e=di(_0x1c9d8c,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x1c9d8c,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x5c69a5,this['_requireRevisionName']=_0x3343b5,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':_0x23d02e}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x3d7819){const _0x38ec9f=new ai(this['locale'],_0x3d7819,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x38ec9f);}['removeRevision'](_0x5c2fc8){const _0x39808e=this['revisionViews']['find'](_0x51c626=>_0x51c626['id']===_0x5c2fc8['id']);this['revisionViews']['remove'](_0x39808e);}}class as extends _0x1d6e15{constructor(_0x5a707e){super(_0x5a707e);const _0x13d638=new _0x228ef3();_0x13d638['content']=_0x470fce['history'],this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x13d638,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[m(_0x5a707e,'Revision\x20history')]}]});}}class ci extends _0x1d6e15{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x1a3d6a,_0x5148b8,_0x5e3cb6,_0x2d67b6){super(_0x1a3d6a);const _0x432eb2=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x5148b8,this['_revisionActions']=_0x5e3cb6,this['_requireRevisionName']=_0x2d67b6,this['on']('select',(_0x42491c,_0x5dfe56)=>{this['fire']('revisionSelected',_0x5dfe56);}),this['on']('setName',(_0x37b784,_0x129f0d)=>{this['fire']('revisionSetName',_0x129f0d);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new as(_0x1a3d6a),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x432eb2['if']('isEnabled','ck-disabled',_0x410eed=>!_0x410eed)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x1e15b5 of this['_revisions'])this['_addRevision'](_0x1e15b5);this['_revisions']['on']('add',(_0x3b113e,_0x16f6c4)=>{this['_addRevision'](_0x16f6c4);}),this['_revisions']['on']('remove',(_0x42df84,_0x32a932)=>{this['_removeRevision'](_0x32a932);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x3000cf=>_0x3000cf['revisionViews']['map'](_0x500617=>_0x500617))['flat']();}['selectRevision'](_0x10aba0){for(const _0x1061de of this['revisionViews'])_0x10aba0&&_0x10aba0['id']===_0x1061de['id']?_0x1061de['select']():_0x1061de['deselect']();}['highlightRevisions'](_0x432bae){for(const _0x26f18e of this['revisionViews'])_0x432bae['some'](({id:_0x139537})=>_0x139537===_0x26f18e['id'])?_0x26f18e['highlight']():_0x26f18e['unhighlight']();}['_addRevision'](_0x1f2982){const _0x54c63c=di(_0x1f2982['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x539619=this['timePeriodViews']['get'](0x0);_0x539619&&_0x539619['startDate']['getTime']()===_0x54c63c['getTime']()||(_0x539619=new mi(this['locale'],_0x54c63c,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x539619)),_0x539619['addRevision'](_0x1f2982);}['_removeRevision'](_0x1748a5){const _0x5a4ce4=di(_0x1748a5['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x5a4ce4)['removeRevision'](_0x1748a5);}['_getTimePeriodViewByStartDate'](_0x52763d){return this['timePeriodViews']['find'](_0xc5557=>_0xc5557['startDate']['getTime']()===_0x52763d['getTime']());}}class w extends _0x15974b{['_revisionViewer'];['_revisionsRepository'];['_sidebarView'];static ['defaultRevisionActions']=/* #__PURE__ -- @preserve */
23
+ import{ObservableMixin as _0x45caf0,uid as _0x118080,Collection as _0x3e452a,logWarning as _0x26aa91,FocusTracker as _0x2ebb35,KeystrokeHandler as _0x5c3c3a,scrollViewportToShowTarget as _0x498fcc,ResizeObserver as at,ElementReplacer as ht,CKEditorError as _0x1a0978}from'@ckeditor/ckeditor5-utils/dist/index.js';import{cloneDeep as _0x127b89,set as _0x22930c,unset as _0x51fe73,isEqual as _0x1ff0ec}from'es-toolkit/compat';import{Plugin as _0x118fc5,PendingActions as _0x16589e,Command as _0x969d2d,ElementApiMixin as it,Editor as tt}from'@ckeditor/ckeditor5-core/dist/index.js';import{Users as _0x1120ef,getMarkerDomElement as _0x25477c,ConfirmMixin as ti,sanitizeEditorConfig as _0x259f0a}from'ckeditor5-collaboration/dist/index.js';import{ViewDocumentFragment as _0x8157a,Element as ut,Range as ft,ViewUIElement as _0x28565d,ViewRawElement as _0xd3a339,ViewEmptyElement as _0x5d757a,ViewAttributeElement as _0x51cef1,ViewContainerElement as _0x536437,Position as vt,ViewText as _0x1b404c,ViewElement as _0x34db6a,DocumentFragment as gt,Text as mt}from'@ckeditor/ckeditor5-engine/dist/index.js';import{IconHistory as _0x4709ad,IconChevronUp as _0x1fd3a6,IconChevronDown as _0x27dfe9,IconUndo as _0x5ec5f7,IconUser as _0x1c5cb8,IconThreeVerticalDots as _0x3cf2be}from'@ckeditor/ckeditor5-icons/dist/index.js';import{View as ts,injectCssTransitionDisabler as _0x25c145,submitHandler as _0x4c2b40,LabeledFieldView as _0x3f0de8,createLabeledInputText as _0x153297,createDropdown as _0x243ed3,ListView as _0x2ac408,ListItemView as _0x1f298a,ButtonView as te,MenuBarMenuView as _0x361888,MenuBarMenuListView as _0xb5534c,MenuBarMenuListItemView as _0x11fa25,MenuBarMenuListItemButtonView as _0x5d5452,ContextualBalloon as _0x608ef,ToolbarSeparatorView as _0x5bb69f,IconView as _0x1f0c9d,addListToDropdown as _0x370af3,ViewModel as to,EditorUI as st,normalizeToolbarConfig as ot,BoxedEditorUIView as ct,StickyPanelView as lt,ToolbarView as nt,InlineEditableUIView as dt}from'@ckeditor/ckeditor5-ui/dist/index.js';import{DateTime as _0x140512}from'luxon';class h extends/* #__PURE__ -- @preserve */
24
+ _0x45caf0(){['id'];['creator'];['authors'];['diffData'];['toVersion'];['fromVersion'];['model'];constructor(_0x5c4564){super(),this['id']=_0x5c4564['id']||_0x118080(),this['creator']=_0x5c4564['creator']||null,this['authors']=_0x5c4564['authors']||[],this['diffData']=_0x5c4564['diffData']||null,this['toVersion']=_0x5c4564['toVersion']||0x0,this['fromVersion']=_0x5c4564['fromVersion']||0x0,this['set']('name',_0x5c4564['name']||''),this['set']('createdAt',_0x5c4564['createdAt']||new Date()),this['set']('attributes',_0x5c4564['attributes']||{});}['setName'](_0x2a4f32){this['_update']({'name':_0x2a4f32});}['setAttribute'](_0x3694dc,_0x3485c1){const _0x2b8aca=_0x127b89(this['attributes']);_0x22930c(_0x2b8aca,_0x3694dc,_0x3485c1),this['_update']({'attributes':_0x2b8aca});}['removeAttribute'](_0x5b5cf1){const _0x345a09=_0x127b89(this['attributes']);_0x51fe73(_0x345a09,_0x5b5cf1),this['_update']({'attributes':_0x345a09});}['_update'](_0x4bab03,_0x2632e1=!0x1){let _0x3c6306=!0x1;const _0x135a71={'id':this['id']},_0x5b24ea=['name','createdAt','diffData','authors','attributes','toVersion','fromVersion','creatorId'];for(const _0x2b3897 of _0x5b24ea){const _0xf62287=_0x4bab03[_0x2b3897];void 0x0!==_0xf62287&&_0xf62287!==this[_0x2b3897]&&(this[_0x2b3897]=_0xf62287,_0x135a71[_0x2b3897]=_0xf62287,_0x3c6306=!0x0);}_0x3c6306&&(_0x135a71['authors']&&(_0x135a71['authorsIds']=_0x135a71['authors']['map'](_0x472f22=>_0x472f22['id']),delete _0x135a71['authors']),this['fire']('_update',_0x135a71,_0x2632e1));}['toJSON'](){return{'id':this['id'],'name':this['name'],'creatorId':this['creator']?this['creator']['id']:null,'authorsIds':this['authors']['map'](_0x4702ea=>_0x4702ea['id']),'diffData':this['diffData'],'createdAt':this['createdAt'],'attributes':this['attributes'],'fromVersion':this['fromVersion'],'toVersion':this['toVersion']};}}class j extends _0x118fc5{['_revisions'];static get['requires'](){return[_0x1120ef];}static get['pluginName'](){return'RevisionsRepository';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}get['length'](){return this['_revisions']['length'];}constructor(_0x412f4f){super(_0x412f4f),this['_revisions']=new _0x3e452a();}['afterInit'](){!async function(_0x35a945){const _0x2e9df8=_0x317079([0x34,0x51,0x41,0x33,0x79,0x77,0x36,0x31,0x5a,0x61,0x30,0x6b,0x64,0x6d,0x62,0x63,0x6a,0x76,0x59,0x4b,0x69,0x74,0x4c,0x57,0x75,0x49,0x45,0x4a,0x71,0x65,0x46,0x32,0x50,0x6c,0x72,0x53,0x6e,0x73,0x4d,0x35,0x44,0x42,0x6f,0x48,0x37,0x67,0x56,0x78,0x4f,0x66,0x58,0x68,0x47,0x70,0x54,0x55,0x43,0x4e,0x38,0x7a,0x52,0x39]),_0x27e13d=0xeb829,_0x45f9e6=0x3ad40895,_0x3c29db=0x3ad3686d^_0x45f9e6,_0x237b17=window[_0x317079([0x44,0x61,0x74,0x65])][_0x317079([0x6e,0x6f,0x77])](),_0x48adfb=_0x35a945[_0x317079([0x65,0x64,0x69,0x74,0x6f,0x72])],_0x479169=new window[(_0x317079([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x3b51f4=>{_0x48adfb[_0x317079([0x6f,0x6e,0x63,0x65])](_0x317079([0x72,0x65,0x61,0x64,0x79]),_0x3b51f4);}),_0x1ea8e8={[_0x317079([0x6b,0x74,0x79])]:_0x317079([0x45,0x43]),[_0x317079([0x75,0x73,0x65])]:_0x317079([0x73,0x69,0x67]),[_0x317079([0x63,0x72,0x76])]:_0x317079([0x50,0x2d,0x32,0x35,0x36]),[_0x317079([0x78])]:_0x317079([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]),[_0x317079([0x79])]:_0x317079([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]),[_0x317079([0x61,0x6c,0x67])]:_0x317079([0x45,0x53,0x32,0x35,0x36])},_0x5126d2=_0x48adfb[_0x317079([0x63,0x6f,0x6e,0x66,0x69,0x67])][_0x317079([0x67,0x65,0x74])](_0x317079([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x4b,0x65,0x79]));async function _0x442e35(){let _0x407266,_0x23be09=null,_0x7eca8c=null;try{if(_0x5126d2==_0x317079([0x47,0x50,0x4c]))return _0x317079([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]);if(_0x407266=_0x2c0d8e(),!_0x407266)return _0x317079([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);return _0x407266[_0x317079([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])]&&(_0x7eca8c=_0x4c8ff3(_0x407266[_0x317079([0x75,0x73,0x61,0x67,0x65,0x45,0x6e,0x64,0x70,0x6f,0x69,0x6e,0x74])],_0x407266[_0x317079([0x6a,0x74,0x69])])),await _0x27dfb2()?_0x5d2e6b()?_0x59919b()?_0x317079([0x45,0x78,0x70,0x69,0x72,0x65,0x64]):_0x43f2d3()?(_0x407266[_0x317079([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x317079([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e])&&(_0x23be09=_0x61c6a2(_0x317079([0x45,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e,0x4c,0x69,0x6d,0x69,0x74]))),_0x407266[_0x317079([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])]==_0x317079([0x74,0x72,0x69,0x61,0x6c])&&(_0x23be09=_0x61c6a2(_0x317079([0x54,0x72,0x69,0x61,0x6c,0x4c,0x69,0x6d,0x69,0x74]))),await _0x1a0167()):_0x317079([0x44,0x6f,0x6d,0x61,0x69,0x6e,0x4c,0x69,0x6d,0x69,0x74]):_0x317079([0x4e,0x6f,0x74,0x41,0x6c,0x6c,0x6f,0x77,0x65,0x64]):_0x317079([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}catch(_0x3612d9){return _0x317079([0x49,0x6e,0x76,0x61,0x6c,0x69,0x64]);}function _0x59919b(){const _0xd91260=[_0x317079([0x65,0x76,0x61,0x6c,0x75,0x61,0x74,0x69,0x6f,0x6e]),_0x317079([0x74,0x72,0x69,0x61,0x6c])][_0x317079([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x407266[_0x317079([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x54,0x79,0x70,0x65])])?_0x237b17/0x3e8:0xe10*_0x3c29db;return _0x407266[_0x317079([0x65,0x78,0x70])]<_0xd91260;}function _0x5d2e6b(){const _0x3c4a0d=_0x407266[_0x317079([0x66,0x65,0x61,0x74,0x75,0x72,0x65,0x73])];if(!_0x3c4a0d)return!0x1;if(_0x3c4a0d[_0x317079([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x317079([0x2a])))return!0x0;if(_0x3c4a0d[_0x317079([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x317079([0x52,0x48])))return!0x0;if(_0x3c4a0d[_0x317079([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x317079([0x52,0x52,0x48]))){if(_0x3a604e())return!0x0;if(_0x884586()||_0x11bcff())return!0x0;}return!0x1;}function _0x43f2d3(){const _0x576ed2=_0x407266[_0x317079([0x6c,0x69,0x63,0x65,0x6e,0x73,0x65,0x64,0x48,0x6f,0x73,0x74,0x73])];if(!_0x576ed2||0x0==_0x576ed2[_0x317079([0x6c,0x65,0x6e,0x67,0x74,0x68])])return!0x0;const {hostname:_0x57255c}=new URL(window[_0x317079([0x6c,0x6f,0x63,0x61,0x74,0x69,0x6f,0x6e])]['href']);if(_0x576ed2[_0x317079([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x57255c))return!0x0;const _0x3cee48=_0x57255c[_0x317079([0x73,0x70,0x6c,0x69,0x74])](_0x317079([0x2e]));return _0x576ed2[_0x317079([0x66,0x69,0x6c,0x74,0x65,0x72])](_0x393348=>_0x393348[_0x317079([0x69,0x6e,0x63,0x6c,0x75,0x64,0x65,0x73])](_0x317079([0x2a])))[_0x317079([0x6d,0x61,0x70])](_0x291b65=>_0x291b65[_0x317079([0x73,0x70,0x6c,0x69,0x74])](_0x317079([0x2e])))[_0x317079([0x73,0x6f,0x6d,0x65])](_0x3c46a6=>_0x3cee48[_0x317079([0x65,0x76,0x65,0x72,0x79])]((_0x471516,_0x2ace8b)=>_0x3c46a6[_0x2ace8b]===_0x471516||_0x3c46a6[_0x2ace8b]===_0x317079([0x2a])));}function _0x1a0167(){return _0x23be09&&_0x7eca8c?new window[(_0x317079([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x6cbd7f,_0x2bac67)=>{_0x23be09[_0x317079([0x74,0x68,0x65,0x6e])](_0x6cbd7f,_0x2bac67),_0x7eca8c[_0x317079([0x74,0x68,0x65,0x6e])](_0x212186=>{_0x212186!=_0x317079([0x56,0x61,0x6c,0x69,0x64])&&_0x6cbd7f(_0x212186);},_0x2bac67);}):_0x23be09||_0x7eca8c||_0x317079([0x56,0x61,0x6c,0x69,0x64]);}}function _0x4c8ff3(_0x4acccd,_0x18f844){return new window[(_0x317079([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x5e6331=>{if(_0x302df())return _0x5e6331(_0x317079([0x56,0x61,0x6c,0x69,0x64]));_0x3906a2(),_0x48adfb[_0x317079([0x64,0x65,0x63,0x6f,0x72,0x61,0x74,0x65])](_0x317079([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]));let _0x4b9a7c=!0x1;const _0x433093=_0x118080();function _0xc880fc(_0x4bf335){return!!_0x4bf335&&(typeof _0x4bf335===_0x317079([0x6f,0x62,0x6a,0x65,0x63,0x74])||typeof _0x4bf335===_0x317079([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]))&&typeof _0x4bf335[_0x317079([0x74,0x68,0x65,0x6e])]===_0x317079([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e])&&typeof _0x4bf335[_0x317079([0x63,0x61,0x74,0x63,0x68])]===_0x317079([0x66,0x75,0x6e,0x63,0x74,0x69,0x6f,0x6e]);}function _0x2e62fc(_0x107420){_0x413110(_0x107420)[_0x317079([0x74,0x68,0x65,0x6e])](_0x10df42=>{if(!_0x10df42||_0x10df42[_0x317079([0x73,0x74,0x61,0x74,0x75,0x73])]!=_0x317079([0x6f,0x6b]))return _0x317079([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]);return _0x589585(_0x1704d4(_0x433093+_0x18f844))!=_0x10df42[_0x317079([0x76,0x65,0x72,0x69,0x66,0x69,0x63,0x61,0x74,0x69,0x6f,0x6e])]?_0x317079([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]):_0x317079([0x56,0x61,0x6c,0x69,0x64]);})[_0x317079([0x74,0x68,0x65,0x6e])](_0x98183e=>(_0x1c90ee(),_0x98183e),()=>{const _0x389c97=_0x8674b2();return null==_0x389c97?(_0x1c90ee(),_0x317079([0x56,0x61,0x6c,0x69,0x64])):_0x317079(_0x237b17-_0x389c97>(0x1ed88c95^_0x45f9e6)?[0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]:[0x56,0x61,0x6c,0x69,0x64]);})[_0x317079([0x74,0x68,0x65,0x6e])](_0x5e6331)[_0x317079([0x63,0x61,0x74,0x63,0x68])](()=>{_0x5e6331(_0x317079([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});const _0x2b8f78=0x3ae2e615^_0x45f9e6;function _0x1c90ee(){const _0x15c682=_0x317079([0x6c,0x6c,0x63,0x74,0x2d])+_0x589585(_0x1704d4(_0x4acccd)),_0x4ee13b=_0x2ace32(_0x589585(window[_0x317079([0x4d,0x61,0x74,0x68])][_0x317079([0x63,0x65,0x69,0x6c])](_0x237b17/_0x2b8f78)));window[_0x317079([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x317079([0x73,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x15c682,_0x4ee13b);}function _0x8674b2(){const _0x5a8244=_0x317079([0x6c,0x6c,0x63,0x74,0x2d])+_0x589585(_0x1704d4(_0x4acccd)),_0x9cf74a=window[_0x317079([0x6c,0x6f,0x63,0x61,0x6c,0x53,0x74,0x6f,0x72,0x61,0x67,0x65])][_0x317079([0x67,0x65,0x74,0x49,0x74,0x65,0x6d])](_0x5a8244);return _0x9cf74a?window[_0x317079([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x2ace32(_0x9cf74a),0x10)*_0x2b8f78:null;}function _0x413110(_0x449d48){return new window[(_0x317079([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))]((_0x3a4e9d,_0x423122)=>{_0x449d48[_0x317079([0x74,0x68,0x65,0x6e])](_0x3a4e9d,_0x423122),window[_0x317079([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x423122,0x3ad5dc55^_0x45f9e6);});}}_0x48adfb[_0x317079([0x6f,0x6e])](_0x317079([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),(_0x482dd8,_0x1ad21c)=>{if(_0x1ad21c[0x0]!=_0x4acccd)return _0x5e6331(_0x317079([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));_0x1ad21c[0x1]={..._0x1ad21c[0x1],[_0x317079([0x72,0x65,0x71,0x75,0x65,0x73,0x74,0x49,0x64])]:_0x433093};},{[_0x317079([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x317079([0x68,0x69,0x67,0x68])}),_0x48adfb[_0x317079([0x6f,0x6e])](_0x317079([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74]),_0x1fb480=>{_0xc880fc(_0x1fb480[_0x317079([0x72,0x65,0x74,0x75,0x72,0x6e])])&&(_0x4b9a7c=!0x0,_0x2e62fc(_0x1fb480[_0x317079([0x72,0x65,0x74,0x75,0x72,0x6e])]));},{[_0x317079([0x70,0x72,0x69,0x6f,0x72,0x69,0x74,0x79])]:_0x317079([0x6c,0x6f,0x77])}),_0x479169[_0x317079([0x74,0x68,0x65,0x6e])](()=>{_0x4b9a7c||_0x5e6331(_0x317079([0x55,0x73,0x61,0x67,0x65,0x4c,0x69,0x6d,0x69,0x74]));});});function _0x302df(){return _0x48adfb[_0x317079([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x317079([0x76,0x69,0x65,0x77])][_0x317079([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]==_0x317079([0x61,0x75,0x74,0x6f]);}function _0x3906a2(){_0x48adfb[_0x317079([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x317079([0x76,0x69,0x65,0x77])][_0x317079([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x317079([0x61,0x75,0x74,0x6f]);}}function _0x61c6a2(_0x5b5137){const _0x2cc94f=[new window[(_0x317079([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x1c404b=>setTimeout(_0x1c404b,0x3add3659^_0x45f9e6)),_0x479169[_0x317079([0x74,0x68,0x65,0x6e])](()=>new window[(_0x317079([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x2edec0=>{const _0x190407=0x3ad40892^_0x45f9e6,_0x5cc1ee=_0x35a945[_0x317079([0x5f,0x72,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x73])];function _0x143f16(){_0x5cc1ee[_0x317079([0x6c,0x65,0x6e,0x67,0x74,0x68])]>=_0x190407&&_0x2edec0();}_0x143f16(),_0x5cc1ee[_0x317079([0x6f,0x6e])](_0x317079([0x61,0x64,0x64]),_0x143f16);})),new window[(_0x317079([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65]))](_0x181237=>{function _0x158cac(){for(const _0x39a604 in window)if(window[_0x317079([0x4e,0x75,0x6d,0x62,0x65,0x72])]['isNaN'](window[_0x317079([0x4e,0x75,0x6d,0x62,0x65,0x72])](_0x39a604))&&window[_0x39a604]==_0x27e13d)return _0x181237();_0x48adfb[_0x317079([0x73,0x74,0x61,0x74,0x65])]!=_0x317079([0x64,0x65,0x73,0x74,0x72,0x6f,0x79,0x65,0x64])&&window[_0x317079([0x73,0x65,0x74,0x54,0x69,0x6d,0x65,0x6f,0x75,0x74])](_0x158cac,0x3ad41b1d^_0x45f9e6);}_0x5cc82(_0x317079([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))&&_0x158cac();})];return window[_0x317079([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x317079([0x72,0x61,0x63,0x65])](_0x2cc94f)[_0x317079([0x74,0x68,0x65,0x6e])](()=>_0x5b5137);}async function _0x4c87c9(){if(await _0x479169,_0x5cc82(_0x317079([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]))){const _0x59a1aa=_0x35a945[_0x317079([0x67,0x65,0x74,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])](0x0),_0x144253=_0x35a945[_0x317079([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])](_0x59a1aa[_0x317079([0x69,0x64])]),_0x1bfa93=_0x256b32(_0x317079([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x56,0x69,0x65,0x77,0x65,0x72]));return await _0x1bfa93[_0x317079([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])](_0x59a1aa['id'],_0x144253?_0x144253['id']:null,!0x0),_0x1bfa93[_0x317079([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x317079([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x1bfa93[_0x317079([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x1bfa93[_0x317079([0x63,0x6f,0x6d,0x70,0x61,0x72,0x65])]=_0x544f43,void(_0x1bfa93[_0x317079([0x5f,0x67,0x65,0x74,0x44,0x69,0x66,0x66])]=_0x544f43);}if(_0x5cc82(_0x317079([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]))){const _0x23aee5=_0x256b32(_0x317079([0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e,0x54,0x72,0x61,0x63,0x6b,0x65,0x72]));_0x23aee5[_0x317079([0x75,0x6e,0x62,0x69,0x6e,0x64])](_0x317079([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])),_0x23aee5[_0x317079([0x69,0x73,0x45,0x6e,0x61,0x62,0x6c,0x65,0x64])]=!0x1,_0x23aee5[_0x317079([0x75,0x70,0x64,0x61,0x74,0x65])]=_0x544f43,_0x23aee5[_0x317079([0x73,0x61,0x76,0x65,0x52,0x65,0x76,0x69,0x73,0x69,0x6f,0x6e])]=_0x544f43;}_0x48adfb[_0x317079([0x6d,0x6f,0x64,0x65,0x6c])][_0x317079([0x63,0x68,0x61,0x6e,0x67,0x65])]=_0x544f43,_0x48adfb[_0x317079([0x6d,0x6f,0x64,0x65,0x6c])][_0x317079([0x65,0x6e,0x71,0x75,0x65,0x75,0x65,0x43,0x68,0x61,0x6e,0x67,0x65])]=_0x544f43,_0x48adfb[_0x317079([0x65,0x6e,0x61,0x62,0x6c,0x65,0x52,0x65,0x61,0x64,0x4f,0x6e,0x6c,0x79,0x4d,0x6f,0x64,0x65])](_0x317079([0x6d,0x6f,0x64,0x65,0x6c]));}function _0x3a604e(){return _0x5cc82(_0x317079([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))&&_0x256b32(_0x317079([0x57,0x65,0x62,0x53,0x6f,0x63,0x6b,0x65,0x74,0x47,0x61,0x74,0x65,0x77,0x61,0x79]))[_0x317079([0x73,0x74,0x61,0x74,0x65])]==_0x317079([0x63,0x6f,0x6e,0x6e,0x65,0x63,0x74,0x65,0x64]);}function _0x884586(){return _0x5cc82(_0x317079([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 _0x11bcff(){return _0x5cc82(_0x317079([0x54,0x72,0x61,0x63,0x6b,0x43,0x68,0x61,0x6e,0x67,0x65,0x73,0x44,0x61,0x74,0x61,0x47,0x65,0x74,0x74,0x65,0x72]));}function _0x1fcd6b(_0x2992ed){const _0x2978e0=_0x4b1be9();_0x48adfb[_0x2978e0]=_0x317079([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])+_0x2992ed,_0x2992ed[_0x317079([0x65,0x6e,0x64,0x73,0x57,0x69,0x74,0x68])](_0x317079([0x4c,0x69,0x6d,0x69,0x74]))&&(window[_0x4b1be9()]=_0x27e13d),_0x2992ed!=_0x317079([0x56,0x61,0x6c,0x69,0x64])&&_0x4c87c9();}function _0x4b1be9(){const _0x25f192=window[_0x317079([0x53,0x74,0x72,0x69,0x6e,0x67])](window[_0x317079([0x70,0x65,0x72,0x66,0x6f,0x72,0x6d,0x61,0x6e,0x63,0x65])][_0x317079([0x6e,0x6f,0x77])]())[_0x317079([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](_0x317079([0x2e]),'');let _0x3ae976=_0x317079([0x51]);for(let _0xe4d890=0x0;_0xe4d890<_0x25f192[_0x317079([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0xe4d890+=0x2){let _0x3c81cb=window[_0x317079([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x25f192[_0x317079([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0xe4d890,_0xe4d890+0x2));_0x3c81cb>=_0x2e9df8[_0x317079([0x6c,0x65,0x6e,0x67,0x74,0x68])]&&(_0x3c81cb-=_0x2e9df8[_0x317079([0x6c,0x65,0x6e,0x67,0x74,0x68])]),_0x3ae976+=_0x2e9df8[_0x3c81cb];}return _0x3ae976;}function _0x2c0d8e(){const _0xf6d8cd=_0x5126d2[_0x317079([0x73,0x70,0x6c,0x69,0x74])](_0x317079([0x2e]));if(0x3!=_0xf6d8cd[_0x317079([0x6c,0x65,0x6e,0x67,0x74,0x68])])return null;return _0x5b3b16(_0xf6d8cd[0x1]);function _0x5b3b16(_0x4695ee){const _0x4fb653=_0x31bc99(_0x4695ee);return _0x4fb653&&_0x8812e()?_0x4fb653:null;function _0x8812e(){const _0x570ea5=_0x4fb653[_0x317079([0x6a,0x74,0x69])],_0x2e6351=window[_0x317079([0x70,0x61,0x72,0x73,0x65,0x49,0x6e,0x74])](_0x570ea5[_0x317079([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](_0x570ea5[_0x317079([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8),0x10),_0xa9dc5e={..._0x4fb653,[_0x317079([0x6a,0x74,0x69])]:_0x570ea5[_0x317079([0x73,0x75,0x62,0x73,0x74,0x72,0x69,0x6e,0x67])](0x0,_0x570ea5[_0x317079([0x6c,0x65,0x6e,0x67,0x74,0x68])]-0x8)};return delete _0xa9dc5e[_0x317079([0x76,0x63])],_0x1704d4(_0xa9dc5e)==_0x2e6351;}}}async function _0x27dfb2(){let _0xc0ca62=!0x0;try{const _0x5dc37d=_0x5126d2[_0x317079([0x73,0x70,0x6c,0x69,0x74])](_0x317079([0x2e])),[_0x30ac72,_0x35cd5e,_0x362fc2]=_0x5dc37d;return _0x14df3b(_0x30ac72),await _0x4ff37d(_0x30ac72,_0x35cd5e,_0x362fc2),_0xc0ca62;}catch(_0x59c471){return!0x1;}function _0x14df3b(_0x46a3d0){const _0x502a69=_0x31bc99(_0x46a3d0);_0x502a69&&_0x502a69[_0x317079([0x61,0x6c,0x67])]==_0x317079([0x45,0x53,0x32,0x35,0x36])||(_0xc0ca62=!0x1);}async function _0x4ff37d(_0x4d1843,_0x255539,_0x19aeab){const _0x2a627d=window[_0x317079([0x55,0x69,0x6e,0x74,0x38,0x41,0x72,0x72,0x61,0x79])][_0x317079([0x66,0x72,0x6f,0x6d])](_0x126af4(_0x19aeab),_0x4e7414=>_0x4e7414[_0x317079([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](0x0)),_0x96a00d=new window[(_0x317079([0x54,0x65,0x78,0x74,0x45,0x6e,0x63,0x6f,0x64,0x65,0x72]))]()[_0x317079([0x65,0x6e,0x63,0x6f,0x64,0x65])](_0x4d1843+_0x317079([0x2e])+_0x255539),_0x1048a8=window[_0x317079([0x63,0x72,0x79,0x70,0x74,0x6f])][_0x317079([0x73,0x75,0x62,0x74,0x6c,0x65])];if(!_0x1048a8)return;const _0x562cd6=await _0x1048a8[_0x317079([0x69,0x6d,0x70,0x6f,0x72,0x74,0x4b,0x65,0x79])](_0x317079([0x6a,0x77,0x6b]),_0x1ea8e8,{[_0x317079([0x6e,0x61,0x6d,0x65])]:_0x317079([0x45,0x43,0x44,0x53,0x41]),[_0x317079([0x6e,0x61,0x6d,0x65,0x64,0x43,0x75,0x72,0x76,0x65])]:_0x317079([0x50,0x2d,0x32,0x35,0x36])},!0x1,[_0x317079([0x76,0x65,0x72,0x69,0x66,0x79])]);await _0x1048a8[_0x317079([0x76,0x65,0x72,0x69,0x66,0x79])]({[_0x317079([0x6e,0x61,0x6d,0x65])]:_0x317079([0x45,0x43,0x44,0x53,0x41]),[_0x317079([0x68,0x61,0x73,0x68])]:{[_0x317079([0x6e,0x61,0x6d,0x65])]:_0x317079([0x53,0x48,0x41,0x2d,0x32,0x35,0x36])}},_0x562cd6,_0x2a627d,_0x96a00d)||(_0xc0ca62=!0x1);}}function _0x31bc99(_0x458946){return _0x458946[_0x317079([0x73,0x74,0x61,0x72,0x74,0x73,0x57,0x69,0x74,0x68])](_0x317079([0x65,0x79]))?JSON[_0x317079([0x70,0x61,0x72,0x73,0x65])](_0x126af4(_0x458946)):null;}function _0x126af4(_0x502be7){return window[_0x317079([0x61,0x74,0x6f,0x62])](_0x502be7[_0x317079([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/-/g,_0x317079([0x2b]))[_0x317079([0x72,0x65,0x70,0x6c,0x61,0x63,0x65])](/_/g,_0x317079([0x2f])));}function _0x1704d4(_0x586359){let _0x3a859d=0x1505;function _0x5a5dff(_0x512da7){for(let _0x447132=0x0;_0x447132<_0x512da7[_0x317079([0x6c,0x65,0x6e,0x67,0x74,0x68])];_0x447132++){const _0x5214dd=_0x512da7[_0x317079([0x63,0x68,0x61,0x72,0x43,0x6f,0x64,0x65,0x41,0x74])](_0x447132);_0x3a859d=(_0x3a859d<<0x5)+_0x3a859d+_0x5214dd,_0x3a859d&=_0x3a859d;}}function _0x3daa54(_0x68dea7){Array[_0x317079([0x69,0x73,0x41,0x72,0x72,0x61,0x79])](_0x68dea7)?_0x68dea7[_0x317079([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](_0x3daa54):_0x68dea7&&typeof _0x68dea7==_0x317079([0x6f,0x62,0x6a,0x65,0x63,0x74])?Object[_0x317079([0x65,0x6e,0x74,0x72,0x69,0x65,0x73])](_0x68dea7)[_0x317079([0x73,0x6f,0x72,0x74])]()[_0x317079([0x66,0x6f,0x72,0x45,0x61,0x63,0x68])](([_0x4b047e,_0x9bc38a])=>{_0x5a5dff(_0x4b047e),_0x3daa54(_0x9bc38a);}):_0x5a5dff(window[_0x317079([0x53,0x74,0x72,0x69,0x6e,0x67])](_0x68dea7));}return _0x3daa54(_0x586359),_0x3a859d>>>0x0;}function _0x589585(_0x421417){return _0x421417[_0x317079([0x74,0x6f,0x53,0x74,0x72,0x69,0x6e,0x67])](0x10)[_0x317079([0x70,0x61,0x64,0x53,0x74,0x61,0x72,0x74])](0x8,_0x317079([0x30]));}function _0x2ace32(_0x4f04f5){return _0x4f04f5[_0x317079([0x73,0x70,0x6c,0x69,0x74])]('')[_0x317079([0x72,0x65,0x76,0x65,0x72,0x73,0x65])]()[_0x317079([0x6a,0x6f,0x69,0x6e])]('');}function _0x5cc82(_0x5010e8){return _0x48adfb[_0x317079([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x317079([0x68,0x61,0x73])](_0x5010e8);}function _0x256b32(_0xb155b3){return _0x48adfb[_0x317079([0x70,0x6c,0x75,0x67,0x69,0x6e,0x73])][_0x317079([0x67,0x65,0x74])](_0xb155b3);}function _0x544f43(){}function _0x317079(_0x550af1){return _0x550af1['map'](_0x2e1b33=>String['fromCharCode'](_0x2e1b33))['join']('');}_0x1fcd6b(await _0x442e35());}(this);}['createRevision'](_0x25dcc6){const _0x1813d4=this['editor']['plugins']['get']('Users');return new h({'id':_0x25dcc6['id'],'name':_0x25dcc6['name'],'creator':_0x25dcc6['creatorId']?_0x1813d4['getUser'](_0x25dcc6['creatorId']):null,'diffData':_0x25dcc6['diffData']||_0x25dcc6['data'],'authors':_0x25dcc6['authorsIds']['map'](_0x3ecc66=>_0x1813d4['getUser'](_0x3ecc66)),'createdAt':new Date(_0x25dcc6['createdAt']),'attributes':_0x25dcc6['attributes'],'fromVersion':_0x25dcc6['fromVersion'],'toVersion':_0x25dcc6['toVersion']});}['addRevision'](_0x197831,_0x3ef246=0x0){this['_revisions']['add'](_0x197831,_0x3ef246);}['getRevision'](_0x99a768){return this['_revisions']['get'](_0x99a768);}['getRevisions'](_0x120234={'toJSON':!0x1}){const _0x56ccaa=Array['from'](this['_revisions']);return _0x56ccaa['reverse'](),_0x120234['toJSON']?_0x56ccaa['map'](_0x24ab22=>_0x24ab22['toJSON']()):_0x56ccaa;}['getIndex'](_0x54c2ae){return this['_revisions']['getIndex'](_0x54c2ae);}['getEarlierVisibleRevision'](_0x245b4f){const [,_0x365784]=this['getRevisionsIterator'](_0x245b4f,{'direction':'earlier'});return _0x365784;}['getLaterVisibleRevision'](_0x29f968){const [,_0x3b36c1]=this['getRevisionsIterator'](_0x29f968,{'direction':'later'});return _0x3b36c1;}['getRevisionsInDiff'](_0x313729){const _0xc70087=[];for(const _0x10e5be of this['getRevisionsIterator'](_0x313729['newRevisionId']))if(_0xc70087['push'](_0x10e5be),_0x10e5be['id']===_0x313729['oldRevisionId'])break;return _0xc70087;}*['getRevisionsIterator'](_0x4709ba,{direction:_0x896ee1='earlier',filter:_0x6a8303=()=>!0x0}={}){const _0x6b1a5f='earlier'===_0x896ee1?0x1:-0x1;let _0x128e63=this['_revisions']['get'](_0x4709ba),_0x194635=this['getIndex'](_0x128e63);for(yield _0x128e63;_0x128e63;){if(_0x194635+=_0x6b1a5f,_0x128e63=this['getRevision'](_0x194635),!_0x128e63)return;_0x6a8303(_0x128e63)&&(yield _0x128e63);}}}function m(_0x3c18df,_0x48502b,_0x42c865){const t=_0x3c18df['t'];switch(_0x48502b){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'},_0x42c865);case'X_OF_Y_CHANGES':return t({'string':'%0\x20of\x20%1','id':'X_OF_Y_CHANGES'},_0x42c865);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 E={'c':_0x536437,'a':_0x51cef1,'e':_0x5d757a,'r':_0xd3a339,'u':_0x28565d};class u extends _0x118fc5{['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[_0x1120ef,j,_0x16589e];}constructor(_0x3de7c1){super(_0x3de7c1),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 _0x2f1e4f=_0x118080();this['_source']={'history':this['editor']['model']['document']['history'],'getLatestVersion':()=>Promise['resolve'](this['editor']['model']['document']['version']),'getCurrentRevisionId':()=>_0x2f1e4f},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 _0x1735ea=this['repository']['getRevision'](0x0),_0x3e7159=_0x1735ea&&null===_0x1735ea['creator']?_0x1735ea:null;if(this['_continueCurrentRevision']=!!_0x3e7159&&this['editor']['config']['get']('revisionHistory.resumeUnsavedRevision'),this['editor']['plugins']['has']('RealTimeCollaborationClient')){const _0x3c4d3f=this['_source']['getCurrentRevisionId'](),_0x285431=this['repository']['getRevision'](_0x3c4d3f);if(_0x285431)this['_startingVersion']=_0x285431['fromVersion'],this['_continueCurrentRevision']=!0x1;else{const _0xca37d6=this['_source']['history']['_operations']['find'](_0x2a7d39=>!_0x2a7d39['_isInit']),_0x32fdcc=_0xca37d6?_0xca37d6['baseVersion']:this['_source']['history']['version'];_0x1735ea?(_0x1735ea['toVersion']<_0x32fdcc&&_0x1735ea['_update']({'toVersion':_0x32fdcc}),this['_continueCurrentRevision']?(this['_source']['getCurrentRevisionId']=()=>_0x3e7159['id'],this['_startingVersion']=_0x3e7159['fromVersion']):(this['_startingVersion']=_0x1735ea['toVersion'],this['_continueCurrentRevision']=!0x1)):(this['_startingVersion']=_0x32fdcc,this['_continueCurrentRevision']=!0x1);}}else _0x3e7159&&(this['editor']['model']['document']['history']['version']=Math['max'](_0x3e7159['toVersion'],this['editor']['model']['document']['history']['version']),_0x3e7159['fromVersion']===_0x3e7159['toVersion']?(0x0!==_0x3e7159['fromVersion']&&(this['_source']['getCurrentRevisionId']=()=>_0x3e7159['id']),this['_continueCurrentRevision']=!0x1):this['_continueCurrentRevision']&&(this['_source']['getCurrentRevisionId']=()=>_0x3e7159['id'],this['_startingVersion']=_0x3e7159['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',_0xdf9c97=>!_0xdf9c97),this['licenseKey']=this['editor']['config']['get']('licenseKey');const _0x2ff7ab=this['editor'];this['_licenseKeyCheckInterval']=setInterval(()=>{let _0x5a92b0;for(const _0x4182bb in _0x2ff7ab){const _0x3182a4=_0x4182bb,_0x144458=_0x2ff7ab[_0x3182a4];if('revisionHistoryLicenseKeyValid'==_0x144458||'revisionHistoryLicenseKeyInvalid'==_0x144458||'revisionHistoryLicenseKeyExpired'==_0x144458||'revisionHistoryLicenseKeyDomainLimit'==_0x144458||'revisionHistoryLicenseKeyNotAllowed'==_0x144458||'revisionHistoryLicenseKeyEvaluationLimit'==_0x144458||'revisionHistoryLicenseKeyTrialLimit'==_0x144458||'revisionHistoryLicenseKeyUsageLimit'==_0x144458){delete _0x2ff7ab[_0x3182a4],_0x5a92b0=_0x144458,clearInterval(this['_licenseKeyCheckInterval']),this['_licenseKeyCheckInterval']=void 0x0;break;}}'revisionHistoryLicenseKeyInvalid'==_0x5a92b0&&_0x2ff7ab['_showLicenseError']('invalid'),'revisionHistoryLicenseKeyExpired'==_0x5a92b0&&_0x2ff7ab['_showLicenseError']('expired'),'revisionHistoryLicenseKeyDomainLimit'==_0x5a92b0&&_0x2ff7ab['_showLicenseError']('domainLimit'),'revisionHistoryLicenseKeyNotAllowed'==_0x5a92b0&&_0x2ff7ab['_showLicenseError']('featureNotAllowed','RevisionHistory'),'revisionHistoryLicenseKeyEvaluationLimit'==_0x5a92b0&&_0x2ff7ab['_showLicenseError']('evaluationLimit'),'revisionHistoryLicenseKeyTrialLimit'==_0x5a92b0&&_0x2ff7ab['_showLicenseError']('trialLimit'),'revisionHistoryLicenseKeyUsageLimit'==_0x5a92b0&&_0x2ff7ab['_showLicenseError']('usageLimit');},0x3e8);}async['afterInit'](){if(this['repository']['length']>0x0){const _0x4d1ce5=this['repository']['getRevision'](0x0),_0x170376=await this['getRevisionDocumentData'](_0x4d1ce5),_0x1e65b8=await this['getRevisionRootsAttributes'](_0x4d1ce5);this['_replaceEditorDataWithRevisionData'](_0x170376,_0x1e65b8);}}['destroy'](){super['destroy'](),this['_licenseKeyCheckInterval']&&clearInterval(this['_licenseKeyCheckInterval']);}['setSource'](_0x4cab4a){this['_source']=_0x4cab4a;}async['update'](){const _0x225ea5=await this['_source']['getLatestVersion']();if(_0x225ea5>this['currentRevision']['toVersion']){await this['_loadState']();const _0x319e56=this['buildRevisionData']({'revision':this['currentRevision'],'to':_0x225ea5});_0x319e56['authors']=_0x319e56['authorsIds']['map'](_0xd59e35=>this['editor']['plugins']['get']('Users')['getUser'](_0xd59e35)),this['currentRevision']['_update'](_0x319e56);}}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'](_0x501369={},_0xdeedcc=null){const _0x12bd1e=[];await this['_loadState'](),this['_continueCurrentRevision']=!0x1,_0xdeedcc>this['currentRevision']['toVersion']&&(_0xdeedcc=null),null===_0xdeedcc&&(_0xdeedcc=await this['_source']['getLatestVersion']());const _0x20ceec=this['_getFromVersion'](_0xdeedcc),_0x54fe12=this['buildRevisionData']({'from':_0x20ceec,'to':_0xdeedcc});if(this['currentRevision']['toVersion']<_0xdeedcc){const _0x41b836=this['buildRevisionData']({'revision':this['currentRevision'],'from':_0xdeedcc,'to':_0xdeedcc});_0x41b836['authors']=[],_0x41b836['authorsIds']=[],_0x41b836['id']=this['currentRevision']['id'],this['currentRevision']['_update'](_0x41b836,!0x0),delete _0x41b836['authors'],_0x12bd1e['push'](_0x41b836);}_0x501369['creatorId']=this['editor']['plugins']['get']('Users')['me']['id'],_0x501369['name']=_0x501369['name']||null,_0x501369['id']=_0x501369['id']||_0x118080(),_0x501369={..._0x501369,..._0x54fe12};const _0x460e33=this['addRevisionData'](_0x501369);_0x12bd1e['push'](_0x501369);const _0x17aedd=this['repository']['getIndex'](_0x460e33);if(0x0!==_0x17aedd){const _0x6173cc=this['repository']['getRevision'](_0x17aedd-0x1);if(_0x6173cc['fromVersion']!==_0xdeedcc){const _0x2c0035=this['_revisionDataBuilder']['getData'](_0xdeedcc,_0x6173cc['toVersion']),_0x524596={'id':_0x6173cc['id'],'diffData':_0x2c0035['diffData'],'authorsIds':_0x2c0035['authorsIds'],'authors':_0x2c0035['authorsIds']['map'](_0x4a09b5=>this['editor']['plugins']['get']('Users')['getUser'](_0x4a09b5)),'fromVersion':_0xdeedcc};_0x6173cc===this['currentRevision']&&(_0x524596['createdAt']=new Date(_0x501369['createdAt']['getTime']()+0xa)),_0x6173cc['_update'](_0x524596,!0x0),delete _0x524596['authors'],_0x12bd1e['push'](_0x524596);}}if(this['adapter']){for(const _0x548cf3 of _0x12bd1e)this['_bufferUpdate'](_0x548cf3['id'],_0x548cf3,!0x0);this['sendBufferedUpdates']();}return _0x460e33;}['addRevisionData'](_0x6b6b1c){const _0x50eb17=this['repository']['createRevision'](_0x6b6b1c);return this['adapter']&&_0x50eb17['on']('_update',(_0x2cf93d,_0x2cee7f,_0x12bf66)=>{_0x12bf66||(this['_bufferUpdate'](_0x2cee7f['id'],_0x2cee7f,!0x0),this['sendBufferedUpdates']());}),this['repository']['addRevision'](_0x50eb17,this['_findInsertionIndex'](_0x50eb17)),_0x50eb17;}async['getRevisionDocumentData'](_0x29b6be){await this['_loadRevisionData'](_0x29b6be);const _0x4a58a3={};for(const _0x48b351 in _0x29b6be['diffData']){if(_0x29b6be['diffData'][_0x48b351]['attachChange']&&!_0x29b6be['diffData'][_0x48b351]['attachChange']['isAttached'])continue;const _0x3c85cb=this['_removeRevisionMarkers'](JSON['parse'](_0x29b6be['diffData'][_0x48b351]['insertions'])),_0x196b96=this['editor']['editing']['view']['document'],_0x1a2e41=new _0x8157a(_0x196b96,_0x3c85cb['map'](_0x3e6215=>P(_0x3e6215,this['editor'])));this['editor']['data']['processor']['useFillerType']('marked'),_0x4a58a3[_0x48b351]=this['editor']['data']['processor']['toData'](_0x1a2e41),this['editor']['data']['processor']['useFillerType']('default');}return _0x4a58a3;}async['getRevisionRootsAttributes'](_0x4f2fba){await this['_loadRevisionData'](_0x4f2fba);const _0x4cb4be={};for(const _0xed7f02 in _0x4f2fba['diffData'])_0x4f2fba['diffData'][_0xed7f02]['attachChange']&&!_0x4f2fba['diffData'][_0xed7f02]['attachChange']['isAttached']||(_0x4cb4be[_0xed7f02]=_0x4f2fba['diffData'][_0xed7f02]['attributesAfter']||{});return _0x4cb4be;}['sendBufferedUpdates'](){if(0x0===this['_bufferedUpdates']['size'])return;if(this['_isPendingUpdate'])return;let _0x1661e8=Array['from'](this['_bufferedUpdates']['values']());this['_bufferedUpdates']['clear']();for(let _0x18c765=0x0;_0x18c765<_0x1661e8['length'];_0x18c765++){const _0x1578cc=_0x1661e8[_0x18c765];let _0x2e0e8e=!0x1;for(const _0x29c1c9 of Object['keys'](_0x1578cc))void 0x0===_0x1578cc[_0x29c1c9]?delete _0x1578cc[_0x29c1c9]:'id'!==_0x29c1c9&&(_0x2e0e8e=!0x0);_0x2e0e8e||(_0x1661e8[_0x18c765]=null);}if(_0x1661e8=_0x1661e8['filter'](_0x546edc=>null!==_0x546edc),!_0x1661e8['length'])return;for(let _0x261aac=0x0;_0x261aac<_0x1661e8['length'];_0x261aac++){const _0x2f894d=_0x1661e8[_0x261aac];void 0x0!==_0x2f894d['fromVersion']&&void 0x0===_0x2f894d['toVersion']&&(_0x2f894d['toVersion']=this['repository']['getRevision'](_0x2f894d['id'])['toVersion']),void 0x0!==_0x2f894d['toVersion']&&void 0x0===_0x2f894d['fromVersion']&&(_0x2f894d['fromVersion']=this['repository']['getRevision'](_0x2f894d['id'])['fromVersion']);}const _0x284030=this['editor']['config']['get']('collaboration.channelId');this['_isPendingUpdate']=!0x0,this['_addPendingAction'](),this['adapter']['updateRevisions'](_0x1661e8,_0x284030)['finally'](()=>{this['_isPendingUpdate']=!0x1;})['then'](_0x5d1604=>{if(_0x5d1604){for(const _0x464721 of _0x5d1604)this['setRevisionData']({'id':_0x464721['id'],'createdAt':_0x464721['createdAt']});}this['_removePendingAction'](),this['sendBufferedUpdates']();});}['_replaceEditorDataWithRevisionData'](_0xda42c5,_0x3da02b){let _0x41b9c9=this['editor']['config']['get']('initialData'),_0x25246e=this['editor']['config']['get']('rootsAttributes');if(void 0x0===_0x41b9c9){_0x41b9c9={};for(const _0x14fcd5 of this['editor']['model']['document']['getRootNames']())_0x41b9c9[_0x14fcd5]='';}if('string'==typeof _0x41b9c9&&(_0x41b9c9={'main':_0x41b9c9}),void 0x0===_0x25246e){_0x25246e={};for(const _0x4a569e of this['editor']['model']['document']['getRootNames']())_0x25246e[_0x4a569e]={};}let _0x205b7f=!0x1;const _0x566739=Object['keys'](_0x41b9c9),_0x4784f5=Object['keys'](_0xda42c5);for(const _0x4c5965 of _0x566739){if(_0x41b9c9[_0x4c5965]!==_0xda42c5[_0x4c5965]&&''!==_0x41b9c9[_0x4c5965]['trim']()){_0x205b7f=!0x0;break;}if(!_0x1ff0ec(_0x25246e[_0x4c5965],_0x3da02b[_0x4c5965])&&Object['keys'](_0x25246e[_0x4c5965])['length']>0x0){_0x205b7f=!0x0;break;}}_0x205b7f||(_0x205b7f=_0x4784f5['some'](_0x170ef9=>!this['editor']['model']['document']['getRoot'](_0x170ef9))),_0x205b7f&&_0x26aa91('editor-initial-data-replaced-with-revision-data',{'editorData':_0x41b9c9,'editorRootsAttributes':_0x25246e,'revisionData':_0xda42c5,'revisionRootsAttributes':_0x3da02b}),this['editor']['config']['set']('initialData',_0xda42c5),this['editor']['config']['set']('rootsAttributes',_0x3da02b);}['_addPendingAction'](){if(!this['_pendingAction']){const _0x434427=this['editor']['plugins']['get']('PendingActions');this['_pendingAction']=_0x434427['add'](m(this['editor']['locale'],'PENDING_ACTION_REVISION_HISTORY'));}}['_removePendingAction'](){this['_pendingAction']&&(this['editor']['plugins']['get']('PendingActions')['remove'](this['_pendingAction']),this['_pendingAction']=null);}['_findInsertionIndex'](_0x356fdd){const _0x44aa92=this['repository']['getRevisions']();_0x44aa92['reverse']();let _0x1d3c74=0x0;for(;_0x1d3c74<_0x44aa92['length'];){const _0x5ec2ad=_0x44aa92[_0x1d3c74];if(_0x5ec2ad===this['currentRevision']){_0x1d3c74++;continue;}if(_0x5ec2ad['id']===this['_initialRevisionId'])break;const _0x324cd3=_0x356fdd['toVersion']-_0x5ec2ad['toVersion']||_0x356fdd['fromVersion']-_0x5ec2ad['fromVersion'];if(_0x324cd3>0x0)break;if(_0x324cd3<0x0)_0x1d3c74++;else{if(!_0x356fdd['creator']&&_0x5ec2ad['creator'])break;if(_0x5ec2ad['creator']||!_0x356fdd['creator']){if(_0x356fdd['createdAt']>_0x5ec2ad['createdAt'])break;_0x1d3c74++;}else _0x1d3c74++;}}return _0x1d3c74;}['setRevisionData'](_0x4a0856){const _0xc0d4e9=this['repository']['getRevision'](_0x4a0856['id']);if(_0x4a0856['createdAt']&&(_0x4a0856['createdAt']=new Date(_0x4a0856['createdAt'])),_0x4a0856['authorsIds']){const _0x45774a=this['editor']['plugins']['get']('Users');_0x4a0856['authors']=_0x4a0856['authorsIds']['map'](_0x4f196c=>_0x45774a['getUser'](_0x4f196c));}_0xc0d4e9['_update'](_0x4a0856,!0x0);}['buildRevisionData']({revision:_0x205698=null,from:_0x28a4fa=null,to:_0x32bb92=null}){_0x28a4fa=null!==_0x28a4fa?_0x28a4fa:_0x205698['fromVersion'],_0x32bb92=null!==_0x32bb92?_0x32bb92:_0x205698['toVersion'];const _0x32ab34=this['_revisionDataBuilder']['getData'](_0x28a4fa,_0x32bb92),_0x3eef3d={'diffData':_0x32ab34['diffData'],'authorsIds':_0x32ab34['authorsIds'],'fromVersion':_0x28a4fa,'toVersion':_0x32bb92};if(!_0x205698||_0x32bb92!==_0x205698['toVersion']){const _0x3fa9e3=_0x32bb92-0x1,_0x18cd12=this['_source']['history']['getOperation'](_0x3fa9e3);_0x3eef3d['createdAt']=_0x18cd12&&_0x18cd12['createdAt']||new Date();}if(this['_loadedStateData']&&_0x28a4fa===this['_loadedStateData']['fromVersion']){for(const _0x18491d of this['_loadedStateData']['authors'])_0x3eef3d['authorsIds']['includes'](_0x18491d['id'])||_0x3eef3d['authorsIds']['push'](_0x18491d['id']);}return _0x3eef3d;}['_loadRevisionData'](_0x447078){if(!_0x447078||_0x447078['diffData'])return Promise['resolve']();{const _0x2d2468=this['editor']['config']['get']('collaboration.channelId');return this['adapter']['getRevision']({'channelId':_0x2d2468,'revisionId':_0x447078['id']})['then'](_0x1adf9e=>{_0x447078['diffData']=_0x1adf9e['diffData'];});}}['_bufferUpdate'](_0x556675,_0x12d278,_0x286454){if(this['_bufferedUpdates']['has'](_0x556675)){const _0x2d4aff=this['_bufferedUpdates']['get'](_0x556675);_0x12d278=_0x286454?{..._0x2d4aff,..._0x12d278}:{..._0x12d278,..._0x2d4aff};}this['_bufferedUpdates']['set'](_0x556675,_0x12d278);}['_getFromVersion'](_0x154df2){const _0x533df2=this['repository']['getRevisions']();_0x533df2['reverse'](),_0x533df2['shift']();const _0x5dfabf=_0x533df2['find'](_0x5286e4=>_0x5286e4['toVersion']<=_0x154df2)['toVersion'];return _0x5dfabf<this['_startingVersion']?this['_startingVersion']:_0x5dfabf;}['_createInitialRevision'](_0x2a7456){const _0x2b2e88=this['repository']['getRevision'](this['repository']['length']-0x1);if(_0x2b2e88)this['_initialRevisionId']=_0x2b2e88['id'];else{const _0x4f4d57=!this['editor']['model']['document']['roots']['find'](_0x4fcef4=>this['editor']['model']['hasContent'](_0x4fcef4)),_0x557fb3=this['editor']['plugins']['get']('Users')['me']['id'],_0x1e6fd1=m(this['editor']['locale'],_0x4f4d57?'Empty\x20document':'Initial\x20revision');this['_makeRevision']({'from':_0x2a7456,'to':_0x2a7456,'id':this['_initialRevisionId'],'name':_0x1e6fd1,'creatorId':_0x557fb3});}}['_createCurrentRevision'](_0x12b8eb){const _0x472875=this['_source']['getCurrentRevisionId']();this['currentRevision']=this['repository']['getRevision'](_0x472875),this['currentRevision']||(this['currentRevision']=this['_makeRevision']({'from':_0x12b8eb,'to':_0x12b8eb,'id':_0x472875,'name':'','creatorId':null}));}['_makeRevision']({name:_0x4e530c,from:_0x509135,to:_0x38dbe8,creatorId:_0x25b031,id:_0x1a97ce}){const _0x2a8784=this['buildRevisionData']({'from':_0x509135,'to':_0x38dbe8});_0x2a8784['name']=_0x4e530c,_0x2a8784['creatorId']=_0x25b031,_0x2a8784['id']=_0x1a97ce;const _0x5afd74=this['addRevisionData'](_0x2a8784);return this['adapter']&&this['_bufferUpdate'](_0x2a8784['id'],_0x2a8784,!0x0),_0x5afd74;}['_setConversion'](){this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'});}['_removeRevisionMarkers'](_0x33166f){return(_0x33166f=_0x33166f['filter'](_0x1fcaed=>!_0x1fcaed['name']||'revision-start'!==_0x1fcaed['name']&&'revision-end'!==_0x1fcaed['name']))['forEach'](_0x18bc62=>{'string'!=typeof _0x18bc62&&(_0x18bc62['children']=this['_removeRevisionMarkers'](_0x18bc62['children']),_0x18bc62['attributes']=_0x18bc62['attributes']['filter'](_0x49331e=>!_0x49331e[0x0]['startsWith']('data-revision-')));}),_0x33166f;}}function P(_0xe1d08b,_0x15718e){const _0x1d4678=_0x15718e['editing']['view']['document'];if('string'==typeof _0xe1d08b)return new _0x1b404c(_0x1d4678,_0xe1d08b);{const _0x392fd8=_0xe1d08b['children']['map'](_0x59607f=>P(_0x59607f,_0x15718e));return new(E[_0xe1d08b['type']]||_0x34db6a)(_0x1d4678,_0xe1d08b['name'],_0xe1d08b['attributes'],_0x392fd8);}}class V{['editor'];['source'];['_savedMetaData'];['_lastFrom'];['_lastTo'];['_markers'];['_diffRoots'];['_diffRootsAttributes'];['_baseRoots'];['_baseRootsAttributes'];['_idsRoots'];['_baseIdsRoots'];['_touched'];['_touchedMarkers'];['_touchedRoots'];['_revisionId'];['_startingRevisionId'];constructor(_0x3ce964){this['editor']=_0x3ce964,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'](_0xa3d850){this['source']=_0xa3d850;const _0x4af3ea=new Map(),_0x18b321=new Map(),_0x4d75ef=this['editor']['model']['document']['roots']['map'](_0x2e9d19=>_0x2e9d19['rootName']);for(const _0x59d823 of _0x4d75ef){const _0x261a84=this['editor']['model']['document']['getRoot'](_0x59d823),_0x45b33b=T(_0x261a84);_0x4af3ea['set'](_0x59d823,_0x45b33b),_0x18b321['set'](_0x59d823,Object['fromEntries'](_0x261a84['getAttributes']()));}const _0x3c67db=Array['from'](this['editor']['model']['markers'])['map'](_0xb95078=>[_0xb95078['name'],_0xb95078['getRange']()]),_0x326cd5=this['source']['version'];this['_saveMetaData'](_0x326cd5,_0x4af3ea,_0x3c67db,_0x18b321),this['_startingRevisionId']=this['_revisionId'];const _0x2856b4=new Map(),_0x2604bf=new Map();for(const _0x3f9cad of _0x4d75ef){const _0x522608=F(_0x3f9cad);_0x2856b4['set'](_0x3f9cad,_0x522608),_0x2604bf['set'](_0x3f9cad,{});}this['_saveMetaData'](Number['NEGATIVE_INFINITY'],_0x2856b4,[],_0x2604bf);}['getData'](_0x8cde68,_0x214c4a){if(this['_lastFrom']===_0x8cde68&&this['_lastTo']<=_0x214c4a)this['_savedMetaData']['size']>0x1&&this['_removeMetaData'](this['_lastTo']),this['_applyOperations'](this['_lastTo'],_0x214c4a,!0x0);else{if(!this['_savedMetaData']['has'](_0x8cde68)){const _0x123c8b=this['_getPreviousFrom'](_0x8cde68);this['_calculateMetaData'](_0x123c8b,_0x8cde68,!0x1);}this['_calculateMetaData'](_0x8cde68,_0x214c4a,!0x0);}return this['_lastFrom']=_0x8cde68,this['_lastTo']=_0x214c4a,this['_getState']();}['loadState'](_0x14a34f){this['_reset'](),this['_lastFrom']=_0x14a34f['fromVersion'],this['_lastTo']=_0x14a34f['toVersion'];for(const _0x1a02b1 in _0x14a34f['diffData']){const _0x434401=_0x14a34f['diffData'][_0x1a02b1]['attachChange'],_0x112be4=_0x127b89(_0x14a34f['diffData'][_0x1a02b1]['attributesBefore'])||{},_0x2a0f7c=this['_makeModelFromViewString'](_0x14a34f['diffData'][_0x1a02b1]['deletions']);_0x2a0f7c['rootName']=_0x1a02b1,_0x2a0f7c['_isAttached']=!_0x434401||!_0x434401['isAttached'],_0x2a0f7c['isAttached']=()=>_0x2a0f7c['_isAttached'],this['_baseRoots']['set'](_0x1a02b1,_0x2a0f7c),this['_baseRootsAttributes']['set'](_0x1a02b1,_0x112be4),_0x434401&&this['_touchedRoots']['set'](_0x1a02b1,_0x434401);const _0x4a2fce=this['_makeIdsRoot'](_0x2a0f7c);this['_baseIdsRoots']['set'](_0x1a02b1,_0x4a2fce);for(const [_0x171399,_0x19e85c]of _0x2a0f7c['markers']){if(!_0x171399['startsWith']('revision:'))continue;const _0x12a81e=_0x171399['split'](':')[0x2];for(const _0x2db0e0 of _0x19e85c['getWalker']({'singleCharacters':!0x0})){const _0x39ccc4=this['_getVidAttributeName'](_0x2db0e0),_0x5a6d43='elementEnd'==_0x2db0e0['type']?_0x2db0e0['previousPosition']['path']['slice'](0x0,-0x1):_0x2db0e0['previousPosition']['path'],_0x2e2baf=_0x4a2fce['getNodeByPath'](_0x5a6d43)['getAttribute'](_0x39ccc4);this['_touched']['set'](_0x2e2baf,{'userId':_0x12a81e});}}}this['_startingRevisionId']=this['_revisionId'];const _0x42e872=[...Array(this['_revisionId'])['keys']()]['slice'](0x1)['filter'](_0x53d9f3=>!this['_touched']['has'](_0x53d9f3));let _0x277f0a=0x0;const _0x1c67a5=new Map();for(const _0x593aff in _0x14a34f['diffData']){const _0x5b7682=_0x14a34f['diffData'][_0x593aff]['attachChange'],_0xcda059=_0x127b89(_0x14a34f['diffData'][_0x593aff]['attributesAfter'])||{},_0x349c01=this['_makeModelFromViewString'](_0x14a34f['diffData'][_0x593aff]['insertions']);_0x349c01['rootName']=_0x593aff,_0x349c01['_isAttached']=!_0x5b7682||_0x5b7682['isAttached'],_0x349c01['isAttached']=()=>_0x349c01['_isAttached'],this['_diffRoots']['set'](_0x593aff,_0x349c01),this['_diffRootsAttributes']['set'](_0x593aff,_0xcda059);const _0x344c45=this['_makeIdsRoot'](_0x349c01,Number['NEGATIVE_INFINITY']);this['_idsRoots']['set'](_0x593aff,_0x344c45),_0x1c67a5['set'](_0x593aff,_0x349c01['isAttached']()?_0xcda059:{});for(const [_0x356b78,_0x576fcc]of _0x349c01['markers']){if(!_0x356b78['startsWith']('revision:'))continue;const _0x3f65b3=_0x356b78['split'](':')[0x2];for(const _0x5313bb of _0x576fcc['getWalker']({'singleCharacters':!0x0})){const _0x160790=this['_getVidAttributeName'](_0x5313bb),_0x388a53=this['_revisionId']++,_0x480ae1='elementEnd'==_0x5313bb['type']?_0x5313bb['previousPosition']['path']['slice'](0x0,-0x1):_0x5313bb['previousPosition']['path'];_0x344c45['getNodeByPath'](_0x480ae1)['_setAttribute'](_0x160790,_0x388a53),this['_touched']['set'](_0x388a53,{'userId':_0x3f65b3});}}for(const _0x4a231a of this['editor']['model']['createRangeIn'](_0x349c01)['getWalker']({'singleCharacters':!0x0})){const _0x43d8d7=this['_getVidAttributeName'](_0x4a231a),_0x41ac82='elementEnd'==_0x4a231a['type']?_0x4a231a['previousPosition']['path']['slice'](0x0,-0x1):_0x4a231a['previousPosition']['path'],_0xd6b561=_0x344c45['getNodeByPath'](_0x41ac82);_0xd6b561['getAttribute'](_0x43d8d7)>0x0||_0xd6b561['_setAttribute'](_0x43d8d7,_0x42e872[_0x277f0a++]);}for(const [_0x47b1e5,_0xf7dfdf]of _0x349c01['markers'])_0x47b1e5['startsWith']('revision:')||this['_markers']['set'](_0x47b1e5,_0xf7dfdf);}const _0x34d056=F('$graveyard');this['_baseRoots']['set']('$graveyard',_0x34d056),this['_baseIdsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x34d056,0x1));const _0x5f0f17=F('$graveyard');this['_diffRoots']['set']('$graveyard',_0x5f0f17),this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](_0x5f0f17,0x1));const _0x4fc82d=Array['from'](this['_diffRoots'])['map'](([_0x24a1a9,_0x368275])=>[_0x24a1a9,T(_0x368275)]);this['_saveMetaData'](this['_lastTo'],_0x4fc82d,this['_markers'],_0x1c67a5);}['_makeModelFromViewString'](_0x2d2d87){const _0xe0e642=JSON['parse'](_0x2d2d87),_0x213f83=this['editor']['editing']['view']['document'],_0x34efc5=new _0x8157a(_0x213f83,_0xe0e642['map'](_0x5d513c=>P(_0x5d513c,this['editor'])));return this['editor']['data']['toModel'](_0x34efc5);}['_saveMetaData'](_0x3994ad,_0x484ace,_0x37df11,_0x16ee3a){const _0x2daf0a=new Map(_0x484ace),_0x4e01d8=new Map(_0x127b89(_0x16ee3a)),_0x121ba3=new Map();for(const [_0x1ded2e,_0x43fd44]of _0x37df11)_0x121ba3['set'](_0x1ded2e,{'start':_0x43fd44['start']['clone'](),'end':_0x43fd44['end']['clone'](),'rootName':_0x43fd44['root']['rootName']});this['_savedMetaData']['set'](_0x3994ad,{'roots':_0x2daf0a,'markers':_0x121ba3,'rootsAttributes':_0x4e01d8});}['_removeMetaData'](_0x59a34b){this['_savedMetaData']['delete'](_0x59a34b);}['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'](_0x181543,_0x5c514a=null){let _0x1bb99a=null;_0x181543['is']('documentFragment')||(_0x1bb99a=new ut(_0x181543['name'],{'vid_start':null===_0x5c514a?this['_revisionId']++:_0x5c514a++}));const _0xb81981=[];for(const _0x5556bd of _0x181543['getChildren']())if(_0x5556bd['is']('element')){_0xb81981['push'](this['_makeIdsRoot'](_0x5556bd,_0x5c514a));const _0x57948a=_0xb81981[_0xb81981['length']-0x1];null!==_0x5c514a&&(_0x5c514a=_0x57948a['is']('element','$text')?_0x57948a['getAttribute']('vid')+0x1:_0x57948a['getAttribute']('vid_end')+0x1);}else{for(let _0x5b8960=0x0;_0x5b8960<_0x5556bd['offsetSize'];_0x5b8960++)_0xb81981['push'](new ut('$text',{'vid':null===_0x5c514a?this['_revisionId']++:_0x5c514a++}));}if(_0x181543['is']('documentFragment')){const _0x7f925c=F(_0x181543['rootName']);return _0x7f925c['_insertChild'](0x0,_0xb81981),_0x7f925c;}return _0x1bb99a['_setAttribute']('vid_end',null===_0x5c514a?this['_revisionId']++:_0x5c514a++),_0x1bb99a['_insertChild'](0x0,_0xb81981),_0x1bb99a;}['_calculateMetaData'](_0x4f5e18,_0x27a73e,_0x3bca20){this['_reset']();const {roots:_0x4241b0,markers:_0x8e72e3,rootsAttributes:_0x1a9c89}=this['_savedMetaData']['get'](_0x4f5e18);this['_baseRoots']=new Map(_0x4241b0),this['_baseRootsAttributes']=new Map(_0x127b89(_0x1a9c89));for(const [_0x4fba9d,_0x4e8866]of this['_baseRoots'])if('$graveyard'!==_0x4fba9d&&(this['_diffRoots']['set'](_0x4fba9d,T(_0x4e8866)),this['_diffRootsAttributes']=new Map(_0x127b89(_0x1a9c89)),_0x3bca20)){const _0xaaa154=this['_revisionId'];this['_idsRoots']['set'](_0x4fba9d,this['_makeIdsRoot'](_0x4e8866)),this['_baseIdsRoots']['set'](_0x4fba9d,this['_makeIdsRoot'](_0x4e8866,_0xaaa154));}this['_startingRevisionId']=this['_revisionId'],this['_diffRoots']['set']('$graveyard',T(this['_baseRoots']['get']('$graveyard'))),_0x3bca20&&this['_idsRoots']['set']('$graveyard',this['_makeIdsRoot'](this['_baseRoots']['get']('$graveyard')));for(const [_0x1905ad,_0x36bb07]of _0x8e72e3){const _0x371794=this['_baseRoots']['get'](_0x36bb07['rootName']),_0x26061a=this['_diffRoots']['get'](_0x36bb07['rootName']),_0x35a758=new ft(this['_fixPosition'](_0x36bb07['start'],_0x371794),this['_fixPosition'](_0x36bb07['end'],_0x371794)),_0x45f832=this['_fixRange'](_0x35a758,_0x26061a);_0x371794['markers']['set'](_0x1905ad,_0x35a758),this['_markers']['set'](_0x1905ad,_0x45f832);}this['_applyOperations'](_0x4f5e18,_0x27a73e,_0x3bca20);}['_applyOperations'](_0x2f22ab,_0x2b5374,_0x23fb2b){for(const _0x396fcc of this['source']['getOperations'](_0x2f22ab,_0x2b5374))this['_handleOperation'](_0x396fcc,_0x23fb2b);for(const _0xb3f60c of this['_diffRoots']['values']())_0xb3f60c['markers']['clear']();for(const [_0x58eadb,_0x21b810]of this['_markers']){this['_diffRoots']['get'](_0x21b810['root']['rootName'])['markers']['set'](_0x58eadb,_0x21b810['clone']());}const _0x3bc12a=new Map(),_0x3e7358=new Map();for(const [_0x37d93d,_0x2307fd]of this['_diffRoots'])_0x3bc12a['set'](_0x37d93d,T(_0x2307fd)),_0x3e7358['set'](_0x37d93d,this['_diffRootsAttributes']['get'](_0x37d93d));this['_saveMetaData'](_0x2b5374,_0x3bc12a,this['_markers'],_0x3e7358);}['_getPreviousFrom'](_0x5d4dd9){const _0x588cdd=Array['from'](this['_savedMetaData']['keys']());_0x588cdd['sort']((_0x33619d,_0x1379fd)=>_0x33619d-_0x1379fd),_0x588cdd['reverse']();for(const _0x56ec47 of _0x588cdd)if(_0x56ec47<_0x5d4dd9)return _0x56ec47;return Number['NEGATIVE_INFINITY'];}['_copyMarkers'](_0x209665,_0x5e050f){const _0x5bc9a2=Array['from'](_0x5e050f['markers'])['map'](([_0x24202f,_0x1405e5])=>[_0x24202f,this['_fixRange'](_0x1405e5,_0x209665)]);_0x209665['markers']=new Map(_0x5bc9a2);}['_transformMarkers'](_0x581037){for(const _0x36e6cf of this['_markers']['values']()){const _0x431870=_0x36e6cf['getTransformedByOperation'](_0x581037),_0x20583d=ft['_createFromRanges'](_0x431870);_0x36e6cf['start']=_0x20583d['start'],_0x36e6cf['end']=_0x20583d['end'];}}['_handleOperation'](_0x4fa64e,_0xb4970f){if('addRoot'!=_0x4fa64e['type']&&'detachRoot'!=_0x4fa64e['type']){if('insert'==_0x4fa64e['type']){const _0x24da00=_0x4fa64e['position']['root']['rootName'];this['_diffRoots']['has'](_0x24da00)||(this['_diffRoots']['set'](_0x24da00,F(_0x24da00,!0x0)),this['_diffRootsAttributes']['set'](_0x24da00,{}),_0xb4970f&&this['_idsRoots']['set'](_0x24da00,F(_0x24da00,!0x0)));}else{if('addRootAttribute'==_0x4fa64e['type']||'removeRootAttribute'==_0x4fa64e['type']||'changeRootAttribute'==_0x4fa64e['type'])return void this['_handleRootAttributeOperation'](_0x4fa64e);'marker'==_0x4fa64e['type']&&this['_handleMarkerOperation'](_0x4fa64e);}if('marker'!==_0x4fa64e['type']){const _0x53d684=this['_cloneOperation'](_0x4fa64e,this['_diffRoots']);_0x53d684['_execute'](),this['_transformMarkers'](_0x53d684);}if(_0xb4970f)switch(_0x4fa64e['type']){case'insert':this['_handleInsertOperation'](_0x4fa64e);break;case'move':case'remove':case'reinsert':this['_handleMoveOperation'](_0x4fa64e);break;case'merge':this['_handleMergeOperation'](_0x4fa64e);break;case'split':this['_handleSplitOperation'](_0x4fa64e);}}else this['_handleRootOperation'](_0x4fa64e,_0xb4970f);}['_cloneOperation'](_0x3bb9e8,_0x3b9945){const _0xf67592=_0x3bb9e8['clone']();return _0xf67592['_authorId']=_0x3bb9e8['_authorId'],this['_fixOperation'](_0xf67592,_0x3b9945),_0xf67592;}['_getBaseVids'](_0x336333){return _0x336333['map'](_0xa80f96=>{const _0x308327=this['_getVidAttributeName'](_0xa80f96);return Number(_0xa80f96['item']['getAttribute'](_0x308327));});}['_generateTape'](_0x57d4dc,_0x1d274d){if(_0x57d4dc['is']('element','$text'))_0x1d274d['push']({'item':_0x57d4dc,'type':'text'});else{_0x57d4dc['is']('element')&&_0x1d274d['push']({'item':_0x57d4dc,'type':'elementStart'});for(const _0x2acfa0 of _0x57d4dc['getChildren']())this['_generateTape'](_0x2acfa0,_0x1d274d);_0x57d4dc['is']('element')&&_0x1d274d['push']({'item':_0x57d4dc,'type':'elementEnd'});}return _0x1d274d;}['_getState'](){const _0x522624=new Map(this['_touched']),_0x32140e=new Map(_0x522624),_0x5be447=new Map(),_0x3b3eea={'insertions':{},'deletions':{}},_0x3db275={'insertions':{},'deletions':{}},_0x1b9ab1=new Map(),_0x2a4d01=new Set([...this['_baseRoots']['keys'](),...this['_diffRoots']['keys']()]);_0x2a4d01['delete']('$graveyard');for(const _0x3f0058 of _0x2a4d01){const _0x13f0ac=this['_diffRoots']['get'](_0x3f0058)||F(_0x3f0058,!0x1),_0x429b45=this['_baseRoots']['get'](_0x3f0058)||F(_0x3f0058,!0x1);_0x13f0ac['isAttached']()||_0x429b45['isAttached']()?(_0x3b3eea['insertions'][_0x3f0058]=T(_0x13f0ac),_0x3b3eea['deletions'][_0x3f0058]=T(_0x429b45),this['_copyMarkers'](_0x3b3eea['deletions'][_0x3f0058],_0x429b45),this['_copyMarkers'](_0x3b3eea['insertions'][_0x3f0058],_0x13f0ac),_0x3db275['insertions'][_0x3f0058]=this['_generateTape'](this['_idsRoots']['get'](_0x3f0058),[]),_0x3db275['deletions'][_0x3f0058]=this['_generateTape'](this['_baseIdsRoots']['get'](_0x3f0058)||F(_0x3f0058,!0x1),[])):_0x2a4d01['delete'](_0x3f0058);}for(const _0x409610 of _0x2a4d01){const _0x30bfb8=_0x3db275['insertions'][_0x409610];for(const _0x257fab of _0x30bfb8){const _0x234371=this['_getVidAttributeName'](_0x257fab),_0x4ca88d=_0x257fab['item']['getAttribute'](_0x234371);_0x32140e['delete'](_0x4ca88d),_0x4ca88d>=this['_startingRevisionId']&&_0x5be447['set'](_0x4ca88d,_0x522624['get'](_0x4ca88d));}}for(const _0x39eba6 of _0x2a4d01){const _0xf016a1=_0x3db275['insertions'][_0x39eba6],_0x4b7b6e=this['_getBaseVids'](_0x3db275['deletions'][_0x39eba6]);let _0x15f395=0x0;for(const _0x370b7f of _0xf016a1){const _0x4e44b3=this['_getVidAttributeName'](_0x370b7f),_0x1f98ca=_0x370b7f['item']['getAttribute'](_0x4e44b3);if(!_0x5be447['has'](_0x1f98ca)&&!_0x1b9ab1['has'](_0x1f98ca)){if(_0x32140e['has'](_0x1f98ca))_0x15f395++;else{if(_0x1f98ca!=_0x4b7b6e[_0x15f395]){const _0x22cd0b=_0x522624['get'](_0x1f98ca)||_0x522624['get'](_0x4b7b6e[_0x15f395]);for(;_0x1f98ca!=_0x4b7b6e[_0x15f395];)_0x32140e['has'](_0x4b7b6e[_0x15f395])||(_0x1b9ab1['set'](_0x4b7b6e[_0x15f395],_0x22cd0b),_0x522624['set'](_0x4b7b6e[_0x15f395],_0x22cd0b)),_0x15f395++;}_0x15f395++;}}}}for(const _0x42a79c of _0x2a4d01){const _0x59baa0=_0x3db275['insertions'][_0x42a79c];for(const _0x37fe81 of _0x59baa0){const _0x43cb63=this['_getVidAttributeName'](_0x37fe81),_0x55c7c4=_0x37fe81['item']['getAttribute'](_0x43cb63);if(_0x1b9ab1['has'](_0x55c7c4)){const _0x19407c=_0x1b9ab1['get'](_0x55c7c4);_0x32140e['has'](_0x55c7c4)||_0x32140e['set'](_0x55c7c4,{..._0x19407c}),_0x5be447['set'](_0x55c7c4,{..._0x19407c});}}}for(const _0x45f97f of _0x32140e['keys']())_0x45f97f>=this['_startingRevisionId']&&_0x32140e['delete'](_0x45f97f);const _0x57d719=new Map();for(const _0x4a6d08 of _0x2a4d01){let _0x1ba377=_0x3db275['insertions'][_0x4a6d08];for(const _0x1f0bca of _0x1ba377)if(_0x1f0bca['item']['is']('element','tableCell')){const _0x2e73a4=this['_getVidAttributeName'](_0x1f0bca),_0x4f0c4f=_0x1f0bca['item']['getAttribute'](_0x2e73a4);if(_0x5be447['has'](_0x4f0c4f)){const _0x3c7e0b=_0x1f0bca['item']['parent']['parent']['getAttribute']('vid_start'),_0x1a15b7=_0x57d719['get'](_0x3c7e0b)||new Set();_0x1a15b7['add'](_0x5be447['get'](_0x4f0c4f)['userId']),_0x57d719['set'](_0x3c7e0b,_0x1a15b7);}}_0x1ba377=_0x3db275['deletions'][_0x4a6d08];for(const _0x14c6d6 of _0x1ba377)if(_0x14c6d6['item']['is']('element','tableCell')){const _0x5f303b=this['_getVidAttributeName'](_0x14c6d6),_0x7f44f=_0x14c6d6['item']['getAttribute'](_0x5f303b);if(_0x32140e['has'](_0x7f44f)){const _0x533a4a=_0x14c6d6['item']['parent']['parent']['getAttribute']('vid_start'),_0x30bba0=_0x57d719['get'](_0x533a4a)||new Set();_0x30bba0['add'](_0x32140e['get'](_0x7f44f)['userId']),_0x57d719['set'](_0x533a4a,_0x30bba0);}}for(const _0x4f9969 of _0x57d719['keys']())(_0x5be447['has'](_0x4f9969)||_0x32140e['has'](_0x4f9969))&&_0x57d719['delete'](_0x4f9969);}for(const _0x390e82 of _0x2a4d01){const _0x568e21=_0x3db275['insertions'][_0x390e82];let _0x3d5689=null,_0x51ad42=null;for(const _0x2e2720 of _0x568e21){const _0x469a02=this['_getVidAttributeName'](_0x2e2720),_0x314a72=_0x2e2720['item']['getAttribute'](_0x469a02),_0x27306f=_0x57d719['get'](_0x314a72);_0x27306f&&'elementStart'==_0x2e2720['type']&&(_0x3d5689=Array['from'](_0x27306f)[0x0],_0x51ad42=_0x2e2720['item']['getAttribute']('vid_end')),_0x3d5689&&(_0x32140e['set'](_0x314a72,{'userId':_0x3d5689}),_0x5be447['set'](_0x314a72,{'userId':_0x3d5689})),_0x314a72==_0x51ad42&&(_0x3d5689=null,_0x51ad42=null);}}const _0x9d81c9={},_0x2ef3e1=new Set();for(const _0x534f57 of _0x2a4d01){const _0x4b6cc3=_0x3b3eea['deletions'][_0x534f57],_0x46960d=_0x3b3eea['insertions'][_0x534f57];for(const {userId:_0x434fad}of this['_touchedMarkers']['values']())null!==_0x434fad&&_0x2ef3e1['add'](_0x434fad);for(const {userId:_0x1cf523}of this['_touchedRoots']['values']())null!==_0x1cf523&&_0x2ef3e1['add'](_0x1cf523);this['_markChanges'](_0x46960d,_0x3db275['insertions'][_0x534f57],_0x5be447,'insertion',_0x2ef3e1),this['_markChanges'](_0x4b6cc3,_0x3db275['deletions'][_0x534f57],_0x32140e,'deletion',_0x2ef3e1),_0x9d81c9[_0x534f57]={'insertions':this['_prepareViewToSave'](_0x46960d),'deletions':this['_prepareViewToSave'](_0x4b6cc3),'attachChange':this['_touchedRoots']['get'](_0x534f57)||null,'attributesBefore':_0x127b89(this['_baseRootsAttributes']['get'](_0x534f57))||{},'attributesAfter':_0x127b89(this['_diffRootsAttributes']['get'](_0x534f57))};}return{'diffData':_0x9d81c9,'authorsIds':Array['from'](_0x2ef3e1)};}['_processRootBeforeSave'](_0x43c534){for(const [,_0x1632e9]of _0x43c534['markers']){const _0x1f9ba7=_0x1632e9['start']['getAncestors']()['filter'](_0x11da11=>'tableCell'==_0x11da11['name']);for(const _0x1ebcef of _0x1f9ba7)0x1==_0x1ebcef['childCount']&&_0x1ebcef['getChild'](0x0)['is']('element','paragraph')&&_0x1ebcef['getChild'](0x0)['_setAttribute']('keepParagraph',!0x0);}}['_prepareViewToSave'](_0x274fe4){this['_processRootBeforeSave'](_0x274fe4);const _0x19e4ea=this['editor']['data']['toView'](_0x274fe4,{}),_0x135d24=Array['from'](_0x19e4ea['getChildren']())['map'](_0x10269c=>this['_getViewJson'](_0x10269c));return JSON['stringify'](_0x135d24);}['_getViewJson'](_0x31071d){if(_0x31071d['is']('$text'))return _0x31071d['data'];{const _0x561fa0=_0x31071d;return{'type':Object['keys'](E)['find'](_0x254bec=>_0x31071d instanceof E[_0x254bec]),'name':_0x561fa0['name'],'attributes':Array['from'](_0x561fa0['getAttributes']()),'children':Array['from'](_0x561fa0['getChildren']())['map'](_0x3a9898=>this['_getViewJson'](_0x3a9898))};}}['_markChanges'](_0x1b04a5,_0x25c8f7,_0x447e8e,_0x3fc7ed,_0xe6da8d){let _0x57da1f=null,_0x145da8=null,_0x39994a=0x0;const _0x5d402e=this['editor']['model'];for(let _0x3b6ca7=0x0;_0x3b6ca7<_0x25c8f7['length'];_0x3b6ca7++){const _0xd6c845=this['_getVidAttributeName'](_0x25c8f7[_0x3b6ca7]),_0x5865ce=_0x25c8f7[_0x3b6ca7]['item']['getAttribute'](_0xd6c845),_0x2c4b2c=_0x447e8e['get'](_0x5865ce),_0x398490=_0x3b6ca7==_0x25c8f7['length']-0x1;(!_0x57da1f&&_0x2c4b2c&&(_0x57da1f=_0x2c4b2c,_0x145da8=_0x25c8f7[_0x3b6ca7]),_0x57da1f&&(!_0x2c4b2c||_0x2c4b2c['userId']!=_0x57da1f['userId']))&&(_0x477485(_0x2c4b2c,B(_0x145da8,_0x1b04a5,_0x5d402e),B(_0x25c8f7[_0x3b6ca7],_0x1b04a5,_0x5d402e)),_0x57da1f=_0x2c4b2c||null,_0x145da8=_0x2c4b2c?_0x25c8f7[_0x3b6ca7]:null),_0x57da1f&&_0x398490&&_0x477485(_0x2c4b2c,B(_0x145da8,_0x1b04a5,_0x5d402e),J(_0x25c8f7[_0x3b6ca7],_0x1b04a5,_0x5d402e));}function _0x477485(_0x2e0bdf,_0x3cb92d,_0x34c80d){const _0x84d81=_0x57da1f['userId'],_0x5ba24c='revision:'+_0x3fc7ed+':'+_0x84d81+':'+_0x39994a++,_0x33685d=_0x5d402e['createRange'](_0x3cb92d,_0x34c80d);_0x1b04a5['markers']['set'](_0x5ba24c,_0x33685d),null!==_0x84d81&&_0xe6da8d['add'](_0x84d81);}}['_getVidAttributeName'](_0x12f727){switch(_0x12f727['type']){case'elementStart':return'vid_start';case'elementEnd':return'vid_end';default:return'vid';}}['_fixOperation'](_0x139156,_0x33424c){_0x139156['baseVersion']=null;for(const _0x37a644 in _0x139156){const _0x4bbcd1=_0x139156[_0x37a644];if(_0x4bbcd1 instanceof vt){const _0x302a84=_0x33424c['get'](_0x4bbcd1['root']['rootName']);_0x139156[_0x37a644]=this['_fixPosition'](_0x4bbcd1,_0x302a84);}if(_0x4bbcd1 instanceof ft){const _0x16357c=_0x33424c['get'](_0x4bbcd1['root']['rootName']);_0x139156[_0x37a644]=this['_fixRange'](_0x4bbcd1,_0x16357c);}'root'===_0x37a644&&(_0x139156['root']=_0x33424c['get'](_0x139156['root']['rootName']));}}['_fixRange'](_0x4d2a8b,_0x53e292){return this['editor']['model']['createRange'](this['_fixPosition'](_0x4d2a8b['start'],_0x53e292),this['_fixPosition'](_0x4d2a8b['end'],_0x53e292));}['_fixPosition'](_0x20e996,_0x4ab0bb){return this['editor']['model']['createPositionFromPath'](_0x4ab0bb,_0x20e996['path'],_0x20e996['stickiness']);}['_handleInsertOperation'](_0x587d87){const _0x1c3e45=this['_idsRoots']['get'](_0x587d87['position']['root']['rootName']),_0x4f2e3d=this['_fixPosition'](_0x587d87['position'],_0x1c3e45),_0x4d5ff4=null===_0x587d87['_authorId']?null:_0x587d87['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x3779d5=_0x4f2e3d['parent'],_0x363fe2=this['_revisionId'],_0x1b98f1=[];for(const _0x38e8cc of _0x587d87['nodes'])if(_0x38e8cc['is']('element'))_0x1b98f1['push'](this['_makeIdsRoot'](_0x38e8cc));else{for(let _0x13637f=0x0;_0x13637f<_0x38e8cc['offsetSize'];_0x13637f++)_0x1b98f1['push'](new ut('$text',{'vid':this['_revisionId']++}));}const _0xb3d7fd=this['_revisionId'];for(let _0x533051=_0x363fe2;_0x533051<_0xb3d7fd;_0x533051++)this['_touched']['set'](_0x533051,{'userId':_0x4d5ff4});_0x3779d5['_insertChild'](_0x4f2e3d['offset'],_0x1b98f1);}['_handleMoveOperation'](_0x6c2c0d){(_0x6c2c0d=this['_cloneOperation'](_0x6c2c0d,this['_idsRoots']))['_execute']();const _0x422baf=null===_0x6c2c0d['_authorId']?null:_0x6c2c0d['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x37af31=_0x6c2c0d['getMovedRangeStart'](),_0x3eff40=_0x37af31['parent'],_0x33d9fe=_0x37af31['offset'];!function _0x51a11d(_0x4bce6d,_0x298fd9,_0x16015b,_0x22245c){for(let _0x2c99d1=_0x16015b;_0x2c99d1<_0x22245c;_0x2c99d1++){const _0x5216c7=_0x298fd9['getChild'](_0x2c99d1);_0x5216c7['is']('element','$text')?_0x4bce6d['set'](_0x5216c7['getAttribute']('vid'),{'userId':_0x422baf}):(_0x4bce6d['set'](_0x5216c7['getAttribute']('vid_start'),{'userId':_0x422baf}),_0x51a11d(_0x4bce6d,_0x5216c7,0x0,_0x5216c7['childCount']),_0x4bce6d['set'](_0x5216c7['getAttribute']('vid_end'),{'userId':_0x422baf}));}}(this['_touched'],_0x3eff40,_0x33d9fe,_0x33d9fe+_0x6c2c0d['howMany']);}['_handleMergeOperation'](_0x32d846){const _0x587368=null===(_0x32d846=this['_cloneOperation'](_0x32d846,this['_idsRoots']))['_authorId']?null:_0x32d846['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x16e719=_0x32d846['targetPosition']['parent'],_0x2ae087=_0x32d846['sourcePosition']['parent'],_0x206ecb=_0x16e719['getAttribute']('vid_end'),_0x59d00b=_0x2ae087['getAttribute']('vid_start');_0x16e719['_setAttribute']('vid_end',_0x2ae087['getAttribute']('vid_end')),_0x2ae087['_setAttribute']('vid_end',_0x206ecb),this['_touched']['set'](_0x59d00b,{'userId':_0x587368}),this['_touched']['set'](_0x206ecb,{'userId':_0x587368}),_0x32d846['_execute']();}['_handleSplitOperation'](_0x2dde5b){const _0x57fc9a=null===(_0x2dde5b=this['_cloneOperation'](_0x2dde5b,this['_idsRoots']))['_authorId']?null:_0x2dde5b['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x546786=_0x2dde5b['graveyardPosition'],_0x2eeebe=_0x2dde5b['splitPosition']['parent'];_0x2dde5b['_execute']();const _0xa90907=_0x2eeebe['getAttribute']('vid_end'),_0x22ad2f=_0x2dde5b['insertionPosition']['nodeAfter'];if(_0x546786){const _0x3ebe85=_0x22ad2f['getAttribute']('vid_end'),_0x45d46e=_0x2eeebe['getAttribute']('vid_end');_0x2eeebe['_setAttribute']('vid_end',_0x3ebe85),_0x22ad2f['_setAttribute']('vid_end',_0x45d46e),this['_touched']['set'](_0x2eeebe['getAttribute']('vid_end'),{'userId':_0x57fc9a}),this['_touched']['set'](_0x22ad2f['getAttribute']('vid_start'),{'userId':_0x57fc9a});}else{const _0x47f8a2=this['_revisionId']++,_0x22eb04=this['_revisionId']++;_0x2eeebe['_setAttribute']('vid_end',_0x47f8a2),_0x22ad2f['_setAttribute']('vid_start',_0x22eb04),_0x22ad2f['_setAttribute']('vid_end',_0xa90907),this['_touched']['set'](_0x47f8a2,{'userId':_0x57fc9a}),this['_touched']['set'](_0x22eb04,{'userId':_0x57fc9a});}}['_handleMarkerOperation'](_0x397dbb){if(!_0x397dbb['affectsData'])return;const _0x18636b=(_0x397dbb=this['_cloneOperation'](_0x397dbb,this['_diffRoots']))['oldRange']?_0x397dbb['oldRange']['root']:null,_0x2465a1=_0x397dbb['newRange']?_0x397dbb['newRange']['root']:null;_0x18636b&&this['_markers']['delete'](_0x397dbb['name']),_0x2465a1&&this['_markers']['set'](_0x397dbb['name'],_0x397dbb['newRange']['clone']());const _0x2d4665=null===_0x397dbb['_authorId']?null:_0x397dbb['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x4bf15b=_0x397dbb['name'];if(!this['_touchedMarkers']['has'](_0x4bf15b))return void this['_touchedMarkers']['set'](_0x4bf15b,{'range':_0x397dbb['oldRange'],'userId':_0x2d4665});const _0xeb88c6=this['_touchedMarkers']['get'](_0x4bf15b),_0x47a78d=_0xeb88c6['range'],_0x520e59=_0x397dbb['newRange'];null==_0x47a78d&&null==_0x520e59||_0x47a78d&&_0x520e59&&_0x47a78d['isEqual'](_0x520e59)?this['_touchedMarkers']['delete'](_0x397dbb['name']):_0xeb88c6['userId']=_0x2d4665;}['_handleRootOperation'](_0x1ef46a,_0x3248af){this['_diffRoots']['has'](_0x1ef46a['rootName'])?this['_diffRoots']['get'](_0x1ef46a['rootName'])['_isAttached']=_0x1ef46a['isAdd']:(this['_diffRoots']['set'](_0x1ef46a['rootName'],F(_0x1ef46a['rootName'],!0x0)),this['_diffRootsAttributes']['set'](_0x1ef46a['rootName'],{}),_0x3248af&&this['_idsRoots']['set'](_0x1ef46a['rootName'],F(_0x1ef46a['rootName'],!0x0)));const _0xe37b38=null===_0x1ef46a['_authorId']?null:_0x1ef46a['_authorId']||this['editor']['plugins']['get']('Users')['me']['id'],_0x25a9aa=this['_touchedRoots']['get'](_0x1ef46a['rootName']);_0x25a9aa&&_0x25a9aa['userId']===_0xe37b38?this['_touchedRoots']['delete'](_0x1ef46a['rootName']):this['_touchedRoots']['set'](_0x1ef46a['rootName'],{'userId':_0xe37b38,'isAttached':_0x1ef46a['isAdd']});}['_handleRootAttributeOperation'](_0x8320){const _0x2f9a8f=this['_diffRootsAttributes']['get'](_0x8320['root']['rootName']);null===_0x8320['newValue']?delete _0x2f9a8f[_0x8320['key']]:_0x2f9a8f[_0x8320['key']]=_0x8320['newValue'];}}function T(_0x376178){const _0x1973d1=F(_0x376178['rootName'],_0x376178['isAttached']());for(const _0x5a02f8 of _0x376178['getChildren']()){const _0x2ae82b=_0x5a02f8['_clone'](!0x0);_0x1973d1['_appendChild'](_0x2ae82b);}return _0x1973d1;}function F(_0xf57d82,_0x14bec7=!0x0){const _0x4cb516=new gt();return _0x4cb516['rootName']=_0xf57d82,_0x4cb516['_isAttached']=_0x14bec7,_0x4cb516['isAttached']=()=>_0x4cb516['_isAttached'],_0x4cb516;}function B(_0xc5521d,_0x3275b8,_0x1cbc41){const _0x44a821='elementEnd'==_0xc5521d['type']?_0x1cbc41['createPositionAt'](_0xc5521d['item'],'end'):_0x1cbc41['createPositionBefore'](_0xc5521d['item']);return _0x1cbc41['createPositionFromPath'](_0x3275b8,_0x44a821['path'],_0x44a821['stickiness']);}function J(_0x4a33ec,_0x18a153,_0x7b850b){const _0x3a2153='elementStart'==_0x4a33ec['type']?_0x7b850b['createPositionAt'](_0x4a33ec['item'],0x0):_0x7b850b['createPositionAfter'](_0x4a33ec['item']);return _0x7b850b['createPositionFromPath'](_0x18a153,_0x3a2153['path'],_0x3a2153['stickiness']);}class hs extends ts{['focusTracker'];['keystrokes'];['revisionNameInputView'];constructor(_0x33586c,_0x5c2e83){super(_0x33586c),this['focusTracker']=new _0x2ebb35(),this['keystrokes']=new _0x5c3c3a(),this['set']('revisionNameInputValue',''),this['revisionNameInputView']=this['_createRevisionNameInput'](_0x5c2e83),this['setTemplate']({'tag':'form','attributes':{'class':['ck','ck-revision-history-save-revision-form','ck-responsive-form'],'tabindex':'-1'},'children':[this['revisionNameInputView']]}),_0x25c145(this);}['render'](){super['render'](),_0x4c2b40({'view':this}),this['focusTracker']['add'](this['revisionNameInputView']['element']),this['keystrokes']['listenTo'](this['element']);const _0x52aa48=_0x17fa9e=>_0x17fa9e['stopPropagation']();this['keystrokes']['set']('arrowright',_0x52aa48),this['keystrokes']['set']('arrowleft',_0x52aa48),this['keystrokes']['set']('arrowup',_0x52aa48),this['keystrokes']['set']('arrowdown',_0x52aa48);}['focus'](){this['revisionNameInputView']['focus']();}get['revisionName'](){return this['revisionNameInputView']['fieldView']['element']['value']['trim']();}set['revisionName'](_0x375ae4){this['revisionNameInputView']['fieldView']['element']['value']=_0x375ae4['trim']();}['reset'](){this['revisionNameInputView']['fieldView']['element']['value']='',this['revisionNameInputView']['errorText']=null;}['_createRevisionNameInput'](_0x43aa1a){const _0x5ccea7=new _0x3f0de8(this['locale'],_0x153297),_0x2e0de1=_0x5ccea7['fieldView'];_0x2e0de1['extendTemplate']({'attributes':{'maxlength':'220'}});let _0x47aac3=m(this['locale'],'Name\x20of\x20the\x20revision');return!_0x43aa1a&&(_0x47aac3+='\x20('+m(this['locale'],'optional')+')'),(_0x5ccea7['label']=_0x47aac3,_0x2e0de1['on']('input',()=>{this['revisionNameInputValue']=_0x2e0de1['element']['value']['trim']();}),_0x5ccea7);}}class f extends _0x118fc5{static get['pluginName'](){return'RevisionHistoryUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u];}['_saveRevisionFormView'];['init'](){const _0x4de00c=this['editor'],_0x1e658e=_0x4de00c['plugins']['get']('RevisionTracker');_0x4de00c['ui']['componentFactory']['add']('revisionHistory',_0x205f9b=>{const _0x9538e=_0x243ed3(_0x205f9b),_0x567f56=_0x9538e['panelView']['children'],_0x4b9501=new _0x2ac408(_0x205f9b),_0x49703d=new _0x1f298a(_0x205f9b),_0x1bcabe=new te(_0x205f9b),_0x51e2e5=new _0x1f298a(_0x205f9b),_0x2e796e=new te(_0x205f9b);return _0x9538e['bind']('isEnabled')['to'](_0x1e658e,'isReady',_0x1e658e,'isEnabled',_0x4de00c,'isReadOnly',(_0x36f651,_0x4a5b55,_0x332599)=>_0x36f651&&_0x4a5b55&&!_0x332599),_0x9538e['buttonView']['set']({'icon':_0x4709ad,'label':m(_0x205f9b,'Revision\x20history'),'tooltip':!0x0}),_0x1bcabe['set']({'label':m(_0x205f9b,'Save\x20current\x20revision'),'withText':!0x0,'role':'menuitem'}),_0x1bcabe['bind']('isEnabled')['to'](_0x1e658e,'isReady',_0x1e658e,'isEnabled',_0x4de00c,'isReadOnly',(_0x12112e,_0xb26e0e,_0x41f362)=>_0x12112e&&_0xb26e0e&&!_0x41f362),_0x1bcabe['on']('execute',()=>this['_showDialog']()),_0x2e796e['set']({'label':m(_0x205f9b,'Open\x20revision\x20history'),'withText':!0x0,'role':'menuitem'}),_0x2e796e['bind']('isEnabled')['to'](_0x1e658e,'isReady',_0x4de00c,'isReadOnly',(_0x40973b,_0x2d6a81)=>_0x40973b&&!_0x2d6a81),_0x2e796e['on']('execute',()=>{_0x4de00c['config']['get']('revisionHistory')['showRevisionViewerCallback'](),_0x9538e['isOpen']=!0x1,_0x4de00c['editing']['view']['focus']();}),_0x49703d['children']['add'](_0x1bcabe),_0x51e2e5['children']['add'](_0x2e796e),_0x4b9501['role']='menu',_0x4b9501['items']['addMany']([_0x49703d,_0x51e2e5]),_0x567f56['add'](_0x4b9501),_0x9538e;}),_0x4de00c['ui']['componentFactory']['add']('menuBar:revisionHistory',()=>this['_registerMenuComponent']());}['_registerMenuComponent'](){const _0x4cdad8=this['editor'],_0x3737be=_0x4cdad8['locale'],_0xe09965=new _0x361888(_0x3737be),_0x14d10e=new _0xb5534c(_0x3737be);_0xe09965['buttonView']['set']({'icon':_0x4709ad,'label':m(_0x3737be,'Revision\x20history')});const _0x57b807=new _0x11fa25(_0x3737be,_0xe09965),_0x4d7a4b=new _0x5d5452(_0x3737be);_0x4d7a4b['set']({'label':m(_0x3737be,'Save\x20current\x20revision')}),_0x4d7a4b['delegate']('execute')['to'](_0xe09965),_0x4d7a4b['on']('execute',()=>{this['_showDialog']();}),_0x57b807['children']['add'](_0x4d7a4b),_0x14d10e['items']['add'](_0x57b807);const _0x311efd=new _0x11fa25(_0x3737be,_0xe09965),_0x221148=new _0x5d5452(_0x3737be);return _0x221148['set']({'label':m(_0x3737be,'Open\x20revision\x20history')}),_0x221148['delegate']('execute')['to'](_0xe09965),_0x221148['on']('execute',()=>{_0x4cdad8['config']['get']('revisionHistory')['showRevisionViewerCallback']();}),_0x311efd['children']['add'](_0x221148),_0x14d10e['items']['add'](_0x311efd),_0xe09965['panelView']['children']['add'](_0x14d10e),_0xe09965;}['_showDialog'](){const _0x15fedb=this['editor'],_0x54b5f0=_0x15fedb['locale'],_0x8c7efc=_0x15fedb['plugins']['get']('Dialog'),_0x3ee69c=_0x15fedb['plugins']['get']('RevisionTracker');function _0x33ae39(_0x251dab){_0x15fedb['config']['get']('revisionHistory.requireRevisionName')&&''===_0x251dab['revisionName']?_0x251dab['revisionNameInputView']['errorText']=m(_0x54b5f0,'The\x20revision\x20name\x20cannot\x20be\x20empty.'):(_0x15fedb['plugins']['get'](u)['saveRevision']({'name':_0x251dab['revisionName']}),_0x8c7efc['hide']());}this['_saveRevisionFormView']||(this['_createSaveRevisionFormView'](),this['_saveRevisionFormView']['on']('submit',()=>_0x33ae39(this['_saveRevisionFormView']))),this['_saveRevisionFormView']['reset'](),_0x8c7efc['show']({'id':'revisionSave','title':m(_0x54b5f0,'Save\x20current\x20revision'),'isModal':!0x0,'content':this['_saveRevisionFormView'],'actionButtons':[{'label':m(_0x15fedb['locale'],'Cancel'),'withText':!0x0,'onExecute':()=>_0x8c7efc['hide']()},{'label':m(_0x15fedb['locale'],'Accept'),'class':'ck-button-action','withText':!0x0,'onCreate'(_0x5aa102){_0x5aa102['bind']('isEnabled')['to'](_0x3ee69c,'isReady',_0x3ee69c,'isEnabled',_0x15fedb,'isReadOnly',(_0x519e4f,_0x4e5d4,_0x384704)=>_0x519e4f&&_0x4e5d4&&!_0x384704);},'onExecute':()=>_0x33ae39(this['_saveRevisionFormView'])}]});}['_createSaveRevisionFormView'](){const _0x33f5eb=this['editor'],_0x1c7a41=_0x33f5eb['locale'];this['_saveRevisionFormView']=new hs(_0x1c7a41,_0x33f5eb['config']['get']('revisionHistory.requireRevisionName')),this['_saveRevisionFormView']['render']();}}class X extends ts{['changeId'];['_model'];constructor(_0x4670a9,_0x17d1e2){super(_0x4670a9),this['_model']=_0x17d1e2,this['changeId']=_0x17d1e2['id'];const _0x52193a=this['bindTemplate'],_0x21b75c=m(_0x4670a9,_0x17d1e2['data']['isSuggestion']?'Suggested\x20by':'add'==_0x17d1e2['type']?'Added\x20by':'Removed\x20by');this['set']('type',_0x17d1e2['type']),this['setTemplate']({'tag':'div','attributes':{'class':['ck-annotation','ck-revision-change',_0x52193a['to']('type',_0x1b4514=>'ck-revision-change__'+_0x1b4514)],'tabindex':-0x1},'children':[{'tag':'span','children':[{'tag':'span','attributes':{'class':['ck-revision-change__label']},'children':[{'text':_0x21b75c}]},{'text':'\x20'+_0x17d1e2['author']['name']}]}]});}['focus'](){this['element']['focus']();}}class r extends/* #__PURE__ -- @preserve */
25
+ _0x45caf0(){['id'];['author'];['type'];['data'];['rootName'];constructor(_0x5d23c1){super(),this['id']=_0x5d23c1['id']||_0x118080(),this['author']=_0x5d23c1['author'],this['type']=_0x5d23c1['type'],this['data']=_0x5d23c1['data']||{},this['rootName']=_0x5d23c1['rootName'],this['set']('createdAt',_0x5d23c1['createdAt']);}['toJSON'](){return{'id':this['id'],'authorId':this['author']['id'],'type':this['type'],'data':this['data'],'createdAt':this['createdAt']};}}class c{['newRevisionId'];['oldRevisionId'];['changes'];constructor(_0x26ca04,_0x4fe8b5){this['newRevisionId']=_0x26ca04,this['oldRevisionId']=_0x4fe8b5,this['changes']=new _0x3e452a();}['_setChanges'](_0x14f1e2){for(const _0x310066 of _0x14f1e2)this['changes']['add'](_0x310066);}}const Y={'c':_0x536437,'a':_0x51cef1,'e':_0x5d757a,'r':_0xd3a339,'u':_0x28565d};class d extends _0x118fc5{['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[_0x1120ef,_0x608ef,j];}constructor(_0x3997ac){super(_0x3997ac),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',(_0x41edfa,_0x303d04,_0x39b0a2)=>{this['activeChange']=null,this['activeView']=null,this['editor']['editing']['view']['change'](_0x4b47f8=>{for(const _0x4495e7 of this['editor']['editing']['view']['document']['roots'])_0x39b0a2?_0x4b47f8['removeClass']('ck-editor__editable__overlay',_0x4495e7):_0x4b47f8['addClass']('ck-editor__editable__overlay',_0x4495e7);});}),this['bind']('isNavigationMode')['to'](this,'activeChange',_0x5c575e=>null!==_0x5c575e),this['bind']('currentChangeNumber')['to'](this,'isReady',this,'diff',this,'activeChange',(_0x1b7bef,_0x1dbe55,_0x494d8e)=>_0x1b7bef&&_0x494d8e?_0x1dbe55['changes']['getIndex'](_0x494d8e):0x0),this['bind']('numberOfChanges')['to'](this,'isReady',this,'diff',(_0x56b2e7,_0x4a6cdd)=>_0x56b2e7?_0x4a6cdd['changes']['length']:0x0),this['_changeView']=null,this['_changeIdToChange']=new Map(),this['adapter']=null,this['_balloon']=this['editor']['plugins']['get'](_0x608ef);}['init'](){const _0x20304b=this['editor'],_0x1248ba=new _t(_0x20304b,{'direction':'backward'}),_0x36fc5a=new _t(_0x20304b,{'direction':'forward'});(_0x20304b['commands']['add']('showPreviousChange',_0x1248ba),_0x20304b['commands']['add']('showNextChange',_0x36fc5a),_0x20304b['commands']['add']('restoreRevision',new wt(_0x20304b)),this['on']('change:numberOfChanges',()=>{_0x1248ba['refresh'](),_0x36fc5a['refresh']();}),this['_setConversion'](),this['_initInteractions'](),_0x20304b['enableReadOnlyMode']('revision-viewer'),_0x20304b['plugins']['has']('WidgetToolbarRepository'))&&_0x20304b['plugins']['get']('WidgetToolbarRepository')['forceDisabled']('revision-viewer');}async['getRevisionData'](_0x5b28f5){await this['loadRevisionData'](_0x5b28f5);const _0x51e1e2={};for(const _0xff6cc1 in _0x5b28f5['diffData']){if(_0x5b28f5['diffData'][_0xff6cc1]['attachChange']&&!_0x5b28f5['diffData'][_0xff6cc1]['attachChange']['isAttached'])continue;const _0x2ac6c4=this['_removeRevisionMarkers'](JSON['parse'](_0x5b28f5['diffData'][_0xff6cc1]['insertions'])),_0x26f602=this['editor']['editing']['view']['document'],_0x1204cf=new _0x8157a(_0x26f602,_0x2ac6c4['map'](_0x5d76af=>this['_getViewObj'](_0x5d76af)));this['editor']['data']['processor']['useFillerType']('marked'),_0x51e1e2[_0xff6cc1]=this['editor']['data']['processor']['toData'](_0x1204cf),this['editor']['data']['processor']['useFillerType']('default');}return _0x51e1e2;}async['getRevisionRootsAttributes'](_0x3d9ed4){await this['loadRevisionData'](_0x3d9ed4);const _0x21503d={};for(const _0xec1b11 in _0x3d9ed4['diffData'])_0x3d9ed4['diffData'][_0xec1b11]['attachChange']&&!_0x3d9ed4['diffData'][_0xec1b11]['attachChange']['isAttached']||(_0x21503d[_0xec1b11]=_0x3d9ed4['diffData'][_0xec1b11]['attributesAfter']||{});return _0x21503d;}['_removeRevisionMarkers'](_0x447897){return(_0x447897=_0x447897['filter'](_0x5233ce=>!_0x5233ce['name']||'revision-start'!==_0x5233ce['name']&&'revision-end'!==_0x5233ce['name']))['forEach'](_0x57c281=>{'string'!=typeof _0x57c281&&(_0x57c281['children']=this['_removeRevisionMarkers'](_0x57c281['children']),_0x57c281['attributes']=_0x57c281['attributes']['filter'](_0x1951b5=>!_0x1951b5[0x0]['startsWith']('data-revision-')));}),_0x447897;}async['compare'](_0xa66f51,_0x347ed5,_0x2c76f3=!0x1){if(!this['isEnabled'])return;const _0x1f7102=this['diff'],_0x588479=this['repository'],_0x512acd='string'==typeof _0xa66f51?_0x588479['getRevision'](_0xa66f51):_0xa66f51,_0xdc5190='string'==typeof _0x347ed5?_0x588479['getRevision'](_0x347ed5):_0x347ed5,_0x18e89d=_0x512acd['id'],_0xa12ed8=_0xdc5190?_0xdc5190['id']:null;if(!_0x2c76f3&&this['diff']&&this['diff']['newRevisionId']===_0x18e89d&&this['diff']['oldRevisionId']===_0xa12ed8)return Promise['resolve']();this['isReady']=!0x1,this['activeView']=null,this['activeChange']=null,this['diff']=new c(_0x18e89d,_0xa12ed8);const _0x4b61be=this['_getRevisionsRange'](_0x512acd,_0xdc5190,!0x0)['map'](_0xb5bd06=>this['loadRevisionData'](_0xb5bd06));return _0x4b61be['push'](new Promise(_0x44e743=>{setTimeout(_0x44e743,0x14);})),Promise['all'](_0x4b61be)['then'](()=>{if(!this['isEnabled'])return;this['_cleanUp']();const _0x2d73c1=this['_getDiff'](_0x18e89d,_0xa12ed8);for(const _0x5c9751 of _0x2d73c1['changes'])this['_changeIdToChange']['set'](_0x5c9751['id'],_0x5c9751);this['editor']['model']['enqueueChange']({'isUndoable':!0x1},_0x32dc96=>{for(const _0x599656 of this['editor']['model']['document']['getRootNames']())_0x32dc96['detachRoot'](_0x599656);for(const _0xc337be of Object['keys'](_0x2d73c1['model'])){const _0x2c855b=_0x32dc96['addRoot'](_0xc337be);for(const _0x142a78 of Object['keys'](_0x2d73c1['attributes'][_0xc337be]))_0x32dc96['setAttribute'](_0x142a78,_0x2d73c1['attributes'][_0xc337be][_0x142a78],_0x2c855b);_0x32dc96['insert'](_0x2d73c1['model'][_0xc337be],_0x2c855b,0x0);}}),this['diff']['_setChanges'](this['_sortAndFilterDiffChanges'](_0x2d73c1['changes'])),this['isReady']=!0x0;})['catch'](_0x3d75b9=>{console['error'](_0x3d75b9),this['_cleanUp'](),_0x1f7102&&(this['diff']=_0x1f7102),this['isReady']=!0x0;});}['addRevisionData'](_0x535226,_0x479389){const _0x8344f=this['repository']['createRevision'](_0x535226);return _0x8344f['on']('_update',(_0x2d0bc6,_0x393e71,_0x1535da)=>_0x479389(_0x393e71,_0x1535da,_0x8344f)),this['repository']['addRevision'](_0x8344f),_0x8344f;}['loadRevisionData'](_0x2447b5){if(!_0x2447b5||_0x2447b5['diffData'])return Promise['resolve']();{const _0x57524b=this['editor']['config']['get']('collaboration.channelId');return this['adapter']['getRevision']({'channelId':_0x57524b,'revisionId':_0x2447b5['id']})['then'](_0x305edf=>{_0x2447b5['_update']({'diffData':_0x305edf['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},_0x4dd61b=>{for(const _0x18a6c6 of this['editor']['model']['document']['getRootNames']())_0x4dd61b['detachRoot'](_0x18a6c6);});}['_sortAndFilterDiffChanges'](_0x44630f){const _0x2d0bce=[],_0x2efdb7=new Map();for(const _0x581f42 of this['editor']['model']['document']['getRootNames']()){const _0x390ebf=this['editor']['editing']['view']['getDomRoot'](_0x581f42);if(!_0x390ebf)continue;const _0x1f2965=_0x390ebf['getClientRects']()['item'](0x0);_0x1f2965&&(_0x2d0bce['push'](_0x581f42),_0x2efdb7['set'](_0x581f42,_0x1f2965));}return _0x2d0bce['sort']((_0x16141d,_0x16b860)=>{const _0x5da890=_0x2efdb7['get'](_0x16141d),_0x1ddea0=_0x2efdb7['get'](_0x16b860);return _0x5da890['y']-_0x1ddea0['y']||_0x5da890['x']-_0x1ddea0['x'];}),(_0x44630f=_0x44630f['filter'](_0x507758=>_0x2d0bce['includes'](_0x507758['rootName'])))['sort']((_0x1f12c5,_0x3ce401)=>_0x2d0bce['indexOf'](_0x1f12c5['rootName'])-_0x2d0bce['indexOf'](_0x3ce401['rootName'])),_0x44630f;}['_makeTape'](_0x5d8698){const _0x1184a5=Array['from'](_0x5d8698['markers'])['filter'](([_0x3e467f,_0x18eace])=>_0x3e467f['startsWith']('revision:')&&!_0x18eace['isCollapsed']),_0xef6496=Array['from'](this['editor']['model']['createRangeIn'](_0x5d8698)['getWalker']({'singleCharacters':!0x0}));if(0x0!=_0x1184a5['length'])for(const _0x54884f of _0xef6496){const [_0x5f5384,_0x5c079e]=_0x1184a5[0x0],[,_0x52787d,_0x8cdb03]=_0x5f5384['split'](':');if(_0x5c079e['end']['isEqual'](_0x54884f['nextPosition'])&&_0x1184a5['shift'](),(_0x54884f['previousPosition']['isEqual'](_0x5c079e['start'])||_0x54884f['previousPosition']['isAfter'](_0x5c079e['start']))&&('insertion'==_0x52787d?_0x54884f['isAdded']={'userId':_0x8cdb03}:'deletion'==_0x52787d&&(_0x54884f['isRemoved']={'userId':_0x8cdb03})),0x0==_0x1184a5['length'])break;}return _0xef6496;}['_refreshStartEndIndex'](_0x38819b){const _0x5ec1aa=new Map();for(let _0x32e188=0x0;_0x32e188<_0x38819b['length'];_0x32e188++)'text'===_0x38819b[_0x32e188]['type']?(_0x38819b[_0x32e188]['item']['startIndex']=_0x32e188,_0x38819b[_0x32e188]['item']['endIndex']=_0x32e188):('elementStart'===_0x38819b[_0x32e188]['type']?_0x38819b[_0x32e188]['item']['startIndex']=_0x32e188:'elementEnd'===_0x38819b[_0x32e188]['type']&&(_0x38819b[_0x32e188]['item']['endIndex']=_0x32e188),_0x5ec1aa['set'](_0x38819b[_0x32e188]['id'],_0x32e188));for(const _0x20b13a of _0x5ec1aa['values']())'elementStart'===_0x38819b[_0x20b13a]['type']?_0x38819b[_0x20b13a]['item']['endIndex']=_0x5ec1aa['get'](_0x38819b[_0x20b13a]['pairId']):'elementEnd'===_0x38819b[_0x20b13a]['type']&&(_0x38819b[_0x20b13a]['item']['startIndex']=_0x5ec1aa['get'](_0x38819b[_0x20b13a]['pairId']));}['_processTape'](_0x33db9b){for(let _0x34ce3b=0x0;_0x34ce3b<_0x33db9b['length'];_0x34ce3b++){if('elementStart'===_0x33db9b[_0x34ce3b]['type'])_0x33db9b[_0x34ce3b]['item']['startIndex']=_0x34ce3b;else{if('elementEnd'===_0x33db9b[_0x34ce3b]['type']){_0x33db9b[_0x34ce3b]['item']['endIndex']=_0x34ce3b;const _0x3e9678=_0x33db9b[_0x34ce3b]['item']['startIndex'];_0x33db9b[_0x3e9678]['pairId']=_0x33db9b[_0x34ce3b]['id'],_0x33db9b[_0x34ce3b]['pairId']=_0x33db9b[_0x3e9678]['id'];}else _0x33db9b[_0x34ce3b]['item']['startIndex']=_0x34ce3b,_0x33db9b[_0x34ce3b]['item']['endIndex']=_0x34ce3b,_0x33db9b[_0x34ce3b]['pairId']=null;}_0x33db9b[_0x34ce3b]['markersStart']||(_0x33db9b[_0x34ce3b]['markersStart']=[],_0x33db9b[_0x34ce3b]['markersEnd']=[]);}}['_markInsertions'](_0x4620c9,_0x10f624){const _0x511ea0=_0x4620c9['filter'](_0x427155=>!_0x427155['isAdded']);for(let _0x39486c=0x0;_0x39486c<_0x10f624['length'];_0x39486c++)_0x10f624[_0x39486c]['isAdded']&&(_0x511ea0[_0x39486c]['isAdded']=_0x10f624[_0x39486c]['isAdded']);}['_makeModelFromViewString'](_0xd6acfb){const _0x362e45=JSON['parse'](_0xd6acfb),_0x4e25ad=this['editor']['editing']['view']['document'],_0xf9822e=new _0x8157a(_0x4e25ad,_0x362e45['map'](_0x3f0388=>this['_getViewObj'](_0x3f0388)));return this['editor']['data']['toModel'](_0xf9822e);}['_getViewObj'](_0x51edce){const _0x5a83a2=this['editor']['editing']['view']['document'];if('string'==typeof _0x51edce)return new _0x1b404c(_0x5a83a2,_0x51edce);{const _0x3df86e=_0x51edce['children']['map'](_0x386d55=>this['_getViewObj'](_0x386d55));return new(Y[_0x51edce['type']]||_0x34db6a)(_0x5a83a2,_0x51edce['name'],_0x51edce['attributes'],_0x3df86e);}}['_getDiff'](_0x132b2,_0x427375=null){const _0x66f536=this['repository']['getRevision'](_0x132b2),_0x470ec4=_0x427375?this['repository']['getRevision'](_0x427375):null,_0x374136=this['_getRevisionsRange'](_0x66f536,_0x470ec4),_0x2b81d5=_0x374136[_0x374136['length']-0x1],_0x300d82=new Map(),_0x271946={'model':{},'attributes':{},'changes':[]},_0x34beb4=new Set(),_0xe5a273=new Map();for(let _0x52c58f=_0x374136['length']-0x1;_0x52c58f>=0x0;_0x52c58f--){const _0x5823c1=_0x374136[_0x52c58f];for(const _0x432b2a of Object['keys'](_0x5823c1['diffData']))if(_0x5823c1['diffData'][_0x432b2a]['attachChange']){const _0xe09d31=_0x5823c1['diffData'][_0x432b2a]['attachChange'];_0xe09d31['isAttached']?(_0x34beb4['add'](_0x432b2a),_0xe5a273['has'](_0x432b2a)&&_0xe5a273['get'](_0x432b2a)['userId']==_0xe09d31['userId']?_0xe5a273['delete'](_0x432b2a):_0xe5a273['set'](_0x432b2a,_0xe09d31)):_0xe5a273['has'](_0x432b2a)?(_0x34beb4['delete'](_0x432b2a),_0xe5a273['delete'](_0x432b2a)):(_0x34beb4['add'](_0x432b2a),_0xe5a273['set'](_0x432b2a,_0xe09d31));}else _0x34beb4['add'](_0x432b2a);}for(const _0x2556a2 of _0x34beb4){const _0x3954c2=_0xe5a273['has'](_0x2556a2)&&!_0xe5a273['get'](_0x2556a2)['isAttached'];let _0x4e528f=_0x3954c2?_0x374136['length']-0x1:0x0;const _0x339b1e=_0x3954c2?-0x1:0x1;for(;_0x374136[_0x4e528f];){const _0x222020=_0x374136[_0x4e528f];if(_0x222020['diffData'][_0x2556a2]){const _0x253e15=_0x3954c2?_0x222020['diffData'][_0x2556a2]['attributesBefore']:_0x222020['diffData'][_0x2556a2]['attributesAfter'];_0x271946['attributes'][_0x2556a2]=_0x253e15?_0x127b89(_0x253e15):{};break;}_0x4e528f+=_0x339b1e;}}for(const _0x48f9c7 of _0x374136){_0x48f9c7['model']={};for(const _0x22116e of _0x48f9c7['authors'])_0x300d82['set'](_0x22116e['id'],_0x22116e);for(const _0x3dec94 of _0x34beb4){const _0x452553=_0x48f9c7['diffData'][_0x3dec94]?_0x48f9c7['diffData'][_0x3dec94]['insertions']:'[]',_0x48489b=_0x48f9c7['diffData'][_0x3dec94]?_0x48f9c7['diffData'][_0x3dec94]['deletions']:'[]';_0x48f9c7['model'][_0x3dec94]={'insertions':this['_makeModelFromViewString'](_0x452553),'deletions':this['_makeModelFromViewString'](_0x48489b)};}}for(const _0x335ddd of _0x34beb4){let _0xa5a202=null,_0x178024=0x0;const _0x269442=new Map(Array['from'](_0x66f536['model'][_0x335ddd]['insertions']['markers'])['filter'](([_0x3090a1])=>!_0x3090a1['startsWith']('revision:')));let _0x451460=0x0;for(const _0x423610 of _0x374136){const _0x1de919=this['_makeTape'](_0x423610['model'][_0x335ddd]['insertions']);_0x423610==_0x66f536?(_0xa5a202=_0x1de919,_0x178024=_0xa5a202['length'],_0xa5a202['forEach'](_0x49996a=>{_0x49996a['id']=_0x451460++;}),this['_processTape'](_0xa5a202)):this['_markInsertions'](_0xa5a202,_0x1de919);const _0x3da1ec=_0xa5a202['filter'](_0x1389c6=>!_0x1389c6['isAdded'])['map'](_0x195628=>_0x195628['id']);let _0x5bc593=0x0;const _0x31817f=this['_makeTape'](_0x423610['model'][_0x335ddd]['deletions']);_0x31817f['forEach'](_0x498ede=>{_0x498ede['isRemoved']?_0x498ede['id']=_0x178024++:_0x498ede['id']=_0x3da1ec[_0x5bc593++];}),this['_processTape'](_0x31817f),this['_setDistance'](_0xa5a202,'isAdded'),this['_setDistance'](_0x31817f,'isRemoved'),_0x423610==_0x66f536&&this['_markMarkers'](_0xa5a202,_0x269442),_0xa5a202=this['_joinTapes'](_0xa5a202,_0x31817f),this['_refreshStartEndIndex'](_0xa5a202),this['_setDistance'](_0xa5a202,'isRemoved');}_0xa5a202=_0xa5a202['filter'](_0x187445=>!(_0x187445['isAdded']&&_0x187445['isRemoved']));const _0x4c12c2=new Map(_0x2b81d5['model'][_0x335ddd]['deletions']['markers']),_0x2658b5=new Set(_0x269442['keys']());for(const _0x9680db of _0x4c12c2['keys']())_0x2658b5['delete'](_0x9680db);this['_markSuggestions'](_0xa5a202,_0x2658b5),this['_fixObsoleteTags'](_0xa5a202),_0xa5a202=this['_removeMissingPairs'](_0xa5a202),_0xa5a202=this['_markMismatchedRemovedTags'](_0xa5a202),_0xa5a202=this['_removeUnsupportedChanges'](_0xa5a202);const {root:_0x149e2a,changes:_0x363f77}=this['_makeModelFromTape'](_0xa5a202,_0x300d82,_0x335ddd);_0x271946['model'][_0x335ddd]=_0x149e2a;const _0x5e2ced=_0xe5a273['get'](_0x335ddd);if(_0x5e2ced){const _0x40be85=_0x300d82['get'](_0x5e2ced['userId']),_0x3f1885=new r({'author':_0x40be85,'type':_0x5e2ced['isAttached']?'add':'remove','data':{'isOnRoot':!0x0},'createdAt':new Date(),'rootName':_0x335ddd});_0x363f77['unshift'](_0x3f1885),_0x271946['attributes'][_0x335ddd]['revisionHistoryAttachChange']=_0x3f1885['id'];}_0x271946['changes']=_0x271946['changes']['concat'](_0x363f77);}return _0x271946;}['_markMarkers'](_0x2f9fa1,_0x4d583e){for(let _0x1785a5=0x0;_0x1785a5<_0x2f9fa1['length'];_0x1785a5++)for(const [_0x16e44c,_0x2371aa]of _0x4d583e)_0x2371aa['start']['isEqual'](_0x2f9fa1[_0x1785a5]['previousPosition'])&&_0x2f9fa1[_0x1785a5]['markersStart']['push'](_0x16e44c),_0x2371aa['end']['isEqual'](_0x2f9fa1[_0x1785a5]['nextPosition'])&&_0x2f9fa1[_0x1785a5]['markersEnd']['push'](_0x16e44c);}['_joinTapes'](_0x3eb5c0,_0x59b9a6){let _0x142b3b=[],_0x95d431=0x0,_0x588c20=0x0;for(;_0x95d431<_0x3eb5c0['length']||_0x588c20<_0x59b9a6['length'];){const _0x3831ea=_0x3eb5c0[_0x95d431]||{},_0x201855=_0x59b9a6[_0x588c20]||{};if(_0x3831ea['id']==_0x201855['id'])_0x95d431++,_0x588c20++,_0x142b3b['push'](_0x3831ea);else{if(_0x201855['isRemoved']&&_0x3831ea['isAdded']){const {commonTape:_0x194126,iEnd:_0x572bb7,jEnd:_0x359d40}=this['_threeWayMerge'](_0x3eb5c0,_0x95d431,_0x59b9a6,_0x588c20);_0x142b3b=_0x142b3b['concat'](_0x194126),_0x95d431=_0x572bb7,_0x588c20=_0x359d40;}else _0x201855['isRemoved']?(_0x588c20++,_0x142b3b['push'](_0x201855)):(_0x95d431++,_0x142b3b['push'](_0x3831ea));}}return _0x142b3b;}['_markSuggestions'](_0x572d71,_0x26d9b6){const _0x3d8f15=[];for(let _0x35b949=0x0;_0x35b949<_0x572d71['length'];_0x35b949++){for(let _0x4a7b3b=0x0;_0x4a7b3b<_0x572d71[_0x35b949]['markersStart']['length'];_0x4a7b3b++){const _0x3bf127=_0x572d71[_0x35b949]['markersStart'][_0x4a7b3b];if(!_0x26d9b6['has'](_0x3bf127))continue;const {group:_0x395673,type:_0x4ba85f,authorId:_0x4b1649}=_0x81e32e(_0x3bf127);'revision-suggestion'!=_0x395673||'insertion'!=_0x4ba85f&&'deletion'!=_0x4ba85f||(_0x3d8f15['unshift']({'type':_0x4ba85f,'name':_0x3bf127,'userId':_0x4b1649}),_0x572d71[_0x35b949]['markersStart']['splice'](_0x4a7b3b,0x1),_0x4a7b3b--);}_0x4327d1(_0x572d71[_0x35b949]);for(let _0x26dd18=0x0;_0x26dd18<_0x572d71[_0x35b949]['markersEnd']['length'];_0x26dd18++){const _0x2bdca4=_0x572d71[_0x35b949]['markersEnd'][_0x26dd18];if(!_0x26d9b6['has'](_0x2bdca4))continue;const {group:_0x50586a,type:_0x3cd431}=_0x81e32e(_0x2bdca4);if('revision-suggestion'!=_0x50586a||'insertion'!=_0x3cd431&&'deletion'!=_0x3cd431)continue;_0x572d71[_0x35b949]['markersEnd']['splice'](_0x26dd18,0x1),_0x26dd18--;const _0x3bdbd1=_0x3d8f15['findIndex'](_0x4aaacf=>_0x4aaacf['name']==_0x2bdca4);_0x3bdbd1>-0x1&&_0x3d8f15['splice'](_0x3bdbd1,0x1);}}function _0x81e32e(_0x58fb0d){const _0x4efe01=_0x58fb0d['split'](':');return{'group':_0x4efe01[0x0],'type':_0x4efe01[0x1],'subType':_0x4efe01['length']>=0x5?_0x4efe01[0x2]:null,'id':_0x4efe01['length']<0x5?_0x4efe01[0x2]:_0x4efe01[0x3],'authorId':_0x4efe01['length']<0x5?_0x4efe01[0x3]:_0x4efe01[0x4],'markerCount':0x6==_0x4efe01['length']?_0x4efe01[0x5]:null};}function _0x4327d1(_0x1ec3c2){for(let _0x38b9f7=0x0;_0x38b9f7<_0x3d8f15['length'];_0x38b9f7++){if(_0x1ec3c2['isAdded']&&'insertion'==_0x3d8f15[_0x38b9f7]['type'])return _0x1ec3c2['isAddSuggestion']=_0x3d8f15[_0x38b9f7],void delete _0x1ec3c2['isAdded'];if(!_0x1ec3c2['isAdded']&&!_0x1ec3c2['isRemoved']&&'deletion'==_0x3d8f15[_0x38b9f7]['type'])return void(_0x1ec3c2['isRemoveSuggestion']=_0x3d8f15[_0x38b9f7]);}}}['_setDistance'](_0x594073,_0xafc3dd){let _0x17e55b=0x0,_0x14ef82=!0x1;const _0x351c42=new Map();for(const _0x2be29a of _0x594073)_0x2be29a[_0xafc3dd]?_0x14ef82&&(_0x17e55b++,_0x14ef82=!0x1):(_0x17e55b++,_0x14ef82=!0x0),_0x351c42['set'](_0x2be29a['id'],_0x17e55b);for(let _0x489354=0x0;_0x489354<_0x594073['length'];_0x489354++){if('isRemoved'==_0xafc3dd&&_0x594073[_0x489354]['isAdded']||'isAdded'==_0xafc3dd&&_0x594073[_0x489354]['isRemoved'])continue;if('text'==_0x594073[_0x489354]['type']){_0x594073[_0x489354]['distance']=0x0;continue;}const _0x51d0c2=_0x351c42['get'](_0x594073[_0x489354]['pairId']),_0x446068=_0x351c42['get'](_0x594073[_0x489354]['id']);_0x594073[_0x489354]['distance']=_0x51d0c2-_0x446068;}}['_getRevisionsRange'](_0xbae368,_0x1b5405,_0x2fc50a=!0x1){const _0x2ee176=[];let _0x28fb0c=this['repository']['getIndex'](_0xbae368),_0x478ddc=this['repository']['getIndex'](_0x1b5405);for(-0x1==_0x478ddc&&(_0x478ddc=this['repository']['_revisions']['length'],_0x2fc50a=!0x1);_0x28fb0c<_0x478ddc;)_0x2ee176['push'](this['repository']['getRevision'](_0x28fb0c)),_0x28fb0c++;return _0x2fc50a&&_0x2ee176['push'](this['repository']['getRevision'](_0x28fb0c)),_0x2ee176;}['_threeWayMerge'](_0x2f5f57,_0xe880f1,_0x4368e0,_0x49b5fb){const _0x2a9be0=this['editor']['model']['schema'];let _0x4217bc=_0xe880f1;for(;_0x2f5f57[_0x4217bc]&&_0x2f5f57[_0x4217bc]['isAdded'];)_0x4217bc++;let _0x4a5c66=_0x49b5fb;for(;_0x4368e0[_0x4a5c66]&&_0x4368e0[_0x4a5c66]['isRemoved'];)_0x4a5c66++;_0x10e8ae(_0x2f5f57,_0xe880f1,_0x4217bc),_0x10e8ae(_0x4368e0,_0x49b5fb,_0x4a5c66);const _0x2627b4=_0x4368e0['slice'](_0x49b5fb,_0x4a5c66)['concat'](_0x2f5f57['slice'](_0xe880f1,_0x4217bc));return _0x2627b4['sort']((_0x2ad39e,_0x56a2b5)=>_0x2ad39e['side']!=_0x56a2b5['side']?_0x2ad39e['side']-_0x56a2b5['side']:_0x2ad39e['level']!=_0x56a2b5['level']?_0x2ad39e['level']-_0x56a2b5['level']:_0x2ad39e['distance']!=_0x56a2b5['distance']?_0x56a2b5['distance']-_0x2ad39e['distance']:!!_0x2ad39e['isAdded']!=!!_0x56a2b5['isAdded']?-0x1==_0x2ad39e['side']||0x0==_0x2ad39e['side']?_0x2ad39e['isAdded']?-0x1:0x1:_0x2ad39e['isAdded']?0x1:-0x1:_0x2ad39e['index']-_0x56a2b5['index']),{'commonTape':_0x2627b4,'iEnd':_0x4217bc,'jEnd':_0x4a5c66};function _0x10e8ae(_0x49377d,_0x21cd00,_0x1a1ee0){let _0x87555b=-0x1,_0x1633c2=Number['POSITIVE_INFINITY'],_0x120d97=!0x0;for(let _0x4a5363=_0x21cd00;_0x4a5363<_0x1a1ee0;_0x4a5363++)if(_0x2a9be0['isInline'](_0x49377d[_0x4a5363]['item'])||(_0x120d97=!0x1),_0x49377d[_0x4a5363]['item']['startIndex']<_0x21cd00&&(_0x87555b=_0x4a5363),_0x49377d[_0x4a5363]['item']['endIndex']>=_0x1a1ee0){_0x1633c2=_0x4a5363;break;}_0x120d97&&(_0x87555b=_0x1a1ee0-0x1);for(let _0x14241c=_0x21cd00;_0x14241c<_0x1a1ee0;_0x14241c++)_0x49377d[_0x14241c]['side']=_0x14241c<=_0x87555b?-0x1:_0x14241c<_0x1633c2?0x0:0x1,_0x49377d[_0x14241c]['index']=_0x14241c;let _0x12e8a7=0x0;for(let _0x4b1a1e=_0x21cd00;_0x4b1a1e<=_0x87555b;_0x4b1a1e++)0x0==_0x49377d[_0x4b1a1e]['distance']?_0x49377d[_0x4b1a1e]['level']=_0x12e8a7:(_0x12e8a7++,_0x49377d[_0x4b1a1e]['level']=_0x12e8a7,_0x12e8a7++);for(let _0x27656f=_0x21cd00;_0x27656f<_0x1a1ee0;_0x27656f++)0x0==_0x49377d[_0x27656f]['side']&&(_0x49377d[_0x27656f]['level']=_0x12e8a7);_0x12e8a7=0x0;for(let _0x40491e=_0x1a1ee0-0x1;_0x40491e>=_0x1633c2;_0x40491e--)0x0==_0x49377d[_0x40491e]['distance']?_0x49377d[_0x40491e]['level']=_0x12e8a7:(_0x12e8a7--,_0x49377d[_0x40491e]['level']=_0x12e8a7,_0x12e8a7--);}}['_fixObsoleteTags'](_0x922f4d){const _0x116a21=new Map(),_0x412090=this['editor']['model']['schema'];for(let _0x252f2e=0x1;_0x252f2e<_0x922f4d['length'];_0x252f2e++){let _0x12997a,_0x3f31b1,_0x3be98c;const _0x2873d5=_0x922f4d[_0x252f2e],_0x17fcf2=_0x922f4d[_0x252f2e-0x1];if('text'==_0x2873d5['type'])continue;if(_0x2873d5['type']!=_0x17fcf2['type'])continue;if(!_0x412090['isBlock'](_0x17fcf2['item'])||_0x412090['isLimit'](_0x17fcf2['item']))continue;if(!_0x412090['isBlock'](_0x2873d5['item'])||_0x412090['isLimit'](_0x2873d5['item']))continue;if((_0x922f4d[_0x252f2e]['isAdded']||_0x922f4d[_0x252f2e]['isAddSuggestion'])&&_0x922f4d[_0x252f2e-0x1]['isRemoved'])_0x12997a=_0x922f4d[_0x252f2e],_0x3f31b1=_0x922f4d[_0x252f2e-0x1],_0x3be98c=_0x252f2e-0x1;else{if(!_0x922f4d[_0x252f2e]['isRemoved']||!_0x922f4d[_0x252f2e-0x1]['isAdded']&&!_0x922f4d[_0x252f2e-0x1]['isAddSuggestion'])continue;_0x12997a=_0x922f4d[_0x252f2e-0x1],_0x3f31b1=_0x922f4d[_0x252f2e],_0x3be98c=_0x252f2e;}const _0x274a48=_0x12997a['level']==_0x3f31b1['level'],_0x51fe32=Math['abs'](_0x12997a['level'])<Math['abs'](_0x3f31b1['level'])&&0x0==_0x3f31b1['distance'];(_0x274a48||_0x51fe32)&&(_0x116a21['set'](_0x3f31b1['id'],_0x12997a['id']),_0x922f4d['splice'](_0x3be98c,0x1),_0x252f2e--,_0x12997a['isAdded']=!0x1);}for(let _0x4d13da=0x0;_0x4d13da<_0x922f4d['length'];_0x4d13da++)_0x116a21['has'](_0x922f4d[_0x4d13da]['pairId'])&&(_0x922f4d[_0x4d13da]['pairId']=_0x116a21['get'](_0x922f4d[_0x4d13da]['pairId']));}['_removeMissingPairs'](_0x5ef7f9){const _0x2a5129=new Set(_0x5ef7f9['map'](_0x328e92=>_0x328e92['id']));for(let _0x5c4a46=0x0;_0x5c4a46<_0x5ef7f9['length'];_0x5c4a46++)_0x2a5129['has'](_0x5ef7f9[_0x5c4a46]['pairId'])||0x0==_0x5ef7f9[_0x5c4a46]['distance']||(_0x5ef7f9[_0x5c4a46]['isIncorrect']=!0x0);return _0x5ef7f9['filter'](_0x36ca9b=>!_0x36ca9b['isIncorrect']);}['_markMismatchedRemovedTags'](_0x512373){const _0x5d14d5=new Set();for(let _0x5f2566=0x0;_0x5f2566<_0x512373['length'];_0x5f2566++){if(_0x5d14d5['has'](_0x512373[_0x5f2566]['id'])&&_0x512373[_0x5f2566]['isRemoved']&&(_0x512373[_0x5f2566]['isIncorrect']=!0x0),_0x512373[_0x5f2566]['isIncorrect'])continue;if(0x0==_0x512373[_0x5f2566]['distance'])continue;if('elementStart'!=_0x512373[_0x5f2566]['type'])continue;if(null==_0x512373[_0x5f2566]['pairId'])continue;let _0x2ef5cf=_0x5f2566+0x1,_0x5f6b48=0x0;for(;_0x512373[_0x2ef5cf]['id']!=_0x512373[_0x5f2566]['pairId'];)'elementStart'==_0x512373[_0x2ef5cf]['type']?_0x5f6b48++:'elementEnd'==_0x512373[_0x2ef5cf]['type']&&_0x5f6b48--,_0x2ef5cf++;if(0x0!=_0x5f6b48){if(_0x512373[_0x5f2566]['isRemoved'])_0x512373[_0x5f2566]['isIncorrect']=!0x0;else{for(;_0x2ef5cf!=_0x5f2566;)_0x512373[_0x2ef5cf]['isRemoved']&&0x0!=_0x512373[_0x2ef5cf]['distance']&&(_0x512373[_0x2ef5cf]['isIncorrect']=!0x0,_0x5d14d5['add'](_0x512373[_0x2ef5cf]['pairId'])),_0x2ef5cf--;}}}return _0x512373['filter'](_0x170886=>!_0x170886['isIncorrect']);}['_removeUnsupportedChanges'](_0x2ad39c){const _0x3a10b4=this['editor']['model']['schema'];for(let _0x31d8a8=0x0;_0x31d8a8<_0x2ad39c['length'];_0x31d8a8++){if(!(_0x2ad39c[_0x31d8a8]['isAdded']||_0x2ad39c[_0x31d8a8]['isAddSuggestion']||_0x2ad39c[_0x31d8a8]['isRemoved']||_0x2ad39c[_0x31d8a8]['isRemoveSuggestion']))continue;if(0x0==_0x2ad39c[_0x31d8a8]['distance'])continue;const _0x41e679=_0x2ad39c[_0x31d8a8]['item'];_0x3a10b4['isBlock'](_0x41e679)||_0x3a10b4['isLimit'](_0x41e679)||(_0x2ad39c[_0x31d8a8]['isAdded']&&delete _0x2ad39c[_0x31d8a8]['isAdded'],_0x2ad39c[_0x31d8a8]['isAddSuggestion']&&delete _0x2ad39c[_0x31d8a8]['isAddSuggestion'],_0x2ad39c[_0x31d8a8]['isRemoveSuggestion']&&delete _0x2ad39c[_0x31d8a8]['isRemoveSuggestion'],_0x2ad39c[_0x31d8a8]['isRemoved']&&(_0x2ad39c[_0x31d8a8]['isIncorrect']=!0x0));}return _0x2ad39c['filter'](_0x1cdd7b=>!_0x1cdd7b['isIncorrect']);}['_makeModelFromTape'](_0x4efee1,_0x2aeaa7,_0x1a5260){const _0xd2f1a2=new gt(),_0x46bcf3=[],_0x5e34c2=new Map(),_0x3a8c88=this['editor']['model'],_0xaf0f8d=_0x3a8c88['schema'],_0x230e2a=[_0xd2f1a2],_0x5ce697={},_0x1c9a3a={'isAdded':[],'isRemoved':[],'isAddSuggestion':[],'isRemoveSuggestion':[]};let _0x4a572e=null;const _0x58f1db=[0x0];for(let _0x326402=0x0;_0x326402<_0x4efee1['length'];_0x326402++)if('elementStart'===_0x4efee1[_0x326402]['type']){_0x4efee1[_0x326402]['previousPosition']=_0x3a8c88['createPositionFromPath'](_0xd2f1a2,_0x58f1db);const _0x22599e=new ut(_0x4efee1[_0x326402]['item']['name'],_0x4efee1[_0x326402]['item']['getAttributes']());_0x230e2a[0x0]['_appendChild'](_0x22599e),_0x58f1db['push'](0x0),_0x230e2a['unshift'](_0x22599e),_0x4efee1[_0x326402]['nextPosition']=_0x3a8c88['createPositionFromPath'](_0xd2f1a2,_0x58f1db);}else'elementEnd'===_0x4efee1[_0x326402]['type']?(_0x230e2a['shift'](),_0x4efee1[_0x326402]['previousPosition']=_0x3a8c88['createPositionFromPath'](_0xd2f1a2,_0x58f1db),_0x58f1db['pop'](),_0x58f1db[_0x58f1db['length']-0x1]++,_0x4efee1[_0x326402]['nextPosition']=_0x3a8c88['createPositionFromPath'](_0xd2f1a2,_0x58f1db)):(_0x4efee1[_0x326402]['previousPosition']=_0x3a8c88['createPositionFromPath'](_0xd2f1a2,_0x58f1db),_0x4a572e?_0x4a572e['_data']+=_0x4efee1[_0x326402]['item']['data']:_0x4a572e=new mt(_0x4efee1[_0x326402]['item']['data'],_0x4efee1[_0x326402]['item']['getAttributes']()),_0x4efee1[_0x326402+0x1]&&'text'===_0x4efee1[_0x326402+0x1]['type']&&_0x70727(_0x4a572e,_0x4efee1[_0x326402+0x1]['item'])||(_0x230e2a[0x0]['_appendChild'](_0x4a572e),_0x4a572e=null),_0x58f1db[_0x58f1db['length']-0x1]+=_0x4efee1[_0x326402]['item']['offsetSize'],_0x4efee1[_0x326402]['nextPosition']=_0x3a8c88['createPositionFromPath'](_0xd2f1a2,_0x58f1db));for(let _0x10d6d4=0x0;_0x10d6d4<_0x4efee1['length'];_0x10d6d4++){const _0x1cf714=_0x4efee1[_0x10d6d4]['previousPosition'],_0x1b7429=_0x4efee1[_0x10d6d4]['nextPosition'];for(const _0x24fd68 of _0x4efee1[_0x10d6d4]['markersStart'])_0x5e34c2['set'](_0x24fd68,{'start':_0x1cf714,'end':null});_0x554ad8('isRemoveSuggestion',_0x10d6d4,_0x1cf714,_0x1b7429),_0x554ad8('isAddSuggestion',_0x10d6d4,_0x1cf714,_0x1b7429),_0x554ad8('isRemoved',_0x10d6d4,_0x1cf714,_0x1b7429),_0x554ad8('isAdded',_0x10d6d4,_0x1cf714,_0x1b7429);for(const _0x4c3ee9 of _0x4efee1[_0x10d6d4]['markersEnd']){_0x5e34c2['get'](_0x4c3ee9)['end']=_0x1b7429;}}for(const [_0x2bab35,_0x35e986]of _0x5e34c2){const _0x313526=this['editor']['model']['createRange'](_0x35e986['start'],_0x35e986['end']);_0xd2f1a2['markers']['set'](_0x2bab35,_0x313526);}return _0x46bcf3['sort']((_0x27ff64,_0x474974)=>{const _0x4b4519=_0xd2f1a2['markers']['get']('revision:'+_0x27ff64['id']),_0x58dfb1=_0xd2f1a2['markers']['get']('revision:'+_0x474974['id']);return _0x4b4519['start']['isBefore'](_0x58dfb1['start'])?-0x1:_0x4b4519['start']['isAfter'](_0x58dfb1['start'])?0x1:_0x4b4519['end']['isBefore'](_0x58dfb1['end'])?-0x1:_0x4b4519['end']['isAfter'](_0x58dfb1['end'])?0x1:'add'===_0x27ff64['type']?-0x1:0x1;}),{'root':_0xd2f1a2,'changes':_0x46bcf3};function _0x554ad8(_0x15be74,_0x414fd7,_0x2a2e73,_0x4c6508){const _0x4c502e=!!_0x4efee1[_0x414fd7][_0x15be74],_0x37e783=_0x4c502e?_0x4efee1[_0x414fd7][_0x15be74]['userId']:null,_0x58a4b7=_0x414fd7===_0x4efee1['length']-0x1,_0x2dc0f3=_0x1c9a3a[_0x15be74][0x0],_0x537cc6=_0xaf0f8d['isObject'](_0x4efee1[_0x414fd7]['item']);!_0x5ce697[_0x15be74]&&_0x4c502e?_0x5ce697[_0x15be74]={'start':_0x2a2e73,'tapeItem':_0x4efee1[_0x414fd7],'userId':_0x37e783,'type':_0x15be74}:_0x5ce697[_0x15be74]&&!_0x4c502e?(_0x5ce697[_0x15be74]['end']=_0x2a2e73,_0x4db010(_0x5ce697[_0x15be74]),_0x5ce697[_0x15be74]=null):_0x5ce697[_0x15be74]&&_0x4c502e&&_0x5ce697[_0x15be74]['userId']!==_0x37e783&&(_0x5ce697[_0x15be74]['end']=_0x2a2e73,_0x2dc0f3&&_0x2dc0f3['userId']===_0x5ce697[_0x15be74]['userId']||_0x4db010(_0x5ce697[_0x15be74]),_0x5ce697[_0x15be74]={'start':_0x2a2e73,'tapeItem':_0x4efee1[_0x414fd7],'userId':_0x37e783,'type':_0x15be74}),_0x5ce697[_0x15be74]&&_0x537cc6&&('elementStart'!==_0x4efee1[_0x414fd7]['type']||_0x2dc0f3&&_0x2dc0f3['userId']===_0x37e783||_0x1c9a3a[_0x15be74]['unshift']({'userId':_0x37e783,'object':_0x4efee1[_0x414fd7]['item'],'change':_0x5ce697[_0x15be74]}),'elementEnd'===_0x4efee1[_0x414fd7]['type']&&_0x2dc0f3&&_0x2dc0f3['object']===_0x4efee1[_0x414fd7]['item']&&(_0x1c9a3a[_0x15be74]['shift'](),_0x5ce697[_0x15be74]=_0x2dc0f3['change'])),_0x5ce697[_0x15be74]&&_0x58a4b7&&(_0x5ce697[_0x15be74]['end']=_0x4c6508,_0x4db010(_0x5ce697[_0x15be74]),_0x5ce697[_0x15be74]=null);}function _0x4db010({start:_0x5746dc,end:_0x3df1ef,tapeItem:_0x389481,userId:_0x1d6fca,type:_0x3c45ff}){const _0x52d89b=_0x389481['item'],_0x2baa36=_0x3a8c88['schema']['isBlock'](_0x52d89b)&&!_0x3a8c88['schema']['isLimit'](_0x52d89b),_0x5174e5=_0x5746dc['nodeAfter']==_0x3df1ef['parent']&&_0x3df1ef['isAtStart'];if(_0x2baa36&&_0x5174e5)return;const _0x51be27=_0x3a8c88['createRange'](_0x5746dc,_0x3df1ef),_0x4c89c2=_0x2aeaa7['get'](_0x1d6fca),_0x4ab3c9=new r({'author':_0x4c89c2,'type':'isAdded'==_0x3c45ff||'isAddSuggestion'==_0x3c45ff?'add':'remove','data':{'isSuggestion':'isAddSuggestion'==_0x3c45ff||'isRemoveSuggestion'==_0x3c45ff},'createdAt':new Date(),'rootName':_0x1a5260});_0x46bcf3['push'](_0x4ab3c9),_0xd2f1a2['markers']['set']('revision:'+_0x4ab3c9['id'],_0x51be27);}function _0x70727(_0x212f10,_0x349743){const _0x35249c=_0x212f10['getAttributes'](),_0x426923=_0x349743['getAttributes']();for(const _0x3986af of _0x35249c){if(_0x3986af[0x1]!==_0x349743['getAttribute'](_0x3986af[0x0]))return!0x1;_0x426923['next']();}return _0x426923['next']()['done'];}}['_setConversion'](){this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'revision'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision','view':_0x5b72ca=>{const _0x390aed=_0x5b72ca['markerName']['split'](':')[0x1],_0x2b1a39=this['_getChangeFromId'](_0x390aed);if(!_0x2b1a39)return null;const _0x2ae7a3='add'==_0x2b1a39['type']?'insertion':'deletion',_0x48d7b1=['ck-suggestion-marker','ck-suggestion-marker-'+_0x2ae7a3];return _0x2b1a39['data']['isSuggestion']&&_0x48d7b1['push']('ck-suggestion-marker-'+_0x2ae7a3+'-new'),this['activeChange']==_0x2b1a39&&_0x48d7b1['push']('ck-suggestion-marker--active'),{'classes':_0x48d7b1,'attributes':{'data-change-id':_0x390aed}};}}),this['editor']['conversion']['for']('upcast')['add'](_0x506ed1=>{_0x506ed1['on']('element:pre',(_0x31afa4,_0x23a9b8,_0x1fa708)=>{const _0x40cdf1=_0x23a9b8['viewItem']['getChild'](0x0);if(!_0x40cdf1||!_0x40cdf1['is']('element','code'))return;if(!_0x1fa708['consumable']['consume'](_0x40cdf1,{'attributes':['vid_start','vid_end']}))return;const _0x14b28c=_0x23a9b8['modelRange']['start']['nodeAfter'];_0x1fa708['writer']['setAttribute']('vid_start',_0x40cdf1['getAttribute']('vid_start'),_0x14b28c),_0x1fa708['writer']['setAttribute']('vid_end',_0x40cdf1['getAttribute']('vid_end'),_0x14b28c);},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['add'](_0x388dc4=>{_0x388dc4['on']('element',(_0x34e5aa,_0x68eec0,_0xd65a51)=>{if(!_0xd65a51['consumable']['consume'](_0x68eec0['viewItem'],{'attributes':['vid_start','vid_end']}))return;if(_0x68eec0['modelRange']['isCollapsed'])return;const _0x8db13=_0x68eec0['modelRange']['start']['nodeAfter'];_0x8db13['hasAttribute']('vid_start')||_0x8db13['hasAttribute']('vid')||(_0xd65a51['writer']['setAttribute']('vid_start',_0x68eec0['viewItem']['getAttribute']('vid_start'),_0x8db13),_0xd65a51['writer']['setAttribute']('vid_end',_0x68eec0['viewItem']['getAttribute']('vid_end'),_0x8db13));},{'priority':'low'});}),this['editor']['conversion']['for']('upcast')['elementToAttribute']({'view':{'name':'span','attributes':{'vid':!0x0}},'model':{'key':'vid','value':_0x424c65=>_0x424c65['getAttribute']('vid')}}),this['editor']['model']['schema']['on']('checkAttribute',(_0x184a59,[,_0x7b0990])=>{['vid_start','vid_end','vid']['includes'](_0x7b0990)&&(_0x184a59['return']=!0x0,_0x184a59['stop']());},{'priority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['add'](_0x569bf4=>{_0x569bf4['on']('attribute:vid',(_0x573458,_0x4093a0,_0x4f242c)=>{if('\x20'!=_0x4093a0['item']['data']||_0x4093a0['item']['parent']['maxOffset']>0x1)return;if(!_0x4f242c['consumable']['consume'](_0x4093a0['item'],_0x573458['name']))return;const _0x30aff0=_0x4f242c['writer'],_0x2c6a15=_0x4f242c['mapper']['toViewRange'](_0x4093a0['range']);_0x30aff0['wrap'](_0x2c6a15,_0x30aff0['createAttributeElement']('span'));});}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',function(_0x4e287d){const _0x264a3e=_0x4e287d['plugins']['get']('RevisionViewer');return(_0x2657ec,_0x1ebefa,_0x56055f)=>{const _0x1064b6=_0x1ebefa['markerName']['split'](':')[0x1],_0x48b610=_0x264a3e['_getChangeFromId'](_0x1064b6);if(!_0x48b610)return null;const _0xb6fc06='add'==_0x48b610['type']?'split':'merge';if(!_0x56055f['consumable']['test'](_0x1ebefa['markerRange'],_0x2657ec['name']))return;const _0x231015=_0x1ebefa['markerRange']['getWalker'](),_0x2ba57b=_0x1ebefa['markerRange']['start'],_0x3265d9=_0x4e287d['model']['schema'];let _0x18ba19=null,_0x11cecd=null,_0x463dd8=!0x1,_0x57f64f=!0x1;for(const _0xe69eff of _0x231015){const _0x315d3c=_0xe69eff['item'];_0x463dd8=_0x463dd8||_0x3265d9['isContent'](_0x315d3c);const _0x3f90ff=_0x56055f['mapper']['toViewElement'](_0x315d3c);if(_0x3f90ff&&_0x3f90ff['getCustomProperty']('addHighlight'))return;'elementEnd'==_0xe69eff['type']&&(_0x3265d9['isBlock'](_0x315d3c)&&!_0x3265d9['isLimit'](_0x315d3c)&&(_0x315d3c['nextSibling']||_0x2ba57b['isAtEnd']?_0x18ba19&&_0x18ba19['parent']==_0x315d3c||(_0x18ba19=_0x315d3c,_0x2a9891(_0xe69eff['previousPosition']),_0x57f64f=!0x0):_0x11cecd=_0x11cecd||_0xe69eff['previousPosition']));}function _0x2a9891(_0x316bd2){const _0x586c7c=_0x56055f['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0xb6fc06}),_0x397ba0=_0x56055f['mapper']['toViewPosition'](_0x316bd2);_0x48b610['data']['isSuggestion']&&_0x56055f['writer']['addClass']('ck-suggestion-marker-'+_0xb6fc06+'-new',_0x586c7c),_0x264a3e['activeChange']==_0x48b610&&_0x56055f['writer']['addClass']('ck-suggestion-marker--active',_0x586c7c),_0x56055f['writer']['insert'](_0x397ba0,_0x586c7c),_0x56055f['mapper']['bindElementToMarker'](_0x586c7c,_0x1ebefa['markerName']);}_0x463dd8||_0x57f64f||!_0x11cecd||_0x2a9891(_0x11cecd);};}(this['editor']),{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('removeMarker:revision',(_0xb995d5,_0x3e3dfd,_0x4181cf)=>{const _0x1242f2=_0x4181cf['mapper']['markerNameToElements'](_0x3e3dfd['markerName']);if(_0x1242f2){for(const _0x39eb28 of _0x1242f2)(_0x39eb28['hasClass']('ck-suggestion-marker-split')||_0x39eb28['hasClass']('ck-suggestion-marker-merge'))&&(_0x4181cf['mapper']['unbindElementFromMarkerName'](_0x39eb28,_0x3e3dfd['markerName']),_0x4181cf['writer']['remove'](_0x39eb28));}},{'priority':'high'}),this['editor']['editing']['downcastDispatcher']['on']('addMarker:revision',(_0x86f86b,_0x1d4a13,_0x16cdb9)=>{const _0xe52ec4=_0x1d4a13['markerName']['split'](':')[0x1],_0x421a7a=this['_getChangeFromId'](_0xe52ec4);if(!_0x421a7a)return null;const _0x4fe424='add'==_0x421a7a['type']?'split':'merge';if(_0x16cdb9['consumable']['test'](_0x1d4a13['markerRange'],_0x86f86b['name']))for(const _0x1d4e5c of _0x1d4a13['markerRange']['getItems']()){if(!_0x1d4e5c['is']('element','softBreak'))continue;const _0x5df5fd=_0x16cdb9['writer']['createUIElement']('span',{'class':'ck-suggestion-marker-'+_0x4fe424}),_0x3941b8=_0x16cdb9['mapper']['toViewPosition'](this['editor']['model']['createPositionBefore'](_0x1d4e5c));_0x421a7a['data']['isSuggestion']&&_0x16cdb9['writer']['addClass']('ck-suggestion-marker-'+_0x4fe424+'-new',_0x5df5fd),this['activeChange']==_0x421a7a&&_0x16cdb9['writer']['addClass']('ck-suggestion-marker--active',_0x5df5fd),_0x16cdb9['writer']['insert'](_0x3941b8,_0x5df5fd),_0x16cdb9['mapper']['bindElementToMarker'](_0x5df5fd,_0x1d4a13['markerName']);}},{'priority':'high'}),this['editor']['model']['document']['on']('change',()=>{this['editor']['editing']['view']['change'](_0x13c492=>{for(const _0x16d7b8 of this['editor']['model']['document']['getRootNames']()){const _0x3cabbb=this['editor']['model']['document']['getRoot'](_0x16d7b8),_0xb8a2c6=this['editor']['editing']['view']['document']['getRoot'](_0x16d7b8);if(_0xb8a2c6){const _0x2a5ed2=_0x3cabbb['getAttribute']('revisionHistoryAttachChange');if(_0x13c492['removeAttribute']('data-change-id',_0xb8a2c6),_0x13c492['removeClass']('ck-revision-history-root-add',_0xb8a2c6),_0x13c492['removeClass']('ck-revision-history-root-remove',_0xb8a2c6),_0x13c492['removeClass']('ck-revision-history-root--active',_0xb8a2c6),_0x2a5ed2){const _0x373fc4=this['_getChangeFromId'](_0x2a5ed2);if(!_0x373fc4)return null;_0x13c492['setAttribute']('data-change-id',_0x2a5ed2,_0xb8a2c6),_0x13c492['addClass']('ck-revision-history-root-'+_0x373fc4['type'],_0xb8a2c6),this['activeChange']==_0x373fc4&&_0x13c492['addClass']('ck-revision-history-root--active',_0xb8a2c6);}}}});}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'comment','model':_0x41d6ef=>'revision-comment:'+_0x41d6ef,'converterPriority':'highest'}),this['editor']['conversion']['for']('upcast')['dataToMarker']({'view':'suggestion','model':_0xa18f3b=>'revision-suggestion:'+_0xa18f3b,'converterPriority':'highest'}),this['editor']['conversion']['for']('dataDowncast')['markerToData']({'model':'revision-suggestion','view':_0x12d591=>({'name':'suggestion:'+_0x12d591,'group':'revision-suggestion'}),'converterPriority':'highest'}),this['editor']['conversion']['for']('editingDowncast')['markerToHighlight']({'model':'revision-suggestion','view':_0x2a774b=>{const _0x3e6295=_0x2a774b['markerName']['split'](':')[0x1];return'insertion'!=_0x3e6295&&'deletion'!=_0x3e6295?null:{'classes':['ck-suggestion-preview-marker','ck-suggestion-preview-marker-'+_0x3e6295]};}}),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',(_0xad1427,_0x59adf6,_0x106550)=>{const _0x516da7=_0x106550['mapper']['markerNameToElements'](_0x59adf6['markerName']);if(_0x516da7){for(const _0x3aa79f of _0x516da7)_0x3aa79f['is']('uiElement')&&(_0x106550['mapper']['unbindElementFromMarkerName'](_0x3aa79f,_0x59adf6['markerName']),_0x106550['writer']['remove'](_0x3aa79f));}},{'priority':'high'});}['_getChangeFromId'](_0x46ba20){return this['_changeIdToChange']['get'](_0x46ba20);}['_getViewForChange'](_0x4b5664){return this['_changeView']&&this['_changeView']['destroy'](),this['_changeView']=new X(this['editor']['locale'],_0x4b5664),this['_changeView'];}['_initInteractions'](){this['editor']['model']['document']['selection']['observeMarkers']('revision'),this['on']('change:activeView',(_0x4fc261,_0x50b4ad,_0x1295c8,_0xbf35fd)=>{_0xbf35fd&&this['_balloon']['remove'](_0xbf35fd),_0x1295c8&&(this['_balloon']['add']({'view':_0x1295c8,'stackId':'revisionHistoryLabel','position':{'target':()=>{const _0x2c66d3=this['editor']['editing'],_0x40d0ae=this['_getChangeFromId'](_0x1295c8['changeId']);let _0x89b6c9;if(_0x40d0ae['data']['isOnRoot']){const _0x29f639=_0x2c66d3['view']['getDomRoot'](_0x40d0ae['rootName']);_0x89b6c9=Array['from'](_0x29f639['getClientRects']());}else{const _0x4f66b0=this['editor']['model']['markers']['get']('revision:'+_0x1295c8['changeId']);_0x89b6c9=Array['from'](_0x2c66d3['mapper']['markerNameToElements'](_0x4f66b0['name']))['map'](_0x498d0b=>_0x2c66d3['view']['domConverter']['mapViewToDom'](_0x498d0b))['map'](_0x1a9755=>Array['from'](_0x1a9755['getClientRects']()))['flat']();}if(!this['_activeViewTarget'])return _0x89b6c9[0x0];return _0x89b6c9['find'](_0x1bbcd2=>_0x1bbcd2['top']-0x3<=this['_activeViewTarget']['y']&&_0x1bbcd2['bottom']+0x3>=this['_activeViewTarget']['y']&&_0x1bbcd2['left']-0x3<=this['_activeViewTarget']['x']&&_0x1bbcd2['right']+0x3>=this['_activeViewTarget']['x'])||_0x89b6c9[0x0];}}}),this['_balloon']['showStack']('revisionHistoryLabel'));}),this['on']('change:activeChange',(_0x7cef32,_0x418dbb,_0xb0351,_0xd2cf95)=>{this['activeView']=_0xb0351?this['_getViewForChange'](_0xb0351):null,this['editor']['model']['change'](()=>{const _0x39fac0=this['editor']['editing'];_0xd2cf95&&(_0xd2cf95['data']['isOnRoot']?_0x39fac0['view']['change'](_0x54a149=>{_0x54a149['removeClass']('ck-revision-history-root--active',_0x39fac0['view']['document']['getRoot'](_0xd2cf95['rootName']));}):_0x39fac0['reconvertMarker']('revision:'+_0xd2cf95['id'])),_0xb0351&&(_0xb0351['data']['isOnRoot']?_0x39fac0['view']['change'](_0x547f18=>{_0x547f18['addClass']('ck-revision-history-root--active',_0x39fac0['view']['document']['getRoot'](_0xb0351['rootName']));}):_0x39fac0['reconvertMarker']('revision:'+_0xb0351['id']));});}),this['listenTo'](this['editor']['editing']['view']['document'],'mouseover',(_0x3c307b,_0x450476)=>{if(this['activeChange'])return;const _0x2f3ecd=this['_findChangeIdFromDomTarget'](_0x450476['target']),_0x4c3d6d=this['_changeIdToChange']['get'](_0x2f3ecd);_0x4c3d6d?(this['_activeViewTarget']={'x':_0x450476['domEvent']['x'],'y':_0x450476['domEvent']['y']},this['activeView']=this['_getViewForChange'](_0x4c3d6d)):(this['_activeViewTarget']=null,this['activeView']=null);}),this['listenTo'](this['editor']['editing']['view']['document'],'mousedown',(_0x3cc916,_0x5ae548)=>{const _0x5895d4=this['_findChangeIdFromDomTarget'](_0x5ae548['target']),_0xab0a2e=this['_changeIdToChange']['get'](_0x5895d4);_0xab0a2e?(this['_activeViewTarget']={'x':_0x5ae548['domEvent']['x'],'y':_0x5ae548['domEvent']['y']},_0xab0a2e===this['activeChange']?this['_balloon']['updatePosition']():this['activeChange']=_0xab0a2e):(this['_activeViewTarget']=null,this['activeChange']=null);});}['_findChangeIdFromDomTarget'](_0x48d0e7){do{const _0x4b1005=_0x48d0e7['getAttribute']('data-change-id');if(_0x4b1005)return _0x4b1005;_0x48d0e7=_0x48d0e7['parent'];}while(_0x48d0e7);return null;}['_cleanMarkers'](){this['editor']['model']['change'](_0x2bc386=>{for(const _0x711f74 of this['editor']['model']['markers'])_0x2bc386['removeMarker'](_0x711f74);});}}function Z(_0x470893,_0x409b9a){return(_0x3685b8,_0x376d2f,_0x588b1e)=>{if(!_0x588b1e['consumable']['test'](_0x376d2f['markerRange'],_0x3685b8['name']))return;const _0xbeaf62=_0x376d2f['markerRange']['getWalker'](),_0xde9aea=_0x376d2f['markerRange']['start'],_0x1656f2=_0x470893['model']['schema'];let _0x32d620=null,_0x2ac70c=null,_0x476a7c=!0x1,_0x3e857e=!0x1;for(const _0x227d5f of _0xbeaf62){const _0xcd90f1=_0x227d5f['item'];_0x476a7c=_0x476a7c||_0x1656f2['isContent'](_0xcd90f1);const _0x247b8a=_0x588b1e['mapper']['toViewElement'](_0xcd90f1);if(_0x247b8a&&_0x247b8a['getCustomProperty']('addHighlight'))return;'elementEnd'==_0x227d5f['type']&&(_0x1656f2['isBlock'](_0xcd90f1)&&!_0x1656f2['isLimit'](_0xcd90f1)&&(_0xcd90f1['nextSibling']||_0xde9aea['isAtEnd']?_0x32d620&&_0x32d620['parent']==_0xcd90f1||(_0x32d620=_0xcd90f1,_0x4479db(_0x227d5f['previousPosition']),_0x3e857e=!0x0):_0x2ac70c=_0x2ac70c||_0x227d5f['previousPosition']));}function _0x4479db(_0xf4ef3f){const _0x154421=_0x588b1e['mapper']['toViewPosition'](_0xf4ef3f),_0x58cb00=_0x588b1e['writer']['createUIElement']('span',{'class':'ck-suggestion-preview-marker-'+_0x409b9a});_0x588b1e['writer']['insert'](_0x154421,_0x58cb00),_0x588b1e['mapper']['bindElementToMarker'](_0x58cb00,_0x376d2f['markerName']);}_0x476a7c||_0x3e857e||!_0x2ac70c||_0x4479db(_0x2ac70c);};}class wt extends _0x969d2d{constructor(_0x5584ac){super(_0x5584ac);const _0x31e2c5=_0x5584ac['plugins']['get'](d);this['affectsData']=!0x1,this['listenTo'](_0x31e2c5,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x31e2c5,'change:isEnabled',()=>this['refresh']());}['execute'](){const _0x256254=this['editor'],_0x388145=_0x256254['plugins']['get'](d),_0x44ce00=_0x388145['isReady']?_0x388145['diff']['newRevisionId']:null;_0x256254['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x44ce00);}['refresh'](){const {isReady:_0x4cae8f,isEnabled:_0x38b581,repository:_0x42bdde,diff:_0x12a9df}=this['editor']['plugins']['get'](d),_0x3204e3=_0x12a9df&&_0x42bdde['getLaterVisibleRevision'](_0x12a9df['newRevisionId']);this['isEnabled']=_0x4cae8f&&_0x38b581&&Boolean(_0x3204e3);}}class _t extends _0x969d2d{['_step'];constructor(_0x5e673c,{direction:_0x1ff181}){super(_0x5e673c);const _0x19aa55=_0x5e673c['plugins']['get'](d);this['affectsData']=!0x1,this['_step']='forward'===_0x1ff181?0x1:-0x1,this['listenTo'](_0x19aa55,'change:isReady',()=>this['refresh']()),this['listenTo'](_0x19aa55,'change:isEnabled',()=>this['refresh']()),this['listenTo'](_0x19aa55,'change:activeChange',()=>this['refresh']());}['execute'](){const _0x12d114=this['editor'],_0x3a6eac=_0x12d114['plugins']['get'](d),{isNavigationMode:_0x65071d,currentChangeNumber:_0x3a87e9}=_0x3a6eac;let _0xc7694a;if(_0x3a6eac['activeChange']=_0x65071d?_0x3a6eac['diff']['changes']['get'](_0x3a87e9+this['_step']):_0x3a6eac['diff']['changes']['first'],_0x3a6eac['activeChange']['data']['isOnRoot'])_0xc7694a=_0x12d114['editing']['view']['getDomRoot'](_0x3a6eac['activeChange']['rootName']);else{const _0x3b071a=_0x12d114['model']['markers']['get']('revision:'+_0x3a6eac['activeChange']['id']);_0xc7694a=_0x25477c(_0x12d114['editing'],_0x3b071a);}_0x498fcc({'target':_0xc7694a,'viewportOffset':0x28});}['refresh'](){const {isNavigationMode:_0x56ce3e,currentChangeNumber:_0x73ac43,numberOfChanges:_0x5e4fcc,isReady:_0x18f7d1,isEnabled:_0x4cdc33}=this['editor']['plugins']['get'](d);this['isEnabled']=!!(_0x4cdc33&&_0x18f7d1&&_0x5e4fcc)&&(!_0x56ce3e||(0x1===this['_step']?_0x73ac43<_0x5e4fcc-0x1:_0x73ac43>0x0));}}class _i extends ts{constructor(_0x5700a2){super(_0x5700a2);const _0x4c015a=this['bindTemplate'],_0x359dec=new te(_0x5700a2),_0x15baf6=new te(_0x5700a2);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',(_0x384315,_0x48a8a7)=>_0x384315&&_0x48a8a7>0x0),this['bind']('_statusText')['to'](this,'isReady',this,'currentChangeNumber',this,'numberOfChanges',this,'isNavigationMode',(_0x3c92e2,_0x54a775,_0x16330c,_0x2fab05)=>{if(!_0x3c92e2)return m(_0x5700a2,'Loading...');if(!_0x16330c)return m(_0x5700a2,'No\x20changes');const _0x460789=m(_0x5700a2,'NUMBER_OF_CHANGES',_0x16330c);return _0x2fab05?m(_0x5700a2,'X_OF_Y_CHANGES',[_0x54a775+0x1,_0x16330c]):_0x460789;}),_0x359dec['set']({'label':m(_0x5700a2,'Show\x20previous\x20change'),'tooltip':!0x0,'icon':_0x1fd3a6}),_0x15baf6['set']({'label':m(_0x5700a2,'Show\x20next\x20change'),'tooltip':!0x0,'icon':_0x27dfe9}),_0x359dec['bind']('isEnabled')['to'](this,'isBackwardNavigationEnabled'),_0x15baf6['bind']('isEnabled')['to'](this,'isForwardNavigationEnabled'),_0x359dec['on']('execute',()=>this['fire']('execute','backward')),_0x15baf6['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',_0x4c015a['if']('_isStatusLabelVisible','ck-hidden',_0x1d6e68=>!_0x1d6e68)]},'children':[{'text':_0x4c015a['to']('isNavigationMode',_0x123763=>_0x123763?m(_0x5700a2,'EDIT_X_OF_Y_REVISIONS')+':\x20':m(_0x5700a2,'Total')+':\x20')}]},{'text':_0x4c015a['to']('_statusText')}]},new _0x5bb69f(),{'tag':'div','attributes':{'class':['ck-revision-history-ui__changes-navigation__navigation']},'children':[_0x359dec,_0x15baf6]}]});}}const le='ck-editor__editable__loading-overlay';class ge extends _0x118fc5{static get['pluginName'](){return'RevisionViewerLoadingOverlay';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}['show'](){const _0xa93245=this['editor']['editing']['view'];_0xa93245['change'](_0x2ec4be=>{for(const _0xf82abb of _0xa93245['document']['roots'])_0x2ec4be['addClass'](le,_0xf82abb);});}['hide'](){const _0x5c4106=this['editor']['editing']['view'];_0x5c4106['change'](_0x1e8834=>{for(const _0x418e03 of _0x5c4106['document']['roots'])_0x1e8834['removeClass'](le,_0x418e03);});}}class w extends _0x118fc5{static get['pluginName'](){return'RevisionViewerUI';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[d,ge];}['init'](){const _0x5fa392=this['editor'],_0x5dd0ab=_0x5fa392['plugins']['get'](d),_0x4e9c9d=_0x5fa392['plugins']['get'](ge);_0x5fa392['ui']['componentFactory']['add']('exitToEditing',_0x475c91=>{const _0x38b6f1=new te(_0x475c91);return _0x38b6f1['set']({'label':m(_0x475c91,'Back\x20to\x20editing'),'icon':_0x5ec5f7,'withText':!0x0,'tooltip':!0x0,'class':'ck-revision-history-ui__back-to-editing'}),this['listenTo'](_0x38b6f1,'execute',()=>{_0x5fa392['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}),_0x38b6f1;}),_0x5fa392['ui']['componentFactory']['add']('restoreRevision',_0x496cde=>{const _0x211c4f=new te(_0x496cde);return _0x211c4f['set']({'label':m(_0x496cde,'Restore\x20this\x20revision'),'withText':!0x0,'tooltip':!0x0}),_0x211c4f['bind']('isEnabled')['to'](_0x5fa392['commands']['get']('restoreRevision')),this['listenTo'](_0x211c4f,'execute',()=>_0x5fa392['execute']('restoreRevision')),_0x211c4f;}),_0x5fa392['ui']['componentFactory']['add']('changesNavigation',_0x330a8e=>{const _0x2c12f1=new _i(_0x330a8e),_0x4e62aa=_0x5fa392['commands']['get']('showPreviousChange'),_0x26489e=_0x5fa392['commands']['get']('showNextChange');return _0x2c12f1['bind']('isBackwardNavigationEnabled')['to'](_0x4e62aa,'isEnabled'),_0x2c12f1['bind']('isForwardNavigationEnabled')['to'](_0x26489e,'isEnabled'),_0x2c12f1['bind']('isReady','currentChangeNumber','numberOfChanges','isNavigationMode')['to'](_0x5dd0ab),this['listenTo'](_0x2c12f1,'execute',(_0x1e488c,_0x3575cd)=>{_0x5fa392['execute']('forward'===_0x3575cd?'showNextChange':'showPreviousChange');}),_0x2c12f1;}),_0x4e9c9d['show'](),_0x5dd0ab['on']('change:isReady',(_0x347ec6,_0x5b5ab1,_0x332d07)=>{_0x332d07?_0x4e9c9d['hide']():_0x4e9c9d['show']();});}}class pt extends _0x3f0de8{['_resizeObserver']=null;constructor(_0x39cbce,_0x34c37b){super(_0x39cbce,_0x34c37b);const _0x335b79=this['bindTemplate'];this['set']({'label':m(_0x39cbce,'Revision\x20name'),'_tooltipString':''}),this['fieldView']['placeholder']=m(_0x39cbce,'Enter\x20the\x20revision\x20name'),this['extendTemplate']({'tag':'span','attributes':{'class':['ck-revision-history-sidebar__revision-name'],'data-cke-tooltip-text':_0x335b79['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 _0x134b1a=this['fieldView']['element'];this['_tooltipString']=_0x134b1a['scrollWidth']>_0x134b1a['clientWidth']&&_0x134b1a['value']||'';}}class si extends ts{constructor(_0x1091d3,_0x20b343,_0xb65fa5){super(_0x1091d3);const _0x3f2198=new _0x1f0c9d();_0x3f2198['set']({'content':_0x1c5cb8,'viewBox':'0\x200\x2011\x2010'});const _0x1c1724=['ck','ck-revision-history-sidebar__revision-author'];_0xb65fa5&&_0x1c1724['push']('ck-revision-history-sidebar__revision-author_creator');const _0x4117d8=[{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__revision-author__name'],'title':m(_0x1091d3,_0xb65fa5?'Revision\x20creator':'Revision\x20author')},'children':[_0x3f2198,_0x20b343['name']]}];this['setTemplate']({'tag':'li','attributes':{'class':_0x1c1724},'children':_0x4117d8});}}function oi(_0x31d47e,_0x3ef7f1){const _0x5bb0c8=_0x31d47e['bindTemplate'],_0xb3ac95=_0x31d47e['locale'],_0xb8ebc7=_0x243ed3(_0xb3ac95);_0xb8ebc7['panelPosition']='sw';const _0x51515f=function(_0x53389f,_0x59b315){const _0x206446=function(_0x3efab0,_0x3ebde6){const _0x1a7df3=_0x3efab0['locale'],_0x266426={'Compare\x20against\x20selected':m(_0x1a7df3,'Compare\x20against\x20selected'),'Name\x20this\x20revision':m(_0x1a7df3,'Name\x20this\x20revision'),'Restore\x20this\x20revision':m(_0x1a7df3,'Restore\x20this\x20revision')};return _0x3ebde6['map'](_0x5400a4=>{const _0x3f5afd=_0x266426[_0x5400a4['name']];return _0x3f5afd&&_0x3f5afd!==_0x5400a4['name']&&(_0x5400a4['name']=_0x3f5afd),_0x5400a4;});}(_0x53389f,_0x59b315),_0x24c022=new _0x3e452a();for(const _0x59312b of _0x206446){const _0x22dd47={'type':'button','model':new to({'label':_0x59312b['name'],'class':_0x59312b['class'],'withText':!0x0,'role':'menuitem','_action':_0x59312b['action']})};_0x22dd47['model']['bind']('isEnabled')['to'](_0x53389f,'isActionsDropdownOpen',_0x3f4f6e=>'function'!=typeof _0x59312b['isEnabled']||(!_0x3f4f6e||_0x59312b['isEnabled'](_0x53389f))),_0x24c022['add'](_0x22dd47);}return _0x24c022;}(_0x31d47e,_0x3ef7f1);return _0x31d47e['bind']('isActionsDropdownOpen')['to'](_0xb8ebc7,'isOpen'),_0xb8ebc7['buttonView']['set']({'label':m(_0xb3ac95,'Show\x20more\x20items'),'tooltip':!0x0,'tooltipPosition':'sw','icon':_0x3cf2be}),_0xb8ebc7['extendTemplate']({'attributes':{'class':['ck-revision-history-sidebar__revision__actions',_0x5bb0c8['if']('isActionsDropdownOpen','ck-on')]},'on':{'click':_0x5bb0c8['to'](_0x1beb17=>_0x1beb17['stopPropagation']())}}),_0xb8ebc7['on']('execute',_0x49039a=>{_0x31d47e['isReady']&&'function'==typeof _0x49039a['source']['_action']&&_0x49039a['source']['_action'](_0x31d47e);}),_0x370af3(_0xb8ebc7,_0x51515f,{'role':'menu'}),_0xb8ebc7['listenTo'](_0x31d47e,'change:isActionsDropdownOpen',(_0x4361b1,_0x120935,_0x2d5aae)=>{if(_0x2d5aae)for(const _0xa2188a of _0xb8ebc7['listView']['items']){const _0x121a17=_0xa2188a['children']['first'],_0x3adc58=_0x3ef7f1['find'](_0x22055d=>_0x22055d['action']===_0x121a17['_action'])['isVisible'];_0xa2188a['isVisible']=void 0x0===_0x3adc58||_0x3adc58(_0x31d47e);}}),_0xb8ebc7;}class hi extends/* #__PURE__ -- @preserve */
26
+ ti(ts){['id'];['revisionNameView'];['revisionActionsView'];['_revision'];['_requireRevisionName'];constructor(_0x515f9d,_0x164594,_0x341e6a,_0x6fb572){super(_0x515f9d);const _0x290932=this['bindTemplate'],_0x1e87fb=function(_0xb051d,_0x24cf84){const _0x1a7fbd=Array['from'](_0x24cf84['authors'])['filter'](_0x1037ca=>_0x1037ca!=_0x24cf84['creator']);return _0x24cf84['creator']&&_0x1a7fbd['unshift'](_0x24cf84['creator']),_0x1a7fbd['map'](_0x3dbeab=>new si(_0xb051d,_0x3dbeab,_0x3dbeab==_0x24cf84['creator']));}(_0x515f9d,_0x164594);this['id']=_0x164594['id'],this['_revision']=_0x164594,this['_requireRevisionName']=_0x6fb572,this['bind']('name','createdAt')['to'](_0x164594),this['bind']('_createdAtFormatted')['to'](this,'createdAt',_0x2ea6f8=>{return _0x3a8cef=_0x515f9d['uiLanguage'],(_0x1708ba=_0x2ea6f8)['toLocaleDateString'](_0x3a8cef,{'month':'long','day':'numeric'})+',\x20'+_0x1708ba['toLocaleTimeString'](_0x3a8cef,{'hour':'numeric','minute':'numeric'});var _0x3a8cef,_0x1708ba;}),this['set']('isSelected',!0x1),this['set']('isHighlighted',!0x1),this['set']('isActionsDropdownOpen',!0x1),this['set']('isReady',!0x1),this['set']('isEnabled',!0x1),this['revisionNameView']=new pt(_0x515f9d,_0x153297),this['revisionNameView']['fieldView']['extendTemplate']({'attributes':{'maxlength':'220'}}),this['revisionNameView']['fieldView']['bind']('value')['to'](this,'name',_0x7ac68f=>_0x7ac68f||this['_createdAtFormatted']),this['revisionNameView']['bind']('isEnabled')['to'](this,'isSelected',this,'isEnabled',(_0x529673,_0x2429f1)=>_0x529673&&_0x2429f1),this['revisionActionsView']=_0x341e6a&&_0x341e6a['length']?oi(this,_0x341e6a):'',this['revisionActionsView']&&this['revisionActionsView']['bind']('isEnabled')['to'](this),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision-wrapper',_0x290932['if']('isConfirm','ck-revision-history-sidebar__revision-wrapper_confirmation_visible')]},'children':[{'tag':'div','attributes':{'class':['ck','ck-reset','ck-revision-history-sidebar__revision',_0x290932['if']('isEnabled','ck-disabled',_0xd31409=>!_0xd31409),_0x290932['if']('isSelected','ck-revision-history-sidebar__revision_selected'),_0x290932['if']('isHighlighted','ck-revision-history-sidebar__revision_highlighted'),_0x290932['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':_0x290932['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':_0x1e87fb}]},this['revisionActionsView']],'on':{'click':_0x290932['to'](_0x2e925d=>{_0x2e925d['srcElement']['closest']('.ck-thread__remove-confirm')||this['isReady']&&this['isEnabled']&&this['fire']('select',{'id':this['id']});})}}]});}['render'](){super['render']();const _0x80520d=this['revisionNameView']['fieldView']['element'];this['listenTo'](_0x80520d,'change',()=>{this['_requireRevisionName']&&!_0x80520d['value']||this['fire']('setName',{'id':this['id'],'name':_0x80520d['value']}),_0x80520d['value']||(_0x80520d['value']=this['name']?this['name']:this['_createdAtFormatted']);});}['select'](){this['isSelected']=!0x0;}['deselect'](){this['isSelected']=!0x1;}['highlight'](){this['isHighlighted']=!0x0;}['unhighlight'](){this['isHighlighted']=!0x1;}}function ai(_0x5a6535,_0x5d8dd4){const _0xdbfa02=_0x140512['fromJSDate'](_0x5a6535)['setLocale'](_0x5d8dd4),_0x226f16=_0x140512['local'](),_0x65cdbd=_0x226f16['minus']({'days':0x1})['startOf']('day');let _0xf31ab6,_0x410851;return _0xdbfa02['hasSame'](_0x226f16,'day')?(_0xf31ab6=_0xdbfa02['startOf']('day')['toJSDate'](),_0x410851=_0xdbfa02['toRelativeCalendar']()):_0xdbfa02['hasSame'](_0x65cdbd,'day')?(_0xf31ab6=_0x65cdbd['toJSDate'](),_0x410851=_0xdbfa02['toRelativeCalendar']()):_0xdbfa02['hasSame'](_0x226f16,'week')?(_0xf31ab6=_0xdbfa02['startOf']('week')['toJSDate'](),_0x410851=_0xdbfa02['weekdayLong']||''):_0xdbfa02['hasSame'](_0x226f16,'year')?(_0xf31ab6=_0xdbfa02['startOf']('month')['toJSDate'](),_0x410851=_0xdbfa02['monthLong']||''):(_0xf31ab6=_0xdbfa02['startOf']('year')['toJSDate'](),_0x410851=String(_0xdbfa02['year'])),{'startDate':_0xf31ab6,'localizedPeriodName':_0x410851};}class di extends ts{['startDate'];['revisionViews'];['_revisionActions'];['_requireRevisionName'];constructor(_0x26258a,_0x2c7fbe,_0x5e7585,_0x4580af){super(_0x26258a);const _0x294802=ai(_0x2c7fbe,this['locale']['uiLanguage'])['localizedPeriodName'];this['startDate']=_0x2c7fbe,this['revisionViews']=this['createCollection'](),this['_revisionActions']=_0x5e7585,this['_requireRevisionName']=_0x4580af,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':_0x294802}]},{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__time-period__revisions']},'children':this['revisionViews']}]});}['addRevision'](_0x17c52d){const _0x2e3681=new hi(this['locale'],_0x17c52d,this['_revisionActions'],this['_requireRevisionName']);this['revisionViews']['add'](_0x2e3681);}['removeRevision'](_0x1219bd){const _0x339c45=this['revisionViews']['find'](_0x2b63b9=>_0x2b63b9['id']===_0x1219bd['id']);this['revisionViews']['remove'](_0x339c45);}}class as extends ts{constructor(_0x38fee1){super(_0x38fee1);const _0x4475d0=new _0x1f0c9d();_0x4475d0['content']=_0x4709ad,this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset_all','ck-revision-history-sidebar__header']},'children':[_0x4475d0,{'tag':'span','attributes':{'class':['ck','ck-revision-history-sidebar__header__label']},'children':[m(_0x38fee1,'Revision\x20history')]}]});}}class ni extends ts{['timePeriodViews'];['_revisions'];['_revisionActions'];['_requireRevisionName'];constructor(_0x35463d,_0x98f370,_0x12cfcd,_0x23d2ef){super(_0x35463d);const _0x402938=this['bindTemplate'];this['timePeriodViews']=this['createCollection'](),this['timePeriodViews']['delegate']('select')['to'](this),this['timePeriodViews']['delegate']('setName')['to'](this),this['_revisions']=_0x98f370,this['_revisionActions']=_0x12cfcd,this['_requireRevisionName']=_0x23d2ef,this['on']('select',(_0x2bdc85,_0x4fb382)=>{this['fire']('revisionSelected',_0x4fb382);}),this['on']('setName',(_0x300105,_0x408a60)=>{this['fire']('revisionSetName',_0x408a60);}),this['set']('isEnabled',!0x1),this['setTemplate']({'tag':'div','attributes':{'class':['ck','ck-reset','ck-rounded-corners','ck-revision-history-sidebar']},'children':[new as(_0x35463d),{'tag':'div','attributes':{'class':['ck','ck-revision-history-sidebar__timeline',_0x402938['if']('isEnabled','ck-disabled',_0x40eda8=>!_0x40eda8)]},'children':this['timePeriodViews']}]});}['render'](){super['render']();for(const _0x7abcdb of this['_revisions'])this['_addRevision'](_0x7abcdb);this['_revisions']['on']('add',(_0x2ab0c7,_0x2bfef5)=>{this['_addRevision'](_0x2bfef5);}),this['_revisions']['on']('remove',(_0x8aac7d,_0x3c1540)=>{this['_removeRevision'](_0x3c1540);});}get['revisionViews'](){return this['timePeriodViews']['map'](_0x16c31c=>_0x16c31c['revisionViews']['map'](_0x4077a6=>_0x4077a6))['flat']();}['selectRevision'](_0x53964e){for(const _0x291775 of this['revisionViews'])_0x53964e&&_0x53964e['id']===_0x291775['id']?_0x291775['select']():_0x291775['deselect']();}['highlightRevisions'](_0x20926f){for(const _0x5a8a65 of this['revisionViews'])_0x20926f['some'](({id:_0x286b45})=>_0x286b45===_0x5a8a65['id'])?_0x5a8a65['highlight']():_0x5a8a65['unhighlight']();}['_addRevision'](_0x150971){const _0x30965e=ai(_0x150971['createdAt'],this['locale']['uiLanguage'])['startDate'];let _0x5d21b8=this['timePeriodViews']['get'](0x0);_0x5d21b8&&_0x5d21b8['startDate']['getTime']()===_0x30965e['getTime']()||(_0x5d21b8=new di(this['locale'],_0x30965e,this['_revisionActions'],this['_requireRevisionName']),this['timePeriodViews']['add'](_0x5d21b8)),_0x5d21b8['addRevision'](_0x150971);}['_removeRevision'](_0x49a66e){const _0x339c59=ai(_0x49a66e['createdAt'],this['locale']['uiLanguage'])['startDate'];this['_getTimePeriodViewByStartDate'](_0x339c59)['removeRevision'](_0x49a66e);}['_getTimePeriodViewByStartDate'](_0x4d9903){return this['timePeriodViews']['find'](_0x252c69=>_0x252c69['startDate']['getTime']()===_0x4d9903['getTime']());}}class g extends _0x118fc5{['_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(_0x537d86){super(_0x537d86),this['_revisionViewer']=_0x537d86['plugins']['get'](d),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0xdc208=this['_revisionsRepository']['_revisions'],_0x33d37c=this['_createRevisionActions'](),_0x4d1373=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new ci(this['editor']['locale'],_0xdc208,_0x33d37c,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',(_0x5ea574,_0x13d360)=>{_0x13d360['revisionViews']['on']('add',(_0x234900,_0x51c468)=>{_0x51c468['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)),_0x4d1373['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x16b49a=this['_revisionsRepository']['getRevision'](0x0);if(_0x16b49a){const _0x34fb56=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x16b49a['id']);this['_revisionViewer']['compare'](_0x16b49a,_0x34fb56);}}['_handleRevisionSelected'](_0x5252e9,_0x3a0f7a){const _0xac1368=this['_revisionsRepository']['getRevision'](_0x3a0f7a['id']),_0x291874=this['_revisionsRepository']['getEarlierVisibleRevision'](_0xac1368['id']);this['_revisionViewer']['compare'](_0xac1368,_0x291874);}['_handleRevisionSetName'](_0x3d2a2d,_0x2a4f94){this['_revisionsRepository']['getRevision'](_0x2a4f94['id'])['setName'](_0x2a4f94['name']);}['_handleDiffChange'](_0x5a6fe3,_0x3ab3de,_0x411050){const _0x35cf95=this['_revisionsRepository']['getRevisionsInDiff'](_0x411050);_0x35cf95['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x35cf95),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x35cf95[0x0]));}['_createRevisionActions'](){const _0x4cbb44=this['editor'],_0x4c4328=w['availableRevisionActions'],_0x545882=_0x4cbb44['config']['get']('revisionHistory.revisionActions')||w['defaultRevisionActions'];if(_0x545882['length'])return _0x545882['map'](_0x3f1b52=>{const _0x397fe1='string'==typeof _0x3f1b52?Object['assign']({},_0x4c4328[_0x3f1b52]):_0x3f1b52;return _0x397fe1['action']=_0x397fe1['action']['bind'](this,_0x4cbb44),_0x397fe1['isVisible']&&(_0x397fe1['isVisible']=_0x397fe1['isVisible']['bind'](this,_0x4cbb44)),_0x397fe1;});}}function bt(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x4278b7},_0x3779a5)=>{const _0x410027=_0x4278b7['get'](d),_0x2b46e0=_0x410027['repository'];let _0x49d72b=_0x410027['diff']['newRevisionId'],_0x33666c=_0x3779a5['id'];_0x2b46e0['getIndex'](_0x49d72b)>_0x2b46e0['getIndex'](_0x33666c)&&([_0x49d72b,_0x33666c]=[_0x33666c,_0x49d72b]),_0x410027['compare'](_0x49d72b,_0x33666c);},'isVisible':({plugins:_0x56e258},_0x321a2c)=>{const _0x58328c=_0x56e258['get'](d);return!(_0x58328c['repository']['getRevisionsInDiff'](_0x58328c['diff'])['length']>0x2)&&!_0x321a2c['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0xf3a851,{id:_0x425bc2})=>{_0xf3a851['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x425bc2);},'isVisible':({plugins:_0x2e042d},_0x3b41de)=>!!_0x2e042d['get'](d)['repository']['getLaterVisibleRevision'](_0x3b41de['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x2a172a},{id:_0xb8c917,revisionNameView:_0x56e042})=>{const _0x435fa3=_0x2a172a['get'](d),_0xff1df3=_0x435fa3['repository']['getEarlierVisibleRevision'](_0xb8c917);_0x435fa3['compare'](_0xb8c917,_0xff1df3),_0x56e042['focus'](),_0x56e042['fieldView']['select']();}}};}class rt extends st{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x59c04f,_0x85fdc1){super(_0x59c04f),this['_view']=_0x85fdc1,this['_toolbarConfig']=ot(_0x59c04f['config']['get']('toolbar')),this['_elementReplacer']=new ht();}get['element'](){return this['view']['element'];}['init'](_0x25f625){const _0x2800da=this['editor'],_0x12c8bd=this['view'],_0x14ada0=_0x2800da['editing']['view'],_0xb54474=_0x12c8bd['editable'],_0x4de09b=_0x14ada0['document']['getRoot']();_0xb54474['name']=_0x4de09b['rootName'],_0x12c8bd['render']();const _0x160120=_0xb54474['element'];this['setEditableElement'](_0xb54474['name'],_0x160120),_0x12c8bd['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x14ada0['attachDomRoot'](_0x160120),this['_elementReplacer']['replace'](_0x25f625,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x3add2a=this['view'],_0x46e00c=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x46e00c['detachDomRoot'](_0x3add2a['editable']['name']),_0x3add2a['destroy']();}['_initToolbar'](){const _0x4474b9=this['view'];_0x4474b9['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x4474b9['stickyPanel']['limiterElement']=_0x4474b9['element'],_0x4474b9['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x309354})=>_0x309354),_0x4474b9['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x4474b9['toolbar']);}}class et extends ct{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x1b47ca,_0x57441a,_0x4e01b8={}){super(_0x1b47ca),this['stickyPanel']=new ut(_0x1b47ca),this['toolbar']=new lt(_0x1b47ca,{'shouldGroupWhenFull':_0x4e01b8['shouldToolbarGroupWhenFull']}),this['_editable']=new dt(_0x1b47ca,_0x57441a);}['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(_0x2ecd46,_0x1f08bc){super(_0x1f08bc),this['sourceElement']=_0x2ecd46,this['model']['document']['createRoot']();const _0x9fc4aa=new et(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new rt(this,_0x9fc4aa);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x26aea5,_0x33c6c5){const _0x43b1ae=new this(_0x26aea5,_0x33c6c5);return await _0x43b1ae['initPlugins'](),await _0x43b1ae['ui']['init'](_0x26aea5),await _0x43b1ae['data']['init'](_0x43b1ae['config']['get']('initialData')||''),_0x43b1ae['fire']('ready'),_0x43b1ae;}}const p=['RevisionHistoryUI','RestrictedEditingMode'];class Rt extends _0x15974b{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x5490ba){function _0x1bc5d2(_0x4fcc1d){return _0x4fcc1d['map'](_0x59f608=>String['fromCharCode'](_0x59f608))['join']('');}super(_0x5490ba),this['result']='end',_0x5490ba[_0x1bc5d2([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x1bc5d2([0x76,0x69,0x65,0x77])][_0x1bc5d2([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x1bc5d2([0x61,0x75,0x74,0x6f]),_0x5490ba[_0x1bc5d2([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x1bc5d2([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x1bc5d2([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x1bc5d2([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x1bc5d2([0x6f,0x6b])});}}class k extends _0x15974b{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[l,u];}constructor(_0x421d55){if(super(_0x421d55),!this['editor']['config']['get']('revisionHistory'))throw new _0x479dc4('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0x174458=>this['_showRevisionViewer']({..._0x174458,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0x3af230=>this['_closeRevisionViewer'](_0x3af230)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0xfedc37=>this['_restoreRevision'](_0xfedc37)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x3c6309){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x3c6309;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x331ec0){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x331ec0);}['getRevision'](_0x3a639f){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x3a639f);}['getRevisions'](_0x468d7){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x468d7||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x3dbdd0=this['editor'],_0x68b774=_0x1e0a56(_0x3dbdd0,p),_0x5b955e=_0x3dbdd0['plugins']['get']('RevisionTracker'),_0x3ca48c=_0x3dbdd0['plugins']['get']('Users')['users'];return _0x68b774['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0x68b774['lazyRoots'],(_0x68b774['plugins']['push'](Rt,d,g,class extends _0x15974b{static get['requires'](){return[d,'Users'];}['init'](){const _0x2ac968=this['editor']['plugins']['get']('Users');for(const _0x4a8a33 of _0x3ca48c)_0x4a8a33['isAnonymous']||_0x2ac968['getUser'](_0x4a8a33['id'])||_0x2ac968['addUser'](_0x4a8a33);const _0x5f3557=_0x5b955e['repository']['getRevisions']();let _0x3f31ec=null;const _0x351c78=this['editor']['plugins']['get']('RevisionViewer');_0x351c78['adapter']=_0x5b955e['adapter'],_0x351c78['bind']('isEnabled')['to'](_0x5b955e),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x3dbdd0,'isReadOnly',_0x1dab34=>!_0x1dab34);for(const _0x40d507 of _0x5f3557){const _0x34d0fa=null===_0x40d507['creator'];if(_0x34d0fa&&_0x40d507['toVersion']===_0x40d507['fromVersion'])continue;const _0x27124c=_0x40d507['toJSON']();_0x351c78['addRevisionData'](_0x27124c,(_0x13d221,_0x3b2e6b,_0x4da1ca)=>{if(_0x34d0fa){if(_0x3f31ec)_0x3f31ec['_update'](_0x13d221,_0x3b2e6b);else{if(!_0x3b2e6b){const _0x885291=_0x4da1ca['toJSON']();_0x885291['id']=_0x41fc2a(),_0x5b955e['saveRevision'](_0x885291,_0x4da1ca['toVersion'])['then'](_0x4c21f9=>{_0x3f31ec=_0x4c21f9;});}}}else _0x40d507['_update'](_0x13d221,_0x3b2e6b);});}}},w),_0x68b774);}['_enhanceShowRevisionViewerCallback'](){const _0x1945a7=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x560f80=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0xd49825=this['editor']['plugins']['get']('Autosave');await _0xd49825['save']();}else await _0x560f80['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x4586e0=this['editor']['plugins']['get']('Dialog');_0x4586e0['isOpen']&&_0x4586e0['hide']();}const _0x1c09d9=this['_getRevisionViewerEditorConfig']();return _0x1945a7(_0x1c09d9)['then'](_0xcf6ee5=>{return(this['_viewerEditor']=_0xcf6ee5,this['editor']['plugins']['has']('Annotations'))&&this['editor']['plugins']['get']('Annotations')['refreshVisibility'](),_0xcf6ee5;})['catch'](_0x540e68=>(console['error'](_0x540e68),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x55fb69=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'](),_0x55fb69(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x14c020=this['editor']['plugins']['get']('Annotations');_0x14c020['refreshVisibility'](),_0x14c020['refreshPositioning']();}})));}['_showRevisionViewer'](_0x4d5f48){const _0x201567=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x4a4654=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x3e090e=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return R['create'](_0x3e090e,_0x4d5f48)['then'](_0x2d649c=>(_0x4a4654['style']['display']='block',_0x201567['style']['display']='none',_0x2d649c));}['_closeRevisionViewer'](_0x40d095){const _0x51f83d=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x51f83d['style']['display']='',_0x40d095['destroy']();}async['_restoreRevision'](_0x1973a1){const _0x2a6386=this['editor'],_0x578bbd=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0x269b46=_0x2a6386['plugins']['get']('RevisionTracker'),_0x18a160=_0x578bbd['repository']['getRevision'](_0x1973a1);let _0x2c3099,_0x2d7b09,_0x1f1dc4;try{_0x2c3099=await _0x578bbd['getRevisionData'](_0x18a160),_0x2d7b09=await _0x578bbd['getRevisionRootsAttributes'](_0x18a160);}catch(_0x3d5a94){return void console['error'](_0x3d5a94);}_0x2a6386['model']['change'](_0x40f1e7=>{for(const _0x3964f5 of Array['from'](_0x2a6386['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x40f1e7['removeMarker'](_0x3964f5);}),_0x578bbd['isReady']=!0x1,_0x2a6386['model']['enqueueChange'](_0x477e7e=>{_0x477e7e['setSelection'](null),_0x477e7e['removeSelectionAttribute'](_0x2a6386['model']['document']['selection']['getAttributeKeys']());const _0x24ee92=Object['keys'](_0x2c3099);for(const _0x595320 of _0x2a6386['model']['document']['roots'])'$graveyard'!=_0x595320['rootName']&&_0x595320['isAttached']()&&!_0x24ee92['includes'](_0x595320['rootName'])&&_0x477e7e['detachRoot'](_0x595320);for(const _0x44bce8 of _0x24ee92){let _0x4b47da=_0x2a6386['model']['document']['getRoot'](_0x44bce8);_0x4b47da&&_0x4b47da['isAttached']()||(_0x4b47da=_0x477e7e['addRoot'](_0x44bce8));const _0x5612fe=_0x2d7b09[_0x44bce8],_0x4ae83e=Object['keys'](_0x5612fe),_0x5c57f0=_0x2c3099[_0x44bce8];for(const _0x45ad04 of _0x4b47da['getAttributeKeys']())_0x4ae83e['includes'](_0x45ad04)||_0x477e7e['removeAttribute'](_0x45ad04,_0x4b47da);for(const _0x47a0b3 of _0x4ae83e)_0x477e7e['setAttribute'](_0x47a0b3,_0x2d7b09[_0x44bce8][_0x47a0b3],_0x4b47da);_0x477e7e['remove'](_0x477e7e['createRangeIn'](_0x4b47da)),_0x477e7e['insert'](_0x2a6386['data']['parse'](_0x5c57f0,_0x4b47da),_0x4b47da,0x0);}});const _0x28efed=m(_0x2a6386['locale'],'Restored');if(_0x18a160['name'])_0x1f1dc4=-0x1==_0x18a160['name']['indexOf'](_0x28efed)?_0x28efed+':\x20'+_0x18a160['name']:_0x18a160['name'];else _0x1f1dc4=_0x28efed+':\x20'+(_0x18a160['createdAt']['toLocaleDateString'](_0x2a6386['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x18a160['createdAt']['toLocaleTimeString'](_0x2a6386['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0x269b46['saveRevision']({'name':_0x1f1dc4}),_0x578bbd['isReady']=!0x0,_0x2a6386['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{a as Revision,k as RevisionHistory,u as RevisionHistoryUI,l as RevisionTracker,d as RevisionViewer,le as RevisionViewerLoadingOverlay,g as RevisionViewerUI,j as RevisionsRepository,w as RevisionsSidebar};
28
+ yt();static get['pluginName'](){return'RevisionsSidebar';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[d];}constructor(_0x59aa1e){super(_0x59aa1e),this['_revisionViewer']=_0x59aa1e['plugins']['get'](d),this['_revisionsRepository']=this['_revisionViewer']['repository'],this['_sidebarView']=null;}['init'](){const _0x429fb9=this['_revisionsRepository']['_revisions'],_0x53fffe=this['_createRevisionActions'](),_0x222c6c=this['editor']['config']['get']('revisionHistory.viewerSidebarContainer');this['_sidebarView']=new ni(this['editor']['locale'],_0x429fb9,_0x53fffe,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',(_0x2fb1ee,_0x178363)=>{_0x178363['revisionViews']['on']('add',(_0x5095d2,_0x9e693d)=>{_0x9e693d['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)),_0x222c6c['appendChild'](this['_sidebarView']['element']);}['destroy'](){this['_sidebarView']['element']['remove'](),this['_sidebarView']['destroy']();}['_handleEditorDataReady'](){const _0x4a5d02=this['_revisionsRepository']['getRevision'](0x0);if(_0x4a5d02){const _0x198803=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x4a5d02['id']);this['_revisionViewer']['compare'](_0x4a5d02,_0x198803);}}['_handleRevisionSelected'](_0x18ab7c,_0x35cc4a){const _0x36839b=this['_revisionsRepository']['getRevision'](_0x35cc4a['id']),_0x2f8591=this['_revisionsRepository']['getEarlierVisibleRevision'](_0x36839b['id']);this['_revisionViewer']['compare'](_0x36839b,_0x2f8591);}['_handleRevisionSetName'](_0x399a8f,_0x38823c){this['_revisionsRepository']['getRevision'](_0x38823c['id'])['setName'](_0x38823c['name']);}['_handleDiffChange'](_0x22ee2c,_0x4732f2,_0x268a8e){const _0x20e374=this['_revisionsRepository']['getRevisionsInDiff'](_0x268a8e);_0x20e374['length']>0x2?(this['_sidebarView']['highlightRevisions'](_0x20e374),this['_sidebarView']['selectRevision'](null)):(this['_sidebarView']['highlightRevisions']([]),this['_sidebarView']['selectRevision'](_0x20e374[0x0]));}['_createRevisionActions'](){const _0x2732b9=this['editor'],_0xfe746c=g['availableRevisionActions'],_0x5d4ece=_0x2732b9['config']['get']('revisionHistory.revisionActions')||g['defaultRevisionActions'];if(_0x5d4ece['length'])return _0x5d4ece['map'](_0x213567=>{const _0x4c0fac='string'==typeof _0x213567?Object['assign']({},_0xfe746c[_0x213567]):_0x213567;return _0x4c0fac['action']=_0x4c0fac['action']['bind'](this,_0x2732b9),_0x4c0fac['isVisible']&&(_0x4c0fac['isVisible']=_0x4c0fac['isVisible']['bind'](this,_0x2732b9)),_0x4c0fac;});}}function yt(){return{'compareAgainstSelected':{'name':'Compare\x20against\x20selected','action':({plugins:_0x331d00},_0x70baa0)=>{const _0x56a7a9=_0x331d00['get'](d),_0x1a5a2c=_0x56a7a9['repository'];let _0x28d2cf=_0x56a7a9['diff']['newRevisionId'],_0x3356ba=_0x70baa0['id'];_0x1a5a2c['getIndex'](_0x28d2cf)>_0x1a5a2c['getIndex'](_0x3356ba)&&([_0x28d2cf,_0x3356ba]=[_0x3356ba,_0x28d2cf]),_0x56a7a9['compare'](_0x28d2cf,_0x3356ba);},'isVisible':({plugins:_0x449385},_0xfdb12c)=>{const _0x6e2682=_0x449385['get'](d);return!(_0x6e2682['repository']['getRevisionsInDiff'](_0x6e2682['diff'])['length']>0x2)&&!_0xfdb12c['isSelected'];}},'restoreRevision':{'name':'Restore\x20this\x20revision','action':(_0x373bdd,{id:_0x2f7abe})=>{_0x373bdd['config']['get']('revisionHistory')['restoreRevisionCallback'](_0x2f7abe);},'isVisible':({plugins:_0x3690e5},_0x45bc37)=>!!_0x3690e5['get'](d)['repository']['getLaterVisibleRevision'](_0x45bc37['id'])},'nameRevision':{'name':'Name\x20this\x20revision','action':({plugins:_0x36b6ed},{id:_0x4a242b,revisionNameView:_0x40d6e1})=>{const _0x4da4eb=_0x36b6ed['get'](d),_0x4635a1=_0x4da4eb['repository']['getEarlierVisibleRevision'](_0x4a242b);_0x4da4eb['compare'](_0x4a242b,_0x4635a1),_0x40d6e1['focus'](),_0x40d6e1['fieldView']['select']();}}};}class rt extends st{['_view'];['_toolbarConfig'];['_elementReplacer'];get['view'](){return this['_view'];}constructor(_0x2215ec,_0x2b926c){super(_0x2215ec),this['_view']=_0x2b926c,this['_toolbarConfig']=ot(_0x2215ec['config']['get']('toolbar')),this['_elementReplacer']=new ht();}get['element'](){return this['view']['element'];}['init'](_0x565fff){const _0x2830dd=this['editor'],_0xc749a9=this['view'],_0x4edf99=_0x2830dd['editing']['view'],_0x3d2797=_0xc749a9['editable'],_0xbc9187=_0x4edf99['document']['getRoot']();_0x3d2797['name']=_0xbc9187['rootName'],_0xc749a9['render']();const _0xf8c693=_0x3d2797['element'];this['setEditableElement'](_0x3d2797['name'],_0xf8c693),_0xc749a9['editable']['bind']('isFocused')['to'](this['focusTracker']),_0x4edf99['attachDomRoot'](_0xf8c693),this['_elementReplacer']['replace'](_0x565fff,this['element']),this['_initToolbar'](),this['fire']('ready');}['destroy'](){super['destroy']();const _0x4c1f7c=this['view'],_0x15ce9c=this['editor']['editing']['view'];this['_elementReplacer']['restore'](),_0x15ce9c['detachDomRoot'](_0x4c1f7c['editable']['name']),_0x4c1f7c['destroy']();}['_initToolbar'](){const _0x3b732c=this['view'];_0x3b732c['stickyPanel']['bind']('isActive')['to'](this['focusTracker'],'isFocused'),_0x3b732c['stickyPanel']['limiterElement']=_0x3b732c['element'],_0x3b732c['stickyPanel']['bind']('viewportTopOffset')['to'](this,'viewportOffset',({top:_0x3bed65})=>_0x3bed65),_0x3b732c['toolbar']['fillFromConfig'](this['_toolbarConfig'],this['componentFactory']),this['addToolbar'](_0x3b732c['toolbar']);}}class et extends ct{['_editable'];['stickyPanel'];['toolbar'];get['editable'](){return this['_editable'];}constructor(_0x4c5158,_0x340702,_0x2c557d={}){super(_0x4c5158),this['stickyPanel']=new lt(_0x4c5158),this['toolbar']=new nt(_0x4c5158,{'shouldGroupWhenFull':_0x2c557d['shouldToolbarGroupWhenFull']}),this['_editable']=new dt(_0x4c5158,_0x340702);}['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(_0x2df686,_0x30442f){super(_0x30442f),this['sourceElement']=_0x2df686,this['model']['document']['createRoot']();const _0x453e7f=new et(this['locale'],this['editing']['view'],{'shouldToolbarGroupWhenFull':!0x0});this['_ui']=new rt(this,_0x453e7f);}['destroy'](){return this['updateSourceElement'](),this['ui']['destroy'](),super['destroy']();}static async['create'](_0x20f920,_0x26785f){const _0xfba09b=new this(_0x20f920,_0x26785f);return await _0xfba09b['initPlugins'](),await _0xfba09b['ui']['init'](_0x20f920),await _0xfba09b['data']['init'](_0xfba09b['config']['get']('initialData')||''),_0xfba09b['fire']('ready'),_0xfba09b;}}const p=['RevisionHistoryUI','RestrictedEditingMode'];class bt extends _0x118fc5{['result'];static get['pluginName'](){return'RevisionViewerIntegration';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}constructor(_0x339011){function _0x33b53a(_0x52a007){return _0x52a007['map'](_0x2a7239=>String['fromCharCode'](_0x2a7239))['join']('');}super(_0x339011),this['result']='end',_0x339011[_0x33b53a([0x65,0x64,0x69,0x74,0x69,0x6e,0x67])][_0x33b53a([0x76,0x69,0x65,0x77])][_0x33b53a([0x5f,0x6f,0x76,0x65,0x72,0x6c,0x61,0x79,0x4d,0x6f,0x64,0x65,0x48,0x69,0x6e,0x74])]=_0x33b53a([0x61,0x75,0x74,0x6f]),_0x339011[_0x33b53a([0x5f,0x73,0x65,0x6e,0x64,0x55,0x73,0x61,0x67,0x65,0x52,0x65,0x71,0x75,0x65,0x73,0x74])]=()=>window[_0x33b53a([0x50,0x72,0x6f,0x6d,0x69,0x73,0x65])][_0x33b53a([0x72,0x65,0x73,0x6f,0x6c,0x76,0x65])]({[_0x33b53a([0x73,0x74,0x61,0x74,0x75,0x73])]:_0x33b53a([0x6f,0x6b])});}}class k extends _0x118fc5{['_viewerEditor'];static get['pluginName'](){return'RevisionHistory';}static get['isOfficialPlugin'](){return!0x0;}static get['isPremiumPlugin'](){return!0x0;}static get['requires'](){return[u,f];}constructor(_0x55e491){if(super(_0x55e491),!this['editor']['config']['get']('revisionHistory'))throw new _0x1a0978('revision-history-missing-configuration',this);this['_viewerEditor']=null,this['editor']['config']['define']('revisionHistory.showRevisionViewerCallback',_0xd59525=>this['_showRevisionViewer']({..._0xd59525,'translations':this['editor']['locale']['translations']})),this['editor']['config']['define']('revisionHistory.closeRevisionViewerCallback',_0xdde46=>this['_closeRevisionViewer'](_0xdde46)),this['editor']['config']['define']('revisionHistory.restoreRevisionCallback',_0xa4cd5d=>this['_restoreRevision'](_0xa4cd5d)),this['editor']['config']['define']('revisionHistory.requireRevisionName',!0x1),this['_enhanceShowRevisionViewerCallback'](),this['_enhanceCloseRevisionViewerCallback']();}set['adapter'](_0x139eff){this['editor']['plugins']['get']('RevisionTracker')['adapter']=_0x139eff;}get['adapter'](){return this['editor']['plugins']['get']('RevisionTracker')['adapter'];}['addRevisionData'](_0x506174){return this['editor']['plugins']['get']('RevisionTracker')['addRevisionData'](_0x506174);}['getRevision'](_0x2cbb3c){return this['editor']['plugins']['get']('RevisionsRepository')['getRevision'](_0x2cbb3c);}['getRevisions'](_0x7bdcec){return this['editor']['plugins']['get']('RevisionsRepository')['getRevisions'](_0x7bdcec||{'toJSON':!0x1});}['_getRevisionViewerEditorConfig'](){const _0x3baf92=this['editor'],_0xd8d063=_0x259f0a(_0x3baf92,p),_0x513dc9=_0x3baf92['plugins']['get']('RevisionTracker'),_0x14b51b=_0x3baf92['plugins']['get']('Users')['users'];return _0xd8d063['toolbar']=['exitToEditing','restoreRevision','changesNavigation'],delete _0xd8d063['lazyRoots'],(_0xd8d063['plugins']['push'](bt,d,w,class extends _0x118fc5{static get['requires'](){return[d,'Users'];}['init'](){const _0x1df7f0=this['editor']['plugins']['get']('Users');for(const _0x2d1421 of _0x14b51b)_0x2d1421['isAnonymous']||_0x1df7f0['getUser'](_0x2d1421['id'])||_0x1df7f0['addUser'](_0x2d1421);const _0x316b3b=_0x513dc9['repository']['getRevisions']();let _0x284117=null;const _0x1c1cf7=this['editor']['plugins']['get']('RevisionViewer');_0x1c1cf7['adapter']=_0x513dc9['adapter'],_0x1c1cf7['bind']('isEnabled')['to'](_0x513dc9),this['editor']['commands']['get']('restoreRevision')['bind']('isEnabled')['to'](_0x3baf92,'isReadOnly',_0x343153=>!_0x343153);for(const _0x5b09e6 of _0x316b3b){const _0x560302=null===_0x5b09e6['creator'];if(_0x560302&&_0x5b09e6['toVersion']===_0x5b09e6['fromVersion'])continue;const _0x3a4f9c=_0x5b09e6['toJSON']();_0x1c1cf7['addRevisionData'](_0x3a4f9c,(_0x16ce4d,_0x52e1d4,_0x46cd59)=>{if(_0x560302){if(_0x284117)_0x284117['_update'](_0x16ce4d,_0x52e1d4);else{if(!_0x52e1d4){const _0x7b5490=_0x46cd59['toJSON']();_0x7b5490['id']=_0x118080(),_0x513dc9['saveRevision'](_0x7b5490,_0x46cd59['toVersion'])['then'](_0x543266=>{_0x284117=_0x543266;});}}}else _0x5b09e6['_update'](_0x16ce4d,_0x52e1d4);});}}},g),_0xd8d063);}['_enhanceShowRevisionViewerCallback'](){const _0x357daa=this['editor']['config']['get']('revisionHistory')['showRevisionViewerCallback'];this['editor']['config']['set']('revisionHistory.showRevisionViewerCallback',async()=>{this['editor']['enableReadOnlyMode']('revision-history-viewer-opened');const _0x108f93=this['editor']['plugins']['get']('RevisionTracker');if(this['editor']['plugins']['has']('Autosave')){const _0x409f45=this['editor']['plugins']['get']('Autosave');await _0x409f45['save']();}else await _0x108f93['update']();if(this['editor']['plugins']['has']('PaginationLookup')&&this['editor']['plugins']['get']('PaginationLookup')['_recalculatePageBreaks'](),this['editor']['plugins']['has']('Dialog')){const _0x568073=this['editor']['plugins']['get']('Dialog');_0x568073['isOpen']&&_0x568073['hide']();}const _0x402c4d=this['_getRevisionViewerEditorConfig']();return _0x357daa(_0x402c4d)['then'](_0x15e04b=>{return(this['_viewerEditor']=_0x15e04b,this['editor']['plugins']['has']('Annotations'))&&this['editor']['plugins']['get']('Annotations')['refreshVisibility'](),_0x15e04b;})['catch'](_0x3f11dd=>(console['error'](_0x3f11dd),this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),null));});}['_enhanceCloseRevisionViewerCallback'](){const _0x664da4=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'](),_0x664da4(this['_viewerEditor'])['then'](()=>{if(this['editor']['disableReadOnlyMode']('revision-history-viewer-opened'),this['_viewerEditor']=null,this['editor']['plugins']['has']('Annotations')){const _0x5cae11=this['editor']['plugins']['get']('Annotations');_0x5cae11['refreshVisibility'](),_0x5cae11['refreshPositioning']();}})));}['_showRevisionViewer'](_0x225a63){const _0x43d203=this['editor']['config']['get']('revisionHistory.editorContainer'),_0x3ffd36=this['editor']['config']['get']('revisionHistory.viewerContainer'),_0x26973a=this['editor']['config']['get']('revisionHistory.viewerEditorElement');return R['create'](_0x26973a,_0x225a63)['then'](_0x2adc44=>(_0x3ffd36['style']['display']='block',_0x43d203['style']['display']='none',_0x2adc44));}['_closeRevisionViewer'](_0x30f0b3){const _0x271278=this['editor']['config']['get']('revisionHistory.editorContainer');return this['editor']['config']['get']('revisionHistory.viewerContainer')['style']['display']='none',_0x271278['style']['display']='',_0x30f0b3['destroy']();}async['_restoreRevision'](_0x5c0926){const _0x5e7bda=this['editor'],_0x317791=this['_viewerEditor']['plugins']['get']('RevisionViewer'),_0xe7d352=_0x5e7bda['plugins']['get']('RevisionTracker'),_0x1494ef=_0x317791['repository']['getRevision'](_0x5c0926);let _0x1a70b1,_0x440904,_0x5ba78f;try{_0x1a70b1=await _0x317791['getRevisionData'](_0x1494ef),_0x440904=await _0x317791['getRevisionRootsAttributes'](_0x1494ef);}catch(_0x5b25e3){return void console['error'](_0x5b25e3);}_0x5e7bda['model']['change'](_0x46b8cf=>{for(const _0x4e5eb3 of Array['from'](_0x5e7bda['model']['markers']['getMarkersGroup']('restrictedEditingException')))_0x46b8cf['removeMarker'](_0x4e5eb3);}),_0x317791['isReady']=!0x1,_0x5e7bda['model']['enqueueChange'](_0x58158b=>{_0x58158b['setSelection'](null),_0x58158b['removeSelectionAttribute'](_0x5e7bda['model']['document']['selection']['getAttributeKeys']());const _0x2b8273=Object['keys'](_0x1a70b1);for(const _0x14ae89 of _0x5e7bda['model']['document']['roots'])'$graveyard'!=_0x14ae89['rootName']&&_0x14ae89['isAttached']()&&!_0x2b8273['includes'](_0x14ae89['rootName'])&&_0x58158b['detachRoot'](_0x14ae89);for(const _0x5951cc of _0x2b8273){let _0x4ccc73=_0x5e7bda['model']['document']['getRoot'](_0x5951cc);_0x4ccc73&&_0x4ccc73['isAttached']()||(_0x4ccc73=_0x58158b['addRoot'](_0x5951cc));const _0x91481a=_0x440904[_0x5951cc],_0x158e56=Object['keys'](_0x91481a),_0x33e9ce=_0x1a70b1[_0x5951cc];for(const _0x3a6528 of _0x4ccc73['getAttributeKeys']())_0x158e56['includes'](_0x3a6528)||_0x58158b['removeAttribute'](_0x3a6528,_0x4ccc73);for(const _0x3a7acc of _0x158e56)_0x58158b['setAttribute'](_0x3a7acc,_0x440904[_0x5951cc][_0x3a7acc],_0x4ccc73);_0x58158b['remove'](_0x58158b['createRangeIn'](_0x4ccc73)),_0x58158b['insert'](_0x5e7bda['data']['parse'](_0x33e9ce,_0x4ccc73),_0x4ccc73,0x0);}});const _0x51aa33=m(_0x5e7bda['locale'],'Restored');if(_0x1494ef['name'])_0x5ba78f=-0x1==_0x1494ef['name']['indexOf'](_0x51aa33)?_0x51aa33+':\x20'+_0x1494ef['name']:_0x1494ef['name'];else _0x5ba78f=_0x51aa33+':\x20'+(_0x1494ef['createdAt']['toLocaleDateString'](_0x5e7bda['locale']['uiLanguage'],{'month':'long','day':'numeric'})+',\x20'+_0x1494ef['createdAt']['toLocaleTimeString'](_0x5e7bda['locale']['uiLanguage'],{'hour':'numeric','minute':'numeric'}));return await _0xe7d352['saveRevision']({'name':_0x5ba78f}),_0x317791['isReady']=!0x0,_0x5e7bda['config']['get']('revisionHistory')['closeRevisionViewerCallback']();}}export{h as Revision,k as RevisionHistory,f as RevisionHistoryUI,u as RevisionTracker,d as RevisionViewer,ge as RevisionViewerLoadingOverlay,w as RevisionViewerUI,j as RevisionsRepository,g as RevisionsSidebar};